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C,iBAAiB,EACjB5tC,UAAU,EACV6tC,YAAa,IACd,CACCl6M,KAAM,eACN/D,MAAO,cACP89M,eAAgB,OAChB1tC,UAAU,EACV2tC,SAAS,EACTC,iBAAiB,EACjBC,YAAa,EACbt+K,YAAa,GACbxL,UAAW,CAAC,qCACb,CACCpwB,KAAM,YACN/D,MAAO,WACP89M,eAAgB,OAChB1tC,UAAU,EACV2tC,SAAS,EACTC,iBAAiB,EACjBC,YAAa,EACbt+K,YAAa,WACbxL,UAAW,CAAC,oCACb,CACCpwB,KAAM,mBACN/D,MAAO,iBACP89M,eAAgB,SAChB1tC,UAAU,EACV2tC,SAAS,EACTC,iBAAiB,EACjBC,YAAa,GACbt+K,YAAa,gBACd,CACC57B,KAAM,kBACN/D,MAAO,gBACP89M,eAAgB,OAChB1tC,UAAU,EACV2tC,SAAS,EACTC,iBAAiB,EACjBC,YAAa,EACbt+K,YAAa,YACbxL,UAAW,CAAC,qCACb,CACCpwB,KAAM,iBACN/D,MAAO,gBACP89M,eAAgB,SAChB1tC,UAAU,EACV2tC,SAAS,EACTC,iBAAiB,EACjBC,YAAa,GACbt+K,YAAa,IACd,CACC57B,KAAM,kBACN/D,MAAO,iBACP89M,eAAgB,SAChB1tC,UAAU,EACV2tC,SAAS,EACTC,iBAAiB,EACjBC,YAAa,GACbt+K,YAAa,gBACd,CACC57B,KAAM,kBACN/D,MAAO,iBACP89M,eAAgB,SAChB1tC,UAAU,EACV2tC,SAAS,EACTC,iBAAiB,EACjBC,YAAa,GACbt+K,YAAa,GACbxL,UAAW,CAAC,yBACb,CACCpwB,KAAM,wBACN/D,MAAO,mBACP89M,eAAgB,SAChB1tC,UAAU,EACV2tC,SAAS,EACTC,iBAAiB,EACjBC,YAAa,IACd,CACCl6M,KAAM,cACN/D,MAAO,aACP89M,eAAgB,SAChB1tC,UAAU,EACV2tC,SAAS,EACTC,iBAAiB,EACjBC,YAAa,GACbt+K,YAAa,cACd,CACC57B,KAAM,gBACN/D,MAAO,eACP89M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C,GACAiwY,GACA53a,MACAy9I,GACAwrR,GACA7jZ,+BAA4B,CAExBxsG,KACAkrG,GACAe,GACA6rF,KAEAwmN,GACAD,GAEAqK,GAEAsK,GACAC,GACAG,GACAqF,GACAymG,GACAvmG,GACAE,GACAE,GACArC,GACAC,GACAwC,GACAO,GACAG,GAEA8L,GACA1M,GACAG,GACAI,GACAD,KAEJ2kG,MCtFD,MAAMoB,GACTr+gB,sBAC+B,IAAIghG,MACVn5C,sBAAsB,kBAAmBi+X,GAClE,yCAJSu4F,GAAiB,kDAAjBA,yDA5BLvvb,KACAA,KACAsR,KACA+F,MACApB,MACArD,MACA4zC,GACAj1C,GACAuE,MACAmJ,GACAggC,gBACArpC,GACA6mB,+BAA4B,CAExBxsG,KACAwma,QCmIL,MAAM+4F,GACTt+gB,qBACI,MAAMH,EAAuB,IAAImhG,KACjCnhG,EAAqBgoD,sBAAsB,WAAYk/Y,IACvDlnc,EAAqBgoD,sBAAsB,WAAY4rY,IACvD5zb,EAAqBgoD,sBAAsB,kBAAmB2zY,IAC9D37b,EAAqBgoD,sBAAsB,eAAgB0zY,GAC/D,yCAPS+iF,GAAU,kDAAVA,0DALE,CACPj0F,IACH9pb,SAvFG+0I,GACAj1C,GACAuE,MACAwB,MACAtB,MACAqB,MACAyvC,MACAkpD,MACA/5F,MACAwwC,MACA7zC,MACAkka,GACA73X,gBACArpC,GACA6mB,+BAA4B,CAExBxsG,KACAg6a,GACAxhG,GACAwlG,GACApH,GACAC,GACAC,GACAE,GACAC,GACA6F,GACA2J,GACAC,GACAtM,KAEJklF,MC7DD,MAAME,GACTv+gB,qBACI,MAAMH,EAAuB,IAAImhG,KACjCnhG,EAAqBgoD,sBAAsB,gBAAiB6kZ,IAC5D7sc,EAAqBgoD,sBAAsB,mBAAoBqgZ,GACnE,yCALSq2E,GAAe,kDAAfA,0DARE,CACPp3E,IACH5mc,SArBG+0I,GACAj1C,GACA09a,GACAn6R,GACAwrR,GACArhY,gBACArpC,GACA6mB,+BA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+F,MACAovC,MACA3wC,MACA0wC,GACAj1C,GACAqB,MACAo4Z,GACA/rX,gBACA2zL,MACAF,MACA98N,GACAqJ,GACAwd,+BAA4B,CAExBxsG,KACAkrG,GACAe,QCsEL,MAAMk4Z,GACTljhB,qBACI,MAAMH,EAAuB,IAAImhG,KACjCk9a,iBACAH,iBACAM,iBACAC,iBACAC,iBACAj9M,iBACAG,iBACA+8M,iBACAC,iBACAyD,iBACAC,iBACAroB,iBACAl4L,iBACAqgN,iBACAI,iBACAxihB,EAAqBQ,qBAAqB,+BAAgC2ihB,OAC1ED,iBACA9T,gBACJ,yCArBSiU,GAAgB,kDAAhBA,0DAvCE,CACP,CAAEnwgB,QAASpiB,eAAc4uhB,SAAUG,IACnCJ,IACAE,GACAwD,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACAA,MACArxe,KACAkoN,GACAu1I,GACA4zI,MACAA,MACAA,MACAA,MACAA,MACA7pN,GACA6pN,MACAA,MACAA,MACAA,MACAG,MACH5ihB,SAlEG+0I,GACA4oY,GACAH,GACAM,GACAC,GACAC,GACAj9M,GACAG,GACAG,GACAqgN,GACAnoB,GACAuoB,GACA7D,GACAC,GACAyD,GACAC,GACAp0Y,gBACAxiB,+BAA4B,CAExBxsG,KACAkrG,GACAe,GACA6rF,OAEJksU,GACA9T,sBCzCD,MAAMmU,4BCxCDr0iB,qCACIA,qDACJA,uDAsCJA,sCAA4D,WAEpDA,oCAAwEA,sBAC5EA,uEAD4EA,uLDF3Eq0iB,GAAgB,kDAAhBA,0DA5BE,CACP,CAAErwgB,QAAS,YAAaswgB,WAAax4nB,GAAWA,EAAE7N,IAAI,aAAck3mB,KAAM,CAAC,cAC3E,CAAEnhf,QAASuwgB,MAAkBD,WAAax4nB,GAAWA,EAAE7N,IAAI,SAAUk3mB,KAAM,CAAC,cAC5E,CAAEnhf,QAAS,QAASswgB,WAAax4nB,GAAW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AAC0xK,QAAyB,CAAEu7c,UAAU,IAC5E7uoB,OAAO80L,UAAiB90L,OAAepK,QAAQc,QAAQ+C,SAASmoB,MAAcikG,WAE9E3kG,EAAK4tnB,YA9DU,IA+DlB,CAEDA,aAMI,MAAMC,EADaC,UAAqB,aAChBptmB,MAAM,SAE9BmtmB,EAAME,QAAU,MAEfD,YAAuBD,GAAyB,EACpD,yCAlFQP,IAASpnjB,8EAATonjB,0DAXE,CACP,CACIpjhB,QAAS8jhB,MACTtX,SAAUoP,GACVx7gB,OAAO,IAEd5S,SAnFGu2hB,gBACAC,gBACAC,gBACAj3hB,gBACAk3hB,gBACAC,gBACAC,gBACAC,gBACAC,gBACAC,gBACAC,cAAqB,CACjBhmoB,QAAS,KACTimoB,cAAe,qBACfC,SAAU,IACVC,gBAAgB,IAEpBC,gBACAC,gBACAC,gBACAC,cACArhZ,GACAkJ,GACAs0L,GACA/yL,GACA29C,GACAsvV,GACAJ,GACAhuM,GACAg4M,MACAC,KACAp7M,GACAiD,GACA9xO,GACAm1a,GACAiK,GACAlnN,GACAmnN,GACAve,GACAkgB,GACAjvM,GACAmG,GACA+mM,GACAiL,MACA/K,GACAle,GACAie,GACAqB,GACA/jM,GACA64L,GACAzd,GACAspB,GACAzuU,GACA4oH,GACAw8L,GACAC,GACAooB,GACAlnM,GACAsnM,GACAI,GACA/f,GACA+e,GACAwI,GACA30V,GACA42V,MACArI,GACA9pN,GACAqpM,GACA0gB,GACAvhB,GACAnG,GACAkG,GACAla,GACAy4B,MC9JD,MAAMl4jB,gBACG,ECmBT,MAAMwjkB,GAQTn4hB,yBACI,MAAMr0G,EAAS,IAAIwsoB,GACnBxsoB,EAAOukE,eAAiByE,eACxBhpE,EAAOujH,mBAAqBvjH,EAAOukE,cAAgB,QAAU,OAC7D,MAAMkokB,EAAW,qCAAqCnxhB,KAAKt/G,OAAOse,SAAS5P,MAC3E,OAAI+hoB,GAA0C,8BAA9BA,EAAS,GAAG5noB,cACxB7E,EAAOujH,mBA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O,GAAG1O,OAAOse,SAASkznB,WAAWD,IAAiBvxoB,OAAOse,SAASwmG,QAgBlG,IAAK+rhB,GAAa,EACd,SAAmBF,GAAU/6oB,SAE7B,MAAMoO,EAASwsoB,qBACfG,GAAUrokB,0BAA4BtkE,EAEjCA,EAAOukE,kBACRygC,oBAKJsqF,SAAyB,CAAE,sBAAwBqD,GAA4BA,EAAY86c,mBAE3FC,OAAyBC,gBAAgBnD,IAAWj5oB,KAAMq8oB,IAEtD5xoB,OAAO4xoB,aAAkB5xoB,OAAO4xoB,YAAer4hB,UAC/Cv5G,OAAO4xoB,YAAiB,KAGxB,MAAMhlC,EAAyBglC,EAAY/rhB,SAASxwH,IAAIw8oB,YAAUjlC,WAQ3CglC,EAAY/rhB,SAASxwH,IAAI2zG,UACzCogC,IANP,SAAS0ogB,IACLllC,EAAWh3b,SACXg3b,EAAW/mc,MACf,EAGwB,qBCrFhC,OACA,aACA,gBACA,aACA,gBACA,mBACA,gBACA,mBACA,gBACA,mBACA,gBACA,mBACA,gBACA,mBACA,cACA,iBACA,gBACA,mBACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,mBACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,YACA,eACA,aACA,gBACA,YACA,eACA,aACA,gBACA,mBACA,gBACA,mBACA,gBACA,aACA,gBACA,aACA,gBACA,gBACA,mBACA,gBACA,mBACA,gBACA,mBACA,gBACA,mBACA,gBACA,mBACA,gBACA,mBACA,gBACA,mBACA,gBACA,mBACA,aACA,gBACA,aACA,gBACA,mBACA,gBACA,mBACA,gBACA,mBACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,cACA,iBACA,aACA,gBACA,aACA,gBACA,mBACA,gBACA,mBACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,YACA,eACA,mBACA,sBACA,kBACA,qBACA,YACA,eACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,gBACA,mBACA,aACA,gBACA,aACA,gBACA,aACA,eACA,kBACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,YACA,eACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,iBACA,oBACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,mBACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,mBACA,gBACA,aACA,gBACA,iBACA,oBACA,gBACA,mBACA,aACA,gBACA,aACA,gBACA,mBACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,iBACA,oBACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,cACA,iBACA,aACA,gBACA,aACA,gBACA,aACA,gBACA,gBACA,mBACA,cACA,iBACA,aACA,gBACA,aACA,gBACA,cACA,mBACA,sBACA,iBACA,gBACA,mBACA,aACA,gBACA,aACA,gBACA,YACA,kBACA,qBACA,eACA,aACA,gBACA,mBACA,sBACA,YACA,eACA,gBACA,mBACA,gBACA,mBACA,eACA,kBACA,gBACA,oBAIA,cACA,WACA,WACA,CACA,cACA,cACA,8CACA,gCACAzrK,CACA,CACA,WACA,CACA23oB,kBACA,qBACA,EACAA,YACAl8oB,YACAk8oB","names":["APP_SOURCE","AuthenticationService","sdLogger","sdHttp","accountService","$rootScope","getUserInfo","_getUserInfo","get","SERVICE_URL","then","response","log","ensureUserHasAccessToPriorInstanceSelection","$emit","angular","module","factory","$inject","Directive","userService","restrict","scope","showCurrent","form","passwords","alreadyUsed","templateUrl","link","element","passwordRegEx","username","clearCurrentValidation","current","$setValidity","clearNewValidation","new","checkAlreadyUsed","validity","activate","user","getUser","directive","Service","getByStateId","stateId","getBySiteId","id","url","getCollectorsByState","getCollectorsByAssessor","assessorId","params","assessorid","getCompanyCollectorVendorCodes","companyID","getAll","createCollectorVendorCode","vendorCode","post","updateCollectorVendorCode","put","deleteCollectorVendorCode","delete","loadPdfIframeService","fileUrl","fileMtype","readOnly","template","$watch","newUrl","objectElem","existingIframe","find","length","empty","document","createElement","initializePdfJs","append","updatePdfJs","xhr","XMLHttpRequest","console","open","responseType","onload","e","this","status","myBlob","reader","FileReader","loadEndEvent","attr","textContent","result","readAsText","send","split","Controller","weissNg1WrapFunc","ng1ControllerInit","arguments","parcelService","$stateParams","activityService","$uibModal","$q","productAnalyticsService","vm","getDataByYear","_x2","useLatestActualized","fromUserChange","loading","logEvent","viewSitePortfolioAnalysis","processData","parcelId","getDataByParcel","siteId","selectedYear","parcelFilterList","apply","activityData","availableYears","parcels","_","map","extend","isIncluded","annualData","propertyCharacteristics","noDataYet","openParcelFilter","updateParcelFilterCacheForSite","getSummaryColumnClass","getGraphColumnClass","parcelFilterSub","storedParcelFilterList","sessionStorage","JSON","parse","userSessionFilterCache$","subscribe","cache","cachedFilters","isEqual","getYears","defer","parcelYears","resolve","getAvailableYears","promise","maxYear","maxBy","year","filter","x","activityStatus","parcelID","$onDestroy","unsubscribe","bindToController","controller","controllerAs","getStatuses","activitySummaryTableDirective","ActivityPanelModes","appealStatus","getPropertyChracteristics","acres","propCharacteristics","label","impsSqFt","units","currentYear","totalFMV","window","Math","round","fmvProjected","some","fmvByPropertyType","isProjected","recentSavings","item","taxSavings","savings","ex","totalTaxes","reduce","collectorTaxes","sum","n","Decimal","plus","tax","toNumber","taxProjected","getAppealsStatusLabel","updateChartType","chartType","$broadcast","replace","isModal","onRow","deadlineDate","section","sortVal","date","Date","getTime","deadlineType","getDeadlineLabel","type","setPopoverContent","popoverContent","data","getValue","chain","omit","values","compact","value","getPlacement","index","filterSections","i","floor","changeRow","getDeadlineData","footerSections","openModal","component","$uibModalInstance","closeModal","dismiss","size","windowTopClass","windowClass","backdropClass","config","ws_analysisGraphChartSelection","activityMode","reflowChart","Highcharts","fireEvent","analyticsEvent","selection","lastConfig","graphConfig","createGraphConfig","$on","event","newValue","oldValue","sdActivityTableDirective","$filter","PropCharNames","formatData","originalConfig","convertedConfig","series","xAxis","loadedAllYears","showingAllYears","getCellValue","seriesItem","symbol","fractionSize","xAxisCategoryIndex","categories","indexOf","val","y","getTotalForSingleYear","forEach","key","originalValue","isProjectedFmvForSingleYear","getTotalFmvByPropValueForSingleYear","propCharName","totalFmv","SQFT","landFMVPerSqFt","landFMVPerAcre","findIndex","o","dividedBy","parseFloat","ACREAGE","getTotalColumnTitle","totalFMVPerSqFt","totalFMVPerUnit","showColumn","arrayOfAllowedModes","UNITS","k","getColumnTitle","getFooterTitle","getPropCharValue","calculateLandSqFt","landAcreage","loadAllYears","getDataByParcelAllYears","getDataForAllYears","getPrecision","fieldName","getAppealCellValue","annualYearIndex","fieldValue","isFinite","updated","targetElement","drawChart","chart","input","trim","toLowerCase","filtered","push","DEFAULT_TITLE","Factory","$log","toastr","trace","error","title","message","isEnabled","info","success","warning","timeOut","sdModalService","cancel","dirty","confirmMessage","confirm","restrictService","showRoles","enableRoles","showSites","enableSites","showCompanies","enableCompanies","flags","processingService","$timeout","getResults","pageNumber","results","ceil","itemsPerPage","resultsObj","search","criteria","resultTypes","showCriteria","concat","resultClicked","executeSearch","resultType","resultId","entityID","entityDetails","entityTypeId","entityId","copy","loadExtraFilters","fieldsToReject","extraFilters","activeFilters","reject","includes","field","sdQuickResults","$http","appStateService","timestampCheckPromise","appState","appState$","s","cacheBuster","now","method","makeRequest","deleteHttp","patch","deleteByEntity","headers","initializeTimestampCheck","checkPromise","appStates","LoggedOut","catch","upgradeNavigationService","$state","$uibModalStack","transitionTo","newState","options","getQuerystringParam","parameterName","getCurrentState","go","stateName","dismissAll","goWithReload","reload","getHrefFromState","href","absolute","goToAnnualDetailsTax","siteID","annualYearID","billClusterID","companyId","goToAnnualDetailsAssessment","assessmentID","annualAssessmentID","goToAnnualDetailsAppeal","appealID","goToAnnualDetailsRefund","refundID","goToAnnualDetailsFiling","filingId","goToFilingBatch","filingBatchId","PropertyTypes","service","cached_value","getPropTypesFromServer","orderBy","gettingDataFromServerNow","getById","propertyTypeID","broadcast","name","args","sdStateDropdown","statesService","StateDropdownController","states","getName","state","stateID","assignValue","loadStates","getSummary","filterByCountryId","countryID","useFullName","fullName","abbr","sortBy","includeAll","all","unshift","hasBlank","blankState","elementType","labelStyle","disabled","isOptional","changeFn","_enabled","toggle","toggleTracing","require","valueToNotMatch","attrs","ngModel","$validators","sdDoesNotMatch","modelValue","$validate","valueToMatch","sdMustMatch","ContactRoleAssociationService","baseUrl","add","addContactRoleAssociation","deleteContactRoleAssociation","openContactAssociationModal","_x","modalScope","$new","dialogParameters","modalConfig","roleService","EntityTypeIDs","_contacts","pageSize","contactId","getByIdScoped","update","contact","updateScoped","deleteContact","deleteContactScoped","getByEntity","entityType","showAll","create","openContactDialog","origin","contacts","entityInfo","roles","onTop","undefined","contactID","isVisible","availableRoles","getAvailableRolesForContactEntityCombinationAPI","someRoles","copyContactProperties","remove","instanceId","searchText","excludeInactive","searchFragment","encodeURIComponent","instanceFragment","searchScoped","searchForSignatureDelegates","getAvailableRoles","role","contactRoleAssociations","contactRoleID","getCached","addToCache","getForSetup","createUser","launchRecipientContactModal","paymentPackageId","recipientMode","PAYMENTPACKAGE","saveContactSignature","signatureBase64","dto","getContactSignature","userId","getForSetupScoped","searchRyan","getUserById","userid","c","r","entityName","firstName","lastName","address","phone","ext","mobilePhone","$scope","contactService","utils","userInstanceService","ContactModalOrigin","contactModalService","lastSearch","gettingDataForTheFirstTime","dialogMode","notAllowedRoles","filterValidationError","oldFilter","header","noMoreData","gettingContactRoles","isCurrentInstanceSystem","$parent","selectedContact","getEntityName","validateFilter","recipientTypes","ResponsibleParty","Cc","Bcc","searchContactsOnServer","excludeInactiveChanged","gettingMoreData","getSelectedInstance","appSource","finally","clearFilter","openCompanyPage","$close","allContacts","ContactsList","getAnyContactPhone","associateRole","selectedRole","closeDialog","selectedContacts","selected","closeRecipientDialog","recipientType","returnObject","recipients","selectContact","contactDto","checkForEnterKey","keyEvent","which","cancelContactAssignRole","Upload","authStorageService","sendBatchDocuments","files","getAuthData","upload","intakeInfo","stringify","file","getDocumentBody","getDocumentInfo","getDocumentInfoByTaskId","getTaskInfo","getTaskInfoByTaskID","mapDocumentToEntity","saveFile","blob","fileName","saveAs","navigator","webkitSaveBlob","mozSaveBlob","saveBlob","msSaveBlob","companyService","company","companyName","getCompanies","searchTerm","topLevelOnly","favoritesOnly","activeOnly","companySelected","checkForBlank","sdCompanyPicker","appendToBody","years","close","dialogData","escapeMode","legalDescription","reason","closed","editMode","preventDefault","weissNg1Wrap","assessorCollectorService","entityTypeID","EntityTypeNames","navigationService","billClusterService","navigate","ASSESSOR","getNavigationInfo","assessorID","location","COLLECTOR","stateCollectorId","collectorID","INVOICE","route","invoiceID","FilingBatch","BILL_CLUSTER","getBillClusterByID","billCluster","TAX_BILL","bills","billID","getEntityTree","tree","transitionState","subsidiaryCompany","site","SITE","PARCEL","parcel","ASSESSMENT","annualYear","revision","APPEAL","appeal","PAYMENT","REFUND","refund","FILING","filing","Error","siteService","entity","Number","typeId","newAllowed","$transitions","initializeNavService","onStart","onNavStart","$onInit","init","_this","$location","$window","showNavbar","fullScreen","itemName","itemType","subject","substr","absUrl","body","showApp","showMenu","loggedOut","showQuick","checkState","Initialized","LoggedIn","LoggingOut","applicationPermissionService","cancelAddPermission","permissionToAdd","availablePermissionRights","availablePermissions","ap","screenTypeID","userData","globalRoles","uniqueScreenTypes","screenTypePermissions","selectPermissionToAdd","addPermission","permission","screenType","getScreenType","assignedPermissions","usablePermission","roleHasAlreadyAssigned","userGlobalRoles","rolesWithSameScreenType","userHasRoleWithScreenType","screenTypeSelected","minBy","deletePermission","getPermissionLabel","roleID","permissionLookup","rights","userHasGlobalRole","cloneDeep","uniqBy","sdApplicationPermissionsPanel","userSetup","accountUserService","companyPermissionService","$interval","intervalRef","OPT_HIDE","OPT_VIEW_ALL","OPT_VIEW_EDIT_SOME","OPT_EDIT_ALL","EF_ACTION_ADD","EF_ACTION_DELETE","isActivated","_loadPermissions","getPermissionsPromise","groupId","getForGroup","companyNameFilter","getForUser","isBusy","permissions","displayPermissionIds","matchedModifiedPermissions","matchedModifiedPermissionIds","unmatchedDisplayPermissions","newPermissionPage","_setPermissionsValues","p","writeAllowed","readAllowed","includeAllChildRecords","displayPermissions","efAction","hasLoadedAllPermissions","companyNameFilterChanged","loadPermissions","showAdd","_showAdd","rejectableOpen","modifiedEntityIds","newPermission","companies","COMPANY","sites","Permission","Name","sitePermission","groupID","_showSites","companyPermission","existingAssignedPermission","existingDisplayPermission","permissionID","companiesOnly","changePermission","updateAction","_changeAllowedFlags","newVal","oldVal","pop","compactMode","modalService","PAGE_SIZE","loadCompanies","getCompaniesThatAreMissingPermissionsForGroup","getCompaniesThatAreMissingPermissionsForUser","newCompaniesPage","selectedCompanies","hasLoadedAllCompanies","PermissionTypes","selectedPermissionType","toggleCompanySelection","$dirty","save","isNewUserBeingCreated","siteListService","getDataFromServer","principalId","SitePermissionTypes","Permission_EDIT","Permission_VIEW","Permission_HIDE","union","sitesToSave","parseInt","GET_DATA_FOR_USER_URL","GET_DATA_FOR_GROUP_URL","getAllForCompany","isGroup","format","has","featureFlagsService","rightHasAlreadyAssigned","userInstanceRights","instanceRights","rightsWithSameScreenType","userHasRightWithScreenTypeInThisInstance","rightsID","permissionsLookup","userHasInstanceRight","hasInstanceRight","featureFlags","rightSelected","instanceRightID","sdInstancePermissionPanel","permissionOptions","selectedDefaultPermissions","userGroup","grantWriteToNewCompanies","grantReadToNewCompanies","permissionChanged","sdUserGroupsNameInfo","userGroupService","Roles","cancelAddUserGroup","userGroupToAdd","availableGroups","hasUsersEdit","hasUsersViewOrEdit","selectUserGroupToAdd","addUserGroup","foundAssignedGroup","assignedGroups","deleteUserGroup","group","assignedUserGroups","groupInAssignedGroups","editUserGroup","user_group","read_only","edit_mode","newParcel","nonDeletedFilter","sdUserGroupsPanel","DocumentProcessingController","$sce","documentService","attachmentService","popUpService","DocumentExceptionActions","messageBoxService","MessageBoxButtons","MessageBoxResult","ProcessingExceptionStatusText","actionViewPersistenceService","taxRateSetupModalLaunchService","RyanInstanceId","busyIndicatorService","completedItemCount","newDocumentTypeID","navigateWarning","cleanParcelData","ExceptionStatusIDs","initializing","showOverlay","isDirty","warnOnEntityReload","validationMessage","dismissModalValidationOpen","saveEntityValidationOpen","completeValidationOpen","loadingRevisionData","searchTimestamp","isQCItem","editModeEntityPanel","addressPopoverData","isPopoutDynamic","hasIdpFeature","ryanInstanceId","warnOnEntityReloadChanged","forceReloadEntity","includeParcel","originalSelectedEntity","selectedEntity","currentRow","intakeDocumentInfo","parcelChanges","originalDataEntryObject","dataEntryJSONHandler","retrieveDataEntryJSON","resetOnLoad","intakeItem","entryJSON","wasOriginallyChanged","associatedEntityChanged","setTimeout","setDirty","reloadEntity","buttons","OKCancel","OK","onFirstEncounterSaved","updateVersion","validationHandler","validate","enableNavWarning","disableNavWarning","getDocumentTypeList","getAttachmentTypes","documentTypeList","currentRowIndex","entityIsMapped","associatedEntityMissing","completeButtonLabel","enableIdp","getCriteria","getResultTypes","rows","selectedRows","busyRef","show","taskID","initializeByTaskID","taskInfo","initializeRows","hide","intakeItemID","initializeByIntakeItemID","logPinTip","attachmentClosingEvent","globalAttachmentsPopUpRef","getByAliasGroup","StaticAliases","Attachment","notifyChildWindow","checkValidationFunction","validator","callback","row","n10908","popUpRef","isOpen","popUpData","attachmentInfo","attachmentID","attachmentMetaData","fileExtension","publish","Topics","AttachmentChanged","disableEntryButtons","extendedData","propertyTypeAbbr","propTypeAbbr","getRowData","n10902","maybeMapOCRValues","documentTypeChanged","Promise","taxBillOcrResults","assign","getCriteriaWithIdp","assessmentNoticeOcrResults","idpConfidence","anticipated","primaryAcctNumOnly","rowIndex","displayNow","fileError","loadAttachment","fileInfo","getMimeTypeByFileExtension","previewSupported","attachmentBlob","Blob","attachmentBlobUrl","URL","createObjectURL","attachmentUrl","trustAsResourceUrl","checkForChangesInParcel","isOverridden","onSkipClick","_asyncToGenerator","disableSkip","openNextDocument","routeParams","popoutPreview","isDynamic","openAttachmentPreview","openDismissModal","isValid","dataEntryJSON","exceptionData","selectedRow","optionalArgs","isTaxBill","f9003","intakeBatch","modalResult","rowVersion","intakeItemRowVersion","actionType","CLEAR_EXCEPTION","exceptionStatusID","REQUEST_TAX_RATE_SETUPS","downloadAttachment","docInfo","downloadAttachmentByGuid","loadQuickSearch","saveEntityDetails","documentIntakeID","saveItemEntity","completeTask","eventString","completeItem","attachmentType","attachmentTypeID","documentType","getResultTypesByDocumentType","foundResultType","defaultResultsEntityTypeID","getCommentsModalData","INTAKE_ITEM","description","getIntakeBatchItemNumber","canEdit","batchNumber","itemNumber","duplicateNumber","launchDuplicateModal","duplicateItem","duplicateCount","launchDuplicateIntakeItemModal","newItems","newIndex","splice","billRevisionChanged","fmv","av","annualGridComponents","assessmentComponentTypeID","fairMarketValue","assessedValue","revisionInfo","totalAssessedValue","showLegalDescriptionDialog","keyboard","modalFade","acctNum","parcelAcctNum","parcelLegalDescription","isSubEntity","editEntityPanel","pick","parcelAddress","parcelState","cancelChanges","isAddress","newTaxSetup","openTaxSetupModal","openDocumentProcessingParcelTaxSetupModal","parcelCollectorID","parcelCollectorRowVersion","collector","text","next","savingCriteria","DpSearchCriteria","currentDocument","currentIntakeItemID","includeIntakeItemData","anticipatedAttachmentTypeID","attachmentTypeId","saveCriteria","refreshCriteria","sdDocumentProcessingSearch","DocumentProcessingExceptionModalController","ProcessingExceptionStatus","teamsService","disableBounceRejected","disableClearException","reassign","escalate","request","taxRateSetups","multipleTasks","taskIDs","hasExceptionStatus","rejectedByUser","contactUser","clientInstanceId","extraData","getBulkDocumentExceptionData","showBounceRejectedOption","showClearExceptionOption","rejectorLastName","rejectorFirstName","contactLastName","contactFirstName","userID","contactUserId","teamID","contactTeamId","rejectedByUserID","REJECTED","getAssignableUserTeams","userTeams","ut","isDefault","contactTeam","isRyanInstanceSelected","showRequestTaxRateSetups","saveShared","processDocumentBulkException","documentExceptionAction","newAssignment","getNewAssignment","commentBody","processDocumentException","addressFields","REASSIGN_ITEM","ESCALATE_ITEM","REQUEST_RESEARCH","REJECT_ITEM","BOUNCE_REJECTED","parentCallsService","createComment","isEmpty","assignee","CLOSE_ITEM","DuplicateIntakeItemModalController","isBulk","isLoading","duplicate","resetCopyNumber","checkCopyNumber","toString","newCount","substring","createDuplicateIntakeItemBulk","createDuplicateIntakeItem","FilePreviewController","pubSubService","navbarTopService","_pubSubSubscriptions","attachmentFileName","attachmentFileExtension","subscription","$apply","publishParent","PreviewInitialized","classList","DUPLICATE_SERVICE_URL","quickFilters","searchService","userSettingsService","getSavedCriteria","getDefaultCriteria","ocrResults","savedCriteria","saved","ocrFields","analyticsOcrFields","isIdpSearch","idpResults","accessObj","path","object","OcrField","criteriaSetting","groupName","folderId","folderName","existingCriteriaSettings","getSettingsByGroup","setting","numberToGet","queryParams","resultsAs","anticipatedItemsOnly","query","QUICK_SEARCH_SERVICE_URL","documentID","documentTaskProcessingEndpoint","associatedEntity","actionID","documentTaskExceptionEndpoint","processedEntityDetails","exceptionDataObj","payload","extended","entityTreeEndpoint","capitalize","allowAtTaxBill","allowAtTaxPayment","allowAtPPReturn","duplicateItemInfo","processNoAppealWarranted","processAppealWarranted","completeFileAppeal","getAppealLevels","changeDueDate","dueDate","processPaymentReviewed","taskIds","performOCR","getDocumentActive","inactiveFilters","getDocumentInactive","CompleteFileAppealModalController","taskService","validateAssessorStateReqs","filingReference","process","BrowseColumnsModalController","columnsToExclude","advancedSearchService","taskSeriesTypeId","clearSelection","allColumns","getAllColumns","columnCategories","column","toAdd","columnsToAdd","addColumns","allColumnsDisabled","category","disableAllColumns","columns","every","toggleCategory","getFilteredColumnCategories","selectedCount","categoryID","subcategories","subcategory","disableColumns","sdColumnCheckboxes","rejectExcluded","columnId","advancedSearchFieldID","columnIdFound","idFound","advancedSearchFieldIdFound","columnToAdd","columnSelected","$item","columnSelectedFn","selectedColumns","filterFromExclude","openBrowseModal","backdrop","taskSeriesTypeAdvancedSearchDepthValue","getColumns","includeTaskColumns","cpMode","disableColumnsAfterLoad","sdColumnPicker","quickFiltersService","resetCriteria","msg","clearForm","loadSavedCriteria","navigatingFrom","fromEnterKey","quickSearchWidget","filters","otherNonDefaultCriteria","resultsDropDown","siteName","siteAssessor","siteStateAbbr","initiateQuickSearch","setCriteria","addOrUpdateFilter","filterTextValue","idx","registerReset","currentCompany","includeSubsidiarySites","stateField","companyField","companyIDField","allFilters","stateFilter","companyFilter","companyIDFilter","reset","resetCriteriaToDefault","excludeSubsidiarySites","CriteriaDirective","StatesService","propertyTypeService","propertyTypes","SectionController","hotkeys","advancedSearchPersistenceService","nubService","criteriaChangedListenerVisibility","setShowCriteria","setShowResults","openQuickSearchListener","resetSearch","resetCriteriaList","resetActiveFilterValues","showSearch","focusOnFilter","toggleSearchVisibility","tabClicked","stopPropagation","active","showResults","clickedOnResultIndex","getClickedOnResultIndex","focusOnResult","focusOnElement","setShowTab","bindHotKeys","unbindHotKeys","del","bool","toggleCriteriaVisibility","clearCriteria","showQuickSearchNub","hideNub","combo","allowIn","toggleSearch","showTab","toggleCriteria","toggleResults","toggleResultsVisibility","resetClicked","saveSearch","userSettings","getSettings","advancedSearchData","actionViewData","registerQuickSearch","registerCriteriaChanged","showQuickSearch$","ResultExtra","isDescriptor","descriptors","resultField","getDescriptors","pickBy","getResultField","parcelAddress1","parcelAddress2","siteAddress1","siteAddress2","parcelAssessorAbbr","parcelAssessorMunicipality","siteAssessorAbbr","siteAssessorMunicipality","newResults","criteriaChangedListenerInfinite","allowToShowSpinner","resetResults","caller","searchElastic","urlToNavTo","getResultUrl","setClickedOnResultIndex","quickSearchInitiator","quickSearchResult","closeSearch","refreshResults","pgDn","focused","lastIndex","pgUp","hoverIn","ResultDirective","$compile","childEntity","types","getPropType","acctNums","keyArr","number","actionListOutput","outputColumns","searchOperators","setSequence","sequence","showClose","addOutputs","addedColumns","addedColumn","operators","getOperatorArray","or","getCompanyOr","getOr","removeOutput","columnMoved","actionViewService","ActionViewGroupByTypes","ActionViewCategoryTypes","ActionViewOrganizeByTypes","searchFilter","organizeBy","drilldownFilter","drilldownMode","showDetail","showOverview","groupBy","taskAssignmentApi","showMostPressing","pageLoading","allFields","taskData","originalSearchFilter","filterChanged","getTableData","getColumnStyleClass","columnSequence","tableType","getTableSpacingClass","groupByCount","drilldownCellNoGroup","taskSeries","readiness","setTask","taskSeriesTypeID","taskTypeID","setFilterFromOrganizeBy","setReadiness","loadDetailView","externalDrilldown","masterFilter","newFilter","resolveTasksAndFieldsDeferred","externalDrilldownData","task","ready","taskTypeChanged","getAllFields","overviewResults","OrganizeBy","headerNames","overviewHeaders","organizeTotals","grandTotals","actionViewId","actionViewType","SYSTEM","getSystemActionViewById","setupResponseData","getCustomActionViewById","setGroupByFromMostPressingTasks","DetailedResults","executeActionView","sql","orderedHeaders","resultsDataTable","groupedTasks","group1ResultList","orgLabelIdx","notReady","totals","GroupBy","forOwn","secondaryGrouping","secondaryValue","secondaryKey","thirdGrouping","newCriteria","TASKTYPE","ThatAreChoice","mostPressingNotReadyOnly","persistCustomColumns","separatedColumns","setOutputs","TaskOutputColumns","prepareOutputColumn","EntityOutputColumns","setTaskOrEntity","ShowMostPressingTasks","setFilterFromGroupBy","firstGroup","ASSIGNEENAME","ShowChoice","WhereChoice","AdditionalWhereFilters","whereChoice","ShowUserTeams","ShowTeams","team","ASSIGNEETEAM","RESPONSIBLENAME","RESPONSIBLETEAM","orObject","operator","resultColumnName","resultsColumnName","UseUrgencyFilter","UrgencyChoice","getUrgencyChoiceByHeaderName","OnlyUnscheduled","DateTimeChoice","IncludeUnscheduled","drilldownDates","getDrilldownDueDates","drilldownLastActivity","getDrilldownLastActivity","UseLastActivityFilter","headerDueDates","calcHeaderDueDates","dateToNoOffset","moment","subtract","toDate","DueDateFrom","DueDateTo","getTimezoneOffset","todayNoOffset","startOf","dateFromNoOffset","plusDate","fromDate","dueWithinDate","DueWithinDays","min","max","headerLastActivity","calcHeaderLastActivity","LastActivityFrom","LastActivityTo","fromDays","toDays","mostPressing","readyOrNotReady","showTotals","CalculateReadyAndNotReady","drilldownColumn","list","twoGroups","drilldownColumnTotal","drilldownTaskSeriesType","drilldownRowNoGroup","drilldownRowOneGroup","drilldownCellOneGroup","drilldownRowFirstGroup","drilldownRowSecondGroup","secondGroup","drilldownCellTwoGroups","drilldownGrandTotal","URGENCY","urgencyChoice","DUEDATE","drilldownDueDates","LASTACTIVITYDATE","self","filterColumns","detailResults","resultsChanged","selectedResult","actionViewName","showOrs","organizeBySelection","sort","columnState","clearSavedData","columnFilterService","cacheManagerService","TaskSeriesTypes","longRunningProcessRepository","snackBarService","SERVICE_URL_CUSTOM_ACTION_VIEW","SERVICE_URL_SYSTEM_ACTION_VIEW","SERVICE_URL_CATEGORIES","SERVICE_URL_FAVORITE","SERVICE_URL_ACTION_VIEW_REVOKE_SHARE","cacheManager","createCacheManager","registerKeyedStaticCache","cacheKey","endpoint","cacheDisabled","deleteCustomActionView","actionView","deleteSystemActionView","actionViewItem","actionViewID","CUSTOM","getCategories","deleteCategory","categoryId","createCategory","changeCategory","actionViewURL","categoryItem","reorder","categoryList","SERVICE_URL_CUSTOM_CATEGORIES","toggleFavorite","toggleValue","hasFavorites","getTaskTypes","keyedStaticGet","taskTypes","isInRyanInstance","hasRyanPrivate","isInRole","RYANPRIVATEITEMSVIEW","RYANPRIVATEITEMSEDIT","hasInstancePrivatePermission","hasAnyInstancePrivate","CLIENTINVOICE","DOCUMENTINTAKE","getTasksAssignmentReadyOptions","mapThatAreChoiceToDisplayValue","thatAreOptions","display","getUrgencies","createCustomActionView","saveActionViewItem","prepareActionViewForSave","createSystemActionView","updateCustomActionView","updateSystemActionView","canceler","isCancelled","savedSearchID","timeout","call","fixAPISearchRequest","processSearchResultPlusRequest","welcomeSearch","viewMode","searchResults","executeActionViewToExcel","outputInt","outputFormat","outputType","lrpId","addById","cancelAvSearch","prepareActionViewForExecution","filterToExecute","mapValues","isArray","obj","isObject","prepareFilters","sortTaskTypes","getFavoriteCount","revokeShare","share","getUrgencyColumnStyleClass","urgencies","urgency","warn","launchCustomOutputModal","clickedTaskType","taskTypeColumns","userSetting","customTaskTypes","fromJson","customTaskType","taskType","fromActionView","taskTypeName","selectedTaskType","systemColumns","columnIds","userColumns","fullColumn","fullColumns","columnsToSave","propsWithBadCasing","output","newProp","oldProp","lookup","columnReferenceLookup","originalRequest","entityOutputColumns","taskOutputColumns","showOptions","myTasks","myTeamsTasks","isSingleInstanceSelected","individualsTasks","teamsTasks","allTasks","whereOptions","includeOptions","isSave","prepareCriteriaForSave","returnCriteria","actionViewSortingDropdowns","groupBySelection","groupBySelectionSecondary","calculateGroupByOptions","groupByOptions","canGroupTaskActionView","displayName","organizeByItems","changeOrganizeSelect","actionViewOrganizeBy","changeGroupSelect","actionViewGroupBy","filterChange","eventName","FiltersOutputsController","plainEnglishService","ActionViewDisplayTypes","userSaveService","searchSaved","agreeToRunLongRunningQuery","isTaskTypeAll","isShowAll","isDateRangeMoreThanWeek","diff","isLongRunningQuery","hasAnyFiltersPopulated","deferred","goToOverview","invalidFilters","initiateSequenceEvent","displayType","originalFilter","showFilterPage","goToDetail","setOrganizeAndGroupOptions","IncludeChoice","IncludeUserTeams","IncludeTeams","CompletedChoice","CompletedWithinDays","setDisplayType","FILTER","OVERVIEW","DETAILED","waitForApi","numTries","dataLoaded","invalidColumns","getPlainEnglish","getForFilter","saveSearchAs","actionViewObj","hasEditPermission","updateList","isSystemView","areNoOrs","orArr","backToOverviewClick","shouldCancelSearch","overviewLoading","detailedResults","hideSaveButton","isOwnedByUser","reloadActionView","inherit","favoriteSearchToggle","isFavorite","showFilter","logSequenceEvent","checkActionViewDefaultOutput","checkDefaultResult","thatAreCompleted","hideRevokeActionViewButton","isShared","revokeActionViewShare","actionViewSavedSearch","hasAnyFilters","customChosen","defaultChosen","populateColumns","updateColumnFilters","SYSTEMSEARCHESEDIT","allSearchFieldsLoaded","initializePageState","source","refreshData","convertDateStringsToDates","getInvalidColumns","ComposeDynamicSql","includeSkipped","isSavedSearch","isById","launchCustomOutput","changedFilters","filterColumnId","newFilterColumns","CustomOutput","CustomOutputModalController","isRemovable","defaultColumns","idProperty","useSystem","xorBy","col","dateTimePanel","dateHack","inputDate","origMoment","utc","dueDateFromOptions","minDate","maxDate","dueDateToOptions","completedDateFromOptions","CompletedDateTo","completedDateToOptions","CompletedDateFrom","dueDateFromChanged","initDate","dueDateToChanged","completedDateFromChanged","completedDateToChanged","includeUnscheduledChanged","includeUnscheduled","includeOnlyUnscheduledChanged","onlyUnscheduled","includeSkippedChanged","onlySkipped","validateLastActivityFrom","lastActivityFromTooltip","validateLastActivityTo","lastActivityToTooltip","whenOptionChanged","optionSelected","taskAssignmentDue","populateDueWithin","urgencyChanged","urgencyLevel","populateUrgency","lastActivityToggled","multiUserTeamPicker","userOnly","toBePickedArray","teamOnly","includeInactiveContacts","addItem","removeItem","str","getShowText","getUserTeamText","userTeam","getTeamText","teams","getTaskTypeText","getWhereText","getThatAreText","getIncludeText","includeUserTeams","includeTeams","getCompletedDateText","getDateText","isAfter","isBefore","getUrgencyText","isNumber","getLastActivity","columnsWithValue","getFilterText","displayNameMap","lowerFirst","isDate","taskAssignmentReadyPanel","api","authenticationService","InstanceRights","TaskTypes","userInstances","getUserInstanceMembership","hasPermission","PRIVATEITEMSVIEW","userInfo","isTeamMemberAndAssignable","taskTypeResult","isCurrentInstanceRyan","invoiceAppealSavingsTaskIndex","INVOICEAPPEALSAVINGS","fieldsResult","prepareCriteriaFromLoad","taskTypeItem","taskTypeIdChanged","matchingFilter","loadColumns","currentTaskType","prepCustom","columnFromAllFields","columnType","prepSystem","ids","fromTaskType","foundColumn","newColumn","fuzzyFieldCompare","field1","field2","filterColumnUpdate","defaultMasterFilter","missingEntityOutputColumns","defaultEntityOutputColumn","currentOutputColumn","missingOutputColumn","extraEntityOutputColumns","extraEntityOutputColumn","hasNonEmptyExistingFilter","existingFilters","filterColumn","existingFilter","blankFilterForThisColumn","entityOutputColumn","resolveDefaultOutput","depthValue","showOptionChanged","taskAssignment","Object","whereOptionChanged","taskAssignmentType","thatAreChanged","taskAssignmentStatus","canViewWhere","option","canViewInclude","logTaskTypeEvent","actionViewTask","OutputDefaultsController","launchModal","sdTaskSeriesArrows","manyToOne","chevronWidth","padding","manyLength","startingPos","lineWidth","extraSeries","range","sdTaskSeries","TaskActionTypes","instanceRepository","taskGroup","updateData","popoverLeftOrRight","waitingOnServer","svg","node","enteringNode","completeNode","currentNode","completeText","completeChevron","completeCheck","completeDate","heights","currentChevronPos","chevronDivot","verticalOffset","completeChevronHeight","updateTaskGroup","maxHeight","height","tasks","transition","selectAll","d","appendEnteringNodeElements","enter","style","temp","transform","getHeight","updateChevrons","chevron","select","specificChevronHeight","d3","line","completedDateTime","isReady","on","hoveredTask","hideContextMenus","css","updateChevronText","each","wrap","assignedUser","assignedUserIsOverridden","assignedTeam","assignedTeamIsOverridden","isDeliverable","deliverableStr","dateFormatStr","INFORMALHEARING","FORMALHEARING","SUBMITEVIDENCE","deliverableName","taskAuthorizationInfo","systemCompletes","clickedNode","startSpinner","parentNode","updateAllTasks","stopSpinner","skipped","last","pointsTo","updateCompleteChevron","lastTaskCompletedDateTime","strokeColor","tz","exit","duration","revertCurrentNode","editingTask","textLength","getComputedTextLength","paddingMultiplyer","slice","splitIntoGroups","userPicked","updateTask","instanceIdUserFilter","initSvg","defineBoxShadow","feMerge","initCompleteChevron","completeChevronPath","removeAttr","getContextOptions","deleteTaskMenu","reassignTaskMenu","rescindTaskMenu","skipTaskMenu","rightClickMenuItems","deleteTask","reassignTask","launchUserTeamPicker","currentIndex","getEntityInstanceId","toPromise","isInstanceImplicit","scopeInstanceId","extraHeight","words","picker","teamPickerDiv","delay","rescindTask","skipTask","t","systemDeletes","systemReassigns","systemRescinds","systemSkips","getInsertOptions","insertBefore","insertTaskBefore","newTaskTypeID","insertTask","INSERTNEWBEFORETHISTASK","insertAfter","insertTaskAfter","INSERTNEWAFTERTHISTASK","getLocalTimezone","guess","taskModalsService","getTaskSummaryByEntity","checkIfEntityMayBeDeactivated","launchTaskModal","readonly","toastMessage","editonly","loadingModal","animation","targetTasks","taskGroupsBySequence","tasksWide","getMaxTasksWide","modalSize","modalInstance","reloadRequired","taskUpdateListener","rendered","taskProcessRequestDTO","RESCINDTASK","REASSIGNTASK","assignedUserID","assignedTeamID","DELETETASK","SKIPTASK","getTaskPermissions","changeContacts","reassignMany","reassignObj","skipMany","completeMany","showErrorNotificationModal","errors","warnings","errorMessage","warningMessage","COMPLETETASK","taskGroupCollection","taskGroups","idSequencer","taskGroupArr","compileThing","firstTask","newGroup","nextTask","otherTasksThatPointToIt","flatten","taskSeriesIds","TasksModalController","getTaskGroupHeights","maxDueDate","chevronPadding","taskSeriesPadding","ErrorNotificationModalController","topLevelMessage","ReassignTaskModalController","ReassignModes","reassignMode","enableMultiUserPermissionsCheck","entityIdsMultiselect","Default","reassignRequest","ChangeContact","changeRequest","teamId","sdTeamAssignmentPanel","cleanAssignedTeams","MANAGEUSERSETUP","processAssignedTeams","getAllContactUserTeams","getFullInfo","includeCompanyRepresentative","getAllTeamsForContact","allTeams","assignedTeams","originalDefault","unaddedTeams","newTeam","newTeamForTasks","isEditMode","addTeam","deletedTeamIdx","addedTeam","isAssignable","teamName","numberOfClientServiceResponsibilities","newTeamID","addNewTeam","updateDefault","checkLinkedEntities","hasLinkedEntities","chooseNew","chooseNewTeam","editedTeam","chosenTeam","isLocked","cancelChooseNewTeam","addedTeams","removeTeam","teamsToSave","strippedTeam","cleanTeam","saveTeamAssignmentTab","isLrpRunning","isSaveDisabled","addTeamRow","switchToEditMode","targetScope","$dismiss","selectedTeam","formatInput","model","teamSelected","closeFn","filterTeam","changed","revertLabel","getAllTeams","sdTeamPicker","clickFn","pickerSm","appendToElement","isReassign","users","selectedUser","userSelected","filterUser","orderFn","getAllAssignableUsers","sdUserPicker","required","patchUsersWithAssignedUserIfMissing","foundUser","keys","filterUserTeam","clearData","getAssignableUsers","restrictToRyanInstance","getAllAssignableRyanUsers","entityIdScope","entityTypeScope","instanceIdScope","entityIdsMultiselectScope","sdUserTeamPicker","showClearButton","valueSetFromOutside","$animate","$element","$attrs","$observe","enabled","bind","$eval","sdEnter","sdSelectOnFocus","getSelection","setSelectionRange","elem","decimals","$parsers","viewValue","$formatters","compile","tElement","tAttrs","transclude","ngClick","iElement","iAttrs","toggleClass","waitingFor","marginTop","marginBottom","linkFn","cubeCount","Array","fill","messageBoxController","$document","hasOK","hasYes","hasNo","hasCancel","hasContinue","YesNoCancel","YesNo","focusButton","Cancel","focus","Continue","ok","yes","Yes","no","No","confirmYesNo","openedClass","isBackdropStatic","prefixes","getPrefixes","String","prototype","match","nonDeleted","currentEntity","getCurrentEntity","notNullorZero","getObjValByString","a","getEntityTypeAndId","stateParams","notEmpty","collectorId","findPropertyName","property_value","strict","getOwnPropertyNames","propertyName","array","removeArrayItem","arr","compareBySequence","b","showJsonUsingPopup","unDefaultOthers","newDefault","tempVal","thing","logIt","convertStringToDate","dateStringMatch","getDateValue","hasOwnProperty","isJson","momentVal","http","timestampCheck","res","rej","getTimestampCheckPromise","startCheck","ts","runtimeTimestamp","weissmanEnvironmentConfig","developerMode","weissmanBuildTimestamp","lastRefresh","StateUIRefreshTime","refreshRetryDelay","showBody","applicationPermissionsService","instanceRightsService","firstPass","SaveButtonText","Title","CompanyPermissions","ApplicationPermissions","availableInstanceRights","saving","appPermissionsChanged","siteOptions","userGroupToSave","prepareObject","instancePermissions","permissionDtoList","updateOrCreate","batch","userGroupObj","deleted","isGroupDirty","memberCount","deleteById","getCancelButtonText","getByGroupId","getAllByGroup","getAllByContactId","getInstanceContactId","getForMember","getList","pagenumber","pagesize","searchtext","isUserInGroup","groups","isInGroup","isUserSuperUser","userGuid","contactsService","userSetupService","instancePermissionService","CommentsModalService","userToRevertTo","emailPasswordReset","userName","_mapPermissions","cleanUpEFAction","entities","setUser","userToEdit","userToGroup","setupSSODropdown","getSSODomains","ssoDomains","domains","ssoDomain","newSSODomains","openAddCommentModal","allowBlank","setUserDescription","configuringSSO","newSSODomain","canEditUserInfo","canResetPassword","contactStatuses","inSupportInstance","showCreateLegacyUser","enableIAM","environment","showLoginManager","enableLoginManager","isLegacyUser","isLicensedUser","showActiveCheckbox","iamMigrationStatus","needTaxDotComPermission","editUser","$show","cancelEdit","$cancel","email","isIAMAdmin","isAdmin","editingUser","saveUser","userToSave","prepareUser","_editedPermissions","uniqWith","updateUser","resetRoles","lockoutEnabled","getUserData","cancelConfigureSSO","checkForSpaces","$setError","$invalid","showDescriptionDialog","getHomeInstanceName","currentHomeInstance","instanceName","goToLoginManager","SystemInstanceId","instanceID","isMigrated","getUserContactInviteStatuses","cs","instance","sdUserSetup","tabSelected","constant","READ","WRITE","READ_INCLUDE_ALL","WRITE_INCLUDE_ALL","DISABLED","ENABLED","DIAGNOSTIC","STATE","ANNUAL_YEAR","USER","CONTACT","ASSET","FORM","FORMREVISION","FACTORTABLE","FILINGBATCH","INTAKE_BATCH","TAXAUTHORITY","TAXRATEAREA","BUDGET","ACCOUNTINGPERIOD","ALLOCATION","PAYMENTBATCH","RE","propTypeName","PP","MN","CA","recentAppeals","ASSESSOREDIT","ASSESSORVIEW","COLLECTOREDIT","COLLECTORVIEW","COMMENTSEDIT","COMMENTSVIEW","COMPANYVIEW","CONTACTROLEVIEW","MANAGEAPIKEYS","PROPCHAREDIT","PROPCHARVIEW","STATEEDIT","STATEVIEW","USERSEDIT","USERSVIEW","COMPLIANCESETUPSVIEW","COMPLIANCESETUPSEDIT","ALLOWDATAIMPORTS","ADMINOPERATIONSVIEW","ADMINOPERATIONSEDIT","FORMSUNDERDEVELOPMENTVIEW","USERREPORTSALLOW","TAXRATESETUP","INSTANCEADMIN","SUPPORT","ALLOWMANAGESYSTEM","LICENSEDDOCUMENTSERVICES","ADDNEWCOMPANY","CONTACTVIEW","CONTACTEDIT","MANAGECONSULTINGENGAGEMENT","AGENTINFORMATIONEDIT","AGENTINFORMATIONVIEW","TEAMSETUPSVIEW","TEAMSETUPSEDIT","USERGROUPSEDIT","USERGROUPSVIEW","COMPLIANCEFEATURESVIEW","ALLOWMOVECOPY","COMPANYDATAIMPORTSVIEW","PRIVATEITEMSEDIT","VALUATIONTEMPLATEEDIT","VALUATIONTEMPLATEVIEW","INSTANCEDATAIMPORTS","ADD","DELETE","UPDATE","ENTITY_MAP","ATTACHMENTS_IMAGES","ATTACHMENTS_ALL_NONE","ATTACHMENTS_ALL_SOME","ATTACHMENTS_IMAGES_ICON","ATTACHMENTS_ALL_NONE_ICON","ATTACHMENTS_ALL_SOME_ICON","ADVANCED_SEARCH","QUICK_SEARCH","CRITERIA","RESULTS","VARCHAR","SMALLINT","INT","DECIMAL","MONEY","BIT","DATETIME2","PICKLIST","TEXT_ALIGN_LEFT","TEXT_ALIGN_RIGHT","TEXT_ALIGN_CENTER","NUMBER_0","NUMBER_1","NUMBER_2","NUMBER_3","NUMBER_0_NOGROUPING","CURRENCY_0","CURRENCY_2","PERCENT_0","PERCENT_1","PERCENT_2","PERCENT_3","PERCENT_4","PERCENT_5","PERCENT_6","YESNO","DATE","DATETIME","ATTACHMENTICONOPENPREVIEW","NA","ACCOUNT_HANDLER","JURISDICTION_SPECIALIST","CONSULTANT","GETINSERTOPTIONS","PPRETURN","ASMTAPPEALREVIEW","APPEALPURSUIT","TAXPAYMENT","MISCFILING","FREEPORTFILING","ABATEMENTFILING","POLLUTIONCONTROLFILING","ADD_COMMENT","ADDEDINERROR","ESCALATED","RESEARCHREQUESTED","ORIGINAL_TO_FINAL","FINAL","OTHER","NO_CHANGE","PAPER_TRANSMITTAL","DIGITAL_TRANSMITTAL","AP_FEED","BILL_PAY","SUBSIDIARY_COLLECTOR_SITE_DUEDATE","COLLECTOR_SITE_DUEDATE","SUBSIDIARY_COLLECTOR_DUEDATE","COLLECTOR_DUEDATE","ComplianceReturns","Assessments","Appeals","TaxBills","TaxBillTransmit","PSR","ProcessDocument","Reassign","AddComment","Duplicate","AppealWarranted","AppealNotWarranted","CompleteFileAppeal","DocumentException","ChangeAppealDeadline","ChangeFilingDeadline","ChangeSubmitEvidenceDate","ChangeInformalHearingDate","ChangeFormalHearingDate","ChangePaymentDueDate","ChangeIntakeItemDueDate","ChangeComplianceFilingDueDate","Transmit","ReviewPayment","ReReviewPayment","CreateInvoice","PrepareDraftInvoice","ReviewDraftInvoice","PreviewThenTransferInvoice","TransferInvoice","ChangeInvoiceDueDate","Skip","SetDocumentRetrievalStatus","CreatePreviewAppealApplication","AddPrepareApplicationTasks","PPReturnDataLoaded","MarkInvoiceUBR","ChangeConfirmHearingDate","AddObtainPaymentReceiptTasks","CompleteObtainPaymentReceiptTasks","PreviewThenTransferUBR","TransferUBR","RequestReliefOfUBR","InsertObtainWorkpapersTaskBefore","GenerateAppealListReport","AppealRecommendation","AddToPaymentBatch","PerformOcr","KNOWNISSUES","RELEASENOTES","ComplianceReportSetup","ComplianceReturnReport","CompliancePackageReport","ComplianceCustomReport","ViewProfile","EntityContact","NewContact","routes","configRoutes","$urlRouterProvider","$stateProvider","views","$title","siteRedirect","parcelRedirect","assessmentRedirect","appealRedirect","billClusterRedirect","billRedirect","filingRedirect","paymentRedirect","refundRedirect","collectorRedirect","assessorRedirect","invoiceRedirect","filingBatchRedirect","filingBatchRedirect2","logout","onEnter","unauthorizedAccess","actionview","onExit","documentProcessing","attachmentPopup","originalStateFunction","definition","routeKeys","routeKey","toCall","rDirections","rCenteredX","rCenteredY","rWidth","rHeight","rFlex","rGrabber","rDisabled","flexBasis","documentElement","width","addClass","w","h","start","dragDir","axis","getComputedStyle","dir","vx","vy","inner","updateInfo","evt","dragging","prop","offset","clientX","clientY","throttle","fun","dragEnd","removeEventListener","removeClass","direction","grabber","setAttribute","innerHTML","appendChild","ondragstart","addEventListener","getPropertyValue","cancelBubble","returnValue","dragStart","initialize","$parse","custom","contextMenus","$currentContextMenu","removeContextMenus","level","processItem","$ul","$li","$promises","$","nestedMenu","isFunction","$a","tabindex","$promise","when","processTextItem","html","registerEnabledEvents","openNestedMenu","$event","ev","pageX","offsetWidth","pageY","offsetTop","view","promisedNestedMenu","renderContextMenu","currentTarget","click","customClass","$contextMenu","position","left","top","_importFile","importContentType","scrollHeight","offsetHeight","clientHeight","removeAllContextMenus","target","hasClass","zIndex","innerHeight","topCoordinate","menuHeight","winHeight","reduceThreshold","leftCoordinate","menuWidth","winWidth","innerWidth","rightPadding","handlePromises","off","openMenuEvent","contextMenuOn","allowEventPropagation","contextMenu","contextMenuClass","defaults","allowFloat","allowNegative","allowHash","getCaret","selectionStart","createRange","re","createTextRange","rc","moveToBookmark","getBookmark","setEndPoint","fn","numericInput","settings","keypress","inputCode","currentValue","charAt","jQuery","LoginService","src_app_Common_Data_base_repository__WEBPACK_IMPORTED_MODULE_0__","constructor","httpClient","super","acceptTermsAndConditions","tokenResponse","rxjs__WEBPACK_IMPORTED_MODULE_1__","httpPut","_angular_common_http__WEBPACK_IMPORTED_MODULE_2__","Authorization","access_token","_angular_core__WEBPACK_IMPORTED_MODULE_3__","i0","TermsAndConditionsModalComponent","_bsModalRef","_loginService","serverAction","hasUserAccepted","selectors","ctx","UserSettingsService","_accountService","_userRepository","getSettingById","userSettingID","getSettingsByGroupAndUserId","lastValueFrom","_mapResponseToSetting","getAdvancedCriteriaSettings","foundSettingIndex","_this2","saveUserSettings","_mapSettingToPayload","newSetting","settingName","settingValue","userSettingGroupID","settingGroupName","userSettingFolderID","settingFolderName","settingToReturn","folderID","settingID","AccrualsGridSummarizeByEnum","AccrualsGridViewModeEnum","AccrualsGridBillRecurTypeEnum","ColumnFiltersOptionsEnum","JournalOptionsEnum","AccrualsColumnFiltersUI","openTaxObligations","Basics","periodContributions","accrualBalances","All","journalImpact","ShowByAccountType","journalBalances","changeDetection","Hide","AccrualsPageService","_Common_Data_base_repository__WEBPACK_IMPORTED_MODULE_5__","currencyPipe","percentPipe","_datePipe","_decimalPipe","fields","getGridColumns","searchModel","columnFilters","resultsModel","colGroups","headerName","children","_getIdentityColumns","_accruals_page_model__WEBPACK_IMPORTED_MODULE_0__","_getOpenTaxObligations","headerClass","_getPeriodContributions","_getAccrualBalances","_getJournalImpact","_getJournalBalances","checkValidateSetup","tlCompanyId","rxjs__WEBPACK_IMPORTED_MODULE_6__","httpGet","getAccountingPeriods","getAvailableFilters","checkAccrualsGridThreshold","httpPost","getAccrualsGridData","startAccrualsGridGet","getAccrualsGridResults","longRunningProcessId","closeAccountingPeriod","accountingPeriodId","openAccountingPeriod","exportToExcel","exportRequest","getExport","observe","applyBulkUpdateToEntry","createExportFile","startTransmitFile","getLongRunningProcessStatus","cols","_getCheckboxColumn","_getEntityCols","summarizeBy","_getStateCol","_getActivityStatusColumn","characteristics","_getAccrualCharacteristicsColumns","mode","_getPeriodRangeColumns","resultModel","duplicates","acc","descriptorName","lodash__WEBPACK_IMPORTED_MODULE_3__","valueFormatter","filterParams","_Compliance_AgGrid__WEBPACK_IMPORTED_MODULE_1__","floatingFilterComponentParams","columnWidth","descriptorFieldTypeId","numCurrency","isNaN","_formatCurrency","colId","toolPanelClass","pinned","lockPinned","minWidth","valueGetter","accrual","characteristicValues","maxWidth","resizable","headerCheckboxSelection","checkboxSelection","suppressColumnsToolPanel","_getCompanyColumn","_getSiteNameColumn","_getSiteNumberColumn","_getPropertyTypeColumn","_getParcelAcctNumColumn","_getCollectorColumn","economicUnitTypeId","_getSiteCodeColumn","cellRendererFramework","_Compliance_AgGrid_CellRenderers_agGridLinkCellRenderer_component__WEBPACK_IMPORTED_MODULE_2__","cellRendererParams","getHelpContentId","newWindow","isHelpDisabled","getLink","entry","billClusterId","getText","collectorAbbr","isRecurring","isDisabled","hideInitially","_getActivityStatusValue","activityStatusId","lockVisible","amountTax","cellClass","amountUnexpensed","isNewThisPeriod","dueDates","commaSeparated","amountExpensed","amountAdjustment","dataFilters","amountTotalExpense","amountTotalPayments","amountBaseExpense","amountTrueUp","amountBasePayments","amountPenalty","amountInterest","enableChangeDetection","amountPriorPeriodExpense","amountExpenseVariance","percentExpenseVariance","changeReasons","amount","amountPeriodBegin","amountChange","amountPeriodEnd","glAccountModels","glAccountsByType","glAccounts","glAccount","_getGLAccountHeader","accountAccrualType","columnHeaderLabel","byTypeOrAcctNum","journalImpactsByType","journalImpacts","checkedValue","_getCheckedValue","comparator","valueA","valueB","nodeA","nodeB","entryA","entryB","byTypeOrAcctNumProp","glAccountsBalanceByType","glAccountsBalance","journalBalancesByType","formattedVal","abs","_angular_core__WEBPACK_IMPORTED_MODULE_7__","AppealApplicationService","_appealApplicationRepository","overrideChangeSource","asObservable","shouldApplyEditsToAll","applyEditsToAll","cacheForms","appealReferences","rxjs__WEBPACK_IMPORTED_MODULE_2__","setApplyEditsToAll","createNewApplication","appealId","createNewApplicationBulk","getMultiAccountFormTemplate","multiAccountAppealFormReference","getFormTemplate","reference","getMultiAccountFormDefaultValues","getFormDefaultValues","getMultiAccountFormOverrides","references","getFormOverrides","correctApplicationFormRevisions","appealIds","createUpdateOverride","override","deleteOverride","searchByTaskIds","getAppealList","getAvailableSupplementForms","getAvailableMainForms","changeSupplementalFormAssociations","changeMainFormAssociations","setOverrideChange","appealFormRevisionId","overridden","generateOutputFile","getOutputFile","getApplicationFormLookups","saveSettings","checkIfSignatureMayBeApplied","completeAppealTasks","setTopAppeal","getGroupNumberMap","settingsProp","download","flattenAndDownload","toAppealFormReference","additionalAccounts","hasAdditionAccounts","allAppealIds","aa","allAppealFormRevisionIds","AppealRecommendationRepository","BaseRepository","getTemplate","_baseUrl","getFields","refresh","getAvailableRecipients","getDescriptorMetadata","updateDescriptor","updateModel","updateTargetValue","startExport","getAppealRecommendationStatuses","updateAppealRecommendationStatus","updateSiteAppealRecommendationIsClientApproved","getTemplatesAsync","saveTemplate","saveTemplateModel","deleteTemplate","appealRecommendationEmailTemplateId","httpDelete","bulkUpdate","ForecastBudgetYearCellEditorComponent","_agGridForecastBudgetYearCellRender_component__WEBPACK_IMPORTED_MODULE_1__","agInit","getEditableValue","afterGuiAttached","inputBox","nativeElement","assessment","lodash__WEBPACK_IMPORTED_MODULE_0__","assessments","yearColumnType","decimal_js__WEBPACK_IMPORTED_MODULE_2__","yoyPctChg","times","toFixed","altFMV","altYoyPctChg","isCancelAfterEnd","_isInvalidNumber","onValueBlur","YearColumnType","_angular_core__WEBPACK_IMPORTED_MODULE_1__","ForecastBudgetYearCellRendererComponent","decimalPipe","_getYear","isInvalidNumber","Fmv","FmvChange","Fmv_A","FmvChange_A","hasExemptions","exemptionsPopover","exemptions","Tax","TaxChange","taxYear","taxes","BudgetFmv","BudgetFmvVariance","BudgetAltFmv","BudgetAltFmvVariance","BudgetTax","BudgetTaxVariance","budget","budgetData","ForecastBudgetAvailableFiltersUI","activityStatuses","ForecastGridSearchModel","ForecastBudgetScopeSelections","showYoYChangesFor","ShowAssessmentsTaxesEnum","AssessmentsAndTaxes","alternateAssessmentView","ForecastBudgetAltAssessmentView","ForecastBudgetScreenModeEnum","Forecast","showBudgetEntriesFor","showBudgetVariances","None","budgetBasis","CompanyBudgetBasisEnum","ForecastBudgetFilterSelections","companyIds","stateIds","propertyTypeIds","activityStatusIds","siteRollup","yearEnd","getFullYear","yearBegin","BudgetTaxYearMissingSyncData","numMissingTaxYears","numMissingBudgets","numOutOfSyncBudgets","ForecastBudgetEditDetails","editAction","ForecastBudgetEditRequest","companyBudgetId","details","autoSyncBudgetToLatest","forBulkUpdate","ForecastBudgetBulkUpdateProgress","parcelCount","siteCount","assessmentCount","billCount","paymentCount","missingTaxYearCount","emptyAssessmentCount","actualizedAssessmentCount","missingBudgetCount","budgetFrozenCount","budgetUnfrozenCount","budgetCreatedCount","budgetSyncedCount","modifiedGridEntry","selections","capture","captureCount","incrementCount","attrName","count","ForecastingBudgetingService","BehaviorSubject","forecastingBudgetingGridData$","_forecastingBudgetingGridDataSubject","freezeButtonLabel","selectedBudget","isFrozen","resetMissingSyncData","missingSyncData","isTLCompany","tlCompany","initServiceModel","scopeEntityTypeId","scopeEntityId","forecastGridSearchModel","tlCompanyID","identityCols","taxYears","_getBudgetFMVColumn","_getBudgetFMVVarianceColumn","_getFMVColumn","_getFMVChangeColumn","_getBudgetAltFMVColumn","_getBudgetAltFMVVarianceColumn","_getAltFMVColumn","_getAltFMVChangeColumn","_getBudgetTaxColumn","_getBudgetTaxVarianceColumn","_getTaxColumn","_getTaxChangeColumn","postProcessEditResult","editResult","entityTypeName","budgetActionTaken","loadData","loadingData","forecastGridResults","getForecastModeList","refreshMissingOutOfSyncCounts","cancelLoad","gridApi","hideOverlay","entries","getMissingCountsForecast","getMissingCountsBudget","getOutOfSyncCountsBudget","getData","updateTotals","totalRows","areSelectedRows","isAtLeastOneRow","totalEntry","totalRow","selectedEntry","forEachNodeAfterFilter","rowNode","_compileNestedTotals","setPinnedBottomRowData","getAreBudgetsEnabled","getCompanyBudgetBasis","getAvailableCompanyBudgets","excludeFrozen","HttpParams","set","getCompanyBudget","createCompanyBudget","budgetName","fiscalStartYear","budgetDate","addRequest","editForecastBudget","forecastBudgetEditRequest","deleteCompanyBudget","saveCompanyBudget","selectedMode","topLevelCompanyId","resp","cashPayEarlyAdjustment","missingTaxYears","missingBudgets","getMissingCountsBudgetForFreeze","_this3","startCreateMissingForecast","startCreateMissingBudgetTaxYear","startSyncBudgets","freezeUnfreezeBudget","_this4","editRequest","_this5","setReferenceFMV","_getIsFrozenColumn","_getLocationColumns","_getEntityColumns","_getBudgetCharacteristicsColumns","AgGridColumns","AgGridFilterParams","suppressAutoSize","AgGridCheckboxCellRendererComponent","onValueChanged","_onFrozenEdited","canEnterEditMode","AgGridLinkCellRendererComponent","isEditingCell","updatingCell","entityCols","_getSiteIdentityColumns","forecastBudgetEditDetails","_this6","_updateCell","_ref","_this7","suppressToolPanel","editable","actualized","cellEditorFramework","cellEditorParams","editDetails","valueFMV","_getFMVCellClass","_this8","showLoadingOverlay","referenceFMVForConcurrency","returnedTotalFMV","returnedAltFMV","_ref2","_this9","_ref3","_this10","yoyPercentFMV","_ref4","_this11","_getBudgetCellClass","budgetFmv","budgetFmvVariance","budgetAltFmv","budgetAltFmvVariance","budgetTax","budgetTaxVariance","isFmvColumn","classString","autoCalculated","isTax","isVariance","fmvUtilized","taxUtilized","isMissing","_getTaxCellClass","totalTax","foundAssessment","startingAssessment","foundTaxYear","startingTaxYear","foundBudget","startingBudget","ReportProcessIntegrationRepository","base_repository","downloadReport","processId","core","AdvancedSearchIntegrationRepository","downloadSearchResults","ActionViewIntegrationRepository","LongRunningProcessIndicatorConfigService","_longRunningProcessRepository","_downloadFileService","_toastsManager","_routerService","_returnAssetRepository","_taxRateCommandCenterService","_assetRepository","_returnRepository","_glAccountRepository","_entityImportRepository","_formSetupRepository","_reportProcessIntegrationRepository","_appealApplicationService","_assessorCommandCenterRepository","_forecastingBudgetingService","_accrualsPageService","_filingBatchRepository","_returnFormRepository","_returnReportRepository","_avancedSearchIntegrationRepository","_actionViewIntegrationRepository","_allocationDetailRepository","_allocationRepository","_rentRollRepository","_incomeStatementLineRepository","_formRepository","_csrCommandCenterRepository","_formLibraryRepository","_contactService","_electronicFilingRepository","_appealRecommendationRepository","_paymentBatchRepository","_responsibleEntityRepository","_transmittalRepository","indicatorRef","cancelled","acknowledge","complete","snack","updateTitle","updateMessage","Map","_importOperations","operationName","downloaded","parameters","getReturnAssetsExport","getDownloadOutput","getTaxRateDataExport","getReconciliationReport","getDownloadForm","getExportedReturnFilingControlSummary","allocationId","getExportFormList","getFormClassificationMappingsExport","getElectronicFilingOutput","getFilesAndFeeds","GetSimulateTransmitResult","importId","importFileId","messages","_processMessageMap","longRunningProcessTypeId","identifier","isCompleted","progressActions","isComplete","progressFailure","_commonMethods","downloadServiceCall","_downloadServiceMap","ProgressActions","downloadResponse","progress","_navigateToMap","_baseDownloadConfig","_baseNavigateConfig","isHidden","_baseNavigateCancelConfig","_ref5","getDownloadReport","setError","of","pipe","processMap","_processMap","_importFileConfig","_baseDownloadWithCancelConfig","_returnReportDownloadConfig","_baseConfig","_baseCancelConfig","_finalizeTransmittalConfig","BusyIndicatorConfig","ProgressIndicator","snackConfig","_next","_messageModalService","Subject","downloadWithCancel","DownloadWithCancel","canDownload","Download","canCancel","canNavigate","Navigate","setWebsocketListeners","statusChange","progressChange","acknowledged","takeUntil","destroy$","longRunningProcessModel","isCanceled","setCancelled","isError","isOwner","performDownload","setComplete","total","setProgressPercentage","downloading","_remove","isSnackBar","performCancel","cancelling","prompt","performDismiss","performNavigate","instant","destroyRef$","SnackSize","SnackBarService","_websocketListenerService","_lrpConfigService","_longRunningProcessesSubject","_longRunningProcesses","lrp","Large","_displayStateSubject","_loadPreviousProcesses","longRunningProcessReconnected$","longRunningProcessStatusChange$","createdBy","_activeTab","_addSnack","hidden","setBusyIndicatorActive","_busyIndicatorsActive","setBusyIndicatorInactive","showSnackBar","_snackSize","showMiniSnackBar","Small","hideSnackBar","Hidden","hideMiniSnackBar","baseConfig","correlationId","createdByName","errorGuid","hostName","isAcknowledged","isPaused","longRunningProcessQueueTypeId","statusCode","_createIndicator","removeById","existing","initialError","indicator","longRunningProcessProgressChange$","longRunningProcessAcknowledged$","m","_loadingPrevious","hideSnackbar","notAcknowledged","allUsers","BusyIndicatorComponent","_elRef","_busyIndicatorMessageIdService","_timer","_messageManager","BusyIndicatorMessageManager","addMessage","generateUniqueMessageIdentifier","paddingBottom","canDismiss","hasAction","progressPercentage","longRunningProcessDelayHelp","ngOnInit","captureFocus","_focusedEl","_getFocusedElement","setAnimationState","ngOnDestroy","_destroy$","restoreFocus","_clearLongRunningProcessStartTimer","isDestroyed","animationState","backdropAnimationState","containerAnimationState","el","_getFocusableElement","setLongRunningProcessId","_longRunningProcessId","_statusReceived","signalRDisconnected","_longRunningProcessStartTimer","isLongRunningProcessDelayed","longRunningProcessDisconnected$","refreshFromLRPServer","longRunningProcess","progressFailed","progressSuccess","_current","_total","action","actionTriggered","_actionSource","onAction","_dismissSource","onDismiss","removeMessage","messageCount","_progressBarSource","onProgressBarComplete","manualUpdateLoading","lrp$","updateLRPManually","activeElement","querySelector","clearTimeout","trigger","opacity","animate","hybridAdapterUtility","_Hybrid_hybrid_adapter_utility__WEBPACK_IMPORTED_MODULE_4__","BusyIndicatorModule","static","ngModule","providers","_busyIndicator_service__WEBPACK_IMPORTED_MODULE_0__","_busyIndicatorMessageId_service__WEBPACK_IMPORTED_MODULE_1__","downgradeNg2Provider","_Config_longRunningProcessIndicatorConfig_service__WEBPACK_IMPORTED_MODULE_3__","imports","_angular_common__WEBPACK_IMPORTED_MODULE_6__","_angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_7__","_UI_Lib_Help_Tooltip_help_module__WEBPACK_IMPORTED_MODULE_2__","BusyIndicatorRef","_componentRef","_isDisposed","isDisposed","_warnDisposed","_messageIds","addLongRunningProcess","destroy","BusyIndicatorService","_componentFactoryResolver","_applicationRef","_injector","_snackBarService","_indicatorActiveSubject","indicatorActive$","_indicatorActive$","busyIndicatorConfig","_globalBusyIndicatorComponentRef","_updateComponent","_createComponent","busyIndicatorRef","isDisposed$","takeWhile","_indicatorsActive","take","componentRef","resolveComponentFactory","busyIndicator_component","attachView","hostView","domEl","rootNodes","actionMessage","BusyIndicatorMessageIdService","_BUSY_IDENTIFIER_PREFIX","_busyIdentifierCounter","BusyIndicatorMessage","_useAutoEllipsis","_getMessageById","_messages","_refreshMessage","itemMessage","endsWithEllipsis","endsWith","CsrCommandCenterRepository","_Common_Data_base_repository__WEBPACK_IMPORTED_MODULE_0__","exportList","exportModel","AgGridLoadingOverlayComponent","_angular_core__WEBPACK_IMPORTED_MODULE_0__","_getOptions","httpPatch","defaultOptions","_angular_common_http__WEBPACK_IMPORTED_MODULE_0__","optionsWithoutHeaders","CachedRepository","_base_repository__WEBPACK_IMPORTED_MODULE_0__","dataCache","DataCache","_http","_primaryAreaName","_primaryCacheExpiration","areaName","_entriesMap","rxjs_operators__WEBPACK_IMPORTED_MODULE_2__","clearCache","clearAllCache","BufferedByteReader","buffer","dataLength","realIndex","needBuffer","bufferIndex","populateBuffer","bufferEnd","getBlobBytes","readNextByte","getIndex","getLength","end","arrayBuffer","from","Uint8Array","resultReader","resultBuffer","onerror","err","readAsArrayBuffer","InternalMultiPartResponseReader","mixedMatch","startIndex","winNl","boundaryBytes","charCodeAt","boundaryIndex","responseReader","readNext","endIndex","headerBuffer","currentByte","fromCharCode","headerMatch","exec","join","binary","readAll","isBinary","contentDisposition","readBlobAsText","srcElement","MultiPartResponseService","ReadResponse","contentType","isMultiPartResponse","DownloadFileService","multiPartResponseService","processedResponse","downloadCount","currentPart","fileNameMatch","FeatureFlagsService","taxDotComBase","base","EntityPermissionService","registerEntityPermission","apiEndpoint","cacheName","_cachedPermissions","getEntityPermission","PermissionFlags","RestrictData","RestrictService","_userInstanceService","_consultingEngagementRepository","_navigationServiceHandler","_entityPermissionService","EntityType","EntityTypeIds","restrictionData","newEndpoint","enableElement","right","explicitInstanceId","isCompany","entityPermissionCheckResult","_newCheckCompanyOrSitePermission","flag","_checkCompanyOrSitePermission","rolesOrEntity","isInRoles","isNotInRole","isNotInRoles","isConsultantUser","instanceIdToCheck","selectedInstance","hasNoInstanceRight","hasInstanceRights","hasNoInstanceRights","instanceMembership","hasSitePermission","hasCompanyPermission","getRestrictionDataForEntity","_newPermissionsCache","entityPermission","isAuthorized","bulkCheckRequest","requestedAccessType","multiEntityCheck","_permissionsCache","permissionUrl","_checkPermission","allowed","CacheManager","keyedStaticCaches","keyPromise","resultPromise","debugMode","buildCacheURL","CacheManagerService","buildCacheMap","buildTimestampPromise","getAPIBuildTimestamp","hex","buildCacheGet","cachedEndpoint","RouteService","_routes","autoSaveInitialRoute","routeBaseRegex","test","hash","validRoutes","Set","currentRoute","matchedRoute","setInitialRoute","src_app_User_authStorage_service__WEBPACK_IMPORTED_MODULE_0__","getInitialRoute","clearInitialRoute","SDHttpService","UpgradeNavigationServiceHandler","EasyAccessService","head","getNgjsService","serviceName","injector","helpDigestDebug","enableDigestDebugging","debugDigest","disableDigestDebugging","enablePauseOnIAM","disablePauseOnIAM","listAngularServices","_getInjectorRecords","getAngularService","targetClasses","targetClass","copyDirectApiToken","getDirectAPIToken","token","records","SettingsService","Load","environmentConfig","getEnvironmentConfig","signalRMessageBrokerUrl","resolveUri","uiConfig","signalRUseUnsafeLogin","weissman2Url","amplitudeApiKey","runtimeEnvironment","inp","onModelChanged","eventTarget","checked","colDef","sanitizer","_navigationService","_link","valueFormatted","textContainsHTML","sanitize","SecurityContext","showLink","showAsyncLink","getLinkAsync","showButtonLink","getButtonLink","hostStyle","getStyle","_testTextContainsHTML","onClick","onClickAsync","onAsyncClick","nav","DateFilterPickerInstanceComponent","EventEmitter","UntypedFormControl","showReset","canReset","dateValue","calendarUID","pickerIndex","valueChanges","distinctUntilChanged","validateDateInput","_isUnique","calendar","datepicker","initialValue","ngAfterContentInit","altField","dateFormat","inline","setDate","onSelect","dateText","dateChanged","isCalendarVisible","writeValue","setValue","setDisabledState","onChange","onTouched","registerOnChange","registerOnTouched","resetInputValue","resetValue","emit","showCalendar","inputValue","provide","NG_VALUE_ACCESSOR","useExisting","forwardRef","multi","decls","AgGridDateFilterComponent","agGridFilterBase","_params","_valueGetter","_searchTypeMap","fv","cv","moment_moment","_defaultFilterOptions","filterOptions","selectFilterOptions","_formatOption","filterValues","filterValue","filterType","_getDefaultFilterType","doesFilterPass","filterTest","_filterValueGetter","valueGetterParams","formattedCellValue","formattedFilterValue","textCustomComparator","displayKey","filterConditionType","getModel","hideFilterInput","setModel","_appliedModel","AgGridNumberFilterComponent","_agGridFilterBase__WEBPACK_IMPORTED_MODULE_0__","filterToValue","onToValueChange","filterModifiedCallback","enterPressed","_invalidNegative","applyNumberFilter","applyFilter","_angular_core__WEBPACK_IMPORTED_MODULE_2__","AgGridTextFilterComponent","_el","filterValueGetter","startsWith","ngAfterViewInit","grid","closest","cellValue","AgGridFilterBase","code","_filterChanged","_hideFilter","isFilterActive","_agGridFilterParams__WEBPACK_IMPORTED_MODULE_0__","hidePopup","onFloatingFilterChanged","submit","newType","_resetFilter","clearInput","addFilterValue","removeFilterValue","trackByFn","setFilterType","setConditionType","toUpperCase","localParams","defaultOption","appliedFilter","lodash__WEBPACK_IMPORTED_MODULE_1__","getFilterModel","filterChangedCallback","hostBindings","AgGridFloatingFilterBase","valueChange","defaultValue","parentFilterInstance","onParentModelChanged","valueToUse","AgGridNumberFloatingFilterComponent","_agGridFloatingFilterBase__WEBPACK_IMPORTED_MODULE_0__","parentModel","conditionApplied","AgGridTextFloatingFilterComponent","GridHelper","filterModel","propertyMap","property","getProperty","filterProperty","getFilterType","getFilterValue","sortModel","sortProperty","sortDirection","getSortDirection","agFilterType","agFilter","dateFrom","numButtons","actionColumnPerButtonWidth","textFilterParamsSmartSearch","textFilterParams","cellValues","clearButton","suppressAndOrCondition","newRowsAction","commaSeparatedFilterOptionDef","blankFilterOptionDef","notBlankFilterOptionDef","applyButton","browserDatePicker","filterLocalDateAtMidnight","dateParts","cellDate","noFilterOptionDef","yesOptionDef","noOptionDef","AgGridDateFloatingFilterComponent","agGridFloatingFilterBase","dateConditionDisplay","AgGridHeaderLegendTooltipComponent","helpInit","AgGridHeaderCellRendererComponent","_agGridPersistenceService","headerTooltipText","tooltipText","fromEventPattern","handler","_sortChanged","context","gridId","isHeaderGroupColorActive$","showGroupColor","_initializeHeader","cycleSort","enableSorting","progressSort","ctrlKey","getColDef","groupColorClass","getColorClassForGroupType","customRenderer","componentParams","groupColor","canHover","isSorting","sortController","getColumnsWithSortingOrdered","sortOrderNumber","getColId","AgGridYesNoFilterComponent","agGridFilterParams","AgGridOptionsBuilder","gridOptions","_gridOptions","defaultColDef","suppressMenu","stopEditingWhenGridLosesFocus","frameworkComponents","agColumnHeader","agDateColumnFilter","agGridDateFilter_component","agDateColumnFloatingFilter","agTextColumnFilter","agGridTextFilter_component","agTextColumnFloatingFilter","agGridTextFloatingFilter_component","agNumberColumnFilter","agGridNumberFilter_component","agNumberColumnFloatingFilter","agGridNumberFloatingFilter_component","agYesNoColumnFilter","withInfiniteScroll","rowModelType","paginationPageSize","cacheBlockSize","infiniteInitialRowCount","blockLoadDebounceMillis","cacheOverflowSize","maxConcurrentDatasourceRequests","maxBlocksInCache","rowBuffer","withColumnMenu","withColumnPinning","withLoadingOverlay","loadingOverlayComponentFramework","agGridLoadingOverlay_component","withSort","sortable","suppressMultiSort","withMultipleColumnSort","multiSortKey","withFloatingFilter","floatingFilter","withContext","withColumnResize","withSingleRowSelect","rowSelection","suppressRowClickSelection","withMultipleRowSelect","withFullWidthCell","isFullWidthCell","fullWidthCellRendererFramework","fullWidthCellRendererParams","withRowHeight","rowHeight","getRowHeight","withFilterChanged","onFilterChanged","withTextSelection","enableCellTextSelection","withVerticalScrollBar","alwaysShowVerticalScroll","withRowId","getRowId","getRowNodeId","withFirstDataRendered","firstDataRendered","onFirstDataRendered","withCellValueChanged","cellValueChanged","onCellValueChanged","withCellEditingStarted","cellEditingStarted","onCellEditingStarted","withCellEditingStopped","cellEditingStopped","onCellEditingStopped","withoutCellEditingStoppedOnGridLostFocus","withDefault","buildDefault","build","AgGridPersistenceService","autoUpdateTables","localStorage","getItem","AUTO_UPDATE_STORAGE_KEY","_convertFromSessionStore","toggleTotalsRowAutomaticUpdate","currentGridLayoutApplied$","tableId","_currentGridLayoutAppliedSubjects","setCurrentGridLayoutApplied","layoutName","_isHeaderGroupColorActiveSubjects","toggleHeaderGroupColor","totalsRowAutomaticUpdate$","_totalsRowAutomaticUpdateSubjects","setItem","_convertToSessionStore","groupType","actionCallback","AgGridDataSourceBase","later","final","_initialRequestComplete","_timeout","_callQueue","_requestResult","successCallback","_refreshing","callNow","_getRows","isMaxRowFound","getInfiniteRowCount","lastModifiedTimestamp","_lastModifiedTimestamp","timestamp","isRefreshing","onFirstDataRendered$","_onFirstDataRendered","updateRow","findRow","getRow","skipRefresh","flashRow","shownNode","getShownNodes","updatedRow","getPageInvolvedProperties","redrawRows","rowNodes","flashCells","getShownRows","gridStart","getFirstDisplayedRow","gridEnd","getLastDisplayedRow","getDisplayedRowAtIndex","props","getSortModel","sortColumn","getRows","refreshDataSourceParams","canGetRows","startRow","_getRowsFn","_showNoRowsOverlay","refreshInfiniteCache","purgeInfiniteCache","setFilterModel","getLoadingMessage","updateCallback","setInterval","repeat","_dataSourceParamsFn","_dataSourceParams","getSortColumns","getColumnFilters","_showLoadingOverlay","getRowsInternal","failCallback","_hideLoadingOverlay","_overlayTimeout","_overlayCount","_clearOverlayTimeout","showNoRowsOverlay","AgGridDatepickerCellEditorComponent","hasOverride","WeissmanDateFormat","validation","cellChanged","formatDateOutputToUTC","onClose","cellFocusLost","isPopup","resetToOriginalValue","stopEditing","AgGridDropdownCellEditorComponent","dropdownOptions","getOptions","dropdownValue","AgGridNumberCellEditorComponent","allowNull","numberValue","debounce","timer","numberEntered","AgGridCurrencyCellEditorComponent","_currencyValueChanged","currencyValue","_value","_formattedValue","distinct","AgGridTextCellEditorComponent","textValue","fillWidth","showOverrideDuringEdit","mask","inputMask","maxLength","wsTextInput","resetToValue","AssetLienDateDetailsComponent","_helpService","LienDateTypes","isCustom","setContent","ASSET_LIEN_DATE_HELP","lienDate","allowNonStandardLienDate","customLienDate","_findCustomLienDate","lienDateItems","isCurrent","lienDateItem","lienDateOptionChanged","standardLienDateChanged","customLienDateChanged","closeObject","holder","blur","UTC","currentMonth","currentDay","standardLienDateItem","_findStandardLienDate","isLienDateCustom","stateLienDateHelpContentId","hasMonthDay","utcStateLienDates","month","getMonth","day","getDate","addLienDate","_createDateFromStateLienDate","stateLienDates","_sortByDate","helpContentId","hasIcon","AssetLienDateComponent","_modalService","ldi","isMarked","_currentYear","providedLienDateInfo","lienDateInfo","requestModel","useSavedLienDate","useCompanyStateLienDate","getLienDates","utcDate","minYear","_yearsBack","selectedLienDate","lienDateSetting","_createLienDateList","currentDate","currentLienDateItem","customLienDateItem","_selectLienDate","selectedDate","standardDateItem","useStateLienDate","lienDateType","dateChange","_markDates","_filterDates","lienDateChanged","saveLienDate","updateLienDateUserSetting","standardLienDate","edit","showAsync","standardLienDateResult","customLienDateResult","ngOnChanges","changes","markedDates","firstChange","showMoreClicked","getDay","AssetDescriptorFieldTypes","EntityImportUploadComponent","_entityImportSpecificationRepository","_ngZone","_authService","_restrictService","_featureFlagService","_entityImportService","fileSpecifications","otherFileDelimiter","initialValueString","eval","busyMessageManager","getFileTypes","getContentTypes","fileTypes","contentTypes","_filterContentTypes","selectedFileType","selectedFileDelimiter","fileDelimiters","_userInfo","selectedContentType","importContentTypeId","selectedContentTypeChanged","_templateMap","lienDateTemplate","selectTemplate","dateTemplate","allowedContentTypes","ct","getSpecifications","specPromise","viewType","getListByUser","getListByCompany","getListShared","specifications","importContentId","selectedFileSpecification","filePicked","run","lastIndexOf","importFileTypeId","_importDisplayNameChangedByUser","importDisplayName","_generateImportDisplayName","attachmentFilePicked","attachmentFile","isFileTypeDelimited","importFileType","importDisplayNameChanged","fileFieldsSelectedValues","_filterFileFields","useFileSpecificationChanged","useFileSpecification","specChosen","headerRowIndex","ft","fd","delimiter","onEffectiveDateChange","effectiveDate","assetEffectiveDate","importFieldId","toISOString","disableSpecDerivedFields","uploadFile","customFields","fileFields","fileMetadata","CompanyId","FileName","ImportContentTypeId","ImportFileTypeId","Delimiter","HeaderRowIndex","ImportFileSpecificationId","importFileSpecificationId","DisplayName","ContentTypeCustomFields","AttachmentFileName","importFileModel","hasEffectiveDate","isReadyForUpload","allFileFieldsHaveValue","supportAttachments","isAttachmentsFileRequired","showImportContentTypeSelections","classRef","fileField","renderer","trackByItem","selectedOptionChanged","contentTypeName","getUTCMonth","getUTCDate","getUTCFullYear","dateString","_joinIfNotEmpty","parts","separator","newFileFields","showWhen","calculateInitialValue","visibleFileFields","getMidnightMoment","rangeEnd","timeZone","WeissmanDatetimeComponent","EntityImportService","taxPaymentsMatchOverallOptions","_taxPaymentsMatchOverallOptions","taxPaymentsMatchParcelOptions","_taxPaymentsMatchParcelOptions","taxPaymentsMatchCollectorOptions","_taxPaymentsMatchCollectorOptions","assessmentsMatchOverallOptions","_assessmentsMatchOverallOptions","assessmentsMatchParcelOptions","_assessmentsMatchParcelOptions","assessmentsMatchAssessorOptions","_assessmentsMatchAssessorOptions","glAccountIntendedUseOptions","_glAccountIntendedUseOptions","AllocationDetailRepository","_Common_Data_base_repository__WEBPACK_IMPORTED_MODULE_1__","_userSettingsService","searchParams","getRowIds","allocationDetailId","allocate","createAssetsNotMatchedFromWorkPapers","matchToExistingNonAllocatedAssets","getSelectedRowsInfo","AssetRepository","getSourceAssetList","getReportingAssetList","getBulkUpdateMetadata","metadataParams","startReportingAssetExport","startSourceAssetExport","getReportingAssetRowIds","assetId","includeTotals","includeChangeDates","includeAssetDescriptors","returnDisposed","lienDateParam","includeTotalsParam","includeChangeDatesParam","includeAssetDescriptorsParam","returnDisposedParam","assetDetailModel","item1","assetSearchTotalsModel","item2","changeDates","item3","minLienDate","item4","maxLienDate","item5","assetDescriptors","item6","getMultiple","reportingAssetIds","returnTotals","startBulkUpdate","getReturns","getActivityLog","reportingAssetId","lienDateRequestModel","getLienDateUserSetting","_lienDateSettingName","getComparisonDateUserSetting","_comparisonDateSettingName","updateComparisonDateUserSetting","comparisonDate","getComparisonDateTypeUserSetting","_comparisonDateTypeSettingName","updateComparisonDateTypeUserSetting","comparisonDateType","createUserCreatedAsset","addModel","assetDetailsModel","getOwnershipTypes","getLeaseTypes","getVerificationReasons","startBulkDelete","AssetClassificationRepository","_Common_Data_cached_repository__WEBPACK_IMPORTED_MODULE_1__","_Common_Data_dataCache__WEBPACK_IMPORTED_MODULE_0__","getAssetClassifications","getAssetClassificationById","rxjs_operators__WEBPACK_IMPORTED_MODULE_3__","_findClassificationById","classifications","foundClassification","ac","assetClassificationId","childClassifications","_angular_core__WEBPACK_IMPORTED_MODULE_4__","FilingBatchRepository","getListByBatch","getListByBatchAvailable","getCountByBatchAvailable","filingIdsToExclude","getRowIdsByBatchAvailable","getListByPriorReturnAvailable","getListByFilingIds","filingIds","updateFilings","force","getTasks","getNextYearInfo","getListByAvailableToMoveFilingsToAsync","moveFilings","amendFilings","getInfo","FormSearchModelImpl","_stateId","_formTypeId","formTypeId","FormRepository","createNextTaxYear","formRevisionId","getByAvailableToCopyTo","formRevisionYearId","copyTo","sourceFormRevisionYearId","targetFormRevisionYearId","deleteTaxYear","getFormClassificationMappings","formRevisionYearAssessorId","exportFormClassificationMappings","getAssessors","rxjs_operators__WEBPACK_IMPORTED_MODULE_1__","getForms","skip","formSearchModel","pagination","createForm","deleteForm","formId","getRevision","deleteRevision","revisionId","createRevisionSupplementalForm","updateForm","updateFormRevision","associateAssessors","disassociateAssessors","formRevisionYearAssessorIds","assessorChangeIsCertified","isCertified","assessorChangeUseDefaultTables","useDefaultTables","assessorChangeUseDefaultMappings","useDefaultMappings","assessorChangeUsePropertyType","usePropertyType","updateIsPrimary","isPrimary","updateIsInDevelopment","isInDevelopment","getSchedulesForRevision","updateSchedules","schedules","getFactors","getFactorTableList","updateFactorTableList","saveClassificationMappings","mappings","getFilingBatches","getDataSourceFieldInfo","getReports","updateReports","reports","updateAppealLevel","appealLevelId","saveCustomReport","reportId","report","reportObject","updateTemplate","metadata","formData","FormData","previewTemplateEdit","previewTemplateEditMetadata","applyTemplateEdit","getTemplateMetadata","getTemplatePageCount","validateTemplate","getAssessorAddresses","updateAssessorAddress","addressId","getStampLocations","exportFormList","exportFormLibrary","formRevisionIds","FormLibraryRepository","getFormRevisions","export","GridLayoutSpecificationRepository","specification","gridLayoutSpecificationId","getGridLayoutUserSetting","_gridLayoutSettingName","gridSetting","updateGridLayoutUserSetting","IncomeStatementCategoryRepository","getIncomeStatementCategories","CostAdjustmentRepository","getTypes","ElectronicFilingRepository","getElectronicFilingTypes","getElectronicFilingInfo","generateElectronicFilingOutput","outputModel","EntityImportRepository","getByCompany","getByCompanyTransferred","importContentTypes","importContentTypeIds","importFile","getFileType","fileTypeId","getContentType","contentTypeId","getImport","ignoreOwnership","deleteImport","getImportRows","getImportSelectedRowIds","updateImportFieldValue","importFileSpecificationImportFieldId","evaluate","selectedRowsModel","transfer","takeOwnership","getValidationSummary","bulkUpdateFieldsAsync","deleteStagingRows","exportStagingRows","revertImport","getAvailableAttachmentTypes","getSystem","getExcelPreviewAsync","updateExcelOptions","markAsCompleted","getAssessmentClasses","getGLAccounts","getTaxingDistricts","startProcess","getGLAccountTypes","getAssetImportInProgressMetadataByLongRunningProcessId","getAssetImportInProgressMetadataByCompanyId","ImportSpecificationRepository","createOrUpdateFromImport","assignStaticField","fieldId","clarificationValues","importFileSpecificationFieldId","isStatic","assignField","headerIndex","unAssignField","specificationFieldId","specificationId","getDynamicFieldBehaviorOptions","updateImportPropertyCharacteristicBehavior","optionId","updateImportFieldPropertyCharacteristicBehavior","FactorTableRepository","getStates","factorTableId","exportSourceAssetList","getAssetExport","exportAttachments","factorTableIds","getExportAttachments","GLAccountRepository","glAccountId","bulkUpdateIncomeStatementTypes","selectionSummary","ReturnAssetRepository","exportReturnAssets","getListByFilingBatch","getRowIdsByFilingBatch","getUnassignedScheduleDetailsByFilingBatch","getScheduleDetailsByFilingBatch","getAssessorsByFilingBatch","getReportingAssetAssessorsByFilingBatch","getWorkingSetAssessorsByFilingBatch","getWorkingSetReportingAssetAssessorsByFilingBatch","updateByFilingBatch","updateClassifications","classificationId","returnAssetBulkUpdateModel","getAssessorFactorTables","ReturnFormRepository","_multiPartResponseService","getFormData","getFormAndData","mergeMap","resultData","startDownloadForm","updateFormFieldOverrides","returnFormOverrideRequestOverride","deleteFormFieldOverrides","getFormFieldOverrides","getOutput","returnIds","ReturnFormRevisionRepository","getByAssociatedWithReturns","getByNotAssociatedWithReturns","models","ReturnFormRevisionReportRepository","getAssociatedWithReturns","getNotAssociatedWithReturns","ReturnSettingsRepository","getByParcel","getByReturn","returnId","saveByCompany","saveByParcel","saveByReturn","getLookupOptions","searchContacts","SupplementalInformationRepository","LongRunningProcessRepository","_easyAccess","lrProcessIncompleteDelay","delayWhen","interval","getQuiescedStatus","updateQuiescedStatus","startSyntheticLongRunningProcess","sendControlMessage","pause","updateError","longRunningProcessError","getQueueTypes","getControlMessageTypes","getServiceHosts","startLrpListExport","CompanyAssetDescriptorRepository","getByCompanyId","getAssetCharacteristics","CompanyRepository","searchCompanies","topLevel","searchCompanyInfo","loadCompany","loadCompanyParent","getCompanyName","getSubsidiaries","updateCompany","isCompanyNameInUse","isCompanyCodeInUseAlready","getPaged","getStatesWithSites","includeSubsidiaries","getByUserPermission","isCache","setIsCompanyFavorite","updateCompanySetting","getCompanyVendorCodesCount","addYear","getCompanyYears","deleteCompany","getAddYearProcessStatus","checkAccrualsEnabled","checkForLongRunningProcesses","getCompanyFiscalYearStart","getTopCompanyForEntity","checkOngoingAction","getEconomicUnitTypes","getInUseCharacteristics","getAllowedAccrualFileTypes","getInfoForCompliance","FormSetupRepository","import","AssessorCommandCenterRepository","getDescriptorInfo","updateDeadline","updateDefaultAddressType","refreshRow","bulkUpdateList","ReturnReportRepository","startDownloadReport","getReport","AllocationRepository","_pathPrefix","getAssessmentsSummary","getTaxAuthorities","addTaxAuthorities","taxAuthorityIds","lockAllocationAssessment","releaseLockedAllocationAssessment","distributeAssessmentVariance","deleteTaxAuthority","getAvailableParcels","getCreateNewMergedParcelsMetadata","createNewMergedParcels","prepareData","getCompanyAssets","getCompanyAssetIds","addCompanyAssets","markAllocationReviewed","ReportingParcelRepository","getSiteByParcel","getSitesByReportingParcel","getSitesByAvailable","getSiteIdsByAvailable","getReportingParcelsByAsset","updateSites","getLinkedSite","getAvailableSites","ReturnRepository","getReturnSignInfo","getReturnTotals","returnsFilter","lockReturn","lockRequestModel","unlockReturn","unlockRequestModel","signReturn","signRequestModel","unsignReturn","unsignRequestModel","finalizeReturn","finalizeRequestModel","getReturnSummary","parcelIds","getReturnFilingControlSummary","columnsToReturn","updateWorkingSet","generateDownloadOutput","getPackages","getMailingTypes","updatePackageMailingType","packageId","newMailTypeId","getFilingBatchReports","getFilingBatchReport","savedSearchId","searchType","taskUpdateModel","taskId","rescindToTask","getTaskUserTeams","startRequest","startPrepareData","getPreparedData","compareForms","resetForms","exportReturnFilingControlSummary","getFilingBatchGeneralReturnSettings","updateFilingBatchGeneralReturnSettings","exportReconciliation","removeFilings","getFinalizeSyncOptions","WeissmanModalService","whenClosed","wsModalTracker","wsModalRef","bsModalRef","closedResolveFn","_modalTrackers","_subscribe","modalClass","modalOptions","class","initialState","ignoreBackdropClick","content","_onHiddenSub","onHidden","_unsubscribe","SignalRMessageBrokerClientService","_authStorageService","_appStateService","_settingsService","_connectionStatusSubject","setup","hubUrl","initialGroup","_appState","_hubUrl","_initialGroup","_joinedGroups","notifyWhen","messageType","containingComponent","_hubConnection","_startedPromise","initializeHubConnection","_callbacks","addDestroyHooks","setRetryInterval","retryInMilliseconds","_retryInterval","joinGroup","invoke","leaveGroup","postConnectLogic","HubConnectionBuilder","withUrl","transport","HttpTransportType","accessTokenFactory","weissman2_token","jsonBody","onclose","disconnected","connectionClosed","asyncToGenerator","reconnected","retryConnect","reconnectLogic","AppStates","retryPromise","origDestroy","stop","WebsocketListenerService","_signalRMessageBrokerClient","_toastr","_setupSignalRClient","signalRUrl","_signalRDisconnected","runOutsideAngular","signalRMessageBrokerRetryInterval","g","_longRunningProcessStatusChangeSubject","_longRunningProcessProgressChangeSubject","_longRunningProcessQuiescedStatusChangeSubject","_longRunningProcessAcknowledgedSubject","_longRunningProcessDisconnectedSubject","_longRunningProcessReconnectedSubject","_launchClient","longRunningProcessQuiescedStatusChange$","ContactsUpgradeService","_contactsRepository","_contactChangedSubject","_contactCacheSubject","currentSearchModel","_currentSearchModel","isDialogMode","_dialogMode","contactChanged$","_contactChanged$","contactCache$","_contactCache$","contactChanged","newContact","updateContactInCache","CommentsRepository","_cacheManagerService","fetch","comment","editComment","deleteComment","commentId","sendTaskComments","getEntityDataForTasks","getEntityData","checkForComments","getAvailableCommentTypesForEntityType","pinComment","commentID","unpinComment","AccountRepository","updateOnboardingStatus","onboardingStatus","BASE_URL","ActionViewRepository","getTaskContextOptions","itemPayload","addObtainPaymentreceiptTasks","addObtainWorkpapersTasks","completeObtainPaymentReceiptTasks","ActivityRepository","parcelFilter","yearsToInclude","includedParcels","useLatestActualizedAssessmentYear","parcelLevel","AdvancedSearchRepository","BASE_SEARCH_URL","BASE_SMART_URL","getColumnsCpMode","getAllCustomSearches","SERVICE_URL_CUSTOM_SEARCH","saveCustomSearch","searchItem","SERVICE_URL_SEARCH_SHARE","SERVICE_URL_SEARCH_REVOKE_SHARE","createCustomSearch","saveSystemSearch","SERVICE_URL_SYSTEM_SEARCH","createSystemSearch","getOneSearch","searchId","searchEndpoint","_getSearchEndpointByType","extendedPath","payloadCriteria","getSearchCategories","createSearchCategory","deleteSearchCategory","patchSearch","changeSearchCategory","categorySearchItem","searchID","deleteSearch","toggleSearchFavoriteOn","toggleSearchFavoriteOff","searchHasFavorites","SERVICE_URL_FAVORITE_CHECK","SERVICE_URL_FAVORITE_COUNT","getBulkUpdateDescriptors","SMART_BULK_DESCRIPTOR_URL","SMART_BULK_UPDATE_URL","searchURL","constants_new","AppealApplicationRepository","API_URL","APPEAL_APP_URL","AssessorCollectorRepository","getCompanyCollectorsByParcel","COMPANY_COLLECTOR_URL","getAssessorExtract","EXTRACT_URL","BLOB_OPTIONS","getCollectorExtract","getCollector","getAssessor","getUpdatedAssessorCollector","extraParam","getCollectorAssociations","getStateCollectorList","getAssessorCollectorList","getCompanyCollectorList","saveAssociations","associations","saveAssessorCollector","getStateAssessorList","getAssessorActiveParcelCounts","countForStateID","getAssessorMunicipalities","createAssessor","assessor","createCollector","saveCollectorProtocols","collectorProtocols","ConsultingEngagementRepository","ContactsRepository","ASSOCIATION_SERVICE_URL","InvoiceRepository","getInvoiceByTaskIds","bulkMarkUBR","bulkTransferToRIBS","ParcelRepository","getView","navigationRequest","callParams","parentid","getContactParcel","getParcelLatestAssessmentYear","getParcelsInfoForSingleYear","yearValue","getParcelLinkageTypes","getLinkedParcels","includeUnlinked","addNewLinks","updateLinks","getParcelListBySiteId","getParcelYears","getOptimusLinkInfo","bulkUpdateModel","getParcelAssessmentClasses","deleteParcel","getAssessorJurisdictionSpecialists","getAcctNumberTypes","SiteRepository","getSite","loadSite","getCompanyId","getParcelIdsBySiteId","updateSite","deleteSite","addSite","getParcelsForSiteId","PARCEL_URL","loadByCompanyId","getSiteName","getParcelsBySiteId","getSiteListByCompanyId","getSiteListByCompanyIdOtherInstance","searchSites","getReportingParcelBySiteId","SiteClassRepository","getPrimaries","StateRepository","TaskRepository","_messageBoxService","internalHttp","UserRepository","isSSOIntegrationEnabled","SSO_INTEGRATION_URL","getSSOIntegrationEndpoint","domain","changePassword","newPassword","currentPassword","sendPasswordResetToken","usernameOrEmail","resetPasswordUsingToken","tokenHash","bulkPermissionCheckRequest","USER_SETTINGS_URL","PaymentBatchRepository","getPaymentBatchList","deletePaymentBatch","paymentBatchId","savePaymentBatch","getPaymentBatchDetailById","savePaymentBatchDetails","paymentBatch","getPaymentBatchWorkflowStatusById","getPaymentBatchPaymentsList","getPaymentBatchPaymentsRowIds","deletePaymentRow","paymentId","startPaymentBatchDetailsPaymentBulkDelete","deleteModel","paymentBatchDetailsPaymentBulkReReview","getAvailableWorkflows","getDeliveryDetailPaymentBatch","getAvailablePaymentBatchesForAddPayments","getPaymentBatchPaymentList","getPaymentBatchPaymentRowIds","addPaymentsToPaymentBatch","addPaymentsToBatchByTaskId","advanceTask","getAllowedBatchTypes","finalizeTransmittalPackage","packages","getTransmittalPaymentPackages","getBillPaymentPackages","getOutputZip","feedTypes","getPaymentBatchSettings","savePaymentBatchSettings","startPaymentBatchExport","startPaymentBatchDetailsExport","startPaymentBatchCheckImport","_angular_common_http__WEBPACK_IMPORTED_MODULE_1__","getPaymentBatchCheckImport","savePaymentBatchCheckImport","paymentBatchCheckImportId","discardPaymentBatchCheckImport","getAvailablePaymentBatchGridFilters","getAvailablePaymentBatchGridSubsidiaries","getShippingMethods","setShippingMethods","TransmittalRepository","CreatePaymentPackage","ReReview","CheckFinalizeLongRunningProcess","packageIds","GetPaymentPackages","packageIDs","GetPaymentPackagesByCompanyID","startDate","endDate","GetPaymentPackagesByPaymentID","paymentID","GetPaymentPackageByID","paymentPackageID","CheckForMissingAttachments","CancelPaymentPackages","FinalizePaymentPackages","handleCode","FinalizePaymentPackagesLR","RecallPaymentPackage","packageItem","GetLRFinalizeResults","GetPreviewData","currentPackage","GetPreviewAttachment","GetPaymentPackageAttachmentSummary","ValuationTemplateRepository","getTemplateList","addOrUpdateTemplate","templateId","getTemplateNamesWithDuplicateSettings","updateTemplateStates","updateTemplateAssessors","assessors","getSiteClassOptions","updateTemplateSiteClasses","siteClasses","getTemplateById","updateTemplateFile","downloadTemplateFile","deleteTemplateFile","ErrorLogRepository","errorLogId","getViaGuid","errorLogGuid","QueryInfoRepository","queryInfoId","HybridAdapterUtility","provider","_angular_upgrade_static__WEBPACK_IMPORTED_MODULE_0__","downgradeNg2Component","AceAuthOidcWrapperService","_scriptLoaderService","_routeService","authWrapperEnabled$","ReplaySubject","authElement$","login","autoStartLogin","loadScript","ScriptLocations","keepCurrentLocation","signOut","Initializing","AppStateService","ngZone","logoutMessage$","ResponsibleEntityRepository","TaxRateCommandCenterService","TaxRateGridService","taxRateCommandCenterData$","_taxRateCommandCenterDataSubject","loadTaxAuthorities","_loadTaxAuthorities","loadTaxRateAreas","_loadTaxRateAreas","getPendingQcCounts","getCollectors","getTaxAuthoritySelectionsForBulkUpdate","selectionOptions","applyBulkUpdateToTaxAuthority","taxAuthorityId","exportTaxRateData","retryProcessingTaxAuthorities","allTaxRateAreas","taxRateAreas","allTaxAuthorities","taxAuthorities","enabledTaxRateAreas","enabledTaxAuthorities","taxYearBegin","_taxYearBegin","taxYearsPrior","_taxYearsPrior","AceButtonComponent","_router","iconFontClass","iconFont","iconSize","buttonClicked","routerOutlet","stateService","buttonClick","iconSvgs","Alert","Clock","Completed","Earth","Filter","Mail","Show","AceIconComponent","atom","bars","bell","briefcase","cog","camera","check","clock","crop","database","earth","exclamation","generic","hands","hammer","home","mail","mobile","network","none","palette","paste","pen","plug","print","question","redo","sparkles","spinner","sync","tools","trash","undo","vial","glyph","_renderAceSvgIcon","_aceDxpIconMap","glyphContainer","_addRandomId","svgStr","uniqueKey","random","ClickOutsideDirective","_elementRef","contains","clickOutside","InputMaskDirective","ngControl","wsMaskValue","_defineValue","onInput","_onValueChange","_updateValue","wsMaskValueChange","_delay","control","updateValueAndValidity","displayValue","maskGenerator","_mask","_processValue","wsKeepMask","_displayValue","_unmask","len","maskLen","pos","maskChar","newChar","regex","_REGEX_MAP","maskedValue","ms","_ALPHA","_NUMERIC","_ALPHANUMERIC","NumbersOnlyDirective","_control","onKeyDown","numbersOnly","forDateInput","negativeAllowed","decimalAllowed","singleDecimalOnly","metaKey","keyCode","shiftKey","onPaste","clipboardData","formatted","num","validNum","minValue","maxValue","validateMinMax","FilePickerComponent","fileDropped","uploadFiles","limit","multiple","fileEntry","isFile","f","_generateFileName","picked","tick","filename","HelpTooltipComponent","_renderer","_changDetectorRef","targetPosition","_targetPosition","boundingBox","_forcePosition","forcePosition","_edgeBuffer","_getEdgeBuffer","edgeBuffer","updateTooltipPosition","componentToRender","removeComponent","providedComponent","componentTarget","onMouseEnter","isHovered","onMouseLeave","onWindowScroll","tooltipPosition","_setTooltipPosition","removeChild","detectChanges","_calculateBottom","_calculateTop","_calculateLeft","_calculateRight","_preRender","tooltip","getBoundingClientRect","scrollY","getBuffer","topBuffer","pointerLeft","pointerXBuffer","tooltipLeft","leftBuffer","tooltipTop","pointerTop","pointerYBuffer","idealTop","idealLeft","wY","wX","closestXEdgeDistance","closestYEdgeDistance","isXAdditive","isYAdditive","xBuffer","yBuffer","HelpTooltipDirective","_helpContentId","_retrieveHelpContent","_helpContent","getUniqueId","contentComponent","helpContentComponent","_setIcon","helpContent","externalTooltipTrigger","setHoverIn","contentComponentValue","_getPosition","setHoverOut","tooltipDelay","helpDisabled","removeTooltip","_helpContentSub","getContent","_addIcon","_removeIcon","_icon","setStyle","_Hybrid_hybrid_adapter_utility__WEBPACK_IMPORTED_MODULE_1__","HelpModule","_help_tooltip_directive__WEBPACK_IMPORTED_MODULE_0__","_angular_common__WEBPACK_IMPORTED_MODULE_3__","APP_HELP","HelpService","tooltipActive","_tooltipActive","_observerMemo","helpGetter","_lib","Observable","observer","_libChanged","updateContent","toggleShowHelp","showHelp","_closingInterval","_contentComponentRef","changeDetectorRef","_tooltipRef","_position","_componentHovering","_currentContent","_contentComponent","_evaluateHoverState","_clearIntervals","resetTooltip","_tooltip","setDelay","bottom","toJSON","_showTooltip","_createTooltip","_closeTooltip","componentFactory","help_tooltip_component","isHovering","helpContentValue","tooltipHovering","_hoverTransitionTimer","tooltipCanHover","hovered","_openingInterval","MessageModalComponent","MessageModalButtons","MessageModalResult","MessageModalDisplayMode","MessageModalService","_wsModalService","alert","isErrorState","displayMode","SingleMessage","alertList","subtitle","MessageList","componentState","messageList","dialogAction","MessageBoxService","DraggableElementSearchDirection","DraggableDirective","_zone","Down","onResize","_checkOutsideBounds","_addButton","_handle","_findElement","dragHandle","dragHandleDirection","_target","dragTarget","dragTargetDirection","_setupEvents","_toggleCenteringButton","mousedown$","fromEvent","mousemove$","mouseup$","_cursorChange","switchMap","startX","startY","_delta","_translate","_dragInProgress","_offset","requestAnimationFrame","handleBounds","documentWidth","clientWidth","documentHeight","_boundingThreshold","_centerTarget","Up","parentElement","childElement","grabbing","translated","_buttonVisible","_centeringButton","listen","icon","AceLoaderComponent","faSize","ModalWrapperComponent","suppressKeyboardEvents","locationEvent","disableSave","headerClicked","isHeaderLink","headerClick","WeissmanAbsoluteUrlPipe","startingUrl","pure","WeissmanYesNoPipe","WeissmanTrueFalsePipe","getMoment","newMoment","moment_timezone__WEBPACK_IMPORTED_MODULE_0__","local","WeissmanDateTimeFormatPipe","allowEmpty","WeissmanDateFormatPipe","WeissmanMonthDayDateFormatPipe","CommentDateTimeFormat","M","WeissmanFilterPipe","items","FilterPipe","keysToCheck","WeissmanKeyValueDisplayPipe","keyTemplate","valueTemplate","SortByPipe","order","colA","colB","localeCompare","numeric","reverse","SplitListPipe","itemsPerColumn","TimeAgoPipe","moment__WEBPACK_IMPORTED_MODULE_0__","fromNow","WeissmanTimeSpanPipe","milliseconds","precision","unit","seconds","minutes","hours","KEY_CODE","SelectComponent","_selectService","searchableOptions","selectedOption","placeholder","labelProperty","valueProperty","disabledProperty","titleProperty","returnEntireOption","isPrimitive","canSearch","canDeselect","deselectLabel","deselectValue","includeSearchAfterN","maxListSize","maxTextLength","alignOptionText","isShowMoreFromParent","customSearch","optionStyleClass","container","updatePosition","selectConfig","tabIndex","formatter","_formatter","_setOptions","_options","UP_ARROW","keyPrevious","DOWN_ARROW","keyNext","_scroll","selectedValueChanged","openDropdown","_applyValueFormatter","widestOption","optionsChanged","_angular_forms__WEBPACK_IMPORTED_MODULE_2__","noop","searchValue","SelectDropdownComponent","exact","fuzzy","pattern","RegExp","aIncludes","bIncludes","aMatch","bMatch","dropdownConfig","_search","updateDropdownPosition","searchInput","selectedItem","dropdown","scrollTop","renderedTop","animateComplete","closeDropdown","_focusOption","_keyPrevious","_keyNext","_container","_prerender","_getBuffer","_renderToTop","dropdownPosition","_scrollBarWidth","listSize","_showMoreClicked","searchResult","searchResultCount","setListItemFocus","focusOption","_resetSearch","showMore","currentShownOptions","MAX_ROWS_BEFORE_SCROLLBAR","getTitle","_focusAtIndex","scrollTo","animations","SelectService","_currentDropdown","_targetBounds","_getTargetBounds","_showDropdown","_dropdownRef","resetDropdown","_lastActiveContainer","_removeDropdown","_dropdown","_createDropdown","containerRect","UtilitiesService","_timerService","regexIso","BuildTimestampService","ValidatorService","isGuid","guidRegexp","ScriptLoaderService","constants","scriptLocation","isModule","src","loadedScripts","GoogleMaps","IAMComponent","PDFJSLib","PdfJsBase","PDFJSViewer","newTag","TimerService","wait","immediate","whenDoneTransitioning","time","DATE_INVALID_MESSAGE","TIME_INVALID_MESSAGE","MIN_DATE","MAX_DATE","endOf","builtInChange","inputDateChange","datePickerClosed","inputDateBlur","validationChange","changedKeys","internalTime","updateDisplayDate","initPicker","_hasScrollListener","_closeOnScroll","dtDateInput","dateOnly","dateRangeOptions","_dateInput","changeEvent","newDate","onUpdateDate","excludeValidation","changeYear","changeMonth","showAnim","dtTimeInput","correctInputType","newInput","getAdjustedMoment","hour","minute","buildMomentHelper","buildMoment","isInvalid","dateInput","timeInput","currentMoment","displayDate","setValidationMessage","rawDateValue","ampm","hourValue","rawTimeValue","timeMatch","altTimeMatch","openDatepicker","onBlur","setAsTouched","resetValidation","is","newObj","utcOffset","clientId","userInfoUrl","logoutMessageIdleTimeout","GrantTypes","AccountService","_weissmanModalService","_featureFlagsService","_aceAuthOidcWrapperService","_toastrService","_accountRepository","_tokenHandled$","initialMessage","_timeouts","loginExpire","idleTimeout","loginMigration","emailAddress","grantType","loginData","requestData","grant_type","client_id","password","saml20","saml20LoginData","sso_request","migration_email","tokenRequest","getMigrationInvite","accessToken","HttpHeaders","loginFromAceOidc","tokenExchange","showIAMLogoutButton","setNoRelogin","isIdpInitSSO","_lastSynchedActivityTime","loginDate","passwordLoginData","subject_token","subject_token_type","getIsMigrationLogin","inviteData","alreadyMigrated","inviteUrl","migration_exception","set_no_relogin","getWeissman2Token","tokenResponseResult","handleTokenResponse","clearAuthData","idleTimeoutInMinutes","idleTimeoutMode","refreshTokenExpireTimeSpanMinutes","needsToAcceptTermsAndConditions","newRefreshTokenData","refreshToken","refresh_token","originalAccessToken","StorageTokenKeys","IdleTimeoutModes","initialRoute","setupRefreshTokenExpire","setupIdleTimeout","handleInitialRoute","_rememberedRoute","beginHomeRealmDiscovery","homeRealmDiscoveryStarted","disableAppStartup","weissmanNg1Bootstrap","checkPersistedLogin","loginSucceeded","attemptRefresh","enableIAMLogin","refreshTokenData","refreshTokenExpirationDate","checkForExistingRefreshToken","navPromise","roleList","rightsByInstance","storedToken","nowInMs","lastActivity","recordActivity","setAuthData","error_description","initializeLogout","resetPathOnLogout","isMigrationException","currentInstanceSelection","activeInstances","inactive","im","getIAMInitialLoginData","_this12","authToken","_this13","_this14","_this15","_this16","hasRyanInstance","iamId","isDemoUser","claims","createDate","login_date","defaultTeam","setupRefresh","authInterceptEnabled","setActivityRecordingMode","lastActivityTime","authData","expires_in","computeNextRefreshTime","configuredRefreshMoment","alternateRefreshMoment","expireTimeSpanMs","_this17","additionalHeaders","requestBody","_this18","nextRefreshTime","isRefreshed","refreshTokenExpirationTime","idleTimeoutTime","_this19","_this20","refreshTokenKey","AuthStorageService","token$","rxjs__WEBPACK_IMPORTED_MODULE_0__","activity$","isMigrationLogin","_authData","lastActivityKey","desc","UserInstanceService","AllInstancesId","isHomeInstance","offersConsultingServices","documentIntakeIdpEnabled","includeHidden","userHasMultipleInstances","_ensureSelectedInstancesKeyExistsWithDefaults","_authStorage_service__WEBPACK_IMPORTED_MODULE_0__","selectedInstanceId","allInstancesItem","isInstanceExplicit","isCrossInstancePerspective","getInstanceById","getInstancesForHeader","saveSelectedInstance","showManageMyInstances","IncomeStatementRepository","getIncomeStatementList","getIncomeStatementEndDates","startIncomeStatementLineExport","getIncomeStatementRowIds","deleteItem","incomeStatementLineId","updateIsValidated","updateBalance","RentRollRepository","getRentRollList","getRentRollEndDates","startRentRollExport","getRentRollRowIds","rentRollLineItemId","Constants","PropertyTypeNames","TransmittalOutputTypeAbbr","TransmittalOutputFormats","ORIGINAL","FMV_AV_LEGAL","FMV_AV_TV_RV_LEGAL","FISCAL_YEAR","ALDI","REALESTATE","PERSONAL","MINERAL","CENTRALLYASSESSED","ContractServiceTypes","ADMIN","fullDisplayName","PREACQUISITION","MISC","ACCRUAL","ASMTREVIEW","RETURN","TAXBILL","HOURLY","LITIGATION","ClientServiceTypes","COMPLIANCERETURNS","ASSESSMENTS","APPEALS","TAXBILLS","TAXBILLSTRANSMIT","FREEPORT","ABATEMENT","POLLUTIONCONTROL","SiteClassIcons","WorkflowUserTypes","ACCOUNTHANDLER","JURISDICTIONSPECIALIST","EntityTypes","PaymentPackage","Invoice","Asset","FactorTableTypes","FilingTypes","RepresentationTypes","FormTypes","ReturnFormFieldEntityTypes","TaxableAssessmentTypes","extraDisplay","TaxableAssessmentTypesForTrueRate","TaxAuthorityCategories","AccountingDurationTypes","CertificationTypes","TaxAuthorityStatuses","Pending","Actual","Estimated","ImageURLs","EmptyGuid","EntityTypeLevels","PropertyType","ContractServiceType","TaskType","CommentType","CommentTypeNames","ContentTypes","SavedSearchCategoryEnum","ClientServiceType","ActiveStatuses","CommonBulkUpdateFieldActionEnum","AssessmentComponentTypeEnum","AdvancedSearchCategoryTypes","DefaultDisplayTypes","RevisionChangeTypes","TaskActionViewContextOption","agGrid","numeral","windowRef","initialiseAgGridWithAngular1","weissmanAppModule","angularjs_lib_esm","uirouter_angular_hybrid","$titleProvider","$get","breadCrumbs","trans","$breadcrumbs","targetState","navigable","hasTitle","lodash","resolvables","parent","hackApply","$httpProvider","$compileProvider","$locationProvider","$urlServiceProvider","debugInfoEnabled","applyBannerColor","hashPrefix","configHeaders","interceptor","$injector","config2","Instances","responseError","rejection","useDefaultAuthHandling","rejectionMessage","interceptors","Pragma","checkDigestDebug","debugDigestFlag","debugDigestFlags","replaceSetInterval","original_setInterval","disablediag","replaceSetTimeout","original_setTimeout","disableAnimations","getElementsByTagName","enableDebugging","getTestability","whenStable","setOptions","lang","thousandsSep","numericSymbols","layoutService","editableOptions","navigation","$urlService","openQuickSearch","loginFromSSO","modal","args2","theme","onSuccess","newTitle","$provide","decorator","$delegate","$exceptionHandler","proto","getPrototypeOf","originalDigest","$digest","originalApply","$$phase","prefixService","loggedInUserId","processContact","canManageUsers","showNewContactForm","prefix","contactRole","assignCurrentEntityPropertiesToNewContact","addressID","showForm","iamIsMigrated","contactForm","roleToSave","createdContact","updatedContact","getParams","saveContact","cancelSave","navigateEntity","isCompanyEntity","validateInput","$error","$viewValue","$name","csrService","annualDetailsNavigationEventService","ActivityStatusIdMap","InstanceRepository","resetAnnualDetails","maximizedPanel","prevParcelId","nextParcelId","permissionFlags","hasWritePermission","hasComplianceResponsibility","tabs","situs","thisVarIsDefinedWhenNotSaving","changeData","panelMaximized","maximized","panelName","resetStrikeThru","activity","upcoming","comments","invoicing","maximize","clientServicesChangeSub","clientServicesChange$","getHasComplianceResponsibility","strikeThru","getCompTypes","compTypes","parcelAssessmentClasses","aClass","uniqueComps","assessmentClass","assessmentClassComponents","comp","componentName","assessmentComponent","loadClientServices$","calls","doPermissionCheck","companyIDErrMsg","siteIDErrMsg","notFoundErrMsg","initializeDeferred","ppReturnPreparationAllowed","parcelViewDTO","reportsSites","hasPrivateItemsPermission","showComplianceInfo","canEditCompanySetups","isInactive","activityStatusID","stateAllowConsolidating","allowConsolidating","enableAllocations","identifyPrevAndNextParcelsIds","prevIndex","nextIndex","promises","load","topLevelCompany","ajaxError","getAnnualGridAndCompTypes","getCompTypesOnly","getAnnualGrid","boundAnnualGridCallback","billTab","aavConfig","getAllYears","annualYearData","components","getComponents","collapsedAppealStatus","annualGridDetails","updatedParcel","openParcel","maximizeChanged","targetPanelName","currentEntityService","hasRyanPrivateItemsEdit","maximizePanel","panel","minimizePanel","sitePromise","enableLicensedConsultingInvoicing","companyPromise","hasRyanPrivateItemsView","ReportType","ActionViewService","ReportDetailCriteria","SiteReportCriteria","includeParcelAssessmentGrid","includeCompanyNameDetails","includeFmvChart","includeSiteAppealComments","includePinnedParcelComment","UserActivityReportCriteria","showUserName","showContactTitle","showLoginDates","showLoginDayCount","showLastPasswordChange","PsrReportCriteria","reportTypeId","paperSize","showAcqInfo","showYearBuiltInfo","showAppealDeadlines","showAssessments","showMetrics","showInitValue","showTargetValue","showLatestValue","showTaxDetails","showAppealDetails","showComments","showParcelList","showSiteAppealCommentsValue","showSavings","orderGroupBy","FormatOutputOptionsPsr","outputFormatOptions","paperSizeOptions","showAssessmentsOptions","showMetricsOptions","showValueOptions","showTaxDetailsOptions","showSiteAppealCommentsOptions","showLatestValueOptions","showSavingsOptions","FormatOutputOptionsBudget","summaryCashBasisPeriodOptions","showPercentChangeOptions","detailLevelOptions","SummaryReportCriteria","summaryCashBasisPeriod","detailLevel","includeBudgetComments","showPercentChange","orderAndTotalBy","BudgetVarianceFormatOutputCriteria","budgetSources","summaryReportOptions","BudgetVarianceSummaryReportCriteria","varianceDetail","BudgetVarianceBudgetSource","budgetId","budgetPeriod","periodBegin","periodEnd","BudgetPeriodSelection","EntitySelection","selectedTopLevelCompanyIDs","selectedEntities","selectedSupportInstanceIds","ReportCategory","ReportDetail","ReportSummary","report_manager_model_GetEntitiesRequest","GetPropCharValuesRequest","ReportManagerService","budgetingService","currentPropCharsSource","setNewPropChars","propChars","selectableBudgetsChanged$","_selectableBudgetsChangedSubject","getReportCategories","reportCategoryManagerUrl","reportType","ReportCategoryTypes","reportCategoryManagerCustomUrl","reportItem","reportManagerUrl","reportID","deleteReport","categoryName","deleteComplianceReport","deleteReportCategory","patchReport","saveReport","isSystemReport","prepareReport","newCategory","categoryType","reportDetail","detailReportOptions","includeAlternateAssessments","budgetPeriods","period","bvrFormatOutput","createReport","getOrderAndTotalByOptions","getTotalAndGroupByOptions","firstYear","secondYear","refreshBudgetPeriods","availableBudgets","periods","sel","fiscalPeriodBegin","fiscalPeriodEnd","availableBudgetPeriods","forcastSources","availableBudgetSources","refreshSelectableBudgetSources","selectedBudgetPeriods","selectableBudgetSources","getSiteStatusOptions","getSiteStatusOptionsExceptInactive","apiRequest","entitySelection","selectedDropdown","selectedIDs","selectedPropCharVals","AceSelectDropdownComponent","AceSelectService","dropdownOpen","dropdownActive","SaveTabColumnType","AceSelectComponent","fesm2020_forms","ReportCategoryComponent","_reportManagerService","_userSaveService","modalTitle","reportName","selectedCategory","refreshCurrentList","createNewCategory","creatingNewCategory","cancelCreateCategory","ReportRenameComponent","variant","variantName","UserSavePage","SearchCategoryType","_columns","_currentSelectedFilter","currentSelectedFilter","currentSelectedCategory","_currentSelectedCategory","_dirty","refreshLocalList","structuredClone","system","favorite","_separateByCategoryType","userCategories","uncategorizedUserSearches","systemCategories","uncategorizedSystemSearches","favoriteSearches","favoriteList","savedItemList","_formatFavorites","_showEmailWindow","searches","SavedReportService","_reportService","_advancedSearchPersistenceService","tabTitle","_systemReportMenuWithPermissions","_customReportContextMenu","_baseValues","reportList","changeDate","canFavorite","originalModel","amplitudeEvent","_getAmplitudeEvent","navigateTo","listItem","_shareReport","clearSearchData","isSystemSeeded","currentName","properties","actComplianceReport","actSystemReport","AdvancedSearchPersistenceService","_updateAdvancedSearchSubject","_deleteAdvancedSearchSubject","_advancedSearchSubject","_isSearchingSubject","_showCriteriaSubject","updateAdvancedSearch$","_updateAdvancedSearch$","deleteAdvancedSearch$","_deleteAdvancedSearch$","advancedSearch$","_advancedSearch$","isSearching$","_isSearching$","showCriteria$","_showCriteria$","scrollLocationIndex","_scrollLocationIndex","loadedSearchCriteriaCache","_loadedSearchCriteriaCache","updateAdvancedSearch","deleteAdvancedSearch","savedSearch","setIsSearching","searching","showPageTitle","fromWidget","hiddenColumns","reloadingSearch","columnsExpanded","setSearchCriteria","searchCriteria","resetSearchCriteria","SearchOperatorsService","_operators","_initializeOperators","filterOperators","getByFilter","filterOps","nullable","equal","sortOrder","notEqual","doesNotContain","beginsWith","blank","notBlank","lessThan","greaterThan","lessThanEqual","greaterThanEqual","isNA","withinDate","should","_createWildcard","_makeNot","_createRange","wildcard","op","opObj","must_not","SmartSearchService","_advancedSearchRepository","_searchOperators","byCategory","persistedDepths","_cacheManager","getCacheManager","targetCache","filterColumnsByRyanPrivateAccess","filterColumnsByRyanInstance","isRyanInternal","categoryColumns","typeAheadName","subcategoryColumns","checkedColumns","temporary","depthsChecked","depth","uniq","getDepthsThatDisable","smartOnly","smartOnlyFields","usedBySmart","checkIfAllFieldsPresent","getFieldById","getFieldByDisplayName","COMPANY_CONTACT","SITE_CONTACT","PARCEL_CONTACT","BILL","REVISION","COMPONENT","disableColumnsFromTaskTypeOnly","taskSeriesType","depthValuesToEnable","fieldIdsToEnable","initColumns","columnIdExists","idExists","advancedSearchFieldIDExists","resetCategoryState","criteriaFilter","operatorName","filterOr","revokeModel","defaultDisplay","isSystemSearch","searchName","returnSearch","cancelSearch","_canceler","sub","toggleSearchFavorite","systemSearchID","persistSetting","SMART_SETTING_GROUP_ID","existingSettings","getSavedSettings","shouldReturnColObject","colDepths","colToCheck","depthsThatDisable","colName","getColName","offendingColumns","SearchCategoryComponent","_smartSearchService","SearchDefaultDisplayComponent","SearchRenameComponent","SavedSmartService","_productAnalyticsService","_shareSmart","userHasEditSystemSearch","searchList","exploreFavoriteToggle","exploreSystemSmart","ActionViewPersistenceService","SearchPageType","ProductAnalyticsService","_logEvent","_amplitude","esm","identify","_getIAMUserId","serverUrl","trackingOptions","ipAddress","_previousEvent","_debounceLogEvent","_sequenceEvents","targetSequence","eventSequence","sequenceEvent","events","envConfig","_userPropertiesSet","_setUserProperties","_getUserType","restrict_service","_getUserAge","days","userType","userAge","IAMUserId","identityEvent","userTenant","UserSaveService","_actionViewService","_actionViewPersistenceService","_currentUserSavePage","Smart","AV","SavedActionViewService","Report","selectedUserSavePage$","_currentUserSavePage$","getSavePage","_currentSavePage","_savePages","ActionViewCategoryComponent","ActionViewDefaultDisplayComponent","selectedDisplayType","thatAreChoice","ActionViewRenameComponent","_systemActionViewMenu","_customActionViewMenuWithPermissions","actionViewList","actFavoriteToggle","_shareActionView","favoriteCount","actSystemActionView","SaveActionViewModalController","broadcastAndClose","savedActionView","errorToast","createOrUpdate","actionViewCategories","newSequence","displayTypes","categoryTypes","actionViewTypeFilter","saveActionView","toggled","categoryEntered","enteringCategory","findSystemCategory","sysCategory","DragAndDropListService","isDragging","_isDragging","_itemType","dropEffect","_dropEffect","effectAllowed","_effectAllowed","_callback","DragAndDropListModule","DirectivesModule","common","SharedPipesModule","date_formatting_pipe","boolean_pipe","keyValueDisplay_pipe","filter_pipe","timeSpan_pipe","absolute_url_pipe","orderBy_pipe","timeAgo_pipe","splitList_pipe","AceIconModule","hybrid_adapter_utility","AceSelectModule","AceSimpleTableCellComponent","dist","AceSimpleTableComponent","AceSimpleTableModule","AceTabSetModule","AceModule","AceBadgeComponent","CurrencyModule","ng2_currency_mask","LoadingSpinnerModule","select_module_hybridAdapterUtility","SelectModule","select_component","select_service","ModalWrapperModule","help_module","TriStateCheckboxModule","TypeaheadComponent","typeaheadConfig","fesm2020_animations","TypeaheadService","_hideDropdown","WsTypeaheadModule","AnchorRouteDirective","sref","_sref","_initialized","_createHREF","isTargetBlank","_href","BreadCrumbsComponent","WeissmanPanelViewEnum","WeissmanPanelComponent","_setDefaultParameters","toggleIsExpanded","isExpanded","expandedToggle","onEdit","_canNavigateTo","canDeactivateDisplayView","canActivateEditView","Edit","onCancel","canDeactivateEditView","canActivateDisplayView","Display","onSave","canExpand","canCollapse","supportsMultipleViews","deactivatePromise","activatePromise","UILib_module_hybridAdapterUtility","UILibModule","weissman_datetime_component","ngx_file_drop","AgGridExtensionsModule","agGridPersistence_service","ngx_bootstrap_dropdown","busyIndicator_module","ngx_bootstrap_modal","ngx_bootstrap_popover","BrowseColumnModalComponent","isTaskTypeSpecialCase","taskTypeDepthValue","_calcCountAndDisabled","columnClicked","isColumnChecked","existingColumns","otherColumnsThatMightDisable","fp","checkedCount","totalCheckedCount","ColumnPickerComponent","columnsLoaded","columnsSelected","typeaheadColumnToAdd","allowDuplicates","_processCategories","columnPicker_module_hybridAdapterUtility","ColumnPickerModule","ngx_bootstrap_typeahead","ngx_bootstrap_tabs","CommentModalData","CommentsService","_commentsRepository","entityYearOverrides","yearIsRelevantForEntityTypeID","isInstanceNameInUse","resourceUri","_entityInstanceCache","getEntityIdPairInstanceId","_entityInstanceCacheById","getInstanceTypes","getCurrentUsersContactInviteStatuses","userEndpointUrlPrefix","acceptInvite","contactEndpointUrlPrefix","rejectInvite","toggleInstance","LoadingSpinnerComponent","LineLimitDirective","_element","lineLimitModel","computedStyle","lineCount","lineHeight","lineLimit","lineLimitNumber","lineLimitIsOver","CommentListItemComponent","_commentDateTimePipe","getTimestampString","_commentIsUpdated","changedByName","showYearTitle","toggleHide","getYear","CommentsComponent","_commentsService","_instanceRepository","valid","updateComment","commentTypeID","entityData","isSingleRyanInstance","yearIsRelevant","areCommentTypesAvailable","availableCommentTypes","commentTypes","commentTypeName","yearFilter","entityTypeFilter","isBelowParcelLevel","includeChildren","entityTypeChanged","editingComment","allComments","commentList","unpinnedComments","pinnedComment","entityTypes","_getAllComments","disableYearSelection","done","commentCount","disableCommentTypeSelection","addComment","isNewComment","_resolveInstancePrivate","_populateYears","submitEditForm","_createComment","_saveEdit","isPinned","verb","yearDisabled","yearChanged","filteredComments","_yearFilterPredicate","allEntityTypeFilters","allCommentTypeFilters","allTypeFilters","_typeFilterPredicate","_setIsPinnableCommentAttribute","_formatPinnedComments","includeChildrenChanged","getAllCommentsDeferred","loadParentComments","_entityTypeChanged","commentTrackBy","hasInstancePrivateView","_prepareComments","lineOne","parentEntityName","lineTwo","lineThree","sortDate","isOverLimit","unpinned","_prepareYears","commentType","allYears","indexOfNullYear","isPinnable","childLabel","AddCommentComponent","processResult","showFull","defaultYear","_getHasInstancePrivateView","canSave","commentTitle","openCommentModal","modalData","modalParams","EntityCommentsButtonComponent","_commentsModalService","showCommentsDialog","getModalData","analyticsCategory","commentData","hasComments","hasCommentsChange","commentCountChange","CommentsModule","Core_Repositories","TaxRatesPanelTaxAuthoritiesCellRendererComponent","taxRateArea","rate","authorities","taxRateAuthorities","TaxRateCommandCenterCommentsCellRendererComponent","gridSofurce","commentModalData","taxRateAreaId","ATTACHMENT_MODAL_HELP","CurrentEntityService","currentTypeId","_getEntityData","revisionDesc","DocumentServiceUpgrade","mimeTypeExtensions","exts","AttachmentService","_utils","_constants","_navService","createAttachment","attachment","_getEntityTypeName","attachmentId","typeID","getSingleAttachmentBody","dontCancel","_terminateSub","urlCreator","webkitURL","createEvent","initMouseEvent","dispatchEvent","fileExt","downloadAttachmentFile","allowMultiple","fileDownloadBufferMaxSizeKB","downloadAttachmentFileStreamed","downloadAttachmentFileBuffered","tap","getFileNameFromHttpResponse","oneTimeCode","MouseEvent","httpResponse","isUntyped","matches","attachmentGuid","isPreviewSupported","deleteAttachment","getAttachmentIcon","hasAttachments","checkForAttachments","getAttachmentCategories","CATEGORY_SERVICE_URL","TYPE_SERVICE_URL","QuickFiltersService","_getFilters","getActive","_getExtraDocumentFilters","getInactive","idpFilterType","associatedWith","default","defaultDocument","sequenceNum","SearchFiltersService","advanced","_initializeFilters","_initializeOrs","_addEmptyTexts","ors","operatorId","SearchRepository","searchAdvanced","searchTerms","SearchService","_quickFilters","_searchFilters","_searchRepository","initializeResultTypes","_savedCriteria","getSavedDefaultCriteria","convertToCompanyField","vals","incomingCriteria","triggerUpdate","criteriaChanged","_clickedOnResultIndex","buildSortObj","city","stateAbbr","_criteriaChangedListeners","_resetListeners","_criteriaSettings","DEFAULT_CRITERIA_NAME","defaultCriteria","_criteriaToSave","getDefaultAdvancedCriteria","resetAdvancedCriteria","_activeAdvancedCriteria","sortByCategory","isStateFilter","buildAdvancedQuery","setActiveAdvancedCriteria","startFrom","getEntityType","sortByFields","startFromRecord","numberOfRecordsToGrab","resultJson","totalCount","totalNumberOfRecords","filtersWithInput","getActiveAdvancedCriteria","deleteAdvancedCriteria","NavigationRepository","NavigationService","_searchService","_currentEntityService","_navigationRepository","_globalEditModeSubject","_loginFromSSOSubject","defaultState","anonymousStates","storedState","storedParams","_quickSearchInitiator","globalEditMode$","_globalEditMode$","loginFromSSO$","_loginFromSSO$","_quickSearchListeners","initialUrl","toState","to","toParams","_globals","router","postLogin","goToLogin","isLogout","setDefaultUnload","onbeforeunload","childWindows","childWindow","registerChildWindow","navWarningEnabled","transitionService","onBefore","getInitialUrl","PubSubService","MissingPublishTopic","MissingSubscriptionTopic","MissingTargetWindow","FailedInvokingCallback","messageInfo","_invokeCallback","publishTopic","publishData","publishWindowName","topic","_Messages","opener","_publishRemote","publishChild","targetWindow","subscribers","_subscriptions","subscribeOnce","windowName","postMessageInfo","postMessage","PopUpService","_pubsub","PopUpBlocked","AttachmentPreview","aliasGroup","ref","_attachmentPreviewInitializedSubscription","_attachmentPreviewInitializedCallback","_AppStates","popUp","_popUps","_openWindow","_getNextWindowName","closeByAliasGroup","popUps","_lastUsedWindowName","screenLeft","outerWidth","screenTop","outerHeight","AttachmentFormComponent","_attachmentService","_fb","attachmentForm","populateYears","noYear","Validators","disableYears","taxYearRequired","setValidators","patchValue","_fetchedCategories","populateTypes","_fetchedTypes","attachmentCategoryID","attachmentTypes","disableAttachmentType","disable","allowType","attachmentTypeName","allowAtSite","allowAtParcel","allowAtCompany","allowAtAssessment","allowAtAppeal","allowAtRefund","allowAtInvoice","allowAtState","allowAtCollector","allowAtAssessor","allowAtForm","allowAtFormRevision","allowAtFactorTable","allowAtFilingBatch","allowAtTaxAuthority","allowAtTaxRateArea","allowAtBudget","allowAtAccountingPeriod","allowAtAllocation","allowAtPaymentBatch","submitButtonLabel","isSaving","attachmentToUpdate","formValues","getRawValue","attachmentFormUpdated","attachmentData","externalID","ownerType","ownerName","secondaryOwnerName","numberOfPages","metaData","changedBy","attachmentFormCreated","attachmentFormCancelled","isDeleting","attachmentFormDeleted","LoadPdfIframeService","iframe","contentWindow","stopImmediatePropagation","doc","styleElement","styleText","createTextNode","PDFViewerComponent","FileViewerComponent","fileReader","readAsDataURL","isImage","AttachmentModalComponent","_documentService","_utilities","_popupService","_rootScope","isListHidden","isViewerFullWidth","belowParcelEntity","skipEntityService","startOnPhotos","viewFlags","_setPermissions","_imageCategoryIds","_attachmentCategories","_CATEGORY_ID_ALL","_CATEGORY_ID_PHOTOS","categoryFilterId","attachmentCategoryId","getAllAttachments","headerLabel","parentType","entityDescription","includeSubEntities","_numberOfDistinctEntities","filteredYears","singleYear","_years","filteredAttachmentYears","_attachments","_passesCategoryFilter","filteredAttachments","_passesYearFilter","filteredCategories","uniqueCategoryIds","imageAttachmentExists","intersection","isFirstAttachment","selectedAttachment","isLastAttachment","selectAttachment","_cachedParentAttachments","_cachedAttachments","_getAttachmentsForCurrentEntity","attachmentLoading","fileNameType","File","_notifyChildWindow","_getPopUpData","selectFirstAttachment","loadParentAttachments","parentId","parentTypeId","_buildAttachmentList","addAttachment","editAttachment","currentEntityForForm","savedAttachment","selectAddedOrUpdatedAttachment","toggleList","viewerWidthDelay","popOutAttachment","getNext","nextAttachment","getPrev","prevAttachment","_composeDialogResult","emailAttachment","hasImages","selectedAttachmentId","selectedAttachmentFileName","allowEntityEdit","attachments","countBy","toArray","_sortAttachments","returnVal","year1","year2","name1","_getAttachmentTypeName","name2","entityAttachments","EntityAttachmentsComponent","forImages","showAttachmentsDialog","hasAttachmentsChange","hasImagesChange","TaxRateCommandCenterAttachmentsCellRendererComponent","attachmentModalData","TaxRateQcByCellRendererComponent","taxAuthority","yearObj","taxAuthorityStatusId","qcRequestTimeUtc","qcBy","moment_timezone","qcRequestUserFullName","SwitchComponent","ngDoCheck","opt1","optionOne","opt2","optionTwo","toggleWidth","onLabel","offLabel","switchWrapper","switchContainer","toggleSwitch","AgGridSwitchCellRendererComponent","TaxingDistrictListGridActionCellRendererComponent","UserGroupsGridActionCellRendererComponent","userGroupGridItem","onViewDetailsClicked","viewDetails","onDeleteClicked","CompanyPermissionsGridActionCellRendererComponent","ActionViewOutputDefaultsGridActionCellRendererComponent","MAX_INT","AgGridMultiSelectTracker","_getRowIdsFn","selectAllRows","_isGridFiltered","_isSelectingRange","selectedRows$","_selectedRowsSubject","isSelectingRange$","_isSelectingRange$","getSelectedRowsModel","_selectedRowsModel","getSelectedRowIds","setSelectedRowsModel","_clickedNodeId","_gridHasFilters","_gridHasFiltersAndSelectAllChecked","hasFilteredRows","hasSelectedAllFilteredRows","isSelectAllChecked","isAllRowsDisabled","allRowsCount","getDisplayedRowCount","columnDef","columnApi","getColumn","isCellRendererDisabledFn","forEachNode","hasSelectedRows","getSelectedRowsCount","getTotalRowsCount","hasAnythingSelected","isRowSelected","rowId","isSelected","isRowPendingRangeSelection","nodeId","_getRowNodeId","_pendingRangeSelections","isGridPendingRangeSelection","setExternalFilterApplied","isExternalFilterApplied","_isExternalFilterApplied","onGridFilterChanged","clearFilters","clear","onGridSortChanged","toggleRowChecked","shiftClicked","lastClickedNodeId","currentClickedNodeId","_selectRange","_clickedNodeChecked","toggleAllChecked","selecting","notify","refreshHeader","aIndex","bIndex","selectRange","rowsResponse","rangeSelection","idSet","idsToRemove","selectedRowsWithoutIds","isAnyFilterPresent","AgGridMultiSelectedHeaderRendererComponent","_tracker","tracker","_rowId","isChecked","hasSelectedAllRows","hasSelectedIndividualRows","isUnchecked","isIndeterminate","isPendingRangeSelection","getCheckboxClass","isForIconStyle","className","toggleChecked","updateAllRowValues","AgGridMultiSelectedCellRendererComponent","isCellRendererHiddenFn","getCheckboxTitle","updateRowValue","InstanceRightGridActionCellRendererComponent","ApplicationPermissionGridActionCellRendererComponent","WsAgGridWrapperModule","main","agGridForecastBudgetYearCellRender_component","agGridForecastBudgetYearCellEditor_component","agGridLinkCellRenderer_component","ParcelIconComponent","isLinkedParcel","isLinked","_linkedOverride","isMasterParcel","isMaster","_masterOverride","parcelTypeClass","parcelType","parcelIconClass","_setParcelParams","propTypeParam","includeIcons","icons","consolidatingTypeId","iconClass","colorClass","helpTooltip","consolidatedParcelId","isReportingParcel","ParcelTypeCellRendererComponent","getParcelType","isConsolidatedParcel","isMergedParcel","ActivityStatusCellRendererComponent","isActivePending","AG_GRID_TOOL_PANEL_HELP","AgGridLayoutSpecificationDetailsComponent","_formBuilder","_gridLayoutSpecificationRepository","visibility","visibilityItem","busyMsgId","busyIndicatorMessageManager","AG_GRID_LAYOUT_SPECIFICATION_HELP","UserService","hasRyanInstanceMembership","deleteUserSettingByNameAndID","setCredentials","_loginCallbacks","shift","homeInstanceId","AgGridLayoutSpecificationComponent","_userService","descriptionNoCompany","visibilityPrivate","visibilityPrivateCompany","visibilityCompany","visibilityCompanyDefault","visibilityShared","_gridId","_load","editHelpContentId","selectedSpecification","copyHelpContentId","deleteHelpContentId","displayedColumnsChanged$","_builtInSpecification","layout","layoutModel","getColumnState","colorize","colorizeHeaders","unResizedColumns","_applySpecification","onSpecificationChanged","visibilities","spec","_getListItem","_sort","canEditCompany","canEditShared","defaultColorizeHeaders","visibilityBuiltIn","specItems","userLayoutId","selectedSpec","loadComplete","sorted","specificationModel","allVisibilities","colState","setColumnState","setSortModel","defaultSort","specificationChanged","AG_GRID_HELP","TriStateCheckboxComponent","SortDirection","AgGridToolPanelColumnsComponent","_refreshColumns","_specification","columnSettings","showHeaders","getColumnGroupState","getColumnGroup","grouped","showGrouped","hasFilterApplied","_filterValue","selectedSort","debounceTime","_applySettings","_showGroupedHeaders","toggleIsVisible","canChangeIsVisible","setColumnVisible","hasColumnChanges","filterInstance","getFilterInstance","setColumnPinned","canChangeIsPinned","trackByColumnId","trackByGroupName","toggleSort","currentSort","Ascending","Descending","toggleSettings","showSettings","toggleGroup","setColumnsVisible","toggleGroupLevelCollapse","isCollapsed","undoChanges","_initialColumns","hasGroupings","enable","_filter","_groupColumnsState","_group","fromSpecificationChange","_columnsInitialized","canUserPin","gridColumns","gridColumn","headerColor","t_r27","ctx_r28","BulkEditButtonOptions","showLoading","toolTipId","AgGridToolPanelComponent","_busyIndicatorService","excel","tabDelimited","pdf","configureLayoutHelpContentId","filtersHelpContentId","isFilterVisible","isFiltered","disableExport","exportOptions","getDisabled","additionalActionsVisible","additionalActions","bulkUpdateButtonHelpId","defaultBulkUpdateButtonHelpId","onGridReady","isInitialized","defaultSizeToFit","sizeToFit","defaultSizeToContent","sizeToContent","onDisplayedColumnsChanged","showExport","isBulkUpdateVisible$","showBulkUpdateLoading","showBulkUpdate","disableBulkUpdate","observers","isBulkDeleteVisible$","showBulkDelete","bulkDelete","isCustomButtonVisible$","showCustom","customButtonClick","_processDestroy$","onExpandClick","onFilterClick","filtersEnabled","onClearFiltersClick","sizeColumnsToFit","autoSizeAllColumns","sizeColumnsToContent","onExportClick","showFileFormatSelection","_exportFile","onExportOptionSelected","onCustomExportOptionSelected","hideFileFormatSelection","onAdditionalActionClick","showAdditionalActions","hideAdditionalActions","onAdditionalActionSelected","onClickCallback","onBulkUpdateClick","onBulkDeleteClick","specificationLoadComplete","toolPanelReady","layoutSpecificationChanged","showFileFormat","fileFormat","availableFileFormats","_showBusyIndicator","_busyRef","_busyRefId","hasProgressBar","_hideBusyIndicator","exportType","customExportOption","getAllDisplayedColumns","clientSideExport","exportDataAsCsv","WsAgGridWrapperComponent","hasToolbar","forceShowToolPanel","gridReady","_gridReadyEvent","onAgGridReady","agGridReady","showConfigureLayout","ParcelFilterModalComponent","rowClassRules","gridTracker","excludeInactiveStored","_allParcels","_gridApi","_getGridRowIds","_setColumnDefinitions","_setRowData","selectedParcels","updateParcels","updateParcelFilter","suppressSizeToFit","headerComponentFramework","AgGridMultiSelectedHeaderRenderer","headerComponentParams","AgGridMultiSelectedCellRenderer","propertyType","isTotalRow","setColumnDefs","setRowData","rowsToDisplay","queryResultModel","totalValidRows","ActivityService","_activityRepository","_userSessionFilterCacheSubject","_userSessionFilterCache$","clearParcelFilterCacheForSite","getColor","nameOrIndex","colors","getColorsArray","colorIndex","calculatePropCharAdjustedFmv","originalValueValue","getFmvValue","getGraphTitle","getTableTitle","getHoverPointFormat","multipleSeries","digits","getTotalTaxHoverPointFormat","floating","color","fontWeight","tableTitle","spacingLeft","marginLeft","spacingRight","marginRight","spacingTop","spacingBottom","options3d","alpha","beta","viewDistance","credits","yAxis","allowDecimals","legend","align","verticalAlign","headerFormat","pointFormat","useHTML","shadow","followPointer","plotOptions","stacking","legendItemClick","createPropertyTypeAndPropCharConfig","createLandConfig","createTotalTaxesConfig","createTaxSavingsConfig","createTotalTaxesUngroupedConfig","FMVByPropertyTypeItem","newSeriesItem","propertyTypeSequence","_colorIndex","propertyTypeIndex","fmvForLandTypeComponents","collectorTaxesItem","collectorName","sdColorIndex","existingSeriesIndex","itemStyle","zoomType","grouping","labels","opposite","lineColor","marker","fillColor","getNumericValue","originalFMV","currentFMV","getValueForPropType","propTypeData","fmvPerSqFt","fmvPerUnit","getLandValueForYear","yearData","createGraphConfigForDashboard","afterPrintCb","totalValues","afterPrint","exporting","contextButton","menuItems","textKey","onclick","printChart","exportChart","newYearTotals","landFMV","createPropertyTypeConfig","createLandConfigForDashboard","activity_module_hybridAdapterUtility","ActivityModule","AssessmentTaxesGridData","AssessmentTaxesCriteria","showLienDate","valueDetails","includeAssessedValueInfo","includePPPropertyType","includeTargetValue","includeValuationMetrics","breakOutTaxPaymentDetails","includePaymentDueDates","AssessmentTaxesOptions","valueDetailsOptions","includeAssessedValueInfoOptions","includeTargetValueOptions","includeValuationMetricsOptions","breakOutTaxPaymentDetailsOptions","AssessmentTaxesDetailsService","getSiteYears","getSiteSummary","getParcelSummary","DataTypes","AssessmentTaxesDetailsModalComponent","_assessmentTaxesDetailsService","maybeGetSelectableYears","setYearDefaults","loadGrid","getGridData","gridData","getSelectableYears","fromYear","selectableYears","toYear","savingSettings","AssessmentTaxesDetailsIconComponent","showModal","assessment_taxes_details_module_hybridAdapterUtility","AssessmentTaxesDetailsModule","YearPickerMixin","getYearPickerTaxYears","ContractsInvoicesService","contractTermsUpdateSubject","contractTermsUpdateObservable","getContractTermsByCompany","getContractTermsBySite","shouldRequireConfirmationDialog","terms","saveCompanyContractTerms","saveSiteContractTerms","rollForwardYear","sourceYear","targetYear","rollForwardSiteOverrides","searchEngagements","getInvoiceRecipientsByEngagement","engagementId","saveFeeEscalator","EngagementNumberLookupModalComponent","_contractsInvoicesService","_renderer2","selectRootElement","initialSearch","engagementResults","selectEngagement","engagement","PanelChevronComponent","ChooseTermPopoverComponent","lookupTerm","termToEdit","selectedTerm","contingencyPct","contingencyCap","chooseTerm","saveTerm","flatFee","hourlyRate","TermRatesAndFeesComponent","ContractTermsPanelCompanyComponent","hasViewPermission","services","enableAppealLitigation","litigationIndex","editLock","expandOrCollapse","loadPanel","propertyTypeId","recentYears","populateContractTermData","goToEditMode","addTerm","newTerm","contractTermDetailId","contractServiceTypeId","contractServiceTypeName","propertyTypeName","getSelectedYear","subsidiaryYears","siteDefault","remarks","contractTermRowVersion","currentContractTerms","areTermsDirty","getDataForYear","removeTerm","term","pullAt","confirmAutoSave","launchAddYearModal","configureFeeEscalator","launchConfigureFeeEscalatorModal","addingYear","yearToAdd","newYearData","allData","populateYearsDropdown","addTermYearModal","savingFeeEscalator","fixedFeeEscalator","newFeeEscalator","contractServiceTypes","newEscalatorServiceTypes","companyRowVersion","configureFeeEscalatorModal","savePanel","stayInEditMode","panelIsInvalid","saveBody","useTopLevelCompanyTerms","ContractTerms","topLevelCompanyContractTerms","getCurrentTermsForSave","requireConfirmationDialog","saveData","lookupEngagement","engagementID","termsAreEditable","showRollForwardYearButton","useTopLevelCompanyChanged","setSelectedYear","serviceTypeChanged","newServiceType","newRemarks","getContractServiceTypename","serviceTypeId","serviceTypeSelected","checkedServiceType","isPanelDirty","v","foundTerm","topLevelYears","prepareDataForView","contractTerms","showFeeEscalator","feeEscalator","escalatorServiceTypes","yearsToAdd","lastDisabledYearIndex","findLastIndex","aContractTermHasChanged","copiedTerm","ContractTermsPanelSiteComponent","currentTermItem","availableTermItems","termDetailId","messagebox_service_upgrade","isTermNotSiteDefault","companySiteDefaultTermId","contractTermYears","termId","SaveAsIconComponent","StateService","_stateRepository","navigatedFrom","_navigatedFrom","multiSelect_component_noop","MultiSelectComponent","selectedOptions","objectIsValue","selectedOptionsChanged","_setSummary","deselectAll","multiSelectOptionActive","selectedOptionsEmpty","setProperty","toggleDropdown","selectedSummary","useSemicolons","StateDropdownComponent","_stateService","_cdRef","selectedStatesSummary","selectedStates","includePlaceholder","_getStates","previousValue","selectedState","selectedIds","stateIdsChange","stateAbbrsChange","stateIdChange","stateAbbrChange","onStateChange","onSelectedStatesChange","_loadingStates","abbrOnly","AddressViewEditComponent","StepProgressIndicatorModule","Busy_Indicator","CategoryColumnPickerComponent","disableUseSystemDefined","colIds","defaultColIds","useSystemDefined","removeColumn","draggableOutputColumns","onSysDefinedChanged","AceDropdownComponent","resize","_calculatePosition","placementClasses","positionClasses","sameWidth","overflowVisible","setOpenState","autoClose","ddPosition","openChange","hostElRect","dropdownHost","menuElRect","dropdownMenu","windowWidth","hostElTop","hostElRight","inset","margin","InstanceFilterComponent","instances","instanceChanged","CompanyService","_companyRepository","_company","noCache","fetchedCompany","_updateParentId","noPermission","isCompanyNameInUseAlready","companyCode","topLevelCompanyID","favoriteOnly","instanceIdFilter","useExplicitCrossInstanceListForPermCheck","vendorCodeSetting","invoiceAppealSavings","fiscalYearStart","syncDXPFlag","budgetsEnabled","budgetDescriptors","accrualsEnabled","defaultAccrualAdjustmentMethodId","useTopLevelCompanyCOA","accrualEconUnitTypeId","accrualEconUnitDescriptorId","accrualFileTypeId","accrualDescriptors","excludeFromAccruals","accrualExportPropertyIdentificationId","accrualExportPropIdentDescriptorId","requireClientApprovalFlag","dataHubEnabled","dataHubClientTenantId","useTopLevelCompanyVendorCodeMapping","syncDXP","requireClientApproval","inUseCharacteristics","CompanyPickerComponent","_companyService","_getCompanies","companyIdChange","companyNameChange","companyChange","onNoResults","_noResult","typeaheadLoading","loadingCompanies","PAGE_NUMBER","ColumnFiltersComponent","removeOr","columnFilter","emptyFilter","addOr","updateOrValue","filtersUsed","_filtersUsed","actionViewFilter","maybeHideValue","hideRow","filterId","changeOperator","oldOrName","selectorType","orName","advancedSearchDataType","COMPANY_NAME_ID","COMPANY_NAME_TOP_LEVEL_ID","datePickerOpened","selectedOr","$$hashKey","isDatePickerOpen","columnFiltersTrackBy","StampModule","StampTooltipComponent","StampComponent","dataValue","_dataValue","_createHelpComponent","inactiveOffset","offsetFrom","visible","soldOffset","getInactiveURL","activatedBy","inactivatedBy","inactivatedDateTime","activatedDateTime","weissman_shared_module_hybridAdapterUtility","WeissmanSharedModule","ngx_bootstrap_tooltip","ngx_bootstrap_carousel","ngx_quill","ngx_bootstrap_progressbar","google_maps","ngx_bootstrap_sortable","ngx_bootstrap_accordion","ExternalAPIService","getKeyTransmittalPublicData","requestCode","getPrivateKey","ExternalAPIKeyComponent","externalAPIService","navigationServiceHandler","privateKey","rcMatch","keyTransmittalPublicData","backToHomepage_Click","AccountModule","AccrualsBulkUpdateModalComponent","editReq","operation","reportedChangeReasonAction","showOverrideChangeReason","editOptions","isSaveable","adjustmentDescription","reportedChangeReason","AccrualsPageComponent","_upgradeNavigationServiceHandler","sortColumns","operationInProgress","closingPeriod","creatingExportFile","gettingGrid","attachmentsModel","startAccountingPeriod","commentsModel","isBulkUpdateDone","bulkUpdateCurrent","selectionsLength","isSummarizeByBills","isExportable","isExportTransmittable","_startAccountingPeriod","_startAccountingPeriodId","endAccountingPeriod","_endAccountingPeriod","_endAccountingPeriodId","parentCompanyId","_initValues","loadLongRunningStatus","lrpStatus","periodCloseInProgress","exportInProgress","gridGetInProgress","activeLongRunningProcessId","refreshBulkUpdateState","_showGridSpinner","loadFilters","_getAvailableFilters","parentCompany","availableFilters","validateSetupModel","isSetupInvalid","noAccountingPeriods","incompleteGLAccounts","_setEntityFilters","_getAccountingPeriods","accountingPeriods","toggleMaximize","isMaximized","goToParentCompany","toggleEditMode","isEdit","isBulkUpdateVisible","getSelectedNodes","singlePeriodSelected","endAccountingPeriodId","startAccountingPeriodId","showApplyButton","periodRangeSelected","_initSelectedAccountingPeriodEnd","previewCloseSelected","firstOpenAccountingPeriodId","accountingPeriodChanged","getSelectedRows","_getRowEntityId","reselectGridNodes","companiesSelected","statesSelected","propertyTypesSelected","setColumns","gridColumnGroups","_orderColumns","handleLRPStatusChange","processType","_hideGridSpinner","startGridDisplay","loadGridResults","thresholdResult","useLongRunningProcess","_startGettingGridData","_startLoadingGrid","_completeGridDisplay","_stopLoadingGrid","transmitFile","unfilteredSelections","_gatherBulkUpdateSelections","closedAccountingPeriods","startNdx","endNdx","accountingPeriod","apName","bulkUpdateInProgress","bulkUpdateTotals","rowsChanged","billsChanged","bulkUpdateCanceled","siteNumber","siteCode","getCurrentBulkUpdateIdentity","identity","endBulkUpdate","_this21","calculatePercentVarianceThreshold","percentVarianceThreshold","_this22","suppressScrollOnNewData","headerHeight","groupHeaderHeight","suppressMovableColumns","onGridColumnsChanged","columnSizing","_updateTotals","onColumnResized","onSelectionChanged","billRecurType","setOpenStatusByIndex","lastClosedAccountingPeriodId","accountingPeriodsModel","_this23","_getStartAccountingPeriod","_this24","unionWith","startingIdx","moveColumns","_this25","_this26","setSelected","rowFields","block","entryValue","account","_this27","LARGE_BULK_UPDATE_THRESHOLD","BalanceAdjustmentsService","getSelectionData","getAdjustments","updateAdjustment","adjustment","deleteAdjustment","accrualBalanceAdjustmentId","getBalances","AccrualsModule","Address","Agent","AgentService","getAgents","getAgentById","createAgent","agent","updateAgent","deleteAgent","emailRegex","AgentsPageComponent","_agentService","_getAgents","agentInEdit","agentID","addNew","agents","_selectNameField","saveAgent","savedAgent","newAgent","confirmDeleteAgent","AgentsModule","TransmittalOutputType","TransmittalFormat","TransmittalGroupBy","RecipientType","AttachmentType","TransmittalOutputTypeButtonLabel","PaymentPackageRecipient","newRecipientType","newContactID","newFullName","newAddress","newEmail","newCompanyName","TransmittalOutputTypeOption","textLabel","ContactModalService","ContactRoleService","_roles","ContactListModalComponent","_contactModalService","_roleService","_loadContacts","compare","contactsTrackBy","AttachmentInfo","newEntityTypeID","newAttachmentID","newEntityID","newFileName","newFileExt","AttachmentTypeID","CustomeEmailTemplateService","getEmailTemplateFields","RecipientTypePipe","ReviewPaymentPackageModalComponent","_transmittalService","_customEmailTemplateService","package","availableAttachments","previewMode","completedByUserID","emailText","emailSubject","editingEmail","getReviewData","apFeedAttachments","subjectHasChanged","backupSubjectTemplate","emailSubjectTemplate","emailHasChanged","backupTextTemplate","blobCallback","previewAnyway","attachmentSizeWarn","allResult","previewData","templateFieldResult","emailTemplateFields","isLateBound","validInSubject","emailTextTemplate","errResult","onAttachmentChange","beginEditEmail","cancelEditEmail","saveEditEmail","originalEmailSubjectTemplate","originalEmailTextTemplate","emailTemplate","lockedForOverrideEmail","addBindingCreated","quillInstance","editorInstance","insertFieldInBody","cursorPosition","insertText","contentChange","change","insertFieldInSubject","templateSubject","cursorPosStart","cursorPosEnd","textBefore","textAfter","skipSizeWarning","firstValueFrom","TransmittalService","showPaymentPackageReviewModal","paymentPackage","EntityAddress","entityAddressCorrespondences","EntityAddressCorrespondence","EntityAddressDeliverabilityIssueComponent","_modalRef","revise","decision","actionTakenID","givenAddress","suggestedAddress","actionTakenDate","ignore","unavailable","AddressDetailsModalService","getEntityAddresses","entityString","getEntityString","getCorrespondenceTypes","updateEntityAddresses","entityAddresses","getEntityAddressDeliverability","entityAddress","AddressDetailsModalComponent","addressDetailsModalService","justSelect","_setupCorrespondenceTypes","editEntityAddress","entityAddressesToRevertTo","isEditing","deleteEntityAddress","cancelAddEdit","newEntityAddress","_addCorrespondenceTypes","checkDeliverability","_determineEntityAddressDeliverability","defaultSelected","entityAddressClicked","indexClicked","addCorrespondence","correspondenceType","entityAddressCorrespondence","correspondenceTypeID","entityAddressID","correspondenceTypes","removeCorrespondence","correspondence","editedAddress","addressDeliverabilityDecision","_correspondenceTypes","_getUpmsAddressString","line1","line2","zip","country","_getAddressString","address1","address2","upmsValidatedAddress","deliverability","validated","upmsServiceIsAvailable","AddressDetailsModalLaunchService","openAddressDetailsModal","isAbleToBeEdited","TransmittalDetailsComponent","addressModalService","upgradeNavigationServiceHandler","selectedPackage","paymentPackageRecipients","recipient","currentBillAttachment","getPropertyTypeName","getTotalAmount","previewBill","downloadBill","downloadInfo","transmittal","paymentTransmittalItems","backClickedUI","backClicked","goToTransmittal","selectedTransmittalID","currentTransmittalIndex","paymentTransmittals","paymentTransmittalID","currentTransmittal","transmittalCollector","collectorAddresses","collectorAddress","slideChanged","isInit","editCollectorAddress","preventCarouselFromInterceptingSpace","PaymentBatchService","_paymentBatchRepo","getPaymentBatches","Id","getPaymentBatchDetailsWorkflowStatus","_this28","_this29","_this30","_this31","_this32","_this33","_this34","shippingMethods","_this35","FinalizePaymentPackageModalComponent","transmittalService","paymentBatchService","websocketListenerService","utilities","statusChangeSubscription","tooManyOutputsError","finalizePaymentPackageModal","setupModal","cancelExecutionLoop","originalSelectedPackages","selectedPackages","prepareOutputTypes","outputTypeOptions","packageList","outputTypes","selectedOutputType","selectedOutputChanged","finalizeHasErrors","transmittalOutputType","successMessage","warningMessaage","isFromPaymentBatch","setParentLoading","transmitPackages","hasPackageFinalized","itemCount","flatMap","pp","pt","threshold","paymentPackageFinalizeLongRunningThreshold","transmitPackagesLR","paymentPackagesToFinalize","executionLoop","nextPackage","packageNumber","transmitPackage","lrId","originalRequestRoute","paymentPackages","subscribeLR","isPlural","lrProcess","finalizeResults","processTransmitResult","lrResultObject","downloadAttachments","newPackage","isFinalized","packageToFinalize","addButtonLabel","PaymentPackagesComponent","messageBox","refreshList","isPrelimApFeed","returnButtonText","saveButtonText","setFinalizeLoading","hideCancelHyperlink","finalizeLoadingMessage","finalizing","processingCancelled","getPaymentPackagesByDraftID","getPaymentPackagesByCompanyID","showDates","getPaymentPackageDetails","getPaymentPackagesByPaymentID","shouldShowSelectAll","closeChildModals","finalizePaymentPackagesModal","preparePaymentPackages","showDetails","newTransmittalID","paymentTransmittal","transmittalItem","draftIDParam","serializedDraftIDs","draftIDs","toggleSelectAll","packagesWithRequests","paymentPackageFinalizeRequestId","packageIdsWithRequests","checkResult","alreadyProcessedLrIds","paymentPackageIndex","plural","packageFinalized","transmittalType","openContactModal","recipientObject","tempRecipient","openReviewModal","selectRow","showSaveButton","removeRecipient","recipientItem","removeTransmittal","transmittalIndex","getRecipientCount","recipientList","getCompletePackageCount","setHoveredRecipient","hoveredRecipient","navigateToActionView","cancelPackages","returnToActionView","finalizePackages","goToDetails","selectedTransmittal","updateValue","paymentItem","recallPackage","isRecalled","finalizedPackages","draftId","unlockPackage","navigateToCompany","PaymentPackageAttachmentSummaryComponent","summary","goToPackage","TransmittalModule","AppealStatusID","ComponentFilter","AnnualDetailsNavigationEventService","_onEventReset","goToAssessment","_subjectAssessment","goToAppeal","_subjectAppeal","goToTax","_subjectTax","goToRefund","_subjectRefund","goToFiling","_subjectFiling","refreshActivityData","_refreshData","refreshAnnualYear","_refreshAnnualYearData","goToGrid","_goToGridData","setYears","_yearsData","refreshAccrualDetailsLink","allPaymentsExcludedFromAccrual","_refreshAccrualDetailsLink","assessmentEvent$","appealEvent$","taxEvent$","refundEvent$","filingEvent$","refreshEvent$","refreshAnnualYearEvent$","goToGridEvent$","yearsChangedEvent$","refreshAccrualDetailsLinkEvent$","AssessmentNavigationInput","AppealNavigationInput","TaxNavigationInput","taxID","FilingNavigationInput","AttachmentModalData","AttachmentModalEntityData","Appeal","AppealStatus","appealStatusID","isClosedStatus","appealStatuses","AnnualDetailsService","_numberPipe","_currencyPipe","getAnnualYears","getAnnualYearByID","getComplianceDisplay","filingTypeId","yearSummaries","moreThanOneFilingOfThisType","filingHasTaskSeries","allTasksCompleted","getComponentsFromYears","saveYear","calcProjected","annualYear1","orderRevisions","annualYearId","orderedAnnualAssessmentIDs","formatYearDateDisplay","nonCapComponents","componentList","viewTaxableValues","assessmentClassComponentID","capComponents","getComponentName","componentTypes","compFromCompTypes","getDisplayAssessment","found","formatSavings","extraChars","getTotalFMV","nonDeletedComponents","roundedFMV","decimal","parseFMV","preNavigateWarn","editState","getDirty","entityLoading","saveHandler","cancelHandler","taxableValueNames","maxIndex","getMaxNumberOfTaxableValues","taxableValues","maxNumberOfTaxableValues","numberOfMissedYears","missedYears","detail","TaskService","AppealService","annualDetailsService","getStateAppealLevels","getAppealsForAnnualYear","getAppealView","annualDetailYear","annualYearView","saveAppeal","createAppeal","deleteAppeal","loadTaskSummary","viewModel","currentTaskSummary","loadingTaskSummary","currentAppeal","taskSummary","setCurrentAppeal","appealIndex","setAppealIndex","currentAppealIndex","resetEdit","updateModalData","setAppealByAssessmentID","addNewAppealToViewModel","saveAppealFromViewModel","cancelAppealEdit","toggleAppealEdit","beginEdit","setSavings","annualYearModel","savingsOverridden","revisionAppealed","revisionAppealedFMV","isClosed","anticipatedFMV","_getSavingsBaseRate","savingsBaseRate","minus","outcomeRevision","outcomeAnnualAssessmentID","annualAssessmentId","outcomeRevisionId","appealStatusId","newSavings","addPrepareApplicationTasks","getAppealViewModelByYear","defaultAppealID","buildAppealViewModel","getAppealViewModelByAppealID","appealView","appealLevels","appeals","showTabs","AppealViewModel","stateAppealLevels","latestAppealIdx","latestAppeal","addDate","submitEvidenceValid","informalHearingValid","hearingValid","resetDateTimeHandler","preEditModelBackup","assignFromExistingAppeal","appealLevelAbbrDisplay","appealLevelID","appealLevel","appealLevelLitigationDisplay","litigation","setParcelDetails","invalidTimes","savingsDate","BillClusterService","getRefundViewByID","paymentPropChanged","payment","possibleAmount","calcPaymentAmount","grossPayment","discountAmount","penaltyAmount","interestAmount","toDecimalPlaces","saveRefund","deleteBillCluster","deleteBill","deleteRefund","getAnnaulAssessmentsByAnnualYearID","savePaymentAttachment","getAccrualDetails","updateAccrualDetails","addAccrualAdjustment","updateAccrualAdjustment","deleteAccrualAdjustment","overrideAccrualTrueUp","getCollectorEntityAddressesForBillCluster","getOneBill","getBillViewByID","billViewDTO","bill","getTabFromBillCluster","getBillForView","payments","showExtraFields","getShowExtraFields","collectorPaymentOptionID","areAllPaymentsExcludedFromAccruals","clusterPayments","showPaymentFields","checkDate","checkNumber","postDate","accrualBegin","originalAccrualBegin","isSame","accrualEnd","originalAccrualEnd","directAsmt","accrualsExclude","paymentAmount","collectorPayment","billAmount","displayProrationPct","prorationPct","getPaymentOptionsForView","collectorPaymentOptions","getTaxesForAnnualYear","yearID","getBillClustersForAnnualYear","getRefundsForAnnualYear","billTabs","refundTabs","tab","taskSummariesPromise","getTaskSummariesForTab","getOneTab","saveTab","newBill","refundAmount","createRefund","saveBillCluster","saveOneBill","collectorPaymentOption","saveBill","getEntityTaskSummaries","getTaskSummariesForBill","showActualCheckbox","EntityID","EntityTypeID","paymentTask","OriginalEntityID","Status","taskSummaries","setTabIndex","currentTabIndex","currentTab","cancelTaxesEdit","saveTabFromViewModel","toggleTaxesEdit","setCurrentTab","setCurrentTabByRefundID","getTaxesViewModelByYear","buildTaxesViewModel","getBillViewModelByBillID","buildBillViewModel","getRefundViewModelByRefundID","buildRefundViewModel","validateBills","annualyearid","getCollectorPaymentOptionsForParcel","collectorBillID","collectorBillScenarioID","taxesTabs","TaxesViewModel","BillViewModel","billForView","yearRevisions","hasAvailableTaxSetup","RefundViewModel","isDifferentTab","tempTab","j","validateTaxes","assignFromExistingBill","assignFromExistingRefund","Assessment","revisionNumber","annualAssessmentDetails","revisionNum","AssessmentService","getAssessment","getAssessmentViewModelByID","buildAssessmentViewModel","getAssessmentViewModelByAssessmentID","getAssessmentComponent","saveAssessmentFromViewModel","dirtyAnnualYear","dirtyTargetValue","detailModel","saveAssessment","prepareAssessmentForSave","deleteAssessment","cancelAssessmentEdit","annualAssessment","annualAssessmentCopy","fmvOverridden","ratio","assessmentClassRatio","assessmentRatio","areDeadlinesEqual","appealDeadline","original","originalDeadline","totalAV","assessmentDetail","toggleAssessmentEdit","prepareAnnualAssessmentForCreate","prepareAnnualAssessment","AssessmentViewModel","assessmentService","preEditTargetValueBackup","targetValue","setEditBackup","AssessmentChanged","attachmentIcon","assignFromExistingAssessment","isActual","recalculateVariables","lastAssessment","isLastAssessment","displayRatio","ComplianceService","getFiling","getFilingBatchInfo","getFilingBatchInfoForAnnualYear","getFilingsForAnnualYear","getAvailablePriorFilings","createFilingBatch","createFiling","updateFiling","deleteFiling","getFilingView","getFilingTypes","getFilingTypesByParcel","getReturnForFiling","isInFilingBatch","_filingBatches","getFilingBatch","getTaskEntityType","getTaskEntityId","getReturnStatusCode","filingBatch","setCurrentFiling","filingIndex","setFilingIndex","currentFilingIndex","currentFiling","filingBatches","returns","currentReturn","loadFilingBatch","addNewFilingToViewModel","saveFilingFromViewModel","cancelFilingEdit","toggleFilingEdit","getComplianceViewModelByYear","masterParcelId","parcelLinkageTypeId","defaultFilingId","filings","filingTypes","_buildComplianceViewModel","showAllocationButton","getComplianceViewModelByFilingId","filingView","ComplianceViewModel","dueDateValid","assignFromExistingFiling","filingType","isFromConsolidatedParcel","AnnualBudgetService","getAnnualBudget","annualBudgetId","updateAnnualBudget","annualBudget","deleteAnnualBudget","addAnnualBudget","getAvailableBudgets","saveAnnualBudgetFromViewModel","cancelBudgetEdit","toggleAnnualBudgetEdit","getAnnualBudgetViewModelByID","buildAnnualBudgetViewModel","AnnualBudgetViewModel","ViewTarget","AnnualDetailsNavigationService","appealService","complianceService","annualBudgetService","navigationEvent","createNavigationState","navigationState","NavigationState","initializeGrid","setEditMode","toggleEditHandler","resetVMs","viewTarget","refreshGrid","resetYearsHandler","goToAppeals","currentRevision","appealViewModel","currentAppealVM","refreshActivity","additionalNotificationMessage","goToTaxes","taxesViewModel","currentTaxesVM","refundRowVersion","savedBill","assessmentVM","currentAssessmentVM","newAssessment","goToCompliance","complianceVM","currentComplianceVM","compliance","goToBudget","annualBudgetVM","currentAnnualBudgetVM","showEditControls","AnnualDetailYearList","AnnualDetailComponent","ANNUAL_DETAILS_HELP","ParcelActivityModalService","AnnualDetailsGridComponent","billClicked","revisionClicked","appealClicked","complianceClicked","budgetClicked","clickableTaxClass","expanded","taxIsEstimated","isFromConsolidated","complianceFilingTypeSummaries","notAllowedIfConsolidated","EntityInProgressIndicatorComponent","onIndicatorHover","intakeItems","getProcessingUrl","AddAppealModalComponent","addAppeal","addAppealModal","showModalInit","newAppeal","AppealComponent","appealApplicationService","skipTaskAppealStatuses","viewModelChanged","hasRyanPrivateEdit","hasRyanPrivateView","isRyanInstance","isRyanLegalServiceEnabled","enableInvoiceRLS","checkDefaultAppealID","submitEvidenceDateElement","informalHearingDateElement","hearingDateElement","appealPreviousStatus","appealHeading","getAssessmentDescription","getAppealStatus","canPrepareApplication","ReadyTaskTypes","canCreateApplicationForm","getAppealOutcomeRevision","setDefaultOutcomeRevision","appealedRevision","nextRevision","appealOutcomeRevisionChanged","calculateSavings","appealStatusChanged","newAppealStatusID","newStatusInTheList","previousStatusInTheList","changeStatus","staleAppealStatus","isEditable","showSubmitEvidence","HasSubmitEvidence","showConfirmHearing","HasConfirmHearing","showInformalHearing","HasInformalHearing","showHearing","HasFormalHearing","isStatusADate","openCallback","taskReadonly","shouldReload","appealTaskValidation","staleAppealSavings","savingsChanged","isCalculatingSavings","savingsBlur","revertToOriginalSavings","openAddAppeal","switchTabs","appealTabs","onSubmitEvidenceValidationChange","onInformalHearingValidationChange","onHearingValidationChange","showBrokenChain","loaded","onTaskRelevantFieldChanged","changeAppealLevelObj","navigateToAppealApplication","hasApplicationForm","ParentheticalCurrencyComponent","AccrualRowActionEnum","AccrualDetailModalComponent","modalRef","_billClusterService","showBalances","accrualDetail","_mapUIRows","setupRowMenu","rowMenuItems","subsequentRows","accrualDetailRows","precedingRow","followingRow","_getAddBeforeItem","_getAddAfterItem","_getOverrideItem","NoAction","performRowAction","AddRowBefore","AddRowAfter","newRow","isAddAdjustment","isReconcileRow","idxToInsert","originalRow","isEditOverridden","currentlyEditing","updateAccrual","updateRequest","accrualAdjustmentMethod","billClusterAccrualSetupRowVersion","fullyExpenseNext","billClusterRowVersion","updateShowBalances","setClass","saveAdjustment","_saveOverride","_saveAdjustment","revertTrueUp","editAdjustment","isEditAdjustment","cancelAdjustment","removeRequest","isPrior","_getIsPrior","getDateRange","beginDate","durationText","_getDurationText","accountingDurationType","Override","shouldRevert","overrideRequest","revert","trueUp","adjustmentRequest","reconcileDescription","nextRow","Payment","parentExcludedFromAccruals","Bill","BillCluster","Refund","BillImageModalComponent","billId","ParcelTaxRateService","getAvailableTaxRateAreas","parcelCollectorId","getAvailableTaxAuthorities","getAvailableTaxRateAreasByParcel","getAvailableTaxAuthoritiesByParcel","getCollectorsByParcelId","parcelid","getAvailableTaxRateAreasForBillCluster","getAvailableTaxAuthoritiesForBillCluster","getTaxRateSetup","getTaxRateDetails","processingBill","searchTaxRateSetup","searchTaxRateSetupByParcel","searchTaxRateDetails","billOverride","getCollectorTaxRateDetails","saveTaxRateSetup","saveTaxRateDetails","getFirstEncounterData","saveFirstEncounterData","TaxRatesService","setIsGroupByEnabled","isGroupByEnabled","getIsGroupByEnabled","ParcelCollectorTaxRateSetupModalComponent","parcelTaxRateService","taxRatesService","loadingAll","groupByCategory","newTaxAuthorityId","enableTrueRateBasedSystem","displayYear","overrideSetup","modelPromise","getTaxSetupByRateArea","getTaxSetupByAuthorities","ta","availableTaxAuthorities","availableTaxRateAreas","originalTaxAuthorities","originalTaxRateAreaId","tra","onModelChange","onTaxRateAreaTextChange","taxRateAreaInputRef","clearSelectedTaxRateAreaId","onTaxRateAreaIdChange","addNewTaxAuthority","newAvailableTaxAuthority","newTaxAuthority","getTaxAuthority","removeTaxAuthority","skipDirtySet","filteredAvailableTaxAuthorities","avail","totalRate","totalEstimated","distinctCategoryIds","taxAuthorityCategoryId","currentTaxAuthorityGroups","onDisplayYearChange","onGroupByCategoryChanged","isDocumentProcessing","taxRateAreaName","taxRateAreaCode","taxAuthorityCount","modalResultSubscriber","onNewTaxAuthorityChange","rateClass","taTooltip","taxableAssessmentTypeName","taxableAssessmentTypeId","taxableAssessmentType","taxAuthorityCategoryName","taxAuthorityCategory","BillClusterTaxRateSetupModalComponent","firstEncounterTaxAuthority","getTaxDetailsByRateArea","getTaxDetailsByAuthorities","getTaxDetailsForParent","getCurrentTaxDetails","processingParcelTaxSetup","usingParentRates","refetchTaxDetailsForAuthorities","refreshFromModel","onUsingParentRatesChanged","confirmed","confirmSwitchToParentRates","shouldClose","getModalResult","showFirstEncounter","startFirstEncounter","endFirstEncounter","hasProcessingChanges","inProcessTaxSetupChanges","firstEncounterSavedCallback","TaxRateSetupModalLaunchService","parcelCollector","subscriber","openParcelCollectorTaxRateSetupModal","openBillClusterTaxRateDetailsModal","billEstimated","intakeAttachmentId","PaymentPackagesModalComponent","paymentPackageModal","onHide","ctx_r92","ctx_r118","ctx_r130","ctx_r137","ctx_r146","ctx_r154","ctx_r170","ctx_r179","BillsComponent","addressDetailsModalLaunchService","featureFlagService","tempVals","allowEdit","enableTaxPaymentAddressLink","foundState","stateIsSupplemental","supplementalTaxBill","showActualRow","showActualCheckboxRow","changeFields","calculateShowFirstEncounterIndicator","assocRevisionChanged","_atLeastOnePaymentinQC","paymentDuePadding","paymentsWithDueDatesChanged","dueDateIsInPast","dueDateIsLaterThanOriginal","detailPromise","makeDetailPromise","processingTaxSetupResult","showFirstEncounterIndicator","RevisionChanged","deletePayment","gridNavigationHandler","makeDiscountNegative","zeroIfNull","makeExemptionNegative","exemptionAmount","dateOverridden","_getOriginalDate","getBillPaymentOptionName","billAmountBlurred","oldBillAmount","_distribute","captureVal","divide","numerator","divisor","dividend","amtWithRemainder","neg","grossPaymentChanged","paymentIdx","previousPayments","subsequentPayments","totalAllocation","notProcessed","previousGross","editablePaymentIDs","subsequentPayment","paymentAmountIsEditable","evenDist","_setBillAmountToSumOfPayments","firstPayment","_isTransmitIncomplete","processedDate","billPropertyIsEditable","collectorPaymentID","disablePaymentOptionDropdown","TaxBillReceived","ReviewPaymentComplete","disableAssocRevisionDropdown","billHasTaskSummary","_atLeastOnePaymentTransmitted","addPayment","newPayment","paymentAmountChanged","paymentAmountBlurred","revertIfNegative","penaltyOrInterestAmountChanged","paymentOptionChanged","AnnualDetailsSaveAllowedChanged","tempBillAmount","savedBillIdx","_getTaskSummariesForBill","launchTaskModalBill","autoSaveAndPerformAction","showToast","launchTaskModalAndReload","reloadOnModalClose","updateSingleBill","updateSavedBill","getCommentModalData","getAttachmentModalData","paymentPropertyIsEditable","paymentOptionIsEditable","changeActual","revertDirectAsmtIfInvalid","maybeRevertToOriginalDate","calcProjectedChanged","updatedBill","showExcludeFromAccruals","bc","excludeFromAccrualsChanged","showAutoCalculateCheckbox","showAutoCalculateCheckboxRow","showAssocRevision","someBillsAreEditable","assocRevisionIsEditable","someBillsHaveAssocRevision","showSupplemental","showProration","getAssocRevisionDesc","yearRevision","openPaymentStubModal","openParcelCollectorAddressModal","collectorEntityAddresses","taxPaymentCollectorEntityAddresses","openTransmittalDetailsModal","paymentPackagesModal","prorationChange","toSignificantDigits","openTaxRateSetup","currentBill","undoDate","dueDateChanged","originalDueDate","getPaymentBatchDetailsSref","belongsToPaymentBatchId","belongsToPaymentBatchNo","_getDiscount","discountPercent","discount","unprocessed","totalProcessedAmount","processed","remainingAmount","_allocationIsNegative","TransmitComplete","isQCed","QCTaxBillComplete","_atLeastThreeIncompleteTransmitPayments","RefundComponent","refundDeleted","_haveLoadedAssessments","loadAnnualAssessmentsByAnnualYearID","annualAssessments","getRevisionDesc","refundAmountChanged","makeRefundNegative","expectedDateChanged","getOriginalDate","capitalizedField","TaxesComponent","isAddBillModalShown","billOrRefund","annualDetailsSaveAllowedChanged","isAnnualDetailsSaveAllowed","AnnualDetailsSaveAllowedChangedX","getBillVM","billVM","getRefundVM","refundVM","addBill","parcelCollectors","getStateCollectors","isStateCollectorsShown","companyCollectors","getCompanyCollectors","getCollectorList","saveBillOrRefund","newBillCluster","addBillModal","reloadVM","cancelAddBillOrRefund","launchAccrualDetailModal","AddRevisionModalComponent","assessmentCreatedEventEmitter","currentAssessment","newAnnualAssessmentDetails","other","checkForEnter","userInput","AnnualYearComponent","currentAnnualDetailAssessment","selectRev","newRevision","activateViewTarget","latestBudgetId","activateAddRevision","promptAutoSave","loadingImage","createNewAssessment","hasStrikeThru","ngClass","totalAppealCountForYear","notActual","latestRevision","activeNotActual","rev","getComplianceFilingType","complianceId","notReceived","createdAssessment","createdAnnualDetailAssessment","ReorderRevisionsModalComponent","_annualDetailsService","assessmentsReorderedEventEmitter","orderedAssessmentIDs","AllocationService","navigationParcelId","_parcelId","createAllocation","createModel","AssessmentComponentExemptionPipe","FmvInputComponent","isOverriddenChange","internalValue","internalIsOverridden","modelChanging","resetIt","internalValueFormatted","ADD_COMMAS_REGEX","REMOVE_COMMAS_REGEX","_processInternalValueChanged","originallyOverridden","periodInput","tempValue","filterFunction","allowOverrides","allowNegatives","annualDetail_r38","annualDetail_r92","annualDetail_r141","annualDetail_r194","AssessmentComponent","_allocationService","_assessmentService","_taskService","_messageBox","_changeDetector","_navigationEvent","_exemptionPipe","hasAllocationFeature","enableAllocationFeature","isPPParcel","setVariablesFromViewModel","popoverDirection","getSortedAnnualAssessmentDetails","getTaskSummaries","getAllocationTaskSummaries","appealByIsInPast","appealByIsLaterThanOriginal","isTargetValueGreaterThanTotalFmv","typeIdsToReject","getTotal","setRevisionName","revisionName","revisionOtherName","originalRevisionName","renamePopover","validateRevisionName","launchRevisionReorder","refreshAssessmentData","componentRatioChange","getUnusedComponentTypes","compType","compTypeIsInUse","annualAssessmentDetail","alternateComponentAlreadyInUse","taskSummariesLoaded","allocationTaskSummaries","allocationTaskSummariesLoaded","shouldReloadTasks","isDeadlineOverridden","revertDateCheck","canEditTable","_isAdjustNoticeReady","_isObtainPostDeterminationReady","isIDP","showComponentDropdown","calcDisabled","disableCalc","someExem","getFairMarketValue","trimmedValue","parsedAssesedValue","parsedRatio","annualDetail","calculate","filterNumber","_recalculateTaxableValues","negative","clean","maybeRevertToCalcRatio","revertToCalcRatio","undoCalcRatio_Click","makeOverridden","addRow","valuesToAdd","vmToUse","assessmentClassID","newComponent","deleteComponent","autoCalculateRefresh","currentYearCarryover","targetValueChanged","onAppealDeadlineChanged","appealByChanged","blurPopover","resetAppealDeadline_click","goToAllocation","hasAllocation","_createAllocation","launchAllocationTaskModal","AdjustNoticeIsReady","ObtainPostDeterminationReady","_busyIndicatorMsgManager","refreshResult","_getUniqueTaxable","uniqueTotals","taxAuthoritiesInfo","taxableComponents","assessmentClassComponent","isLandComponent","exemptionComponentIds","assessmentComponentID","allComponents","taxableTotal","alternativeAV","AddYearModalComponent","initializeYearData","yearsList","currentYears","parcelHasYears","latestYear","earliestYear","yearsArray","saveEnabled","addYearModal","ComplianceReturnAddComponent","_complianceService","priorFilings","priorFiling","priorReturnSelected","isAmendment","priorReturnId","priorReturnChanged","ClientServiceResponsibilityService","_httpClient","_clientServicesChangedSubject","notifyClientServicesChange","clientServiceID","saveEntity","getAvailableTransmittalFormats","getAvailableFeedSpecs","getPackageEmailTemplates","getTopLevelPropertyTypes","getPackageCovers","retryWorkflowUpdateFromQueue","req","clientServiceId","doesEntityHaveErrantResponsibilities","FilingBatchService","editGroup","filingBatchChange$","_filingBatchSubject","_filingBatchId","_filingBatchStatusChangeSub","notifyFilingBatchStatusChange","isNotStarted","processStatus","isStarted","isLocking","isUnlocking","isFinalizing","isSigned","isSigning","isUnsigning","isReadOnly","isLongRunningProcessActive","hasLockError","hasFinalizeError","getProgressStatusDisplay","notifyFilingBatchFilingsChange","viewTasks","filingBatchUpdate","getListByAvailableToMoveFilings","nextYearInfo","moveModel","amendModel","setExpandedComponent","_expandedComponent","isComponentExpanded","isOtherComponentExpanded","Filing","AddFilingModalComponent","addFiling","addFilingModal","filingTypesDropdown","newFiling","creatingFiling","ComplianceComponent","_clientResponsibilityService","_filingBatchService","canCreateFilingBatch","_hasComplianceFeaturesView","_hasAssignee","returnPreparationAllowed","SeriesIsComplete","responsibility","entityClientServices","responsibilities","workflowUserTypeID","dueDateElement","showModalFn","getFilingHeading","getFilingBatchPrepareLabel","_afterTaskModalClose","openAddFiling","filingTabs","onDueDateValidationChange","dueDateOverridden","filingDeadline","resetDueDate","goToFilingBatchDetails","goToReturnFilingBatch","returnAccessPath","AnnualBudgetComponent","availableCompanyBudgets","filteredCompanyBudgets","cb","budgetOverlaps","overlappingCompanyBudgets","nonOverlappingCompanyBudgets","selectedBudgetToAdd","standardAssessmentComponents","assessmentComponents","alternativeAssessment","budgetAssessmentTotals","paymentDueDates","taxCollectors","taxPayments","totalPaymentAmount","totalPayment","getCollectorPaymentAmount","selectedBudgetChanged","deleteBudget","tryDelete","addNewBudget","AnnualDetailsComponent","annualDetailsNavigationService","parcelActivityModalService","forecastingBudgetingService","settingsGroup","viewTaxableValueSavedSetting","_viewTaxableValueSettingName","isViewTaxableValuesEnabled","preLoadAnnualYearID","getParameterValue","getYearData","checkNavigationParameters","ensureYearLoaded","hasYear","annualDetailsSaveAllowed","annualYearIDs","maximize_click","unmaximize_click","annualYearParamID","_setNavigationBasedOnAnnualYearId","taxYearParam","_setNavigationBasedOnTaxYear","searchForYear","annualGridYearsInfo","totalYears","getFilingTypesFromYears","yearList","vanillaYears","toggleEdit","saveEdit","aDValidation","parsedName","decodeURIComponent","assessmentModelChange","changedAssessment","changedComponent","openParcelActivityModal","onViewTaxableValueChange","AnnualDetailsModule","ngx_bootstrap_buttons","TeamService","includeUsers","shouldIncludeUsers","_TEAM_URL","editTeam","deleteTeam","createTeam","getMembersForTeam","_USER_TEAM_URL","getDocumentIntakeUserTeamsOnly","entityIds","getUserDefaultTeam","_getAllUserTeams","getAllForGroup","TeamUI","Team","practiceArea","TeamsPageComponent","dataLoading","hasTeamEditPermissions","showUniqueTeamNameError","enableEdit","originalTeam","saveTeam","teamToSave","savedTeam","unableToDeleteTemplate","teamMembers","unableToDeleteRef","teamMembersLoading","TeamAssignmentPanelComponent","_teamsService","_instanceId","contactFilter","_assignedTeams","assignedTeamsToChoose","allChoosableTeams","_allTeams","_cleanAssignedTeams","TeamModule","TaskTypeID","PROP_TYPE_COMP_MAP","IdpService","billAmountDoesntAddUp","billDetail","billDetailCopy","_mapBillFromIdp","grossPaymentSum","isDueDateMismatch","installments","installment","discountIndex","_getInstallmentAndDiscountIdx","pmtIdx","ocrPayment","possibleDueDate","isMissingPaymentDueDate","mapBillVMFromIDP","getDiscount","netAmount","mapAssessmentVMFromIDP","assessmentChild","postMappingFlags","disableApplyAll","lowerConfidence","enabledComponents","idpComponents","valueStr","nonZeroIdpComponents","_divvyUpIdpTotal","_mapComponents","nonZeroIdpExemComponents","assessedValueAmount","idpComponent","inUseComponent","fmvAddsUp","equals","availableComponent","totalAmount","calculateStr","componentStr","componentType","componentsOfCertainType","propTypeComponent","landComponent","totalMinusLand","dividedLeftoverAmountWholeNumber","remainder","remainderToAdd","idpPayments","idpPayment","directAssessmentAmount","interest","penalty","IdpDetailCardComponent","IdpBillDetailModalComponent","_idpService","confidence","_billDetail","_idpResults","billCard","_cardValues","card","modalContainer","applyAll","OcrApplyAll","_getAssocRevisionDesc","_getBillPaymentOptionName","IdpAssessmentDetailModalComponent","isNum","_assessmentVM","_assessmentRevision","assessmentRevision","avComponents","fmvComponents","ratioComponents","vallArra","fmvTotal","avTotal","exemRows","exemTotalRow","IdpConfidencePanelComponent","_scope","canSeeDetails","confidenceLevel","seeDetails","_seeBillDetails","_seeAssessmentDetails","idpAcceptedBill","_originalBillDetail","idpAcceptedAssessmentDetail","_originalAssessmentDetail","updatedBillModel","disableAssessmentApplyAll","updatedAssessmentVM","clonedAssessment","DataEntry","attachmentDescription","completeReadyTask","useDocumentAsBillImage","readyTaskID","dataEntryChanged","searchAnticipated","completeReadyTaskChanged","taxSetup","GenericEntityVM","EntityEditComponent","_appealService","_util","verifiedChangedEntity","_getInitEditState","retrieveEntityJSON","forComplete","wrappedFirstEncounterSavedCallback","initialBillRowVersion","finalBillRowVersion","initialBillClusterRowVersion","finalBillClusterRowVersion","anticipatedTaskPromise","_handleAnticipatedTask","entityIdentifier","displayEditPanel","buildVMPromise","dataEntryFiling","_parseJSON","_processDataEntry","_resetVMs","dataEntry","appealVM","dataEntryBill","showExtraBillFields","showOcrResults","hasBeenReceived","hasBeenTransmitted","savedByUser","dataEntryRefund","dataEntryAssessment","enableIdpAssessment","_setGenericEntityVM","dataEntryFallback","isReadyTaskAnticipated","genericEntityVM","shouldShowConfidencePanel","billRevisionChangedX","verifyChangedEntity","anyCalcProjected","assessmentModel","newEntry","attachmentYear","onCompleteReadyTaskChange","updatedIdpBillModel","idpAcceptedAssessment","updatedIdpAssessmentVM","intakeBatchItemNumber","targetEntityTasks","readyTaskName","isReadyTaskReviewBill","aid","isMatchAnticipated","isMatchReviewBill","readyTask","tid","inputJSON","ProcessingDetailEditState","setDirtyHandler","DocumentProcessingModule","ProcessingService","ChangeDueDateModalComponent","_processingService","optionID","dueDateText","dueDateTextOptions","RetrievalStatusPayload","ignoreRetrievalStatus","ignoreFollowUpDate","followUpDate","RetrievalStatusService","getRetrievalStatuses","getRetrievalStatusIdsByTaskIds","setStatus","UserTeamPickerComponent","teamService","onDocumentKeydownEnter","isUserObjRemoved","areIdsRemoved","selectedUserName","parentUsers","_getUsers","revertIfEmptyOnBlur","userChange","selectItem","showDocumentIntakeUserTeamsOnly","FollowUpChoice","InvoiceTypes","InvoiceRouteNames","OverrideStatus","SetDocumentRetrievalStatusModalComponent","retrievalStatusService","datePipe","daysOptions","setComputedDate","followUpChoice","followUpChoices","retrievalStatuses","retrievalStatusId","uniqueRetrievalStatuses","retrievalStatusPayload","selectedUserInfo","setComputedDataFromSelect","followUpInXdays","isoWeekday","computedDate","_setPayload","recreateComment","generatedComment","_getCommentBody","DAYS","NO_FOLLOWUP","RetrievalStatusModalService","launchSetDocumentRetrievalStatusModal","setDocumentRetrievalStatusModalRef","RevenueShare","invoiceId","allocationPct","displayAllocationPct","costCenter","costCenterTeamId","engagementNum","isAccountHandler","optionalIdentifier","feeAmount","invoiceAmount","InvoiceService","numberPipe","contractServiceName","contractServiceType","getInvoice","invoice","calculateInvoiceData","getInvoiceForTask","refreshInvoice","originalInvoice","appealIDs","finalInvoice","otherParcelFMV","includeOtherParcels","resetFromAppealData","saveInvoice","completeInvoice","deleteInvoice","getInvoices","getReadyInvoiceAppealSavingTasksCount","getReadyAdminFeeInvoiceCount","bulkInvoicePreCheck","createInvoices","createCompanyAdminInvoices","removeAppeal","removedAppeal","finalFMV","preserveOverrides","savingsTotal","_appealsSum","calculateFMVFields","previousFMVStatus","previousFMV","calculatedPreviousFMV","invoiceFMVStatus","invoiceFMV","calculatedInvoiceFMV","fmvChange","fmvChangeStatus","savingsStatus","taxRateStatus","contingencyPctStatus","feeAmountStatus","contingencyCapStatus","invoiceAmountStatus","isSavingsOverridden","calculatedSavings","contingencyPctOriginal","contingencyCapOriginal","taxRate","calculateTaxRate","calculatedTaxRate","calculateFeeAmount","calculatedFeeAmount","fixedFee","fixedFeeOriginal","fixedFeeStatus","calculateSavingsTaxRate","backupContingencyPct","setDisplayPercentages","setInvoiceStatus","totalFeeAmount","expenseAmount","automaticallyUpdateNotes","notes","generateNotes","resetTotalSavings","calculateInitialTaxRate","totalSavings","initialTaxRate","getCompanyInvoiceDefaults","getSiteInvoiceDefaults","createAdHocInvoice","getDisplayPercent","sourceNum","getRealPercentFromDisplay","tempNotes","uncappedFeeAmount","litigationPostfix","siteAddress","siteState","isAdHoc","displayTaxRate","displayContingencyPct","_showCapOnFees","excludeCap","calcFee","previousFmvTotal","invoiceFmvTotal","invoiceRevenueShareCodes","RevenueShareGridActionCellRendererComponent","revenueShare","AgGridEngagementNumberCellRendererComponent","TeamPickerComponent","useCostCenter","costCenterString","placeHolder","typeaheadField","typeaheadString","costCenterTeamIdChange","itemSelected","teamChange","costCenterChange","AgGridCostCenterCellRendererComponent","AgGridPercentAllocationCellRendererComponent","AgGridExpenseAmountCellRendererComponent","currentInvoice","FeeAllocationComponent","_bsModalService","invoiceService","AgGrid","_allocationChange","rSC","isTotal","_lookupEngagementNumber","expenseIndex","_calculateInvoiceAmounts","canDelete","_delete","newRevenueShare","updateRowData","engagementChanged","aHIdx","rs","_normalizeAllocationPercent","_calculateFeeAmountPercent","_ensureFeeAmountsAddUp","refreshCells","_setTotalRow","difference","percentage","feeAmountSum","feeAmountDiff","feeAmountDecimal","InvoiceDetailsComponent","CalculatedFields","calculatedFieldChanged","fieldChanged","PreviousFMV","revertPreviousFMV","InvoiceFMV","revertInvoiceFMV","FeeAmount","Savings","TaxRate","newTaxRate","revertTaxRate","ContingencyPct","clearContingencyPct","ContingencyCap","ExpenseAmount","FixedFee","shouldCalcInvoiceData","revertFeeAmount","revertSavings","revertContingencyPct","revertContingencyCap","revertFixedFee","includeOtherParcelChange","refreshCurrentInvoice","automatedNoteChange","navigateToParcel","parcelHref","InvoiceRecipientLookupComponent","contractsInvoicesService","getRecipientList","setSelectedRecipient","recipientChanged","selectedRecipient","recipientName","recipientMailingAddress","postalCode","recipientCdsContactId","cdsBillingContactID","ProcessInvoiceComponent","canTransferToRIBS","enableInvoiceUBR","contractTerm","_currentContractTerm","isContractTermOverridden","_isContractTermOverridden","setupPage","currentState","getInvoiceById","taskString","taskList","navigationWarningText","taskIndex","isAppealSavingsInvoice","appealContractTypes","_siteAppealContractTerms","hasLitigationContractTypes","serviceId","hasAppealContractTypes","canChangeContractType","companyContractTerms","currentCompanyContractTerms","companyAppealContractTerms","_calculateCurrentTermId","resultInvoice","companyIDParam","siteIDParam","stashCurrentInvoice","setButtonText","setAttachmentAndComments","isInvoiceCompleted","readyTaskId","companyUrl","siteUrl","taskOnlyEditMode","cachedInvoice","showCompleteButton","readyTaskTypeId","isUBR","closeText","invoiceRecipientLookup","goToSite","goToCompany","_hasChanges","_rejectHandler","_getValidationMessage","newInvoice","calcInvoice","navigateBackHandler","thirdPartyApprovalDate","callInProgress","returnedInvoice","skipInvoice","onContractServiceTypeChange","_updateInvoice","onContractTermChange","contractTermDetail","selectedContractTermDetail","currentContractTermDetailId","InvoiceModalComponent","z","validationMessages","defaultRequest","createInvoice","onCreate","CreateInvoiceModalLaunchService","openCreateInvoiceModal","InvoicePanelComponent","createInvoiceModalLaunchService","creatingAdminInvoices","contractTermsUpdateSubscription","actions","invoices","showSiteColumn","updateSiteReadyCounts","updateCompanyReadyCounts","cancelCreateAdminInvoices","startCreateAdminInvoices","createAdminInvoices","preCheckResult","existingInvoiceCount","handleInvoiceCreate","rowSelected","parcelsReadyForInvoiceCount","sitesReadyForInvoiceCount","isTask","successfulResults","operationResult","errorResults","showError","ProcessingModule","ConsultingEngagementsRepository","getAcceptedEngagements","getEngagements","getEngagementInfo","consultingEngagementId","getConsultants","accept","invite","updatePermissions","updatedPermissions","getUserGroups","InstancePermissionService","CONTACT_API_FRAGMENT","getByContactId","GROUP_API_FRAGMENT","getForConsultingEngagement","INSTANCE_RIGHTS_API_FRAGMENT","InstanceRightsListComponent","onUpdateEditMode","editModeEvent","getUniqueAvailableScreenTypes","unique","isPermissionUsable","closeAddPermission","lookupPermission","screenTypeId","companyInstanceId","rightsId","perm","ir","engagementInstanceRights","VisualState","CompanyContractsModalComponent","_consultingEngagementsRepository","List","consultingEngagements","consultants","availableConsultants","ce","getEngagementStatus","accepted","editModeEventHander","permsBeingEdited","editEngagement","selectedEngagement","setAvailableInstanceRights","visualState","consultant","selectedConsultant","accountHandler","consultantName","Invite","confirmInvite","getPermissionPayload","cancelEngagement","engagementInfo","consultingEngagementCSRs","DXPService","getDXPMode","testDXPSync","IsSyncDxpLocked","DescriptorService","getByCategoryId","useCache","descriptor","getAvailable","usageEntityType","searchAvailableOverrides","getUsedBySite","DescriptorPickerComponent","descriptorService","descriptorId","selectedDescriptor","selectedDescriptorName","AccountingPeriod","AccountingPeriodsRequest","NewFiscalYearRequest","AccountingPeriodsService","httpService","updateAccountingPeriods","addNewFiscalYear","deleteFiscalYear","companyFiscalYearId","_r10","i_r38","AccountingPeriodsModalComponent","accountingPeriodsService","durationTypes","_initPeriodData","fiscalYearIdx","companyAccounting","companyFiscalYears","selectedFiscalYear","originalSelectedFiscalYear","beginDelete","deleting","cancelDelete","_arePeriodsInvalid","fiscalYearName","originalPeriod","addSinglePeriod","periodToAdd","lastExistingPeriod","undeletedPeriods","choosePlacement","placement","newFiscalYearRequest","accountingDurationTypeId","placementChosen","beginningChosen","addFiscalYearClicked","forcePlacement","addFiscalYear","fiscalYear","AccountingPeriodsLinkComponent","AccrualsDescriptorSelectorComponent","selectedDescriptorId","inUseDescriptors","descriptorSelected","onDescriptorSelected","selectedDescriptorIdChange","AccrualsDescriptorsModalComponent","updateInUseDescriptors","removeDescriptor","flatInUseDescriptors","AccrualsDescriptorsLinkComponent","BudgetDescriptorSelectorComponent","BudgetDescriptorsModalComponent","BudgetDescriptorsLinkComponent","CompanySettingsComponent","_dxpService","_statesService","stateNames","siteCharSelectedForExport","siteNumberSelectedForExport","canChangeUseTopLevelCompanyCOA","hasIncomeStatements","useTopLevelCompanyCOATitle","showAllocations","enableResponsibleEntityFeature","enablePaymentBatchDataHub","useParentVendorFlag","useParentVendorCodes","invoiceAppealSavingsFlag","tlCompanyAccrualsEnabled","_getInUseDescriptors","initialCalls","economicUnitTypes","siteCodeEconUnitTypeId","exportFileTypes","entityIsInRyanInstance","canImportData","hasManageConsultingEngagements","showInvoiceAppealSavingsSetting","_originalOptions","selectingState","dateSlashValid","Moment","dateDashValid","isTopLevelCompany","vendorCodeCount","isShowSettings","companyYears","startingYear","companyStates","dxpSyncDisabled","syncDxpLocked","startAddYear","cancelAddYear","companyStateModel","stateSummary","st","invoiceAppealSavingsOverridden","topLevelCompanyInvoiceAppealSavings","requireClientApprovalOverridden","topLevelCompanyRequireClientApproval","toggleSelectingState","showContracts","budgetEnabledChanged","budgetEnabled","accrualsEnabledChanged","exportPropertyChanged","enableAllocationsOverridden","topLevelCompanyEnableAllocations","logAnalyticsEvent","exportProperties","CompanyComplianceComponent","isShowInfo","emitAnalyticsEvent","VendorCodeService","vendorCodeId","AgGridRowCountComponent","supportsSelect","selectedRowCount","totalRowCount","VendorCodeMappingComponent","_vendorCodeService","breadcrumbs","_cellValueChanged","_refresh","setDataValue","vendorCodeValue","vendorCodeID","refreshing","_vendorCodes","showAllCollectors","VendorCodeModule","SiteClassService","_siteClassRepository","getSecondaries","ParcelList","_incomingParcels","_initialize","tiles","_tiles","_parcels","filterInactive","_parcelsRepository","_getTotalsRow","returnCount","originalConsolidatingTypeId","originalConsolidatedParcelId","i1","i2","totalComponents","isFmvInclude","ParcelService","_parcelRepository","_parcelCount","parcelCollectorTaxAuthorities$","_parcelCollectorTaxAuthoritiesSubject","setParcelCollectorTaxAuthorities","parcelCollectorTaxAuthorities","resolveView","taxRateSetup","trs","pc","hasTaxRateSetup","SiteService","_siteRepository","_parcelService","_parcelListSubject","_siteSubject","siteClassSecondaryID","_site","setParcelCount","getParcelCount","hasParcels","updateParcelList","_currentTaxYear","_latestTaxYearLabel","parcelList","_setReportingParcel","reportingParcel","currentReportingParcel","originalIsReportingParcel","externalReportingParcel","_getParcelControlRow","altAcctNum","altParcel2","assesseeName","assessorAbbr","taxPercentDiff","isExternalReportingParcel","setStateId","newId","getStateId","AddSiteModalComponent","_siteClassService","_siteService","addSiteForm","memoryStorage","siteClassPrimary","siteClassPrimaryDesc","siteClassDesc","controls","siteToAdd","newSite","CompanyExplorationComponent","_nagivationService","_retrieveUserSettings","dataPromises","_getWritePermission","isConsultantPerspective","sitesTitle","isTopLevel","companyHasSubsidiaries","childCompanies","doQuickSearch","includeSubsidiaryFlag","includeSubsidiarySitesChanged","companyViewSettings","_COMPANY_VIEW_USER_SETTINGS_GROUP","_COMPANY_VIEW_USER_SETTINGS_NAME","_getNewUserSettings","AddCompanyModalComponent","companyCodeControl","addCompanyForm","accountHandlerUserID","accountHandlerTeamID","accountHandlerSelected","newAccountHandler","markAsTouched","companyToAdd","validationPromises","isCompanyCodeInUse","newCompany","LaunchAddCompanyModalService","addCompany","CompanyInfoPanelComponent","_validationService","UntypedFormGroup","defaultAddress","saveFunc","permissionResult","isIAMEnabled","editLocked","isImplicitAccess","infoForm","isCustomer","crmNumber","iamTenantId","canBeDeactivatedResult","canBeDeactivated","openFilingTaskCount","openAssessmentTaskCount","openTaxBillTaskCount","_saveToServer","_resetActivityStatus","openPaymentBatchTaskCount","companyToSave","savedCompany","COMPANY_INFO_PANEL_HELP","CompanyInfoPanelViewComponent","_addressDetailsModalLaunchService","companyIsActive","inactiveUrl","isCompanyInRyanInstance","isRyanInsanceSelected","shouldDisplayPaymentBatches","enablePaymentBatch","hasInstancePrivateEditPermission","numInactiveSubsidiaries","childCompaniesNotInactive","_setSubHeader","_setSubsidiaries","hasInstancePrivateViewPermission","serverActionChange","launchAddressModal","showInactiveSubsidiariesClicked","showInactiveSubsidiaries","isFavoriting","goToPBCC","fromTlCompany","pbccFilters","tlCompanyIds","subHeader","subCompSiteCount","subsidiaries","CompanyInfoPanelEditComponent","_launchAddCompanyModalService","nonDeletedEntityAddresses","hasMoveCopyPermission","showAddSubsidiary","statuses","launchAddressDetailsModal","_navWarning","addSubsidiary","goToMoveCopy","isMove","HistoryFieldType","OperationType","ChangeHistoryService","getChangeHistoryByEntity","subType","startDateTime","endDateTime","subTypeArg","momentDateFormat","ChangeHistoryModalComponent","changeHistoryService","getHistory","operations","historyFieldType","deserializeTaxAuthorityValue","originalTitlePresent","originalTitle","tmpResult","calendarDisplayDate","sameElse","isCalendarDisplay","getDisplayValue","historyFieldTypeId","ActivityStatus","valueLength","getExpandedDisplayValue","taxAuthorityCode","taxAuthorityName","resolveCSRRelationship","csrProperties","relatedEntityType","parsed","TaxAuthorityId","TaxAuthorityName","TaxAuthorityCode","ChangeHistoryModalLaunchService","openChangeHistoryModal","PropertyTypeService","ClientServiceExceptionRequest","pEntityId","pEntityTypeId","pClientServiceIds","pPropertyTypeIds","pIncludeAll","clientServiceIds","EntityResponsibilityAssignmentChange","workflowUserTypeId","ClientServicesExceptionService","getClientServiceExceptionsForEntity","exceptionInput","saveClientServiceExceptions","updatedExceptions","ctx_r60","ClientServicesExceptionModalComponent","clientServicesExceptionService","consultingEngagementsRepository","clientServicesTypes","workflowUserTypes","initModal","clientServiceExceptions","loadConsultingEngagements","canEditCompanySetup","changeConsultingEngagementFromSelect","changeConsultingEngagement","changeAssignmentSelection","determineShowDatepicker","assignmentSaved","isConsultingClient","propertyTypesChanged","clientServicesChanged","getAssigneeLabelForChildResponsibility","exception","userValue","getAssigneeLabelForResponsibility","changeEntityContext","toggleResponsibilitySelection","enableSaveButton","toggleAllResponsibilitySelections","assignUserValue","updateWorkflowType","applyChanges","dateToSave","showDatePicker","setDateFrom","selectedExceptions","CONSULTING_ENGAGEMENT","workflowUserType","enagagementId","consultantsEngagement","bulkExceptionSetResponse","areNotAuthorized","haveErrors","navigateToEntity","shouldUseConsultingEngagementInstanceId","ClientServicesExceptionModalService","openExceptionsModal","exceptionsModalRef","modalComponent","TaxFeedSettingRepository","DocumentIntakeLicensedClientDetailRepository","getDocumentGroupList","updateSettings","clientDetail","getListAccepted","getListAcceptedForDI","UserGroupService","userType_r10","DeliveryDetailsComplianceReturnsComponent","_teamService","hasCompliancePermission","entityInstanceId","currentData","userSearchInstanceId","maybePopulateBatchUsers","DR_USERS","_isUserEmpty","personalResponsibility","drUserType","_removeUser","currentDataChange","userChanged","newUser","userTypePrefix","getDisplayName","ces","DeliveryDetailsTeamRetrievesComponent","_toasr","showTaxFeedToggle","taxFeedToggleVisible","isSubsidiary","useTopLevelChanged","useTopLevelCompanySettings","topLevelData","ownerEntityID","taxFeedEnabledChanged","taxFeedEnablingMessage","taxFeedDisablingMessage","taxFeedIsEnabledChange","taxFeedToggleDisabled","taxFeedToggleEnabled","DELIVERY_DETAILS_HELP","ctx_r9","DeliveryDetailsPaymentBatchWorkflowComponent","_paymentBatchService","availableWorkflows","currentPaymentBatchData","setCurrentData","selectedWorkflow","paymentBatchTaskSeriesOptionId","setEfAction","workflowChanged","isRequired","setIsDirty","deliveryDetailsFeedSpecsComponent","_clientServicesService","availableFeedSpecs","feedSpecifications","feedSpecificationID","_sortAvailableFeedSpecs","isBillPay","getFeedApplicability","feedApplicability","feedSpecification","apFeed","checkFeed","shouldDisplayDataHub","dataHub","addSpec","specToadd","chosenSpec","includedInEmail","feedSpecificationsChange","removeSpec","DeliveryDetailsConfigureModalComponent","shouldDisplayPaymentBatch","isEntityInRyanInstance","paymentBatchResult","feedSpecResult","clientAbbreviation","paymentBatchData","CustomEmailTemplateModalComponent","sortedResults","packageEmailCustomTemplateSubject","baseTemplateChange","oldSelectedTemplate","selectedEmailTemplate","packageEmailCustomTemplateBody","copySelectedTemplateFields","subjectTemplate","bodyTemplate","PreviewEmailTemplateModalComponent","modules","toolbar","LaunchEmailTemplateModalService","openCustomTemplateModal","onCloseFn","templateBody","packageEmailTemplates","openPreviewTemplateModal","SiteDescriptorSelectorComponent","descriptorFilter","_filterDescriptors","_onChangeFn","_onTouchedFn","_selectDescriptor","onSelected","_descriptorNoResult","onLoadingChange","descriptorIsLoading","descriptorChange","observableOf","selectedDescriptors","SiteDescriptorsListComponent","_descriptorService","availableDescriptorsCount","_numberOfDescriptorsToSelect","allDescriptors","siteDescriptors","descriptorID","numToWord","_numberWord","onDescriptorChange","trackByIndex","removeAllSelectedDescriptors","SiteDescriptorsEditComponent","siteDescriptorsChanged","DeliveryDetailsTransmitComponent","_launchEmailTemplateModalService","_clientServiceResponsibilityService","_setTransmittalDropdowns","_setDeliveryDetailsDefaults","_setCheckboxes","areNoTopLevelSettings","taxBillDeliveryDetailID","showSiteDescriptorsSelector","transmittalFormatID","transmittalGroupByID","launchConfigureModal","transmittalOutputTypeID","paymentBatchDataToSave","currentPaymentBatchDataChange","maybeNullInputs","maxPackageSize","isMaxPackageSize","maxPaymentItemsPerTransmittal","isMaxPaymentItems","isOne","deliveryDetailPerPackageLimitTypeID","deliveryDetailPerPackageLimitTypes","onSiteDescriptorsChanged","siteDescriptorIds","maybeLaunchCustomModal","newPackageEmailTemplateID","oldPackageEmailTemplateID","packageEmailTemplateID","previewTemplate","selectedTemplate","transmittalOutputTypes","transmittalFormats","transmittalGroupBys","packageCovers","transmittalPackageCovers","transmittalPackageCoverId","DeliveryDetailsAssessmentAllocationComponent","_updateAllocationReviewer","_removeAllocationReviewer","allocationReviewerUser","allocationReviewerTeam","allocationReviewerUserID","allocationReviewerTeamID","ClientServicesPanelComponent","_changeHistoryModalLaunchService","_annualDetailsNavigationEventService","_propertyTypeService","_clientServicesExceptionModalService","_csrService","_busyService","_taxFeedSettingRepository","_documentIntakeLicensedClientRepository","_userGroupService","panelData","accountHandlerTitle","isExplicitView","accountHandlerTeam","_formatPersonsName","_consultingEngagementAccountHandlerTitle","isAccountHandlerOverridden","accountHandlerIsOverridden","canLaunchHistory","panelLoading","isLongRunningProcessRunning","showJurisdictionSpecialistOption","validProcessTypes","_loadPanel","_broadcastRowVersionChange","externalLoadSub","externalLoad$","launchHistoryModal","enteringEditMode","loadingDropdownData","clientServices","availableClientServices","availablePropertyTypes","_propertyTypes","_originalPPReturnPreparationAllowed","_originalPanelData","ahAvailableUsers","csrAvailableUsers","consultantsInstanceId","placeholderText","_getPlaceholderText","panelToSave","isParcel","assessmentsTaxFeedEnabled","taxFeedSettings","assessmentsTaxFeedsEnabled","taxBillsTaxFeedEnabled","taxBillsTaxFeedsEnabled","originalResponsibilities","originalResp","clientServiceResponsibilityID","addingOverride","isException","isTopCompany","clientService","editedDeliveryDetails","_extractDeliveryDetails","originalDeliveryDetails","removePaymentBatchDataFlag","deliveryDetailsToSave","editedDeliveryDetail","originalDeliveryDetail","_getOriginalDeliveryDetail","_isComplianceReturns","_isAllocations","deliveryDetailAssessmentID","deliveryDetailBillID","deliveryDetails_PPBatchReturnsId","_isFeedSpecificationsUpdated","deliveryDetailPaymentBatch","hasOpenPrepareDraftInvoiceTasks","DeliveryDetailPPReturnBatches","_busyDestroy$","ppReturnPreparationAllowedChanged","getAnnualGridCallback","addClientService","serviceToAdd","newClientService","entityResponsibilities","_getInitialValues","disabledWorkflowUserTypes","_getDisabledWorkflowUserTypes","clientServiceResponsibilityUpdateStatus","translatedWorkflowUserTypeId","_getTranslatedWorkflowUserTypeId","addPropertyType","propTypeToAdd","newPropertyType","respToAdd","canEditResponsibility","isLicensedDIUser","isMyConsultingCompany","showSpecificIndividualUserTeamPicker","showConsultingEngagementsList","showWorkflowUserTypeOption","userTypeValue","retryResponsibilityUpdate","showResponsibilityUpdatingInfoIcon","showRetryResponsibilityUpdateIcon","userTypeChanged","previousWorkflowUserTypeId","showExceptionsLink","specificIndividualSelected","newIndividual","isTaxFeedToggleEnabled","topLevelTaxFeedSetting","hasTaxFeeds","currentInstanceId","propertyTypeXServiceHasChildExceptions","aeEntityTypeId","aeEntityId","entityTree","topLevelCompanyTaxFeedSettings","currentlyRunningUpdates","noPagination","hasComplianceFeatureView","instanceInfo","documentIntakeAndProcessingAssignToRyan","responses","_instanceLicensedDISettings","userGroups","ryanUserGroupId","propType","_getIsException","customerHasChildExceptions","_getHasChildExceptions","_getIsMyConsultingCompany","assigneeDisplay","_getAssigneeDisplay","customerIsException","consultingEngagement","_lookupWorkflowUserType","_getResponsibilityLabel","csrUser","u","ahUser","_checkIfNASelected","_checkServiceHasUserSelected","clientServiceResponsibility","rslt","_getComplianceReturnsDisabledWorkflowUserTypes","_getAssessmentsDisabledWorkflowUserTypes","_getTaxBillsDisabledWorkflowUserTypes","_getTaxBillTransmitDisabledWorkflowUserTypes","_getAppealsDisabledWorkflowUserTypes","_getAllocationDisabledWorkflowUserTypes","hasTaxBillTransmitUser","hasAssessmentsUser","hasComplianceUser","canAssignPPWorkflowUser","hasAppealsUser","hasTaxBillsUser","hasAllocationsUser","taxBillDeliveryDetailsCurrent","deliveryDetailAssessmentCurrent","deliveryDetailBillCurrent","deliveryDetailPPReturnBatchCurrent","deliveryDetailAssessmentAllocationTop","originalFeedSpecs","editedFeedSpecs","userObj","prefixKey","COMPLIANCE_PREFIX","ALLOCATIONS_PREFIX","newRowVersion","ReturnSettingsViewModelEnum","GeneralReturnSettingLookupTypeEnum","GeneralReturnSettingStateEnum","ReturnSettingsLookupType","ReturnSettingsSettingTypeEnum","ReturnSettingsEntityTypeEnum","GeneralReturnSettingLookupEnum","TaskProcessingActions","ReturnSignActions","extendedModelBase_ExtendedModelBase","_model","ExtendedContactModel","ExtendedUserTeamModel","RETURN_SETTINGS_HELP","isMultiLine","ReturnSettingsEntityAttributeComponent","lookupOptions","renameSettingNameOption","contactName","settingNameOption","lookupId","optionSettingNameId","toLocaleString","settingType","lookupHasOverride","currentLookupId","parentLookupId","hasChanges","lookupValue","parentValue","ReturnSettingsNameAttributeComponent","selectionChanged","selectedValue","ReturnSettingsContactAttributeComponent","_returnSettingsRepository","_filterContacts","representationTypes","_setContactFilterToCurrentValue","contactHasOverride","currentContactId","parentContactId","currentContact","parentContact","extendedContact","representationHasOverride","currentRepresentationId","parentRepresentationId","representationId","representationChanged","onContactSelected","onContactBlur","_contactNoResult","contactDisplay","parentContactNameLookupValue","onRemoveContactOverride","contactInfo","representationValue","currentRepresentationValue","parentRepresentationValue","representationDisplay","includeInactive","ReturnSettingsComponent","_loadSettings","getSaveModel","_getSaveModel","onInitialized","_currentSettingsCopy","_refreshWetSignatureOverrideSwitch","lookupType","lookupTypeId","_lookupOptions","currentGeneralReturnSetting","_editMode","parentGeneralReturnSetting","ownerContact","_ownerContactName","accountingContact","_accountingContactName","preparerContact","_preparerContactName","signerContact","_signerContactName","allowWetSignatureOverrideSettingState","hideWetSignatureOverrideWarning","redWetSignatureOverrideLabelText","_isDisabled","ownerContactName","ownerContactId","accountingContactName","accountingContactId","preparerContactName","preparerContactId","signerContactName","signerContactId","CompanyReturnSettingsPanelComponent","showInfo","returnSettingsComponent","onReturnSettingsInitialized","onReturnSettingsChanged","AgGridActionCellRendererComponent","PicklistComponent","availableOptions","_allOptions","picklist","optionIndex","_disableDropdown","_enableDropdown","picklistChanged","listSelection","addOption","unsetSelected","picklistItemAdded","animationComplete","removeOption","picklistItemRemoved","shiftOptionUp","selectedOptionIndex","shiftOptionDown","EditRoleModalComponent","_contactsService","isLastAssociatedRole","roleDesc","associatedRoles","originalRoles","modalHeader","addRole","removeRole","newRole","contactRoleAssociationID","ContactListComponent","worksForColumn","_openContactModal","buttonConfigs","_openRoleModal","isShown","_hasWorksFor","worksFor","contactsUpdated","ContactPanelBodyActionsComponent","getNewContactPermission","associateExisting","singleRoles","existingContactsWithThisId","saveAssociation","newAssociation","hasContactPermission","hasNewContactPermission","ContactPanelComponent","isEntityCompanyBased","getViewPermission","getEditPermissionForContactAndEntity","showAllContacts","hasViewOrEditPermission","descriptor_overrides_service_baseUrl","DescriptorOverridesService","createBatch","descriptorOverrides","getAssetUsage","descriptorIds","DescriptorHelperService","getFieldTypes","getUsages","getFormats","getSetup","_SetupColumns","EntityPropertyCharacteristicsService","searchAvailable","PropertyCharacteristicsPickerComponent","_entityDescriptorService","dataSource","descriptorIdsToExclude","descriptorsToExclude","descriptorsSelected","changeTypeaheadLoading","_browseModalRef","availableDescriptors","descriptorCategories","_map","descriptorClicked","categoryIdx","descriptorsToAdd","isDescriptorChecked","addDescriptors","isForCompanyOverrides","PropertyCharacteristicsOverridesComponent","descriptorOverridesService","helperService","_doPermissionCheck","_getData","getAssetUsages","canAssetUsageBeRemoved","_assetUsages","_assetUsagesMinusNever","getDescriptorUsage","usages","descriptorUsageID","getAssetDescriptorUsage","descriptorOverride","usageIdKey","descriptorDTO","descriptorOverrideToEdit","descriptorOverrideID","editDescriptorOverride","saveDescriptorOverride","serverActionSingle","deleteDescriptorOverride","descriptorToAdd","addingDescriptor","_getDescriptorOverrides","hideComplianceFeatures","initialGet","assetUsage","assetDescriptorIdsToCheck","assetUsageID","isLoadingAssetUsage","descriptorsInfo","descriptor_picklist_service_baseUrl","DescriptorPicklistService","getByPicklistGroupId","updateItem","createItem","deleteItemById","canLimitToList","picklistGroupId","DescriptorFieldTypes","DescriptorFormats","EntityPropertyCharacteristicsInputComponent","_picklistService","saveAttempted","attempted","wasSaveAttempted","_validate","fieldTypeID","dateMatch","numberOptions","suffix","thousands","formatID","NoSeparators","CommaSeparatorsPrecision2","CommaSeparatorsPrecision3","picklistOptions","pickListGroupID","EntityPropertyCharacteristicsListComponent","EntityPropertyCharacteristicsComponent","_upgradeNavService","_changeHistoryService","_changeDetectorRef","descriptorsAlpha","isDeleted","_setDescriptorViews","originalDescriptorsAlpha","originalDescriptorCategories","descriptorsToSave","enableHtml","_broadcastMaximize","unmaximize","launchChangeHistoryModal","isOpenCategory","_getCurrentEntity","allowMaximize","_doPermissionsCheck","hasPrivateView","hasPrivateEdit","CompanyPageComponent","_hasRyanPrivateItemsView","_hasRyanPrivateItemsEdit","allowInvoiceEdit","setShowComplianceInfo","ClientServicesModule","AssetClassSelectorModule","ReturnPartServiceBase","isActive","_isActive","getSharedStateClone","sharedState","hasSharedStateChanged","paths","o1","o2","subscribeToServiceActivationCycle","_subscribers","onReturnPartServiceActivated","unsubscribeFromServiceActivationCycle","onReturnPartServiceDeactivated","notifyServiceActivationChange","AssessorFactorsEnum","FilingControlGroupBy","ReturnService","_returnFormRevisionRepository","returnFormRevisionsUpdatedTimestamp","isReturnInReadOnly","_sharedState","_canEditCompany","canViewRyanPrivateItems","_canViewRyanPrivateItems","companyAssetDescriptorMappings","_companyAssetDescriptorMappings","_filingBatch","_tasks","priorCompletedTask","_priorCompletedTask","currentTask","_currentTask","_nextTask","_lienDate","_formRevisionId","processStatusError","isReturnInReadOnlyMode","_isReturnInReadOnlyMode","isReturnInReadOnlyMode$","_isReturnInReadOnlyModeSubject","parcelName","parcelAcctNumber","returnGroupDetails","_returnGroupDetails","validateFormsResult","_validateFormsResult","compareFormsResult","_compareFormsResult","returnSummary","_returnSummary","_isReturnInReadOnly","isConsolidatedReturn","_isConsolidatedReturn","start$","_startSubject","returns$","_returnsSubject","formRevisionId$","_formRevisionIdSubject","processStatus$","_filingBatchProcessStatusSubject","progress$","_filingBatchProgressSubject","tasks$","_tasksSubject","compareForms$","_compareFormsSubject","validateForms$","_validateFormsSubject","returnBatchFilter$","_returnBatchFilterSubject","longRunningProcessId$","_longRunningProcessIdSubject","parcelsChanged$","_parcelsChangedSubject","onlyReloadFilingBatchDetails","forceCurrent","_getLastSelectedFormRevisionId","_setData","filingBatchProcessStatus","notifyProcessStatusChange","loadPreparedData","_associatedReturnFormRevisions","_notAssociatedReturnFormRevisions","_consolidatedReturns","_filingBatchProgressChangeSub","setReturns","lastSelectedFormRevisionId","_setFormRevisionId","setReturnFilterChanged","loadReturnFormRevisions","setReturnTotals","returnDetails","setFirstFormRevisionId","saveToSharedState","primaryFormCount","firstFormRevision","setFormRevisionId","getDefaultFactorTables","includeRetiredTables","assessorName","getAssociatedReturnFormRevisions","getUniqueAssociatedReturnFormRevisions","getNotAssociatedReturnFormRevisions","notifyReportsUpdate","isReturnConsolidated","associateOrDisassociateReturnFormRevisions","startLocking","startUnlocking","startSigning","startUnsigning","startFinalizing","_loadTasks","startResult","_start","validateForms","compareResult","_setCompareFormsResult","getFilenameFromResponseContentDisposition","saveFileAsPdf","getReturnFormRevisionDisplayName","returnFormRevision","formRevisionName","getRepresentationType","representationType","getReportType","filingBatchReport","isSystem","getReportName","getSavedSearchReportType","getSavedSearchReportName","getReturnReportName","returnFormRevisionReport","applyRemoteReturnBatchFilter","getCompanyAssetDescriptorMappingsAsColDefs","mapping","typeSpecificAttributes","cellStyle","fieldType","mindWidth","columnName","rowData","notifyParcelsChanged","cutOffDate","_cutOffDate","_changeDetection","ages","_ages","loadFilingBatchInfo","_lastSelectedFormRevisionIds","lastSelectedFormRevision","tasksByEntity","_setTasks","formResult","_wsHandleFilingBatchStatusChange","_wsHandleFilingBatchProgressChange","companyAssetDescriptors","formsAssociatedWithReturns","formsNotAssociatedWithReturns","returnTotalsDetails","ReturnAssetsService","_returnService","assetStatusesFilter","assessorFactorsFilter","assessorFactor","AnyAssessor","assessorIds","scheduleAndFactorFilter","showOnlyNotAssignedToASchedule","showOnlyAssignedToNonReportableSchedule","showOnlyAssignedToReportableSchedule","formRevisionScheduleIds","depreciationFactorId","scheduleAge","assetDetailsUpdatedTimestamp","assetMappingsUpdatedTimestamp","hideEmptySchedulesFilter","separateFactorTablesFilter","_assetDetailsUpdatedSubject","_assetMappingsUpdatedSubject","_requestUpdatedSchedules","_assetStatusesFilterSubject","_assessorFactorsFilterSubject","_scheduleAndFactorFilterSubject","hasResetNoDataFilterApplied","_hasResetNoDataFilterApplied","requestUpdatedSchedules","setAssessorFactorsFilter","setScheduleAndFactorFilter","scheduleFactorFilter","userSelectedEmptySchedule","setAssetStatusesFilter","setHideEmptySchedulesFilter","setSeparateFactorTablesFilter","getScheduleDetails","forAllFormRevisions","assessorFilter","_getAssessorFilterForSelectedAssessorFactors","formScheduleIds","formFactorTableId","priorReturnStatuses","aggregationLevel","includeMergedParcels","getUnassignedScheduleDetails","exportAssets","updateAssetMappings","notifyAssetDetailsUpdated","recalculateWorkingSet","getWorkingSetAssessors","clearScheduleAndFactorFilter","AssessorsUsingDefaultFactors","SpecificAssessor","ScheduleAdditionsDisposalReconciliationReportRow","formRevisionScheduleId","scheduleName","netChange","cost","priorCost","percentChange","ScheduleAdditionsDisposalsReconciliationReport","_assignedScheduleDetails","_unassignedScheduleDetails","notAssignedToASchedule","scheduleDetail","assetsCount","assetCount","disposalsCost","disposedAssetCount","scheduleData","additions","disposals","isReportable","reportableSchedules","totalNonReportable","totalReportable","ReturnSummaryReconciliationReportRow","reportableCost","nonReportableCost","unassignedCost","ReturnSummaryReconciliationReportAdditions","ReturnSummaryReconciliationReportDeductions","ReturnSummaryReconciliationReport","_returnSummaryResult","reportableSummary","addsAndDeletes","scheduleType","nonReportableSummary","unassignedSummary","acquisitions","addAcquisitionsCost","transferIns","addTransfersInCost","costChanges","addCostChangesCost","reportabilityChanges","addReportabilityChangesCost","addCost","deductions","deductionDisposalCost","transferOuts","deductionTransferOutCost","deductionCostChangesCost","deductionReportabilityChangesCost","suppressedAssets","suppressedAssetsCost","deductionCost","currentCost","priorReturnCostForward","existingOverridesTrueUp","existingOverridesTrueUpCost","existingDeductionsTrueUp","existingDeductionsTrueUpCost","priorReturn","priorReportedValue","priorRenderedValue","currentEstimatedFMV","priorEstimatedFMV","currentReportedValue","currentRenderedValue","notAssignedToAScheduleCost","unAssignedCost","showEstimatedFMV","FilingControlReconciliationReport","_returnFilingControlSummary","_returnFormRevisions","_returnTotals","revisionsByReturn","returnFormRevisionId","filingControlMap","isGroupRow","isSubTotalRow","returnFormRevisions","_getTotalRow","consolidatedReturnGroups","isMerged","parcelAcctNumberDisplay","ar","subtotal","_getBlankSubtotalRow","_addToSubtotalRow","groupedRows","depreciatedCost","taxLiability","estimatedFMV","priorYearReportedCost","priorYearDepreciatedValue","groupedReturns","reportedAssetCount","notReportedAssetCount","isSelectedTotalsRow","ReturnOverviewService","reconciliationReport","allowPrimaryForReturn","returnSummaryReconciliationReport","scheduleAdditionsDisposalsReconciliationReport","filingControlReconciliationReport","reconciliationReports","_reconciliationReports","availableReconciliationReports","reconciliationReport$","_reconciliationReportSubject","returnAssetsSelected$","_returnAssetsSelectedSubject","returnPreviewSelected$","_returnPreviewSelectedSubject","firstLoad","setReconciliationReport","notifyReturnAssetsSelected","notifyReturnPreviewSelected","getScheduleAdditionsDisposalReconciliationReport","assignedScheduleDetails","unassignedScheduleDetails","getReturnSummaryReconciliationReport","returnSummaryResult","formRevisions","getFilingControlReconciliationReport","filingControlSummaryResult","ReturnOutputService","returnOutputModel","loadSharedState","includeFilingControlReport","includeUSPSCertificateOfMailingLog","includeUSPSCertificateOfMailingIndividual","includeEnvelopeInserts","includePackageCoverSheets","includeReturns","organizeForMailing","embedExcelReportsInPdf","_outputSettingName","saveSharedState","ReturnSettingsService","WeissmanMutexService","lockChanged$","_lockChangedSubject","acquire","existingHandler","_registrations","wsMutexRelease","_publishLockState","canAcquire","release","lockState","ReturnFormsErrorComponent","errorTypes","formErrors","errorType","showCancel","_titlesByErrorType","aggregate","acc2","groupingValue","_getErrorGroupingValue","_getErrorDisplayValue","forms","showForms","_getListDescriptor","toggleParcels","RETURN_PAGE_HELP","ReturnUpdateLogicService","_returnAssetsService","_returnOverviewService","OVERVIEW_TAB","returnService","returnAssetsService","returnOverviewService","ASSETS_TAB","_loadingSubject","_returnFormRevisionsSubject","_returnOverviewSubject","_returnSummarySubject","_returnAssessorsSubject","loading$","_loading$","returnFormRevisions$","_returnFormRevision$","returnOverviewReport$","_returnOverview$","returnSummaryReport$","_returnSummary$","returnAssessors$","_returnAssessors$","setActiveTab","activeTab","startLoading","stopLoading","_refreshActiveTab","parcelFilterChanged","returnFormRevisionChanged","refreshReturnOverview","refreshAssetFormDetails","refreshReturnFormRevisions","_refreshReturnFormRevisions","refreshOverview","_refreshReturnOverview","refreshReturnSummary","_refreshReturnSummary","_persistLocalState","refreshAssessors","_refreshAssessors","returnServiceSharedState","localSharedState","_sharedStates","localReturnIds","sharedReturnIds","localReturnFormRevisionsUpdatedTimestamp","sharedReturnFormRevisionsUpdatedTimestamp","uniqueRevisions","returnAssetsServiceSharedState","localReturnSharedState","localReturnAssetsSharedState","localReturnOverviewServiceSharedState","localFormRevisionId","sharedFormRevisionId","localReconciliationReport","sharedReconciliationReport","localAssetsUpdatedTimestamp","sharedAssetsUpdatedTimestamp","localAssetMappingsUpdatedTimestamp","sharedAssetMappingsUpdatedTimestamp","selectedReconciliationReport","returnOverviewServiceSharedState","localAssetDetailsUpdatedTimestamp","sharedAssetDetailsUpdatedTimestamp","StepProgressIndicatorComponent","step","clickable","getClass","isWorking","FilingBatchProgressComponent","_getBeginTitle","_beginIsError","_beginIsCurrent","_beginIsWorking","_beginIsComplete","_click","_getLockTitle","_lockIsError","_lockIsCurrent","_lockIsWorking","_lockIsComplete","_getFinalizeTitle","_finalizeIsError","_finalizeIsCurrent","_finalizeIsWorking","_finalizeIsComplete","RETURN_LOCK_HELP","ReturnLockModalComponent","packageStrategies","selectedPackageStrategy","returnInOwnPackageThreshold","certifiedMailPackageThreshold","returnLockPackageStrategy","returnTaskUpdate","certifiedMailPackageThresholdSelected","returnInOwnPackageThresholdSelected","packageStrategyChanged","RETURN_SIGN_HELP","WarningMessageComponent","toggleDetails","showDetailsChange","_calculateEdgeDistance","closeDetails","warningDetails","edgeOffsetPercent","ReturnSignModalComponent","signInfos","_signInfos","_getIsError","isWarning","_getIsWarning","applicable","_getApplicable","signerContactDisplay","wetSignatureOverrideWarning","signInfo","assessorWetSignatureRequired","signatureFieldsCount","dateFieldsCount","selectedActionChanged","ReturnFinalizeModalComponent","nameInvalid","createNextYear","subGroup","formInvalid","nextYear","nextYearBatch","initialFinalizeOption","finalizeSyncOptions","syncOptions","_syncTargetValue","_syncEstimatedFMV","filingBatchGroup","nameValidation","createFilingsAsNecessary","finalizeOptionsForm","attachReturns","_attachReturns","_embedExcelReportsInPdf","syncTargetValue","syncEstimatedFMV","nextYearBatchModel","formValidation","_toggleNextYearGroup","onDueDateChanged","ReturnTaskComponent","_mutexService","_completeTask","_prepareReturns","_digitallySignReturns","_finalizeReturns","currentTaskTooltip","_refreshTasks","_tasksSub","completeCurrentTask","e2","taskError","currentTaskId","_taskMap","_skipTask","returnSignRequestModel","ReturnTaskExceptionModalComponent","rescindLevels","rescindAction","_unlock","reassignAction","_reassign","_unsign","_rescindToTask","userTeamFilter","_filterUserTeams","currentTaskMapping","taskName","taskTypeId","userTeamModel","onUserTeamSelected","selectedUserTeam","onUserTeamBlur","onUserTeamsLoadingChange","userTeamsLoading","busyMsg","taskMapping","assignedUserId","assignedTeamId","observableFrom","RETURN_TASK_EXCEPTION_HELP","ReturnTaskExceptionComponent","exceptionButtonHelpContentId","showException","ReturnBatchTaxYearAdditionalInfoComponent","ReturnBatchComponent","_returnUpdateLogicService","returnGroupType","idParam","nameParam","_GROUP_SELECTION_ASSESSOR","_GROUP_SELECTION_COMPANY","_GROUP_SELECTION_NONE","viewport","checkViewportSize","_applyRemoteFilter","isPageLoading","_parcelsChangeDate","scrollable","elementRef","spacer","firstChild","_assetDetailsUpdatedSub","assetDetailsUpdated$","_updateReturnTotals","_assetMappingUpdatedSub","assetMappingsUpdated$","nodeCheckChanged","_applyIsCheckedStatusToTreePathDown","_applyIsCheckedStatusToTreePathUp","automaticRefresh","_setSelectedReturns","returnsSelectionApplied","onAutoRefreshChanged","refreshReturns","getWorkflowStatusDisplay","toggleNodeIsExpanded","_collapseAndHideChildren","flatTree","_getFlatChildren","_root","selectOptionChanged","group2SelectOptions","group1Option","group2Option","selectOptionsForGroup2","_initializeTree","selectAllReturns","selectPositive","filterReturns","_fetchReturnTotals","resetReturnFilter","trackDataNodes","taxYearAdditionalInfoComponent","busyCounter","returnTotalsMap","reportedCost","groupSelection","totalsInfo","levels","_getChildren","_applyIsCheckedStatusToTreePath","filtersForPathToNode","filteredReturns","matchesFiltersForPathToNode","treeNodesForReturns","newNode","returnInfo","widestListItem","onlyVisible","_getSelectedChildren","checkedNodes","fromFilterChange","selectedReturns","selectedReturnsCount","checkedNodeCount","indeterminateNodeCount","nodes","flatNodes","_toggleNodeIsExpandedUp","toggleState","CdkVirtualScrollViewport","ReturnCompareConfirmationModalComponent","submitReset","ReturnCompareMessageComponent","_setComparisonValue","isReadOnlyMode","comparison","toggleReports","showReports","showConfirmation","showMessageDetails","getIconClass","getIconTitle","trackByReturnId","customReturns","HTTPStatusError","captureStackTrace","ReturnPreviewService","_returnFormRevisionReportRepository","returnForm","fieldOverrideHolder","_fieldOverrideHolder","returnForm$","_returnFormSubject","formOverrides$","_formOverridesSubject","returnFormOverrideList$","_returnFormOverrideListSubject","openPreviewByOverrides$","_openPreviewByOverrideSubject","navigateToOverride","notifyReturnFormOverrideListChanged","setReturnForm","openPreviewByOverrides","overrideModel","forceGetFieldData","mergeParcelId","reportOptions","requestType","flattenFields","_getFieldDataType","getFormTemplateAndData","isFormInReviewMode","getReturnFormReport","isFormDataNeededOnPdf","taskStatus","overrides","returnMergedParcelIds","overrideValue","loadFormOverrides","formOverrideRequestModel","paginationModel","getAssociatedReportsForReturns","getNotAssociatedReportsForReturns","ReturnPreviewFormAssociationsComponent","applyChangesScopeOptions","_APPLY_CHANGES_SCOPE_OPTION_ALL_SELECTED_RETURNS","selectedReturn","_APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN","selectedApplyChangesScopeOption","onSelectedApplyChangesScopeFilterChange","onFormSelectedChange","isSelectedInitial","totalReturnsAvailableToUse","formRevisionAssociations","createOrUpdateReturnFormRevisions","inUseReturnFormRevisions","canUseReturnFormRevisions","formRevisionAssociation","rfr","updateReturnForms","hasOrphanedSupplementalForms","parentIds","parentFormRevisionId","itemIds","getMessage","totalReturns","selectedReturnIds","allReturnFormRevisions","returnFormRevisionsGroupedByFormRevisionId","allReturnsAdded","formRevisionDisplayName","fra","sortedForms","parentFormRevisionAssociations","childFormRevisionAssociations","childDictionary","child","ReturnPreviewFormDownloadComponent","_returnPreviewService","selectedReturnFormRevision","_refreshReports","onSelectedReturnFormRevisionChange","downloadForm","selectedReturnFormRevisionReport","returnFormRevisionReports","RETURN_PREVIEW_FORM_LIST_HELP","RETURN_PREVIEW_FORM_OVERRIDES_HELP","FormOverridesListAgGridDataSource","endRow","_propertyMap","ReturnPreviewFormOverridesListActionCellRendererComponent","ReturnPreviewFormOverrideListComponent","deletedOverrides","clickedOverride","actionButtonCount","lockPosition","parcelAssessorId","viewReturn","_viewReturn","_deleteOverride","_setDataSource","_refreshDataSource","_gridDataSource","setDatasource","mergedParcelId","returnFormOverrideDeleteRequestModel","ReturnPreviewFormOverridesComponent","openOverridesModal","r_r26","r_r35","ReturnTemplateTypes","ReturnPreviewFormListComponent","_returns","formInfo","showPreview","editReportsHelpContentId","formsAndReportsHelpContentId","hasEditComplianceSetupsPermission","filingBatchIdParam","Return","returnTemplate","Form","formTemplate","reportTemplate","Merged","mergedTemplate","_createComparisonMap","_destroyTabSubs$","_openPreviewByOverrideClick","_refreshFormRevisions","_tabChangedReload","showList","isReadonly","_isFormOverridden","merged","_isReportOverridden","selectedReturnId","selectedReturnFormRevisionId","selectedReturnFormRevisionReportId","returnFormRevisionReportId","selectedFormRevisionId","selectedReportId","selectedMergeParcelId","selectedIsExcel","isExcel","_editModeSubject","getReportSource","downloadReturnDocument","prev","cur","manageReturnFormRevisions","useValue","_onSelectedFormListItemChanged","selectReport","applySelectionsToAllReports","returnFormReportInfo","returnFormInfo","enterEditMode","_returnsPreEditModeCopy","_setFlatReturns","cancelEditMode","saveFormReports","modelsToPersist","_loadFormRevisions","updateReturnReports","_checkForReportChanges","currentReports","hasUpdates","lastUsedReports","_localReturnServiceSharedState","currentReport","prevReport","filingBatchReportId","_loadingFormRevisions","flatReturns","updateFormRevisions","reportsForReturns","reportsAvailable","reportsAvailableForReturns","parcelAcctNumDisplay","priorReturnUsedAnotherForm","hasElectronicFileType","hasLongName","formsLength","isFormConsolidated","mergedForm","isMergedForm","childDict","isFrequentlyUsed","showOnlyFrequentlyUsedReports","hasReturnFile","returnNotDefaultMap","ReturnPreviewFormOverrideEditComponent","ruleResults","_returnReadOnlyFlagSub","isFilingRuleResult","ruleResult","hasLink","deleteConfirmed","getFieldEntityName","typeEnumVal","fieldEntityTypes","getEntityUrl","FULL_FIELD_NAME_REGEX","ACCOUNT_PARAMETER_REGEX","UI_ACCOUNT_INDEX_PARAMETER_REGEX","FieldOverrideHolder","_overrides","aR","formElements","bR","getSaved","_savedOverrides","getFieldOverride","saveOverride","addOverride","existingOverride","renumberOverrides","followingElement","PDFViewerBase","_PDF_OUTPUT_HOLDER_QUERY_SELECTOR","calculateLowestRenderedPage","lowestRenderedPage","highestPageNumberInDoc","pdfDocument","numPages","pageNum","currentlyRenderedPageNums","calculateHighestRenderedPage","highestRenderedPage","showPreviousPages","lowestPageToRender","renderPagesWithAnnotations","updateNextPageVisibility","checkForPageDeletions","showNextPages","topPageToRender","deleteFromUpperEnd","MAX_RENDERED_PAGES","deletePages","lowestPageToDelete","highestPageToDelete","pageDivs","pdfPage","_pdfPageViews","updateZoomScale","_zoomScale","zoomScaleUpdating","zoomPercentage","lowest","highest","finished","pdfPageView","scale","_annotations","annotation","_fieldIdMap","draw","scrollToElement","scrollIntoView","behavior","loadPdfDocument","addPdfViewer","scrollExtentSubscription","pdfjsLib","getDocument","lastPageToRender","renderPageDivs","setupScrollObservable","showNextPagesVisible","showPreviousPagesVisible","disposePdfDocument","getElementRef","overrideHolder","_createOverrideUI","overrideUIElement","_deleteOverrideMarker","_createOverrideMarker","isSaved","formElement","ownerDocument","fieldInfo","_getFieldData","_clickOverride","_getOriginalValue","_originalValues","_originalValuesByShortName","_fieldDataLookup","_fieldDataLookupByShortName","inputElem","isAppealForm","_deleteInfoMarker","_deleteOverrideUI","_isCheckedValue","_createInfoMarker","_clickFieldInfo","isFullFieldName","shortenFullFieldName","skipUIAccountIndex","accountIndex","_multiAccountFieldMap","getUIAccountIndex","shortName","paramMatch","removeUIAccountIndex","setUIAccountIndex","_loadPreviewForForm","showFormForReviewOnly","perAccountFieldLookup","_loadFormData","_postFormLoadAction","overrideLookup","resolveAccountIndex","fieldData","_getInputByFieldName","fieldsToHide","fieldIndex","savedOverride","shortNameWithoutAccountIndex","fullNameOverride","shortNameOverride","shortFieldName","_oldFormatOverrides","MODIFIED_FIELD_CSS_CLASS","signatureDiv","_updateInputFieldReadOnlyAttributes","querySelectorAll","GlobalWorkerOptions","workerSrc","showPreviousPagesButton","showNextPagesButton","firstPage","lastPage","annotationsPromise","getPage","pdfPageViewParams","defaultViewport","getViewport","eventBus","pdfjsViewer","EventBus","textLayerMode","annotationMode","isShowingAnnotations","PDFPageView","setPdfPage","getAnnotations","_idFieldMap","_accountlessNameIdMap","fieldElementMaps","accountlessName","elements","outerHolder","div","RETURN_PREVIEW_FORM_VIEWER_HELP","PDFControlsComponent","pct","_zoomValue","submitZoomValue","zoomOut","zoomStep","setZoomValue","zoomIn","zoomChanged","ReturnPreviewOverrideChangesComponent","unsavedOverrides","_setUnsavedOverrides","unsaved","newOverrides","savedIndex","exists","isExisting","newChanges","cap","ReturnPreviewFormViewerComponent","isExcelReport","isReportEmpty","_isReportEmpty","canPreview","canShowFieldLocations","canEditComplianceSetups","_refreshPreview","_handleReturnReadOnlyFlagChange","_returnFormSub","_returnFormOverrideListSub","_returnFormOverridesListChanged","_loadPreview","onApplyEditsToAllChange","setShowFieldLocation","showFieldLocation","thisPageNeedsRefreshForDeletes","overrideDetail","removeUnsavedOverrides","formChanges","submitPdfChanges","_getReturnAndParcelIdsForEdits","persistedResult","onPdfFieldChange","getAttribute","oldFormatOverride","returnPreviewServiceSharedState","localReturnForm","_localReturnPreviewServiceSharedState","sharedReturnForm","_localReturnAssetsServiceSharedState","reloadTemplate","_persistState","hasTooManyRows","_loadPreviewForReport","formRevisionOverrides","oldFormatShortName","overrideToScrollTo","ReturnPreviewComponent","RETURN_OVERVIEW_COMPONENT_HELP","ReturnFormSelectorComponent","returnPartService","_returnsSub","ReturnAssetDisposalsListAgGridDataSource","_totalsUpdateCallback","getSearchParamsWithoutPagination","searchParamsString","fetchTotals","lastFetchedTotals","_lastFilterUsedInTotals","clearTotals","getPriorReturnFromAssetList","age","scheduleGroupType","priorScheduleGroupType","includeOnlyTotals","includeUnassigned","includeDisposed","targetNonReportableSchedule","targetReportableSchedule","getRowIdsInternal","ReturnAssetChangeIconCellRendererComponent","rowModel","statusChanged","assetReturnStatus","calculatedAssetReturnStatus","toolTipTitle","assetNumber","initialized","AssessorTablePickerComponent","defaultAssessor","hasCompanyAssessorFactorTable","assessorFactorTables","factorTables","isUsingDefaultTables","defaultAssessors","lockedAssessorAssignments","showDefaultAssessor","defaultDepreciationTables","defaultFactorTables","defaultDepreciationUsedTables","isUsed","defaultIndexTables","defaultIndexUsedTables","_assessorFactorTables","assessorDepreciationTables","table","assessorDepreciationUsedTables","assessorIndexTables","assessorIndexUsedTables","defaultDepreciationValue","defaultFactorTable","dft","isDefaultForSchedule","isLockedForSchedule","formGroupMap","defaultDepreciationControl","defaultIndexControl","showAllAvailableFactors","showAvailable","depControls","controlValue","defaultTable","adt","assessorDepreciationControls","addUnlistedOptionsToShortlist","assessorIndexControls","defDep","defIndex","_updateDropdownState","depreciationTableId","indexTableId","optionIdentify","factorTable","compareFn","obj1","obj2","switchFactorList","defaultControl","formControlValues","_toggleDefaultOptions","_toggleAssessorOptions","dep","AssetClassPickerComponent","_assetClassificationRepository","_elem","assetClassifications","secondLevel","_expandedAssetClassifications","selectAssetClass","assetClassification","classification","expandClass","collapseClass","AssetClassSelectorComponent","assetClassificationFilter","_filterAssetClassifications","_populateAssetClassifications","_assetClassificationSubscription","first","_selectAssetClass","onAssetClassificationBlur","isRequiredField","assetClassificationName","assetClassificationChange","onAssetClassificationSelected","assetClass","assetClassificationIdChange","openPickerModal","_assetClassifications","outerItem","secondLevelItem","extraPath","thirdLevelItem","ReturnAssetBulkUpdateActionComponent","possibleActions","selectedAction","onlyAllowRemoveOverrides","fieldHasOverrides","fieldHasClassificationDefault","enabledActions","fieldActionChanged","fieldActionChange","fieldActionNameChange","ScheduleSelectorComponent","scheduleFilter","_filterSchedules","_scheduleData","_schedules","_selectSchedule","formRevisionScheduleName","onScheduleBlur","formRevisionScheduleChange","onScheduleSelected","schedule","formRevisionScheduleIdChange","ReturnAssetBulkUpdateComponent","possibleReturnStatuses","_loadBulkUpdateMetadata","formRevisionSchedule","priorScheduleAction","_populateAssessorFactorTableAssignments","classificationIdAction","returnStatus","returnStatusAction","scheduleAssignmentAction","priorScheduleAssignmentAction","priorScheduleId","assessorFactorTableAssignments","additionalDepreciation","additionalDepreciationAction","estimatedFMVAction","requestSchedules","analytics","removeOverride","classificationName","scheduleAssignment","scheduleAssignmentName","validateForm","setClassificationName","setScheduleAssignmentName","bulkUpdateMetadata","_validateSelectedRecords","validReturnStatuses","assetReturnStatuses","assetReturnStatusTooltipText","isAssetReturnStatusFieldDisabled","showAssetReturnStatusTooltip","allowAssetReturnStatusRemoveOverride","calculatedAssetReturnStatuses","returnStatusActionField","allAssessors","isDepreciable","_updateForExpandedScheduleDetail","lockedAssessors","la","_updateLockedSchedule","_askForFactorAndUpdate","_updateNonDepreciableSchedule","_updateAssessorFactorTableAssignments","assessorPickerResult","reportingAssetAssessorMap","nullAssessor","areAllLocked","assessorAssignment","depreciationFactorTableId","assessorFactorTableResult","defaultAssessorFactorTables","companyDefaultAssessorTables","companyAssessorTables","ASSET_DETAILS_HELP","AssetSummary","displayPipe","_displayPipe","_setModel","reportingAssetOverride","reportingAsset","reportingAssetOverrideId","isGLAccountIdBlank","_isLocked","_rowIndex","alternativeCostDescriptorId","sourceAssetNumber","reportedAssetNumber","reportedAssetNumberHasOverride","reportedAssetNumberHasOverrideWithBlank","reportedAssetId","acqDate","sourceAcqDate","sourceAsset","reportedAcqDate","reportedAcqDateHasOverride","sourceDescription","reportedDescription","reportedDescriptionHasOverride","reportedDescriptionHasOverrideWithBlank","isCompanyCalculated","sourceCompanyName","assetVerificationReason","assetOwnershipType","assetOwnershipTypeId","isLeasedAsset","isLeasedFromOther","isLeasedToOther","municipalityName","sourceState","sourceCost","sourceAdjustedCost","reportedCostHasOverride","reportedColumnHasOverride","reportedCostHasOverrideWithBlank","sourcePriorCost","priorCostHasOverride","sourceCostChange","costChange","costChangeHasOverride","sourceGlAccount","sourceGlAccountDisplay","accountNumber","accountName","sourceGlAccountNumber","sourceGlAccountClassificationId","reportedGlAccount","reportedGlAccountHasOverride","isReportedGlAccountBlank","reportedGlAccountDisplay","reportedGlAccountNumber","reportedGlAccountClassificationId","sourceSite","sourceSiteDisplay","sourceSiteName","sourceSiteNumber","reportedSite","reportedSiteHasOverride","reportedSiteId","reportedSiteDisplay","reportedSiteName","reportedSiteNumber","sourceSiteReportingParcelId","reportedParcelId","assetReportingParcelId","siteReportingParcelId","reportedParcelName","assetReportingParcelAcctNum","siteReportingParcelName","reportedParcelHasOverride","siteReportedParcelId","parcelDisplay","parcelHasOverride","siteReportingParcelAcctNum","sourceDisposedDate","disposedDate","reportedDisposedDate","reportedDisposedDateHasOverride","reportedAssetClassificationDisplay","reportedAssetClassificationId","allowPerpetual","isInventory","assetClassificationHasOverride","classificationAllowsPerpetual","reportingIsPerpetual","isPerpetual","isUserCreated","hasImportedSource","areSplitAllocationsValid","splitAllocationPercentage","getOverrides","sourceLeaseClientId","leaseClientId","reportedLeaseClientId","isOverride","reportedLeaseClientIdHasOverride","sourceLeaseLocationName","leaseLocationName","reportedLeaseLocationName","reportedLeaseLocationNameHasOverride","sourceLeaseAddress","leaseAddress","reportedLeaseAddress","reportedLeaseAddressHasOverride","sourceLeaseCity","leaseCity","reportedLeaseCity","reportedLeaseCityHasOverride","sourceLeaseState","leaseState","reportedLeaseState","reportedLeaseStateHasOverride","sourceLeaseZip","leaseZip","reportedLeaseZip","reportedLeaseZipHasOverride","sourceLeaseTermInMonths","leaseTermInMonths","reportedLeaseTermInMonths","reportedLeaseTermInMonthsHasOverride","sourceLeaseMonthlyPayment","leaseMonthlyPayment","reportedLeaseMonthlyPayment","reportedLeaseMonthlyPaymentHasOverride","sourceLeaseTypeId","leaseTypeId","reportedLeaseTypeId","reportedLeaseTypeIdHasOverride","sourceLeaseAssetId","leaseAssetId","reportedLeaseAssetId","reportedLeaseAssetIdHasOverride","sourceLeaseNumber","leaseNumber","reportedLeaseNumber","reportedLeaseNumberHasOverride","sourceLeaseBillingName","leaseBillingName","reportedLeaseBillingName","reportedLeaseBillingNameHasOverride","sourceLeaseBillingAddress","leaseBillingAddress","reportedLeaseBillingAddress","reportedLeaseBillingAddressHasOverride","sourceLeaseBillingCity","leaseBillingCity","reportedLeaseBillingCity","reportedLeaseBillingCityHasOverride","sourceLeaseBillingState","leaseBillingState","reportedLeaseBillingState","reportedLeaseBillingStateHasOverride","sourceLeaseBillingZip","leaseBillingZip","reportedLeaseBillingZip","reportedLeaseBillingZipHasOverride","sourceLeaseStartDate","leaseStartDate","reportedLeaseStartDate","reportedLeaseStartDateHasOverride","sourceLeaseEndDate","leaseEndDate","reportedLeaseEndDate","reportedLeaseEndDateHasOverride","sourceT1","t1","reportedT1","sourceT2","t2","reportedT2","sourceT3","t3","reportedT3","sourceT4","t4","reportedT4","sourceT5","t5","reportedT5","sourceT6","t6","reportedT6","sourceT7","t7","reportedT7","sourceT8","t8","reportedT8","sourceT9","t9","reportedT9","sourceT10","t10","reportedT10","sourceT11","t11","reportedT11","sourceT12","t12","reportedT12","sourceT13","t13","reportedT13","sourceT14","t14","reportedT14","sourceT15","t15","reportedT15","sourceT16","t16","reportedT16","sourceT17","t17","reportedT17","sourceT18","t18","reportedT18","sourceT19","t19","reportedT19","sourceT20","t20","reportedT20","sourceT21","t21","reportedT21","sourceT22","t22","reportedT22","sourceT23","t23","reportedT23","sourceT24","t24","reportedT24","sourceT25","t25","reportedT25","sourceT26","t26","reportedT26","sourceT27","t27","reportedT27","sourceT28","t28","reportedT28","sourceT29","t29","reportedT29","sourceT30","t30","reportedT30","sourceN1","n1","reportedN1","sourceN2","n2","reportedN2","sourceN3","n3","reportedN3","sourceN4","n4","reportedN4","sourceN5","n5","reportedN5","sourceN6","n6","reportedN6","sourceN7","n7","reportedN7","sourceN8","n8","reportedN8","sourceN9","n9","reportedN9","sourceN10","n10","reportedN10","slotColumnHasOverride","toLocaleLowerCase","slotColumnHasOverrideWithBlank","sourceD1","d1","reportedD1","sourceD2","d2","reportedD2","sourceD3","reportedD3","sourceD4","d4","reportedD4","sourceD5","d5","reportedD5","sourceD6","d6","reportedD6","sourceD7","d7","reportedD7","sourceD8","d8","reportedD8","sourceD9","d9","reportedD9","sourceD10","d10","reportedD10","reportedCostAdjustmentAmount1","costAdjustmentAmount1","reportedCostAdjustmentAmount2","costAdjustmentAmount2","reportedCostAdjustmentAmount3","costAdjustmentAmount3","reportedCostAdjustmentAmount4","costAdjustmentAmount4","reportedCostAdjustmentAmount5","costAdjustmentAmount5","reportedCostAdjustmentAmount6","costAdjustmentAmount6","reportedCostAdjustmentAmount7","costAdjustmentAmount7","reportedCostAdjustmentAmount8","costAdjustmentAmount8","reportedCostAdjustmentAmount9","costAdjustmentAmount9","reportedCostAdjustmentAmount10","costAdjustmentAmount10","hasCostAdjustment","sourceAssetId","transientReportedCost","_transientReportedCost","transientReportedN1","transientReportedN2","transientReportedN3","transientReportedN4","transientReportedN5","transientReportedN6","transientReportedN7","transientReportedN8","transientReportedN9","transientReportedN10","sourceOldAssetNumber","oldAssetNumber","reportedOldAssetNumber","reportedOldAssetNumberHasOverride","reportedOldAssetNumberHasOverrideWithBlank","sourceInventoryJan","inventoryJan","reportedInventoryJan","reportedInventoryJanHasOverride","sourceInventoryFeb","inventoryFeb","reportedInventoryFeb","reportedInventoryFebHasOverride","sourceInventoryMar","inventoryMar","reportedInventoryMar","reportedInventoryMarHasOverride","sourceInventoryApr","inventoryApr","reportedInventoryApr","reportedInventoryAprHasOverride","sourceInventoryMay","inventoryMay","reportedInventoryMay","reportedInventoryMayHasOverride","sourceInventoryJun","inventoryJun","reportedInventoryJun","reportedInventoryJunHasOverride","sourceInventoryJul","inventoryJul","reportedInventoryJul","reportedInventoryJulHasOverride","sourceInventoryAug","inventoryAug","reportedInventoryAug","reportedInventoryAugHasOverride","sourceInventorySep","inventorySep","reportedInventorySep","reportedInventorySepHasOverride","sourceInventoryOct","inventoryOct","reportedInventoryOct","reportedInventoryOctHasOverride","sourceInventoryNov","inventoryNov","reportedInventoryNov","reportedInventoryNovHasOverride","sourceInventoryDec","inventoryDec","reportedInventoryDec","reportedInventoryDecHasOverride","sourceInventoryAggregatedString","inventoryAggregatedString","reportedInventoryAggregatedString","sourceInventoryAvr","inventoryAvr","reportedInventoryAvr","_getInventorySupplyAggregateInfo","reportedInventoryAvrHasOverride","reportedInventoryAvrCalculated","inventoryAvrCalculated","reportedInventoryAvrIsCalculated","sourceNetBookValue","netBookValue","reportedNetBookValue","reportedNetBookValueHasOverride","alternativeAcqDateDescriptorName","alternativeCostDescriptorName","sourceCompanyId","sourceCompanyCode","reportedIsAnchored","isAnchored","reportedDoNotPotentiallyDispose","doNotPotentiallyDispose","reportedIsLocked","lastReturnDescription","lastReturnId","reportedSiteAddressHasOverride","reportingSiteAddress","sourceSiteAddress","jan","feb","mar","apr","may","jun","jul","aug","sep","oct","nov","dec","monthWithValue","totalMonthsValue","populateMonthInfo","monthValue","average","AssetInfoService","calculatedCostUpdated$","_calculatedCostEventEmitter","costAdjustments","_costAdjustments","selectedCompanyId","_selectedCompanyId","clearValues","calculatedCost","costAdjustmentDescription","costAdjustmentCalculations","calculateCostsAndCheckTotals","sourceFieldValue","assets","_calculateCosts","_checkAssetsMatchCalculatedSourceCost","runningTotal","hasSourceValue","adjustmentsFound","extendedCostAdjustmentTypes","costAdjustmentTypeId","adjustmentAmount","typeName","adjustmentPercentage","percentCalcRh","applyToSource","adjustmentAmountFromPercentage","calculatedCostValue","hasAdjustments","expectedTotal","allocatedTotal","asset","assetValueMatched","AssetDetailsComponent","ModalComponentBase","closeWithDirtyCheck","_assetInfoService","_keyValueDisplayPipe","savedModels","newAssetCompanyId","initialReportingAssetIds","totalsModel","assetTitle","createNewAsset","hasNonRyanInternalComments","hasRyanInternalComments","isReturnAsset","assetListLienDate","isFromLockedReturn","fromLockedReturn","isFromLockedAllocation","fromLockedAllocation","alternativeAcqDateDescriptorId","busyMsgLoadAsset","resultFromRepository","updatedOverrideLienDates","_setAssets","assetInfo","isFormDirty","toggleIsExpandedForAssetInfoPanel","isMaximizedAssetInfoPanel","isExpandedAssetInfoPanel","toggleIsMaximizedForAssetInfoPanel","toggleIsExpandedReturnFilingsPanel","isMaximizedReturnFilingsPanel","isExpandedReturnFilingsPanel","toggleIsMaximizedReturnFilingsPanel","toggleIsExpandedForAssetActivityPanel","isMaximizedAssetActivityPanel","isExpandedAssetActivityPanel","toggleIsMaximizedForAssetActivityPanel","enterAssetInfoEdit","isAssetInfoComponentInEditState","cancelAssetInfoEdit","updateAssetDescriptors","selectedAssetDescriptors","setCurrentAssetModel","currentAsset","assetInfoIsReady","isReadyAssetInfoComponent","saveAssetInfoEdit","saveNewUserCreatedAsset","updateModels","ownershipTypeId","reportingParcelId","reportingAssets","acqDateAssetDescriptors","costAssetDescriptors","nonNullAdjustments","cat","ca","resultsFromRepository","propertyUpdates","ownershipType","acquisitionDate","_lienDateChanged","busyMsgSaveAsset","onLienDateChanged","lienDateDate","assetModel","assetAdjustmentSetId","assetIndex","ReturnAssetDisposalsListGridActionCellRendererComponent","returnAsset","ReturnAssetDisposalsListComponent","onSortChanged","totalsRow","assetModelRow","disposalAssetNumber","totalCost","reportedValue","totalReportedValue","totalPriorCost","totalCostChange","gridTotalsRow","_gridMultiSelectSub","_updateOccurred","createMultiSelectSubs","isClassificationUpdateButtonVisible","_viewAssetDetails","inputParams","initialIds","savedReportingAssetIds","_refreshNeeded","finalColumnDefs","pinnedRowCellRenderer","priorDepreciationFactorTableName","priorDepreciationFactorTableLife","depreciationFactorTableName","depreciationFactorTableLife","priorSiteName","priorAcqDate","priorScheduleName","changeText","handleTotalsUpdate","showPriorScheduleField","updateWorkingSetReportingAssetIds","ReturnSummaryReconciliationReportComponent","_showEstimatedFMV","navigateToAssets","navigateToAssetsAssignedToNoSchedule","filterAcquisition","filterTransferIn","filterCostChange","navigateToAssetsAssignedToNonReportableSchedule","navigateToAssetsAssignedToReportableSchedule","navigateToAdditions","filterReportabilityChange","navigateToDeductions","filterDisposed","filterTransferOut","isDisposalOrTransferOut","ScheduleAdditionsDisposalsReconciliationReportComponent","hideEmptySchedules","_refreshReport","navigateToReturnTotals","isForAdditions","isForNonReportableAssets","isForReportableAssets","isForUnassignedAssets","navigateToReturnDisposals","_loadReport","_refreshCanNavigate","_localReturnOverviewServiceSharedState","_blankReport","FilingControlReconciliationReportComponent","assetFilter","primaryFormRevisionId","navigateToPreview","filingControl","localFormRevisionsTimestamp","sharedFormRevisionsTimestamp","ReturnOverviewComponent","returnPartServiceForInterPartComponent","_hasForms","groupOptions","_consolidatedOption","onSelectedReconciliationReportChange","WsUniqueYearValidator","yearControls","wsUniqueYear","BaseExpandableComponent","expandableComponentContainer","expandComponent","collapseComponent","AssessorService","WeissmanFactorTableTypeNamePipe","factorTableType","GridSourceOptionEnum","DisplayMode","PanelView","FactorTableDetailsComponent","_assessorService","_factorTableRepository","Details","_filterCompanies","View","fCore","fCoreState","fCoreCompany","fCoreAssessor","fYears","fAges","fFloors","fYearsHaveValidationErrorsRequired","fYearsHaveValidationErrorsUnique","_displayMode","_factorTableDetailModel","usedInReturn","clearAssessorEnabled","Add","CopyFrom","DisplayModeEnum","newFactorTableParams","coreGroup","tableName","tableLife","tableRetiredTaxYear","stateGroup","companyGroup","assessorGroup","floors","_yearControlValueChangedSub","_refreshYearControls","busyMsgInitializing","tableParams","isCopyFrom","life","transferId","taxYearValues","taxYearFloors","retiredTaxYear","selectedCompany","editCompany","_updateFormFromModel","addAge","onAssessorSelected","onAssessorClear","onAssessorBlur","insert","_createYearControl","_createFactorControl","_createFloorControl","removeYear","yearIndex","removeAt","factors","factorArray","ageGroup","ageIndex","addFloors","floorsByYear","floorArray","floorGroup","floorIndex","removeAge","onCompanySelected","typeAheadMatch","onCompanyBlur","_availableCompanies","onCompanyLoadingChange","companiesLoading","setViewSelection","selectedView","_updateModelFromForm","busyMsgSaving","preparePPReturnsOnly","maxAge","coreValues","factor","onlySelf","emitEvent","companyEditing","saveCompany","ReturnAssetDragAndDropService","_dragulaService","_activeSubject","_draggingSubject","_draggingOverSubject","_droppedSubject","getAssetIdsFn","getAssetsFn","_getAssetIdsFn","_getAssetsFn","createGroup","BAG_NAME","getDragulaOptions","drag","dragend","over","out","drop","draggedAssetIds","droppedEvent","getSelectedAssets","copyItem","revertOnSpill","removeOnSpill","accepts","sibling","CONTAINER_TYPE_SOURCE","moves","ReturnAssetDragAndDropSourceComponent","_returnAssetDragAndDropService","dragulaContainerType","dragulaBagName","active$","isServiceActive","ReturnAssetListAgGridDataSource","getSelectedRowTotals","dataSourceResult","_getAllRowTotals","ReturnAssetListGridActionCellRendererComponent","ReturnAssetListComponent","selectedTotalsRow","selectedTotals","totalPriorReportedValue","totalN1","totalN2","totalN3","totalN4","totalN5","totalN6","totalN7","totalN8","totalN9","totalN10","totalInventoryJan","totalInventoryFeb","totalInventoryMar","totalInventoryApr","totalInventoryMay","totalInventoryJun","totalInventoryJul","totalInventoryAug","totalInventorySep","totalInventoryOct","totalInventoryNov","totalInventoryDec","totalInventoryAvr","totalEstimatedFMV","gridSelectedTotalsRow","totalsLoading","clearInterval","_getDraggedAssetIds","_getDraggedAssets","scheduleAndFactorFilter$","_refreshAssets","_setGridTracker","_tabActive","isBulkUpdateButtonVisible","_reloadTotals","sourceGlAccountId","glAccountClassificationId","ws","isRelatedToPriorReturn","defaultFormScheduleId","defaultFormDepreciationTableId","indexFactorTableId","indexFactorTableName","indexFactorTableLife","defaultFormIndexTableId","estimatedFMVOverridden","_cellClassForOverrides","updateReturnAssetSearchModel","_refreshRows","localAssetFormRevisionId","sharedAssetFormRevisionId","localAssetStatusFilter","sharedAssetStatusFilter","localAssessorFactors","sharedAssessorFactors","localScheduleAndFactorFilter","sharedScheduleAndFactorFilter","_loadAssets","gridRow","getRowNode","colNameForSource","ReturnAssetDragAndDropTargetComponent","CONTAINER_TYPE_TARGET","dragging$","draggingOver$","draggingOver","dragulaElRef","dropped$","assetsDropped","getOverlayTitle","scheduleDescription","depreciationTableLife","ReturnAssetStatusSelectorComponent","isDeduction","newAssetStatusFilter","transferInAssetStatusFilter","newOrTransferInAssetStatusFilter","changedCostIncreasedAssetStatusFilter","changedToReportedFilter","allAdditionsAssetStatusFilter","disposedAssetStatusFilter","transferOutAssetStatusFilter","disposedOrTransferOutAssetStatusFilter","changedCostDecreasedAssetStatusFilter","changedToNotReportedFilter","allDeductionsAssetStatusFilter","allAssetStatusFilter","changedAssetStatusFilter","notChangedAssetStatusFilter","assetAdditionsStatusFilter","assetDeductionsStatusFilter","assetStatusFilters","selectedFilterValue","selectedValueChange","setOptionsToSuppress","onSelectedAssetStatusFilterChange","selectDeductions","selectedAssetStatusFilterEl","selectedIndex","disableDeductionsDisposalsOrTransferOuts","reportDataSource","disableDeductionsOtherThanDisposalsAndTransferOutOrTotalDeductions","ReturnAssetFormStatusSelectorComponent","selectedAssetStatusFilter","_assessorFactorSub","assessorFactorsFilter$","_refreshAssetStatusFilter","ReturnAssetFormFactorSelectorComponent","isMappingCertified","isUsingDefaultMappings","pairwise","_autoSelectAssessorFilter","onSelectedAssessorFilterChange","_getAssessorFactorsFilterFromSelectedAssessor","selectedAssessorFilter","_ANY_ASSESSOR_OPTION","_selectedFormRevisionAssessors","assessorFilters","assessorsThatUseDefaultTables","assessorsThatUseCustomTables","_DEFAULT_ASSESSORS_OPTION","ReturnAssetFormScheduleComponent","scheduleForUnassignedAssets","scheduleForNonReportableAssets","scheduleForReportableAssets","groupedScheduleDetails","scheduleDetails","isTaxable","depreciationTableName","depreciationFactor","exemptCost","isScheduleActive","isScheduleDetailActive","onScheduleClicked","scheduleClick","onScheduleDetailClicked","scheduleAgeClick","ReturnAssetFormDetailsComponent","hasSchedules","scheduleFilterEnabled","observableMerge","assetStatusesFilter$","separateFactorTablesFilterDisabled","_refreshSchedules","requestUpdatedSchedules$","_loadSchedules","_applyFilters","hasFilters","separateFactorTablesFilterChange","hideEmptySchedulesFilterChange","onScheduleAndFactorFilterClick","onScheduleAgeFilterClick","onAssetsDropped","_updateNonReportable","assetAssessors","assessorFactorTableAssociations","_submitAssetUpdateModel","_updateAssets","raam","_blankSchedules","_unassignedScheduleData","unassignedSchedule","nonReportableSchedule","reportableSchedule","aggregatedSchedules","aggregatedSchedule","assetIds","formScheduleId","assessorFactorTableAssociationModel","ReturnAssetsComponent","ReturnOutputPackageListDropdownCellRenderer","_editModeSub","editMode$","mouseover","mouseout","relatedTarget","outerDiv","dropdownItem","dropdownItems","valueField","displayGetter","ReturnOutputPackageListComponent","_returnOutputService","returnPackageId","_mailingTypes","_mailingTypeChanged","_mailTypesTableRenderer","rowIds","_packageData","returnMailingTypeName","returnPackage","returnMailingTypeId","ReturnOutputPrintingMailingComponent","onOptionChange","ReturnOutputComponent","packagesSelected","printingOptionsSelected","showOutput","disableDownload","ReturnSettingsOverrideComponent","_returnSettingsService","$ref","ReturnSettingsReportAddComponent","allReports","fb","_availableReports","_selectedRowsSub","rowsSelected","suppressMovable","savedSearchCategoryId","savedSearchCategoryID","ReturnSettingsReportListGridActionCellRendererComponent","ReportManagerModalComponent","handleSaveModalClose","savedReport","ReportManagerModalService","showForFormRevision","showForFilingBatch","AgGridFilterToggleComponent","_isFiltered","ReturnSettingsReportListComponent","_reportManagerModalService","added","_canEdit","_canEnterEditMode","_edit","getEditTitle","_getEditTitle","canRemove","_canRemove","canUndoRemove","_canUndoRemove","undoRemove","_undoRemove","_setReports","newReports","reportRow","selectAdditionalReports","_reports","filingBatchReportRow","ReturnSettingsGeneralComponent","_returnAssetService","reportNBVInsteadOfFactoredCostControl","returnCostReportingDisplayControl","reportNBVInsteadOfFactoredCost","returnCostReportingDisplayId","_generalSettings","_setSettings","_reportNBVInsteadOfFactoredCost","_returnCostReportingDisplayId","reportNBVInsteadOfFactoredCostChanged","returnCostReportingDisplayChanged","showReportNBVInsteadOfFactoredCost","supportsNBVReporting","showReturnCostReportingDisplay","supportsEstFMVReporting","ReturnSettingsTabComponent","showGeneralReturnSettings","ReturnPartsComponent","heading","deactivate","assetsTab","activationParam","tabset","previewTab","overviewTab","settingsTab","outputTab","_returnServiceStartSub","_returnAssetsSelectedSub","_returnPreviewSelectedSub","tabDeselected","fromClick","ReturnAssessorAddressChangedMessageComponent","_formRevisions","showWarning","_updateValidation","_setCanShowMessage","formWarnings","canShowMessage","ReturnPageComponent","attachmentsHelpContentId","commentsHelpContentId","_loadFilingBatchInfo","_isPrepareDataLongRunningProcess","isPrepareDataLongRunningProcess","_loadData","_progressStatusSub","_handleStatusChange","_lockChangedSub","_progressSub","refreshBatch","intervalMessageIndex","busyConfig","_userMessages","intervalId","_validateForms","navigateToUnauthorized","_handleProgressError","navigateToFilingBatchDetails","canUserEditReturns","defaultMessage","FilingControlListReconciliationReportComponent","_updateTotal","_isInitialLoad","_updateSelectedRowsTotals","siteProperty","priorFilingId","priorFilingDescription","calculatedPriorFilingId","primaryFormRevisionName","_getSelectedRows","potentiallyConsolidatedParcels","hasConsolidatedParcels","potentiallyConsolidatedParcel","mergedParcels","isInvalidSelection","numberOfParcelsToRemove","getPinnedBottomRowCount","getPinnedBottomRow","priorYearDepreciationValue","FilingControlReconciliationReportAssessorRenderer","toggleExpanded","resetRowHeights","AgGridConsolidatedGroupCellRenderer","FilingControlGroupedReconciliationReportComponent","_isFullWidthRow","_groupBy","toggleShowMergedParcels","_toggleShowMergedParcels","FilingBatchListGridActionCellRendererComponent","FilingBatchListAgGridDataSource","includeCompleted","getSearchModel","FilingBatchProgressCellRendererComponent","FILING_BATCH_LIST_HELP","FilingBatchListComponent","completedDate","reportExportHelp","resume","_onProgressViewDetails","_viewTasks","_onViewDetails","_canDelete","exportReconciliationReport","gridModel","onIncludeCompletedChange","_deleteFilingBatch","_navigateToFilingBatchDetails","_selectedRowModel","FILING_BATCH_DETAILS_HELP","AMEND_RETURNS_HELP","AmendReturnsComponent","FilingBatchDetailsService","currentFilings","_filings","FILING_BATCH_INFO_HELP","ComplianceInfoRepository","getDeadlines","FilingBatchInfoComponent","_complianceInfoRepository","fState","tasksHelpContentId","_filingBatchChangeSub","filingCount","statusDate","statesTypeAheadDataSource","statesTypeAheadAsyncSelected","getStatesAsObservable","deadlines","stateDeadlines","deadline","_stateDeadlineMap","_isInitialized","_isSecondDeadlineEarlierThanFirst","firstDeadline","secondDeadline","firstDate","deadlineMonthDay","_getDateFromDeadlineAndTaxYear","busyMessageId","_saveModel","onFilingBatchChangesCancelled","onStateSelected","updateDeadlineForStateAndTaxYear","onStateBlur","_findEarliestDeadlineForStateAndTaxYear","earliestFoundDeadline","stateDeadline","exceptionDeadlines","ed","ad","deadlineYearID","onFilingBatchDeleted","addMode","displayId","_setReadOnlyFormFields","onFilingBatchCreated","onFilingBatchUpdated","markAsPristine","markAsUntouched","FilingBatchAccountsGridActionCellRendererComponent","onRemoveClicked","onUndoRemoveClicked","onEditClicked","FilingBatchAddAccountsAgGridDataSource","FILING_BATCH_ADD_ACCOUNTS_HELP","FilingBatchAddAccountsComponent","filingDescription","parcelActivityStatusId","selectedRowIds","addedFilingIds","FILING_DETAILS_HELP","FilingDetailsComponent","saveDisabled","_initialIsAmendment","_initialPriorReturn","selectedPriorReturn","priorReturns","priorReturnDescription","BaseExpandableAgGridComponent","_api","setGridApi","FILING_BATCH_MOVE_MODAL_HELP","RadioOptions","FilingBatchMoveModalComponent","Move","dateInvalid","radioOption","batchInfo","dateValidation","moveControl","availableTargets","Create","moveTo","sourceBatchRowVersion","targetBatchRowVersion","targetFilingBatch","targetFilingBatchId","FilingBatchMoveResultModalComponent","FILING_BATCH_ACCOUNTS_HELP","AgGridYesNoFloatingFilterComponent","conditionValues","FilingBatchAccountsComponent","_filingDetailsService","moveHelpContentId","addHelpContentId","_refreshSub","refresh$","calculatedPriorReturnId","priorFilingBatchId","floatingFilterComponentFramework","moveResultParams","moveCount","batchRowVersion","filingRow","filingReturnUpdateModel","availableFilingCount","_availableFilingCount","enteredEditMode","filingIdsToGet","selectedId","newFilings","_getFilingRowModel","numberOfFilingsAdded","_removeAddedFiling","numberOfFilingsRemoved","analyticsProperty","amendingPriorReturn","changeModel","hasPriorReturns","filingsChanged","_refreshAvailableFilingCount","calculatedPriorReturnDescription","isAvailableBusy","FilingBatchDetailsComponent","_filingDetailService","hasFilings","beginPreparationHelpContentId","continuePreparationHelpContentId","viewReturnsHelpContentId","refreshHelpContentId","filingBatchModel","navigateToFilingBatchList","amendReturns","navigateToReturnBatch","onFilingsChanged","showChangeDetection","FilingBatchModule","ReturnPreviewModule","scrolling","ReturnModule","ng2_dragula","agGridCheckboxCellRender_component","ComplianceCompanyModule","ContactListAgGridDataSource","ContactListPageComponent","_upgradeNavigationService","_openContactDialog","hasUser","ExtendedContactModelCore","ExtendedModelBase","nameStr","includeCompany","UserPickerComponent","usersOnly","includeBlank","SignatureType","SignaturePanelComponent","canvas","_signaturePad","_canvas","SignaturePad","onEnd","signatureChanged","canAddUser","authorizedUsers","userToAdd","authorizedUsersChanged","authorizedUsersChanges","signatureLoading","usersAuthorizedLoading","_getUserSettings","_getContactSig","beginSigEditMode","isSignatureEditMode","newContactSignatureImage","contactSignatureImage","clearSignature","imageFile","saveSignature","signatureType","toDataURL","cancelSignature","canvasRotation","signatureTypeChanged","uploadTypeError","imageCropped","base64","loadImageFailed","rotateImageLeft","rotateImageRight","beginAuthEditMode","isAuthorizedEditMode","cancelAuthorized","saveAuthorized","authUserModel","addUser","addNewPerson","removeUser","cancelAddUser","assignUser","sig","CompanyPermissionsService","excludeCompanyIds","serviceUrl","ApplicationPermissionService","getByContactIdScoped","UserSetupService","applicationPermissions","getUserDataScoped","UserModule","ngx_image_cropper","ContactModule","DescriptorValidationComponent","_helperService","picklistLoading","formats","savePicklistItem","picklistSaving","deletePicklistItem","descriptorPickListID","showPicklistItemInput","addingItem","itemToAdd","addPicklistItem","itemToAddText","picklistItemToAdd","PropertyCharacteristicsComponent","_descriptorHelperService","_descriptorPicklistService","hasComplianceFeatures","arccUsageColumnId","selectedCategoryId","descriptorCategoryID","fieldTypes","assetUsages","usage","aRCCUsages","_loadDescriptors","getARCCDescriptorUsage","getDescriptorFieldType","descriptorFieldTypeID","editDescriptor","descriptorToEdit","addDescriptor","newDescriptor","assessorUsageID","collectorUsageID","siteUsageID","parcelUsageID","companyUsageId","arccUsageId","sequenceNumber","saveDescriptor","_getValidationError","descriptorIsSaving","deleteDescriptor","deletingDescriptorId","showPicklistValuesModal","picklistValuesModal","shouldDisableEditButtons","isSystemControlled","canSaveDescriptor","PropertyCharacteristicsModule","CompanyModule","AddInstanceModalComponent","instanceForm","instanceType","_instanceNameChanged","instanceTypes","addInstance","instanceTypeId","currentTeamName","_previousInstanceName","CarouselComponent","goToSlide","currentSlide","currentSlideChange","nextSlide","slides","prevSlide","NavOnboardingComponent","_topNavService","imageUrl","progressBtnLabel","fromHashChange","showOnboardingBanner","OnboardingBannerComponent","showOnboardingModal","branding","logoTitle","footerPortalTitle","footerPortalHref","footerText","TopNavService","_sideNavOpen","_bannerMessage","sideNavOpen$","_sideNavOpen$","sideNavOpen","bannerMessage","bannerMessage$","_bannerMessage$","hasManageAPIKeys","hasAdminOperationsView","hasComplianceSetupsView","hasContactRoleRoles","hasViewRyanPrivatePermissions","hasUserGroupViewOrEdit","hasPropCharsRoles","hasValuationTemplateEdit","hasCompanyDataImportsView","hasContactRoles","hasAgentInfo","hasTeamViewOrEdit","hasAllowDataImports","hasAddNewCompanyRole","hasAddNewInstanceRole","hasUserGroupEdit","hasEditRyanPrivatePermissions","hasComplianceSetupsEdit","hasAdminOperationsEdit","hasLicensedDocumentServices","hasSupportRole","hasAdminRole","AdminComponent","FormControl","amplitudeProperty","manageAdminImport","_enableLicensedDocumentIntakeAndProcessing","showManageInstancesMenuItem","enableLicensedDocumentIntakeAndProcessing","adminOptions","_allManageOptions","_setAdminControlValue","globals","_destroyTransitionHook","adminControl","newInstance","routerState","ManageAPIKeysService","getPublicKeys","getPublicKey","integrationHmacId","savePublicKey","integrationHmac","sendKeyEmail","publicKey","createNewKey","keyName","deleteKey","TypeaheadCompany","typeaheadOnSelect","inputChanged","ManageAPIKeysComponent","manageAPIKeysService","addingKey","loadKeys","apiKeys","addNewKey","newKeyName","newCompanyId","newCompanyValidationMessage","newKeyNameValidationMessage","saveKey","cancelAddKey","apiKey","LoginManagerService","loadUser","getIAMUserData","updateLockedFields","unmigrateUser","getIAMTenantData","removeUserIAMTenant","updateUserIAMTenantId","tenantId","LoginManagerComponent","_loginManagerService","selectedInstanceChanged","loadContact","cancelUserAction","busyIndicator","homeInstanceName","userActionState","startManageIAMUser","iamUserData","updatingUserIAMId","startManageIAMTenant","iamTenantData","updatingUserTenantId","startUpdateLockedFields","newFirstName","newLastName","newIsMigrated","startUpdateUserIAMId","newIAMId","saveUserIAMId","performUserAction","cancelUpdateUserIAMId","unMigrateUser","startUpdateUserIAMTenantId","newIAMTenantId","saveUserIAMTenantId","cancelUpdateUserIAMTenantId","toggleNewIsMigrated","saveLockedFields","IntegrationHmacUserDetail","userTeamMember","integratonHmacUserId","APIKeyDetailComponent","addingUser","inEditMode","integrationHmacDetailBackup","integrationHmacDetail","backToManage","edit_click","keyNameValidationMessage","cancel_click","save_click","deleteKey_click","sendEmail","beginAddUser_click","setNewUser","cancelAddUser_click","saveAddUser_click","integrationHmacUserId","AboutService","getAllAppVersionInfo","GetUIVersionInfo","getJSReportVersionInfo","AboutComponent","aboutService","reportVersionInfo","allAppVersionInfo","uiVersionInfo","TestDXPPageComponent","AdminModule","LogoutMessageComponent","loggingOut","modals","getElementsByClassName","backdrops","logoutMessage","loginClick","iamLogoutClick","NUB_HELP","NubService","showNub","_activeNub","_showQuickSearch","searchTooltip","activeNub$","_activeNub$","_showQuickSearch$","showActionViewNub","_actionViewNub","showAdvancedSearchNub","_advancedSearchNub","_quickSearchNub","showQuickSearch","NubComponent","_nubService","_uiRouter","nub","AceAuthOidcWrapperComponent","iamEndpoint","endpointMatch","authSettings","authApi","iamAudience","redirectUri","homeRealmDiscovery","postLogoutRedirectUri","immediatelyStartAuthentication","overrideAuthResponse","authority","knownAuthorities","logoUrl","logoHeight","_authElement","AppComponent","_easyAccessService","aceOidcWrapperEnabled","isAttachmentPopup","setTheme","handleAuthResponseOverride","handleAuthresponse","idToken","gmapsLoaded","easyAccess","ForecastingBudgetingBulkUpdateModalComponent","selectableTaxYears","availableEditActions","commonEditActions","selectedAltAsmtView","totalFmvEditActions","altFmvEditActions","budgetModeTaxYearSpecificEditActions","yoyPercentDisplay","editActionChanged","fmvValueLabel","yoyPercentLabel","isTaxYearEnabled","isFmvValueEnabled","isYoYPercentEnabled","fmvValueBlur","_isValidNumericValue","fmvValueDisplay","yoyPercentBlur","saveable","AddCompanyBudgetModalComponent","availableFiscalPeriods","strFYBegin","momFYStart","existingBudgets","isBudgetNameUnique","createdBudget","addInProgress","ForecastCreateMissingComponent","createMissing","createClick","isMissingCreateAllowed","lrUpdateInProgress","BudgetTaxYearCreateMissingComponent","isBudgetFrozen","BudgetTaxYearSyncBudgetsComponent","syncBudgets","syncClick","isSyncBudgetsAllowed","ForecastingBudgetingPageComponent","singleClickEdit","dynamicColIdx","_lrTypeMapping","subscriptions","priorYears","populateBudgetNameDropdown","_setFiltersAndLoadData","isData","modeChanged","showFilterApplyButton","selectName","taxYearsChanged","selectedBudgetBasisChanged","showBudgetApplyButton","savingBudget","loadNewColumnData","newBudgetAdded","activityStatusesSelected","applyFilters","createMissingForecast","createMissingBudgetTaxYear","confirmActionOnPendingStatus","isFreezeUnfreezeAllowed","counts","confirmTitle","confirmMsg","curBudget","proceed","isPendingStatusSelected","areSelectionsGiven","numPendingSelected","gatherBulkUpdateSelections","processBulkUpdateRequest","bulkUpdateEntityType","executeBulkUpdate","bulkUpdateProgress","curEntry","getCurrentBulkUpdateSelection","getCurrentBulkUpdateDistributedFMV","cancelBulkUpdate","distributionFMVs","overallDistributionFMV","totalFMVSelected","fmvValue","busyRefId","BudgetModule","BulkImportAssessmentsModel","BulkImportSitesModel","BulkImportService","importAssessmentData","importSiteData","importParcelData","BulkImportAssessmentsComponent","assessorService","bulkImportService","initValues","isImporting","userCancelled","initIndex","fileLines","successfulImportCount","stateSelected","fileChanged","startImporting","successfullyImported","cancelImport","DisplayStringArrayModel","DisplayStringArrayComponent","ImportType","BulkImportSitesComponent","topCompanyID","hasFile","userCancelling","stringArray","clearFilePicker","fileInput","fileText","lines","blankIndex","validateOnly","_createOutputFile","totalProcessedRows","performImport","bulkImportResult","criticalErrors","validationResults","numberOfValidRows","importType","Parcel","Site","stringLines","finalString","outputFile","revokeObjectURL","BulkImportModule","DiagnosticsModule","AttachmentModule","CollectorService","DocumentIntakeService","DocumentIntakeComponent","_collectorService","_cdr","_documentIntakeService","requests","enableAssignToRyan","enableIntakeToLicensedInstance","instanceHasIdpEnabled","documentIntakeUsers","documentIntakeSettings","_assignToRyan","licensedClients","initializeForm","batchDocument","splitDocument","shouldDisplayAssignToRyan","shouldDisplayPerformOCR","documentTypeID","pagesPerItem","excludeFirstXPages","assignedQC","assignedEntry","ultimatelyResponsible","earliestDueDate","assignToRyan","_defaultContact","pageExclusionChanged","pageCount","pagesPerItemList","_startCheckPageCount","resetExclusionInput","ultimatelyResponsibleChosen","stateChanged","assessorList","collectorList","collectorsLoading","isUploadDisabled","singleFile","multiFiles","filesPicked","MAX_FILE_NUM","selectInstance","selectedInstanceName","ryanUltimatelyResp","ryanAssignedEntry","ryanAssignedQC","licensedClient","intakeToLicensedInstanceChanged","removeSingleDocument","viewMultiFile","multiFileViewer","selectedMultiFile","removeMultiFile","uploadClicked","_createBatch","assignToRyanChanged","togglePerformOcr","performOcr","selectDocumentCount","assignedQcChanged","documentTypeSelected","docType","DocumentType","earliestDueDateChanged","numDays","DaysToEarliestDueDate","assessorChanged","collectorChanged","taxYearChanged","commentChanged","pageCountTimer","PDFViewerApplication","pagesCount","_preparePageCount","countTotal","invalidPageCount","_getPagesPerItem","uploading","NAVIGATE_WARNING","totalPages","pages","DocumentIntakeLicensedClientDetailComponent","busyLoading","client","clientContactName","clientContact","assignedEntryChosen","assignedQCChosen","groupSelected","updateUsers","DocumentIntakeLicensedClientListComponent","_documentIntakeLicensedClientDetailRepository","getStatus","cancellationDate","configure","DocumentsModule","SnackComponent","loadingWaitComplete","cancelDisabled","SnackBarComponent","longRunningProcesses","snacks","displayState","processIdTracker","SnackMessageComponent","snackBar_service","processes","processing","snackBar_module_hybridAdapterUtility","SnackBarModule","SideNavComponent","stateJurisdictionCommandCenter","taxRateCommandCenter","paymentBatchCommandCenter","_setLoggedInMenu","_setLoggedOutMenu","currentUrl","hiding","routeTo","handleActionTriggered","menuAction","_analytics","isHeading","routerLink","commandCenters","_getCommandCenters","navActions","aceColorLookup","fgWhite","AceBannerComponent","colorModel","BannerState","displayIcon","suppressDefaultIcon","isNarrow","contentIsComponent","createComponent","handleClose","closing","dismissed","ViewContainerRef","TopNavComponent","AceUIIcon","showInstanceFilter","_isAttachmentPopup","showBanner","_processLRP","_destroyRouteListener","entering","currentAction","toggleSideNav","dismissBanner","commands","chromeActions","isLoggedIn","profile","_profileMenu","menuOption","isDivider","_searchMenuOption","_helpMenuOption","completeProcesses","activeProcesses","_snackMenuOption","NavigationModalsModule","NavigationModule","NewPasswordComponent","passwordIncorrect","incorrect","currentPasswordValid","doesNotMatchUsername","isNotAlreadyUsed","confirmMustMatchNew","passwordsChange","passwordsValidChange","ChangePasswordComponent","modelState","_setNewValidation","goToHome","LoginPageModesEnum","LoginComponent","passwordResetEmailHasBeenSentMessage","showSpinner","showGetNewTokenButton","rememberSSODomain","rememberSSOEmail","SAVE_SSO_EMAIL_KEY","newAppState","isSSOEnabled","currentMode","isIAMMigration","selectSSODomain","loginWithSSO","useToken","LAST_SSO_DOMAIN_KEY","loginDomain","showLogin","setFocus","errorHandler","migrateResult","startAuthOidcLogin","didSucceed","ssoRequest","resetPassword","passwordObj","showResetPaswordFormAgain","submitHomeRealmDiscovery","initialData","migrationSSOExceptionEndpoint","initializeSSOLogin","needsMigration","migratePassword","redirectUrl","authenticate","forceLogin","switchToSSOMode","overrideEndpoint","awaitingSSO","cancelSelectSSODomain","setRememberSSODomain","AppealApplicationSetTopModalComponent","topAppealCandidates","appealFormList","isTopAppeal","_originalTopAppealFormRevisionId","topAppealFormRevisionId","AppealApplicationViewerComponent","selectedForm","loadForm","processAppealOverrideMultiAccountIndexes","overrideAccountIndexLookup","multiAccountOverrides","appealFormRevisionOverrideId","selectTopAppeal","topAppealSelected","isFormLoading","appealFormReference","_processSingleFieldChange","relatedId","relatedFieldData","_deleteSingleOverride","fieldOverrides","fieldOverride","appealFormItem","currentAccountIndex","perAccountField","inEdit","otherReferences","topFormReference","cleanedOverride","APPEAL_APPLICATION_HELP","DownloadAppealFormComponent","appealForms","includeSupplementalForms","supplementalForms","downloadRequest","batchAppealIds","onlyTheseFormRevisions","zipOutput","skipOptimize","EditAppealSupplementAssociationsComponent","Subscription","_APPLY_CHANGES_SCOPE_OPTION_ALL_SELECTED_APPEALS","selectedAppeal","_APPLY_CHANGES_SCOPE_OPTION_SELECTED_APPEAL","_refreshAppealFormRevisions","isAssociated","isAssociatedInitial","canAddToAppealTotal","busyMessage","updates","parentAppeals","supplementalFormRevisionId","associate","totalAppeals","canRemoveFromAppealTotal","allPossibleSupplementAssociations","possibleAssociationsForSelectedAppeal","possibleAssociation","supplemental","AdditionalAccountTooltipComponent","EditAppealMainAssociationsComponent","appealMainFormAssociation","mainForms","newMainFormRevisionId","AppealApplicationListComponent","overrideChange$","overrideChange","changedItem","hasOverrides","_getAppealList","formSelectedOnList","selectedAppealFormRevisionId","formSelected","downloadAppealDocument","editAppealSupplements","_availableSupplementalForms","editAppealMainForms","_availableNonMultiAccountMainFormsFor","canChangeMainForm","toggleHovered","hoveredAppealFormRevisionId","canChangeSupplements","isMultiAccount","supplements","appealsNeedingCaching","appealFormListFetched","afl","supplementalTemplate","appealTemplate","defaultForm","defaultSelectedAppealId","_getAvailableSupplementalForms","_getAvailableMainForms","_availableMainForms","AppealFormSettings","AppealFormDropdownSettings","ownerAddress","agentContact","agentAddress","agentPhone","signer","signerType","ctx_r67","ctx_r74","AppealApplicationSettingsComponent","getInstanceIdForAppeal","groupNumberMap","saveSetting","groupNumber","otherModel","appealFormSettingLookups","appealRevisionFormIds","exceptions","appealFormRevisionIds","appealFormSettings","agentContactOtherValue","signerOtherValue","otherValue","checkIfSignatureMayBeAppliedResult","multiAccountSettingChanged","settingsChanged","setFlagApplyDigitalSignature","_getDropdowns","_getSavedSettings","optionArr","agentContactOtherId","signerOtherId","AppealApplicationComponent","initBusyRef","appealBatchId","serializedAppealIds","_appealApplicationChangeSub","onAppealFormListRetrieved","af","onViewerTabSelected","_event","haveSettingsChanged","appealApplicationViewer","hasMultiAccountSettingChanged","originalAppealIds","newTopAppealFormRevisionId","topAppealId","additionalTopAccounts","otherAppealIds","generateOutput","useLRProcess","isDownloadingForms","downloadEditable","downloadFlat","isCompleting","_goBackToPreviousState","ExpandCellRendererComponent","ExpandCellHeaderRendererComponent","AppealRecommendationGridRowInfoTreeItemModel","accountHandlerUserId","appealRecommendationStatus","appealRecommendationStatusId","canChangeAppealRecommendationStatus","currentAV","currentImpsAV","currentImpsFMV","currentPersAV","currentPersFMV","currentAltAV","currentAltFMV","currentLandAV","currentLandFMV","determineIfAppealWarrantedTaskId","emailSentDate","fmvVariance","isClientApproved","isClientApprovalRequired","originalAV","originalImpsAV","originalImpsFMV","originalPersAV","originalPersFMV","originalAltAV","originalAltFMV","originalLandAV","originalLandFMV","parcelAccountNumber","priorYearAppealId","priorYearAppeal","priorYearAV","priorYearFMV","priorYearImpsAV","priorYearImpsFMV","priorYearPersAV","priorYearPersFMV","priorYearAltAV","priorYearAltFMV","priorYearLandAV","priorYearLandFMV","responsibleUser","topLevelCompanyName","totalDollarSqFt","totalDollarUnit","totalLandDollarAcre","totalLandDollarSqFt","totalPriorYearDollarSqFt","totalPriorYearDollarUnit","totalPriorYearLandDollarAcre","totalPriorYearLandDollarSqFt","AgGridTooltipCellRendererComponent","getTooltipText","cellText","DESCRIPTOR_COLUMN_DEFINITIONS","getDescriptorValue","getDescriptor","assessorUsage","isDescending","AppealRecommendationCommandCenterGridActionCellRendererComponent","APPEAL_RECOMMENDATION_HELP","AppealRecommendationTemplateLastSentHelpComponent","sentInfos","sentInfo","uniqueInfo","sentDate","isSameDateSamePerson","totalParcelsCount","_trimValue","getUserName","userLastName","userFirstName","APPEAL_RECOMMENDATION_TEMPLATE_DETAILS_HELP","AppealRecommendationTemplateDetailsComponent","hasEditSystemSearch","_hasDuplicateName","emailBodyTemplate","showPriorYear","showYearBuilt","showAcquisitionInfo","showInitialValue","embedInEmail","includeSiteComment","attachChart","saveHelpId","existingTemplates","ctx_r76","AnalyticsEvent","AppealRecommendationTemplateComponent","_sanitizer","Options","toFilter","_filterRecipients","ccFilter","optionsPanel1","_optionsPanel1","_setConsistentPanelWidth","optionsPanel2","_optionsPanel2","enableAppealRecommendationEmailTemplate","_hasEditSystemSearchPermission","templates","_convertToListItem","_sortSavedTemplates","savedSettings","recipientFirstName","appealRecommendationInfo","_initialAppealRecommendationInfo","_siteDivisorDescriptors","siteDivisors","hasMultipleSites","hasMultipleAssessors","emailTemplateSubjectFields","emailTemplateBodyFields","_availableRecipients","emailBody","lastSentInfo","at","lastSent","sentInfoTooltip","parcelsCount","settingChanged","hasNotSavedChanges","_appealRecommendationInfo","_savedSettings","editing","_selectedTemplateId","changeTab","subjectField","setSelection","bodyField","bodyBlur","downloadEmail","toId","ccId","cc","_saveSettings","getCheckboxHelpContentId","onToBlur","_selectTo","onToSelected","recipientRoleOne","onCCBlur","_selectCC","onCCSelected","recipientRoleTwo","refreshTemplate","commentSiteChanged","attachmentSiteChanged","existingAttachment","disableCategories","showEmailAttachmentButton","attachmentName","eventProperties","removeAttachment","getCanIncludeAsAttachmentHelpContentId","canIncludePDFAsAttachment","_checkIfExceedsPrintableArea","ClickShowAcquisitionInfo","ClickShowYearBuilt","ClickShowAppealDeadlines","ClickShowAssessments","assessmentOptions","showAssessmentOptions","ClickShowMetrics","metricsOptions","showMetricOptions","ClickShowInitialValue","initialValueOptions","showInitialValueOptions","ClickShowTargetValue","targetValueOptions","showTargetValueOptions","ClickShowLatestValue","latestValueOptions","ClickShowTaxDetails","taxDetailsOptions","ClickShowSavings","savingsOptions","showSavingOptions","ClickEmbedChart","ClickAttachChart","includeInAttachment","editTemplate","savedTemplate","updatedTemplateIndex","updatedTemplate","onTemplateChanged","deletedTemplateIndex","userInitiated","canEditDelete","_canIncludePDFAsAttachment","_calculateNumberOfGridColumns","userInfos","_savedUserSettings","_settingName","savedTemplateId","p1","p2","panelSize","columnsCount","_getMetricsColumnsCount","defaultTemplates","customTemplates","attachChartOptions","APPEAL_RECOMMENDATION_COMMAND_CENTER_HELP","BulkUpdateDynamicBase","_isValidation","numberInvalid","textInvalid","isFormValid","bulkUpdateForm","verificationModified","fieldsModified","rowActionChanged","formControl","_actionModified","validationActionChanged","dateValueChange","markAsDirty","updateOptions","CurrencyInputComponent","currencyChanged","BulkUpdateActionComponent","hideField","hiddenField","removeOptionName","_formSub","ARCCBulkUpdateComponent","selectedRowsInfo","numberTemplate","picklistTemplate","textTemplate","currencyTemplate","_hasSelectedSites","_hasSelectedParcels","appealRecommendationStatusControl","addControl","appealRecommendationStatuses","formControlName","canChangeIsClientApproved","isClientApprovedControl","_getPicklist","descriptorInfo","siteUsage","controlName","_validators","parcelUsage","_bulkUpdate","appealRecommendationStatusOption","isClientApprovedOption","selectedSiteAnnualAssessmentIds","appealDeadlineStart","appealDeadlineEnd","assignedFilter","appealRecommendationStatusAction","isClientApprovedAction","isSiteLevel","picklistInfo","ARCCBulkUpdateResultConfirmationComponent","ignoredSites","ProcessAppealWarrantedComponent","cancelLabel","updateAppealRecommendation","runWithBuffer","_runModalResultWithBuffer","bufferSize","processingBufferOverride","chunks","processChunk","chunk","loadingMessage","tempResult","ProcessNoAppealComponent","revisionChangeTypeID","newRevisionDescription","ErrorNotificationComponent","TaskModalsService","AppealRecommendationCCAssignedFilterShowOptionEnum","AppealRecommendationCCAssignedFilterWhereOptionEnum","AppealRecommendationCCAssignedFilterThatOptionEnum","ARCCAssignedDetailsModalComponent","selectedOptionName","_originalCustomOption","specificUsers","addNewUser","specificTeams","_populateSpecificTeams","modifiedSelectedOption","predefinedOption","where","that","defaultCustomOption","MyTasks","MyTeamTasks","SpecificIndividualTasks","SpecificTeamTasks","optionName","reloadCustom","teamChanged","disableSubmit","selectedOptionValue","specificIndividualTasks","specificTeamTasks","ARCCAssignedComponent","_savedSelectedOptionSetting","optionChange","arccAssigned","_getNameFromEnum","_saveSelectedOption","arccShow","arccWhere","arccThatAre","ARCCComponent","_percentPipe","_taskModalService","customExportType","selectedRowsOrdered","_mappingViewData","_selectedRowIds","_assignedFilter","_hasSelectedRows","customExportFileFormats","_sitesOnlyExportOptionDisabled","disabledTooltip","_parcelsOnlyExportOptionDisabled","_canOpenEmailPreview","_showAppealRecommendationEmailModal","_canAcceptRecommendation","_acceptRecommendation","_siteRequiredFilterSet","hasError","columnNames","getColumnDef","arccFilteredColumn","_getDescriptorValue","_addDays","descriptorMetadata","_descriptorInfo","_picklistInfo","pickList","_appealRecommendationStatuses","_bypassDateRangeValidation","isRefreshDisabled","onAssignedFilterChange","_gridColumnApi","selectedEntityIds","_getCanChangeAppealRecommendationStatus","_getCanChangeIsClientApproved","_getVisibleDescriptorInfo","_setColumns","onAgGridFilterChanged","numberExpanded","hadRequiredSites","_collapsedSites","_sites","expandSites","filterMethod","_filterString","_filterDate","_filterNumber","_filterBoolean","_filterPercent","descriptorValue","_descriptorValues","_expandedSites","_redrawGrid","onAgGridSortChanged","emitStateAnalyticsEvent","arccState","emitDateAnalyticsEvent","today","arccBeginDate","arccEndDate","layoutChanged","selectedSiteIds","resultsParams","siteInfo","parcelInfo","descriptorValues","_searchTimestamp","searchTimeStamp","displayedDescriptorColumns","_populateMappingViewData","sortFunction","localX","localY","xValue","yValue","_expand","_collapse","_showHiddenParcels","_canExpand","_canCollapse","_canShowHiddenParcels","_filteredOutParcelsMap","_canExpandAll","_canExpandAllRows","_canCollapseAll","_expandAll","_collapseAll","gridValue","filterText","filterPassed","_filterCheckStringValue","someParcelsPass","_filterCheckDateValue","_filterCheckNumberValue","_filterCheckPercentValue","_filterCheckBooleanValue","sourceString","matchString","sourceCompare","matchCompare","sourceDate","matchDate","fixedSource","_updateDescriptor","updatedValue","updatedSiteInfo","setData","newDescriptorInfo","_updateTargetValue","siteNode","_updateAppealRecommendationStatus","annualAssessmentIds","_updateIsClientApproved","expand","collapse","canShowHiddenChildren","showHiddenChildren","getTooltip","expandAll","collapseAll","canExpandAll","canCollapseAll","headerText","AgGridDropdownCellEditor","valueSetter","AgGridNumberCellEditor","descriptorColumns","canEditParcel","canEditSite","accountHandlers","_uniqueNumberFilter","_uniqueGuidFilter","_getSelectedTaskIds","selectedSites","hasSelectedSites","selectedAppealRecommendationStatuses","selectedTaskIds","displayedRow","allErrors","uniqueErrors","allWarnings","uniqueWarnings","_addSeconds","getSeconds","AssessorCollectorService","_assessorCollectorRepository","getUpdatedAssessor","getUpdatedCollector","saveAssessor","saveCollector","assesorId","getAssessorList","DeadlineService","getAvailableStateYears","getAvailableAssessorYears","getStateDeadlines","getAssessorDeadlines","getAppealDeadlineTypes","saveForState","appealDeadlineId","doUpdate","getAssessorExceptions","appealDeadlineTypeID","AssessorExceptionsModalComponent","_deadlineService","deadlineDateDisplay","isEarliestPossibleDeadline","getAssessorSref","DeadlineListPanelComponent","_propertTypeService","_entityString","isStatePage","_undeletedFlatDeadlines","_flatDeadlines","_entityId","_isOnDefault","getDeadlineDateStr","_getDeadlinesByYear","deadlineHasExceptions","hasDefaultExceptions","yearsWithNonDefaultExceptions","_orignalSelectedYear","_originalDeadlines","_updateYears","addDeadline","newDeadline","appealDeadlineID","chosenDeadlineProptype","earliestPossible","openAssessorExceptions","invalidDateDeadline","_sendRequests","_impactedEntities","_doUpdate","getHelpTooltip","tooltipInfo","_getTooltipInfo","showTooltip","tooltipDate","showTooltipIcon","deadlinePromises","_getDeadlinePayload","statePromise","handleCRUDResult","deletedStateDeadlines","_availableDeadlineTypes","assessorDeadlines","checkUseEarliestPossible","deadlinesByDeadlineType","_getDeadlinesByType","unassignedDeadlinePropTypes","unassigned","usedDeadlineType","unassignedForDeadlineType","deadlineArr","assessorTaxYearDeadline","assessorDefaultDeadline","stateDefaultDeadline","fiscalDatesDeadlines","lienDateMonthDay","ppLienDateMonthDay","lienDateYearID","ppLienDateYearOffset","ppLienDateDisplayMonthDay","personalPropTaxable","AssessmentClassService","getAssessmentComponents","getExemptionChoicesForTaxAuthority","getParcelsAffectedByRatio","assessmentClassRatioId","deleteClass","assessmentClassId","ToPercentDirective","textAlign","specialKeys","toPercent","onChangeCallback","innerValue","AssessmentClassModalComponent","_assessmentClassService","readOnlyRatio","ratioSetAtAssessor","undeletedComponents","undeletedDefaults","assessmentClassDefaults","undeletedRatios","assessmentClassRatios","_ratioYears","_availableComponents","_availablePropertyTypes","_initDefaults","_getAvailableCombos","updateEfAction","removeEntity","entityArray","toggleDefault","availableDefault","acDefault","_deleteDefault","inUse","addComponent","chosenComponent","onEnabledChange","onStateWideRatioChange","onFixedRatioChange","fixedRatio","latest","fixed","firstRatio","addRatio","acToSave","parcelsAffectedPromises","assessmentClassRatioID","parcelsAffectedArr","parcelsAffected","newAvailableDefaults","availableDefaults","availableCombos","AssessmentClassListPanelComponent","_getAssessmentClasses","onShowUnusedChanged","assessmentClasses","_setClassVisibility","launchClassModal","lastClass","propTypes","componentsString","showStateClasses","ProtocolService","getByState","getByAssessor","getExceptionsByStateXPropertyType","saveStateSpecialists","specialists","saveAssessorSpecialists","updatedModel","jurisdictionSpecialists","StateAssessorExceptionsModalComponent","_protocolService","showFootnote","JurisdictionSpecialistUI","JurisdictionSpecialist","undeletedExceptions","siteClassExceptions","showNoneAssigned","ProtocolListPanelComponent","_entityIdString","_loadSpecialists","getJSDisplay","js","isNoneAssigned","getAssigneeDisplay","jurisdictionSpecialist","_availableSiteClasses","availableSiteClasses","_getJSAvailableSiteClasses","_originalJurisdictionSpecialists","editException","exceptionToEdit","jsUserChanged","jsUI","_setNewUser","jurisdictionSpecialistID","noneAssignedChanged","_getBlankJS","exceptionUserChanged","deleteException","isExceptionInEditMode","cancelUserChange","addSiteClass","chosenSiteClass","siteClassName","specialistsToSave","changedSpecialists","changedJSs","changedExceptions","showExceptionsModal","sc","siteClassSecondary","_getAssessorSpecialists","assessorSpecialists","propertyTypeXStateHasChildExceptions","stateSpecialists","newJS","disablePicker","stateSpecialist","tax_rates_panel_model_TaxRateArea","tax_rates_panel_model_TaxAuthority","obtainInAdvance","TaxAuthorityDetail","rateChange","TaxRateAreaTaxAuthorityDetail","TaxRateService","getTaxRateArea","updateTaxRateArea","taxRateAreaPayload","createTaxRateArea","deleteTaxRateArea","updateTaxAuthority","taxAuthorityPayload","createTaxAuthority","TaxAuthority","getPanelProjections","panelProjectionsPayload","cloneTaxRateArea","AddTaxEntityModalComponent","_taxRateService","taxEntity","defaultAnnualRateIncrease","TaxRateArea","TAX_AUTHORITY_HELP","AddTaxYearModalComponent","without","yearsAlreadyAdded","TaxAuthorityComponent","taxRateService","assessmentClassService","allExemptions","certainExemptions","noExemptions","alternateAV","landOnly","lowerOfTotalAvAndAlternateAv","_initPickLists","_prepareData","availableExemptionComponents","allowedExemptions","exemption","allowedExemptionAssessmentComponentIds","uniqTRAs","getCompiledListOfTaxRateAreaTaxAuthorityDetails","taxRateAreaTaxAuthorityDetails","taxRateAreaInclusions","tratad","yearsIncluded","tad","shouldDisplayCheck","launchInEditMode","originalTaxAuthority","getCategory","getTaxableAssessmentLabel","taxableAssessmentId","taxableAssessments","getCertificationType","certificationTypes","certificationType","getYearEstimated","yearDetail","getShadingFromStatus","tratd","allTratad","tartadList","removeYearDetail","disableTaxAuthority","maxYearDetail","taxAuthorityDetail","rateAsMills","syncRateFromMillsToPct","rateChangeAsPercent","syncRateChange","launchAddTaxYearModal","deletedYear","_calculateRate","detailIdx","displayAs","syncDefaultAnnualRateIncrease","_isValidNumber","defaultAnnualRateIncreaseAsPct","syncRateFromPctToMills","rateAsPct","defaultAnnualRateIncreaseAsPctBlur","rateAsMillsBlur","currentYearDetail","_updateCurrentYearRateChange","rateAsPctBlur","rateChangeAsPercentBlur","_updateCurrentYearRate","originalYearDetail","taxAuthorityDetailId","taxAuthorityExemptionTypeId","allowExemptionsOnAlternateAV","savedAuthority","_saveOrUpdateTaxAuthority","enableTaxRateAreaTaxAuthorityBackgroundProcess","getQcInfo","_changesWereMade","_refreshAndNotifyParent","certificationMonths","certificationDays","names","previousYearDetail","_findPreviousYearDetail","_updateNextYearRateChange","_computeRateFromPrevious","nextYearDetail","_findNextYearDetail","prevRate","yr","ShowTaxYearComponent","taxYearOptions","priorOptions","onTaxYearBeginChange","taxYearBeginChange","showTaxYearChanged","onTaxYearsPriorChange","taxYearsPriorChange","TaxRateAreaComponent","showTaxYearOptions","taxYearBeginEndOptions","_initTaxRateArea","originalTaxRateArea","getYearRate","tratdDetail","getTaxAuthotitiesSortedByName","getTotalRateForDisplay","_getTotalRate","_isDetailActual","getTotalEstimated","_nonDeletedDetails","sortData","collectors","ae","be","addTaxAuthority","yearBeginChange","taxRateAreaTaxAuthorityDetail","_taxYearChange","yearEndChange","removeTaxRateAreaTaxAuthorityDetail","shouldDisableAddCollector","atLeastOneTab","addCollector","isTab","disableTaxRateArea","globalYearEnd","_atLeastOneInfiniteTaxYearEnd","_atLeastOneTaxYearRangeOverlap","savedArea","_saveOrUpdateTaxRateArea","clonedTaxRateArea","shouldUseDropup","taLength","sum2","clone","cloning","loadingProjections","panelProjectionsRequestPayload","taxAuthorityDefaultAnnualRateIncrease","panelProjectionsResponsePayload","hideAddCollectorButton","firstActiveIdx","detailArray","TaxRateGridComponent","taxRateGridService","hasTaxRatePermission","launchTaxAuthorityModal","savedTaxAuthority","selectedGridSourceOption","launchTaxRateAreaModal","savedTaxRateArea","getSharedColumns","getAreaColumns","getAuthorityColumns","_getRateColumn","_getChangeColumn","_getTaxAreaRateByYear","_getAuthoritiesByTaxRateArea","_getCellClass","_getTaxAuthorityRateByYear","_getYearObj","yearRateSummaryList","baseClass","estimatedClass","yearRateSummary","taDetail","TaxRatesPanelService","taxRatesPanelData$","_taxRatesPanelDataSubject","loadTaxRatesByCollector","_loadTaxRatesByCollector","loadTaxRatesByAssessor","_loadTaxRatesByAssessor","taxRatesPanelPayload","TaxRatesPanelComponent","taxRatesPanelService","onRowClicked","_taxRatesPanelDataSub","selectedGridSourceChanged","maximizeToggled","showDisabledChanged","addTaxRateArea","annualRateIncrease","navigateToCommandCenter","_getRowData","showDisabled","TaxingDistrictListComponent","taxingDistricts","taxingDistrict","newTaxingDistrict","townshipCode","townshipName","taxingDistrictId","startEditingCell","colKey","regexp","TaxingDistrictComponent","showTaxingDistricts","taxingDistrictModels","AssessorInfoComponent","_assessorCollectorService","allowTaxingDistricts","assessorSaved","municipalities","_originalAssessor","updateMunicipality","municipalityID","municipality","municipalityAbbr","AssessorAvailableCollectorsComponent","collectorAssociations","_states","collectorState","_originalCollectorAssociations","loadAvailableCollectors","removeAssociation","collectorassociation","filteredStateCollectors","addAssociation","newCollector","collectorAssociationToAdd","loadingAvailableCollectors","_stateCollectors","AssessorComponent","assessorForInfo","toggleTaxRatesMaximize","isTaxRatesMaximized","stateIDErrMsg","COLLECTOR_HELP","CollectorDetailsComponent","_COLLECTOR_CAPS","viewOnly","collectorValue","_initializeCollectorValues","editingCollector","_WARNING_MESSAGE","_setEditAddress","addressesLength","BillingScenarioRepository","getByParcelId","getInUse","addScenario","scenario","updateScenario","deleteScenario","BillingScenarioService","_billingScenarioRepository","BillingScenarioModalComponent","_billingScenarioService","fromWhen","whens","billNumber","scenarioForm","collectorBills","inputScenario","_oldScenario","isCompanyCollector","_newScenario","_prepareScenario","_addRemoveBills","billValues","pmtOption","_newOption","removeBill","paymentNumber","_newPayment","_watchPaymentChanges","removePayment","_paymentSubs","addRemovePayments","optionValues","collectorPayments","removeIndex","removeCollectorPaymentOption","makeDefault","collectorBillScenarios","validateOnSave","scenarioToSave","_prepare","deleteScenarioModal","undefaultOthers","undiscountOthers","newDiscount","ptxDiscount","discountPercentChanged","dueMonthDay","projectionPercentage","accrualBeginDate","accrualEndDate","_validateNoOverlap","_validateAtLeastOnePaymentOptionIsDefault","scenarioToPrepare","oldBill","oldOption","oldPayment","_newBill","lastBill","monthDay","accrualBeginYearID","accrualEndYearID","dueYearID","projectionType","scenarioId","startEmpty","collectorBillName","procureDays","inUseObj","billControl","optionControl","bt","paymentControl","dt","collectorPaymentId","collectorPaymentOptionId","collectorBillId","collectorBillScenario","nonDeletedOptions","anyChecked","taxPeriods","beginStr","endStr","begin","taxPeriod1","taxPeriod2","areTaxPeriodsIdentical","taxPeriodsNotOverlapping","period1BeginMinusOne","period1EndPlusOne","endYear","BillingScenarioComponent","toWords","openScenario","collectorUpdated","showYearWarning","CollectorProtocolsComponent","originalTaxBillRequired","protocolForm","receiveByDueDate","maxItemsPerCheck","WARNING_MESSAGE","CollectorComponent","_route","_taxRatesService","_companyName","_loadCollector","_state","_setBreadcrumbs","entityProperties","refreshCollector","crumb","selectedCollectorLetter","letter","AddAssessorModalComponent","newAssessor","_$dataLoaded","isLoaded","savedAssesor","AlphabetizedListComponent","itemsByLetters","_alphabet","itemsByLetter","startingLetter","letterTabs","letterSelected","AssessorListComponent","canAdd","onLetterSelected","launchAddModal","assessorActiveParcelCounts","assessorsByLetters","firstChar","badge","activeParcelCount","AddCollectorModalComponent","collectorForm","CollectorListComponent","collectorsByLetters","StateJurisdictionCommandCenterService","_assessorRepo","Assessor","_GRID_SOURCE_OPTION_ASSESSOR","_getDate","_selectedGridSourceOptionSubject","_currentSearchModelSubject","_currentFilterModelSubject","_highlightChangesSubject","_updatingValueSubject","currentFilterModel","_currentFilterModel","highlightChangesModel","_highlightChanges","highlightDates","_highlightDates","verificationOptions","_verificationOptions","gridSourceOptions","_gridSourceOptions","setSelectedGridSourceOption","gso","formChanged","filtersChanged","highlightChanged","months","setMonth","CsrBulkUpdateComponent","setEntityInstanceId","updatedResponsibilities","selectedConsultingEngagementId","csrs","CsrListAgGridDataSource","_csrCommandCenterService","rootEntityId","rootEntityType","exceptionsOnly","entityFilters","sitePropCharFilters","parcelPropCharFilters","sourceEntityIDs","sourceEntityIsTopLevelCompany","sourceEntityTypeID","excludeInactiveCompanies","searchRowIds","entityCharacteristics","_filterSortMap","filterParameter","CSR_COMMAND_CENTER_HELP","CsrUpdateStatusCellRendererComponent","csrUpdateStatus","retryAction","retryResponsiblityUpdate","CsrCommandCenterService","csrRepo","groupSearchModel","removeExceptions","getEntityDescriptors","ReportManagerSelectEntitiesService","getTopLevelCompanies","onlyFavorites","onlyFavoritesString","getEntitiesFromParent","getUsersWithAccessToCertainCompanies","includeInternalUsers","getPropCharsFromParent","getPropCharValues","getClientServices","getPropertyTypes","getPayloadSourceEntityData","omitForCurrentEntity","nonSourceEntityIDs","lastSourceEntity","findLast","isEntityIncluded","propChar","parcelCharFilters","userIdFilters","contactIds","entityIDs","getSelectedEntities","buttonName","prerequisites","blockers","dropdownList","isAppealResponsibility","getSupportInstances","ReportManagerSelectEntitiesComponent","selectEntitiesService","reportManagerService","reportFavoriteChange","entitySelectionChanged","hasInactiveEntities","topLevelCompanies","supportInstances","frequentlyUsed","initedEntities","initedEntity","configureAdditionalSelections","hideTopLevelCompanyPicker","showSupportInstancePicker","loadInstances","maybeGetSubentities","loadingTopLevelCompanies","topLevelCompanyIDs","topLevelCompanies$","topLevelCompanyIds","initFromSavedReport","removeEmptyEntities","selectionButtonClicked","targetEntity","additionalSelections","propCharChanged","selectedPropCharName","propCharValues","selectAllTopLevelCompanies","unselectAllTopLevelCompanies","unselectAll","areAllSelected","removeLast","selectedTopLevelCompaniesChanged","_reportDisallowsMultipleTLCs","multiSelect","getElementById","selectedSubEntitiesChanged","showAdditionalSelections","noItemsSelected","lastEntity","isAppealResponsibilitySelected","loadingSupportInstances","instanceIds","selectAllSupportInstances","unselectAllSupportInstances","getNextEntities","parentPropChars","targetEntityTypeID","parentEntities","reportTypes","UserAccess","selectedEntitiesIDs","preReqsSatisfied","notBlocked","maybeAppealResp","maybeContacts","UserActivity","maybeUsers","maybeSupportUsers","SupportInstanceEscalationActivity","maybeSubsidiaries","maybeUserActivityReport","maybeUserAccessReport","maybeCsrCommandCenterReport","CsrCommandCenter","processPropChars","processEntity","entityList","CsrCommandCenterComponent","_ccService","_selectEntitiesService","refreshingGrid","debouncedEntitySelectionChanged","onEntitySelectionChanged","loadEntity","loadEntityCharacteristics","configureBreadcrumbs","onColumnVisible","initialDescriptors","longRunningUpdateUnderway","isRemoveExceptionsVisible$","_setGridColumns","showGrid","sri","parseCsrGridId","rootEntityTypeId","getRenderedNodes","exceptionRows","er","possibleExceptions","clientServiceResponsibilityId","responsibilitiesToRemove","sourceEntityIds","sourceEntityTypeId","selectedServicesIds","selectedPropertyTypeIds","_getGridColumnsBySource","BASE_DYNAMIC_DEFINITIONS","hexRepresentation","replaceAll","firstNumStr","firstNum","secondNumStr","secondNum","thirdNumStr","thirdNum","fourthNumStr","pow","gridSourceOption","selectedFilters","selectedSubsidiaryFilter","selectedSiteFilter","selectedParcelFilter","respData","AgGridCurrencyCellEditor","AgGridDatepickerCellEditor","AgGridTextCellEditor","parcelDescriptors","AllocationDetailGridRowModel","_allocationDetailModel","workPaperInitialAllocationAmount","initialAllocationAmount","initialAllocationAmountOverridden","initialAllocationAmountCalculated","workPaperFinalAllocationAmount","finalAllocationAmount","finalAllocationAmountOverridden","calculatedParcel","isWorkPaperParcelOverridden","statusId","allocationDetailStatusId","allocationDetailStatus","isReconciled","assignedAllocationAssessmentIds","glAccountNumber","parcelAddressComplete","linkedParcelAccountNumber","parcelDescription","linkedParcelDescription","linkedParcelAssessorAbbr","acqYear","workPaperCost","workPaperAcqDate","canBeReconciled","returnAssetId","isMatched","varianceDollar","variancePercentage","workPaperDescription","workPaperAcqYear","workPaperSchedule","workPaperFactor","workPaperAddlDep","workPaperAssessor","workPaperTaxingUnit","workPaperPhysicalAddress","workPaperLesseeName","workPaperNote","workPaperMisc1","workPaperMisc2","workPaperMisc3","workPaperMisc4","workPaperMisc5","siteIsDifferent","workPaperSiteId","parcelIsDifferent","workPaperParcelId","linkedParcelId","calculatedAssetId","calculatedReportingAssetId","parcelSiteId","priorYearEffectiveTaxRate","priorYearFinalAllocationAmount","priorYearFactor","taxVarianceDollar","AllocationDetailsListAgGridDataSource","_allocationDetailService","summaryFilter","allocationDetailsFilter","hideNotReportedAssets","managementReviewSelectedOption","managementReviewOption","reloadDataAfterUpdate","columnMap","isInUseInFilter","isInUseInSort","AllocationDetailDragAndDropService","_getAllocationDetailIdsFn","_dropComplete","draggedAllocationDetailIds","AllocationDetailDragAndDropSourceComponent","_allocationDetailDragAndDropService","AssessmentSummaryInfo","FMV","allocationAmount","summaryType","allocationAnnualAssessmentId","emptyValuePlaceholder","annualAssessmentRevisionDesc","variance","lockDate","canLock","isComitted","isTaxAuthority","canReleaseLock","_isSelected","canSelect","parcelAccountNumber2","parcelCity","parcelZip","hasActiveAppeal","taxAuthoritiesCount","sortByName","isMarkedAsReviewed","isCommitted","AddTaxAuthorityComponent","_taxAuthorities","_selectedRows","newAssessmentSummaries","newSummaries","EntityPickerComponent","entityPicker","getSelectedIds","titleOverride","optionFlagValue","optionFlag","getColDefs","getDataSource","getResult","EntityPickerDataSource","_getRowsFunction","paginatedSearchModel","ParcelPicker","EntityPicker","onSelectEdited","isSelectVisible","isSelectEditable","getModalClass","addSelectedFlag","getIdFromRow","idRowDataField","storeSelection","removeSelection","singleSelector","singleSelectedEntity","reportingParcelSearchModel","_siteIds","_masterSiteIds","_selectedReportingParcelSiteId","_getParcels","optionFlagText","siteIds","masterSiteIds","singleSelectColDef","optionFlagChange","includeSiteIds","EntityPickerService","showParcelPicker","selectedReportingParcelSiteId","getParcels","_showEntityPicker","AllocationDetailBulkUpdateActionComponent","fieldAction","requiredField","isInitialAllocationAmount","isFinalAllocationAmount","AllocationDetailBulkUpdateComponent","_entityPickerService","_differs","_assessmentsSummary","assessmentsSummary","allocationDetailListLastModifiedTimestamp","isReconciledAction","allocationAction","statusAction","initialAllocationAmountAction","finalAllocationAmountAction","initialAllocationAmountSelectionValid","finalAllocationAmountSelectionValid","allocationSelectionValid","statusSelectionValid","isReconciledSelectionValid","atLeastOneItemChanged","assessmentSummary","_assessmentSummaryInfo","allocation","allocationAnnualAssessmentIds","initialAllocationAmountActionChanged","finalAllocationAmountActionChanged","parcelActionChanged","statusActionChanged","isReconciledActionChanged","getParcelOptionText","CreateNewMergedParcelsComponent","selectedBillScenarioIds","_collectors","collectorBillScenarioId","collectorHasDuplicatesSelected","validateCollectorSelection","allocationDetailSelectRowsModel","_assessors","_allocationAnnualAssessmentIds","selectedAssessmentSummaryIds","_filterCollectors","_filteredCollectors","onSiteChanged","onAssessorChange","collectorBillScenarioIds","collectorBillScenarioName","defaultCollectors","AllocationDetailListGridActionCellRendererComponent","allocationDetail","canView","AllocationDetailDragAndDropCellRendererComponent","allocationDetailsDropped","AllocationAssessmentSummaryComponentComponent","situsLinesNumber","situsLine3","situsLine1","situsLine2","AllocationDetailsService","AgGridAssessmentSummaryActionCellRendererComponent","lockCheckboxTitle","filterActive","isNormalType","deleteAssessmentClicked","lockReleaseLockedAssessmentClicked","lock","filterOnSummary","clearFilterClicked","filterClicked","AgGridAssessmentSummaryActionHeaderRendererComponent","lockAssessmentClicked","showLockedAssessments","showLockedAssessmentsChange","ALLOCATIONS_HELP","RetrieveAssetsAgGridDataSource","RETRIEVE_ASSETS_HELP","RetrieveAssetsComponent","_selectedRowsSubscription","defaultSortModel","AssetsInAnotherAllocationsComponent","additionalCompanyId","additionalSiteId","additionalParcelId","additionalAnnualYearId","additionalAnnualAssessmentId","SelectTaxAuthorityComponent","selectedAssessmentSummaries","ResizableDirective","_styleProperty","rDragAxis","rDragPosition","_setStartValues","_startWidth","rMinWidth","rMaxWidth","rChanged","_startHeight","rMinHeight","rMaxHeight","baseValues","ExcelPreviewComponent","previewInfo","worksheetsInfo","selectedWorksheetName","worksheetName","selectedWorksheetChanged","worksheetInfo","_toColumnName","rawData","allColumnIds","autoSizeColumns","ret","toLocaleUpperCase","BeginNewImportComponent","newImport","resumeImport","previewResult","showImportFileIsProcessingMessage","succeeded","_dismissImportFileIsProcessingMessage","AssessmentActions","AllocationDetailsComponent","_companyAssetDescriptorRepository","LockAllocation","ReleaseLockedAllocation","DistributeVariance","CreateNewMergedParcels","_dragging","startEditMode","endEditMode","_allocationDetailSelectionInfo","hasNotMatchedAssets","hasNewParcels","createNewParcelsFromDetails","totalReportedCost","totalReturnValue","totalInitialAllocationValue","totalFinalAllocationValue","totalInventoryAvrCalculated","totalLeaseMonthlyPayment","totalNetBookValue","totalWorkPaperCost","totalVarianceDollar","totalPriorYearFinalAllocationAmount","totalTaxVarianceDollar","assetGridSelectedTotalsRow","assetGridTotalsRow","_statuses","displayOrder","_setAssessmentsSummary","_convertToAssessmentSummaryInfo","navigationProperties","_getDraggedAllocationDetailIds","_setAssessmentDraggingColumns","_setAssessmentGridColumns","uploadNewImport","lastImportFile","navigateToLastImport","lastImportFileId","onAssessmentAgGridReady","_assessmentGridApi","assessmentGridTracker","assessmentGridOptions","_getAssessmentGridRowIds","_totalAssessmentsSummary","_unassignedAssessmentsSummary","_editGroup","refreshAssetsList","_refreshAssessmentsSummary","hasLockedAssessments","hasLockedNotReviewedAssessments","onAllocationDetailsDropped","allocationDetailIds","parcelTaxAuthorities","selectedAllocationDetailIds","hideLockedAssessment","hideLockedAssessments","onAllocationSummaryFilterClick","clearAssessmentFilter","onLockReleaseLockedAssessmentClick","assessmentSummaryInfo","_lockAssessments","_releaseLockedAssessments","removeExistingAllocations","totalAssessmentsCount","onDeletTaxAuthorityClick","affectedAssessmentSummaries","toggleAssessmentGridFilters","filterAssessmentsSummary","filterSummary","assessmentsSummaryFilter","hasReadyToLockAllocations","canDistributeVariance","lockAllocation","releaseLockedAllocation","distributeVariance","existingSummaryIndex","onHideNotReportedAssetsChange","allocationDescription","allAssessmentActionsDisabled","assessmentActions","onActionSelected","createNewParcelsFromAssessmentSummary","createNewParcels","selectedAllocationAssessmentSummaryIds","canCreateMergedParcels","retrieveAssets","_updateAssessmentActions","dropZoneColumn","_isRowEditable","_onValueChanged","additionalClass","summaryModel","existingAllocationSummary","_canChangeReconciliationStatus","actionColumn","_canViewAssetDetails","allocationDetailGridModel","reloadTotals","updatedField","reloadData","updateResult","updatedGridRow","updatedAllocationDetailModel","updatedTotalSummary","updatedUnassignedSummary","updatedSummary","selectedTotalsLoading","reloadAllocationDetails","assetsInAnotherAllocations","AssetListAgGridDataSource","_autoUpdateTotalsCallback","selectedRowProperty","fetchSourceAssets","limitOption","advancedAssetFilters","advancedFilters","overrideFilterColumns","noReportingParcel","invalidCostAllocations","getAllRowTotals","hasLatestTotals","clearSort","ASSET_LIST_HELP","AssetListGridActionCellRendererComponent","ExtendedGLAccountModel","keyValueDisplayPipe","ExtendedSiteModel","ASSET_BULK_UPDATE_HELP","CostAdjustmentHelpComponent","adjustments","DecimalNumberDirective","decimalPrecision","ParcelSelectorComponent","reportingParcelFilter","_filterReportingParcels","loadParcelsOnInit","loadParcels","_selectReportingParcel","excludeParcelIds","_filterInvalidExcludeParcelIds","reportingParcels","allReportingParcels","nge","onReportingParcelBlur","onReportingParcelSelected","reportingParcelIdChange","excludeIds","entityPickerResult","rp","selectedReportingParcelAcctNum","ReportingAssetBulkUpdateFieldActionEnum","AssetBulkUpdateActionComponent","verifyField","AssetDescriptorEditComponent","enums","descriptorTypesEq","booleanValue","notifyTextChange","notifyNumberChange","notifyDateChange","notifyBooleanChange","getMaxLength","descriptor_r19","descriptor_r28","descriptor_r40","AssetBulkUpdateTabEnum","AssetBulkUpdateComponent","_costAdjustmentRepository","_reportingParcelRepository","AssetFields","glAccountFilter","_filterGlAccounts","siteFilter","_filterSites","_loadMetadata","initializeBulkUpdateModel","_bulkUpdateModelDiffer","reportingAssetBulkUpdateModel","_focusOnFormElement","hotkeyFocus","onGlAccountSelected","glAccountLastMatch","onGlAccountBlur","_glAccountNoResult","onGlAccountNoResults","onSiteNoResults","_siteNoResult","isSplitTabValid","areSplitFieldsValid","isBulkCreateSplitOperation","splitCreateCostAllocationPercentage","isBulkUpdateSplitOperation","splitUpdateCostAllocationPercentage","areBaseFieldsValid","assetVerificationDate","assetVerificationAction","ownershipTypeAction","leaseTypeAction","acqDateAction","costAction","isPerpetualAction","descriptionAction","disposedDateAction","glAccountIdAction","siteIdAction","reportingParcelIdAction","t1Action","t2Action","t3Action","t4Action","t5Action","t6Action","t7Action","t8Action","t9Action","t10Action","t11Action","t12Action","t13Action","t14Action","t15Action","t16Action","t17Action","t18Action","t19Action","t20Action","t21Action","t22Action","t23Action","t24Action","t25Action","t26Action","t27Action","t28Action","t29Action","t30Action","n1Action","n2Action","n3Action","n4Action","n5Action","n6Action","n7Action","n8Action","n9Action","n10Action","d1Action","d2Action","d3Action","d4Action","d5Action","d6Action","d7Action","d8Action","d9Action","d10Action","netBookValueAction","isAnchoredAction","doNotPotentiallyDisposeAction","isLockedAction","isAlternativeAcqDateFieldRequired","alternativeAcqDateDescriptorIdAction","isAlternativeCostFieldRequired","alternativeCostDescriptorIdAction","isAlternativeAcqDateFieldValid","isAlternativeCostFieldValid","alternativeAcqDateAssetDescriptor","companyAssetDescriptorMappingId","alternativeCostAssetDescriptor","costAdjustmentUpdates","costAdjustmentUpdate","isAssetFieldTabValid","_closed","changeActiveTab","Splits","isCreateSplitEnabled","isUpdateSplitEnabled","unlockAssets","overrideAllFields","isLockedChanged","isLockedRemoveOverridesAction","isLockedRemoveOverrides","ownershipTypeChanged","OWNERSHIP_TYPE_OWNED","leaseTypeActionField","isLeaseTypeFieldDisabled","isCostInputDisabled","isPercent","otherElemSelector","otherElem","bulkUpdateFormElement","existingCostAdjustmentUpdate","updateCostAdjustmentAmount","updateCostAdjustmentPercent","onCostAdjustmentActionChange","newCostAdjustmentUpdate","onSiteBlur","siteFieldEdited","onSiteLoadingChange","siteIsLoading","onSiteSelected","onVerificationDateChanged","verificationDate","assetListLastModifiedTimestamp","filterBySiteId","filterByParcelId","newRowData","ownershipTypes","leaseTypes","assetVerificationReasons","glAccountResponse","assetDescriptorsResponse","costAdjustmentTypes","_getBulkUpdateMetaData","_glAccounts","accountType","filteredTypes","bulkUpdateStateCostAdjustment","costAdjustment","customHelpRenderer","sequencedCostAdjustments","typeState","stateCostAdjustments","isCreateNewSplitAllowed","isUpdateSplitAllowed","perpetualAllowedAssetsCount","displayPerpetualTooltip","perpetualHelpContentId","isBulkMetadataLoaded","excludeFromInactiveCompany","firstInit","hasLockedAssets","AssetChangeIconComponent","activeIcons","AssetChangeIconCellRendererComponent","selector","tooltipTitle","isTotalsRow","HotkeyService","_eventManager","hotkey","_default","dispose","DeleteConfirmationComponent","AgGridTextWithTotalsUpdateCellRendererComponent","totalsNeedRefresh","autoUpdateChecked","autoUpdate","onAutomaticUpdatesClicked","AssetImportProgressComponent","assetImportProgressService","importStarted$","activeImportSelectedRowsCount","selectedRowsCount","importFinished$","processedRows$","activeImportProcessedRowsCount","timeRemaining$","activeImportTimeRemaining","selectedRowsCountLoaded$","AssetImportProgressService","_importStartedSubject","_importFinishedSubject","_processedRowsSubject","_timeRemainingSubject","_selectedRowsCountLoadedSubject","_reconnectedSub","_statusChangedSub","_progressChangedSub","_companyId","_loadAssetImportInProgress","_assetImportInProgressMetadata","_processedRowsCount","_selectedRowsCount","_progressIntervalId","_timeRemainingIntervalId","_loadingAssetImportInProgressMetadata","assetImportInProgressMetadata","_initializeAssetImportProgress","transferredRowsCount","activeImportInfo","millisecondsPerRow","timeToProcess","padStart","AgGridCurrentLayoutAppliedComponent","_sub","ASSET_ADVANCED_HELP","AdvancedFormElements","AssetAdvancedDetailsComponent","FieldChanged","isOutputControl","AllAssets","Changed","AnyImpactful","SpecificField","additionalSelect","fieldSelect","Transferred","NewAddition","NotChanged","PotentiallyDisposed","Disposed","DisposedPeriod","DisposedLien","comparisonLienDateType","selectOptions","selectControl","_dropdownOnOpen","fieldSelectOptions","comparisonLienDate","comparisonLienDateTypeOption","comparisonLienDateTypeOptions","comparisonLienDateDisabled","_buildForm","applyFromDropdown","_registerFormListeners","_createOutputModel","fieldChangedColumns","advancedFilterForm","helperFormGroup","_checkChildChanges","assetFilters","comparisonLienDateTypeOptionChanged","_validateComparisonDate","onComparisonLienDateChanged","_updateFormChildren","_checkQuickListMatch","filterActiveCount","filterIndeterminateCount","_createFormControls","filterList","accumulator","formResults","comparisonLienDateTypeFilter","allAssetsAtLienDate","helperFormControls","advancedFormControls","validators","_validateForm","fieldSelected","AssetPropertyMap","isFurtherLimitTo","isChangeFilter","AssetAdvancedComponent","includeAnyReturnImpactfulFieldChange","includeDisposedSinceLastLienDate","includeNewAddition","includePotentiallyDisposed","includeChanged","includeNotChanged","includeTransferred","_setAssetDescriptors","_fieldSelectOptions","overrideProperties","descriptorKey","descriptorPropertyInfo","ASSET_LIMIT_HELP","AssetLimitDetailsComponent","limitOptions","furtherLimitForm","selectedOverrides","_formChanged","AssetLimitComponent","overrideOptions","AssetListComponent","_hotkeyService","_assetImportProgressService","Imported","Reporting","_REPORTING_VALUES_GRID_ID","_GRID_SOURCE_OPTION_IMPORTED_VALUES","_GRID_SOURCE_OPTION_REPORTING_VALUES","_IMPORTED_VALUES_FILTER_OPTION_LIEN","_IMPORTED_VALUES_FILTER_OPTION_IMPORT","_layoutName","viewName","totalSourceCost","totalSourceAdjustedCost","totalSourceN1","totalSourceN2","totalSourceN3","totalSourceN4","totalSourceN5","totalSourceN6","totalSourceN7","totalSourceN8","totalSourceN9","totalSourceN10","totalCostAdjustmentAmount1","totalCostAdjustmentAmount2","totalCostAdjustmentAmount3","totalCostAdjustmentAmount4","totalSourceInventoryJan","totalSourceInventoryFeb","totalSourceInventoryMar","totalSourceInventoryApr","totalSourceInventoryMay","totalSourceInventoryJun","totalSourceInventoryJul","totalSourceInventoryAug","totalSourceInventorySep","totalSourceInventoryOct","totalSourceInventoryNov","totalSourceInventoryDec","totalSourceInventoryAvr","totalSourceNetBookValue","importFilterOptionVisible","isEmbeddedMode","lienDateVisible","selectedImportGridFilterOption","furtherLimitVisible","importFileListVisible","isLienDatePrior","isLienDateExact","_autoUpdateTotals","_layoutDestroy$","companyIdFilter","siteIdFilter","parcelIdFilter","loadingChange","filterHref","parcelPromise","companyInfo","assetDescriptorsPromise","costAdjustmentTypesPromise","_costAdjustmentTypes","activeImportLongRunningProcessId","openAssetImportInProgressModal","_calculateTotalsClicked","onAdvancedOptionChanged","onLimitOptionChanged","onImportGridFilterChanged","importGridFilterOption","onSelectedImportFileChanged","selectedImportFileId","_refreshImportFiles","addAsset","_getGridIdBySource","importFiles","getListViewHelpContentId","confirmOptions","_assetImportInProgressModalOpened","assetSummary","allNodesOnPage","_handleTotalsUpdate","effectiveDateColDef","actionsColDef","onUpdateTotalsClicked","getCacheBlockState","filterName","_getColDef","lastReturnColDef","_IMPORTED_VALUES_GRID_ID","ElectronicFilingAgGridDataSource","electronicFilingTypeId","ELECTRONIC_FILING_HELP","ElectronicFilingComponent","ppeFilingAvailability","NOT_AVAILABLE","allowElectronicFilingUnapprovedDownload","hasApprovalTask","isApproved","isReviewed","canRefresh","electronicFilingType","viewControlForm","electronicFilingTypes","placeholderElectronicFilingType","sdrTestUrl","caSdrTestUrl","sdrUrl","caSdrUrl","downloadControlForm","bundleAssessors","onElectronicFilingTypeChanged","isCASdr","downloadElectronicFilings","bundleByAssessor","hasRowsSelected","returnDueDate","downloadedDate","isAmended","efiling","toTake","EntityImportListGridDataSource","isCompanyImport","EntityImportProgressComponent","_getUploadTitle","_uploadIsError","_uploadIsCurrent","_uploadIsWorking","_uploadIsComplete","_onClick","_getMapTitle","_mapIsError","_mapIsCurrent","_mapIsWorking","_mapIsComplete","_getTransferTitle","_transferIsError","_transferIsCurrent","_transferIsWorking","_transferIsComplete","requiredFieldsAssigned","lastTransferInfo","insertedCount","updatedCount","unchangedCount","transferredRows","EntityImportListGridProgressCellRendererComponent","EntityImportListGridActionCellRendererComponent","revertHelpContentId","canRevert","markCompletedHelpContentId","canComplete","IMPORT_LIST_HELP","TransferConfirmComponent","isAssetsImport","DynamicFieldBehaviorService","importDynamicFieldBehavior","setAllFields","dynamicFieldsBehavior","fieldMappings","_fields","_fieldMappings","_showDynamicFieldConfiguration","supportsDynamicFieldBehaviorConfiguration","_dynamicFieldBehaviorOptions","_selectedDynamicFieldBehaviorOption","_selectedDynamicFieldBehaviorOptions","getFileDynamicFieldBehaviorOptions","showDynamicFieldConfiguration","getSelectedDynamicFieldBehaviorOption","getSelectedDynamicFieldBehaviorOptions","setSelectedDynamicFieldBehaviorOption","getFieldMappings","EntityImportProcessService","_dynamicFieldBehaviorService","importProcessStatusError","_importProcessStatusError","importStatus$","_importStatusSubject","_assetEffectiveDate","_assetOwnershipTypeId","_assetOwnershipTypeName","_accrualAdjustmentAmountValueType","_taxPaymentsMatchOverall","_isTaxPaymentsImportMatchByPaymentSystemId","_taxPaymentsMatchParcel","_taxPaymentsMatchCollector","_sitesUpdatesOnlyMatchBy","matchOverall","matchParcel","matchCollector","_incomeStatementsEndingDate","_rentRollEndingDate","intendedUse","_glAccountsIntendedUse","_importStatusChangeSub","_wsHandleStatusChange","_importProgressChangeSub","_wsHandleProgressChange","dynamicFieldBehavior","setAllDynamicFieldBehavior","importFields","assignedFields","notifyValidationSummaryChanged","notifyErrorFilterChanged","notifyValidated","notifyEvaluating","_lastEvaluationResult","_selectedRowsInfo","evaluatedInsertCount","insertCount","evaluatedUpdateCount","updateCount","evaluatedDeleteCount","deleteCount","evaluatedNoChangeCount","noChangeCount","accrualAdjustmentAmountValueType","startTransfer","updateCell","notifyCellUpdated","notValidatedUpdates$","_cellUpdatedEventEmitter","validationSummaryChanged$","_validationSummaryBehaviorSubject","validationErrors","validated$","_validatedEventEmitter","evaluating$","_evaluatingEventEmitter","selectedRowsChanged$","_selectedRowsEventEmitter","notifySelectedRowsChanged","errorFilterChanged$","_errorFilterChangedBehaviorSubject","getValidationResults","showValidRowsOnlyChanged$","_showValidRowsOnlyEventEmitter","notifyShowValidRowsOnlyChanged","showValidRowsOnly","assetOwnershipTypeName","forceValidate$","_forceValidateSubject","forceValidate","sitesUpdatesOnlyMatchBy","taxPaymentsMatchOverall","isTaxPaymentsImportMatchByPaymentSystemId","taxPaymentsMatchParcel","taxPaymentsMatchCollector","incomeStatementsEndingDate","rentRollEndingDate","glAccountsIntendedUse","clearErrorsWarningsSelectionChanged$","_clearErrorsWarningsSelectionEventEmitter","notifyClearErrorsWarningsSelection","_importProgressStatusSubject","EntityImportListComponent","_datetimePipe","_importService","dataImportSpecificationsHelpContentId","_hasComplianceFeaturePermission","_updateRowModel","_onProgressResume","_onResume","_onDelete","_onRevert","_canRevert","_onComplete","_canComplete","navigateToImportSpecifications","_deleteImport","_resumeImport","resumeResult","_showImportProgress","_revertImport","messageId","canBeReverted","_completeImport","EntityImportSpecificationMappingComponent","canSaveSharedSpecs","saveType","supportsDynamicFieldConfiguration","saveSpecification","specificationName","existingFileSpecificationId","importFileSpecificationName","fromImportFileId","IMPORT_PROCESS_HELP","EntityImportColumnMappingStepService","fileModel","contentTypeModel","_headers","importFileHeaders","_fileSpecificationId","_fileSpecificationName","canAssignField","targetId","getFileHeaders","getFileSpecificationInfo","assignFieldToColumn","_fieldAssigned","fieldMapping","_fieldUnassigned","fieldAssigned$","fieldUnassigned$","AgGridPinnedRowCellRenderer","colMetadata","EntityImportEditorAgGridDataSource","_importId","showTransferredRows","estimatedActionFilter","AgGridMappingHeaderRowCellRendererComponent","_columnMappingStepService","unmapped","isHeaderMappedToRequiredField","isStaticColumn","isUnknown","isHeaderMapped","_specificationFieldId","isMappingRequired","mappingMaintenanceAllowed","_enableMappingMaintenance","_headerId","colDefMetadata","enableMappingMaintenance","fileHeaderId","staticFieldId","_fieldAssignedSub","importFileHeaderId","EntityImportStaticFieldsComponent","clarificationFieldControl","_clarificationFieldValue","_availableImportFields","availableImportFields","staticColumn","_staticColumn","clarificationFields","clarificationColumn","staticValue","clarificationFieldValues","COLUMN_MAPPING_STEP_HELP","ImportMappingModalComponent","clarificationField","possibleOptions","onAccept","AgGridOverlayService","notifyColumnAdd","_columnAddEmitter","notifyColumnRemove","_columnRemoveEmitter","notifyColumnResize","_columnResizeEmitter","notifyGridHorizontalScroll","_gridHorizontalScrollEmitter","columnAdd$","columnRemove$","columnResize$","gridHorizontalScroll$","AgGridOverlayContainer","_columnId","_left","_overlayContainerPadding","horizontalScrollOffset","_width","AgGridOverlayComponent","_agGridOverlayService","_getDragulaTargetId","bagName","dropEl","_getDragulaSourceId","sourceElIdAttribute","sourceId","overlayContainers","hasMouseOver","_horizontalScrollOffset","DynamicFieldBehaviorHelpComponent","DynamicFieldBehaviorConfigurationComponent","isFileOnlyOption","dynamicFields","setAllValue","fieldOptions","DynamicFieldSelectedBehaviorHelpComponent","DynamicFieldBehaviorComponent","availableDynamicFieldBehaviorOptions","dynamicFieldBehaviorTooltip","selectedImportDynamicFieldBehavior","selectedPropertyCharacteristicOptionName","showFieldOptionsTooltip","fieldsSettings","setAllOption","_getDynamicFields","dynamicFieldSelectedBehaviorTooltip","fieldSelectedOption","canEditDynamicFieldConfiguration","editDynamicFieldBehavior","setDynamicFieldBehavior","mappedFields","EntityImportColumnMappingStepComponent","enableFilter","enableServerSideFilter","mappedColumns","unmappedColumns","staticColumns","gridColumnFilters","_loadImportFileInformation","canGridInitialize","l","mappedField","availableImportFieldsRequired","availableImportFieldsOptional","_getGridColumnsAssociatedWithImportFileColumns","_getGridColumnsAssociatedWithMappedImportFileColumns","headerId","_getGridColumnsAssociatedWithUnmappedImportFileColumns","_getGridColumnsAssociatedWithStaticImportFileColumns","_getDragAndDropOverlaysFromGridColumns","getLeft","getActualWidth","_applyGridColumnFilter","selectedGridColumnFilter","_showGridColumn","_removeGridOverlay","_hideGridColumn","_showStaticFieldsModal","_addStaticColumnToGrid","_prepareStaticColumnDefinition","colDefList","_removeStaticColumnFromGrid","staticFieldMappingId","_dropMappingCharacteristicModal","availableImportFieldsDragAndDropBagName","availableImportFieldsDragAndDropSourceContainerIdentifier","_dragSub","availableImportFieldsOverlayVisible","_dragEndSub","_fieldUnassignedSub","_modelHiddenSub","rowIdColumnDef","columnDefList","staticColumnDefList","headersRow","setPinnedTopRowData","onAgGridColumnResized","onAgGridBodyScroll","onAvailableImportFieldMapped","addStaticColumn","availableFields","staticFieldMapping","filterGridColumns","saveImportSpecification","importSpecInfo","allowNoSave","_rowsLoaded","_setTotalValidCount","_notProcessedUpdatesCallback","gridParams","getSearchModelWithoutPagination","supportsTotals","notValidatedUpdates","totalNotValidatedUpdates","gridRows","flatRowObj","validationStatus","originalValues","_setupFields","ve","assignedField","actualAction","estimatedAction","validationSummaryFilters","sortingColumns","forceRefreshOfTotalValidRows","contentTypeField","rowObj","gr","importFieldHeader","ifh","EntityImportEditorEstimatedActionHeaderRendererComponent","EntityImportEditorEstimatedActionFilterRendererComponent","selectedEstimatedAction","selectedEstimatedActionChange","EntityImportEditorEstimatedActionCellRendererComponent","isNotEvaluated","isUpdate","isInsert","isNoChange","isEntityDeleted","isDelete","showControl","Utilities_Service_upgrade","EntityImportEditorAssetClassSelectorCellEditorComponent","focusIn","focusOut","assetClassSelector","isCancelBeforeStart","onAssetClassificationChanged","IncomeStatementCategoryPickerComponent","_incomeStatementCategoryRepository","incomeStatementCategories","_matchesAccountType","incomeStatementCategoryId","childIncomeStatementCategories","_expandedIncomeStatementCategories","selectIncomeStatementCategory","incomeStatementCategory","expandCategory","collapseCategory","glAccountTypeId","incomeStatementCategoryTypeId","IncomeStatementCategorySelectorComponent","incomeStatementCategoryFilter","_filterIncomeStatementCategories","_populateIncomeStatementCategories","_incomeStatementCategorySubscription","_selectIncomeStatementCategory","incomeStatementCategoryName","onIncomeStatementCategoryBlur","onIncomeStatementCategorySelected","incomeStatementCategoryChange","incomeStatementCategoryIdChange","_incomeStatementCategories","forceFindByName","osc","ImportBulkUpdateActionComponent","_possibleActions","changeToAllowed","AssessorSelectorComponent","_filterAssessors","assessorValue","_selectAssessor","_isMatch","localAssessor","primaryMatch","additionalMatches","additionalMatch","AssessmentClassSelectorComponent","GLAccountSelectorComponent","_select","TaxingDistrictSelectorComponent","allMatches","localTaxingDistrict","ImportBulkUpdateComponent","_entityImportProcessService","updateFields","_bulkUpdateModel","selectionModel","onActionChanged","uiCellRenderer","_isIncomeStatementCategoryDirty","_isGlAccountTypeDirty","onIncomeStatementCategoryChanged","onAssessorChanged","onAssessmentClassChanged","assessmentClassValue","onGLAccountChanged","onTaxingDistrictChanged","onGlAccountTypeChanged","glAccountType","isChangeToAllowed","areAdditionalParamsValid","additionalParams","saveCompleteCallback","TypeaheadSelectorComponent","_allValues","filterFn","findFn","EntityImportEditorAssessorSelectorCellEditorComponent","typeaheadSelector","EntityImportEditorAttachmentTypeSelectorCellEditorComponent","onChanged","LeaseTypeSelectorComponent","leaseType","EntityImportEditorLeaseTypeSelectorCellEditorComponent","leaseTypeSelector","EntityImportEditorAssessmentClassSelectorCellEditorComponent","assessmentClassSelector","EntityImportEditorGLAccountSelectorCellEditorComponent","EntityImportEditorTaxingSelectorCellEditorComponent","_formatCode","taxingDistrictValue","OneTimeVRecurringSelectorComponent","EntityImportEditorOneTimeVRecurringSelectorRendererCellEditorComponent","selectorComponent","EntityImportEditorIncomeStatementCategorySelectorCellEditorComponent","incomeStatementCategorySelector","getGlAccountTypeId","EntityImportEditorGLAccountTypeSelectorCellEditorComponent","LongRunningProcessService","quiescedStatus","_quiescedStatus","queueTypes","_queueTypes","controlMessageTypes","_controlMessageTypes","serviceHosts","_serviceHosts","autoRefresh","_autoRefresh","_refreshSubject","_longRunningProcessStatusSubject","_longRunningProcessQuiescedStatusSubject","_loadQuiescedStatus","_loadQueueTypes","_loadControlMessageTypes","_loadServiceHosts","_longRunningProcessStatusChangeSub","_longRunningProcessQuiescedStatusChangeSub","setAutoRefresh","controlMessage","EntityImportEditorComponent","_longRunningProcessService","_isRowSelectionDisabled","_isRowSelectionHidden","suppressFieldDotNotation","suppressCellSelection","_validationErrors","_showTotals","_fieldNames","importGridSelectedTotalsRow","importGridTotalsRow","_importFileModel","_isImportCompleted","_evaluatingSub","_validationSummarySub","_transferredSub","transferCompletedEventEmitter","selectedRowsInfo$","hasDataForBulkOperation","invalidRowsCount","validRowsCount","_selectionSupportDeleteOperation","bulkUpdateFields","_getBulkUpdateFields","_selectionSupportBulkOperation","_notValidatedUpdates","totalValidCount","_destroyIndicator$","_errorFilterSub","selectRowColumnDef","estimatedActionColumnDef","suppressFilterButton","fileColumnDefList","columnIndex","onAgCellValueChanged","fieldMappingId","isMappedToRequiredFields","_getAssetClassifications","suppressKeyboardEvent","KEY_ENTER","_getAssessors","_getAttachmentTypes","_getLeaseTypes","_getGLAccounts","_getTaxingDistricts","_getGLAccountTypes","_getGlAccountTypeId","_sortingColumns","staticColumnDef","_defaultSortModel","_selectedRowIndex","showTransferredRowsChange","showValidRowsOnlyChange","glAccountTypes","validForAccrual","_bulkUpdateSaveCompleteCallback","_selectedRow","_updateCellParams","longRunningProcessResult","selectedRowIndex","_getPageInvolvedProperties","moreThanOneRowsAffected","rowValidationSummary","rvs","errorSource","importValidationSummary","visibleColumnsCount","_setFilteredRowCount","filteredRowCount","filteredRows","_getSelectionModel","siteNumberAssignedField","siteField","parcelAssignedField","parcelField","_leaseTypes","selectedTotalsTimestamp","_taxingDistricts","removeOverrideOption","parentAssetClassificationId","_glAccountTypes","forIncomeStatement","glAccountTypeName","bulkUpdateAllowed","EntityImportValidationSummaryComponent","_getRowId","_loadValidationErrors","_transferCompletedSub","_showValidRowsOnlyChangedSub","_showValidRowsOnlyChanged","_clearErrorsWarningsSelectionSub","_clearSelection","_notValidatedUpdatesSub","notValidatedUpdatesCount","cellRenderer","validationError","onAgGridSelectionChanged","selectedData","_selectedIds","errorCount","warningCount","issue","EntityImportEditingStepComponent","ImportStep","ImportInitiatorEnum","EntityImportProcessComponent","Indeterminate","nextText","importStep","ColumnMapping","Editing","_isEvaluated","isGoBackVisible","_unknownImportStep","isGoBackEnabled","isGoNextVisible","importFileDescription","isGoNextEnabled","isCloseEnabled","nextHelpContentId","helpId","backHelpContentId","isMarkAsCompletedVisible","isValidateVisible","isMarkAsCompletedEnabled","allocationName","_importInitiator","Allocation","CompanyList","SystemList","_getImport","navigateToImportsList","_setModelDirty","selectedRowsEvent","_previousEvaluationAllSelected","_validatedSub","_isValidated","_startValidation","_forceValidateSub","revalidate","_importStatusSub","_importProgressSub","goBack","goNext","_isModelDirty","importFileSpecificationIsPrivate","importFileSpecificationUserId","_goNext","onCloseClick","isRevalidateVisible","validateNotValidatedUpdatesOnly","isDeleteVisible","isDeleteEnabled","isSiteUpdatesOnlyImport","isTaxPaymentsImport","errResp","isFirstLoad","rowsCount","deletedCount","errorsCount","resultTitle","goToNextStep","validationModel","ImportSpecificationListAgGridDataSource","_importSpecificationRepository","excludeReadOnly","includeDisabled","ImportSpecificationListGridActionCellRendererComponent","importSpecification","EntityImportSpecificationEditComponent","visibilityOptions","editForm","importFieldDataType","currency","lastColumnIndex","IMPORT_SPECIFICATION_LIST_HELP","ImportSpecificationListComponent","onIncludeDisabledChanged","importSpec","specParams","FactorTableListGridActionCellRendererComponent","factorTableGridItem","onCopyClicked","FactorTableExportAttachmentsComponent","_dateTimePipe","_factorTables","formRevision","FactorTableListComponent","_GRID_SOURCE_OPTION_SYSTEM","_GRID_SOURCE_OPTION_COMPANY","processCellCallback","hasCompanyWritePermission","canExportAttachments","tableTypes","selectedTableType","selectedTaxYear","stateTracker","factorTableStateModel","onSelectedTableTypeChange","onSelectedStateChanged","onSelectedTaxYearChanged","_showModal","onIncludeRetiredTablesChanged","reloadStates","_setTaxYears","minTaxYear","maxTaxYear","indexTableMinTaxYear","indexTableMaxTaxYear","depreciationTableMinTaxYear","depreciationTableMaxTaxYear","factorTableDetailModel","_factorTableExportAttachmentsLongRunningProcessId","FormTypeEnum","FORM_HELP","FormType","FormMode","FormDetailsComponent","formTitle","busyMsgLoad","selectedStateId","FormRevision","SupplementalForm","initialFormRevisionNameIfEdit","supplementalFormName","priorFormRevisions","allFormRevisions","doesStateHaveElectronicFilingType","formTypesEqual","getElectronicFilingTypeHelpContentId","isFormRevisionInLockedBatch","busyMsgSave","formName","revisionStampLocationId","formCreateModel","formDescription","revisionDescription","revisionPriorFormRevisionId","priorFormRevisionId","newFormRevision","revisionCreateModel","formRevisionStampLocationId","supplementalCreateModel","parentRevisionId","supplementalFormDescription","supplement","formUpdateModel","revisionUpdateModel","supplementalUpdateModel","FormSetupUploadComponent","replaceTargetFormRevision","FormSetupDownloadComponent","ExportFormListComponent","formType","fileType","FormLibraryExportComponent","exportFileType","allTaxYears","FormService","_canView","_defaultAssessor","_factorTableAssessor","_assessor","_assetClassificationMappings","_formRevision","_formRevisionYears","_formRevisionYear","_maxFormRevisionYear","_minFormRevisionYear","_allFactorTables","_allReports","_appealLevels","_anyAssessorMappingsCertified","_templateValidationResult","defaultAssessorId","factorTableAssessor","factorTableAssessorId","factorTablesAssessorName","classificationMappingsAssessorName","assetClassificationMappings","formRevisionStateId","lastFormRevision","_lastFormRevision","formRevisionYears","formRevisionYear","maxFormRevisionYear","minFormRevisionYear","isMaxFormRevisionYear","isMinFormRevisionYear","assessorsAvailableForAssignment","assessorsAssigned","allFactorTables","isFormTypeAppeal","isFormTypeCompliance","anyAssessorMappingsCertified","templateValidationResult","isPlaceholderTemplate","hasTemplateValidationErrors","hasTemplateValidationWarnings","assessors$","_assessorsSubject","assessor$","_assessorSubject","formRevision$","_formRevisionSubject","formRevisionYears$","_formRevisionYearsSubject","formRevisionYear$","_formRevisionYearSubject","assetClassificationMappings$","_assetClassificationMappingsSubject","schedules$","_schedulesSubject","factorTables$","_factorTablesSubject","reports$","_reportsSubject","isInDevelopment$","_isInDevelopmentSubject","isPrimary$","_isPrimarySubject","anyAssessorMappingsCertified$","_anyAssessorMappingsCertifiedSubject","isValidForAppeal","_validAppealPanels","setAssessors","_setAssessors","setAssessor","_setAssessor","checkEditDefaultAssessor","_warnDefaultAssessorEdit","loadFormRevision","_loadFormRevision","setFormRevisionYear","_setFormRevisionYear","setFormRevisionAppealLevel","loadAssetClassificationMappings","_loadAssetClassificationMappings","setSchedules","_setSchedules","loadSchedules","formClassificationMappingsUpdated","setFactorTables","_setFactorTables","setReports","associationModel","_associateAssessors","disassociateAssessor","_disassociateAssessors","_assessorChangeIsCertified","_updateAssessorAddress","_assessorChangeUseDefaultTables","_assessorChangeUseDefaultMappings","_assessorChangeUsePropertyType","updateFactorTables","_validateTemplate","downloadTemplate","_saveFileAsPdf","_getFilenameFromResponseContentDisposition","templateChangeDate","templateChangedBy","hasTemplate","createTaxYear","targetFormRevisionId","_this36","_this37","loadRoles","_loadRoles","getFactorTableTypeName","formRevisionReport","updateFormRevisionInfo","templateSafeFileName","_this38","_loadAppealLevels","_loadAssetClassifications","_loadAllReports","formRevisionReports","formRevisionSchedules","_setFormRevisionYears","_this39","_this40","_this41","_this42","selectedAssessor","_this43","_this44","_this45","_loadAllFactorTables","_this46","_this47","_this48","_this49","_this50","_this51","updatedAssessors","_this52","updatedAssessor","existingAssessor","assessorIndex","_this53","_this54","_this55","_this56","_this57","_this58","_this59","FormListComponent","_formService","canExport","_setLastFormRevision","_longRunningProcessProgressSub","_longRunningProcessStatusSub","summaryData","stampLocations","_expandedFormIds","isRevisionCollapsed","_collapsedRevisionIds","expandFormRevision","collapseFormRevision","expandForm","collapseForm","selectedFormType","formList","createNewForm","showFormDetailsWithParams","typeText","deleteSupplement","createRevision","configureAssociations","createSupplement","parentRevision","priorFormRevision","editRevision","editSupplement","exportFormsSetup","_formsSetupFileLongRunningProcessId","importFormsSetup","_exportFormListLongRunningProcessId","exportFormsLibrary","formTypes","FormScheduleListGridCheckboxCellRendererComponent","FormScheduleListGridActionCellRendererComponent","FormScheduleListGridFactorTableDropdownCellRendererComponent","_factorTablesSub","FormScheduleListGridInputCellRendererComponent","FormScheduleListGridReportDropdownCellRendererComponent","_reportsSub","FormScheduleListComponent","_formRevisionSub","_assessorSub","_assessorsSub","_formRevisionYearSub","_schedulesSub","_canEditSchedule","scheduleFactorTables","isFactorTableLocked","_setDefaultFactorTable","factorTableName","_defaultFactorTableChanged","_isLockVisible","canUndoDelete","undoDelete","scheduleChangedToNonDepreciable","abbrInvalid","scheduleRow","abbrDupes","_setSavedSearch","newSchedule","scheduleFactorTable","formRevisionScheduleFactorTableId","formSchedules","FormYearListComponent","selectedYearChanged","FormYearNewModalComponent","priorTaxYear","nextTaxYear","isTaxYearIndeterminate","FormYearNewComponent","canCreateTaxYear","FormYearCopyListComponent","allAvailableTaxYearsForFormRevision","selectedFormRevisionName","formRevisionTaxYear","allAvailableFormRevisionNames","isSaveEnabled","selectedFormRevisionTaxYear","busyMsgLoading","selectedFormRevisionYear","FormYearCopyComponent","copyTaxYear","FormYearDeleteComponent","canDeleteTaxYear","FormAssessorsPanelGridActionCellRendererComponent","FormAssessorAddComponent","filteredAssessors","AssessorAddressTooltipComponent","FormAssessorListAddressCellRendererComponent","FormAssessorAddressPickerComponent","addressChanged","selectedAssessorAddress","_addressId","addresses","assessorAddresses","isFormRevisionYearAssessor","fryaAddress","_onSelectEdited","assessorAddress","combined","AssessorCertifiedTooltipComponent","FormAssessorListComponent","_gridTracker","forEachNodeAfterFilterAndSort","_isVisibleAssessor","_canEditDefaults","_editAddress","_canCertifyAssessor","_canEditAssessor","_canViewAssessor","_canRemoveAssessor","_onRemove","addNewAssessor","bulkRemove","_areAllAssessorsCertified","addressParams","e4","e5","e7","e9","areAllCertified","nonCertifiedAssessors","certifiedTooltip","areAllAssessorsCertified","FormCommentsComponent","FormAttachmentsComponent","FormFactorTableAddComponent","aft","fft","_availableFactorTables","FormFactorTableListGridActionCellRendererComponent","FormFactorTableListComponent","_getRowNodesFromSelectModel","hasRemovedSelected","_canEditFactorTable","formFactorTable","disassociations","bulkUndoRemove","selectModel","DropdownCellRenderer","overridesParentValue","isScheduleOverridden","isDepreciationOverridden","isFactorOverridden","hasChildOverride","childOverridesSchedule","childOverridesDepreciation","childOverridesFactor","FormAssetClassMappingListGridActionCellRendererComponent","FormAssetClassMappingComponent","_parentRequiredFilterSet","currentAssetClassification","_assetClassificationsNameMap","_childrenAssetIdsToShowDespiteFilter","mappingForClassification","ownedFormRevisionScheduleId","_blankFilterScheduleTest","_notBlankFilterScheduleTest","_setAssetClassifications","_factorTableSub","_classificationMappingsUpdatedSub","assetClassName","_filterName","_canShowHiddenChildren","_showHiddenChildren","_getName","_getTooltip","_filterMappingLookup","scheduleChanged","_depreciationFactorTables","factorAssessorTableRenderer","isFormRevisionScheduleReportable","isDepreciationFactorTableLocked","depreciationTableChanged","leasedToScheduleChanged","leasedFromScheduleChanged","_indexFactorTables","factorTableChanged","isExempt","exemptChanged","canViewDepreciationTable","_canViewDepreciationTable","viewDepreciationTable","_viewDepreciationTable","_collapsedClassifications","matchingRow","_flattenedData","dataRow","filteredOut","assetClassNameString","scheduleFilterType","scheduleFilterValue","_expandedClassifications","mapNodesWithFilteredOutChildren","filteredOutChildrenMap","idsInGrid","treeModel","_flattenedAssetClassificationsFullList","filteredOutChildren","_filteredOutChildrenMap","getRootDataNode","parentTreeItem","_setExempt","_setFormRevisionScheduleId","_setDepreciationTables","_populateOverrides","_setLeasedToFormRevisionScheduleId","leasedToFormRevisionScheduleId","_setLeasedFromFormRevisionScheduleId","leasedFromFormRevisionScheduleId","oldFormRevisionScheduleId","newFormRevisionScheduleId","_setDepreciationTableId","_setIndexFactorTableId","_originalMappingViewData","okToSave","mvd","formClassificationMappingId","oldDepreciationTableId","newDepreciationTableId","oldIndexTableId","newIndexTableId","_getScheduleFactorTable","_setDepreciationTable","defaultFactorTableId","_mapClassification","_setAssessorMappings","flattenedData","_generateAndPushTreeItem","resetAssessorMappings","_filterCheckValue","someChildrenPass","mappingFieldName","lookupFieldName","lookupTable","lookupNameFieldRenderer","lookupName","mappingViewData","dataNode","thirdLevel","classificationItem","assessorMappings","assetClassAllowPerpetual","depreciationTable","parentAssetClassificationNode","parentDataRow","childOverridesIndex","childClassification","childDataRow","_isPropertyOverridden","isIndexOverridden","itemValue","childrenToShowDespiteFilter","FormFieldListComponent","parameterList","rules","ruleList","tooltipField","FormFieldsComponent","FormTemplateEditComponent","currentMetadata","_setCurrentRowData","_setPreviewRowData","onCurrentAgGridReady","_currentGridApi","currentGridOptions","onOptionChanged","onPreviewAgGridReady","_previewGridApi","previewMetadata","preview","pagesIn","rotateBy","moveX","moveY","page","FormTemplateValidationComponent","_validationRows","validationResult","validationType","FormTemplateUploadComponent","hasErrors","hasWarnings","FormTemplateComponent","showValidations","FormReportListGridActionCellRendererComponent","FormReportListCheckboxCellRendererComponent","FormReportAddComponent","fr","formRevisionReportId","FormReportListComponent","_canEditSettings","formRevisionReportRow","FormSwitchesComponent","_updateIsPrimary","_updateIsInDevelopment","selectedFormIsSupplementalAppeal","onIsPrimaryChange","onIsInDevelopmentChange","initializedPrimary","_setCanEdit","initializedDevelopment","FormAppealLevelListComponent","onSelectedAppealLevelChange","FormAssessorSelectComponent","selectedAssessorChanged","FormFilingBatchListComponent","FormFilingBatchesComponent","FormPageComponent","areHidden","componentNames","GLAccountListAgGridDataSource","GLAccountService","_accrualsFeatureEnabled","_tlCompany","isSubsidiaryCompany","canReadCompany","_canReadCompany","canWriteCompany","_canWriteCompany","startResults","_startResults","accrualsFeatureEnabled","read","write","updateBulk","updateBulkIncomeStatementTypes","GLAccountDetailsComponent","_glAccountService","fPropTypes","fPmtTypes","accountAccrualTypes","glAccountAccrualTypes","paymentTypes","accrualScopeCompanies","selectedAccountType","applicableToAccruals","payableIncludesPrepaid","selectedAccountAccrualType","forAllCompanies","forPropertyTypes","forPaymentTypes","forCompanies","isValidated","foundInAccruals","_loadGLAccount","accountTypes","setupAllowedAccountTypes","accountTypeChanged","currAccountType","initializeScopeSelections","repopulateAccountAccrualTypes","foundInAssets","foundInIncomeStatements","switchApplicableToAccruals","accountAccrualTypeChanged","glAccountAccrualTypeId","PropertyTaxPayableType","showAssetClassification","showIncomeStatementCategory","arrPropTypeSel","arrPmtTypeSel","repopulate","currAccountAccrualTypes","accountTypeName","paymentTypeId","arrCompanySel","fc","ndx","cid","GLAccountBulkUpdateActionComponent","GLAccountBulkUpdateComponent","newClassification","_newClassificationName","glAccountBulkUpdateModel","glAccountListLastModifiedTimestamp","GL_ACCOUNT_LIST_HELP","GLAccountBulkUpdateIncomeStatementTypesComponent","accountTypeId","accountTypeIdAction","incomeStatementCategoryIdAction","accountTypeAction","incomeStatementCategoryAction","showIncomeStatementCategoryChoices","incomeStatementCategoryControl","incomeStatementCategoryActionControl","equity","liability","internalSubs","accountTypeControl","accountTypeActionChanged","incomeStatementCategoryActionChanged","accountTypeIsChanging","originalAccountTypeId","accountTypeNoChangeIsValid","accountTypeChangeIsValid","categoryIsSet","categorySetToBlankIsValid","categoryChangeToIsValid","GLAccountListComponent","getSelectionSummary","catchError","canBulkUpdate","buttonClass","_isAllSelectedAccountsFoundInISAndValidated","incomeStatementTypes","revenue","reporting","expense","otherTypes","showIncomeStatementTypesBulkUpdate","cellParams","LONG_RUNNING_PROCESS_PAGE_HELP","LongRunningProcessListAgGridDataSource","LONG_RUNNING_PROCESS_LIST_HELP","LongRunningProcessListGridActionCellRendererComponent","ErrorLogDetailsComponent","_errorLogRepository","errorLog","LongRunningProcessListGridErrorGuidCellRendererComponent","LongRunningProcessListComponent","_timeSpanPipe","_gridInitialized","_statusChangeSub","showErrorDetails","_showErrorDetails","canUpdateError","_canUpdateError","_updateError","errorModel","detailParams","LONG_RUNNING_PROCESS_QUIESCE_MODAL_HELP","LongRunningProcessQuiesceModalComponent","LONG_RUNNING_PROCESS_QUIESCE_HELP","LONG_RUNNING_PROCESS_SYNTHETIC_MODAL_HELP","LongRunningProcessSyntheticModalComponent","longRunningProcessQueueType","queueType","throwException","publishProgressChangeMessage","setInstantsDefault","setWithDurationDefault","setMultipleDefault","setOverTimeDefault","numberOfProcesses","LONG_RUNNING_PROCESS_SYNTHETIC_HELP","LongRunningProcessSyntheticComponent","LONG_RUNNING_PROCESS_CONTROL_MODAL_HELP","LongRunningProcessControlModalComponent","serviceHost","getControlMessage","LONG_RUNNING_PROCESS_CONTROL_HELP","LongRunningProcessControlComponent","sendMessage","LongRunningProcessQuiesceComponent","isQuiesced","LongRunningProcessPageComponent","onAutoRefreshChange","verifications","elementId","verifiedByName","stateJurisdiction_columns_getDescriptorValue","stateJurisdiction_columns_BASE_DYNAMIC_DEFINITIONS","headerParams","StateJurisdictionCommandCenterAgGridDataSource","_stateJurisdictionService","sortParameter","verification","StateJurisdictionBulkUpdateComponent","defaultAddressCorrespondenceTypeName","ppReturnAddress","appealFilingAddress","generalAddress","defaultAddressType","ppAddress","changedDescriptors","changeToCorrespondenceType","showSplitControls","showControls","_setTabFormState","areSplitControlsVisible","STATE_JURISDICTION_COMMAND_CENTER_HELP","CommandViewControlsComponent","countryId","highlightModel","filterForm","recentChanges","_outputFormChanges","_outputHighlightChanges","_outputFilterChanges","_all","StateJurisdictionCommandCenterComponent","selectedGridSourceOption$","currentSearchModel$","currentFilterModel$","verificationStatus","highlightChanges$","_highlightDate","updatingValue$","updating","updateParams","updatedDate","deadlineInfo","initialDate","assessorWebsite","assessorEmail","compliancePPAssessorDeadlineIsForTaxYear","compliancePPDeadline","appealPPAssessorDeadlineIsForTaxYear","appealPPDeadline","appealREAssessorDeadlineIsForTaxYear","appealREDeadline","appealCAAssessorDeadlineIsForTaxYear","appealCADeadline","appealMNAssessorDeadlineIsForTaxYear","appealMNDeadline","ppReturnFormsPrimaryCount","generalAddressVerificationElementId","qcDate","verifiedDate","generalAddressCount","getAddressCellStyle","generalAddressChangeDate","ppReturnAddressVerificationElementId","ppReturnAddressCount","ppReturnAddressChangeDate","appealFilingAddressVerificationElementId","appealFilingAddressCount","appealFilingAddressChangeDate","minVerifiedDate","STATE_JURISDICTION_LIST_COLUMNS","_getCellStyle","_getCellWarning","verifiedColumn","BASE_VERIFICATION_COLUMN","addressCount","isRecent","highlightDate","agGridDropdownCellRenderer_component_DropdownCellRenderer","isInherited","sourceType","SupplementalInformationSheetComponent","_supplementalInformationRepository","_onAgCellValueChanged","labelName","optionType","_supplementaryInformationOptions","supplementalDataChanged","stateFilterTypeChanged","selectedCompanyIdChanged","fieldMapChanged","rowsToSave","topRow","getFloatingTopRow","fieldMap","fm","tooltipValueGetter","tip","supplementalInformationLookupType","supplementalList","defaultRow","stateFilterType","activeStates","defRowToShow","ConsultingEngagementModalComponent","_engagementsRepository","engagementForm","assignedUserTeam","transformAccountHandler","_sortUserGroups","getPropTypeAbbr","accountHandlerChanged","getSaveLabel","saveEngagement","engagementRequest","accountHandlerTeamId","userGroupIds","handleUpdateErrors","anyErrors","isNotAuthorized","addingNewGroup","selectedGroupId","groupIndex","ConsultingEngagementsComponent","engagements","openEngagementModal","rejectInvitation","Dashboard","userWidgets","WidgetIds","RefreshPolicies","DashboardCalendarEventTypes","CalendarMonth","weeks","CalendarWeek","CalendarDay","DashboardDataService","getDashboard","resetDashboard","addToDashboard","widgetId","firstPossiblePosition","widgetUrl","removeFromDashboard","updateUserWidget","userWidget","userWidgetId","getWidgetData","widgetDataLookup","httpParams","widgetCache","widget","refreshPolicy","getWidgetSettings","saveWidgetSettings","widgetSettings","getShowDashBoardUserSetting","_showDashboardSettingGroupId","_showDashboardSettingName","updateShowDashboardUserSetting","showDashboard","showDashboardToggled$","getSmartAvFields","saveSmartAvFields","calendarWidgetFields","getSmartAvFieldsDefault","UnsubscribeMixin","AppealSavingsWidgetComponent","_advancedSearchService","data$","goToSmart","appealSavingsWidget","QuickSearchButtonWidgetComponent","resetFilter","StatesButtonWidgetComponent","goToStatePage","CalendarWidgetComponent","calendarDate","eventTypesByDay","_groupEventTypesByDay","_generateMonth","legendBlocks","_getLegendFromData","nextMonth","_monthChanged","previousMonth","dashboardCalendarEventType","getBackgroundColor","goToSmartFromPopover","eventTypeBlock","clickedDay","encodeURI","_goToSmart","legendClicked","legendBlock","calendarTaskIcon","eventTypeBlocks","_EVENT_TYPE_TO_TEXT","isDayToday","getEventTypeTitle","dayView","getPopoverPlacement","weekIdx","dayIdx","dayClicked","calendarDateIcon","_getEventTypeSequence","eventDays","firstDayOfTheWeekIdx","week","daysInMonth","dayOfTheWeekIdx","weekdayAbbr","_createEventTypeBlocks","newParams","_aggregateStates","dateEvents","summedEvent","ShortcutWidgetComponent","groupByType","groupedShortcuts","shortcuts","_getCategory","goToShortcut","shortcut","ShortcutWidgetSettingsComponent","dashboardDataService","canViewReports","_compileShortcutLists","addedShortcuts","savedSearchIds","actionViews","smart","smarts","_removeAddedShortcutsFromLists","addShortcuts","selectedActionViews","selectedSmarts","selectedReports","removeShortcut","saveAndClose","PortfolioAnalysisAnnualData","exporting_default","PortfolioAnalysisChartTableComponent","_activityService","_dashboardDataService","TOTALFMV","FMVPERSQFT","FMVPERUNIT","LANDFMV","LANDFMVPERSQFT","LANDFMVPERACRE","TOTALTAX","resize$","highChart","setSize","resizeGrid$","reverseIt","getTotalValueForYear","totalValueName","yearTotals","TotalValueAttributes","sortByPropType","chartTypeSelected","graphSelected","PortfolioAnalysisWidgetComponent","isChartWidget","userWidgetResize$","lineItemClicked","chartTableComponent","analyticsValue","taskSeriesTypeItem_r10","MyTasksWidgetComponent","taskSeriesTypeList","dataSubscription","actionViewTimeout","colClass","drilldownCell","cell","taskSeriesTypeName","goToActionView","MyTasksView","MyTasksWidgetSettingsComponent","myTasksViews","viewId","selectedMyTasksView","myTasksView","CalendarWidgetSettingsComponent","asService","calendarWidgetIds","calendarWidgetIdsDefaults","allOutputColumns","_isDummyComplianceCategory","defaultCategory","eventTypeTitleMap","_mapColIds","masterComplianceCategoryIdx","masterComplianceCategory","calendarWidgetFieldsIds","columnsToMap","columnsToKeep","WidgetComponentRegistryService","smallerSettingsModal","getWidgetComponentById","widgetComponents","getRegisteredWidgetById","UserWidgetComponent","widgetComponentRegistryService","resolver","widgetDataSource","widgetParams","confirmRemove","widgetRemove","goToSettings","registeredWidget","DashboardComponent","draggable","displayGrid","designMode","enableEmptyCellClick","maxCols","minCols","minRows","maxRows","scrollToNewItems","emptyCellClickCallback","itemResizeCallback","itemChangeCallback","setDashboard","isShowDashboard","resizeGridSub","addWidget","possibleGridItem","getNextPossiblePosition","getFirstPossiblePosition","dashboard","availableWidgets","newUserWidgetIdArr","newUserWidget","minItemCols","minItemRows","removeWidget","removedIdx","toggleDesignMode","resetToDefault","toggleShowDashboard","useLightIcon","DatabaseProcessListGridActionCellRendererComponent","DATABASE_PROCESS_LIST_HELP","DatabaseRepository","getRunningProcesses","killProcesses","sessionIds","clearCacheEntries","planHandles","searchCachePlan","searchString","DatabaseClearCacheEntryComponent","_databaseRepository","planEntries","searchObject","objectName","clearPlanEntry","planHandle","ProcessListComponent","sessionId","_navigateToUnauthorized","_isSelectingRangeSub","_sourceData","killProcess","_killProcess","bulkKill","_killProcesses","clearCacheEntry","confirmationMessage","progressMessage","DiagnosticsComponent","_hasAdminOperationsView","_hasAdminOperationsEdit","_hasAllowManageSystem","_hasAdminRole","diagnosticOptions","_allDiagnosticOptions","_setDiagnosticControlValue","diagnosticControl","ErrorLogListAgGridDataSource","ErrorLogListGridActionCellRendererComponent","ErrorLogService","ErrorLogListComponent","_errorLogService","_viewDetails","QueryInfoListAgGridDataSource","_queryInfoRepository","QueryInfoListGridActionCellRendererComponent","queryInfo","QueryInfoDetailsComponent","QueryInfoService","QueryInfoListComponent","_queryInfoService","paginationSetPageSize","InstanceInfoPanelComponent","_instanceRepo","showSpinnerSettings","showSpinnerDocumentIntakeAndProcessing","instanceModel","showDocumentIntakeAndProcessingPanel","companyModel","customerCompanyId","customerCompanyName","documentIntakeAndProcessingClientUserId","setEditSettings","isEditSettings","_setEdit","setEditDocumentIntakeAndProcessing","isEditDocumentIntakeAndProcessing","_save","initialInstanceModel","cancelSettings","_cancel","saveDocumentIntakeAndProcessing","canSaveDocumentIntakeAndProcessingSettings","documentIntakeAndProcessingClientSpecialInstructions","cancelDocumentIntakeAndProcessing","userChosen","documentIntakeAndProcessingClientTeamId","ManageInvitationsComponent","getHomeIndicator","acceptInvitation","changesMade","toggleVisibility","MOVE_COPY_HELP","MoveCopyEntityService","copyMoveEntity","Entity","CopyMoveCSRModeEnum","LandingViewTypes","MoveCopyPayload","actionId","destEntityID","sourceIDs","includeAttachments","includeAppeals","includeComments","csrMode","AlwaysPreserveExisting","MoveCopyEntityComponent","_moveCopyEntityService","sourceIdIdx","sourceIds","_areValidIds","launchingEntity","_goToHome","hasCsrErrors","targetInstanceId","hasInstanceAdminPermission","_setupEntity","_getBeginningYears","_getYears","moveCopyPayload","getSitesByCompanyId","_getFilteredStates","isTarget","stateSites","_getFilteredSites","selectedEntitiesChanged","movingSitesSelected","isCopy","targetCompany","movingParcelsSelected","allParcels","targetCompanySelected","loadingSites","getSiteNameWithNumber","getTargetSiteName","executeMoveCopy","_executeMoveCopy","cancelExecute","isExecuting","moveCopyCompleted","backToEntity","siteInactiveStatusChanged","showSiteNumberStatusChanged","s1","s2","parcelInactiveStatusChanged","siteStateIds","arg","_setupCompany","showSiteNumber","awaitingConfirm","interInstanceCopy","ignorePendingReturnError","SiteMapService","featureType","stylers","getSitesToMap","sitesToMapRequest","getSiteMarkerInfo","SiteMapInfoWindowComponent","selectedMarkerInfo","siteMarkerInfoArr","getAbbrevs","propertyTypeAbbrevs","navigateToSite","SiteMapComponent","_Constants","siteMapService","startingZoom","siteClassPrimaryIds","mapOptions","styles","mapStyles","markerOptions","google","maps","Animation","DROP","infoWindowOptions","_getSite","debouncedGetSiteInfo","getSiteInfo","getNewSites$","_getNewSites","originalSite","originalCenter","lat","latitude","lng","longitude","paddedBounds","_getPaddedBounds","filteredSites","bounds","isOriginalSiteIncluded","filteredSitesNotOnMap","sitesToDisplay","sitesToAdd","iconName","siteClassPrimaryID","stackId","center","sitesToRemove","totalOffset","startingOffset","zoom","northwestCorner","viewportBounds","southeastCorner","siteClassesSelected","boundsChanged","getBounds","northeastCorner","getNorthEast","southwestCorner","getSouthWest","getZoom","mapIdle","navigateToOriginalSite","mapMarker","infoWindow","hoveredSiteId","siteMarkerInfoGetResult","mouseOutOfPin","windowHover","limitToParentCompany","mouseEnterWindow","mouseleaveWindow","MapInfoWindow","GoogleMap","HelpComponent","LandingComponent","existingDefaultViewSetting","defaultView","defaultViewChange","showActionView","MyTeamsTasks","settingUpdated","savedSetting","goToDashboard","LandingSelectorComponent","AceButtonGroupComponent","singleSelect","selectedButton","button","selectedButtonChange","_validateRouterChange","onButtonClicked","_updateButtonStyles","activeStyle","activeState","inactiveStyle","inactiveState","SavePageComponent","userSavePage","SavedActionViewComponent","newActionView","SavedReportComponent","SaveTabContentComponent","_deleteCategory","categoryTotal","curr","selectedFilter","userPageConfig","_checkSelectedCategory","selectCategory","hasMenuOptions","getMenuOptions","loadingRowMenu","rowMenuOptions","SavedSmartComponent","newSmart","PaymentBatchCommandCenterAgGridDataSource","gridFilters","PAYMENT_BATCH_COMMAND_CENTER_HELP","PaymentBatchListGridActionCellRendererComponent","CreatePaymentBatchModalComponent","GetEntitiesRequest","newPaymentBatchForm","descriptionText","batchType","topCompanySelected","allowedBatchTypes","batchTypes","batchTypeOptions","selectedBatchTypeId","paymentBatchCreation","PaymentBatchFiltersComponent","_initSelections","workflowTypes","workflows","batchStatuses","dateTypes","_dateTypeMap","pbGoBack","selectionsString","tlCompanies","dateTypeFilters","showCompleted","isDisabledBasedOnBatchType","batchTypeId","makeItDirty","subCompanies","subCompanyIds","availableSubCompanies","dateTypeChanged","dateFilter","dateType","batchTypeSelected","workflowTypeId","batchStatusName","workflowType","_populateBatchStatuses","workflowSelected","showCompletedToggle","disableAppyButton","PaymentBatchCommandCenterComponent","gridDataSource","launch","onViewDetails","_navigateToPaymentBatchDetails","_deletePaymentBatch","editDeleteAllowed","formatCurrency","overlayNoRowsString","fundingDueDate","PAYMENT_BATCH_LIST_COLUMNS","PaymentBatchTaskExceptionModalComponent","workflowStatus","canReassignTask","taskStatusName","canRescindTask","taskRescindName","_actOnTask","TabIdxs","PaymentBatchDetailsComponent","_loadPaymentBatch","_loadPaymentBatchDetailsWorkflowStatus","paymentDetailsTabs","isTransmittal","refreshPage","bypassTabSwitch","Packages","paymentBatchPackages","Payments","paymentBatchDetailsGrid","taskAdvanceName","advanceCreatesPackages","hasZeroAmountPayments","refreshStatus","refreshPayments","refreshPackages","paymentErrors","newKey","draftID","addPaymentErrors","uniqueErrorPayments","launchExceptionModal","recallBatch","batchNo","SaveReportModalComponent","modalParameters","isComplianceReport","_isComplianceReport","allCategories","systemReportCategories","userReportCategories","defaultUserCategory","defaultSystemCategory","reportTypeClicked","newCategoryName","reportCopy","newReport","_saveCompleted","_saveReport","forceSystem","PsrRequest","MaarRequest","BudgetRequest","BudgetVarianceReportingRequest","formatOutput","includeDisclaimer","ProgressStatusRequest","SiteRequest","UserActivityRequest","UserAccessRequest","UserCSRRequest","SupportInstanceEscalationActivityReportRequest","ReportingService","runPsrReport","psrRequest","shouldZip","runBudgetReport","budgetRequest","runBudgetVarianceReport","budgetVarianceRequest","runMaarReport","maarRequest","runProgressStatusExtract","pseRequest","runSiteReport","siteRequest","runUserActivityReport","userActivityRequest","runUserAccessReport","userAccessRequest","runUserCSRExtract","userCSRRequest","runAppealListReport","runSupportInstanceEscalationActivityReport","REPORT_MANAGER_HELP","FurtherLimitPanelPsrComponent","newYearValue","propertyTypeIDs","includeEstimatedAssessments","includeOnlySitesUnderAppeal","yearChangedValidation","taxYearEnd","FurtherLimitPanelBudgetComponent","yearsToDisplay","topLevelCompaniesObj","fiscalYearStartDate","fiscalYearEnd","yearSelected","numYears","defaultValues","minimumDetailYearsShown","budgetYear","endBudgetYear","budgetYearString","FurtherLimitPanelMaarComponent","siteStatuses","siteStatus","FurtherLimitPanelProgressStatusComponent","FormatOutputPanelPsrComponent","currentPropChars$","filterPropChars","_setDefaultsBudget","orderAndTotalByChanged","psrFormatOutputOptions","orderAndTotalBySelection","orderAndTotalByOptions","groupByThisItem","orderAndTotalBySelected","addNewOrderAndTotalBy","removeOrderAndTotalBy","groupByChanged","entityPropChars","orderAndTotalByOptionsOriginal","formatOutputOptions","primarySortOrder","_populateOrderBy","lastOrderById","ReportOrderByComponent","orderByOptions","orderByChange","ReportDetailOptionsComponent","_detailReportOptions","detailReportOptionsChange","FormatOutputPanelBudgetComponent","budgetBasisChanged","budgetYearSources","availableBasisBudgets","priorYearSources","currCompanyBudgetID","priorCompanyBudgetID","FurtherLimitPanelSiteComponent","yearChoice","numberOfYearsToInclude","taxYearBeginUI","yearChoiceChanged","FormatOutputPanelSiteComponent","siteFormatOutputOptions","FurtherLimitPanelSchedulesSummaryComponent","scheduleId","selectedSchedule","scheduleSelectorDisabled","FormatOutputPanelSchedulesSummaryComponent","_getTitle","reportOutputForm","createControl","formatOptions","optionalCols","_updateReport","includeFactorAndDepreciatedValue","FurtherLimitPanelAssetDetailComponent","_scheduleFilters","assignScheduleId","priorReturnStatusName","onFormRevisionChange","FormatOutputPanelAssetDetailComponent","includeAssetClass","includeAcqYear","includeDisposedDate","includeGLAccount","includeScheduleName","includeFactorTableName","includeAdditionalDepreciation","includeEstimatedFMV","includeCost","includeCostChange","_previousScheduleName","_scheduleName","_setTitle","_priorReturnStatusName","hasMoreAvailableDescriptors","additionalDescriptors","layoutGroup","_createLayoutGroup","reportFormatGroup","_createFormatGroup","leaseFromGroup","_createLeaseFormGroup","leaseToGroup","leaseToCols","leaseFromCols","assetType","_initializeAdditionalColumns","_getLeaseValues","optionalGroup","_getOptionalValues","_initializeSelectedGroups","selectedAssetGroups","_applyGroupingChanges","_outputReport","includeLeaseClientId","includeLeaseLocationName","includeLeaseLocationAddress","includeLeaseStartDate","includeLeaseEndDate","includeLeaseTerm","includeLeaseMonthlyPayments","includeLeaseType","includeLeaseAssestId","includeLeaseNumber","includeLeaseBillingInfo","includeLinkedSubParcelAcctNumber","includeLinkedSubParcelDescription","includeLinkedSubAssessorAbbr","previousExpectedName","newExpectedName","include","assetDescriptor","skipNext","assetGroup","assetGroups","legalSize","showLandscape","watermark","showTaxpayerName","showTransferDetails","showChangeDetails","showGrandTotal","leaseOutput","reportChange","UserAccessReportLimitByLoginDateEnum","SupportInstanceEscalationActivityReportLimitByEscalationDateEnum","SupportInstanceEscalationActivityReportGroupByEnum","StartWithEnum","FurtherLimitPanelUserActivityComponent","limitByLoginDate","loginDatePeriod","loginDateBeginUI","loginDateBegin","loginDateEndUI","loginDateEnd","loginDateChoiceChanged","onlyActiveUsers","includeUsersWithoutLogin","FormatOutputPanelUserActivityComponent","userActivityFormatOutputOptions","FurtherLimitPanelBudgetVarianceComponent","_topLevelCompanyChangedSub","availablePeriods","budgetPeriodSelectionChanged","FormatOutputPanelBudgetVarianceComponent","_loading","_selectedBudgetsChangedSub","refreshBudgetSources","filteredBudgetSources","noForecastBudgetSources","sourceBudgetChanged","firstBudgetSources","NoSelectionBudgetSource","confirmSelection","secondBudgetSources","thirdBudgetSources","fourthBudgetSources","srcIndex","selectionAvailable","FurtherLimitPanelSupportInstanceEscalationActivityComponent","limitByEscalationDate","escalationDatePeriod","escalationDateBeginUI","escalationDateBegin","escalationDateEndUI","escalationDateEnd","escalationDateChoiceChanged","anyEscalationDates","FormatOutputPanelSupportInstanceEscalationActivityComponent","escalationGroupBy","ReportManagerComponent","_reportingService","saveModalClosed","showEntitiesSelector","ReturnScheduleSummary","ReturnAssetDetail","UserCSR","startWith","requestButtonIsDisabled","initializingReport","hasSystemReportPermission","hasRyanPrivatePermission","isInModal","userSearch","saveVisible","saveAsVisible","hasRestrictedAccess","isUndefined","updateSaveVisible","updatedReport","_saveSystemReport","saveReportAs","requestReport","lrpTypeId","ProjectStatus","requestPsrReport","Maar","requestMaarReport","Budget","requestBudgetReport","BudgetVariance","requestBudgetVarianceReport","ProgressStatus","requestProgressStatusReport","requestSiteReport","requestUserActivity","requestUserAccess","requestUserCSR","requestSupportInstanceEscalationActivityReport","showRevokeReportButton","revokeReportShare","updateFavoriteStatus","showRequestReportButton","setSelectedContact","specialCompliancePermission","reportRequest","basePayload","reportTitle","showParcelsAddedSinceCheckbox","showParcelsAddedSince","startYearValue","endYearValue","includeEstAssessment","psrReportType","YearValue","includeAllCompanies","merge","selectedUserId","userAccessReportStartWith","userAccessReportLimitByLoginDate","totalEntityFilterLevelsApplied","RolesListComponent","SMART_SEARCH_HELP","ColumnFilterService","map_default","reject_default","SaveSearchModalComponent","searchCategoryOptions","searchFormGroup","_searchCategories","formGroup","saveHelpContentId","addingNewCategory","searchCategories","_noCategory","setCustomCategory","categoriesLoading","searchNameRef","newCategoryNameRef","categoryToSubmit","_createOrUpdate","smartSavedSearchType","smartSavedSearchDisplay","smartSavedSearchCategory","_broadcastAndClose","e1","_errorToast","FilterListComponent","_searchCriteria","searchFilters","addFilters","updateCriteria","toggleOrs","smartOrToggle","loadSaveSettings","DragAndDropDraggableDirective","_dndState","originalEvent","dndType","dndEffectAllowed","ALL_EFFECTS","dataTransfer","dndDraggable","mimeType","MIME_TYPE","EDGE_MIME_TYPE","effectsAllowed","effect","MSIE_MIME_TYPE","_dndHandle","setDragImage","dndDragstart","dndCallback","move","dndDragend","dndSelected","_setDraggableAttr","dndDisableIf","_disableIfSub","DragAndDropListDirective","dragenter","_hoverCount","dndAllowedTypes","_listSettings","allowedTypes","externalSources","dndExternalSources","horizontal","dndHorizontalList","_getMimeType","_isDropAllowed","_getItemType","dragover","_placeholderNode","_listNode","_placeholder","listItemNode","rect","isFirstHalf","nextSibling","ignoreDataTransfer","_getDropEffect","dndDragover","_stopDragover","_getPlaceholderIndex","droppedItem","dndList","dndListItemIdGetter","dndDrop","dndListChange","dndInserted","dragleave","newTarget","elementFromPoint","_dndPhShown","_getPlaceholderElement","effects","_filterEffects","altKey","expression","external","isPrototypeOf","HTMLCollection","childNode","li","DragAndDropNoDragDirective","dragstart","DragAndDropHandleDirective","OutputListComponent","groupByBatches","outputChanged","areBatchFields","batchFieldsPresent","AdvancedSearchComponent","hideRevokeShareButton","_populateSearch","_updateAdvancedSearchMenu","revokeSearchShare","savedSearchDTO","reloadSearch","_initSearch","userChangedSettings","updateSearch","updateSearchResults","_loadSearch","_populateFilters","transitionToNewSearch","filterToUpdate","AdvancedSearchListService","fieldCollection","advancedSearchFieldIds","AdvancedSearchBulkUpdateComponent","_advancedSearchListService","getUpdatableFields","accArr","advancedSearchFieldId","ptxFields","fieldIds","dummyDescriptor","internalName","descriptorPickList","descriptorPickLists","AdvancedSearchColumnBuilder","_popUpService","getColumnDefinition","baseDefinition","navigationRoute","_getNavigationRoute","_setPersistentState","suppliedFormatting","formatting","dataTypeCustomFormatting","_getTypeColumnProperties","clickHandler","_fieldSpecificClickEvents","onCellClicked","_getCommentCell","navigationFieldName","_getNavigationalFieldValueByName","minimumFractionDigits","advancedSearchDataTypeID","valueToFormat","Intl","NumberFormat","maximumFractionDigits","dateFormatter","inputDateTime","cA","_constructDateIfAbsent","cB","customFormatting","gridShowValueAsZeroIfZero","gridShowValueAsZeroIfNull","useGrouping","pdfLoading","_ref18","attchmentGroupName","n1000","n1498","n1900","AdvancedSearchListComponent","_columnBuilder","onRowDataChanged","ensureIndexVisible","dataTable","_tableData","_buildTable","_clearTable","haveAllSearchFields","rowDataIds","searchFields","ptxCompanyFields","ptxParcelFields","depthFieldId","advancedSearchCategory","parentCategoryID","smartBulkUpdatedRecords","tableData","outputIds","baseColumn","tableDataWithRowIds","_exportToCsv","_exportToExcel","SmartSearchComponent","_columnFilterService","smartRefineCriteria","noOutputColumns","hideCriteria","_REFINE_SEARCH_EVENT","excelDownloading","gridResult","smartOutput","UnitedStatesComponent","_resizeMap","disableCollectorList","disableAssessorList","downloadAssessorExtract","loadingAssessorList","_downloadFile","_NAVIGATED_DASHBOARD","downloadCollectorExtract","loadingCollectorList","onStateSelect","typeaheadVal","unitedStates","_mapHeight","_updateMap","Datamap","geographyConfig","popupOnHover","highlightFillColor","highlightBorderColor","highlightBorderWidth","fills","defaultFill","labelSize","responsive","datamap","geography","labelColor","fontSize","StateDetailsComponent","USStateComponent","_loadState","SupportInstanceRepository","requestAccess","terminateAccess","deactivateInstancePending","deactivateInstanceConfirm","deactivateInstanceRevert","deactivationInfo","SupportInstanceRequestAccessComponent","_supportInstanceRepository","reasonLength","onReasonChange","SupportInstanceDeactivateInstancePendingComponent","maxReasonLength","SupportInstanceDeactivateInstanceConfirmComponent","busyMsgIdSaving","checkForOpenAppeals","confirmDeactivateInstance","hasOpenAppeals","openAppealNames","busyMsgIdOpenAppeals","requestTwo","SupportInstanceListComponent","userHasDeactivateInstancePermissions","instanceActivationStatus","accessGrantedDate","showDeactivateInstanceButton","showAccessInstanceButton","isAccessTerminating","deactivateInstance","pendingReason","deactivationReason","pendingUserName","deactivationPendingUserName","pendingDateTime","deactivationPendingDate","toLocaleDateString","updateStatusPopoverOpened","isMouseHovering","statusPopoverOpened","ActionViewOutputCustomComponent","ActionViewOutputDefaultsComponent","_userSettingService","_taskTypeColumns","_getUserColumns","_saveUserSetting","_taskTypes","TaxAuthoritySelectionType","CommandCenterPropertyEnum","TaxAuthorityBulkUpdateRequest","TaxAuthorityBulkUpdateContent","TaxAuthorityBulkUpdateProgress","TaxAuthorityUpdateResults","billClusterCount","TaxAuthorityBulkUpdateActionComponent","TaxAuthorityBulkUpdateComponent","taBulkUpdateRequest","defaultAnnualIncreaseDisplay","defaultAnnualIncrease","yoyPercent","categoryAction","taxableAssessmentTypeAction","certificationDateAction","obtainInAdvanceAction","defaultAnnualIncreaseAction","yoyAction","defaultAnnualIncreaseBlur","_isValidPercentage","certificationMonth","certificationDay","TaxRateCommandCenterAgGridDataSource","onlyPendingQC","getSearchModelForBulkUpdate","RightsDisplay","CompanyPermissionOptions","TaxRateCommandCenterComponent","taxRateCommandCenterService","qcCountsUpdating","selectedNode","hasDataImportPermission","_TAX_AUTHORITIES_GRID_ID","_qcCountSub","observableInterval","pendingQcStateCounts","_getQcCountTotal","_selectedEntitiesInfo","queueProcessingStatus","_agGridReady","gridSourceSelected","gridSource","_changeGridSource","filterGridByStateAndQc","refreshQcCounts","assessorsCollectorsLoading","stateAssessors","_abbrSort","stateCollectors","selectedAssessorId","selectedCollectorId","assessorSelected","assessorCollectors","collectorSelected","showTaxYearChangedCC","onlyPendingQCChanged","rowsSelectionModel","selectionType","selectedTaxAuthorityIds","_refreshAssessorCollectors","getCurrentTABulkUpdateSelection","getCurrentTABulkUpdateIdentity","isRetryDisabled","isRetryVisible","retry","retriedNodes","queueProcessingStatusId","queueProcessingStatusName","showBulkUpdateRecalcSummary","addressString","certificationDate","_TAX_RATE_AREAS_GRID_ID","qcCountTotal","selectionInfo","CompanySitePermissionsAgGridDataSource","_permissionService","getCompanySiteRowIds","getAvailableSitePermissions","PermissionService","getGroupInstanceRights","getAvailableGroupInstanceRights","updateGroupInstanceRights","instanceRightsIds","getGroupApplicationRights","getAvailableGroupApplicationRights","updateGroupApplicationRights","roleIds","getUserOrGroupEntityPermissions","getCompanyRowIds","getAvailableCompanyPermissionsForGroup","getAvailableCompanyPermissionsRowIds","updateEntityPermissions","permissionSaveRequest","CompanySitePermissionsComponent","headerTooltip","alreadyUpdatedIdx","saveRequest","alreadyDeletedIdx","adds","alreadyAddedIdx","deletes","_getDropownPermission","dbPermission","inMemoryPermissions","CompanyListAgGridDataSource","CompanyPermissionAddComponent","onExcludeInactive","CompanyPermissionAgGridDataSource","USER_GROUP_DETAIL_HELP","UserGroupsService","_panelEditSub","setPanelEdit","getGroup","deleteWithConfirm","CompanyPermissionPanelComponent","_userGroupsService","suppressHorizontalScroll","currentInstance","permissionRow","_setPermissionFlags","gridIsDirty","canLaunchSitesModal","launchSitesModal","rowPinned","addedCompanies","addNewCompanyPermission","dataSourceParams","_resetPanel","expandCollapse","expandClicked","rightsString","InstancePermissionPanelComponent","setDataSource","allPermissions","_initPermissions","otherOptions","noneOption","rightOptions","_originalAllPermissions","_exitEditMode","ApplicationPermissionPanelComponent","canBeEdited","UserGroupDetailComponent","_loadUserGroup","panelEditChange$","isPanelEdit","companyPermissionPanel","instancePermissionPanel","applicationPermissionPanel","expandedPanel","userGroupId","AddUserGroupModalComponent","nameInput","UserGroupListComponent","isConsultantGroup","isSupportGroup","isDocumentsGroup","newUserGroup","_userGroups","IncomeStatementAgGridDataSource","_incomeStatementRepository","IncomeStatementBulkUpdateComponent","isValidatedControl","balanceControl","isValidatedAction","balanceAction","balance","IncomeStatementListComponent","currentTotals","isEmbededMode","onLoading","_initEndDates","onEndDateChange","selectedEndDate","_deleteItem","lineItem","_updateIsValidated","cellClassRules","calculatedBalance","importedBalance","_updateBalance","glAccountName","endDates","validatedBy","validatedDate","RentRollAgGridDataSource","RentRollGridActionCellRendererComponent","RentRollBulkUpdateComponent","RentRollListComponent","rentRollRow","sqFt","annualMarketRent","annualMarketRentCalculated","monthlyMarketRent","monthlyMarketRentCalculated","annualRent","annualRentCalculated","monthlyRent","monthlyRentCalculated","annualOther","annualOtherCalculated","monthlyOther","monthlyOtherCalculated","annualCAM","annualCAMCalculated","monthlyCAM","monthlyCAMCalculated","occupancySqFt","vacancySqFt","totalSqFt","occupiedUnits","vacantUnits","totalUnits","rentRollGridSelectedTotalsRow","rentRollGridTotalsRow","_getCalcOrUncalcValue","rentRollItem","actualValue","calcValue","ValuationTemplateService","_valuationTemplateRepository","_downloadService","_activeTemplateSubject","template$","_activeTemplate$","AddEditValuationTemplateComponent","_valuationTemplateService","templateForm","VALUATION_TEMPLATE_HELP","AddStateComponent","_allStates","_selectableStates","valuationTemplateId","ValuationStatesListComponent","_setGridData","addNewState","_toggleGridEdit","AddAssessorComponent","_allAssessors","_selectableAssessors","assessorsSelected","ValuationAssessorsListComponent","AddSiteClassComponent","_allowedSiteClasses","_selectableSiteClasses","siteClassPrimaryId","ValuationSiteClassListComponent","allRowsSelected","siteClassPrimaries","addNewSiteClass","siteClass","UploadComponent","ValuationTemplateUploadComponent","fileChangedBy","fileChangedByUserName","fileChangeDate","ValuationTemplateDetailComponent","_templateId","editTemplateName","isInDevelopmentInput","ValuationTemplatesComponent","refreshGridData","createNewTemplate","_gridValues","ResponsibleEntityAgGridDataSource","ResponsibleEntityListGridActionCellRendererComponent","responsibleEntityId","ResponsibleEntityDetailsComponent","entityForm","responsibleEntityTypeId","allocationDebitAccount","allocationCreditAccount","allocationReceivableAccount","allocationsExport","accrualsExport","_setAllocationOptionalValidators","ResponsibleEntityListComponent","_getColumns","addResponsibleEntity","_siteGridId","_parcelGridId","_companyGridId","responsibleEntity","embeddedColumns","additionalColumns","ssoSessionKey","SSOLoginComponent","ssoResponse","keepLoading","AttachmentDownloadDiagnosticComponent","loadInfo","bufferedDownload","streamedDownload","simulateDownload","fetchResponse","abortController","AbortController","signal","byteCount","getReader","showDownloadChunkLengths","abort","STATES","redirectTo","deps","resolveFn","Ng2RoutesModule","UIRouterModule","uiRouter","urlService","initial","otherwise","CoreLongRunningProcessService","SearchCategoriesService","groupedSettings","folder","folderArr","_buildChildren","isLeaf","folderIndex","tslib_es6","providedIn","NG1UpgradeProviders","setupProviders","ngx_toastr","account_service","authStorage_service","userInstance_service","feature_flags_service","entityPermission_service","userSettings_service","websocketListener_service","cache_manager_service","contacts_service_upgrade","aceAuthOidcWrapper_service","ParcelActivityService","getParcelActivity","deliverableDueDateHasTime","deliverableDueDate","getUTCHours","getUTCMinutes","getUTCSeconds","getUTCMilliseconds","getParcelActivityForSite","ParcelActivitySummaryComponent","isParcelLevel","getActivityData","_clientServicesChangeSubscription","refreshSubscription","activitySummaryItems","parentEntityID","getTaskIcon","getTaskIconColor","ReportingParcelSiteListComponent","deletedSiteIds","showSiteList","minLength","parentSite","hasReportingParcel","isReportingParcelForParentSite","isPartOfAMasterSite","isSiteLinked","isAnotherParcelReportingForParentSite","addedSiteIds","_loadSites","_getSiteUpdateModel","_setSites","_originalSites","_setParentSite","_originalParentSite","parcelSite","_getSiteRowModel","siteModel","siteRowModel","ComplianceInfoPanelComponent","saveModel","returnSettings","_returnSettingsComponent","_reportingParcelSitesComponent","onReportingParcelSitesInitialized","onReportingParcelSitesChanged","FirstEncounterComponent","_parcelTaxRateSevice","_msgBox","rateIncrease","lastYearDisplayRateIncrease","lastYearRateIncrease","rateInputRef","taxAuthorityDisplayName","twoYearsAgoDisplayRate","twoYearsAgoRate","lastYearDisplayRate","lastYearRate","displayRate","onRateChange","trackBillId","ComplianceParcelModule","LinkedParcelsListGridActionCellRendererComponent","LinkedParcelsAddComponent","as","_availableParcels","_getParcelType","_isLinkedParcel","_isMasterParcel","linked","masterParcel","LinkedParcelsListGridNameCellRendererComponent","LinkedParcelRepository","getLinkageTypes","LinkedParcelsListComponent","_linkedParcelRepository","masterParcelAcctNum","linkedParcels","selectedLinkageType","linkageTypes","linkageTypeId","isBulkDeleteAvailable","toggleMaster","_toggleMaster","getMasterTitle","_getMasterTitle","canToggleMaster","parcelLinks","callingParcelId","addResult","focusElement","newParcels","removeAll","newMasterParcel","masterParcels","subordinateParcels","LINKED_PARCELS_HELP","LinkedParcelsComponent","showParcels","_linkageTypes","linkedParcelCount","LinkedParcelsEditComponent","linkedParcelsChanged","ParcelReportsSitesListGridNameCellRendererComponent","ParcelReportsSitesListComponent","reportingSites","_navigateToSite","ParcelReportsSitesComponent","siteNames","siteNumbers","ParcelIconModule","AccrualsAdjustmentsListComponent","_balanceAdjustmentsService","selectionData","getAcctPeriodName","acctPeriod","getCollectorName","getImpactAmount","impacts","impact","setImpactAmount","impactIdx","writeJournalChanged","writeJournal","_originalAdjustment","_setEditMode","_invalidData","savedAdjustment","firstOpenAccountingPeriod","isPeriodClosed","editModeChange","_isAccrualInvalid","noValue","accrualAmount","noJournalImpacts","_rowDoesNotBalance","impactsSum","AccrualsBalancesListComponent","balances","AccrualsPanelComponent","ParcelCollector","collectorBillInfo","CollectorBillInfo","displayPaymentOptions","collectorPaymentOptionInfo","AddParcelCollectorModalComponent","_changeDetRef","_prepareCollectorList","selectedCollector","isStateCollector","governmentalCollectorsSelected","companyCollectorsSelected","applyToChange","applyTo","billScenario","collectorPaymentOptionName","selectedPaymentOptions","defaultPaymentOption","parcelCollectorPaymentOptions","collectorBill","selectedPaymentOptionIDs","collectorPaymentOptionIDs","addedCollectorIds","TempParcelCollectorModalService","AssessorDetailsComponent","LegalDescriptionModalComponent","descToEdit","PARCEL_INFO_PANEL_HELP","CollectorTaxRateAreaComponent","_taxRateSetupModalLaunchService","shouldDisplay","isAddedCollector","launchParcelCollectorTaxRateModal","currentCalendarYear","sortedYears","parcelYear","collectorBillingScenarioName","affectedParcelCollectors","_applyTaxRateSetupModalResult","parcelCollectorTAs","ParcelInfoPanelViewComponent","parcelViewDto","acctNumHasDoubleSpace","showTaxingDistrict","parcelAssessor","altAcctNums","altAccountNumbers","accountNumberType","accountNumberDesc","optimusLinkInfo","getCollectorSref","collectorStateID","getTRS","ActivityStatusService","ParcelInfoPanelEditComponent","_activityStatusService","_parcelTaxRateService","acctNumTypes","collectorBillingScenarioList","availablePaymentOptionsMap","_mapCollectorBillingScenarioList","_mapParcelAssessmentClasses","nonDeletedParcelCollectors","shouldDisplayAcctNum","deleteAcctNum","altAcctNumAlreadyAdded","acctNumType","accountNumberTypeID","enterAltAcctNumToAdd","acctNumToAdd","acctNumber","cancelAddAcctNum","addAltAcctNum","onPropertyTypeChange","_showWarningIfAnnualData","reloadAnnualGrid","getCollectorPaymentOptionInfo","deleteParcelCollector","addParcelCollector","hasCompanyCollectors","allResults","recordToAdd","taxYearForward","parcelCollectorPaymentOption","linkedParcelInfo","excludeFMV","excludeFmv","parcelLinkageID","subParcelCount","newParcelRowVersion","parcelAssessmentClass","billScenarioInfo","ParcelInfoPanelComponent","_initParcel","_originalParcel","missingAcctNum","_shouldReloadGridAfterSave","_saveParcelToAPI","checkIfEntityMayBeDeactivatedResult","savedParcelDTO","_parcelCollectorTaxAuthorities","savedParcelCollector","saveTaxResult","_siteId","transaction","soldDate","loadingPermissions","assessorDetailsRenderer","originalIds","editIds","ParcelModule","ReportingModule","RoleModule","AutoPopulateInputComponent","isDateInput","setSingleIdpValue","inputValueChanged","buttonHoverOut","idpButtonHovered","_closeMenu","menuHoverOut","idpMenuHovered","menuFocusIn","showIdpMenu","menuFocusOut","keyedSelection","previousIndex","testEl","QuickSearchCriteriaComponent","onEnterPressed","bsDropdown","addFilterButtonClicked","addFilter","sortedIndex","removeFilter","changeResultType","subEntityTypes","filterTypes","foundType","showAnticipated","addFilterToggled","addCriteria","addFilterClosed","togglePrimaryAcctNumOnly","DpPrimaryAcct","toggleExcludeInactive","DpExcludeInactive","toggleAnticipated","DpAnticipated","QuickSearchCriteriaModule","quickSearch_module_hybridAdapterUtility","QuickSearchModule","CompleteFileAppealModalComponent","DocumentProcessingExceptionModalComponent","DuplicateIntakeItemModalComponent","ReassignTaskModalComponent","AppealRecommendationTemplateModalService","AddPaymentsToBatchModalComponent","paymentBatches","paymentBatchIdToAddTo","AddPaymentsToBatchModalService","ActionViewContextMenuService","_retrievalStatusModalService","_appealRecommendationModalService","_addPaymentsToBatchModalService","_actionViewRepository","_invoiceRepository","openProcessNoAppealModal","openProcessAppealWarrantedModal","getContextMenu","avTasksSelected","function","_updateChangedGridRows","_getSortedSelection","limitMessage","_runModalResult","multipleYears","_correctForAsyncError","_processAddPaymentsToBatchResult","_changeDueDates","_processResult","taskIdsNeedingApplications","applicationExists","errorCallback","errorResult","_processResultPromise","processingResult","finalResult","resultObject","_toastProcessResult","_showInvoicePage","handleErrors","_bulkTransferToRIBS","_addObtainPaymentreceiptTasks","_completeObtainPaymentReceiptTasks","_addObtainWorkpapersTasks","keyValues","columnController","columnDefs","noOfParcels","noOfSites","siteJuris","daysToAppealDeadline","n110","contextOption","menuHandler","_ref29","avAction","_warningLimit","singleInstanceId","_errors","clearErrors","modalResultFunction","loadingText","isConcurrencyCheckFailed","_markErrorResults","GENERIC_ERROR_MESSAGE","PERMISSION_ERROR_MESSAGE","CONCURRENCY_ERROR_MESSAGE","authReasons","authorizationReason","persistIndex","markStale","stale","changedFields","consoleErrors","asyncState","resolution","updatedNodes","ActionDetailedComponent","_actionViewContextMenuService","getRowStyle","contextMenuDisabled","contextMenuLoading","contextMenuTooltip","contextMenuItems","showContextMenu","finalFilter","executeDetailedFilter","setPersistenceServiceWithResult","setPersistenceService","originalData","fromRefresh","showErrorsOnly","contextMenuOpen","exportToCsv","resizeColumns","filterResults","_setAgGridValues","ActionViewModule","AppealRecommendationModule","appealRecommendation_repository","task_module_hybridAdapterUtility","TaskModule","task_r11","OverviewSingleGroupingComponent","DashboardModule","angular_gridster2","landing_module_hybridAdapterUtility","LandingModule","ElectronicFilingModule","ValuationTemplatesModule","valuationTemplate_repository","ValuationModule","AssetReturnFilingStatusCellRendererComponent","assetReturnModel","CustomTemplateTypes","AssetAdvancedDetailCheckboxComponent","changedFromClick","encapsulation","AssetInfoCostEditorComponent","unattributedPercent","percentages","costAmounts","percentagesIt","_getAlternativeCostColumnName","onUpdatePercentages","unattributedPercentDecimal","percent","realAmounts","roundedAmount","leftOver","highestValue","lowestValue","altCostMappingModel","alternativeCostMappingModel","ASSET_FIELDS","sourceParam","sourceTemplate","sourceValueGetter","reportedParam","reportedOverride","reportedTemplate","onIsLockedChange","reportedValueGetter","getIsLockedDisplayValue","isRowShown","onOwnershipTypeChange","getOwnershipTypeDescription","Companies","getCompanyNameFromId","isCalculated","reportedOverrideWithBlank","hasOldAssetNumber","labelHelpContentId","descriptorList","descriptorHelpContentId","AcqDate","assetListForm","onAcquisitionDateChanged","onClear","clearAcqDateOverride","formatAlternativeDate","onDisposedDateChanged","clearDisposedDateOverride","labelTemplate","CostAdjustments","isDoubleWidth","formatTransientCost","isSourceCellShown","onTransientReportedCostChange","GlAccount","onGlAccountRemoveOverride","Sites","onSiteRemoveOverride","AssetClass","getAssetClassName","onAssetClassificationRemoveValue","ParcelSelector","getParcelName","LEASED_TO_FIELDS","LEASED_TO_FROM_FIELDS","INVENTORY_FIELDS","AssetInfoFieldsTab","AssetInfoComponent","dPath","arrowPoints","_assetDetailModel","_populateAltToggleFields","_currentAsset","_primaryAssetIsLocked","_configureCurrentAsset","_reloadArrows","enterEditState","exitEditState","costFieldHasSource","assetCostsMatchCalculatedTotals","yesNoTemplate","_customTemplateMap","acqDateTemplate","assetClassTemplate","companiesSelector","costAdjustmentTemplate","glAccountTemplate","parcelSelectorTemplate","sitesTemplate","selectedDescriptorsChanged","_drawArrow","arrowBounds","altAcqDateId","altCostId","calculateCosts","assetListFields","setCostAdjustmentControlsVisible","hasCostAdjustments","_flattenAssetClassifications","_setDescriptors","onAltAcqDateIdChange","_setCostDescriptors","_setStandardDescriptors","_getOwnershipTypes","canSeeHistory","assetInfoReady","_updateCostAdjustmentTypes","_updateCostAdjustments","newAsset","splitNum","padded","newAssetSummary","currentAssetChanged","assetToDelete","assetForm","resetForm","templateValueChange","formatValue","trackByFieldParam","trackByAssetId","viewHistory","clearValue","updateSelectedCompanyId","onIsPerpetualChanged","isCostField","showCostAdjustments","nonNullFound","costAdjustmentControlsVisible","costField","getAlternativeCostOrOverride","formatAlternativeCost","getAlternativeCostDisplay","selectedCost","expectedValue","onTransientAlternateReportedCostChange","getCostAdjustmentDescription","showCostPercentageModal","getCostCompanyAssetDescriptorMappingModel","costAmount","showAssignByPercentageButton","selectedAssetClassification","selectedFieldsTab","_selectedFieldsTab","inventoryFields","_inventoryFields","showInventoryFields","Inventory","overrideAll","_overrideField","leasedToFields","leasedToFromFields","onDoNoPotentiallyDisposeChanged","_removeOverrideAll","primaryAssetIsLocked","descriptorType","listName","addAtIndex","primary","descriptorCount","_fieldFromDescriptor","updateByReportedParam","updateYesNo","picklistField","addAdjustment","assetCostAdjustmentId","stateCostAdjustmentId","originId","arrowDataHolder","originBounds","targetBounds","arrowRightDistance","rightTop","rightBottom","arrowOffset","AssetReturnFilingsComponent","_assetReturns","AssetActivityLogComponent","getRowClass","_getRowClass","postSort","_postSort","_outerDateComparator","_formatChangeField","rowCount","newRowNodesArr","renumbers","assetLogModel","oldRowIndex","masterRowCount","childrenRows","_formattingType","inverted","dateA","dateB","_activityLogData","_initializeRowData","expandedRowData","_expandRowData","lastInGroup","actionDate","changedFrom","changedTo","oldRows","sourceRows","expandedRows","sourceRow","priorValue","CostAdjustmentsComponent","_costAdjustmentControlsVisible","costAdjustmentControlsVisibleChange","_getCostFieldSourceValue","costAdjustmentsChange","costAdjustmentEmpty","adjustmentType","costCompanyAssetDescriptorMappingModel","GLAccountSelectorModule","SiteSelectorModule","AssetLienDateModule","_getGlAccounts","_populateGlAccounts","_glAccountSubscription","_selectGlAccount","glAccountChange","glAccountIdChange","gl","SiteSelectorComponent","_siteName","siteChange","_selectsite","siteIdChange","AssetDetailsModule","AssetModule","assetLienDateDetails_component","AttachmentTypeSelectorComponent","EntityImportModule","messageModal_service","entityImport_service","FactorTableModule","FormModule","GLAccountModule","SupplementalInformationModule","LongRunningProcessModule","DateConvertInterceptor","intercept","handle","Angular1CallbackInterceptor","HandledError","originalError","AuthInterceptor","_location","inMemoryAuthData","setHeaders","CacheBusterInterceptor","InstanceHeaderInterceptor","httpInterceptorProviders","useClass","LoggingService","logError","GlobalErrorHandler","_debouncedErrorHandler","internalErrorHandler","handleError","xhrStatus","loggingService","_translationMap","LinkedSitesListGridActionCellRendererComponent","ComplianceSiteService","getLinkedSiteName","linkedSite","LinkedSitesAddComponent","includeMasterSites","availableSites","_allSites","originalSites","_availableSites","LinkedSitesListGridNameCellRendererComponent","LinkedSitesListComponent","masterSiteId","masterSite","linkedSiteModel","newSites","newMasterSite","masterSites","subordinateSites","LINKED_SITES_HELP","LinkedSitesComponent","linkedSites","showLinkedSites","LinkedSitesReportingType","LinkedSitesReportingComponent","ThisSite","selectedMasterSite","selectedReportingTypeChanged","reportingType","LinkedSitesEditComponent","reportingResult","sitesResult","ComplianceSiteModule","ErrorLogModule","QueryInfoModule","stateJurisdiction_module_hybridAdapterUtility","StateJurisdictionModule","AddAllocationModalComponent","allocationForm","addAllocation","AllocationListGridActionCellRendererComponent","AllocationListAgGridDataSource","ALLOCATION_LIST_HELP","AllocationListComponent","_allocationSelected","_navigateToDetail","AllocationModule","Repositories","allocationDetail_repository","ComplianceModule","formLibraryRepository","Ng1UpgradeModule","useFactory","Utilities","sd_http_service","upgrade_navigation_handler_service","EventAdapterService","authentication_service_upgrade","ContactsRoleAssociationServiceUpgrade","StartupService","AddParcelModalComponent","parcelForm","useSiteAddress","linkMasterParcel","_setDefaultAssessor","_validPropertyTypes","canLinkMaster","addParcel","fax","parcelLinkageId","PARCEL_LIST_PANEL_HELP","PARCEL_BULK_UPDATE_HELP","ParcelBulkUpdateActionComponent","ParcelBulkUpdateComponent","consolidatingTypeAction","isConsolidatedParcelSelected","isNonPPParcelsSelected","reportingParcelAction","consolidatedParcelAction","optInParcelsAction","optInParcels","optOutParcelsAction","optOutParcels","consolidatingType","ParcelListActionCellRendererComponent","PercentChangeRendererComponent","getPercentage","FMVChangeRendererComponent","TotalFMVRendererComponent","EntityService","LATEST","_parcelListDisplayStateSubject","_parcelListTaxYearSubject","_parcelListScrollIndex","currentSiteId","_currentSiteId","setParcelListScrollIndex","changeParcelListDisplayState","changeParcelListTaxYear","ParcelTileComponent","ParcelListPanelComponent","_entityService","_navigateToParcelFromRowSelect","hasSiteWritePermission","hasMasterSite","availableTaxYears","latestTaxYearLabel","parcelListDisplayState$","contentTypeToggle","parcelListTaxYear$","parcelListScrollIndex$","_selectedParcelIndex","excludeInactiveParcels","exclude","parcelList$","inactiveParcelCount","isExcludeInactiveParcelsCheckboxVisible","_gridColumnsInitialized","_columnApi","site$","_setSiteVars","onViewChanged","onTaxYearChanged","_setDataLoading","expandPanel","collapsePanel","minimize","accessSiteParcel","showAddParcel","_firstAssessor","_canRemoveReportingParcel","_removeReportingParcel","_canSetReportingParcel","oldParcel","_canSetConsolidated","_setConsolidatedParcel","_warnOnConsolidatedChange","_canRemoveConsolidated","_removeConsolidatedParcel","_canOptOutConsolidated","_optOutConsolidatedParcel","_canOptInConsolidated","_optInConsolidatedParcel","uniqueComponents","_getUniqueComponents","componentCols","uniqueComponent","foundComponent","canSetReporting","setReporting","canRemoveReporting","removeReporting","canSetConsolidated","setConsolidated","canRemoveConsolidated","removeConsolidated","canOptOutConsolidated","optOutConsolidated","canOptInConsolidated","optInConsolidated","_maxTileCount","SITE_INFO_PANEL_HELP","GoogleMapsSingleMarkerModalComponent","_getIconName","coordinates","siteMapUrl","markerElem","SiteInfoPanelComponent","_siteMapService","fAccrualsExclude","siteForm","imageUrls","hasStateRoles","entityEditPermissionCheck","siteNumberRequired","_loadActivityStatuses","_loadSiteClasses","_loadStates","goToMove","goToCopy","goToAssessor","allowUserToEditEntity","saveSiteToAPI","siteToSave","savedSite","saveSite","openInvoiceTaskCount","launchSiteMap","getSiteClassName","foundSiteClass","permissionsLoaded","onSoldDateChanged","getState","goToValuationTool","valuationToolUrl","_processAttachmentDialogResult","AssetListPanelComponent","ValuationPanelComponent","incomeStatementSelected","showRentRoll","showIncomeStatement","rentRollSelected","ResponsibleEntityPanelComponent","onLoadingChanged","ResponsibleEntityModule","responsbileEntity_repository","SiteModule","EntityModule","LayoutModule","InstanceModule","ConsultingModule","CsrCommandCenterModule","csrCommandCenter_repository","CheckboxListComponent","isAllChecked","checkChanged","TaxRateModule","TaxRatesPanelModule","TaxingDistrictModule","StateAssessorSharedModule","AssessorModule","CollectorModule","AssessorCollectorModule","smartSearch_module_hybridAdapterUtility","SmartSearchModule","appealApplication_module_hybridAdapterUtility","AppealApplicationModule","appeal_application_service","StateModule","LoginModule","login_service","termsAndConditionsModal_component","SupportInstanceModule","UserGroupPermissions","BlobErrorHttpInterceptor","errmsg","statusText","throwError","DatabaseModule","CompanyPermissionUserPanelComponent","PermissionModule","UserGroupInfoComponent","_initForm","canUncheckIsConsultantGroup","_initialValues","onSubmit","defaultPermission","consultingEngagementsCount","showDocumentsGroupCheckbox","showSupportGroupCheckbox","_getDefaultPermission","isConsultantGroupTitle","UserGroupModule","WebComponentWrapperModule","PaymentBatchPaymentsGridActionCellRendererComponent","PaymentBatchPaymentsGridPaymentErrorsCellRendererComponent","TRANSMITTAL_PACKAGE_COLUMN","transmittalPackageNum","PaymentBatchPaymentsAgGridDataSource","_getSearchModel","PAYMENT_BATCH_DETAILS_HELP","PaymentBatchPaymentsGridComponent","onModelUpdated","_noColumnsSelected","paymentRow","paymentAmountTotal","installmentName","getErrors","deleteRow","PAYMENT_BATCH_PAYMENTS_COLUMNS","billAmountIdx","isBulkDeleteVisible","canAddDeletePayments","canAdvanceTask","_paymentErrors","_deletePaymentBatchPaymentsRow","gridDataChanged","visibleColumns","PaymentBatchPackagesComponent","responsible","bcc","awaitingPackageCreation","isSeriesCompleted","_getPackages","ele","getPackageNum","pmtPackage","navigateToBillPaymentPackages","launchReviewModal","isDownloadDisabled","isDownloading","feedType","userHasElevatedPermission","dataHubStatus","ShippingMethodsModalComponent","shippingMethodPackages","getIt","PaymentBatchOutputComponent","feeds","showShippingMethods","hasCheckFeed","launchShippingMethodsModal","PaymentBatchSettingsComponent","_setCollectorOverridesUI","canModifyMaxItemsPerCheck","allPayees","individualPayees","isAppliedToAll","collectorOverrideScope","_originalSettings","_originalCollectorOverridesUI","collectorOverridesUI","editChange","revertOverride","payee","maxItemsPerCheckCollector","maxItemsPerCheckOverride","MAX_PAYMENT_ITEMS","collectorOverrides","PaymentBatchAddPaymentAgGridDataSource","PaymentBatchAddPaymentsModalComponent","addedCount","PAYMENT_BATCH_ADD_PAYMENT_COLUMNS","CheckImportModalComponent","returnFile","FinalizeCheckImportPaymentGridComponent","checkNo","checkImportPayments","matchedPayments","matchedRow","justMatched","FinalizeCheckImportChecksGridComponent","checkImportChecks","checkAmount","FinalizeCheckImportModalComponent","checks","checkImportModel","excludeMatchedItems","disableFinalize","filterItems","finalizeCheckImportPaymentGrid","finalizeCheckImportChecksGrid","finalize","discard","PaymentBatchSummaryComponent","_originalPaymentBatch","canModifyDescription","canModifyFundedAmount","launchAddPaymentsModal","importChecks","finalizeCheckImport","paymentBatch_module_hybridAdapterUtility","PaymentBatchModule","paymentBatch_repository","AppModule","upgrade","ngDoBootstrap","$destroy","bootstrap","strictDi","setupQuill","Block","Quill","tagName","HTTP_INTERCEPTORS","BsDropdownModule","CarouselModule","ProgressbarModule","AccordionModule","TabsModule","ModalModule","ButtonsModule","PopoverModule","TooltipModule","ToastrModule","positionClass","easeTime","onActivateTick","DragulaModule","QuillModule","SortableModule","UIRouterUpgradeModule","BrowserAnimationsModule","BrowserModule","HttpClientModule","UpgradeModule","WeissmanEnvironmentConfig","urlMatch","LocalStorageKeys","main_windowRef","refreshRegexResult","locationSet","weissmanRefreshState","newHash","history","replaceState","parsedQueryString","queryStringArguments","tokens","raw","domainArgument","newQueryString","pathname","deferIntercept","platform_browser","bootstrapModule","platformRef","lib_esm","startUIRouter","webpackContext"],"sourceRoot":"webpack:///","sources":["./src/app/Account/Authentication.Service.js","./src/app/Account/New.Password.Directive.js","./src/app/Assessor-Collector/Assessor/Assessor.Service.js","./src/app/Assessor-Collector/Collector/Collector.Service.js","./src/app/Attachment/Viewer/File.Viewer.Directive.js","./src/app/Common/Activity/Activity.Panel.Controller.js","./src/app/Common/Activity/Activity.Status.Service.js","./src/app/Common/Activity/Activity.Summary.Table.Directive.js","./src/app/Common/Activity/Deadline-Footer/Activity.Deadline.Footer.Directive.js","./src/app/Common/Activity/SD.Activity.Directive.js","./src/app/Common/Activity/SD.Activity.Table.Directive.js","./src/app/Common/Activity/SD.Highcharts.Column.Directive.js","./src/app/Common/Filters/contains.filter.js","./src/app/Common/Logging/sd.Logger.Factory.js","./src/app/Common/Modal/sd.Modal.Service.js","./src/app/Common/Permissions/SD.Restrict.Directive.js","./src/app/Common/Quick-Search/Quick.Search.Results.Directive.js","./src/app/Common/Routing/SD.Http.Service.js","./src/app/Common/Routing/upgrade-navigation.service.js","./src/app/Common/Services/Property.Type.Service.js","./src/app/Common/Services/event-adapter.service.js","./src/app/Common/States/State-Dropdown/SD.State.Dropdown.Directive.js","./src/app/Common/Trace/Trace.Service.js","./src/app/Common/Validators/Does.Not.Match.Directive.js","./src/app/Common/Validators/Must.Match.Directive.js","./src/app/Contact/ContactRoleAssociation.Service.js","./src/app/Contact/Contacts.Service.js","./src/app/Contact/List/Contact.List.Controller.js","./src/app/Documents/Document.Service.js","./src/app/Entity/Company/Picker/Company.Picker.Directive.js","./src/app/Entity/Parcel/Info/Activity/Parcel.Activity.Modal.Controller.js","./src/app/Entity/Parcel/Info/Activity/parcel-activity-modal.service.js","./src/app/Entity/Parcel/Info/Parcel.LegalDescription.Modal.Controller.js","./src/app/Entity/Redirect.Controller.js","./src/app/Entity/Site/Site.Contacts.Panel.Controller.js","./src/app/Hybrid/startup.service.js","./src/app/Hybrid/weissNg1Wrap.js","./src/app/Layout/Navbar.Top.Service.js","./src/app/Layout/layout.service.js","./src/app/Permission/Application/Panel.Controller.js","./src/app/Permission/Application/Panel.Directive.js","./src/app/Permission/Company/Panel/Panel.Controller.js","./src/app/Permission/Company/Panel/Panel.Directive.js","./src/app/Permission/Company/Permission.Company.Add.Controller.js","./src/app/Permission/Company/Site/Site.List.Controller.js","./src/app/Permission/Company/Site/Site.List.Service.js","./src/app/Permission/Instance/Panel.Controller.js","./src/app/Permission/Instance/Panel.Directive.js","./src/app/Permission/User-Groups/NameInfo.Controller.js","./src/app/Permission/User-Groups/NameInfo.Directive.js","./src/app/Permission/User-Groups/Panel.Controller.js","./src/app/Permission/User-Groups/Panel.Directive.js","./src/app/Processing/Documents/Document.Processing.Controller.js","./src/app/Processing/Documents/Document.Processing.Quick.Search.Directive.js","./src/app/Processing/Documents/Modals/Document.Processing.Exception.Modal.Controller.js","./src/app/Processing/Documents/Modals/Duplicate.Intake.Item.Modal.Controller.js","./src/app/Processing/Documents/Popups/File.Preview.Controller.js","./src/app/Processing/Processing.Service.js","./src/app/Processing/complete-file-appeal.modal.controller.js","./src/app/Search/Advanced/Column-Picker/Browse.Columns.Modal.Controller.js","./src/app/Search/Advanced/Column-Picker/Column.Checkboxes.Directive.js","./src/app/Search/Advanced/Column-Picker/Column.Picker.Directive.js","./src/app/Search/Quick/Criteria/Quick.Criteria.Controller.js","./src/app/Search/Quick/Criteria/Quick.Criteria.Directive.js","./src/app/Search/Quick/Quick.Controller.js","./src/app/Search/Quick/Quick.Directive.js","./src/app/Search/Quick/Results/Quick.Result.Company.Directive.js","./src/app/Search/Quick/Results/Quick.Result.Extra.Directive.js","./src/app/Search/Quick/Results/Quick.Result.Infinite.Controller.js","./src/app/Search/Quick/Results/Quick.Result.Infinite.Directive.js","./src/app/Search/Quick/Results/Quick.Result.Parcel.Directive.js","./src/app/Search/Quick/Results/Quick.Result.Site.Directive.js","./src/app/Task/ActionView/Action.List.Output.Directive.js","./src/app/Task/ActionView/Action.View.Overview.Directive.js","./src/app/Task/ActionView/Action.View.Persistence.Service.js","./src/app/Task/ActionView/Action.View.Service.js","./src/app/Task/ActionView/Action.View.Sorting.Dropdowns.Directive.js","./src/app/Task/ActionView/Filters.Outputs.Controller.js","./src/app/Task/ActionView/Filters/Custom.Output.Modal.Controller.js","./src/app/Task/ActionView/Filters/Date.Time.Panel.Directive.js","./src/app/Task/ActionView/Filters/Multi.User.Team.Picker.Directive.js","./src/app/Task/ActionView/Filters/Plain.English.Service.js","./src/app/Task/ActionView/Filters/Task.Assignment.Ready.Panel.Directive.js","./src/app/Task/ActionView/Output.Defaults.Controller.js","./src/app/Task/ActionView/Tables/Overview.Table.Directive.js","./src/app/Task/Task.Series.Arrows.Directive.js","./src/app/Task/Task.Series.Directive.js","./src/app/Task/Task.Service.js","./src/app/Task/Tasks.Modal.Controller.js","./src/app/Task/error-notification.modal.controller.js","./src/app/Task/reassign.task.modal.controller.js","./src/app/Team/Assignment/Teams.Assignment.Panel.Directive.js","./src/app/Team/Team.Picker.Directive.js","./src/app/Team/User-Picker/User.Picker.Directive.js","./src/app/Team/User-Team-Picker/User.Team.Picker.Directive.js","./src/app/UI-Lib/Directives/Disable.Animation.Directive.js","./src/app/UI-Lib/Directives/SD.Enter.Directive.js","./src/app/UI-Lib/Directives/Select.On.Focus.Directive.js","./src/app/UI-Lib/Directives/To-Percent/Percent.Directive.js","./src/app/UI-Lib/Directives/sd.Disable.Link.Directive.js","./src/app/UI-Lib/Loading-Spinner/Loading.Spinner.Directive.Old.js","./src/app/UI-Lib/Loading-Spinner/Loading.Spinner.Directive.js","./src/app/UI-Lib/Message-Box/MessageBox.Modal.Controller.js","./src/app/UI-Lib/Message-Box/MessageBox.Service.js","./src/app/UI-Lib/Utilities/Name.Prefix.Service.js","./src/app/UI-Lib/Utilities/String.Format.js","./src/app/UI-Lib/Utilities/Utilities.Service.js","./src/app/UI-Lib/Utilities/build-timestamp.service.js","./src/app/UI-Lib/Weissman-Panel/Panel.Chevron.Directive.js","./src/app/User-Group/User.Group.Modal.Controller.js","./src/app/User-Group/User.Group.Service.js","./src/app/User/User.Setup.Controller.js","./src/app/User/User.Setup.Directive.js","./src/app/build-timestamp.js","./src/app/constants.js","./src/app/routes.js","./src/app/vendor/Angular.Resize.Directive.js","./src/app/vendor/contextMenu.js","./src/app/vendor/jQuery.NumericInput.js","./src/app/Account/Login/login.service.ts","./src/app/Account/Login/termsAndConditionsModal.component.ts","./src/app/Account/authentication-service.upgrade.ts","./src/app/Account/userSettings.service.ts","./src/app/Accruals/accruals.page.model.ts","./src/app/Accruals/accruals.page.service.ts","./src/app/Appeal-Application/appeal.application.service.ts","./src/app/Appeal-Recommendation/appealRecommendation.repository.ts","./src/app/Budget/agGridForecastBudgetYearCellEditor.component.ts","./src/app/Budget/agGridForecastBudgetYearCellRender.component.ts","./src/app/Budget/forecasting.budgeting.model.ts","./src/app/Budget/forecasting.budgeting.service.ts","./src/app/Reporting/ReportProcessIntegrationRepository.ts","./src/app/Search/AdvancedSearchIntegrationRepository.ts","./src/app/Task/ActionView/ActionViewIntegrationRepository.ts","./src/app/Busy-Indicator/Config/longRunningProcessIndicatorConfig.service.ts","./src/app/Busy-Indicator/Models/busyIndicatorConfig.ts","./src/app/Busy-Indicator/Models/progressIndicator.model.ts","./src/app/Busy-Indicator/SnackBar/snackBar.service.ts","./src/app/Busy-Indicator/busyIndicator.component.html","./src/app/Busy-Indicator/busyIndicator.component.ts","./src/app/Busy-Indicator/busyIndicator.module.ts","./src/app/Busy-Indicator/busyIndicatorRef.ts","./src/app/Busy-Indicator/busyIndicator.service.ts","./src/app/Busy-Indicator/busyIndicatorMessageId.service.ts","./src/app/Busy-Indicator/busyIndicatorMessage.ts","./src/app/Busy-Indicator/busyIndicatorMessageManager.ts","./src/app/Client-Services/Command-Center/csrCommandCenter.repository.ts","./src/app/Common/AgGrid/agGridLoadingOverlay.component.ts","./src/app/Common/Data/base.repository.ts","./src/app/Common/Data/cached.repository.ts","./src/app/Common/Data/dataCache.ts","./src/app/Common/Download/MultiPartResponseService.ts","./src/app/Common/Download/downloadFileService.ts","./src/app/Common/FeatureFlags/feature-flags-service.ts","./src/app/Common/Permissions/entityPermission.service.ts","./src/app/Common/Permissions/restrict.service.ts","./src/app/Common/Routing/cache-manager.service.ts","./src/app/Common/Routing/route.service.ts","./src/app/Common/Routing/sd-http.service.ts","./src/app/Common/Routing/upgrade-navigation-handler.service.ts","./src/app/Common/Services/easyAccess.service.ts","./src/app/Common/Settings/settings.service.ts","./src/app/Compliance/AgGrid/CellRenderers/agGridCheckboxCellRender.component.ts","./src/app/Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component.ts","./src/app/Compliance/AgGrid/Filters/Date/dateFilterPickerInstance.component.ts","./src/app/Compliance/AgGrid/Filters/Date/agGridDateFilter.component.html","./src/app/Compliance/AgGrid/Filters/Date/agGridDateFilter.component.ts","./src/app/Compliance/AgGrid/Filters/Number/agGridNumberFilter.component.html","./src/app/Compliance/AgGrid/Filters/Number/agGridNumberFilter.component.ts","./src/app/Compliance/AgGrid/Filters/Text/agGridTextFilter.component.html","./src/app/Compliance/AgGrid/Filters/Text/agGridTextFilter.component.ts","./src/app/Compliance/AgGrid/Filters/agGridFilterBase.ts","./src/app/Compliance/AgGrid/FloatingFilters/agGridFloatingFilterBase.ts","./src/app/Compliance/AgGrid/FloatingFilters/agGridNumberFloatingFilter.component.ts","./src/app/Compliance/AgGrid/FloatingFilters/agGridTextFloatingFilter.component.ts","./src/app/Compliance/AgGrid/GridHelper.ts","./src/app/Compliance/AgGrid/agGridColumns.ts","./src/app/Compliance/AgGrid/agGridFilterParams.ts","./src/app/Compliance/AgGrid/FloatingFilters/agGridDateFloatingFilter.component.ts","./src/app/Compliance/AgGrid/ColumnHeader/agGridHeaderLegendTooltip.component.ts","./src/app/Compliance/AgGrid/ColumnHeader/agGridHeaderCellRenderer.component.ts","./src/app/Compliance/AgGrid/Filters/YesNo/agGridYesNoFilter.component.ts","./src/app/Compliance/AgGrid/agGridOptionsBuilder.ts","./src/app/Compliance/AgGrid/agGridPersistence.service.ts","./src/app/Compliance/AgGrid/agGridDataSourceBase.ts","./src/app/Compliance/AgGrid/CellEditors/agGridDatePickerCellEditor.component.ts","./src/app/Compliance/AgGrid/CellEditors/agGridDropdownCellEditor.component.ts","./src/app/Compliance/AgGrid/CellEditors/agGridNumberCellEditor.component.ts","./src/app/Compliance/AgGrid/CellEditors/agGridCurrencyCellEditor.component.ts","./src/app/Compliance/AgGrid/CellEditors/agGridTextCellEditor.component.ts","./src/app/Compliance/Asset/Asset-Lien-Date-Details/assetLienDateDetails.component.html","./src/app/Compliance/Asset/Asset-Lien-Date-Details/assetLienDateDetails.component.ts","./src/app/Compliance/Asset/Asset-Lien-Date/assetLienDate.component.help.ts","./src/app/Compliance/Asset/Asset-Lien-Date/assetLienDate.component.html","./src/app/Compliance/Asset/Asset-Lien-Date/assetLienDate.component.ts","./src/app/Compliance/Asset/Models/enums.ts","./src/app/Compliance/Entity-Import/Upload/upload.component.html","./src/app/Compliance/Entity-Import/Upload/upload.component.ts","./src/app/Compliance/Entity-Import/entityImport.service.ts","./src/app/Compliance/Repositories/allocationDetail.repository.ts","./src/app/Compliance/Repositories/asset.repository.ts","./src/app/Compliance/Repositories/assetClassification.repository.ts","./src/app/Compliance/Repositories/filingBatch.repository.ts","./src/app/Compliance/Repositories/form.repository.ts","./src/app/Compliance/Repositories/formLibraryRepository.ts","./src/app/Compliance/Repositories/gridLayoutSpecificationRepository.ts","./src/app/Compliance/Repositories/incomeStatementCategory.repository.ts","./src/app/Compliance/Repositories/costAdjustment.repository.ts","./src/app/Compliance/Repositories/electronicFiling.repository.ts","./src/app/Compliance/Repositories/entityImport.repository.ts","./src/app/Compliance/Repositories/import-specification-repository.service.ts","./src/app/Compliance/Repositories/factorTable.repository.ts","./src/app/Compliance/Repositories/glAccount.repository.ts","./src/app/Compliance/Repositories/returnAsset.repository.ts","./src/app/Compliance/Repositories/returnForm.repository.ts","./src/app/Compliance/Repositories/returnFormRevision.repository.ts","./src/app/Compliance/Repositories/returnFormRevisionReport.repository.ts","./src/app/Compliance/Repositories/returnSettings.repository.ts","./src/app/Compliance/Repositories/supplementalInformation.repository.ts","./src/app/Compliance/Repositories/longRunningProcess.repository.ts","./src/app/Compliance/Repositories/companyAssetDescriptor.repository.ts","./src/app/Compliance/Repositories/company.repository.ts","./src/app/Compliance/Repositories/formSetupRepository.ts","./src/app/Compliance/Repositories/assessorCommandCenter.repository.ts","./src/app/Compliance/Repositories/returnReport.repository.ts","./src/app/Compliance/Repositories/allocation.repository.ts","./src/app/Compliance/Repositories/reportingParcel.repository.ts","./src/app/Compliance/Repositories/return.repository.ts","./src/app/Compliance/WeissmanModalService.ts","./src/app/Common/SignalR/signal-r-message-broker-client.service.ts","./src/app/Compliance/websocketListener.service.ts","./src/app/Contact/contacts.service.upgrade.ts","./src/app/Core-Repositories/comments.repository.ts","./src/app/Core-Repositories/account.repository.ts","./src/app/Core-Repositories/actionView.repository.ts","./src/app/Core-Repositories/activity.repository.ts","./src/app/Core-Repositories/advancedSearch.Repository.ts","./src/app/Appeal-Application/appealApplication.repository.ts","./src/app/Core-Repositories/assessorCollector.repository.ts","./src/app/Core-Repositories/consultingEngagement.repository.ts","./src/app/Core-Repositories/contacts.repository.ts","./src/app/Core-Repositories/invoice.repository.ts","./src/app/Core-Repositories/parcel.repository.ts","./src/app/Core-Repositories/site.repository.ts","./src/app/Core-Repositories/siteClass.repository.ts","./src/app/Core-Repositories/state.repository.ts","./src/app/Core-Repositories/task.repository.ts","./src/app/Core-Repositories/user.repository.ts","./src/app/Core-Repositories/paymentBatch.repository.ts","./src/app/Core-Repositories/transmittal.repository.ts","./src/app/Core-Repositories/valuationTemplate.repository.ts","./src/app/Diagnostics/Error-Log/errorLog.repository.ts","./src/app/Diagnostics/Query-Info/queryInfo.repository.ts","./src/app/Hybrid/hybrid-adapter.utility.ts","./src/app/IAM/aceAuthOidcWrapper.service.ts","./src/app/Layout/appStateService.ts","./src/app/Responsible-Entity/responsbileEntity.repository.ts","./src/app/Tax-Rate/Command-Center/tax.rate.command.center.service.ts","./src/app/Tax-Rate/tax.rate.grid.service.ts","./src/app/UI-Lib/ACE/Button/button.component.html","./src/app/UI-Lib/ACE/Button/button.component.ts","./src/app/UI-Lib/ACE/Icon/iconLib.ts","./src/app/UI-Lib/ACE/Icon/icon.component.html","./src/app/UI-Lib/ACE/Icon/icon.component.ts","./src/app/UI-Lib/Directives/Click-Outside-Directive/clickOutside.directive.ts","./src/app/UI-Lib/Directives/Input-Mask/inputMask.directive.ts","./src/app/UI-Lib/Directives/Numbers-Only/numbersOnly.directive.ts","./src/app/UI-Lib/FilePicker/filePicker.component.html","./src/app/UI-Lib/FilePicker/filePicker.component.ts","./src/app/UI-Lib/Help-Tooltip/help-tooltip.component.ts","./src/app/UI-Lib/Help-Tooltip/help-tooltip.directive.ts","./src/app/UI-Lib/Help-Tooltip/help.module.ts","./src/app/app.help.ts","./src/app/UI-Lib/Help-Tooltip/help.service.ts","./src/app/UI-Lib/Message-Box/message-modal.component.html","./src/app/UI-Lib/Message-Box/message-modal.component.ts","./src/app/UI-Lib/Message-Box/messageModal.service.ts","./src/app/UI-Lib/Message-Box/messagebox.service.upgrade.ts","./src/app/UI-Lib/Directives/Draggable/draggable.directive.ts","./src/app/UI-Lib/ACE/Loader/loader.component.html","./src/app/UI-Lib/ACE/Loader/loader.component.ts","./src/app/UI-Lib/Modal-Wrapper/modalWrapper.component.html","./src/app/UI-Lib/Modal-Wrapper/modalWrapper.component.ts","./src/app/UI-Lib/Pipes/Absolute-Url/absolute.url.pipe.ts","./src/app/UI-Lib/Pipes/Boolean/boolean-pipe.ts","./src/app/UI-Lib/Pipes/Date-Format/date-formatting.pipe.ts","./src/app/UI-Lib/Pipes/Filter/filter-pipe.ts","./src/app/UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe.ts","./src/app/UI-Lib/Pipes/Order-By/orderBy.pipe.ts","./src/app/UI-Lib/Pipes/Split-List/splitList.pipe.ts","./src/app/UI-Lib/Pipes/Time-Ago/timeAgo.pipe.ts","./src/app/UI-Lib/Pipes/Time-Span/timeSpan.pipe.ts","./src/app/UI-Lib/Select/select.component.html","./src/app/UI-Lib/Select/select.component.ts","./src/app/UI-Lib/Select/Dropdown/selectDropdown.component.html","./src/app/UI-Lib/Select/Dropdown/selectDropdown.component.ts","./src/app/UI-Lib/Select/select.service.ts","./src/app/UI-Lib/Utilities/Utilities.Service.upgrade.ts","./src/app/UI-Lib/Utilities/build-timestamp.service.upgrade.ts","./src/app/UI-Lib/Utilities/Validators.Service.ts","./src/app/UI-Lib/Utilities/scriptLoader.service.ts","./src/app/UI-Lib/Utilities/timer.service.ts","./src/app/UI-Lib/Weiss-Datepicker/weissman-datetime.component.html","./src/app/UI-Lib/Weiss-Datepicker/weissman-datetime.component.ts","./src/app/User/account.service.ts","./src/app/User/authStorage.service.ts","./src/app/User/userInstance.service.ts","./src/app/Valuation/Income-Statement/incomeStatement.repository.ts","./src/app/Valuation/Rent-Roll/rentRoll.repository.ts","./src/app/constants.new.ts","./src/app/Hybrid/externalImports.js","./src/app/Hybrid/ngjsStart.ts","./src/app/Contact/View/Contact.View.Modal.Controller.js","./src/app/Entity/Parcel/Parcel.Controller.js","./src/app/Entity/Site/Site.Controller.js","./src/app/Reporting/Manager/report-type.ts","./src/app/Task/ActionView/action-view-service.upgrade.ts","./src/app/Reporting/Manager/report.manager.model.ts","./src/app/Reporting/Manager/report.manager.service.ts","./src/app/UI-Lib/ACE/Select/Select-Dropdown/dropdown.component.html","./src/app/UI-Lib/ACE/Select/Select-Dropdown/dropdown.component.ts","./src/app/UI-Lib/ACE/Select/select.service.ts","./src/app/UI-Lib/ACE/Select/select.component.html","./src/app/UI-Lib/ACE/Select/select.component.ts","./src/app/Navigation/User-Save/userSavePage.model.ts","./src/app/Navigation/User-Save/Modals/Category/navChangeCategory.component.html","./src/app/Navigation/User-Save/Modals/Category/reportCategory.component.ts","./src/app/Navigation/User-Save/Modals/Rename/reportRename.component.html","./src/app/Navigation/User-Save/Modals/Rename/reportRename.component.ts","./src/app/Navigation/Saved-Report/savedReport.service.ts","./src/app/Search/Advanced/advancedSearchPersistence.service.ts","./src/app/Search/searchOperators.service.ts","./src/app/Search/Advanced/smartSearch.service.ts","./src/app/Navigation/User-Save/Modals/Category/searchCategory.component.ts","./src/app/Navigation/User-Save/Modals/Default-Display/searchDefaultDisplay.component.ts","./src/app/Navigation/User-Save/Modals/Rename/searchRename.component.html","./src/app/Navigation/User-Save/Modals/Default-Display/searchDefaultDisplay.component.html","./src/app/Navigation/User-Save/Modals/Rename/searchRename.component.ts","./src/app/Navigation/Saved-Smart/savedSmart.service.ts","./src/app/Task/ActionView/Action.View.Persistence.Service.upgrade.ts","./src/app/Navigation/User-Save/userSave.service.ts","./src/app/Common/Amplitude/productAnalytics.service.ts","./src/app/Navigation/User-Save/Modals/Category/actionViewCategory.component.ts","./src/app/Navigation/User-Save/Modals/Default-Display/actionViewDefaultDisplay.component.ts","./src/app/Navigation/User-Save/Modals/Rename/actionViewRename.component.html","./src/app/Navigation/User-Save/Modals/Default-Display/actionViewDefaultDisplay.component.html","./src/app/Navigation/User-Save/Modals/Rename/actionViewRename.component.ts","./src/app/Navigation/Saved-AV/savedActionView.service.ts","./src/app/Task/ActionView/Save.Action.View.Modal.Controller.js","./src/app/UI-Lib/Directives/Drag-And-Drop-List/dragAndDropList.service.ts","./src/app/UI-Lib/Directives/Drag-And-Drop-List/dragAndDropList.module.ts","./src/app/UI-Lib/Directives/directives.module.ts","./src/app/UI-Lib/Pipes/shared-pipes.module.ts","./src/app/UI-Lib/ACE/Icon/icon.module.ts","./src/app/UI-Lib/ACE/Select/select.module.ts","./src/app/UI-Lib/ACE/Simple-Table/Simple-Table-Cell/simpleTableCell.component.ts","./src/app/UI-Lib/ACE/Simple-Table/simpleTable.component.html","./src/app/UI-Lib/ACE/Simple-Table/Simple-Table-Cell/simpleTableCell.component.html","./src/app/UI-Lib/ACE/Simple-Table/simpleTable.component.ts","./src/app/UI-Lib/ACE/Simple-Table/simpleTable.module.ts","./src/app/UI-Lib/ACE/Tab-Set/tabSet.module.ts","./src/app/UI-Lib/ACE/ace.module.ts","./src/app/UI-Lib/ACE/Badge/badge.component.html","./src/app/UI-Lib/ACE/Badge/badge.component.ts","./src/app/UI-Lib/Currency/currency.module.ts","./src/app/UI-Lib/Loading-Spinner/loadingSpinner.module.ts","./src/app/UI-Lib/Select/select.module.ts","./src/app/UI-Lib/Modal-Wrapper/modalWrapper.module.ts","./src/app/UI-Lib/Tri-State-Checkbox/triStateCheckbox.module.ts","./src/app/UI-Lib/Typeahead/typeahead.component.html","./src/app/UI-Lib/Typeahead/typeahead.component.ts","./src/app/UI-Lib/Typeahead/typeahead.service.ts","./src/app/UI-Lib/Typeahead/typeahead.module.ts","./src/app/UI-Lib/Directives/Anchor-Route/anchorRoute.directive.ts","./src/app/UI-Lib/Bread-Crumb/breadCrumbs.component.html","./src/app/UI-Lib/Bread-Crumb/breadCrumbs.component.ts","./src/app/UI-Lib/Weissman-Panel/weissmanPanel.component.html","./src/app/UI-Lib/Weissman-Panel/weissmanPanel.component.ts","./src/app/UI-Lib/UILib.module.ts","./src/app/Compliance/AgGrid/agGridExtensions.module.ts","./src/app/Search/Advanced/Column-Picker/Browse-Column-Modal/browseColumnModal.component.html","./src/app/Search/Advanced/Column-Picker/Browse-Column-Modal/browseColumnModal.component.ts","./src/app/Search/Advanced/Column-Picker/columnPicker.component.ts","./src/app/Search/Advanced/Column-Picker/columnPicker.component.html","./src/app/Search/Advanced/Column-Picker/columnPicker.module.ts","./src/app/Comments/comments.service.ts","./src/app/Entity/Instance/instance.repository.ts","./src/app/UI-Lib/Loading-Spinner/loadingSpinner.component.ts","./src/app/UI-Lib/Directives/Line-Limit/lineLimit.directive.ts","./src/app/Comments/Modal/commentListItem.component.ts","./src/app/Comments/Modal/comments.component.html","./src/app/Comments/Modal/comments.component.ts","./src/app/Comments/Add-Comment-Modal/addComment.component.html","./src/app/Comments/Add-Comment-Modal/addComment.component.ts","./src/app/Comments/commentsModal.service.ts","./src/app/Comments/Entity-Comments-Button/entityCommentsButton.component.ts","./src/app/Comments/Entity-Comments-Button/entityCommentsButton.component.html","./src/app/Comments/comments.module.ts","./src/app/Assessor-Collector/Tax-Rates/agGridTaxAuthoritiesCellRenderer.component.ts","./src/app/Tax-Rate/Command-Center/agGridCommentsCellRenderer.component.ts","./src/app/Attachment/Modal/attachmentModal.component.help.ts","./src/app/Common/Entity/CurrentEntityService.ts","./src/app/Documents/document.service.upgrade.ts","./src/app/Attachment/attachments.constants.ts","./src/app/Attachment/attachment.service.ts","./src/app/Search/Quick/Criteria/quickFilters.service.ts","./src/app/Search/searchFilters.service.ts","./src/app/Core-Repositories/search.repository.ts","./src/app/Search/search.service.ts","./src/app/Core-Repositories/navigation.repository.ts","./src/app/Layout/navigation.service.ts","./src/app/Common/Popup/pubsub.service.ts","./src/app/Common/Popup/popup.service.ts","./src/app/Attachment/Form/attachmentForm.component.html","./src/app/Attachment/Form/attachmentForm.component.ts","./src/app/Common/PDFViewer/LoadPdfIframeService.ts","./src/app/Common/PDFViewer/pdf-viewer.component.ts","./src/app/Attachment/Viewer/file.viewer.component.ts","./src/app/Attachment/Modal/attachmentModal.component.html","./src/app/Attachment/Modal/attachmentModal.component.ts","./src/app/Attachment/Entity/entity-attachments.component.ts","./src/app/Tax-Rate/Command-Center/agGridAttachmentsCellRenderer.component.ts","./src/app/Attachment/Entity/entity-attachments.component.html","./src/app/Tax-Rate/agGridQcByCellRenderer.component.ts","./src/app/UI-Lib/Switch/switch.component.ts","./src/app/UI-Lib/Switch/switch.component.html","./src/app/Budget/agGridSwitchCellRenderer.component.ts","./src/app/Assessor-Collector/Taxing-District/Taxing-District-List/agGridActionCellRenderer.component.ts","./src/app/User-Group/User-Group-List/agGridActionCellRendererComponent.ts","./src/app/Permission/Company/Panel/agGridActionCellRenderer.component.ts","./src/app/Task/ActionView/Action-View-Output-Defaults/agGridActionCellRenderer.component.ts","./src/app/Compliance/AgGrid/MultiSelectTracker/agGridMultiSelectTracker.ts","./src/app/Compliance/AgGrid/MultiSelectTracker/agGridMultiSelectHeaderRenderer.component.ts","./src/app/Compliance/AgGrid/MultiSelectTracker/agGridMultiSelectCellRenderer.component.ts","./src/app/Permission/Instance/agGridActionCellRenderer.component.ts","./src/app/Permission/Application/agGridActionCellRenderer.component.ts","./src/app/Compliance/AgGrid/AgGridWrapper/wsAgGridWrapper.module.ts","./src/app/Entity/Parcel/Icon/parcelIcon.component.html","./src/app/Entity/Parcel/Icon/parcelIcon.component.ts","./src/app/Entity/Parcel/Parcel-Type-Cell-Renderer/parcelTypeCellRenderer.component.ts","./src/app/Common/Activity/Parcel-Filter/Activity-Status-Cell-Renderer/activityStatusCellRenderer.component.ts","./src/app/Compliance/AgGrid/ToolPanel/agGridToolPanel.component.help.ts","./src/app/Compliance/AgGrid/ToolPanel/LayoutSpecification/Details/agGridLayoutSpecificationDetails.component.html","./src/app/Compliance/AgGrid/ToolPanel/LayoutSpecification/Details/agGridLayoutSpecificationDetails.component.ts","./src/app/Compliance/AgGrid/ToolPanel/LayoutSpecification/agGridLayoutSpecification.component.help.ts","./src/app/Account/user.service.ts","./src/app/Compliance/AgGrid/ToolPanel/LayoutSpecification/agGridLayoutSpecification.component.html","./src/app/Compliance/AgGrid/ToolPanel/LayoutSpecification/agGridLayoutSpecification.component.ts","./src/app/Compliance/AgGrid/agGrid.help.ts","./src/app/UI-Lib/Tri-State-Checkbox/triStateCheckbox.component.ts","./src/app/Compliance/AgGrid/ToolPanel/Columns/agGridToolPanelColumns.component.html","./src/app/UI-Lib/Tri-State-Checkbox/triStateCheckbox.component.html","./src/app/Compliance/AgGrid/ToolPanel/Columns/agGridToolPanelColumns.component.ts","./src/app/Compliance/AgGrid/ToolPanel/agGridToolPanel.component.html","./src/app/Compliance/AgGrid/ToolPanel/agGridToolPanel.component.ts","./src/app/Compliance/AgGrid/AgGridWrapper/wsAgGridWrapper.component.html","./src/app/Compliance/AgGrid/AgGridWrapper/wsAgGridWrapper.component.ts","./src/app/Common/Activity/Parcel-Filter/parcelFilterModal.component.ts","./src/app/Common/Activity/activity.service.ts","./src/app/Common/Activity/Parcel-Filter/parcelFilterModal.component.html","./src/app/Common/Activity/activity.module.ts","./src/app/Common/Assessment-Taxes-Details/assessment-taxes-details.models.ts","./src/app/Common/Assessment-Taxes-Details/assessment-taxes-details-modal.service.ts","./src/app/Common/Assessment-Taxes-Details/assessment-taxes-details-modal.component.html","./src/app/Common/Assessment-Taxes-Details/assessment-taxes-details-modal.component.ts","./src/app/Common/Assessment-Taxes-Details/assessment-taxes-details-icon.component.ts","./src/app/Common/Assessment-Taxes-Details/assessment-taxes-details.module.ts","./src/app/UI-Lib/Mixins/year-picker.mixin.ts","./src/app/Common/Contracts-Invoices/contract-invoices.service.ts","./src/app/Common/Contracts-Invoices/engagement-number-lookup-modal.component.html","./src/app/Common/Contracts-Invoices/engagement-number-lookup-modal.component.ts","./src/app/UI-Lib/Weissman-Panel/panel.chevron.component.ts","./src/app/Common/Contracts-Invoices/choose-term-popover.component.html","./src/app/Common/Contracts-Invoices/choose-term-popover.component.ts","./src/app/Common/Contracts-Invoices/term-rates-and-fees.component.ts","./src/app/Common/Contracts-Invoices/contract-terms-panel-company.component.html","./src/app/Common/Contracts-Invoices/contract-terms-panel-company.component.ts","./src/app/Common/Contracts-Invoices/contract-terms-panel-site.component.html","./src/app/Common/Contracts-Invoices/contract-terms-panel-site.component.ts","./src/app/Common/SaveAsIcon/saveAsIcon.component.ts","./src/app/Common/SaveAsIcon/saveAsIcon.component.html","./src/app/Common/States/States.Service.ts","./src/app/UI-Lib/Multi-Select/multiSelect.component.html","./src/app/UI-Lib/Multi-Select/multiSelect.component.ts","./src/app/Common/States/State-Dropdown/state.dropdown.component.ts","./src/app/Common/Address/Address-View-Edit/address.view.edit.component.html","./src/app/Common/Address/Address-View-Edit/address.view.edit.component.ts","./src/app/Common/Step-Progress-Indicator/stepProgressIndicator.module.ts","./src/app/Common/AV-AS/category.column.picker.component.ts","./src/app/UI-Lib/ACE/Dropdown/dropdown.component.html","./src/app/UI-Lib/ACE/Dropdown/dropdown.component.ts","./src/app/Common/Instance-Filter/instanceFilter.component.html","./src/app/Common/Instance-Filter/instanceFilter.component.ts","./src/app/Entity/Company/company.service.ts","./src/app/Common/Company-Picker/companyPicker.component.ts","./src/app/Common/Company-Picker/companyPicker.component.html","./src/app/Common/AV-AS/Column-Filters/columnFilters.component.html","./src/app/Common/AV-AS/Column-Filters/columnFilters.component.ts","./src/app/Common/Stamp/stamp.module.ts","./src/app/Common/Stamp/stampTooltip.component.ts","./src/app/Common/Stamp/stamp.component.html","./src/app/Common/Stamp/stamp.component.ts","./src/app/Common/weissman-shared.module.ts","./src/app/Account/ExternalAPI/external-api.service.ts","./src/app/Account/ExternalAPI/external-api-key.component.html","./src/app/Account/ExternalAPI/external-api-key.component.ts","./src/app/Account/account.module.ts","./src/app/Accruals/accruals.bulk.update.modal.component.html","./src/app/Accruals/accruals.bulk.update.modal.component.ts","./src/app/Accruals/accruals.page.component.html","./src/app/Accruals/accruals.page.component.ts","./src/app/Accruals/Balance-Adjustments/balanceAdjustments.service.ts","./src/app/Accruals/accruals.module.ts","./src/app/Common/Models/common.model.ts","./src/app/Agents/agents.model.ts","./src/app/Agents/agents.service.ts","./src/app/Agents/agents.page.component.html","./src/app/Agents/agents.page.component.ts","./src/app/Agents/agents.module.ts","./src/app/Processing/Transmittal/transmittal.models.ts","./src/app/Contact/contactModal.service.ts","./src/app/Role/contact.role.service.ts","./src/app/Contact/Panel/List/Associate-Contact/contactListModal.component.html","./src/app/Contact/Panel/List/Associate-Contact/contactListModal.component.ts","./src/app/Attachment/attachment.model.ts","./src/app/Common/Custom-Email-Template/custom-email-template.service.ts","./src/app/Processing/Transmittal/transmittal.pipes.ts","./src/app/Processing/Transmittal/Modals/payment-packages-review.modal.html","./src/app/Processing/Transmittal/Modals/payment-packages-review.modal.ts","./src/app/Processing/Transmittal/transmittal.service.ts","./src/app/Common/Address/Address-View-Edit/address.model.ts","./src/app/Common/Address/Address-View-Edit/address.deliverability.issue.ts","./src/app/Common/Address/Address-View-Edit/address.details.modal.service.ts","./src/app/Common/Address/Address-View-Edit/address.details.modal.component.html","./src/app/Common/Address/Address-View-Edit/address.details.modal.component.ts","./src/app/Common/Address/Address-View-Edit/address.details.modal.launch.service.ts","./src/app/Processing/Transmittal/transmittal-details.component.html","./src/app/Processing/Transmittal/transmittal-details.component.ts","./src/app/Payment-Batch/paymentBatch.service.ts","./src/app/Processing/Transmittal/Modals/payment-packages-finalize.modal.html","./src/app/Processing/Transmittal/Modals/payment-packages-finalize.modal.ts","./src/app/Processing/Transmittal/payment-packages.component.html","./src/app/Processing/Transmittal/payment-packages.component.ts","./src/app/Processing/Transmittal/payment-package-attachment-summary.component.html","./src/app/Processing/Transmittal/payment-package-attachment-summary.component.ts","./src/app/Processing/Transmittal/transmittal.module.ts","./src/app/Annual-Details/Appeals/appeal.model.ts","./src/app/Annual-Details/annual-details.service.ts","./src/app/Annual-Details/annual-details-event.service.ts","./src/app/Attachment/attachment.modal.model.ts","./src/app/Task/task.service.upgrade.ts","./src/app/Annual-Details/Appeals/appeal.service.ts","./src/app/Annual-Details/Taxes/bill-cluster.service.ts","./src/app/Annual-Details/Assessments/assessment.model.ts","./src/app/Annual-Details/Assessments/assessment.service.ts","./src/app/Annual-Details/Compliance/compliance.service.ts","./src/app/Annual-Details/Budget/budget.details.service.ts","./src/app/Annual-Details/annual-details-navigation.service.ts","./src/app/Annual-Details/Annual-Year/annual-year.model.ts","./src/app/Annual-Details/annual-details.component.help.ts","./src/app/Entity/Parcel/Info/Activity/parcel-activity-modal.service.upgrade.ts","./src/app/Annual-Details/Grid/annual-details-grid.component.html","./src/app/Annual-Details/Grid/annual-details-grid.component.ts","./src/app/Common/Entity/entity.in.progress.indicator.component.ts","./src/app/Annual-Details/Modals/add-appeal.component.html","./src/app/Annual-Details/Modals/add-appeal.component.ts","./src/app/Annual-Details/Appeals/appeal.component.html","./src/app/Annual-Details/Appeals/appeal.component.ts","./src/app/UI-Lib/Currency/parenthetical-currency.component.ts","./src/app/Annual-Details/Modals/accrual-detail.component.html","./src/app/Annual-Details/Modals/accrual-detail.component.ts","./src/app/Annual-Details/Taxes/payment.model.ts","./src/app/Annual-Details/Taxes/bill.model.ts","./src/app/Annual-Details/Taxes/bill-cluster.model.ts","./src/app/Annual-Details/Taxes/refund.model.ts","./src/app/Attachment/Bill-Image-Modal/billImageModal.component.ts","./src/app/Entity/Parcel/TaxRateSetup/parcelTaxRateService.ts","./src/app/Assessor-Collector/Tax-Rates/tax.rates.service.ts","./src/app/Entity/Parcel/TaxRateSetup/parcelCollectorTaxRateSetupModal.component.html","./src/app/Entity/Parcel/TaxRateSetup/parcelCollectorTaxRateSetupModal.component.ts","./src/app/Entity/Parcel/TaxRateSetup/billClusterTaxRateSetupModal.component.html","./src/app/Entity/Parcel/TaxRateSetup/billClusterTaxRateSetupModal.component.ts","./src/app/Entity/Parcel/TaxRateSetup/taxRateSetupModalLaunchService.ts","./src/app/Annual-Details/Modals/payment-package-modal.component.ts","./src/app/Annual-Details/Modals/payment-package-modal.component.html","./src/app/Annual-Details/Taxes/bills.component.html","./src/app/Annual-Details/Taxes/bills.component.ts","./src/app/Annual-Details/Taxes/refund.component.html","./src/app/Annual-Details/Taxes/refund.component.ts","./src/app/Annual-Details/Taxes/taxes.component.html","./src/app/Annual-Details/Taxes/taxes.component.ts","./src/app/Annual-Details/Modals/add-revision.component.html","./src/app/Annual-Details/Modals/add-revision.component.ts","./src/app/Annual-Details/Annual-Year/annual-year.component.html","./src/app/Annual-Details/Annual-Year/annual-year.component.ts","./src/app/Annual-Details/Modals/reorder-revisions.component.html","./src/app/Annual-Details/Modals/reorder-revisions.component.ts","./src/app/Compliance/Allocation/allocation.service.ts","./src/app/Annual-Details/Pipes/assessment-component-exemption.pipe.ts","./src/app/Annual-Details/Assessments/assessment-input.component.ts","./src/app/Annual-Details/Assessments/assessment-input.component.html","./src/app/Annual-Details/Assessments/assessment.component.html","./src/app/Annual-Details/Assessments/assessment.component.ts","./src/app/Annual-Details/Modals/add-annual-year.component.html","./src/app/Annual-Details/Modals/add-annual-year.component.ts","./src/app/Annual-Details/Compliance/Return-Add/return-add.component.html","./src/app/Annual-Details/Compliance/Return-Add/return-add.component.ts","./src/app/Client-Services/clientServiceResponsibility.service.ts","./src/app/Compliance/Filing-Batch/filingBatch.service.ts","./src/app/Annual-Details/Compliance/compliance.model.ts","./src/app/Annual-Details/Modals/add-filing.component.html","./src/app/Annual-Details/Modals/add-filing.component.ts","./src/app/Annual-Details/Compliance/compliance.component.html","./src/app/Annual-Details/Compliance/compliance.component.ts","./src/app/Annual-Details/Budget/budget.details.component.html","./src/app/Annual-Details/Budget/budget.details.component.ts","./src/app/Annual-Details/annual-details.component.html","./src/app/Annual-Details/annual-details.component.ts","./src/app/Annual-Details/annual-details.module.ts","./src/app/Team/team.service.ts","./src/app/Team/teams.page.component.html","./src/app/Team/teams.page.component.ts","./src/app/Team/team.model.ts","./src/app/Team/Assignment/teamAssignmentPanel.component.html","./src/app/Team/Assignment/teamAssignmentPanel.component.ts","./src/app/Team/team.module.ts","./src/app/Task/Task.Model.ts","./src/app/Processing/Documents/Entity-Edit/IDP/idp.service.ts","./src/app/Processing/Documents/Entity-Edit/IDP/Detail-Modal/Card/idpDetailCard.component.html","./src/app/Processing/Documents/Entity-Edit/IDP/Detail-Modal/Card/idpDetailCard.component.ts","./src/app/Processing/Documents/Entity-Edit/IDP/Detail-Modal/idpBillDetailModal.component.html","./src/app/Processing/Documents/Entity-Edit/IDP/Detail-Modal/idpBillDetailModal.component.ts","./src/app/Processing/Documents/Entity-Edit/IDP/Detail-Modal/idpAssessmentDetailModal.component.html","./src/app/Processing/Documents/Entity-Edit/IDP/Detail-Modal/idpAssessmentDetailModal.component.ts","./src/app/Processing/Documents/Entity-Edit/IDP/idpConfidencePanel.component.html","./src/app/Processing/Documents/Entity-Edit/IDP/idpConfidencePanel.component.ts","./src/app/Processing/Documents/Entity-Edit/entity-edit.component.html","./src/app/Processing/Documents/Entity-Edit/entity-edit.component.ts","./src/app/Processing/Documents/documentProcessing.module.ts","./src/app/Processing/processing.service.upgrade.ts","./src/app/Processing/change-due-date.modal.component.html","./src/app/Processing/change-due-date.modal.component.ts","./src/app/Processing/RetrievalStatus/retrieval-status.model.ts","./src/app/Processing/RetrievalStatus/retrieval-status.service.ts","./src/app/Common/User-Pickers/user-team-picker.component.ts","./src/app/Processing/RetrievalStatus/set-document-retrieval-status.modal.component.html","./src/app/Processing/RetrievalStatus/set-document-retrieval-status.modal.component.ts","./src/app/Processing/Invoice/invoice.model.ts","./src/app/Common/User-Pickers/user-team-picker.component.html","./src/app/Processing/RetrievalStatus/retrieval-status-modal.service.ts","./src/app/Processing/Invoice/invoice.service.ts","./src/app/Processing/Invoice/Fee-Allocation/agGridActionCellRendererComponent.ts","./src/app/Processing/Invoice/Fee-Allocation/agGridEngagementNumberCellRenderer.ts","./src/app/Team/teamPicker.component.ts","./src/app/Processing/Invoice/Fee-Allocation/agGridCostCenterCellRenderer.ts","./src/app/Processing/Invoice/Fee-Allocation/agGridPercentAllocationCellRenderer.ts","./src/app/Processing/Invoice/Fee-Allocation/agGridExpenseAmountCellRenderer.ts","./src/app/Processing/Invoice/Fee-Allocation/fee-allocation.component.html","./src/app/Processing/Invoice/Fee-Allocation/fee-allocation.component.ts","./src/app/Processing/Invoice/invoice-details.component.html","./src/app/Processing/Invoice/invoice-details.component.ts","./src/app/Common/Contracts-Invoices/invoice-recipient-lookup.component.html","./src/app/Common/Contracts-Invoices/invoice-recipient-lookup.component.ts","./src/app/Processing/Invoice/invoice.component.html","./src/app/Processing/Invoice/invoice.component.ts","./src/app/Common/Invoice/create-invoice-modal.component.html","./src/app/Common/Invoice/create-invoice-modal.component.ts","./src/app/Common/Invoice/create-invoice-modal-launch.service.ts","./src/app/Processing/Invoice/invoice-panel.component.html","./src/app/Processing/Invoice/invoice-panel.component.ts","./src/app/Processing/processing.module.ts","./src/app/Consulting/consultingEngagements.repository.ts","./src/app/Permission/Instance/Instance.Permission.Service.ts","./src/app/Consulting/CompanyContracts/instanceRightsList.component.html","./src/app/Consulting/CompanyContracts/instanceRightsList.component.ts","./src/app/Consulting/CompanyContracts/companyContractsModal.component.html","./src/app/Consulting/CompanyContracts/companyContractsModal.component.ts","./src/app/Admin/DXP/dxp.service.ts","./src/app/Property-Characteristics/descriptor.service.ts","./src/app/Property-Characteristics/descriptor.picker.component.ts","./src/app/Entity/Company/Company-Settings/Accounting-Periods/accounting.periods.model.ts","./src/app/Entity/Company/Company-Settings/Accounting-Periods/accounting.periods.service.ts","./src/app/Entity/Company/Company-Settings/Accounting-Periods/accounting.periods.modal.component.html","./src/app/Entity/Company/Company-Settings/Accounting-Periods/accounting.periods.modal.component.ts","./src/app/Entity/Company/Company-Settings/Accounting-Periods/accounting.periods.link.component.ts","./src/app/Entity/Company/Company-Settings/Accruals-Descriptors/accruals.descriptor.selector.component.ts","./src/app/Entity/Company/Company-Settings/Accruals-Descriptors/accruals.descriptors.modal.component.html","./src/app/Entity/Company/Company-Settings/Accruals-Descriptors/accruals.descriptors.modal.component.ts","./src/app/Entity/Company/Company-Settings/Accruals-Descriptors/accruals.descriptors.link.component.ts","./src/app/Entity/Company/Company-Settings/Budget-Descriptors/budget.descriptor.selector.component.ts","./src/app/Entity/Company/Company-Settings/Budget-Descriptors/budget.descriptors.modal.component.html","./src/app/Entity/Company/Company-Settings/Budget-Descriptors/budget.descriptors.modal.component.ts","./src/app/Entity/Company/Company-Settings/Budget-Descriptors/budget.descriptors.link.component.ts","./src/app/Entity/Company/Company-Settings/companySettings.component.html","./src/app/Entity/Company/Company-Settings/companySettings.component.ts","./src/app/Entity/Company/Company-Compliance/companyCompliance.component.html","./src/app/Entity/Company/Company-Compliance/companyCompliance.component.ts","./src/app/Entity/Company/Vendor-Codes/vendorCode.service.ts","./src/app/Compliance/AgGrid/Row-Count/agGridRowCount.component.html","./src/app/Compliance/AgGrid/Row-Count/agGridRowCount.component.ts","./src/app/Entity/Company/Vendor-Codes/vendorCodeMapping.component.html","./src/app/Entity/Company/Vendor-Codes/vendorCodeMapping.component.ts","./src/app/Entity/Company/Vendor-Codes/vendorCode.module.ts","./src/app/Entity/Site/siteClass.service.ts","./src/app/Entity/Site/Models/parcelList.ts","./src/app/Entity/Parcel/parcel.service.upgrade.ts","./src/app/Entity/Site/Site.Service.upgrade.ts","./src/app/Entity/Company/Exploration/addSiteModal.component.html","./src/app/Entity/Company/Exploration/addSiteModal.component.ts","./src/app/Entity/Company/Exploration/companyExploration.component.html","./src/app/Entity/Company/Exploration/companyExploration.component.ts","./src/app/Entity/Company/Add/addCompanyModal.component.html","./src/app/Entity/Company/Add/addCompanyModal.component.ts","./src/app/Entity/Company/Add/launchAddCompanyModal.service.ts","./src/app/Entity/Company/Info/companyInfoPanel.component.html","./src/app/Entity/Company/Info/companyInfoPanel.component.ts","./src/app/Entity/Company/Info/companyInfoPanel.component.help.ts","./src/app/Entity/Company/Info/companyInfoPanelView.component.html","./src/app/Entity/Company/Info/companyInfoPanelView.component.ts","./src/app/Entity/Company/Info/companyInfoPanelEdit.component.html","./src/app/Entity/Company/Info/companyInfoPanelEdit.component.ts","./src/app/Common/Change-History/change-history.model.ts","./src/app/Common/Change-History/change-history.service.ts","./src/app/Common/Change-History/change-history-modal.component.html","./src/app/Common/Change-History/change-history-modal.component.ts","./src/app/Common/Change-History/change-history-modal-launch.service.ts","./src/app/Common/Services/propertyType.service.upgrade.ts","./src/app/Client-Services/Exceptions/client-service-exception.models.ts","./src/app/Client-Services/Exceptions/client-services-exception.service.ts","./src/app/Client-Services/Exceptions/client-service-exception.modal.html","./src/app/Client-Services/Exceptions/client-service-exception.modal.ts","./src/app/Client-Services/Exceptions/client-service-exception-modal.service.ts","./src/app/Entity/taxFeedSettingRepository.ts","./src/app/Documents/Document-Intake-Licensed-Clients/documentIntakeLicensedClient.repository.ts","./src/app/User-Group/user-group-service.upgrade.ts","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsComplianceReturns.component.html","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsComplianceReturns.component.ts","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsTeamRetrieves.component.html","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsTeamRetrieves.component.ts","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetails.help.ts","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsPaymentBatchWorkflow.component.html","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsPaymentBatchWorkflow.component.ts","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsFeedSpecs.component.html","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsFeedSpecs.component.ts","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsConfigureModal.component.html","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsConfigureModal.component.ts","./src/app/Common/Custom-Email-Template/custom-email-template-modal.component.html","./src/app/Common/Custom-Email-Template/custom-email-template-modal.component.ts","./src/app/Common/Custom-Email-Template/preview-email-template-modal.component.ts","./src/app/Common/Custom-Email-Template/preview-email-template-modal.component.html","./src/app/Common/Custom-Email-Template/launch.email.template.modal.service.ts","./src/app/Client-Services/Site-Descriptor-Selector/siteDescriptorSelector.component.ts","./src/app/Client-Services/Site-Descriptors-List/siteDescriptorsList.component.html","./src/app/Client-Services/Site-Descriptor-Selector/siteDescriptorSelector.component.html","./src/app/Client-Services/Site-Descriptors-List/siteDescriptorsList.component.ts","./src/app/Client-Services/Site-Descriptors-Edit/siteDescriptorsEdit.component.ts","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsTransmit.component.html","./src/app/Client-Services/Site-Descriptors-Edit/siteDescriptorsEdit.component.html","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsTransmit.component.ts","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsAssessmentAllocation.component.html","./src/app/Client-Services/Panel/Delivery-Details/deliveryDetailsAssessmentAllocation.component.ts","./src/app/Client-Services/Panel/clientServicesPanel.component.html","./src/app/Client-Services/Panel/clientServicesPanel.component.ts","./src/app/Compliance/Return/Models/enums.ts","./src/app/Compliance/Models/extendedModelBase.ts","./src/app/Compliance/Return/Models/extendedContactModel.ts","./src/app/Compliance/Return/Return-Parts/Settings/Return-Settings/returnSettings.component.help.ts","./src/app/Compliance/Return/Return-Parts/Settings/Return-Settings-Entity-Attribute/returnSettingsEntityAttribute.component.html","./src/app/Compliance/Return/Return-Parts/Settings/Return-Settings-Entity-Attribute/returnSettingsEntityAttribute.component.ts","./src/app/Compliance/Return/Return-Parts/Settings/Return-Settings-Name-Attribute/returnSettingsNameAttribute.component.html","./src/app/Compliance/Return/Return-Parts/Settings/Return-Settings-Name-Attribute/returnSettingsNameAttribute.component.ts","./src/app/Compliance/Return/Return-Parts/Settings/Return-Settings-Contact-attribute/returnSettingsContactAttribute.component.html","./src/app/Compliance/Return/Return-Parts/Settings/Return-Settings-Contact-attribute/returnSettingsContactAttribute.component.ts","./src/app/Compliance/Return/Return-Parts/Settings/Return-Settings/returnSettings.component.html","./src/app/Compliance/Return/Return-Parts/Settings/Return-Settings/returnSettings.component.ts","./src/app/Compliance/Company/Company-Return-Settings-Panel/companyReturnSettingsPanel.component.html","./src/app/Compliance/Company/Company-Return-Settings-Panel/companyReturnSettingsPanel.component.ts","./src/app/Compliance/AgGrid/CellRenderers/agGridActionCellRenderer.component.ts","./src/app/UI-Lib/Picklist/picklist.component.html","./src/app/UI-Lib/Picklist/picklist.component.ts","./src/app/Contact/Panel/List/Edit-Role/editRoleModal.component.ts","./src/app/Contact/Panel/List/Edit-Role/editRoleModal.component.html","./src/app/Contact/Panel/List/contactList.component.ts","./src/app/Contact/Panel/Body-Actions/panelBodyActions.component.html","./src/app/Contact/Panel/List/contactList.component.html","./src/app/Contact/Panel/Body-Actions/panelBodyActions.component.ts","./src/app/Contact/Panel/contactPanel.component.html","./src/app/Contact/Panel/contactPanel.component.ts","./src/app/Property-Characteristics/descriptor.overrides.service.ts","./src/app/Property-Characteristics/descriptor.helper.service.ts","./src/app/Property-Characteristics/Entity-Property-Characteristics/entity.property.characteristics.service.ts","./src/app/Property-Characteristics/Picker/property.characteristics.picker.component.html","./src/app/Property-Characteristics/Picker/property.characteristics.picker.component.ts","./src/app/Property-Characteristics/property.characteristics.overrides.component.html","./src/app/Property-Characteristics/property.characteristics.overrides.component.ts","./src/app/Property-Characteristics/descriptor.picklist.service.ts","./src/app/Property-Characteristics/Entity-Property-Characteristics/Characteristic-Input/entity.property.characteristics.input.component.html","./src/app/Property-Characteristics/Entity-Property-Characteristics/Characteristic-Input/entity.property.characteristics.input.component.ts","./src/app/Property-Characteristics/Entity-Property-Characteristics/entity.property.characteristics.list.component.ts","./src/app/Property-Characteristics/Entity-Property-Characteristics/entity.property.characteristics.component.html","./src/app/Property-Characteristics/Entity-Property-Characteristics/entity.property.characteristics.component.ts","./src/app/Entity/Company/companyPage.component.html","./src/app/Entity/Company/companyPage.component.ts","./src/app/Client-Services/client-services.module.ts","./src/app/Compliance/Asset/Asset-Class-Selector/assetClassSelector.module.ts","./src/app/Compliance/Return/Models/returnPartServiceBase.ts","./src/app/Compliance/Return/Return-Parts/Assets/returnAssets.service.ts","./src/app/Compliance/Return/Return-Parts/Overview/returnOverview.service.ts","./src/app/Compliance/Return/return.service.ts","./src/app/Compliance/Return/Models/scheduleAdditionsDisposalsReconciliationReport.ts","./src/app/Compliance/Return/Models/returnSummaryReconciliationReport.ts","./src/app/Compliance/Return/Models/filingControlReconciliationReport.ts","./src/app/Compliance/Return/Return-Parts/Output/returnOutput.service.ts","./src/app/Compliance/Return/Return-Parts/Settings/returnSettings.service.ts","./src/app/Compliance/WeissmanMutexService.ts","./src/app/Compliance/Return/Return-Forms-Error/returnFormsError.component.html","./src/app/Compliance/Return/Return-Forms-Error/returnFormsError.component.ts","./src/app/Compliance/Return/returnPage.component.help.ts","./src/app/Compliance/Return/returnUpdateLogic.service.ts","./src/app/Common/Step-Progress-Indicator/stepProgressIndicator.component.html","./src/app/Common/Step-Progress-Indicator/stepProgressIndicator.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Progress/filingBatchProgress.component.ts","./src/app/Compliance/Return/Return-Task/Return-Lock-Modal/returnLockModal.component.help.ts","./src/app/Compliance/Return/Return-Task/Return-Lock-Modal/returnLockModal.component.html","./src/app/Compliance/Return/Return-Task/Return-Lock-Modal/returnLockModal.component.ts","./src/app/Compliance/Return/Return-Task/Return-Sign-Modal/returnSignModal.component.help.ts","./src/app/Common/Warning-Message/warningMessage.component.ts","./src/app/Compliance/Return/Return-Task/Return-Sign-Modal/returnSignModal.component.ts","./src/app/Compliance/Return/Return-Task/Return-Finalize-Modal/returnFinalizeModal.component.html","./src/app/Compliance/Return/Return-Task/Return-Sign-Modal/returnSignModal.component.html","./src/app/Compliance/Return/Return-Task/Return-Finalize-Modal/returnFinalizeModal.component.ts","./src/app/Compliance/Return/Return-Task/returnTask.component.html","./src/app/Compliance/Return/Return-Task/returnTask.component.ts","./src/app/Compliance/Return/Return-Task/Return-Task-Exception-Modal/returnTaskExceptionModal.component.html","./src/app/Compliance/Return/Return-Task/Return-Task-Exception-Modal/returnTaskExceptionModal.component.ts","./src/app/Compliance/Return/Return-Task/Return-Task-Exception/returnTaskException.component.help.ts","./src/app/Compliance/Return/Return-Task/Return-Task-Exception/returnTaskException.component.ts","./src/app/Compliance/Return/Return-Batch/returnBatchTaxYearAdditionalInfo.component.ts","./src/app/Compliance/Return/Return-Task/Return-Task-Exception/returnTaskException.component.html","./src/app/Compliance/Return/Return-Batch/returnBatch.component.html","./src/app/Compliance/Return/Return-Batch/returnBatch.component.ts","./src/app/Compliance/Return/Return-Compare-Message/returnCompareConfirmationModal.component.ts","./src/app/Compliance/Return/Return-Compare-Message/returnCompareMessage.component.html","./src/app/Compliance/Return/Return-Compare-Message/returnCompareMessage.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/returnPreview.service.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Associations/returnPreviewFormAssociations.component.html","./src/app/Compliance/Return/Return-Parts/Preview/Form-Associations/returnPreviewFormAssociations.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Download/returnPreviewFormDownload.component.html","./src/app/Compliance/Return/Return-Parts/Preview/Form-Download/returnPreviewFormDownload.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-List/returnPreviewFormList.component.help.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Overrides/returnPreviewFormOverrides.component.help.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Overrides-List/agGridDataSource.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Overrides-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Overrides-List/returnPreviewFormOverrideList.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Overrides-List/returnPreviewFormOverrideList.component.html","./src/app/Compliance/Return/Return-Parts/Preview/Form-Overrides/returnPreviewFormOverrides.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Overrides/returnPreviewFormOverrides.component.html","./src/app/Compliance/Return/Return-Parts/Preview/Form-List/returnPreviewFormList.component.html","./src/app/Compliance/Return/Return-Parts/Preview/Form-List/returnPreviewFormList.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Viewer/Override-Edit/returnPreviewFormOverrideEdit.component.html","./src/app/Compliance/Return/Return-Parts/Preview/Form-Viewer/Override-Edit/returnPreviewFormOverrideEdit.component.ts","./src/app/Common/PDFViewer/pdfViewerBase.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Viewer/returnPreviewFormViewer.component.help.ts","./src/app/Common/PDFViewer/PDF-Controls/pdfControls.component.html","./src/app/Common/PDFViewer/PDF-Controls/pdfControls.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Viewer/Override-Changes/returnPreviewOverrideChanges.component.html","./src/app/Compliance/Return/Return-Parts/Preview/Form-Viewer/Override-Changes/returnPreviewOverrideChanges.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/Form-Viewer/returnPreviewFormViewer.component.html","./src/app/Compliance/Return/Return-Parts/Preview/Form-Viewer/returnPreviewFormViewer.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/returnPreview.component.ts","./src/app/Compliance/Return/Return-Parts/Preview/returnPreview.component.html","./src/app/Compliance/Return/Return-Parts/Overview/returnOverview.component.help.ts","./src/app/Compliance/Return/Return-Form-Selector/returnFormSelector.component.ts","./src/app/Compliance/Return/Return-Form-Selector/returnFormSelector.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Asset-Disposals-List/agGridDataSource.ts","./src/app/Compliance/Return/Return-Parts/Assets/Asset-List/agGridChangeIconCellRenderer.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Assessor-Table-Picker/assessorTablePicker.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Assessor-Table-Picker/assessorTablePicker.component.ts","./src/app/Compliance/Asset/Asset-Class-Selector/assetClassPicker.component.html","./src/app/Compliance/Asset/Asset-Class-Selector/assetClassPicker.component.ts","./src/app/Compliance/Asset/Asset-Class-Selector/assetClassSelector.component.html","./src/app/Compliance/Asset/Asset-Class-Selector/assetClassSelector.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Return-Asset-Bulk-Update/returnAssetBulkUpdateAction.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Return-Asset-Bulk-Update/returnAssetBulkUpdateAction.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Schedule-Selector/scheduleSelector.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Schedule-Selector/scheduleSelector.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Return-Asset-Bulk-Update/returnAssetBulkUpdate.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Return-Asset-Bulk-Update/returnAssetBulkUpdate.component.ts","./src/app/Compliance/Asset/Asset-Details/assetDetails.component.help.ts","./src/app/Compliance/Asset/Models/assetSummary.ts","./src/app/Compliance/Asset/Asset-Details/Asset-Info/assetInfo.service.ts","./src/app/Compliance/Asset/Asset-Details/assetDetails.component.html","./src/app/Compliance/Asset/Asset-Details/assetDetails.component.ts","./src/app/Compliance/modalComponentBase.ts","./src/app/Compliance/Return/Return-Parts/Assets/Asset-Disposals-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Asset-Disposals-List/returnAssetDisposalsList.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Asset-Disposals-List/returnAssetDisposalsList.component.ts","./src/app/Compliance/Return/Return-Parts/Overview/Return-Summary/returnSummary.component.html","./src/app/Compliance/Return/Return-Parts/Overview/Return-Summary/returnSummary.component.ts","./src/app/Compliance/Return/Return-Parts/Overview/Schedule-Additions-Disposals/scheduleAdditionsDisposals.component.html","./src/app/Compliance/Return/Return-Parts/Overview/Schedule-Additions-Disposals/scheduleAdditionsDisposals.component.ts","./src/app/Compliance/Return/Return-Parts/Overview/Filing-Control/filingControl.component.html","./src/app/Compliance/Return/Return-Parts/Overview/Filing-Control/filingControl.component.ts","./src/app/Compliance/Return/Return-Parts/Overview/returnOverview.component.html","./src/app/Compliance/Return/Return-Parts/Overview/returnOverview.component.ts","./src/app/Compliance/Factor-Table/Factor-Table-Details/validators.ts","./src/app/UI-Lib/Expandable-Component/baseExpandableComponent.ts","./src/app/Assessor-Collector/Assessor/assessor-service.ts","./src/app/Compliance/Factor-Table/Factor-Table-Details/factorTableTypeName-pipe.ts","./src/app/Compliance/Factor-Table/Factor-Table-Details/factorTableDetails.component.html","./src/app/Compliance/Factor-Table/Factor-Table-Details/factorTableDetails.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Drag-And-Drop/returnAssetDragAndDrop.service.ts","./src/app/Compliance/Return/Return-Parts/Assets/Drag-And-Drop/returnAssetDragAndDropSource.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Asset-List/agGridDataSource.ts","./src/app/Compliance/Return/Return-Parts/Assets/Asset-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Asset-List/returnAssetList.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Asset-List/returnAssetList.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Drag-And-Drop/returnAssetDragAndDropTarget.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Asset-Status-Selector/returnAssetStatusSelector.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Form-Details/Form-Status-Selector/returnAssetFormStatusSelector.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Asset-Status-Selector/returnAssetStatusSelector.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Form-Details/Form-Status-Selector/returnAssetFormStatusSelector.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Form-Details/Form-Factor-Selector/returnAssetFormFactorSelector.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Form-Details/Form-Factor-Selector/returnAssetFormFactorSelector.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Form-Details/Form-Schedule/returnAssetFormSchedule.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Form-Details/Form-Schedule/returnAssetFormSchedule.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/Form-Details/returnAssetFormDetails.component.html","./src/app/Compliance/Return/Return-Parts/Assets/Form-Details/returnAssetFormDetails.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/returnAssets.component.ts","./src/app/Compliance/Return/Return-Parts/Assets/returnAssets.component.html","./src/app/Compliance/Return/Return-Parts/Output/Package-List/agGridDropdownCellRenderer.component.ts","./src/app/Compliance/Return/Return-Parts/Output/Package-List/returnOutputPackageList.component.ts","./src/app/Compliance/Return/Return-Parts/Output/Printing-Mailing/returnOutputPrintingMailing.component.html","./src/app/Compliance/Return/Return-Parts/Output/Package-List/returnOutputPackageList.component.html","./src/app/Compliance/Return/Return-Parts/Output/Printing-Mailing/returnOutputPrintingMailing.component.ts","./src/app/Compliance/Return/Return-Parts/Output/returnOutput.component.html","./src/app/Compliance/Return/Return-Parts/Output/returnOutput.component.ts","./src/app/Compliance/Return/Return-Parts/Settings/Settings-Override/returnSettingsOverride.component.html","./src/app/Compliance/Return/Return-Parts/Settings/Settings-Override/returnSettingsOverride.component.ts","./src/app/Compliance/Return/Return-Parts/Settings/Report-List-Add/returnSettingsReportAdd.component.html","./src/app/Compliance/Return/Return-Parts/Settings/Report-List-Add/returnSettingsReportAdd.component.ts","./src/app/Compliance/Return/Return-Parts/Settings/Report-List/agGridActionCellRenderer.component.ts","./src/app/Reporting/Manager/reportManagerModal.component.ts","./src/app/Reporting/Manager/reportManagerModal.component.html","./src/app/Reporting/Manager/reportManagerModal.service.ts","./src/app/Compliance/AgGrid/FilterToggle/agGridFilterToggle.component.ts","./src/app/Compliance/Return/Return-Parts/Settings/Report-List/returnSettingsReportList.component.html","./src/app/Compliance/AgGrid/FilterToggle/agGridFilterToggle.component.html","./src/app/Compliance/Return/Return-Parts/Settings/Report-List/returnSettingsReportList.component.ts","./src/app/Compliance/Return/Return-Parts/Settings/General/returnSettingsGeneral.component.html","./src/app/Compliance/Return/Return-Parts/Settings/General/returnSettingsGeneral.component.ts","./src/app/Compliance/Return/Return-Parts/Settings/returnSettingsTab.component.html","./src/app/Compliance/Return/Return-Parts/Settings/returnSettingsTab.component.ts","./src/app/Compliance/Return/Return-Parts/returnParts.component.html","./src/app/Compliance/Return/Return-Parts/returnParts.component.ts","./src/app/Compliance/Return/Return-Assessor-Address-Changed-Message/returnAssessorAddressChangedMessage.component.html","./src/app/Compliance/Return/Return-Assessor-Address-Changed-Message/returnAssessorAddressChangedMessage.component.ts","./src/app/Compliance/Return/returnPage.component.html","./src/app/Compliance/Return/returnPage.component.ts","./src/app/Compliance/Return/Return-Parts/Overview/Filing-Control/Filing-Control-List/filingControlList.component.ts","./src/app/Compliance/Return/Return-Parts/Overview/Filing-Control/Filing-Control-Grouped/agGridAssessorCellRenderer.component.html","./src/app/Compliance/Return/Return-Parts/Overview/Filing-Control/Filing-Control-List/filingControlList.component.html","./src/app/Compliance/Return/Return-Parts/Overview/Filing-Control/Filing-Control-Grouped/agGridAssessorCellRenderer.component.ts","./src/app/Compliance/Return/Return-Parts/Overview/Filing-Control/Filing-Control-Grouped/agGridConsolidatedGroupCellRenderer.component.ts","./src/app/Compliance/Return/Return-Parts/Overview/Filing-Control/Filing-Control-Grouped/filingControlGrouped.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Return/Return-Parts/Overview/Filing-Control/Filing-Control-Grouped/filingControlGrouped.component.html","./src/app/Compliance/Filing-Batch/Filing-Batch-List/agGridDataSource.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-List/agGridProgressCellRenderer.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-List/filingBatchList.component.help.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-List/filingBatchList.component.html","./src/app/Compliance/Filing-Batch/Filing-Batch-List/filingBatchList.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/filingBatchDetails.component.help.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Amend-Returns-Modal/amendReturns.component.help.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Amend-Returns-Modal/amendReturns.component.html","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Amend-Returns-Modal/amendReturns.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/filingBatchDetails.service.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Info/filingBatchInfo.component.help.ts","./src/app/Compliance/Repositories/complianceInfo.repository.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Info/filingBatchInfo.component.html","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Info/filingBatchInfo.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Accounts/filingBatchAccountsAgGridActionCellRenderer.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Add-Accounts/filingBatchAddAccountsAgGridDataSource.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Add-Accounts/filingBatchAddAccounts.component.help.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Add-Accounts/filingBatchAddAccounts.component.html","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Add-Accounts/filingBatchAddAccounts.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Details/filingDetails.component.help.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Details/filingDetails.component.html","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Details/filingDetails.component.ts","./src/app/UI-Lib/Expandable-Component/baseExpandableAgGridComponent.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Move-Modal/filingBatchMoveModal.component.help.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Move-Modal/filingBatchMoveModal.component.html","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Move-Modal/filingBatchMoveModal.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Move-Result-Modal/filingBatchMoveResultModal.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Accounts/filingBatchAccounts.component.help.ts","./src/app/Compliance/AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Accounts/filingBatchAccounts.component.html","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/Filing-Batch-Accounts/filingBatchAccounts.component.ts","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/filingBatchDetails.component.html","./src/app/Compliance/Filing-Batch/Filing-Batch-Details/filingBatchDetails.component.ts","./src/app/Compliance/Filing-Batch/filingBatch.module.ts","./src/app/Compliance/Return/Return-Parts/Preview/returnPreview.module.ts","./src/app/Compliance/Return/return.module.ts","./src/app/Compliance/Company/company.module.ts","./src/app/Contact/Page/agGridDataSource.ts","./src/app/Contact/Page/contactListPage.component.html","./src/app/Contact/Page/contactListPage.component.ts","./src/app/Common/User-Pickers/user.picker.component.ts","./src/app/User/Signature/signature-panel.component.html","./src/app/User/Signature/signature-panel.component.ts","./src/app/Permission/Company/companyPermissions.service.ts","./src/app/Permission/Application/applicationPermission.service.ts","./src/app/User/userSetup.service.ts","./src/app/User/user.module.ts","./src/app/Contact/contact.module.ts","./src/app/Property-Characteristics/descriptor.validation.component.html","./src/app/Property-Characteristics/descriptor.validation.component.ts","./src/app/Property-Characteristics/property.characteristics.component.html","./src/app/Property-Characteristics/property.characteristics.component.ts","./src/app/Property-Characteristics/propertyCharacteristics.module.ts","./src/app/Entity/Company/company.module.ts","./src/app/Entity/Instance/Add/addInstanceModal.component.html","./src/app/Entity/Instance/Add/addInstanceModal.component.ts","./src/app/UI-Lib/Carousel/carousel.component.html","./src/app/UI-Lib/Carousel/carousel.component.ts","./src/app/Navigation/Onboarding-Modal/navOnboarding.component.ts","./src/app/Navigation/Onboarding-Modal/navOnboarding.component.html","./src/app/Navigation/Onboarding-Modal/onboardingBanner.component.ts","./src/app/Navigation/Top-Nav/topNav.service.ts","./src/app/Admin/admin.component.html","./src/app/Admin/admin.component.ts","./src/app/Admin/ManageAPIKeys/manage-api-keys.service.ts","./src/app/Entity/Company/Company.Picker.Component.html","./src/app/Entity/Company/Company.Picker.Component.ts","./src/app/Admin/ManageAPIKeys/manage-api-keys.component.html","./src/app/Admin/ManageAPIKeys/manage-api-keys.component.ts","./src/app/Admin/LoginManager/loginManager.service.ts","./src/app/Admin/LoginManager/loginManager.component.html","./src/app/Admin/LoginManager/loginManager.component.ts","./src/app/Admin/ManageAPIKeys/manage-api-keys.models.ts","./src/app/Admin/ManageAPIKeys/api-key-detail.component.html","./src/app/Admin/ManageAPIKeys/api-key-detail.component.ts","./src/app/Admin/About/about.service.ts","./src/app/Admin/About/about.component.html","./src/app/Admin/About/about.component.ts","./src/app/Admin/DXP/testDXPPage.component.html","./src/app/Admin/DXP/testDXPPage.component.ts","./src/app/Admin/admin.module.ts","./src/app/Layout/logoutMessage.component.ts","./src/app/Navigation/Nub/nub.help.ts","./src/app/Navigation/Nub/nub.service.ts","./src/app/Navigation/Nub/nub.component.html","./src/app/Navigation/Nub/nub.component.ts","./src/app/IAM/aceAuthOidcWrapper.component.ts","./src/app/app.component.html","./src/app/app.component.ts","./src/app/Budget/forecasting.budgeting.bulk.update.modal.component.html","./src/app/Budget/forecasting.budgeting.bulk.update.modal.component.ts","./src/app/Budget/add.company.budget.modal.component.html","./src/app/Budget/add.company.budget.modal.component.ts","./src/app/Budget/forecast.create.missing.component.html","./src/app/Budget/forecast.create.missing.component.ts","./src/app/Budget/budget.taxyear.create.missing.component.html","./src/app/Budget/budget.taxyear.create.missing.component.ts","./src/app/Budget/budget.taxyear.sync.budgets.component.html","./src/app/Budget/budget.taxyear.sync.budgets.component.ts","./src/app/Budget/forecasting.budgeting.page.component.html","./src/app/Budget/forecasting.budgeting.page.component.ts","./src/app/Budget/budget.module.ts","./src/app/Bulk-Import/bulk.import.model.ts","./src/app/Bulk-Import/bulk.import.service.ts","./src/app/Bulk-Import/Assessments/bulk.import.assessments.component.html","./src/app/Bulk-Import/Assessments/bulk.import.assessments.component.ts","./src/app/Bulk-Import/Display-String-Array/display.String.Array.model.ts","./src/app/Bulk-Import/Display-String-Array/display.String.Array.component.html","./src/app/Bulk-Import/Display-String-Array/display.String.Array.component.ts","./src/app/Bulk-Import/Sites/bulk.import.sites.component.html","./src/app/Bulk-Import/Sites/bulk.import.sites.component.ts","./src/app/Bulk-Import/bulk.import.module.ts","./src/app/Diagnostics/diagnostics.module.ts","./src/app/Attachment/attachment.module.ts","./src/app/Assessor-Collector/Collector/collector.service.upgrade.ts","./src/app/Documents/Document-Intake/document.intake.service.ts","./src/app/Documents/Document-Intake/document.intake.component.html","./src/app/Documents/Document-Intake/document.intake.component.ts","./src/app/Documents/Document-Intake-Licensed-Clients/Document-Intake-Licensed-Client-Detail/documentIntakeLicensedClientDetail.component.html","./src/app/Documents/Document-Intake-Licensed-Clients/Document-Intake-Licensed-Client-Detail/documentIntakeLicensedClientDetail.component.ts","./src/app/Documents/Document-Intake-Licensed-Clients/Document-Intake-Licensed-Client-List/documentIntakeLicensedClientList.component.html","./src/app/Documents/Document-Intake-Licensed-Clients/Document-Intake-Licensed-Client-List/documentIntakeLicensedClientList.component.ts","./src/app/Documents/documents.module.ts","./src/app/Busy-Indicator/SnackBar/Snack/snack.component.html","./src/app/Busy-Indicator/SnackBar/Snack/snack.component.ts","./src/app/Busy-Indicator/SnackBar/snackBar.component.html","./src/app/Busy-Indicator/SnackBar/snackBar.component.ts","./src/app/Busy-Indicator/SnackBar/SnackMessage/snackMessage.component.ts","./src/app/Busy-Indicator/SnackBar/snackBar.module.ts","./src/app/Navigation/Side-Nav/sideNav.component.html","./src/app/Navigation/Side-Nav/sideNav.component.ts","./src/app/UI-Lib/ACE/Utils/colorHelper.ts","./src/app/UI-Lib/ACE/Banner/banner.component.html","./src/app/UI-Lib/ACE/Banner/banner.component.ts","./src/app/Navigation/Top-Nav/topNav.component.html","./src/app/Navigation/Top-Nav/topNav.component.ts","./src/app/Navigation/User-Save/Modals/navigationModals.module.ts","./src/app/Navigation/navigation.module.ts","./src/app/Account/New-Password/newPassword.component.html","./src/app/Account/New-Password/newPassword.component.ts","./src/app/Account/Change-Password/changePassword.component.ts","./src/app/Account/Login/login.component.html","./src/app/Account/Change-Password/changePassword.component.html","./src/app/Account/Login/login.component.ts","./src/app/Appeal-Application/Set-Top-Modal/appealApplicationSetTopModal.component.html","./src/app/Appeal-Application/Set-Top-Modal/appealApplicationSetTopModal.component.ts","./src/app/Appeal-Application/PDF-Viewer/appealApplicationViewer.component.html","./src/app/Appeal-Application/PDF-Viewer/appealApplicationViewer.component.ts","./src/app/Appeal-Application/appealApplication.help.ts","./src/app/Appeal-Application/Appeal-Application-List/Download-Appeal-Form/downloadAppealForm.component.html","./src/app/Appeal-Application/Appeal-Application-List/Download-Appeal-Form/downloadAppealForm.component.ts","./src/app/Appeal-Application/Appeal-Application-List/Edit-Appeal-Associations/editAppealSupplementAssociations.component.html","./src/app/Appeal-Application/Appeal-Application-List/Edit-Appeal-Associations/editAppealSupplementAssociations.component.ts","./src/app/Appeal-Application/Appeal-Application-List/Additional-Account-Tooltip/additionalAccountTooltip.component.ts","./src/app/Appeal-Application/Appeal-Application-List/Edit-Appeal-Associations/editAppealMainAssociations.component.html","./src/app/Appeal-Application/Appeal-Application-List/Edit-Appeal-Associations/editAppealMainAssociations.component.ts","./src/app/Appeal-Application/Appeal-Application-List/appealApplicationList.component.html","./src/app/Appeal-Application/Appeal-Application-List/appealApplicationList.component.ts","./src/app/Appeal-Application/appeal.application.model.ts","./src/app/Appeal-Application/Appeal-Application-Settings/appeal.application.settings.component.html","./src/app/Appeal-Application/Appeal-Application-Settings/appeal.application.settings.component.ts","./src/app/Appeal-Application/appealApplication.component.html","./src/app/Appeal-Application/appealApplication.component.ts","./src/app/Common/AgGrid/agGridExpandCellRenderer.component.ts","./src/app/Common/AgGrid/agGridExpandCellHeaderRenderer.component.ts","./src/app/Appeal-Recommendation/ARCC/appealRecommendationGridRowInfoTreeItemModel.ts","./src/app/Compliance/AgGrid/CellRenderers/agGridTooltipCellRenderer.component.ts","./src/app/Compliance/AgGrid/agGridDescriptorColumnDefenition.ts","./src/app/Appeal-Recommendation/ARCC/agGridActionCellRenderer.component.ts","./src/app/Appeal-Recommendation/Appeal-Recommendation-Template/appealRecommendationTemplate.component.help.ts","./src/app/Appeal-Recommendation/Appeal-Recommendation-Template/appealRecommendationTemplateLastSentHelp.component.html","./src/app/Appeal-Recommendation/Appeal-Recommendation-Template/appealRecommendationTemplateLastSentHelp.component.ts","./src/app/Appeal-Recommendation/Appeal-Recommendation-Template/Appeal-Recommendation-Template-Details/appealRecommendationTemplateDetails.component.help.ts","./src/app/Appeal-Recommendation/Appeal-Recommendation-Template/Appeal-Recommendation-Template-Details/appealRecommendationTemplateDetails.component.html","./src/app/Appeal-Recommendation/Appeal-Recommendation-Template/Appeal-Recommendation-Template-Details/appealRecommendationTemplateDetails.component.ts","./src/app/Appeal-Recommendation/Appeal-Recommendation-Template/appealRecommendationTemplate.component.html","./src/app/Appeal-Recommendation/Appeal-Recommendation-Template/appealRecommendationTemplate.component.ts","./src/app/Appeal-Recommendation/ARCC/aRCC.component.help.ts","./src/app/UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component.ts","./src/app/UI-Lib/Currency/currencyInput.component.html","./src/app/UI-Lib/Currency/currencyInput.component.ts","./src/app/UI-Lib/Bulk-Update/Update-Action/bulkUpdateAction.component.ts","./src/app/UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component.html","./src/app/Appeal-Recommendation/ARCC/ARCC-Bulk-Update/aRCCBulkUpdate.component.ts","./src/app/Appeal-Recommendation/ARCC/ARCC-Bulk-Update/ARCC-Bulk-Update-Result-Confirmation/aRCCBulkUpdateResultConfirmation.component.html","./src/app/Appeal-Recommendation/ARCC/ARCC-Bulk-Update/ARCC-Bulk-Update-Result-Confirmation/aRCCBulkUpdateResultConfirmation.component.ts","./src/app/Processing/Process-Appeal-Warranted-Modal/processAppealWarranted.component.html","./src/app/Processing/Process-Appeal-Warranted-Modal/processAppealWarranted.component.ts","./src/app/Processing/Process-No-Appeal-Modal/processNoAppeal.component.html","./src/app/Processing/Process-No-Appeal-Modal/processNoAppeal.component.ts","./src/app/Task/Error-Notification/errorNotification.component.html","./src/app/Task/Error-Notification/errorNotification.component.ts","./src/app/Task/taskModals.service.ts","./src/app/Appeal-Recommendation/ARCC/ARCC-Assigned-Details-Modal/aRCCAssignedDetailsModal.component.html","./src/app/Appeal-Recommendation/ARCC/ARCC-Assigned-Details-Modal/aRCCAssignedDetailsModal.component.ts","./src/app/Appeal-Recommendation/ARCC/ARCC-Assigned/aRCCAssigned.component.html","./src/app/Appeal-Recommendation/ARCC/ARCC-Assigned/aRCCAssigned.component.ts","./src/app/Appeal-Recommendation/ARCC/aRCC.component.html","./src/app/Appeal-Recommendation/ARCC/aRCC.component.ts","./src/app/Assessor-Collector/assessor.collector.service.ts","./src/app/AppealDeadline/deadline.service.ts","./src/app/AppealDeadline/Assessor-Exceptions/assessorExceptionsModal.component.ts","./src/app/AppealDeadline/Panel/deadlineListPanel.component.html","./src/app/AppealDeadline/Panel/deadlineListPanel.component.ts","./src/app/Assessment-Class/assessmentClass.service.ts","./src/app/UI-Lib/Directives/To-Percent/toPercent.directive.ts","./src/app/Assessment-Class/View/assessmentClassModal.component.html","./src/app/Assessment-Class/View/assessmentClassModal.component.ts","./src/app/Assessment-Class/List/assessmentClassListPanel.component.html","./src/app/Assessment-Class/List/assessmentClassListPanel.component.ts","./src/app/Protocols/protocol.service.ts","./src/app/Protocols/stateAssessorExceptionsModal.component.ts","./src/app/Protocols/protocolListPanel.component.html","./src/app/Protocols/protocolListPanel.component.ts","./src/app/Assessor-Collector/Tax-Rates/tax.rates.panel.model.ts","./src/app/Tax-Rate/tax.rate.service.ts","./src/app/Assessor-Collector/Tax-Rates/add.tax.entity.modal.component.ts","./src/app/Tax-Rate/Tax-Authority/taxAuthority.help.ts","./src/app/Tax-Rate/Tax-Authority/add.tax.year.modal.component.ts","./src/app/Tax-Rate/Tax-Authority/tax.authority.component.html","./src/app/Tax-Rate/Tax-Authority/tax.authority.component.ts","./src/app/Tax-Rate/show.tax.year.component.ts","./src/app/Tax-Rate/Tax-Rate-Area/tax.rate.area.component.html","./src/app/Tax-Rate/Tax-Rate-Area/tax.rate.area.component.ts","./src/app/Tax-Rate/tax.rate.grid.component.ts","./src/app/Assessor-Collector/Tax-Rates/tax.rates.panel.service.ts","./src/app/Assessor-Collector/Tax-Rates/tax.rates.panel.component.html","./src/app/Assessor-Collector/Tax-Rates/tax.rates.panel.component.ts","./src/app/Assessor-Collector/Taxing-District/Taxing-District-List/taxingDistrictList.component.html","./src/app/Assessor-Collector/Taxing-District/Taxing-District-List/taxingDistrictList.component.ts","./src/app/Assessor-Collector/Taxing-District/taxingDistrict.component.ts","./src/app/Assessor-Collector/Assessor/Assessor-Info/assessor.info.component.html","./src/app/Assessor-Collector/Taxing-District/taxingDistrict.component.html","./src/app/Assessor-Collector/Assessor/Assessor-Info/assessor.info.component.ts","./src/app/Assessor-Collector/Assessor/Assessor-Available-Collectors/assessor.available.collectors.component.html","./src/app/Assessor-Collector/Assessor/Assessor-Available-Collectors/assessor.available.collectors.component.ts","./src/app/Assessor-Collector/Assessor/assessor.component.html","./src/app/Assessor-Collector/Assessor/assessor.component.ts","./src/app/Assessor-Collector/Collector/collector.help.ts","./src/app/Assessor-Collector/Collector/Collector-Details/collectorDetails.component.html","./src/app/Assessor-Collector/Collector/Collector-Details/collectorDetails.component.ts","./src/app/Core-Repositories/billingScenario.repository.ts","./src/app/Assessor-Collector/Collector/Billing-Scenario/billingScenario.service.ts","./src/app/Assessor-Collector/Collector/Billing-Scenario/New-Scenario/billingScenarioModal.component.html","./src/app/Assessor-Collector/Collector/Billing-Scenario/New-Scenario/billingScenarioModal.component.ts","./src/app/Assessor-Collector/Collector/Billing-Scenario/billingScenario.component.html","./src/app/Assessor-Collector/Collector/Billing-Scenario/billingScenario.component.ts","./src/app/Assessor-Collector/Collector/Protocols/collectorProtocols.component.html","./src/app/Assessor-Collector/Collector/Protocols/collectorProtocols.component.ts","./src/app/Assessor-Collector/Collector/collector.component.html","./src/app/Assessor-Collector/Collector/collector.component.ts","./src/app/Assessor-Collector/List/addAssessorModal.component.ts","./src/app/Assessor-Collector/alphabetizedList.component.ts","./src/app/Assessor-Collector/List/assessorList.component.ts","./src/app/Assessor-Collector/Add/Collector/addCollectorModal.component.html","./src/app/Assessor-Collector/Add/Collector/addCollectorModal.component.ts","./src/app/Assessor-Collector/List/collectorList.component.ts","./src/app/Compliance/State-And-Jurisdiction/stateJurisdiction.service.ts","./src/app/Client-Services/Command-Center/Bulk-Update/csrBulkUpdate.component.html","./src/app/Client-Services/Command-Center/Bulk-Update/csrBulkUpdate.component.ts","./src/app/Client-Services/Command-Center/agGridDataSource.ts","./src/app/Client-Services/Command-Center/csrCommandCenter.component.help.ts","./src/app/Client-Services/Command-Center/agGridCsrUpdateStatusCellRenderer.component.ts","./src/app/Client-Services/Command-Center/csrCommandCenter.service.ts","./src/app/Reporting/Manager/select.entities.service.ts","./src/app/Reporting/Manager/select.entities.component.html","./src/app/Reporting/Manager/select.entities.component.ts","./src/app/Client-Services/Command-Center/csrCommandCenter.component.html","./src/app/Client-Services/Command-Center/csrCommandCenter.component.ts","./src/app/Compliance/Allocation/Allocation-Details/AllocationDetailGridRowModel.ts","./src/app/Compliance/Allocation/Allocation-Details/agGridDataSource.ts","./src/app/Compliance/Allocation/Allocation-Details/Drag-And-Drop/allocationDetailDragAndDrop.service.ts","./src/app/Compliance/Allocation/Allocation-Details/Drag-And-Drop/allocationDetailDragAndDropSource.component.ts","./src/app/Compliance/Allocation/Allocation-Details/assessmentSummaryInfo.ts","./src/app/Compliance/Allocation/Allocation-Details/Add-Tax-Authority/addTaxAuthority.component.html","./src/app/Compliance/Allocation/Allocation-Details/Add-Tax-Authority/addTaxAuthority.component.ts","./src/app/Compliance/Entity-Picker/entityPicker.component.html","./src/app/Compliance/Entity-Picker/entityPicker.component.ts","./src/app/Compliance/Entity-Picker/entityPicker.ts","./src/app/Compliance/Entity-Picker/parcelPicker.ts","./src/app/Compliance/Entity-Picker/entityPicker.service.ts","./src/app/Compliance/Allocation/Allocation-Details/Allocation-Detail-Bulk-Update/allocationDetailBulkUpdateAction.component.html","./src/app/Compliance/Allocation/Allocation-Details/Allocation-Detail-Bulk-Update/allocationDetailBulkUpdateAction.component.ts","./src/app/Compliance/Allocation/Allocation-Details/Allocation-Detail-Bulk-Update/allocationDetailBulkUpdate.component.html","./src/app/Compliance/Allocation/Allocation-Details/Allocation-Detail-Bulk-Update/allocationDetailBulkUpdate.component.ts","./src/app/Compliance/Allocation/Allocation-Details/Create-New-Merged-Parcels/create-new-merged-parcels.component.html","./src/app/Compliance/Allocation/Allocation-Details/Create-New-Merged-Parcels/create-new-merged-parcels.component.ts","./src/app/Compliance/Allocation/Allocation-Details/agGridActionCellRenderer.component.ts","./src/app/Compliance/Allocation/Allocation-Details/Drag-And-Drop/allocationDetailDragAndDropCellRenderer.component.ts","./src/app/Compliance/Allocation/Allocation-Details/Allocation-Assessment-Summary/allocationAssessmentSummaryComponent.component.ts","./src/app/Compliance/Allocation/Allocation-Details/allocationDetails.service.ts","./src/app/Compliance/Allocation/Allocation-Details/agGridAssessmentSummaryActionCellRenderer.component.ts","./src/app/Compliance/Allocation/Allocation-Details/agGridAssessmentSummaryActionHeaderRenderer.component.ts","./src/app/Compliance/Allocation/Allocation-Details/allocationDetails.help.ts","./src/app/Compliance/Allocation/Allocation-Details/Retrieve-Assets/agGridDataSource.ts","./src/app/Compliance/Allocation/Allocation-Details/Retrieve-Assets/retrieveAssets.component.help.ts","./src/app/Compliance/Allocation/Allocation-Details/Retrieve-Assets/retrieveAssets.component.html","./src/app/Compliance/Allocation/Allocation-Details/Retrieve-Assets/retrieveAssets.component.ts","./src/app/Compliance/Allocation/Allocation-Details/Assets-In-Another-Allocations/assetsInAnotherAllocations.component.ts","./src/app/Compliance/Allocation/Allocation-Details/Select-Tax-Authority/selectTaxAuthority.component.html","./src/app/Compliance/Allocation/Allocation-Details/Assets-In-Another-Allocations/assetsInAnotherAllocations.component.html","./src/app/Compliance/Allocation/Allocation-Details/Select-Tax-Authority/selectTaxAuthority.component.ts","./src/app/UI-Lib/Directives/Resizable/resizable.directive.ts","./src/app/Compliance/Entity-Import/Excel-Preview/excelPreview.component.html","./src/app/Compliance/Entity-Import/Excel-Preview/excelPreview.component.ts","./src/app/Common/import/beginNewImport.component.ts","./src/app/Compliance/Allocation/Allocation-Details/allocationDetails.component.html","./src/app/Compliance/Allocation/Allocation-Details/allocationDetails.component.ts","./src/app/Compliance/Asset/Asset-List/agGridDataSource.ts","./src/app/Compliance/Asset/Asset-List/assetList.component.help.ts","./src/app/Compliance/Asset/Asset-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Asset/Asset-Details/Asset-Info/extendedGLAccountModel.ts","./src/app/Compliance/Asset/Asset-Details/Asset-Info/extendedSiteModel.ts","./src/app/Compliance/Asset/Asset-List/Asset-Bulk-Update/assetBulkUpdate.component.help.ts","./src/app/Compliance/Asset/Asset-Details/costAdjustmentHelp.component.ts","./src/app/UI-Lib/Directives/Decimal-Number-Input/decimal-number-input.directive.ts","./src/app/Compliance/Parcel/Reporting-Parcel-Selector/parcelSelector.component.html","./src/app/Compliance/Parcel/Reporting-Parcel-Selector/parcelSelector.component.ts","./src/app/Compliance/Asset/Asset-List/Asset-Bulk-Update/assetBulkUpdateAction.component.ts","./src/app/Compliance/Asset/Asset-List/Asset-Bulk-Update/assetBulkUpdateAction.component.html","./src/app/Compliance/Asset/Asset-Descriptors/assetDescriptorEdit.component.html","./src/app/Compliance/Asset/Asset-Descriptors/assetDescriptorEdit.component.ts","./src/app/Compliance/Asset/Asset-List/Asset-Bulk-Update/assetBulkUpdate.component.html","./src/app/Compliance/Asset/Asset-List/Asset-Bulk-Update/assetBulkUpdate.component.ts","./src/app/Compliance/Asset/Asset-List/Asset-Change-Icon/assetChangeIcon.component.ts","./src/app/Compliance/Asset/Asset-List/agGridChangeIconCellRenderer.component.ts","./src/app/UI-Lib/HotKeys/hotKeys.service.ts","./src/app/Common/Delete-Confirmation/deleteConfirmation.component.ts","./src/app/Compliance/AgGrid/CellRenderers/agGridTextWithTotalsUpdateCellRenderer.component.ts","./src/app/Compliance/Asset/Asset-List/Asset-Import-Progress/assetImportProgress.component.ts","./src/app/Compliance/Asset/Asset-List/Asset-Import-Progress/assetImportProgress.component.html","./src/app/Compliance/Asset/Asset-List/Asset-Import-Progress/assetImportProgress.service.ts","./src/app/Compliance/AgGrid/ToolPanel/LayoutSpecification/CurrentLayoutApplied/agGridCurrentLayoutApplied.component.ts","./src/app/Compliance/Asset/Asset-List/Asset-Advanced/assetAdvanced.component.help.ts","./src/app/Compliance/Asset/Asset-List/Asset-Advanced-Details/assetAdvancedDetails.component.html","./src/app/Compliance/Asset/Asset-List/Asset-Advanced-Details/assetAdvancedDetails.component.ts","./src/app/Compliance/Asset/Models/assetPropertyMap.ts","./src/app/Compliance/Asset/Asset-List/Asset-Advanced/assetAdvanced.component.html","./src/app/Compliance/Asset/Asset-List/Asset-Advanced/assetAdvanced.component.ts","./src/app/Compliance/Asset/Asset-List/Asset-Limit/assetLimit.component.help.ts","./src/app/Compliance/Asset/Asset-List/Asset-Limit-Details/assetLimitDetails.component.html","./src/app/Compliance/Asset/Asset-List/Asset-Limit-Details/assetLimitDetails.component.ts","./src/app/Compliance/Asset/Asset-List/Asset-Limit/assetLimit.component.html","./src/app/Compliance/Asset/Asset-List/Asset-Limit/assetLimit.component.ts","./src/app/Compliance/Asset/Asset-List/assetList.component.html","./src/app/Compliance/Asset/Asset-List/assetList.component.ts","./src/app/Compliance/Electronic-Filing/agGridDataSource.ts","./src/app/Compliance/Electronic-Filing/electronicFiling.component.help.ts","./src/app/Compliance/Electronic-Filing/electronicFiling.component.html","./src/app/Compliance/Electronic-Filing/electronicFiling.component.ts","./src/app/Compliance/Entity-Import/Import-List/agGridDataSource.ts","./src/app/Compliance/Entity-Import/Import-Progress/entityImportProgress.component.ts","./src/app/Compliance/Entity-Import/Import-List/agGridProgressCellRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-List/importList.component.help.ts","./src/app/Compliance/Entity-Import/Import-Process/Transfer-Confirm/transferConfirm.component.html","./src/app/Compliance/Entity-Import/Import-Process/Transfer-Confirm/transferConfirm.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Dynamic-Field-Behavior/dynamicFieldBehavior.service.ts","./src/app/Compliance/Entity-Import/Import-Process/importProcess.service.ts","./src/app/Compliance/Entity-Import/Import-List/importList.component.html","./src/app/Compliance/Entity-Import/Import-List/importList.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/Import-Specification-Mapping/importSpecificationMapping.component.html","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/Import-Specification-Mapping/importSpecificationMapping.component.ts","./src/app/Compliance/Entity-Import/Import-Process/importProcess.component.help.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/columnMappingStep.service.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/agGridPinnedRowCellRenderer.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/agGridDataSource.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/agGridHeaderRowCellRenderer.component.ts","./src/app/Compliance/Entity-Import/Static-Fields/staticFields.component.html","./src/app/Compliance/Entity-Import/Static-Fields/staticFields.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/columnMappingStep.component.help.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/Import-Mapping-Modal/importMappingModal.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/Import-Mapping-Modal/importMappingModal.component.html","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/Drag-And-Drop-Overlay/agGridOverlay.service.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/Drag-And-Drop-Overlay/agGridOverlayContainer.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/Drag-And-Drop-Overlay/agGridOverlay.component.html","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/Drag-And-Drop-Overlay/agGridOverlay.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Dynamic-Field-Behavior/Dynamic-Field-Behavior-Help/dynamicFieldBehaviorHelp.component.html","./src/app/Compliance/Entity-Import/Import-Process/Dynamic-Field-Behavior/Dynamic-Field-Behavior-Help/dynamicFieldBehaviorHelp.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Dynamic-Field-Behavior/Dynamic-Field-Behavior-Configuration/dynamicFieldBehaviorConfiguration.component.html","./src/app/Compliance/Entity-Import/Import-Process/Dynamic-Field-Behavior/Dynamic-Field-Behavior-Configuration/dynamicFieldBehaviorConfiguration.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Dynamic-Field-Behavior/Dynamic-Field-Selected-Behavior-Help/dynamicFieldSelectedBehaviorHelp.component.html","./src/app/Compliance/Entity-Import/Import-Process/Dynamic-Field-Behavior/Dynamic-Field-Selected-Behavior-Help/dynamicFieldSelectedBehaviorHelp.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Dynamic-Field-Behavior/dynamicFieldBehavior.component.html","./src/app/Compliance/Entity-Import/Import-Process/Dynamic-Field-Behavior/dynamicFieldBehavior.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/columnMappingStep.component.html","./src/app/Compliance/Entity-Import/Import-Process/Column-Mapping-Step/columnMappingStep.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/agGridDataSource.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/agGridEstimatedActionHeaderRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/agGridEstimatedActionFilterRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/agGridEstimatedActionCellRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/SelectorRenderers/agGridAssetClassSelectorRenderer.component.ts","./src/app/Valuation/Income-Statement/Income-Statement-Category-Selector/incomeStatementCategoryPicker.component.html","./src/app/Valuation/Income-Statement/Income-Statement-Category-Selector/incomeStatementCategoryPicker.component.ts","./src/app/Valuation/Income-Statement/Income-Statement-Category-Selector/incomeStatementCategorySelector.component.html","./src/app/Valuation/Income-Statement/Income-Statement-Category-Selector/incomeStatementCategorySelector.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Import-Bulk-Update/importBulkUpdateAction.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Import-Bulk-Update/importBulkUpdateAction.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/Assessor-Selector/assessorSelector.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/AssessmentClass-Selector/assessmentClassSelector.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/Assessor-Selector/assessorSelector.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/AssessmentClass-Selector/assessmentClassSelector.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/GLAccount-Selector/glAccountSelector.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/GLAccount-Selector/glAccountSelector.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/TaxingDistrict-Selector/taxingDistrictSelector.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Import-Bulk-Update/importBulkUpdate.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/TaxingDistrict-Selector/taxingDistrictSelector.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Import-Bulk-Update/importBulkUpdate.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/Typeahead-Selector/typeaheadSelector.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/Typeahead-Selector/typeaheadSelector.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/SelectorRenderers/agGridAssessorSelectorRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/SelectorRenderers/agGridAttachmentTypeSelectorRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/Lease-Type-Selector/leaseTypeSelector.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/Lease-Type-Selector/leaseTypeSelector.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/SelectorRenderers/agGridLeaseTypeSelectorRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/SelectorRenderers/agGridAssessmentClassSelectorRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/SelectorRenderers/agGridGLAccountSelectorRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/SelectorRenderers/agGridTaxingDistrictSelectorRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/OneTimeVRecurring-Selector/oneTimeVRecurringSelector.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/OneTimeVRecurring-Selector/oneTimeVRecurringSelector.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/SelectorRenderers/agGridOneTimeVRecurringSelectorRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/SelectorRenderers/agGridIncomeStatementCategorySelectorRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/SelectorRenderers/agGridGLAccountTypeSelectorRenderer.component.ts","./src/app/Compliance/Long-Running-Process/longRunningProcess.service.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/editor.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/editor.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Validation-Summary/validationSummary.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Validation-Summary/validationSummary.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/editingStep.component.html","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/editingStep.component.ts","./src/app/Compliance/Entity-Import/Import-Process/importProcess.component.html","./src/app/Compliance/Entity-Import/Import-Process/importProcess.component.ts","./src/app/Compliance/Entity-Import/Import-Specification-List/agGridDataSource.ts","./src/app/Compliance/Entity-Import/Import-Specification-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Entity-Import/Import-Specification-List/Import-Specification-Edit/importSpecificationEdit.component.html","./src/app/Compliance/Entity-Import/Import-Specification-List/Import-Specification-Edit/importSpecificationEdit.component.ts","./src/app/Compliance/Entity-Import/Import-Specification-List/importSpecificationList.component.help.ts","./src/app/Compliance/Entity-Import/Import-Specification-List/importSpecificationList.component.html","./src/app/Compliance/Entity-Import/Import-Specification-List/importSpecificationList.component.ts","./src/app/Compliance/Factor-Table/Factor-Table-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Factor-Table/Factor-Table-Export-Attachments/factorTableExportAttachments.component.html","./src/app/Compliance/Factor-Table/Factor-Table-Export-Attachments/factorTableExportAttachments.component.ts","./src/app/Compliance/Factor-Table/Factor-Table-List/factorTableList.component.html","./src/app/Compliance/Factor-Table/Factor-Table-List/factorTableList.component.ts","./src/app/Compliance/Form/Models/enums.ts","./src/app/Compliance/Form/form.help.ts","./src/app/Compliance/Form/Form-Details/formDetails.component.ts","./src/app/Compliance/Form/Form-Details/formDetails.component.html","./src/app/Compliance/Form/Form-Setup-Upload/formSetupUpload.component.html","./src/app/Compliance/Form/Form-Setup-Upload/formSetupUpload.component.ts","./src/app/Compliance/Form/Form-Setup-Download/formSetupDownload.component.html","./src/app/Compliance/Form/Form-Setup-Download/formSetupDownload.component.ts","./src/app/Compliance/Form/Export-Form-List/exportFormList.component.html","./src/app/Compliance/Form/Export-Form-List/exportFormList.component.ts","./src/app/Compliance/Form/Form-Library-Export/formLibraryExport.component.html","./src/app/Compliance/Form/Form-Library-Export/formLibraryExport.component.ts","./src/app/Compliance/Form/form.service.ts","./src/app/Compliance/Form/Form-List/formList.component.html","./src/app/Compliance/Form/Form-List/formList.component.ts","./src/app/Compliance/Form/Form-Schedule-List/agGridCheckboxCellRender.component.ts","./src/app/Compliance/Form/Form-Schedule-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Form/Form-Schedule-List/agGridFactorTableDropdownCellRenderer.component.ts","./src/app/Compliance/Form/Form-Schedule-List/agGridInputCellRender.component.ts","./src/app/Compliance/Form/Form-Schedule-List/agGridReportDropdownCellRenderer.component.ts","./src/app/Compliance/Form/Form-Schedule-List/formScheduleList.component.html","./src/app/Compliance/Form/Form-Schedule-List/formScheduleList.component.ts","./src/app/Compliance/Form/Form-Year-List/formYearList.component.ts","./src/app/Compliance/Form/Form-Year-New-Modal/formYearNewModal.component.html","./src/app/Compliance/Form/Form-Year-List/formYearList.component.html","./src/app/Compliance/Form/Form-Year-New-Modal/formYearNewModal.component.ts","./src/app/Compliance/Form/Form-Year-New/formYearNew.component.ts","./src/app/Compliance/Form/Form-Year-Copy-List/formYearCopyList.component.html","./src/app/Compliance/Form/Form-Year-New/formYearNew.component.html","./src/app/Compliance/Form/Form-Year-Copy-List/formYearCopyList.component.ts","./src/app/Compliance/Form/Form-Year-Copy/formYearCopy.component.ts","./src/app/Compliance/Form/Form-Year-Copy/formYearCopy.component.html","./src/app/Compliance/Form/Form-Year-Delete/formYearDelete.component.ts","./src/app/Compliance/Form/Form-Assessor-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Form/Form-Year-Delete/formYearDelete.component.html","./src/app/Compliance/Form/Form-Assessor-Add/FormAssessorAdd.component.html","./src/app/Compliance/Form/Form-Assessor-Add/formAssessorAdd.component.ts","./src/app/Compliance/Form/Form-Assessor-List/Assessor-Address-Tooltip/assessorAddressTooltip.component.ts","./src/app/Compliance/Form/Form-Assessor-List/agGridAddressCellRenderer.component.ts","./src/app/Compliance/Form/Form-Assessor-Address-Picker/formAssessorAddressPicker.component.html","./src/app/Compliance/Form/Form-Assessor-Address-Picker/formAssessorAddressPicker.component.ts","./src/app/Compliance/Form/Form-Assessor-List/Assessor-Certified-Tooltip/assessorCertifiedTooltip.component.html","./src/app/Compliance/Form/Form-Assessor-List/Assessor-Certified-Tooltip/assessorCertifiedTooltip.component.ts","./src/app/Compliance/Form/Form-Assessor-List/formAssessorList.component.html","./src/app/Compliance/Form/Form-Assessor-List/formAssessorList.component.ts","./src/app/Compliance/Form/Form-Comments/FormComments.component.html","./src/app/Compliance/Form/Form-Comments/formComments.component.ts","./src/app/Compliance/Form/Form-Attachments/FormAttachments.component.html","./src/app/Compliance/Form/Form-Attachments/formAttachments.component.ts","./src/app/Compliance/Form/Form-Factor-Table-Add/formFactorTableAdd.component.html","./src/app/Compliance/Form/Form-Factor-Table-Add/formFactorTableAdd.component.ts","./src/app/Compliance/Form/Form-Factor-Table-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Form/Form-Factor-Table-List/formFactorTableList.component.html","./src/app/Compliance/Form/Form-Factor-Table-List/formFactorTableList.component.ts","./src/app/Compliance/Form/Form-Asset-Class-Mapping/agGridDropdownCellRenderer.component.ts","./src/app/Compliance/Form/Form-Asset-Class-Mapping/agGridActionCellRenderer.component.ts","./src/app/Compliance/Form/Form-Asset-Class-Mapping/formAssetClassMapping.component.html","./src/app/Compliance/Form/Form-Asset-Class-Mapping/formAssetClassMapping.component.ts","./src/app/Compliance/Form/Form-Field-List/formFieldList.component.html","./src/app/Compliance/Form/Form-Field-List/formFieldList.component.ts","./src/app/Compliance/Form/Form-Fields/formFields.component.ts","./src/app/Compliance/Form/Form-Template-Edit/formTemplateEdit.component.html","./src/app/Compliance/Form/Form-Fields/formFields.component.html","./src/app/Compliance/Form/Form-Template-Edit/formTemplateEdit.component.ts","./src/app/Compliance/Form/Form-Template-Validation/formTemplateValidation.component.html","./src/app/Compliance/Form/Form-Template-Validation/formTemplateValidation.component.ts","./src/app/Compliance/Form/Form-Template-Upload/formTemplateUpload.component.html","./src/app/Compliance/Form/Form-Template-Upload/formTemplateUpload.component.ts","./src/app/Compliance/Form/Form-Template/formTemplate.component.html","./src/app/Compliance/Form/Form-Template/formTemplate.component.ts","./src/app/Compliance/Form/Form-Report-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Form/Form-Report-List/agGridCheckboxCellRender.component.ts","./src/app/Compliance/Form/Form-Report-Add/formReportAdd.component.ts","./src/app/Compliance/Form/Form-Report-List/formReportList.component.html","./src/app/Compliance/Form/Form-Report-Add/formReportAdd.component.html","./src/app/Compliance/Form/Form-Report-List/formReportList.component.ts","./src/app/Compliance/Form/Form-Switches/formSwitches.component.html","./src/app/Compliance/Form/Form-Switches/formSwitches.component.ts","./src/app/Compliance/Form/Form-Appeal-Level-List/formAppealLevelList.component.ts","./src/app/Compliance/Form/Form-Appeal-Level-List/formAppealLevelList.component.html","./src/app/Compliance/Form/Form-Assessor-Select/formAssessorSelect.component.ts","./src/app/Compliance/Form/Form-Assessor-Select/formAssessorSelect.component.html","./src/app/Compliance/Form/Form-Filing-Batch-List/formFilingBatchList.component.ts","./src/app/Compliance/Form/Form-Filing-Batch-List/formFilingBatchList.component.html","./src/app/Compliance/Form/Form-FilingBatches/formFilingBatches.component.ts","./src/app/Compliance/Form/Form-Page/formPage.component.html","./src/app/Compliance/Form/Form-FilingBatches/formFilingBatches.component.html","./src/app/Compliance/Form/Form-Page/formPage.component.ts","./src/app/Compliance/GL-Account/GL-Account-List/agGridDataSource.ts","./src/app/Compliance/GL-Account/glAccount.service.ts","./src/app/Compliance/GL-Account/GL-Account-Details/glAccountDetails.component.html","./src/app/Compliance/GL-Account/GL-Account-Details/glAccountDetails.component.ts","./src/app/Compliance/GL-Account/GL-Account-List/GL-Account-Bulk-Update/glAccountBulkUpdateAction.component.html","./src/app/Compliance/GL-Account/GL-Account-List/GL-Account-Bulk-Update/glAccountBulkUpdateAction.component.ts","./src/app/Compliance/GL-Account/GL-Account-List/GL-Account-Bulk-Update/glAccountBulkUpdate.component.html","./src/app/Compliance/GL-Account/GL-Account-List/GL-Account-Bulk-Update/glAccountBulkUpdate.component.ts","./src/app/Compliance/GL-Account/GL-Account-List/glAccountList.component.help.ts","./src/app/Compliance/GL-Account/GL-Account-List/GL-Account-Bulk-Update/glAccountBulkUpdateIncomeStatementTypes.component.html","./src/app/Compliance/GL-Account/GL-Account-List/GL-Account-Bulk-Update/glAccountBulkUpdateIncomeStatementTypes.component.ts","./src/app/Compliance/GL-Account/GL-Account-List/glAccountList.component.html","./src/app/Compliance/GL-Account/GL-Account-List/glAccountList.component.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Page/longRunningProcessPage.component.help.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-List/agGridDataSource.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-List/longRunningProcessList.component.help.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-List/agGridActionCellRenderer.component.ts","./src/app/Diagnostics/Error-Log/Error-Log-Details/errorLogDetails.component.html","./src/app/Diagnostics/Error-Log/Error-Log-Details/errorLogDetails.component.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-List/long-running-process-list-grid-error-guid-cell-renderer.component.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-List/longRunningProcessList.component.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-List/longRunningProcessList.component.html","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Quiesce-Modal/longRunningProcessQuiesceModal.component.help.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Quiesce-Modal/longRunningProcessQuiesceModal.component.html","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Quiesce-Modal/longRunningProcessQuiesceModal.component.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Quiesce/longRunningProcessQuiesce.component.help.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Synthetic-Modal/longRunningProcessSyntheticModal.component.help.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Synthetic-Modal/longRunningProcessSyntheticModal.component.html","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Synthetic-Modal/longRunningProcessSyntheticModal.component.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Synthetic/longRunningProcessSynthetic.component.help.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Synthetic/longRunningProcessSynthetic.component.html","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Synthetic/longRunningProcessSynthetic.component.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Control-Modal/longRunningProcessControlModal.component.help.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Control-Modal/longRunningProcessControlModal.component.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Control-Modal/longRunningProcessControlModal.component.html","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Control/longRunningProcessControl.component.help.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Control/longRunningProcessControl.component.html","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Control/longRunningProcessControl.component.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Quiesce/longRunningProcessQuiesce.component.html","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Quiesce/longRunningProcessQuiesce.component.ts","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Page/longRunningProcessPage.component.html","./src/app/Compliance/Long-Running-Process/Long-Running-Process-Page/longRunningProcessPage.component.ts","./src/app/Compliance/State-And-Jurisdiction/stateJurisdiction.columns.ts","./src/app/Compliance/State-And-Jurisdiction/agGridDataSource.ts","./src/app/Compliance/State-And-Jurisdiction/Bulk-Update/stateJurisdictionBulkUpdate.component.html","./src/app/Compliance/State-And-Jurisdiction/Bulk-Update/stateJurisdictionBulkUpdate.component.ts","./src/app/Compliance/State-And-Jurisdiction/stateJurisdiction.component.help.ts","./src/app/Compliance/State-And-Jurisdiction/Command-View-Controls/viewControls.component.ts","./src/app/Compliance/State-And-Jurisdiction/stateJurisdiction.component.html","./src/app/Compliance/State-And-Jurisdiction/Command-View-Controls/viewControls.component.html","./src/app/Compliance/State-And-Jurisdiction/stateJurisdiction.component.ts","./src/app/Compliance/Supplemental-Information/Supplemental-Information-Sheet/agGridDropdownCellRenderer.component.ts","./src/app/Compliance/Supplemental-Information/Supplemental-Information-Sheet/supplementalInformationSheet.component.html","./src/app/Compliance/Supplemental-Information/Supplemental-Information-Sheet/supplementalInformationSheet.component.ts","./src/app/Consulting/consultingEngagementModal.component.html","./src/app/Consulting/consultingEngagementModal.component.ts","./src/app/Consulting/consultingEngagements.component.html","./src/app/Consulting/consultingEngagements.component.ts","./src/app/Dashboard/dashboard.model.ts","./src/app/Dashboard/Widgets/Calendar-Widget/calendar.widget.model.ts","./src/app/Dashboard/dashboard.data.service.ts","./src/app/UI-Lib/Mixins/unsubscribe.mixin.ts","./src/app/Dashboard/Widgets/appeal.savings.widget.component.ts","./src/app/Dashboard/Widgets/quick.search.button.widget.component.ts","./src/app/Dashboard/Widgets/states.button.widget.component.ts","./src/app/Dashboard/Widgets/Calendar-Widget/calendar.widget.component.html","./src/app/Dashboard/Widgets/Calendar-Widget/calendar.widget.component.ts","./src/app/Dashboard/Widgets/Shortcuts-Widget/shortcut.widget.component.ts","./src/app/Dashboard/Widgets/Shortcuts-Widget/shortcut.widget.settings.component.html","./src/app/Dashboard/Widgets/Shortcuts-Widget/shortcut.widget.settings.component.ts","./src/app/Dashboard/Widgets/Portfolio-Analysis-Widget/portfolio.analysis.widget.model.ts","./src/app/Dashboard/Widgets/Portfolio-Analysis-Widget/portfolio.analysis.chart.table.component.html","./src/app/Dashboard/Widgets/Portfolio-Analysis-Widget/portfolio.analysis.chart.table.component.ts","./src/app/Dashboard/Widgets/Portfolio-Analysis-Widget/portfolio.analysis.widget.component.html","./src/app/Dashboard/Widgets/Portfolio-Analysis-Widget/portfolio.analysis.widget.component.ts","./src/app/Dashboard/Widgets/My-Tasks-Widget/my.tasks.widget.component.html","./src/app/Dashboard/Widgets/My-Tasks-Widget/my.tasks.widget.component.ts","./src/app/Dashboard/Widgets/My-Tasks-Widget/my.tasks.widget.model.ts","./src/app/Dashboard/Widgets/My-Tasks-Widget/my.tasks.widget.settings.component.html","./src/app/Dashboard/Widgets/My-Tasks-Widget/my.tasks.widget.settings.component.ts","./src/app/Dashboard/Widgets/Calendar-Widget/calendar.widget.settings.component.html","./src/app/Dashboard/Widgets/Calendar-Widget/calendar.widget.settings.component.ts","./src/app/Dashboard/widget.component.registry.service.ts","./src/app/Dashboard/Widgets/user.widget.component.ts","./src/app/Dashboard/dashboard.component.ts","./src/app/Diagnostics/Database/Process-List/agGridActionCellRenderer.component.ts","./src/app/Diagnostics/Database/Process-List/processList.component.help.ts","./src/app/Diagnostics/Database/database.repository.ts","./src/app/Diagnostics/Database/Database-Clear-Cache-Entry/databaseClearCacheEntry.component.html","./src/app/Diagnostics/Database/Database-Clear-Cache-Entry/databaseClearCacheEntry.component.ts","./src/app/Diagnostics/Database/Process-List/processList.component.html","./src/app/Diagnostics/Database/Process-List/processList.component.ts","./src/app/Diagnostics/diagnostics.component.ts","./src/app/Diagnostics/diagnostics.component.html","./src/app/Diagnostics/Error-Log/Error-Log-List/agGridDataSource.ts","./src/app/Diagnostics/Error-Log/Error-Log-List/agGridActionCellRenderer.component.ts","./src/app/Diagnostics/Error-Log/errorLog.service.ts","./src/app/Diagnostics/Error-Log/Error-Log-List/errorLogList.component.html","./src/app/Diagnostics/Error-Log/Error-Log-List/errorLogList.component.ts","./src/app/Diagnostics/Query-Info/Query-Info-List/agGridDataSource.ts","./src/app/Diagnostics/Query-Info/Query-Info-List/agGridActionCellRenderer.component.ts","./src/app/Diagnostics/Query-Info/Query-Info-Details/queryInfoDetails.component.html","./src/app/Diagnostics/Query-Info/Query-Info-Details/queryInfoDetails.component.ts","./src/app/Diagnostics/Query-Info/queryInfo.service.ts","./src/app/Diagnostics/Query-Info/Query-Info-List/queryInfoList.component.html","./src/app/Diagnostics/Query-Info/Query-Info-List/queryInfoList.component.ts","./src/app/Entity/Instance/Info/instanceInfoPanel.component.html","./src/app/Entity/Instance/Info/instanceInfoPanel.component.ts","./src/app/Entity/Instance/manageInvitations.component.html","./src/app/Entity/Instance/manageInvitations.component.ts","./src/app/Entity/move.copy.entity.component.help.ts","./src/app/Entity/move.copy.entity.service.ts","./src/app/Entity/move.copy.entity.component.html","./src/app/Entity/move.copy.entity.component.ts","./src/app/Landing/landing.component.ts","./src/app/Entity/site.map.service.ts","./src/app/Entity/site.map.info.window.component.ts","./src/app/Entity/site.map.component.html","./src/app/Entity/site.map.component.ts","./src/app/Landing/Help/_help.html","./src/app/Landing/Help/help.component.ts","./src/app/Landing/landing.component.html","./src/app/Landing/landing.selector.component.ts","./src/app/UI-Lib/ACE/Button-Group/buttonGroup.component.html","./src/app/UI-Lib/ACE/Button-Group/buttonGroup.component.ts","./src/app/Navigation/User-Save/Save-Page/savePage.component.html","./src/app/Navigation/User-Save/Save-Page/savePage.component.ts","./src/app/Navigation/Saved-AV/savedActionView.component.ts","./src/app/Navigation/Saved-AV/savedActionView.component.html","./src/app/Navigation/Saved-Report/savedReport.component.ts","./src/app/Navigation/User-Save/Save-Tab-Content/saveTabContent.component.html","./src/app/Navigation/Saved-Report/savedReport.component.html","./src/app/Navigation/User-Save/Save-Tab-Content/saveTabContent.component.ts","./src/app/Navigation/Saved-Smart/savedSmart.component.ts","./src/app/Navigation/Saved-Smart/savedSmart.component.html","./src/app/Payment-Batch/Command-Center/agGridDataSource.ts","./src/app/Payment-Batch/Command-Center/paymentBatch.component.help.ts","./src/app/Payment-Batch/Command-Center/agGridActionCellRenderer.component.ts","./src/app/Payment-Batch/Command-Center/paymentBatch.columns.ts","./src/app/Payment-Batch/Create-Payment-Batch-Modal/createPaymentBatchModal.component.html","./src/app/Payment-Batch/Create-Payment-Batch-Modal/createPaymentBatchModal.component.ts","./src/app/Payment-Batch/Command-Center/Filters/paymentBatchFilters.component.html","./src/app/Payment-Batch/Command-Center/Filters/paymentBatchFilters.component.ts","./src/app/Payment-Batch/Command-Center/paymentBatch.component.html","./src/app/Payment-Batch/Command-Center/paymentBatch.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Task-Exception-Modal/paymentBatchTaskExceptionModal.component.html","./src/app/Payment-Batch/Payment-Batch-Details/Task-Exception-Modal/paymentBatchTaskExceptionModal.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/paymentBatchDetails.component.html","./src/app/Payment-Batch/Payment-Batch-Details/paymentBatchDetails.component.ts","./src/app/Reporting/Modals/save-report.component.html","./src/app/Reporting/Modals/save-report.component.ts","./src/app/Reporting/reporting.service.ts","./src/app/Reporting/Manager/report.manager.component.help.ts","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.psr.component.ts","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.budget.component.ts","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.maar.component.ts","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.progress.status.component.ts","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.psr.component.html","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.psr.component.ts","./src/app/Reporting/Manager/Format-Output-Panel/Order-By/reportOrderBy.component.ts","./src/app/Reporting/Manager/Format-Output-Panel/report.detail.options.component.ts","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.budget.component.html","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.budget.component.ts","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.site.component.ts","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.site.component.ts","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.schedules.summary.component.html","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.schedules.summary.component.ts","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.schedules.summary.component.html","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.schedules.summary.component.ts","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.asset.detail.component.html","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.asset.detail.component.ts","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.asset.detail.component.html","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.asset.detail.component.ts","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.user.activity.component.ts","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.support.instance.escalation.activity.component.ts","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.support.instance.escalation.activity.component.ts","./src/app/Reporting/Manager/report.manager.component.ts","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.user.activity.component.ts","./src/app/Reporting/Manager/Further-Limit-Panel/further.limit.panel.budget.variance.component.ts","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.budget.variance.component.html","./src/app/Reporting/Manager/Format-Output-Panel/format.output.panel.budget.variance.component.ts","./src/app/Reporting/Manager/report.manager.component.html","./src/app/Role/roles.list.component.html","./src/app/Role/roles.list.component.ts","./src/app/Search/Advanced/smartSearch.help.ts","./src/app/Common/AV-AS/Column-Filters/columnFilter.service.ts","./src/app/Search/Advanced/Save-Search-Modal/saveSearchModal.component.html","./src/app/Search/Advanced/Save-Search-Modal/saveSearchModal.component.ts","./src/app/Search/Advanced/Advanced-Search/Filter-List/filterList.component.html","./src/app/Search/Advanced/Advanced-Search/Filter-List/filterList.component.ts","./src/app/UI-Lib/Directives/Drag-And-Drop-List/dragAndDropList.directive.ts","./src/app/Search/Advanced/Advanced-Search/Output-List/outputList.component.html","./src/app/Search/Advanced/Advanced-Search/Output-List/outputList.component.ts","./src/app/Search/Advanced/Advanced-Search/advancedSearch.component.html","./src/app/Search/Advanced/Advanced-Search/advancedSearch.component.ts","./src/app/Search/Advanced/Advanced-Search-List/advancedSearchList.service.ts","./src/app/Search/Advanced/Advanced-Search-List/Bulk-Update/advancedSearchBulkUpdate.component.ts","./src/app/Search/Advanced/Advanced-Search-List/advancedSearchColumnBuilder.service.ts","./src/app/Search/Advanced/Advanced-Search-List/advancedSearchList.component.ts","./src/app/Search/Advanced/Advanced-Search-List/advancedSearchList.component.html","./src/app/Search/Advanced/smartSearch.component.html","./src/app/Search/Advanced/smartSearch.component.ts","./src/app/State/states.component.html","./src/app/State/states.component.ts","./src/app/State/State-Details/state.details.component.ts","./src/app/State/us.state.component.html","./src/app/State/State-Details/state.details.component.html","./src/app/State/us.state.component.ts","./src/app/Compliance/Repositories/supportInstance.repository.ts","./src/app/Support-Instances/Support-Instance-Request-Access/supportInstanceRequestAccess.component.html","./src/app/Support-Instances/Support-Instance-Request-Access/supportInstanceRequestAccess.component.ts","./src/app/Support-Instances/Support-Instance-Deactivate-Instance-Pending/supportInstanceDeactivateInstancePending.component.html","./src/app/Support-Instances/Support-Instance-Deactivate-Instance-Pending/supportInstanceDeactivateInstancePending.component.ts","./src/app/Support-Instances/Support-Instance-Deactivate-Instance-Confirm/supportInstanceDeactivateInstanceConfirm.component.html","./src/app/Support-Instances/Support-Instance-Deactivate-Instance-Confirm/supportInstanceDeactivateInstanceConfirm.component.ts","./src/app/Support-Instances/Support-Instance-List/supportInstanceList.component.html","./src/app/Support-Instances/Support-Instance-List/supportInstanceList.component.ts","./src/app/Task/ActionView/Action-View-Output-Custom/actionViewOutputCustom.component.ts","./src/app/Task/ActionView/Action-View-Output-Defaults/actionViewOutputDefaults.component.html","./src/app/Task/ActionView/Action-View-Output-Defaults/actionViewOutputDefaults.component.ts","./src/app/Tax-Rate/tax.rate.model.ts","./src/app/Tax-Rate/Command-Center/Tax-Authority-Bulk-Update/tax.authority.bulk.update.action.component.html","./src/app/Tax-Rate/Command-Center/Tax-Authority-Bulk-Update/tax.authority.bulk.update.action.component.ts","./src/app/Tax-Rate/Command-Center/Tax-Authority-Bulk-Update/tax.authority.bulk.update.component.html","./src/app/Tax-Rate/Command-Center/Tax-Authority-Bulk-Update/tax.authority.bulk.update.component.ts","./src/app/Tax-Rate/Command-Center/agGridDataSource.ts","./src/app/Permission/Company/Site/companySitePermissions.component.ts","./src/app/Permission/Company/Panel/CompanyPermissionOptions.ts","./src/app/Tax-Rate/Command-Center/tax.rate.command.center.component.html","./src/app/Tax-Rate/Command-Center/tax.rate.command.center.component.ts","./src/app/Permission/Company/Site/companySitePermissionsAgGridDataSource.ts","./src/app/Permission/permission.service.ts","./src/app/Permission/Company/Site/companySitePermissions.component.html","./src/app/Permission/Company/Add/agGridDataSource.ts","./src/app/Permission/Company/Add/companyPermissionAdd.component.html","./src/app/Permission/Company/Add/companyPermissionAdd.component.ts","./src/app/Permission/Company/Panel/agGridDataSource.ts","./src/app/User-Group/User-Group-Detail/userGroupDetail.component.help.ts","./src/app/User-Group/userGroup.service.ts","./src/app/Permission/Company/Panel/companyPermissionPanel.component.html","./src/app/Permission/Company/Panel/companyPermissionPanel.component.ts","./src/app/Permission/Instance/instancePermissionPanel.component.html","./src/app/Permission/Instance/instancePermissionPanel.component.ts","./src/app/Permission/Application/applicationPermissionPanel.component.html","./src/app/Permission/Application/applicationPermissionPanel.component.ts","./src/app/User-Group/User-Group-Detail/userGroupDetail.component.html","./src/app/User-Group/User-Group-Detail/userGroupDetail.component.ts","./src/app/User-Group/User-Group-List/addUserGroupModal.component.ts","./src/app/User-Group/User-Group-List/userGroupList.component.html","./src/app/User-Group/User-Group-List/userGroupList.component.ts","./src/app/Valuation/Income-Statement/Income-Statement-List/agGridDataSource.ts","./src/app/Valuation/Income-Statement/Income-Statement-Bulk-Update/incomeStatementBulkUpdate.component.ts","./src/app/Valuation/Income-Statement/Income-Statement-List/incomeStatementList.component.html","./src/app/Valuation/Income-Statement/Income-Statement-List/incomeStatementList.component.ts","./src/app/Valuation/Rent-Roll/Rent-Roll-List/agGridDataSource.ts","./src/app/Valuation/Rent-Roll/Rent-Roll-List/agGridActionCellRendererComponent.ts","./src/app/Valuation/Rent-Roll/Rent-Roll-Bulk-Update/rentRollBulkUpdate.component.ts","./src/app/Valuation/Rent-Roll/Rent-Roll-List/rentRollList.component.html","./src/app/Valuation/Rent-Roll/Rent-Roll-List/rentRollList.component.ts","./src/app/Valuation/Templates/valuationTemplate.service.ts","./src/app/Valuation/Templates/Add-Edit-Tempalate/addEditValuationTemplate.component.html","./src/app/Valuation/Templates/Add-Edit-Tempalate/addEditValuationTemplate.component.ts","./src/app/Valuation/Templates/valuationTemplate.help.ts","./src/app/Valuation/Templates/Template-Detail/States-List/Add-State/addState.component.ts","./src/app/Valuation/Templates/Template-Detail/States-List/valuationStatesList.component.html","./src/app/Valuation/Templates/Template-Detail/States-List/Add-State/addState.component.html","./src/app/Valuation/Templates/Template-Detail/States-List/valuationStatesList.component.ts","./src/app/Valuation/Templates/Template-Detail/Assessor-List/Add-Assessor/addAssessor.component.ts","./src/app/Valuation/Templates/Template-Detail/Assessor-List/valuationAssessorsList.component.html","./src/app/Valuation/Templates/Template-Detail/Assessor-List/Add-Assessor/addAssessor.component.html","./src/app/Valuation/Templates/Template-Detail/Assessor-List/valuationAssessorsList.component.ts","./src/app/Valuation/Templates/Template-Detail/Site-Class-List/Add-Site-Class/addSiteClass.component.ts","./src/app/Valuation/Templates/Template-Detail/Site-Class-List/valuationSiteClassList.component.html","./src/app/Valuation/Templates/Template-Detail/Site-Class-List/Add-Site-Class/addSiteClass.component.html","./src/app/Valuation/Templates/Template-Detail/Site-Class-List/valuationSiteClassList.component.ts","./src/app/Valuation/Templates/Template-Detail/Upload/Template-Upload/upload.component.html","./src/app/Valuation/Templates/Template-Detail/Upload/Template-Upload/upload.component.ts","./src/app/Valuation/Templates/Template-Detail/Upload/valuationTemplateUpload.component.html","./src/app/Valuation/Templates/Template-Detail/Upload/valuationTemplateUpload.component.ts","./src/app/Valuation/Templates/Template-Detail/valuationTemplateDetail.component.html","./src/app/Valuation/Templates/Template-Detail/valuationTemplateDetail.component.ts","./src/app/Valuation/Templates/valuationTemplates.component.ts","./src/app/Valuation/Templates/valuationTemplates.component.html","./src/app/Responsible-Entity/Responsible-Entity-List/agGridDataSource.ts","./src/app/Responsible-Entity/Responsible-Entity-List/agGridActionCellRenderer.component.ts","./src/app/Responsible-Entity/Responsible-Entity-Details/responsibleEntityDetails.component.html","./src/app/Responsible-Entity/Responsible-Entity-Details/responsibleEntityDetails.component.ts","./src/app/Responsible-Entity/Responsible-Entity-List/responsibleEntityList.component.html","./src/app/Responsible-Entity/Responsible-Entity-List/responsibleEntityList.component.ts","./src/app/Landing/ssoLogin.component.ts","./src/app/Diagnostics/Attachment-Download/attachmentDownloadDiagnostic.component.html","./src/app/Diagnostics/Attachment-Download/attachmentDownloadDiagnostic.component.ts","./src/app/ng2Routes.module.ts","./src/app/Common/Long-Running-Process/core.long.running.process.service.ts","./src/app/Search/searchCategories.service.ts","./src/app/Hybrid/ng1-upgrade-providers.ts","./src/app/Entity/Parcel/Activity/parcel-activity.service.ts","./src/app/Entity/Parcel/Activity/parcel-activity-summary.component.html","./src/app/Entity/Parcel/Activity/parcel-activity-summary.component.ts","./src/app/Compliance/Parcel/Reporting-Parcel-Site-List/reportingParcelSiteList.component.html","./src/app/Compliance/Parcel/Reporting-Parcel-Site-List/reportingParcelSiteList.component.ts","./src/app/Compliance/Parcel/Compliance-Info-Panel/complianceInfoPanel.component.html","./src/app/Compliance/Parcel/Compliance-Info-Panel/complianceInfoPanel.component.ts","./src/app/Entity/Parcel/TaxRateSetup/firstEncounter.component.html","./src/app/Entity/Parcel/TaxRateSetup/firstEncounter.component.ts","./src/app/Compliance/Parcel/parcel.module.ts","./src/app/Entity/Parcel/Linked-Parcels/Linked-Parcels-List/agGridActionCellRenderer.component.ts","./src/app/Entity/Parcel/Linked-Parcels/Linked-Parcels-Add/linkedParcelsAdd.component.ts","./src/app/Entity/Parcel/Linked-Parcels/Linked-Parcels-List/agGridNameCellRenderer.component.ts","./src/app/Entity/Parcel/Linked-Parcels/Linked-Parcels-Add/linkedParcelsAdd.component.html","./src/app/Entity/Parcel/Linked-Parcels/linkedParcel.repository.ts","./src/app/Entity/Parcel/Linked-Parcels/Linked-Parcels-List/linkedParcelsList.component.html","./src/app/Entity/Parcel/Linked-Parcels/Linked-Parcels-List/linkedParcelsList.component.ts","./src/app/Entity/Parcel/Linked-Parcels/linkedParcels.component.help.ts","./src/app/Entity/Parcel/Linked-Parcels/linkedParcels.component.html","./src/app/Entity/Parcel/Linked-Parcels/linkedParcels.component.ts","./src/app/Entity/Parcel/Linked-Parcels/Linked-Parcels-Edit/linkedParcelsEdit.component.ts","./src/app/Entity/Parcel/Reports-Sites/Reports-Sites-List/agGridNameCellRenderer.component.ts","./src/app/Entity/Parcel/Linked-Parcels/Linked-Parcels-Edit/linkedParcelsEdit.component.html","./src/app/Entity/Parcel/Reports-Sites/Reports-Sites-List/parcelReportsSitesList.component.ts","./src/app/Entity/Parcel/Reports-Sites/parcelReportsSites.component.html","./src/app/Entity/Parcel/Reports-Sites/Reports-Sites-List/parcelReportsSitesList.component.html","./src/app/Entity/Parcel/Reports-Sites/parcelReportsSites.component.ts","./src/app/Entity/Parcel/Icon/parcelIcon.module.ts","./src/app/Accruals/Balance-Adjustments/accrualsAdjustmentsList.component.html","./src/app/Accruals/Balance-Adjustments/accrualsAdjustmentsList.component.ts","./src/app/Accruals/Balance-Adjustments/accrualsBalancesList.component.html","./src/app/Accruals/Balance-Adjustments/accrualsBalancesList.component.ts","./src/app/Entity/Parcel/Accruals/accrualsPanel.component.html","./src/app/Entity/Parcel/Accruals/accrualsPanel.component.ts","./src/app/Entity/Parcel/Info/addParcelCollectorModal.component.html","./src/app/Entity/Parcel/Info/addParcelCollectorModal.component.ts","./src/app/Entity/Parcel/Info/tempParcelCollectorModal.service.ts","./src/app/Entity/Assessor-Details/assessorDetails.component.ts","./src/app/Entity/Parcel/Info/legalDescriptionModal.component.ts","./src/app/Entity/Parcel/Info/parcelInfoPanel.component.help.ts","./src/app/Entity/Parcel/Info/Tax-Rates/collectorTaxRateArea.component.ts","./src/app/Entity/Parcel/Info/parcelInfoPanelView.component.html","./src/app/Entity/Parcel/Info/parcelInfoPanelView.component.ts","./src/app/Common/Activity/activityStatus.service.ts","./src/app/Entity/Parcel/Info/parcelInfoPanelEdit.component.html","./src/app/Entity/Parcel/Info/parcelInfoPanelEdit.component.ts","./src/app/Entity/Parcel/Info/parcelInfoPanel.component.html","./src/app/Entity/Parcel/Info/parcelInfoPanel.component.ts","./src/app/Entity/Parcel/parcel.module.ts","./src/app/Reporting/reporting.module.ts","./src/app/Role/role.module.ts","./src/app/Search/Quick/Criteria/IDP-Auto-Populate-Input/autoPopulateInput.component.html","./src/app/Search/Quick/Criteria/IDP-Auto-Populate-Input/autoPopulateInput.component.ts","./src/app/Search/Quick/Criteria/quickSearchCriteria.component.html","./src/app/Search/Quick/Criteria/quickSearchCriteria.component.ts","./src/app/Search/Quick/Criteria/quickSearchCriteria.module.ts","./src/app/Search/Quick/quickSearch.module.ts","./src/app/Processing/Complete-File-Appeal-Modal/completeFileAppealModal.component.html","./src/app/Processing/Complete-File-Appeal-Modal/completeFileAppealModal.component.ts","./src/app/Processing/Documents/Modals/documentProcessingExceptionModal.component.html","./src/app/Processing/Documents/Modals/documentProcessingExceptionModal.component.ts","./src/app/Processing/Documents/Modals/duplicateIntakeItemModal.component.html","./src/app/Processing/Documents/Modals/duplicateIntakeItemModal.component.ts","./src/app/Task/Reassign-Task-Modal/reassignTaskModal.component.ts","./src/app/Task/Reassign-Task-Modal/reassignTaskModal.component.html","./src/app/Appeal-Recommendation/Appeal-Recommendation-Template/appealRecommendationTemplateModal.service.ts","./src/app/Payment-Batch/Add-Payments-To-Batch-Modal/addPaymentsToBatchModal.component.ts","./src/app/Payment-Batch/Add-Payments-To-Batch-Modal/addPaymentsToBatchModal.service.ts","./src/app/Task/ActionView/actionViewContextMenu.service.ts","./src/app/Task/ActionView/Detailed-List/actionDetailed.component.html","./src/app/Task/ActionView/Detailed-List/actionDetailed.component.ts","./src/app/Task/ActionView/actionView.module.ts","./src/app/Appeal-Recommendation/appealRecommendation.module.ts","./src/app/Task/task.module.ts","./src/app/Landing/Widgets/overview-single-grouping.component.html","./src/app/Landing/Widgets/overview-single-grouping.component.ts","./src/app/Dashboard/dashboard.module.ts","./src/app/Landing/landing.module.ts","./src/app/Compliance/Electronic-Filing/electronicFiling.module.ts","./src/app/Valuation/Templates/valuationTemplates.module.ts","./src/app/Valuation/valuation.module.ts","./src/app/Compliance/Asset/Asset-Details/Return-Filings/agGridStatusCellRenderer.component.ts","./src/app/Compliance/Asset/Asset-Details/Asset-Info/assetInfo.columns.ts","./src/app/Compliance/Asset/Asset-List/Asset-Advanced-Details/assetAdvancedDetailCheckbox.component.html","./src/app/Compliance/Asset/Asset-List/Asset-Advanced-Details/assetAdvancedDetailCheckbox.component.ts","./src/app/Compliance/Asset/Asset-Details/Asset-Info/Cost-Editor/assetInfoCostEditor.component.html","./src/app/Compliance/Asset/Asset-Details/Asset-Info/Cost-Editor/assetInfoCostEditor.component.ts","./src/app/Compliance/Asset/Asset-Details/Asset-Info/assetInfo.component.html","./src/app/Compliance/Asset/Asset-Details/Asset-Info/assetInfo.component.ts","./src/app/Compliance/Asset/Asset-Details/Return-Filings/assetReturnFilings.component.ts","./src/app/Compliance/Asset/Asset-Details/Return-Filings/assetReturnFilings.component.html","./src/app/Compliance/Asset/Asset-Details/Activity-Log/assetActivityLog.component.ts","./src/app/Compliance/Asset/Asset-Details/Asset-Info/Cost-Adjustments/costAdjustments.component.html","./src/app/Compliance/Asset/Asset-Details/Activity-Log/assetActivityLog.component.html","./src/app/Compliance/Asset/Asset-Details/Asset-Info/Cost-Adjustments/costAdjustments.component.ts","./src/app/Compliance/GL-Account/GL-Account-Selector/glAccountSelector.module.ts","./src/app/Compliance/Site/Site-Selector/siteSelector.module.ts","./src/app/Compliance/Asset/Asset-Lien-Date/assetLienDate.module.ts","./src/app/Compliance/GL-Account/GL-Account-Selector/glAccountSelector.component.html","./src/app/Compliance/GL-Account/GL-Account-Selector/glAccountSelector.component.ts","./src/app/Compliance/Site/Site-Selector/siteSelector.component.ts","./src/app/Compliance/Site/Site-Selector/siteSelector.component.html","./src/app/Compliance/Asset/Asset-Details/assetDetails.module.ts","./src/app/Compliance/Asset/asset.module.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/Attachment-Type-Selector/attachmentTypeSelector.component.ts","./src/app/Compliance/Entity-Import/Import-Process/Editing-Step/Editor/Selectors/Attachment-Type-Selector/attachmentTypeSelector.component.html","./src/app/Compliance/Entity-Import/entityImport.module.ts","./src/app/Compliance/Factor-Table/factorTable.module.ts","./src/app/Compliance/Form/form.module.ts","./src/app/Compliance/GL-Account/glAccount.module.ts","./src/app/Compliance/Supplemental-Information/supplementalInformation.module.ts","./src/app/Compliance/Long-Running-Process/longRunningProcess.module.ts","./src/app/Common/Data/HttpInterceptors/dateConvertInterceptor.ts","./src/app/Common/Data/HttpInterceptors/angular1CallbackInterceptor.ts","./src/app/Common/Models/errorModels.ts","./src/app/Common/Data/HttpInterceptors/authInterceptor.ts","./src/app/Common/Data/HttpInterceptors/cacheBusterInterceptor.ts","./src/app/Common/Data/HttpInterceptors/instanceHeaderInterceptor.ts","./src/app/Common/Data/HttpInterceptors/index.ts","./src/app/Common/Logging/logging.service.ts","./src/app/Common/ErrorHandler/globalErrorHandler.ts","./src/app/Compliance/Site/Linked-Sites/Linked-Sites-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Site/site.service.ts","./src/app/Compliance/Site/Linked-Sites/Linked-Sites-Add/linkedSitesAdd.component.ts","./src/app/Compliance/Site/Linked-Sites/Linked-Sites-List/agGridNameCellRenderer.component.ts","./src/app/Compliance/Site/Linked-Sites/Linked-Sites-Add/linkedSitesAdd.component.html","./src/app/Compliance/Site/Linked-Sites/Linked-Sites-List/linkedSitesList.component.html","./src/app/Compliance/Site/Linked-Sites/Linked-Sites-List/linkedSitesList.component.ts","./src/app/Compliance/Site/Linked-Sites/linkedSites.component.help.ts","./src/app/Compliance/Site/Linked-Sites/linkedSites.component.html","./src/app/Compliance/Site/Linked-Sites/linkedSites.component.ts","./src/app/Compliance/Site/Linked-Sites/Linked-Sites-Reporting/linkedSitesReporting.component.ts","./src/app/Compliance/Site/Linked-Sites/Linked-Sites-Reporting/linkedSitesReporting.component.html","./src/app/Compliance/Site/Linked-Sites/Linked-Sites-Edit/linkedSitesEdit.component.ts","./src/app/Compliance/Site/Linked-Sites/Linked-Sites-Edit/linkedSitesEdit.component.html","./src/app/Compliance/Site/site.module.ts","./src/app/Diagnostics/Error-Log/errorLog.module.ts","./src/app/Diagnostics/Query-Info/queryInfo.module.ts","./src/app/Compliance/State-And-Jurisdiction/stateJurisdiction.module.ts","./src/app/Compliance/Allocation/Allocation-List/Add-Allocation/addAllocationModal.component.html","./src/app/Compliance/Allocation/Allocation-List/Add-Allocation/addAllocationModal.component.ts","./src/app/Compliance/Allocation/Allocation-List/agGridActionCellRenderer.component.ts","./src/app/Compliance/Allocation/Allocation-List/agGridDataSource.ts","./src/app/Compliance/Allocation/Allocation-List/allocationList.component.help.ts","./src/app/Compliance/Allocation/Allocation-List/allocationList.component.html","./src/app/Compliance/Allocation/Allocation-List/allocationList.component.ts","./src/app/Compliance/Allocation/allocation.module.ts","./src/app/Compliance/compliance.module.ts","./src/app/Hybrid/ng1Upgrade.module.ts","./src/app/Entity/Site/Parcels/Add-Parcel-Modal/addParcelModal.component.html","./src/app/Common/Services/event-adapter.service.upgrade.ts","./src/app/Contact/contactsRoleAssociation.service.upgrade.ts","./src/app/Hybrid/startup.service.upgrade.ts","./src/app/Entity/Site/Parcels/Add-Parcel-Modal/addParcelModal.component.ts","./src/app/Entity/Site/Parcels/parcelListPanel.component.help.ts","./src/app/Entity/Site/Parcels/Parcel-Bulk-Update/parcelBulkUpdate.component.help.ts","./src/app/Entity/Site/Parcels/Parcel-Bulk-Update/Parcel-Bulk-Update-Action/parcelBulkUpdateAction.component.html","./src/app/Entity/Site/Parcels/Parcel-Bulk-Update/Parcel-Bulk-Update-Action/parcelBulkUpdateAction.component.ts","./src/app/Entity/Site/Parcels/Parcel-Bulk-Update/parcelBulkUpdate.component.html","./src/app/Entity/Site/Parcels/Parcel-Bulk-Update/parcelBulkUpdate.component.ts","./src/app/Entity/Site/Parcels/agGridActionCellRenderer.component.ts","./src/app/Entity/Site/Parcels/agGridPercentChangeRenderer.component.ts","./src/app/Entity/Site/Parcels/agGridFMVChangeRenderer.component.ts","./src/app/Entity/Site/Parcels/agGridFMVRenderer.component.ts","./src/app/Entity/entity.service.ts","./src/app/Entity/Site/Parcels/Parcel-Tile/parcelTile.component.html","./src/app/Entity/Site/Parcels/Parcel-Tile/parcelTile.component.ts","./src/app/Entity/Site/Parcels/parcelListPanel.component.html","./src/app/Entity/Site/Parcels/parcelListPanel.component.ts","./src/app/Entity/Site/Info/siteInfoPanel.component.help.ts","./src/app/Common/Address/google.maps.single.marker.modal.component.ts","./src/app/Entity/Site/Info/siteInfoPanel.component.html","./src/app/Entity/Site/Info/siteInfoPanel.component.ts","./src/app/Entity/Site/Assets/assetListPanel.component.html","./src/app/Entity/Site/Assets/assetListPanel.component.ts","./src/app/Entity/Site/Valuation/valuationPanel.component.html","./src/app/Entity/Site/Valuation/valuationPanel.component.ts","./src/app/Entity/Site/Responsible-Entity/responsibleEntityPanel.component.html","./src/app/Entity/Site/Responsible-Entity/responsibleEntityPanel.component.ts","./src/app/Responsible-Entity/responsibleEntity.module.ts","./src/app/Entity/Site/site.module.ts","./src/app/Entity/entity.module.ts","./src/app/Layout/layout.module.ts","./src/app/Entity/Instance/instance.module.ts","./src/app/Consulting/consulting.module.ts","./src/app/Client-Services/Command-Center/csrCommandCenter.module.ts","./src/app/Tax-Rate/Tax-Authority/Allowed-Exemption-List/checkboxList.component.html","./src/app/Tax-Rate/Tax-Authority/Allowed-Exemption-List/checkboxList.component.ts","./src/app/Tax-Rate/tax.rate.module.ts","./src/app/Assessor-Collector/Tax-Rates/taxRatesPanel.module.ts","./src/app/Assessor-Collector/Taxing-District/taxingDistrict.module.ts","./src/app/State/stateAssessorShared.module.ts","./src/app/Assessor-Collector/Assessor/assessor.module.ts","./src/app/Assessor-Collector/Collector/collector.module.ts","./src/app/Assessor-Collector/assessorCollector.module.ts","./src/app/Search/Advanced/smartSearch.module.ts","./src/app/Appeal-Application/appealApplication.module.ts","./src/app/State/state.module.ts","./src/app/Account/Login/login.module.ts","./src/app/Support-Instances/supportInstance.module.ts","./src/app/User-Group/User-Group-Detail/User-Group-Info/userGroupInfo.component.ts","./src/app/UI-Lib/Interceptors/blobErrorHttp.interceptor.ts","./src/app/Diagnostics/Database/database.module.ts","./src/app/Permission/Company/Panel/companyPermissionUserPanel.component.html","./src/app/Permission/Company/Panel/companyPermissionUserPanel.component.ts","./src/app/Permission/permission.module.ts","./src/app/User-Group/User-Group-Detail/User-Group-Info/userGroupInfo.component.html","./src/app/User-Group/userGroup.module.ts","./src/app/Common/webComponentWrapper.module.ts","./src/app/Payment-Batch/Payment-Batch-Details/Payments-Grid/agGridActionCellRenderer.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Payments-Grid/agGridPaymentErrorsCellRenderer.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Payments-Grid/paymentBatchPayments.columns.ts","./src/app/Payment-Batch/Payment-Batch-Details/Payments-Grid/agGridDataSource.ts","./src/app/Payment-Batch/Payment-Batch-Details/paymentBatchDetails.component.help.ts","./src/app/Payment-Batch/Payment-Batch-Details/Payments-Grid/paymentBatchPaymentsGrid.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Packages-Table/paymentBatchPackages.component.html","./src/app/Payment-Batch/Payment-Batch-Details/Payments-Grid/paymentBatchPaymentsGrid.component.html","./src/app/Payment-Batch/Payment-Batch-Details/Packages-Table/paymentBatchPackages.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Output/shippingMethodsModal.component.html","./src/app/Payment-Batch/Payment-Batch-Details/Output/shippingMethodsModal.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Output/paymentBatchOutput.component.html","./src/app/Payment-Batch/Payment-Batch-Details/Output/paymentBatchOutput.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Settings/paymentBatchSettings.component.html","./src/app/Payment-Batch/Payment-Batch-Details/Settings/paymentBatchSettings.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Add-Payments-Modal/agGridDataSource.ts","./src/app/Payment-Batch/Payment-Batch-Details/Add-Payments-Modal/addPaymentsToBatchModal.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Add-Payments-Modal/paymentBatchAddPayment.columns.ts","./src/app/Payment-Batch/Payment-Batch-Details/Check-Import-Modal/checkImportModal.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Check-Import-Modal/Finalize/finalizeCheckImportPaymentGrid.componet.ts","./src/app/Payment-Batch/Payment-Batch-Details/Check-Import-Modal/Finalize/finalizeCheckImportChecksGrid.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Check-Import-Modal/Finalize/finalizeCheckImportModal.component.ts","./src/app/Payment-Batch/Payment-Batch-Details/Payment-Batch-Summary/paymentBatchSummary.component.html","./src/app/Payment-Batch/Payment-Batch-Details/Payment-Batch-Summary/paymentBatchSummary.component.ts","./src/app/Payment-Batch/paymentBatch.module.ts","./src/app/app.module.ts","./src/environments/environment.prod.ts","./src/app/weissmanEnvironmentConfig.ts","./src/app/localStorageKeys.ts","./src/main.ts","./node_modules/moment/locale/ sync ^\\.\\/.*$"],"sourcesContent":["// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Authentication.Service';\r\n\tvar SERVICE_URL = '/api/account/';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, AuthenticationService);\r\n\r\n\tAuthenticationService.$inject = [\r\n\t\t'sdLogger',\r\n\t\t'sd.Http.Service',\r\n\t\t'accountService',\r\n\t\t'$rootScope',\r\n\t];\r\n\r\n\tfunction AuthenticationService(sdLogger, sdHttp, accountService, $rootScope) {\r\n\t\tvar service = {\r\n\t\t\tgetUserInfo: _getUserInfo\r\n\t\t};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction _getUserInfo() {\r\n\t\t\treturn sdHttp.get(SERVICE_URL + 'GetUserInfo')\r\n\t\t\t\t.then(function (response) {\r\n\t\t\t\t\tsdLogger.log(APP_SOURCE + '._getUserInfo(): ', {\r\n\t\t\t\t\t\t'response': response\r\n\t\t\t\t\t});\r\n\t\t\t\t\taccountService.ensureUserHasAccessToPriorInstanceSelection(response);\r\n\t\t\t\t\t$rootScope.$emit(\"userInfoRetrieved\",response);\r\n\t\t\t\t\treturn response;\r\n\t\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sdNewPassword';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive(APP_SOURCE, Directive);\r\n\r\n\tDirective.$inject = [\r\n\t\t'sd.Account.User.Service',\r\n ];\r\n\r\n\tfunction Directive(userService) {\r\n\t\t// Usage:\r\n\t\t// \t\t
foo
\r\n\t\t//\r\n\t\t// See PermissionFlags constant in constants.js for PermissionFlags values\r\n\t\t// See Roles constant in constants.js for Roles values\r\n\t\tvar directive = {\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n showCurrent: '=',\r\n form: '=',\r\n passwords: '=',\r\n alreadyUsed: '='\r\n },\r\n templateUrl: 'app/Account/newPassword.html',\r\n\t\t\tlink: link\r\n\t\t};\r\n\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element) {\r\n scope.passwordRegEx = '';\r\n scope.username = '';\r\n\r\n scope.clearCurrentValidation = clearCurrentValidation;\r\n scope.clearNewValidation = clearNewValidation;\r\n scope.checkAlreadyUsed = checkAlreadyUsed;\r\n\r\n activate();\r\n\r\n function activate() {\r\n // (?=.*\\d)(?=.*[a-z])(?=.*[A-Z]).{8,}/\r\n scope.passwordRegEx = /^(?=.*?[a-zA-Z])(?=.*?[0-9])(?=.*?[^\\w\\s]).{8,}$/;;\r\n var user = userService.getUser();\r\n if (user) {\r\n scope.username = user.username;\r\n }\r\n }\r\n\r\n function clearCurrentValidation(form) {\r\n form.current.$setValidity('incorrect', true);\r\n }\r\n\r\n function clearNewValidation(form) {\r\n form.new.$setValidity('noSpecialChars', true);\r\n }\r\n\r\n function checkAlreadyUsed(form) {\r\n var validity = scope.passwords.new !== scope.alreadyUsed;\r\n\r\n form.new.$setValidity('alreadyUsed', validity)\r\n }\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissmanApp.Assessor.Service\r\n * @description\r\n * # Assessor Service\r\n * Factory in the weissmanApp.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Assessor.Service';\r\n\tvar SERVICE_URL = '/api/assessor/';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = [\r\n\t\t'sd.Http.Service',\r\n\t];\r\n\r\n\tfunction Service(sdHttp) {\r\n\t\t// Public API.\r\n\t\tvar service = {\r\n\t\t\tgetByStateId: getByStateId,\r\n\t\t\tgetBySiteId: getBySiteId\r\n\t\t};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction getByStateId(stateId) {\r\n\t\t\treturn sdHttp.get(`${SERVICE_URL}/state/${stateId}`)\r\n\t\t}\r\n\r\n\t\tfunction getBySiteId(id) {\r\n\t\t\tvar url = SERVICE_URL + 'sitedefault/' + id;\r\n\r\n\t\t\treturn sdHttp.get(url);\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissmanApp.Collector.Service\r\n * @description\r\n * # Collector Service\r\n * Factory in the weissmanApp.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'CollectorService';\r\n\tvar API_URL = '/api/';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = [\r\n\t\t'sd.Http.Service'\r\n\t];\r\n\r\n\tfunction Service(sdHttp) {\r\n\t\t// Public API.\r\n\t\tvar service = {\r\n\t\t\tgetCollectorsByState: getCollectorsByState,\r\n\t\t\tgetCollectorsByAssessor: getCollectorsByAssessor,\r\n\t\t\tgetCompanyCollectorVendorCodes: getCompanyCollectorVendorCodes,\r\n\t\t\tcreateCollectorVendorCode: createCollectorVendorCode,\r\n\t\t\tupdateCollectorVendorCode: updateCollectorVendorCode,\r\n\t\t\tdeleteCollectorVendorCode: deleteCollectorVendorCode\r\n\t\t};\r\n\t\treturn service;\r\n\r\n\t\tfunction getCollectorsByState(stateId) {\r\n\t\t\treturn sdHttp.get(`/api/collector/state/${stateId}`\r\n\t\t\t // This probably still needs optimizing; we should make another service call that\r\n // returns a smaller data set and use that.\r\n\t\t\t /*,\r\n\t\t\t\tcache: true*/\r\n\t\t\t);\r\n\t\t}\r\n\r\n\t\tfunction getCollectorsByAssessor(assessorId) {\r\n\t\t\treturn sdHttp.get('/api/collectorassociation', {\r\n\t\t\t\tparams: {\r\n\t\t\t\t\tassessorid: assessorId\r\n\t\t\t\t}\r\n\t\t\t // This probably still needs optimizing; we should make another service call that\r\n // returns a smaller data set and use that.\r\n\t\t\t /*,\r\n\t\t\t\tcache: true*/\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction getCompanyCollectorVendorCodes(companyID, getAll) {\r\n\t\t\treturn sdHttp.get('/api/Collector/Company/' + companyID + '/collectorVendor', {\r\n\t\t\t\tparams: {\r\n\t\t\t\t\tgetAll: getAll\r\n\t\t\t\t}\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\tfunction createCollectorVendorCode(vendorCode) {\r\n\t\t\treturn sdHttp.post('/api/vendorcode', vendorCode);\r\n\t\t}\r\n\r\n\t\tfunction updateCollectorVendorCode(vendorCode) {\r\n\t\t\treturn sdHttp.put('/api/vendorcode', vendorCode);\r\n\t\t}\r\n\r\n\t\tfunction deleteCollectorVendorCode(id) {\r\n\t\t\treturn sdHttp.delete('/api/vendorcode/' + id);\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:Contacts.Panel.Directive\r\n * @description\r\n * # Contacts Panel Directive\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdFileViewer', Directive);\r\n\r\n\tDirective.$inject = ['loadPdfIframeService'];\r\n\r\n\tfunction Directive(loadPdfIframeService) {\r\n\t\tvar directive = {\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tfileUrl: '@',\r\n\t\t\t\tfileMtype: '@',\r\n\t\t\t\treadOnly: '='\r\n\t\t\t},\r\n template: '',\r\n\t\t\tlink: link\r\n\t\t};\r\n\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element) {\r\n scope.$watch('fileUrl', function (newUrl) {\r\n\t\t\t\tvar objectElem = {};\r\n\r\n\t\t\t\tif (newUrl) {\r\n\t\t\t\t\tswitch (scope.fileMtype) {\r\n\t\t\t\t\t\tcase 'application/pdf':\r\n // When switching between PDFs in the attachment viewer the iframe will already be there\r\n var existingIframe = angular.element(element.find('iframe'));\r\n\r\n if (existingIframe.length == 0) {\r\n\t\t\t\t\t\t\t\telement.empty();\r\n\t\t\t\t\t\t\t\tobjectElem = angular.element(document.createElement('iframe'));\r\n loadPdfIframeService.initializePdfJs(objectElem[0], newUrl, scope.readOnly);\r\n element.append(objectElem);\r\n }\r\n else {\r\n loadPdfIframeService.updatePdfJs(existingIframe[0], newUrl);\r\n }\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tcase 'text/plain':\r\n\t\t\t\t\t\t\telement.empty();\r\n\r\n\t\t\t\t\t\t\t// we can't use embed because FF doesn't like it (requires special plugin for text embed)\r\n\t\t\t\t\t\t\t// lets read text from blob and place it onto the page\r\n\t\t\t\t\t\t\tvar xhr = new XMLHttpRequest();\r\n\t\t\t\t\t\t\tconsole.log('we are about to load blob: ', newUrl);\r\n\t\t\t\t\t\t\txhr.open('GET', newUrl, true);\r\n\t\t\t\t\t\t\txhr.responseType = 'blob';\r\n\t\t\t\t\t\t\txhr.onload = function (e) {\r\n\t\t\t\t\t\t\t\tconsole.log('loaded blob: ', e);\r\n\t\t\t\t\t\t\t\tif (this.status == 200) {\r\n\t\t\t\t\t\t\t\t\tvar myBlob = this.response;\r\n\t\t\t\t\t\t\t\t\t// myBlob is now the blob that the object URL pointed to.\r\n\t\t\t\t\t\t\t\t\tvar reader = new FileReader();\r\n\r\n\t\t\t\t\t\t\t\t\treader.onload = function (loadEndEvent) {\r\n\t\t\t\t\t\t\t\t\t\tconsole.log('loaded blob content: ', loadEndEvent);\r\n\t\t\t\t\t\t\t\t\t\tobjectElem = angular.element(document.createElement('pre'));\r\n\t\t\t\t\t\t\t\t\t\tobjectElem.attr('class', 'preview-window');\r\n\t\t\t\t\t\t\t\t\t\tobjectElem.attr('style', 'white-space: pre-wrap; word-break: break-word;');\r\n\t\t\t\t\t\t\t\t\t\tobjectElem[0].textContent = reader.result;\r\n\t\t\t\t\t\t\t\t\t\telement.append(objectElem);\r\n\t\t\t\t\t\t\t\t\t};\r\n\t\t\t\t\t\t\t\t\treader.readAsText(myBlob);\r\n\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t};\r\n\t\t\t\t\t\t\txhr.send();\r\n\r\n\t\t\t\t\t\t\t// this approach is cleaner but it doesn't work with Firefox ...\r\n\t\t\t\t\t\t\t//objectElem = angular.element(document.createElement('embed'));\r\n\t\t\t\t\t\t\t//objectElem.attr('src', newUrl);\r\n\t\t\t\t\t\t\t//objectElem.attr('type', scope.fileMtype);\r\n\t\t\t\t\t\t\t//objectElem.attr('class', 'preview-window');\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tdefault:\r\n\t\t\t\t\t\t\telement.empty();\r\n\t\t\t\t\t\t\tif (scope.fileMtype.split('/')[0] === 'image') {\r\n\t\t\t\t\t\t\t\tobjectElem = angular.element(document.createElement('img'));\r\n\t\t\t\t\t\t\t\tobjectElem.attr('src', newUrl);\r\n\t\t\t\t\t\t\t\tobjectElem.attr('class', 'img-responsive preview-window-image');\r\n\t\t\t\t\t\t\t\tobjectElem.attr('alt', 'Image File Missing');\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t//} else {\r\n\t\t\t\t\t\t\t//\tobjectElem = angular.element(document.createElement('a'));\r\n\t\t\t\t\t\t\t//\tobjectElem.attr('href', newUrl);\r\n\t\t\t\t\t\t\t//\tobjectElem.html('Click to download or view in native application.');\r\n\t\t\t\t\t\t\t//}\r\n\t\t\t\t\t\t\telement.append(objectElem);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\t\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Site.Activity.Panel.Controller';\r\n\r\n\tangular.module('weissmanApp')\r\n\t\t.directive('sdActivityAnalysis', directive);\r\n\r\n\tfunction directive() {\r\n\t\treturn {\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tsiteId: '=',\r\n\t\t\t\tparcelId: '=',\r\n\t\t\t\tparcelYears: '='\r\n\t\t\t},\r\n\t\t\ttemplateUrl: 'app/Common/Activity/_activityPanel.html',\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: APP_SOURCE,\r\n\t\t\tcontrollerAs: 'vm'\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * @ngdoc function\r\n\t * @name weissmanApp.controller:Site.Activity.Controller\r\n\t * @description\r\n\t * # Site.Activity.Controller\r\n\t * Controller of the weissmanApp\r\n\t */\r\n\tangular.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'ParcelService',\r\n\t\t'$stateParams',\r\n\t\t'sd.Activity.Service',\r\n\t\t'$uibModal',\r\n\t\t'$rootScope',\r\n\t\t'$q',\r\n 'productAnalyticsService'\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(parcelService, $stateParams, activityService, $uibModal, $rootScope, $q, productAnalyticsService) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.noDataYet = true;\r\n\t\tvm.parcels = [];\r\n\t\tvm.annualData = [];\r\n\t\tvm.propertyCharacteristics = [];\r\n\t\tvm.openParcelFilter = openParcelFilter;\r\n\t\tvm.parcelFilterList = [];\r\n\t\tvm.useLatestActualized = false;\r\n\t\tvm.loading = false;\r\n\r\n\t\t//vm.activityData = activityService.getSampleData();\r\n\r\n\t\tvm.getDataByYear = getDataByYear;\r\n\t\tvm.siteId = $stateParams.siteId\r\n\t\tvm.getSummaryColumnClass = getSummaryColumnClass;\r\n\t\tvm.getGraphColumnClass = getGraphColumnClass;\r\n\r\n\t\tvm.parcelFilterSub = null;\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n var storedParcelFilterList = sessionStorage['ws_analysisIncludedParcels' + vm.siteId];\r\n vm.parcelFilterList = storedParcelFilterList ? JSON.parse(storedParcelFilterList) : [];\r\n\r\n\t\t\tvm.parcelFilterSub = activityService.userSessionFilterCache$.subscribe(async (cache) => {\r\n\t\t\t\tconst cachedFilters = cache[vm.siteId];\r\n\t\t\t\tif (cachedFilters?.length && !_.isEqual(vm.parcelFilterList, cachedFilters)) {\r\n\t\t\t\t\tvm.parcelFilterList = cachedFilters;\r\n\t\t\t\t\tif (!vm.noDataYet) {\r\n\t\t\t\t\t\tawait getDataByYear();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\tgetYears().then(function (result) {\r\n\t\t\t\tvm.availableYears = result;\r\n\r\n\t\t\t\tgetDataByYear(true).then(function () {\r\n const maxYear = _.maxBy(vm.annualData, 'year');\r\n if(maxYear){\r\n vm.selectedYear = maxYear.year;\r\n }\r\n\t\t\t\t\tif (!vm.parcelFilterList.length) {\r\n\t\t\t\t\t\tvm.parcelFilterList = vm.parcels.filter(x => x.activityStatus === 'Active')\r\n .map(x => x.parcelID);\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\t\t\t});\r\n\r\n\t\t\tvm.$onDestroy = function () {\r\n\t\t\t\tvm.parcelFilterSub?.unsubscribe();\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction getYears() {\r\n\t\t\tconst defer = $q.defer();\r\n\r\n\t\t\tif (vm.parcelYears) {\r\n\t\t\t\tdefer.resolve(vm.parcelYears);\r\n\t\t\t} else {\r\n\t\t\t\tparcelService.getAvailableYears(vm.siteId)\r\n\t\t\t\t\t.then(function (result) {\r\n\t\t\t\t\t\tdefer.resolve(result)\r\n\t\t\t\t\t})\r\n\t\t\t}\r\n\r\n\t\t\treturn defer.promise;\r\n\t\t}\r\n\r\n\t\tasync function getDataByYear(useLatestActualized, fromUserChange) {\r\n\t\t\tvm.loading = true;\r\n\r\n if (fromUserChange) {\r\n productAnalyticsService.logEvent('click-activity-analysis-panel', { viewSitePortfolioAnalysis: 'Tax Year' });\r\n }\r\n\r\n\t\t\ttry {\r\n\t\t\t\tvm.useLatestActualized = useLatestActualized;\r\n\r\n\t\t\t\tconst data = vm.parcelId\r\n\t\t\t\t\t? await activityService.getDataByParcel(vm.siteId, vm.selectedYear, vm.parcelId, useLatestActualized)\r\n\t\t\t\t\t: await activityService.getDataByYear(vm.siteId, vm.selectedYear, vm.parcelFilterList, useLatestActualized);\r\n\r\n\t\t\t\tprocessData(data)\r\n\t\t\t} finally {\r\n\t\t\t\tvm.loading = false;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction processData(result) {\r\n\t\t\tvm.activityData = result;\r\n\r\n\t\t\tif (vm.parcelId) {\r\n\t\t\t\tvm.activityData.parcelFilterList = [vm.parcelId];\r\n\t\t\t} else {\r\n\t\t\t\tvm.activityData.parcelFilterList = vm.parcelFilterList; // we will need it if we want to load data for all years from within the table\r\n\t\t\t}\r\n\r\n\t\t\tvm.activityData.siteId = vm.siteId;\r\n\t\t\tvm.activityData.useLatestActualized = vm.useLatestActualized;\r\n\r\n\r\n\t\t\tvm.activityData.availableYears = vm.availableYears;\r\n\r\n\t\t\tvm.parcels = _.map(result.parcels, function (element) {\r\n\t\t\t\treturn _.extend({}, element, {\r\n\t\t\t\t\tisIncluded: true\r\n\t\t\t\t});\r\n\t\t\t});\r\n\r\n\t\t\tvm.annualData = result.annualData;\r\n\t\t\tvm.propertyCharacteristics = result.propertyCharacteristics;\r\n\r\n\t\t\tvm.noDataYet = false;\r\n\t\t}\r\n\r\n\t\tasync function openParcelFilter() {\r\n\t\t\tconst result = await activityService.openParcelFilter(vm.parcels, vm.parcelFilterList);\r\n if (!result) {\r\n return;\r\n }\r\n\t\t\tactivityService.updateParcelFilterCacheForSite(vm.siteId, result);\r\n\t\t}\r\n\r\n\t\tfunction getSummaryColumnClass() {\r\n\t\t\treturn vm.parcelId ? 'col-sm-4' : 'col-sm-5';\r\n\t\t}\r\n\r\n\t\tfunction getGraphColumnClass() {\r\n\t\t\treturn vm.parcelId ? 'col-sm-8' : 'col-sm-7';\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissmanApp.Activity.Status.Service\r\n * @description\r\n * # Activity.Status Service\r\n * Factory in the weissmanApp.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Activity.Status.Service';\r\n\tvar SERVICE_URL = '/api/activitystatus/';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = [\r\n\t\t'sd.Http.Service',\r\n\t];\r\n\r\n\tfunction Service(sdHttp) {\r\n\t\t// Public API.\r\n\t\tvar service = {\r\n\t\t\tget: getStatuses\r\n\t\t};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction getStatuses() {\r\n\t\t\tvar config = {};\r\n\r\n\t\t\treturn sdHttp.get(SERVICE_URL, config)\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('activitySummaryTable', activitySummaryTableDirective);\r\n\r\n\tactivitySummaryTableDirective.$inject = ['$rootScope', 'ActivityPanelModes', 'productAnalyticsService'];\r\n\r\n\tfunction activitySummaryTableDirective($rootScope, ActivityPanelModes, productAnalyticsService) {\r\n\r\n\t\tvar directive = {\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Common/Activity/_summaryTable.html',\r\n\t\t\treplace: true,\r\n\t\t\tscope: {\r\n\t\t\t\tannualData: '=',\r\n\t\t\t\tpropCharacteristics: '=',\r\n\t\t\t\tselectedYear: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope) {\r\n\r\n\t\t\tscope.ActivityPanelModes = ActivityPanelModes;\r\n\t\t\t//scope.Math = window.Math;\r\n\r\n\t\t\tfunction activate() {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tscope.appealStatus = '';\r\n\t\t\t\t\tgetPropertyChracteristics();\r\n\r\n\t\t\t\t\tscope.currentYear = _.find(scope.annualData, { 'year': scope.selectedYear });\r\n\r\n\t\t\t\t\tscope.currentYear.totalFMV = window.Math.round(scope.currentYear.totalFMV);\r\n\r\n\t\t\t\t\tscope.fmvProjected = _.some(scope.currentYear.fmvByPropertyType, { isProjected: true });\r\n\r\n\t\t\t\t\ttry {\r\n\t\t\t\t\t\tscope.recentSavings = _.filter(scope.annualData, function(item) {\r\n\t\t\t\t\t\t\treturn item.taxSavings.savings > 0;\r\n\t\t\t\t\t\t});\r\n\t\t\t\t\t} catch(ex) {\r\n\t\t\t\t\t\tconsole.log('Savings not present: '+ex);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\ttry {\r\n\t\t\t\t\t\tscope.totalTaxes = _.reduce(scope.currentYear.collectorTaxes, function(sum, n) {\r\n\t\t\t\t\t\t\treturn new Decimal(sum).plus(n.tax).toNumber();\r\n\t\t\t\t\t\t}, 0);\r\n\t\t\t\t\t\tscope.taxProjected = _.some(scope.currentYear.collectorTaxes, { isProjected: true });\r\n\t\t\t\t\t} catch(ex) {\r\n\t\t\t\t\t\tconsole.log('Tax Collector not present: '+ex);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tgetAppealsStatusLabel(scope.currentYear.taxSavings.status);\r\n\t\t\t\t} catch(ex){\r\n\t\t\t\t\tconsole.log('ERROR: '+ex);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction getAppealsStatusLabel(status) {\r\n\t\t\t\tswitch(status) {\r\n\t\t\t\t\tcase 'No Appeal':\r\n\t\t\t\t\t\tscope.appealStatus = 'No'\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase 'N/A':\r\n\t\t\t\t\t\tscope.appealStatus = 'N/A'\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tdefault:\r\n\t\t\t\t\t\tscope.appealStatus = status;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction getPropertyChracteristics() {\r\n\t\t\t\tscope.acres = _.find(scope.propCharacteristics, {'label': 'Land Acreage' });\r\n\t\t\t\tscope.impsSqFt = _.find(scope.propCharacteristics, {'label': 'Imps. SqFt' });\r\n\t\t\t\tscope.units = _.find(scope.propCharacteristics, {'label': 'Units' });\r\n\t\t\t}\r\n\r\n\t\t\tscope.updateChartType = function(chartType) {\r\n if (chartType === 'recentAppeals') {\r\n productAnalyticsService.logEvent('click-activity-analysis-panel', { viewSitePortfolioAnalysis: 'Appeal Savings' });\r\n } else {\r\n productAnalyticsService.logEvent('click-activity-analysis-panel', { viewSitePortfolioAnalysis: 'FMV' });\r\n }\r\n\r\n\t\t\t\t$rootScope.$broadcast('chartTypeChange', chartType);\r\n\t\t\t}\r\n\r\n\t\t\tscope.$watch('annualData', function(){\r\n\t\t\t\tactivate();\r\n\t\t\t}, true);\r\n\r\n\t\t\tscope.$watch('propCharacteristics', function () {\r\n\t\t\t\tactivate();\r\n\t\t\t}, true);\r\n\r\n\r\n\t\t\tactivate();\r\n\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'activityDeadlineFooter';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive(APP_SOURCE, Directive);\r\n\r\n\tDirective.$inject = [\r\n\t\t'sd.Activity.Service',\r\n '$uibModal'\r\n\t];\r\n\r\n\tfunction Directive(activityService, $uibModal) {\r\n\t\tvar directive = {\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tsiteId: '=',\r\n\t\t\t\tparcelId: '=',\r\n isModal: '='\r\n\t\t\t},\r\n\t\t\ttemplateUrl: 'app/Common/Activity/Deadline-Footer/_activityDeadlineFooter.html',\r\n\t\t\tlink: link\r\n\t\t};\r\n\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element) {\r\n\t\t\tscope.onRow = 0;\r\n\r\n\t\t\tscope.deadlineDate = deadlineDate;\r\n\t\t\tscope.getDeadlineLabel = getDeadlineLabel;\r\n\t\t\tscope.setPopoverContent = setPopoverContent;\r\n\t\t\tscope.getValue = getValue;\r\n\t\t\tscope.getPlacement = getPlacement;\r\n\t\t\tscope.filterSections = filterSections;\r\n\t\t\tscope.changeRow = changeRow;\r\n\r\n\t\t\tactivate();\r\n\r\n\t\t\tfunction activate() {\r\n\t\t\t\tactivityService.getDeadlineData(scope.siteId, scope.parcelId)\r\n\t\t\t\t\t.then(function (result) {\r\n\t\t\t\t\t\tscope.footerSections = _.chain(result)\r\n\t\t\t\t\t\t.map(function (data, deadlineType) {\r\n\t\t\t\t\t\t\treturn angular.extend(data, {\r\n\t\t\t\t\t\t\t\tdeadlineType: deadlineType\r\n\t\t\t\t\t\t\t})\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.filter('date')\r\n\t\t\t\t\t\t.value();\r\n\t\t\t\t\t})\r\n\t\t\t}\r\n\r\n\t\t\tfunction deadlineDate(section) {\r\n\t\t\t\tvar sortVal = section.date === 'Pending' ? 0 : new Date(section.date).getTime();\r\n\t\t\t\tswitch (section.deadlineType) {\r\n\t\t\t\t\tcase 'appealHearing': return sortVal;\r\n\t\t\t\t\tcase 'appealDeadline': return sortVal + 1;\r\n\t\t\t\t\tcase 'paymentDeadline': return sortVal + 2;\r\n\t\t\t\t\tcase 'complianceDeadline': return sortVal + 3;\r\n\t\t\t\t\tdefault: return sortVal;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction getDeadlineLabel(type) {\r\n\t\t\t\tswitch (type) {\r\n\t\t\t\t\tcase 'appealHearing': return 'Next Appeal Hearing';\r\n\t\t\t\t\tcase 'appealDeadline': return 'Next Appeal Deadline';\r\n\t\t\t\t\tcase 'paymentDeadline': return 'Next Payment Deadline';\r\n\t\t\t\t\tcase 'complianceDeadline': return 'Next Filing Deadline';\r\n\t\t\t\t\tdefault: return type;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction setPopoverContent(section) {\r\n\t\t\t\tvar label;\r\n\t\t\t\tswitch (section.deadlineType) {\r\n\t\t\t\t\tcase 'appealDeadline':\r\n\t\t\t\t\t\tlabel = 'Revision';\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase 'appealHearing':\r\n\t\t\t\t\t\tlabel = 'Appeal Level';\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase 'paymentDeadline':\r\n\t\t\t\t\t\tlabel = 'Collector';\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase 'complianceDeadline':\r\n\t\t\t\t\t\tlabel = 'Filing Description';\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t\tscope.popoverContent = {\r\n\t\t\t\t\tlabel: label,\r\n\t\t\t\t\tdata: section\r\n\t\t\t\t};\r\n\t\t\t}\r\n\r\n\t\t\tfunction getValue(year) {\r\n\t\t\t\tvar valArr = _.chain(year)\r\n\t\t\t\t\t.omit('annualYear')\r\n\t\t\t\t\t.values()\r\n\t\t\t\t\t.compact()\r\n\t\t\t\t\t.value()\r\n\t\t\t\treturn valArr[0];\r\n\t\t\t}\r\n\r\n\t\t\tfunction getPlacement(index) {\r\n\t\t\t\tswitch (index) {\r\n\t\t\t\t\tcase 0: return 'top-left';\r\n\t\t\t\t\tcase 1: return 'top';\r\n\t\t\t\t\tcase 2: return 'top-right';\r\n\t\t\t\t\tdefault: return 'top';\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction filterSections(section, i) {\r\n\t\t\t\treturn Math.floor(i/3) === scope.onRow;\r\n\t\t\t}\r\n\r\n\t\t\tfunction changeRow() {\r\n\t\t\t\tscope.onRow = scope.onRow ? 0 : 1;\r\n\t\t\t}\r\n\r\n\t\t\tscope.openModal = function() {\r\n\t\t\t if(!scope.parcelId) {\r\n $uibModal.open({\r\n component: 'modalComponent',\r\n templateUrl: 'app/Common/Activity/Deadline-Footer/parcelActivitySummaryModal.html',\r\n controller: ['siteId', '$uibModalInstance', function(siteId, $uibModalInstance) {\r\n this.siteId = siteId;\r\n this.closeModal = function () {\r\n $uibModalInstance.dismiss();\r\n };\r\n }],\r\n controllerAs: 'vm',\r\n resolve: {\r\n siteId: function() {\r\n return scope.siteId;\r\n }\r\n },\r\n size: 'lg',\r\n windowTopClass: 'fixed-height-modal',\r\n\t\t\t\t\t\twindowClass: 'show',\r\n\t\t\t\t\t\tbackdropClass: 'show',\r\n });\r\n }\r\n }\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc directive\r\n * @name weissman.directive:Activity\r\n * @description\r\n * # Activity\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sdActivity';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive(APP_SOURCE, Directive);\r\n\r\n\tDirective.$inject = [\r\n\t\t'ActivityPanelModes',\r\n\t\t'$rootScope',\r\n\t\t'sd.Activity.Service',\r\n 'productAnalyticsService'\r\n\t];\r\n\r\n\tfunction Directive(ActivityPanelModes, $rootScope, activityService, productAnalyticsService) {\r\n\t\tvar directive = {\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Common/Activity/SD.Activity.Directive.Template.html',\r\n\t\t\tscope: {\r\n\t\t\t\tconfig: '=',\r\n\t\t\t\tparcelId: '='\r\n\t\t\t},\r\n\t\t\tlink: link,\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element) {\r\n\r\n\t\t if(!sessionStorage['ws_analysisGraphChartSelection']) {\r\n scope.activityMode = 'graph';\r\n } else {\r\n\t\t scope.activityMode = sessionStorage['ws_analysisGraphChartSelection'];\r\n }\r\n\r\n\t\t\tscope.reflowChart = function () {\r\n\t\t\t\tconsole.log('reflowing');\r\n\t\t\t\tHighcharts.fireEvent(window, 'resize')\r\n\t\t\t}\r\n\r\n scope.analyticsEvent = function (selection) {\r\n productAnalyticsService.logEvent('click-activity-analysis-panel', { viewSitePortfolioAnalysis: selection });\r\n }\r\n\r\n\t\t\tscope.chartType = ActivityPanelModes.totalFMV;\r\n\t\t\tscope.lastConfig = scope.config;\r\n\r\n\t\t\t//console.log('sdActivity - scope.config', scope.config);\r\n\t\t\tscope.graphConfig = activityService.createGraphConfig(scope.config, ActivityPanelModes.totalFMV);\r\n\t\t\t//console.log('scope.graphConfig', scope.graphConfig);\r\n\r\n\t\t\t$rootScope.$on('chartTypeChange', function (event, chartType) {\r\n\t\t\t\t//console.log('sdActivity - received event chartTypeChange ', chartType);\r\n\r\n\t\t\t\tscope.chartType = chartType;\r\n\t\t\t\t// we have to change our model and redraw chart and table\r\n\t\t\t\t// we will not touch scope.config (it's shared by other components)\r\n\t\t\t\t//\r\n\t\t\t\tscope.graphConfig = activityService.createGraphConfig(scope.lastConfig, chartType);\r\n\r\n\t\t\t\t//console.log('sdActivity - scope.graphConfig has been updated ', scope.graphConfig);\r\n\r\n\t\t\t});\r\n\r\n\t\t\tscope.$watch(\"config\", function (newValue, oldValue) {\r\n\t\t\t\t//This gets called when data changes.\r\n\t\t\t\t//console.log('sdActivity - config changed! ', newValue)\r\n\t\t\t\tscope.lastConfig = newValue;\r\n\t\t\t\tscope.graphConfig = activityService.createGraphConfig(newValue, scope.chartType);\r\n\t\t\t});\r\n\r\n\t\t\tscope.$watch('activityMode', function(newValue) {\r\n sessionStorage['ws_analysisGraphChartSelection'] = newValue;\r\n })\r\n\r\n\t\t}\r\n\t};\r\n})();\r\n\r\n\r\n\r\n","(function () {\r\n\t'use strict';\r\n\r\n\t/**\r\n\t * @ngdoc directive\r\n\t * @name weissman.directive:Activity Table\r\n\t * @description\r\n\t * # Activity Table\r\n\t */\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdActivityTable', sdActivityTableDirective);\r\n\r\n\tsdActivityTableDirective.$inject = [\r\n\t\t'$filter',\r\n\t\t'PropCharNames',\r\n\t\t'sd.Activity.Service',\r\n\t\t'ActivityPanelModes'\r\n\t];\r\n\r\n\tfunction sdActivityTableDirective($filter, PropCharNames, activityService, ActivityPanelModes) {\r\n\r\n\t\tvar directive = {\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Common/Activity/SD.Activity.Table.Directive.Template.html',\r\n\t\t\tscope: {\r\n\t\t\t\tconfig: '=',\r\n\t\t\t\toriginalConfig: '=',\r\n\t\t\t\tparcelId: '='\r\n\t\t\t},\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element) {\r\n\r\n\t\t\t//if (scope.config) {\r\n\t\t\t//\tconsole.log('');\r\n\t\t\t//\tconsole.log('');\r\n\t\t\t//\tconsole.log('loading table - scope.config.chartType = ', scope.config.chartType);\r\n\t\t\t//\tconsole.log('');\r\n\t\t\t//\tconsole.log('');\r\n\t\t\t//}\r\n\t\t\tscope.ActivityPanelModes = ActivityPanelModes;\r\n\r\n\t\t\tscope.$watch(\"config\", function (newValue, oldValue) {\r\n\t\t\t\t//This gets called when data changes.\r\n\t\t\t\tconsole.log('sdActivityTable - config changed! ', newValue)\r\n\t\t\t\tscope.showingAllYears = newValue.loadedAllYears;\r\n\t\t\t\t//scope.lastConfig = newValue;\r\n\t\t\t\t//scope.graphConfig = activityService.createGraphConfig(newValue, scope.chartType);\r\n\t\t\t});\r\n\r\n\r\n\t\t\tscope.showingAllYears = false;\r\n\r\n\t\t\tscope.PropCharNames = PropCharNames;\r\n\r\n\t\t\tscope.getCellValue = function (seriesItem, year, symbol, fractionSize) {\r\n\t\t\t\tvar xAxisCategoryIndex = scope.config.xAxis.categories.indexOf(year);\r\n\t\t\t\tvar val = seriesItem.data[xAxisCategoryIndex].y;\r\n\r\n\t\t\t\treturn val || val === 0 ? $filter('currency')(val, symbol, fractionSize): '';\r\n\t\t\t}\r\n\r\n\t\t\tscope.isProjected = function (seriesItem, year) {\r\n\t\t\t\tvar xAxisCategoryIndex = scope.config.xAxis.categories.indexOf(year);\r\n\t\t\t\treturn seriesItem.data[xAxisCategoryIndex].isProjected;\r\n\t\t\t}\r\n\r\n\t\t\tscope.getTotalForSingleYear = function (year) {\r\n\t\t\t\tvar result = 0;\r\n\t\t\t\tvar xAxisCategoryIndex = scope.config.xAxis.categories.indexOf(year);\r\n\t\t\t\t_.forEach(scope.config.series, function (item, key) {\r\n\t\t\t\t\tif (item.data[xAxisCategoryIndex].originalValue)\r\n\t\t\t\t\t\tresult = new Decimal(result).plus(item.data[xAxisCategoryIndex].originalValue).toNumber();\r\n\t\t\t\t})\r\n\r\n\t\t\t\t//console.log('getTotalForSingleYear - ', year, result);\r\n\r\n\t\t\t\treturn result;\r\n\t\t\t}\r\n\r\n\t\t\tscope.isProjectedFmvForSingleYear = function (year) {\r\n\t\t\t\tvar result = false;\r\n\t\t\t\tvar xAxisCategoryIndex = scope.config.xAxis.categories.indexOf(year);\r\n\t\t\t\t_.forEach(scope.config.series, function (item, key) {\r\n\t\t\t\t\tresult = result || item.data[xAxisCategoryIndex].isProjected;\r\n\t\t\t\t})\r\n\r\n\t\t\t\treturn result;\r\n\t\t\t}\r\n\r\n\r\n\t\t\tscope.getTotalFmvByPropValueForSingleYear = function (year, propCharName) {\r\n\t\t\t\tvar totalFmv = scope.getTotalForSingleYear(year);\r\n\r\n\t\t\t\tif (propCharName == PropCharNames.SQFT &&\r\n (scope.config.chartType == ActivityPanelModes.landFMVPerSqFt || scope.config.chartType == ActivityPanelModes.landFMVPerAcre)) {\r\n\t\t\t\t\t// special case, instead of sqft attribute we will use acreage /43560\r\n\t\t\t\t\t//\r\n\t\t\t\t\tvar i = _.findIndex(scope.config.propertyCharacteristics, function (o) { return o.label == PropCharNames.ACREAGE });\r\n\t\t\t\t\tif (i >= 0) {\r\n\t\t\t\t\t\treturn new Decimal(totalFmv).dividedBy(parseFloat(scope.config.propertyCharacteristics[i].value)).dividedBy(43560).toNumber();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tvar i = _.findIndex(scope.config.propertyCharacteristics, function (o) { return o.label == propCharName });\r\n\t\t\t\t\tif (i >= 0) {\r\n\t\t\t\t\t\treturn new Decimal(totalFmv).dividedBy(parseFloat(scope.config.propertyCharacteristics[i].value)).toNumber();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\treturn -1;\r\n\t\t\t}\r\n\r\n\r\n\t\t\tscope.getTotalColumnTitle = function () {\r\n\t\t\t\tswitch (scope.config.chartType) {\r\n\t\t\t\t\tcase ActivityPanelModes.totalFMV:\r\n\t\t\t\t\tcase ActivityPanelModes.totalFMVPerSqFt:\r\n\t\t\t\t\tcase ActivityPanelModes.totalFMVPerUnit:\r\n\t\t\t\t\t\treturn 'Total FMV';\r\n\t\t\t\t\tcase ActivityPanelModes.landFMVPerSqFt:\r\n\t\t\t\t\tcase ActivityPanelModes.landFMVPerAcre:\r\n\t\t\t\t\t\treturn 'Land FMV'\r\n\t\t\t\t\tcase ActivityPanelModes.totalTaxes:\r\n\t\t\t\t\t\treturn 'Total Tax'\r\n\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\r\n\t\t\tscope.showColumn = function (propCharName, arrayOfAllowedModes) {\r\n\t\t\t\tif (arrayOfAllowedModes.indexOf(scope.config.chartType) < 0)\r\n\t\t\t\t\treturn false;\r\n\r\n\t\t\t\tif (propCharName === '')\r\n\t\t\t\t\treturn true;\r\n\r\n\t\t\t\tvar i = _.findIndex(scope.config.propertyCharacteristics, function (o) { return o.label == propCharName });\r\n\r\n\t\t\t\t// do we have this prop char at all?\r\n\t\t\t\tif (i < 0)\r\n\t\t\t\t\treturn false;\r\n\r\n\t\t\t\t// do we have any value?\r\n\t\t\t\tif (scope.config.propertyCharacteristics[i].value == 0)\r\n\t\t\t\t\treturn false;\r\n\r\n\t\t\t\tswitch (propCharName) {\r\n\t\t\t\t\tcase PropCharNames.ACREAGE:\r\n\t\t\t\t\tcase PropCharNames.UNITS:\r\n\t\t\t\t\t\treturn true;\r\n\t\t\t\t\tcase PropCharNames.SQFT:\r\n\r\n\t\t\t\t\t\tswitch (scope.config.chartType) {\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerUnit:\r\n\t\t\t\t\t\t\t\treturn true;\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMV:\r\n\t\t\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerAcre:\r\n\t\t\t\t\t\t\t\t// only if acreage is not here or acreage < 10\r\n\t\t\t\t\t\t\t\tvar k = _.findIndex(scope.config.propertyCharacteristics, function (o) { return o.label == PropCharNames.ACREAGE });\r\n\t\t\t\t\t\t\t\tif (k < 0)\r\n\t\t\t\t\t\t\t\t\treturn true;\r\n\t\t\t\t\t\t\t\treturn (scope.config.propertyCharacteristics[k].value < 10)\r\n\t\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// some othre property name - just hide\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\r\n\t\t\tscope.getColumnTitle = function (propCharName) {\r\n\t\t\t\tswitch (propCharName) {\r\n\r\n\t\t\t\t\tcase PropCharNames.SQFT:\r\n\t\t\t\t\t\tswitch (scope.config.chartType) {\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerUnit:\r\n\t\t\t\t\t\t\t\treturn '$/SqFt';\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMV:\r\n\t\t\t\t\t\t\t\treturn 'error!';\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerAcre:\r\n\t\t\t\t\t\t\t\treturn 'Land $/SqFt';\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tbreak;\r\n\r\n\r\n\t\t\t\t\tcase PropCharNames.UNITS:\r\n\t\t\t\t\t\tswitch (scope.config.chartType) {\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerUnit:\r\n\t\t\t\t\t\t\t\treturn '$/Unit';\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMV:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerAcre:\r\n\t\t\t\t\t\t\t\treturn 'error!';\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tbreak;\r\n\r\n\t\t\t\t\tcase PropCharNames.ACREAGE:\r\n\t\t\t\t\t\tswitch (scope.config.chartType) {\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerUnit:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMV:\r\n\t\t\t\t\t\t\t\treturn 'error!';\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerAcre:\r\n\t\t\t\t\t\t\t\treturn 'Land $/Acre';\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tscope.getFooterTitle = function (propCharName) {\r\n\t\t\t\tswitch (propCharName) {\r\n\r\n\t\t\t\t\tcase PropCharNames.SQFT:\r\n\t\t\t\t\t\tswitch (scope.config.chartType) {\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerUnit:\r\n\t\t\t\t\t\t\t\treturn 'Imps. SqFt';\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMV:\r\n\t\t\t\t\t\t\t\treturn 'error!';\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerAcre:\r\n\t\t\t\t\t\t\t\treturn 'Land SqFt';\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tbreak;\r\n\r\n\r\n\t\t\t\t\tcase PropCharNames.UNITS:\r\n\t\t\t\t\t\tswitch (scope.config.chartType) {\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerUnit:\r\n\t\t\t\t\t\t\t\treturn 'Units';\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMV:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerAcre:\r\n\t\t\t\t\t\t\t\treturn 'error!';\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tbreak;\r\n\r\n\t\t\t\t\tcase PropCharNames.ACREAGE:\r\n\t\t\t\t\t\tswitch (scope.config.chartType) {\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMVPerUnit:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.totalFMV:\r\n\t\t\t\t\t\t\t\treturn 'error!';\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerSqFt:\r\n\t\t\t\t\t\t\tcase ActivityPanelModes.landFMVPerAcre:\r\n\t\t\t\t\t\t\t\treturn 'Land Acreage';\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tscope.getPropCharValue = function (propCharName) {\r\n\t\t\t //This was added to handle a special case. The whole panel was written assuming the values would be the rap property\r\n //characteristic values, but this assumption was wrong. Imps Sq Ft !== Land Sq Ft, one is a calculated value. So this\r\n //catches that condition and runs the calculation.\r\n\t\t\t if(propCharName === PropCharNames.SQFT &&\r\n (scope.config.chartType === ActivityPanelModes.landFMVPerSqFt ||\r\n scope.config.chartType === ActivityPanelModes.landFMVPerAcre)) {\r\n\t\t\t return calculateLandSqFt();\r\n }\r\n\t\t\t\tvar propChar = _.find(scope.config.propertyCharacteristics, { 'label': propCharName });\r\n\t\t\t\treturn propChar.value;\r\n\t\t\t}\r\n\r\n\t\t\tfunction calculateLandSqFt() {\r\n\t\t\t //From Grant, calculation is Land Acreage * 43,560)\r\n var landAcreage = _.find(scope.config.propertyCharacteristics, {'label': PropCharNames.ACREAGE});\r\n\t\t\t return parseFloat(landAcreage.value) * 43560;\r\n }\r\n\r\n\t\t\tscope.loadAllYears = function () {\r\n\t\t\t\t// we want to call api and update scope.config\r\n\t\t\t\t//\r\n\r\n\t\t\t\tif (scope.parcelId) {\r\n\t\t\t\t\tactivityService.getDataByParcelAllYears(scope.config.siteId, scope.parcelId)\r\n\t\t\t\t\t\t.then(formatData)\r\n\t\t\t\t} else {\r\n\t\t\t\t\tactivityService.getDataForAllYears(scope.config.siteId, scope.config.parcelFilterList)\r\n\t\t\t\t\t\t.then(formatData);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction formatData(result) {\r\n\t\t\t\tconsole.log('table directive - activityService.getDataForAllYears - result', result);\r\n\r\n\t\t\t\t// convert received data to the right format\r\n\t\t\t\t// we don't want to replace\r\n\r\n\t\t\t\t// uodate original config\r\n\t\t\t\tscope.originalConfig.annualData = result.annualData;\r\n\t\t\t\tscope.originalConfig.propertyCharacteristics = result.propertyCharacteristics;\r\n\r\n\t\t\t\tvar convertedConfig = activityService.createGraphConfig(result, scope.config.chartType);\r\n\r\n\t\t\t\tscope.config.series = convertedConfig.series;\r\n\t\t\t\tscope.config.xAxis = convertedConfig.xAxis;\r\n\t\t\t\tscope.config.useLatestActualized = scope.originalConfig.useLatestActualized;\r\n\t\t\t\tscope.config.loadedAllYears = true;\r\n\t\t\t\tscope.config.availableYears = scope.originalConfig.availableYears;\r\n\t\t\t\tscope.originalConfig.loadedAllYears = true;\r\n\r\n\t\t\t\t//console.log('table directive - converted scope.config ', scope.config);\r\n\t\t\t\tscope.showingAllYears = true;\r\n\r\n\t\t\t}\r\n\r\n\t\t\tscope.getPrecision = function (fieldName) {\r\n\r\n\t\t\t\tif (fieldName == ActivityPanelModes.totalFMV && scope.config.chartType != ActivityPanelModes.totalTaxes)\r\n\t\t\t\t\treturn 0;\r\n\r\n\t\t\t\tswitch (scope.config.chartType) {\r\n\t\t\t\t\tcase ActivityPanelModes.totalFMV:\r\n\t\t\t\t\t\treturn 0;\r\n\t\t\t\t\tcase ActivityPanelModes.totalFMVPerSqFt:\r\n\t\t\t\t\tcase ActivityPanelModes.totalFMVPerUnit:\r\n\t\t\t\t\tcase ActivityPanelModes.landFMVPerSqFt:\r\n\t\t\t\t\tcase ActivityPanelModes.landFMVPerSqFt:\r\n\t\t\t\t\tcase ActivityPanelModes.landFMVPerAcre:\r\n\t\t\t\t\t\treturn 2;\r\n\t\t\t\t\tcase ActivityPanelModes.totalTaxes:\r\n\t\t\t\t\tcase \"recentAppeals\":\r\n\t\t\t\t\t\treturn 2;\r\n\t\t\t\t}\r\n\t\t\t\treturn 0;\r\n\t\t\t}\r\n\r\n\t\t\tscope.getAppealCellValue = function (year, fieldName) {\r\n\r\n\t\t\t\tvar annualYearIndex = scope.config.xAxis.categories.indexOf(year);\r\n\t\t\t\tvar fieldValue = scope.config.series[1].data[annualYearIndex][fieldName];\r\n\r\n\t\t\t\tif (!fieldValue)\r\n\t\t\t\t\treturn '';\r\n\r\n\t\t\t\t// is this a number? if so, format and return it\r\n\t\t\t\t//\r\n\t\t\t\tif (isFinite(fieldValue)) {\r\n\r\n\t\t\t\t\tif (fieldName == 'savings')\r\n\t\t\t\t\t\treturn $filter('currency')(fieldValue, '$', 0)\r\n\t\t\t\t\telse\r\n\t\t\t\t\t\treturn $filter('currency')(fieldValue, '', 0)\r\n\t\t\t\t}\r\n\t\t\t\treturn fieldValue;\r\n\t\t\t}\r\n\r\n\r\n\t\t}\r\n\t};\r\n})();\r\n","'use strict';\r\n\r\n/**\r\n * @ngdoc directive\r\n * @name weissman.directive:Highcharts\r\n * @description\r\n * # Highcharts\r\n */\r\n\r\nangular.module('weissmanApp')\r\n .directive('sdHighchartsColumn', function () {\r\n \treturn {\r\n \t\trestrict: 'E',\r\n \t\treplace: false,\r\n \t\ttemplate: '
',\r\n \t\tscope: {\r\n \t\t\tconfig:'='\r\n \t\t},\r\n \t\tlink: function (scope, element) {\r\n \t\t\tscope.updated = false;\r\n \t\t\tscope.targetElement = element[0];\r\n \t\t\t// http://www.highcharts.com/plugin-registry/single/9/Pattern-Fill\r\n\r\n \t\t\tdrawChart(element[0], scope.config);\r\n\r\n \t\t\tscope.$watch(\"config\", function (newValue, oldValue) {\r\n \t\t\t\t//This gets called when data changes.\r\n \t\t\t\t//console.log('sdHighchartsColumn - config changed! ', newValue)\r\n \t\t\t\tdrawChart(element[0], newValue);\r\n \t\t\t});\r\n \t\t}\r\n \t};\r\n \tfunction drawChart(element, config) {\r\n\r\n \t\t//var w = window.innerWidth;\r\n \t\t//console.log('window.innerWidth', w);\r\n\r\n \t\t//if (window.innerWidth <= 1280)\r\n \t\t//\tchartConfig.chart.width = 350;\r\n\r\n \t\tif (config) {\r\n \t\t\t//Object.keys(config).forEach(function (keyName, index) {\r\n \t\t\t//\t//if (keyName != 'title')\r\n \t\t\t//\t\tchartConfig[keyName] = config[keyName];\r\n \t\t\t//});\r\n \t\t\t//chartConfig.title.text = '';\r\n \t\t\tvar newChart = Highcharts.chart(element, config);\r\n\r\n \t\t}\r\n\r\n \t}\r\n });\r\n","'use strict';\r\n\r\nangular.module('weissmanApp')\r\n .filter('weissmanStringContains', function(){\r\n return function (input, filter) {\r\n if (!filter || (filter.trim().length === 0)) return input;\r\n if (!input) return null;\r\n\r\n return input.toLowerCase().indexOf(filter.toLowerCase()) !== -1 ? input : null;\r\n }\r\n })\r\n .filter('weissmanArrayContains', function(){\r\n return function (input, filter, index) {\r\n if (!filter || (filter.trim().length === 0)) return input;\r\n if (!input) return [];\r\n\r\n var filtered = [];\r\n var i = input.length;\r\n\r\n if (index) {\r\n while (i--) {\r\n if (input[i] && input[i][index] && input[i][index].toLowerCase().indexOf(filter.toLowerCase()) !== -1) filtered.push(input[i]);\r\n }\r\n } else {\r\n while (i--) {\r\n if (input[i].toLowerCase().indexOf(filter.toLowerCase()) !== -1) filtered.push(input[i]);\r\n }\r\n }\r\n\r\n return filtered;\r\n }\r\n });\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.factory:Common.Logger.Factory\r\n * @description\r\n * # Logging Factory\r\n * Factory of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar DEFAULT_TITLE = 'sd.Weissman';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory('sdLogger', Factory);\r\n\r\n\tFactory.$inject = [\r\n\t\t'$log',\r\n\t\t'toastr',\r\n\t\t'sd.Trace.Service'\r\n\t];\r\n\r\n\tfunction Factory($log, toastr, trace) {\r\n\t\tvar factory = {\r\n\t\t\terror: error,\r\n\t\t\tinfo: info,\r\n\t\t\tlog: log,\r\n\t\t\tsuccess: success,\r\n\t\t\twarning: warning\r\n\t\t};\r\n\r\n\t\treturn factory;\r\n\r\n\t\t// ToDo: Log error/log messages to a logging web service, adding a reference identifier to the message.\r\n\r\n\t\tfunction error(title, message, error) {\r\n\t\t\tif (!title) title = DEFAULT_TITLE;\r\n // I'm unclear on why this ever had its timeout set to 0. I'm also unclear on why we toast within\r\n // an error log handler; seems like that should be independent, but generally we should refactor\r\n // out anything that depends on this anyway.\r\n\t\t\t// toastr.error(message, title, {\r\n\t\t\t// \ttimeOut: 0,\r\n\t\t\t// \textendedTimeOut: 0\r\n\t\t\t// });\r\n toastr.error(message, title);\r\n\t\t\tif (trace.isEnabled()) {\r\n\t\t\t\t$log.error(message, error);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction info(title, message) {\r\n\t\t\tif (!title) title = DEFAULT_TITLE;\r\n\t\t\ttoastr.info(message, title);\r\n\t\t}\r\n\r\n\t\tfunction log(message, data) {\r\n\t\t\tif (trace.isEnabled()) {\r\n\t\t\t\t$log.log(message, data);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction success(title, message) {\r\n\t\t\tif (!title) title = DEFAULT_TITLE;\r\n\t\t\ttoastr.success(message, title);\r\n\t\t}\r\n\r\n\t\tfunction warning(title, message) {\r\n\t\t\tif (!title) title = DEFAULT_TITLE;\r\n\t\t\ttoastr.warning(message, title, {\r\n\t\t\t\ttimeOut: 3000\r\n\t\t\t});\r\n\t\t}\r\n\t};\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissmanApp.Current.Entity.Service.Service\r\n * @description\r\n * # Property.Type Service\r\n * Factory in the weissmanApp.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory('sdModalService', sdModalService);\r\n\r\n\tfunction sdModalService() {\r\n\t\t// Public API.\r\n\t\tvar service = {\r\n\t\t\tcancel: cancel\r\n\t\t};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction cancel(dirty, dismiss) {\r\n\t\t\tvar confirmMessage = 'Are you sure you want to cancel and discard all changes?';\r\n\r\n\t\t\tif (!dirty || (dirty && confirm(confirmMessage))) {\r\n\t\t\t\tdismiss();\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:Component.Permission.Directive\r\n * @description\r\n * # check if the logged in user has permission to access the applied element.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sdRestrict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive(APP_SOURCE, Directive);\r\n\r\n\tDirective.$inject = [\r\n\t\t'SD.Restrict.Service'\r\n\t];\r\n\r\n\tfunction Directive(restrictService) {\r\n\t\t// Usage:\r\n\t\t// \t\t
foo
\r\n\t\t//\r\n\t\t// See PermissionFlags constant in constants.js for PermissionFlags values\r\n\t\t// See Roles constant in constants.js for Roles values\r\n\t\tvar directive = {\r\n\t\t\trestrict: 'A',\r\n\t\t\tscope: {\r\n\t\t\t\tshowRoles: '=',\r\n\t\t\t\tenableRoles: '=',\r\n\t\t\t\tshowSites: '=',\r\n\t\t\t\tenableSites: '=',\r\n\t\t\t\tshowCompanies: '=',\r\n\t\t\t\tenableCompanies: '=',\r\n\t\t\t\tflags: '@'\r\n\t\t\t},\r\n\t\t\tlink: link\r\n\t\t};\r\n\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element) {\r\n // Calling this method does nothing. I am commenting it out to get things working again but this whole\r\n // directive can be removed from the app since it doesn't do anything anymore\r\n\t\t\t//restrictService.checkElement(scope, element);\r\n\t\t}\r\n\t}\r\n})();\r\n","// This is in /Common, but is currently only used by document processing. \r\n// It is not general enough for actual quick search\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdQuickResults', sdQuickResults);\r\n\r\n\t// sdQuickResults.$inject = ['dependencies'];\r\n\r\n\tfunction sdQuickResults() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Common/Quick-Search/quickSearchResults.html',\r\n\t\t\tscope: {\r\n\t\t\t\tcriteria: '=',\r\n\t\t\t\tresultTypes: '=',\r\n\t\t\t\tshowCriteria: '='\r\n\t\t\t}\r\n\t\t};\r\n\r\n\t\treturn directive;\r\n\t}\r\n\r\n\tController.$inject = ['processingService', '$rootScope', 'toastr', '$timeout'];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(processingService, $rootScope, toastr, $timeout) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.itemsPerPage = 30;\r\n\t\tvm.results = [];\r\n\t\tvm.resultType = angular.copy(vm.criteria.resultType)\r\n\r\n\t\tvm.getResults = getResults;\r\n\t\tvm.resultClicked = resultClicked;\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\t\t\tloadExtraFilters();\r\n\t\t\tgetResults();\r\n\t\t}\r\n\r\n\t\tasync function getResults() {\r\n\t\t\tvm.loading = true;\r\n\r\n\t\t\ttry {\r\n\t\t\t\tvar pageNumber = vm.results ? Math.ceil(vm.results.length / vm.itemsPerPage) + 1 : 1;\r\n\t\r\n\t\t\t\tconst resultsObj = await processingService.search(pageNumber, vm.itemsPerPage, vm.criteria, vm.resultTypes)\r\n\t\t\t\t\r\n\t\t\t\tif (resultsObj.results && resultsObj.results[0]?.error)\r\n\t\t\t\t{\r\n\t\t\t\tif (resultsObj.results[0].error == 'too many rows') {\r\n\t\t\t\t\ttoastr.error('Please narrow your search criteria', 'Too many results!');\r\n\t\t\t\t}\r\n\t\t\t\telse if (resultsObj.results[0].error == 'Execution Timeout Expired') {\r\n\t\t\t\t\ttoastr.error('Please narrow your search criteria', 'Search has taken too long!');\r\n\t\t \t}\r\n\t\t\t\t vm.showCriteria = true;\r\n\t\t\t return;\r\n\t\t\t }\r\n\t\r\n\t\t\t\tvm.results = vm.results.concat(resultsObj.results);\r\n\t\t\t\t\r\n\t\t\t\tif (vm.results.length === 1) {\r\n\t\t\t\t\t$timeout(function () {\r\n\t\t\t\t\t\tresultClicked(vm.results[0]);\r\n\t\t\t\t\t}, 1000)\r\n\t\t\t\t}\r\n\t\t\t} finally {\r\n\t\t\t\tvm.loading = false;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction loadExtraFilters() {\r\n\t\t\tvar fieldsToReject = ['parcelPropType', 'parcelAcctNum', 'taxYear'];\r\n\r\n\t\t\tvm.extraFilters = _.chain(vm.criteria.activeFilters)\r\n\t\t\t\t.filter('text')\r\n\t\t\t\t.reject('default')\r\n\t\t\t\t.reject(function (filter) {\r\n\t\t\t\t\treturn _.includes(fieldsToReject, filter.field);\r\n\t\t\t\t})\r\n\t\t\t\t.value();\r\n\t\t}\r\n\r\n\t\tfunction resultClicked(result) {\r\n\t\t\tvm.criteria.executeSearch = false;\r\n\r\n\t\t\tvar type = _.find(vm.resultTypes, { type: vm.resultType });\r\n\t\t\tvar resultId = result.entityID ? result.entityID : result[vm.resultType + 'ID'];\r\n\r\n\t\t\tvar entityDetails = {\r\n\t\t\t\tentityTypeId: type.id,\r\n\t\t\t\tentityId: resultId\r\n\t\t\t};\r\n\r\n\t\t\t$rootScope.$broadcast('processingQuickSearchClicked', entityDetails);\r\n\t\t}\r\n\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissmanApp.Http.Service\r\n * @description\r\n * # Advanced Search Entities Service\r\n * Factory in the weissmanApp.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Http.Service';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = [\r\n\t\t'$http',\r\n\t\t'$q',\r\n 'appStateService'\r\n\t];\r\n\r\n\tfunction Service($http, $q, appStateService) {\r\n\t var timestampCheckPromise = null;\r\n var appState = null;\r\n appStateService.appState$.subscribe(function (s) { appState = s; });\r\n\r\n\t\tvar service = {\r\n\t\t\tget: get,\r\n\t\t\tpost: post,\r\n\t\t\tput: put,\r\n\t\t\t'delete': deleteHttp,\r\n\t\t\tpatch: patch,\r\n\t\t\tdeleteByEntity: deleteByEntity,\r\n initializeTimestampCheck: initializeTimestampCheck\r\n\t\t};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction get(url, config) {\r\n\t\t\tconfig = config || {};\r\n\t\t\tconfig.params = config.params || {};\r\n\r\n\t\t\tif(!config.cache) {\r\n\t\t\t\tangular.extend(config.params, {\r\n\t\t\t\t\tcacheBuster: Date.now()\r\n\t\t\t\t});\r\n\t\t\t}\r\n\r\n\t\t\tangular.extend(config, {\r\n\t\t\t\tmethod: 'GET',\r\n\t\t\t\turl: url\r\n\t\t\t});\r\n\r\n\t\t\treturn makeRequest(config);\r\n\t\t}\r\n\r\n\t\tfunction post(url, data, config) {\r\n\t\t\tconfig = config || {};\r\n\r\n\t\t\tangular.extend(config, {\r\n\t\t\t\tmethod: 'POST',\r\n\t\t\t\turl: url,\r\n\t\t\t\tdata: data\r\n\t\t\t})\r\n\r\n\t\t\treturn makeRequest(config);\r\n\t\t}\r\n\r\n\t\tfunction put(url, data, config) {\r\n\t\t\tconfig = config || {};\r\n\r\n\t\t\tangular.extend(config, {\r\n\t\t\t\tmethod: 'PUT',\r\n\t\t\t\turl: url,\r\n\t\t\t\tdata: data\r\n\t\t\t})\r\n\r\n\t\t\treturn makeRequest(config);\r\n\t\t}\r\n\r\n\t\tfunction deleteHttp(url, config) {\r\n\t\t\tconfig = config || {};\r\n\r\n\t\t\tangular.extend(config, {\r\n\t\t\t\tmethod: 'DELETE',\r\n\t\t\t\turl: url\r\n\t\t\t});\r\n\r\n\t\t\treturn makeRequest(config);\r\n\t\t}\r\n\r\n function deleteByEntity(url, data, config) {\r\n config = config || {};\r\n\r\n angular.extend(config, {\r\n method: 'DELETE',\r\n url: url,\r\n data: data,\r\n headers: {'Content-Type': 'application/json'}\r\n });\r\n\r\n return makeRequest(config);\r\n }\r\n\r\n function patch(url, data, config) {\r\n\t\t\tconfig = config || {};\r\n\r\n\t\t\tangular.extend(config, {\r\n\t\t\t\tmethod: 'PATCH',\r\n\t\t\t\turl: url,\r\n\t\t\t\tdata: data\r\n\t\t\t});\r\n\r\n\t\t\treturn makeRequest(config);\r\n\t\t}\r\n\r\n\t // No HTTP calls should be made until we've verified that the UI hasn't been cached. The BuildTimestampService will\r\n // call this initialize function on app startup to register the check.\r\n function initializeTimestampCheck(checkPromise) {\r\n timestampCheckPromise = checkPromise;\r\n }\r\n\r\n\t\tfunction makeRequest(config) {\r\n if (appState === appStateService.appStates.LoggedOut) {\r\n throw 'Cannot make web request when logged out';\r\n }\r\n\t\t var httpPromise;\r\n\t\t if (timestampCheckPromise) {\r\n\t\t httpPromise = timestampCheckPromise.then(function () { return $http(config); });\r\n\t\t }\r\n\t\t else {\r\n\t\t httpPromise = $http(config);\r\n\t\t }\r\n\r\n\t\t\treturn httpPromise\r\n\t\t\t\t.then(function (response) {\r\n\t\t\t\t\treturn response ? response.data : response;\r\n\t\t\t\t})\r\n\t\t\t\t.catch(function (error) {\r\n\t\t\t\t\treturn $q.reject(error);\r\n\t\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * This file exists to upgrade router changes to angular 2, giving us a window into the routing without\r\n * having to upgrade the entire stateRouter\r\n */\r\n\r\n(function () {\r\n 'use strict';\r\n\r\n angular\r\n .module('weissmanApp')\r\n .factory('UpgradeNavigationServiceHandler', upgradeNavigationService);\r\n\r\n upgradeNavigationService.$inject = [\r\n '$state',\r\n '$stateParams',\r\n '$uibModalStack'\r\n ];\r\n\r\n function upgradeNavigationService($state, $stateParams, $uibModalStack) {\r\n var service = {\r\n //Common functions\r\n transitionTo: transitionTo,\r\n getQuerystringParam: getQuerystringParam,\r\n getCurrentState: getCurrentState,\r\n go: go,\r\n goWithReload: goWithReload,\r\n getHrefFromState: getHrefFromState,\r\n\r\n //annual details\r\n goToAnnualDetailsTax: goToAnnualDetailsTax,\r\n goToAnnualDetailsAssessment: goToAnnualDetailsAssessment,\r\n goToAnnualDetailsAppeal: goToAnnualDetailsAppeal,\r\n goToAnnualDetailsRefund: goToAnnualDetailsRefund,\r\n goToAnnualDetailsFiling: goToAnnualDetailsFiling,\r\n goToFilingBatch: goToFilingBatch\r\n };\r\n return service;\r\n\r\n function transitionTo(newState, params, options) {\r\n if (options) {\r\n console.log([newState, params, options]);\r\n $state.transitionTo(newState, params, options);\r\n }\r\n else {\r\n $state.transitionTo(newState, params);\r\n }\r\n }\r\n\r\n function go(stateName, params, closeModal) {\r\n if (closeModal){\r\n $uibModalStack.dismissAll();\r\n }\r\n $state.go(stateName, params);\r\n }\r\n\r\n function goWithReload(stateName, params) {\r\n $state.go(stateName, params, { reload: true });\r\n }\r\n\r\n function goToAnnualDetailsAssessment(companyID, siteID, parcelID, annualYearID, assessmentID) {\r\n $uibModalStack.dismissAll();\r\n\r\n $state.go('parcel', {\r\n annualAssessmentID: assessmentID,\r\n siteId: siteID,\r\n companyId: companyID,\r\n annualYearID: annualYearID,\r\n parcelId: parcelID\r\n });\r\n }\r\n\r\n function goToAnnualDetailsAppeal(companyID, siteID, parcelID, annualYearID, assessmentID, appealID) {\r\n $uibModalStack.dismissAll();\r\n\r\n $state.go('parcel', {\r\n annualAssessmentID: assessmentID,\r\n siteId: siteID,\r\n companyId: companyID,\r\n annualYearID: annualYearID,\r\n parcelId: parcelID,\r\n appealID: appealID\r\n });\r\n }\r\n\r\n function goToAnnualDetailsTax(companyID, siteID, parcelID, annualYearID, billClusterID) {\r\n $uibModalStack.dismissAll();\r\n\r\n $state.go('parcel', {\r\n billClusterID: billClusterID,\r\n siteId: siteID,\r\n companyId: companyID,\r\n annualYearID: annualYearID,\r\n parcelId: parcelID\r\n });\r\n }\r\n\r\n function goToAnnualDetailsRefund(companyID, siteID, parcelID, annualYearID, refundID) {\r\n $uibModalStack.dismissAll();\r\n\r\n $state.go('parcel', {\r\n refundID: refundID,\r\n siteId: siteID,\r\n companyId: companyID,\r\n annualYearID: annualYearID,\r\n parcelId: parcelID\r\n });\r\n }\r\n\r\n function goToAnnualDetailsFiling(companyID, siteID, parcelID, annualYearID, filingId) {\r\n $uibModalStack.dismissAll();\r\n\r\n $state.go('parcel', {\r\n filingId: filingId,\r\n siteId: siteID,\r\n companyId: companyID,\r\n annualYearID: annualYearID,\r\n parcelId: parcelID\r\n });\r\n }\r\n\r\n function goToFilingBatch(filingBatchId) {\r\n $uibModalStack.dismissAll();\r\n\r\n $state.go('returnFilingBatchPage', {\r\n filingBatchId: filingBatchId\r\n });\r\n }\r\n\r\n function getCurrentState() {\r\n return $state.current;\r\n }\r\n\r\n function getQuerystringParam(parameterName) {\r\n return $stateParams[parameterName];\r\n }\r\n\r\n function getHrefFromState(stateName, options) {\r\n return $state.href(stateName, options, {absolute: true});\r\n }\r\n }\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissmanApp.Property.Type.Service\r\n * @description\r\n * # Property.Type Service\r\n * Factory in the weissmanApp.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Property.Type.Service';\r\n\tvar SERVICE_URL = '/api/propertytype/';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = [\r\n\t\t'sd.Http.Service',\r\n\t\t'$q',\r\n\t\t'PropertyTypes'\r\n\t];\r\n\r\n\tfunction Service(sdHttp, $q, PropertyTypes) {\r\n\t\t// Public API.\r\n\t\tvar service = {\r\n\t\t\tget: get,\r\n\t\t\tgetById: getById\r\n\t\t};\r\n\r\n\t\tvar vm = this;\r\n\t\tvm.cached_value = null;\r\n\t\tvm.gettingDataFromServerNow = false;\r\n\r\n\t\treturn service;\r\n\r\n\t\t// todo: refactor if/when we will implement central storage\r\n\t\t//\r\n\t\tfunction get() {\r\n\t\t\t//console.log('Property.Type.Service - get');\r\n\t\t\tvar defer = $q.defer();\r\n\t\t\tif (vm.cached_value != null) {\r\n\t\t\t\t//console.log('Property.Type.Service - returning cached value', vm.cached_value);\r\n\t\t\t\tdefer.resolve(angular.copy(vm.cached_value));\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t//console.log('Property.Type.Service - there is no cached value, getting data from server');\r\n\t\t\t\t//vm.gettingDataFromServerNow = true;\r\n\t\t\t\tgetPropTypesFromServer().then(function (data) {\r\n\t\t\t\t\tvm.cached_value = data;\r\n\t\t\t\t\t//console.log('Property.Type.Service - got data from server, storing as cached value and returning', vm.cached_value);\r\n\t\t\t\t\tvm.gettingDataFromServerNow = false;\r\n\t\t\t\t\tdefer.resolve(angular.copy(vm.cached_value));\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\t\treturn defer.promise;\r\n\t\t}\r\n\r\n\t\tfunction getPropTypesFromServer() {\r\n\t\t\t//console.log('Property.Type.Service - getPropTypesFromServer');\r\n\t\t\tvar config = {};\r\n\r\n\t\t // Why did this ever get property types from the server? This entire flow is nonsense. We should\r\n\t\t // eventually gut this and remove the property type service, but for now we need the quick search\r\n\t\t // code to be able to get property types without going to the server (since the user might not be\r\n\t\t\t// authenticated yet), so just return the values from constants as if we got them from the server.\r\n\t\t\t//return sdHttp.get(SERVICE_URL, config)\r\n\t\t\treturn $q.resolve(_.orderBy(_.values(PropertyTypes), \"sequence\"));\r\n\t\t}\r\n\r\n\t\tfunction getById(id) {\r\n\t\t\treturn _.find(PropertyTypes, { propertyTypeID: id });\r\n\t\t}\r\n\r\n\t}\r\n})();\r\n","(function () {\r\n 'use strict';\r\n\r\n angular.module('weissmanApp')\r\n .factory('eventAdapterService', Service);\r\n\r\n Service.$inject = ['$rootScope'];\r\n\r\n function Service($rootScope) {\r\n return {\r\n broadcast: broadcast\r\n };\r\n\r\n function broadcast(name, args) {\r\n return $rootScope.$broadcast.apply($rootScope, arguments);\r\n }\r\n }\r\n}());\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdStateDropdown', sdStateDropdown);\r\n\r\n\tsdStateDropdown.$inject = ['StatesService'];\r\n\r\n\tfunction sdStateDropdown(statesService) {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\ttemplateUrl: 'app/Common/States/State-Dropdown/_stateDropdown.html',\r\n\t\t\trestrict: 'E',\r\n\t\t\tcontroller: StateDropdownController,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tscope: {\r\n\t\t\t\tstateId: '=',\r\n\t\t\t\telementType: '@',\r\n\t\t\t\tlabelStyle: '=',\r\n\t\t\t\thasBlank: '=',\r\n\t\t\t\tdisabled: '=',\r\n\t\t\t\tisOptional: '=',\r\n\t\t\t\tuseFullName: '=',\r\n\t\t\t\tincludeAll: '=',\r\n\t\t\t\tchangeFn: '&',\r\n\t\t\t\tfilterByCountryId: '='\r\n\t\t\t},\r\n\t\t\tbindToController: true\r\n\t\t};\r\n\r\n\t\treturn directive;\r\n\r\n\t\tfunction StateDropdownController() {\r\n\t\t\tvar vm = this;\r\n\r\n\t\t\tvm.states = [];\r\n\r\n\t\t\tvm.getName = getName;\r\n\t\t\tvm.assignValue = assignValue\r\n\r\n\t\t\tactivate();\r\n\r\n\t\t\tfunction activate() {\r\n\t\t\t\tloadStates();\r\n\t\t\t}\r\n\r\n\t\t\tfunction loadStates() {\r\n\t\t\t\tstatesService.getSummary()\r\n\t\t\t\t\t.then(function (result) {\r\n\t\t\t\t\t\tresult = _\r\n\t\t\t\t\t\t\t.chain(result)\r\n\t\t\t\t\t\t\t.filter(function(state) {\r\n return vm.filterByCountryId ? state.countryID === vm.filterByCountryId : true;\r\n\t\t\t\t\t\t\t})\r\n\t\t\t\t\t\t\t.map(function(state) {\r\n\t\t\t\t\t\t\t\tstate.name = vm.useFullName ? state.fullName : state.abbr;\r\n\t\t\t\t\t\t\t\treturn state;\r\n\t\t\t\t\t\t\t})\r\n\t\t\t\t\t\t\t.sortBy(['name'])\r\n\t\t\t\t\t\t\t.value();\r\n\r\n\t\t\t\t\t\tif(vm.includeAll) {\r\n\t\t\t\t\t\t\tvar all = {\r\n\t\t\t\t\t\t\t\tstateID: 999,\r\n\t\t\t\t\t\t\t\tname: 'All'\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tresult.unshift(all);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tif (vm.hasBlank) {\r\n\t\t\t\t\t\t\tvar blankState = {\r\n\t\t\t\t\t\t\t\tstateID: null,\r\n\t\t\t\t\t\t\t\tname: ''\r\n\t\t\t\t\t\t\t};\r\n\t\t\t\t\t\t\tresult.unshift(blankState);\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tvm.states = result;\r\n\t\t\t\t\t})\r\n\t\t\t}\r\n\r\n\t\t\tfunction getName(id) {\r\n\t\t\t\tvar state = _.find(vm.states, {\r\n\t\t\t\t\tstateID: id\r\n\t\t\t\t});\r\n\r\n\t\t\t\tif (state) {\r\n\t\t\t\t\treturn state.name;\r\n\t\t\t\t} else {\r\n\t\t\t\t\treturn null;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction assignValue(data) {\r\n\t\t\t\tvm.stateId = data;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.service:Common.Trace.Service\r\n * @description\r\n * # Trace Service\r\n * Service of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Trace.Service';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = [\r\n\t];\r\n\r\n\tfunction Service() {\r\n\t\tvar _enabled = false;\r\n\t\tvar service = {\r\n\t\t\tisEnabled: isEnabled,\r\n\t\t\ttoggle: toggleTracing,\r\n\t\t};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction isEnabled() {\r\n\t\t\treturn _enabled;\r\n\t\t}\r\n\r\n\t\tfunction toggleTracing() {\r\n\t\t\t_enabled = !_enabled;\r\n\r\n\t\t\t// Using console.log due to a circular reference with sdLogger.\r\n\t\t\tconsole.log(APP_SOURCE + '.toggleTracing(): ', {\r\n\t\t\t\t'_enabled': _enabled\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:Validators.Does.Not.Match.Directive\r\n * @description\r\n * # Validators Does Not Match Match Directive\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Validators.Does.Not.Match.Directive';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdDoesNotMatch', Directive);\r\n\r\n\tDirective.$inject = [\r\n\t\t'sdLogger',\r\n\t];\r\n\r\n\tfunction Directive(sdLogger) {\r\n\t\t// Usage:\r\n\t\t// \r\n\t\tvar directive = {\r\n\t\t\trequire: \"ngModel\",\r\n\t\t\tscope: {\r\n\t\t\t\tvalueToNotMatch: \"=sdDoesNotMatch\",\r\n\t\t\t},\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'A'\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs, ngModel) {\r\n\t\t\tngModel.$validators.sdDoesNotMatch = function (modelValue) {\r\n\t\t\t\tsdLogger.log(APP_SOURCE, {\r\n\t\t\t\t\t'valueToNotMatch': scope.valueToNotMatch,\r\n\t\t\t\t\t'modelValue': modelValue\r\n\t\t\t\t});\r\n\r\n\t\t\t\treturn (modelValue != scope.valueToNotMatch);\r\n\t\t\t};\r\n\r\n\t\t\tscope.$watch(\"valueToNotMatch\", function () {\r\n\t\t\t\tngModel.$validate();\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:Validators.Must.Match.Directive\r\n * @description\r\n * # Validators Must Match Directive\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Validators.Must.Match.Directive';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdMustMatch', Directive);\r\n\r\n\tDirective.$inject = [\r\n\t\t'sdLogger',\r\n\t];\r\n\r\n\tfunction Directive(sdLogger) {\r\n\t\t// Usage:\r\n\t\t// \r\n\t\tvar directive = {\r\n\t\t\trequire: \"ngModel\",\r\n\t\t\tscope: {\r\n\t\t\t\tvalueToMatch: \"=sdMustMatch\",\r\n\t\t\t},\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'A'\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs, ngModel) {\r\n\t\t\tngModel.$validators.sdMustMatch = function (modelValue) {\r\n\t\t\t\tsdLogger.log(APP_SOURCE, {\r\n\t\t\t\t\t'valueToMatch': scope.valueToMatch,\r\n\t\t\t\t\t'modelValue': modelValue\r\n\t\t\t\t});\r\n\r\n\t\t\t\treturn (modelValue === scope.valueToMatch);\r\n\t\t\t};\r\n\r\n\t\t\tscope.$watch(\"valueToMatch\", function () {\r\n\t\t\t\tngModel.$validate();\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","(function() {\r\n\t'use strict';\r\n\r\n\t/**\r\n * @ngdoc service\r\n * @name weissman.ContactRoleAssociation\r\n * @description\r\n * # ContactRoleAssociations\r\n * Factory in the weissman.\r\n */\r\n\tangular\r\n .module('weissmanApp')\r\n .factory('ContactRoleAssociationService',ContactRoleAssociationService);\r\n\r\n\tContactRoleAssociationService.$inject=['sd.Http.Service', '$uibModal', '$rootScope'];\r\n\tfunction ContactRoleAssociationService(sdHttp, $uibModal, $rootScope) {\r\n\t\tvar baseUrl='/api/ContactRoleAssociation/';\r\n\r\n\t\tvar service={\r\n\t\t\tadd: addContactRoleAssociation,\r\n\t\t\t'delete': deleteContactRoleAssociation,\r\n openContactAssociationModal: openContactAssociationModal\r\n\t\t};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction addContactRoleAssociation(data) {\r\n\t\t\treturn sdHttp.post(baseUrl,data);\r\n\t\t}\r\n\r\n\t\tfunction deleteContactRoleAssociation(id) {\r\n\t\t\tvar url=baseUrl+id;\r\n\t\t\treturn sdHttp.delete(url)\r\n\t\t}\r\n\r\n async function openContactAssociationModal(params) {\r\n const modalScope = $rootScope.$new();\r\n modalScope.dialogParameters = params;\r\n\r\n const modalConfig = {\r\n templateUrl: 'app/Contact/List/_contactList.html',\r\n controller: 'sd.Contacts.List.Controller',\r\n size: 'lg',\r\n windowClass: 'associate-contact-modal show',\r\n\t\t\t\tbackdropClass: 'show',\r\n controllerAs: 'vm',\r\n scope: modalScope,\r\n };\r\n\r\n const modalInstance = $uibModal.open(modalConfig);\r\n\r\n return await modalInstance.result;\r\n }\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissman.Contacts.Service\r\n * @description\r\n * # Contacts Service\r\n * Factory in the weissman.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Contacts.Service.old';\r\n\tvar SERVICE_URL = '/api/contact/';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = [\r\n\t\t'sd.Http.Service',\r\n\t\t'roleService',\r\n\t\t'$uibModal',\r\n '$q',\r\n '$rootScope',\r\n 'EntityTypeIDs'\r\n\t];\r\n\r\n\tfunction Service(sdHttp, roleService, $uibModal, $q, $rootScope, EntityTypeIDs) {\r\n\t\tvar _contacts = [];\r\n\r\n\t\t// Public API.\r\n\t\tvar service = {\r\n\t\t\tget: get,\r\n\t\t\tgetById: getById,\r\n\t\t\tgetByIdScoped: getByIdScoped,\r\n\t\t\tupdate: update,\r\n\t\t\tupdateScoped: updateScoped,\r\n\t\t\t'delete': deleteContact,\r\n\t\t\tdeleteContactScoped: deleteContactScoped,\r\n\t\t\tgetByEntity: getByEntity,\r\n\t\t\tcreate: create,\r\n\t\t\topenContactDialog: openContactDialog,\r\n\t\t\tsearch: search,\r\n\t\t\tsearchScoped: searchScoped,\r\n\t\t\tsearchForSignatureDelegates: searchForSignatureDelegates,\r\n\t\t\tgetAvailableRoles: getAvailableRoles,\r\n\t\t\tgetCached: getCached,\r\n\t\t\taddToCache: addToCache,\r\n\t\t\tgetForSetup: getForSetup,\r\n\t\t\tcreateUser: createUser,\r\n\t\t\tlaunchRecipientContactModal: launchRecipientContactModal,\r\n\t\t\tsaveContactSignature: saveContactSignature,\r\n\t\t\tgetContactSignature : getContactSignature,\r\n\t\t\tgetForSetupScoped: getForSetupScoped,\r\n\t\t\tsearchRyan: searchRyan,\r\n\t\t\tgetUserById: getUserById\r\n\t\t};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction get(pageNumber, pageSize) {\r\n\t\t\treturn sdHttp.get(SERVICE_URL + '?pageNumber=' + pageNumber + '&pageSize=' + pageSize);\r\n\t\t}\r\n\r\n\t\tfunction getById(contactId) {\r\n\t\t\treturn sdHttp.get(`${SERVICE_URL}${contactId}`);\r\n\t\t}\r\n\r\n\t\tfunction getByIdScoped(contactId) {\r\n\t\t\treturn sdHttp.get(`${SERVICE_URL}${contactId}/scoped`);\r\n\t\t}\r\n\r\n\t\tfunction getForSetup(contactId) {\r\n\t\t\treturn sdHttp.get(`${SERVICE_URL}${contactId}/setup`);\r\n\t\t}\r\n\r\n\t\tfunction getForSetupScoped(contactId) {\r\n\t\t\treturn sdHttp.get(`${SERVICE_URL}${contactId}/setup/scoped`);\r\n\t\t}\r\n\r\n\t\tfunction getUserById(id) {\r\n\t\t\tvar config = {\r\n\t\t\t\tparams: {\r\n\t\t\t\t\tuserid: id\r\n\t\t\t\t}\r\n\t\t\t};\r\n\t\t\treturn sdHttp.get(SERVICE_URL, config);\r\n\t\t}\r\n\r\n\t\tfunction copyContactProperties(c, r) {\r\n\t\t\t// we'll have a mix between real contact and Dto\r\n\t\t\tr.contactID = c.contactID;\r\n\t\t\tr.entityID = c.entityID;\r\n\t\t\tr.entityName = c.entityName;\r\n\t\t\tr.firstName = c.firstName;\r\n\t\t\tr.lastName = c.lastName;\r\n\t\t\tr.title = c.title;\r\n\t\t\tr.address = c.address;\r\n\t\t\tif (c.address) {\r\n\t\t\t\tr.phone = c.address.phone;\r\n\t\t\t\tr.ext = c.address.ext;\r\n\t\t\t\tr.mobilePhone = c.address.mobilePhone;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction search(instanceId, searchText, pageNumber, pageSize, excludeInactive) {\r\n\t\t\tlet searchFragment = '';\r\n\t\t\tif (searchText || searchText.trim() !== '') {\r\n\t\t\t\tsearchFragment = `&search=${encodeURIComponent(searchText)}`;\r\n\t\t\t}\r\n\r\n\t\t\t//endpoint supports sending specific instanceId or resolving selected instance(s) from the headers\r\n\t\t\tlet instanceFragment = '';\r\n\t\t\tif (instanceId) {\r\n\t\t\t\tinstanceFragment = `&instanceId=${instanceId}`;\r\n\t\t\t}\r\n\r\n\t\t\treturn sdHttp.get(`${SERVICE_URL}?pageNumber=${pageNumber}&pageSize=${pageSize}&excludeInactive=${excludeInactive}${searchFragment}${instanceFragment}`);\r\n\t\t}\r\n\r\n\t\tfunction searchScoped(entityId, entityType,searchText, pageNumber, pageSize, excludeInactive) {\r\n\t\t\tlet searchFragment = '';\r\n\t\t\tif (searchText || searchText.trim() !== '') {\r\n\t\t\t\tsearchFragment = `&search=${encodeURIComponent(searchText)}`;\r\n\t\t\t}\r\n\t\t\tvar url = `${SERVICE_URL}${entityType}/${entityId}/scoped?pageNumber=${pageNumber}&pageSize=${pageSize}&excludeInactive=${excludeInactive}${searchFragment}`;\r\n\t\t\treturn sdHttp.get(url);\r\n\t\t}\r\n\r\n\t\tfunction searchRyan(searchText, pageNumber, pageSize, excludeInactive) {\r\n\t\t\tlet searchFragment = '';\r\n\t\t\tif (searchText || searchText.trim() !== '') {\r\n\t\t\t\tsearchFragment = `&search=${encodeURIComponent(searchText)}`;\r\n\t\t\t}\r\n\t\t\tvar url = `${SERVICE_URL}ryan?pageNumber=${pageNumber}&pageSize=${pageSize}&excludeInactive=${excludeInactive}${searchFragment}`;\r\n\t\t\treturn sdHttp.get(url);\r\n\t\t}\r\n\r\n\t\tfunction searchForSignatureDelegates(contactId,searchText) {\r\n\t\t\tlet searchFragment = '';\r\n\t\t\tif (searchText || searchText.trim() !== '') {\r\n\t\t\t\tsearchFragment = `search=${encodeURIComponent(searchText)}`;\r\n\r\n\t\t\t\tvar url = `${SERVICE_URL}${contactId}/signature/search-for-delegates?${searchFragment}`;\r\n\t\t\t\treturn sdHttp.get(url);\r\n\t\t\t}\r\n\t\t\treturn [];\r\n\t\t}\r\n\r\n\t\tfunction getByEntity(entityId, entityType, showAll) {\r\n\t\t\tif (showAll) {\r\n\t\t\t\treturn sdHttp.get(`${SERVICE_URL}${entityType}/${entityId}`)\r\n\t\t\t\t.then(function (response) {\r\n\t\t\t\t\t_contacts = response;\r\n\t\t\t\t\treturn response;\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t//This is really just for company and allows us to hide unassoicated contacts\r\n\t\t\t\t//using a different URI for this, which will call the same logic in the api\r\n\t\t\t\t//just using a bool to control that bit\r\n\t\t\t\treturn sdHttp.get(`${SERVICE_URL}${entityType}/${entityId}/filtered`)\r\n\t\t\t\t.then(function (response) {\r\n\t\t\t\t\t_contacts = response;\r\n\t\t\t\t\treturn response;\r\n\t\t\t\t});\r\n\t\t\t}\r\n\r\n\t\t}\r\n\r\n\t\t//uses instance right for security check\r\n\t\tfunction update(contact) {\r\n\t\t\treturn sdHttp.put(SERVICE_URL, contact);\r\n\t\t}\r\n\r\n\t\t//uses entity permission for security check\r\n\t\tfunction updateScoped(contact) {\r\n\t\t\treturn sdHttp.put(`${SERVICE_URL}scoped`, contact);\r\n\t\t}\r\n\r\n\r\n\t\t//uses instance right for security check\r\n\t\tfunction deleteContact(contactId) {\r\n\t\t\treturn sdHttp.delete(`${SERVICE_URL}${contactId}`);\r\n\t\t}\r\n\r\n\t\t//uses entity permission for security check\r\n\t\tfunction deleteContactScoped(contactId) {\r\n\t\t\treturn sdHttp.delete(`${SERVICE_URL}${contactId}/scoped`);\r\n\t\t}\r\n\r\n\t\tfunction create(contact) {\r\n\t\t\treturn sdHttp.post(SERVICE_URL, contact)\r\n\t\t\t\t.then(function (response) {\r\n\t\t\t\t\t_contacts.push(response);\r\n\t\t\t\t\treturn response;\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction getContactSignature(userId) {\r\n\t\t\treturn sdHttp.get(SERVICE_URL + userId + '/Signature')\r\n\t\t\t\t.then(function (response) {\r\n\t\t\t\t\treturn response;\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction saveContactSignature(contactId, signatureBase64) {\r\n\t\t\tvar dto = {\r\n\t\t\t\tcontactId: contactId,\r\n\t\t\t\tsignatureBase64 : signatureBase64\r\n\t\t\t}\r\n\t\t\treturn sdHttp.post(SERVICE_URL + 'Signature/', dto)\r\n\t\t\t\t.then(function (response) {\r\n\t\t\t\t\treturn response;\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\r\n\t\tfunction openContactDialog(contactId, origin, contacts, entityInfo, roles, onTop) {\r\n\r\n\t\t\t//console.log(APP_SOURCE + ' openContactDialog - ', contactId, contacts, entityInfo, roles)\r\n\r\n\t\t\t// problem: this dialog can be called from contact entity panel.\r\n\t\t\t// (contact list has real contacts) or from contacts view (we have list of contactDto objects)\r\n\t\t\t// ToDo: Re-factor contact detail dialog to better handle problem described above.\r\n\r\n\t\t\tif (entityInfo === undefined) {\r\n entityInfo = null;\r\n }\r\n\r\n\t\t\tif (roles === undefined) {\r\n roles = null;\r\n }\r\n\r\n\t\t\tconst modalConfig = {\r\n\t\t\t\ttemplateUrl: 'app/Contact/View/_contactViewModal.html',\r\n\t\t\t\tcontroller: 'sd.Contact.View.Modal.Controller',\r\n\t\t\t\tcontrollerAs: 'vm',\r\n\t\t\t\tsize: 'xl',\r\n\t\t\t\twindowClass: 'ace-modal show' + (onTop ? ' modal-on-top' : ''),\r\n\t\t\t\tbackdropClass: 'show',\r\n\t\t\t\tresolve: {\r\n\t\t\t\t\tcontactId: function () {\r\n\t\t\t\t\t\treturn contactId;\r\n\t\t\t\t\t},\r\n\t\t\t\t\tentityInfo: function () {\r\n\t\t\t\t\t\treturn entityInfo;\r\n\t\t\t\t\t},\r\n\t\t\t\t\troles: function () {\r\n\t\t\t\t\t\treturn roles;\r\n\t\t\t\t\t},\r\n\t\t\t\t\torigin: function() {\r\n\t\t\t\t\t\treturn origin;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tconst modalInstance = $uibModal.open(modalConfig);\r\n\r\n\t\t\treturn modalInstance.result\r\n\t\t\t\t.then(function (contact) {\r\n\r\n\t\t\t\t\t//console.log('contact dialog - result: ', contact);\r\n\r\n\t\t\t\t\tif (contact) {\r\n\t\t\t\t\t\tconst i = _.findIndex(_contacts, {\r\n\t\t\t\t\t\t\tcontactID: contact.contactID\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\tif (i < 0) {\r\n\t\t\t\t\t\t\t// this was a new contact, lets insert it\r\n\t\t\t\t\t\t\t_contacts.push(contact);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\t// updating existing one\r\n\r\n\t\t\t\t\t\t\t// todo: what is going on here ???\r\n\r\n\t\t\t\t\t\t\t// array element might have 2 custom properties used by Contacts page (if loaded in dialog mode)\r\n\t\t\t\t\t\t\t// transferring these properties\r\n\t\t\t\t\t\t\t//\r\n\t\t\t\t\t\t\tcontact.isVisible = _contacts[i].isVisible;\r\n\t\t\t\t\t\t\tif (_contacts[i].availableRoles)\r\n\t\t\t\t\t\t\t\tcontact.availableRoles = _contacts[i].availableRoles;\r\n\t\t\t\t\t\t\telse if (entityInfo)\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t// this is actually a new contact, but it has been inserted already\r\n\t\t\t\t\t\t\t\t// todo - refactor this mess\r\n\t\t\t\t\t\t\t\t//\r\n\t\t\t\t\t\t\t\troleService.getAvailableRolesForContactEntityCombinationAPI(contact.contactID, entityInfo).then(function (someRoles) {\r\n\t\t\t\t\t\t\t\t\t//console.log('got available roles - ', someRoles);\r\n\t\t\t\t\t\t\t\t\tcontact.availableRoles = someRoles;\r\n\t\t\t\t\t\t\t\t\tcopyContactProperties(contact, _contacts[i]);\r\n\t\t\t\t\t\t\t\t})\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tcopyContactProperties(contact, _contacts[i]);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\t_.remove(_contacts, {\r\n\t\t\t\t\t\t\tcontactID: contactId\r\n\t\t\t\t\t\t});\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\treturn contact;\r\n\t\t\t\t})\r\n\t\t}\r\n\r\n\t\tfunction launchRecipientContactModal(paymentPackageId) {\r\n return $q(function(resolve) {\r\n var modalScope = $rootScope.$new();\r\n modalScope.dialogParameters = {\r\n recipientMode: true,\r\n entityInfo: {\r\n id: paymentPackageId,\r\n type: EntityTypeIDs.PAYMENTPACKAGE\r\n }\r\n };\r\n\r\n var modalConfig = {\r\n templateUrl: 'app/Contact/List/_contactList.html',\r\n controller: 'sd.Contacts.List.Controller',\r\n size: 'lg',\r\n windowClass: 'associate-contact-modal show',\r\n controllerAs: 'vm',\r\n\t\t\t\t\tbackdropClass: 'show',\r\n scope: modalScope\r\n };\r\n\r\n var modalInstance = $uibModal.open(modalConfig);\r\n\r\n modalInstance.result\r\n .then(function (response) {\r\n resolve(response);\r\n });\r\n });\r\n }\r\n\r\n\t\tfunction getAvailableRoles(roles, contact, entityInfo) {\r\n\t\t\t// using local data - no trips to the server.\r\n\t\t\treturn _.filter(roles, function (role) {\r\n\t\t\t\tif (!role[entityInfo.type]) {\r\n\t\t\t\t\treturn false;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (!contact.contactRoleAssociations) {\r\n\t\t\t\t\tcontact.contactRoleAssociations = [];\r\n\t\t\t\t}\r\n\r\n\t\t\t\tvar existingRoles = _.filter(contact.contactRoleAssociations, function (item) {\r\n\t\t\t\t\tvar result =\r\n\t\t\t\t\t\t(\r\n\t\t\t\t\t\t\t(item.contactRoleID == role.contactRoleID) &&\r\n\t\t\t\t\t\t\t(item.entityID == entityInfo.id) &&\r\n\t\t\t\t\t\t\t(item.entityType == entityInfo.type)\r\n\t\t\t\t\t\t);\r\n\t\t\t\t\treturn result;\r\n\t\t\t\t})\r\n\r\n\t\t\t\t// this contact doesn't have this role yet.\r\n\t\t\t\treturn (existingRoles.length == 0);\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction getCached() {\r\n\t\t\treturn _contacts;\r\n\t\t}\r\n\r\n\t\tfunction addToCache(contact) {\r\n\t\t\t_contacts.push(contact);\r\n\t\t}\r\n\r\n\t\tfunction createUser(contactId, user) {\r\n\t\t\treturn sdHttp.post(`${SERVICE_URL}${contactId}/user`,user);\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:Contacts.List.Controller\r\n * @description\r\n * The list of all contacts in the system is available from the main Weissman menu.\r\n * Permissions will likely be limited to only internal (non-client) users.\r\n * Controller of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\t// ToDo: Shouldn't this be called sd.Contacts.Search.Results.Controller?\r\n\tvar APP_SOURCE = 'sd.Contacts.List.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'sdLogger',\r\n\t\t'$scope',\r\n\t\t'$state',\r\n\t\t'sd.Contacts.Service',\r\n\t\t'roleService',\r\n\t\t'utils',\r\n\t\t'userInstanceService',\r\n\t\t'ContactModalOrigin',\r\n 'sd.Contacts.Service.old'\r\n\t];\r\n\r\n\t// ToDo: Clean this pile up and get in-line with our standard!\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(sdLogger, $scope, $state, contactService, roleService, utils, userInstanceService, ContactModalOrigin, contactModalService) {\r\n\t\t/* jshint validthis:true */\r\n\t\tvar vm = this;\r\n\t\tvar lastSearch = '';\r\n\t\t$scope.gettingDataForTheFirstTime = true;\r\n\t\tvm.dialogMode = !!$scope.dialogParameters;\r\n\t\tvm.notAllowedRoles = []; //Dima: list of roles, which needs to be removed from the drop down list.E.g. for entity contacts, we can select only one Tax Bill Recipient\r\n\r\n\t\tif (vm.dialogMode) {\r\n\t\t\tvm.recipientMode = $scope.dialogParameters.recipientMode;\r\n\t\t} else {\r\n\t\t\tvm.recipientMode = false;\r\n\t\t}\r\n\r\n\t\tvm.contacts = [];\r\n\t\tvm.pageNumber = 0;\r\n\t\tvm.pageSize = 50;\r\n\t\tvm.filter = '';\r\n\t\tvm.filterValidationError = '';\r\n\t\tvm.oldFilter = '';\r\n\t\tvm.header = 'Contacts';\r\n\t\tvm.noMoreData = false;\r\n\t\tvm.gettingContactRoles = false;\r\n\t\tvm.excludeInactive = userInstanceService.isCurrentInstanceSystem() ? false : true;\r\n\r\n\t\tif (vm.dialogMode) {\r\n vm.entityInfo = $scope.$parent.dialogParameters.entityInfo;\r\n if (!vm.recipientMode) {\r\n vm.selectedContact = null;\r\n vm.notAllowedRoles = $scope.$parent.dialogParameters.notAllowedRoles;\r\n console.log(APP_SOURCE, vm.entityInfo);\r\n vm.header = 'Associate Contact to ' + utils.getEntityName(vm.entityInfo.id);\r\n }\r\n\t\t}\r\n\r\n\t\t$scope.validateFilter = function () {\r\n\t\t\tif (vm.filter.length > 100) {\r\n\t\t\t\tvm.filterValidationError = 'Filter length should be 100 characters or less';\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\tvm.filterValidationError = '';\r\n\t\t}\r\n\r\n\t\t$scope.recipientTypes = {\r\n\t\t\tResponsibleParty: 1,\r\n\t\t\tCc: 2,\r\n\t\t\tBcc: 3\r\n\t\t}\r\n\r\n\t\t$scope.searchContactsOnServer = function (searchText, excludeInactiveChanged) {\r\n\t\t\tif (!searchText) {\r\n\t\t\t\tsearchText = '';\r\n\t\t\t}\r\n\r\n\t\t\t$scope.validateFilter();\r\n\r\n\t\t\tif (vm.filterValidationError !== '') {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tvm.filter = searchText;\r\n\r\n\t\t\tif (searchText !== vm.oldFilter || excludeInactiveChanged) {\r\n\t\t\t\tvm.oldFilter = searchText;\r\n\t\t\t\tvm.pageNumber = 1;\r\n\t\t\t\tvm.noMoreData = false;\r\n\t\t\t\tvm.contacts = [];\r\n\t\t\t} else {\r\n\t\t\t\tvm.pageNumber++;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.noMoreData) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.contacts.length === 0) {\r\n\t\t\t\t$scope.gettingDataForTheFirstTime = true;\r\n\t\t\t} else {\r\n\t\t\t\t$scope.gettingMoreData = true;\r\n\t\t\t}\r\n\r\n\t\t\tvar searchPromise;\r\n\r\n\t\t\tif(vm.dialogMode) {\r\n\t\t\t\tif(vm.entityInfo.type === 'assessor' || vm.entityInfo.type === 'state' || vm.entityInfo.type === 'collector') {\r\n\t\t\t\t\tsearchPromise = contactService.searchRyan(searchText, vm.pageNumber, vm.pageSize, vm.excludeInactive);\r\n\t\t\t\t} else {\r\n\t\t\t\t\tsearchPromise = contactService.searchScoped(vm.entityInfo.id, vm.entityInfo.type, searchText, vm.pageNumber, vm.pageSize, vm.excludeInactive)\r\n\t\t\t\t}\r\n\t\t\t} else {\r\n\t\t\t\tsearchPromise = contactService.search(userInstanceService.getSelectedInstance().instanceId, searchText, vm.pageNumber, vm.pageSize, vm.excludeInactive);\r\n\t\t\t}\r\n\r\n\t\t\tsearchPromise.then(function (result) {\r\n\t\t\t\tif (!result.length || result.length === 0) {\r\n\t\t\t\t\tvm.noMoreData = true;\r\n\t\t\t\t} else {\r\n\t\t\t\t\tvm.contacts = vm.contacts.concat(result);\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (result.length < vm.pageSize) {\r\n\t\t\t\t\tvm.noMoreData = true;\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$scope.gettingDataForTheFirstTime = false;\r\n\t\t\t\t$scope.gettingMoreData = false;\r\n\t\t\t})\r\n\t\t\t.catch(function (error) {\r\n\t\t\t\terror.appSource = APP_SOURCE;\r\n\t\t\t\tsdLogger.error('Error', error.data.message, error);\r\n\t\t\t\t$scope.gettingDataForTheFirstTime = false;\r\n\t\t\t\t$scope.gettingMoreData = false;\r\n\t\t\t})\r\n\t\t\t.finally(function(){\r\n\t\t\t\tlastSearch = searchText;\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction activate() {\r\n\r\n\t\t\t//console.log('activate');\r\n\t\t\t$scope.gettingDataForTheFirstTime = true;\r\n\t\t\tif (vm.dialogMode) {\r\n\t\t\t\t// get roles first they will be needed in order to set available roles for each contact\r\n\t\t\t\t//\r\n\t\t\t\troleService.get().then(function (result) {\r\n\t\t\t\t\tvm.roles = result;\r\n\t\t\t\t\t//console.log('we got roles! vm.roles:', vm.roles);\r\n\r\n\t\t\t\t\t// now get all contacts\r\n\t\t\t\t\t$scope.searchContactsOnServer('');\r\n\t\t\t\t})\r\n\t\t\t} else {\r\n\t\t\t\t// we don't need roles, just load contacts\r\n\t\t\t\t//\r\n\t\t\t\t$scope.searchContactsOnServer('');\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tactivate();\r\n\r\n\t\t$scope.clearFilter = function () {\r\n\t\t\tvm.filter = '';\r\n\r\n\t\t\tif (lastSearch) {\r\n\t\t\t\t$scope.searchContactsOnServer('');\r\n\t\t\t}\r\n\t\t};\r\n\r\n\t\t$scope.openCompanyPage = function (companyId) {\r\n\t\t\t$state.go('company', {\r\n\t\t\t\tcompanyId: companyId\r\n\t\t\t});\r\n\t\t\tif (vm.dialogMode) {\r\n\t\t\t\t$scope.$close();\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t$scope.openContactDialog = function (contactId, allContacts) {\r\n\t\t\tcontactModalService.openContactDialog(contactId, ContactModalOrigin.ContactsList)\r\n\t\t\t\t.then(function (contact) {\r\n\t\t\t\t\tconsole.log(contact)\r\n\t\t\t\t\t//var editedContact = _.find(allContacts, {\r\n\t\t\t\t\t//\tcontactID: contactId\r\n\t\t\t\t\t//});\r\n\r\n\t\t\t\t\t//var index = allContacts.indexOf(editedContact);\r\n\t\t\t\t\t//allContacts[index] = editedContact;\r\n\r\n\t\t\t\t\t//var index = _.findIndex(vm.active.letter.list, {\r\n\t\t\t\t\t//\tcontactID: contactId\r\n\t\t\t\t\t//});\r\n\r\n\t\t\t\t\t//vm.active.letter.list[index] = editedContact;\r\n\r\n\t\t\t\t\tif(!contact) {\r\n\t\t\t\t\t\t$scope.clearFilter();\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\t\t$scope.getAnyContactPhone = function (contact) {\r\n\t\t\tif (!contact) {\r\n\t\t\t\treturn '';\r\n\t\t\t}\r\n\r\n\t\t\tif (contact.phone) {\r\n\t\t\t\tif (contact.ext) {\r\n\t\t\t\t\treturn contact.phone + ' x' + contact.ext;\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\treturn contact.phone;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tif (contact.mobilePhone) {\r\n\t\t\t\treturn contact.mobilePhone;\r\n\t\t\t}\r\n\r\n\t\t\treturn '';\r\n\t\t}\r\n\r\n\t\t$scope.associateRole = function (contact) {\r\n\t\t\tvar result = {\r\n\t\t\t\tcontact: contact,\r\n\t\t\t\tselectedRole: contact.selectedRole\r\n\t\t\t};\r\n\t\t\t$scope.$close(result);\r\n\t\t};\r\n\r\n\t\t$scope.closeDialog = function () {\r\n\t\t\tvar selectedContacts = _.filter(vm.contacts, { 'selected': true });\r\n\t\t\t$scope.$close(selectedContacts);\r\n\t\t}\r\n\r\n\t\t$scope.closeRecipientDialog = function (recipientType) {\r\n\t\t\tvar selectedContacts = _.filter(vm.contacts, { 'selected': true });\r\n\t\t\tvar returnObject = {\r\n\t\t\t\trecipients: selectedContacts,\r\n\t\t\t\trecipientType: recipientType\r\n\t\t\t}\r\n\t\t\t$scope.$close(returnObject);\r\n\t\t}\r\n\r\n\t\t$scope.selectContact = function (contactDto) {\r\n\t\t\tif (vm.recipientMode) { return; }\r\n\t\t\t//console.log('selecting contact', contactDto);\r\n\r\n\t\t\t// deselect other contacts\r\n\t\t\t//\r\n\t\t\tfor (var i = 0; i < vm.contacts.length; i++) {\r\n\t\t\t\tif (vm.contacts[i].contactID !== contactDto.contactID) {\r\n\t\t\t\t\tvm.contacts[i].selected = false;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\t// did we get all available roles for this contact already?\r\n\t\t\tif (contactDto.availableRoles) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tvm.gettingContactRoles = true;\r\n\t\t\t//contactDto.selected = false;\t// to keep it from expanding before we got available roles\r\n\r\n\t\t\t//console.log('getting roles for contact and entity: ', vm.entityInfo);\r\n\r\n\t\t\troleService.getAvailableRolesForContactEntityCombinationAPI(contactDto.contactID, vm.entityInfo).then(function (someRoles) {\r\n\t\t\t\t//console.log('got available roles - ', someRoles);\r\n\t\t\t\tcontactDto.availableRoles = someRoles.filter(function (role) {\r\n\t\t\t\t\treturn vm.notAllowedRoles.indexOf(role.contactRoleID) === -1;\r\n\t\t\t\t});\r\n\t\t\t\tvm.gettingContactRoles = false;\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\t$scope.checkForEnterKey = function (keyEvent) {\r\n\t\t\tif (keyEvent.which === 13) {\r\n\t\t\t\t$scope.searchContactsOnServer(vm.filter);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t$scope.cancelContactAssignRole = function (contact) {\r\n\t\t\tcontact.selectedRole = null;\r\n\t\t\tcontact.selected = false;\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'DocumentService';\r\n\tvar SERVICE_URL = '/api/DocumentIntake/';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = ['Upload', 'authStorageService', '$http', 'sd.Http.Service', 'toastr', '$q'];\r\n\r\n\tfunction Service(Upload, authStorageService, $http, sdHttp, toastr, $q) {\r\n\t\tvar service = {\r\n\t\t\tsendBatchDocuments: sendBatchDocuments,\r\n\t\t\tgetDocumentBody: getDocumentBody,\r\n\t\t\tgetDocumentInfo: getDocumentInfo,\r\n\t\t\tgetDocumentInfoByTaskId: getDocumentInfoByTaskId,\r\n\t\t\tgetTaskInfo: getTaskInfo,\r\n getTaskInfoByTaskID: getTaskInfoByTaskID,\r\n\t\t\tmapDocumentToEntity: mapDocumentToEntity,\r\n\t\t\tsaveFile: saveFile,\r\n\t\t\tput: put\r\n\t\t};\r\n\t\treturn service;\r\n\r\n\t\tfunction sendBatchDocuments(options, files) {\r\n\t\t\tvar authData = authStorageService.getAuthData();\r\n\r\n\t\t\treturn Upload.upload({\r\n\t\t\t\turl: SERVICE_URL + 'Batch',\r\n\t\t\t\tdata: {\r\n\t\t\t\t\tintakeInfo: encodeURIComponent(JSON.stringify(options)),\r\n\t\t\t\t\t//headers: { 'Authorization': 'Bearer ' + authData.assess_token },\r\n\t\t\t\t\tfile: files\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction getDocumentBody(id) {\r\n\t\t return $q(function (resolve, reject) {\r\n return $http({\r\n url: '/api/attachment/' + id,\r\n method: 'GET',\r\n responseType: 'arraybuffer'\r\n }).then(function (result) {\r\n if (!result.headers('Content-Disposition')) {\r\n toastr.error(\"Document not found\");\r\n reject();\r\n }\r\n else {\r\n resolve.apply(this, arguments);\r\n }\r\n }, reject);\r\n\t\t });\r\n\t\t}\r\n\r\n\t\tfunction getDocumentInfo(id) {\r\n\t\t\treturn sdHttp.get(SERVICE_URL + id);\r\n\t\t}\r\n\r\n\t\tfunction getDocumentInfoByTaskId(id) {\r\n\t\t return sdHttp.get(SERVICE_URL + 'task/' + id);\r\n\t\t}\r\n\r\n\t\tfunction getTaskInfo(id) {\r\n\t\t return sdHttp.get(SERVICE_URL + id + '/taskInfo');\r\n\t\t}\r\n\r\n\t\tfunction getTaskInfoByTaskID(id) {\r\n\t\t return sdHttp.get(SERVICE_URL + 'task/' + id + '/taskInfo');\r\n }\r\n\r\n\t\tfunction saveFile(blob, fileName) {\r\n\t\t\tvar saveBlob = saveAs || navigator.webkitSaveBlob || navigator.mozSaveBlob || navigator.saveBlob || navigator.msSaveBlob;\r\n\r\n\t\t\tsaveBlob(blob, fileName)\r\n\t\t}\r\n\r\n\t\tfunction mapDocumentToEntity(id, data) {\r\n\t\t return sdHttp.patch(SERVICE_URL + id, data);\r\n\t\t}\t\t\r\n\r\n\t\tfunction put(data) {\r\n\t\t return sdHttp.put(SERVICE_URL, data);\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\t\r\n\tvar PAGE_SIZE = 8;\r\n\tvar PAGE_NUMBER = 1;\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdCompanyPicker', sdCompanyPicker);\r\n\r\n\tfunction sdCompanyPicker() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Entity/Company/Picker/_companyPicker.html',\r\n\t\t\tscope: {\r\n\t\t\t\tcompanyId: '=?',\r\n\t\t\t\tcompanyName: '=?',\r\n\t\t\t\tappendToBody: '=?',\r\n\t\t\t\ttopLevelOnly: '=?',\r\n\t\t\t\tfavoritesOnly: '=?',\r\n\t\t\t\tactiveOnly: '=?'\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n\r\n\tController.$inject = [\r\n\t\t'sd.Company.Service'\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(companyService) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.company = {\r\n\t\t\tcompanyID: vm.companyID || null,\r\n\t\t\tcompanyName: vm.companyName || null\r\n\t\t};\r\n\r\n\t\tvm.getCompanies = function(searchTerm) {\r\n\t\t\treturn companyService.search(searchTerm, PAGE_SIZE, PAGE_NUMBER, vm.topLevelOnly, vm.favoritesOnly, vm.activeOnly);\r\n\t\t}\r\n\r\n\t\tvm.companySelected = function() {\r\n\t\t\tvm.companyId = vm.company.companyID;\r\n\t\t\tvm.companyName = vm.company.companyName;\r\n\t\t}\r\n\r\n\t\tvm.checkForBlank = function() {\r\n\t\t\tif(!vm.company) {\r\n\t\t\t\tvm.companyId = null;\r\n\t\t\t\tvm.companyName = '';\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Parcel.Activity.Modal.Controller';\r\n\r\n\t/**\r\n\t * @ngdoc function\r\n\t * @name weissmanApp.controller:Parcel.Activity.Modal.Controller\r\n\t * @description\r\n\t * # Parcel.Activity.Modal.Controller\r\n\t * Controller of the weissmanApp\r\n\t */\r\n\tangular.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'$uibModalInstance',\r\n\t\t'params',\r\n\t\t'parcelYears'\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit($uibModalInstance, params, parcelYears) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.params = params;\r\n\t\tvm.years = parcelYears;\r\n\r\n\t\tvm.close = close\r\n\r\n\t\tfunction close() {\r\n\t\t\t$uibModalInstance.dismiss();\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n 'use strict';\r\n\r\n angular\r\n .module('weissmanApp')\r\n .factory('ParcelActivityModalService', Service);\r\n\r\n Service.$inject = ['$uibModal'];\r\n\r\n function Service($uibModal) {\r\n return {\r\n open: open\r\n };\r\n\r\n function open(parcelID, siteID, years) {\r\n $uibModal.open({\r\n templateUrl: 'app/Entity/Parcel/Info/Activity/_parcelActivityModal.html',\r\n controller: 'sd.Parcel.Activity.Modal.Controller',\r\n controllerAs: 'vm',\r\n size: 'lg',\r\n windowClass: 'show',\r\n backdropClass: 'show',\r\n resolve: {\r\n params: function () {\r\n return {\r\n parcelId: parcelID,\r\n siteId: siteID\r\n }\r\n },\r\n parcelYears: function () {\r\n return years;\r\n }\r\n }\r\n });\r\n }\r\n }\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:sd.Attachment.Modal.Controller\r\n * @description\r\n * Controller for the Attachments modal dialog\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'Parcel.LegalDescription.Modal.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'sdLogger',\r\n\t\t'$scope',\r\n\t\t'$uibModalInstance',\r\n\t\t'dialogData'\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(\r\n\t\tsdLogger,\r\n\t\t$scope,\r\n\t\t$uibModalInstance,\r\n\t\tdialogData\r\n\t\t) {\r\n\t\t/* jshint validthis:true */\r\n\r\n\t\tvar vm = this;\r\n\t\tvm.closeModal = closeModal;\r\n\t\tvm.dialogData = dialogData;\r\n\t\tvm.oldValue = dialogData.legalDescription;\r\n\t\tvm.escapeMode = false;\r\n\r\n\t\tactivate();\r\n\r\n\r\n\t\tfunction activate() {\r\n\t\t}\r\n\r\n\r\n\t\tfunction logError(error) {\r\n\t\t\tsdLogger.log(APP_SOURCE + '.activate(): ', {\r\n\t\t\t\t'error': error\r\n\t\t\t});\r\n\t\t\tvm.loading = false;\r\n\t\t}\r\n\r\n\r\n\t\t// reacting to esc button (or if user clicks outside of the dialog)\r\n\t\t// we can't pass dialog value back to controller\r\n\t\t// we will store it in the service instead\r\n\t\t//\r\n\t\t$scope.$on('modal.closing', function (event, reason, closed) {\r\n\t\t\t//console.log('modal.closing: ', event, reason, closed);\r\n\t\t\tif (!vm.dialogData.editMode || dialogData.legalDescription == vm.oldValue)\r\n\t\t\t\treturn;\r\n\r\n\t\t\tif (\r\n\t\t\t\t reason === \"backdrop click\" \r\n\t\t\t\t|| reason === \"cancel\" \r\n\t\t\t\t|| reason === \"escape key press\"\r\n\t\t\t\t|| (closed == true && vm.escapeMode == true))\t// \"close\" button - upper right corner\r\n\t\t\t{\r\n\t\t\t\tif (!confirm('Any changes will be discarded, are you sure?'))\r\n\t\t\t\t\tevent.preventDefault();\r\n\t\t\t\telse\r\n\t\t\t\t\tdialogData.legalDescription = vm.oldValue;\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\tfunction closeModal(escapeMode) {\r\n\t\t\tvm.escapeMode = escapeMode;\r\n\t\t\t$uibModalInstance.close(vm.dialogData);\r\n\t\t}\r\n\r\n\t}\r\n})();\r\n","'use strict';\r\n\r\nangular.module('weissmanApp').controller('RedirectCtrl', [\r\n '$state',\r\n '$stateParams',\r\n 'processingService',\r\n 'sd.Assessor.Collector.Service',\r\n 'entityTypeID',\r\n 'EntityTypeIDs',\r\n 'EntityTypeNames',\r\n 'sd.Navigation.Service',\r\n 'billClusterService',\r\n weissNg1Wrap(function (\r\n $state,\r\n $stateParams,\r\n processingService,\r\n assessorCollectorService,\r\n entityTypeID,\r\n EntityTypeIDs,\r\n EntityTypeNames,\r\n navigationService,\r\n billClusterService\r\n ) {\r\n\r\n navigate(entityTypeID, $stateParams.entityID);\r\n\r\n function navigate(entityTypeID, entityID) {\r\n if (entityTypeID === EntityTypeIDs.ASSESSOR) {\r\n assessorCollectorService.getNavigationInfo('assessor', entityID).then(function (info) {\r\n $state.transitionTo('assessor', {\r\n stateId: info.stateID,\r\n id: info.assessorID\r\n }, { location: 'replace' });\r\n });\r\n }\r\n else if (entityTypeID === EntityTypeIDs.COLLECTOR) {\r\n assessorCollectorService.getNavigationInfo('collector', entityID).then(function (info) {\r\n $state.transitionTo('collector', {\r\n stateId: info.stateID,\r\n stateCollectorId: info.collectorID\r\n }, { location: 'replace' });\r\n });\r\n }\r\n else if (entityTypeID === EntityTypeIDs.INVOICE) {\r\n navigationService.getNavigationInfo(EntityTypeNames[EntityTypeIDs.INVOICE], entityID).then(function (info) {\r\n var route = 'companyInvoice';\r\n var config = {\r\n companyID: info.companyID,\r\n invoiceID: entityID\r\n };\r\n if (info.siteID) {\r\n route = 'siteInvoice';\r\n config.siteID = info.siteID\r\n }\r\n $state.transitionTo(route, config, { location: 'replace' });\r\n });\r\n }\r\n else if (entityTypeID === EntityTypeIDs.FilingBatch) {\r\n navigationService.getNavigationInfo('filingBatch', entityID).then(function (info) {\r\n const config = {\r\n companyId: info.companyID,\r\n filingBatchId: entityID\r\n };\r\n $state.transitionTo('filingBatchDetails', config, { location: 'replace' });\r\n });\r\n }\r\n else if (entityTypeID === EntityTypeIDs.BILL_CLUSTER) {\r\n billClusterService.getBillClusterByID(entityID).then(function (billCluster) {\r\n navigate(EntityTypeIDs.TAX_BILL, billCluster.bills[0].billID);\r\n });\r\n }\r\n else {\r\n processingService.getEntityTree(entityTypeID, entityID).then(function (tree) {\r\n var transitionState = {\r\n companyId: tree.subsidiaryCompany.entityId,\r\n siteId: tree.site.entityId\r\n };\r\n switch (entityTypeID) {\r\n case EntityTypeIDs.SITE:\r\n $state.transitionTo('site', transitionState, { location: 'replace' });\r\n break;\r\n case EntityTypeIDs.PARCEL:\r\n $state.transitionTo('parcel', _.extend({}, transitionState, {\r\n parcelId: tree.parcel.entityId\r\n }), { location: 'replace' });\r\n break;\r\n case EntityTypeIDs.ASSESSMENT:\r\n $state.transitionTo('parcel', _.extend({}, transitionState, {\r\n parcelId: tree.parcel.entityId,\r\n annualYearID: tree.annualYear.entityId,\r\n annualAssessmentID: tree.revision.entityId\r\n }), { location: 'replace' });\r\n break;\r\n case EntityTypeIDs.APPEAL:\r\n $state.transitionTo('parcel', _.extend({}, transitionState, {\r\n parcelId: tree.parcel.entityId,\r\n annualYearID: tree.annualYear.entityId,\r\n annualAssessmentID: tree.revision.entityId,\r\n appealID: tree.appeal.entityId\r\n }), { location: 'replace' });\r\n break;\r\n case EntityTypeIDs.TAX_BILL:\r\n case EntityTypeIDs.PAYMENT:\r\n $state.transitionTo('parcel', _.extend({}, transitionState, {\r\n parcelId: tree.parcel.entityId,\r\n annualYearID: tree.annualYear.entityId,\r\n billClusterID: tree.billCluster.entityId\r\n }), { location: 'replace' });\r\n break;\r\n case EntityTypeIDs.REFUND:\r\n $state.transitionTo('parcel', _.extend({}, transitionState, {\r\n parcelId: tree.parcel.entityId,\r\n annualYearID: tree.annualYear.entityId,\r\n refundID: tree.refund.entityId\r\n }), { location: 'replace' });\r\n break;\r\n case EntityTypeIDs.FILING:\r\n $state.transitionTo('parcel', _.extend({}, transitionState, {\r\n parcelId: tree.parcel.entityId,\r\n annualYearID: tree.annualYear.entityId,\r\n filingId: tree.filing.entityId\r\n }), { location: 'replace' });\r\n break;\r\n default:\r\n throw new Error('Entity type ID invalid or missing (got: ' + entityTypeID + ')');\r\n }\r\n });\r\n }\r\n }\r\n })\r\n]);\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:Site.Contacts.Panel.Controller\r\n * @description\r\n * # Site Contacts Panel\r\n * Controller of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Site.Contacts.Panel.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'sdLogger',\r\n\t\t'$stateParams',\r\n\t\t'sd.Site.Service',\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(sdLogger, $stateParams, siteService) {\r\n\t\t/* jshint validthis:true */\r\n\t\tvar vm = this;\r\n\t\tvm.entity = {};\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\t\t\tvm.entity = {\r\n\t\t\t\tid: Number($stateParams.siteId),\r\n\t\t\t\tname: siteService.get().name,\r\n\t\t\t\t// ToDo: Create a global entity enum that encapsulates type and typeid?\r\n\t\t\t\ttype: 'site',\r\n\t\t\t\ttypeId: 5,\r\n\t\t\t\tnewAllowed: false,\r\n\t\t\t};\r\n\r\n\t\t\tsdLogger.log(APP_SOURCE + '.activate(): ', {\r\n\t\t\t\t'vm': vm,\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n 'use strict';\r\n\r\n angular.module('weissmanApp').factory('StartupService', Service);\r\n\r\n Service.$inject = ['sd.Navigation.Service', '$transitions'];\r\n\r\n function Service(navigationService, $transitions) {\r\n return {\r\n initializeNavService: initializeNavService\r\n };\r\n\r\n // Fixes an issue where the navStart hook was not firing for the first navigation, and that's necessary for getting auth\r\n // data filled in before the UI is rendered.\r\n function initializeNavService() {\r\n $transitions.onStart({}, navigationService.onNavStart);\r\n }\r\n }\r\n})();\r\n","(function () {\r\n \"use strict\";\r\n /* The upgrade from AngularJS 1.5 to 1.6 changed how controller functions are\r\n * bound. Since the majority of Weissman was written in Angular 1.4, our\r\n * conventions are somewhat out of date. The weissNg1Wrap functions are shims\r\n * that allowed a minimally-invasive fix to allow the upgrade to continue, but\r\n * it requires a bit of boilerplate. Generally, it is expected that collector\r\n * declarations will work one of two ways. The first approach looks like this: \r\n\r\n angular.module('weissmanApp')\r\n .controller('myController', ['dep1', function (dep1) {\r\n var vm = this;\r\n }\r\n ]);\r\n\r\n * And the second approach looks like this:\r\n \r\n\tangular.module('weissmanApp')\r\n\t\t.controller('myController', Controller);\r\n\r\n Controller.$inject = ['dep1'];\r\n\r\n function Controller(dep1) {\r\n var vm = this;\r\n }\r\n\r\n * In both cases, our application code generally expects bindings to happen\r\n * before the controller function is called, and that no longer happens in\r\n * AngularJS 1.6+. The weissNg1Wrap function exists to correct the first form of\r\n * controller declaration above and the weissNg1WrapFunc funtion exists for the\r\n * second form. The above first example would now look like:\r\n\r\n angular.module('weissmanApp')\r\n .controller('myController', ['dep1', weissNg1Wrap(function (dep1) {\r\n var vm = this;\r\n })\r\n ]);\r\n\r\n * And the second example would look like:\r\n\r\n\tangular.module('weissmanApp')\r\n\t\t.controller('myController', Controller);\r\n\r\n Controller.$inject = ['dep1'];\r\n\r\n function Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(dep1) {\r\n var vm = this;\r\n }\r\n\r\n * Note that ideally, in the future we'll write controllers following the newer\r\n * AngularJS conventions instead of leaning on these shims; this was just to\r\n * allow the upgrade to continue without a massive refactor.\r\n */\r\n window.weissNg1Wrap = function (controller) {\r\n return function () {\r\n var args = arguments;\r\n this.$onInit = function () {\r\n controller.apply(this, args);\r\n };\r\n };\r\n };\r\n\r\n window.weissNg1WrapFunc = function (init, args, _this) {\r\n _this.$onInit = function () {\r\n init.apply(this, args);\r\n };\r\n };\r\n}());\r\n","(function () {\r\n 'use strict';\r\n\r\n var APP_SOURCE = 'sdNavbarTopService';\r\n\r\n angular\r\n .module('weissmanApp')\r\n .factory(APP_SOURCE, Service);\r\n\r\n Service.$inject = [\r\n '$location',\r\n '$window'\r\n ];\r\n\r\n function Service($location, $window) {\r\n var showNavbar = true;\r\n var fullScreen = false;\r\n\r\n var service = {\r\n showNavbar: showNavbar,\r\n fullScreen: fullScreen\r\n };\r\n\r\n service.showEmailWindow = function(route, itemName, itemType){\r\n var subject = 'Shared ' + itemType;\r\n\r\n var url = route;\r\n // Get rid of leading #\r\n if (url[0] === '#') {\r\n url = url.substr(1);\r\n }\r\n\r\n url = $location.url(url).absUrl();\r\n\r\n var body = encodeURIComponent(\r\n 'Hello.\\r\\n\\r\\n' +\r\n 'Click on the link below to access the ' + itemType + ' \"' + itemName + '\" which has been shared with you in PropertyPoint.\\r\\n\\r\\n' +\r\n 'You may run it directly or, after opening it, save it as one of your own ' + itemType + 's by clicking Save As.\\r\\n\\r\\n' +\r\n url + '\\r\\n\\r\\n'\r\n );\r\n\r\n $window.open(\"mailto:\" + '' + \"?subject=\" + subject + \"&body=\" + body, \"_self\");\r\n }\r\n\r\n return service;\r\n }\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory('layoutService', Service);\r\n\r\n\tService.$inject = ['appStateService'];\r\n\r\n\tfunction Service(appStateService) {\r\n var service = {\r\n showApp: false,\r\n showMenu: false,\r\n loggedOut: false,\r\n showQuick: false\r\n };\r\n\r\n appStateService.appState$.subscribe(function (state) {\r\n var checkState = function (states) { return states.indexOf(state) >= 0; };\r\n var appStates = appStateService.appStates;\r\n\r\n service.showApp = checkState([appStates.Initialized, appStates.LoggedIn]);\r\n service.showMenu = checkState([appStates.Initialized, appStates.LoggedIn, appStates.LoggingOut]);\r\n service.showQuick = checkState([appStates.LoggedIn]);\r\n service.loggedOut = checkState([appStates.LoggingOut, appStates.LoggedOut]);\r\n });\r\n\r\n return service;\r\n }\r\n}());\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:Application.Permissions.Panel.Controller\r\n * @description\r\n * # Application Permissions Panel\r\n * Controller of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Application.Permissions.Panel.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'sdLogger',\r\n\t\t'sd.Application.Permission.Service',\r\n\t\t'accountService'\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(sdLogger, applicationPermissionService, accountService) {\r\n\t\t/* jshint validthis:true */\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.availablePermissions = [];\r\n\t\tvm.permissionToAdd = null;\r\n\t\tvm.uniqueScreenTypes = [];\r\n\t\tvm.screenTypePermissions = [];\r\n\t\tvm.selectPermissionToAdd = selectPermissionToAdd;\r\n\t\tvm.cancelAddPermission = cancelAddPermission;\r\n\t\tvm.addPermission = addPermission;\r\n\t\tvm.usablePermission = usablePermission;\r\n\t\tvm.screenTypeSelected = screenTypeSelected;\r\n\t\tvm.availablePermissionRights = availablePermissionRights;\r\n\t\tvm.deletePermission = deletePermission;\r\n\t\tvm.getPermissionLabel = getPermissionLabel\r\n\t\tvm.userHasGlobalRole = userHasGlobalRole;\r\n\t\tvm.permissionLookup = [];\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\t\t\tapplicationPermissionService.get()\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t\tvm.availablePermissions = result;\r\n\t\t\t\t\tvm.permissionLookup = _.cloneDeep(vm.availablePermissions);\r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\tvm.uniqueScreenTypes = _.uniqBy(vm.availablePermissions, 'screenTypeID');\r\n\t\t\t\t});\r\n\r\n\t\t\tsdLogger.log(APP_SOURCE + '.activate(): ', {\r\n\t\t\t\t'vm': vm,\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction selectPermissionToAdd() {\r\n\t\t\tvm.permissionToAdd = {};\r\n\t\t}\r\n\r\n\t\tfunction cancelAddPermission() {\r\n\t\t\tvm.permissionToAdd = null;\r\n\t\t}\r\n\r\n\t\tfunction addPermission() {\r\n\t\t\tvm.permissionToAdd.permission.screenTypeID = vm.permissionToAdd.screenTypeID;\r\n\t\t\tvm.permissionToAdd.permission.screenType = vm.permissionToAdd.permission.screenType || getScreenType(vm.permissionToAdd.screenTypeID)\r\n\r\n\t\t\tvm.assignedPermissions.push(vm.permissionToAdd.permission);\r\n\r\n\t\t\tcancelAddPermission();\r\n\t\t}\r\n\r\n\t\tfunction getScreenType(id) {\r\n\t\t\treturn _.find(vm.availablePermissions, {\r\n\t\t\t\tscreenTypeID: id\r\n\t\t\t}).screenType;\r\n\t\t}\r\n\r\n\t\tfunction usablePermission(permission) {\r\n\t\t\tconst roleHasAlreadyAssigned = !_.some(vm.assignedPermissions, {\r\n\t\t\t\tscreenTypeID: permission.screenTypeID\r\n\t\t\t});\r\n\r\n\t\t\tconst userGlobalRoles = accountService.userData.globalRoles;\r\n\t\t\tconst rolesWithSameScreenType = vm.availablePermissions.filter(ap=>ap.screenTypeID == permission.screenTypeID);\r\n\t\t\tconst userHasRoleWithScreenType = userGlobalRoles.some(r=>rolesWithSameScreenType.some(s=>s.name === r));\r\n\r\n\t\t\treturn roleHasAlreadyAssigned && userHasRoleWithScreenType;\r\n\t\t}\r\n\r\n\t\tfunction screenTypeSelected() {\r\n\t\t\tvm.screenTypePermissions = availablePermissionRights(vm.permissionToAdd.screenTypeID);\r\n\r\n\t\t\tvm.permissionToAdd.permission = _.minBy(vm.screenTypePermissions, 'rightsID');\r\n\t\t}\r\n\r\n\t\tfunction availablePermissionRights(id) {\r\n\t\t\tif (vm.availablePermissions.length === 0) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\treturn _.filter(vm.availablePermissions, function(ap){\r\n\t\t\t\treturn ap.screenTypeID == id && accountService.userData.globalRoles.includes(ap.name);\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction deletePermission(permission) {\r\n\t\t\t_.remove(vm.assignedPermissions, permission);\r\n\t\t}\r\n\r\n\t\tfunction getPermissionLabel(roleID) {\r\n\t\t\tvar permission = _.find(vm.permissionLookup, {roleID: roleID})\r\n\r\n\t\t\treturn permission ? permission.rights : '';\r\n\t\t}\r\n\r\n\t\tfunction userHasGlobalRole(permission) {\r\n\t\t\tlet globalRoles = accountService.userData.globalRoles;\r\n\t\t\treturn globalRoles.includes(permission.name);\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar VIEW_TEMPLATE_URL = 'app/Permission/Application/_panel.html';\r\n\tvar CONTROLLER_NAME = 'sd.Application.Permissions.Panel.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdApplicationPermissionsPanel', sdApplicationPermissionsPanel);\r\n\r\n\tsdApplicationPermissionsPanel.$inject = [];\r\n\r\n\tfunction sdApplicationPermissionsPanel() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\tcontroller: CONTROLLER_NAME,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\teditMode: '=',\r\n\t\t\t\tassignedPermissions: '=',\r\n\t\t\t\tuserSetup: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:Company.Permission.Panel.Controller\r\n * @description\r\n * # Company Permission Panel\r\n * Controller of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Company.Permission.Panel.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'$scope',\r\n\t\t'$uibModal',\r\n\t\t'sd.Account.User.Service',\r\n\t\t'utils',\r\n\t\t'sd.Company.Permission.Service',\r\n\t\t'EntityTypeIDs',\r\n\t\t'$interval',\r\n\t\t'userInstanceService',\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit($scope, $uibModal, accountUserService, utils, companyPermissionService, EntityTypeIDs, $interval, userInstanceService) {\r\n\t\t/* jshint validthis:true */\r\n\t\tvar OPT_HIDE = 'Hide';\r\n\t\tvar OPT_VIEW_ALL = 'View All Sites';\r\n\t\tvar OPT_VIEW_EDIT_SOME = 'View/Edit Some Sites';\r\n\t\tvar OPT_EDIT_ALL = 'Edit All Sites';\r\n\r\n\t\tvar EF_ACTION_ADD = 'add';\r\n\t\tvar EF_ACTION_DELETE = 'delete';\r\n\t\tvar EF_ACTION_UPDATE = 'update';\r\n\r\n\t\tvar PAGE_SIZE = 100;\r\n\r\n\t\tvar intervalRef;\r\n\r\n\t\tvar isActivated = false;\r\n\r\n\t\tvar pageNumber = 0;\r\n\r\n\t\tvar user = {};\r\n\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.isBusy = false;\r\n\t\tvm.hasLoadedAllPermissions = false;\r\n\r\n\t\tvm.companyNameFilter = null;\r\n\t\tvm.companyNameFilterChanged = companyNameFilterChanged;\r\n\r\n\t\t// a collection of modified permissions that can be persisted\r\n\t\tvm.assignedPermissions = vm.assignedPermissions || [];\r\n\r\n\t\t// a collection of permissions being displayed on the UI\r\n\t\t// this will change depending on pagination and company name filter\r\n\t\tvm.displayPermissions = [];\r\n\r\n\t\tvm.loadPermissions = _loadPermissions;\r\n\t\tvm.showAdd = _showAdd;\r\n\t\tvm.showSites = _showSites;\r\n\t\tvm.companiesOnly = companiesOnly;\r\n\t\tvm.changePermission = changePermission;\r\n\t\tvm.userInstanceService = userInstanceService;\r\n\r\n\t\tvm.options = [OPT_VIEW_ALL, OPT_VIEW_EDIT_SOME, OPT_EDIT_ALL, OPT_HIDE];\r\n\r\n\t\t$scope.$on('$destroy', function() {\r\n\t\t\tif (intervalRef) {\r\n\t\t\t\t$interval.cancel(intervalRef);\r\n\t\t\t\tintervalRef = null;\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\t// because the save operation happens outside of this controller, the only way to know it has happened is to watch the collection for changes\r\n\t\t// when that collection changes, refresh data\r\n\t\t$scope.$watch('vm.assignedPermissions', function(newVal, oldVal) {\r\n\t\t\tif (newVal !== oldVal && isActivated) {\r\n\t\t\t\tvar i = vm.displayPermissions.length;\r\n\t\t\t\twhile (i--) {\r\n\t\t\t\t\tvm.displayPermissions.pop();\r\n\t\t\t\t}\r\n\t\t\t\tvm.hasLoadedAllPermissions = false;\r\n\t\t\t\tpageNumber = 0;\r\n\t\t\t\t_loadPermissions();\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\tfunction activate() {\r\n\t\t\tuser = accountUserService.getUser();\r\n\r\n\t\t\t// because we don't know if the component has initialized and all the bindings have been set\r\n\t\t\t// check on an interval basis to see if any of those two values (groupId, userId) have been set\r\n\t\t\t// if they have been set, stop the interval and proceed as normal\r\n\t\t\tintervalRef = $interval(function() {\r\n\t\t\t\tif (vm.groupId || vm.userId) {\r\n\t\t\t\t\t$interval.cancel(intervalRef);\r\n\t\t\t\t\tintervalRef = null;\r\n\r\n\t\t\t\t\tisActivated = true;\r\n\r\n\t\t\t\t\t// if the parent passed any assigned permissions that it is tracking then make sure to use that array with those objects\r\n\t\t\t\t\tvm.assignedPermissions = vm.assignedPermissions || [];\r\n\r\n\t\t\t\t\t_loadPermissions();\r\n\t\t\t\t}\r\n\t\t\t}, 500, 10);\r\n\t\t}\r\n\r\n\t\tfunction _loadPermissions() {\r\n\t\t\tif (!vm.groupId && !vm.userId) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tpageNumber += 1;\r\n\r\n\t\t\tvar getPermissionsPromise;\r\n\r\n\t\t\tif (vm.groupId) {\r\n\t\t\t\tgetPermissionsPromise = companyPermissionService.getForGroup(vm.groupId, pageNumber, PAGE_SIZE, vm.companyNameFilter);\r\n\t\t\t}\r\n\t\t\tif (vm.userId) {\r\n\t\t\t\tgetPermissionsPromise = companyPermissionService.getForUser(vm.userId, pageNumber, PAGE_SIZE, vm.companyNameFilter);\r\n\t\t\t}\r\n\r\n\t\t\tvm.isBusy = true;\r\n\r\n\t\t\tgetPermissionsPromise.then(function (permissions) {\r\n\t\t\t\t// if it is a permission that we've already touched/modified then use the modified value\r\n\t\t\t\tif (permissions && permissions.length) {\r\n\t\t\t\t\t// get the IDs of the page of permission we're going to display\r\n\t\t\t\t\tvar displayPermissionIds = _.map(permissions, 'entityID');\r\n\r\n\t\t\t\t\t// find existing permission that we've modified that match those IDs; we will use these instead of the display permissions we just loaded\r\n\t\t\t\t\tvar matchedModifiedPermissions = _.filter(vm.assignedPermissions, function(i) {\r\n\t\t\t\t\t\treturn displayPermissionIds.indexOf(i.entityID) !== -1;\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\t// get the IDs of the matching permissions that we just found\r\n\t\t\t\t\tvar matchedModifiedPermissionIds = _.map(matchedModifiedPermissions, 'entityID');\r\n\r\n\t\t\t\t\t// get the remaining display permissions that do not match the modified permissions; we will show these on the UI\r\n\t\t\t\t\tvar unmatchedDisplayPermissions = _.filter(permissions, function(i) {\r\n\t\t\t\t\t\treturn matchedModifiedPermissionIds.indexOf(i.entityID) === -1;\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\t// prepare the permissions that will be displayed as part of the new page that was just loaded\r\n\t\t\t\t\tvar newPermissionPage = [].concat(matchedModifiedPermissions).concat(unmatchedDisplayPermissions)\r\n\r\n\t\t\t\t\t// set values\r\n\t\t\t\t\t_setPermissionsValues(newPermissionPage);\r\n\r\n\t\t\t\t\t// update UI collection\r\n\t\t\t\t\tvm.displayPermissions = vm.displayPermissions.concat(newPermissionPage);\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// if the count of all permissions is less than what we've asked the service to load, that means we're on the last page\r\n\t\t\t\tvar alreadyLoadedCount = _.filter(vm.displayPermissions, function(i) {\r\n\t\t\t\t\treturn i.efAction !== EF_ACTION_ADD;\r\n\t\t\t\t}).length;\r\n\r\n\t\t\t\tif (alreadyLoadedCount < (pageNumber * PAGE_SIZE)) {\r\n\t\t\t\t\tvm.hasLoadedAllPermissions = true;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tvm.isBusy = false;\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction _setPermissionsValues(permissions) {\r\n\t\t\tif (permissions === undefined) return;\r\n\r\n\t\t\tfor (var i = 0; i < permissions.length; i++) {\r\n\t\t\t\tvar p = permissions[i];\r\n\r\n\t\t\t\tif (!p.writeAllowed && !p.readAllowed) {\r\n\t\t\t\t\tp.permission = OPT_HIDE;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (p.writeAllowed) {\r\n\t\t\t\t\tif (p.includeAllChildRecords) {\r\n\t\t\t\t\t\tp.permission = OPT_EDIT_ALL;\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tp.permission = OPT_VIEW_EDIT_SOME;\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (p.readAllowed) {\r\n\t\t\t\t\tif (p.includeAllChildRecords) {\r\n\t\t\t\t\t\tp.permission = OPT_VIEW_ALL;\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tp.permission = OPT_VIEW_EDIT_SOME;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction companyNameFilterChanged() {\r\n\t\t\t// reset pagination data, load permissions for new company name filter\r\n\t\t\t// remove everything from display permissions that has and EF action other than added\r\n\t\t\t_.remove(vm.displayPermissions, function(i) {\r\n\t\t\t\treturn i.efAction !== EF_ACTION_ADD;\r\n\t\t\t});\r\n\t\t\tvm.hasLoadedAllPermissions = false;\r\n\t\t\tpageNumber = 0;\r\n\t\t\t_loadPermissions();\r\n\t\t}\r\n\r\n\t\t// function for company list filter\r\n\t\tfunction companiesOnly(e) {\r\n\t\t\treturn e.entityTypeID === 1;\r\n\t\t}\r\n\r\n\t\tfunction _showSites(companyPermission) {\r\n\t\t\tvar modalInstance = $uibModal.rejectableOpen({\r\n\t\t\t\ttemplateUrl: 'app/Permission/Company/_site-list.html',\r\n\t\t\t\tcontroller: 'sd.Site.List.Controller',\r\n\t\t\t\tbindToController: true,\r\n\t\t\t\twindowClass: 'sites-permissions-dialog show',\r\n backdropClass: 'show',\r\n\t\t\t\tsize: 'lg',\r\n\r\n\t\t\t\tcontrollerAs: 'vm',\r\n\t\t\t\tresolve: {\r\n\t\t\t\t\tcompanyId: function () {\r\n\t\t\t\t\t\treturn companyPermission.entityID;\r\n\t\t\t\t\t},\r\n\t\t\t\t\tuserId: function () {\r\n\t\t\t\t\t\treturn vm.userId;\r\n\t\t\t\t\t},\r\n\t\t\t\t\tgroupId: function () {\r\n\t\t\t\t\t\treturn vm.groupId;\r\n\t\t\t\t\t},\r\n\t\t\t\t\tsites: function () {\r\n\t\t\t\t\t\tif (!companyPermission.sites || companyPermission.sites.length === 0) {\r\n\t\t\t\t\t\t\tcompanyPermission.sites = []\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\treturn companyPermission.sites;\r\n\t\t\t\t\t},\r\n\t\t\t\t\teditMode: function () {\r\n\t\t\t\t\t\treturn vm.editMode;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\tmodalInstance.result.then(function (results) {\r\n\t\t\t\t// persist the list of sites for the companyPermission so we don't have to fetch it again\r\n\t\t\t\tcompanyPermission.sites = results.sites;\r\n\r\n\t\t\t\tvar SITE_OPT_VIEW = 'View';\r\n\t\t\t\tvar SITE_OPT_EDIT = 'Edit';\r\n\t\t\t\tvar SITE_OPT_HIDE = 'Hide';\r\n\r\n\t\t\t\tfor (var i = 0; i < results.sites.length; i++) {\r\n\t\t\t\t\t// only process updated records\r\n\t\t\t\t\tif (results.sites[i].efAction === null) {\r\n\t\t\t\t\t\tcontinue;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tvar newPermission = angular.copy(results.sites[i]);\r\n\t\t\t\t\tvar permission;\r\n\r\n\t\t\t\t\t// if this site permission already exists in our list, find the index of that item\r\n\t\t\t\t\tvar existingAssignedPermission = _.find(vm.assignedPermissions, function(item) {\r\n\t\t\t\t\t\treturn item.entityID === newPermission.entityID;\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\tif (!existingAssignedPermission) {\r\n\t\t\t\t\t\t// try to locate that permission in the display (it is currently being displayed) if not create new permission\r\n\t\t\t\t\t\tvar existingDisplayPermission = _.find(vm.displayPermissions, function(i) {\r\n\t\t\t\t\t\t\treturn i.entityID === newPermission.id;\r\n\t\t\t\t\t\t});\r\n\t\t\t\t\t\t// ideally it should never not-find it in the dispaly collection becauase you can get to the site modifications modal only from a display permission\r\n\t\t\t\t\t\tif (!existingDisplayPermission) {\r\n\t\t\t\t\t\t\tpermission = newPermission;\r\n\t\t\t\t\t\t\t// track it in our display permission collection as well\r\n\t\t\t\t\t\t\tvm.displayPermissions.push(permission);\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\tpermission = existingDisplayPermission;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t// track it in our assigned permissions collection\r\n\t\t\t\t\t\tvm.assignedPermissions.push(permission);\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tpermission = existingAssignedPermission;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t// for sites, we don't care about including all child records right now, so that setting will be ignored\r\n\t\t\t\t\tpermission.readAllowed = newPermission.Permission.Name !== SITE_OPT_HIDE;\r\n\t\t\t\t\tpermission.writeAllowed = newPermission.Permission.Name === SITE_OPT_EDIT;\r\n\r\n\t\t\t\t\tpermission.efAction = newPermission.permissionID === null ? EF_ACTION_ADD : EF_ACTION_UPDATE;\r\n\t\t\t\t\tif (permission.Permission.Name === SITE_OPT_HIDE && permission.permissionID !== null) {\r\n\t\t\t\t\t\tpermission.efAction = EF_ACTION_DELETE;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif (vm.groupId) {\r\n\t\t\t\t\t\tpermission.groupID = vm.groupId;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif (vm.userId) {\r\n\t\t\t\t\t\tpermission.userId = user.id;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\treturn true;\r\n\t\t\t}, function () { });\r\n\t\t}\r\n\r\n\t\tfunction changePermission(permission) {\r\n\t\t\tutils.updateAction(permission);\r\n\t\t\t_changeAllowedFlags(permission);\r\n\r\n\t\t\t// keep track of modified permission\r\n\t\t\tvar index = vm.assignedPermissions.indexOf(permission);\r\n\t\t\tif (index === -1) {\r\n\t\t\t\tvm.assignedPermissions.push(permission);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction _changeAllowedFlags(permission) {\r\n\t\t\tpermission.readAllowed = permission.permission !== OPT_HIDE;\r\n\t\t\tpermission.writeAllowed = permission.permission === OPT_EDIT_ALL;\r\n\t\t\tpermission.includeAllChildRecords = permission.permission === OPT_VIEW_ALL || permission.permission === OPT_EDIT_ALL;\r\n\r\n\t\t\t// utils doesn't handle 'hide' setting. have to do this here\r\n\t\t\tif (permission.permission.toLowerCase().indexOf('hide') >= 0) {\r\n\t\t\t\tpermission.efAction = EF_ACTION_DELETE;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t// adding company permissions\r\n\t\tfunction _showAdd() {\r\n\t\t\tvar modalInstance = $uibModal.rejectableOpen({\r\n\t\t\t\ttemplateUrl: 'app/Permission/Company/_add.html',\r\n\t\t\t\tcontroller: 'sd.Permission.Company.Add.Controller',\r\n\t\t\t\tbindToController: true,\r\n\t\t\t\twindowClass: 'permission-dialog show',\r\n backdropClass: 'show',\r\n\t\t\t\tcontrollerAs: 'vm',\r\n\t\t\t\tresolve: {\r\n\t\t\t\t\tmodifiedEntityIds: function () {\r\n\t\t\t\t\t\treturn _.map(vm.assignedPermissions, 'entityID');\r\n\t\t\t\t\t},\r\n\t\t\t\t\tuserId: function () {\r\n\t\t\t\t\t\treturn vm.userId;\r\n\t\t\t\t\t},\r\n\t\t\t\t\tgroupId: function(){\r\n\t\t\t\t\t\treturn vm.groupId;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\tmodalInstance.result.then(function (newPermission) {\r\n\t\t\t\tif (newPermission && newPermission.companies) {\r\n\t\t\t\t\t_.forEach(newPermission.companies, function(company) {\r\n\t\t\t\t\t\t// see if that company permission has already been modified\r\n\t\t\t\t\t\tvar existingPermission = _.find(vm.assignedPermissions, function(i) {\r\n\t\t\t\t\t\t\treturn i.entityID === company.id;\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\tif (!existingPermission) {\r\n\t\t\t\t\t\t\t// try to locate that permission in the display (it is currently being displayed) if not create new permission\r\n\t\t\t\t\t\t\tvar permission = _.find(vm.displayPermissions, function(i) {\r\n\t\t\t\t\t\t\t\treturn i.entityID === company.id;\r\n\t\t\t\t\t\t\t});\r\n\t\t\t\t\t\t\tif (!permission) {\r\n\t\t\t\t\t\t\t\tpermission = {\r\n\t\t\t\t\t\t\t\t\tentityID: company.id,\r\n\t\t\t\t\t\t\t\t\tentityName: company.name,\r\n\t\t\t\t\t\t\t\t\tentityTypeID: EntityTypeIDs.COMPANY,\r\n\t\t\t\t\t\t\t\t};\r\n\t\t\t\t\t\t\t\tvm.displayPermissions.push(permission);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tvm.assignedPermissions.push(permission);\r\n\r\n\t\t\t\t\t\t\t// set values for new permission\r\n\t\t\t\t\t\t\tpermission.sites = [],\r\n\t\t\t\t\t\t\tpermission.includeAllChildRecords = newPermission.Permission.Name === OPT_VIEW_ALL || newPermission.Permission.Name === OPT_EDIT_ALL,\r\n\t\t\t\t\t\t\tpermission.permission = newPermission.Permission.Name,\r\n\t\t\t\t\t\t\tpermission.readAllowed = newPermission.Permission.Name !== OPT_HIDE,\r\n\t\t\t\t\t\t\tpermission.sitePermission = newPermission.Permission.Name,\r\n\t\t\t\t\t\t\tpermission.writeAllowed = newPermission.Permission.Name === OPT_EDIT_ALL,\r\n\t\t\t\t\t\t\tpermission.efAction = newPermission.Permission.Name === OPT_HIDE ? EF_ACTION_DELETE : EF_ACTION_ADD\r\n\r\n\t\t\t\t\t\t\tif (vm.groupId) {\r\n\t\t\t\t\t\t\t\tpermission.groupID = vm.groupId;\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tif (vm.userId) {\r\n\t\t\t\t\t\t\t\tpermission.userId = user.id;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t});\r\n\t\t\t\t}\r\n\r\n\t\t\t\treturn true;\r\n\t\t\t}, function () {});\r\n\t\t}\r\n\r\n\t\tactivate();\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:Company.Permission.Panel.Directive\r\n * @description\r\n * # Company Permission Panel Directive\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Company.Permission.Panel.Directive';\r\n\tvar VIEW_TEMPLATE_URL = 'app/Permission/Company/Panel/_panel.html';\r\n\tvar CONTROLLER_NAME = 'sd.Company.Permission.Panel.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdCompanyPermissionPanel', Directive);\r\n\r\n\tDirective.$inject = [\r\n\r\n\t];\r\n\r\n\tfunction Directive() {\r\n\t\t// Usage:\r\n\t\t// \r\n\t\t// Creates:\r\n\t\t//\r\n\t\t// Example of permissions arrary:\r\n\t\t// [\r\n\t\t// {\r\n\t\t// companyId: 1444,\r\n\t\t// companyName: 'M. Alfieri Co., Inc.',\r\n\t\t// permission: 'View|Edit|Hide',\r\n\t\t// sitePermission: 'View Some Sites|View All Sites|Edit All Sites|Hide All Sites',\r\n\t\t// sitePermissions: [\r\n\t\t// {\r\n\t\t// siteId: 1,\r\n\t\t// siteName: 'Canyon Woods Apartments',\r\n\t\t// state: 'CA',\r\n\t\t// propertyNumber: 3213,\r\n\t\t// permission: 'View|Edit|Hide'\r\n\t\t// },\r\n\t\t// ...\r\n\t\t// ]\r\n\t\t// },\r\n\t\t// ...\r\n\t\t// ]\r\n\t\tvar directive = {\r\n\t\t\trestrict: 'E',\r\n\t\t\treplace: true,\r\n\t\t\tscope: {\r\n\t\t\t\tassignedPermissions: '=assignedPermissions',\r\n\t\t\t\teditMode: '=',\r\n\t\t\t\tcompactMode: '=',\r\n\t\t\t\tuserId: '=',\r\n\t\t\t\tgroupId: '='\r\n\t\t\t},\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: CONTROLLER_NAME,\r\n\t\t\tcontrollerAs: 'vm'\r\n\t\t};\r\n\t\treturn directive;\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Permission.Company.Add.Controller';\r\n\r\n\t/**\r\n\t * @ngdoc function\r\n\t * @name weissmanApp.Permission.Company.Add.Controller\r\n\t * @description\r\n\t * # Permission.Company.Add.Controller\r\n\t * Controller of the weissmanApp\r\n\t */\r\n\tangular.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'$uibModalInstance',\r\n\t\t'sd.Company.Permission.Service',\r\n\t\t'modifiedEntityIds',\r\n\t\t'userId',\r\n\t\t'groupId',\r\n\t\t'sdModalService',\r\n\t\t'sd.Company.Service'\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit($uibModalInstance, companyPermissionService, modifiedEntityIds, userId, groupId, modalService, companyService) {\r\n\t\tvar PAGE_SIZE = 100;\r\n\r\n\t\tvar OPT_HIDE = 'Hide';\r\n\t\tvar OPT_VIEW_ALL = 'View All Sites';\r\n\t\tvar OPT_VIEW_EDIT_SOME = 'View/Edit Some Sites';\r\n\t\tvar OPT_EDIT_ALL = 'Edit All Sites';\r\n\r\n\t\tvar pageNumber = 1;\r\n\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.PermissionTypes = [\r\n\t\t\t{\r\n\t\t\t\tid: 2,\r\n\t\t\t\tName: OPT_VIEW_ALL\r\n\t\t\t},\r\n\t\t\t{\r\n\t\t\t\tid: 3,\r\n\t\t\t\tName: OPT_VIEW_EDIT_SOME\r\n\t\t\t},\r\n\t\t\t{\r\n\t\t\t\tid: 4,\r\n\t\t\t\tName: OPT_EDIT_ALL\r\n\t\t\t}\r\n\t\t];\r\n\t\tvm.selectedPermissionType = vm.PermissionTypes[0];\r\n\r\n\t\tvm.isBusy = false;\r\n\t\tvm.hasLoadedAllCompanies = false;\r\n\r\n\t\tvm.companyNameFilter = null;\r\n\t\tvm.companyNameFilterChanged = companyNameFilterChanged;\r\n\r\n\t\tvm.selectedCompanies = [];\r\n\t\tvm.companies = [];\r\n\t\r\n\t\tvm.toggleCompanySelection = toggleCompanySelection;\r\n\t\tvm.loadCompanies = loadCompanies;\r\n\t\tvm.cancel = cancel;\r\n\t\tvm.save = save;\r\n\r\n\t\tfunction activate() {\r\n\t\t\tvm.isNewUserBeingCreated = !groupId && !userId;\r\n\t\t\t\r\n\t\t\tloadCompanies();\r\n\t\t}\r\n\r\n\t\tfunction loadCompanies() {\r\n\t\t\tvar getPermissionsPromise;\r\n\t\t\t\r\n\t\t\tif (groupId) {\r\n\t\t\t\tgetPermissionsPromise = companyPermissionService.getCompaniesThatAreMissingPermissionsForGroup(groupId, pageNumber, PAGE_SIZE, vm.companyNameFilter, modifiedEntityIds);\r\n\t\t\t} else if (userId) {\r\n\t\t\t\tgetPermissionsPromise = companyPermissionService.getCompaniesThatAreMissingPermissionsForUser(userId, pageNumber, PAGE_SIZE, vm.companyNameFilter, modifiedEntityIds);\r\n\t\t\t} else if (vm.companyNameFilter) { // no group or user id means new user is being created. Only search if there's a search term\r\n\t\t\t\tgetPermissionsPromise = companyService.search(vm.companyNameFilter, PAGE_SIZE, pageNumber, false, false, false);\r\n\t\t\t} else {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tpageNumber += 1;\r\n\r\n\t\t\tvm.isBusy = true;\r\n\r\n\t\t\t// for the specified group or user, load all companies that have no permissions associated with them\r\n\t\t\t// exclude any of the modifiedEntityIds (this comes into play for newly added permissions that have not been saved yet; we don't wanna show those in the list)\r\n\t\t\tgetPermissionsPromise.then(function(data) {\r\n\t\t\t\tif (data) {\r\n\t\t\t\t\t// update selected property for any company that has been already selected\r\n\t\t\t\t\tvar newCompaniesPage = data.map(function(i) {\r\n\t\t\t\t\t\t// || is for different result model returned from companyService.search\r\n\t\t\t\t\t\treturn {\r\n\t\t\t\t\t\t\tname: i.entityName || i.companyName,\r\n\t\t\t\t\t\t\tid: i.entityID || i.companyID,\r\n\t\t\t\t\t\t\tselected: _.some(vm.selectedCompanies, function(company) {\r\n\t\t\t\t\t\t\t\treturn company.id === (i.entityID || i.companyID)\r\n\t\t\t\t\t\t\t})\r\n\t\t\t\t\t\t};\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\tvm.companies = vm.companies.concat(newCompaniesPage);\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// if the count of all companies is less than that we've asked the service to load, that means we're on the last page\r\n\t\t\t\tif (vm.companies.length < (pageNumber * PAGE_SIZE)) {\r\n\t\t\t\t\tvm.hasLoadedAllCompanies = true;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tvm.isBusy = false;\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction save() {\r\n\t\t\t$uibModalInstance.close({\r\n\t\t\t\tcompanies: vm.selectedCompanies,\r\n\t\t\t\tPermission: vm.selectedPermissionType\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction cancel(form) {\r\n\t\t\tmodalService.cancel(form.$dirty, $uibModalInstance.dismiss);\r\n\t\t}\r\n\r\n\t\tfunction companyNameFilterChanged() {\r\n\t\t\t// reset pagination data, load companies for new company name filter\r\n\t\t\tpageNumber = 1;\r\n\t\t\tvm.companies = [];\r\n\t\t\tvm.hasLoadedAllCompanies = false;\r\n\t\t\tloadCompanies();\r\n\t\t}\r\n\r\n\t\tfunction toggleCompanySelection(company) {\r\n\t\t\tcompany.selected = !company.selected;\r\n\r\n\t\t\tif (company.selected) {\r\n\t\t\t\tvm.selectedCompanies.push({\r\n\t\t\t\t\tid: company.id,\r\n\t\t\t\t\tname: company.name\r\n\t\t\t\t});\r\n\t\t\t} else {\r\n\t\t\t\t_.remove(vm.selectedCompanies, function(i) {\r\n\t\t\t\t\treturn i.id === company.id;\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tactivate();\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:Site.List.Controller\r\n * @description\r\n * # Site List for a given company\r\n * Controller of the weissmanApp\r\n */\r\n\r\n// stvhere\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Site.List.Controller';\r\n\tvar OPT_VIEW = 'View';\r\n\tvar OPT_EDIT = 'Edit';\r\n\tvar OPT_HIDE = 'Hide';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'sdLogger',\r\n\t\t'$uibModalInstance',\r\n\t\t'sd.Site.List.Service',\r\n\t\t'companyId',\r\n\t\t'userId',\r\n\t\t'groupId',\r\n\t\t'sites',\r\n\t\t'editMode'\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(sdLogger, $uibModalInstance, siteListService, companyId, userId, groupId, sites, editMode) {\r\n\t\t/* jshint validthis:true */\r\n\r\n\t\tvar PAGE_SIZE = 50;\r\n\t\tvar vm = this;\r\n\t\tvm.sites = [];\r\n\r\n\t\tvm.save = save;\r\n\t\tvm.cancel = cancel;\r\n\t\tvm.getDataFromServer = getDataFromServer;\r\n\t\tvm.clearFilter = clearFilter;\r\n\t\tvm.validateFilter = validateFilter;\r\n\t\tvm.checkForEnterKey = checkForEnterKey;\r\n\t\tvm.updateAction = updateAction;\r\n\r\n\t\tvm.pageNumber = parseInt(vm.sites.length / PAGE_SIZE);\r\n\r\n\t\tvm.filter = '';\r\n\t\tvm.filterValidationError = '';\r\n\t\tvm.oldFilter = '';\r\n\t\tvm.noMoreData = false;\r\n\r\n\t\tvm.SitePermissionTypes = [];\r\n\t\tvm.Permission_VIEW = 0;\r\n\t\tvm.Permission_EDIT = 1\r\n\t\tvm.Permission_HIDE = 2;\r\n\t\tvm.editMode = editMode;\r\n\r\n\t\tvm.SitePermissionTypes.push({\r\n\t\t\tid: vm.Permission_VIEW,\r\n\t\t\tName: OPT_VIEW\r\n\t\t});\r\n\t\tvm.SitePermissionTypes.push({\r\n\t\t\tid: vm.Permission_EDIT,\r\n\t\t\tName: OPT_EDIT\r\n\t\t});\r\n\t\tvm.SitePermissionTypes.push({\r\n\t\t\tid: vm.Permission_HIDE,\r\n\t\t\tName: OPT_HIDE\r\n\t\t});\r\n\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction clearFilter() {\r\n\t\t\tvm.filter = '';\r\n\t\t\tgetDataFromServer('');\r\n\t\t};\r\n\r\n\t\tfunction validateFilter() {\r\n\t\t\tif (vm.filter.length > 100) {\r\n\t\t\t\tvm.filterValidationError = \"Filter length should be 100 characters or less\";\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\tvm.filterValidationError = \"\";\r\n\t\t}\r\n\r\n\t\tfunction updateAction(p) {\r\n\t\t\tp.efAction = 'update';\r\n\t\t}\r\n\r\n\t\tfunction getDataFromServer(searchText) {\r\n\r\n\t\t\t//console.log('getDataFromServer');\r\n\t\t\tif (!searchText) {\r\n\t\t\t\tsearchText = '';\r\n\t\t\t}\r\n\r\n\t\t\tvalidateFilter();\r\n\r\n\t\t\tif (vm.filterValidationError != '') {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tvm.filter = searchText;\r\n\r\n\t\t\tif (searchText != vm.oldFilter) {\r\n\t\t\t\tvm.oldFilter = searchText;\r\n\t\t\t\tvm.pageNumber = 1;\r\n\t\t\t\tvm.noMoreData = false;\r\n\t\t\t\tvm.sites = [];\r\n\t\t\t} else {\r\n\t\t\t\tvm.pageNumber++;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.noMoreData) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.sites.length == 0) {\r\n\t\t\t\tvm.gettingDataForTheFirstTime = true;\r\n\t\t\t} else {\r\n\t\t\t\tvm.gettingMoreData = true;\r\n\t\t\t}\r\n\r\n\t\t\tvar principalId = userId;\r\n\t\t\tif (groupId)\r\n\t\t\t\tprincipalId = groupId;\r\n\r\n\r\n\t\t\tsiteListService.search(principalId, (principalId == groupId), companyId, vm.pageNumber, PAGE_SIZE, searchText)\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t\tif (!result.length || result.length == 0) {\r\n\t\t\t\t\t\tvm.noMoreData = true;\r\n\t\t\t\t\t} else {\r\n\r\n\t\t\t\t\t\tfor (var i = 0; i < result.length; i++) {\r\n\t\t\t\t\t\t\tvar site = result[i];\r\n\r\n\t\t\t\t\t\t\tif (site.writeAllowed) {\r\n\t\t\t\t\t\t\t\tsite.Permission = angular.copy(vm.SitePermissionTypes[vm.Permission_EDIT]);\r\n\t\t\t\t\t\t\t} else if (site.readAllowed) {\r\n\t\t\t\t\t\t\t\tsite.Permission = angular.copy(vm.SitePermissionTypes[vm.Permission_VIEW]);\r\n\t\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t\tsite.Permission = angular.copy(vm.SitePermissionTypes[vm.Permission_HIDE]);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t// vm.sites = vm.sites.concat(result);\r\n\t\t\t\t\t\tvm.sites = _.chain(result)\r\n\t\t\t\t\t\t\t.map(site => {\r\n\t\t\t\t\t\t\t\tconst matchingSite = _.find(sites, {entityID: site.entityID});\r\n\t\t\t\t\t\t\t\treturn matchingSite || site;\r\n\t\t\t\t\t\t\t})\r\n\t\t\t\t\t\t\t.union(vm.sites)\r\n\t\t\t\t\t\t\t.value();\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif (result.length < PAGE_SIZE) {\r\n\t\t\t\t\t\tvm.noMoreData = true;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tvm.gettingDataForTheFirstTime = false;\r\n\t\t\t\t\tvm.gettingMoreData = false;\r\n\t\t\t\t})\r\n\t\t\t\t.catch(function (error) {\r\n\t\t\t\t\terror.appSource = APP_SOURCE;\r\n\t\t\t\t\tsdLogger.error('Error', error.data.message, error);\r\n\t\t\t\t\tvm.gettingDataForTheFirstTime = false;\r\n\t\t\t\t\tvm.gettingMoreData = false;\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\r\n\t\tfunction activate() {\r\n\t\t\tvm.gettingDataForTheFirstTime = true;\r\n\t\t\tgetDataFromServer('');\r\n\t\t}\r\n\r\n\r\n\t\tfunction save() {\r\n\t\t\tconsole.log('closing dialog, vm.sites', vm.sites);\r\n\r\n\t\t\tconst sitesToSave = _.filter(vm.sites, 'efAction')\r\n\r\n\t\t\t$uibModalInstance.close({\r\n\t\t\t\tsites: sitesToSave\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction cancel() {\r\n\t\t\t$uibModalInstance.dismiss();\r\n\t\t}\r\n\r\n\t\tfunction checkForEnterKey (keyEvent) {\r\n\t\t\tif (keyEvent.which === 13)\r\n\t\t\t\tgetDataFromServer(vm.filter);\r\n\t\t}\r\n\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissmanApp.CompanyPermission.Service\r\n * @description\r\n * # Company Permission Service\r\n * Factory in the weissmanApp.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Site.List.Service';\r\n\tvar GET_DATA_FOR_USER_URL = '/api/User/{0}/company/{1}/accessiblesites';\r\n\tvar GET_DATA_FOR_GROUP_URL = '/api/UserGroup/{0}/company/{1}/accessiblesites';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = [\r\n\t\t'sd.Http.Service',\r\n\t];\r\n\r\n\tfunction Service(sdHttp) {\r\n\t\t// Public API.\r\n\t\tvar service = {\r\n\t\t\tgetAllForCompany: getAllForCompany,\r\n\t\t\tsearch: search\r\n\t\t};\r\n\t\treturn service;\r\n\r\n\r\n\t\tfunction search(principalId, isGroup, companyId, pageNumber, pageSize, searchText) {\r\n\t\t\t//console.log('sd.Site.List.Service - search', userId, companyId, pageNumber, pageSize, searchText);\r\n\t\t\tvar config = {\r\n\t\t\t\tparams: {\r\n\t\t\t\t\tpageNumber: pageNumber,\r\n\t\t\t\t\tpageSize: pageSize\r\n\t\t\t\t}\r\n\t\t\t};\r\n\r\n\t\t\tif (searchText && searchText.trim() != '') {\r\n\t\t\t\tconfig.params.search = encodeURIComponent(searchText);\r\n\t\t\t}\r\n\r\n\t\t\tvar url = isGroup ? GET_DATA_FOR_GROUP_URL : GET_DATA_FOR_USER_URL;\r\n\r\n\t\t\treturn sdHttp.get(url.format(principalId, companyId), config);\r\n\t\t}\r\n\r\n\t\tfunction getAllForCompany(principalId, isGroup, companyId, pageNumber, pageSize) {\r\n\t\t\t//console.log('sd.Site.List.Service - getAllForCompany', userId, companyId, pageNumber, pageSize);\r\n\r\n\t\t\tif (!pageNumber) pageNumber = 1;\r\n\t\t\tif (!pageSize) pageSize = 100;\r\n\r\n\t\t\tvar config = {\r\n\t\t\t\tparams: {\r\n\t\t\t\t\tpageNumber: pageNumber,\r\n\t\t\t\t\tpageSize: pageSize\r\n\t\t\t\t}\r\n\t\t\t};\r\n\r\n\t\t\tvar url = isGroup ? GET_DATA_FOR_GROUP_URL : GET_DATA_FOR_USER_URL;\r\n\r\n\t\t\treturn sdHttp.get(url.format(principalId, companyId), config);\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\nconst { has } = require(\"lodash\");\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:Instance.Permission.Panel.Controller\r\n * @description\r\n * # Instance Permissions Panel\r\n * Controller of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Instance.Permission.Panel.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'sdLogger',\r\n\t\t'accountService',\r\n\t\t'$scope',\r\n\t\t'featureFlagsService',\r\n\t\t'SD.Restrict.Service',\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(sdLogger, accountService, $scope, featureFlagsService, restrictService) {\r\n\t\t/* jshint validthis:true */\r\n\t\tvar vm = this;\r\n\t\tvm.permissionToAdd = null;\r\n\t\tvm.uniqueScreenTypes = [];\r\n\t\tvm.screenTypePermissions = [];\r\n\t\tvm.selectPermissionToAdd = selectPermissionToAdd;\r\n\t\tvm.cancelAddPermission = cancelAddPermission;\r\n\t\tvm.addPermission = addPermission;\r\n\t\tvm.usablePermission = usablePermission;\r\n\t\tvm.screenTypeSelected = screenTypeSelected;\r\n\t\tvm.availablePermissionRights = availablePermissionRights;\r\n\t\tvm.deletePermission = deletePermission;\r\n\t\tvm.getPermissionLabel = getPermissionLabel\r\n\t\tvm.userHasInstanceRight = userHasInstanceRight;\r\n\t\tvm.featureFlags= featureFlagsService.featureFlags;\r\n\t\tvm.rightSelected = rightSelected;\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\t\t\tsdLogger.log(APP_SOURCE + '.activate(): ', {\r\n\t\t\t\t'vm': vm,\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\t$scope.$watch('vm.availablePermissions', function (newVal, oldVal) {\r\n\t\t\tvm.uniqueScreenTypes = _.uniqBy(vm.availablePermissions, 'screenTypeID');\r\n\t\t}, true);\r\n\r\n\t\t$scope.$watch('vm.instanceId', function (newVal, oldVal) {\r\n\t\t\tvm.instanceId = newVal;\r\n\t\t}, true);\r\n\r\n\t\tfunction selectPermissionToAdd() {\r\n\t\t\tvm.permissionToAdd = {};\r\n\t\t}\r\n\r\n\t\tfunction cancelAddPermission() {\r\n\t\t\tvm.permissionToAdd = null;\r\n\t\t}\r\n\r\n\t\tfunction addPermission() {\r\n\t\t\tvm.permissionToAdd.permission.screenTypeID = vm.permissionToAdd.screenTypeID;\r\n\t\t\tvm.permissionToAdd.permission.screenType = vm.permissionToAdd.permission.screenType || getScreenType(vm.permissionToAdd.screenTypeID)\r\n\r\n\t\t\tvm.assignedPermissions.push(vm.permissionToAdd.permission);\r\n\r\n\t\t\tcancelAddPermission();\r\n\t\t}\r\n\r\n\t\tfunction getScreenType(id) {\r\n\t\t\treturn _.find(vm.availablePermissions, {\r\n\t\t\t\tscreenTypeID: id\r\n\t\t\t}).screenType;\r\n\t\t}\r\n\r\n\t\tfunction usablePermission(permission) {\r\n\r\n\t\t\tconst rightHasAlreadyAssigned = !_.some(vm.assignedPermissions, { screenTypeID: permission.screenTypeID});\r\n\r\n\t\t\tconst userInstanceRights = accountService.userData.instanceRights.find(i=>i.instanceId == vm.instanceId).rights.map(r=>r.name);\r\n\t\t\tconst rightsWithSameScreenType = vm.availablePermissions.filter(ap=>ap.screenTypeID == permission.screenTypeID);\r\n\t\t\tconst userHasRightWithScreenTypeInThisInstance = userInstanceRights.some(r=>rightsWithSameScreenType.some(s=>s.name === r));\r\n\r\n\t\t\treturn rightHasAlreadyAssigned && userHasRightWithScreenTypeInThisInstance;\r\n\t\t}\r\n\r\n\t\tfunction screenTypeSelected() {\r\n\t\t\tvm.screenTypePermissions = availablePermissionRights(vm.permissionToAdd.screenTypeID);\r\n\t\t\tvm.permissionToAdd.permission = _.minBy(vm.screenTypePermissions, 'rightsID');\r\n\t\t}\r\n\r\n\t\tfunction rightSelected(permission) {\r\n\t\t\tconst p = vm.permissionsLookup.find(p=>p.instanceRightID == permission.instanceRightID);\r\n\t\t\tpermission.rights = p.rights;\r\n\t\t\tpermission.rightsID = p.rightsID;\r\n\t\t}\r\n\r\n\t\tfunction availablePermissionRights(id) {\r\n\t\t\tif ( vm.availablePermissions === undefined || vm.availablePermissions.length === 0) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\treturn _.filter(vm.availablePermissions, function(ap){\r\n\t\t\t\treturn ap.screenTypeID == id;\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction deletePermission(permission) {\r\n\t\t\t_.remove(vm.assignedPermissions, permission);\r\n\t\t}\r\n\r\n\t\tfunction getPermissionLabel(rightsID) {\r\n\t\t\tvar permission = vm.permissionsLookup.find(p=>p.rightsID === rightsID);\r\n\r\n\t\t\treturn permission ? permission.rights : '';\r\n\t\t}\r\n\r\n\t\tfunction userHasInstanceRight(permission) {\r\n\t\t\treturn restrictService.hasInstanceRight(permission.name, vm.instanceId);\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar VIEW_TEMPLATE_URL = 'app/Permission/Instance/_panel.html';\r\n\tvar CONTROLLER_NAME = 'sd.Instance.Permission.Panel.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdInstancePermissionPanel', sdInstancePermissionPanel);\r\n\r\n\tsdInstancePermissionPanel.$inject = [];\r\n\r\n\tfunction sdInstancePermissionPanel() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\tcontroller: CONTROLLER_NAME,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\teditMode: '=',\r\n\t\t\t\tassignedPermissions: '=',\r\n\t\t\t\tuserSetup: '=',\r\n\t\t\t\tavailablePermissions:\"=\",\r\n\t\t\t\tpermissionsLookup:\"=\",\r\n\t\t\t\tinstanceId: '=',\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:User.Groups.Modal.Controller\r\n * @description\r\n * # User Groups Modal Popup\r\n * Controller of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.User.Group.NameInfo.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit() {\r\n\r\n\t\t/* jshint validthis:true */\r\n\t\tvar vm = this;\r\n\r\n\t\tfunction init() {\r\n\r\n\t\t\tvm.permissionOptions = [{id:0,name:\"None\"},{id:1,name:\"View\"},{id:2,name:\"Edit\"}];\r\n\t\t\tvm.selectedDefaultPermissions = vm.permissionOptions.filter(p=>p.id == (vm.userGroup.grantWriteToNewCompanies ? 2 : vm.userGroup.grantReadToNewCompanies ? 1 : 0))[0];\r\n\r\n\t\t\tvm.permissionChanged = function() {\r\n\t\t\t\tvm.userGroup.grantReadToNewCompanies = vm.selectedDefaultPermissions.id > 0;\r\n\t\t\t\tvm.userGroup.grantWriteToNewCompanies = vm.selectedDefaultPermissions.id > 1;\r\n\t\t\t}\r\n\t\t}\r\n\t\tinit();\r\n\t}\r\n\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar VIEW_TEMPLATE_URL = 'app/Permission/User-Groups/_nameInfo.html';\r\n\tvar CONTROLLER_NAME = 'sd.User.Group.NameInfo.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdUserGroupsNameInfo', sdUserGroupsNameInfo);\r\n\r\n\tsdUserGroupsNameInfo.$inject = [];\r\n\r\n\tfunction sdUserGroupsNameInfo() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\tcontroller: CONTROLLER_NAME,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\treplace: true,\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tuserGroup: '=',\r\n\t\t\t\teditMode: '=',\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:User.Groups.Panel.Controller\r\n * @description\r\n * # User Groups Panel\r\n * Controller of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.User.Groups.Panel.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'sdLogger',\r\n\t\t'sd.User.Group.Service',\r\n\t\t'$uibModal',\r\n\t\t'utils',\r\n\t\t'sd.Account.User.Service',\r\n\t\t'Roles'\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(sdLogger, userGroupService, $uibModal, utils, userService, Roles) {\r\n\r\n\t\t/* jshint validthis:true */\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.userGroupToAdd = null;\r\n\t\tvm.availableGroups = [];\r\n\t\tvm.hasUsersEdit = true; //userService.isInRole(Roles.USERSEDIT);\r\n\t\tvm.hasUsersViewOrEdit = true; //!userService.isNotInRoles([Roles.USERSVIEW, Roles.USERSEDIT]);\r\n\r\n\t\tactivate();\r\n\r\n\t\tvm.selectUserGroupToAdd = selectUserGroupToAdd;\r\n\t\tvm.cancelAddUserGroup = cancelAddUserGroup;\r\n\t\tvm.addUserGroup = addUserGroup;\r\n\t\tvm.deleteUserGroup = deleteUserGroup;\r\n\t\tvm.assignedUserGroups = assignedUserGroups;\r\n\t\tvm.editUserGroup = editUserGroup;\r\n\t\tvm.nonDeletedFilter = utils.nonDeletedFilter;\r\n\r\n\t\tfunction activate() {\r\n\t\t\tuserGroupService.get(vm.instanceId)\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t\tvm.availableGroups = result;\r\n\t\t\t\t});\r\n\r\n\t\t\tsdLogger.log(APP_SOURCE + '.activate(): ', {\r\n\t\t\t\t'vm': vm,\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction selectUserGroupToAdd() {\r\n\t\t\tvm.userGroupToAdd = {};\r\n\t\t}\r\n\r\n\t\tfunction cancelAddUserGroup() {\r\n\t\t\tvm.userGroupToAdd = null;\r\n\t\t}\r\n\r\n\t\tfunction addUserGroup() {\r\n\t\t\tvar foundAssignedGroup = _.find(vm.assignedGroups, {\r\n\t\t\t\tgroupID: vm.userGroupToAdd.groupID\r\n\t\t\t});\r\n\r\n\t\t\tif (foundAssignedGroup) {\r\n\t\t\t\tfoundAssignedGroup.efAction = null;\r\n\t\t\t} else {\r\n\t\t\t\tvm.userGroupToAdd.efAction = 'add';\r\n\t\t\t\tvm.assignedGroups.push(vm.userGroupToAdd);\r\n\t\t\t}\r\n\r\n\t\t\tcancelAddUserGroup();\r\n\t\t}\r\n\r\n\t\tfunction deleteUserGroup(group) {\r\n\t\t\tif (group.efAction === 'add') {\r\n\t\t\t\t_.remove(vm.assignedGroups, group);\r\n\t\t\t} else {\r\n\t\t\t\tgroup.efAction = 'delete';\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction assignedUserGroups(group) {\r\n\t\t\tvar groupInAssignedGroups = _.find(vm.assignedGroups, {\r\n\t\t\t\tgroupID: group.groupID\r\n\t\t\t});\r\n\r\n\t\t\tif (groupInAssignedGroups) {\r\n\t\t\t\treturn groupInAssignedGroups.efAction === 'delete'\r\n\t\t\t} else {\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction editUserGroup(group) {\r\n\t\t\tvar modalInstance = $uibModal.open({\r\n\t\t\t\ttemplateUrl: 'app/User-Group/_userGroupModal.html',\r\n\t\t\t\tcontroller: 'sd.User.Group.Modal.Controller',\r\n\t\t\t\tresolve: {\r\n\t\t\t\t\tuser_group: function () {\r\n\t\t\t\t\t\treturn group;\r\n\t\t\t\t\t},\r\n\t\t\t\t\tread_only: function () {\r\n\t\t\t\t\t\treturn true;\r\n\t\t\t\t\t},\r\n\t\t\t\t\tedit_mode: function () {\r\n\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t}\r\n\t\t\t\t},\r\n\t\t\t\twindowClass: 'show',\r\n\t\t\t\tbackdropClass: 'show',\r\n\t\t\t\tcontrollerAs: 'vm'\r\n\t\t\t});\r\n\r\n\t\t\tmodalInstance.result.then(function (newParcel) {\r\n\r\n\t\t\t\treturn true;\r\n\t\t\t}, function () {\r\n\t\t\t\tconsole.log('Modal dismissed at: ' + new Date());\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar VIEW_TEMPLATE_URL = 'app/Permission/User-Groups/_panel.html';\r\n\tvar CONTROLLER_NAME = 'sd.User.Groups.Panel.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdUserGroupsPanel', sdUserGroupsPanel);\r\n\r\n\tsdUserGroupsPanel.$inject = [];\r\n\r\n\tfunction sdUserGroupsPanel() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\tcontroller: CONTROLLER_NAME,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\teditMode: '=',\r\n\t\t\t\tassignedGroups: '=',\r\n\t\t\t\tinstanceId: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n})();\r\n","(function() {\r\n 'use strict';\r\n\r\n angular\r\n .module('weissmanApp')\r\n .controller('DocumentProcessingController', DocumentProcessingController);\r\n\r\n DocumentProcessingController.$inject = [\r\n '$q',\r\n '$sce',\r\n '$stateParams',\r\n '$rootScope',\r\n '$scope',\r\n '$state',\r\n 'DocumentService',\r\n 'sdAttachmentService',\r\n 'popUpService',\r\n '$uibModal',\r\n 'processingService',\r\n 'toastr',\r\n 'sd.Navigation.Service',\r\n 'EntityTypeIDs',\r\n 'DocumentExceptionActions',\r\n 'messageBoxService',\r\n 'MessageBoxButtons',\r\n 'MessageBoxResult',\r\n 'PropertyTypes',\r\n 'ProcessingExceptionStatusText',\r\n 'actionViewPersistenceService',\r\n 'EntityTypeNames',\r\n 'taxRateSetupModalLaunchService',\r\n 'featureFlagsService',\r\n 'RyanInstanceId',\r\n 'productAnalyticsService',\r\n 'busyIndicatorService'\r\n ];\r\n\r\n function DocumentProcessingController() {\r\n weissNg1WrapFunc(ng1ControllerInit, arguments, this);\r\n }\r\n\r\n function ng1ControllerInit(\r\n $q,\r\n $sce,\r\n $stateParams,\r\n $rootScope,\r\n $scope,\r\n $state,\r\n documentService,\r\n attachmentService,\r\n popUpService,\r\n $uibModal,\r\n processingService,\r\n toastr,\r\n navigationService,\r\n EntityTypeIDs,\r\n DocumentExceptionActions,\r\n messageBoxService,\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n PropertyTypes,\r\n ProcessingExceptionStatusText,\r\n actionViewPersistenceService,\r\n EntityTypeNames,\r\n taxRateSetupModalLaunchService,\r\n featureFlagsService,\r\n RyanInstanceId,\r\n productAnalyticsService,\r\n busyIndicatorService\r\n ) {\r\n var vm = this;\r\n var completedItemCount = 0;\r\n var newDocumentTypeID = null;\r\n var navigateWarning = 'Entity is in process. Are you sure you want to leave?';\r\n var cleanParcelData = null;\r\n const ExceptionStatusIDs = {\r\n RATES_REQUESTED: 5\r\n };\r\n\r\n vm.initializing = false;\r\n vm.EntityTypeNames = EntityTypeNames;\r\n vm.ProcessingExceptionStatusText = ProcessingExceptionStatusText;\r\n vm.showCriteria = true;\r\n vm.showOverlay = false;\r\n vm.isDirty = false;\r\n vm.warnOnEntityReload = false;\r\n vm.validationMessage = '';\r\n vm.dismissModalValidationOpen = false;\r\n vm.saveEntityValidationOpen = false;\r\n vm.completeValidationOpen = false;\r\n vm.loadingRevisionData = false;\r\n vm.searchTimestamp = null;\r\n vm.isQCItem = false;\r\n vm.editModeEntityPanel = false;\r\n vm.addressPopoverData = {};\r\n vm.isPopoutDynamic = false;\r\n vm.hasIdpFeature = false;\r\n vm.ryanInstanceId = RyanInstanceId;\r\n\r\n vm.warnOnEntityReloadChanged = function(newValue) {\r\n vm.warnOnEntityReload = newValue;\r\n };\r\n\r\n vm.forceReloadEntity = function(includeParcel) {\r\n return $q(function(resolve) {\r\n vm.loadingRevisionData = true;\r\n // Reset the entity edit panel first, then reload the necessary data\r\n var originalSelectedEntity = vm.selectedEntity;\r\n vm.selectedEntity = null;\r\n if (includeParcel) {\r\n vm.currentRow.intakeDocumentInfo.parcelChanges = null;\r\n }\r\n var originalDataEntryObject = JSON.parse(vm.dataEntryJSONHandler.retrieveDataEntryJSON());\r\n originalDataEntryObject.resetOnLoad = true;\r\n vm.currentRow.intakeDocumentInfo.intakeItem.entryJSON = JSON.stringify(originalDataEntryObject);\r\n var wasOriginallyChanged = vm.associatedEntityChanged;\r\n vm.editModeEntityPanel = false;\r\n setTimeout(function() {\r\n vm.associatedEntityChanged = false;\r\n if (wasOriginallyChanged) {\r\n vm.setDirty(true);\r\n }\r\n if (includeParcel) {\r\n getEntityTree(originalSelectedEntity.entityTypeId, originalSelectedEntity.entityId).then(function() {\r\n resolve();\r\n });\r\n } else {\r\n vm.selectedEntity = {\r\n entityId: originalSelectedEntity.entityId,\r\n entityTypeId: originalSelectedEntity.entityTypeId\r\n };\r\n resolve();\r\n }\r\n }, 1);\r\n });\r\n };\r\n\r\n vm.reloadEntity = function() {\r\n productAnalyticsService.logEvent('click-reload-entity')\r\n\r\n if (vm.warnOnEntityReload || (vm.currentRow && vm.currentRow.intakeDocumentInfo && vm.currentRow.intakeDocumentInfo.parcelChanges)) {\r\n return messageBoxService.open({\r\n message: 'Changes have been made to this entity; if you reload now, those changes will be undone. Are you sure?',\r\n buttons: MessageBoxButtons.OKCancel\r\n }).then(function(result) {\r\n if (result === MessageBoxResult.OK) {\r\n vm.setDirty(true);\r\n return vm.forceReloadEntity(true).then(function() {\r\n });\r\n } else {\r\n return $q.resolve();\r\n }\r\n });\r\n } else {\r\n return vm.forceReloadEntity(true).then(function() {\r\n });\r\n }\r\n };\r\n\r\n vm.onFirstEncounterSaved = function(result) {\r\n vm.setDirty(true);\r\n if (!result.updateVersion) {\r\n return vm.forceReloadEntity(false);\r\n }\r\n return $q.resolve();\r\n };\r\n\r\n\r\n // The entity edit panel needs to be able to set up a function that the document processing\r\n // controller can call to get data entry JSON. We're creating the dataEntryJSONHandler object to\r\n // set that up; when the entity edit panel loads, it should set the retrieveDataEntryJSON property\r\n // to a function that will get the current dataEntryJSON value.\r\n vm.dataEntryJSONHandler = {\r\n retrieveDataEntryJSON: null\r\n };\r\n\r\n // Same kind of deal with the validation handler; document processing needs to reach into the\r\n // entityEditComponent and call it's validation function\r\n vm.validationHandler = {\r\n validate: null\r\n };\r\n\r\n vm.setDirty = function(isDirty) {\r\n if (vm.isDirty !== isDirty) {\r\n vm.isDirty = isDirty;\r\n if (isDirty) {\r\n navigationService.enableNavWarning(navigateWarning);\r\n } else {\r\n navigationService.disableNavWarning();\r\n }\r\n }\r\n };\r\n\r\n activate();\r\n\r\n $scope.$on('$destroy', function() {\r\n navigationService.disableNavWarning();\r\n });\r\n\r\n $scope.$on('angular-resizable.resizeStart', function() {\r\n vm.showOverlay = true;\r\n });\r\n\r\n $scope.$on('angular-resizable.resizeEnd', function() {\r\n vm.showOverlay = false;\r\n });\r\n\r\n // If the attachment dialog is opened, the popout preview will show attachments potentially; when the modal\r\n // is closed, navigate it back to the current processing document if appropriate\r\n var attachmentClosingEvent = $rootScope.$on('attachment.modal.closing', function() {\r\n var globalAttachmentsPopUpRef = popUpService.getByAliasGroup(popUpService.StaticAliases.Attachment)[0];\r\n if (globalAttachmentsPopUpRef && vm.currentRow && vm.currentRow.intakeDocumentInfo) {\r\n notifyChildWindow(globalAttachmentsPopUpRef, vm.currentRow.intakeDocumentInfo);\r\n }\r\n });\r\n\r\n $scope.$on('$destroy', function() {\r\n attachmentClosingEvent();\r\n });\r\n\r\n\r\n ////////////////\r\n\r\n vm.onSkipClick = async function() {\r\n productAnalyticsService.logEvent('click-skip-button')\r\n\r\n if (vm.isDirty) {\r\n messageBoxService.confirm(navigateWarning).then(async function() {\r\n vm.disableSkip = true;\r\n try {\r\n await vm.openNextDocument();\r\n } finally {\r\n vm.disableSkip = false;\r\n }\r\n });\r\n } else {\r\n vm.disableSkip = true;\r\n try {\r\n await vm.openNextDocument();\r\n } finally {\r\n vm.disableSkip = false;\r\n }\r\n }\r\n };\r\n\r\n vm.openNextDocument = function() {\r\n vm.setDirty(false);\r\n newDocumentTypeID = null;\r\n if (vm.currentRowIndex >= vm.rows.length - 1) {\r\n messageBoxService.open({\r\n title: 'SUCCESS',\r\n message: 'You have completed or skipped all documents. Number of documents processed: ' + completedItemCount + '. Click ok to return',\r\n buttons: MessageBoxButtons.OK\r\n }).then(function() {\r\n navigationService.disableNavWarning();\r\n if ($state.params.parcelID) {\r\n $state.go('parcelRedirect', { entityID: $state.params.parcelID });\r\n } else {\r\n $state.go('actionview', actionViewPersistenceService.routeParams);\r\n }\r\n });\r\n return $q.resolve(null);\r\n }\r\n\r\n vm.currentRowIndex++;\r\n vm.selectedEntity = null;\r\n\r\n // just in case if data is not here\r\n if (!vm.rows[vm.currentRowIndex].intakeDocumentInfo) {\r\n getRowData(vm.currentRowIndex, true).then(function() {\r\n var globalAttachmentsPopUpRef = popUpService.getByAliasGroup(popUpService.StaticAliases.Attachment)[0];\r\n globalAttachmentsPopUpRef && vm.isPopoutDynamic && notifyChildWindow(globalAttachmentsPopUpRef, vm.currentRow.intakeDocumentInfo);\r\n });\r\n } else {\r\n vm.currentRow = vm.rows[vm.currentRowIndex];\r\n var globalAttachmentsPopUpRef = popUpService.getByAliasGroup(popUpService.StaticAliases.Attachment)[0];\r\n globalAttachmentsPopUpRef && vm.isPopoutDynamic && notifyChildWindow(globalAttachmentsPopUpRef, vm.currentRow.intakeDocumentInfo);\r\n }\r\n\r\n vm.entityIsMapped = vm.currentRow.intakeDocumentInfo.intakeItem.entityID !== null;\r\n vm.associatedEntityMissing = vm.currentRow.intakeDocumentInfo.associatedEntityMissing;\r\n vm.associatedEntityChanged = vm.currentRow.intakeDocumentInfo.associatedEntityChanged;\r\n vm.documentTypeChanged();\r\n\r\n if (vm.entityIsMapped) {\r\n if (!vm.associatedEntityMissing) {\r\n getEntityTree(vm.currentRow.intakeDocumentInfo.intakeItem.entityTypeID, vm.currentRow.intakeDocumentInfo.intakeItem.entityID);\r\n }\r\n vm.showCriteria = false;\r\n } else {\r\n vm.entityDetails = undefined;\r\n vm.showCriteria = true;\r\n }\r\n\r\n $scope.$broadcast('changeProcessingDocument');\r\n\r\n // load next one\r\n return getRowData(vm.currentRowIndex + 1, false).then(function() {\r\n const intakeDocumentInfo = vm.rows[vm.currentRowIndex]?.intakeDocumentInfo;\r\n\r\n // If it has OCR values, map them to the search criteria\r\n maybeMapOCRValues(intakeDocumentInfo);\r\n })\r\n };\r\n\r\n vm.popoutPreview = function(isDynamic) {\r\n var globalAttachmentsPopUpRef = popUpService.getByAliasGroup(popUpService.StaticAliases.Attachment)[0];\r\n if (globalAttachmentsPopUpRef && globalAttachmentsPopUpRef.isOpen()) {\r\n notifyChildWindow(globalAttachmentsPopUpRef, vm.rows[vm.currentRowIndex].intakeDocumentInfo);\r\n } else {\r\n popUpService.openAttachmentPreview(popUpService.StaticAliases.Attachment, globalAttachmentsPopUpRef).then(function(popUpRef) {\r\n notifyChildWindow(popUpRef, vm.rows[vm.currentRowIndex].intakeDocumentInfo);\r\n }, function() {\r\n });\r\n }\r\n\r\n vm.isPopoutDynamic = isDynamic;\r\n };\r\n\r\n function checkValidationFunction(validator) {\r\n // wk-2511- Dismiss and save buttons not working until an entity has been selected\r\n var result = null;\r\n if (validator) {\r\n result = validator;\r\n } else {\r\n result = function(callback) {\r\n callback(true, '');\r\n return;\r\n };\r\n }\r\n return result;\r\n }\r\n\r\n vm.openDismissModal = function() {\r\n\r\n productAnalyticsService.logEvent('click-exception-button')\r\n\r\n checkValidationFunction(vm.validationHandler.validate)(function(isValid, message) {\r\n vm.dismissModalValidationOpen = false;\r\n vm.saveEntityValidationOpen = false;\r\n vm.completeValidationOpen = false;\r\n\r\n if (!isValid) {\r\n vm.validationMessage = message;\r\n // HACK: Need to set timeout for message to propogate before triggering tooltip show\r\n setTimeout(function() {\r\n vm.dismissModalValidationOpen = true;\r\n }, 1);\r\n return;\r\n }\r\n vm.validationMessage = '';\r\n //console.log(vm.currentRow);\r\n var selectedEntity = vm.selectedEntity;\r\n\r\n if (!selectedEntity) {\r\n selectedEntity = {\r\n entityID: vm.currentRow.intakeDocumentInfo.intakeItem.entityID,\r\n entityTypeID: vm.currentRow.intakeDocumentInfo.intakeItem.entityTypeID\r\n };\r\n }\r\n\r\n var dataEntryJSON = null;\r\n if (vm.selectedEntity && vm.dataEntryJSONHandler && vm.dataEntryJSONHandler.retrieveDataEntryJSON) {\r\n dataEntryJSON = vm.dataEntryJSONHandler.retrieveDataEntryJSON();\r\n }\r\n\r\n var exceptionData = {\r\n selectedRow: vm.currentRow,\r\n selectedEntity: selectedEntity,\r\n dataEntryJSON: dataEntryJSON,\r\n newDocumentTypeID: newDocumentTypeID,\r\n entityDetails: vm.entityDetails\r\n };\r\n\r\n var modalInstance = $uibModal.open({\r\n templateUrl: 'app/Processing/Documents/Modals/_documentProcessingException.html',\r\n controller: 'DocumentProcessingExceptionModalController',\r\n resolve: {\r\n exceptionData: exceptionData,\r\n searchTimestamp: vm.searchTimestamp,\r\n optionalArgs: { isTaxBill: vm.currentRow.f9003 === 'Tax Bill' },\r\n instanceId: vm.currentRow.intakeDocumentInfo.intakeBatch.instanceId\r\n },\r\n windowClass: 'show',\r\n backdropClass: 'show'\r\n });\r\n\r\n modalInstance.result.then(function(modalResult) {\r\n vm.currentRow.intakeDocumentInfo.intakeItem.rowVersion = modalResult.result.intakeItemRowVersion;\r\n\r\n if (modalResult.actionType === DocumentExceptionActions.CLEAR_EXCEPTION) {\r\n vm.currentRow.intakeDocumentInfo.intakeItem.exceptionStatusID = undefined;\r\n } else {\r\n if (modalResult.actionType == DocumentExceptionActions.REQUEST_TAX_RATE_SETUPS) {\r\n vm.currentRow.intakeDocumentInfo.intakeItem.exceptionStatusID = ExceptionStatusIDs.RATES_REQUESTED;\r\n }\r\n vm.openNextDocument();\r\n }\r\n });\r\n });\r\n };\r\n\r\n vm.downloadAttachment = function() {\r\n var docInfo = vm.currentRow.intakeDocumentInfo;\r\n attachmentService.downloadAttachmentByGuid(docInfo.attachmentID, docInfo.attachmentMetaData, docInfo.fileExtension);\r\n };\r\n\r\n vm.loadQuickSearch = function() {\r\n productAnalyticsService.logEvent('click-entity-search')\r\n\r\n vm.entityIsMapped = false;\r\n vm.associatedEntityMissing = false;\r\n vm.associatedEntityChanged = false;\r\n vm.showCriteria = true;\r\n vm.setDirty(true);\r\n\r\n vm.entityDetails = undefined;\r\n vm.selectedEntity = undefined;\r\n vm.currentRow.intakeDocumentInfo.intakeItem.entryJSON = null;\r\n };\r\n\r\n vm.saveEntityDetails = function() {\r\n checkValidationFunction(vm.validationHandler.validate)(function(isValid, message) {\r\n vm.dismissModalValidationOpen = false;\r\n vm.saveEntityValidationOpen = false;\r\n vm.completeValidationOpen = false;\r\n\r\n if (!isValid) {\r\n vm.validationMessage = message;\r\n // HACK: Need to set timeout for message to propogate before triggering tooltip show\r\n setTimeout(function() {\r\n vm.saveEntityValidationOpen = true;\r\n }, 1);\r\n return;\r\n }\r\n vm.validationMessage = '';\r\n var documentIntakeID = vm.currentRow.intakeDocumentInfo.intakeItem.intakeItemID;\r\n var taskID = vm.currentRow.n10908;\r\n var dataEntryJSON = null;\r\n if (vm.selectedEntity && vm.dataEntryJSONHandler && vm.dataEntryJSONHandler.retrieveDataEntryJSON) {\r\n dataEntryJSON = vm.dataEntryJSONHandler.retrieveDataEntryJSON();\r\n }\r\n\r\n checkForChangesInParcel();\r\n\r\n processingService.saveItemEntity(documentIntakeID, taskID, vm.selectedEntity, newDocumentTypeID, dataEntryJSON, vm.currentRow.intakeDocumentInfo.intakeItem.rowVersion, vm.currentRow.intakeDocumentInfo.parcelChanges)\r\n .then(function(result) {\r\n vm.currentRow.intakeDocumentInfo.intakeItem.rowVersion = result.intakeItemRowVersion;\r\n // The user may have navigated away after clicking save; we don't want to change\r\n // the dirty state in that case\r\n if (taskID === vm.currentRow.n10908) {\r\n vm.setDirty(false);\r\n }\r\n toastr.success('Save successful', 'Entity Details have been saved');\r\n });\r\n });\r\n };\r\n\r\n vm.completeTask = function() {\r\n const eventString = vm.isQCItem ? 'click-complete-QC-button' : 'click-complete-entry-button'\r\n productAnalyticsService.logEvent(eventString)\r\n\r\n vm.validationHandler.validate(function(isValid, message) {\r\n vm.dismissModalValidationOpen = false;\r\n vm.saveEntityValidationOpen = false;\r\n vm.completeValidationOpen = false;\r\n\r\n if (!isValid) {\r\n vm.validationMessage = message;\r\n // HACK: Need to set timeout for message to propogate before triggering tooltip show\r\n setTimeout(function() {\r\n vm.completeValidationOpen = true;\r\n }, 1);\r\n return;\r\n }\r\n vm.validationMessage = '';\r\n var documentIntakeID = vm.currentRow.intakeDocumentInfo.intakeItem.intakeItemID;\r\n var taskID = vm.currentRow.n10908;\r\n var selectedEntity = vm.selectedEntity;\r\n\r\n if (!selectedEntity) {\r\n selectedEntity = {\r\n entityID: vm.currentRow.intakeDocumentInfo.intakeItem.entityID,\r\n entityTypeID: vm.currentRow.intakeDocumentInfo.intakeItem.entityTypeID\r\n };\r\n }\r\n\r\n var dataEntryJSON = null;\r\n if (vm.selectedEntity && vm.dataEntryJSONHandler && vm.dataEntryJSONHandler.retrieveDataEntryJSON) {\r\n dataEntryJSON = vm.dataEntryJSONHandler.retrieveDataEntryJSON();\r\n }\r\n\r\n checkForChangesInParcel();\r\n\r\n vm.disableEntryButtons = true;\r\n processingService.completeItem(documentIntakeID, taskID, selectedEntity, newDocumentTypeID, dataEntryJSON, vm.currentRow.intakeDocumentInfo.intakeItem.rowVersion, vm.currentRow.intakeDocumentInfo.parcelChanges)\r\n .then(function() {\r\n toastr.success('Task completed successfully', 'Success');\r\n completedItemCount++;\r\n vm.openNextDocument();\r\n })\r\n .finally(function() {\r\n vm.disableEntryButtons = false;\r\n });\r\n }, true);\r\n };\r\n\r\n vm.documentTypeChanged = function() {\r\n newDocumentTypeID = vm.currentRow.intakeDocumentInfo.attachmentType.attachmentTypeID;\r\n var documentType = _.find(vm.documentTypeList, { attachmentTypeID: vm.currentRow.intakeDocumentInfo.attachmentType.attachmentTypeID });\r\n\r\n vm.resultTypes = processingService.getResultTypesByDocumentType(documentType);\r\n\r\n if (!_.some(vm.resultTypes, { type: vm.criteria.resultType }) && vm.resultTypes.length) {\r\n var foundResultType = _.find(vm.resultTypes, { id: documentType.defaultResultsEntityTypeID });\r\n\r\n vm.criteria.resultType = foundResultType ? foundResultType.type : vm.resultTypes[0].type;\r\n }\r\n };\r\n\r\n vm.getCommentsModalData = function() {\r\n return {\r\n entityTypeID: EntityTypeIDs.INTAKE_ITEM,\r\n entityID: vm.currentRow.intakeDocumentInfo.intakeItem.intakeItemID,\r\n description: vm.getIntakeBatchItemNumber(),\r\n canEdit: true\r\n };\r\n };\r\n\r\n vm.getIntakeBatchItemNumber = function() {\r\n return 'Intake Item: ' + vm.currentRow.intakeDocumentInfo.intakeBatch.batchNumber + '#' + vm.currentRow.intakeDocumentInfo.intakeItem.itemNumber +\r\n (vm.currentRow.intakeDocumentInfo.intakeItem.duplicateNumber ? ('_' + vm.currentRow.intakeDocumentInfo.intakeItem.duplicateNumber) : '');\r\n };\r\n\r\n vm.launchDuplicateModal = function() {\r\n productAnalyticsService.logEvent('click-duplicate-button')\r\n\r\n var duplicateItem = {\r\n duplicateCount: 1,\r\n intakeItemID: vm.currentRow.intakeDocumentInfo.intakeItem.intakeItemID,\r\n attachmentTypeID: vm.currentRow.intakeDocumentInfo.attachmentType.attachmentTypeID\r\n };\r\n processingService.launchDuplicateIntakeItemModal(duplicateItem)\r\n .then(function(newItems) {\r\n if (newItems) {\r\n toastr.success('Duplicate successfully created');\r\n\r\n // WK-5083 Don't show duplicate items if we're currently on a QC task\r\n if (!vm.isQCItem) {\r\n var newIndex = vm.currentRowIndex + 1;\r\n _.forEach(newItems, function(item) {\r\n vm.rows.splice(newIndex, 0, item);\r\n newIndex++;\r\n });\r\n\r\n getRowData(vm.currentRowIndex + 1);\r\n }\r\n }\r\n }, function() {\r\n toastr.error('Failed to duplicate, please try again');\r\n });\r\n };\r\n\r\n vm.billRevisionChanged = function(revision) {\r\n var fmv = new Decimal(0);\r\n var av = new Decimal(0);\r\n _.forEach(revision.annualGridComponents, function(component) {\r\n if (component.assessmentComponentTypeID !== 3) {\r\n fmv = fmv.plus(component.fairMarketValue);\r\n av = av.plus(component.assessedValue);\r\n }\r\n });\r\n vm.revisionInfo = {\r\n totalFMV: fmv.toNumber(),\r\n totalAssessedValue: av.toNumber(),\r\n isProjected: revision.status === 1 ? false : true\r\n };\r\n\r\n vm.loadingRevisionData = false;\r\n };\r\n\r\n function logPinTip(row) {\r\n if (row && row.n10908) {\r\n console.log(\r\n 'To pin this task to document processing, paste the following at the end of your url and refresh the page:\\n' +\r\n '?taskID=' + row.n10908);\r\n }\r\n }\r\n\r\n function notifyChildWindow(popUpRef, intakeDocumentInfo) {\r\n logPinTip(vm.currentRow);\r\n if (popUpRef.isOpen()) {\r\n var popUpData = {\r\n attachmentInfo: {\r\n attachmentID: intakeDocumentInfo.attachmentID,\r\n fileName: intakeDocumentInfo.attachmentMetaData,\r\n fileExtension: intakeDocumentInfo.fileExtension\r\n }\r\n };\r\n popUpRef.publish(popUpService.Topics.Attachment.AttachmentChanged, popUpData);\r\n }\r\n }\r\n\r\n function getEntityTree(entityTypeId, entityId) {\r\n vm.selectedEntity = {\r\n entityId: entityId,\r\n entityTypeId: entityTypeId\r\n };\r\n\r\n vm.disableEntryButtons = true;\r\n return processingService.getEntityTree(entityTypeId, entityId, true)\r\n .then(function(response) {\r\n vm.entityDetails = response;\r\n\r\n if (vm.entityDetails.extendedData.propertyTypeID) {\r\n vm.entityDetails.extendedData.propertyTypeAbbr = _.find(PropertyTypes, { propertyTypeID: vm.entityDetails.extendedData.propertyTypeID }).propTypeAbbr;\r\n }\r\n\r\n vm.entityIsMapped = true;\r\n vm.associatedEntityMissing = false;\r\n\r\n cleanParcelData = null;\r\n vm.editModeEntityPanel = false;\r\n })\r\n .finally(function() {\r\n vm.disableEntryButtons = false;\r\n });\r\n }\r\n\r\n function activate() {\r\n getDocumentTypeList();\r\n\r\n vm.currentRow = null;\r\n vm.currentRowIndex = 0;\r\n vm.entityIsMapped = false;\r\n vm.associatedEntityMissing = false;\r\n vm.associatedEntityChanged = false;\r\n vm.selectedEntity = undefined;\r\n vm.entityDetails = undefined;\r\n vm.completeButtonLabel = '';\r\n vm.hasIdpFeature = featureFlagsService.featureFlags.enableIdp;\r\n vm.criteria = processingService.getCriteria();\r\n\r\n vm.resultTypes = processingService.getResultTypes();\r\n\r\n newDocumentTypeID = null;\r\n vm.setDirty(false);\r\n\r\n vm.rows = $stateParams.selectedRows;\r\n vm.searchTimestamp = $stateParams.searchTimestamp;\r\n\r\n // console.log('vm.searchTimestamp', vm.searchTimestamp);\r\n\r\n // Hack for displaying a single task ID by URL\r\n vm.initializing = true;\r\n const busyRef = busyIndicatorService.show({message: 'Loading'});\r\n if ($state.params.taskID) {\r\n initializeByTaskID($state.params.taskID).then(function() {\r\n initializeRows().then(function() {\r\n vm.initializing = false;\r\n busyRef.hide();\r\n })\r\n });\r\n } else if ($state.params.intakeItemID) {\r\n initializeByIntakeItemID($state.params.intakeItemID).then(function() {\r\n initializeRows().then(function() {\r\n vm.initializing = false;\r\n busyRef.hide();\r\n })\r\n });\r\n } else {\r\n initializeRows().then(function() {\r\n vm.initializing = false;\r\n busyRef.hide();\r\n });\r\n logPinTip(vm.rows[0]);\r\n }\r\n\r\n $scope.$on('processingQuickSearchClicked', function(event, result) {\r\n vm.setDirty(true);\r\n getEntityTree(result.entityTypeId, result.entityId);\r\n });\r\n }\r\n\r\n function initializeRows() {\r\n if (vm.rows.length > 0) {\r\n return getRowData(0, true).then(function() {\r\n // refresh pop-up window if it is available\r\n if (vm.rows[vm.currentRowIndex] && vm.rows[vm.currentRowIndex].intakeDocumentInfo) {\r\n var globalAttachmentsPopUpRef = popUpService.getByAliasGroup(popUpService.StaticAliases.Attachment)[0];\r\n globalAttachmentsPopUpRef && notifyChildWindow(globalAttachmentsPopUpRef, vm.rows[vm.currentRowIndex].intakeDocumentInfo);\r\n }\r\n\r\n switch (vm.rows[0].n10902) {\r\n case 31:\r\n vm.completeButtonLabel = 'Complete Data Entry';\r\n vm.isQCItem = false;\r\n break;\r\n case 32:\r\n vm.completeButtonLabel = 'Complete QC';\r\n vm.isQCItem = true;\r\n break;\r\n }\r\n\r\n const intakeDocumentInfo = vm.rows[0].intakeDocumentInfo;\r\n\r\n // If it has OCR values, map them to the search criteria\r\n maybeMapOCRValues(intakeDocumentInfo)\r\n\r\n vm.entityIsMapped = intakeDocumentInfo.intakeItem.entityID !== null;\r\n if (vm.entityIsMapped) {\r\n vm.associatedEntityMissing = intakeDocumentInfo.associatedEntityMissing;\r\n vm.associatedEntityChanged = intakeDocumentInfo.associatedEntityChanged;\r\n var entityId = intakeDocumentInfo.intakeItem.entityID;\r\n var entityTypeId = intakeDocumentInfo.intakeItem.entityTypeID;\r\n vm.documentTypeChanged();\r\n\r\n if (!vm.associatedEntityMissing) {\r\n getEntityTree(entityTypeId, entityId);\r\n }\r\n }\r\n });\r\n } else {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n function maybeMapOCRValues(intakeDocumentInfo) {\r\n if (intakeDocumentInfo?.taxBillOcrResults) {\r\n _.assign(vm.criteria, processingService.getCriteriaWithIdp(intakeDocumentInfo.taxBillOcrResults));\r\n } else if (intakeDocumentInfo?.assessmentNoticeOcrResults) {\r\n _.assign(vm.criteria, processingService.getCriteriaWithIdp(intakeDocumentInfo.assessmentNoticeOcrResults));\r\n }\r\n\r\n if(intakeDocumentInfo?.taxBillOcrResults || intakeDocumentInfo?.assessmentNoticeOcrResults || intakeDocumentInfo?.idpConfidence) {\r\n vm.criteria.anticipated = true;\r\n vm.criteria.primaryAcctNumOnly = false;\r\n }\r\n }\r\n\r\n function initializeByTaskID(taskID) {\r\n return documentService.getTaskInfoByTaskID(taskID).then(function(taskInfo) {\r\n vm.rows = [taskInfo];\r\n });\r\n }\r\n\r\n function initializeByIntakeItemID(intakeItemID) {\r\n return documentService.getTaskInfo(intakeItemID).then(function(taskInfo) {\r\n vm.rows = [taskInfo];\r\n });\r\n }\r\n\r\n function getRowData(rowIndex, displayNow) {\r\n if (vm.rows.length <= rowIndex) {\r\n return $q.resolve(null);\r\n } else {\r\n //TODO: Maybe check for the intakeDocumentInfo object first\r\n return documentService.getDocumentInfoByTaskId(vm.rows[rowIndex].n10908 || vm.rows[rowIndex].taskID) //https://dev.azure.com/ryanunity/PropertyPoint/_workitems/edit/302375\r\n .then(function(intakeDocumentInfo) {\r\n vm.rows[rowIndex].intakeDocumentInfo = intakeDocumentInfo;\r\n vm.rows[rowIndex].fileError = false;\r\n\r\n return loadAttachment(rowIndex, displayNow);\r\n });\r\n\r\n }\r\n }\r\n\r\n function loadAttachment(rowIndex, displayNow) {\r\n\r\n // console.log('getRowData - loading attachment ', rowIndex);\r\n\r\n var fileInfo = attachmentService.getMimeTypeByFileExtension(vm.rows[rowIndex].intakeDocumentInfo.fileExtension);\r\n if (fileInfo.previewSupported) {\r\n return documentService.getDocumentBody(vm.rows[rowIndex].intakeDocumentInfo.attachmentID)\r\n .then(function(response) {\r\n var attachmentBlob = new Blob([response.data], { type: fileInfo.type });\r\n var attachmentBlobUrl = URL.createObjectURL(attachmentBlob);\r\n // console.log('getRowData - attachment loaded ', rowIndex);\r\n\r\n if (fileInfo.previewSupported) {\r\n vm.rows[rowIndex].intakeDocumentInfo.attachmentUrl = $sce.trustAsResourceUrl(attachmentBlobUrl);\r\n //// console.log('vm.attachmentUrl', vm.attachmentUrl);\r\n vm.rows[rowIndex].intakeDocumentInfo.fileInfo = fileInfo;\r\n //// console.log('vm.fileInfo', vm.fileInfo);\r\n }\r\n\r\n if (displayNow == true) {\r\n // console.log('getRowData - setting this row as current one ', rowIndex);\r\n vm.currentRow = vm.rows[rowIndex];\r\n }\r\n\r\n //// console.log(vm.currentRow)\r\n\r\n // we might want to load next row - if there is one\r\n //\r\n if (rowIndex == 0 && vm.rows.length >= 2) {\r\n // console.log('getRowData - loading second row right away ');\r\n if (!vm.rows[1].intakeDocumentInfo) {\r\n getRowData(1, false);\r\n }\r\n }\r\n }).catch(function() {\r\n vm.rows[rowIndex].fileError = true;\r\n }).finally(function() {\r\n if (displayNow == true) {\r\n vm.currentRow = vm.rows[rowIndex];\r\n }\r\n });\r\n } else {\r\n vm.rows[rowIndex].intakeDocumentInfo.attachmentUrl = null;\r\n vm.rows[rowIndex].intakeDocumentInfo.fileInfo = fileInfo;\r\n if (displayNow == true) {\r\n vm.currentRow = vm.rows[rowIndex];\r\n }\r\n\r\n // we might want to load next row - if there is one\r\n //\r\n if (rowIndex == 0 && vm.rows.length >= 2) {\r\n // console.log('getRowData - loading second row right away ');\r\n if (!vm.rows[1].intakeDocumentInfo) {\r\n getRowData(1, false);\r\n }\r\n }\r\n\r\n return $q.resolve();\r\n }\r\n }\r\n\r\n function getDocumentTypeList() {\r\n attachmentService.getAttachmentTypes().then(function(results) {\r\n vm.documentTypeList = results;\r\n });\r\n }\r\n\r\n vm.showLegalDescriptionDialog = function() {\r\n\r\n var legalDescriptionDialogModalInstance = $uibModal.open({\r\n keyboard: true,\r\n modalFade: true,\r\n size: 'lg',\r\n windowClass: 'super-max-modal-size show',\r\n templateUrl: 'app/Entity/Parcel/Info/_legalDescription.Modal.html',\r\n controller: 'Parcel.LegalDescription.Modal.Controller',\r\n controllerAs: 'vm',\r\n backdropClass: 'show',\r\n resolve: {\r\n dialogData: function() {\r\n return {\r\n acctNum: vm.entityDetails.extendedData.parcelAcctNum,\r\n legalDescription: vm.entityDetails.extendedData.parcelLegalDescription,\r\n editMode: false\r\n };\r\n }\r\n }\r\n });\r\n };\r\n\r\n vm.isSubEntity = function() {\r\n if (!vm.selectedEntity) {\r\n return;\r\n }\r\n\r\n return _.includes([EntityTypeIDs.TAX_BILL, EntityTypeIDs.ASSESSMENT, EntityTypeIDs.APPEAL, EntityTypeIDs.FILING, EntityTypeIDs.PAYMENT], vm.selectedEntity.entityTypeId);\r\n };\r\n\r\n vm.editEntityPanel = function() {\r\n productAnalyticsService.logEvent('click-edit-pencil')\r\n // If parcel changes object from API, then save it off so it can be reverted to on cancel\r\n if (vm.currentRow.intakeDocumentInfo.parcelChanges) {\r\n cleanParcelData = _.cloneDeep(vm.currentRow.intakeDocumentInfo.parcelChanges);\r\n } else {\r\n // If no parcel changes, then init it with extended data.\r\n var parcelChangesFields = ['assesseeName', 'collectorAcctNum', 'parcelCollectorID', 'parcelRowVersion', 'parcelAddressRowVersion', 'parcelCollectorRowVersion'];\r\n\r\n vm.currentRow.intakeDocumentInfo.parcelChanges = _.pick(vm.entityDetails.extendedData, parcelChangesFields);\r\n vm.currentRow.intakeDocumentInfo.parcelChanges.parcelAddress = _.pick(vm.entityDetails.extendedData.parcelAddress, ['address1', 'address2', 'city', 'stateID', 'zip']);\r\n vm.currentRow.intakeDocumentInfo.parcelChanges.parcelAddress.abbr = vm.entityDetails.extendedData.parcelState.abbr;\r\n }\r\n\r\n vm.setDirty(true);\r\n vm.editModeEntityPanel = true;\r\n };\r\n\r\n vm.cancelChanges = function() {\r\n vm.currentRow.intakeDocumentInfo.parcelChanges = _.cloneDeep(cleanParcelData);\r\n\r\n cleanParcelData = null;\r\n\r\n vm.editModeEntityPanel = false;\r\n };\r\n\r\n vm.isOverridden = function(field, isAddress) {\r\n if (!vm.currentRow.intakeDocumentInfo.parcelChanges) {\r\n return false;\r\n }\r\n\r\n if (field === 'taxSetup') {\r\n return !!vm.currentRow.intakeDocumentInfo.parcelChanges.newTaxSetup;\r\n } else if (isAddress) {\r\n return !_.isEqual(vm.currentRow.intakeDocumentInfo.parcelChanges.parcelAddress[field], vm.entityDetails.extendedData.parcelAddress[field]);\r\n } else {\r\n return !_.isEqual(vm.currentRow.intakeDocumentInfo.parcelChanges[field], vm.entityDetails.extendedData[field]);\r\n }\r\n };\r\n\r\n vm.openTaxSetupModal = function() {\r\n var newTaxSetup = null;\r\n if (vm.currentRow.intakeDocumentInfo.parcelChanges) {\r\n newTaxSetup = vm.currentRow.intakeDocumentInfo.parcelChanges.newTaxSetup;\r\n }\r\n taxRateSetupModalLaunchService.openDocumentProcessingParcelTaxSetupModal(\r\n vm.entityDetails.parcel.entityId, {\r\n parcelCollectorID: vm.entityDetails.extendedData.parcelCollectorID,\r\n rowVersion: vm.entityDetails.extendedData.parcelCollectorRowVersion,\r\n collectorID: vm.entityDetails.collector.collectorID\r\n },\r\n newTaxSetup,\r\n vm.entityDetails.collector.text,\r\n vm.entityDetails.annualYear.text,\r\n !vm.editModeEntityPanel\r\n ).subscribe({\r\n next: function(modalResult) {\r\n vm.currentRow.intakeDocumentInfo.parcelChanges.newTaxSetup = modalResult;\r\n }\r\n });\r\n };\r\n\r\n function checkForChangesInParcel() {\r\n if (!vm.isOverridden('assesseeName')\r\n && !vm.isOverridden('address1', true)\r\n && !vm.isOverridden('address2', true)\r\n && !vm.isOverridden('city', true)\r\n && !vm.isOverridden('zip', true)\r\n && !vm.isOverridden('collectorAcctNum')\r\n && !vm.isOverridden('taxSetup')) {\r\n vm.currentRow.intakeDocumentInfo.parcelChanges = null;\r\n }\r\n }\r\n }\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdDocumentProcessingSearch', sdDocumentProcessingSearch);\r\n\r\n\t// sdDocumentProcessingSearch.$inject = ['dependencies'];\r\n\r\n\tfunction sdDocumentProcessingSearch() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Processing/Documents/_documentProcessingQuickSearch.html',\r\n\t\t\tscope: {\r\n\t\t\t\tcurrentDocument: '=',\r\n\t\t\t\tshowCriteria: '=',\r\n\t\t\t\tcriteria: '=',\r\n\t\t\t\tresultTypes: '=',\r\n attachmentTypeId: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {\r\n\t\t\tscope.$on(\"changeProcessingDocument\", function () {\r\n\t\t\t\tscope.vm.refreshCriteria();\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n\r\n\tController.$inject = ['processingService', '$timeout', 'productAnalyticsService'];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(processingService, $timeout, productAnalyticsService) {\r\n\t\tvar vm = this;\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\t\t\tvm.savingCriteria = false;\r\n\t\t}\r\n\r\n\t\tvm.search = function () {\r\n\t\t\tproductAnalyticsService.logEvent('enter-search-criteria', {DpSearchCriteria: _.map(vm.criteria.activeFilters, 'name')})\r\n\t\t\t\r\n\t\t if (vm.currentDocument && vm.currentDocument.intakeItem) {\r\n\t\t vm.criteria.currentIntakeItemID = vm.currentDocument.intakeItem.intakeItemID;\r\n\t\t }\r\n\t\t vm.criteria.includeIntakeItemData = true;\r\n\t\t\tvm.criteria.executeSearch = false;\r\n\t\t\tif (vm.criteria.anticipated) {\r\n vm.criteria.anticipatedAttachmentTypeID = vm.attachmentTypeId;\r\n\t\t\t}\r\n\r\n\t\t\t$timeout(function () {\r\n\t\t\t\tvm.criteria.executeSearch = true;\r\n\t\t\t});\r\n\r\n\t\t\tvm.showCriteria = false;\r\n\t\t}\r\n\r\n\t\tvm.saveCriteria = async function () {\r\n\t\t\tproductAnalyticsService.logEvent('click-dp-save-criteria')\r\n\r\n\t\t\tvm.savingCriteria = true;\r\n\r\n\t\t\ttry {\r\n\t\t\t\tawait processingService.saveCriteria(_.omit(vm.criteria, 'resultType'))\r\n\t\t\t} finally {\r\n\t\t\t\tvm.savingCriteria = false;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tvm.refreshCriteria = function () {\r\n\t\t\tproductAnalyticsService.logEvent('clear-dp-search-criteria')\r\n\t\t\t\r\n\t\t\t_.assign(vm.criteria, processingService.getCriteria());\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller('DocumentProcessingExceptionModalController', DocumentProcessingExceptionModalController);\r\n\r\n\tDocumentProcessingExceptionModalController.$inject = [\r\n '$scope',\r\n '$uibModalInstance',\r\n 'exceptionData',\r\n 'processingService',\r\n 'toastr',\r\n 'DocumentExceptionActions',\r\n 'ProcessingExceptionStatus',\r\n 'optionalArgs',\r\n 'searchTimestamp',\r\n 'teamsService',\r\n 'instanceId',\r\n 'sd.Account.User.Service',\r\n\t\t'RyanInstanceId'\r\n\t];\r\n\r\n\tfunction DocumentProcessingExceptionModalController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit($scope, $uibModalInstance, exceptionData, processingService, toastr, DocumentExceptionActions,\r\n\t\t\t\t\t\t\t ProcessingExceptionStatus, optionalArgs, searchTimestamp, teamsService, instanceId, userService,\r\n\t\t\t\t\t\t\t RyanInstanceId) {\r\n\t $scope.DocumentExceptionActions = DocumentExceptionActions;\r\n\t\t//$scope.documentExceptionActions = {\r\n\t\t//\tAddComment: 1,\r\n\t\t//\tReassignItem: 2,\r\n\t\t//\tEscalateItem: 3,\r\n\t\t//\tRejectItem: 4,\r\n\t\t//\tCloseItem: 5,\r\n\t\t//\tRequestResearch: 6,\r\n\t\t//\tClearException: 7,\r\n\t\t//\tWK-5431 - Assign a rejected item back to the user who rejected it\r\n\t\t//\tBounceRejected = 8\r\n\t\t// RequestTaxRateSetups = 9\r\n\t\t//};\r\n\t\t$scope.commentBody = '';\r\n\t\t$scope.loading = false;\r\n $scope.instanceId = instanceId;\r\n\r\n\t\tactivate();\r\n\r\n\t\t////////////////\r\n\r\n\t\tasync function activate() {\r\n\t\t\t$scope.actionType = null;\r\n\t\t\t$scope.disableBounceRejected = false;\r\n\t\t\t$scope.disableClearException = false;\r\n\t\t\t$scope.reassign = {};\r\n\t\t\t$scope.escalate = {};\r\n\t\t\t$scope.request = {};\r\n\t\t\t$scope.taxRateSetups = {};\r\n\t\t\t$scope.multipleTasks = !!exceptionData.taskIDs;\r\n\t\t\t$scope.hasExceptionStatus = false;\r\n\t\t\t$scope.rejectedByUser = null;\r\n\t\t\t$scope.contactUser = null;\r\n $scope.clientInstanceId = null;\r\n $scope.intakeItem = null;\r\n\r\n\t\t\tif ($scope.multipleTasks) {\r\n\t\t\t $scope.taskIDs = exceptionData.taskIDs;\r\n\t\t\t\t$scope.loading = true;\r\n\r\n\t\t\t\ttry {\r\n\t\t\t\t\tconst extraData = await processingService.getBulkDocumentExceptionData(exceptionData.taskIDs)\r\n\t\t\t\t\t$scope.disableBounceRejected = !extraData.showBounceRejectedOption;\r\n\t\t\t\t\t$scope.disableClearException = !extraData.showClearExceptionOption;\r\n\t\t\t\t\tif (extraData.rejectorLastName) {\r\n\t\t\t\t\t\t$scope.rejectedByUser = {\r\n\t\t\t\t\t\t\tfirstName: extraData.rejectorFirstName,\r\n\t\t\t\t\t\t\tlastName: extraData.rejectorLastName\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (extraData.contactLastName) {\r\n\t\t\t\t\t\t$scope.contactUser = {\r\n\t\t\t\t\t\t\tfirstName: extraData.contactFirstName,\r\n\t\t\t\t\t\t\tlastName: extraData.contactLastName\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n $scope.clientInstanceId = extraData.clientInstanceId;\r\n\r\n if ($scope.clientInstanceId) {\r\n $scope.escalate = {\r\n userID: extraData.contactUserId,\r\n teamID: extraData.contactTeamId\r\n };\r\n }\r\n\t\t\t\t} finally {\r\n\t\t\t\t\t$scope.loading = false;\r\n\t\t\t\t}\r\n\t\t\t}\r\n else {\r\n $scope.intakeItem = exceptionData.selectedRow.intakeDocumentInfo;\r\n $scope.hasExceptionStatus = !!exceptionData.selectedRow.intakeDocumentInfo.intakeItem.exceptionStatusID;\r\n\t\t\t\tif ($scope.intakeItem &&\r\n\t\t\t\t\t$scope.intakeItem.intakeItem &&\r\n\t\t\t\t\t$scope.intakeItem.intakeItem.rejectedByUserID &&\r\n\t\t\t\t\t$scope.intakeItem.intakeItem.exceptionStatusID == ProcessingExceptionStatus.REJECTED) {\r\n\t\t\t\t\t\tteamsService.getAssignableUserTeams($scope.intakeItem.intakeItem.rejectedByUserID).then(function (userTeams) {\r\n\t\t\t\t\t\t\t$scope.rejectedByUser = _.find(userTeams, function (ut) { return ut.isDefault; });\r\n\t\t\t\t\t\t});\r\n\t\t\t\t}\r\n\r\n if ($scope.intakeItem && $scope.intakeItem.intakeBatch.clientInstanceId) {\r\n $scope.escalate = {\r\n userID: $scope.intakeItem.contactUser.userID,\r\n teamID: $scope.intakeItem.contactTeam.teamID\r\n };\r\n }\r\n\r\n $scope.clientInstanceId = $scope.intakeItem.intakeBatch.clientInstanceId;\r\n\t\t\t}\r\n\r\n\t\t\t$scope.isTaxBill = optionalArgs.isTaxBill;\r\n\r\n if (!userService.isRyanInstanceSelected() && $scope.clientInstanceId) {\r\n $scope.instanceId = $scope.clientInstanceId;\r\n\t\t\t\t$scope.escalate = {};\r\n }\r\n\r\n\t\t\t$scope.showRequestTaxRateSetups = $scope.isTaxBill && userService.isRyanInstanceSelected();\r\n\t\t}\r\n\r\n\t\t$scope.cancel = function () {\r\n\t\t\t$uibModalInstance.dismiss();\r\n\t\t};\r\n\r\n\t\t$scope.save = function () {\r\n\t\t if (optionalArgs.parentCallsService) {\r\n\t\t $uibModalInstance.close(function () {\r\n\t\t return saveShared();\r\n\t\t });\r\n\t\t }\r\n\t\t else {\r\n\t\t $scope.loading = true;\r\n\t\t // I'm pretty sure $scope.multipleTasks will always be falsey at this point since action views\r\n\t\t // now pass in parentCallsService; that said, we really should just refactor this mess so the\r\n\t\t // processing modal doesn't depend on parts of the grid\r\n\t\t if ($scope.multipleTasks) {\r\n saveShared().then(function (result) {\r\n $uibModalInstance.close(result);\r\n }).catch(function (error) {\r\n $uibModalInstance.dismiss();\r\n });\r\n\t\t }\r\n\t\t else {\r\n saveShared().then(function (result) {\r\n toastr.success('Item Updated', 'Item was successfully updated');\r\n $uibModalInstance.close({\r\n\t\t\t\t\t\t\tactionType: $scope.actionType,\r\n\t\t\t\t\t\t\tresult\r\n\t\t\t\t\t\t});\r\n }).catch(function () { $scope.loading = false; });\r\n\t\t }\r\n\t\t\t}\r\n\t\t};\r\n\r\n\t\t$scope.isValid = function () {\r\n\t\t if (!$scope.actionType) {\r\n\t\t return false;\r\n\t\t }\r\n else if (($scope.actionType === DocumentExceptionActions.REASSIGN_ITEM && !$scope.reassign.userID)\r\n\t\t\t\t\t|| ($scope.actionType === DocumentExceptionActions.ESCALATE_ITEM && !($scope.escalate.userID || $scope.intakeItem && $scope.intakeItem.clientInstanceId || $scope.clientInstanceId))\r\n\t\t\t\t\t|| ($scope.actionType === DocumentExceptionActions.REQUEST_TAX_RATE_SETUPS && !$scope.taxRateSetups.userID)\r\n || ($scope.actionType === DocumentExceptionActions.REQUEST_RESEARCH && !$scope.request.userID)) {\r\n return false;\r\n }\r\n\r\n\t\t return true;\r\n\t\t};\r\n\r\n\t\t$scope.createComment = function() {\r\n\t\t\t$scope.commentBody = '';\r\n\r\n\t\t\tswitch($scope.actionType) {\r\n\t\t\t\tcase DocumentExceptionActions.REASSIGN_ITEM:\r\n\t\t\t\t\tif($scope.reassign && !_.isEmpty($scope.reassign.assignee)) {\r\n\t\t\t\t\t\t$scope.commentBody = 'Reassigned item to ' + $scope.reassign.assignee.firstName + ' ' + $scope.reassign.assignee.lastName + '.';\r\n\t\t\t\t\t}\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase DocumentExceptionActions.ESCALATE_ITEM:\r\n\t\t\t\t\tif($scope.escalate && !_.isEmpty($scope.escalate.assignee)) {\r\n\t\t\t\t\t\t$scope.commentBody = 'Escalated item to ' + $scope.escalate.assignee.firstName + ' ' + $scope.escalate.assignee.lastName + '.';\r\n\t\t\t\t\t}\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase DocumentExceptionActions.REQUEST_RESEARCH:\r\n\t\t\t\t\tif($scope.request && !_.isEmpty($scope.request.assignee)) {\r\n\t\t\t\t\t\t$scope.commentBody = 'Research requested from ' + $scope.request.assignee.firstName + ' ' + $scope.request.assignee.lastName + '.';\r\n\t\t\t\t\t}\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase DocumentExceptionActions.REQUEST_TAX_RATE_SETUPS:\r\n\t\t\t\t\tif($scope.taxRateSetups && !_.isEmpty($scope.taxRateSetups.assignee)) {\r\n\t\t\t\t\t\t$scope.commentBody = 'Tax rate setups requested from ' + $scope.taxRateSetups.assignee.firstName + ' ' + $scope.taxRateSetups.assignee.lastName + '.';\r\n\t\t\t\t\t}\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase DocumentExceptionActions.REJECT_ITEM:\r\n if ($scope.multipleTasks) {\r\n $scope.commentBody = 'Rejected item to ' + ($scope.contactUser ? ($scope.contactUser.firstName + ' ' + $scope.contactUser.lastName) : 'contact user') + '.';\r\n }\r\n else {\r\n $scope.commentBody = 'Rejected item to ' + $scope.intakeItem.contactUser.firstName + ' ' + $scope.intakeItem.contactUser.lastName + '.';\r\n }\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase DocumentExceptionActions.CLOSE_ITEM:\r\n\t\t\t\t\t$scope.commentBody = 'Closed item (added in error)';\r\n\t\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction saveShared() {\r\n\t\t\tif ($scope.multipleTasks) {\r\n\t\t\t return processingService.processDocumentBulkException({\r\n\t\t\t taskIDs: $scope.taskIDs,\r\n\t\t\t documentExceptionAction: $scope.actionType,\r\n\t\t\t newAssignment: getNewAssignment(),\r\n\t\t\t commentBody: $scope.commentBody,\r\n searchTimestamp: searchTimestamp\r\n\r\n\t\t\t })/*.then(function (result) {\r\n\t\t\t $uibModalInstance.close(result);\r\n\t\t\t }).catch(function (error) {\r\n\t\t\t $uibModalInstance.dismiss();\r\n\t\t\t })*/;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tcheckForChangesInParcel();\r\n\r\n var documentIntakeID = $scope.intakeItem.intakeItem.intakeItemID;\r\n var taskID = exceptionData.selectedRow.n10908;\r\n return processingService.processDocumentException(documentIntakeID, taskID, exceptionData.selectedEntity,\r\n $scope.actionType, getNewAssignment(), $scope.commentBody, exceptionData.newDocumentTypeID,\r\n exceptionData.dataEntryJSON,\r\n $scope.intakeItem.intakeItem.rowVersion, $scope.intakeItem.parcelChanges)\r\n /*.then(function () {\r\n toastr.success('Item Updated', 'Item was successfully updated');\r\n $uibModalInstance.close($scope.actionType);\r\n }).catch(function () { $scope.loading = false; })*/;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction checkForChangesInParcel() {\r\n\t\t\tif(!isOverridden('assesseeName') && !isOverridden('parcelAddress') && !isOverridden('collectorAcctNum')) {\r\n\t\t\t\t$scope.intakeItem.parcelChanges = null;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction isOverridden(field) {\r\n\t\t\tif(!$scope.intakeItem.parcelChanges) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\r\n\t\t\tif(field === 'parcelAddress') {\r\n\t\t\t\tvar addressFields = ['address1', 'address2', 'city', 'zip'];\r\n\t\t\t\treturn !_.isEqual(_.pick($scope.intakeItem.parcelChanges.parcelAddress, addressFields), _.pick(exceptionData.entityDetails.extendedData.parcelAddress, addressFields));\r\n\t\t\t} else {\r\n\t\t\t\treturn !_.isEqual($scope.intakeItem.parcelChanges[field], exceptionData.entityDetails.extendedData[field]);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction getNewAssignment() {\r\n\t\t\tswitch($scope.actionType) {\r\n\t\t\t\tcase DocumentExceptionActions.REASSIGN_ITEM:\r\n\t\t\t\t\treturn {\r\n\t\t\t\t\t\tuserID: $scope.reassign.userID,\r\n\t\t\t\t\t\tteamID: $scope.reassign.teamID\r\n\t\t\t\t\t};\r\n\t\t\t\tcase DocumentExceptionActions.ESCALATE_ITEM:\r\n\t\t\t\t\treturn {\r\n\t\t\t\t\t\tuserID: $scope.escalate.userID,\r\n\t\t\t\t\t\tteamID: $scope.escalate.teamID\r\n\t\t\t\t\t};\r\n\t\t\t\tcase DocumentExceptionActions.REQUEST_RESEARCH:\r\n\t\t\t\t\treturn {\r\n\t\t\t\t\t\tuserID: $scope.request.userID,\r\n\t\t\t\t\t\tteamID: $scope.request.teamID\r\n\t\t\t\t\t};\r\n\t\t\t\tcase DocumentExceptionActions.REQUEST_TAX_RATE_SETUPS:\r\n\t\t\t\t\treturn {\r\n\t\t\t\t\t\tuserID: $scope.taxRateSetups.userID,\r\n\t\t\t\t\t\tteamID: $scope.taxRateSetups.teamID\r\n\t\t\t\t\t};\r\n\t\t\t\tcase DocumentExceptionActions.REJECT_ITEM:\r\n\t\t\t\t\tif(!$scope.multipleTasks) {\r\n\t\t\t\t\t\treturn {\r\n\t\t\t\t\t\t\tuserID: $scope.intakeItem.contactUser.userID,\r\n\t\t\t\t\t\t\tteamID: $scope.intakeItem.contactTeam.teamID\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\treturn null;\r\n\t\t\t\t\t}\r\n\t\t\t\tcase DocumentExceptionActions.BOUNCE_REJECTED:\r\n\t\t\t\t\tif(!$scope.multipleTasks) {\r\n\t\t\t\t\t\treturn {\r\n\t\t\t\t\t\t\tuserID: $scope.rejectedByUser.userID,\r\n\t\t\t\t\t\t\tteamID: $scope.rejectedByUser.teamID\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\treturn null;\r\n\t\t\t\t\t}\r\n\t\t\t\tdefault:\r\n\t\t\t\t\treturn null;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n 'use strict';\r\n\r\n angular\r\n .module('weissmanApp')\r\n .controller('DuplicateIntakeItemModalController', DuplicateIntakeItemModalController);\r\n\r\n DuplicateIntakeItemModalController.$inject = [\r\n '$scope',\r\n '$uibModalInstance',\r\n 'processingService',\r\n 'sdAttachmentService',\r\n 'isBulk',\r\n 'duplicateItem',\r\n 'optionalArgs'\r\n ];\r\n\r\n function DuplicateIntakeItemModalController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit($scope, $uibModalInstance, processingService, attachmentService, isBulk, duplicateItem, optionalArgs) {\r\n $scope.isLoading = true;\r\n $scope.duplicate = duplicateItem;\r\n\r\n activate();\r\n\r\n function activate() {\r\n getDocumentTypeList();\r\n }\r\n\r\n function getDocumentTypeList() {\r\n attachmentService.getAttachmentTypes().then(function (results) {\r\n $scope.documentTypeList = results;\r\n $scope.isLoading = false;\r\n });\r\n\r\n }\r\n\r\n $scope.resetCopyNumber = function() {\r\n if(!$scope.duplicate.duplicateCount || $scope.duplicate.duplicateCount <= 0) {\r\n $scope.duplicate.duplicateCount = 1;\r\n }\r\n }\r\n\r\n $scope.checkCopyNumber = function() {\r\n if($scope.duplicate.duplicateCount && $scope.duplicate.duplicateCount.toString().length > 2) {\r\n var newCount = $scope.duplicate.duplicateCount.toString();\r\n newCount = newCount.substring(0, 2);\r\n\r\n $scope.duplicate.duplicateCount = parseInt(newCount);\r\n }\r\n }\r\n\r\n $scope.cancel = function () {\r\n $uibModalInstance.dismiss();\r\n };\r\n\r\n $scope.save = function () {\r\n $scope.isLoading = true;\r\n if(isBulk) {\r\n if (optionalArgs.parentCallsService) {\r\n $uibModalInstance.close(function () {\r\n return processingService.createDuplicateIntakeItemBulk(duplicateItem);\r\n });\r\n }\r\n else {\r\n processingService.createDuplicateIntakeItemBulk(duplicateItem)\r\n .then(function (response) {\r\n $scope.isLoading = false;\r\n $uibModalInstance.close(response);\r\n });\r\n }\r\n } else {\r\n processingService.createDuplicateIntakeItem(duplicateItem)\r\n .then(function(response) {\r\n $scope.isLoading = false;\r\n $uibModalInstance.close(response);\r\n }, function() {\r\n $scope.isLoading = false;\r\n $uibModalInstance.dismiss();\r\n });\r\n }\r\n };\r\n }\r\n})();\r\n","(function () {\r\n 'use strict';\r\n\r\n angular\r\n .module('weissmanApp')\r\n .controller('FilePreviewController', FilePreviewController);\r\n\r\n FilePreviewController.$inject = [\r\n '$sce',\r\n '$scope',\r\n 'popUpService',\r\n 'pubSubService',\r\n 'DocumentService',\r\n\t 'sdAttachmentService',\r\n\t 'sdNavbarTopService'\r\n ];\r\n\r\n function FilePreviewController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit(\r\n $sce,\r\n $scope,\r\n popUpService,\r\n pubSubService,\r\n documentService,\r\n attachmentService,\r\n navbarTopService\r\n ) {\r\n var _pubSubSubscriptions = [];\r\n\r\n var vm = this;\r\n vm.attachmentID = null;\r\n vm.attachmentFileName = null;\r\n vm.attachmentFileExtension = null;\r\n\r\n activate();\r\n // File preview doesn't have a navbar; use CSS to selectively add/remove the top content padding as appropriate\r\n document.body.classList.remove('show-nav');\r\n navbarTopService.showNavbar = false;\r\n navbarTopService.fullScreen = true;\r\n\r\n vm.previewSupported = false;\r\n\r\n vm.downloadAttachment = function () {\r\n attachmentService.downloadAttachmentByGuid(vm.attachmentID, vm.attachmentFileName, vm.attachmentFileExtension);\r\n };\r\n\r\n // clean up pub-sub subscription upon destroy\r\n $scope.$on('$destroy', function() {\r\n var i = _pubSubSubscriptions.length;\r\n while (i--) {\r\n _pubSubSubscriptions[i].unsubscribe();\r\n }\r\n });\r\n\r\n function activate() {\r\n // subscribe to pub-sub to handle \"attachmentChanged\" messages\r\n var subscription = pubSubService.subscribe(popUpService.Topics.Attachment.AttachmentChanged, function (data) {\r\n loadAttachment(data.attachmentInfo);\r\n });\r\n _pubSubSubscriptions.push(subscription);\r\n\r\n // notify the caller that the preview is ready\r\n pubSubService.publishParent(popUpService.Topics.Attachment.PreviewInitialized);\r\n }\r\n\r\n function loadAttachment(attachmentInfo) {\r\n if (attachmentInfo.attachmentID !== vm.attachmentID) {\r\n vm.fileInfo = attachmentService.getMimeTypeByFileExtension(attachmentInfo.fileExtension);\r\n vm.previewSupported = vm.fileInfo.previewSupported;\r\n if (vm.previewSupported) {\r\n documentService.getDocumentBody(attachmentInfo.attachmentID)\r\n .then(function (response) {\r\n var attachmentBlob = new Blob([response.data], { type: attachmentInfo.fileExtension });\r\n var attachmentBlobUrl = URL.createObjectURL(attachmentBlob);\r\n vm.attachmentUrl = $sce.trustAsResourceUrl(attachmentBlobUrl);\r\n vm.attachmentID = attachmentInfo.attachmentID;\r\n vm.attachmentFileName = attachmentInfo.fileName;\r\n vm.attachmentFileExtension = attachmentInfo.fileExtension;\r\n vm.fileError = false;\r\n }).catch(function () {\r\n vm.attachmentUrl = null;\r\n vm.attachmentID = attachmentInfo.attachmentID;\r\n vm.attachmentFileName = attachmentInfo.fileName;\r\n vm.attachmentFileExtension = attachmentInfo.fileExtension;\r\n vm.fileError = true;\r\n $scope.$apply();\r\n });\r\n }\r\n else {\r\n vm.attachmentUrl = null;\r\n vm.attachmentID = attachmentInfo.attachmentID;\r\n vm.attachmentFileName = attachmentInfo.fileName;\r\n vm.attachmentFileExtension = attachmentInfo.fileExtension;\r\n vm.fileError = false;\r\n $scope.$apply();\r\n }\r\n }\r\n }\r\n }\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory('processingService', processingService);\r\n\r\n\tprocessingService.$inject = [\r\n\t\t'sd.Quick.Filters.Service',\r\n\t\t'searchService',\r\n\t\t'sd.Http.Service',\r\n\t\t'sd.Account.User.Service',\r\n\t\t'$uibModal',\r\n\t\t'sd.Account.User.Settings.Service',\r\n\t\t'productAnalyticsService',\r\n\t];\r\n\r\n\tvar QUICK_SEARCH_SERVICE_URL = '/api/search';\r\n\tvar DUPLICATE_SERVICE_URL = '/api/documentintake/duplicate';\r\n\tvar DUPLICATE_BULK_SERVICE_URL = DUPLICATE_SERVICE_URL + '/bulk';\r\n\r\n\tfunction processingService(quickFilters, searchService, sdHttp, userService, $uibModal, userSettingsService, productAnalyticsService) {\r\n\t\tvar service = {\r\n\t\t\tgetCriteria: getCriteria,\r\n getCriteriaWithIdp: getCriteriaWithIdp,\r\n\t\t\tgetDefaultCriteria: getDefaultCriteria,\r\n\t\t\tgetResultTypes: getResultTypes,\r\n\t\t\tsaveCriteria: saveCriteria,\r\n\t\t\tgetSavedCriteria: getSavedCriteria,\r\n\t\t\tsearch: search,\r\n\t\t\tcompleteItem: completeItem,\r\n\t\t\tprocessDocumentException: processDocumentException,\r\n processDocumentBulkException: processDocumentBulkException,\r\n\t\t\tsaveItemEntity: saveItemEntity,\r\n\t\t\tgetEntityTree: getEntityTree,\r\n\t\t\tgetResultTypesByDocumentType: getResultTypesByDocumentType,\r\n launchDuplicateIntakeItemModal: launchDuplicateIntakeItemModal,\r\n // launchDuplicateIntakeItemBulkModal: launchDuplicateIntakeItemBulkModal,\r\n createDuplicateIntakeItem: createDuplicateIntakeItem,\r\n\t\t\tcreateDuplicateIntakeItemBulk: createDuplicateIntakeItemBulk,\r\n\t\t\tprocessNoAppealWarranted: processNoAppealWarranted,\r\n\t\t\tprocessAppealWarranted: processAppealWarranted,\r\n\t\t\tcompleteFileAppeal: completeFileAppeal,\r\n\t\t\tgetAppealLevels: getAppealLevels,\r\n\t\t\tchangeDueDate: changeDueDate,\r\n processPaymentReviewed: processPaymentReviewed,\r\n getBulkDocumentExceptionData: getBulkDocumentExceptionData,\r\n\t\t\tperformOCR: performOCR\r\n\t\t};\r\n\t\t\r\n var idpSubCategoryMap = {\r\n 'f601': 'Parcel Account Number',\r\n 'f602': 'Alternate Parcel Account Number',\r\n 'f603': 'Account Number',\r\n 'f604': 'Parcel Identification Number'\r\n }\r\n\r\n\t\tvar acctNumMap = [{\r\n\t\t\tfield: 'parcelDetails.parcelIdentificationNumber', \r\n\t\t\tname: 'Parcel Acct #'\r\n\t\t},{\r\n\t\t\tfield: 'parcelDetails.alternativeAccountNumber', \r\n\t\t\tname: 'Alternate Acct #'\r\n\t\t}]\r\n\r\n\t\treturn service;\r\n\r\n\r\n\t\t////////////////\r\n\r\n\t\tfunction getCriteria() {\r\n\t\t\treturn getSavedCriteria() || getDefaultCriteria();\r\n\t\t}\r\n\r\n\t\tfunction accessObj (path, object) {\r\n\t\t\treturn path.split('.').reduce((o, i) => {\r\n\t\t\t\treturn o ? o[i] : null;\r\n\t\t\t}, object)\r\n\t\t}\r\n\r\n function getCriteriaWithIdp(ocrResults) {\r\n // Get the defaults and overwrite with saved criteria which is likely missing some new fields\r\n const savedCriteria = getSavedCriteria();\r\n let criteria = getDefaultCriteria();\r\n if (savedCriteria) {\r\n criteria.activeFilters = criteria.activeFilters.map(x => {\r\n const saved = savedCriteria.activeFilters.find(y => y.field === x.field);\r\n return { ...x, ...saved, ocrFields: x.ocrFields };\r\n })\r\n }\r\n\r\n\t\t\tconst analyticsOcrFields = ['parcelAcctNum', 'taxCollector', 'taxYear']\r\n\r\n // Add IDP values to the filters\r\n criteria['isIdpSearch'] = true;\r\n criteria.activeFilters.forEach(filter => {\r\n\t\t\t\tif(filter.ocrFields?.length) {\r\n\t\t\t\t\tfilter.idpResults = filter.ocrFields\r\n\t\t\t\t\t\t.map(field => accessObj(field, ocrResults))\r\n\t\t\t\t\t\t.filter(x => x)\r\n\t\t\t\t\t\r\n\t\t\t\t\tfilter.text = filter.idpResults[0];\r\n\r\n\t\t\t\t\tif(_.includes(analyticsOcrFields, filter.field)) {\r\n\t\t\t\t\t\tproductAnalyticsService.logEvent('capture-partial-results', { OcrField: filter.name});\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n });\r\n\r\n return criteria;\r\n }\r\n\r\n\t\tfunction getDefaultCriteria() {\r\n\t\t\treturn {\r\n\t\t\t\tactiveFilters: quickFilters.getDocumentActive(),\r\n\t\t\t\tinactiveFilters: quickFilters.getDocumentInactive(),\r\n\t\t\t\tactiveOnly: true,\r\n\t\t\t\tprimaryAcctNumOnly: true\r\n\t\t\t};\r\n\t\t}\r\n\r\n\t\tfunction getResultTypes() {\r\n\t\t\tvar documentResultTypes = [{\r\n\t\t\t\tname: 'Assessments',\r\n\t\t\t\ttype: 'assessment',\r\n\t\t\t\tid: 7\r\n\t\t\t}, {\r\n\t\t\t\tname: 'Appeals',\r\n\t\t\t\ttype: 'appeal',\r\n\t\t\t\tid: 8\r\n\t\t\t}, {\r\n\t\t\t\tname: 'Tax Bills',\r\n\t\t\t\ttype: 'taxBill',\r\n\t\t\t\tid: 9\r\n\t\t\t}, {\r\n\t\t\t\tname: 'Refunds',\r\n\t\t\t\ttype: 'refund',\r\n\t\t\t\tid: 14\r\n\t\t\t}, {\r\n\t\t\t\tname: 'Comp Filing',\r\n\t\t\t\ttype: 'filing',\r\n\t\t\t\tid: 10\r\n\t\t\t}, {\r\n\t\t\t\tname: 'Invoices', // Added for WK-9242 -- Band aid fix. I imagine more result types are missing, but I'm not sure if we need to include all of the entity types\r\n\t\t\t\ttype: 'invoice',\r\n\t\t\t\tid: 21\r\n\t\t\t}];\r\n\r\n\t\t\treturn _.union(searchService.getResultTypes(), documentResultTypes)\r\n\t\t}\r\n\r\n\t\tfunction saveCriteria(criteria) {\r\n\t\t\tvar criteriaSetting = {\r\n\t\t\t\tid: 0,\r\n\t\t\t\tname: 'Document-Processing-Criteria',\r\n\t\t\t\tvalue: criteria,\r\n\t\t\t\tgroupId: 13,\r\n\t\t\t\tgroupName: 'Document-Processing-Criteria',\r\n\t\t\t\tfolderId: 20,\r\n\t\t\t\tfolderName: 'Document-Processing-Criteria',\r\n\t\t\t};\r\n\r\n\t\t\tvar existingCriteriaSettings = userSettingsService.getSettingsByGroup(13);\r\n\r\n\t\t\tif (existingCriteriaSettings.length) {\r\n\t\t\t\tcriteriaSetting = angular.copy(existingCriteriaSettings[0]);\r\n\t\t\t\tcriteriaSetting.value = angular.copy(criteria);\r\n\t\t\t}\r\n\r\n\t\t\tuserSettingsService.save(criteriaSetting)\r\n\r\n\t\t\treturn userSettingsService.save(criteriaSetting, userService.getUser().id)\r\n\t\t\t\t.then(function (setting) {\r\n\t\t\t\t\tconsole.log(setting)\r\n\t\t\t\t})\r\n\t\t}\r\n\r\n\t\tfunction getSavedCriteria() {\r\n\t\t\tvar existingCriteriaSettings = userSettingsService.getSettingsByGroup(13);\r\n\r\n\t\t\tif (existingCriteriaSettings.length) {\r\n\t\t\t var savedCriteria = angular.copy(existingCriteriaSettings[0].value);\r\n\t\t\t savedCriteria.executeSearch = false;\r\n\t\t\t\treturn savedCriteria;\r\n\t\t\t} else {\r\n\t\t\t\treturn null;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction search(pageNumber, numberToGet, criteria, resultTypes) {\r\n\t\t\tvar resultTypeObj = _.find(resultTypes, {\r\n\t\t\t\ttype: criteria.resultType\r\n\t\t\t});\r\n\r\n\t\t\tvar queryParams = {\r\n\t\t\t\tresultsAs: resultTypeObj.id,\r\n\t\t\t\tactiveOnly: criteria.activeOnly,\r\n\t\t\t\tprimaryAcctNumOnly: criteria.primaryAcctNumOnly,\r\n\t\t\t\tpageNumber: pageNumber,\r\n\t\t\t\tpageSize: numberToGet,\r\n\t\t\t\tanticipatedItemsOnly: criteria.anticipated,\r\n\t\t\t\tcurrentIntakeItemID: criteria.currentIntakeItemID,\r\n includeIntakeItemData: criteria.includeIntakeItemData,\r\n anticipatedAttachmentTypeID: criteria.anticipated ? criteria.anticipatedAttachmentTypeID : null\r\n\t\t\t};\r\n\r\n\t\t\tvar query = _.chain(criteria.activeFilters)\r\n\t\t\t\t.filter('text')\r\n\t\t\t\t.reduce(function (result, filter) {\r\n\t\t\t\t\tresult[filter.field] = filter.text;\r\n\r\n\t\t\t\t\treturn result;\r\n\t\t\t\t}, {})\r\n\t\t\t\t.assign(queryParams)\r\n\t\t\t\t.value();\r\n\r\n\t\t\treturn sdHttp.post(QUICK_SEARCH_SERVICE_URL + '/quick', query)\r\n\t\t\t\t.then(function (response) {\r\n\t\t\t\t\treturn {\r\n\t\t\t\t\t\t//results: JSON.parse(response)\r\n\t\t\t\t\t\tresults: response\r\n\t\t\t\t\t};\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction processDocumentException(documentID, taskID, entityDetails, actionID, newAssignment, commentBody, newDocumentTypeID, data, intakeItemRowVersion, parcelChanges) {\r\n\t\t\tvar documentTaskExceptionEndpoint = '/api/Processing/Document/' + documentID + '/Task/' + taskID + '/Exception';\r\n\t\t\tvar processedEntityDetails = entityDetails.entityID !== null ? entityDetails : null;\r\n\r\n\t\t\tvar exceptionDataObj = {\r\n\t\t\t\tdocumentExceptionAction: actionID,\r\n\t\t\t\tassociatedEntity: processedEntityDetails,\r\n\t\t\t\tnewAssignment: newAssignment,\r\n\t\t\t\tcommentBody: commentBody,\r\n newDocumentTypeID: newDocumentTypeID,\r\n\t\t\t\tentryJSON: data,\r\n\t\t\t\tintakeItemRowVersion: intakeItemRowVersion,\r\n\t\t\t\tparcelChanges: parcelChanges\r\n\t\t\t}\r\n\t\t\treturn sdHttp.put(documentTaskExceptionEndpoint, exceptionDataObj);\r\n\t\t}\r\n\r\n\t\tfunction processDocumentBulkException(payload) {\r\n\t\t return sdHttp.post('/api/Processing/Document/BulkException', payload);\r\n\t\t}\r\n\r\n\t\tfunction completeItem(documentID, taskID, entityDetails, newDocumentTypeID, data, intakeItemRowVersion, parcelChanges) {\r\n\t\t\tvar documentTaskProcessingEndpoint = '/api/Processing/Document/' + documentID + '/Task/' + taskID + '/Complete';\r\n\t\t\treturn sdHttp.put(documentTaskProcessingEndpoint, {\r\n associatedEntity: entityDetails,\r\n entryJSON: data,\r\n newDocumentTypeID: newDocumentTypeID,\r\n\t\t\t\tintakeItemRowVersion: intakeItemRowVersion,\r\n\t\t\t\tparcelChanges: parcelChanges\r\n });\r\n\t\t}\r\n\r\n\t\tfunction saveItemEntity(documentID, taskID, entityDetails, newDocumentTypeID, data, intakeItemRowVersion, parcelChanges) {\r\n\t\t\tvar documentTaskProcessingEndpoint = '/api/Processing/Document/' + documentID + '/Task/' + taskID;\r\n\t\t\treturn sdHttp.put(documentTaskProcessingEndpoint, {\r\n associatedEntity: entityDetails,\r\n entryJSON: data,\r\n newDocumentTypeID: newDocumentTypeID,\r\n\t\t\t\tintakeItemRowVersion: intakeItemRowVersion,\r\n\t\t\t\tparcelChanges: parcelChanges\r\n });\r\n\t\t}\r\n\r\n\t\tfunction getEntityTree(entityTypeId, entityId, extended) {\r\n\t\t var entityTreeEndpoint;\r\n\t\t if (extended) {\r\n\t\t entityTreeEndpoint = '/api/entityTree/extended/entityType/';\r\n\r\n\t\t }\r\n\t\t else {\r\n\t\t entityTreeEndpoint = '/api/entityTree/entityType/';\r\n\t\t }\r\n\r\n entityTreeEndpoint = entityTreeEndpoint + entityTypeId + '/entity/' + entityId;\r\n\t\t\treturn sdHttp.get(entityTreeEndpoint);\r\n\t\t}\r\n\r\n\t\tfunction getResultTypesByDocumentType(documentType) {\r\n\t\t\tvar resultTypes = _.filter(getResultTypes(), function (resultType) {\r\n\t\t\t\tvar entity = _.capitalize(resultType.type);\r\n\r\n\t\t\t\tswitch (entity) {\r\n\t\t\t\t\tcase 'Taxbill':\r\n\t\t\t\t\t\treturn documentType['allowAtTaxBill'] || documentType.allowAtTaxPayment;\r\n\t\t\t\t\tcase 'Filing':\r\n\t\t\t\t\t\treturn documentType['allowAt' + entity] || documentType.allowAtPPReturn;\r\n\t\t\t\t\tdefault:\r\n\t\t\t\t\t\treturn documentType['allowAt' + entity];\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\treturn resultTypes;\r\n\t\t}\r\n\r\n\t\t//TODO\r\n //Launch duplication modal with list of items\r\n/*\r\n function launchDuplicateIntakeItemBulkModal(duplicateItemInfo) {\r\n var modalInstance = $uibModal.open({\r\n templateUrl: 'app/Processing/Documents/Modals/_duplicateIntakeItemModal.html',\r\n controller: 'DuplicateIntakeItemModalController',\r\n controllerAs: 'vm',\r\n resolve: {\r\n isBulk: true,\r\n duplicateItem: duplicateItemInfo\r\n }\r\n });\r\n\r\n return modalInstance.result\r\n .then(function (response) {\r\n if (result)\r\n {\r\n toastr.success(response.length + ' items were created.', 'Duplication Complete');\r\n }\r\n });\r\n }\r\n*/\r\n\r\n //Launch duplication modal with single item\r\n function launchDuplicateIntakeItemModal(duplicateItemInfo) {\r\n var modalInstance = $uibModal.open({\r\n templateUrl: 'app/Processing/Documents/Modals/_duplicateIntakeItemModal.html',\r\n controller: 'DuplicateIntakeItemModalController',\r\n controllerAs: 'vm',\r\n\t\t\t\twindowClass: 'show',\r\n\t\t\t\tbackdropClass: 'show',\r\n resolve: {\r\n isBulk: false,\r\n duplicateItem: duplicateItemInfo\r\n }\r\n });\r\n\r\n return modalInstance.result;\r\n }\r\n\r\n //call API with list\r\n function createDuplicateIntakeItem(duplicateItem) {\r\n return sdHttp.post(DUPLICATE_SERVICE_URL, duplicateItem);\r\n }\r\n\r\n function createDuplicateIntakeItemBulk(duplicateItem) {\r\n return sdHttp.post(DUPLICATE_BULK_SERVICE_URL, duplicateItem);\r\n }\r\n\r\n\t\t//call API with single\r\n\r\n\r\n\t\tfunction processNoAppealWarranted(payload) {\r\n\t\t\treturn sdHttp.post('/api/processing/assessment/noappeal', payload);\r\n\t\t}\r\n\r\n\t\tfunction processAppealWarranted(payload) {\r\n\t\t\treturn sdHttp.post('/api/processing/assessment/appealwarranted', payload);\r\n\t\t}\r\n\r\n\t\tfunction completeFileAppeal(payload) {\r\n\t\t return sdHttp.put('/api/Tasks/completefileappeals', payload);\r\n\t\t}\r\n\r\n\t\tfunction getAppealLevels(taskIDs) {\r\n\t\t\treturn sdHttp.post('/api/processing/assessment/appeallevels', taskIDs);\r\n\t\t}\r\n\r\n\t\tfunction changeDueDate(taskIDs, dueDate, searchTimestamp) {\r\n\t\t return sdHttp.put('/api/tasks/changeduedates', {\r\n\t\t taskIDs: taskIDs,\r\n\t\t dueDate: dueDate,\r\n searchTimestamp: searchTimestamp\r\n\t\t });\r\n\t\t}\r\n\r\n\t\tfunction processPaymentReviewed(payload) {\r\n\t\t return sdHttp.put('/api/tasks/processpaymentreviewed', payload);\r\n\t\t}\r\n\r\n\t\tfunction getBulkDocumentExceptionData(taskIds) {\r\n\t\t\treturn sdHttp.post('/api/processing/Document/BulkException/TaskData', taskIds);\r\n\t\t}\r\n\r\n\t\tfunction performOCR(taskIDs) {\r\n\t\t\treturn sdHttp.post(`/api/processing/performidp`, taskIDs)\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n 'use strict';\r\n\r\n angular\r\n .module('weissmanApp')\r\n .controller('CompleteFileAppealModalController', CompleteFileAppealModalController);\r\n\r\n CompleteFileAppealModalController.$inject = ['taskIDs', '$uibModalInstance', 'processingService', 'searchTimestamp', 'optionalArgs', 'taskService', 'messageBoxService'];\r\n function CompleteFileAppealModalController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit(taskIDs, $uibModalInstance, processingService, searchTimestamp, optionalArgs, taskService, messageBoxService) {\r\n var vm = this;\r\n\r\n vm.payload = {\r\n taskIDs: taskIDs,\r\n filingReference: null,\r\n searchTimestamp: searchTimestamp\r\n }\r\n\r\n activate();\r\n\r\n ////////////////\r\n\r\n async function activate() {\r\n vm.loading = true;\r\n const warning = await taskService.validateAssessorStateReqs(taskIDs);\r\n if (warning) {\r\n await messageBoxService.warning(warning);\r\n }\r\n vm.loading = false;\r\n }\r\n\r\n vm.cancel = function () {\r\n $uibModalInstance.dismiss();\r\n }\r\n\r\n vm.process = function () {\r\n if (optionalArgs.parentCallsService) {\r\n $uibModalInstance.close(function () {\r\n return processingService.completeFileAppeal(vm.payload);\r\n });\r\n }\r\n else {\r\n vm.loading = true;\r\n\r\n processingService.completeFileAppeal(vm.payload).then(function (result) {\r\n $uibModalInstance.close(result);\r\n }, function (error) {\r\n $uibModalInstance.dismiss();\r\n });\r\n }\r\n\r\n //// Code to demonstrate partial success\r\n //console.log(['Faking out completing tasks', vm.payload]);\r\n //setTimeout(function () {\r\n // var result = {\r\n // errorResult: null\r\n // };\r\n\r\n // result.actionResults = _.map(vm.payload.taskIDs, function (taskID) {\r\n // return {\r\n // taskActionResult: {\r\n // taskID: taskID,\r\n // result: null, // would have value in real-world example\r\n // errorMessage: null,\r\n // isAuthorized: true,\r\n // authorizationReason: 'Assigned User'\r\n // }\r\n // };\r\n // });\r\n\r\n // result.actionResults[0].taskActionResult = {\r\n // taskID: result.actionResults[0].taskActionResult.taskID,\r\n // result: null,\r\n // errorMessage: 'An unexpected error has occurred: [uuid]',\r\n // isAuthorized: true,\r\n // authorizationReason: null\r\n // };\r\n\r\n // $uibModalInstance.close(result);\r\n //}, 500);\r\n }\r\n }\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller('BrowseColumnsModalController', BrowseColumnsModalController);\r\n\r\n\tBrowseColumnsModalController.$inject = ['$scope', 'columnsToExclude', '$uibModalInstance', 'advancedSearchService'];\r\n\r\n\tfunction BrowseColumnsModalController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit($scope, columnsToExclude, $uibModalInstance, advancedSearchService, taskSeriesTypeId) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.columnsToAdd = 0;\r\n\r\n\t\tvm.cancel = cancel;\r\n\t\tvm.addColumns = addColumns;\r\n\t\tvm.allColumnsDisabled = allColumnsDisabled;\r\n\t\tvm.toggleCategory = toggleCategory;\r\n\t\tvm.clearSelection = clearSelection;\r\n\r\n\t\tactivate();\r\n\r\n\t\t////////////////\r\n\r\n\t\tfunction activate() {\r\n\t\t\tvm.title = columnsToExclude ? 'Add Output Columns' : 'Add Filter Columns';\r\n\r\n\t\t\tvm.columnCategories = advancedSearchService.getFilteredColumnCategories(columnsToExclude);\r\n\r\n\t\t\tvar i = 0;\r\n\r\n\t\t\t$scope.$watch('vm.columnCategories', function () {\r\n\t\t\t\t// Hack to skip the first two watches (false positives)\r\n\t\t\t\tif (i++ < 2) {\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n\t\t\t\t\r\n\t\t\t\tvar allColumns = advancedSearchService.getAllColumns(vm.columnCategories);\r\n\t\t\t\t\r\n\t\t\t\tvm.columnsToAdd = _.filter(allColumns, 'toAdd');\r\n\r\n\t\t\t\t_.forEach(vm.columnCategories, function(category) {\r\n\t\t\t\t\tcategory.selectedCount = _.filter(vm.columnsToAdd, {categoryID: category.categoryID}).length;\r\n\r\n\t\t\t\t\t_.forEach(category.subcategories, function(subcategory) {\r\n\t\t\t\t\t\tsubcategory.selectedCount = _.filter(vm.columnsToAdd, {categoryID: subcategory.categoryID}).length;\r\n\t\t\t\t\t\tcategory.selectedCount += subcategory.selectedCount;\r\n\t\t\t\t\t});\r\n\t\t\t\t});\r\n\r\n\t\t\t\t// disable certain columns\r\n\t\t\t\tadvancedSearchService.disableColumns(vm.columnsToAdd, true, taskSeriesTypeId);\r\n\r\n\t\t\t}, true)\r\n\r\n\t\t}\r\n\r\n\t\tfunction allColumnsDisabled(category) {\r\n\t\t\tvar disableAllColumns = category.columns.length && _.every(category.columns, 'disabled');\r\n\r\n\t\t\tif (disableAllColumns) {\r\n\t\t\t\tcategory.isOpen = false;\r\n\t\t\t}\r\n\r\n\t\t\treturn disableAllColumns;\r\n\t\t}\r\n\r\n\t\tfunction cancel() {\r\n\t\t\tclearSelection();\r\n\t\t\t$uibModalInstance.dismiss();\r\n\t\t}\r\n\t\t\r\n\t\tfunction addColumns() {\r\n\t\t\t$uibModalInstance.close(vm.columnsToAdd);\r\n\t\t}\r\n\t\t\r\n\t\tfunction toggleCategory(category) {\r\n\t\t\tif (!vm.allColumnsDisabled(category)) {\r\n\t\t\t\tcategory.isOpen = !category.isOpen;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\tfunction clearSelection() {\r\n\t\t\tvar allColumns = advancedSearchService.getAllColumns(vm.columnCategories);\r\n\r\n\t\t\tallColumns = _.map(allColumns, function (column) {\r\n\t\t\t\tcolumn.toAdd = false;\r\n\r\n\t\t\t\treturn column;\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdColumnCheckboxes', sdColumnCheckboxes);\r\n\r\n\tsdColumnCheckboxes.$inject = [];\r\n\r\n\tfunction sdColumnCheckboxes() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Search/Advanced/Column-Picker/_columnCheckboxes.html',\r\n\t\t\tscope: {\r\n\t\t\t\tcategory: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit() {\r\n\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdColumnPicker', sdColumnPicker);\r\n\r\n\tfunction sdColumnPicker() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Search/Advanced/Column-Picker/_columnPicker.html',\r\n\t\t\tscope: {\r\n\t\t\t\tcolumnSelectedFn: '&',\r\n\t\t\t\tcolumnsToExclude: '=',\r\n\t\t\t\tincludeTaskColumns: '=',\r\n\t\t\t\tdisableColumnsAfterLoad: '=',\r\n\t\t\t\ttaskSeriesTypeAdvancedSearchDepthValue: '=',\r\n\t\t\t\tcpMode: '@'\r\n\t\t\t}\r\n\t\t};\r\n\r\n\t\treturn directive;\r\n\t}\r\n\r\n\tController.$inject = ['advancedSearchService', '$timeout', '$uibModal'];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(advancedSearchService, $timeout, $uibModal) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.columnToAdd = '';\r\n\t\tvm.columns = null;\r\n\r\n\t\tvm.columnSelected = columnSelected;\r\n\t\tvm.filterFromExclude = filterFromExclude;\r\n\t\tvm.openBrowseModal = openBrowseModal;\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\r\n\t\t\t//console.log('mode: ', vm.cpMode);\r\n\r\n\t\t\tadvancedSearchService.getColumns(vm.includeTaskColumns, vm.cpMode)\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t\tvm.columns = result;\r\n\r\n\t\t\t\t\tif (vm.disableColumnsAfterLoad) {\r\n\t\t\t\t\t\tadvancedSearchService.disableColumns(vm.columnsToExclude, false, vm.taskSeriesTypeAdvancedSearchDepthValue)\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction columnSelected($item) {\r\n\t\t\t$timeout(function () {\r\n\t\t\t\tvm.columnSelectedFn({\r\n\t\t\t\t\tselectedColumns: [$item]\r\n\t\t\t\t});\r\n\r\n\t\t\t\tvm.columnToAdd = '';\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction filterFromExclude(allColumns) {\r\n\t\t\treturn _.chain(allColumns)\r\n\t\t\t\t.reject('disabled')\r\n\t\t\t\t.reject(rejectExcluded)\r\n\t\t\t\t.value();\r\n\t\t}\r\n\r\n\t\tfunction rejectExcluded(column) {\r\n\t\t\tvar columnId = column.columnId || column.advancedSearchFieldID || column.id;\r\n\t\t\tvar columnIdFound = _.some(vm.columnsToExclude, { columnId: columnId });\r\n\t\t\tvar idFound = _.some(vm.columnsToExclude, { id: columnId });\r\n\t\t\tvar advancedSearchFieldIdFound = _.some(vm.columnsToExclude, { advancedSearchFieldID: columnId });\r\n\r\n\t\t\treturn columnIdFound || idFound || advancedSearchFieldIdFound;\r\n\t\t}\r\n\r\n\t\tfunction openBrowseModal() {\r\n\t\t\tvar modalInstance = $uibModal.open({\r\n\t\t\t\ttemplateUrl: 'app/Search/Advanced/Column-Picker/_browseColumnsModal.html',\r\n\t\t\t\tcontroller: 'BrowseColumnsModalController',\r\n\t\t\t\tcontrollerAs: 'vm',\r\n\t\t\t\tsize: 'lg',\r\n\t\t\t\twindowClass: 'as-add-columns-modal show',\r\n\t\t\t\tbackdropClass: 'show',\r\n\t\t\t\tbackdrop: 'static',\r\n\t\t\t\tresolve: {\r\n\t\t\t\t\tcolumnsToExclude: function () {\r\n\t\t\t\t\t\treturn vm.columnsToExclude;\r\n\t\t\t\t\t},\r\n\r\n\t\t\t\t\ttaskSeriesTypeAdvancedSearchDepthValue: function () {\r\n\t\t\t\t\t\treturn vm.taskSeriesTypeAdvancedSearchDepthValue;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\tmodalInstance.result\r\n\t\t\t\t.then(function (columnsToAdd) {\r\n\t\t\t\t\t$timeout(function () {\r\n\t\t\t\t\t\tvm.columnSelectedFn({\r\n\t\t\t\t\t\t\tselectedColumns: columnsToAdd\r\n\t\t\t\t\t\t});\r\n\t\t\t\t\t});\r\n\t\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Search.Quick.Criteria.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'$scope',\r\n\t\t'sdLogger',\r\n\t\t'searchService',\r\n\t\t'sd.Quick.Filters.Service',\r\n 'productAnalyticsService'\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit($scope, sdLogger, searchService, quickFiltersService, productAnalyticsService) {\r\n\t\tvar appSource = APP_SOURCE;\r\n\t\t/* jshint validthis:true */\r\n\t\tvar vm = this;\r\n\r\n\t\t// Variables\r\n\t\tvm.criteria = {\r\n\t\t\tresultType: 'youshouldneverseeme'\r\n\t\t};\r\n vm.navigatingFrom = null;\r\n\r\n\t\t// Functions\r\n\t\tvm.clearForm = clearForm;\r\n\t\tvm.search = search;\r\n\r\n\t\tactivate();\r\n\r\n\t\t//Function Definitions\r\n\t\tfunction activate() {\r\n\t\t\tsearchService.registerReset(resetCriteria);\r\n\r\n\t\t\tsdLogger.log(appSource + '.activate(): ', {\r\n\t\t\t\t'vm': vm\r\n\t\t\t});\r\n\r\n\t\t\tfunction addOrUpdateFilter(fieldName, filter, filterTextValue) {\r\n\t\t\t\t// check if these filters have been added or not\r\n\t\t\t\tfilter.text = filterTextValue;\r\n\t\t\t\tvar idx = _.findIndex(vm.criteria.activeFilters, {field: fieldName});\r\n\r\n\t\t\t\t// Handle filter\r\n\t\t\t\tif (idx >= 0) {\r\n\t\t\t\t\tvm.criteria.activeFilters[idx] = filter;\r\n\t\t\t\t} else {\r\n\t\t\t\t\tvm.criteria.activeFilters.push(filter);\r\n\t\t\t\t\t_.remove(vm.criteria.inactiveFilters, { field: fieldName });\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\r\n\t\t\t$scope.$on('quickSearch:getSitesForCompany', function (event, state, currentCompany, activeOnly, includeSubsidiarySites, primaryAcctNumOnly) {\r\n\r\n\t\t\t\tconsole.log('Quick.Criteria.Controller - received quickSearch:criteriaChanged event', state, currentCompany, activeOnly, primaryAcctNumOnly);\r\n\r\n\t\t\t\tvar stateField = 'siteStateAbbr';\r\n\t\t\t\tvar companyField = 'companyName';\r\n\t\t\t\tvar companyIDField = 'companyID';\r\n\r\n\t\t\t\t// hardcoded set\r\n\t\t\t\tvar allFilters = quickFiltersService.getAll();\r\n\r\n\t\t\t\t// get companyName and stateAbbr filters\r\n\t\t\t\tvar stateFilter = _.find(allFilters, {field: stateField});\r\n\t\t\t\tvar companyFilter = _.find(allFilters, {field: companyField});\r\n\t\t\t\tvar companyIDFilter = _.find(allFilters, {field: companyIDField});\r\n\r\n\t\t\t\tvar query = {\r\n\t\t\t\t\tactiveOnly: activeOnly,\r\n\t\t\t\t\tprimaryAcctNumOnly: primaryAcctNumOnly,\r\n\t\t\t\t\tpageNumber: 1,\r\n\t\t\t\t\tpageSize: 30,\r\n\t\t\t\t\tresultType: 'site',\r\n\t\t\t\t\tresultsAs: { id: 5 },\r\n\t\t\t\t\tsiteStateAbbr: state,\r\n\t\t\t\t\texcludeSubsidiarySites: !includeSubsidiarySites,\r\n\t\t\t\t\tactiveFilters: [companyFilter, stateFilter]\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// todo: what is going on here?\r\n\t\t\t\tsearchService.reset();\r\n\t\t\t\tsearchService.resetCriteria();\r\n\t\t\t\tsearchService.resetCriteriaToDefault();\r\n\r\n\t\t\t\t// get default criteria, add (or assign value to) companyName and stateAbbr elements\r\n\t\t\t\tvm.criteria = searchService.getCriteria();\r\n\r\n\t\t\t\t// set the result type to 'site'\r\n\t\t\t\tvm.criteria.resultType = query.resultType;\r\n\r\n\t\t\t\taddOrUpdateFilter(stateField, stateFilter, state);\r\n\t\t\t\taddOrUpdateFilter(companyField, companyFilter, currentCompany.companyName);\r\n\t\t\t\taddOrUpdateFilter(companyIDField, companyIDFilter, currentCompany.companyID);\r\n\r\n vm.criteria.activeOnly = activeOnly;\r\n\t\t\t\tvm.criteria.primaryAcctNumOnly = primaryAcctNumOnly;\r\n\t\t\t\tvm.criteria.excludeSubsidiarySites = !includeSubsidiarySites\r\n\r\n\t\t\t\t// set criteria and trigger the search\r\n\t\t\t\tsearchService.setCriteria(vm.criteria, true);\r\n\t\t\t});\r\n\t\t}\r\n\r\n\r\n\t\tfunction resetCriteria(msg) {\r\n\t\t\tsdLogger.log(appSource + '.resetCriteria(): ', msg);\r\n\r\n\t\t\tclearForm();\r\n\t\t}\r\n\r\n\t\tfunction clearForm() {\r\n\t\t\tsearchService.loadSavedCriteria(); // ToDo: Move this to activate function once we are no longer loading search on initial app load.\r\n\r\n\t\t\tsearchService.resetCriteria();\r\n\t\t\tvm.resultTypes = searchService.getResultTypes();\r\n\t\t\tvm.criteria = searchService.getCriteria();\r\n\r\n\t\t\tsdLogger.log(appSource + '.clearForm(): ', {\r\n\t\t\t\t'vm': vm\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction search(fromEnterKey = false) {\r\n\t\t\tsdLogger.log(appSource + '.search(): ', {\r\n\t\t\t\tcriteria: vm.criteria\r\n\t\t\t});\r\n\r\n productAnalyticsService.logEvent('execute-quick-search');\r\n if (vm.navigatingFrom === 'dashboard') {\r\n productAnalyticsService.logEvent('click-quick-search-widget', {\r\n quickSearchWidget: vm.criteria.resultType\r\n });\r\n }\r\n\r\n const filters = vm.criteria.activeFilters.map(x => ({ field: x.field, value: x.text }));\r\n const otherNonDefaultCriteria = filters.filter(x => {\r\n return !['companyName', 'companyID','parcelAcctNum', 'siteName', 'siteAssessor', 'siteStateAbbr'].includes(x.field);\r\n }).map(x => `${x.field}: ${x.value ? 'yes' : 'no'}`);\r\n\r\n productAnalyticsService.logEvent('enter-quick-search-criteria', {\r\n companyName: filters.find(x => x.field === 'companyName')?.value ? 'yes' : 'no',\r\n\t\t\t\tcompanyID: filters.find(x => x.field === 'companyID')?.value ? 'yes' : 'no',\r\n excludeInactive: vm.criteria.activeOnly ? 'yes' : 'no',\r\n parcelAcctNum: filters.find(x => x.field === 'parcelAcctNum')?.value ? 'yes' : 'no',\r\n otherNonDefaultCriteria: otherNonDefaultCriteria.length ? otherNonDefaultCriteria : undefined,\r\n primaryAcctNumOnly: vm.criteria.primaryAcctNumOnly ? 'yes' : 'no',\r\n resultsDropDown: vm.criteria.resultType ? 'yes' : 'no',\r\n siteName: filters.find(x => x.field === 'siteName')?.value ? 'yes' : 'no',\r\n siteAssessor: filters.find(x => x.field === 'siteAssessor')?.value ? 'yes' : 'no',\r\n siteStateAbbr: filters.find(x => x.field === 'siteStateAbbr')?.value ? 'yes' : 'no',\r\n initiateQuickSearch: fromEnterKey ? 'enter' : 'quick search button'\r\n });\r\n\r\n\t\t\tsearchService.setCriteria(vm.criteria, true);\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:sdSearchCriteria\r\n * @description\r\n * # sdSearchCriteria\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Search.Quick.Criteria.Directive';\r\n\tvar VIEW_TEMPLATE_URL = 'app/Search/Quick/_quickCriteria.html';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdQuickSearchCriteria', CriteriaDirective);\r\n\r\n\tCriteriaDirective.$inject = ['sdLogger', 'StatesService', 'sd.Property.Type.Service', 'appStateService'];\r\n\r\n\tfunction CriteriaDirective(sdLogger, StatesService, propertyTypeService, appStateService) {\r\n\t\treturn {\r\n\t\t\trestrict: 'E',\r\n\t\t\treplace: true,\r\n\t\t\tscope: {\r\n\t\t\t\tcriteria: '=criteria',\r\n navigatingFrom: '=navigatingFrom',\r\n isOpen: '=isOpen'\r\n\t\t\t},\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: 'sd.Search.Quick.Criteria.Controller',\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: function (scope) {\r\n appStateService.appState$.subscribe(function (state) {\r\n if (state === appStateService.appStates.LoggedIn) {\r\n StatesService.getSummary().then(function (result) {\r\n result.unshift({\r\n label: ''\r\n });\r\n scope.vm.states = result;\r\n });\r\n }\r\n });\r\n\r\n\t\t\t\tpropertyTypeService.get().then(function (result) {\r\n\t\t\t\t\tresult.unshift({\r\n\t\t\t\t\t\tpropertyTypeID: '',\r\n\t\t\t\t\t\tpropTypeAbbr: ''\r\n\t\t\t\t\t});\r\n\t\t\t\t\tscope.vm.propertyTypes = result;\r\n\t\t\t\t});\r\n\r\n\t\t\t\tsdLogger.log(APP_SOURCE + '.link(): ', {\r\n\t\t\t\t\t'scope': scope\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\t};\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Search.Quick.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, SectionController);\r\n\r\n\tSectionController.$inject = [\r\n\t\t'$scope',\r\n\t\t'sdLogger',\r\n\t\t'sd.Navigation.Service',\r\n\t\t'searchService',\r\n\t\t'sd.Account.User.Service',\r\n\t\t'hotkeys',\r\n\t\t'sd.Property.Type.Service',\r\n\t\t'advancedSearchPersistenceService',\r\n\t\t'actionViewPersistenceService',\r\n 'sd.Account.User.Settings.Service',\r\n 'productAnalyticsService',\r\n 'nubService'\r\n\t];\r\n\r\n\tfunction SectionController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit($scope, sdLogger, navigationService, searchService, userService, hotkeys, propertyTypeService, advancedSearchPersistenceService, actionViewPersistenceService, userSettingsService, productAnalyticsService, nubService) {\r\n\t\tvar appSource = APP_SOURCE;\r\n\t\t/* jshint validthis:true */\r\n\t\tvar vm = this;\r\n\t\tvm.active = false; // prevent initial animation on page load\r\n\t\tvm.showSearch = false;\r\n\t\tvm.toggleSearch = toggleSearchVisibility;\r\n\t\tvm.showTab = false;\r\n\t\tvm.showCriteria = false;\r\n\t\tvm.toggleCriteria = toggleCriteriaVisibility;\r\n\t\tvm.showResults = false;\r\n\t\tvm.toggleResults = toggleResultsVisibility;\r\n\t\tvm.resetClicked = resetClicked;\r\n\t\tvm.resetSearch = resetSearch;\r\n\t\tvm.saveSearch = saveSearch;\r\n\t\tvm.criteria = searchService.getCriteria();\r\n vm.navigatingFrom = null;\r\n\r\n\t\tvm.advancedSearchData = advancedSearchPersistenceService;\r\n\t\tvm.actionViewData = actionViewPersistenceService;\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\r\n\t\t\t//searchService.resetCriteriaList = true;\r\n\t\t\tnavigationService.registerQuickSearch(openQuickSearchListener);\r\n\t\t\tsearchService.registerCriteriaChanged(criteriaChangedListenerVisibility);\r\n\r\n\t\t\tpropertyTypeService.get().then(function (data) {\r\n\t\t\t\t// todo: in order to do it properly, service must be able to queue all requests until it has the data\r\n\t\t\t\t//console.log('quick search - this is a hack - getting property types - so we dont send 50 requests at once later', data);\r\n\t\t\t});\r\n\r\n nubService.showQuickSearch$.subscribe(function () {\r\n toggleSearchVisibility(null, true);\r\n });\r\n\r\n\t\t\tsdLogger.log(appSource + '.activate(): ', {\r\n\t\t\t\t'vm': vm\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction criteriaChangedListenerVisibility() {\r\n\t\t\tsetShowCriteria(false);\r\n\t\t\tsetShowResults(true);\r\n\r\n\t\t\tsdLogger.log(APP_SOURCE + '.criteriaChangedListener(): ', {\r\n\t\t\t\t'vm': vm\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction openQuickSearchListener(navigatingFrom) {\r\n vm.navigatingFrom = navigatingFrom || null;\r\n\t\t\tvm.resetSearch(searchService.resetCriteriaList);\r\n\r\n\t\t\tsearchService.resetActiveFilterValues();\r\n\t\t\tvm.showSearch = true;\r\n\t\t\tsearchService.focusOnFilter(0);\r\n\t\t}\r\n\r\n\t\tfunction toggleSearchVisibility(event, tabClicked) {\r\n if (event) {\r\n event.stopPropagation();\r\n }\r\n\r\n\t\t\tvm.active = true; // set to true on initial click. no need to set it back\r\n vm.navigatingFrom = null;\r\n\r\n vm.showSearch = !vm.showSearch;\r\n\r\n if (tabClicked) {\r\n productAnalyticsService.logEvent('quick-search-results-tab');\r\n }\r\n\r\n\t\t\tif (vm.showResults) {\r\n\t\t\t\tif (vm.showSearch) {\r\n\t\t\t\t\tvar clickedOnResultIndex = searchService.getClickedOnResultIndex();\r\n\t\t\t\t\tif (clickedOnResultIndex) {\r\n\t\t\t\t\t\tsearchService.focusOnResult(clickedOnResultIndex);\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tsearchService.focusOnElement('.search-results-infinite')\r\n\t\t\t\t\t}\r\n\t\t\t\t\tsetShowTab(false);\r\n\t\t\t\t} else {\r\n\t\t\t\t\tsetShowTab(true);\r\n\t\t\t\t}\r\n\r\n\t\t\t} else {\r\n\t\t\t\tsetShowTab(false);\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.showSearch) {\r\n\t\t\t\tbindHotKeys();\r\n\t\t\t} else {\r\n\t\t\t\tunbindHotKeys();\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction setShowCriteria(bool) {\r\n\t\t\tvm.showCriteria = bool;\r\n\t\t}\r\n\r\n\t\tfunction toggleCriteriaVisibility() {\r\n\t\t\tvm.showCriteria = !vm.showCriteria;\r\n\r\n\t\t\tif (vm.showCriteria) {\r\n\t\t\t\tsearchService.focusOnFilter(0);\r\n productAnalyticsService.logEvent('refine-quick-search-criteria');\r\n\t\t\t} else {\r\n\t\t\t\tsearchService.focusOnResult(0);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction setShowResults(bool) {\r\n\t\t\tvm.showResults = bool;\r\n\t\t}\r\n\r\n\t\tfunction toggleResultsVisibility(event) {\r\n\t\t\tevent.preventDefault();\r\n\t\t\tvm.showResults = !vm.showResults;\r\n\t\t}\r\n\r\n function resetClicked() {\r\n productAnalyticsService.logEvent('reset-quick-search-criteria');\r\n resetSearch(true);\r\n }\r\n\r\n\t\tfunction resetSearch(clearCriteria) {\r\n\t\t\tsearchService.reset();\r\n\r\n\t\t\tif(clearCriteria) {\r\n\t\t\t\tsearchService.clearCriteria();\r\n\t\t\t}\r\n\r\n\t\t\tsetShowTab(false);\r\n\r\n\t\t\tsetShowCriteria(true);\r\n\r\n\t\t\tsetShowResults(false);\r\n\r\n\t\t\tbindHotKeys();\r\n\t\t}\r\n\r\n\t\tfunction saveSearch() {\r\n\t\t\tsearchService.setCriteria(vm.criteria, false);\r\n\r\n\t\t\tsearchService.saveCriteria(vm.criteria)\r\n\t\t\t\t.then(function () {\r\n\t\t\t\t\tsearchService.focusOnFilter(0);\r\n\t\t\t\t\tsdLogger.success('Save', 'Search criteria successfully saved.');\r\n\t\t\t\t\tsdLogger.log(appSource + '.saveSearch(): ', {\r\n\t\t\t\t\t\t'userSettings': userSettingsService.getSettings(),\r\n\t\t\t\t\t\t'criteria': searchService.getCriteria()\r\n\t\t\t\t\t});\r\n\t\t\t\t})\r\n\t\t\t\t.catch(function (error) {\r\n\t\t\t\t\tsdLogger.error('Save Search', 'Unable to save search criteria.', error);\r\n\t\t\t\t});\r\n\r\n productAnalyticsService.logEvent('save-quick-search-criteria');\r\n\t\t}\r\n\r\n\t\tfunction setShowTab(bool) {\r\n if (bool) {\r\n nubService.showQuickSearchNub();\r\n } else {\r\n nubService.hideNub();\r\n }\r\n\t\t}\r\n\r\n\t\tfunction bindHotKeys() {\r\n\t\t\thotkeys.add({\r\n\t\t\t\tcombo: 'alt+c',\r\n\t\t\t\tdescription: 'Toggle Criteria',\r\n\t\t\t\tcallback: toggleCriteriaVisibility,\r\n\t\t\t\tallowIn: ['INPUT', 'SELECT']\r\n\t\t\t});\r\n\t\t\thotkeys.add({\r\n\t\t\t\tcombo: 'alt+r',\r\n\t\t\t\tdescription: 'Reset Search',\r\n\t\t\t\tcallback: resetSearch,\r\n\t\t\t\tallowIn: ['INPUT', 'SELECT']\r\n\t\t\t});\r\n\t\t\thotkeys.add({\r\n\t\t\t\tcombo: 'esc',\r\n\t\t\t\tdescription: 'Toggle Search',\r\n\t\t\t\tcallback: toggleSearchVisibility,\r\n\t\t\t\tallowIn: ['INPUT', 'SELECT']\r\n\t\t\t});\r\n\r\n\t\t\tsdLogger.log(APP_SOURCE + '.bindHotKeys(): ', {\r\n\t\t\t\t'vm': vm\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction unbindHotKeys() {\r\n\t\t\thotkeys.del('alt+c');\r\n\t\t\thotkeys.del('alt+r');\r\n\t\t\thotkeys.del('esc');\r\n\r\n\t\t\tsdLogger.log(APP_SOURCE + '.unbindHotKeys(): ', {\r\n\t\t\t\t'vm': vm\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:sdQuickSearch\r\n * @description\r\n * # Quick Search\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Search.Quick.Directive';\r\n\tvar VIEW_TEMPLATE_URL = 'app/Search/Quick/_quickSection.html';\r\n\tvar CONTROLLER_NAME = 'sd.Search.Quick.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdQuickSearch', Directive);\r\n\r\n\tDirective.$inject = [\r\n\t\t'sdLogger'\r\n\t];\r\n\r\n\tfunction Directive(sdLogger) {\r\n\t\tvar directive = {\r\n\t\t\trestrict: 'E',\r\n\t\t\treplace: true,\r\n\t\t\tscope: true,\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: CONTROLLER_NAME,\r\n\t\t\tcontrollerAs: 'vm'\r\n\t\t};\r\n\r\n\t\treturn directive;\r\n\t};\r\n})();\r\n","'use strict';\r\n\r\n/**\r\n * @ngdoc directive\r\n * @name weissmanApp.directive:searchResultCompany\r\n * @description\r\n * # searchResultCompany\r\n */\r\nangular.module('weissmanApp')\r\n\t.directive('searchResultCompany', function () {\r\n\t\treturn {\r\n\t\t\ttemplateUrl: 'app/Search/Quick/_quickResultCompany.html',\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tresult: '='\r\n\t\t\t},\r\n\t\t\tlink: function postLink(scope, element, attrs) {\r\n\r\n\r\n\t\t\t}\r\n\t\t};\r\n\t});\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:SearchResultInfinite\r\n * @description\r\n * # SearchResultInfinite\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar VIEW_TEMPLATE_URL = 'app/Search/Quick/_quickResultExtra.html';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdQuickResultExtra', ResultExtra);\r\n\r\n\tResultExtra.$inject = [];\r\n\r\n\tfunction ResultExtra() {\r\n\t\treturn {\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tresult: '=',\r\n\t\t\t\tfilter: '='\r\n\t\t\t},\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\t// bindToController: true,\r\n\t\t\t// controller: 'sd.Search.Quick.Result.Infinite.Controller',\r\n\t\t\t// controllerAs: 'vm',\r\n\t\t\tlink: function (scope) {\r\n\t\t\t\tscope.descriptors = [];\r\n\t\t\t\tscope.resultField = '';\r\n\r\n\t\t\t\tscope.isDescriptor = isDescriptor;\r\n\r\n\t\t\t\tif (isDescriptor()) {\r\n\t\t\t\t\tscope.descriptors = getDescriptors();\r\n\t\t\t\t} else {\r\n\t\t\t\t\tscope.resultField = getResultField();\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction getResultField() {\r\n\t\t\t\t\tvar value = '';\r\n\r\n\t\t\t\t\tswitch (scope.filter.field) {\r\n\t\t\t\t\t\tcase 'parcelAddress':\r\n\t\t\t\t\t\t\tvalue += scope.result.parcelAddress1 || '';\r\n\t\t\t\t\t\t\tif (scope.result.parcelAddress2) {\r\n\t\t\t\t\t\t\t\tvalue += ', ' + scope.result.parcelAddress2;\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\treturn value;\r\n\t\t\t\t\t\tcase 'siteAddress':\r\n\t\t\t\t\t\t\tvalue += scope.result.siteAddress1 || '';\r\n\t\t\t\t\t\t\tif (scope.result.siteAddress2) {\r\n\t\t\t\t\t\t\t\tvalue += ', ' + scope.result.siteAddress2;\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\treturn value;\r\n\t\t\t\t\t\tcase 'parcelAssessor':\r\n\t\t\t\t\t\t\tvalue += scope.result.parcelAssessorAbbr || '';\r\n\t\t\t\t\t\t\tif (scope.result.parcelAssessorMunicipality) {\r\n\t\t\t\t\t\t\t\tvalue += ' ' + scope.result.parcelAssessorMunicipality;\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\treturn value;\r\n\t\t\t\t\t\tcase 'siteAssessor':\r\n\t\t\t\t\t\t\tvalue += scope.result.siteAssessorAbbr || '';\r\n\t\t\t\t\t\t\tif (scope.result.siteAssessorMunicipality) {\r\n\t\t\t\t\t\t\t\tvalue += ' ' + scope.result.siteAssessorMunicipality;\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\treturn value;\r\n\t\t\t\t\t\tdefault:\r\n\t\t\t\t\t\t\treturn scope.result[scope.filter.resultField] || '';\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction getDescriptors() {\r\n\t\t\t\t\tvar descriptors = _.chain(scope.result)\r\n\t\t\t\t\t\t.pickBy(function (val, key) {\r\n\t\t\t\t\t\t\treturn key.split('.')[0] === scope.filter.field && val;\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.map(function (val, key) {\r\n\t\t\t\t\t\t\treturn {\r\n\t\t\t\t\t\t\t\tlabel: key.substring(key.indexOf('.') + 1),\r\n\t\t\t\t\t\t\t\tvalue: val\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.value();\r\n\r\n\t\t\t\t\treturn descriptors;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction isDescriptor() {\r\n\t\t\t\t\treturn scope.filter.field === 'parcelDescriptor' || scope.filter.field === 'siteDescriptor'\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t};\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:Search.Result.Infinite.Controller\r\n * @description\r\n * # Search.Result.Infinite.Controller\r\n * Controller of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Search.Quick.Result.Infinite.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'$scope',\r\n\t\t'$location',\r\n\t\t'$timeout',\r\n\t\t'sdLogger',\r\n\t\t'searchService',\r\n\t\t'advancedSearchPersistenceService',\r\n\t\t'productAnalyticsService',\r\n 'nubService',\r\n 'sd.Navigation.Service'\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit($scope, $location, $timeout, sdLogger, searchService, advancedSearchPersistenceService, productAnalyticsService, nubService, navigationService) {\r\n\t\tvar appSource = APP_SOURCE;\r\n\t\t/* jshint validthis:true */\r\n\t\tvar vm = this;\r\n\r\n\t\t// Variables\r\n\t\tvm.loading = false;\r\n\t\tvm.allowToShowSpinner = true;\t// we can hide spinner if it's unlikely that there are more results\r\n\t\tvm.itemsPerPage = 30;\r\n\t\tvm.results = [];\r\n\t\tvm.criteria = {};\r\n\r\n\t\t// Functions\r\n\t\tvm.navigate = navigate;\r\n\t\tvm.getResults = getResults;\r\n\t\tvm.refreshResults = refreshResults;\r\n\t\tvm.pgDn = pgDn;\r\n\t\tvm.pgUp = pgUp;\r\n\t\tvm.hoverIn = hoverIn;\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\t\t\tgetResults('infinite scroll activate').finally(newResults);\r\n\r\n\t\t\tsearchService.registerCriteriaChanged(criteriaChangedListenerInfinite);\r\n\r\n\t\t\tsdLogger.log(appSource + '.activate(): ', {\r\n\t\t\t\t'$scope': $scope,\r\n\t\t\t\t'vm': vm\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction newResults() {\r\n\t\t\tsearchService.focusOnResult(0);\r\n\r\n\t\t\tif (vm.results.length === 1) {\r\n\t\t\t\t$timeout(function () {\r\n\t\t\t\t\tnavigate(vm.results[0])\r\n\t\t\t\t}, 1000)\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction closeSearch() {\r\n\t\t\t$scope.$parent.vm.showSearch = false;\r\n nubService.showQuickSearchNub();\r\n\t\t}\r\n\r\n\t\tfunction criteriaChangedListenerInfinite() {\r\nconsole.log('criteriaChangedListenerInfinite');\r\n\t\t\t//console.log('search criteria has been changed');\r\n\t\t\tvm.allowToShowSpinner = true;\r\n\r\n\t\t\tresetResults();\r\n\r\n\t\t\tgetResults('criteria changed listener').finally(newResults);\r\n\r\n\t\t\tsdLogger.log(appSource + ': Refreshed results due to criteria changed event.', {\r\n\t\t\t\t'$scope': $scope,\r\n\t\t\t\t'vm': vm\r\n\t\t\t});\r\n\t\t}\r\n\r\n\r\n\t\tasync function getResults(caller) {\r\n\t\t\tconsole.log(caller);\r\n\r\n\t\t\tvm.loading = true;\r\n\r\n\t\t\ttry {\r\n\t\t\t\tvm.criteria = searchService.getCriteria();\r\n\t\t\t\tloadExtraFilters();\r\n\r\n\t\t\t\tvar pageNumber = vm.results ? Math.ceil(vm.results.length / vm.itemsPerPage) + 1 : 1;\r\n\r\n\t\t\t\tconst resultsObj = await searchService.searchElastic(pageNumber, vm.itemsPerPage);\r\n\t\t\t\t//console.log('getResults - we have response from server', resultsObj)\r\n\r\n\t\t\t\tif (resultsObj.results.length === 0)\r\n\t\t\t\t\tvm.allowToShowSpinner = false;\r\n\r\n\t\t\t\tvm.results = vm.results.concat(resultsObj.results);\r\n\t\t\t} finally {\r\n\t\t\t\tvm.loading = false;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction navigate(result, index, e) {\r\n\t\t\tsdLogger.log(APP_SOURCE + '.navigate(): ', {\r\n\t\t\t\t'result': result,\r\n\t\t\t\t'index': index,\r\n\t\t\t});\r\n\t\t\t// ToDo: Look into moving this to the parent controller or the navigation service.\r\n\t\t\tvar urlToNavTo = getResultUrl(result);\r\n\t\t\t$location.path(urlToNavTo);\r\n\r\n\t\t\tsearchService.setClickedOnResultIndex(index);\r\n if (['navbar', 'hotkey', 'home', 'dashboard', 'quick-search-nub'].includes(navigationService.quickSearchInitiator)) {\r\n productAnalyticsService.logEvent('click-quick-search-result', { quickSearchResult: vm.criteria.resultType });\r\n navigationService.quickSearchInitiator = null;\r\n }\r\n\t\t\tcloseSearch();\r\n\r\n\t\t\tif (e) {\r\n\t\t\t\te.stopPropagation();\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction getResultUrl(result) {\r\n\t\t\tconst baseUrl = '/company/';\r\n\t\t\tswitch (vm.criteria.resultType) {\r\n\t\t\t\tcase 'parcel':\r\n\t\t\t\t\treturn baseUrl + result.companyID + '/site/' + result.siteID + '/parcel/' + result.parcelID;\r\n\t\t\t\tcase 'site':\r\n\t\t\t\t\treturn baseUrl + result.companyID + '/site/' + result.siteID;\r\n\t\t\t\tcase 'company':\r\n\t\t\t\t\treturn baseUrl + result.companyID;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction loadExtraFilters() {\r\n\t\t\tvar fieldsToReject = ['parcelPropType', 'parcelAcctNum'];\r\n\r\n\t\t\tvm.extraFilters = _.chain(vm.criteria.activeFilters)\r\n\t\t\t\t.filter('text')\r\n\t\t\t\t.reject('default')\r\n\t\t\t\t.reject(function (filter) {\r\n\t\t\t\t\treturn _.includes(fieldsToReject, filter.field);\r\n\t\t\t\t})\r\n\t\t\t\t.value();\r\n\t\t}\r\n\r\n\t\tfunction resetResults() {\r\n\t\t\tvm.results = [];\r\n\t\t}\r\n\r\n\t\tfunction refreshResults() {\r\n\t\t\tsdLogger.log('Trace Begin - ' + appSource + '.refreshResults()', {\r\n\t\t\t\t'vm': vm\r\n\t\t\t});\r\n\r\n\t\t\tvm.results = [];\r\n\t\t\tgetResults('refresh results').finally(newResults);\r\n\r\n\t\t\tsdLogger.log('Trace End - ' + appSource + '.refreshResults()', {\r\n\t\t\t\t'vm': vm\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction pgDn(e, index) {\r\n\t\t\tvar focused = index + 10;\r\n\t\t\tvar lastIndex = vm.results.length - 1;\r\n\r\n\t\t\tfocused = focused > lastIndex ? lastIndex : focused;\r\n\r\n\t\t\tsearchService.focusOnResult(focused)\r\n\t\t\te.preventDefault();\r\n\t\t}\r\n\r\n\t\tfunction pgUp(e, index) {\r\n\t\t\tvar focused = index - 10;\r\n\t\t\tfocused = focused < 0 ? 0 : focused;\r\n\r\n\t\t\tsearchService.focusOnResult(focused)\r\n\t\t\te.preventDefault();\r\n\t\t}\r\n\r\n\t\tfunction hoverIn(index) {\r\n\t\t\tsearchService.focusOnResult(index);\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:SearchResultInfinite\r\n * @description\r\n * # SearchResultInfinite\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Search.Quick.Result.Infinite'\r\n\tvar VIEW_TEMPLATE_URL = 'app/Search/Quick/_quickResultInfinite.html';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdSearchQuickResultInfinite', ResultDirective);\r\n\r\n\tResultDirective.$inject = ['sdLogger'];\r\n\r\n\tfunction ResultDirective(sdLogger) {\r\n\t\treturn {\r\n\t\t\trestrict: 'E',\r\n\t\t\treplace: true,\r\n\t\t\tscope: {},\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: 'sd.Search.Quick.Result.Infinite.Controller',\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: function (scope) {\r\n\t\t\t\tsdLogger.log(APP_SOURCE + '.link(): ', {\r\n\t\t\t\t\t'scope': scope\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\t};\r\n\t}\r\n})();\r\n","'use strict';\r\n\r\n/**\r\n * @ngdoc directive\r\n * @name weissmanApp.directive:searchResultParcel\r\n * @description\r\n * # searchResultParcel\r\n */\r\nangular.module('weissmanApp')\r\n\t.directive('searchResultParcel', ['$compile', 'sd.Property.Type.Service', function ($compile, propertyTypeService) {\r\n\t\treturn {\r\n\t\t\ttemplateUrl: 'app/Search/Quick/_quickResultParcel.html',\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tresult: '=',\r\n\t\t\t\tchildEntity: '=?'\r\n\t\t\t},\r\n\t\t\tlink: function postLink(scope, element, attrs) {\r\n\t\t\t\tvar propertyTypes;\r\n\t\t\t\tpropertyTypeService.get().then(function (types) {\r\n\t\t\t\t\tpropertyTypes = types;\r\n\r\n\t\t\t\t\tscope.getPropType = function (id) {\r\n\t\t\t\t\t\tif (!id) {\r\n\t\t\t\t\t\t\treturn;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\treturn _.find(propertyTypes, {\r\n\t\t\t\t\t\t\tpropertyTypeID: id\r\n\t\t\t\t\t\t}).propTypeAbbr;\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\r\n\t\t\t\tscope.acctNums = _.chain(scope.result)\r\n\t\t\t\t\t.pickBy(function (val, key) {\r\n\t\t\t\t\t\tvar keyArr = key.split('.');\r\n\t\t\t\t\t\treturn keyArr[0] === 'parcelAccountNumber' && val && keyArr[1][0] !== '!';\r\n\t\t\t\t\t})\r\n\t\t\t\t\t.map(function (val, key) {\r\n\t\t\t\t\t\tconsole.log(key)\r\n\t\t\t\t\t\treturn {\r\n\t\t\t\t\t\t\tlabel: key.substring(key.indexOf('.') + 1),\r\n\t\t\t\t\t\t\tnumber: val\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t})\r\n\t\t\t\t\t.value();\r\n\t\t\t}\r\n\t\t};\r\n\r\n\t\t//function getPropertyTypes() {\r\n\t\t//\treturn $http.get('/api/propertytype/').then(function (result) {\r\n\t\t//\t\treturn result.data;\r\n\t\t//\t})\r\n\t\t//}\r\n\t}]);\r\n","'use strict';\r\n\r\n/**\r\n * @ngdoc directive\r\n * @name weissmanApp.directive:searchResultSite\r\n * @description\r\n * # searchResultSite\r\n */\r\nangular.module('weissmanApp')\r\n\t.directive('searchResultSite', function () {\r\n\t\treturn {\r\n\t\t\ttemplateUrl: 'app/Search/Quick/_quickResultSite.html',\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tresult: '='\r\n\t\t\t},\r\n\t\t\tlink: function postLink(scope, element, attrs) {}\r\n\t\t};\r\n\t});\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('actionListOutput', actionListOutput);\r\n\r\n\tactionListOutput.$inject = [];\r\n\r\n\tfunction actionListOutput() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Task/ActionView/_actionListOutput.html',\r\n\t\t\tscope: {\r\n\t\t\t\toutputColumns: '=',\r\n\t\t\t\treadOnly: '=',\r\n\t\t\t\ttaskSeriesTypeAdvancedSearchDepthValue: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n\r\n\tController.$inject = ['searchOperators', 'advancedSearchService'];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(searchOperators, advancedSearchService) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.addOutputs = addOutputs;\r\n\t\tvm.removeOutput = removeOutput;\r\n\t\tvm.columnMoved = columnMoved;\r\n\r\n\t\tfunction addOutputs(columns) {\r\n\t\t\tvar addedColumns = _.map(columns, function (column) {\r\n\t\t\t\tvar addedColumn = angular.copy(column);\r\n\r\n\t\t\t\taddedColumn.operators = searchOperators.getOperatorArray(addedColumn.operators)\r\n\r\n if(column.columnId === 101 || column.columnId === 109) {\r\n addedColumn.or = [searchOperators.getCompanyOr(addedColumn.operators)];\r\n } else {\r\n addedColumn.or = [searchOperators.getOr(addedColumn.operators)];\r\n }\r\n\r\n\t\t\t\treturn addedColumn;\r\n\t\t\t});\r\n\r\n\t\t\tvm.outputColumns.push.apply(vm.outputColumns, addedColumns);\r\n\r\n\t\t\tsetSequence();\r\n\r\n\t\t\tadvancedSearchService.disableColumns(vm.outputColumns, false, vm.taskSeriesTypeAdvancedSearchDepthValue)\r\n\t\t}\r\n\r\n\t\tfunction removeOutput(column) {\r\n\t\t\t_.remove(vm.outputColumns, column);\r\n\r\n\t\t\tsetSequence();\r\n\t\t\tadvancedSearchService.disableColumns(vm.outputColumns, false, vm.taskSeriesTypeAdvancedSearchDepthValue);\r\n\t\t}\r\n\r\n\t\tfunction columnMoved(index) {\r\n\t\t\tvm.outputColumns.splice(index, 1);\r\n\t\t\tsetSequence();\r\n\t\t}\r\n\r\n\t\tfunction setSequence() {\r\n\t\t\tvm.outputColumns = _.map(vm.outputColumns, function (column, i) {\r\n\t\t\t\tcolumn.sequence = i;\r\n\t\t\t\tcolumn.showClose = false;\r\n\t\t\t\treturn column;\r\n\t\t\t})\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:actionViewOverview\r\n * @description\r\n * # Stand alone widget for Action View Overview panel\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar VIEW_TEMPLATE_URL = 'app/Task/ActionView/_actionOverview.html';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('actionViewOverview', Directive);\r\n\r\n\r\n\tDirective.$inject = [\r\n 'actionViewService',\r\n 'ActionViewGroupByTypes',\r\n '$stateParams',\r\n 'ActionViewCategoryTypes',\r\n 'actionViewPersistenceService',\r\n 'advancedSearchService',\r\n 'ActionViewOrganizeByTypes',\r\n '$timeout'\r\n\t];\r\n\r\n\tfunction Directive(actionViewService, ActionViewGroupByTypes, $stateParams, ActionViewCategoryTypes, actionViewPersistenceService, advancedSearchService, ActionViewOrganizeByTypes, $timeout) {\r\n\t\tvar directive = {\r\n restrict: 'E',\r\n replace: true,\r\n templateUrl: VIEW_TEMPLATE_URL,\r\n scope: {\r\n searchFilter: '=searchFilter',\r\n organizeBy: '=organizeBy',\r\n drilldownFilter: '=drilldownFilter',\r\n drilldownMode: '=drilldownMode',\r\n showDetail: '=showDetail',\r\n showOverview: '=showOverview',\r\n groupBy: '=groupBy',\r\n taskAssignmentApi: '=taskAssignmentApi',\r\n showMostPressing: '=showMostPressing',\r\n pageLoading: '=pageLoading'\r\n },\r\n link: function (scope) {\r\n var allFields;\r\n\r\n scope.taskData = null;\r\n\r\n scope.originalSearchFilter = angular.copy(scope.searchFilter);\r\n scope.filterChanged = false;\r\n scope.getTableData = getTableData;\r\n scope.getColumnStyleClass = getColumnStyleClass;\r\n scope.getTableSpacingClass = getTableSpacingClass;\r\n scope.drilldownCellNoGroup = drilldownCellNoGroup;\r\n //to control the style of the table\r\n scope.tableType = 1;\r\n scope.filterChanged = false;\r\n\r\n if (actionViewPersistenceService.externalDrilldown) {\r\n scope.drilldownFilter = angular.copy(actionViewPersistenceService.drilldownFilter);\r\n\r\n //Hardcoding to urgency for now but we can expand this later to be dynamic\r\n scope.organizeBy = 1;\r\n scope.searchFilter = angular.copy(actionViewPersistenceService.masterFilter);\r\n scope.newFilter = angular.copy(actionViewPersistenceService.drilldownFilter);\r\n $timeout(function() {\r\n scope.taskAssignmentApi.resolveTasksAndFieldsDeferred.then(function() {\r\n scope.drilldownCellNoGroup(actionViewPersistenceService.externalDrilldownData.task,\r\n actionViewPersistenceService.externalDrilldownData.item,\r\n actionViewPersistenceService.externalDrilldownData.ready);\r\n\r\n });\r\n\r\n // Needed to load filter panel on filter page when coming from dashboard\r\n scope.taskAssignmentApi.taskTypeChanged();\r\n });\r\n } else {\r\n\r\n if (actionViewPersistenceService.masterFilter) {\r\n scope.searchFilter = angular.copy(actionViewPersistenceService.masterFilter);\r\n }\r\n\r\n scope.newFilter = angular.copy(scope.searchFilter);\r\n\r\n advancedSearchService.getAllFields()\r\n .then(function (result) {\r\n allFields = result;\r\n });\r\n\r\n if (!actionViewPersistenceService.overviewResults) {\r\n if (scope.searchFilter) {\r\n getTableData();\r\n } else {\r\n var actionViewId = parseInt($stateParams.actionViewId);\r\n var isSystemView = parseInt($stateParams.actionViewType) === ActionViewCategoryTypes.SYSTEM;\r\n\r\n if (isSystemView) {\r\n actionViewService.getSystemActionViewById(actionViewId)\r\n .then(function (response) {\r\n setupResponseData(response);\r\n });\r\n } else {\r\n actionViewService.getCustomActionViewById(actionViewId)\r\n .then(function (response) {\r\n setupResponseData(response);\r\n });\r\n }\r\n }\r\n } else {\r\n scope.taskData = actionViewPersistenceService.overviewResults;\r\n\r\n scope.searchFilter = actionViewPersistenceService.masterFilter;\r\n\r\n scope.tableType = scope.searchFilter.OrganizeBy;\r\n scope.headerNames = actionViewPersistenceService.overviewHeaders;\r\n scope.groupByCount = actionViewPersistenceService.groupByCount;\r\n scope.organizeTotals = actionViewPersistenceService.organizeTotals;\r\n scope.grandTotals - actionViewPersistenceService.grandTotals\r\n\r\n scope.drilldownMode = false;\r\n\r\n //This $timeout is so the loading image goes away when the DOM is loaded, which takes some time\r\n $timeout(function () {\r\n scope.pageLoading = false;\r\n }, 1);\r\n\r\n if (_.isEmpty(scope.drilldownFilter)) {\r\n scope.drilldownFilter = actionViewPersistenceService.drilldownFilter;\r\n }\r\n }\r\n }\r\n\r\n function getTableData() {\r\n scope.searchFilter = angular.copy(scope.newFilter);\r\n setGroupByFromMostPressingTasks(scope.searchFilter);\r\n scope.pageLoading = true;\r\n scope.searchFilter.DetailedResults = false;\r\n actionViewService.executeActionView(scope.searchFilter).then(function (results) {\r\n scope.filterChanged = false;\r\n\r\n // please do not remove this console output,Grant is using it\r\n //\r\n console.info([\"ActionView Overview Search results:\", results]);\r\n console.info([\"ActionView Overview Search result sql:\", results.sql]);\r\n\r\n var groupedTasks = [],\r\n orderedHeaders = {};\r\n scope.headerNames = [];\r\n scope.groupByCount = 0;\r\n\r\n var resultsDataTable;\r\n resultsDataTable = results.group1ResultList;\r\n\r\n if (!resultsDataTable.length) {\r\n scope.pageLoading = false;\r\n return\r\n }\r\n\r\n scope.tableType = scope.searchFilter.OrganizeBy;\r\n\r\n scope.organizeTotals = [];\r\n\r\n // Get Column Totals\r\n _.forEach(resultsDataTable, function(task) {\r\n _.forEach(task.data, function(item) {\r\n var orgLabelIdx = _.findIndex(scope.organizeTotals, {label: item.label});\r\n\r\n if(orgLabelIdx < 0) {\r\n scope.organizeTotals.push({label: item.label, value: 0, ready: 0, notReady: 0, sequence: item.sequence});\r\n orgLabelIdx = scope.organizeTotals.length - 1;\r\n }\r\n\r\n scope.organizeTotals[orgLabelIdx].value += item.value;\r\n scope.organizeTotals[orgLabelIdx].ready += item.ready;\r\n scope.organizeTotals[orgLabelIdx].notReady += item.notReady;\r\n })\r\n });\r\n\r\n // Get Row Totals\r\n resultsDataTable = _.map(resultsDataTable, function(task) {\r\n task.totals = {\r\n value: 0,\r\n ready: 0,\r\n notReady: 0\r\n }\r\n\r\n _.forEach(task.totals, function(value, key) {\r\n task.totals[key] = _.reduce(task.data, function(sum, item) {\r\n return sum + item[key];\r\n }, 0)\r\n });\r\n\r\n return task;\r\n });\r\n\r\n // Get Grand Total\r\n scope.grandTotals = {\r\n value: 0,\r\n ready: 0,\r\n notReady: 0\r\n }\r\n\r\n _.forEach(scope.grandTotals, function(value, key) {\r\n scope.grandTotals[key] = _.reduce(scope.organizeTotals, function(sum, item) {\r\n return sum + item[key];\r\n }, 0)\r\n });\r\n\r\n //If no user grouping\r\n if (!scope.searchFilter.GroupBy || scope.searchFilter.GroupBy.length === 0) {\r\n scope.groupByCount = 0;\r\n groupedTasks = resultsDataTable;\r\n }\r\n\r\n //if there are user groupings\r\n else if (scope.searchFilter.GroupBy.length >= 1) {\r\n scope.groupByCount = scope.searchFilter.GroupBy.length;\r\n\r\n //first group by task category\r\n groupedTasks = _.groupBy(resultsDataTable, 'taskSeriesTypeName');\r\n console.log(groupedTasks)\r\n\r\n //next group by the first grouping\r\n _.forOwn(groupedTasks, function (value, key) {\r\n var secondaryGrouping = _.groupBy(value, 'firstGroup.value');\r\n groupedTasks[key] = secondaryGrouping;\r\n\r\n if (scope.groupByCount === 2) {\r\n _.forOwn(groupedTasks[key], function (secondaryValue, secondaryKey) {\r\n var thirdGrouping = _.groupBy(secondaryValue, 'secondGroup.value');\r\n groupedTasks[key][secondaryKey] = thirdGrouping;\r\n });\r\n }\r\n });\r\n\r\n }\r\n\r\n //get header names by sequence\r\n orderedHeaders = resultsDataTable[0].data;\r\n _.sortBy(orderedHeaders, 'sequence');\r\n _.forEach(orderedHeaders, function (value) {\r\n scope.headerNames.push(value.label)\r\n });\r\n\r\n scope.taskData = groupedTasks;\r\n console.log(_.cloneDeep(scope.taskData))\r\n scope.pageLoading = false;\r\n scope.originalSearchFilter = angular.copy(scope.searchFilter);\r\n scope.filterChanged = false;\r\n }, function (reject) {\r\n if (reject !== \"Cancelled\") {\r\n console.log(['ActionView search - Failure', reject]);\r\n // error handler\r\n if (reject.status === 0) {\r\n // $http timeout\r\n console.log('ActionView search - Failure - $http timeout');\r\n } else {\r\n // response error status from server\r\n console.log('ActionView search - Failure ');\r\n scope.pageLoading = false;\r\n //scope.filterChanged = true;\r\n //showFilter()\r\n }\r\n }\r\n });\r\n }\r\n\r\n function setupResponseData(response) {\r\n var newCriteria = JSON.parse(response.criteria);\r\n scope.searchFilter = newCriteria.masterFilter;\r\n scope.originalSearchFilter = angular.copy(scope.searchFilter);\r\n scope.drilldownFilter = angular.copy(scope.searchFilter);\r\n getTableData();\r\n }\r\n\r\n function getTableSpacingClass() {\r\n if (scope.groupByCount >= 2) {\r\n return 'task-table-grouping';\r\n } else {\r\n return '';\r\n }\r\n }\r\n\r\n function getColumnStyleClass(columnSequence) {\r\n if (Number(scope.tableType) === 1) {\r\n switch (columnSequence) {\r\n case 0:\r\n return 'urgency-overdue';\r\n case 1:\r\n return 'urgency-critical';\r\n case 2:\r\n return 'urgency-imminent';\r\n case 3:\r\n return 'urgency-approaching';\r\n case 4:\r\n return 'urgency-prospective';\r\n default:\r\n return '';\r\n }\r\n } else if (Number(scope.tableType) === 2) {\r\n if (columnSequence === 0) {\r\n return 'urgency-overdue';\r\n } else {\r\n return 'misc-background';\r\n }\r\n } else {\r\n return 'misc-background';\r\n }\r\n }\r\n\r\n scope.$watch('organizeBy', function () {\r\n if (scope.newFilter) {\r\n scope.newFilter.OrganizeBy = scope.organizeBy;\r\n scope.filterChanged = true;\r\n }\r\n }, true);\r\n\r\n scope.$on('actionViewFilterChanged', function (event, mostPressing, readyOrNotReady, showTotals) {\r\n if (scope.newFilter) {\r\n scope.newFilter.ShowMostPressingTasks = mostPressing;\r\n scope.showMostPressing = mostPressing;\r\n scope.newFilter.CalculateReadyAndNotReady = readyOrNotReady;\r\n scope.newFilter.showTotals = showTotals;\r\n setGroupByFromMostPressingTasks(scope.newFilter);\r\n scope.filterChanged = true;\r\n }\r\n });\r\n\r\n scope.$watch('groupBy', function () {\r\n if (scope.newFilter) {\r\n setGroupByFromMostPressingTasks(scope.newFilter);\r\n }\r\n scope.filterChanged = true;\r\n }, true);\r\n\r\n function setGroupByFromMostPressingTasks(filter) {\r\n filter.GroupBy = [];\r\n filter.OrganizeBy = scope.organizeBy;\r\n if (!scope.showMostPressing) {\r\n filter.GroupBy[0] = ActionViewGroupByTypes.TASKTYPE.id;\r\n }\r\n if (scope.groupBy) {\r\n filter.GroupBy.push(scope.groupBy);\r\n }\r\n if (filter.GroupBy.length === 0) {\r\n filter.GroupBy = null;\r\n }\r\n }\r\n\r\n scope.drilldownColumn = function (header, list, twoGroups) {\r\n setFilterFromOrganizeBy(header);\r\n\r\n if (list) {\r\n var taskSeries = _.values(list)[0][0];\r\n\r\n if (twoGroups) {\r\n setTask(taskSeries.taskSeriesTypeID, Number(taskSeries.firstGroup.id))\r\n } else {\r\n setTask(taskSeries.taskSeriesTypeID, 0);\r\n }\r\n }\r\n\r\n loadDetailView();\r\n }\r\n\r\n scope.drilldownColumnTotal = function(header, readiness) {\r\n setFilterFromOrganizeBy(header);\r\n\r\n if(readiness) {\r\n setReadiness(readiness);\r\n }\r\n\r\n loadDetailView();\r\n }\r\n\r\n scope.drilldownTaskSeriesType = function (list) {\r\n var taskSeries;\r\n\r\n if (scope.groupByCount === 1) {\r\n taskSeries = _.values(list)[0][0];\r\n } else {\r\n taskSeries = _.values(_.values(list)[0])[0][0];\r\n }\r\n\r\n setTask(taskSeries.taskSeriesTypeID, 0);\r\n\r\n loadDetailView();\r\n }\r\n\r\n scope.drilldownRowNoGroup = function (taskSeries, readiness) {\r\n setTask(taskSeries.taskSeriesTypeID, taskSeries.taskTypeID);\r\n\r\n if(readiness) {\r\n setReadiness(readiness);\r\n }\r\n\r\n loadDetailView();\r\n }\r\n\r\n //loaded into scope earlier as it's used by the external drilldown\r\n function drilldownCellNoGroup(taskSeries, item, readiness) {\r\n setTask(taskSeries.taskSeriesTypeID, taskSeries.taskTypeID);\r\n setFilterFromOrganizeBy(item.label);\r\n setReadiness(readiness);\r\n\r\n loadDetailView();\r\n }\r\n\r\n scope.drilldownRowOneGroup = function (taskSeries, readiness) {\r\n setTaskOrEntity(taskSeries);\r\n\r\n if(readiness) {\r\n setReadiness(readiness);\r\n }\r\n\r\n loadDetailView();\r\n }\r\n\r\n scope.drilldownCellOneGroup = function (taskSeries, item, readiness) {\r\n\r\n setTaskOrEntity(taskSeries);\r\n setFilterFromOrganizeBy(item.label);\r\n setReadiness(readiness);\r\n\r\n loadDetailView();\r\n }\r\n\r\n scope.drilldownRowFirstGroup = function (taskSeries) {\r\n setTask(taskSeries.taskSeriesTypeID, Number(taskSeries.firstGroup.id))\r\n\r\n loadDetailView();\r\n }\r\n\r\n scope.drilldownRowSecondGroup = function (taskSeries, readiness) {\r\n setTask(taskSeries.taskSeriesTypeID, Number(taskSeries.firstGroup.id))\r\n setFilterFromGroupBy(taskSeries.secondGroup);\r\n\r\n if(readiness) {\r\n setReadiness(readiness);\r\n }\r\n\r\n loadDetailView();\r\n }\r\n\r\n scope.drilldownCellTwoGroups = function (taskSeries, item, readiness) {\r\n setTask(taskSeries.taskSeriesTypeID, Number(taskSeries.firstGroup.id))\r\n setFilterFromGroupBy(taskSeries.secondGroup);\r\n setFilterFromOrganizeBy(item.label);\r\n setReadiness(readiness);\r\n\r\n loadDetailView();\r\n }\r\n\r\n scope.drilldownGrandTotal = function(readiness) {\r\n if(readiness) {\r\n setReadiness(readiness);\r\n }\r\n\r\n loadDetailView();\r\n }\r\n\r\n function setReadiness(readiness) {\r\n if (readiness === 'ready') {\r\n scope.drilldownFilter.ThatAreChoice = 1;\r\n scope.drilldownFilter.mostPressingNotReadyOnly = false;\r\n }\r\n if (readiness === 'not ready') {\r\n scope.drilldownFilter.ThatAreChoice = 2;\r\n scope.drilldownFilter.mostPressingNotReadyOnly = true;\r\n }\r\n }\r\n\r\n function setTask(taskSeriesTypeID, taskTypeID) {\r\n scope.drilldownFilter.taskSeriesTypeID = taskSeriesTypeID;\r\n\r\n if (taskTypeID !== 0) {\r\n scope.drilldownFilter.taskTypeID = taskTypeID;\r\n }\r\n\r\n if (!scope.drilldownFilter.persistCustomColumns) {\r\n var separatedColumns = scope.taskAssignmentApi.setOutputs(taskSeriesTypeID, taskTypeID);\r\n\r\n separatedColumns.TaskOutputColumns = _.map(separatedColumns.TaskOutputColumns, actionViewService.prepareOutputColumn)\r\n separatedColumns.EntityOutputColumns = _.map(separatedColumns.EntityOutputColumns, actionViewService.prepareOutputColumn)\r\n\r\n _.assign(scope.drilldownFilter, separatedColumns);\r\n }\r\n }\r\n\r\n function setTaskOrEntity(taskSeries) {\r\n if (scope.searchFilter.ShowMostPressingTasks) {\r\n setTask(taskSeries.taskSeriesTypeID, taskSeries.taskTypeID);\r\n setFilterFromGroupBy(taskSeries.firstGroup)\r\n } else {\r\n setTask(taskSeries.taskSeriesTypeID, Number(taskSeries.firstGroup.id))\r\n }\r\n }\r\n\r\n scope.columnSelected = function (name) {\r\n switch (Number(scope.tableType)) {\r\n case ActionViewOrganizeByTypes.URGENCY:\r\n var urgencyChoice = actionViewService.getUrgencyChoiceByHeaderName(name);\r\n return !scope.searchFilter.UrgencyChoice || urgencyChoice === scope.searchFilter.UrgencyChoice;\r\n\r\n case ActionViewOrganizeByTypes.DUEDATE:\r\n var drilldownDueDates = getDrilldownDueDates(name);\r\n return drilldownDueDates.DueDateFrom <= drilldownDueDates.DueDateTo;\r\n\r\n case ActionViewOrganizeByTypes.LASTACTIVITYDATE:\r\n var drilldownLastActivity = getDrilldownLastActivity(name);\r\n return drilldownLastActivity.LastActivityFrom <= drilldownLastActivity.LastActivityTo || drilldownLastActivity.LastActivityTo === undefined;\r\n\r\n default:\r\n return true;\r\n }\r\n }\r\n\r\n function setFilterFromGroupBy(group) {\r\n switch (scope.groupBy) {\r\n case undefined: //task type\r\n //setTask(group);\r\n break;\r\n\r\n case ActionViewGroupByTypes.ASSIGNEENAME.id: // assignee name\r\n scope.drilldownFilter.ShowChoice = 4;\r\n\r\n // https://weissmandemo.atlassian.net/browse/WK-2649\r\n if (scope.searchFilter.WhereChoice === 2) {\r\n scope.drilldownFilter.AdditionalWhereFilters = [{\r\n whereChoice: 2,\r\n userTeams: [_.omit(scope.searchFilter.ShowUserTeams[0], 'user')]\r\n }];\r\n }\r\n\r\n //Bug fix. Grant says the drilldown should include all teams in the filter with the user ID clicked\r\n if (scope.searchFilter.ShowTeams && scope.searchFilter.ShowTeams.length > 0) {\r\n scope.drilldownFilter.ShowUserTeams = [];\r\n _.forEach(scope.searchFilter.ShowTeams, function (team) {\r\n scope.drilldownFilter.ShowUserTeams.push({\r\n userID: group.id,\r\n name: group.value,\r\n teamID: team.teamID\r\n })\r\n });\r\n } else {\r\n scope.drilldownFilter.ShowUserTeams = [{userID: group.id, name: group.value}]\r\n }\r\n scope.drilldownFilter.WhereChoice = 1;\r\n\r\n break;\r\n\r\n case ActionViewGroupByTypes.ASSIGNEETEAM.id: // assignee team\r\n scope.drilldownFilter.ShowChoice = 5;\r\n scope.drilldownFilter.ShowTeams = [{teamID: group.id, name: group.value}];\r\n scope.drilldownFilter.WhereChoice = scope.drilldownFilter.WhereChoice || 1;\r\n break;\r\n\r\n case ActionViewGroupByTypes.RESPONSIBLENAME.id: // responsible name\r\n scope.drilldownFilter.ShowChoice = 4;\r\n scope.drilldownFilter.ShowUserTeams = [{userID: group.id, name: group.value}]\r\n scope.drilldownFilter.WhereChoice = scope.drilldownFilter.WhereChoice || 1;\r\n break;\r\n\r\n case ActionViewGroupByTypes.RESPONSIBLETEAM.id: // responsible team\r\n scope.drilldownFilter.ShowChoice = 5;\r\n scope.drilldownFilter.ShowTeams = [{teamID: group.id, name: group.value}];\r\n scope.drilldownFilter.WhereChoice = scope.drilldownFilter.WhereChoice || 1;\r\n break;\r\n\r\n default:\r\n scope.drilldownFilter.filters = _.reject(scope.drilldownFilter.filters, {columnId: scope.groupBy});\r\n\r\n var orObject = [{\r\n operator: 'equal',\r\n value: group.value\r\n }];\r\n\r\n if (!group.value) {\r\n orObject[0].operator = 'blank'\r\n }\r\n\r\n scope.drilldownFilter.filters.push({\r\n columnId: scope.groupBy,\r\n resultColumnName: _.find(allFields, {'advancedSearchFieldID': Number(scope.groupBy)}).resultsColumnName,\r\n or: orObject\r\n });\r\n\r\n break;\r\n }\r\n }\r\n\r\n function setFilterFromOrganizeBy(header) {\r\n switch (Number(scope.organizeBy)) {\r\n case 1:\r\n //urgency\r\n scope.drilldownFilter.UseUrgencyFilter = true; //Set to Urgency\r\n scope.drilldownFilter.UrgencyChoice = actionViewService.getUrgencyChoiceByHeaderName(header);\r\n\r\n break;\r\n case 2:\r\n // due date\r\n if (header === 'Unscheduled') {\r\n scope.drilldownFilter.OnlyUnscheduled = true;\r\n } else {\r\n scope.drilldownFilter.DateTimeChoice = 3; // Due dates\r\n scope.drilldownFilter.IncludeUnscheduled = false;\r\n\r\n var drilldownDates = getDrilldownDueDates(header);\r\n _.assign(scope.drilldownFilter, drilldownDates);\r\n }\r\n\r\n break;\r\n case 3:\r\n //last action hero\r\n\r\n var drilldownLastActivity = getDrilldownLastActivity(header);\r\n\r\n scope.drilldownFilter.UseLastActivityFilter = true;\r\n _.assign(scope.drilldownFilter, drilldownLastActivity);\r\n\r\n break;\r\n default:\r\n console.log('Failure');\r\n }\r\n }\r\n\r\n\r\n function getDrilldownDueDates(header) {\r\n var headerDueDates = calcHeaderDueDates(header);\r\n\r\n if (scope.searchFilter.DateTimeChoice === 2) {\r\n var now = new Date();\r\n\r\n var dueWithinDate = moment(new Date()).add(scope.searchFilter.DueWithinDays, 'days')\r\n .startOf('day')\r\n .subtract(now.getTimezoneOffset(), 'minutes')\r\n .toDate();\r\n\r\n return {\r\n DueDateFrom: headerDueDates.DueDateFrom,\r\n DueDateTo: new Date(Math.min(headerDueDates.DueDateTo, dueWithinDate))\r\n };\r\n } else if (scope.searchFilter.DateTimeChoice === 3) {\r\n return {\r\n DueDateFrom: new Date(Math.max(headerDueDates.DueDateFrom, scope.searchFilter.DueDateFrom)),\r\n DueDateTo: new Date(Math.min(headerDueDates.DueDateTo, scope.searchFilter.DueDateTo))\r\n }\r\n } else {\r\n return headerDueDates;\r\n }\r\n }\r\n\r\n function calcHeaderDueDates(header) {\r\n var now = new Date()\r\n\r\n switch (header) {\r\n case 'Overdue':\r\n var dateToNoOffset = moment(now).subtract(1, 'days')\r\n .toDate();\r\n\r\n return {\r\n DueDateFrom: moment('1970-01-01').toDate(),\r\n DueDateTo: moment(now).subtract(1, 'days')\r\n .subtract(dateToNoOffset.getTimezoneOffset(), 'minutes')\r\n .toDate()\r\n }\r\n case 'Due Today':\r\n var todayNoOffset = moment(now).startOf('day')\r\n .toDate();\r\n\r\n return {\r\n DueDateFrom: moment(now).startOf('day')\r\n .subtract(todayNoOffset.getTimezoneOffset(), 'minutes')\r\n .toDate(),\r\n DueDateTo: moment(now).startOf('day')\r\n .subtract(todayNoOffset.getTimezoneOffset(), 'minutes')\r\n .toDate()\r\n }\r\n default:\r\n var dateFromNoOffset, dateToNoOffset;\r\n\r\n if (_.includes(header, '+')) {\r\n var plusDate = header.split('+')[0];\r\n\r\n dateFromNoOffset = moment(now).add(plusDate, 'days')\r\n .startOf('day')\r\n .toDate();\r\n dateToNoOffset = moment(now).add(30, 'years')\r\n .startOf('day')\r\n .toDate();\r\n\r\n return {\r\n DueDateFrom: moment(now).add(plusDate, 'days')\r\n .startOf('day')\r\n .subtract(dateFromNoOffset.getTimezoneOffset(), 'minutes')\r\n .toDate(),\r\n DueDateTo: moment(now).add(30, 'years')\r\n .startOf('day')\r\n .subtract(dateToNoOffset.getTimezoneOffset(), 'minutes')\r\n .toDate()\r\n }\r\n }\r\n\r\n var fromDate = header.split(' ')[0].split('-')[0]\r\n var toDate = header.split(' ')[0].split('-')[1];\r\n\r\n dateFromNoOffset = moment(now).add(fromDate, 'days')\r\n .startOf('day')\r\n .toDate();\r\n dateToNoOffset = moment(now).add(toDate, 'days')\r\n .startOf('day')\r\n .toDate();\r\n\r\n return {\r\n DueDateFrom: moment(now).add(fromDate, 'days')\r\n .startOf('day')\r\n .subtract(dateFromNoOffset.getTimezoneOffset(), 'minutes')\r\n .toDate(),\r\n DueDateTo: moment(now).add(toDate, 'days')\r\n .startOf('day')\r\n .subtract(dateToNoOffset.getTimezoneOffset(), 'minutes')\r\n .toDate()\r\n }\r\n }\r\n }\r\n\r\n function getDrilldownLastActivity(header) {\r\n var headerLastActivity = calcHeaderLastActivity(header);\r\n\r\n if (scope.searchFilter.UseLastActivityFilter) {\r\n return {\r\n LastActivityFrom: Math.max(headerLastActivity.LastActivityFrom, scope.searchFilter.LastActivityFrom),\r\n LastActivityTo: Math.min(headerLastActivity.LastActivityTo, scope.searchFilter.LastActivityTo || 9999)\r\n }\r\n } else {\r\n return headerLastActivity;\r\n }\r\n }\r\n\r\n function calcHeaderLastActivity(header) {\r\n switch (header) {\r\n case 'Today':\r\n return {\r\n LastActivityFrom: 0,\r\n LastActivityTo: 0\r\n };\r\n case '1 Day':\r\n return {\r\n LastActivityFrom: 1,\r\n LastActivityTo: 1\r\n };\r\n\r\n case '2 Days':\r\n return {\r\n LastActivityFrom: 2,\r\n LastActivityTo: 2\r\n }\r\n\r\n case '31+ Days':\r\n return {\r\n LastActivityFrom: 31,\r\n LastActivityTo: 9999\r\n };\r\n\r\n default:\r\n var fromDays = header.split(' ')[0].split('-')[0]\r\n var toDays = header.split(' ')[0].split('-')[1];\r\n\r\n return {\r\n LastActivityFrom: Number(fromDays),\r\n LastActivityTo: Number(toDays)\r\n };\r\n }\r\n }\r\n\r\n function loadDetailView() {\r\n //means we've come back to overview from a previous drilldown\r\n if (!scope.drilldownFilter) {\r\n scope.drilldownFilter = actionViewPersistenceService.drilldownFilter;\r\n }\r\n\r\n scope.drilldownFilter.OrganizeBy = scope.searchFilter.OrganizeBy;\r\n scope.drilldownFilter.filters = _.map(scope.drilldownFilter.filters, function (filter) {\r\n filter.resultColumnName = filter.resultColumnName || _.find(allFields, {'advancedSearchFieldID': filter.columnId}).resultsColumnName;\r\n\r\n return filter;\r\n });\r\n\r\n scope.drilldownFilter.DetailedResults = true;\r\n\r\n actionViewPersistenceService.overviewResults = angular.copy(scope.taskData);\r\n actionViewPersistenceService.groupByCount = angular.copy(scope.groupByCount);\r\n actionViewPersistenceService.overviewHeaders = angular.copy(scope.headerNames);\r\n actionViewPersistenceService.drilldownFilter = angular.copy(scope.drilldownFilter);\r\n actionViewPersistenceService.masterFilter = angular.copy(scope.searchFilter);\r\n actionViewPersistenceService.organizeTotals = angular.copy(scope.organizeTotals);\r\n actionViewPersistenceService.grandTotals = angular.copy(scope.grandTotals)\r\n actionViewPersistenceService.drilldownMode = true;\r\n\r\n scope.drilldownMode = true;\r\n scope.showOverview = false;\r\n scope.showDetail = true;\r\n }\r\n\r\n }\r\n\r\n\r\n }\r\n\r\n\t\treturn directive;\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.service('actionViewPersistenceService', actionViewPersistenceService);\r\n\r\n\tfunction actionViewPersistenceService() {\r\n\t\tvar self = this;\r\n\t\tself.routeParams = {};\r\n\t\tself.filterColumns = {};\r\n\t\tself.outputColumns = [];\r\n\t\tself.detailResults = null;\r\n\t\tself.overviewResults = null;\r\n\t\tself.overviewHeaders = [];\r\n\t\tself.drilldownMode = false;\r\n\t\tself.resultsChanged = false;\r\n\t\tself.selectedResult = {};\r\n\t\tself.actionViewType = null;\r\n\t\tself.actionViewName = '';\r\n\t\tself.masterFilter = null;\r\n\t\tself.drilldownFilter = null;\r\n\t\tself.showOrs = false;\r\n\t\tself.organizeBySelection = 0;\r\n\t\tself.groupByCount = 0;\r\n\t\tself.sort = {};\r\n\t\tself.externalDrilldown = false;\r\n\t\tself.externalDrilldownData = null;\r\n\t\tself.filter = null;\r\n\t\tself.columnState = null;\r\n\t\tself.organizeTotals = null;\r\n\t\tself.grandTotals = null;\r\n\r\n\t\tself.clearSavedData = function() {\r\n\t\t\tself.routeParams = {};\r\n\t\t\tself.filterColumns = {};\r\n\t\t\tself.outputColumns = [];\r\n\t\t\tself.detailResults = null;\r\n\t\t\tself.overviewResults = null;\r\n\t\t\tself.overviewHeaders = [];\r\n\t\t\tself.drilldownMode = false;\r\n\t\t\tself.resultsChanged = false;\r\n\t\t\tself.selectedResult = {};\r\n\t\t\tself.actionViewType = null;\r\n\t\t\tself.actionViewName = '';\r\n\t\t\tself.masterFilter = null;\r\n\t\t\tself.drilldownFilter = null;\r\n\t\t\tself.showOrs = false;\r\n\t\t\tself.organizeBySelection = 0;\r\n\t\t\tself.groupByCount = 0;\r\n\t\t\tself.sort = {};\r\n\t\t\tself.externalDrilldown = false;\r\n\t\t\tself.externalDrilldownData = null;\r\n\t\t\tself.filter = null;\r\n\t\t\tself.columnState = null;\r\n\t\t\tself.organizeTotals = null;\r\n\t\t\tself.grandTotals = null;\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar SERVICE_URL = '/api/taskActionView/';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory('actionViewService', actionViewService);\r\n\r\n\tactionViewService.$inject = [\r\n\t\t'$q',\r\n\t\t'sd.Http.Service',\r\n\t\t'ActionViewCategoryTypes',\r\n\t\t'actionViewPersistenceService',\r\n\t\t'columnFilterService',\r\n\t\t'cacheManagerService',\r\n\t\t'SD.Restrict.Service',\r\n\t\t'TaskSeriesTypes',\r\n\t\t'$stateParams',\r\n\t\t'busyIndicatorService',\r\n\t\t'longRunningProcessRepository',\r\n\t\t'sd.Account.User.Service',\r\n\t\t'userInstanceService',\r\n\t\t'RyanInstanceId',\r\n\t\t'advancedSearchService',\r\n\t\t'sd.Account.User.Settings.Service',\r\n 'snackBarService',\r\n\t\t'$uibModal'\r\n\t];\r\n\r\n\tfunction actionViewService($q, sdHttp, ActionViewCategoryTypes, actionViewPersistenceService, columnFilterService, cacheManagerService, restrictService, TaskSeriesTypes, $stateParams, busyIndicatorService, longRunningProcessRepository, userService, userInstanceService, RyanInstanceId, advancedSearchService, userSettingsService, snackBarService, $uibModal) {\r\n\t\tvar SERVICE_URL_CUSTOM_ACTION_VIEW = '/api/taskactionview/custom/';\r\n\t\tvar SERVICE_URL_SYSTEM_ACTION_VIEW = '/api/taskactionview/system/';\r\n\t\tvar SERVICE_URL_CATEGORIES = '/api/taskactionview/category/';\r\n\t\tvar SERVICE_URL_SYSTEM_CATEGORIES = '/api/taskactionview/category/system/';\r\n\t\tvar SERVICE_URL_CUSTOM_CATEGORIES = '/api/taskactionview/category/custom/';\r\n\t\tvar SERVICE_URL_FAVORITE = '/api/taskactionview/favorite/';\r\n\t\tvar SERVICE_URL_FAVORITE_CHECK = '/api/taskactionview/system/hasfavorite/';\r\n\t\tvar SERVICE_URL_FAVORITE_COUNT = '/api/taskactionview/system/favoritecount/';\r\n\t\tvar SERVICE_URL_ACTION_VIEW_SHARE = '/api/taskactionview/share/';\r\n\t\tvar SERVICE_URL_ACTION_VIEW_REVOKE_SHARE = '/api/taskactionview/revokeshare/';\r\n\r\n\t\tvar cacheManager = cacheManagerService.createCacheManager();\r\n\t\tcacheManager.registerKeyedStaticCache('taskTypes', {\r\n\t\t\tcacheKey: 'taskTypes',\r\n\t\t\tendpoint: SERVICE_URL + 'taskTypes',\r\n\t\t\tcacheDisabled: false\r\n\t\t});\r\n\r\n\t\tvar vm = this;\r\n\r\n\t\treturn {\r\n\t\t\tdeleteCustomActionView: deleteCustomActionView,\r\n\t\t\tdeleteSystemActionView: deleteSystemActionView,\r\n\t\t\tpatch: patch,\r\n\t\t\tgetCategories: getCategories,\r\n\t\t\tdeleteCategory: deleteCategory,\r\n\t\t\tcreateCategory: createCategory,\r\n\t\t\tchangeCategory: changeCategory,\r\n\t\t\treorder: reorder,\r\n\t\t\ttoggleFavorite: toggleFavorite,\r\n\t\t\thasFavorites: hasFavorites,\r\n\t\t\tgetTaskTypes: getTaskTypes,\r\n\t\t\tgetTasksAssignmentReadyOptions: getTasksAssignmentReadyOptions,\r\n\t\t\tmapThatAreChoiceToDisplayValue: mapThatAreChoiceToDisplayValue,\r\n\t\t\tgetUrgencies: getUrgencies,\r\n\t\t\tcreateCustomActionView: createCustomActionView,\r\n\t\t\tcreateSystemActionView: createSystemActionView,\r\n\t\t\tupdateCustomActionView: updateCustomActionView,\r\n\t\t\tupdateSystemActionView: updateSystemActionView,\r\n\t\t\tgetCustomActionViewById: getCustomActionViewById,\r\n\t\t\tgetSystemActionViewById: getSystemActionViewById,\r\n executeActionView: executeActionView,\r\n fixAPISearchRequest: fixAPISearchRequest,\r\n processSearchResultPlusRequest: processSearchResultPlusRequest,\r\n welcomeSearch: welcomeSearch,\r\n\t\t\texecuteActionViewToExcel: executeActionViewToExcel,\r\n\t\t\tcancelAvSearch: cancelAvSearch,\r\n\t\t\tprepareActionViewForExecution: prepareActionViewForExecution,\r\n\t\t\tprepareOutputColumn: prepareOutputColumn,\r\n\t\t\tsortTaskTypes: sortTaskTypes,\r\n\t\t\tgetFavoriteCount: getFavoriteCount,\r\n\t\t\trevokeShare: revokeShare,\r\n\t\t\tshare: share,\r\n getUrgencyColumnStyleClass: getUrgencyColumnStyleClass,\r\n getUrgencyChoiceByHeaderName: getUrgencyChoiceByHeaderName,\r\n\t\t\tlaunchCustomOutputModal: launchCustomOutputModal\r\n\t\t}\r\n\r\n\t\tfunction getCategories() {\r\n\t\t\treturn sdHttp.get(SERVICE_URL_CATEGORIES);\r\n\t\t}\r\n\r\n\t\tfunction createCategory(category) {\r\n\t\t\treturn sdHttp.post(SERVICE_URL_CATEGORIES, category);\r\n\t\t}\r\n\r\n\t\tfunction changeCategory(actionViewItem, categoryId, actionViewType) {\r\n\t\t\tvar actionViewURL = '';\r\n\r\n\t\t\tif (actionViewType === ActionViewCategoryTypes.SYSTEM) {\r\n\t\t\t\tactionViewURL = SERVICE_URL_SYSTEM_ACTION_VIEW;\r\n\t\t\t} else if (actionViewType === ActionViewCategoryTypes.CUSTOM) {\r\n\t\t\t\tactionViewURL = SERVICE_URL_CUSTOM_ACTION_VIEW;\r\n\t\t\t}\r\n\r\n\t\t\tvar categoryItem = {\r\n\t\t\t\tactionViewID: actionViewItem.actionViewID,\r\n\t\t\t\tcategoryID: categoryId,\r\n\t\t\t\trowVersion: actionViewItem.rowVersion\r\n\t\t\t};\r\n\r\n\t\t\treturn sdHttp.patch(actionViewURL + actionViewItem.actionViewID, categoryItem)\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t\treturn result;\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction reorder(categoryList, actionViewType) {\r\n\t\t if (actionViewType !== ActionViewCategoryTypes.CUSTOM) {\r\n\t\t throw new Error('Invalid action view type for reordering (only allowed on custom searches)');\r\n\t\t }\r\n\t\t\treturn sdHttp.put(SERVICE_URL_CUSTOM_CATEGORIES + 'reorder', categoryList);\r\n\t\t}\r\n\r\n\t\tfunction deleteCustomActionView(actionView) {\r\n\t\t\treturn sdHttp.deleteByEntity(SERVICE_URL_CUSTOM_ACTION_VIEW, actionView);\r\n\t\t}\r\n\r\n\t\tfunction deleteSystemActionView(actionView) {\r\n\t\t\treturn sdHttp.deleteByEntity(SERVICE_URL_SYSTEM_ACTION_VIEW, actionView);\r\n\t\t}\r\n\r\n\t\tfunction updateCustomActionView(actionViewItem, filterColumns) {\r\n\t\t\tvar saveActionViewItem = prepareActionViewForSave(actionViewItem, filterColumns, true);\r\n\t\t\treturn sdHttp.put(SERVICE_URL_CUSTOM_ACTION_VIEW, actionViewItem);\r\n\t\t}\r\n\r\n\t\tfunction updateSystemActionView(actionViewItem, filterColumns) {\r\n\t\t\tvar saveActionViewItem = prepareActionViewForSave(actionViewItem, filterColumns, true);\r\n\t\t\treturn sdHttp.put(SERVICE_URL_SYSTEM_ACTION_VIEW, actionViewItem);\r\n\t\t}\r\n\r\n\t\tfunction patch(actionViewItem, actionViewType) {\r\n\t\t\tif (actionViewType === ActionViewCategoryTypes.SYSTEM) {\r\n\t\t\t\treturn sdHttp.patch(SERVICE_URL_SYSTEM_ACTION_VIEW + actionViewItem.actionViewID, actionViewItem);\r\n\t\t\t} else if (actionViewType === ActionViewCategoryTypes.CUSTOM) {\r\n\t\t\t\treturn sdHttp.patch(SERVICE_URL_CUSTOM_ACTION_VIEW + actionViewItem.actionViewID, actionViewItem);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction deleteCategory(category) {\r\n\t\t\treturn sdHttp.delete(SERVICE_URL_CATEGORIES + category.categoryId);\r\n\t\t}\r\n\r\n\t\tfunction createCustomActionView(actionViewItem, filterColumns) {\r\n\t\t\tvar saveActionViewItem = prepareActionViewForSave(actionViewItem, filterColumns, false);\r\n\t\t\treturn sdHttp.post(SERVICE_URL_CUSTOM_ACTION_VIEW, saveActionViewItem);\r\n\t\t}\r\n\r\n\t\tfunction createSystemActionView(actionViewItem, filterColumns) {\r\n\t\t\tvar saveActionViewItem = prepareActionViewForSave(actionViewItem, filterColumns, false);\r\n\t\t\treturn sdHttp.post(SERVICE_URL_SYSTEM_ACTION_VIEW, actionViewItem);\r\n\t\t}\r\n\r\n\t\tfunction toggleFavorite(actionViewId, toggleValue) {\r\n\t\t\tif (toggleValue) {\r\n\t\t\t\treturn sdHttp.post(SERVICE_URL_FAVORITE, { actionViewID: actionViewId });\r\n\t\t\t} else {\r\n\t\t\t\treturn sdHttp.delete(SERVICE_URL_FAVORITE + actionViewId);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction hasFavorites(actionViewItem) {\r\n\t\t\treturn sdHttp.get(SERVICE_URL_FAVORITE_CHECK + actionViewItem.actionViewID);\r\n\t\t}\r\n\r\n\t\tfunction getTaskTypes() {\r\n\t\t\treturn $q(function (resolve, reject) {\r\n\t\t\t\tcacheManager.keyedStaticGet('taskTypes').then(function (taskTypes) {\r\n\t\t\t\t\tvar isInRyanInstance = userInstanceService.getSelectedInstance().instanceId === RyanInstanceId;\r\n\t\t\t\t\tvar hasRyanPrivate = restrictService.isInRole(restrictService.Roles.RYANPRIVATEITEMSVIEW) || restrictService.isInRole(restrictService.Roles.RYANPRIVATEITEMSEDIT);\r\n\t\t\t\t\tvar hasInstancePrivatePermission = restrictService.hasAnyInstancePrivate();\r\n\r\n\t\t\t\t\ttaskTypes.taskTypes = _.chain(taskTypes.taskTypes)\r\n\t\t\t\t\t\t.filter(x => isInRyanInstance && hasRyanPrivate || x.taskSeriesTypeID !== TaskSeriesTypes.CLIENTINVOICE) // Invoice\r\n\t\t\t\t\t\t.filter(x => hasInstancePrivatePermission || x.taskSeriesTypeID !== TaskSeriesTypes.DOCUMENTINTAKE) // Document Intake\r\n\t\t\t\t\t\t.value();\r\n\r\n\t\t\t\t\tresolve(taskTypes);\r\n\r\n\t\t\t\t}).catch(function () {\r\n\t\t\t\t\treject.apply(this, arguments);\r\n\t\t\t\t});\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction getCustomActionViewById(id) {\r\n\t\t\treturn sdHttp.get(SERVICE_URL_CUSTOM_ACTION_VIEW + id);\r\n\t\t}\r\n\r\n\t\tfunction getSystemActionViewById(id) {\r\n\t\t\treturn sdHttp.get(SERVICE_URL_SYSTEM_ACTION_VIEW + id);\r\n\t\t}\r\n\r\n\t\tfunction executeActionView(filter) {\r\n\t\t\tvm.canceler = $q.defer();\r\n\t\t\tvar isCancelled = false;\r\n\t\t\tvm.canceler.promise.then(function () { isCancelled = true; });\r\n\r\n\t\t\tfilter.savedSearchID = $stateParams.actionViewId || null;\r\n\t\t\treturn $q(function (resolve, reject) {\r\n\t\t\t sdHttp.post(SERVICE_URL + 'search', filter, { timeout: vm.canceler.promise }).then(resolve, function () {\r\n\t\t\t // If the user cancelled, we want code that called executeActionView to be able to detect that, so\r\n // either reject with the string \"Cancelled\" or reject with the original http rejection otherwise\r\n\t\t\t if (isCancelled) {\r\n\t\t\t reject.call(this, \"Cancelled\");\r\n\t\t\t }\r\n\t\t\t else {\r\n\t\t\t reject.apply(this, arguments);\r\n\t\t\t }\r\n\t\t\t });\r\n\t\t\t});\r\n }\r\n\r\n function fixAPISearchRequest(request) {\r\n // There's a mismatch in casing on these properties; all properties on UI objects should be camelCase, but for some reason\r\n // we CamelCased a few, and it's causing a mismatch. This would be an enormous effort to correct in-place, so for now when\r\n // the API sends a search filter down (not in a saved search because that's not touched by the API), correct the problem\r\n // manually. The TODO is to completely rewrite the Action View UI.\r\n var propsWithBadCasing = [\r\n 'CalculateReadyAndNotReady',\r\n 'CustomOutput',\r\n 'DetailedResults',\r\n 'ShowChoice',\r\n 'WhereChoice',\r\n 'ThatAreChoice',\r\n 'ShowUserTeams',\r\n 'ShowTeams',\r\n 'ShowMostPressingTasks',\r\n 'IncludeUnscheduled',\r\n 'IncludeUserTeams',\r\n 'IncludeTeams',\r\n 'DateTimeChoice',\r\n 'CompletedChoice',\r\n 'DueWithinDays',\r\n 'IncludeChoice',\r\n 'OrganizeBy',\r\n 'ComposeDynamicSql',\r\n 'LastActivityTo',\r\n 'LastActivityFrom',\r\n 'EntityOutputColumns',\r\n 'TaskOutputColumns'\r\n ];\r\n\r\n if (request.output === null) {\r\n request.output = 'default';\r\n }\r\n\r\n for (var i = 0; i < propsWithBadCasing.length; i++) {\r\n var newProp = propsWithBadCasing[i];\r\n var oldProp = newProp[0].toLowerCase() + newProp.substring(1);\r\n request[newProp] = request[oldProp];\r\n delete request[oldProp];\r\n }\r\n }\r\n\r\n function processSearchResultPlusRequest(searchResults) {\r\n var lookup = searchResults.columnReferenceLookup;\r\n // For each column, find the matching lookup and combine the properties of the object from lookup\r\n // and the column\r\n searchResults.originalRequest.entityOutputColumns = _.map(\r\n searchResults.originalRequest.entityOutputColumns,\r\n function (c) { return _.assign({}, lookup[c.id], c); }\r\n );\r\n searchResults.originalRequest.taskOutputColumns = _.map(\r\n searchResults.originalRequest.taskOutputColumns,\r\n function (c) { return _.assign({}, lookup[c.id], c); }\r\n );\r\n fixAPISearchRequest(searchResults.originalRequest);\r\n }\r\n\r\n function welcomeSearch(viewMode) {\r\n return sdHttp.get(SERVICE_URL + 'Welcome/' + viewMode.toString()).then(function (searchResults) {\r\n processSearchResultPlusRequest(searchResults);\r\n return searchResults;\r\n });\r\n }\r\n\r\n\t\tfunction executeActionViewToExcel(filter) {\r\n\t\t\tfilter.outputInt = 1;\r\n\t\t\tfilter.outputFormat = 1;\r\n\t\t\tfilter.outputType = 1;\r\n\r\n\t\t\tvar config = {};\r\n\r\n\t\t\t// start long-running process\r\n\t\t\tconst busyRef = busyIndicatorService.show({\r\n\t\t\t\tmessage: 'Exporting search results',\r\n\t\t\t});\r\n\r\n\t\t\tsdHttp.post(SERVICE_URL + 'export', filter, config).then(function (lrpId) {\r\n snackBarService.addById(lrpId, 35); //35 = Compliance.LongRunningProcessTypeEnum.ActionViewExport\r\n\t\t\t\tbusyRef.hide();\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction cancelAvSearch() {\r\n\t\t\tif (vm.canceler)\r\n\t\t\t\tvm.canceler.resolve(\"user cancelled\");\r\n\t\t\tconsole.log('action view search has been cancelled');\r\n\t\t}\r\n\r\n\t\tfunction shareSearch(searchItem) {\r\n\t\t\treturn sdHttp.patch(SERVICE_URL_SEARCH_SHARE, searchItem);\r\n\t\t}\r\n\r\n\t\tfunction revokeActionViewShare(actionViewItem) {\r\n\t\t\treturn sdHttp.patch(SERVICE_URL_ACTION_VIEW_REVOKE_SHARE, actionViewItem);\r\n\t\t}\r\n\r\n\t\tfunction share(actionViewItem) {\r\n\t\t\treturn sdHttp.patch(SERVICE_URL_ACTION_VIEW_SHARE, actionViewItem);\r\n\t\t}\r\n\r\n\t\tfunction revokeShare(actionViewItem) {\r\n\t\t\treturn sdHttp.patch(SERVICE_URL_ACTION_VIEW_REVOKE_SHARE, actionViewItem);\r\n\t\t}\r\n\r\n\t\tfunction getTasksAssignmentReadyOptions() {\r\n\t\t\tvar options = {\r\n\t\t\t\tshowOptions: {\r\n\t\t\t\t\tmyTasks: {\r\n\t\t\t\t\t\tid: 2,\r\n\t\t\t\t\t\tdisplay: 'My Tasks'\r\n\t\t\t\t\t},\r\n\t\t\t\t\tmyTeamsTasks: {\r\n\t\t\t\t\t\tid: 3,\r\n\t\t\t\t\t\tdisplay: userService.isSingleInstanceSelected() ? \"My Team's Tasks\" : \"My Teams' Tasks\"\r\n\t\t\t\t\t},\r\n\t\t\t\t\tindividualsTasks: {\r\n\t\t\t\t\t\tid: 4,\r\n\t\t\t\t\t\tdisplay: \"Specific Individual's Tasks\"\r\n\t\t\t\t\t},\r\n\t\t\t\t\tteamsTasks: {\r\n\t\t\t\t\t\tid: 5,\r\n\t\t\t\t\t\tdisplay: \"Specific Team's Tasks\"\r\n\t\t\t\t\t},\r\n\t\t\t\t\tallTasks: {\r\n\t\t\t\t\t\tid: 1,\r\n\t\t\t\t\t\tdisplay: 'All Tasks'\r\n\t\t\t\t\t}\r\n\t\t\t\t},\r\n\r\n\t\t\t\twhereOptions: [{\r\n\t\t\t\t\tdisplay: 'Assigned',\r\n\t\t\t\t\tid: 1\r\n\t\t\t\t}, {\r\n\t\t\t\t\tdisplay: \"Ultimately Responsible\",\r\n\t\t\t\t\tid: 2\r\n\t\t\t\t}, {\r\n\t\t\t\t\tdisplay: \"Assigned or Ultimately Responsible\",\r\n\t\t\t\t\tid: 3\r\n\t\t\t\t}, {\r\n\t\t\t\t\tdisplay: \"Account Handler\",\r\n\t\t\t\t\tid: 4\r\n\t\t\t\t}, {\r\n\t\t\t\t\tdisplay: \"Compliance Returns PP Resp\",\r\n\t\t\t\t\tid: 5\r\n\t\t\t\t}],\r\n\r\n\t\t\t\tthatAreOptions: [{\r\n\t\t\t\t\tdisplay: 'Ready',\r\n\t\t\t\t\tid: 1\r\n\t\t\t\t}, {\r\n\t\t\t\t\tdisplay: \"Not Ready\",\r\n\t\t\t\t\tid: 2\r\n\t\t\t\t}, {\r\n\t\t\t\t\tdisplay: \"Ready or Not Ready\",\r\n\t\t\t\t\tid: 3\r\n\t\t\t\t}, {\r\n\t\t\t\t\tdisplay: \"Completed\",\r\n\t\t\t\t\tid: 4\r\n\t\t\t\t}],\r\n\r\n\t\t\t\tincludeOptions: [{\r\n\t\t\t\t\tdisplay: 'All Completed Tasks',\r\n\t\t\t\t\tid: 1\r\n\t\t\t\t}, {\r\n\t\t\t\t\tdisplay: 'Tasks Completed by Me',\r\n\t\t\t\t\tid: 2\r\n\t\t\t\t\t// At the moment, we're not saving data about what team completed a task, so the backend can't execute\r\n\t\t\t\t\t// queries with a filter about completed team. We're hiding this option on the interface until/unless we\r\n\t\t\t\t\t// decide to open that option up in the future. This also affects the _taskAssignmentReadyPanel.html page.\r\n\t\t\t\t\t//}, {\r\n\t\t\t\t\t//\tdisplay: 'Tasks Completed by My Team',\r\n\t\t\t\t\t//\tid: 3\r\n\t\t\t\t}, {\r\n\t\t\t\t\tdisplay: 'Tasks Completed by a Specific Individual',\r\n\t\t\t\t\tid: 4\r\n\t\t\t\t\t//}, {\r\n\t\t\t\t\t//\tdisplay: 'Tasks Completed by a Specific Team',\r\n\t\t\t\t\t//\tid: 5\r\n\t\t\t\t}]\r\n\t\t\t};\r\n\r\n\t\t\treturn options;\r\n\t\t}\r\n\r\n\t\tfunction mapThatAreChoiceToDisplayValue(id) {\r\n\t\t\tconst thatAreOptions = getTasksAssignmentReadyOptions().thatAreOptions;\r\n\r\n\t\t\tfor(let i = 0; i < thatAreOptions.length; i++){\r\n\t\t\t\tif(thatAreOptions[i].id === id)\r\n\t\t\t\t\treturn thatAreOptions[i].display;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction getUrgencies() {\r\n\t\t\treturn [{\r\n\t\t\t\tid: 1,\r\n\t\t\t\tdisplay: 'Overdue (Black)'\r\n\t\t\t}, {\r\n\t\t\t\tid: 2,\r\n\t\t\t\tdisplay: 'Critical (Red)'\r\n\t\t\t}, {\r\n\t\t\t\tid: 3,\r\n\t\t\t\tdisplay: 'Imminent (Yellow)'\r\n\t\t\t}, {\r\n\t\t\t\tid: 4,\r\n\t\t\t\tdisplay: 'Approaching (Green)'\r\n\t\t\t}, {\r\n\t\t\t\tid: 5,\r\n\t\t\t\tdisplay: 'Prospective (Grey)'\r\n\t\t\t}, {\r\n\t\t\t\tid: 6,\r\n\t\t\t\tdisplay: 'Critical Or Imminent'\r\n\t\t\t}]\r\n\t\t}\r\n\r\n\t\tfunction prepareCriteriaForSave(criteria) {\r\n\t\t\tvar returnCriteria = {};\r\n\t\t\treturnCriteria.outputColumns = _.map(criteria, function (column) {\r\n\t\t\t\treturn column.columnId || column.advancedSearchFieldID\r\n\t\t\t});\r\n\r\n\t\t\treturnCriteria.filters = _.map(angular.copy(criteria), function (filter) {\r\n\t\t\t\tfilter.or = _.map(filter.or, function (or) {\r\n\t\t\t\t\treturn {\r\n\t\t\t\t\t\tvalue: or.value,\r\n\t\t\t\t\t\toperator: or.operator.name\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\r\n\t\t\t\treturn {\r\n\t\t\t\t\tcolumnId: filter.columnId || filter.advancedSearchFieldID,\r\n\t\t\t\t\tor: filter.or\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\treturn returnCriteria;\r\n\t\t}\r\n\r\n\t\tfunction prepareActionViewForSave(actionView, filterColumns, isSave) {\r\n\t\t\tvar saveActionViewItem = actionView;\r\n\t\t\tsaveActionViewItem.criteria = prepareCriteriaForSave(filterColumns);\r\n\r\n\t\t\t//This moves the masterFilter to criteria, where it is saved\r\n\t\t\tsaveActionViewItem.criteria.masterFilter = actionView.masterFilter;\r\n\r\n\t\t\tif (isSave) {\r\n\t\t\t\tsaveActionViewItem.criteria = JSON.stringify(saveActionViewItem.criteria);\r\n\t\t\t}\r\n\t\t\tdelete saveActionViewItem.masterFilter;\r\n\r\n\t\t\treturn saveActionViewItem;\r\n\t\t}\r\n\r\n\t\tfunction prepareActionViewForExecution(filterColumns, masterFilter) {\r\n\t\t\tactionViewPersistenceService.filterColumns = filterColumns;\r\n\r\n\t\t\tvar filterToExecute = _.mapValues(angular.copy(masterFilter), function (val) {\r\n\t\t\t\tif (val === undefined) {\r\n\t\t\t\t\tval = 0\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// Null out any arrays with empty objects\r\n\t\t\t\t// - userTeams and teams - show and include\r\n\t\t\t\tif (_.isArray(val)) {\r\n\t\t\t\t\tval = _.reject(val, function (obj) {\r\n\t\t\t\t\t\treturn (_.isEmpty(obj) && _.isObject(obj)) || obj.teamID === null || obj.userID === null; // band aid fix for when these props are null.\r\n\t\t\t\t\t})\r\n\r\n\t\t\t\t\tif (!val.length) {\r\n\t\t\t\t\t\tval = null;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\treturn val;\r\n\t\t\t});\r\n\r\n\t\t\tfilterToExecute.filters = columnFilterService.prepareFilters(filterColumns);\r\n\r\n\t\t\tfilterToExecute.TaskOutputColumns = _.map(filterToExecute.TaskOutputColumns, prepareOutputColumn)\r\n\t\t\tfilterToExecute.EntityOutputColumns = _.map(filterToExecute.EntityOutputColumns, prepareOutputColumn);\r\n\r\n\t\t\treturn filterToExecute;\r\n\t\t}\r\n\r\n\t\tfunction prepareOutputColumn(column) {\r\n\t\t\tcolumn.id = column.id || column.columnId || column.advancedSearchFieldID;\r\n\r\n\t\t\treturn _.pick(column, 'id', 'sequence', 'displayName', 'depthValue', 'resultColumnName', 'canGroupTaskActionView', 'fromTaskType');\r\n\t\t}\r\n\r\n\t\tfunction sortTaskTypes(taskTypes) {\r\n\t\t\treturn _.sortBy(taskTypes, ['taskSeriesTypeSequence', 'sequence']);\r\n\t\t}\r\n\r\n\t\tfunction getFavoriteCount(actionViewItem) {\r\n\t\t\treturn sdHttp.get(SERVICE_URL_FAVORITE_COUNT + actionViewItem.actionViewID);\r\n\t\t}\r\n\r\n function getUrgencyColumnStyleClass(columnSequence) {\r\n switch (columnSequence) {\r\n case 0:\r\n return 'urgency-overdue';\r\n case 1:\r\n return 'urgency-critical';\r\n case 2:\r\n return 'urgency-imminent';\r\n case 3:\r\n return 'urgency-approaching';\r\n case 4:\r\n return 'urgency-prospective';\r\n default:\r\n return '';\r\n }\r\n }\r\n\r\n function getUrgencyChoiceByHeaderName(header) {\r\n var urgencies = getUrgencies();\r\n\r\n var urgency = _.find(urgencies, function (urgency) {\r\n return urgency.display.split(' ')[0].toLowerCase() === header.toLowerCase()\r\n });\r\n\r\n if (urgency === undefined) {\r\n console.warn('urgency id not found from header!')\r\n }\r\n\r\n return urgency.id;\r\n }\r\n\r\n\t\t// Mostly copied from src\\app\\Task\\ActionView\\Output.Defaults.Controller.js\r\n\t\tfunction launchCustomOutputModal(clickedTaskType, taskTypeColumns) {\r\n\t\t\tvar userSetting = userSettingsService.getSettingsByGroup(12)[0] || {\r\n\t\t\t\tgroupId: 12,\r\n\t\t\t\tname: 'Task View Output Defaults',\r\n\t\t\t\tvalue: [],\r\n\t\t\t\tid: 0\r\n\t\t\t};\r\n\r\n\t\t\tvar customTaskTypes = angular.fromJson(userSetting.value);\r\n\r\n\t\t\tvar customTaskType = _.find(customTaskTypes, function (taskType) {\r\n\t\t\t\treturn taskType.taskSeriesTypeID === clickedTaskType.taskSeriesTypeID && taskType.taskTypeID === clickedTaskType.taskTypeID;\r\n\t\t\t});\r\n\r\n\t\t\treturn advancedSearchService.getAllFields().then(function (allFields) {\r\n\t\t\t\tvar modalInstance = $uibModal.open({\r\n\t\t\t\t\ttemplateUrl: 'app/Task/ActionView/Filters/_customOutputModal.html',\r\n\t\t\t\t\tcontroller: 'CustomOutputModalController',\r\n\t\t\t\t\tcontrollerAs: 'vm',\r\n\t\t\t\t\twindowClass: 'show',\r\n\t\t\t\t\tbackdropClass: 'show',\r\n\t\t\t\t\tresolve: {\r\n\t\t\t\t\t\tfromActionView: function () {\r\n\t\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t\t},\r\n\r\n\t\t\t\t\t\ttaskTypeName: function () {\r\n\t\t\t\t\t\t\treturn clickedTaskType.name;\r\n\t\t\t\t\t\t},\r\n\r\n\t\t\t\t\t\tselectedTaskType: function () {\r\n\t\t\t\t\t\t\treturn _.find(vm.taskTypes, { taskSeriesTypeID: clickedTaskType.taskSeriesTypeID });\r\n\t\t\t\t\t\t},\r\n\r\n\t\t\t\t\t\tsystemColumns: function () {\r\n\t\t\t\t\t\t\tvar systemColumns = _.map(clickedTaskType.columnIds, function (columnId) {\r\n\t\t\t\t\t\t\t\tvar column = angular.copy(_.find(taskTypeColumns, { columnId: columnId }));\r\n\r\n\t\t\t\t\t\t\t\treturn column;\r\n\t\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\t\t\treturn systemColumns;\r\n\t\t\t\t\t\t},\r\n\r\n\t\t\t\t\t\tuserColumns: function () {\r\n\t\t\t\t\t\t\tif (!customTaskType) {\r\n\t\t\t\t\t\t\t\treturn [];\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tvar userColumns = _.map(angular.copy(customTaskType.columns), function (column) {\r\n\t\t\t\t\t\t\t\tvar fullColumn = angular.copy(_.find(allFields, { advancedSearchFieldID: column.columnId }))\r\n\t\t\t\t\t\t\t\t_.assign(column, _.omit(fullColumn, 'sequence'));\r\n\r\n\t\t\t\t\t\t\t\treturn column;\r\n\t\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\t\treturn userColumns;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\r\n\t\t\t\treturn modalInstance.result\r\n\t\t\t\t\t.then(function (fullColumns) {\r\n\t\t\t\t\t\tif (fullColumns.length) {\r\n\t\t\t\t\t\t\tvar columnsToSave = _.map(fullColumns, function (filter, i) {\r\n\t\t\t\t\t\t\t\treturn {\r\n\t\t\t\t\t\t\t\t\tcolumnId: filter.columnId,\r\n\t\t\t\t\t\t\t\t\tsequence: i\r\n\t\t\t\t\t\t\t\t};\r\n\t\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\t\tif (customTaskType) {\r\n\t\t\t\t\t\t\t\tvar i = _.findIndex(customTaskTypes, function (taskType) {\r\n\t\t\t\t\t\t\t\t\treturn taskType.taskSeriesTypeID === customTaskType.taskSeriesTypeID && taskType.taskTypeID === customTaskType.taskTypeID;\r\n\t\t\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\t\t\tcustomTaskTypes[i].columns = columnsToSave\r\n\r\n\t\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t\tcustomTaskTypes.push({\r\n\t\t\t\t\t\t\t\t\ttaskSeriesTypeID: clickedTaskType.taskSeriesTypeID,\r\n\t\t\t\t\t\t\t\t\ttaskTypeID: clickedTaskType.taskTypeID,\r\n\t\t\t\t\t\t\t\t\tcolumns: columnsToSave\r\n\t\t\t\t\t\t\t\t});\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tuserSetting.value = JSON.stringify(customTaskTypes);\r\n\t\t\t\t\t\t\treturn userSettingsService.save(userSetting)\r\n\t\t\t\t\t\t\t\t.then(function () { })\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\tif (customTaskType) {\r\n\t\t\t\t\t\t\t\t_.remove(customTaskTypes, customTaskType);\r\n\r\n\t\t\t\t\t\t\t\tuserSetting.value = customTaskTypes;\r\n\t\t\t\t\t\t\t\treturn userSettingsService.save(userSetting)\r\n\t\t\t\t\t\t\t\t\t.then(function () { })\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t})\r\n\r\n\t\t\t\t})\r\n\r\n\t\t}\r\n\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('actionViewSortingDropdowns', actionViewSortingDropdowns);\r\n\r\n\tactionViewSortingDropdowns.$inject = [];\r\n\r\n\tfunction actionViewSortingDropdowns() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Task/ActionView/_actionViewSortingDropdowns.html',\r\n\t\t\tscope: {\r\n\t\t\t\torganizeBySelection: '=',\r\n\t\t\t\tgroupBySelection: '=',\r\n\t\t\t\tgroupBySelectionSecondary: '=',\r\n\t\t\t\tfilterColumns: '=',\r\n\t\t\t\tmasterFilter: '=',\r\n\t\t\t\tfilterChanged: '=',\r\n\t\t\t\tpageLoading: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n\r\n\tController.$inject = [\r\n '$scope',\r\n 'ActionViewGroupByTypes',\r\n '$rootScope',\r\n 'productAnalyticsService'\r\n\t];\r\n\r\n function Controller() {\r\n weissNg1WrapFunc(init, arguments, this);\r\n }\r\n\r\n\tfunction init($scope, ActionViewGroupByTypes, $rootScope, productAnalyticsService) {\r\n\t\tvar vm = this;\r\n\r\n\t\tif(vm.groupBySelection) {\r\n\t\t\tvm.groupBySelection = Number(vm.groupBySelection)\r\n\t\t}\r\n\r\n\t\tvm.organizeByItems = [{ id: 1, name: 'Urgency' }, { id: 2, name: 'Due Date Range' }, { id: 3, name: 'Last Action Date Range' }];\r\n\r\n\t\tcalculateGroupByOptions();\r\n\t\t$rootScope.$broadcast('actionViewFilterChanged', vm.masterFilter.ShowMostPressingTasks, vm.masterFilter.CalculateReadyAndNotReady, vm.masterFilter.showTotals);\r\n\r\n\t\tfunction calculateGroupByOptions() {\r\n\t\t\tvar allGroupByOptions = angular.copy(ActionViewGroupByTypes);\r\n\t\t\tvar groupByOptions = [];\r\n\r\n\t\t\t_.forEach(vm.filterColumns, function (value, key) {\r\n\t\t\t\tif(value.canGroupTaskActionView) {\r\n\t\t\t\t\tgroupByOptions.push({\r\n\t\t\t\t\t\tid: value.columnId || value.advancedSearchFieldID || value.id,\r\n\t\t\t\t\t\tname: value.resultColumnName || value.resultsColumnName || value.displayName\r\n\t\t\t\t\t});\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\t_.forEach(vm.masterFilter.TaskOutputColumns, function (value, key) {\r\n\t\t\t\tif (value.canGroupTaskActionView) {\r\n\t\t\t\t\tgroupByOptions.push({\r\n\t\t\t\t\t\tid: value.id || value.columnId || value.advancedSearchFieldID,\r\n\t\t\t\t\t\tname: value.resultColumnName || value.resultsColumnName || value.displayName\r\n\t\t\t\t\t});\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\tvm.groupByOptions = groupByOptions;\r\n\t\t}\r\n\r\n\t\t$scope.$watch('vm.filterColumns', function () {\r\n\t\t\tcalculateGroupByOptions();\r\n\t\t});\r\n\r\n\t\t$scope.$watch('vm.masterFilter.TaskOutputColumns', function () {\r\n\t\t\tcalculateGroupByOptions();\r\n\t\t})\r\n\r\n vm.changeOrganizeSelect = function () {\r\n productAnalyticsService.logEvent('select-action-view-organize-option', {\r\n actionViewOrganizeBy: vm.organizeByItems.find(x => x.id === vm.organizeBySelection)?.name\r\n });\r\n }\r\n\r\n vm.changeGroupSelect = function () {\r\n productAnalyticsService.logEvent('select-action-view-group-by-option', {\r\n actionViewGroupBy: vm.groupByOptions.find(x => x.id === vm.groupBySelection)?.name\r\n });\r\n }\r\n\r\n\t\tvm.filterChange = function (eventName) {\r\n\t\t\t$rootScope.$broadcast('actionViewFilterChanged', vm.masterFilter.ShowMostPressingTasks, vm.masterFilter.CalculateReadyAndNotReady, vm.masterFilter.showTotals);\r\n if (eventName) {\r\n productAnalyticsService.logEvent(eventName);\r\n }\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller('FiltersOutputsController', FiltersOutputsController);\r\n\r\n\tFiltersOutputsController.$inject = [\r\n\t\t'$scope',\r\n\t\t'$rootScope',\r\n\t\t'$uibModal',\r\n\t\t'plainEnglishService',\r\n\t\t'$stateParams',\r\n\t\t'ActionViewDisplayTypes',\r\n\t\t'SD.Restrict.Service',\r\n\t\t'actionViewService',\r\n\t\t'advancedSearchService',\r\n\t\t'actionViewPersistenceService',\r\n\t\t'toastr',\r\n\t\t'ActionViewCategoryTypes',\r\n\t\t'ActionViewGroupByTypes',\r\n\t\t'utils',\r\n\t\t'$state',\r\n\t\t'messageBoxService',\r\n\t\t'$q',\r\n\t\t'$timeout',\r\n\t\t'productAnalyticsService',\r\n\t\t'userInstanceService',\r\n 'userSaveService'\r\n\t];\r\n\r\n\tfunction FiltersOutputsController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit($scope, $rootScope, $uibModal, plainEnglishService, $stateParams, ActionViewDisplayTypes, restrictService, actionViewService, advancedSearchService, actionViewPersistenceService, toastr, ActionViewCategoryTypes, ActionViewGroupByTypes, utils, $state, messageBoxService, $q, $timeout, productAnalyticsService, userInstanceService, userSaveService) {\r\n\r\n\t\tvar vm = this;\r\n\r\n\t\tvar defaultColumns = [];\r\n\t\tvar allFields = [];\r\n\t\tvar searchSaved = false;\r\n\r\n\t\tvm.excludeInactive = false;\r\n\t\tvm.showOrs = false;\r\n\t\tvm.dataLoaded = false;\r\n\r\n\t\tvm.filterColumns = [];\r\n\t\tvm.masterFilter = {};\r\n\t\tvm.drilldownFilter = {};\r\n\t\tvm.actionView = {};\r\n\t\tvm.originalFilter = {};\r\n\t\tvm.invalidColumns = [];\r\n\r\n\t\tvm.getPlainEnglish = plainEnglishService.getForFilter;\r\n\t\tvm.saveSearchAs = saveSearchAs;\r\n\t\tvm.saveSearch = saveSearch;\r\n\t\tvm.areNoOrs = areNoOrs;\r\n\t\tvm.goToOverview = goToOverview;\r\n\t\tvm.goToDetail = goToDetail;\r\n\t\tvm.backToOverviewClick = backToOverviewClick;\r\n\t\tvm.hideSaveButton = hideSaveButton;\r\n\t\tvm.reloadActionView = reloadActionView;\r\n\t\tvm.favoriteSearchToggle = favoriteSearchToggle;\r\n\t\tvm.showFilter = showFilter;\r\n\t\tvm.thatAreCompleted = thatAreCompleted;\r\n\t\tvm.cancelAvSearch = cancelAvSearch;\r\n\t\tvm.hideRevokeActionViewButton = hideRevokeActionViewButton;\r\n\t\tvm.revokeActionViewShare = revokeActionViewShare;\r\n\t\tvm.hasAnyFiltersPopulated = hasAnyFiltersPopulated;\r\n\t\tvm.customChosen = customChosen;\r\n\t\tvm.defaultChosen = defaultChosen;\r\n vm.updateColumnFilters = updateColumnFilters;\r\n\r\n\t\tvm.detailedResults;\r\n\t\tvm.showOverview = false;\r\n\t\tvm.showDetail = false;\r\n\t\tvm.showFilterPage = false;\r\n\t\tvm.overviewLoading = false;\r\n\r\n\t\tvm.organizeBySelection = \"1\";\r\n\t\t//vm.groupBySelection = 0;\r\n\r\n\t\tvm.hasEditPermission = restrictService.isInRole(restrictService.Roles.SYSTEMSEARCHESEDIT);\r\n\r\n\t\tadvancedSearchService.getAllFields()\r\n\t\t\t.then(function (result) {\r\n\t\t\t\t//console.log('we have advanced search fields', result);\r\n\t\t\t\tvm.allSearchFieldsLoaded = true;\r\n\t\t\t\tallFields = result;\r\n\t\t\t});\r\n\r\n\t\tactivate();\r\n\r\n\t\t$scope.$on('deleteActionView', function (event, actionView) {\r\n\t\t\tvar actionViewId = parseInt($stateParams.actionViewId);\r\n\t\t\tconsole.log(actionView);\r\n\r\n\t\t\tif (actionViewId === actionView.actionViewID) {\r\n\t\t\t\t$state.go('home');\r\n\t\t\t}\r\n\t\t})\r\n\r\n\t\tvm.launchCustomOutput = function () {\r\n\t\t\tvar modalInstance = $uibModal.open({\r\n\t\t\t\ttemplateUrl: 'app/Task/ActionView/Filters/_customOutputModal.html',\r\n\t\t\t\tcontroller: 'CustomOutputModalController',\r\n\t\t\t\tcontrollerAs: 'vm',\r\n\t\t\t\twindowClass: 'show',\r\n\t\t\t\tbackdropClass: 'show',\r\n\t\t\t\tresolve: {\r\n\t\t\t\t\tfromActionView: function () {\r\n\t\t\t\t\t\treturn true\r\n\t\t\t\t\t},\r\n\r\n\t\t\t\t\tselectedTaskType: function () {\r\n\t\t\t\t\t\treturn _.find(vm.taskTypes, { taskTypeID: vm.masterFilter.taskTypeID });\r\n\t\t\t\t\t},\r\n\r\n\t\t\t\t\ttaskTypeName: function () {\r\n\t\t\t\t\t\treturn vm.masterFilter.taskTypeName\r\n\t\t\t\t\t},\r\n\r\n\t\t\t\t\tsystemColumns: function () {\r\n\t\t\t\t\t\treturn _.union(vm.masterFilter.TaskOutputColumns, vm.masterFilter.EntityOutputColumns);\r\n\t\t\t\t\t},\r\n\r\n\t\t\t\t\tuserColumns: function () {\r\n\t\t\t\t\t\treturn _.union(vm.masterFilter.TaskOutputColumns, vm.masterFilter.EntityOutputColumns);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\tmodalInstance.result\r\n\t\t\t\t.then(function (changedFilters) {\r\n\t\t\t\t\tvar outputColumns = _.groupBy(angular.copy(changedFilters), function (filter) {\r\n\t\t\t\t\t\tvar filterColumnId = filter.columnId || filter.advancedSearchFieldID || filter.id;\r\n\t\t\t\t\t\treturn filterColumnId > 9999 && filterColumnId < 11000 ? 'TaskOutputColumns' : 'EntityOutputColumns';\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\toutputColumns.TaskOutputColumns = outputColumns.TaskOutputColumns || [];\r\n\t\t\t\t\toutputColumns.EntityOutputColumns = outputColumns.EntityOutputColumns || [];\r\n\r\n\t\t\t\t\tvar newFilterColumns = _.filter(angular.copy(outputColumns.EntityOutputColumns), function (column) {\r\n\t\t\t\t\t\tvar columnId = column.columnId || column.advancedSearchFieldID || column.id;\r\n\t\t\t\t\t\t// We need to remove the document image preview column because it can't be filtered on\r\n\t\t\t\t\t\treturn columnId !== 9002 && columnId !== 1430;\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\tvm.filterColumns = _.map(newFilterColumns, function (column) {\r\n\t\t\t\t\t\tvar columnId = column.columnId || column.advancedSearchFieldID || column.id;\r\n\t\t\t\t\t\tvar existingColumn = _.find(vm.filterColumns, function (filter) {\r\n\t\t\t\t\t\t\treturn (filter.columnId || filter.advancedSearchFieldID || filter.id) === columnId\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\treturn existingColumn || column\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\toutputColumns.CustomOutput = true;\r\n\r\n\t\t\t\t\t_.assign(vm.masterFilter, outputColumns);\r\n\r\n\t\t\t\t\tvar outputColumns = _.chain(outputColumns.TaskOutputColumns)\r\n\t\t\t\t\t\t.union(outputColumns.EntityOutputColumns)\r\n\t\t\t\t\t\t.cloneDeep()\r\n\t\t\t\t\t\t.value();\r\n\r\n\t\t\t\t\tvm.invalidColumns = advancedSearchService.getInvalidColumns(outputColumns)\r\n\t\t\t\t})\r\n\t\t}\r\n\r\n\t\tfunction areNoOrs() {\r\n\t\t\treturn _.chain(vm.filterColumns)\r\n\t\t\t\t.map('or')\r\n\t\t\t\t.every(function (orArr) {\r\n\t\t\t\t\tif (orArr) {\r\n\t\t\t\t\t\treturn orArr.length < 2;\r\n\t\t\t\t\t}\r\n\t\t\t\t})\r\n\t\t\t\t.value();\r\n\t\t}\r\n\r\n\t\tfunction saveSearchAs() {\r\n\t\t\tagreeToRunLongRunningQuery().then(function (result) {\r\n\t\t\t\tif (result) {\r\n\t\t\t\t\tsetOrganizeAndGroupOptions();\r\n\t\t\t\t\tvm.filterToExecute = actionViewService.prepareActionViewForExecution(vm.filterColumns, vm.masterFilter);\r\n\t\t\t\t\tvar modalInstance = $uibModal.open({\r\n\t\t\t\t\t\ttemplateUrl: 'app/Task/ActionView/_saveActionViewModal.html',\r\n\t\t\t\t\t\tcontroller: 'SaveActionViewModalController',\r\n\t\t\t\t\t\tcontrollerAs: 'vm',\r\n\t\t\t\t\t\twindowClass: 'show',\r\n\t\t\t\t\t\tbackdropClass: 'show',\r\n size: 'lg',\r\n\t\t\t\t\t\tresolve: {\r\n\t\t\t\t\t\t\tactionViewObj: function () {\r\n\t\t\t\t\t\t\t\tvar actionView = {\r\n\t\t\t\t\t\t\t\t\tmasterFilter: angular.copy(vm.filterToExecute)\r\n\t\t\t\t\t\t\t\t};\r\n\r\n\t\t\t\t\t\t\t\tactionView.masterFilter.showOrs = vm.showOrs;\r\n\t\t\t\t\t\t\t\tactionView.actionViewName = vm.actionView.actionViewName;\r\n\r\n\t\t\t\t\t\t\t\treturn actionView;\r\n\t\t\t\t\t\t\t},\r\n\t\t\t\t\t\t\thasEditPermission: function () {\r\n\t\t\t\t\t\t\t\treturn vm.hasEditPermission;\r\n\t\t\t\t\t\t\t},\r\n\t\t\t\t\t\t\tfilterColumns: function () {\r\n\t\t\t\t\t\t\t\treturn angular.copy(vm.filterColumns);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\tmodalInstance.result\r\n\t\t\t\t\t.then(function() {\r\n userSaveService.updateList(1);\r\n\t\t\t\t\t\tsearchSaved = true;\r\n\t\t\t\t\t})\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction saveSearch() {\r\n\t\t\tagreeToRunLongRunningQuery().then(function (result) {\r\n\t\t\t\tif (result) {\r\n\t\t\t\t\t//var search = angular.copy(vm.search);\r\n\t\t\t\t\tsetOrganizeAndGroupOptions();\r\n\t\t\t\t\tvm.filterToExecute = actionViewService.prepareActionViewForExecution(vm.filterColumns, vm.masterFilter);\r\n\t\t\t\t\tvm.actionView.masterFilter = angular.copy(vm.filterToExecute);\r\n\t\t\t\t\tvm.actionView.masterFilter.showOrs = vm.showOrs;\r\n\t\t\t\t\tif (vm.isSystemView) {\r\n\t\t\t\t\t\tif (confirm('Confirm Overwriting System Action View')) {\r\n\t\t\t\t\t\t\tactionViewService.updateSystemActionView(vm.actionView, angular.copy(vm.filterColumns))\r\n\t\t\t\t\t\t\t\t.then(function () {\r\n\t\t\t\t\t\t\t\t\ttoastr.success('System Action View Saved!');\r\n userSaveService.updateList(1);\r\n\t\t\t\t\t\t\t\t\tsearchSaved = true;\r\n\t\t\t\t\t\t\t\t});\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tactionViewService.updateCustomActionView(vm.actionView, angular.copy(vm.filterColumns))\r\n\t\t\t\t\t\t\t.then(function (result) {\r\n\t\t\t\t\t\t\t\ttoastr.success('User Action View Saved!')\r\n\t\t\t\t\t\t\t\tvm.actionView.rowVersion = result.rowVersion;\r\n userSaveService.updateList(1);\r\n\t\t\t\t\t\t\t\tsearchSaved = true;\r\n\t\t\t\t\t\t\t})\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction revokeActionViewShare() {\r\n\t\t\tmessageBoxService.confirm('Sharing with other users will be revoked. Click OK to confirm.', 'Action View')\r\n\t\t\t\t.then(function () {\r\n\t\t\t\t\tactionViewService.revokeShare(vm.actionView)\r\n\t\t\t\t\t\t.then(function (result) {\r\n\t\t\t\t\t\t\tvm.actionView.isShared = result.actionViewSavedSearch.isShared;\r\n\t\t\t\t\t\t\ttoastr.success('Share was revoked!')\r\n\t\t\t\t\t\t});\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\r\n\t\tfunction showFilter() {\r\n productAnalyticsService.logSequenceEvent('refine-action-view-filter-criteria', 'click-change');\r\n\t\t\tactionViewPersistenceService.detailResults = null;\r\n\t\t\tvm.detailedResults = null\r\n\t\t\tvm.showOverview = false;\r\n\t\t\tvm.showDetail = false;\r\n\t\t\tvm.showFilterPage = true;\r\n\r\n if(!vm.filterColumns || vm.filterColumns.length == 0) {\r\n vm.taskAssignmentApi.checkActionViewDefaultOutput().then(function (checkDefaultResult) {\r\n vm.filterColumns = checkDefaultResult.filterColumns;\r\n });\r\n }\r\n\r\n\t\t\tcancelAvSearch();\r\n\t\t}\r\n\r\n\t\tfunction hasAnyFiltersPopulated() {\r\n\t\t\tvar hasAnyFilters = false;\r\n\r\n\t\t\t_.forEach(vm.filterColumns, function (filter, index) {\r\n\t\t\t\t_.forEach(filter.or, function (or, index) {\r\n\t\t\t\t\thasAnyFilters = or.value !== \"\" && or.value !== undefined;\r\n\r\n\t\t\t\t\tif (hasAnyFilters) {\r\n\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\r\n\t\t\t\tif (hasAnyFilters) {\r\n\t\t\t\t\treturn false;\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\treturn hasAnyFilters;\r\n\t\t}\r\n\r\n\r\n\t\tfunction agreeToRunLongRunningQuery() {\r\n\t\t\tvar showOptions = actionViewService.getTasksAssignmentReadyOptions().showOptions;\r\n\r\n\t\t\tvar isTaskTypeAll = vm.masterFilter.taskTypeID === 0;\r\n\t\t\tvar isShowAll = vm.masterFilter.ShowChoice === showOptions['allTasks'].id;\r\n\t\t\tvar isDateRangeMoreThanWeek = !vm.masterFilter.OnlyUnscheduled &&\r\n\t\t\t\t((vm.masterFilter.DateTimeChoice === 1) ||\r\n\t\t\t\t\t(vm.masterFilter.DateTimeChoice === 2 && vm.masterFilter.DueWithinDays > 7) ||\r\n\t\t\t\t\t(vm.masterFilter.DateTimeChoice === 3 && moment(vm.masterFilter.DueDateTo).diff(moment(vm.masterFilter.DueDateFrom), 'days') > 7));\r\n\r\n\t\t\tvar isLongRunningQuery = isTaskTypeAll && isShowAll && isDateRangeMoreThanWeek && !vm.hasAnyFiltersPopulated();\r\n\r\n\t\t\tif (isLongRunningQuery) {\r\n\t\t\t\tisLongRunningQuery = isLongRunningQuery &&\r\n\t\t\t\t\t(restrictService.isInRole(restrictService.Roles.RYANPRIVATEITEMSEDIT) ||\r\n\t\t\t\t\t\trestrictService.isInRole(restrictService.Roles.RYANPRIVATEITEMSVIEW));\r\n\t\t\t}\r\n\r\n\t\t\tvar deferred = $q.defer();\r\n\r\n\t\t\tdeferred.resolve(true);\r\n\r\n\t\t\t// WK-4799 asked us to remove this message. I left the code and structure in place in case we need to quickly revert\r\n // and don't want to dig through source control or cherry pick a reverted change. It's possible we want to show it\r\n // but less often, and after some discussion no one was completely confident about it.\r\n\r\n\t\t // IMPORTANT: messageBoxService.confirm has changed since this was written; if we uncomment this, we should get rid\r\n\t\t // of the .catch line; probably we need to convert to messageBoxService.open since the service no longer rejects on\r\n // cancel.\r\n\r\n\t\t\t/*if (isLongRunningQuery) {\r\n\t\t\t\tmessageBoxService.confirm('The Action View maybe slow to execute and/or return too much data. Do you want to proceed?', 'Task View', MessageBoxResult.Cancel).then(function () {\r\n\t\t\t\t\tdeferred.resolve(true);\r\n\t\t\t\t}).catch(function () {\r\n\t\t\t\t\tdeferred.resolve(false);\r\n\t\t\t\t})\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tdeferred.resolve(true);\r\n\t\t\t}*/\r\n\r\n\t\t\treturn deferred.promise;\r\n\t\t}\r\n\r\n\t\tfunction goToOverview() {\r\n\t\t\tif (invalidFilters()) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tagreeToRunLongRunningQuery().then(function (result) {\r\n\t\t\t\tif (result) {\r\n const event = { event: 'refine-action-view-filter-criteria' };\r\n productAnalyticsService.initiateSequenceEvent(event, ['click-overview', 'click-change']);\r\n productAnalyticsService.logEvent('click-action-view-overview');\r\n\r\n\t\t\t\t\tactionViewPersistenceService.clearSavedData();\r\n\r\n\t\t\t\t\tvm.masterFilter.DetailedResults = false;\r\n\r\n\t\t\t\t\tif ($stateParams.actionViewId !== undefined && Number($stateParams.displayType) && searchSaved) {\r\n\t\t\t\t\t\tsearchSaved = false;\r\n\t\t\t\t\t\tvm.filterToExecute = angular.copy(vm.masterFilter);\r\n\r\n\t\t\t\t\t\tvm.filterToExecute.filters = _.map(vm.filterToExecute.filters, function (filter) {\r\n\t\t\t\t\t\t\tfilter.resultColumnName = _.find(allFields, { 'advancedSearchFieldID': filter.columnId }).resultsColumnName;\r\n\r\n\t\t\t\t\t\t\treturn filter;\r\n\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tvm.filterToExecute = actionViewService.prepareActionViewForExecution(vm.filterColumns, vm.masterFilter);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t//This is super hacky, but somewhere along the way we misused these various filters\r\n\t\t\t\t\t//For now this is the best way to keep track of the filter as it was from the\r\n\t\t\t\t\t//Action view criteria page. It is needed to reset the drilldown filter before\r\n\t\t\t\t\t//going to overview\r\n\t\t\t\t\tvm.originalFilter = angular.copy(vm.filterToExecute);\r\n\t\t\t\t\tvm.drilldownFilter = angular.copy(vm.originalFilter);\r\n\r\n\t\t\t\t\tvm.showOverview = true;\r\n\t\t\t\t\tvm.showFilterPage = false;\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction cancelAvSearch() {\r\n\t\t\tactionViewService.cancelAvSearch();\r\n\t\t\t//toastr.info('', 'Action View request has been cancelled');\r\n\t\t}\r\n\r\n\r\n\t\tfunction backToOverviewClick(shouldCancelSearch) {\r\n\t\t\tif(shouldCancelSearch) {\r\n\t\t\t\tcancelAvSearch();\r\n\t\t\t}\r\n\r\n vm.showDetail = false;\r\n vm.showFilterPage = false;\r\n vm.showOverview = true;\r\n vm.overviewLoading = true;\r\n vm.detailedResults = null;\r\n\t\t\tactionViewPersistenceService.detailResults = {};\r\n\t\t\tactionViewPersistenceService.drilldownMode = false;\r\n\t\t\tvm.drilldownFilter = angular.copy(vm.originalFilter);\r\n\t\t\tvm.drilldownMode = false;\r\n\t\t\tif(actionViewPersistenceService.masterFilter && actionViewPersistenceService.externalDrilldown) {\r\n\t\t\t vm.masterFilter = actionViewPersistenceService.masterFilter\r\n }\r\n actionViewPersistenceService.externalDrilldown = false;\r\n actionViewPersistenceService.externalDrilldownData = null;\r\n\r\n\t\t}\r\n\r\n\t\tfunction hideSaveButton() {\r\n\t\t\tvar hideButton = (vm.isSystemView && !vm.hasEditPermission) || !vm.actionView.actionViewId || (!vm.isSystemView && !vm.actionView.isOwnedByUser);\r\n\t\t\treturn hideButton;\r\n\t\t}\r\n\r\n\t\tfunction hideRevokeActionViewButton() {\r\n\t\t\treturn !vm.actionView.isOwnedByUser || !vm.actionView.isShared;\r\n\t\t}\r\n\r\n\t\tfunction reloadActionView() {\r\n\t\t\tactionViewPersistenceService.clearSavedData();\r\n\t\t\t$state.go('actionview', $stateParams, { reload: true, inherit: false});\r\n\t\t}\r\n\r\n\t\tfunction goToDetail() {\r\n\t\t\tif (invalidFilters()) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tagreeToRunLongRunningQuery().then(function (result) {\r\n\t\t\t\tif (result) {\r\n const event = { event: 'refine-action-view-filter-criteria' };\r\n productAnalyticsService.initiateSequenceEvent(event, ['click-details-list', 'click-change']);\r\n productAnalyticsService.logEvent('click-action-view-detailed-list');\r\n\r\n\t\t\t\t\tsetOrganizeAndGroupOptions();\r\n\r\n\t\t\t\t\tvm.masterFilter.DetailedResults = true;\r\n\r\n\t\t\t\t\tactionViewPersistenceService.clearSavedData();\r\n\r\n\t\t\t\t\t//set up persistence service for return nub\r\n\t\t\t\t\tactionViewPersistenceService.filterColumns = angular.copy(vm.filterColumns);\r\n\t\t\t\t\tactionViewPersistenceService.filter = angular.copy(vm.masterFilter);\r\n\t\t\t\t\tactionViewPersistenceService.showOrs = vm.showOrs;\r\n\t\t\t\t\tactionViewPersistenceService.outputColumns = _.chain(angular.copy(vm.masterFilter))\r\n\t\t\t\t\t\t.map('columnId')\r\n\t\t\t\t\t\t.groupBy(function (id) {\r\n\t\t\t\t\t\t\treturn id > 9999 && id < 11000 ? 'TaskOutputColumns' : 'EntityOutputColumns';\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.value();\r\n\r\n\t\t\t\t\tvm.filterToExecute = actionViewService.prepareActionViewForExecution(vm.filterColumns, vm.masterFilter);\r\n\t\t\t\t\tvm.showDetail = true;\r\n\t\t\t\t\tvm.showFilterPage = false;\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction favoriteSearchToggle(isFavorite) {\r\n\t\t\tactionViewService.toggleFavorite(vm.actionView.actionViewId, isFavorite)\r\n\t\t\t\t.then(function (results) {\r\n\t\t\t\t\tvm.actionView.isFavorite = isFavorite;\r\n\t\t\t\t\t$rootScope.$broadcast('updateActionViewMenu');\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction invalidFilters() {\r\n\t\t\tvar showOptions = actionViewService.getTasksAssignmentReadyOptions().showOptions;\r\n\r\n\t\t\t// create an id mapping to fix a horrible id mismatch bug, this is a band-aid\r\n\t\t\t_.map(vm.masterFilter.TaskOutputColumns, function (item) {\r\n\t\t\t\tif (!item.id) {\r\n\t\t\t\t\tif (item.advancedSearchFieldID) {\r\n\t\t\t\t\t\titem.id = item.advancedSearchFieldID;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\t_.map(vm.masterFilter.EntityOutputColumns, function (item) {\r\n\t\t\t\tif (!item.id) {\r\n\t\t\t\t\tif (item.advancedSearchFieldID) {\r\n\t\t\t\t\t\titem.id = item.advancedSearchFieldID;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\r\n\t\t\tif (vm.masterFilter.ShowChoice === showOptions.individualsTasks.id && (!vm.masterFilter.ShowUserTeams[0] || !vm.masterFilter.ShowUserTeams[0].userID || !vm.masterFilter.ShowUserTeams[0].teamID)) {\r\n\t\t\t\ttoastr.error('User required for Show', 'Error');\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.masterFilter.ShowChoice === showOptions.teamsTasks.id && (!vm.masterFilter.ShowTeams[0] || !vm.masterFilter.ShowTeams[0].teamID)) {\r\n\t\t\t\ttoastr.error('Team required for Show', 'Error');\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.masterFilter.IncludeChoice === 4 && (!vm.masterFilter.IncludeUserTeams[0] || !vm.masterFilter.IncludeUserTeams[0].userID)) {\r\n\t\t\t\ttoastr.error('User required for Include', 'Error');\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.masterFilter.IncludeChoice === 5 && (!vm.masterFilter.IncludeTeams[0] || !vm.masterFilter.IncludeTeams[0].teamID)) {\r\n\t\t\t\ttoastr.error('Team required for Include', 'Error');\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.masterFilter.DateTimeChoice === 2 && !vm.masterFilter.DueWithinDays) {\r\n\t\t\t\tif (vm.masterFilter.DueWithinDays === undefined) {\r\n\t\t\t\t\ttoastr.error('\"Due Within Days\" should be less than 365', 'Error');\r\n\t\t\t\t} else {\r\n\t\t\t\t\ttoastr.error('\"Due Within Days\" is required', 'Error');\r\n\t\t\t\t}\r\n\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.masterFilter.UseLastActivityFilter) {\r\n\t\t\t\tif (vm.masterFilter.LastActivityFrom === undefined || vm.masterFilter.LastActivityTo === undefined) {\r\n\t\t\t\t\ttoastr.error('\"Last Activity\" fields should be less than 365', 'Error');\r\n\r\n\t\t\t\t\treturn true;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (vm.masterFilter.LastActivityFrom === null && vm.masterFilter.LastActivityTo === null) {\r\n\t\t\t\t\ttoastr.error('\"Last Activity\" fields should contain at least one value', 'Error');\r\n\r\n\t\t\t\t\treturn true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tif(vm.masterFilter.CompletedChoice == 1 && !vm.masterFilter.CompletedWithinDays) {\r\n\t\t\t\tif (vm.masterFilter.CompletedWithinDays === undefined) {\r\n\t\t\t\t\ttoastr.error('\"Completed Within Days\" should be less than 365', 'Error');\r\n\t\t\t\t} else {\r\n\t\t\t\t\ttoastr.error('\"Completed Within Days\" is required', 'Error');\r\n\t\t\t\t}\r\n\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\r\n\t\t\treturn false;\r\n\t\t}\r\n\r\n\t\tfunction setOrganizeAndGroupOptions() {\r\n\t\t\tvm.masterFilter.OrganizeBy = parseInt(vm.organizeBySelection);\r\n\t\t\tvm.masterFilter.GroupBy = [];\r\n\r\n\t\t\t//TODO set up \"pressing tasks\" flag once there's an API for it\r\n\t\t\tif (!vm.masterFilter.ShowMostPressingTasks) {\r\n\t\t\t\tvm.masterFilter.GroupBy.push(ActionViewGroupByTypes.TASKTYPE.id);\r\n\t\t\t}\r\n\t\t\tif (vm.groupBySelection) {\r\n\t\t\t\tvm.masterFilter.GroupBy.push(vm.groupBySelection);\r\n\t\t\t}\r\n\t\t}\r\n\r\n function defaultChosen() {\r\n vm.taskAssignmentApi.populateColumns();\r\n vm.masterFilter.persistCustomColumns = false;\r\n productAnalyticsService.logEvent('click-action-view-default-output');\r\n }\r\n\r\n function updateColumnFilters(filterColumns) {\r\n vm.filterColumns = filterColumns;\r\n }\r\n\r\n\t\tfunction customChosen() {\r\n\t\t\tif (vm.masterFilter.persistCustomColumns === undefined) {\r\n\t\t\t\tvm.masterFilter.persistCustomColumns = true;\r\n\t\t\t}\r\n productAnalyticsService.logEvent('click-action-view-custom-output');\r\n\t\t}\r\n\r\n\t\tfunction thatAreCompleted() {\r\n\t\t\treturn vm.masterFilter.ThatAreChoice === 4;\r\n\t\t}\r\n\r\n\t\tfunction activate() {\r\n\t\t\t// Promise is necessary for loading task assignment ready panel\r\n\t\t\t// after all appropriate data has loaded\r\n\t\t\tinitializePageState(false)\r\n\t\t\t\t.then(function(isById) {\r\n\t\t\t\t\tvm.dataLoaded = true;\r\n\r\n\t\t\t\t\tif(isById) {\r\n\t\t\t\t\t\twaitForApi().then(function (){\r\n\t\t\t\t\t\t\tvm.taskAssignmentApi.checkActionViewDefaultOutput().then(function (checkDefaultResult) {\r\n\t\t\t\t\t\t\t\tvm.filterColumns = checkDefaultResult.filterColumns;\r\n if (parseInt($stateParams.displayType)) {\r\n actionViewPersistenceService.filterColumns = angular.copy(vm.filterColumns);\r\n }\r\n\t\t\t\t\t\t\t});\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t}\r\n\t\t\t\t})\r\n\r\n\t\t\tvm.isSingleInstanceSelected = userInstanceService.isSingleInstanceSelected();\r\n\t\t}\r\n\r\n\t\tfunction setDisplayType(displayType) {\r\n\t\t\tswitch (displayType) {\r\n\t\t\t\tcase ActionViewDisplayTypes.FILTER:\r\n\t\t\t\t\tvm.showOverview = false;\r\n\t\t\t\t\tvm.showDetail = false;\r\n\t\t\t\t\tvm.showFilterPage = true;\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase ActionViewDisplayTypes.OVERVIEW:\r\n\t\t\t\t\tvm.filterToExecute = angular.copy(vm.masterFilter);\r\n\t\t\t\t\tvm.drilldownFilter = _.isEmpty(vm.originalFilter) ? angular.copy(vm.filterToExecute) : angular.copy(vm.originalFilter);\r\n\t\t\t\t\tvm.showOverview = true;\r\n\t\t\t\t\tvm.showDetail = false;\r\n\t\t\t\t\tvm.showFilterPage = false;\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase ActionViewDisplayTypes.DETAILED:\r\n\t\t\t\t\tvm.showOverview = false;\r\n\t\t\t\t\tvm.showDetail = true;\r\n\t\t\t\t\tvm.showFilterPage = false;\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tdefault:\r\n\t\t\t\t\tvm.showOverview = false;\r\n\t\t\t\t\tvm.showDetail = false;\r\n\t\t\t\t\tvm.showFilterPage = true;\r\n\t\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\r\n // HACK: I was occasionally getting errors where vm.taskAssignmentApi was undefined where it was\r\n // needed; a proper fix would be to restructure the AV ui, but as a workaround for now use timeout\r\n // to wait until vm.taskAssignemntApi is available\r\n\t\tfunction waitForApi() {\r\n\t\t var waitTime = 1;\r\n\t\t var numTries = 0;\r\n\t\t return $q(function (resolve) {\r\n\t\t var callback = function () {\r\n\t\t if (vm.taskAssignmentApi) {\r\n\t\t console.log('vm.taskAssignmentApi available');\r\n\t\t resolve();\r\n\t\t }\r\n\t\t else {\r\n\t\t if (numTries > 3) {\r\n\t\t throw new Error('vm.taskAssignmentApi unavailable');\r\n\t\t }\r\n\t\t console.log('vm.taskAssignmentApi unavailable; trying again');\r\n\t\t numTries++;\r\n\t\t waitTime = 500;\r\n\t\t $timeout(callback, 500);\r\n\t\t }\r\n\t\t };\r\n // Initially allow digest to finish and immediately allow execution to continue; if the value\r\n // isn't set yet, wait a half-second at a time until it is\r\n\t\t $timeout(callback, 1);\r\n\t\t });\r\n\t\t}\r\n\r\n\t\tfunction initializePageState() {\r\n\t\t\tvar deferred = $q.defer();\r\n\t\t\tvar displayType = parseInt($stateParams.displayType);\r\n\t\t\tvar actionViewId = parseInt($stateParams.actionViewId);\r\n\r\n\t\t\tvm.isSystemView = parseInt($stateParams.actionViewType) === ActionViewCategoryTypes.SYSTEM;\r\n\r\n\t\t\t//special case - if we are coming to a drilldown from an external page, like dashboard\r\n\t\t\tif(actionViewPersistenceService.externalDrilldown) {\r\n\t\t\t\tvm.source = \"externalDrilldown\";\r\n\t\t\t //This seemingly random variable is set to true so we can load the task assignment ready directive\r\n //This is important because it's where a lot of our business logic lives, and without this variable\r\n //it will not load and break the flow.\r\n\t\t\t vm.dataLoaded = true;\r\n\r\n\t\t\t waitForApi().then(function() {\r\n vm.masterFilter = angular.copy(actionViewPersistenceService.masterFilter);\r\n vm.originalFilter = angular.copy(actionViewPersistenceService.masterFilter);\r\n vm.taskAssignmentApi.checkActionViewDefaultOutput().then(function (checkDefaultResult) {\r\n vm.filterColumns = checkDefaultResult.filterColumns;\r\n vm.taskAssignmentApi.refreshData();\r\n setDisplayType(ActionViewDisplayTypes.OVERVIEW);\r\n\t\t\t\t\t});\r\n });\r\n\r\n\r\n }\r\n\t\t\t//if we are returning with a filter saved in a nub\r\n\t\t\telse if (!_.isEmpty(actionViewPersistenceService.masterFilter)) {\r\n\t\t\t\tvm.source = \"nub\";\r\n\t\t\t\tvm.isSavedSearch = (actionViewPersistenceService.routeParams.actionViewId !== '');\r\n\r\n\t\t\t\t//setup vars from service\r\n\t\t\t\tvm.masterFilter = angular.copy(actionViewPersistenceService.masterFilter);\r\n\t\t\t\tvm.filterToExecute = angular.copy(vm.masterFilter);\r\n\r\n\t\t\t\tvm.drilldownFilter = angular.copy(actionViewPersistenceService.drilldownFilter);\r\n\r\n\t\t\t\tif(vm.masterFilter.DetailedResults || (vm.drilldownFilter && vm.drilldownFilter.DetailedResults)) {\r\n displayType = ActionViewDisplayTypes.DETAILED;\r\n vm.detailedResults = actionViewPersistenceService.detailResults;\r\n } else {\r\n\t\t\t\t displayType = ActionViewDisplayTypes.OVERVIEW;\r\n }\r\n\r\n\t\t\t\tvm.drilldownMode = actionViewPersistenceService.drilldownMode;\r\n\t\t\t\tvm.filterColumns = angular.copy(actionViewPersistenceService.filterColumns);\r\n\t\t\t\t//vm.outputColumnsIds = actionViewPersistenceService.outputColumns;\r\n\t\t\t\tvm.organizeBySelection = vm.masterFilter.OrganizeBy;\r\n\t\t\t\tvm.showOrs = actionViewPersistenceService.showOrs;\r\n\t\t\t\tvm.actionView.actionViewName = actionViewPersistenceService.actionViewName;\r\n\r\n\t\t\t\t//two groupings\r\n\t\t\t\tif (!vm.masterFilter.ShowMostPressingTasks && (vm.masterFilter.GroupBy && vm.masterFilter.GroupBy.length > 1)) {\r\n\t\t\t\t\tvm.groupBySelection = vm.masterFilter.GroupBy[1].toString();\r\n\t\t\t\t}\r\n\t\t\t\t//one grouping that isn't most pressing\r\n\t\t\t\telse if (vm.masterFilter.GroupBy && vm.masterFilter.GroupBy.length > 0 && vm.masterFilter.ShowMostPressingTasks) {\r\n\t\t\t\t\tvm.groupBySelection = angular.copy(vm.masterFilter.GroupBy[0].toString());\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (vm.detailedResults) {\r\n\t\t\t\t\tsetDisplayType(displayType);\r\n\t\t\t\t} else if(!vm.masterFilter.DetailedResults) {\r\n\t\t\t\t\tgoToOverview();\r\n\t\t\t\t} else {\r\n\t\t\t\t\tgoToDetail();\r\n\t\t\t\t}\r\n\r\n\t\t\t\tdeferred.resolve();\r\n\r\n\t\t\t} else if (actionViewId) {\r\n\t\t\t\tactionViewPersistenceService.clearSavedData();\r\n\r\n\t\t\t\tvm.source = \"saved\";\r\n\r\n\t\t\t\t//if we are accessing this by id\r\n\t\t\t\tactionViewService.getCustomActionViewById(parseInt($stateParams.actionViewId))\r\n\t\t\t\t\t.then(function (result) {\r\n\t\t\t\t\t\tvar newCriteria = JSON.parse(result.criteria);\r\n\r\n\t\t\t\t\t\tvm.actionView = result;\r\n\r\n utils.convertDateStringsToDates(newCriteria);\r\n\t\t\t\t\t\tvm.masterFilter = _.cloneDeep(newCriteria.masterFilter);\r\n\r\n\t\t\t\t\t\tvm.filterColumns = _.chain(newCriteria.filters)\r\n\t\t\t\t\t\t\t.map(function(filter) {\r\n\t\t\t\t\t\t\t\tfilter.or = _.filter(filter.or, 'operator');\r\n\t\t\t\t\t\t\t\treturn filter;\r\n\t\t\t\t\t\t\t})\r\n\t\t\t\t\t\t\t.filter(function(filter) {\r\n\t\t\t\t\t\t\t\treturn filter.or.length;\r\n\t\t\t\t\t\t\t})\r\n\t\t\t\t\t\t\t.value();\r\n\r\n\t\t\t\t\t\t//vm.outputColumnsIds = newCriteria.outputColumns;\r\n\t\t\t\t\t\tvm.organizeBySelection = vm.masterFilter.OrganizeBy;\r\n\t\t\t\t\t\tvm.showOrs = vm.masterFilter.showOrs || false;\r\n\r\n\t\t\t\t\t\tif (displayType === 2) {\r\n\t\t\t\t\t\t\tvm.masterFilter.DetailedResults = true;\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tif (vm.masterFilter.GroupBy) {\r\n\t\t\t\t\t\t\t//two groupings\r\n\t\t\t\t\t\t\tif (!vm.masterFilter.ShowMostPressingTasks && vm.masterFilter.GroupBy.length > 1) {\r\n\t\t\t\t\t\t\t\tvm.groupBySelection = vm.masterFilter.GroupBy[1];\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t//one grouping\r\n\t\t\t\t\t\t\telse if (vm.masterFilter.GroupBy && vm.masterFilter.GroupBy.length > 0 && vm.masterFilter.ShowMostPressingTasks) {\r\n\t\t\t\t\t\t\t\tvm.groupBySelection = angular.copy(vm.masterFilter.GroupBy[0]);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tsetDisplayType(displayType);\r\n\r\n\t\t\t\t\t\tvar outputColumns = _.chain(vm.masterFilter.TaskOutputColumns)\r\n\t\t\t\t\t\t\t.union(vm.masterFilter.EntityOutputColumns)\r\n\t\t\t\t\t\t\t.cloneDeep()\r\n\t\t\t\t\t\t\t.value();\r\n\r\n\t\t\t\t\t\tvm.invalidColumns = advancedSearchService.getInvalidColumns(outputColumns)\r\n\r\n\t\t\t\t\t\tdeferred.resolve(true);\r\n\t\t\t\t\t});\r\n\t\t\t} else {\r\n\t\t\t\tvm.source = \"new\";\r\n\r\n\t\t\t\t//if it's a new filter, create an empty object\r\n\t\t\t\tactionViewPersistenceService.clearSavedData();\r\n\t\t\t\tvm.masterFilter = {\r\n\t\t\t\t\tShowChoice: 2,\r\n\t\t\t\t\tWhereChoice: 1,\r\n\t\t\t\t\tThatAreChoice: 1,\r\n\t\t\t\t\tShowUserTeams: [{}],\r\n\t\t\t\t\tShowTeams: [{}],\r\n\t\t\t\t\tIncludeUnscheduled: true,\r\n\t\t\t\t\tIncludeUserTeams: [{}],\r\n\t\t\t\t\tIncludeTeams: [{}],\r\n\t\t\t\t\toutput: 'default',\r\n\t\t\t\t\tDateTimeChoice: 2,\r\n\t\t\t\t\tDueWithinDays: 90,\r\n\t\t\t\t\tCompletedChoice: 1,\r\n\t\t\t\t\tCompletedWithinDays: 30,\r\n\t\t\t\t\tIncludeChoice: 1,\r\n\t\t\t\t\tComposeDynamicSql: true,\r\n\t\t\t\t\tLastActivityTo: null,\r\n\t\t\t\t\tLastActivityFrom: null,\r\n\t\t\t\t\tincludeSkipped: true\r\n\t\t\t\t};\r\n\r\n\t\t\t\tvm.organizeBySelection = 1;\r\n\t\t\t\tvm.groupBySelection = undefined;\r\n\t\t\t\tvm.showFilterPage = true;\r\n\r\n\t\t\t\tdeferred.resolve();\r\n\t\t\t}\r\n\r\n\t\t\treturn deferred.promise;\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller('CustomOutputModalController', CustomOutputModalController);\r\n\r\n\tCustomOutputModalController.$inject = [\r\n '$uibModalInstance',\r\n 'taskTypeName',\r\n 'systemColumns',\r\n 'userColumns',\r\n 'fromActionView',\r\n\t\t'selectedTaskType'\r\n\t];\r\n\r\n\tfunction CustomOutputModalController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit($uibModalInstance, taskTypeName, systemColumns, userColumns, fromActionView, selectedTaskType) {\r\n\t\tvar vm = this;\r\n\r\n\t\tactivate();\r\n\r\n\t\t////////////////\r\n\r\n\t\tfunction activate() {\r\n\t\t\tvm.fromActionView = fromActionView;\r\n\t\t\tvm.taskTypeName = taskTypeName === 'All' ? 'All Task Types': taskTypeName;\r\n\t\t\tvm.selectedTaskType = selectedTaskType;\r\n\r\n\t\t\tvar filterColumns = userColumns.length ? userColumns : systemColumns;\r\n\t\t\tvm.category = {\r\n\t\t\t\tcolumns: _.chain(filterColumns)\r\n\t\t\t\t\t.map(function(column) {\r\n\t\t\t\t\t\tcolumn.isRemovable = true\r\n\t\t\t\t\t\treturn column;\r\n\t\t\t\t\t})\r\n\t\t\t\t\t.sortBy('sequence')\r\n\t\t\t\t\t.value(),\r\n\t\t\t\tdefaultColumns: systemColumns\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tvm.cancel = function () {\r\n\t\t\t$uibModalInstance.dismiss();\r\n\t\t}\r\n\r\n\t\tvm.save = function () {\r\n\t\t\tif(!vm.category.columns.length) {\r\n\t\t\t\t$uibModalInstance.close([]);\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tvar idProperty = vm.category.columns[0].columnId ? 'columnId' : 'advancedSearchFieldID'\r\n\t\t\tvar useSystem = _.xorBy(vm.category.columns, vm.category.defaultColumns, idProperty).length == 0;\r\n\r\n\t\t\tvm.category.columns = _.map(vm.category.columns, function(col, i) {\r\n\t\t\t\tcol.sequence = i;\r\n\t\t\t\treturn col;\r\n\t\t\t})\r\n\r\n\t\t\tvar columns = useSystem && !vm.fromActionView ? [] : vm.category.columns;\r\n\t\t\t$uibModalInstance.close(columns)\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('dateTimePanel', dateTimePanel);\r\n\r\n\tdateTimePanel.$inject = [];\r\n\r\n\tfunction dateTimePanel() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\ttemplateUrl: 'app/Task/ActionView/Filters/_dateTimePanel.html',\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tmasterFilter: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n\r\n\tController.$inject = ['actionViewService', '$timeout', 'productAnalyticsService'];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(actionViewService, $timeout, productAnalyticsService) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.urgencies = actionViewService.getUrgencies();\r\n\r\n\t\tvm.dueDateFromOptions = {\r\n\t\t\tminDate: moment('2000-01-01').toDate(),\r\n\t\t\tmaxDate: dateHack(vm.masterFilter.DueDateTo)\r\n\t\t};\r\n\r\n\t\tvm.dueDateToOptions = {\r\n\t\t\tminDate: dateHack(vm.masterFilter.DueDateFrom)\r\n\t\t};\r\n\r\n\t\tvm.completedDateFromOptions = {\r\n\t\t\tminDate: moment('2000-01-01').toDate(),\r\n\t\t\tmaxDate: dateHack(vm.masterFilter.CompletedDateTo)\r\n\t\t};\r\n\r\n\t\tvm.completedDateToOptions = {\r\n\t\t\tminDate: dateHack(vm.masterFilter.CompletedDateFrom)\r\n\t\t};\r\n\r\n\t\tvm.dueDateFromChanged = function () {\r\n\t\t\t$timeout(function () {\r\n\t\t\t\tif (!vm.masterFilter.DueDateFrom) {\r\n\t\t\t\t\tvm.dueDateToOptions.minDate = null;\r\n\t\t\t\t\tvm.dueDateToOptions.initDate = null;\r\n\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tvm.dueDateToOptions.minDate = dateHack(vm.masterFilter.DueDateFrom);\r\n\t\t\t\tvm.dueDateToOptions.initDate = dateHack(vm.masterFilter.DueDateFrom);\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\tvm.dueDateToChanged = function () {\r\n\t\t\t$timeout(function () {\r\n\t\t\t\tif (!vm.masterFilter.DueDateTo) {\r\n\t\t\t\t\tvm.dueDateFromOptions.maxDate = null;\r\n\t\t\t\t\tvm.dueDateFromOptions.initDate = null;\r\n\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tvm.dueDateFromOptions.maxDate = dateHack(vm.masterFilter.DueDateTo);\r\n\t\t\t\tvm.dueDateFromOptions.initDate = dateHack(vm.masterFilter.DueDateTo);\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\tvm.completedDateFromChanged = function () {\r\n\t\t\t$timeout(function () {\r\n\t\t\t\tif (!vm.masterFilter.CompletedDateFrom) {\r\n\t\t\t\t\tvm.completedDateToOptions.minDate = null;\r\n\t\t\t\t\tvm.completedDateToOptions.initDate = null;\r\n\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tvm.completedDateToOptions.minDate = dateHack(vm.masterFilter.CompletedDateFrom);\r\n\t\t\t\tvm.completedDateToOptions.initDate = dateHack(vm.masterFilter.CompletedDateFrom);\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\tvm.completedDateToChanged = function () {\r\n\t\t\t$timeout(function () {\r\n\t\t\t\tif (!vm.masterFilter.CompletedDateTo) {\r\n\t\t\t\t\tvm.completedDateFromOptions.maxDate = null;\r\n\t\t\t\t\tvm.completedDateFromOptions.initDate = null;\r\n\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tvm.completedDateFromOptions.maxDate = dateHack(vm.masterFilter.CompletedDateTo);\r\n\t\t\t\tvm.completedDateFromOptions.initDate = dateHack(vm.masterFilter.CompletedDateTo);\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\tvm.includeUnscheduledChanged = function () {\r\n\t\t\tif (!vm.masterFilter.IncludeUnscheduled) {\r\n\t\t\t\tvm.masterFilter.OnlyUnscheduled = false;\r\n\t\t\t}\r\n productAnalyticsService.logEvent('click-action-view-include-unscheduled', { includeUnscheduled: vm.masterFilter.IncludeUnscheduled });\r\n\t\t}\r\n\r\n vm.includeOnlyUnscheduledChanged = function () {\r\n productAnalyticsService.logEvent('click-action-view-only-unscheduled', { onlyUnscheduled: vm.masterFilter.OnlyUnscheduled });\r\n }\r\n\r\n\t\tvm.includeSkippedChanged = function () {\r\n\t\t\tif (!vm.masterFilter.includeSkipped) {\r\n\t\t\t\tvm.masterFilter.onlySkipped = false;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tvm.validateLastActivityFrom = function () {\r\n\t\t\tif (!vm.masterFilter.LastActivityFrom || !vm.masterFilter.LastActivityTo) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.masterFilter.LastActivityFrom > vm.masterFilter.LastActivityTo) {\r\n\t\t\t\tvm.lastActivityFromTooltip = true;\r\n\t\t\t\tvm.masterFilter.LastActivityFrom = null;\r\n\t\t\t} else {\r\n\t\t\t\tvm.lastActivityFromTooltip = false;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tvm.validateLastActivityTo = function () {\r\n\t\t\tif (!vm.masterFilter.LastActivityFrom || !vm.masterFilter.LastActivityTo) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tif (vm.masterFilter.LastActivityTo < vm.masterFilter.LastActivityFrom) {\r\n\t\t\t\tvm.lastActivityToTooltip = true;\r\n\t\t\t\tvm.masterFilter.LastActivityTo = null;\r\n\t\t\t} else {\r\n\t\t\t\tvm.lastActivityToTooltip = false;\r\n\t\t\t}\r\n\t\t}\r\n\r\n vm.whenOptionChanged = function () {\r\n let optionSelected = '';\r\n switch (vm.masterFilter.DateTimeChoice) {\r\n case 1:\r\n optionSelected = 'All Dates';\r\n break;\r\n case 2:\r\n optionSelected = 'Within # Days';\r\n break;\r\n case 3:\r\n optionSelected = 'Due Date Range';\r\n break;\r\n }\r\n productAnalyticsService.logEvent('click-action-view-task-due-date', { taskAssignmentDue: optionSelected });\r\n }\r\n\r\n\t\tvm.populateDueWithin = function () {\r\n\t\t\tvm.masterFilter.DueWithinDays = vm.masterFilter.DueWithinDays || 120;\r\n vm.whenOptionChanged();\r\n\t\t}\r\n\r\n vm.urgencyChanged = function () {\r\n productAnalyticsService.logEvent('click-action-view-urgency', { urgencyLevel: vm.urgencies.find(x => x.id === vm.masterFilter.UrgencyChoice)?.display });\r\n }\r\n\r\n\t\tvm.populateUrgency = function () {\r\n\t\t\tvm.masterFilter.UrgencyChoice = vm.masterFilter.UseUrgencyFilter ? 1 : undefined;\r\n\r\n if (vm.masterFilter.UrgencyChoice) {\r\n vm.urgencyChanged();\r\n }\r\n\t\t}\r\n\r\n vm.lastActivityToggled = function () {\r\n productAnalyticsService.logEvent('click-action-view-last-activity');\r\n }\r\n\r\n\t // We reason with dates in UTC, but the angular-bootstrap datepicker is designed to work in local. We have\r\n\t // hooks in place in our picker wrapper to deal with getting/setting dates in UTC, but the minDate/initDate\r\n\t // code requires us to convert UTC to local. This \"dateHack\" function does exactly that, producing a date\r\n // suitable for use in those fields.\r\n\t\tfunction dateHack(inputDate) {\r\n\t\t if (!inputDate) { return inputDate; }\r\n\t\t var origMoment = moment.utc(inputDate);\r\n\t\t if (!origMoment.isValid()) { return inputDate; }\r\n\t\t return moment(origMoment.format(\"YYYY-MM-DD\")).toDate();\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('multiUserTeamPicker', multiUserTeamPicker);\r\n\r\n\tmultiUserTeamPicker.$inject = [];\r\n\r\n\tfunction multiUserTeamPicker() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Task/ActionView/Filters/_multiUserTeamPicker.html',\r\n\t\t\tscope: {\r\n\t\t\t\ttoBePickedArray: '=',\r\n\t\t\t\tteamOnly: '=',\r\n userOnly: '=?',\r\n\t\t\t\tincludeInactiveContacts: '=?'\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs, vm) {\r\n\t\t if (attrs.userOnly === \"\") {\r\n\t\t vm.userOnly = true;\r\n\t\t }\r\n\t\t}\r\n\t}\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit() {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.addItem = function () {\r\n\t\t\tvm.toBePickedArray.push({});\r\n\t\t}\r\n\r\n\t\tvm.removeItem = function (item) {\r\n\t\t\t_.remove(vm.toBePickedArray, item);\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory('plainEnglishService', plainEnglishService);\r\n\r\n\tplainEnglishService.$inject = ['actionViewService', 'actionViewPersistenceService', 'searchOperators'];\r\n\r\n\tfunction plainEnglishService(actionViewService, actionViewPersistenceService, searchOperators) {\r\n\t\tvar service = {\r\n\t\t\tgetForFilter: getForFilter\r\n\t\t};\r\n\t\treturn service;\r\n\r\n\t\t////////////////\r\n\r\n\t\tfunction getForFilter(filter, filterColumns) {\r\n\t\t\tvar str = '';\r\n\r\n\t\t\tif (!filter.taskTypeName || filter.taskTypeName === 'All') {\r\n\t\t\t\tstr += 'All ';\r\n\t\t\t}\r\n\r\n\t\t\tstr += getShowText();\r\n\t\t\tstr += getTaskTypeText();\r\n\t\t\tstr += ' ' + getWhereText();\r\n\t\t\tstr += ' ' + getThatAreText();\r\n\r\n\t\t\tif (filter.ThatAreChoice === 4) {\r\n\t\t\t\tstr += getIncludeText();\r\n\t\t\t\tstr += getCompletedDateText();\r\n\t\t\t}\r\n\r\n\t\t\tstr += getDateText();\r\n\t\t\tstr += getUrgencyText();\r\n\r\n\t\t\tif (filter.IncludeUnscheduled) {\r\n\t\t\t\tstr += filter.OnlyUnscheduled ? ' AND only' : ' OR';\r\n\t\t\t\tstr += ' Unscheduled';\r\n\t\t\t}\r\n\r\n\t\t\tif (filter.UseLastActivityFilter && (_.isNumber(filter.LastActivityTo) || _.isNumber(filter.LastActivityFrom))) {\r\n\t\t\t\tstr += getLastActivity();\r\n\t\t\t}\r\n\r\n\t\t\tvar columnsWithValue = _.filter(filterColumns, function (column) {\r\n\t\t\t\treturn _.chain(column.or)\r\n\t\t\t\t\t.map(function(or) {\r\n\t\t\t\t\t\treturn or.value || (or.operator && (or.operator.name === 'blank' || or.operator.name === 'notBlank' || or.operator.name === 'isNA'));\r\n\t\t\t\t\t})\r\n\t\t\t\t\t.compact()\r\n\t\t\t\t\t.value()\r\n\t\t\t\t\t.length;\r\n\t\t\t});\r\n\r\n\t\t\tif (filter.filters && filter.filters.length && actionViewPersistenceService.drilldownMode) {\r\n\t\t\t\tstr += getFilterText(filter.filters);\r\n\t\t\t} else if (columnsWithValue.length) {\r\n\t\t\t\tstr += getFilterText(columnsWithValue)\r\n\t\t\t}\r\n\r\n\t\t\treturn str;\r\n\r\n\r\n\t\t\t// Functions for getForFilter()\r\n\t\t\tfunction getShowText() {\r\n\t\t\t\tswitch (filter.ShowChoice) {\r\n\t\t\t\t\tcase 1:\r\n\t\t\t\t\t\treturn '';\r\n\r\n\t\t\t\t\tcase 2:\r\n\t\t\t\t\t\treturn 'My';\r\n\r\n\t\t\t\t\tcase 3:\r\n\t\t\t\t\t\treturn \"My team's\";\r\n\r\n\t\t\t\t\tcase 4:\r\n\t\t\t\t\t\treturn getUserTeamText(filter.ShowUserTeams);\r\n\r\n\t\t\t\t\tcase 5:\r\n\t\t\t\t\t\treturn getTeamText(filter.ShowTeams)\r\n\r\n\t\t\t\t\tdefault:\r\n\t\t\t\t\t\treturn '';\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction getUserTeamText(userTeams) {\r\n\t\t\t\tuserTeams = _.filter(userTeams, 'userID');\r\n\r\n\t\t\t\tif (!userTeams.length) {\r\n\t\t\t\t\treturn \"Specific Individual's\";\r\n\t\t\t\t}\r\n\r\n\t\t\t\treturn _.reduce(userTeams, function (str, userTeam, i) {\r\n\r\n\t\t\t\t\tif (userTeam.user) {\r\n\t\t\t\t\t\tstr += userTeam.user.firstName + ' ' + userTeam.user.lastName;\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tstr += userTeam.name;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif (i === userTeams.length - 2) {\r\n\t\t\t\t\t\tstr += ' and ';\r\n\t\t\t\t\t} else if (i === userTeams.length - 1) {\r\n\t\t\t\t\t\tstr += \"'s\"\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tstr += ', ';\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\treturn str;\r\n\t\t\t\t}, '');\r\n\t\t\t}\r\n\r\n\t\t\tfunction getTeamText(teams) {\r\n\t\t\t\tvar teams = _.filter(teams, 'teamID');\r\n\r\n\t\t\t\tif (!teams.length) {\r\n\t\t\t\t\treturn \"Specific team's\";\r\n\t\t\t\t}\r\n\r\n\t\t\t\treturn _.reduce(teams, function (str, team, i) {\r\n\t\t\t\t\tstr += team.team ? team.team.name : team.name;\r\n\r\n\t\t\t\t\tif (i === teams.length - 2) {\r\n\t\t\t\t\t\tstr += ' and ';\r\n\t\t\t\t\t} else if (i === teams.length - 1) {\r\n\t\t\t\t\t\tstr += \"'s\"\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tstr += ', ';\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\treturn str;\r\n\t\t\t\t}, '');\r\n\t\t\t}\r\n\r\n\t\t\tfunction getTaskTypeText() {\r\n\t\t\t\tif (filter.taskTypeName === 'All' || filter.taskTypeName === undefined) {\r\n\t\t\t\t\treturn '';\r\n\t\t\t\t} else {\r\n\t\t\t\t\treturn ' ' + filter.taskTypeName + ''\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction getWhereText() {\r\n\t\t\t\tswitch (filter.WhereChoice) {\r\n\t\t\t\t\tcase 1:\r\n\t\t\t\t\t\treturn 'assigned tasks';\r\n\t\t\t\t\tcase 2:\r\n\t\t\t\t\t\treturn 'tasks where ultimately responsible';\r\n\t\t\t\t\tcase 3:\r\n\t\t\t\t\t\treturn 'assigned tasks or tasks where ultimately responsible';\r\n\t\t\t\t\tcase 4:\r\n\t\t\t\t\t\treturn 'tasks for companies where account handler';\r\n\t\t\t\t\tcase 5:\r\n\t\t\t\t\t\treturn 'tasks for companies where Compliance Returns PP Resp';\r\n\t\t\t\t\tdefault:\r\n\t\t\t\t\t\treturn 'Tasks';\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction getThatAreText() {\r\n\t\t\t\tvar str = 'that are ';\r\n\t\t\t\tswitch (filter.ThatAreChoice) {\r\n\t\t\t\t\tcase 1:\r\n\t\t\t\t\t\treturn str + 'READY';\r\n\t\t\t\t\tcase 2:\r\n\t\t\t\t\t\treturn str + 'NOT READY';\r\n\t\t\t\t\tcase 3:\r\n\t\t\t\t\t\treturn str + 'READY or NOT READY'\r\n\t\t\t\t\tcase 4:\r\n\t\t\t\t\t\treturn str + '';\r\n\t\t\t\t\tdefault:\r\n\t\t\t\t\t\treturn '';\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction getIncludeText() {\r\n\t\t\t\tif (filter.includeSkipped && filter.onlySkipped) {\r\n\t\t\t\t\tstr = 'skipped';\r\n\t\t\t\t} else {\r\n\t\t\t\t\tstr = 'completed';\r\n\r\n\t\t\t\t\tif(filter.includeSkipped) {\r\n\t\t\t\t\t\tstr += ' OR skipped';\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tswitch (filter.IncludeChoice) {\r\n\t\t\t\t\tcase 1:\r\n\t\t\t\t\t\treturn str;\r\n\r\n\t\t\t\t\tcase 2:\r\n\t\t\t\t\t\treturn str + ' by me';\r\n\r\n\t\t\t\t\tcase 3:\r\n\t\t\t\t\t\treturn str + ' by my team';\r\n\r\n\t\t\t\t\tcase 4:\r\n\t\t\t\t\t\tvar includeUserTeams = _.filter(filter.IncludeUserTeams, 'userID');\r\n\t\t\t\t\t\tstr += ' by ';\r\n\r\n\t\t\t\t\t\tif (!includeUserTeams.length) {\r\n\t\t\t\t\t\t\treturn str + \"a Specific Individual\";\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\treturn str += _.reduce(includeUserTeams, function (str, userTeam, i) {\r\n\t\t\t\t\t\t\tif (userTeam.user) {\r\n\t\t\t\t\t\t\t\tstr += userTeam.user.firstName + ' ' + userTeam.user.lastName;\r\n\t\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t\tstr += userTeam.name;\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tif (i === includeUserTeams.length - 2) {\r\n\t\t\t\t\t\t\t\tstr += ' and ';\r\n\t\t\t\t\t\t\t} else if (i !== includeUserTeams.length - 1) {\r\n\t\t\t\t\t\t\t\tstr += ', ';\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\treturn str;\r\n\t\t\t\t\t\t}, '');\r\n\r\n\t\t\t\t\tcase 5:\r\n\t\t\t\t\t\tvar includeTeams = _.filter(filter.IncludeTeams, 'teamID');\r\n\t\t\t\t\t\tstr += ' by ';\r\n\r\n\t\t\t\t\t\tif (!includeTeams.length) {\r\n\t\t\t\t\t\t\treturn str + \"a Specific Team\";\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\treturn str + _.reduce(includeTeams, function (str, team, i) {\r\n\t\t\t\t\t\t\tstr += team.team ? team.team.name : team.name;\r\n\r\n\t\t\t\t\t\t\tif (i === includeTeams.length - 2) {\r\n\t\t\t\t\t\t\t\tstr += ' and ';\r\n\t\t\t\t\t\t\t} else if (i !== includeTeams.length - 1) {\r\n\t\t\t\t\t\t\t\tstr += ', ';\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\treturn str;\r\n\t\t\t\t\t\t}, '');\r\n\r\n\t\t\t\t\tdefault:\r\n\t\t\t\t\t\treturn '';\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction getCompletedDateText() {\r\n\t\t\t\tvar str = '';\r\n\r\n\t\t\t\tif(filter.CompletedChoice == 0) {\r\n\t\t\t\t\tif (filter.CompletedDateFrom) {\r\n\t\t\t\t\t\tstr += ' on or after ' + moment.utc(filter.CompletedDateFrom).format('M/D/YYYY') + ' '\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (filter.CompletedDateTo) {\r\n\t\t\t\t\t\tif (filter.CompletedDateFrom) {\r\n\t\t\t\t\t\t\tstr += ' and';\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tstr += ' by ' + moment.utc(filter.CompletedDateTo).format('M/D/YYYY');\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if(filter.CompletedChoice == 1 ) {\r\n\t\t\t\t\tif (filter.CompletedWithinDays) {\r\n\t\t\t\t\t\tstr += ' within the last ' + filter.CompletedWithinDays + ' days';\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\treturn str;\r\n\t\t\t}\r\n\r\n\t\t\tfunction getDateText() {\r\n\r\n\t\t\t\tif (filter.OnlyUnscheduled) {\r\n\t\t\t\t\treturn '';\r\n\t\t\t\t}\r\n\r\n\t\t\t\tswitch (filter.DateTimeChoice) {\r\n\t\t\t\t\tcase 1:\r\n\t\t\t\t\t\treturn '';\r\n\r\n\t\t\t\t\tcase 2:\r\n\t\t\t\t\t\tif (!filter.DueWithinDays) {\r\n\t\t\t\t\t\t\treturn '';\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\treturn ' and due within the next ' + filter.DueWithinDays + ' days';\r\n\r\n\t\t\t\t\tcase 3:\r\n\t\t\t\t\t\tvar str = '';\r\n\r\n\t\t\t\t\t\tif (filter.DueDateFrom && moment.utc(filter.DueDateFrom).isAfter(moment.utc(new Date()).subtract(40, 'years'), 'year')) {\r\n\t\t\t\t\t\t\tstr += ' and due on or after ' + moment.utc(filter.DueDateFrom).format('M/D/YYYY') + ' '\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tif (filter.DueDateTo && moment.utc(filter.DueDateTo).isBefore(moment.utc(new Date()).add(30, 'years'), 'year')) {\r\n\t\t\t\t\t\t\tstr += ' and due by ' + moment.utc(filter.DueDateTo).format('M/D/YYYY');\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\treturn str;\r\n\r\n\t\t\t\t\tdefault:\r\n\t\t\t\t\t\treturn '';\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction getUrgencyText() {\r\n\t\t\t\tif (!filter.UseUrgencyFilter) {\r\n\t\t\t\t\treturn '';\r\n\t\t\t\t}\r\n\r\n\t\t\t\tvar urgencies = actionViewService.getUrgencies();\r\n\t\t\t\tvar urgency = _.find(urgencies, { id: filter.UrgencyChoice });\r\n\r\n\t\t\t\treturn ' with an urgency of ' + urgency.display;\r\n\t\t\t}\r\n\r\n\t\t\tfunction getLastActivity() {\r\n\t\t\t\tvar str = ', and last activity is ';\r\n\r\n\t\t\t\tif (filter.LastActivityTo === 0 && filter.LastActivityFrom === 0) {\r\n\t\t\t\t\treturn str + 'today';\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (filter.LastActivityTo === null) {\r\n\t\t\t\t\tstr += 'greater than ' + filter.LastActivityFrom\r\n\t\t\t\t} else if (filter.LastActivityFrom === null) {\r\n\t\t\t\t\tstr += 'up to ' + filter.LastActivityTo;\r\n\t\t\t\t} else if (filter.LastActivityTo === filter.LastActivityFrom) {\r\n\t\t\t\t\tstr += filter.LastActivityTo;\r\n\t\t\t\t} else if (filter.LastActivityTo === 9999) {\r\n\t\t\t\t\tstr += filter.LastActivityFrom + '+';\r\n\t\t\t\t} else {\r\n\t\t\t\t\tstr += filter.LastActivityFrom + ' to ' + filter.LastActivityTo;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tstr += ' days ago';\r\n\r\n\t\t\t\treturn str;\r\n\t\t\t}\r\n\r\n\t\t\tfunction getFilterText(filters) {\r\n\t\t\t\tvar str = '; further limited by ';\r\n\t\t\t\tvar operators = searchOperators.displayNameMap();\r\n\r\n\t\t\t\tstr += _.reduce(filters, function (str, column, i) {\r\n\t\t\t\t\tstr += i > 0 ? ' AND ' : '';\r\n\t\t\t\t\tstr += column.resultColumnName || column.resultsColumnName;\r\n\r\n\t\t\t\t\tstr += _.reduce(column.or, function (str, or, i) {\r\n\t\t\t\t\t\tvar operator;\r\n\r\n\t\t\t\t\t\tif (_.isObject(or.operator)) {\r\n\t\t\t\t\t\t\toperator = or.operator;\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\toperator = operators[or.operator]\r\n\t\t\t\t\t\t\toperator.name = or.operator;\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tstr += i > 0 ? ' OR ' : ' ';\r\n\t\t\t\t\t\tif (operator.displayName) {\r\n\t\t\t\t\t\t\tstr += operator.name === 'isNA' ? _.lowerFirst(operator.displayName) : operator.displayName.toLowerCase();\r\n\r\n\t\t\t\t\t\t\tif (operator.name !== 'blank' && operator.name !== 'notBlank' && operator.name !== 'nullable' && operator.name !== 'isNA') {\r\n\t\t\t\t\t\t\t\tstr += ' ';\r\n\r\n\t\t\t\t\t\t\t\tif(_.isDate(or.value)) {\r\n\t\t\t\t\t\t\t\t\tstr += moment.utc(or.value).format('M/D/YYYY');\r\n\t\t\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t\t\tstr += or.value;\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\tif(operator.name === 'withinDate') {\r\n\t\t\t\t\t\t\t\t\tstr += ' days';\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\tstr += '';\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\treturn str;\r\n\t\t\t\t\t}, '');\r\n\r\n\t\t\t\t\treturn str;\r\n\t\t\t\t}, '');\r\n\r\n\t\t\t\treturn str;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('taskAssignmentReadyPanel', taskAssignmentReadyPanel);\r\n\r\n\ttaskAssignmentReadyPanel.$inject = [];\r\n\r\n\tfunction taskAssignmentReadyPanel() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\ttemplateUrl: 'app/Task/ActionView/Filters/_taskAssignmentReadyPanel.html',\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tmasterFilter: '=',\r\n\t\t\t\tfilterColumns: '=',\r\n\t\t\t\tapi: '=',\r\n\t\t\t\ttaskTypes: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n\r\n\tController.$inject = [\r\n\t\t'actionViewService',\r\n\t\t'searchOperators',\r\n\t\t'SD.Restrict.Service',\r\n\t\t'$scope',\r\n\t\t'advancedSearchService',\r\n\t\t'sd.Account.User.Settings.Service',\r\n\t\t'sd.Account.User.Service',\r\n\t\t'actionViewPersistenceService',\r\n\t\t'sd.Authentication.Service',\r\n\t\t'InstanceRights',\r\n\t\t'userInstanceService',\r\n 'TaskTypes',\r\n 'productAnalyticsService'\r\n\t]\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(\r\n\t\tactionViewService,\r\n\t\tsearchOperators,\r\n\t\trestrictService,\r\n\t\t$scope,\r\n\t\tadvancedSearchService,\r\n\t\tuserSettingsService,\r\n\t\tuserService,\r\n\t\tactionViewPersistenceService,\r\n\t\tauthenticationService,\r\n\t\tInstanceRights,\r\n\t\tuserInstanceService,\r\n TaskTypes,\r\n productAnalyticsService) {\r\n\r\n\t\tvar vm = this;\r\n\t\tvar taskTypeColumns = [];\r\n\t\tvar allFields;\r\n\t\tvar customTaskTypes = [];\r\n\t\tvar resolveTasksAndFieldsDeferred;\r\n\r\n\t\tvm.taskTypes = [];\r\n\t\t_.assign(vm, actionViewService.getTasksAssignmentReadyOptions());\r\n\r\n\t\tvm.taskTypeChanged = taskTypeChanged;\r\n\r\n\t\tvm.api = {\r\n\t\t\tpopulateColumns: taskTypeChanged,\r\n\t\t\tsetOutputs: setOutputs,\r\n\t\t\trefreshData: activate,\r\n\t\t\tcheckActionViewDefaultOutput: checkActionViewDefaultOutput,\r\n\t\t\tresolveDefaultOutput: resolveDefaultOutput,\r\n prepareCriteriaFromLoad: prepareCriteriaFromLoad,\r\n taskTypeChanged: taskTypeChanged\r\n\t\t};\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n //Dima: this call is to ensure that the user has permissions to execute the action view.\r\n // See issue [WK-3318 'No permission to view this page' warning is only displayed on 2nd try] for additional details\r\n /*var actionViewId = parseInt($stateParams.actionViewId);\r\n if (actionViewId){\r\n actionViewService.getCustomActionViewById(actionViewId);\r\n\t\t\t}*/\r\n\r\n\t\t\tvar userInstances = userInstanceService.getUserInstanceMembership();\r\n\t\t\tvm.hasPermission = _.some(userInstances, x => restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW, x.instanceId));\r\n\r\n\t\t\tif (!vm.hasPermission) {\r\n\t\t\t\tauthenticationService.getUserInfo()\r\n\t\t\t\t\t.then(function(userData) {\r\n\t\t\t\t\t\tvm.userInfo = userData;\r\n\r\n\t\t\t\t\t\tif(!vm.userInfo.isTeamMemberAndAssignable) {\r\n\t\t\t\t\t\t\tvm.masterFilter.ShowChoice = vm.showOptions['allTasks'].id\r\n\t\t\t\t\t\t\tvm.masterFilter.WhereChoice = undefined;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t});\r\n\t\t\t}\r\n\r\n resolveTasksAndFieldsDeferred = actionViewService.getTaskTypes()\r\n\t\t\t\t.then(function (taskTypeResult) {\r\n\t\t\t\t\tconsole.log('taskTypeResult', taskTypeResult);\r\n\r\n if (userInstanceService.isSingleInstanceSelected() &&\r\n !(userInstanceService.isCurrentInstanceRyan() || userInstanceService.isCurrentInstanceSystem())) {\r\n const invoiceAppealSavingsTaskIndex = taskTypeResult.taskTypes.indexOf(x => x.taskTypeID === TaskTypes.INVOICEAPPEALSAVINGS);\r\n taskTypeResult.taskTypes.splice(invoiceAppealSavingsTaskIndex, 1);\r\n }\r\n\r\n\t\t\t\t\ttaskTypeColumns = taskTypeResult.columns;\r\n\r\n\t\t\t\t\treturn advancedSearchService.getAllFields()\r\n\t\t\t\t\t\t.then(function (fieldsResult) {\r\n\t\t\t\t\t\t\tallFields = fieldsResult;\r\n\r\n\t\t\t\t\t\t\tvar userSetting = userSettingsService.getSettingsByGroup(12)[0];\r\n\r\n\t\t\t\t\t\t\tif (userSetting) {\r\n\t\t\t\t\t\t\t\tcustomTaskTypes = angular.fromJson(userSetting.value);\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tvm.taskTypes = actionViewService.sortTaskTypes(taskTypeResult.taskTypes);\r\n\r\n\t\t\t\t\t\t\t//Temporary fix, removing ID 1 aka PP Compliance, since there's no viabel tasks\r\n\t\t\t\t\t\t\t//vm.taskTypes = _.reject(vm.taskTypes, { 'taskSeriesTypeID': 1});\r\n\r\n\t\t\t\t\t\t\tif (vm.masterFilter.taskTypeID !== undefined && _.isEmpty(actionViewPersistenceService.masterFilter)) {\r\n\t\t\t\t\t\t\t\tprepareCriteriaFromLoad(vm.filterColumns);\r\n\r\n\t\t\t\t\t\t\t\tvar taskType = _.find(vm.taskTypes, function (taskTypeItem) {\r\n\t\t\t\t\t\t\t\t\treturn (taskTypeItem.taskTypeID === vm.masterFilter.taskTypeID) && (taskTypeItem.taskSeriesTypeID === vm.masterFilter.taskSeriesTypeID);\r\n\t\t\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\t\t\tvm.taskType = taskType || vm.taskTypes[0];\r\n\t\t\t\t\t\t\t} else if (_.isEmpty(actionViewPersistenceService.masterFilter)) {\r\n\t\t\t\t\t\t\t\tvm.taskType = vm.taskTypes[0];\r\n\r\n\t\t\t\t\t\t\t\ttaskTypeChanged();\r\n\t\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t\tvar taskType = _.find(vm.taskTypes, function (taskTypeItem) {\r\n\t\t\t\t\t\t\t\t\treturn (taskTypeItem.taskTypeID === vm.masterFilter.taskTypeID) && (taskTypeItem.taskSeriesTypeID === vm.masterFilter.taskSeriesTypeID);\r\n\t\t\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\t\t\tvm.taskType = taskType || vm.taskTypes[0];\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t})\r\n\r\n\t\t\t\t});\r\n\r\n //Assigning this to the API so we can drilldown outside the normal flow of the page, e.g. drilldown from dashboard\r\n vm.api.resolveTasksAndFieldsDeferred = resolveTasksAndFieldsDeferred;\r\n\t\t}\r\n\r\n\t\tvm.showOptionChanged = function () {\r\n\t\t\tif (vm.masterFilter.ShowChoice === vm.showOptions.allTasks.id) {\r\n\t\t\t\tvm.masterFilter.WhereChoice = undefined\r\n\t\t\t} else {\r\n\t\t\t\tvm.masterFilter.WhereChoice = vm.masterFilter.WhereChoice || 1;\r\n\t\t\t}\r\n productAnalyticsService.logEvent('click-action-view-task-option', { taskAssignment: Object.values(vm.showOptions).find(x => x.id === vm.masterFilter.ShowChoice)?.display });\r\n\t\t}\r\n\r\n vm.whereOptionChanged = function () {\r\n productAnalyticsService.logEvent('click-action-view-task-assignment-type', {\r\n taskAssignmentType: vm.whereOptions.find(x => x.id === vm.masterFilter.WhereChoice)?.display\r\n });\r\n }\r\n\r\n\t\tvm.thatAreChanged = function() {\r\n\t\t\tif(vm.masterFilter.ThatAreChoice !== 4) {\r\n\t\t\t\tvm.masterFilter.CompletedDateFrom = null;\r\n\t\t\t\tvm.masterFilter.CompletedDateTo = null;\r\n\t\t\t}\r\n productAnalyticsService.logEvent('click-action-view-task-status', {\r\n taskAssignmentStatus: vm.thatAreOptions.find(x => x.id === vm.masterFilter.ThatAreChoice)?.display\r\n });\r\n\t\t}\r\n\r\n\t\tvm.canViewWhere = function (option) {\r\n\t\t\tif (option.id === 5) {\r\n\t\t\t\treturn vm.taskType && (vm.taskType.taskSeriesTypeID === 1 || vm.taskType.taskSeriesTypeID === 13);\r\n\t\t\t}\r\n\r\n\t\t\treturn vm.hasPermission || option.id === 1;\r\n\t\t}\r\n\r\n\t\tvm.canViewInclude = function (option) {\r\n\t\t\tif (vm.hasPermission) {\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\r\n\t\t\treturn option.id === 1 || option.id === 2;\r\n\t\t}\r\n\r\n\r\n\t\t$scope.$watch('vm.masterFilter.ThatAreChoice', function () {\r\n\t\t\tif (vm.masterFilter.ThatAreChoice !== 3) {\r\n\t\t\t\tvm.masterFilter.CalculateReadyAndNotReady = false;\r\n\t\t\t}\r\n\t\t}, true);\r\n\r\n\t\tfunction taskTypeChanged() {\r\n\t\t var taskTypeIdChanged = vm.masterFilter.taskTypeID !== vm.taskType.taskTypeID;\r\n vm.masterFilter.taskTypeID = vm.taskType.taskTypeID;\r\n\r\n\t\t\tif(vm.masterFilter.taskSeriesTypeID !== vm.taskType.taskSeriesTypeID || vm.masterFilter.output === 'default') {\r\n\t\t\t var oldFilter = angular.copy(vm.filterColumns);\r\n\r\n\t\t\t\tvm.masterFilter.output='default';\r\n\t\t\t\tvm.masterFilter.taskSeriesTypeID = vm.taskType.taskSeriesTypeID;\r\n\t\t\t\t_.assign(vm.masterFilter, setOutputs(vm.masterFilter.taskSeriesTypeID, vm.masterFilter.taskTypeID));\r\n\t\t\t\tvm.filterColumns = angular.copy(vm.masterFilter.EntityOutputColumns);\r\n vm.filterColumns = _.filter(vm.filterColumns, function (column) {\r\n var columnId = column.columnId || column.advancedSearchFieldID || column.id;\r\n // We need to remove the document image preview column because it can't be filtered on\r\n return columnId !== 9002 && columnId !== 1430;\r\n });\r\n\r\n\r\n //If old filter value exists, we want to persist it if we can\r\n\t\t\t\tvm.filterColumns = _.map(vm.filterColumns, function(newFilter) {\r\n\t\t\t\t var matchingFilter = _.find(oldFilter, {columnId: newFilter.columnId});\r\n\r\n\t\t\t\t if(matchingFilter) {\r\n\t\t\t\t newFilter.or = matchingFilter.or;\r\n }\r\n\r\n return newFilter;\r\n });\r\n\t\t\t} else if (taskTypeIdChanged){\r\n _.assign(vm.masterFilter, setOutputs(vm.masterFilter.taskSeriesTypeID, vm.masterFilter.taskTypeID));\r\n }\r\n\t\t}\r\n\r\n vm.logTaskTypeEvent = function() {\r\n productAnalyticsService.logEvent('select-action-view-task-type', {\r\n actionViewTask: vm.taskTypes.find(x => x.taskTypeID === vm.masterFilter.taskTypeID && x.taskSeriesTypeID === vm.masterFilter.taskSeriesTypeID)?.name\r\n });\r\n }\r\n\r\n function loadColumns(taskSeriesTypeID, taskTypeID) {\r\n var currentTaskType = _.find(vm.taskTypes, function (taskType) {\r\n return taskType.taskSeriesTypeID === taskSeriesTypeID && taskType.taskTypeID === taskTypeID;\r\n });\r\n\r\n var customTaskType = _.find(customTaskTypes, function (taskType) {\r\n return taskType.taskSeriesTypeID === currentTaskType?.taskSeriesTypeID && taskType.taskTypeID === currentTaskType?.taskTypeID;\r\n });\r\n\r\n\t\t\tvar separatedColumns = customTaskType ? prepCustom(customTaskType.columns) : prepSystem(currentTaskType?.columnIds);\r\n\t\t\tseparatedColumns.EntityOutputColumns = _.map(separatedColumns.EntityOutputColumns, col => {\r\n\t\t\t\tcol.fromTaskType = true;\r\n\t\t\t\treturn col;\r\n\t\t\t})\r\n\r\n separatedColumns.taskTypeName = currentTaskType?.name;\r\n return separatedColumns;\r\n }\r\n\r\n function setOutputs(taskSeriesTypeID, taskTypeID) {\r\n\t\t if(vm.taskTypes) {\r\n return loadColumns(taskSeriesTypeID, taskTypeID);\r\n } else {\r\n resolveTasksAndFieldsDeferred.then(function() {\r\n return loadColumns(taskSeriesTypeID, taskTypeID);\r\n })\r\n }\r\n\t\t}\r\n\r\n\t\tfunction prepCustom(columns) {\r\n\t\t\tvar separatedColumns = _.chain(angular.copy(columns))\r\n\t\t\t\t.map(columnFromAllFields)\r\n\t\t\t\t.groupBy(columnType)\r\n\t\t\t\t.value();\r\n\r\n\t\t\tseparatedColumns.CustomOutput = true;\r\n\r\n\t\t\treturn separatedColumns;\r\n\t\t}\r\n\r\n\t\tfunction columnFromAllFields(column) {\r\n\t\t\tvar columnId = column.columnId || column.advancedSearchFieldID || column.id;\r\n\r\n\t\t\tvar foundColumn = _.find(allFields, function (field) {\r\n\t\t\t\treturn field.advancedSearchFieldID === columnId;\r\n\t\t\t});\r\n\r\n\t\t\tvar newColumn = angular.copy(foundColumn);\r\n\r\n\t\t\tnewColumn.resultColumnName = newColumn.resultsColumnName;\r\n\t\t\tnewColumn.operators = searchOperators.getOperatorArray(newColumn.operators);\r\n\r\n\t\t\tif(newColumn.advancedSearchFieldID === 101 || newColumn.advancedSearchFieldID === 109) {\r\n\t\t\t\tnewColumn.or = [searchOperators.getCompanyOr(newColumn.operators)];\r\n\t\t\t} else {\r\n\t\t\t\tnewColumn.or = [searchOperators.getOr(newColumn.operators)];\r\n\t\t\t}\r\n\r\n\t\t\tnewColumn.sequence = column.sequence;\r\n\r\n\t\t\treturn newColumn;\r\n\t\t}\r\n\r\n\t\tfunction prepSystem(ids) {\r\n\t\t\tvar separatedColumns = _.chain(ids)\r\n\t\t\t\t.map(function (id, index) {\r\n\t\t\t\t\tvar column = angular.copy(_.find(taskTypeColumns, { columnId: id }));\r\n\r\n\t\t\t\t\tcolumn.operators = searchOperators.getOperatorArray(column.operators)\r\n\r\n if(id === 101 || id === 109) {\r\n column.or = [searchOperators.getCompanyOr(column.operators)];\r\n } else {\r\n column.or = [searchOperators.getOr(column.operators)];\r\n }\r\n\t\t\t\t\tcolumn.sequence = index;\r\n\r\n\t\t\t\t\treturn column;\r\n\t\t\t\t})\r\n\t\t\t\t.groupBy(columnType)\r\n\t\t\t\t.value();\r\n\r\n\t\t\tseparatedColumns.CustomOutput = false;\r\n\r\n\t\t\treturn separatedColumns;\r\n\t\t}\r\n\r\n\t\tfunction columnType(column) {\r\n\t\t\tvar columnId = column.columnId || column.advancedSearchFieldID || column.id;\r\n\r\n\t\t\tif (columnId > 9999 && columnId < 11000) {\r\n\t\t\t\treturn 'TaskOutputColumns';\r\n\t\t\t} else {\r\n\t\t\t\treturn 'EntityOutputColumns'\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction prepareCriteriaFromLoad(criteria) {\r\n\t\t\tcriteria = angular.fromJson(criteria);\r\n\r\n\t\t\tvm.filterColumns = _.map(criteria, function (filter) {\r\n\t\t\t\tconst column = angular.copy(_.find(allFields, { advancedSearchFieldID: (filter.columnId || filter.advancedSearchFieldID || filter.id) }));\r\n\t\t\t\tcolumn.operators = searchOperators.getOperatorArray(column.operators);\r\n\t\t\t\tcolumn.or = _.map(filter.or, function (or) {\r\n\t\t\t\t\treturn {\r\n\t\t\t\t\t\tvalue: or.value,\r\n\t\t\t\t\t\toperator: _.find(column.operators, { name: or.operator?.name || or.operator })\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\r\n\t\t\t\treturn column;\r\n\t\t\t});\r\n\r\n\t\t\tvar keys = ['ShowUserTeams', 'ShowTeams', 'IncludeUserTeams', 'IncludeTeams'];\r\n\r\n\t\t\tangular.forEach(keys, function (key) {\r\n\t\t\t\tvm.masterFilter[key] = vm.masterFilter[key] || [{}];\r\n\t\t\t})\r\n\r\n\t\t\tif (vm.masterFilter.EntityOutputColumns[0].sequence === undefined) {\r\n\t\t\t\tvm.masterFilter.EntityOutputColumns = angular.copy(vm.filterColumns);\r\n\t\t\t}\r\n\t\t\tvm.masterFilter.TaskOutputColumns = _.map(vm.masterFilter.TaskOutputColumns, columnFromAllFields)\r\n\t\t}\r\n\r\n\t\tfunction fuzzyFieldCompare(field1, field2) {\r\n\t\t var id1 = field1.columnId || field1.advancedSearchFieldID || field1.id;\r\n\t\t var id2 = field2.columnId || field2.advancedSearchFieldID || field2.id;\r\n\t\t return id1 === id2;\r\n\t\t}\r\n\r\n\t\tfunction checkActionViewDefaultOutput(filterColumnUpdate) {\r\n\t\t /*if(filterColumnUpdate) {\r\n vm.filterColumns = filterColumnUpdate;\r\n }*/\r\n\r\n\t\t return resolveTasksAndFieldsDeferred.then(function () {\r\n\t\t if (vm.masterFilter.output === \"default\") {\r\n\t\t var defaultMasterFilter = setOutputs(vm.masterFilter.taskSeriesTypeID, vm.masterFilter.taskTypeID);\r\n\r\n\t\t var missingEntityOutputColumns = _.filter(defaultMasterFilter.EntityOutputColumns, function (defaultEntityOutputColumn) {\r\n\t\t return !_.some(vm.masterFilter.EntityOutputColumns, function (currentOutputColumn) {\r\n\t\t return fuzzyFieldCompare(currentOutputColumn, defaultEntityOutputColumn);\r\n\t\t });\r\n\t\t });\r\n\r\n\t\t _.forEach(missingEntityOutputColumns, function (missingOutputColumn) {\r\n\t\t console.log([\"Adding missing column\", _.cloneDeep(missingOutputColumn)]);\r\n\t\t // WK-5548 - There's at least one circumstance where id is needed and all we have is advancedSearchFieldID\r\n\t\t // TODO: Refactor the AV nightmare\r\n\t\t if (missingOutputColumn.advancedSearchFieldID && !missingOutputColumn.id) {\r\n\t\t missingOutputColumn.id = missingOutputColumn.advancedSearchFieldID;\r\n\t\t }\r\n\r\n\t\t vm.masterFilter.EntityOutputColumns.push(missingOutputColumn);\r\n\t\t vm.filterColumns.push(missingOutputColumn);\r\n\t\t });\r\n\r\n\t\t var extraEntityOutputColumns = _.filter(vm.masterFilter.EntityOutputColumns, function (currentOutputColumn) {\r\n\t\t return !_.some(defaultMasterFilter.EntityOutputColumns, function (defaultEntityOutputColumn) {\r\n\t\t return fuzzyFieldCompare(defaultEntityOutputColumn, currentOutputColumn);\r\n\t\t });\r\n\t\t });\r\n\r\n\t\t _.forEach(extraEntityOutputColumns, function (extraEntityOutputColumn) {\r\n\t\t // Check for a filter on this extra property before removing it\r\n\t\t var hasNonEmptyExistingFilter = false;\r\n\t\t var existingFilters = _.filter(vm.filterColumns, function (filterColumn) {\r\n\t\t return fuzzyFieldCompare(filterColumn, extraEntityOutputColumn);\r\n\t\t });\r\n\t\t if (existingFilters.length > 0) {\r\n\t\t // (don't worry if there's more than one; it shouldn't happen, and if it does other things more important than this will break)\r\n var existingFilter = existingFilters[0]\r\n var blankFilterForThisColumn = columnFromAllFields(extraEntityOutputColumn);\r\n if (!_.isEqual(blankFilterForThisColumn.or, existingFilter.or)) {\r\n console.log([\"An extra column exists but has a filter\", _.cloneDeep(existingFilter)]);\r\n hasNonEmptyExistingFilter = true;\r\n }\r\n if (!hasNonEmptyExistingFilter) {\r\n console.log([\"Removing extra column\", _.cloneDeep(extraEntityOutputColumn)]);\r\n _.remove(vm.masterFilter.EntityOutputColumns, function (entityOutputColumn) {\r\n return fuzzyFieldCompare(entityOutputColumn, extraEntityOutputColumn);\r\n });\r\n _.remove(vm.filterColumns, function (filterColumn) {\r\n return fuzzyFieldCompare(filterColumn, extraEntityOutputColumn);\r\n });\r\n }\r\n\t\t }\r\n\t\t });\r\n\r\n\t\t if (missingEntityOutputColumns.length > 0 || extraEntityOutputColumns.length > 0) {\r\n\t\t vm.masterFilter.CustomOutput = defaultMasterFilter.CustomOutput;\r\n\t\t }\r\n\t\t }\r\n\r\n vm.filterColumns = _.filter(vm.filterColumns, function (column) {\r\n var columnId = column.columnId || column.advancedSearchFieldID || column.id;\r\n // We need to remove the document image preview column because it can't be filtered on\r\n return columnId !== 9002 && columnId !== 1430;\r\n });\r\n\r\n\t\t return {\r\n\t\t masterFilter: vm.masterFilter,\r\n\t\t filterColumns: vm.filterColumns\r\n\t\t };\r\n });\r\n\t\t}\r\n\r\n\t\tfunction resolveDefaultOutput(searchFilter) {\r\n\t\t return resolveTasksAndFieldsDeferred.then(function () {\r\n\t\t if (searchFilter.output === \"default\") {\r\n\t\t var defaultMasterFilter = setOutputs(searchFilter.taskSeriesTypeID, searchFilter.taskTypeID);\r\n\r\n\t\t var missingEntityOutputColumns = _.filter(defaultMasterFilter.EntityOutputColumns, function (defaultEntityOutputColumn) {\r\n\t\t return !_.some(searchFilter.EntityOutputColumns, function (currentOutputColumn) {\r\n\t\t return fuzzyFieldCompare(currentOutputColumn, defaultEntityOutputColumn);\r\n\t\t });\r\n\t\t });\r\n\r\n\t\t _.forEach(missingEntityOutputColumns, function (missingOutputColumn) {\r\n\t\t console.log([\"Adding missing column to saved search\", _.cloneDeep(missingOutputColumn)]);\r\n\t\t searchFilter.EntityOutputColumns.push({\r\n\t\t id: missingOutputColumn.advancedSearchFieldID,\r\n\t\t sequence: missingOutputColumn.sequence,\r\n\t\t displayName: missingOutputColumn.displayName,\r\n\t\t depthValue: missingOutputColumn.depthValue,\r\n resultColumnName: missingOutputColumn.resultColumnName\r\n\t\t });\r\n\t\t });\r\n\r\n\t\t var extraEntityOutputColumns = _.filter(searchFilter.EntityOutputColumns, function (currentOutputColumn) {\r\n\t\t return !_.some(defaultMasterFilter.EntityOutputColumns, function (defaultEntityOutputColumn) {\r\n\t\t return fuzzyFieldCompare(defaultEntityOutputColumn, currentOutputColumn);\r\n\t\t });\r\n\t\t });\r\n\r\n\t\t _.forEach(extraEntityOutputColumns, function (extraEntityOutputColumn) {\r\n\t\t // Check for a filter on this extra property before removing it\r\n\t\t var existingFilter = _.filter(searchFilter.filters, function (filter) {\r\n\t\t return fuzzyFieldCompare(filter, extraEntityOutputColumn);\r\n\t\t });\r\n\r\n\t\t if (existingFilter.length > 0) {\r\n console.log([\"An extra column exists but has a filter for this saved search\", _.cloneDeep(existingFilter)]);\r\n\t\t }\r\n\t\t else {\r\n console.log([\"Removing extra column for this saved search\", _.cloneDeep(extraEntityOutputColumn)]);\r\n _.remove(searchFilter.EntityOutputColumns, function (entityOutputColumn) {\r\n return fuzzyFieldCompare(entityOutputColumn, extraEntityOutputColumn);\r\n });\r\n\t\t }\r\n\t\t });\r\n\r\n\t\t if (missingEntityOutputColumns.length > 0) {\r\n\t\t searchFilter.CustomOutput = defaultMasterFilter.CustomOutput;\r\n\t\t }\r\n\t\t }\r\n\r\n\t\t return searchFilter;\r\n\t\t });\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller('OutputDefaultsController', OutputDefaultsController);\r\n\r\n\tOutputDefaultsController.$inject = ['actionViewService', '$uibModal', 'advancedSearchService', 'sd.Account.User.Settings.Service', 'sd.Account.User.Service'];\r\n\r\n\tfunction OutputDefaultsController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit(actionViewService, $uibModal, advancedSearchService, userSettingsService, userService) {\r\n\t\tvar vm = this;\r\n\t\tvar taskTypeColumns;\r\n\t\tvar allFields;\r\n\t\tvar userSetting;\r\n\t\tvar customTaskTypes;\r\n\r\n\t\tactivate();\r\n\r\n\t\t////////////////\r\n\r\n\t\tfunction activate() {\r\n\t\t\tactionViewService.getTaskTypes()\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t\ttaskTypeColumns = result.columns;\r\n\r\n\t\t\t\t\tvm.taskTypes = actionViewService.sortTaskTypes(result.taskTypes);\r\n\t\t\t\t\t \t//_.reject(taskTypeList, { 'taskSeriesTypeID': 1 });\r\n\t\t\t\t});\r\n\r\n\t\t\tadvancedSearchService.getAllFields()\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t\tallFields = result;\r\n\r\n\t\t\t\t\tuserSetting = userSettingsService.getSettingsByGroup(12)[0] || {\r\n\t\t\t\t\t\tgroupId: 12,\r\n\t\t\t\t\t\tname: 'Task View Output Defaults',\r\n\t\t\t\t\t\tvalue: [],\r\n\t\t\t\t\t\tid: 0\r\n\t\t\t\t\t};\r\n\r\n\t\t\t\t\tcustomTaskTypes = angular.fromJson(userSetting.value);\r\n\r\n\t\t\t\t})\r\n\t\t}\r\n\r\n\t\tvm.launchModal = function (clickedTaskType) {\r\n\t\t\tvar customTaskType = _.find(customTaskTypes, function (taskType) {\r\n\t\t\t\treturn taskType.taskSeriesTypeID === clickedTaskType.taskSeriesTypeID && taskType.taskTypeID === clickedTaskType.taskTypeID;\r\n\t\t\t});\r\n\r\n\r\n\t\t\tconsole.log('clickedTaskType', clickedTaskType);\r\n\r\n\t\t\tvar modalInstance = $uibModal.open({\r\n\t\t\t\ttemplateUrl: 'app/Task/ActionView/Filters/_customOutputModal.html',\r\n\t\t\t\tcontroller: 'CustomOutputModalController',\r\n\t\t\t\tcontrollerAs: 'vm',\r\n\t\t\t\twindowClass: 'show',\r\n\t\t\t\tbackdropClass: 'show',\r\n\t\t\t\tresolve: {\r\n\t\t\t\t\tfromActionView: function () {\r\n\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t},\r\n\r\n\t\t\t\t\ttaskTypeName: function () {\r\n\t\t\t\t\t\treturn clickedTaskType.name;\r\n\t\t\t\t\t},\r\n\r\n\t\t\t\t\tselectedTaskType: function () {\r\n\t\t\t\t\t\treturn _.find(vm.taskTypes, {taskSeriesTypeID: clickedTaskType.taskSeriesTypeID});\r\n\t\t\t\t\t},\r\n\r\n\t\t\t\t\tsystemColumns: function () {\r\n\t\t\t\t\t\tvar systemColumns = _.map(clickedTaskType.columnIds, function (columnId) {\r\n\t\t\t\t\t\t\tvar column = angular.copy(_.find(taskTypeColumns, { columnId: columnId }));\r\n\r\n\t\t\t\t\t\t\treturn column;\r\n\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\t\treturn systemColumns;\r\n\t\t\t\t\t},\r\n\r\n\t\t\t\t\tuserColumns: function () {\r\n\t\t\t\t\t\tif (!customTaskType) {\r\n\t\t\t\t\t\t\treturn [];\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tvar userColumns = _.map(angular.copy(customTaskType.columns), function (column) {\r\n\t\t\t\t\t\t\tvar fullColumn = angular.copy(_.find(allFields, { advancedSearchFieldID: column.columnId }))\r\n\t\t\t\t\t\t\t_.assign(column, _.omit(fullColumn, 'sequence'));\r\n\r\n\t\t\t\t\t\t\treturn column;\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\treturn userColumns;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\tmodalInstance.result\r\n\t\t\t\t.then(function (fullColumns) {\r\n\t\t\t\t\tif (fullColumns.length) {\r\n\t\t\t\t\t\tvar columnsToSave = _.map(fullColumns, function (filter, i) {\r\n\t\t\t\t\t\t\treturn {\r\n\t\t\t\t\t\t\t\tcolumnId: filter.columnId,\r\n\t\t\t\t\t\t\t\tsequence: i\r\n\t\t\t\t\t\t\t};\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\tif (customTaskType) {\r\n\t\t\t\t\t\t\tvar i = _.findIndex(customTaskTypes, function (taskType) {\r\n\t\t\t\t\t\t\t\treturn taskType.taskSeriesTypeID === customTaskType.taskSeriesTypeID && taskType.taskTypeID === customTaskType.taskTypeID;\r\n\t\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\t\tcustomTaskTypes[i].columns = columnsToSave\r\n\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\tcustomTaskTypes.push({\r\n\t\t\t\t\t\t\t\ttaskSeriesTypeID: clickedTaskType.taskSeriesTypeID,\r\n\t\t\t\t\t\t\t\ttaskTypeID: clickedTaskType.taskTypeID,\r\n\t\t\t\t\t\t\t\tcolumns: columnsToSave\r\n\t\t\t\t\t\t\t});\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tuserSetting.value = JSON.stringify(customTaskTypes);\r\n\t\t\t\t\t\tuserSettingsService.save(userSetting)\r\n\t\t\t\t\t\t\t.then(function () {})\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tif (customTaskType) {\r\n\t\t\t\t\t\t\t_.remove(customTaskTypes, customTaskType);\r\n\r\n\t\t\t\t\t\t\tuserSetting.value = customTaskTypes;\r\n\t\t\t\t\t\t\tuserSettingsService.save(userSetting)\r\n\t\t\t\t\t\t\t\t.then(function () {})\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t})\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:actionViewOverview\r\n * @description\r\n * # Stand alone widget for Action View Overview panel\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar VIEW_TEMPLATE_URL = 'app/Task/ActionView/Tables/_overview-table.html';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('actionViewOverviewTable', Directive);\r\n\r\n\t//Directive.$inject = ['actionViewService', 'ActionViewCategoryTypes'];\r\n\r\n\tfunction Directive() {\r\n\t\tvar directive = {\r\n\t\t\trestrict: 'E',\r\n\t\t\treplace: true,\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL\r\n\t\t}\r\n\r\n\t\treturn directive;\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdTaskSeriesArrows', sdTaskSeriesArrows);\r\n\r\n\tsdTaskSeriesArrows.$inject = [];\r\n\r\n\tfunction sdTaskSeriesArrows() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Task/_taskSeriesArrows.html',\r\n\t\t\tscope: {\r\n\t\t\t\tmanyToOne: '=',\r\n\t\t\t\tchevronWidth: '=',\r\n\t\t\t\tpadding: '=',\r\n\t\t\t\tmanyLength: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit() {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.startingPos = (vm.chevronWidth + (vm.padding * 2)) / 2;\r\n\t\tvm.lineWidth = vm.chevronWidth + (vm.padding * 3);\r\n\t\tvm.extraSeries = _.range(vm.manyLength - 1)\r\n\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdTaskSeries', sdTaskSeries);\r\n\r\n\tsdTaskSeries.$inject = [\r\n\t\t'$compile',\r\n\t\t'taskService',\r\n\t\t'$q',\r\n\t\t'$rootScope',\r\n\t\t'TaskActionTypes',\r\n\t\t'TaskTypes',\r\n\t\t'userInstanceService',\r\n\t\t'instanceRepository',\r\n\t];\r\n\r\n\tfunction sdTaskSeries($compile, taskService, $q, $rootScope, TaskActionTypes, TaskTypes, userInstanceService, instanceRepository) {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\ttemplateUrl: 'app/Task/_taskPopover.html',\r\n\t\t\trestrict: 'A',\r\n\t\t\tscope: {\r\n\t\t\t\ttaskGroup: '=',\r\n\t\t\t\tchevronWidth: '=',\r\n\t\t\t\tpadding: '=',\r\n\t\t\t\tupdateData: '&',\r\n\t\t\t\tpopoverLeftOrRight: '=',\r\n\t\t\t\twaitingOnServer: '='\r\n\t\t\t},\r\n\t\t\tlink: function (scope, element, attrs) {\r\n\t\t\t\tvar heights = {\r\n\t\t\t\t\tsm: 50, // one line\r\n\t\t\t\t\tmd: 75, // two lines\r\n\t\t\t\t\tlg: 100, // three lines\r\n\t\t\t\t\txl: 125 // four lines\r\n\t\t\t\t};\r\n\r\n\t\t\t\tvar currentChevronPos = 0;\r\n\t\t\t\tvar chevronWidth = scope.chevronWidth;\r\n\t\t\t\tvar padding = scope.padding;\r\n\t\t\t\tvar chevronDivot = heights.lg * 0.10;\r\n\t\t\t\tvar svg, node, enteringNode, completeNode, currentNode;\r\n\t\t\t\tvar completeText, completeChevron, completeCheck, completeDate;\r\n\t\t\t\tvar verticalOffset = 0;\r\n\t\t\t\tvar completeChevronHeight = heights.lg;\r\n\r\n\t\t\t\tscope.userPicked = userPicked;\r\n\t\t\t\tscope.instanceIdUserFilter = null;\r\n\r\n\t\t\t\tactivate();\r\n\r\n\t\t\t\tfunction activate() {\r\n\t\t\t\t\tinitSvg();\r\n\t\t\t\t\tdefineBoxShadow();\r\n\t\t\t\t\tinitCompleteChevron();\r\n\r\n\t\t\t\t\telement.removeAttr('sd-task-series');\r\n\r\n\t\t\t\t\tscope.$watch('taskGroup', updateTaskGroup, true)\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction initSvg() {\r\n\t\t\t\t\tsvg = d3.select(element[0])\r\n\t\t\t\t\t\t.append(\"svg\")\r\n\t\t\t\t\t\t.attr(\"width\", chevronWidth + (padding * 2))\r\n\t\t\t\t\t\t.attr('height', 0);\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction defineBoxShadow() {\r\n\t\t\t\t\tvar defs = svg.append(\"defs\");\r\n\r\n\t\t\t\t\t// create filter with id #drop-shadow\r\n\t\t\t\t\t// height=130% so that the shadow is not clipped\r\n\t\t\t\t\tvar filter = defs.append(\"filter\")\r\n\t\t\t\t\t\t.attr(\"id\", \"drop-shadow\")\r\n\t\t\t\t\t\t.attr(\"height\", \"130%\");\r\n\r\n\t\t\t\t\t// SourceAlpha refers to opacity of graphic that this filter will be applied to\r\n\t\t\t\t\t// convolve that with a Gaussian with standard deviation 3 and store result\r\n\t\t\t\t\t// in blur\r\n\t\t\t\t\tfilter.append(\"feGaussianBlur\")\r\n\t\t\t\t\t\t.attr(\"in\", \"SourceAlpha\")\r\n\t\t\t\t\t\t.attr(\"stdDeviation\", 2)\r\n\t\t\t\t\t\t.attr(\"result\", \"blur\");\r\n\r\n\t\t\t\t\t// translate output of Gaussian blur to the right and downwards with 2px\r\n\t\t\t\t\t// store result in offsetBlur\r\n\t\t\t\t\tfilter.append(\"feOffset\")\r\n\t\t\t\t\t\t.attr(\"in\", \"blur\")\r\n\t\t\t\t\t\t.attr(\"dx\", 2)\r\n\t\t\t\t\t\t.attr(\"dy\", 2)\r\n\t\t\t\t\t\t.attr(\"result\", \"offsetBlur\");\r\n\r\n\t\t\t\t\t// overlay original SourceGraphic over translated blurred opacity by using\r\n\t\t\t\t\t// feMerge filter. Order of specifying inputs is important!\r\n\t\t\t\t\tvar feMerge = filter.append(\"feMerge\");\r\n\r\n\t\t\t\t\tfeMerge.append(\"feMergeNode\")\r\n\t\t\t\t\t\t.attr(\"in\", \"offsetBlur\")\r\n\t\t\t\t\tfeMerge.append(\"feMergeNode\")\r\n\t\t\t\t\t\t.attr(\"in\", \"SourceGraphic\");\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction initCompleteChevron() {\r\n\t\t\t\t\tvar completeChevronPath = d3.svg.line()([\r\n\t\t\t\t\t\t[0, 0],\r\n\t\t\t\t\t\t[chevronWidth / 2, chevronDivot],\r\n\t\t\t\t\t\t[chevronWidth, 0],\r\n\t\t\t\t\t\t[chevronWidth, completeChevronHeight - chevronDivot],\r\n\t\t\t\t\t\t[0, completeChevronHeight - chevronDivot],\r\n\t\t\t\t\t\t[0, 0]\r\n\t\t\t\t\t])\r\n\r\n\t\t\t\t\tcompleteNode = svg.append('g')\r\n\t\t\t\t\t\t.attr('oncontextmenu', 'return false')\r\n\t\t\t\t\t\t.attr('fill-opacity', 1e-6)\r\n\t\t\t\t\t\t.attr('stroke-opacity', 1e-6);\r\n\r\n\t\t\t\t\tcompleteChevron = completeNode.append('path')\r\n\t\t\t\t\t\t.attr('d', completeChevronPath)\r\n\t\t\t\t\t\t.attr('stroke-width', 1)\r\n\t\t\t\t\t\t.attr('fill', '#eee')\r\n\t\t\t\t\t\t.style(\"filter\", \"url(#drop-shadow)\")\r\n\r\n\t\t\t\t\tcompleteText = completeNode.append('text')\r\n\t\t\t\t\t\t.attr('y', completeChevronHeight / 2)\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.attr('x', chevronWidth / 2)\r\n\t\t\t\t\t\t.attr('text-anchor', 'middle')\r\n\t\t\t\t\t\t.attr('class', 'chevron-text')\r\n\t\t\t\t\t\t.text('Tasks Complete!');\r\n\r\n\t\t\t\t\tcompleteCheck = completeNode.append('text')\r\n\t\t\t\t\t\t.attr('y', completeChevronHeight / 2)\r\n\t\t\t\t\t\t.attr('x', 10 + padding)\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.style('font', 'var(--fa-font-regular)')\r\n\t\t\t\t\t\t.style('font-weight', '900')\r\n\t\t\t\t\t\t.style('font-size', '36')\r\n\t\t\t\t\t\t.attr('class', 'task-checked')\r\n\r\n\t\t\t\t\tcompleteDate = completeNode.append('text')\r\n\t\t\t\t\t\t.attr('y', completeChevronHeight * .42 + 20)\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.attr('x', chevronWidth / 2)\r\n\t\t\t\t\t\t.attr('text-anchor', 'middle')\r\n\t\t\t\t\t\t.attr('class', 'chevron-text')\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction updateTaskGroup() {\r\n\t\t\t\t\t// used to configure y value of chevrons of variable height\r\n\t\t\t\t\tcurrentChevronPos = 0;\r\n\t\t\t\t\tverticalOffset = (scope.taskGroup.maxHeight - scope.taskGroup.height) / scope.taskGroup.tasks.length;\r\n\r\n\t\t\t\t\t// set new svg height\r\n\t\t\t\t\tsvg.transition()\r\n\t\t\t\t\t\t.attr(\"height\", scope.taskGroup.maxHeight);\r\n\r\n\t\t\t\t\t// selection of all nodes that are bound to data\r\n\t\t\t\t\tnode = svg.selectAll('g.task-node')\r\n\t\t\t\t\t\t.data(scope.taskGroup.tasks, function (d) {\r\n\t\t\t\t\t\t\treturn d.taskID;\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t// add new nodes from new data\r\n\t\t\t\t\tappendEnteringNodeElements();\r\n\r\n\t\t\t\t\t// update existing nodes\r\n\t\t\t\t\tnode.attr('fill-opacity', function (d) {\r\n\t\t\t\t\t\treturn d.temp ? 1e-6 : 1;\r\n\t\t\t\t\t})\r\n\t\t\t\t\t\t.attr('stroke-opacity', function (d) {\r\n\t\t\t\t\t\t\treturn d.temp ? 1e-6 : 1;\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.transition()\r\n\t\t\t\t\t\t.attr('fill-opacity', 1)\r\n\t\t\t\t\t\t.attr('stroke-opacity', 1)\r\n\t\t\t\t\t\t.attr('transform', function (d, i) {\r\n\t\t\t\t\t\t\tvar transform = \"translate(\" + padding + \",\" + (currentChevronPos + padding) + \")\";\r\n\t\t\t\t\t\t\tcurrentChevronPos += getHeight(d);\r\n\r\n\t\t\t\t\t\t\treturn transform;\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\tupdateChevrons();\r\n\t\t\t\t\tupdateChevronText();\r\n\r\n\t\t\t\t\tif (!_.last(scope.taskGroup.tasks).pointsTo.length) {\r\n\t\t\t\t\t\tupdateCompleteChevron();\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t// remove nodes no longer bound to data\r\n\t\t\t\t\tnode.exit()\r\n\t\t\t\t\t\t.transition()\r\n\t\t\t\t\t\t.duration(1000)\r\n\t\t\t\t\t\t.attr('fill-opacity', 1e-6)\r\n\t\t\t\t\t\t.attr('stroke-opacity', 1e-6)\r\n\t\t\t\t\t\t.remove();\r\n\r\n\t\t\t\t\t$compile(element)(scope);\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction appendEnteringNodeElements() {\r\n\t\t\t\t\tenteringNode = node.enter().append('g').attr('class', 'task-node');\r\n\r\n\t\t\t\t\tenteringNode.append('path').attr('class', 'task-chevron')\r\n\t\t\t\t\t\t.attr('stroke-width', 1)\r\n\t\t\t\t\t\t.style(\"filter\", \"url(#drop-shadow)\")\r\n\t\t\t\t\t\t.attr('uib-popover-template', \"'taskPopover.html'\")\r\n\t\t\t\t\t\t.attr('popover-trigger', 'mouseenter')\r\n\t\t\t\t\t\t.attr('popover-placement', scope.popoverLeftOrRight)\r\n\t\t\t\t\t\t.attr('popover-append-to-body', 'true')\r\n\r\n\t\t\t\t\tenteringNode.append('text').attr('class', 'task-name chevron-text')\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.attr('x', chevronWidth / 2)\r\n\t\t\t\t\t\t.attr('text-anchor', 'middle')\r\n\r\n\t\t\t\t\tenteringNode.append('text').attr('class', 'task-user chevron-text')\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.attr('x', chevronWidth / 2)\r\n\t\t\t\t\t\t.attr('text-anchor', 'middle')\r\n\r\n\t\t\t\t\tenteringNode.append('text').attr('class', 'task-team chevron-text')\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.attr('x', chevronWidth / 2)\r\n\t\t\t\t\t\t.attr('text-anchor', 'middle')\r\n\r\n\t\t\t\t\tenteringNode.append('text').attr('class', 'task-deliverable chevron-text')\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.attr('x', chevronWidth / 2)\r\n\t\t\t\t\t\t.attr('text-anchor', 'middle')\r\n\t\t\t\t\t\t.style('font-size', '13')\r\n\r\n\t\t\t\t\tenteringNode.append('text').attr('class', 'task-checkbox')\r\n\t\t\t\t\t\t.attr('x', 5)\r\n\t\t\t\t\t\t.attr('y', 20)\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.style('font', 'var(--fa-font-regular)')\r\n\t\t\t\t\t\t.style('font-weight', '900')\r\n\t\t\t\t\t\t.style('font-size', '22')\r\n\t\t\t\t\t\t.attr('tooltip-append-to-body', 'true')\r\n\t\t\t\t\t\t.text('\\uf0c8')\r\n\r\n\t\t\t\t\tenteringNode.append('text').attr('class', 'task-checked')\r\n\t\t\t\t\t\t.attr('x', 5)\r\n\t\t\t\t\t\t.attr('y', 20)\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.style('font', 'var(--fa-font-regular)')\r\n\t\t\t\t\t\t.style('font-weight', '900')\r\n\t\t\t\t\t\t.style('font-size', '24')\r\n\t\t\t\t\t\t.text('\\uf046')\r\n\r\n\t\t\t\t\tenteringNode.append('text').attr('class', 'task-skipped')\r\n\t\t\t\t\t\t.attr('x', 5)\r\n\t\t\t\t\t\t.attr('y', 20)\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.style('font', 'var(--fa-font-regular)')\r\n\t\t\t\t\t\t.style('font-weight', '900')\r\n\t\t\t\t\t\t.style('font-size', '24')\r\n\t\t\t\t\t\t.text('\\uf147')\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction updateChevrons() {\r\n\t\t\t\t\tvar chevron = node.select('path.task-chevron')\r\n\r\n\t\t\t\t\tchevron.transition()\r\n\t\t\t\t\t\t.attr('d', function (d) {\r\n\t\t\t\t\t\t\tvar specificChevronHeight = getHeight(d);\r\n\r\n\t\t\t\t\t\t\treturn d3.svg.line()([\r\n\t\t\t\t\t\t\t\t[0, 0],\r\n\t\t\t\t\t\t\t\t[chevronWidth / 2, chevronDivot],\r\n\t\t\t\t\t\t\t\t[chevronWidth, 0],\r\n\t\t\t\t\t\t\t\t[chevronWidth, specificChevronHeight - chevronDivot],\r\n\t\t\t\t\t\t\t\t[chevronWidth / 2, specificChevronHeight],\r\n\t\t\t\t\t\t\t\t[0, specificChevronHeight - chevronDivot],\r\n\t\t\t\t\t\t\t\t[0, 0]\r\n\t\t\t\t\t\t\t])\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.attr('stroke', function (d) {\r\n\t\t\t\t\t\t\treturn d.completedDateTime ? 'var(--ace-success)' : 'gray';\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.attr('fill', function (d) {\r\n\t\t\t\t\t\t\treturn d.isReady ? 'lightblue' : '#eee';\r\n\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\tchevron.on('mouseenter', function (d) {\r\n\t\t\t\t\t\tscope.hoveredTask = d;\r\n\t\t\t\t\t\thideContextMenus();\r\n\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t})\r\n\t\t\t\t\t\t.attr('context-menu', function (d, i) {\r\n\t\t\t\t\t\t\treturn 'getContextOptions(' + d.taskID + ',' + i + ')'\r\n\t\t\t\t\t\t});\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction launchUserTeamPicker(task, currentIndex) {\r\n\t\t\t\t\tscope.editingTask = angular.copy(task);\r\n\r\n\t\t\t\t\t//determine instance scope filter to use on the user picker if needed for a consultant\r\n\t\t\t\t\tinstanceRepository.getEntityInstanceId(scope.editingTask.entityTypeID, scope.editingTask.entityId).toPromise()\r\n\t\t\t\t\t.then(instanceId=>\t{\r\n\t\t\t\t\t\tif(userInstanceService.isInstanceImplicit(instanceId)) {\r\n\t\t\t\t\t\t\tlet scopeInstanceId = userInstanceService.getSelectedInstance().instanceId;\r\n\t\t\t\t\t\t\tscope.instanceIdUserFilter = scopeInstanceId;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\tscope.instanceIdUserFilter = null;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\tcurrentNode = d3.select(node[0][currentIndex]);\r\n\t\t\t\t\tvar extraHeight = 125 - getHeight(task)\r\n\r\n\t\t\t\t\tsvg.transition()\r\n\t\t\t\t\t\t.attr('height', Number(svg.attr('height')) + extraHeight);\r\n\r\n\t\t\t\t\tcurrentNode.select('path.task-chevron')\r\n\t\t\t\t\t\t.transition()\r\n\t\t\t\t\t\t.attr('d', function (d) {\r\n\t\t\t\t\t\t\tvar specificChevronHeight = getHeight(d) + extraHeight;\r\n\r\n\t\t\t\t\t\t\treturn d3.svg.line()([\r\n\t\t\t\t\t\t\t\t[0, 0],\r\n\t\t\t\t\t\t\t\t[chevronWidth / 2, chevronDivot],\r\n\t\t\t\t\t\t\t\t[chevronWidth, 0],\r\n\t\t\t\t\t\t\t\t[chevronWidth, specificChevronHeight - chevronDivot],\r\n\t\t\t\t\t\t\t\t[chevronWidth / 2, specificChevronHeight],\r\n\t\t\t\t\t\t\t\t[0, specificChevronHeight - chevronDivot],\r\n\t\t\t\t\t\t\t\t[0, 0]\r\n\t\t\t\t\t\t\t])\r\n\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\tcurrentNode.select('text.task-user')\r\n\t\t\t\t\t\t.attr('visibility', 'hidden')\r\n\r\n\t\t\t\t\tcurrentNode.select('text.task-team')\r\n\t\t\t\t\t\t.attr('visibility', 'hidden')\r\n\r\n\t\t\t\t\tcurrentNode.select('text.task-deliverable')\r\n\t\t\t\t\t\t.attr('visibility', 'hidden');\r\n\r\n\t\t\t\t\tnode.transition()\r\n\t\t\t\t\t\t.attr('transform', function (d, i) {\r\n\t\t\t\t\t\t\tif (i > currentIndex) {\r\n\t\t\t\t\t\t\t\tvar y = _.words(d3.select(this).attr('transform'))[2];\r\n\r\n\r\n\t\t\t\t\t\t\t\treturn 'translate(' + padding + ',' + (Number(y) + extraHeight) + ')';\r\n\t\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t\treturn d3.select(this).attr('transform')\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\tvar y = _.words(completeNode.attr('transform'))[2];\r\n\r\n\t\t\t\t\tcompleteNode.transition()\r\n\t\t\t\t\t\t.attr('transform', 'translate(' + padding + ',' + (Number(y) + extraHeight) + ')');\r\n\r\n\t\t\t\t\tvar picker = currentNode.append('g')\r\n\t\t\t\t\t\t.attr('class', 'picker')\r\n\r\n\t\t\t\t\tpicker.append('text')\r\n\t\t\t\t\t\t.attr('y', 60)\r\n\t\t\t\t\t\t.attr('width', chevronWidth)\r\n\t\t\t\t\t\t.attr('height', 30)\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.attr('x', 10)\r\n\t\t\t\t\t\t.text('Assigned To:')\r\n\t\t\t\t\t// .style('font-weight', 'bold')\r\n\r\n\t\t\t\t\tpicker.append('text')\r\n\t\t\t\t\t\t.attr('y', 85)\r\n\t\t\t\t\t\t.attr('width', 30)\r\n\t\t\t\t\t\t.attr('height', 30)\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.attr('x', 215)\r\n\t\t\t\t\t\t.text(\"\\uf00d\")\r\n\t\t\t\t\t\t.style('font', 'var(--fa-font-regular)')\r\n\t\t\t\t\t\t.style('font-weight', '900')\r\n\t\t\t\t\t\t.style('font-size', '24')\r\n\t\t\t\t\t\t.style('cursor', 'pointer')\r\n\t\t\t\t\t\t.attr('fill', 'red')\r\n\t\t\t\t\t\t.on('click', function () {\r\n\t\t\t\t\t\t\trevertCurrentNode();\r\n\r\n\t\t\t\t\t\t\tupdateTaskGroup();\r\n\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\tvar foreignObject = picker.append('foreignObject')\r\n\t\t\t\t\t\t.attr('y', 70)\r\n\t\t\t\t\t\t.attr('width', 200)\r\n\t\t\t\t\t\t.attr('height', 30)\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.attr('x', 10)\r\n\r\n\t\t\t\t\tvar teamPickerDiv = foreignObject\r\n\t\t\t\t\t\t.append('xhtml:div')\r\n\t\t\t\t\t\t.style('display', 'none');\r\n\r\n\t\t\t\t\tteamPickerDiv.append('xhtml:sd-user-team-picker')\r\n\t\t\t\t\t\t.attr('picker-sm', 'true')\r\n\t\t\t\t\t\t.attr('user-id', 'editingTask.assignedUserID')\r\n\t\t\t\t\t\t.attr('team-id', 'editingTask.assignedTeamID')\r\n\t\t\t\t\t\t.attr('user', 'editingTask.assignedUser')\r\n\t\t\t\t\t\t.attr('team', 'editingTask.assignedTeam')\r\n\t\t\t\t\t\t.attr('entity-id-scope', '[editingTask.taskID]')\r\n\t\t\t\t\t\t.attr('entity-type-scope', '\"task\"')\r\n\t\t\t\t\t\t.attr('append-to-body', \"true\")\r\n\t\t\t\t\t\t.attr('close-fn', 'userPicked()')\r\n\t\t\t\t\t\t.attr('is-reassign', 'true')\r\n\t\t\t\t\t\t.attr('instance-id-scope', 'instanceIdUserFilter')\r\n\r\n\r\n\t\t\t\t\tteamPickerDiv.transition()\r\n\t\t\t\t\t\t.delay(500)\r\n\t\t\t\t\t\t.style('display', 'block')\r\n\r\n\t\t\t\t\t$compile(element)(scope);\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction revertCurrentNode() {\r\n\t\t\t\t\tscope.editingTask = null;\r\n\r\n\t\t\t\t\tcurrentNode.select('g.picker')\r\n\t\t\t\t\t\t.remove();\r\n\r\n\t\t\t\t\tcurrentNode.select('text.task-user')\r\n\t\t\t\t\t\t.attr('visibility', 'visible')\r\n\r\n\t\t\t\t\tcurrentNode.select('text.task-team')\r\n\t\t\t\t\t\t.attr('visibility', 'visible')\r\n\r\n\t\t\t\t\tcurrentNode.select('text.task-deliverable')\r\n\t\t\t\t\t\t.attr('visibility', 'visible')\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction userPicked() {\r\n\t\t\t\t\tscope.waitingOnServer = true;\r\n\t\t\t\t\ttaskService.updateTask(scope.editingTask)\r\n\t\t\t\t\t\t.then(function (data) {\r\n\t\t\t\t\t\t\trevertCurrentNode();\r\n\r\n\t\t\t\t\t\t\tupdateAllTasks(data);\r\n\t\t\t\t\t\t});\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction updateChevronText() {\r\n\t\t\t\t\tnode.select('text.task-name')\r\n\t\t\t\t\t\t.style('font-weight', function (d) {\r\n\t\t\t\t\t\t\treturn d.isReady ? 'bold' : 'normal'\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.text(function (d) {\r\n\t\t\t\t\t\t\treturn d.name\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.each(wrap)\r\n\t\t\t\t\t\t.attr('y', padding + 20 + (verticalOffset / 2))\r\n\r\n\r\n\t\t\t\t\tnode.select('text.task-user')\r\n\t\t\t\t\t\t.text(function (d) {\r\n\t\t\t\t\t\t\tif (d.isReady) {\r\n\t\t\t\t\t\t\t\treturn 'Assign: ' + d.assignedUser.firstName + ' ' + d.assignedUser.lastName;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.each(wrap)\r\n\t\t\t\t\t\t.attr('y', padding + 40 + (verticalOffset / 2))\r\n\t\t\t\t\t\t.attr('fill', function (d) {\r\n\t\t\t\t\t\t\treturn d.assignedUserIsOverridden ? 'red' : 'initial';\r\n\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\tnode.select('text.task-team')\r\n\t\t\t\t\t\t.text(function (d) {\r\n\t\t\t\t\t\t\tif (d.isReady) {\r\n\t\t\t\t\t\t\t\treturn d.assignedTeam.name;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.each(wrap)\r\n\t\t\t\t\t\t.attr('y', padding + 60 + (verticalOffset / 2))\r\n\t\t\t\t\t\t.attr('fill', function (d) {\r\n\t\t\t\t\t\t\treturn d.assignedTeamIsOverridden ? 'red' : 'initial';\r\n\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\tnode.select('text.task-deliverable')\r\n\t\t\t\t\t\t.attr('y', function (d) {\r\n\t\t\t\t\t\t\treturn d.isReady ? padding + 80 + (verticalOffset / 2) : padding + 40 + (verticalOffset / 2);\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.text(function (d) {\r\n\t\t\t\t\t\t\tif (isDeliverable(d)) {\r\n\t\t\t\t\t\t\t\tvar deliverableStr = '';\r\n\t\t\t\t\t\t\t\tvar dateFormatStr = '';\r\n\r\n\t\t\t\t\t\t\t\tswitch(d.taskTypeID) {\r\n\t\t\t\t\t\t\t\t\tcase TaskTypes.INFORMALHEARING:\r\n\t\t\t\t\t\t\t\t\tcase TaskTypes.FORMALHEARING:\r\n\t\t\t\t\t\t\t\t\tcase TaskTypes.SUBMITEVIDENCE:\r\n\t\t\t\t\t\t\t\t\t\tdateFormatStr = 'M/D/YYYY h:mm a';\r\n\t\t\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\t\t\tdefault:\r\n\t\t\t\t\t\t\t\t\t\tdateFormatStr = 'M/D/YYYY';\r\n\t\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t\tdeliverableStr += d.deliverableName ? d.deliverableName : 'Due';\r\n\t\t\t\t\t\t\t\tdeliverableStr += ' ';\r\n\t\t\t\t\t\t\t\tdeliverableStr += d.dueDate ? moment.utc(d.dueDate).format(dateFormatStr) : '?';\r\n\r\n\t\t\t\t\t\t\t\treturn deliverableStr;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.each(wrap);\r\n\r\n\t\t\t\t\tnode.select('text.task-checkbox')\r\n\t\t\t\t\t\t.attr('visibility', function (d) {\r\n\t\t\t\t\t\t\treturn d.isReady && d.taskAuthorizationInfo.completeTask ? 'visible' : 'hidden';\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.style('cursor', function(d) {\r\n\t\t\t\t\t\t\treturn d.taskType.systemCompletes ? 'not-allowed' : 'pointer';\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.style('fill', function(d) {\r\n\t\t\t\t\t\t\treturn d.taskType.systemCompletes ? 'lightgray' : 'white';\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.attr('uib-tooltip', function(d) {\r\n\t\t\t\t\t\t\treturn d.taskType.systemCompletes ? \"Cannot Complete. Skip instead.\" : \"\";\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.on('click', function (d) {\r\n\t\t\t\t\t\t\tif(d.taskType.systemCompletes) {\r\n\t\t\t\t\t\t\t\treturn;\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tcompleteTask(d, this);\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\tnode.select('text.task-checked')\r\n\t\t\t\t\t\t.attr('visibility', function (d) {\r\n\t\t\t\t\t\t\treturn d.completedDateTime && !d.skipped ? 'visible' : 'hidden';\r\n\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\tnode.select('text.task-skipped')\r\n\t\t\t\t\t\t.attr('visibility', function (d) {\r\n\t\t\t\t\t\t\treturn d.skipped ? 'visible' : 'hidden';\r\n\t\t\t\t\t\t})\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction wrap() {\r\n\t\t\t\t\tvar self = d3.select(this),\r\n\t\t\t\t\t\ttextLength = self.node().getComputedTextLength(),\r\n\t\t\t\t\t\ttext = self.text(),\r\n\r\n\t\t\t\t\t\t// The task name should be shorter than the rest because it overlaps with the checkbox\r\n\t\t\t\t\t\tpaddingMultiplyer = _.includes(self.attr('class'), 'task-name') ? 5 : 2;\r\n\r\n\t\t\t\t\twhile (textLength > (chevronWidth - paddingMultiplyer * padding) && text.length > 0) {\r\n\t\t\t\t\t\ttext = text.slice(0, -1);\r\n\t\t\t\t\t\tself.text(text + '...');\r\n\t\t\t\t\t\ttextLength = self.node().getComputedTextLength();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction hideContextMenus() {\r\n\t\t\t\t\tvar dropdowns = angular.element('.angular-bootstrap-contextmenu .dropdown-menu, .dropdown.clearfix .dropdown-menu');\r\n\t\t\t\t\tdropdowns.css('display', 'none');\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction updateCompleteChevron() {\r\n\t\t\t\t\tvar lastTaskCompletedDateTime = _.last(scope.taskGroup.tasks).completedDateTime;\r\n\t\t\t\t\tvar strokeColor = lastTaskCompletedDateTime ? 'var(--ace-success)' : 'gray';\r\n\r\n\t\t\t\t\tcompleteNode\r\n\t\t\t\t\t\t.transition()\r\n\t\t\t\t\t\t.attr('fill-opacity', 1)\r\n\t\t\t\t\t\t.attr('stroke-opacity', 1)\r\n\t\t\t\t\t\t.attr('transform', \"translate(\" + padding + \",\" + (currentChevronPos + padding) + \")\")\r\n\r\n\t\t\t\t\tcompleteChevron.attr('stroke', strokeColor)\r\n\r\n\t\t\t\t\tif (lastTaskCompletedDateTime) {\r\n\t\t\t\t\t\tcompleteCheck.text('\\uf00c')\r\n\t\t\t\t\t\tcompleteText.attr('y', completeChevronHeight * .42);\r\n\t\t\t\t\t\tcompleteDate.text(moment.utc(lastTaskCompletedDateTime).tz(\"America/Chicago\").format('M/D/YYYY'));\r\n\t\t\t\t\t\tcompleteNode.style('font-weight', 'bold');\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tcompleteCheck.text('');\r\n\t\t\t\t\t\tcompleteText.attr('y', completeChevronHeight / 2);\r\n\t\t\t\t\t\tcompleteDate.text('');\r\n\t\t\t\t\t\tcompleteNode.style('font-weight', 'normal');\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tscope.getContextOptions = function (taskID, index) {\r\n\t\t\t\t\tvar rightClickMenuItems = [],\r\n\t\t\t\t\t\ttask = {},\r\n\t\t\t\t\t\tdeleteTaskMenu = [],\r\n\t\t\t\t\t\treassignTaskMenu = [],\r\n\t\t\t\t\t\trescindTaskMenu = [],\r\n\t\t\t\t\t\tskipTaskMenu = [];\r\n\r\n\t\t\t\t\tvar deferred = $q.defer();\r\n\r\n\t\t\t\t\t// No menu if we are in edit mode\r\n\t\t\t\t\tif (scope.editingTask) {\r\n\t\t\t\t\t\tdeferred.resolve([]);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t// Load the task by taskID - so we have all variables needed\r\n\t\t\t\t\ttask = _.find(scope.taskGroup.tasks, function (t) {\r\n\t\t\t\t\t\treturn t.taskID === taskID;\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\t// Add individual action functions\r\n\t\t\t\t\tdeleteTaskMenu = ['Delete Task', function () { deleteTask(task) }];\r\n\t\t\t\t\treassignTaskMenu = ['Reassign Task', function () { reassignTask(task, index) }];\r\n\t\t\t\t\trescindTaskMenu = ['Rescind Task', function () { rescindTask(task) }];\r\n\t\t\t\t\tskipTaskMenu = ['Skip Task', function () { skipTask(task) }];\r\n\r\n if (task.taskAuthorizationInfo.deleteTask && !task.taskType.systemDeletes === true) {\r\n\t\t\t\t\t\trightClickMenuItems.push(deleteTaskMenu);\r\n\t\t\t\t\t}\r\n if (task.taskAuthorizationInfo.reassignTask && !task.taskType.systemReassigns === true) {\r\n\t\t\t\t\t\trightClickMenuItems.push(reassignTaskMenu);\r\n\t\t\t\t\t}\r\n if (task.taskAuthorizationInfo.rescindTask && !task.taskType.systemRescinds === true) {\r\n\t\t\t\t\t\trightClickMenuItems.push(rescindTaskMenu);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (task.taskAuthorizationInfo.skipTask && !task.taskType.systemSkips === true) {\r\n\t\t\t\t\t\trightClickMenuItems.push(skipTaskMenu);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\ttaskService.getInsertOptions(task.entityId, task.entityTypeID, task.taskID)\r\n\t\t\t\t\t\t.then(function (data) {\r\n\t\t\t\t\t\t\tdata.insertBefore = _.map(data.insertBefore, function (item) {\r\n\t\t\t\t\t\t\t\treturn [item.name, function () { insertTaskBefore(task, item.taskTypeID) }];\r\n\t\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\t\t\tdata.insertAfter = _.map(data.insertAfter, function (item) {\r\n\t\t\t\t\t\t\t\treturn [item.name, function () { insertTaskAfter(task, item.taskTypeID) }];\r\n\t\t\t\t\t\t\t})\r\n\r\n\t\t\t\t\t\t\tif (data.insertAfter.length && task.taskAuthorizationInfo.insertTaskAfter) {\r\n\t\t\t\t\t\t\t\trightClickMenuItems.unshift(['Insert Task Below', data.insertAfter])\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tif (data.insertBefore.length && task.taskAuthorizationInfo.insertTaskBefore) {\r\n\t\t\t\t\t\t\t\trightClickMenuItems.unshift(['Insert Task Above', data.insertBefore])\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tdeferred.resolve(rightClickMenuItems);\r\n\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\treturn deferred.promise;\r\n\t\t\t\t}\r\n\r\n\t\t\t\t//Context Menu Functions\r\n\t\t\t\tfunction insertTaskBefore(task, newTaskTypeID) {\r\n\t\t\t\t\tscope.waitingOnServer = true;\r\n\t\t\t\t\ttaskService.insertTask(task, newTaskTypeID, TaskActionTypes.INSERTNEWBEFORETHISTASK).then(function (data) {\r\n\t\t\t\t\t\tupdateAllTasks(data)\r\n\t\t\t\t\t\t$rootScope.$broadcast('entityTaskUpdated');\r\n\t\t\t\t\t});\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction insertTaskAfter(task, newTaskTypeID) {\r\n\t\t\t\t\tscope.waitingOnServer = true;\r\n\t\t\t\t\ttaskService.insertTask(task, newTaskTypeID, TaskActionTypes.INSERTNEWAFTERTHISTASK).then(function (data) {\r\n\t\t\t\t\t\tupdateAllTasks(data)\r\n\t\t\t\t\t\t$rootScope.$broadcast('entityTaskUpdated');\r\n\t\t\t\t\t});\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction deleteTask(task) {\r\n\t\t\t\t\tif (confirm('Are you sure you wish to delete ' + task.name + '?')) {\r\n\t\t\t\t\t\tscope.waitingOnServer = true;\r\n\t\t\t\t\t\ttaskService.deleteTask(task)\r\n\t\t\t\t\t\t\t.then(function (response) {\r\n\t\t\t\t\t\t\t\tupdateAllTasks(response);\r\n\t\t\t\t\t\t\t\t$rootScope.$broadcast('entityTaskUpdated');\r\n\t\t\t\t\t\t\t});\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction reassignTask(task, index) {\r\n\t\t\t\t\tlaunchUserTeamPicker(task, index);\r\n\r\n\t\t\t\t\t//Added this in - if a reassign happens then we need to reload the activity panel\r\n $rootScope.$broadcast('entityTaskUpdated');\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction rescindTask(task) {\r\n\t\t\t\t\tif (confirm('Are you sure you wish to rescind the status of ' + task.name + '?')) {\r\n\t\t\t\t\t\tscope.waitingOnServer = true;\r\n\t\t\t\t\t\ttaskService.rescindTask(task)\r\n\t\t\t\t\t\t\t.then(function (response) {\r\n\t\t\t\t\t\t\t\tupdateAllTasks(response);\r\n\t\t\t\t\t\t\t\t$rootScope.$broadcast('entityTaskUpdated');\r\n\t\t\t\t\t\t\t});\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction skipTask(task) {\r\n\t\t\t\t\tscope.waitingOnServer = true;\r\n\t\t\t\t\ttaskService.skipTask(task)\r\n\t\t\t\t\t\t.then(function (response) {\r\n\t\t\t\t\t\t\tupdateAllTasks(response);\r\n\t\t\t\t\t\t\t$rootScope.$broadcast('entityTaskUpdated');\r\n\t\t\t\t\t\t});\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction completeTask(task, clickedNode) {\r\n\t\t\t\t\tstartSpinner(clickedNode, task);\r\n\t\t\t\t\tscope.waitingOnServer = true;\r\n\r\n\t\t\t\t\ttaskService.completeTask(task)\r\n\t\t\t\t\t\t.then(function (response) {\r\n\t\t\t\t\t\t\tupdateAllTasks(response);\r\n\t\t\t\t\t\t\t$rootScope.$broadcast('entityTaskUpdated');\r\n\t\t\t\t\t\t}).catch(function () {\r\n\t\t\t\t\t\t\tstopSpinner(clickedNode);\r\n\t\t\t\t\t\t\tscope.waitingOnServer = false;\r\n\t\t\t\t\t\t});\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction getHeight(task) {\r\n\t\t\t\t\treturn verticalOffset + (function () {\r\n\t\t\t\t\t\tif (task.isReady) {\r\n\t\t\t\t\t\t\treturn isDeliverable(task) ? heights.xl : heights.lg;\r\n\t\t\t\t\t\t} else if (isDeliverable(task)) {\r\n\t\t\t\t\t\t\treturn heights.md;\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\treturn heights.sm;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t})()\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction updateAllTasks(data) {\r\n\t\t\t\t\tscope.updateData({ data: taskService.splitIntoGroups(data.tasks) });\r\n\t\t\t\t\tscope.waitingOnServer = false;\r\n\t\t\t\t\tstopSpinner();\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction isDeliverable(task) {\r\n\t\t\t\t\treturn task.deliverableName || task.dueDate;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction startSpinner(clickedNode, task) {\r\n\t\t\t\t\td3.select(clickedNode)\r\n\t\t\t\t\t\t.attr('visibility', 'hidden')\r\n\r\n\t\t\t\t\td3.select(clickedNode.parentNode)\r\n\t\t\t\t\t\t.append('text')\r\n\t\t\t\t\t\t.attr('class', 'fa fa-spinner')\r\n\t\t\t\t\t\t.text('\\uf110')\r\n\t\t\t\t\t\t.attr('y', 20)\r\n\t\t\t\t\t\t.attr('x', 5)\r\n\t\t\t\t\t\t.attr('dy', '0.35em')\r\n\t\t\t\t\t\t.style('font', 'var(--fa-font-regular)')\r\n\t\t\t\t\t\t.style('font-weight', '900')\r\n\t\t\t\t\t\t.style('font-size', '24')\r\n\t\t\t\t\t// .style('animation', 'fa-spin 1s infinite steps(8)')\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfunction stopSpinner(clickedNode) {\r\n\t\t\t\t\tif (clickedNode) {\r\n\t\t\t\t\t\td3.select(clickedNode)\r\n\t\t\t\t\t\t\t.attr('visibility', '')\r\n\t\t\t\t\t}\r\n\t\t\t\t\td3.select('text.fa-spinner').remove();\r\n\t\t\t\t}\r\n\r\n\t\t\t\tscope.getLocalTimezone = function () {\r\n\t\t\t\t\treturn moment.tz.guess();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t};\r\n\r\n\t\treturn directive;\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar SERVICE_URL = '/api/Tasks';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory('taskService', taskService);\r\n\r\n\ttaskService.$inject = ['sd.Http.Service', '$uibModal', 'TaskActionTypes', '$q', '$rootScope', 'toastr', 'messageBoxService', 'taskModalsService'];\r\n\r\n\tfunction taskService(sdHttp, $uibModal, TaskActionTypes, $q, $rootScope, toastr, messageBoxService, taskModalsService) {\r\n\t\treturn {\r\n\t\t\tgetByEntity: getByEntity,\r\n\t\t\tgetTaskSummaryByEntity: getTaskSummaryByEntity,\r\n\t\t\tcheckIfEntityMayBeDeactivated : checkIfEntityMayBeDeactivated,\r\n\t\t\tlaunchTaskModal: launchTaskModal,\r\n\t\t\trescindTask: rescindTask,\r\n\t\t\tinsertTask: insertTask,\r\n\t\t\tupdateTask: updateTask,\r\n\t\t\tdeleteTask: deleteTask,\r\n\t\t\tcompleteTask: completeTask,\r\n\t\t\tskipTask: skipTask,\r\n\t\t\tsplitIntoGroups: splitIntoGroups,\r\n\t\t\tgetTaskPermissions: getTaskPermissions,\r\n\t\t\tgetInsertOptions: getInsertOptions,\r\n\t\t\tgetMaxTasksWide: getMaxTasksWide,\r\n changeContacts: changeContacts,\r\n\t\t\treassignMany: reassignMany,\r\n\t\t\tskipMany: skipMany,\r\n\t\t\tcompleteMany: completeMany,\r\n showErrorNotificationModal: showErrorNotificationModal,\r\n\t\t\tvalidateAssessorStateReqs: validateAssessorStateReqs\r\n\t\t};\r\n\r\n\t\tfunction rescindTask(task) {\r\n\t\t\tvar taskProcessRequestDTO = {\r\n\t\t\t\tentityID: task.entityId,\r\n\t\t\t\tentityTypeID: task.entityTypeID,\r\n\t\t\t\ttaskID: task.taskID,\r\n\t\t\t\trowVersion: task.rowVersion,\r\n\t\t\t\tactionID: TaskActionTypes.RESCINDTASK\r\n\t\t\t};\r\n\t\t\tvar url = SERVICE_URL + '/performAction';\r\n\r\n\t\t\treturn sdHttp.put(url, taskProcessRequestDTO);\r\n\t\t}\r\n\r\n\t\tfunction insertTask(task, newTaskTypeID, actionID) {\r\n\t\t\tvar taskProcessRequestDTO = {\r\n\t\t\t\tentityID: task.entityId,\r\n\t\t\t\tentityTypeID: task.entityTypeID,\r\n\t\t\t\ttaskID: task.taskID,\r\n\t\t\t\trowVersion: task.rowVersion,\r\n\t\t\t\tactionID: actionID,\r\n\t\t\t\tnewTaskTypeID: newTaskTypeID\r\n\t\t\t};\r\n\r\n\t\t\tvar url = SERVICE_URL + '/performAction';\r\n\r\n\t\t\treturn sdHttp.put(url, taskProcessRequestDTO);\r\n\t\t}\r\n\r\n\t\tfunction updateTask(task) {\r\n\t\t\tvar taskProcessRequestDTO = {\r\n\t\t\t\tentityID: task.entityId,\r\n\t\t\t\tentityTypeID: task.entityTypeID,\r\n\t\t\t\ttaskID: task.taskID,\r\n\t\t\t\trowVersion: task.rowVersion,\r\n\t\t\t\tactionID: TaskActionTypes.REASSIGNTASK,\r\n\t\t\t\tassignedUserID: task.assignedUserID,\r\n\t\t\t\tassignedTeamID: task.assignedTeamID\r\n\t\t\t};\r\n\t\t\tvar url = SERVICE_URL + '/performAction';\r\n\r\n\t\t\treturn sdHttp.put(url, taskProcessRequestDTO);\r\n\t\t}\r\n\r\n\t\tfunction deleteTask(task) {\r\n\t\t\tvar taskProcessRequestDTO = {\r\n\t\t\t\tentityID: task.entityId,\r\n\t\t\t\tentityTypeID: task.entityTypeID,\r\n\t\t\t\ttaskID: task.taskID,\r\n\t\t\t\trowVersion: task.rowVersion,\r\n\t\t\t\tactionID: TaskActionTypes.DELETETASK\r\n\t\t\t};\r\n\t\t\tvar url = SERVICE_URL + '/performAction';\r\n\r\n\t\t\treturn sdHttp.put(url, taskProcessRequestDTO);\r\n\t\t}\r\n\r\n\t\tfunction skipTask(task) {\r\n\t\t\tvar taskProcessRequestDTO = {\r\n\t\t\t\tentityID: task.entityId,\r\n\t\t\t\tentityTypeID: task.entityTypeID,\r\n\t\t\t\ttaskID: task.taskID,\r\n\t\t\t\trowVersion: task.rowVersion,\r\n\t\t\t\tactionID: TaskActionTypes.SKIPTASK\r\n\t\t\t};\r\n\t\t\tvar url = SERVICE_URL + '/performAction';\r\n\r\n\t\t\treturn sdHttp.put(url, taskProcessRequestDTO);\r\n\t\t}\r\n\r\n\t\tasync function completeTask(task) {\r\n\t\t\tconst warning = await validateAssessorStateReqs([task.taskID]);\r\n\t\t\tif (warning) {\r\n\t\t\t\tawait messageBoxService.warning(warning);\r\n\t\t\t}\r\n\r\n\t\t\tconst taskProcessRequestDTO = {\r\n\t\t\t\tentityID: task.entityId,\r\n\t\t\t\tentityTypeID: task.entityTypeID,\r\n\t\t\t\ttaskID: task.taskID,\r\n\t\t\t\trowVersion: task.rowVersion,\r\n\t\t\t\tactionID: TaskActionTypes.COMPLETETASK\r\n\t\t\t};\r\n\t\t\tconst url = SERVICE_URL + '/performAction';\r\n\r\n\t\t\treturn await sdHttp.put(url, taskProcessRequestDTO);\r\n\t\t}\r\n\r\n\t\tfunction checkIfEntityMayBeDeactivated(entityID, entityTypeID) {\r\n\t\t\tvar params = {\r\n\t\t\t\tentityID: entityID,\r\n\t\t\t\tentityTypeID: entityTypeID\r\n\t\t\t};\r\n\r\n\t\t\tvar url = SERVICE_URL + '/entity/CheckIfMayBeDeactivated';\r\n\r\n\t\t\treturn sdHttp.get(url, { params: params });\r\n\t\t}\r\n\r\n\r\n\t\tfunction getByEntity(entityID, entityTypeID) {\r\n\t\t\tvar params = {\r\n\t\t\t\tentityID: entityID,\r\n\t\t\t\tentityTypeID: entityTypeID\r\n\t\t\t};\r\n\r\n\t\t\tvar url = SERVICE_URL + '/entity';\r\n\r\n\t\t\treturn sdHttp.get(url, { params: params });\r\n\t\t}\r\n\r\n\t\tfunction getTaskSummaryByEntity(entityID, entityTypeID) {\r\n\t\t\tvar params = {\r\n\t\t\t\tentityID: entityID,\r\n\t\t\t\tentityTypeID: entityTypeID\r\n\t\t\t};\r\n\r\n\t\t\tvar url = SERVICE_URL + '/entity/summary';\r\n\r\n\t\t\treturn sdHttp.get(url, { params: params });\r\n\t\t}\r\n\r\n\r\n\t\tfunction getTaskPermissions(entityID, entityTypeID, taskID) {\r\n\t\t\t//var params = {\r\n\t\t\t//\tentityID: entityID,\r\n\t\t\t//\tentityTypeID: entityTypeID,\r\n\t\t\t//\ttaskID: taskID\r\n\t\t\t//};\r\n\r\n\t\t\t//var url = SERVICE_URL + '/permissions';\r\n\r\n\t\t\t//return sdHttp.get(url, { params: params })\r\n\t\t\t//\t.then(function (response) {\r\n\t\t\t//\t\treturn response;\r\n\t\t\t//\t});\r\n\t\t}\r\n\r\n\t\tfunction getInsertOptions(entityID, entityTypeID, taskID) {\r\n\t\t\tvar params = {\r\n\t\t\t\tentityId: entityID,\r\n\t\t\t\tentityTypeID: entityTypeID,\r\n\t\t\t\ttaskID: taskID\r\n\t\t\t};\r\n\r\n\t\t\tvar url = SERVICE_URL + '/InsertOptions';\r\n\r\n\t\t\treturn sdHttp.get(url, { params: params })\r\n\t\t\t\t.then(function (response) {\r\n\t\t\t\t\treturn response;\r\n\t\t\t\t});\r\n\t\t}\r\n\r\n\t\tfunction launchTaskModal(entityID, entityTypeID, readonly, toastMessage, editonly) {\r\n\t\t\tif(toastMessage) {\r\n\t\t\t\ttoastr.info(toastMessage);\r\n\t\t\t}\r\n\r\n\t\t return $q(function (resolve) {\r\n var loadingModal = $uibModal.open({\r\n template: '',\r\n size: 'sm',\r\n\t\t\t\t\twindowClass: 'show',\r\n\t\t\t\t\tbackdropClass: 'show',\r\n animation: false\r\n })\r\n\r\n getByEntity(entityID, entityTypeID)\r\n .then(function (result) {\r\n // HACK: The task modal doesn't have the concept of \"readonly\" built-in,\r\n // but it does read permissions to check if it should allow changes; we'll\r\n // overwrite the permission data here to put the modal in read-only mode.\r\n if (readonly) {\r\n var targetTasks = [];\r\n if (result && result.tasks) {\r\n targetTasks = result.tasks\r\n }\r\n\r\n _.forEach(targetTasks, function (task) {\r\n task.taskAuthorizationInfo = {\r\n completeTask: false,\r\n deleteTask: false,\r\n insertTaskAfter: false,\r\n insertTaskBefore: false,\r\n reassignTask: false,\r\n rescindTask: false,\r\n skipTask: false\r\n };\r\n });\r\n }\r\n\r\n if(editonly) {\r\n var targetTasks = [];\r\n if (result && result.tasks) {\r\n targetTasks = result.tasks\r\n }\r\n _.forEach(targetTasks, function (task) {\r\n if(task.taskAuthorizationInfo) {\r\n task.taskAuthorizationInfo.completeTask = false;\r\n }\r\n });\r\n }\r\n var taskGroupsBySequence = splitIntoGroups(result.tasks);\r\n var tasksWide = getMaxTasksWide(taskGroupsBySequence);\r\n var modalSize = tasksWide > 1 ? 'lg' : 'sm';\r\n var windowClass = '';\r\n\r\n if (tasksWide > 1) {\r\n windowClass = tasksWide < 4 ? 'task-modal-' + tasksWide : 'task-modal-xl';\r\n }\r\n\r\n var modalInstance = $uibModal.open({\r\n templateUrl: 'app/Task/_tasksModal.html',\r\n controller: 'TasksModalController',\r\n controllerAs: 'vm',\r\n size: modalSize,\r\n windowClass: `${windowClass} show`,\r\n\t\t\t\t\t\t\tbackdropClass: 'show',\r\n resolve: {\r\n tasks: function () {\r\n return taskGroupsBySequence;\r\n }\r\n }\r\n });\r\n\r\n var reloadRequired = false;\r\n\r\n // HACK: The AngularJS version of this used events to notify that entity task summaries\r\n // need to be reloaded; for Angular 2+ it's easier for this function to return a promise\r\n // whose resolution is a bool indicating if the tasks changed.\r\n // Watch for events, then return \"true\" if the entity task was updated while the modal\r\n // was open.\r\n var taskUpdateListener = $rootScope.$on('entityTaskUpdated', function () {\r\n reloadRequired = true;\r\n });\r\n\r\n modalInstance.rendered\r\n .then(function () {\r\n loadingModal.dismiss();\r\n })\r\n\r\n modalInstance.closed.then(function () {\r\n // Remove the listener\r\n taskUpdateListener();\r\n resolve(reloadRequired);\r\n });\r\n\r\n modalInstance.result\r\n .then(function () { });\r\n })\r\n\t\t });\r\n\t\t}\r\n\r\n\t\tfunction changeContacts(request) {\r\n\t\t return sdHttp.put(SERVICE_URL + '/changecontacts', request);\r\n\t\t}\r\n\r\n\t\tfunction reassignMany(reassignObj) {\r\n\t\t return sdHttp.put(SERVICE_URL + '/reassignUser', reassignObj);\r\n\t\t}\r\n\r\n\t\tfunction skipMany(taskIds) {\r\n\t\t return sdHttp.put(SERVICE_URL + '/skiptasks', taskIds);\r\n\t\t}\r\n\r\n\t\tfunction completeMany(taskIds) {\r\n\t\t return sdHttp.put(SERVICE_URL + '/completetasks', taskIds);\r\n\t\t}\r\n\r\n\t // Errors and warnings are string arrays, error message will be shown over error messages\r\n\t // and warning message will be shown over warning messages (warningMessage is optional,\r\n // even if the warning array has entries)\r\n\t\tfunction showErrorNotificationModal(errors, warnings, errorMessage, warningMessage) {\r\n taskModalsService.showErrorNotificationModal(errors, warnings, errorMessage, warningMessage);\r\n\t\t}\r\n\r\n\t\tfunction getMaxTasksWide(taskGroupsBySequence) {\r\n\t\t\treturn _.chain(taskGroupsBySequence)\r\n\t\t\t\t.map(function (taskGroupCollection) {\r\n\t\t\t\t\treturn taskGroupCollection.taskGroups.length;\r\n\t\t\t\t})\r\n\t\t\t\t.max()\r\n\t\t\t\t.value();\r\n\t\t}\r\n\r\n\t\tfunction splitIntoGroups(tasks) {\r\n\t\t\tvar idSequencer = 0;\r\n\t\t\tvar taskGroupArr = [];\r\n\t\t\tvar firstGroup = {\r\n\t\t\t\ttasks: [],\r\n\t\t\t\tsequence: 1,\r\n\t\t\t\tid: idSequencer++\r\n\t\t\t};\r\n\t\t\tvar firstTask = _.find(tasks, { sequence: 1 });\r\n\r\n\t\t\tcompileThing(firstTask, firstGroup);\r\n\r\n\t\t\treturn _.chain(taskGroupArr)\r\n\t\t\t\t.groupBy('sequence')\r\n\t\t\t\t.map(function (taskGroups, sequence) {\r\n\t\t\t\t\treturn {\r\n\t\t\t\t\t\ttaskGroups: taskGroups,\r\n\t\t\t\t\t\tsequence: Number(sequence)\r\n\t\t\t\t\t};\r\n\t\t\t\t})\r\n\t\t\t\t.value();\r\n\r\n\t\t\tfunction compileThing(task, group) {\r\n\t\t\t\tgroup.tasks.push(task);\r\n\r\n\t\t\t\tif (task.pointsTo.length > 1) {\r\n\t\t\t\t\t_.forEach(task.pointsTo, function (taskID) {\r\n\t\t\t\t\t\tvar firstTask = _.find(tasks, { taskID: taskID });\r\n\t\t\t\t\t\tvar newGroup = {\r\n\t\t\t\t\t\t\ttasks: [],\r\n\t\t\t\t\t\t\tsequence: group.sequence + 1,\r\n\t\t\t\t\t\t\tid: idSequencer++\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tcompileThing(firstTask, newGroup)\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\ttaskGroupArr.unshift(group);\r\n\t\t\t\t} else if (task.pointsTo.length === 1) {\r\n\t\t\t\t\tvar nextTask = _.find(tasks, { taskID: task.pointsTo[0] });\r\n\r\n\t\t\t\t\tvar otherTasksThatPointToIt = _.filter(tasks, function (t) {\r\n\t\t\t\t\t\treturn _.includes(t.pointsTo, task.pointsTo[0]) && t.taskID !== task.taskID;\r\n\t\t\t\t\t})\r\n\r\n\t\t\t\t\tvar taskIds = _.chain(taskGroupArr)\r\n\t\t\t\t\t\t.map('tasks')\r\n\t\t\t\t\t\t.flatten()\r\n\t\t\t\t\t\t.map('taskID')\r\n\t\t\t\t\t\t.value();\r\n\r\n\t\t\t\t\tif (otherTasksThatPointToIt.length) {\r\n\t\t\t\t\t\ttaskGroupArr.unshift(group);\r\n\t\t\t\t\t\tif (!_.includes(taskIds, nextTask.taskID)) {\r\n\t\t\t\t\t\t\tvar newGroup = {\r\n\t\t\t\t\t\t\t\ttasks: [],\r\n\t\t\t\t\t\t\t\tsequence: group.sequence + 1,\r\n\t\t\t\t\t\t\t\tid: idSequencer++\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tcompileThing(nextTask, newGroup);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tcompileThing(nextTask, group);\r\n\t\t\t\t\t}\r\n\t\t\t\t} else {\r\n\t\t\t\t\ttaskGroupArr.unshift(group)\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tasync function validateAssessorStateReqs(taskSeriesIds) {\r\n\t\t\treturn await sdHttp.post(SERVICE_URL + '/ValidateAssessorStateReqs', taskSeriesIds);\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller('TasksModalController', TasksModalController);\r\n\r\n\tTasksModalController.$inject = ['$uibModalInstance', 'tasks', 'taskService', '$scope'];\r\n\r\n\tfunction TasksModalController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit($uibModalInstance, tasks, taskService, $scope) {\r\n\t\tvar vm = this;\r\n\t\tvar heights = {\r\n\t\t\tsm: 50,\r\n\t\t\tmd: 75,\r\n\t\t\tlg: 100,\r\n\t\t\txl: 125\r\n\t\t};\r\n\r\n\t\tvm.chevronWidth = 244;\r\n\t\tvm.chevronPadding = 10;\r\n\t\tvm.taskSeriesPadding = 10;\r\n\t\tvm.waitingOnServer = false;\r\n\r\n\t\tvm.closeModal = closeModal;\r\n\t\tvm.updateData = updateData;\r\n\t\tvm.getPlacement = getPlacement;\r\n\r\n\t\tactivate();\r\n\r\n\t\t////////////////\r\n\r\n\t\t$scope.$on('modal.closing', function (event, result, closed) {\r\n\t\t\tif (vm.waitingOnServer) {\r\n\t\t\t\tevent.preventDefault();\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\tfunction activate() {\r\n\t\t\tvm.taskGroupsBySequence = _.map(tasks, getTaskGroupHeights);\r\n\t\t}\r\n\r\n\t\tfunction getTaskGroupHeights(taskGroupCollection) {\r\n\t\t\ttaskGroupCollection.taskGroups = _.chain(taskGroupCollection.taskGroups)\r\n\t\t\t\t.sortBy([function (taskGroup) {\r\n\t\t\t\t\tvar maxDueDate = _.chain(taskGroup.tasks)\r\n\t\t\t\t\t\t.map(function (task) {\r\n\t\t\t\t\t\t\treturn task.dueDate ? moment(task.dueDate).startOf('day').toDate().getTime() : null;\r\n\t\t\t\t\t\t})\r\n\t\t\t\t\t\t.compact()\r\n\t\t\t\t\t\t.max()\r\n\t\t\t\t\t\t.value();\r\n\r\n\t\t\t\t\treturn maxDueDate === -Infinity ? null : maxDueDate;\r\n\t\t\t\t}, function (taskGroup) {\r\n\t\t\t\t\treturn taskGroup.tasks[0].entityId;\r\n\t\t\t\t}])\r\n\t\t\t\t.map(function (taskGroup) {\r\n\t\t\t\t\ttaskGroup.height = _.reduce(taskGroup.tasks, function (result, task) {\r\n\t\t\t\t\t\treturn result + getHeight(task);\r\n\t\t\t\t\t}, 0);\r\n\t\t\t\t\ttaskGroup.height += vm.chevronPadding;\r\n\t\t\t\t\ttaskGroup.height += _.last(taskGroup.tasks).pointsTo.length ? vm.chevronPadding : heights.lg;\r\n\r\n\t\t\t\t\treturn taskGroup;\r\n\t\t\t\t})\r\n\t\t\t\t.value();\r\n\r\n\t\t\tvar maxHeight = _.maxBy(taskGroupCollection.taskGroups, 'height').height;\r\n\r\n\t\t\ttaskGroupCollection.taskGroups = _.map(taskGroupCollection.taskGroups, function (taskGroup) {\r\n\t\t\t\ttaskGroup.maxHeight = maxHeight;\r\n\t\t\t\treturn taskGroup;\r\n\t\t\t});\r\n\r\n\t\t\treturn taskGroupCollection;\r\n\t\t}\r\n\r\n\t\tfunction updateData(data) {\r\n\t\t\tvm.taskGroupsBySequence = _.map(data, getTaskGroupHeights);\r\n\t\t}\r\n\r\n\t\tfunction getHeight(task) {\r\n\t\t\tif (task.isReady) {\r\n\t\t\t\treturn isDeliverable(task) ? heights.xl : heights.lg;\r\n\t\t\t} else if (isDeliverable(task)) {\r\n\t\t\t\treturn heights.md;\r\n\t\t\t} else {\r\n\t\t\t\treturn heights.sm;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction isDeliverable(task) {\r\n\t\t\treturn task.deliverableName || task.dueDate;\r\n\t\t}\r\n\r\n\t\tfunction closeModal() {\r\n\t\t\t$uibModalInstance.dismiss();\r\n\t\t}\r\n\r\n\t\tfunction getPlacement(index) {\r\n\t\t\tif (index < 2 && vm.taskGroupsBySequence && taskService.getMaxTasksWide(vm.taskGroupsBySequence) > 2) {\r\n\t\t\t\treturn 'right';\r\n\t\t\t} else {\r\n\t\t\t\treturn 'left'\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n 'use strict';\r\n\r\n angular\r\n .module('weissmanApp')\r\n .controller('ErrorNotificationModalController', ErrorNotificationModalController);\r\n\r\n ErrorNotificationModalController.$inject = ['errors', 'warnings', 'errorMessage', 'warningMessage', '$uibModalInstance'];\r\n\r\n function ErrorNotificationModalController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit(errors, warnings, errorMessage, warningMessage, $uibModalInstance) {\r\n var vm = this;\r\n vm.errors = errors;\r\n vm.warnings = warnings;\r\n if (errorMessage && !warningMessage) {\r\n vm.topLevelMessage = errorMessage;\r\n }\r\n else {\r\n vm.errorMessage = errorMessage;\r\n vm.warningMessage = warningMessage;\r\n }\r\n\r\n activate();\r\n\r\n function activate() { }\r\n\r\n vm.close = function () {\r\n $uibModalInstance.dismiss();\r\n }\r\n }\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller('ReassignTaskModalController', ReassignTaskModalController);\r\n\r\n\tReassignTaskModalController.$inject = ['$uibModalInstance', 'taskService', 'taskIDs', 'searchTimestamp', 'ReassignModes', 'reassignMode', 'instanceId', 'featureFlagsService'];\r\n\r\n\tfunction ReassignTaskModalController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit($uibModalInstance, taskService, taskIDs, searchTimestamp, ReassignModes, reassignMode, instanceId, featureFlagsService) {\r\n\t\tvar vm = this;\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\t\t\tvm.user = {};\r\n\t\t\tvm.reassignMode = reassignMode;\r\n\t\t\tvm.ReassignModes = ReassignModes;\r\n\r\n\t\t\tif(featureFlagsService.featureFlags.enableMultiUserPermissionsCheck){\r\n\t\t\t\tvm.entityIdsMultiselect = taskIDs;\r\n\t\t\t\tvm.entityType = 'Task';\r\n\t\t\t}\r\n\t\t\telse{\r\n\t\t\t\tvm.entityId = instanceId;\r\n\t\t\t\tvm.entityType = 'Instance';\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tvm.save = function () {\r\n\t\t $uibModalInstance.close(function () {\r\n\t\t switch (reassignMode) {\r\n\t\t case ReassignModes.Default:\r\n var reassignRequest = _.cloneDeep(vm.user);\r\n reassignRequest.taskIds = taskIDs;\r\n reassignRequest.searchTimestamp = searchTimestamp;\r\n return taskService.reassignMany(reassignRequest);\r\n\t\t case ReassignModes.ChangeContact:\r\n\t\t var changeRequest = {\r\n\t\t taskIds: taskIDs,\r\n\t\t searchTimestamp: searchTimestamp,\r\n\t\t userId: vm.user.userID,\r\n teamId: vm.user.teamID\r\n\t\t };\r\n return taskService.changeContacts(changeRequest);\r\n\t\t default:\r\n\t\t throw new Error(\"Unrecognized reassign mode \" + reassignMode);\r\n\t\t }\r\n\t\t });\r\n\t\t}\r\n\r\n\t\tvm.cancel = function () {\r\n\t\t\t$uibModalInstance.dismiss();\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar VIEW_TEMPLATE_URL = 'app/Team/Assignment/_teamAssignmentPanel.html';\r\n\t//\tvar CONTROLLER_NAME = 'sdTeamAssignmentPanelController';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdTeamAssignmentPanel', sdTeamAssignmentPanel);\r\n\r\n\tsdTeamAssignmentPanel.$inject = ['teamsService', 'toastr', 'utils','SD.Restrict.Service','InstanceRights','instanceRepository','EntityTypeIDs', 'messageBoxService'];\r\n\r\n\tfunction sdTeamAssignmentPanel(teamsService, toastr, utils, restrictService, InstanceRights,instanceRepository,EntityTypeIDs, messageBoxService) {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\t// controllerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tuser: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {\r\n\t\t\tvar cleanAssignedTeams = [];\r\n\r\n\t\t\tscope.unaddedTeams = [];\r\n\t\t\tscope.loading = false;\r\n\t\t\tscope.newTeam = {};\r\n\t\t\tscope.newTeamForTasks = {};\r\n\t\t\tscope.originalDefault = {};\r\n\t\t\tscope.canEdit = false;\r\n\t\t\tscope.isEditMode = false;\r\n\r\n\t\t\tscope.addTeam = addTeam;\r\n\t\t\tscope.updateDefault = updateDefault;\r\n\t\t\tscope.checkLinkedEntities = checkLinkedEntities;\r\n\t\t\tscope.chooseNewTeam = chooseNewTeam;\r\n\t\t\tscope.cancelChooseNewTeam = cancelChooseNewTeam;\r\n\t\t\tscope.nonDeletedFilter = utils.nonDeletedFilter;\r\n\t\t\tscope.addedTeams = addedTeams;\r\n\t\t\tscope.removeTeam = removeTeam;\r\n\t\t\tscope.save = save;\r\n\t\t\tscope.isSaveDisabled = isSaveDisabled;\r\n\t\t\tscope.addTeamRow = addTeamRow;\r\n\t\t\tscope.isLrpRunning = false;\r\n\r\n\t\t\tscope.switchToEditMode = function() {\r\n\t\t\t\tscope.isEditMode = true;\r\n\t\t\t}\r\n\r\n\t\t\tscope.cancel = function() {\r\n\t\t\t\tscope.assignedTeams = angular.copy(cleanAssignedTeams);\r\n\t\t\t\tscope.isEditMode = false;\r\n\t\t\t}\r\n\r\n\t\t\tactivate();\r\n\r\n\t\t\tfunction addedTeams(team) {\r\n\t\t\t\treturn _.every(scope.assignedTeams, function(assignedTeam) {\r\n\t\t\t\t\treturn assignedTeam.teamID !== team.teamID || assignedTeam.efAction === 'delete';\r\n\t\t\t\t})\r\n\t\t\t}\r\n\r\n\t\t\tasync function activate() {\r\n\t\t\t\t//get instance id\r\n\t\t\t\tscope.loading = true;\r\n\r\n\t\t\t\ttry {\r\n\t\t\t\t\tconst instanceId = await instanceRepository.getEntityInstanceId('company', scope.user.companyID).toPromise();\r\n\t\t\t\t\tscope.canEdit = restrictService.hasInstanceRight(InstanceRights.MANAGEUSERSETUP, instanceId);\r\n\t\r\n\t\t\t\t\tif (scope.user.userID) {\r\n\t\t\t\t\t\tvar filter = {\r\n\t\t\t\t\t\t\tgetFullInfo: true,\r\n\t\t\t\t\t\t\tincludeCompanyRepresentative: true\r\n\t\t\t\t\t\t};\r\n\t\r\n\t\t\t\t\t\tconst teams = await teamsService.getAllContactUserTeams(scope.user.contactID, filter);\r\n\t\t\t\t\t\tprocessAssignedTeams(teams);\r\n\t\r\n\t\t\t\t\t\tconst response = await teamsService.getAllTeamsForContact(false, instanceId, scope.user.userID);\r\n\t\t\t\t\t\tscope.allTeams = angular.copy(response);\r\n\t\t\t\t\t}\r\n\t\t\t\t} finally {\r\n\t\t\t\t\tscope.loading = false;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction processAssignedTeams(teams) {\r\n\t\t\t\tscope.assignedTeams = teams;\r\n\t\t\t\tcleanAssignedTeams = angular.copy(teams);\r\n\t\t\t\tscope.originalDefault = _.find(teams, { isDefault: true });\r\n\t\t\t}\r\n\r\n\t\t\tfunction updateDefault(team) {\r\n\t\t\t\t_.each(scope.assignedTeams, function (item) {\r\n\t\t\t\t\titem.isDefault = (item.teamID === team.teamID);\r\n\t\t\t\t});\r\n\t\t\t}\r\n\r\n\t\t\tfunction checkLinkedEntities(team) {\r\n\t\t\t\tif(!team.isAssignable) {\r\n\t\t\t\t\tteam.loading = true;\r\n\t\t\t\t\tteamsService.hasLinkedEntities(scope.user.userID, team.teamID)\r\n\t\t\t\t\t\t.then(function(result) {\r\n\t\t\t\t\t\t\t//console.log(result);\r\n\t\t\t\t\t\t\tif(result.hasLinkedEntities) {\r\n\t\t\t\t\t\t\t\tif(_.some(scope.assignedTeams, 'isAssignable')) {\r\n\t\t\t\t\t\t\t\t\tteam.chooseNew = true;\r\n\t\t\t\t\t\t\t\t\tteam.message = result.message + ' Please choose another team to which they can be assigned.';\r\n\t\t\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t\t\tteam.isAssignable = true;\r\n\r\n\t\t\t\t\t\t\t\t\ttoastr.info(result.message + ' Please add another team that is assignable before removing this one.');\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tteam.loading = false;\r\n\t\t\t\t\t\t})\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction cancelChooseNewTeam(team) {\r\n\t\t\t\tteam.isAssignable = true;\r\n\t\t\t\tteam.chooseNew = false;\r\n\t\t\t}\r\n\r\n\t\t\tfunction chooseNewTeam(editedTeam) {\r\n\t\t\t\tvar chosenTeam = scope.newTeamForTasks.team;\r\n\t\t\t\teditedTeam.chooseNew = false;\r\n\t\t\t\teditedTeam.newTeamID = chosenTeam.teamID;\r\n\r\n\t\t\t\tchosenTeam.isLocked = true;\r\n\t\t\t}\r\n\r\n\t\t\tfunction removeTeam(team) {\r\n\t\t\t\tif(team.efAction === 'add') {\r\n\t\t\t\t\t_.remove(scope.assignedTeams, team);\r\n\t\t\t\t} else {\r\n\t\t\t\t\tteam.efAction = 'delete';\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfunction addTeam(team) {\r\n\t\t\t\tvar isDefault = false;\r\n\t\t\t\tvar team = scope.newTeam.team;\r\n\t\t\t\tif (scope.assignedTeams.length === 0 ||\r\n\t\t\t\t\t_.findIndex(scope.assignedTeams, { 'isDefault': true }) === -1) {\r\n\t\t\t\t\tisDefault = true;\r\n\t\t\t\t}\r\n if(team) {\r\n\t\t\t\tvar deletedTeamIdx = _.findIndex(scope.assignedTeams, {teamID: team.teamID});\r\n\r\n\t\t\t\tif(deletedTeamIdx !== -1) {\r\n\t\t\t\t\tscope.assignedTeams[deletedTeamIdx].efAction = null;\r\n\t\t\t\t\tscope.assignedTeams[deletedTeamIdx].isDefault = false;\r\n\r\n\t\t\t\t\treturn;\r\n\t\t\t\t} \r\n\r\n\t\t\t\tvar addedTeam = {\r\n\t\t\t\t\tisAssignable: true,\r\n\t\t\t\t\tisDefault: isDefault,\r\n\t\t\t\t\tteamID: team.teamID,\r\n\t\t\t\t\tuserID: scope.user.userID,\r\n\t\t\t\t\tteamName: team.name,\r\n\t\t\t\t\tefAction: 'add',\r\n\t\t\t\t\tfirstName: scope.user.firstName,\r\n\t\t\t\t\tlastName: scope.user.lastName,\r\n\t\t\t\t\tnumberOfClientServiceResponsibilities: 0,\r\n\t\t\t\t\tnewTeamID: null\r\n\t\t\t\t};\r\n\r\n\t\t\t\tscope.assignedTeams.push(addedTeam);\r\n\r\n\t\t\t\tif (isDefault) {\r\n\t\t\t\t\tscope.originalDefault = addedTeam;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\tscope.addNewTeam = false;\r\n\t\t\t}\r\n\r\n\t\t\tfunction addTeamRow() {\r\n\t\t\t\tscope.addNewTeam = true;\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tscope.$on('modal.closing', function (event) {\r\n\t\t\t\tif(scope.isEditMode) {\r\n\t\t\t\t\tevent.preventDefault();\r\n\t\r\n\t\t\t\t\tmessageBoxService.confirm('Editing is in progress. Are you sure you want to leave?').then(function() {\r\n\t\t\t\t\t\tscope.isEditMode = false;\r\n\t\t\t\t\t\tevent.targetScope.$dismiss();\r\n\t\t\t\t\t});\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\tfunction save() {\r\n\t\t\t\tvar teamsToSave = _.map(angular.copy(scope.assignedTeams), function(team) {\r\n\t\t\t\t\tvar strippedTeam = _.omit(team, 'isLocked', 'loading', 'chooseNew');\r\n\r\n\t\t\t\t\tif(!team.efAction) {\r\n\t\t\t\t\t\tvar cleanTeam = _.find(cleanAssignedTeams, {teamID: strippedTeam.teamID});\r\n\r\n\t\t\t\t\t\tif(!_.isEqual(strippedTeam, cleanTeam)) {\r\n\t\t\t\t\t\t\tstrippedTeam.efAction = 'update';\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} \r\n\r\n\t\t\t\t\treturn strippedTeam;\r\n\t\t\t\t});\r\n\r\n\t\t\t\tscope.loading = true;\r\n\t\t\t\tteamsService.saveTeamAssignmentTab(teamsToSave) \r\n\t\t\t\t\t.then(processAssignedTeams(teamsToSave))\r\n\t\t\t\t\t.finally(function() {\r\n\t\t\t\t\t\tscope.isEditMode = false;\r\n\t\t\t\t\t\tscope.loading = false;\r\n\t\t\t\t\t\tscope.isLrpRunning = true;\r\n\t\t\t\t\t})\r\n\t\t\t}\r\n\r\n\t\t\tfunction isSaveDisabled() {\r\n\t\t\t\treturn _.some(scope.assignedTeams, function(team) {\r\n\t\t\t\t\treturn team.loading || team.chooseNew;\r\n\t\t\t\t})\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdTeamPicker', sdTeamPicker);\r\n\r\n\t// sdTeamPicker.$inject = [];\r\n\r\n\tfunction sdTeamPicker() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Team/_teamPicker.html',\r\n\t\t\tscope: {\r\n\t\t\t\tteamId: '=',\r\n\t\t\t\tteam: '=?',\r\n\t\t\t\tcloseFn: '&',\r\n\t\t\t\tclickFn: '&',\r\n\t\t\t\tpickerSm: '=?',\r\n\t\t\t\tappendToElement: '=?',\r\n\t\t\t\tisReassign: '=?'\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {\r\n\r\n\t\t}\r\n\t}\r\n\r\n\tController.$inject = ['teamsService', '$timeout'];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(teamsService, $timeout) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.teams = [];\r\n\t\tvm.selectedTeam = {};\r\n\t\tvm.team = vm.team || {};\r\n\r\n\t\tvm.formatInput = formatInput;\r\n\t\tvm.teamSelected = teamSelected;\r\n\t\tvm.filterTeam = filterTeam;\r\n\t\tvm.changed = changed;\r\n\t\tvm.revertLabel = revertLabel;\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\t\t\tteamsService.getAllTeams(false)\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t\tvm.teams = result;\r\n\r\n\t\t\t\t\tvm.selectedTeam = _.find(vm.teams, { teamID: vm.teamId }) || {};\r\n\t\t\t\t})\r\n\t\t}\r\n\r\n\t\tfunction formatInput(model) {\r\n\t\t\tif (_.isEmpty(model)) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\treturn model.name;\r\n\t\t}\r\n\r\n\t\tfunction teamSelected($item) {\r\n\t\t\tvm.teamId = $item.teamID;\r\n\t\t\tvm.team = {\r\n\t\t\t\tteamID: $item.teamID,\r\n\t\t\t\tname: $item.name\r\n\t\t\t}\r\n\r\n\t\t\t$timeout(vm.closeFn);\r\n\t\t}\r\n\r\n\t\tfunction filterTeam(val) {\r\n\t\t\tvar teams = _.filter(vm.teams, function (team) {\r\n\t\t\t\treturn _.includes(team.name.toLowerCase(), val.toLowerCase());\r\n\t\t\t})\r\n\r\n\t\t\treturn teams\r\n\t\t}\r\n\r\n\t\tfunction changed() {\r\n\t\t\tif (!vm.selectedTeam) {\r\n\t\t\t\tvm.teamId = null;\r\n\t\t\t\tvm.team = {};\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction revertLabel() {\r\n\t\t\tvm.selectedTeam = _.find(vm.teams, { teamID: vm.teamId }) || {};\r\n\t\t}\r\n\t}\r\n\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdUserPicker', sdUserPicker);\r\n\r\n\t// sdUserPicker.$inject = [];\r\n\r\n\tfunction sdUserPicker() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Team/User-Picker/_userPicker.html',\r\n\t\t\tscope: {\r\n\t\t\t\tuserId: '=',\r\n\t\t\t\tassignee: '=?',\r\n\t\t\t\tcloseFn: '&',\r\n\t\t\t\tclickFn: '&',\r\n\t\t\t\tpickerSm: '=?',\r\n\t\t\t\tappendToBody: '=?',\r\n\t\t\t\tisReassign: '=?',\r\n\t\t\t\trequired: '=?',\r\n\t\t\t\tname: '=?'\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs, vm) {\r\n\t\t // In this case we have a required attribute with no value, which means it is required\r\n\t\t if (attrs.required === \"\") {\r\n\t\t vm.required = true;\r\n\t\t }\r\n\t\t}\r\n\t}\r\n\r\n\tController.$inject = ['teamsService', '$timeout'];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(teamsService, $timeout) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.users = [];\r\n\t\tvm.selectedUser = {};\r\n\t\tvm.assignee = vm.assignee || {};\r\n\r\n\t\tvm.formatInput = formatInput;\r\n\t\tvm.userSelected = userSelected;\r\n\t\tvm.filterUser = filterUser;\r\n\t\tvm.orderFn = orderFn;\r\n\t\tvm.changed = changed;\r\n\t\tvm.revertLabel = revertLabel;\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\t\t\tteamsService.getAllAssignableUsers(vm.isReassign)\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t console.log([\"UserPicker get assignable users\", _.cloneDeep(result)]);\r\n\t\t\t\t\tvm.users = result;\r\n\r\n\t\t\t\t\tvm.selectedUser = _.find(vm.users, { userID: vm.userId }) || {};\r\n\t\t\t\t})\r\n\t\t}\r\n\r\n\t\tfunction formatInput(model) {\r\n\t\t\tif (_.isEmpty(model)) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\treturn model.lastName + ', ' + model.firstName;\r\n\t\t}\r\n\r\n\t\tfunction userSelected($item) {\r\n\t\t\tvm.userId = $item.userID;\r\n\t\t\tvm.assignee = _.pick($item, 'userID', 'firstName', 'lastName');\r\n\r\n\t\t\t$timeout(vm.closeFn);\r\n\t\t}\r\n\r\n\t\tfunction filterUser(val) {\r\n\t\t return _.uniqBy(_.filter(vm.users, function (user) {\r\n return _.includes(user.lastName.toLowerCase(), val.toLowerCase()) ||\r\n _.includes(user.firstName.toLowerCase(), val.toLowerCase());\r\n }), function (user) {\r\n return user.userID;\r\n });\r\n\t\t}\r\n\r\n\t\tfunction orderFn(user) {\r\n\t\t\treturn user.lastName + user.firstName;\r\n\t\t}\r\n\r\n\t\tfunction changed() {\r\n\t\t\tif (!vm.selectedUser) {\r\n\t\t\t\tvm.userId = null;\r\n\t\t\t\tvm.assignee = {};\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction revertLabel() {\r\n\t\t\tvm.selectedUser = _.find(vm.users, { userID: vm.userId }) || {};\r\n\t\t}\r\n\t}\r\n\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdUserTeamPicker', sdUserTeamPicker);\r\n\r\n\t// sdUserTeamPicker.$inject = [];\r\n\r\n\tfunction sdUserTeamPicker() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\tcontroller: Controller,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/Team/User-Team-Picker/_userTeamPicker.html',\r\n\t\t\tscope: {\r\n\t\t\t\tuserId: '=',\r\n\t\t\t\tteamId: '=',\r\n\t\t\t\tteam: '=?',\r\n\t\t\t\tassignee: '=?',\r\n\t\t\t\tcloseFn: '&',\r\n\t\t\t\tclickFn: '&',\r\n\t\t\t\tpickerSm: '=?',\r\n\t\t\t\tappendToBody: '=?',\r\n\t\t\t\tisReassign: '=?',\r\n\t\t\t\trequired: '=?',\r\n\t\t\t\tshowClearButton: '=?',\r\n\t\t\t\tname: '=?',\r\n\t\t\t\tdisabled: '=?',\r\n\t\t\t\tvalueSetFromOutside: '=?',\r\n\t\t\t\tincludeCompanyRepresentative: '=?',\r\n\t\t\t\trestrictToRyanInstance: '=',\r\n\t\t\t\tentityIdScope: '=',\r\n\t\t\t\tentityTypeScope:'=',\r\n\t\t\t\tinstanceIdScope:'=',\r\n\t\t\t\tincludeInactiveContacts: '=?',\r\n\t\t\t\tentityIdsMultiselectScope: '=?',\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs, vm) {\r\n\t\t // In this case we have a required attribute with no value, which means it is required\r\n\t\t if (attrs.required === \"\") {\r\n\t\t vm.required = true;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\tController.$inject = ['teamsService', '$timeout', '$scope'];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit(teamsService, $timeout, $scope) {\r\n\t\tvar vm = this;\r\n\r\n\t\tvm.users = [];\r\n\t\tvm.selectedUser = {};\r\n\t\tvm.team = vm.team || {};\r\n\t\tvm.assignee = vm.assignee || {};\r\n\t\tvm.formatInput = formatInput;\r\n\t\tvm.userSelected = userSelected;\r\n\t\tvm.filterUserTeam = filterUserTeam;\r\n\t\tvm.orderFn = orderFn;\r\n\t\tvm.changed = changed;\r\n\t\tvm.revertLabel = revertLabel;\r\n\t\tvm.clearData = clearData;\r\n\r\n\t\t$scope.$watch('vm.valueSetFromOutside', function (newValue, oldValue, scope) {\r\n\t\t\t//console.log(\"vm.valueSetFromOutside has been changed!\", newValue, oldValue);\r\n\t\t\tif (newValue){\r\n\t\t\t\tvm.selectedUser = newValue;\r\n\t\t\t\tuserSelected(newValue);\r\n\t\t\t}\r\n\t\t}, true);\r\n\r\n\t\tactivate();\r\n\r\n\t\tfunction activate() {\r\n\t\t\tgetAssignableUsers();\r\n\t\t}\r\n\r\n\t\tfunction getAssignableUsers() {\r\n\t\t\t//call endpoint that is locked down to Ryan contacts only\r\n\t\t\tif(vm.restrictToRyanInstance === true) {\r\n\t\t\t\tteamsService.getAllAssignableRyanUsers(vm.includeCompanyRepresentative, vm.entityIdScope, vm.entityTypeScope)\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t\tvm.users = result;\r\n\r\n\t\t\t\t\tlet foundUser = _.find(vm.users, { userID: vm.userId, teamID: vm.teamId });\r\n\t\t\t\t\tpatchUsersWithAssignedUserIfMissing(foundUser);\r\n\t\t\t\t\tvm.selectedUser = foundUser || vm.assignee;\r\n\t\t\t\t})\t\t\t\r\n\t\t\t}\r\n\t\t\t//get contacts for \r\n\t\t\telse {\r\n\t\t\t\tteamsService.getAllAssignableUsers(vm.isReassign, vm.includeCompanyRepresentative, vm.entityIdScope, vm.entityTypeScope, vm.instanceIdScope, vm.includeInactiveContacts, vm.entityIdsMultiselectScope)\r\n\t\t\t\t.then(function (result) {\r\n\t\t\t\t\tvm.users = result;\r\n\r\n\t\t\t\t\tlet foundUser = _.find(vm.users, { userID: vm.userId, teamID: vm.teamId });\r\n\t\t\t\t\tpatchUsersWithAssignedUserIfMissing(foundUser);\r\n\r\n\t\t\t\t\tvm.selectedUser = foundUser || vm.assignee;\t\t\t\t\t\r\n\t\t\t\t})\t\t\t\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t//insert current assigned user if missing - cross instance assignments (consulting engagements)\r\n\t\tfunction patchUsersWithAssignedUserIfMissing(foundUser) {\r\n\t\t\tif (!foundUser && Object.keys(vm.assignee).length !== 0) {\r\n\t\t\t\tvm.assignee.teamName = vm.team.name;\r\n\t\t\t\tvm.users.push(vm.assignee);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction formatInput(model) {\r\n\t\t\tif (_.isEmpty(model)) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\treturn model.lastName + ', ' + model.firstName + ' (' + model.teamName + ')';\r\n\t\t}\r\n\r\n\t\tfunction userSelected($item) {\r\n\t\t\tvm.userId = $item.userID;\r\n\t\t\tvm.teamId = $item.teamID;\r\n\t\t\tvm.assignee = _.pick($item, 'userID', 'firstName', 'lastName');\r\n\t\t\tvm.team = {\r\n\t\t\t\tteamID: $item.teamID,\r\n\t\t\t\tname: $item.teamName\r\n\t\t\t}\r\n\r\n\t\t\t$timeout(vm.closeFn);\r\n\t\t}\r\n\r\n\t\tfunction filterUserTeam(val) {\r\n\t\t\treturn _.filter(vm.users, function (user) {\r\n\t\t\t\treturn _.includes(user.lastName.toLowerCase() + ', ' + user.firstName.toLowerCase() + ' (' + user.teamName.toLowerCase() + ')', val.toLowerCase());\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\tfunction orderFn(user) {\r\n\t\t\treturn user.lastName + user.firstName + user.teamName;\r\n\t\t}\r\n\r\n\t\tfunction changed() {\r\n\t\t\tif (!vm.selectedUser) {\r\n\t\t\t\tvm.userId = null;\r\n\t\t\t\tvm.teamId = null;\r\n\t\t\t\tvm.assignee = {};\r\n\t\t\t\tvm.team = {};\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction clearData() {\r\n\t\t\tvm.selectedUser = null;\r\n\t\t\tvm.userId = null;\r\n\t\t\tvm.teamId = null;\r\n\t\t\tvm.assignee = {};\r\n\t\t\tvm.team = {};\r\n\t\t}\r\n\r\n\t\tfunction revertLabel() {\r\n\t\t\tvm.selectedUser = _.find(vm.users, { userID: vm.userId, teamID: vm.teamId }) || {};\r\n\t\t}\r\n\t}\r\n\r\n})();\r\n","'use strict';\r\n\r\n/**\r\n * @ngdoc directive\r\n * @name weissman.directive:disableAnimation\r\n * @description\r\n * # disableAnimation\r\n */\r\nangular.module('weissmanApp')\r\n .directive('disableAnimation', function($animate) {\r\n return {\r\n restrict: 'A',\r\n link: function($scope, $element, $attrs) {\r\n $attrs.$observe('disableAnimation', function(value) {\r\n $animate.enabled(!value, $element);\r\n });\r\n }\r\n };\r\n });\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:sdTrace\r\n * @description\r\n * # Trace Directive\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n 'use strict';\r\n\r\n angular\r\n .module('weissmanApp')\r\n .directive('sdEnter', Directive);\r\n\r\n Directive.$inject = [];\r\n\r\n function Directive() {\r\n\r\n return {\r\n link: function (scope, element, attrs) {\r\n \r\n element.bind(\"keydown keypress\", function (event) {\r\n if (event.which === 13) {\r\n scope.$apply(function () {\r\n scope.$eval(attrs.sdEnter);\r\n });\r\n\r\n event.preventDefault();\r\n }\r\n });\r\n }\r\n };\r\n \r\n }\r\n})();","(function () {\r\n\r\n\t// http://stackoverflow.com/questions/14995884/select-text-on-input-focus\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdSelectOnFocus', sdSelectOnFocus);\r\n\r\n\tsdSelectOnFocus.$inject = ['$window'];\r\n\r\n\tfunction sdSelectOnFocus($window) {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'A'\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {\r\n\t\t\telement.on('click', function () {\r\n\t\t\t\tif (!$window.getSelection().toString()) {\r\n\t\t\t\t\t// Required for mobile Safari\r\n\t\t\t\t\tthis.setSelectionRange(0, this.value.length)\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n})();\r\n","'use strict';\r\n\r\n/**\r\n * @ngdoc directive\r\n * @name weissman.directive:percent\r\n * @description\r\n * # percent\r\n */\r\nangular.module('weissmanApp')\r\n .directive('percent', ['$filter', function($filter) {\r\n return {\r\n require: 'ngModel',\r\n link: function(elem, $scope, attrs, ngModel) {\r\n var decimals = attrs.decimals === undefined ? 3 : attrs.decimals;\r\n ngModel.$parsers.unshift(\r\n function(viewValue) {\r\n console.log(viewValue)\r\n return $filter('number')(parseFloat(viewValue) / 100, decimals + 2);\r\n }\r\n );\r\n ngModel.$formatters.unshift(\r\n function(modelValue) {\r\n console.log(modelValue)\r\n return $filter('number')(parseFloat(modelValue) * 100, decimals);\r\n }\r\n );\r\n }\r\n }\r\n }]);\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:Component.Permission.Directive\r\n * @description\r\n * # check if the logged in user has permission to access the applied element.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sdDisableLink';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive(APP_SOURCE, function() {\r\n\t\t\treturn {\r\n\t\t\t\tcompile: function(tElement, tAttrs, transclude) {\r\n\t\t\t\t\t//Disable ngClick\r\n\t\t\t\t\ttAttrs[\"ngClick\"] = \"!(\"+tAttrs[APP_SOURCE]+\") && (\"+tAttrs[\"ngClick\"]+\")\";\r\n\r\n\t\t\t\t\t//Toggle \"disabled\" to class when APP_SOURCE becomes true\r\n\t\t\t\t\treturn function (scope, iElement, iAttrs) {\r\n\t\t\t\t\t\tscope.$watch(iAttrs[APP_SOURCE], function(newValue) {\r\n\t\t\t\t\t\t\tif (newValue !== undefined) {\r\n\t\t\t\t\t\t\t\tiElement.toggleClass(\"disabled\", newValue);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t});\r\n\r\n\t\t\t\t\t\t//Disable href on click\r\n\t\t\t\t\t\tiElement.on(\"click\", function(e) {\r\n\t\t\t\t\t\t\tif (scope.$eval(iAttrs[APP_SOURCE])) {\r\n\t\t\t\t\t\t\t\te.preventDefault();\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t});\r\n\t\t\t\t\t};\r\n\t\t\t\t}\r\n\t\t\t};\r\n\t\t}\r\n\t)\r\n})();\r\n","'use strict';\r\n\r\n/**\r\n * @ngdoc directive\r\n * @name weissman.directive:loadingSpinner\r\n * @description\r\n * # loadingSpinner\r\n */\r\nangular.module('weissmanApp')\r\n .directive('loadingSpinner', function() {\r\n return {\r\n scope: {\r\n waitingFor: '='\r\n },\r\n template: '
',\r\n restrict: 'A',\r\n transclude: true\r\n };\r\n });\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.directive:\r\n * @description\r\n * # Loading Spinner\r\n * Directive of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar VIEW_TEMPLATE_URL = 'app/UI-Lib/Loading-Spinner/_loadingSpinner.html';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdLoadingSpinner', Directive);\r\n\r\n\tDirective.$inject = [];\r\n\r\n\tfunction Directive() {\r\n\t\tvar directive = {\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tsize: '@',\r\n\t\t\t\tmarginTop: '@',\r\n\t\t\t\tmarginBottom: '@'\r\n\t\t\t},\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\tlink: linkFn\r\n\t\t};\r\n\r\n\t\tfunction linkFn(scope) {\r\n\t\t\tscope.size = Number(scope.size) || 5;\r\n\t\t\tscope.marginTop = Number(scope.marginTop) || 50;\r\n\t\t\tscope.marginBottom = Number(scope.marginBottom) || 1;\r\n\r\n\t\t\t//hack to simulate regular for loop in ngFor block\r\n\t\t\tscope.cubeCount = Array(8).fill(0);\r\n\t\t}\r\n\r\n\t\treturn directive;\r\n\t}\r\n})();\r\n","(function () {\r\n 'use strict';\r\n\r\n angular.module('weissmanApp')\r\n .controller('MessageBoxController', messageBoxController);\r\n\r\n messageBoxController.$inject = ['$uibModalInstance', 'MessageBoxButtons', 'MessageBoxResult', 'options', '$document', '$timeout'];\r\n\r\n function messageBoxController () { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit($uibModalInstance, MessageBoxButtons, MessageBoxResult, options, $document, $timeout) {\r\n var vm = this;\r\n\r\n activate();\r\n\r\n function activate() {\r\n vm.title = options.title;\r\n vm.message = options.message;\r\n vm.hasOK = false;\r\n vm.hasYes = false;\r\n vm.hasNo = false;\r\n vm.hasCancel = false;\r\n vm.hasContinue = false;\r\n\r\n switch (options.buttons || MessageBoxButtons.OKCancel) {\r\n case MessageBoxButtons.YesNoCancel:\r\n vm.hasCancel = true;\r\n vm.hasYes = true;\r\n vm.hasNo = true;\r\n break;\r\n case MessageBoxButtons.YesNo:\r\n vm.hasYes = true;\r\n vm.hasNo = true;\r\n break;\r\n case MessageBoxButtons.OKCancel:\r\n vm.hasCancel = true;\r\n vm.hasOK = true;\r\n\r\n if (options.focusButton === MessageBoxResult.Cancel){\r\n $timeout(function(){\r\n $document.find('button:contains(\"Cancel\")').focus();\r\n });\r\n }\r\n\r\n break;\r\n case MessageBoxButtons.OK:\r\n vm.hasOK = true;\r\n break;\r\n case MessageBoxButtons.Continue:\r\n vm.hasContinue = true;\r\n break;\r\n default:\r\n throw new Error('Unrecognized button constant: ' + buttons);\r\n }\r\n }\r\n\r\n vm.ok = function () {\r\n $uibModalInstance.close(MessageBoxResult.OK);\r\n };\r\n\r\n vm.yes = function () {\r\n $uibModalInstance.close(MessageBoxResult.Yes);\r\n };\r\n\r\n vm.no = function () {\r\n $uibModalInstance.close(MessageBoxResult.No);\r\n };\r\n\r\n vm.cancel = function () {\r\n $uibModalInstance.close(MessageBoxResult.Cancel);\r\n };\r\n }\r\n}());\r\n","// This service provides two functions; open and confirm. See the comment blocks\r\n// over each function for instructions.\r\n\r\n(function () {\r\n 'use strict';\r\n\r\n angular.module('weissmanApp')\r\n .factory('messageBoxService', Service);\r\n\r\n Service.$inject = ['$q', '$uibModal', 'MessageBoxButtons', 'MessageBoxResult'];\r\n\r\n function Service($q, $uibModal, MessageBoxButtons, MessageBoxResult) {\r\n return {\r\n open: open,\r\n confirm: confirm,\r\n confirmYesNo: confirmYesNo,\r\n warning: warning\r\n };\r\n\r\n /* open accepts an options argument, which is an object with the following\r\n properties:\r\n\r\n title: An optional property which specifies what to display in the modal title\r\n message: The message to be displayed to the user\r\n buttons: A number specifying what buttons to display on the dialog\r\n\r\n For the buttons property, if you're in JavaScript you can inject the\r\n MessageBoxButtons property from the globals file for options. If you're in\r\n TypeScript, the MessageBoxButtons enumeration has the options.\r\n\r\n The open function returns a promise which resolves a number indicating which\r\n button was pressed. Similar to the buttons property, you can inject\r\n MessageBoxResult in JavaScript or use the MessageBoxResult enumeration in\r\n TypeScript to see what might result. If the modal is closed without the user\r\n pressing a button, a Cancel result is resolved. That means the promise will not\r\n be rejected; it always resolves with a button result. It also means that you\r\n should think about the cancel result even if you don't display a cancel button.\r\n To use:\r\n\r\n messageBoxService.open({\r\n title: 'Save changes?',\r\n message: 'Do you wish to save before leaving this page?',\r\n buttons: MessageBoxButtons.YesNo\r\n }).then(function (result) {\r\n switch (result) {\r\n case MessageBoxResult.Yes:\r\n // Do something when yes is clicked\r\n break;\r\n case MessageBoxResult.No:\r\n // Do something when no is clicked\r\n break;\r\n case MessageBoxResult.Cancel:\r\n // Do something when the dialog is closed\r\n break;\r\n }\r\n }); */\r\n function open(options, isBackdropStatic) {\r\n return $q(function (resolve) {\r\n var messageBoxModal = $uibModal.rejectableOpen({\r\n templateUrl: 'app/UI-Lib/Message-Box/messageBoxModal.html',\r\n controller: 'MessageBoxController',\r\n controllerAs: 'vm',\r\n// size: 'sm',\r\n animation: false,\r\n windowClass: 'modal-on-top show',\r\n backdropClass: 'show',\r\n openedClass: 'modal-open-nested',\r\n backdrop: isBackdropStatic ? 'static' : true,\r\n resolve: {\r\n options: options\r\n }\r\n });\r\n\r\n messageBoxModal.result.then(function (result) {\r\n resolve(result);\r\n }, function () {\r\n // If the modal is closed via escape or click outside the modal,\r\n // resolve as if the cancel button was pressed\r\n resolve(MessageBoxResult.Cancel);\r\n });\r\n });\r\n }\r\n\r\n /* confirm takes two arguments; first the message to display to the user in the\r\n modal, and second a title for the modal (optional). The function returns a\r\n promise that is resolved if the user clicks OK. To use:\r\n\r\n messageBoxService.confirm(\"Are you sure you want to delete this?\", \"Confirm Delete\").then(function() {\r\n // Some code here that actually takes action (such as deleting)\r\n });\r\n\r\n If you need to take action when a user clicks on Cancel, you should use the more\r\n general open function. Note that confirm used to reject the promise when users\r\n clicked on cancel, but the AngularJS upgrade altered promise behavior, making that\r\n a less convenient option. */\r\n function confirm(message, title, focusButton) {\r\n return $q(function (resolve, reject) {\r\n open({\r\n message: message,\r\n title: title,\r\n buttons: MessageBoxButtons.OKCancel,\r\n focusButton: focusButton,\r\n windowClass: 'message-box-z-index show',\r\n backdropClass: 'show'\r\n }).then(function (result) {\r\n if (result !== MessageBoxResult.Cancel) {\r\n resolve();\r\n }\r\n });\r\n });\r\n }\r\n\r\n // This works exactly the same way as confirm but uses Yes/No buttons instead of OK/Cancel;\r\n // dismissing the dialog is the same as clicking \"No\" in this case\r\n function confirmYesNo(message, title) {\r\n return $q(function (resolve, reject) {\r\n open({\r\n message: message,\r\n title: title,\r\n buttons: MessageBoxButtons.YesNo\r\n }).then(function (result) {\r\n if (!(result === MessageBoxResult.No || result === MessageBoxResult.Cancel)) {\r\n resolve();\r\n }\r\n })\r\n })\r\n }\r\n\r\n // For a warning message the user needs to confirm seeing before moving on\r\n function warning(message, title) {\r\n return $q(function (resolve) {\r\n var messageBoxModal = $uibModal.rejectableOpen({\r\n templateUrl: 'app/UI-Lib/Message-Box/messageBoxWarning.html',\r\n controller: 'MessageBoxController',\r\n controllerAs: 'vm',\r\n// size: 'sm',\r\n animation: false,\r\n windowClass: 'nested-modal show',\r\n backdropClass: 'show',\r\n openedClass: 'modal-open-nested',\r\n backdrop: true,\r\n resolve: {\r\n options: {\r\n message: message,\r\n title: title,\r\n buttons: MessageBoxButtons.OK\r\n }\r\n }\r\n });\r\n\r\n messageBoxModal.result.then(function (result) {\r\n resolve(result);\r\n }, function () {\r\n // If the modal is closed via escape or click outside the modal,\r\n // resolve as if the cancel button was pressed\r\n resolve(MessageBoxResult.Cancel);\r\n });\r\n });\r\n }\r\n }\r\n}());\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissmanApp.Name.Prefix.Service\r\n * @description\r\n * # Name.Prefix Service\r\n * Factory in the weissmanApp.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.Name.Prefix.Service';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = [];\r\n\r\n\tfunction Service() {\r\n\r\n\t\tvar prefixes = ['','Mr.','Ms.','Miss','Mrs.','Dr.'];\r\n\r\n\t\t//var prefixes = [{\r\n\t\t// id: 1,\r\n\t\t// value: null,\r\n\t\t// display: ''\r\n\t\t//}, {\r\n\t\t// id: 2,\r\n\t\t// value: 'Mr.',\r\n\t\t// display: 'Mr.'\r\n\t\t//}, {\r\n\t\t// id: 3,\r\n\t\t// value: 'Ms.',\r\n\t\t// display: 'Ms.'\r\n\t\t//}, {\r\n\t\t// id: 4,\r\n\t\t// value: 'Miss',\r\n\t\t// display: 'Miss'\r\n\t\t//}, {\r\n\t\t// id: 5,\r\n\t\t// value: 'Mrs.',\r\n\t\t// display: 'Mrs.'\r\n\t\t//}];\r\n\r\n\t\t// Public API.\r\n\t\tvar service = {\r\n\t\t\tgetAll: getPrefixes\r\n\t\t};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction getPrefixes() {\r\n\t\t\treturn prefixes;\r\n\t\t}\r\n\t}\r\n})();\r\n","(function () {\r\n\tif (!String.prototype.format) {\r\n\t\tString.prototype.format = function () {\r\n\t\t\tvar args = arguments;\r\n\t\t\treturn this.replace(/{(\\d+)}/g, function (match, number) {\r\n\t\t\t\treturn typeof args[number] != 'undefined' ? encodeURIComponent(args[number]) : match;\r\n\t\t\t});\r\n\t\t};\r\n\t}\r\n})();\r\n","'use strict';\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissman.utils\r\n * @description\r\n * # utils\r\n * Factory in the weissman.\r\n */\r\n\r\nangular.module('weissmanApp')\r\n\t.factory('utils', ['sdLogger', '$timeout', '$location', function (sdLogger, $timeout, $location) {\r\n\t\tvar nonDeleted = function (list) {\r\n\t\t\treturn _.reject(list, {\r\n\t\t\t\tefAction: 'delete'\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\tvar notNullorZero = function (val) {\r\n\t\t\tif (val === null) {\r\n\t\t\t\treturn false\r\n\t\t\t}\r\n\t\t\tif (val === 0) {\r\n\t\t\t\treturn false\r\n\t\t\t}\r\n\r\n\t\t\treturn true\r\n\t\t}\r\n\r\n\t\tvar getObjValByString = function (o, s) {\r\n\t\t\ts = s.replace(/\\[(\\w+)\\]/g, '.$1'); // convert indexes to properties\r\n\t\t\ts = s.replace(/^\\./, ''); // strip a leading dot\r\n\t\t\tvar a = s.split('.');\r\n\t\t\tfor (var i = 0, n = a.length; i < n; ++i) {\r\n\t\t\t\tvar k = a[i];\r\n\t\t\t\tif (k in o) {\r\n\t\t\t\t\to = o[k];\r\n\t\t\t\t} else {\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn o;\r\n\t\t}\r\n\r\n\t\t// Public API here\r\n\t\tvar service = {\r\n\t\t\tgetEntityName: getEntityName,\r\n\t\t\tgetCurrentEntity: getCurrentEntity,\r\n\t\t\tfocusOnElement: focusOnElement,\r\n\t\t\tnonDeleted: nonDeleted,\r\n\t\t\tnotNullorZero: notNullorZero,\r\n\t\t\tgetObjValByString: getObjValByString,\r\n\t\t\tgetEntityTypeAndId: getEntityTypeAndId,\r\n\t\t\tfindPropertyName: findPropertyName,\r\n\t\t\tremoveArrayItem: removeArrayItem,\r\n\t\t\tcompareBySequence: compareBySequence,\r\n\t\t\tshowJsonUsingPopup: showJsonUsingPopup,\r\n\t\t\tunDefaultOthers: function (list, newDefault) {\r\n\t\t\t\tvar tempVal = newDefault.isDefault;\r\n\r\n\t\t\t\tlist = _.map(nonDeleted(list), function (item) {\r\n\t\t\t\t\titem.isDefault = false;\r\n\t\t\t\t\treturn item;\r\n\t\t\t\t})\r\n\r\n\t\t\t\tnewDefault.isDefault = tempVal;\r\n\t\t\t}, // Falsify all others in list, but keep checked value (true or false) of checkbox checked\r\n\t\t\tupdateAction: function (thing) {\r\n\t\t\t\tthing.efAction = thing.efAction === null ? 'update' : thing.efAction;\r\n\t\t\t},\r\n\t\t\tlogIt: function () {\r\n\t\t\t\tvar args = [];\r\n\t\t\t\tfor (var i = 0; i < arguments.length; i++) {\r\n\t\t\t\t\targs[i] = arguments[i];\r\n\t\t\t\t}\r\n\t\t\t},\r\n\t\t\tnonDeletedFilter: nonDeletedFilter,\r\n\t\t\tconvertStringToDate: convertStringToDate,\r\n convertDateStringsToDates: convertDateStringsToDates\r\n\t\t};\r\n\r\n\t\tservice.vm = {};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction focusOnElement(elem, delay) {\r\n\t\t\tdelay = delay || 100;\r\n\r\n\t\t\t$timeout(function () {\r\n\t\t\t\tvar element = angular.element(elem)\r\n\t\t\t\telement.focus();\r\n\r\n\t\t\t\tsdLogger.log('.focusOnElement(): ', {\r\n\t\t\t\t\t'element': element\r\n\t\t\t\t});\r\n\t\t\t}, delay)\r\n\t\t}\r\n\r\n\t\tfunction notEmpty(s) {\r\n\t\t\tif (!s)\r\n\t\t\t\treturn false;\r\n\t\t\tif (s == '')\r\n\t\t\t\treturn false;\r\n\t\t\treturn true;\r\n\t\t}\r\n\r\n\t\tfunction getEntityTypeAndId(stateParams) {\r\n\t\t\t//console.log('getEntityTypeAndId - $stateParams', stateParams);\r\n\r\n\t\t\t// EntityTypeId\tEntityTypeName\r\n\t\t\t// 1\t\t\tCompany\r\n\t\t\t// 2\t\t\tState\r\n\t\t\t// 3\t\t\tAssessor\r\n\t\t\t// 4\t\t\tCollector\r\n\r\n\r\n\t\t\tif (stateParams.parcelId !== undefined) { //parcel}`\r\n\t\t\t\treturn {\r\n\t\t\t\t\ttype: 'parcel',\r\n\t\t\t\t\ttypeId: -1,\r\n\t\t\t\t\tid: stateParams.parcelId\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif (stateParams.siteId !== undefined) {\r\n\t\t\t\treturn {\r\n\t\t\t\t\ttype: 'site',\r\n\t\t\t\t\ttypeId: -1,\r\n\t\t\t\t\tid: stateParams.siteId\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif (stateParams.companyId !== undefined) {\r\n\t\t\t\treturn {\r\n\t\t\t\t\ttype: 'company',\r\n\t\t\t\t\ttypeId: 1,\r\n\t\t\t\t\tid: stateParams.companyId\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif (notEmpty(stateParams.collectorId)) {\r\n\t\t\t\treturn {\r\n\t\t\t\t\ttype: 'collector',\r\n\t\t\t\t\ttypeId: 4,\r\n\t\t\t\t\tid: stateParams.collectorId\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif (notEmpty(stateParams.assessorId)) {\r\n\t\t\t\treturn {\r\n\t\t\t\t\ttype: 'assessor',\r\n\t\t\t\t\ttypeId: 3,\r\n\t\t\t\t\tid: stateParams.assessorId\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tif (stateParams.stateId !== undefined) {\r\n\t\t\t\treturn {\r\n\t\t\t\t\ttype: 'state',\r\n\t\t\t\t\ttypeId: 2,\r\n\t\t\t\t\tid: stateParams.stateId\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\treturn {\r\n\t\t\t\ttype: 'unknown',\r\n\t\t\t\tid: -1\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction getEntityName(id) //entityInfo\r\n\t\t{\r\n\t\t\tif (service.vm.currentEntity && service.vm.currentEntity.id === id) {\r\n\t\t\t\treturn service.vm.currentEntity.name;\r\n\t\t\t}\r\n\r\n\t\t\treturn '';\r\n\t\t}\r\n\r\n\t\tfunction getCurrentEntity(id) {\r\n\t\t\tif (service.vm.currentEntity && service.vm.currentEntity.id === id) {\r\n\t\t\t\treturn service.vm.currentEntity;\r\n\t\t\t}\r\n\r\n\t\t\treturn null;\r\n\t\t}\r\n\r\n\t\tfunction nonDeletedFilter(item) {\r\n\t\t\treturn item.efAction !== 'delete';\r\n\t\t}\r\n\r\n\t\tfunction findPropertyName(object, property_value, strict) {\r\n\t\t\tvar result = 'unknown property name';\r\n\r\n\t\t\tif (typeof strict === 'undefined') {\r\n\t\t\t\tstrict = false;\r\n\t\t\t}\r\n\r\n\t\t\tObject.getOwnPropertyNames(object).forEach(function (propertyName, idx, array) {\r\n\t\t\t\tif ((strict && object[propertyName] === property_value) ||\r\n\t\t\t\t\t(!strict && object[propertyName] === property_value)) {\r\n\t\t\t\t\tresult = propertyName;\r\n\t\t\t\t}\r\n\t\t\t});\r\n\r\n\t\t\treturn result.toLowerCase();\r\n\t\t}\r\n\r\n\t\tfunction compareBySequence(a, b) {\r\n\t\t\tif (a.sequence < b.sequence)\r\n\t\t\t\treturn -1;\r\n\t\t\telse if (a.sequence > b.sequence)\r\n\t\t\t\treturn 1;\r\n\t\t\telse\r\n\t\t\t\treturn 0;\r\n\t\t}\r\n\r\n\t\tfunction removeArrayItem(arr, item) {\r\n\t\t\tvar i = arr.indexOf(item)\r\n\t\t\tif (i < 0)\r\n\t\t\t\treturn false;\r\n\t\t\tarr.splice(i, 1);\r\n\t\t\treturn true;\r\n\t\t}\r\n\r\n\t\tfunction convertStringToDate(value) {\r\n var match = dateStringMatch(value);\r\n\r\n if (match) {\r\n var newValue = getDateValue(match);\r\n if (newValue) {\r\n return newValue;\r\n }\r\n }\r\n\r\n return value;\r\n\t\t}\r\n\r\n\t\tfunction convertDateStringsToDates(input) {\r\n // Ignore things that aren't objects.\r\n if (typeof input !== \"object\") return input;\r\n\r\n for (var key in input) {\r\n if (!input.hasOwnProperty(key)) { continue; }\r\n var value = input[key];\r\n var match = dateStringMatch(value);\r\n if (match) {\r\n var newValue = getDateValue(match);\r\n if (newValue) {\r\n input[key] = newValue;\r\n }\r\n } else if (typeof value === 'object') {\r\n // Recurse into object\r\n convertDateStringsToDates(value);\r\n }\r\n }\r\n }\r\n\r\n function dateStringMatch(value) {\r\n var regexIso = /^\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d(?:(?::[0-5]\\d)?|(?::[0-5]\\d\\.\\d+))?(Z|(?:[+-][0-2]\\d:[0-5]\\d))?$/;\r\n\r\n // Check for string properties which look like dates.\r\n if (typeof value === 'string') {\r\n var match = value.match(regexIso);\r\n if (match && !isJson(value)) {\r\n return match;\r\n }\r\n }\r\n\r\n return undefined;\r\n }\r\n\r\n\t\tfunction getDateValue(match) {\r\n // The first capture group is the timezone specifier; if not present, assume UTC\r\n var momentVal = match[1] ? moment(match[0]) : moment.utc(match[0]);\r\n if (momentVal.isValid()) {\r\n return momentVal.toDate();\r\n }\r\n\r\n return undefined;\r\n\t\t}\r\n\r\n\t\tfunction isJson(str) {\r\n\t\t\ttry {\r\n\t\t\t\tJSON.parse(str);\r\n\t\t\t} catch (e) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\treturn true;\r\n\t\t}\r\n\r\n\t\tfunction showJsonUsingPopup(data) {\r\n\t\t\tvar url = 'data:text/json;charset=utf8,' + encodeURIComponent(data);\r\n\t\t\twindow.open(url, '_blank');\r\n\t\t\twindow.focus();\r\n\t\t}\r\n\t}]);\r\n","(function () {\r\n 'use strict';\r\n\r\n // Make sure it's been at least 60 seconds since the last time we tried to do a stale refresh\r\n const refreshRetryDelay = 60000;\r\n\r\n angular.module('weissmanApp').factory('BuildTimestampService', Service);\r\n\r\n Service.$inject = ['$q', 'sd.Http.Service'];\r\n\r\n function Service($q, http) {\r\n var resolve;\r\n var reject;\r\n\r\n var timestampCheck = $q(function (res, rej) {\r\n resolve = res;\r\n reject = rej;\r\n });\r\n\r\n return {\r\n getTimestampCheckPromise: getTimestampCheckPromise,\r\n startCheck: startCheck\r\n };\r\n\r\n function getTimestampCheckPromise() {\r\n return timestampCheck;\r\n }\r\n\r\n function startCheck() {\r\n timestampCheck = http.get('/app/build-timestamp.txt').then(function (ts) {\r\n var runtimeTimestamp = parseInt(ts, 10);\r\n if (window.weissmanEnvironmentConfig.developerMode) {\r\n console.log('Developer mode; skipping UI build time check');\r\n }\r\n else if (runtimeTimestamp !== window.weissmanBuildTimestamp) {\r\n // Looks like the UI is stale. Try to figure out the last time the page was refreshed\r\n var lastRefresh = sessionStorage['StateUIRefreshTime'];\r\n if (!lastRefresh || (new Date()).getTime() - parseInt(lastRefresh, 10) > refreshRetryDelay) {\r\n console.log('Stale build detected; attempting refresh. Build time: ' + new Date(window.weissmanBuildTimestamp) +\r\n '; runtime-detected build time: ' + new Date(runtimeTimestamp));\r\n reject(\"Refreshing\");\r\n window.location.reload(true);\r\n sessionStorage['StateUIRefreshTime'] = (new Date()).getTime();\r\n }\r\n else {\r\n // We failed at failing\r\n console.error('Build timestamp mismatch, and it appears a reload has already been tried. Build timestamp: ' +\r\n window.weissmanBuildTimestamp + '; runtime value: ' + runtimeTimestamp);\r\n }\r\n }\r\n else {\r\n delete sessionStorage['StateUIRefreshTime'];\r\n console.log('Verified UI build up to date (build time: ' + new Date(weissmanBuildTimestamp) + ')');\r\n }\r\n resolve();\r\n }).catch(function (error) {\r\n reject(error);\r\n });\r\n\r\n http.initializeTimestampCheck(timestampCheck);\r\n }\r\n }\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc directive\r\n * @name weissman.directive:PanelChevron\r\n * @description\r\n * # Activity\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sdPanelChevron';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive(APP_SOURCE, Directive);\r\n\r\n\tDirective.$inject = [];\r\n\r\n\tfunction Directive() {\r\n\t\tvar directive = {\r\n\t\t\trestrict: 'E',\r\n\t\t\ttemplateUrl: 'app/UI-Lib/Weissman-Panel/panelChevron.html',\r\n\t\t\tscope: {\r\n\t\t\t\tshowBody: '='\r\n\t\t\t},\r\n\t\t\tlink: link,\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element) {}\r\n\t};\r\n})();\r\n\r\n\r\n\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:User.Groups.Modal.Controller\r\n * @description\r\n * # User Groups Modal Popup\r\n * Controller of the weissmanApp\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.User.Group.Modal.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller(APP_SOURCE, Controller);\r\n\r\n\tController.$inject = [\r\n\t\t'$uibModalInstance',\r\n\t\t'sd.User.Group.Service',\r\n\t\t'sd.Application.Permission.Service',\r\n\t\t'user_group',\r\n\t\t'edit_mode',\r\n\t\t'read_only',\r\n\t\t'Roles',\r\n\t\t'toastr',\r\n\t\t'sd.Account.User.Service',\r\n\t\t'$scope',\r\n\t\t'sdModalService',\r\n\t\t'instancePermissionService',\r\n\t\t'InstanceRights',\r\n\t\t'userInstanceService',\r\n\t];\r\n\r\n\tfunction Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n\tfunction ng1ControllerInit($uibModalInstance, userGroupService, applicationPermissionsService, user_group, edit_mode, read_only, Roles, toastr, user, $scope, sdModalService,instanceRightsService,InstanceRights,userInstanceService) {\r\n\r\n\t\t/* jshint validthis:true */\r\n\t\tvar vm = this;\r\n\t\tvar firstPass = false;\r\n\r\n\t\tvm.SaveButtonText = 'Save';\r\n\t\tvm.Title = 'User Group';\r\n\t\tvm.CompanyPermissions = [];\r\n\t\tvm.ApplicationPermissions = [];\r\n\t\tvm.availableInstanceRights = [];\r\n\t\tvm.permissionsLookup = [];\r\n\t\tvm.editMode = edit_mode;\r\n\t\tvm.readOnly = read_only;\r\n\t\tvm.saving = false;\r\n\t\tvm.hasEditPermission = user.hasInstanceRight(InstanceRights.MANAGEUSERSETUP);\r\n\t\tvm.appPermissionsChanged = false;\r\n\r\n\t\tvm.siteOptions = ['View All Sites', 'View Some Sites', 'Edit All Sites', 'Hide All Sites'];\r\n\r\n\t\tvm.save = save;\r\n\t\tvm.cancel = cancel;\r\n\t\tvm.deleteUserGroup = deleteUserGroup;\r\n\t\tvm.editUserGroup = editUserGroup;\r\n\t\tvm.getCancelButtonText = getCancelButtonText;\r\n\t\tvm.instanceId = userInstanceService.getSelectedInstance().instanceId;\r\n\r\n\t\tactivate();\r\n\r\n\t\t$scope.$watch('vm.ApplicationPermissions', function (newVal, oldVal) {\r\n\t\t\tif (!oldVal.length && !newVal.length) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tif (!oldVal.length && !firstPass) {\r\n\t\t\t\tfirstPass = true;\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tvm.appPermissionsChanged = true;\r\n\t\t}, true)\r\n\r\n\t\tfunction activate() {\r\n\t\t\tif (user_group) {\r\n\t\t\t\t\r\n\t\t\t\tvm.user_group = angular.copy(user_group);\r\n\t\t\t\tvm.instanceId = vm.user_group.instanceId;\r\n\r\n\t\t\t\tvm.CompanyPermissions = [];\r\n\r\n\t\t\t\tapplicationPermissionsService.getByGroupId(user_group.groupID)\r\n\t\t\t\t\t.then(function (results) {\r\n\t\t\t\t\t\tvm.ApplicationPermissions = results;\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t//get assigned instance permissions\r\n\t\t\t\tinstanceRightsService.getByGroupId(user_group.groupID)\r\n\t\t\t\t.then( function(r) {\r\n\t\t\t\t\tvm.instancePermissions = r;\r\n\t\t\t\t});\t\t\t\r\n\r\n //get available instance rights\r\n instanceRightsService.getAllByGroup(user_group.groupID)\r\n .then( function(r) {\r\n vm.availableInstanceRights = r;\r\n\t\t\t\t\t\tvm.permissionsLookup = _.cloneDeep(r);\t\t\t\t\t\t\r\n });\t\t\t\t\t\r\n\t\t\t} else {\r\n\t\t\t\tvm.user_group = {\r\n\t\t\t\t\tgroupID: 0\r\n\t\t\t\t};\r\n\t\t\t\tvm.instancePermissions =[];\r\n\t\t\t\tinstanceRightsService.getAllByContactId(userInstanceService.getInstanceContactId()).then(\r\n\t\t\t\t\tfunction(r) {\r\n\t\t\t\t\t\tvm.availableInstanceRights = r;\r\n\t\t\t\t\t\tvm.permissionsLookup = _.cloneDeep(r);\r\n\t\t\t\t\t}\r\n\t\t\t\t)\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction save() {\r\n\t\t\tvar userGroupToSave = prepareObject();\r\n\t\t\tvm.saving = true;\r\n\r\n\t\t\tupdateOrCreate(userGroupToSave).catch(function (error) {\r\n\t\t\t\tvm.saving = false;\r\n\r\n\t\t\t\ttoastr.error('Error Deleting Group From DB');\r\n\t\t\t\tconsole.warn(error);\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\tfunction updateOrCreate(userGroupToSave) {\r\n\t\t\tvar batch = true; //force this to be true: previously if one collection was empty then no changes would be saved except the group name and description\r\n\r\n\t\t\tvar userGroupObj = {\r\n\t\t\t\tdeleted: false\r\n\t\t\t}\r\n\r\n\t\t\tif (userGroupToSave.groupID) {\r\n\t\t\t\treturn userGroupService.update(userGroupToSave, batch)\r\n\t\t\t\t\t.then(function () {\r\n\t\t\t\t\t\tuserGroupObj.userGroup = vm.user_group;\r\n\r\n\t\t\t\t\t\t$uibModalInstance.close(userGroupObj);\r\n\t\t\t\t\t});\r\n } else {\r\n userGroupToSave.instanceId = userInstanceService.getSelectedInstance().instanceId;\r\n\t\t\t\treturn userGroupService.create(userGroupToSave, batch)\r\n\t\t\t\t\t.then(function (newGroup) {\r\n\t\t\t\t\t\tuserGroupObj.userGroup = _.omit(newGroup, 'roles', 'permissionDtoList');\r\n\r\n\t\t\t\t\t\t$uibModalInstance.close(userGroupObj);\r\n\t\t\t\t\t})\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction prepareObject() {\r\n\t\t\tvar group = angular.copy(vm.user_group);\r\n\r\n\t\t\tgroup.roles = vm.ApplicationPermissions;\r\n\r\n\t\t\t//console.log('User.Group.Modal.Controller - saving', vm.CompanyPermissions);\r\n\r\n\t\t\tgroup.instancePermissions = vm.instancePermissions;\r\n\r\n\t\t\tgroup.permissionDtoList = _.filter(vm.CompanyPermissions, 'efAction');\r\n\r\n\t\t\treturn group;\r\n\t\t}\r\n\r\n\t\tfunction cancel() {\r\n\t\t\tif (vm.user_group.groupID) {\r\n\t\t\t\tsdModalService.cancel(isGroupDirty(), $uibModalInstance.dismiss)\r\n\t\t\t} else {\r\n\t\t\t\t$uibModalInstance.dismiss();\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction isGroupDirty() {\r\n\t\t\treturn vm.appPermissionsChanged || _.some(vm.CompanyPermissions, 'efAction')\r\n\t\t}\r\n\r\n\t\tfunction deleteUserGroup() {\r\n\t\t\tvar warningMessage = 'Confirm Deleting User Group.';\r\n\r\n\t\t\tif (user_group.memberCount) {\r\n\t\t\t\twarningMessage += ' ' + user_group.memberCount + ' users will be removed.';\r\n\t\t\t}\r\n\t\t\tif (confirm(warningMessage)) {\r\n\t\t\t\tvm.editMode = false;\r\n\r\n\t\t\t\tuserGroupService.deleteById(user_group.groupID)\r\n\t\t\t\t\t.then(function () {\r\n\t\t\t\t\t\tvar userGroupObj = {\r\n\t\t\t\t\t\t\tdeleted: true,\r\n\t\t\t\t\t\t\tuserGroup: user_group\r\n\t\t\t\t\t\t};\r\n\r\n\t\t\t\t\t\t$uibModalInstance.close(userGroupObj);\r\n\t\t\t\t\t})\r\n\t\t\t\t\t.catch(function (error) {\r\n\t\t\t\t\t\tvm.editMode = true;\r\n\r\n\t\t\t\t\t\ttoastr.error('Error Deleting Group From DB');\r\n\t\t\t\t\t\tconsole.warn(error)\r\n\t\t\t\t\t})\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction editUserGroup() {\r\n\t\t\tvm.editMode = vm.hasEditPermission ? true : false;\r\n\t\t}\r\n\r\n\t\tfunction getCancelButtonText() {\r\n\t\t\treturn vm.editMode ? 'Cancel' : 'Close';\r\n\t\t}\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc service\r\n * @name weissmanApp.User.Group.Service\r\n * @description\r\n * # User.Group.Service\r\n * Factory in the weissmanApp.\r\n */\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tvar APP_SOURCE = 'sd.User.Group.Service';\r\n\tvar SERVICE_URL = '/api/usergroup/';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.factory(APP_SOURCE, Service);\r\n\r\n\tService.$inject = [\r\n\t\t'sd.Http.Service',\r\n 'sd.Account.User.Service',\r\n '$q'\r\n\t];\r\n\r\n\tfunction Service(sdHttp, userService, $q) {\r\n\t\t// Public API.\r\n\t\tvar service = {\r\n\t\t\tget: getAll,\r\n\t\t\tgetById: getById,\r\n\t\t\tgetForMember: getForMember,\r\n\t\t\tgetForSetup: getForSetup,\r\n\t\t\tgetList: getList,\r\n\t\t\tupdate: update,\r\n\t\t\tcreate: create,\r\n\t\t\tdeleteById: deleteById,\r\n isUserInGroup: isUserInGroup,\r\n isUserSuperUser: isUserSuperUser\r\n\t\t};\r\n\r\n\t\treturn service;\r\n\r\n\t\tfunction getAll(instanceId) {\r\n\t\t\treturn sdHttp.get(SERVICE_URL + 'instance/' + instanceId);\r\n\t\t}\r\n\r\n\t\tfunction getById(id) {\r\n\t\t\tvar url = SERVICE_URL + id;\r\n\t\t\tvar config = {};\r\n\r\n\t\t\treturn sdHttp.get(url, config);\r\n\t\t}\r\n\r\n\t\tfunction getForMember(userGuid) {\r\n\t\t\tvar url = SERVICE_URL + 'member';\r\n\t\t\tvar config = {\r\n\t\t\t\tparams: {\r\n\t\t\t\t\tuserid: userGuid\r\n\t\t\t\t}\r\n\t\t\t};\r\n\r\n\t\t\treturn sdHttp.get(url, config);\r\n\t\t}\r\n\r\n\t\tfunction getForSetup(contactId) {\r\n\r\n\t\t\treturn sdHttp.get(`${SERVICE_URL}setup/${contactId}`);\r\n\t\t}\r\n\r\n\t\tfunction getList(pageNumber, pageSize, searchTerm) {\r\n\t\t\tvar config = {\r\n\t\t\t\tparams: {\r\n\t\t\t\t\tpagenumber: pageNumber,\r\n\t\t\t\t\tpagesize: pageSize\r\n\t\t\t\t}\r\n\t\t\t};\r\n\r\n\t\t\tif (searchTerm) {\r\n\t\t\t\tconfig.params.searchtext = searchTerm;\r\n\t\t\t}\r\n\r\n\t\t\treturn sdHttp.get(SERVICE_URL, config);\r\n\t\t}\r\n\r\n\t\tfunction update(userGroup, batch) {\r\n\t\t\tvar url = SERVICE_URL + userGroup.groupID;\r\n\t\t\tvar config = {\r\n\t\t\t\tparams: {\r\n\t\t\t\t\tbatch: batch\r\n\t\t\t\t}\r\n\t\t\t};\r\n\r\n\t\t\treturn sdHttp.put(url, userGroup, config);\r\n\t\t}\r\n\r\n\t\tfunction create(userGroup, batch) {\r\n\t\t\tvar config = {\r\n\t\t\t\tparams: {\r\n\t\t\t\t\tbatch: batch\r\n\t\t\t\t}\r\n\t\t\t};\r\n\r\n\t\t\treturn sdHttp.post(SERVICE_URL, userGroup, config);\r\n\t\t}\r\n\r\n\t\tfunction deleteById(id) {\r\n\t\t\tvar url = SERVICE_URL + id;\r\n\r\n\t\t\treturn sdHttp.delete(url, {});\r\n\t\t}\r\n\r\n\t\tfunction isUserInGroup(groupName) {\r\n var user = userService.getUser();\r\n var deferred = $q.defer();\r\n\r\n getForMember(user.id).then(function(groups) {\r\n var isInGroup = user !== null && _.some(groups, { name: groupName });\r\n deferred.resolve(isInGroup);\r\n });\r\n\r\n return deferred.promise;\r\n }\r\n\r\n function isUserSuperUser() {\r\n\t\t return sdHttp.get('/api/Account/IsSuperUser');\r\n }\r\n\t}\r\n})();\r\n","// Copyright (c) Second Decimal, Inc. All rights reserved.\r\n\r\n/**\r\n * @ngdoc function\r\n * @name weissmanApp.controller:User.Setup.Controller\r\n * @description\r\n * # User Setup\r\n * Controller of the weissmanApp\r\n */\r\n\r\n\r\n(function () {\r\n 'use strict';\r\n\r\n var APP_SOURCE = 'sd.User.Setup.Controller';\r\n\r\n angular\r\n .module('weissmanApp')\r\n .controller(APP_SOURCE, Controller);\r\n\r\n Controller.$inject = [\r\n 'sdLogger',\r\n '$uibModal',\r\n 'sd.Contacts.Service',\r\n 'sd.User.Setup.Service',\r\n 'sd.Account.User.Service',\r\n 'toastr',\r\n 'messageBoxService',\r\n 'accountService',\r\n 'instancePermissionService',\r\n 'userInstanceService',\r\n 'SD.Restrict.Service',\r\n 'instanceRepository',\r\n 'MessageBoxButtons',\r\n 'MessageBoxResult',\r\n '$scope',\r\n 'featureFlagsService',\r\n 'CommentsModalService',\r\n '$q',\r\n 'productAnalyticsService'\r\n ];\r\n\r\n function Controller() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit(sdLogger, $uibModal, contactsService, userSetupService, accountUserService, toastr,\r\n messageBoxService, accountService, instancePermissionService,userInstanceService,\r\n restrictService, instanceRepository, MessageBoxButtons, MessageBoxResult, $scope,\r\n featureFlagsService, CommentsModalService, $q, productAnalyticsService) {\r\n\r\n var OPT_HIDE = 'Hide';\r\n var OPT_VIEW_ALL = 'View All Sites';\r\n var OPT_VIEW_EDIT_SOME = 'View/Edit Some Sites';\r\n var OPT_EDIT_ALL = 'Edit All Sites';\r\n\r\n /* jshint validthis:true */\r\n var vm = this;\r\n\r\n var userToRevertTo = {};\r\n\r\n var featureFlags = featureFlagsService.featureFlags;\r\n\r\n vm.instanceId = null;\r\n vm.editMode = false;\r\n vm.configuringSSO = false;\r\n vm.newSSODomain = null;\r\n vm.userId = null;\r\n vm.userToEdit = {};\r\n vm.canEdit = false;\r\n vm.canEditUserInfo = false;\r\n vm.canResetPassword = false;\r\n vm.availableInstanceRights = [];\r\n vm.permissionsLookup = [];\r\n vm.contactStatuses = [];\r\n vm.inSupportInstance = userInstanceService.isCurrentInstanceSystem();\r\n // Only show the Create Legacy User button if this is dev or staging/uat (staging and UAT both use 'S' as the environment character)\r\n vm.showCreateLegacyUser = featureFlags.enableIAM && (featureFlags.environment === 'D' || featureFlags.environment === 'S');\r\n vm.showLoginManager = featureFlags.enableLoginManager;\r\n vm.isLegacyUser = false;\r\n vm.isLicensedUser = false;\r\n vm.showActiveCheckbox = false;\r\n vm.iamMigrationStatus = 'Not Migrated';\r\n vm.isLoading = false;\r\n vm.needTaxDotComPermission = false;\r\n\r\n vm.options = [OPT_HIDE, OPT_VIEW_ALL, OPT_VIEW_EDIT_SOME, OPT_EDIT_ALL];\r\n\r\n vm.editUser = editUser;\r\n vm.cancelEdit = cancelEdit;\r\n vm.createUser = createUser;\r\n vm.editingUser = editingUser;\r\n vm.saveUser = saveUser;\r\n vm.cancelConfigureSSO = cancelConfigureSSO;\r\n vm.checkForSpaces = checkForSpaces;\r\n vm.showDescriptionDialog = showDescriptionDialog;\r\n vm.emailPasswordReset = emailPasswordReset;\r\n vm.getHomeInstanceName = getHomeInstanceName;\r\n vm.goToLoginManager = goToLoginManager;\r\n\r\n activate();\r\n\r\n $scope.$on('modal.closing', function (event) {\r\n if(vm.editMode) {\r\n event.preventDefault();\r\n\r\n messageBoxService.confirm('Editing is in progress. Are you sure you want to leave?').then(function() {\r\n vm.editMode = false;\r\n event.targetScope.$dismiss();\r\n });\r\n }\r\n\t\t});\r\n\r\n function activate() {\r\n vm.canEdit = true;//accountUserService.isInRole(accountUserService.Roles.USERSEDIT);\r\n vm.canEditUserInfo = restrictService.hasInstanceRight(restrictService.InstanceRights.MANAGEUSERSETUP, userInstanceService.SystemInstanceId) && vm.inSupportInstance;\r\n vm.userId = vm.contact.userID;\r\n vm.instanceId = vm.contact.company.instanceID;\r\n vm.canResetPassword = restrictService.hasInstanceRight(restrictService.InstanceRights.MANAGEUSERSETUP, vm.instanceId) &&\r\n (!featureFlagsService.featureFlags.enableIAM || !vm.contact.isMigrated);\r\n vm.showActiveCheckbox = !featureFlagsService.featureFlags.enableIAM;\r\n\r\n if (vm.contact.iamMigrationStatus === 1/* Core.ContactIamStatusEnum.Onboarding */) {\r\n vm.iamMigrationStatus = 'Onboarding';\r\n } else if (vm.contact.iamMigrationStatus === 2/* Core.ContactIamStatusEnum.Migrated */) {\r\n vm.iamMigrationStatus = 'Migrated';\r\n }\r\n\r\n //get available instance rights\r\n instancePermissionService.getAllByContactId(vm.contact.contactID)\r\n .then( function(r) {\r\n vm.availableInstanceRights = r;\r\n vm.permissionsLookup = _.cloneDeep(r);\r\n\r\n if (vm.userId) {\r\n //get user\r\n userSetupService.getUserData(vm.userId, vm.contact.contactID)\r\n .then(setUser);\r\n } else {\r\n vm.userToEdit = {\r\n active: true,\r\n userToGroup: [],\r\n roles: [],\r\n permissions: [],\r\n instancePermissions:[],\r\n };\r\n }\r\n });\r\n\r\n if (vm.canEditUserInfo) {\r\n if (vm.userId) {\r\n instanceRepository.getUserContactInviteStatuses(vm.userId).then(cs => {\r\n vm.contactStatuses = [];\r\n if (cs) {\r\n vm.contactStatuses = cs.filter(c=>c.active);\r\n }\r\n });\r\n } else {\r\n vm.contactStatuses = [{\r\n instanceId: vm.contact && vm.contact.company && vm.contact.company.instance && vm.contact.company.instance.instanceID,\r\n instanceName: vm.contact && vm.contact.company && vm.contact.company.instance && vm.contact.company.instance.name\r\n }];\r\n }\r\n }\r\n\r\n vm.isLicensedUser = accountService.userData.isLicensedUser;\r\n }\r\n\r\n //BFM WK-2639\r\n function emailPasswordReset(userName) {\r\n messageBoxService.open({\r\n message: 'This will generate a new password and email it to this user. Are you sure?',\r\n buttons: MessageBoxButtons.OKCancel\r\n }).then(function (result) {\r\n if (result !== MessageBoxResult.OK) {\r\n vm.isLoading = false;\r\n }\r\n else {\r\n accountUserService.emailPasswordReset(userName).then(function () {\r\n toastr.success('Password generated and emailed to user');\r\n vm.isLoading = false;\r\n }).catch(function () {\r\n toastr.error('There was an error generating the password or emailing it to the user');\r\n vm.isLoading = false;\r\n });\r\n }\r\n });\r\n }\r\n\r\n function editUser(form) {\r\n form.$show();\r\n\r\n vm.configuringSSO = false;\r\n vm.newSSODomain = null;\r\n vm.editMode = true;\r\n }\r\n\r\n function cancelEdit(form) {\r\n form.$cancel();\r\n\r\n vm.editMode = false;\r\n vm.userToEdit = angular.copy(userToRevertTo);\r\n }\r\n\r\n function editingUser() {\r\n return vm.userId || vm.editMode;\r\n }\r\n\r\n function createUser(isLegacyUser) {\r\n vm.isLegacyUser = isLegacyUser;\r\n\r\n if (!vm.contact || !vm.contact.address || !vm.contact.address.email) {\r\n toastr.error('Email is required; please edit contact info, enter valid email address and try again', '');\r\n return;\r\n }\r\n\r\n vm.isLoading = true;\r\n\r\n (function() {\r\n if (isLegacyUser) {\r\n // Essentially a no-op; you don't have to be an IAM admin to create a legacy user\r\n return $q(function (res) { res(true); });\r\n }\r\n else {\r\n return userSetupService.isIAMAdmin();\r\n }\r\n }()).then(function (isAdmin) {\r\n if (!isAdmin) {\r\n vm.needTaxDotComPermission = true;\r\n }\r\n else {\r\n return setupSSODropdown().then(function () {\r\n vm.ssoDomains[0] = \"(no SSO)\";\r\n vm.userToEdit.ssoDomain = vm.ssoDomains[0];\r\n vm.editMode = true;\r\n });\r\n }\r\n }).finally(function () {\r\n vm.isLoading = false;\r\n productAnalyticsService.logEvent('PP-contact-create-user');\r\n });\r\n\r\n vm.userToEdit.instanceId = vm.instanceId;\r\n vm.userToEdit.userName = vm.contact.address.email;\r\n }\r\n\r\n function saveUser(form) {\r\n\r\n sdLogger.log(APP_SOURCE + '.saveUser(): Success - ', {\r\n 'result': vm.userToEdit\r\n });\r\n\r\n vm.isLoading = true;\r\n\r\n //editing existing user\r\n if (vm.userId) {\r\n vm.configuringSSO = false;\r\n if (vm.userToEdit.ssoDomain === '(disable)') {\r\n vm.userToEdit.ssoDomain = null;\r\n }\r\n if (vm.newSSODomain) {\r\n vm.userToEdit.ssoDomain = vm.newSSODomain;\r\n vm.newSSODomain = null;\r\n }\r\n var userToSave = prepareUser();\r\n\r\n return accountUserService.updateUser(userToSave)\r\n .then(function (result) {\r\n\r\n //console.log('user info saved; result: ', result);\r\n\r\n vm.userToEdit.userToGroup = cleanUpEFAction(vm.userToEdit.userToGroup);\r\n vm.userToEdit.permissions = cleanUpEFAction(vm.userToEdit.permissions);\r\n\r\n _mapPermissions(vm.userToEdit.permissions);\r\n\r\n // We used to do this in the old user service; it's been moved. Also, it never took an argument,\r\n // so I think this probably should somehow detect when the user changed their own roles. Also,\r\n // does this need to be done at all? It seems like nonsense to me; users can't add new roles\r\n // to themselves, and would rarely remove them from themselves.\r\n //accountUserService.resetRoles(userToSave);\r\n accountService.resetRoles();\r\n\r\n userToRevertTo = angular.copy(vm.userToEdit);\r\n vm.editMode = false;\r\n vm.isLoading = false;\r\n })\r\n .catch(function (error) {\r\n vm.isLoading = false;\r\n error.appSource = APP_SOURCE;\r\n error.message = 'Sorry, there was a problem updating this user.';\r\n toastr.error(error.error.message);\r\n return error.message;\r\n });\r\n }\r\n //creating new user\r\n else {\r\n\r\n //console.log('calling contactsService.createUser(vm.contact.contactID, vm.userToEdit)', vm.contact.contactID, vm.userToEdit);\r\n vm.userToEdit.lockoutEnabled = 1;\r\n if (vm.userToEdit.ssoDomain === vm.ssoDomains[0]) {\r\n vm.userToEdit.ssoDomain = null;\r\n }\r\n\r\n vm.userToEdit.isLegacyUser = vm.isLegacyUser;\r\n\r\n var message = 'You are about to create a new user from this contact Are you sure?';\r\n messageBoxService.open({\r\n title: 'Confirm Create User',\r\n message: message,\r\n buttons: MessageBoxButtons.YesNo\r\n }).then(function (result) {\r\n if (result !== MessageBoxResult.Yes) {\r\n vm.isLoading = false;\r\n form.$show();\r\n return;\r\n }\r\n\r\n return contactsService.createUser(vm.contact.contactID, vm.userToEdit).then(function (user) {\r\n vm.contact.userID = user.id;\r\n userSetupService.getUserData(user.id, vm.contact.contactID).then(function (result) {\r\n setUser(result);\r\n\r\n //send email only for non-sso users being created (user's home instance is the current instance - brand new user)\r\n if (\r\n !vm.userToEdit.ssoDomain &&\r\n (!featureFlagsService.featureFlags.enableIAM || vm.isLegacyUser) &&\r\n vm.userToEdit.instanceId === userInstanceService.getSelectedInstance().instanceId\r\n ) {\r\n emailPasswordReset(result.userName);\r\n }\r\n else {\r\n vm.isLoading = false;\r\n toastr.success('User saved');\r\n }\r\n });\r\n }).catch(function (error) {\r\n vm.isLoading = false;\r\n console.log(error)\r\n error.appSource = APP_SOURCE;\r\n let message = 'Sorry, there was a problem updating this user.';\r\n\r\n if (error.status === 409) {\r\n message = 'User Name is already in use with another Contact.';\r\n }\r\n else if(error.error) {\r\n message = error.error.message;\r\n }\r\n\r\n toastr.error(message);\r\n form.$show();\r\n vm.editMode = true;\r\n\r\n return message;\r\n });\r\n });\r\n }\r\n }\r\n\r\n // this function takes the permission attributes and puts them into a 'permission' attribute\r\n // which can be mapped to a dropdown list value\r\n /*\r\n const OPT_HIDE = 'Hide';\r\n const OPT_VIEW_ALL = 'View All Sites';\r\n const OPT_VIEW_EDIT_SOME = 'View/Edit Some Sites';\r\n const OPT_EDIT_ALL = 'Edit All Sites';\r\n */\r\n function _mapPermissions(permissions) {\r\n\r\n if (permissions === undefined) return;\r\n\r\n for (var i = 0; i < permissions.length; i++) {\r\n\r\n var p = permissions[i];\r\n\r\n if (!p.writeAllowed && !p.readAllowed) {\r\n p.permission = OPT_HIDE;\r\n }\r\n\r\n if (p.writeAllowed) {\r\n if (p.includeAllChildRecords) {\r\n p.permission = OPT_EDIT_ALL;\r\n } else {\r\n p.permission = OPT_VIEW_EDIT_SOME;\r\n }\r\n } else if (p.readAllowed) {\r\n if (p.includeAllChildRecords) {\r\n p.permission = OPT_VIEW_ALL;\r\n } else {\r\n p.permission = OPT_VIEW_EDIT_SOME;\r\n }\r\n }\r\n\r\n }\r\n }\r\n\r\n function cleanUpEFAction(entities) {\r\n return _.chain(entities)\r\n .reject({\r\n efAction: 'delete'\r\n })\r\n .map(function (group) {\r\n group.efAction = null;\r\n\r\n return group;\r\n })\r\n .value();\r\n }\r\n\r\n function setUser(result) {\r\n sdLogger.log(APP_SOURCE + '.setUser(): Success - ', {\r\n 'result': result\r\n });\r\n\r\n console.log('setuser: ', result);\r\n\r\n vm.userToEdit = result;\r\n vm.userId = result.id;\r\n\r\n vm.userToEdit.userToGroup = cleanUpEFAction(vm.userToEdit.userToGroup);\r\n vm.userToEdit.permissions = cleanUpEFAction(vm.userToEdit.permissions);\r\n vm.userToEdit.instancePermissions = cleanUpEFAction(vm.userToEdit.instancePermissions);\r\n\r\n _mapPermissions(vm.userToEdit.permissions);\r\n _mapPermissions(vm.userToEdit.instancePermissions);\r\n\r\n //console.log('setuser: vm.userToEdit.userToGroup ', vm.userToEdit.userToGroup);\r\n //console.log('setuser: vm.userToEdit.permissions ', vm.userToEdit.permissions);\r\n\r\n userToRevertTo = angular.copy(vm.userToEdit);\r\n\r\n vm.editMode = false;\r\n setupSSODropdown();\r\n }\r\n\r\n function setupSSODropdown() {\r\n return userSetupService.getSSODomains(vm.contact.contactID).then(function (ssoDomains) {\r\n var domains = [];\r\n if (vm.userToEdit.ssoDomain && ssoDomains.indexOf(vm.userToEdit.ssoDomain) < 0) {\r\n domains.push(vm.userToEdit.ssoDomain);\r\n }\r\n domains = domains.concat(ssoDomains);\r\n vm.newSSODomains = domains;\r\n vm.ssoDomains = ['(disable)'].concat(domains);\r\n });\r\n }\r\n\r\n function prepareUser() {\r\n var user = angular.copy(vm.userToEdit);\r\n\r\n user.contactID = vm.contact.contactID;\r\n\r\n //roles\r\n user.roles = _.map(user.roles, function (role) {\r\n return {\r\n roleID: role.roleID,\r\n userID: user.id\r\n }\r\n });\r\n\r\n //user to group\r\n user.userToGroup = _.map(user.userToGroup, function (userGroup) {\r\n userGroup = _.pick(userGroup, 'groupID', 'efAction');\r\n userGroup.userID = user.id;\r\n\r\n return userGroup;\r\n });\r\n\r\n //global roles (app permisisons)\r\n var _editedPermissions = _.filter(user.permissions, function (p) {\r\n return p.efAction !== null;\r\n });\r\n user.permissions = _editedPermissions;\r\n user.permissions = _.map(user.permissions, function (permission) {\r\n permission.userId = user.id;\r\n\r\n return permission;\r\n });\r\n user.permissions = _.uniqWith(user.permissions, _.isEqual);\r\n //instance rights - leave them alone\r\n\r\n return user;\r\n }\r\n\r\n function checkForSpaces(userName, form) {\r\n if (userName.indexOf(' ') !== -1) {\r\n form.$setError('userName', 'User Name cannot contain spaces');\r\n form.$invalid = true;\r\n } else {\r\n form.$setError('userName', '');\r\n form.$invalid = false;\r\n }\r\n }\r\n\r\n async function showDescriptionDialog() {\r\n const commentBody = await CommentsModalService.openAddCommentModal({\r\n title: 'User: ' + vm.userToEdit.userName,\r\n commentBody: vm.userToEdit.description,\r\n readOnly: !vm.canEdit,\r\n allowBlank: true\r\n });\r\n if (commentBody) {\r\n accountUserService.setUserDescription(vm.contact.userID, commentBody).then(function () {\r\n vm.userToEdit.description = commentBody;\r\n toastr.success(\"User comments saved\");\r\n });\r\n }\r\n }\r\n\r\n function cancelConfigureSSO() {\r\n vm.configuringSSO = false;\r\n vm.newSSODomain = null;\r\n }\r\n\r\n function getHomeInstanceName() {\r\n if (vm.userToEdit && vm.userToEdit.instanceId && vm.contactStatuses) {\r\n const currentHomeInstance = vm.contactStatuses.find(c=>c.instanceId == vm.userToEdit.instanceId);\r\n return currentHomeInstance && currentHomeInstance.instanceName;\r\n }\r\n }\r\n\r\n function goToLoginManager() {\r\n vm.closeModal();\r\n }\r\n }\r\n})();\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tvar VIEW_TEMPLATE_URL = 'app/User/_userSetup.html';\r\n\tvar CONTROLLER_NAME = 'sd.User.Setup.Controller';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.directive('sdUserSetup', sdUserSetup);\r\n\r\n\tsdUserSetup.$inject = [];\r\n\r\n\tfunction sdUserSetup() {\r\n\t\t// Usage:\r\n\t\t//\r\n\t\t// Creates:\r\n\t\t//\r\n\t\tvar directive = {\r\n\t\t\tbindToController: true,\r\n\t\t\ttemplateUrl: VIEW_TEMPLATE_URL,\r\n\t\t\tcontroller: CONTROLLER_NAME,\r\n\t\t\tcontrollerAs: 'vm',\r\n\t\t\tlink: link,\r\n\t\t\trestrict: 'E',\r\n\t\t\tscope: {\r\n\t\t\t\tcontact: '=',\r\n\t\t\t\ttabSelected: '=',\r\n\t\t\t\tcloseModal: '='\r\n\t\t\t}\r\n\t\t};\r\n\t\treturn directive;\r\n\r\n\t\tfunction link(scope, element, attrs) {}\r\n\t}\r\n})();\r\n","window.weissmanBuildTimestamp=1742589304547;","(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.constant('PermissionFlags', {\r\n\t\t\tREAD: 0,\r\n\t\t\tWRITE: 1,\r\n\t\t\tREAD_INCLUDE_ALL: 2,\r\n\t\t\tWRITE_INCLUDE_ALL: 3\r\n\t\t})\r\n\t\t.constant('DXPSyncModes', {\r\n\t\t\tDISABLED: 1,\r\n\t\t\tENABLED: 2,\r\n\t\t\tDIAGNOSTIC: 3\r\n\t\t})\r\n\t\t.constant('EntityTypes', {\r\n\t\t\tCOMPANY: 'company',\r\n\t\t\tSITE: 'site'\r\n\t\t})\r\n\t\t.constant('EntityTypeIDs', {\r\n\t\t\tCOMPANY: 1,\r\n\t\t\tSTATE: 2,\r\n\t\t\tASSESSOR: 3,\r\n\t\t\tCOLLECTOR: 4,\r\n\t\t\tSITE: 5,\r\n\t\t\tPARCEL: 6,\r\n\t\t\tASSESSMENT: 7,\r\n\t\t\tAPPEAL: 8,\r\n\t\t\tTAX_BILL: 9,\r\n\t\t\tFILING: 10,\r\n\t\t\tPAYMENT: 11,\r\n\t\t\tANNUAL_YEAR: 12,\r\n\t\t\tBILL_CLUSTER: 13,\r\n\t\t\tREFUND: 14,\r\n\t\t\tINTAKE_ITEM: 15,\r\n\t\t\tUSER: 16,\r\n\t\t\tCONTACT: 17,\r\n\t\t\tPAYMENTPACKAGE: 19,\r\n\t\t\tINVOICE: 21,\r\n ASSET: 22,\r\n FORM: 23,\r\n FORMREVISION: 24,\r\n FACTORTABLE: 25,\r\n\t\t\tFILINGBATCH: 26,\r\n\t\t\tINTAKE_BATCH: 27,\r\n\t\t\tTAXAUTHORITY: 28,\r\n\t\t\tTAXRATEAREA: 29,\r\n\t\t\tBUDGET: 31,\r\n\t\t\tACCOUNTINGPERIOD: 32,\r\n ALLOCATION: 33,\r\n\t\t\tPAYMENTBATCH: 41\r\n\t\t})\r\n\t\t.constant('EntityTypeNames', {\r\n\t\t\t1: 'Company',\r\n\t\t\t2: 'State',\r\n\t\t\t3: 'Assessor',\r\n\t\t\t4: 'Collector',\r\n\t\t\t5: 'Site',\r\n\t\t\t6: 'Parcel',\r\n\t\t\t7: 'Assessment',\r\n\t\t\t8: 'Appeal',\r\n\t\t\t9: 'Tax Bill',\r\n\t\t\t10: 'PP Compliance',\r\n\t\t\t11: 'Tax Payment',\r\n\t\t\t12: 'Annual Year',\r\n\t\t\t13: 'Bill Cluster',\r\n\t\t\t14: 'Refund',\r\n\t\t\t15: 'Intake',\r\n\t\t\t16: 'User',\r\n\t\t\t17: 'Contact',\r\n\t\t\t19: 'PaymentPackage',\r\n\t\t\t21: 'Invoice',\r\n\t\t\t22: 'Asset',\r\n 23: 'Form',\r\n 24: 'Form Revision',\r\n 25: 'Factor Table',\r\n 26: 'Filing Batch',\r\n 27: 'Intake Batch',\r\n 28: 'Tax Authority',\r\n 29: 'Tax Rate Area',\r\n 31: 'Budget',\r\n 32: 'Accounting Period',\r\n 33: 'Allocation',\r\n\t\t\t41: 'Payment Batch'\r\n\t\t})\r\n\t\t.constant('EntityTypeLevels', {\r\n\t\t\t1: 7,\r\n\t\t\t5: 5,\r\n\t\t\t6: 4,\r\n\t\t\t7: 3,\r\n\t\t\t8: 3,\r\n\t\t\t9: 2,\r\n\t\t\t10: 1,\r\n\t\t\t14: 3,\r\n\t\t\t31: 3\r\n\t\t})\r\n\t\t.constant('PropertyTypes', {\r\n\t\t\tRE: {\r\n\t\t\t\tpropTypeName: 'Real Estate',\r\n\t\t\t\tpropTypeAbbr: 'RE',\r\n\t\t\t\tsequence: 1,\r\n\t\t\t\tpropertyTypeID: 1\r\n\t\t\t},\r\n\t\t\tPP: {\r\n\t\t\t\tpropTypeName: 'Personal',\r\n\t\t\t\tpropTypeAbbr: 'PP',\r\n\t\t\t\tsequence: 2,\r\n\t\t\t\tpropertyTypeID: 2\r\n\t\t\t},\r\n\t\t\tMN: {\r\n\t\t\t\tpropTypeName: 'Mineral',\r\n\t\t\t\tpropTypeAbbr: 'MN',\r\n\t\t\t\tsequence: 3,\r\n\t\t\t\tpropertyTypeID: 3\r\n\t\t\t},\r\n\t\t\tCA: {\r\n\t\t\t\tpropTypeName: 'Centrally Assessed',\r\n\t\t\t\tpropTypeAbbr: 'CA',\r\n\t\t\t\tsequence: 4,\r\n\t\t\t\tpropertyTypeID: 4\r\n\t\t\t}\r\n\t\t})\r\n\t\t.constant('PropCharNames', {\r\n\t\t\tSQFT: 'Imps. SqFt',\r\n\t\t\tUNITS: 'Units',\r\n\t\t\tACREAGE: 'Land Acreage',\r\n\t\t})\r\n\t\t.constant('ActivityPanelModes', {\r\n\t\t\ttotalFMV: 'totalFMV',\r\n\t\t\ttotalFMVPerSqFt: 'totalFMVPerSqFt',\r\n\t\t\ttotalFMVPerUnit: 'totalFMVPerUnit',\r\n\t\t\tlandFMVPerSqFt: 'landFMVPerSqFt',\r\n\t\t\tlandFMVPerAcre: 'landFMVPerAcre',\r\n\t\t\ttotalTaxes: 'totalTaxes',\r\n\t\t\trecentAppeals: 'recentAppeals',\r\n\t\t})\r\n\t\t.constant('Roles', {\r\n\t\t\t// ADDNEWCOMPANY: 'AddNewCompany',\r\n\t\t\tASSESSOREDIT: 'AssessorEdit',\r\n\t\t\tASSESSORVIEW: 'AssessorView',\r\n\t\t\tCOLLECTOREDIT: 'CollectorEdit',\r\n\t\t\tCOLLECTORVIEW: 'CollectorView',\r\n\t\t\tCOMMENTSEDIT: 'CommentsEdit',\r\n\t\t\tCOMMENTSVIEW: 'CommentsView',\r\n\t\t\tCOMPANYVIEW: 'CompanyView',\r\n\t\t\t// CONTACTVIEW: 'ContactView',\r\n\t\t\t// CONTACTEDIT: 'ContactEdit',\r\n\t\t\t//CONTACTROLEEDIT: 'ContactRoleEdit',\r\n\t\t\tCONTACTROLEVIEW: 'ContactRoleView',\r\n MANAGEAPIKEYS: 'ManageAPIKeys',\r\n\t\t\tPROPCHAREDIT: 'PropCharEdit',\r\n\t\t\tPROPCHARVIEW: 'PropCharView',\r\n\t\t\t// AGENTINFORMATIONEDIT: 'AgentInformationEdit',\r\n\t\t\t// AGENTINFORMATIONVIEW: 'AgentInformationView',\r\n\t\t\tRYANPRIVATEITEMSVIEW: 'RyanPrivateItemsView',\r\n\t\t\tRYANPRIVATEITEMSEDIT: 'RyanPrivateItemsEdit',\r\n\t\t\tSTATEEDIT: 'StateEdit',\r\n\t\t\tSTATEVIEW: 'StateView',\r\n\t\t\t//TEAMSETUPVIEW: 'TeamSetupsView',\r\n\t\t\t// TEAMSETUPSEDIT: 'TeamSetupsEdit',\r\n\t\t\t//USERGROUPSEDIT: 'UserGroupsEdit',\r\n\t\t\t//USERGROUPSVIEW: 'UserGroupsView',\r\n\t\t\tUSERSEDIT: 'UsersEdit',\r\n\t\t\tUSERSVIEW: 'UsersView',\r\n SYSTEMSEARCHESEDIT: 'EditSystemSearches',\r\n //COMPLIANCEFEATURESVIEW: 'ComplianceFeaturesView',\r\n COMPLIANCESETUPSVIEW: 'ComplianceSetupsView',\r\n COMPLIANCESETUPSEDIT: 'ComplianceSetupsEdit',\r\n\t\t\tALLOWDATAIMPORTS: 'AllowDataImports',\r\n\t\t\t// ALLOWMOVECOPY: 'AllowMoveCopy',\r\n ADMINOPERATIONSVIEW: 'AdminOperationsView',\r\n\t\t\tADMINOPERATIONSEDIT: 'AdminOperationsEdit',\r\n FORMSUNDERDEVELOPMENTVIEW: 'FormsUnderDevelopmentView',\r\n\t\t\t//COMPANYDATAIMPORTSVIEW: 'CompanyDataImportsView',\r\n\t\t\tUSERREPORTSALLOW: 'UserReportsAllow',\r\n\t\t\tTAXRATESETUP: 'TaxRateSetup',\r\n\t\t\tINSTANCEADMIN: 'InstanceAdmin',\r\n SUPPORT: 'Support',\r\n ALLOWMANAGESYSTEM: 'AllowManageSystem',\r\n LICENSEDDOCUMENTSERVICES: 'LicensedDocumentServices'\r\n })\r\n\t\t.constant('InstanceRights', {\r\n\t\t\tADDNEWCOMPANY: 'AddNewCompany',\r\n\t\t\t// ASSESSOREDIT: 'AssessorEdit',\r\n\t\t\t// ASSESSORVIEW: 'AssessorView',\r\n\t\t\t// COLLECTOREDIT: 'CollectorEdit',\r\n\t\t\t// COLLECTORVIEW: 'CollectorView',\r\n\t\t\t// COMMENTSEDIT: 'CommentsEdit',\r\n\t\t\t// COMMENTSVIEW: 'CommentsView',\r\n\t\t\t// COMPANYVIEW: 'CompanyView',\r\n\t\t\tCONTACTVIEW: 'ContactView',\r\n\t\t\tCONTACTEDIT: 'ContactEdit',\r\n\t\t\tMANAGECONSULTINGENGAGEMENT:'ManageConsultingEngagement',\r\n\t\t\t// CONTACTROLEEDIT: 'ContactRoleEdit',\r\n\t\t\t// CONTACTROLEVIEW: 'ContactRoleView',\r\n // MANAGEAPIKEYS: 'ManageAPIKeys',\r\n\t\t\t// PROPCHAREDIT: 'PropCharEdit',\r\n\t\t\t// PROPCHARVIEW: 'PropCharView',\r\n\t\t\tAGENTINFORMATIONEDIT: 'AgentInformationEdit',\r\n\t\t\tAGENTINFORMATIONVIEW: 'AgentInformationView',\r\n\t\t\t// RYANPRIVATEITEMSVIEW: 'RyanPrivateItemsView',\r\n\t\t\t// RYANPRIVATEITEMSEDIT: 'RyanPrivateItemsEdit',\r\n\t\t\t// STATEEDIT: 'StateEdit',\r\n\t\t\t// STATEVIEW: 'StateView',\r\n\t\t\tTEAMSETUPSVIEW: 'TeamSetupsView',\r\n\t\t\tTEAMSETUPSEDIT: 'TeamSetupsEdit',\r\n\t\t\tUSERGROUPSEDIT: 'UserGroupsEdit',\r\n\t\t\tUSERGROUPSVIEW: 'UserGroupsView',\r\n\t\t\tUSERSEDIT: 'UsersEdit',\r\n\t\t\tUSERSVIEW: 'UsersView',\r\n // SYSTEMSEARCHESEDIT: 'EditSystemSearches',\r\n COMPLIANCEFEATURESVIEW: 'ComplianceFeaturesView',\r\n // COMPLIANCESETUPSVIEW: 'ComplianceSetupsView',\r\n // COMPLIANCESETUPSEDIT: 'ComplianceSetupsEdit',\r\n\t\t\t// ALLOWDATAIMPORTS: 'AllowDataImports',\r\n\t\t\tALLOWMOVECOPY: 'AllowMoveCopy',\r\n // ADMINOPERATIONSVIEW: 'AdminOperationsView',\r\n\t\t\t// ADMINOPERATIONSEDIT: 'AdminOperationsEdit',\r\n // FORMSUNDERDEVELOPMENTVIEW: 'FormsUnderDevelopmentView',\r\n\t\t\tCOMPANYDATAIMPORTSVIEW: 'CompanyDataImportsView',\r\n\t\t\t// USERREPORTSALLOW: 'UserReportsAllow',\r\n\t\t\t// TAXRATESETUP: 'TaxRateSetup',\r\n\t\t\tPRIVATEITEMSEDIT: 'PrivateItemsEdit',\r\n\t\t\tPRIVATEITEMSVIEW: 'PrivateItemsView',\r\n\t\t\tMANAGEUSERSETUP:'ManageUserSetup',\r\n\t\t\tVALUATIONTEMPLATEEDIT: 'ValuationTemplateEdit',\r\n\t\t\tVALUATIONTEMPLATEVIEW: 'ValuationTemplateView',\r\n INSTANCEDATAIMPORTS: 'InstanceDataImports'\r\n })\r\n\t\t.constant('EfActions', {\r\n\t\t\tADD: 'add',\r\n\t\t\tDELETE: 'delete',\r\n\t\t\tUPDATE: 'update'\r\n\t\t})\r\n\t\t.constant('ImageURLs', {\r\n\t\t\tENTITY_MAP: '/images/googlemaps-icon.png',\r\n\t\t\tATTACHMENTS_IMAGES: '/images/image_attachment.png',\r\n\t\t\tATTACHMENTS_ALL_NONE: '/images/attachment_empty.png',\r\n\t\t\tATTACHMENTS_ALL_SOME: '/images/attachment_some.png',\r\n\t\t\tATTACHMENTS_IMAGES_ICON: 'fa-files-o',\r\n\t\t\tATTACHMENTS_ALL_NONE_ICON: 'fa-paperclip',\r\n\t\t\tATTACHMENTS_ALL_SOME_ICON: 'fa-files-o'\r\n\t\t})\r\n\t\t.constant('UserSettings', {\r\n\t\t\tADVANCED_SEARCH: 10,\r\n\t\t\tQUICK_SEARCH: 11\r\n\t\t})\r\n\t\t.constant('AdvancedSearchCategoryTypes', {\r\n\t\t\tSYSTEM: 0,\r\n\t\t\tCUSTOM: 1,\r\n\t\t\tCOMPANY: 2\r\n\t\t})\r\n\t\t.constant('DefaultDisplayTypes', {\r\n\t\t\tCRITERIA: 0,\r\n\t\t\tRESULTS: 1\r\n\t\t})\r\n\t\t.constant('AdvancedSearchDataTypes', {\r\n\t\t\tVARCHAR: 1,\r\n\t\t\tSMALLINT: 2,\r\n\t\t\tINT: 3,\r\n\t\t\tDECIMAL: 4,\r\n\t\t\tMONEY: 5,\r\n\t\t\tBIT: 6,\r\n\t\t\tDATETIME2: 7,\r\n\t\t\tPICKLIST: 8,\r\n\t\t\tTEXT_ALIGN_LEFT: 10,\r\n\t\t\tTEXT_ALIGN_RIGHT: 11,\r\n\t\t\tTEXT_ALIGN_CENTER: 12,\r\n\t\t\tNUMBER_0: 20,\r\n\t\t\tNUMBER_1: 21,\r\n\t\t\tNUMBER_2: 22,\r\n\t\t\tNUMBER_3: 23,\r\n\t\t\tNUMBER_0_NOGROUPING: 24,\r\n\t\t\tCURRENCY_0: 30,\r\n\t\t\tCURRENCY_2: 32,\r\n\t\t\tPERCENT_0: 40,\r\n\t\t\tPERCENT_1: 41,\r\n\t\t\tPERCENT_2: 42,\r\n\t\t\tPERCENT_3: 43,\r\n\t\t\tPERCENT_4: 44,\r\n\t\t\tPERCENT_5: 45,\r\n\t\t\tPERCENT_6: 46,\r\n\t\t\tYESNO: 50,\r\n\t\t\tDATE: 60,\r\n\t\t\tDATETIME: 61,\r\n\t\t\tATTACHMENTICONOPENPREVIEW: 70\r\n\t\t})\r\n\t\t.constant('ActionViewCategoryTypes', {\r\n\t\t\tSYSTEM: 0,\r\n\t\t\tCUSTOM: 1\r\n\t\t})\r\n\t\t.constant('ReportCategoryTypes', {\r\n\t\t\tSYSTEM: 0,\r\n\t\t\tCUSTOM: 1\r\n\t\t})\r\n\t\t.constant('WorkflowUserTypes', {\r\n\t\t\tNA: 0,\r\n\t\t\tACCOUNT_HANDLER: 1,\r\n\t\t\tJURISDICTION_SPECIALIST: 2,\r\n\t\t\tUSER: 3,\r\n\t\t\tCONSULTANT:4\r\n\t\t})\r\n\t\t.constant('TaskActionTypes', {\r\n\t\t\tCOMPLETETASK: 3,\r\n\t\t\tRESCINDTASK: 4,\r\n\t\t\tREASSIGNTASK: 5,\r\n\t\t\tINSERTNEWAFTERTHISTASK: 6,\r\n\t\t\tDELETETASK: 7,\r\n\t\t\tSKIPTASK: 8,\r\n\t\t\tINSERTNEWBEFORETHISTASK: 9,\r\n\t\t\tGETINSERTOPTIONS: 10\r\n\t\t})\r\n\t\t.constant('TaskTypes', {\r\n\t\t\tINFORMALHEARING: 8,\r\n\t\t\tFORMALHEARING: 9,\r\n\t\t\tSUBMITEVIDENCE: 27,\r\n INVOICEAPPEALSAVINGS: 34\r\n\t\t})\r\n .constant('TaskSeriesTypes', {\r\n PPRETURN: 1,\r\n ASMTAPPEALREVIEW: 2,\r\n APPEALPURSUIT: 3,\r\n REFUND: 4,\r\n TAXPAYMENT: 6,\r\n DOCUMENTINTAKE: 7,\r\n MISCFILING: 8,\r\n CLIENTINVOICE: 9,\r\n FREEPORTFILING: 10,\r\n ABATEMENTFILING: 11,\r\n POLLUTIONCONTROLFILING: 12\r\n })\r\n\t\t.constant('ActionViewCategoryTypes', {\r\n\t\t\tSYSTEM: 0,\r\n\t\t\tCUSTOM: 1\r\n\t\t})\r\n\t\t.constant('ActionViewOrganizeByTypes', {\r\n\t\t\tURGENCY: 1,\r\n\t\t\tDUEDATE: 2,\r\n\t\t\tLASTACTIVITYDATE: 3\r\n\t\t})\r\n\t\t.constant('ActionViewGroupByTypes', {\r\n\t\t\tTASKTYPE: {\r\n\t\t\t\tid: 10001,\r\n\t\t\t\tdisplayName: 'Task Type'\r\n\t\t\t},\r\n\t\t\t/*TASKCATEGORY: {\r\n\t\t\t\tid: null,\r\n\t\t\t\tdisplayName: 'Task Category'\r\n\t\t\t},*/\r\n\t\t\tASSIGNEENAME: {\r\n\t\t\t\tid: 10002,\r\n\t\t\t\tdisplayName: 'Assignee Name'\r\n\t\t\t},\r\n\t\t\tASSIGNEETEAM: {\r\n\t\t\t\tid: 10003,\r\n\t\t\t\tdisplayName: 'Assignee Team'\r\n\t\t\t},\r\n\t\t\tRESPONSIBLENAME: {\r\n\t\t\t\tid: 10004,\r\n\t\t\t\tdisplayName: 'Responsible Name'\r\n\t\t\t},\r\n\t\t\tRESPONSIBLETEAM: {\r\n\t\t\t\tid: 10005,\r\n\t\t\t\tdisplayName: 'Responsible Team'\r\n\t\t\t}\r\n\r\n\t\t})\r\n\t\t.constant('ActionViewDisplayTypes', {\r\n\t\t\tFILTER: 0,\r\n\t\t\tOVERVIEW: 1,\r\n\t\t\tDETAILED: 2\r\n\t\t})\r\n\t\t.constant('DocumentExceptionActions', {\r\n\t\t\tADD_COMMENT: 1,\r\n\t\t\tREASSIGN_ITEM: 2,\r\n\t\t\tESCALATE_ITEM: 3,\r\n\t\t\tREJECT_ITEM: 4,\r\n\t\t\tCLOSE_ITEM: 5,\r\n\t\t\tREQUEST_RESEARCH: 6,\r\n\t\t\tCLEAR_EXCEPTION: 7,\r\n\t\t\tBOUNCE_REJECTED: 8,\r\n\t\t\tREQUEST_TAX_RATE_SETUPS: 9\r\n\t\t})\r\n\t\t.constant('ProcessingExceptionStatus', {\r\n\t\t\tADDEDINERROR: 1,\r\n\t\t\tESCALATED: 2,\r\n\t\t\tREJECTED: 3,\r\n\t\t\tRESEARCHREQUESTED: 4\r\n\t\t})\r\n\t\t.constant('ProcessingExceptionStatusText', {\r\n\t\t\t1: 'Added in Error',\r\n\t\t\t2: 'Escalated',\r\n\t\t\t3: 'Rejected',\r\n\t\t\t4: 'Research Requested',\r\n\t\t\t5: 'Rates Requested'\r\n\t\t})\r\n\t\t// If these ever change, be sure to also change them in common/Message-Box/messagebox.service.ts\r\n\t\t.constant('MessageBoxButtons', {\r\n\t\t\tOK: 1,\r\n\t\t\tOKCancel: 2,\r\n\t\t\tYesNo: 3,\r\n\t\t\tYesNoCancel: 4\r\n\t\t})\r\n\t\t// If these ever change, be sure to also change them in common/Message-Box/messagebox.service.ts\r\n\t\t.constant('MessageBoxResult', {\r\n\t\t\tOK: 1,\r\n\t\t\tCancel: 2,\r\n\t\t\tYes: 3,\r\n\t\t\tNo: 4\r\n\t\t})\r\n\t\t.constant('RevisionChangeTypes', {\r\n\t\t\tORIGINAL_TO_FINAL: 1,\r\n\t\t\tFINAL: 2,\r\n\t\t\tOTHER: 3,\r\n\t\t\tNO_CHANGE: 4\r\n\t\t})\r\n\t\t.constant('TransmittalOutputTypes', {\r\n\t\t\tPAPER_TRANSMITTAL: {\r\n\t\t\t\tid: 1,\r\n\t\t\t\tname: 'Paper Transmittal',\r\n\t\t\t\tabbr: 'PT'\r\n\t\t\t},\r\n\t\t\tDIGITAL_TRANSMITTAL: {\r\n\t\t\t\tid: 2,\r\n\t\t\t\tname: 'Digital Transmittal',\r\n\t\t\t\tabbr: 'DT'\r\n\t\t\t},\r\n\t\t\tAP_FEED: {\r\n\t\t\t\tid: 3,\r\n\t\t\t\tname: 'AP Feed',\r\n\t\t\t\tabbr: 'AP'\r\n\t\t\t},\r\n\t\t\tBILL_PAY: {\r\n\t\t\t\tid: 4,\r\n\t\t\t\tname: 'Bill Pay',\r\n\t\t\t\tabbr: 'BP'\r\n\t\t\t}\r\n\t\t})\r\n\t\t.constant('TransmittalGroupBys', {\r\n\t\t\tSUBSIDIARY_COLLECTOR_SITE_DUEDATE: {\r\n\t\t\t\tid: 1,\r\n\t\t\t\tname: 'Subsidiary / Collector / Site / Due Date'\r\n\t\t\t},\r\n\t\t\tCOLLECTOR_SITE_DUEDATE: {\r\n\t\t\t\tid: 2,\r\n\t\t\t\tname: 'Collector / Site / Due Date'\r\n\t\t\t},\r\n\t\t\tSUBSIDIARY_COLLECTOR_DUEDATE: {\r\n\t\t\t\tid: 3,\r\n\t\t\t\tname: 'Subsidiary / Collector / Due Date'\r\n\t\t\t},\r\n\t\t\tCOLLECTOR_DUEDATE: {\r\n\t\t\t\tid: 4,\r\n\t\t\t\tname: 'Collector / Due Date'\r\n\t\t\t}\r\n\t\t})\r\n\t\t.constant('ClientServicesEnum', {\r\n\t\t\tComplianceReturns: {\r\n\t\t\t\tid: 1,\r\n\t\t\t\tname: 'Compliance Returns'\r\n\t\t\t},\r\n\t\t\tAssessments: {\r\n\t\t\t\tid: 2,\r\n\t\t\t\tname: 'Assessments'\r\n\t\t\t},\r\n\t\t\tAppeals: {\r\n\t\t\t\tid: 3,\r\n\t\t\t\tname: 'Appeals'\r\n\t\t\t},\r\n\t\t\tTaxBills: {\r\n\t\t\t\tid: 4,\r\n\t\t\t\tname: 'Tax Bills'\r\n\t\t\t},\r\n\t\t\tTaxBillTransmit: {\r\n\t\t\t\tid: 5,\r\n\t\t\t\tname: 'Tax Bill - Transmit'\r\n\t\t\t}\r\n\t\t})\r\n\t\t.constant('CommentTypeNames', {\r\n\t\t\t1: 'Budget',\r\n\t\t\t2: 'PSR',\r\n\t\t\t3: 'Appeal Recommendation',\r\n\t\t\t4: 'DRTT',\r\n 5: 'Accrual Export/Transmit',\r\n 6: 'Import'\r\n\t\t})\r\n\t\t.constant('CommentTypeIDs', {\r\n\t\t\tBUDGET: 1,\r\n\t\t\tPSR: 2\r\n\t\t})\r\n .constant(\r\n 'TaskActionViewContextOption', {\r\n ProcessDocument: 1,\r\n Reassign: 2,\r\n AddComment: 3,\r\n Duplicate: 4,\r\n AppealWarranted: 5,\r\n AppealNotWarranted: 6,\r\n CompleteFileAppeal: 7,\r\n DocumentException: 8,\r\n ChangeAppealDeadline: 9,\r\n ChangeFilingDeadline: 10,\r\n ChangeSubmitEvidenceDate: 11,\r\n ChangeInformalHearingDate: 12,\r\n ChangeFormalHearingDate: 13,\r\n ChangePaymentDueDate: 14,\r\n ChangeIntakeItemDueDate: 15,\r\n ChangeComplianceFilingDueDate: 16,\r\n Transmit: 17,\r\n ReviewPayment: 18,\r\n ReReviewPayment: 19,\r\n CreateInvoice: 20,\r\n PrepareDraftInvoice: 21,\r\n ReviewDraftInvoice: 22,\r\n PreviewThenTransferInvoice: 23,\r\n TransferInvoice: 24,\r\n ChangeInvoiceDueDate: 25,\r\n Skip: 26,\r\n SetDocumentRetrievalStatus: 27,\r\n ChangeContact: 28,\r\n\t\t\t\tCreatePreviewAppealApplication: 29,\r\n\t\t\t\tAddPrepareApplicationTasks: 30,\r\n\t\t\t\tPPReturnDataLoaded: 31,\r\n\t\t\t\t// PPReturnReturnsReviewed: 32,\r\n\t\t\t\t// PPReturnReturnsApproved: 33\r\n MarkInvoiceUBR: 34,\r\n ChangeConfirmHearingDate: 35,\r\n\t\t\t\tAddObtainPaymentReceiptTasks: 36,\r\n\t\t\t\tCompleteObtainPaymentReceiptTasks: 37,\r\n PreviewThenTransferUBR: 38,\r\n TransferUBR: 39,\r\n RequestReliefOfUBR: 40,\r\n InsertObtainWorkpapersTaskBefore: 41,\r\n GenerateAppealListReport: 42,\r\n\t\t\t\tAppealRecommendation: 43,\r\n\t\t\t\tAddToPaymentBatch: 44,\r\n\t\t\t\tPerformOcr: 45\r\n }\r\n )\r\n .constant('ReassignModes', {\r\n Default: 1,\r\n ChangeContact: 2\r\n })\r\n .constant('ContentTypes', {\r\n KNOWNISSUES: 1,\r\n RELEASENOTES: 2\r\n\t\t})\r\n\t\t.constant('SavedSearchCategoryEnum', {\r\n\t\t\tComplianceReportSetup: 200,\r\n\t\t\tComplianceReturnReport: 201,\r\n\t\t\tCompliancePackageReport: 202,\r\n\t\t\tComplianceCustomReport: 203\r\n\t\t})\r\n\t\t.constant('RyanInstanceId', 1)\r\n\t\t.constant('ContactModalOrigin', {\r\n\t\t\tViewProfile:1,\r\n\t\t\tContactsList:2,\r\n\t\t\tEntityContact:3,\r\n\t\t\tNewContact:4\r\n\t\t})\r\n\t\t.constant('ActivityStatusIdMap', {\r\n\t\t\t0: 'Inactive',\r\n\t\t\t1: 'ActivePending',\r\n\t\t\t2: 'Active'\r\n\t\t})\r\n})();\r\n","(function () {\r\n 'use strict';\r\n\r\n var routes = null;\r\n\r\n angular\r\n .module('weissmanApp')\r\n // routes is built internally in configRoutes, but make the object availble to other services\r\n // by exposing a factory to return it.\r\n .factory('routes', function () { return routes; })\r\n .config(configRoutes);\r\n\r\n configRoutes.$inject = ['$urlRouterProvider', '$stateProvider', 'Roles', 'EntityTypeIDs', 'InstanceRights','ContactModalOrigin'];\r\n\r\n function configRoutes($urlRouterProvider, $stateProvider, Roles, EntityTypeIDs, InstanceRights, ContactModalOrigin) {\r\n var baseUrl = 'app/';\r\n\r\n routes = {\r\n 'site': {\r\n url: '/company/:companyId/site/:siteId',\r\n views: {\r\n '': {\r\n templateUrl: baseUrl + 'Entity/Site/_panels.html',\r\n controller: 'sd.Site.Controller',\r\n controllerAs: 'vm',\r\n },\r\n 'contacts@site': {\r\n templateUrl: baseUrl + 'Entity/Site/_contactsPanel.html',\r\n controller: 'sd.Site.Contacts.Panel.Controller',\r\n controllerAs: 'vm',\r\n }\r\n },\r\n resolve: {\r\n $title: function () {\r\n return 'Site';\r\n }\r\n },\r\n },\r\n 'parcel': {\r\n url: '/company/:companyId/site/:siteId/parcel/:parcelId?annualYearID?billClusterID?refundID?annualAssessmentID?appealID?filingId',\r\n templateUrl: baseUrl + 'Entity/Parcel/_parcel.html',\r\n controller: 'ParcelCtrl',\r\n resolve: {\r\n $title: function () {\r\n return 'Parcel';\r\n }\r\n },\r\n },\r\n 'siteRedirect': {\r\n url: '/site/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.SITE; }\r\n }\r\n },\r\n 'parcelRedirect': {\r\n url: '/parcel/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.PARCEL; }\r\n }\r\n },\r\n 'assessmentRedirect': {\r\n url: '/assessment/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.ASSESSMENT; }\r\n }\r\n },\r\n 'appealRedirect': {\r\n url: '/appeal/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.APPEAL; }\r\n }\r\n },\r\n 'billClusterRedirect': {\r\n url: '/billcluster/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.BILL_CLUSTER; }\r\n }\r\n },\r\n 'billRedirect': {\r\n url: '/bill/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.TAX_BILL; }\r\n }\r\n },\r\n 'filingRedirect': {\r\n url: '/filing/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.FILING; }\r\n }\r\n },\r\n 'paymentRedirect': {\r\n url: '/payment/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.PAYMENT; }\r\n }\r\n },\r\n 'refundRedirect': {\r\n url: '/refund/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.REFUND; }\r\n }\r\n },\r\n 'collectorRedirect': {\r\n url: '/collector/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.COLLECTOR; }\r\n }\r\n },\r\n 'assessorRedirect': {\r\n url: '/assessor/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.ASSESSOR; }\r\n }\r\n },\r\n 'invoiceRedirect': {\r\n url: '/invoice/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.INVOICE; }\r\n }\r\n },\r\n 'filingBatchRedirect': {\r\n url: '/filingbatch/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.FilingBatch; }\r\n }\r\n },\r\n 'filingBatchRedirect2': {\r\n url: '/filingBatch/:entityID',\r\n templateUrl: baseUrl + 'Entity/_redirect.html',\r\n controller: 'RedirectCtrl',\r\n resolve: {\r\n entityTypeID: function () { return EntityTypeIDs.FilingBatch; }\r\n }\r\n },\r\n 'logout': {\r\n onEnter: ['accountService', function (accountService) {\r\n return accountService.logout().then(function () {\r\n return false;\r\n });\r\n }]\r\n },\r\n 'contact': {\r\n url: '/contacts/:contactId',\r\n onEnter: ['sd.Contacts.Service.old', '$stateParams', function (contactsService, $stateParams) {\r\n if ($stateParams.contactId) {\r\n contactsService.openContactDialog($stateParams.contactId, ContactModalOrigin.ContactsList);\r\n }\r\n }]\r\n },\r\n 'unauthorizedAccess': {\r\n template: '

You do not have permission to view this page. If you have any questions, please contact the site administrator.

',\r\n resolve: {\r\n $title: function () {\r\n return 'Unauthorized Access';\r\n }\r\n }\r\n },\r\n 'actionview': {\r\n url: '/actionview/:actionViewId?actionViewType&displayType',\r\n params: { actionViewId: null },\r\n templateUrl: baseUrl + 'Task/ActionView/_filtersOutputs.html',\r\n controller: 'FiltersOutputsController',\r\n controllerAs: 'vm',\r\n resolve: {\r\n $title: function () {\r\n return 'Action View';\r\n }\r\n },\r\n onExit: ['actionViewService', function (actionViewService) {\r\n actionViewService.cancelAvSearch();\r\n }]\r\n },\r\n 'documentProcessing': {\r\n url: '/processing/document?taskID?parcelID?intakeItemID',\r\n templateUrl: baseUrl + 'Processing/Documents/_documentProcessing.html',\r\n controller: 'DocumentProcessingController',\r\n controllerAs: 'vm',\r\n params: {\r\n selectedRows: [],\r\n searchTimestamp: null\r\n },\r\n resolve: {\r\n $title: function () {\r\n return 'Document Processing';\r\n }\r\n }\r\n },\r\n // TODO: Consider eliminating the document preview version of this route and moving the files\r\n // to more logical locations; they're the same route except for the URL\r\n 'attachmentPopup': {\r\n url: '/attachmentPopup',\r\n resolve: {\r\n $title: function () {\r\n return 'Attachment Viewer';\r\n }\r\n },\r\n templateUrl: baseUrl + 'Processing/Documents/Popups/_filePreview.html',\r\n controller: 'FilePreviewController',\r\n controllerAs: 'vm'\r\n }\r\n };\r\n\r\n // Hack to produce a resolve on every state definition\r\n // (see https://stackoverflow.com/a/33280010; this was needed\r\n // for navigation warnings)\r\n var originalStateFunction = $stateProvider.state;\r\n $stateProvider.state = function (name, definition) {\r\n if (!definition.resolve) {\r\n definition.resolve = {};\r\n }\r\n\r\n return originalStateFunction.apply(this, arguments);\r\n };\r\n // End hack\r\n\r\n var routeKeys = Object.keys(routes);\r\n\r\n for (var i = 0; i < routeKeys.length; i++) {\r\n var routeKey = routeKeys[i];\r\n\r\n $stateProvider.state(routeKey, routes[routeKey]);\r\n }\r\n }\r\n})();\r\n\r\n","(function () {\r\n\t'use strict';\r\n\r\n\tangular.module('weissmanApp')\r\n\t\t.directive('resizable', function () {\r\n\t\t\tvar toCall;\r\n\r\n\t\t\tfunction throttle(fun) {\r\n\t\t\t\tif (toCall === undefined) {\r\n\t\t\t\t\ttoCall = fun;\r\n\t\t\t\t\tsetTimeout(function () {\r\n\t\t\t\t\t\ttoCall();\r\n\t\t\t\t\t\ttoCall = undefined;\r\n\t\t\t\t\t}, 100);\r\n\t\t\t\t} else {\r\n\t\t\t\t\ttoCall = fun;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn {\r\n\t\t\t\trestrict: 'AE',\r\n\t\t\t\tscope: {\r\n\t\t\t\t\trDirections: '=',\r\n\t\t\t\t\trCenteredX: '=',\r\n\t\t\t\t\trCenteredY: '=',\r\n\t\t\t\t\trWidth: '=',\r\n\t\t\t\t\trHeight: '=',\r\n\t\t\t\t\trFlex: '=',\r\n\t\t\t\t\trGrabber: '@',\r\n\t\t\t\t\trDisabled: '@'\r\n\t\t\t\t},\r\n\t\t\t\tlink: function (scope, element, attr) {\r\n\t\t\t\t\tvar flexBasis = 'flexBasis' in document.documentElement.style ? 'flexBasis' :\r\n\t\t\t\t\t\t'webkitFlexBasis' in document.documentElement.style ? 'webkitFlexBasis' :\r\n\t\t\t\t\t\t'msFlexPreferredSize' in document.documentElement.style ? 'msFlexPreferredSize' : 'flexBasis';\r\n\r\n\t\t\t\t\t// register watchers on width and height attributes if they are set\r\n\t\t\t\t\tscope.$watch('rWidth', function (value) {\r\n\t\t\t\t\t\telement[0].style.width = scope.rWidth + 'px';\r\n\t\t\t\t\t});\r\n\t\t\t\t\tscope.$watch('rHeight', function (value) {\r\n\t\t\t\t\t\telement[0].style.height = scope.rHeight + 'px';\r\n\t\t\t\t\t});\r\n\r\n\t\t\t\t\telement.addClass('resizable');\r\n\r\n\t\t\t\t\tvar style = window.getComputedStyle(element[0], null),\r\n\t\t\t\t\t\tw,\r\n\t\t\t\t\t\th,\r\n\t\t\t\t\t\tdir = scope.rDirections,\r\n\t\t\t\t\t\tvx = scope.rCenteredX ? 2 : 1, // if centered double velocity\r\n\t\t\t\t\t\tvy = scope.rCenteredY ? 2 : 1, // if centered double velocity\r\n\t\t\t\t\t\tinner = scope.rGrabber ? scope.rGrabber : '',\r\n\t\t\t\t\t\tstart,\r\n\t\t\t\t\t\tdragDir,\r\n\t\t\t\t\t\taxis,\r\n\t\t\t\t\t\tinfo = {};\r\n\r\n\t\t\t\t\tvar updateInfo = function (e) {\r\n\t\t\t\t\t\tinfo.width = false;\r\n\t\t\t\t\t\tinfo.height = false;\r\n\t\t\t\t\t\tif (axis === 'x')\r\n\t\t\t\t\t\t\tinfo.width = parseInt(element[0].style[scope.rFlex ? flexBasis : 'width']);\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tinfo.height = parseInt(element[0].style[scope.rFlex ? flexBasis : 'height']);\r\n\t\t\t\t\t\tinfo.id = element[0].id;\r\n\t\t\t\t\t\tinfo.evt = e;\r\n\t\t\t\t\t};\r\n\r\n\t\t\t\t\tvar dragging = function (e) {\r\n\t\t\t\t\t\tvar prop, offset = axis === 'x' ? start - e.clientX : start - e.clientY;\r\n\t\t\t\t\t\tswitch (dragDir) {\r\n\t\t\t\t\t\t\tcase 'top':\r\n\t\t\t\t\t\t\t\tprop = scope.rFlex ? flexBasis : 'height';\r\n\t\t\t\t\t\t\t\telement[0].style[prop] = h + (offset * vy) + 'px';\r\n\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\tcase 'bottom':\r\n\t\t\t\t\t\t\t\tprop = scope.rFlex ? flexBasis : 'height';\r\n\t\t\t\t\t\t\t\telement[0].style[prop] = h - (offset * vy) + 'px';\r\n\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\tcase 'right':\r\n\t\t\t\t\t\t\t\tprop = scope.rFlex ? flexBasis : 'width';\r\n\t\t\t\t\t\t\t\telement[0].style[prop] = w - (offset * vx) + 'px';\r\n\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\tcase 'left':\r\n\t\t\t\t\t\t\t\tprop = scope.rFlex ? flexBasis : 'width';\r\n\t\t\t\t\t\t\t\telement[0].style[prop] = w + (offset * vx) + 'px';\r\n\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tupdateInfo(e);\r\n\t\t\t\t\t\tthrottle(function () { scope.$emit('angular-resizable.resizing', info); });\r\n\t\t\t\t\t};\r\n\t\t\t\t\tvar dragEnd = function (e) {\r\n\t\t\t\t\t\tupdateInfo();\r\n\t\t\t\t\t\tscope.$emit('angular-resizable.resizeEnd', info);\r\n\t\t\t\t\t\tscope.$apply();\r\n\t\t\t\t\t\tdocument.removeEventListener('mouseup', dragEnd, false);\r\n\t\t\t\t\t\tdocument.removeEventListener('mousemove', dragging, false);\r\n\t\t\t\t\t\telement.removeClass('no-transition');\r\n\t\t\t\t\t};\r\n\t\t\t\t\tvar dragStart = function (e, direction) {\r\n\t\t\t\t\t\tdragDir = direction;\r\n\t\t\t\t\t\taxis = dragDir === 'left' || dragDir === 'right' ? 'x' : 'y';\r\n\t\t\t\t\t\tstart = axis === 'x' ? e.clientX : e.clientY;\r\n\t\t\t\t\t\tw = parseInt(style.getPropertyValue('width'));\r\n\t\t\t\t\t\th = parseInt(style.getPropertyValue('height'));\r\n\r\n\t\t\t\t\t\t//prevent transition while dragging\r\n\t\t\t\t\t\telement.addClass('no-transition');\r\n\r\n\t\t\t\t\t\tdocument.addEventListener('mouseup', dragEnd, false);\r\n\t\t\t\t\t\tdocument.addEventListener('mousemove', dragging, false);\r\n\r\n\t\t\t\t\t\t// Disable highlighting while dragging\r\n\t\t\t\t\t\tif (e.stopPropagation) e.stopPropagation();\r\n\t\t\t\t\t\tif (e.preventDefault) e.preventDefault();\r\n\t\t\t\t\t\te.cancelBubble = true;\r\n\t\t\t\t\t\te.returnValue = false;\r\n\r\n\t\t\t\t\t\tupdateInfo(e);\r\n\t\t\t\t\t\tscope.$emit('angular-resizable.resizeStart', info);\r\n\t\t\t\t\t\tscope.$apply();\r\n\t\t\t\t\t};\r\n\r\n\t\t\t\t\tdir.forEach(function (direction) {\r\n\t\t\t\t\t\tvar grabber = document.createElement('div');\r\n\r\n\t\t\t\t\t\t// add class for styling purposes\r\n\t\t\t\t\t\tgrabber.setAttribute('class', 'rg-' + direction);\r\n\t\t\t\t\t\tgrabber.innerHTML = inner;\r\n\t\t\t\t\t\telement[0].appendChild(grabber);\r\n\t\t\t\t\t\tgrabber.ondragstart = function () {\r\n\t\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t\t};\r\n\t\t\t\t\t\tgrabber.addEventListener('mousedown', function (e) {\r\n\t\t\t\t\t\t\tvar disabled = (scope.rDisabled === 'true');\r\n\t\t\t\t\t\t\tif (!disabled && e.which === 1) {\r\n\t\t\t\t\t\t\t\t// left mouse click\r\n\t\t\t\t\t\t\t\tdragStart(e, direction);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}, false);\r\n\t\t\t\t\t});\r\n\t\t\t\t}\r\n\t\t\t};\r\n\t\t});\r\n})();\r\n","angular.module('ui.bootstrap.contextMenu', [])\r\n\r\n.service('CustomService', function () {\r\n \"use strict\";\r\n\r\n return {\r\n initialize: function (item) {\r\n console.log(\"got here\", item);\r\n }\r\n }\r\n\r\n })\r\n .directive('contextMenu', [\"$parse\", \"$q\", \"CustomService\", \"$sce\", function ($parse, $q, custom, $sce) {\r\n\r\n var contextMenus = [];\r\n var $currentContextMenu = null;\r\n var defaultItemText = \"New Item\";\r\n\r\n var removeContextMenus = function (level) {\r\n /// Remove context menu.\r\n while (contextMenus.length && (!level || contextMenus.length > level)) {\r\n contextMenus.pop().remove();\r\n }\r\n if (contextMenus.length == 0 && $currentContextMenu) {\r\n $currentContextMenu.remove();\r\n }\r\n };\r\n\r\n\r\n var processTextItem = function ($scope, item, text, event, modelValue, $promises, nestedMenu, $) {\r\n \"use strict\";\r\n\r\n var $a = $('');\r\n $a.css(\"padding-right\", \"8px\");\r\n $a.attr({ tabindex: '-1', href: '#' });\r\n\r\n if (typeof item[0] === 'string') {\r\n text = item[0];\r\n } else if (typeof item[0] === \"function\") {\r\n text = item[0].call($scope, $scope, event, modelValue);\r\n } else if (typeof item.text !== \"undefined\") {\r\n text = item.text;\r\n }\r\n\r\n var $promise = $q.when(text);\r\n $promises.push($promise);\r\n $promise.then(function (text) {\r\n if (nestedMenu) {\r\n $a.css(\"cursor\", \"default\");\r\n $a.append($('>'));\r\n }\r\n $a.append(text);\r\n });\r\n\r\n return $a;\r\n\r\n };\r\n\r\n var processItem = function ($scope, event, modelValue, item, $ul, $li, $promises, $q, $, level) {\r\n /// Process individual item\r\n \"use strict\";\r\n // nestedMenu is either an Array or a Promise that will return that array.\r\n var nestedMenu = angular.isArray(item[1]) || (item[1] && angular.isFunction(item[1].then)) ? item[1] : angular.isArray(item[2]) || (item[2] && angular.isFunction(item[2].then)) ? item[2] : angular.isArray(item[3]) || (item[3] && angular.isFunction(item[3].then)) ? item[3] : null;\r\n\r\n // if html property is not defined, fallback to text, otherwise use default text\r\n // if first item in the item array is a function then invoke .call()\r\n // if first item is a string, then text should be the string.\r\n\r\n var text = defaultItemText;\r\n if (typeof item[0] === 'function' || typeof item[0] === 'string' || typeof item.text !== \"undefined\") {\r\n text = processTextItem($scope, item, text, event, modelValue, $promises, nestedMenu, $);\r\n } else if (typeof item.html === 'function') {\r\n // leave styling open to dev\r\n text = item.html($scope);\r\n } else if (typeof item.html !== \"undefined\") {\r\n // leave styling open to dev\r\n text = item.html;\r\n }\r\n\r\n $li.append(text);\r\n\r\n\r\n\r\n\r\n // if item is object, and has enabled prop invoke the prop\r\n // els if fallback to item[2]\r\n\r\n var isEnabled = function () {\r\n if (typeof item.enabled !== \"undefined\") {\r\n return item.enabled.call($scope, $scope, event, modelValue, text);\r\n } else if (typeof item[2] === \"function\") {\r\n return item[2].call($scope, $scope, event, modelValue, text);\r\n } else {\r\n return true;\r\n }\r\n };\r\n\r\n registerEnabledEvents($scope, isEnabled(), item, $ul, $li, nestedMenu, modelValue, text, event, $, level);\r\n };\r\n\r\n var handlePromises = function ($ul, level, event, $promises) {\r\n /// \r\n /// calculate if drop down menu would go out of screen at left or bottom\r\n /// calculation need to be done after element has been added (and all texts are set; thus thepromises)\r\n /// to the DOM the get the actual height\r\n /// \r\n \"use strict\";\r\n $q.all($promises).then(function () {\r\n var topCoordinate = event.pageY;\r\n var menuHeight = angular.element($ul[0]).prop('offsetHeight');\r\n var winHeight = event.view.innerHeight;\r\n if (topCoordinate > menuHeight && winHeight - topCoordinate < menuHeight) {\r\n topCoordinate = event.pageY - menuHeight;\r\n } else if (winHeight <= menuHeight) {\r\n // If it really can't fit, reset the height of the menu to one that will fit\r\n angular.element($ul[0]).css({ \"height\": winHeight - 5, \"overflow-y\": \"scroll\" });\r\n // ...then set the topCoordinate height to 0 so the menu starts from the top\r\n topCoordinate = 0;\r\n } else if (winHeight - topCoordinate < menuHeight) {\r\n var reduceThreshold = 5;\r\n if (topCoordinate < reduceThreshold) {\r\n reduceThreshold = topCoordinate;\r\n }\r\n topCoordinate = winHeight - menuHeight - reduceThreshold;\r\n }\r\n\r\n var leftCoordinate = event.pageX;\r\n var menuWidth = angular.element($ul[0]).prop('offsetWidth');\r\n var winWidth = event.view.innerWidth;\r\n var rightPadding = 5;\r\n if (leftCoordinate > menuWidth && winWidth - leftCoordinate - rightPadding < menuWidth) {\r\n leftCoordinate = winWidth - menuWidth - rightPadding;\r\n } else if (winWidth - leftCoordinate < menuWidth) {\r\n var reduceThreshold = 5;\r\n if (leftCoordinate < reduceThreshold + rightPadding) {\r\n reduceThreshold = leftCoordinate + rightPadding;\r\n }\r\n leftCoordinate = winWidth - menuWidth - reduceThreshold - rightPadding;\r\n }\r\n\r\n $ul.css({\r\n display: 'block',\r\n position: 'absolute',\r\n left: leftCoordinate + 'px',\r\n top: topCoordinate + 'px'\r\n });\r\n });\r\n\r\n };\r\n\r\n var registerEnabledEvents = function ($scope, enabled, item, $ul, $li, nestedMenu, modelValue, text, event, $, level) {\r\n /// If item is enabled, register various mouse events.\r\n if (enabled) {\r\n var openNestedMenu = function ($event) {\r\n removeContextMenus(level + 1);\r\n /*\r\n * The object here needs to be constructed and filled with data\r\n * on an \"as needed\" basis. Copying the data from event directly\r\n * or cloning the event results in unpredictable behavior.\r\n */\r\n var ev = {\r\n pageX: event.pageX + $ul[0].offsetWidth - 1,\r\n pageY: $ul[0].offsetTop + $li[0].offsetTop - 3,\r\n view: event.view || window\r\n };\r\n\r\n /*\r\n * At this point, nestedMenu can only either be an Array or a promise.\r\n * Regardless, passing them to when makes the implementation singular.\r\n */\r\n $q.when(nestedMenu).then(function (promisedNestedMenu) {\r\n renderContextMenu($scope, ev, promisedNestedMenu, modelValue, level + 1);\r\n });\r\n };\r\n\r\n $li.on('click', function ($event) {\r\n $event.preventDefault();\r\n $scope.$apply(function () {\r\n if (nestedMenu) {\r\n openNestedMenu($event);\r\n } else {\r\n $(event.currentTarget).removeClass('context');\r\n removeContextMenus();\r\n\r\n if (angular.isFunction(item[1])) {\r\n item[1].call($scope, $scope, event, modelValue, text, $li)\r\n } else {\r\n item.click.call($scope, $scope, event, modelValue, text, $li);\r\n }\r\n }\r\n });\r\n });\r\n\r\n $li.on('mouseover', function ($event) {\r\n $scope.$apply(function () {\r\n if (nestedMenu) {\r\n openNestedMenu($event);\r\n }\r\n });\r\n });\r\n } else {\r\n $li.on('click', function ($event) {\r\n $event.preventDefault();\r\n });\r\n $li.addClass('disabled');\r\n }\r\n\r\n };\r\n\r\n\r\n var renderContextMenu = function ($scope, event, options, modelValue, level, customClass) {\r\n /// Render context menu recursively.\r\n if (!level) { level = 0; }\r\n if (!$) {\r\n var $ = angular.element;\r\n }\r\n $(event.currentTarget).addClass('context');\r\n var $contextMenu = $('
');\r\n if ($currentContextMenu) {\r\n $contextMenu = $currentContextMenu;\r\n } else {\r\n $currentContextMenu = $contextMenu;\r\n $contextMenu.addClass('angular-bootstrap-contextmenu dropdown clearfix');\r\n }\r\n if (customClass) {\r\n $contextMenu.addClass(customClass);\r\n }\r\n var $ul = $('
\r\n","import {\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n ViewChild,\r\n ViewEncapsulation\r\n} from '@angular/core';\r\nimport { TimerService } from '../../../Utilities';\r\nimport { DropdownPosition, SelectConfig, SelectSearch } from '../select.interface';\r\n\r\nconst noop = (values: any[], searchValue: string) => [];\r\n\r\ninterface WindowBuffer {\r\n leftBuffer: number;\r\n topBuffer: number;\r\n}\r\n\r\n@Component({\r\n selector: 'ws-ace-select-dropdown',\r\n templateUrl: './dropdown.component.html',\r\n styleUrls: ['./../select.component.scss', './dropdown.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class AceSelectDropdownComponent {\r\n constructor(private readonly _changDetectorRef: ChangeDetectorRef, private readonly _timer: TimerService) { }\r\n\r\n @Input()\r\n set dropdownConfig(selectConfig: SelectConfig) {\r\n this.selectConfig = selectConfig;\r\n if (this.selectConfig.customSearch) {\r\n this._search.custom = this.selectConfig.customSearch;\r\n }\r\n this.search();\r\n }\r\n @Input()\r\n set targetPosition(target: DOMRect) {\r\n this._targetPosition = target;\r\n this.updateDropdownPosition();\r\n }\r\n @Input()\r\n set isOpen(open: boolean) {\r\n this.open = open;\r\n this._timer.setTimeout(() => {\r\n if (open && this.selectConfig.canSearch && this.selectConfig.options.length >= this.selectConfig.includeSearchAfterN) {\r\n this.searchInput.nativeElement.focus();\r\n }\r\n this._changDetectorRef.detectChanges();\r\n }, 150);\r\n }\r\n\r\n @Output() closed = new EventEmitter();\r\n\r\n @ViewChild('dropdown', { static: true }) dropdown: ElementRef;\r\n @ViewChild('searchInput') searchInput: ElementRef;\r\n\r\n selectConfig: SelectConfig;\r\n open: boolean;\r\n renderedTop: boolean;\r\n searchValue: string;\r\n searchResultCount: number;\r\n dropdownPosition: DropdownPosition;\r\n\r\n private _showMoreClicked: number = 0;\r\n private _targetPosition: DOMRect;\r\n private _edgeBuffer = 10;\r\n private _search: SelectSearch = {\r\n exact: (values: any[], searchValue: string) => values.filter(o => {\r\n const value = (`${(this.selectConfig.isPrimitive) ? o : o[this.selectConfig.labelProperty]}`).toLowerCase();\r\n return (value) ? value.substring(0, searchValue.length) === searchValue.toLowerCase() : false;\r\n }),\r\n fuzzy: (values: any[], searchValue: string) => {\r\n const pattern = searchValue.split('').reduce((a, b) => (`${a }[^${ b }]*${ b}`));\r\n const regex = new RegExp(pattern);\r\n return values.filter(o => {\r\n const value = (this.selectConfig.isPrimitive) ? o : o[this.selectConfig.labelProperty];\r\n return (value) ? regex.test((`${value}`).toLowerCase()) : false;\r\n }).sort((a, b) => {\r\n // Sort by most exact match first\r\n const valueA = (`${(this.selectConfig.isPrimitive) ? a : a[this.selectConfig.labelProperty]}`).toLowerCase();\r\n const valueB = (`${(this.selectConfig.isPrimitive) ? b : b[this.selectConfig.labelProperty]}`).toLowerCase();\r\n const aIncludes = valueA.includes(searchValue.toLowerCase());\r\n const bIncludes = valueB.includes(searchValue.toLowerCase());\r\n if (!aIncludes && bIncludes) {\r\n return 1;\r\n } else if (aIncludes && !bIncludes) {\r\n return -1;\r\n }\r\n return valueA.localeCompare(valueB);\r\n });\r\n },\r\n substring: (values: any[], searchValue: string) => values.filter(o => {\r\n const value = (`${(this.selectConfig.isPrimitive) ? o : o[this.selectConfig.labelProperty]}`).toLowerCase();\r\n return (value) ? value.includes(searchValue.toLowerCase()) : false;\r\n }),\r\n state: (values: { value: Core.StateModel }[], searchValue: string) => {\r\n const pattern = searchValue.split('').reduce((a, b) => (`${a }[^${ b }]*${ b}`));\r\n const regex = new RegExp(pattern);\r\n return values.filter(o => {\r\n return (o.value.fullName && regex.test(o.value.fullName.toLowerCase())) || (o.value.abbr && regex.test(o.value.abbr.toLowerCase()));\r\n }).sort((a, b) => {\r\n // Sort by state abbreviation exact match first\r\n const aMatch = a.value.abbr.toLowerCase() === searchValue.toLowerCase();\r\n const bMatch = b.value.abbr.toLowerCase() === searchValue.toLowerCase();\r\n if (!aMatch && bMatch) {\r\n return 1;\r\n } else if (aMatch && !bMatch) {\r\n return -1;\r\n }\r\n return a.value.fullName.localeCompare(b.value.fullName);\r\n });\r\n },\r\n custom: noop\r\n };\r\n\r\n private readonly MAX_ROWS_BEFORE_SCROLLBAR = 7;\r\n\r\n /**\r\n * Update the position of the dropdown\r\n */\r\n updateDropdownPosition(): void {\r\n // Pre-render to calculate right edge detection accurately\r\n this._prerender();\r\n\r\n // Calculate actual position\r\n const boundingBox = this.dropdown.nativeElement.getBoundingClientRect();\r\n\r\n const top = this._targetPosition.y + window.scrollY + this._targetPosition.height;\r\n const left = this._targetPosition.x;\r\n\r\n const buffer = this._getBuffer(boundingBox, this._targetPosition.y, left);\r\n\r\n if (buffer.topBuffer < 0) {\r\n this._renderToTop();\r\n return;\r\n }\r\n\r\n const width = Math.ceil(this._targetPosition.width);\r\n this.dropdownPosition = {\r\n left: `${left + buffer.leftBuffer}px`,\r\n top: `${top}px`,\r\n width: this._scrollBarWidth(width)\r\n };\r\n this.renderedTop = false;\r\n this._changDetectorRef.detectChanges();\r\n }\r\n\r\n /**\r\n * Search the data\r\n */\r\n search(): boolean {\r\n const searchValue = (this.searchValue && this.searchValue.length) ? this.searchValue.trim().toLowerCase() : null;\r\n\r\n const options = [...this.selectConfig.options];\r\n\r\n let listSize: number;\r\n if (this.selectConfig.maxListSize) {\r\n listSize = this.selectConfig.maxListSize + (10 * this._showMoreClicked);\r\n listSize = listSize > this.selectConfig.options.length ? this.selectConfig.options.length : listSize;\r\n }\r\n\r\n if (searchValue) {\r\n const searchResult = (searchValue.length === 1)\r\n ? this._search.exact(options, searchValue)\r\n : this._search[this.selectConfig.searchType](options, searchValue);\r\n this.searchResultCount = searchResult.length;\r\n this.selectConfig.searchableOptions = (this.selectConfig.maxListSize) ? searchResult.slice(0, listSize) : searchResult;\r\n } else {\r\n this.searchResultCount = options.length;\r\n this.selectConfig.searchableOptions = (this.selectConfig.maxListSize) ? options.slice(0, listSize) : options;\r\n }\r\n\r\n this._changDetectorRef.detectChanges();\r\n\r\n // prevent event propagation\r\n return false;\r\n }\r\n\r\n /**\r\n * Emit selected option\r\n * @param option\r\n */\r\n optionSelected(option: any): boolean {\r\n this.selectConfig.selectedOptionChanged(option);\r\n\r\n this.closeDropdown();\r\n // prevent event propagation\r\n return false;\r\n }\r\n\r\n /**\r\n * Close the dropdown\r\n */\r\n closeDropdown(): void {\r\n this.closed.emit(this.selectConfig);\r\n this._timer.setTimeout(() => {\r\n this._resetSearch();\r\n }, 150);\r\n }\r\n\r\n /**\r\n * Show more if the list has a max limit to start\r\n */\r\n showMore(event: MouseEvent): boolean {\r\n event.stopPropagation();\r\n const currentShownOptions = this.selectConfig.searchableOptions.length;\r\n this._showMoreClicked++;\r\n\r\n if (this.selectConfig.isShowMoreFromParent) {\r\n this.selectConfig.showMoreClicked(this._showMoreClicked);\r\n } else {\r\n this.search();\r\n }\r\n\r\n // Create the space for the scrollbar if it is going to show up\r\n if (currentShownOptions < this.MAX_ROWS_BEFORE_SCROLLBAR && this.selectConfig.searchableOptions.length > this.MAX_ROWS_BEFORE_SCROLLBAR) {\r\n this.updateDropdownPosition();\r\n }\r\n // prevent event propagation\r\n return false;\r\n }\r\n\r\n /**\r\n * Reset the search\r\n */\r\n private _resetSearch(): void {\r\n this.searchValue = '';\r\n this.search();\r\n }\r\n\r\n /**\r\n * Flip the dropdown to the top\r\n */\r\n private _renderToTop(): void {\r\n this._prerender();\r\n\r\n const boundingBox = this.dropdown.nativeElement.getBoundingClientRect();\r\n\r\n const top = this._targetPosition.y + window.scrollY;\r\n const left = this._targetPosition.x - Math.floor((boundingBox.width - this._targetPosition.width) / 2);\r\n\r\n const buffer = this._getBuffer(boundingBox, top, left);\r\n\r\n this.dropdownPosition = {\r\n left: `${left + buffer.leftBuffer}px`,\r\n top: `${top + this._targetPosition.height}px`,\r\n width: this._scrollBarWidth(this._targetPosition.width)\r\n };\r\n\r\n this.renderedTop = true;\r\n this._changDetectorRef.detectChanges();\r\n }\r\n\r\n /**\r\n * Pre-render to calculate right edge detection accurately\r\n */\r\n private _prerender(): void {\r\n this.dropdownPosition = {\r\n left: `${window.innerWidth / 2 - 130}px`,\r\n top: '10px',\r\n width: this._scrollBarWidth(this._targetPosition.width)\r\n };\r\n this._changDetectorRef.detectChanges();\r\n }\r\n\r\n /**\r\n * Check distance to edge of screen\r\n * @param element\r\n * @param idealTop\r\n * @param idealLeft\r\n */\r\n private _getBuffer(element: DOMRect, idealTop: number, idealLeft: number): WindowBuffer {\r\n const wY = window.innerHeight;\r\n const wX = window.innerWidth;\r\n\r\n const closestXEdgeDistance = (idealLeft < (wX - (idealLeft + element.width))) ? idealLeft : (wX - (idealLeft + element.width));\r\n const closestYEdgeDistance = (idealTop < (wY - (idealTop + element.height))) ? idealTop : (wY - (idealTop + element.height));\r\n const isXAdditive = idealLeft < (wX - (idealLeft + element.width));\r\n const isYAdditive = idealTop < (wY - (idealTop + element.height));\r\n\r\n let xBuffer = 0;\r\n if (closestXEdgeDistance < this._edgeBuffer) {\r\n xBuffer = this._edgeBuffer - closestXEdgeDistance;\r\n xBuffer = (isXAdditive) ? xBuffer : -xBuffer;\r\n }\r\n let yBuffer = 0;\r\n if (closestYEdgeDistance < this._edgeBuffer) {\r\n yBuffer = this._edgeBuffer - closestYEdgeDistance;\r\n yBuffer = (isYAdditive) ? yBuffer : -yBuffer;\r\n }\r\n\r\n return {\r\n leftBuffer: xBuffer,\r\n topBuffer: yBuffer\r\n };\r\n }\r\n private _scrollBarWidth(width: number): string {\r\n if(width === 0) {\r\n return `${width}px`;\r\n }\r\n\r\n width += 3;\r\n\r\n // Add 15 for scrollbar\r\n return (this.selectConfig.searchableOptions.length > this.MAX_ROWS_BEFORE_SCROLLBAR) ? `${width + 15}px` : `${width}px`;\r\n }\r\n\r\n}\r\n","import { Injectable, ComponentFactoryResolver, Injector, ComponentRef, EmbeddedViewRef } from '@angular/core';\r\nimport { AceSelectDropdownComponent } from './Select-Dropdown/dropdown.component';\r\nimport { SelectConfig } from './select.interface';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\nimport { TimerService } from '../../Utilities';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class AceSelectService {\r\n constructor(\r\n private readonly _componentFactoryResolver: ComponentFactoryResolver,\r\n private readonly _injector: Injector,\r\n private readonly _timer: TimerService\r\n ) { }\r\n\r\n dropdownActive: boolean;\r\n dropdownOpen: boolean;\r\n\r\n private _dropdownRef: ComponentRef;\r\n private _dropdown: HTMLElement;\r\n\r\n private _currentDropdown: SelectConfig;\r\n\r\n private _targetBounds: DOMRect;\r\n private _closingInterval;\r\n private _destroy$: Subject = new Subject();\r\n\r\n /**\r\n * Open the dropdown\r\n * @param selectConfig\r\n * @param position\r\n */\r\n openDropdown(selectConfig: SelectConfig, position: DOMRect): void {\r\n if (this._currentDropdown) {\r\n this.closeDropdown(() => {\r\n this._currentDropdown = selectConfig;\r\n this._targetBounds = position;\r\n this._showDropdown();\r\n });\r\n } else {\r\n this._currentDropdown = selectConfig;\r\n this._targetBounds = position;\r\n this._showDropdown();\r\n }\r\n }\r\n\r\n /**\r\n * Close the dropdown\r\n * Timed to allow for fade-out animation\r\n * @param callback\r\n */\r\n closeDropdown(callback?: any): void {\r\n this._dropdownRef.instance.isOpen = false;\r\n this._destroy$.next();\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n\r\n if (this._closingInterval) {\r\n clearTimeout(this._closingInterval);\r\n }\r\n this._closingInterval = this._timer.setTimeout(() => {\r\n this.resetDropdown();\r\n if (callback) {\r\n callback();\r\n }\r\n this.dropdownOpen = false;\r\n this._closingInterval = null;\r\n }, 150);\r\n }\r\n\r\n /**\r\n * Update the position for scroll and resize events\r\n */\r\n updatePosition(selectConfig: SelectConfig, position: DOMRect): void {\r\n if (this._currentDropdown === selectConfig) {\r\n this._targetBounds = position;\r\n this._dropdownRef.instance.targetPosition = this._targetBounds;\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n }\r\n }\r\n\r\n /**\r\n * Update the list if the options change while it is open\r\n */\r\n optionsChanged(): void {\r\n if (this._dropdownRef) {\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n }\r\n }\r\n\r\n /**\r\n * Reset the dropdown component values\r\n */\r\n resetDropdown(): void {\r\n this._currentDropdown = null;\r\n this._dropdownRef.instance.targetPosition = {\r\n bottom: 0,\r\n top: 0,\r\n left: 0,\r\n right: 0,\r\n height: 0,\r\n width: 0,\r\n x: 260, // allows left pre-render for positioning calculations\r\n y: 0,\r\n toJSON: null\r\n };\r\n\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n }\r\n\r\n /**\r\n * Update the dropdown with new values\r\n */\r\n private _showDropdown(): void {\r\n if (!this.dropdownActive) {\r\n if (!this._dropdown) {\r\n this._createDropdown();\r\n }\r\n this.dropdownActive = true;\r\n document.body.appendChild(this._dropdown);\r\n }\r\n // Init blank component\r\n this._dropdownRef.instance.dropdownConfig = this._currentDropdown;\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n\r\n this._dropdownRef.instance.targetPosition = this._targetBounds;\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n\r\n this._dropdownRef.instance.isOpen = true;\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n this.dropdownOpen = true;\r\n\r\n this._dropdownRef.instance.closed\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe((config) => config === this._currentDropdown && this.closeDropdown());\r\n }\r\n\r\n /**\r\n * Create the dropdown DOM element\r\n */\r\n private _createDropdown(): void {\r\n const componentFactory = this._componentFactoryResolver.resolveComponentFactory(AceSelectDropdownComponent);\r\n this._dropdownRef = componentFactory.create(this._injector);\r\n\r\n this._dropdown = (this._dropdownRef.hostView as EmbeddedViewRef).rootNodes[0] as HTMLElement;\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n }\r\n}\r\n","
\r\n \r\n \r\n {{selectConfig.placeholder}}\r\n \r\n {{(selectConfig.isPrimitive) ? selectedOption : selectedOption[selectConfig.labelProperty]}}\r\n \r\n \r\n \r\n {{widestOption}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n","import {\r\n Component,\r\n ElementRef,\r\n EventEmitter,\r\n forwardRef,\r\n HostBinding,\r\n HostListener,\r\n Input,\r\n NgZone,\r\n OnChanges,\r\n OnDestroy,\r\n OnInit,\r\n Output,\r\n SimpleChanges,\r\n ViewChild,\r\n ViewEncapsulation\r\n} from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { SelectConfig, WsSelectValueFormatter } from './select.interface';\r\nimport { AceSelectService } from './select.service';\r\n\r\nexport enum KEY_CODE {\r\n UP_ARROW = 38,\r\n DOWN_ARROW = 40\r\n}\r\n\r\n/**\r\n * Select dropdown\r\n *\r\n * Allows the user to select multiple items from the dropdown and displays a summary of the selections\r\n *\r\n * Tied into ControlValueAccessor for integration with native Angular FormControls and ngModel\r\n *\r\n * The input options can be any model. The properties to use as the selectors for each option in the dropdown are set using\r\n * labelProperty and valueProperty. To have the whole object returned as the value set returnEntireOption to true. If it is an array\r\n * of primitive values, set isPrimitive to true and returnEntireOption to true.\r\n *\r\n * Example usage:\r\n * \r\n * \r\n *\r\n */\r\n@Component({\r\n selector: 'ws-ace-select',\r\n templateUrl: './select.component.html',\r\n styleUrls: ['./select.component.scss'],\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => AceSelectComponent),\r\n multi: true\r\n }\r\n ],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class AceSelectComponent implements ControlValueAccessor, OnInit, OnChanges, OnDestroy {\r\n constructor(\r\n private readonly _selectService: AceSelectService,\r\n private readonly _elementRef: ElementRef,\r\n private readonly _ngZone: NgZone\r\n ) { }\r\n\r\n @Input() placeholder: string;\r\n @Input() labelProperty: string;\r\n @Input() valueProperty: string;\r\n @Input() disabledProperty: string;\r\n @Input() returnEntireOption: boolean;\r\n @Input() isPrimitive: boolean;\r\n @Input() canSearch: boolean;\r\n @Input() canDeselect: boolean;\r\n @Input() deselectLabel: string;\r\n @Input() deselectValue: any;\r\n @Input() includeSearchAfterN: number;\r\n @Input() size: string;\r\n @Input() searchType: string;\r\n @Input() maxListSize: number;\r\n @Input() maxTextLength: number;\r\n @Input() isLoading: boolean;\r\n @Input() isShowMoreFromParent: boolean;\r\n @Input() alignOptionText: string;\r\n @Input() set tabindex(tabindex: number) { this.tabIndex = tabindex; }\r\n\r\n @Input()\r\n set valueFormatter(formatter: WsSelectValueFormatter) {\r\n this._formatter = formatter;\r\n this._setOptions(this._options);\r\n }\r\n\r\n @Input()\r\n set options(options: any[]) {\r\n if (!options) { return; }\r\n this._options = options;\r\n this._setOptions(options);\r\n }\r\n\r\n @Input() optionStyleClass: (optionValue: any) => string;\r\n @Input() customSearch: (values: any[], searchValue: string) => any[];\r\n\r\n // Output whole selected option\r\n @Output() selectedOptionChanged = new EventEmitter();\r\n // Output selected value only\r\n @Output() selectedValueChanged = new EventEmitter();\r\n\r\n @Output() showMoreClicked = new EventEmitter();\r\n\r\n @ViewChild('wsSelectDropdown', { static: true }) selectDropdown: ElementRef;\r\n\r\n @HostBinding('attr.tabindex') tabIndex = 0;\r\n\r\n value: any;\r\n disabled: boolean;\r\n widestOption: any;\r\n selectedOption: any;\r\n\r\n selectConfig: SelectConfig = {\r\n options: [],\r\n searchableOptions: [],\r\n selectedOption: null,\r\n placeholder: null,\r\n labelProperty: 'label',\r\n valueProperty: 'value',\r\n disabledProperty: 'disabled',\r\n returnEntireOption: false,\r\n isPrimitive: false,\r\n canSearch: true,\r\n canDeselect: false,\r\n deselectLabel: 'None',\r\n deselectValue: null,\r\n includeSearchAfterN: 10,\r\n size: 'md',\r\n tabindex: null,\r\n maxListSize: null,\r\n maxTextLength: 50,\r\n searchType: 'fuzzy',\r\n alignOptionText: 'left',\r\n isShowMoreFromParent: false,\r\n customSearch: null,\r\n optionStyleClass: null,\r\n selectedOptionChanged: (option) => this.optionSelected(option),\r\n showMoreClicked: (count: number) => this.showMoreClicked.emit(count)\r\n };\r\n\r\n private _options: any[] = [];\r\n private _formatter: WsSelectValueFormatter;\r\n\r\n @HostListener('window:resize') onResize(): void {\r\n this._selectService.updatePosition(this.selectConfig, this._elementRef.nativeElement.getBoundingClientRect());\r\n }\r\n\r\n @HostListener('keyup', ['$event'])\r\n keyEvent(event: KeyboardEvent) {\r\n if (event.keyCode === KEY_CODE.UP_ARROW) {\r\n this.keyPrevious();\r\n }\r\n if (event.keyCode === KEY_CODE.DOWN_ARROW) {\r\n this.keyNext();\r\n }\r\n event.stopPropagation();\r\n }\r\n\r\n get isOpen(): boolean {\r\n return this._selectService.dropdownOpen;\r\n }\r\n\r\n // Angular Form methods\r\n\r\n onChange: (val: any[]) => void;\r\n onTouched: () => void;\r\n\r\n writeValue(value: any): void {\r\n this.selectedOption = (this.returnEntireOption || this.selectConfig.isPrimitive)\r\n ? value : this._options.find(o => o[this.selectConfig.valueProperty] === value);\r\n if (this._formatter && this.selectConfig.options) {\r\n this.selectedOption = this.selectConfig.options.find(x => x[this.selectConfig.valueProperty] === value);\r\n }\r\n this.value = value;\r\n this.selectConfig.selectedOption = this.selectedOption;\r\n }\r\n\r\n setDisabledState(disabled: boolean): void {\r\n this.disabled = disabled;\r\n }\r\n\r\n next(): void {\r\n this.value = ((this.returnEntireOption && !this._formatter)\r\n || this.selectConfig.isPrimitive\r\n || (this.selectConfig.canDeselect && this.selectedOption === this.selectConfig.deselectValue))\r\n ? this.selectedOption\r\n : this.selectedOption[this.selectConfig.valueProperty];\r\n this.onChange(this.value);\r\n this.onTouched();\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouched = fn;\r\n }\r\n\r\n // Custom methods\r\n\r\n ngOnInit(): void {\r\n this._ngZone.runOutsideAngular(() => {\r\n window.addEventListener('scroll', this._scroll, true);\r\n });\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n Object.keys(changes).forEach(key => {\r\n this.selectConfig[key] = changes[key].currentValue;\r\n if (key === 'options') {\r\n this._setOptions(this._options);\r\n }\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n window.removeEventListener('scroll', this._scroll, true);\r\n if (this.isOpen) {\r\n this._selectService.closeDropdown();\r\n }\r\n }\r\n\r\n optionSelected(option: any): boolean {\r\n if (this.disabled || (option && option[this.selectConfig.disabledProperty])) {\r\n return false;\r\n }\r\n\r\n if (this.selectedOption !== option) {\r\n this.selectedOption = option;\r\n this.selectConfig.selectedOption = option;\r\n }\r\n\r\n this.next();\r\n this.selectedOptionChanged.emit(this.selectedOption);\r\n this.selectedValueChanged.emit(this.value);\r\n // prevent event propagation\r\n return false;\r\n }\r\n\r\n openDropdown(event): boolean {\r\n if (this.disabled || !this.selectConfig.searchableOptions.length) {\r\n return false;\r\n }\r\n\r\n this._selectService.openDropdown(this.selectConfig, this._elementRef.nativeElement.getBoundingClientRect());\r\n\r\n event.stopPropagation();\r\n // prevent event propagation\r\n return false;\r\n }\r\n\r\n keyPrevious(): void {\r\n if (!this.selectedOption) {\r\n return;\r\n }\r\n const index = this.selectConfig.searchableOptions.indexOf(this.selectedOption);\r\n if (index > 0) {\r\n this.optionSelected(this.selectConfig.searchableOptions[index - 1]);\r\n }\r\n }\r\n\r\n keyNext(): void {\r\n if (!this.selectedOption) {\r\n this.optionSelected(this.selectConfig.searchableOptions[0]);\r\n return;\r\n }\r\n const index = this.selectConfig.searchableOptions.indexOf(this.selectedOption);\r\n if (index !== -1 && index < (this.selectConfig.searchableOptions.length - 1)) {\r\n this.optionSelected(this.selectConfig.searchableOptions[index + 1]);\r\n }\r\n }\r\n\r\n private _scroll = () => this._selectService.updatePosition(this.selectConfig, this._elementRef.nativeElement.getBoundingClientRect());\r\n\r\n private _setOptions(options: any[]): void {\r\n if (options && options.length) {\r\n const dropdownOptions = this._applyValueFormatter(options);\r\n this.widestOption = dropdownOptions.reduce((acc, o) => {\r\n const value = (this.selectConfig.isPrimitive) ? o : o[this.selectConfig.labelProperty];\r\n return (value && value.length > acc.length) ? value : acc;\r\n }, '');\r\n this.widestOption = (this.selectConfig.placeholder && this.selectConfig.placeholder.length > this.widestOption.length)\r\n ? this.selectConfig.placeholder\r\n : this.widestOption;\r\n this.widestOption = (this.selectConfig.deselectLabel && this.selectConfig.deselectLabel.length > this.widestOption.length)\r\n ? this.selectConfig.deselectLabel\r\n : this.widestOption;\r\n this.selectConfig.options = dropdownOptions;\r\n this.selectConfig.searchableOptions = [...dropdownOptions];\r\n if (this.value !== undefined) {\r\n this.writeValue(this.value);\r\n }\r\n this._selectService.optionsChanged();\r\n }\r\n }\r\n\r\n private _applyValueFormatter(options: any[]): any[] {\r\n if (!this._formatter || this.selectConfig.isPrimitive) {\r\n return options;\r\n }\r\n return options\r\n .map(this._formatter)\r\n .map((o, i) => {\r\n const option = options[i];\r\n return {\r\n [this.selectConfig.labelProperty]: o,\r\n [this.selectConfig.valueProperty]: (this.returnEntireOption) ? option : option[this.selectConfig.valueProperty]\r\n };\r\n });\r\n }\r\n\r\n}\r\n","import { Observable, Subject } from 'rxjs';\r\nimport { AmplitudeEvent } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { SearchCategoryType } from './userSave.service';\r\n\r\nexport interface SaveListItem {\r\n id: number;\r\n name: string;\r\n isFavorite?: boolean;\r\n canFavorite?: boolean;\r\n variantName?: string;\r\n changeDate?: Date;\r\n\r\n originalModel: T;\r\n amplitudeEvent?: AmplitudeEvent;\r\n\r\n // isSystemSeeded?: boolean;\r\n // sequence?: number;\r\n // categoryId?: number;\r\n // defaultDisplay?: number;\r\n // instanceID?: number;\r\n // isDisabled?: boolean;\r\n // isRyanInternal?: boolean;\r\n // isSystemSearch?: boolean;\r\n // reportTypeId?: number;\r\n // rowVersion?: number[];\r\n // thatAreChoice?: number;\r\n}\r\n\r\nexport interface SaveCategory {\r\n categoryId: number;\r\n categoryName: string;\r\n categoryType: number;\r\n savedItemList: SaveListItem[];\r\n}\r\n\r\nexport enum SaveTabColumnType {\r\n String,\r\n Date\r\n}\r\n\r\nexport interface SaveTabColumn {\r\n name: string;\r\n key: string;\r\n type: SaveTabColumnType\r\n}\r\n\r\nexport interface ContextMenuItem {\r\n name: string;\r\n onClick: (item: SaveListItem, searchType: Core.SearchCategoryType) => void;\r\n isDisabled: (item: SaveListItem) => boolean;\r\n}\r\n\r\nexport abstract class UserSavePage {\r\n public user: SaveCategory[] = [];\r\n public system: SaveCategory[] = [];\r\n public favorite: SaveCategory[] = [];\r\n\r\n protected _columns: SaveTabColumn[];\r\n protected _currentSelectedFilter: SearchCategoryType = SearchCategoryType.System;\r\n protected _dirty: boolean = true;\r\n\r\n private _currentSelectedCategory: SaveCategory;\r\n\r\n get columns(): SaveTabColumn[] {\r\n return this._columns;\r\n }\r\n\r\n get categories(): SaveCategory[] {\r\n return this[this._currentSelectedFilter];\r\n }\r\n\r\n get currentSelectedFilter(): SearchCategoryType {\r\n return this._currentSelectedFilter || SearchCategoryType.System;\r\n }\r\n\r\n set currentSelectedFilter(filter: SearchCategoryType) {\r\n this._currentSelectedFilter = filter;\r\n }\r\n\r\n get currentSelectedCategory(): SaveCategory {\r\n return this._currentSelectedCategory;\r\n }\r\n\r\n set currentSelectedCategory(category: SaveCategory) {\r\n this._currentSelectedCategory = category;\r\n }\r\n\r\n set dirty(isDirty: boolean) {\r\n this._dirty = isDirty;\r\n }\r\n\r\n abstract get tabTitle(): string;\r\n abstract getList(): Promise;\r\n abstract navigateTo(listItem: SaveListItem, categoryType: number): void;\r\n abstract contextMenu(category: SaveCategory, index: number): ContextMenuItem[];\r\n abstract toggleFavorite(search: SaveListItem): Promise;\r\n\r\n refreshLocalList(): void {\r\n this.user = structuredClone(this.user);\r\n this.system = structuredClone(this.system);\r\n this.favorite = structuredClone(this.favorite);\r\n }\r\n\r\n protected _separateByCategoryType(categoryList: SaveCategory[]): void {\r\n const userCategories = categoryList\r\n .filter(x => {\r\n return x.categoryId !== null && x.categoryType === Core.SearchCategoryType.Custom;\r\n })\r\n .sort((a, b) => a.categoryName.localeCompare(b.categoryName));\r\n\r\n const uncategorizedUserSearches = categoryList\r\n .filter(x => {\r\n return x.categoryId === null && x.categoryType === Core.SearchCategoryType.Custom;\r\n });\r\n\r\n const systemCategories = categoryList\r\n .filter(x => {\r\n return x.categoryId !== null && x.categoryType === Core.SearchCategoryType.System;\r\n })\r\n .sort((a, b) => a.categoryName.localeCompare(b.categoryName));\r\n\r\n const uncategorizedSystemSearches = categoryList\r\n .filter(x => {\r\n return x.categoryId === null && x.categoryType === Core.SearchCategoryType.System;\r\n });\r\n\r\n const favoriteSearches = categoryList\r\n .reduce((acc, x) => {\r\n const favoriteList = x.savedItemList.filter(y => y.isFavorite === true);\r\n if (favoriteList.length > 0) {\r\n acc.push({ ...x, savedItemList: favoriteList });\r\n }\r\n return acc;\r\n }, []);\r\n\r\n this.user = [ ...userCategories, ...uncategorizedUserSearches ];\r\n this.system = [...systemCategories, ...uncategorizedSystemSearches];\r\n this.favorite = this._formatFavorites(favoriteSearches);\r\n this._dirty = false;\r\n }\r\n\r\n protected _showEmailWindow(route: string, itemName: string, itemType: string): void {\r\n const subject = `Shared ${ itemType }`;\r\n\r\n const url = route;\r\n // // Get rid of leading #\r\n // if (url[0] === '#') {\r\n // url = url.substring(1);\r\n // }\r\n //\r\n // url = this._location.url(url).absUrl();\r\n\r\n const body = encodeURIComponent(\r\n 'Hello.\\r\\n\\r\\n' +\r\n `Click on the link below to access the ${ itemType } \"${ itemName }\" which has been shared with you in PropertyPoint.\\r\\n\\r\\n` +\r\n `You may run it directly or, after opening it, save it as one of your own ${ itemType }s by clicking Save As.\\r\\n\\r\\n${\r\n url }\\r\\n\\r\\n`\r\n );\r\n\r\n window.open('mailto:' + '' + `?subject=${ subject }&body=${ body }`, '_self');\r\n }\r\n\r\n private _formatFavorites(searches: SaveCategory[]): SaveCategory[] {\r\n return [\r\n {\r\n categoryId: 0,\r\n categoryName: 'System Favorites',\r\n categoryType: Core.SearchCategoryType.System,\r\n savedItemList: searches.reduce((acc, x) => {\r\n if (x.categoryType === Core.SearchCategoryType.System) {\r\n return [ ...acc, ...x.savedItemList ];\r\n }\r\n return acc;\r\n }, [])\r\n },\r\n {\r\n categoryId: 1,\r\n categoryName: 'User Favorites',\r\n categoryType: Core.SearchCategoryType.Custom,\r\n savedItemList: searches.reduce((acc, x) => {\r\n if (x.categoryType === Core.SearchCategoryType.Custom) {\r\n return [ ...acc, ...x.savedItemList ];\r\n }\r\n return acc;\r\n }, [])\r\n }\r\n ];\r\n }\r\n}\r\n","\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { SavedSearchCategoryEnum } from '../../../../constants.new';\r\nimport { ReportManagerService } from '../../../../Reporting/Manager/report.manager.service';\r\nimport { UserSaveService } from '../../userSave.service';\r\n\r\nexport interface ReportCategoryModalParams {\r\n report: Core.ReportListDTO;\r\n reportType: Core.SearchCategoryType;\r\n}\r\n\r\n@Component({\r\n selector: 'report-category',\r\n templateUrl: './navChangeCategory.component.html'\r\n})\r\nexport class ReportCategoryComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(private readonly _reportManagerService: ReportManagerService,\r\n private readonly _userSaveService: UserSaveService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: ReportCategoryModalParams;\r\n result: void;\r\n\r\n modalTitle: string;\r\n report: Core.ReportListDTO;\r\n reportType: Core.SearchCategoryType;\r\n categories: any[] = [];\r\n selectedCategory: any;\r\n newCategory: string;\r\n creatingNewCategory = false;\r\n\r\n async ngOnInit(): Promise {\r\n this.report = this.params.report;\r\n this.reportType = this.params.reportType;\r\n this.modalTitle = `Change \"${this.report.reportName}\" View's Category`;\r\n\r\n const results = await this._reportManagerService.getReportCategories();\r\n\r\n if (results && results.length) {\r\n this.categories = results.filter(item => {\r\n return item.categoryType === this.reportType && (item.categoryId != SavedSearchCategoryEnum.ComplianceReport &&\r\n item.categoryId != SavedSearchCategoryEnum.ComplianceReturnReport &&\r\n item.categoryId != SavedSearchCategoryEnum.CompliancePackageReport &&\r\n item.categoryId != SavedSearchCategoryEnum.ComplianceCustomReport);\r\n });\r\n this.selectedCategory = this.categories.find(x => x.categoryId === this.report.categoryId) || this.categories[0];\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n //Create new category first, then update view\r\n if (this.selectedCategory.categoryId === -1) {\r\n const category = { ...this.selectedCategory };\r\n delete category.categoryId;\r\n\r\n const result = await this._reportManagerService.createCategory(category.categoryName, this.reportType === Core.SearchCategoryType.System);\r\n\r\n this.report.categoryId = result.categoryId;\r\n this.selectedCategory.categoryId = result.categoryId;\r\n }\r\n\r\n await this._reportManagerService.changeCategory(this.reportType, this.report, this.selectedCategory.categoryId);\r\n await this._userSaveService.refreshCurrentList();\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n createNewCategory(): void {\r\n if (!this.newCategory) {\r\n this.creatingNewCategory = false;\r\n return;\r\n }\r\n\r\n let category;\r\n if (this.categories.some(x => x.categoryId === -1)) {\r\n category = this.categories.find(x => x.categoryId === -1);\r\n category.categoryName = this.newCategory;\r\n category.categoryType = this.reportType;\r\n } else {\r\n category = {\r\n categoryName: this.newCategory,\r\n categoryType: this.reportType,\r\n categoryId: -1\r\n };\r\n this.categories.push(category);\r\n }\r\n\r\n this.selectedCategory = category;\r\n this.report.categoryId = -1;\r\n this.creatingNewCategory = false;\r\n this.newCategory = '';\r\n }\r\n\r\n cancelCreateCategory(): void {\r\n this.creatingNewCategory = false;\r\n this.newCategory = '';\r\n }\r\n}\r\n","\r\n \r\n
\r\n {{report.reportName}} -\r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { ReportManagerService } from '../../../../Reporting/Manager/report.manager.service';\r\nimport { UserSaveService } from '../../userSave.service';\r\n\r\nexport interface reportRenameModalParams {\r\n report: Core.ReportListDTO;\r\n reportType: Core.SearchCategoryType;\r\n}\r\n\r\n@Component({\r\n selector: 'report-rename',\r\n templateUrl: './reportRename.component.html'\r\n})\r\nexport class ReportRenameComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(private readonly _reportManagerService: ReportManagerService,\r\n private readonly _userSaveService: UserSaveService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: reportRenameModalParams;\r\n result: void;\r\n\r\n modalTitle: string;\r\n report: Core.ReportListDTO;\r\n reportType: Core.SearchCategoryType;\r\n\r\n ngOnInit(): void {\r\n this.report = this.params.report;\r\n this.reportType = this.params.reportType;\r\n const variant = this.report.variantName ? ` - ${this.report.variantName}` : '';\r\n this.modalTitle = `Rename \"${this.report.reportName}${variant}\" report`;\r\n }\r\n\r\n async save() {\r\n await this._reportManagerService.patchReport(this.report, this.reportType);\r\n await this._userSaveService.refreshCurrentList();\r\n this.cancel();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { UIRouter } from '@uirouter/angular';\r\nimport { AmplitudeEvent } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { ReportManagerService } from '../../Reporting/Manager/report.manager.service';\r\nimport { AdvancedSearchPersistenceService } from '../../Search/Advanced/advancedSearchPersistence.service';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { ReportCategoryComponent } from '../User-Save/Modals/Category/reportCategory.component';\r\nimport { ReportRenameComponent } from '../User-Save/Modals/Rename/reportRename.component';\r\nimport {\r\n ContextMenuItem,\r\n SaveCategory,\r\n SaveListItem,\r\n SaveTabColumn, SaveTabColumnType,\r\n UserSavePage\r\n} from '../User-Save/userSavePage.model';\r\n\r\nexport class SavedReportService extends UserSavePage {\r\n constructor(private readonly _reportService: ReportManagerService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _router: UIRouter,\r\n private readonly _restrictService: RestrictService) {\r\n super();\r\n }\r\n\r\n protected _columns: SaveTabColumn[] = [\r\n {\r\n name: 'Name',\r\n key: 'name',\r\n type: SaveTabColumnType.String\r\n },\r\n {\r\n name: 'Variant',\r\n key: 'variantName',\r\n type: SaveTabColumnType.String\r\n },\r\n {\r\n name: 'Change Date',\r\n key: 'changeDate',\r\n type: SaveTabColumnType.Date\r\n }\r\n ];\r\n\r\n private _baseValues: Core.SavedReportCategoryManagementDTO[] = [];\r\n\r\n get tabTitle(): string {\r\n return 'Saved Reports';\r\n }\r\n\r\n contextMenu(category: SaveCategory, index: number): ContextMenuItem[] {\r\n return category.categoryType === Core.SearchCategoryType.System\r\n ? this._systemReportMenuWithPermissions(category, index) : this._customReportContextMenu(category, index);\r\n }\r\n\r\n async getList(): Promise {\r\n if (!this._dirty) {\r\n return;\r\n }\r\n this._baseValues = await this._reportService.getReportCategories();\r\n\r\n let categoryList: SaveCategory[] = this._baseValues.map(x => {\r\n const list: SaveListItem[] = x.reportList.map(y => {\r\n return {\r\n id: y.reportID,\r\n name: y.reportName,\r\n variantName: y.variantName,\r\n changeDate: y.changeDate,\r\n canFavorite: false,\r\n originalModel: y,\r\n amplitudeEvent: this._getAmplitudeEvent(x, y)\r\n };\r\n });\r\n return {\r\n categoryId: x.categoryId,\r\n categoryName: x.categoryName,\r\n categoryType: x.categoryType,\r\n savedItemList: list\r\n };\r\n });\r\n\r\n categoryList = categoryList.filter(x => x.categoryId !== Core.SavedSearchCategoryEnum.ComplianceReturnReport\r\n && x.categoryId !== Core.SavedSearchCategoryEnum.CompliancePackageReport\r\n && x.categoryId !== Core.SavedSearchCategoryEnum.ComplianceCustomReport);\r\n\r\n this._separateByCategoryType(categoryList);\r\n }\r\n\r\n navigateTo(listItem: SaveListItem, categoryType: number): void {\r\n const params = {\r\n reportId: listItem.id,\r\n reportType: categoryType\r\n };\r\n this._router.stateService.transitionTo('reportmanager', params);\r\n }\r\n\r\n async toggleFavorite(search: SaveListItem): Promise {\r\n // Do nothing\r\n }\r\n\r\n private async _shareReport(reportItem: SaveListItem, searchType: Core.SearchCategoryType): Promise {\r\n // Go update the search to mark it as \"Shared\" if this is a custom search\r\n if (searchType === Core.SearchCategoryType.Custom) {\r\n await this._reportService.share(reportItem.originalModel);\r\n }\r\n await this.getList();\r\n this._advancedSearchPersistenceService.clearSearchData();\r\n const params = {\r\n reportId: reportItem.id,\r\n reportType: searchType\r\n };\r\n const route = this._router.stateService.href('reportmanager', params, { absolute: true });\r\n const name = reportItem.variantName ? `${reportItem.name} - ${reportItem.variantName}` : reportItem.name;\r\n this._showEmailWindow(route, name, 'Report');\r\n }\r\n\r\n private _systemReportMenuWithPermissions(category: SaveCategory, index: number): ContextMenuItem[] {\r\n if (!this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT)) {\r\n return [];\r\n }\r\n return [\r\n {\r\n name: 'Share',\r\n onClick: (item, searchType) => {\r\n this._shareReport(item, searchType);\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.categoryId === Core.SavedSearchCategoryEnum.ComplianceReportSetup;\r\n }\r\n },\r\n {\r\n name: 'Rename',\r\n onClick: (item, reportType) => {\r\n this._modalService.showAsync(ReportRenameComponent, { report: item.originalModel, reportType }, 'modal-lg');\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.isSystemSeeded;\r\n }\r\n },\r\n {\r\n name: 'Change Category',\r\n onClick: (item, reportType) => {\r\n this._modalService.showAsync(ReportCategoryComponent, { report: item.originalModel, reportType }, 'modal-lg');\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.isSystemSeeded\r\n || category.categoryId === Core.SavedSearchCategoryEnum.ComplianceReportSetup;\r\n }\r\n },\r\n {\r\n name: 'Delete',\r\n onClick: async(item) => {\r\n try {\r\n let currentName = item.name;\r\n if (item.variantName) {\r\n currentName += ` - ${ item.variantName}`;\r\n }\r\n await this._messageModalService.confirm(`Are you sure you want to delete ${ currentName }?`);\r\n } catch(e) {\r\n return;\r\n }\r\n this.dirty = true;\r\n await this._reportService.deleteReport(item.originalModel, Core.SearchCategoryType.Custom);\r\n category.savedItemList.splice(index, 1);\r\n await this.getList();\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.isSystemSeeded;\r\n }\r\n }\r\n ];\r\n }\r\n\r\n private _customReportContextMenu(category: SaveCategory, index: number): ContextMenuItem[] {\r\n return [\r\n {\r\n name: 'Share',\r\n onClick: (item, searchType) => {\r\n this._shareReport(item, searchType);\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.categoryId === Core.SavedSearchCategoryEnum.ComplianceReportSetup;\r\n }\r\n },\r\n {\r\n name: 'Rename',\r\n onClick: (item, reportType) => {\r\n this._modalService.showAsync(ReportRenameComponent, { report: item.originalModel, reportType }, 'modal-lg');\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.isSystemSeeded;\r\n }\r\n },\r\n {\r\n name: 'Change Category',\r\n onClick: (item, reportType) => {\r\n this._modalService.showAsync(ReportCategoryComponent, { report: item.originalModel, reportType }, 'modal-lg');\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.isSystemSeeded\r\n || category.categoryId === Core.SavedSearchCategoryEnum.ComplianceReportSetup;\r\n }\r\n },\r\n {\r\n name: 'Delete',\r\n onClick: async(item) => {\r\n try {\r\n let currentName = item.name;\r\n if (item.variantName) {\r\n currentName += ` - ${ item.variantName}`;\r\n }\r\n await this._messageModalService.confirm(`Are you sure you want to delete ${ currentName }?`);\r\n } catch(e) {\r\n return;\r\n }\r\n this.dirty = true;\r\n await this._reportService.deleteReport(item.originalModel, Core.SearchCategoryType.Custom);\r\n category.savedItemList.splice(index, 1);\r\n await this.getList();\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.isSystemSeeded;\r\n }\r\n }\r\n ];\r\n }\r\n\r\n private _getAmplitudeEvent(category: Core.SavedReportCategoryManagementDTO, report: Core.ReportListDTO): AmplitudeEvent {\r\n let categoryType = category.categoryType ? 'saved' : 'system';\r\n if (category.categoryId === Core.SavedSearchCategoryEnum.ComplianceReportSetup) {\r\n categoryType = 'compliance';\r\n }\r\n const event = `click-report-${categoryType}`;\r\n let properties: { [key: string]: string };\r\n if (category.categoryId === Core.SavedSearchCategoryEnum.ComplianceReportSetup) {\r\n properties = { actComplianceReport: report.reportName };\r\n } else if (category.categoryType === Core.SearchCategoryType.System) {\r\n properties = { actSystemReport: report.reportName };\r\n }\r\n return { event, properties };\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, Subject } from 'rxjs';\r\nimport { DisplayName } from '../searchOperators.service';\r\nimport * as _ from 'lodash';\r\n\r\ntype Omit = Pick>;\r\n\r\nexport interface AdvancedSearchRouteParams {\r\n searchId?: number;\r\n searchType?: string;\r\n filters?: any;\r\n}\r\n\r\nexport interface AdvancedSearchResults extends Omit {\r\n payloadCriteria: AdvancedSearchCriteria;\r\n dataTable: any[];\r\n}\r\n\r\nexport interface SearchOutputColumns {\r\n [key: string]: any;\r\n}\r\n\r\nexport interface SearchOr extends Omit {\r\n operator: DisplayName;\r\n}\r\n\r\nexport interface SearchFilters extends Omit, Core.AdvancedSearchField {\r\n categoryID: number;\r\n or: SearchOr[];\r\n}\r\n\r\nexport interface AdvancedSearchCriteria extends Omit {\r\n categoryId?: number;\r\n defaultDisplay?: number;\r\n filters: SearchFilters[];\r\n groupByBatches: boolean;\r\n outputColumns: SearchOutputColumns[];\r\n outputInt?: number;\r\n rowVersion?: number;\r\n savedSearchID?: string;\r\n}\r\n\r\nexport interface SavedSearchModel extends Omit, Omit {\r\n searchCriteria: AdvancedSearchCriteria;\r\n type: number;\r\n rowVersion: number;\r\n}\r\n\r\nexport interface RevokeShareModel extends Omit {\r\n searchCriteria: AdvancedSearchCriteria;\r\n rowVersion: number;\r\n}\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class AdvancedSearchPersistenceService {\r\n\r\n routeParams: AdvancedSearchRouteParams = {};\r\n results: AdvancedSearchResults;\r\n selectedResult = {};\r\n sort = null;\r\n searchType = null;\r\n showPageTitle: boolean = true;\r\n fromWidget: boolean = false;\r\n hiddenColumns = [];\r\n reloadingSearch: boolean = false;\r\n columnsExpanded: boolean = false;\r\n\r\n private _updateAdvancedSearchSubject: Subject = new Subject();\r\n private _deleteAdvancedSearchSubject: Subject = new Subject();\r\n private _advancedSearchSubject: Subject = new Subject();\r\n private _isSearchingSubject: Subject = new Subject();\r\n private _showCriteriaSubject: BehaviorSubject = new BehaviorSubject(true);\r\n\r\n private _updateAdvancedSearch$: Observable = this._updateAdvancedSearchSubject.asObservable();\r\n private _deleteAdvancedSearch$: Observable = this._deleteAdvancedSearchSubject.asObservable();\r\n private _advancedSearch$: Observable = this._advancedSearchSubject.asObservable();\r\n private _isSearching$: Observable = this._isSearchingSubject.asObservable();\r\n private _showCriteria$: Observable = this._showCriteriaSubject.asObservable();\r\n\r\n private _search: SavedSearchModel;\r\n private _scrollLocationIndex: number;\r\n private _loadedSearchCriteriaCache: AdvancedSearchCriteria;\r\n\r\n get updateAdvancedSearch$() { return this._updateAdvancedSearch$; }\r\n get deleteAdvancedSearch$() { return this._deleteAdvancedSearch$; }\r\n get advancedSearch$() { return this._advancedSearch$; }\r\n get isSearching$() { return this._isSearching$; }\r\n get showCriteria$() { return this._showCriteria$; }\r\n\r\n set search(search: SavedSearchModel) {\r\n this._search = search;\r\n }\r\n\r\n get search(): SavedSearchModel {\r\n return this._search;\r\n }\r\n\r\n set scrollLocationIndex(index: number) {\r\n this._scrollLocationIndex = index;\r\n }\r\n\r\n get scrollLocationIndex(): number {\r\n return this._scrollLocationIndex;\r\n }\r\n\r\n set loadedSearchCriteriaCache(cache: AdvancedSearchCriteria) {\r\n this._loadedSearchCriteriaCache = cache;\r\n }\r\n\r\n updateAdvancedSearch(): void {\r\n this._updateAdvancedSearchSubject.next(undefined);\r\n }\r\n\r\n deleteAdvancedSearch(savedSearch: Core.AdvancedSearchList): void {\r\n this._deleteAdvancedSearchSubject.next(savedSearch);\r\n }\r\n\r\n setIsSearching(searching: boolean): void {\r\n this._isSearchingSubject.next(searching);\r\n }\r\n\r\n showCriteria(show: boolean): void {\r\n this._showCriteriaSubject.next(show);\r\n }\r\n\r\n clearSearchData(): void {\r\n this.routeParams = {};\r\n this.search = null;\r\n this.results = null;\r\n this.selectedResult = {};\r\n this.searchType = null;\r\n this.showPageTitle = true;\r\n this.fromWidget = false;\r\n this.hiddenColumns = [];\r\n this.reloadingSearch = false;\r\n this.columnsExpanded = false;\r\n this._loadedSearchCriteriaCache = null;\r\n this.setIsSearching(false);\r\n this.showCriteria(true);\r\n }\r\n\r\n setSearchCriteria(searchCriteria: AdvancedSearchCriteria) {\r\n if (!this.search) {\r\n this.search = {} as SavedSearchModel;\r\n }\r\n this.search['searchCriteria'] = searchCriteria;\r\n this._advancedSearchSubject.next(this.search);\r\n }\r\n\r\n resetSearchCriteria(): void {\r\n if (this._loadedSearchCriteriaCache) {\r\n this.setSearchCriteria(_.cloneDeep(this._loadedSearchCriteriaCache));\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nexport interface Wildcard {\r\n wildcard: { [key: string]: string };\r\n}\r\n\r\nexport interface Range {\r\n range: { [key: string]: { [key: string]: string } };\r\n}\r\n\r\nexport interface NotOperator {\r\n bool: {\r\n must_not: Wildcard[]\r\n };\r\n}\r\n\r\nexport interface SearchOperatorOr {\r\n value: string;\r\n operator: SearchOperator;\r\n}\r\n\r\nexport interface SearchOperator {\r\n id: number;\r\n name: string;\r\n type: string;\r\n should: (field: string, text: string) => any;\r\n}\r\n\r\nexport interface DisplayName {\r\n displayName: string;\r\n sortOrder: number;\r\n name?: string;\r\n}\r\n\r\ninterface DisplayNames {\r\n [key: string]: DisplayName;\r\n}\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class SearchOperatorsService {\r\n constructor() {\r\n this._operators = this._initializeOperators();\r\n }\r\n\r\n private _operators: SearchOperator[];\r\n\r\n getOperatorArray(keys: string[]): DisplayName[] {\r\n const map = this.displayNameMap();\r\n\r\n return keys.map((key) => {\r\n return {...map[key], ...{ name: key }};\r\n });\r\n }\r\n\r\n getOr(filterOperators): SearchOperatorOr {\r\n const operator = filterOperators.find(x => x.name === 'beginsWith') || _.minBy(filterOperators, 'sortOrder');\r\n\r\n return {\r\n value: '',\r\n operator: operator\r\n };\r\n }\r\n\r\n getCompanyOr(filterOperators): SearchOperatorOr {\r\n const operator = filterOperators.find(x => x.name === 'equals') || _.minBy(filterOperators, 'sortOrder');\r\n\r\n return {\r\n value: '',\r\n operator: operator\r\n };\r\n }\r\n\r\n getById(id: number): SearchOperator {\r\n return this._operators.find(x => x.id === id);\r\n }\r\n\r\n getByFilter(filter): SearchOperator[] {\r\n if (!filter) {\r\n return;\r\n }\r\n\r\n let filterOps = this._operators.filter(x => x.type === 'all');\r\n\r\n if (filter.nullable) {\r\n filterOps = _.union(filterOps, this._operators.filter(x => x.type === 'nullable'));\r\n }\r\n\r\n if (filter.numeric) {\r\n filterOps = _.union(filterOps, this._operators.filter(x => x.type === 'numeric'));\r\n } else {\r\n filterOps = _.union(filterOps, this._operators.filter(x => x.type === 'alpha'));\r\n }\r\n\r\n return filterOps;\r\n }\r\n\r\n displayNameMap(): DisplayNames {\r\n return {\r\n equal: {\r\n displayName: 'Equals',\r\n sortOrder: 1\r\n },\r\n notEqual: {\r\n displayName: 'Does Not Equal',\r\n sortOrder: 2\r\n },\r\n contains: {\r\n displayName: 'Contains',\r\n sortOrder: 3\r\n },\r\n doesNotContain: {\r\n displayName: 'Does Not Contain',\r\n sortOrder: 4\r\n },\r\n beginsWith: {\r\n displayName: 'Begins With',\r\n sortOrder: 5\r\n },\r\n endsWith: {\r\n displayName: 'Ends With',\r\n sortOrder: 6\r\n },\r\n blank: {\r\n displayName: 'Is Blank',\r\n sortOrder: 7\r\n },\r\n notBlank: {\r\n displayName: 'Is Not Blank',\r\n sortOrder: 8\r\n },\r\n lessThan: {\r\n displayName: 'Is Less Than',\r\n sortOrder: 9\r\n },\r\n greaterThan: {\r\n displayName: 'Is Greater Than',\r\n sortOrder: 10\r\n },\r\n lessThanEqual: {\r\n displayName: 'Less Than Equal',\r\n sortOrder: 11\r\n },\r\n greaterThanEqual: {\r\n displayName: 'Greater Than Equal',\r\n sortOrder: 12\r\n },\r\n nullable: {\r\n displayName: 'Nullable',\r\n sortOrder: 13\r\n },\r\n isNA: {\r\n displayName: 'Is N/A',\r\n sortOrder: 14\r\n },\r\n withinDate: {\r\n displayName: 'Is Within',\r\n sortOrder: 15\r\n }\r\n };\r\n }\r\n\r\n private _initializeOperators(): SearchOperator[] {\r\n return [\r\n {\r\n id: 0,\r\n name: 'Equals',\r\n type: 'all',\r\n should: this._createWildcard\r\n },\r\n {\r\n id: 1,\r\n name: 'Does Not Equal',\r\n type: 'all',\r\n should: (field: string, text: string) => {\r\n return this._makeNot(this._createWildcard(field, text));\r\n }\r\n },\r\n {\r\n id: 2,\r\n name: 'Is Blank',\r\n type: 'nullable',\r\n should: (field: string, text: string) => {\r\n return this._createWildcard(field, '');\r\n }\r\n },\r\n {\r\n id: 3,\r\n name: 'Is Not Blank',\r\n type: 'nullable',\r\n should: (field: string, text: string) => {\r\n return this._makeNot(this._createWildcard(field, ''));\r\n }\r\n },\r\n {\r\n id: 4,\r\n name: 'Is N/A',\r\n type: 'nullable',\r\n should: (field: string, text: string) => {\r\n return this._createWildcard(field, '');\r\n }\r\n },\r\n {\r\n id: 5,\r\n name: 'Within Date',\r\n type: 'numeric',\r\n should: (field: string, text: string) => {\r\n return this._createRange(field, text, 'gt');\r\n }\r\n },\r\n {\r\n id: 6,\r\n name: 'Contains',\r\n type: 'alpha',\r\n should: (field: string, text: string) => {\r\n return this._createWildcard(field, `*${ text }*`);\r\n }\r\n },\r\n {\r\n id: 7,\r\n name: 'Does Not Contain',\r\n type: 'alpha',\r\n should: (field: string, text: string) => {\r\n return this._makeNot(this._createWildcard(field, `*${ text }*`));\r\n }\r\n },\r\n {\r\n id: 8,\r\n name: 'Begins With',\r\n type: 'alpha',\r\n should: (field: string, text: string) => {\r\n return this._createWildcard(field, `${text }*`);\r\n }\r\n },\r\n {\r\n id: 9,\r\n name: 'Ends With',\r\n type: 'alpha',\r\n should: (field: string, text: string) => {\r\n return this._createWildcard(field, `*${ text}`);\r\n }\r\n },\r\n {\r\n id: 10,\r\n name: '>',\r\n type: 'numeric',\r\n should: (field: string, text: string) => {\r\n return this._createRange(field, text, 'gt');\r\n }\r\n },\r\n {\r\n id: 11,\r\n name: '>=',\r\n type: 'numeric',\r\n should: (field: string, text: string) => {\r\n return this._createRange(field, text, 'gte');\r\n }\r\n },\r\n {\r\n id: 12,\r\n name: '<',\r\n type: 'numeric',\r\n should: (field: string, text: string) => {\r\n return this._createRange(field, text, 'lt');\r\n }\r\n },\r\n {\r\n id: 13,\r\n name: '<=',\r\n type: 'numeric',\r\n should: (field: string, text: string) => {\r\n return this._createRange(field, text, 'lte');\r\n }\r\n }\r\n ];\r\n }\r\n\r\n private _createWildcard(field: string, text: string): Wildcard {\r\n const wildcard = {};\r\n\r\n if (typeof text === 'string') {\r\n text = text.toLowerCase();\r\n }\r\n\r\n wildcard[field] = text;\r\n return {\r\n wildcard: wildcard\r\n };\r\n }\r\n\r\n private _createRange(field: string, text: string, op: string): Range {\r\n const range = {};\r\n const opObj = {};\r\n\r\n opObj[op] = text;\r\n\r\n range[field] = opObj;\r\n\r\n return {\r\n range: range\r\n };\r\n }\r\n\r\n private _makeNot(entity: Wildcard): NotOperator[] {\r\n return [{\r\n bool: {\r\n must_not: [entity]\r\n }\r\n }];\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { TaskSeriesType } from '../../Task/Task.Model';\r\nimport { AllColumnsData, OutputColumn, OutputColumnCategory } from './Column-Picker/column.model';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { AdvancedSearchPersistenceService, RevokeShareModel, SavedSearchModel } from './advancedSearchPersistence.service';\r\nimport { AdvancedSearchRepository } from '../../Core-Repositories';\r\nimport { UserSettingsService } from '../../Account/userSettings.service';\r\nimport { CacheManager, CacheManagerService } from '../../Common/Routing/cache-manager.service';\r\nimport { DisplayName, SearchOperatorsService } from '../searchOperators.service';\r\n\r\nimport { map, flatten, filter, uniqBy, uniq, compact, union, reject } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\nimport { Settings } from '../../User/account.service';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class SmartSearchService {\r\n constructor(private readonly _userInstanceService: UserInstanceService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _advancedSearchRepository: AdvancedSearchRepository,\r\n private readonly _userSettingsService: UserSettingsService,\r\n private readonly _cacheManagerService: CacheManagerService,\r\n private readonly _searchOperators: SearchOperatorsService) {\r\n this._cacheManager = this._cacheManagerService.createCacheManager();\r\n this._cacheManager.registerKeyedStaticCache('allSearchFields', {\r\n cacheKey: 'searchfields',\r\n endpoint: '/api/search/advanced/fields/all',\r\n cacheDisabled: false\r\n });\r\n\r\n /* I'm sure there's a better way to do this, but as an 11th-hour fix, this is all the ways\r\n * I figure we sometimes call the lookups endpoint:\r\n *\r\n * SERVICE_URL + 'lookups'\r\n * SERVICE_URL + 'lookups?cpMode=av'\r\n * SERVICE_URL + 'lookups?cpMode=smart'\r\n * SERVICE_URL + 'lookups/all'\r\n * SERVICE_URL + 'lookups/all?cpMode=av'\r\n * SERVICE_URL + 'lookups/all?cpMode=smart'\r\n *\r\n * So we'll make a cache for each possibility */\r\n\r\n ['', '?cpMode=av', '?cpMode=smart', '/all', '/all?cpMode=av', '/all?cpMode=smart'].forEach((url) => {\r\n this._cacheManager.registerKeyedStaticCache(`searchLookups${ url}`, {\r\n cacheKey: 'searchfields',\r\n endpoint: `/api/search/advanced/lookups${url}`,\r\n cacheDisabled: false\r\n });\r\n });\r\n }\r\n\r\n allFields: Core.AdvancedSearchField[] = null;\r\n smartOnlyFields = null;\r\n columns: AllColumnsData = {\r\n byCategory: [],\r\n all: [],\r\n persistedDepths: []\r\n };\r\n\r\n private readonly SMART_SETTING_GROUP_ID = 18;\r\n\r\n private readonly COMPANY = 10;\r\n private readonly SITE = 20;\r\n private readonly PARCEL = 30;\r\n private readonly ASSESSMENT = 40;\r\n private readonly COMPANY_CONTACT = 50;\r\n private readonly SITE_CONTACT = 60;\r\n private readonly PARCEL_CONTACT = 70;\r\n private readonly REVISION = 80;\r\n private readonly COMPONENT = 90;\r\n private readonly APPEAL = 100;\r\n private readonly PAYMENT = 110;\r\n private readonly INTAKE_ITEM = 120;\r\n private readonly REFUND = 130;\r\n private readonly FILING = 140;\r\n private readonly INVOICE = 150;\r\n private readonly BILL = 105;\r\n\r\n private _cacheManager: CacheManager;\r\n private _canceler: (string) => void;\r\n\r\n getCacheManager(): CacheManager {\r\n return this._cacheManager;\r\n }\r\n\r\n async getColumns(includeTaskColumns: boolean, cpMode: 'smart'| 'av'): Promise {\r\n let targetCache = null;\r\n\r\n if (includeTaskColumns) {\r\n if (cpMode === 'smart') { targetCache = 'searchLookups/all?cpMode=smart'; }\r\n else if (cpMode === 'av') { targetCache = 'searchLookups/all?cpMode=av'; }\r\n else if (!cpMode) { targetCache = 'searchLookups/all'; }\r\n }\r\n else {\r\n if (cpMode === 'smart') { targetCache = 'searchLookups?cpMode=smart'; }\r\n else if (cpMode === 'av') { targetCache = 'searchLookups?cpMode=av'; }\r\n else if (!cpMode) { targetCache = 'searchLookups'; }\r\n }\r\n\r\n let result;\r\n if (targetCache) {\r\n result = await this._cacheManager.keyedStaticGet(targetCache);\r\n }\r\n // I'm 99% sure that cpMode will always only be av or smart, but on the 1% chance I'm wrong,\r\n // go ahead and let it work otherwise, just don't cache.\r\n else {\r\n result = await lastValueFrom(this._advancedSearchRepository.getColumnsCpMode(cpMode, includeTaskColumns));\r\n }\r\n\r\n const isInRyanInstance = this._userInstanceService.isCurrentInstanceRyan();\r\n const hasRyanPrivate = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW) || this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT);\r\n\r\n result = result.filter(category => isInRyanInstance && hasRyanPrivate || category.categoryID !== 19); // this.INVOICE\r\n\r\n if(!isInRyanInstance) {\r\n result = this.filterColumnsByRyanInstance(result);\r\n }\r\n else{\r\n result = this.filterColumnsByRyanPrivateAccess(result, hasRyanPrivate);\r\n }\r\n\r\n this.columns.byCategory = result;\r\n this.columns.all = this.getAllColumns(result);\r\n\r\n return this.columns;\r\n }\r\n\r\n filterColumnsByRyanInstance(categories): any[] {\r\n return categories.map(category => {\r\n category.columns = _.reject(category.columns, column => { // This is bad and not sustainable. We need a new soluction at some point\r\n return _.includes(column.displayName, 'DR Team Retrieves')\r\n || _.includes(column.displayName, 'Jurisdiction Specialist')\r\n || _.includes(column.displayName, 'DRTT')\r\n || column.isRyanInternal; // internal ryan fields should not be shown by any other instance\r\n });\r\n\r\n if(category.subcategories.length) {\r\n category.subcategories = this.filterColumnsByRyanInstance(category.subcategories);\r\n }\r\n\r\n return category;\r\n });\r\n }\r\n\r\n\r\n filterColumnsByRyanPrivateAccess(categories: any, hasRyanPrivate: boolean): any[] {\r\n return categories.map(category => {\r\n category.columns = _.reject(category.columns, column => {\r\n return column.isRyanInternal && !hasRyanPrivate; // non-ryan user should not see ryan internal SMART/AV columns\r\n });\r\n\r\n if(category.subcategories.length) {\r\n category.subcategories = this.filterColumnsByRyanPrivateAccess(category.subcategories, hasRyanPrivate);\r\n }\r\n\r\n return category;\r\n });\r\n }\r\n\r\n getAllColumns(columnCategories: any): any[] {\r\n\r\n console.log('stvhere smartSearch.service - columnCategories');\r\n\r\n const categoryColumns = _.flow([\r\n map(category => {\r\n if (category.columns) {\r\n category.columns.forEach((column) => {\r\n column.categoryName = category.categoryName;\r\n column.categoryID = category.categoryID;\r\n\r\n column.typeAheadName = `${column.categoryName }: ${ column.displayName}`;\r\n });\r\n }\r\n\r\n return category;\r\n }),\r\n map(x => x.columns),\r\n flatten,\r\n compact\r\n ])(columnCategories);\r\n\r\n const subcategoryColumns = _.flow([\r\n map(category => {\r\n category.subcategories.forEach(subcategory => {\r\n subcategory.columns.forEach(column => {\r\n column.categoryName = `${category.categoryName } - ${ subcategory.categoryName}`;\r\n column.categoryID = subcategory.categoryID;\r\n\r\n column.typeAheadName = `${column.categoryName }: ${ column.displayName}`;\r\n });\r\n });\r\n\r\n return category;\r\n }),\r\n map(x => x.subcategories),\r\n flatten,\r\n map(x => x.columns),\r\n flatten,\r\n compact\r\n ])(columnCategories);\r\n\r\n return _.union(categoryColumns, subcategoryColumns);\r\n }\r\n\r\n disableColumns(checkedColumns: any[], temporary: boolean = false, taskSeriesTypeAdvancedSearchDepthValue?: number): void {\r\n let depthsChecked = _.flow([\r\n map(column => column.depthValue === undefined ? column.depth.depthValue : column.depthValue),\r\n union([taskSeriesTypeAdvancedSearchDepthValue]),\r\n uniq\r\n ])(checkedColumns);\r\n\r\n // Persisted depths are those which include the filters and output columns\r\n if (temporary) {\r\n depthsChecked = _.union(depthsChecked, this.columns.persistedDepths);\r\n } else {\r\n this.columns.persistedDepths = depthsChecked;\r\n }\r\n\r\n // disable all columns whose depth is not included into depthsChecked\r\n //\r\n this.columns.all.forEach(column => {\r\n column.disabled = !!this.getDepthsThatDisable(depthsChecked, column.depthValue).length;\r\n });\r\n }\r\n\r\n async getAllFields(smartOnly: boolean): Promise {\r\n // TODO: We should consider refactoring this; it's unecessarily convoluted at the moment. I attempted\r\n // to replace all this with a relatively straightforward call to cacheManager.keyedStaticGet and got\r\n // failures downsteam, so this works for now\r\n\r\n if (!this.allFields) {\r\n const cacheManager = this.getCacheManager();\r\n this.allFields = await cacheManager.keyedStaticGet('allSearchFields');\r\n }\r\n\r\n if (smartOnly) {\r\n if (!this.smartOnlyFields) {\r\n this.smartOnlyFields = this.allFields.filter(field => {\r\n return field.usedBySmart;\r\n });\r\n }\r\n return this.smartOnlyFields;\r\n }\r\n else {\r\n return this.allFields;\r\n }\r\n }\r\n\r\n checkIfAllFieldsPresent() : boolean {\r\n if (!this.allFields) {\r\n return false;\r\n }\r\n return true;\r\n }\r\n\r\n getFieldById(id: number): Core.AdvancedSearchField {\r\n if (!this.allFields) {\r\n console.log('************* error - trying to access allFields while this array has not been loaded yet');\r\n return null;\r\n }\r\n\r\n // advancedSearchFieldID\r\n return this.allFields.find(x => x.advancedSearchFieldID === id);\r\n }\r\n\r\n getFieldByDisplayName(displayName: string): Core.AdvancedSearchField {\r\n if (!this.allFields) {\r\n console.log('************* error - trying to access allFields while this array has not been loaded yet');\r\n return null;\r\n }\r\n\r\n return this.allFields.find(x => x.displayName === displayName);\r\n }\r\n\r\n getDepthsThatDisable(depthsChecked: any[], depth: number): any[] {\r\n switch (depth) {\r\n case this.SITE:\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT]);\r\n case this.PARCEL:\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT, this.SITE_CONTACT, this.INVOICE]);\r\n case this.ASSESSMENT:\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT, this.SITE_CONTACT, this.PARCEL_CONTACT, this.INVOICE, this.INTAKE_ITEM, this.BILL]);\r\n case this.COMPANY_CONTACT:\r\n return _.intersection(depthsChecked, [this.SITE, this.PARCEL, this.SITE_CONTACT, this.PARCEL_CONTACT, this.REVISION, this.COMPONENT, this.APPEAL, this.PAYMENT, this.BILL, this.REFUND, this.FILING, this.INVOICE, this.ASSESSMENT]);\r\n case this.SITE_CONTACT:\r\n return _.intersection(depthsChecked, [this.PARCEL, this.COMPANY_CONTACT, this.PARCEL_CONTACT, this.REVISION, this.COMPONENT, this.APPEAL, this.PAYMENT, this.BILL, this.REFUND, this.FILING, this.INVOICE, this.ASSESSMENT]);\r\n case this.PARCEL_CONTACT:\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT, this.SITE_CONTACT, this.REVISION, this.COMPONENT, this.APPEAL, this.PAYMENT, this.BILL, this.REFUND, this.FILING, this.INVOICE, this.ASSESSMENT]);\r\n case this.REVISION:\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT, this.SITE_CONTACT, this.PARCEL_CONTACT, this.APPEAL, this.PAYMENT, this.BILL, this.REFUND, this.FILING, this.INVOICE]);\r\n case this.COMPONENT:\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT, this.SITE_CONTACT, this.PARCEL_CONTACT, this.APPEAL, this.PAYMENT, this.BILL, this.REFUND, this.FILING, this.INVOICE]);\r\n case this.APPEAL:\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT, this.SITE_CONTACT, this.PARCEL_CONTACT, this.REVISION, this.COMPONENT, this.PAYMENT, this.BILL, this.REFUND, this.FILING, this.INVOICE]);\r\n case this.PAYMENT:\r\n // wk-7545 - removed this.ASSESSMENT from array below, tax fields should be blocked by this.REVISION, not this.ASSESSMENT\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT, this.SITE_CONTACT, this.PARCEL_CONTACT, this.REVISION, this.COMPONENT, this.APPEAL, this.REFUND, this.FILING, this.INVOICE, this.INTAKE_ITEM]);\r\n case this.REFUND:\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT, this.SITE_CONTACT, this.PARCEL_CONTACT, this.REVISION, this.COMPONENT, this.APPEAL, this.PAYMENT, this.BILL, this.FILING, this.INVOICE]);\r\n case this.FILING:\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT, this.SITE_CONTACT, this.PARCEL_CONTACT, this.REVISION, this.COMPONENT, this.APPEAL, this.PAYMENT, this.BILL, this.REFUND, this.INVOICE]);\r\n case this.INVOICE:\r\n return _.intersection(depthsChecked, [this.PARCEL, this.ASSESSMENT, this.COMPANY_CONTACT, this.SITE_CONTACT, this.PARCEL_CONTACT, this.REVISION, this.COMPONENT, this.APPEAL, this.PAYMENT, this.BILL, this.REFUND, this.FILING]);\r\n case this.BILL:\r\n return _.intersection(depthsChecked, [this.COMPANY_CONTACT, this.SITE_CONTACT, this.PARCEL_CONTACT, this.REVISION, this.COMPONENT, this.APPEAL, this.REFUND, this.FILING, this.INVOICE, this.INTAKE_ITEM, this.ASSESSMENT]);\r\n default:\r\n return [];\r\n }\r\n }\r\n\r\n disableColumnsFromTaskTypeOnly(taskSeriesType: TaskSeriesType): void {\r\n this.columns.all = this.columns.all.map((column) => {\r\n column.disabled = !_.includes(taskSeriesType.depthValuesToEnable, column.depthValue)\r\n && !_.includes(taskSeriesType.fieldIdsToEnable, (column.id || column.columnId || column.advancedSearchFieldID));\r\n\r\n return column;\r\n });\r\n }\r\n\r\n getFilteredColumnCategories(columnsToExclude: OutputColumn[]): OutputColumnCategory[] {\r\n const initColumns = (category) => {\r\n return _.flow([\r\n filter({ categoryID: category.categoryID }),\r\n reject(column => {\r\n const columnId = column.id || column.columnId || column.advancedSearchFieldID;\r\n const columnIdExists = _.some(columnsToExclude, { columnId: columnId });\r\n const idExists = _.some(columnsToExclude, { id: columnId });\r\n const advancedSearchFieldIDExists = _.some(columnsToExclude, { advancedSearchFieldID: columnId });\r\n return columnIdExists || idExists || advancedSearchFieldIDExists;\r\n }),\r\n map(column => {\r\n column.toAdd = false;\r\n return column;\r\n })\r\n ])(this.columns.all);\r\n };\r\n return [ ...this.columns.byCategory ].map((category) => {\r\n category.columns = initColumns(category);\r\n category.subcategories = category.subcategories.map((subcategory) => {\r\n subcategory.columns = initColumns(subcategory);\r\n\r\n return subcategory;\r\n });\r\n\r\n return category;\r\n });\r\n }\r\n\r\n resetCategoryState(): void {\r\n this.columns.byCategory.forEach(category => {\r\n category.isOpen = false;\r\n });\r\n }\r\n\r\n async prepareCriteriaFromLoad(criteria): Promise {\r\n if (typeof criteria === 'string') {\r\n criteria = JSON.parse(criteria);\r\n }\r\n const columns = await this.getColumns(false, 'smart');\r\n criteria.outputColumns = _.flow([\r\n map(columnId => {\r\n const column = columns.all.find(x => x && x.columnId === columnId);\r\n if(!column) {\r\n this._advancedSearchPersistenceService.hiddenColumns.push(columnId);\r\n }\r\n\r\n return column;\r\n }),\r\n compact\r\n ])(criteria.outputColumns);\r\n\r\n criteria.filters = criteria.filters.map(criteriaFilter => {\r\n const column = { ...columns.all.find(x => x && x.columnId === criteriaFilter.columnId) };\r\n column.operators = this._searchOperators.getOperatorArray(column.operators as string[]);\r\n\r\n column.or = criteriaFilter.or.map(or => {\r\n return {\r\n value: or.value,\r\n operator: (column.operators as DisplayName[]).find(x => x.name === or.operatorName)\r\n };\r\n });\r\n\r\n return column;\r\n });\r\n\r\n return criteria;\r\n }\r\n\r\n prepareCriteriaForSave(criteria: any): any {\r\n const outputColumns = criteria.outputColumns.map(x => x.columnId);\r\n const filters = criteria.filters.map(criteriaFilter => {\r\n const or = criteriaFilter.or.map(filterOr => ({ value: filterOr.value, operatorName: filterOr.operator.name }));\r\n\r\n return {\r\n columnId: criteriaFilter.columnId,\r\n or\r\n };\r\n });\r\n\r\n return { ...criteria, ...{ outputColumns, filters }};\r\n }\r\n\r\n\r\n getAllCustomSearches(): Promise {\r\n const config = {\r\n cache: true\r\n };\r\n\r\n return lastValueFrom(this._advancedSearchRepository.getAllCustomSearches(config));\r\n }\r\n\r\n saveCustomSearch(searchItem: SavedSearchModel): Promise {\r\n searchItem.searchCriteria = this.prepareCriteriaForSave(searchItem.searchCriteria);\r\n return lastValueFrom(this._advancedSearchRepository.saveCustomSearch(searchItem));\r\n }\r\n\r\n share(searchItem: Core.AdvancedSearchList): Promise {\r\n return lastValueFrom(this._advancedSearchRepository.share(searchItem));\r\n }\r\n\r\n revokeShare(searchItem: SavedSearchModel): Promise {\r\n const revokeModel: RevokeShareModel = {\r\n categoryID: searchItem.categoryId,\r\n categoryName: searchItem.categoryName,\r\n defaultDisplay: searchItem.defaultDisplay,\r\n instanceID: searchItem.instanceID,\r\n isRyanInternal: searchItem.isRyanInternal,\r\n isSystemSearch: searchItem.isSystemSearch,\r\n rowVersion: searchItem.rowVersion,\r\n searchCriteria: searchItem.searchCriteria,\r\n searchID: searchItem.searchId,\r\n searchName: searchItem.searchName\r\n };\r\n return lastValueFrom(this._advancedSearchRepository.revokeShare(revokeModel));\r\n }\r\n\r\n createCustomSearch(searchItem: SavedSearchModel): Promise {\r\n searchItem.searchCriteria = this.prepareCriteriaForSave(searchItem.searchCriteria);\r\n return lastValueFrom(this._advancedSearchRepository.createCustomSearch(searchItem));\r\n }\r\n\r\n saveSystemSearch(searchItem: SavedSearchModel): Promise {\r\n searchItem.searchCriteria = this.prepareCriteriaForSave(searchItem.searchCriteria);\r\n return lastValueFrom(this._advancedSearchRepository.saveSystemSearch(searchItem));\r\n }\r\n\r\n createSystemSearch(searchItem: SavedSearchModel): Promise {\r\n searchItem.searchCriteria = this.prepareCriteriaForSave(searchItem.searchCriteria);\r\n return lastValueFrom(this._advancedSearchRepository.createSystemSearch(searchItem));\r\n }\r\n\r\n /*\r\n function getOneCustomSearch(searchId) {\r\n return sdHttp.get(SERVICE_URL_CUSTOM_SEARCH + searchId)\r\n .then(returnSearch);\r\n }\r\n\r\n function getOneSystemSearch(searchId) {\r\n return sdHttp.get(SERVICE_URL_SYSTEM_SEARCH + searchId)\r\n .then(returnSearch);\r\n }\r\n */\r\n async getOneSearch(searchId: number, searchType: number): Promise {\r\n const result = await lastValueFrom(this._advancedSearchRepository.getOneSearch(searchId, searchType));\r\n return await this.returnSearch(result);\r\n }\r\n\r\n async returnSearch(result): Promise {\r\n result.searchCriteria = await this.prepareCriteriaFromLoad(result.searchCriteria);\r\n return result;\r\n }\r\n\r\n /*\r\n\r\n available operators:\r\n\r\n public static List AvailableOperators = new List()\r\n {\r\n new Operator() {Name = \"Nullable\", Value = 1},\r\n new Operator() {Name = \"Equal\", Value = 2, Expression = \" = {0}\"},\r\n new Operator() {Name = \"NotEqual\", Value = 4, Expression = \" != {0}\"},\r\n new Operator() {Name = \"Blank\", Value = 8, Expression = \" IS NULL \"},\r\n new Operator() {Name = \"Contain\", Value = 16, Expression = \" LIKE %{0}%\"},\r\n new Operator() {Name = \"DoesNotContain\", Value = 32},\r\n new Operator() {Name = \"BeginsWith\", Value = 64},\r\n new Operator() {Name = \"EndsWith\", Value = 128},\r\n new Operator() {Name = \"LessThan\", Value = 256},\r\n new Operator() {Name = \"LessThanEqual\", Value = 512},\r\n new Operator() {Name = \"GreaterThan\", Value = 1024 },\r\n new Operator() {Name = \"GreaterThanEqual\", Value = 2048}\r\n };\r\n\r\n */\r\n\r\n cancelSearch(): void {\r\n if (this._canceler) {\r\n this._canceler('user cancelled');\r\n }\r\n }\r\n\r\n async executeSearch(payloadCriteria): Promise {\r\n const config = {};\r\n\r\n return new Promise(resolve => {\r\n const sub = this._advancedSearchRepository.executeSearch('EXECUTE/', payloadCriteria, config)\r\n .subscribe(x => {\r\n resolve(x);\r\n this._canceler = null;\r\n },\r\n err => {\r\n this._canceler('error');\r\n }\r\n\r\n );\r\n\r\n this._canceler = (msg: string) => {\r\n sub.unsubscribe();\r\n resolve({});\r\n this._canceler = null;\r\n };\r\n });\r\n }\r\n\r\n async export(payloadCriteria): Promise {\r\n const config = {};\r\n\r\n return await lastValueFrom(this._advancedSearchRepository.executeSearch('export', payloadCriteria, config));\r\n }\r\n\r\n getSearchCategories(): Promise {\r\n return lastValueFrom(this._advancedSearchRepository.getSearchCategories());\r\n }\r\n\r\n createSearchCategory(category: any): Promise {\r\n return lastValueFrom(this._advancedSearchRepository.createSearchCategory(category));\r\n }\r\n\r\n deleteSearchCategory(category: any): Promise {\r\n return lastValueFrom(this._advancedSearchRepository.deleteSearchCategory(category.categoryId));\r\n }\r\n\r\n patchSearch(searchItem: any, searchType: number): Promise {\r\n return lastValueFrom(this._advancedSearchRepository.patchSearch(searchItem, searchType));\r\n }\r\n\r\n changeSearchCategory(searchItem: any, categoryId: number, searchType: Core.SearchCategoryType): Promise {\r\n const categorySearchItem = {\r\n searchID: searchItem.searchId,\r\n categoryID: categoryId,\r\n rowVersion: searchItem.rowVersion,\r\n isSystemSearch: searchType === Core.SearchCategoryType.System\r\n };\r\n\r\n return lastValueFrom(this._advancedSearchRepository.changeSearchCategory(categorySearchItem, searchType));\r\n }\r\n\r\n async deleteSearch(searchItem: Core.AdvancedSearchList, searchType: Core.SearchCategoryType): Promise {\r\n return await lastValueFrom(this._advancedSearchRepository.deleteSearch(searchItem, searchType));\r\n }\r\n\r\n async toggleSearchFavorite(searchItem: any, isFavorite: boolean): Promise {\r\n const data = {\r\n systemSearchID: searchItem.searchId\r\n };\r\n\r\n if (isFavorite) {\r\n return await lastValueFrom(this._advancedSearchRepository.toggleSearchFavoriteOn(data));\r\n } else {\r\n return await lastValueFrom(this._advancedSearchRepository.toggleSearchFavoriteOff(searchItem.searchId));\r\n }\r\n }\r\n\r\n async searchHasFavorites(searchItem: any): Promise {\r\n return await lastValueFrom(this._advancedSearchRepository.searchHasFavorites(searchItem.searchId));\r\n }\r\n\r\n async getFavoriteCount(searchItem: any): Promise {\r\n return await lastValueFrom(this._advancedSearchRepository.getFavoriteCount(searchItem.searchId));\r\n }\r\n\r\n async persistSetting(settings): Promise {\r\n settings = _.pick(settings, 'excludeInactive', 'frequentlyUsed', 'groupByBatches');\r\n\r\n let criteriaSetting: Settings = {\r\n id: 0,\r\n name: 'Smart-Defaults',\r\n value: settings,\r\n groupId: this.SMART_SETTING_GROUP_ID,\r\n groupName: 'Smart-Defaults',\r\n folderId: 20,\r\n folderName: 'Smart-Defaults',\r\n };\r\n\r\n const existingSettings = this._userSettingsService.getSettingsByGroup(this.SMART_SETTING_GROUP_ID);\r\n\r\n if (existingSettings.length) {\r\n criteriaSetting = _.cloneDeep(existingSettings[0]);\r\n criteriaSetting.value = _.cloneDeep(settings);\r\n }\r\n\r\n return await this._userSettingsService.save(criteriaSetting);\r\n }\r\n\r\n getSavedSettings(): any {\r\n const existingCriteriaSettings = this._userSettingsService.getSettingsByGroup(this.SMART_SETTING_GROUP_ID);\r\n\r\n if (existingCriteriaSettings.length) {\r\n return _.cloneDeep(existingCriteriaSettings[0].value);\r\n } else {\r\n return null;\r\n }\r\n }\r\n\r\n getInvalidColumns(outputColumns: any[], shouldReturnColObject?: boolean): any {\r\n const invalidColumns = [];\r\n const colDepths = outputColumns.map(x => x.depthValue);\r\n\r\n outputColumns.forEach(colToCheck => {\r\n if(colToCheck.fromTaskType) {\r\n return;\r\n }\r\n\r\n const depthsThatDisable = this.getDepthsThatDisable(colDepths, colToCheck.depthValue);\r\n\r\n if (depthsThatDisable.length) {\r\n invalidColumns.push({\r\n colName: this.getColName(colToCheck),\r\n offendingColumns: _.flow([\r\n filter((column) => {\r\n return _.includes(depthsThatDisable, column.depthValue);\r\n }),\r\n uniqBy((column) => {\r\n return column.typeAheadName || column.displayName;\r\n }),\r\n map((column) => {\r\n return shouldReturnColObject ? column : this.getColName(column);\r\n })\r\n ])(outputColumns)\r\n });\r\n }\r\n });\r\n\r\n return invalidColumns;\r\n }\r\n\r\n getColName(column: any): string {\r\n return column.categoryName ? `${column.categoryName } - ${ column.displayName}` : column.resultColumnName;\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { SmartSearchService } from '../../../../Search/Advanced/smartSearch.service';\r\nimport { UserSaveService } from '../../userSave.service';\r\n\r\nexport interface SearchCategoryModalParams {\r\n search: Core.AdvancedSearchList;\r\n searchType: Core.SearchCategoryType;\r\n}\r\n\r\n@Component({\r\n selector: 'search-category',\r\n templateUrl: './navChangeCategory.component.html'\r\n})\r\nexport class SearchCategoryComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(private readonly _smartSearchService: SmartSearchService,\r\n private readonly _userSaveService: UserSaveService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: SearchCategoryModalParams;\r\n result: void;\r\n\r\n modalTitle: string;\r\n search: Core.AdvancedSearchList;\r\n searchType: Core.SearchCategoryType;\r\n categories: any[] = [];\r\n selectedCategory: any;\r\n newCategory: string;\r\n creatingNewCategory = false;\r\n\r\n async ngOnInit(): Promise {\r\n this.search = this.params.search;\r\n this.searchType = this.params.searchType;\r\n this.modalTitle = `Change \"${this.search.searchName}\" View's Category`;\r\n\r\n const categories = await this._smartSearchService.getSearchCategories();\r\n\r\n if (categories && categories.length) {\r\n this.categories = categories.filter(x => x.categoryType === this.searchType);\r\n this.selectedCategory = this.categories.find(x => x.categoryId === this.search.categoryId) || this.categories[0];\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n //Create new category first, then update view\r\n if (this.selectedCategory.categoryId === -1) {\r\n const category = { ...this.selectedCategory };\r\n delete category.categoryId;\r\n\r\n const result = await this._smartSearchService.createSearchCategory(category);\r\n\r\n this.search.categoryId = result.categoryId;\r\n this.selectedCategory.categoryId = result.categoryId;\r\n }\r\n\r\n await this._smartSearchService.changeSearchCategory(this.search, this.selectedCategory.categoryId, this.searchType);\r\n await this._userSaveService.refreshCurrentList();\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n createNewCategory(): void {\r\n if (!this.newCategory) {\r\n this.creatingNewCategory = false;\r\n return;\r\n }\r\n\r\n let category;\r\n if (this.categories.some(x => x.categoryId === -1)) {\r\n category = this.categories.find(x => x.categoryId === -1);\r\n category.categoryName = this.newCategory;\r\n category.categoryType = this.searchType;\r\n } else {\r\n category = {\r\n categoryName: this.newCategory,\r\n categoryType: this.searchType,\r\n categoryId: -1\r\n };\r\n this.categories.push(category);\r\n }\r\n\r\n this.selectedCategory = category;\r\n this.search.categoryId = -1;\r\n this.creatingNewCategory = false;\r\n this.newCategory = '';\r\n }\r\n\r\n cancelCreateCategory(): void {\r\n this.creatingNewCategory = false;\r\n this.newCategory = '';\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { DefaultDisplayTypes } from '../../../../constants.new';\r\nimport { SmartSearchService } from '../../../../Search/Advanced/smartSearch.service';\r\n\r\nexport interface SearchDefaultDisplayModalParams {\r\n search: Core.AdvancedSearchList;\r\n searchType: Core.SearchCategoryType;\r\n}\r\n\r\n@Component({\r\n selector: 'search-default-display',\r\n templateUrl: './searchDefaultDisplay.component.html'\r\n})\r\nexport class SearchDefaultDisplayComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(private readonly _smartSearchService: SmartSearchService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: SearchDefaultDisplayModalParams;\r\n result: void;\r\n\r\n modalTitle: string;\r\n search: Core.AdvancedSearchList;\r\n searchType: number;\r\n defaultDisplayTypes = DefaultDisplayTypes;\r\n\r\n ngOnInit(): void {\r\n this.search = this.params.search;\r\n this.searchType = this.params.searchType;\r\n this.modalTitle = `Change \"${this.search.searchName}\" Default Display`;\r\n }\r\n\r\n async save() {\r\n const result = await this._smartSearchService.patchSearch(this.search, this.searchType);\r\n this.search.rowVersion = result.rowVersion;\r\n this.cancel();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { SmartSearchService } from '../../../../Search/Advanced/smartSearch.service';\r\nimport { UserSaveService } from '../../userSave.service';\r\n\r\nexport interface searchRenameModalParams {\r\n search: Core.AdvancedSearchList;\r\n searchType: Core.SearchCategoryType;\r\n}\r\n\r\n@Component({\r\n selector: 'search-rename',\r\n templateUrl: './searchRename.component.html'\r\n})\r\nexport class SearchRenameComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(private readonly _smartSearchService: SmartSearchService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _userSaveService: UserSaveService) {\r\n }\r\n\r\n params: searchRenameModalParams;\r\n result: void;\r\n\r\n modalTitle: string;\r\n search: Core.AdvancedSearchList;\r\n searchType: number;\r\n\r\n ngOnInit(): void {\r\n this.search = this.params.search;\r\n this.searchType = this.params.searchType;\r\n this.modalTitle = `Rename \"${this.search.searchName}\" Search`;\r\n }\r\n\r\n async save() {\r\n const result = await this._smartSearchService.patchSearch(this.search, this.searchType);\r\n this.search.rowVersion = result.rowVersion;\r\n await this._userSaveService.refreshCurrentList();\r\n this.cancel();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { UIRouter } from '@uirouter/angular';\r\nimport { AmplitudeEvent, ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { AdvancedSearchPersistenceService } from '../../Search/Advanced/advancedSearchPersistence.service';\r\nimport { SmartSearchService } from '../../Search/Advanced/smartSearch.service';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { SearchCategoryComponent } from '../User-Save/Modals/Category/searchCategory.component';\r\nimport { SearchDefaultDisplayComponent } from '../User-Save/Modals/Default-Display/searchDefaultDisplay.component';\r\nimport { SearchRenameComponent } from '../User-Save/Modals/Rename/searchRename.component';\r\nimport { SearchCategoryType } from '../User-Save/userSave.service';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport {\r\n ContextMenuItem,\r\n SaveCategory,\r\n SaveListItem,\r\n SaveTabColumn, SaveTabColumnType,\r\n UserSavePage\r\n} from '../User-Save/userSavePage.model';\r\n\r\nexport class SavedSmartService extends UserSavePage {\r\n constructor(private readonly _smartSearchService: SmartSearchService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _router: UIRouter,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _restrictService: RestrictService\r\n ) {\r\n super();\r\n }\r\n\r\n protected _columns: SaveTabColumn[] = [\r\n {\r\n name: 'Name',\r\n key: 'name',\r\n type: SaveTabColumnType.String\r\n },\r\n {\r\n name: 'Change Date',\r\n key: 'changeDate',\r\n type: SaveTabColumnType.Date\r\n }\r\n ];\r\n\r\n private _baseValues: Core.SavedSearchCategoryManagementDTO[] = [];\r\n private userHasEditSystemSearch: boolean = this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT);\r\n\r\n get tabTitle(): string {\r\n return 'Saved Smarts';\r\n }\r\n\r\n contextMenu(category: SaveCategory, index: number): ContextMenuItem[] {\r\n return [\r\n {\r\n name: 'Share',\r\n onClick: (item, searchType) => {\r\n this._shareSmart(item, searchType);\r\n },\r\n isDisabled: () => {\r\n return this._currentSelectedFilter === SearchCategoryType.Favorite;\r\n }\r\n },\r\n {\r\n name: 'Rename',\r\n onClick: (item, searchType) => {\r\n this._modalService.showAsync(SearchRenameComponent, { search: item.originalModel, searchType }, 'modal-lg');\r\n },\r\n isDisabled: (item: SaveListItem) => {\r\n return item.originalModel.isSystemSeeded\r\n || this._currentSelectedFilter === SearchCategoryType.Favorite\r\n || (this._currentSelectedFilter === SearchCategoryType.System && !this.userHasEditSystemSearch);\r\n }\r\n },\r\n {\r\n name: 'Change Category',\r\n onClick: (item, searchType) => {\r\n this._modalService.showAsync(SearchCategoryComponent, { search: item.originalModel, searchType }, 'modal-lg');\r\n },\r\n isDisabled: (item: SaveListItem) => {\r\n return item.originalModel.isSystemSeeded\r\n || this._currentSelectedFilter === SearchCategoryType.Favorite\r\n || (this._currentSelectedFilter === SearchCategoryType.System && !this.userHasEditSystemSearch);\r\n }\r\n },\r\n {\r\n name: 'Change Default Display',\r\n onClick: (item, searchType) => {\r\n this._modalService.showAsync(SearchDefaultDisplayComponent, { search: item.originalModel, searchType }, 'modal-lg');\r\n },\r\n isDisabled: (item: SaveListItem) => {\r\n return item.originalModel.isSystemSeeded\r\n || this._currentSelectedFilter === SearchCategoryType.Favorite\r\n || (this._currentSelectedFilter === SearchCategoryType.System && !this.userHasEditSystemSearch);\r\n }\r\n },\r\n {\r\n name: 'Delete',\r\n onClick: async(item, searchType) => {\r\n try {\r\n await this._messageModalService.confirm(`Are you sure you want to delete ${ item.name }?`);\r\n } catch(e) {\r\n return;\r\n }\r\n\r\n this.dirty = true;\r\n await this._smartSearchService.deleteSearch(item.originalModel, searchType);\r\n category.savedItemList.splice(index, 1);\r\n this._advancedSearchPersistenceService.deleteAdvancedSearch(item.originalModel);\r\n await this.getList();\r\n },\r\n isDisabled: (item: SaveListItem) => {\r\n return item.originalModel.isSystemSeeded\r\n || this._currentSelectedFilter === SearchCategoryType.Favorite\r\n || (this._currentSelectedFilter === SearchCategoryType.System && !this.userHasEditSystemSearch);\r\n }\r\n }\r\n ];\r\n }\r\n\r\n async getList(): Promise {\r\n if (!this._dirty) {\r\n return;\r\n }\r\n this._baseValues = await this._smartSearchService.getSearchCategories();\r\n\r\n const categoryList: SaveCategory[] = this._baseValues.map(x => {\r\n const list: SaveListItem[] = x.searchList.map(y => {\r\n return {\r\n id: y.searchId,\r\n name: y.searchName,\r\n isFavorite: y.isFavorite,\r\n changeDate: y.changeDate,\r\n canFavorite: true,\r\n originalModel: y,\r\n amplitudeEvent: this._getAmplitudeEvent(x, y)\r\n };\r\n });\r\n return {\r\n categoryId: x.categoryId,\r\n categoryName: x.categoryName,\r\n categoryType: x.categoryType,\r\n savedItemList: list\r\n };\r\n });\r\n\r\n this._separateByCategoryType(categoryList);\r\n }\r\n\r\n navigateTo(listItem: SaveListItem, categoryType: number): void {\r\n this._advancedSearchPersistenceService.clearSearchData();\r\n const params = {\r\n searchId: listItem.id,\r\n searchType: categoryType\r\n };\r\n this._router.stateService.transitionTo('search', params);\r\n }\r\n\r\n async toggleFavorite(search: SaveListItem): Promise {\r\n this.dirty = true;\r\n this._productAnalyticsService.logEvent('click-explore-favorite', { exploreFavoriteToggle: search.isFavorite ? 'on' : 'off' });\r\n await this._smartSearchService.toggleSearchFavorite(search.originalModel, search.isFavorite);\r\n }\r\n\r\n private async _shareSmart(searchItem: SaveListItem, searchType: Core.SearchCategoryType): Promise {\r\n // Go update the search to mark it as \"Shared\" if this is a custom search\r\n if (searchType === Core.SearchCategoryType.Custom) {\r\n await this._smartSearchService.share(searchItem.originalModel);\r\n }\r\n await this.getList();\r\n this._advancedSearchPersistenceService.clearSearchData();\r\n const params = {\r\n searchId: searchItem.id,\r\n searchType: searchType\r\n };\r\n const route = this._router.stateService.href('search', params, { absolute: true });\r\n this._showEmailWindow(route, searchItem.name, 'SMART');\r\n }\r\n\r\n private _getAmplitudeEvent(category: Core.SavedSearchCategoryManagementDTO, search: Core.AdvancedSearchList): AmplitudeEvent {\r\n const event = `click-explore-${category.categoryType ? 'saved' : 'system' }`;\r\n let properties: { [key: string]: string } = { exploreSystemSmart: category.categoryName };\r\n if (search.isFavorite && this._currentSelectedFilter === SearchCategoryType.Favorite) {\r\n properties = { exploreSystemSmart: 'favorite' };\r\n }\r\n return { event, properties };\r\n }\r\n}\r\n","export abstract class ActionViewPersistenceService {\r\n // I very lazily ported these over; anything I could tell the type of at a glance I provided\r\n // a type for, otherwise used any. We should put in proper types at some point, but for now\r\n // this gets us TS support\r\n routeParams: any;\r\n filterColumns: any;\r\n outputColumns: any[];\r\n detailResults: any;\r\n overviewResults: any;\r\n overviewHeaders: any[];\r\n drilldownMode: boolean;\r\n resultsChanged: boolean;\r\n selectedResult: any;\r\n actionViewType: any;\r\n actionViewName: string;\r\n masterFilter: any;\r\n drilldownFilter: any;\r\n showOrs: boolean;\r\n organizeBySelection: number;\r\n groupByCount: number;\r\n externalDrilldown: boolean;\r\n externalDrilldownData: any;\r\n revisionChangeTypeID: number;\r\n selectionData: any[];\r\n sort: any;\r\n filter: any;\r\n columnState: any;\r\n\r\n abstract clearSavedData(): void;\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { Observable, Subject } from 'rxjs';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { RestrictService } from '../../Common/Permissions/restrict.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { ReportManagerService } from '../../Reporting/Manager/report.manager.service';\r\nimport { AdvancedSearchPersistenceService } from '../../Search/Advanced/advancedSearchPersistence.service';\r\nimport { SmartSearchService } from '../../Search/Advanced/smartSearch.service';\r\nimport { ActionViewService } from '../../Task/ActionView/action-view-service.upgrade';\r\nimport { ActionViewPersistenceService } from '../../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { SavedActionViewService } from '../Saved-AV/savedActionView.service';\r\nimport { SavedReportService } from '../Saved-Report/savedReport.service';\r\nimport { SavedSmartService } from '../Saved-Smart/savedSmart.service';\r\nimport { UserSavePage } from './userSavePage.model';\r\n\r\nexport enum SearchPageType {\r\n Smart = 0,\r\n AV = 1,\r\n Report = 2\r\n}\r\n\r\nexport enum SearchCategoryType {\r\n System = 'system',\r\n User = 'user',\r\n Favorite = 'favorite'\r\n}\r\n\r\ntype SavePages = {\r\n [key in SearchPageType]?: UserSavePage;\r\n};\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class UserSaveService {\r\n constructor(private readonly _smartSearchService: SmartSearchService,\r\n private readonly _actionViewService: ActionViewService,\r\n private readonly _reportManagerService: ReportManagerService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService,\r\n private readonly _router: UIRouter,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n protected readonly _restrictService: RestrictService) {\r\n }\r\n\r\n private _currentSavePage: UserSavePage;\r\n\r\n private _currentUserSavePage: Subject> = new Subject>();\r\n private _currentUserSavePage$: Observable> = this._currentUserSavePage.asObservable();\r\n private _savePages: SavePages = {\r\n [SearchPageType.Smart]: new SavedSmartService(this._smartSearchService, this._messageModalService, this._modalService, this._advancedSearchPersistenceService, this._router, this._productAnalyticsService, this._restrictService),\r\n [SearchPageType.AV]: new SavedActionViewService(this._actionViewService, this._messageModalService, this._modalService, this._actionViewPersistenceService, this._router, this._productAnalyticsService, this._restrictService),\r\n [SearchPageType.Report]: new SavedReportService(this._reportManagerService, this._messageModalService, this._modalService, this._advancedSearchPersistenceService, this._router, this._restrictService)\r\n };\r\n\r\n get selectedUserSavePage$(): Observable> {\r\n return this._currentUserSavePage$;\r\n }\r\n\r\n getSavePage(type: SearchPageType): UserSavePage {\r\n this._currentSavePage = this._savePages[type];\r\n return this._savePages[type];\r\n }\r\n\r\n async refreshCurrentList(): Promise {\r\n this._currentSavePage.dirty = true;\r\n await this._currentSavePage.getList();\r\n this._currentUserSavePage.next(this._currentSavePage);\r\n }\r\n\r\n async updateList(type: SearchPageType): Promise {\r\n this._currentSavePage = this._savePages[type];\r\n await this._currentSavePage.getList();\r\n this._currentUserSavePage.next(this._currentSavePage);\r\n }\r\n\r\n setDirty(type: SearchPageType): void {\r\n this._savePages[type].dirty = true;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { TimerService } from '../../UI-Lib/Utilities';\r\nimport { AccountService } from '../../User/account.service';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { FeatureFlagsService } from '../FeatureFlags/feature-flags-service';\r\nimport { Roles } from '../Permissions/restrict.service';\r\nimport { init, Identify, identify, logEvent, setUserId } from '@amplitude/analytics-browser';\r\n\r\nimport * as moment from 'moment';\r\n\r\nexport interface AmplitudeEvent {\r\n event: string;\r\n properties?: { [key: string]: any };\r\n}\r\n\r\ninterface AmplitudeSequenceEvent {\r\n event: AmplitudeEvent;\r\n targetSequence: string[];\r\n eventSequence: string[];\r\n strict?: boolean;\r\n}\r\n\r\ninterface AmplitudeSequenceEvents {\r\n [event: string]: AmplitudeSequenceEvent;\r\n}\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ProductAnalyticsService {\r\n constructor(\r\n private readonly _accountService: AccountService,\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _timer: TimerService\r\n ) {\r\n this._amplitude = {\r\n init: init,\r\n logEvent: logEvent,\r\n identify: identify\r\n };\r\n }\r\n\r\n private _userPropertiesSet: boolean;\r\n // I hate to do this but otherwise this service is untestable\r\n private _amplitude: {\r\n init: (\r\n apiKey: string,\r\n userId?: string | undefined,\r\n options?: import('@amplitude/analytics-types').BrowserOptions | undefined\r\n ) => import('@amplitude/analytics-types').AmplitudeReturn;\r\n identify: (\r\n identify: import('@amplitude/analytics-types').Identify,\r\n eventOptions?: import('@amplitude/analytics-types').EventOptions | undefined\r\n ) => import('@amplitude/analytics-types').AmplitudeReturn;\r\n logEvent: (\r\n eventInput: string | import('@amplitude/analytics-types').BaseEvent,\r\n eventProperties?: Record | undefined,\r\n eventOptions?: import('@amplitude/analytics-types').EventOptions | undefined\r\n ) => import('@amplitude/analytics-types').AmplitudeReturn;\r\n };\r\n\r\n private _sequenceEvents: AmplitudeSequenceEvents = {};\r\n private _previousEvent: string;\r\n private _debounceLogEvent = this._timer.debounce((eventName: string, properties: any = {}) => {\r\n this._logEvent(eventName, properties);\r\n }, 40, true);\r\n\r\n init(amplitudeApiKey: string): void {\r\n const userId = this._getIAMUserId();\r\n this._amplitude.init(amplitudeApiKey, userId, {\r\n serverUrl: 'https://api.app.tax.com/analytics/2/httpapi',\r\n trackingOptions: {\r\n ipAddress: false\r\n }\r\n });\r\n }\r\n\r\n logEvent(eventName: string, properties: any = {}) {\r\n if (this._previousEvent === eventName) {\r\n this._debounceLogEvent(eventName, properties);\r\n } else {\r\n this._logEvent(eventName, properties);\r\n this._previousEvent = eventName;\r\n }\r\n }\r\n\r\n /**\r\n * Initiates a sequence event\r\n * @param event - The event to log when the sequence is complete\r\n * @param sequence - The sequence of events to log starting with the current event\r\n * @param strict - If true, there may not be any other events logged between the events in the sequence\r\n */\r\n initiateSequenceEvent(event: AmplitudeEvent, sequence: string[], strict?: boolean): void {\r\n this._sequenceEvents[`${event.event}.${sequence[sequence.length - 1]}`] = {\r\n event,\r\n targetSequence: sequence,\r\n eventSequence: [sequence[0]],\r\n strict\r\n };\r\n }\r\n\r\n /**\r\n * Logs a sequence event if it is the final event in the sequence\r\n * @param eventName\r\n * @param sequenceEvent\r\n */\r\n logSequenceEvent(eventName: string, sequenceEvent: string): void {\r\n // Check for events with multiple sequences\r\n const events = Object.keys(this._sequenceEvents).filter(x => x.startsWith(eventName));\r\n if (!events.length) {\r\n return;\r\n }\r\n\r\n events.forEach(x => {\r\n const sequence = this._sequenceEvents[x];\r\n if (\r\n sequence.targetSequence.includes(sequenceEvent) &&\r\n sequence.targetSequence.indexOf(sequenceEvent) === sequence.eventSequence.length\r\n ) {\r\n sequence.eventSequence.push(sequenceEvent);\r\n }\r\n\r\n if (sequence.eventSequence.toString() === sequence.targetSequence.toString()) {\r\n this.logEvent(sequence.event.event, sequence.event.properties);\r\n delete this._sequenceEvents[x];\r\n }\r\n });\r\n\r\n // Clear any strict events that remain\r\n this._sequenceEvents = Object.keys(this._sequenceEvents).reduce(\r\n (acc, key) => (this._sequenceEvents[key].strict ? acc : { ...acc, [key]: this._sequenceEvents[key] }),\r\n {}\r\n );\r\n }\r\n\r\n private _logEvent(eventName: string, properties: any = {}): void {\r\n const envConfig = (window as any)?.weissmanEnvironmentConfig;\r\n if (envConfig?.amplitudeApiKey) {\r\n if (!this._userPropertiesSet) {\r\n this._setUserProperties();\r\n }\r\n this._amplitude.logEvent(eventName, properties);\r\n }\r\n if (['local', 'test', 'uat'].includes(envConfig?.runtimeEnvironment)) {\r\n console.log(`Amplitude Event: ${eventName}`, properties);\r\n }\r\n }\r\n\r\n private _getUserType(): string {\r\n const hasRyanInstance = this._accountService.userData.instanceMembership.some(x => x.name === 'Ryan');\r\n const hasRyanPrivate = this._accountService.userData.globalRoles.some(\r\n x => x === Roles.RYANPRIVATEITEMSVIEW || x === Roles.RYANPRIVATEITEMSEDIT\r\n );\r\n if (hasRyanInstance && hasRyanPrivate) {\r\n return 'internal';\r\n } else if (hasRyanInstance && !hasRyanPrivate) {\r\n return 'external read only';\r\n } else {\r\n return 'licensed';\r\n }\r\n }\r\n\r\n private _getUserAge(): string {\r\n const days = moment().diff(this._accountService.userData.createDate, 'days');\r\n const years = moment().diff(this._accountService.userData.createDate, 'years');\r\n if (days < 365) {\r\n return 'Less than 1 year';\r\n } else if (years >= 5) {\r\n return '5+ years';\r\n } else {\r\n return `${years} ${years === 1 ? 'year' : 'years'}`;\r\n }\r\n }\r\n\r\n private _setUserProperties(): void {\r\n const userType = this._getUserType();\r\n const userAge = this._getUserAge();\r\n const selectedInstance = this._userInstanceService.getSelectedInstance();\r\n\r\n const IAMUserId = this._getIAMUserId();\r\n if (IAMUserId) {\r\n setUserId(IAMUserId);\r\n }\r\n\r\n const identityEvent = new Identify();\r\n identityEvent.set('userType', userType);\r\n identityEvent.set('createDate', this._accountService.userData.createDate);\r\n identityEvent.set('userAge', userAge);\r\n identityEvent.set('userTenant', selectedInstance?.name);\r\n identityEvent.set('defaultTeam', this._accountService.userData.defaultTeam);\r\n this._amplitude.identify(identityEvent);\r\n\r\n if (['test', 'uat'].includes((window as any)?.weissmanEnvironmentConfig?.runtimeEnvironment)) {\r\n console.log('Amplitude User:', {\r\n userId: IAMUserId,\r\n userType,\r\n createDate: this._accountService.userData.createDate,\r\n userAge,\r\n userTenant: selectedInstance?.name,\r\n defaultTeam: this._accountService.userData.defaultTeam\r\n });\r\n }\r\n\r\n this._userPropertiesSet = true;\r\n }\r\n\r\n private _getIAMUserId(): string {\r\n if (this._featureFlagsService.featureFlags.enableIAM && this._accountService.userData?.iamId) {\r\n return this._accountService.userData.iamId;\r\n }\r\n return null;\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { ActionViewService } from '../../../../Task/ActionView/action-view-service.upgrade';\r\nimport { UserSaveService } from '../../userSave.service';\r\n\r\nexport interface ActionViewCategoryModalParams {\r\n actionView: Core.ActionViewListDTO;\r\n actionViewType: Core.SearchCategoryType;\r\n}\r\n\r\n@Component({\r\n selector: 'action-view-category',\r\n templateUrl: './navChangeCategory.component.html'\r\n})\r\nexport class ActionViewCategoryComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(private readonly _actionViewService: ActionViewService,\r\n private readonly _userSaveService: UserSaveService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: ActionViewCategoryModalParams;\r\n result: void;\r\n\r\n modalTitle: string;\r\n actionView: Core.ActionViewListDTO;\r\n actionViewType: Core.SearchCategoryType;\r\n categories: any[] = [];\r\n selectedCategory: any;\r\n newCategory: string;\r\n creatingNewCategory = false;\r\n\r\n async ngOnInit(): Promise {\r\n this.actionView = this.params.actionView;\r\n this.actionViewType = this.params.actionViewType;\r\n this.modalTitle = `Change \"${this.actionView.actionViewName}\" View's Category`;\r\n\r\n const categories = await this._actionViewService.getCategories();\r\n if (categories && categories.length) {\r\n this.categories = categories.filter(x => x.categoryType === this.actionViewType);\r\n this.selectedCategory = this.categories.find(x => x.categoryId === this.actionView.categoryId) || this.categories[0];\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n //Create new category first, then update view\r\n if (this.selectedCategory.categoryId === -1) {\r\n const category = { ...this.selectedCategory };\r\n delete category.categoryId;\r\n\r\n const result = await this._actionViewService.createCategory(category);\r\n\r\n this.actionView.categoryId = result.categoryId;\r\n this.selectedCategory.categoryId = result.categoryId;\r\n }\r\n\r\n await this._actionViewService.changeCategory(this.actionView, this.selectedCategory.categoryId, this.actionViewType);\r\n await this._userSaveService.refreshCurrentList();\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n createNewCategory(): void {\r\n if (!this.newCategory) {\r\n this.creatingNewCategory = false;\r\n return;\r\n }\r\n if (this.categories.some(x => x.categoryId === -1)) {\r\n const category = this.categories.find(x => x.categoryId === -1);\r\n category.categoryName = this.newCategory;\r\n category.categoryType = this.actionViewType;\r\n } else {\r\n this.categories.push({\r\n categoryName: this.newCategory,\r\n categoryType: this.actionViewType,\r\n categoryId: -1\r\n });\r\n }\r\n\r\n this.actionView.categoryId = -1;\r\n this.creatingNewCategory = false;\r\n this.newCategory = '';\r\n }\r\n\r\n cancelCreateCategory(): void {\r\n this.creatingNewCategory = false;\r\n this.newCategory = '';\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { ActionViewDisplayTypes } from '../../../../constants.new';\r\nimport { ActionViewService } from '../../../../Task/ActionView/action-view-service.upgrade';\r\nimport { UserSaveService } from '../../userSave.service';\r\n\r\nexport interface ActionViewDefaultDisplayModalParams {\r\n actionView: Core.ActionViewListDTO;\r\n actionViewType: Core.SearchCategoryType;\r\n}\r\n\r\n@Component({\r\n selector: 'action-view-default-display',\r\n templateUrl: './actionViewDefaultDisplay.component.html'\r\n})\r\nexport class ActionViewDefaultDisplayComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(private readonly _actionViewService: ActionViewService,\r\n private readonly _userSaveService: UserSaveService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: ActionViewDefaultDisplayModalParams;\r\n result: void;\r\n\r\n modalTitle: string;\r\n actionView: Core.ActionViewListDTO;\r\n actionViewType: Core.SearchCategoryType;\r\n displayTypes = ActionViewDisplayTypes;\r\n selectedDisplayType: number = 0;\r\n\r\n ngOnInit(): void {\r\n this.actionView = this.params.actionView;\r\n this.actionViewType = this.params.actionViewType;\r\n this.modalTitle = `Change \"${this.actionView.actionViewName}\" Default Display`;\r\n }\r\n\r\n async save() {\r\n this.actionView.defaultDisplay = this.selectedDisplayType;\r\n\r\n //This is to work around a bug where no categoryId passed in clears the Id unintentionally. categoryId < 0 means \"don't change\"\r\n this.actionView.categoryId = -1;\r\n\r\n await this._actionViewService.patch(this.actionView, this.actionViewType);\r\n await this._userSaveService.refreshCurrentList();\r\n this.cancel();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n thatAreCompleted() {\r\n return this.actionView.thatAreChoice === 4;\r\n }\r\n}\r\n","\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { ActionViewService } from '../../../../Task/ActionView/action-view-service.upgrade';\r\nimport { UserSaveService } from '../../userSave.service';\r\n\r\nexport interface ActionViewRenameModalParams {\r\n actionView: Core.ActionViewListDTO;\r\n actionViewType: Core.SearchCategoryType;\r\n}\r\n\r\n@Component({\r\n selector: 'actionView-rename',\r\n templateUrl: './actionViewRename.component.html'\r\n})\r\nexport class ActionViewRenameComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(private readonly _actionViewService: ActionViewService,\r\n private readonly _userSaveService: UserSaveService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: ActionViewRenameModalParams;\r\n result: void;\r\n\r\n modalTitle: string;\r\n actionView: Core.ActionViewListDTO;\r\n actionViewType: Core.SearchCategoryType;\r\n\r\n ngOnInit(): void {\r\n this.actionView = this.params.actionView;\r\n this.actionViewType = this.params.actionViewType;\r\n this.modalTitle = `Rename \"${this.actionView.actionViewName}\" Action View`;\r\n }\r\n\r\n async save(): Promise {\r\n await this._actionViewService.patch(this.actionView, this.actionViewType);\r\n await this._userSaveService.refreshCurrentList();\r\n this.cancel();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { UIRouter } from '@uirouter/angular';\r\nimport { AmplitudeEvent, ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { ActionViewService } from '../../Task/ActionView/action-view-service.upgrade';\r\nimport { ActionViewPersistenceService } from '../../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { ActionViewCategoryComponent } from '../User-Save/Modals/Category/actionViewCategory.component';\r\nimport { ActionViewDefaultDisplayComponent } from '../User-Save/Modals/Default-Display/actionViewDefaultDisplay.component';\r\nimport { ActionViewRenameComponent } from '../User-Save/Modals/Rename/actionViewRename.component';\r\nimport { SearchCategoryType } from '../User-Save/userSave.service';\r\nimport {\r\n ContextMenuItem,\r\n SaveCategory,\r\n SaveListItem,\r\n SaveTabColumn, SaveTabColumnType,\r\n UserSavePage\r\n} from '../User-Save/userSavePage.model';\r\n\r\nexport class SavedActionViewService extends UserSavePage {\r\n constructor(private readonly _actionViewService: ActionViewService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService,\r\n private readonly _router: UIRouter,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _restrictService: RestrictService) {\r\n super();\r\n }\r\n\r\n protected _columns: SaveTabColumn[] = [\r\n {\r\n name: 'Name',\r\n key: 'name',\r\n type: SaveTabColumnType.String\r\n },\r\n {\r\n name: 'Change Date',\r\n key: 'changeDate',\r\n type: SaveTabColumnType.Date\r\n }\r\n ];\r\n\r\n get tabTitle(): string {\r\n return 'Saved Action Views';\r\n }\r\n\r\n contextMenu(category: SaveCategory, index: number): ContextMenuItem[] {\r\n return category.categoryType === Core.SearchCategoryType.System\r\n ? this._systemActionViewMenu(category, index) : this._customActionViewMenuWithPermissions(category, index);\r\n }\r\n\r\n async getList(): Promise {\r\n if (!this._dirty) {\r\n return;\r\n }\r\n const response = await this._actionViewService.getCategories();\r\n\r\n const categoryList: SaveCategory[] = response.map(x => {\r\n const list: SaveListItem[] = x.actionViewList.map(y => {\r\n return {\r\n id: y.actionViewID,\r\n name: y.actionViewName,\r\n isFavorite: y.isFavorite,\r\n changeDate: y.changeDate,\r\n canFavorite: true,\r\n originalModel: y,\r\n amplitudeEvent: this._getAmplitudeEvent(x, y)\r\n };\r\n });\r\n return {\r\n categoryId: x.categoryId,\r\n categoryName: x.categoryName,\r\n categoryType: x.categoryType,\r\n savedItemList: list\r\n };\r\n });\r\n\r\n this._separateByCategoryType(categoryList);\r\n }\r\n\r\n navigateTo(listItem: SaveListItem, categoryType: number): void {\r\n this._actionViewPersistenceService.clearSavedData();\r\n const params = {\r\n actionViewId: listItem.id,\r\n actionViewType: categoryType,\r\n displayType: listItem.originalModel.defaultDisplay\r\n };\r\n this._router.stateService.transitionTo('actionview', params);\r\n }\r\n\r\n async toggleFavorite(search: SaveListItem): Promise {\r\n this.dirty = true;\r\n this._productAnalyticsService.logEvent('click-act-favorite', { actFavoriteToggle: search.isFavorite ? 'on' : 'off' });\r\n await this._actionViewService.toggleFavorite(search.id, search.isFavorite);\r\n }\r\n\r\n private async _shareActionView(actionViewItem: SaveListItem, searchType: Core.SearchCategoryType): Promise {\r\n // Go update the search to mark it as \"Shared\" if this is a custom search\r\n if (searchType === Core.SearchCategoryType.Custom) {\r\n await this._actionViewService.share(actionViewItem.originalModel);\r\n }\r\n await this.getList();\r\n this._actionViewPersistenceService.clearSavedData();\r\n const params = {\r\n actionViewId: actionViewItem.id,\r\n actionViewType: searchType,\r\n displayType: actionViewItem.originalModel.defaultDisplay\r\n };\r\n const route = this._router.stateService.href('actionview', params, { absolute: true });\r\n this._showEmailWindow(route, actionViewItem.name, 'Action View');\r\n }\r\n\r\n private _systemActionViewMenu(category: SaveCategory, index: number): ContextMenuItem[] {\r\n // User doesn't have permission to edit system action views\r\n if (!this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT)) {\r\n return [];\r\n }\r\n return [\r\n {\r\n name: 'Share',\r\n onClick: (item, searchType) => {\r\n this._shareActionView(item, searchType);\r\n },\r\n isDisabled: () => {\r\n return this._currentSelectedFilter === SearchCategoryType.Favorite;\r\n }\r\n },\r\n {\r\n name: 'Rename',\r\n onClick: (item, actionViewType) => {\r\n this._modalService.showAsync(ActionViewRenameComponent, { actionView: item.originalModel, actionViewType }, 'modal-lg');\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.isSystemSeeded\r\n || this._currentSelectedFilter === SearchCategoryType.Favorite;\r\n }\r\n },\r\n {\r\n name: 'Change Category',\r\n onClick: (item, actionViewType) => {\r\n this._modalService.showAsync(ActionViewCategoryComponent, { actionView: item.originalModel, actionViewType }, 'modal-lg');\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.isSystemSeeded\r\n || this._currentSelectedFilter === SearchCategoryType.Favorite;\r\n }\r\n },\r\n {\r\n name: 'Change Display Type',\r\n onClick: (item, actionViewType) => {\r\n this._modalService.showAsync(ActionViewDefaultDisplayComponent, { actionView: item.originalModel, actionViewType }, 'modal-lg');\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.isSystemSeeded\r\n || this._currentSelectedFilter === SearchCategoryType.Favorite;\r\n }\r\n },\r\n {\r\n name: 'Delete',\r\n onClick: async(item) => {\r\n try {\r\n const favoriteCount = await this._actionViewService.getFavoriteCount(item.originalModel);\r\n let confirmMessage = '';\r\n if (favoriteCount > 0) {\r\n if (favoriteCount === 1) {\r\n confirmMessage = 'WARNING: 1 user currently has this action view favorited.\\n';\r\n }\r\n else {\r\n confirmMessage = `WARNING: ${ favoriteCount } users currently have this action view favorited.\\n`;\r\n }\r\n }\r\n\r\n confirmMessage += `Are you sure you want to delete ${ item.name }?`;\r\n await this._messageModalService.confirm(confirmMessage);\r\n } catch(e) {\r\n return;\r\n }\r\n this.dirty = true;\r\n await this._actionViewService.deleteSystemActionView(item.originalModel);\r\n category.savedItemList.splice(index, 1);\r\n await this.getList();\r\n },\r\n isDisabled: (item) => {\r\n return item.originalModel.isSystemSeeded\r\n || this._currentSelectedFilter === SearchCategoryType.Favorite;\r\n }\r\n }\r\n ];\r\n }\r\n\r\n private _customActionViewMenuWithPermissions(category: SaveCategory, index: number): ContextMenuItem[] {\r\n return [\r\n {\r\n name: 'Share',\r\n onClick: (item, searchType) => {\r\n this._shareActionView(item, searchType);\r\n },\r\n isDisabled: () => {\r\n return false;\r\n }\r\n },\r\n {\r\n name: 'Rename',\r\n onClick: (item, actionViewType) => {\r\n this._modalService.showAsync(ActionViewRenameComponent, { actionView: item.originalModel, actionViewType }, 'modal-lg');\r\n },\r\n isDisabled: () => {\r\n return false;\r\n }\r\n },\r\n {\r\n name: 'Change Category',\r\n onClick: (item, actionViewType) => {\r\n this._modalService.showAsync(ActionViewCategoryComponent, { actionView: item.originalModel, actionViewType }, 'modal-lg');\r\n },\r\n isDisabled: () => {\r\n return false;\r\n }\r\n },\r\n {\r\n name: 'Change Display Type',\r\n onClick: (item, actionViewType) => {\r\n this._modalService.showAsync(ActionViewDefaultDisplayComponent, { actionView: item.originalModel, actionViewType }, 'modal-lg');\r\n },\r\n isDisabled: () => {\r\n return false;\r\n }\r\n },\r\n {\r\n name: 'Delete',\r\n onClick: async(item) => {\r\n try {\r\n const favoriteCount = await this._actionViewService.getFavoriteCount(item.originalModel);\r\n let confirmMessage = '';\r\n if (favoriteCount > 0) {\r\n if (favoriteCount === 1) {\r\n confirmMessage = 'WARNING: 1 user currently has this action view favorited.\\n';\r\n }\r\n else {\r\n confirmMessage = `WARNING: ${ favoriteCount } users currently have this action view favorited.\\n`;\r\n }\r\n }\r\n\r\n confirmMessage += `Are you sure you want to delete ${ item.name }?`;\r\n await this._messageModalService.confirm(confirmMessage);\r\n } catch(e) {\r\n return;\r\n }\r\n this.dirty = true;\r\n await this._actionViewService.deleteCustomActionView(item.originalModel);\r\n category.savedItemList.splice(index, 1);\r\n await this.getList();\r\n },\r\n isDisabled: () => {\r\n return false;\r\n }\r\n }\r\n ];\r\n }\r\n\r\n private _getAmplitudeEvent(category: Core.ActionViewSavedSearchCategoryManagementDTO, av: Core.ActionViewListDTO): AmplitudeEvent {\r\n const event = `click-act-${category.categoryType ? 'saved' : 'system' }`;\r\n let properties: { [key: string]: string };\r\n if (category.categoryType === Core.SearchCategoryType.System) {\r\n properties = { actSystemActionView: category.categoryName };\r\n } else if (av.isFavorite && this._currentSelectedFilter === SearchCategoryType.Favorite) {\r\n properties = { actSystemActionView: 'favorite' };\r\n }\r\n return { event, properties };\r\n }\r\n}\r\n","import { SavedActionViewService } from '../../Navigation/Saved-AV/savedActionView.service';\r\n\r\n(function () {\r\n\t'use strict';\r\n\r\n\tangular\r\n\t\t.module('weissmanApp')\r\n\t\t.controller('SaveActionViewModalController', SaveActionViewModalController);\r\n\r\n\tSaveActionViewModalController.$inject = [\r\n '$uibModalInstance',\r\n 'actionViewService',\r\n 'ActionViewCategoryTypes',\r\n 'ActionViewDisplayTypes',\r\n 'actionViewObj',\r\n 'filterColumns',\r\n 'utils',\r\n '$rootScope',\r\n 'hasEditPermission',\r\n '$state',\r\n 'toastr',\r\n 'userSaveService'\r\n\t];\r\n\r\n\tfunction SaveActionViewModalController() { weissNg1WrapFunc(ng1ControllerInit, arguments, this); }\r\n function ng1ControllerInit($uibModalInstance, actionViewService, ActionViewCategoryTypes, ActionViewDisplayTypes, actionViewObj, filterColumns, utils, $rootScope, hasEditPermission, $state, toastr, userSaveService) {\r\n\t\tvar vm = this;\r\n\t\tvm.selectedDisplayType = 0;\r\n\r\n\t\tvm.actionView = actionViewObj\r\n\t\tvm.actionViewCategories = [];\r\n\t\tvm.displayTypes = ActionViewDisplayTypes;\r\n\t\tvm.hasEditPermission = hasEditPermission;\r\n\r\n\t\tvm.categoryTypes = ActionViewCategoryTypes;\r\n\t\tvm.actionViewTypeFilter = actionViewTypeFilter;\r\n\t\tvm.cancel = cancel;\r\n\t\tvm.saveActionView = saveActionView;\r\n\t\tvm.toggled = toggled;\r\n\t\tvm.createNewCategory = createNewCategory;\r\n\t\tvm.findSystemCategory = findSystemCategory;\r\n\t\tvm.thatAreCompleted = thatAreCompleted;\r\n\t\tvm.actionViewName = '';\r\n\r\n\t\tif (vm.actionView.defaultDisplay) {\r\n\t\t\tvm.selectedDisplayType = vm.actionView.defaultDisplay;\r\n\t\t}\r\n\r\n\r\n\t\tactivate();\r\n\r\n\t\t////////////////\r\n\r\n\t\tfunction activate() {\r\n\t\t\tvm.actionView.type = vm.actionView.type || ActionViewCategoryTypes.CUSTOM;\r\n\t\t\tvm.actionView.categoryId = vm.actionView.categoryId || null;\r\n\r\n\t\t\tactionViewService.getCategories()\r\n\t\t\t\t.then(function (result) {\r\n\r\n\t\t\t\t\tvm.actionViewCategories = _.sortBy(result, x => x.categoryName.toLowerCase());\r\n\t\t\t\t});\r\n\r\n\t\t\tutils.focusOnElement('[ng-model=\"vm.actionView.actionViewName\"]')\r\n\t\t}\r\n\r\n\t\tfunction actionViewTypeFilter(category) {\r\n\t\t\treturn category.categoryType === vm.actionView.type || (!category.categoryId && vm.actionView.type === ActionViewCategoryTypes.CUSTOM);\r\n\t\t}\r\n\r\n\t\tfunction toggled(open) {\r\n\t\t\tif (open) {\r\n\t\t\t\tutils.focusOnElement('#new-action-view-category');\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction findSystemCategory() {\r\n\t\t\tif (!vm.actionView.categoryId) {\r\n\t\t\t\tvar sysCategory = _.find(vm.actionViewCategories, { categoryType: ActionViewCategoryTypes.SYSTEM });\r\n\t\t\t\tif (sysCategory) {\r\n\t\t\t\t\tvm.actionView.categoryId = sysCategory.categoryId;\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction cancel() {\r\n\t\t\t$uibModalInstance.dismiss();\r\n\t\t}\r\n\r\n\t\tfunction createNewCategory() {\r\n\t\t\tif (!vm.newCategory) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\tvm.actionViewCategories.push({\r\n\t\t\t\tcategoryName: vm.newCategory,\r\n\t\t\t\tcategoryType: vm.actionView.type,\r\n\t\t\t\tcategoryId: 'new'\r\n\t\t\t});\r\n\r\n\t\t\tvm.actionViewCategories = _.sortBy(vm.actionViewCategories, x => x.categoryName.toLowerCase())\r\n\r\n\t\t\tvm.actionView.categoryId = 'new';\r\n\r\n\t\t\tvm.categoryEntered = true;\r\n\t\t\tvm.enteringCategory = false;\r\n\r\n\t\t\tutils.focusOnElement('[ng-model=\"vm.actionView.actionViewName\"]')\r\n\t\t}\r\n\r\n\t\tfunction saveActionView() {\r\n\t\t\tvar category = {};\r\n\r\n\t\t\tif (vm.actionView.categoryId === 'new') {\r\n\t\t\t\tcategory = _.find(vm.actionViewCategories, { categoryId: 'new' });\r\n\r\n\t\t\t\tactionViewService.createCategory(_.omit(category, 'categoryId'))\r\n\t\t\t\t\t.then(function (result) {\r\n\t\t\t\t\t\tvm.actionView.categoryId = result.categoryId;\r\n\r\n\t\t\t\t\t\tcreateOrUpdate().then(broadcastAndClose)\r\n\t\t\t\t\t\t\t.catch(errorToast);\r\n\t\t\t\t\t})\r\n\t\t\t\t\t.catch(function (error) {\r\n\t\t\t\t\t\tif (error.status === 409) {\r\n\t\t\t\t\t\t\ttoastr.error('Error!', 'Category already exists.');\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\ttoastr.error('Error!', 'Server Error')\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t})\r\n\t\t\t} else {\r\n\t\t\t\tcreateOrUpdate().then(broadcastAndClose)\r\n\t\t\t\t\t.catch(errorToast);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction broadcastAndClose(savedActionView) {\r\n userSaveService.setDirty(1); //SearchPageType.AV\r\n\t\t\t$rootScope.$broadcast('updateActionViewMenu');\r\n\r\n\t\t\t$state.transitionTo('actionview', { actionViewId: savedActionView.actionViewId, actionViewType: vm.actionView.type }, { reload: true })\r\n\t\t\t$uibModalInstance.close();\r\n\t\t}\r\n\r\n\t\tfunction errorToast(error) {\r\n\t\t\tif (error.status === 409) {\r\n\t\t\t\ttoastr.error('Error!', 'Action View name/category already exists');\r\n\t\t\t} else {\r\n\t\t\t\ttoastr.error('Error!', 'Server Error')\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tfunction createOrUpdate() {\r\n\t\t\tvar selectedCategory = _.find(vm.actionViewCategories, { categoryId: vm.actionView.categoryId});\r\n\t\t\tvar newSequence = (selectedCategory && selectedCategory.actionViewList.length > 0) ? selectedCategory.actionViewList.length : 0;\r\n\r\n\t\t\tvm.actionView.sequence = newSequence;\r\n\t\t\tvm.actionView.defaultDisplay = vm.selectedDisplayType;\r\n\r\n\r\n\t\t\tif (vm.actionView.type === ActionViewCategoryTypes.CUSTOM) {\r\n\t\t\t\treturn actionViewService.createCustomActionView(_.omit(vm.actionView, 'type'), filterColumns);\r\n\t\t\t} else {\r\n\t\t\t\treturn actionViewService.createSystemActionView(_.omit(vm.actionView, 'type'), filterColumns);\r\n\t\t\t}\r\n\r\n\t\t}\r\n\r\n\t\tfunction thatAreCompleted() {\r\n\t\t\treturn actionViewObj.masterFilter.ThatAreChoice === 4;\r\n\t\t}\r\n\t}\r\n})();\r\n","import { Injectable } from '@angular/core';\r\n\r\n/**\r\n * State persistence service between drag item and drop zone\r\n */\r\n@Injectable()\r\nexport class DragAndDropListService {\r\n readonly ALL_EFFECTS = ['move', 'copy', 'link'];\r\n readonly MIME_TYPE = 'application/x-dnd';\r\n readonly EDGE_MIME_TYPE = 'application/json';\r\n readonly MSIE_MIME_TYPE = 'Text';\r\n\r\n private _isDragging: boolean;\r\n private _itemType: string;\r\n private _dropEffect: string;\r\n private _effectAllowed: string;\r\n private _callback: any;\r\n\r\n set isDragging(isDragging: boolean) {\r\n this._isDragging = isDragging;\r\n }\r\n get isDragging(): boolean {\r\n return this._isDragging;\r\n }\r\n\r\n set itemType(itemType: string) {\r\n this._itemType = itemType;\r\n }\r\n get itemType(): string {\r\n return this._itemType;\r\n }\r\n\r\n set dropEffect(dropEffect: string) {\r\n this._dropEffect = dropEffect;\r\n }\r\n get dropEffect(): string {\r\n return this._dropEffect;\r\n }\r\n\r\n set effectAllowed(effectAllowed: string) {\r\n this._effectAllowed = effectAllowed;\r\n }\r\n get effectAllowed(): string {\r\n return this._effectAllowed;\r\n }\r\n\r\n set callback(isDragging: any) {\r\n this._callback = isDragging;\r\n }\r\n get callback(): any {\r\n return this._callback;\r\n }\r\n\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { DragAndDropDraggableDirective, DragAndDropHandleDirective, DragAndDropListDirective, DragAndDropNoDragDirective } from './dragAndDropList.directive';\r\nimport { DragAndDropListService } from './dragAndDropList.service';\r\n\r\n@NgModule({\r\n declarations: [\r\n DragAndDropListDirective,\r\n DragAndDropDraggableDirective,\r\n DragAndDropNoDragDirective,\r\n DragAndDropHandleDirective\r\n ],\r\n providers: [ DragAndDropListService ],\r\n exports: [\r\n DragAndDropListDirective,\r\n DragAndDropDraggableDirective,\r\n DragAndDropNoDragDirective,\r\n DragAndDropHandleDirective\r\n ]\r\n})\r\nexport class DragAndDropListModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ClickOutsideDirective } from './Click-Outside-Directive/clickOutside.directive';\r\nimport { DraggableDirective } from './Draggable/draggable.directive';\r\nimport { AnchorRouteDirective } from './Anchor-Route/anchorRoute.directive';\r\nimport { NumbersOnlyDirective } from './Numbers-Only/numbersOnly.directive';\r\nimport { InputMaskDirective } from './Input-Mask/inputMask.directive';\r\nimport { ResizableDirective } from './Resizable/resizable.directive';\r\nimport { ToPercentDirective } from './To-Percent/toPercent.directive';\r\nimport { LineLimitDirective } from './Line-Limit/lineLimit.directive';\r\nimport { DecimalNumberDirective } from './Decimal-Number-Input/decimal-number-input.directive';\r\nimport { NumberDirective } from './Number-Input/number-input.directive';\r\nimport { DragAndDropListModule } from './Drag-And-Drop-List/dragAndDropList.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n DragAndDropListModule\r\n ],\r\n declarations: [\r\n ClickOutsideDirective,\r\n DraggableDirective,\r\n AnchorRouteDirective,\r\n NumbersOnlyDirective,\r\n InputMaskDirective,\r\n LineLimitDirective,\r\n ResizableDirective,\r\n ToPercentDirective,\r\n DecimalNumberDirective,\r\n NumberDirective\r\n ],\r\n exports: [\r\n ClickOutsideDirective,\r\n DraggableDirective,\r\n AnchorRouteDirective,\r\n NumbersOnlyDirective,\r\n InputMaskDirective,\r\n LineLimitDirective,\r\n ResizableDirective,\r\n ToPercentDirective,\r\n DecimalNumberDirective,\r\n NumberDirective\r\n ]\r\n})\r\nexport class DirectivesModule { }\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanAbsoluteUrlPipe } from './Absolute-Url/absolute.url.pipe';\r\nimport { WeissmanYesNoPipe, WeissmanTrueFalsePipe } from './Boolean/boolean-pipe';\r\nimport { WeissmanDateTimeFormatPipe, WeissmanDateFormatPipe, WeissmanMonthDayDateFormatPipe, CommentDateTimeFormat } from './Date-Format/date-formatting.pipe';\r\nimport { FilterPipe, WeissmanFilterPipe } from './Filter/filter-pipe';\r\nimport { WeissmanKeyValueDisplayPipe } from './Key-Value-Display/keyValueDisplay-pipe';\r\nimport { SortByPipe } from './Order-By/orderBy.pipe';\r\nimport { SplitListPipe } from './Split-List/splitList.pipe';\r\nimport { TimeAgoPipe } from './Time-Ago/timeAgo.pipe';\r\nimport { WeissmanTimeSpanPipe } from './Time-Span/timeSpan.pipe';\r\n\r\n@NgModule({\r\n declarations: [\r\n WeissmanDateTimeFormatPipe,\r\n WeissmanDateFormatPipe,\r\n WeissmanMonthDayDateFormatPipe,\r\n WeissmanYesNoPipe,\r\n WeissmanTrueFalsePipe,\r\n WeissmanKeyValueDisplayPipe,\r\n WeissmanFilterPipe,\r\n WeissmanTimeSpanPipe,\r\n WeissmanAbsoluteUrlPipe,\r\n SortByPipe,\r\n TimeAgoPipe,\r\n FilterPipe,\r\n SplitListPipe,\r\n CommentDateTimeFormat\r\n ],\r\n exports: [\r\n WeissmanDateTimeFormatPipe,\r\n WeissmanDateFormatPipe,\r\n WeissmanMonthDayDateFormatPipe,\r\n WeissmanYesNoPipe,\r\n WeissmanTrueFalsePipe,\r\n WeissmanKeyValueDisplayPipe,\r\n WeissmanFilterPipe,\r\n WeissmanTimeSpanPipe,\r\n WeissmanAbsoluteUrlPipe,\r\n SortByPipe,\r\n TimeAgoPipe,\r\n FilterPipe,\r\n SplitListPipe,\r\n CommentDateTimeFormat\r\n ],\r\n // Allows for use as dependency injection in constructor\r\n providers: [\r\n WeissmanDateTimeFormatPipe,\r\n WeissmanDateFormatPipe,\r\n WeissmanMonthDayDateFormatPipe,\r\n WeissmanYesNoPipe,\r\n WeissmanTrueFalsePipe,\r\n WeissmanKeyValueDisplayPipe,\r\n WeissmanFilterPipe,\r\n WeissmanTimeSpanPipe,\r\n WeissmanAbsoluteUrlPipe,\r\n SortByPipe,\r\n TimeAgoPipe,\r\n FilterPipe,\r\n SplitListPipe,\r\n CommentDateTimeFormat\r\n ]\r\n})\r\nexport class SharedPipesModule { }\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { AceIconComponent } from './icon.component';\r\n\r\n@NgModule({\r\n imports: [CommonModule],\r\n declarations: [AceIconComponent],\r\n exports: [AceIconComponent]\r\n })\r\nexport class AceIconModule {\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\r\nimport { HybridAdapterUtility } from '../../../Hybrid/hybrid-adapter.utility';\r\nimport { AceIconModule } from '../Icon/icon.module';\r\nimport { AceSelectDropdownComponent } from './Select-Dropdown/dropdown.component';\r\nimport { AceSelectComponent } from './select.component';\r\nimport { ReactiveFormsModule, FormsModule } from '@angular/forms';\r\nimport { DirectivesModule } from '../../Directives/directives.module';\r\nimport { AceSelectService } from './select.service';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ReactiveFormsModule,\r\n FormsModule,\r\n DirectivesModule,\r\n BrowserAnimationsModule,\r\n AceIconModule\r\n ],\r\n declarations: [\r\n AceSelectComponent,\r\n AceSelectDropdownComponent\r\n ],\r\n providers: [AceSelectService],\r\n exports: [\r\n AceSelectComponent,\r\n AceSelectDropdownComponent\r\n ]\r\n})\r\nexport class AceSelectModule {\r\n static setupModule(): void {\r\n hybridAdapterUtility.downgradeNg2Component('aceSelect', AceSelectComponent);\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { getByPath } from '@ace/shared';\r\nimport { ISimpleTableColumnDefinition } from '../simpleTable.component';\r\n\r\n@Component({\r\n selector: 'ws-ace-simple-table-cell',\r\n templateUrl: './simpleTableCell.component.html',\r\n styleUrls: ['./simpleTableCell.component.scss']\r\n})\r\nexport class AceSimpleTableCellComponent implements OnInit {\r\n @Input() row: object;\r\n @Input() col: ISimpleTableColumnDefinition;\r\n\r\n content: string;\r\n\r\n ngOnInit(): void {\r\n this.content = getByPath(this.row, this.col.field);\r\n }\r\n}\r\n","\r\n \r\n {{ col.headerName }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","{{ content }}\r\n","import { AfterViewInit, Component, Input, OnInit } from '@angular/core';\r\n\r\nexport interface ISimpleTableColumnDefinition {\r\n /** A unique identifier for this column, which is also a dottable path into the row item to find the display value */\r\n field: string;\r\n\r\n /** Text to display in this column's header */\r\n headerName: string;\r\n}\r\n\r\n/**\r\n * Input for SimpleTable element\r\n * @template TItem The type of model used for this element's items\r\n */\r\nexport interface ISimpleTableInput {\r\n /** The rows to display */\r\n rows: TItem[];\r\n\r\n /** (optional) Rows to display in the footer. Default: no footer rows */\r\n footerRows?: TItem[];\r\n\r\n /** The columns to display */\r\n columns: ISimpleTableColumnDefinition[];\r\n}\r\n\r\n@Component({\r\n selector: 'ace-simple-table',\r\n templateUrl: './simpleTable.component.html',\r\n styleUrls: ['./simpleTable.component.scss']\r\n})\r\nexport class AceSimpleTableComponent {\r\n @Input() input: ISimpleTableInput;\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { AceSimpleTableCellComponent } from './Simple-Table-Cell/simpleTableCell.component';\r\nimport { AceSimpleTableComponent } from './simpleTable.component';\r\n\r\n@NgModule({\r\n imports: [CommonModule],\r\n declarations: [\r\n AceSimpleTableCellComponent,\r\n AceSimpleTableComponent\r\n ],\r\n exports: [\r\n AceSimpleTableComponent\r\n ]\r\n})\r\nexport class AceSimpleTableModule {\r\n\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { UIRouterUpgradeModule } from '@uirouter/angular-hybrid';\r\nimport { AceIconModule } from '../Icon/icon.module';\r\nimport { AceTabComponent } from './Tab/tab.component';\r\nimport { AceTabsComponent } from './Tabs/tabs.component';\r\nimport { AceTabSetComponent } from './tabSet.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n AceIconModule,\r\n UIRouterUpgradeModule\r\n ],\r\n declarations: [\r\n AceTabComponent,\r\n AceTabsComponent,\r\n AceTabSetComponent\r\n ],\r\n exports: [\r\n AceTabSetComponent\r\n ]\r\n})\r\nexport class AceTabSetModule {}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { DirectivesModule } from '../Directives/directives.module';\r\nimport { SharedPipesModule } from '../Pipes/shared-pipes.module';\r\nimport { AceBadgeComponent } from './Badge/badge.component';\r\nimport { AceBannerComponent } from './Banner/banner.component';\r\nimport { AceButtonGroupComponent } from './Button-Group/buttonGroup.component';\r\nimport { AceButtonComponent } from './Button/button.component';\r\nimport { AceDropdownComponent } from './Dropdown/dropdown.component';\r\nimport { AceIconComponent } from './Icon/icon.component';\r\nimport { AceIconModule } from './Icon/icon.module';\r\nimport { AceLoaderComponent } from './Loader/loader.component';\r\nimport { AceSelectComponent } from './Select/select.component';\r\nimport { AceSelectModule } from './Select/select.module';\r\nimport { AceSimpleTableComponent } from './Simple-Table/simpleTable.component';\r\nimport { AceSimpleTableModule } from './Simple-Table/simpleTable.module';\r\nimport { AceTabSetComponent } from './Tab-Set/tabSet.component';\r\nimport { AceTabSetModule } from './Tab-Set/tabSet.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n DirectivesModule,\r\n SharedPipesModule,\r\n AceSelectModule,\r\n AceIconModule,\r\n AceTabSetModule,\r\n AceSimpleTableModule\r\n ],\r\n declarations: [\r\n AceBadgeComponent,\r\n AceBannerComponent,\r\n AceButtonComponent,\r\n AceButtonGroupComponent,\r\n AceDropdownComponent,\r\n AceLoaderComponent,\r\n ],\r\n exports: [\r\n AceBadgeComponent,\r\n AceBannerComponent,\r\n AceButtonComponent,\r\n AceButtonGroupComponent,\r\n AceDropdownComponent,\r\n AceIconComponent,\r\n AceLoaderComponent,\r\n AceSelectComponent,\r\n AceSimpleTableComponent,\r\n AceTabSetComponent\r\n ]\r\n})\r\nexport class AceModule {\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{content}}\r\n\r\n","import { AceUIIcon, BadgeState, IconFontStyle } from '@ace/shared';\r\nimport { Component, HostBinding, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'ws-ace-badge',\r\n templateUrl: './badge.component.html',\r\n styleUrls: ['./badge.component.scss']\r\n})\r\nexport class AceBadgeComponent {\r\n @Input() content: string;\r\n @Input() icon: AceUIIcon | string;\r\n @Input() iconFont: IconFontStyle | IconFontStyle[] | string;\r\n @Input() iconSlot: string = 'icon';\r\n\r\n @HostBinding('attr.size')\r\n @Input() size: 'default' | 'small';\r\n\r\n @HostBinding('attr.badge-state')\r\n @Input() badgeState: BadgeState | string;\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ReactiveFormsModule, FormsModule } from '@angular/forms';\r\nimport { DirectivesModule } from '../Directives/directives.module';\r\nimport { CurrencyInputComponent } from './currencyInput.component';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ReactiveFormsModule,\r\n FormsModule,\r\n CurrencyMaskModule,\r\n DirectivesModule\r\n ],\r\n declarations: [\r\n CurrencyInputComponent\r\n ],\r\n exports: [\r\n CurrencyInputComponent\r\n ]\r\n})\r\nexport class CurrencyModule { }\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { LoadingSpinnerComponent } from './loadingSpinner.component';\r\n\r\n@NgModule({\r\n imports: [CommonModule],\r\n declarations: [LoadingSpinnerComponent],\r\n exports: [LoadingSpinnerComponent]\r\n})\r\nexport class LoadingSpinnerModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { SelectComponent } from './select.component';\r\nimport { ReactiveFormsModule, FormsModule } from '@angular/forms';\r\nimport { DirectivesModule } from '../Directives/directives.module';\r\nimport { SelectDropdownComponent } from './Dropdown/selectDropdown.component';\r\nimport { SelectService } from './select.service';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ReactiveFormsModule,\r\n FormsModule,\r\n DirectivesModule,\r\n BrowserAnimationsModule\r\n ],\r\n declarations: [\r\n SelectComponent,\r\n SelectDropdownComponent\r\n ],\r\n providers: [SelectService],\r\n exports: [\r\n SelectComponent\r\n ]\r\n})\r\nexport class SelectModule {\r\n static setupModule(): void {\r\n hybridAdapterUtility.downgradeNg2Component('wsSelect', SelectComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { AceModule } from '../ACE/ace.module';\r\nimport { LoadingSpinnerModule } from '../Loading-Spinner/loadingSpinner.module';\r\nimport { ModalWrapperComponent } from './modalWrapper.component';\r\nimport { DirectivesModule } from '../Directives/directives.module';\r\nimport { HelpModule } from '../Help-Tooltip/help.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n DirectivesModule,\r\n HelpModule,\r\n AceModule,\r\n LoadingSpinnerModule\r\n ],\r\n declarations: [\r\n ModalWrapperComponent\r\n ],\r\n exports: [\r\n ModalWrapperComponent\r\n ]\r\n})\r\nexport class ModalWrapperModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ReactiveFormsModule, FormsModule } from '@angular/forms';\r\nimport { TriStateCheckboxComponent } from './triStateCheckbox.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ReactiveFormsModule,\r\n FormsModule,\r\n ],\r\n declarations: [\r\n TriStateCheckboxComponent\r\n ],\r\n exports: [\r\n TriStateCheckboxComponent\r\n ]\r\n})\r\nexport class TriStateCheckboxModule {\r\n}\r\n","
    \r\n
  • \r\n \r\n {{config.deselectLabel}}\r\n \r\n
  • \r\n
  • \r\n \r\n {{((config.isPrimitive) ? option : option[config.typeaheadOptionField])}}\r\n \r\n
  • \r\n
\r\n","import { Component, ChangeDetectorRef, Input, Output, ViewChild, ElementRef, EventEmitter, HostListener } from '@angular/core';\r\nimport {\r\n trigger,\r\n state,\r\n style,\r\n animate,\r\n transition\r\n} from '@angular/animations';\r\nimport { DropdownPosition } from '../Select/select.interface';\r\nimport { Subject } from 'rxjs';\r\nimport { TypeaheadConfig } from './typeahead.service';\r\n\r\n@Component({\r\n selector: 'ws-typeahead-component',\r\n templateUrl: './typeahead.component.html',\r\n styleUrls: ['./typeahead.component.scss'],\r\n animations: [\r\n trigger('dropdownVisible', [\r\n state('show', style({\r\n height: '*'\r\n })),\r\n state('hide', style({\r\n height: '0'\r\n })),\r\n transition('show => hide', animate('200ms ease')),\r\n transition('hide => show', animate('200ms ease'))\r\n ])\r\n ]\r\n})\r\nexport class TypeaheadComponent {\r\n constructor(private readonly _changDetectorRef: ChangeDetectorRef) { }\r\n\r\n @Input()\r\n set typeaheadConfig(config: TypeaheadConfig) {\r\n this.config = config;\r\n }\r\n\r\n @Input()\r\n set targetPosition(target: DOMRect) {\r\n this._targetPosition = target;\r\n this.updateDropdownPosition();\r\n }\r\n\r\n @Input()\r\n set isOpen(open: boolean) {\r\n this.open = open;\r\n }\r\n\r\n @Output() closed = new EventEmitter();\r\n\r\n @ViewChild('dropdown') dropdown: ElementRef;\r\n\r\n config: TypeaheadConfig;\r\n open: boolean;\r\n searchValue: string;\r\n dropdownPosition: DropdownPosition;\r\n listValues: any[] = [];\r\n\r\n private _targetPosition: DOMRect;\r\n private _edgeBuffer = 10;\r\n private _destroy$: Subject = new Subject();\r\n\r\n @HostListener('window:scroll') onWindowScroll(): void {\r\n this.updateDropdownPosition();\r\n }\r\n\r\n @HostListener('window:resize') onResize(): void {\r\n this.updateDropdownPosition();\r\n }\r\n\r\n /**\r\n * Update the position of the dropdown\r\n */\r\n updateDropdownPosition() {\r\n // Pre-render to calculate right edge detection accurately\r\n this.dropdownPosition = {\r\n left: `${window.innerWidth / 2 - 130}px`,\r\n top: '10px',\r\n width: `${this._targetPosition.width}px`\r\n };\r\n this._changDetectorRef.detectChanges();\r\n\r\n // Calculate actual position\r\n const boundingBox = this.dropdown.nativeElement.getBoundingClientRect();\r\n\r\n const top = this._targetPosition.y + this._targetPosition.height + window.scrollY;\r\n const left = this._targetPosition.x;\r\n\r\n const buffer = this._getBuffer(boundingBox, top, left);\r\n\r\n if (buffer.topBuffer < 0) {\r\n // TODO handle bottom up\r\n }\r\n\r\n this.dropdownPosition = {\r\n left: `${left + buffer.leftBuffer}px`,\r\n top: `${top}px`,\r\n width: `${this._targetPosition.width}px`\r\n };\r\n this._changDetectorRef.detectChanges();\r\n }\r\n\r\n /**\r\n * Emit selected option\r\n * @param option\r\n */\r\n optionSelected(option: any): boolean {\r\n if (option && option[this.config.disabledProperty]) {\r\n return false;\r\n }\r\n\r\n if (this.config.selectedOption !== option) {\r\n this.config.selectedOption = option;\r\n this.config.selectedOptionChanged(option);\r\n }\r\n\r\n this._destroy$.next();\r\n this.closed.emit(this.config);\r\n // prevent event propagation\r\n return false;\r\n }\r\n\r\n /**\r\n * Close the dropdown\r\n */\r\n closeDropdown(): void {\r\n if (!this.config.focused) {\r\n this._destroy$.next();\r\n this.closed.emit(this.config);\r\n }\r\n }\r\n\r\n /**\r\n * Check distance to edge of screen\r\n * @param element\r\n * @param idealTop\r\n * @param idealLeft\r\n */\r\n private _getBuffer(element: DOMRect, idealTop: number, idealLeft: number): any {\r\n const wY = window.innerHeight;\r\n const wX = window.innerWidth;\r\n const closestXEdgeDistance = (idealLeft < (wX - (idealLeft + element.width))) ? idealLeft : (wX - (idealLeft + element.width));\r\n const closestYEdgeDistance = (idealTop < (wY - (idealTop + element.height))) ? idealTop : (wY - (idealTop + element.height));\r\n const isXAdditive = idealLeft < (wX - (idealLeft + element.width));\r\n const isYAdditive = idealTop < (wY - (idealTop + element.height));\r\n\r\n let xBuffer = 0;\r\n if (closestXEdgeDistance < this._edgeBuffer) {\r\n xBuffer = this._edgeBuffer - closestXEdgeDistance;\r\n xBuffer = (isXAdditive) ? xBuffer : -xBuffer;\r\n }\r\n let yBuffer = 0;\r\n if (closestYEdgeDistance < this._edgeBuffer) {\r\n yBuffer = this._edgeBuffer - closestYEdgeDistance;\r\n yBuffer = (isYAdditive) ? yBuffer : -yBuffer;\r\n }\r\n\r\n return {\r\n leftBuffer: xBuffer,\r\n topBuffer: yBuffer,\r\n pointerXBuffer: xBuffer + 12,\r\n pointerYBuffer: yBuffer + 12,\r\n };\r\n }\r\n}\r\n","import { Injectable, ComponentFactoryResolver, Injector, ComponentRef, EmbeddedViewRef } from '@angular/core';\r\nimport { TypeaheadComponent } from './typeahead.component';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { TimerService } from '../Utilities/timer.service';\r\n\r\nexport interface TypeaheadConfig {\r\n [options: string]: any;\r\n focused: boolean;\r\n values: any[];\r\n selectedOption: any;\r\n selectedOptionChanged: (option: any) => void;\r\n}\r\n\r\n@Injectable()\r\nexport class TypeaheadService {\r\n constructor(\r\n private readonly _componentFactoryResolver: ComponentFactoryResolver,\r\n private readonly _injector: Injector,\r\n private readonly _timer: TimerService\r\n ) { }\r\n\r\n dropdownActive: boolean;\r\n\r\n private _dropdownRef: ComponentRef;\r\n private _dropdown: HTMLElement;\r\n\r\n private _currentDropdown: TypeaheadConfig;\r\n\r\n private _targetBounds: DOMRect;\r\n private _closingInterval;\r\n private _destroy$: Subject = new Subject();\r\n\r\n /**\r\n * Open the dropdown\r\n * @param config\r\n * @param position\r\n */\r\n openDropdown(config: TypeaheadConfig, position: DOMRect): void {\r\n if (this._currentDropdown) {\r\n this._hideDropdown(() => {\r\n this._currentDropdown = config;\r\n this._targetBounds = position;\r\n this._showDropdown();\r\n });\r\n } else {\r\n this._currentDropdown = config;\r\n this._targetBounds = position;\r\n this._showDropdown();\r\n }\r\n }\r\n\r\n /**\r\n * Close the dropdown\r\n */\r\n closeDropdown(config: TypeaheadConfig): void {\r\n if (config === this._currentDropdown) {\r\n this._hideDropdown(() => this._currentDropdown = null);\r\n }\r\n }\r\n\r\n /**\r\n * Update the position for scroll and resize events\r\n */\r\n update(selectConfig: TypeaheadConfig, position: DOMRect): void {\r\n if (this._currentDropdown === selectConfig) {\r\n this._dropdownRef.instance.typeaheadConfig = this._currentDropdown;\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n\r\n this._targetBounds = position;\r\n this._dropdownRef.instance.targetPosition = this._targetBounds;\r\n\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n }\r\n }\r\n\r\n /**\r\n * Reset the dropdown component values\r\n */\r\n resetDropdown(): void {\r\n this._currentDropdown = null;\r\n this._dropdownRef.instance.targetPosition = {\r\n bottom: 0,\r\n top: 0,\r\n left: 0,\r\n right: 0,\r\n height: 0,\r\n width: 0,\r\n x: 260, // allows left pre-render for positioning calculations\r\n y: 0,\r\n toJSON: null\r\n };\r\n\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n }\r\n\r\n /**\r\n * Update the dropdown with new values\r\n */\r\n private _showDropdown(): void {\r\n if (!this.dropdownActive) {\r\n if (!this._dropdown) {\r\n this._createDropdown();\r\n }\r\n this.dropdownActive = true;\r\n document.body.appendChild(this._dropdown);\r\n }\r\n\r\n // Init blank component\r\n this._dropdownRef.instance.typeaheadConfig = this._currentDropdown;\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n\r\n this._dropdownRef.instance.targetPosition = this._targetBounds;\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n\r\n this._dropdownRef.instance.isOpen = true;\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n\r\n this._dropdownRef.instance.closed\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe((config) => {\r\n return config === this._currentDropdown && this._hideDropdown();\r\n });\r\n }\r\n\r\n private _hideDropdown(callback?: any): void {\r\n this._dropdownRef.instance.isOpen = false;\r\n this._destroy$.next();\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n\r\n if (this._closingInterval) {\r\n clearTimeout(this._closingInterval);\r\n }\r\n this._closingInterval = this._timer.setTimeout(() => {\r\n this.resetDropdown();\r\n if (callback) {\r\n callback();\r\n }\r\n if (document.body.contains(this._dropdown)) {\r\n document.body.removeChild(this._dropdown);\r\n this.dropdownActive = false;\r\n }\r\n this._closingInterval = null;\r\n }, 200);\r\n }\r\n\r\n /**\r\n * Create the dropdown DOM element\r\n */\r\n private _createDropdown(): void {\r\n const componentFactory = this._componentFactoryResolver.resolveComponentFactory(TypeaheadComponent);\r\n this._dropdownRef = componentFactory.create(this._injector);\r\n\r\n this._dropdown = (this._dropdownRef.hostView as EmbeddedViewRef).rootNodes[0] as HTMLElement;\r\n this._dropdownRef.changeDetectorRef.detectChanges();\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\r\nimport { TypeaheadComponent } from './typeahead.component';\r\nimport { TypeaheadDirective } from './typeahead.directive';\r\nimport { TypeaheadService } from './typeahead.service';\r\nimport { DirectivesModule } from '../Directives/directives.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n BrowserAnimationsModule,\r\n DirectivesModule\r\n ],\r\n declarations: [\r\n TypeaheadComponent,\r\n TypeaheadDirective\r\n ],\r\n providers: [TypeaheadService],\r\n exports: [TypeaheadDirective]\r\n})\r\nexport class WsTypeaheadModule { }\r\n","import { Directive, Input, OnInit, Renderer2, ElementRef, HostListener } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\n\r\nexport interface AnchorSREF {\r\n target: string;\r\n options: {[option: string]: any}\r\n}\r\n\r\n/**\r\n *\r\n * Anchor Route Directive\r\n *\r\n * Provides a way to use anchor tags with the router so that right click and Ctrl click works\r\n * to open in new tabs.\r\n *\r\n * example usage:\r\n *\r\n * Go to Company \"\r\n *\r\n */\r\n@Directive({\r\n selector: '[anchor-route]'\r\n})\r\nexport class AnchorRouteDirective implements OnInit {\r\n constructor(\r\n private readonly _routerService: UIRouter,\r\n private readonly _renderer: Renderer2,\r\n private readonly _elementRef: ElementRef\r\n ) { }\r\n\r\n @Input() isTargetBlank: boolean;\r\n @Input()\r\n set sref(sref: AnchorSREF) {\r\n this._sref = sref;\r\n if (this._initialized) {\r\n this._createHREF();\r\n }\r\n }\r\n\r\n private _href: string;\r\n private _sref: AnchorSREF;\r\n private _initialized: boolean;\r\n\r\n /**\r\n * Listen for click to route to new page\r\n *\r\n * @param e\r\n */\r\n @HostListener('click', ['$event'])\r\n click(e: MouseEvent) {\r\n\r\n // Prevent the href from doing any navigation on click\r\n e.preventDefault();\r\n\r\n if (!this._sref) { return; }\r\n\r\n if (e.ctrlKey || this.isTargetBlank) {\r\n // Ctrl click opens in new tab\r\n window.open(this._href, '_blank');\r\n } else {\r\n this._routerService.stateService.transitionTo(this._sref.target, this._sref.options);\r\n }\r\n }\r\n\r\n ngOnInit(): void {\r\n this._createHREF();\r\n this._initialized = true;\r\n }\r\n\r\n private _createHREF(): void {\r\n if (this._sref) {\r\n // Create the href dynamically for right-click menu to open in new tab\r\n this._href = this._routerService.stateService.href(this._sref.target, this._sref.options, { absolute: true });\r\n this._renderer.setAttribute(this._elementRef.nativeElement, 'href', this._href);\r\n }\r\n }\r\n}\r\n","
\r\n
    \r\n
  1. \r\n {{ crumb.name }}\r\n
  2. \r\n
  3. {{ currentPageTitle }}
  4. \r\n
\r\n
\r\n","import { Component, Input } from '@angular/core';\r\nimport { AnchorSREF } from '../Directives/Anchor-Route/anchorRoute.directive';\r\n\r\nexport interface BreadCrumb extends AnchorSREF {\r\n name: string;\r\n}\r\n\r\n@Component({\r\n selector: 'ws-bread-crumbs',\r\n templateUrl: './breadCrumbs.component.html',\r\n styleUrls: ['./breadCrumbs.component.scss']\r\n})\r\nexport class BreadCrumbsComponent {\r\n @Input() breadcrumbs: BreadCrumb[];\r\n @Input() currentPageTitle: string;\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

{{ panelTitle }}

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n","import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';\r\n\r\nenum WeissmanPanelViewEnum {\r\n Display = 'DISPLAY',\r\n Edit = 'EDIT'\r\n}\r\n\r\n@Component({\r\n selector: 'weissman-panel',\r\n templateUrl: './weissmanPanel.component.html'\r\n})\r\nexport class WeissmanPanelComponent implements OnInit {\r\n\r\n @Input() panelId: string;\r\n @Input() panelTitle: string;\r\n @Input() panelClass: string;\r\n @Input() panelIconClass: string;\r\n\r\n @Input() canExpand: boolean;\r\n @Input() canCollapse: boolean;\r\n @Input() isExpanded: boolean;\r\n\r\n @Input() supportsMultipleViews: boolean;\r\n @Input() view: WeissmanPanelViewEnum;\r\n\r\n @Input() canActivateDisplayView: () => Promise;\r\n @Input() canActivateEditView: () => Promise;\r\n @Input() canDeactivateDisplayView: () => Promise;\r\n @Input() canDeactivateEditView: () => Promise;\r\n\r\n @Input() onEdit: () => Promise;\r\n @Input() onCancel: () => Promise;\r\n @Input() onSave: () => Promise;\r\n\r\n @Output() expandedToggle: EventEmitter = new EventEmitter();\r\n\r\n ngOnInit(): void {\r\n this._setDefaultParameters();\r\n }\r\n\r\n toggleIsExpanded(): void {\r\n this.isExpanded = !this.isExpanded;\r\n this.expandedToggle.emit(this.isExpanded);\r\n }\r\n\r\n async edit(): Promise {\r\n try {\r\n const actionCheck = this.onEdit ? this.onEdit() : Promise.resolve(true);\r\n const actionCheckResult = await actionCheck;\r\n if (!actionCheckResult) return Promise.resolve(false);\r\n } catch(ex) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const canNavigateTo = await this._canNavigateTo(\r\n this.canDeactivateDisplayView ? this.canDeactivateDisplayView() : Promise.resolve(true),\r\n this.canActivateEditView ? this.canActivateEditView() : Promise.resolve(true)\r\n );\r\n\r\n if (canNavigateTo) {\r\n this.view = WeissmanPanelViewEnum.Edit;\r\n }\r\n }\r\n\r\n async cancel(): Promise {\r\n try {\r\n const actionCheck = this.onCancel ? this.onCancel() : Promise.resolve(true);\r\n const actionCheckResult = await actionCheck;\r\n if (!actionCheckResult) return Promise.resolve(false);\r\n } catch(ex) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const canNavigateTo = await this._canNavigateTo(\r\n this.canDeactivateEditView ? this.canDeactivateEditView() : Promise.resolve(true),\r\n this.canActivateDisplayView ? this.canActivateDisplayView() : Promise.resolve(true)\r\n );\r\n\r\n if (canNavigateTo) {\r\n this.view = WeissmanPanelViewEnum.Display;\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n try {\r\n const actionCheck = this.onSave ? this.onSave() : Promise.resolve(true);\r\n const actionCheckResult = await actionCheck;\r\n if (!actionCheckResult) return Promise.resolve(false);\r\n } catch(ex) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const canNavigateTo = await this._canNavigateTo(\r\n this.canDeactivateEditView ? this.canDeactivateEditView() : Promise.resolve(true),\r\n this.canActivateDisplayView ? this.canActivateDisplayView() : Promise.resolve(true),\r\n );\r\n if (canNavigateTo) {\r\n this.view = WeissmanPanelViewEnum.Display;\r\n }\r\n }\r\n\r\n private _setDefaultParameters(): void {\r\n if (this.canExpand === undefined) this.canExpand = true;\r\n if (this.canCollapse === undefined) this.canCollapse = true;\r\n if (this.isExpanded === undefined) this.isExpanded = true;\r\n if (this.supportsMultipleViews === undefined) this.supportsMultipleViews = false;\r\n if (this.view === undefined) this.view = WeissmanPanelViewEnum.Display;\r\n }\r\n\r\n private async _canNavigateTo(deactivatePromise: Promise, activatePromise: Promise): Promise {\r\n try {\r\n const canDeactivate = await deactivatePromise;\r\n if (!canDeactivate) return Promise.resolve(false);\r\n } catch(ex) {\r\n return Promise.resolve(false);\r\n }\r\n try {\r\n const canActivate = await activatePromise;\r\n if (!canActivate) return Promise.resolve(false);\r\n } catch(ex) {\r\n return Promise.resolve(false);\r\n }\r\n return Promise.resolve(true);\r\n }\r\n}","import { NgModule } from '@angular/core';\r\nimport { CommonModule, NgOptimizedImage } from '@angular/common';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { NgxFileDropModule } from 'ngx-file-drop';\r\nimport { AceModule } from './ACE/ace.module';\r\nimport { AceBadgeComponent } from './ACE/Badge/badge.component';\r\nimport { CarouselComponent } from './Carousel/carousel.component';\r\nimport { CurrencyModule } from './Currency/currency.module';\r\nimport { DirectivesModule } from './Directives/directives.module';\r\nimport { SharedPipesModule } from './Pipes/shared-pipes.module';\r\nimport { HelpModule } from './Help-Tooltip/help.module';\r\nimport { LoadingSpinnerModule } from './Loading-Spinner/loadingSpinner.module';\r\nimport { SelectModule } from './Select/select.module';\r\nimport { ModalWrapperModule } from './Modal-Wrapper/modalWrapper.module';\r\nimport { TriStateCheckboxModule } from './Tri-State-Checkbox/triStateCheckbox.module';\r\nimport { WsTypeaheadModule } from './Typeahead/typeahead.module';\r\nimport { BreadCrumbsComponent } from './Bread-Crumb/breadCrumbs.component';\r\nimport { BulkUpdateActionComponent } from './Bulk-Update/Update-Action/bulkUpdateAction.component';\r\nimport { ParentheticalCurrencyComponent } from './Currency/parenthetical-currency.component';\r\nimport { FilePickerComponent } from './FilePicker/filePicker.component';\r\nimport { MultiSelectComponent } from './Multi-Select/multiSelect.component';\r\nimport { PicklistComponent } from './Picklist/picklist.component';\r\nimport { SwitchComponent } from './Switch/switch.component';\r\nimport { WeissmanDatetimeComponent } from './Weiss-Datepicker/weissman-datetime.component';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanPanelComponent } from './Weissman-Panel/weissmanPanel.component';\r\nimport { PanelChevronComponent } from './Weissman-Panel/panel.chevron.component';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n NgOptimizedImage,\r\n NgxFileDropModule,\r\n CurrencyModule,\r\n DirectivesModule,\r\n SharedPipesModule,\r\n HelpModule,\r\n LoadingSpinnerModule,\r\n ModalWrapperModule,\r\n SelectModule,\r\n TriStateCheckboxModule,\r\n WsTypeaheadModule,\r\n AceModule\r\n ],\r\n declarations: [\r\n BreadCrumbsComponent,\r\n BulkUpdateActionComponent,\r\n ParentheticalCurrencyComponent,\r\n FilePickerComponent,\r\n MultiSelectComponent,\r\n PicklistComponent,\r\n SwitchComponent,\r\n WeissmanDatetimeComponent,\r\n WeissmanPanelComponent,\r\n PanelChevronComponent,\r\n CarouselComponent\r\n ],\r\n exports: [\r\n // Modules\r\n CurrencyModule,\r\n DirectivesModule,\r\n SharedPipesModule,\r\n HelpModule,\r\n LoadingSpinnerModule,\r\n ModalWrapperModule,\r\n SelectModule,\r\n TriStateCheckboxModule,\r\n WsTypeaheadModule,\r\n AceModule,\r\n // Components\r\n BreadCrumbsComponent,\r\n BulkUpdateActionComponent,\r\n ParentheticalCurrencyComponent,\r\n FilePickerComponent,\r\n MultiSelectComponent,\r\n PicklistComponent,\r\n SwitchComponent,\r\n WeissmanDatetimeComponent,\r\n WeissmanPanelComponent,\r\n PanelChevronComponent,\r\n CarouselComponent\r\n ]\r\n})\r\nexport class UILibModule {\r\n static setupModule(): void {\r\n SelectModule.setupModule();\r\n HelpModule.setupModule();\r\n hybridAdapterUtility.downgradeNg2Component('weissmanDatetime', WeissmanDatetimeComponent);\r\n hybridAdapterUtility.downgradeNg2Component('weissmanPanel', WeissmanPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Component('wsBreadCrumbs', BreadCrumbsComponent);\r\n hybridAdapterUtility.downgradeNg2Component('wsAceBadge', AceBadgeComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { ModalModule } from 'ngx-bootstrap/modal';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator/busyIndicator.module';\r\nimport { AgGridCheckboxCellRendererComponent } from './CellRenderers/agGridCheckboxCellRender.component';\r\nimport { AgGridLinkCellRendererComponent } from './CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AgGridFilterToggleComponent } from './FilterToggle/agGridFilterToggle.component';\r\nimport { AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer } from './MultiSelectTracker';\r\nimport { AgGridLayoutSpecificationComponent } from './ToolPanel/LayoutSpecification/agGridLayoutSpecification.component';\r\nimport {\r\n AgGridCurrentLayoutAppliedComponent\r\n} from './ToolPanel/LayoutSpecification/CurrentLayoutApplied/agGridCurrentLayoutApplied.component';\r\nimport { AgGridLayoutSpecificationDetailsComponent } from './ToolPanel/LayoutSpecification/Details/agGridLayoutSpecificationDetails.component';\r\nimport { AgGridToolPanelComponent } from './ToolPanel/agGridToolPanel.component';\r\nimport { AgGridToolPanelColumnsComponent } from './ToolPanel/Columns/agGridToolPanelColumns.component';\r\nimport { HelpModule } from '../../UI-Lib/Help-Tooltip/help.module';\r\nimport { AgGridDatepickerCellEditorComponent } from './CellEditors/agGridDatePickerCellEditor.component';\r\nimport { AgGridDropdownCellEditorComponent } from './CellEditors/agGridDropdownCellEditor.component';\r\nimport { SelectModule } from '../../UI-Lib/Select/select.module';\r\nimport { AgGridNumberCellEditorComponent } from './CellEditors/agGridNumberCellEditor.component';\r\nimport { AgGridCurrencyCellEditorComponent } from './CellEditors/agGridCurrencyCellEditor.component';\r\nimport { AgGridTextCellEditorComponent } from './CellEditors/agGridTextCellEditor.component';\r\nimport { AgGridTooltipCellRendererComponent } from './CellRenderers/agGridTooltipCellRenderer.component';\r\nimport { AgGridRowCountComponent } from './Row-Count/agGridRowCount.component';\r\nimport { AgGridTextFilterComponent } from './Filters/Text/agGridTextFilter.component';\r\nimport { AgGridTextFloatingFilterComponent } from './FloatingFilters/agGridTextFloatingFilter.component';\r\nimport { AgGridNumberFilterComponent } from './Filters/Number/agGridNumberFilter.component';\r\nimport { AgGridNumberFloatingFilterComponent } from './FloatingFilters/agGridNumberFloatingFilter.component';\r\nimport { DirectivesModule } from '../../UI-Lib/Directives/directives.module';\r\nimport { AgGridDateFloatingFilterComponent } from './FloatingFilters/agGridDateFloatingFilter.component';\r\nimport { TriStateCheckboxModule } from '../../UI-Lib/Tri-State-Checkbox/triStateCheckbox.module';\r\nimport { DateFilterPickerInstanceComponent } from './Filters/Date/dateFilterPickerInstance.component';\r\nimport { AgGridDateFilterComponent } from './Filters/Date/agGridDateFilter.component';\r\nimport { AgGridHeaderCellRendererComponent } from './ColumnHeader/agGridHeaderCellRenderer.component';\r\nimport { AgGridHeaderLegendTooltipComponent } from './ColumnHeader/agGridHeaderLegendTooltip.component';\r\nimport { AgGridYesNoFloatingFilterComponent } from './FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport { AgGridTextWithTotalsUpdateCellRendererComponent } from './CellRenderers/agGridTextWithTotalsUpdateCellRenderer.component';\r\nimport { AgGridPersistenceService } from './agGridPersistence.service';\r\nimport { AgGridYesNoFilterComponent } from './Filters/YesNo/agGridYesNoFilter.component';\r\nimport { AgGridActionCellRendererComponent } from './CellRenderers/agGridActionCellRenderer.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n BsDropdownModule,\r\n BusyIndicatorModule.forRoot(),\r\n ModalModule,\r\n PopoverModule,\r\n HelpModule,\r\n SelectModule,\r\n DirectivesModule,\r\n TriStateCheckboxModule\r\n ],\r\n declarations: [\r\n AgGridLayoutSpecificationComponent,\r\n AgGridLayoutSpecificationDetailsComponent,\r\n AgGridToolPanelComponent,\r\n AgGridToolPanelColumnsComponent,\r\n AgGridCheckboxCellRendererComponent,\r\n AgGridFilterToggleComponent,\r\n AgGridRowCountComponent,\r\n AgGridDatepickerCellEditorComponent,\r\n AgGridDatepickerCellEditorComponent,\r\n AgGridDropdownCellEditorComponent,\r\n AgGridNumberCellEditorComponent,\r\n AgGridCurrencyCellEditorComponent,\r\n AgGridTextCellEditorComponent,\r\n AgGridTooltipCellRendererComponent,\r\n AgGridTextFilterComponent,\r\n AgGridTextFloatingFilterComponent,\r\n AgGridNumberFilterComponent,\r\n AgGridNumberFloatingFilterComponent,\r\n AgGridDateFloatingFilterComponent,\r\n AgGridDateFilterComponent,\r\n DateFilterPickerInstanceComponent,\r\n AgGridHeaderCellRendererComponent,\r\n AgGridHeaderLegendTooltipComponent,\r\n AgGridYesNoFilterComponent,\r\n AgGridYesNoFloatingFilterComponent,\r\n AgGridTextWithTotalsUpdateCellRendererComponent,\r\n AgGridActionCellRendererComponent,\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridLinkCellRendererComponent,\r\n AgGridCurrentLayoutAppliedComponent\r\n ],\r\n providers: [\r\n AgGridPersistenceService\r\n ],\r\n exports: [\r\n AgGridToolPanelComponent,\r\n AgGridCheckboxCellRendererComponent,\r\n AgGridFilterToggleComponent,\r\n AgGridRowCountComponent,\r\n AgGridDatepickerCellEditorComponent,\r\n AgGridDropdownCellEditorComponent,\r\n AgGridNumberCellEditorComponent,\r\n AgGridCurrencyCellEditorComponent,\r\n AgGridTextCellEditorComponent,\r\n AgGridTooltipCellRendererComponent,\r\n AgGridTextFilterComponent,\r\n AgGridTextFloatingFilterComponent,\r\n AgGridNumberFilterComponent,\r\n AgGridNumberFloatingFilterComponent,\r\n AgGridDateFloatingFilterComponent,\r\n AgGridDateFilterComponent,\r\n AgGridHeaderCellRendererComponent,\r\n AgGridYesNoFilterComponent,\r\n AgGridYesNoFloatingFilterComponent,\r\n AgGridTextWithTotalsUpdateCellRendererComponent,\r\n AgGridActionCellRendererComponent,\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridLinkCellRendererComponent,\r\n AgGridCurrentLayoutAppliedComponent\r\n ]\r\n})\r\nexport class AgGridExtensionsModule {\r\n}\r\n","\r\n \r\n \r\n \r\n {{category.categoryName}}{{category.totalCheckedCount}}\r\n \r\n
\r\n
\r\n

This category is disabled because the following fields are already included:

\r\n
    \r\n
  • {{col.typeAheadName || col.displayName}}
  • \r\n
\r\n
\r\n
\r\n

This category is disabled because the {{selectedTaskType.name}} task type is selected.

\r\n
\r\n
\r\n \r\n \r\n \r\n General{{category.checkedCount}}\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n {{subcategory.categoryName}}{{subcategory.checkedCount}}\r\n \r\n
\r\n

This subcategory is disabled because the following fields are already included:

\r\n
    \r\n
  • {{col.typeAheadName || col.displayName}}
  • \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { OutputColumn } from '../column.model';\r\nimport { OutputColumnCategoryBrowse } from '../columnPicker.component';\r\nimport { SmartSearchService } from '../../smartSearch.service';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { TaskSeriesType } from '../../../../Task/Task.Model';\r\n\r\nimport { flatMap, uniq, reject } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface BrowseColumnModalParams {\r\n existingColumns: OutputColumn[];\r\n otherColumnsThatMightDisable: OutputColumn[];\r\n selectedTaskType: TaskSeriesType;\r\n columnCategories: OutputColumnCategoryBrowse[];\r\n isTaskTypeSpecialCase: boolean;\r\n taskTypeDepthValue: number;\r\n}\r\n\r\n@Component({\r\n selector: 'browse-column-modal',\r\n templateUrl: './browseColumnModal.component.html',\r\n styleUrls: ['./browseColumnModal.component.scss']\r\n})\r\nexport class BrowseColumnModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _smartSearchService: SmartSearchService\r\n ) {}\r\n\r\n params: BrowseColumnModalParams;\r\n result: OutputColumn[];\r\n\r\n selectedTaskType: TaskSeriesType;\r\n columnCategories: OutputColumnCategoryBrowse[];\r\n columnsToAdd: OutputColumn[] = [];\r\n offendingColumns: OutputColumn[];\r\n isTaskTypeSpecialCase: boolean = false;\r\n taskTypeDepthValue: number;\r\n\r\n ngOnInit(): void {\r\n this.selectedTaskType = this.params.selectedTaskType;\r\n this.columnCategories = this.params.columnCategories;\r\n this.isTaskTypeSpecialCase = this.params.isTaskTypeSpecialCase;\r\n this.taskTypeDepthValue = this.params.taskTypeDepthValue;\r\n\r\n this._calcCountAndDisabled();\r\n }\r\n\r\n clearSelection(): void {\r\n this.columnsToAdd = [];\r\n this._calcCountAndDisabled();\r\n }\r\n\r\n addColumns(): void {\r\n this.result = this.columnsToAdd;\r\n this.closeModal();\r\n }\r\n\r\n closeModal(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n columnClicked(column: OutputColumn, e): void {\r\n if (e.target.checked) {\r\n this.columnsToAdd.push(column);\r\n } else {\r\n _.pull(this.columnsToAdd, column);\r\n }\r\n\r\n this._calcCountAndDisabled();\r\n }\r\n\r\n isColumnChecked(column: OutputColumn): boolean {\r\n return this.columnsToAdd.some(x => x.columnId === column.columnId);\r\n }\r\n\r\n tabSelected(category: OutputColumnCategoryBrowse): void {\r\n if (!category.disabled || this.isTaskTypeSpecialCase) {\r\n return;\r\n }\r\n\r\n const invalidColumns = this._smartSearchService.getInvalidColumns([\r\n ...this.params.existingColumns,\r\n ...this.columnsToAdd,\r\n ...category.columns,\r\n ...this.params.otherColumnsThatMightDisable\r\n ], true);\r\n\r\n this.offendingColumns = _.flow([\r\n flatMap('offendingColumns'),\r\n uniq,\r\n reject(column => category.columns.some(x => x.columnId === column.columnId))\r\n ])(invalidColumns);\r\n }\r\n\r\n private _calcCountAndDisabled(): void {\r\n if (!this.isTaskTypeSpecialCase) {\r\n this._smartSearchService.disableColumns(this.columnsToAdd, true, this.taskTypeDepthValue);\r\n }\r\n\r\n this.columnCategories = this.columnCategories.map(category => {\r\n category.checkedCount = category.totalCheckedCount = this.columnsToAdd.filter(x => x.categoryID === category.categoryID).length;\r\n category.disabled = category.columns.every(x => x.disabled);\r\n\r\n category.subcategories = category.subcategories.map(subcategory => {\r\n subcategory.checkedCount = this.columnsToAdd.filter(x => x.categoryID === subcategory.categoryID).length;\r\n category.totalCheckedCount += subcategory.checkedCount;\r\n subcategory.disabled = subcategory.columns.every(x => x.disabled);\r\n\r\n return subcategory;\r\n });\r\n\r\n return category;\r\n });\r\n }\r\n\r\n}\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { OutputColumn, OutputColumnCategory } from './column.model';\r\nimport { TaskSeriesType } from '../../../Task/Task.Model';\r\nimport { SmartSearchService } from '../smartSearch.service';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { BrowseColumnModalComponent, BrowseColumnModalParams } from './Browse-Column-Modal/browseColumnModal.component';\r\n\r\nimport { map, sortBy } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface OutputColumnCategoryBrowse extends OutputColumnCategory {\r\n disabled?: boolean;\r\n checkedCount?: number;\r\n totalCheckedCount?: number;\r\n subcategories: OutputColumnCategoryBrowse[];\r\n}\r\n\r\n@Component({\r\n selector: 'column-picker',\r\n templateUrl: './columnPicker.component.html'\r\n})\r\nexport class ColumnPickerComponent implements OnInit {\r\n constructor(\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _modalService: WeissmanModalService,\r\n ) { }\r\n\r\n @Input() cpMode: 'av' | 'smart';\r\n @Input() disableColumnsAfterLoad: boolean;\r\n @Input() existingColumns: OutputColumn[];\r\n @Input() otherColumnsThatMightDisable: OutputColumn[];\r\n @Input() selectedTaskType: TaskSeriesType;\r\n @Input() allowDuplicates: boolean;\r\n\r\n @Output() columnsSelected: EventEmitter = new EventEmitter();\r\n\r\n typeaheadColumnToAdd: string;\r\n columnsLoaded: boolean = false;\r\n columnCategories: OutputColumnCategoryBrowse[];\r\n isTaskTypeSpecialCase: boolean = false;\r\n taskTypeDepthValue: number;\r\n\r\n private _columns: OutputColumn[] = [];\r\n\r\n async ngOnInit(): Promise {\r\n this.existingColumns = this.existingColumns || [];\r\n this.otherColumnsThatMightDisable = this.otherColumnsThatMightDisable || [];\r\n\r\n if(this.selectedTaskType) {\r\n this.isTaskTypeSpecialCase = !!this.selectedTaskType.depthValuesToEnable || !!this.selectedTaskType.fieldIdsToEnable;\r\n this.taskTypeDepthValue = this.selectedTaskType.taskSeriesTypeAdvancedSearchDepthValue;\r\n }\r\n\r\n this._columns = (await this._smartSearchService.getColumns(this.cpMode == 'av', this.cpMode)).all;\r\n this.columnsLoaded = true;\r\n\r\n if (this.disableColumnsAfterLoad) {\r\n if(this.isTaskTypeSpecialCase) {\r\n this._smartSearchService.disableColumnsFromTaskTypeOnly(this.selectedTaskType);\r\n } else {\r\n this._smartSearchService.disableColumns([...this.existingColumns, ...this.otherColumnsThatMightDisable], false, this.taskTypeDepthValue);\r\n }\r\n }\r\n }\r\n\r\n columnSelected(e: TypeaheadMatch): void {\r\n this.columnsSelected.emit([e.item]);\r\n this.typeaheadColumnToAdd = '';\r\n }\r\n\r\n async openBrowseModal(): Promise {\r\n const columnsToExclude = this.allowDuplicates ? [] : _.cloneDeep(this.existingColumns);\r\n const columnCategories = this._smartSearchService.getFilteredColumnCategories(columnsToExclude);\r\n\r\n const params: BrowseColumnModalParams = {\r\n existingColumns: this.existingColumns,\r\n otherColumnsThatMightDisable: this.otherColumnsThatMightDisable,\r\n selectedTaskType: this.selectedTaskType,\r\n columnCategories: this._processCategories(columnCategories),\r\n isTaskTypeSpecialCase: this.isTaskTypeSpecialCase,\r\n taskTypeDepthValue: this.taskTypeDepthValue\r\n };\r\n\r\n if(!this.isTaskTypeSpecialCase) {\r\n this._smartSearchService.disableColumns([...this.existingColumns, ...this.otherColumnsThatMightDisable], true, this.taskTypeDepthValue);\r\n }\r\n\r\n const result = await this._modalService.showAsync(BrowseColumnModalComponent, params, 'modal-xl');\r\n\r\n if (!result) {\r\n return;\r\n }\r\n\r\n this.columnsSelected.emit(result);\r\n }\r\n\r\n filterColumns(): OutputColumn[] {\r\n return _.reject(this._columns, column => {\r\n const columnId = column.columnId || column.advancedSearchFieldID || column.id;\r\n const columnIdFound = _.some(this.existingColumns, { columnId: columnId });\r\n const idFound = _.some(this.existingColumns, { id: columnId });\r\n const advancedSearchFieldIdFound = _.some(this.existingColumns, { advancedSearchFieldID: columnId });\r\n\r\n return column.disabled || (!this.allowDuplicates && (columnIdFound || idFound || advancedSearchFieldIdFound));\r\n });\r\n }\r\n\r\n private _processCategories(categories: OutputColumnCategoryBrowse[]): OutputColumnCategoryBrowse[] {\r\n return _.flow([\r\n map(category => {\r\n return {\r\n ...category,\r\n columns: _.sortBy(category.columns, 'displayName'),\r\n subcategories: this._processCategories(category.subcategories),\r\n checkedCount: 0,\r\n disabled: category.columns.every(x => x.disabled)\r\n };\r\n }),\r\n sortBy('sequence')\r\n ])(categories);\r\n }\r\n}\r\n\r\n","
\r\n \r\n \r\n
\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { ModalWrapperModule } from '../../../UI-Lib/Modal-Wrapper/modalWrapper.module';\r\nimport { ColumnPickerComponent } from './columnPicker.component';\r\nimport { BrowseColumnModalComponent } from './Browse-Column-Modal/browseColumnModal.component';\r\n\r\nimport { HybridAdapterUtility } from '../../../Hybrid/hybrid-adapter.utility';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n TypeaheadModule,\r\n ModalWrapperModule,\r\n TabsModule\r\n ],\r\n declarations: [\r\n ColumnPickerComponent,\r\n BrowseColumnModalComponent\r\n ],\r\n providers: [],\r\n exports: [ColumnPickerComponent]\r\n})\r\nexport class ColumnPickerModule {\r\n static setupModule(): void {\r\n hybridAdapterUtility.downgradeNg2Component('columnPicker', ColumnPickerComponent);\r\n }\r\n}\r\n","import { lastValueFrom } from 'rxjs';\r\nimport { EntityTypeIds } from '../constants.new';\r\nimport { Injectable } from '@angular/core';\r\nimport { CommentsRepository, SendTaskCommentsBody } from '../Core-Repositories/comments.repository';\r\n\r\nexport class CommentModalData {\r\n entityID: number;\r\n entityTypeID: number;\r\n commentID?: number;\r\n commentTypeID?: number;\r\n parcelAcctNum?: string;\r\n parcelID?: number;\r\n canEdit: boolean;\r\n description: string;\r\n year?: string;\r\n isPinned?: boolean;\r\n disableYearSelection?: boolean;\r\n disableCommentTypeSelection?: boolean;\r\n}\r\n\r\nexport interface CommentModalResult {\r\n commentCount: number;\r\n pinnedComment?: string;\r\n}\r\n\r\nexport interface AddCommentModalData {\r\n allowBlank: boolean;\r\n commentBody: string;\r\n defaultYear: string;\r\n processResult: (string) => Promise;\r\n readOnly: boolean;\r\n showFull: boolean;\r\n title: string;\r\n yearIsRelevant: boolean;\r\n}\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CommentsService {\r\n constructor(\r\n private readonly _commentsRepository: CommentsRepository\r\n ) {}\r\n\r\n fetch(filter): Promise {\r\n return lastValueFrom(this._commentsRepository.fetch(filter));\r\n }\r\n\r\n createComment(comment): Promise {\r\n return lastValueFrom(this._commentsRepository.createComment(comment));\r\n }\r\n\r\n editComment(comment): Promise {\r\n return lastValueFrom(this._commentsRepository.editComment(comment));\r\n }\r\n\r\n deleteComment(commentId: number): Promise {\r\n return lastValueFrom(this._commentsRepository.deleteComment(commentId));\r\n }\r\n\r\n sendTaskComments(taskIDs, comment, entityYearOverrides): Promise {\r\n const update = {\r\n taskIDs: taskIDs,\r\n comment: comment,\r\n entityYearOverrides: entityYearOverrides\r\n } as SendTaskCommentsBody;\r\n return lastValueFrom(this._commentsRepository.sendTaskComments(update));\r\n }\r\n\r\n getEntityDataForTasks(taskIds: number[]): Promise {\r\n return lastValueFrom(this._commentsRepository.getEntityDataForTasks(taskIds));\r\n }\r\n\r\n getEntityData(entityId: number, entityTypeId: EntityTypeIds): Promise {\r\n return lastValueFrom(this._commentsRepository.getEntityData(entityId, entityTypeId));\r\n }\r\n\r\n yearIsRelevantForEntityTypeID(entityTypeId: EntityTypeIds): boolean {\r\n return ![EntityTypeIds.INTAKE_ITEM, EntityTypeIds.CONTACT, EntityTypeIds.PAYMENT_BATCH].some(x => x === entityTypeId);\r\n }\r\n\r\n // This checks if an entity has comments. Usually we don't want to make a separate API call\r\n // to make that determination, but at least on document processing there isn't a more logical\r\n // place to add a hasComments flag on an API call result\r\n checkForComments(entityTypeId: EntityTypeIds, entityId: number): Promise {\r\n return lastValueFrom(this._commentsRepository.checkForComments(entityTypeId, entityId));\r\n }\r\n\r\n getAvailableCommentTypesForEntityType(entityTypeId: EntityTypeIds): Promise {\r\n return this._commentsRepository.getAvailableCommentTypesForEntityType(entityTypeId);\r\n }\r\n\r\n pinComment(commentId: number): Promise {\r\n return lastValueFrom(this._commentsRepository.pinComment(commentId));\r\n }\r\n\r\n unpinComment(commentId: number): Promise {\r\n return lastValueFrom(this._commentsRepository.unpinComment(commentId));\r\n }\r\n}\r\n","import { HttpClient, HttpResponse } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom, Observable } from 'rxjs';\r\nimport { UserSettingsService } from '../../Account/userSettings.service';\r\nimport { BaseRepository } from '../../Common/Data/base.repository';\r\n\r\n@Injectable()\r\nexport class InstanceRepository extends BaseRepository {\r\n constructor(\r\n httpClient: HttpClient,\r\n private readonly _userSettingsService: UserSettingsService\r\n ) {\r\n super(httpClient);\r\n }\r\n\r\n\r\n private _pathPrefix = 'api/instance';\r\n private _entityInstanceCache: any = {};\r\n private _entityInstanceCacheById: any = {};\r\n\r\n\r\n //create new instance\r\n create(model: any): any {\r\n return this.httpPost(`${this._pathPrefix}`, model);\r\n }\r\n\r\n get (instanceId: number): Observable {\r\n return this.httpGet(`${this._pathPrefix}/${instanceId}`);\r\n }\r\n\r\n update(model: Core.InstanceDTO) {\r\n const response = this.httpPut(this._pathPrefix, model);\r\n return response;\r\n }\r\n\r\n //check for duplicate instance name\r\n isInstanceNameInUse(model):Observable {\r\n return this.httpPost(`${this._pathPrefix}/IsInstanceNameInUse`, model);\r\n }\r\n\r\n //look up instanceId for an entity by type and entity id\r\n getEntityInstanceId(entityType: string, entityId:number): Observable {\r\n const resourceUri = `${entityType}/${entityId}`;\r\n if (this._entityInstanceCache[resourceUri]) {\r\n return new Observable(s => {\r\n s.next(+this._entityInstanceCache[resourceUri]);\r\n s.complete();\r\n });\r\n }\r\n return new Observable(s => {\r\n this.httpGet(`${this._pathPrefix}/resolve/${resourceUri}`).subscribe(r => {\r\n this._entityInstanceCache[resourceUri] = r;\r\n s.next(+r);\r\n s.complete();\r\n });\r\n });\r\n }\r\n\r\n\r\n //look up instanceId for an entity by typeId and entityId\r\n getEntityIdPairInstanceId(entityTypeId: number, entityId:number): Observable {\r\n const resourceUri = `${entityTypeId}/${entityId}`;\r\n if (this._entityInstanceCacheById[resourceUri]) {\r\n return new Observable(s => {\r\n s.next(+this._entityInstanceCacheById[resourceUri]);\r\n s.complete();\r\n });\r\n }\r\n return new Observable(s => {\r\n this.httpGet(`${this._pathPrefix}/resolveById/${resourceUri}`).subscribe(r => {\r\n this._entityInstanceCacheById[resourceUri] = r;\r\n s.next(+r);\r\n s.complete();\r\n });\r\n });\r\n }\r\n\r\n getInstanceTypes (): Promise {\r\n return lastValueFrom(this.httpGet(`${this._pathPrefix}/types`));\r\n }\r\n\r\n userEndpointUrlPrefix: string = '/api/user/';\r\n contactEndpointUrlPrefix: string = '/api/contact/';\r\n\r\n //get list of current user's instance contacts and statuses\r\n async getCurrentUsersContactInviteStatuses():Promise {\r\n const url = `${this.userEndpointUrlPrefix}contactsstatus`;\r\n const statuses : Core.ContactStatusDTO[] = await lastValueFrom(this.httpGet(url));\r\n return statuses;\r\n }\r\n\r\n //get list of current user's instance contacts and statuses\r\n async getUserContactInviteStatuses(userId):Promise {\r\n const url = `${this.userEndpointUrlPrefix}contactsstatus/${userId}`;\r\n const statuses : Core.ContactStatusDTO[] = await lastValueFrom(this.httpGet(url));\r\n return statuses;\r\n }\r\n\r\n //accept pending instance invite\r\n async acceptInvite(contactId: number) {\r\n const url = `${this.contactEndpointUrlPrefix}invite/accept/${contactId}`;\r\n const result = await lastValueFrom(this.httpPut(url, null));\r\n if(result === false) {\r\n throw 'Invitation could not be accepted';\r\n }\r\n\r\n return result;\r\n }\r\n\r\n //reject pending instance invite\r\n async rejectInvite(contactId: number) {\r\n const url = `${this.contactEndpointUrlPrefix}invite/reject/${contactId}`;\r\n const result = await lastValueFrom(this.httpPut(url, null));\r\n if(result === false) {\r\n throw 'Invitation could not be rejected';\r\n }\r\n return result;\r\n }\r\n\r\n //toggle instance visibility\r\n async toggleInstance(contactId: number) {\r\n const url = `${this.contactEndpointUrlPrefix}instance/togglevisibility/${contactId}`;\r\n const result = await lastValueFrom(this.httpPut(url, null));\r\n if(result === false) {\r\n throw 'Instance visibility could not be toggled';\r\n }\r\n\r\n return result;\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\n\r\n/**\r\n * @deprecated Use the `ws-ace-loader` component from the `ACE` module instead.\r\n */\r\n@Component({\r\n selector: 'loading-spinner',\r\n template: `\r\n
\r\n \r\n
\r\n `,\r\n styleUrls: ['loadingSpinner.component.scss']\r\n})\r\nexport class LoadingSpinnerComponent {\r\n @Input() show: boolean = true;\r\n @Input() hasOverlay: boolean = false; // Parent container must be display relative\r\n @Input() darkOverlay: boolean = true;\r\n @Input() zIndex: number;\r\n\r\n @Input()\r\n set marginTop(marginTop: number) {\r\n this.top = `${marginTop}px`;\r\n }\r\n\r\n @Input()\r\n set marginBottom(marginBottom: number) {\r\n this.bottom = `${marginBottom}px`;\r\n }\r\n\r\n @Input()\r\n set size(size: number | string) {\r\n this.faSize = `fa-${size}x`;\r\n }\r\n\r\n top: string = '50px';\r\n bottom: string = '1px';\r\n faSize: string;\r\n}\r\n","import { Directive, ElementRef, EventEmitter, Input, Output } from '@angular/core';\r\n\r\n@Directive({\r\n selector: '[line-limit]'\r\n})\r\nexport class LineLimitDirective {\r\n constructor(private readonly _element: ElementRef) {}\r\n\r\n @Input() lineLimitIsOver: boolean;\r\n @Input() lineLimitNumber: number;\r\n @Input()\r\n set lineLimitModel(model: string) {\r\n const computedStyle = getComputedStyle(this._element.nativeElement);\r\n const lineCount = parseFloat(computedStyle.height) / parseFloat(computedStyle.lineHeight);\r\n let lineLimit = 3;\r\n if (this.lineLimitNumber) {\r\n lineLimit = this.lineLimitNumber;\r\n }\r\n this.lineLimitIsOver = lineCount > lineLimit;\r\n }\r\n\r\n @Output() lineLimitIsOverChange: EventEmitter = new EventEmitter();\r\n}\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { EntityTypeIds } from 'src/app/constants.new';\r\nimport { CommentDateTimeFormat } from 'src/app/UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\n\r\n@Component({\r\n selector: 'comment-list-item',\r\n template: `\r\n
\r\n {{getTimestampString(comment)}}\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n {{ comment.year }} - {{comment.lineOne}}\r\n
\r\n
\r\n {{comment.lineTwo}}\r\n
\r\n
\r\n {{comment.lineThree}}\r\n
\r\n
\r\n
\r\n \r\n
{{comment.description}}
\r\n
\r\n
\r\n \r\n less...\r\n more...\r\n \r\n
\r\n
\r\n `,\r\n styles: [`\r\n em { color: var(--ace-neutral-600);}\r\n .comment-item { color: var(--ace-neutral-700) }\r\n `]\r\n})\r\n\r\nexport class CommentListItemComponent {\r\n constructor(private _commentDateTimePipe: CommentDateTimeFormat) { }\r\n\r\n @Input() comment: any;\r\n @Input() pinned: boolean = false;\r\n @Input() canEdit: boolean = false;\r\n @Input() loading: boolean = false;\r\n @Output() editComment: EventEmitter = new EventEmitter();\r\n @Output() pinComment: EventEmitter = new EventEmitter();\r\n\r\n getTimestampString(comment) {\r\n if(this._commentIsUpdated(comment)) {\r\n return `Updated by ${comment.changedByName} at ${this._commentDateTimePipe.transform(comment.changeDate)}`;\r\n } else {\r\n return `${comment.createdByName} at ${this._commentDateTimePipe.transform(comment.createDate)}`;\r\n }\r\n }\r\n\r\n showYearTitle(comment: any): boolean {\r\n return comment.year && comment.entityTypeID !== EntityTypeIds.TAX_BILL;\r\n }\r\n\r\n toggleHide(event, comment) {\r\n comment.showMore = !comment.showMore;\r\n event.preventDefault();\r\n event.stopPropagation();\r\n }\r\n\r\n private _commentIsUpdated(comment): boolean {\r\n // Sometimes on create a comment gets a slightly different change and create date; detect a delta of\r\n // at least 10 seconds before a comment \"counts\" as updated, or alternatively detect that someone else\r\n // changed a comment regardless of the time (noticed in WK-10171)\r\n return comment.changeDate.getYear() > 1 && ((Math.abs(comment.changeDate - comment.createDate) > 10000) || (comment.changedByName && comment.changedByName != comment.createdByName));\r\n }\r\n}\r\n","\r\n\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n\r\n \r\n
0 && !loading\"\r\n class=\"pinned-comment list-group comment-container list-border\"\r\n [ngStyle]=\"{'max-height': pinnedComment ? '38vh' : '58vh' }\">\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n \r\n
0}\" *ngIf=\"commentList.length > 0 && !loading\">\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n

No comments found

\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { CommentTypeNames, EntityTypeIds, EntityTypeNames } from '../../constants.new';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { CommentModalData, CommentModalResult, CommentsService } from '../comments.service';\r\nimport { InstanceRepository } from '../../Entity/Instance/instance.repository';\r\nimport { InstanceRights, RestrictService } from '../../Common/Permissions/restrict.service';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\n\r\nimport * as moment from 'moment';\r\nimport * as _ from 'lodash';\r\nimport { map, uniq, orderBy, filter, each, compact, sortBy, reverse, concat, uniqBy, reject } from 'lodash/fp';\r\n\r\nexport interface CommentsComponentModalParams {\r\n entityData: CommentModalData;\r\n availableCommentTypes: any[];\r\n}\r\n\r\n@Component({\r\n selector: 'comments-component',\r\n templateUrl: './comments.component.html',\r\n styleUrls: ['./comments.component.scss']\r\n})\r\nexport class CommentsComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _commentsService: CommentsService,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _userInstanceService: UserInstanceService\r\n ) {}\r\n\r\n params: CommentsComponentModalParams;\r\n result: CommentModalResult;\r\n\r\n availableYears: string[] = [];\r\n years: string[] = [];\r\n commentTypes: any[] = [];\r\n allComments: any[] = [];\r\n commentList: any[] = [];\r\n entityTypes: any[] = [];\r\n unpinnedComments: any[] = [];\r\n updateComment: any;\r\n getAllCommentsDeferred: any;\r\n pinnedComment: any;\r\n entityData: CommentModalData;\r\n EntityTypeIds = EntityTypeIds;\r\n yearFilter: string = 'All';\r\n entityTypeFilter: any = {\r\n text: 'Comments',\r\n entityTypeID: null\r\n };\r\n childLabel = null;\r\n\r\n hasInstancePrivateView: boolean;\r\n isSingleRyanInstance: boolean;\r\n loading: boolean;\r\n editingComment: boolean;\r\n isNewComment: boolean;\r\n includeChildren: boolean;\r\n areCommentTypesAvailable: boolean;\r\n yearIsRelevant: boolean;\r\n // TODO: Figure this out based on filterTypeID\r\n isBelowParcelLevel: boolean;\r\n\r\n get valid(): boolean {\r\n return this.updateComment\r\n && this.updateComment.title\r\n && (this.updateComment.commentTypeID === 3 ? !!this.updateComment.year : true);\r\n }\r\n\r\n ngOnInit(): void {\r\n this.entityData = this.params.entityData;\r\n\r\n this.isSingleRyanInstance = this._userInstanceService.isCurrentInstanceRyan();\r\n this.yearIsRelevant = this._commentsService.yearIsRelevantForEntityTypeID(this.entityData.entityTypeID);\r\n\r\n // setup comment type dropdown\r\n this.areCommentTypesAvailable = this.params.availableCommentTypes && this.params.availableCommentTypes.length > 0;\r\n if (this.areCommentTypesAvailable) {\r\n this.commentTypes = [\r\n { id: null, name: '' }\r\n ].concat(this.params.availableCommentTypes.map(item => {\r\n return {\r\n id: item.commentTypeID,\r\n name: item.commentTypeName\r\n };\r\n }));\r\n }\r\n\r\n this.yearFilter = 'All';\r\n this.entityTypeFilter = {\r\n text: 'Comments',\r\n entityTypeID: null\r\n };\r\n\r\n // did we want to preselect a certain comment type?\r\n if (this.entityData.commentTypeID){\r\n this.entityTypeFilter.filterType = 'commentType' ;\r\n this.entityTypeFilter.id = this.entityData.commentTypeID;\r\n }\r\n\r\n this.isBelowParcelLevel = false;\r\n this.includeChildren = false;\r\n this.entityTypeChanged();\r\n this.editingComment = false;\r\n this.allComments = [];\r\n this.commentList = [];\r\n this.unpinnedComments = [];\r\n this.pinnedComment = {};\r\n this.entityTypes = [];\r\n this.years = [];\r\n\r\n this.loading = false;\r\n this._getAllComments();\r\n\r\n if (this.entityData.disableYearSelection) {\r\n this.yearFilter = this.entityData.year;\r\n }\r\n }\r\n\r\n displayDate(inputDate) {\r\n return moment(inputDate).fromNow();\r\n }\r\n\r\n // Button click handlers\r\n done(): void {\r\n if (this.editingComment) {\r\n this.cancelEdit();\r\n return;\r\n }\r\n\r\n const commentCount: number = this.entityData.disableCommentTypeSelection && this.entityData.commentTypeID\r\n ? this.commentList.filter(x => x.commentTypeID === this.entityData.commentTypeID).length\r\n : this.commentList.length;\r\n\r\n this.result = {\r\n commentCount: commentCount,\r\n pinnedComment: this.pinnedComment ? this.pinnedComment.description : null };\r\n this._bsModalRef.hide();\r\n }\r\n\r\n addComment(): void {\r\n this.editingComment = true;\r\n this.isNewComment = true;\r\n this.updateComment = {\r\n commentTypeID: null\r\n };\r\n\r\n if (this.entityData.disableCommentTypeSelection) {\r\n this.updateComment.commentTypeID = this.entityData.commentTypeID;\r\n }\r\n\r\n this._resolveInstancePrivate();\r\n this._populateYears();\r\n }\r\n\r\n editComment(comment): void {\r\n this.editingComment = true;\r\n this.isNewComment = false;\r\n this.updateComment = _.cloneDeep(comment);\r\n this._resolveInstancePrivate();\r\n this._populateYears();\r\n }\r\n\r\n submitEditForm(): void {\r\n if (this.isNewComment) {\r\n this._createComment();\r\n } else {\r\n this._saveEdit();\r\n }\r\n }\r\n\r\n async pinComment(comment): Promise {\r\n await this._commentsService.pinComment(comment.commentID);\r\n this._getAllComments();\r\n }\r\n\r\n async unpinComment(comment): Promise {\r\n await this._commentsService.unpinComment(comment.commentID);\r\n if (this.pinnedComment) {\r\n this.pinnedComment.isPinned = false;\r\n this.unpinnedComments.push(_.cloneDeep(this.pinnedComment));\r\n this.pinnedComment = null;\r\n }\r\n }\r\n\r\n async deleteComment(): Promise {\r\n if (confirm(`Are you sure you want to delete the comment \"${ this.updateComment.title }\"?`)) {\r\n await this._commentsService.deleteComment(this.updateComment.commentID);\r\n this.editingComment = false;\r\n this._getAllComments();\r\n }\r\n }\r\n\r\n cancelEdit(): void {\r\n const verb = this.isNewComment ? 'adding' : 'saving';\r\n\r\n if (confirm(`Are you sure you want to cancel ${ verb } a comment?`)) {\r\n this.editingComment = false;\r\n }\r\n }\r\n\r\n yearDisabled(): boolean {\r\n return !!this.entityData.year ||\r\n this.updateComment.entityTypeID === EntityTypeIds.ASSESSMENT ||\r\n this.updateComment.entityTypeID === EntityTypeIds.APPEAL ||\r\n this.updateComment.entityTypeID === EntityTypeIds.TAX_BILL ||\r\n this.updateComment.entityTypeID === EntityTypeIds.REFUND;\r\n\r\n }\r\n // End of button click handlers\r\n\r\n yearChanged(): void {\r\n const filteredComments = this.allComments.filter(x => this._yearFilterPredicate(x));\r\n\r\n const allEntityTypeFilters = _.flow([\r\n uniqBy('entityTypeID'),\r\n map(comment => {\r\n return {\r\n filterType: 'entityType',\r\n id: comment.entityTypeID,\r\n text: `${EntityTypeNames[comment.entityTypeID] } Comments`\r\n };\r\n }),\r\n sortBy('text')\r\n ])(filteredComments);\r\n\r\n const allCommentTypeFilters = _.flow([\r\n uniqBy('commentTypeID'),\r\n reject({ 'commentTypeID': null }),\r\n map(comment => {\r\n return {\r\n filterType: 'commentType',\r\n id: comment.commentTypeID,\r\n text: `${EntityTypeNames[this.entityData.entityTypeID] } ${ CommentTypeNames[comment.commentTypeID] } Comments`\r\n };\r\n }),\r\n sortBy('text')\r\n ])(filteredComments);\r\n\r\n // the \"type\" filter can originate from the \"entity type\" or the \"comment type\" for that entity type\r\n // currently presenting those two filters to the user under one dropdown, however using the \"filterType\" property on each filter to differentiate\r\n const allTypeFilters = _.flow([\r\n concat(allCommentTypeFilters),\r\n concat(allEntityTypeFilters)\r\n ])([]);\r\n\r\n // include the \"Comments\" filter if there are multiple \"entityType\" filters (because the user needs a way to view all comments across all different entity types)\r\n // we can ignore { filterType: \"commentType\" } filters as they will belong to the entity type of the entity that is being loaded\r\n // i.e. if we have the following three filters\r\n // - Site Comments (entity type Site)\r\n // - Site Budget Comments (entity type Site, comment type Budget)\r\n // - Site PSR Comments (entity type Site, comment type PSR)\r\n // we do not need to include the \"Comments\" filter as the \"Site Comments\" one will serve as that\r\n // with the current implementation when an \"entityType\" filter is selected, we return all comments that have or don't have a \"commentType\" filter for that entity type\r\n this.entityTypes = allEntityTypeFilters.length === 1\r\n ? allTypeFilters\r\n : [{ text: ' Comments', id: null, filterType: null }].concat(allTypeFilters);\r\n\r\n // if the existing entity type filter is not part of the new entity types automatically update it\r\n this.entityTypeFilter =\r\n ( this.entityTypeFilter\r\n && this.entityTypes.find(x => x.id === this.entityTypeFilter.id && x.filterType === this.entityTypeFilter.filterType)\r\n )\r\n || this.entityTypes[0];\r\n\r\n this.entityTypeChanged();\r\n }\r\n\r\n entityTypeChanged(): void {\r\n this.pinnedComment = null;\r\n\r\n this.commentList = _.flow([\r\n filter(x => this._yearFilterPredicate(x) && this._typeFilterPredicate(x)),\r\n each(x => x.active = false),\r\n each(x => this._setIsPinnableCommentAttribute(x))\r\n ])(this.allComments);\r\n\r\n this.years = _.flow([\r\n map('year'),\r\n compact,\r\n uniq,\r\n sortBy([]),\r\n reverse\r\n ])(this.allComments);\r\n\r\n this.years.unshift('All');\r\n\r\n this._formatPinnedComments(this.commentList);\r\n }\r\n\r\n async includeChildrenChanged(): Promise {\r\n if (this.getAllCommentsDeferred) {\r\n // Wait for any previous calls to finish (maybe we should try to cancel the old request?)\r\n await this.getAllCommentsDeferred();\r\n }\r\n this._getAllComments();\r\n }\r\n\r\n async loadParentComments(): Promise {\r\n this.entityData = {\r\n description: `Parcel: ${ this.entityData.parcelAcctNum}`,\r\n entityID: this.entityData.parcelID,\r\n entityTypeID: EntityTypeIds.PARCEL,\r\n canEdit: this.entityData.canEdit\r\n };\r\n\r\n await this._getAllComments();\r\n\r\n this._entityTypeChanged();\r\n }\r\n\r\n commentTrackBy(index: number, comment: CommentModalData): number {\r\n return comment.commentID;\r\n }\r\n\r\n private _resolveInstancePrivate() {\r\n lastValueFrom(this._instanceRepository.getEntityIdPairInstanceId(this.entityData.entityTypeID, this.entityData.entityID))\r\n .then(instanceId => {\r\n this.hasInstancePrivateView = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, instanceId)\r\n || this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW, instanceId);\r\n });\r\n }\r\n\r\n private _saveEdit() {\r\n this._commentsService.editComment(this.updateComment).then(() => {\r\n this.editingComment = false;\r\n this._getAllComments();\r\n });\r\n }\r\n\r\n private _createComment() {\r\n this.updateComment.entityTypeID = this.entityData.entityTypeID;\r\n this.updateComment.entityID = this.entityData.entityID;\r\n this._commentsService.createComment(this.updateComment).then(() => {\r\n this.editingComment = false;\r\n this._getAllComments();\r\n });\r\n }\r\n\r\n private _prepareComments(commentList: any[]): any[] {\r\n return commentList.map(comment => {\r\n const isSubEntity = [EntityTypeIds.TAX_BILL, EntityTypeIds.ASSESSMENT, EntityTypeIds.APPEAL, EntityTypeIds.REFUND].indexOf(comment.entityTypeID) >= 0;\r\n if (this.includeChildren) {\r\n if (this.entityData.entityTypeID === EntityTypeIds.SITE && isSubEntity) {\r\n comment.lineOne = comment.parentEntityName;\r\n comment.lineTwo = comment.entityName;\r\n comment.lineThree = comment.title;\r\n } else {\r\n comment.lineOne = comment.entityName;\r\n comment.lineTwo = comment.title;\r\n comment.lineThree = null;\r\n }\r\n } else {\r\n if (this.entityData.entityTypeID === EntityTypeIds.PARCEL && isSubEntity) {\r\n comment.lineOne = comment.entityName;\r\n comment.lineTwo = comment.title;\r\n comment.lineThree = null;\r\n } else {\r\n comment.lineOne = comment.title;\r\n comment.lineTwo = null;\r\n comment.lineThree = null;\r\n }\r\n }\r\n if (comment.changeDate.getYear() > 1) {\r\n comment.sortDate = comment.changeDate;\r\n } else {\r\n comment.sortDate = comment.createDate;\r\n }\r\n comment.isOverLimit = false;\r\n comment.showMore = false;\r\n return comment;\r\n });\r\n }\r\n\r\n private _formatPinnedComments(commentList: CommentModalData[]): void {\r\n if (this.entityTypeFilter && this.entityTypeFilter.filterType === 'commentType') {\r\n this.pinnedComment = commentList.find(x => x.isPinned && x.commentTypeID === this.entityTypeFilter.id);\r\n } else {\r\n this.pinnedComment = commentList.find(x => x.isPinned && x.commentTypeID === null);\r\n }\r\n\r\n const unpinned = _.without(commentList, this.pinnedComment);\r\n\r\n this.unpinnedComments = _.orderBy(unpinned, ['sortDate'], ['desc']);\r\n }\r\n\r\n private _prepareYears(): string[] {\r\n return _.flow([\r\n map(x => x.year ? x.year.toString() : null),\r\n uniq,\r\n orderBy(year => year, ['desc'])\r\n ])(this.allComments);\r\n }\r\n\r\n private async _getAllComments(): Promise {\r\n this.loading = true;\r\n // this.includeChildren represents the state of the checkbox, and it defaults to false for most cases since things like states\r\n // or contacts do not have children. There is one strange example; when viewing parcel comments, we always display children\r\n // but do not show the user a checkbox. For that case, we should submit a true value to the API for that property.\r\n\r\n try {\r\n let includeChildren = this.includeChildren;\r\n if (this.entityData.entityTypeID === EntityTypeIds.PARCEL) {\r\n includeChildren = true;\r\n }\r\n const commentList = await this._commentsService.fetch({\r\n entityTypeID: this.entityData.entityTypeID,\r\n entityID: this.entityData.entityID,\r\n commentType: 'All',\r\n year: 'All',\r\n includeChildren: includeChildren\r\n });\r\n\r\n this.allComments = this._prepareComments(commentList);\r\n\r\n const allYears = this._prepareYears();\r\n\r\n // not all comments will have the year property populated\r\n const indexOfNullYear = allYears.indexOf(null);\r\n if (indexOfNullYear !== -1) {\r\n // remove null year\r\n allYears.splice(indexOfNullYear, 1);\r\n }\r\n\r\n // if only one year and no NULL year then default to that and don't show the \"All\" option\r\n this.years = (allYears.length === 1 && indexOfNullYear === -1) ? allYears : ['All'].concat(allYears);\r\n\r\n // if the existing year filter is not part of the new years automatically update it\r\n this.yearFilter = (this.yearFilter && this.years.find(y => y === this.yearFilter)) || this.years[0];\r\n\r\n this.yearChanged();\r\n } finally {\r\n this.loading = false;\r\n }\r\n\r\n }\r\n\r\n private _yearFilterPredicate(comment) {\r\n return this.yearFilter === 'All' || (comment.year !== null && this.yearFilter.toString() === comment.year.toString());\r\n }\r\n\r\n private _typeFilterPredicate(comment) {\r\n // when an entityFilter is selected (and not a commentType filter)\r\n // we must show all comments for that entity type and not leave out the ones that might have a commentTypeID\r\n return (this.entityTypeFilter.filterType === null) ||\r\n (this.entityTypeFilter.filterType === 'entityType' && this.entityTypeFilter.id === comment.entityTypeID) ||\r\n (this.entityTypeFilter.filterType === 'commentType' && this.entityTypeFilter.id === comment.commentTypeID);\r\n }\r\n\r\n private _setIsPinnableCommentAttribute(comment) {\r\n // a comment is pinnable\r\n // if it belongs to the entity type and entity type ID for the entity that the comments are being shown AND\r\n // if we're not filtering by comment type then it must not belong to a comment type (commentTypeID is null) OR\r\n // if we are filtering by comment type then the ID must match that of the filter\r\n comment.isPinnable =\r\n comment.entityTypeID === this.entityData.entityTypeID &&\r\n comment.entityID === this.entityData.entityID && (\r\n ((this.entityTypeFilter.filterType === null || this.entityTypeFilter.filterType === 'entityType') && !comment.commentTypeID) ||\r\n (this.entityTypeFilter.filterType === 'commentType' && this.entityTypeFilter.id === comment.commentTypeID)\r\n );\r\n }\r\n\r\n private _entityTypeChanged() {\r\n this.isBelowParcelLevel = this.entityData.parcelAcctNum && this.entityData.entityTypeID !== EntityTypeIds.PARCEL;\r\n switch (this.entityData.entityTypeID) {\r\n case EntityTypeIds.COMPANY:\r\n this.childLabel = 'Sites';\r\n break;\r\n case EntityTypeIds.SITE:\r\n this.childLabel = 'Parcels';\r\n break;\r\n default:\r\n this.childLabel = null;\r\n break;\r\n }\r\n }\r\n\r\n private _populateYears(): void {\r\n if (this.entityData.year) {\r\n this.availableYears = [this.entityData.year];\r\n\r\n this.updateComment.year = this.entityData.year;\r\n } else {\r\n this.availableYears = [];\r\n const now = new Date();\r\n const currentYear = now.getFullYear();\r\n\r\n for (let i = currentYear + 3; i >= currentYear - 10; i--) {\r\n this.availableYears.push(`${i}`);\r\n }\r\n }\r\n }\r\n}\r\n","\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { InstanceRepository } from '../../Entity/Instance/instance.repository';\r\nimport { InstanceRights, RestrictService } from '../../Common/Permissions/restrict.service';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { AddCommentModalData } from '../comments.service';\r\n\r\nexport interface AddCommentModalParams extends AddCommentModalData {\r\n title: string;\r\n commentBody: string;\r\n processResult: (result: AddCommentModalResult | string) => Promise;\r\n readOnly: boolean;\r\n allowBlank: boolean;\r\n yearIsRelevant: boolean;\r\n showFull: boolean;\r\n defaultYear: string;\r\n entityTypeName?: string;\r\n entityId?: number;\r\n}\r\n\r\nexport interface AddCommentModalResult {\r\n title: string;\r\n year: string;\r\n description: string;\r\n isRyanInternal: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'add-comment-modal',\r\n templateUrl: './addComment.component.html'\r\n})\r\nexport class AddCommentComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _userInstanceService: UserInstanceService\r\n ) {}\r\n\r\n params: AddCommentModalParams;\r\n result: AddCommentModalResult | string;\r\n\r\n availableYears = [];\r\n title: string;\r\n commentTitle: string = '';\r\n commentBody: string;\r\n processResult: (result: AddCommentModalResult | string) => Promise;\r\n readOnly: boolean;\r\n isRyanInternal: boolean;\r\n allowBlank: boolean;\r\n yearIsRelevant: boolean;\r\n year: string;\r\n showFull: boolean;\r\n yearDisabled: boolean;\r\n loading: boolean;\r\n hasInstancePrivateView: boolean;\r\n isSingleRyanInstance: boolean;\r\n\r\n ngOnInit(): void {\r\n this.title = this.params.title || 'Add Comment';\r\n this.commentBody = this.params.commentBody || '';\r\n this.processResult = this.params.processResult || null;\r\n this.readOnly = !!this.params.readOnly;\r\n this.allowBlank = this.params.allowBlank || false;\r\n this.yearIsRelevant = this.params.yearIsRelevant || false;\r\n this.showFull = this.params.showFull;\r\n this.yearDisabled = !this.params.defaultYear;\r\n this.isSingleRyanInstance = this._userInstanceService.isCurrentInstanceRyan();\r\n\r\n this._populateYears();\r\n\r\n if(this.showFull) {\r\n this._getHasInstancePrivateView();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this.loading = false;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n get canSave(): boolean {\r\n return !this.loading && (this.allowBlank || !!this.commentBody || !!this.commentTitle);\r\n }\r\n\r\n async save(): Promise {\r\n if (this.params.showFull) {\r\n this.result = {\r\n title: this.commentTitle,\r\n year: this.year,\r\n description: this.commentBody,\r\n isRyanInternal: this.isRyanInternal\r\n };\r\n } else {\r\n this.result = this.commentBody;\r\n }\r\n\r\n if (this.processResult) {\r\n this.loading = true;\r\n try {\r\n await this.processResult(this.result);\r\n this.cancel();\r\n } catch(err) {\r\n this.cancel();\r\n }\r\n } else {\r\n this.cancel();\r\n }\r\n }\r\n\r\n private _populateYears(): void {\r\n if (this.params.defaultYear) {\r\n this.availableYears = [{\r\n display: this.params.defaultYear,\r\n value: this.params.defaultYear\r\n }];\r\n\r\n this.year = this.params.defaultYear;\r\n } else {\r\n this.availableYears = [];\r\n const now = new Date();\r\n const currentYear = now.getFullYear();\r\n\r\n for (let i = currentYear + 3; i >= currentYear - 10; i--) {\r\n this.availableYears.push({\r\n display: i,\r\n value: i\r\n });\r\n }\r\n }\r\n }\r\n\r\n private async _getHasInstancePrivateView(): Promise {\r\n if (this.params.entityTypeName && this.params.entityId) {\r\n const instanceId = await lastValueFrom(this._instanceRepository.getEntityInstanceId(this.params.entityTypeName, this.params.entityId));\r\n\r\n this.hasInstancePrivateView = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, instanceId)\r\n || this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW, instanceId);\r\n } else {\r\n this.hasInstancePrivateView = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT)\r\n || this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW);\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { CommentsComponent, CommentsComponentModalParams } from './Modal/comments.component';\r\nimport { AddCommentComponent, AddCommentModalParams } from './Add-Comment-Modal/addComment.component';\r\nimport { CommentModalData, CommentsService } from './comments.service';\r\nimport { WeissmanModalService } from '../Compliance/WeissmanModalService';\r\n\r\n/**\r\n * Service used to open the comments modal\r\n * This had to be split from the CommentsService during the upgrade from angularjs to prevent a circular dependency\r\n */\r\n@Injectable()\r\nexport class CommentsModalService {\r\n constructor(\r\n private readonly _weissmanModalService: WeissmanModalService,\r\n private readonly _commentsService: CommentsService\r\n ) {}\r\n\r\n async openCommentModal(modalData: CommentModalData): Promise {\r\n const modalParams = {\r\n entityData: modalData,\r\n availableCommentTypes: await this._commentsService.getAvailableCommentTypesForEntityType(modalData.entityTypeID)\r\n } as CommentsComponentModalParams;\r\n\r\n return await this._weissmanModalService.showAsync(CommentsComponent, modalParams, 'modal-lg ace-modal-dialog');\r\n }\r\n\r\n openAddCommentModal(modalData: any): Promise {\r\n const params = {\r\n ...modalData\r\n } as AddCommentModalParams;\r\n\r\n return this._weissmanModalService.showAsync(AddCommentComponent, params, 'modal-lg');\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { CommentModalData } from '../comments.service';\r\nimport { CommentsModalService } from '../commentsModal.service';\r\n\r\n@Component({\r\n selector: 'entity-comments',\r\n templateUrl: './entityCommentsButton.component.html'\r\n})\r\nexport class EntityCommentsButtonComponent {\r\n constructor(\r\n private readonly _commentsModalService: CommentsModalService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n @Input() pinnedComment?: string;\r\n @Input() hasComments: boolean;\r\n @Input() buttonClass: string;\r\n @Input() getModalData: () => CommentModalData;\r\n @Input() modalData: CommentModalData;\r\n @Input() disabled: boolean;\r\n @Input() isNestedModal: boolean;\r\n @Input() analyticsCategory: string;\r\n @Input() tooltipPosition: string = 'bottom';\r\n\r\n @Output() hasCommentsChange: EventEmitter = new EventEmitter();\r\n @Output() commentCountChange: EventEmitter = new EventEmitter();\r\n\r\n async showCommentsDialog(): Promise {\r\n const modalData = this.modalData || (this.getModalData && this.getModalData());\r\n if (this.analyticsCategory) {\r\n this._productAnalyticsService.logEvent(`click-${this.analyticsCategory}-comment`);\r\n }\r\n\r\n const commentData = await this._commentsModalService.openCommentModal(modalData);\r\n\r\n this.hasComments = !!commentData.commentCount;\r\n this.pinnedComment = commentData.pinnedComment;\r\n this.hasCommentsChange.emit(this.hasComments);\r\n this.commentCountChange.emit(commentData.commentCount);\r\n }\r\n}\r\n","\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { EntityCommentsButtonComponent } from './Entity-Comments-Button/entityCommentsButton.component';\r\nimport { AddCommentComponent } from './Add-Comment-Modal/addComment.component';\r\nimport { CommentsComponent } from './Modal/comments.component';\r\nimport { CommentsModalService } from './commentsModal.service';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { DirectivesModule } from '../UI-Lib/Directives/directives.module';\r\nimport { CommentsRepository } from '../Core-Repositories';\r\nimport { ModalWrapperModule } from '../UI-Lib/Modal-Wrapper/modalWrapper.module';\r\nimport { HelpModule } from '../UI-Lib/Help-Tooltip/help.module';\r\nimport { SelectModule } from '../UI-Lib/Select/select.module';\r\nimport { LoadingSpinnerModule } from '../UI-Lib/Loading-Spinner/loadingSpinner.module';\r\nimport { SharedPipesModule } from '../UI-Lib/Pipes/shared-pipes.module';\r\nimport { CommentListItemComponent } from './Modal/commentListItem.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ModalWrapperModule,\r\n HelpModule,\r\n SelectModule,\r\n LoadingSpinnerModule,\r\n DirectivesModule,\r\n SharedPipesModule\r\n ],\r\n declarations: [\r\n EntityCommentsButtonComponent,\r\n CommentsComponent,\r\n AddCommentComponent,\r\n CommentListItemComponent\r\n ],\r\n providers: [\r\n CommentsRepository,\r\n CommentsModalService\r\n ],\r\n exports: [\r\n CommentsComponent,\r\n EntityCommentsButtonComponent\r\n ]\r\n})\r\nexport class CommentsModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('entityComments', EntityCommentsButtonComponent);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { TaxRateArea } from './tax.rates.panel.model';\r\nexport interface ICellRendererParamsForTaxRatesPanelTaxAuthorities extends ICellRendererParams {\r\n rate: (taxRateArea: TaxRateArea, year: number) => string;\r\n taxRateAuthorities: (taxRateArea: TaxRateArea, year: number) => {name: string, rate: number}[];\r\n year: number;\r\n}\r\n\r\n@Component({\r\n selector: 'tax-authorities-cell',\r\n template: `\r\n {{rate}}\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Authority NameRate
{{authority.name}}{{authority.rate | percent:\"1.6-6\"}}
\r\n
\r\n `\r\n})\r\nexport class TaxRatesPanelTaxAuthoritiesCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForTaxRatesPanelTaxAuthorities;\r\n rate: string;\r\n authorities: {name: string, rate: number}[];\r\n\r\n agInit(params: ICellRendererParamsForTaxRatesPanelTaxAuthorities): void {\r\n this.params = params;\r\n\r\n const taxRateArea: TaxRateArea = params.data;\r\n const year: number = params.year;\r\n\r\n this.rate = params.rate(taxRateArea, year);\r\n this.authorities = params.taxRateAuthorities(taxRateArea, year);\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { GridSource } from '../tax.rate.grid.component';\r\nimport { TaxAuthority, TaxRateArea } from '../../Assessor-Collector/Tax-Rates/tax.rates.panel.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\n\r\nexport interface ICellRendererParamsForTaxRateCommandCenterComments extends ICellRendererParams {\r\n canEdit: boolean;\r\n gridSofurce: GridSource;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-comments-cell',\r\n template:\r\n `\r\n
\r\n \r\n \r\n
\r\n `\r\n})\r\nexport class TaxRateCommandCenterCommentsCellRendererComponent implements ICellRendererAngularComp {\r\n entity: TaxAuthority | TaxRateArea;\r\n commentModalData: CommentModalData;\r\n canEdit: boolean = false;\r\n\r\n agInit(params: ICellRendererParamsForTaxRateCommandCenterComments): void {\r\n this.canEdit = params.canEdit;\r\n\r\n if (!params.data) {\r\n return;\r\n }\r\n\r\n if(params.gridSofurce == 'authorities') {\r\n this.entity = params.data as TaxAuthority;\r\n this.commentModalData = {\r\n entityID: this.entity.taxAuthorityId,\r\n entityTypeID: Core.EntityTypes.TaxAuthority,\r\n description: this.entity.name,\r\n canEdit: this.canEdit\r\n } as CommentModalData;\r\n } else {\r\n this.entity = params.data as TaxRateArea;\r\n this.commentModalData = {\r\n entityID: this.entity.taxRateAreaId,\r\n entityTypeID: Core.EntityTypes.TaxRateArea,\r\n description: this.entity.name,\r\n canEdit: this.canEdit\r\n } as CommentModalData;\r\n }\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const ATTACHMENT_MODAL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'attachment-modal.show-list',\r\n tooltipText: 'Show Attachment List'\r\n },\r\n {\r\n helpContentId: 'attachment-modal.hide-list',\r\n tooltipText: 'Hide Attachment List'\r\n }\r\n];\r\n","import { Injectable } from '@angular/core';\r\nimport { EntityTypeIds } from '../../constants.new';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface CurrentEntity {\r\n id?: string;\r\n type: string;\r\n name?: string;\r\n typeId?: EntityTypeIds;\r\n}\r\n\r\n/**\r\n * Global state store for the current active entity utilized on a number of pages in the app\r\n *\r\n * TODO - determine why we are handling this in this way instead of each page service handling their entities on\r\n * their own, which would provide much better type security.\r\n */\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class CurrentEntityService {\r\n currentEntity: any = {};\r\n currentTypeId: EntityTypeIds = null;\r\n\r\n /**\r\n * Initializes the class variables back to their initial state\r\n */\r\n init(): void {\r\n this.currentEntity = {};\r\n this.currentTypeId = null;\r\n }\r\n\r\n /**\r\n * Get the current entity state\r\n */\r\n get(): CurrentEntity {\r\n return this._getEntityData();\r\n }\r\n\r\n /**\r\n * Set the current entity state\r\n * @param entity - This could be any number of entity types\r\n * @param typeId - The EntityTypeIds enum value for the entity provided\r\n */\r\n set(entity: any, typeId: EntityTypeIds): void {\r\n this.currentEntity = _.cloneDeep(entity);\r\n this.currentTypeId = typeId;\r\n }\r\n\r\n private _getEntityData(): CurrentEntity {\r\n switch (this.currentTypeId) {\r\n case EntityTypeIds.PARCEL:\r\n return {\r\n id: this.currentEntity.parcelID,\r\n type: 'parcel',\r\n name: this.currentEntity.acctNum,\r\n typeId: EntityTypeIds.PARCEL\r\n };\r\n\r\n case EntityTypeIds.SITE:\r\n return {\r\n id: this.currentEntity.siteID,\r\n type: 'site',\r\n name: this.currentEntity.name,\r\n typeId: EntityTypeIds.SITE\r\n };\r\n\r\n case EntityTypeIds.COMPANY:\r\n return {\r\n id: this.currentEntity.companyID,\r\n type: 'company',\r\n name: this.currentEntity.name || this.currentEntity.companyName,\r\n typeId: EntityTypeIds.COMPANY\r\n };\r\n\r\n case EntityTypeIds.STATE:\r\n return {\r\n id: this.currentEntity.stateID,\r\n type: 'state',\r\n name: this.currentEntity.fullName,\r\n typeId: EntityTypeIds.STATE\r\n };\r\n\r\n case EntityTypeIds.ASSESSOR:\r\n return {\r\n id: this.currentEntity.assessorID,\r\n type: 'assessor',\r\n name: this.currentEntity.name,\r\n typeId: EntityTypeIds.ASSESSOR\r\n };\r\n\r\n case EntityTypeIds.COLLECTOR:\r\n return {\r\n id: this.currentEntity.collectorID,\r\n type: 'collector',\r\n name: this.currentEntity.name,\r\n typeId: EntityTypeIds.COLLECTOR\r\n };\r\n\r\n case EntityTypeIds.TAX_BILL:\r\n return {\r\n id: this.currentEntity.billID,\r\n type: 'tax_bill',\r\n name: this.currentEntity.name,\r\n typeId: EntityTypeIds.TAX_BILL\r\n };\r\n\r\n case EntityTypeIds.ASSESSMENT:\r\n return {\r\n id: this.currentEntity.annualAssessmentID,\r\n type: 'assessment',\r\n name: this.currentEntity.revisionDesc,\r\n typeId: EntityTypeIds.ASSESSMENT\r\n };\r\n\r\n default:\r\n return {\r\n type: 'unknown'\r\n };\r\n }\r\n }\r\n}\r\n","export abstract class DocumentServiceUpgrade {\r\n abstract sendBatchDocuments(options, files);\r\n\r\n abstract getDocumentBody(id: any): Promise;\r\n\r\n abstract getDocumentInfo(id): Promise;\r\n\r\n abstract getDocumentInfoByTaskId(id): Promise;\r\n\r\n abstract getTaskInfo(id): Promise;\r\n\r\n abstract getTaskInfoByTaskID(id): Promise;\r\n\r\n abstract saveFile(blob, fileName): Promise;\r\n\r\n abstract mapDocumentToEntity(id, data): Promise;\r\n\r\n abstract put(data): Promise;\r\n}\r\n","import { MimeTypeExtension } from './attachment.model';\r\n\r\nexport const mimeTypeExtensions: MimeTypeExtension[] = [{\r\n type: 'application/pdf',\r\n exts: ['.pdf'],\r\n previewSupported: true\r\n}, {\r\n type: 'text/plain',\r\n exts: ['.txt'],\r\n previewSupported: true\r\n}, {\r\n type: 'image/png',\r\n exts: ['.png'],\r\n previewSupported: true\r\n}, {\r\n type: 'image/gif',\r\n exts: ['.gif'],\r\n previewSupported: true\r\n}, {\r\n type: 'image/jpeg',\r\n exts: ['.jpeg', '.jpg'],\r\n previewSupported: true\r\n}, {\r\n type: 'image/tiff',\r\n exts: ['.tif', '.tiff'],\r\n previewSupported: true\r\n}, {\r\n type: 'application/msword',\r\n exts: ['.doc', '.dot'],\r\n previewSupported: false\r\n}, {\r\n type: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',\r\n exts: ['.docx', '.dotx'],\r\n previewSupported: false\r\n}, {\r\n type: 'application/vnd.ms-excel',\r\n exts: ['.xls', '.xlt', '.xla'],\r\n previewSupported: false\r\n}, {\r\n type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',\r\n exts: ['.xlsx'],\r\n previewSupported: false\r\n}, {\r\n type: 'application/vnd.ms-powerpoint',\r\n exts: ['.ppt', '.pot', '.pps', '.ppa'],\r\n previewSupported: false\r\n}, {\r\n type: 'application/zip',\r\n exts: ['.zip'],\r\n previewSupported: false\r\n}];","import { Injectable } from '@angular/core';\r\nimport { UtilitiesService } from '../UI-Lib/Utilities';\r\nimport { Constants, EntityTypeIds } from '../constants.new';\r\nimport { HttpClient, HttpResponse } from '@angular/common/http';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { Observable, Subject, lastValueFrom, takeUntil, tap } from 'rxjs';\r\nimport { Attachment, AttachmentCategory, AttachmentInfo, MimeTypeExtension } from './attachment.model';\r\nimport { endsWith, find, includes } from 'lodash';\r\nimport { mimeTypeExtensions } from './attachments.constants';\r\nimport { FeatureFlagsService } from '../Common/FeatureFlags/feature-flags-service';\r\n\r\ndeclare global {\r\n interface Navigator {\r\n msSaveBlob?: (blob: Blob, defaultName?: string) => boolean;\r\n webkitSaveBlob?: (blob: Blob, defaultName?: string) => boolean;\r\n mozSaveBlob?: (blob: Blob, defaultName?: string) => boolean;\r\n saveBlob?: (blob: Blob, defaultName?: string) => boolean;\r\n }\r\n}\r\n\r\n@Injectable()\r\nexport class AttachmentService {\r\n constructor(private readonly _utils: UtilitiesService,\r\n private readonly _http: HttpClient,\r\n private readonly _constants: Constants,\r\n private readonly _navService: UpgradeNavigationServiceHandler,\r\n private readonly _featureFlagsService: FeatureFlagsService) { }\r\n\r\n private readonly SERVICE_URL = 'api/attachment';\r\n private readonly CATEGORY_SERVICE_URL = '/api/AttachmentCategory';\r\n private readonly TYPE_SERVICE_URL = '/api/AttachmentType';\r\n private _terminateSub: Subject = new Subject();\r\n\r\n createAttachment(files: File[], attachment: Attachment): Promise {\r\n const entityTypeName = this._getEntityTypeName(attachment.entityTypeID);\r\n const formData = new FormData();\r\n\r\n if (files.length > 0) {\r\n formData.append('0', files[0]);\r\n }\r\n\r\n const url = `${this.SERVICE_URL}/${entityTypeName}/${attachment.entityID}?json=${encodeURIComponent(JSON.stringify(attachment))}`;\r\n\r\n const request = this._http.post(url, formData, {\r\n params: {\r\n siteID: this._navService.getQuerystringParam('siteId') // This is weird, we should be passing this in\r\n }\r\n });\r\n\r\n return lastValueFrom(request) as Promise;\r\n }\r\n\r\n getInfo(attachmentId:string): Promise {\r\n return lastValueFrom(this._http.get(`${this.SERVICE_URL}/${encodeURIComponent(attachmentId)}/info`));\r\n }\r\n\r\n getAll(entityTypeId: number, entityId: number, includeChildren: boolean): Promise {\r\n const entityTypeName = this._getEntityTypeName(entityTypeId);\r\n\r\n if (entityTypeName === 'Parcel') {\r\n includeChildren = true;\t\t// we always include children for parcel\r\n }\r\n\r\n const config = {\r\n params: {\r\n siteID: this._navService.getQuerystringParam('siteId'), // This is weird, we should be passing this in\r\n year: 'All',\r\n categoryID: 0,\r\n includeChildren,\r\n typeID: entityTypeId\r\n }\r\n };\r\n\r\n const url = `${this.SERVICE_URL}/${entityTypeName}/all/${entityId}`;\r\n return lastValueFrom(this._http.get(url, config)) as Promise;\r\n }\r\n\r\n getSingleAttachmentBody(attachmentInfo: AttachmentInfo, dontCancel?: boolean): Observable> {\r\n if(!dontCancel) {\r\n this._terminateSub.next();\r\n }\r\n const url = `${this.SERVICE_URL}/${attachmentInfo.attachmentID}`;\r\n\r\n return this._http.get(url, {responseType: 'arraybuffer', observe: 'response'}).pipe(\r\n takeUntil(this._terminateSub)\r\n );\r\n }\r\n\r\n // Based on http://stackoverflow.com/questions/24080018/download-file-from-an-asp-net-web-api-method-using-angularjs\r\n\t\t//\r\n performDownload(data, filename: string, fileExtension: string): void {\r\n const octetStreamMime = 'application/octet-stream';\r\n let success = false;\r\n const contentType = this.getMimeTypeByFileExtension(fileExtension);\r\n\r\n try {\r\n if (!endsWith(filename, `.${fileExtension}`)) {\r\n filename = `${filename}.${fileExtension}`;\r\n }\r\n // Try using msSaveBlob if supported\r\n console.log('Trying saveBlob method ...');\r\n const blob = new Blob([data], { type: contentType.type });\r\n if (navigator.msSaveBlob)\r\n navigator.msSaveBlob(blob, filename);\r\n else {\r\n // Try using other saveBlob implementations, if available\r\n const saveBlob = navigator.webkitSaveBlob || navigator.mozSaveBlob || navigator.saveBlob;\r\n if (saveBlob === undefined) throw 'Not supported';\r\n saveBlob(blob, filename);\r\n }\r\n console.log('saveBlob succeeded');\r\n success = true;\r\n } catch (ex) {\r\n console.log('saveBlob method failed with the following exception:');\r\n console.log(ex);\r\n }\r\n\r\n if (!success) {\r\n // Get the blob url creator\r\n const urlCreator = window.URL || window.webkitURL;\r\n if (urlCreator) {\r\n // Try to use a download link\r\n const link = document.createElement('a');\r\n if ('download' in link) {\r\n // Try to simulate a click\r\n try {\r\n // Prepare a blob URL\r\n console.log('Trying download link method with simulated click ...');\r\n const blob = new Blob([data], { type: contentType.type });\r\n const url = urlCreator.createObjectURL(blob);\r\n link.setAttribute('href', url);\r\n\r\n // Set the download attribute (Supported in Chrome 14+ / Firefox 20+)\r\n link.setAttribute('download', filename);\r\n\r\n // Simulate clicking the download link\r\n const event = document.createEvent('MouseEvents');\r\n event.initMouseEvent('click', true, true, window, 1, 0, 0, 0, 0, false, false, false, false, 0, null);\r\n link.dispatchEvent(event);\r\n console.log('Download link method with simulated click succeeded');\r\n success = true;\r\n\r\n } catch (ex) {\r\n console.log('Download link method with simulated click failed with the following exception:');\r\n console.log(ex);\r\n }\r\n }\r\n\r\n if (!success) {\r\n // Fallback to window.location method\r\n try {\r\n // Prepare a blob URL\r\n // Use application/octet-stream when using window.location to force download\r\n console.log('Trying download link method with window.location ...');\r\n const blob = new Blob([data], { type: octetStreamMime });\r\n const url = urlCreator.createObjectURL(blob);\r\n window.location = url as any;\r\n console.log('Download link method with window.location succeeded');\r\n success = true;\r\n } catch (ex) {\r\n console.log('Download link method with window.location failed with the following exception:');\r\n console.log(ex);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n getMimeTypeByFileExtension(fileExt: string): MimeTypeExtension {\r\n // todo should we store mime type along with the file?\r\n //\r\n\r\n if (fileExt && fileExt.length > 0) {\r\n if (fileExt[0] != '.')\r\n fileExt = `.${ fileExt}`;\r\n }\r\n\r\n const foundMimeType = find(mimeTypeExtensions, type => includes(type.exts, fileExt.toLowerCase()));\r\n const defaultMimeType = {\r\n type: 'application/octet-stream',\r\n previewSupported: false,\r\n exts: []\r\n };\r\n\r\n return foundMimeType || defaultMimeType;\r\n }\r\n\r\n async downloadAttachmentFile(attachmentInfo: AttachmentInfo, allowMultiple?: boolean): Promise {\r\n // If the file has a size specified and is large, stream instead of buffering it all into the client\r\n if (attachmentInfo.size && attachmentInfo.size > (this._featureFlagsService.featureFlags.fileDownloadBufferMaxSizeKB * 1024)) {\r\n await this.downloadAttachmentFileStreamed(attachmentInfo);\r\n return;\r\n }\r\n \r\n await this.downloadAttachmentFileBuffered(attachmentInfo, allowMultiple);\r\n }\r\n\r\n async downloadAttachmentFileBuffered(attachmentInfo: AttachmentInfo, allowMultiple?: boolean): Promise {\r\n await lastValueFrom(this.getSingleAttachmentBody(attachmentInfo, allowMultiple).pipe(\r\n tap((response: HttpResponse) => {\r\n\r\n if(!attachmentInfo.fileName) {\r\n attachmentInfo.fileName = this.getFileNameFromHttpResponse(response);\r\n }\r\n if(attachmentInfo.fileName && !attachmentInfo.fileExtension) {\r\n attachmentInfo.fileExtension = attachmentInfo.fileName.split('.').pop();\r\n }\r\n\r\n this.performDownload(response.body, attachmentInfo.fileName, attachmentInfo.fileExtension);\r\n })\r\n ));\r\n }\r\n\r\n async downloadAttachmentFileStreamed(attachmentInfo: AttachmentInfo): Promise {\r\n const oneTimeCode = await lastValueFrom(this._http.get(`/api/attachment/${attachmentInfo.attachmentID}/OneTimeCode`));\r\n\r\n const link = document.createElement('a');\r\n link.setAttribute('target', '_blank');\r\n link.setAttribute('href', `/api/attachment/Download/${encodeURIComponent(oneTimeCode)}`);\r\n link.dispatchEvent(new MouseEvent('click'));\r\n }\r\n\r\n getFileNameFromHttpResponse(httpResponse: HttpResponse | any, isUntyped?: boolean): string {\r\n let fileName = '';\r\n const contentDisposition = isUntyped\r\n ? httpResponse.headers('Content-Disposition') || ''\r\n : httpResponse.headers.get('Content-Disposition') || '';\r\n\r\n const filenameRegex = /filename[^;=\\n]*=((['\"]).*?\\2|[^;\\n]*)/;\r\n const matches = filenameRegex.exec(contentDisposition);\r\n if (matches != null && matches[1]) {\r\n fileName = matches[1].replace(/['\"]/g, '').trim();\r\n }\r\n\r\n return fileName;\r\n }\r\n\r\n downloadAttachmentByGuid(attachmentGuid: string, filename: string, fileExtension: string): void {\r\n this._terminateSub.next(); // cancels any outstanding requests\r\n\r\n const url = `${this.SERVICE_URL}/${attachmentGuid}`;\r\n\r\n this._http.get(url, {responseType: 'arraybuffer'}).pipe(\r\n takeUntil(this._terminateSub)\r\n ).subscribe((response: any) => {\r\n this.performDownload(response, filename, fileExtension);\r\n });\r\n }\r\n\r\n isPreviewSupported(type: string): boolean {\r\n const entry = find(mimeTypeExtensions, { type });\r\n return entry?.previewSupported || false;\r\n }\r\n\r\n async deleteAttachment(attachmentInfo: AttachmentInfo): Promise {\r\n const url = `${this.SERVICE_URL}/${attachmentInfo.attachmentID}`;\r\n await lastValueFrom(this._http.delete(url));\r\n }\r\n\r\n update(attachmentInfo: AttachmentInfo): Promise {\r\n const entityTypeName = this._getEntityTypeName(attachmentInfo.entityTypeID);\r\n const url = `${this.SERVICE_URL}/${entityTypeName}/${attachmentInfo.entityID}`;\r\n\r\n return lastValueFrom(this._http.put(url, attachmentInfo)) as Promise;\r\n }\r\n\r\n getAttachmentIcon(hasAttachments: boolean): string {\r\n return hasAttachments\r\n ? this._constants.ImageURLs.ATTACHMENTS_ALL_SOME_ICON\r\n : this._constants.ImageURLs.ATTACHMENTS_ALL_NONE_ICON;\r\n }\r\n\r\n checkForAttachments(entityTypeID: number, entityID: number): Promise {\r\n const url = `${this.SERVICE_URL}/${entityTypeID}/${entityID}/hasattachments`;\r\n return lastValueFrom(this._http.get(url)) as Promise;\r\n }\r\n\r\n getAttachmentCategories(): Promise {\r\n return lastValueFrom(this._http.get(this.CATEGORY_SERVICE_URL)) as Promise;\r\n }\r\n\r\n getAttachmentTypes(): Promise {\r\n return lastValueFrom(this._http.get(this.TYPE_SERVICE_URL)) as Promise;\r\n }\r\n\r\n private _getEntityTypeName(entityTypeId: number): string {\r\n const entityTypeName = this._utils.findPropertyName(EntityTypeIds, entityTypeId);\r\n\r\n if (entityTypeName === 'tax_bill') {\r\n return 'Bill';\r\n }\r\n if (entityTypeName === 'assessment') {\r\n return 'AnnualAssessment';\r\n }\r\n if(entityTypeName === 'payment_batch') {\r\n return 'PaymentBatch';\r\n }\r\n\r\n return entityTypeName;\r\n }\r\n}","import { Injectable } from '@angular/core';\r\nimport { QuickCriteriaFilter } from './quickCriteria.model';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class QuickFiltersService {\r\n getAll(): QuickCriteriaFilter[] {\r\n return this._getFilters();\r\n }\r\n\r\n getActive(): QuickCriteriaFilter[] {\r\n return _.filter(this._getFilters(), 'default');\r\n }\r\n\r\n getDocumentActive(): QuickCriteriaFilter[] {\r\n return _.union(_.filter(this._getFilters(), 'defaultDocument'), this._getExtraDocumentFilters());\r\n }\r\n\r\n getInactive(): QuickCriteriaFilter[] {\r\n return _.reject(this._getFilters(), 'default');\r\n }\r\n\r\n getDocumentInactive(): QuickCriteriaFilter[] {\r\n return _.reject(this._getFilters(), 'defaultDocument');\r\n }\r\n\r\n private _getExtraDocumentFilters(): QuickCriteriaFilter[] {\r\n return [{\r\n idpFilterType: 'f1402',\r\n ocrFields: ['collectorDetails.name'],\r\n name: 'Tax Collector',\r\n field: 'taxCollector',\r\n associatedWith: 'taxbill',\r\n default: false,\r\n defaultDocument: false,\r\n dropdown: false,\r\n sequenceNum: 16\r\n }, {\r\n idpFilterType: 'f901',\r\n ocrFields: ['taxYear'],\r\n name: 'Tax Year',\r\n field: 'taxYear',\r\n associatedWith: 'taxbill',\r\n default: false,\r\n defaultDocument: false,\r\n dropdown: false,\r\n sequenceNum: 17\r\n }];\r\n }\r\n\r\n private _getFilters(): QuickCriteriaFilter[] {\r\n return [{\r\n name: 'Company Name',\r\n field: 'companyName',\r\n associatedWith: 'company',\r\n default: true,\r\n defaultDocument: true,\r\n dropdown: false,\r\n sequenceNum: 1\r\n }, {\r\n name: 'Company ID',\r\n field: 'companyID',\r\n associatedWith: 'company',\r\n default: false,\r\n defaultDocument: false,\r\n dropdown: false,\r\n sequenceNum: 2\r\n }, {\r\n name: 'Company Characteristic',\r\n field: 'companyDescriptor',\r\n associatedWith: 'company',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 3\r\n }, {\r\n name: 'Site Name',\r\n field: 'siteName',\r\n associatedWith: 'site',\r\n default: true,\r\n defaultDocument: true,\r\n dropdown: false,\r\n sequenceNum: 4\r\n }, {\r\n idpFilterType: 'f601',\r\n ocrFields: [\r\n 'parcelDetails.parcelIdentificationNumber',\r\n 'parcelDetails.alternativeAccountNumber',\r\n 'parcelDetails.alternativeAccountNumber1',\r\n 'parcelDetails.alternativeAccountNumber2',\r\n 'parcelDetails.alternativeAccountNumber3',\r\n 'parcelDetails.collectorAccountNumber'\r\n ],\r\n name: 'Parcel Acct Num',\r\n field: 'parcelAcctNum',\r\n associatedWith: 'parcel',\r\n default: true,\r\n defaultDocument: true,\r\n dropdown: false,\r\n sequenceNum: 11\r\n }, {\r\n name: 'Site Address',\r\n field: 'siteAddress',\r\n associatedWith: 'site',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 6,\r\n resultField: '',\r\n ocrFields: ['parcelDetails.situsAddress.line1']\r\n }, {\r\n name: 'Site City',\r\n field: 'siteCity',\r\n associatedWith: 'site',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 7,\r\n resultField: 'siteCity',\r\n ocrFields: ['parcelDetails.situsAddress.city']\r\n }, {\r\n name: 'Parcel Prop Type',\r\n field: 'parcelPropType',\r\n associatedWith: 'parcel',\r\n dropdown: true,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 12,\r\n resultField: 'propertyType'\r\n }, {\r\n name: 'Site State Abbr',\r\n field: 'siteStateAbbr',\r\n associatedWith: 'site',\r\n dropdown: true,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 8,\r\n resultField: 'siteState',\r\n ocrFields: ['parcelDetails.situsAddress.state']\r\n }, {\r\n name: 'Parcel Address',\r\n field: 'parcelAddress',\r\n associatedWith: 'parcel',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 12,\r\n resultField: ''\r\n }, {\r\n name: 'Parcel Assessee',\r\n field: 'parcelAssessee',\r\n associatedWith: 'parcel',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 16,\r\n resultField: 'assesseeName'\r\n }, {\r\n name: 'Parcel Assessor',\r\n field: 'parcelAssessor',\r\n associatedWith: 'parcel',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: true,\r\n sequenceNum: 14,\r\n resultField: '',\r\n ocrFields: ['assessorDetails.name']\r\n }, {\r\n name: 'Parcel Characteristic',\r\n field: 'parcelDescriptor',\r\n associatedWith: 'parcel',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 17\r\n }, {\r\n name: 'Parcel City',\r\n field: 'parcelCity',\r\n associatedWith: 'parcel',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 15,\r\n resultField: 'parcelCity'\r\n }, {\r\n name: 'Site Assessor',\r\n field: 'siteAssessor',\r\n associatedWith: 'site',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 9,\r\n resultField: ''\r\n }, {\r\n name: 'Site Characteristic',\r\n field: 'siteDescriptor',\r\n associatedWith: 'site',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 10\r\n }, {\r\n name: 'Site Number',\r\n field: 'siteNumber',\r\n associatedWith: 'site',\r\n dropdown: false,\r\n default: false,\r\n defaultDocument: false,\r\n sequenceNum: 5,\r\n resultField: 'propertyNumber'\r\n }];\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nexport interface SearchFilterOr {\r\n text: string;\r\n operatorId: number;\r\n}\r\n\r\nexport interface SearchFilter {\r\n name: string;\r\n field: string;\r\n associatedWith: string;\r\n default: boolean;\r\n dropdown: boolean;\r\n nullable?: boolean;\r\n numeric?: boolean;\r\n text?: string;\r\n ors?: SearchFilterOr[];\r\n}\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class SearchFiltersService {\r\n getAll(advanced: boolean): SearchFilter[] {\r\n return this._initializeFilters(advanced);\r\n }\r\n\r\n getActive(advanced: boolean): SearchFilter[] {\r\n return this._initializeFilters(advanced).filter(x => x.default);\r\n }\r\n\r\n getInactive(advanced: boolean): SearchFilter[] {\r\n return this._initializeFilters(advanced).filter(x => !x.default);\r\n }\r\n\r\n private _initializeFilters(advanced: boolean): SearchFilter[] {\r\n let filters: SearchFilter[] = [{\r\n name: 'Company Name',\r\n field: 'site.company.companyName',\r\n associatedWith: 'company',\r\n nullable: true,\r\n numeric: false,\r\n default: true,\r\n dropdown: false\r\n }, {\r\n name: 'Site Name',\r\n field: 'site.name',\r\n associatedWith: 'site',\r\n nullable: true,\r\n numeric: false,\r\n default: true,\r\n dropdown: false\r\n }, {\r\n name: 'Parcel Acct Num',\r\n field: 'acctNum',\r\n associatedWith: 'parcel',\r\n nullable: false,\r\n numeric: false,\r\n default: true,\r\n dropdown: false\r\n }, {\r\n name: 'Site Address1',\r\n field: 'site.address1',\r\n associatedWith: 'site',\r\n dropdown: false,\r\n nullable: true,\r\n numeric: false,\r\n default: false\r\n }, {\r\n name: 'Site City',\r\n field: 'site.city',\r\n associatedWith: 'site',\r\n dropdown: false,\r\n nullable: true,\r\n numeric: false,\r\n default: false\r\n }, {\r\n name: 'Site Zip Code',\r\n field: 'site.postalCode',\r\n associatedWith: 'site',\r\n dropdown: false,\r\n nullable: true,\r\n numeric: false,\r\n default: false\r\n }, {\r\n name: 'Property Type',\r\n field: 'propertyTypeID',\r\n associatedWith: 'parcel',\r\n dropdown: true,\r\n nullable: true,\r\n numeric: false,\r\n default: false\r\n }, {\r\n name: 'State Abbr',\r\n field: 'site.stateAbbr',\r\n associatedWith: 'state',\r\n dropdown: true,\r\n nullable: true,\r\n numeric: false,\r\n default: false\r\n }];\r\n\r\n filters = advanced ? filters.map(this._initializeOrs) : filters.map(this._addEmptyTexts);\r\n\r\n return filters;\r\n }\r\n\r\n private _initializeOrs(filter: SearchFilter): SearchFilter {\r\n filter.ors = [{\r\n text: '',\r\n operatorId: 0\r\n }];\r\n\r\n return filter;\r\n }\r\n\r\n private _addEmptyTexts(filter: SearchFilter): SearchFilter {\r\n filter.text = '';\r\n\r\n return filter;\r\n }\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { BaseRepository } from '../Common/Data/base.repository';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class SearchRepository extends BaseRepository {\r\n constructor(httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n private readonly SERVICE_URL = '/api/search';\r\n private readonly DEFAULT_CRITERIA_NAME = 'Search-Quick-Saved-Criteria';\r\n\r\n searchAdvanced(searchTerms): Observable {\r\n return this.httpPost(this.SERVICE_URL, searchTerms);\r\n }\r\n\r\n search(query): Observable {\r\n return this.httpPost(`${this.SERVICE_URL }/quick`, query);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { UserSettingsService } from '../Account/userSettings.service';\r\nimport { SearchRepository } from '../Core-Repositories/search.repository';\r\nimport { TimerService } from '../UI-Lib/Utilities';\r\nimport { Settings } from '../User/account.service';\r\nimport {\r\n AdvancedCriteria,\r\n QuickCriteria,\r\n QuickCriteriaFilter,\r\n QuickResultType\r\n} from './Quick/Criteria/quickCriteria.model';\r\nimport { QuickFiltersService } from './Quick/Criteria/quickFilters.service';\r\nimport { SearchOperatorsService } from './searchOperators.service';\r\nimport { SearchFilter, SearchFiltersService } from './searchFilters.service';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class SearchService {\r\n constructor(private readonly _timerService: TimerService,\r\n private readonly _userSettingsService: UserSettingsService,\r\n private readonly _quickFilters: QuickFiltersService,\r\n private readonly _searchFilters: SearchFiltersService,\r\n private readonly _searchOperators: SearchOperatorsService,\r\n private readonly _searchRepository: SearchRepository) {\r\n this.resultTypes = this.initializeResultTypes();\r\n }\r\n\r\n resultTypes: QuickResultType[] = [];\r\n criteria: QuickCriteria;\r\n resetCriteriaList: boolean;\r\n\r\n private _criteriaChangedListeners: ((msg: string) => void)[] = [];\r\n private _resetListeners: ((msg: string) => void)[] = [];\r\n private _clickedOnResultIndex: number;\r\n private _savedCriteria: Settings;\r\n private _criteriaSettings: Settings[];\r\n private _criteriaToSave: Settings[];\r\n private _activeAdvancedCriteria: AdvancedCriteria;\r\n\r\n private DEFAULT_CRITERIA_NAME: string = 'Search-Quick-Saved-Criteria';\r\n\r\n resetCriteria(): void {\r\n this.resultTypes = this.initializeResultTypes();\r\n this.criteria = this._savedCriteria ? this.getSavedDefaultCriteria() : this.getDefaultCriteria();\r\n }\r\n\r\n resetCriteriaToDefault(): void {\r\n this.criteria = this.getDefaultCriteria();\r\n }\r\n\r\n resetActiveFilterValues(): void {\r\n this.criteria.activeFilters = this.criteria.activeFilters.map(filter => {\r\n filter.text = '';\r\n\r\n return filter;\r\n });\r\n }\r\n\r\n initializeResultTypes(): QuickResultType[] {\r\n return [{\r\n name: 'Companies',\r\n type: 'company',\r\n sortBy: 'site.company.companyName',\r\n id: 1\r\n }, {\r\n name: 'Sites',\r\n type: 'site',\r\n sortBy: 'site.name',\r\n id: 5\r\n }, {\r\n name: 'Parcels',\r\n type: 'parcel',\r\n sortBy: 'acctNum',\r\n id: 6\r\n }];\r\n }\r\n\r\n convertToCompanyField(filter: SearchFilter): SearchFilter {\r\n const vals = filter.field.split('.');\r\n filter.field = vals[vals.length - 1];\r\n return filter;\r\n }\r\n\r\n setCriteria(incomingCriteria: QuickCriteria, triggerUpdate: boolean): void {\r\n this.criteria = incomingCriteria;\r\n\r\n if(triggerUpdate) {\r\n this.criteriaChanged();\r\n }\r\n }\r\n\r\n getCriteria(): QuickCriteria {\r\n return structuredClone(this.criteria);\r\n }\r\n\r\n getResultTypes(): QuickResultType[] {\r\n return this.resultTypes;\r\n }\r\n\r\n setClickedOnResultIndex(index: number): void {\r\n this._clickedOnResultIndex = index;\r\n }\r\n\r\n getClickedOnResultIndex(): number {\r\n return this._clickedOnResultIndex;\r\n }\r\n\r\n async searchElastic(pageNumber: number, numberToGet: number): Promise<{ results: QuickCriteria }> {\r\n const resultTypeObj = this.resultTypes.find(x => x.type === this.criteria.resultType);\r\n\r\n const queryParams = {\r\n resultsAs: resultTypeObj.id,\r\n activeOnly: this.criteria.activeOnly,\r\n primaryAcctNumOnly: this.criteria.primaryAcctNumOnly,\r\n pageNumber: pageNumber,\r\n pageSize: numberToGet,\r\n excludeSubsidiarySites: this.criteria.excludeSubsidiarySites\r\n };\r\n\r\n const query = this.criteria.activeFilters\r\n .filter(x => x.text)\r\n .reduce((result, filter) => {\r\n result[filter.field] = filter.text;\r\n return result;\r\n }, {...queryParams});\r\n\r\n const response = await lastValueFrom(this._searchRepository.search(query));\r\n return {\r\n results: response\r\n };\r\n }\r\n\r\n buildSortObj(entityType: string) {\r\n switch (entityType) {\r\n case 'company':\r\n return {\r\n 'companyName': true\r\n };\r\n case 'site':\r\n return {\r\n 'name': true,\r\n 'city': true,\r\n 'stateAbbr': true,\r\n 'company.companyName': true\r\n };\r\n case 'parcel':\r\n return {\r\n 'acctNum': true,\r\n 'site.city': true,\r\n 'site.stateAbbr': true,\r\n 'site.company.companyName': true\r\n };\r\n }\r\n }\r\n\r\n registerCriteriaChanged(callback: (msg: string) => void): void {\r\n this._criteriaChangedListeners.push(callback);\r\n }\r\n\r\n criteriaChanged(): void {\r\n this._criteriaChangedListeners.forEach(callback => {\r\n callback('Criteria changed.');\r\n });\r\n }\r\n\r\n registerReset(callback: (msg: string) => void): void {\r\n this._resetListeners.push(callback);\r\n }\r\n\r\n reset(): void {\r\n this._resetListeners.forEach(callback => {\r\n callback('Reset!.');\r\n });\r\n }\r\n\r\n clearCriteria(): void {\r\n this._criteriaChangedListeners.splice(1, this._criteriaChangedListeners.length - 1);\r\n }\r\n\r\n focusOnResult(index: number): void {\r\n this.focusOnElement(`.search-scroll a.list-group-item.search-result-${ index}`);\r\n }\r\n\r\n focusOnFilter(index: number): void {\r\n this.focusOnElement(`.search-filter .search-filter-${ index}`);\r\n }\r\n\r\n focusOnElement(elem: string): void {\r\n this._timerService.setTimeout(() => {\r\n const element: HTMLElement = document.querySelector(elem);\r\n if (element) {element.focus();}\r\n }, 100);\r\n }\r\n\r\n loadSavedCriteria(): void {\r\n this._savedCriteria = {\r\n id: 0,\r\n name: '',\r\n value: {},\r\n groupId: 0,\r\n groupName: '',\r\n folderId: 0,\r\n folderName: '',\r\n };\r\n\r\n this._criteriaSettings = this._userSettingsService.getSettingsByGroup(11);\r\n\r\n if (this._criteriaSettings.length > 0) {\r\n this._savedCriteria = structuredClone(this._criteriaSettings[0]);\r\n } else {\r\n this._savedCriteria = {\r\n id: 0,\r\n name: this.DEFAULT_CRITERIA_NAME,\r\n value: this.getDefaultCriteria(),\r\n groupId: 11,\r\n groupName: this.DEFAULT_CRITERIA_NAME,\r\n folderId: 20,\r\n folderName: this.DEFAULT_CRITERIA_NAME,\r\n };\r\n }\r\n }\r\n\r\n getDefaultCriteria(): QuickCriteria {\r\n return {\r\n activeFilters: this._quickFilters.getActive(),\r\n inactiveFilters: this._quickFilters.getInactive(),\r\n resultType: this.resultTypes[0].type,\r\n activeOnly: true,\r\n primaryAcctNumOnly: true\r\n };\r\n }\r\n\r\n getSavedDefaultCriteria() {\r\n // ToDo: Get by name instead of index.\r\n const defaultCriteria = this._savedCriteria.value;\r\n\r\n return structuredClone(defaultCriteria);\r\n }\r\n\r\n async saveCriteria(newCriteria: QuickCriteria): Promise {\r\n //const newCriteriaToSave = newCriteria || this.criteria;\r\n this._criteriaToSave = this._userSettingsService.getSettingsByGroup(11);\r\n\r\n if (this._criteriaToSave.length > 0) {\r\n this._savedCriteria = structuredClone(this._criteriaToSave[0]);\r\n this._savedCriteria.value = structuredClone(this.criteria);\r\n\r\n } else {\r\n this._savedCriteria = {\r\n id: 0,\r\n name: this.DEFAULT_CRITERIA_NAME,\r\n value: this.criteria,\r\n groupId: 11,\r\n groupName: this.DEFAULT_CRITERIA_NAME,\r\n folderId: 20,\r\n folderName: this.DEFAULT_CRITERIA_NAME,\r\n };\r\n }\r\n if(this._savedCriteria.value.excludeSubsidiarySites !== undefined) {\r\n delete this._savedCriteria.value.excludeSubsidiarySites;\r\n }\r\n\r\n return await this._userSettingsService.save(this._savedCriteria);\r\n }\r\n\r\n getDefaultAdvancedCriteria(): AdvancedCriteria {\r\n return {\r\n activeFilters: this._searchFilters.getActive(true),\r\n filters: this._searchFilters.getAll(true),\r\n activeOnly: true,\r\n primaryAcctNumOnly: true\r\n };\r\n }\r\n\r\n resetAdvancedCriteria(): void {\r\n this._activeAdvancedCriteria = this.getDefaultAdvancedCriteria();\r\n }\r\n\r\n sortByCategory(filter: QuickCriteriaFilter): 1| 2| 3 {\r\n switch (filter.associatedWith) {\r\n case 'company':\r\n return 1;\r\n case 'site':\r\n return 2;\r\n case 'parcel':\r\n return 3;\r\n }\r\n }\r\n\r\n isStateFilter(filter: QuickCriteriaFilter): boolean {\r\n const vals = filter.field.split('.');\r\n return vals[vals.length - 1] === 'stateAbbr';\r\n }\r\n\r\n buildAdvancedQuery(entityType: string): string {\r\n const filters: SearchFilter[] = entityType === 'company'\r\n ? this._activeAdvancedCriteria.activeFilters.map(this.convertToCompanyField.bind(this))\r\n : this._activeAdvancedCriteria.activeFilters;\r\n\r\n const shoulds = filters\r\n .filter(filter => filter.ors.some(x => x.text))\r\n .map(filter => {\r\n return filter.ors\r\n .filter(x => x.text)\r\n .map(x => {\r\n const operator = this._searchOperators.getById(x.operatorId);\r\n return operator.should(filter.field, x.text);\r\n });\r\n });\r\n\r\n const query = {\r\n bool: {\r\n should: shoulds,\r\n must_not: []\r\n }\r\n };\r\n\r\n if (this._activeAdvancedCriteria.activeOnly) {\r\n query.bool.must_not = [{\r\n match: {\r\n activityStatusID: '0'\r\n }\r\n }];\r\n }\r\n\r\n return encodeURIComponent(JSON.stringify(query));\r\n }\r\n\r\n setActiveAdvancedCriteria(incomingCriteria: AdvancedCriteria): void {\r\n this._activeAdvancedCriteria = incomingCriteria;\r\n }\r\n\r\n searchAdvanced(startFrom: number, numberToGet: number) {\r\n const entityType = this.getEntityType();\r\n\r\n const searchTerms = {\r\n query: this.buildAdvancedQuery(entityType),\r\n filter: 'ignoring filters for now',\r\n entityType: entityType, // which 'table' you want to search\r\n //sortByField: resultTypeObj.sort, // not in use anymore\r\n //sortAsc: 'true', // not in use anymore\r\n sortByFields: this.buildSortObj(entityType),\r\n startFromRecord: startFrom,\r\n numberOfRecordsToGrab: numberToGet\r\n };\r\n\r\n return lastValueFrom(this._searchRepository.searchAdvanced(searchTerms))\r\n .then((response) => {\r\n return {\r\n results: JSON.parse(response.resultJson),\r\n totalCount: response.totalNumberOfRecords\r\n };\r\n });\r\n }\r\n\r\n getEntityType(): 'parcel' | 'site' | 'company' {\r\n const filtersWithInput = this._activeAdvancedCriteria.activeFilters.filter((filter) => {\r\n return filter.ors.some(x => x.text);\r\n });\r\n\r\n if (filtersWithInput.some(x => x.associatedWith === 'parcel')) {\r\n return 'parcel';\r\n } else if (filtersWithInput.some(x => x.associatedWith === 'site')) {\r\n return 'site';\r\n } else if (filtersWithInput.some(x => x.associatedWith === 'company')) {\r\n return 'company';\r\n } else {\r\n // must be state only\r\n return 'parcel';\r\n }\r\n }\r\n\r\n getActiveAdvancedCriteria() {\r\n return this._activeAdvancedCriteria;\r\n }\r\n\r\n // saveAdvancedCriteria(criteria: AdvancedCriteria) {\r\n // return this._userSettingsService.save(this.criteria).then((result) => {\r\n // this._activeAdvancedCriteria = result.value;\r\n // });\r\n // }\r\n\r\n deleteAdvancedCriteria(criteria) {\r\n // return this._userSettingsService.delete(this._userService.getUser().id, this.criteria.id);\r\n }\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { BaseRepository } from '../Common/Data/base.repository';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class NavigationRepository extends BaseRepository {\r\n constructor(\r\n httpClient: HttpClient\r\n ) {\r\n super(httpClient);\r\n }\r\n\r\n getNavigationInfo(entityName: string, id: number): Observable {\r\n return this.httpGet(`/api/${ entityName }/${ id }/Navigation`);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { Transition } from '@uirouter/core/lib/transition/transition';\r\nimport { BehaviorSubject, lastValueFrom, Observable, Subject } from 'rxjs';\r\nimport { CurrentEntityService } from '../Common/Entity/CurrentEntityService';\r\nimport { RestrictService } from '../Common/Permissions/restrict.service';\r\nimport { NavigationRepository } from '../Core-Repositories/navigation.repository';\r\nimport { SearchService } from '../Search/search.service';\r\nimport { MessageBoxService } from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { AccountService, GrantTypes, ILoginData } from '../User/account.service';\r\nimport { AuthStorageService } from '../User/authStorage.service';\r\n\r\nexport interface LoginFromSSOModel {\r\n message: string,\r\n grantType: GrantTypes,\r\n request: string | ILoginData\r\n}\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class NavigationService {\r\n constructor(private readonly _accountService: AccountService,\r\n private readonly _searchService: SearchService,\r\n private readonly _authStorageService: AuthStorageService,\r\n private readonly _currentEntityService: CurrentEntityService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _navigationRepository: NavigationRepository,\r\n private readonly _router: UIRouter) {\r\n }\r\n\r\n childWindows = [];\r\n navWarningEnabled: boolean;\r\n initialUrl: string;\r\n\r\n private _globalEditModeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _globalEditMode$: Observable = this._globalEditModeSubject.asObservable();\r\n\r\n private _loginFromSSOSubject: Subject = new Subject();\r\n private _loginFromSSO$: Observable = this._loginFromSSOSubject.asObservable();\r\n\r\n private _quickSearchListeners = [];\r\n private _globals = {\r\n defaultState: 'home',\r\n anonymousStates: [\r\n 'login',\r\n 'register',\r\n 'resetPasswordUsingTokenFromEmail',\r\n 'ssoLogin'\r\n ],\r\n storedState: '',\r\n storedParams: null\r\n };\r\n private _quickSearchInitiator: string;\r\n\r\n get quickSearchInitiator(): string {\r\n return this._quickSearchInitiator;\r\n }\r\n\r\n get globalEditMode$(): Observable {\r\n return this._globalEditMode$;\r\n }\r\n\r\n get loginFromSSO$(): Observable {\r\n return this._loginFromSSO$;\r\n }\r\n\r\n set quickSearchInitiator(value: string) {\r\n this._quickSearchInitiator = value;\r\n }\r\n\r\n set loginFromSSO(value: LoginFromSSOModel) {\r\n this._loginFromSSOSubject.next(value);\r\n }\r\n\r\n registerQuickSearch(callback: (string) => void): void {\r\n this._quickSearchListeners.push(callback);\r\n }\r\n\r\n openQuickSearch(resetCriteriaList: boolean, navigatingFrom?: string): void {\r\n // ToDo: This is here because the shortcut key to open quick search is activated during app load. Fix it!\r\n if (this._accountService.userData) {\r\n this._quickSearchInitiator = navigatingFrom;\r\n this._searchService.resetCriteriaList = resetCriteriaList;\r\n\r\n this._quickSearchListeners.forEach((callback) => {\r\n callback(navigatingFrom);\r\n });\r\n }\r\n }\r\n\r\n async onNavStart(transition: Transition): Promise {\r\n this.initialUrl = window.location.href;\r\n\r\n const toState = transition.to();\r\n const toParams = transition.params();\r\n this._authStorageService.recordActivity('Navigation');\r\n // Skip navigation guard if we're going to an anonymous state (like login)\r\n const isRestricted = !this._globals.anonymousStates.includes(toState.name);\r\n if (!isRestricted) {\r\n return;\r\n }\r\n\r\n await this._accountService.navPromise();\r\n\r\n this._currentEntityService.init();\r\n\r\n if (!this._accountService.userData) {\r\n this._globals.storedState = toState.name;\r\n this._globals.storedParams = toParams;\r\n\r\n return transition.router.stateService.target('login');\r\n //$state.go('login');\r\n } else if (toState.name !== 'login') {\r\n // Remember last state visited except login.\r\n this._globals.storedState = toState.name;\r\n this._globals.storedParams = toParams;\r\n }\r\n\r\n // global roles check\r\n if (toState.data && toState.data.roles) {\r\n // check application permissions\r\n if (this._restrictService.isNotInRoles(toState.data.roles)) {\r\n return transition.router.stateService.target('unauthorizedAccess');\r\n }\r\n }\r\n\r\n // instance rights check\r\n if (toState.data && toState.data.instanceRights) {\r\n // check application permissions\r\n if (this._restrictService.hasNoInstanceRights(toState.data.instanceRights)) {\r\n return transition.router.stateService.target('unauthorizedAccess');\r\n }\r\n }\r\n }\r\n\r\n postLogin(): void {\r\n // Make sure the login state didn't find it's way into the storedState property.\r\n if (this._globals.storedState.indexOf('login') !== -1 || this._globals.storedState.length === 0) {\r\n this._globals.storedState = this._globals.defaultState;\r\n }\r\n\r\n if (this._globals.storedState === 'unauthorizedAccess' || this._globals.storedState === 'logout' || this._globals.storedState === 'resetPasswordUsingTokenFromEmail') {\r\n this._router.stateService.go('home');\r\n } else {\r\n this._router.stateService.go(this._globals.storedState, this._globals.storedParams);\r\n }\r\n }\r\n\r\n goToLogin(isLogout: boolean): void {\r\n console.log('Navigation.Service - goToLogin', isLogout);\r\n if (isLogout) {\r\n this._globals.storedState = 'home';\r\n this._router.stateService.go('login', { logout: true });\r\n } else {\r\n this._router.stateService.go('login');\r\n }\r\n }\r\n\r\n setDefaultUnload(): void {\r\n window.onbeforeunload = () => {\r\n for (let i = 0; i < this.childWindows.length; i++) {\r\n const childWindow = this.childWindows[i];\r\n if (childWindow && !childWindow.closed) {\r\n childWindow.close();\r\n }\r\n }\r\n };\r\n }\r\n\r\n registerChildWindow(childWindow: any): void {\r\n this.childWindows.push(childWindow);\r\n if (!this.navWarningEnabled) {\r\n this.setDefaultUnload();\r\n }\r\n }\r\n\r\n enableNavWarning(message: string): void {\r\n this.navWarningEnabled = true;\r\n this._globalEditModeSubject.next(true);\r\n\r\n // First handle angular routing change\r\n this._router.transitionService.onBefore({}, async () => {\r\n if (this.navWarningEnabled) {\r\n await this._messageBoxService.confirm(message);\r\n this.disableNavWarning();\r\n }\r\n });\r\n\r\n // Now handle browser navigation changes\r\n // This message is ignored in Chrome, but at least it still warns the user\r\n window.onbeforeunload = (e) => {\r\n for (let i = 0; i < this.childWindows.length; i++) {\r\n const childWindow = this.childWindows[i];\r\n if (childWindow && !childWindow.closed) {\r\n childWindow.close();\r\n }\r\n }\r\n // If we haven't been passed the event get the window.event\r\n e = e || window.event;\r\n\r\n // For IE6-8 and Firefox prior to version 4\r\n if (e) {\r\n e.returnValue = message;\r\n }\r\n\r\n // For Chrome, Safari, IE8+ and Opera 12+\r\n return message;\r\n };\r\n }\r\n\r\n disableNavWarning(): void {\r\n this.navWarningEnabled = false;\r\n this._globalEditModeSubject.next(false);\r\n this.setDefaultUnload();\r\n }\r\n\r\n getNavigationInfo(entityName: string, id: number): Promise {\r\n return lastValueFrom(this._navigationRepository.getNavigationInfo(entityName, id));\r\n }\r\n\r\n getInitialUrl(): string {\r\n return this.initialUrl;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nexport interface IPubSubSubscription {\r\n unsubscribe: () => void;\r\n}\r\n\r\nexport interface IPubSubService {\r\n publish: (topic: string, data?: any) => void;\r\n publishParent: (topic: string, data?: any) => void;\r\n publishChild: (childWindow: Window, topic: string, data?: any) => void;\r\n subscribe: (topic: string, callback: (data: any, topic: string, windowName: string) => void) => IPubSubSubscription;\r\n subscribeOnce: (topic: string, callback: (data: any, topic: string, windowName: string) => void) => IPubSubSubscription;\r\n}\r\n\r\n/**\r\n * WARNING: We should use RXJS instead of this\r\n */\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class PubSubService implements IPubSubService {\r\n constructor() {\r\n window.addEventListener('message', (event: Event) => {\r\n if (event['origin'] !== window['origin']) return;\r\n\r\n const messageInfo = event['data'];\r\n this._invokeCallback(messageInfo.publishTopic, messageInfo.publishData, messageInfo.publishWindowName);\r\n }, false);\r\n }\r\n\r\n private readonly _Messages = {\r\n MissingPublishTopic: 'Missing topic. A topic is required for publishing.',\r\n MissingSubscriptionTopic: 'Missing topic. A subscription topic is required.',\r\n MissingTargetWindow: 'Missing target window. A target window is required for publishing.',\r\n FailedInvokingCallback: 'Failed executing subscription callback.'\r\n };\r\n\r\n // key/value map of topic names and a collection of subscribers\r\n private _subscriptions: { [topic: string]: any[] } = { };\r\n\r\n publish(topic: string, data?: any): void {\r\n if (!topic) throw new Error(this._Messages.MissingPublishTopic);\r\n\r\n this._invokeCallback(topic, data);\r\n }\r\n\r\n publishParent(topic: string, data?: any): void {\r\n if (!topic) throw new Error(this._Messages.MissingPublishTopic);\r\n if (!window.opener) throw new Error(this._Messages.MissingTargetWindow);\r\n\r\n this._publishRemote(window.opener, topic, data);\r\n }\r\n\r\n publishChild(targetWindow: Window, topic: string, data?: any): void {\r\n if (!topic) throw new Error(this._Messages.MissingPublishTopic);\r\n if (!targetWindow) throw new Error(this._Messages.MissingTargetWindow);\r\n\r\n this._publishRemote(targetWindow, topic, data);\r\n }\r\n\r\n subscribe(topic: string, callback: (data: any, topic: string, windowName: string) => void): IPubSubSubscription {\r\n if (!topic) throw new Error(this._Messages.MissingSubscriptionTopic);\r\n\r\n const subscribers = this._subscriptions[topic] || (this._subscriptions[topic] = []);\r\n subscribers.push(callback);\r\n return {\r\n unsubscribe: () => {\r\n const index = subscribers.indexOf(callback);\r\n if (index !== -1) {\r\n subscribers.splice(index, 1);\r\n }\r\n }\r\n };\r\n }\r\n\r\n subscribeOnce(topic: string, callback: (data: any, topic: string, windowName: string) => void): IPubSubSubscription {\r\n const subscription = this.subscribe(topic, (a, b, c) => {\r\n subscription.unsubscribe();\r\n return callback(a, b, c);\r\n });\r\n return subscription;\r\n }\r\n\r\n private _invokeCallback(topic: string, data?: any, windowName?: string) {\r\n let subscribers = this._subscriptions[topic];\r\n if (subscribers) {\r\n subscribers = subscribers.slice();\r\n let i = subscribers.length;\r\n while (i--) {\r\n try {\r\n subscribers[i](data, topic, windowName);\r\n } catch(e) {\r\n console.error(this._Messages.FailedInvokingCallback, e);\r\n }\r\n }\r\n }\r\n }\r\n\r\n private _publishRemote(targetWindow: Window, topic: string, data?: any): void {\r\n const postMessageInfo = {\r\n publishTopic: topic,\r\n publishData: data,\r\n publishWindowName: window.name\r\n };\r\n targetWindow.postMessage(postMessageInfo, '*');\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../Routing/upgrade-navigation-handler.service';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { PubSubService, IPubSubSubscription } from './pubsub.service';\r\n\r\n/** A collection of topics for communication with the pop-up window via RPC. */\r\nexport interface IPopUpTopics {\r\n Attachment: {\r\n PreviewInitialized: string;\r\n AttachmentChanged: string;\r\n }\r\n}\r\n\r\n/** A collection of identifiers for global windows access in multiple points. */\r\nexport interface IPopUpStaticAliases {\r\n Attachment: string;\r\n}\r\n\r\n/** Pop-Up Service Interface */\r\nexport interface IPopUpService {\r\n StaticAliases: IPopUpStaticAliases;\r\n Topics: IPopUpTopics;\r\n openAttachmentPreview: (aliasGroup?: string, ref?: IPopUpRef) => Promise;\r\n closeByAliasGroup: (aliasGroup: string) => void;\r\n getByAliasGroup: (aliasGroup: string) => IPopUpRef[];\r\n}\r\n\r\n/** A public API for communicating with a pop-up window. */\r\nexport interface IPopUpRef {\r\n publish: (topic: string, data?: any) => void;\r\n isOpen: () => boolean;\r\n close: () => void;\r\n}\r\n\r\n/** A private API for communicating with a pop-up window. */\r\ninterface IPopUp {\r\n aliasGroup: string;\r\n windowName: string;\r\n window: Window;\r\n ref: IPopUpRef;\r\n close: () => void;\r\n // used to resolve the promise and notify the caller that the pop-up window is ready to interact with\r\n ready: (ref: IPopUpRef) => void;\r\n}\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class PopUpService implements IPopUpService {\r\n constructor(\r\n private _navigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private _navigationService: NavigationService,\r\n private _toastr: ToastrService,\r\n private _pubsub: PubSubService\r\n ) { }\r\n\r\n readonly StaticAliases = {\r\n Attachment: 'global-attachment-pop-up'\r\n };\r\n\r\n readonly Topics = {\r\n Attachment: {\r\n PreviewInitialized: 'topics.attachment.preview-initialized',\r\n AttachmentChanged: 'topics.attachment.attachment-changed'\r\n }\r\n };\r\n\r\n private readonly _Messages = {\r\n PopUpBlocked: 'Your web browser appears to have blocked this function from opening a pop-up window. Please check your browser settings.'\r\n };\r\n\r\n private readonly _AppStates = {\r\n AttachmentPreview: 'attachmentPopup'\r\n };\r\n\r\n private _lastUsedWindowName: number = 0;\r\n\r\n // a collection of all pop-up\r\n private _popUps: IPopUp[] = [];\r\n\r\n private _attachmentPreviewInitializedSubscription: IPubSubSubscription;\r\n\r\n openAttachmentPreview(aliasGroup?: string, ref?: IPopUpRef): Promise {\r\n // we're using one subscription handlers for all attachment windows and resolving the correct pop-up reference within that handler\r\n if (!this._attachmentPreviewInitializedSubscription) {\r\n this._attachmentPreviewInitializedSubscription = this._pubsub.subscribe(this.Topics.Attachment.PreviewInitialized, this._attachmentPreviewInitializedCallback.bind(this));\r\n }\r\n\r\n return new Promise((resolve, reject) => {\r\n // figure out what URL we're navigating to\r\n const url = this._navigationServiceHandler.getHrefFromState(this._AppStates.AttachmentPreview, null);\r\n\r\n // if a pop-up ref was specified, find the existing pop-up associated with it\r\n let popUp = this._popUps.find((i) => { return i.ref === ref; });\r\n\r\n // if no pop-up was found, create a new one\r\n if (!popUp) {\r\n popUp = {\r\n aliasGroup: aliasGroup,\r\n window: null,\r\n windowName: this._getNextWindowName(),\r\n ref: {\r\n publish: (topic: string, data?: any) => {\r\n if (popUp.window && !popUp.window.closed) {\r\n popUp.window.focus();\r\n this._pubsub.publishChild(popUp.window, topic, data);\r\n }\r\n },\r\n isOpen: () => {\r\n return popUp.window && !popUp.window.closed;\r\n },\r\n close: () => { popUp.close(); }\r\n },\r\n close: () => {\r\n if (popUp.window && !popUp.window.closed) {\r\n popUp.window.close();\r\n }\r\n delete popUp.window;\r\n delete popUp.windowName;\r\n const index = this._popUps.indexOf(popUp);\r\n if (index !== -1) {\r\n this._popUps.splice(index, 1);\r\n }\r\n },\r\n // keep track of the resolve so we can notify the caller later that the pop-up is ready\r\n ready: resolve\r\n };\r\n popUp.window = this._openWindow(url, popUp.windowName);\r\n if (popUp.window) {\r\n this._navigationService.registerChildWindow(popUp.window);\r\n this._popUps.push(popUp);\r\n } else {\r\n reject && reject();\r\n }\r\n return;\r\n }\r\n\r\n // if found a pop-up but the window was closed by the user, we will re-open using same ref\r\n if (popUp && popUp.window && popUp.window.closed) {\r\n popUp.ready = resolve;\r\n popUp.window = this._openWindow(url, popUp.windowName);\r\n if (popUp.window) {\r\n this._navigationService.registerChildWindow(popUp.window);\r\n this._popUps.push(popUp);\r\n } else {\r\n reject();\r\n }\r\n return;\r\n }\r\n\r\n // if found a pop-up and the window is open, we will reload using same ref and bring the window to focus\r\n if (popUp && popUp.window && !popUp.window.closed) {\r\n popUp.ready = resolve;\r\n popUp.window.focus();\r\n // (see logoutMessage.component.ts for notes on why the any cast is necessary)\r\n (popUp.window.location).reload(true);\r\n return;\r\n }\r\n\r\n // we should never get here, all cases should have been covered in the IF checks above\r\n console.warn('Unknown state of the pop-up reference. Check pop-up handling logic to determine next step.');\r\n reject();\r\n });\r\n }\r\n\r\n closeByAliasGroup(aliasGroup: string) {\r\n const popUps = this._popUps.filter((i) => i.aliasGroup === aliasGroup);\r\n let i = popUps.length;\r\n while (i--) {\r\n popUps[i].close();\r\n }\r\n }\r\n\r\n getByAliasGroup(aliasGroup: string): IPopUpRef[] {\r\n return this._popUps\r\n .filter((i) => i.aliasGroup === aliasGroup)\r\n .map((i) => i.ref);\r\n }\r\n\r\n private _attachmentPreviewInitializedCallback(data: any, topic: string, windowName: string): void {\r\n // child window is ready, find the pop-up by window name and notify the caller that it is ready\r\n const popUp = this._popUps.find((i) => i.windowName === windowName);\r\n if (popUp) {\r\n popUp.ready(popUp.ref);\r\n }\r\n }\r\n\r\n private _getNextWindowName(): string {\r\n return `WEISSMAN_${++this._lastUsedWindowName}`;\r\n }\r\n\r\n private _openWindow(url: string, windowName: string): Window {\r\n const left = window.screenLeft + (0.6 * window.outerWidth) - 100;\r\n const top = window.screenTop;\r\n const width = (0.4 * window.outerWidth);\r\n const height = window.outerHeight - 100;\r\n\r\n const childWindow = window.open(url, windowName, `toolbar=no,location=no,directories=no,status=no,menubar=no,resizable=yes,left=${left},top=${top},width=${width},height=${height}`);\r\n if (!childWindow) {\r\n this._toastr.warning(this._Messages.PopUpBlocked);\r\n }\r\n return childWindow;\r\n }\r\n\r\n}\r\n","
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n Type is required.\r\n
\r\n
\r\n \r\n \r\n \r\n Year is required for the selected type.\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n

\r\n Only visible to Ryan personnel\r\n

\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, NgZone, OnInit, Output } from '@angular/core';\r\nimport { EntityTypeIds, EntityTypeLevels } from 'src/app/constants.new';\r\nimport { AbstractControl, UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { EmptyGuid } from '../../constants.new';\r\n\r\nimport * as _ from 'lodash';\r\nimport { AttachmentService } from '../attachment.service';\r\nimport { Attachment } from '../attachment.model';\r\n\r\n@Component({\r\n selector: 'attachment-form',\r\n templateUrl: './attachmentForm.component.html'\r\n})\r\nexport class AttachmentFormComponent implements OnInit {\r\n constructor(\r\n private readonly _attachmentService: AttachmentService,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _ngZone: NgZone,\r\n private readonly _toastr: ToastrService\r\n ) {}\r\n\r\n @Input() attachment;\r\n @Input() currentEntity;\r\n @Input() defaultYear: number;\r\n @Input() disableYears: boolean;\r\n @Input() disableAttachmentType: boolean;\r\n @Input() attachmentTypeId: Core.AttachmentTypes;\r\n\r\n @Output() attachmentFormUpdated: EventEmitter = new EventEmitter();\r\n @Output() attachmentFormCreated: EventEmitter = new EventEmitter();\r\n @Output() attachmentFormDeleted: EventEmitter = new EventEmitter();\r\n @Output() attachmentFormCancelled: EventEmitter = new EventEmitter();\r\n\r\n attachmentForm: UntypedFormGroup;\r\n\r\n years: Compliance.NameValuePair[] = [];\r\n attachmentTypes: Core.AttachmentTypeModel[] = [];\r\n submitButtonLabel: string = 'Save';\r\n isSaving: boolean;\r\n noYear: boolean;\r\n isDeleting: boolean;\r\n loading: boolean;\r\n\r\n private _fetchedCategories: any;\r\n private _fetchedTypes: any;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get type(): AbstractControl {\r\n return this.attachmentForm.get('type');\r\n }\r\n\r\n get year(): AbstractControl {\r\n return this.attachmentForm.get('year');\r\n }\r\n\r\n get file(): AbstractControl {\r\n return this.attachmentForm.get('file');\r\n }\r\n\r\n async ngOnInit() {// populate years\r\n this.populateYears();\r\n\r\n // disable year dropdown for an attachment at a level below parcel\r\n this.noYear = EntityTypeLevels[this.currentEntity.typeId] < EntityTypeLevels[EntityTypeIds.PARCEL];\r\n\r\n this.attachmentForm = this._fb.group({\r\n type: [null, Validators.required],\r\n year: [{ value: this.defaultYear, disabled: this.noYear || this.disableYears }],\r\n description: [''],\r\n file: [null, Validators.required]\r\n });\r\n\r\n this.type.valueChanges.pipe(takeUntil(this._destroy$)).subscribe(type => {\r\n const validator = type.taxYearRequired ? [Validators.required] : [];\r\n this.year.setValidators(validator);\r\n this.year.updateValueAndValidity();\r\n });\r\n\r\n if (this.attachment) {\r\n // initialize view model for editing attachment\r\n this.attachmentForm.patchValue({\r\n year: this.attachment.year,\r\n description: this.attachment.description\r\n });\r\n\r\n this.file.setValidators([]);\r\n this.file.updateValueAndValidity();\r\n }\r\n\r\n // populate attachment categories and types from cache\r\n if (this._fetchedCategories) {\r\n this.populateTypes(this._fetchedTypes);\r\n } else {\r\n this.loading = true;\r\n\r\n try {\r\n // populate attachment categories and types from db\r\n this._fetchedCategories = {};\r\n const categories = await this._attachmentService.getAttachmentCategories();\r\n categories.forEach((category) => {\r\n this._fetchedCategories[category.attachmentCategoryID] = category.category;\r\n });\r\n\r\n // populate attachmentTypes\r\n const types = await this._attachmentService.getAttachmentTypes();\r\n this.populateTypes(types);\r\n // cache the result\r\n this._fetchedTypes = types;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n if (this.attachmentTypeId) {\r\n this.type.setValue(this.attachmentTypes.find(x => x.attachmentTypeID === this.attachmentTypeId));\r\n }\r\n\r\n if (this.disableAttachmentType) {\r\n this.type.disable();\r\n }\r\n }\r\n\r\n populateTypes(types: Core.AttachmentTypeModel[]): void {\r\n types.forEach((type) => {\r\n if (this.allowType(type)) {\r\n type['displayName'] = `${this._fetchedCategories[type.attachmentCategoryID] } - ${ type.attachmentTypeName}`;\r\n this.attachmentTypes.push(type);\r\n // determine editing attachment type\r\n if (this.attachment && this.attachment.attachmentTypeID === type.attachmentTypeID) {\r\n this.attachmentForm.patchValue({ type });\r\n if (type.taxYearRequired) {\r\n this.year.setValidators([Validators.required]);\r\n this.year.updateValueAndValidity();\r\n }\r\n }\r\n }\r\n });\r\n }\r\n\r\n allowType(type) {\r\n switch (this.currentEntity.typeId) {\r\n case EntityTypeIds.SITE:\r\n return type.allowAtSite;\r\n case EntityTypeIds.PARCEL:\r\n return type.allowAtParcel;\r\n case EntityTypeIds.TAX_BILL:\r\n return type.allowAtTaxBill;\r\n case EntityTypeIds.COMPANY:\r\n return type.allowAtCompany;\r\n case EntityTypeIds.ASSESSMENT:\r\n return type.allowAtAssessment;\r\n case EntityTypeIds.APPEAL:\r\n return type.allowAtAppeal;\r\n case EntityTypeIds.REFUND:\r\n return type.allowAtRefund;\r\n case EntityTypeIds.FILING:\r\n return type.allowAtPPReturn;\r\n case EntityTypeIds.INVOICE:\r\n return type.allowAtInvoice;\r\n case EntityTypeIds.STATE:\r\n return type.allowAtState;\r\n case EntityTypeIds.COLLECTOR:\r\n return type.allowAtCollector;\r\n case EntityTypeIds.ASSESSOR:\r\n return type.allowAtAssessor;\r\n case EntityTypeIds.FORM:\r\n return type.allowAtForm;\r\n case EntityTypeIds.FORMREVISION:\r\n return type.allowAtFormRevision;\r\n case EntityTypeIds.FACTORTABLE:\r\n return type.allowAtFactorTable;\r\n case EntityTypeIds.FILINGBATCH:\r\n return type.allowAtFilingBatch;\r\n case EntityTypeIds.TAXAUTHORITY:\r\n return type.allowAtTaxAuthority;\r\n case EntityTypeIds.TAXRATEAREA:\r\n return type.allowAtTaxRateArea;\r\n case EntityTypeIds.BUDGET:\r\n return type.allowAtBudget;\r\n case EntityTypeIds.ACCOUNTINGPERIOD:\r\n return type.allowAtAccountingPeriod;\r\n case EntityTypeIds.ALLOCATION:\r\n return type.allowAtAllocation;\r\n case EntityTypeIds.PAYMENT_BATCH:\r\n return type.allowAtPaymentBatch;\r\n case EntityTypeIds.PAYMENT:\r\n return type.allowAtTaxPayment;\r\n }\r\n return false;\r\n }\r\n\r\n populateYears(): void {\r\n const now = new Date();\r\n const currentYear = now.getFullYear();\r\n\r\n this.years.push({\r\n name: '',\r\n value: null\r\n });\r\n\r\n // WK-9315 We typically would use currentYear - 10 as the cutoff, but we received an oddball\r\n // request to allow 2010 as an option at the beginning of 2021. As a quick fix we just added\r\n // a year to the available list, but perhaps in the long term we need to add a \"more\" option\r\n // to the bottom of the list and allow the user to enter a year outside the range.\r\n for (let i = currentYear + 3; i >= currentYear - 11; i--) {\r\n this.years.push({\r\n name: `${i}`,\r\n value: i\r\n });\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n this.submitButtonLabel = 'Saving...';\r\n this.isSaving = true;\r\n\r\n await this.updateOrCreate();\r\n\r\n this.isSaving = false;\r\n this.submitButtonLabel = 'Save';\r\n }\r\n\r\n async updateOrCreate(): Promise {\r\n if (this.attachment) {\r\n await this.update();\r\n } else {\r\n await this.create();\r\n }\r\n }\r\n\r\n async update(): Promise {\r\n const attachmentToUpdate = _.cloneDeep(this.attachment);\r\n const formValues = this.attachmentForm.getRawValue();\r\n\r\n const update = {\r\n ...attachmentToUpdate,\r\n ...{\r\n attachmentCategoryID: formValues.type.attachmentCategoryID,\r\n attachmentTypeID: formValues.type.attachmentTypeID,\r\n description: formValues.description,\r\n year: formValues.year !== 'All' ? parseInt(formValues.year) : null\r\n }\r\n };\r\n\r\n try {\r\n const result = await this._attachmentService.update(update);\r\n this.attachmentFormUpdated.emit(result);\r\n } catch(err) {\r\n this._toastr.error('There was an error creating this attachment.');\r\n\r\n }\r\n }\r\n\r\n async create() {\r\n const formValues = this.attachmentForm.getRawValue();\r\n\r\n const attachmentData = {\r\n externalID: '1',\r\n entityID: this.currentEntity.id,\r\n entityTypeID: this.currentEntity.typeId,\r\n fileName: formValues.file.name,\r\n fileExtension: formValues.file.name.substring(formValues.file.name.lastIndexOf('.')),\r\n description: formValues.description,\r\n year: formValues.year !== 'All' ? parseInt(formValues.year) : null,\r\n attachmentCategoryID: formValues.type.attachmentCategoryID,\r\n attachmentTypeID: formValues.type.attachmentTypeID,\r\n ownerType: 0,\r\n ownerName: null,\r\n secondaryOwnerName: null,\r\n size: formValues.file.size,\r\n numberOfPages: 0,\r\n metaData: 'done',\r\n changedBy: EmptyGuid,\r\n changeDate: '2015-12-04T08:33:15.193',\r\n efAction: null\r\n } as any;\r\n\r\n try {\r\n const result = await this._attachmentService.createAttachment([formValues.file], attachmentData);\r\n\r\n // TODO: the result from server should include the generated attachment id so that\r\n // it can be set on attachmentData. e.g. attachmentData.attachmentID = result.attachmentID\r\n this.attachmentFormCreated.emit(result[0]);\r\n } catch(err) {\r\n this._toastr.error((err && err.error && err.error.message) ?\r\n err.error.message :\r\n 'There was an error creating this attachment.');\r\n\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this.attachmentFormCancelled.emit();\r\n }\r\n\r\n attachmentFilePicked(files: File[]): void {\r\n this._ngZone.run(() => {\r\n this.attachmentForm.patchValue({file: files[0]});\r\n });\r\n }\r\n\r\n async deleteAttachment(): Promise {\r\n\r\n // Removing for now, because this window is appear behind the attachment modal\r\n // Need to straigten out our z-indices before adding back in\r\n //\r\n // try {\r\n // await this._messageModalService.confirm('Confirm Delete Attachment.');\r\n // } catch(err) {\r\n // return;\r\n // }\r\n\r\n if(confirm('Confirm Delete Attachment.')) {\r\n this.isDeleting = true;\r\n\r\n try {\r\n await this._attachmentService.deleteAttachment(this.attachment);\r\n\r\n this.isDeleting = false;\r\n this.attachmentFormDeleted.emit(this.attachment);\r\n } finally {\r\n this.isDeleting = false;\r\n }\r\n }\r\n\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Constants } from '../../constants.new';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class LoadPdfIframeService {\r\n constructor(private constants:Constants) { }\r\n\r\n initializePdfJs(iframe: HTMLIFrameElement, file: string, readOnly?: boolean): void {\r\n this.updatePdfJs(iframe, file);\r\n // NOTE: Don't convert this to an arrow function; this is referenced and will have a different\r\n // meaning if this uses an arrow function instead\r\n iframe.addEventListener('load', function () {\r\n // https://stackoverflow.com/a/72229532/18059803\r\n this.contentWindow.onbeforeunload = function (event) {\r\n event.stopImmediatePropagation();\r\n };\r\n\r\n const doc = this.contentWindow.document;\r\n const styleElement = doc.createElement('style');\r\n styleElement.type = 'text/css';\r\n let styleText = '#outerContainer #openFile,#openFile { display: none; }';\r\n if(readOnly) {\r\n styleText += '\\n .pdfViewer { pointer-events: none }';\r\n }\r\n styleElement.appendChild(doc.createTextNode(styleText));\r\n doc.head.appendChild(styleElement);\r\n });\r\n }\r\n\r\n updatePdfJs(iframe: HTMLElement, file: string): void {\r\n iframe.setAttribute('src', `${this.constants.PdfJsBase}web/viewer.html?file=${encodeURIComponent(file)}`);\r\n iframe.classList.add('preview-window');\r\n }\r\n}\r\n","import { Component, ElementRef, Input, OnInit, ViewChild } from '@angular/core';\r\nimport { LoadPdfIframeService } from './LoadPdfIframeService';\r\n\r\n@Component({\r\n selector: 'pdf-viewer',\r\n template: ''\r\n})\r\nexport class PDFViewerComponent implements OnInit {\r\n constructor(private loadPdfIframeService: LoadPdfIframeService) { }\r\n\r\n @Input() fileUrl: string;\r\n @ViewChild('iframe', { static: true }) iframe: ElementRef;\r\n\r\n ngOnInit(): void {\r\n this.loadPdfIframeService.initializePdfJs(this.iframe.nativeElement, this.fileUrl);\r\n }\r\n}\r\n","import { Component, ElementRef, Input, OnInit, ViewChild } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'file-viewer',\r\n template: `\r\n \r\n
{{text}}
\r\n \"Image\r\n `,\r\n styles: [`\r\n .preview-window {\r\n white-space: pre-wrap;\r\n word-break: break-word;\r\n }\r\n .preview-window-image {\r\n margin: auto;\r\n max-width: 100%;\r\n max-height: 100%;\r\n }\r\n `]\r\n})\r\nexport class FileViewerComponent implements OnInit {\r\n @Input() file: File;\r\n @ViewChild('elemRoot') elemRoot: ElementRef;\r\n fileUrl: string;\r\n text: string | ArrayBuffer;\r\n isImage: boolean = false;\r\n\r\n ngOnInit(): void {\r\n if (this.file.type === 'text/plain') {\r\n const fileReader = new FileReader();\r\n fileReader.onload = () => {\r\n this.text = fileReader.result;\r\n };\r\n\r\n fileReader.readAsText(this.file);\r\n } else if (this.file.type.split('/')[0] === 'image') {\r\n const reader = new FileReader();\r\n reader.readAsDataURL(this.file);\r\n reader.onload = () => {\r\n this.fileUrl = reader.result as string;\r\n this.isImage = true;\r\n };\r\n } else {\r\n const blob = new Blob([this.file], { type: this.file.type });\r\n this.fileUrl = URL.createObjectURL(blob);\r\n }\r\n }\r\n}\r\n","\r\n \r\n\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
0 && selectedAttachment\">\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n Added by: {{ selectedAttachment.createdByLastName }}, {{ selectedAttachment.createdByFirstName }}\r\n {{ displayDate(selectedAttachment.createdDate) }}\r\n
\r\n
{{ selectedAttachment?.lineTwo || 'Preview Window' }}
\r\n
Added by: {{ selectedAttachment.createdByLastName }}\r\n , {{ selectedAttachment.createdByFirstName }}\r\n {{ displayDate(selectedAttachment.createdDate) }}
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n\r\n
\r\n","import { Component, Inject, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { AttachmentModalData, AttachmentModalEntityData } from '../attachment.modal.model';\r\nimport { CurrentEntity, CurrentEntityService } from 'src/app/Common/Entity/CurrentEntityService';\r\nimport { EntityTypeLevels } from 'src/app/constants.new';\r\nimport { RestrictData, RestrictService } from 'src/app/Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\nimport { AttachmentService } from '../attachment.service';\r\nimport { chain, cloneDeep, compact, filter, find, findIndex, head, includes, intersection, last, map, some } from 'lodash';\r\nimport { Attachment, AttachmentCategory } from '../attachment.model';\r\nimport { UtilitiesService } from 'src/app/UI-Lib/Utilities';\r\nimport * as moment from 'moment';\r\nimport { DocumentServiceUpgrade } from 'src/app/Documents/document.service.upgrade';\r\nimport { IPopUpRef, PopUpService } from 'src/app/Common/Popup/popup.service';\r\nimport { HelpService } from 'src/app/UI-Lib/Help-Tooltip';\r\nimport { ATTACHMENT_MODAL_HELP } from './attachmentModal.component.help';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\n\r\ninterface AttachmentListItem extends Attachment {\r\n lineOne: string;\r\n lineTwo: string;\r\n lineThree: string;\r\n active: boolean;\r\n}\r\n\r\ninterface PopupData {\r\n attachmentInfo: {\r\n attachmentID: string;\r\n fileName: string;\r\n fileExtension: string;\r\n }\r\n}\r\n\r\nexport interface AttachmentModalResult {\r\n count: number;\r\n hasImages: boolean;\r\n selectedAttachmentId?: System.Guid;\r\n selectedAttachmentFileName?: string;\r\n}\r\n\r\n@Component({\r\n selector: 'attachment-modal',\r\n templateUrl: 'attachmentModal.component.html',\r\n styleUrls: ['./attachmentModal.component.scss']\r\n})\r\nexport class AttachmentModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _currentEntityService: CurrentEntityService,\r\n private readonly _navService: UpgradeNavigationServiceHandler,\r\n private readonly _documentService: DocumentServiceUpgrade,\r\n private readonly _attachmentService: AttachmentService,\r\n private readonly _utilities: UtilitiesService,\r\n private readonly _popupService: PopUpService,\r\n private readonly _helpService: HelpService,\r\n @Inject('$rootScope') private _rootScope: any,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _messageBoxService: MessageBoxService\r\n ) {}\r\n params: AttachmentModalData;\r\n result: AttachmentModalResult;\r\n\r\n subHeaderLabel: string;\r\n childLabel: string;\r\n currentEntity: AttachmentModalEntityData | CurrentEntity;\r\n includeChildren: boolean = false;\r\n skipEntityService: boolean = false;\r\n allowEntityEdit: boolean = false;\r\n editMode: boolean = false;\r\n attachmentTypes: Core.AttachmentTypeModel[];\r\n categoryFilterId: number;\r\n yearFilter: number;\r\n selectedAttachment: AttachmentListItem;\r\n isBelowParcelLevel: boolean = false;\r\n viewFlags: {isListHidden: boolean; isViewerFullWidth: boolean } = {\r\n isListHidden: false,\r\n isViewerFullWidth: false\r\n };\r\n currentEntityForForm: AttachmentModalEntityData | CurrentEntity;\r\n file: File;\r\n hovered: boolean = false;\r\n loading: boolean = false;\r\n attachmentLoading: boolean = false;\r\n\r\n private readonly _CATEGORY_ID_ALL = -1;\r\n private readonly _CATEGORY_ID_PHOTOS = -2;\r\n private _attachments: AttachmentListItem[] = [];\r\n private _imageCategoryIds: number[]= [];\r\n private _cachedAttachments: AttachmentListItem[] = [];\r\n private _cachedParentAttachments: AttachmentListItem[] = [];\r\n private _numberOfDistinctEntities: number;\r\n private _attachmentCategories: AttachmentCategory[];\r\n private _years: Compliance.NameValuePair[] = [];\r\n\r\n async ngOnInit(): Promise {\r\n // entityData is not normally specified; I added it a while after the attachment modal code was written so I didn't\r\n // have to use currentEntityService for document processing. In a perfect world we'd refactor this and get rid of\r\n // currentEntityService entirely.\r\n // Also, an additional hack here is that later on, the entity service is used in the edit form; we need to know if we\r\n // used this.params.entityData or currentEntityService (see comments around the edit form function)\r\n if (this.params.belowParcelEntity) {\r\n this.currentEntity = this.params.belowParcelEntity;\r\n }\r\n else if (this.params.entityData) {\r\n this.currentEntity = this.params.entityData;\r\n this.skipEntityService = true;\r\n }\r\n else {\r\n this.currentEntity = this._currentEntityService.get();\r\n }\r\n\r\n this.isBelowParcelLevel = EntityTypeLevels[this.currentEntity?.typeId] < EntityTypeLevels[Core.EntityTypes.Parcel];\r\n this.includeChildren = this.params.entityType === 'Parcel';\r\n this._helpService.setContent(ATTACHMENT_MODAL_HELP);\r\n\r\n if (this.params.startOnPhotos) {\r\n this.viewFlags.isListHidden = true;\r\n this.viewFlags.isViewerFullWidth = true;\r\n }\r\n\r\n this.loading = true;\r\n try {\r\n await this._setPermissions();\r\n\r\n this.attachmentTypes = await this._attachmentService.getAttachmentTypes();\r\n this._imageCategoryIds = chain(this.attachmentTypes)\r\n .filter('isImage')\r\n .map('attachmentCategoryID')\r\n .uniq()\r\n .value();\r\n\r\n this._attachmentCategories = await this._attachmentService.getAttachmentCategories();\r\n this._attachmentCategories.unshift({\r\n attachmentCategoryID: this._CATEGORY_ID_ALL,\r\n category: 'Attachments',\r\n efAction: null\r\n }, {\r\n attachmentCategoryID: this._CATEGORY_ID_PHOTOS,\r\n category: 'Photos/Plats',\r\n efAction: null\r\n });\r\n\r\n this.categoryFilterId = this.params.startOnPhotos ? this._CATEGORY_ID_PHOTOS : (this.params.attachmentCategoryId || this._CATEGORY_ID_ALL);\r\n } finally {\r\n this.loading = false;\r\n }\r\n\r\n await this.getAllAttachments();\r\n }\r\n\r\n get headerLabel(): string {\r\n let headerLabel = `${this.params.parentType || this.params.entityType}`;\r\n headerLabel += this.params.entityName ? `: ${this.params.entityName}` : '';\r\n headerLabel += this.params.entityDescription ? `, ${this.params.entityDescription}` : '';\r\n\r\n return headerLabel;\r\n }\r\n\r\n get includeSubEntities(): boolean {\r\n return EntityTypeLevels[this.currentEntity?.typeId] > EntityTypeLevels[Core.EntityTypes.Parcel] && (this.includeChildren || this._numberOfDistinctEntities > 1);\r\n }\r\n\r\n get filteredYears(): Compliance.NameValuePair[] {\r\n if(this.params.singleYear) {\r\n return this._years;\r\n }\r\n\r\n const filteredAttachmentYears = chain(this._attachments)\r\n .filter(x => this._passesCategoryFilter(x))\r\n .map('year')\r\n .uniq()\r\n .value();\r\n\r\n return filter(this._years, year => {\r\n\t\t\treturn !year.value\r\n\t\t\t\t|| (year.value === -1 && filteredAttachmentYears.length !== compact(filteredAttachmentYears).length)\r\n\t\t\t\t|| includes(filteredAttachmentYears, year.value)\r\n\t\t\t\t|| this.isBelowParcelLevel;\r\n });\r\n }\r\n\r\n get filteredAttachments(): AttachmentListItem [] {\r\n return filter(this._attachments, attachment => {\r\n return attachment === undefined\r\n || (this._passesYearFilter(attachment) && this._passesCategoryFilter(attachment));\r\n });\r\n }\r\n\r\n get filteredCategories(): AttachmentCategory[] {\r\n const uniqueCategoryIds = chain(this._attachments)\r\n .filter(x => this._passesYearFilter(x))\r\n .map('attachmentCategoryID')\r\n .uniq()\r\n .value();\r\n\r\n const imageAttachmentExists = intersection(uniqueCategoryIds, this._imageCategoryIds).length > 0;\r\n\r\n return filter(this._attachmentCategories, category => {\r\n return includes(uniqueCategoryIds, category.attachmentCategoryID)\r\n || category.attachmentCategoryID === this._CATEGORY_ID_ALL\r\n || (category.attachmentCategoryID === this._CATEGORY_ID_PHOTOS && imageAttachmentExists);\r\n });\r\n }\r\n\r\n get isFirstAttachment() {\r\n return this.selectedAttachment?.attachmentID === head(this.filteredAttachments).attachmentID;\r\n }\r\n\r\n get isLastAttachment() {\r\n return this.selectedAttachment?.attachmentID === last(this.filteredAttachments).attachmentID;\r\n }\r\n\r\n async getAllAttachments() {\r\n this.loading = true;\r\n\r\n try {\r\n await this.selectAttachment(null);\r\n this._attachments = [];\r\n\r\n if(this.includeChildren && this._cachedParentAttachments.length) {\r\n this._attachments = this._cachedParentAttachments;\r\n } else if(!this.includeChildren && this._cachedAttachments.length) {\r\n this._attachments = this._cachedAttachments;\r\n } else {\r\n await this._getAttachmentsForCurrentEntity();\r\n\r\n if(this.includeChildren) {\r\n this._cachedParentAttachments = cloneDeep(this._attachments);\r\n } else {\r\n this._cachedAttachments = cloneDeep(this._attachments);\r\n }\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async selectAttachment(attachment: AttachmentListItem): Promise {\r\n this.file = undefined;\r\n this._attachments = map(this._attachments, a => {\r\n if (a !== null) {\r\n a.active = false;\r\n }\r\n return a;\r\n });\r\n\r\n this.selectedAttachment = attachment;\r\n\r\n if (this.selectedAttachment === null || this.attachmentLoading) {\r\n return;\r\n }\r\n\r\n this.attachmentLoading = true;\r\n this.selectedAttachment.active = true;\r\n this._utilities.focusOnElement('.active', 0);\r\n\r\n const { previewSupported, type } = this._attachmentService.getMimeTypeByFileExtension(this.selectedAttachment?.fileExtension);\r\n\r\n if (previewSupported) {\r\n try {\r\n const response = await this._documentService.getDocumentBody(this.selectedAttachment.attachmentID);\r\n const fileName = this._attachmentService.getFileNameFromHttpResponse(response, true);\r\n const fileNameType = fileName.split('.')[1].substring(0, 3);\r\n const blob = new Blob([response.data], { type: fileNameType });\r\n\r\n this.file = new File([blob], fileName, { type });\r\n } catch {\r\n // this.fileError = true;\r\n }\r\n }\r\n\r\n // notify pop-up window that that attachment changed\r\n if (this.selectedAttachment) {\r\n setTimeout(() => {\r\n const globalAttachmentsPopUpRef = this._popupService.getByAliasGroup(this._popupService.StaticAliases.Attachment)[0];\r\n globalAttachmentsPopUpRef && this._notifyChildWindow(globalAttachmentsPopUpRef, this._getPopUpData(this.selectedAttachment));\r\n });\r\n }\r\n\r\n this.attachmentLoading = false;\r\n }\r\n\r\n async selectFirstAttachment() {\r\n await new Promise(resolve => setTimeout(resolve, 500));\r\n const attachment = this.filteredAttachments.length ? this.filteredAttachments[0] : null;\r\n\r\n await this.selectAttachment(attachment);\r\n }\r\n\r\n async loadParentAttachments() {\r\n if (!this.isBelowParcelLevel) {\r\n return;\r\n }\r\n\r\n // TODO: include logic to show/hide _attachments based on level.\r\n const id = this.params.parentId || +this._navService.getQuerystringParam('parcelId');\r\n const parentType = this.params.parentTypeId || Core.EntityTypes.Parcel;\r\n\r\n this._attachments = [];\r\n this.params.entityDescription = '';\r\n this.isBelowParcelLevel = false;\r\n\r\n this.loading = true;\r\n try {\r\n const results = await this._attachmentService.getAll(parentType, id, true);\r\n this._buildAttachmentList(results);\r\n await this.selectFirstAttachment();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n addAttachment() {\r\n this.selectedAttachment = null;\r\n this.editAttachment();\r\n }\r\n\r\n editAttachment() {\r\n this.currentEntityForForm = (this.isBelowParcelLevel || this.skipEntityService)\r\n ? this.currentEntity\r\n : this._currentEntityService.get();\r\n\r\n this.editMode = true;\r\n }\r\n\r\n async downloadAttachment() {\r\n await this._attachmentService.downloadAttachmentFile(this.selectedAttachment);\r\n }\r\n\r\n async attachmentFormUpdated(savedAttachment: Attachment) {\r\n this.editMode = false;\r\n this.loading = true;\r\n\r\n try {\r\n await this._getAttachmentsForCurrentEntity();\r\n\r\n const idx = findIndex(this._attachments, {attachmentID: savedAttachment.attachmentID});\r\n this.selectAddedOrUpdatedAttachment(this._attachments[idx]);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async attachmentFormCreated(savedAttachment: Attachment) {\r\n this._cachedAttachments = [];\r\n this.attachmentFormUpdated(savedAttachment);\r\n }\r\n\r\n async attachmentFormDeleted() {\r\n this.editMode = false;\r\n this._cachedAttachments = [];\r\n\r\n this.loading = true;\r\n try {\r\n await this._getAttachmentsForCurrentEntity();\r\n await this.selectFirstAttachment();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async attachmentFormCancelled() {\r\n this.editMode = false;\r\n\r\n this.loading = true;\r\n try {\r\n if (this.selectedAttachment) {\r\n await this.selectAttachment(this.selectedAttachment);\r\n } else {\r\n await this.selectFirstAttachment();\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async selectAddedOrUpdatedAttachment(attachment: AttachmentListItem) {\r\n // if (!this.isBelowParcelLevel) {\r\n // Not sure why this clears out the yearFilter, but if the attachment modal\r\n // was opened for a specific year, we need to keep that around (see WK-3856)\r\n // This is a change; originally this was:\r\n // this.yearFilter = null;\r\n // const year = this._years.find(x => x.value === this.params.year);\r\n // this.yearFilter = year?.value || null;\r\n // }\r\n\r\n this.categoryFilterId = this.params.attachmentCategoryId || this._CATEGORY_ID_ALL;\r\n\r\n this.loading = true;\r\n\r\n try {\r\n await this.selectAttachment(attachment);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n displayDate(date: Date): string {\r\n return moment(date).fromNow();\r\n }\r\n\r\n toggleList() {\r\n const viewerWidthDelay = 200;\r\n\r\n if(this.viewFlags.isViewerFullWidth) {\r\n this.viewFlags.isListHidden = !this.viewFlags.isListHidden;\r\n\r\n setTimeout(() => {\r\n this.viewFlags.isViewerFullWidth = !this.viewFlags.isViewerFullWidth;\r\n }, 0);\r\n } else {\r\n this.viewFlags.isViewerFullWidth = !this.viewFlags.isViewerFullWidth;\r\n\r\n setTimeout(() => {\r\n this.viewFlags.isListHidden = !this.viewFlags.isListHidden;\r\n }, viewerWidthDelay);\r\n }\r\n\r\n }\r\n\r\n async popOutAttachment(isDynamic: boolean) {\r\n const popUpData = this._getPopUpData(this.selectedAttachment);\r\n\r\n if (!isDynamic) {\r\n const popUpRef = await this._popupService.openAttachmentPreview();\r\n this._notifyChildWindow(popUpRef, popUpData);\r\n return;\r\n }\r\n\r\n const globalAttachmentsPopUpRef = this._popupService.getByAliasGroup(this._popupService.StaticAliases.Attachment)[0];\r\n\r\n if (globalAttachmentsPopUpRef?.isOpen()) {\r\n this._notifyChildWindow(globalAttachmentsPopUpRef, popUpData);\r\n return;\r\n }\r\n\r\n const popUpRef = await this._popupService.openAttachmentPreview(this._popupService.StaticAliases.Attachment, globalAttachmentsPopUpRef);\r\n this._notifyChildWindow(popUpRef, popUpData);\r\n }\r\n\r\n async getNext() {\r\n const currentIndex = findIndex(this.filteredAttachments, this.selectedAttachment);\r\n const nextAttachment = this.filteredAttachments[currentIndex + 1];\r\n\r\n if (nextAttachment) {\r\n this.loading = true;\r\n\r\n try {\r\n await this.selectAttachment(nextAttachment);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n\r\n async getPrev() {\r\n const currentIndex = findIndex(this.filteredAttachments, this.selectedAttachment);\r\n const prevAttachment = this.filteredAttachments[currentIndex - 1];\r\n\r\n if (prevAttachment) {\r\n this.loading = true;\r\n\r\n try {\r\n await this.selectAttachment(prevAttachment);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n\r\n close() {\r\n this._composeDialogResult();\r\n this._rootScope.$emit('attachment.modal.closing');\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async emailAttachment(): Promise {\r\n this.result = {\r\n count: 1,\r\n hasImages: false,\r\n selectedAttachmentId: this.selectedAttachment.attachmentID,\r\n selectedAttachmentFileName: `${this.selectedAttachment.fileName}.${this.selectedAttachment.fileExtension}`\r\n };\r\n\r\n if (this.params.selectedAttachmentId && this.selectedAttachment.attachmentID !== this.params.selectedAttachmentId) {\r\n if ((await this._messageBoxService.open({\r\n message: 'An attachment for this site has already been included. Do you want to replace the existing attachment?',\r\n buttons: MessageBoxButtons.OKCancel\r\n })) !== MessageBoxResult.OK) {\r\n this.result.selectedAttachmentId = this.params.selectedAttachmentId;\r\n this.result.selectedAttachmentFileName = null;\r\n }\r\n }\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private async _setPermissions(): Promise {\r\n let isCompany = false;\r\n let entityId = Number(this.currentEntity.id);\r\n if (this.params.entityType === 'Company') {\r\n isCompany = true;\r\n this.childLabel = 'Sites';\r\n } else if (this.params.entityType === 'Site') {\r\n this.childLabel = 'Parcels';\r\n } else {\r\n entityId = +this._navService.getQuerystringParam('siteId') || undefined;\r\n }\r\n\r\n const restrictionData = {\r\n isCompany,\r\n entityId,\r\n roles: [],\r\n flag: Core.AccessRightsEnum.Write\r\n } as RestrictData;\r\n\r\n const hasPermission = await this._restrictService.hasPermission(restrictionData);\r\n this.allowEntityEdit = hasPermission\r\n && (this.params.readOnly === null\r\n || this.params.readOnly === undefined\r\n || !this.params.readOnly);\r\n }\r\n\r\n private async _getAttachmentsForCurrentEntity() {\r\n const results = await this._attachmentService.getAll(this.currentEntity.typeId, +this.currentEntity.id, this.includeChildren);\r\n this._buildAttachmentList(results);\r\n await this.selectFirstAttachment();\r\n }\r\n\r\n private _buildAttachmentList(attachments: Attachment[]): void {\r\n this._attachments = map(attachments, a => {\r\n let lineOne = this.currentEntity.typeId === a.entityTypeID ? this.currentEntity.name : a.entityName;\r\n let lineTwo = a.year?.toString() || '';\r\n const lineThree = a.description;\r\n\r\n const { attachmentTypeName } = find(this.attachmentTypes, { attachmentTypeID: a.attachmentTypeID });\r\n lineTwo += ` ${attachmentTypeName || ''}`;\r\n\r\n if (EntityTypeLevels[a.entityTypeID] < EntityTypeLevels[Core.EntityTypes.Parcel]) {\r\n if (a.entityName !== null) {\r\n lineTwo += ` ${ a.entityName.replace(a.year?.toString(), '')}`;\r\n }\r\n if (this.includeChildren) { // include parcel account number when user clicks 'Include Parcel'\r\n lineOne = a.parentEntityName;\r\n }\r\n }\r\n\r\n return {\r\n ...a,\r\n lineOne, lineTwo, lineThree,\r\n active: false\r\n };\r\n });\r\n\r\n this._numberOfDistinctEntities = chain(this._attachments)\r\n .countBy('entityTypeID')\r\n .toArray()\r\n .value()\r\n .length;\r\n\r\n if(this.isBelowParcelLevel || (this.params.disableYears && this.params.year)) {\r\n this._years = [{\r\n name: this.params.year?.toString(),\r\n value: this.params.year\r\n }];\r\n\r\n this.yearFilter = this.params.year;\r\n } else {\r\n this._years = chain(this._attachments)\r\n .filter('year')\r\n .uniqBy('year')\r\n .map(a => {\r\n return {\r\n name: a.year?.toString(),\r\n value: a.year\r\n };\r\n })\r\n .orderBy(['value'], ['desc'])\r\n .unshift({\r\n name: 'No Year',\r\n value: -1\r\n })\r\n .unshift({\r\n name: 'All',\r\n value: null\r\n })\r\n .value();\r\n this.yearFilter = this._years[0].value;\r\n }\r\n\r\n this._attachments.sort((a, b) => this._sortAttachments(a, b));\r\n }\r\n\r\n private _sortAttachments(item1: AttachmentListItem, item2: AttachmentListItem) {\r\n /*\r\n List items should be sorted by:\r\n Entity Name (Line 1) value (if present),\r\n Tax Year DESC with blanks last,\r\n Attachment Category ASC,\r\n extra information for entity lower than a parcel ASC,\r\n Attachment Description ASC\r\n */\r\n\r\n /*\r\n\r\n First Line: Entity Name value to which the attachment is related (show just parcel for levels below parcel).\r\n Line suppressed unless showing mixed entities in attachment list.\r\n\r\n If the attachment is attached deeper than the parcel level (assessment, tax bill, etc.), the first line continues with a\r\n space + hyphen + space then, if an assessment, the revision description or, if a tax bill, the additional information shown in the tab header of the tax bill itself + the bill name.\r\n\r\n Second Line: Year (if available) + space (if there was a year) + Attachment Type.\r\n\r\n Third Line: Attachment Description. Line suppressed if there is no attachment description for the attachment.\r\n */\r\n\r\n let returnVal = 0;\r\n\r\n if (this.includeChildren) {\r\n // sort by entity name - we always have it if we include children\r\n if (\r\n // EntityTypeLevels[item1.enityTypeID] <= EntityTypeLevels[EntityTypeIDs.PARCEL]\r\n //&& EntityTypeLevels[item2.enityTypeID] <= EntityTypeLevels[EntityTypeIDs.PARCEL]\r\n //&&\r\n item1.lineOne < item2.lineOne) {\r\n returnVal = -1;\r\n }\r\n if (\r\n // EntityTypeLevels[item1.enityTypeID] <= EntityTypeLevels[EntityTypeIDs.PARCEL]\r\n //&& EntityTypeLevels[item2.enityTypeID] <= EntityTypeLevels[EntityTypeIDs.PARCEL]\r\n //&&\r\n item1.lineOne > item2.lineOne) {\r\n returnVal = 1;\r\n }\r\n\r\n if (returnVal !== 0) {\r\n return returnVal;\r\n }\r\n }\r\n\r\n // next by year DESC. force null years to the bottom\r\n const year1 = item1.year;\r\n const year2 = item2.year;\r\n\r\n item1.year = year1 || 0;\r\n item2.year = year2 || 0;\r\n\r\n if (item2.year < item1.year) {\r\n returnVal = -1;\r\n }\r\n if (item2.year > item1.year) {\r\n returnVal = 1;\r\n }\r\n item1.year = year1; // put back the original value\r\n item2.year = year2; // put back the original value\r\n\r\n if (returnVal !== 0) {\r\n return returnVal;\r\n }\r\n\r\n // next by category\r\n const name1 = this._getAttachmentTypeName(item1.attachmentTypeID);\r\n const name2 = this._getAttachmentTypeName(item2.attachmentTypeID);\r\n\r\n if (name1 < name2) {\r\n returnVal = -1;\r\n }\r\n if (name1 > name2) {\r\n returnVal = 1;\r\n }\r\n if (returnVal !== 0) {\r\n return returnVal;\r\n }\r\n\r\n // next by description\r\n if (item1.description < item2.description) {\r\n returnVal = -1;\r\n }\r\n if (item1.description > item2.description) {\r\n returnVal = 1;\r\n }\r\n\r\n return returnVal;\r\n }\r\n\r\n private _getAttachmentTypeName(attachmentTypeID: number): string {\r\n const { attachmentTypeName } = find(this.attachmentTypes, { attachmentTypeID });\r\n return attachmentTypeName || '';\r\n }\r\n\r\n private _passesCategoryFilter(item: AttachmentListItem): boolean {\r\n const isImage = includes(this._imageCategoryIds, item.attachmentCategoryID);\r\n\r\n return this.categoryFilterId === null\r\n || item.attachmentCategoryID === this.categoryFilterId\r\n || this.categoryFilterId === this._CATEGORY_ID_ALL\r\n || (this.categoryFilterId === this._CATEGORY_ID_PHOTOS && isImage);\r\n }\r\n\r\n private _passesYearFilter(item: AttachmentListItem) {\r\n // item.year could be int, this.yearFilter is string\r\n return item.year == this.yearFilter\r\n || this.yearFilter === null\r\n || (this.yearFilter === -1 && !item.year);\r\n\r\n }\r\n\r\n private _getPopUpData(attachment: Attachment): PopupData {\r\n return {\r\n attachmentInfo: {\r\n attachmentID: attachment.attachmentID,\r\n fileName: attachment.fileName,\r\n fileExtension: attachment.fileExtension\r\n }\r\n };\r\n }\r\n\r\n private _notifyChildWindow(popUpRef: IPopUpRef, popUpData: PopupData) {\r\n popUpRef.isOpen() && popUpRef.publish(this._popupService.Topics.Attachment.AttachmentChanged, popUpData);\r\n }\r\n\r\n private _composeDialogResult() {\r\n if (this.loading) {\r\n // we are closing while dialog is still loading data; we don't want to update calling icon etc\r\n return null;\r\n }\r\n\r\n let entityAttachments = this._attachments;\r\n if(this.currentEntity.typeId !== Core.EntityTypes.Parcel) {\r\n entityAttachments = filter(this._attachments, {\r\n entityTypeID: this.currentEntity.typeId\r\n });\r\n }\r\n\r\n if (this.params.disableYears && this.params.year) {\r\n entityAttachments = filter(entityAttachments, {\r\n year: this.params.year\r\n });\r\n }\r\n\r\n const hasImages = some(entityAttachments, attachment => includes(this._imageCategoryIds, attachment.attachmentCategoryID));\r\n\r\n this.result = {\r\n count: entityAttachments.length,\r\n hasImages\r\n };\r\n }\r\n}\r\n","import { Component, Input, Output, EventEmitter } from '@angular/core';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { AttachmentModalData } from '../attachment.modal.model';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { AttachmentModalComponent } from '../Modal/attachmentModal.component';\r\n\r\n@Component({\r\n selector: 'entity-attachments',\r\n templateUrl: './entity-attachments.component.html'\r\n})\r\nexport class EntityAttachmentsComponent {\r\n constructor(private readonly _modalService: WeissmanModalService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) { }\r\n\r\n @Input() hasAttachments: boolean;\r\n @Input() buttonClass: string;\r\n @Input() modalData: AttachmentModalData;\r\n @Input() disabled: boolean;\r\n @Input() isNestedModal: boolean;\r\n @Input() forImages: boolean;\r\n @Input() analyticsCategory: string;\r\n\r\n @Output() hasAttachmentsChange: EventEmitter = new EventEmitter();\r\n @Output() hasImagesChange: EventEmitter = new EventEmitter();\r\n\r\n get icon(): string {\r\n if (this.forImages) {\r\n return 'fa-file-image-o';\r\n } else {\r\n return this.hasAttachments ? 'fa-files-o' : 'fa-paperclip';\r\n }\r\n }\r\n\r\n async showAttachmentsDialog(): Promise {\r\n if (this.analyticsCategory) {\r\n this._productAnalyticsService.logEvent(`click-${this.analyticsCategory}-attachment`);\r\n }\r\n\r\n const result = await this._modalService.showAsync(AttachmentModalComponent, this.modalData, 'modal-xl modal-no-max-width');\r\n\r\n if(result?.count >= 0) {\r\n this.hasAttachments = result.count > 0;\r\n this.hasAttachmentsChange.emit(this.hasAttachments);\r\n if (this.hasImagesChange) {\r\n this.hasImagesChange.emit(result.hasImages);\r\n }\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { GridSource } from '../tax.rate.grid.component';\r\nimport { TaxAuthority, TaxRateArea } from '../../Assessor-Collector/Tax-Rates/tax.rates.panel.model';\r\nimport { AttachmentModalData } from '../../Attachment/attachment.modal.model';\r\n\r\nexport interface ICellRendererParamsForTaxRateCommandCenterAttachments extends ICellRendererParams {\r\n canEdit: boolean;\r\n gridSofurce: GridSource;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-attachments-cell',\r\n template:\r\n `\r\n
\r\n \r\n \r\n
\r\n `\r\n})\r\nexport class TaxRateCommandCenterAttachmentsCellRendererComponent implements ICellRendererAngularComp {\r\n entity: TaxAuthority | TaxRateArea;\r\n attachmentModalData: AttachmentModalData;\r\n canEdit: boolean = false;\r\n\r\n agInit(params: ICellRendererParamsForTaxRateCommandCenterAttachments): void {\r\n this.canEdit = params.canEdit;\r\n\r\n if (!params.data) {\r\n return;\r\n }\r\n\r\n if(params.gridSofurce == 'authorities') {\r\n this.entity = params.data as TaxAuthority;\r\n this.attachmentModalData = {\r\n entityType: 'TaxAuthority',\r\n entityName: this.entity.name,\r\n entityData: {\r\n typeId: Core.EntityTypes.TaxAuthority,\r\n id: this.entity.taxAuthorityId,\r\n name: this.entity.name\r\n },\r\n readOnly: !this.canEdit\r\n } as AttachmentModalData;\r\n } else {\r\n this.entity = params.data as TaxRateArea;\r\n this.attachmentModalData = {\r\n entityType: 'TaxRateAuthority',\r\n entityName: this.entity.name,\r\n entityData: {\r\n typeId: Core.EntityTypes.TaxRateArea,\r\n id: this.entity.taxRateAreaId,\r\n name: this.entity.name\r\n },\r\n readOnly: !this.canEdit\r\n } as AttachmentModalData;\r\n }\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","\r\n\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment-timezone';\r\nimport { TaxAuthorityStatuses } from '../constants.new';\r\nimport { TaxAuthority, TaxAuthorityDetail } from '../Assessor-Collector/Tax-Rates/tax.rates.panel.model';\r\n\r\nexport interface ICellRendererParamsForTaxRateQcBy extends ICellRendererParams {\r\n rate: (params, year: number) => string;\r\n year: number;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-qc-by-cell',\r\n template:\r\n ' {{rate}} '\r\n})\r\nexport class TaxRateQcByCellRendererComponent implements ICellRendererAngularComp {\r\n rate: string;\r\n qcBy: string = '';\r\n\r\n agInit(params: ICellRendererParamsForTaxRateQcBy): void {\r\n this.rate = params.rate(params, params.year);\r\n\r\n if(!params.data) {\r\n return;\r\n }\r\n\r\n const taxAuthority: TaxAuthority = params.data;\r\n const yearObj: TaxAuthorityDetail = _.find(taxAuthority.details as TaxAuthorityDetail[], {taxYear: params.year});\r\n\r\n\r\n if (yearObj && yearObj.taxAuthorityStatusId === TaxAuthorityStatuses.Pending) {\r\n if (yearObj.qcRequestTimeUtc) {\r\n this.qcBy = `QC requested at ${ moment(yearObj.qcRequestTimeUtc).utc().format('M/D/Y')}`;\r\n if (yearObj.qcRequestUserFullName) {\r\n this.qcBy += ` by ${ yearObj.qcRequestUserFullName}`;\r\n }\r\n }\r\n }\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}","import { Component, forwardRef, Input, ViewChild, ElementRef, Output, EventEmitter, DoCheck } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\n\r\n/**\r\n * Switch\r\n *\r\n * Allows the user to toggle a boolean value\r\n *\r\n * Tied into ControlValueAccessor for integration with native Angular FormControls and ngModel\r\n *\r\n * Example usage:\r\n * \r\n * \r\n *\r\n */\r\n@Component({\r\n selector: 'ws-switch',\r\n templateUrl: './switch.component.html',\r\n styleUrls: ['./switch.component.scss'],\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => SwitchComponent),\r\n multi: true\r\n }\r\n ]\r\n})\r\nexport class SwitchComponent implements DoCheck, ControlValueAccessor {\r\n\r\n @Input() onLabel: string = '';\r\n @Input() offLabel: string = '';\r\n @Input() onTextColor: string = '#fff';\r\n @Input() offTextColor: string = '#555';\r\n // @Input() onColor: string = '#0E247E';\r\n @Input() onColor: string = '#5373b4';\r\n @Input() offColor: string = '#eeeeee';\r\n @Input() size: string;\r\n @Input() title: string;\r\n\r\n // for angularjs downgrade\r\n @Input() active: boolean = true;\r\n\r\n @Output() selectedOptionChanged: EventEmitter = new EventEmitter();\r\n\r\n @ViewChild('optionOne', { static: true }) optionOne: ElementRef;\r\n @ViewChild('optionTwo', { static: true }) optionTwo: ElementRef;\r\n\r\n toggleWidth: number = 0;\r\n switchWrapper: string = '0px';\r\n switchContainer: string = '0px';\r\n\r\n // Angular control value accessor methods\r\n value: boolean = false;\r\n\r\n disabled: boolean;\r\n\r\n ngDoCheck(): void {\r\n const opt1 = this.optionOne.nativeElement.offsetWidth;\r\n const opt2 = this.optionTwo.nativeElement.offsetWidth;\r\n this.toggleWidth = Math.ceil((this.onLabel.length > this.offLabel.length) ? opt1 : opt2);\r\n\r\n this.switchWrapper = `${(this.toggleWidth + 25)}px`;\r\n this.switchContainer = `${((this.toggleWidth * 2) + 27)}px`;\r\n }\r\n\r\n writeValue(value: boolean): void {\r\n this.value = value;\r\n }\r\n\r\n setDisabledState(disabled: boolean): void {\r\n this.disabled = disabled;\r\n }\r\n\r\n next(): void {\r\n this.value = !this.value;\r\n this.onChange(this.value);\r\n this.selectedOptionChanged.emit(this.value);\r\n this.onTouched();\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouched = fn;\r\n }\r\n\r\n // Switch methods\r\n\r\n toggleSwitch(): boolean {\r\n if (this.disabled || !this.active) {\r\n return;\r\n }\r\n this.next();\r\n return false; // prevent propagation\r\n }\r\n\r\n private onChange: (val: boolean) => void = (val) => { return null; };\r\n private onTouched: () => void = () => { return null; };\r\n\r\n}\r\n","
\r\n
\r\n
\r\n\r\n {{onLabel}}\r\n\r\n  \r\n\r\n {{offLabel}}\r\n\r\n \r\n
\r\n
\r\n  \r\n
\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForAgGridSwitch extends ICellRendererParams {\r\n isVisible: (params: ICellRendererParamsForAgGridSwitch) => boolean;\r\n canEdit: (params: ICellRendererParamsForAgGridSwitch) => boolean;\r\n canEnterEditMode: () => boolean;\r\n onValueChanged: (params: ICellRendererParamsForAgGridSwitch, newValue: boolean) => Promise;\r\n}\r\n\r\n@Component({\r\n selector: 'ag-grid-grid-switch',\r\n template: `\r\n
\r\n \r\n
\r\n `\r\n})\r\nexport class AgGridSwitchCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForAgGridSwitch;\r\n\r\n agInit(params: ICellRendererParamsForAgGridSwitch): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onModelChanged(value: boolean): void {\r\n this.params.value = value;\r\n this.params.data[this.params.colDef.field] = value;\r\n this.params.onValueChanged(this.params, value);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface TaxingDistrictListGridActionCellRendererParams extends ICellRendererParams {\r\n canDelete: (params: TaxingDistrictListGridActionCellRendererParams) => boolean;\r\n delete: (params: TaxingDistrictListGridActionCellRendererParams) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n \r\n `\r\n})\r\nexport class TaxingDistrictListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: TaxingDistrictListGridActionCellRendererParams;\r\n\r\n agInit(params: TaxingDistrictListGridActionCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForUserGroupsGridAction extends ICellRendererParams {\r\n hasEditPermission: () => boolean;\r\n viewDetails: (params: ICellRendererParamsForUserGroupsGridAction) => void;\r\n delete: (params: ICellRendererParamsForUserGroupsGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n `\r\n})\r\nexport class UserGroupsGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n userGroupGridItem: Core.GroupModel;\r\n hasEditPermission: boolean;\r\n private _params: ICellRendererParamsForUserGroupsGridAction;\r\n\r\n agInit(params: ICellRendererParamsForUserGroupsGridAction): void {\r\n this._params = params;\r\n this.hasEditPermission = params.hasEditPermission();\r\n this.userGroupGridItem = params.data as Core.GroupModel;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this._params.viewDetails(this._params);\r\n }\r\n\r\n onDeleteClicked(): void {\r\n this._params.delete(this._params);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForCompanyPermissionsGridAction extends ICellRendererParams {\r\n launchSitesModal: (params: ICellRendererParamsForCompanyPermissionsGridAction) => Promise;\r\n canLaunchSitesModal: (params: ICellRendererParamsForCompanyPermissionsGridAction) => boolean;\r\n editMode: (params: ICellRendererParamsForCompanyPermissionsGridAction) => boolean;\r\n canRemove: (params: ICellRendererParamsForCompanyPermissionsGridAction) => boolean;\r\n remove: (params: ICellRendererParamsForCompanyPermissionsGridAction) => void;\r\n canUndoRemove: (params: ICellRendererParamsForCompanyPermissionsGridAction) => boolean;\r\n undoRemove: (params: ICellRendererParamsForCompanyPermissionsGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n \r\n \r\n \r\n `\r\n})\r\nexport class CompanyPermissionsGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForCompanyPermissionsGridAction;\r\n helpContentId: string;\r\n\r\n agInit(params: ICellRendererParamsForCompanyPermissionsGridAction): void {\r\n this.params = params;\r\n this.helpContentId = this.params.editMode(this.params) ? 'user-group-detail.edit-site-permissions' : 'user-group-detail.view-site-permissions';\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForActionViewOutputDefaultsGridAction extends ICellRendererParams {\r\n hasEditPermission: () => boolean;\r\n viewDetails: (params: ICellRendererParamsForActionViewOutputDefaultsGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n ``\r\n})\r\nexport class ActionViewOutputDefaultsGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n userGroupGridItem: Core.GroupModel;\r\n hasEditPermission: boolean;\r\n private _params: ICellRendererParamsForActionViewOutputDefaultsGridAction;\r\n\r\n agInit(params: ICellRendererParamsForActionViewOutputDefaultsGridAction): void {\r\n this._params = params;\r\n this.hasEditPermission = params.hasEditPermission();\r\n this.userGroupGridItem = params.data as Core.GroupModel;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this._params.viewDetails(this._params);\r\n }\r\n}\r\n","import { BehaviorSubject, Observable, Subject } from 'rxjs';\r\nimport { RowNode, GridOptions } from 'ag-grid-community';\r\nimport { IHeaderParams, ICellRendererParams } from 'ag-grid-community';\r\nimport * as _ from 'lodash';\r\n\r\n// there is a problem with how Json.NET is deserializing this integer value and for some reason cannot use the largest signed int value\r\nconst MAX_INT: number = 2000000000;\r\n\r\n/**\r\n * An object used to keep track of a range selection. The ID could be the index of a row in the grid or the actual row ID if the Grid is pre-sorted.\r\n * As far as this construct goes, it assumes you're always dealing with numbers and it only tracks a from/to value.\r\n */\r\ninterface RangeSelection {\r\n from: number;\r\n to: number;\r\n}\r\n\r\n/**\r\n * Parameters for the AgGrid multi-select Header and Cell (renderer) components.\r\n */\r\nexport interface AgGridMultiSelectRendererParams extends IHeaderParams, ICellRendererParams {\r\n tracker: AgGridMultiSelectTracker,\r\n}\r\n\r\n/**\r\n * Parameters for the AgGrid multi-select Header renderer component.\r\n */\r\nexport interface AgGridMultiSelectHeaderRendererParams extends AgGridMultiSelectRendererParams {\r\n isCellRendererDisabledFn?: (value: number, data: any) => boolean;\r\n updateAllRowValues?: (params: AgGridMultiSelectHeaderRendererParams, checked: boolean) => void;\r\n}\r\n\r\n/**\r\n * Parameters for the AgGrid multi-select Cell renderer component.\r\n */\r\nexport interface AgGridMultiSelectCellRendererParams extends AgGridMultiSelectRendererParams {\r\n isCellRendererHiddenFn?: (value: number, data: any) => boolean;\r\n isCellRendererDisabledFn?: (value: number, data: any) => boolean;\r\n updateRowValue?: (params: AgGridMultiSelectCellRendererParams, checked: boolean) => void;\r\n tooltipText?: (params: AgGridMultiSelectCellRendererParams) => string;\r\n}\r\n\r\nexport class AgGridMultiSelectTracker {\r\n constructor(\r\n private _gridOptions: GridOptions,\r\n private _getRowIdsFn: (startId: number, endId: number) => Promise>) {\r\n }\r\n\r\n private _selectedRowsModel: Compliance.SelectedRowsModel = {\r\n selectAllRows: false,\r\n selectedRows: []\r\n };\r\n\r\n private _selectedRowsSubject = new Subject();\r\n\r\n // the id of the node in the grid where the click event is originating from\r\n private _clickedNodeId: number = null;\r\n\r\n // when a range selection API is fired then that information is stored in this array\r\n // the array is cleared after the API call has completed\r\n // used to ensure that rows that have a pending range selection cannot be interacted with while that selection is still pending\r\n private _pendingRangeSelections: RangeSelection[] = [];\r\n\r\n // keeps track of what was the action performed on the node. this is used when selecting a range:\r\n // option 1: you \"check\" the node, it will check everything in the range\r\n // option 2: you \"uncheck\" the node, it will uncheck everything in the range.\r\n // note:\r\n // for a range, the node that will be checked will be the first node defining the range\r\n // after the action (selection or deselection) is completed, the node you clicked on - the last in the range - will be stored here\r\n // therefore becoming the first in the definition of a new range (if the user were to follow that with another shift-click)\r\n private _clickedNodeChecked: boolean = false;\r\n\r\n // keep track if the results in the grid are being filtered\r\n private _gridHasFilters: boolean = this._isGridFiltered();\r\n\r\n // Some grids have filters not associated with the grid itself that need to be accounted for when selecting all rows\r\n private _isExternalFilterApplied: boolean = false;\r\n\r\n // (when the results in the grid are being filtered) keep track of the header checkbox (select all)\r\n private _gridHasFiltersAndSelectAllChecked: boolean = false;\r\n\r\n // Flags when the range is being selected so the UI can be notified when it is finished\r\n private _isSelectingRange: BehaviorSubject = new BehaviorSubject(false);\r\n private _isSelectingRange$: Observable = this._isSelectingRange.asObservable();\r\n\r\n /**\r\n * An Observable that notifies when the selected rows changes.\r\n */\r\n get selectedRows$(): Observable {\r\n return this._selectedRowsSubject.asObservable();\r\n }\r\n\r\n get isSelectingRange$(): Observable {\r\n return this._isSelectingRange$;\r\n }\r\n\r\n /**\r\n * Retrieves the model that is tracking selected rows. The model tracks if rows are selected as a group or individually.\r\n * If all rows are selected then the individual tracking operates in exclusion mode (all selected but exclude these individual rows).\r\n * If all rows are not selected then the individual tracking operates in inclusion mode (not all selected but include these individual rows).\r\n */\r\n getSelectedRowsModel(): Compliance.SelectedRowsModel {\r\n return Object.assign({}, this._selectedRowsModel);\r\n }\r\n\r\n /**\r\n * Retrieves the row IDs for the selected rows model.\r\n */\r\n async getSelectedRowIds(): Promise {\r\n // option 1: you're in exclude mode, everything has been selected except for the individual rows being tracked\r\n // option 2: you're in include mode, all individual tracked rows are the selected ones\r\n if (this._selectedRowsModel.selectAllRows) {\r\n // get all rows in this case and exclude the individual selected rows to get the IDs\r\n const rowIdsResponse = await this._getRowIdsFn(0, MAX_INT);\r\n const selectedRowIds = rowIdsResponse.data.filter(x => !this._selectedRowsModel.selectedRows.includes(x));\r\n return selectedRowIds;\r\n } else {\r\n // return the selected rows\r\n return this._selectedRowsModel.selectedRows;\r\n }\r\n }\r\n\r\n /**\r\n * Sets the row model that the tracker is using for the grid that it is associated with.\r\n * @param model The new row model.\r\n */\r\n setSelectedRowsModel(model: Compliance.SelectedRowsModel) {\r\n this._selectedRowsModel = Object.assign({}, model);\r\n\r\n // refresh filters now that we have a new model, can't call onGridFilterChanged because it will clear the new model\r\n this._clickedNodeId = null;\r\n this._gridHasFilters = this._isGridFiltered();\r\n this._gridHasFiltersAndSelectAllChecked = this._gridHasFilters && this._selectedRowsModel.selectAllRows && this._selectedRowsModel.selectedRows.length === 0;\r\n }\r\n\r\n /**\r\n * Checks to see if the grid is displaying any rows as a result of an applied filter.\r\n */\r\n hasFilteredRows(): boolean {\r\n return this._gridHasFilters;\r\n }\r\n\r\n /**\r\n * Checks to see if the grid has selected all rows that are being displayed as a result of an applied filter.\r\n */\r\n hasSelectedAllFilteredRows(): boolean {\r\n return this._gridHasFilters && this._gridHasFiltersAndSelectAllChecked;\r\n }\r\n\r\n /**\r\n * Checks to see if the grid has selected all rows, with our without filter.\r\n */\r\n isSelectAllChecked(): boolean {\r\n return this._selectedRowsModel.selectAllRows || (this._gridHasFilters && this._gridHasFiltersAndSelectAllChecked);\r\n }\r\n\r\n /**\r\n * Are all the rows disabled\r\n */\r\n isAllRowsDisabled(): boolean {\r\n let allRowsCount: number;\r\n if (this._gridOptions.rowModelType === 'infinite') {\r\n allRowsCount = this._gridOptions.api.isMaxRowFound() ? this._gridOptions.api.getInfiniteRowCount() : 0;\r\n } else {\r\n allRowsCount = this._gridOptions.api.getDisplayedRowCount();\r\n }\r\n\r\n // If the grid is infinite scroll we can't determine if all rows are disabled\r\n if (allRowsCount > this._gridOptions.paginationPageSize) {\r\n return false;\r\n } else if (allRowsCount === 0) {\r\n return true;\r\n }\r\n\r\n // If the grid doesn't have an assigned disable function, all rows will always be enabled\r\n const columnDef = this._gridOptions.columnApi.getColumn('grid-column-multiselect').getColDef();\r\n if (!columnDef.cellRendererParams.isCellRendererDisabledFn) {\r\n return false;\r\n }\r\n\r\n let disabled = true;\r\n this._gridOptions.api.forEachNode((node: RowNode) => {\r\n if (disabled && node.data) {\r\n disabled = columnDef.cellRendererParams.isCellRendererDisabledFn(node.data.id, node.data);\r\n }\r\n });\r\n\r\n return disabled;\r\n }\r\n\r\n /**\r\n * Checks to see if the tracker has any rows that are selected.\r\n */\r\n hasSelectedRows(): boolean {\r\n // option 1: all rows are selected so it has selected rows\r\n // option 2: not all rows are selected but there are individually selected rows so it has selected rows\r\n return !!(this._selectedRowsModel.selectAllRows || (!this._selectedRowsModel.selectAllRows && this._selectedRowsModel.selectedRows.length));\r\n }\r\n\r\n /**\r\n * It retrieves the count of selected rows in the grid.\r\n */\r\n getSelectedRowsCount(): number {\r\n // if everything is selected then we're keeping track of the deselected rows in the selectedRows collection\r\n // option 1: everything is selected and nothing is deselected so \"count = total - length\" and length is zero\r\n // option 2: everything is selected and some rows are deselected so \"count = total - length\" and length is greater than zero\r\n if (this._selectedRowsModel.selectAllRows) {\r\n return this.getTotalRowsCount() - this._selectedRowsModel.selectedRows.length;\r\n }\r\n return this._selectedRowsModel.selectedRows.length;\r\n }\r\n\r\n /**\r\n * It retrieves the count of all rows in the grid.\r\n */\r\n getTotalRowsCount(): number {\r\n if (this._gridOptions.rowModelType === 'virtual') {\r\n return this._gridOptions.api.isMaxRowFound() ? this._gridOptions.api.getInfiniteRowCount() : 0;\r\n } else {\r\n return this._gridOptions.api.getDisplayedRowCount();\r\n }\r\n }\r\n\r\n hasAnythingSelected(): boolean {\r\n if (this.getSelectedRowsModel().selectAllRows) {\r\n return (this._selectedRowsModel.selectedRows.length < this.getTotalRowsCount());\r\n } else {\r\n return (this.getSelectedRowsCount() > 0);\r\n }\r\n }\r\n\r\n /**\r\n * Checks if the specified row is selected.\r\n * @param rowId The unique row identifier.\r\n */\r\n isRowSelected(rowId: any): boolean {\r\n // a row is selected if:\r\n // option 1: everything is selected and this row is not excluded\r\n // option 2: not everything is selected and this row is included\r\n const isSelected = _.some(this._selectedRowsModel.selectedRows, x => x === rowId);\r\n return (this._selectedRowsModel.selectAllRows && !isSelected) || (!this._selectedRowsModel.selectAllRows && isSelected);\r\n }\r\n\r\n /**\r\n * Checks to see if the specified row is part of a range selection that has an API call which has not completed yet.\r\n * @param rowId The unique row identifier.\r\n */\r\n isRowPendingRangeSelection(rowId: number, rowNode: RowNode): boolean {\r\n const nodeId = this._getRowNodeId(rowId, rowNode);\r\n const rangeSelectionIndex = this._pendingRangeSelections.findIndex(x => x.from <= nodeId && x.to >= nodeId);\r\n return rangeSelectionIndex !== -1;\r\n }\r\n\r\n /**\r\n * Checks to see if any rows in the grid are pending a range selection.\r\n */\r\n isGridPendingRangeSelection(): boolean {\r\n return this._pendingRangeSelections.length > 0;\r\n }\r\n\r\n /**\r\n * Sets the external filter flag to indicate that an external filter is applied to the grid.\r\n */\r\n setExternalFilterApplied(isExternalFilterApplied: boolean): void {\r\n this._isExternalFilterApplied = isExternalFilterApplied;\r\n this._gridHasFilters = this._isGridFiltered();\r\n }\r\n\r\n /**\r\n * Notifies that the grid filters have changed. Every time filters change, the tracker resets the \"all checked\" status and the node index it's tracking for Shift clicks.\r\n */\r\n onGridFilterChanged(clearFilters: boolean = true): void {\r\n // when grid filter is changed, clear selections so there aren't rows selected which aren't visible with the current filter\r\n if (clearFilters) {\r\n this.clear();\r\n }\r\n\r\n this._clickedNodeId = null;\r\n this._gridHasFilters = this._isGridFiltered();\r\n this._gridHasFiltersAndSelectAllChecked = this._gridHasFilters && this._selectedRowsModel.selectAllRows && this._selectedRowsModel.selectedRows.length === 0;\r\n }\r\n\r\n /**\r\n * Notifies that the grid sort order has changed. Every time sort changes the tracker resets the node index it's tracking for Shift clicks.\r\n */\r\n onGridSortChanged(): void {\r\n this._clickedNodeId = null;\r\n }\r\n\r\n /**\r\n * Toggles the selection of a row.\r\n * If the user is holding the Shift key during this toggle, all result between the current row and previously clicked row will be toggled.\r\n * @param rowId The unique row identifier.\r\n * @param rowNode The grid node for that row.\r\n * @param shiftClicked A value indicating if the Shift key is clicked during this toggle event.\r\n */\r\n async toggleRowChecked(rowId: number, rowNode: RowNode, shiftClicked: boolean): Promise {\r\n // using an index of NULL as the initial value, if they shift click the first node in the grid, ignore it and treat it as a click\r\n if (shiftClicked && this._clickedNodeId !== null) {\r\n const lastClickedNodeId = this._clickedNodeId;\r\n const currentClickedNodeId = this._getRowNodeId(rowId, rowNode);\r\n // follow the action they took on the clicked node; if they checked it, check the entire range, otherwise uncheck the range\r\n await this._selectRange(currentClickedNodeId, lastClickedNodeId, this._clickedNodeChecked);\r\n this._selectedRowsSubject.next(this._selectedRowsModel);\r\n this._gridOptions.api.redrawRows();\r\n } else {\r\n // look for the row in the include/exclude list and add/remove to the list\r\n // option 1: the row is not there, add it to the list (checked)\r\n // option 2: the row is there, remove it from the list (uncheck)\r\n const index = this._selectedRowsModel.selectedRows.indexOf(rowId);\r\n if (index === -1) {\r\n this._selectedRowsModel.selectedRows.push(rowId);\r\n } else {\r\n this._selectedRowsModel.selectedRows.splice(index, 1);\r\n }\r\n this._selectedRowsSubject.next(this._selectedRowsModel);\r\n this._gridOptions.api.redrawRows({ rowNodes: [rowNode] });\r\n }\r\n\r\n // record the index and the action (checked/unchecked) of where the click happened. the node was \"checked\" if:\r\n // option 1: is included in the list of individual rows and not all rows are selected\r\n // option 2: is not included in the list of individual rows and all rows are selected\r\n this._clickedNodeId = this._getRowNodeId(rowId, rowNode);\r\n this._clickedNodeChecked = (this._selectedRowsModel.selectedRows.indexOf(rowId) !== -1 && !this._selectedRowsModel.selectAllRows) ||\r\n (this._selectedRowsModel.selectedRows.indexOf(rowId) === -1 && this._selectedRowsModel.selectAllRows);\r\n\r\n // if the grid could have been filtered and the \"select all\" checkbox was checked; reset it\r\n this._gridHasFiltersAndSelectAllChecked = false;\r\n }\r\n\r\n /**\r\n * Toggles the selection of all rows.\r\n * When filters are applied, it will select all within the results that the filter returns.\r\n */\r\n async toggleAllChecked(): Promise {\r\n // reset the click node index; they have to start over and click on a node in order to support Shift click\r\n this._clickedNodeId = null;\r\n\r\n if (this._gridHasFilters) {\r\n // the grid has filters:\r\n // option 1: we have currently selected all the results; get rows in the entire filter range and exclude them\r\n // option 2: we have currently selected none of the results; get rows in the entire filter range and include them\r\n const selecting: boolean = !this._gridHasFiltersAndSelectAllChecked;\r\n this._gridHasFiltersAndSelectAllChecked = !this._gridHasFiltersAndSelectAllChecked;\r\n\r\n if ((!this._selectedRowsModel.selectAllRows && !selecting)) {\r\n // If we are only deselecting all, do so and skip the range selection\r\n this._selectedRowsModel.selectedRows = [];\r\n } else {\r\n await this._selectRange(0, MAX_INT, selecting);\r\n }\r\n } else {\r\n // grid does not have filters. check which mode we're in and do the opposite:\r\n // option 1: we are in exclude mode; select all and clear out individual row tracking list\r\n // option 2: we are not in exclude mode; select all rows and clear out the individual row tracking list\r\n this._gridHasFiltersAndSelectAllChecked = false;\r\n if (this._selectedRowsModel.selectAllRows && this._selectedRowsModel.selectedRows.length) {\r\n this._selectedRowsModel.selectAllRows = true;\r\n this._selectedRowsModel.selectedRows = [];\r\n } else {\r\n this._selectedRowsModel.selectAllRows = !this._selectedRowsModel.selectAllRows;\r\n this._selectedRowsModel.selectedRows = [];\r\n }\r\n }\r\n\r\n this._selectedRowsSubject.next(this._selectedRowsModel);\r\n this._gridOptions.api.redrawRows();\r\n }\r\n\r\n /**\r\n * Clears any selection tracking returning it to the original state where nothing is selected.\r\n */\r\n clear(notify: boolean = true): void {\r\n this._pendingRangeSelections = [];\r\n this._selectedRowsModel = {\r\n selectAllRows: false,\r\n selectedRows: []\r\n };\r\n\r\n this._gridHasFiltersAndSelectAllChecked = false;\r\n\r\n if (this._gridOptions && this._gridOptions.api) {\r\n this._gridOptions.api.refreshHeader();\r\n }\r\n\r\n if (notify) {\r\n this._selectedRowsSubject.next(this._selectedRowsModel);\r\n }\r\n }\r\n\r\n /**\r\n * This function will fetch all the IDs between two indices defining a range and select/deselect that range of IDs.\r\n * @param aIndex The ID of the first row in the selection range.\r\n * @param bIndex The ID of the last (second) row in the selection range.\r\n * @param selectRange Mark the IDs in that range as selected.\r\n */\r\n private async _selectRange(aIndex: number, bIndex: number, selectRange: boolean): Promise {\r\n this._isSelectingRange.next(true);\r\n\r\n // take them in either order and sort them\r\n const startIndex = aIndex > bIndex ? bIndex : aIndex;\r\n const endIndex = aIndex > bIndex ? aIndex : bIndex;\r\n\r\n let rowsResponse: Compliance.QueryResultModel;\r\n\r\n const rangeSelection: RangeSelection = { from: startIndex, to: endIndex };\r\n this._pendingRangeSelections.push(rangeSelection);\r\n\r\n try {\r\n rowsResponse = await this._getRowIdsFn(startIndex, endIndex);\r\n } finally {\r\n const index = this._pendingRangeSelections.indexOf(rangeSelection);\r\n this._pendingRangeSelections.splice(index, 1);\r\n }\r\n\r\n // we are going to select or deselect, no matter what that action is we must check the mode the grid is in as well\r\n // if selecting range\r\n // option 1: we are in include mode so the IDs need to be added to the collection of individually tracked rows\r\n // option 2: we are in exclude mode, so those IDs need to be removed from the collection of individually tracked rows\r\n // by excluding them we are automatically marking them as selected as we're in select all (exclude) mode\r\n // if deselecting range, the same as above but reversed\r\n\r\n // as far as the collection of individually tracked rows and how it gets modified, the following applies\r\n // you want to add the collection only if:\r\n // option 1: you are in include mode (selectAllRows = false) and are trying to select the range of IDs\r\n // option 2: you are in exclude mode (selectAllRows = true) and are trying to deselect the range of IDs\r\n // you want to remove from the collection only if:\r\n // option 1: you are in exclude mode (selectAllRows = true) and are trying to select the range of IDs\r\n // option 2: you are in include mode (selectAllRows = false) and are trying to deselect the range of IDs\r\n if ((!this._selectedRowsModel.selectAllRows && selectRange) || (this._selectedRowsModel.selectAllRows && !selectRange)) {\r\n // add to the individually tracked row Ids (using a Set data type to enforce unique IDs)\r\n const idSet = new Set(this._selectedRowsModel.selectedRows.concat(rowsResponse.data));\r\n this._selectedRowsModel.selectedRows = Array.from(idSet);\r\n this._isSelectingRange.next(false);\r\n return;\r\n }\r\n\r\n if ((this._selectedRowsModel.selectAllRows && selectRange) || (!this._selectedRowsModel.selectAllRows && !selectRange)) {\r\n // remove from the individually tracked row Ids (using a Set data type to enforce unique IDs)\r\n const idsToRemove = new Set(rowsResponse.data);\r\n const selectedRowsWithoutIds = this._selectedRowsModel.selectedRows.filter(x => !idsToRemove.has(x));\r\n this._selectedRowsModel.selectedRows = selectedRowsWithoutIds;\r\n this._isSelectingRange.next(false);\r\n return;\r\n }\r\n\r\n // all options should be covered\r\n console.warn('Could not determine how to multi-select a range in the grid.');\r\n }\r\n\r\n /**\r\n * Checks if the grid has any active filters applied.\r\n */\r\n private _isGridFiltered(): boolean {\r\n return this._gridOptions.api.isAnyFilterPresent() || this._isExternalFilterApplied;\r\n }\r\n\r\n /**\r\n * Retrieves the identifier of a row node given the ID of a row (user specified) and a row node (grid specific).\r\n * Takes into account how the tracker is setup to identify range selection (via grid node index) or if a pre-sort is implied and the row ID should be used.\r\n */\r\n private _getRowNodeId(rowId: number, rowNode: RowNode): number {\r\n return rowNode.rowIndex;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { IHeaderAngularComp } from 'ag-grid-angular/main';\r\nimport { AgGridMultiSelectTracker, AgGridMultiSelectHeaderRendererParams } from './agGridMultiSelectTracker';\r\n\r\n@Component({\r\n selector: 'ag-grid-multi-select-header',\r\n template: `\r\n \r\n \r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class AgGridMultiSelectedHeaderRendererComponent implements IHeaderAngularComp {\r\n /**\r\n * SELECTED ALL ROWS | SELECTED INDIVIDUAL ROWS | HAS FILTERED ROWS | HAS SELECTED ALL FILTERED ROWS | STATE\r\n * true | true | true | true | checked\r\n * true | true | true | false | indeterminate\r\n * true | true | false | true | ERROR\r\n * true | true | false | false | indeterminate\r\n * true | false | true | true | checked (ERROR?)\r\n * true | false | true | false | ERROR\r\n * true | false | false | true | ERROR\r\n * true | false | false | false | checked\r\n * false | true | true | true | checked\r\n * false | true | true | false | unchecked\r\n * false | true | false | true | ERROR\r\n * false | true | false | false | indeterminate\r\n * false | false | true | true | checked\r\n * false | false | true | false | unchecked\r\n * false | false | false | true | ERROR\r\n * false | false | false | false | unchecked\r\n */\r\n\r\n private _params: AgGridMultiSelectHeaderRendererParams;\r\n private _tracker: AgGridMultiSelectTracker;\r\n private _rowId: number;\r\n\r\n agInit(params: AgGridMultiSelectHeaderRendererParams): void {\r\n this._params = params;\r\n this._tracker = params.tracker;\r\n this._rowId = params.value;\r\n }\r\n\r\n /**\r\n * Checks if the grid header component is checked. (see table for implementation logic)\r\n */\r\n isChecked(): boolean {\r\n const hasSelectedAllRows = this._tracker.getSelectedRowsModel().selectAllRows;\r\n const hasSelectedIndividualRows = this._tracker.getSelectedRowsModel().selectedRows.length > 0;\r\n const hasFilteredRows = this._tracker.hasFilteredRows();\r\n const hasSelectedAllFilteredRows = this._tracker.hasSelectedAllFilteredRows();\r\n if (hasSelectedAllRows && hasSelectedIndividualRows && hasFilteredRows && hasSelectedAllFilteredRows) return true;\r\n if (hasSelectedAllRows && !hasSelectedIndividualRows && !hasFilteredRows && !hasSelectedAllFilteredRows) return true;\r\n if (hasSelectedAllRows && !hasSelectedIndividualRows && hasFilteredRows && hasSelectedAllFilteredRows) return true;\r\n if (!hasSelectedAllRows && hasSelectedIndividualRows && hasFilteredRows && hasSelectedAllFilteredRows) return true;\r\n if (!hasSelectedAllRows && !hasSelectedIndividualRows && hasFilteredRows && hasSelectedAllFilteredRows) return true;\r\n return false;\r\n }\r\n\r\n /**\r\n * Checks if the grid header component is unchecked. (see table for implementation logic)\r\n */\r\n isUnchecked(): boolean {\r\n const hasSelectedAllRows = this._tracker.getSelectedRowsModel().selectAllRows;\r\n const hasSelectedIndividualRows = this._tracker.getSelectedRowsModel().selectedRows.length > 0;\r\n const hasFilteredRows = this._tracker.hasFilteredRows();\r\n const hasSelectedAllFilteredRows = this._tracker.hasSelectedAllFilteredRows();\r\n if (!hasSelectedAllRows && hasSelectedIndividualRows && hasFilteredRows && !hasSelectedAllFilteredRows) return true;\r\n if (!hasSelectedAllRows && !hasSelectedIndividualRows && hasFilteredRows && !hasSelectedAllFilteredRows) return true;\r\n if (!hasSelectedAllRows && !hasSelectedIndividualRows && !hasFilteredRows && !hasSelectedAllFilteredRows) return true;\r\n return false;\r\n }\r\n\r\n /**\r\n * Checks if the grid header component is indeterminate. (see table for implementation logic)\r\n */\r\n isIndeterminate(): boolean {\r\n const hasSelectedAllRows = this._tracker.getSelectedRowsModel().selectAllRows;\r\n const hasSelectedIndividualRows = this._tracker.getSelectedRowsModel().selectedRows.length > 0;\r\n const hasFilteredRows = this._tracker.hasFilteredRows();\r\n const hasSelectedAllFilteredRows = this._tracker.hasSelectedAllFilteredRows();\r\n if (hasSelectedAllRows && hasSelectedIndividualRows && hasFilteredRows && !hasSelectedAllFilteredRows) return true;\r\n if (hasSelectedAllRows && hasSelectedIndividualRows && !hasFilteredRows && !hasSelectedAllFilteredRows) return true;\r\n if (!hasSelectedAllRows && hasSelectedIndividualRows && !hasFilteredRows && !hasSelectedAllFilteredRows) return true;\r\n return false;\r\n }\r\n\r\n /**\r\n * Checks if the toggle button is enabled/disabled based on any ongoing activity in the grid.\r\n */\r\n isPendingRangeSelection(): boolean {\r\n const isGridPendingRangeSelection = this._tracker.isGridPendingRangeSelection();\r\n if (isGridPendingRangeSelection) return true;\r\n return false;\r\n }\r\n\r\n /**\r\n * Determines the class to be applied to the checkbox based on the state that is being tracked.\r\n * @param isForIconStyle Target icon classes.\r\n */\r\n getCheckboxClass(isForIconStyle: boolean): string {\r\n const isDisabled = this.isPendingRangeSelection() || this.isDisabled();\r\n\r\n let className = isForIconStyle ? 'ag-icon ag-icon-checkbox' : 'ag-checkbox';\r\n\r\n const isChecked = this.isChecked();\r\n if (isChecked) {\r\n className += isDisabled ? '-checked-readonly' : '-checked';\r\n return className;\r\n }\r\n\r\n const isUnchecked = this.isUnchecked();\r\n if (isUnchecked) {\r\n className += isDisabled ? '-unchecked-readonly' : '-unchecked';\r\n return className;\r\n }\r\n\r\n const isIndeterminate = this.isIndeterminate();\r\n if (isIndeterminate) {\r\n className += isDisabled ? '-indeterminate-readonly' : '-indeterminate';\r\n return className;\r\n }\r\n\r\n return className;\r\n }\r\n\r\n /**\r\n * Toggle checked status.\r\n * @param event Event.\r\n */\r\n toggleChecked(event: Event): void {\r\n if (!this.isDisabled()) {\r\n this._tracker.toggleAllChecked();\r\n\r\n if (this._params && this._params.updateAllRowValues) {\r\n this._params.updateAllRowValues(this._params, this.isChecked());\r\n }\r\n }\r\n }\r\n\r\n /**\r\n * Check if disabled\r\n */\r\n isDisabled(): boolean {\r\n return this._params && this._params.isCellRendererDisabledFn && this._params.isCellRendererDisabledFn(this._rowId, this._params.data);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular/main';\r\nimport { AgGridMultiSelectCellRendererParams } from './agGridMultiSelectTracker';\r\nimport { AgGridMultiSelectTracker } from './agGridMultiSelectTracker';\r\n\r\n@Component({\r\n selector: 'ag-grid-multi-select-cell',\r\n template: `\r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class AgGridMultiSelectedCellRendererComponent implements ICellRendererAngularComp {\r\n params: AgGridMultiSelectCellRendererParams;\r\n\r\n private _tracker: AgGridMultiSelectTracker;\r\n private _rowId: number;\r\n\r\n agInit(params: AgGridMultiSelectCellRendererParams): void {\r\n this.params = params;\r\n this._tracker = params.tracker;\r\n this._rowId = params.value;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n isDisabled(): boolean {\r\n return this.params && this.params.isCellRendererDisabledFn && this.params.isCellRendererDisabledFn(this._rowId, this.params.data);\r\n }\r\n\r\n isHidden(): boolean {\r\n return this.params && this.params.isCellRendererHiddenFn && this.params.isCellRendererHiddenFn(this._rowId, this.params.data);\r\n }\r\n\r\n isSelected(): boolean {\r\n return !this.isDisabled() && this._rowId && this._tracker.isRowSelected(this._rowId);\r\n }\r\n\r\n isPendingRangeSelection(): boolean {\r\n return this._tracker.isRowPendingRangeSelection(this._rowId, this.params.node);\r\n }\r\n\r\n /**\r\n * Determines the class to be applied to the checkbox based on the state that is being tracked.\r\n */\r\n getCheckboxClass(): string {\r\n const isDisabled = this.isDisabled();\r\n const isSelected = this.isSelected();\r\n\r\n let className = 'ag-icon ag-icon-checkbox';\r\n\r\n // if is selected and disabled then mark it as indeterminate\r\n // a disabled checkbox could be selected only because of the \"select all\" header checkbox, nothing we can do in that case (the API has to take care of it)\r\n if (isSelected) {\r\n // if disabled it should probably be \"checked-readonly\"\r\n // a parameter should be specified if read-only items should be visually shown as \"checked\" or forced to always \"unchecked\"\r\n className += isDisabled ? '-unchecked-readonly' : '-checked';\r\n } else {\r\n className += isDisabled ? '-unchecked-readonly' : '-unchecked';\r\n }\r\n return className;\r\n }\r\n\r\n /**\r\n * Determines the title of the checkbox.\r\n */\r\n getCheckboxTitle() {\r\n if (this.params.tooltipText && this.params.tooltipText(this.params)) {\r\n return this.params.tooltipText(this.params);\r\n } else {\r\n return this._rowId ? 'Toggle selection' : '';\r\n }\r\n }\r\n\r\n /**\r\n * Toggle checked status.\r\n * @param event Event.\r\n */\r\n toggleChecked(event: Event): void {\r\n if (this.isDisabled()) return;\r\n\r\n if (event instanceof MouseEvent) {\r\n this._tracker.toggleRowChecked(this._rowId, this.params.node, (event as MouseEvent).shiftKey);\r\n } else {\r\n this._tracker.toggleRowChecked(this._rowId, this.params.node, false);\r\n }\r\n\r\n if (this.params && this.params.updateRowValue) {\r\n this.params.updateRowValue(this.params, this.isSelected());\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { PermissionWithOptions } from './instancePermissionPanel.component';\r\n\r\nexport interface ICellRendererParamsForInstanceRightGridAction extends ICellRendererParams {\r\n canEdit: () => boolean;\r\n permissionChanged: () => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n {{params.data.right.rights}}\r\n \r\n `\r\n})\r\nexport class InstanceRightGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForInstanceRightGridAction;\r\n rightOptions: PermissionWithOptions[];\r\n right: PermissionWithOptions;\r\n\r\n agInit(params: ICellRendererParamsForInstanceRightGridAction): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { PermissionWithOptions } from './applicationPermissionPanel.component';\r\n\r\nexport interface ICellRendererParamsForApplicationPermissionGridAction extends ICellRendererParams {\r\n canEdit: () => boolean;\r\n permissionChanged: () => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n {{params.data.right.rights}}\r\n \r\n `\r\n})\r\nexport class ApplicationPermissionGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForApplicationPermissionGridAction;\r\n rightOptions: PermissionWithOptions[];\r\n right: PermissionWithOptions;\r\n\r\n agInit(params: ICellRendererParamsForApplicationPermissionGridAction): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WsAgGridWrapperComponent } from './wsAgGridWrapper.component';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { TaxRatesPanelTaxAuthoritiesCellRendererComponent } from '../../../Assessor-Collector/Tax-Rates/agGridTaxAuthoritiesCellRenderer.component';\r\nimport { TaxRateCommandCenterCommentsCellRendererComponent } from '../../../Tax-Rate/Command-Center/agGridCommentsCellRenderer.component';\r\nimport { TaxRateCommandCenterAttachmentsCellRendererComponent } from '../../../Tax-Rate/Command-Center/agGridAttachmentsCellRenderer.component';\r\nimport { TaxRateQcByCellRendererComponent } from '../../../Tax-Rate/agGridQcByCellRenderer.component';\r\nimport { ForecastBudgetYearCellRendererComponent } from '../../../Budget/agGridForecastBudgetYearCellRender.component';\r\nimport { ForecastBudgetYearCellEditorComponent } from '../../../Budget/agGridForecastBudgetYearCellEditor.component';\r\nimport { AgGridSwitchCellRendererComponent } from '../../../Budget/agGridSwitchCellRenderer.component';\r\nimport { TaxingDistrictListGridActionCellRendererComponent } from '../../../Assessor-Collector/Taxing-District/Taxing-District-List/agGridActionCellRenderer.component';\r\nimport { UserGroupsGridActionCellRendererComponent } from '../../../User-Group/User-Group-List/agGridActionCellRendererComponent';\r\nimport { CompanyPermissionsGridActionCellRendererComponent } from '../../../Permission/Company/Panel/agGridActionCellRenderer.component';\r\nimport { ActionViewOutputDefaultsGridActionCellRendererComponent } from '../../../Task/ActionView/Action-View-Output-Defaults/agGridActionCellRenderer.component';\r\nimport { AgGridExtensionsModule } from '../agGridExtensions.module';\r\nimport { AgGridLoadingOverlayComponent } from '../../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer } from '../MultiSelectTracker';\r\nimport { AgGridLinkCellRendererComponent } from '../CellRenderers/agGridLinkCellRenderer.component';\r\nimport {\r\n InstanceRightGridActionCellRendererComponent\r\n} from '../../../Permission/Instance/agGridActionCellRenderer.component';\r\nimport {\r\n ApplicationPermissionGridActionCellRendererComponent\r\n} from '../../../Permission/Application/agGridActionCellRenderer.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n AgGridExtensionsModule,\r\n AgGridModule.withComponents([\r\n TaxRatesPanelTaxAuthoritiesCellRendererComponent,\r\n TaxRateCommandCenterCommentsCellRendererComponent,\r\n TaxRateCommandCenterAttachmentsCellRendererComponent,\r\n TaxRateQcByCellRendererComponent,\r\n ForecastBudgetYearCellRendererComponent,\r\n ForecastBudgetYearCellEditorComponent,\r\n AgGridSwitchCellRendererComponent,\r\n TaxingDistrictListGridActionCellRendererComponent,\r\n UserGroupsGridActionCellRendererComponent,\r\n CompanyPermissionsGridActionCellRendererComponent,\r\n InstanceRightGridActionCellRendererComponent,\r\n ApplicationPermissionGridActionCellRendererComponent,\r\n ActionViewOutputDefaultsGridActionCellRendererComponent,\r\n AgGridLoadingOverlayComponent,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridLinkCellRendererComponent\r\n ])\r\n ],\r\n declarations: [WsAgGridWrapperComponent],\r\n exports: [WsAgGridWrapperComponent]\r\n})\r\nexport class WsAgGridWrapperModule {}\r\n","
\r\n \r\n {{parcelType}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n","import { Component, Input, OnChanges } from '@angular/core';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'parcel-icon',\r\n templateUrl: './parcelIcon.component.html',\r\n styleUrls: ['./parcelIcon.component.scss']\r\n})\r\nexport class ParcelIconComponent implements OnChanges {\r\n @Input() size: string = 'small';\r\n @Input() includeIcons: boolean;\r\n @Input() stateAllowConsolidating: boolean;\r\n @Input() ppReturnPreparationAllowed: boolean;\r\n @Input() parcel: any;\r\n @Input() propTypeParam: string;\r\n\r\n @Input()\r\n set isLinkedParcel(isLinked: boolean) {\r\n this.isLinked = isLinked;\r\n this._linkedOverride = true;\r\n }\r\n\r\n @Input()\r\n set isMasterParcel(isMaster: boolean) {\r\n this.isMaster = isMaster;\r\n this._masterOverride = true;\r\n }\r\n\r\n icons: any[] = [];\r\n\r\n isLinked: boolean;\r\n isMaster: boolean;\r\n parcelType: string;\r\n\r\n private _linkedOverride: boolean;\r\n private _masterOverride: boolean;\r\n\r\n get parcelTypeClass(): string {\r\n return `${this.size}${(this.isLinked || this.isMaster) ? '-with-icon' : ''} property-type-${this.parcelType}`;\r\n }\r\n\r\n get parcelIconClass(): string {\r\n return `${(this.isMaster) ? 'fa-star' : 'fa-chain'} property-type-${this.parcelType}`;\r\n }\r\n\r\n ngOnChanges(): void {\r\n this._setParcelParams();\r\n }\r\n\r\n private _setParcelParams(): void {\r\n this.parcelType = (this.propTypeParam) ? _.get(this.parcel, this.propTypeParam) : this.parcel.propTypeAbbr;\r\n\r\n if (!this._linkedOverride) {\r\n this.isLinked = this.parcel.isLinked;\r\n }\r\n\r\n if (!this._masterOverride) {\r\n this.isMaster = this.parcel.isMasterParcel;\r\n }\r\n\r\n if (this.includeIcons) {\r\n this.icons = [];\r\n if (this.parcel.consolidatingTypeId === 2 && this.ppReturnPreparationAllowed) {\r\n this.icons.push({\r\n iconClass: 'fa-sitemap',\r\n colorClass: `${this.size} consolidated`,\r\n helpTooltip: this.stateAllowConsolidating ? 'app.state-consolidated-parcel' : 'app.site-consolidated-parcel'\r\n });\r\n }\r\n if (this.parcel.consolidatedParcelId && this.ppReturnPreparationAllowed && !this.parcel.consolidatingTypeId && this.parcel.activityStatusID !== Core.ActivityStatuses.Inactive) {\r\n this.icons.push({\r\n iconClass: 'fa-sitemap',\r\n colorClass: `${this.size} merged`,\r\n helpTooltip: this.stateAllowConsolidating ? 'app.state-merged-parcel' : 'app.site-merged-parcel'\r\n });\r\n }\r\n if (this.parcel.isReportingParcel && this.ppReturnPreparationAllowed) {\r\n this.icons.push({\r\n iconClass: 'fa-file-text-o',\r\n colorClass: `${this.size} default`,\r\n helpTooltip: 'app.reporting-parcel'\r\n });\r\n }\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ParcelTypeCellRendererComponentParams extends ICellRendererParams {\r\n getParcelType: (params: ParcelTypeCellRendererComponentParams) => string;\r\n isLinkedParcel: (params: ParcelTypeCellRendererComponentParams) => boolean;\r\n isMasterParcel: (params: ParcelTypeCellRendererComponentParams) => boolean;\r\n isReportingParcel?: (params: ParcelTypeCellRendererComponentParams) => boolean;\r\n isConsolidatedParcel?: (params: ParcelTypeCellRendererComponentParams) => boolean;\r\n stateAllowConsolidating?: (params: ParcelTypeCellRendererComponentParams) => boolean;\r\n ppReturnPreparationAllowed?: (params: ParcelTypeCellRendererComponentParams) => boolean;\r\n isMergedParcel?: (params: ParcelTypeCellRendererComponentParams) => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'parcel-type-cell',\r\n template: `\r\n \r\n \r\n `,\r\n styleUrls: ['./parcelTypeCellRenderer.component.scss']\r\n})\r\nexport class ParcelTypeCellRendererComponent implements ICellRendererAngularComp {\r\n params: ParcelTypeCellRendererComponentParams;\r\n isReportingParcel: boolean = false;\r\n isConsolidatedParcel: boolean = false;\r\n stateAllowConsolidating: boolean = false;\r\n ppReturnPreparationAllowed: boolean = false;\r\n isMergedParcel: boolean = false;\r\n\r\n parcel: Core.ParcelTileDTO;\r\n\r\n agInit(params: ParcelTypeCellRendererComponentParams): void {\r\n this.params = params;\r\n this.parcel = params.data as Core.ParcelTileDTO;\r\n\r\n if (params.getParcelType) {\r\n this.parcel.propTypeAbbr = params.getParcelType(params);\r\n }\r\n\r\n if (params.isLinkedParcel) {\r\n this.parcel.isLinked = params.isLinkedParcel(params);\r\n }\r\n\r\n if (params.isMasterParcel) {\r\n this.parcel.isMasterParcel = params.isMasterParcel(params);\r\n }\r\n\r\n if (params.isReportingParcel) {\r\n this.isReportingParcel = params.isReportingParcel(params);\r\n }\r\n if (params.isConsolidatedParcel) {\r\n this.isConsolidatedParcel = params.isConsolidatedParcel(params);\r\n }\r\n if (params.stateAllowConsolidating) {\r\n this.stateAllowConsolidating = params.stateAllowConsolidating(params);\r\n }\r\n if (params.ppReturnPreparationAllowed) {\r\n this.ppReturnPreparationAllowed = params.ppReturnPreparationAllowed(params);\r\n }\r\n if (params.isMergedParcel) {\r\n this.isMergedParcel = params.isMergedParcel(params);\r\n }\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport {\r\n AgGridTooltipCellRendererParams\r\n} from '../../../../Compliance/AgGrid/CellRenderers/agGridTooltipCellRenderer.component';\r\n\r\n@Component({\r\n selector: 'activity-status-cell-renderer',\r\n template: `\r\n Inactive\r\n Active (Pending)\r\n `,\r\n styles: [`\r\n .status-img {\r\n height: 20px;\r\n width: auto;\r\n margin-top: 2px;\r\n transform: rotate(0deg);\r\n right: unset;\r\n }\r\n `]\r\n})\r\nexport class ActivityStatusCellRendererComponent implements ICellRendererAngularComp {\r\n\r\n params: AgGridTooltipCellRendererParams;\r\n isInactive: boolean;\r\n isActivePending: boolean;\r\n\r\n agInit(params: AgGridTooltipCellRendererParams): void {\r\n this.params = params;\r\n this.isInactive = params.value.toLowerCase() === 'inactive';\r\n this.isActivePending = params.value.toLowerCase() === 'active (pending)';\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const AG_GRID_TOOL_PANEL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'ag-grid-tool-panel.show-configure',\r\n tooltipText: 'Configure layout'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.hide-configure',\r\n tooltipText: 'Hide configure layout'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.show-filters',\r\n tooltipText: 'Show filters'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.hide-filters',\r\n tooltipText: 'Hide filters'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.export',\r\n tooltipText: 'Export data'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.export-tab-delimited',\r\n tooltipText: 'Export data to tab-delimited format which does not have formatting but exports faster'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.export-pdf',\r\n tooltipText: 'Archive and Export pdf files'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.export-excel',\r\n tooltipText: 'Export data to Excel'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.size-to-fit',\r\n tooltipText: 'Size columns to fit the available space'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.size-to-content',\r\n tooltipText: 'Size columns to fit cell contents'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.bulk-update',\r\n tooltipText: 'Bulk update selected rows'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.clearFiltersHelpContentId',\r\n tooltipText: 'Clear filters'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.pinColumn',\r\n tooltipText: 'Pin column left'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.additional-actions',\r\n tooltipText: 'Additional actions are available'\r\n }\r\n];\r\n"," 0\">\r\n\r\n
\r\n

Layout

\r\n \r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
Name is required.
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
Description max length is 50 characters.
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
Visibility is required.
\r\n
\r\n
\r\n {{ params.companyId ? form.controls.visibility.value?.description : form.controls.visibility.value?.descriptionNoCompany }}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n {{ form.controls.visibility.value?.warning }}\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
    \r\n
  • \r\n {{ v.name }}: {{ params.companyId ? v.description : v.descriptionNoCompany }}\r\n
  • \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { BusyIndicatorMessageManager } from '../../../../../Busy-Indicator';\r\nimport { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';\r\nimport { GridLayoutSpecificationRepository } from '../../../../Repositories/gridLayoutSpecificationRepository';\r\nimport * as _ from 'lodash';\r\nimport { AgGridLayoutSpecificationListItemModel, AgGridLayoutSpecificationVisibilityModel } from '../../models';\r\nimport { IWeissmanModalComponent } from '../../../../WeissmanModalService';\r\n\r\nexport interface AgGridLayoutSpecificationDetailsParams {\r\n specification: AgGridLayoutSpecificationListItemModel;\r\n userId: System.Guid;\r\n visibilities: AgGridLayoutSpecificationVisibilityModel[];\r\n companyId: number;\r\n}\r\n\r\n@Component({\r\n templateUrl: './agGridLayoutSpecificationDetails.component.html',\r\n selector: 'ag-grid-layout-specification-details',\r\n styleUrls: ['./agGridLayoutSpecificationDetails.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class AgGridLayoutSpecificationDetailsComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formBuilder: UntypedFormBuilder,\r\n private readonly _gridLayoutSpecificationRepository: GridLayoutSpecificationRepository) {\r\n }\r\n\r\n params: AgGridLayoutSpecificationDetailsParams;\r\n result: Compliance.GridLayoutSpecificationModel;\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n form: UntypedFormGroup;\r\n\r\n ngOnInit(): void {\r\n this.form = this._formBuilder.group({\r\n layoutName: [null, [Validators.required]],\r\n visibility: [null, [Validators.required]],\r\n description: [null, [Validators.maxLength(50)]],\r\n });\r\n\r\n this.form.setValue({\r\n layoutName: this.params.specification.name,\r\n description: this.params.specification.description,\r\n visibility: this.params.specification.visibilityItem\r\n });\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgId = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgId);\r\n\r\n try {\r\n const visibilityItem = this.form.get('visibility').value;\r\n\r\n const updateModel: Compliance.GridLayoutSpecificationModel = _.extend(\r\n {} as Compliance.GridLayoutSpecificationModel,\r\n this.params.specification,\r\n {\r\n name: this.form.get('layoutName').value,\r\n description: this.form.get('description').value,\r\n visibility: visibilityItem.visibility,\r\n isDefault: visibilityItem.isDefault,\r\n companyId: visibilityItem.isCompany ? this.params.companyId : null,\r\n userId: visibilityItem.visibility === Compliance.SpecificationVisibilityEnum.Private ? this.params.userId: null\r\n });\r\n\r\n if (updateModel.gridLayoutSpecificationId === 0) {\r\n this.result = await lastValueFrom(this._gridLayoutSpecificationRepository.create(updateModel));\r\n } else {\r\n this.result = await lastValueFrom(this._gridLayoutSpecificationRepository.update(updateModel));\r\n }\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const AG_GRID_LAYOUT_SPECIFICATION_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'ag-grid-layout-specification.copy',\r\n tooltipText: 'Save a copy of this layout.'\r\n },\r\n {\r\n helpContentId: 'ag-grid-layout-specification.no-layout',\r\n tooltipText: 'Select a layout.'\r\n },\r\n {\r\n helpContentId: 'ag-grid-layout-specification.edit-default',\r\n tooltipText: 'The built-in default layout cannot be saved.'\r\n },\r\n {\r\n helpContentId: 'ag-grid-layout-specification.delete-default',\r\n tooltipText: 'The built-in default layout cannot be deleted.'\r\n }\r\n];\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AccountService, UserData } from '../User/account.service';\r\nimport { UserInstanceService } from '../User/userInstance.service';\r\nimport { RyanInstanceId } from '../constants.new';\r\nimport { UserRepository } from '../Core-Repositories';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Injectable(\r\n {providedIn: 'root'}\r\n)\r\nexport class UserService {\r\n constructor(\r\n private readonly _accountService: AccountService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _userRepository: UserRepository\r\n ) {}\r\n\r\n private _loginCallbacks = [];\r\n\r\n isSingleInstanceSelected() {\r\n return this._userInstanceService.isSingleInstanceSelected();\r\n }\r\n\r\n isRyanInstanceSelected(): boolean {\r\n return this._userInstanceService.isRyanInstanceSelected();\r\n }\r\n\r\n isSSOIntegrationEnabled(): Promise {\r\n return lastValueFrom(this._userRepository.isSSOIntegrationEnabled());\r\n }\r\n\r\n getSSOIntegrationEndpoint(domain: string): any {\r\n return lastValueFrom(this._userRepository.getSSOIntegrationEndpoint(domain));\r\n }\r\n\r\n hasRyanInstanceMembership(): boolean {\r\n return this.getUser().instanceMembership.filter(i=>i.instanceId === RyanInstanceId).length > 0;\r\n }\r\n\r\n getUser(): UserData {\r\n return this._accountService.userData;\r\n }\r\n\r\n deleteUserSettingByNameAndID(name: string, groupID: number, id: number): void {\r\n _.remove(this._accountService.userData.settings, (item) => {\r\n return item.name === name && item.groupId === groupID && item.id === id;\r\n })\r\n }\r\n\r\n setCredentials(user): void {\r\n let callback = this._loginCallbacks.shift();\r\n while (callback) {\r\n console.log(['Executing login callback', callback]);\r\n callback();\r\n callback = this._loginCallbacks.shift();\r\n }\r\n }\r\n\r\n changePassword(current: string, newPassword: string): Promise {\r\n return lastValueFrom(this._userRepository.changePassword(this._accountService.userData.username, current, newPassword));\r\n }\r\n\r\n emailPasswordReset(userName: string): Promise {\r\n return lastValueFrom(this._userRepository.emailPasswordReset(userName));\r\n }\r\n\r\n updateUser(user: UserData): Promise {\r\n return lastValueFrom(this._userRepository.updateUser(user));\r\n }\r\n\r\n setUserDescription(userId: number, description: string): Promise {\r\n return lastValueFrom(this._userRepository.setUserDescription(userId, description));\r\n }\r\n\r\n sendPasswordResetToken(usernameOrEmail: string): Promise {\r\n return lastValueFrom(this._userRepository.sendPasswordResetToken(usernameOrEmail));\r\n }\r\n\r\n resetPasswordUsingToken(tokenHash: string, newPassword: string): Promise {\r\n return lastValueFrom(this._userRepository.resetPasswordUsingToken(tokenHash, newPassword));\r\n }\r\n\r\n homeInstanceId(): number {\r\n return this.getUser().instanceMembership.find(x => x.isHomeInstance).instanceId;\r\n }\r\n}\r\n"," 0\">\r\n\r\n
\r\n
\r\n
\r\n
Layout
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n \r\n
\r\n {{ selectedSpecification.description }}\r\n
\r\n
\r\n
\r\n \r\n
\r\n {{ selectedSpecification.visibilityItem.name }}\r\n {{ companyId ? selectedSpecification.visibilityItem.description : selectedSpecification.visibilityItem.descriptionNoCompany }}\r\n
\r\n
\r\n
\r\n \r\n
\r\n {{ selectedSpecification.changedByName }}\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit, Output, EventEmitter } from '@angular/core';\r\nimport { GridLayoutSpecificationRepository } from '../../../Repositories';\r\nimport { GridOptions } from 'ag-grid-community';\r\nimport { MessageModalService } from '../../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { WeissmanModalService } from '../../../WeissmanModalService';\r\nimport { UserService } from '../../../../Account/user.service';\r\nimport { RestrictService, Roles } from '../../../../Common/Permissions/restrict.service';\r\nimport { AgGridLayoutSpecificationModel, AgGridLayoutSpecificationListItemModel, AgGridLayoutSpecificationVisibilityModel } from '../models';\r\nimport { BusyIndicatorMessageManager } from '../../../../Busy-Indicator';\r\nimport { AgGridLayoutSpecificationDetailsComponent, AgGridLayoutSpecificationDetailsParams } from './Details/agGridLayoutSpecificationDetails.component';\r\nimport { AG_GRID_LAYOUT_SPECIFICATION_HELP } from './agGridLayoutSpecification.component.help';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/internal/operators/takeUntil';\r\nimport { AgGridPersistenceService } from '../../agGridPersistence.service';\r\n\r\nimport * as _ from 'lodash';\r\nimport { filter, forEach } from 'lodash/fp';\r\n\r\n@Component({\r\n selector: 'ag-grid-layout-specification',\r\n templateUrl: './agGridLayoutSpecification.component.html',\r\n styleUrls: ['./agGridLayoutSpecification.component.scss']\r\n})\r\nexport class AgGridLayoutSpecificationComponent implements OnInit {\r\n constructor(\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _gridLayoutSpecificationRepository: GridLayoutSpecificationRepository,\r\n private readonly _userService: UserService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _agGridPersistenceService: AgGridPersistenceService,\r\n private readonly _helpService: HelpService) { }\r\n\r\n @Input() set gridId(gridId: System.Guid) {\r\n this._gridId = gridId;\r\n if (this._initialized) {\r\n this._load();\r\n }\r\n }\r\n @Input() companyId: number;\r\n @Input() gridOptions: GridOptions & { api?: {appliedFilter?: any}};\r\n @Input() defaultColorizeHeaders: boolean;\r\n @Input() displayedColumnsChanged$: Subject;\r\n\r\n @Output() specificationChanged: EventEmitter = new EventEmitter();\r\n @Output() loadComplete: EventEmitter = new EventEmitter();\r\n\r\n selectedSpecification: AgGridLayoutSpecificationListItemModel;\r\n specifications: AgGridLayoutSpecificationListItemModel[];\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n isBusy: boolean = true;\r\n userId: System.Guid;\r\n canEditShared: boolean = false;\r\n canEditCompany: boolean = false;\r\n colorizeHeaders: boolean = false;\r\n\r\n visibilityBuiltIn: AgGridLayoutSpecificationVisibilityModel = {\r\n name: 'Default',\r\n visibility: Compliance.SpecificationVisibilityEnum.Private,\r\n isDefault: false,\r\n isCompany: false,\r\n description: 'Visible to everyone for any company',\r\n descriptionNoCompany: 'Visible to everyone'\r\n };\r\n\r\n visibilityPrivate: AgGridLayoutSpecificationVisibilityModel = {\r\n name: 'Private',\r\n visibility: Compliance.SpecificationVisibilityEnum.Private,\r\n isDefault: false,\r\n isCompany: false,\r\n description: 'Visible only to you for any company',\r\n descriptionNoCompany: 'Visible only to you'\r\n };\r\n\r\n visibilityPrivateCompany: AgGridLayoutSpecificationVisibilityModel = {\r\n name: 'Private Company',\r\n visibility: Compliance.SpecificationVisibilityEnum.Private,\r\n isDefault: false,\r\n isCompany: true,\r\n description: 'Visible only to you for this top-level company',\r\n descriptionNoCompany: 'Visible only to you'\r\n };\r\n\r\n visibilityCompany: AgGridLayoutSpecificationVisibilityModel = {\r\n name: 'Company',\r\n visibility: Compliance.SpecificationVisibilityEnum.Company,\r\n isDefault: false,\r\n isCompany: true,\r\n description: 'Visible to everyone in this top-level company',\r\n descriptionNoCompany: 'Visible to everyone'\r\n };\r\n\r\n visibilityCompanyDefault: AgGridLayoutSpecificationVisibilityModel = {\r\n name: 'Company Default',\r\n visibility: Compliance.SpecificationVisibilityEnum.Company,\r\n isDefault: true,\r\n isCompany: true,\r\n description: 'Default for everyone in this top-level company',\r\n descriptionNoCompany: 'Default for everyone',\r\n warning: 'Layout is default for top-level company'\r\n };\r\n\r\n visibilityShared: AgGridLayoutSpecificationVisibilityModel = {\r\n name: 'Shared',\r\n visibility: Compliance.SpecificationVisibilityEnum.Shared,\r\n isDefault: false,\r\n isCompany: false,\r\n description: 'Visible to everyone',\r\n descriptionNoCompany: 'Visible to everyone'\r\n };\r\n\r\n visibilities: AgGridLayoutSpecificationVisibilityModel[] = [];\r\n allVisibilities: AgGridLayoutSpecificationVisibilityModel[] = [\r\n this.visibilityPrivate,\r\n this.visibilityPrivateCompany,\r\n this.visibilityCompany,\r\n this.visibilityCompanyDefault,\r\n this.visibilityShared];\r\n\r\n private _builtInSpecification: AgGridLayoutSpecificationListItemModel;\r\n private _initialized: boolean;\r\n private _gridId: System.Guid;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get editHelpContentId(): string {\r\n if (!this.selectedSpecification) {\r\n return 'ag-grid-layout-specification.no-layout';\r\n }\r\n\r\n if (this.selectedSpecification.isDefault) {\r\n return 'ag-grid-layout-specification.edit-default';\r\n }\r\n\r\n if (!this.selectedSpecification.canEdit) {\r\n return 'app.save-disabled';\r\n }\r\n\r\n return 'app.save';\r\n }\r\n\r\n get copyHelpContentId(): string {\r\n if (!this.selectedSpecification) {\r\n return 'ag-grid-layout-specification.no-layout';\r\n }\r\n\r\n return 'ag-grid-layout-specification.copy';\r\n }\r\n\r\n get deleteHelpContentId(): string {\r\n if (!this.selectedSpecification) {\r\n return 'ag-grid-layout-specification.no-layout';\r\n }\r\n\r\n if (this.selectedSpecification.isDefault) {\r\n return 'ag-grid-layout-specification.delete-default';\r\n }\r\n\r\n if (!this.selectedSpecification.canEdit) {\r\n return 'app.delete-disabled';\r\n }\r\n\r\n return 'app.delete';\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(AG_GRID_LAYOUT_SPECIFICATION_HELP);\r\n\r\n await this._load();\r\n\r\n this.displayedColumnsChanged$.pipe(takeUntil(this._destroy$))\r\n .subscribe(() => {\r\n if (!this._builtInSpecification.layout) {\r\n const layoutModel: AgGridLayoutSpecificationModel = {\r\n column: this.gridOptions.columnApi.getColumnState(),\r\n filter: this.gridOptions.api.getFilterModel(),\r\n sort: this.gridOptions.api.getSortModel(),\r\n colorize: this.colorizeHeaders,\r\n unResizedColumns: false\r\n };\r\n\r\n this._builtInSpecification.layout = JSON.stringify(layoutModel);\r\n this._applySpecification();\r\n }\r\n });\r\n\r\n this._agGridPersistenceService.isHeaderGroupColorActive$(this._gridId as string)\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.colorizeHeaders = x);\r\n\r\n this._initialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async delete(): Promise {\r\n if (this.selectedSpecification === this._builtInSpecification) {\r\n return Promise.resolve();\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n `Are you sure you wish to delete '${this.selectedSpecification.name}'?`,\r\n 'Confirm Delete');\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n const index = this.specifications.indexOf(this.selectedSpecification);\r\n\r\n const busyMsgId = 'deleting';\r\n this.busyIndicatorMessageManager.add('Deleting', busyMsgId);\r\n\r\n try {\r\n await lastValueFrom(this._gridLayoutSpecificationRepository.delete(this.selectedSpecification.gridLayoutSpecificationId));\r\n\r\n this.specifications.splice(index, 1);\r\n\r\n this.selectedSpecification = this._builtInSpecification;\r\n this._agGridPersistenceService.setCurrentGridLayoutApplied(this._gridId as string, this.selectedSpecification.name);\r\n\r\n this.onSpecificationChanged();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async edit(copy: boolean): Promise {\r\n if (!(this.gridOptions && this.gridOptions.api && this.gridOptions.columnApi)) {\r\n return Promise.resolve();\r\n }\r\n\r\n const layoutModel: AgGridLayoutSpecificationModel = {\r\n column: this.gridOptions.columnApi.getColumnState(),\r\n filter: this.gridOptions.api.getFilterModel(),\r\n sort: this.gridOptions.api.getSortModel(),\r\n colorize: this.colorizeHeaders,\r\n unResizedColumns: false\r\n };\r\n\r\n const specification: AgGridLayoutSpecificationListItemModel = {\r\n ...this.selectedSpecification,\r\n ...{\r\n gridLayoutSpecificationId: copy ? 0 : this.selectedSpecification.gridLayoutSpecificationId,\r\n layout: JSON.stringify(layoutModel),\r\n name: copy ? '' : this.selectedSpecification.name,\r\n description: copy ? '' : this.selectedSpecification.description,\r\n userId: copy ? this.userId : this.selectedSpecification.userId,\r\n visibility: copy ? Compliance.SpecificationVisibilityEnum.Private : this.selectedSpecification.visibility,\r\n visibilityItem: copy ? this.visibilityPrivate : this.selectedSpecification.visibilityItem,\r\n }\r\n } as AgGridLayoutSpecificationListItemModel;\r\n\r\n const params: AgGridLayoutSpecificationDetailsParams = {\r\n specification: specification,\r\n userId: this.userId,\r\n visibilities: this.visibilities,\r\n companyId: this.companyId\r\n };\r\n\r\n const result = await this._modalService.showAsync(AgGridLayoutSpecificationDetailsComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const spec = this._getListItem(result);\r\n\r\n if (copy) {\r\n this.specifications.push(spec);\r\n\r\n this.selectedSpecification = spec;\r\n this._agGridPersistenceService.setCurrentGridLayoutApplied(this._gridId as string, this.selectedSpecification.name);\r\n\r\n this.onSpecificationChanged();\r\n } else {\r\n Object.assign(this.selectedSpecification, spec);\r\n }\r\n\r\n this.specifications = this._sort(this.specifications);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async onSpecificationChanged(): Promise {\r\n this._applySpecification();\r\n this._agGridPersistenceService.setCurrentGridLayoutApplied(this._gridId as string, this.selectedSpecification.name);\r\n await this._gridLayoutSpecificationRepository.updateGridLayoutUserSetting(this._gridId, this.companyId, this.selectedSpecification.gridLayoutSpecificationId);\r\n }\r\n\r\n private async _load(): Promise {\r\n if (!(this._gridId && this.gridOptions && this.gridOptions.api && this.gridOptions.columnApi && this._gridId)) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.isBusy = true;\r\n\r\n try {\r\n this.userId = this._userService.getUser().id;\r\n\r\n const visibilities: AgGridLayoutSpecificationVisibilityModel[] = [];\r\n\r\n visibilities.push(this.visibilityPrivate);\r\n\r\n if (this.companyId) {\r\n visibilities.push(this.visibilityPrivateCompany);\r\n\r\n this.canEditCompany = await this._restrictService.hasCompanyPermission(this.companyId, Core.AccessRightsEnum.Write);\r\n if (this.canEditCompany) {\r\n visibilities.push(this.visibilityCompany);\r\n visibilities.push(this.visibilityCompanyDefault);\r\n }\r\n }\r\n\r\n this.canEditShared = this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT);\r\n if (this.canEditShared) {\r\n visibilities.push(this.visibilityShared);\r\n }\r\n\r\n this.visibilities = visibilities;\r\n\r\n const searchModel: Compliance.GridLayoutSpecificationSearchModel = {\r\n gridId: this._gridId,\r\n companyId: this.companyId\r\n };\r\n\r\n // default represents the built-in grid configuration\r\n const layoutModel: AgGridLayoutSpecificationModel = {\r\n column: this.gridOptions.columnApi.getColumnState(),\r\n filter: this.gridOptions.api.getFilterModel(),\r\n sort: this.gridOptions.api.getSortModel(),\r\n colorize: this.defaultColorizeHeaders,\r\n unResizedColumns: false\r\n };\r\n\r\n this._builtInSpecification = {\r\n gridLayoutSpecificationId: 0,\r\n companyId: this.companyId,\r\n gridId: this._gridId,\r\n layout: (layoutModel.column.length) ? JSON.stringify(layoutModel) : null,\r\n isDefault: true,\r\n visibility: Compliance.SpecificationVisibilityEnum.Private,\r\n visibilityItem: this.visibilityBuiltIn,\r\n name: 'Default',\r\n description: 'Built-in layout',\r\n canEdit: false\r\n };\r\n\r\n const specs = await lastValueFrom(this._gridLayoutSpecificationRepository.getList(searchModel));\r\n const specItems = specs.data.map((x: Compliance.GridLayoutSpecificationModel) => this._getListItem(x));\r\n\r\n specItems.splice(0, 0, this._builtInSpecification);\r\n\r\n // get the last used layout for the user\r\n const userLayoutId = await this._gridLayoutSpecificationRepository.getGridLayoutUserSetting(this._gridId, this.companyId);\r\n let selectedSpec: AgGridLayoutSpecificationListItemModel = null;\r\n if (userLayoutId) {\r\n selectedSpec = specItems.find(\r\n x => {\r\n return x.gridLayoutSpecificationId === userLayoutId;\r\n });\r\n }\r\n\r\n // if no last used layout, get the company default\r\n if ((!selectedSpec) && this.companyId) {\r\n selectedSpec = specItems.find(\r\n x => {\r\n return x.visibility === Compliance.SpecificationVisibilityEnum.Company &&\r\n x.isDefault &&\r\n x.companyId === this.companyId;\r\n });\r\n }\r\n\r\n // if nothing selected, select built in\r\n if (!selectedSpec) {\r\n selectedSpec = this._builtInSpecification;\r\n }\r\n\r\n this.specifications = this._sort(specItems);\r\n this.selectedSpecification = selectedSpec;\r\n this._agGridPersistenceService.setCurrentGridLayoutApplied(this._gridId as string, this.selectedSpecification.name);\r\n this._applySpecification();\r\n } finally {\r\n this.loadComplete.emit();\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n private _sort(list: AgGridLayoutSpecificationListItemModel[]): AgGridLayoutSpecificationListItemModel[] {\r\n const sorted = _.sortBy(list.filter(x => x !== this._builtInSpecification), x => x.name);\r\n sorted.splice(0, 0, this._builtInSpecification);\r\n return sorted;\r\n }\r\n\r\n private _getListItem(specificationModel: Compliance.GridLayoutSpecificationModel): AgGridLayoutSpecificationListItemModel {\r\n const spec: AgGridLayoutSpecificationListItemModel = {\r\n ...specificationModel,\r\n ...{\r\n visibilityItem: this.allVisibilities.find(x => x.visibility === specificationModel.visibility && x.isDefault === specificationModel.isDefault && (specificationModel.companyId ? x.isCompany : !x.isCompany)) || null,\r\n changed: false,\r\n canEdit: false\r\n }\r\n } as AgGridLayoutSpecificationListItemModel;\r\n\r\n if (!spec.visibilityItem) {\r\n console.warn('Did not find valid visibility item for spec.', spec);\r\n }\r\n\r\n switch (spec.visibility) {\r\n case Compliance.SpecificationVisibilityEnum.Private:\r\n spec.canEdit = specificationModel.userId === this.userId;\r\n break;\r\n case Compliance.SpecificationVisibilityEnum.Company:\r\n spec.canEdit = this.canEditCompany;\r\n break;\r\n case Compliance.SpecificationVisibilityEnum.Shared:\r\n spec.canEdit = this.canEditShared;\r\n break;\r\n }\r\n\r\n return spec;\r\n }\r\n\r\n private _applySpecification(): void {\r\n if (!(this.gridOptions && this.gridOptions.api && this.gridOptions.columnApi && this._builtInSpecification.layout)) {\r\n return;\r\n }\r\n\r\n const model = JSON.parse(this.selectedSpecification.layout) as AgGridLayoutSpecificationModel;\r\n\r\n if (model.column) {\r\n const colState = this.gridOptions.columnApi.getColumnState();\r\n\r\n // If a column was removed from the app, we need to remove it from the saved spec\r\n model.column = model.column.filter(x => colState.find(y => y.colId === x.colId));\r\n\r\n // Check if there are missing columns that were added after the spec was saved\r\n const missing = colState.reduce((acc, x, i) => {\r\n if (!model.column.find(y => y.colId === x.colId)){\r\n acc.push({col: x, index: i});\r\n }\r\n return acc;\r\n }, []);\r\n // Inject the missing columns into the spec\r\n missing.forEach(x => model.column.splice(x.index, 0, x.col));\r\n\r\n // Check to see if the column lock pinned value has changed since the last save\r\n _.flow([\r\n filter(x => {\r\n const colDef = x.getColDef();\r\n return colDef.lockPinned && colDef.pinned === 'left';\r\n }),\r\n forEach(x => {\r\n const col = model.column.find(y => x.getColId() === y.colId);\r\n if (col && !col.pinned) {\r\n col.pinned = 'left';\r\n }\r\n })\r\n ])(this.gridOptions.columnApi.getAllColumns());\r\n\r\n this.gridOptions.columnApi.setColumnState(model.column);\r\n }\r\n\r\n if (model.filter && !_.isEmpty(model.filter)) {\r\n model.filter = _.omitBy(model.filter, x => !x.filterValues);\r\n this.gridOptions.api.setFilterModel(model.filter);\r\n } else {\r\n this.gridOptions.api.setFilterModel(null);\r\n if (this.gridOptions.api.appliedFilter) {\r\n delete this.gridOptions.api.appliedFilter;\r\n }\r\n }\r\n\r\n if (model.sort && model.sort.length) {\r\n this.gridOptions.api.setSortModel(model.sort);\r\n } else {\r\n const defaultSort = this._builtInSpecification && this._builtInSpecification.layout\r\n ? JSON.parse(this._builtInSpecification.layout).sort : null;\r\n this.gridOptions.api.setSortModel(defaultSort);\r\n }\r\n\r\n this.gridOptions.api.redrawRows();\r\n\r\n this.specificationChanged.emit(model);\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const AG_GRID_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'ag-grid.sort',\r\n tooltipText: 'Sort'\r\n },\r\n {\r\n helpContentId: 'ag-grid.layout-filter-toggle',\r\n tooltipText: 'Filter and group the column list'\r\n },\r\n {\r\n helpContentId: 'ag-grid.group-by-category',\r\n tooltipText: 'Display the columns by category'\r\n },\r\n {\r\n helpContentId: 'ag-grid.no-categories',\r\n tooltipText: 'There are no categories for this table'\r\n },\r\n {\r\n helpContentId: 'ag-grid.show-category-headers',\r\n tooltipText: 'Show category headers on the table'\r\n },\r\n {\r\n helpContentId: 'ag-grid.filter-applied',\r\n tooltipText: 'With a filter, sort, or grouping applied, the order of the columns in the list will no longer reflect the order they appear in the table'\r\n },\r\n {\r\n helpContentId: 'ag-grid.applyFilter',\r\n tooltipText: 'Apply filter'\r\n },\r\n {\r\n helpContentId: 'ag-grid.clearFilterHelpContentId',\r\n tooltipText: 'Clear filter'\r\n },\r\n {\r\n helpContentId: 'ag-grid.clearField',\r\n tooltipText: 'Clear the field'\r\n },\r\n {\r\n helpContentId: 'ag-grid.addFilter',\r\n tooltipText: 'Add another filter value'\r\n },\r\n {\r\n helpContentId: 'ag-grid.removeFilter',\r\n tooltipText: 'Remove filter value'\r\n }\r\n];\r\n","import { Component, forwardRef } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\n\r\n/**\r\n * Tri-state checkbox (checked, unchecked, indeterminate)\r\n *\r\n * Tied into ControlValueAccessor for integration with native Angular FormControls and ngModel\r\n *\r\n * Input state:\r\n * true - checked\r\n * false - unchecked\r\n * null - indeterminate\r\n *\r\n * Example usage:\r\n * \r\n *\r\n */\r\n@Component({\r\n selector: 'ws-tri-state-checkbox',\r\n templateUrl: './triStateCheckbox.component.html',\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => TriStateCheckboxComponent),\r\n multi: true\r\n }\r\n ],\r\n})\r\nexport class TriStateCheckboxComponent implements ControlValueAccessor {\r\n\r\n value: boolean;\r\n\r\n disabled: boolean;\r\n\r\n writeValue(value: boolean) {\r\n this.value = value;\r\n }\r\n\r\n setDisabledState(disabled: boolean) {\r\n this.disabled = disabled;\r\n }\r\n\r\n next() {\r\n this.onChange(this.value = !this.value);\r\n this.onTouched();\r\n }\r\n\r\n registerOnChange(fn: any) {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any) {\r\n this.onTouched = fn;\r\n }\r\n\r\n private onChange: (val: boolean) => void = (val) => { return null; };\r\n private onTouched: () => void = () => { return null; };\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n
Columns \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","\r\n","import { Component, Input, OnInit, OnDestroy } from '@angular/core';\r\nimport { AgGridColumnModel, AgGridLayoutSpecificationModel } from '../models';\r\nimport { GridOptions, Column } from 'ag-grid-community';\r\nimport { Subject } from 'rxjs';\r\nimport { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms';\r\nimport { debounceTime, distinctUntilChanged, take, takeUntil } from 'rxjs/operators';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { AG_GRID_HELP } from '../../agGrid.help';\r\nimport { AgGridPersistenceService } from '../../agGridPersistence.service';\r\n\r\nimport { filter, forEach } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\n\r\nexport enum SortDirection {\r\n None,\r\n Ascending,\r\n Descending\r\n}\r\n\r\ninterface ColumnNode {\r\n groupName: string;\r\n columns: AgGridColumnModel[];\r\n isVisible: boolean;\r\n groups?: ColumnNode[];\r\n headerColor?: string;\r\n isCollapsed?: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'ag-grid-tool-panel-columns',\r\n templateUrl: './agGridToolPanelColumns.component.html',\r\n styleUrls: ['./agGridToolPanelColumns.component.scss']\r\n})\r\nexport class AgGridToolPanelColumnsComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _fb: UntypedFormBuilder,\r\n private readonly _helpService: HelpService,\r\n private readonly _agGridPersistenceService: AgGridPersistenceService\r\n ) { }\r\n\r\n @Input() gridId: string | System.Guid;\r\n @Input() displayedColumnsChanged$: Subject;\r\n @Input() defaultColorizeHeaders: boolean;\r\n\r\n @Input()\r\n set gridOptions(gridOptions: GridOptions) {\r\n this._gridOptions = gridOptions;\r\n this._refreshColumns();\r\n }\r\n\r\n @Input()\r\n set specification(specification: AgGridLayoutSpecificationModel) {\r\n if (specification) {\r\n this._specification = specification;\r\n this._refreshColumns(true);\r\n }\r\n }\r\n\r\n columnSettings: UntypedFormGroup;\r\n\r\n columns: ColumnNode;\r\n sortDirection = SortDirection;\r\n selectedSort: SortDirection = SortDirection.None;\r\n showSettings: boolean;\r\n showGrouped: boolean;\r\n hasFilterApplied: boolean;\r\n hasGroupings: boolean;\r\n hasColumnChanges: boolean;\r\n canUserPin: boolean;\r\n\r\n private _gridOptions: GridOptions & { api?: {appliedFilter?: any}};\r\n private _specification: AgGridLayoutSpecificationModel;\r\n private _columns: AgGridColumnModel[] = [];\r\n private _initialColumns: AgGridColumnModel[] = [];\r\n private _filterValue: string = '';\r\n private _columnsInitialized: boolean;\r\n private _destroy$: Subject = new Subject;\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(AG_GRID_HELP);\r\n\r\n this.columnSettings = this._fb.group({\r\n groupBy: [false],\r\n showHeaders: [this.defaultColorizeHeaders],\r\n filter: ['']\r\n });\r\n\r\n // Disable colors for tables that have group headers\r\n const colGroupNames = this._gridOptions.columnApi.getColumnGroupState().map(x => x.groupId);\r\n const colGroups = colGroupNames.map(x => this._gridOptions.columnApi.getColumnGroup(x)).filter(x => x);\r\n if (colGroups.length) {\r\n this.columnSettings.get('showHeaders').disable();\r\n }\r\n\r\n this.columnSettings.get('groupBy').valueChanges\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe((grouped: boolean) => {\r\n this.showGrouped = grouped;\r\n this.hasFilterApplied = !!this._filterValue || this.selectedSort !== SortDirection.None || this.showGrouped;\r\n });\r\n\r\n this.columnSettings.get('filter').valueChanges\r\n .pipe(takeUntil(this._destroy$), debounceTime(200), distinctUntilChanged())\r\n .subscribe(x => {\r\n this._filterValue = x;\r\n this.columns = this._applySettings();\r\n });\r\n\r\n this.columnSettings.get('showHeaders').valueChanges\r\n .pipe(takeUntil(this._destroy$), distinctUntilChanged())\r\n .subscribe(show => {\r\n this._showGroupedHeaders(show);\r\n });\r\n\r\n this.displayedColumnsChanged$\r\n .pipe(takeUntil(this._destroy$), debounceTime(200))\r\n .subscribe(x => this._refreshColumns());\r\n\r\n // Initialize the colors when columns are first set\r\n this.displayedColumnsChanged$\r\n .pipe(takeUntil(this._destroy$), take(1))\r\n .subscribe(x => this._showGroupedHeaders(this.columnSettings.get('showHeaders').value));\r\n\r\n this._applySettings();\r\n this._showGroupedHeaders(this.defaultColorizeHeaders);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n toggleIsVisible(isVisible: boolean, column: AgGridColumnModel): void {\r\n if (!column.canChangeIsVisible) { return; }\r\n\r\n column.isVisible = isVisible;\r\n this._gridOptions.columnApi.setColumnVisible(column.id, column.isVisible);\r\n this.hasColumnChanges = true;\r\n\r\n if (!column.isVisible) {\r\n const filterInstance = this._gridOptions.api.getFilterInstance(column.id);\r\n\r\n if (filterInstance && filterInstance.isFilterActive()) {\r\n filterInstance.setModel(null);\r\n delete this._gridOptions.api.appliedFilter[column.id];\r\n this._gridOptions.api.onFilterChanged();\r\n }\r\n }\r\n }\r\n\r\n setColumnPinned(isPinned: boolean, column: AgGridColumnModel): void {\r\n if (!column.canChangeIsPinned) { return; }\r\n\r\n column.isPinned = isPinned;\r\n const pinned = (column.isPinned) ? 'left' : '';\r\n\r\n this._gridOptions.columnApi.setColumnPinned(column.id, pinned);\r\n this.hasColumnChanges = true;\r\n }\r\n\r\n trackByColumnId(column) {\r\n return column.id;\r\n }\r\n\r\n trackByGroupName(column) {\r\n return column.groupName;\r\n }\r\n\r\n toggleSort(currentSort: SortDirection): void {\r\n switch (currentSort) {\r\n case SortDirection.None:\r\n this.selectedSort = SortDirection.Ascending;\r\n break;\r\n case SortDirection.Ascending:\r\n this.selectedSort = SortDirection.Descending;\r\n break;\r\n case SortDirection.Descending:\r\n this.selectedSort = SortDirection.None;\r\n break;\r\n }\r\n this.columns = this._applySettings();\r\n }\r\n\r\n toggleSettings(): void {\r\n this.showSettings = !this.showSettings;\r\n }\r\n\r\n toggleGroup(isVisible: boolean, group: ColumnNode): void {\r\n const columnIds = group.columns.reduce((acc, x) => {\r\n if (x.canChangeIsVisible) {\r\n acc.push(x.id);\r\n }\r\n return acc;\r\n }, []);\r\n\r\n this._gridOptions.columnApi.setColumnsVisible(columnIds, isVisible);\r\n group.isVisible = isVisible;\r\n this.hasColumnChanges = true;\r\n\r\n // If columns with filters are being hidden, reset their filter\r\n if (!isVisible) {\r\n let filterChanged = false;\r\n group.columns.forEach(x => {\r\n const filterInstance = this._gridOptions.api.getFilterInstance(x.id);\r\n\r\n if (filterInstance && filterInstance.isFilterActive()) {\r\n filterInstance.setModel(null);\r\n if (this._gridOptions.api.appliedFilter[x.id]) {\r\n delete this._gridOptions.api.appliedFilter[x.id];\r\n }\r\n filterChanged = true;\r\n }\r\n });\r\n if (filterChanged) {\r\n this._gridOptions.api.onFilterChanged();\r\n }\r\n }\r\n }\r\n\r\n toggleGroupLevelCollapse(group: ColumnNode): void {\r\n group.isCollapsed = !group.isCollapsed;\r\n }\r\n\r\n undoChanges(): void {\r\n this._columns = this._initialColumns.map(x => ({ ...x }));\r\n this._columns.forEach(x => {\r\n this.toggleIsVisible(x.isVisible, x);\r\n this.setColumnPinned(x.isPinned, x);\r\n });\r\n this.columns = this._applySettings();\r\n this.hasColumnChanges = false;\r\n }\r\n\r\n private _applySettings(): ColumnNode {\r\n this.hasFilterApplied = !!this._filterValue || this.selectedSort !== SortDirection.None || this.showGrouped;\r\n if (this.columnSettings) {\r\n if (this.hasGroupings) {\r\n this.columnSettings.get('groupBy').enable();\r\n this.columnSettings.get('showHeaders').enable();\r\n } else {\r\n this.columnSettings.get('groupBy').disable();\r\n this.columnSettings.get('showHeaders').disable();\r\n }\r\n }\r\n\r\n const filtered = this._filter([...this._columns]);\r\n const sorted = this._sort(filtered);\r\n const columns = {\r\n groupName: null,\r\n columns: sorted,\r\n groups: [],\r\n isVisible: this._groupColumnsState(sorted)\r\n };\r\n return (this.hasGroupings) ? this._group(columns) : columns;\r\n }\r\n\r\n private _refreshColumns(fromSpecificationChange: boolean = false): void {\r\n if (!(this._gridOptions && this._gridOptions.columnApi && this._gridOptions.columnApi.getAllColumns())) {\r\n return;\r\n }\r\n\r\n this._columns = [];\r\n if (!this._columnsInitialized || fromSpecificationChange) {\r\n this._initialColumns = [];\r\n }\r\n this.hasGroupings = false;\r\n this.canUserPin = false;\r\n\r\n const gridColumns = this._gridOptions.columnApi.getAllColumns();\r\n\r\n // get column state (so that we can process them in order)\r\n const columnState = this._gridOptions.columnApi.getColumnState();\r\n\r\n _.flow([\r\n filter(x => {\r\n const gridColumn: Column = gridColumns.find(y => y.getColId() === x.colId);\r\n\r\n // column must not be suppressed and have a header\r\n return (gridColumn && !gridColumn.getColDef().suppressToolPanel) && (!gridColumn.getColDef().suppressColumnsToolPanel) && gridColumn.getColDef().headerName;\r\n }),\r\n forEach(x => {\r\n const gridColumn: Column = gridColumns.find(y => y.getColId() === x.colId);\r\n const colDef = gridColumn.getColDef();\r\n const column: () => AgGridColumnModel = () => {\r\n const isVisible = gridColumn.isVisible();\r\n if (!this.canUserPin && !colDef.lockPinned) {\r\n this.canUserPin = true;\r\n }\r\n return {\r\n id: x.colId,\r\n name: colDef.headerName,\r\n isVisible,\r\n canChangeIsVisible: !colDef.lockVisible,\r\n isPinned: !!x.pinned,\r\n pinned: x.pinned,\r\n canChangeIsPinned: !colDef.lockPinned,\r\n groupName: colDef.toolPanelClass\r\n };\r\n };\r\n\r\n if (colDef.lockVisible) {\r\n this._columns.unshift(column());\r\n } else {\r\n this._columns.push(column());\r\n }\r\n\r\n if (!this._columnsInitialized || fromSpecificationChange) {\r\n this._initialColumns.push(column());\r\n }\r\n\r\n if (colDef.toolPanelClass && !this.hasGroupings) {\r\n this.hasGroupings = true;\r\n }\r\n })\r\n ])(columnState);\r\n\r\n this.columns = this._applySettings();\r\n\r\n if (!this._columnsInitialized || fromSpecificationChange) {\r\n this.hasColumnChanges = false;\r\n }\r\n this._columnsInitialized = !!this._initialColumns.length;\r\n\r\n if (fromSpecificationChange && this._specification) {\r\n this.columnSettings.patchValue({ showHeaders: this._specification.colorize });\r\n }\r\n }\r\n\r\n private _group(node: ColumnNode): ColumnNode {\r\n const grouped = node.columns.reduce((acc, x) => {\r\n if (!x.groupName) { x.groupName = 'General'; }\r\n if (!acc[x.groupName]) {\r\n acc[x.groupName] = [];\r\n }\r\n acc[x.groupName].push(x);\r\n return acc;\r\n }, {});\r\n node.groups = Object.keys(grouped)\r\n .sort()\r\n .map(x => {\r\n return {\r\n groupName: x,\r\n columns: grouped[x],\r\n headerColor: this._agGridPersistenceService.getColorClassForGroupType(x),\r\n isCollapsed: false,\r\n isVisible: this._groupColumnsState(grouped[x])\r\n };\r\n });\r\n return node;\r\n }\r\n\r\n private _filter(columns: AgGridColumnModel[]): AgGridColumnModel[] {\r\n return (this._filterValue) ? columns.filter(x => x.name.toLowerCase().includes(this._filterValue.toLowerCase())) : columns;\r\n }\r\n\r\n private _sort(columns: AgGridColumnModel[]): AgGridColumnModel[] {\r\n switch (this.selectedSort) {\r\n case SortDirection.Ascending:\r\n columns.sort((a, b) => a.name.localeCompare(b.name));\r\n break;\r\n case SortDirection.Descending:\r\n columns.sort((a, b) => b.name.localeCompare(a.name));\r\n break;\r\n }\r\n return columns;\r\n }\r\n\r\n private _groupColumnsState(columns: AgGridColumnModel[]): boolean {\r\n if (columns.every(x => x.isVisible)) {\r\n return true;\r\n } else if (columns.some(x => x.isVisible)) {\r\n return null;\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n private _showGroupedHeaders(show: boolean): void {\r\n const columnState = this._gridOptions.columnApi.getColumnState();\r\n const colDefs = columnState.map(x => this._gridOptions.columnApi.getColumn(x.colId).getColDef());\r\n colDefs.forEach(x => x.headerClass = (show) ? this._agGridPersistenceService.getColorClassForGroupType(x.toolPanelClass as string) : '');\r\n this._gridOptions.columnApi.setColumnState(this._gridOptions.columnApi.getColumnState());\r\n this._agGridPersistenceService.toggleHeaderGroupColor(this.gridId as string, show);\r\n }\r\n}\r\n","
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
    \r\n
  • Excel
  • \r\n
  • Tab Delimited
  • \r\n
  • PDF
  • \r\n
  • {{t.name}}
  • \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
    \r\n
  • {{action.name}}
  • \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
    \r\n
  • \r\n {{action.name}}\r\n
  • \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { GridOptions } from 'ag-grid-community';\r\nimport { BehaviorSubject, lastValueFrom, Subject } from 'rxjs';\r\nimport { BusyIndicatorRef, BusyIndicatorService, IBusyIndicatorConfig, SnackBarService } from '../../../Busy-Indicator';\r\nimport { LongRunningProcessRepository } from '../../Repositories';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport {\r\n AgGridExportOptions,\r\n AgGridLayoutSpecificationModel,\r\n AgGridToolPanelAction,\r\n AgGridToolPanelButton\r\n} from './models';\r\nimport { AG_GRID_TOOL_PANEL_HELP } from './agGridToolPanel.component.help';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport ExportFileFormatEnum = Compliance.ExportFileFormatEnum;\r\n\r\nexport class BulkEditButtonOptions {\r\n constructor(\r\n public show: boolean,\r\n public showLoading: boolean,\r\n public disable: boolean,\r\n public toolTipId: string = 'ag-grid-tool-panel.bulk-delete') {\r\n }\r\n\r\n static Create( o: Partial): BulkEditButtonOptions\r\n {\r\n if (!o){\r\n return new BulkEditButtonOptions(false, false, false);\r\n }\r\n return new BulkEditButtonOptions(\r\n o.show || false,\r\n o.showLoading || false,\r\n o.disable || false,\r\n o.toolTipId || 'ag-grid-tool-panel.bulk-delete'\r\n );\r\n }\r\n}\r\n\r\n@Component({\r\n selector: 'ag-grid-tool-panel',\r\n templateUrl: './agGridToolPanel.component.html',\r\n styleUrls: ['./agGridToolPanel.component.scss']\r\n})\r\nexport class AgGridToolPanelComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _longRunningProcessRepository: LongRunningProcessRepository,\r\n private readonly _snackBarService: SnackBarService,\r\n private readonly _helpService: HelpService) { }\r\n\r\n @Input() companyId: number;\r\n @Input() gridId: string | System.Guid;\r\n @Input() gridOptions: GridOptions & { api?: {appliedFilter?: any}};\r\n @Input() isBulkUpdateVisible$: BehaviorSubject;\r\n @Input() isBulkDeleteVisible$: BehaviorSubject;\r\n @Input() isCustomButtonVisible$: BehaviorSubject;\r\n @Input() exportOptions: AgGridExportOptions;\r\n @Input() showConfigureLayout: boolean = true;\r\n @Input() showResizeColumns: boolean = true;\r\n @Input() defaultSizeToFit: boolean = true;\r\n @Input() defaultSizeToContent: boolean = false;\r\n @Input() defaultColorizeHeaders: boolean = false;\r\n @Input() gridReady: boolean = false;\r\n @Input() exportIcon: string = 'fa-file-excel-o';\r\n @Input() exportHelpContentId: string = 'ag-grid-tool-panel.export';\r\n @Input() additionalActions: AgGridToolPanelAction[];\r\n @Input() additionalButtons: AgGridToolPanelButton[];\r\n\r\n @Output() bulkUpdate = new EventEmitter();\r\n @Output() bulkDelete = new EventEmitter();\r\n @Output() customButtonClick = new EventEmitter();\r\n @Output() toolPanelReady = new EventEmitter();\r\n @Output() filtersEnabled = new EventEmitter();\r\n @Output() sizeColumnsToFit = new EventEmitter();\r\n @Output() sizeColumnsToContent = new EventEmitter();\r\n @Output() layoutSpecificationChanged = new EventEmitter();\r\n\r\n showExport: boolean = false;\r\n showBulkUpdate: boolean = false;\r\n showBulkUpdateLoading: boolean = false;\r\n disableBulkUpdate: boolean = false;\r\n bulkUpdateButtonHelpId: string;\r\n\r\n showBulkDelete: boolean = false;\r\n showFileFormatSelection: boolean = false;\r\n showAdditionalActions: boolean = false;\r\n showCustom: boolean = false;\r\n isExpanded: boolean = false;\r\n isInitialized: boolean = false;\r\n\r\n fileFormats = {\r\n excel: Compliance.ExportFileFormatEnum.Excel,\r\n tabDelimited: Compliance.ExportFileFormatEnum.TabDelimited,\r\n pdf: Compliance.ExportFileFormatEnum.PDF\r\n };\r\n displayedColumnsChanged$: Subject = new Subject();\r\n specification: AgGridLayoutSpecificationModel;\r\n\r\n private _busyRef: BusyIndicatorRef;\r\n private _busyRefId = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n private _longRunningProcessId: number;\r\n private _destroy$: Subject = new Subject();\r\n private _processDestroy$: Subject = new Subject();\r\n\r\n private readonly defaultBulkUpdateButtonHelpId = 'ag-grid-tool-panel.bulk-update';\r\n\r\n get configureLayoutHelpContentId(): string {\r\n return this.isExpanded ?\r\n 'ag-grid-tool-panel.hide-configure' :\r\n 'ag-grid-tool-panel.show-configure';\r\n }\r\n\r\n get filtersHelpContentId(): string {\r\n return this.isFilterVisible ?\r\n 'ag-grid-tool-panel.hide-filters' :\r\n 'ag-grid-tool-panel.show-filters';\r\n }\r\n\r\n get isFilterVisible(): boolean {\r\n return this.gridOptions && this.gridOptions.floatingFilter;\r\n }\r\n\r\n get isFiltered(): boolean {\r\n return this.gridOptions && this.gridOptions.api && this.gridOptions.api.isAnyFilterPresent();\r\n }\r\n\r\n get disableExport(): boolean {\r\n let disabled = this.exportOptions?.disabled;\r\n if (this.exportOptions?.getDisabled) {\r\n disabled = this.exportOptions.getDisabled();\r\n }\r\n return disabled;\r\n }\r\n\r\n get additionalActionsVisible(): boolean {\r\n return this.additionalActions.some(x => !x.disabled());\r\n }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(AG_GRID_TOOL_PANEL_HELP);\r\n this.bulkUpdateButtonHelpId = this.defaultBulkUpdateButtonHelpId;\r\n\r\n this.gridOptions.onGridReady = () => this.isInitialized = true;\r\n\r\n this.gridOptions.onFirstDataRendered = () => {\r\n if (this.defaultSizeToFit) {\r\n this.sizeToFit();\r\n }\r\n\r\n if (this.defaultSizeToContent) {\r\n this.sizeToContent();\r\n }\r\n };\r\n\r\n this.gridOptions.onDisplayedColumnsChanged = () => {\r\n this.displayedColumnsChanged$.next();\r\n };\r\n\r\n this.showExport = !!this.exportOptions;\r\n\r\n if (this.isBulkUpdateVisible$) {\r\n this.isBulkUpdateVisible$.pipe(takeUntil(this._destroy$)).subscribe(x => {\r\n if (x instanceof(BulkEditButtonOptions))\r\n {\r\n this.showBulkUpdateLoading = x.showLoading;\r\n this.showBulkUpdate = x.show || x.showLoading;\r\n this.disableBulkUpdate = x.disable;\r\n this.bulkUpdateButtonHelpId = x.toolTipId;\r\n }\r\n else {\r\n this.showBulkUpdate = this.bulkUpdate.observers.length > 0 && x;\r\n this.showBulkUpdateLoading = false;\r\n this.disableBulkUpdate = false;\r\n this.bulkUpdateButtonHelpId = this.defaultBulkUpdateButtonHelpId;\r\n }\r\n });\r\n }\r\n\r\n if (this.isBulkDeleteVisible$) {\r\n this.isBulkDeleteVisible$.pipe(takeUntil(this._destroy$)).subscribe(x => {\r\n this.showBulkDelete = this.bulkDelete.observers.length > 0 && x;\r\n });\r\n }\r\n\r\n if (this.isCustomButtonVisible$) {\r\n this.isCustomButtonVisible$.pipe(takeUntil(this._destroy$)).subscribe(x => {\r\n this.showCustom = this.customButtonClick.observers.length > 0 && x;\r\n });\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._processDestroy$.next();\r\n this._processDestroy$.complete();\r\n }\r\n\r\n onExpandClick(): void {\r\n this.isExpanded = !this.isExpanded;\r\n }\r\n\r\n onFilterClick(): void {\r\n if (!(this.gridOptions && this.gridOptions.api)) {\r\n return;\r\n }\r\n\r\n this.gridOptions.floatingFilter = !this.gridOptions.floatingFilter;\r\n this.gridOptions.api.refreshHeader();\r\n\r\n // clear filter when hiding\r\n if (!this.gridOptions.floatingFilter && this.isFiltered) {\r\n this.gridOptions.api.setFilterModel(null);\r\n this.gridOptions.api.appliedFilter = null;\r\n this.gridOptions.api.onFilterChanged();\r\n }\r\n\r\n this.filtersEnabled.emit(this.gridOptions.floatingFilter);\r\n }\r\n\r\n onClearFiltersClick(): void {\r\n if (!(this.gridOptions && this.gridOptions.api)) {\r\n return;\r\n }\r\n\r\n this.gridOptions.api.setFilterModel(null);\r\n this.gridOptions.api.appliedFilter = null;\r\n this.gridOptions.api.setSortModel(null);\r\n this.gridOptions.api.onFilterChanged();\r\n }\r\n\r\n sizeToFit(): void {\r\n if (!(this.gridOptions && this.gridOptions.api)) {\r\n return;\r\n }\r\n\r\n this.gridOptions.api.sizeColumnsToFit();\r\n this.sizeColumnsToFit.emit();\r\n }\r\n\r\n sizeToContent(): void {\r\n if (!(this.gridOptions && this.gridOptions.api && this.gridOptions.columnApi)) {\r\n return;\r\n }\r\n\r\n this.gridOptions.columnApi.autoSizeAllColumns();\r\n this.sizeColumnsToContent.emit();\r\n }\r\n\r\n onExportClick(): void {\r\n if (this.disableExport || !(this.gridOptions && this.gridOptions.columnApi)) {\r\n return;\r\n }\r\n\r\n if (this.exportOptions.showFileFormatSelection) {\r\n this.showFileFormatSelection = !this.showFileFormatSelection;\r\n } else {\r\n this._exportFile(Compliance.ExportFileFormatEnum.Excel);\r\n }\r\n }\r\n\r\n onExportOptionSelected(type: Compliance.ExportFileFormatEnum): void {\r\n this.showFileFormatSelection = false;\r\n this._exportFile(type);\r\n }\r\n\r\n onCustomExportOptionSelected(value: number): void {\r\n this.showFileFormatSelection = false;\r\n this._exportFile(ExportFileFormatEnum.Excel, value);\r\n }\r\n\r\n hideFileFormatSelection(): void {\r\n this.showFileFormatSelection = false;\r\n }\r\n\r\n onAdditionalActionClick(): void {\r\n this.showAdditionalActions = true;\r\n }\r\n\r\n hideAdditionalActions(): void {\r\n this.showAdditionalActions = false;\r\n }\r\n\r\n onAdditionalActionSelected(action: AgGridToolPanelAction): void {\r\n if (!action.disabled()) {\r\n action.onClickCallback();\r\n this.hideAdditionalActions();\r\n }\r\n }\r\n\r\n onBulkUpdateClick() {\r\n this.bulkUpdate.emit(null);\r\n }\r\n\r\n onBulkDeleteClick() {\r\n this.bulkDelete.emit(null);\r\n }\r\n\r\n specificationLoadComplete(): void {\r\n this.toolPanelReady.emit();\r\n }\r\n\r\n specificationChanged(specification: AgGridLayoutSpecificationModel): void {\r\n this.specification = specification;\r\n\r\n // Show filter floating filters if the selected specification has applied filters\r\n if (Object.keys(specification.filter).length) {\r\n this.gridOptions.floatingFilter = true;\r\n this.gridOptions.api.refreshHeader();\r\n }\r\n\r\n this.layoutSpecificationChanged.emit(this.specification);\r\n }\r\n\r\n showFileFormat(fileFormat: Compliance.ExportFileFormatEnum) {\r\n return (!this.exportOptions || !this.exportOptions.availableFileFormats) && fileFormat !== Compliance.ExportFileFormatEnum.PDF ||\r\n this.exportOptions && this.exportOptions.availableFileFormats && this.exportOptions.availableFileFormats.indexOf(fileFormat) >= 0;\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...'): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this._busyRefId);\r\n return;\r\n }\r\n\r\n const config: IBusyIndicatorConfig = {\r\n identifier: this._busyRefId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: true\r\n };\r\n\r\n if (this.exportOptions.canCancel) {\r\n config.hasAction = true;\r\n config.actionMessage = 'Cancel';\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show(config);\r\n\r\n this._busyRef.onAction().pipe(takeUntil(this._processDestroy$)).subscribe(async () => {\r\n this._showBusyIndicator(title, 'Attempting to cancel export');\r\n await lastValueFrom(this._longRunningProcessRepository.cancel(this._longRunningProcessId));\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._processDestroy$)).subscribe(() => this._hideBusyIndicator());\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._processDestroy$.next();\r\n }\r\n\r\n private async _exportFile(exportType: Compliance.ExportFileFormatEnum, customExportOption?: number): Promise {\r\n if (!(this.gridOptions && this.gridOptions.columnApi)) {\r\n return;\r\n }\r\n\r\n if (this.exportOptions.start) { // server-side\r\n const columnsToReturn: Compliance.NameValuePair[] = [];\r\n const displayedColumns = this.gridOptions.columnApi.getAllDisplayedColumns();\r\n\r\n displayedColumns.forEach(item => {\r\n // Don't add if headerName is empty.\r\n if (item.getColDef().headerName && item.getColDef().headerName.trim()) {\r\n columnsToReturn.push({ name: item.getColDef().field || item.getColDef().colId, value: item.getColDef().headerName });\r\n }\r\n });\r\n\r\n const lrp = await this.exportOptions.start(columnsToReturn, exportType, customExportOption);\r\n this._snackBarService.addById(lrp.longRunningProcessId, lrp.longRunningProcessTypeId);\r\n }\r\n\r\n if (this.exportOptions.clientSideExport) {\r\n const params = this.exportOptions.clientSideExport();\r\n this.gridOptions.api.exportDataAsCsv(params);\r\n }\r\n\r\n if (this.exportOptions.onExportClick) {\r\n this.exportOptions.onExportClick();\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport {\r\n AgGridEvent,\r\n BodyScrollEvent,\r\n CellClickedEvent,\r\n ColumnResizedEvent,\r\n FilterChangedEvent,\r\n GridOptions,\r\n GridReadyEvent,\r\n SortChangedEvent\r\n} from 'ag-grid-community';\r\nimport { BehaviorSubject } from 'rxjs';\r\nimport {\r\n AgGridExportOptions,\r\n AgGridLayoutSpecificationModel,\r\n AgGridToolPanelAction,\r\n AgGridToolPanelButton\r\n} from '../ToolPanel/models';\r\nimport { BulkEditButtonOptions } from '../ToolPanel/agGridToolPanel.component';\r\n\r\n@Component({\r\n selector: 'ws-ag-grid-angular',\r\n templateUrl: './wsAgGridWrapper.component.html',\r\n styles: [\r\n ':host { height: 100%; width: 100%; overflow: auto }'\r\n ]\r\n})\r\nexport class WsAgGridWrapperComponent implements OnInit {\r\n\r\n // Ag-Grid\r\n @Input() gridOptions: GridOptions;\r\n @Input() rowSelection: string;\r\n @Input() gridClass: string;\r\n @Input() wrapperClass: string;\r\n @Input() pinnedTopRowData: any[];\r\n\r\n // Tool panel\r\n @Input() companyId: number;\r\n @Input() gridId: string | System.Guid;\r\n @Input() isBulkUpdateVisible$: BehaviorSubject;\r\n @Input() isBulkDeleteVisible$: BehaviorSubject;\r\n @Input() isCustomButtonVisible$: BehaviorSubject;\r\n @Input() exportOptions: AgGridExportOptions;\r\n @Input() showConfigureLayout: boolean = true;\r\n @Input() showResizeColumns: boolean = true;\r\n @Input() defaultSizeToFit: boolean = true;\r\n @Input() defaultSizeToContent: boolean = false;\r\n @Input() defaultColorizeHeaders: boolean = false;\r\n @Input() exportIcon: string = 'fa-file-excel-o';\r\n @Input() exportHelpContentId: string = 'ag-grid-tool-panel.export';\r\n @Input() additionalActions: AgGridToolPanelAction[];\r\n @Input() additionalButtons: AgGridToolPanelButton[];\r\n @Input() forceShowToolPanel: boolean = false;\r\n @Input() overlayNoRowsTemplate: string;\r\n\r\n // Ag-Grid outputs\r\n @Output() gridReady: EventEmitter = new EventEmitter();\r\n @Output() filterChanged: EventEmitter = new EventEmitter();\r\n @Output() selectionChanged: EventEmitter = new EventEmitter();\r\n @Output() cellClicked: EventEmitter = new EventEmitter();\r\n @Output() columnResized: EventEmitter = new EventEmitter();\r\n @Output() bodyScroll: EventEmitter = new EventEmitter();\r\n @Output() sortChanged: EventEmitter = new EventEmitter();\r\n\r\n // Tool panel outputs\r\n @Output() bulkUpdate: EventEmitter = new EventEmitter();\r\n @Output() bulkDelete: EventEmitter = new EventEmitter();\r\n @Output() customButtonClick: EventEmitter = new EventEmitter();\r\n @Output() filtersEnabled = new EventEmitter();\r\n @Output() sizeColumnsToFit = new EventEmitter();\r\n @Output() sizeColumnsToContent = new EventEmitter();\r\n @Output() layoutChanged = new EventEmitter();\r\n\r\n agGridReady: boolean;\r\n hasToolbar: boolean;\r\n\r\n private _gridReadyEvent: GridReadyEvent;\r\n\r\n ngOnInit(): void {\r\n this.hasToolbar = !!(this.companyId || this.gridId || this.forceShowToolPanel);\r\n }\r\n\r\n toolPanelReady(): void {\r\n this.gridReady.emit(this._gridReadyEvent);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridReadyEvent = event;\r\n if (this.hasToolbar) {\r\n this.agGridReady = true;\r\n if (!this.showConfigureLayout) {\r\n this.toolPanelReady();\r\n }\r\n return;\r\n }\r\n this.gridReady.emit(this._gridReadyEvent);\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AgGridColumns, AgGridOptionsBuilder } from '../../../Compliance/AgGrid';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams, AgGridMultiSelectTracker\r\n} from '../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport {\r\n ParcelTypeCellRendererComponent,\r\n ParcelTypeCellRendererComponentParams\r\n} from '../../../Entity/Parcel/Parcel-Type-Cell-Renderer/parcelTypeCellRenderer.component';\r\nimport { UpgradeNavigationServiceHandler } from '../../Routing/upgrade-navigation-handler.service';\r\nimport {\r\n ActivityStatusCellRendererComponent\r\n} from './Activity-Status-Cell-Renderer/activityStatusCellRenderer.component';\r\n\r\ninterface ParcelFilterModalComponentParams {\r\n parcels: any[];\r\n selectedParcels: number[];\r\n}\r\n\r\n@Component({\r\n selector: 'parcel-filter-modal',\r\n templateUrl: './parcelFilterModal.component.html'\r\n})\r\nexport class ParcelFilterModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _navigationService: UpgradeNavigationServiceHandler) {\r\n }\r\n\r\n params: ParcelFilterModalComponentParams;\r\n result: number[] = [];\r\n\r\n excludeInactive: boolean = true;\r\n parcels: any[] = [];\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridId: System.Guid = '9bb2d71b-40cd-437b-9941-2aa1238a5ae0';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => {\r\n const parcel = params.data;\r\n return parcel && this.gridTracker.isRowSelected(parcel.parcelID);\r\n }\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .withRowId((data) => {\r\n const parcel = data;\r\n return parcel && parcel.parcelID.toString();\r\n })\r\n .withColumnPinning()\r\n .build();\r\n\r\n siteId: number;\r\n\r\n private _allParcels: any[] = [];\r\n private _gridApi: GridApi;\r\n\r\n get isValid(): boolean {\r\n return this.gridTracker?.hasAnythingSelected();\r\n }\r\n\r\n ngOnInit(): void {\r\n this.siteId = +this._navigationService.getQuerystringParam('siteId');\r\n const excludeInactiveStored = sessionStorage[`ws_analysisExcludeInactive${this.siteId}`];\r\n if (excludeInactiveStored) {\r\n this.excludeInactive = JSON.parse(excludeInactiveStored);\r\n } else {\r\n sessionStorage[`ws_analysisExcludeInactive${this.siteId}`] = JSON.stringify(true);\r\n this.excludeInactive = true;\r\n }\r\n this._allParcels = this.params.parcels;\r\n\r\n this.parcels = this.excludeInactive ? this._allParcels.filter(x => x.activityStatus === 'Active') : this._allParcels;\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n if (this.parcels) {\r\n this._setColumnDefinitions();\r\n }\r\n\r\n this._setRowData();\r\n\r\n const selectAllRows = this.params.selectedParcels.length === this.parcels.length;\r\n this.gridTracker.setSelectedRowsModel({\r\n selectAllRows: selectAllRows,\r\n selectedRows: selectAllRows ? [] : [...this.params.selectedParcels]\r\n });\r\n this._gridApi.redrawRows();\r\n }\r\n\r\n cancel(): void {\r\n this.result = null;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n updateParcels(excludeInactive: boolean): void {\r\n this.excludeInactive = excludeInactive;\r\n sessionStorage[`ws_analysisExcludeInactive${this.siteId}`] = JSON.stringify(this.excludeInactive);\r\n this.parcels = this._allParcels.filter(x => !excludeInactive || x.activityStatus === 'Active');\r\n this.gridTracker.clear();\r\n this._setRowData();\r\n }\r\n\r\n async updateParcelFilter(): Promise {\r\n this.result = await this.gridTracker.getSelectedRowIds();\r\n if (this.result.length === 0) {\r\n this.result = this._allParcels.map(x => x.parcelID);\r\n }\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setColumnDefinitions(): void {\r\n const columns: ColDef[] = [\r\n {\r\n colId: 'grid-column-select',\r\n field: 'parcelID',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'propType',\r\n width: 50,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n cellRendererFramework: ParcelTypeCellRendererComponent,\r\n cellRendererParams: {\r\n getParcelType: (params: ParcelTypeCellRendererComponentParams): string => {\r\n const parcel = params.data;\r\n return parcel.propertyType;\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Acct Num',\r\n field: 'accountNumber',\r\n lockVisible: true,\r\n valueFormatter: (params) => {\r\n const parcel = params.data;\r\n return (!parcel.isTotalRow) ? parcel.acctNum : 'TOTAL';\r\n }\r\n },\r\n {\r\n headerName: 'Status',\r\n field: 'activityStatus',\r\n lockVisible: true,\r\n cellRendererFramework: ActivityStatusCellRendererComponent\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'acctNum',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n this.gridTracker && this.gridTracker.clear();\r\n\r\n this._gridApi.setRowData(this.parcels);\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n const queryResultModel: Compliance.QueryResultModel = {\r\n lastModifiedTimestamp: new Date(),\r\n totalRows: rows.length,\r\n totalValidRows: rows.length,\r\n data: rows.map((x) => {\r\n const parcel = x.data;\r\n return parcel && parcel.parcelID;\r\n })\r\n };\r\n\r\n return Promise.resolve(queryResultModel);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, lastValueFrom, Observable } from 'rxjs';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { Constants } from '../../constants.new';\r\nimport { ActivityRepository } from '../../Core-Repositories';\r\nimport { ProductAnalyticsService } from '../Amplitude/productAnalytics.service';\r\nimport * as _ from 'lodash';\r\nimport { ParcelFilterModalComponent } from './Parcel-Filter/parcelFilterModal.component';\r\n\r\nexport enum ActivityPanelModes {\r\n totalFMV = 'totalFMV',\r\n totalFMVPerSqFt = 'totalFMVPerSqFt',\r\n totalFMVPerUnit = 'totalFMVPerUnit',\r\n landFMVPerSqFt = 'landFMVPerSqFt',\r\n landFMVPerAcre = 'landFMVPerAcre',\r\n totalTaxes = 'totalTaxes',\r\n recentAppeals = 'recentAppeals'\r\n}\r\n\r\nexport enum PropCharNames {\r\n SQFT = 'Imps. SqFt',\r\n UNITS = 'Units',\r\n ACREAGE = 'Land Acreage'\r\n}\r\n\r\ninterface GraphConfigTitle {\r\n text: string;\r\n floating: boolean;\r\n useHTML?: boolean;\r\n zIndex?: number;\r\n style: { [key: string]: string | number };\r\n}\r\n\r\ninterface GraphConfigChart {\r\n type?: string;\r\n zoomType?: string;\r\n spacingLeft: number;\r\n marginLeft: number;\r\n spacingRight: number;\r\n marginRight: number;\r\n spacingTop: number;\r\n marginTop: number;\r\n spacingBottom: number;\r\n marginBottom: number;\r\n width?: string;\r\n options3d: {\r\n enabled: boolean;\r\n alpha: number;\r\n beta: number;\r\n viewDistance: number;\r\n depth: number;\r\n },\r\n events?: {\r\n afterPrint: () => void;\r\n }\r\n}\r\n\r\ninterface GraphConfigLegend {\r\n layout?: string;\r\n align?: string;\r\n verticalAlign?: string;\r\n x?: number;\r\n y?: number;\r\n floating?: boolean;\r\n itemStyle?: {\r\n width: number;\r\n };\r\n enabled?: boolean;\r\n}\r\n\r\ninterface GraphConfigExportingMenuItem {\r\n textKey?: string;\r\n onclick?: () => void;\r\n separator?: boolean;\r\n}\r\n\r\ninterface GraphConfigExporting {\r\n buttons: {\r\n contextButton: {\r\n menuItems: GraphConfigExportingMenuItem[]\r\n }\r\n };\r\n}\r\n\r\ninterface GraphConfigYAxis {\r\n title: {\r\n text: string;\r\n x?: number,\r\n style?: {\r\n color: string;\r\n }\r\n },\r\n labels?: {\r\n format?: string;\r\n style?: {\r\n color: string;\r\n }\r\n },\r\n opposite?: boolean;\r\n allowDecimals?: boolean;\r\n offset?: number;\r\n min?: number;\r\n}\r\n\r\ninterface GraphConfig {\r\n title: GraphConfigTitle;\r\n tableTitle: string;\r\n colors: string[];\r\n xAxis: {\r\n categories: any[]\r\n },\r\n series: any[];\r\n chartType: ActivityPanelModes | string;\r\n propertyCharacteristics?: any;\r\n chart: GraphConfigChart;\r\n credits: {\r\n enabled: boolean\r\n },\r\n yAxis: GraphConfigYAxis | GraphConfigYAxis[],\r\n legend: GraphConfigLegend,\r\n tooltip: {\r\n headerFormat: string;\r\n pointFormat: string;\r\n useHTML: boolean;\r\n shadow: boolean;\r\n followPointer: boolean;\r\n style: {\r\n 'z-index': number;\r\n //'max-width': 100\r\n 'white-space': string;\r\n }\r\n },\r\n\r\n plotOptions: {\r\n column: {\r\n stacking: string | boolean;\r\n grouping?: string | boolean;\r\n depth: number;\r\n events?: {\r\n legendItemClick: () => boolean;\r\n }\r\n },\r\n series: {\r\n animation: boolean;\r\n }\r\n },\r\n parcelFilterList?: any[];\r\n siteId?: number;\r\n loadedAllYears?: boolean;\r\n useLatestActualized?: boolean;\r\n availableYears?: number[];\r\n spacingBottom?: number;\r\n totalValues?: any[];\r\n exporting?: GraphConfigExporting;\r\n}\r\n\r\ninterface UserSessionFilterCache {\r\n [key: number]: number[];\r\n}\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class ActivityService {\r\n constructor(private readonly _activityRepository: ActivityRepository,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _constants: Constants,\r\n private readonly _modalService: WeissmanModalService\r\n ) {\r\n }\r\n\r\n private _userSessionFilterCacheSubject: BehaviorSubject = new BehaviorSubject({});\r\n private _userSessionFilterCache$: Observable = this._userSessionFilterCacheSubject.asObservable();\r\n\r\n get userSessionFilterCache$(): Observable {\r\n return this._userSessionFilterCache$;\r\n }\r\n\r\n updateParcelFilterCacheForSite(siteId: number, parcelIds: number[]): void {\r\n sessionStorage[`ws_analysisIncludedParcels${siteId}`] = JSON.stringify(parcelIds);\r\n const cache = this._userSessionFilterCacheSubject.getValue();\r\n cache[siteId] = parcelIds;\r\n this._userSessionFilterCacheSubject.next(cache);\r\n }\r\n\r\n clearParcelFilterCacheForSite(siteId: number): void {\r\n const cache = this._userSessionFilterCacheSubject.getValue();\r\n delete cache[siteId];\r\n this._userSessionFilterCacheSubject.next(cache);\r\n }\r\n\r\n getDataByYear(siteId: number, year: number, parcelFilter: any, useLatestActualized: boolean): Promise {\r\n return lastValueFrom(this._activityRepository.getDataByYear(siteId, year, parcelFilter, useLatestActualized));\r\n }\r\n\r\n getDataForAllYears(siteId: number, parcelFilter, useLatestActualized: boolean): Promise {\r\n return lastValueFrom(this._activityRepository.getDataForAllYears(siteId, parcelFilter, useLatestActualized));\r\n }\r\n\r\n getDataByParcel(siteId: number, year: number, parcelId: number, useLatestActualized: boolean): Promise {\r\n return lastValueFrom(this._activityRepository.getDataByParcel(siteId, year, parcelId, useLatestActualized));\r\n }\r\n\r\n getDataByParcelAllYears(siteId: number, parcelId: number, useLatestActualized: boolean): Promise {\r\n return lastValueFrom(this._activityRepository.getDataByParcelAllYears(siteId, parcelId, useLatestActualized));\r\n }\r\n\r\n getDeadlineData(siteId: number, parcelId: number): Promise {\r\n return lastValueFrom(this._activityRepository.getDeadlineData(siteId, parcelId));\r\n }\r\n\r\n // TODO - this can be moved back into activity panel component once it is updated to new Angular\r\n async openParcelFilter(parcels: any[], selectedParcels: number[]): Promise {\r\n return await this._modalService.showAsync(ParcelFilterModalComponent, { parcels, selectedParcels }, 'modal-md');\r\n }\r\n\r\n getColor(chartType: ActivityPanelModes | string, nameOrIndex: number | string, isProjected: boolean): string {\r\n const colors = this.getColorsArray(chartType);\r\n let colorIndex: number;\r\n\r\n if (_.isNumber(nameOrIndex)) {\r\n if (nameOrIndex < colors[1].length)\r\n colorIndex = nameOrIndex;\r\n else\r\n colorIndex = nameOrIndex % colors[1].length;\r\n } else { // name\r\n colorIndex = colors[2].indexOf(nameOrIndex);\r\n if (colorIndex < 0)\r\n throw 'unable to find color';\r\n }\r\n if (isProjected)\r\n return colors[1][colorIndex]; // transparent color\r\n else\r\n return colors[0][colorIndex]; // solid color\r\n }\r\n\r\n\r\n calculatePropCharAdjustedFmv(originalValueValue: number, propCharName: string, config: GraphConfig): number {\r\n const i = _.findIndex(config.propertyCharacteristics, (o: any) => {\r\n return o.label == propCharName;\r\n });\r\n if (i >= 0 && config.propertyCharacteristics[i].value != 0) {\r\n return new Decimal(originalValueValue).dividedBy(parseFloat(config.propertyCharacteristics[i].value)).toNumber();\r\n }\r\n return 0;\r\n }\r\n\r\n\r\n getFmvValue(originalValueValue: number, chartType: ActivityPanelModes | string, config: GraphConfig): number {\r\n switch (chartType) {\r\n case ActivityPanelModes.totalFMV:\r\n return originalValueValue;\r\n case ActivityPanelModes.totalFMVPerSqFt:\r\n return this.calculatePropCharAdjustedFmv(originalValueValue, PropCharNames.SQFT, config);\r\n case ActivityPanelModes.landFMVPerSqFt:\r\n // special case, instead of sqft attribute we will use acreage /43560\r\n //\r\n return new Decimal(this.calculatePropCharAdjustedFmv(originalValueValue, PropCharNames.ACREAGE, config)).dividedBy(43560).toNumber();\r\n case ActivityPanelModes.totalFMVPerUnit:\r\n return this.calculatePropCharAdjustedFmv(originalValueValue, PropCharNames.UNITS, config);\r\n case ActivityPanelModes.landFMVPerAcre:\r\n return this.calculatePropCharAdjustedFmv(originalValueValue, PropCharNames.ACREAGE, config);\r\n }\r\n return 0;\r\n }\r\n\r\n\r\n getGraphTitle(chartType: ActivityPanelModes | string): string {\r\n switch (chartType) {\r\n case ActivityPanelModes.totalFMV:\r\n return 'Total FMV';\r\n case ActivityPanelModes.totalFMVPerSqFt:\r\n return 'Total $/Imps. Sq Ft';\r\n case ActivityPanelModes.totalFMVPerUnit:\r\n return 'Total $/Unit';\r\n case ActivityPanelModes.landFMVPerSqFt:\r\n return 'Land $/Land Sq Ft';\r\n case ActivityPanelModes.landFMVPerAcre:\r\n return 'Land $/Acre';\r\n case ActivityPanelModes.totalTaxes:\r\n case 'totalTaxesUngrouped':\r\n return 'Tax Liabilities';\r\n case 'recentAppeals':\r\n return 'Recent Appeals';\r\n\r\n }\r\n return '';\r\n }\r\n\r\n getTableTitle(chartType: ActivityPanelModes | string): string {\r\n switch (chartType) {\r\n case ActivityPanelModes.totalFMV:\r\n return 'Total FMV';\r\n case ActivityPanelModes.totalFMVPerSqFt:\r\n case ActivityPanelModes.totalFMVPerUnit:\r\n return 'Total $ Per Metrics '; //+ chartType;\r\n case ActivityPanelModes.landFMVPerSqFt:\r\n case ActivityPanelModes.landFMVPerAcre:\r\n return 'Land $ Per Metrics '; //+ chartType;\r\n case ActivityPanelModes.totalTaxes:\r\n return 'Tax Liabilities';\r\n case 'recentAppeals':\r\n return 'Recent Appeals';\r\n\r\n }\r\n return '';\r\n }\r\n\r\n\r\n getColorsArray(chartType: ActivityPanelModes | string): string[][] {\r\n switch (chartType) {\r\n case ActivityPanelModes.totalFMV:\r\n case ActivityPanelModes.totalFMVPerSqFt:\r\n case ActivityPanelModes.totalFMVPerUnit:\r\n return [ // columns = values by property type\r\n ['rgba(186,133,46,1)', 'rgba(104,35,45,1)', 'rgba(255,214,224, 1)', 'rgba(185,217,255, 1)'], // solid\t\t\t// PP was rgba(166,153,131,1)\r\n ['rgba(186,133,46,0.6)', 'rgba(104,35,45,0.5)', 'rgba(255,214,224, 0.6)', 'rgba(185,217,255, 0.6)'], // transparent\r\n ['PP', 'RE', 'MN', 'CA'] // names\r\n ];\r\n\r\n case ActivityPanelModes.landFMVPerSqFt:\r\n case ActivityPanelModes.landFMVPerAcre:\r\n return [ // all columns will represent Land\r\n ['rgba(33,126,36, 1)'], // solid\r\n ['rgba(33,126,36, 0.5)'], // transparent\r\n ['Land'] // names\r\n ];\r\n\r\n case ActivityPanelModes.totalTaxes:\r\n case 'totalTaxesUngrouped':\r\n return [ // columns = values by property type\r\n ['rgba(166,206,227, 1)', 'rgba(178,223,138, 1)', 'rgba(51,160,44, 1)', 'rgba(251,154,153, 1)', 'rgba(227,26,28, 1)', 'rgba(253,191,111, 1)', 'rgba(255,127,0, 1)', 'rgba(202,178,214, 1)', 'rgba(106,61,154, 1)', 'rgba(255,255,153, 1)', 'rgba(177,89,40, 1)', 'rgba(141,211,199, 1)', 'rgba(255,255,179, 1)', 'rgba(190,186,218, 1)', 'rgba(251,128,114, 1)', 'rgba(128,177,211, 1)', 'rgba(253,180,98, 1)', 'rgba(179,222,105, 1)', 'rgba(252,205,229, 1)', 'rgba(217,217,217, 1)', 'rgba(188,128,189, 1)', 'rgba(204,235,197, 1)', 'rgba(255,237,111, 1)'], // solid\r\n ['rgba(166,206,227, 0.5)', 'rgba(178,223,138, 0.5)', 'rgba(51,160,44, 0.5)', 'rgba(251,154,153, 0.5)', 'rgba(227,26,28, 0.5)', 'rgba(253,191,111, 0.5)', 'rgba(255,127,0, 0.5)', 'rgba(202,178,214, 0.5)', 'rgba(106,61,154, 0.5)', 'rgba(255,255,153, 0.5)', 'rgba(177,89,40, 0.5)', 'rgba(141,211,199, 0.5)', 'rgba(255,255,179, 0.5)', 'rgba(190,186,218, 0.5)', 'rgba(251,128,114, 0.5)', 'rgba(128,177,211, 0.5)', 'rgba(253,180,98, 0.5)', 'rgba(179,222,105, 0.5)', 'rgba(252,205,229, 0.5)', 'rgba(217,217,217, 0.5)', 'rgba(188,128,189, 0.5)', 'rgba(204,235,197, 0.5)', 'rgba(255,237,111, 0.5)'], // transparent\r\n [] // names\r\n ];\r\n\r\n case 'recentAppeals':\r\n return [ // all columns will represent Land\r\n ['rgba(98, 99, 116, 1)'], // solid\r\n ['rgba(98, 99, 116, 0.5)'], // transparent\r\n ['recentAppeals'] // names\r\n ];\r\n }\r\n return [];\r\n }\r\n\r\n\r\n getHoverPointFormat(multipleSeries: boolean, digits: number): string {\r\n if (multipleSeries)\r\n return `\\u25CF {series.name}: {point.y:,.${digits}f} / {point.stackTotal:,.${digits}f}`;\r\n else\r\n return `\\u25CF {series.name}: {point.y:,.${digits}f}`;\r\n }\r\n\r\n getTotalTaxHoverPointFormat(multipleSeries: boolean, digits: number): string {\r\n if (multipleSeries)\r\n return `
\\u25CF {series.name}
{point.y:,.${digits}f} / {point.stackTotal:,.${digits}f}
`;\r\n else\r\n return `
\\u25CF
{series.name}

{point.y:,.${digits}f}
`;\r\n }\r\n\r\n\r\n createGraphConfig(config: any, chartType: ActivityPanelModes | string): GraphConfig {\r\n let graphConfig: GraphConfig = {\r\n title: {\r\n text: this.getGraphTitle(chartType),\r\n floating: false,\r\n //useHTML: true,\r\n //zIndex: 1,\r\n style: {\r\n color: 'var(--ace-neutral-700)',\r\n fontWeight: 'bold',\r\n 'z-index': 0,\r\n 'font-size': '12pt',\r\n 'background-color': 'white',\r\n //'margin': '30px;',\r\n //border: '1px solid black',\r\n '-ms-transform': 'rotate(3deg)',\r\n /* IE 9 */\r\n '-webkit-transform': 'rotate(3deg)',\r\n /* Chrome, Safari, Opera */\r\n 'transform': 'rotate(3deg)'\r\n }\r\n },\r\n tableTitle: this.getTableTitle(chartType),\r\n\r\n // this will return 3 arrays; first one (solid colors) will be used for legend\r\n colors: this.getColorsArray(chartType)[0],\r\n xAxis: {\r\n categories: []\r\n },\r\n series: [],\r\n chartType: chartType,\r\n propertyCharacteristics: config.propertyCharacteristics,\r\n\r\n chart: {\r\n type: 'column',\r\n spacingLeft: 10,\r\n marginLeft: 40,\r\n\r\n spacingRight: 10,\r\n marginRight: 30,\r\n\r\n spacingTop: 0,\r\n marginTop: 20,\r\n\r\n spacingBottom: 10,\r\n marginBottom: 50,\r\n\r\n //width: '400',\r\n options3d: {\r\n enabled: true,\r\n alpha: 15,\r\n beta: 15,\r\n viewDistance: 25,\r\n depth: 70\r\n }\r\n },\r\n\r\n credits: {\r\n enabled: false\r\n },\r\n\r\n yAxis: {\r\n allowDecimals: false,\r\n offset: -30,\r\n min: 0,\r\n title: {\r\n text: ''\r\n }\r\n },\r\n\r\n legend: {\r\n layout: 'vertical',\r\n align: 'right',\r\n verticalAlign: '',\r\n x: 10,\r\n y: 60,\r\n floating: true\r\n },\r\n\r\n tooltip: {\r\n headerFormat: '{point.key}
',\r\n pointFormat: '', // will be defined later\r\n useHTML: true,\r\n shadow: false,\r\n followPointer: false,\r\n style: {\r\n 'z-index': 100,\r\n //'max-width': 100\r\n 'white-space': 'normal !important'\r\n }\r\n },\r\n\r\n plotOptions: {\r\n column: {\r\n stacking: 'normal',\r\n depth: 50,\r\n events: {\r\n legendItemClick: null\r\n }\r\n },\r\n series: {\r\n animation: false\r\n }\r\n },\r\n parcelFilterList: null,\r\n siteId: null,\r\n loadedAllYears: null,\r\n useLatestActualized: null,\r\n availableYears: null\r\n };\r\n\r\n switch (chartType) {\r\n case ActivityPanelModes.totalFMV:\r\n graphConfig = this.createPropertyTypeAndPropCharConfig(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = this.getHoverPointFormat((graphConfig.series.length > 1), 0);\r\n break;\r\n\r\n case ActivityPanelModes.totalFMVPerSqFt:\r\n case ActivityPanelModes.totalFMVPerUnit:\r\n graphConfig = this.createPropertyTypeAndPropCharConfig(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = this.getHoverPointFormat((graphConfig.series.length > 1), 2);\r\n break;\r\n case ActivityPanelModes.landFMVPerSqFt:\r\n graphConfig = this.createLandConfig(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = this.getHoverPointFormat((graphConfig.series.length > 1), 2);\r\n break;\r\n case ActivityPanelModes.landFMVPerAcre:\r\n graphConfig = this.createLandConfig(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = this.getHoverPointFormat((graphConfig.series.length > 1), 2);\r\n break;\r\n case ActivityPanelModes.totalTaxes:\r\n graphConfig = this.createTotalTaxesConfig(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = this.getTotalTaxHoverPointFormat((graphConfig.series.length > 1), 2);\r\n break;\r\n case 'recentAppeals':\r\n graphConfig = this.createTaxSavingsConfig(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = this.getHoverPointFormat(false, 0);\r\n break;\r\n case 'totalTaxesUngrouped':\r\n graphConfig = this.createTotalTaxesUngroupedConfig(graphConfig, config);\r\n }\r\n //console.log('graphConfig', JSON.stringify(graphConfig));\r\n\r\n graphConfig.parcelFilterList = config.parcelFilterList; // we will need it if we want to load data for all years from within the table\r\n graphConfig.siteId = config.siteId;\r\n graphConfig.loadedAllYears = config.loadedAllYears;\r\n graphConfig.useLatestActualized = config.useLatestActualized;\r\n graphConfig.availableYears = config.availableYears;\r\n\r\n if (graphConfig.series.length < 2) {\r\n // there is no reason to show/hide part of the column in this case\r\n graphConfig.plotOptions.column.events = {\r\n legendItemClick: () => {\r\n return false;\r\n }\r\n };\r\n }\r\n\r\n return graphConfig;\r\n\r\n }\r\n\r\n\r\n createPropertyTypeAndPropCharConfig(graphConfig: GraphConfig, config: any, chartType: ActivityPanelModes | string): GraphConfig {\r\n // create categories\r\n _.forEach(config.annualData, (annualYear) => {\r\n graphConfig.xAxis.categories.push(annualYear.year);\r\n _.forEach(annualYear.fmvByPropertyType, (FMVByPropertyTypeItem) => {\r\n // if our series array does not have this property type - add it\r\n const propertyTypeIndex = _.findIndex(graphConfig.series, o => {\r\n return o.name == FMVByPropertyTypeItem.name;\r\n });\r\n if (propertyTypeIndex < 0) {\r\n const newSeriesItem = {\r\n name: FMVByPropertyTypeItem.name,\r\n propertyTypeSequence: this._constants.PropertyTypes[FMVByPropertyTypeItem.name].sequence,\r\n data: []\r\n };\r\n graphConfig.series.push(newSeriesItem);\r\n //propertyTypeIndex = graphConfig.series.length - 1;\r\n }\r\n });\r\n });\r\n\r\n // sorting years\r\n graphConfig.xAxis.categories.sort();\r\n\r\n\r\n // sorting series (property types - the one with the smallest sequence must go to the end)\r\n //\r\n graphConfig.series.sort(\r\n (item1, item2) => {\r\n return item2.propertyTypeSequence - item1.propertyTypeSequence;\r\n }\r\n );\r\n\r\n _.forEach(graphConfig.series, (seriesItem) => {\r\n seriesItem._colorIndex = graphConfig.colors.indexOf(this.getColor(chartType, seriesItem.name, false));\r\n // set NULL for each property type (if you don't do that, HighChart will assign Zero)\r\n for (let i = 0; i < graphConfig.xAxis.categories.length; i++) {\r\n seriesItem.data.push({\r\n y: null\r\n });\r\n }\r\n });\r\n\r\n // by now our graphConfig should have all years, property types and series initialized with 0 for every year\r\n //\r\n _.forEach(config.annualData, (annualYear) => {\r\n const annualYearIndex = graphConfig.xAxis.categories.indexOf(annualYear.year);\r\n\r\n _.forEach(annualYear.fmvByPropertyType, (FMVByPropertyTypeItem) => {\r\n // if our series does not have this property type - add it\r\n const propertyTypeIndex = _.findIndex(graphConfig.series, (o) => {\r\n return o.name == FMVByPropertyTypeItem.name;\r\n });\r\n\r\n // now we can insert data for this year and property type\r\n //\r\n graphConfig.series[propertyTypeIndex].data[annualYearIndex].y = this.getFmvValue(FMVByPropertyTypeItem.fmv, chartType, config);\r\n graphConfig.series[propertyTypeIndex].data[annualYearIndex].originalValue = FMVByPropertyTypeItem.fmv;\r\n\r\n // now mark it as projected\r\n graphConfig.series[propertyTypeIndex].data[annualYearIndex].color = this.getColor(chartType, FMVByPropertyTypeItem.name, FMVByPropertyTypeItem.isProjected);\r\n\r\n graphConfig.series[propertyTypeIndex].data[annualYearIndex].isProjected = FMVByPropertyTypeItem.isProjected;\r\n });\r\n });\r\n\r\n return graphConfig;\r\n\r\n }\r\n\r\n createLandConfig(graphConfig: GraphConfig, config: any, chartType: ActivityPanelModes | string): GraphConfig {\r\n graphConfig.series = [{\r\n name: 'Land',\r\n data: []\r\n }];\r\n\r\n // create categories (years)\r\n _.forEach(config.annualData, (annualYear) => {\r\n graphConfig.xAxis.categories.push(annualYear.year);\r\n });\r\n\r\n // sorting years\r\n graphConfig.xAxis.categories.sort();\r\n\r\n const seriesItem = graphConfig.series[0]; // that's the only series item we'll have here\r\n seriesItem._colorIndex = graphConfig.colors.indexOf(this.getColor(chartType, 'Land', false));\r\n for (let i = 0; i < graphConfig.xAxis.categories.length; i++) {\r\n seriesItem.data.push({\r\n y: 0\r\n });\r\n }\r\n\r\n // by now our graphConfig should have all years - and series data initialized with 0 for every year\r\n //\r\n _.forEach(config.annualData, (annualYear) => {\r\n const annualYearIndex = graphConfig.xAxis.categories.indexOf(annualYear.year);\r\n\r\n graphConfig.series[0].data[annualYearIndex].y = this.getFmvValue(annualYear.fmvForLandTypeComponents.fmv, chartType, config);\r\n graphConfig.series[0].data[annualYearIndex].originalValue = annualYear.fmvForLandTypeComponents.fmv;\r\n\r\n // now mark it as projected\r\n graphConfig.series[0].data[annualYearIndex].color = this.getColor(chartType, 'Land', annualYear.fmvForLandTypeComponents.isProjected);\r\n graphConfig.series[0].data[annualYearIndex].isProjected = annualYear.fmvForLandTypeComponents.isProjected;\r\n });\r\n\r\n return graphConfig;\r\n\r\n }\r\n\r\n\r\n createTotalTaxesConfig(graphConfig: GraphConfig, config: any, chartType: ActivityPanelModes | string): GraphConfig {\r\n // create categories\r\n _.forEach(config.annualData, (annualYear) => {\r\n graphConfig.xAxis.categories.push(annualYear.year);\r\n _.forEach(annualYear.collectorTaxes, (collectorTaxesItem) => {\r\n // if our series array does not have this property type - add it\r\n const existingSeriesIndex = _.findIndex(graphConfig.series, (o) => {\r\n return o.name == collectorTaxesItem.collectorName;\r\n });\r\n if (existingSeriesIndex < 0) {\r\n const newSeriesItem = {\r\n name: collectorTaxesItem.collectorName,\r\n data: []\r\n };\r\n graphConfig.series.push(newSeriesItem);\r\n //propertyTypeIndex = graphConfig.series.length - 1;\r\n }\r\n });\r\n });\r\n\r\n // sorting years\r\n graphConfig.xAxis.categories.sort();\r\n\r\n let sdColorIndex = 0;\r\n _.forEach(graphConfig.series, (seriesItem) => {\r\n seriesItem._colorIndex = graphConfig.colors.indexOf(this.getColor(chartType, sdColorIndex, false));\r\n seriesItem.sdColorIndex = sdColorIndex;\r\n for (let i = 0; i < graphConfig.xAxis.categories.length; i++) {\r\n seriesItem.data.push({\r\n y: 0\r\n });\r\n }\r\n sdColorIndex++;\r\n });\r\n\r\n // by now our graphConfig should have all years and series initialized with 0 for every year\r\n //\r\n _.forEach(config.annualData, (annualYear) => {\r\n const annualYearIndex = graphConfig.xAxis.categories.indexOf(annualYear.year);\r\n\r\n _.forEach(annualYear.collectorTaxes, (collectorTaxesItem) => {\r\n // if our series does not have this property type - add it\r\n const existingSeriesIndex = _.findIndex(graphConfig.series, (o) => {\r\n return o.name == collectorTaxesItem.collectorName;\r\n });\r\n\r\n if (collectorTaxesItem.tax) {\r\n // now we can insert data for this year and property type\r\n //\r\n graphConfig.series[existingSeriesIndex].data[annualYearIndex].y = collectorTaxesItem.tax;\r\n graphConfig.series[existingSeriesIndex].data[annualYearIndex].originalValue = collectorTaxesItem.tax;\r\n //graphConfig.series[existingSeriesIndex].data[annualYearIndex].originalTax = collectorTaxesItem.tax;\r\n\r\n // now mark it as projected\r\n graphConfig.series[existingSeriesIndex].data[annualYearIndex].color = this.getColor(chartType, graphConfig.series[existingSeriesIndex].sdColorIndex, collectorTaxesItem.isProjected);\r\n\r\n graphConfig.series[existingSeriesIndex].data[annualYearIndex].isProjected = collectorTaxesItem.isProjected;\r\n }\r\n });\r\n });\r\n\r\n //console.log('graphConfig.series.length', graphConfig.series.length);\r\n\r\n if (graphConfig.series.length <= 4) {\r\n\r\n graphConfig.chart.marginBottom = (graphConfig.series.length * 21) + 25;\r\n graphConfig.spacingBottom = 10;\r\n graphConfig.chart.marginRight = 0;\r\n\r\n graphConfig.legend = {\r\n layout: 'horizontal',\r\n align: 'left',\r\n //itemWidth: LegendWidth,\r\n verticalAlign: 'bottom',\r\n floating: false,\r\n //y: 10,\r\n itemStyle: { width: 400 }\r\n };\r\n\r\n } else {\r\n graphConfig.legend = {\r\n enabled: false\r\n };\r\n }\r\n\r\n return graphConfig;\r\n\r\n }\r\n\r\n createTaxSavingsConfig(graphConfig: GraphConfig, config: any, chartType: ActivityPanelModes | string): GraphConfig {\r\n // create categories\r\n _.forEach(config.annualData, (annualYear) => {\r\n graphConfig.xAxis.categories.push(annualYear.year);\r\n });\r\n\r\n // sorting years\r\n graphConfig.xAxis.categories.sort();\r\n\r\n graphConfig.colors = ['rgba(163, 164, 178, 1)']; // this color will be used to indicate Savings legend\r\n\r\n graphConfig.chart = {\r\n zoomType: 'xy',\r\n options3d: {\r\n enabled: false,\r\n alpha: 15,\r\n beta: 15,\r\n viewDistance: 25,\r\n depth: 70\r\n },\r\n spacingLeft: 5,\r\n marginLeft: 60,\r\n\r\n spacingRight: 10,\r\n marginRight: 60,\r\n\r\n spacingTop: 0,\r\n marginTop: 30,\r\n\r\n spacingBottom: 0,\r\n marginBottom: 80\r\n };\r\n\r\n\r\n graphConfig.title = {\r\n text: this.getGraphTitle(chartType),\r\n floating: false,\r\n useHTML: true,\r\n style: {\r\n color: 'var(--ace-neutral-700)',\r\n fontWeight: 'bold',\r\n 'font-size': '12pt',\r\n 'background-color': 'white',\r\n 'font-family': 'Arial, Helvetica, sans-serif'\r\n //'margin': '30px;',\r\n //border: '1px solid black',\r\n }\r\n };\r\n\r\n\r\n graphConfig.plotOptions = {\r\n column: {\r\n depth: 40,\r\n stacking: false,\r\n grouping: false\r\n //groupZPadding: 10\r\n },\r\n series: {\r\n animation: false\r\n }\r\n };\r\n\r\n graphConfig.yAxis = [{ // Primary yAxis - savings oer year\r\n labels: {\r\n style: {\r\n color: 'rgba(98, 99, 116, 1)'\r\n }\r\n },\r\n title: {\r\n text: 'Savings',\r\n x: 5,\r\n style: {\r\n color: 'rgba(98, 99, 116, 1)'\r\n }\r\n }\r\n\r\n\r\n }, { // Secondary yAxis - FMV per year\r\n //gridLineWidth: 0,\r\n title: {\r\n text: 'FMV',\r\n style: {\r\n color: 'rgba(77, 25, 136, 1)'\r\n }\r\n },\r\n labels: {\r\n //format: '{value} mm',\r\n style: {\r\n color: 'rgba(77, 25, 136, 1)'\r\n }\r\n },\r\n offset: -30,\r\n opposite: true // draw this one on the right side\r\n }];\r\n\r\n\r\n graphConfig.series = [{\r\n 'name': 'Savings',\r\n type: 'column',\r\n yAxis: 0,\r\n zIndex: 1,\r\n 'data': []\r\n\r\n }, {\r\n type: 'line',\r\n name: 'Original FMV',\r\n yAxis: 1,\r\n zIndex: 2,\r\n data: [],\r\n lineColor: 'rgba(77, 25, 136, 1)',\r\n marker: {\r\n lineWidth: 2,\r\n lineColor: 'rgba(77, 25, 136, 1)',\r\n fillColor: 'rgba(273, 174, 73, 1)'\r\n }\r\n }, {\r\n type: 'line',\r\n name: 'Current FMV',\r\n yAxis: 1,\r\n zIndex: 3,\r\n data: [],\r\n lineColor: 'rgba(77, 25, 136, 1)',\r\n marker: {\r\n lineWidth: 2,\r\n lineColor: 'rgba(77, 25, 136, 1)',\r\n fillColor: 'rgba(33, 126, 56, 1)'\r\n }\r\n }];\r\n\r\n\r\n // now we will have several series\r\n\r\n //const sdColorIndex = 0;\r\n _.forEach(graphConfig.series, (seriesItem) => {\r\n //seriesItem._colorIndex = graphConfig.colors.indexOf(getColor(chartType, sdColorIndex, false))\r\n //seriesItem.sdColorIndex = sdColorIndex;\r\n for (let i = 0; i < graphConfig.xAxis.categories.length; i++) {\r\n seriesItem.data.push({\r\n y: 0\r\n });\r\n }\r\n //sdColorIndex++;\r\n });\r\n\r\n // by now our graphConfig should have all years and series initialized with 0 for every year\r\n //\r\n _.forEach(config.annualData, (annualYear) => {\r\n const annualYearIndex = graphConfig.xAxis.categories.indexOf(annualYear.year);\r\n\r\n // now we can insert data for this year\r\n //\r\n graphConfig.series[0].data[annualYearIndex].color = 'rgba(163, 164, 178, 1)';\r\n if (annualYear.taxSavings) {\r\n // savings bar\r\n graphConfig.series[0].data[annualYearIndex].y = this.getNumericValue(annualYear.taxSavings.savings); // should we have a here?\r\n\r\n // original fmv line\r\n graphConfig.series[1].data[annualYearIndex].y = annualYear.taxSavings.originalFMV;\r\n graphConfig.series[1].data[annualYearIndex].originalFMV = annualYear.taxSavings.originalFMV;\r\n graphConfig.series[1].data[annualYearIndex].appealStatus = annualYear.taxSavings.status;\r\n graphConfig.series[1].data[annualYearIndex].savings = annualYear.taxSavings.savings;\r\n } else { // taxSavings record doesn't exist\r\n // savings bar\r\n graphConfig.series[0].data[annualYearIndex].y = 0;\r\n // original fmv line\r\n graphConfig.series[1].data[annualYearIndex].y = 0;\r\n }\r\n // current fmv line\r\n graphConfig.series[2].data[annualYearIndex].y = annualYear.totalFMV;\r\n graphConfig.series[1].data[annualYearIndex].currentFMV = annualYear.totalFMV;\r\n\r\n // now mark it as projected\r\n //graphConfig.series[existingSeriesIndex].data[annualYearIndex].color = getColor(chartType, graphConfig.series[existingSeriesIndex].sdColorIndex, collectorTaxesItem.isProjected);\r\n //graphConfig.series[existingSeriesIndex].data[annualYearIndex].isProjected = collectorTaxesItem.isProjected;\r\n });\r\n\r\n graphConfig.legend = {\r\n layout: 'horizontal',\r\n align: 'left',\r\n verticalAlign: 'bottom',\r\n floating: true\r\n };\r\n return graphConfig;\r\n\r\n }\r\n\r\n\r\n getNumericValue(val: string): number {\r\n let result = parseFloat(val);\r\n if (isNaN(result))\r\n result = 0;\r\n return result;\r\n }\r\n\r\n\r\n // BEGIN Dashboard-specific methods\r\n //\r\n getValueForPropType(propTypeData, chartType: ActivityPanelModes | string): number {\r\n switch (chartType) {\r\n case ActivityPanelModes.totalFMV:\r\n return propTypeData.fmv;\r\n case ActivityPanelModes.totalFMVPerSqFt:\r\n return propTypeData.fmvPerSqFt;\r\n case ActivityPanelModes.totalFMVPerUnit:\r\n return propTypeData.fmvPerUnit;\r\n }\r\n return 0;\r\n }\r\n\r\n getLandValueForYear(yearData, chartType: ActivityPanelModes | string): number {\r\n switch (chartType) {\r\n case ActivityPanelModes.totalFMV:\r\n return yearData.fmvForLandTypeComponents.fmv;\r\n case ActivityPanelModes.landFMVPerSqFt:\r\n return yearData.fmvForLandTypeComponents.landFMVPerSqFt;\r\n case ActivityPanelModes.landFMVPerAcre:\r\n return yearData.fmvForLandTypeComponents.landFMVPerAcre;\r\n }\r\n return 0;\r\n }\r\n\r\n\r\n createGraphConfigForDashboard(config: any, chartType: ActivityPanelModes | string, afterPrintCb: () => void): GraphConfig {\r\n const productAnalyticsService = this._productAnalyticsService;\r\n let graphConfig: GraphConfig = {\r\n title: {\r\n text: this.getGraphTitle(chartType),\r\n floating: false,\r\n //useHTML: true,\r\n //zIndex: 1,\r\n style: {\r\n color: 'black',\r\n fontWeight: 'bold',\r\n 'z-index': 0,\r\n 'font-size': '12pt',\r\n 'background-color': 'white',\r\n //'margin': '30px;',\r\n //border: '1px solid black',\r\n '-ms-transform': 'rotate(3deg)',\r\n /* IE 9 */\r\n '-webkit-transform': 'rotate(3deg)',\r\n /* Chrome, Safari, Opera */\r\n 'transform': 'rotate(3deg)'\r\n }\r\n },\r\n tableTitle: this.getTableTitle(chartType),\r\n\r\n // this will return 3 arrays; first one (solid colors) will be used for legend\r\n colors: this.getColorsArray(chartType)[0],\r\n xAxis: {\r\n categories: []\r\n },\r\n series: [],\r\n chartType: chartType,\r\n totalValues: [],\r\n\r\n chart: {\r\n type: 'column',\r\n spacingLeft: 10,\r\n marginLeft: 40,\r\n\r\n spacingRight: 10,\r\n marginRight: 30,\r\n\r\n spacingTop: 0,\r\n marginTop: 20,\r\n\r\n spacingBottom: 10,\r\n marginBottom: 50,\r\n\r\n //width: '400',\r\n options3d: {\r\n enabled: true,\r\n alpha: 15,\r\n beta: 15,\r\n viewDistance: 25,\r\n depth: 70\r\n },\r\n\r\n events: {\r\n afterPrint: afterPrintCb\r\n }\r\n },\r\n\r\n credits: {\r\n enabled: false\r\n },\r\n\r\n yAxis: {\r\n allowDecimals: false,\r\n offset: -30,\r\n min: 0,\r\n title: {\r\n text: ''\r\n }\r\n },\r\n\r\n legend: {\r\n layout: 'vertical',\r\n align: 'right',\r\n verticalAlign: '',\r\n x: 20,\r\n floating: false,\r\n y: 60\r\n },\r\n\r\n tooltip: {\r\n headerFormat: '{point.key}
',\r\n pointFormat: '', // will be defined later\r\n useHTML: true,\r\n shadow: false,\r\n followPointer: false,\r\n style: {\r\n 'z-index': 100,\r\n //'max-width': 100\r\n 'white-space': 'normal !important'\r\n }\r\n },\r\n\r\n plotOptions: {\r\n column: {\r\n stacking: 'normal',\r\n depth: 50\r\n },\r\n series: {\r\n animation: false\r\n }\r\n },\r\n\r\n exporting: {\r\n buttons: {\r\n contextButton: {\r\n menuItems: [\r\n {\r\n textKey: 'printChart',\r\n onclick: function() {\r\n this.print();\r\n productAnalyticsService.logEvent('click-portfolio-widget', {\r\n printChart: 'print'\r\n });\r\n }\r\n },\r\n { separator: true },\r\n {\r\n textKey: 'downloadPNG',\r\n onclick: function() {\r\n this.exportChart();\r\n productAnalyticsService.logEvent('click-portfolio-widget', {\r\n printChart: 'png'\r\n });\r\n }\r\n },\r\n {\r\n textKey: 'downloadJPEG',\r\n onclick: function() {\r\n this.exportChart({\r\n type: 'image/jpeg'\r\n });\r\n productAnalyticsService.logEvent('click-portfolio-widget', {\r\n printChart: 'jpeg'\r\n });\r\n }\r\n },\r\n {\r\n textKey: 'downloadPDF',\r\n onclick: function() {\r\n this.exportChart({\r\n type: 'application/pdf'\r\n });\r\n productAnalyticsService.logEvent('click-portfolio-widget', {\r\n printChart: 'pdf'\r\n });\r\n }\r\n },\r\n {\r\n textKey: 'downloadSVG',\r\n onclick: function() {\r\n this.exportChart({\r\n type: 'image/svg+xml'\r\n });\r\n productAnalyticsService.logEvent('click-portfolio-widget', {\r\n printChart: 'svg'\r\n });\r\n }\r\n }\r\n ]\r\n }\r\n }\r\n }\r\n };\r\n\r\n // create categories (years) and totalValues by years.\r\n _.forEach(config.annualData, (annualYear) => {\r\n graphConfig.xAxis.categories.push(annualYear.year);\r\n\r\n const newYearTotals = {\r\n year: annualYear.year,\r\n totalFMV: annualYear.totalFMV,\r\n fmvPerSqFt: annualYear.totalFMVPerSqFt,\r\n fmvPerUnit: annualYear.totalFMVPerUnit,\r\n landFMV: annualYear.fmvForLandTypeComponents.fmv,\r\n landFMVPerSqFt: annualYear.fmvForLandTypeComponents.landFMVPerSqFt,\r\n landFMVPerAcre: annualYear.fmvForLandTypeComponents.landFMVPerAcre,\r\n totalTax: annualYear.totalTax\r\n };\r\n graphConfig.totalValues.push(newYearTotals);\r\n });\r\n\r\n // sort categories and totalValues in ascending years so they are parallel\r\n graphConfig.xAxis.categories.sort();\r\n graphConfig.totalValues.sort(\r\n (item1, item2) => {\r\n return item1.year - item2.year;\r\n }\r\n );\r\n\r\n switch (chartType) {\r\n case ActivityPanelModes.totalFMV:\r\n graphConfig = this.createPropertyTypeConfig(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = this.getHoverPointFormat((graphConfig.series.length > 1), 0);\r\n break;\r\n\r\n case ActivityPanelModes.totalFMVPerSqFt:\r\n case ActivityPanelModes.totalFMVPerUnit:\r\n graphConfig = this.createPropertyTypeConfig(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = this.getHoverPointFormat((graphConfig.series.length > 1), 2);\r\n break;\r\n case ActivityPanelModes.landFMVPerSqFt:\r\n case ActivityPanelModes.landFMVPerAcre:\r\n graphConfig = this.createLandConfigForDashboard(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = this.getHoverPointFormat((graphConfig.series.length > 1), 2);\r\n break;\r\n /* TODO for Site\r\n case ActivityPanelModes.totalTaxes:\r\n graphConfig = createTotalTaxesConfig(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = getTotalTaxHoverPointFormat((graphConfig.series.length > 1), 2);\r\n break;\r\n case \"recentAppeals\":\r\n graphConfig = createTaxSavingsConfig(graphConfig, config, chartType);\r\n graphConfig.tooltip.pointFormat = getHoverPointFormat(false, 0);\r\n break;\r\n */\r\n case 'totalTaxesUngrouped':\r\n graphConfig = this.createTotalTaxesUngroupedConfig(graphConfig, config);\r\n graphConfig.tooltip.pointFormat = this.getTotalTaxHoverPointFormat(false, 2);\r\n break;\r\n }\r\n //console.log('graphConfig', JSON.stringify(graphConfig));\r\n\r\n graphConfig.parcelFilterList = config.parcelFilterList; // we will need it if we want to load data for all years from within the table\r\n graphConfig.siteId = config.siteId;\r\n graphConfig.loadedAllYears = config.loadedAllYears;\r\n graphConfig.useLatestActualized = config.useLatestActualized;\r\n graphConfig.availableYears = config.availableYears;\r\n\r\n if (graphConfig.series.length < 2) {\r\n // there is no reason to show/hide part of the column in this case\r\n graphConfig.plotOptions.column.events = {\r\n legendItemClick: () => {\r\n return false;\r\n }\r\n };\r\n }\r\n\r\n return graphConfig;\r\n\r\n }\r\n\r\n\r\n createPropertyTypeConfig(graphConfig: GraphConfig, config: any, chartType: ActivityPanelModes | string): GraphConfig {\r\n // create series\r\n _.forEach(config.annualData, (annualYear) => {\r\n _.forEach(annualYear.fmvByPropertyType, (FMVByPropertyTypeItem) => {\r\n // if our series array does not have this property type - add it\r\n const propertyTypeIndex = _.findIndex(graphConfig.series, (o) => {\r\n return o.name == FMVByPropertyTypeItem.name;\r\n });\r\n if (propertyTypeIndex < 0) {\r\n const newSeriesItem = {\r\n name: FMVByPropertyTypeItem.name,\r\n propertyTypeSequence: this._constants.PropertyTypes[FMVByPropertyTypeItem.name].sequence,\r\n data: []\r\n };\r\n graphConfig.series.push(newSeriesItem);\r\n //propertyTypeIndex = graphConfig.series.length - 1;\r\n }\r\n });\r\n });\r\n\r\n\r\n // sorting series (property types - the one with the smallest sequence must go to the end)\r\n //\r\n graphConfig.series.sort(\r\n (item1, item2) => {\r\n return item2.propertyTypeSequence - item1.propertyTypeSequence;\r\n }\r\n );\r\n\r\n _.forEach(graphConfig.series, (seriesItem) => {\r\n seriesItem._colorIndex = graphConfig.colors.indexOf(this.getColor(chartType, seriesItem.name, false));\r\n // set NULL for each property type (if you don't do that, HighChart will assign Zero)\r\n for (let i = 0; i < graphConfig.xAxis.categories.length; i++)\r\n seriesItem.data.push({\r\n y: null\r\n });\r\n });\r\n\r\n // by now our graphConfig should have all years, property types and series initialized with 0 for every year\r\n //\r\n _.forEach(config.annualData, (annualYear) => {\r\n const annualYearIndex = graphConfig.xAxis.categories.indexOf(annualYear.year);\r\n\r\n _.forEach(annualYear.fmvByPropertyType, (FMVByPropertyTypeItem) => {\r\n // if our series does not have this property type - add it\r\n const propertyTypeIndex = _.findIndex(graphConfig.series, (o) => {\r\n return o.name == FMVByPropertyTypeItem.name;\r\n });\r\n\r\n // now we can insert data for this year and property type\r\n //\r\n graphConfig.series[propertyTypeIndex].data[annualYearIndex].y = this.getValueForPropType(FMVByPropertyTypeItem, chartType);\r\n graphConfig.series[propertyTypeIndex].data[annualYearIndex].originalValue = this.getValueForPropType(FMVByPropertyTypeItem, chartType);\r\n\r\n // now mark it as projected\r\n graphConfig.series[propertyTypeIndex].data[annualYearIndex].color = this.getColor(chartType, FMVByPropertyTypeItem.name, FMVByPropertyTypeItem.isProjected);\r\n graphConfig.series[propertyTypeIndex].data[annualYearIndex].isProjected = false;\r\n /* TODO for SITE\r\n graphConfig.series[propertyTypeIndex].data[annualYearIndex].isProjected = FMVByPropertyTypeItem.isProjected;\r\n */\r\n });\r\n });\r\n\r\n return graphConfig;\r\n\r\n }\r\n\r\n createLandConfigForDashboard(graphConfig: GraphConfig, config: any, chartType: ActivityPanelModes | string): GraphConfig {\r\n\r\n graphConfig.series = [{\r\n name: 'Land',\r\n data: []\r\n }];\r\n\r\n const seriesItem = graphConfig.series[0]; // that's the only series item we'll have here\r\n seriesItem._colorIndex = graphConfig.colors.indexOf(this.getColor(chartType, 'Land', false));\r\n for (let i = 0; i < graphConfig.xAxis.categories.length; i++)\r\n seriesItem.data.push({\r\n y: 0\r\n });\r\n\r\n // by now our graphConfig should have all years - and series data initialized with 0 for every year\r\n //\r\n _.forEach(config.annualData, (annualYear) => {\r\n const annualYearIndex = graphConfig.xAxis.categories.indexOf(annualYear.year);\r\n\r\n graphConfig.series[0].data[annualYearIndex].y = this.getLandValueForYear(annualYear, chartType);\r\n graphConfig.series[0].data[annualYearIndex].originalValue = this.getLandValueForYear(annualYear, chartType);\r\n\r\n // now mark it as projected\r\n graphConfig.series[0].data[annualYearIndex].color = this.getColor(chartType, 'Land', annualYear.fmvForLandTypeComponents.isProjected);\r\n graphConfig.series[0].data[annualYearIndex].isProjected = false;\r\n /* TODO for SITE\r\n graphConfig.series[0].data[annualYearIndex].isProjected = annualYear.fmvForLandTypeComponents.isProjected;\r\n */\r\n });\r\n\r\n return graphConfig;\r\n\r\n }\r\n\r\n createTotalTaxesUngroupedConfig(graphConfig, config) {\r\n graphConfig.series = [{\r\n name: 'Tax Liabilities',\r\n data: []\r\n }];\r\n\r\n const seriesItem = graphConfig.series[0]; // that's the only series item we'll have here\r\n seriesItem._colorIndex = graphConfig.colors.indexOf('rgba(166,206,227, 1)');\r\n for (let i = 0; i < graphConfig.xAxis.categories.length; i++) {\r\n seriesItem.data.push({\r\n y: 0\r\n });\r\n }\r\n\r\n // by now our graphConfig should have all years - and series data initialized with 0 for every year\r\n //\r\n _.forEach(config.annualData, (annualYear) => {\r\n const annualYearIndex = graphConfig.xAxis.categories.indexOf(annualYear.year);\r\n\r\n graphConfig.series[0].data[annualYearIndex].y = annualYear.totalTax;\r\n graphConfig.series[0].data[annualYearIndex].originalValue = annualYear.totalTax;\r\n\r\n // now mark it as projected\r\n graphConfig.series[0].data[annualYearIndex].color = 'rgba(166,206,227, 1)';\r\n graphConfig.series[0].data[annualYearIndex].isProjected = false;\r\n });\r\n\r\n return graphConfig;\r\n }\r\n\r\n //\r\n // END Dashboard-specific methods\r\n}\r\n","\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { AgGridExtensionsModule } from '../../Compliance/AgGrid/agGridExtensions.module';\r\nimport { WsAgGridWrapperModule } from '../../Compliance/AgGrid/AgGridWrapper/wsAgGridWrapper.module';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { UILibModule } from '../../UI-Lib/UILib.module';\r\nimport { ActivityService } from './activity.service';\r\nimport {\r\n ActivityStatusCellRendererComponent\r\n} from './Parcel-Filter/Activity-Status-Cell-Renderer/activityStatusCellRenderer.component';\r\nimport { ParcelFilterModalComponent } from './Parcel-Filter/parcelFilterModal.component';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n UILibModule,\r\n WsAgGridWrapperModule,\r\n AgGridExtensionsModule\r\n ],\r\n declarations: [\r\n ParcelFilterModalComponent,\r\n ActivityStatusCellRendererComponent\r\n ],\r\n exports: [ActivityStatusCellRendererComponent]\r\n})\r\nexport class ActivityModule {\r\n static setupModule(): void {\r\n hybridAdapterUtility.downgradeNg2Provider('sd.Activity.Service', ActivityService);\r\n }\r\n}\r\n","export class AssessmentTaxesGridData {\r\n headers: string[];\r\n rows: GridDataRow[];\r\n}\r\n\r\nexport class GridDataRow {\r\n fields: GridDataField[];\r\n isTotal: boolean;\r\n label: string;\r\n rowSubOrder: number;\r\n}\r\n\r\nexport class GridDataField {\r\n displayValue: string;\r\n isEstimated: boolean;\r\n isUnderAppeal: boolean;\r\n type: number;\r\n value: any;\r\n}\r\n\r\nexport class AssessmentTaxesCriteria {\r\n constructor() {\r\n this.showLienDate = true;\r\n this.valueDetails = 1;\r\n this.includeAssessedValueInfo = 1;\r\n this.includePPPropertyType = true;\r\n this.includeTargetValue = 2;\r\n this.includeValuationMetrics = 1;\r\n this.breakOutTaxPaymentDetails = 1;\r\n this.showPercentChange = 0;\r\n this.includePaymentDueDates = false;\r\n this.includeAlternateAssessments = true;\r\n }\r\n\r\n showLienDate: boolean;\r\n valueDetails: number;\r\n includeAssessedValueInfo: number;\r\n includePPPropertyType: boolean;\r\n includeTargetValue: number;\r\n includeValuationMetrics: number;\r\n breakOutTaxPaymentDetails: number;\r\n showPercentChange: number;\r\n includePaymentDueDates: boolean;\r\n toYear: number;\r\n fromYear: number;\r\n includeBudgetComments: boolean;\r\n includeAlternateAssessments: boolean;\r\n}\r\n\r\nexport class AssessmentTaxesOptions {\r\n constructor() {\r\n this.valueDetailsOptions = ['Property Type', 'Assessment Component', 'None'];\r\n this.includeAssessedValueInfoOptions = ['Always', 'When AV isn\\'t 100%', 'Never'];\r\n this.includeTargetValueOptions = ['Always', 'For <> 0', 'Never'];\r\n this.includeValuationMetricsOptions = ['Always', 'For Items <> 0', 'Never'];\r\n this.breakOutTaxPaymentDetailsOptions = ['Always', 'For Items <> 0', 'Never'];\r\n this.showPercentChangeOptions = ['Yes, with details', 'Yes, no details', 'No'];\r\n }\r\n\r\n valueDetailsOptions: string[];\r\n includeAssessedValueInfoOptions: string[];\r\n includeTargetValueOptions: string[];\r\n includeValuationMetricsOptions: string[];\r\n breakOutTaxPaymentDetailsOptions: string[];\r\n showPercentChangeOptions: string[];\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Routing/sd-http.service';\r\nimport { AssessmentTaxesGridData, AssessmentTaxesCriteria } from './assessment-taxes-details.models';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class AssessmentTaxesDetailsService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n getSiteYears(siteId: number): Promise {\r\n return this.http.get(`/api/parcel/years/${ siteId}`);\r\n }\r\n\r\n getSiteSummary(siteId: number, payload: AssessmentTaxesCriteria): Promise {\r\n return this.http.post(`/api/taxSummary/site/${ siteId}`, payload);\r\n }\r\n\r\n getParcelSummary(parcelId: number, payload: AssessmentTaxesCriteria): Promise {\r\n return this.http.post(`/api/taxSummary/parcel/${ parcelId}`, payload);\r\n }\r\n}\r\n","\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
0\">{{ header }}\r\n
{{ row.label }}{{ field.displayValue }}\r\n
\r\n
\r\n
\r\n

Criteria

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n to\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { AssessmentTaxesDetailsService } from './assessment-taxes-details-modal.service';\r\nimport { UserSettingsService } from '../../Account/userSettings.service';\r\nimport { AssessmentTaxesGridData, AssessmentTaxesCriteria, AssessmentTaxesOptions } from './assessment-taxes-details.models';\r\nimport { Settings } from '../../User/account.service';\r\n\r\nexport enum DataTypes {\r\n date,\r\n number,\r\n number4,\r\n money,\r\n percent,\r\n percent6,\r\n text\r\n}\r\n\r\nexport interface AssessmentTaxesDetailsModalParams {\r\n siteId?: number;\r\n parcelId?: number;\r\n selectableYears?: number[];\r\n analyticsCategory?: string;\r\n}\r\n\r\n@Component({\r\n selector: 'assessment-taxes-details-modal',\r\n templateUrl: './assessment-taxes-details-modal.component.html',\r\n styleUrls: ['./assessment-taxes-details-modal.component.scss']\r\n})\r\nexport class AssessmentTaxesDetailsModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _assessmentTaxesDetailsService: AssessmentTaxesDetailsService,\r\n private readonly _userSettingsService: UserSettingsService,\r\n private readonly _bsModalRef: BsModalRef) { }\r\n\r\n params: AssessmentTaxesDetailsModalParams;\r\n result: void;\r\n\r\n isLoading: boolean = false;\r\n savingSettings: boolean = false;\r\n dataTypes = DataTypes;\r\n criteria: AssessmentTaxesCriteria;\r\n\r\n // selections\r\n valueDetailsOptions: string[];\r\n includeAssessedValueInfoOptions: string[];\r\n includeTargetValueOptions: string[];\r\n includeValuationMetricsOptions: string[];\r\n breakOutTaxPaymentDetailsOptions: string[];\r\n showPercentChangeOptions: string[];\r\n\r\n gridData: AssessmentTaxesGridData = new AssessmentTaxesGridData();\r\n\r\n\r\n ngOnInit(): void {\r\n this.setOptions();\r\n this.criteria = this.getSavedCriteria() || new AssessmentTaxesCriteria();\r\n\r\n this.maybeGetSelectableYears()\r\n .then(() => {\r\n this.setYearDefaults();\r\n this.loadGrid();\r\n });\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n loadGrid(): void {\r\n this.isLoading = true;\r\n\r\n this.getGridData()\r\n .then((result: AssessmentTaxesGridData) => {\r\n this.gridData = result;\r\n this.isLoading = false;\r\n });\r\n }\r\n\r\n getSelectableYears(fromYear: boolean): number[] {\r\n if(fromYear) {\r\n return _.filter(this.params.selectableYears, (year) => {\r\n return year <= this.criteria.toYear;\r\n });\r\n } else {\r\n return _.filter(this.params.selectableYears, (year) => {\r\n return year >= this.criteria.fromYear;\r\n });\r\n }\r\n }\r\n\r\n async saveSettings(): Promise {\r\n this.savingSettings = true;\r\n\r\n try {\r\n let criteriaSetting: Settings = {\r\n id: 0,\r\n name: 'Assessment-Taxes-Criteria',\r\n value: this.criteria,\r\n groupId: 14,\r\n groupName: 'Assessment-Taxes-Criteria',\r\n folderId: 20,\r\n folderName: 'Assessment-Taxes-Criteria',\r\n };\r\n\r\n const existingCriteriaSettings = this._userSettingsService.getSettingsByGroup(14);\r\n\r\n if (existingCriteriaSettings.length) {\r\n criteriaSetting = _.cloneDeep(existingCriteriaSettings[0]);\r\n criteriaSetting.value = _.cloneDeep(this.criteria);\r\n }\r\n\r\n await this._userSettingsService.save(criteriaSetting);\r\n } finally {\r\n this.savingSettings = false;\r\n }\r\n }\r\n\r\n private maybeGetSelectableYears(): Promise {\r\n if (!this.params.selectableYears && this.params.siteId) {\r\n return this._assessmentTaxesDetailsService.getSiteYears(this.params.siteId)\r\n .then((result) => {\r\n this.params.selectableYears = result.reverse();\r\n });\r\n } else {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n private getGridData(): Promise {\r\n if (this.params.siteId) {\r\n return this._assessmentTaxesDetailsService.getSiteSummary(this.params.siteId, this.criteria);\r\n } else if (this.params.parcelId) {\r\n return this._assessmentTaxesDetailsService.getParcelSummary(this.params.parcelId, this.criteria);\r\n } else {\r\n console.warn('We don\\'t have an entity ID!');\r\n return Promise.resolve(new AssessmentTaxesGridData());\r\n }\r\n }\r\n\r\n private setYearDefaults(): void {\r\n if(!this.criteria.toYear || this.criteria.toYear > _.first(this.params.selectableYears)) {\r\n this.criteria.toYear = _.max(this.params.selectableYears);\r\n }\r\n if(!this.criteria.fromYear || this.criteria.fromYear < _.last(this.params.selectableYears)) {\r\n this.criteria.fromYear = this.params.selectableYears.length >= 4 ? this.params.selectableYears[3] : _.last(this.params.selectableYears);\r\n }\r\n }\r\n\r\n private setOptions(): void {\r\n _.assign(this, new AssessmentTaxesOptions());\r\n }\r\n\r\n private getSavedCriteria(): AssessmentTaxesCriteria {\r\n const existingCriteriaSettings = this._userSettingsService.getSettingsByGroup(14);\r\n\r\n if (existingCriteriaSettings.length) {\r\n return _.cloneDeep(existingCriteriaSettings[0].value);\r\n } else {\r\n return null;\r\n }\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { ProductAnalyticsService } from '../Amplitude/productAnalytics.service';\r\nimport {\r\n AssessmentTaxesDetailsModalComponent,\r\n AssessmentTaxesDetailsModalParams\r\n} from './assessment-taxes-details-modal.component';\r\n\r\n@Component({\r\n selector: 'assessment-taxes-details-icon',\r\n template: `\r\n \r\n `\r\n})\r\nexport class AssessmentTaxesDetailsIconComponent {\r\n constructor(private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _weissmanModalService: WeissmanModalService) { }\r\n\r\n @Input() siteId?: number;\r\n @Input() parcelId?: number;\r\n @Input() selectableYears?: number[];\r\n @Input() analyticsCategory?: string;\r\n\r\n showModal(): void {\r\n if (this.analyticsCategory) {\r\n this._productAnalyticsService.logEvent(`click-${this.analyticsCategory}-asmt-details-taxes`);\r\n }\r\n\r\n const params: AssessmentTaxesDetailsModalParams = {\r\n siteId: this.siteId,\r\n parcelId: this.parcelId,\r\n selectableYears: this.selectableYears,\r\n analyticsCategory: this.analyticsCategory\r\n };\r\n\r\n this._weissmanModalService.showAsync(AssessmentTaxesDetailsModalComponent, params, 'modal-lg');\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { ModalWrapperModule } from '../../UI-Lib/Modal-Wrapper/modalWrapper.module';\r\nimport { AssessmentTaxesDetailsIconComponent } from './assessment-taxes-details-icon.component';\r\nimport { AssessmentTaxesDetailsModalComponent } from './assessment-taxes-details-modal.component';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ModalWrapperModule\r\n ],\r\n declarations: [\r\n AssessmentTaxesDetailsModalComponent,\r\n AssessmentTaxesDetailsIconComponent\r\n ],\r\n exports: [AssessmentTaxesDetailsIconComponent]\r\n})\r\nexport class AssessmentTaxesDetailsModule {\r\n static setupModule() {\r\n hybridAdapterUtility.downgradeNg2Component('assessmentTaxesDetailsIcon', AssessmentTaxesDetailsIconComponent);\r\n }\r\n}\r\n","export type Constructor = new (...args: any[]) => T;\r\n\r\n// Exported for use in AngularJS components that can't use mixin\r\nexport const getYearPickerTaxYears = () => {\r\n const year = new Date().getFullYear();\r\n const years: number[] = [];\r\n for (let i = (year + 5); i >= (year - 10); i--) {\r\n years.push(i);\r\n }\r\n return years;\r\n};\r\n\r\n/**\r\n * Mixin that provides a common way to get a defined set of tax years for a year dropdown\r\n *\r\n * @param base\r\n */\r\nexport const YearPickerMixin = (base: any = class { } as T): any => {\r\n return class extends base {\r\n public readonly taxYears: number[] = getYearPickerTaxYears();\r\n\r\n constructor(...args) {\r\n super(...args);\r\n }\r\n };\r\n};\r\n","import { Injectable } from '@angular/core';\r\nimport { Subject, Observable } from 'rxjs';\r\nimport { SDHttpService } from '../Routing/sd-http.service';\r\nimport {\r\n ContractTermSaveEvent,\r\n ContractTerm,\r\n ContractTermData,\r\n Engagement,\r\n InvoiceRecipient,\r\n SiteContractTerm,\r\n FeeEscalatorUpdateDTO\r\n} from '../Contracts-Invoices/contract-invoices.model';\r\nimport { EntityType } from '../../constants.new';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class ContractsInvoicesService {\r\n constructor(private http: SDHttpService) {\r\n this.contractTermsUpdateSubject = new Subject();\r\n this.contractTermsUpdateObservable = this.contractTermsUpdateSubject.asObservable();\r\n }\r\n\r\n public contractTermsUpdateObservable: Observable;\r\n private contractTermsUpdateSubject: Subject;\r\n\r\n\r\n getContractTermsByCompany(companyId: number): Promise {\r\n return this.http.get(`/api/company/${ companyId }/contractTerms/`);\r\n }\r\n\r\n getContractTermsBySite(siteId: number): Promise {\r\n return this.http.get(`/api/site/${ siteId }/contractTerms/`);\r\n }\r\n\r\n shouldRequireConfirmationDialog(companyId: number, terms: any): Promise {\r\n return this.http.post(`/api/company/${ companyId }/contractterms/confirmationrequired`, terms);\r\n }\r\n\r\n saveCompanyContractTerms(companyId: number, terms: any): Promise {\r\n return this.http.post(`/api/company/${ companyId }/contractterms`, terms).then(result => {\r\n this.contractTermsUpdateSubject.next({\r\n entityId: companyId,\r\n entityType: EntityType.Company\r\n });\r\n return result;\r\n });\r\n }\r\n\r\n saveSiteContractTerms(siteId: number, terms: any): Promise {\r\n return this.http.post(`/api/site/${ siteId }/contractterms`, terms).then(result => {\r\n this.contractTermsUpdateSubject.next({\r\n entityId: siteId,\r\n entityType: EntityType.Site\r\n });\r\n return result;\r\n });\r\n }\r\n\r\n rollForwardYear(companyId: number, sourceYear: number, targetYear: number, rollForwardSiteOverrides: boolean): Promise {\r\n return this.http.post(`/api/company/${ companyId }/contractterms/rollforwardyear`, {\r\n sourceYear: sourceYear,\r\n targetYear: targetYear,\r\n rollForwardSiteOverrides: rollForwardSiteOverrides\r\n });\r\n }\r\n\r\n searchEngagements(searchTerm: string): Promise {\r\n return this.http.get(`/api/invoice/engagements?search=${ searchTerm}`);\r\n }\r\n\r\n getInvoiceRecipientsByEngagement(engagementId: string): Promise {\r\n return this.http.get(`/api/invoice/billingcontacts?engagementId=${ engagementId}`);\r\n }\r\n\r\n saveFeeEscalator(companyId: number, request: FeeEscalatorUpdateDTO): Promise {\r\n return this.http.put(`/api/company/${companyId}/ContractTerms/FeeEscalator`, request);\r\n }\r\n}\r\n","
\r\n

{{title}}

\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n No results\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n Engagement #\r\n
\r\n
\r\n
\r\n Client Name\r\n
\r\n
\r\n
\r\n Description\r\n
\r\n
\r\n
\r\n Engagement #\r\n
\r\n
\r\n
\r\n Client Name\r\n
\r\n
\r\n
\r\n Description\r\n
\r\n
{{engagement.engagementID}}{{engagement.clientName}}{{engagement.engagementDesc}}
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Renderer2 } from '@angular/core';\r\nimport { ContractsInvoicesService } from './contract-invoices.service';\r\nimport { Engagement } from './contract-invoices.model';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport * as _ from 'lodash';\r\nimport { TimerService } from '../../UI-Lib/Utilities/timer.service';\r\n\r\n@Component({\r\n selector: 'engagement-number-lookup-modal',\r\n templateUrl: './engagement-number-lookup-modal.component.html'\r\n})\r\nexport class EngagementNumberLookupModalComponent implements OnInit {\r\n constructor(private readonly _contractsInvoicesService: ContractsInvoicesService,\r\n public bsModalRef: BsModalRef,\r\n private readonly _renderer2: Renderer2,\r\n private readonly _toastr: ToastrService,\r\n private readonly _timer: TimerService) { }\r\n\r\n isLoading: boolean = false;\r\n searchTerm: string = '';\r\n engagementResults: Engagement[] = [];\r\n selectedEngagement: Engagement;\r\n onClose: any;\r\n initialSearch: boolean = false;\r\n title: string;\r\n\r\n ngOnInit() {\r\n this._timer.setTimeout(() => {\r\n const onElement = this._renderer2.selectRootElement('#engagementSearch');\r\n onElement.focus();\r\n });\r\n }\r\n\r\n search(): void {\r\n if(!this.searchTerm) {\r\n return;\r\n }\r\n\r\n this.initialSearch = true;\r\n this.isLoading = true;\r\n this._contractsInvoicesService.searchEngagements(this.searchTerm)\r\n .then((result: Engagement[]) => {\r\n if(result.length === 100) {\r\n this._toastr.warning('Please refine search to see more.', 'Only 100 records displayed!');\r\n }\r\n\r\n this.engagementResults = _.sortBy(result, 'engagementID');\r\n this.isLoading = false;\r\n });\r\n }\r\n\r\n selectEngagement(engagement: Engagement) {\r\n this.onClose(engagement);\r\n this.bsModalRef.hide();\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'panel-chevron',\r\n template: `\r\n
\r\n \r\n
\r\n `\r\n})\r\nexport class PanelChevronComponent {\r\n @Input() showBody: boolean;\r\n}","\r\n\r\n\r\n
\r\n % Contingency Fee\r\n
\r\n
\r\n Contingency Cap\r\n
\r\n
\r\n Fixed Fee\r\n
\r\n\r\n
\r\n","import { Component, Input, ViewChild } from '@angular/core';\r\nimport { ContractTerm } from './contract-invoices.model';\r\nimport { PopoverDirective } from 'ngx-bootstrap/popover';\r\nimport * as _ from 'lodash';\r\nimport { ContractServiceType } from '../../constants.new';\r\n\r\n@Component({\r\n selector: 'choose-term-popover',\r\n templateUrl: './choose-term-popover.component.html'\r\n})\r\nexport class ChooseTermPopoverComponent {\r\n @Input() selectedTerm: ContractTerm;\r\n @ViewChild('chooseTerm', { static: true }) public chooseTerm: PopoverDirective;\r\n termToEdit: ContractTerm;\r\n ContractServiceType = ContractServiceType;\r\n\r\n lookupTerm(): void {\r\n this.termToEdit = _.cloneDeep(this.selectedTerm);\r\n\r\n if(!this.termToEdit.contingencyPct) {\r\n this.termToEdit.contingencyCap = null;\r\n }\r\n\r\n this.chooseTerm.show();\r\n }\r\n\r\n saveTerm(): void {\r\n this.selectedTerm.contingencyPct = this.termToEdit.contingencyPct;\r\n this.selectedTerm.contingencyCap = this.termToEdit.contingencyCap;\r\n this.selectedTerm.flatFee = this.termToEdit.flatFee;\r\n this.selectedTerm.hourlyRate = this.termToEdit.hourlyRate;\r\n }\r\n}","import { Component, Input } from '@angular/core';\r\nimport { ContractTerm, TermItem } from './contract-invoices.model';\r\n\r\n@Component({\r\n selector: 'term-rates-and-fees',\r\n template: `\r\n {{usePercent ? (term.contingencyPct | percent: '1.1-2') : (term.contingencyPct)}}% contingency fee\r\n capped at {{term.contingencyCap | currency:'USD'}};\r\n {{term.flatFee | currency:'USD'}} fixed fee;\r\n {{term.hourlyRate | currency:'USD'}} hourly rate\r\n `\r\n})\r\nexport class TermRatesAndFeesComponent {\r\n @Input() term: ContractTerm | TermItem;\r\n @Input() usePercent: boolean;\r\n}\r\n","
\r\n\t
\r\n\t\t\r\n\t\t

Contract Terms

\r\n\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\tTax Year:\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t\t\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t
\r\n\t
\r\n\t
\r\n\t\t
\r\n\t\t\t\r\n\t\t
\r\n\t\t
\r\n
\r\n \r\n \r\n Annual Fixed Fee Escalator: {{allData.feeEscalator * 100 | number: '1.2' }}%\r\n \r\n \r\n Configure Annual Fixed Fee Escalator\r\n \r\n \r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n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t\r\n\t\t
\r\n\t
\r\n
\r\n\r\n
\r\n\t
\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t

Choose Year

\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t\t
\r\n\t\t\t\t
\r\n\t\t\t\t\t
\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\r\n
\r\n
\r\n NOTE: A {{allData.feeEscalator * 100 | number: '1.2-2'}}% annual fixed fee escalator will be applied to the following services:\r\n
    \r\n
  • \r\n {{getContractServiceTypename(serviceType)}}\r\n
  • \r\n
\r\n
\r\n\t\t\t\t\t
\r\n\t\t\t\t
\r\n\t\t\t
\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t
\r\n\t
\r\n
\r\n\r\n
\r\n\t
\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t

Configure Fee Escalator

\r\n\t\t\t\t\r\n\t\t\t
\r\n
\r\n
\r\n
\r\n Apply Fixed Fee Escalator to:\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n\t\t\t
\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t
\r\n\t
\r\n
\r\n\r\n","import { Component, Input, ViewChild, OnInit, OnDestroy } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { YearPickerMixin } from '../../UI-Lib/Mixins';\r\nimport { ProductAnalyticsService } from '../Amplitude/productAnalytics.service';\r\nimport { ContractsInvoicesService } from './contract-invoices.service';\r\nimport { ContractTerm, ContractTermData, Engagement } from './contract-invoices.model';\r\nimport { Constants, ContractServiceType } from '../../constants.new';\r\nimport {\r\n MessageBoxService,\r\n MessageBoxButtons,\r\n MessageBoxResult\r\n} from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { ModalDirective, BsModalService } from 'ngx-bootstrap/modal';\r\nimport { EngagementNumberLookupModalComponent } from './engagement-number-lookup-modal.component';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Decimal } from 'decimal.js';\r\nimport { RestrictService, Roles } from '../Permissions/restrict.service';\r\nimport { TimerService } from '../../UI-Lib/Utilities/timer.service';\r\nimport { CommentsModalService } from '../../Comments/commentsModal.service';\r\nimport { FeatureFlagsService } from '../FeatureFlags/feature-flags-service';\r\n//import * as _ from 'lodash';\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'contract-terms-panel-company',\r\n templateUrl: './contract-terms-panel-company.component.html'\r\n})\r\nexport class ContractTermsPanelCompanyComponent extends YearPickerMixin() implements OnInit, OnDestroy {\r\n constructor(private readonly _contractsInvoicesService: ContractsInvoicesService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _modalService: BsModalService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _commentsModalService: CommentsModalService,\r\n private readonly _constants: Constants,\r\n private readonly _timer: TimerService,\r\n private readonly _featureFlagService: FeatureFlagsService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {\r\n super();\r\n }\r\n\r\n @Input() entity: { id: number, name: string, newAllowed: boolean, type: string };\r\n @Input() isTopLevel: boolean;\r\n @ViewChild('addTermYearModal', { static: true }) public addTermYearModal: ModalDirective;\r\n @ViewChild('configureFeeEscalatorModal', { static: true }) public configureFeeEscalatorModal: ModalDirective;\r\n\r\n isLoading: boolean = false;\r\n hasViewPermission: boolean = false;\r\n hasEditPermission: boolean = false;\r\n showBody: boolean = false;\r\n isEditMode: boolean = false;\r\n editLock: boolean;\r\n topLevelYears: number[] = [];\r\n subsidiaryYears: number[] = [];\r\n selectedYear: number;\r\n propertyTypes: any[];\r\n allData: ContractTermData;\r\n topLevelCompanyContractTerms: ContractTerm[];\r\n currentContractTerms: ContractTerm[];\r\n useTopLevelCompanyTerms: boolean = false;\r\n addingYear: boolean = false;\r\n savingFeeEscalator: boolean = false;\r\n yearsToAdd: { year: number, disabled: boolean }[];\r\n yearToAdd: number;\r\n rollForwardSiteOverrides: boolean;\r\n bsModalRef: BsModalRef;\r\n recentYears: number[];\r\n currentYear: number = new Date().getFullYear();\r\n services: { id: number, name: string, fullDisplayName: string }[];\r\n ContractServiceType = ContractServiceType;\r\n showFeeEscalator: boolean;\r\n newEscalatorServiceTypes: number[] = [];\r\n newFeeEscalator: number;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this.hasViewPermission = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n this.hasEditPermission = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT);\r\n this.services = _.chain(this._constants.ContractServiceTypes)\r\n .toArray()\r\n .sortBy('name')\r\n .value();\r\n\r\n if (!this._featureFlagService.featureFlags.enableAppealLitigation) {\r\n const litigationIndex = this.services.findIndex(x => x.id === ContractServiceType.Litigation);\r\n this.services.splice(litigationIndex, 1);\r\n }\r\n\r\n this._navigationService.globalEditMode$.pipe(takeUntil(this._destroy$)).subscribe(editMode => {\r\n this.editLock = editMode;\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n expandOrCollapse(): void {\r\n if (this.isEditMode) {\r\n return;\r\n }\r\n\r\n this.showBody = !this.showBody;\r\n this._productAnalyticsService.logEvent('company-toggle-panel', {\r\n panel: 'Contract Terms',\r\n isOpen: this.showBody\r\n });\r\n\r\n if (this.showBody) {\r\n this.loadPanel();\r\n }\r\n }\r\n\r\n loadPanel(): void {\r\n this.propertyTypes = _.map(this._constants.PropertyTypeNames, (name: string, id: number) => {\r\n return {\r\n name: name,\r\n propertyTypeId: Number(id)\r\n };\r\n });\r\n\r\n this.recentYears = _.range(this.currentYear - 10, this.currentYear + 6).reverse() as number[];\r\n\r\n this.isLoading = true;\r\n this._contractsInvoicesService.getContractTermsByCompany(this.entity.id)\r\n .then((result: ContractTermData) => {\r\n this.populateContractTermData(result);\r\n this.isLoading = false;\r\n });\r\n }\r\n\r\n goToEditMode(): void {\r\n this.isEditMode = true;\r\n this._navigationService.enableNavWarning('You have unsaved changes. Are you sure you want to leave this page?');\r\n this._productAnalyticsService.logEvent('edit-contract-terms');\r\n }\r\n\r\n addTerm(): void {\r\n const newTerm: ContractTerm = {\r\n contractTermDetailId: null,\r\n contractServiceTypeId: _.head(this.services).id,\r\n contractServiceTypeName: _.head(this.services).name,\r\n propertyTypeId: null,\r\n propertyTypeName: null,\r\n taxYear: this.getSelectedYear(this.subsidiaryYears),\r\n engagement: '',\r\n siteDefault: true,\r\n contingencyPct: null,\r\n contingencyCap: null,\r\n flatFee: null,\r\n hourlyRate: null,\r\n remarks: null,\r\n rowVersion: '',\r\n contractTermRowVersion: '',\r\n efAction: 'add'\r\n };\r\n\r\n this.currentContractTerms.push(newTerm);\r\n }\r\n\r\n //this.selectedYear = old\r\n //e = new\r\n yearChanged(): void {\r\n const oldVal = this.selectedYear;\r\n\r\n if (this.areTermsDirty()) {\r\n this._messageBoxService.open({\r\n message: 'Discard changes for current changes and switch year selection?',\r\n buttons: MessageBoxButtons.OKCancel\r\n })\r\n .then((result: number) => {\r\n if (result === MessageBoxResult.OK) {\r\n this.getDataForYear();\r\n } else {\r\n this._timer.setTimeout(() => {\r\n this.selectedYear = oldVal;\r\n });\r\n }\r\n });\r\n } else {\r\n this._timer.setTimeout(() => {\r\n this.getDataForYear();\r\n });\r\n }\r\n\r\n }\r\n\r\n removeTerm(term: ContractTerm, index: number): void {\r\n if (term.efAction === 'add') {\r\n // We can't use the object with lodash for removal since an un-saved object is identical and\r\n // lodash purges them all with a _.remove\r\n _.pullAt(this.currentContractTerms, [index]);\r\n } else {\r\n term.efAction = 'delete';\r\n }\r\n }\r\n\r\n async rollForwardYear(): Promise {\r\n if (await this.confirmAutoSave()) {\r\n this.launchAddYearModal();\r\n }\r\n }\r\n\r\n async configureFeeEscalator(): Promise {\r\n if (await this.confirmAutoSave()) {\r\n this.launchConfigureFeeEscalatorModal();\r\n }\r\n }\r\n\r\n addYear(): void {\r\n this.addingYear = true;\r\n this._contractsInvoicesService.rollForwardYear(this.entity.id, this.selectedYear, this.yearToAdd, this.rollForwardSiteOverrides)\r\n .then((newYearData: ContractTerm[]) => {\r\n this.addingYear = false;\r\n this.allData.currentContractTerms = _.union(this.allData.currentContractTerms, newYearData) as ContractTerm[];\r\n\r\n this.populateYearsDropdown();\r\n this.selectedYear = this.yearToAdd;\r\n\r\n this.addTermYearModal.hide();\r\n this.getDataForYear();\r\n this.isEditMode = false;\r\n this._navigationService.disableNavWarning();\r\n }).catch(() => {\r\n this.addingYear = false;\r\n });\r\n }\r\n\r\n saveFeeEscalator(): Promise {\r\n this.savingFeeEscalator = true;\r\n return this._contractsInvoicesService.saveFeeEscalator(this.entity.id, {\r\n fixedFeeEscalator: this.newFeeEscalator / 100,\r\n contractServiceTypes: this.newEscalatorServiceTypes,\r\n companyRowVersion: this.allData.companyRowVersion\r\n }).then(() => {\r\n this.configureFeeEscalatorModal.hide();\r\n this.isLoading = true;\r\n this._contractsInvoicesService.getContractTermsByCompany(this.entity.id).then((result: ContractTermData) => {\r\n this.populateContractTermData(result);\r\n this.isLoading = false;\r\n }).catch(() => {\r\n this.isLoading = false;\r\n });\r\n this.savingFeeEscalator = false;\r\n }).catch(err => {\r\n this.savingFeeEscalator = false;\r\n });\r\n }\r\n\r\n cancelEdit(): void {\r\n this.getDataForYear();\r\n\r\n this.isEditMode = false;\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n savePanel(stayInEditMode?: boolean): Promise {\r\n const errorMessage = this.panelIsInvalid();\r\n if (errorMessage) {\r\n this._toastr.error('Error!', errorMessage);\r\n return;\r\n }\r\n\r\n const saveBody: any = {\r\n useTopLevelCompanyTerms: this.useTopLevelCompanyTerms,\r\n ContractTerms: this.useTopLevelCompanyTerms ? this.topLevelCompanyContractTerms : this.getCurrentTermsForSave(),\r\n efAction: this.useTopLevelCompanyTerms !== this.allData.useTopLevelCompanyTerms ? 'update' : null,\r\n companyRowVersion: this.allData.companyRowVersion\r\n };\r\n\r\n this.isLoading = true;\r\n return this._contractsInvoicesService.shouldRequireConfirmationDialog(this.entity.id, saveBody)\r\n .then((requireConfirmationDialog: boolean) => {\r\n if (requireConfirmationDialog) {\r\n return this._messageBoxService.open({\r\n message: 'Overrides will be removed',\r\n buttons: MessageBoxButtons.OKCancel\r\n })\r\n .then((result: number) => {\r\n if (result === MessageBoxResult.OK) {\r\n return this.saveData(saveBody, stayInEditMode);\r\n }\r\n\r\n this.cancelEdit();\r\n });\r\n }\r\n\r\n return this.saveData(saveBody, stayInEditMode);\r\n })\r\n .catch(() => {\r\n this.isLoading = false;\r\n });\r\n }\r\n\r\n lookupEngagement(term: ContractTerm): void {\r\n this.bsModalRef = this._modalService.show(EngagementNumberLookupModalComponent, { class: 'modal-lg' });\r\n this.bsModalRef.content.title = 'Lookup Engagement Number';\r\n\r\n this.bsModalRef.content.onClose = (engagement: Engagement) => {\r\n term.engagement = engagement.engagementID;\r\n };\r\n }\r\n\r\n termsAreEditable(): boolean {\r\n return this.isEditMode && !this.useTopLevelCompanyTerms;\r\n }\r\n\r\n showRollForwardYearButton(): boolean {\r\n return this.termsAreEditable() && this.selectedYear !== 0 && _.some(this.currentContractTerms, (term: ContractTerm) => {\r\n return term.contractTermDetailId && term.efAction !== 'delete';\r\n }) as boolean;\r\n }\r\n\r\n useTopLevelCompanyChanged(): void {\r\n this.setSelectedYear();\r\n this.getDataForYear();\r\n }\r\n\r\n serviceTypeChanged(newServiceType: string, term: ContractTerm): void {\r\n if (Number(newServiceType) != ContractServiceType.Appeal && Number(newServiceType) != ContractServiceType.Litigation) {\r\n term.propertyTypeId = null;\r\n term.contingencyCap = null;\r\n term.contingencyPct = null;\r\n }\r\n\r\n if (Number(newServiceType) == ContractServiceType.Misc || Number(newServiceType) == ContractServiceType.Hourly) {\r\n term.flatFee = null;\r\n }\r\n }\r\n\r\n async showComments(term: ContractTerm, readOnly: boolean): Promise {\r\n const newRemarks = await this._commentsModalService.openAddCommentModal({\r\n title: 'Contract Term Remarks',\r\n commentBody: term.remarks,\r\n allowBlank: false,\r\n readOnly: readOnly,\r\n entityTypeName: 'company',\r\n entityId: this.entity.id\r\n });\r\n\r\n if (!readOnly && newRemarks !== undefined) {\r\n term.remarks = newRemarks;\r\n }\r\n }\r\n\r\n getContractServiceTypename(serviceTypeId): string {\r\n return this.services\r\n .filter(s => s.id == serviceTypeId)\r\n .map(t => t.fullDisplayName || t.name)[0];\r\n }\r\n\r\n serviceTypeSelected(serviceTypeId: number): boolean {\r\n return this.newEscalatorServiceTypes.some(t => t == serviceTypeId);\r\n }\r\n\r\n checkedServiceType(serviceTypeId: number, checked: boolean): void {\r\n console.log('checked', checked);\r\n if (checked) {\r\n this.newEscalatorServiceTypes.push(serviceTypeId);\r\n } else {\r\n const index = this.newEscalatorServiceTypes.findIndex(t => t == serviceTypeId);\r\n if (!(index >= 0)) {\r\n // Sanity check\r\n throw new Error(`Array unexpectedly missing value: ${serviceTypeId}`);\r\n }\r\n\r\n this.newEscalatorServiceTypes.splice(index, 1);\r\n }\r\n }\r\n\r\n //\r\n // Private functions\r\n //\r\n\r\n private async confirmAutoSave(): Promise {\r\n if (this.isPanelDirty()) {\r\n const msgBoxResult = await this._messageBoxService.open({\r\n message: 'Current Contract Terms will be Saved',\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n if (msgBoxResult === MessageBoxResult.OK) {\r\n await this.savePanel(true);\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n return true;\r\n }\r\n\r\n private panelIsInvalid(): string {\r\n const missingTerms: boolean = _.some(this.currentContractTerms, (term: ContractTerm) => {\r\n return !term.contingencyPct && !term.flatFee && !term.hourlyRate && term.contractServiceTypeId !== ContractServiceType.Misc && term.contractServiceTypeId !== ContractServiceType.Hourly;\r\n }) as boolean;\r\n\r\n if (missingTerms) {\r\n return 'At least one term is missing fee details.';\r\n }\r\n\r\n const negativeAmounts = _.some(this.currentContractTerms, (term: ContractTerm) => {\r\n return [term.contingencyPct, term.contingencyCap, term.flatFee, term.hourlyRate].some(v => v < 0);\r\n });\r\n\r\n if (negativeAmounts) {\r\n return 'Amounts cannot be negative';\r\n }\r\n\r\n const missingYear = _.some(this.currentContractTerms, (term: ContractTerm) => {\r\n return term.taxYear === 0 || !term.taxYear;\r\n });\r\n\r\n if (missingYear) {\r\n return 'At least one term is missing a tax year.';\r\n }\r\n\r\n const invalidServiceYears: any = _.chain(this.currentContractTerms)\r\n .filter((term: ContractTerm) => {\r\n return (term.contractServiceTypeId == ContractServiceType.Misc || term.contractServiceTypeId == ContractServiceType.Hourly);\r\n })\r\n .groupBy((term: ContractTerm) => {\r\n return `${term.contractServiceTypeId}-${term.taxYear}`;\r\n })\r\n .some(grouping => grouping.length > 1)\r\n .value();\r\n\r\n if (invalidServiceYears) {\r\n return 'Only one Misc contract term can be created for a given year';\r\n }\r\n\r\n const percentInvalid: boolean = _.some(this.currentContractTerms, (term: ContractTerm) => {\r\n return term.contingencyPct < 0 || term.contingencyPct > 100;\r\n });\r\n\r\n return percentInvalid ? 'Contingency Fee must be between 0 and 100%' : '';\r\n\r\n }\r\n\r\n private getCurrentTermsForSave(): ContractTerm[] {\r\n return _.chain(this.currentContractTerms)\r\n .cloneDeep()\r\n .map((term: ContractTerm) => {\r\n if (term.contingencyPct) {\r\n term.contingencyPct = new Decimal(term.contingencyPct).dividedBy(100).toNumber();\r\n }\r\n\r\n if (!term.efAction) {\r\n const foundTerm: ContractTerm = _.find(this.allData.currentContractTerms, { contractTermDetailId: term.contractTermDetailId }) as ContractTerm;\r\n term.efAction = !_.isEqual(foundTerm, term) ? 'update' : null;\r\n }\r\n\r\n return term;\r\n })\r\n .value() as ContractTerm[];\r\n }\r\n\r\n private saveData(saveBody: any, stayInEditMode: boolean): Promise {\r\n return this._contractsInvoicesService.saveCompanyContractTerms(this.entity.id, saveBody)\r\n .then((result: ContractTermData) => {\r\n this.populateContractTermData(result);\r\n\r\n this.isLoading = false;\r\n this.isEditMode = !!stayInEditMode;\r\n if (!stayInEditMode) {\r\n this._navigationService.disableNavWarning();\r\n }\r\n })\r\n .catch(() => {\r\n this.isLoading = false;\r\n });\r\n }\r\n\r\n private populateContractTermData(data: ContractTermData): void {\r\n this.allData = data;\r\n this.useTopLevelCompanyTerms = this.allData.useTopLevelCompanyTerms;\r\n\r\n this.populateYearsDropdown();\r\n this.setSelectedYear();\r\n this.getDataForYear();\r\n }\r\n\r\n private populateYearsDropdown(): void {\r\n this.topLevelYears = this.getYears(this.allData.topLevelCompanyContractTerms);\r\n this.subsidiaryYears = this.getYears(this.allData.currentContractTerms);\r\n }\r\n\r\n private setSelectedYear(): void {\r\n this.selectedYear = this.useTopLevelCompanyTerms ? this.getSelectedYear(this.topLevelYears) : this.getSelectedYear(this.subsidiaryYears);\r\n }\r\n\r\n private getYears(terms: ContractTerm[]): number[] {\r\n return _.chain(terms)\r\n .map('taxYear')\r\n .uniq()\r\n .sortBy()\r\n .reverse()\r\n .value() as number[];\r\n }\r\n\r\n private getSelectedYear(years: number[]): number {\r\n if (years.length) {\r\n const selectedYear: number = _.includes(years, this.selectedYear) ? this.selectedYear : null;\r\n const currentYear: number = _.includes(years, this.currentYear) ? this.currentYear : null;\r\n\r\n return selectedYear || currentYear || _.maxBy(years) as number;\r\n } else {\r\n return 0;\r\n }\r\n }\r\n\r\n private getDataForYear(): void {\r\n this.selectedYear = Number(this.selectedYear);\r\n\r\n this.topLevelCompanyContractTerms = this.prepareDataForView(this.allData.topLevelCompanyContractTerms);\r\n this.currentContractTerms = this.prepareDataForView(this.allData.currentContractTerms);\r\n }\r\n\r\n private prepareDataForView(contractTerms: ContractTerm[]): ContractTerm[] {\r\n return _.chain(contractTerms)\r\n .filter((term: ContractTerm) => {\r\n return this.selectedYear === 0 || term.taxYear == this.selectedYear;\r\n })\r\n .cloneDeep()\r\n .map((term: ContractTerm) => {\r\n if (term.contingencyPct) {\r\n term.contingencyPct = new Decimal(term.contingencyPct).times(100).toNumber();\r\n }\r\n return term;\r\n })\r\n .orderBy('taxYear', 'desc')\r\n .value() as ContractTerm[];\r\n }\r\n\r\n private launchAddYearModal(): void {\r\n this.showFeeEscalator = this.allData.feeEscalator !== null && this.allData.escalatorServiceTypes.length > 0;\r\n this.yearsToAdd = this.taxYears.map((year: number) => {\r\n return {\r\n year: year,\r\n disabled: this.currentContractTerms.some(x => x.taxYear === year)\r\n };\r\n });\r\n\r\n const lastDisabledYearIndex: number = _.findLastIndex(this.yearsToAdd, 'disabled') as number;\r\n\r\n if (this.yearsToAdd[lastDisabledYearIndex - 1]) {\r\n this.yearToAdd = this.yearsToAdd[lastDisabledYearIndex - 1].year;\r\n } else {\r\n this.yearToAdd = _.maxBy(this.yearsToAdd, (option) => {\r\n return option.disabled ? 0 : option.year;\r\n }).year;\r\n }\r\n\r\n this.addTermYearModal.show();\r\n }\r\n\r\n private launchConfigureFeeEscalatorModal(): void {\r\n if (this.allData.feeEscalator) {\r\n this.newFeeEscalator = this.allData.feeEscalator * 100;\r\n this.newEscalatorServiceTypes = Array.prototype.slice.apply(this.allData.escalatorServiceTypes);\r\n } else {\r\n this.newFeeEscalator = 0;\r\n this.newEscalatorServiceTypes = Array.prototype.slice.apply(this.services.map(s => s.id));\r\n }\r\n this.configureFeeEscalatorModal.show();\r\n }\r\n\r\n private isPanelDirty(): boolean {\r\n return this.useTopLevelCompanyTerms !== this.allData.useTopLevelCompanyTerms || this.areTermsDirty();\r\n }\r\n\r\n private areTermsDirty(): boolean {\r\n return !this.useTopLevelCompanyTerms && this.aContractTermHasChanged();\r\n }\r\n\r\n private aContractTermHasChanged(): boolean {\r\n return _.some(this.currentContractTerms, (term: ContractTerm) => {\r\n if (term.efAction) {\r\n return true;\r\n }\r\n\r\n const copiedTerm: ContractTerm = _.cloneDeep(term) as ContractTerm;\r\n if (copiedTerm.contingencyPct) {\r\n copiedTerm.contingencyPct = new Decimal(copiedTerm.contingencyPct).dividedBy(100).toNumber();\r\n }\r\n const foundTerm: ContractTerm = _.find(this.allData.currentContractTerms, { contractTermDetailId: copiedTerm.contractTermDetailId }) as ContractTerm;\r\n\r\n return !_.isEqual(foundTerm, copiedTerm) as boolean;\r\n }) as boolean;\r\n }\r\n}\r\n","
\r\n
\r\n \r\n

Contract Terms

\r\n\r\n
\r\n
\r\n Tax Year:\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
ServiceProperty TypeTax YearTermsEngagement #
{{term.service}}{{term.propertyType}}{{term.taxYear}}\r\n
N/A
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n {{term.currentTermItem.engagement}}\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input } from '@angular/core';\r\nimport { ContractsInvoicesService } from './contract-invoices.service';\r\nimport { SiteContractTerm } from './contract-invoices.model';\r\nimport { MessageBoxService, MessageBoxButtons, MessageBoxResult } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { RestrictService, Roles } from '../Permissions/restrict.service';\r\nimport { TimerService } from '../../UI-Lib/Utilities/timer.service';\r\nimport { CommentsModalService } from '../../Comments/commentsModal.service';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'contract-terms-panel-site',\r\n templateUrl: './contract-terms-panel-site.component.html'\r\n})\r\nexport class ContractTermsPanelSiteComponent {\r\n constructor(private readonly _contractsInvoicesService: ContractsInvoicesService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _commentsModalService: CommentsModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _timer: TimerService) {\r\n this.hasViewPermission = _restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n this.hasEditPermission = _restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT);\r\n }\r\n @Input() entity: { id: number, name: string, newAllowed: boolean, type: string, hasWritePermission: boolean };\r\n\r\n isLoading: boolean = false;\r\n hasViewPermission: boolean = false;\r\n hasEditPermission: boolean = false;\r\n showBody: boolean = false;\r\n isEditMode: boolean = false;\r\n contractTermYears: number[] = [];\r\n selectedYear: number;\r\n allData: SiteContractTerm[];\r\n contractTerms: SiteContractTerm[];\r\n currentYear: number = new Date().getFullYear();\r\n\r\n expandOrCollapse(): void {\r\n if(this.isEditMode) {\r\n return;\r\n }\r\n\r\n this.showBody = !this.showBody;\r\n\r\n if(this.showBody) {\r\n this.loadPanel();\r\n }\r\n }\r\n\r\n loadPanel(): void {\r\n this.isLoading = true;\r\n this._contractsInvoicesService.getContractTermsBySite(this.entity.id)\r\n .then((result: SiteContractTerm[]) => {\r\n this.populateContractTermData(result);\r\n this.isLoading = false;\r\n });\r\n\r\n }\r\n\r\n showComments(term: SiteContractTerm): void {\r\n this._commentsModalService.openAddCommentModal({\r\n title: 'Contract Term Remarks',\r\n commentBody: term.currentTermItem.remarks,\r\n allowBlank: true,\r\n readOnly: true,\r\n entityTypeName: 'site',\r\n entityId: this.entity.id\r\n });\r\n }\r\n\r\n getDataForYear(): void {\r\n this.selectedYear = Number(this.selectedYear);\r\n\r\n this.contractTerms = _.chain(this.allData)\r\n .filter((term: SiteContractTerm) => {\r\n return this.selectedYear === 0 || term.taxYear == this.selectedYear;\r\n })\r\n .cloneDeep()\r\n .map((term: SiteContractTerm) => {\r\n if(term.currentTermItem) {\r\n term.currentTermItem = _.find(term.availableTermItems, {termDetailId: term.currentTermItem.termDetailId});\r\n }\r\n\r\n return term;\r\n })\r\n .value() as SiteContractTerm[];\r\n }\r\n\r\n goToEditMode(): void {\r\n this.isEditMode = true;\r\n }\r\n\r\n cancelEdit(): void {\r\n this.getDataForYear();\r\n\r\n this.isEditMode = false;\r\n }\r\n\r\n savePanel(): void {\r\n this.isLoading = true;\r\n this._contractsInvoicesService.saveSiteContractTerms(this.entity.id, this.contractTerms)\r\n .then((result: SiteContractTerm[]) => {\r\n this.populateContractTermData(result);\r\n\r\n this.isLoading = false;\r\n this.isEditMode = false;\r\n })\r\n .catch((error) => {\r\n this.isLoading = false;\r\n });\r\n\r\n }\r\n\r\n //this.selectedYear = old\r\n //e = new\r\n yearChanged(e): void {\r\n const oldVal = this.selectedYear;\r\n\r\n if (this.aContractTermHasChanged()) {\r\n this._messageBoxService.open({\r\n message: 'Discard changes for current changes and switch year selection?',\r\n buttons: MessageBoxButtons.OKCancel\r\n })\r\n .then((result: number) => {\r\n if (result === MessageBoxResult.OK) {\r\n this.getDataForYear();\r\n } else {\r\n this._timer.setTimeout(() => {\r\n this.selectedYear = oldVal;\r\n });\r\n }\r\n });\r\n } else {\r\n this._timer.setTimeout(() => {\r\n this.getDataForYear();\r\n });\r\n }\r\n\r\n }\r\n\r\n\r\n isTermNotSiteDefault(term: SiteContractTerm) {\r\n if(term.currentTermItem) {\r\n return term.currentTermItem.termDetailId !== term.companySiteDefaultTermId;\r\n } else {\r\n return term.companySiteDefaultTermId;\r\n }\r\n }\r\n\r\n private populateContractTermData(data: SiteContractTerm[]): void {\r\n this.allData = data;\r\n\r\n this.contractTermYears = this.populateYearsDropdown();\r\n this.selectedYear = this.getSelectedYear();\r\n this.getDataForYear();\r\n }\r\n\r\n private populateYearsDropdown(): number [] {\r\n return _.chain(this.allData)\r\n .map('taxYear')\r\n .uniq()\r\n .sortBy()\r\n .reverse()\r\n .value() as number[];\r\n }\r\n\r\n private getSelectedYear(): number {\r\n if (this.contractTermYears.length) {\r\n const selectedYear: number = _.includes(this.contractTermYears, this.selectedYear) ? this.selectedYear : null;\r\n const currentYear: number = _.includes(this.contractTermYears, this.currentYear) ? this.currentYear : null;\r\n\r\n return selectedYear || currentYear || _.maxBy(this.contractTermYears) as number;\r\n } else {\r\n return 0;\r\n }\r\n }\r\n\r\n private aContractTermHasChanged(): boolean {\r\n return _.some(this.contractTerms, (term: SiteContractTerm) => {\r\n const foundTerm: SiteContractTerm = _.find(this.allData, { termId: term.termId }) as SiteContractTerm;\r\n\r\n return !_.isEqual(foundTerm, term) as boolean;\r\n }) as boolean;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'ws-save-as-icon',\r\n templateUrl: './saveAsIcon.component.html',\r\n styleUrls: ['./saveAsIcon.component.scss']\r\n})\r\nexport class SaveAsIconComponent {\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { StateSummary } from './state.model';\r\nimport { CacheManagerService } from '../Routing/cache-manager.service';\r\nimport { StateRepository } from '../../Core-Repositories';\r\n\r\n@Injectable()\r\nexport class StateService {\r\n constructor(\r\n private readonly _cacheManagerService: CacheManagerService,\r\n private readonly _stateRepository: StateRepository\r\n ) {}\r\n\r\n private _navigatedFrom: string;\r\n private readonly BASE_URL = '/api/state/';\r\n\r\n set navigatedFrom(location: string) {\r\n this._navigatedFrom = location;\r\n }\r\n\r\n get navigatedFrom(): string {\r\n return this._navigatedFrom;\r\n }\r\n\r\n async getSummary(): Promise {\r\n const states = await this._cacheManagerService.buildCacheGet(`${this.BASE_URL}summary`, false);\r\n // This map is to support values added by the old state service that are used in the older code\r\n return states.map(x => ({ ...x, value: x.abbr, label: x.abbr}));\r\n }\r\n\r\n getById(stateId: number): Promise {\r\n return lastValueFrom(this._stateRepository.getById(stateId));\r\n }\r\n}\r\n","
\r\n \r\n \r\n \r\n \r\n {{placeholder}}\r\n {{selectedSummary}}\r\n \r\n
    \r\n
  • \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
  • \r\n
  • \r\n \r\n \r\n \r\n
  • \r\n
  • \r\n \r\n \r\n \r\n
  • \r\n
  • \r\n \r\n \r\n \r\n
  • \r\n
\r\n
\r\n","import { Component, forwardRef, Input, Renderer2, ElementRef, ViewChild, Output, EventEmitter } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { SelectSearch } from '../Select/select.interface';\r\nimport { TimerService } from '../Utilities';\r\n\r\nconst noop = (values: any[], searchValue: string) => [];\r\n\r\n/**\r\n * Multi-select dropdown\r\n *\r\n * Allows the user to select multiple items from the dropdown and displays a summary of the selections\r\n *\r\n * Tied into ControlValueAccessor for integration with native Angular FormControls and ngModel\r\n *\r\n * The input options can be any model. The properties to use as the selectors for each option in the dropdown are set using\r\n * labelProperty and valueProperty.\r\n *\r\n * Example usage:\r\n * \r\n * \r\n *\r\n */\r\n@Component({\r\n selector: 'ws-multi-select',\r\n templateUrl: './multiSelect.component.html',\r\n styleUrls: ['./multiSelect.component.scss'],\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => MultiSelectComponent),\r\n multi: true\r\n }\r\n ],\r\n})\r\nexport class MultiSelectComponent implements ControlValueAccessor {\r\n constructor(private _timerService: TimerService,\r\n private _renderer2: Renderer2) {\r\n }\r\n\r\n @Input() placeholder: string;\r\n @Input() labelProperty: string = 'label';\r\n @Input() valueProperty: string = 'value';\r\n @Input() isPrimitive: boolean;\r\n @Input() objectIsValue: boolean;\r\n @Input() useSemicolons: boolean;\r\n @Input() isDropup: boolean;\r\n @Input() canSearch: boolean;\r\n @Input() searchType: 'exact' | 'fuzzy' | 'substring' | 'state' | 'custom' = 'fuzzy';\r\n @Input() set options(options: any[]) {\r\n this.dropdownOptions = options;\r\n this.searchableOptions = [...options];\r\n this._updateValue(this.value);\r\n }\r\n @Input() hideSelectAll: boolean = false;\r\n @Input() hasDeselectAll: boolean = false;\r\n\r\n @Output() selectedOptionsChanged: EventEmitter = new EventEmitter();\r\n\r\n @ViewChild('searchInput') searchInput: ElementRef;\r\n @ViewChild('dropdown') dropdown: ElementRef;\r\n\r\n value: any[];\r\n disabled: boolean;\r\n open: boolean;\r\n selectedSummary: string;\r\n dropdownOptions: any[] = [];\r\n searchableOptions: any[] = [];\r\n selectedOptions: any[] = [];\r\n\r\n searchValue: string;\r\n\r\n private _search: SelectSearch = {\r\n exact: (values: any[], searchValue: string) => values.filter(o => {\r\n const value = (`${(this.isPrimitive) ? o : o[this.labelProperty]}`).toLowerCase();\r\n return (value) ? value.substring(0, searchValue.length) === searchValue.toLowerCase() : false;\r\n }),\r\n fuzzy: (values: any[], searchValue: string) => {\r\n const pattern = searchValue.split('').reduce((a, b) => (`${a }[^${ b }]*${ b}`));\r\n const regex = new RegExp(pattern);\r\n return values.filter(o => {\r\n const value = (this.isPrimitive) ? o : o[this.labelProperty];\r\n return (value) ? regex.test((`${value}`).toLowerCase()) : false;\r\n }).sort((a, b) => {\r\n // Sort by most exact match first\r\n const valueA = (`${(this.isPrimitive) ? a : a[this.labelProperty]}`).toLowerCase();\r\n const valueB = (`${(this.isPrimitive) ? b : b[this.labelProperty]}`).toLowerCase();\r\n const aIncludes = valueA.includes(searchValue.toLowerCase());\r\n const bIncludes = valueB.includes(searchValue.toLowerCase());\r\n if (!aIncludes && bIncludes) {\r\n return 1;\r\n } else if (aIncludes && !bIncludes) {\r\n return -1;\r\n }\r\n return valueA.localeCompare(valueB);\r\n });\r\n },\r\n substring: (values: any[], searchValue: string) => values.filter(o => {\r\n const value = (`${(this.isPrimitive) ? o : o[this.labelProperty]}`).toLowerCase();\r\n return (value) ? value.includes(searchValue.toLowerCase()) : false;\r\n }),\r\n state: (values: { value: Core.StateModel }[], searchValue: string) => {\r\n const pattern = searchValue.split('').reduce((a, b) => (`${a }[^${ b }]*${ b}`));\r\n const regex = new RegExp(pattern);\r\n return values.filter(o => {\r\n return (o.value.fullName && regex.test(o.value.fullName.toLowerCase())) || (o.value.abbr && regex.test(o.value.abbr.toLowerCase()));\r\n }).sort((a, b) => {\r\n // Sort by state abbreviation exact match first\r\n const aMatch = a.value.abbr.toLowerCase() === searchValue.toLowerCase();\r\n const bMatch = b.value.abbr.toLowerCase() === searchValue.toLowerCase();\r\n if (!aMatch && bMatch) {\r\n return 1;\r\n } else if (aMatch && !bMatch) {\r\n return -1;\r\n }\r\n return a.value.fullName.localeCompare(b.value.fullName);\r\n });\r\n },\r\n custom: noop\r\n };\r\n\r\n onChange: (val: any[]) => void = () => { /* noop */};\r\n onTouched: () => void = () => { /* noop */};\r\n\r\n // Angular Form methods\r\n\r\n writeValue(value: any[]) {\r\n this._updateValue(value);\r\n this.value = value;\r\n }\r\n\r\n setDisabledState(disabled: boolean) {\r\n this.disabled = disabled;\r\n }\r\n\r\n next() {\r\n this.onChange(this.value = this.selectedOptions.map(o => this.isPrimitive || this.objectIsValue ? o : o[this.valueProperty]));\r\n this.selectedOptionsChanged.emit(this.value);\r\n this.onTouched();\r\n }\r\n\r\n registerOnChange(fn: any) {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any) {\r\n this.onTouched = fn;\r\n }\r\n\r\n // Custom methods\r\n\r\n /**\r\n * Search the data\r\n */\r\n search(): boolean {\r\n const searchValue = (this.searchValue && this.searchValue.length) ? this.searchValue.trim().toLowerCase() : null;\r\n\r\n const options = [...this.dropdownOptions];\r\n\r\n if (searchValue) {\r\n this.searchableOptions = (searchValue.length === 1)\r\n ? this._search.exact(options, searchValue)\r\n : this._search[this.searchType](options, searchValue);\r\n } else {\r\n this.searchableOptions = options;\r\n }\r\n\r\n return false;\r\n }\r\n\r\n selectAll(): boolean {\r\n if (this.disabled) {\r\n return;\r\n }\r\n this.selectedOptions = (this.selectedOptions.length === this.dropdownOptions.length) ? [] : [...this.dropdownOptions];\r\n this._setSummary();\r\n this.next();\r\n return false;\r\n }\r\n\r\n deselectAll(): boolean {\r\n this.selectedOptions = [];\r\n this._setSummary();\r\n this.next();\r\n return false;\r\n }\r\n\r\n optionSelected(option: any): boolean {\r\n if (this.disabled) {\r\n return;\r\n }\r\n if (!this.multiSelectOptionActive(option)) {\r\n const selectedOptionsEmpty = !this.selectedOptions.length;\r\n this.selectedOptions.push(option);\r\n if (selectedOptionsEmpty) {\r\n let scrollTop = this.dropdown.nativeElement.scrollTop <= 31 ? 1 : this.dropdown.nativeElement.scrollTop;\r\n if (this.dropdownOptions[0] === option) {\r\n scrollTop = this.dropdown.nativeElement.scrollTop <= 31 ? 0 : this.dropdown.nativeElement.scrollTop;\r\n }\r\n this._renderer2.setProperty(this.dropdown.nativeElement, 'scrollTop', scrollTop);\r\n }\r\n } else {\r\n const i = this.selectedOptions.indexOf(option);\r\n this.selectedOptions.splice(i, 1);\r\n }\r\n this._setSummary();\r\n this.next();\r\n return false;\r\n }\r\n\r\n multiSelectOptionActive(option: any): boolean {\r\n return this.selectedOptions.indexOf(option) > -1;\r\n }\r\n\r\n toggleDropdown(): void {\r\n if (this.disabled) {\r\n return;\r\n }\r\n this.open = !this.open;\r\n if (this.open && this.canSearch) {\r\n this._timerService.setTimeout(() => {\r\n this.searchInput.nativeElement.focus();\r\n this._renderer2.setProperty(this.dropdown.nativeElement, 'scrollTop', 0);\r\n }, 0);\r\n }\r\n }\r\n\r\n closeDropdown(): void {\r\n this.open = false;\r\n }\r\n\r\n private _updateValue(value: any[]): void {\r\n if (!value) { return; }\r\n this.selectedOptions = this.dropdownOptions.filter(o => {\r\n return value.indexOf(this.isPrimitive || this.objectIsValue ? o : o[this.valueProperty]) > -1;\r\n });\r\n this._setSummary();\r\n }\r\n\r\n private _setSummary() {\r\n if (!this.selectedOptions || !this.selectedOptions.length) {\r\n this.selectedSummary = null;\r\n return;\r\n }\r\n\r\n const delimiter = this.useSemicolons ? '; ' : ', ';\r\n\r\n if (this.selectedOptions.length === 1) {\r\n const selection = this.isPrimitive && !this.objectIsValue ? this.selectedOptions[0] : this.selectedOptions[0][this.labelProperty];\r\n this.selectedSummary = `${selection}`;\r\n } else if (this.selectedOptions.length === 2) {\r\n const selected = this.selectedOptions.map(o => this.isPrimitive && !this.objectIsValue ? o : o[this.labelProperty]).join(delimiter);\r\n this.selectedSummary = `${this.selectedOptions.length} items (${selected})`;\r\n } else {\r\n this.selectedSummary = `${this.selectedOptions.length} items selected`;\r\n }\r\n }\r\n\r\n}\r\n","import {\r\n Component,\r\n Input,\r\n Output,\r\n EventEmitter,\r\n forwardRef,\r\n OnChanges,\r\n SimpleChanges,\r\n OnInit,\r\n ChangeDetectorRef\r\n} from '@angular/core';\r\nimport { StateSummary } from '../state.model';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { StateService } from '../States.Service';\r\n\r\n@Component({\r\n selector: 'state-dropdown',\r\n template: `\r\n \r\n \r\n \r\n {{ selectedState?.name }}\r\n \r\n \r\n {{ selectedStatesSummary }}\r\n `,\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => StateDropdownComponent),\r\n multi: true\r\n }\r\n ]\r\n})\r\nexport class StateDropdownComponent implements ControlValueAccessor, OnInit, OnChanges {\r\n constructor(private readonly _stateService: StateService,\r\n private readonly _cdRef: ChangeDetectorRef) { }\r\n\r\n @Input() stateId: number;\r\n @Input() stateIds: number[];\r\n @Input() readOnly: boolean;\r\n @Input() isSmall: boolean;\r\n @Input() disabled: boolean;\r\n @Input() stateAbbr: string;\r\n @Input() includeAll: boolean;\r\n @Input() includeBlank: boolean;\r\n @Input() includePlaceholder: boolean;\r\n @Input() abbrOnly: boolean = true;\r\n @Input() filterByCountryId: number;\r\n @Input() canSearch: boolean;\r\n @Input() useHtmlSelect: boolean;\r\n @Input() styleClass: string;\r\n @Input() deselectValue: string; //Selecting no state provides this undefined value\r\n @Input() container: string = 'body';\r\n\r\n // multiple\r\n @Input() multiple: boolean;\r\n @Input() hasSelectAll: boolean;\r\n @Input() hasDeselectAll: boolean;\r\n\r\n @Output() stateIdChange: EventEmitter = new EventEmitter();\r\n @Output() stateIdsChange: EventEmitter = new EventEmitter();\r\n @Output() stateAbbrChange: EventEmitter = new EventEmitter();\r\n @Output() stateAbbrsChange: EventEmitter = new EventEmitter();\r\n\r\n states: Compliance.NameValuePair[] = [];\r\n selectedState: Compliance.NameValuePair;\r\n selectedStates: Compliance.NameValuePair[];\r\n placeholder: string = '';\r\n\r\n private _loadingStates: boolean = false;\r\n\r\n get selectedStatesSummary(): string {\r\n return this.selectedStates.map(x => x.name).join(', ');\r\n }\r\n\r\n onChange: (val: number | number[]) => void = () => { return null; };\r\n onTouched: () => void = () => { return null; };\r\n\r\n async ngOnInit(): Promise {\r\n this.placeholder = (this.includePlaceholder) ? 'Select State' : '';\r\n\r\n if(!this.states.length) {\r\n await this._getStates();\r\n }\r\n }\r\n\r\n async ngOnChanges(changes: SimpleChanges): Promise {\r\n if(!this.states.length) {\r\n await this._getStates();\r\n }\r\n\r\n if(changes.stateId?.currentValue && changes.stateId?.currentValue !== changes.stateId?.previousValue) {\r\n this.selectedState = this.states.find(x => x.value.stateID === this.stateId);\r\n this._cdRef.detectChanges();\r\n } else if (changes.stateAbbr?.currentValue && changes.stateAbbr?.currentValue !== changes.stateAbbr?.previousValue) {\r\n this.selectedState = this.states.find(x => x.name === this.stateAbbr);\r\n this._cdRef.detectChanges();\r\n }\r\n }\r\n\r\n writeValue(value: number | number[]): void {\r\n if (value) {\r\n if (Array.isArray(value)) {\r\n this.stateIds = value;\r\n this.selectedStates = this.states.filter(x => value.includes(x.value.stateID));\r\n } else {\r\n this.stateId = value;\r\n this.selectedState = this.states.find(x => x.value.stateID === this.stateId);\r\n }\r\n }\r\n }\r\n\r\n setDisabledState(disabled: boolean): void {\r\n this.disabled = disabled;\r\n }\r\n\r\n next(): void {\r\n if (this.multiple) {\r\n const selectedIds = this.selectedStates.map(x => x.value.stateID);\r\n this.onChange(selectedIds);\r\n this.stateIdsChange.emit(selectedIds);\r\n this.stateAbbrsChange.emit(this.selectedStates.map(x => x.value.abbr));\r\n } else {\r\n this.onChange(this.selectedState?.value.stateID);\r\n this.stateIdChange.emit(this.selectedState?.value.stateID);\r\n this.stateAbbrChange.emit(this.selectedState?.value.abbr);\r\n }\r\n this.onTouched();\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouched = fn;\r\n }\r\n\r\n onStateChange(selection: Compliance.NameValuePair) {\r\n this.selectedState = selection;\r\n this.next();\r\n }\r\n\r\n onSelectedStatesChange(selections: Compliance.NameValuePair[]) {\r\n this.selectedStates = selections;\r\n this.next();\r\n }\r\n\r\n private async _getStates(): Promise {\r\n if (this._loadingStates) {\r\n return;\r\n }\r\n this._loadingStates = true;\r\n\r\n const states: StateSummary[] = await this._stateService.getSummary();\r\n\r\n this.states = states.map((s) => {\r\n return {\r\n name: (this.abbrOnly) ? `${s.abbr}` : `${s.fullName} (${s.abbr})`,\r\n value: s\r\n };\r\n });\r\n\r\n if (this.includeAll) {\r\n this.states.unshift({ name: 'All', value: { stateID: null } as StateSummary });\r\n }\r\n if(this.filterByCountryId) {\r\n this.states = this.states.filter(x => x.value.countryID === +this.filterByCountryId);\r\n }\r\n if (this.stateId) {\r\n this.selectedState = this.states.find(x => x.value.stateID === this.stateId);\r\n }\r\n this._loadingStates = false;\r\n }\r\n}\r\n","
\r\n
\r\n {{address.address1}}
\r\n {{address.address2}}
\r\n {{address.city}}, {{address.zip}}
\r\n P: {{address.phone}} F: {{address.fax}}
\r\n {{address.email}}\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n T\r\n \r\n
\r\n
\r\n F\r\n \r\n
\r\n
\r\n
\r\n @\r\n \r\n
\r\n
\r\n
\r\n\r\n \r\n
\r\n","import { Component, Input } from '@angular/core';\r\nimport { IAddress } from '../../Models/common.model';\r\n\r\n@Component({\r\n selector: 'address-view-edit',\r\n templateUrl: './address.view.edit.component.html'\r\n})\r\nexport class AddressViewEditComponent {\r\n @Input() address: IAddress;\r\n @Input() isEditMode: boolean;\r\n @Input() shouldIncludeDetails: boolean;\r\n @Input() shouldRestrictExtended: boolean;\r\n @Input() isSmall: boolean;\r\n @Input() readOnlyState: boolean;\r\n @Input() removeBottomMargin: boolean;\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { ModalModule } from 'ngx-bootstrap/modal';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { StepProgressIndicatorComponent } from './stepProgressIndicator.component';\r\nimport { HelpModule } from '../../UI-Lib/Help-Tooltip/help.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n BsDropdownModule,\r\n BusyIndicatorModule.forRoot(),\r\n ModalModule,\r\n HelpModule\r\n ],\r\n declarations: [\r\n StepProgressIndicatorComponent\r\n ],\r\n exports: [\r\n StepProgressIndicatorComponent\r\n ]\r\n})\r\nexport class StepProgressIndicatorModule {\r\n}\r\n","import { Component, Input, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { OutputColumn } from '../../Search/Advanced/Column-Picker/column.model';\r\nimport * as _ from 'lodash';\r\nimport { SearchOperatorsService } from '../../Search/searchOperators.service';\r\nimport { TaskSeriesType } from '../../Task/Task.Model';\r\n\r\nexport interface DraggableOutputColumn extends OutputColumn {\r\n isRemovable: boolean;\r\n}\r\n\r\nexport interface ColumnCategory {\r\n categoryName?: string;\r\n columns: DraggableOutputColumn[];\r\n defaultColumns: DraggableOutputColumn[];\r\n showBody?: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'category-column-picker',\r\n template: `\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
Add Column
\r\n \r\n \r\n
\r\n\r\n \r\n
\r\n {{ item.value.displayName }}\r\n {{ item.value.typeAheadName }}\r\n \r\n
\r\n
\r\n `,\r\n styleUrls: ['categoryColumnPicker.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class CategoryColumnPickerComponent implements OnInit {\r\n constructor(private searchOperators: SearchOperatorsService) { }\r\n\r\n @Input() cpMode: 'av' | 'smart';\r\n @Input() category: ColumnCategory;\r\n @Input() selectedTaskType: TaskSeriesType;\r\n @Input() disableUseSystemDefined: boolean;\r\n\r\n useSystemDefined: boolean;\r\n\r\n ngOnInit() {\r\n if(!this.disableUseSystemDefined) {\r\n const colIds = _.map(this.category.columns, x => x.id || x.columnId || x.advancedSearchFieldID);\r\n const defaultColIds = _.map(this.category.defaultColumns, x => x.id || x.columnId || x.advancedSearchFieldID);\r\n\r\n this.useSystemDefined = _.xor(colIds, defaultColIds).length == 0;\r\n }\r\n }\r\n\r\n removeColumn(column: DraggableOutputColumn): void {\r\n let idProperty = 'columnId';\r\n\r\n if(column.id) {\r\n idProperty = 'id';\r\n } else if(column.advancedSearchFieldID) {\r\n idProperty = 'advancedSearchFieldID';\r\n }\r\n\r\n this.category.columns = _.reject(this.category.columns, x => {\r\n return x[idProperty] == column[idProperty];\r\n });\r\n }\r\n\r\n addColumns(columns: OutputColumn[]): void {\r\n const draggableOutputColumns = _.map(columns, column => {\r\n const addedColumn = _.cloneDeep(column);\r\n\r\n if(this.cpMode == 'av') {\r\n addedColumn.operators = this.searchOperators.getOperatorArray(addedColumn.operators as string[]);\r\n\r\n if (addedColumn.columnId === 101 || addedColumn.columnId === 109) {\r\n addedColumn.or = [this.searchOperators.getCompanyOr(addedColumn.operators)];\r\n } else {\r\n addedColumn.or = [this.searchOperators.getOr(addedColumn.operators)];\r\n }\r\n }\r\n\r\n return { ...addedColumn, isRemovable: true };\r\n });\r\n\r\n this.category.columns = [...this.category.columns, ...draggableOutputColumns];\r\n }\r\n\r\n onSysDefinedChanged(): void {\r\n if (this.useSystemDefined) {\r\n this.category.columns = _.cloneDeep(this.category.defaultColumns);\r\n }\r\n }\r\n}\r\n\r\n","
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import {\r\n Component, ElementRef,\r\n EventEmitter, HostListener,\r\n Input, NgZone, OnInit,\r\n Output, ViewChild,\r\n ViewEncapsulation\r\n} from '@angular/core';\r\nimport { TimerService } from '../../Utilities';\r\nimport { DropdownPosition } from '../Select/select.interface';\r\n\r\n@Component({\r\n selector: 'ws-ace-dropdown',\r\n templateUrl: './dropdown.component.html',\r\n styleUrls: ['./dropdown.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class AceDropdownComponent implements OnInit {\r\n constructor(private readonly _timer: TimerService,\r\n private readonly _ngZone: NgZone) { }\r\n @Input() icon: string = 'chevron-down';\r\n @Input() size: 'default' | 'small' = 'default';\r\n @Input() content: string;\r\n @Input() asyncMenu: boolean;\r\n\r\n @Input() enableFocus: boolean;\r\n @Input() autoClose: boolean | 'inside' | 'outside' = true;\r\n @Input() suppressAutoOpen: boolean;\r\n @Input() attachment: any;\r\n @Input() position: DropdownPosition | string;\r\n @Input() sameWidth: boolean;\r\n @Input() displayAbsolute: boolean;\r\n @Input() overflowVisible: boolean;\r\n @Input() isLoading: boolean;\r\n @Input() isDisabled: boolean;\r\n /** A selector or element that will contain the dropdown. Default: closest(.ace-con section.content) */\r\n @Input() boundary?: string | HTMLElement;\r\n // draw a dropdown with zero padding, for colored footers\r\n @Input() suppressPadding?: boolean;\r\n /** use full-width hitbox */\r\n @Input() block?: boolean;\r\n /** Event will be raised when dropdown opens or closes */\r\n @Output() openChange?: EventEmitter = new EventEmitter();\r\n\r\n @ViewChild('dropdownHost', { static: true }) dropdownHost: ElementRef;\r\n @ViewChild('dropdownMenu', { static: true }) dropdownMenu: ElementRef;\r\n\r\n isOpen = false;\r\n placementClasses: { [key: string]: boolean };\r\n positionClasses: { [key: string]: boolean };\r\n ddPosition: { [key: string]: string } = {\r\n opacity: '0',\r\n };\r\n\r\n @HostListener('window:resize', [])\r\n resize() {\r\n this._calculatePosition();\r\n }\r\n\r\n ngOnInit(): void {\r\n this.placementClasses = { 'dropdown-wrapper': true };\r\n if (this.attachment) {\r\n this.placementClasses[`drop${this.attachment}`] = true;\r\n } else {\r\n this.placementClasses['dropdown'] = true;\r\n }\r\n this.positionClasses = { 'dropdown-menu': true };\r\n if (this.position) {\r\n this.positionClasses[`dropdown-menu-${this.position}`] = true;\r\n }\r\n if (this.sameWidth) {\r\n this.positionClasses['same-width'] = true;\r\n }\r\n if (this.overflowVisible) {\r\n this.positionClasses['overflow-visible'] = true;\r\n }\r\n\r\n window.addEventListener('scroll', this._calculatePosition.bind(this), true);\r\n }\r\n\r\n setOpenState(isOpen: boolean, location?: string): void {\r\n if ((!this.isDisabled || (this.isDisabled && !isOpen)) && (!location || (this.autoClose === true || this.autoClose === location))) {\r\n this.isOpen = isOpen;\r\n if (this.isOpen) {\r\n this._timer.setTimeout(() => {\r\n this._calculatePosition();\r\n }, 0);\r\n } else {\r\n this.ddPosition = {\r\n opacity: '0',\r\n };\r\n }\r\n this.openChange.emit(isOpen);\r\n }\r\n }\r\n\r\n private _calculatePosition(): void {\r\n const hostElRect = this.dropdownHost.nativeElement.getBoundingClientRect();\r\n const menuElRect = this.dropdownMenu.nativeElement.getBoundingClientRect();\r\n const windowWidth = window.innerWidth;\r\n let hostElTop = hostElRect.top + hostElRect.height;\r\n\r\n let hostElRight = windowWidth - hostElRect.left - menuElRect.width;\r\n if (this.position === 'end') {\r\n hostElRight = window.innerWidth - hostElRect.left - hostElRect.width;\r\n }\r\n if (hostElRight < 0) {\r\n hostElRight = 0;\r\n }\r\n\r\n if (hostElTop + menuElRect.height > window.innerHeight) {\r\n this.position = 'top';\r\n hostElTop = hostElRect.top - menuElRect.height;\r\n }\r\n\r\n this.ddPosition = {\r\n position: 'fixed',\r\n inset: '0px 0px auto auto',\r\n margin: '0px',\r\n opacity: '1',\r\n transform: `translate(${-hostElRight}px, ${hostElTop}px)`\r\n };\r\n }\r\n}\r\n"," 1\"\r\n class=\"d-inline\"\r\n position=\"end\"\r\n [content]=\"selectedInstance.name\">\r\n \r\n \r\n \r\n\r\n","import { Component, Inject, OnDestroy, OnInit } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { UpgradeNavigationServiceHandler } from '../Routing/upgrade-navigation-handler.service';\r\n\r\n/**\r\n * Instance Filter Single-selection dropdown\r\n * loads the list of a user's instance memberships from UserInstanceService\r\n * works in conjunction with the InstanceHeaderInterceptor.\r\n * NOTE: When the instance is changed, the user is redirected to the homepage\r\n * to ensure any navigation/views will respect the change\r\n * Example usage:\r\n * \r\n *\r\n */\r\n@Component({\r\n selector: 'ws-instance-filter',\r\n templateUrl: './instanceFilter.component.html',\r\n styleUrls: ['./instanceFilter.component.scss']\r\n})\r\nexport class InstanceFilterComponent implements OnInit, OnDestroy {\r\n constructor(\r\n @Inject('$rootScope') private _rootScope: any,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _navigationService: NavigationService\r\n ) {\r\n _rootScope.$on('global.edit.mode.activated', () => {\r\n this.isDisabled = true;\r\n });\r\n _rootScope.$on('global.edit.mode.deactivated', () => {\r\n this.isDisabled = false;\r\n });\r\n }\r\n\r\n instances: Array = [];\r\n selectedInstance: Core.InstanceViewModel;\r\n isDisabled: boolean = false;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n // get all the instances the current user has access to\r\n this.instances = [this._userInstanceService.allInstancesItem].concat(this._userInstanceService.getUserInstanceMembership(false));\r\n\r\n // set initial value\r\n this.selectedInstance = this._userInstanceService.getSelectedInstance();\r\n\r\n this._navigationService.globalEditMode$.pipe(takeUntil(this._destroy$))\r\n .subscribe((editMode: boolean) => {\r\n this.isDisabled = editMode;\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n instanceChanged(instance: Core.InstanceViewModel): void {\r\n this.selectedInstance = instance;\r\n this._userInstanceService.saveSelectedInstance(instance);\r\n\r\n //go home and reload page so that all the permissions are checked - especially on the top menus which do not reload on navigation\r\n window.location.replace(`${window.location.origin}/#/home`);\r\n window.location.reload();\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { CompanyRepository } from '../../Compliance/Repositories';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AddYearConfig, UpdateCompanySettingConfig } from '../../Compliance/Repositories/company.repository';\r\nimport {ToastrService} from 'ngx-toastr';\r\n\r\nexport interface CompanyModel extends Weissman.Model.Domain.Company {\r\n parentId: number;\r\n}\r\n\r\n@Injectable()\r\nexport class CompanyService {\r\n constructor(private readonly _companyRepository: CompanyRepository,\r\n private readonly _toastrService: ToastrService) {}\r\n\r\n private _company: CompanyModel;\r\n\r\n async load(companyId: number, noCache: boolean, navigationRequest: any): Promise {\r\n const config = {\r\n navigationRequest: !!navigationRequest\r\n };\r\n\r\n const fetchedCompany = await lastValueFrom(this._companyRepository.loadCompany(companyId, config));\r\n\r\n // The below needs to be refactored, we shouldn't be doing in-line viewmodels\r\n // this has caused multiple bugs on the site as we add new things\r\n this._updateParentId(fetchedCompany);\r\n if (!noCache) {\r\n this._company = fetchedCompany;\r\n }\r\n return fetchedCompany;\r\n }\r\n\r\n async loadCompanyParent(companyId: number, topLevelCompanyId: number): Promise {\r\n const response = await lastValueFrom(this._companyRepository.loadCompanyParent(companyId, topLevelCompanyId));\r\n // A bit of a hack; if there's no row version on the parent company, we know this was a stubbed-in\r\n // company and the user doesn't have permission for it. We need to know that so we can disable the\r\n // link to the top-level company.\r\n if (response.rowVersion === null) {\r\n response.noPermission = true;\r\n }\r\n return response;\r\n }\r\n\r\n getCompanyName(companyId: number): Promise {\r\n return lastValueFrom(this._companyRepository.getCompanyName(companyId));\r\n }\r\n\r\n getSubsidiaries(topLevelCompanyId: number, excludeInactive: boolean = false): Promise {\r\n return lastValueFrom(this._companyRepository.getSubsidiaries(topLevelCompanyId, excludeInactive));\r\n }\r\n\r\n async update(company: any): Promise {\r\n try {\r\n this._company = await lastValueFrom(this._companyRepository.updateCompany(company));\r\n } catch (e) {\r\n this._toastrService.error(e?.error?.message ?? e.message);\r\n }\r\n\r\n return this._company;\r\n }\r\n\r\n isCompanyNameInUseAlready(name: string, topLevelCompanyId: number, companyId: number): Promise {\r\n const model: Core.CompanyNameLookupDTO = {\r\n companyName: name,\r\n companyId: companyId,\r\n topLevelCompanyId: topLevelCompanyId\r\n };\r\n\r\n return lastValueFrom(this._companyRepository.isCompanyNameInUse(model));\r\n }\r\n\r\n isCompanyCodeInUseAlready(companyCode, topLevelCompanyID: number, companyID: number, ppReturnPreparationAllowed: boolean): Promise {\r\n if(ppReturnPreparationAllowed && (!companyCode || 0 === companyCode.length))\r\n {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const config: Core.CompanyCodeLookupDTO = {\r\n companyCode: companyCode,\r\n topLevelCompanyID: topLevelCompanyID,\r\n companyID: companyID\r\n };\r\n return lastValueFrom(this._companyRepository.isCompanyCodeInUseAlready(config));\r\n }\r\n\r\n search(criteria: any, pageSize: number, pageNumber: number, topLevelOnly: boolean = false, favoriteOnly: boolean = false,\r\n activeOnly?: boolean, instanceIdFilter?: number, clientInstanceId?: number, useExplicitCrossInstanceListForPermCheck?: boolean): Promise {\r\n const config : any = {\r\n params: {\r\n search: criteria,\r\n pageSize: pageSize,\r\n pageNumber: pageNumber,\r\n topLevelOnly: topLevelOnly,\r\n favoriteOnly: favoriteOnly,\r\n activeOnly: activeOnly || false\r\n }\r\n };\r\n\r\n if(instanceIdFilter) {\r\n config.params.instanceIdFilter = instanceIdFilter;\r\n }\r\n\r\n if (clientInstanceId) {\r\n config.params.clientInstanceId = clientInstanceId;\r\n }\r\n\r\n if (useExplicitCrossInstanceListForPermCheck) {\r\n config.params.useExplicitCrossInstanceListForPermCheck = useExplicitCrossInstanceListForPermCheck;\r\n }\r\n\r\n return lastValueFrom(this._companyRepository.search(config));\r\n }\r\n\r\n get(): any {\r\n this._updateParentId(this._company);\r\n return this._company;\r\n }\r\n\r\n // TODO This is used in some AngularJS code and is passed to the dom. Once things are upgraded this should be changed to a getter.\r\n isTopLevel = (): boolean => {\r\n return !this._company?.parentId;\r\n };\r\n\r\n create(company: any): Promise {\r\n return lastValueFrom(this._companyRepository.create(company));\r\n }\r\n\r\n getStatesWithSites(companyId: number, activeOnly: boolean, includeSubsidiaries: boolean): Promise {\r\n return lastValueFrom(this._companyRepository.getStatesWithSites(companyId, activeOnly, includeSubsidiaries));\r\n }\r\n\r\n getByUserPermission(userId: number, isCache: boolean = false): Promise {\r\n return lastValueFrom(this._companyRepository.getByUserPermission(userId, isCache));\r\n }\r\n\r\n setIsCompanyFavorite(companyId: number, isFavorite: boolean): Promise {\r\n return lastValueFrom(this._companyRepository.setIsCompanyFavorite(companyId, isFavorite));\r\n }\r\n\r\n updateCompanySetting(companyId: number, vendorCodeSetting, invoiceAppealSavings, fiscalYearStart, syncDXPFlag, budgetsEnabled, budgetBasis, budgetDescriptors,\r\n accrualsEnabled: boolean, defaultAccrualAdjustmentMethodId: number, useTopLevelCompanyCOA, accrualEconUnitTypeId: number, accrualEconUnitDescriptorId: number, accrualFileTypeId: number,\r\n accrualDescriptors, excludeFromAccruals: boolean, accrualExportPropertyIdentificationId: number, accrualExportPropIdentDescriptorId: number,\r\n requireClientApprovalFlag: boolean, enableAllocations: boolean, dataHubEnabled: boolean, dataHubClientTenantId: string): Promise {\r\n\r\n const config: UpdateCompanySettingConfig = {\r\n useTopLevelCompanyVendorCodeMapping: vendorCodeSetting,\r\n invoiceAppealSavings: invoiceAppealSavings,\r\n fiscalYearStart: fiscalYearStart,\r\n syncDXP: syncDXPFlag,\r\n budgetsEnabled: budgetsEnabled,\r\n budgetBasis: budgetBasis,\r\n budgetDescriptors: budgetDescriptors,\r\n accrualsEnabled: accrualsEnabled,\r\n defaultAccrualAdjustmentMethodId: defaultAccrualAdjustmentMethodId,\r\n useTopLevelCompanyCOA: useTopLevelCompanyCOA,\r\n accrualEconUnitTypeId: accrualEconUnitTypeId,\r\n accrualEconUnitDescriptorId: accrualEconUnitDescriptorId,\r\n accrualFileTypeId: accrualFileTypeId,\r\n accrualDescriptors: accrualDescriptors,\r\n excludeFromAccruals: excludeFromAccruals,\r\n accrualExportPropertyIdentificationId,\r\n accrualExportPropIdentDescriptorId,\r\n requireClientApproval: requireClientApprovalFlag,\r\n enableAllocations: enableAllocations,\r\n dataHubEnabled: dataHubEnabled,\r\n dataHubClientTenantId: dataHubClientTenantId\r\n };\r\n\r\n return lastValueFrom(this._companyRepository.updateCompanySetting(companyId, config));\r\n }\r\n\r\n getCompanyVendorCodesCount(companyId: number): Promise {\r\n return lastValueFrom(this._companyRepository.getCompanyVendorCodesCount(companyId));\r\n }\r\n\r\n addYear(companyId: number, year: number, stateIds?: number[]): Promise {\r\n const config: AddYearConfig = {\r\n companyId: companyId,\r\n annualYear: year,\r\n stateIds\r\n };\r\n\r\n return lastValueFrom(this._companyRepository.addYear(config));\r\n }\r\n\r\n getCompanyYears(companyId: number): Promise {\r\n return lastValueFrom(this._companyRepository.getCompanyYears(companyId));\r\n }\r\n\r\n ppReturnPreparationAllowed(): boolean {\r\n return this._company && this._company.ppReturnPreparationAllowed;\r\n }\r\n\r\n deleteCompany(id: number): Promise {\r\n return lastValueFrom(this._companyRepository.deleteCompany(id));\r\n }\r\n\r\n getAddYearProcessStatus(longRunningProcessId: number): Promise {\r\n return lastValueFrom(this._companyRepository.getAddYearProcessStatus(longRunningProcessId));\r\n }\r\n\r\n checkAccrualsEnabled(): Promise {\r\n return lastValueFrom(this._companyRepository.checkAccrualsEnabled());\r\n }\r\n\r\n checkForLongRunningProcesses(companyId: number): Promise {\r\n return lastValueFrom(this._companyRepository.checkForLongRunningProcesses(companyId));\r\n }\r\n\r\n getCompanyFiscalYearStart(companyId: number): Promise {\r\n return lastValueFrom(this._companyRepository.getCompanyFiscalYearStart(companyId));\r\n }\r\n\r\n getTopCompanyForEntity(entityTypeId: number, entityId: number): Promise {\r\n return lastValueFrom(this._companyRepository.getTopCompanyForEntity(entityTypeId, entityId));\r\n }\r\n\r\n checkOngoingAction(companyId: number): Promise {\r\n return lastValueFrom(this._companyRepository.checkOngoingAction(companyId));\r\n }\r\n\r\n getEconomicUnitTypes(): Promise {\r\n return lastValueFrom(this._companyRepository.getEconomicUnitTypes());\r\n }\r\n\r\n async getInUseCharacteristics(topLevelCompanyId: number, activeOnly: boolean): Promise {\r\n const result = await lastValueFrom(this._companyRepository.getInUseCharacteristics(topLevelCompanyId, activeOnly));\r\n return result.inUseCharacteristics;\r\n }\r\n\r\n async getAllowedAccrualFileTypes(topLevelCompanyId: number): Promise {\r\n return await lastValueFrom(this._companyRepository.getAllowedAccrualFileTypes(topLevelCompanyId));\r\n }\r\n\r\n getInfoForCompliance(companyId: number) : Promise {\r\n return lastValueFrom(this._companyRepository.getInfoForCompliance(companyId));\r\n }\r\n\r\n private _updateParentId(fetchedCompany): void {\r\n fetchedCompany.parentId = fetchedCompany.topLevelCompanyId !== fetchedCompany.companyID\r\n ? fetchedCompany.topLevelCompanyId\r\n : null;\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { from, Observable } from 'rxjs';\r\nimport { mergeMap } from 'rxjs/operators';\r\nimport { CompanyService } from '../../Entity/Company/company.service';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\n\r\nexport interface CompanyPickerResult {\r\n companyID: number;\r\n companyName: string;\r\n}\r\n\r\n@Component({\r\n selector: 'ws-company-picker',\r\n templateUrl: './companyPicker.component.html'\r\n})\r\nexport class CompanyPickerComponent implements OnInit {\r\n constructor(private readonly _companyService: CompanyService) {}\r\n\r\n @Input() companyId: number;\r\n @Input() companyName: string;\r\n @Input() appendToBody: boolean;\r\n @Input() topLevelOnly: boolean;\r\n @Input() favoritesOnly: boolean;\r\n @Input() activeOnly: boolean;\r\n\r\n @Output() companyIdChange: EventEmitter = new EventEmitter();\r\n @Output() companyNameChange: EventEmitter = new EventEmitter();\r\n @Output() companyChange: EventEmitter = new EventEmitter();\r\n\r\n company: CompanyPickerResult;\r\n companyFilter: string = '';\r\n loadingCompanies: boolean;\r\n\r\n companies$: Observable = (new Observable((observer: any) => { observer.next(this.companyFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._getCompanies(token)));\r\n\r\n private readonly PAGE_SIZE = 50;\r\n private readonly PAGE_NUMBER = 1;\r\n\r\n private _noResult: boolean;\r\n\r\n ngOnInit(): void {\r\n this.company = {\r\n companyID: this.companyId || null,\r\n companyName: this.companyName || null\r\n };\r\n this.companyFilter = this.companyName || null;\r\n }\r\n\r\n companySelected(selected: TypeaheadMatch): void {\r\n this.companyId = selected.item.companyID;\r\n this.companyIdChange.emit(this.companyId);\r\n this.companyName = selected.item.companyName;\r\n this.companyNameChange.emit(this.companyName);\r\n this.company = {\r\n companyID: this.companyId,\r\n companyName: this.companyName\r\n };\r\n this.companyChange.emit(this.company);\r\n }\r\n\r\n checkForBlank(): void {\r\n if (!this.company) {\r\n this.companyId = null;\r\n this.companyName = '';\r\n }\r\n }\r\n\r\n onNoResults(event: boolean): void {\r\n this._noResult = event;\r\n\r\n if (event) {\r\n this.companyId = null;\r\n this.companyName = '';\r\n }\r\n }\r\n\r\n onBlur(): void {\r\n if (!this.companyFilter) {\r\n this.companyIdChange.emit(null);\r\n this.companyNameChange.emit(null);\r\n }\r\n }\r\n\r\n typeaheadLoading(isLoading: boolean): void {\r\n this.loadingCompanies = isLoading;\r\n }\r\n\r\n private _getCompanies(searchTerm: string): Observable {\r\n if (searchTerm) {\r\n return from(this._companyService.search(searchTerm || '', this.PAGE_SIZE, this.PAGE_NUMBER, this.topLevelOnly, this.favoritesOnly, this.activeOnly));\r\n } else {\r\n return from(Promise.resolve([]));\r\n }\r\n }\r\n}\r\n","
\r\n \r\n \r\n
\r\n","\r\n \r\n \r\n \r\n \r\n \r\n
{{filter.resultColumnName || filter.resultsColumnName || filter.displayName}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
OR\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n
\r\n
\r\n \r\n
\r\n\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { SearchOperatorsService } from '../../../Search/searchOperators.service';\r\nimport { ProductAnalyticsService } from '../../Amplitude/productAnalytics.service';\r\n\r\n@Component({\r\n selector: 'ws-column-filters',\r\n templateUrl: './columnFilters.component.html'\r\n})\r\nexport class ColumnFiltersComponent {\r\n constructor(private readonly _searchOperators: SearchOperatorsService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {}\r\n\r\n @Input() columnFilters: any[] = [];\r\n @Input() showOrs: boolean;\r\n @Input() hideDelete: boolean;\r\n @Input() onlyFrequentlyUsedCompanies: boolean;\r\n @Input() activeOnly: boolean;\r\n\r\n @Output() emptyFilter: EventEmitter = new EventEmitter();\r\n @Output() updateColumnFilters: EventEmitter = new EventEmitter();\r\n\r\n isDatePickerOpen: any = {};\r\n\r\n readonly COMPANY_NAME_TOP_LEVEL_ID = 109;\r\n private readonly COMPANY_NAME_ID = 101;\r\n\r\n private _filtersUsed: string[] = [];\r\n\r\n removeOr(filter: any, or: any): void {\r\n const index = filter.or.indexOf(or);\r\n filter.or.splice(index, 1);\r\n\r\n if (!filter.or.length) {\r\n this.columnFilters = this.columnFilters.filter((columnFilter) => columnFilter.or && columnFilter.or.length);\r\n this.updateColumnFilters.emit(this.columnFilters);\r\n this.emptyFilter.emit();\r\n }\r\n }\r\n\r\n addOr(filter: any): void {\r\n filter.or.push(this._searchOperators.getOr(filter.operators));\r\n this.updateColumnFilters.emit(this.columnFilters);\r\n }\r\n\r\n updateOrValue(value: any, or: any): void {\r\n or.value = value;\r\n this.updateColumnFilters.emit(this.columnFilters);\r\n const filtersUsed = this.columnFilters.filter(x => x.or.some(y => y.value)).map(x => x.resultColumnName || x.resultsColumnName || x.displayName);\r\n if (this._filtersUsed.sort().join() !== filtersUsed.sort().join()) {\r\n this._productAnalyticsService.logEvent('enter-action-view-filters', { actionViewFilter: filtersUsed });\r\n this._filtersUsed = filtersUsed;\r\n }\r\n }\r\n\r\n maybeHideValue(operatorName: string): string {\r\n if (operatorName === 'blank' || operatorName === 'notBlank' || operatorName === 'isNA') {\r\n return 'invisible';\r\n }\r\n }\r\n\r\n hideRow(filter: any): string {\r\n const filterId = filter.columnId || filter.id || filter.advancedSearchFieldID;\r\n\r\n if (filterId === 9002 || filterId === 1430) {\r\n return 'none';\r\n } else {\r\n return 'table-row';\r\n }\r\n }\r\n\r\n changeOperator(filter: any, or: any, oldOrName: string): void {\r\n // Reset the filter value when the selector type changes\r\n if (this.selectorType(filter, or.operator.name) !== this.selectorType(filter, oldOrName)) {\r\n or.value = null;\r\n }\r\n this.updateColumnFilters.emit(this.columnFilters);\r\n }\r\n\r\n selectorType(filter: any, orName: string) {\r\n if(!filter.type) {\r\n if(filter.advancedSearchDataType) {\r\n filter.type = filter.advancedSearchDataType.name;\r\n }\r\n }\r\n\r\n const dateFilters = ['datetime2', 'Date', 'DateTime', 'DateText', 'UTCDateTime', 'UTCDate'];\r\n if (orName === 'withinDate') {\r\n return 'withinDate';\r\n }\r\n else if (dateFilters.indexOf(filter.type) > -1) {\r\n return 'date';\r\n }\r\n else if ((filter.columnId === this.COMPANY_NAME_ID ||\r\n filter.columnId === this.COMPANY_NAME_TOP_LEVEL_ID ||\r\n filter.advancedSearchFieldID === this.COMPANY_NAME_ID ||\r\n filter.advancedSearchFieldID === this.COMPANY_NAME_TOP_LEVEL_ID) &&\r\n (orName === 'equal' || orName === 'notEqual')) {\r\n return 'company';\r\n }\r\n else if (filter.type === 'YesNo') {\r\n return 'yesNo';\r\n }\r\n else {\r\n return 'input';\r\n }\r\n }\r\n\r\n datePickerOpened(selectedOr: any): void {\r\n this.columnFilters.forEach(filter => {\r\n filter.or.forEach(or => {\r\n if (or.$$hashKey !== selectedOr.$$hashKey) {\r\n this.isDatePickerOpen[or.$$hashKey] = false;\r\n }\r\n });\r\n });\r\n }\r\n\r\n columnFiltersTrackBy(item: any, i: number): number {\r\n return i;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { StampComponent } from './stamp.component';\r\nimport { StampTooltipComponent } from './stampTooltip.component';\r\nimport { HelpModule } from '../../UI-Lib/Help-Tooltip/help.module';\r\n\r\n@NgModule({\r\n imports: [CommonModule, HelpModule],\r\n declarations: [StampComponent, StampTooltipComponent],\r\n exports: [StampComponent]\r\n})\r\nexport class StampModule {\r\n\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { HelpContentComponent, HelpContentRendererValue } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport type StampTooltipComponentParams = HelpContentRendererValue;\r\n\r\n@Component({\r\n selector: 'stamp-tooltip',\r\n template: `\r\n
data.inactivatedDateTime\">\r\n
\r\n Activated by {{data.activatedBy}}
\r\n Date: {{data.activatedDateTime | date:'M/d/yyyy'}}\r\n
\r\n
\r\n Inactivated by {{data.inactivatedBy}}
\r\n Date: {{data.inactivatedDateTime | date:'M/d/yyyy'}}\r\n
\r\n
\r\n
\r\n
\r\n Inactivated by {{data.inactivatedBy}}
\r\n Date: {{data.inactivatedDateTime | date:'M/d/yyyy'}}\r\n
\r\n
\r\n Activated by {{data.activatedBy}}
\r\n Date: {{data.activatedDateTime | date:'M/d/yyyy'}}\r\n
\r\n
\r\n `\r\n})\r\nexport class StampTooltipComponent implements HelpContentComponent {\r\n\r\n params: StampTooltipComponentParams;\r\n data: any;\r\n\r\n helpInit(params: StampTooltipComponentParams) {\r\n this.data = params.value;\r\n }\r\n}\r\n","\r\n\r\n\r\n\r\n\"Sold\"\r\n\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { HelpContentComponentConfig } from '../../UI-Lib/Help-Tooltip';\r\nimport { StampTooltipComponent, StampTooltipComponentParams } from './stampTooltip.component';\r\n\r\n@Component({\r\n selector: 'ws-stamp',\r\n templateUrl: './stamp.component.html',\r\n styleUrls: ['./stamp.component.scss']\r\n})\r\nexport class StampComponent implements OnInit {\r\n @Input() visible: boolean;\r\n @Input() activityStatusId: Core.ActivityStatuses;\r\n @Input() transaction: any;\r\n @Input() offsetFrom: string = 'top';\r\n @Input() rightOffset: number = 85;\r\n @Input() set dataValue(dataValue: any) {\r\n this._dataValue = dataValue;\r\n this._createHelpComponent();\r\n }\r\n get dataValue(): any {\r\n return this._dataValue;\r\n }\r\n\r\n helpContentComponent: HelpContentComponentConfig;\r\n\r\n private _dataValue: any;\r\n\r\n\r\n get inactiveOffset(): string {\r\n return (this.offsetFrom === 'bottom' && !this.visible && this.activityStatusId !== 2) ? '120px' : null;\r\n }\r\n\r\n get soldOffset(): string {\r\n return (this.offsetFrom === 'top' && !this.visible && this.activityStatusId !== 2) ? '140px' : null;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._createHelpComponent();\r\n }\r\n\r\n getInactiveURL(): string {\r\n return `/images/${(this.activityStatusId === 0) ? 'inactive' : 'active-pending'}.jpg`;\r\n }\r\n\r\n private _createHelpComponent(): void {\r\n if (this.dataValue && (this.dataValue.activatedBy\r\n || this.dataValue.inactivatedBy\r\n || this.dataValue.inactivatedDateTime\r\n || (this.dataValue.activatedDateTime && this.dataValue.inactivatedDateTime && this.dataValue.activatedDateTime <= this.dataValue.inactivatedDateTime))) {\r\n this.helpContentComponent = {\r\n component: StampTooltipComponent,\r\n componentParams: {}\r\n };\r\n }\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule, PercentPipe } from '@angular/common';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\r\nimport { GoogleMapsModule } from '@angular/google-maps';\r\n\r\nimport { CarouselModule } from 'ngx-bootstrap/carousel';\r\nimport { ModalModule } from 'ngx-bootstrap/modal';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { ProgressbarModule } from 'ngx-bootstrap/progressbar';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { SortableModule } from 'ngx-bootstrap/sortable';\r\nimport { AccordionModule } from 'ngx-bootstrap/accordion';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { NgxFileDropModule } from 'ngx-file-drop';\r\nimport { QuillModule } from 'ngx-quill';\r\n\r\nimport { UILibModule } from '../UI-Lib/UILib.module';\r\nimport { AgGridExtensionsModule } from '../Compliance/AgGrid/agGridExtensions.module';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { ColumnPickerModule } from '../Search/Advanced/Column-Picker/columnPicker.module';\r\nimport { CommentsModule } from '../Comments/comments.module';\r\nimport { EntityAttachmentsComponent } from '../Attachment/Entity/entity-attachments.component';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { ActivityModule } from './Activity/activity.module';\r\nimport { AssessmentTaxesDetailsModule } from './Assessment-Taxes-Details/assessment-taxes-details.module';\r\nimport { PDFViewerComponent } from './PDFViewer/pdf-viewer.component';\r\nimport { PDFControlsComponent } from './PDFViewer/PDF-Controls/pdfControls.component';\r\nimport { WsAgGridWrapperModule } from '../Compliance/AgGrid/AgGridWrapper/wsAgGridWrapper.module';\r\nimport { WsAgGridWrapperComponent } from '../Compliance/AgGrid/AgGridWrapper/wsAgGridWrapper.component';\r\n\r\n\r\nimport { ContractTermsPanelCompanyComponent } from './Contracts-Invoices/contract-terms-panel-company.component';\r\nimport { EngagementNumberLookupModalComponent } from './Contracts-Invoices/engagement-number-lookup-modal.component';\r\nimport { ContractTermsPanelSiteComponent } from './Contracts-Invoices/contract-terms-panel-site.component';\r\nimport { ChooseTermPopoverComponent } from './Contracts-Invoices/choose-term-popover.component';\r\nimport { TermRatesAndFeesComponent } from './Contracts-Invoices/term-rates-and-fees.component';\r\nimport { SaveAsIconComponent } from './SaveAsIcon/saveAsIcon.component';\r\nimport { CustomEmailTemplateModalComponent } from './Custom-Email-Template/custom-email-template-modal.component';\r\nimport { UserTeamPickerComponent } from './User-Pickers/user-team-picker.component';\r\nimport { PreviewEmailTemplateModalComponent } from './Custom-Email-Template/preview-email-template-modal.component';\r\nimport { AgGridLoadingOverlayComponent } from './AgGrid/agGridLoadingOverlay.component';\r\nimport { EntityInProgressIndicatorComponent } from './Entity/entity.in.progress.indicator.component';\r\nimport { ChangeHistoryModalComponent } from './Change-History/change-history-modal.component';\r\nimport { InvoiceModalComponent } from './Invoice/create-invoice-modal.component';\r\nimport { StateDropdownComponent } from './States/State-Dropdown/state.dropdown.component';\r\nimport { UserPickerComponent } from './User-Pickers/user.picker.component';\r\nimport { AddressViewEditComponent } from './Address/Address-View-Edit/address.view.edit.component';\r\nimport { AddressDetailsModalComponent } from './Address/Address-View-Edit/address.details.modal.component';\r\nimport { EntityAddressDeliverabilityIssueComponent } from './Address/Address-View-Edit/address.deliverability.issue';\r\nimport { StepProgressIndicatorModule } from './Step-Progress-Indicator/stepProgressIndicator.module';\r\nimport { BeginNewImportComponent } from './import/beginNewImport.component';\r\nimport { DeleteConfirmationComponent } from './Delete-Confirmation/deleteConfirmation.component';\r\nimport { GoogleMapsSingleMarkerModalComponent } from './Address/google.maps.single.marker.modal.component';\r\nimport { CategoryColumnPickerComponent } from './AV-AS/category.column.picker.component';\r\nimport { InstanceFilterComponent } from './Instance-Filter/instanceFilter.component';\r\nimport { ColumnFiltersComponent } from './AV-AS/Column-Filters/columnFilters.component';\r\nimport { CompanyPickerComponent } from './Company-Picker/companyPicker.component';\r\nimport { StampModule } from './Stamp/stamp.module';\r\nimport { StampComponent } from './Stamp/stamp.component';\r\nimport { WarningMessageComponent } from './Warning-Message/warningMessage.component';\r\nimport { SwitchComponent } from '../UI-Lib/Switch/switch.component';\r\nimport { ExpandCellRendererComponent } from './AgGrid/agGridExpandCellRenderer.component';\r\nimport {\r\n ExpandCellHeaderRendererComponent\r\n} from './AgGrid/agGridExpandCellHeaderRenderer.component';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n UILibModule,\r\n TooltipModule,\r\n ModalModule,\r\n BsDropdownModule,\r\n CurrencyMaskModule,\r\n CarouselModule,\r\n PopoverModule,\r\n QuillModule,\r\n TypeaheadModule,\r\n ProgressbarModule,\r\n NgxFileDropModule,\r\n BusyIndicatorModule,\r\n TabsModule,\r\n StepProgressIndicatorModule,\r\n AgGridExtensionsModule,\r\n WsAgGridWrapperModule,\r\n GoogleMapsModule,\r\n SortableModule,\r\n BrowserAnimationsModule,\r\n AccordionModule,\r\n StampModule,\r\n ColumnPickerModule,\r\n CommentsModule,\r\n ActivityModule,\r\n AssessmentTaxesDetailsModule\r\n ],\r\n declarations: [\r\n AgGridLoadingOverlayComponent,\r\n SaveAsIconComponent,\r\n EntityAttachmentsComponent,\r\n PDFViewerComponent,\r\n ContractTermsPanelCompanyComponent,\r\n ContractTermsPanelSiteComponent,\r\n EngagementNumberLookupModalComponent,\r\n ChooseTermPopoverComponent,\r\n CustomEmailTemplateModalComponent,\r\n PreviewEmailTemplateModalComponent,\r\n UserTeamPickerComponent,\r\n EntityInProgressIndicatorComponent,\r\n ChangeHistoryModalComponent,\r\n InvoiceModalComponent,\r\n TermRatesAndFeesComponent,\r\n StateDropdownComponent,\r\n UserPickerComponent,\r\n AddressViewEditComponent,\r\n AddressDetailsModalComponent,\r\n EntityAddressDeliverabilityIssueComponent,\r\n BeginNewImportComponent,\r\n DeleteConfirmationComponent,\r\n GoogleMapsSingleMarkerModalComponent,\r\n PDFControlsComponent,\r\n CategoryColumnPickerComponent,\r\n InstanceFilterComponent,\r\n ColumnFiltersComponent,\r\n CompanyPickerComponent,\r\n WarningMessageComponent,\r\n ExpandCellRendererComponent,\r\n ExpandCellHeaderRendererComponent\r\n ],\r\n providers: [\r\n PercentPipe\r\n ],\r\n exports: [\r\n //Modules\r\n AccordionModule,\r\n AgGridExtensionsModule,\r\n BsDropdownModule,\r\n CarouselModule,\r\n ColumnPickerModule,\r\n CommentsModule,\r\n CommonModule,\r\n CurrencyMaskModule,\r\n FormsModule,\r\n ModalModule,\r\n PopoverModule,\r\n ProgressbarModule,\r\n ReactiveFormsModule,\r\n StampModule,\r\n TabsModule,\r\n TooltipModule,\r\n TypeaheadModule,\r\n UILibModule,\r\n AssessmentTaxesDetailsModule,\r\n //Components\r\n SaveAsIconComponent,\r\n EntityAttachmentsComponent,\r\n UserTeamPickerComponent,\r\n AgGridLoadingOverlayComponent,\r\n EntityInProgressIndicatorComponent,\r\n AddressViewEditComponent,\r\n BeginNewImportComponent,\r\n DeleteConfirmationComponent,\r\n UserPickerComponent,\r\n PDFControlsComponent,\r\n PDFViewerComponent,\r\n CategoryColumnPickerComponent,\r\n InstanceFilterComponent,\r\n ColumnFiltersComponent,\r\n CompanyPickerComponent,\r\n WsAgGridWrapperComponent,\r\n StateDropdownComponent,\r\n ContractTermsPanelCompanyComponent,\r\n WarningMessageComponent,\r\n TermRatesAndFeesComponent,\r\n ExpandCellRendererComponent,\r\n ExpandCellHeaderRendererComponent\r\n ]\r\n})\r\nexport class WeissmanSharedModule {\r\n static setupModule(): void {\r\n ActivityModule.setupModule();\r\n UILibModule.setupModule();\r\n BusyIndicatorModule.setupModule();\r\n ColumnPickerModule.setupModule();\r\n AssessmentTaxesDetailsModule.setupModule();\r\n hybridAdapterUtility.downgradeNg2Component('contractTermsPanelCompany', ContractTermsPanelCompanyComponent);\r\n hybridAdapterUtility.downgradeNg2Component('contractTermsPanelSite', ContractTermsPanelSiteComponent);\r\n hybridAdapterUtility.downgradeNg2Component('wsSaveAsIcon', SaveAsIconComponent);\r\n hybridAdapterUtility.downgradeNg2Component('addressViewEdit', AddressViewEditComponent);\r\n hybridAdapterUtility.downgradeNg2Component('categoryColumnPicker', CategoryColumnPickerComponent);\r\n hybridAdapterUtility.downgradeNg2Component('instanceFilter', InstanceFilterComponent);\r\n hybridAdapterUtility.downgradeNg2Component('columnFilters', ColumnFiltersComponent);\r\n hybridAdapterUtility.downgradeNg2Component('wsStamp', StampComponent);\r\n hybridAdapterUtility.downgradeNg2Component('wsSwitch', SwitchComponent);\r\n hybridAdapterUtility.downgradeNg2Component('wsColumnFilters', ColumnFiltersComponent);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { KeyTransmittalPublicData } from './external-api.models';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class ExternalAPIService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n getKeyTransmittalPublicData(requestCode: string): Promise {\r\n return this.http.get(`/api/ExternalAPIConfig/KeyTransmittalRequest/${ requestCode }/PublicData`, {\r\n handleCode: 404\r\n });\r\n }\r\n\r\n getPrivateKey(requestCode: string): Promise {\r\n return this.http.get(`/api/ExternalApiConfig/KeyTransmittalRequest/${ requestCode }/PrivateKey`, {\r\n handleCode: 404\r\n });\r\n }\r\n}\r\n","
\r\n\t
\r\n\t\t

External API Key

\r\n
\r\n \r\n
\r\n

{{errorMessage}}

\r\n
\r\n

Your public key is:

\r\n
{{keyTransmittalPublicData.publicKey}}
\r\n
\r\n
\r\n

\r\n Note: once you get the private key this request will expire; if you lose the key you will have to\r\n request a new API key email\r\n

\r\n
\r\n
\r\n

Your private key is:

\r\n
{{privateKey}}
\r\n

\r\n Please record this information in a secure location; if you lose this key you will have to request a\r\n new API key email\r\n

\r\n
\r\n
\r\n
\r\n

\r\n (back to home page)\r\n

\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { KeyTransmittalPublicData } from './external-api.models';\r\nimport { ExternalAPIService } from './external-api.service';\r\n\r\n@Component({\r\n selector: 'external-api-key',\r\n templateUrl: './external-api-key.component.html'\r\n})\r\nexport class ExternalAPIKeyComponent implements OnInit {\r\n constructor(private externalAPIService: ExternalAPIService,\r\n private navigationServiceHandler: UpgradeNavigationServiceHandler) { }\r\n\r\n requestCode: string;\r\n errorMessage: string;\r\n loading: boolean;\r\n keyTransmittalPublicData: KeyTransmittalPublicData;\r\n privateKey: string;\r\n\r\n ngOnInit() {\r\n this.privateKey = undefined;\r\n this.loading = false;\r\n this.requestCode = this.navigationServiceHandler.getQuerystringParam('requestCode');\r\n // I have a complaint in the API code about this too; Angular UI-Router dies without error message or any clues if a url\r\n // parameter is a UUID. I coded the API to send emails with UUIDs in the URL with the dashes removed as a workaround. A\r\n // better workaround would be to stop using Angular UI-Router, considering the insane amount of trouble it's given us.\r\n // In the meantime, check that this is a 32-character long string of hex characters and reconstruct the UUID if so.\r\n const rcMatch = /^([0-9a-fA-F]{8})([0-9a-fA-F]{4})([0-9a-fA-F]{4})([0-9a-fA-F]{4})([0-9a-fA-F]{12})$/.exec(this.requestCode);\r\n if (rcMatch) {\r\n this.requestCode = rcMatch.slice(1).join('-');\r\n this.loading = true;\r\n try {\r\n this.externalAPIService.getKeyTransmittalPublicData(this.requestCode).then(r => {\r\n this.keyTransmittalPublicData = r;\r\n }, err => {\r\n console.log(err);\r\n if (err.status === 404) {\r\n this.errorMessage = 'Key request not found; most likely the request either expired after 24 hours or the private key has already been obtained. A private key request can only be used one time; you will need to contact an administrator and ask for your private key again if you do not know it.';\r\n }\r\n });\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n else {\r\n this.requestCode = undefined;\r\n }\r\n }\r\n\r\n getPrivateKey() {\r\n this.loading = true;\r\n try {\r\n this.externalAPIService.getPrivateKey(this.requestCode).then(k => {\r\n this.privateKey = k;\r\n }, err => {\r\n console.log(err);\r\n if (err.status === 404) {\r\n this.errorMessage = 'Key request not found; most likely the request either expired after 24 hours or the private key has already been obtained. A private key request can only be used one time; you will need to contact an administrator and ask for your private key again if you do not know it.';\r\n }\r\n });\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n backToHomepage_Click() {\r\n this.navigationServiceHandler.go('home', {});\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { ChangePasswordComponent } from './Change-Password/changePassword.component';\r\nimport { ExternalAPIKeyComponent } from './ExternalAPI/external-api-key.component';\r\nimport { NewPasswordComponent } from './New-Password/newPassword.component';\r\n\r\n@NgModule({\r\n imports: [ WeissmanSharedModule ],\r\n declarations: [\r\n ExternalAPIKeyComponent,\r\n NewPasswordComponent,\r\n ChangePasswordComponent\r\n ],\r\n exports: [\r\n ExternalAPIKeyComponent,\r\n NewPasswordComponent,\r\n ChangePasswordComponent\r\n ]\r\n})\r\nexport class AccountModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('externalApiKey', ExternalAPIKeyComponent);\r\n hybridAdapterUtility.downgradeNg2Component('externalApiKey', ExternalAPIKeyComponent);\r\n }\r\n}\r\n","\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'accruals-bulk-update-modal',\r\n templateUrl: './accruals.bulk.update.modal.component.html',\r\n})\r\nexport class AccrualsBulkUpdateModalComponent implements OnInit {\r\n constructor(\r\n private bsModalRef: BsModalRef\r\n ) { }\r\n\r\n onClose: (request?: Core.AccrualsBulkUpdateRequestModel) => void;\r\n selectedCount: number;\r\n showOverrideChangeReason: boolean;\r\n\r\n headerLabel: string;\r\n editReq: Core.AccrualsBulkUpdateRequestModel = {} as Core.AccrualsBulkUpdateRequestModel;\r\n\r\n editOptions: Compliance.NameValuePair[] =\r\n [\r\n { name: '--select an Action--', value: Core.AccrualsBulkUpdateOperationEnum.None },\r\n { name: 'Convert True Up to \"Before\" Adjustment', value: Core.AccrualsBulkUpdateOperationEnum.ConvertTrueUpToBeforeAdjustment },\r\n { name: 'Remove \"Before\" Adjustment', value: Core.AccrualsBulkUpdateOperationEnum.RemoveBeforeAdjustment },\r\n { name: 'Remove \"After\" Adjustment', value: Core.AccrualsBulkUpdateOperationEnum.RemoveAfterAdjustment },\r\n ];\r\n OverrideReportedChangeReason: Core.AccrualsBulkUpdateOperationEnum = Core.AccrualsBulkUpdateOperationEnum.OverrideReportedChangeReason;\r\n ConvertTrueUpToBeforeAdjustment: Core.AccrualsBulkUpdateOperationEnum = Core.AccrualsBulkUpdateOperationEnum.ConvertTrueUpToBeforeAdjustment;\r\n\r\n commonBulkUpdateFieldActions: Compliance.NameValuePair[] =\r\n [\r\n { name: 'No Change', value: Core.CommonBulkUpdateFieldActionEnum.NoChange },\r\n { name: 'Set to Blank', value: Core.CommonBulkUpdateFieldActionEnum.SetToBlank },\r\n { name: 'Remove Override', value: Core.CommonBulkUpdateFieldActionEnum.RemoveOverride },\r\n { name: 'Change To', value: Core.CommonBulkUpdateFieldActionEnum.ChangeTo },\r\n ];\r\n ChangeTo: Core.CommonBulkUpdateFieldActionEnum = Core.CommonBulkUpdateFieldActionEnum.ChangeTo;\r\n\r\n\r\n async ngOnInit() {\r\n this.editReq.operation = Core.AccrualsBulkUpdateOperationEnum.None;\r\n this.editReq.reportedChangeReasonAction = Core.CommonBulkUpdateFieldActionEnum.NoChange;\r\n\r\n if (this.showOverrideChangeReason) {\r\n this.editOptions.push({ name: 'Override Reported Change Reason', value: Core.AccrualsBulkUpdateOperationEnum.OverrideReportedChangeReason });\r\n }\r\n\r\n this.headerLabel = `Bulk Update ${this.selectedCount} Accruals entries`;\r\n }\r\n\r\n isSaveable(): boolean {\r\n if (this.editReq.operation === Core.AccrualsBulkUpdateOperationEnum.None) {\r\n return false;\r\n }\r\n\r\n if(this.editReq.operation == Core.AccrualsBulkUpdateOperationEnum.OverrideReportedChangeReason) {\r\n return this.editReq.reportedChangeReasonAction != Core.CommonBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n\r\n if(this.editReq.operation == Core.AccrualsBulkUpdateOperationEnum.ConvertTrueUpToBeforeAdjustment) {\r\n return !!this.editReq.adjustmentDescription;\r\n }\r\n\r\n return true;\r\n }\r\n\r\n async save(): Promise {\r\n this.editReq.reportedChangeReason = _.trim(this.editReq.reportedChangeReason);\r\n\r\n this.bsModalRef.hide();\r\n this.onClose(this.editReq);\r\n }\r\n\r\n cancel() {\r\n this.bsModalRef.hide();\r\n this.onClose();\r\n }\r\n}\r\n","
\r\n
\r\n
    \r\n
  1. \r\n {{parentCompany.name}}\r\n
  2. \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Accruals

\r\n
\r\n
\r\n
View:
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n {{startAccountingPeriod.periodDuration}}\r\n
\r\n
\r\n \r\n \r\n \r\n - \r\n \r\n
\r\n
\r\n CLOSED\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n {{endAccountingPeriod.periodDuration}}\r\n
\r\n
\r\n \r\n \r\n \r\n - \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n Close Accounting Period\r\n \r\n \r\n Re-open Accounting Period\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
    \r\n
  1. \r\n {{parentCompany.name}}\r\n
  2. \r\n \r\n
\r\n
\r\n
\r\n
\r\n

The Company has less than two (2) Fiscal Years of Accounting Periods configured

\r\n

OR

\r\n

does not have one (1) of each Accruals type G/L Accounts provisioned (Payable, Prepaid, Cash, Expense).

\r\n
\r\n

The Accruals Command Center cannot be accessed until this is corrected.

\r\n
\r\n
\r\n\r\n
\r\n
\r\n

Bulk Updating

\r\n

Done

\r\n \r\n \r\n

{{getCurrentBulkUpdateIdentity()}}

\r\n
\r\n
\r\n

Canceled

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n
\r\n \r\n {{bulkUpdateCurrent.index - 1}}
\r\n \r\n {{bulkUpdateTotals.rowsChanged}}
\r\n \r\n {{bulkUpdateTotals.billsChanged}}
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport {\r\n ColGroupDef,\r\n ColumnApi,\r\n ColumnEventType,\r\n ColumnResizedEvent,\r\n GridApi,\r\n GridOptions,\r\n GridReadyEvent,\r\n RowNode\r\n} from 'ag-grid-community';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { AgGridOptionsBuilder } from '../Compliance/AgGrid';\r\nimport { CompanyService } from '../Entity/Company/company.service';\r\nimport { AccrualsPageService } from './accruals.page.service';\r\nimport * as _ from 'lodash';\r\nimport {\r\n AccrualsColumnFiltersUI,\r\n AccrualsGridAvailableFiltersModelUI,\r\n AccrualsGridBillRecurTypeEnum,\r\n AccrualsGridSummarizeByEnum,\r\n AccrualsGridViewModeEnum,\r\n ColumnFiltersOptionsEnum,\r\n JournalOptionsEnum\r\n} from './accruals.page.model';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../Compliance/AgGrid/ToolPanel/models';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { BehaviorSubject, lastValueFrom, Subject, takeUntil } from 'rxjs';\r\nimport { InstanceRights, RestrictService } from '../Common/Permissions/restrict.service';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { AccrualsBulkUpdateModalComponent } from './accruals.bulk.update.modal.component';\r\nimport { AttachmentModalData } from '../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../Comments/comments.service';\r\nimport { InstanceRepository } from '../Entity/Instance/instance.repository';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport { SnackBarService } from '../Busy-Indicator';\r\nimport { WebsocketListenerService } from 'src/app/Compliance/websocketListener.service';\r\n\r\n@Component({\r\n selector: 'accruals-page',\r\n templateUrl: './accruals.page.component.html',\r\n styleUrls: ['./accruals.page.component.scss']\r\n})\r\nexport class AccrualsPageComponent implements OnInit {\r\n constructor(private _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private _companyService: CompanyService,\r\n private _accrualsPageService: AccrualsPageService,\r\n private _messageBoxService: MessageBoxService,\r\n private _toastrService: ToastrService,\r\n private _restrictService: RestrictService,\r\n private _modalService: BsModalService,\r\n private _instanceRepository: InstanceRepository,\r\n private _snackBarService: SnackBarService,\r\n private _websocketListenerService: WebsocketListenerService\r\n ) { }\r\n\r\n parentCompanyId: number;\r\n parentCompany: Core.NameIdPair;\r\n isMaximized: boolean = false;\r\n isEditMode: boolean = false;\r\n hasEditPermission: boolean = false;\r\n isSetupInvalid: boolean = false;\r\n showApplyButton: boolean = true;\r\n loading: boolean = false;\r\n closingPeriod: boolean = false;\r\n creatingExportFile: boolean = false;\r\n gettingGrid: boolean = false;\r\n activeLongRunningProcessId: number = 0;\r\n\r\n lastClosedAccountingPeriodId: number = null;\r\n firstOpenAccountingPeriodId: number = null;\r\n\r\n gridApi: GridApi;\r\n gridOptions: GridOptions;\r\n columnApi: ColumnApi;\r\n columnSizing: ColumnEventType = 'sizeColumnsToFit';\r\n\r\n accountingPeriods: Core.AccrualsGridAccountingPeriodModel[];\r\n availableFilters: AccrualsGridAvailableFiltersModelUI;\r\n columnFilters: AccrualsColumnFiltersUI = new AccrualsColumnFiltersUI();\r\n\r\n searchModel: Core.AccrualsGridSearchModel = {} as Core.AccrualsGridSearchModel;\r\n resultsModel: Core.AccrualsGridResultsModel;\r\n\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n bulkUpdateInProgress: boolean = false;\r\n bulkUpdateCurrent: { index: number, entry: Core.AccrualsGridEntryModel };\r\n bulkUpdateTotals: { rowsChanged: number, billsChanged: number };\r\n selectionsLength: number;\r\n bulkUpdateCanceled: boolean = false;\r\n reselectGridNodes: boolean = false;\r\n\r\n percentVarianceThresholdDisplay: number;\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[]): Promise => {\r\n const request = {\r\n columnFilters: [],\r\n sortColumns: [],\r\n columnsToReturn: columnsToReturn,\r\n ...this.searchModel,\r\n ...this.columnFilters\r\n } as any;\r\n\r\n const longRunningProcessId = await this._accrualsPageService.exportToExcel(this.searchModel.tlCompanyId, request);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportAccrualsGridToExcel };\r\n },\r\n canCancel: true,\r\n disabled: false\r\n };\r\n selectedIds: number[];\r\n\r\n readonly AccrualsGridViewModeEnum = AccrualsGridViewModeEnum;\r\n readonly AccrualsGridSummarizeByEnum = AccrualsGridSummarizeByEnum;\r\n readonly AccrualsGridBillRecurTypeEnum = AccrualsGridBillRecurTypeEnum;\r\n readonly ColumnFiltersOptionsEnum = ColumnFiltersOptionsEnum;\r\n readonly JournalOptionsEnum = JournalOptionsEnum;\r\n\r\n private readonly LARGE_BULK_UPDATE_THRESHOLD: number = 100;\r\n\r\n private _startAccountingPeriod: Core.AccrualsGridAccountingPeriodModel;\r\n private _endAccountingPeriod: Core.AccrualsGridAccountingPeriodModel;\r\n private _startAccountingPeriodId: number;\r\n private _endAccountingPeriodId: number;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get operationInProgress(): boolean {\r\n return this.loading || this.closingPeriod || this.creatingExportFile || this.gettingGrid;\r\n }\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.startAccountingPeriod) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: 'ACCOUNTINGPERIOD',\r\n entityName: this.startAccountingPeriod.name,\r\n entityData: {\r\n typeId: Core.EntityTypes.AccountingPeriod,\r\n id: this.startAccountingPeriod.accountingPeriodId,\r\n name: this.startAccountingPeriod.name\r\n },\r\n readOnly: !this.hasEditPermission\r\n } as AttachmentModalData;\r\n }\r\n\r\n get commentsModel(): CommentModalData {\r\n if (!this.startAccountingPeriod) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityID: this.startAccountingPeriod.accountingPeriodId,\r\n entityTypeID: Core.EntityTypes.AccountingPeriod,\r\n description: this.startAccountingPeriod.name,\r\n canEdit: this.hasEditPermission\r\n } as CommentModalData;\r\n }\r\n\r\n get isBulkUpdateDone() {\r\n return this.bulkUpdateCurrent && this.bulkUpdateCurrent.index >= this.selectionsLength;\r\n }\r\n\r\n get isSummarizeByBills(): boolean {\r\n return this.searchModel.filters.summarizeBy === Core.AccrualsGridSummarizeByEnum.Bills;\r\n }\r\n\r\n get isExportable() {\r\n return this.startAccountingPeriod && this.resultsModel && this.resultsModel.isExportable;\r\n }\r\n\r\n get isExportTransmittable() {\r\n return this.startAccountingPeriod && this.resultsModel && this.resultsModel.isExportTransmittable;\r\n }\r\n\r\n get startAccountingPeriod() {\r\n return this._startAccountingPeriod;\r\n }\r\n set startAccountingPeriod(period) {\r\n this._startAccountingPeriod = period;\r\n this._startAccountingPeriodId = period?.accountingPeriodId;\r\n }\r\n\r\n get endAccountingPeriod() {\r\n return this._endAccountingPeriod;\r\n }\r\n set endAccountingPeriod(period) {\r\n this._endAccountingPeriod = period;\r\n this._endAccountingPeriodId = period?.accountingPeriodId;\r\n }\r\n\r\n async ngOnInit() {\r\n this.parentCompanyId = +this._upgradeNavigationServiceHandler.getQuerystringParam('companyId');\r\n await this._initValues();\r\n }\r\n\r\n async loadLongRunningStatus() {\r\n this.loading = true;\r\n\r\n try {\r\n const lrpStatus = await this._accrualsPageService.getLongRunningProcessStatus(this.searchModel.tlCompanyId);\r\n\r\n this.closingPeriod = lrpStatus.periodCloseInProgress;\r\n this.creatingExportFile = lrpStatus.exportInProgress;\r\n this.gettingGrid = lrpStatus.gridGetInProgress;\r\n\r\n if ( this.closingPeriod ) {\r\n this._toastrService.info('A Close/Re-open Accounting Period operation is in progress for this company.');\r\n }\r\n else if ( this.creatingExportFile ) {\r\n this._toastrService.info('A Create Export File operation is in progress for this company.');\r\n }\r\n else if ( this.gettingGrid ) {\r\n this._toastrService.info('A Grid display/refresh operation is in progress for this company.');\r\n }\r\n if ( this.closingPeriod || this.creatingExportFile || this.gettingGrid ) {\r\n this.activeLongRunningProcessId = lrpStatus.activeLongRunningProcessId;\r\n this.exportOptions.disabled = true;\r\n this.refreshBulkUpdateState();\r\n this._showGridSpinner();\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async loadFilters() {\r\n this.loading = true;\r\n\r\n try {\r\n await this._getAvailableFilters();\r\n\r\n this.parentCompany = _.find(this.availableFilters.companies, { id: this.parentCompanyId });\r\n\r\n // This was put here so that parentCompany could be set for the breadcrumb\r\n // when the invalid setup page is displayed.\r\n const validateSetupModel = await this._accrualsPageService.checkValidateSetup(this.searchModel.tlCompanyId);\r\n this.isSetupInvalid = validateSetupModel.noAccountingPeriods || validateSetupModel.incompleteGLAccounts;\r\n\r\n if ( this.isSetupInvalid )\r\n {\r\n this.loading = false;\r\n this.gridApi.showNoRowsOverlay();\r\n return;\r\n }\r\n\r\n this._setEntityFilters();\r\n\r\n await this._getAccountingPeriods();\r\n if (!this.accountingPeriods.length) {\r\n this.gridApi.showNoRowsOverlay();\r\n this._toastrService.info('Fiscal Years are not yet setup for this company!');\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n toggleMaximize(isMaximized: boolean): void {\r\n this.isMaximized = isMaximized;\r\n }\r\n\r\n goToParentCompany(): void {\r\n this._upgradeNavigationServiceHandler.go('company', { companyId: this.parentCompany.id });\r\n }\r\n\r\n toggleEditMode(isEdit: boolean) {\r\n this.isEditMode = isEdit;\r\n this.refreshBulkUpdateState();\r\n }\r\n\r\n refreshBulkUpdateState() {\r\n const isBulkUpdateVisible = this.isEditMode && this.gridApi.getSelectedNodes().length > 0 && !this.operationInProgress;\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n }\r\n\r\n async singlePeriodSelected() {\r\n this.searchModel.mode = Core.AccrualsGridViewModeEnum.SinglePeriod;\r\n\r\n this.endAccountingPeriod = undefined;\r\n this.searchModel.filters.endAccountingPeriodId = this.searchModel.filters.startAccountingPeriodId;\r\n\r\n this.showApplyButton = true;\r\n }\r\n\r\n async periodRangeSelected() {\r\n this.searchModel.mode = Core.AccrualsGridViewModeEnum.PeriodRange;\r\n\r\n this._initSelectedAccountingPeriodEnd();\r\n\r\n this.showApplyButton = true;\r\n }\r\n\r\n async previewCloseSelected() {\r\n if (!this.firstOpenAccountingPeriodId) {\r\n // No First Open AP. Prevew Close mode not valid. Fallback to Single Period mode.\r\n await this.singlePeriodSelected();\r\n return;\r\n }\r\n\r\n this.searchModel.mode = Core.AccrualsGridViewModeEnum.PreviewClose;\r\n\r\n this._startAccountingPeriod = _.find(this.accountingPeriods, { accountingPeriodId: this.firstOpenAccountingPeriodId });\r\n\r\n this.endAccountingPeriod = undefined;\r\n this.searchModel.filters.endAccountingPeriodId = this.searchModel.filters.startAccountingPeriodId;\r\n\r\n this.showApplyButton = true;\r\n }\r\n\r\n async accountingPeriodChanged(): Promise {\r\n this.selectedIds = _.map(this.gridApi.getSelectedRows(), row => this._getRowEntityId(row));\r\n\r\n if ( this.searchModel.mode === Core.AccrualsGridViewModeEnum.PreviewClose &&\r\n (!this.firstOpenAccountingPeriodId || this.startAccountingPeriod.accountingPeriodId !== this.firstOpenAccountingPeriodId) ) {\r\n // Selected an Accounting Period other than First Open in Preview Close mode.\r\n // Switch to Single Period mode.\r\n await this.singlePeriodSelected();\r\n }\r\n else {\r\n this.searchModel.filters.startAccountingPeriodId = this.startAccountingPeriod.accountingPeriodId;\r\n\r\n this.searchModel.filters.endAccountingPeriodId = this.searchModel.mode === Core.AccrualsGridViewModeEnum.PeriodRange\r\n ? this.endAccountingPeriod.accountingPeriodId\r\n : this.startAccountingPeriod.accountingPeriodId;\r\n }\r\n\r\n this.reselectGridNodes = true;\r\n this.showApplyButton = true;\r\n }\r\n\r\n async companiesSelected(eventTarget: EventTarget): Promise {\r\n this.availableFilters.states = this.availableFilters.propertyTypes = [];\r\n this.searchModel.filters.companyIds = _.map((eventTarget as HTMLSelectElement).selectedOptions, (option: any) => Number(option.value));\r\n\r\n this._setEntityFilters();\r\n\r\n this.showApplyButton = true;\r\n }\r\n\r\n async statesSelected(eventTarget: EventTarget): Promise {\r\n this.searchModel.filters.stateIds = _.map((eventTarget as HTMLSelectElement).selectedOptions, (option: any) => Number(option.value));\r\n\r\n this.showApplyButton = true;\r\n }\r\n\r\n async propertyTypesSelected(eventTarget: EventTarget): Promise {\r\n this.searchModel.filters.propertyTypeIds = _.map((eventTarget as HTMLSelectElement).selectedOptions, (option: any) => Number(option.value));\r\n\r\n this.showApplyButton = true;\r\n }\r\n\r\n setColumns(): void {\r\n const gridColumnGroups: ColGroupDef[] = this._accrualsPageService.getGridColumns(this.searchModel, this.columnFilters, this.resultsModel) as ColGroupDef[];\r\n this.gridApi.setColumnDefs(gridColumnGroups);\r\n this._orderColumns(gridColumnGroups);\r\n }\r\n\r\n async handleLRPStatusChange(x: Compliance.LongRunningProcessStatusChangeModel): Promise {\r\n\r\n const validProcessTypes = [Compliance.LongRunningProcessTypeEnum.CloseAccrualAccountingPeriod,\r\n Compliance.LongRunningProcessTypeEnum.ReopenAccrualAccountingPeriod,\r\n Compliance.LongRunningProcessTypeEnum.ExportAccrualDataToFile,\r\n Compliance.LongRunningProcessTypeEnum.AccrualsGridGet];\r\n if (!validProcessTypes.includes(x.processType) ||\r\n !(x.isCanceled || x.isError || x.isCompleted) ||\r\n x.entityId !== this.searchModel.tlCompanyId) {\r\n // Not an event we are interested in, or not for our TL Company.\r\n return;\r\n }\r\n\r\n console.log(`event.lrpid=${x.longRunningProcessId}, active.lrpid=${this.activeLongRunningProcessId}`);\r\n console.log(`event: Canceled=${x.isCanceled}, Completed=${x.isCompleted}, Error=${x.isError}`);\r\n console.log(`closingPeriod=${this.closingPeriod}, creatingExportFile=${this.creatingExportFile}, gettingGrid=${this.gettingGrid}`);\r\n if (this.activeLongRunningProcessId !== x.longRunningProcessId)\r\n {\r\n console.log('DROPPING LRP EVENT');\r\n return;\r\n }\r\n\r\n switch ( x.processType ) {\r\n case Compliance.LongRunningProcessTypeEnum.CloseAccrualAccountingPeriod:\r\n if ( this.closingPeriod ) {\r\n if (x.isError && x.errorMessage) {\r\n this._toastrService.error(x.errorMessage);\r\n }\r\n else {\r\n this._toastrService.info('Accounting Period was successfully closed.');\r\n }\r\n\r\n this.closingPeriod = false;\r\n this.activeLongRunningProcessId = 0;\r\n this.exportOptions.disabled = false;\r\n this.refreshBulkUpdateState();\r\n await this._getAccountingPeriods();\r\n this._hideGridSpinner();\r\n\r\n if ( !x.isCanceled && !x.isError ) {\r\n await this.startGridDisplay();\r\n }\r\n }\r\n break;\r\n case Compliance.LongRunningProcessTypeEnum.ReopenAccrualAccountingPeriod:\r\n if ( this.closingPeriod ) {\r\n if (x.isError && x.errorMessage) {\r\n this._toastrService.error(x.errorMessage);\r\n }\r\n else {\r\n this._toastrService.info('Accounting Period was successfully re-opened.');\r\n }\r\n\r\n this.closingPeriod = false;\r\n this.activeLongRunningProcessId = 0;\r\n this.exportOptions.disabled = false;\r\n this.refreshBulkUpdateState();\r\n await this._getAccountingPeriods();\r\n this._hideGridSpinner();\r\n\r\n if ( !x.isCanceled && !x.isError ) {\r\n await this.startGridDisplay();\r\n }\r\n }\r\n break;\r\n case Compliance.LongRunningProcessTypeEnum.ExportAccrualDataToFile:\r\n if ( this.creatingExportFile ) {\r\n if (x.isError && x.errorMessage) {\r\n this._toastrService.error(x.errorMessage);\r\n }\r\n else {\r\n this._toastrService.info('Export File was successfully added as an attachment.');\r\n }\r\n\r\n this.creatingExportFile = false;\r\n this.activeLongRunningProcessId = 0;\r\n this.exportOptions.disabled = false;\r\n this.refreshBulkUpdateState();\r\n this._hideGridSpinner();\r\n }\r\n break;\r\n case Compliance.LongRunningProcessTypeEnum.AccrualsGridGet:\r\n if ( this.gettingGrid ) {\r\n if (x.isError && x.errorMessage) {\r\n this._toastrService.error(x.errorMessage);\r\n }\r\n\r\n if ( !x.isCanceled && !x.isError ) {\r\n await this._snackBarService.removeById(x.longRunningProcessId);\r\n\r\n await this.loadGridResults(x.longRunningProcessId);\r\n }\r\n\r\n this.gettingGrid = false;\r\n this.activeLongRunningProcessId = 0;\r\n this.exportOptions.disabled = false;\r\n this.refreshBulkUpdateState();\r\n this._hideGridSpinner();\r\n if ( x.isCanceled || x.isError ) {\r\n this.loading = false;\r\n }\r\n }\r\n break;\r\n }\r\n }\r\n\r\n async startGridDisplay(): Promise {\r\n if (this.gridApi) {\r\n // Check request against threshold for using LRP.\r\n // If request is under the threshold, the original API that returns the\r\n // results is called, bypassing LRP.\r\n // If request is over the threshold, the API that retrieves the Grid via\r\n // LRP is called.\r\n const thresholdResult = await this._accrualsPageService.checkAccrualsGridThreshold(this.searchModel.tlCompanyId, this.searchModel);\r\n console.log(`CheckThreshold: ParcelCount=${thresholdResult.parcelCount}, useLRP=${thresholdResult.useLongRunningProcess}`);\r\n const useLRP: boolean = thresholdResult.useLongRunningProcess;\r\n\r\n if (useLRP) {\r\n // Start long running process to retrieve Grid\r\n await this._startGettingGridData();\r\n }\r\n else {\r\n // Retrieve Grid without long running process, returning results directly.\r\n this._startLoadingGrid();\r\n\r\n try {\r\n this.resultsModel = await this._accrualsPageService.getAccrualsGridData(this.searchModel.tlCompanyId, this.searchModel);\r\n this.gridApi.setRowData(this.resultsModel.entries);\r\n\r\n this._completeGridDisplay();\r\n } finally {\r\n this._stopLoadingGrid();\r\n }\r\n }\r\n }\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this.gridApi = event.api;\r\n this.columnApi = event.columnApi;\r\n\r\n this.gridApi.hideOverlay();\r\n await this.loadFilters();\r\n await this.loadLongRunningStatus();\r\n }\r\n\r\n async refresh() {\r\n await this.loadFilters();\r\n await this.loadLongRunningStatus();\r\n await this.startGridDisplay();\r\n }\r\n\r\n async closeAccountingPeriod() {\r\n if ((await this._messageBoxService.open({\r\n message: 'Are you sure you want to Close this accounting period?',\r\n buttons: MessageBoxButtons.YesNo\r\n })) === MessageBoxResult.Yes) {\r\n this.closingPeriod = true;\r\n this.exportOptions.disabled = true;\r\n this.refreshBulkUpdateState();\r\n this._showGridSpinner();\r\n try {\r\n const accountingPeriodId = this.startAccountingPeriod.accountingPeriodId;\r\n const lrp = await this._accrualsPageService.closeAccountingPeriod(this.parentCompany.id, accountingPeriodId);\r\n this.activeLongRunningProcessId = lrp.longRunningProcessId;\r\n this._snackBarService.addById(lrp.longRunningProcessId, Compliance.LongRunningProcessTypeEnum.CloseAccrualAccountingPeriod);\r\n } catch (e) {\r\n if(e.error) {\r\n this._toastrService.error(e.error.message);\r\n }\r\n this.closingPeriod = false;\r\n this.activeLongRunningProcessId = 0;\r\n this.exportOptions.disabled = false;\r\n this.refreshBulkUpdateState();\r\n this._hideGridSpinner();\r\n }\r\n }\r\n }\r\n\r\n async openAccountingPeriod() {\r\n if ((await this._messageBoxService.open({\r\n message: 'Are you sure you want to Re-open this accounting period?',\r\n buttons: MessageBoxButtons.YesNo\r\n })) === MessageBoxResult.Yes) {\r\n this.closingPeriod = true;\r\n this.exportOptions.disabled = true;\r\n this.refreshBulkUpdateState();\r\n this._showGridSpinner();\r\n try {\r\n const accountingPeriodId = this.startAccountingPeriod.accountingPeriodId;\r\n const lrp = await this._accrualsPageService.openAccountingPeriod(this.parentCompany.id, accountingPeriodId);\r\n this.activeLongRunningProcessId = lrp.longRunningProcessId;\r\n this._snackBarService.addById(lrp.longRunningProcessId, Compliance.LongRunningProcessTypeEnum.ReopenAccrualAccountingPeriod);\r\n } catch (e) {\r\n if(e.error) {\r\n this._toastrService.error(e.error.message);\r\n }\r\n this.closingPeriod = false;\r\n this.activeLongRunningProcessId = 0;\r\n this.exportOptions.disabled = false;\r\n this.refreshBulkUpdateState();\r\n this._hideGridSpinner();\r\n }\r\n }\r\n }\r\n\r\n async createExportFile(): Promise {\r\n this.creatingExportFile = true;\r\n this.exportOptions.disabled = true;\r\n this.refreshBulkUpdateState();\r\n this._showGridSpinner();\r\n\r\n try {\r\n const lrp = await this._accrualsPageService.createExportFile(this.searchModel.tlCompanyId, this.startAccountingPeriod.accountingPeriodId);\r\n this.activeLongRunningProcessId = lrp.longRunningProcessId;\r\n this._snackBarService.addById(lrp.longRunningProcessId, Compliance.LongRunningProcessTypeEnum.ExportAccrualDataToFile);\r\n } catch (e) {\r\n if(e.error) {\r\n this._toastrService.error(e.error.message);\r\n }\r\n this.creatingExportFile = false;\r\n this.activeLongRunningProcessId = 0;\r\n this.exportOptions.disabled = false;\r\n this._hideGridSpinner();\r\n this.refreshBulkUpdateState();\r\n }\r\n }\r\n\r\n async transmitFile(): Promise {\r\n const lrp = await this._accrualsPageService.startTransmitFile(this.startAccountingPeriod.accountingPeriodId, this.searchModel.tlCompanyId);\r\n this._snackBarService.addById(lrp.longRunningProcessId, Compliance.LongRunningProcessTypeEnum.TransmitAccrual);\r\n }\r\n\r\n async bulkUpdate() {\r\n const unfilteredSelections: Core.AccrualsGridEntryModel[] = await this._gatherBulkUpdateSelections();\r\n if (unfilteredSelections.length === 0) {\r\n return;\r\n }\r\n\r\n // Create lookup object, indexed by Accounting Period name, of the\r\n // Closed Accounting Periods in the selected contiguous range.\r\n const closedAccountingPeriods: { [key:string]: number } = {};\r\n if ( this.startAccountingPeriod )\r\n {\r\n const startNdx = _.findIndex(this.accountingPeriods, { accountingPeriodId: this.startAccountingPeriod.accountingPeriodId });\r\n const endNdx = 1 + (this.endAccountingPeriod\r\n ? _.findIndex(this.accountingPeriods, { accountingPeriodId: this.endAccountingPeriod.accountingPeriodId })\r\n : startNdx);\r\n _.each(this.accountingPeriods.slice(startNdx, endNdx), (entry) => {\r\n if ( entry.isFrozen )\r\n {\r\n closedAccountingPeriods[entry.name] = 0;\r\n }\r\n return true;\r\n });\r\n }\r\n\r\n // Filter out selections for Closed Accounting Periods, tallying\r\n // a count for each Accounting Period.\r\n const selections = _.filter(unfilteredSelections, (entry) => {\r\n if ( entry.accountingPeriod in closedAccountingPeriods )\r\n {\r\n closedAccountingPeriods[entry.accountingPeriod] += 1;\r\n return false;\r\n }\r\n return true;\r\n });\r\n if (selections.length === 0) {\r\n // All selections were for Closed accounting periods.\r\n this._toastrService.info('Unable to perform operation! All selections are for CLOSED Accounting Periods!');\r\n return;\r\n }\r\n // Show an info toast for each Closed Accounting Period that had 1 or more selections.\r\n _.each(closedAccountingPeriods, (count: number, apName: string) => {\r\n if ( count > 0 )\r\n {\r\n this._toastrService.info(`Warning: ${count} row updates will be skipped because Accounting Period '${apName}' is CLOSED`);\r\n }\r\n return true;\r\n });\r\n\r\n const initialState = {\r\n selectedCount: selections.length,\r\n showOverrideChangeReason: this.searchModel.filters.summarizeBy == Core.AccrualsGridSummarizeByEnum.EconomicUnit\r\n };\r\n\r\n const modalRef = this._modalService.show(AccrualsBulkUpdateModalComponent, { initialState, class: 'modal-lg', ignoreBackdropClick: true });\r\n\r\n modalRef.content.onClose = async (request?: Core.AccrualsBulkUpdateRequestModel) => {\r\n if(!request) {\r\n return;\r\n }\r\n\r\n request.filters = this.searchModel.filters;\r\n\r\n this.bulkUpdateInProgress = true;\r\n this.bulkUpdateTotals = {rowsChanged: null, billsChanged: null};\r\n this.selectionsLength = selections.length;\r\n\r\n for (const [i, selection] of selections.entries()) { // https://stackoverflow.com/questions/34348937/access-to-es6-array-element-index-inside-for-of-loop\r\n if(this.bulkUpdateCanceled) {\r\n break;\r\n }\r\n\r\n this.bulkUpdateCurrent = {\r\n index: i + 1,\r\n entry: selection\r\n };\r\n\r\n const {\r\n accountingPeriodId,\r\n companyId,\r\n siteId,\r\n parcelId,\r\n billClusterId,\r\n economicUnitTypeId,\r\n siteNumber,\r\n siteCode,\r\n stateId\r\n } = selection;\r\n\r\n request.selection = {\r\n accountingPeriodId,\r\n companyId,\r\n siteId,\r\n parcelId,\r\n billClusterId,\r\n economicUnitTypeId,\r\n siteNumber,\r\n siteCode,\r\n stateId\r\n };\r\n\r\n const result = await this._accrualsPageService.applyBulkUpdateToEntry(this.searchModel.tlCompanyId, request);\r\n\r\n if(result.billsChanged != null) {\r\n this.bulkUpdateTotals.billsChanged += result.billsChanged;\r\n }\r\n if(result.rowsChanged != null) {\r\n this.bulkUpdateTotals.rowsChanged += result.rowsChanged;\r\n }\r\n }\r\n\r\n this.bulkUpdateCurrent.index++;\r\n };\r\n }\r\n\r\n getCurrentBulkUpdateIdentity(): string {\r\n let identity: string = '';\r\n\r\n if (this.bulkUpdateCurrent) {\r\n identity = `[${this.bulkUpdateCurrent.index} of ${this.selectionsLength}] `;\r\n\r\n switch (this.searchModel.filters.summarizeBy) {\r\n case Core.AccrualsGridSummarizeByEnum.State:\r\n identity += `State: ${this.bulkUpdateCurrent.entry.stateName}`;\r\n break;\r\n case Core.AccrualsGridSummarizeByEnum.Company:\r\n identity += `Company: ${this.bulkUpdateCurrent.entry.companyName}`;\r\n break;\r\n case Core.AccrualsGridSummarizeByEnum.Site:\r\n identity += `Site Name: ${this.bulkUpdateCurrent.entry.siteName}`;\r\n break;\r\n case Core.AccrualsGridSummarizeByEnum.Parcel:\r\n identity += `Site Name: ${this.bulkUpdateCurrent.entry.siteName}`;\r\n identity += ` Parcel: ${this.bulkUpdateCurrent.entry.parcelAcctNum}`;\r\n break;\r\n case Core.AccrualsGridSummarizeByEnum.Bills:\r\n identity += `Site Name: ${this.bulkUpdateCurrent.entry.siteName}`;\r\n identity += ` Parcel: ${this.bulkUpdateCurrent.entry.parcelAcctNum}`;\r\n identity += ` Collector: ${this.bulkUpdateCurrent.entry.collectorAbbr}`;\r\n break;\r\n case Core.AccrualsGridSummarizeByEnum.EconomicUnit:\r\n switch (this.bulkUpdateCurrent.entry.economicUnitTypeId) {\r\n case Core.AccrualEconomicUnitTypeEnum.SiteNumber:\r\n identity += `Site Number: ${this.bulkUpdateCurrent.entry.siteNumber}`;\r\n break;\r\n case Core.AccrualEconomicUnitTypeEnum.SubsidiaryCompany:\r\n identity += `Company: ${this.bulkUpdateCurrent.entry.companyName}`;\r\n break;\r\n case Core.AccrualEconomicUnitTypeEnum.SiteCode:\r\n identity += `Site Code: ${this.bulkUpdateCurrent.entry.siteCode}`;\r\n break;\r\n case Core.AccrualEconomicUnitTypeEnum.Parcel:\r\n identity += `Site Name: ${this.bulkUpdateCurrent.entry.siteName}`;\r\n identity += ` Parcel: ${this.bulkUpdateCurrent.entry.parcelAcctNum}`;\r\n break;\r\n case Core.AccrualEconomicUnitTypeEnum.Bill:\r\n identity += `Site Name: ${this.bulkUpdateCurrent.entry.siteName}`;\r\n identity += ` Parcel: ${this.bulkUpdateCurrent.entry.parcelAcctNum}`;\r\n identity += ` Collector: ${this.bulkUpdateCurrent.entry.collectorAbbr}`;\r\n break;\r\n }\r\n break;\r\n }\r\n }\r\n return identity;\r\n }\r\n\r\n async endBulkUpdate() {\r\n this.bulkUpdateCanceled = false;\r\n this.bulkUpdateInProgress = false;\r\n\r\n await this.refresh();\r\n this.refreshBulkUpdateState();\r\n }\r\n\r\n calculatePercentVarianceThreshold(val: number) {\r\n if(val) {\r\n this.searchModel.filters.percentVarianceThreshold = new Decimal(val).dividedBy(100).toNumber();\r\n this.showApplyButton = true;\r\n }\r\n }\r\n\r\n private async _initValues() {\r\n this.gridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true,\r\n suppressRowClickSelection: true,\r\n headerHeight: 45,\r\n groupHeaderHeight: 25,\r\n suppressMovableColumns: true,\r\n onGridColumnsChanged: () => {\r\n if(this.columnSizing == 'sizeColumnsToFit') {\r\n this.gridApi.sizeColumnsToFit();\r\n } else if (this.columnSizing == 'autosizeColumns') {\r\n this.columnApi.autoSizeAllColumns();\r\n }\r\n },\r\n onFilterChanged: () => {\r\n this._updateTotals();\r\n },\r\n onColumnResized: (e: ColumnResizedEvent) => {\r\n if(e.source != 'uiColumnDragged') {\r\n this.columnSizing = e.source;\r\n }\r\n },\r\n onSelectionChanged: () => {\r\n this._updateTotals();\r\n this.refreshBulkUpdateState();\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .withVerticalScrollBar()\r\n .withMultipleColumnSort()\r\n .withColumnPinning()\r\n .build();\r\n\r\n // this.gridOptions.defaultColDef.cellStyle = (cell) => cell.column.colId === cell.column.parent.displayedChildren[0].colId ? { 'border-left': '1px solid lightgray' } : null\r\n\r\n this.searchModel = {\r\n tlCompanyId: (await this._companyService.getTopCompanyForEntity(Core.EntityTypes.Company, this.parentCompanyId)).companyID,\r\n mode: Core.AccrualsGridViewModeEnum.SinglePeriod,\r\n filters: {\r\n startAccountingPeriodId: null,\r\n endAccountingPeriodId: null,\r\n companyIds: [],\r\n stateIds: [],\r\n propertyTypeIds: [],\r\n summarizeBy: Core.AccrualsGridSummarizeByEnum.Site,\r\n billRecurType: Core.AccrualsGridBillRecurTypeEnum.Both,\r\n enableChangeDetection: false\r\n },\r\n pagination: {}\r\n } as Core.AccrualsGridSearchModel;\r\n\r\n const instanceId = await lastValueFrom(this._instanceRepository.getEntityInstanceId('company', this.parentCompanyId));\r\n this.hasEditPermission = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, instanceId) &&\r\n await this._restrictService.hasCompanyPermission(this.parentCompanyId, Core.AccessRightsEnum.Write);\r\n\r\n this._websocketListenerService.longRunningProcessStatusChange$.pipe(takeUntil(this._destroy$)).subscribe(this.handleLRPStatusChange.bind(this));\r\n }\r\n\r\n private setOpenStatusByIndex(index: number): void {\r\n if (index === 0) {\r\n this.lastClosedAccountingPeriodId = null;\r\n this.firstOpenAccountingPeriodId = this.accountingPeriods[0].accountingPeriodId;\r\n }\r\n else if (index >= 0) {\r\n this.lastClosedAccountingPeriodId = this.accountingPeriods[index - 1].accountingPeriodId;\r\n this.firstOpenAccountingPeriodId = this.accountingPeriods[index].accountingPeriodId;\r\n }\r\n else if(this.accountingPeriods.length) {\r\n this.lastClosedAccountingPeriodId = this.accountingPeriods[this.accountingPeriods.length - 1].accountingPeriodId;\r\n this.firstOpenAccountingPeriodId = null;\r\n }\r\n }\r\n\r\n private async _getAccountingPeriods(): Promise {\r\n const accountingPeriodsModel = await this._accrualsPageService.getAccountingPeriods(this.searchModel.tlCompanyId);\r\n this.accountingPeriods = accountingPeriodsModel.accountingPeriods;\r\n\r\n this.setOpenStatusByIndex(this.accountingPeriods.findIndex(ap => !ap.isFrozen));\r\n\r\n this.startAccountingPeriod = this._getStartAccountingPeriod();\r\n if (this.startAccountingPeriod) {\r\n this.searchModel.filters.startAccountingPeriodId = this.startAccountingPeriod.accountingPeriodId;\r\n\r\n if (this.searchModel.mode === Core.AccrualsGridViewModeEnum.PeriodRange) {\r\n if(this._endAccountingPeriodId) {\r\n this.endAccountingPeriod = _.find(this.accountingPeriods, { accountingPeriodId: this._endAccountingPeriodId });\r\n } else {\r\n this._initSelectedAccountingPeriodEnd();\r\n }\r\n }\r\n else {\r\n this.searchModel.filters.endAccountingPeriodId = this.searchModel.filters.startAccountingPeriodId;\r\n }\r\n }\r\n }\r\n\r\n private _getStartAccountingPeriod(): Core.AccrualsGridAccountingPeriodModel {\r\n if (this._startAccountingPeriodId) {\r\n return _.find(this.accountingPeriods, { accountingPeriodId: this._startAccountingPeriodId });\r\n }\r\n else if (this.firstOpenAccountingPeriodId) {\r\n return _.find(this.accountingPeriods, { accountingPeriodId: this.firstOpenAccountingPeriodId });\r\n }\r\n else {\r\n return _.last(this.accountingPeriods);\r\n }\r\n }\r\n\r\n private _initSelectedAccountingPeriodEnd() {\r\n this.endAccountingPeriod = _.chain(this.accountingPeriods)\r\n .reject('isFrozen')\r\n .find(period => period.startDate > this.startAccountingPeriod.startDate)\r\n .value();\r\n\r\n if(!this.endAccountingPeriod) {\r\n this.endAccountingPeriod = _.last(this.accountingPeriods);\r\n this.startAccountingPeriod = this.accountingPeriods[this.accountingPeriods.length - 2];\r\n }\r\n\r\n if (this.endAccountingPeriod) {\r\n this.searchModel.filters.endAccountingPeriodId = this.endAccountingPeriod.accountingPeriodId;\r\n }\r\n }\r\n\r\n private _getRowEntityId(row: Core.AccrualsGridEntryModel): number {\r\n switch (this.searchModel.filters.summarizeBy) {\r\n case Core.AccrualsGridSummarizeByEnum.Bills:\r\n return row.billClusterId;\r\n case Core.AccrualsGridSummarizeByEnum.Company:\r\n return row.companyId;\r\n case Core.AccrualsGridSummarizeByEnum.EconomicUnit:\r\n switch (row.economicUnitTypeId) {\r\n case Core.AccrualEconomicUnitTypeEnum.SiteNumber:\r\n return row.siteId;\r\n case Core.AccrualEconomicUnitTypeEnum.SubsidiaryCompany:\r\n return row.companyId;\r\n case Core.AccrualEconomicUnitTypeEnum.SiteCode:\r\n return row.billClusterId;\r\n case Core.AccrualEconomicUnitTypeEnum.Parcel:\r\n return row.parcelId;\r\n case Core.AccrualEconomicUnitTypeEnum.Bill:\r\n return row.billClusterId;\r\n }\r\n case Core.AccrualsGridSummarizeByEnum.Parcel:\r\n return row.parcelId;\r\n case Core.AccrualsGridSummarizeByEnum.Site:\r\n return row.siteId;\r\n case Core.AccrualsGridSummarizeByEnum.State:\r\n return row.stateId;\r\n }\r\n }\r\n\r\n private async _getAvailableFilters(): Promise {\r\n this.availableFilters = await this._accrualsPageService.getAvailableFilters(this.parentCompanyId);\r\n this.availableFilters.companies = _.sortBy(this.availableFilters.companies, company => company.id == this.searchModel.tlCompanyId || company.name.toLowerCase());\r\n }\r\n\r\n private _setEntityFilters(): void {\r\n _.chain(this.availableFilters.companies)\r\n .filter(company => !this.searchModel.filters.companyIds.length || _.includes(this.searchModel.filters.companyIds, company.id))\r\n .forEach(company => {\r\n this.availableFilters.states = _.chain(this.availableFilters.states)\r\n .unionWith(company.states, _.isEqual)\r\n .sortBy('name')\r\n .value();\r\n\r\n this.availableFilters.propertyTypes = _.unionWith(this.availableFilters.propertyTypes, company.propertyTypes, _.isEqual);\r\n })\r\n .value();\r\n\r\n this.searchModel.filters.stateIds = _.intersectionBy(this.searchModel.filters.stateIds, _.map(this.availableFilters.states, 'id'));\r\n this.searchModel.filters.propertyTypeIds = _.intersectionBy(this.searchModel.filters.propertyTypeIds, _.map(this.availableFilters.propertyTypes, 'id'));\r\n }\r\n\r\n private _orderColumns(gridColumnGroups: ColGroupDef[]): void {\r\n let startingIdx: number = 0;\r\n\r\n _.forEach(gridColumnGroups, (group, i) => {\r\n if (gridColumnGroups[i - 1]) {\r\n startingIdx += gridColumnGroups[i - 1].children.length;\r\n }\r\n\r\n const colIds: string[] = _.map(group.children, 'colId');\r\n this.columnApi.moveColumns(colIds, startingIdx);\r\n });\r\n }\r\n\r\n private async _startGettingGridData(): Promise {\r\n this._startLoadingGrid();\r\n\r\n this.gettingGrid = true;\r\n this.exportOptions.disabled = true;\r\n this.refreshBulkUpdateState();\r\n this._showGridSpinner();\r\n try {\r\n const lrp = await this._accrualsPageService.startAccrualsGridGet(this.searchModel.tlCompanyId, this.searchModel);\r\n this.activeLongRunningProcessId = lrp.longRunningProcessId;\r\n this._snackBarService.addById(lrp.longRunningProcessId, Compliance.LongRunningProcessTypeEnum.AccrualsGridGet);\r\n } catch (e) {\r\n if(e.error) {\r\n this._toastrService.error(e.error.message);\r\n }\r\n this.gettingGrid = false;\r\n this.activeLongRunningProcessId = 0;\r\n this.exportOptions.disabled = false;\r\n this.refreshBulkUpdateState();\r\n this._stopLoadingGrid();\r\n }\r\n }\r\n\r\n private async loadGridResults(longRunningProcessId: number): Promise {\r\n this._startLoadingGrid();\r\n\r\n try {\r\n this.resultsModel = await this._accrualsPageService.getAccrualsGridResults(this.searchModel.tlCompanyId, longRunningProcessId);\r\n this.gridApi.setRowData(this.resultsModel.entries);\r\n\r\n this._completeGridDisplay();\r\n } finally {\r\n this._stopLoadingGrid();\r\n }\r\n }\r\n\r\n private _completeGridDisplay(): void {\r\n this._updateTotals();\r\n\r\n this.setColumns();\r\n\r\n this.showApplyButton = false;\r\n\r\n if(this.reselectGridNodes) {\r\n this.gridApi.forEachNode(node => {\r\n if (_.includes(this.selectedIds, this._getRowEntityId(node.data))) {\r\n node.setSelected(true);\r\n }\r\n });\r\n\r\n this.reselectGridNodes = false;\r\n }\r\n }\r\n\r\n //async loadData(): Promise {\r\n // this._startLoadingGrid();\r\n\r\n // try {\r\n // this.resultsModel = await this._accrualsPageService.getAccrualsGridData(this.searchModel.tlCompanyId, this.searchModel);\r\n // this.gridApi.setRowData(this.resultsModel.entries);\r\n\r\n // this._updateTotals();\r\n // } finally {\r\n // this._stopLoadingGrid();\r\n // }\r\n //}\r\n\r\n private _startLoadingGrid(): void {\r\n this.loading = true;\r\n this._showGridSpinner();\r\n }\r\n\r\n private _stopLoadingGrid(): void {\r\n this.loading = false;\r\n this._hideGridSpinner();\r\n }\r\n\r\n private _showGridSpinner(): void {\r\n if ( this.gridApi ) {\r\n this.gridApi.showLoadingOverlay();\r\n }\r\n }\r\n\r\n private _hideGridSpinner(): void {\r\n if ( this.gridApi ) {\r\n this.gridApi.hideOverlay();\r\n }\r\n }\r\n\r\n private _updateTotals(): void {\r\n const totalRows = [];\r\n let isAtLeastOneRow: boolean = false;\r\n let areSelectedRows: boolean = false;\r\n\r\n const totalRow: Core.AccrualsGridEntryModel = {\r\n stateName: 'TOTAL',\r\n openTaxObligations: {},\r\n periodContributions: {},\r\n accrualBalances: {},\r\n journalImpacts: [],\r\n journalBalances: [],\r\n journalImpactsByType: [],\r\n journalBalancesByType: []\r\n } as Core.AccrualsGridEntryModel;\r\n const selectedRow: Core.AccrualsGridEntryModel = {\r\n stateName: 'SELECTED',\r\n openTaxObligations: {},\r\n periodContributions: {},\r\n accrualBalances: {},\r\n journalImpacts: [],\r\n journalBalances: [],\r\n journalImpactsByType: [],\r\n journalBalancesByType: []\r\n } as Core.AccrualsGridEntryModel;\r\n\r\n this.gridApi.forEachNodeAfterFilter((rowNode: RowNode) => {\r\n isAtLeastOneRow = true;\r\n const entry = rowNode.data as Core.AccrualsGridEntryModel;\r\n\r\n if(rowNode.isSelected()) {\r\n areSelectedRows = true;\r\n this._compileNestedTotals(entry, selectedRow);\r\n }\r\n\r\n this._compileNestedTotals(entry, totalRow);\r\n });\r\n\r\n if (isAtLeastOneRow) {\r\n totalRows.push(totalRow);\r\n }\r\n if (areSelectedRows) {\r\n totalRows.push(selectedRow);\r\n }\r\n\r\n this.gridApi.setPinnedBottomRowData(totalRows);\r\n }\r\n\r\n private _compileNestedTotals(entry: Core.AccrualsGridEntryModel, totalRow: Core.AccrualsGridEntryModel) {\r\n _.forEach(this._accrualsPageService.rowFields, (block: any) => {\r\n _.forEach(block.fields, field => {\r\n const entryValue = entry[block.category][field];\r\n\r\n if (entryValue == undefined || entryValue == null) {\r\n return;\r\n }\r\n\r\n if (!totalRow[block.category][field]) {\r\n totalRow[block.category][field] = 0;\r\n }\r\n\r\n totalRow[block.category][field] = new Decimal(totalRow[block.category][field]).add(entryValue).toNumber();\r\n });\r\n });\r\n\r\n _.forEach(this.resultsModel.glAccountsByType, (account, i) => {\r\n if (!totalRow.journalBalancesByType[i]) {\r\n totalRow.journalBalancesByType[i] = { amount: 0 };\r\n }\r\n\r\n if (!totalRow.journalImpactsByType[i]) {\r\n totalRow.journalImpactsByType[i] = { amount: 0 };\r\n }\r\n\r\n if (entry.journalBalancesByType[i] && entry.journalBalancesByType[i].amount != null && entry.journalBalancesByType[i].amount != undefined) {\r\n totalRow.journalBalancesByType[i].amount = new Decimal(totalRow.journalBalancesByType[i].amount).add(entry.journalBalancesByType[i].amount).toNumber();\r\n }\r\n\r\n if (entry.journalImpactsByType[i] && entry.journalImpactsByType[i].amount != null && entry.journalImpactsByType[i].amount != undefined) {\r\n totalRow.journalImpactsByType[i].amount = new Decimal(totalRow.journalImpactsByType[i].amount).add(entry.journalImpactsByType[i].amount).toNumber();\r\n }\r\n });\r\n\r\n _.forEach(this.resultsModel.glAccounts, (account, i) => {\r\n if (!totalRow.journalBalances[i]) {\r\n totalRow.journalBalances[i] = { amount: 0 };\r\n }\r\n\r\n if (!totalRow.journalImpacts[i]) {\r\n totalRow.journalImpacts[i] = { amount: 0 };\r\n }\r\n\r\n if (entry.journalBalances[i] && entry.journalBalances[i].amount != null && entry.journalBalances[i].amount != undefined) {\r\n totalRow.journalBalances[i].amount = new Decimal(totalRow.journalBalances[i].amount).add(entry.journalBalances[i].amount).toNumber();\r\n }\r\n\r\n if (entry.journalImpacts[i] && entry.journalImpacts[i].amount != null && entry.journalImpacts[i].amount != undefined) {\r\n totalRow.journalImpacts[i].amount = new Decimal(totalRow.journalImpacts[i].amount).add(entry.journalImpacts[i].amount).toNumber();\r\n }\r\n });\r\n }\r\n\r\n private async _gatherBulkUpdateSelections(): Promise {\r\n\r\n // this.bulkUpdateEntityType = (this.filters.siteRollup ? \"Site\" : \"Parcel\");\r\n\r\n const selections: Core.AccrualsGridEntryModel[] = this.gridApi.getSelectedRows();\r\n\r\n // If Selected count is less than threshold for \"an awful lot\", just proceed.\r\n if (selections.length < this.LARGE_BULK_UPDATE_THRESHOLD) {\r\n return selections;\r\n }\r\n\r\n // Confirm with the user to Builk Update that many Tax Authorities.\r\n const answer: number = await this._messageBoxService.open({\r\n message: `Are you sure you want to Bulk Update ${selections.length} entries?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (answer === MessageBoxResult.OK) {\r\n return selections;\r\n }\r\n\r\n // Canceled Bulk Update, return no selections.\r\n console.log('Bulk Update confirmation canceled');\r\n return [];\r\n }\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class BalanceAdjustmentsService {\r\n constructor(private readonly _http: HttpClient) {}\r\n\r\n private readonly _baseUrl = 'api/parcel';\r\n\r\n getSelectionData(parcelId: number): Promise {\r\n return lastValueFrom(this._http.get(`${this._baseUrl}/${parcelId}/Accrual/BalanceAdjustmentSelectionData`)) as Promise;\r\n }\r\n\r\n getAdjustments(parcelId: number): Promise {\r\n return lastValueFrom(this._http.get(`${this._baseUrl}/${parcelId}/Accrual/BalanceAdjustments`)) as Promise;\r\n }\r\n\r\n updateAdjustment(parcelId: number, adjustment: Core.AccrualBalanceAdjustmentModel): Promise {\r\n return lastValueFrom(this._http.put(`${this._baseUrl}/${parcelId}/Accrual/BalanceAdjustment`, adjustment)) as Promise;\r\n }\r\n\r\n deleteAdjustment(parcelId: number, accrualBalanceAdjustmentId: number): Promise {\r\n return lastValueFrom(this._http.delete(`${this._baseUrl}/${parcelId}/Accrual/BalanceAdjustment/${accrualBalanceAdjustmentId}`)) as Promise;\r\n }\r\n\r\n getBalances(parcelId: number): Promise {\r\n return lastValueFrom(this._http.get(`${this._baseUrl}/${parcelId}/Accrual/Balances`)) as Promise;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { AccrualsBulkUpdateModalComponent } from './accruals.bulk.update.modal.component';\r\nimport { AccrualsPageComponent } from './accruals.page.component';\r\nimport { AccrualsAdjustmentsListComponent } from './Balance-Adjustments/accrualsAdjustmentsList.component';\r\nimport { AccrualsBalancesListComponent } from './Balance-Adjustments/accrualsBalancesList.component';\r\nimport {\r\n AccrualsAdjustmentsGridActionCellRendererComponent\r\n} from './Balance-Adjustments/agGridActionCellRendererComponent';\r\nimport { BalanceAdjustmentsService } from './Balance-Adjustments/balanceAdjustments.service';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule\r\n ],\r\n declarations: [\r\n AccrualsPageComponent,\r\n AccrualsBulkUpdateModalComponent,\r\n AccrualsAdjustmentsListComponent,\r\n AccrualsBalancesListComponent,\r\n AccrualsAdjustmentsListComponent,\r\n AccrualsAdjustmentsGridActionCellRendererComponent\r\n ],\r\n providers: [BalanceAdjustmentsService],\r\n exports: [\r\n AccrualsPageComponent,\r\n AccrualsAdjustmentsListComponent,\r\n AccrualsBalancesListComponent\r\n ]\r\n})\r\nexport class AccrualsModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('accrualsPage', AccrualsPageComponent);\r\n }\r\n}\r\n","export interface IAddress extends Core.AddressModel {\r\n abbr?: string;\r\n}\r\n\r\nexport class Address implements IAddress {\r\n address1: string;\r\n address2: string;\r\n addressID: number;\r\n city: string;\r\n email: string;\r\n ext: string;\r\n fax: string;\r\n mobilePhone: string;\r\n phone: string;\r\n rowVersion: number[];\r\n state: Core.StateModel;\r\n stateID: number;\r\n url: string;\r\n zip: string;\r\n abbr?: string;\r\n}\r\n\r\nexport class UserTeamMember {\r\n firstName: string;\r\n lastName: string;\r\n userID: string;\r\n teamID: number;\r\n teamName: string;\r\n}\r\n","import { Address } from '../Common/Models/common.model';\r\n\r\nexport class Agent {\r\n constructor() {\r\n this.address = new Address();\r\n }\r\n\r\n agentID: number;\r\n name: string;\r\n company: string;\r\n addressID: number;\r\n address: Address;\r\n hover: boolean;\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\nimport { Agent } from './agents.model';\r\n\r\nconst url = '/api/agent/';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class AgentService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n getAgents(): Promise {\r\n return this.http.get(url) ;\r\n }\r\n\r\n getAgentById(id: number): Promise {\r\n return this.http.get(url + id);\r\n }\r\n\r\n createAgent(agent: Agent): Promise {\r\n return this.http.post(url, agent);\r\n }\r\n\r\n updateAgent(agent: Agent): Promise {\r\n return this.http.put(url, agent);\r\n }\r\n\r\n deleteAgent(id: number): Promise {\r\n return this.http.delete(url + id);\r\n }\r\n}\r\n","
\r\n
\r\n

Agents

\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
NameCompanyAddress
\r\n {{agent.name}}\r\n \r\n \r\n {{agent.company}}\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Renderer2 } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { Agent } from './agents.model';\r\nimport { AgentService } from './agents.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { MessageBoxService, MessageBoxButtons, MessageBoxResult } from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { RestrictService, InstanceRights } from '../Common/Permissions/restrict.service';\r\nimport { TimerService } from '../UI-Lib/Utilities/timer.service';\r\n\r\nconst emailRegex = /^(([^<>()\\[\\]\\\\.,;:\\s@\"]+(\\.[^<>()\\[\\]\\\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$/;\r\n\r\n@Component({\r\n selector: 'agents-page',\r\n templateUrl: './agents.page.component.html',\r\n styleUrls: ['./agents.page.component.scss']\r\n})\r\nexport class AgentsPageComponent implements OnInit {\r\n constructor(\r\n private readonly _renderer2: Renderer2,\r\n private readonly _agentService: AgentService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _timer: TimerService\r\n ) {\r\n this.hasEditPermission = _restrictService.hasInstanceRight(InstanceRights.AGENTINFORMATIONEDIT);\r\n }\r\n\r\n agents: Agent[];\r\n agentInEdit: Agent;\r\n hasEditPermission: boolean = false;\r\n\r\n ngOnInit() {\r\n this._getAgents();\r\n }\r\n\r\n goToEditMode(agent: Agent): void {\r\n this.agentInEdit = _.cloneDeep(agent);\r\n }\r\n\r\n isEditMode(agent: Agent): boolean {\r\n return this.agentInEdit && this.agentInEdit.agentID == agent.agentID;\r\n }\r\n\r\n addNew(): void {\r\n this.agents.push(new Agent());\r\n this.agentInEdit = new Agent();\r\n\r\n this._timer.setTimeout(() => {\r\n this._selectNameField();\r\n });\r\n }\r\n\r\n cancelEdit(): void {\r\n this.agentInEdit = undefined;\r\n this.agents = _.filter(this.agents, 'agentID');\r\n }\r\n\r\n async saveAgent(): Promise {\r\n if(this.agentInEdit.address.email && !emailRegex.test(this.agentInEdit.address.email.toLowerCase())) {\r\n this._toastr.error('Email Invalid!');\r\n\r\n return;\r\n }\r\n\r\n if(this.agentInEdit.agentID) {\r\n const savedAgent: Agent = await this._agentService.updateAgent(this.agentInEdit);\r\n const i: number = _.findIndex(this.agents, {agentID: this.agentInEdit.agentID});\r\n\r\n this.agents[i] = savedAgent;\r\n } else {\r\n const newAgent: Agent = await this._agentService.createAgent(this.agentInEdit);\r\n\r\n this.agents.push(newAgent);\r\n }\r\n\r\n this.cancelEdit();\r\n }\r\n\r\n async confirmDeleteAgent(agent: Agent): Promise {\r\n const result: number = await this._messageBoxService.open({\r\n message: `Are you sure you want to delete ${agent.name}?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (result === MessageBoxResult.OK) {\r\n this._agentService.deleteAgent(agent.agentID).then(() => {\r\n _.remove(this.agents, agent);\r\n });\r\n\r\n\r\n }\r\n }\r\n\r\n private _selectNameField(): void {\r\n const onElement = this._renderer2.selectRootElement('#agentName');\r\n onElement.focus();\r\n }\r\n\r\n private async _getAgents(): Promise {\r\n this.agents = await this._agentService.getAgents();\r\n }\r\n\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { AgentsPageComponent } from './agents.page.component';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\n\r\n@NgModule({\r\n imports: [ WeissmanSharedModule ],\r\n declarations: [ AgentsPageComponent ],\r\n exports: [ AgentsPageComponent ]\r\n})\r\nexport class AgentsModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('agentsPage', AgentsPageComponent);\r\n }\r\n}\r\n","import { Address } from '../../Common/Models/common.model';\r\nimport { Attachment, AttachmentInfo } from '../../Attachment/attachment.model';\r\n\r\nexport enum TransmittalOutputType {\r\n PaperTransmittal = 1,\r\n DigitalTransmittal = 2,\r\n APFeed = 3,\r\n BillPay = 4\r\n}\r\n\r\nexport class TransmittalOutputTypeButtonLabel{\r\n public static PaperTransmittal: string = 'Print Package';\r\n public static DigitalTransmittal: string = 'Email Package';\r\n public static APFeed: string = 'Send AP Feed';\r\n public static BillPay: string = 'Pay Bills';\r\n}\r\n\r\nexport enum TransmittalFormat {\r\n Original_Default = 1,\r\n FMV_AV_Legal = 2,\r\n FMV_AV_TV_RV_Legal = 3,\r\n FiscalYear = 4,\r\n DirectAsmtSummary = 5\r\n}\r\n\r\nexport enum TransmittalGroupBy {\r\n Subsidiary_Site = 1,\r\n Collector_Site = 2,\r\n Subsidiary = 3,\r\n Collector = 4\r\n}\r\n\r\nexport enum RecipientType {\r\n ResponsibleParty = Weissman.Model.RecipientType.ResponsibleParty,\r\n Cc = Weissman.Model.RecipientType.Cc,\r\n Bcc = Weissman.Model.RecipientType.Bcc\r\n}\r\n\r\nexport enum AttachmentType{\r\n PaymentPackage = 1,\r\n PaymentTransmittal = 2,\r\n APFeed = 3\r\n}\r\n\r\nexport class PaymentPackage {\r\n paymentPackageID: number;\r\n companyID: number;\r\n companyName: string;\r\n transmittalOutputType: TransmittalOutputType;\r\n transmittalType: string;\r\n specialInstructions: string;\r\n packageNumber: string;\r\n completedDateTime: Date;\r\n completedByUserID: string;\r\n isRecalled: boolean;\r\n paymentPackageRecipients: PaymentPackageRecipient[];\r\n paymentTransmittals: PaymentTransmittal[];\r\n paymentPackageFeedSpecifications: PaymentPackageFeedSpecification[];\r\n isSelected: boolean;\r\n packageType: Core.PaymentPackageTypes;\r\n emailSubjectTemplate: string;\r\n emailSubject: string;\r\n emailTemplate: string;\r\n emailText: string;\r\n apFeedAttachments: Attachment[];\r\n consolidateTransmittalAttachment: boolean;\r\n skipBillImage: boolean;\r\n attachments: Attachment[];\r\n isFinalized: boolean;\r\n paymentBatchId: number;\r\n paymentPackageFinalizeRequestId: number;\r\n // Does not come from server; use this for ability to restore an original email template\r\n lockedForOverrideEmail: boolean;\r\n originalEmailSubjectTemplate: string;\r\n originalEmailTextTemplate: string;\r\n\r\n}\r\n\r\nexport class PaymentPackageRecipient {\r\n constructor(newRecipientType: RecipientType,\r\n newContactID: number,\r\n newFullName: string,\r\n newTitle: string,\r\n newAddress: Address,\r\n newEmail: string,\r\n newCompanyName: string) {\r\n this.recipientType = newRecipientType;\r\n this.contactID = newContactID;\r\n this.fullName = newFullName;\r\n this.title = newTitle;\r\n this.address = newAddress;\r\n this.email = newEmail;\r\n this.companyName = newCompanyName;\r\n }\r\n\r\n paymentPackageRecipientID: number;\r\n paymentPackageID: number;\r\n recipientType: RecipientType;\r\n contactID: number;\r\n fullName: string;\r\n title: string;\r\n address: Address;\r\n email: string;\r\n companyName: string;\r\n}\r\n\r\nexport class PaymentTransmittal {\r\n paymentTransmittalID: number;\r\n paymentPackageID: number;\r\n collectorID: number;\r\n collectorName: string;\r\n siteID: number;\r\n title: string;\r\n collectorAddress: Address;\r\n dueDate: Date;\r\n note: string;\r\n transmittalFormat: TransmittalFormat;\r\n paymentTransmittalItems: PaymentTransmittalItem[];\r\n}\r\n\r\nexport class PaymentTransmittalItem {\r\n paymentTransmittalItemID: number;\r\n paymentTransmittalID: number;\r\n paymentID: number;\r\n attachmentID: number;\r\n attachment: Attachment;\r\n siteName: string;\r\n acctNum: string;\r\n collectorAcctNum: string;\r\n propertyType: number;\r\n amount: number;\r\n intakeItemID: number;\r\n intakeBatchNumber: number;\r\n intakeItemNumber: number;\r\n}\r\n\r\nexport class TransmittalOutputTypeOption {\r\n constructor(type: TransmittalOutputType, textLabel: string){\r\n this.outputType = type;\r\n this.label = textLabel;\r\n }\r\n\r\n outputType: TransmittalOutputType;\r\n label: string;\r\n}\r\n\r\nexport class PaymentPackageFeedSpecification {\r\n PaymentPackageFeedSpecificationID: number;\r\n PaymentPackageID: number;\r\n FeedSpecificationID: number;\r\n IncludedInEmail: boolean;\r\n}\r\n\r\nexport class InvoiceAttachmentInfo {\r\n fileName: string;\r\n fileExtension: string;\r\n // We'll either have an attachment or enough data to generate a preview\r\n Attachment?: Attachment;\r\n id?: string;\r\n attachmentType: AttachmentType;\r\n}\r\n\r\nexport class InvoicePreviewData {\r\n emailTextTemplate: string;\r\n emailText: string;\r\n emailSubjectTemplate: string;\r\n emailSubject: string;\r\n attachments: InvoiceAttachmentInfo[];\r\n}\r\n\r\nexport class PackageEmailTemplate {\r\n bodyTemplate: string;\r\n name: string;\r\n packageEmailTemplateID: number;\r\n subjectTemplate: string;\r\n}\r\n\r\nexport class PaymentPackageAttachmentSummary {\r\n paymentPackageID: number;\r\n packageName: string;\r\n companyID: number;\r\n attachments: AttachmentInfo[];\r\n}\r\n","// import { Injectable } from '@angular/core';\r\n// import { WeissmanModalService } from '../Compliance/WeissmanModalService';\r\n// import { ContactsUpgradeService } from './contacts.service.upgrade';\r\n// import { ContactRoleService } from '../Role/contact.role.service';\r\n// import { BsModalService } from 'ngx-bootstrap/modal';\r\n\r\n// todo reimplement this as a service once the user modal update is implemented\r\n\r\n// Needed to be its own service to prevent circular dependency\r\n// @Injectable()\r\n// export class ContactModalService {\r\n// constructor(\r\n// private readonly _weissmanModalService: WeissmanModalService,\r\n// private readonly _contactsService: ContactsUpgradeService,\r\n// private readonly _roleService: ContactRoleService,\r\n// private readonly _modalService: BsModalService\r\n// ) {}\r\n//\r\n// async openContactDialog(contactId: number, origin, entityInfo?, roles?) {\r\n// // problem: this dialog can be called from contact entity panel.\r\n// // (contact list has real contacts) or from contacts view (we have list of contactDto objects)\r\n// // ToDo: Re-factor contact detail dialog to better handle problem described above.\r\n// const params = {\r\n// contactId,\r\n// entityInfo: entityInfo || null,\r\n// roles: roles || null,\r\n// origin\r\n// }\r\n//\r\n// // const contact = await this._weissmanModalService.showAsync(ContactViewModalComponent, params, 'modal-lg');\r\n//\r\n// if (contact) {\r\n// const i = this._contactsService.contacts.findIndex(x => x.contactID === contact.contactID);\r\n//\r\n// if (i < 0) {\r\n// // this was a new contact, lets insert it\r\n// this._contactsService.contacts.push(contact);\r\n// }\r\n// else {\r\n// // updating existing one\r\n//\r\n// // todo: what is going on here ???\r\n//\r\n// // array element might have 2 custom properties used by Contacts page (if loaded in dialog mode)\r\n// // transferring these properties\r\n// //\r\n// contact.isVisible = this._contactsService.contacts[i].isVisible;\r\n// if (this._contactsService.contacts[i].availableRoles)\r\n// contact.availableRoles = this._contactsService.contacts[i].availableRoles;\r\n// else\r\n// {\r\n// // this is actually a new contact, but it has been inserted already\r\n// // todo - refactor this mess\r\n// //\r\n// contact.availableRoles = await this._roleService.getAvailableRolesForContactEntityCombinationAPI(contact.contactID, entityInfo);\r\n// this._copyContactProperties(contact, this._contactsService.contacts[i]);\r\n// }\r\n// this._copyContactProperties(contact, this._contactsService.contacts[i]);\r\n// }\r\n// }\r\n//\r\n// return contact;\r\n// }\r\n//\r\n// private _copyContactProperties(c, r) {\r\n// // we'll have a mix between real contact and Dto\r\n// r.contactID = c.contactID;\r\n// r.entityID = c.entityID;\r\n// r.entityName = c.entityName;\r\n// r.firstName = c.firstName;\r\n// r.lastName = c.lastName;\r\n// r.title = c.title;\r\n// r.address = c.address;\r\n// if (c.address) {\r\n// r.phone = c.address.phone;\r\n// r.ext = c.address.ext;\r\n// r.mobilePhone = c.address.mobilePhone;\r\n// }\r\n// }\r\n// }\r\n\r\nexport abstract class ContactModalService {\r\n abstract openContactDialog(contactId: number, origin, contacts?, entityInfo?, roles?, onTop?: boolean): Promise;\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\nimport { EntityTypeIds } from '../constants.new';\r\n\r\nconst url = '/api/role/';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class ContactRoleService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n private _roles: Weissman.Model.Contacts.ContactRole[];\r\n\r\n async get(): Promise {\r\n const result = await this.http.get(url);\r\n this._roles = result;\r\n return result;\r\n }\r\n\r\n update(role: Weissman.Model.Contacts.ContactRole): Promise {\r\n return this.http.put(url, role);\r\n }\r\n\r\n async create(role: Weissman.Model.Contacts.ContactRole): Promise {\r\n const result = await this.http.post(url, role);\r\n this._roles.push(result);\r\n\r\n return result;\r\n }\r\n\r\n delete(id: number): Promise {\r\n return this.http.delete(`${url}${id}`);\r\n }\r\n\r\n getAvailableRolesForContactEntityCombinationAPI(contactID: number, entityInfo): Promise {\r\n const entityTypeID = EntityTypeIds[entityInfo.type.toUpperCase()];\r\n\r\n return this.http.get(url, {\r\n params: {\r\n contactID,\r\n entityTypeID,\r\n entityId: entityInfo.id\r\n }\r\n });\r\n }\r\n\r\n getCached(): Weissman.Model.Contacts.ContactRole[] {\r\n return this._roles;\r\n }\r\n}\r\n","\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n\t\t\t\t\t\t\r\n
\r\n
\r\n {{filterValidationError}}\r\n
\r\n
\r\n
\r\n {{filterValidationError}}\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
0\" class=\"row contacts-infinite-scroll\" style=\"margin: 30px; margin-bottom: 0; width: 95%; max-height: 369px; overflow-y:scroll;\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
NameTitlePhoneCompany
\r\n \r\n \r\n \r\n {{ contact.lastName }}, {{ contact.firstName }}\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n {{ contact.title }}\r\n \r\n {{getAnyContactPhone(contact)}}\r\n \r\n \r\n {{ contact.entityName }}\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n

No Matching Contacts Found

\r\n
\r\n
\r\n Exclude Inactive\r\n
\r\n
\r\n
\r\n
\r\n","import { Component } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { ContactsUpgradeService } from '../../../contacts.service.upgrade';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UserInstanceService } from '../../../../User/userInstance.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { ContactRoleService } from '../../../../Role/contact.role.service';\r\nimport { ContactModalOrigin } from '../../../../constants.new';\r\nimport { ContactModalService } from '../../../contactModal.service';\r\n\r\nexport interface ContactListModalParams {\r\n recipientMode?: boolean;\r\n entityInfo?: any;\r\n notAllowedRoles?: any[];\r\n}\r\n\r\n@Component({\r\n selector: 'entity-contact-list-modal',\r\n templateUrl: './contactListModal.component.html'\r\n})\r\nexport class ContactListModalComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _contactService: ContactsUpgradeService,\r\n private readonly _contactModalService: ContactModalService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _navigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _roleService: ContactRoleService\r\n ) {}\r\n\r\n params: any;\r\n result: any;\r\n\r\n lastSearch: string = '';\r\n gettingDataForTheFirstTime: boolean = true;\r\n gettingMoreData: boolean;\r\n roles: any[] = [];\r\n notAllowedRoles: any[] = []; //Dima: list of roles, which needs to be removed from the drop down list.E.g. for entity contacts, we can select only one Tax Bill Recipient\r\n\r\n entityInfo;\r\n recipientTypes;\r\n recipientMode;\r\n contacts: any[] = [];\r\n selectedContact;\r\n pageNumber: number = 0;\r\n pageSize: number = 50;\r\n filter: string = '';\r\n filterValidationError: string = '';\r\n oldFilter: string = '';\r\n header: string = 'Contacts';\r\n dialogMode: boolean;\r\n noMoreData: boolean;\r\n gettingContactRoles: boolean;\r\n excludeInactive: boolean;\r\n\r\n ngOnInit(): void {\r\n this.dialogMode = !!this.params;\r\n this.notAllowedRoles = []; //Dima: list of roles, which needs to be removed from the drop down list.E.g. for entity contacts, we can select only one Tax Bill Recipient\r\n\r\n if (this.dialogMode) {\r\n this.recipientMode = this.params.recipientMode;\r\n } else {\r\n this.recipientMode = false;\r\n }\r\n\r\n this.excludeInactive = !this._userInstanceService.isCurrentInstanceSystem();\r\n\r\n if (this.dialogMode) {\r\n this.entityInfo = this.params.entityInfo;\r\n if (!this.recipientMode) {\r\n this.selectedContact = null;\r\n this.notAllowedRoles = this.params.notAllowedRoles;\r\n this.header = 'Associate Contact to '; // TODO this service call always provides nothing + this._utilsService.getEntityName(this.entityInfo.id);\r\n }\r\n }\r\n\r\n this.recipientTypes = {\r\n ResponsibleParty: 1,\r\n Cc: 2,\r\n Bcc: 3\r\n };\r\n\r\n this._loadContacts();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n validateFilter(): void {\r\n if (this.filter.length > 100) {\r\n this.filterValidationError = 'Filter length should be 100 characters or less';\r\n return;\r\n }\r\n this.filterValidationError = '';\r\n }\r\n\r\n async searchContactsOnServer(searchText: string, excludeInactiveChanged: boolean = false): Promise {\r\n if (!searchText) {\r\n searchText = '';\r\n }\r\n\r\n this.validateFilter();\r\n\r\n if (this.filterValidationError !== '') {\r\n return;\r\n }\r\n\r\n this.filter = searchText;\r\n\r\n if (searchText !== this.oldFilter || excludeInactiveChanged) {\r\n this.oldFilter = searchText;\r\n this.pageNumber = 1;\r\n this.noMoreData = false;\r\n this.contacts = [];\r\n } else {\r\n this.pageNumber++;\r\n }\r\n\r\n if (this.noMoreData) {\r\n return;\r\n }\r\n\r\n if (this.contacts.length === 0) {\r\n this.gettingDataForTheFirstTime = true;\r\n } else {\r\n this.gettingMoreData = true;\r\n }\r\n\r\n let result;\r\n\r\n try {\r\n if(this.dialogMode) {\r\n if(this.entityInfo.type === 'assessor' || this.entityInfo.type === 'state' || this.entityInfo.type === 'collector') {\r\n result = await this._contactService.searchRyan(searchText, this.pageNumber, this.pageSize, this.excludeInactive);\r\n } else {\r\n result = await this._contactService.searchScoped(this.entityInfo.id, this.entityInfo.type, searchText, this.pageNumber, this.pageSize, this.excludeInactive);\r\n }\r\n } else {\r\n result = await this._contactService.search(this._userInstanceService.getSelectedInstance().instanceId, searchText, this.pageNumber, this.pageSize, this.excludeInactive);\r\n }\r\n\r\n if (!result.length || result.length === 0) {\r\n this.noMoreData = true;\r\n } else {\r\n this.contacts = this.contacts.concat(result);\r\n // Sort by last name, then first name\r\n this.contacts.sort((a, b) => {\r\n const compare = a.lastName.localeCompare(b.lastName);\r\n return compare !== 0 ? compare : a.firstName.localeCompare(b.firstName);\r\n });\r\n }\r\n\r\n if (result.length < this.pageSize) {\r\n this.noMoreData = true;\r\n }\r\n } finally {\r\n this.gettingDataForTheFirstTime = false;\r\n this.gettingMoreData = false;\r\n this.lastSearch = searchText;\r\n }\r\n }\r\n\r\n async clearFilter(): Promise {\r\n this.filter = '';\r\n\r\n if (this.lastSearch) {\r\n await this.searchContactsOnServer('');\r\n }\r\n }\r\n\r\n openCompanyPage(companyId: number): void {\r\n this._navigationServiceHandler.go('company', {\r\n companyId: companyId\r\n });\r\n\r\n if (this.dialogMode) {\r\n this.cancel();\r\n }\r\n }\r\n\r\n async openContactDialog(contactId: number, allContacts): Promise {\r\n const contact = await this._contactModalService.openContactDialog(contactId, ContactModalOrigin.ContactsList, null, this.entityInfo, null, true);\r\n //const editedContact = _.find(allContacts, {\r\n //\tcontactID: contactId\r\n //});\r\n\r\n //const index = allContacts.indexOf(editedContact);\r\n //allContacts[index] = editedContact;\r\n\r\n //const index = _.findIndex(this.active.letter.list, {\r\n //\tcontactID: contactId\r\n //});\r\n\r\n //this.active.letter.list[index] = editedContact;\r\n\r\n if(!contact) {\r\n await this.clearFilter();\r\n }\r\n }\r\n\r\n getAnyContactPhone(contact): string {\r\n if (!contact) {\r\n return '';\r\n }\r\n\r\n if (contact.phone) {\r\n if (contact.ext) {\r\n return `${contact.phone } x${ contact.ext}`;\r\n }\r\n else {\r\n return contact.phone;\r\n }\r\n }\r\n\r\n if (contact.mobilePhone) {\r\n return contact.mobilePhone;\r\n }\r\n\r\n return '';\r\n }\r\n\r\n associateRole(contact): void {\r\n this.result = {\r\n contact: contact,\r\n selectedRole: contact.selectedRole\r\n };\r\n this.cancel();\r\n }\r\n\r\n closeDialog(): void {\r\n this.result = this.contacts.filter(x => x.selected);\r\n this.cancel();\r\n }\r\n\r\n closeRecipientDialog(recipientType) {\r\n const selectedContacts = this.contacts.filter(x => x.selected);\r\n this.result = {\r\n recipients: selectedContacts,\r\n recipientType: recipientType\r\n };\r\n this.cancel();\r\n }\r\n\r\n async selectContact(contactDto): Promise {\r\n if (this.recipientMode) { return; }\r\n\r\n // deselect other contacts\r\n //\r\n this.contacts.forEach(x => {\r\n if (x.contactID !== contactDto.contactID) {\r\n x.selected = false;\r\n }\r\n });\r\n\r\n // did we get all available roles for this contact already?\r\n if (contactDto.availableRoles) {\r\n return;\r\n }\r\n\r\n this.gettingContactRoles = true;\r\n //contactDto.selected = false;\t// to keep it from expanding before we got available roles\r\n\r\n const someRoles = await this._roleService.getAvailableRolesForContactEntityCombinationAPI(contactDto.contactID, this.entityInfo);\r\n\r\n contactDto.availableRoles = someRoles.filter(x => this.notAllowedRoles.indexOf(x.contactRoleID) === -1);\r\n this.gettingContactRoles = false;\r\n }\r\n\r\n async checkForEnterKey(keyEvent): Promise {\r\n if (keyEvent.which === 13) {\r\n await this.searchContactsOnServer(this.filter);\r\n }\r\n }\r\n\r\n cancelContactAssignRole(contact): void {\r\n contact.selectedRole = null;\r\n contact.selected = false;\r\n }\r\n\r\n contactsTrackBy(i: number, contact): number {\r\n return contact.contactID;\r\n }\r\n\r\n private async _loadContacts(): Promise {\r\n if (this.dialogMode) {\r\n // get roles first they will be needed in order to set available roles for each contact\r\n this.roles = await this._roleService.get();\r\n\r\n // now get all contacts\r\n await this.searchContactsOnServer('');\r\n } else {\r\n // we don't need roles, just load contacts\r\n await this.searchContactsOnServer('');\r\n }\r\n }\r\n}\r\n","import { efAction } from '../constants.new';\r\n\r\nexport class Attachment {\r\n attachmentID: string;\r\n externalID: string;\r\n entityID: number;\r\n entityTypeID: number;\r\n fileName: string;\r\n fileExtension: string;\r\n description: string;\r\n year: number;\r\n attachmentCategoryID: number;\r\n attachmentCategory: string;\r\n attachmentTypeID: number;\r\n attachmentType: Core.AttachmentTypeModel;\r\n size: number;\r\n numberOfPages: number;\r\n metaData: string;\r\n entityName: string;\r\n parentEntityName: string;\r\n createdBy: string;\r\n createdByFirstName: string;\r\n createdByLastName: string;\r\n createdDate: Date;\r\n efAction: efAction;\r\n externalFileLocationId: number;\r\n relativeFilePath: string;\r\n rowVersion: string;\r\n}\r\n\r\nexport interface AttachmentCategory {\r\n attachmentCategoryID: number;\r\n category: string;\r\n efAction: efAction;\r\n}\r\n\r\nexport class AttachmentInfo {\r\n constructor(newEntityTypeID, newAttachmentID, newEntityID, newFileName, newFileExt, size) {\r\n this.entityTypeID = newEntityTypeID;\r\n this.attachmentID = newAttachmentID;\r\n this.entityID = newEntityID;\r\n this.fileName = newFileName;\r\n this.fileExtension = newFileExt;\r\n this.size = size;\r\n }\r\n\r\n entityTypeID: number;\r\n attachmentID: string;\r\n entityID: number;\r\n fileName: string;\r\n fileExtension: string;\r\n size: number;\r\n}\r\n\r\n// This enumeration should probably be defined in some sort of global constant system\r\n// Also note, this is not all attachment types, just the ones we have special logic for in the UI\r\nexport enum AttachmentTypeID {\r\n AppealApplication = 1,\r\n AppealDecision = 2,\r\n AppealDocumentExchange = 3,\r\n Refund = 8,\r\n TaxBill = 9,\r\n TaxReceipt = 11,\r\n PPReturn = 23,\r\n ValueNotice = 27,\r\n HearingNotice = 28,\r\n MiscFiling = 49,\r\n AbatementApplication = 54,\r\n FreeportApplication = 55,\r\n PollutionControlApplication = 56,\r\n AppealConfirmation = 64\r\n}\r\n\r\nexport interface MimeTypeExtension {\r\n type: string;\r\n exts: string[];\r\n previewSupported: boolean;\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Routing/sd-http.service';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class CustomeEmailTemplateService {\r\n\r\n constructor(private http: SDHttpService) { }\r\n\r\n getEmailTemplateFields() {\r\n return this.http.get('/api/PaymentPackage/EmailTemplateFields');\r\n }\r\n}\r\n","import { Pipe, PipeTransform } from '@angular/core';\r\nimport {PaymentPackageRecipient} from './transmittal.models';\r\n\r\n@Pipe({\r\n name: 'recipientType',\r\n pure: false\r\n})\r\nexport class RecipientTypePipe implements PipeTransform {\r\n transform(items: PaymentPackageRecipient[], filter: any): PaymentPackageRecipient[] {\r\n if (!items || !filter) {\r\n return items;\r\n }\r\n\r\n return items.filter(item => item.recipientType === filter.recipientType);\r\n }\r\n}","\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
0\" style=\"margin-top:-20px;\">\r\n \r\n
\r\n
\r\n \r\n
\r\n To:\r\n \r\n {{ recipient.fullName }}; \r\n \r\n
\r\n
\r\n \r\n Cc:\r\n {{ recipient.fullName }}; \r\n \r\n
\r\n
\r\n \r\n Bcc:\r\n {{ recipient.fullName }}; \r\n \r\n
\r\n
\r\n {{ emailSubject }}\r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n

\r\n This file is large and may take a long time to preview.\r\n Please use the download button below or\r\n Click here to preview the file anyway.\r\n

\r\n
\r\n
\r\n

Preview not supported. Please use the download button below.

\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { QuillModules } from 'ngx-quill';\r\nimport { ContentChange } from 'ngx-quill/lib/quill-editor.component';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport {\r\n PaymentPackage, RecipientType, InvoiceAttachmentInfo,\r\n AttachmentType, InvoicePreviewData\r\n} from '../transmittal.models';\r\nimport { TransmittalService } from '../transmittal.service';\r\nimport { Attachment, AttachmentInfo } from '../../../Attachment/attachment.model';\r\nimport { CustomeEmailTemplateService } from '../../../Common/Custom-Email-Template/custom-email-template.service';\r\nimport * as _ from 'lodash';\r\nimport { AttachmentService } from 'src/app/Attachment/attachment.service';\r\nimport { firstValueFrom } from 'rxjs';\r\n\r\ndeclare const $: any;\r\n\r\nexport interface TemplateField {\r\n name: string;\r\n validInSubject: boolean;\r\n isLateBound: boolean;\r\n}\r\n\r\nexport interface TemplateFields {\r\n subject: TemplateField[];\r\n body: TemplateField[];\r\n}\r\n\r\n@Component({\r\n selector: 'review-payment-package-modal',\r\n templateUrl: './payment-packages-review.modal.html'\r\n})\r\nexport class ReviewPaymentPackageModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _attachmentService: AttachmentService,\r\n private readonly _transmittalService: TransmittalService,\r\n private readonly _customEmailTemplateService: CustomeEmailTemplateService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _messageBoxService: MessageBoxService) {\r\n }\r\n\r\n params: PaymentPackage;\r\n result: void;\r\n\r\n package: PaymentPackage;\r\n loading: boolean = true;\r\n\r\n attachment: Attachment;\r\n attachmentUrl: string;\r\n availableAttachments: InvoiceAttachmentInfo[];\r\n selectedAttachment: InvoiceAttachmentInfo;\r\n previewMode: boolean;\r\n emailSubjectTemplate: string;\r\n backupSubjectTemplate: string;\r\n emailSubject: string;\r\n emailTextTemplate: string;\r\n backupTextTemplate: string;\r\n emailText: string;\r\n editingEmail: boolean;\r\n emailTemplateFields: TemplateFields;\r\n editorInstance: QuillModules;\r\n attachmentSizeWarn: boolean;\r\n downloading: boolean;\r\n\r\n RecipientType = RecipientType;\r\n\r\n\r\n async ngOnInit(): Promise {\r\n this.downloading = false;\r\n\r\n this.package = this.params;\r\n this.availableAttachments = [];\r\n this.previewMode = !this.package.completedByUserID;\r\n this.emailText = this.package.emailText;\r\n this.emailSubject = this.package.emailSubject;\r\n this.editingEmail = false;\r\n\r\n if (!this.previewMode) {\r\n if (this.package.attachments.length > 0) {\r\n _.forEach(this.package.attachments, attachment => {\r\n this.availableAttachments.push({\r\n fileExtension: attachment.fileExtension,\r\n fileName: attachment.fileName,\r\n Attachment: attachment,\r\n attachmentType: AttachmentType.APFeed,\r\n id: attachment.attachmentID\r\n });\r\n });\r\n }\r\n }\r\n\r\n await this.getReviewData();\r\n\r\n if (this.package.apFeedAttachments.length > 0) {\r\n _.forEach(this.package.apFeedAttachments, attachment => {\r\n this.availableAttachments.push({\r\n fileExtension: attachment.fileExtension,\r\n fileName: attachment.fileName,\r\n Attachment: attachment,\r\n attachmentType: AttachmentType.APFeed\r\n });\r\n });\r\n }\r\n }\r\n\r\n async close(): Promise {\r\n const subjectHasChanged = this.backupSubjectTemplate && JSON.stringify(this.backupSubjectTemplate) !== JSON.stringify(this.emailSubjectTemplate);\r\n const emailHasChanged = this.backupTextTemplate && JSON.stringify(this.backupTextTemplate) !== JSON.stringify(this.emailText);\r\n\r\n if (subjectHasChanged || emailHasChanged) {\r\n const response = await this._messageBoxService.open({\r\n message: 'Changes will be lost. Are you sure you would like to close before downloading or sending?',\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n if (response === MessageBoxResult.Yes) {\r\n this._bsModalRef.hide();\r\n }\r\n } else {\r\n this._bsModalRef.hide();\r\n }\r\n }\r\n\r\n blobCallback(result: ArrayBuffer): void {\r\n const attachmentBlob = new Blob([result], {\r\n type: 'application/pdf'\r\n });\r\n this.attachmentUrl = URL.createObjectURL(attachmentBlob);\r\n }\r\n\r\n async previewAnyway(): Promise {\r\n this.attachmentSizeWarn = false;\r\n await this.loadAttachment(true);\r\n }\r\n\r\n async getReviewData(): Promise {\r\n this.attachmentSizeWarn = false;\r\n if (this.previewMode) {\r\n this.loading = true;\r\n try {\r\n const allResult = await Promise.all([this._transmittalService.GetPreviewData(this.package), this._customEmailTemplateService.getEmailTemplateFields()]);\r\n const previewData: InvoicePreviewData = allResult[0];\r\n // TODO: Make a model for this\r\n const templateFieldResult = allResult[1];\r\n this.emailTemplateFields = {\r\n subject: _.filter(templateFieldResult, r => r.isLateBound && r.validInSubject),\r\n body: _.filter(templateFieldResult, r => r.isLateBound)\r\n };\r\n\r\n this.emailSubjectTemplate = previewData.emailSubjectTemplate;\r\n this.emailSubject = previewData.emailSubject;\r\n this.emailTextTemplate = previewData.emailTextTemplate;\r\n this.emailText = previewData.emailText;\r\n this.availableAttachments = previewData.attachments;\r\n this.selectedAttachment = this.availableAttachments[0];\r\n const template = await this._transmittalService.GetPreviewAttachment(this.package, this.selectedAttachment);\r\n this.blobCallback(template.data);\r\n } finally {\r\n this.loading = false;\r\n }\r\n } else {\r\n this.selectedAttachment = this.availableAttachments[0];\r\n await this.loadAttachment(false);\r\n }\r\n }\r\n\r\n async downloadAttachment(): Promise {\r\n this.downloading = true;\r\n\r\n try {\r\n if (this.previewMode) {\r\n let result;\r\n try {\r\n result = await this._transmittalService.GetPreviewAttachment(this.package, this.selectedAttachment);\r\n } catch (err) {\r\n // HACK: We specifically asked for an ArrayBuffer in the result, but if there's an error we need a string. Meaningful\r\n // messages are possible from this endpoint, so catch errors and convert them to strings.\r\n // This is an obscure circumstance so a hack probably isn't a huge deal here, but ideally this'd be handled in our general\r\n // http code instead of right here in the logic.\r\n if (err.status === 400) {\r\n const errResult: {\r\n message: string\r\n } = JSON.parse(String.fromCharCode.apply(null, new Uint8Array(err.data)));\r\n this._toastr.error(errResult.message);\r\n return;\r\n } else {\r\n throw err;\r\n }\r\n }\r\n this._attachmentService.performDownload(result.data, this.selectedAttachment.fileName, this.selectedAttachment.fileExtension);\r\n } else {\r\n const attachment = this.selectedAttachment.Attachment;\r\n const attachmentInfo = new AttachmentInfo(attachment.entityTypeID,\r\n attachment.attachmentID,\r\n attachment.entityID,\r\n attachment.fileName,\r\n attachment.fileExtension,\r\n attachment.size);\r\n await this._attachmentService.downloadAttachmentFile(attachmentInfo, false);\r\n }\r\n } finally {\r\n this.downloading = false;\r\n }\r\n }\r\n\r\n async onAttachmentChange(attachmentInfo: InvoiceAttachmentInfo): Promise {\r\n this.attachmentSizeWarn = false;\r\n this.selectedAttachment = attachmentInfo;\r\n\r\n if (this.previewMode) {\r\n if (attachmentInfo.fileExtension === 'pdf') {\r\n this.loading = true;\r\n\r\n try {\r\n const result = await this._transmittalService.GetPreviewAttachment(this.package, this.selectedAttachment);\r\n this.blobCallback(result.data);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n } else {\r\n await this.loadAttachment(false);\r\n }\r\n }\r\n\r\n beginEditEmail(): void {\r\n this.editingEmail = true;\r\n this.backupSubjectTemplate = this.emailSubjectTemplate;\r\n this.backupTextTemplate = this.emailTextTemplate;\r\n }\r\n\r\n cancelEditEmail(): void {\r\n this.emailSubjectTemplate = this.backupSubjectTemplate;\r\n this.emailTextTemplate = this.backupTextTemplate;\r\n this.editingEmail = false;\r\n }\r\n\r\n async saveEditEmail(): Promise {\r\n if (!this.package.originalEmailSubjectTemplate) {\r\n this.package.originalEmailSubjectTemplate = this.package.emailSubjectTemplate;\r\n }\r\n if (!this.package.originalEmailTextTemplate) {\r\n this.package.originalEmailTextTemplate = this.package.emailTemplate;\r\n }\r\n this.package.emailSubjectTemplate = this.emailSubjectTemplate;\r\n this.package.emailTemplate = this.emailTextTemplate;\r\n\r\n await this.getReviewData();\r\n this.editingEmail = false;\r\n this.package.lockedForOverrideEmail = true;\r\n }\r\n\r\n addBindingCreated(quillInstance: QuillModules): void {\r\n this.editorInstance = quillInstance;\r\n }\r\n\r\n insertFieldInBody(field: TemplateField): void {\r\n const cursorPosition: number = this.editorInstance.getSelection(true).index;\r\n const fieldName: string = `{{ ${field.name} }}`;\r\n\r\n this.editorInstance.insertText(cursorPosition, fieldName);\r\n }\r\n\r\n // Inserting field does not trigger binding change event, so we need to manually update the model\r\n contentChange(change: ContentChange): void {\r\n this.emailTextTemplate = change.html;\r\n }\r\n\r\n // http://jsfiddle.net/4abr7jc5/2/\r\n insertFieldInSubject(field: TemplateField): void {\r\n const templateSubject = $('#template-subject');\r\n const cursorPosStart = templateSubject.prop('selectionStart');\r\n const cursorPosEnd = templateSubject.prop('selectionEnd');\r\n const v = templateSubject.val();\r\n const textBefore = v.substring(0, cursorPosStart);\r\n const textAfter = v.substring(cursorPosEnd, v.length);\r\n const fieldName = `{{ ${field.name} }}`;\r\n\r\n templateSubject.val(textBefore + fieldName + textAfter);\r\n this.emailSubjectTemplate = templateSubject.val();\r\n\r\n templateSubject.focus();\r\n }\r\n\r\n private async loadAttachment(skipSizeWarning: boolean): Promise {\r\n const attachment = this.selectedAttachment.Attachment;\r\n if (attachment.fileExtension !== 'pdf') {\r\n this.attachmentUrl = null;\r\n this.loading = false;\r\n return Promise.resolve();\r\n }\r\n // Don't show the preview if the attachment is over 5 MB (maybe this value should be\r\n // configurable somehow?)\r\n else if (!skipSizeWarning && attachment.size > 5242880) {\r\n this.attachmentUrl = null;\r\n this.attachmentSizeWarn = true;\r\n this.loading = false;\r\n return Promise.resolve();\r\n } else {\r\n this.loading = true;\r\n\r\n try {\r\n const attachmentInfo: AttachmentInfo = new AttachmentInfo(attachment.entityTypeID,\r\n attachment.attachmentID,\r\n attachment.entityID,\r\n attachment.fileName,\r\n attachment.fileExtension,\r\n attachment.size);\r\n\r\n const result = await firstValueFrom(this._attachmentService.getSingleAttachmentBody(attachmentInfo));\r\n this.blobCallback(result.body);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { TransmittalRepository } from '../../Core-Repositories/transmittal.repository';\r\nimport { ReviewPaymentPackageModalComponent } from './Modals/payment-packages-review.modal';\r\nimport {\r\n PaymentPackage,\r\n InvoicePreviewData,\r\n InvoiceAttachmentInfo,\r\n PaymentPackageAttachmentSummary, AttachmentType\r\n} from './transmittal.models';\r\n\r\n@Injectable()\r\nexport class TransmittalService {\r\n constructor(private readonly _transmittalRepository: TransmittalRepository,\r\n private readonly _weissmanModalService: WeissmanModalService) {\r\n }\r\n\r\n // TODO: Create a model for bulk operation results and use it here instead of \"any\"\r\n CreatePaymentPackage(taskIDs: number[]): Promise {\r\n return lastValueFrom(this._transmittalRepository.CreatePaymentPackage(taskIDs));\r\n }\r\n\r\n ReReview(payload: any): Promise {\r\n return lastValueFrom(this._transmittalRepository.ReReview(payload));\r\n }\r\n\r\n CheckFinalizeLongRunningProcess(packageIds: number[]): Promise {\r\n return lastValueFrom(this._transmittalRepository.CheckFinalizeLongRunningProcess(packageIds));\r\n }\r\n\r\n GetPaymentPackages(packageIDs: number[]): Promise {\r\n return lastValueFrom(this._transmittalRepository.GetPaymentPackages(packageIDs));\r\n }\r\n\r\n GetPaymentPackagesByCompanyID(companyId: string, startDate: Date, endDate: Date): Promise {\r\n return lastValueFrom(this._transmittalRepository.GetPaymentPackagesByCompanyID(companyId, startDate, endDate));\r\n }\r\n\r\n GetPaymentPackagesByPaymentID(paymentID: number): Promise {\r\n return lastValueFrom(this._transmittalRepository.GetPaymentPackagesByPaymentID(paymentID));\r\n }\r\n\r\n GetPaymentPackageByID(paymentPackageID: number): Promise {\r\n return lastValueFrom(this._transmittalRepository.GetPaymentPackageByID(paymentPackageID));\r\n }\r\n\r\n CheckForMissingAttachments(taskIDs: number[]): Promise {\r\n return lastValueFrom(this._transmittalRepository.CheckForMissingAttachments(taskIDs));\r\n }\r\n\r\n CancelPaymentPackages(packageIDs: number[]): Promise {\r\n return lastValueFrom(this._transmittalRepository.CancelPaymentPackages(packageIDs));\r\n }\r\n\r\n FinalizePaymentPackages(packages: PaymentPackage[]): Promise {\r\n return lastValueFrom(this._transmittalRepository.FinalizePaymentPackages(packages));\r\n }\r\n\r\n FinalizePaymentPackagesLR(request: Core.PaymentPackageFinalizeRequestDTO): Promise {\r\n return lastValueFrom(this._transmittalRepository.FinalizePaymentPackagesLR(request));\r\n }\r\n\r\n RecallPaymentPackage(packageItem: PaymentPackage): Promise {\r\n return lastValueFrom(this._transmittalRepository.RecallPaymentPackage(packageItem));\r\n }\r\n\r\n GetLRFinalizeResults(longRunningProcessId: number) : Promise {\r\n return lastValueFrom(this._transmittalRepository.GetLRFinalizeResults(longRunningProcessId));\r\n }\r\n\r\n GetPreviewData(currentPackage: PaymentPackage): Promise {\r\n return lastValueFrom(this._transmittalRepository.GetPreviewData(currentPackage));\r\n }\r\n\r\n GetPreviewAttachment(currentPackage: PaymentPackage, attachmentInfo: InvoiceAttachmentInfo): Promise {\r\n return this._transmittalRepository.GetPreviewAttachment(currentPackage, attachmentInfo);\r\n }\r\n\r\n GetPaymentPackageAttachmentSummary(paymentPackageID: number): Promise {\r\n return lastValueFrom(this._transmittalRepository.GetPaymentPackageAttachmentSummary(paymentPackageID));\r\n }\r\n\r\n showPaymentPackageReviewModal(paymentPackage: PaymentPackage): Promise {\r\n return this._weissmanModalService.showAsync(ReviewPaymentPackageModalComponent, paymentPackage, 'modal-xl');\r\n }\r\n}\r\n","import { Address } from '../../Models/common.model';\r\n\r\nexport class EntityAddress {\r\n constructor(entityID: number, entityTypeID: number) {\r\n this.entityID = entityID;\r\n this.entityTypeID = entityTypeID;\r\n this.entityAddressCorrespondences = [];\r\n this.address = new Address();\r\n }\r\n\r\n address: Address;\r\n entityAddressCorrespondences: EntityAddressCorrespondence[];\r\n entityAddressID: number;\r\n entityTypeID: number;\r\n entityID: number;\r\n addressID: number;\r\n remark: string;\r\n isDefault: boolean;\r\n efAction: string;\r\n isEditMode: boolean;\r\n correspondenceTypes: CorrespondenceType[];\r\n addressDeliverabilityDecision: Core.EntityAddressDeliverabilityDecisionDTO;\r\n}\r\n\r\nexport class EntityAddressCorrespondence {\r\n correspondenceType: CorrespondenceType;\r\n entityAddressCorrespondenceID: number;\r\n entityAddressID: number;\r\n correspondenceTypeID: number;\r\n efAction: string;\r\n}\r\n\r\nexport class CorrespondenceType {\r\n correspondenceTypeID: number;\r\n name: string;\r\n sequence: number;\r\n efAction: string;\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { EntityAddressDeliverabilityActionEnum } from 'src/app/constants.new';\r\n\r\nexport interface EntityAddressDeliverabilityIssueParams {\r\n entityTypeID: Core.EntityTypes;\r\n givenAddress: string;\r\n suggestedAddress: string;\r\n entityID: number;\r\n addressID?: number;\r\n messages: string[];\r\n validated: boolean;\r\n upmsServiceIsAvailable: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'assets-deliverability-issue-modal',\r\n template: `\r\n \r\n
    0\">\r\n
  • {{message}}
  • \r\n
\r\n
\r\n `\r\n})\r\n\r\nexport class EntityAddressDeliverabilityIssueComponent implements IWeissmanModalComponent\r\n{\r\n constructor(\r\n private readonly _modalRef: BsModalRef\r\n ) {}\r\n\r\n params: EntityAddressDeliverabilityIssueParams;\r\n result: Core.EntityAddressDeliverabilityDecisionDTO;\r\n\r\n\r\n async revise(): Promise {\r\n const decision: Core.EntityAddressDeliverabilityDecisionDTO = {\r\n actionTakenID: EntityAddressDeliverabilityActionEnum.Revise,\r\n givenAddress: this.params.givenAddress,\r\n suggestedAddress: this.params.suggestedAddress,\r\n addressID: this.params.addressID,\r\n entityTypeID: this.params.entityTypeID,\r\n entityID: this.params.entityID,\r\n actionTakenDate: new Date()\r\n };\r\n\r\n this.result = decision;\r\n this._modalRef.hide();\r\n }\r\n\r\n async ignore(): Promise {\r\n const decision: Core.EntityAddressDeliverabilityDecisionDTO = {\r\n actionTakenID: EntityAddressDeliverabilityActionEnum.Ignore,\r\n givenAddress: this.params.givenAddress,\r\n suggestedAddress: this.params.suggestedAddress,\r\n addressID: this.params.addressID,\r\n entityTypeID: this.params.entityTypeID,\r\n entityID: this.params.entityID,\r\n actionTakenDate: new Date()\r\n };\r\n\r\n this.result = decision;\r\n this._modalRef.hide();\r\n }\r\n\r\n async unavailable(): Promise {\r\n const decision: Core.EntityAddressDeliverabilityDecisionDTO = {\r\n actionTakenID: EntityAddressDeliverabilityActionEnum.Unavailable,\r\n givenAddress: this.params.givenAddress,\r\n suggestedAddress: null,\r\n addressID: this.params.addressID,\r\n entityTypeID: this.params.entityTypeID,\r\n entityID: this.params.entityID,\r\n actionTakenDate: new Date()\r\n };\r\n\r\n this.result = decision;\r\n this._modalRef.hide();\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../../Routing/sd-http.service';\r\nimport { EntityAddress, CorrespondenceType } from './address.model';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class AddressDetailsModalService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n getEntityAddresses(entityID: number, entityTypeID: number): Promise {\r\n const entityString: string = this.getEntityString(entityTypeID);\r\n\r\n return this.http.get(`/api/${entityString}/EntityAddresses/${entityID}`);\r\n }\r\n\r\n getCorrespondenceTypes(entityTypeId: number): Promise {\r\n return this.http.get(`/api/correspondenceType/entityType/${entityTypeId}`);\r\n }\r\n\r\n updateEntityAddresses(entityAddresses: EntityAddress[], entityTypeID: number): Promise {\r\n const entityString: string = this.getEntityString(entityTypeID);\r\n\r\n return this.http.put(`/api/${entityString}/EntityAddresses`, entityAddresses);\r\n }\r\n\r\n getEntityAddressDeliverability(entityAddress: EntityAddress, entityTypeID: number): Promise {\r\n const entityString: string = this.getEntityString(entityTypeID);\r\n\r\n return this.http.post(`/api/${entityString}/EntityAddress/Deliverability`, entityAddress);\r\n }\r\n\r\n private getEntityString(entityTypeID: number): string {\r\n switch(entityTypeID) {\r\n case 1:\r\n return 'company';\r\n case 3:\r\n return 'assessor';\r\n case 4:\r\n return 'collector';\r\n }\r\n }\r\n}\r\n","
\r\n

Addresses

\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n Default\r\n AddressCorrespondenceRemark
\r\n \r\n \r\n \r\n \r\n
\r\n {{correspondence.correspondenceType.name}}, \r\n
\r\n
\r\n \r\n {{correspondence.correspondenceType.name}} \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n {{entityAddress.remark}}\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { EntityAddress, CorrespondenceType, EntityAddressCorrespondence } from './address.model';\r\nimport { AddressDetailsModalService } from './address.details.modal.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { Address } from '../../Models/common.model';\r\nimport { EntityAddressDeliverabilityIssueComponent, EntityAddressDeliverabilityIssueParams } from './address.deliverability.issue';\r\nimport { EntityAddressDeliverabilityActionEnum } from 'src/app/constants.new';\r\n\r\ninterface EntityAddressUI extends EntityAddress {\r\n isHovered?: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'address-details-modal',\r\n templateUrl: './address.details.modal.component.html'\r\n})\r\nexport class AddressDetailsModalComponent implements OnInit {\r\n constructor(public bsModalRef: BsModalRef,\r\n private addressDetailsModalService: AddressDetailsModalService,\r\n private toastr: ToastrService,\r\n private readonly _modalService: WeissmanModalService) { }\r\n\r\n entityAddressesToRevertTo: EntityAddressUI[];\r\n entityID: number;\r\n entityTypeID: number;\r\n entityAddresses: EntityAddressUI[];\r\n isAbleToBeEdited: boolean;\r\n justSelect: boolean;\r\n checkDeliverability: boolean;\r\n itemCount: number;\r\n\r\n isEditing: boolean = false;\r\n loading: boolean = false;\r\n onClose: any;\r\n\r\n private _correspondenceTypes: CorrespondenceType[];\r\n\r\n\r\n ngOnInit() {\r\n if(this.justSelect) {\r\n return;\r\n }\r\n\r\n this._setupCorrespondenceTypes();\r\n }\r\n\r\n editEntityAddress(entityAddress: EntityAddress): void {\r\n this.entityAddressesToRevertTo = _.cloneDeep(this.entityAddresses);\r\n\r\n entityAddress.isEditMode = true;\r\n this.isEditing = true;\r\n }\r\n\r\n deleteEntityAddress(entityAddress: EntityAddress): void {\r\n if(entityAddress.efAction == 'add') {\r\n _.remove(this.entityAddresses, entityAddress);\r\n } else {\r\n entityAddress.efAction = 'delete';\r\n }\r\n }\r\n\r\n cancelAddEdit(entityAddress: EntityAddress): void {\r\n if(entityAddress.efAction == 'add') {\r\n _.remove(this.entityAddresses, entityAddress);\r\n } else {\r\n entityAddress.isEditMode = false;\r\n }\r\n\r\n this.entityAddresses = this.entityAddressesToRevertTo;\r\n\r\n this.isEditing = false;\r\n }\r\n\r\n async addNew(): Promise {\r\n this.entityAddressesToRevertTo = _.cloneDeep(this.entityAddresses);\r\n\r\n let newEntityAddress: EntityAddressUI = new EntityAddress(this.entityID, this.entityTypeID);\r\n newEntityAddress.isEditMode = true;\r\n newEntityAddress.efAction = 'add';\r\n newEntityAddress.isDefault = !this.entityAddresses.length;\r\n newEntityAddress = this._addCorrespondenceTypes(newEntityAddress);\r\n\r\n this.entityAddresses.push(newEntityAddress);\r\n\r\n this.isEditing = true;\r\n }\r\n\r\n async update(entityAddress: EntityAddress): Promise {\r\n if(!entityAddress.address.stateID) {\r\n this.toastr.error('State is Required!');\r\n\r\n return;\r\n }\r\n\r\n if(entityAddress.efAction != 'add') {\r\n entityAddress.efAction = 'update';\r\n }\r\n\r\n if(this.checkDeliverability){\r\n await this._determineEntityAddressDeliverability(entityAddress);\r\n } else {\r\n entityAddress.isEditMode = false;\r\n this.isEditing = false;\r\n }\r\n }\r\n\r\n defaultSelected(entityAddressClicked: EntityAddress, indexClicked: number): void {\r\n this.entityAddresses = _.map(this.entityAddresses, (entityAddress: EntityAddress, i: number) => {\r\n if(entityAddress.isDefault && i !== indexClicked) {\r\n entityAddress.isDefault = false;\r\n\r\n entityAddress.efAction = entityAddress.efAction || 'update';\r\n }\r\n\r\n return entityAddress;\r\n });\r\n\r\n setTimeout(() => entityAddressClicked.isDefault = true);\r\n entityAddressClicked.efAction = entityAddressClicked.efAction || 'update';\r\n }\r\n\r\n addCorrespondence(correspondenceType: CorrespondenceType, entityAddress: EntityAddress): void {\r\n const entityAddressCorrespondence: EntityAddressCorrespondence = new EntityAddressCorrespondence();\r\n entityAddressCorrespondence.correspondenceType = correspondenceType;\r\n entityAddressCorrespondence.correspondenceTypeID = correspondenceType.correspondenceTypeID;\r\n entityAddressCorrespondence.entityAddressID - entityAddress.entityAddressID;\r\n\r\n entityAddress.entityAddressCorrespondences.push(entityAddressCorrespondence);\r\n\r\n _.remove(entityAddress.correspondenceTypes, correspondenceType);\r\n\r\n entityAddress.efAction = entityAddress.efAction || 'update';\r\n }\r\n\r\n removeCorrespondence(correspondence: EntityAddressCorrespondence, entityAddress: EntityAddress): void {\r\n _.remove(entityAddress.entityAddressCorrespondences, correspondence);\r\n\r\n entityAddress.correspondenceTypes.push(correspondence.correspondenceType);\r\n entityAddress.correspondenceTypes = _.sortBy(entityAddress.correspondenceTypes, 'name');\r\n\r\n entityAddress.efAction = entityAddress.efAction || 'update';\r\n }\r\n\r\n save(): void {\r\n if(this.isEditing) {\r\n const editedAddress = _.find(this.entityAddresses, 'isEditMode');\r\n\r\n this.cancelAddEdit(editedAddress);\r\n }\r\n\r\n const entityAddresses: EntityAddress[] = _.map(this.entityAddresses,\r\n address => {\r\n _.omit(address, ['hover', 'isEditMode', 'correspondenceTypes']);\r\n _.omit(address.addressDeliverabilityDecision, ['hover', 'isEditMode', 'correspondenceTypes']);\r\n return address;\r\n }) as EntityAddress[];\r\n\r\n this.onClose(entityAddresses);\r\n this.bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this.bsModalRef.hide();\r\n }\r\n\r\n private async _setupCorrespondenceTypes() {\r\n this.loading = true;\r\n\r\n try {\r\n this._correspondenceTypes = await this.addressDetailsModalService.getCorrespondenceTypes(this.entityTypeID);\r\n\r\n this.entityAddresses = _.chain(this.entityAddresses)\r\n .map((entityAddress: EntityAddressUI) => this._addCorrespondenceTypes(entityAddress))\r\n .orderBy(['isDefault', 'address.address1'], ['desc', 'asc'])\r\n .value();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n private _addCorrespondenceTypes(entityAddress: EntityAddressUI): EntityAddressUI {\r\n entityAddress.correspondenceTypes = _.chain(this._correspondenceTypes)\r\n .cloneDeep()\r\n .reject((correspondenceType: CorrespondenceType) => {\r\n return _.some(entityAddress.entityAddressCorrespondences, {correspondenceTypeID: correspondenceType.correspondenceTypeID});\r\n })\r\n .sortBy('name')\r\n .value();\r\n\r\n return entityAddress;\r\n }\r\n\r\n\r\n private _getUpmsAddressString(item: Core.UpmsAddressDto): string{\r\n let arr = [item.line1, item.line2, item.city, item.state, item.zip, item.country];\r\n arr = arr.filter(e => e && String(e).trim());\r\n return arr.join(', ');\r\n }\r\n\r\n private _getAddressString(item: Address, item2: Core.UpmsAddressDto): string{\r\n let arr = [item.address1, item.address2, item.city, item.abbr, item.zip, item2 && item2.country];\r\n arr = arr.filter(e => String(e).trim());\r\n return arr.join(', ');\r\n }\r\n\r\n private async _determineEntityAddressDeliverability(entityAddress: EntityAddress){\r\n this.loading = true;\r\n\r\n let upmsValidatedAddress: Core.UpmsValidatedAddressDto = null;\r\n\r\n try\r\n {\r\n upmsValidatedAddress = await this.addressDetailsModalService.getEntityAddressDeliverability(entityAddress, this.entityTypeID);\r\n }\r\n finally\r\n {\r\n this.loading = false;\r\n }\r\n\r\n if(upmsValidatedAddress.deliverability == Core.UpmsEntityAddressDeliverability.Unavailable)\r\n {\r\n const params: EntityAddressDeliverabilityIssueParams = {\r\n entityTypeID: this.entityTypeID,\r\n givenAddress: this._getAddressString(entityAddress.address, upmsValidatedAddress.address),\r\n suggestedAddress: this._getUpmsAddressString(upmsValidatedAddress.address),\r\n entityID: this.entityID,\r\n addressID: entityAddress.address.addressID && entityAddress.address.addressID != 0 ? entityAddress.address.addressID : null,\r\n validated: upmsValidatedAddress.validated,\r\n messages: upmsValidatedAddress.messages,\r\n upmsServiceIsAvailable: false\r\n };\r\n\r\n const result: Core.EntityAddressDeliverabilityDecisionDTO = await this._modalService.showAsync(EntityAddressDeliverabilityIssueComponent, params, 'modal-md');\r\n entityAddress.addressDeliverabilityDecision = result;\r\n }\r\n\r\n if(upmsValidatedAddress.deliverability == Core.UpmsEntityAddressDeliverability.Undeliverable)\r\n {\r\n const params: EntityAddressDeliverabilityIssueParams = {\r\n entityTypeID: this.entityTypeID,\r\n givenAddress: this._getAddressString(entityAddress.address, upmsValidatedAddress.address),\r\n suggestedAddress: this._getUpmsAddressString(upmsValidatedAddress.address),\r\n entityID: this.entityID,\r\n addressID: entityAddress.address.addressID && entityAddress.address.addressID != 0 ? entityAddress.address.addressID : null,\r\n validated: upmsValidatedAddress.validated,\r\n messages: upmsValidatedAddress.messages,\r\n upmsServiceIsAvailable: true\r\n };\r\n\r\n const result: Core.EntityAddressDeliverabilityDecisionDTO = await this._modalService.showAsync(EntityAddressDeliverabilityIssueComponent, params, 'modal-md');\r\n entityAddress.addressDeliverabilityDecision = result;\r\n\r\n if(result.actionTakenID == EntityAddressDeliverabilityActionEnum.Revise) {\r\n entityAddress.isEditMode = true;\r\n this.isEditing = true;\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n entityAddress.isEditMode = false;\r\n this.isEditing = false;\r\n return Promise.resolve();\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AddressDetailsModalComponent } from './address.details.modal.component';\r\nimport { EntityAddress } from './address.model';\r\n\r\n@Injectable(\r\n {providedIn: 'root'}\r\n)\r\nexport class AddressDetailsModalLaunchService {\r\n constructor(\r\n private modalService: BsModalService\r\n ) { }\r\n\r\n customTemplateModalRef: BsModalRef;\r\n\r\n openAddressDetailsModal(entityID: number, entityTypeID: number, entityAddresses: EntityAddress[], isAbleToBeEdited: boolean, justSelect?: boolean, checkDeliverability?: boolean): Promise {\r\n const promise = new Promise((resolve) => {\r\n const initialState = {\r\n entityID: entityID,\r\n entityTypeID: entityTypeID,\r\n entityAddresses: entityAddresses,\r\n isAbleToBeEdited: isAbleToBeEdited,\r\n justSelect: justSelect,\r\n checkDeliverability: checkDeliverability\r\n };\r\n\r\n const modalRef = this.modalService.show(AddressDetailsModalComponent, {initialState, class: 'modal-change-history'});\r\n\r\n modalRef.content.onClose = (x: EntityAddress[]) => resolve(x);\r\n });\r\n\r\n return promise;\r\n }\r\n}\r\n","\r\n \r\n
\r\n
\r\n \r\n

\r\n Package #: {{ selectedPackage.transmittalType }}\r\n -\r\n Draft\r\n {{ selectedPackage.packageNumber }}\r\n

\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n {{transmittal.collectorName}}\r\n
{{transmittal.collectorAddress.address1}}\r\n
{{transmittal.collectorAddress.address2}}\r\n
{{transmittal.collectorAddress.city}}, {{transmittal.collectorAddress.abbr}} {{transmittal.collectorAddress.zip}}\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n {{recipients[RecipientType.ResponsibleParty][0].companyName}}\r\n
{{recipients[RecipientType.ResponsibleParty][0].fullName}}\r\n
{{recipients[RecipientType.ResponsibleParty][0].title}}\r\n
\r\n {{recipients[RecipientType.ResponsibleParty][0].address.address1}}\r\n
{{recipients[RecipientType.ResponsibleParty][0].address.address2}}\r\n
{{recipients[RecipientType.ResponsibleParty][0].address.city}}, {{recipients[RecipientType.ResponsibleParty][0].address.abbr}} {{recipients[RecipientType.ResponsibleParty][0].address.zip}}\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n {{cc.fullName}}; \r\n \r\n \r\n \r\n {{bcc.fullName}}; \r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Site NameParcel # / Collector #Property TypeAmountIntake ItemBill Image
{{item.siteName}}{{item.acctNum}} / {{item.collectorAcctNum}}{{constants.PropertyTypeNames[item.propertyType]}}{{item.amount | currency:'USD'}}\r\n {{item.intakeBatchNumber}}#{{item.intakeItemNumber}}\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n 1 && !readOnly && !selectedPackage.completedDateTime && !selectedPackage.lockedForOverrideEmail\" class=\"fa fa-close\" (click)=\"removeItem(transmittal, item)\">\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Total Amount:{{getTotalAmount(transmittal.paymentTransmittalItems) | currency:'USD'}}
Payment Due:\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Input, EventEmitter, Output } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { PaymentPackage, PaymentTransmittal, PaymentTransmittalItem, PaymentPackageRecipient, RecipientType } from './transmittal.models';\r\nimport { Constants, EntityTypeIds } from '../../constants.new';\r\nimport { PopUpService } from '../../Common/Popup/popup.service';\r\nimport { Attachment, AttachmentInfo } from '../../Attachment/attachment.model';\r\nimport { AssessorCollectorRepository } from '../../Core-Repositories';\r\nimport { AddressDetailsModalLaunchService } from '../../Common/Address/Address-View-Edit/address.details.modal.launch.service';\r\nimport { EntityAddress } from '../../Common/Address/Address-View-Edit/address.model';\r\nimport { AttachmentService } from 'src/app/Attachment/attachment.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'transmittal-details',\r\n templateUrl: './transmittal-details.component.html'\r\n})\r\nexport class TransmittalDetailsComponent implements OnInit {\r\n constructor(\r\n public constants: Constants,\r\n private popUpService: PopUpService,\r\n private assessorCollectorService: AssessorCollectorRepository,\r\n private addressModalService: AddressDetailsModalLaunchService,\r\n private upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private attachmentService: AttachmentService) {\r\n }\r\n\r\n @Input() selectedPackage: PaymentPackage;\r\n @Input() selectedTransmittalID: number;\r\n @Input() readOnly: boolean = true;\r\n @Input() isModal: boolean;\r\n @Input() isFromPaymentBatch: boolean;\r\n @Output() backClicked: EventEmitter = new EventEmitter();\r\n\r\n currentTransmittalIndex: number = null;\r\n recipients: object;\r\n RecipientType = RecipientType;\r\n isInit: boolean = true;\r\n currentBillAttachment: Attachment;\r\n collectorAddresses: EntityAddress[];\r\n\r\n\r\n ngOnInit() {\r\n this.recipients = _.groupBy(this.selectedPackage.paymentPackageRecipients, (recipient: PaymentPackageRecipient) => {\r\n return recipient.recipientType;\r\n });\r\n this.currentBillAttachment = null;\r\n\r\n }\r\n\r\n getPropertyTypeName(propertyTypeID: number): string {\r\n return this.constants.PropertyTypeNames[propertyTypeID];\r\n }\r\n\r\n getTotalAmount(items: PaymentTransmittalItem[]): number {\r\n return _.reduce(items, (total: Decimal, item: PaymentTransmittalItem) => {\r\n return total.plus(item.amount);\r\n }, new Decimal(0))\r\n .toNumber();\r\n }\r\n\r\n previewBill(item: PaymentTransmittalItem): void {\r\n const popUpData = {\r\n attachmentInfo: item.attachment\r\n };\r\n\r\n // if we have already opened the default window and the user hasn't closed it, just publish directly to it (it's faster)\r\n const globalAttachmentsPopUpRef = this.popUpService.getByAliasGroup(this.popUpService.StaticAliases.Attachment)[0];\r\n if (globalAttachmentsPopUpRef && globalAttachmentsPopUpRef.isOpen()) {\r\n globalAttachmentsPopUpRef.publish(this.popUpService.Topics.Attachment.AttachmentChanged, popUpData);\r\n } else {\r\n this.popUpService.openAttachmentPreview(this.popUpService.StaticAliases.Attachment, globalAttachmentsPopUpRef).then((popUpRef) => {\r\n popUpRef.publish(this.popUpService.Topics.Attachment.AttachmentChanged, popUpData);\r\n });\r\n }\r\n }\r\n\r\n async downloadBill(item: PaymentTransmittalItem): Promise {\r\n const downloadInfo: AttachmentInfo = new AttachmentInfo(item.attachment.entityTypeID,\r\n item.attachmentID,\r\n item.attachment.entityID,\r\n item.attachment.fileName,\r\n item.attachment.fileExtension,\r\n item.attachment.size);\r\n\r\n await this.attachmentService.downloadAttachmentFile(downloadInfo, false);\r\n }\r\n\r\n removeItem(transmittal: PaymentTransmittal, item: PaymentTransmittalItem): void {\r\n _.remove(transmittal.paymentTransmittalItems, item);\r\n }\r\n\r\n backClickedUI(): void {\r\n this.backClicked.emit();\r\n }\r\n\r\n async goToTransmittal(): Promise {\r\n this.selectedTransmittalID = Number(this.selectedTransmittalID);\r\n this.currentTransmittalIndex = _.findIndex(this.selectedPackage.paymentTransmittals, { paymentTransmittalID: this.selectedTransmittalID }) as number;\r\n\r\n const currentTransmittal = this.selectedPackage.paymentTransmittals[this.currentTransmittalIndex];\r\n const transmittalCollector = await lastValueFrom(this.assessorCollectorService.getCollector(currentTransmittal.collectorID));\r\n this.collectorAddresses = _.map(transmittalCollector.entityAddresses, x => {\r\n x.isDefault = x.addressID == currentTransmittal.collectorAddress.addressID;\r\n return x;\r\n });\r\n\r\n }\r\n\r\n slideChanged(e: number): void {\r\n // SlideChanged is called when this component is initialiazed, which is what we don't want, because the index gets set to 0\r\n // So we bypass it for this first time.\r\n if(this.isInit) {\r\n this.goToTransmittal();\r\n\r\n this.isInit = false;\r\n return;\r\n }\r\n\r\n this.selectedTransmittalID = this.selectedPackage.paymentTransmittals[this.currentTransmittalIndex].paymentTransmittalID;\r\n }\r\n\r\n async editCollectorAddress(): Promise {\r\n const currentTransmittal = this.selectedPackage.paymentTransmittals[this.currentTransmittalIndex];\r\n\r\n this.collectorAddresses = await this.addressModalService.openAddressDetailsModal(\r\n currentTransmittal.collectorID,\r\n EntityTypeIds.COLLECTOR,\r\n this.collectorAddresses,\r\n false,\r\n true\r\n );\r\n\r\n currentTransmittal.collectorAddress = _.find(this.collectorAddresses, 'isDefault').address;\r\n }\r\n\r\n preventCarouselFromInterceptingSpace($event) {\r\n if ($event.key === ' ') {\r\n $event.stopPropagation();\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { PaymentBatchRepository } from '../Core-Repositories/paymentBatch.repository';\r\nimport { PaymentBatchCompany } from './paymentBatch.model';\r\nimport { PaymentPackage } from '../Processing/Transmittal/transmittal.models';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PaymentBatchService {\r\n constructor(private readonly _paymentBatchRepo: PaymentBatchRepository) { }\r\n\r\n async getPaymentBatches(searchModel: Core.PaymentBatchSearchModel): Promise> {\r\n return lastValueFrom(this._paymentBatchRepo.getPaymentBatchList(searchModel));\r\n }\r\n\r\n async exportList(model: Compliance.AssessorCommandCenterExportModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.exportList(model));\r\n }\r\n\r\n async savePaymentBatch(request: Core.PaymentBatchCreateRequestModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.savePaymentBatch(request));\r\n }\r\n\r\n async getPaymentBatchDetailById(Id: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getPaymentBatchDetailById(Id));\r\n }\r\n\r\n async savePaymentBatchDetails(paymentBatchId: number, paymentBatch: Core.PaymentBatchModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.savePaymentBatchDetails(paymentBatchId, paymentBatch));\r\n }\r\n\r\n async getPaymentBatchDetailsWorkflowStatus(Id: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getPaymentBatchWorkflowStatusById(Id));\r\n }\r\n\r\n async getPaymentBatchPaymentsList(searchModel: Core.PaymentBatchDetailsSearchModel): Promise> {\r\n return lastValueFrom(this._paymentBatchRepo.getPaymentBatchPaymentsList(searchModel));\r\n }\r\n\r\n async getPaymentBatchPaymentsRowIds(searchModel: Core.PaymentBatchDetailsSearchModel): Promise> {\r\n return lastValueFrom(this._paymentBatchRepo.getPaymentBatchPaymentsRowIds(searchModel));\r\n }\r\n\r\n async startPaymentBatchDetailsPaymentBulkDelete(deleteModel: Core.PaymentBatchDetailsPaymentBulkDeleteModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.startPaymentBatchDetailsPaymentBulkDelete(deleteModel));\r\n }\r\n\r\n async paymentBatchDetailsPaymentBulkReReview(model: Core.PaymentBatchDetailsPaymentBulkReReviewModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.paymentBatchDetailsPaymentBulkReReview(model));\r\n }\r\n\r\n async getAvailableWorkflows(companyId: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getAvailableWorkflows(companyId));\r\n }\r\n\r\n async getDeliveryDetailPaymentBatch(companyId: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getDeliveryDetailPaymentBatch(companyId));\r\n }\r\n\r\n async getAvailablePaymentBatchesForAddPayments(tlCompanyId: number, taskIds: number[]): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getAvailablePaymentBatchesForAddPayments(tlCompanyId, taskIds));\r\n }\r\n\r\n async getPaymentBatchPaymentList(searchModel: Core.PaymentBatchAddPaymentSearchModel): Promise> {\r\n return lastValueFrom(this._paymentBatchRepo.getPaymentBatchPaymentList(searchModel));\r\n }\r\n\r\n async getPaymentBatchPaymentRowIds(searchModel: Core.PaymentBatchAddPaymentSearchModel): Promise> {\r\n return lastValueFrom(this._paymentBatchRepo.getPaymentBatchPaymentRowIds(searchModel));\r\n }\r\n\r\n async addPaymentsToPaymentBatch(paymentBatchId: number, request: Core.PaymentBatchAddPaymentRequestModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.addPaymentsToPaymentBatch(paymentBatchId, request));\r\n }\r\n\r\n async addPaymentsToBatchByTaskId(paymentBatchId: number, taskIds: number[]): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.addPaymentsToBatchByTaskId(paymentBatchId, taskIds));\r\n }\r\n\r\n async advanceTask(paymentBatchId: number, updateModel: Core.PaymentBatchTaskUpdateModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.advanceTask(paymentBatchId, updateModel));\r\n }\r\n\r\n async rescindTask(paymentBatchId: number, updateModel: Core.PaymentBatchTaskUpdateModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.rescindTask(paymentBatchId, updateModel));\r\n }\r\n\r\n async reassignTask(paymentBatchId: number, updateModel: Core.PaymentBatchTaskUpdateModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.reassignTask(paymentBatchId, updateModel));\r\n }\r\n\r\n async getAllowedBatchTypes(companyId: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getAllowedBatchTypes(companyId));\r\n }\r\n\r\n async finalizeTransmittalPackage(paymentBatchId: number, taskId: number, packages: PaymentPackage[]): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.finalizeTransmittalPackage(paymentBatchId, taskId, packages));\r\n }\r\n\r\n async getTransmittalPaymentPackages(paymentBatchId: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getTransmittalPaymentPackages(paymentBatchId));\r\n }\r\n\r\n async getBillPaymentPackages(paymentBatchId: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getBillPaymentPackages(paymentBatchId));\r\n }\r\n\r\n async getOutputZip(paymentBatchId: number, feedTypes: Core.PaymentBatchFeedTypes[]): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getOutputZip(paymentBatchId, feedTypes));\r\n }\r\n\r\n async getPaymentBatchSettings(paymentBatchId: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getPaymentBatchSettings(paymentBatchId));\r\n }\r\n\r\n async savePaymentBatchSettings(paymentBatchId: number, settings: Core.PaymentBatchSettingsModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.savePaymentBatchSettings(paymentBatchId, settings));\r\n }\r\n\r\n async startPaymentBatchCheckImport(paymentBatchId: number, file: FormData): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.startPaymentBatchCheckImport(paymentBatchId, file));\r\n }\r\n\r\n async getPaymentBatchCheckImport(paymentBatchId: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getPaymentBatchCheckImport(paymentBatchId));\r\n }\r\n\r\n async savePaymentBatchCheckImport(paymentBatchId: number, paymentBatchCheckImportId: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.savePaymentBatchCheckImport(paymentBatchId, paymentBatchCheckImportId));\r\n }\r\n\r\n async discardPaymentBatchCheckImport(paymentBatchId: number, paymentBatchCheckImportId: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.discardPaymentBatchCheckImport(paymentBatchId, paymentBatchCheckImportId));\r\n }\r\n\r\n async getAvailablePaymentBatchGridFilters(): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getAvailablePaymentBatchGridFilters());\r\n }\r\n\r\n async getAvailablePaymentBatchGridSubsidiaries(request: Core.PaymentBatchGridFilterSubCompaniesRequestModel): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getAvailablePaymentBatchGridSubsidiaries(request));\r\n }\r\n\r\n async getShippingMethods(paymentBatchId: number): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.getShippingMethods(paymentBatchId));\r\n }\r\n\r\n async setShippingMethods(paymentBatchId, shippingMethods: Core.PaymentBatchDetailsShippingMethodsModel[]): Promise {\r\n return lastValueFrom(this._paymentBatchRepo.setShippingMethods(paymentBatchId, shippingMethods));\r\n }\r\n}\r\n\r\n","
\r\n
\r\n
\r\n
\r\n

Finalize Payment Package

\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n

\r\n Too many output types selected\r\n

\r\n

\r\n Please select payment packages with only one output type\r\n

\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, OnDestroy, Output, ViewChild } from '@angular/core';\r\nimport { ModalDirective } from 'ngx-bootstrap/modal';\r\nimport {\r\n PaymentPackage,\r\n TransmittalOutputType,\r\n TransmittalOutputTypeButtonLabel,\r\n TransmittalOutputTypeOption\r\n} from '../transmittal.models';\r\nimport { TransmittalService } from '../transmittal.service';\r\nimport { AttachmentInfo } from '../../../Attachment/attachment.model';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AttachmentService } from 'src/app/Attachment/attachment.service';\r\nimport { PaymentBatchService } from 'src/app/Payment-Batch/paymentBatch.service';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\nimport { WebsocketListenerService } from 'src/app/Compliance/websocketListener.service';\r\nimport { lastValueFrom, Subscription } from 'rxjs';\r\nimport { LongRunningProcessRepository } from 'src/app/Compliance/Repositories';\r\nimport { UtilitiesService } from 'src/app/UI-Lib/Utilities/Utilities.Service.upgrade';\r\n\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'finalize-payment-package-modal',\r\n templateUrl: './payment-packages-finalize.modal.html'\r\n})\r\nexport class FinalizePaymentPackageModalComponent implements OnDestroy {\r\n constructor(private transmittalService: TransmittalService,\r\n private attachmentService: AttachmentService,\r\n private paymentBatchService: PaymentBatchService,\r\n private readonly busyIndicatorService: BusyIndicatorService,\r\n private upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private toastr: ToastrService,\r\n private websocketListenerService: WebsocketListenerService,\r\n private featureFlagsService: FeatureFlagsService,\r\n private utilities: UtilitiesService,\r\n private longRunningProcessRepository: LongRunningProcessRepository) {\r\n }\r\n\r\n @ViewChild('FinalizePaymentPackageModal', { static: true }) finalizePaymentPackageModal: ModalDirective;\r\n @Input() packageList: PaymentPackage[];\r\n @Input() setParentLoading: (loading: boolean, message: string, hideCancelHyperlink?: boolean) => void;\r\n @Input() isFromPaymentBatch: boolean;\r\n @Input() paymentBatchId: number;\r\n @Input() taskId: number;\r\n @Input() cancelExecutionLoop: boolean = false;\r\n @Output() hasPackageFinalized: EventEmitter = new EventEmitter();\r\n selectedPackages: PaymentPackage[];\r\n originalSelectedPackages: PaymentPackage[];\r\n tooManyOutputsError: boolean = false;\r\n outputTypeOptions: TransmittalOutputTypeOption[];\r\n buttonLabel: string;\r\n selectedOutputType: TransmittalOutputType;\r\n loading: boolean = false;\r\n addButtonLabel: string = 'Add';\r\n finalizeHasErrors: boolean = false;\r\n private statusChangeSubscription: Subscription = null;\r\n\r\n ngOnDestroy(): void {\r\n this.statusChangeSubscription && this.statusChangeSubscription.unsubscribe();\r\n }\r\n\r\n close(): void {\r\n this.tooManyOutputsError = false;\r\n this.finalizePaymentPackageModal.hide();\r\n }\r\n\r\n show(): void {\r\n this.setupModal(true);\r\n }\r\n\r\n setupModal(showModal: boolean) {\r\n this.loading = false;\r\n this.cancelExecutionLoop = false;\r\n this.originalSelectedPackages = this.selectedPackages;\r\n if (showModal) {\r\n this.finalizePaymentPackageModal.show();\r\n }\r\n this.prepareOutputTypes();\r\n }\r\n\r\n prepareOutputTypes(): void {\r\n //clear old value, if any, and initialize\r\n this.outputTypeOptions = [];\r\n\r\n //load selected packages\r\n this.selectedPackages = _.filter(this.packageList, (packageItem: PaymentPackage) => {\r\n return packageItem.isSelected === true;\r\n });\r\n\r\n //check if there are multiple output types in this selection\r\n const outputTypes: TransmittalOutputType[] = _.uniq(_.map(this.selectedPackages, 'transmittalOutputType'));\r\n if(outputTypes.length > 1) {\r\n this.tooManyOutputsError = true;\r\n return;\r\n } else if(outputTypes.length === 0) {\r\n //throw error?\r\n return;\r\n }\r\n\r\n //should only be one item by now\r\n const outputType = outputTypes[0];\r\n this.selectedOutputType = outputType;\r\n this.selectedOutputChanged(this.selectedOutputType);\r\n\r\n //generate dropdown options based on current default output types\r\n if(parseInt(outputType.toString()) === TransmittalOutputType.PaperTransmittal ||\r\n parseInt(outputType.toString()) === TransmittalOutputType.DigitalTransmittal) {\r\n this.outputTypeOptions.push(new TransmittalOutputTypeOption(TransmittalOutputType.PaperTransmittal, 'Paper Transmittal'));\r\n this.outputTypeOptions.push(new TransmittalOutputTypeOption(TransmittalOutputType.DigitalTransmittal, 'Digital Transmittal'));\r\n }\r\n\r\n if(parseInt(outputType.toString()) === TransmittalOutputType.APFeed) {\r\n this.outputTypeOptions.push(new TransmittalOutputTypeOption(TransmittalOutputType.APFeed, 'AP Feed'));\r\n }\r\n\r\n if(parseInt(outputType.toString()) === TransmittalOutputType.BillPay) {\r\n this.outputTypeOptions.push(new TransmittalOutputTypeOption(TransmittalOutputType.BillPay, 'Bill Pay'));\r\n }\r\n }\r\n\r\n /* The save function used to work by setting the modal's loading flag while processing, but for WK-4736 we determined that\r\n * we don't want the modal to be dismissable while processing. As a more robust solution the loading indicator was moved to the\r\n * parent page, however that now means the code is in a bit of a strange ordering. If this becomes a maintanence headache, we\r\n * should consider moving all the code that deals with finalizing into payment-packages.component and altering\r\n * payment-packages-finalize.modal so that the show function returns a promise.\r\n */\r\n save(): void {\r\n this.finalizeHasErrors = false;\r\n this.cancelExecutionLoop = false;\r\n this.finalizePaymentPackageModal.hide();\r\n\r\n this.originalSelectedPackages = _.cloneDeep(this.selectedPackages);\r\n this.selectedPackages = _.map(this.selectedPackages, (packageItem: PaymentPackage) => {\r\n packageItem.transmittalOutputType = this.selectedOutputType;\r\n return packageItem;\r\n });\r\n\r\n // TODO: Re-arrange logic so this doesn't have to be duplicated between the finalize modal and the main component\r\n const successMessage = 'Payment package(s) finalized.';\r\n const warningMessaage = 'One or more payment packages could not be processed. Please try again.';\r\n\r\n if (this.isFromPaymentBatch) {\r\n const busyRef = this.busyIndicatorService.show({ message: 'Finalizing package ...' });\r\n\r\n this.paymentBatchService.finalizeTransmittalPackage(this.paymentBatchId, this.taskId, this.originalSelectedPackages).then(() => {\r\n this.setParentLoading(false, null);\r\n this.toastr.success(successMessage);\r\n this.upgradeNavigationServiceHandler.transitionTo('paymentBatchDetailsWithTabIndex', {paymentBatchId: this.paymentBatchId, tabIndex: 1});\r\n }).catch(() => {\r\n this.finalizeHasErrors = true;\r\n this.toastr.warning(warningMessaage);\r\n }).finally(() => {\r\n busyRef.hide();\r\n });\r\n }\r\n else {\r\n this.transmitPackages().then(() => {\r\n this.setParentLoading(false, null);\r\n\r\n if(this.finalizeHasErrors) {\r\n this.toastr.warning(warningMessaage);\r\n } else {\r\n this.toastr.success(successMessage);\r\n }\r\n\r\n this.hasPackageFinalized.emit(true);\r\n }).catch(() => {\r\n //restore original packages since they weren't changed, but we altered them for transmittal\r\n this.selectedPackages = _.cloneDeep(this.originalSelectedPackages);\r\n this.setParentLoading(false, null);\r\n });\r\n }\r\n }\r\n\r\n transmitPackages(): Promise {\r\n const itemCount = this.selectedPackages.flatMap(pp => pp.paymentTransmittals).flatMap(pt => pt.paymentTransmittalItems).length;\r\n const threshold = this.featureFlagsService.featureFlags.paymentPackageFinalizeLongRunningThreshold;\r\n\r\n // A 0 or negative threshold means LR processing is disabled. Otherwise check if the count is over or equal to the threshold.\r\n if (threshold > 0 && itemCount >= threshold) {\r\n return this.transmitPackagesLR();\r\n }\r\n\r\n // Not using LR process. Note that technically the finalize API endpoint can handle multiple packages at once, but this loops\r\n // through them one at a time to prevent any one API call from getting too long.\r\n const vm = this;\r\n\r\n return new Promise((resolve) => {\r\n const paymentPackagesToFinalize = _.cloneDeep(this.selectedPackages);\r\n\r\n const executionLoop = function () {\r\n if (paymentPackagesToFinalize.length > 0 && vm.cancelExecutionLoop === false) {\r\n const nextPackage: PaymentPackage = paymentPackagesToFinalize.shift();\r\n\r\n vm.setParentLoading(true, `Finalizing Draft #${ nextPackage.packageNumber }...`, paymentPackagesToFinalize.length === 0);\r\n\r\n vm.transmitPackage(nextPackage).then(function () {\r\n executionLoop();\r\n }).catch(() => {\r\n vm.finalizeHasErrors = true;\r\n executionLoop();\r\n });\r\n }\r\n else {\r\n resolve();\r\n }\r\n };\r\n\r\n executionLoop();\r\n });\r\n }\r\n\r\n transmitPackagesLR(): Promise {\r\n return new Promise(async resolve => {\r\n this.setParentLoading(true, 'Sending transmittal request...', true);\r\n\r\n const lrId = await this.transmittalService.FinalizePaymentPackagesLR({\r\n originalRequestRoute: window.location.hash,\r\n // TODO: Sort out models\r\n // Payment package functionality predates TypeLite integration, so none of the original code uses the exported types and instead\r\n // uses custom-built types. The LR finalize process is newer and uses a TypeLite model for the request, but it's incompatible\r\n // with the existing type. For now, just cast the existing type as \"any\" so it compiles, but eventually we need to upgrade all\r\n // the transmittal-related models to TypeLite models and adjust the UI accordingly.\r\n paymentPackages: this.selectedPackages\r\n });\r\n\r\n this.subscribeLR(lrId, this.selectedPackages.length > 1, resolve);\r\n });\r\n }\r\n\r\n subscribeLR(lrId: number, isPlural: boolean, callback: () => unknown) {\r\n this.setParentLoading(true, `Finalizing selected draft${isPlural ? 's' : ''}...`, true);\r\n\r\n this.statusChangeSubscription && this.statusChangeSubscription.unsubscribe();\r\n this.statusChangeSubscription = this.websocketListenerService.longRunningProcessStatusChange$.subscribe(async status => {\r\n if (status.longRunningProcessId === lrId && status.isCompleted) {\r\n const lrProcess = await lastValueFrom(this.longRunningProcessRepository.get(lrId));\r\n if (lrProcess.error) {\r\n this.finalizeHasErrors = true;\r\n // If there are multiple packages there may have been a partial success; go check before finishing\r\n if (isPlural) {\r\n const finalizeResults = await this.transmittalService.GetLRFinalizeResults(lrId);\r\n if (finalizeResults.length > 0) {\r\n console.log('Partial success detected', finalizeResults);\r\n this.processTransmitResult(finalizeResults);\r\n }\r\n }\r\n }\r\n else {\r\n const lrResultObject = JSON.parse(lrProcess.result);\r\n\r\n // Replicate what would have been done if this had been a conventional API return (see DateConvertInterceptor)\r\n this.utilities.convertDateStringsToDates(lrResultObject);\r\n\r\n this.processTransmitResult(lrResultObject.result);\r\n }\r\n this.statusChangeSubscription.unsubscribe();\r\n this.statusChangeSubscription = null;\r\n callback();\r\n }\r\n });\r\n }\r\n\r\n processTransmitResult(result: PaymentPackage[]): void {\r\n if(parseInt(this.selectedOutputType.toString()) === TransmittalOutputType.PaperTransmittal) {\r\n this.downloadAttachments(result);\r\n }\r\n\r\n //Old way of mapping the response to the bound items. This is necessary for now because it returns an array\r\n //but the logic is much simpler in theory\r\n _.map(this.packageList, (packageItem: PaymentPackage) => {\r\n\r\n const newPackage: PaymentPackage = _.find(result, { paymentPackageID: packageItem.paymentPackageID });\r\n\r\n if(newPackage) {\r\n //todo map items\r\n packageItem.completedDateTime = newPackage.completedDateTime;\r\n packageItem.completedByUserID = newPackage.completedByUserID;\r\n packageItem.packageNumber = newPackage.packageNumber;\r\n packageItem.emailText = newPackage.emailText;\r\n packageItem.emailSubject = newPackage.emailSubject;\r\n packageItem.attachments = newPackage.attachments;\r\n packageItem.apFeedAttachments = newPackage.apFeedAttachments;\r\n }\r\n\r\n packageItem.isSelected = false;\r\n packageItem.isFinalized = true;\r\n\r\n return packageItem;\r\n });\r\n }\r\n\r\n // Function to save a specific package and set up and map the return object so the actual package items are preserved.\r\n // Part of this is so we don't have to refetch the entire package list to get the new data as that's a heavy call\r\n transmitPackage(packageToFinalize: PaymentPackage): Promise {\r\n return this.transmittalService.FinalizePaymentPackages([packageToFinalize]).then(result => {\r\n this.processTransmitResult(result);\r\n });\r\n }\r\n\r\n downloadAttachments(packageList: PaymentPackage[]): void {\r\n _.forEach(packageList, (packageItem: PaymentPackage) => {\r\n const attachmentInfo: AttachmentInfo = {\r\n attachmentID: null,\r\n entityTypeID: 19,\r\n entityID: packageItem.paymentPackageID,\r\n fileName: null,\r\n fileExtension: null,\r\n size: null\r\n };\r\n\r\n if (packageItem.attachments) {\r\n attachmentInfo.attachmentID = packageItem.attachments[0].attachmentID;\r\n attachmentInfo.fileName = packageItem.attachments[0].fileName;\r\n attachmentInfo.fileExtension = packageItem.attachments[0].fileExtension;\r\n attachmentInfo.size = packageItem.attachments[0].size;\r\n }\r\n\r\n this.attachmentService.downloadAttachmentFile(attachmentInfo, true).then();\r\n });\r\n }\r\n\r\n selectedOutputChanged(event) {\r\n\r\n switch(Number(event)){\r\n case TransmittalOutputType.PaperTransmittal:\r\n this.addButtonLabel = TransmittalOutputTypeButtonLabel.PaperTransmittal;\r\n break;\r\n case TransmittalOutputType.DigitalTransmittal:\r\n this.addButtonLabel = TransmittalOutputTypeButtonLabel.DigitalTransmittal;\r\n break;\r\n case TransmittalOutputType.APFeed:\r\n this.addButtonLabel = TransmittalOutputTypeButtonLabel.APFeed;\r\n break;\r\n case TransmittalOutputType.BillPay:\r\n this.addButtonLabel = TransmittalOutputTypeButtonLabel.BillPay;\r\n break;\r\n default:\r\n this.addButtonLabel = 'Add';\r\n break;\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
    \r\n
  1. \r\n {{companyName}}\r\n
  2. \r\n
\r\n
\r\n
\r\n
\r\n

Bill Payment Packages

\r\n
\r\n
\r\n
\r\n \r\n \r\n Finalizing...\r\n {{ finalizeLoadingMessage }}\r\n
\r\n (Cancel)\r\n Cancelling Remaining Packages...\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n to\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n 0 && selectedCount < paymentPackages.length\"\r\n [checked]=\"selectedCount === paymentPackages.length\"\r\n (click)=\"toggleSelectAll()\" [disabled]=\"isDisabled\"/>\r\n Package #SentResponsible PartyCc/Bcc\r\n \r\n \r\n \r\n \r\n \r\n
TransmittalsPayment Count
\r\n
Special InstructionsRecall?
\r\n \r\n \r\n {{ package.transmittalType }} Draft {{ package.packageNumber }}\r\n \r\n \r\n \r\n \r\n {{ package.transmittalType }} - {{ package.packageNumber }}\r\n \r\n \r\n \r\n \r\n Draft\r\n \r\n \r\n \r\n {{ package.completedDateTime | weissmanDateFormat }}\r\n \r\n \r\n
\r\n \r\n {{ recipient.fullName }}\r\n \r\n
\r\n
\r\n
N/A
\r\n
\r\n \r\n
0\">\r\n
\r\n
\r\n
\r\n CC: \r\n {{ recipient.fullName }}\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n BCC: \r\n {{ recipient.fullName }}\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n There are no other recipients\r\n
\r\n \r\n
\r\n
\r\n
\r\n
N/A
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n {{ package.companyName }}\r\n
\r\n \r\n {{ transmittal.collectorAddress.abbr }} - {{ transmittal.title }}\r\n \r\n \r\n \r\n \r\n {{ transmittal.paymentTransmittalItems.length }}\r\n
\r\n
\r\n
\r\n \r\n \r\n {{ package.specialInstructions }}\r\n \r\n
N/A
\r\n
\r\n \r\n (recalled)\r\n
\r\n
\r\n

No payment packages

\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n\r\n\r\n
\r\n {{hoveredRecipient.companyName}}\r\n
{{hoveredRecipient.fullName}}\r\n
{{hoveredRecipient.title}}\r\n
\r\n {{hoveredRecipient.address.address1}}\r\n
{{hoveredRecipient.address.address2}}\r\n
{{hoveredRecipient.address.city}}, {{hoveredRecipient.address.abbr}} {{hoveredRecipient.address.zip}}\r\n
\r\n
\r\n
\r\n\r\n","import { Component, Input, OnChanges, OnInit, SimpleChanges, ViewChild } from '@angular/core';\r\nimport { TransmittalService } from './transmittal.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport {\r\n PaymentPackage, PaymentPackageRecipient, PaymentTransmittal, PaymentTransmittalItem,\r\n RecipientType\r\n} from './transmittal.models';\r\nimport { WeissmanDatetimeComponent } from '../../UI-Lib/Weiss-Datepicker/weissman-datetime.component';\r\nimport { MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { Constants, EntityTypeIds } from '../../constants.new';\r\nimport { FinalizePaymentPackageModalComponent } from './Modals/payment-packages-finalize.modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { CompanyService } from '../../Entity/Company/company.service';\r\nimport {\r\n ContactListModalComponent,\r\n ContactListModalParams\r\n} from '../../Contact/Panel/List/Associate-Contact/contactListModal.component';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'payment-packages',\r\n templateUrl: './payment-packages.component.html'\r\n})\r\nexport class PaymentPackagesComponent implements OnInit, OnChanges {\r\n constructor(private transmittalService: TransmittalService,\r\n public upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private constants: Constants,\r\n private messageBox: MessageBoxService,\r\n private companyService: CompanyService,\r\n private toastr: ToastrService,\r\n private readonly _weissmanModalService: WeissmanModalService,\r\n private readonly _transmittalService: TransmittalService) {\r\n }\r\n\r\n @Input() paymentID: number;\r\n @Input() readOnly: boolean = true;\r\n @Input() isModal: boolean = false;\r\n @ViewChild('FinalizePaymentPackageModal', { static: true }) finalizePaymentPackagesModal: FinalizePaymentPackageModalComponent;\r\n\r\n selectedTransmittalID: number = null;\r\n selectedPackage: PaymentPackage = undefined;\r\n paymentPackages: PaymentPackage[];\r\n showSaveButton: boolean = false;\r\n selectedCount: number = 0;\r\n draftIDs: number[];\r\n draftIDParam: string;\r\n companyID: string;\r\n startDate: Date;\r\n endDate: Date;\r\n state: any;\r\n loading: boolean = false;\r\n finalizing: boolean = false;\r\n hoveredRecipient: PaymentPackageRecipient;\r\n showDates: boolean = true;\r\n setFinalizeLoading: (loading: boolean, message: string, hideCancelHyperlink?: boolean) => void;\r\n finalizeLoadingMessage: string = null;\r\n processingCancelled: boolean = false;\r\n hideCancelHyperlink: boolean = false;\r\n companyName: string;\r\n paymentBatchId: number;\r\n taskId: number;\r\n isPrelimApFeed: boolean;\r\n isDisabled: boolean = false;\r\n returnButtonText: string;\r\n saveButtonText: string ='Finalize and Release Selected Transmittals';\r\n\r\n //This is to get the enum usable in the view for an if condition\r\n RecipientType = RecipientType;\r\n\r\n ngOnChanges(changes: SimpleChanges) {\r\n if (Object.keys(changes).indexOf('paymentID') >= 0) {\r\n this.refreshList();\r\n }\r\n }\r\n\r\n async ngOnInit() {\r\n this.startDate = WeissmanDatetimeComponent.getMidnight(new Date(), false, 'Central');\r\n this.endDate = WeissmanDatetimeComponent.getMidnight(new Date(), true, 'Central');\r\n this.state = this.upgradeNavigationServiceHandler.getCurrentState();\r\n if (this.upgradeNavigationServiceHandler.getQuerystringParam('paymentBatchId')) {\r\n this.paymentBatchId = JSON.parse(this.upgradeNavigationServiceHandler.getQuerystringParam('paymentBatchId'));\r\n }\r\n if (this.upgradeNavigationServiceHandler.getQuerystringParam('taskId')) {\r\n this.taskId = JSON.parse(this.upgradeNavigationServiceHandler.getQuerystringParam('taskId'));\r\n }\r\n this.isPrelimApFeed = !!this.upgradeNavigationServiceHandler.getQuerystringParam('isPrelimApFeed');\r\n\r\n if (this.isFromPaymentBatch) {\r\n this.returnButtonText= 'Return to Payment Batch';\r\n if(this.isPrelimApFeed) {\r\n this.saveButtonText = 'Release all Preliminary Transmittals';\r\n }\r\n }\r\n else{\r\n this.returnButtonText= 'Return to Action View';\r\n }\r\n\r\n this.setFinalizeLoading = (loading: boolean, message: string, hideCancelHyperlink?: boolean) => {\r\n this.finalizeLoadingMessage = message;\r\n this.finalizing = loading;\r\n this.hideCancelHyperlink = hideCancelHyperlink;\r\n\r\n if (!loading) {\r\n this.processingCancelled = false;\r\n }\r\n };\r\n\r\n if (this.state.name === 'paymentPackagesDraft') {\r\n this.readOnly = false;\r\n await this.getPaymentPackagesByDraftID();\r\n } else if (this.state.name === 'paymentPackagesForCompany') {\r\n this.readOnly = true;\r\n this.getPaymentPackagesByCompanyID();\r\n } else if (this.state.name === 'paymentPackageDetail') {\r\n this.readOnly = true;\r\n this.showDates = false;\r\n this.companyID = this.upgradeNavigationServiceHandler.getQuerystringParam('companyID');\r\n const paymentPackageID = Number(this.upgradeNavigationServiceHandler.getQuerystringParam('paymentPackageID'));\r\n this.getPaymentPackageDetails(paymentPackageID);\r\n } else {\r\n if (this.paymentID) {\r\n this.getPaymentPackagesByPaymentID();\r\n }\r\n }\r\n\r\n }\r\n\r\n get isFromPaymentBatch() {\r\n return !!this.paymentBatchId;\r\n }\r\n\r\n get shouldShowSelectAll() {\r\n return _.some(this.paymentPackages, x => !x.completedDateTime)\r\n }\r\n\r\n closeChildModals(): void {\r\n this.finalizePaymentPackagesModal.close();\r\n }\r\n\r\n async getPaymentPackageDetails(paymentPackageID: number): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n const result = await this.transmittalService.GetPaymentPackageByID(paymentPackageID);\r\n this.paymentPackages = [result];\r\n this.preparePaymentPackages();\r\n\r\n if (result.paymentTransmittals.length > 0) {\r\n this.showDetails(result.paymentTransmittals[0], result);\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async getPaymentPackagesByCompanyID(): Promise {\r\n this.companyID = this.upgradeNavigationServiceHandler.getQuerystringParam('companyID');\r\n if (this.companyID) {\r\n this.loading = true;\r\n\r\n try {\r\n this.paymentPackages = await this.transmittalService.GetPaymentPackagesByCompanyID(this.companyID, this.startDate, this.endDate);\r\n this.preparePaymentPackages();\r\n\r\n this.companyName = await this.companyService.getCompanyName(Number(this.companyID));\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n\r\n async getPaymentPackagesByPaymentID(): Promise {\r\n if (this.paymentID) {\r\n this.loading = true;\r\n\r\n try {\r\n this.paymentPackages = await this.transmittalService.GetPaymentPackagesByPaymentID(this.paymentID);\r\n this.preparePaymentPackages();\r\n let newTransmittalID: number;\r\n let selectedPackage: PaymentPackage;\r\n //1. search paymentTransmittals\r\n //1a. Find paymentID inside of paymentTransmittalItems\r\n //2. Set selectedTransmittalID to that transmittalID\r\n\r\n _.forEach(this.paymentPackages, (packageItem: PaymentPackage) => {\r\n _.forEach(packageItem.paymentTransmittals, (paymentTransmittal: PaymentTransmittal) => {\r\n _.forEach(paymentTransmittal.paymentTransmittalItems, (transmittalItem: PaymentTransmittalItem) => {\r\n if (transmittalItem.paymentID === this.paymentID) {\r\n newTransmittalID = paymentTransmittal.paymentTransmittalID;\r\n selectedPackage = packageItem;\r\n\r\n }\r\n });\r\n });\r\n });\r\n\r\n if (newTransmittalID && selectedPackage) {\r\n this.selectedTransmittalID = newTransmittalID;\r\n this.selectedPackage = selectedPackage;\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n\r\n async getPaymentPackagesByDraftID(): Promise {\r\n // TODO: Re-arrange logic so this doesn't have to be duplicated between the finalize modal and the main component\r\n const successMessage = 'Payment package(s) finalized.';\r\n const warningMessaage = 'One or more payment packages could not be processed. Please try again.';\r\n\r\n this.draftIDParam = this.upgradeNavigationServiceHandler.getQuerystringParam('draftID');\r\n if (this.draftIDParam) {\r\n const serializedDraftIDs: string = sessionStorage[`PaymentPackageDrafts${this.draftIDParam}`];\r\n if (serializedDraftIDs) {\r\n this.draftIDs = JSON.parse(serializedDraftIDs);\r\n const packages = await this.transmittalService.GetPaymentPackages(this.draftIDs);\r\n\r\n this.paymentPackages = packages;\r\n this.preparePaymentPackages();\r\n this.loading = false;\r\n if(this.isFromPaymentBatch) {\r\n this.toggleSelectAll();\r\n this.isDisabled = true;\r\n }\r\n\r\n // Some payment packages might have a long-running process still going, which affects how the page loads. First find packages\r\n // that ever had an LR request.\r\n const packagesWithRequests = packages.filter(p => p.paymentPackageFinalizeRequestId);\r\n\r\n // If there are any, check with the API if the LR processes are still active.\r\n if (packagesWithRequests.length > 0) {\r\n const packageIdsWithRequests = packagesWithRequests.map(p => p.paymentPackageID);\r\n const checkResult = await this.transmittalService.CheckFinalizeLongRunningProcess(packageIdsWithRequests);\r\n\r\n if (checkResult.length > 0) {\r\n this.loading = true;\r\n\r\n const alreadyProcessedLrIds = [];\r\n\r\n for (let i = 0; i < checkResult.length; i++) {\r\n const { longRunningProcessId } = checkResult[i];\r\n if (alreadyProcessedLrIds.indexOf(longRunningProcessId) < 0) {\r\n alreadyProcessedLrIds.push(longRunningProcessId);\r\n const packageIds = checkResult\r\n .filter(r => r.longRunningProcessId == longRunningProcessId)\r\n .map(r => r.paymentPackageId);\r\n\r\n for (let paymentPackageIndex = 0; paymentPackageIndex < this.paymentPackages.length; paymentPackageIndex++) {\r\n const packageItem = this.paymentPackages[paymentPackageIndex];\r\n packageItem.isSelected = packageIds.indexOf(packageItem.paymentPackageID) >= 0;\r\n }\r\n\r\n // HACK: As noted in the modal code, the responsibility for showing loading indicators has moved several times, so\r\n // we've got a few layers of fix here. Ideally we should untangle this responsibility and put all loading logic\r\n // in PaymentPackagesComponent and make FinalizePaymentPackagesModal a simple modal to retrieve user input. Until\r\n // that's fixed, set up the modal so that subscribeLR will work.\r\n this.finalizePaymentPackagesModal.setupModal(false);\r\n\r\n const plural = packageIds.length > 1;\r\n await new Promise(r => this.finalizePaymentPackagesModal.subscribeLR(longRunningProcessId, plural, r));\r\n }\r\n }\r\n\r\n this.loading = false;\r\n this.setFinalizeLoading(false, null);\r\n\r\n if(this.finalizePaymentPackagesModal.finalizeHasErrors) {\r\n this.toastr.warning(warningMessaage);\r\n } else {\r\n this.toastr.success(successMessage);\r\n }\r\n\r\n this.packageFinalized();\r\n }\r\n }\r\n } else {\r\n // TODO: Handle this case somehow (we got a draft ID string, but sessionStorage didn't have it)\r\n }\r\n }\r\n\r\n }\r\n\r\n preparePaymentPackages(): void {\r\n this.paymentPackages = _.chain(this.paymentPackages)\r\n .map((packageItem: PaymentPackage) => {\r\n packageItem.transmittalType = this.constants.TransmittalOutputTypeAbbr[packageItem.transmittalOutputType];\r\n packageItem.isSelected = false;\r\n\r\n return packageItem;\r\n })\r\n .sortBy((packageItem: PaymentPackage) => {\r\n return _.parseInt(packageItem.packageNumber);\r\n })\r\n .value();\r\n }\r\n\r\n async openContactModal(event: any, packageItem: PaymentPackage): Promise {\r\n const params = {\r\n recipientMode: true,\r\n entityInfo: {\r\n id: packageItem.paymentPackageID,\r\n type: EntityTypeIds.PAYMENTPACKAGE\r\n }\r\n } as ContactListModalParams;\r\n\r\n const recipientObject = await this._weissmanModalService.showAsync(ContactListModalComponent, params, 'modal-lg');\r\n\r\n if (recipientObject) {\r\n _.forEach(recipientObject.recipients, (recipient: any) => {\r\n if (!recipient.email) {\r\n this.toastr.error(`Contact ${recipient.firstName} ${recipient.lastName} is missing email address!`, 'Missing email address');\r\n return;\r\n }\r\n\r\n let companyName: string = '';\r\n if (recipient.companyName) {\r\n companyName = recipientObject.companyName;\r\n } else if (recipient.entityName) {\r\n companyName = recipient.entityName;\r\n }\r\n\r\n const tempRecipient: PaymentPackageRecipient = new PaymentPackageRecipient(recipientObject.recipientType,\r\n recipient.contactID,\r\n `${recipient.firstName} ${recipient.lastName}`,\r\n recipient.title,\r\n recipient.address,\r\n recipient.email,\r\n companyName);\r\n\r\n packageItem.paymentPackageRecipients.push(tempRecipient);\r\n });\r\n }\r\n }\r\n\r\n openReviewModal(event: any, packageItem: PaymentPackage): void {\r\n this._transmittalService.showPaymentPackageReviewModal(packageItem);\r\n }\r\n\r\n selectRow(event: any, packageItem: PaymentPackage): void {\r\n if (!this.isFromPaymentBatch && !packageItem.completedDateTime && !/no-bubble/.test(event.target.className)) {\r\n packageItem.isSelected = !packageItem.isSelected;\r\n this.selectedCount = _.filter(this.paymentPackages, item => item.isSelected).length;\r\n\r\n this.showSaveButton = this.selectedCount !== 0;\r\n }\r\n }\r\n\r\n removeRecipient(event: any, recipient: PaymentPackageRecipient, packageItem: PaymentPackage): void {\r\n packageItem.paymentPackageRecipients = _.reject(packageItem.paymentPackageRecipients, (recipientItem: PaymentPackageRecipient) => {\r\n return recipientItem.contactID === recipient.contactID;\r\n });\r\n }\r\n\r\n removeTransmittal(event: any, packageItem: PaymentPackage, transmittalIndex: number): void {\r\n if (packageItem.paymentTransmittals.length === 1) {\r\n this.paymentPackages = _.reject(this.paymentPackages, (item: PaymentPackage) => {\r\n return item.paymentPackageID === packageItem.paymentPackageID;\r\n });\r\n } else {\r\n packageItem.paymentTransmittals.splice(transmittalIndex, 1);\r\n }\r\n }\r\n\r\n getRecipientCount(recipientList: PaymentPackageRecipient[]): number {\r\n return _.filter(recipientList, recipient =>\r\n recipient.recipientType === RecipientType.Bcc || recipient.recipientType === RecipientType.Cc\r\n ).length;\r\n }\r\n\r\n getCompletePackageCount(): number {\r\n let count: number = 0;\r\n\r\n count = _.filter(this.paymentPackages, packageItem => !!packageItem.completedDateTime).length;\r\n\r\n return count;\r\n }\r\n\r\n setHoveredRecipient(recipient: PaymentPackageRecipient): void {\r\n this.hoveredRecipient = recipient;\r\n }\r\n\r\n navigateToActionView(): void {\r\n sessionStorage.removeItem(`PaymentPackageDrafts${this.draftIDParam}`);\r\n if (this.isFromPaymentBatch) {\r\n this.upgradeNavigationServiceHandler.transitionTo('paymentBatchDetails', {paymentBatchId: this.paymentBatchId});}\r\n else{\r\n this.upgradeNavigationServiceHandler.transitionTo('actionview', {});\r\n }\r\n }\r\n\r\n cancelPackages(): void {\r\n if (this.draftIDs.length != 0) {\r\n this.messageBox.confirm('Are you sure you want to cancel?').then(() => {\r\n this.transmittalService.CancelPaymentPackages(this.draftIDs).then(() => {\r\n this.navigateToActionView();\r\n });\r\n });\r\n } else {\r\n this.navigateToActionView();\r\n }\r\n }\r\n\r\n returnToActionView(): void {\r\n //this.upgradeNavigationServiceHandler.transitionTo('actionview', {});\r\n if (this.isFromPaymentBatch) {\r\n this.upgradeNavigationServiceHandler.transitionTo('paymentBatchDetails', {paymentBatchId: this.paymentBatchId});}\r\n else{\r\n this.upgradeNavigationServiceHandler.transitionTo('actionview', {});\r\n }\r\n }\r\n\r\n finalizePackages(): void {\r\n this.finalizePaymentPackagesModal.show();\r\n }\r\n\r\n goToDetails(event: any, selectedTransmittal: PaymentTransmittal, selectedPackage: PaymentPackage): void {\r\n this.showDetails(selectedTransmittal, selectedPackage);\r\n }\r\n\r\n showDetails(selectedTransmittal: PaymentTransmittal, selectedPackage: PaymentPackage): void {\r\n this.selectedTransmittalID = selectedTransmittal.paymentTransmittalID;\r\n this.selectedPackage = selectedPackage;\r\n }\r\n\r\n refreshList(): void {\r\n this.selectedPackage = null;\r\n this.selectedTransmittalID = null;\r\n\r\n if (this.state && this.state.name === 'paymentPackagesForCompany') {\r\n this.getPaymentPackagesByCompanyID();\r\n } else if (this.paymentID) {\r\n this.getPaymentPackagesByPaymentID();\r\n }\r\n }\r\n\r\n toggleSelectAll(): void {\r\n const updateValue = this.selectedCount !== this.paymentPackages.length;\r\n\r\n this.paymentPackages = _.map(this.paymentPackages, (paymentItem: PaymentPackage) => {\r\n paymentItem.isSelected = updateValue && !paymentItem.completedDateTime;\r\n return paymentItem;\r\n });\r\n\r\n this.selectedCount = _.filter(this.paymentPackages, item => item.isSelected).length;\r\n this.showSaveButton = this.selectedCount !== 0;\r\n }\r\n\r\n recallPackage(packageItem: PaymentPackage): void {\r\n this.messageBox.confirm(`Are you sure you want to recall package #${packageItem.packageNumber}?`).then(() => {\r\n this.loading = true;\r\n this.transmittalService.RecallPaymentPackage(packageItem).then(() => {\r\n // Remove the recalled package from the list, set it's \"isRecalled\" flag, and add it back to the end\r\n const removedPackages: PaymentPackage[] = _.remove(this.paymentPackages, {\r\n paymentPackageID: packageItem.paymentPackageID\r\n });\r\n\r\n removedPackages.forEach((paymentPackage) => {\r\n paymentPackage.isRecalled = true;\r\n this.paymentPackages.push(paymentPackage);\r\n });\r\n\r\n this.paymentPackages = _.sortBy(this.paymentPackages, (x: PaymentPackage) => {\r\n return _.parseInt(x.packageNumber);\r\n });\r\n\r\n this.loading = false;\r\n }).catch((result) => {\r\n if (result.status === 400) {\r\n this.toastr.error(result.data);\r\n }\r\n this.loading = false;\r\n });\r\n });\r\n }\r\n\r\n packageFinalized() {\r\n this.selectedCount = _.filter(this.paymentPackages, item => item.isSelected).length;\r\n this.showSaveButton = this.selectedCount !== 0;\r\n\r\n const finalizedPackages: PaymentPackage[] = _.filter(this.paymentPackages, { isFinalized: true });\r\n\r\n _.forEach(finalizedPackages, (item: PaymentPackage) => {\r\n _.remove(this.draftIDs, (draftId: number) => {\r\n return draftId === item.paymentPackageID;\r\n });\r\n });\r\n }\r\n\r\n unlockPackage(event: any, packageItem: PaymentPackage) {\r\n this.messageBox.confirm('Unlocking this package will undo your changes to the package email. Are you sure?').then(() => {\r\n packageItem.emailSubjectTemplate = packageItem.originalEmailSubjectTemplate;\r\n packageItem.emailTemplate = packageItem.originalEmailTextTemplate;\r\n packageItem.lockedForOverrideEmail = false;\r\n });\r\n }\r\n\r\n navigateToCompany(): void {\r\n this.upgradeNavigationServiceHandler.go('company', { companyId: this.companyID });\r\n }\r\n\r\n backClicked() {\r\n if(this.isFromPaymentBatch) {\r\n this.upgradeNavigationServiceHandler.transitionTo('paymentBatchDetails', {paymentBatchId: this.paymentBatchId});\r\n } else {\r\n this.selectedTransmittalID = null;\r\n }\r\n }\r\n}\r\n","
\r\n\t
\r\n\t\t

Payment Package Downloads

\r\n
\r\n \r\n
\r\n
\r\n
\r\n

Package Name: {{summary.packageName}}

\r\n

\r\n Go to package details\r\n

\r\n

Attachments

\r\n
\r\n {{attachment.fileName}}.{{attachment.fileExtension}}\r\n
\r\n
\r\n
\r\n
\r\n
","import { Component, OnInit } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { TransmittalService } from './transmittal.service';\r\nimport { AttachmentInfo } from '../../Attachment/attachment.model';\r\nimport { PaymentPackageAttachmentSummary } from './transmittal.models';\r\nimport { AttachmentService } from 'src/app/Attachment/attachment.service';\r\n\r\n// Note that at this moment you can't navigate to this page via the main interface; links to the payment\r\n// package attachment summary page are sent in emails. The URL for this page is:\r\n// /processing/paymentPackages/attachmentSummary/:paymentPackageID\r\n@Component({\r\n selector: 'payment-package-attachment-summary',\r\n templateUrl: './payment-package-attachment-summary.component.html'\r\n})\r\nexport class PaymentPackageAttachmentSummaryComponent implements OnInit {\r\n constructor(\r\n private upgradeNavigationService: UpgradeNavigationServiceHandler,\r\n private transmittalService: TransmittalService,\r\n private attachmentService: AttachmentService\r\n ) {\r\n }\r\n\r\n summary: PaymentPackageAttachmentSummary;\r\n downloading: boolean;\r\n\r\n ngOnInit() {\r\n const paymentPackageID = Number(this.upgradeNavigationService.getQuerystringParam('paymentPackageID'));\r\n this.transmittalService.GetPaymentPackageAttachmentSummary(paymentPackageID).then(summary => {\r\n this.summary = summary;\r\n });\r\n }\r\n\r\n goToPackage(summary: PaymentPackageAttachmentSummary): void {\r\n this.upgradeNavigationService.go('paymentPackageDetail', {\r\n companyID: summary.companyID,\r\n paymentPackageID: summary.paymentPackageID\r\n });\r\n }\r\n\r\n async downloadAttachment(attachment: AttachmentInfo) {\r\n this.downloading = true;\r\n try {\r\n await this.attachmentService.downloadAttachmentFile(attachment, false);\r\n } finally {\r\n this.downloading = false;\r\n }\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { QuillModule } from 'ngx-quill';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { PaymentPackagesComponent } from './payment-packages.component';\r\nimport { TransmittalDetailsComponent } from './transmittal-details.component';\r\nimport { FinalizePaymentPackageModalComponent } from './Modals/payment-packages-finalize.modal';\r\nimport { ReviewPaymentPackageModalComponent } from './Modals/payment-packages-review.modal';\r\nimport { PaymentPackageAttachmentSummaryComponent } from './payment-package-attachment-summary.component';\r\nimport { TransmittalService } from './transmittal.service';\r\nimport { RecipientTypePipe } from './transmittal.pipes';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n WeissmanSharedModule,\r\n QuillModule,\r\n BusyIndicatorModule\r\n ],\r\n declarations: [\r\n PaymentPackagesComponent,\r\n TransmittalDetailsComponent,\r\n FinalizePaymentPackageModalComponent,\r\n ReviewPaymentPackageModalComponent,\r\n PaymentPackageAttachmentSummaryComponent,\r\n RecipientTypePipe\r\n ],\r\n providers: [\r\n TransmittalService\r\n ],\r\n exports: [\r\n PaymentPackagesComponent,\r\n PaymentPackageAttachmentSummaryComponent,\r\n ReviewPaymentPackageModalComponent\r\n ]\r\n})\r\nexport class TransmittalModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('paymentPackages', PaymentPackagesComponent);\r\n hybridAdapterUtility.downgradeNg2Component('paymentPackageAttachmentSummary', PaymentPackageAttachmentSummaryComponent);\r\n }\r\n}\r\n","import { State } from '../../Common/States/state.model';\r\n\r\ndeclare const _: any;\r\n\r\nexport class Appeal {\r\n annualAssessmentID: number;\r\n appealID: number;\r\n appealLevel: AppealLevel;\r\n appealLevelID: number;\r\n appealStatusID: number;\r\n outcomeAnnualAssessmentID: number;\r\n fileByDate: string;\r\n submitEvidenceDateTimeLocal: string;\r\n hearingDateTimeLocal: string;\r\n confirmHearingDate: string;\r\n informalHearingDateTimeLocal: string;\r\n savingsDate: string;\r\n anticipatedFMV: number;\r\n savings: number;\r\n savingsOverridden: boolean;\r\n caseNumber: string;\r\n filingReference: string;\r\n hearingLocation: string;\r\n hasComments: boolean;\r\n hasAttachments: boolean;\r\n rowVersion: any;\r\n additionalNotificationMessage: boolean;\r\n hasApplicationForm: boolean;\r\n canCreateApplicationForm: boolean;\r\n isFromAcquisition: boolean;\r\n isRyanLegalServices: boolean;\r\n}\r\n\r\n// Consider using Core.AppealLevelModel autogenerated from backend\r\n// Consider moving this to another file if it ends up referenced in many places or this file ends up very large\r\nexport class AppealLevel {\r\n abbr: string;\r\n appealLevelID: number;\r\n efAction: string;\r\n fullName: string;\r\n sequence: number;\r\n stateID: number;\r\n state: State;\r\n litigation: boolean;\r\n}\r\n\r\nexport class AppealStatus {\r\n constructor(\r\n public appealStatusID: number,\r\n public description: string,\r\n public isClosedStatus: boolean,\r\n public status: string,\r\n public sequence: number) { }\r\n\r\n static appealStatuses: AppealStatus[];\r\n static getByID(appealStatusID: number): AppealStatus {\r\n return _.find(AppealStatus.appealStatuses, (appealStatus) => {\r\n return appealStatus.appealStatusID === appealStatusID;\r\n });\r\n }\r\n}\r\n\r\nexport enum AppealStatusID {\r\n //ToBeFiled = 1,\r\n //Open = 2,\r\n //Board = 3,\r\n //Continued = 4,\r\n //Pending = 5,\r\n //Litigation = 6,\r\n\tNull = null,\r\n Withdrawn = 7,\r\n //STIP = 8, Removed by Grant request\r\n Closed = 9,\r\n AddInError = 10,\r\n Reduction = 11\r\n}\r\n\r\n// If this was C#, I'd use a static constructor for this. There is no such thing, so this works.\r\n// https://github.com/Microsoft/TypeScript/issues/265\r\n\r\nAppealStatus.appealStatuses = [\r\n //new AppealStatus(1, 'Identified for appeal but appeal application has yet to be filed.', false, 'To Be Filed', 1),\r\n //new AppealStatus(2, 'Default setting. Open appeal; waiting for hearing date to be assigned. Typically the status is Open until changed due to the progression of the hearing.', false, 'Open', 2),\r\n //new AppealStatus(3, 'If an appeal has transitioned to the Appeal Board and is waiting for further action, the appeal status should be changed to Board. ', false, 'Board', 3),\r\n //new AppealStatus(4, 'Continued or rescheduled appeal. Once the date and time are changed on an existing appeal, the status must be changed to �Continued�. Confirmation from the Appeals Board should be received before AtlasTax is updated with this status.', false, 'Continued', 4),\r\n //new AppealStatus(5, 'Waiting for hearing results or stipulated value confirmation from the Appeals Board.', false, 'Pending', 5),\r\n //new AppealStatus(6, 'This status is specially assigned to hearings that go into a �Litigation� process, and should relate to the notice received.', false, 'Litigation', 6),\r\n\tnew AppealStatus(null, '', true, '', null),\r\n new AppealStatus(7, 'Withdrawn appeal; no further action will be taken. A completion date MUST be entered.', true, 'Withdrawn', 7),\r\n //new AppealStatus(8, 'Stipulated Value; representing an agreement with the Assessor; was obtained and a reduction in value is confirmed. A completion date should be entered.', true, 'STIP', 8), Removed by Grant request\r\n new AppealStatus(9, 'If an appeal is Closed, possibly due to negotiations with the Assessor, but not withdrawn. A completion date MUST be entered.', true, 'Closed', 9),\r\n new AppealStatus(10, 'If an appeal has been added erroneously the status needs to be changed to �Added in Error�. A completion date must be entered.', true, 'Add-in-Error', 10),\r\n new AppealStatus(11, 'Reduction achieved resulting in savings.', true, 'Reduction', 11)\r\n];\r\n\r\n// (I generated this code from an API call in Weissman; if we change the statuses, the code can be regenerated using this JavaScript executed in a console from Weissman)\r\n/*\r\n(function () {\r\n \"use strict\";\r\n var authData = JSON.parse(sessionStorage[\"ngStorage-authorizationData\"])[\"token\"];\r\n $.ajax({\r\n type: \"GET\",\r\n cache: false,\r\n url: \"/api/appealstatus\",\r\n headers: {\r\n Authorization: \"Bearer \" + authData\r\n }\r\n }).done(function (result) {\r\n console.log(_.map(result, function (appealStatus) {\r\n return \"new AppealStatus(\" + [\r\n appealStatus.appealStatusID,\r\n \"'\" + appealStatus.description + \"'\",\r\n appealStatus.isClosedStatus,\r\n \"'\" + appealStatus.status + \"'\",\r\n appealStatus.sequence].join(\", \") + \"),\";\r\n }).join(\"\\n\"));\r\n });\r\n}());\r\n*/\r\n","import { CurrencyPipe, DecimalPipe } from '@angular/common';\r\nimport { Injectable } from '@angular/core';\r\nimport { MessageBoxButtons, MessageBoxResult, MessageBoxService } from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\nimport { AnnualDetailEditState } from './annual-details-navigation.service';\r\nimport {\r\n AnnualDetailAssessment,\r\n AnnualDetailComponent,\r\n AnnualDetailYear,\r\n AnnualGridYearsInfo\r\n} from './Annual-Year/annual-year.model';\r\nimport { Assessment } from './Assessments/assessment.model';\r\nimport { Decimal } from 'decimal.js';\r\nimport { TimerService } from '../UI-Lib/Utilities/timer.service';\r\n\r\nimport { map, flatten, uniqBy } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment';\r\nimport { FilingTypeSummary } from './Compliance/compliance.model';\r\nimport { AssessmentComponentTypeEnum } from '../constants.new';\r\n\r\n@Injectable()\r\nexport class AnnualDetailsService {\r\n\r\n constructor(private readonly _http: SDHttpService,\r\n private readonly _numberPipe: DecimalPipe,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _currencyPipe: CurrencyPipe,\r\n private readonly _timer: TimerService) {\r\n }\r\n\r\n getAnnualYears(parcelId: number, getAllYears: boolean): Promise{\r\n const config = {\r\n params: {\r\n parcelID: parcelId,\r\n getAllYears: getAllYears\r\n }\r\n };\r\n return this._http.get('/api/annualassessmentview/', config);\r\n }\r\n\r\n getAnnualYearByID(annualYearID: number): Promise {\r\n const url = `/api/AnnualYear/${ annualYearID}`;\r\n\r\n return this._http.get(url);\r\n }\r\n\r\n getComplianceDisplay(filingTypeId: number, yearSummaries: FilingTypeSummary[]) {\r\n const summary = _.find(yearSummaries, { filingTypeId: filingTypeId });\r\n\r\n if (!summary) {\r\n return '----';\r\n }\r\n\r\n if (summary.moreThanOneFilingOfThisType) {\r\n return 'Details';\r\n }\r\n\r\n if(!summary.filingHasTaskSeries) {\r\n return summary.value || summary.value === 0 ? `$${this._numberPipe.transform(summary.value, '1.0-0')}` : moment.utc(summary.dueDate).format('M/D/YYYY');\r\n }\r\n else{\r\n if (summary.allTasksCompleted) {\r\n return summary.value || summary.value === 0 ? `$${this._numberPipe.transform(summary.value, '1.0-0')}` : 'Filed';\r\n } else {\r\n return moment.utc(summary.dueDate).format('M/D/YYYY');\r\n }\r\n }\r\n }\r\n\r\n getComponentsFromYears(years: AnnualDetailYear[]): Array {\r\n return _.flow([\r\n map('annualGridDetails'),\r\n flatten,\r\n map('annualGridComponents'),\r\n flatten,\r\n uniqBy('assessmentClassComponentID'),\r\n ])(years);\r\n }\r\n\r\n getRevision(revisionId): Promise {\r\n const serviceUrl = '/api/annualassessment/';\r\n return this._http.get(serviceUrl + revisionId);\r\n }\r\n\r\n saveYear(year: AnnualDetailYear): Promise {\r\n return this._http.put('/api/annualassessmentview', _.omit(year, 'annualGridDetails'));\r\n }\r\n\r\n addYear(parcelId: number, year: number, calcProjected: boolean) {\r\n const data = {\r\n parcelID: parcelId,\r\n annualYear1: year,\r\n calcProjected: calcProjected\r\n };\r\n\r\n return this._http.post('/api/AnnualYear/', data);\r\n }\r\n\r\n orderRevisions(annualYearId: number, orderedAnnualAssessmentIDs: number[]): Promise {\r\n // project the array into a dictionary where the IDs are the keys and the order is the value\r\n const data = {};\r\n for (let i = 0; i < orderedAnnualAssessmentIDs.length; i++) {\r\n data[orderedAnnualAssessmentIDs[i]] = i;\r\n }\r\n return this._http.put(`/api/AnnualYear/${annualYearId}/AssessmentNumbers`, data);\r\n }\r\n\r\n formatYearDateDisplay(years: AnnualDetailYear[]): AnnualDetailYear[] {\r\n _.map(years, function (year) {\r\n year.collapsedAppealStatus = Date.parse(year.collapsedAppealStatus) ? moment.utc(year.collapsedAppealStatus).format('M/D/YYYY') : year.collapsedAppealStatus;\r\n\r\n year.annualGridDetails = _.map(year.annualGridDetails, function (revision) {\r\n revision.appealStatus = Date.parse(revision.appealStatus) ? moment.utc(revision.appealStatus).format('M/D/YYYY') : revision.appealStatus;\r\n return revision;\r\n });\r\n\r\n return year;\r\n });\r\n\r\n return years;\r\n }\r\n\r\n nonCapComponents(components: AnnualDetailComponent[], componentList: any, viewTaxableValues: boolean): AnnualDetailComponent[] {\r\n let nonCapComponents: AnnualDetailComponent[] = _.reject(components, (component) =>\r\n component.assessmentComponentTypeID === 3 || (viewTaxableValues && component.assessmentComponentTypeID === 2)\r\n );\r\n\r\n if (componentList) {\r\n nonCapComponents = _.sortBy(nonCapComponents, (component) => {\r\n if (component.sequence >= 0){\r\n return component.sequence;\r\n }\r\n else{\r\n return _.findIndex(componentList, {\r\n assessmentClassComponentID: component.assessmentClassComponentID\r\n });\r\n }\r\n });\r\n }\r\n\r\n return nonCapComponents;\r\n }\r\n\r\n capComponents(components: AnnualDetailComponent[], componentList: any, viewTaxableValues: boolean): AnnualDetailComponent[] {\r\n let capComponents: AnnualDetailComponent[] = _.filter(components, (component) =>\r\n component.assessmentComponentTypeID === 3 || (viewTaxableValues && component.assessmentComponentTypeID === 2)\r\n );\r\n\r\n if (componentList) {\r\n capComponents = _.sortBy(capComponents, (component) => {\r\n let sort: number;\r\n\r\n if (component.sequence >= 0){\r\n sort = component.sequence;\r\n }\r\n else{\r\n sort = _.findIndex(componentList, {\r\n assessmentClassComponentID: component.assessmentClassComponentID});\r\n }\r\n\r\n return sort * (viewTaxableValues ? -1 : 1);\r\n });\r\n }\r\n\r\n return capComponents;\r\n }\r\n\r\n //Get the component name from the type, or from the component itself?\r\n getComponentName(component: AnnualDetailComponent, componentTypes?: any[]): string {\r\n const compFromCompTypes = _.find(componentTypes, {\r\n assessmentClassComponentID: component.assessmentClassComponentID\r\n });\r\n\r\n if (compFromCompTypes) {\r\n return compFromCompTypes.componentName;\r\n } else {\r\n return component.componentName;\r\n }\r\n }\r\n\r\n // Return FMV value or null display characters\r\n getDisplayAssessment(component: AnnualDetailComponent, components: AnnualDetailComponent[]): string {\r\n const found = _.find(components, {\r\n 'assessmentClassComponentID': component.assessmentClassComponentID\r\n });\r\n\r\n return found ? this._numberPipe.transform(found.fairMarketValue, '1.0-0') : '----';\r\n }\r\n\r\n //Format the display of the savings section\r\n formatSavings(savings: string): string {\r\n const extraChars = ' + ?';\r\n let num = _.trimEnd(savings, extraChars);\r\n\r\n if (num && num !== '-') {\r\n num = this._currencyPipe.transform(num, 'USD', 'symbol', '1.2-2');\r\n if (_.endsWith(savings, extraChars)) {\r\n return num + extraChars;\r\n } else {\r\n return num;\r\n }\r\n } else {\r\n if (savings) {\r\n return savings;\r\n } else {\r\n return '0';\r\n }\r\n }\r\n }\r\n\r\n //Format the total FMV value\r\n getTotalFMV(components: AnnualDetailComponent[], viewTaxableValues: boolean): number {\r\n const nonDeletedComponents = _.reject(components, (component) =>{\r\n return component.efAction === 'delete' ||\r\n viewTaxableValues && component.assessmentComponentTypeID === AssessmentComponentTypeEnum.Adjustment;\r\n });\r\n\r\n return _.reduce(nonDeletedComponents, (sum, comp) => {\r\n if (comp.assessmentComponentTypeID === 3) {\r\n return sum;\r\n }\r\n const roundedFMV: Decimal = new Decimal(this.parseFMV(`${comp.fairMarketValue}`)).round();\r\n return new Decimal(sum).plus(roundedFMV).toNumber();\r\n }, 0);\r\n }\r\n\r\n // Parse FMV value as a number from a string, removing special characters\r\n parseFMV(fmv: string): number {\r\n let parseFMV = fmv;\r\n\r\n if (parseFMV) {\r\n parseFMV = parseFMV.toString();\r\n }\r\n\r\n //Return 0 if null\r\n if (parseFMV === '' || parseFMV === '#' || !parseFMV)\r\n return 0;\r\n\r\n //Manually parse out a # symbol from the string\r\n if (parseFMV[0] === '#')\r\n parseFMV = parseFMV.substring(1, parseFMV.length);\r\n\r\n return parseFloat(parseFMV);\r\n }\r\n\r\n\r\n // This is a bit messy; we need a function to call that pops up a yes/no/cancel modal if\r\n // the edit state is dirty. This is needed by the annual details navigation service\r\n // for generally navigating between assessments, appeals, and bills, but it is also needed\r\n // within appeals and bills for going between tabs. Having this function sit in\r\n // AnnualDetailsService allows us to access it anywhere it's needed, but maybe this should\r\n // be refactored so that it's in the navigation service code somehow.\r\n preNavigateWarn(editState: AnnualDetailEditState): Promise {\r\n return new Promise((resolve, reject) => {\r\n if (!editState.getDirty()) {\r\n resolve();\r\n }\r\n else {\r\n this._messageBoxService.open({\r\n message: 'Do you want to save your changes?',\r\n buttons: MessageBoxButtons.YesNoCancel\r\n }).then((result) => {\r\n switch (result) {\r\n case MessageBoxResult.Yes:\r\n editState.entityLoading = true;\r\n editState.validationHandler((isValid, errorMessage) => {\r\n if (!isValid) {\r\n editState.validationMessage = errorMessage;\r\n\r\n // HACK need setTimeout for some reason as when the 'show'\r\n // is called the validationMessage is not set unless we have the timeout\r\n this._timer.setTimeout(() => {\r\n // TODO this validation tooltip is not available in the\r\n // annual details service. Need to figure out how to set it\r\n //\r\n // editState.aDValidation.show();\r\n //\r\n // For now, console.warn:\r\n console.warn(errorMessage);\r\n });\r\n return;\r\n }\r\n\r\n editState.validationMessage = '';\r\n\r\n editState.saveHandler().then(() => {\r\n editState.setDirty(false);\r\n editState.entityLoading = false;\r\n resolve();\r\n });\r\n });\r\n break;\r\n case MessageBoxResult.No:\r\n editState.setDirty(false);\r\n editState.cancelHandler();\r\n resolve();\r\n break;\r\n case MessageBoxResult.Cancel:\r\n reject();\r\n break;\r\n }\r\n });\r\n }\r\n });\r\n }\r\n\r\n taxableValueNames(years: AnnualDetailYear[]): string[] {\r\n const result = [];\r\n let maxIndex = this.getMaxNumberOfTaxableValues(years);\r\n\r\n for (let i = 0; i < maxIndex; i++) {\r\n result.push(i === 0 ? 'Taxable' : `Taxable${i + 1}`);\r\n }\r\n\r\n return result;\r\n }\r\n\r\n taxableValues(revision: AnnualDetailAssessment, maxNumberOfTaxableValues: number): string[] {\r\n revision.taxableValues.sort((x, y) => x.sequence - y.sequence);\r\n const values = revision.taxableValues.map(x => this._numberPipe.transform(x.fairMarketValue, '1.0-0'));\r\n const numberOfMissedYears = maxNumberOfTaxableValues - values.length;\r\n const missedYears: string[] = new Array(numberOfMissedYears).fill('---');\r\n return [...values, ...missedYears];\r\n }\r\n\r\n getMaxNumberOfTaxableValues(years: AnnualDetailYear[]) {\r\n let maxIndex: number = 0;\r\n\r\n for (let year of years) {\r\n for (let detail of year.annualGridDetails) {\r\n maxIndex = Math.max(maxIndex, detail.taxableValues.length)\r\n }\r\n }\r\n return maxIndex;\r\n }\r\n}\r\n\r\nexport enum ComponentFilter { exempt, nonexempt, alternative }\r\n","import { Observable, Subject, ReplaySubject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class AnnualDetailsNavigationEventService {\r\n private _subjectAssessment = new Subject();\r\n private _subjectAppeal = new Subject();\r\n private _subjectTax = new Subject();\r\n private _subjectRefund = new Subject();\r\n private _subjectFiling = new Subject();\r\n private _refreshData = new Subject();\r\n private _refreshAnnualYearData = new Subject();\r\n private _goToGridData = new Subject();\r\n private _yearsData = new ReplaySubject(1);\r\n private _onEventReset = new Subject();\r\n private _refreshAccrualDetailsLink = new Subject();\r\n\r\n resetAnnualDetails(): void {\r\n this._onEventReset.next();\r\n }\r\n\r\n goToAssessment(input: AssessmentNavigationInput): void {\r\n this._subjectAssessment.next(input);\r\n }\r\n\r\n goToAppeal(input: AppealNavigationInput): void {\r\n this._subjectAppeal.next(input);\r\n }\r\n\r\n goToTax(input: TaxNavigationInput): void {\r\n this._subjectTax.next(input);\r\n }\r\n\r\n goToRefund(input: TaxNavigationInput): void {\r\n this._subjectRefund.next(input);\r\n }\r\n\r\n goToFiling(input: FilingNavigationInput): void {\r\n this._subjectFiling.next(input);\r\n }\r\n\r\n refreshActivityData(): void {\r\n this._refreshData.next();\r\n }\r\n\r\n refreshAnnualYear(): void {\r\n this._refreshAnnualYearData.next();\r\n }\r\n\r\n goToGrid(): void {\r\n this._goToGridData.next();\r\n }\r\n\r\n setYears(years: number[]): void {\r\n this._yearsData.next(years);\r\n }\r\n\r\n refreshAccrualDetailsLink( allPaymentsExcludedFromAccrual: boolean ): void {\r\n this._refreshAccrualDetailsLink.next(allPaymentsExcludedFromAccrual);\r\n }\r\n\r\n get assessmentEvent$(): Observable {\r\n return this._subjectAssessment.asObservable().pipe(takeUntil(this._onEventReset));\r\n }\r\n\r\n get appealEvent$(): Observable {\r\n return this._subjectAppeal.asObservable().pipe(takeUntil(this._onEventReset));\r\n }\r\n\r\n get taxEvent$(): Observable {\r\n return this._subjectTax.asObservable().pipe(takeUntil(this._onEventReset));\r\n }\r\n\r\n get refundEvent$(): Observable {\r\n return this._subjectRefund.asObservable().pipe(takeUntil(this._onEventReset));\r\n }\r\n\r\n get filingEvent$(): Observable {\r\n return this._subjectFiling.asObservable().pipe(takeUntil(this._onEventReset));\r\n }\r\n\r\n get refreshEvent$(): Observable {\r\n return this._refreshData.asObservable().pipe(takeUntil(this._onEventReset));\r\n }\r\n\r\n get refreshAnnualYearEvent$(): Observable {\r\n return this._refreshAnnualYearData.asObservable().pipe(takeUntil(this._onEventReset));\r\n }\r\n\r\n get goToGridEvent$(): Observable {\r\n return this._goToGridData.asObservable().pipe(takeUntil(this._onEventReset));\r\n }\r\n\r\n get yearsChangedEvent$(): Observable {\r\n return this._yearsData.asObservable().pipe(takeUntil(this._onEventReset));\r\n }\r\n\r\n get refreshAccrualDetailsLinkEvent$(): Observable {\r\n return this._refreshAccrualDetailsLink.asObservable().pipe(takeUntil(this._onEventReset));\r\n }\r\n}\r\n\r\nexport class AssessmentNavigationInput {\r\n constructor(annualYearID: number, annualAssessmentID: number) {\r\n this.annualYearID = annualYearID;\r\n this.annualAssessmentID = annualAssessmentID;\r\n }\r\n\r\n annualYearID: number;\r\n annualAssessmentID: number;\r\n}\r\n\r\nexport class AppealNavigationInput {\r\n constructor(annualYearID: number, annualAssessmentID: number, appealID: number) {\r\n this.annualYearID = annualYearID;\r\n this.annualAssessmentID = annualAssessmentID;\r\n this.appealID = appealID;\r\n }\r\n\r\n annualYearID: number;\r\n annualAssessmentID: number;\r\n appealID: number;\r\n}\r\n\r\nexport class TaxNavigationInput {\r\n constructor(annualYearID: number, taxID: number) {\r\n this.annualYearID = annualYearID;\r\n this.taxID = taxID;\r\n }\r\n\r\n annualYearID: number;\r\n taxID: number;\r\n}\r\n\r\nexport class FilingNavigationInput {\r\n constructor(annualYearID: number, filingId: number) {\r\n this.annualYearID = annualYearID;\r\n this.filingId = filingId;\r\n }\r\n\r\n annualYearID: number;\r\n filingId: number;\r\n}","export class AttachmentModalData {\r\n entityType: string;\r\n parentId: number;\r\n parentType: string;\r\n entityName: string;\r\n entityDescription: string;\r\n belowParcelEntity: AttachmentModalEntityData;\r\n entityData: AttachmentModalEntityData;\r\n year: number;\r\n disableYears: boolean;\r\n singleYear: boolean;\r\n readOnly: boolean = false;\r\n startOnPhotos: boolean;\r\n parentTypeId?: number;\r\n disableCategories?: boolean;\r\n attachmentCategoryId?: Core.AttachmentCategories;\r\n attachmentTypeId?: Core.AttachmentTypes;\r\n showEmailAttachmentButton?: boolean;\r\n selectedAttachmentId?: System.Guid;\r\n}\r\n\r\nexport class AttachmentModalEntityData {\r\n typeId: number;\r\n id: number;\r\n name: string;\r\n}\r\n","import { TasksByEntityDTO } from './Task.Model';\r\nimport { EntityDeactivationValidation } from './Task.Model';\r\n\r\nexport interface ReassignTaskRequestModel extends Core.UserTeamModel {\r\n taskIds: number[];\r\n searchTimestamp: Date;\r\n}\r\n\r\nexport interface ReassignUserTaskRequestModel {\r\n taskIds: number[];\r\n searchTimestamp: Date;\r\n teamId: number;\r\n userId: System.Guid;\r\n}\r\n\r\n// This only contains some functionality from the task service; please add more to the definition as needed\r\nexport abstract class TaskService {\r\n // At some point we should define this so it doesn't have to be \"any\" (for what it's worth, this isn't well-defined on the server either)\r\n abstract getTaskSummaryByEntity(entityID: number, entityTypeID: number): Promise;\r\n abstract launchTaskModal(entityID: number, entityTypeID: number, readonly?: boolean, toastMessage?: string, editonly?:boolean): Promise;\r\n abstract getByEntity(entityID: number, entityTypeID: number): Promise;\r\n abstract showErrorNotificationModal(errors: string[], warnings: string[], errorMessage: string, warningMessage?: string): void;\r\n abstract checkIfEntityMayBeDeactivated(entityID: number, entityTypeID: number): Promise;\r\n abstract skipMany(taskIDs: number[]): Promise;\r\n abstract completeMany(taskIDs: number[]): Promise;\r\n abstract reassignMany(reassignRequest: ReassignTaskRequestModel): Promise;\r\n abstract changeContacts(changeRequest: ReassignUserTaskRequestModel): Promise;\r\n abstract validateAssessorStateReqs(payload): Promise;\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { AttachmentModalData, AttachmentModalEntityData } from '../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { AnnualDetailsService } from '../annual-details.service';\r\nimport { AnnualDetailAssessment, AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { Appeal, AppealLevel, AppealStatus, AppealStatusID } from './appeal.model';\r\nimport { Decimal } from 'decimal.js';\r\nimport { BulkOperationResult } from '../../Common/Models/bulk-operation-result.model';\r\n\r\ndeclare const _: any;\r\n\r\n// TODO: Handle global consts in Angular 2+\r\nconst APPEAL_ENTITY_TYPE_ID = 8;\r\n\r\nexport class AppealViewDTO {\r\n annualDetailYear: AnnualDetailYear;\r\n appeals: Appeal[];\r\n stateID: number;\r\n}\r\n\r\n@Injectable()\r\nexport class AppealService {\r\n constructor(private annualDetailsService: AnnualDetailsService, private http: SDHttpService, private taskService: TaskService) { }\r\n\r\n //******************** API Calls ********************\r\n getStateAppealLevels(stateID: number): Promise {\r\n return this.http.get(`/api/appeallevel/state/${ stateID}`);\r\n }\r\n\r\n getAppealsForAnnualYear(annualYearID: number): Promise {\r\n return this.http.get(`/api/appeal/annualyear/${ annualYearID}`);\r\n }\r\n\r\n getAppealView(appealID: number): Promise {\r\n return this.http.get(`api/annualassessmentview/appeal/${ appealID}`).then((result: any) => {\r\n // The server calls the annualDetailYear \"annualYearView\", so we'll change the name here\r\n result.annualDetailYear = result.annualYearView;\r\n delete result.annualYearView;\r\n return result as AppealViewDTO;\r\n });\r\n }\r\n\r\n saveAppeal(appeal: Appeal): Promise {\r\n return this.http.put('/api/appeal', appeal);\r\n }\r\n\r\n createAppeal(appeal: Appeal): Promise {\r\n // Note that many properties of appeal will be ignored; as of this comment, we're only\r\n // saving the appeal level ID and assessment ID, leaving everything else at defaults\r\n\r\n // Also, some properties that we don't have selectable on the UI are required by the UI\r\n if (!appeal.appealStatusID) {\r\n\t\t\tappeal.appealStatusID = null;\t//AppealStatusID.Open; it's nullable now, see WK-2102\r\n }\r\n\r\n // Note that the server normally fills in a property called \"appealLevel\" on appeal objects,\r\n // but it is not returned on the create API call. The Appeal model on the UI does not have\r\n // an appealLevel property, so it shouldn't create any problems, but if we ever add the\r\n // appealLevel property to the UI model and lean on it, we should correct that issue here.\r\n return this.http.post('/api/appeal', appeal);\r\n }\r\n\r\n deleteAppeal(appealID: number): Promise {\r\n return this.http.delete(`/api/appeal/${ appealID}`);\r\n }\r\n //****************** End API Calls ******************\r\n\r\n loadTaskSummary(viewModel: AppealViewModel) {\r\n viewModel.currentTaskSummary = null;\r\n viewModel.loadingTaskSummary = true;\r\n const appealID = viewModel.currentAppeal.appealID;\r\n this.taskService.getTaskSummaryByEntity(appealID, APPEAL_ENTITY_TYPE_ID).then((taskSummary) => {\r\n // If we've navigated to another appeal by the time this happens, don't pay attention to the result\r\n if (appealID === viewModel.currentAppeal.appealID) {\r\n viewModel.loadingTaskSummary = false;\r\n viewModel.currentTaskSummary = taskSummary[0];\r\n }\r\n });\r\n }\r\n\r\n setCurrentAppeal(viewModel: AppealViewModel, appealID: number): void {\r\n const appealIndex = _.findIndex(viewModel.model, (appeal) => {\r\n return appeal.appealID === appealID;\r\n });\r\n\r\n if (appealIndex >= 0) {\r\n this.setAppealIndex(viewModel, appealIndex);\r\n }\r\n }\r\n\r\n setAppealIndex(viewModel: AppealViewModel, appealIndex: number, force: boolean = false): void {\r\n if (force || viewModel.currentAppealIndex !== appealIndex) {\r\n viewModel.currentAppealIndex = appealIndex;\r\n viewModel.currentAppeal = viewModel.model[appealIndex];\r\n viewModel.resetEdit();\r\n viewModel.updateModalData();\r\n this.loadTaskSummary(viewModel);\r\n }\r\n }\r\n\r\n setAppealByAssessmentID(viewModel: AppealViewModel, assessmentID: number): void {\r\n const appealIndex = _.findIndex(viewModel.model, (appeal: Appeal) => {\r\n return appeal.annualAssessmentID === assessmentID;\r\n });\r\n\r\n if (appealIndex >= 0) {\r\n this.setAppealIndex(viewModel, appealIndex);\r\n }\r\n }\r\n\r\n addNewAppealToViewModel(viewModel: AppealViewModel, appeal: Appeal): Promise {\r\n const originalModel = viewModel.model || [];\r\n viewModel.model = [];\r\n // HACK: For whatever reason, ngx-bootstrap's tab control didn't handle this\r\n // correctly without the setTimeout; this gives it time to \"breathe\" after resetting\r\n // the list\r\n return new Promise(resolve => {\r\n setTimeout(() => {\r\n originalModel.unshift(appeal);\r\n viewModel.model = originalModel;\r\n this.setAppealIndex(viewModel, 0, true);\r\n resolve(appeal);\r\n }, 1);\r\n });\r\n }\r\n\r\n saveAppealFromViewModel(viewModel: AppealViewModel): Promise {\r\n return this.saveAppeal(viewModel.currentAppeal);\r\n }\r\n\r\n cancelAppealEdit(viewModel: AppealViewModel): void {\r\n viewModel.cancelEdit();\r\n }\r\n\r\n toggleAppealEdit(viewModel: AppealViewModel, editMode: boolean): void {\r\n if (editMode) {\r\n viewModel.beginEdit();\r\n }\r\n }\r\n\r\n // Whenever the user manually updates the \"Savings\" field, the \"savingsOverriden\" flag on the\r\n // appeal is set. For the specified appeal, this function computes the savings if they have\r\n // not been overriden.\r\n setSavings(appeal: Appeal, annualYearModel: AnnualDetailYear): Promise {\r\n if (appeal.savingsOverridden) {\r\n return Promise.resolve();\r\n }\r\n\r\n const revisionAppealed = _.find(annualYearModel.annualGridDetails, (assessment: AnnualDetailAssessment) => {\r\n return assessment.annualAssessmentID === appeal.annualAssessmentID;\r\n }) as AnnualDetailAssessment;\r\n\r\n const revisionAppealedFMV = this.annualDetailsService.getTotalFMV(revisionAppealed.annualGridComponents, false);\r\n if (this.isClosed(appeal)) {\r\n const outcomeRevision = _.find(annualYearModel.annualGridDetails, { annualAssessmentID: appeal.outcomeAnnualAssessmentID });\r\n if (outcomeRevision) {\r\n // let outcomeRevisionFMV = this.annualDetailsService.getTotalFMV(outcomeRevision.annualGridComponents);\r\n\r\n // return this._getSavingsBaseRate(appeal.appealID, annualYearModel.annualYearID)\r\n // .then((savingsBaseRate: number) => {\r\n // appeal.savings = Decimal.max(0, new Decimal(revisionAppealedFMV).times(100).minus(new Decimal(outcomeRevisionFMV).times(100)).times(savingsBaseRate).dividedBy(100).toNumber()).toNumber();\r\n // })\r\n\r\n // WK-7747 - Savings used to be calculated on the UI, but as it has become more complex that has made less sense over time.\r\n return this.http.post(`/api/appeal/${appeal.appealID}/fetchsavings`, {\r\n appealId: appeal.appealID,\r\n annualAssessmentId: appeal.annualAssessmentID,\r\n outcomeRevisionId: outcomeRevision.annualAssessmentID,\r\n appealStatusId: appeal.appealStatusID,\r\n anticipatedFMV: appeal.anticipatedFMV\r\n }).then((newSavings: number) => {\r\n appeal.savings = +newSavings;\r\n });\r\n } else {\r\n appeal.savings = null;\r\n }\r\n }\r\n else {\r\n if (!appeal.anticipatedFMV) {\r\n appeal.savings = undefined;\r\n return Promise.resolve();\r\n }\r\n\r\n return this._getSavingsBaseRate(appeal.appealID, annualYearModel.annualYearID)\r\n .then((savingsBaseRate: number) => {\r\n appeal.savings = new Decimal(revisionAppealedFMV).times(100).minus(new Decimal(appeal.anticipatedFMV).times(100)).times(savingsBaseRate).dividedBy(100).toNumber();\r\n });\r\n }\r\n\r\n if (appeal.savings < 0) {\r\n appeal.savings = 0;\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n isClosed(appeal: Appeal): boolean {\r\n if (!appeal.appealStatusID) {\r\n return false;\r\n }\r\n\r\n const status = AppealStatus.getByID(appeal.appealStatusID);\r\n return status.isClosedStatus;\r\n }\r\n\r\n addPrepareApplicationTasks(taskIds: number[]): Promise {\r\n return this.http.put('api/tasks/addprepareapplicationtasks', taskIds);\r\n }\r\n\r\n getAppealViewModelByYear(annualYearModel: AnnualDetailYear, parcelID: number, parcelAcctNum: string, stateID: number, defaultAppealID?: number): Promise {\r\n return Promise.all([this.getStateAppealLevels(stateID), this.getAppealsForAnnualYear(annualYearModel.annualYearID)])\r\n .then((result) => {\r\n const viewModel = this.buildAppealViewModel(result[1], result[0], annualYearModel, parcelID, parcelAcctNum);\r\n viewModel.defaultAppealID = defaultAppealID;\r\n\r\n return viewModel;\r\n });\r\n }\r\n\r\n getAppealViewModelByAppealID(appealID: number): Promise {\r\n return this.getAppealView(appealID).then((appealView) => {\r\n return this.getStateAppealLevels(appealView.stateID).then((appealLevels) => {\r\n const viewModel = this.buildAppealViewModel(appealView.appeals, appealLevels, appealView.annualDetailYear, null, null);\r\n viewModel.defaultAppealID = appealID;\r\n this.setCurrentAppeal(viewModel, appealID);\r\n viewModel.showTabs = false;\r\n\r\n return viewModel;\r\n });\r\n });\r\n }\r\n\r\n private buildAppealViewModel(appeals: Appeal[], appealLevels: AppealLevel[], annualYearModel: AnnualDetailYear, parcelID: number, parcelAcctNum: string): AppealViewModel {\r\n const viewModel = new AppealViewModel();\r\n viewModel.stateAppealLevels = appealLevels;\r\n viewModel.annualYearModel = annualYearModel;\r\n viewModel.model = appeals;\r\n viewModel.showTabs = true;\r\n viewModel.parcelID = parcelID;\r\n viewModel.parcelAcctNum = parcelAcctNum;\r\n if (viewModel.model.length < 1) {\r\n viewModel.currentAppealIndex = -1;\r\n viewModel.currentAppeal = null;\r\n }\r\n else {\r\n let latestAppealIdx = 0;\r\n\r\n const latestAppeal= _.maxBy(appeals, x => new Date(x.addDate));\r\n if(latestAppeal) {\r\n latestAppealIdx = _.findIndex(appeals, {appealID: latestAppeal.appealID});\r\n }\r\n\r\n this.setAppealIndex(viewModel, latestAppealIdx);\r\n }\r\n\r\n return viewModel;\r\n }\r\n\r\n private _getSavingsBaseRate(appealID: number, annualYearID: number): Promise {\r\n return this.http.get(`api/appeal/${appealID}/baserate/${annualYearID}`);\r\n }\r\n}\r\n\r\nexport class AppealViewModel {\r\n constructor() {\r\n // This will be set by the appeal component when loaded\r\n this.hasWritePermission = false;\r\n\r\n this.submitEvidenceValid = true;\r\n this.informalHearingValid = true;\r\n this.hearingValid = true;\r\n this.resetDateTimeHandler = null;\r\n }\r\n\r\n model: Appeal[];\r\n annualYearModel: AnnualDetailYear;\r\n stateAppealLevels: AppealLevel[];\r\n loadingTaskSummary: boolean;\r\n currentTaskSummary: any;\r\n currentAppealIndex: number;\r\n currentAppeal: Appeal;\r\n parcelID: number;\r\n parcelAcctNum: string;\r\n showTabs: boolean;\r\n defaultAppealID: number;\r\n commentModalData: CommentModalData;\r\n attachmentModalData: AttachmentModalData;\r\n hasWritePermission: boolean;\r\n submitEvidenceValid: boolean;\r\n informalHearingValid: boolean;\r\n hearingValid: boolean;\r\n resetDateTimeHandler: () => void;\r\n private preEditModelBackup: Appeal;\r\n\r\n // Usually, the backup object used for cancelling will be set whenever a navigation event happens,\r\n // and the navigation service informs us we need to handle it in the beginEdit handler. However,\r\n // within the appeal control, there are some circumstances where the backup must be created again.\r\n // At the moment, those circumstances are:\r\n // 1. Switching tabs\r\n // 2. An automatic save occurring before opening the task modal\r\n resetEdit(force: boolean = false): void {\r\n if (force || (this.currentAppeal &&\r\n this.preEditModelBackup &&\r\n this.currentAppeal.appealID !== this.preEditModelBackup.appealID)) {\r\n this.preEditModelBackup = _.cloneDeep(this.currentAppeal) as Appeal;\r\n console.log(['Creating preEditModelBackup', this.preEditModelBackup]);\r\n if (this.resetDateTimeHandler) {\r\n this.resetDateTimeHandler();\r\n }\r\n }\r\n }\r\n\r\n beginEdit(): void {\r\n if (this.currentAppeal) {\r\n this.preEditModelBackup = _.cloneDeep(this.currentAppeal) as Appeal;\r\n if (this.resetDateTimeHandler) {\r\n this.resetDateTimeHandler();\r\n }\r\n }\r\n else {\r\n this.preEditModelBackup = undefined;\r\n if (this.resetDateTimeHandler) {\r\n this.resetDateTimeHandler();\r\n }\r\n }\r\n }\r\n\r\n cancelEdit(): void {\r\n if (this.currentAppeal.appealID === this.preEditModelBackup.appealID) {\r\n _.assign(this.currentAppeal, this.preEditModelBackup);\r\n if (this.resetDateTimeHandler) {\r\n this.resetDateTimeHandler();\r\n }\r\n }\r\n else {\r\n throw new Error(`Sanity check failed; attempted to restore backup with different appeal ID than current. Current appeal ID: ${\r\n this.currentAppeal.appealID }, backup appeal ID: + ${ this.preEditModelBackup.appealID}`);\r\n }\r\n }\r\n\r\n assignFromExistingAppeal(appeal: Appeal): void {\r\n if (!this.currentAppeal) {\r\n throw new Error('Invalid attempt to load appeal from existing data when no current appeal is set');\r\n }\r\n\r\n if (this.currentAppeal.appealID !== appeal.appealID) {\r\n throw new Error(`Invalid attempt to appeal appeal with appealID ${ appeal.appealID\r\n } into appeal with appealID ${ this.currentAppeal.appealID}`);\r\n }\r\n\r\n _.assign(this.currentAppeal, appeal);\r\n if (this.resetDateTimeHandler) {\r\n this.resetDateTimeHandler();\r\n }\r\n }\r\n\r\n appealLevelAbbrDisplay(appealLevelID: number): string {\r\n const appealLevel = _.find(this.stateAppealLevels, (x) => {\r\n return x.appealLevelID === appealLevelID;\r\n }) as AppealLevel;\r\n\r\n return appealLevel === undefined ? '' : appealLevel.abbr;\r\n }\r\n\r\n appealLevelLitigationDisplay(appealLevelId: number): string {\r\n const appealLevel = _.find(this.stateAppealLevels, (x) => {\r\n return x.appealLevelID === appealLevelId;\r\n }) as AppealLevel;\r\n\r\n return appealLevel === undefined\r\n ? ''\r\n : appealLevel.litigation ? 'Yes' : 'No';\r\n }\r\n\r\n setParcelDetails(parcelID: number, parcelAcctNum: string): void {\r\n this.parcelID = parcelID;\r\n this.parcelAcctNum = parcelAcctNum;\r\n this.updateModalData();\r\n }\r\n\r\n updateModalData(): void {\r\n const appeal = this.currentAppeal;\r\n if (appeal) {\r\n const appealLevel = this.appealLevelAbbrDisplay(appeal.appealLevelID);\r\n const description = `${this.annualYearModel.annualYear1 } - ${ appealLevel}`;\r\n\r\n // comment data\r\n this.commentModalData = new CommentModalData();\r\n this.commentModalData.entityID = appeal.appealID;\r\n this.commentModalData.entityTypeID = APPEAL_ENTITY_TYPE_ID;\r\n this.commentModalData.canEdit = this.hasWritePermission;\r\n this.commentModalData.parcelID = this.parcelID;\r\n this.commentModalData.parcelAcctNum = this.parcelAcctNum;\r\n this.commentModalData.description = description;\r\n this.commentModalData.year = this.annualYearModel.annualYear1.toString();\r\n\r\n // attachment data\r\n this.attachmentModalData = new AttachmentModalData();\r\n this.attachmentModalData.belowParcelEntity = new AttachmentModalEntityData();\r\n this.attachmentModalData.belowParcelEntity.id = appeal.appealID;\r\n this.attachmentModalData.belowParcelEntity.typeId = APPEAL_ENTITY_TYPE_ID;\r\n this.attachmentModalData.belowParcelEntity.name = appealLevel;\r\n this.attachmentModalData.entityType = 'Appeal';\r\n this.attachmentModalData.parentId = this.parcelID;\r\n this.attachmentModalData.parentType = 'Parcel';\r\n this.attachmentModalData.entityName = this.parcelAcctNum;\r\n this.attachmentModalData.entityDescription = description;\r\n this.attachmentModalData.year = this.annualYearModel.annualYear1;\r\n }\r\n }\r\n\r\n validate(callback: (boolean, string) => void): void {\r\n const invalidTimes = [];\r\n\r\n // For now I believe this is only possible by entering a date but not a time\r\n // TODO: Write this in a less crappy way\r\n if (!this.submitEvidenceValid) {\r\n invalidTimes.push('Submit Evidence');\r\n }\r\n if (!this.informalHearingValid) {\r\n invalidTimes.push('Informal Hearing');\r\n }\r\n if (!this.hearingValid) {\r\n invalidTimes.push('Formal Hearing');\r\n }\r\n\r\n let validationMessage = '';\r\n\r\n switch (invalidTimes.length) {\r\n case 1:\r\n validationMessage = ' date/time not valid';\r\n break;\r\n case 2:\r\n validationMessage = `${invalidTimes[0] } and ${ invalidTimes[1] } date/time not valid`;\r\n break;\r\n case 3:\r\n validationMessage = `${invalidTimes[0] }, ${ invalidTimes[1] }, and ${ invalidTimes[2] } date/time not valid`;\r\n break;\r\n }\r\n\r\n const appealStatusID = this.currentAppeal.appealStatusID;\r\n if ((appealStatusID === AppealStatusID.Reduction || (appealStatusID === AppealStatusID.Closed && this.currentAppeal.savings > 0)) && !this.currentAppeal.savingsDate) {\r\n validationMessage = `Savings Date is required${ validationMessage === '' ? '' : (`; ${ validationMessage}`)}`;\r\n }\r\n else if (this.currentAppeal.appealStatusID === AppealStatusID.Null && this.currentAppeal.savingsDate) {\r\n validationMessage = `Savings Date is not valid unless the appeal is closed${ validationMessage === '' ? '' : (`; ${ validationMessage}`)}`;\r\n }\r\n\r\n if (validationMessage !== '') {\r\n callback(false, validationMessage);\r\n }\r\n else {\r\n callback(true, '');\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { CollectorPaymentOption } from '../../Assessor-Collector/Collector/Billing-Scenario/billingScenario.models';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { AnnualDetailAssessment, AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { BillCluster } from './bill-cluster.model';\r\nimport { Bill } from './bill.model';\r\nimport { Payment } from './payment.model';\r\nimport { Refund } from './refund.model';\r\nimport { Decimal } from 'decimal.js';\r\nimport { BillClusterTaxRateSetupModalResult } from '../../Entity/Parcel/TaxRateSetup/billClusterTaxRateSetupModal.component';\r\nimport { EntityAddress } from 'src/app/Common/Address/Address-View-Edit/address.model';\r\nimport { AddressDetailsModalService } from 'src/app/Common/Address/Address-View-Edit/address.details.modal.service';\r\nimport { EntityType } from '../../constants.new';\r\n\r\ndeclare const _: any;\r\ndeclare const moment: any;\r\n\r\nconst PAYMENT_ENTITY_TYPE_ID = 11;\r\nconst TAXBILL_ENTITY_TYPE_ID = 9;\r\nconst REFUND_ENTITY_TYPE_ID = 14;\r\n\r\nexport class BillViewDTO {\r\n annualYearView: AnnualDetailYear;\r\n bill: Bill;\r\n hasAvailableTaxSetup: boolean;\r\n}\r\n\r\n@Injectable()\r\nexport class BillClusterService {\r\n constructor(\r\n private http: SDHttpService,\r\n private readonly taskService: TaskService,\r\n private readonly addressDetailsModalService: AddressDetailsModalService) { }\r\n\r\n getRefundViewByID(refundID: number): Promise {\r\n return this.http.get(`/api/refund/${ refundID}`);\r\n }\r\n\r\n\r\n paymentPropChanged(payment: Payment): number {\r\n\t\tconst possibleAmount = this.calcPaymentAmount(payment);\r\n\t\treturn possibleAmount < 0 ? 0 : possibleAmount;\r\n\r\n\t\t//This recalcuates totals for the annual year\r\n\t\t// this.calcTaxTotals();\r\n\t}\r\n\r\n calcPaymentAmount(payment: Payment): number {\r\n\t\tpayment.grossPayment = payment.grossPayment || 0;\r\n\r\n\t\treturn new Decimal(payment.grossPayment)\r\n\t\t\t.plus(payment.discountAmount || 0)\r\n\t\t\t.plus(payment.penaltyAmount || 0)\r\n\t\t\t.plus(payment.interestAmount || 0)\r\n\t\t\t.toDecimalPlaces(2)\r\n\t\t\t.toNumber();\r\n\t}\r\n\r\n saveRefund(refund: Refund): Promise {\r\n return this.http.put('/api/refund', refund);\r\n }\r\n\r\n deleteBillCluster(billClusterID: number): Promise {\r\n return this.http.delete(`/api/billcluster/${ billClusterID}`);\r\n }\r\n\r\n deleteBill(billID: number): Promise {\r\n return this.http.delete(`/api/bill/${ billID}`);\r\n }\r\n\r\n deleteRefund(refundID: number): Promise {\r\n return this.http.delete(`/api/refund/${ refundID}`);\r\n }\r\n\r\n getAnnaulAssessmentsByAnnualYearID(annualYearId: number): Promise {\r\n return this.http.get(`/api/refund/${ annualYearId}/annualassessments`);\r\n }\r\n\r\n savePaymentAttachment(attachmentID: string, paymentID: number): Promise {\r\n return this.http.patch('api/payment', {\r\n paymentID: paymentID,\r\n attachmentID: attachmentID || null\r\n });\r\n }\r\n\r\n getAccrualDetails(billClusterId: number): Promise {\r\n return this.http.get(`/api/billcluster/${billClusterId}/accrualdetail`);\r\n }\r\n\r\n updateAccrualDetails(billClusterId: number, request: Core.BillClusterAccrualUpdateRequest): Promise {\r\n return this.http.put(`/api/billcluster/${billClusterId}/accrualdetail`, request);\r\n }\r\n\r\n addAccrualAdjustment(billClusterId: number, request: Core.BillClusterAccrualAdjustmentRequest): Promise {\r\n return this.http.post(`/api/billcluster/${billClusterId}/accrualadjustment`, request);\r\n }\r\n\r\n updateAccrualAdjustment(billClusterId: number, request: Core.BillClusterAccrualAdjustmentRequest): Promise {\r\n return this.http.put(`/api/billcluster/${billClusterId}/accrualadjustment`, request);\r\n }\r\n\r\n deleteAccrualAdjustment(billClusterId: number, request: Core.BillClusterAccrualAdjustmentRemoveRequest): Promise {\r\n return this.http.post(`/api/billcluster/${billClusterId}/accrualadjustment/remove`, request);\r\n }\r\n\r\n overrideAccrualTrueUp(billClusterId: number, request: Core.BillClusterAccrualOverrideRequest): Promise {\r\n return this.http.put(`/api/billcluster/${billClusterId}/accrualdetail/trueup`, request);\r\n }\r\n\r\n async getCollectorEntityAddressesForBillCluster(billClusterId: number): Promise {\r\n const billCluster = await this.getBillClusterByID(billClusterId);\r\n return this.addressDetailsModalService.getEntityAddresses(billCluster.collectorID, EntityType.Collector);\r\n }\r\n\r\n getOneBill(billID: number): Promise {\r\n return this.getBillViewByID(billID)\r\n .then((billViewDTO: BillViewDTO) => {\r\n return billViewDTO.bill;\r\n });\r\n }\r\n\r\n getTabFromBillCluster(billCluster: BillCluster): BillCluster {\r\n billCluster.bills = _.chain(billCluster.bills)\r\n .map((bill: Bill): Bill => {\r\n return this.getBillForView(bill);\r\n })\r\n .sortBy((bill: Bill) => {\r\n if (bill.payments.length > 0) {\r\n return bill.payments[0].dueDate !== null ? bill.payments[0].dueDate.getTime() : null;\r\n }\r\n\r\n return null;\r\n })\r\n .value();\r\n\r\n billCluster.showExtraFields = this.getShowExtraFields(billCluster.bills);\r\n billCluster.icon = billCluster.bills[0].collectorPaymentOptionID ? 'fa-refresh' : 'fa-envelope';\r\n billCluster.allPaymentsExcludedFromAccrual = this.areAllPaymentsExcludedFromAccruals(billCluster.bills);\r\n\r\n return billCluster;\r\n }\r\n\r\n getShowExtraFields(bills: Bill[]): { bill: boolean, payment: boolean } {\r\n const clusterPayments = _.chain(bills)\r\n .map('payments')\r\n .flatten()\r\n .value();\r\n\r\n const showPaymentFields = _.some(clusterPayments, (payment: Payment) => {\r\n return payment.discountAmount !== 0 || payment.interestAmount !== 0 || payment.penaltyAmount !== 0 || payment.checkDate || payment.checkNumber || payment.postDate ||\r\n (payment.accrualBegin && payment.originalAccrualBegin && !moment(payment.accrualBegin).isSame(payment.originalAccrualBegin)) ||\r\n (payment.accrualEnd && payment.originalAccrualEnd && !moment(payment.accrualEnd).isSame(payment.originalAccrualEnd));\r\n });\r\n\r\n const showBillFields = _.some(bills, (bill: Bill) => {\r\n return bill.directAsmt !== 0;\r\n });\r\n\r\n return {\r\n bill: showBillFields,\r\n payment: showPaymentFields\r\n };\r\n }\r\n\r\n areAllPaymentsExcludedFromAccruals(bills: Bill[]): boolean {\r\n const clusterPayments = _.chain(bills)\r\n .map('payments')\r\n .flatten()\r\n .value();\r\n\r\n // If any Payment is not excluded from Accruals, false is returned.\r\n return _.every(clusterPayments, (payment: Payment) => payment.accrualsExclude.excludeFromAccruals);\r\n }\r\n\r\n getBillForView(bill: Bill): Bill {\r\n bill.payments = _.chain(bill.payments)\r\n .sortBy([(payment: Payment) => {\r\n return payment.dueDate !== null ? payment.dueDate.getTime() : null;\r\n }, 'paymentID'])\r\n .map((payment: Payment, i: number) => {\r\n payment.discountAmount = payment.discountAmount || 0;\r\n payment.penaltyAmount = payment.penaltyAmount || 0;\r\n payment.interestAmount = payment.interestAmount || 0;\r\n payment.grossPayment = new Decimal(payment.paymentAmount)\r\n .minus(payment.discountAmount)\r\n .minus(payment.interestAmount)\r\n .minus(payment.penaltyAmount)\r\n .toNumber();\r\n\r\n if (payment.collectorPayment) {\r\n payment.name = payment.collectorPayment.name;\r\n } else {\r\n payment.name = 'Payment';\r\n\r\n if (bill.payments.length > 1) {\r\n payment.name += ` ${ i + 1 } of ${ bill.payments.length}`;\r\n }\r\n }\r\n\r\n return payment;\r\n })\r\n .value();\r\n\r\n bill.billAmount = _.reduce(_.map(bill.payments, 'grossPayment'), (sum, payment) => {\r\n return sum + payment;\r\n });\r\n\r\n bill.displayProrationPct = bill.prorationPct == null ? null : new Decimal(bill.prorationPct).times(100).toNumber();\r\n\r\n this.getPaymentOptionsForView(bill)\r\n .then((options: CollectorPaymentOption[]) => {\r\n bill.collectorPaymentOptions = options;\r\n });\r\n\r\n return bill;\r\n }\r\n\r\n getTaxesForAnnualYear(yearID: number): Promise {\r\n return Promise.all([this.getBillClustersForAnnualYear(yearID), this.getRefundsForAnnualYear(yearID)])\r\n .then(result => {\r\n const billTabs = _.chain(result[0])\r\n .map((billCluster: BillCluster) => {\r\n return this.getTabFromBillCluster(billCluster);\r\n })\r\n .sortBy([(billCluster: BillCluster) => {\r\n if (billCluster.bills.length) {\r\n return billCluster.bills[0].collectorPaymentOptionID;\r\n }\r\n\r\n return null;\r\n },\r\n (billCluster: BillCluster) => {\r\n if (billCluster.bills.length > 0) {\r\n const bill = billCluster.bills[0];\r\n\r\n if (bill.payments.length > 0) {\r\n return bill.payments[0].dueDate !== null ? bill.payments[0].dueDate.getTime() : null;\r\n }\r\n }\r\n\r\n return null;\r\n }])\r\n .value();\r\n\r\n const refundTabs = _.map(result[1], (refund: Refund) => {\r\n return {\r\n title: `${refund.collector.abbr }- Refund`,\r\n bills: [],\r\n refund: refund,\r\n icon: 'fa-money'\r\n };\r\n });\r\n\r\n const tabs: BillCluster[] = _.chain(billTabs)\r\n .union(refundTabs)\r\n .map((tab: BillCluster): BillCluster => {\r\n tab.taskSummariesPromise = this.getTaskSummariesForTab(tab);\r\n\r\n return tab;\r\n\r\n })\r\n .value();\r\n\r\n return tabs;\r\n\r\n });\r\n }\r\n\r\n getOneTab(billClusterID: number): Promise {\r\n return this.getBillClusterByID(billClusterID)\r\n .then((result: BillCluster) => {\r\n const tab: BillCluster = this.getTabFromBillCluster(result);\r\n tab.taskSummariesPromise = this.getTaskSummariesForTab(tab);\r\n\r\n return tab;\r\n });\r\n }\r\n\r\n saveTab(tab: BillCluster, newBill: boolean): Promise {\r\n if (tab.refund) {\r\n\r\n if (tab.refund.refundAmount) {\r\n tab.refund.refundAmount = -Math.abs(tab.refund.refundAmount);\r\n }\r\n\r\n if (tab.refund.refundID) {\r\n return this.saveRefund(tab.refund);\r\n } else {\r\n return this.createRefund(tab.refund);\r\n }\r\n\r\n } else {\r\n if (tab.billClusterID || newBill) {\r\n const billCluster = _.pick(tab, 'annualYearID', 'billClusterID', 'bills', 'calcProjected', 'collector', 'collectorID', 'taxRateAreaId', 'rowVersion');\r\n\r\n return this.saveBillCluster(billCluster);\r\n } else {\r\n return this.saveOneBill(tab.bills[0]);\r\n }\r\n }\r\n }\r\n\r\n saveOneBill(bill: Bill): Promise {\r\n bill.collectorPaymentOption = null;\r\n\r\n return this.saveBill(bill);\r\n }\r\n\r\n getTaskSummariesForTab(tab: BillCluster): Promise {\r\n if (tab.refund) {\r\n tab.refund.taskSummary = {};\r\n\r\n return this.getEntityTaskSummaries(tab.refund, REFUND_ENTITY_TYPE_ID, tab.refund.refundID);\r\n }\r\n\r\n const promises: Promise[] = [];\r\n\r\n _.forEach(tab.bills, (bill: Bill): void => {\r\n // TODO: This is copied to buildBillViewModel; this should probably be refactored\r\n const promise = this.getTaskSummariesForBill(bill)\r\n .then(() => {\r\n bill.showActualCheckbox = bill.payments[0].taskSummary && !_.some(bill.payments, (payment: Payment) => {\r\n return !_.isEmpty(payment.taskSummary);\r\n });\r\n });\r\n\r\n promises.push(promise);\r\n });\r\n\r\n return Promise.all(promises);\r\n }\r\n\r\n getTaskSummariesForBill(bill: Bill): Promise {\r\n bill.taskSummary = {};\r\n const promises: Promise[] = [];\r\n\r\n _.forEach(bill.payments, (payment: Payment): void => {\r\n const promise = this.getEntityTaskSummaries(payment, PAYMENT_ENTITY_TYPE_ID, payment.paymentID)\r\n .then((response) => {\r\n payment.taskSummary = {};\r\n\r\n //Filter out bill data\r\n if (!bill.taskSummary || _.isEmpty(bill.taskSummary)) {\r\n bill.taskSummary = _.find(response, {\r\n EntityID: bill.billID,\r\n EntityTypeID: TAXBILL_ENTITY_TYPE_ID\r\n }) || {};\r\n }\r\n\r\n //Filter out payment data\r\n let paymentTask = _.find(response, {\r\n EntityID: payment.paymentID,\r\n EntityTypeID: PAYMENT_ENTITY_TYPE_ID\r\n });\r\n\r\n if (!paymentTask) {\r\n paymentTask = _.find(response, {\r\n OriginalEntityID: payment.paymentID,\r\n EntityTypeID: PAYMENT_ENTITY_TYPE_ID\r\n });\r\n }\r\n\r\n if (paymentTask) {\r\n payment.taskSummary = paymentTask;\r\n if (!payment.taskSummary.Status || payment.taskSummary.Status.trim() === '') {\r\n payment.taskSummary.Status = bill.taskSummary.Status;\r\n }\r\n } else if (bill.taskSummary.Status) {\r\n payment.taskSummary = {\r\n Status: bill.taskSummary.Status\r\n };\r\n }\r\n });\r\n\r\n promises.push(promise);\r\n });\r\n\r\n return Promise.all(promises);\r\n }\r\n\r\n getEntityTaskSummaries(entity, entityTypeID, entityID) {\r\n return this.taskService.getTaskSummaryByEntity(entityID, entityTypeID)\r\n .then((taskSummaries) => {\r\n if (taskSummaries && taskSummaries.length > 0) {\r\n entity.taskSummary = taskSummaries[0];\r\n }\r\n return taskSummaries;\r\n });\r\n }\r\n\r\n setTabIndex(viewModel: TaxesViewModel, tabIndex: number): void {\r\n if (viewModel.currentTabIndex !== tabIndex) {\r\n viewModel.currentTabIndex = tabIndex;\r\n viewModel.currentTab = viewModel.model[tabIndex];\r\n viewModel.model[tabIndex].active = true;\r\n viewModel.resetEdit();\r\n }\r\n }\r\n\r\n cancelTaxesEdit(viewModel: TaxesViewModel): void {\r\n viewModel.cancelEdit();\r\n }\r\n\r\n saveTabFromViewModel(viewModel: TaxesViewModel): Promise {\r\n return this.saveTab(viewModel.currentTab, false);\r\n }\r\n\r\n toggleTaxesEdit(viewModel: TaxesViewModel, editMode: boolean): void {\r\n if (editMode) {\r\n viewModel.beginEdit();\r\n }\r\n }\r\n\r\n setCurrentTab(viewModel: TaxesViewModel, billClusterID: number): void {\r\n const tabIndex = _.findIndex(viewModel.model, (billCluster: BillCluster) => {\r\n return billCluster.billClusterID === billClusterID;\r\n });\r\n\r\n if (tabIndex >= 0 && billClusterID) {\r\n this.setTabIndex(viewModel, tabIndex);\r\n } else {\r\n this.setTabIndex(viewModel, 0);\r\n }\r\n }\r\n\r\n setCurrentTabByRefundID(viewModel: TaxesViewModel, refundID: number): void {\r\n const tabIndex = _.findIndex(viewModel.model, (billCluster: BillCluster) => {\r\n return billCluster.refund && billCluster.refund.refundID === refundID;\r\n });\r\n\r\n if (tabIndex >= 0 && refundID) {\r\n this.setTabIndex(viewModel, tabIndex);\r\n } else {\r\n this.setTabIndex(viewModel, 0);\r\n }\r\n }\r\n\r\n getTaxesViewModelByYear(annualYearModel: AnnualDetailYear, parcelID: number, parcelAcctNum: string): Promise {\r\n return this.getTaxesForAnnualYear(annualYearModel.annualYearID)\r\n .then((result: BillCluster[]) => {\r\n const viewModel = this.buildTaxesViewModel(result, annualYearModel, parcelID, parcelAcctNum);\r\n\r\n return viewModel;\r\n });\r\n }\r\n\r\n getBillViewModelByBillID(billID: number): Promise {\r\n return this.getBillViewByID(billID)\r\n .then((billViewDTO: BillViewDTO) => {\r\n const viewModel = this.buildBillViewModel(billViewDTO);\r\n\r\n return viewModel;\r\n });\r\n }\r\n\r\n getRefundViewModelByRefundID(refundID: number): Promise {\r\n return this.getRefundViewByID(refundID)\r\n .then((refund: Refund) => {\r\n const viewModel = this.buildRefundViewModel(refund);\r\n\r\n return viewModel;\r\n });\r\n }\r\n\r\n // A static function here isn't ideal; perhaps instead of having validate be a member\r\n // of the ViewModel, we could require code requiring validation to invoke the BillCluster\r\n // instead.\r\n static validateBills(bills: Bill[]): string {\r\n let errorMessage: string = '';\r\n\r\n _.forEach(bills, (bill: Bill) => {\r\n if(bill.prorationPct > 1) {\r\n errorMessage = 'Proration % must be less than 100';\r\n return false;\r\n }\r\n\r\n _.forEach(bill.payments, (payment: Payment) => {\r\n if (!payment.dueDate) {\r\n errorMessage = 'Missing payment due date!';\r\n return false;\r\n }\r\n\r\n if (moment(payment.accrualEnd).isBefore(payment.accrualBegin)) {\r\n errorMessage = 'Accrual End is before Accrual Begin!';\r\n return false;\r\n }\r\n\r\n if (moment(payment.accrualEnd).subtract(1, 'years').isAfter(payment.accrualBegin)) {\r\n errorMessage = 'Accrual date range exceeds one year!';\r\n return false;\r\n }\r\n\r\n });\r\n });\r\n\r\n return errorMessage;\r\n }\r\n\r\n static validateTaxes(currentTab: BillCluster): string {\r\n const errorMessage: string = BillClusterService.validateBills(currentTab.bills);\r\n\r\n if (errorMessage) {\r\n return errorMessage;\r\n }\r\n\r\n if (!currentTab.refund) {\r\n return '';\r\n }\r\n\r\n if (moment(currentTab.refund.accrualEnd).isBefore(currentTab.refund.accrualBegin)) {\r\n return 'Accrual End is before Accrual Begin!';\r\n }\r\n\r\n if (moment(currentTab.refund.accrualEnd).subtract(1, 'years').isAfter(currentTab.refund.accrualBegin)) {\r\n return 'Accrual date range exceeds one year!';\r\n }\r\n\r\n return '';\r\n }\r\n\r\n //******************** API Calls ********************\r\n private getBillClustersForAnnualYear(yearID: number): Promise {\r\n return this.http.get('/api/billcluster/', { params: { annualYearID: yearID } });\r\n }\r\n\r\n private getRefundsForAnnualYear(yearID: number): Promise {\r\n return this.http.get('/api/refund', { params: { annualyearid: yearID } });\r\n }\r\n\r\n private async getBillClusterByID(billClusterID: number): Promise {\r\n return this.http.get(`/api/billcluster/${billClusterID}`);\r\n }\r\n\r\n private getBillViewByID(billID: number): Promise {\r\n return this.http.get(`/api/annualassessmentview/bill/${billID}`);\r\n }\r\n\r\n private getCollectorPaymentOptionsForParcel(collectorBillID: number, collectorBillScenarioID: number): Promise {\r\n return this.http.get('/api/collectorpaymentoption/parcel', {\r\n params: {\r\n collectorBillID: collectorBillID,\r\n collectorBillScenarioID: collectorBillScenarioID\r\n }\r\n });\r\n }\r\n private saveBillCluster(billCluster: BillCluster): Promise {\r\n return this.http.put('/api/billcluster/', billCluster);\r\n }\r\n\r\n private createRefund(refund: Refund): Promise {\r\n return this.http.post('/api/refund', refund);\r\n }\r\n\r\n private saveBill(bill: Bill): Promise {\r\n return this.http.put('/api/bill', bill);\r\n }\r\n\r\n //****************** End API Calls ******************\r\n\r\n private getPaymentOptionsForView(bill: Bill): Promise {\r\n if (bill.collectorPaymentOption) {\r\n return this.getCollectorPaymentOptionsForParcel(bill.collectorPaymentOption.collectorBillID, bill.collectorPaymentOption.collectorBillScenarioID)\r\n .then((result: CollectorPaymentOption[]) => {\r\n const option = _.chain(result)\r\n .map((x: CollectorPaymentOption, i) => {\r\n x.name = x.name || 'N/A';\r\n\r\n return x;\r\n })\r\n .orderBy(['isDefault', 'name'], ['desc', 'asc'])\r\n .value();\r\n\r\n return option;\r\n });\r\n } else {\r\n return new Promise((resolve, reject) => {\r\n resolve([]);\r\n });\r\n }\r\n }\r\n\r\n //*************** ViewModel factories ***************\r\n private buildTaxesViewModel(taxesTabs: BillCluster[], annualYearModel: AnnualDetailYear, parcelID: number, parcelAcctNum: string): TaxesViewModel {\r\n const viewModel = new TaxesViewModel();\r\n\r\n viewModel.annualYearModel = annualYearModel;\r\n viewModel.model = taxesTabs;\r\n viewModel.parcelID = parcelID;\r\n viewModel.parcelAcctNum = parcelAcctNum;\r\n\r\n if (viewModel.model.length < 1) {\r\n viewModel.currentTabIndex = -1;\r\n viewModel.currentTab = null;\r\n } else {\r\n this.setTabIndex(viewModel, 0);\r\n }\r\n\r\n return viewModel;\r\n }\r\n\r\n private buildBillViewModel(billViewDTO: BillViewDTO): BillViewModel {\r\n const viewModel = new BillViewModel();\r\n\r\n const billForView: Bill = this.getBillForView(billViewDTO.bill);\r\n //this.getTaskSummariesForBill(billForView);\r\n // TODO: This is copied from getTaskSummariesForTab; this should probably be refactored\r\n viewModel.taskSummariesPromise = this.getTaskSummariesForBill(billForView)\r\n .then(() => {\r\n billForView.showActualCheckbox = billForView.payments[0].taskSummary && !_.some(billForView.payments, (payment: Payment) => {\r\n return !_.isEmpty(payment.taskSummary);\r\n });\r\n });\r\n\r\n viewModel.year = billViewDTO.annualYearView.annualYear1;\r\n viewModel.yearRevisions = billViewDTO.annualYearView.annualGridDetails;\r\n viewModel.model[0] = billForView;\r\n viewModel.hasAvailableTaxSetup = billViewDTO.hasAvailableTaxSetup;\r\n\r\n return viewModel;\r\n }\r\n\r\n private buildRefundViewModel(refund: Refund) {\r\n const viewModel = new RefundViewModel();\r\n\r\n refund.taskSummary = {};\r\n this.getEntityTaskSummaries(refund, REFUND_ENTITY_TYPE_ID, refund.refundID);\r\n\r\n viewModel.year = refund.annualYear.annualYear1;\r\n viewModel.model = refund;\r\n\r\n return viewModel;\r\n }\r\n}\r\n\r\n\r\nexport class TaxesViewModel {\r\n model: BillCluster[];\r\n annualYearModel: AnnualDetailYear;\r\n currentTabIndex: number;\r\n currentTab: BillCluster;\r\n preEditModelBackup: BillCluster;\r\n parcelID: number;\r\n parcelAcctNum: string;\r\n hasWritePermission: boolean;\r\n\r\n resetEdit(force: boolean = false): void {\r\n if (force || this.isDifferentTab()) {\r\n this.preEditModelBackup = _.cloneDeep(this.currentTab) as BillCluster;\r\n }\r\n }\r\n\r\n beginEdit(): void {\r\n if (this.currentTab) {\r\n this.preEditModelBackup = _.cloneDeep(this.currentTab) as BillCluster;\r\n } else {\r\n this.preEditModelBackup = undefined;\r\n }\r\n }\r\n\r\n cancelEdit(): void {\r\n const tempTab = _.cloneDeep(this.currentTab) as BillCluster;\r\n // _.assign(this.currentTab, this.preEditModelBackup);\r\n\r\n this.currentTab.bills = _.map(this.currentTab.bills, (bill: Bill, i: number) => {\r\n bill.taskSummary = tempTab.bills[i].taskSummary;\r\n bill.payments = _.map(bill.payments, (payment: Payment, j: number) => {\r\n payment.taskSummary = tempTab.bills[i].payments[j].taskSummary;\r\n return payment;\r\n });\r\n\r\n return bill;\r\n });\r\n\r\n if (this.currentTab.refund) {\r\n if (tempTab.refund?.taskSummary)\r\n this.currentTab.refund.taskSummary = tempTab.refund.taskSummary;\r\n }\r\n }\r\n\r\n validate(callback: (boolean, string) => void): void {\r\n const errorMessage: string = BillClusterService.validateTaxes(this.currentTab);\r\n\r\n const isValid: boolean = !errorMessage;\r\n callback(isValid, errorMessage);\r\n }\r\n\r\n private isDifferentTab() {\r\n if (!this.currentTab || !this.preEditModelBackup) {\r\n return false;\r\n }\r\n\r\n if (this.currentTab.refund && this.preEditModelBackup.refund) {\r\n return this.currentTab.refund.refundID !== this.preEditModelBackup.refund.refundID;\r\n } else {\r\n return this.currentTab.billClusterID !== this.preEditModelBackup.billClusterID;\r\n }\r\n }\r\n}\r\n\r\nexport class BillViewModel {\r\n constructor() {\r\n this.model = [];\r\n }\r\n\r\n model: Bill[];\r\n hasWritePermission: boolean;\r\n parcelID: number;\r\n parcelAcctNum: string;\r\n tabTitle: string;\r\n year: number;\r\n yearRevisions: AnnualDetailAssessment[];\r\n hasAvailableTaxSetup: boolean;\r\n taskSummariesPromise: Promise;\r\n processingTaxSetupResult?: BillClusterTaxRateSetupModalResult;\r\n intakeAttachmentId?: string;\r\n hasProcessingParcelChanges?: boolean;\r\n\r\n assignFromExistingBill(bill: Bill): void {\r\n if (!this.model.length) {\r\n throw new Error('Invalid attempt to load bill from existing data when no current bill is set');\r\n }\r\n\r\n if (this.model[0].billID !== bill.billID) {\r\n throw new Error(`Invalid attempt to build bill with billID ${ bill.billID\r\n } into bill with billID ${ this.model[0].billID}`);\r\n }\r\n\r\n _.assign(this.model[0], bill);\r\n }\r\n\r\n validate(callback: (boolean, string) => void): void {\r\n const errorMessage: string = BillClusterService.validateBills(this.model);\r\n\r\n callback(!errorMessage, errorMessage);\r\n }\r\n}\r\n\r\nexport class RefundViewModel {\r\n constructor() {\r\n this.model = null;\r\n }\r\n\r\n model: Refund;\r\n hasWritePermission: boolean;\r\n parcelID: number;\r\n parcelAcctNum: string;\r\n tabTitle: string;\r\n year: number;\r\n\r\n assignFromExistingRefund(refund: Refund): void {\r\n if (!this.model) {\r\n throw new Error('Invalid attempt to load refund from existing data when no current refund is set');\r\n }\r\n\r\n if (this.model.refundID !== refund.refundID) {\r\n throw new Error(`Invalid attempt to build refund with refundID ${ refund.refundID\r\n } into refund with refundID ${ this.model.refundID}`);\r\n }\r\n\r\n _.assign(this.model, refund);\r\n }\r\n}\r\n","export class Assessment {\r\n constructor(annualYearID: number, revisionNumber: number, status: number, efAction: string, annualAssessmentDetails: AnnualAssessmentDetail[]) {\r\n this.annualYearID = annualYearID;\r\n this.revisionNum = revisionNumber;\r\n this.status = status;\r\n this.annualAssessmentDetails = annualAssessmentDetails;\r\n this.efAction = efAction;\r\n this.revisionDesc = '';\r\n }\r\n\r\n allocationId: number;\r\n annualAssessmentDetails: AnnualAssessmentDetail[];\r\n annualAssessmentID: number;\r\n annualYearID: number;\r\n revisionNum: number;\r\n status: number;\r\n finalRevision: boolean;\r\n revisionDate: Date;\r\n revisionDesc: string;\r\n hasAttachments: boolean;\r\n appealDeadLineID: number;\r\n appealDeadline: Date;\r\n originalDeadline: Date;\r\n hasComments: boolean;\r\n efAction: string;\r\n rowVersion: any;\r\n annualYearRowVersion: any;\r\n hasInProgressIntakeItems: boolean;\r\n taxableValues: Core.AnnualAssessmentTaxableValue[];\r\n taxAuthoritiesInfo: Core.TaxAuthorityInfo[];\r\n}\r\n\r\nexport class AnnualAssessmentDetail {\r\n assessmentClassComponent: any; //I don't know what this is\r\n assessmentClassRatio: AssessmentClassRatio;\r\n annualAssessmentDetailID: number;\r\n annualAssessmentID: number;\r\n assessmentClassComponentID: number;\r\n assessmentClassRatioID: number;\r\n ratio: number;\r\n displayRatio: number;\r\n assessedValue: number;\r\n fairMarketValue: number;\r\n fmvOverridden: boolean;\r\n componentName: string;\r\n assessmentComponentTypeID: number;\r\n efAction: string;\r\n sequence: number;\r\n}\r\n\r\nexport class AssessmentClassRatio\r\n{\r\n assessmentClassRatioID: number;\r\n assessmentClassID: number;\r\n assessorID: number;\r\n taxYear: number;\r\n assessmentRatio: number;\r\n efAction: string;\r\n}\r\n","import { DecimalPipe } from '@angular/common';\r\nimport { EventEmitter, Injectable } from '@angular/core';\r\nimport { Decimal } from 'decimal.js';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AttachmentModalData, AttachmentModalEntityData } from '../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { AnnualDetailsService } from '../annual-details.service';\r\nimport { AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { AnnualAssessmentDetail, Assessment } from './assessment.model';\r\n\r\nimport { map, sortBy } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\nconst ASSESSMENT_ENTITY_TYPE_ID = 7;\r\n\r\n@Injectable()\r\nexport class AssessmentService {\r\n constructor(\r\n private http: SDHttpService,\r\n private annualDetailsService: AnnualDetailsService,\r\n private decimalPipe: DecimalPipe,\r\n public toastr: ToastrService\r\n ) {}\r\n\r\n getAssessment(assessmentID: number): Promise {\r\n return this.http.get(`/api/annualassessment/${ assessmentID}`);\r\n }\r\n\r\n async getAssessmentViewModelByID(assessmentID: number, assessorID: number, parcelID: number, parcelAcctNum: string, annualYear: AnnualDetailYear): Promise {\r\n const assessment = assessmentID ? await this.getAssessment(assessmentID) : new Assessment(annualYear.annualYearID, 0, 0, 'add', []);\r\n const viewModel = this.buildAssessmentViewModel(assessment);\r\n\r\n viewModel.assessorID = assessorID;\r\n viewModel.parcelID = parcelID;\r\n viewModel.parcelAcctNum = parcelAcctNum;\r\n viewModel.currentYear = annualYear;\r\n\r\n return viewModel;\r\n }\r\n\r\n getAssessmentViewModelByAssessmentID(assessmentID: number): Promise {\r\n return this.http.get(`api/annualassessmentview/assessment/${ assessmentID}`).then((result: AssessmentViewDTO) => {\r\n const vm = this.buildAssessmentViewModel(result.assessment);\r\n vm.assessorID = result.assessorID;\r\n vm.components = result.componentTypes;\r\n vm.currentYear = result.annualYearView;\r\n return vm;\r\n });\r\n }\r\n\r\n getAssessmentComponent(params): Promise {\r\n return this.http.get('/api/AnnualAssessmentDetail', {\r\n params: params\r\n });\r\n }\r\n\r\n saveAssessmentFromViewModel(viewModel: AssessmentViewModel): Promise {\r\n\r\n //if the year's autocalculate has been set to false, it wasn't saved yet, so we must save it\r\n if ((viewModel.dirtyAnnualYear && !viewModel.currentYear.calcProjected) || viewModel.dirtyTargetValue) {\r\n return this.annualDetailsService.saveYear(viewModel.currentYear).then((result) => {\r\n viewModel.currentYear.rowVersion = result.rowVersion;\r\n\r\n const resultModel = _.find(result.annualGridDetails, (detailModel) => {\r\n return detailModel.annualAssessmentID === viewModel.model.annualAssessmentID;\r\n });\r\n\r\n if (resultModel){\r\n viewModel.model.rowVersion = resultModel.rowVersion;\r\n }\r\n\r\n /*\r\n if (viewModel.currentYear.annualGridDetails){\r\n _.forEach(viewModel.currentYear.annualGridDetails, (gridModel) => {\r\n var resultModel = _.find(result.annualGridDetails, (detailModel) => {\r\n return detailModel.annualAssessmentID === gridModel.annualAssessmentID;\r\n });\r\n\r\n if (resultModel){\r\n gridModel.rowVersion = resultModel.rowVersion;\r\n }\r\n })\r\n }\r\n */\r\n\r\n // NOTE: It may look like we want \"viewModel.dirtyAnnualYear = false;\" here, but the dirty flag\r\n // should tell the grid to reload the year later on, so we don't want to reset that flag yet\r\n viewModel.dirtyAnnualYear = false;\r\n viewModel.dirtyTargetValue = false;\r\n return this.saveAssessment(this.prepareAssessmentForSave(viewModel.model));\r\n });\r\n }\r\n\r\n return this.saveAssessment(this.prepareAssessmentForSave(viewModel.model));\r\n }\r\n\r\n deleteAssessment(assessmentID: number): Promise {\r\n return this.http.delete(`/api/AnnualAssessment/${ assessmentID}`);\r\n }\r\n\r\n cancelAssessmentEdit(viewModel: AssessmentViewModel): void {\r\n viewModel.cancelEdit();\r\n }\r\n\r\n prepareAssessmentForSave(annualAssessment: Assessment): Assessment {\r\n const annualAssessmentCopy = _.cloneDeep(annualAssessment);\r\n\r\n annualAssessmentCopy.annualAssessmentDetails = annualAssessmentCopy.annualAssessmentDetails.map((comp) => {\r\n if (!comp.fmvOverridden) {\r\n comp.fairMarketValue = null;\r\n }\r\n\r\n comp.ratio = comp.ratio === comp.assessmentClassRatio.assessmentRatio ? null : comp.ratio;\r\n return comp;\r\n });\r\n\r\n if (this.areDeadlinesEqual(annualAssessmentCopy)) {\r\n annualAssessmentCopy.appealDeadline = null;\r\n }\r\n\r\n return annualAssessmentCopy;\r\n }\r\n\r\n areDeadlinesEqual(assessment: Assessment): boolean {\r\n const appeal = new Date(assessment.appealDeadline);\r\n const original = new Date(assessment.originalDeadline);\r\n\r\n if (appeal && original) {\r\n return appeal.getFullYear() === original.getFullYear() &&\r\n appeal.getMonth() === original.getMonth() &&\r\n appeal.getDate() === original.getDate();\r\n } else {\r\n return !appeal && !original;\r\n }\r\n }\r\n\r\n saveAssessment(assessment: Assessment): Promise {\r\n let totalAV: Decimal = new Decimal(0);\r\n\r\n _.forEach(assessment.annualAssessmentDetails, (assessmentDetail: AnnualAssessmentDetail) => {\r\n totalAV = totalAV.add(assessmentDetail.assessedValue);\r\n });\r\n\r\n if(totalAV.toNumber() < 0) {\r\n return Promise.reject(new Error('Cannot save assessment with negative assessed value'));\r\n } else {\r\n return this.http.put('/api/annualassessment/', assessment);\r\n }\r\n }\r\n\r\n toggleAssessmentEdit(viewModel: AssessmentViewModel, editMode: boolean): void {\r\n if (editMode) {\r\n viewModel.beginEdit();\r\n }\r\n }\r\n\r\n prepareAnnualAssessmentForCreate(annualAssessment: Assessment): Assessment {\r\n const annualAssessmentCopy: Assessment = _.cloneDeep(annualAssessment);\r\n\r\n annualAssessmentCopy.annualAssessmentDetails = annualAssessmentCopy.annualAssessmentDetails\r\n .filter((item) => {\r\n return item.efAction !== 'delete';\r\n })\r\n .map((comp) => {\r\n if (!comp.fmvOverridden) {\r\n comp.fairMarketValue = null;\r\n }\r\n\r\n comp.ratio = comp.ratio === comp.assessmentClassRatio.assessmentRatio ? null : comp.ratio;\r\n return comp;\r\n });\r\n\r\n if (this.areDeadlinesEqual(annualAssessmentCopy)) {\r\n annualAssessmentCopy.appealDeadline = null;\r\n }\r\n\r\n return annualAssessmentCopy;\r\n }\r\n\r\n //This function is basically the opposite of prepareAssessmentForSave\r\n prepareAnnualAssessment(annualAssessment: Assessment): Assessment {\r\n annualAssessment.annualAssessmentDetails = _.flow([\r\n map(function (comp) {\r\n //Prepare Ratio\r\n if(comp.ratio === null) {\r\n comp.ratio = comp.assessmentClassRatio.assessmentRatio;\r\n }\r\n\r\n //Prepare FMV\r\n if (comp.fairMarketValue) {\r\n comp.fmvOverridden = true;\r\n } else {\r\n comp.fairMarketValue = new Decimal(comp.assessedValue).dividedBy(comp.ratio).round().toNumber();\r\n }\r\n return comp;\r\n }),\r\n sortBy('sequence')\r\n ])(annualAssessment.annualAssessmentDetails);\r\n\r\n //Prepare appeal deadline\r\n if(annualAssessment.appealDeadline === null) {\r\n annualAssessment.appealDeadline = annualAssessment.originalDeadline;\r\n }\r\n\r\n return annualAssessment;\r\n }\r\n\r\n private buildAssessmentViewModel(result: Assessment) {\r\n const viewModel = new AssessmentViewModel(this, this.decimalPipe);\r\n viewModel.model = this.prepareAnnualAssessment(result);\r\n\r\n return viewModel;\r\n }\r\n\r\n}\r\n\r\n\r\nexport class AssessmentViewModel {\r\n constructor(private assessmentService: AssessmentService, private decimalPipe: DecimalPipe) {}\r\n\r\n model: Assessment;\r\n isLastAssessment: boolean;\r\n assessorID: number;\r\n parcelID: number;\r\n parcelAcctNum: string;\r\n components: any[];\r\n currentYear: AnnualDetailYear;\r\n // TODO: Consider refactoring this; when originally built, auto-calculate was the only thing from AnnualYear\r\n // being updated in assessment. Now there's target value, and more may come later. We're handling those fields\r\n // separately, but we could unify that. For now, \"dirtyAnnualYear\" means that autoCalc has changed.\r\n dirtyAnnualYear: boolean;\r\n dirtyTargetValue: boolean;\r\n commentModalData: CommentModalData;\r\n attachmentModalData: AttachmentModalData;\r\n hasWritePermission: boolean;\r\n AssessmentChanged: EventEmitter;\r\n\r\n private preEditModelBackup: Assessment;\r\n // The targetValue is a property on the year, so it needs to get backed up separately\r\n private preEditTargetValueBackup: number;\r\n\r\n beginEdit(): void {\r\n if (this.model) {\r\n this.preEditModelBackup = _.cloneDeep(this.model) as Assessment;\r\n this.preEditTargetValueBackup = this.currentYear.targetValue;\r\n }\r\n else {\r\n this.preEditModelBackup = undefined;\r\n this.preEditTargetValueBackup = undefined;\r\n }\r\n }\r\n\r\n //used to re-set the backup in cases like autosave when we need to re-set\r\n // the backup outside of starting edit\r\n setEditBackup(): void {\r\n _.assign(this.preEditModelBackup, this.model);\r\n }\r\n\r\n cancelEdit(): void {\r\n //if the year has changed, aka if autocalc has changed, change it back\r\n //we only save the year if we change TO calc, because this generates the numbers\r\n //this is done poorly but we are restricted by how auto calculate works\r\n //so this is basically \"if changed and true, make it false and save\"\r\n if(this.dirtyAnnualYear && !this.currentYear.calcProjected) {\r\n this.currentYear.calcProjected = true;\r\n //this.annualDetailsService.saveYear(this.currentYear);\r\n\r\n this.dirtyAnnualYear = false;\r\n this.dirtyTargetValue = false;\r\n }\r\n this.currentYear.targetValue = this.preEditTargetValueBackup;\r\n _.assign(this.model, this.preEditModelBackup);\r\n if(this.AssessmentChanged) {\r\n this.AssessmentChanged.emit(this.model);\r\n }\r\n }\r\n\r\n attachmentIcon(hasAttachments): string {\r\n return hasAttachments ? 'fa-files-o' : 'fa-paperclip';\r\n }\r\n\r\n assignFromExistingAssessment(assessment: Assessment): void {\r\n if (!this.model) {\r\n throw new Error('Invalid attempt to load assessment from existing data when no current assessment is set');\r\n }\r\n\r\n\r\n\r\n if (this.model.annualAssessmentID !== assessment.annualAssessmentID) {\r\n throw new Error(`Invalid attempt to map assessment with assessmentID ${ assessment.annualAssessmentID\r\n } into assessment with assessmentID ${ this.model.annualAssessmentID}`);\r\n }\r\n\r\n _.assign(this.model, this.assessmentService.prepareAnnualAssessment(assessment));\r\n }\r\n\r\n isActual(): boolean {\r\n return this.model.status === 1;\r\n }\r\n\r\n updateModalData(): void {\r\n const assessment = this.model;\r\n //let appealLevel = this.appealLevelAbbrDisplay(appeal.appealLevelID);\r\n const description = `${+this.currentYear.annualYear1 } - ${ assessment.revisionDesc}`;\r\n\r\n // comment data\r\n this.commentModalData = new CommentModalData();\r\n this.commentModalData.entityID = assessment.annualAssessmentID;\r\n this.commentModalData.entityTypeID = ASSESSMENT_ENTITY_TYPE_ID;\r\n this.commentModalData.canEdit = this.hasWritePermission;\r\n this.commentModalData.parcelID = this.parcelID;\r\n this.commentModalData.parcelAcctNum = this.parcelAcctNum;\r\n this.commentModalData.description = description;\r\n this.commentModalData.year = this.currentYear.annualYear1.toString();\r\n\r\n // attachment data\r\n this.attachmentModalData = new AttachmentModalData();\r\n this.attachmentModalData.belowParcelEntity = new AttachmentModalEntityData();\r\n this.attachmentModalData.belowParcelEntity.id = assessment.annualAssessmentID;\r\n this.attachmentModalData.belowParcelEntity.typeId = ASSESSMENT_ENTITY_TYPE_ID;\r\n this.attachmentModalData.belowParcelEntity.name = assessment.revisionDesc;\r\n this.attachmentModalData.entityType = 'Assessment';\r\n this.attachmentModalData.parentId = this.parcelID;\r\n this.attachmentModalData.parentType = 'Parcel';\r\n this.attachmentModalData.entityName = this.parcelAcctNum;\r\n this.attachmentModalData.entityDescription = description;\r\n this.attachmentModalData.year = this.currentYear.annualYear1;\r\n }\r\n\r\n recalculateVariables() {\r\n if (this.currentYear) {\r\n // \"First\" in array order is the leftmost on the grid, so it's actually the last one chronologically\r\n const lastAssessment = _.head(this.currentYear.annualGridDetails);\r\n this.isLastAssessment = lastAssessment.annualAssessmentID === this.model.annualAssessmentID;\r\n }\r\n\r\n this.model.annualAssessmentDetails = _.map(this.model.annualAssessmentDetails, (component) => {\r\n component.displayRatio = +this.decimalPipe.transform(component.ratio * 100, '1.3-3');\r\n return component;\r\n });\r\n }\r\n\r\n}\r\n\r\n//This is for retrieving all data for the assessment when we're loading it outside the grid\r\nexport class AssessmentViewDTO {\r\n annualYearView: AnnualDetailYear;\r\n assessment: Assessment;\r\n assessorID: number;\r\n componentTypes: any[];\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { AttachmentModalData, AttachmentModalEntityData } from '../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { Filing, FilingType } from './compliance.model';\r\nimport * as _ from 'lodash';\r\n\r\nexport class FilingViewDTO {\r\n annualYearView: AnnualDetailYear;\r\n filings: Filing[];\r\n}\r\n\r\n@Injectable()\r\nexport class ComplianceService {\r\n constructor(\r\n private http: SDHttpService,\r\n private taskService: TaskService) { }\r\n\r\n private _filingBatches: Compliance.FilingBatchInfoModel[] = [];\r\n\r\n getFiling(filingId: number): Promise {\r\n return this.http.get(`/api/filing/${filingId}`);\r\n }\r\n\r\n getFilingBatchInfo(filingBatchId: number): Promise {\r\n return this.http.get(`/api/filingBatch/${filingBatchId}/info`);\r\n }\r\n\r\n getFilingBatchInfoForAnnualYear(annualYearId: number): Promise {\r\n return this.http.get(`/api/filingBatch/annualYear/${annualYearId}`);\r\n }\r\n\r\n getFilingsForAnnualYear(annualYearId: number): Promise {\r\n return this.http.get(`/api/filing/annualYear/${annualYearId}`);\r\n }\r\n\r\n getAvailablePriorFilings(filingId: number,): Promise {\r\n return this.http.get(`/api/filing/${filingId}/priorreturn`);\r\n }\r\n\r\n createFilingBatch(updateModel: Compliance.FilingReturnUpdateModel): Promise {\r\n return this.http.post('/api/filingBatch/fromFiling', updateModel);\r\n }\r\n\r\n createFiling(filing: Filing): Promise {\r\n return this.http.post('/api/filing', filing);\r\n }\r\n\r\n updateFiling(filing: Filing): Promise {\r\n return this.http.put('/api/filing', filing);\r\n }\r\n\r\n deleteFiling(filingId: number): Promise {\r\n return this.http.delete(`/api/filing/${filingId}`);\r\n }\r\n\r\n getFilingView(filingId: number): Promise {\r\n return this.http.get(`/api/annualassessmentview/filing/${filingId}`);\r\n }\r\n\r\n getFilingTypes(): Promise {\r\n return this.http.get('/api/filingType');\r\n }\r\n\r\n getFilingTypesByParcel(parcelId: number): Promise {\r\n return this.http.get(`/api/filingtype/parcel/${parcelId}`);\r\n }\r\n\r\n getReturnForFiling(filingId: number): Promise {\r\n return this.http.get(`/api/return/filing/${filingId}`);\r\n }\r\n\r\n //****************** End API Calls ******************\r\n isInFilingBatch(filing: Filing): boolean {\r\n return filing.filingBatchId && this._filingBatches.find(x => x.filingBatchId === filing.filingBatchId) ? true : false;\r\n }\r\n\r\n getFilingBatch(filing): Compliance.FilingBatchInfoModel {\r\n if (this._filingBatches &&\r\n this._filingBatches.length &&\r\n filing &&\r\n filing.filingBatchId) {\r\n const filingBatch = this._filingBatches.find(x => x.filingBatchId === filing.filingBatchId);\r\n return filingBatch;\r\n } else {\r\n return null;\r\n }\r\n }\r\n\r\n getTaskEntityType(filing: Filing): number {\r\n return this.isInFilingBatch(filing) ? Core.EntityTypes.FilingBatch : Core.EntityTypes.Filing;\r\n }\r\n\r\n getTaskEntityId(filing: Filing): number {\r\n return this.isInFilingBatch(filing) ? filing.filingBatchId : filing.filingId;\r\n }\r\n\r\n getReturnStatusCode(filing: Filing): string {\r\n if (!(this._filingBatches && this._filingBatches.length)) {\r\n return null;\r\n }\r\n\r\n if (!(filing && filing.filingBatchId)) {\r\n return null;\r\n }\r\n\r\n const filingBatch = this._filingBatches.find(x => x.filingBatchId === filing.filingBatchId);\r\n\r\n if (!filingBatch) {\r\n return null;\r\n }\r\n\r\n return filingBatch.statusCode;\r\n }\r\n\r\n setCurrentFiling(viewModel: ComplianceViewModel, filingId: number): void {\r\n const filingIndex = _.findIndex(viewModel.model, (filing) => {\r\n return filing.filingId === filingId;\r\n });\r\n\r\n if (filingIndex >= 0) {\r\n this.setFilingIndex(viewModel, filingIndex);\r\n }\r\n }\r\n\r\n async setFilingIndex(viewModel: ComplianceViewModel, filingIndex: number, force: boolean = false): Promise {\r\n if (force || viewModel.currentFilingIndex !== filingIndex) {\r\n viewModel.currentFilingIndex = filingIndex;\r\n viewModel.currentFiling = viewModel.model[filingIndex];\r\n viewModel.resetEdit();\r\n viewModel.updateModalData();\r\n\r\n const [filingBatches, returns] = await Promise.all(\r\n [\r\n this.getFilingBatchInfoForAnnualYear(viewModel.annualYearModel.annualYearID),\r\n this.getReturnForFiling(viewModel.currentFiling.filingId)\r\n ]);\r\n\r\n this._filingBatches = filingBatches;\r\n\r\n if (returns && returns.length) {\r\n viewModel.currentReturn = returns[0];\r\n }\r\n\r\n await this.loadTaskSummary(viewModel);\r\n\r\n await this.loadFilingBatch(viewModel);\r\n }\r\n }\r\n\r\n addNewFilingToViewModel(viewModel: ComplianceViewModel, filing: Filing): Promise {\r\n const originalModel = viewModel.model || [];\r\n viewModel.model = [];\r\n // HACK: For whatever reason, ngx-bootstrap's tab control didn't handle this\r\n // correctly without the setTimeout; this gives it time to \"breathe\" after resetting\r\n // the list\r\n return new Promise(resolve => {\r\n setTimeout(() => {\r\n originalModel.unshift(filing);\r\n viewModel.model = originalModel;\r\n this.setFilingIndex(viewModel, 0, true);\r\n resolve(filing);\r\n }, 1);\r\n });\r\n }\r\n\r\n saveFilingFromViewModel(viewModel: ComplianceViewModel): Promise {\r\n return this.updateFiling(viewModel.currentFiling);\r\n }\r\n\r\n cancelFilingEdit(viewModel: ComplianceViewModel): void {\r\n viewModel.cancelEdit();\r\n }\r\n\r\n toggleFilingEdit(viewModel: ComplianceViewModel, editMode: boolean): void {\r\n if (editMode) {\r\n viewModel.beginEdit();\r\n }\r\n }\r\n\r\n async loadTaskSummary(viewModel: ComplianceViewModel): Promise {\r\n viewModel.currentTaskSummary = null;\r\n\r\n const entityId = this.getTaskEntityId(viewModel.currentFiling);\r\n const entityType = this.getTaskEntityType(viewModel.currentFiling);\r\n\r\n // get the task series from the filing batch if in a batch\r\n const taskSummary = await this.taskService.getTaskSummaryByEntity(entityId, entityType);\r\n\r\n // If we've navigated to another appeal by the time this happens, don't pay attention to the result\r\n const currentEntityId = this.getTaskEntityId(viewModel.currentFiling);\r\n\r\n if (entityId === currentEntityId) {\r\n viewModel.currentTaskSummary = taskSummary[0];\r\n }\r\n }\r\n\r\n async loadFilingBatch(viewModel: ComplianceViewModel): Promise {\r\n viewModel.currentFiling.filingBatch = null;\r\n\r\n if (this.isInFilingBatch(viewModel.currentFiling)) {\r\n viewModel.currentFiling.filingBatch = await this.getFilingBatchInfo(viewModel.currentFiling.filingBatchId);\r\n }\r\n }\r\n\r\n //*************** ViewModel factories ***************\r\n async getComplianceViewModelByYear(annualYearModel: AnnualDetailYear, parcelId: number, masterParcelId: number, parcelLinkageTypeId: number, parcelAcctNum: string, consolidatingTypeId?: number, consolidatedParcelId?: number, defaultFilingId?: number): Promise {\r\n const filings = await this.getFilingsForAnnualYear(annualYearModel.annualYearID);\r\n const filingTypes = await this.getFilingTypes();\r\n\r\n const viewModel = await this._buildComplianceViewModel(filings, filingTypes, annualYearModel, parcelId, masterParcelId, parcelLinkageTypeId, parcelAcctNum, consolidatingTypeId, consolidatedParcelId);\r\n viewModel.defaultFilingId = defaultFilingId;\r\n viewModel.showAllocationButton = true;\r\n\r\n this.setCurrentFiling(viewModel, viewModel.defaultFilingId);\r\n\r\n return viewModel;\r\n }\r\n\r\n async getComplianceViewModelByFilingId(filingId: number): Promise {\r\n const filingView = await this.getFilingView(filingId);\r\n const filingTypes = await this.getFilingTypes();\r\n\r\n const viewModel = await this._buildComplianceViewModel(filingView.filings, filingTypes, filingView.annualYearView, null, null, null, null, null);\r\n viewModel.defaultFilingId = filingId;\r\n viewModel.showAllocationButton = false;\r\n\r\n this.setCurrentFiling(viewModel, filingId);\r\n viewModel.showTabs = false;\r\n\r\n return viewModel;\r\n }\r\n\r\n private async _buildComplianceViewModel(filings: Filing[], filingTypes: FilingType[], annualYearModel: AnnualDetailYear, parcelID: number, masterParcelId: number, parcelLinkageTypeId: number, parcelAcctNum: string, consolidatingTypeId?: number, consolidatedParcelId?: number): Promise {\r\n const viewModel = new ComplianceViewModel();\r\n viewModel.filingTypes = filingTypes;\r\n viewModel.annualYearModel = annualYearModel;\r\n viewModel.model = filings;\r\n viewModel.showTabs = true;\r\n viewModel.parcelID = parcelID;\r\n viewModel.masterParcelId = masterParcelId;\r\n viewModel.parcelLinkageTypeId = parcelLinkageTypeId;\r\n viewModel.consolidatingTypeId = consolidatingTypeId;\r\n viewModel.consolidatedParcelId = consolidatedParcelId;\r\n viewModel.parcelAcctNum = parcelAcctNum;\r\n\r\n if (viewModel.model.length < 1) {\r\n viewModel.currentFilingIndex = -1;\r\n viewModel.currentFiling = null;\r\n }\r\n else {\r\n await this.setFilingIndex(viewModel, 0);\r\n }\r\n\r\n return viewModel;\r\n }\r\n //************* End ViewModel factories *************\r\n}\r\n\r\nexport class ComplianceViewModel {\r\n\r\n constructor() {\r\n this.hasWritePermission = false;\r\n this.dueDateValid = true;\r\n this.resetDateTimeHandler = null;\r\n }\r\n\r\n model: Filing[];\r\n defaultFilingId: number;\r\n annualYearModel: AnnualDetailYear;\r\n currentTaskSummary: any;\r\n currentFilingIndex: number;\r\n currentFiling: Filing;\r\n currentReturn: Compliance.ReturnModel;\r\n filingTypes: FilingType[] = [];\r\n parcelID: number;\r\n masterParcelId: number;\r\n parcelLinkageTypeId: number;\r\n consolidatingTypeId?: number;\r\n consolidatedParcelId?: number;\r\n parcelAcctNum: string;\r\n showTabs: boolean;\r\n commentModalData: CommentModalData;\r\n attachmentModalData: AttachmentModalData;\r\n hasWritePermission: boolean;\r\n dueDateValid: boolean;\r\n filingBatchId?: number;\r\n resetDateTimeHandler: () => void;\r\n showAllocationButton: boolean;\r\n private preEditModelBackup: Filing;\r\n\r\n resetEdit(force: boolean = false): void {\r\n if (force || (this.currentFiling &&\r\n this.preEditModelBackup &&\r\n this.currentFiling.filingId !== this.preEditModelBackup.filingId)) {\r\n this.preEditModelBackup = _.cloneDeep(this.currentFiling) as Filing;\r\n\r\n if (this.resetDateTimeHandler) {\r\n this.resetDateTimeHandler();\r\n }\r\n }\r\n }\r\n\r\n cancelEdit(): void {\r\n if (this.currentFiling.filingId === this.preEditModelBackup.filingId) {\r\n _.assign(this.currentFiling, this.preEditModelBackup);\r\n if (this.resetDateTimeHandler) {\r\n this.resetDateTimeHandler();\r\n }\r\n }\r\n else {\r\n throw new Error(`Sanity check failed; attempted to restore backup with different filing ID than current. Current filing ID: ${\r\n this.currentFiling.filingId }, backup filing ID: + ${ this.preEditModelBackup.filingId}`);\r\n }\r\n }\r\n\r\n beginEdit(): void {\r\n if (this.currentFiling) {\r\n this.preEditModelBackup = _.cloneDeep(this.currentFiling) as Filing;\r\n if (this.resetDateTimeHandler) {\r\n this.resetDateTimeHandler();\r\n }\r\n }\r\n else {\r\n this.preEditModelBackup = undefined;\r\n if (this.resetDateTimeHandler) {\r\n this.resetDateTimeHandler();\r\n }\r\n }\r\n }\r\n\r\n assignFromExistingFiling(filing: Filing): void {\r\n if (!this.currentFiling) {\r\n throw new Error('Invalid attempt to load filing from existing data when no current filing is set');\r\n }\r\n\r\n if (this.currentFiling.filingId !== filing.filingId) {\r\n throw new Error(`Invalid attempt to filing filing with filingID ${filing.filingId} into filing with filingID ${this.currentFiling.filingId}`);\r\n }\r\n\r\n _.assign(this.currentFiling, filing);\r\n if (this.resetDateTimeHandler) {\r\n this.resetDateTimeHandler();\r\n }\r\n }\r\n\r\n setParcelDetails(parcelId: number, parcelAcctNum: string): void {\r\n this.parcelID = parcelId;\r\n this.parcelAcctNum = parcelAcctNum;\r\n this.updateModalData();\r\n }\r\n\r\n updateModalData(): void {\r\n const filing = this.currentFiling;\r\n\r\n if (!filing) {\r\n return;\r\n }\r\n\r\n const filingType = _.find(this.filingTypes, x => x.filingTypeId === filing.filingTypeId);\r\n const name = `${filing.description } ${ filingType.name}`;\r\n const description = `${this.annualYearModel.annualYear1 } - ${ name}`;\r\n\r\n // comment data\r\n this.commentModalData = new CommentModalData();\r\n this.commentModalData.entityID = filing.filingId;\r\n this.commentModalData.entityTypeID = Core.EntityTypes.Filing;\r\n this.commentModalData.canEdit = this.hasWritePermission && !filing.isFromConsolidatedParcel;\r\n this.commentModalData.parcelID = this.parcelID;\r\n this.commentModalData.parcelAcctNum = this.parcelAcctNum;\r\n this.commentModalData.description = description;\r\n this.commentModalData.year = this.annualYearModel.annualYear1.toString();\r\n\r\n // attachment data\r\n this.attachmentModalData = new AttachmentModalData();\r\n this.attachmentModalData.belowParcelEntity = new AttachmentModalEntityData();\r\n this.attachmentModalData.belowParcelEntity.id = filing.filingId;\r\n this.attachmentModalData.belowParcelEntity.typeId = Core.EntityTypes.Filing;\r\n this.attachmentModalData.belowParcelEntity.name = name;\r\n this.attachmentModalData.entityType = 'Filing';\r\n this.attachmentModalData.parentId = this.parcelID;\r\n this.attachmentModalData.parentType = 'Parcel';\r\n this.attachmentModalData.entityName = this.parcelAcctNum;\r\n this.attachmentModalData.entityDescription = description;\r\n this.attachmentModalData.year = this.annualYearModel.annualYear1;\r\n this.attachmentModalData.readOnly = filing.isFromConsolidatedParcel;\r\n }\r\n\r\n validate(callback: (boolean, string) => void): void {\r\n const invalidTimes: string[] = [];\r\n\r\n // For now I believe this is only possible by entering a date but not a time\r\n // TODO: Write this in a less crappy way\r\n\r\n if(!_.trim(this.currentFiling.description)) {\r\n callback(false, 'Description is Required');\r\n return;\r\n }\r\n\r\n if (!this.dueDateValid) {\r\n invalidTimes.push('Due Date');\r\n }\r\n\r\n switch (invalidTimes.length) {\r\n case 0:\r\n callback(true, '');\r\n break;\r\n case 1:\r\n callback(false, `${invalidTimes[0] } not valid`);\r\n break;\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { AttachmentModalData, AttachmentModalEntityData } from '../../Attachment/attachment.modal.model';\r\nimport * as _ from 'lodash';\r\nimport { EntityType } from '../../constants.new';\r\n\r\n@Injectable()\r\nexport class AnnualBudgetService {\r\n constructor(private http: HttpClient) {\r\n }\r\n\r\n\r\n // CRUD Operations\r\n getAnnualBudget(annualBudgetId: number): Promise {\r\n return lastValueFrom(this.http.get(`/api/AnnualBudget/${ annualBudgetId}`));\r\n }\r\n updateAnnualBudget(annualBudget: Core.AnnualBudgetDTO): Promise {\r\n return lastValueFrom(this.http.put('/api/AnnualBudget', annualBudget));\r\n }\r\n\r\n deleteAnnualBudget(annualBudgetId: number): Promise {\r\n return lastValueFrom(this.http.delete(`/api/AnnualBudget/${annualBudgetId}`));\r\n }\r\n\r\n addAnnualBudget(parcelId: number, year: number, companyBudgetId: number): Promise {\r\n return lastValueFrom(this.http.post('/api/AnnualBudget/', {\r\n parcelID: parcelId,\r\n taxYear: year,\r\n companyBudgetId: companyBudgetId\r\n }));\r\n }\r\n\r\n getAvailableBudgets(year: number, parcelId: number): Promise {\r\n return lastValueFrom(this.http.get(`api/AnnualBudget/Available/Parcel/${parcelId}/Year/${year}`));\r\n }\r\n\r\n getAvailableCompanyBudgets(parcelId: number): Promise<[Core.AvailableCompanyBudget]> {\r\n return lastValueFrom(this.http.get<[Core.AvailableCompanyBudget]>(`api/CompanyBudget/Available/${EntityType.Parcel}/${parcelId}?excludeFrozen=true`));\r\n }\r\n\r\n\r\n saveAnnualBudgetFromViewModel(viewModel: AnnualBudgetViewModel): Promise {\r\n return this.updateAnnualBudget(viewModel.model);\r\n }\r\n\r\n cancelBudgetEdit(viewModel: AnnualBudgetViewModel): void {\r\n viewModel.cancelEdit();\r\n }\r\n\r\n toggleAnnualBudgetEdit(viewModel: AnnualBudgetViewModel, editMode: boolean): void {\r\n if (editMode) {\r\n viewModel.beginEdit();\r\n }\r\n }\r\n\r\n async getAnnualBudgetViewModelByID(annualYearModel: AnnualDetailYear, annualBudgetId: number, parcelID: number, parcelAcctNum: string): Promise {\r\n let viewModel: AnnualBudgetViewModel;\r\n\r\n if(annualBudgetId > 0) {\r\n const annualBudget = await this.getAnnualBudget(annualBudgetId);\r\n viewModel = this.buildAnnualBudgetViewModel(annualBudget);\r\n } else {\r\n viewModel = new AnnualBudgetViewModel();\r\n }\r\n\r\n viewModel.parcelID = parcelID;\r\n viewModel.parcelAcctNum = parcelAcctNum;\r\n viewModel.annualYearModel = annualYearModel;\r\n\r\n return viewModel;\r\n }\r\n\r\n private buildAnnualBudgetViewModel(annualBudget: Core.AnnualBudgetDTO) {\r\n const viewModel = new AnnualBudgetViewModel();\r\n viewModel.model = annualBudget;\r\n\r\n return viewModel;\r\n }\r\n}\r\n\r\n\r\nexport class AnnualBudgetViewModel {\r\n constructor() {\r\n // This will be set by the appeal component when loaded\r\n this.hasWritePermission = false;\r\n }\r\n\r\n model: Core.AnnualBudgetDTO;\r\n annualYearModel: AnnualDetailYear;\r\n parcelID: number;\r\n parcelAcctNum: string;\r\n commentModalData: CommentModalData;\r\n attachmentModalData: AttachmentModalData;\r\n hasWritePermission: boolean;\r\n private preEditModelBackup: Core.AnnualBudgetDTO;\r\n\r\n\r\n resetEdit(force: boolean = false): void {\r\n if (force || (this.model &&\r\n this.preEditModelBackup &&\r\n this.model.annualBudgetId !== this.preEditModelBackup.annualBudgetId)) {\r\n this.preEditModelBackup = _.cloneDeep(this.model);\r\n console.log(['Creating preEditModelBackup', this.preEditModelBackup]);\r\n }\r\n }\r\n\r\n cancelEdit(): void {\r\n if (this.model.annualBudgetId === this.preEditModelBackup.annualBudgetId) {\r\n _.assign(this.model, this.preEditModelBackup);\r\n }\r\n else {\r\n throw new Error(`Sanity check failed; attempted to restore backup with different annual budget Id than current. Current annual budget Id: ${\r\n this.model.annualBudgetId }, backup annual budget Id: + ${ this.preEditModelBackup.annualBudgetId}`);\r\n }\r\n }\r\n\r\n beginEdit(): void {\r\n if (this.model) {\r\n this.preEditModelBackup = _.cloneDeep(this.model);\r\n }\r\n else {\r\n this.preEditModelBackup = undefined;\r\n }\r\n }\r\n\r\n assignFromExistingFiling(annualBudget: Core.AnnualBudgetDTO): void {\r\n if (!this.model) {\r\n throw new Error('Invalid attempt to load annualBudget from existing data when no current annualBudget is set');\r\n }\r\n\r\n if (this.model.annualBudgetId !== annualBudget.annualBudgetId) {\r\n throw new Error(`Invalid attempt to annualBudget annualBudget with annualBudgetId ${ annualBudget.annualBudgetId\r\n } into annualBudget with annualBudgetId ${ this.model.annualBudgetId}`);\r\n }\r\n\r\n _.assign(this.model, annualBudget);\r\n }\r\n\r\n setParcelDetails(parcelID: number, parcelAcctNum: string): void {\r\n this.parcelID = parcelID;\r\n this.parcelAcctNum = parcelAcctNum;\r\n this.updateModalData();\r\n }\r\n\r\n updateModalData(): void {\r\n const budget = this.model;\r\n\r\n if (budget) {\r\n // let filingType = _.find(this.filingTypes, {filingTypeId: budget.filingTypeId}) || {};\r\n const name = `${budget.budgetName } Budget`;\r\n let description = name;\r\n if(budget.description) {\r\n description += ` - ${budget.description}`;\r\n }\r\n\r\n // comment data\r\n this.commentModalData = new CommentModalData();\r\n this.commentModalData.entityID = budget.annualBudgetId;\r\n this.commentModalData.entityTypeID = EntityType.Budget;\r\n this.commentModalData.canEdit = this.hasWritePermission;\r\n this.commentModalData.parcelID = this.parcelID;\r\n this.commentModalData.parcelAcctNum = this.parcelAcctNum;\r\n this.commentModalData.description = description;\r\n this.commentModalData.year = this.annualYearModel.annualYear1.toString();\r\n\r\n // attachment data\r\n this.attachmentModalData = new AttachmentModalData();\r\n this.attachmentModalData.belowParcelEntity = new AttachmentModalEntityData();\r\n this.attachmentModalData.belowParcelEntity.id = budget.annualBudgetId;\r\n this.attachmentModalData.belowParcelEntity.typeId = EntityType.Budget;\r\n this.attachmentModalData.belowParcelEntity.name = name;\r\n this.attachmentModalData.entityType = 'Budget';\r\n this.attachmentModalData.parentId = this.parcelID;\r\n this.attachmentModalData.parentType = 'Parcel';\r\n this.attachmentModalData.entityName = this.parcelAcctNum;\r\n this.attachmentModalData.entityDescription = description;\r\n this.attachmentModalData.year = this.annualYearModel.annualYear1;\r\n this.attachmentModalData.readOnly = this.hasWritePermission;\r\n }\r\n }\r\n\r\n validate(callback: (boolean, string) => void): void {\r\n callback(true, '');\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { NavigationService } from '../Layout/navigation.service';\r\nimport { AnnualDetailsNavigationEventService } from './annual-details-event.service';\r\nimport { AnnualDetailsService } from './annual-details.service';\r\nimport { AnnualDetailAssessment, AnnualDetailYear } from './Annual-Year/annual-year.model';\r\nimport { AppealService, AppealViewModel } from './Appeals/appeal.service';\r\nimport { Assessment } from './Assessments/assessment.model';\r\nimport { AssessmentService, AssessmentViewModel } from './Assessments/assessment.service';\r\nimport { ComplianceService, ComplianceViewModel } from './Compliance/compliance.service';\r\nimport { BillCluster } from './Taxes/bill-cluster.model';\r\nimport { BillClusterService, TaxesViewModel } from './Taxes/bill-cluster.service';\r\nimport { Bill } from './Taxes/bill.model';\r\nimport { AnnualBudgetService, AnnualBudgetViewModel } from './Budget/budget.details.service';\r\n\r\ndeclare const _: any;\r\n\r\nexport enum ViewTarget { grid, appeal, assessment, tax, compliance, budget }\r\n\r\n@Injectable()\r\nexport class AnnualDetailsNavigationService {\r\n constructor(private appealService: AppealService,\r\n private billClusterService: BillClusterService,\r\n private assessmentService: AssessmentService,\r\n private complianceService: ComplianceService,\r\n private annualBudgetService: AnnualBudgetService,\r\n private annualDetailsService: AnnualDetailsService,\r\n private navigationService: NavigationService,\r\n private navigationEvent: AnnualDetailsNavigationEventService) { }\r\n\r\n createNavigationState(years: AnnualDetailYear[], parcelID: number, masterParcelId: number, parcelLinkageTypeId: number, consolidatingTypeId: number, consolidatedParcelId: number, parcelAcctNum: string, stateID: number, assessorID: number, hasWritePermission: boolean): NavigationState {\r\n const navigationState = new NavigationState(years,\r\n this.appealService,\r\n this.billClusterService,\r\n this.assessmentService,\r\n this.complianceService,\r\n this.annualBudgetService,\r\n this.annualDetailsService,\r\n this.navigationService,\r\n this.navigationEvent,\r\n parcelID,\r\n masterParcelId,\r\n parcelLinkageTypeId,\r\n consolidatingTypeId,\r\n consolidatedParcelId,\r\n parcelAcctNum,\r\n stateID,\r\n assessorID,\r\n hasWritePermission);\r\n navigationState.initializeGrid();\r\n return navigationState;\r\n }\r\n}\r\n\r\n// As of this comment, we plan on two places an Annual Details entity can be edited; the parcel\r\n// page and the document processing screen. Both of those locations will define some class for\r\n// this interface so that detail entity components don't have to care how the edit state is\r\n// implemented.\r\nexport interface AnnualDetailEditState {\r\n showEditControls: boolean;\r\n editMode: boolean;\r\n entityLoading: boolean;\r\n refreshGrid: boolean;\r\n refreshActivity: boolean;\r\n hasWritePermission: boolean;\r\n validationMessage: string;\r\n // Strikethrough for stale appeal data\r\n staleAppealSavings: boolean;\r\n staleAppealStatus: boolean;\r\n\r\n cancelHandler: () => void;\r\n saveHandler: () => Promise;\r\n validationHandler: (callback: (boolean, string) => void) => void;\r\n\r\n setEditMode(editMode: boolean): void;\r\n // TODO: Since we're using an edit mode setter, we probably should remove editMode from\r\n // this interface and add a getter instead so we encapsulate edit mode. For now, anyone\r\n // who references AnnualDetailEditState should promise not to set editMode manually,\r\n // but instead use setEditMode\r\n setDirty(isDirty: boolean): void;\r\n getDirty(): boolean;\r\n}\r\n\r\nexport class NavigationState implements AnnualDetailEditState {\r\n // The annual-details module is responsible for building this state initially\r\n constructor(\r\n // The AnnualDetailYear is the root model everything is based on\r\n public years: AnnualDetailYear[],\r\n // We need the following services\r\n private appealService: AppealService,\r\n private billClusterService: BillClusterService,\r\n private assessmentService: AssessmentService,\r\n private complianceService: ComplianceService,\r\n private annualBudgetService: AnnualBudgetService,\r\n private annualDetailsService: AnnualDetailsService,\r\n private navigationService: NavigationService,\r\n private navigationEvent: AnnualDetailsNavigationEventService,\r\n // Finally there's some data we need from the parcel\r\n private parcelID: number,\r\n private masterParcelId: number,\r\n private parcelLinkageTypeId: number,\r\n private consolidatingTypeId: number,\r\n private consolidatedParcelId: number,\r\n private parcelAcctNum: string,\r\n private stateID: number,\r\n private assessorID: number,\r\n public hasWritePermission: boolean) { }\r\n\r\n viewTarget: ViewTarget;\r\n currentAppealVM: AppealViewModel;\r\n currentAssessmentVM: AssessmentViewModel;\r\n currentTaxesVM: TaxesViewModel;\r\n currentComplianceVM: ComplianceViewModel;\r\n currentAnnualBudgetVM: AnnualBudgetViewModel;\r\n currentYear: AnnualDetailYear;\r\n currentRevision: AnnualDetailAssessment;\r\n isDirty: boolean;\r\n refreshActivity: boolean;\r\n entityLoading: boolean;\r\n refreshGrid: boolean;\r\n editMode: boolean;\r\n showEditControls: boolean;\r\n validationMessage: string;\r\n staleAppealSavings: boolean;\r\n staleAppealStatus: boolean;\r\n toggleEditHandler: (editMode: boolean) => void;\r\n cancelHandler: () => void;\r\n saveHandler: () => Promise;\r\n resetYearsHandler: () => Promise;\r\n validationHandler: (callback: (boolean, string) => void) => void;\r\n\r\n setDirty(isDirty: boolean) {\r\n if (this.isDirty !== isDirty) {\r\n this.isDirty = isDirty;\r\n if (this.isDirty) {\r\n this.navigationService.enableNavWarning('You have unsaved changes; if you continue, these changes will not be saved');\r\n }\r\n else {\r\n this.navigationService.disableNavWarning();\r\n }\r\n }\r\n }\r\n\r\n getDirty(): boolean {\r\n return this.isDirty;\r\n }\r\n\r\n setEditMode(editMode: boolean): void {\r\n this.editMode = editMode;\r\n if (this.toggleEditHandler) {\r\n this.toggleEditHandler(editMode);\r\n }\r\n }\r\n\r\n initializeGrid(): void {\r\n this.resetVMs();\r\n this.viewTarget = ViewTarget.grid;\r\n }\r\n\r\n goToGrid(): Promise {\r\n return this.annualDetailsService.preNavigateWarn(this).then(() => {\r\n if (this.refreshGrid) {\r\n this.entityLoading = true;\r\n this.resetYearsHandler();\r\n }\r\n this.initializeGrid();\r\n\r\n }, () => null);\r\n }\r\n\r\n goToAppeals(year: AnnualDetailYear, revision?: AnnualDetailAssessment, defaultAppealID?: number): Promise {\r\n return this.annualDetailsService.preNavigateWarn(this).then(() => {\r\n this.entityLoading = true;\r\n this.currentYear = year;\r\n if (revision === undefined) {\r\n this.currentRevision = year.annualGridDetails[0];\r\n }\r\n else {\r\n this.currentRevision = revision;\r\n }\r\n\r\n return this.appealService.getAppealViewModelByYear(year, this.parcelID, this.parcelAcctNum, this.stateID, defaultAppealID).then((appealViewModel: AppealViewModel) => {\r\n this.resetVMs();\r\n this.currentAppealVM = appealViewModel;\r\n this.viewTarget = ViewTarget.appeal;\r\n // If a particular revision was selected, we'll find the relevant appeal and select it here\r\n this.appealService.setAppealByAssessmentID(this.currentAppealVM, this.currentRevision.annualAssessmentID);\r\n // Set up edit state for appeals\r\n this.cancelHandler = () => {\r\n this.appealService.cancelAppealEdit(this.currentAppealVM);\r\n };\r\n this.saveHandler = () => {\r\n this.entityLoading = true;\r\n return this.appealService.saveAppealFromViewModel(this.currentAppealVM).then((result) => {\r\n\r\n this.appealService.loadTaskSummary(this.currentAppealVM);\r\n this.currentAppealVM.assignFromExistingAppeal(result);\r\n\r\n if (this.refreshActivity) {\r\n this.navigationEvent.refreshActivityData();\r\n }\r\n this.navigationEvent.refreshAnnualYear();\r\n this.refreshActivity = false;\r\n this.entityLoading = false;\r\n\r\n const toastMessage = result.additionalNotificationMessage;\r\n result.additionalNotificationMessage = null;\r\n\r\n return toastMessage;\r\n }).catch(reason => {\r\n this.entityLoading = false;\r\n throw reason;\r\n });\r\n };\r\n this.toggleEditHandler = () => {\r\n this.appealService.toggleAppealEdit(this.currentAppealVM, this.editMode);\r\n };\r\n this.validationHandler = (callback: (boolean, string) => void) => {\r\n this.currentAppealVM.validate(callback);\r\n };\r\n\r\n this.entityLoading = false;\r\n return appealViewModel;\r\n });\r\n }, () => undefined as AppealViewModel);\r\n }\r\n\r\n goToTaxes(year: AnnualDetailYear, billClusterID?: number, refundID?: number): Promise {\r\n return this.annualDetailsService.preNavigateWarn(this).then(() => {\r\n this.entityLoading = true;\r\n this.currentYear = year;\r\n this.currentRevision = year.annualGridDetails[0];\r\n\r\n return this.billClusterService.getTaxesViewModelByYear(year, this.parcelID, this.parcelAcctNum)\r\n .then((taxesViewModel: TaxesViewModel) => {\r\n this.resetVMs();\r\n this.currentTaxesVM = taxesViewModel;\r\n this.viewTarget = ViewTarget.tax;\r\n this.entityLoading = false;\r\n\r\n if (refundID) {\r\n this.billClusterService.setCurrentTabByRefundID(taxesViewModel, refundID);\r\n }\r\n else if(taxesViewModel.model.length) {\r\n this.billClusterService.setCurrentTab(taxesViewModel, billClusterID);\r\n }\r\n\r\n this.cancelHandler = () => {\r\n this.billClusterService.cancelTaxesEdit(this.currentTaxesVM);\r\n };\r\n this.saveHandler = () => {\r\n this.entityLoading = true;\r\n return this.billClusterService.saveTabFromViewModel(this.currentTaxesVM)\r\n .then((result: BillCluster) => {\r\n\r\n const isNewPayment: boolean = _.some(this.currentTaxesVM.currentTab.bills, (bill: Bill) => {\r\n return !_.every(bill.payments, 'paymentID');\r\n });\r\n\r\n if (isNewPayment) {\r\n this.setDirty(false);\r\n this.goToTaxes(this.currentTaxesVM.annualYearModel, result.billClusterID);\r\n\r\n return;\r\n }\r\n\r\n if (this.currentTaxesVM.currentTab.refund) {\r\n this.currentTaxesVM.currentTab.refund.refundRowVersion = result.refundRowVersion;\r\n }\r\n else if (this.currentTaxesVM.currentTab.billClusterID) {\r\n this.currentTaxesVM.currentTab.rowVersion = result.rowVersion;\r\n this.currentTaxesVM.currentTab.bills = _.map(this.currentTaxesVM.currentTab.bills, bill => {\r\n const savedBill = _.find(result.bills, {billID: bill.billID});\r\n\r\n if(savedBill) {\r\n bill.rowVersion = savedBill.rowVersion;\r\n }\r\n\r\n return bill;\r\n });\r\n }\r\n\r\n if (this.refreshActivity) {\r\n this.navigationEvent.refreshActivityData();\r\n }\r\n this.navigationEvent.refreshAnnualYear();\r\n this.refreshActivity = false;\r\n this.entityLoading = false;\r\n }).catch(reason => {\r\n this.entityLoading = false;\r\n throw reason;\r\n });\r\n };\r\n this.toggleEditHandler = () => {\r\n this.billClusterService.toggleTaxesEdit(this.currentTaxesVM, this.editMode);\r\n };\r\n this.validationHandler = (callback: (boolean, string) => void) => {\r\n // This really shouldn't be in the validation handler,\r\n // But saving taxes functions differently from assessments\r\n // and appeals, so I'm adding it here instead of adding\r\n // another handler for this specific case\r\n if (this.currentTaxesVM.preEditModelBackup && !_.isEqual(this.currentTaxesVM.preEditModelBackup, this.currentTaxesVM.currentTab)) {\r\n this.refreshGrid = true;\r\n }\r\n\r\n this.currentTaxesVM.validate(callback);\r\n };\r\n\r\n return taxesViewModel;\r\n });\r\n }, () => undefined as TaxesViewModel);\r\n }\r\n\r\n goToAssessment(year: AnnualDetailYear, revision: AnnualDetailAssessment): Promise {\r\n return this.annualDetailsService.preNavigateWarn(this).then(() => {\r\n this.entityLoading = true;\r\n this.currentRevision = revision;\r\n this.currentYear = year;\r\n\r\n return this.assessmentService.getAssessmentViewModelByID(revision.annualAssessmentID, this.assessorID, this.parcelID, this.parcelAcctNum, year)\r\n .then((assessmentVM: AssessmentViewModel) => {\r\n this.resetVMs();\r\n\r\n this.currentAssessmentVM = assessmentVM;\r\n this.viewTarget = ViewTarget.assessment;\r\n\r\n this.cancelHandler = () => {\r\n this.assessmentService.cancelAssessmentEdit(this.currentAssessmentVM);\r\n };\r\n\r\n this.saveHandler = () => {\r\n this.entityLoading = true;\r\n return this.assessmentService.saveAssessmentFromViewModel(this.currentAssessmentVM).then((newAssessment: Assessment) => {\r\n this.currentAssessmentVM.assignFromExistingAssessment(newAssessment);\r\n this.currentAssessmentVM.recalculateVariables();\r\n\r\n if (this.refreshActivity) {\r\n this.navigationEvent.refreshActivityData();\r\n }\r\n this.navigationEvent.refreshAnnualYear();\r\n this.refreshActivity = false;\r\n this.entityLoading = false;\r\n }).catch(reason => {\r\n this.entityLoading = false;\r\n throw reason;\r\n });\r\n };\r\n\r\n this.toggleEditHandler = () => {\r\n this.assessmentService.toggleAssessmentEdit(this.currentAssessmentVM, this.editMode);\r\n };\r\n\r\n this.entityLoading = false;\r\n return assessmentVM;\r\n });\r\n }, () => undefined as AssessmentViewModel);\r\n\r\n }\r\n\r\n goToCompliance(year: AnnualDetailYear, filingId?: number): Promise {\r\n return this.annualDetailsService.preNavigateWarn(this).then(() => {\r\n this.entityLoading = true;\r\n this.currentYear = year;\r\n this.currentRevision = year.annualGridDetails[0];\r\n\r\n return this.complianceService.getComplianceViewModelByYear(year, this.parcelID, this.masterParcelId, this.parcelLinkageTypeId, this.parcelAcctNum, this.consolidatingTypeId, this.consolidatedParcelId, filingId)\r\n .then(async (complianceVM: ComplianceViewModel) => {\r\n this.resetVMs();\r\n this.currentComplianceVM = complianceVM;\r\n this.viewTarget = ViewTarget.compliance;\r\n\r\n this.cancelHandler = () => {\r\n this.complianceService.cancelFilingEdit(this.currentComplianceVM);\r\n };\r\n this.saveHandler = () => {\r\n this.entityLoading = true;\r\n return this.complianceService.saveFilingFromViewModel(this.currentComplianceVM).then((result) => {\r\n if (this.currentComplianceVM.currentFiling) {\r\n this.currentComplianceVM.currentFiling.rowVersion = result.rowVersion;\r\n }\r\n if (this.refreshActivity) {\r\n this.navigationEvent.refreshActivityData();\r\n }\r\n this.navigationEvent.refreshAnnualYear();\r\n this.refreshActivity = false;\r\n this.entityLoading = false;\r\n }).catch(reason => {\r\n this.entityLoading = false;\r\n throw reason;\r\n });\r\n };\r\n this.toggleEditHandler = () => {\r\n this.complianceService.toggleFilingEdit(this.currentComplianceVM, this.editMode);\r\n };\r\n this.validationHandler = (callback: (boolean, string) => void) => {\r\n this.currentComplianceVM.validate(callback);\r\n };\r\n\r\n this.entityLoading = false;\r\n return complianceVM;\r\n }, () => undefined as ComplianceViewModel);\r\n });\r\n }\r\n\r\n goToBudget(year: AnnualDetailYear, annualBudgetId: number): Promise {\r\n return this.annualDetailsService.preNavigateWarn(this).then(() => {\r\n this.entityLoading = true;\r\n this.currentYear = year;\r\n this.currentRevision = year.annualGridDetails[0];\r\n\r\n return this.annualBudgetService.getAnnualBudgetViewModelByID(year, annualBudgetId, this.parcelID, this.parcelAcctNum)\r\n .then(async (annualBudgetVM: AnnualBudgetViewModel) => {\r\n this.resetVMs();\r\n this.currentAnnualBudgetVM = annualBudgetVM;\r\n this.viewTarget = ViewTarget.budget;\r\n\r\n this.cancelHandler = () => {\r\n this.annualBudgetService.cancelBudgetEdit(this.currentAnnualBudgetVM);\r\n };\r\n this.saveHandler = () => {\r\n this.entityLoading = true;\r\n return this.annualBudgetService.saveAnnualBudgetFromViewModel(this.currentAnnualBudgetVM).then((result) => {\r\n if (this.currentAnnualBudgetVM.model) {\r\n this.currentAnnualBudgetVM.model.rowVersion = result.rowVersion;\r\n }\r\n if (this.refreshActivity) {\r\n this.navigationEvent.refreshActivityData();\r\n }\r\n this.navigationEvent.refreshAnnualYear();\r\n this.refreshActivity = false;\r\n this.entityLoading = false;\r\n }).catch(reason => {\r\n this.entityLoading = false;\r\n throw reason;\r\n });\r\n };\r\n this.toggleEditHandler = () => {\r\n this.annualBudgetService.toggleAnnualBudgetEdit(this.currentAnnualBudgetVM, this.editMode);\r\n };\r\n this.validationHandler = (callback: (boolean, string) => void) => {\r\n this.currentAnnualBudgetVM.validate(callback);\r\n };\r\n\r\n this.entityLoading = false;\r\n return annualBudgetVM;\r\n }, () => undefined as AnnualBudgetViewModel);\r\n });\r\n }\r\n\r\n private resetVMs(): void {\r\n this.currentAppealVM = null;\r\n this.currentTaxesVM = null;\r\n this.currentComplianceVM = null;\r\n this.currentAnnualBudgetVM = null;\r\n this.validationMessage = '';\r\n this.cancelHandler = undefined;\r\n this.saveHandler = undefined;\r\n this.toggleEditHandler = undefined;\r\n this.validationHandler = (callback: any) => {\r\n callback(true, '');\r\n };\r\n this.showEditControls = false;\r\n this.editMode = false;\r\n this.setDirty(false);\r\n }\r\n}\r\n","import {FilingTypeSummary} from '../Compliance/compliance.model';\r\n\r\nexport class AnnualGridYearsInfo{\r\n years: AnnualDetailYear[];\r\n annualYearIDs: number[];\r\n totalYears: number;\r\n}\r\n\r\nexport class AnnualDetailYear {\r\n annualYearID: number;\r\n annualYear1: number;\r\n totalTaxes: number;\r\n effectiveRate: number;\r\n baseRate: number;\r\n taxIsEstimated: boolean;\r\n targetValue: number;\r\n totalNumberofYears: number;\r\n calcProjected: boolean;\r\n collapsedAppealStatus: string;\r\n collapsedSavings: string;\r\n totalAppealCountForYear: number;\r\n annualGridDetails: AnnualDetailAssessment[];\r\n complianceFilingTypeSummaries: FilingTypeSummary[];\r\n latestBudgetAmount: number;\r\n latestBudgetId: number;\r\n recalculatedStatus: any;\r\n recalculatedSavings: any;\r\n expanded: boolean;\r\n collapsedIsUnderAppeal: boolean;\r\n rowVersion: any;\r\n}\r\n\r\n//This isn't great, but this is to drive the add year dropdown, which was done a bit hacky in the old solution\r\n//ideally we should type the selcted and options\r\nexport class AnnualDetailYearList {\r\n constructor(years: AnnualDetailYear[]) {\r\n this.years = years;\r\n }\r\n\r\n years: AnnualDetailYear[];\r\n selected: any;\r\n options: any;\r\n}\r\n\r\nexport class AnnualDetailAssessment {\r\n annualAssessmentID: number;\r\n status: number;\r\n revisionDesc: string;\r\n revisionNum: number;\r\n appealStatus: string;\r\n savings: string;\r\n annualGridComponents: AnnualDetailComponent[];\r\n isUnderAppeal: boolean;\r\n rowVersion: any;\r\n taxableValues: Core.AnnualGridTaxableValueDTO[];\r\n}\r\n\r\nexport class AnnualDetailComponent {\r\n constructor(componentName: string, fairMarketValue: number, assessmentComponentTypeID: number) {\r\n this.componentName = componentName;\r\n this.fairMarketValue = fairMarketValue;\r\n this.assessmentComponentTypeID = assessmentComponentTypeID;\r\n }\r\n\r\n componentName: string;\r\n fairMarketValue: number;\r\n sequence: number;\r\n assessmentClassComponentID: number;\r\n assessmentComponentTypeID: number;\r\n efAction?: string;\r\n}\r\n\r\nexport class AddYearModel {\r\n constructor(newYear: number) {\r\n this.year = newYear;\r\n }\r\n\r\n year: number;\r\n}\r\n\r\n\r\n\r\n\r\n","import { HelpContent } from '../UI-Lib/Help-Tooltip';\r\n\r\nexport const ANNUAL_DETAILS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'annual-details.phantom-year',\r\n tooltipText: 'This tax year contains filing(s) from a consolidated parcel.'\r\n },\r\n {\r\n helpContentId: 'annual-details.phantom-filing',\r\n tooltipText: 'This filing is from a consolidated parcel.'\r\n }\r\n];\r\n","export abstract class ParcelActivityModalService {\r\n abstract open(parcelID: number, siteID: number, years: number[]): void;\r\n}\r\n","
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n {{year.annualYear1}}\r\n 1\" [attr.data-sd-expand-year-revisions] [attr.data-sd-annual-year]=\"year.annualYear1\">\r\n \r\n \r\n \r\n 10\" class=\"blank\">\r\n
\r\n Comp\r\n \r\n
{{ filingType.filingTypeName }}
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n Asmts\r\n \r\n Revision:\r\n
{{ annualDetailsService.getComponentName(comp, componentTypes) }}
\r\n
Total FMV:
\r\n
{{annualDetailsService.getComponentName(comp, componentTypes) }}:
\r\n \r\n
{{taxableName}}
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n {{revision.revisionDesc}}\r\n
\r\n
\r\n {{ annualDetailsService.getDisplayAssessment(comp, revision.annualGridComponents)}}\r\n
\r\n
{{ annualDetailsService.getTotalFMV(revision.annualGridComponents, viewTaxableValues) | number:'1.0-0'}}
\r\n
{{ annualDetailsService.getDisplayAssessment(comp, revision.annualGridComponents)}}
\r\n \r\n
{{taxableValue}}
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n Appeals\r\n \r\n
Resolution:
\r\n
Savings:
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n =2\">\r\n \r\n \r\n
\r\n
\r\n {{revision.appealStatus}}\r\n {{revision.appealStatus}}\r\n
\r\n
{{annualDetailsService.formatSavings(revision.savings) || '0'}}
\r\n
\r\n {{year.collapsedAppealStatus}}\r\n {{year.collapsedAppealStatus}}\r\n
{{annualDetailsService.formatSavings(year.collapsedSavings) || '0'}}
\r\n
\r\n
\r\n
\r\n Taxes\r\n \r\n
Total:
\r\n
Eff. Rate:
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
{{year.totalTaxes | currency: 'USD':'symbol'}}
\r\n
{{year.effectiveRate | number: '1.6-6'}}%
\r\n
\r\n
\r\n
Budget\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
0\">{{year.latestBudgetAmount | currency: 'USD':'symbol'}}
\r\n
No Budget
\r\n
\r\n
\r\n
\r\n \r\n
\r\n","import { Component, Input } from '@angular/core';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { NavigationState } from '../annual-details-navigation.service';\r\nimport { AnnualDetailsService } from '../annual-details.service';\r\nimport { AnnualDetailAssessment, AnnualDetailComponent, AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { AppealService } from '../Appeals/appeal.service';\r\nimport { FilingType, FilingTypeSummary } from '../Compliance/compliance.model';\r\nimport { BillClusterService } from '../Taxes/bill-cluster.service';\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'annual-details-grid',\r\n templateUrl: './annual-details-grid.component.html',\r\n styleUrls: ['./annual-details-grid.component.scss'],\r\n providers: [AppealService, BillClusterService]\r\n})\r\n\r\nexport class AnnualDetailsGridComponent {\r\n constructor(\r\n public readonly annualDetailsService: AnnualDetailsService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n )\r\n { }\r\n\r\n @Input() years: AnnualDetailYear[];\r\n @Input() components: AnnualDetailComponent[];\r\n @Input() componentTypes: any;\r\n @Input() filings: FilingTypeSummary[];\r\n @Input() filingTypes: FilingType[];\r\n @Input() parcelState: number;\r\n @Input() navigationState: NavigationState;\r\n @Input() hasComplianceResponsibility: boolean;\r\n @Input() budgetsEnabled: boolean;\r\n @Input() consolidatingTypeId: Core.ConsolidatingTypeEnum;\r\n @Input() viewTaxableValues: boolean;\r\n // @Input() appealsClick() :void;\r\n state: number;\r\n\r\n /* CLICK FUNCTIONS */\r\n billClicked(year: AnnualDetailYear): void {\r\n if (this.consolidatingTypeId == Core.ConsolidatingTypeEnum.Consolidated) return;\r\n this._productAnalyticsService.logEvent('click-annual-details-taxes');\r\n this.navigationState.goToTaxes(year);\r\n }\r\n\r\n revisionClicked(year: AnnualDetailYear, revision: AnnualDetailAssessment): void {\r\n if(this.consolidatingTypeId == Core.ConsolidatingTypeEnum.Consolidated) return;\r\n this._productAnalyticsService.logEvent('click-annual-details-asmts');\r\n this.navigationState.goToAssessment(year, revision);\r\n }\r\n\r\n appealClicked(year: AnnualDetailYear, revision?: AnnualDetailAssessment): void {\r\n if (this.consolidatingTypeId == Core.ConsolidatingTypeEnum.Consolidated) return;\r\n this._productAnalyticsService.logEvent('click-annual-details-appeals');\r\n this.navigationState.goToAppeals(year, revision);\r\n }\r\n\r\n complianceClicked(year: AnnualDetailYear): void {\r\n this._productAnalyticsService.logEvent('click-annual-details-comp');\r\n this.navigationState.goToCompliance(year);\r\n }\r\n\r\n budgetClicked(year: AnnualDetailYear, annualBudgetId: number): void {\r\n if (this.consolidatingTypeId == Core.ConsolidatingTypeEnum.Consolidated) return;\r\n this._productAnalyticsService.logEvent('click-annual-details-budget');\r\n this.navigationState.goToBudget(year, annualBudgetId);\r\n }\r\n\r\n /* STYLE FUNCTIONS */\r\n clickableTaxClass(year): string {\r\n let str = '';\r\n\r\n if (year.expanded) {\r\n str += 'expanded';\r\n }\r\n\r\n if (year.taxIsEstimated) {\r\n str += ' not-actual';\r\n }\r\n\r\n return str;\r\n }\r\n\r\n isNumber(value): boolean {\r\n return typeof value === 'number';\r\n }\r\n\r\n isFromConsolidated(year: AnnualDetailYear, filingType: FilingTypeSummary): boolean {\r\n return !!year.complianceFilingTypeSummaries.find(summary => summary.isFromConsolidatedParcel)\r\n && (filingType && filingType.filingTypeId === 1);\r\n }\r\n\r\n get notAllowedIfConsolidated() {\r\n return this.isConsolidatedParcel ? 'not-allowed' : 'pointer';\r\n }\r\n\r\n get isConsolidatedParcel(): boolean {\r\n return this.consolidatingTypeId == Core.ConsolidatingTypeEnum.Consolidated;\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { SDHttpService } from '../Routing/sd-http.service';\r\nimport { UserTeamMember } from '../Models/common.model';\r\nimport { InstanceRights, RestrictService, Roles } from '../Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../Routing/upgrade-navigation-handler.service';\r\nimport { Constants, RyanInstanceId } from '../../constants.new';\r\nimport { InstanceRepository } from '../../Entity/Instance/instance.repository';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\n\r\nexport class EntityInProgressIntakeData {\r\n entityID: number;\r\n entityTypID: number;\r\n intakeItemID: number;\r\n batchNumber: string;\r\n itemNumber: string;\r\n exceptionStatusID: number;\r\n duplicateNumber: number;\r\n assignedUser: UserTeamMember;\r\n}\r\n\r\n@Component({\r\n selector: 'entity-in-progress-indicator',\r\n template: `\r\n \r\n\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n {{item.batchNumber}}#{{item.itemNumber}}_{{item.duplicateNumber}}\r\n \r\n \r\n \r\n {{item.batchNumber}}#{{item.itemNumber}}_{{item.duplicateNumber}}\r\n \r\n - {{item.assignedUser.lastName}}, {{item.assignedUser.firstName}}\r\n {{constants.ProcessingExceptionStatusText[item.exceptionStatusID]}}\r\n
\r\n
\r\n
\r\n
\r\n `\r\n})\r\nexport class EntityInProgressIndicatorComponent implements OnInit {\r\n constructor(\r\n private readonly _http: SDHttpService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _navigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _instanceRepository: InstanceRepository,\r\n public constants: Constants,\r\n private readonly _userInstanceService: UserInstanceService) {\r\n }\r\n\r\n @Input() entityId: number;\r\n @Input() entityTypeId: number;\r\n @Input() isDocumentProcessing: boolean = false;\r\n\r\n hasPermission: boolean = false;\r\n intakeItems: EntityInProgressIntakeData[] = [];\r\n\r\n async ngOnInit() {\r\n const instanceId = await lastValueFrom(this._instanceRepository.getEntityIdPairInstanceId(this.entityTypeId, this.entityId));\r\n this.hasPermission = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW, instanceId) ||\r\n this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, instanceId);\r\n\r\n if (!this.hasPermission && instanceId !== RyanInstanceId && this._userInstanceService.isCurrentInstanceRyan() &&\r\n this._restrictService.isInRole(Roles.LICENSEDDOCUMENTSERVICES)) {\r\n this.hasPermission = true;\r\n }\r\n }\r\n\r\n onIndicatorHover(): void {\r\n const config = {\r\n params: {\r\n entityID: this.entityId,\r\n entityTypeID: this.entityTypeId\r\n }\r\n };\r\n\r\n this._http.get('/api/processing/document/entityInProgressIntakeData', config)\r\n .then((result: EntityInProgressIntakeData[]) => {\r\n this.intakeItems = result;\r\n });\r\n }\r\n\r\n getProcessingUrl(intakeItemID: number): string {\r\n const parcelId = this._navigationServiceHandler.getQuerystringParam('parcelId');\r\n\r\n return this._navigationServiceHandler.getHrefFromState('documentProcessing', { parcelID: parcelId, intakeItemID: intakeItemID});\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n

Add Appeal

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, Output, ViewChild } from '@angular/core';\r\nimport { ModalDirective } from 'ngx-bootstrap/modal';\r\nimport { AnnualDetailAssessment } from '../Annual-Year/annual-year.model';\r\nimport { Appeal, AppealLevel } from '../Appeals/appeal.model';\r\nimport { AppealService } from '../Appeals/appeal.service';\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'add-appeal-modal',\r\n templateUrl: './add-appeal.component.html'\r\n})\r\nexport class AddAppealModalComponent {\r\n constructor(private appealService: AppealService) {\r\n this.addAppeal = new EventEmitter();\r\n }\r\n @Input() assessments: AnnualDetailAssessment[];\r\n @Input() appealLevels: AppealLevel[];\r\n @Output() addAppeal: EventEmitter;\r\n @ViewChild('addAppealModal', { static: true }) addAppealModal: ModalDirective;\r\n\r\n newAppeal: Appeal;\r\n loading: boolean;\r\n\r\n\r\n show(): void {\r\n this.addAppealModal.show();\r\n }\r\n\r\n showModalInit(): void {\r\n this.newAppeal = new Appeal();\r\n\r\n if (this.appealLevels && this.appealLevels.length > 0) {\r\n this.newAppeal.appealLevelID = this.appealLevels[0].appealLevelID;\r\n }\r\n\r\n if (this.assessments && this.assessments.length > 0) {\r\n this.newAppeal.annualAssessmentID = (_.minBy(this.assessments, 'revisionNum') as AnnualDetailAssessment).annualAssessmentID;\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n const appeal = await this.appealService.createAppeal(this.newAppeal);\r\n this.addAppeal.emit(appeal);\r\n this.addAppealModal.hide();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n}\r\n\r\n","
\r\n \r\n \r\n
\r\n
\r\n There are presently no appeals for {{currentYear.annualYear1}}\r\n {{currentRevision.revisionDesc}}.\r\n
\r\n Deadline of {{currentRevision.appealStatus}} from the\r\n {{currentRevision.revisionDesc}}\r\n assessment.\r\n
\r\n
\r\n
\r\n There are presently no appeals for this year.\r\n
\r\n \r\n
\r\n \r\n
\r\n 0 && viewModel.showTabs\" #appealTabs>\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Appeal Level:\r\n {{viewModel.appealLevelAbbrDisplay(appeal.appealLevelID)}}\r\n \r\n
Litigation:\r\n {{viewModel.appealLevelLitigationDisplay(appeal.appealLevelID)}}\r\n
Revision Appealed:\r\n {{getAssessmentDescription(appeal.annualAssessmentID)}}\r\n \r\n
Filing Reference:\r\n {{appeal.filingReference}}\r\n \r\n
Case #:\r\n {{appeal.caseNumber}}\r\n \r\n
Hearing Location:\r\n {{appeal.hearingLocation}}\r\n \r\n
File By Date:\r\n
\r\n \r\n \r\n
\r\n
Submit Evidence Date:\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
Confirm Hearing Date:\r\n
\r\n \r\n \r\n
\r\n
Informal Hearing Date:\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
Formal Hearing Date:\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
Status: \r\n
\r\n \r\n \r\n {{ viewModel.currentTaskSummary.Status }}\r\n \r\n {{ viewModel.currentTaskSummary.CompletedDateTime | weissmanDateFormat: true: \"Central\" }}\r\n \r\n \r\n
\r\n \r\n
Status: \r\n
\r\n N/A - No Responsibility\r\n
\r\n
Resolution:\r\n {{ getAppealStatus(appeal) }}\r\n \r\n \r\n \r\n
Outcome Revision:\r\n {{ getAppealOutcomeRevision(appeal) }}\r\n \r\n \r\n \r\n \r\n
Anticipated FMV:\r\n {{ appeal.anticipatedFMV | number:'1.0-0' }}\r\n \r\n
Savings:\r\n {{ appeal.savings | currency: 'USD'}}\r\n
\r\n \r\n \r\n \r\n
\r\n
Savings Date:\r\n
\r\n \r\n \r\n
\r\n
Non-Ryan:\r\n \r\n
RLS:\r\n \r\n
\r\n \r\n
\r\n","import { Component, Input, OnChanges, OnInit, SimpleChanges, ViewChild } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { TabsetComponent } from 'ngx-bootstrap/tabs';\r\nimport { TooltipDirective } from 'ngx-bootstrap/tooltip';\r\nimport { MessageBoxService, MessageBoxButtons, MessageBoxResult } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { WeissmanDatetimeComponent } from '../../UI-Lib/Weiss-Datepicker/weissman-datetime.component';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { AnnualDetailsNavigationEventService } from '../annual-details-event.service';\r\nimport { AnnualDetailEditState } from '../annual-details-navigation.service';\r\nimport { AnnualDetailsService } from '../annual-details.service';\r\nimport { AnnualDetailAssessment, AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { AddAppealModalComponent } from '../Modals/add-appeal.component';\r\nimport { Appeal, AppealStatus, AppealStatusID } from './appeal.model';\r\nimport { AppealService, AppealViewModel } from './appeal.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { AppealApplicationService } from '../../Appeal-Application/appeal.application.service';\r\nimport { TaskType } from '../../constants.new';\r\nimport { RestrictService, Roles } from 'src/app/Common/Permissions/restrict.service';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\ndeclare const _: any;\r\n\r\n// TODO: Create a solution for dealing with consts in Angular 2+ and move this there\r\nconst APPEAL_ENTITY_TYPE_ID = 8;\r\n\r\n@Component({\r\n selector: 'appeal',\r\n templateUrl: './appeal.component.html'\r\n})\r\nexport class AppealComponent implements OnInit, OnChanges {\r\n constructor(private appealService: AppealService,\r\n private annualDetailsService: AnnualDetailsService,\r\n private taskService: TaskService,\r\n public toastr: ToastrService,\r\n private messageBoxService: MessageBoxService,\r\n private navigationEvent: AnnualDetailsNavigationEventService,\r\n private upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private restrictService: RestrictService,\r\n private appealApplicationService: AppealApplicationService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n public readonly featureFlagsService: FeatureFlagsService\r\n ) {\r\n this.appealStatuses = _.sortBy(AppealStatus.appealStatuses, '');\r\n this.skipTaskAppealStatuses = [AppealStatusID.Withdrawn, AppealStatusID.AddInError];\r\n }\r\n\r\n @Input() viewModel: AppealViewModel;\r\n // IMPORTANT: The currentYear input is not present when loading the appeal component from document processing.\r\n // This property is used in the markup to represent the year in the year panel on the left; if code needs access\r\n // to a property on the annual year, viewModel.annualYearModel is more suitable than currentYear.\r\n @Input() currentYear: AnnualDetailYear;\r\n @Input() currentRevision: AnnualDetailAssessment;\r\n @Input() assessmentNavigateHandler: (year: AnnualDetailYear, revision: AnnualDetailAssessment) => any;\r\n @Input() editState: AnnualDetailEditState;\r\n @Input() taskReadonly: boolean = false;\r\n @Input() hideDelete: boolean = false;\r\n @Input() isDocumentProcessing: boolean = false;\r\n @ViewChild('appealTabs') appealTabs: TabsetComponent;\r\n @ViewChild('AddAppealModal') addAppealModal: AddAppealModalComponent;\r\n @ViewChild('submitEvidenceDateTimeLocal') submitEvidenceDateElement: WeissmanDatetimeComponent;\r\n @ViewChild('informalHearingDateTimeLocal') informalHearingDateElement: WeissmanDatetimeComponent;\r\n @ViewChild('hearingDateTimeLocal') hearingDateElement: WeissmanDatetimeComponent;\r\n @ViewChild('appealTaskValidation') appealTaskValidation: TooltipDirective;\r\n\r\n appealStatuses: AppealStatus[];\r\n appealPreviousStatus: number;\r\n skipTaskAppealStatuses: number[];\r\n appealEntityTypeId: number = APPEAL_ENTITY_TYPE_ID;\r\n isCalculatingSavings: boolean = false;\r\n hasRyanPrivateEdit: boolean = false;\r\n hasRyanPrivateView: boolean = false;\r\n isRyanInstance: boolean = false;\r\n isRyanLegalServiceEnabled: boolean = false;\r\n enableAppealLitigation: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this.viewModelChanged();\r\n\r\n this.hasRyanPrivateEdit = this.restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT);\r\n this.hasRyanPrivateView = this.restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n this.isRyanInstance = this._userInstanceService.RyanInstanceId == this._userInstanceService.getSelectedInstance().instanceId;\r\n this.isRyanLegalServiceEnabled = this.featureFlagsService.featureFlags.enableInvoiceRLS;\r\n this.enableAppealLitigation = this.featureFlagsService.featureFlags.enableAppealLitigation;\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n // Look for changes to the viewModel input property\r\n if (Object.keys(changes).indexOf('viewModel') >= 0) {\r\n this.viewModelChanged();\r\n }\r\n }\r\n\r\n viewModelChanged(): void {\r\n this.checkDefaultAppealID();\r\n this.editState.showEditControls = this.viewModel && this.viewModel.model.length > 0;\r\n if (this.viewModel) {\r\n this.viewModel.hasWritePermission = this.editState.hasWritePermission;\r\n this.viewModel.updateModalData();\r\n this.viewModel.resetDateTimeHandler = () => {\r\n if (this.submitEvidenceDateElement) {\r\n this.submitEvidenceDateElement.resetValidation();\r\n }\r\n if (this.informalHearingDateElement) {\r\n this.informalHearingDateElement.resetValidation();\r\n }\r\n if (this.hearingDateElement) {\r\n this.hearingDateElement.resetValidation();\r\n }\r\n };\r\n\r\n if (this.viewModel.currentAppeal){\r\n this.appealPreviousStatus = this.viewModel.currentAppeal.appealStatusID;\r\n }\r\n }\r\n }\r\n\r\n checkDefaultAppealID(): void {\r\n if (this.viewModel && this.viewModel.defaultAppealID) {\r\n this.appealService.setCurrentAppeal(this.viewModel, this.viewModel.defaultAppealID);\r\n }\r\n }\r\n\r\n appealHeading(appealIndex: number) {\r\n return this.viewModel.appealLevelAbbrDisplay(this.viewModel.model[appealIndex].appealLevelID);\r\n }\r\n\r\n getAssessmentDescription(assessmentID: number) {\r\n const assessment = _.find(this.viewModel.annualYearModel.annualGridDetails, (x: AnnualDetailAssessment) => {\r\n return x.annualAssessmentID === assessmentID;\r\n }) as AnnualDetailAssessment;\r\n\r\n return assessment.revisionDesc;\r\n }\r\n\r\n getAppealStatus(appeal: Appeal): string {\r\n if (appeal.appealStatusID) {\r\n return AppealStatus.getByID(appeal.appealStatusID).status;\r\n }\r\n else {\r\n return 'Not set';\r\n }\r\n }\r\n\r\n canPrepareApplication(appeal: Appeal): boolean {\r\n // WK-6708 There is no read-only appeal application page at the moment, so restrict this to users who have\r\n // write permission on the appeal for now\r\n return this.editState.hasWritePermission &&\r\n _.some(this.viewModel.currentTaskSummary.ReadyTaskTypes, (t: TaskType) => t === TaskType.PrintApplication) &&\r\n appeal.canCreateApplicationForm;\r\n }\r\n\r\n getAppealOutcomeRevision(appeal: Appeal): string {\r\n const revision: AnnualDetailAssessment = _.find(this.viewModel.annualYearModel.annualGridDetails, { annualAssessmentID: appeal.outcomeAnnualAssessmentID });\r\n return revision && revision.revisionDesc;\r\n }\r\n\r\n setDefaultOutcomeRevision(appeal: Appeal): void {\r\n // Default to the next revision (or current revision if no next revision) unless the Status (Resolution) is set to Added-in-Error, then do nothing.\r\n if (appeal.appealStatusID === AppealStatusID.AddInError) {\r\n appeal.outcomeAnnualAssessmentID = AppealStatusID.Null;\r\n return;\r\n }\r\n\r\n const appealedRevision = _.find(this.viewModel.annualYearModel.annualGridDetails, {\r\n annualAssessmentID: this.viewModel.currentAppeal.annualAssessmentID\r\n });\r\n const nextRevision = _.find(this.viewModel.annualYearModel.annualGridDetails, { revisionNum: appealedRevision.revisionNum + 1 });\r\n appeal.outcomeAnnualAssessmentID = (nextRevision && nextRevision.annualAssessmentID) || appealedRevision.annualAssessmentID;\r\n }\r\n\r\n appealOutcomeRevisionChanged(appeal: Appeal): void {\r\n this.calculateSavings(appeal);\r\n }\r\n\r\n appealStatusChanged(appeal: Appeal, newAppealStatusID: number) {\r\n // track old status and update the new one\r\n this.appealPreviousStatus = appeal.appealStatusID;\r\n appeal.appealStatusID = newAppealStatusID;\r\n\r\n const newStatusInTheList = _.indexOf(this.skipTaskAppealStatuses, this.viewModel.currentAppeal.appealStatusID);\r\n const previousStatusInTheList = _.indexOf(this.skipTaskAppealStatuses, this.appealPreviousStatus);\r\n\r\n if (newStatusInTheList != -1 && previousStatusInTheList === -1){\r\n this.messageBoxService.open({\r\n message: `Changing resolution to ${ this.getAppealStatus(appeal) } will cause all open appeal tasks to be skipped when the appeal is saved. Proceed?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n }).then((result: MessageBoxResult) => {\r\n if (result === MessageBoxResult.OK) {\r\n this.changeStatus(appeal);\r\n }\r\n else {\r\n appeal.appealStatusID = this.appealPreviousStatus;\r\n }\r\n });\r\n }\r\n else{\r\n this.changeStatus(appeal);\r\n }\r\n }\r\n\r\n changeStatus(appeal: Appeal) : void {\r\n // default the Outcome Revision when the option is shown the first time\r\n // this would typically be when the status changes from NULL to a closed status\r\n if (this.appealPreviousStatus === AppealStatusID.Null && this.isClosed(appeal)) {\r\n this.setDefaultOutcomeRevision(appeal);\r\n }\r\n\r\n //// Feature removed through WK-7290\r\n // Default savings date to today\r\n // if (appeal.appealStatusID !== AppealStatusID.Null && !appeal.savingsDate) {\r\n // appeal.savingsDate = WeissmanDatetime.getMidnightMoment(new Date(), false, \"Central\").format();\r\n // }\r\n ////\r\n\r\n // Savings Date is not valid unless we have an appeal status\r\n if (appeal.appealStatusID !== AppealStatusID.Reduction) {\r\n appeal.savingsDate = null;\r\n }\r\n this.appealPreviousStatus = appeal.appealStatusID;\r\n\r\n this.setSavings(appeal)\r\n .then(() => {\r\n this.editState.staleAppealStatus = true;\r\n this.editState.refreshGrid = true;\r\n });\r\n }\r\n\r\n // isEditable and editMode do subtly different things; if the user is currently editing the appeal, editMode is true.\r\n // However, if the appeal status indicates that it is closed only the status should be editable, so the isEditable\r\n // function checks both the editMode and the appeal status.\r\n isEditable(appeal: Appeal): boolean {\r\n return this.editState.editMode && !this.isClosed(appeal);\r\n }\r\n\r\n isClosed(appeal: Appeal):boolean {\r\n if (!appeal.appealStatusID) {\r\n return false;\r\n }\r\n else {\r\n return AppealStatus.getByID(appeal.appealStatusID).isClosedStatus;\r\n }\r\n }\r\n\r\n showSubmitEvidence(): boolean {\r\n return this.viewModel.currentTaskSummary &&\r\n ((!this.viewModel.currentTaskSummary.Status && !this.viewModel.loadingTaskSummary) ||\r\n this.viewModel.currentTaskSummary.HasSubmitEvidence);\r\n }\r\n\r\n showConfirmHearing(): boolean {\r\n return this.viewModel.currentTaskSummary &&\r\n ((!this.viewModel.currentTaskSummary.Status && !this.viewModel.loadingTaskSummary) ||\r\n this.viewModel.currentTaskSummary.HasConfirmHearing);\r\n }\r\n\r\n showInformalHearing(): boolean {\r\n return this.viewModel.currentTaskSummary &&\r\n ((!this.viewModel.currentTaskSummary.Status && !this.viewModel.loadingTaskSummary) ||\r\n this.viewModel.currentTaskSummary.HasInformalHearing);\r\n }\r\n\r\n showHearing(): boolean {\r\n return this.viewModel.currentTaskSummary &&\r\n ((!this.viewModel.currentTaskSummary.Status && !this.viewModel.loadingTaskSummary) ||\r\n this.viewModel.currentTaskSummary.HasFormalHearing);\r\n }\r\n\r\n isStatusADate(): boolean {\r\n // I sloppily ported this from our old JavaScript solution; there's probably a better way to do this. We're just checking\r\n // if the string appealStatus property on the current revision is actually a date\r\n if (this.currentRevision) {\r\n const d = new Date(this.currentRevision.appealStatus);\r\n if (d.getDate()) {\r\n return true;\r\n }\r\n else {\r\n return false;\r\n }\r\n }\r\n else {\r\n return false;\r\n }\r\n }\r\n\r\n launchTaskModal(appeal: Appeal): void {\r\n const openCallback = () => {\r\n this.taskService.launchTaskModal(appeal.appealID, APPEAL_ENTITY_TYPE_ID, this.taskReadonly || !this.editState.editMode).then(shouldReload => {\r\n if (shouldReload) {\r\n this.navigationEvent.refreshActivityData();\r\n this.appealService.loadTaskSummary(this.viewModel);\r\n this.editState.refreshGrid = true;\r\n }\r\n });\r\n };\r\n\r\n if (this.editState.editMode && !this.taskReadonly && this.editState.getDirty()) {\r\n this.editState.validationHandler((isValid, errorMessage) => {\r\n if (!isValid) {\r\n this.editState.validationMessage = errorMessage;\r\n setTimeout(() => {\r\n this.appealTaskValidation.show();\r\n }, 1);\r\n }\r\n else {\r\n this.editState.validationMessage = '';\r\n this.editState.saveHandler().then((toastMessage) => {\r\n this.toastr.info('Appeal changes autosaved');\r\n this.editState.setDirty(false);\r\n this.viewModel.resetEdit(true);\r\n\r\n if (toastMessage){\r\n this.toastr.info(toastMessage);\r\n }\r\n openCallback();\r\n });\r\n }\r\n });\r\n }\r\n else {\r\n openCallback();\r\n }\r\n }\r\n\r\n calculateSavings(appeal: Appeal): void {\r\n this.setSavings(appeal)\r\n .then(() => {\r\n this.editState.staleAppealSavings = true;\r\n this.editState.refreshGrid = true;\r\n });\r\n }\r\n\r\n savingsChanged(appeal: Appeal): void {\r\n this.setDirty();\r\n appeal.savingsOverridden = true;\r\n this.editState.staleAppealSavings = true;\r\n this.editState.refreshGrid = true;\r\n }\r\n\r\n setSavings(appeal: Appeal): Promise {\r\n this.isCalculatingSavings = true;\r\n return this.appealService.setSavings(appeal, this.viewModel.annualYearModel)\r\n .then(() => {\r\n this.isCalculatingSavings = false;\r\n });\r\n }\r\n\r\n savingsBlur(appeal: Appeal): void {\r\n if (appeal.savings !== 0 && !appeal.savings) {\r\n appeal.savingsOverridden = false;\r\n this.calculateSavings(appeal);\r\n this.editState.staleAppealSavings = true;\r\n this.editState.refreshGrid = true;\r\n }\r\n }\r\n\r\n revertToOriginalSavings(appeal: Appeal): void {\r\n appeal.savingsOverridden = false;\r\n this.calculateSavings(appeal);\r\n this.editState.staleAppealSavings = true;\r\n this.editState.refreshGrid = true;\r\n }\r\n\r\n openAddAppeal(): void {\r\n this.annualDetailsService.preNavigateWarn(this.editState).then(() => {\r\n this.addAppealModal.show();\r\n });\r\n }\r\n\r\n addAppeal(newAppeal: any): void {\r\n newAppeal = newAppeal as Appeal;\r\n this.appealService.addNewAppealToViewModel(this.viewModel, newAppeal).then(appeal => {\r\n this.editState.staleAppealStatus = true;\r\n this.editState.refreshGrid = true;\r\n this.appealPreviousStatus = appeal.appealStatusID;\r\n this.navigationEvent.refreshActivityData();\r\n // If we're adding the first appeal for this year, showEditControls will be false\r\n // when the component is loaded; reset to true now that we have an appeal to edit\r\n this.editState.showEditControls = true;\r\n if (!this.editState.editMode) {\r\n // We normally would be worried about isDirty here, but the preNavigationWarn call\r\n // on the button event should ensure that we can't get here from a dirty form\r\n this.editState.setEditMode(true);\r\n }\r\n });\r\n }\r\n\r\n switchTabs(i: number) {\r\n // For posterity; here's how you'd \"cancel\" selecting a tab:\r\n /*\r\n // Allow tab control to \"breathe\" before cancelling the navigate event and going\r\n // back to the previously selected tab\r\n setTimeout(() => {\r\n this.appealTabs.tabs.forEach((t, index) => {\r\n t.active = index === this.viewModel.currentAppealIndex;\r\n });\r\n this.newAppeal();\r\n }, 1);\r\n */\r\n\r\n if (i !== this.viewModel.currentAppealIndex) {\r\n this.annualDetailsService.preNavigateWarn(this.editState).then(() => {\r\n this.appealService.setAppealIndex(this.viewModel, i);\r\n }, () => {\r\n this.appealTabs.tabs.forEach((t, index) => {\r\n t.active = index === this.viewModel.currentAppealIndex;\r\n });\r\n });\r\n }\r\n }\r\n\r\n onSubmitEvidenceValidationChange(validationMessage): void {\r\n this.viewModel.submitEvidenceValid = !validationMessage;\r\n }\r\n\r\n onInformalHearingValidationChange(validationMessage): void {\r\n this.viewModel.informalHearingValid = !validationMessage;\r\n }\r\n\r\n onHearingValidationChange(validationMessage): void {\r\n this.viewModel.hearingValid = !validationMessage;\r\n }\r\n\r\n showBrokenChain(value: Date): boolean {\r\n return (!this.viewModel.currentTaskSummary || (!this.viewModel.currentTaskSummary.status && this.viewModel.currentTaskSummary.loaded)) && (value !== undefined && value !== null);\r\n }\r\n\r\n setDirty(): void {\r\n this.editState.setDirty(true);\r\n this.editState.refreshGrid = true;\r\n }\r\n\r\n onTaskRelevantFieldChanged(): void {\r\n this.editState.setDirty(true);\r\n this.editState.refreshActivity = true;\r\n }\r\n\r\n deleteAppeal(appeal: Appeal): void {\r\n this.messageBoxService.confirm(`Are you sure you want to delete ${\r\n this.viewModel.appealLevelAbbrDisplay(appeal.appealLevelID) }?`).then(() => {\r\n this.appealService.deleteAppeal(appeal.appealID).then(() => {\r\n this.editState.staleAppealStatus = true;\r\n this.editState.refreshGrid = true;\r\n _.remove(this.viewModel.model, appeal);\r\n // Stay in edit mode after deleting an appeal\r\n this.editState.setDirty(false);\r\n this.editState.refreshActivity = false;\r\n\r\n this.navigationEvent.refreshActivityData();\r\n\r\n if (this.viewModel.model.length < 1) {\r\n this.editState.showEditControls = false;\r\n this.editState.setEditMode(false);\r\n }\r\n else {\r\n this.viewModel.resetEdit();\r\n this.appealService.setAppealIndex(this.viewModel, 0);\r\n }\r\n });\r\n });\r\n }\r\n\r\n changeAppealLevelObj(event, appeal: Appeal): void{\r\n appeal.appealLevel = _.find(this.viewModel.stateAppealLevels, {\r\n appealLevelID: appeal.appealLevelID\r\n });\r\n }\r\n\r\n async navigateToAppealApplication(appeal: Appeal): Promise {\r\n let cancelled = false;\r\n await (this.annualDetailsService.preNavigateWarn(this.editState).then(() => null, () => { cancelled = true; }));\r\n if (cancelled) { return; }\r\n console.log(appeal.hasApplicationForm);\r\n\r\n if(!appeal.hasApplicationForm) {\r\n await this.appealApplicationService.createNewApplication(appeal.appealID);\r\n }\r\n\r\n this.upgradeNavigationServiceHandler.go('appealApplication', {appealId: appeal.appealID});\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'parenthetical-currency',\r\n template: `\r\n = 0\">{{value | currency: 'USD':'symbol-narrow'}}\r\n ({{math.abs(value) | currency: 'USD':'symbol-narrow'}})\r\n `\r\n})\r\nexport class ParentheticalCurrencyComponent {\r\n @Input() value: number;\r\n math = Math;\r\n}","\r\n
\r\n \r\n
\r\n
\r\n No accrual details to show\r\n
\r\n
0\" class=\"accrual-detail\">\r\n
\r\n
\r\n
\r\n \r\n {{accrualDetail.collector}}\r\n
\r\n
\r\n \r\n {{accrualDetail.isRecurring ? 'Recurring' : 'One Time'}}\r\n
\r\n
\r\n \r\n {{accrualDetail.taxAmount | currency: 'USD':'symbol-narrow'}}\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n - \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Acct. PeriodDurationTax AmountBase ExpenseTrue Up (Dn)Period ExpenseTotal ExpensedRemainingPayment AmtPrepaid BalancePayable Balance
{{row.accountingPeriodName}}{{row.durationText}}\r\n Adjustment - {{row.reconcileDescription}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
    \r\n
  • {{item.name}}
  • \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BillClusterService } from '../Taxes/bill-cluster.service';\r\nimport * as moment from 'moment';\r\nimport * as _ from 'lodash';\r\nimport { MessageBoxButtons, MessageBoxResult, MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\n\r\nexport enum AccrualRowActionEnum {\r\n AddRowBefore = 1,\r\n AddRowAfter = 2,\r\n Override = 3,\r\n NoAction = 4\r\n}\r\n\r\ninterface BillClusterAccrualDetailDtoUI extends Core.BillClusterAccrualDetailDTO {\r\n accrualDetailRows: AccrualDetailRowUI[];\r\n}\r\n\r\nexport interface AccrualDetailRowUI extends Core.AccrualDetailRow {\r\n isHovered: boolean;\r\n isEditAdjustment: boolean;\r\n isAddAdjustment: boolean;\r\n isEditOverridden: boolean;\r\n durationText: string;\r\n}\r\n\r\n@Component({\r\n selector: 'accrual-detail-modal',\r\n templateUrl: './accrual-detail.component.html',\r\n styleUrls: ['./accrual-detail.component.scss']\r\n})\r\nexport class AccrualDetailModalComponent implements OnInit {\r\n constructor(\r\n public modalRef: BsModalRef,\r\n private readonly _billClusterService: BillClusterService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n ) { }\r\n\r\n // From initialState\r\n editMode: boolean;\r\n billClusterId: number;\r\n\r\n accrualDetail: BillClusterAccrualDetailDtoUI;\r\n loading: boolean = false;\r\n originalRow: AccrualDetailRowUI;\r\n rowMenuItems: Compliance.NameValuePair[] = [];\r\n currentlyEditing = false;\r\n showBalances: boolean;\r\n AccrualRowActionEnum = AccrualRowActionEnum;\r\n\r\n async ngOnInit() {\r\n this.loading = true;\r\n this.showBalances = false;\r\n\r\n try {\r\n const accrualDetail = await this._billClusterService.getAccrualDetails(this.billClusterId);\r\n this.accrualDetail = this._mapUIRows(accrualDetail) as BillClusterAccrualDetailDtoUI;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n setupRowMenu(row: AccrualDetailRowUI, i: number): void {\r\n this.rowMenuItems = [];\r\n const subsequentRows = _.drop(this.accrualDetail.accrualDetailRows, i + 1);\r\n const precedingRow = this.accrualDetail.accrualDetailRows[i - 1];\r\n const followingRow = this.accrualDetail.accrualDetailRows[i + 1];\r\n\r\n if(row.isProjected) {\r\n if (!precedingRow || precedingRow.accountingPeriodId != row.accountingPeriodId) {\r\n this.rowMenuItems.push(this._getAddBeforeItem());\r\n }\r\n\r\n if(_.some(subsequentRows, 'isProjected')) {\r\n if (followingRow && followingRow.accountingPeriodId != row.accountingPeriodId) {\r\n this.rowMenuItems.push(this._getAddAfterItem());\r\n }\r\n\r\n this.rowMenuItems.push(this._getOverrideItem());\r\n }\r\n } else {\r\n if (_.every(subsequentRows, 'isProjected') && followingRow && followingRow.accountingPeriodId != row.accountingPeriodId) {\r\n this.rowMenuItems.push(this._getAddAfterItem());\r\n }\r\n }\r\n\r\n if (!this.rowMenuItems.length) {\r\n this.rowMenuItems.push({ value: AccrualRowActionEnum.NoAction, name: 'No action can be taken' });\r\n }\r\n }\r\n\r\n performRowAction(row: AccrualDetailRowUI, item: Compliance.NameValuePair, i: number): void {\r\n if(item.value == AccrualRowActionEnum.AddRowBefore || item.value == AccrualRowActionEnum.AddRowAfter) {\r\n const newRow: AccrualDetailRowUI = _.cloneDeep(row);\r\n newRow.isAddAdjustment = true;\r\n newRow.isReconcileRow = true;\r\n newRow.isProjected = false;\r\n\r\n const idxToInsert = item.value == AccrualRowActionEnum.AddRowBefore ? i : i + 1;\r\n this.accrualDetail.accrualDetailRows.splice(idxToInsert, 0, newRow);\r\n } else {\r\n this.originalRow = _.cloneDeep(row);\r\n row.isEditOverridden = true;\r\n }\r\n\r\n this.currentlyEditing = true;\r\n }\r\n\r\n async updateAccrual(): Promise {\r\n const updateRequest: Core.BillClusterAccrualUpdateRequest = {\r\n accrualAdjustmentMethod: this.accrualDetail.accrualAdjustmentMethod,\r\n billClusterAccrualSetupRowVersion: this.accrualDetail.billClusterAccrualSetupRowVersion,\r\n billClusterId: this.billClusterId,\r\n fullyExpenseNext: this.accrualDetail.fullyExpenseNext,\r\n billClusterRowVersion: this.accrualDetail.billClusterRowVersion\r\n };\r\n\r\n this.loading = true;\r\n\r\n try {\r\n const accrualDetail = await this._billClusterService.updateAccrualDetails(this.billClusterId, updateRequest);\r\n this.accrualDetail = this._mapUIRows(accrualDetail) as BillClusterAccrualDetailDtoUI;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n updateShowBalances(): void {\r\n this.modalRef.setClass('modal-xl');\r\n }\r\n\r\n saveAdjustment(row: AccrualDetailRowUI, i: number): void {\r\n if (row.isEditOverridden) {\r\n this._saveOverride(row, false);\r\n } else {\r\n this._saveAdjustment(row, i);\r\n }\r\n }\r\n\r\n async revertTrueUp(row: AccrualDetailRowUI): Promise {\r\n const msgBoxResult = await this._messageBoxService.open({\r\n title: 'Confirm',\r\n message: 'Are you sure you want to revert the True Up?',\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n\r\n if (msgBoxResult === MessageBoxResult.Yes) {\r\n this._saveOverride(row, true);\r\n }\r\n }\r\n\r\n editAdjustment(row: AccrualDetailRowUI): void {\r\n this.originalRow = _.cloneDeep(row);\r\n row.isEditAdjustment = true;\r\n this.currentlyEditing = true;\r\n }\r\n\r\n cancelAdjustment(row: AccrualDetailRowUI): void {\r\n if (row.isEditAdjustment || row.isEditOverridden) {\r\n _.assign(row, this.originalRow);\r\n } else {\r\n this.accrualDetail.accrualDetailRows = _.reject(this.accrualDetail.accrualDetailRows, 'isAddAdjustment');\r\n }\r\n\r\n this.currentlyEditing = false;\r\n }\r\n\r\n async deleteAdjustment(row: AccrualDetailRowUI, i: number): Promise {\r\n const msgBoxResult = await this._messageBoxService.open({\r\n title: 'Confirm',\r\n message: 'Are you sure you want to delete the adjustment?',\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n\r\n if (msgBoxResult === MessageBoxResult.No) {\r\n return;\r\n }\r\n\r\n const removeRequest: Core.BillClusterAccrualAdjustmentRemoveRequest = {\r\n accountingPeriodId: row.accountingPeriodId,\r\n billClusterRowVersion: this.accrualDetail.billClusterRowVersion,\r\n billClusterAccrualSetupRowVersion: this.accrualDetail.billClusterAccrualSetupRowVersion,\r\n billClusterId: this.billClusterId,\r\n isPrior: this._getIsPrior(row, i)\r\n };\r\n\r\n this.loading = true;\r\n\r\n try {\r\n const accrualDetail = await this._billClusterService.deleteAccrualAdjustment(this.billClusterId, removeRequest);\r\n this.accrualDetail = this._mapUIRows(accrualDetail) as BillClusterAccrualDetailDtoUI;\r\n } finally {\r\n this.loading = false;\r\n this.currentlyEditing = false;\r\n }\r\n }\r\n\r\n getDateRange(row: AccrualDetailRowUI): string {\r\n return `${moment(row.beginDate).utc().format('M/D/Y')} - ${moment(row.endDate).utc().format('M/D/Y')}`;\r\n }\r\n\r\n close(): void {\r\n this.modalRef.hide();\r\n }\r\n\r\n private _mapUIRows(accrualDetail: Core.BillClusterAccrualDetailDTO): Core.BillClusterAccrualDetailDTO {\r\n accrualDetail.accrualDetailRows = _.map(accrualDetail.accrualDetailRows, (row: AccrualDetailRowUI) => {\r\n row.isAddAdjustment = row.isEditAdjustment = row.isEditOverridden = row.isHovered = false;\r\n row.durationText = this._getDurationText(row);\r\n return row;\r\n });\r\n\r\n return accrualDetail;\r\n }\r\n\r\n private _getDurationText(row: AccrualDetailRowUI): string {\r\n switch (row.accountingDurationType) {\r\n case Core.AccountingDurationTypeEnum.Monthly:\r\n return '1 Mo';\r\n case Core.AccountingDurationTypeEnum.Quarterly:\r\n return '1 Qtr';\r\n default:\r\n return `${moment(row.endDate).diff(row.beginDate, 'days') + 1} days`;\r\n }\r\n }\r\n\r\n private _getAddBeforeItem(): Compliance.NameValuePair {\r\n return { value: AccrualRowActionEnum.AddRowBefore, name: 'Add Row Before' };\r\n }\r\n\r\n private _getAddAfterItem(): Compliance.NameValuePair {\r\n return { value: AccrualRowActionEnum.AddRowAfter, name: 'Add Row After' };\r\n }\r\n\r\n private _getOverrideItem(): Compliance.NameValuePair {\r\n return { value: AccrualRowActionEnum.Override, name: 'Override' };\r\n }\r\n\r\n private async _saveOverride(row: AccrualDetailRowUI, shouldRevert: boolean): Promise {\r\n const overrideRequest: Core.BillClusterAccrualOverrideRequest = {\r\n accountingPeriodId: row.accountingPeriodId,\r\n billClusterRowVersion: this.accrualDetail.billClusterRowVersion,\r\n billClusterAccrualSetupRowVersion: this.accrualDetail.billClusterAccrualSetupRowVersion,\r\n billClusterId: this.billClusterId,\r\n revert: shouldRevert,\r\n trueUp: row.trueUp\r\n };\r\n\r\n this.loading = true;\r\n\r\n try {\r\n const accrualDetail = await this._billClusterService.overrideAccrualTrueUp(this.billClusterId, overrideRequest);\r\n this.accrualDetail = this._mapUIRows(accrualDetail) as BillClusterAccrualDetailDtoUI;\r\n } catch (e) {\r\n this.cancelAdjustment(row);\r\n } finally {\r\n this.loading = false;\r\n this.currentlyEditing = false;\r\n }\r\n }\r\n\r\n private async _saveAdjustment(row: AccrualDetailRowUI, i: number): Promise {\r\n const adjustmentRequest: Core.BillClusterAccrualAdjustmentRequest = {\r\n accountingPeriodId: row.accountingPeriodId,\r\n billClusterRowVersion: this.accrualDetail.billClusterRowVersion,\r\n billClusterAccrualSetupRowVersion: this.accrualDetail.billClusterAccrualSetupRowVersion,\r\n billClusterId: this.billClusterId,\r\n isPrior: this._getIsPrior(row, i),\r\n reconcileDescription: row.reconcileDescription,\r\n trueUp: row.trueUp\r\n };\r\n\r\n this.loading = true;\r\n\r\n try {\r\n const accrualDetail = row.isEditAdjustment\r\n ? await this._billClusterService.updateAccrualAdjustment(this.billClusterId, adjustmentRequest)\r\n : await this._billClusterService.addAccrualAdjustment(this.billClusterId, adjustmentRequest);\r\n\r\n this.accrualDetail = this._mapUIRows(accrualDetail) as BillClusterAccrualDetailDtoUI;\r\n } catch (e) {\r\n this.cancelAdjustment(row);\r\n } finally {\r\n this.loading = false;\r\n this.currentlyEditing = false;\r\n }\r\n }\r\n\r\n private _getIsPrior(row: AccrualDetailRowUI, i: number): boolean {\r\n const nextRow = this.accrualDetail.accrualDetailRows[i + 1];\r\n return nextRow && nextRow.accountingPeriodId == row.accountingPeriodId;\r\n }\r\n}\r\n","import { CollectorPayment } from '../../Assessor-Collector/Collector/Billing-Scenario/billingScenario.models';\r\n\r\ndeclare const moment: any;\r\n\r\nexport class Payment {\r\n\tconstructor() {\r\n\t\tthis.paymentAmount = 0;\r\n\t\tthis.discountAmount = 0;\r\n\t\tthis.interestAmount = 0;\r\n\t\tthis.penaltyAmount = 0;\r\n\t\tthis.dueDate = moment().startOf('day').toDate();\r\n\t\tthis.directAsmt = 0;\r\n\t\tthis.name = 'Payment';\r\n\t\tthis.accrualsExclude = {\r\n\t\t\texcludeFromAccruals: false,\r\n\t\t\tparentExcludedFromAccruals: false\r\n\t\t};\r\n\t}\r\n\r\n billID: number;\r\n\tcollectorPayment: CollectorPayment;\r\n\tcollectorPaymentID: number;\r\n\tdiscountAmount: number;\r\n\tdueDate: Date;\r\n\tdueDateOverridden: boolean;\r\n\tdueDateString: string;\r\n\tefAction: string;\r\n\tpaymentAmount: number;\r\n\tpaymentID: number;\r\n\tinterestAmount: number;\r\n\tpenaltyAmount: number;\r\n\tprocessedDate: Date;\r\n\tprocessedDateString: string;\r\n\tSeriesIsComplete: boolean;\r\n\toriginalDueDate: Date;\r\n\tdirectAsmt: number;\r\n\tattachmentID: string;\r\n\tcheckNumber: string;\r\n\tcheckDate: Date;\r\n\t// previouslyPaid: boolean;\r\n\taccrualBegin: Date;\r\n\taccrualEnd: Date;\r\n\toriginalAccrualBegin: Date;\r\n\toriginalAccrualEnd: Date;\r\n\tpostDate: Date;\r\n\taccrualsExclude: Core.AccrualsExcludeSummaryModel;\r\n\texemptionAmount: number;\r\n\tcompletedPaymentPackageCount: number;\r\n\tbelongsToPaymentBatchId?: number;\r\n\tbelongsToPaymentBatchNo?: string;\r\n\r\n\t// Derived Values\r\n\tgrossPayment: number;\r\n\tname: string;\r\n\ttaskSummary: any;\r\n\tdueDateChanged: boolean;\r\n}\r\n","import { CollectorPaymentOption } from '../../Assessor-Collector/Collector/Billing-Scenario/billingScenario.models';\r\nimport { Payment } from './payment.model';\r\n\r\nexport class Bill {\r\n\tconstructor() {\r\n\t\tthis.billClusterID = 0;\r\n\t\tthis.payments = [new Payment()];\r\n\t}\r\n\r\n\tbillClusterID: number;\r\n\tbillID: number;\r\n\tcollectorPaymentOption: CollectorPaymentOption;\r\n\tcollectorPaymentOptionID: number;\r\n\tefAction: string;\r\n\thasAttachments: boolean;\r\n\thasComments: boolean;\r\n\tname: string;\r\n\tpayments: Payment[];\r\n\treceivedDate: Date;\r\n\treceivedDateString: string;\r\n\ttabName: string;\r\n\tstatus: number;\r\n\tcalcProjected: boolean;\r\n\tdirectAsmt: number;\r\n\tannualAssessmentID: number;\r\n\trowVersion: string;\r\n\tbillClusterRowVersion: string;\r\n\tisSupplemental: boolean;\r\n\tprorationPct: number;\r\n\tdisplayProrationPct: number;\r\n\tshowActualCheckbox: boolean;\r\n\thasInProgressIntakeItems: boolean;\r\n\r\n\t//Derived Values\r\n\tbillAmount: number;\r\n\tcollectorPaymentOptions: CollectorPaymentOption[];\r\n\ttaskSummary: any;\r\n}\r\n","import { Collector } from '../../Assessor-Collector/collector.model';\r\nimport { Bill } from './bill.model';\r\nimport { Refund } from './refund.model';\r\n\r\nexport class BillCluster {\r\n\tconstructor(annualYearID: number, collectorID: number) {\r\n\t\tthis.billClusterID = 0;\r\n\t\tthis.annualYearID = annualYearID;\r\n\t\tthis.collectorID = collectorID;\r\n\t\tthis.bills = [new Bill()];\r\n\t\tthis.allPaymentsExcludedFromAccrual = false;\r\n\t}\r\n\r\n\tannualYear: number;\r\n\tannualYearID: number;\r\n\tbillClusterID: number;\r\n\tbills: Bill[];\r\n\tcollector: Collector;\r\n\tcollectorID: number;\r\n\ttaxRateAreaId: number;\r\n\thasAvailableTaxSetup: boolean;\r\n\tefAction: string;\r\n\trowVersion: any;\r\n\trefundRowVersion: any;\r\n\tisAccrualsAvailable: boolean;\r\n\taccrualsEnabled: boolean;\r\n\r\n\t//Derived Values\r\n\tshowExtraFields: {bill: boolean, payment: boolean};\r\n\trefund: Refund;\r\n\ticon: string;\r\n\ttitle: string;\r\n\tactive: boolean;\r\n\ttaskSummariesPromise: Promise;\r\n\tallPaymentsExcludedFromAccrual: boolean;\r\n\tdisabled: boolean;\r\n}\r\n","import { Collector } from '../../Assessor-Collector/collector.model';\r\n\r\nexport class Refund {\r\n\tconstructor(annualYearID: number, collectorID: number) {\r\n\t\tthis.annualYearID = annualYearID;\r\n\t\tthis.collectorID = collectorID;\r\n\t}\r\n\r\n\tannualYearID: number;\r\n\tcollector: Collector;\r\n\tcollectorID: number;\r\n\tefAction: string;\r\n\texpectedDate: Date;\r\n\thasComments: boolean;\r\n\thasAttachments: boolean;\r\n\trefundAmount: number;\r\n\trefundID: number;\r\n\trefundRowVersion: string;\r\n\tannualYear: any;\r\n\trowVersion: any;\r\n\taccrualBegin: Date;\r\n\taccrualEnd: Date;\r\n\toriginalAccrualBegin: Date;\r\n\toriginalAccrualEnd: Date;\r\n\tcheckNumber: string;\r\n\thasInProgressIntakeItems: boolean;\r\n\tannualAssessmentID: number;\r\n\r\n\t// Derived Values\r\n\ttaskSummary: any;\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { Payment } from 'src/app/Annual-Details/Taxes/payment.model';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { AttachmentService } from '../attachment.service';\r\nimport { EntityType } from 'src/app/constants.new';\r\nimport { find, map } from 'lodash';\r\nimport { Attachment } from '../attachment.model';\r\nimport { DocumentServiceUpgrade } from 'src/app/Documents/document.service.upgrade';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\nexport interface BillImageModalParams {\r\n billId: number;\r\n payment: Payment;\r\n}\r\n\r\nexport interface BillImageModalResult {\r\n saved: boolean;\r\n attachmentId: string;\r\n}\r\n\r\n@Component({\r\n selector: 'bill-image-modal',\r\n template: `\r\n \r\n \r\n
\r\n

None Selected

\r\n

Error Loading Attachment

\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n `\r\n})\r\n\r\nexport class BillImageModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _attachmentService: AttachmentService,\r\n private _modalRef: BsModalRef,\r\n private _http: HttpClient,\r\n private readonly _documentService: DocumentServiceUpgrade) { }\r\n\r\n params: BillImageModalParams;\r\n result: BillImageModalResult = {\r\n saved: false,\r\n attachmentId: ''\r\n };\r\n\r\n selectedAttachmentId: string;\r\n file: File;\r\n attachments: Attachment[];\r\n fileError: boolean;\r\n serverAction: boolean = false;\r\n\r\n async ngOnInit() {\r\n this.selectedAttachmentId = this.params.payment.attachmentID ? this.params.payment.attachmentID.toString() : '';\r\n\r\n this.serverAction = true;\r\n\r\n try {\r\n let attachments = await this._attachmentService.getAll(EntityType.TaxBill, this.params.billId, false);\r\n\r\n attachments = map(attachments, attachment => {\r\n attachment.attachmentID = attachment.attachmentID.toString();\r\n attachment.description = attachment.description || 'No Description';\r\n return attachment;\r\n });\r\n\r\n attachments.unshift({\r\n attachmentID: '',\r\n description: ''\r\n } as Attachment);\r\n\r\n this.attachments = attachments;\r\n await this.loadAttachment();\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n async loadAttachment() {\r\n const selectedAttachment = find(this.attachments, {attachmentID: this.selectedAttachmentId});\r\n\r\n if(!selectedAttachment?.attachmentID) {\r\n this.file = undefined;\r\n return;\r\n }\r\n\r\n const { previewSupported, type } = this._attachmentService.getMimeTypeByFileExtension(selectedAttachment?.fileExtension);\r\n\r\n try {\r\n const response = await this._documentService.getDocumentBody(selectedAttachment.attachmentID);\r\n const fileName = this._attachmentService.getFileNameFromHttpResponse(response, true);\r\n const fileNameType = fileName.split('.')[1].substring(0, 3);\r\n const blob = new Blob([response.data], { type: fileNameType });\r\n\r\n if (previewSupported) {\r\n this.file = new File([blob], fileName, { type });\r\n } else {\r\n await this._documentService.saveFile(blob, fileName);\r\n }\r\n } catch {\r\n this.fileError = true;\r\n }\r\n\r\n }\r\n\r\n async save() {\r\n this.serverAction = true;\r\n\r\n try {\r\n const request = this._http.patch('api/payment', {\r\n paymentID: this.params.payment.paymentID,\r\n attachmentID: this.selectedAttachmentId || null\r\n });\r\n\r\n await lastValueFrom(request);\r\n this.result = {\r\n saved: true,\r\n attachmentId: this.selectedAttachmentId\r\n };\r\n this._modalRef.hide();\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n cancel() {\r\n this._modalRef.hide();\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { Bill } from '../../../Annual-Details/Taxes/bill.model';\r\nimport { BillClusterTaxRateSetupModalResult } from './billClusterTaxRateSetupModal.component';\r\n\r\n// TODO: This should probably be integrated with the tax rate service (I'm making it as a separate service for now\r\n// until the feature is done)\r\n\r\n@Injectable()\r\nexport class ParcelTaxRateService {\r\n constructor (private http: HttpClient) { }\r\n\r\n // TODO: Perhaps the current \"ByParcel\" versions should be the only versions that exist, and we should delete\r\n // the versions of these endpoints that use parcelCollectorId so that the UI is more consistent.\r\n async getAvailableTaxRateAreas(parcelCollectorId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `/api/ParcelCollector/${parcelCollectorId}/AvailableTaxRateAreas`\r\n ));\r\n }\r\n\r\n async getAvailableTaxAuthorities(parcelCollectorId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `/api/ParcelCollector/${parcelCollectorId}/AvailableTaxAuthorities`\r\n ));\r\n }\r\n\r\n async getAvailableTaxRateAreasByParcel(parcelId: number, collectorId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `/api/ParcelCollector/Parcel/${parcelId}/Collector/${collectorId}/AvailableTaxRateAreas`\r\n ));\r\n }\r\n\r\n async getAvailableTaxAuthoritiesByParcel(parcelId: number, collectorId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `/api/ParcelCollector/Parcel/${parcelId}/Collector/${collectorId}/AvailableTaxAuthorities`\r\n ));\r\n }\r\n\r\n async getCollectorsByParcelId(parcelId: number): Promise {\r\n const params = {parcelid: parcelId};\r\n return await lastValueFrom(this.http.get('/api/ParcelCollector/', { params })) as Promise;\r\n }\r\n\r\n async getAvailableTaxRateAreasForBillCluster(billClusterId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `/api/BillCluster/${billClusterId}/AvailableTaxRateAreas`\r\n ));\r\n }\r\n\r\n async getAvailableTaxAuthoritiesForBillCluster(billClusterId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `/api/BillCluster/${billClusterId}/AvailableTaxAuthorities`\r\n ));\r\n }\r\n\r\n async getTaxRateSetup(parcelCollectorId: number, year: number) {\r\n return await lastValueFrom(this.http.get(\r\n `/api/ParcelCollector/${parcelCollectorId}/Year/${year}/TaxRateSetup`\r\n ));\r\n }\r\n\r\n async getTaxRateDetails(billClusterId: number, processingBill: Bill) {\r\n if (processingBill) {\r\n return await lastValueFrom(this.http.post(\r\n `/api/BillCluster/${billClusterId}/FetchCurrentTaxRateDetails`,\r\n processingBill\r\n ));\r\n }\r\n else {\r\n return await lastValueFrom(this.http.get(\r\n `/api/BillCluster/${billClusterId}/TaxRateDetails`\r\n ));\r\n }\r\n }\r\n\r\n async searchTaxRateSetup(parcelCollectorId: number, year: number, taxRateAreaId: number, taxAuthorityIds: number[]) {\r\n return await lastValueFrom(this.http.post(\r\n `/api/ParcelCollector/${parcelCollectorId}/Year/${year}/FetchTaxRateSetup`, {\r\n taxRateAreaId: taxRateAreaId,\r\n taxAuthorityIds: taxAuthorityIds\r\n }\r\n ));\r\n }\r\n\r\n async searchTaxRateSetupByParcel(parcelId: number, collectorId: number, year: number, taxRateAreaId: number, taxAuthorityIds: number[]) {\r\n return await lastValueFrom(this.http.post(\r\n `/api/ParcelCollector/Parcel/${parcelId}/Collector/${collectorId}/Year/${year}/FetchTaxRateSetup`, {\r\n taxRateAreaId: taxRateAreaId,\r\n taxAuthorityIds: taxAuthorityIds\r\n }\r\n ));\r\n }\r\n\r\n async searchTaxRateDetails(billClusterId: number, taxRateAreaId: number, taxAuthorityIds: number[], processingBill: Bill) {\r\n return await lastValueFrom(this.http.post(\r\n `/api/BillCluster/${billClusterId}/FetchTaxRateDetails`, {\r\n taxRateAreaId: taxRateAreaId,\r\n taxAuthorityIds: taxAuthorityIds,\r\n billOverride: processingBill\r\n }\r\n ));\r\n }\r\n\r\n async getCollectorTaxRateDetails(billClusterId: number, processingBill: Bill) {\r\n if (processingBill) {\r\n return await lastValueFrom(this.http.post(\r\n `/api/BillCluster/${billClusterId}/FetchCollectorTaxRateDetails`,\r\n processingBill\r\n ));\r\n }\r\n else {\r\n return await lastValueFrom(this.http.get(\r\n `/api/BillCluster/${billClusterId}/CollectorTaxRateDetails`\r\n ));\r\n }\r\n }\r\n\r\n async saveTaxRateSetup(\r\n parcelCollectorId: number,\r\n parcelCollectorRowVersion: string,\r\n taxRateAreaId: number,\r\n taxAuthorityIds: number[]\r\n ) {\r\n return await lastValueFrom(this.http.put<{ parcelCollectorRowVersion }>(\r\n `/api/ParcelCollector/${parcelCollectorId}/TaxRateSetup`, {\r\n taxRateAreaId,\r\n taxAuthorityIds,\r\n parcelCollectorRowVersion\r\n }\r\n ));\r\n }\r\n\r\n async saveTaxRateDetails(\r\n billClusterId: number,\r\n billClusterRowVersion: string,\r\n taxRateAreaId: number,\r\n taxAuthorityIds: number[]\r\n ) {\r\n return await lastValueFrom(this.http.put<{ billClusterRowVersion }>(\r\n `/api/BillCluster/${billClusterId}/TaxRateDetails`, {\r\n billClusterRowVersion,\r\n taxRateAreaId,\r\n taxAuthorityIds\r\n }\r\n ));\r\n }\r\n\r\n async getFirstEncounterData(taxAuthorityId: number, taxYear: number) {\r\n return await lastValueFrom(this.http.get(\r\n `/api/TaxAuthority/${taxAuthorityId}/Year/${taxYear}/FirstEncounter`\r\n ));\r\n }\r\n\r\n async saveFirstEncounterData(taxAuthorityId: number, taxYear: number, request: FirstEncounterSaveRequest) {\r\n return await lastValueFrom(this.http.post(\r\n `/api/TaxAuthority/${taxAuthorityId}/Year/${taxYear}/FirstEncounter`,\r\n request\r\n ));\r\n }\r\n}\r\n\r\n// TODO: These models should be exported from the API\r\nexport class AvailableTaxAuthority {\r\n taxAuthorityId: number;\r\n name: string;\r\n code: string;\r\n}\r\nexport class AvailableTaxRateArea {\r\n taxRateAreaId: number;\r\n name: string;\r\n code: string;\r\n}\r\nexport class TaxAuthorityRate {\r\n taxAuthorityId: number;\r\n name: string;\r\n code: string;\r\n efAction?: string;\r\n taxAuthorityCategoryId: number;\r\n taxableAssessmentTypeId: number;\r\n taxAuthorityStatusId: number;\r\n rate: number;\r\n taxYear: number;\r\n qcRequestTimeUtc?: Date;\r\n qcRequestUserId?: string;\r\n qcRequestUserFullName?: string;\r\n}\r\nexport class TaxRateSetup {\r\n taxRateAreaId: number;\r\n name: string;\r\n code: string;\r\n taxAuthorities: TaxAuthorityRate[];\r\n}\r\nexport class TaxAuthorityRateDetails extends TaxAuthorityRate {\r\n assessedValue: number;\r\n assessedValueAdjustment: number;\r\n taxableAssessedValue: number;\r\n annualTaxAmount: number;\r\n}\r\nexport class TaxRateDetails {\r\n taxRateAreaId: number;\r\n name: string;\r\n code: string;\r\n taxAuthorities: TaxAuthorityRateDetails[];\r\n usingParentRates: boolean;\r\n totalTaxRate: number;\r\n totalTaxAmount: number;\r\n directAssessmentTaxAmount: number;\r\n calculatedTaxAmount: number;\r\n totalBillTaxAmount: number;\r\n otherBillTaxAmount: number;\r\n taxAmountVariance: number;\r\n}\r\n\r\nexport interface TaxSetupMinimumDTO {\r\n taxRateAreaId: number;\r\n taxAuthorities: { taxAuthorityId: number }[];\r\n}\r\n\r\nexport class FirstEncounterSaveRequest\r\n{\r\n trackBillId?: number;\r\n rate: number;\r\n attachmentId: string;\r\n}\r\n\r\nexport class FirstEncounterSaveResult\r\n{\r\n initialBillClusterRowVersion: string;\r\n initialBillRowVersion: string;\r\n finalBillClusterRowVersion: string;\r\n finalBillRowVersion: string;\r\n updateVersion: boolean;\r\n inProcessTaxSetupChanges: BillClusterTaxRateSetupModalResult;\r\n}\r\n\r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\n\r\n@Injectable()\r\nexport class TaxRatesService {\r\n constructor (private http: HttpClient) {\r\n }\r\n\r\n private isGroupByEnabled: boolean;\r\n\r\n setIsGroupByEnabled(isGroupByEnabled: boolean) {\r\n this.isGroupByEnabled = isGroupByEnabled;\r\n }\r\n\r\n getIsGroupByEnabled() {\r\n return this.isGroupByEnabled;\r\n }\r\n}\r\n","
\r\n

\r\n Parcel Collector Tax Rate Setup\r\n - {{title}}\r\n

\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n Tax Rate Area:\r\n {{model.name || '(none)'}}\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n 0)\">\r\n \r\n \r\n \r\n
CodeTax AuthorityCategoryAssessment SourceRate
{{taxAuthority.code}}{{taxAuthority.name}}{{taxAuthorityCategoryName(taxAuthority.taxAuthorityCategoryId)}}{{taxableAssessmentTypeName(taxAuthority.taxableAssessmentTypeId)}}\r\n {{taxAuthority.rate * 100 | number:\"1.6-6\"}}\r\n \r\n \r\n \r\n \r\n
\r\n 0 && !readOnly\"\r\n [ngModel]=\"newTaxAuthorityId\"\r\n (ngModelChange)=\"onNewTaxAuthorityChange($event)\"\r\n [disabled]=\"loading\"\r\n class=\"form-select form-select-sm new-tax-auth\"\r\n >\r\n \r\n \r\n \r\n \r\n (no more available tax authorities to add)\r\n \r\n Total:{{totalRate * 100 | number:\"1.6-6\"}}
\r\n
\r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnInit, ViewChild, ElementRef } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { Constants, TaxAuthorityStatuses } from '../../../constants.new';\r\nimport { AvailableTaxRateArea, AvailableTaxAuthority, ParcelTaxRateService, TaxRateSetup, TaxAuthorityRate, TaxSetupMinimumDTO } from './parcelTaxRateService';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Subscriber } from 'rxjs';\r\nimport { TaxRatesService } from '../../../Assessor-Collector/Tax-Rates/tax.rates.service';\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment-timezone';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\nexport class ParcelCollectorTaxRateSetupModalResult {\r\n parcelCollectorId: number;\r\n rowVersion: string;\r\n taxRateAreaId: number;\r\n taxRateAreaName: string;\r\n taxRateAreaCode: string;\r\n taxAuthorityCount: number;\r\n taxAuthorities?: TaxAuthorityRate[];\r\n}\r\n\r\n@Component({\r\n templateUrl: './parcelCollectorTaxRateSetupModal.component.html'\r\n})\r\nexport class ParcelCollectorTaxRateSetupModalComponent implements OnInit {\r\n constructor(\r\n private bsModalRef: BsModalRef,\r\n private toastr: ToastrService,\r\n private parcelTaxRateService: ParcelTaxRateService,\r\n private taxRatesService: TaxRatesService,\r\n public constants: Constants,\r\n private featureFlagsService: FeatureFlagsService\r\n ) { }\r\n\r\n @ViewChild('taxRateAreaInput')\r\n private taxRateAreaInputRef: ElementRef;\r\n // loadingAll indicates the whole modal should be hidden with a loading indicator; loading just means\r\n // disable the controls temporarily while additional data is coming in\r\n loadingAll: boolean;\r\n loading: boolean;\r\n readOnly: boolean;\r\n isDirty: boolean;\r\n availableTaxRateAreas: AvailableTaxRateArea[];\r\n availableTaxAuthorities: AvailableTaxAuthority[];\r\n filteredAvailableTaxAuthorities: AvailableTaxAuthority[];\r\n model: TaxRateSetup;\r\n parcelCollectorId: number;\r\n parcelCollectorRowVersion: string;\r\n parcelId: number;\r\n collectorId: number;\r\n originalTaxAuthorities: TaxAuthorityRate[];\r\n originalTaxRateAreaId: number;\r\n overrideSetup: TaxSetupMinimumDTO;\r\n totalRate: number;\r\n availableYears: number[];\r\n displayYear: number;\r\n title: string;\r\n groupByCategory: boolean;\r\n currentTaxAuthorityGroups: {\r\n taxAuthorityCategoryId: number,\r\n categoryName: string,\r\n taxAuthorities: TaxAuthorityRate[]\r\n }[];\r\n modalResultSubscriber: Subscriber;\r\n newTaxAuthorityId: string;\r\n totalEstimated: boolean;\r\n isDocumentProcessing: boolean;\r\n enableTrueRateBasedSystem: boolean;\r\n\r\n async ngOnInit() {\r\n this.loadingAll = true;\r\n this.groupByCategory = this.taxRatesService.getIsGroupByEnabled();\r\n this.newTaxAuthorityId = '';\r\n this.enableTrueRateBasedSystem = this.featureFlagsService.featureFlags.enableTrueRateBasedSystem;\r\n // The modal launch service should provide year data, but as a fallback use the current year\r\n // and +-5 years from current year.\r\n if (!this.displayYear) {\r\n this.displayYear = (new Date()).getFullYear();\r\n }\r\n if (!this.availableYears) {\r\n this.availableYears = [];\r\n this.availableYears = [];\r\n for (let i = this.displayYear + 5; i > this.displayYear - 5; i--) {\r\n this.availableYears.push(i);\r\n }\r\n }\r\n\r\n try {\r\n if (this.parcelCollectorId) {\r\n if (this.overrideSetup) {\r\n let modelPromise = Promise.resolve({\r\n taxRateAreaId: null,\r\n name: null,\r\n code: null,\r\n taxAuthorities: []\r\n });\r\n\r\n if (this.overrideSetup.taxRateAreaId) {\r\n modelPromise = this.getTaxSetupByRateArea(this.overrideSetup.taxRateAreaId);\r\n }\r\n else if (this.overrideSetup.taxAuthorities && this.overrideSetup.taxAuthorities.length > 0) {\r\n modelPromise = this.getTaxSetupByAuthorities(this.overrideSetup.taxAuthorities.map(ta => ta.taxAuthorityId));\r\n }\r\n\r\n [this.availableTaxAuthorities, this.availableTaxRateAreas, this.model] = await Promise.all([\r\n this.parcelTaxRateService.getAvailableTaxAuthorities(this.parcelCollectorId),\r\n this.parcelTaxRateService.getAvailableTaxRateAreas(this.parcelCollectorId),\r\n modelPromise\r\n ]);\r\n }\r\n else {\r\n [this.availableTaxAuthorities, this.availableTaxRateAreas, this.model] = await Promise.all([\r\n this.parcelTaxRateService.getAvailableTaxAuthorities(this.parcelCollectorId),\r\n this.parcelTaxRateService.getAvailableTaxRateAreas(this.parcelCollectorId),\r\n this.parcelTaxRateService.getTaxRateSetup(this.parcelCollectorId, this.displayYear)\r\n ]);\r\n }\r\n }\r\n else {\r\n [this.availableTaxAuthorities, this.availableTaxRateAreas] = await Promise.all([\r\n this.parcelTaxRateService.getAvailableTaxAuthoritiesByParcel(this.parcelId, this.collectorId),\r\n this.parcelTaxRateService.getAvailableTaxRateAreasByParcel(this.parcelId, this.collectorId)\r\n ]);\r\n\r\n this.model = {\r\n taxRateAreaId: null,\r\n name: null,\r\n code: null,\r\n taxAuthorities: []\r\n };\r\n if (this.originalTaxAuthorities || this.originalTaxRateAreaId) {\r\n this.model.taxRateAreaId = this.originalTaxRateAreaId;\r\n if (this.originalTaxRateAreaId) {\r\n const taxRateArea = this.availableTaxRateAreas.find(tra => tra.taxRateAreaId === this.originalTaxRateAreaId);\r\n if (taxRateArea) {\r\n this.model.name = taxRateArea.name;\r\n this.model.code = taxRateArea.code;\r\n }\r\n else {\r\n // This shouldn't happen in practice except in pathological cases (where a user deletes a tax rate area while\r\n // another user is actively adding that tax rate area to a parcel)\r\n this.model.name = '(invalid)';\r\n }\r\n }\r\n this.model.taxAuthorities = this.originalTaxAuthorities || [];\r\n }\r\n }\r\n\r\n this.onModelChange(true);\r\n this.isDirty = false;\r\n }\r\n finally {\r\n this.loadingAll = false;\r\n }\r\n }\r\n\r\n onTaxRateAreaTextChange() {\r\n if (this.taxRateAreaInputRef.nativeElement.value == '') {\r\n this.clearSelectedTaxRateAreaId();\r\n }\r\n else {\r\n this.taxRateAreaInputRef.nativeElement.value = this.model.name;\r\n }\r\n }\r\n\r\n async onTaxRateAreaIdChange(event: TypeaheadMatch) {\r\n try {\r\n this.loadingAll = true;\r\n this.model = await this.getTaxSetupByRateArea(event.item.taxRateAreaId);\r\n this.onModelChange();\r\n }\r\n finally {\r\n this.loadingAll = false;\r\n }\r\n }\r\n\r\n clearSelectedTaxRateAreaId() {\r\n this.isDirty = true;\r\n Object.assign(this.model, { taxRateAreaId: null, name: null, code: null });\r\n }\r\n\r\n closeModal() {\r\n this.bsModalRef.hide();\r\n }\r\n\r\n async addNewTaxAuthority(newAvailableTaxAuthority: AvailableTaxAuthority) {\r\n this.loading = true;\r\n try {\r\n const newTaxAuthority = await this.getTaxAuthority(newAvailableTaxAuthority.taxAuthorityId);\r\n if (newTaxAuthority) {\r\n this.model.taxAuthorities.push(newTaxAuthority);\r\n this.onModelChange();\r\n }\r\n }\r\n finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n removeTaxAuthority(taxAuthority: TaxAuthorityRate) {\r\n this.model.taxAuthorities = this.model.taxAuthorities.filter(a => a.taxAuthorityId !== taxAuthority.taxAuthorityId);\r\n this.onModelChange();\r\n }\r\n\r\n onModelChange(skipDirtySet?: boolean) {\r\n if (!skipDirtySet) {\r\n this.isDirty = true;\r\n }\r\n this.filteredAvailableTaxAuthorities = _.sortBy(this.availableTaxAuthorities.filter(avail =>\r\n !this.model.taxAuthorities.some(a => avail.taxAuthorityId === a.taxAuthorityId)),\r\n [function(ta) { return ta.name.toLowerCase(); }]);\r\n this.totalRate = this.model.taxAuthorities.reduce((acc, val) => acc + val.rate, 0);\r\n this.totalEstimated = this.model.taxAuthorities.some(ta => ta.taxAuthorityStatusId !== TaxAuthorityStatuses.Actual);\r\n if (this.groupByCategory) {\r\n const distinctCategoryIds = [...new Set(this.model.taxAuthorities.map(ta => ta.taxAuthorityCategoryId))];\r\n this.currentTaxAuthorityGroups = _.chain(distinctCategoryIds)\r\n .map(c => {\r\n return {\r\n taxAuthorityCategoryId: c,\r\n categoryName: c ? this.constants.TaxAuthorityCategories[c].displayName : null,\r\n taxAuthorities: _.chain(this.model.taxAuthorities)\r\n .filter(ta => ta.taxAuthorityCategoryId == c)\r\n .sortBy('name')\r\n .value()\r\n };\r\n })\r\n .sortBy('categoryName')\r\n .value();\r\n }\r\n else {\r\n this.currentTaxAuthorityGroups = [{\r\n taxAuthorityCategoryId: 0,\r\n categoryName: null,\r\n taxAuthorities: _.sortBy(this.model.taxAuthorities, 'name')\r\n }];\r\n }\r\n }\r\n\r\n async onDisplayYearChange($event: string) {\r\n this.displayYear = +$event;\r\n this.loading = true;\r\n try {\r\n if (this.model.taxRateAreaId) {\r\n this.model = await this.getTaxSetupByRateArea(this.model.taxRateAreaId);\r\n }\r\n else {\r\n this.model = await this.getTaxSetupByAuthorities(this.model.taxAuthorities.map(a => a.taxAuthorityId));\r\n }\r\n this.onModelChange(true);\r\n }\r\n finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n onGroupByCategoryChanged($event: boolean) {\r\n this.groupByCategory = $event;\r\n this.taxRatesService.setIsGroupByEnabled($event);\r\n this.onModelChange(true);\r\n }\r\n\r\n async save() {\r\n if (!this.isDirty) {\r\n this.closeModal();\r\n return;\r\n }\r\n if (!this.parcelCollectorId || this.isDocumentProcessing) {\r\n const modalResult = {\r\n parcelCollectorId: null,\r\n rowVersion: null,\r\n taxRateAreaId: null,\r\n taxRateAreaName: null,\r\n taxRateAreaCode: null,\r\n taxAuthorityCount: 0,\r\n taxAuthorities: null\r\n };\r\n\r\n if (this.model.taxRateAreaId) {\r\n modalResult.taxRateAreaId = this.model.taxRateAreaId;\r\n modalResult.taxRateAreaName = this.model.name;\r\n modalResult.taxRateAreaCode = this.model.code;\r\n }\r\n else {\r\n modalResult.taxAuthorityCount = this.model.taxAuthorities.length;\r\n modalResult.taxAuthorities = this.model.taxAuthorities;\r\n }\r\n this.modalResultSubscriber.next(modalResult);\r\n this.modalResultSubscriber.complete();\r\n this.bsModalRef.hide();\r\n }\r\n else {\r\n this.loadingAll = true;\r\n try {\r\n const { parcelCollectorRowVersion } = await this.parcelTaxRateService.saveTaxRateSetup(\r\n this.parcelCollectorId,\r\n this.parcelCollectorRowVersion,\r\n this.model.taxRateAreaId,\r\n this.model.taxRateAreaId ? [] : this.model.taxAuthorities.map(ta => ta.taxAuthorityId)\r\n );\r\n const modalResult = {\r\n parcelCollectorId: this.parcelCollectorId,\r\n rowVersion: parcelCollectorRowVersion,\r\n taxRateAreaId: null,\r\n taxRateAreaName: null,\r\n taxRateAreaCode: null,\r\n taxAuthorityCount: 0\r\n };\r\n\r\n if (this.model.taxRateAreaId) {\r\n modalResult.taxRateAreaId = this.model.taxRateAreaId;\r\n modalResult.taxRateAreaName = this.model.name;\r\n modalResult.taxRateAreaCode = this.model.code;\r\n }\r\n else {\r\n modalResult.taxAuthorityCount = this.model.taxAuthorities.length;\r\n }\r\n\r\n this.modalResultSubscriber.next(modalResult);\r\n this.modalResultSubscriber.complete();\r\n this.bsModalRef.hide();\r\n this.toastr.success('Parcel Collector Tax Rate Setup Saved');\r\n }\r\n catch (err) {\r\n this.loadingAll = false;\r\n throw err;\r\n }\r\n }\r\n }\r\n\r\n onNewTaxAuthorityChange(newTaxAuthorityId: string) {\r\n this.newTaxAuthorityId = '';\r\n if (newTaxAuthorityId) {\r\n this.addNewTaxAuthority(this.availableTaxAuthorities.find(ta => ta.taxAuthorityId == +newTaxAuthorityId));\r\n }\r\n }\r\n\r\n async getTaxAuthority(taxAuthorityId: number) {\r\n return (await this.getTaxSetupByAuthorities([taxAuthorityId])).taxAuthorities[0];\r\n }\r\n\r\n async getTaxSetupByAuthorities(taxAuthorityIds: number[]) {\r\n if (this.parcelCollectorId) {\r\n return await this.parcelTaxRateService.searchTaxRateSetup(\r\n this.parcelCollectorId,\r\n this.displayYear,\r\n null,\r\n taxAuthorityIds);\r\n }\r\n else {\r\n return await this.parcelTaxRateService.searchTaxRateSetupByParcel(\r\n this.parcelId,\r\n this.collectorId,\r\n this.displayYear,\r\n null,\r\n taxAuthorityIds);\r\n }\r\n }\r\n\r\n async getTaxSetupByRateArea(taxRateAreaId: number) {\r\n if (this.parcelCollectorId) {\r\n return await this.parcelTaxRateService.searchTaxRateSetup(\r\n this.parcelCollectorId,\r\n this.displayYear,\r\n taxRateAreaId,\r\n null);\r\n }\r\n else {\r\n return await this.parcelTaxRateService.searchTaxRateSetupByParcel(\r\n this.parcelId,\r\n this.collectorId,\r\n this.displayYear,\r\n taxRateAreaId,\r\n null);\r\n }\r\n }\r\n\r\n rateClass(taxAuthority: TaxAuthorityRate) {\r\n switch (taxAuthority.taxAuthorityStatusId) {\r\n case TaxAuthorityStatuses.Estimated:\r\n return 'estimated';\r\n case TaxAuthorityStatuses.Pending:\r\n return 'pending';\r\n default:\r\n return '';\r\n }\r\n }\r\n\r\n taTooltip(taxAuthority: TaxAuthorityRate) {\r\n let result: string = null;\r\n if (taxAuthority.taxAuthorityStatusId === TaxAuthorityStatuses.Pending) {\r\n if (taxAuthority.qcRequestTimeUtc) {\r\n result = `QC requested at ${ moment(taxAuthority.qcRequestTimeUtc).tz('America/Chicago').format('M/D/Y h:mm a')}`;\r\n if (taxAuthority.qcRequestUserFullName) {\r\n result += ` by ${ taxAuthority.qcRequestUserFullName}`;\r\n }\r\n }\r\n }\r\n\r\n return result;\r\n }\r\n\r\n taxableAssessmentTypeName(taxableAssessmentTypeId: number) {\r\n if (!taxableAssessmentTypeId) {\r\n return null;\r\n }\r\n\r\n const taxableAssessmentType = this.enableTrueRateBasedSystem\r\n ? this.constants.TaxableAssessmentTypesForTrueRate[taxableAssessmentTypeId]\r\n : this.constants.TaxableAssessmentTypes[taxableAssessmentTypeId];\r\n\r\n if (!taxableAssessmentType) {\r\n return null;\r\n }\r\n return taxableAssessmentType.displayName;\r\n }\r\n\r\n taxAuthorityCategoryName(taxAuthorityCategoryId: number) {\r\n if (!taxAuthorityCategoryId) {\r\n return null;\r\n }\r\n const taxAuthorityCategory = this.constants.TaxAuthorityCategories[taxAuthorityCategoryId];\r\n if (!taxAuthorityCategory) {\r\n return null;\r\n }\r\n return taxAuthorityCategory.displayName;\r\n }\r\n}\r\n","
\r\n

\r\n Bill Cluster Tax Rate Details\r\n - {{title}}\r\n

\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n Tax Rate Area:\r\n {{model.name || '(none)'}}\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n 0)\">\r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
CodeTax AuthorityCategoryTaxable Asmt TypeAssessmentAdjustmentTaxable AsmtRateAnnual Tax Amount
{{taxAuthority.code}}{{taxAuthority.name}}{{taxAuthorityCategoryName(taxAuthority.taxAuthorityCategoryId)}}{{taxableAssessmentTypeName(taxAuthority.taxableAssessmentTypeId)}}{{taxAuthority.assessedValue | number:\"1.0-0\"}}{{taxAuthority.assessedValueAdjustment | number:\"1.0-0\"}}{{taxAuthority.taxableAssessedValue | number:\"1.0-0\"}}\r\n {{taxAuthority.rate * 100 | number:\"1.6-6\"}}\r\n \r\n ${{taxAuthority.annualTaxAmount | number:\"1.2-2\"}}\r\n \r\n \r\n \r\n \r\n
\r\n 0\"\r\n [ngModel]=\"newTaxAuthorityId\"\r\n (ngModelChange)=\"onNewTaxAuthorityChange($event)\"\r\n [disabled]=\"loading\"\r\n class=\"form-select form-select-sm new-tax-auth\"\r\n >\r\n \r\n \r\n \r\n \r\n (no more available tax authorities to add)\r\n \r\n Total Ad Valorem:{{model.totalTaxRate * 100 | number:\"1.6-6\"}}${{model.totalTaxAmount | number:\"1.2-2\"}}
Direct Asmt:${{model.directAssessmentTaxAmount | number:\"1.2-2\"}}
System Calculated Tax:${{model.calculatedTaxAmount | number:\"1.2-2\"}}
Total Bill Amount(s):${{model.totalBillTaxAmount | number:\"1.2-2\"}}
\r\n Variance:${{model.taxAmountVariance | number:\"1.2-2\"}}
\r\n
\r\n Note that ${{model.otherBillTaxAmount | number:\"1.2-2\"}} of the bill amount is from tax bills not displayed here\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n","import { Component, OnInit, ViewChild, ElementRef } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { Constants, TaxAuthorityStatuses } from '../../../constants.new';\r\nimport { MessageBoxService, MessageBoxButtons, MessageBoxResult } from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport {\r\n AvailableTaxRateArea,\r\n AvailableTaxAuthority,\r\n ParcelTaxRateService,\r\n TaxAuthorityRate,\r\n TaxRateDetails,\r\n TaxAuthorityRateDetails,\r\n TaxSetupMinimumDTO,\r\n FirstEncounterSaveResult\r\n} from './parcelTaxRateService';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { TaxRatesService } from '../../../Assessor-Collector/Tax-Rates/tax.rates.service';\r\nimport { Subscriber } from 'rxjs';\r\nimport * as _ from 'lodash';\r\nimport { Bill } from '../../../Annual-Details/Taxes/bill.model';\r\nimport * as moment from 'moment-timezone';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\nexport class BillClusterTaxRateSetupModalResult {\r\n taxRateAreaId: number;\r\n taxAuthorityIds: number[];\r\n rowVersion: string;\r\n}\r\n\r\n@Component({\r\n templateUrl: './billClusterTaxRateSetupModal.component.html'\r\n})\r\nexport class BillClusterTaxRateSetupModalComponent implements OnInit {\r\n constructor(\r\n private bsModalRef: BsModalRef,\r\n private toastr: ToastrService,\r\n private parcelTaxRateService: ParcelTaxRateService,\r\n private taxRatesService: TaxRatesService,\r\n private messageBoxService: MessageBoxService,\r\n public constants: Constants,\r\n private featureFlagsService: FeatureFlagsService\r\n ) { }\r\n\r\n @ViewChild('taxRateAreaInput')\r\n private taxRateAreaInputRef: ElementRef;\r\n // loadingAll indicates the whole modal should be hidden with a loading indicator; loading just means\r\n // disable the controls temporarily while additional data is coming in\r\n loadingAll: boolean;\r\n loading: boolean;\r\n availableTaxRateAreas: AvailableTaxRateArea[];\r\n availableTaxAuthorities: AvailableTaxAuthority[];\r\n filteredAvailableTaxAuthorities: AvailableTaxAuthority[];\r\n model: TaxRateDetails;\r\n billClusterId: number;\r\n billClusterRowVersion: string;\r\n groupByCategory: boolean;\r\n currentTaxAuthorityGroups: { taxAuthorityCategoryId: number, categoryName: string, taxAuthorities: TaxAuthorityRateDetails[] }[];\r\n title: string;\r\n billEstimated: boolean;\r\n totalEstimated: boolean;\r\n newTaxAuthorityId: string;\r\n modalResultSubscriber: Subscriber;\r\n readOnly: boolean;\r\n isDocumentProcessing: boolean;\r\n overrideSetup: BillClusterTaxRateSetupModalResult;\r\n processingParcelTaxSetup: TaxSetupMinimumDTO;\r\n processingBill: Bill;\r\n firstEncounterTaxAuthority: TaxAuthorityRateDetails;\r\n intakeAttachmentId: string;\r\n hasProcessingChanges: boolean;\r\n calcProjected: boolean;\r\n // I'd like to use Angular forms handling for a dirty flag, but it seems this works much better\r\n // for reactive forms than it does for template-driven forms. For now, just use a flag.\r\n isDirty: boolean;\r\n enableTrueRateBasedSystem: boolean;\r\n firstEncounterSavedCallback: (result: FirstEncounterSaveResult) => Promise;\r\n\r\n async ngOnInit() {\r\n this.loadingAll = true;\r\n this.newTaxAuthorityId = '';\r\n this.firstEncounterTaxAuthority = null;\r\n this.groupByCategory = this.taxRatesService.getIsGroupByEnabled();\r\n this.enableTrueRateBasedSystem = this.featureFlagsService.featureFlags.enableTrueRateBasedSystem;\r\n\r\n try {\r\n // The model is usually determined from the bill cluster, however document processing allows for an\r\n // overrideSetup object. If such an object is present, get the model based on the tax rate area, tax\r\n // authorities, or from the parcel collector as appropriate.\r\n let modelPromise: Promise;\r\n if (!this.overrideSetup) {\r\n // Another wrinkle, it's possible to change the parcel setup on document processing before\r\n // opening this modal. In that case, the API will have the actual saved values, and we might\r\n // need the intermediate values (saved in processingParcelTaxSetup). getTaxDetailsForParent\r\n // automatically adjusts for this, but in this case use special handling to re-fetch the values\r\n // if this is synched to the parcel.\r\n modelPromise = new Promise(async (res) => {\r\n let details = await this.getCurrentTaxDetails();\r\n if (this.processingParcelTaxSetup && details.usingParentRates) {\r\n details = await this.getTaxDetailsForParent();\r\n }\r\n res(details);\r\n });\r\n }\r\n else if (this.overrideSetup.taxRateAreaId) {\r\n modelPromise = this.getTaxDetailsByRateArea(this.overrideSetup.taxRateAreaId);\r\n }\r\n else if (this.overrideSetup.taxAuthorityIds && this.overrideSetup.taxAuthorityIds.length > 0) {\r\n modelPromise = this.getTaxDetailsByAuthorities(this.overrideSetup.taxAuthorityIds);\r\n }\r\n else {\r\n modelPromise= this.getTaxDetailsForParent();\r\n }\r\n\r\n [this.availableTaxAuthorities, this.availableTaxRateAreas, this.model] = await Promise.all([\r\n this.parcelTaxRateService.getAvailableTaxAuthoritiesForBillCluster(this.billClusterId),\r\n this.parcelTaxRateService.getAvailableTaxRateAreasForBillCluster(this.billClusterId),\r\n modelPromise\r\n ]);\r\n\r\n this.onModelChange(true);\r\n this.isDirty = false;\r\n }\r\n finally {\r\n this.loadingAll = false;\r\n }\r\n }\r\n\r\n onTaxRateAreaTextChange() {\r\n if (this.taxRateAreaInputRef.nativeElement.value == '') {\r\n this.clearSelectedTaxRateAreaId();\r\n }\r\n else {\r\n this.taxRateAreaInputRef.nativeElement.value = this.model.name;\r\n }\r\n }\r\n\r\n async onTaxRateAreaIdChange(event: TypeaheadMatch) {\r\n try {\r\n this.loadingAll = true;\r\n this.model = await this.getTaxDetailsByRateArea(event.item.taxRateAreaId);\r\n this.onModelChange();\r\n }\r\n finally {\r\n this.loadingAll = false;\r\n }\r\n }\r\n\r\n clearSelectedTaxRateAreaId() {\r\n Object.assign(this.model, { taxRateAreaId: null, name: null, code: null });\r\n this.isDirty = true;\r\n }\r\n\r\n async addNewTaxAuthority(newAvailableTaxAuthority: AvailableTaxAuthority) {\r\n this.loading = true;\r\n try {\r\n const newTaxAuthority = await this.getTaxAuthority(newAvailableTaxAuthority.taxAuthorityId);\r\n if (newTaxAuthority) {\r\n this.model.taxAuthorities.push(newTaxAuthority);\r\n await this.refetchTaxDetailsForAuthorities();\r\n this.onModelChange();\r\n }\r\n }\r\n finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async removeTaxAuthority(taxAuthority: TaxAuthorityRate) {\r\n this.model.taxAuthorities = this.model.taxAuthorities.filter(a => a.taxAuthorityId !== taxAuthority.taxAuthorityId);\r\n await this.refetchTaxDetailsForAuthorities();\r\n this.onModelChange();\r\n }\r\n\r\n async refetchTaxDetailsForAuthorities() {\r\n // Re-fetch the Tax Details for all Tax Authorities to get totals re-computed.\r\n const taxAuthorityIds = this.model.taxAuthorities.map(a => a.taxAuthorityId);\r\n this.model = await this.getTaxDetailsByAuthorities(taxAuthorityIds);\r\n }\r\n\r\n async refreshFromModel() {\r\n if (this.model.usingParentRates) {\r\n this.model = await this.getTaxDetailsForParent();\r\n }\r\n else if (this.model.taxRateAreaId) {\r\n this.model = await this.getTaxDetailsByRateArea(this.model.taxRateAreaId);\r\n }\r\n else {\r\n this.model = await this.getTaxDetailsByAuthorities(this.model.taxAuthorities ? this.model.taxAuthorities.map(a => a.taxAuthorityId) : []);\r\n }\r\n this.onModelChange(true);\r\n }\r\n\r\n onModelChange(skipDirtySet?: boolean) {\r\n if (!skipDirtySet) {\r\n this.isDirty = true;\r\n }\r\n this.filteredAvailableTaxAuthorities = _.sortBy(this.availableTaxAuthorities.filter(avail =>\r\n !this.model.taxAuthorities.some(a => avail.taxAuthorityId === a.taxAuthorityId)),\r\n [function(ta) { return ta.name.toLowerCase(); }]);\r\n this.totalEstimated = this.model.taxAuthorities.some(ta => ta.taxAuthorityStatusId !== TaxAuthorityStatuses.Actual);\r\n if (this.groupByCategory) {\r\n const distinctCategoryIds = [...new Set(this.model.taxAuthorities.map(ta => ta.taxAuthorityCategoryId))];\r\n this.currentTaxAuthorityGroups = _.chain(distinctCategoryIds)\r\n .map(c => {\r\n return {\r\n taxAuthorityCategoryId: c,\r\n categoryName: c ? this.constants.TaxAuthorityCategories[c].displayName : null,\r\n taxAuthorities: this.model.taxAuthorities\r\n .filter(ta => ta.taxAuthorityCategoryId == c)\r\n .sort((x, y) => x.name.localeCompare(y.name))\r\n };\r\n })\r\n .sortBy('categoryName')\r\n .value();\r\n }\r\n else {\r\n this.currentTaxAuthorityGroups = [{\r\n taxAuthorityCategoryId: 0,\r\n categoryName: null,\r\n taxAuthorities: this.model.taxAuthorities.sort((x, y) => x.name.localeCompare(y.name))\r\n }];\r\n }\r\n }\r\n\r\n onGroupByCategoryChanged($event: boolean) {\r\n this.groupByCategory = $event;\r\n this.taxRatesService.setIsGroupByEnabled($event);\r\n this.onModelChange(true);\r\n }\r\n\r\n async onUsingParentRatesChanged($event: boolean) {\r\n let confirmed = !$event ? true : false;\r\n if ($event) {\r\n confirmed = await this.confirmSwitchToParentRates();\r\n }\r\n if (confirmed) {\r\n this.model.usingParentRates = $event;\r\n if ($event) {\r\n try {\r\n this.loadingAll = true;\r\n this.model = await this.getTaxDetailsForParent();\r\n }\r\n finally {\r\n this.loadingAll = false;\r\n }\r\n }\r\n }\r\n else {\r\n this.model.usingParentRates = false;\r\n }\r\n this.onModelChange();\r\n }\r\n\r\n async confirmSwitchToParentRates(): Promise {\r\n const result = await this.messageBoxService.open({\r\n message: 'Are you sure you want to discard this configuration and Sync to parcel\\'s Collector defaults?',\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n return result === MessageBoxResult.OK;\r\n }\r\n\r\n async closeModal() {\r\n let shouldClose = true;\r\n\r\n if (this.isDirty) {\r\n const confirmResult = await this.messageBoxService.open({\r\n message: 'You have unsaved changes; are you sure you wish to leave?',\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n shouldClose = confirmResult === MessageBoxResult.OK;\r\n }\r\n\r\n if (shouldClose) {\r\n this.bsModalRef.hide();\r\n }\r\n }\r\n\r\n async save() {\r\n if (!this.isDirty) {\r\n this.bsModalRef.hide();\r\n return;\r\n }\r\n\r\n this.loadingAll = true;\r\n try {\r\n const modalResult = await this.getModalResult();\r\n this.modalResultSubscriber.next(modalResult);\r\n this.modalResultSubscriber.complete();\r\n this.bsModalRef.hide();\r\n if (!this.isDocumentProcessing) {\r\n this.toastr.success('Bill Cluster Tax Rate Setup Saved');\r\n }\r\n }\r\n catch (err) {\r\n this.loadingAll = false;\r\n throw err;\r\n }\r\n }\r\n\r\n onNewTaxAuthorityChange(newTaxAuthorityId: string) {\r\n this.newTaxAuthorityId = '';\r\n if (newTaxAuthorityId) {\r\n this.addNewTaxAuthority(this.availableTaxAuthorities.find(ta => ta.taxAuthorityId == +newTaxAuthorityId));\r\n }\r\n }\r\n\r\n async getTaxAuthority(taxAuthorityId: number) {\r\n return (await this.getTaxDetailsByAuthorities([taxAuthorityId])).taxAuthorities[0];\r\n }\r\n\r\n async getCurrentTaxDetails() {\r\n return await this.parcelTaxRateService.getTaxRateDetails(this.billClusterId, this.processingBill);\r\n }\r\n\r\n async getTaxDetailsByAuthorities(taxAuthorityIds: number[]) {\r\n return await this.parcelTaxRateService.searchTaxRateDetails(\r\n this.billClusterId,\r\n null,\r\n taxAuthorityIds,\r\n this.processingBill);\r\n }\r\n\r\n async getTaxDetailsByRateArea(taxRateAreaId: number) {\r\n return await this.parcelTaxRateService.searchTaxRateDetails(\r\n this.billClusterId,\r\n taxRateAreaId,\r\n null,\r\n this.processingBill);\r\n }\r\n\r\n async getTaxDetailsForParent() {\r\n let result: TaxRateDetails;\r\n\r\n if (!this.processingParcelTaxSetup) {\r\n result = await this.parcelTaxRateService.getCollectorTaxRateDetails(this.billClusterId, this.processingBill);\r\n }\r\n else {\r\n if (this.processingParcelTaxSetup.taxRateAreaId) {\r\n result = await this.getTaxDetailsByRateArea(this.processingParcelTaxSetup.taxRateAreaId);\r\n }\r\n else if (this.processingParcelTaxSetup.taxAuthorities && this.processingParcelTaxSetup.taxAuthorities) {\r\n result = await this.getTaxDetailsByAuthorities(this.processingParcelTaxSetup.taxAuthorities.map(ta => ta.taxAuthorityId));\r\n }\r\n else {\r\n result = await this.getTaxDetailsByAuthorities([]);\r\n }\r\n result.usingParentRates = true;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n showFirstEncounter(taxAuthority: TaxAuthorityRateDetails) {\r\n return this.isDocumentProcessing && taxAuthority && taxAuthority.taxAuthorityStatusId === TaxAuthorityStatuses.Estimated;\r\n }\r\n\r\n startFirstEncounter(taxAuthority: TaxAuthorityRateDetails) {\r\n if (this.isDocumentProcessing) {\r\n this.firstEncounterTaxAuthority = taxAuthority;\r\n }\r\n }\r\n\r\n async endFirstEncounter(reload: boolean, result?: FirstEncounterSaveResult) {\r\n this.firstEncounterTaxAuthority = null;\r\n if (reload) {\r\n this.loading = true;\r\n try {\r\n result.updateVersion = this.hasProcessingChanges && !this.calcProjected;\r\n if (this.isDirty) {\r\n result.inProcessTaxSetupChanges = await this.getModalResult();\r\n }\r\n await this.firstEncounterSavedCallback(result);\r\n if (!result.updateVersion) {\r\n this.bsModalRef.hide();\r\n }\r\n else {\r\n await this.refreshFromModel();\r\n }\r\n }\r\n finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n\r\n rateClass(taxAuthority: TaxAuthorityRateDetails) {\r\n switch (taxAuthority.taxAuthorityStatusId) {\r\n case TaxAuthorityStatuses.Estimated:\r\n return 'estimated';\r\n case TaxAuthorityStatuses.Pending:\r\n return 'pending';\r\n default:\r\n return '';\r\n }\r\n }\r\n\r\n taTooltip(taxAuthority: TaxAuthorityRateDetails) {\r\n let result: string = null;\r\n if (taxAuthority.taxAuthorityStatusId === TaxAuthorityStatuses.Pending) {\r\n if (taxAuthority.qcRequestTimeUtc) {\r\n result = `QC requested at ${ moment(taxAuthority.qcRequestTimeUtc).tz('America/Chicago').format('M/D/Y h:mm a')}`;\r\n if (taxAuthority.qcRequestUserFullName) {\r\n result += ` by ${ taxAuthority.qcRequestUserFullName}`;\r\n }\r\n }\r\n }\r\n\r\n return result;\r\n }\r\n\r\n taxableAssessmentTypeName(taxableAssessmentTypeId: number) {\r\n if (!taxableAssessmentTypeId) {\r\n return null;\r\n }\r\n\r\n const taxableAssessmentType = this.enableTrueRateBasedSystem\r\n ? this.constants.TaxableAssessmentTypesForTrueRate[taxableAssessmentTypeId]\r\n : this.constants.TaxableAssessmentTypes[taxableAssessmentTypeId];\r\n\r\n if (!taxableAssessmentType) {\r\n return null;\r\n }\r\n return taxableAssessmentType.displayName;\r\n }\r\n\r\n taxAuthorityCategoryName(taxAuthorityCategoryId: number) {\r\n if (!taxAuthorityCategoryId) {\r\n return null;\r\n }\r\n const taxAuthorityCategory = this.constants.TaxAuthorityCategories[taxAuthorityCategoryId];\r\n if (!taxAuthorityCategory) {\r\n return null;\r\n }\r\n return taxAuthorityCategory.displayName;\r\n }\r\n\r\n private async getModalResult(): Promise {\r\n let taxRateAreaId: number = null;\r\n let taxAuthorityIds: number[] = [];\r\n // If we're using parent rates, clear out all existing entries. Otherwise, prefer the\r\n // taxRateAreaId if it exists, falling back to the model's tax authorities array otherwise.\r\n if (!this.model.usingParentRates) {\r\n if (this.model.taxRateAreaId) {\r\n taxRateAreaId = this.model.taxRateAreaId;\r\n }\r\n else {\r\n taxAuthorityIds = this.model.taxAuthorities.map(ta => ta.taxAuthorityId);\r\n }\r\n }\r\n\r\n let modalResult = {\r\n rowVersion: null,\r\n taxRateAreaId,\r\n taxAuthorityIds\r\n };\r\n\r\n if (!this.isDocumentProcessing) {\r\n const { billClusterRowVersion } = await this.parcelTaxRateService.saveTaxRateDetails(\r\n this.billClusterId,\r\n this.billClusterRowVersion,\r\n taxRateAreaId,\r\n taxAuthorityIds\r\n );\r\n modalResult = {\r\n rowVersion: billClusterRowVersion,\r\n taxRateAreaId,\r\n taxAuthorityIds\r\n };\r\n }\r\n\r\n return modalResult;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { ParcelCollectorTaxRateSetupModalComponent, ParcelCollectorTaxRateSetupModalResult } from './parcelCollectorTaxRateSetupModal.component';\r\nimport { BillClusterTaxRateSetupModalComponent, BillClusterTaxRateSetupModalResult } from './billClusterTaxRateSetupModal.component';\r\nimport { Observable } from 'rxjs';\r\nimport { TaxAuthorityRate, TaxSetupMinimumDTO, FirstEncounterSaveResult } from './parcelTaxRateService';\r\nimport { Bill } from '../../../Annual-Details/Taxes/bill.model';\r\n\r\n@Injectable()\r\nexport class TaxRateSetupModalLaunchService {\r\n constructor(private modalService: BsModalService) { }\r\n\r\n openDocumentProcessingParcelTaxSetupModal(\r\n parcelId: number,\r\n parcelCollector: {\r\n parcelCollectorID?: number,\r\n rowVersion?: string,\r\n collectorID: number\r\n },\r\n overrideSetup: TaxSetupMinimumDTO,\r\n title: string,\r\n currentYear: number,\r\n readOnly: boolean\r\n ) {\r\n return new Observable(subscriber => {\r\n const initialState = {\r\n parcelId,\r\n parcelCollectorId: parcelCollector.parcelCollectorID,\r\n parcelCollectorRowVersion: parcelCollector.rowVersion,\r\n collectorId: parcelCollector.collectorID,\r\n displayYear: currentYear,\r\n availableYears: [currentYear],\r\n title,\r\n overrideSetup,\r\n modalResultSubscriber: subscriber,\r\n readOnly: !!readOnly,\r\n isDocumentProcessing: true\r\n };\r\n\r\n this.modalService.show(ParcelCollectorTaxRateSetupModalComponent, {\r\n initialState,\r\n ignoreBackdropClick: !readOnly,\r\n keyboard: !!readOnly,\r\n class: 'modal-lg'\r\n });\r\n });\r\n }\r\n\r\n openParcelCollectorTaxRateSetupModal(\r\n parcelId: number,\r\n parcelCollector: {\r\n parcelCollectorID?: number,\r\n rowVersion?: string,\r\n collectorID: number,\r\n taxRateAreaId?: number\r\n },\r\n title: string,\r\n availableYears: number[],\r\n currentYear: number,\r\n readOnly?: boolean,\r\n taxAuthorities?: TaxAuthorityRate[],\r\n ) {\r\n return new Observable(subscriber => {\r\n const initialState = {\r\n parcelId,\r\n parcelCollectorId: parcelCollector.parcelCollectorID,\r\n parcelCollectorRowVersion: parcelCollector.rowVersion,\r\n collectorId: parcelCollector.collectorID,\r\n originalTaxAuthorities: taxAuthorities,\r\n originalTaxRateAreaId: parcelCollector.taxRateAreaId,\r\n displayYear: currentYear,\r\n availableYears,\r\n title,\r\n modalResultSubscriber: subscriber,\r\n readOnly: !!readOnly\r\n };\r\n\r\n this.modalService.show(ParcelCollectorTaxRateSetupModalComponent, {\r\n initialState,\r\n ignoreBackdropClick: !readOnly,\r\n keyboard: !!readOnly,\r\n class: 'modal-lg'\r\n });\r\n });\r\n }\r\n\r\n openBillClusterTaxRateDetailsModal(\r\n billClusterId: number,\r\n billClusterRowVersion: string,\r\n title: string,\r\n billEstimated: boolean,\r\n readOnly?: boolean,\r\n isDocumentProcessing?: boolean,\r\n overrideSetup?: BillClusterTaxRateSetupModalResult,\r\n processingParcelTaxSetup?: TaxSetupMinimumDTO,\r\n processingBill?: Bill,\r\n intakeAttachmentId?: string,\r\n calcProjected?: boolean,\r\n hasProcessingChanges?: boolean,\r\n firstEncounterSavedCallback?: (result: FirstEncounterSaveResult) => Promise\r\n ) {\r\n return new Observable(subscriber => {\r\n const initialState = {\r\n billClusterId,\r\n billClusterRowVersion,\r\n title,\r\n billEstimated,\r\n modalResultSubscriber: subscriber,\r\n readOnly: !!readOnly,\r\n isDocumentProcessing: !!isDocumentProcessing,\r\n overrideSetup,\r\n processingParcelTaxSetup,\r\n processingBill,\r\n intakeAttachmentId,\r\n calcProjected,\r\n hasProcessingChanges,\r\n firstEncounterSavedCallback\r\n };\r\n this.modalService.show(BillClusterTaxRateSetupModalComponent, {\r\n initialState,\r\n ignoreBackdropClick: !readOnly,\r\n keyboard: !!readOnly,\r\n class: 'modal-xl'\r\n });\r\n });\r\n }\r\n}\r\n","import { Component, ViewChild } from '@angular/core';\r\nimport { ModalDirective } from 'ngx-bootstrap/modal';\r\nimport { PaymentPackagesComponent } from '../../Processing/Transmittal/payment-packages.component';\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'payment-packages-modal',\r\n templateUrl: './payment-package-modal.component.html'\r\n})\r\nexport class PaymentPackagesModalComponent {\r\n // newAppeal: Appeal;\r\n // @Input() assessments: AnnualDetailAssessment[];\r\n // @Input() appealLevels: AppealLevel[];\r\n // @Output('add') onAddAppeal: EventEmitter;\r\n\r\n @ViewChild('paymentPackagesModal', { static: true }) paymentPackageModal: ModalDirective;\r\n @ViewChild('paymentPackages', { static: true }) paymentPackages: PaymentPackagesComponent;\r\n paymentID: number;\r\n\r\n\r\n show(paymentID: number): void {\r\n this.paymentID = paymentID;\r\n this.paymentPackageModal.onHide.subscribe(() => {\r\n this.paymentPackages.closeChildModals();\r\n });\r\n this.paymentPackageModal.show();\r\n }\r\n\r\n showModalInit(): void {\r\n // this.newAppeal = new Appeal();\r\n\r\n // if (this.appealLevels && this.appealLevels.length > 0) {\r\n // this.newAppeal.appealLevelID = this.appealLevels[0].appealLevelID;\r\n // }\r\n\r\n // if (this.assessments && this.assessments.length > 0) {\r\n // this.newAppeal.annualAssessmentID = (_.minBy(this.assessments, 'revisionNum') as AnnualDetailAssessment).annualAssessmentID;\r\n // }\r\n }\r\n}","
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","
0\" [style.overflow]=\"isDocumentProcessing ? 'auto' : 'initial'\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n \r\n \r\n Bill Amt:\r\n \r\n Bill Amt:
Direct Asmt:
Assoc. Revision:
Proration %:
Payment Option:
\r\n \r\n
Base Payment Amt:
Discount Amt:
Interest:
Penalty:
Payment Amt:
Payment Due:
Exemption Amt:
Status:
Check #:
Check Date:
Pmt Post Date:
Tax Period Begin:
Tax Period End:
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n {{bill.name || \"Bill\"}}\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n {{bill.billAmount | currency:'USD'}}\r\n
\r\n \r\n {{bill.directAsmt || 0 | currency:'USD'}}\r\n
\r\n \r\n {{getAssocRevisionDesc(bill)}}\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n {{bill.displayProrationPct | number:\"1.4-4\"}}%\r\n
\r\n
\r\n \r\n\r\n \r\n \r\n {{getBillPaymentOptionName(bill)}}\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
{{payment.name}} \r\n
\r\n \r\n {{payment.grossPayment | currency:'USD'}}\r\n
\r\n \r\n {{payment.discountAmount | currency:'USD'}}\r\n
\r\n
\r\n \r\n {{payment.interestAmount | currency:'USD'}}\r\n
\r\n
\r\n
\r\n \r\n {{payment.penaltyAmount | currency:'USD'}}\r\n
\r\n
\r\n \r\n {{payment.paymentAmount | currency:'USD'}}\r\n
\r\n
\r\n
WARNING! Payment Due date is in the past
\r\n
WARNING! The date entered is later
than the system default date
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n {{payment.exemptionAmount | currency:'USD'}}\r\n
\r\n
\r\n Parent Excluded From Accruals\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n {{ payment.taskSummary.Status }} {{ payment.taskSummary.CompletedDateTime | weissmanDateFormat: true: \"Central\"}}\r\n N/A - No Responsibilities\r\n \r\n Save To view Status\r\n \r\n
\r\n \r\n \r\n
0\">\r\n \r\n Transmittal\r\n \r\n
\r\n \r\n
\r\n \r\n {{payment.checkNumber}}\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n","import { Component, EventEmitter, Input, OnChanges, Output, ViewChild, OnInit, SimpleChanges } from '@angular/core';\r\nimport { Decimal } from 'decimal.js';\r\nimport * as _ from 'lodash';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AttachmentModalData, AttachmentModalEntityData } from '../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { MessageBoxButtons, MessageBoxResult, MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { AnnualDetailsNavigationEventService } from '../annual-details-event.service';\r\nimport { AnnualDetailEditState } from '../annual-details-navigation.service';\r\nimport { AnnualDetailsService } from '../annual-details.service';\r\nimport { AnnualDetailAssessment } from '../Annual-Year/annual-year.model';\r\nimport { PaymentPackagesModalComponent } from '../Modals/payment-package-modal.component';\r\nimport { PaymentStubModalComponent } from '../Modals/payment-stub.component';\r\nimport { BillClusterService, BillViewModel, TaxesViewModel } from './bill-cluster.service';\r\nimport { Bill } from './bill.model';\r\nimport { Payment } from './payment.model';\r\nimport { StateService } from '../../Common/States/States.Service';\r\nimport { StateSummary } from '../../Common/States/state.model';\r\nimport { TaxRateSetupModalLaunchService } from '../../Entity/Parcel/TaxRateSetup/taxRateSetupModalLaunchService';\r\nimport { TaxSetupMinimumDTO, FirstEncounterSaveResult, ParcelTaxRateService, TaxRateDetails } from '../../Entity/Parcel/TaxRateSetup/parcelTaxRateService';\r\nimport { TaxAuthorityStatuses } from '../../constants.new';\r\nimport { flatMap, filter } from 'lodash/fp';\r\nimport { WeissmanModalService } from 'src/app/Compliance/WeissmanModalService';\r\nimport { BillImageModalComponent } from 'src/app/Attachment/Bill-Image-Modal/billImageModal.component';\r\nimport { AddressDetailsModalLaunchService } from '../../Common/Address/Address-View-Edit/address.details.modal.launch.service';\r\nimport { ProductAnalyticsService } from 'src/app/Common/Amplitude/productAnalytics.service';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\ndeclare const moment: any;\r\n\r\nconst TAXBILL_ENTITY_TYPE_ID = 9;\r\n\r\n@Component({\r\n\tselector: 'bills',\r\n\ttemplateUrl: './bills.component.html'\r\n})\r\nexport class BillsComponent implements OnChanges, OnInit {\r\n\r\n\tconstructor(\r\n\t\tprivate billClusterService: BillClusterService,\r\n\t\tprivate taskService: TaskService,\r\n\t\tprivate messageBoxService: MessageBoxService,\r\n\t\tprivate toastr: ToastrService,\r\n\t\tprivate annualDetailsService: AnnualDetailsService,\r\n\t\tprivate navigationEvent: AnnualDetailsNavigationEventService,\r\n private statesService: StateService,\r\n private taxRateSetupModalLaunchService: TaxRateSetupModalLaunchService,\r\n\t\tprivate modalService: WeissmanModalService,\r\n private parcelTaxRateService: ParcelTaxRateService,\r\n\t\tprivate productAnalyticsService: ProductAnalyticsService,\r\n\t\tprivate readonly addressDetailsModalLaunchService: AddressDetailsModalLaunchService,\r\n\t\tprivate featureFlagService: FeatureFlagsService\r\n ) {\r\n\t\tthis.tempVals = {};\r\n\t\tthis.allowEdit = true;\r\n\t\tthis.enableTaxPaymentAddressLink = this.featureFlagService.featureFlags.enableTaxPaymentAddressLink;\r\n\r\n\t\tthis.statesService.getSummary().then((states: StateSummary[]) => {\r\n\t\t\tconst foundState = _.find(states, { stateID: this.stateId });\r\n\r\n\t\t\tthis.stateIsSupplemental = foundState ? foundState.supplementalTaxBill : false;\r\n\t\t});\r\n\t}\r\n\r\n\t@Input() editState: AnnualDetailEditState;\r\n\t@Input() viewModel: BillViewModel;\r\n\t@Input() gridNavigationHandler: () => void;\r\n\t@Input() isDocumentProcessing: boolean = false;\r\n @Input() firstEncounterSavedCallback?: (result: FirstEncounterSaveResult) => Promise;\r\n\t@Input() taxesViewModel: TaxesViewModel;\r\n\t@Input() showExtraFields: { bill: boolean, payment: boolean };\r\n @Input() stateId: number;\r\n @Input() processingParcelTaxSetup?: TaxSetupMinimumDTO;\r\n\t@Output() RevisionChanged: EventEmitter = new EventEmitter();\r\n @Output() AnnualDetailsSaveAllowedChanged: EventEmitter = new EventEmitter();\r\n\t@Output() saveBillCluster: EventEmitter = new EventEmitter();\r\n @Input() hasProcessingChanges?: boolean;\r\n\t@ViewChild('PaymentStubModal') paymentStubModal: PaymentStubModalComponent;\r\n\t@ViewChild('PaymentPackageModal', { static: true }) paymentPackagesModal: PaymentPackagesModalComponent;\r\n\r\n\twaitingOnServer: boolean;\r\n\ttempVals;\r\n\tallowEdit: boolean;\r\n\tpaymentStubParams: { billID: number, payment: Payment };\r\n\ttaxBillEntityTypeId: number = TAXBILL_ENTITY_TYPE_ID;\r\n\tstateIsSupplemental: boolean;\r\n showActualRow: boolean;\r\n showFirstEncounterIndicator: boolean;\r\n\toldBillAmount: number;\r\n\tenableTaxPaymentAddressLink: boolean;\r\n\r\n\tngOnInit() {\r\n // This won't execute on document processing, but the different view model handler should take care of this anyway\r\n // (TODO: Test that more carefully to ensure it's happening as expected)\r\n if (this.viewModel) {\r\n this.viewModel.taskSummariesPromise\r\n .then(() => {\r\n this.showActualRow = this.showActualCheckboxRow();\r\n });\r\n }\r\n\t}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n const changeFields = Object.keys(changes);\r\n\t\tif (this.isDocumentProcessing && this.viewModel) {\r\n\t\t\tif (!this.viewModel.model[0].annualAssessmentID) {\r\n\t\t\t\tthis.viewModel.model[0].annualAssessmentID = _.maxBy(this.viewModel.yearRevisions, 'revisionNum').annualAssessmentID;\r\n }\r\n\r\n if (changeFields.some(f => f === 'processingParcelTaxSetup' || f === 'viewModel')) {\r\n this.calculateShowFirstEncounterIndicator();\r\n }\r\n\r\n\t\t\tthis.assocRevisionChanged(this.viewModel.model[0]);\r\n\t\t}\r\n }\r\n\r\n\tget analyticsCategory(): string {\r\n\t\tif(this.isDocumentProcessing) {\r\n\t\t\treturn this._atLeastOnePaymentinQC() ? 'document-qc' : 'document-dp';\r\n\t\t} else {\r\n\t\t\treturn '';\r\n\t\t}\r\n\t}\r\n\r\n\tget paymentDuePadding(): string {\r\n\t\tif (!this.editState.editMode) {\r\n\t\t\treturn '0px';\r\n\t\t}\r\n\r\n\t\tconst paymentsWithDueDatesChanged = _.flow([\r\n\t\t\tflatMap('payments'),\r\n\t\t\tfilter('dueDateChanged')\r\n\t\t])(this.viewModel.model);\r\n\r\n\t\tif (!paymentsWithDueDatesChanged.length) {\r\n\t\t\treturn '0px';\r\n\t\t}\r\n\r\n\t\tlet max = 0;\r\n\t\t_.forEach(paymentsWithDueDatesChanged, payment => {\r\n\t\t\tlet padding = 0;\r\n\t\t\tconst dueDateIsInPast = this.dueDateIsInPast(payment.dueDate);\r\n\t\t\tconst dueDateIsLaterThanOriginal = this.dueDateIsLaterThanOriginal(payment);\r\n\r\n\t\t\tif(dueDateIsInPast) {\r\n\t\t\t\tpadding = 22;\r\n\t\t\t}\r\n\r\n\t\t\tif(dueDateIsLaterThanOriginal) {\r\n\t\t\t\tpadding = 37;\r\n\t\t\t}\r\n\r\n\t\t\tif(dueDateIsInPast && dueDateIsLaterThanOriginal) {\r\n\t\t\t\tpadding = 52;\r\n\t\t\t}\r\n\r\n\t\t\tmax = padding > max ? padding : max;\r\n\t\t});\r\n\r\n\t\treturn `${max}px`;\r\n\r\n\t}\r\n\r\n calculateShowFirstEncounterIndicator() {\r\n const billClusterId = this.viewModel.model[0].billClusterID;\r\n let detailPromise: Promise = null;\r\n const makeDetailPromise = (taxRateAreaId: number, taxAuthorityIds: number[]) => {\r\n if (taxRateAreaId || (taxAuthorityIds && taxAuthorityIds.length > 0)) {\r\n return this.parcelTaxRateService.searchTaxRateDetails(\r\n billClusterId,\r\n taxRateAreaId,\r\n taxAuthorityIds,\r\n null);\r\n }\r\n return null;\r\n };\r\n\r\n if (this.viewModel.processingTaxSetupResult) {\r\n if ((this.viewModel.processingTaxSetupResult.taxAuthorityIds && this.viewModel.processingTaxSetupResult.taxAuthorityIds.length > 0) || this.viewModel.processingTaxSetupResult.taxRateAreaId) {\r\n detailPromise = makeDetailPromise(\r\n this.viewModel.processingTaxSetupResult.taxRateAreaId,\r\n this.viewModel.processingTaxSetupResult.taxAuthorityIds);\r\n }\r\n else {\r\n if (this.processingParcelTaxSetup) {\r\n detailPromise = makeDetailPromise(\r\n this.processingParcelTaxSetup.taxRateAreaId,\r\n this.processingParcelTaxSetup.taxAuthorities ?\r\n this.processingParcelTaxSetup.taxAuthorities.map(ta => ta.taxAuthorityId) :\r\n null);\r\n }\r\n else {\r\n detailPromise = this.parcelTaxRateService.getCollectorTaxRateDetails(billClusterId, null);\r\n }\r\n }\r\n }\r\n else {\r\n detailPromise = this.parcelTaxRateService.getTaxRateDetails(billClusterId, null).then(details => {\r\n if (!this.processingParcelTaxSetup || !details.usingParentRates) {\r\n return details;\r\n }\r\n else {\r\n return makeDetailPromise(\r\n this.processingParcelTaxSetup.taxRateAreaId,\r\n this.processingParcelTaxSetup.taxAuthorities ?\r\n this.processingParcelTaxSetup.taxAuthorities.map(ta => ta.taxAuthorityId) :\r\n null);\r\n }\r\n });\r\n }\r\n\r\n if (detailPromise) {\r\n detailPromise.then(details => {\r\n this.showFirstEncounterIndicator = details &&\r\n details.taxAuthorities &&\r\n details.taxAuthorities.some(ta => ta.taxAuthorityStatusId === TaxAuthorityStatuses.Estimated);\r\n });\r\n }\r\n }\r\n\r\n\tassocRevisionChanged(bill: Bill): void {\r\n\t\tconst revision = _.find(this.viewModel.yearRevisions, { annualAssessmentID: bill.annualAssessmentID }) as AnnualDetailAssessment;\r\n\r\n\t\tthis.RevisionChanged.emit(revision);\r\n\t}\r\n\r\n\tasync deletePayment(bill: Bill, payment: Payment): Promise {\r\n\t\tconst result = await this.messageBoxService.open({\r\n\t\t\tmessage: 'Confirm Deleting Payment?',\r\n\t\t\tbuttons: MessageBoxButtons.OKCancel\r\n\t\t});\r\n\r\n\t\tif (result !== MessageBoxResult.OK) {\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tthis.editState.refreshGrid = true;\r\n\r\n\t\tif (bill.payments.length > 1) {\r\n\t\t\t_.remove(bill.payments, payment);\r\n\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tif (this.viewModel.model.length > 1) {\r\n\t\t\tthis.billClusterService.deleteBill(bill.billID).then(() => {\r\n\t\t\t\t_.remove(this.viewModel.model, bill);\r\n\t\t\t\tthis.navigationEvent.refreshActivityData();\r\n\t\t\t});\r\n\t\t} else {\r\n\t\t\tif (bill.collectorPaymentOptionID) {\r\n\t\t\t\tthis.billClusterService.deleteBillCluster(bill.billClusterID).then(() => {\r\n\t\t\t\t\tthis.gridNavigationHandler();\r\n\t\t\t\t\tthis.navigationEvent.refreshActivityData();\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthis.billClusterService.deleteBill(bill.billID).then(() => {\r\n\t\t\t\t\tthis.gridNavigationHandler();\r\n\t\t\t\t\tthis.navigationEvent.refreshActivityData();\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\tmakeDiscountNegative(payment: Payment): void {\r\n\t\tif (payment.discountAmount > 0) {\r\n\t\t\tpayment.discountAmount = -payment.discountAmount;\r\n\t\t} else {\r\n\t\t\tthis.zeroIfNull(payment, 'discountAmount');\r\n\t\t}\r\n\r\n\t\tthis.paymentPropChanged(payment);\r\n\t}\r\n\r\n makeExemptionNegative(payment: Payment): void {\r\n if (payment.exemptionAmount > 0) {\r\n payment.exemptionAmount = -payment.exemptionAmount;\r\n } else {\r\n this.zeroIfNull(payment, 'exemptionAmount');\r\n }\r\n this.paymentPropChanged(payment);\r\n }\r\n\r\n dateOverridden(payment: Payment, field: string): boolean {\r\n\t\tconst current = payment[field];\r\n\t\tconst original = this._getOriginalDate(payment, field);\r\n\r\n\t\tif (!current || !original) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\r\n\t\treturn !moment(current).isSame(original);\r\n\t}\r\n\r\n\tgetBillPaymentOptionName(bill: Bill): string {\r\n\t\tif (bill.collectorPaymentOptionID === null || bill.collectorPaymentOptions === undefined) {\r\n\t\t\treturn '';\r\n\t\t} else if (bill.collectorPaymentOptions.length === 0) {\r\n\t\t\treturn bill.collectorPaymentOption ? bill.collectorPaymentOption.name : 'N/A';\r\n\t\t}\r\n\r\n\t\tconst option = _.find(bill.collectorPaymentOptions, {\r\n\t\t\tcollectorPaymentOptionID: bill.collectorPaymentOptionID\r\n\t\t});\r\n\r\n\t\treturn option ? option.name : 'N/A';\r\n\t}\r\n\r\n\tbillAmountBlurred(oldBillAmount: number, bill: Bill): void {\r\n\t\tif (oldBillAmount !== bill.billAmount) {\r\n\t\t\tthis._distribute(bill);\r\n\t\t}\r\n\t}\r\n\r\n\tpaymentPropChanged(payment): void {\r\n\t\tpayment.paymentAmount = this.billClusterService.paymentPropChanged(payment);\r\n\t\t//This recalcuates totals for the annual year\r\n\t\t// this.calcTaxTotals();\r\n\t}\r\n\r\n\t//Not liking this...\r\n\tcaptureVal(entity: any, field: string): void {\r\n\t\tsetTimeout(() => {\r\n\t\t\tthis.tempVals[field] = entity[field];\r\n\t\t}, 250);\r\n\t}\r\n\r\n\tdivide(numerator: number, divisor: number): number[] {\r\n\t\tconst results: number[] = [];\r\n\t\t// let dividend: number = parseFloat((Math.floor(numerator / divisor * 100) / 100).toFixed(2)); // dividend with 2 decimal places\r\n\r\n\t\tconst dividend: number = new Decimal(numerator).dividedBy(divisor).times(100).floor().dividedBy(100).toNumber();\r\n\r\n\t\tfor (let i = 0; i < divisor - 1; i++) {\r\n\t\t\tresults.push(dividend); // Put n-1 copies of dividend in results\r\n\t\t}\r\n\r\n\t\tconst amtWithRemainder: number = new Decimal(divisor).minus(1).neg().times(dividend).plus(numerator).toNumber();\r\n\t\tresults.unshift(amtWithRemainder); // Add remainder to first payment amt\r\n\r\n\t\treturn results;\r\n\t}\r\n\r\n\t// Possibly redistribute $ when gross payment amt changed\r\n\tgrossPaymentChanged(bill: Bill, payment: Payment): void {\r\n\t\t// if amt unchanged, no work to be done\r\n\t\tif (payment.grossPayment === this.tempVals.grossPayment) {\r\n\t\t\treturn;\r\n\t\t} else if (this.billClusterService.calcPaymentAmount(payment) < 0) {\r\n\t\t\tpayment.grossPayment = this.tempVals.grossPayment;\r\n\t\t\tthis.paymentPropChanged(payment);\r\n\r\n\t\t\t// I think this should be toast\r\n\t\t\tthis.toastr.error('Error!', 'Payment Amount Cannot be negative');\r\n\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tlet paymentIdx: number = _.findIndex(bill.payments, { paymentID: payment.paymentID });\r\n\r\n\t\t// Bug Fix - if index is -1 then it means the payment hasn't been saved yet, and this breaks the calculation\r\n\t\tif (paymentIdx < 0) {\r\n\t\t\tpaymentIdx = bill.payments.length - 1;\r\n\t\t}\r\n\r\n\t\tconst previousPayments: Payment[] = bill.payments.slice(0, paymentIdx);\r\n\t\tconst subsequentPayments: Payment[] = bill.payments.slice(paymentIdx + 1);\r\n\t\tlet totalAllocation: number = new Decimal(bill.billAmount).sub(new Decimal(payment.grossPayment)).toNumber();\r\n\r\n\t\tif (subsequentPayments.length > 0 && _.some(subsequentPayments, x => this.notProcessed(x))) {\r\n\t\t\tconst previousGross = _.chain(previousPayments)\r\n\t\t\t\t.map('grossPayment')\r\n\t\t\t\t.reduce((sum: number, num: number) => new Decimal(sum).plus(num).toNumber())\r\n\t\t\t\t.value() || 0;\r\n\r\n\t\t\t// this is us allocating previous gross payments before distributing subsequent\r\n\t\t\ttotalAllocation = new Decimal(totalAllocation).sub(previousGross).toNumber();\r\n\r\n\t\t\t// only update editable payment amounts\r\n\t\t\tconst editablePaymentIDs: number[] = _.chain(subsequentPayments)\r\n\t\t\t\t.filter(subsequentPayment => this.paymentAmountIsEditable(bill, subsequentPayment))\r\n\t\t\t\t.map('paymentID')\r\n\t\t\t\t.value();\r\n\r\n\t\t\tif(editablePaymentIDs.length && totalAllocation >= 0) {\r\n\t\t\t\t//allocate payment amounts that can't be edited\r\n\t\t\t\t_.forEach(subsequentPayments, (subsequentPayment) => {\r\n\t\t\t\t\tif(!this.paymentAmountIsEditable(bill, subsequentPayment)) {\r\n\t\t\t\t\t\ttotalAllocation = new Decimal(totalAllocation).sub(subsequentPayment.grossPayment).toNumber();\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\r\n\t\t\t\tconst evenDist: number[] = this.divide(totalAllocation, editablePaymentIDs.length);\r\n\r\n\t\t\t\t_.forEach(editablePaymentIDs, (paymentId, i) => {\r\n\t\t\t\t\tconst idx = _.findIndex(bill.payments, {paymentID: paymentId});\r\n\r\n\t\t\t\t\tbill.payments[idx].grossPayment = evenDist[i];\r\n\t\t\t\t\tthis.paymentPropChanged(bill.payments[idx]);\r\n\t\t\t\t});\r\n\t\t\t} else {\r\n\t\t\t\t// if no editable payments or total allocation is negative, transfer change to bill amount and notify the user\r\n\t\t\t\tthis._setBillAmountToSumOfPayments(bill);\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tconst firstPayment = bill.payments[0];\r\n\r\n\t\t\tif (paymentIdx === 1 && bill.payments.length === 2 && this.notProcessed(firstPayment)) {\r\n\t\t\t\tif (totalAllocation < 0) {\r\n\t\t\t\t\tthis._setBillAmountToSumOfPayments(bill);\r\n\t\t\t\t} else if(this.paymentAmountIsEditable(bill, firstPayment)) {\r\n\t\t\t\t\tfirstPayment.grossPayment = totalAllocation;\r\n\t\t\t\t\tthis.paymentPropChanged(firstPayment);\r\n\t\t\t\t} else {\r\n\t\t\t\t\tthis._setBillAmountToSumOfPayments(bill);\r\n\t\t\t\t}\r\n\t\t\t} else if (this._isTransmitIncomplete(payment)) {\r\n\t\t\t\tthis._setBillAmountToSumOfPayments(bill);\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tpayment.grossPayment = payment.paymentAmount = this.tempVals.grossPayment;\r\n\r\n\t\t\t\tthis.toastr.error('Error!', 'No unprocessed subsequent payments');\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t}\r\n\r\n\tnotProcessed(payment: Payment): boolean {\r\n\t\treturn !payment.processedDate;\r\n\t}\r\n\r\n\tshowAdd(bill: Bill): boolean {\r\n\t\treturn this.billPropertyIsEditable(bill) && !this.isDocumentProcessing;\r\n\t}\r\n\r\n\tshowClose(bill: Bill, payment: Payment): boolean {\r\n\t\treturn this.editState.editMode && !payment.collectorPaymentID && this.billPropertyIsEditable(bill) && !this.isDocumentProcessing;\r\n\t}\r\n\r\n\tdisablePaymentOptionDropdown(bill: Bill): boolean {\r\n\t\treturn _.some(bill.payments, (payment: Payment) => payment.processedDate || (payment.taskSummary && payment.taskSummary.TaxBillReceived && payment.taskSummary.ReviewPaymentComplete));\r\n\t}\r\n\r\n\tdisableAssocRevisionDropdown(bill: Bill): boolean {\r\n\t\t// return !this._atLeastOnePaymentHasAdjustNotice(bill) && (+bill.status !== 0 || (this.billHasTaskSummary(bill) && (allSeriesComplete || allReviewComplete))); turning off until we turn it on\r\n\t\treturn +bill.status !== 0 && (this.billHasTaskSummary(bill) && this._atLeastOnePaymentTransmitted(bill));\r\n\t}\r\n\r\n\taddPayment(bill: Bill) {\r\n\t\tconst newPayment = new Payment();\r\n\r\n\t\tnewPayment.billID = bill.billID;\r\n\t\tnewPayment.dueDate = moment().startOf('day').toDate();\r\n\r\n\t\tbill.payments.push(newPayment);\r\n\r\n\t\tthis.editState.setDirty(true);\r\n\t}\r\n\r\n\tzeroIfNull(payment: Payment, field: string): void {\r\n\t\tif (payment[field] === null || payment[field] === undefined || isNaN(payment[field])) {\r\n\t\t\tpayment[field] = 0;\r\n\r\n\t\t\tthis.paymentPropChanged(payment);\r\n\t\t}\r\n\t}\r\n\r\n\tpaymentAmountChanged(): void {\r\n\t\tthis.editState.staleAppealSavings = true;\r\n\t\tthis.editState.refreshGrid = true;\r\n\r\n\t\t//This recalcuates totals for the annual year\r\n\t\t// this.calcTaxTotals();\r\n\t}\r\n\r\n\tpaymentAmountBlurred(bill: Bill, payment: Payment): void {\r\n\t\tthis.zeroIfNull(payment, 'paymentAmount');\r\n\r\n\t\tpayment.grossPayment = payment.paymentAmount;\r\n\r\n\t\tthis.grossPaymentChanged(bill, payment);\r\n\t\t//This recalcuates totals for the annual year\r\n\t\t// this.calcTaxTotals();\r\n\t}\r\n\r\n\trevertIfNegative(payment: Payment, field: string): void {\r\n\t\tif (this.billClusterService.calcPaymentAmount(payment) < 0) {\r\n\t\t\tpayment[field] = this.tempVals[field];\r\n\r\n\t\t\tthis.toastr.error('Error!', 'Payment Amount Cannot be negative');\r\n\t\t}\r\n\r\n\t\tthis.paymentPropChanged(payment);\r\n\t}\r\n\r\n\tpenaltyOrInterestAmountChanged(payment: Payment, field: string) {\r\n\t\tthis.zeroIfNull(payment, field);\r\n\t\tthis.revertIfNegative(payment, field);\r\n\t}\r\n\r\n\tasync paymentOptionChanged(bill: Bill): Promise {\r\n\t\tconst result = await this.messageBoxService.open({\r\n\t\t\tmessage: 'This will save the current state of the Bill',\r\n\t\t\tbuttons: MessageBoxButtons.OKCancel\r\n\t\t});\r\n\r\n\t\tswitch (result) {\r\n\t\t\tcase MessageBoxResult.OK:\r\n\t\t\t\tthis.editState.validationHandler(async (isValid, errorMessage) => {\r\n\t\t\t\t\tif (!isValid) {\r\n\t\t\t\t\t\tthis.editState.validationMessage = errorMessage;\r\n\r\n\t\t\t\t\t\t// HACK need setTimeout for some reason as when the 'show'\r\n\t\t\t\t\t\t// is called the validationMessage is not set unless we have the timeout\r\n\t\t\t\t\t\tsetTimeout(() => {\r\n\t\t\t\t\t\t\t// TODO this validation tooltip is not available in the\r\n\t\t\t\t\t\t\t// annual details service. Need to figure out how to set it\r\n\t\t\t\t\t\t\t//\r\n\t\t\t\t\t\t\t// editState.aDValidation.show();\r\n\t\t\t\t\t\t\t//\r\n\t\t\t\t\t\t\t// For now, console.warn:\r\n\t\t\t\t\t\t\tthis.toastr.error(errorMessage);\r\n\t\t\t\t\t\t});\r\n\t\t\t\t\t\treturn;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tthis.editState.entityLoading = true;\r\n\r\n\t\t\t\t\ttry {\r\n\t\t\t\t\t\tthis.AnnualDetailsSaveAllowedChanged.emit(false);\r\n\t\t\t\t\t\tconst tempBillAmount = bill.billAmount;\r\n\t\t\t\t\t\tconst savedBill = await this.billClusterService.saveOneBill(bill);\r\n\r\n\t\t\t\t\t\tif (!this.isDocumentProcessing) {\r\n\t\t\t\t\t\t\tthis.taxesViewModel.resetEdit(true);\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tconst savedBillIdx = _.findIndex(this.viewModel.model, { billID: savedBill.billID });\r\n\t\t\t\t\t\tthis.viewModel.model[savedBillIdx] = this.billClusterService.getBillForView(savedBill);\r\n\t\t\t\t\t\tthis._getTaskSummariesForBill(this.viewModel.model[savedBillIdx]);\r\n\r\n\t\t\t\t\t\tif (!this.viewModel.model[savedBillIdx].calcProjected) {\r\n\t\t\t\t\t\t\tthis.viewModel.model[savedBillIdx].billAmount = tempBillAmount;\r\n\t\t\t\t\t\t\tthis._distribute(this.viewModel.model[savedBillIdx]);\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tthis.showExtraFields = this.billClusterService.getShowExtraFields([savedBill]);\r\n\r\n\t\t\t\t\t\tthis.AnnualDetailsSaveAllowedChanged.emit(true);\r\n\t\t\t\t\t} finally {\r\n\t\t\t\t\t\tthis.editState.entityLoading = false;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t});\r\n\t\t\t\tbreak;\r\n\r\n\t\t\tcase MessageBoxResult.Cancel:\r\n\t\t\t\tthis.editState.cancelHandler();\r\n\t\t\t\tbreak;\r\n\t\t}\r\n\t}\r\n\r\n\tlaunchTaskModalBill(bill: Bill) {\r\n\t\tif (!this.editState.editMode || this.isDocumentProcessing) {\r\n\t\t\tthis.taskService.launchTaskModal(bill.billID, TAXBILL_ENTITY_TYPE_ID, true);\r\n\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n this.autoSaveAndPerformAction([bill], showToast => this.launchTaskModalAndReload(bill.billID, showToast));\r\n }\r\n\r\n autoSaveAndPerformAction(bills: Bill[], action: (showToast: boolean) => void) {\r\n\t\tif (!this.editState.editMode || !this.editState.getDirty() || this.isDocumentProcessing) {\r\n action(false);\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tthis.editState.validationHandler((isValid, errorMessage) => {\r\n\t\t\tif (!isValid) {\r\n\t\t\t\tthis.editState.validationMessage = errorMessage;\r\n\r\n\t\t\t\t// HACK need setTimeout for some reason as when the 'show'\r\n\t\t\t\t// is called the validationMessage is not set unless we have the timeout\r\n\t\t\t\tsetTimeout(() => {\r\n\t\t\t\t\t// TODO this validation tooltip is not available in the\r\n\t\t\t\t\t// annual details service. Need to figure out how to set it\r\n\t\t\t\t\t//\r\n\t\t\t\t\t// editState.aDValidation.show();\r\n\t\t\t\t\t//\r\n\t\t\t\t\t// For now, console.warn:\r\n\t\t\t\t\tthis.toastr.error(errorMessage);\r\n\t\t\t\t});\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n this.AnnualDetailsSaveAllowedChanged.emit(false);\r\n Promise.all(bills.map(bill => {\r\n return this.billClusterService.saveOneBill(bill).then((savedBill: Bill) => {\r\n if (!this.isDocumentProcessing) {\r\n this.taxesViewModel.resetEdit(true);\r\n }\r\n\r\n const savedBillIdx = _.findIndex(this.viewModel.model, { billID: savedBill.billID });\r\n this.viewModel.model[savedBillIdx] = this.billClusterService.getBillForView(savedBill);\r\n return this._getTaskSummariesForBill(this.viewModel.model[savedBillIdx]);\r\n }).then(() => {\r\n this.editState.setDirty(false);\r\n });\r\n })).then(() => {\r\n action(true);\r\n this.AnnualDetailsSaveAllowedChanged.emit(true);\r\n });\r\n\t\t});\r\n }\r\n\r\n\tasync launchTaskModalAndReload(billID: number, showToast: boolean): Promise {\r\n\t\tconst toastMessage = showToast ? 'Bill changes autosaved' : '';\r\n\r\n\t\tconst shouldReload = await this.taskService.launchTaskModal(billID, TAXBILL_ENTITY_TYPE_ID, false, toastMessage);\r\n\r\n\t\tif (!shouldReload) {\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tthis.reloadOnModalClose(billID);\r\n }\r\n\r\n async reloadOnModalClose(billID?: number) {\r\n\t\tthis.AnnualDetailsSaveAllowedChanged.emit(false);\r\n\t\tthis.editState.showEditControls = false;\r\n\t\tthis.editState.entityLoading = true;\r\n\t\tthis.editState.refreshGrid = true;\r\n\t\tthis.navigationEvent.refreshActivityData();\r\n\t\tthis.navigationEvent.refreshAnnualYear();\r\n\r\n\t\tconst updateSingleBill = async (id: number) => {\r\n\t\t\tconst savedBill = await this.billClusterService.getOneBill(id);\r\n\t\t\tthis.updateSavedBill(savedBill);\r\n\t\t\tthis.taxesViewModel.currentTab.rowVersion = savedBill.billClusterRowVersion;\r\n\t\t};\r\n\t\tif (billID) {\r\n\t\t\tawait updateSingleBill(billID);\r\n\t\t}\r\n\t\telse {\r\n\t\t\tfor (let i = 0; i < this.viewModel.model.length; i++) {\r\n\t\t\t\tawait updateSingleBill(this.viewModel.model[i].billID);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tthis.editState.entityLoading = false;\r\n\t\tthis.editState.showEditControls = true;\r\n\t\tthis.AnnualDetailsSaveAllowedChanged.emit(true);\r\n }\r\n\r\n\tgetCommentModalData(bill) {\r\n\t\tconst commentModalData = new CommentModalData();\r\n\t\tcommentModalData.entityID = bill.billID;\r\n\t\tcommentModalData.entityTypeID = TAXBILL_ENTITY_TYPE_ID;\r\n\t\tcommentModalData.canEdit = this.viewModel.hasWritePermission;\r\n\t\tcommentModalData.parcelID = this.viewModel.parcelID;\r\n\t\tcommentModalData.parcelAcctNum = this.viewModel.parcelAcctNum;\r\n\t\tcommentModalData.description = `${this.viewModel.year } - ${ this.viewModel.tabTitle } ${ bill.name === null ? 'Bill' : bill.name}`;\r\n\t\tcommentModalData.year = this.viewModel.year.toString();\r\n\r\n\t\treturn commentModalData;\r\n\t}\r\n\r\n\tgetAttachmentModalData(bill) {\r\n\t\tconst attachmentModalData = new AttachmentModalData();\r\n\r\n\t\tattachmentModalData.belowParcelEntity = new AttachmentModalEntityData();\r\n\t\tattachmentModalData.belowParcelEntity.id = bill.billID;\r\n\t\tattachmentModalData.belowParcelEntity.typeId = TAXBILL_ENTITY_TYPE_ID;\r\n\t\tattachmentModalData.belowParcelEntity.name = bill.name;\r\n\t\tattachmentModalData.entityType = 'Tax Bill';\r\n\t\tattachmentModalData.parentId = this.viewModel.parcelID;\r\n\t\tattachmentModalData.parentType = 'Parcel';\r\n\t\tattachmentModalData.entityName = this.viewModel.parcelAcctNum;\r\n\t\tattachmentModalData.entityDescription = `${this.viewModel.year } - ${ this.viewModel.tabTitle } ${ bill.name === null ? 'Bill' : bill.name}`;\r\n\t\tattachmentModalData.year = this.viewModel.year;\r\n\r\n\t\treturn attachmentModalData;\r\n\t}\r\n\r\n\tbillPropertyIsEditable(bill: Bill): boolean {\r\n\t\treturn this.editState.editMode\r\n\t\t\t&& !bill.calcProjected\r\n\t\t\t&& (!bill.status || !this._atLeastOnePaymentTransmitted(bill));\r\n\t}\r\n\r\n\tpaymentAmountIsEditable(bill: Bill, payment: Payment): boolean {\r\n\t\treturn this.editState.editMode\r\n\t\t\t&& !bill.calcProjected\r\n\t\t\t&& !this._atLeastOnePaymentTransmitted(bill)\r\n\t\t\t&& bill.payments.length > 1;\r\n\t}\r\n\r\n\tpaymentPropertyIsEditable(bill: Bill, payment: Payment): boolean {\r\n\t\treturn this.editState.editMode\r\n\t\t\t&& !bill.calcProjected\r\n\t\t\t&& this._isTransmitIncomplete(payment);\r\n\t}\r\n\r\n\tpaymentOptionIsEditable(bill: Bill): boolean {\r\n\t\treturn this.editState.editMode\r\n\t\t\t&& bill.collectorPaymentOptions.length > 1\r\n\t\t\t&& (!bill.status || !this._atLeastOnePaymentTransmitted(bill))\r\n\t\t\t&& !this.isDocumentProcessing;\r\n\t}\r\n\r\n\tbillHasTaskSummary(bill: Bill): boolean {\r\n\t\treturn _.some(bill.payments, (payment: Payment) => !_.isEmpty(payment.taskSummary));\r\n\t}\r\n\r\n\tchangeActual(bill: Bill): void {\r\n\t\tbill.status = bill.status ? 0 : 1;\r\n\r\n\t\tif (bill.status && !bill.annualAssessmentID) {\r\n\t\t\tbill.annualAssessmentID = _.maxBy(this.viewModel.yearRevisions, 'revisionNum').annualAssessmentID;\r\n\t\t}\r\n\t}\r\n\r\n\trevertDirectAsmtIfInvalid(bill: Bill): void {\r\n\t\tlet revert: boolean = false;\r\n\r\n\t\tif (bill.directAsmt === undefined || bill.directAsmt === null || isNaN(bill.directAsmt)) {\r\n\t\t\tbill.directAsmt = 0;\r\n\t\t}\r\n\r\n\t\tif (bill.directAsmt > bill.billAmount) {\r\n\t\t\tthis.toastr.error('Cannot exceed Bill Amount!');\r\n\t\t\trevert = true;\r\n\t\t}\r\n\r\n\t\tif (revert) {\r\n\t\t\tbill.directAsmt = this.tempVals.directAsmt;\r\n\t\t}\r\n\t}\r\n\r\n\tmaybeRevertToOriginalDate(payment: Payment, field: string): void {\r\n\t\tif (!payment[field]) {\r\n\t\t\tpayment[field] = this._getOriginalDate(payment, field);\r\n\t\t}\r\n\t}\r\n\r\n\tasync calcProjectedChanged(bill: Bill): Promise {\r\n\t\tif (!bill.calcProjected) {\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tif (this.isDocumentProcessing) {\r\n\t\t\tbill.calcProjected = false;\r\n\r\n\t\t\tthis.messageBoxService.open({\r\n\t\t\t\tmessage: 'Please Refresh instead.',\r\n\t\t\t\tbuttons: MessageBoxButtons.OK\r\n\t\t\t});\r\n\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tconst result = await this.messageBoxService.open({\r\n\t\t\ttitle: 'WARNING',\r\n\t\t\tmessage: 'Enabling auto calculate will force the bill to be saved. Do you wish to continue?',\r\n\t\t\tbuttons: MessageBoxButtons.OKCancel\r\n\t\t});\r\n\r\n\t\tswitch (result) {\r\n\t\t\tcase MessageBoxResult.OK:\r\n\t\t\t\tthis.editState.validationHandler(async (isValid, errorMessage) => {\r\n\t\t\t\t\tif (!isValid) {\r\n\t\t\t\t\t\tthis.editState.validationMessage = errorMessage;\r\n\r\n\t\t\t\t\t\t// HACK need setTimeout for some reason as when the 'show'\r\n\t\t\t\t\t\t// is called the validationMessage is not set unless we have the timeout\r\n\t\t\t\t\t\tsetTimeout(() => {\r\n\t\t\t\t\t\t\t// TODO this validation tooltip is not available in the\r\n\t\t\t\t\t\t\t// annual details service. Need to figure out how to set it\r\n\t\t\t\t\t\t\t//\r\n\t\t\t\t\t\t\t// editState.aDValidation.show();\r\n\t\t\t\t\t\t\t//\r\n\t\t\t\t\t\t\t// For now, console.warn:\r\n\t\t\t\t\t\t\tthis.toastr.error(errorMessage);\r\n\t\t\t\t\t\t});\r\n\t\t\t\t\t\treturn;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tthis.AnnualDetailsSaveAllowedChanged.emit(false);\r\n\t\t\t\t\tthis.saveBillCluster.emit(() => {\r\n\t\t\t\t\t\tthis.AnnualDetailsSaveAllowedChanged.emit(true);\r\n\t\t\t\t\t});\r\n\t\t\t\t});\r\n\r\n\t\t\t\tbreak;\r\n\t\t}\r\n\t}\r\n\r\n\tasync updateSavedBill(bill: Bill): Promise {\r\n\t\tconst savedBillIdx = _.findIndex(this.viewModel.model, { billID: bill.billID });\r\n\t\tthis.viewModel.model[savedBillIdx] = this.billClusterService.getBillForView(bill);\r\n\t\tawait this._getTaskSummariesForBill(this.viewModel.model[savedBillIdx]);\r\n\r\n\t\tif (this.billHasTaskSummary(bill) && !bill.annualAssessmentID && _.some(bill.payments, 'taskSummary.TaxBillReceived')) {\r\n\t\t\tthis.viewModel.model[savedBillIdx].annualAssessmentID = _.maxBy(this.viewModel.yearRevisions, 'revisionNum').annualAssessmentID;\r\n\r\n\t\t\tthis.billClusterService.saveOneBill(this.viewModel.model[savedBillIdx]).then((updatedBill) => {\r\n\t\t\t\tthis.viewModel.model[savedBillIdx].rowVersion = updatedBill.rowVersion;\r\n\t\t\t\tthis.toastr.info('Bill autosaved with latest revision');\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tif (!this.isDocumentProcessing) {\r\n\t\t\tthis.taxesViewModel.resetEdit(true);\r\n\t\t}\r\n\t}\r\n\r\n\tshowExcludeFromAccruals(bill: Bill): boolean {\r\n if (bill === null) {\r\n return _.some(this.viewModel.model, b => this.showExcludeFromAccruals(b));\r\n }\r\n\r\n // TODO: It appears taxesViewModel is always missing in document processing. For now that's OK; just don't show this checkbox in that\r\n // case, but this needs some investigation.\r\n if (!this.taxesViewModel || bill.payments.length === 0) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\r\n\t\tconst bc = this.taxesViewModel.model.find(x => x.billClusterID === bill.billClusterID);\r\n\t\treturn bc ? bc.accrualsEnabled : false;\r\n\t}\r\n\r\n\texcludeFromAccrualsChanged(): void {\r\n\t\tthis.setDirty();\r\n\t\tthis.navigationEvent.refreshAccrualDetailsLink(this.billClusterService.areAllPaymentsExcludedFromAccruals(this.viewModel.model));\r\n\t}\r\n\r\n\tsetDirty(): void {\r\n\t\tthis.editState.setDirty(true);\r\n\t\tthis.editState.refreshGrid = true;\r\n\r\n\t\tif(this.isDocumentProcessing) {\r\n\t\t\tconst eventName = this._atLeastOnePaymentinQC() ? 'edit-document-amount-qc' : 'edit-document-amount-dp';\r\n\t\t\tthis.productAnalyticsService.logEvent(eventName);\r\n\t\t}\r\n\t}\r\n\r\n\tshowActualCheckbox(bill: Bill): boolean {\r\n\t\tif (bill.payments.length == 0)\r\n\t\t\treturn false;\r\n\r\n\t\treturn !this.billHasTaskSummary(bill);\r\n\t}\r\n\r\n\tshowAutoCalculateCheckbox(bill: Bill): boolean {\r\n\t\treturn !bill.status && bill.collectorPaymentOptionID !== undefined && bill.collectorPaymentOptionID !== null;\r\n\t}\r\n\r\n\tshowActualCheckboxRow(): boolean {\r\n\t\treturn this.viewModel && _.some(this.viewModel.model, (bill: Bill) => this.showActualCheckbox(bill));\r\n\t}\r\n\r\n\tshowAutoCalculateCheckboxRow(): boolean {\r\n\t\treturn this.viewModel && _.some(this.viewModel.model, (bill: Bill) => this.showAutoCalculateCheckbox(bill));\r\n\t}\r\n\r\n\tshowAssocRevision(): boolean {\r\n\t\tif (!this.viewModel.model) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\r\n\t\tconst someBillsAreEditable: boolean = _.some(this.viewModel.model, (bill: Bill) => this.assocRevisionIsEditable(bill)) as boolean;\r\n\t\tconst someBillsHaveAssocRevision: boolean = _.some(this.viewModel.model, (bill: Bill) => bill.annualAssessmentID) as boolean;\r\n\r\n\t\treturn someBillsAreEditable || someBillsHaveAssocRevision;\r\n\t}\r\n\r\n\tshowSupplemental(): boolean {\r\n\t\treturn this.stateIsSupplemental && !_.every(this.viewModel.model, 'collectorPaymentOptionID');\r\n\t}\r\n\r\n\tshowProration(): boolean {\r\n\t\treturn _.some(this.viewModel.model, 'isSupplemental');\r\n\t}\r\n\r\n\tassocRevisionIsEditable(bill: Bill): boolean {\r\n\t\treturn this.editState.editMode && !bill.calcProjected;\r\n\t}\r\n\r\n\tgetAssocRevisionDesc(bill: Bill): string {\r\n\t\tconst yearRevision = _.find(this.viewModel.yearRevisions, { annualAssessmentID: bill.annualAssessmentID });\r\n\r\n\t\tif(yearRevision) {\r\n\t\t\treturn yearRevision.revisionDesc;\r\n\t\t} else {\r\n\t\t\tconsole.warn('Cannot find year revision for Bill!');\r\n\t\t\treturn '';\r\n\t\t}\r\n\t}\r\n\r\n\tasync openPaymentStubModal(billId: number, payment: Payment): Promise {\r\n try {\r\n await this.annualDetailsService.preNavigateWarn(this.editState);\r\n } catch(err) {\r\n return;\r\n }\r\n\r\n\t\tconst params = {billId, payment};\r\n const { saved, attachmentId } = await this.modalService.showAsync(BillImageModalComponent, params, 'modal-lg');\r\n\r\n\t\tif(saved) {\r\n\t\t\tpayment.attachmentID = attachmentId;\r\n\t\t}\r\n\r\n\t}\r\n\r\n\tasync openParcelCollectorAddressModal(billClusterId: number, payment: Payment) {\r\n\t\ttry {\r\n\t\t\tconst collectorEntityAddresses = await this.billClusterService.getCollectorEntityAddressesForBillCluster(billClusterId);\r\n\t\t\tconst taxPaymentCollectorEntityAddresses = collectorEntityAddresses.length != 0\r\n\t\t\t\t\t? collectorEntityAddresses.filter(x => x.correspondenceTypes?.some(y => y.correspondenceTypeID == Core.CorrespondenceTypes.TaxPayment))\r\n\t\t\t\t\t: [];\r\n\r\n const result = await this.addressDetailsModalLaunchService.openAddressDetailsModal(\r\n\t\t\t\tpayment.paymentID,\r\n Core.EntityTypes.Payment,\r\n _.cloneDeep(taxPaymentCollectorEntityAddresses),\r\n this.editState.editMode,\r\n false,\r\n true\r\n );\r\n\r\n if (this.editState.editMode) {\r\n //save address\r\n }\r\n } catch (err) {\r\n if(err.error?.message) {\r\n this.toastr.error(err.error.message);\r\n }\r\n }\r\n\t}\r\n\r\n\topenTransmittalDetailsModal(payment: Payment) {\r\n\t\tthis.paymentPackagesModal.show(payment.paymentID);\r\n\t}\r\n\r\n\tprorationChange(bill: Bill, e): void {\r\n\t\tthis.setDirty();\r\n\r\n\t\tbill.prorationPct = new Decimal(e)\r\n\t\t\t.dividedBy(100)\r\n\t\t\t.toSignificantDigits(6)\r\n\t\t\t.toNumber();\r\n }\r\n\r\n openTaxRateSetup() {\r\n if (this.viewModel && this.viewModel.model && this.viewModel.model[0]) {\r\n this.autoSaveAndPerformAction(this.viewModel.model, showToast => {\r\n if (showToast) {\r\n this.toastr.info('Bill changes autosaved');\r\n }\r\n const billClusterID = this.viewModel.model[0].billClusterID;\r\n let currentBill: Bill = null;\r\n if (this.isDocumentProcessing) {\r\n currentBill = this.viewModel.model[0];\r\n }\r\n this.taxRateSetupModalLaunchService.openBillClusterTaxRateDetailsModal(\r\n billClusterID,\r\n this.viewModel.model[0].billClusterRowVersion,\r\n this.viewModel.tabTitle,\r\n !this.viewModel.model.some(b => !!b.status),\r\n !this.editState.editMode,\r\n this.isDocumentProcessing,\r\n this.viewModel.processingTaxSetupResult,\r\n this.processingParcelTaxSetup,\r\n currentBill,\r\n this.viewModel.intakeAttachmentId,\r\n currentBill ? currentBill.calcProjected : null,\r\n this.hasProcessingChanges,\r\n this.firstEncounterSavedCallback\r\n ).subscribe(result => {\r\n // If this is document processing, nothing was saved in the modal, so there is a lot\r\n // less to handle.\r\n if (this.isDocumentProcessing) {\r\n this.viewModel.processingTaxSetupResult = result;\r\n this.setDirty();\r\n this.calculateShowFirstEncounterIndicator();\r\n }\r\n else {\r\n // Adding this years after the bill component was written; we want to update the\r\n // bill cluster row version for any model that has the same bill cluster ID. Given\r\n // how this is called, I suspect this isn't necessary (I probably could have just\r\n // updated this.viewModel.model[0]), but I'm not sure, so this seemed safer.\r\n this.viewModel.model\r\n .filter(m => m.billClusterID === billClusterID)\r\n .forEach(m => m.billClusterRowVersion = result.rowVersion);\r\n // We also have the row version here\r\n this.taxesViewModel.model\r\n .filter(m => m.billClusterID === billClusterID)\r\n .forEach(m => m.rowVersion = result.rowVersion);\r\n\r\n // We've also potentially changed the BillCluster itself, so update the relevant\r\n // property (in this case \"taxRateAreaId\").\r\n this.taxesViewModel.model.filter(m => m.billClusterID === billClusterID).forEach(m => {\r\n m.rowVersion = result.rowVersion;\r\n m.taxRateAreaId = result.taxRateAreaId;\r\n });\r\n\r\n this.taxesViewModel.preEditModelBackup.rowVersion = result.rowVersion;\r\n this.taxesViewModel.preEditModelBackup.taxRateAreaId = result.taxRateAreaId;\r\n\r\n // All of that only dealt with the bill cluster; it's also possible that a bill changed.\r\n // Reload all the bills in that case.\r\n this.reloadOnModalClose();\r\n }\r\n });\r\n });\r\n }\r\n }\r\n\r\n undoDate(payment: Payment, field: string) {\r\n payment[field] = this._getOriginalDate(payment, field);\r\n\t\tpayment.dueDateChanged = false;\r\n this.setDirty();\r\n }\r\n\r\n\tdueDateIsInPast(dueDate): boolean {\r\n return moment(dueDate).isBefore(moment());\r\n }\r\n\r\n dueDateIsLaterThanOriginal(payment: Payment): boolean {\r\n return moment(payment.dueDate).isAfter(payment.originalDueDate);\r\n }\r\n\r\n get hasExemptions(): boolean {\r\n return this.viewModel.model.some(x => x.payments.some(y => y.exemptionAmount));\r\n }\r\n\r\n getPaymentBatchDetailsSref(payment: Payment) {\r\n\t\t// Return sref Payment Batch Details page in another tab for the BelongsToPaymentBatchId\r\n\t\tconsole.log(`openPaymentBatchDetails(${payment.paymentID}, ${payment.belongsToPaymentBatchId}, ${payment.belongsToPaymentBatchNo})`);\r\n return {\r\n target: 'paymentBatchDetails',\r\n options: {\r\n paymentBatchId: payment.belongsToPaymentBatchId\r\n }\r\n };\r\n }\r\n\r\n\r\n\tprivate _getOriginalDate(payment: Payment, field: string): Date {\r\n\t\tconst capitalizedField: string = field.charAt(0).toUpperCase() + field.slice(1);\r\n\r\n\t\treturn payment[`original${ capitalizedField}`];\r\n\t}\r\n\r\n\tprivate _getDiscount(payment: Payment): number {\r\n\t\tif (payment.collectorPayment && payment.collectorPayment.discountPercent) {\r\n\t\t\tconst discount = new Decimal(payment.grossPayment)\r\n\t\t\t\t.times(payment.collectorPayment.discountPercent)\r\n\t\t\t\t.times(100)\r\n\t\t\t\t.round()\r\n\t\t\t\t.dividedBy(100)\r\n\t\t\t\t.toNumber();\r\n\r\n\t\t\treturn -Math.abs(discount);\r\n\t\t} else {\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t}\r\n\r\n\t// When a bills Gross Bill Amt is changed, distribute the amount over the bills payments\r\n\tprivate _distribute(bill: Bill): void {\r\n\t\t// Separate bill's payments by processed and unprocessed\r\n\t\tconst payments = _.groupBy(bill.payments, (payment: Payment) => {\r\n\t\t\treturn this.notProcessed(payment) ? 'unprocessed' : 'processed';\r\n\t\t});\r\n\r\n\t\t// if no unprocessed, no work to be done\r\n\t\tif (!payments.unprocessed) {\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\t// Get the sum of the processed Gross payment amounts\r\n\t\tconst totalProcessedAmount = _.reduce(payments.processed, (result: number, payment: Payment) => {\r\n\t\t\treturn new Decimal(result).plus(payment.grossPayment).toNumber();\r\n\t\t}, 0);\r\n\r\n\t\t// Get an array of Gross payment amounts (distribution)\r\n\t\t// by dividing remaining amount by the number of unprocessed\r\n\t\t// payments\r\n\t\tconst remainingAmount = new Decimal(bill.billAmount).minus(totalProcessedAmount).toNumber();\r\n\t\tconst evenDist = this.divide(remainingAmount, payments.unprocessed.length);\r\n\r\n\t\t// Assign each unprocessed payment their amounts by using the distributed array.\r\n\t\tbill.payments = _.map(bill.payments, (payment: Payment, idx: number): Payment => {\r\n\t\t\tpayment.grossPayment = evenDist[idx];\r\n\t\t\tpayment.discountAmount = this._getDiscount(payment);\r\n\t\t\tpayment.penaltyAmount = 0;\r\n\t\t\tpayment.interestAmount = 0;\r\n\t\t\tpayment.paymentAmount = new Decimal(payment.grossPayment).plus(payment.discountAmount).toNumber();\r\n\r\n\t\t\treturn payment;\r\n\t\t});\r\n\r\n\t\t// recalcute total and effective rate to the right of Bills\r\n\t\t//This recalcuates totals for the annual year\r\n\t\t// this.calcTaxTotals();\r\n\t}\r\n\r\n\tprivate _setBillAmountToSumOfPayments(bill: Bill): void {\r\n\t\tbill.billAmount = _.reduce(bill.payments, (sum, payment) => sum + (payment.grossPayment || 0), 0);\r\n\r\n\t\tthis.toastr.info('Overall Bill Amount has been updated');\r\n\t}\r\n\r\n\tprivate _allocationIsNegative(payment: Payment): void {\r\n\t\tpayment.grossPayment = payment.paymentAmount = this.tempVals.grossPayment;\r\n\r\n\t\tthis.toastr.error('Error!', 'Total Allocation cannot be negative');\r\n\t}\r\n\r\n\tprivate _atLeastOnePaymentTransmitted(bill: Bill): boolean {\r\n\t\treturn _.some(bill.payments, x => x.taskSummary && x.taskSummary && x.taskSummary.TransmitComplete);\r\n\t}\r\n\r\n\tprivate _atLeastOnePaymentinQC(): boolean {\r\n\t\treturn _.some(this.viewModel.model, x => {\r\n\t\t\treturn _.some(x.payments, ({taskSummary}) => taskSummary && taskSummary.isQCed && !taskSummary.QCTaxBillComplete);\r\n\t\t});\r\n\t}\r\n\r\n\tprivate async _getTaskSummariesForBill(bill: Bill): Promise {\r\n\t\treturn this.billClusterService.getTaskSummariesForBill(bill)\r\n\t\t\t.then(() => {\r\n\t\t\t\tthis.showActualRow = this.showActualCheckboxRow();\r\n\t\t\t\tbill.showActualCheckbox = this.showActualCheckbox(bill);\r\n\t\t\t});\r\n\t}\r\n\r\n\tprivate _isTransmitIncomplete(payment: Payment): boolean {\r\n\t\treturn !payment.paymentID\r\n\t\t\t|| _.isEmpty(payment.taskSummary)\r\n\t\t\t// || (!payment.taskSummary.TransmitComplete || payment.taskSummary.AdjustPaymentIsReady) turning off until turning on\r\n\t\t\t|| !payment.taskSummary.TransmitComplete;\r\n\t}\r\n\r\n\tprivate _atLeastThreeIncompleteTransmitPayments(bill: Bill): boolean {\r\n\t\tconst paymentCount: number = _.reduce(bill.payments, (count: number, payment: Payment) => {\r\n\t\t\tif (this._isTransmitIncomplete(payment)) {\r\n\t\t\t\tcount++;\r\n\t\t\t}\r\n\r\n\t\t\treturn count;\r\n\t\t}, 0);\r\n\r\n\t\treturn paymentCount > 2;\r\n\t}\r\n\r\n\t// private _atLeastOnePaymentHasAdjustNotice(bill: Bill): boolean {\r\n\t// \treturn _.some(bill.payments, payment => !_.isEmpty(payment.taskSummary) && payment.taskSummary.AdjustPaymentIsReady); turning off until turning on\r\n\t// }\r\n\r\n\t// leftover from angular 2 implementation.\r\n\t// Might need this again\r\n\t// updatePaymentAttachmentID(attachmentID: string): void {\r\n\t// \tthis.paymentStubParams.payment.attachmentID = attachmentID;\r\n\t// }\r\n}\r\n","
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Refund Amt:
Expected Date:
Revision:
Check #:
Status:
Tax Period Begin:
Tax Period End:
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n Refund\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n {{viewModel.model.refundAmount | currency:'USD'}}\r\n
\r\n \r\n
\r\n \r\n {{getRevisionDesc()}}\r\n
\r\n \r\n {{viewModel.model.checkNumber}}\r\n
\r\n \r\n \r\n {{ viewModel.model.taskSummary.Status }} {{ viewModel.model.taskSummary.CompletedDateTime | weissmanDateFormat: true: \"Central\" || ''}}\r\n N/A - No Responsibilities\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnChanges, Output } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AttachmentModalData, AttachmentModalEntityData } from '../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { AnnualDetailsNavigationEventService } from '../annual-details-event.service';\r\nimport { AnnualDetailEditState } from '../annual-details-navigation.service';\r\nimport { BillClusterService, RefundViewModel, TaxesViewModel } from './bill-cluster.service';\r\nimport { Refund } from './refund.model';\r\n\r\ndeclare const _: any;\r\ndeclare const moment: any;\r\n\r\nconst REFUND_ENTITY_TYPE_ID = 14;\r\n\r\n@Component({\r\n\tselector: 'refund',\r\n\ttemplateUrl: './refund.component.html'\r\n})\r\nexport class RefundComponent implements OnChanges {\r\n\tconstructor(private billClusterService: BillClusterService,\r\n private taskService: TaskService,\r\n private toastr: ToastrService,\r\n private navigationEvent: AnnualDetailsNavigationEventService) {\r\n\t\tthis.refundDeleted = new EventEmitter();\r\n\t}\r\n\r\n\t@Input() editState: AnnualDetailEditState;\r\n\t@Input() viewModel: RefundViewModel;\r\n\t@Input() isDocumentProcessing: boolean;\r\n\t@Input() taxesViewModel: TaxesViewModel;\r\n\t@Output() refundDeleted: EventEmitter;\r\n\r\n\trefundEntityTypeId: number = REFUND_ENTITY_TYPE_ID;\r\n\r\n\twaitingOnServer: boolean;\r\n\tannualAssessments: Weissman.Model.Assessments.AnnualAssessment[];\r\n\tprivate _haveLoadedAssessments: boolean = false;\r\n\r\n\tasync ngOnChanges(): Promise {\r\n\t\tif(this.viewModel && !this._haveLoadedAssessments) {\r\n\t\t\tthis._haveLoadedAssessments = true;\r\n\t\t\tawait this.loadAnnualAssessmentsByAnnualYearID();\r\n\t\t}\r\n\t}\r\n\r\n\tasync loadAnnualAssessmentsByAnnualYearID(): Promise {\r\n\t\tthis.annualAssessments = await this.billClusterService.getAnnaulAssessmentsByAnnualYearID(this.viewModel.model.annualYearID);\r\n\r\n\t\t// if there is only one, make it default\r\n\t\tif (this.annualAssessments.length === 1 && !this.viewModel.model.annualAssessmentID) {\r\n\t\t\tthis.viewModel.model.annualAssessmentID = this.annualAssessments[0].annualAssessmentID;\r\n\t\t}\r\n\t}\r\n\r\n\tgetRevisionDesc(): string {\r\n\t\tconst yearRevision = _.find(this.annualAssessments, { annualAssessmentID: this.viewModel.model.annualAssessmentID });\r\n\r\n\t\tif(yearRevision) {\r\n\t\t\treturn yearRevision.revisionDesc;\r\n\t\t} else {\r\n\t\t\tconsole.warn('Cannot find year revision for the refund!');\r\n\t\t\treturn '';\r\n\t\t}\r\n\t}\r\n\r\n\trefundAmountChanged(): void {\r\n this.setDirty();\r\n\t\tthis.editState.staleAppealSavings = true;\r\n\t\tthis.editState.refreshGrid = true;\r\n\t}\r\n\r\n\r\n\tdeleteRefund(): void {\r\n\t\tconst message: string = 'Confirm deleting refund';\r\n\r\n\t\tif (confirm(message)) {\r\n\t\t\tthis.billClusterService.deleteRefund(this.viewModel.model.refundID)\r\n\t\t\t\t.then(() => {\r\n\t\t\t\t\tthis.refundDeleted.emit();\r\n this.navigationEvent.refreshActivityData();\r\n\t\t\t\t});\r\n\t\t}\r\n\t}\r\n\r\n\tlaunchTaskModal() {\r\n\t\tif (!this.editState.editMode || this.isDocumentProcessing) {\r\n\t\t\tthis.taskService.launchTaskModal(this.viewModel.model.refundID, REFUND_ENTITY_TYPE_ID, true);\r\n\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tif (!this.editState.getDirty()) {\r\n\t\t\tthis.launchTaskModalAndReload();\r\n\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tthis.billClusterService.saveRefund(this.viewModel.model)\r\n\t\t\t.then((saveRefund: Refund) => {\r\n\t\t\t\tthis.viewModel.model.refundRowVersion = saveRefund.refundRowVersion;\r\n\r\n\t\t\t\tif(!this.isDocumentProcessing) {\r\n\t\t\t\t\tthis.taxesViewModel.resetEdit(true);\r\n\t\t\t\t}\r\n\r\n\t\t\t\tthis.editState.setDirty(false);\r\n\r\n\t\t\t\tthis.toastr.info('Refund changes autosaved');\r\n\r\n\t\t\t\tthis.launchTaskModalAndReload();\r\n\t\t\t});\r\n\t}\r\n\r\n\tlaunchTaskModalAndReload() {\r\n\t\tthis.taskService.launchTaskModal(this.viewModel.model.refundID, REFUND_ENTITY_TYPE_ID, false)\r\n\t\t\t.then(shouldReload => {\r\n\t\t\t\tif (!shouldReload) {\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n this.navigationEvent.refreshActivityData();\r\n\r\n\t\t\t\tthis.billClusterService.getRefundViewModelByRefundID(this.viewModel.model.refundID)\r\n\t\t\t\t\t.then((refund) => {\r\n\t\t\t\t\t\t_.assign(this.viewModel.model, refund.model);\r\n\r\n\t\t\t\t\t\tthis.viewModel.model.taskSummary = {};\r\n\t\t\t\t\t\tthis.billClusterService.getEntityTaskSummaries(this.viewModel.model, REFUND_ENTITY_TYPE_ID, this.viewModel.model.refundID);\r\n\r\n\t\t\t\t\t\tif(!this.isDocumentProcessing) {\r\n\t\t\t\t\t\t\tthis.taxesViewModel.resetEdit(true);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t});\r\n\t\t\t});\r\n\t}\r\n\r\n\tmakeRefundNegative() {\r\n\t\tthis.viewModel.model.refundAmount = -Math.abs(this.viewModel.model.refundAmount);\r\n\t}\r\n\r\n\tgetCommentModalData() {\r\n\t\tconst commentModalData = new CommentModalData();\r\n\t\tcommentModalData.entityID = this.viewModel.model.refundID;\r\n\t\tcommentModalData.entityTypeID = REFUND_ENTITY_TYPE_ID;\r\n\t\tcommentModalData.canEdit = this.viewModel.hasWritePermission;\r\n\t\tcommentModalData.parcelID = this.viewModel.parcelID;\r\n\t\tcommentModalData.parcelAcctNum = this.viewModel.parcelAcctNum;\r\n\t\tcommentModalData.description = `${this.viewModel.year } - ${ this.viewModel.tabTitle}`;\r\n\t\tcommentModalData.year = this.viewModel.year.toString();\r\n\r\n\t\treturn commentModalData;\r\n\t}\r\n\r\n\tgetAttachmentModalData() {\r\n\t\tconst attachmentModalData = new AttachmentModalData();\r\n\r\n\t\tattachmentModalData.belowParcelEntity = new AttachmentModalEntityData();\r\n\t\tattachmentModalData.belowParcelEntity.id = this.viewModel.model.refundID;\r\n\t\tattachmentModalData.belowParcelEntity.typeId = REFUND_ENTITY_TYPE_ID;\r\n\t\tattachmentModalData.belowParcelEntity.name = 'Refund';\r\n\t\tattachmentModalData.entityType = 'Refund';\r\n\t\tattachmentModalData.parentId = this.viewModel.parcelID;\r\n\t\tattachmentModalData.parentType = 'Parcel';\r\n\t\tattachmentModalData.entityName = this.viewModel.parcelAcctNum;\r\n\t\tattachmentModalData.entityDescription = `${this.viewModel.year } - ${ this.viewModel.tabTitle}`;\r\n\t\tattachmentModalData.year = this.viewModel.year;\r\n\r\n\t\treturn attachmentModalData;\r\n\t}\r\n\r\n\tsetDirty() {\r\n\t\tthis.editState.setDirty(true);\r\n\t\tthis.editState.refreshGrid = true;\r\n }\r\n\r\n expectedDateChanged() {\r\n this.editState.refreshActivity = true;\r\n this.setDirty();\r\n\t}\r\n\r\n\tdateOverridden(field: string): boolean {\r\n\t\tconst current = this.viewModel.model[field];\r\n\t\tconst original = this.getOriginalDate(field);\r\n\r\n\t\tif (!current || !original) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\r\n\t\treturn !moment(current).isSame(original);\r\n\t}\r\n\r\n\tmaybeRevertToOriginalDate(field: string): void {\r\n\t\tif(!this.viewModel.model[field]) {\r\n\t\t\tthis.viewModel.model[field] = this.getOriginalDate(field);\r\n\t\t}\r\n\t}\r\n\r\n undoDate(field: string) {\r\n this.viewModel.model[field] = this.getOriginalDate(field);\r\n this.setDirty();\r\n }\r\n\r\n\tprivate getOriginalDate(field: string): Date {\r\n\t\tconst capitalizedField: string = field.charAt(0).toUpperCase() + field.slice(1);\r\n\r\n\t\treturn this.viewModel.model[`original${ capitalizedField}`];\r\n }\r\n}\r\n","\r\n
\r\n
\r\n There are presently no tax bills for {{currentYear.annualYear1}}\r\n
\r\n
\r\n There are presently no tax bills for this year.\r\n
\r\n \r\n
\r\n 0\" justify=\"start\">\r\n \r\n \r\n {{tab.title || tab.collector.abbr || tab.collector.name}} \r\n \r\n
\r\n \r\n \r\n\r\n \r\n\r\n Accrual Detail\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n

Add One-time Bill or Refund

\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, Output, OnInit, SimpleChanges, ViewChild } from '@angular/core';\r\nimport { BsModalService, ModalDirective } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Collector } from '../../Assessor-Collector/collector.model';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { AnnualDetailsNavigationEventService } from '../annual-details-event.service';\r\nimport { AnnualDetailEditState } from '../annual-details-navigation.service';\r\nimport { AnnualDetailsService } from '../annual-details.service';\r\nimport { AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { AccrualDetailModalComponent } from '../Modals/accrual-detail.component';\r\nimport { BillCluster } from './bill-cluster.model';\r\nimport { BillClusterService, BillViewModel, RefundViewModel, TaxesViewModel } from './bill-cluster.service';\r\nimport { Refund } from './refund.model';\r\nimport { assign } from 'lodash';\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n\tselector: 'taxes',\r\n\ttemplateUrl: './taxes.component.html'\r\n})\r\nexport class TaxesComponent implements OnInit {\r\n\tconstructor(private billClusterService: BillClusterService,\r\n private http: SDHttpService,\r\n private annualDetailsService: AnnualDetailsService,\r\n\t\t\t\tprivate navigationEvent: AnnualDetailsNavigationEventService,\r\n\t\t\t\tprivate modalService: BsModalService,\r\n\t\t\t\tprivate toastr: ToastrService) {\r\n\t\tthis.isAddBillModalShown = false;\r\n\t\tthis.billOrRefund = {};\r\n\t}\r\n\r\n\t@Input() currentYear?: AnnualDetailYear;\r\n\t@Input() editState: AnnualDetailEditState;\r\n\t@Input() hasCompanyCollectors: boolean;\r\n\t@Input() viewModel: TaxesViewModel;\r\n\t@Input() parcelID: number;\r\n\t@Input() gridNavigationHandler: () => void;\r\n\t@Output() AnnualDetailsSaveAllowedChangedX: EventEmitter = new EventEmitter();\r\n\r\n\t@ViewChild('addBillModal') addBillModal: ModalDirective;\r\n\r\n\twaitingOnServer: boolean;\r\n\tisAddBillModalShown: boolean;\r\n\tisStateCollectorsShown: boolean = true;\r\n\tparcelCollectors: Collector[] = [];\r\n\tcompanyCollectors: Collector[];\r\n\tbillOrRefund: any;\r\n\r\n\tngOnInit(): void {\r\n\t\tthis.viewModelChanged();\r\n\r\n this.navigationEvent.refreshAccrualDetailsLinkEvent$.forEach((event: boolean) => {\r\n\t\t\t// This will toggle the visibility of the Accrual Details link\r\n\t\t\t// based on whether all Payments are excluded from Accrual or not.\r\n\t\t\tthis.viewModel.currentTab.allPaymentsExcludedFromAccrual = event;\r\n });\r\n\t}\r\n\r\n\tngOnChanges(changes: SimpleChanges): void {\r\n\t\t// Look for changes to the viewModel input property\r\n\t\tif (Object.keys(changes).indexOf('viewModel') >= 0) {\r\n\t\t\tthis.viewModelChanged();\r\n\t\t}\r\n\t}\r\n\r\n annualDetailsSaveAllowedChanged(isAnnualDetailsSaveAllowed: boolean): void {\r\n\t\tthis.AnnualDetailsSaveAllowedChangedX.emit(isAnnualDetailsSaveAllowed);\r\n }\r\n\r\n\tviewModelChanged(): void {\r\n\t\tthis.editState.showEditControls = this.viewModel && this.viewModel.model.length > 0;\r\n\t}\r\n\r\n\tgetBillVM(tab: BillCluster): BillViewModel {\r\n\t\tconst billVM = new BillViewModel();\r\n\r\n\t\tbillVM.model = tab.bills;\r\n\t\tbillVM.parcelID = this.viewModel.parcelID;\r\n\t\tbillVM.parcelAcctNum = this.viewModel.parcelAcctNum;\r\n\t\tbillVM.tabTitle = tab.title || tab.collector.abbr;\r\n\t\tbillVM.hasWritePermission = this.editState.hasWritePermission;\r\n\t\tbillVM.year = this.viewModel.annualYearModel.annualYear1;\r\n\t\tbillVM.yearRevisions = this.currentYear.annualGridDetails;\r\n billVM.taskSummariesPromise = tab.taskSummariesPromise;\r\n billVM.hasAvailableTaxSetup = tab.bills[0].collectorPaymentOptionID && tab.hasAvailableTaxSetup;\r\n billVM.model.forEach(m => m.billClusterRowVersion = tab.rowVersion);\r\n\r\n\t\treturn billVM;\r\n\t}\r\n\r\n\tgetRefundVM(tab: BillCluster) {\r\n\t\tconst refundVM = new RefundViewModel();\r\n\r\n\t\trefundVM.model = tab.refund;\r\n\t\trefundVM.parcelID = this.viewModel.parcelID;\r\n\t\trefundVM.parcelAcctNum = this.viewModel.parcelAcctNum;\r\n\t\trefundVM.tabTitle = tab.title;\r\n\t\trefundVM.hasWritePermission = this.editState.hasWritePermission;\r\n\t\trefundVM.year = this.viewModel.annualYearModel.annualYear1;\r\n\r\n\t\treturn refundVM;\r\n\t}\r\n\r\n\t// Need to catch this event in Angular 2\r\n\r\n\t// scope.$on('entityTaskUpdated', function () {\r\n\t// \tif (scope.active.billTab) {\r\n\t// \t\tgetTaskSummaries(scope.active.billTab);\r\n\t// \t}\r\n\t// });\r\n\r\n\r\n\t// scope.$watch('active.billTab', function (newVal, oldVal) {\r\n\t// \tfunction maybeBill() {\r\n\t// \t\tif (oldVal.bills > 0) {\r\n\t// \t\t\treturn oldVal.calcProjected === newVal.calcProjected && oldVal.bills[0].collectorPaymentOptions\r\n\t// \t\t}\r\n\t// \t\treturn true;\r\n\t// \t}\r\n\r\n\t// \tif (oldVal && newVal && oldVal.billClusterID === newVal.billClusterID && oldVal.updated === newVal.updated && maybeBill()) {\r\n\t// \t\tscope.active.billTab.updated = true;\r\n\t// \t}\r\n\t// }, true)\r\n\r\n\tasync addBill(): Promise {\r\n\t\tthis.parcelCollectors = await this.getStateCollectors();\r\n\r\n\t\tif(this.parcelCollectors.length) {\r\n\t\t\tthis.billOrRefund.collectorID = this.parcelCollectors[0].collectorID;\r\n\t\t} else {\r\n\t\t\tthis.isStateCollectorsShown = false;\r\n\t\t\tthis.companyCollectors = await this.getCompanyCollectors();\r\n\r\n\t\t\tif(this.companyCollectors.length) {\r\n\t\t\t\tthis.billOrRefund.collectorID = this.companyCollectors[0].collectorID;\r\n\t\t\t} else {\r\n\t\t\t\tthis.toastr.warning('This parcel has no associated governmental or company collectors.', 'Cannot Add Bill');\r\n\t\t\t\treturn Promise.resolve();\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tthis.billOrRefund.type = 'bill';\r\n\t\tthis.isAddBillModalShown = true;\r\n\t}\r\n\r\n async getCollectorList(): Promise {\r\n\t\tif(!this.isStateCollectorsShown) {\r\n\t\t\tthis.companyCollectors = await this.getCompanyCollectors();\r\n\t\t\tif(this.companyCollectors.length) {\r\n\t\t\t\tthis.billOrRefund.collectorID = this.companyCollectors[0].collectorID;\r\n\t\t\t}\r\n } else {\r\n\t\t\tthis.parcelCollectors = await this.getStateCollectors();\r\n\t\t\tif(this.parcelCollectors.length) {\r\n\t\t\t\tthis.billOrRefund.collectorID = this.parcelCollectors[0].collectorID;\r\n\t\t\t}\r\n }\r\n }\r\n\r\n async getCompanyCollectors(): Promise {\r\n const results = await this.http.get(`/api/collector/AnnualYear/${ this.currentYear.annualYearID}`);\r\n\t\treturn _.sortBy(results, (collector) => collector.abbr.toLowerCase());\r\n }\r\n\r\n async getStateCollectors(): Promise {\r\n const results = await this.http.get('/api/collectorassociation', { params: { parcelid: this.parcelID } });\r\n\t\treturn _.sortBy(results, (collector) => collector.collector.abbr.toLowerCase());\r\n }\r\n\r\n\tonHidden(): void {\r\n\t\tthis.isAddBillModalShown = false;\r\n\t}\r\n\r\n\tsaveBillOrRefund() {\r\n\t\tconst newBillCluster = new BillCluster(this.currentYear.annualYearID, this.billOrRefund.collectorID);\r\n\r\n\t\tif (this.billOrRefund.type == 'refund') {\r\n\t\t\tnewBillCluster.refund = new Refund(this.currentYear.annualYearID, this.billOrRefund.collectorID);\r\n\t\t}\r\n\r\n\t\t// Weird to do a PUT for a new bill cluster, but here we are.\r\n\t\t// Consider refactoring\r\n\t\tthis.waitingOnServer = true;\r\n\t\tthis.billClusterService.saveTab(newBillCluster, true)\r\n\t\t\t.then((tab) => {\r\n\t\t\t\tthis.addBillModal.hide();\r\n\t\t\t\tthis.navigationEvent.refreshActivityData();\r\n\r\n\t\t\t\tthis.reloadVM(tab.billClusterID);\r\n\t\t\t})\r\n\t\t\t.catch(() => {\r\n\t\t\t\tthis.waitingOnServer = false;\r\n\t\t\t});\r\n\t}\r\n\r\n\treloadVM(billClusterID?: number) {\r\n\t\tthis.waitingOnServer = true;\r\n\r\n\t\tthis.billClusterService.getTaxesViewModelByYear(this.currentYear, this.viewModel.parcelID, this.viewModel.parcelAcctNum)\r\n\t\t\t.then((viewModel: TaxesViewModel) => {\r\n\t\t\t\t_.assign(this.viewModel, viewModel);\r\n\r\n\t\t\t\tlet index: number = this.viewModel.model.length -1;\r\n\r\n\t\t\t\tif(billClusterID) {\r\n\t\t\t\t\tindex = _.findIndex(this.viewModel.model, {billClusterID: billClusterID});\r\n\t\t\t\t}\r\n\r\n\t\t\t\tthis.billClusterService.setTabIndex(this.viewModel, index);\r\n\r\n\t\t\t\tthis.waitingOnServer = false;\r\n\t\t\t\tthis.editState.entityLoading = false;\r\n\t\t\t})\r\n\t\t\t.catch(() => {\r\n\t\t\t\tthis.waitingOnServer = false;\r\n this.editState.entityLoading = false;\r\n\t\t\t});\r\n\t}\r\n\r\n\tcancelAddBillOrRefund() {\r\n\t\tthis.addBillModal.hide();\r\n\t}\r\n\r\n\tswitchTabs(viewModel: TaxesViewModel, i: number) {\r\n\t\tif (i !== viewModel.currentTabIndex) {\r\n\t\t\tthis.annualDetailsService.preNavigateWarn(this.editState).then(() => {\r\n\t\t\t\tthis.billClusterService.setTabIndex(viewModel, i);\r\n\t\t\t}).catch(() => {\r\n\t\t\t\tthis.viewModel.model.forEach((t, index) => {\r\n\t\t\t\t\tt.active = index === viewModel.currentTabIndex;\r\n\t\t\t\t});\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n\r\n\tasync launchAccrualDetailModal(billCluster: BillCluster) {\r\n\t\tif (this.editState.editMode && this.editState.getDirty()) {\r\n\t\t\tawait this.saveBillCluster();\r\n\t\t}\r\n\r\n\t\tconst initialState = {\r\n\t\t\teditMode: this.editState.editMode,\r\n\t\t\tbillClusterId: billCluster.billClusterID\r\n };\r\n\r\n this.modalService.show(AccrualDetailModalComponent, {initialState, class: 'modal-xl', ignoreBackdropClick: true});\r\n\t}\r\n\r\n\tasync saveBillCluster(callback?: any) {\r\n\t\tthis.editState.entityLoading = true;\r\n\t\tconst result: BillCluster = await this.billClusterService.saveTabFromViewModel(this.viewModel);\r\n\r\n\t\tthis.toastr.info('Bill changes autosaved');\r\n\r\n\t\tif (this.viewModel.currentTab.refund) {\r\n\t\t\tthis.viewModel.currentTab.refund.refundRowVersion = result.refundRowVersion;\r\n\t\t}\r\n\t\telse if (this.viewModel.currentTab.billClusterID) {\r\n\t\t\tthis.viewModel.currentTab.rowVersion = result.rowVersion;\r\n\t\t\tthis.viewModel.currentTab.bills = _.map(this.viewModel.currentTab.bills, bill => {\r\n\t\t\t\tconst savedBill = _.find(result.bills, {billID: bill.billID});\r\n\r\n\t\t\t\tif(savedBill) {\r\n\t\t\t\t\tbill.rowVersion = savedBill.rowVersion;\r\n\t\t\t\t}\r\n\r\n\t\t\t\treturn bill;\r\n\t\t\t});\r\n\t\t}\r\n\r\n\t\tthis.navigationEvent.refreshActivityData();\r\n\t\tthis.navigationEvent.refreshAnnualYear();\r\n\t\tthis.editState.setDirty(false);\r\n\t\tthis.viewModel.resetEdit(true);\r\n\r\n\t\tthis.editState.entityLoading = false;\r\n\r\n\t\tif(callback) {\r\n\t\t\tcallback();\r\n\t\t}\r\n\t}\r\n}\r\n","\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { NavigationState } from '../annual-details-navigation.service';\r\nimport { AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { AnnualAssessmentDetail, Assessment } from '../Assessments/assessment.model';\r\nimport { AssessmentService } from '../Assessments/assessment.service';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nexport interface IAddRevisionConfig {\r\n currentAssessment: Assessment;\r\n currentYear: AnnualDetailYear;\r\n navigationState: NavigationState;\r\n}\r\n\r\n@Component({\r\n selector: 'add-revision-modal',\r\n templateUrl: './add-revision.component.html'\r\n})\r\nexport class AddRevisionModalComponent implements OnDestroy {\r\n constructor(\r\n private http: SDHttpService,\r\n private assessmentService: AssessmentService,\r\n public modalRef: BsModalRef\r\n ) { }\r\n\r\n assessmentCreatedEventEmitter: EventEmitter = new EventEmitter();\r\n config: IAddRevisionConfig;\r\n isBusy: boolean = false;\r\n newAssessment: Assessment;\r\n other: string;\r\n\r\n ngOnDestroy(): void {\r\n this.assessmentCreatedEventEmitter.complete();\r\n }\r\n\r\n initialize(config): void {\r\n this.config = config;\r\n\r\n const revisionNumber = _.maxBy(this.config.currentYear.annualGridDetails, 'revisionNum').revisionNum + 1;\r\n\r\n // Bug fix - if you use annual year component to navigate, current year isn't set yet, so we need to grab\r\n // it from the navigation state view model\r\n if(!this.config.currentAssessment) {\r\n this.config.currentAssessment = this.config.navigationState.currentAssessmentVM.model;\r\n }\r\n\r\n const newAnnualAssessmentDetails = this.config.currentAssessment.annualAssessmentDetails.map((comp) => {\r\n return _.omit(comp, 'annualAssessmentID', 'annualAssessmentDetailID') as AnnualAssessmentDetail;\r\n });\r\n this.newAssessment = new Assessment(this.config.currentYear.annualYearID, revisionNumber, 0, 'add', newAnnualAssessmentDetails);\r\n\r\n //This is to set up the radio button properly since the 3rd item is \"misc\".\r\n if(this.newAssessment.revisionDesc !== 'Final' && this.newAssessment.revisionDesc !== 'Original' && this.newAssessment.revisionDesc !== 'Forecast') {\r\n this.other = this.newAssessment.revisionDesc;\r\n this.newAssessment.revisionDesc = 'other';\r\n }\r\n }\r\n\r\n checkForEnter(e: any): void {\r\n if (e.which === 13) {\r\n this.save();\r\n }\r\n }\r\n\r\n disableSave(): boolean {\r\n let userInput: string = this.other;\r\n if(userInput) {\r\n userInput = userInput.trim();\r\n }\r\n return (this.newAssessment.revisionDesc === 'other' && !userInput) || this.isBusy;\r\n }\r\n\r\n async save(): Promise {\r\n if (this.newAssessment.revisionDesc === 'other') {\r\n if (this.other) {\r\n this.newAssessment.revisionDesc = this.other;\r\n } else {\r\n return;\r\n }\r\n }\r\n\r\n this.isBusy = true;\r\n\r\n try {\r\n const assessment = this.assessmentService.prepareAnnualAssessmentForCreate(this.newAssessment);\r\n const response = await this.http.post('/api/annualassessment/', assessment);\r\n\r\n this.assessmentCreatedEventEmitter.emit(response);\r\n this.modalRef.hide();\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{ currentYear?.annualYear1 }}
\r\n \r\n\r\n \r\n
\r\n Comp\r\n \r\n
\r\n {{ getComplianceFilingType(filingType.filingTypeId) }}\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n Asmts\r\n \r\n {{ annualDetailsService.getComponentName(comp, componentTypes) }}\r\n \r\n
Total FMV:
\r\n
{{ annualDetailsService.getComponentName(comp, componentTypes) }}\r\n
\r\n \r\n
Taxable{{i === 0 ? '' : i + 1}}
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n {{ comp.fairMarketValue | number:'1.0-0' }}\r\n
\r\n
{{\r\n annualDetailsService.getTotalFMV(currentAnnualDetailAssessment?.annualGridComponents, viewTaxableValues) |\r\n number:'1.0-0'\r\n }}\r\n
\r\n
{{ comp.fairMarketValue | number: '1.0-0' }}\r\n
\r\n \r\n
{{taxableValue}}
\r\n
\r\n
\r\n
\r\n
\r\n Appeals\r\n \r\n
Resolution:
\r\n
Savings:
\r\n
\r\n
\r\n
\r\n
\r\n {{ currentYear.recalculatedStatus || currentYear.annualGridDetails[0].appealStatus }}\r\n {{ currentYear.recalculatedStatus || currentYear.annualGridDetails[0].appealStatus }}\r\n
\r\n
{{ annualDetailsService.formatSavings(currentYear.recalculatedSavings) || annualDetailsService.formatSavings(currentYear.annualGridDetails[0].savings) }}\r\n
\r\n
\r\n
= 2\" class=\"revision\"\r\n [style.cursor]=\"notAllowedIfConsolidated\">\r\n
\r\n {{ currentYear.recalculatedStatus || currentYear.collapsedAppealStatus }}\r\n {{ currentYear.recalculatedStatus || currentYear.collapsedAppealStatus }}\r\n
\r\n
\r\n {{ annualDetailsService.formatSavings(currentYear.recalculatedSavings) }}\r\n {{ annualDetailsService.formatSavings(currentYear.collapsedSavings) }}\r\n
\r\n
\r\n
\r\n
\r\n Taxes\r\n \r\n
Total:
\r\n
Eff. Rate:
\r\n
\r\n
\r\n
{{ currentYear.totalTaxes | currency: 'USD' }}
\r\n
{{ currentYear.effectiveRate | number: '1.6-6' }}%
\r\n
\r\n
\r\n Budget\r\n \r\n
0\" style=\"padding-top: 0; padding-bottom: 0;\">\r\n
{{ currentYear.latestBudgetAmount | currency: 'USD' }}
\r\n
\r\n
\r\n","import { Component, Input, OnChanges, OnInit, SimpleChanges } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { MessageBoxButtons, MessageBoxResult, MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { NavigationState, ViewTarget } from '../annual-details-navigation.service';\r\nimport { AnnualDetailsService } from '../annual-details.service';\r\nimport { AnnualBudgetService } from '../Budget/budget.details.service';\r\nimport { Assessment } from '../Assessments/assessment.model';\r\nimport { FilingType } from '../Compliance/compliance.model';\r\nimport { AddRevisionModalComponent } from '../Modals/add-revision.component';\r\nimport { AnnualDetailAssessment, AnnualDetailYear } from './annual-year.model';\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'annual-year',\r\n templateUrl: './annual-year.component.html'\r\n})\r\nexport class AnnualYearComponent implements OnInit, OnChanges {\r\n constructor(\r\n public annualDetailsService: AnnualDetailsService,\r\n private annualBudgetService: AnnualBudgetService,\r\n private http: SDHttpService,\r\n private messageBox: MessageBoxService,\r\n private modalService: BsModalService\r\n ) { }\r\n\r\n @Input() navigationState: NavigationState;\r\n @Input() currentYear: AnnualDetailYear;\r\n @Input() currentAnnualDetailAssessment: AnnualDetailAssessment;\r\n @Input() componentTypes: any[];\r\n @Input() filingTypes: FilingType[];\r\n @Input() budgetsEnabled: boolean;\r\n @Input() consolidatingTypeId: Core.ConsolidatingTypeEnum;\r\n @Input() viewTaxableValues: boolean;\r\n @Input() maxNumberOfTaxableValues: number;\r\n\r\n currentAssessment: Assessment;\r\n ViewTarget = ViewTarget;\r\n loadingImage: boolean = false;\r\n\r\n get notAllowedIfConsolidated() {\r\n return this.consolidatingTypeId == Core.ConsolidatingTypeEnum.Consolidated ? 'not-allowed' : 'pointer';\r\n }\r\n\r\n ngOnInit() {\r\n //this.currentAnnualDetailAssessment = this.navigationState.currentRevision;\r\n\r\n //this.selectedChangeRevision = this.currentAnnualDetailAssessment;\r\n\r\n if(this.navigationState.viewTarget === this.ViewTarget.assessment) {\r\n this.currentAssessment = this.navigationState.currentAssessmentVM.model;\r\n }\r\n\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void{\r\n if (Object.keys(changes).indexOf('currentYear') >= 0) {\r\n const currentRevision = _.find(this.currentYear.annualGridDetails, { 'annualAssessmentID': this.currentAnnualDetailAssessment.annualAssessmentID });\r\n if(currentRevision) {\r\n this.currentAnnualDetailAssessment = currentRevision;\r\n }\r\n } /*else if(Object.keys(changes).indexOf('viewTarget') >= 0 ) {\r\n if(this.navigationState.viewTarget === this.ViewTarget.assessment) {\r\n this.currentAssessment = this.navigationState.currentAssessmentVM.model;\r\n }\r\n }*/\r\n\r\n }\r\n\r\n //change event for the revision dropdown\r\n selectRev(newRevision?: AnnualDetailAssessment): void {\r\n //this.currentAnnualDetailAssessment = this.selectedChangeRevision;\r\n //if(this.navigationState.viewTarget === ViewTarget.assessment) {\r\n // If this is an event, we'll get the new revision as an arguments before Angular actually changes\r\n // this.currentAnnualDetailAssessment, so in that case use the argument instead (WK-2563)\r\n this.navigationState.goToAssessment(this.currentYear, newRevision || this.currentAnnualDetailAssessment);\r\n //}\r\n }\r\n\r\n activateViewTarget(viewTarget: ViewTarget): void {\r\n if (this.navigationState.viewTarget == viewTarget) return;\r\n\r\n switch(viewTarget) {\r\n case ViewTarget.appeal:\r\n if (this.consolidatingTypeId != Core.ConsolidatingTypeEnum.Consolidated)\r\n this.navigationState.goToAppeals(this.currentYear, this.currentAnnualDetailAssessment);\r\n break;\r\n case ViewTarget.assessment:\r\n if (this.consolidatingTypeId != Core.ConsolidatingTypeEnum.Consolidated)\r\n this.navigationState.goToAssessment(this.currentYear, this.currentAnnualDetailAssessment);\r\n break;\r\n case ViewTarget.tax:\r\n if (this.consolidatingTypeId != Core.ConsolidatingTypeEnum.Consolidated)\r\n this.navigationState.goToTaxes(this.currentYear);\r\n break;\r\n case ViewTarget.compliance:\r\n this.navigationState.goToCompliance(this.currentYear);\r\n break;\r\n case ViewTarget.budget:\r\n this.navigationState.goToBudget(this.currentYear, this.currentYear.latestBudgetId);\r\n break;\r\n }\r\n }\r\n\r\n activateAddRevision(): void {\r\n this.promptAutoSave('Creating a new revision with pending changes will force a save of the current revision. Do you wish to continue?').then(() => {\r\n const ref = this.modalService.show(AddRevisionModalComponent, {\r\n class: 'modal-sm'\r\n });\r\n\r\n ref.content.initialize({\r\n currentAssessment: this.currentAssessment,\r\n currentYear: this.currentYear,\r\n navigationState: this.navigationState\r\n });\r\n\r\n const subscription = ref.content.assessmentCreatedEventEmitter.subscribe(\r\n // next\r\n async (assessment) => {\r\n this.loadingImage = true;\r\n\r\n try {\r\n await this.createNewAssessment(assessment);\r\n } finally {\r\n this.loadingImage = false;\r\n }\r\n },\r\n // error\r\n () => {\r\n return null;\r\n },\r\n // completed\r\n () => {\r\n subscription.unsubscribe();\r\n ref.hide();\r\n }\r\n );\r\n }, () => {\r\n return null;\r\n });\r\n }\r\n\r\n /////////////////////////////////\r\n // Formatting functions\r\n /////////////////////////////////\r\n //determines if we need the strikethrough on a cell\r\n hasStrikeThru(): string {\r\n let ngClass = '';\r\n\r\n switch (this.navigationState.viewTarget) {\r\n case ViewTarget.appeal:\r\n /*if ($scope.strikeThru.status) {\r\n ngClass += 'strike-thru-status strike-thru-savings';\r\n } else if ($scope.strikeThru.savings) {\r\n ngClass += 'strike-thru-savings'\r\n }*/\r\n\r\n break;\r\n case ViewTarget.assessment:\r\n if (this.currentAnnualDetailAssessment) {\r\n //This model does not contain efAction, where does this come from?\r\n /*if (this.currentAssessment.efAction !== null) {\r\n ngClass += 'strike-thru-status';\r\n }*/\r\n\r\n //if (revisionEdited($scope.active.revision) && $scope.active.year.totalAppealCountForYear > 0) {\r\n if(this.currentYear.totalAppealCountForYear > 0 &&\r\n _.some(this.currentAnnualDetailAssessment.annualGridComponents, (component) => {\r\n return component.efAction !== null;\r\n })) {\r\n\r\n ngClass += ' strike-thru-savings';\r\n }\r\n }\r\n break;\r\n }\r\n\r\n return ngClass;\r\n }\r\n\r\n notActual(): boolean {\r\n const latestRevision: AnnualDetailAssessment = _.maxBy(this.navigationState.currentYear.annualGridDetails, 'revisionNum');\r\n\r\n if (latestRevision.status === 0 || this.activeNotActual(this.currentAnnualDetailAssessment, latestRevision)) {\r\n return true;\r\n }\r\n\r\n return false;\r\n }\r\n\r\n activeNotActual(rev: AnnualDetailAssessment, latestRevision: AnnualDetailAssessment): boolean {\r\n if (rev) {\r\n return rev.revisionNum >= latestRevision.revisionNum && rev.status === 0;\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n getComplianceFilingType(complianceId: number): string {\r\n const filingType: FilingType = _.find(this.filingTypes, { filingTypeId: complianceId });\r\n return filingType ? filingType.name : '';\r\n }\r\n\r\n // Returns the not-actual class if at least one bill for that year has not been received.\r\n //TODO: We don't have taxes.tabs yet. Don't know where this comes from.\r\n notReceived(): boolean {\r\n //Grant said to make this like the annual year. This is what annual year does for the\r\n //not-actual coloring\r\n if(this.currentYear.taxIsEstimated) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n private createNewAssessment(createdAssessment): Promise {\r\n return this.http.get(`/api/annualassessmentview/annualyear/${ this.currentYear.annualYearID}`).then((result: AnnualDetailYear) => {\r\n result = this.annualDetailsService.formatYearDateDisplay([result])[0];\r\n _.assign(this.currentYear, result);\r\n\r\n const createdAnnualDetailAssessment = _.find(result.annualGridDetails, {'annualAssessmentID': createdAssessment.annualAssessmentID});\r\n\r\n _.assign(this.currentAssessment, createdAnnualDetailAssessment);\r\n this.currentAnnualDetailAssessment = createdAnnualDetailAssessment;\r\n\r\n this.navigationState.refreshGrid = true;\r\n this.navigationState.goToAssessment(this.currentYear, createdAnnualDetailAssessment).then(() => {\r\n this.navigationState.setEditMode(true);\r\n });\r\n\r\n });\r\n }\r\n\r\n private promptAutoSave(message: string) : Promise {\r\n return new Promise((resolve, reject) => {\r\n if (this.navigationState.getDirty()) {\r\n return this.messageBox.open({\r\n title: 'WARNING',\r\n message: message,\r\n buttons: MessageBoxButtons.YesNo\r\n }).then((result) => {\r\n switch (result) {\r\n case MessageBoxResult.Yes:\r\n return this.navigationState.saveHandler().then(() => {\r\n this.navigationState.setDirty(false);\r\n resolve();\r\n });\r\n\r\n default:\r\n reject();\r\n break;\r\n }\r\n });\r\n }\r\n\r\n resolve();\r\n });\r\n }\r\n}\r\n","
\r\n
\r\n

{{ config.year }} Revisions

\r\n \r\n
\r\n
\r\n
\r\n Savings changes...\r\n
\r\n
\r\n
Drag & drop the revisions below to order them from the earliest (top) to the most recent (bottom).
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n\r\n REVISION {{ index + 1 }}\r\n
\r\n {{ item.value.description }}\r\n
\r\n
\r\n","import { Component, EventEmitter, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AnnualDetailsService } from '../annual-details.service';\r\n\r\ndeclare const _: any;\r\n\r\nexport interface IReorderRevisionsConfig {\r\n annualYearID: number;\r\n year: number;\r\n assessments: {\r\n id: number;\r\n description: string;\r\n sequence: number;\r\n }[]\r\n}\r\n\r\n@Component({\r\n selector: 'reorder-revisions-modal',\r\n templateUrl: './reorder-revisions.component.html'\r\n})\r\nexport class ReorderRevisionsModalComponent implements OnDestroy {\r\n constructor(\r\n public modalRef: BsModalRef,\r\n private _annualDetailsService: AnnualDetailsService\r\n ) { }\r\n\r\n assessmentsReorderedEventEmitter: EventEmitter = new EventEmitter();\r\n\r\n config: IReorderRevisionsConfig;\r\n\r\n isBusy: boolean = false;\r\n\r\n ngOnDestroy(): void {\r\n this.assessmentsReorderedEventEmitter.complete();\r\n }\r\n\r\n initialize(config: IReorderRevisionsConfig): void {\r\n // the sortable compoenent reorganizes items in the array based on their index as the user drag-and-drops\r\n // sorting revisions so that the first revision matches the first index in the array\r\n config.assessments = _.orderBy(config.assessments, ['sequence'], ['asc']);\r\n this.config = config;\r\n }\r\n\r\n save(): void {\r\n this.isBusy = true;\r\n\r\n const orderedAssessmentIDs = this.config.assessments.map(i => i.id);\r\n\r\n this._annualDetailsService.orderRevisions(this.config.annualYearID, orderedAssessmentIDs).then(() => {\r\n this.isBusy = false;\r\n this.assessmentsReorderedEventEmitter.emit();\r\n this.modalRef.hide();\r\n }, () => {\r\n this.isBusy = false;\r\n });\r\n }\r\n}","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AllocationRepository } from '../Repositories';\r\n\r\n@Injectable()\r\nexport class AllocationService {\r\n constructor(private _allocationRepository: AllocationRepository) { }\r\n\r\n private _parcelId: number;\r\n\r\n set navigationParcelId(parcelId: number) {\r\n this._parcelId = parcelId;\r\n }\r\n\r\n get navigationParcelId(): number {\r\n return this._parcelId;\r\n }\r\n\r\n createAllocation(companyId: number, createModel: Compliance.AllocationCreateModel): Promise {\r\n return lastValueFrom(this._allocationRepository.create(companyId, createModel));\r\n }\r\n}\r\n","import { Pipe, PipeTransform } from '@angular/core';\r\nimport { ComponentFilter } from '../annual-details.service';\r\nimport { AnnualAssessmentDetail } from '../Assessments/assessment.model';\r\n\r\n@Pipe({\r\n name: 'componentFilter',\r\n pure: false\r\n})\r\nexport class AssessmentComponentExemptionPipe implements PipeTransform {\r\n transform(items: AnnualAssessmentDetail[], filterType: ComponentFilter): AnnualAssessmentDetail[] {\r\n if (!items || filterType === undefined) {\r\n return items;\r\n }\r\n\r\n switch (filterType as ComponentFilter) {\r\n case ComponentFilter.exempt:\r\n return items.filter(item => item.assessmentComponentTypeID !== 3 && item.assessmentComponentTypeID !== 2 && item.efAction !== 'delete');\r\n case ComponentFilter.nonexempt:\r\n return items.filter(item => item.assessmentComponentTypeID === 2 && item.efAction !== 'delete');\r\n case ComponentFilter.alternative:\r\n return items.filter(item => item.assessmentComponentTypeID === 3 && item.efAction !== 'delete');\r\n default:\r\n return items;\r\n }\r\n }\r\n}","import { Input, Output, EventEmitter, Component, SimpleChanges } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'assessment-input',\r\n templateUrl: './assessment-input.component.html'\r\n})\r\nexport class FmvInputComponent {\r\n constructor() {\r\n this.isOverriddenChange = new EventEmitter();\r\n this.valueChange = new EventEmitter();\r\n this.internalValue = '';\r\n this.internalIsOverridden = false;\r\n this.modelChanging = false;\r\n this.resetIt = new EventEmitter();\r\n }\r\n\r\n @Input() isOverridden: boolean;\r\n @Output() isOverriddenChange: EventEmitter;\r\n @Input() value: number;\r\n @Input() componentName: string;\r\n @Output() valueChange: EventEmitter;\r\n @Input() filterFunction: (input: string, hash: boolean, negative: boolean) => string;\r\n @Output() resetIt: EventEmitter;\r\n @Input() allowNegatives: boolean = false;\r\n @Input() allowOverrides: boolean = false;\r\n internalValue: string;\r\n internalIsOverridden: boolean;\r\n modelChanging: boolean;\r\n\r\n // find the location where commas need to be inserted so that they can be replaced with ','\r\n readonly ADD_COMMAS_REGEX = new RegExp('\\\\B(?=(\\\\d{3})+(?!\\\\d))', 'g');\r\n\r\n // find the commas so that they can be replaced with ''\r\n readonly REMOVE_COMMAS_REGEX = new RegExp(',', 'g');\r\n\r\n /**\r\n * The 'internalValueFormatted' property is setup as a wrapper around the 'internalValue' property and it only provided comma formatting.\r\n * Because such input box is setup to handle the '#' as a special character we cannot directly apply the 'currencyMask' directive.\r\n * Notes:\r\n * In the future, consider a UI flag for turning on/off the 'overrride' mode. That will not require us to support the '#' character\r\n * and allow us to use the 'currencyMask' directive.\r\n */\r\n get internalValueFormatted(): string {\r\n if (this.internalValue !== null && this.internalValue !== undefined) {\r\n // if the user is overwriting with the '#' character keep the '#' and format the rest with commas otherwise just format with commas\r\n return this.internalValue.toString().charAt(0) === '#'\r\n ? `#${this.internalValue.toString().slice(1).replace(this.ADD_COMMAS_REGEX, ',')}`\r\n : this.internalValue.toString().replace(this.ADD_COMMAS_REGEX, ',');\r\n }\r\n return this.internalValue;\r\n }\r\n set internalValueFormatted(value: string) {\r\n // remove commas and set internal value\r\n this.internalValue = value.toString().replace(this.REMOVE_COMMAS_REGEX, '');\r\n this._processInternalValueChanged();\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges) {\r\n if (changes['value'] && !this.modelChanging) {\r\n this.internalValue = changes['value'].currentValue && changes['value'].currentValue.toString();\r\n }\r\n if (changes['isOverridden']) {\r\n this.internalIsOverridden = changes['isOverridden'].currentValue;\r\n }\r\n }\r\n\r\n onBlur() {\r\n //this.internalValue = event.target.value as string;\r\n const originallyOverridden = this.internalIsOverridden;\r\n\r\n if (this.internalValue[0] === '#') {\r\n this.internalValue = this.internalValue.substr(1);\r\n //event.target.value = this.internalValue; // two-way binding of the \"internalValueFormatted\" will take care of this\r\n this.internalIsOverridden = true;\r\n }\r\n\r\n if (this.internalValue === '') {\r\n if (this.internalIsOverridden) {\r\n this.resetIt.emit();\r\n }\r\n else {\r\n this.valueChange.emit(null);\r\n }\r\n this.internalIsOverridden = false;\r\n }\r\n else {\r\n this.valueChange.emit(parseInt(this.internalValue, 10));\r\n }\r\n\r\n if (originallyOverridden !== this.internalIsOverridden) {\r\n this.isOverriddenChange.emit(this.internalIsOverridden);\r\n }\r\n }\r\n\r\n private _processInternalValueChanged() {\r\n if (this.modelChanging) return;\r\n\r\n setTimeout(() => {\r\n this.modelChanging = true;\r\n const originallyOverridden = this.internalIsOverridden;\r\n\r\n //Remove cents in the case we've copy/pasted\r\n const periodInput: number = this.internalValue.indexOf('.');\r\n let tempValue: string;\r\n if(periodInput >= 0) {\r\n tempValue = this.internalValue.substr(0, periodInput);\r\n } else {\r\n tempValue = this.internalValue;\r\n }\r\n\r\n const newValue = this.filterFunction(tempValue, this.allowOverrides, this.allowNegatives);\r\n this.internalValue = newValue;\r\n\r\n if (!newValue) {\r\n this.valueChange.emit(0);\r\n }\r\n else if (newValue === '#' && this.allowOverrides) {\r\n this.internalIsOverridden = true;\r\n }\r\n else if (newValue[0] === '#' && this.allowOverrides) {\r\n this.valueChange.emit(parseInt(newValue.substr(1), 10));\r\n this.internalIsOverridden = true;\r\n }\r\n else {\r\n this.valueChange.emit(parseInt(newValue, 10));\r\n }\r\n\r\n if (originallyOverridden !== this.internalIsOverridden) {\r\n this.isOverriddenChange.emit(this.internalIsOverridden);\r\n }\r\n\r\n setTimeout(() => {\r\n this.modelChanging = false;\r\n }, 1);\r\n }, 1);\r\n }\r\n}","","\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
{{ viewModel.model.revisionDesc }}
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0 && !viewTaxableValues\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n Component\r\n \r\n AV\r\n \r\n Ratio (%)\r\n \r\n \r\n \r\n FMV\r\n MV\r\n \r\n \r\n
{{ annualDetailsService.getComponentName(annualDetail, viewModel.components) }}\r\n \r\n \r\n\r\n {{ annualDetail.assessedValue | number:\"1.0-0\" }}\r\n \r\n \r\n\r\n {{ annualDetail.displayRatio | number:\"1.3-3\" }}%\r\n \r\n \r\n \r\n \r\n \r\n {{ getFairMarketValue(annualDetail) | number:\"1.0-0\" }}\r\n \r\n \r\n \r\n \r\n
\r\n Pre AdjTotal\r\n {{ getTotal('assessedValue', [2, 3]) | number: '1.0-0' }}{{ getTotal('fairMarketValue', [2, 3]) | number: '1.0-0' }}
{{ annualDetailsService.getComponentName(annualDetail, viewModel.components) }}\r\n \r\n \r\n\r\n {{ annualDetail.assessedValue | number:\"1.0-0\" }}\r\n \r\n \r\n\r\n {{ annualDetail.ratio * 100.000 | number:\"1.3-3\" }}%\r\n \r\n \r\n \r\n \r\n \r\n {{ getFairMarketValue(annualDetail) | number:\"1.0-0\" }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{ annualDetailsService.getComponentName(annualDetail, viewModel.components) }}\r\n \r\n \r\n {{ annualDetail.assessedValue | number:\"1.0-0\" }}\r\n \r\n \r\n {{ annualDetail.ratio * 100.000 | number:\"1.3-3\" }}%\r\n \r\n \r\n \r\n \r\n \r\n {{ getFairMarketValue(annualDetail) | number:\"1.0-0\" }}\r\n \r\n \r\n \r\n \r\n
Total{{ getTotal('assessedValue', [3]) | number:'1.0-0' }}{{ getTotal('fairMarketValue', [3]) | number:'1.0-0' }}
{{ annualDetailsService.getComponentName(annualDetail, viewModel.components) }}\r\n \r\n \r\n\r\n {{ annualDetail.assessedValue | number:\"1.0-0\" }}\r\n \r\n \r\n\r\n {{ annualDetail.ratio * 100.000 | number:\"1.3-3\" }}%\r\n \r\n \r\n \r\n \r\n \r\n {{ getFairMarketValue(annualDetail) | number:\"1.0-0\" }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n
Taxable{{i !== 0 ? i + 1 : ''}}{{ total.assessedValue | number:'1.0-0' }}{{ total.fairMarketValue | number:'1.0-0' }}
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
WARNING! Target Value exceeds FMV
\r\n
\r\n \r\n
\r\n \r\n Target Value: {{ viewModel.currentYear.targetValue | number:'1.0-0' }}\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
WARNING! Appeal By date is in the past
\r\n
WARNING! The date entered is later than\r\n the system default date\r\n
\r\n
\r\n
\r\n
\r\n
\r\n Appeal By: \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n {{ viewModel.model.appealDeadline | weissmanDateFormat: true }}\r\n \r\n
\r\n\r\n \r\n
\r\n Status: N/A - No Responsibility
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n Allocation Status:\r\n {{ allocationTaskSummaries.Status }}\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n\r\n \r\n
\r\n \r\n \r\n
\r\n\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n","import {\r\n ChangeDetectorRef,\r\n Component,\r\n EventEmitter,\r\n Input,\r\n OnChanges,\r\n OnInit,\r\n Output,\r\n SimpleChanges,\r\n ViewChild,\r\n} from '@angular/core';\r\nimport { AnnualDetailComponent, AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { AnnualDetailEditState } from '../annual-details-navigation.service';\r\nimport { AnnualAssessmentDetail, Assessment } from './assessment.model';\r\nimport { AssessmentService, AssessmentViewModel } from './assessment.service';\r\nimport { AnnualDetailsService, ComponentFilter } from '../annual-details.service';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { CurrentEntityService } from '../../Common/Entity/CurrentEntityService';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { PopoverDirective } from 'ngx-bootstrap/popover';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AnnualDetailsNavigationEventService } from '../annual-details-event.service';\r\nimport { ReorderRevisionsModalComponent } from '../Modals/reorder-revisions.component';\r\nimport { AllocationService } from '../../Compliance/Allocation/allocation.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { Decimal } from 'decimal.js';\r\nimport { BusyIndicatorMessageManager } from '../../Busy-Indicator';\r\nimport * as moment from 'moment';\r\nimport * as _ from 'lodash';\r\nimport { isNumber } from 'lodash';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { AssessmentComponentExemptionPipe } from '../Pipes/assessment-component-exemption.pipe';\r\nimport { AssessmentComponentTypeEnum } from '../../constants.new';\r\nimport EntityTypes = Core.EntityTypes;\r\nimport TaxableAssessmentTypeEnum = Core.TaxableAssessmentTypeEnum;\r\n\r\nconst ASSESSMENT_ENTITY_TYPE_ID = EntityTypes.AnnualAssessment;\r\n\r\n// type lite should have had our back here but no joy, so hand coding this. please don't use outside this component\r\ninterface TaskSummaryItemDTO {\r\n TaskSeriesID: number;\r\n TaskSeriesTypeID: number;\r\n Status: string;\r\n CompletedDateTime?: Date;\r\n SeriesIsComplete: boolean;\r\n EntityID: number;\r\n EntityTypeID: number;\r\n OriginalEntityID: number;\r\n TrackDataEnterRefundComplete: boolean;\r\n}\r\n\r\n// type lite should have had our back here but no joy, so hand coding this. please don't use outside this component\r\ninterface TaskSummaryItemDTOAssessment extends TaskSummaryItemDTO {\r\n AdjustNoticeIsReady?: boolean;\r\n ObtainPostDeterminationReady?: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'assessment',\r\n templateUrl: './assessment.component.html'\r\n})\r\nexport class AssessmentComponent implements OnInit, OnChanges {\r\n constructor(\r\n public annualDetailsService: AnnualDetailsService,\r\n private _allocationService: AllocationService,\r\n private _assessmentService: AssessmentService,\r\n private _taskService: TaskService,\r\n private _currentEntityService: CurrentEntityService,\r\n private _decimalPipe: DecimalPipe,\r\n private _messageBox: MessageBoxService,\r\n private _toastr: ToastrService,\r\n private _changeDetector: ChangeDetectorRef,\r\n private _navigationEvent: AnnualDetailsNavigationEventService,\r\n private _navigationService: UpgradeNavigationServiceHandler,\r\n private _modalService: BsModalService,\r\n private _featureFlagService: FeatureFlagsService,\r\n private _exemptionPipe: AssessmentComponentExemptionPipe\r\n ) { }\r\n\r\n @Input() viewModel: AssessmentViewModel;\r\n @Input() currentYear?: AnnualDetailYear;\r\n @Input() componentTypes?: any[];\r\n @Input() editState?: AnnualDetailEditState;\r\n @Input() taskReadonly: boolean = false;\r\n @Input() gridNavigationHandler: () => void;\r\n @Input() compactMode: boolean = false;\r\n @Input() isDocumentProcessing: boolean = false;\r\n @Input() isIDP: boolean = false;\r\n @Input() companyId: number;\r\n @Input() propertyType: number;\r\n @Input() viewTaxableValues: boolean;\r\n @Output() viewModelChange: EventEmitter = new EventEmitter();\r\n @Output() AssessmentChanged: EventEmitter = new EventEmitter();\r\n @ViewChild('renamePopover') renamePopover: PopoverDirective;\r\n\r\n ComponentFilter = ComponentFilter;\r\n taskSummaries: TaskSummaryItemDTOAssessment;\r\n allocationTaskSummaries: TaskSummaryItemDTO;\r\n originalRevisionName: string;\r\n revisionName: string;\r\n revisionOtherName: string;\r\n taskSummariesLoaded: boolean = false;\r\n allocationTaskSummariesLoaded: boolean = false;\r\n showPopover: boolean = false;\r\n popoverDirection: 'bottom' | 'right' = 'bottom';\r\n dateChanged: boolean = false;\r\n AssessmentEntityTypeId: number = ASSESSMENT_ENTITY_TYPE_ID;\r\n\r\n hasAllocationFeature: boolean;\r\n hasAllocation: boolean;\r\n isPPParcel: boolean;\r\n appealByChanged: boolean = false;\r\n\r\n private _busyIndicatorMsgManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n ngOnInit(): void {\r\n this.hasAllocationFeature = this._featureFlagService.featureFlags.enableAllocationFeature;\r\n this.isPPParcel = this.propertyType === Core.PropertyTypes.Personal;\r\n\r\n this.viewModelChanged();\r\n\r\n if (this.viewModel) {\r\n this.setVariablesFromViewModel();\r\n }\r\n\r\n if (this.compactMode) {\r\n this.popoverDirection = 'right';\r\n }\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (Object.keys(changes).indexOf('viewModel') >= 0 && !changes.viewModel.firstChange) {\r\n this.viewModelChanged();\r\n }\r\n\r\n // This might not strictly-speaking be necessary, but for completeness make sure componentTypes is\r\n // always synced with the view model\r\n if (Object.keys(changes).indexOf('componentTypes') >= 0 && this.componentTypes && this.viewModel) {\r\n this.viewModel.components = this.componentTypes;\r\n }\r\n\r\n // if (Object.keys(changes).indexOf('revisionName') >= 0){\r\n // this.viewModel.model.revisionDesc = ((this.viewModel.model.revisionDesc.toString() == 'Final') || (this.viewModel.model.revisionDesc.toString() == 'Original')) ? this.revisionName : this.revisionOtherName;\r\n // }\r\n }\r\n\r\n viewModelChanged(): void {\r\n if (this.viewModel) {\r\n this.viewModel.model.annualAssessmentDetails = this.getSortedAnnualAssessmentDetails();\r\n this.editState.showEditControls = this.viewModel.model !== undefined;\r\n this.setVariablesFromViewModel();\r\n this.viewModel.hasWritePermission = this.editState.hasWritePermission;\r\n this.viewModel.updateModalData();\r\n this.getTaskSummaries();\r\n this.getAllocationTaskSummaries(); // TODO: maybe wrap in feature flag\r\n if (this.componentTypes) {\r\n this.viewModel.components = this.componentTypes;\r\n }\r\n } else {\r\n this.editState.showEditControls = false;\r\n }\r\n }\r\n\r\n get appealByIsInPast(): boolean {\r\n return moment(this.viewModel.model.appealDeadline).isBefore(moment());\r\n }\r\n\r\n get appealByIsLaterThanOriginal(): boolean {\r\n return moment(this.viewModel.model.appealDeadline).isAfter(this.viewModel.model.originalDeadline);\r\n }\r\n\r\n get isTargetValueGreaterThanTotalFmv(): boolean {\r\n let typeIdsToReject = [];\r\n\r\n if(this._exemptionPipe.transform(this.viewModel.model.annualAssessmentDetails, ComponentFilter.nonexempt).length > 0) {\r\n typeIdsToReject = [3];\r\n }\r\n else if(this._exemptionPipe.transform(this.viewModel.model.annualAssessmentDetails, ComponentFilter.exempt).length > 0) {\r\n typeIdsToReject = [2, 3];\r\n }\r\n\r\n return this.viewModel.currentYear.targetValue > this.getTotal('fairMarketValue', typeIdsToReject);\r\n }\r\n\r\n setRevisionName(closeModal: boolean = false): void {\r\n if (this.revisionName !== 'Other') {\r\n this.viewModel.model.revisionDesc = this.revisionName;\r\n } else {\r\n if ((this.revisionOtherName ? this.revisionOtherName.trim() : '') !== '') {\r\n this.viewModel.model.revisionDesc = this.revisionOtherName;\r\n } else {\r\n this.viewModel.model.revisionDesc = this.originalRevisionName;\r\n }\r\n }\r\n\r\n if (closeModal) {\r\n this.renamePopover.hide();\r\n }\r\n\r\n this.editState.refreshGrid = true;\r\n this.editState.refreshActivity = true;\r\n this.setDirty();\r\n }\r\n\r\n validateRevisionName(): void {\r\n if (!this.viewModel.model.revisionDesc) {\r\n this.viewModel.model.revisionDesc = this.originalRevisionName;\r\n }\r\n }\r\n\r\n launchRevisionReorder(): void {\r\n this.promptAutoSave('Reordering revisions with pending changes will force a save of the current revision. Do you wish to continue?').then(() => {\r\n const ref = this._modalService.show(ReorderRevisionsModalComponent);\r\n\r\n ref.content.initialize({\r\n annualYearID: this.currentYear.annualYearID,\r\n year: this.currentYear.annualYear1,\r\n assessments: this.currentYear.annualGridDetails.map(i => ({\r\n id: i.annualAssessmentID,\r\n description: i.revisionDesc,\r\n sequence: i.revisionNum\r\n }))\r\n });\r\n\r\n const subscription = ref.content.assessmentsReorderedEventEmitter.subscribe(\r\n // next\r\n () => {\r\n this.editState.refreshGrid = true;\r\n this.refreshAssessmentData();\r\n },\r\n // error\r\n () => null,\r\n // completed\r\n () => {\r\n subscription.unsubscribe();\r\n ref.hide();\r\n }\r\n );\r\n });\r\n }\r\n\r\n componentRatioChange(component: AnnualAssessmentDetail): void {\r\n if(isNumber(component.displayRatio)) {\r\n component.ratio = new Decimal(component.displayRatio)\r\n .dividedBy(100)\r\n .toNumber()\r\n }\r\n }\r\n\r\n // We left this as \"any\" because this is a generic component type\r\n // and we don't currently have a model or understand it well enough\r\n getUnusedComponentTypes(annualAssessmentDetails): any {\r\n return _.reject(this.viewModel.components, (compType) => {\r\n // check if this compType has been used by any of the annualAssessmentDetails already\r\n const compTypeIsInUse = _.some(annualAssessmentDetails, (annualAssessmentDetail: AnnualDetailComponent) => {\r\n return annualAssessmentDetail.efAction !== 'delete' && annualAssessmentDetail.assessmentClassComponentID === compType.assessmentClassComponentID;\r\n });\r\n\r\n let alternateComponentAlreadyInUse = false;\r\n\r\n if (compType.assessmentComponent.assessmentComponentTypeID === 3) {\r\n alternateComponentAlreadyInUse = _.some(annualAssessmentDetails, function (annualAssessmentDetail: AnnualDetailComponent) {\r\n return annualAssessmentDetail.efAction !== 'delete' && annualAssessmentDetail.assessmentComponentTypeID === 3;\r\n });\r\n }\r\n\r\n return compTypeIsInUse || alternateComponentAlreadyInUse || !compType.enabled;\r\n });\r\n }\r\n\r\n getTaskSummaries(): void {\r\n if (this.viewModel && this.viewModel.model && this.viewModel.model.annualAssessmentID) {\r\n //removed a constant value\r\n this._taskService.getTaskSummaryByEntity(this.viewModel.model.annualAssessmentID, EntityTypes.AnnualAssessment)\r\n .then((response) => {\r\n this.taskSummaries = response && response.length > 0\r\n ? response[0]\r\n : undefined;\r\n\r\n this.taskSummariesLoaded = true;\r\n\r\n });\r\n }\r\n }\r\n\r\n getAllocationTaskSummaries(): void {\r\n if (this.viewModel && this.viewModel.model && this.viewModel.model.annualAssessmentID) {\r\n // Determine annualAssessmentID to use if there are multiple revisions\r\n const annualAssessmentId = this.viewModel.currentYear.annualGridDetails.length > 1\r\n ? this.viewModel.currentYear.annualGridDetails[this.viewModel.currentYear.annualGridDetails.length - 1].annualAssessmentID\r\n : this.viewModel.model.annualAssessmentID;\r\n\r\n this._taskService.getTaskSummaryByEntity(annualAssessmentId, EntityTypes.AssessmentAllocation)\r\n .then((response) => {\r\n this.allocationTaskSummaries = response && response.length > 0\r\n ? response[0]\r\n : undefined;\r\n\r\n this.allocationTaskSummariesLoaded = true;\r\n });\r\n }\r\n }\r\n\r\n launchTaskModal(): void {\r\n // step 1: if dirty and in \"full\" mode aka annual details, save assessment\r\n // step 2: show toast if auto save is successful\r\n // step 3: launch modal\r\n // step 4: on modal close if shouldReloadTasks, refetch assessments\r\n if (this.editState.getDirty() && !this.compactMode) {\r\n this.editState.saveHandler().then(() => {\r\n this.editState.setDirty(false);\r\n this.viewModel.setEditBackup();\r\n this._toastr.info('Assessment changes autosaved');\r\n this._taskService.launchTaskModal(this.viewModel.model.annualAssessmentID, ASSESSMENT_ENTITY_TYPE_ID, this.taskReadonly || !this.editState.editMode).then(shouldReloadTasks => {\r\n if (shouldReloadTasks) {\r\n this.getTaskSummaries();\r\n this.getAllocationTaskSummaries(); // TODO: feature flag?\r\n this.refreshAssessmentData();\r\n this._navigationEvent.refreshActivityData();\r\n this.editState.setDirty(false);\r\n this.editState.refreshGrid = true;\r\n }\r\n });\r\n });\r\n } else {\r\n this._taskService.launchTaskModal(this.viewModel.model.annualAssessmentID, ASSESSMENT_ENTITY_TYPE_ID, this.taskReadonly || !this.editState.editMode).then(shouldReloadTasks => {\r\n if (shouldReloadTasks) {\r\n this.getTaskSummaries();\r\n this.getAllocationTaskSummaries(); // TODO: feature flag?\r\n this.refreshAssessmentData();\r\n this._navigationEvent.refreshActivityData();\r\n this.editState.refreshGrid = true;\r\n }\r\n });\r\n }\r\n }\r\n\r\n isDeadlineOverridden(): boolean {\r\n return this.viewModel.model &&\r\n (this.viewModel.model.appealDeadline && !this.viewModel.model.originalDeadline ||\r\n (this.viewModel.model.appealDeadline &&\r\n this.viewModel.model.originalDeadline &&\r\n !this.areDeadlinesEqual()));\r\n }\r\n\r\n revertDateCheck(): void {\r\n if (!this.areDeadlinesEqual() && !this.viewModel.model.appealDeadline) {\r\n this.viewModel.model.appealDeadline = this.viewModel.model.originalDeadline;\r\n }\r\n }\r\n\r\n /*updateAction(revision): void {\r\n revision.efAction = revision.efAction === null ? 'update' : revision.efAction\r\n }*/\r\n\r\n readOnly(): boolean {\r\n if (this.viewModel.model === undefined) {\r\n return true;\r\n }\r\n return !this.editState.editMode;\r\n }\r\n\r\n changeActual(): void {\r\n this.viewModel.model.status = this.viewModel.model.status ? 0 : 1;\r\n }\r\n\r\n canEditTable(): boolean {\r\n return this.editState.editMode\r\n && (!this.viewModel.isActual()\r\n || this._isAdjustNoticeReady()\r\n || this._isObtainPostDeterminationReady()\r\n || (this.isDocumentProcessing && this.isIDP))\r\n && !this.viewModel.currentYear.calcProjected;\r\n }\r\n\r\n showComponentDropdown(): boolean {\r\n //Conditions are to show if:\r\n //1) We are in Edit Mode\r\n //2) There are still more components to add\r\n //3) The revision is Not Actual\r\n //4) The revision is Not Auto Calculated\r\n\r\n return !(this.readOnly() ||\r\n this.getUnusedComponentTypes(this.viewModel.model.annualAssessmentDetails).length === 0 ||\r\n (this.viewModel.isActual() && !this._isAdjustNoticeReady()) ||\r\n this.viewModel.currentYear.calcProjected);\r\n }\r\n\r\n //We need better names for this...\r\n calcDisabled(): string {\r\n if (this.disableCalc()) {\r\n return 'disabled';\r\n } else {\r\n return '';\r\n }\r\n }\r\n\r\n //We really need better names for this...\r\n disableCalc(): boolean {\r\n return !this.viewModel.currentYear.calcProjected && _.reject(this.viewModel.currentYear.annualGridDetails, {\r\n revisionDesc: ''\r\n }).length > 1;\r\n }\r\n\r\n //Like, seriously we need better names\r\n someExem(): boolean {\r\n return _.some(this.viewModel.model.annualAssessmentDetails, {\r\n assessmentComponentTypeID: 2\r\n });\r\n }\r\n\r\n getTotal(column, typeIdsToReject: number[]): number {\r\n return this.viewModel.model.annualAssessmentDetails\r\n .filter((component) => {\r\n return !_.includes(typeIdsToReject, component.assessmentComponentTypeID);\r\n })\r\n .reduce((sum, component) => {\r\n if (component.efAction === 'delete') {\r\n return sum;\r\n }\r\n\r\n if (column === 'fairMarketValue') {\r\n return new Decimal(sum).plus(this.getFairMarketValue(component)).toNumber();\r\n } else {\r\n return new Decimal(sum).plus(Number(component[column])).toNumber();\r\n }\r\n }, 0);\r\n }\r\n\r\n getFairMarketValue(component): number {\r\n if (component.fairMarketValue !== undefined) {\r\n const trimmedValue = _.trim(component.fairMarketValue, '#');\r\n return Number(trimmedValue);\r\n }\r\n if (!component.ratio || this.annualDetailsService.parseFMV(component.ratio) === 0) {\r\n return 0;\r\n }\r\n\r\n const parsedAssesedValue: number = this.annualDetailsService.parseFMV(component.assessedValue);\r\n const parsedRatio: number = this.annualDetailsService.parseFMV(component.ratio);\r\n\r\n return new Decimal(parsedAssesedValue).dividedBy(parsedRatio).toNumber();\r\n\r\n }\r\n\r\n areDeadlinesEqual(): boolean {\r\n const appeal = new Date(this.viewModel.model.appealDeadline);\r\n const original = new Date(this.viewModel.model.originalDeadline);\r\n\r\n if (appeal && original) {\r\n return appeal.getFullYear() === original.getFullYear() &&\r\n appeal.getMonth() === original.getMonth() &&\r\n appeal.getDate() === original.getDate();\r\n } else {\r\n return !appeal && !original;\r\n }\r\n }\r\n\r\n reset(annualDetail: AnnualAssessmentDetail): void {\r\n annualDetail.fmvOverridden = false;\r\n this.calculate('', annualDetail, 0);\r\n this.setDirty();\r\n }\r\n\r\n calculate(changed: string, component: AnnualAssessmentDetail, newValue: number = undefined): void {\r\n let allowNegatives: boolean = false;\r\n\r\n //set emitted new value, if applicable. This depends on the changed component type\r\n if (newValue !== undefined) {\r\n if (changed === 'av') {\r\n component.assessedValue = newValue;\r\n } else if (changed === 'fairMarketValue') {\r\n component.fairMarketValue = newValue;\r\n }\r\n }\r\n if (component.assessmentComponentTypeID === 2) {\r\n allowNegatives = true;\r\n\r\n }\r\n\r\n //If we're running calculations, something has changed, so mark it\r\n this.setDirty();\r\n\r\n //Process each of the textboxes separately\r\n switch (changed) {\r\n case 'ratio':\r\n component.displayRatio = component.displayRatio ? component.displayRatio : null;\r\n break;\r\n case 'av':\r\n let assessedValue: string;\r\n\r\n if (component.assessedValue) {\r\n assessedValue = component.assessedValue.toString();\r\n } else {\r\n assessedValue = '0';\r\n }\r\n component.assessedValue = +this.filterNumber(assessedValue, false, allowNegatives);\r\n this._changeDetector.detectChanges();\r\n break;\r\n }\r\n\r\n this.componentRatioChange(component);\r\n\r\n component.efAction = component.efAction === null ? 'update' : component.efAction;\r\n\r\n if (!((component.fairMarketValue && component.fairMarketValue.toString().indexOf('#') !== -1) || component[changed] === '-' || component.fmvOverridden || !component.ratio)) {\r\n\r\n //Process negatives from the exemptions field\r\n if (component.assessmentComponentTypeID === 2) {\r\n if (component.fairMarketValue > 0) {\r\n component.fairMarketValue = -Math.abs(component.fairMarketValue);\r\n }\r\n if (component.assessedValue > 0) {\r\n component.assessedValue = -Math.abs(component.assessedValue);\r\n }\r\n } else {\r\n if (component.fairMarketValue < 0) {\r\n component.fairMarketValue = Math.abs(component.fairMarketValue);\r\n }\r\n if (component.assessedValue < 0) {\r\n component.assessedValue = Math.abs(component.assessedValue);\r\n }\r\n }\r\n\r\n if (changed === 'fairMarketValue') {\r\n component.assessedValue = new Decimal(component.fairMarketValue).times(component.ratio).round().toNumber();\r\n } else {\r\n component.fairMarketValue = new Decimal(component.assessedValue).dividedBy(component.ratio).round().toNumber();\r\n }\r\n\r\n if (this.viewModel) {\r\n this.viewModel.AssessmentChanged = this.AssessmentChanged;\r\n\r\n if (this.AssessmentChanged) {\r\n this._recalculateTaxableValues();\r\n this.AssessmentChanged.emit(this.viewModel.model);\r\n }\r\n }\r\n }\r\n }\r\n\r\n filterNumber(input: string, hash: boolean, negative: boolean): string {\r\n if (input === undefined) {\r\n input = '';\r\n }\r\n let clean;\r\n\r\n if (hash && input[0] === '#') {\r\n clean = input.substring(1);\r\n if (negative && clean[0] === '-') {\r\n clean = `-${ clean.substring(1).replace(/[^0-9]+/g, '')}`;\r\n } else {\r\n clean = clean.replace(/[^0-9]+/g, '');\r\n }\r\n clean = `#${ clean}`;\r\n } else {\r\n if (negative && input[0] === '-') {\r\n clean = `-${ input.substring(1).replace(/[^0-9]+/g, '')}`;\r\n } else {\r\n clean = input.replace(/[^0-9]+/g, '');\r\n }\r\n }\r\n\r\n return clean;\r\n }\r\n\r\n maybeRevertToCalcRatio(component: AnnualAssessmentDetail): void {\r\n if (component.ratio) {\r\n component.displayRatio = +this._decimalPipe.transform(component.displayRatio, '1.3-3');\r\n\r\n this.calculate('ratio', component);\r\n } else {\r\n this.revertToCalcRatio(component);\r\n }\r\n }\r\n\r\n revertToCalcRatio(component: AnnualAssessmentDetail): void {\r\n component.ratio = component.assessmentClassRatio.assessmentRatio;\r\n component.displayRatio = +this._decimalPipe.transform(component.ratio * 100, '1.3-3');\r\n\r\n this.calculate('ratio', component);\r\n }\r\n\r\n undoCalcRatio_Click(component: AnnualAssessmentDetail) {\r\n this.revertToCalcRatio(component);\r\n this.setDirty();\r\n }\r\n\r\n makeOverridden(component): void {\r\n if (component.fairMarketValue[0] === '#') {\r\n component.fairMarketValue = this.annualDetailsService.parseFMV(component.fairMarketValue);\r\n component.fmvOverridden = true;\r\n } else if (!component.fairMarketValue) {\r\n component.fmvOverridden = false;\r\n this.calculate('', component);\r\n } else {\r\n component.fmvOverridden = false;\r\n }\r\n\r\n this.AssessmentChanged.emit(this.viewModel.model);\r\n }\r\n\r\n async addRow(component: any, valuesToAdd?: {fairMarketValue?: number, av?: number, ratio?: number}, assessmentVM?: AssessmentViewModel): Promise {\r\n const vmToUse = assessmentVM ?? this.viewModel\r\n // api/AnnualAssessmentDetail?annualAssessmentID=5202118&assessmentClassComponentID=292&assessmentClassID=8&assessorID=170&annualYear=2016&componentName=Other\r\n const params = {\r\n annualAssessmentID: vmToUse.model.annualAssessmentID,\r\n assessmentClassComponentID: component.assessmentClassComponentID,\r\n assessmentClassID: component.assessmentClassID,\r\n assessorID: vmToUse.assessorID,\r\n annualYear: vmToUse.currentYear.annualYear1,\r\n componentName: component.componentName\r\n };\r\n\r\n this._assessmentService.getAssessmentComponent(params).then((result: AnnualAssessmentDetail) => {\r\n const newComponent: AnnualAssessmentDetail = result;\r\n\r\n if (!newComponent.fairMarketValue) {\r\n newComponent.fairMarketValue = 0;\r\n }\r\n\r\n if (vmToUse.model.annualAssessmentID !== undefined) {\r\n newComponent.annualAssessmentID = vmToUse.model.annualAssessmentID;\r\n }\r\n\r\n newComponent.efAction = 'add';\r\n\r\n // Adding row from Document processing OCR\r\n if(isNumber(valuesToAdd?.fairMarketValue)) {\r\n this.calculate('fairMarketValue', newComponent, valuesToAdd.fairMarketValue)\r\n }\r\n if(isNumber(valuesToAdd?.av)) {\r\n this.calculate('av', newComponent, valuesToAdd.av)\r\n }\r\n if(isNumber(valuesToAdd?.ratio)) {\r\n newComponent.displayRatio = valuesToAdd.ratio\r\n this.calculate('ratio', newComponent)\r\n }\r\n\r\n vmToUse.model.annualAssessmentDetails.push(newComponent);\r\n vmToUse.model.annualAssessmentDetails = this.getSortedAnnualAssessmentDetails();\r\n vmToUse.recalculateVariables();\r\n this.setDirty();\r\n vmToUse.AssessmentChanged = this.AssessmentChanged;\r\n this.AssessmentChanged.emit(vmToUse.model);\r\n });\r\n }\r\n\r\n deleteComponent(component: AnnualAssessmentDetail): void {\r\n _.remove(this.viewModel.model.annualAssessmentDetails, component);\r\n this.setDirty();\r\n this.viewModel.AssessmentChanged = this.AssessmentChanged;\r\n this._recalculateTaxableValues();\r\n this.AssessmentChanged.emit(this.viewModel.model);\r\n this._navigationEvent.refreshActivityData();\r\n }\r\n\r\n deleteAssessment(): void {\r\n let message: string = 'Are you sure you want to delete this assessment?';\r\n\r\n if (this.viewModel.currentYear.annualGridDetails.length === 1) {\r\n message = `WARNING: All related assessment, appeal, tax bill, and compliance information for ${ this.viewModel.currentYear.annualYear1 } will also be deleted!`;\r\n }\r\n\r\n this._messageBox.open({\r\n title: 'WARNING',\r\n message: message,\r\n buttons: MessageBoxButtons.YesNo\r\n }).then((result) => {\r\n switch (result) {\r\n case MessageBoxResult.Yes:\r\n this._assessmentService.deleteAssessment(this.viewModel.model.annualAssessmentID).then(() => {\r\n this.editState.editMode = false;\r\n this.editState.setDirty(false);\r\n this.editState.refreshGrid = true;\r\n this.editState.staleAppealSavings = true;\r\n this._navigationEvent.refreshActivityData();\r\n this.gridNavigationHandler();\r\n });\r\n break;\r\n case MessageBoxResult.No:\r\n break;\r\n }\r\n });\r\n }\r\n\r\n getCommentsModalData(): any {\r\n const parcel = this._currentEntityService.get();\r\n\r\n return {\r\n parcelAcctNum: parcel.name,\r\n parcelID: parcel.id,\r\n entityTypeID: 7,\r\n entityID: this.viewModel.model.annualAssessmentID,\r\n description: `${this.viewModel.currentYear.annualYear1 } - ${ this.viewModel.model.revisionDesc}`,\r\n year: this.viewModel.currentYear.annualYear1,\r\n canEdit: true\r\n };\r\n }\r\n\r\n async autoCalculateRefresh(): Promise {\r\n this.viewModel.dirtyAnnualYear = true;\r\n //if setting autocalculate to true, we must:\r\n //1) Confirm\r\n //2) Save the assessment, to store any name/date changes made\r\n //3) Save the year, which is what triggers the autocalc values to change\r\n //4) Refetch the assessment to get the autocalculated values\r\n if (this.viewModel.currentYear.calcProjected) {\r\n const result = await this._messageBox.open({\r\n title: 'WARNING',\r\n message: 'Enabling auto calculate will force your revision to be saved. Do you wish to continue?',\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n switch (result) {\r\n case MessageBoxResult.Yes:\r\n this.editState.entityLoading = true;\r\n await this._assessmentService.saveAssessmentFromViewModel(this.viewModel);\r\n //this.viewModel.model = result;\r\n this.annualDetailsService.saveYear(this.viewModel.currentYear).then(({rowVersion}: AnnualDetailYear) => {\r\n this.viewModel.currentYear.rowVersion = rowVersion;\r\n if (this.viewModel.currentYear.calcProjected) {\r\n const currentYearCarryover = this.viewModel.currentYear;\r\n this.refreshAssessmentData().then(() => {\r\n this.viewModel.currentYear = currentYearCarryover;\r\n });\r\n }\r\n });\r\n break;\r\n case MessageBoxResult.No:\r\n this.viewModel.currentYear.calcProjected = false;\r\n break;\r\n }\r\n }\r\n //Save the \"auto calculate\" in the year, independent of the assessment\r\n else {\r\n //this.annualDetailsService.saveYear(this.viewModel.currentYear);\r\n this.viewModel.currentYear.calcProjected = false;\r\n this.setDirty();\r\n }\r\n }\r\n\r\n targetValueChanged(): void {\r\n this.viewModel.dirtyTargetValue = true;\r\n }\r\n\r\n onAppealDeadlineChanged(): void {\r\n this.setDirty();\r\n this.editState.staleAppealStatus = true;\r\n this.editState.refreshActivity = true;\r\n this.appealByChanged = true;\r\n }\r\n\r\n setDirty(): void {\r\n this.editState.setDirty(true);\r\n this.editState.staleAppealSavings = true;\r\n this.editState.refreshGrid = true;\r\n }\r\n\r\n blurPopover($event): void {\r\n $event.preventDefault();\r\n $event.target.blur();\r\n }\r\n\r\n getSortedAnnualAssessmentDetails(): AnnualAssessmentDetail[] {\r\n return _.sortBy(this.viewModel.model.annualAssessmentDetails, (component) => { return component.sequence;});\r\n }\r\n\r\n resetAppealDeadline_click(): void {\r\n this.viewModel.model.appealDeadline = this.viewModel.model.originalDeadline;\r\n this.appealByChanged = false;\r\n this.setDirty();\r\n }\r\n\r\n goToAllocation(): void {\r\n this._allocationService.navigationParcelId = this.viewModel.parcelID;\r\n\r\n if (!this.hasAllocation) {\r\n this._createAllocation();\r\n return;\r\n }\r\n\r\n this._navigationService.go('allocationDetails',\r\n {\r\n allocationId: this.viewModel.model.allocationId\r\n });\r\n }\r\n\r\n launchAllocationTaskModal() {\r\n // Determine the annualAssessmentID to use if there are multiple revisions\r\n const annualAssessmentId = this.viewModel.currentYear.annualGridDetails.length > 1\r\n ? this.viewModel.currentYear.annualGridDetails[this.viewModel.currentYear.annualGridDetails.length - 1].annualAssessmentID\r\n : this.viewModel.model.annualAssessmentID;\r\n\r\n // step 1: if dirty and in \"full\" mode aka annual details, save assessment\r\n // step 2: show toast if auto save is successful\r\n // step 3: launch modal\r\n // step 4: on modal close if shouldReloadTasks, refetch assessments\r\n if (this.editState.getDirty() && !this.compactMode) {\r\n this.editState.saveHandler().then(() => {\r\n this.editState.setDirty(false);\r\n this.viewModel.setEditBackup();\r\n this._toastr.info('Assessment Allocations changes autosaved');\r\n this._taskService.launchTaskModal(annualAssessmentId, EntityTypes.AssessmentAllocation, this.taskReadonly || !this.editState.editMode).then(shouldReloadTasks => {\r\n if (shouldReloadTasks) {\r\n this.getAllocationTaskSummaries(); // TODO: feature flag?\r\n this.refreshAssessmentData();\r\n this._navigationEvent.refreshActivityData();\r\n this.editState.setDirty(false);\r\n this.editState.refreshGrid = true;\r\n }\r\n });\r\n });\r\n } else {\r\n this._taskService.launchTaskModal(annualAssessmentId, EntityTypes.AssessmentAllocation, this.taskReadonly || !this.editState.editMode).then(shouldReloadTasks => {\r\n if (shouldReloadTasks) {\r\n this.getAllocationTaskSummaries(); // TODO: feature flag?\r\n this.refreshAssessmentData();\r\n this._navigationEvent.refreshActivityData();\r\n this.editState.refreshGrid = true;\r\n }\r\n });\r\n }\r\n }\r\n\r\n private _isAdjustNoticeReady(): boolean {\r\n return this.taskSummaries && this.taskSummaries.AdjustNoticeIsReady;\r\n }\r\n\r\n private _isObtainPostDeterminationReady(): boolean {\r\n return this.taskSummaries && this.taskSummaries.ObtainPostDeterminationReady;\r\n }\r\n\r\n private async _createAllocation(): Promise {\r\n try {\r\n await this.annualDetailsService.preNavigateWarn(this.editState);\r\n } catch (e) {\r\n return;\r\n }\r\n\r\n const busyMsgId = 'loading';\r\n this._busyIndicatorMsgManager.add('Creating Allocation', busyMsgId);\r\n\r\n try {\r\n const model: Compliance.AllocationCreateModel = {\r\n annualAssessmentId: this.viewModel.model.annualAssessmentID\r\n };\r\n const result = await this._allocationService.createAllocation(this.companyId, model);\r\n this.viewModel.model.allocationId = result.allocationId;\r\n this.hasAllocation = true;\r\n this.goToAllocation();\r\n } finally {\r\n this._busyIndicatorMsgManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n private setVariablesFromViewModel() {\r\n //Set initial revision name for the rename modal radio button list\r\n if ((this.viewModel.model.revisionDesc.toString() == 'Final') || (this.viewModel.model.revisionDesc.toString() == 'Original') || (this.viewModel.model.revisionDesc.toString() == 'Forecast')) {\r\n this.revisionName = this.viewModel.model.revisionDesc;\r\n } else {\r\n this.revisionName = 'Other';\r\n this.revisionOtherName = this.viewModel.model.revisionDesc;\r\n }\r\n\r\n if (!this.viewModel.currentYear && this.currentYear) {\r\n this.viewModel.currentYear = this.currentYear;\r\n }\r\n\r\n this.hasAllocation = !!this.viewModel.model.allocationId;\r\n\r\n this.viewModel.recalculateVariables();\r\n }\r\n\r\n private promptAutoSave(message: string): Promise {\r\n return new Promise((resolve, reject) => {\r\n if (this.editState.getDirty() && !this.compactMode) {\r\n return this._messageBox.open({\r\n title: 'WARNING',\r\n message: message,\r\n buttons: MessageBoxButtons.YesNo\r\n }).then((result) => {\r\n switch (result) {\r\n case MessageBoxResult.Yes:\r\n return this.editState.saveHandler().then(() => {\r\n this.editState.setDirty(false);\r\n this.viewModel.setEditBackup();\r\n this._toastr.success('Successfully saved.');\r\n resolve();\r\n }, () => reject());\r\n\r\n default:\r\n reject();\r\n break;\r\n }\r\n });\r\n }\r\n\r\n resolve();\r\n });\r\n }\r\n\r\n private refreshAssessmentData(): Promise {\r\n return this._assessmentService.getAssessmentViewModelByID(\r\n this.viewModel.model.annualAssessmentID,\r\n this.viewModel.assessorID,\r\n this.viewModel.parcelID,\r\n this.viewModel.parcelAcctNum,\r\n this.viewModel.currentYear)\r\n .then((refreshResult: AssessmentViewModel) => {\r\n _.assign(this.viewModel, refreshResult);\r\n this.setVariablesFromViewModel();\r\n this.editState.entityLoading = false;\r\n this.viewModel.beginEdit();\r\n this.AssessmentChanged.emit(this.viewModel.model);\r\n this._navigationEvent.refreshAnnualYear();\r\n });\r\n }\r\n\r\n private _getUniqueTaxable(totals: Core.AnnualAssessmentTaxableValue[]): Core.AnnualAssessmentTaxableValue[] {\r\n const uniqueTotals = new Map();\r\n\r\n return totals.filter((x: Core.AnnualAssessmentTaxableValue) => {\r\n if (x.assessedValue === 0 && x.fairMarketValue === 0){\r\n return false;\r\n }\r\n\r\n const key = JSON.stringify(x);\r\n if (uniqueTotals.has(key)) {\r\n return false;\r\n }\r\n\r\n uniqueTotals.set(key, x);\r\n return true;\r\n });\r\n }\r\n\r\n private _recalculateTaxableValues() {\r\n if (this.viewTaxableValues) {\r\n const taxableValues: Core.AnnualAssessmentTaxableValue[] = [];\r\n this.viewModel.model.taxAuthoritiesInfo.forEach(x => {\r\n let taxableComponents: AnnualAssessmentDetail[];\r\n\r\n switch (x.taxableAssessmentTypeId) {\r\n case Core.TaxableAssessmentTypeEnum.TotalAV:\r\n taxableComponents = this.viewModel.model.annualAssessmentDetails\r\n .filter(y => y.assessmentComponentTypeID === +AssessmentComponentTypeEnum.Normal);\r\n break;\r\n case Core.TaxableAssessmentTypeEnum.AlternateAV:\r\n taxableComponents = this.viewModel.model.annualAssessmentDetails\r\n .filter(y => y.assessmentComponentTypeID === +AssessmentComponentTypeEnum.Cap);\r\n\r\n if (taxableComponents.length === 0) {\r\n taxableComponents = this.viewModel.model.annualAssessmentDetails\r\n .filter(y => y.assessmentComponentTypeID === +AssessmentComponentTypeEnum.Normal);\r\n }\r\n break;\r\n case Core.TaxableAssessmentTypeEnum.LandOnly:\r\n taxableComponents = this.viewModel.model.annualAssessmentDetails\r\n .filter(y => y.assessmentClassComponent.assessmentComponent.isLandComponent);\r\n break;\r\n case TaxableAssessmentTypeEnum.LowerOfTotalAvAndAlternateAv:\r\n taxableComponents = this.viewModel.model.annualAssessmentDetails\r\n .filter(y => y.assessmentComponentTypeID === +AssessmentComponentTypeEnum.Normal ||\r\n y.assessmentComponentTypeID === +AssessmentComponentTypeEnum.Cap);\r\n break;\r\n }\r\n\r\n const exemptions = this.viewModel.model.annualAssessmentDetails\r\n .filter(y => x.exemptionComponentIds.includes(y.assessmentClassComponent && y.assessmentClassComponent.assessmentComponentID));\r\n\r\n const allComponents = [...taxableComponents, ...exemptions];\r\n\r\n if (x.taxableAssessmentTypeId != TaxableAssessmentTypeEnum.LowerOfTotalAvAndAlternateAv) {\r\n const result = allComponents.reduce((taxableTotal, component) => {\r\n taxableTotal.assessedValue += component.assessedValue;\r\n taxableTotal.fairMarketValue += component.fairMarketValue;\r\n\r\n return taxableTotal;\r\n }, {assessedValue: 0, fairMarketValue: 0} as Core.AnnualAssessmentTaxableValue);\r\n taxableValues.push(result);\r\n } else {\r\n const totalAV = allComponents\r\n .filter(y => y.assessmentComponentTypeID === +AssessmentComponentTypeEnum.Normal)\r\n .reduce((taxableTotal, component) => {\r\n taxableTotal.assessedValue += component.assessedValue;\r\n taxableTotal.fairMarketValue += component.fairMarketValue;\r\n\r\n return taxableTotal;\r\n }, {assessedValue: 0, fairMarketValue: 0} as Core.AnnualAssessmentTaxableValue);\r\n\r\n const alternativeAV = allComponents\r\n .filter(y => y.assessmentComponentTypeID === +AssessmentComponentTypeEnum.Cap)\r\n .reduce((taxableTotal, component) => {\r\n taxableTotal.assessedValue += component.assessedValue;\r\n taxableTotal.fairMarketValue += component.fairMarketValue;\r\n\r\n return taxableTotal;\r\n }, {assessedValue: 0, fairMarketValue: 0} as Core.AnnualAssessmentTaxableValue)\r\n\r\n taxableValues.push(totalAV.assessedValue < alternativeAV.assessedValue ? totalAV : alternativeAV);\r\n }\r\n });\r\n\r\n taxableValues.sort((x, y) => y.assessedValue - x.assessedValue);\r\n this.viewModel.model.taxableValues = this._getUniqueTaxable(taxableValues);\r\n }\r\n }\r\n}\r\n","\r\n\r\n
\r\n
\r\n
\r\n
\r\n

Add Year

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit, ViewChild } from '@angular/core';\r\nimport { ModalDirective } from 'ngx-bootstrap/modal';\r\nimport { AnnualDetailsNavigationEventService } from '../annual-details-event.service';\r\nimport { NavigationState } from '../annual-details-navigation.service';\r\nimport { AnnualDetailsService } from '../annual-details.service';\r\nimport { AnnualDetailYear, AnnualDetailYearList } from '../Annual-Year/annual-year.model';\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'add-year-modal',\r\n templateUrl: './add-annual-year.component.html'\r\n})\r\nexport class AddYearModalComponent implements OnInit {\r\n constructor(private annualDetailsService: AnnualDetailsService,\r\n private navigationEvent: AnnualDetailsNavigationEventService) {\r\n }\r\n\r\n @Input() parcelId: number;\r\n @Input() yearsList: AnnualDetailYearList;\r\n @Input() navigationState: NavigationState;\r\n @ViewChild('addYearModal', { static: true }) addYearModal: ModalDirective;\r\n\r\n //currentYears: any;\r\n selectedYear: number;\r\n years: AnnualDetailYear[];\r\n saveEnabled: boolean = true;\r\n loading: boolean = false;\r\n\r\n\r\n ngOnInit():void {\r\n this.initializeYearData();\r\n }\r\n\r\n showModalInit(): void {\r\n this.initializeYearData();\r\n }\r\n\r\n initializeYearData():void {\r\n this.years = this.yearsList.years;\r\n let currentYears = _.map(this.years, 'annualYear1');\r\n let parcelHasYears = true;\r\n\r\n if (currentYears.length === 0) {\r\n const d = new Date();\r\n currentYears = [d.getFullYear()];\r\n\r\n parcelHasYears = false;\r\n }\r\n\r\n const latestYear = _.maxBy(currentYears);\r\n const earliestYear = _.minBy(currentYears);\r\n const yearsArray = _.range(earliestYear - 5, latestYear + 5);\r\n\r\n // this.yearsList.options = _.filter(yearsArray, (element) => {\r\n // return currentYears.indexOf(element) < 0; // || !this.parcelHasYears;\r\n // });\r\n\r\n yearsArray.sort();\r\n yearsArray.reverse();\r\n\r\n this.yearsList.options = _.map(yearsArray, function(year) {\r\n return {\r\n year: year,\r\n disabled: _.includes(currentYears, year) && parcelHasYears\r\n };\r\n });\r\n\r\n this.selectedYear = parcelHasYears ? latestYear + 1 : new Date().getFullYear();\r\n }\r\n\r\n async save(): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n this.saveEnabled = false;\r\n await this.annualDetailsService.addYear(this.parcelId, this.selectedYear, true);\r\n //this instead of refreshGrid because the add years is acceesible ON the grid\r\n this.navigationState.resetYearsHandler();\r\n this.addYearModal.hide();\r\n // Update parcel activity panel\r\n this.navigationEvent.refreshActivityData();\r\n this.saveEnabled = true;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n cancel(): void {\r\n return null;\r\n }\r\n}\r\n"," 0\">\r\n\r\n
\r\n

\r\n Begin Preparation\r\n

\r\n \r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n Select a prior return to use as the basis for calculations such as additions and disposals.\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { ComplianceService } from '../compliance.service';\r\n\r\nexport interface ComplianceReturnAddOutputParameters {\r\n filingBatchId: number;\r\n companyId: number;\r\n}\r\n\r\n@Component({\r\n templateUrl: './return-add.component.html',\r\n selector: 'compliance-return-add'\r\n})\r\nexport class ComplianceReturnAddComponent implements OnInit {\r\n constructor(\r\n private readonly _complianceService: ComplianceService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n filingId: number;\r\n result: ComplianceReturnAddOutputParameters;\r\n priorFilings: Compliance.FilingModel[];\r\n priorFiling: Compliance.FilingModel = null;\r\n isAmendment: boolean = false;\r\n isInitialized: boolean = false;\r\n priorReturnSelected: boolean;\r\n\r\n async ngOnInit(): Promise {\r\n const busyMsgId = 'loading';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsgId);\r\n\r\n try {\r\n // in case the filing batch has already been created close\r\n const filing = await this._complianceService.getFiling(this.filingId);\r\n if (filing.filingBatchId) {\r\n this.result = {\r\n filingBatchId: filing.filingBatchId,\r\n companyId: filing.topLevelCompanyId\r\n };\r\n this._bsModalRef.hide();\r\n }\r\n\r\n this.priorFilings = await this._complianceService.getAvailablePriorFilings(this.filingId);\r\n this.priorFiling = (this.priorFilings && this.priorFilings.length) ? this.priorFilings[0] : null;\r\n this.priorReturnSelected = this.priorFiling !== null;\r\n this.isAmendment = this.priorFiling ? this.priorFiling.isAmendment : false;\r\n this.isInitialized = true;\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgId = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgId);\r\n\r\n const updateModel: Compliance.FilingReturnUpdateModel = {\r\n filingId: this.filingId,\r\n priorReturnId: this.priorFiling && this.priorFiling.returnId,\r\n isAmendment: this.isAmendment\r\n };\r\n\r\n try {\r\n const filingBatch = await this._complianceService.createFilingBatch(updateModel);\r\n this.result = {\r\n filingBatchId: filingBatch.filingBatchId,\r\n companyId: filingBatch.companyId\r\n };\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n priorReturnChanged(): void {\r\n this.priorReturnSelected = this.priorFiling !== null;\r\n\r\n if(!this.priorReturnSelected) {\r\n this.isAmendment = false;\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { firstValueFrom, lastValueFrom, Subject } from 'rxjs';\r\nimport { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { ClientServiceType } from '../constants.new';\r\nimport * as _ from 'lodash';\r\nimport { ClientServicesPanelData } from './clientServices.model';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class ClientServiceResponsibilityService {\r\n constructor(private readonly _httpClient: HttpClient) { }\r\n\r\n private _clientServicesChangedSubject: Subject = new Subject();\r\n\r\n get clientServicesChange$() {\r\n return this._clientServicesChangedSubject.asObservable();\r\n }\r\n\r\n notifyClientServicesChange() {\r\n this._clientServicesChangedSubject.next();\r\n }\r\n\r\n getByEntity(entity): Promise {\r\n const params = new HttpParams()\r\n .set('entityID', entity.id)\r\n .set('entityType', entity.type);\r\n\r\n return lastValueFrom(this._httpClient.get('/api/ClientServiceResponsibility', { params: params })) as Promise;\r\n }\r\n\r\n getAll(): Promise {\r\n return lastValueFrom(this._httpClient.get('/api/clientservice'));\r\n }\r\n\r\n async getHasComplianceResponsibility(entityID: number, entityTypeID: number): Promise {\r\n const params = new HttpParams()\r\n .set('entityID', entityID.toString())\r\n .set('entityTypeID', entityTypeID.toString());\r\n\r\n const services = await lastValueFrom(this._httpClient.get('/api/clientserviceresponsibility/clientservices', { params: params }));\r\n\r\n const complianceService = _.find(services, (x: any) => x.clientServiceID === ClientServiceType.ComplianceReturns ||\r\n x.clientServiceID === ClientServiceType.Freeport ||\r\n x.clientServiceID === ClientServiceType.Abatement ||\r\n x.clientServiceID === ClientServiceType.PollutionControl);\r\n\r\n return complianceService ? true : false;\r\n }\r\n\r\n async saveEntity(data: any): Promise {\r\n const result = await lastValueFrom(this._httpClient.put('/api/ClientServiceResponsibility', data));\r\n this._clientServicesChangedSubject.next();\r\n return result;\r\n }\r\n\r\n getAvailableTransmittalFormats(entityTypeId: number, entityId: number): Promise<{ transmittalFormatID: number, name: string }[]> {\r\n return lastValueFrom(this._httpClient.get<{ transmittalFormatID: number, name: string }[]>(\r\n `api/PaymentPackage/TransmittalFormats/EntityType/${entityTypeId}/Entity/${entityId}`\r\n ));\r\n }\r\n\r\n getAvailableFeedSpecs(entityTypeId: number, entityId: number): Promise {\r\n return lastValueFrom(this._httpClient.get(`api/ClientServiceResponsibility/feedspecifications/EntityType/${entityTypeId}/Entity/${entityId}`));\r\n }\r\n\r\n //todo: refactor from this service as it doesn't appear to be related to CSR\r\n getPackageEmailTemplates(entityTypeId: number, entityId: number): Promise {\r\n return lastValueFrom(this._httpClient.get(`api/PaymentPackage/PackageEmailTemplates/EntityType/${entityTypeId}/Entity/${entityId}`));\r\n }\r\n\r\n getTopLevelPropertyTypes(entityId: number, entityTypeId: number): Promise {\r\n return lastValueFrom(this._httpClient.get(`/api/ClientServiceResponsibility/propertytypes/${entityId}/${entityTypeId}`)) as Promise;\r\n }\r\n\r\n getPackageCovers(): Promise {\r\n return lastValueFrom(this._httpClient.get('/api/PaymentPackage/transmittalPackageCovers')) as Promise;\r\n }\r\n\r\n retryWorkflowUpdateFromQueue(req:{entityTypeId: number, entityId: number, clientServiceId: number, propertyTypeId: number}): Promise {\r\n const params = new HttpParams()\r\n .set('entityTypeId', req.entityTypeId)\r\n .set('entityId', req.entityId)\r\n .set('clientServiceId', req.clientServiceId)\r\n .set('propertyTypeId', req.propertyTypeId);\r\n return firstValueFrom(this._httpClient.put('/api/clientserviceresponsibility/retry', {}, {params})).then(x => {\r\n this._clientServicesChangedSubject.next();\r\n return x;\r\n });\r\n }\r\n\r\n doesEntityHaveErrantResponsibilities(req:{entityTypeId, entityId: number}): Promise {\r\n const params = new HttpParams()\r\n .set('entityTypeId', req.entityTypeId)\r\n .set('entityId', req.entityId);\r\n return firstValueFrom(this._httpClient.get('/api/clientserviceresponsibility/anyerrant', {params}));\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { FilingBatchRepository } from '../Repositories/filingBatch.repository';\r\nimport { Subject , Observable , Subscription, lastValueFrom } from 'rxjs';\r\nimport { WebsocketListenerService } from '../websocketListener.service';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { IExpandableComponentContainer, } from '../../UI-Lib/Expandable-Component/expandableComponentContainer.model';\r\nimport { IExpandableComponent } from '../../UI-Lib/Expandable-Component/expandableComponent.model';\r\n\r\n@Injectable()\r\nexport class FilingBatchService implements IExpandableComponentContainer {\r\n constructor(\r\n private readonly _filingBatchRepository: FilingBatchRepository,\r\n private readonly _websocketListenerService: WebsocketListenerService,\r\n private readonly _taskService: TaskService\r\n ) { }\r\n\r\n private _filingBatchStatusChangeSub: Subscription;\r\n private _filingBatchSubject = new Subject();\r\n private _filingBatchId: number;\r\n private _expandedComponent: IExpandableComponent = null;\r\n\r\n get editGroup(): string {\r\n return 'filing-batch';\r\n }\r\n\r\n get filingBatchChange$(): Observable {\r\n return this._filingBatchSubject.asObservable();\r\n }\r\n\r\n async start(filingBatchId: number): Promise {\r\n this._filingBatchId = filingBatchId;\r\n this._filingBatchStatusChangeSub = this._websocketListenerService.longRunningProcessStatusChange$.subscribe(\r\n x => {\r\n if (x.processType === Compliance.LongRunningProcessTypeEnum.Return && this._filingBatchId === x.entityId) {\r\n this.notifyFilingBatchStatusChange(x);\r\n }\r\n });\r\n }\r\n\r\n stop(): void {\r\n this._filingBatchStatusChangeSub && this._filingBatchStatusChangeSub.unsubscribe();\r\n }\r\n\r\n isNotStarted(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus === Compliance.FilingBatchProcessStatusEnum.NotStarted; }\r\n isStarted(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus === Compliance.FilingBatchProcessStatusEnum.Started; }\r\n isLocked(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus === Compliance.FilingBatchProcessStatusEnum.Locked; }\r\n isLocking(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus === Compliance.FilingBatchProcessStatusEnum.Locking; }\r\n isUnlocking(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus === Compliance.FilingBatchProcessStatusEnum.Unlocking; }\r\n isFinalizing(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus === Compliance.FilingBatchProcessStatusEnum.Finalizing; }\r\n isFinalized(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus === Compliance.FilingBatchProcessStatusEnum.Finalized; }\r\n isSigned(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus === Compliance.FilingBatchProcessStatusEnum.Signed; }\r\n isSigning(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus === Compliance.FilingBatchProcessStatusEnum.Signing; }\r\n isUnsigning(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus === Compliance.FilingBatchProcessStatusEnum.Unsigning; }\r\n isReadOnly(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean { return processStatus !== Compliance.FilingBatchProcessStatusEnum.NotStarted && processStatus !== Compliance.FilingBatchProcessStatusEnum.Started; }\r\n isLongRunningProcessActive(processStatus: Compliance.FilingBatchProcessStatusEnum): boolean {\r\n return processStatus === Compliance.FilingBatchProcessStatusEnum.Locking ||\r\n processStatus === Compliance.FilingBatchProcessStatusEnum.Unlocking ||\r\n processStatus === Compliance.FilingBatchProcessStatusEnum.Signing ||\r\n processStatus === Compliance.FilingBatchProcessStatusEnum.Unsigning ||\r\n processStatus === Compliance.FilingBatchProcessStatusEnum.Finalizing;\r\n }\r\n\r\n hasLockError(filingBatch: Compliance.FilingBatchModel) {\r\n return filingBatch && filingBatch.longRunningProcessError && filingBatch.processStatus === Compliance.FilingBatchProcessStatusEnum.Started;\r\n }\r\n\r\n hasFinalizeError(filingBatch: Compliance.FilingBatchModel) {\r\n return filingBatch && filingBatch.longRunningProcessError && filingBatch.processStatus === Compliance.FilingBatchProcessStatusEnum.Locked;\r\n }\r\n\r\n getProgressStatusDisplay(processStatus: Compliance.FilingBatchProcessStatusEnum): string {\r\n switch (processStatus) {\r\n case Compliance.FilingBatchProcessStatusEnum.NotStarted: return 'Not started';\r\n case Compliance.FilingBatchProcessStatusEnum.Started: return 'Started';\r\n case Compliance.FilingBatchProcessStatusEnum.Finalizing: return 'Finalizing';\r\n case Compliance.FilingBatchProcessStatusEnum.Finalized: return 'Finalized';\r\n case Compliance.FilingBatchProcessStatusEnum.Locking: return 'Locking';\r\n case Compliance.FilingBatchProcessStatusEnum.Locked: return 'Locked';\r\n case Compliance.FilingBatchProcessStatusEnum.Unlocking: return 'Unlocking';\r\n case Compliance.FilingBatchProcessStatusEnum.Signing: return 'Signing';\r\n case Compliance.FilingBatchProcessStatusEnum.Unsigning: return 'Unsigning';\r\n case Compliance.FilingBatchProcessStatusEnum.Signed: return 'Signed';\r\n default: return '';\r\n }\r\n }\r\n\r\n async notifyFilingBatchFilingsChange(filingBatchId: number): Promise {\r\n const filingBatch = await lastValueFrom(this._filingBatchRepository.get(filingBatchId));\r\n this._filingBatchSubject.next(filingBatch);\r\n }\r\n\r\n /**\r\n * Notifies all subscribers listening for filingBatch changes that the filing batch has changed.\r\n * Fetches and provides the most up-to-date data for the filing batch.\r\n * @param filingBatchId The ID of the filing batch.\r\n */\r\n async notifyFilingBatchStatusChange(statusChange: Compliance.LongRunningProcessStatusChangeModel): Promise {\r\n const filingBatch = await lastValueFrom(this._filingBatchRepository.get(statusChange.entityId));\r\n this._filingBatchSubject.next(filingBatch);\r\n }\r\n\r\n async viewTasks(filingBatch: Compliance.FilingBatchModel, editMode: boolean = false): Promise {\r\n const entityId = filingBatch.filingBatchId;\r\n\r\n const entityType = Core.EntityTypes.FilingBatch;\r\n\r\n const updated = await this._taskService.launchTaskModal(entityId, entityType, (!editMode) || this.isReadOnly(filingBatch.processStatus));\r\n if (!updated) {\r\n return;\r\n }\r\n\r\n const filingBatchUpdate = await lastValueFrom(this._filingBatchRepository.get(filingBatch.filingBatchId));\r\n\r\n this._filingBatchSubject.next(filingBatchUpdate);\r\n }\r\n\r\n async getListByAvailableToMoveFilings(filingIds: number[]): Promise {\r\n return await lastValueFrom(this._filingBatchRepository.getListByAvailableToMoveFilingsToAsync(this._filingBatchId, filingIds));\r\n }\r\n\r\n async nextYearInfo(): Promise {\r\n return await lastValueFrom(this._filingBatchRepository.getNextYearInfo(this._filingBatchId));\r\n }\r\n\r\n async moveFilings(moveModel: Compliance.FilingBatchFilingsMoveModel): Promise {\r\n return await lastValueFrom(this._filingBatchRepository.moveFilings(this._filingBatchId, moveModel));\r\n }\r\n\r\n async amendFilings(amendModel: Compliance.FilingBatchFilingsAmendModel): Promise {\r\n return await lastValueFrom(this._filingBatchRepository.amendFilings(this._filingBatchId, amendModel));\r\n }\r\n\r\n setExpandedComponent(component: IExpandableComponent): void {\r\n this._expandedComponent = component;\r\n }\r\n\r\n isComponentExpanded(component: IExpandableComponent): boolean {\r\n return this._expandedComponent === component;\r\n }\r\n\r\n isExpanded(componentName: string): boolean {\r\n return this._expandedComponent && (this._expandedComponent.getName() === componentName);\r\n }\r\n\r\n isOtherComponentExpanded(componentName: string): boolean {\r\n return this._expandedComponent && (this._expandedComponent.getName() !== componentName);\r\n }\r\n\r\n async getInfo(filingBatchId: number): Promise {\r\n return lastValueFrom(this._filingBatchRepository.getInfo(filingBatchId));\r\n }\r\n}\r\n","export class Filing {\r\n filingTypeId: number;\r\n filingId: number;\r\n annualYearID: number;\r\n description: string;\r\n dueDate: Date;\r\n value: number;\r\n filingType: FilingType;\r\n filingDeadline: Date;\r\n rowVersion: any;\r\n filingBatchId?: number;\r\n reportedCost: number;\r\n isFromConsolidatedParcel: boolean;\r\n filingBatch?: Compliance.FilingBatchModel;\r\n allocatedReportedValue?: number;\r\n allocatedReportedCost?: number;\r\n allocation: Compliance.AllocationModel;\r\n assessorName: string;\r\n}\r\n\r\nexport class FilingType {\r\n filingTypeAppId: number;\r\n filingTypeId: number;\r\n filingTypeName: string;\r\n name: string;\r\n sequence: number;\r\n}\r\n\r\nexport class FilingTypeSummary {\r\n allTasksCompleted: boolean;\r\n dueDate: string;\r\n filingHasTaskSeries: boolean;\r\n filingTypeId: number;\r\n isFromConsolidatedParcel: boolean;\r\n isMissing: boolean;\r\n moreThanOneFilingOfThisType: boolean;\r\n value: number;\r\n filingTypeName: string;\r\n filingTypeSequence: number;\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n

New Compliance Filing

\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, Output, ViewChild } from '@angular/core';\r\nimport { ModalDirective } from 'ngx-bootstrap/modal';\r\nimport { Filing, FilingType } from '../Compliance/compliance.model';\r\nimport { ComplianceService } from '../Compliance/compliance.service';\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'add-filing-modal',\r\n templateUrl: './add-filing.component.html'\r\n})\r\nexport class AddFilingModalComponent {\r\n constructor(private complianceService: ComplianceService) {\r\n this.addFiling = new EventEmitter();\r\n }\r\n @Input() filingTypes: FilingType[];\r\n @Input() annualYearID: number;\r\n @Input() isMergedParcel: boolean;\r\n @Output('add') addFiling: EventEmitter;\r\n @ViewChild('addFilingModal', { static: true }) addFilingModal: ModalDirective;\r\n\r\n newFiling: Filing;\r\n\r\n filingTypesDropdown: FilingType[];\r\n creatingFiling: boolean = false;\r\n\r\n\r\n show(): void {\r\n this.addFilingModal.show();\r\n }\r\n\r\n showModalInit(): void {\r\n this.filingTypesDropdown = _.reject(this.filingTypes, x => x.filingTypeId == Core.FilingTypes.PPReturn && this.isMergedParcel);\r\n this.newFiling = new Filing();\r\n this.newFiling.annualYearID = this.annualYearID;\r\n this.newFiling.filingTypeId = this.filingTypesDropdown[0].filingTypeId;\r\n }\r\n\r\n save(): void {\r\n this.creatingFiling = true;\r\n this.complianceService.createFiling(this.newFiling)\r\n .then((filing) => {\r\n filing.filingType = _.find(this.filingTypesDropdown, { filingTypeId: filing.filingTypeId });\r\n this.addFiling.emit(filing);\r\n this.addFilingModal.hide();\r\n })\r\n .finally(() => {\r\n this.creatingFiling = false;\r\n });\r\n }\r\n}\r\n"," 0\">\r\n
\r\n \r\n \r\n
\r\n
\r\n There are presently no compliance filings for {{ currentYear.annualYear1 }}.\r\n
\r\n \r\n
\r\n \r\n 0 && viewModel.showTabs\" #filingTabs>\r\n \r\n \r\n \r\n \r\n \r\n {{ getFilingHeading(filing) }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Filing Type:\r\n {{ filing.filingType.name }}\r\n
Description:\r\n {{ filing.description }}\r\n \r\n
Due Date:\r\n \r\n \r\n \r\n
Batch Due Date:\r\n {{ filing.filingBatch.dueDate | weissmanDateFormat: true }}\r\n
Reported Cost (Merged):\r\n ${{(filing.mergedReportedCost || 0) | number: '1.0-0'}}\r\n
Filed Value (Merged):\r\n ${{(filing.mergedReportedValue || 0) | number: '1.0-0'}}\r\n
Reported Cost:\r\n ${{ (filing.reportedCost || 0) | number: '1.0-0'}}\r\n \r\n
Filed Value:\r\n ${{ (filing.value || 0) | number: '1.0-0'}}\r\n \r\n
Status:\r\n
\r\n \r\n \r\n {{ viewModel.currentTaskSummary.Status }}\r\n \r\n {{ viewModel.currentTaskSummary.CompletedDateTime | weissmanDateFormat: true: \"Central\" }}\r\n \r\n \r\n
\r\n\r\n
\r\n N/A - No Responsibility\r\n
\r\n
Consolidated Filing:\r\n {{ getFilingHeading(filing) }}\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, Input, OnChanges, SimpleChange, SimpleChanges, ViewChild } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { TabsetComponent } from 'ngx-bootstrap/tabs';\r\nimport { TooltipDirective } from 'ngx-bootstrap/tooltip';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { WeissmanDatetimeComponent } from '../../UI-Lib/Weiss-Datepicker/weissman-datetime.component';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { AnnualDetailsNavigationEventService } from '../annual-details-event.service';\r\nimport { AnnualDetailEditState } from '../annual-details-navigation.service';\r\nimport { AnnualDetailsService } from '../annual-details.service';\r\nimport { AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { AddFilingModalComponent } from '../Modals/add-filing.component';\r\nimport { Filing, FilingType } from './compliance.model';\r\nimport { ComplianceService, ComplianceViewModel } from './compliance.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { ComplianceReturnAddComponent, ComplianceReturnAddOutputParameters } from './Return-Add/return-add.component';\r\nimport { BsModalService, BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { FilingBatchService } from '../../Compliance/Filing-Batch/filingBatch.service';\r\nimport { BusyIndicatorMessageManager } from '../../Busy-Indicator';\r\nimport { ClientServiceResponsibilityService } from '../../Client-Services/clientServiceResponsibility.service';\r\nimport { InstanceRights, RestrictService } from '../../Common/Permissions/restrict.service';\r\nimport { InstanceRepository } from '../../Entity/Instance/instance.repository';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\n\r\nimport * as _ from 'lodash';\r\n\r\ninterface ComponentChanges extends SimpleChanges {\r\n viewModel: SimpleChange;\r\n filingTypes: SimpleChange;\r\n}\r\n\r\n@Component({\r\n selector: 'compliance',\r\n templateUrl: './compliance.component.html',\r\n styleUrls: ['./compliance.component.scss']\r\n})\r\nexport class ComplianceComponent implements OnChanges {\r\n constructor(\r\n public readonly toastr: ToastrService,\r\n private readonly _complianceService: ComplianceService,\r\n private readonly _annualDetailsService: AnnualDetailsService,\r\n private readonly _taskService: TaskService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _navigationEvent: AnnualDetailsNavigationEventService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _modalService: BsModalService,\r\n private readonly _wsModalService: WeissmanModalService,\r\n private readonly _clientResponsibilityService: ClientServiceResponsibilityService,\r\n private readonly _filingBatchService: FilingBatchService,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) { }\r\n\r\n @Input() filingTypes: FilingType[];\r\n @Input() viewModel: ComplianceViewModel;\r\n @Input() currentYear: AnnualDetailYear;\r\n @Input() editState: AnnualDetailEditState;\r\n @Input() taskReadonly: boolean = false;\r\n @Input() hideDelete: boolean = false;\r\n @Input() companyId: number;\r\n @Input() topLevelCompanyId: number;\r\n @Input() returnPreparationAllowed: boolean;\r\n @Input() isDocumentProcessing: boolean = false;\r\n @ViewChild('filingTabs') filingTabs: TabsetComponent;\r\n @ViewChild('AddFilingModal') addFilingModal: AddFilingModalComponent;\r\n @ViewChild('dueDate') dueDateElement: WeissmanDatetimeComponent;\r\n @ViewChild('filingTaskValidation') filingTaskValidation: TooltipDirective;\r\n\r\n isLoading: boolean = false;\r\n filingEntityTypeId: number = Core.EntityTypes.Filing;\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n private _hasAssignee: boolean;\r\n private _hasComplianceFeaturesView: boolean;\r\n\r\n get canCreateFilingBatch(): boolean {\r\n return (!this.editState.editMode) && // not in edit mode\r\n this._hasComplianceFeaturesView &&\r\n this._hasAssignee && // Compliance return responsibility is not N/A\r\n this.viewModel &&\r\n this.viewModel.currentFiling &&\r\n this.viewModel.currentFiling.filingTypeId === Core.FilingTypes.PPReturn && // for now, only PP returns get batches\r\n this.returnPreparationAllowed && // prepare pp returns on\r\n (this.viewModel.consolidatedParcelId === this.viewModel.parcelID || this.viewModel.consolidatingTypeId === Core.ConsolidatingTypeEnum.None || (!this.viewModel.consolidatedParcelId)) && // only consolidated parcel, opt out parcel or no consolidation can create batch\r\n (!this.viewModel.currentFiling.isFromConsolidatedParcel) && // phantom filing from consolidated parcel\r\n (!this.viewModel.currentFiling.filingBatchId) && // already in a batch\r\n this.viewModel.currentTaskSummary && // make sure there is a current task summary status\r\n !this.viewModel.currentTaskSummary.SeriesIsComplete; // already filed (outside the system)\r\n\r\n }\r\n\r\n get isMergedParcel(): boolean {\r\n return !this.viewModel.consolidatingTypeId && !!this.viewModel.consolidatedParcelId;\r\n }\r\n\r\n async ngOnChanges(changes: ComponentChanges): Promise {\r\n if (this.viewModel) {\r\n const responsibility = await this._clientResponsibilityService.getByEntity({\r\n id: this.viewModel.parcelID,\r\n type: 'parcel'\r\n });\r\n if (responsibility.entityClientServices && responsibility.entityClientServices.length) {\r\n this._hasAssignee = responsibility.entityClientServices.some(x => {\r\n return x.clientServiceID === 1 && !x.responsibilities.some(y => y.workflowUserTypeID === 0);\r\n });\r\n }\r\n\r\n this.editState.showEditControls = this.viewModel && this.viewModel.model.length > 0;\r\n\r\n this.viewModel.hasWritePermission = this.editState.hasWritePermission;\r\n this.viewModel.updateModalData();\r\n this.viewModel.resetDateTimeHandler = () => {\r\n if (this.dueDateElement) {\r\n this.dueDateElement.resetValidation();\r\n }\r\n };\r\n\r\n if (this.viewModel.defaultFilingId) {\r\n this._complianceService.setCurrentFiling(this.viewModel, this.viewModel.defaultFilingId);\r\n }\r\n\r\n const instanceId = await lastValueFrom(this._instanceRepository.getEntityInstanceId('company', this.companyId));\r\n this._hasComplianceFeaturesView = this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, instanceId);\r\n }\r\n }\r\n\r\n getReturnStatusCode(filing: Filing): string {\r\n return this._complianceService.getReturnStatusCode(filing);\r\n }\r\n\r\n async createFilingBatch(filing: Filing): Promise {\r\n try {\r\n await this._annualDetailsService.preNavigateWarn(this.editState);\r\n } catch (e) {\r\n return;\r\n }\r\n\r\n let result: ComplianceReturnAddOutputParameters;\r\n\r\n if (filing.filingBatchId) {\r\n result = {\r\n filingBatchId: filing.filingBatchId,\r\n companyId: this.topLevelCompanyId\r\n };\r\n } else {\r\n const showModalFn = (): BsModalRef => {\r\n return this._modalService.show(ComplianceReturnAddComponent, {\r\n class: 'modal-md',\r\n initialState: {\r\n filingId: filing.filingId\r\n }\r\n });\r\n };\r\n\r\n const bsModalRef = await this._wsModalService.show(showModalFn.bind(this)).whenClosed;\r\n result = (bsModalRef.content as ComplianceReturnAddComponent).result;\r\n }\r\n\r\n if (!result) {\r\n return;\r\n }\r\n\r\n this._upgradeNavigationServiceHandler.go('returnFilingBatchPage',\r\n {\r\n 'filingBatchId': result.filingBatchId\r\n });\r\n }\r\n\r\n isFinalized(filing: Filing): boolean {\r\n if (!filing.filingBatch) {\r\n return false;\r\n }\r\n\r\n return this._filingBatchService.isFinalized(filing.filingBatch.processStatus);\r\n }\r\n\r\n getFilingHeading(filing: Filing): string {\r\n return `${filing.description} ${filing.filingType.name}`;\r\n }\r\n\r\n getFilingBatchPrepareLabel(filing: Filing): string {\r\n if (this._filingBatchService.isReadOnly(filing.filingBatch.processStatus)) {\r\n return 'View Returns';\r\n }\r\n\r\n if (this._filingBatchService.isStarted(filing.filingBatch.processStatus)) {\r\n return 'Continue Preparation';\r\n }\r\n\r\n return 'Begin Preparation';\r\n }\r\n\r\n launchTaskModal(filing: Filing): void {\r\n if (filing.isFromConsolidatedParcel || filing.filingBatch || (!this.editState.editMode) || (!this.editState.getDirty()) || this.taskReadonly) {\r\n const entityId = this._complianceService.getTaskEntityId(filing);\r\n const entityType = this._complianceService.getTaskEntityType(filing);\r\n\r\n this._taskService.launchTaskModal(entityId, entityType, filing.isFromConsolidatedParcel || filing.filingBatch ? true : false || !this.editState.editMode || this.taskReadonly)\r\n .then((shouldReload) => {\r\n this._afterTaskModalClose(shouldReload);\r\n });\r\n // This branch will never execute based on the above conditions.\r\n // Leaving in for posterity\r\n // } else if (this.editState.editMode && !this.editState.getDirty()) {\r\n // this._taskService.launchTaskModal(filing.filingId, Core.EntityTypes.Filing, false)\r\n // .then((shouldReload) => {\r\n // this._afterTaskModalClose(shouldReload);\r\n // });\r\n } else {\r\n this.editState.validationHandler((isValid, errorMessage) => {\r\n if (!isValid) {\r\n this.editState.validationMessage = errorMessage;\r\n\r\n // HACK need setTimeout for some reason as when the 'show'\r\n // is called the validationMessage is not set unless we have the timeout\r\n setTimeout(() => {\r\n // TODO this validation tooltip is not available in the\r\n // annual details service. Need to figure out how to set it\r\n //\r\n // editState.aDValidation.show();\r\n //\r\n // For now, console.warn:\r\n this.toastr.error(errorMessage);\r\n });\r\n return;\r\n }\r\n\r\n this.editState.saveHandler().then(() => {\r\n this.toastr.info('Filing changes autosaved');\r\n this.editState.setDirty(false);\r\n this.viewModel.resetEdit(true);\r\n\r\n this._taskService.launchTaskModal(filing.filingId, Core.EntityTypes.Filing, false)\r\n .then((shouldReload) => {\r\n this._afterTaskModalClose(shouldReload);\r\n });\r\n });\r\n });\r\n }\r\n }\r\n\r\n async openAddFiling(): Promise {\r\n try {\r\n await this._annualDetailsService.preNavigateWarn(this.editState);\r\n\r\n this.addFilingModal.show();\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n async addFiling(newFiling: any): Promise {\r\n newFiling = newFiling as Filing;\r\n\r\n this.isLoading = true;\r\n\r\n try {\r\n await this._complianceService.addNewFilingToViewModel(this.viewModel, newFiling);\r\n\r\n this.editState.refreshGrid = true;\r\n this._navigationEvent.refreshActivityData();\r\n\r\n // If we're adding the first appeal for this year, showEditControls will be false\r\n // when the component is loaded; reset to true now that we have an appeal to edit\r\n this.editState.showEditControls = true;\r\n\r\n if (!this.editState.editMode) {\r\n // We normally would be worried about isDirty here, but the preNavigationWarn call\r\n // on the button event should ensure that we can't get here from a dirty form\r\n this.editState.setEditMode(true);\r\n }\r\n } finally {\r\n this.isLoading = false;\r\n }\r\n }\r\n\r\n async switchTabs(i: number): Promise {\r\n // For posterity; here's how you'd \"cancel\" selecting a tab:\r\n /*\r\n // Allow tab control to \"breathe\" before cancelling the navigate event and going\r\n // back to the previously selected tab\r\n setTimeout(() => {\r\n this.filingTabs.tabs.forEach((t, index) => {\r\n t.active = index === this.viewModel.currentFilingIndex;\r\n });\r\n this.newAppeal();\r\n }, 1);\r\n */\r\n\r\n if (i !== this.viewModel.currentFilingIndex) {\r\n try {\r\n await this._annualDetailsService.preNavigateWarn(this.editState);\r\n } catch (e) {\r\n this.filingTabs.tabs.forEach((t, index) => {\r\n t.active = index === this.viewModel.currentFilingIndex;\r\n });\r\n\r\n return;\r\n }\r\n\r\n this.isLoading = true;\r\n try {\r\n await this._complianceService.setFilingIndex(this.viewModel, i);\r\n } finally {\r\n this.isLoading = false;\r\n }\r\n }\r\n }\r\n\r\n onDueDateValidationChange(validationMessage): void {\r\n this.viewModel.dueDateValid = !validationMessage;\r\n }\r\n\r\n setDirty(): void {\r\n this.editState.setDirty(true);\r\n this.editState.refreshGrid = true;\r\n }\r\n\r\n onTaskRelevantFieldChanged(): void {\r\n this.editState.setDirty(true);\r\n this.editState.refreshActivity = true;\r\n }\r\n\r\n dueDateOverridden(filing): boolean {\r\n if (!filing.dueDate || !filing.filingDeadline) {\r\n return false;\r\n }\r\n\r\n return new Date(filing.dueDate).getTime() !== new Date(filing.filingDeadline).getTime();\r\n }\r\n\r\n revertDateCheck(filing): void {\r\n if (!filing.dueDate) {\r\n filing.dueDate = filing.filingDeadline;\r\n }\r\n }\r\n\r\n resetDueDate(filing): void {\r\n filing.dueDate = filing.filingDeadline;\r\n this.onTaskRelevantFieldChanged();\r\n this.setDirty();\r\n }\r\n\r\n async deleteFiling(filing: Filing): Promise {\r\n try {\r\n await this._messageBoxService.confirm(`Are you sure you want to delete ${this.getFilingHeading(filing)}?`);\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.isLoading = true;\r\n\r\n try {\r\n await this._complianceService.deleteFiling(filing.filingId);\r\n\r\n _.remove(this.viewModel.model, filing);\r\n\r\n this.editState.refreshGrid = true;\r\n\r\n // stay in edit mode after deleting a filing\r\n this.editState.setDirty(false);\r\n this.editState.refreshActivity = false;\r\n\r\n this._navigationEvent.refreshActivityData();\r\n\r\n if (this.viewModel.model.length < 1) {\r\n this.editState.showEditControls = false;\r\n this.editState.setEditMode(false);\r\n } else {\r\n this.viewModel.resetEdit();\r\n this._complianceService.setFilingIndex(this.viewModel, 0, true);\r\n }\r\n } finally {\r\n this.isLoading = false;\r\n }\r\n }\r\n\r\n goToFiling(filing: Filing): void {\r\n this._upgradeNavigationServiceHandler.go('filingRedirect',\r\n {\r\n 'entityID': filing.filingId\r\n });\r\n }\r\n\r\n goToFilingBatchDetails(filing: Filing): void {\r\n this._upgradeNavigationServiceHandler.go('filingBatchDetails',\r\n {\r\n 'companyId': filing.filingBatch.companyId,\r\n 'filingBatchId': filing.filingBatch.filingBatchId\r\n });\r\n }\r\n\r\n goToReturnFilingBatch(filing: Filing): void {\r\n this._productAnalyticsService.logEvent('access-filing-batch', {\r\n returnAccessPath: 'parcel prepare'\r\n });\r\n this._upgradeNavigationServiceHandler.go('returnFilingBatchPage',\r\n {\r\n 'filingBatchId': filing.filingBatch.filingBatchId\r\n });\r\n }\r\n\r\n private async _afterTaskModalClose(shouldReload): Promise {\r\n if (!shouldReload) {\r\n return;\r\n }\r\n\r\n this._navigationEvent.refreshActivityData();\r\n\r\n this.isLoading = true;\r\n try {\r\n await this._complianceService.loadTaskSummary(this.viewModel);\r\n } finally {\r\n this.isLoading = false;\r\n }\r\n\r\n this.editState.refreshGrid = true;\r\n }\r\n}\r\n","
\r\n
0\">\r\n
There are presently no budgets for {{this.currentYear.annualYear1}}
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
There are presently no budgets available to add
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n FROZEN\r\n
\r\n
0\">\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n

Budget Assessment

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
ComponentAVRatioFMV
{{component.assessmentComponentName}}{{component.assessedValue | number:'1.0-0'}}{{component.ratio | percent:'1.3-3'}}{{getFairMarketValue(component) | number:\"1.0-0\"}}
Total:{{budgetAssessmentTotals.av | number:'1.0-0'}}{{budgetAssessmentTotals.fmv | number:'1.0-0'}}
{{alternativeAssessment.assessmentComponentName}}{{alternativeAssessment.assessedValue | number:'1.0-0'}}{{alternativeAssessment.ratio | percent:'1.3-3'}}{{getFairMarketValue(alternativeAssessment) | number:\"1.0-0\"}}
\r\n
\r\n
\r\n
\r\n
\r\n \r\n

{{viewModel.model.description}}

\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Budget Taxes

\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Tax CollectorEff. RateTotal
{{collector.collectorName}}{{collector.effectiveTaxRate | percent:'1.6-6'}}{{collector.totalPayment | currency: 'USD':'symbol-narrow'}}{{getCollectorPaymentAmount(collector.taxPayments, dueDate.date) | currency: 'USD':'symbol-narrow'}}
Total:{{totalPaymentAmount | currency: 'USD':'symbol-narrow'}}{{dueDate.total | currency: 'USD':'symbol-narrow'}}
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Tax CollectorPayment DuePayment AmountTax Period BeginTax Period End
{{collector.collectorName}} 1\">- Payment {{i+1}} of {{collector.taxPayments.length}}{{payment.paymentAmount | currency: 'USD':'symbol-narrow'}}
Total:{{totalPaymentAmount | currency: 'USD':'symbol-narrow'}}
\r\n
\r\n
\r\n
\r\n","import { Component, OnChanges, Input } from '@angular/core';\r\nimport { AnnualBudgetViewModel, AnnualBudgetService } from './budget.details.service';\r\nimport { AnnualDetailYear } from '../Annual-Year/annual-year.model';\r\nimport { AnnualDetailEditState } from '../annual-details-navigation.service';\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment';\r\nimport { MessageBoxService, MessageBoxButtons, MessageBoxResult } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { AssessmentComponentTypeEnum } from '../../constants.new';\r\n\r\n@Component({\r\n selector: 'annual-budget',\r\n templateUrl: './budget.details.component.html',\r\n styleUrls: ['./budget.details.component.scss']\r\n})\r\nexport class AnnualBudgetComponent implements OnChanges {\r\n constructor(private annualBudgetService: AnnualBudgetService,\r\n private messageBoxService: MessageBoxService){}\r\n\r\n @Input() viewModel: AnnualBudgetViewModel;\r\n @Input() currentYear?: AnnualDetailYear;\r\n @Input() editState?: AnnualDetailEditState;\r\n\r\n availableBudgets: Core.AvailableAnnualBudget[] = [];\r\n selectedBudget: Core.AvailableAnnualBudget = {\r\n\t\tannualBudgetId: 0,\r\n budgetName: '',\r\n budgetDate: new Date(),\r\n\t\tcompanyBudgetId: 0,\r\n\t\tisFrozen: false\r\n\t};\r\n standardAssessmentComponents: Core.BudgetAssessmentComponentDTO[] = [];\r\n alternativeAssessment: Core.BudgetAssessmentComponentDTO;\r\n budgetAssessmentTotals: {av: number, fmv: number} = {\r\n av: null,\r\n fmv: null\r\n };\r\n totalPaymentAmount: number;\r\n selectedBudgetTaxesView: 'summary' | 'detail' = 'summary';\r\n paymentDueDates: {date: Date, total: number}[];\r\n\r\n availableCompanyBudgets: Core.AvailableCompanyBudget[] = [];\r\n filteredCompanyBudgets: Core.AvailableCompanyBudget[] = [];\r\n overlappingCompanyBudgets: Core.AvailableCompanyBudget[] = [];\r\n nonOverlappingCompanyBudgets: Core.AvailableCompanyBudget[] = [];\r\n selectedBudgetToAdd: Core.AvailableCompanyBudget;\r\n addCompanyBudgetId: number;\r\n\r\n async ngOnChanges() {\r\n this.viewModelChanged();\r\n }\r\n\r\n async viewModelChanged(): Promise {\r\n if(this.viewModel) {\r\n this.viewModel.hasWritePermission = this.editState.editMode;\r\n\r\n const availableBudgets = await this.annualBudgetService.getAvailableBudgets(this.currentYear.annualYear1, this.viewModel.parcelID);\r\n this.availableBudgets = _.orderBy(availableBudgets, ['budgetDate', 'budgetName'], ['desc', 'asc']);\r\n // Get Company Budgets available for the TL Company parent of Parcel.\r\n this.availableCompanyBudgets = await this.annualBudgetService.getAvailableCompanyBudgets(this.viewModel.parcelID);\r\n // Remove Budgets from Available Company Budgets that the Parcel already has an AnnualBudget instance for.\r\n this.filteredCompanyBudgets = _.reject(this.availableCompanyBudgets, (cb) => {\r\n return cb.isFrozen || _.some(this.availableBudgets, {companyBudgetId: cb.companyBudgetId});\r\n });\r\n // Remove Budgets where the Year doesn't overlap with the Fiscal Period\r\n // OR Budgets where the next Year doesn't overlap with the Fiscal Period (to support\r\n // prior year payments for Cash basis).\r\n const budgetOverlaps = (cb) : boolean => {\r\n if ( cb.fiscalPeriodBegin.getUTCFullYear() === this.currentYear.annualYear1 ||\r\n cb.fiscalPeriodEnd.getUTCFullYear() === this.currentYear.annualYear1 )\r\n {\r\n return true;\r\n }\r\n if ( (cb.fiscalPeriodBegin.getUTCFullYear() === this.currentYear.annualYear1 + 1 ||\r\n cb.fiscalPeriodEnd.getUTCFullYear() === this.currentYear.annualYear1 + 1) )\r\n {\r\n return true;\r\n }\r\n return false;\r\n };\r\n this.overlappingCompanyBudgets = _.reject(this.filteredCompanyBudgets, (cb) => {\r\n return !budgetOverlaps(cb);\r\n });\r\n this.nonOverlappingCompanyBudgets = _.reject(this.filteredCompanyBudgets, (cb) => {\r\n return budgetOverlaps(cb);\r\n });\r\n\r\n if(!this.viewModel.model) {\r\n return;\r\n }\r\n\r\n this.editState.showEditControls = true;\r\n\r\n this.selectedBudget = _.find(this.availableBudgets, {annualBudgetId: this.viewModel.model.annualBudgetId});\r\n // If only one available Company Budget, pre-select it for Add, for convenience.\r\n this.selectedBudgetToAdd = (this.filteredCompanyBudgets.length === 1 ? this.filteredCompanyBudgets[0] : undefined);\r\n if ( this.overlappingCompanyBudgets.length === 1 ) {\r\n this.selectedBudgetToAdd = this.overlappingCompanyBudgets[0];\r\n }\r\n else if ( this.filteredCompanyBudgets.length === 1 ) {\r\n this.selectedBudgetToAdd = this.filteredCompanyBudgets[0];\r\n }\r\n\r\n console.log(this.viewModel);\r\n this.standardAssessmentComponents = _.chain(this.viewModel.model.assessmentComponents)\r\n .filter((item) => {\r\n return item.assessmentComponentTypeID !== AssessmentComponentTypeEnum.Cap;\r\n })\r\n .sortBy(['sequence'])\r\n .value();\r\n this.alternativeAssessment = _.find(this.viewModel.model.assessmentComponents, (item) => {\r\n return item.assessmentComponentTypeID === AssessmentComponentTypeEnum.Cap;\r\n });\r\n this.budgetAssessmentTotals.av = _.reduce(this.standardAssessmentComponents, (sum, component) => sum + component.assessedValue, 0);\r\n this.budgetAssessmentTotals.fmv = _.reduce(this.standardAssessmentComponents, (sum, component) => sum + this.getFairMarketValue(component), 0);\r\n\r\n this.paymentDueDates = _.chain(this.viewModel.model.taxCollectors)\r\n .flatMap('taxPayments')\r\n .uniqBy(payment => payment.dueDate.getTime())\r\n .map('dueDate')\r\n .sortBy()\r\n .map(dueDate => {\r\n const total = _.reduce(this.viewModel.model.taxCollectors, (sum, collector) => {\r\n const payment = _.find(collector.taxPayments, x => moment(x.dueDate).isSame(dueDate));\r\n return payment ? sum + payment.paymentAmount : sum;\r\n }, 0);\r\n\r\n return {date: dueDate, total: total};\r\n })\r\n .value();\r\n\r\n //this.viewModel.model.taxCollectors = _.map(this.viewModel.model.taxCollectors, collector => {\r\n // collector.totalPayment = _.reduce(collector.taxPayments, (sum, payment) => sum + payment.paymentAmount, 0);\r\n // return collector;\r\n //});\r\n\r\n this.totalPaymentAmount = _.reduce(this.viewModel.model.taxCollectors, (sum, collector) => sum + collector.totalPayment, 0);\r\n this.viewModel.updateModalData();\r\n } else {\r\n this.editState.showEditControls = false;\r\n }\r\n }\r\n\r\n getCollectorPaymentAmount(taxPayments: Core.BudgetTaxPaymentDTO[], dueDate: Date): number{\r\n const payment = _.find(taxPayments, x => moment(x.dueDate).isSame(dueDate));\r\n return payment ? payment.paymentAmount : null;\r\n }\r\n\r\n getFairMarketValue(component: Core.BudgetAssessmentComponentDTO): number {\r\n if ( component.fairMarketValue ) {\r\n return Number(component.fairMarketValue);\r\n }\r\n if ( !component.ratio || component.ratio === 0 ) {\r\n return 0;\r\n }\r\n\r\n return new Decimal(component.assessedValue).dividedBy(component.ratio).toNumber();\r\n }\r\n\r\n async selectedBudgetChanged(): Promise {\r\n this.editState.entityLoading = true;\r\n const viewModel = await this.annualBudgetService.getAnnualBudgetViewModelByID(this.viewModel.annualYearModel, this.selectedBudget.annualBudgetId, this.viewModel.parcelID, this.viewModel.parcelAcctNum);\r\n\r\n _.assign(this.viewModel, viewModel);\r\n this.viewModelChanged();\r\n\r\n this.editState.entityLoading = false;\r\n }\r\n\r\n async deleteBudget(): Promise {\r\n const result = await this.messageBoxService.open({\r\n message: 'Are you sure you want to delete this budget?',\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (result === MessageBoxResult.Cancel) {\r\n return;\r\n }\r\n\r\n const deleteSuccess = await this.tryDelete();\r\n\r\n if(deleteSuccess) {\r\n this.editState.setEditMode(false);\r\n\r\n this.availableBudgets = await this.annualBudgetService.getAvailableBudgets(this.currentYear.annualYear1, this.viewModel.parcelID);\r\n\r\n if(this.availableBudgets.length) {\r\n this.selectedBudget = this.availableBudgets[0];\r\n\r\n this.viewModel.model = await this.annualBudgetService.getAnnualBudget(this.selectedBudget.annualBudgetId);\r\n\r\n this.viewModelChanged();\r\n\r\n this.viewModel.resetEdit();\r\n this.editState.refreshGrid = true;\r\n } else {\r\n this.viewModel.model = undefined;\r\n\r\n this.viewModelChanged();\r\n this.editState.refreshGrid = true;\r\n }\r\n }\r\n }\r\n\r\n async addNewBudget(): Promise {\r\n if ( !this.selectedBudgetToAdd )\r\n {\r\n return Promise.resolve();\r\n }\r\n this.editState.entityLoading = true;\r\n\r\n this.viewModel.model = await this.annualBudgetService.addAnnualBudget(this.viewModel.parcelID, this.currentYear.annualYear1, this.selectedBudgetToAdd.companyBudgetId);\r\n await this.viewModelChanged();\r\n\r\n this.selectedBudgetToAdd = undefined;\r\n this.viewModel.resetEdit();\r\n this.editState.setEditMode(true);\r\n this.editState.refreshGrid = true;\r\n\r\n this.editState.entityLoading = false;\r\n }\r\n\r\n private async tryDelete(): Promise {\r\n this.editState.entityLoading = true;\r\n try {\r\n await this.annualBudgetService.deleteAnnualBudget(this.viewModel.model.annualBudgetId);\r\n return Promise.resolve(true);\r\n }\r\n catch(e) {\r\n console.warn(e);\r\n return Promise.resolve(false);\r\n }\r\n finally {\r\n this.editState.entityLoading = false;\r\n }\r\n\r\n }\r\n\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n

Annual Details

\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { TooltipDirective } from 'ngx-bootstrap/tooltip';\r\nimport { ProductAnalyticsService } from '../Common/Amplitude/productAnalytics.service';\r\nimport { MessageBoxButtons, MessageBoxResult, MessageBoxService } from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { ParcelActivityModalService } from '../Entity/Parcel/Info/Activity/parcel-activity-modal.service.upgrade';\r\nimport { AnnualDetailsNavigationEventService, AppealNavigationInput, AssessmentNavigationInput, TaxNavigationInput } from './annual-details-event.service';\r\nimport { AnnualDetailsNavigationService, NavigationState, ViewTarget } from './annual-details-navigation.service';\r\nimport { AnnualDetailsService } from './annual-details.service';\r\nimport { AnnualDetailAssessment, AnnualDetailComponent, AnnualDetailYear, AnnualDetailYearList, AnnualGridYearsInfo } from './Annual-Year/annual-year.model';\r\nimport { AnnualAssessmentDetail, Assessment } from './Assessments/assessment.model';\r\nimport { AssessmentViewModel } from './Assessments/assessment.service';\r\nimport { FilingType, FilingTypeSummary } from './Compliance/compliance.model';\r\nimport { ComplianceService } from './Compliance/compliance.service';\r\nimport * as _ from 'lodash';\r\nimport { EntityType } from '../constants.new';\r\nimport { ForecastingBudgetingService } from '../Budget/forecasting.budgeting.service';\r\nimport { HelpService } from '../UI-Lib/Help-Tooltip';\r\nimport { ANNUAL_DETAILS_HELP } from './annual-details.component.help';\r\nimport { TimerService } from '../UI-Lib/Utilities/timer.service';\r\nimport { UserSettingsService } from '../Account/userSettings.service';\r\nimport { FeatureFlagsService } from '../Common/FeatureFlags/feature-flags-service';\r\n\r\n@Component({\r\n selector: 'annual-details',\r\n templateUrl: './annual-details.component.html'\r\n})\r\nexport class AnnualDetailsComponent implements OnInit {\r\n constructor(\r\n private readonly annualDetailsService: AnnualDetailsService,\r\n private readonly annualDetailsNavigationService: AnnualDetailsNavigationService,\r\n private readonly complianceService: ComplianceService,\r\n private readonly messageBox: MessageBoxService,\r\n private readonly parcelActivityModalService: ParcelActivityModalService,\r\n private readonly navigationEvent: AnnualDetailsNavigationEventService,\r\n private readonly forecastingBudgetingService: ForecastingBudgetingService,\r\n private readonly _helpService: HelpService,\r\n private readonly _timer: TimerService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _userSettingsService: UserSettingsService,\r\n public toastr: ToastrService,\r\n private readonly _featureFlagsService: FeatureFlagsService\r\n ) { }\r\n\r\n @Input() parcelId: number;\r\n @Input() entityTypeId: number;\r\n @Input() siteId: number;\r\n @Input() stateId: number;\r\n @Input() companyId: number;\r\n @Input() topLevelCompanyId: number;\r\n @Input() returnPreparationAllowed: boolean;\r\n @Input() assessorId: number;\r\n @Input() componentTypes: any[];\r\n @Input() hasWritePermission: boolean;\r\n @Input() hasCompanyCollectors: boolean;\r\n @Input() hasComplianceResponsibility: boolean;\r\n @Input() parcelAcctNum: string;\r\n @Input() masterParcelId: number;\r\n @Input() parcelLinkageTypeId: number;\r\n @Input() consolidatingTypeId: number;\r\n @Input() consolidatedParcelId: number;\r\n @Input() propertyType: number;\r\n @Input() annualYearData: AnnualGridYearsInfo;\r\n @Output() maximizeChanged: EventEmitter = new EventEmitter();\r\n @ViewChild('aDValidation') aDValidation: TooltipDirective;\r\n\r\n components: AnnualDetailComponent[];\r\n filingTypes: FilingType[] = [];\r\n filings: FilingTypeSummary[] = [];\r\n years: AnnualDetailYear[];\r\n annualYearIDs: number[];\r\n maximize: boolean;\r\n navigationState: NavigationState;\r\n ViewTarget = ViewTarget;\r\n yearList: AnnualDetailYearList;\r\n vanillaYears: number[]; // For assessment-taxes-details modal\r\n totalYears: number = 0;\r\n annualDetailsSaveAllowed: boolean = true;\r\n budgetsEnabled: boolean = false;\r\n viewTaxableValueSavedSetting: any;\r\n isViewTaxableValuesEnabled: boolean;\r\n\r\n // *** Navigation functions ***\r\n // We originally didn't have these, prefering instead to do something like:\r\n // [gotoGridHandler]=\"navigationState.goToGrid\"\r\n // in the bindings; however we discovered that the \"this\" variable in the\r\n // goToGrid function isn't set to the navigationState in that case, causing\r\n // breakage. Using these shims in the component solves the problem.\r\n goToGrid: () => Promise;\r\n goToAssessment: (year: AnnualDetailYear, revision: AnnualDetailAssessment) => Promise;\r\n // *** End navigation functions ***\r\n\r\n private _viewTaxableValueSettingName: string = 'View-Taxable-Values'\r\n\r\n async ngOnInit() {\r\n this._helpService.setContent(ANNUAL_DETAILS_HELP);\r\n this.maximize = false;\r\n this.navigationState = null;\r\n //this.navigationEvent.resetAnnualDetails();\r\n\r\n const settingsGroup = this._userSettingsService.getSettingsByGroup(Core.UserSettingGroup.AnnualDetails);\r\n this.viewTaxableValueSavedSetting = settingsGroup.find(x => x.name === this._viewTaxableValueSettingName);\r\n this.isViewTaxableValuesEnabled = this._featureFlagsService.featureFlags.enableTrueRateBasedSystem;\r\n\r\n this.complianceService.getFilingTypesByParcel(this.parcelId).then((data) => {\r\n this.filingTypes = data;\r\n // It's possible that we're loading the page with a pre-selected annual year that's outside the\r\n // first 10-year range; if that happens, we need to default to showing all years\r\n const preLoadAnnualYearID = +this.getParameterValue('annualYearID');\r\n this.getYearData(false, preLoadAnnualYearID, this.annualYearData).then(() => {\r\n this.checkNavigationParameters();\r\n });\r\n });\r\n\r\n this.goToGrid = () => {\r\n return this.navigationState.goToGrid();\r\n };\r\n this.goToAssessment = (year: AnnualDetailYear, revision: AnnualDetailAssessment) => {\r\n return this.navigationState.goToAssessment(year, revision);\r\n };\r\n\r\n this.navigationEvent.assessmentEvent$.forEach((event: AssessmentNavigationInput) => {\r\n this.ensureYearLoaded(event.annualYearID).then(hasYear => {\r\n if (hasYear) {\r\n const year = _.find(this.years, { annualYearID: event.annualYearID });\r\n this.navigationState.goToGrid().then(() => {\r\n const assessment = _.find(year.annualGridDetails, { annualAssessmentID: event.annualAssessmentID });\r\n this.navigationState.goToAssessment(year, assessment);\r\n });\r\n }\r\n });\r\n });\r\n\r\n this.navigationEvent.appealEvent$.forEach((event: AppealNavigationInput) => {\r\n this.ensureYearLoaded(event.annualYearID).then(hasYear => {\r\n if (hasYear) {\r\n const year = _.find(this.years, { annualYearID: event.annualYearID });\r\n this.navigationState.goToGrid().then(() => {\r\n const assessment = _.find(year.annualGridDetails, { annualAssessmentID: event.annualAssessmentID });\r\n this.navigationState.goToAppeals(year, assessment, event.appealID);\r\n });\r\n }\r\n });\r\n });\r\n\r\n this.navigationEvent.taxEvent$.forEach((event: TaxNavigationInput) => {\r\n this.ensureYearLoaded(event.annualYearID).then(hasYear => {\r\n if (hasYear) {\r\n const year = _.find(this.years, { annualYearID: event.annualYearID });\r\n if (year) {\r\n this.navigationState.goToGrid().then(() => {\r\n this.navigationState.goToTaxes(year, event.taxID);\r\n });\r\n }\r\n }\r\n });\r\n });\r\n\r\n this.navigationEvent.refundEvent$.forEach((event) => {\r\n this.ensureYearLoaded(event.annualYearID).then(hasYear => {\r\n if (hasYear) {\r\n const year = _.find(this.years, { annualYearID: event.annualYearID });\r\n if (year) {\r\n this.navigationState.goToGrid().then(() => {\r\n this.navigationState.goToTaxes(year, null, event.taxID);\r\n });\r\n }\r\n }\r\n });\r\n });\r\n\r\n this.navigationEvent.filingEvent$.forEach((event) => {\r\n this.ensureYearLoaded(event.annualYearID).then(hasYear => {\r\n if (hasYear) {\r\n const year = _.find(this.years, { annualYearID: event.annualYearID });\r\n if (year) {\r\n this.navigationState.goToGrid().then(() => {\r\n this.navigationState.goToCompliance(year, event.filingId);\r\n });\r\n }\r\n }\r\n });\r\n });\r\n\r\n this.navigationEvent.refreshAnnualYearEvent$.forEach((event) => {\r\n const year = this.navigationState.currentYear;\r\n\r\n if(!year) {\r\n return;\r\n }\r\n\r\n const currentRevision = this.navigationState.currentRevision;\r\n this.getYearData(false, year.annualYearID).then(() => {\r\n const newYearData: AnnualDetailYear = _.find(this.years, { annualYearID: year.annualYearID });\r\n this.navigationState.currentYear = newYearData;\r\n if(this.navigationState.currentAssessmentVM) {\r\n this.navigationState.currentAssessmentVM.currentYear = newYearData;\r\n }\r\n this.navigationState.currentRevision = _.find(newYearData.annualGridDetails, { annualAssessmentID: currentRevision.annualAssessmentID });\r\n });\r\n\r\n });\r\n\r\n this.navigationEvent.goToGridEvent$.forEach((event) => {\r\n this.navigationState.refreshGrid = true;\r\n this.navigationState.goToGrid();\r\n });\r\n\r\n this.budgetsEnabled = await this.forecastingBudgetingService.getAreBudgetsEnabled(EntityType.Parcel, this.parcelId);\r\n }\r\n\r\n annualDetailsSaveAllowedChanged(isAnnualDetailsSaveAllowed: boolean): void {\r\n this.annualDetailsSaveAllowed = isAnnualDetailsSaveAllowed;\r\n }\r\n\r\n ensureYearLoaded(annualYearID: number): Promise {\r\n return new Promise((resolve, reject) => {\r\n if (!annualYearID || _.some(this.years, y => y.annualYearID === annualYearID)) {\r\n resolve(true);\r\n }\r\n else if (_.some(this.annualYearIDs, i => i === annualYearID)) {\r\n console.log(['Reloading annual years', this.years, annualYearID]);\r\n this.getYearData(true).then(() => {\r\n resolve(true);\r\n });\r\n }\r\n else {\r\n resolve(false);\r\n }\r\n });\r\n }\r\n\r\n maximize_click(): void {\r\n this.maximize = true;\r\n this.maximizeChanged.emit(this.maximize);\r\n }\r\n\r\n unmaximize_click(): void {\r\n this.maximize = false;\r\n this.maximizeChanged.emit(this.maximize);\r\n }\r\n\r\n checkNavigationParameters(): void {\r\n //Read parameters\r\n //Find year to load from years, by ID. If none found, do nothing\r\n const annualYearParamID = +this.getParameterValue('annualYearID');\r\n if (annualYearParamID) {\r\n this._setNavigationBasedOnAnnualYearId(annualYearParamID);\r\n }\r\n\r\n const taxYearParam = +this.getParameterValue('taxYear');\r\n if (taxYearParam) {\r\n this._setNavigationBasedOnTaxYear(taxYearParam);\r\n }\r\n }\r\n\r\n async getYearData(getAllYears: boolean, searchForYear?: number, annualYearData?: AnnualGridYearsInfo): Promise {\r\n const annualGridYearsInfo = annualYearData || await this.annualDetailsService.getAnnualYears(this.parcelId, getAllYears);\r\n\r\n this.annualYearIDs = annualGridYearsInfo.annualYearIDs;\r\n const callback = ({totalYears, years}) => {\r\n this.totalYears = totalYears;\r\n this.components = this.annualDetailsService.getComponentsFromYears(years);\r\n this.filings = this.getFilingTypesFromYears(years);\r\n this.years = this.annualDetailsService.formatYearDateDisplay(years);\r\n this.yearList = new AnnualDetailYearList(this.years);\r\n this.navigationEvent.setYears(this.yearList.years.map(y => y.annualYear1));\r\n this.vanillaYears = _.map(this.years, 'annualYear1');\r\n if (!this.navigationState) {\r\n this.navigationState = this.annualDetailsNavigationService.createNavigationState(years, this.parcelId,\r\n this.masterParcelId, this.parcelLinkageTypeId, this.consolidatingTypeId, this.consolidatedParcelId, this.parcelAcctNum, this.stateId, this.assessorId, this.hasWritePermission);\r\n }\r\n this.navigationState.entityLoading = false;\r\n this.navigationState.resetYearsHandler = () => {\r\n return this.complianceService.getFilingTypesByParcel(this.parcelId).then((data) => {\r\n this.filingTypes = data;\r\n return this.getYearData(false);\r\n });\r\n };\r\n this.navigationState.staleAppealSavings = false;\r\n this.navigationState.staleAppealStatus = false;\r\n };\r\n\r\n // We'll go get the annual year data, and in the very rare case where we've loaded the page with a link to a year that's\r\n // not in the first 10 years, repeat the call and get all years before continuing (WK-4700)\r\n if (searchForYear && !_.some(annualGridYearsInfo.years, y => y.annualYearID === searchForYear) &&\r\n _.some(this.annualYearIDs, i => i === searchForYear)) {\r\n //console.log(['Extending annual year search', annualGridYearsInfo.years, searchForYear]);\r\n return this.annualDetailsService.getAnnualYears(this.parcelId, true).then(callback);\r\n }\r\n\r\n return callback(annualGridYearsInfo);\r\n }\r\n\r\n getFilingTypesFromYears(years: AnnualDetailYear[]): FilingTypeSummary[] {\r\n return _.chain(years)\r\n .map('complianceFilingTypeSummaries')\r\n .flatten()\r\n .uniqBy('filingTypeId')\r\n .compact()\r\n .sortBy('filingTypeSequence')\r\n .value() as FilingTypeSummary[];\r\n }\r\n\r\n toggleEdit(): void {\r\n this.navigationState.setEditMode(!this.navigationState.editMode);\r\n }\r\n\r\n saveEdit(): void {\r\n this.navigationState.validationHandler((isValid, errorMessage) => {\r\n if (!isValid) {\r\n this.navigationState.validationMessage = errorMessage;\r\n\r\n // HACK need setTimeout for some reason as when the 'show'\r\n // is called the validationMessage is not set unless we have the timeout\r\n this._timer.setTimeout(() => {\r\n this.aDValidation.show();\r\n });\r\n\r\n return;\r\n }\r\n\r\n this.navigationState.validationMessage = '';\r\n\r\n if (this.navigationState.refreshGrid) {\r\n this.navigationState.saveHandler().then((toastMessage) => {\r\n if (toastMessage) {\r\n this.toastr.info(toastMessage);\r\n }\r\n\r\n this.getYearData(false).then(() => {\r\n this.navigationState.editMode = false;\r\n this.navigationState.setDirty(false);\r\n this.navigationState.refreshGrid = false;\r\n });\r\n });\r\n } else {\r\n this.navigationState.saveHandler().then((toastMessage) => {\r\n if (toastMessage) {\r\n this.toastr.info(toastMessage);\r\n }\r\n\r\n this.navigationState.editMode = false;\r\n this.navigationState.setDirty(false);\r\n }).catch(reason => {\r\n this.navigationState.editMode = true;\r\n });\r\n }\r\n });\r\n }\r\n\r\n cancelEdit(): void {\r\n const performCancel = (): void => {\r\n this.navigationState.cancelHandler();\r\n this.navigationState.editMode = false;\r\n this.navigationState.setDirty(false);\r\n };\r\n if (this.navigationState.isDirty) {\r\n this.messageBox.open({\r\n title: 'WARNING',\r\n message: 'Are you sure you wish to cancel your changes?',\r\n buttons: MessageBoxButtons.YesNo\r\n }).then((result) => {\r\n if (result === MessageBoxResult.Yes) {\r\n performCancel();\r\n }\r\n });\r\n }\r\n else {\r\n performCancel();\r\n }\r\n }\r\n\r\n getParameterValue(name: string): any {\r\n const path = window.location.href;\r\n const parsedName = name.replace(/[\\[\\]]/g, '\\\\$&');\r\n const regex = new RegExp(`[?&]${parsedName}(=([^&#]*)|&|#|$)`), results = regex.exec(path);\r\n if (!results) {\r\n return null;\r\n }\r\n if (!results[2]) {\r\n return '';\r\n }\r\n\r\n return decodeURIComponent(results[2].replace(/\\+/g, ' '));\r\n }\r\n\r\n assessmentModelChange(changedAssessment: Assessment): void {\r\n if (this.navigationState.currentRevision.annualAssessmentID === changedAssessment.annualAssessmentID) {\r\n //If the name has changed of the\r\n this.navigationState.currentRevision.revisionDesc = changedAssessment.revisionDesc;\r\n this.navigationState.currentRevision.taxableValues = changedAssessment.taxableValues;\r\n\r\n //Update each component by hand\r\n changedAssessment.annualAssessmentDetails.forEach((component: AnnualAssessmentDetail, index: number) => {\r\n let changedComponent: AnnualDetailComponent = _.find(this.navigationState.currentRevision.annualGridComponents, { 'assessmentClassComponentID': component.assessmentClassComponentID });\r\n\r\n if (changedComponent) {\r\n changedComponent.fairMarketValue = component.fairMarketValue;\r\n }\r\n\r\n if (component.efAction === 'add') {\r\n //If there's no existing component in navigation state, add it\r\n //This goes off of componentName because there are no IDs yet since it's not saved\r\n if (!changedComponent && !_.some(this.navigationState.currentRevision.annualGridComponents, { 'componentName': component.componentName })) {\r\n this.navigationState.currentRevision.annualGridComponents.push(new AnnualDetailComponent(component.componentName, component.fairMarketValue, component.assessmentComponentTypeID));\r\n } else {\r\n changedComponent = _.find(this.navigationState.currentRevision.annualGridComponents, { 'componentName': component.componentName });\r\n changedComponent.fairMarketValue = component.fairMarketValue;\r\n }\r\n }\r\n });\r\n\r\n //Delete components missing from the input\r\n //Using name here in case we are deleting an un-committed component (hence no ID)\r\n //Reverse for loop so we can safely splice out the \"current\" item without upsetting the index order\r\n for (let i = this.navigationState.currentRevision.annualGridComponents.length - 1; i >= 0; i--) {\r\n const componentExists = _.some(changedAssessment.annualAssessmentDetails, { 'componentName': this.navigationState.currentRevision.annualGridComponents[i].componentName });\r\n if (!componentExists) {\r\n this.navigationState.currentRevision.annualGridComponents.splice(i, 1);\r\n }\r\n }\r\n }\r\n }\r\n\r\n openParcelActivityModal(): void {\r\n this._productAnalyticsService.logEvent('click-parcel-analysis');\r\n this.parcelActivityModalService.open(this.parcelId, this.siteId, _.map(this.years, 'annualYear1') as number[]);\r\n }\r\n\r\n async onViewTaxableValueChange(value: boolean): Promise {\r\n if (!this.viewTaxableValueSavedSetting) {\r\n this.viewTaxableValueSavedSetting = {\r\n id: 0,\r\n name: this._viewTaxableValueSettingName,\r\n groupId: Core.UserSettingGroup.AnnualDetails,\r\n folderId: Core.UserSettingFolder.Default,\r\n value: {}\r\n };\r\n }\r\n\r\n this.viewTaxableValueSavedSetting.value = value;\r\n\r\n this.viewTaxableValueSavedSetting = await this._userSettingsService.save(this.viewTaxableValueSavedSetting);\r\n }\r\n\r\n private _setNavigationBasedOnAnnualYearId(annualYearID: number): void {\r\n const year = _.find(this.years, { annualYearID: annualYearID });\r\n\r\n if (!year) { return; }\r\n\r\n if (this.getParameterValue('annualAssessmentID')) {\r\n const revision = _.find(year.annualGridDetails, { annualAssessmentID: +this.getParameterValue('annualAssessmentID') });\r\n\r\n if (this.getParameterValue('appealID')) {\r\n const appealID = +this.getParameterValue('appealID');\r\n\r\n this.navigationState.goToAppeals(year, revision, appealID);\r\n } else {\r\n this.navigationState.goToAssessment(year, revision);\r\n }\r\n } else if (this.getParameterValue('billClusterID')) {\r\n const billClusterID = +this.getParameterValue('billClusterID');\r\n\r\n this.navigationState.goToTaxes(year, billClusterID);\r\n } else if (this.getParameterValue('refundID')) {\r\n const refundID = +this.getParameterValue('refundID');\r\n\r\n this.navigationState.goToTaxes(year, null, refundID);\r\n } else if (this.getParameterValue('filingId')) {\r\n const filingId = +this.getParameterValue('filingId');\r\n\r\n this.navigationState.goToCompliance(year, filingId);\r\n }\r\n }\r\n\r\n private _setNavigationBasedOnTaxYear(taxYear: number): void {\r\n const year = _.find(this.years, { annualYear1: taxYear });\r\n\r\n if (!year) { return; }\r\n\r\n this.navigationState.goToCompliance(year);\r\n }\r\n}\r\n","import { CommonModule, DecimalPipe } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { ButtonsModule } from 'ngx-bootstrap/buttons';\r\n\r\nimport { DraggableItemService } from 'ngx-bootstrap/sortable';\r\nimport { ModalModule } from 'ngx-bootstrap/modal';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { SortableModule } from 'ngx-bootstrap/sortable';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { TransmittalModule } from '../Processing/Transmittal/transmittal.module';\r\nimport { SharedPipesModule } from '../UI-Lib/Pipes/shared-pipes.module';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { AnnualDetailsNavigationEventService } from './annual-details-event.service';\r\nimport { AnnualDetailsNavigationService } from './annual-details-navigation.service';\r\nimport { AnnualDetailsComponent } from './annual-details.component';\r\nimport { AnnualDetailsService } from './annual-details.service';\r\nimport { AnnualYearComponent } from './Annual-Year/annual-year.component';\r\nimport { AppealComponent } from './Appeals/appeal.component';\r\nimport { AppealService } from './Appeals/appeal.service';\r\nimport { FmvInputComponent } from './Assessments/assessment-input.component';\r\nimport { AssessmentComponent } from './Assessments/assessment.component';\r\nimport { AssessmentService } from './Assessments/assessment.service';\r\nimport { ComplianceComponent } from './Compliance/compliance.component';\r\nimport { ComplianceReturnAddComponent } from './Compliance/Return-Add/return-add.component';\r\nimport { ComplianceService } from './Compliance/compliance.service';\r\nimport { AnnualDetailsGridComponent } from './Grid/annual-details-grid.component';\r\nimport { AddYearModalComponent } from './Modals/add-annual-year.component';\r\nimport { AddAppealModalComponent } from './Modals/add-appeal.component';\r\nimport { AddFilingModalComponent } from './Modals/add-filing.component';\r\nimport { AddRevisionModalComponent } from './Modals/add-revision.component';\r\nimport { PaymentPackagesModalComponent } from './Modals/payment-package-modal.component';\r\nimport { PaymentStubModalComponent } from './Modals/payment-stub.component';\r\nimport { ReorderRevisionsModalComponent } from './Modals/reorder-revisions.component';\r\nimport { AssessmentComponentExemptionPipe } from './Pipes/assessment-component-exemption.pipe';\r\nimport { BillClusterService } from './Taxes/bill-cluster.service';\r\nimport { BillsComponent } from './Taxes/bills.component';\r\nimport { RefundComponent } from './Taxes/refund.component';\r\nimport { TaxesComponent } from './Taxes/taxes.component';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { AnnualBudgetService } from './Budget/budget.details.service';\r\nimport { AnnualBudgetComponent } from './Budget/budget.details.component';\r\nimport { AccrualDetailModalComponent } from './Modals/accrual-detail.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BsDropdownModule,\r\n TabsModule,\r\n ModalModule,\r\n SortableModule,\r\n ButtonsModule,\r\n PopoverModule,\r\n TooltipModule,\r\n CurrencyMaskModule,\r\n TransmittalModule,\r\n BusyIndicatorModule.forRoot()\r\n ],\r\n declarations: [\r\n AnnualDetailsComponent,\r\n AnnualDetailsGridComponent,\r\n AppealComponent,\r\n TaxesComponent,\r\n AnnualYearComponent,\r\n AssessmentComponent,\r\n FmvInputComponent,\r\n AddRevisionModalComponent,\r\n AddYearModalComponent,\r\n ReorderRevisionsModalComponent,\r\n AddAppealModalComponent,\r\n AddFilingModalComponent,\r\n AssessmentComponentExemptionPipe,\r\n BillsComponent,\r\n RefundComponent,\r\n ComplianceComponent,\r\n ComplianceReturnAddComponent,\r\n PaymentStubModalComponent,\r\n PaymentPackagesModalComponent,\r\n AnnualBudgetComponent,\r\n AccrualDetailModalComponent\r\n ],\r\n providers: [\r\n AnnualDetailsService,\r\n AnnualDetailsNavigationService,\r\n AnnualDetailsNavigationEventService,\r\n AssessmentService,\r\n AppealService,\r\n BillClusterService,\r\n ComplianceService,\r\n DecimalPipe,\r\n DraggableItemService,\r\n AnnualBudgetService,\r\n AssessmentComponentExemptionPipe\r\n ],\r\n //Needed for other modules that reference these components (e.g. entity edit)\r\n exports: [\r\n AppealComponent,\r\n TaxesComponent,\r\n AnnualYearComponent,\r\n AssessmentComponent,\r\n BillsComponent,\r\n RefundComponent,\r\n ComplianceComponent,\r\n ComplianceReturnAddComponent\r\n ]\r\n})\r\nexport class AnnualDetailsModule {\r\n static setupModule(): void {\r\n //We only need to downgrade the entry components\r\n //Entry components must have only two words, for example: annualDetails not annualDetailsComponent\r\n //This is due to a bug in angular 1 case formatting where it gets confused with kebab casing with multiple dashes\r\n //And angular 1 will autoconvert camelCase to kebab-case\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('annualDetails', AnnualDetailsComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('billClusterService', BillClusterService);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\nimport { UserService } from '../Account/user.service';\r\nimport { find } from 'lodash';\r\nimport { Team } from './team.model';\r\nimport { UserTeamMember } from '../Common/Models/common.model';\r\n\r\n@Injectable()\r\nexport class TeamService {\r\n constructor(private http: SDHttpService, private readonly _userService: UserService) {}\r\n\r\n private _TEAM_URL = '/api/team';\r\n\tprivate _USER_TEAM_URL = '/api/userteam';\r\n\r\n getAllTeams(includeUsers: boolean): Promise {\r\n let shouldIncludeUsers = includeUsers;\r\n if (includeUsers === undefined) {\r\n shouldIncludeUsers = true;\r\n }\r\n return this.http.get(`${this._TEAM_URL}?includeUsers=${shouldIncludeUsers}`);\r\n //return this.http.get(this._TEAM_URL + '/all/instance/1?includeUsers=' + shouldIncludeUsers);\r\n }\r\n\r\n getAllTeamsForContact(includeUsers: boolean, instanceId: number, userId: System.Guid): Promise {\r\n let shouldIncludeUsers = includeUsers;\r\n if (includeUsers === undefined) {\r\n shouldIncludeUsers = true;\r\n }\r\n return this.http.get(`${this._TEAM_URL}/available/${instanceId}/${userId}` + `?includeUsers=${shouldIncludeUsers}`);\r\n //return this.http.get(this._TEAM_URL + '/all/instance/1?includeUsers=' + shouldIncludeUsers);\r\n }\r\n\r\n editTeam(team: Team): Promise {\r\n return this.http.put(this._TEAM_URL, team);\r\n }\r\n\r\n deleteTeam(team: Team):Promise {\r\n return this.http.delete(`${this._TEAM_URL}/${team.teamID}`);\r\n }\r\n\r\n createTeam(team: Team): Promise {\r\n return this.http.post(this._TEAM_URL, team);\r\n }\r\n\r\n getMembersForTeam(teamID: number):Promise {\r\n const params = {\r\n getFullInfo: true,\r\n includeCompanyRepresentative: true\r\n };\r\n return this.http.get(`${this._USER_TEAM_URL}/${teamID}/members`, { params });\r\n }\r\n\r\n getAllContactUserTeams(contactId: number, params: {\r\n getFullInfo: boolean;\r\n includeCompanyRepresentative: boolean\r\n }): Promise {\r\n return this.http.get(`${this._USER_TEAM_URL}/member/${contactId}`, { params });\r\n }\r\n\r\n getAssignableUserTeams(userId): Promise {\r\n return this.http.get(`${this._USER_TEAM_URL}/assignable`, {\r\n params: {\r\n getFullInfo: true,\r\n userId: userId\r\n }\r\n });\r\n }\r\n\r\n getAllAssignableUsers(isReassign: boolean, includeCompanyRepresentative: boolean, entityIdScope?: number, entityTypeScope?: string, instanceIdScope?: number, includeInactiveContacts?: boolean, entityIdsMultiselectScope?: number[], getDocumentIntakeUserTeamsOnly?: boolean): Promise {\r\n const params: any = {\r\n isAssignable: true,\r\n getFullInfo: true,\r\n includeCompanyRepresentative: includeCompanyRepresentative ?? false,\r\n instanceId: instanceIdScope ?? null, //because of undefined\r\n includeInactiveContacts: includeInactiveContacts ?? false,\r\n getDocumentIntakeUserTeamsOnly: getDocumentIntakeUserTeamsOnly ?? false\r\n };\r\n\r\n let entityIds:number[] = [];\r\n\r\n if(entityIdsMultiselectScope && entityIdsMultiselectScope.length > 0){\r\n entityIds = entityIdsMultiselectScope;\r\n }\r\n else if(entityIdScope) {\r\n if(Array.isArray(entityIdScope)) {\r\n entityIds = entityIdScope;\r\n }\r\n else {\r\n entityIds = [entityIdScope];\r\n }\r\n }\r\n\r\n const isForEntities = entityIds.length > 0 && !!entityTypeScope;\r\n\r\n if(isForEntities) {\r\n params.entityType = entityTypeScope;\r\n return this.http.post(`${this._USER_TEAM_URL}/forentities`, entityIds, { params });\r\n }\r\n else{\r\n return this.http.get(this._USER_TEAM_URL, { params });\r\n }\r\n }\r\n\r\n getAllAssignableRyanUsers(includeCompanyRepresentative?: boolean, entityIdScope?: number, entityTypeScope?: string): Promise {\r\n includeCompanyRepresentative = includeCompanyRepresentative ?? false;\r\n\r\n const params = {\r\n isAssignable: true,\r\n getFullInfo: true,\r\n includeCompanyRepresentative: includeCompanyRepresentative,\r\n entityId: entityIdScope,\r\n entityType: entityTypeScope\r\n };\r\n\r\n //NOTE: if it is not a reassignment, the base this._USER_TEAM_URL is called and it MUST be single instance\r\n //For now will always call the forryanonly - otherwise the selected instance would be in effect if the base url is called and this method name does not make sense\r\n //const url = isReassign ? this._USER_TEAM_URL + '/forryanonly' : this._USER_TEAM_URL;\r\n const url = `${this._USER_TEAM_URL }/forryanonly`;\r\n\r\n return this.http.get(url, { params });\r\n }\r\n\r\n getUserDefaultTeam(): Promise {\r\n const user = this._userService.getUser();\r\n\r\n const filter = {\r\n userId: user.id,\r\n getFullInfo: false\r\n };\r\n\r\n return this._getAllUserTeams(filter)\r\n .then((result) => {\r\n const defaultTeam = find(result, { isDefault: true }) as any;\r\n\r\n if (defaultTeam) {\r\n return {\r\n userID: user.id,\r\n teamID: defaultTeam.teamID\r\n } as unknown as Core.UserTeamModel;\r\n } else {\r\n console.warn('user does not have default team for some reason');\r\n return {} as Core.UserTeamModel;\r\n }\r\n\r\n });\r\n }\r\n\r\n hasLinkedEntities(userId: System.Guid, teamId: number): Promise<{hasLinkedEntities: boolean; message: string}> {\r\n const params = { userId, teamId };\r\n\r\n return this.http.get(`${this._USER_TEAM_URL }/haslinkedentities`, { params });\r\n }\r\n\r\n saveTeamAssignmentTab(teams: Core.UserTeamModel[]): Promise {\r\n return this.http.put(this._USER_TEAM_URL, teams);\r\n }\r\n\r\n getAllForGroup(groupId: number): Promise {\r\n return this.http.get(`${this._USER_TEAM_URL}/group/${groupId}`);\r\n }\r\n\r\n private _getAllUserTeams(params: {userId: System.Guid, getFullInfo: boolean}): Promise {\r\n return this.http.get(this._USER_TEAM_URL, { params });\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n
\r\n

Teams

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n
Team NamePractice AreaCost Center
\r\n \r\n {{ team.name}}\r\n \r\n \r\n Must be unique\r\n \r\n \r\n {{ team.practiceArea}}\r\n \r\n \r\n \r\n \r\n {{ team.costCenter}}\r\n \r\n \r\n \r\n  \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n

Unable to Delete Team

\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n Cannot delete a team with existing users. To delete, please remove the following users from this team:\r\n
    \r\n
  • \r\n {{user.firstName}} {{user.lastName}}\r\n
  • \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, TemplateRef } from '@angular/core';\r\nimport { RestrictService, InstanceRights } from '../Common/Permissions/restrict.service';\r\nimport { Team } from './team.model';\r\nimport * as _ from 'lodash';\r\nimport { MessageBoxButtons, MessageBoxResult, MessageBoxService } from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { NavigationService } from '../Layout/navigation.service';\r\nimport { BsModalRef, BsModalService } from 'ngx-bootstrap/modal';\r\nimport { UserTeamMember } from '../Common/Models/common.model';\r\nimport { TeamService } from './team.service';\r\n\r\nexport class TeamUI extends Team {\r\n isEditing: boolean;\r\n isDeleting: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'teams-page',\r\n templateUrl: './teams.page.component.html',\r\n styleUrls: ['./teams.page.component.scss']\r\n})\r\nexport class TeamsPageComponent implements OnInit {\r\n constructor(private teamsService: TeamService,\r\n private restrictService: RestrictService,\r\n private messageBoxService: MessageBoxService,\r\n private toastr: ToastrService,\r\n private navigationService: NavigationService,\r\n private modalService: BsModalService) { }\r\n\r\n teams: TeamUI[];\r\n dataLoading: boolean = false;\r\n hasTeamEditPermissions: boolean;\r\n editMode: boolean;\r\n originalTeam: TeamUI;\r\n showUniqueTeamNameError: boolean;\r\n readonly warningMessage: string = 'Editing is in progress. Are you sure you want to leave?';\r\n teamMembers: UserTeamMember[];\r\n unableToDeleteRef: BsModalRef;\r\n teamMembersLoading: boolean = false;\r\n\r\n\r\n async ngOnInit() {\r\n this.dataLoading = true;\r\n const teams = await this.teamsService.getAllTeams(false) as TeamUI[];\r\n this.teams = _.sortBy(teams, 'name');\r\n this.dataLoading = false;\r\n\r\n this.hasTeamEditPermissions = this.restrictService.hasInstanceRight(InstanceRights.TEAMSETUPSEDIT);\r\n }\r\n\r\n addTeam() {\r\n this.editMode = true;\r\n this.showUniqueTeamNameError = false;\r\n\r\n this.navigationService.enableNavWarning(this.warningMessage);\r\n const newTeam = new TeamUI();\r\n newTeam.isEditing = true;\r\n this.teams.push(newTeam);\r\n }\r\n\r\n enableEdit(team: TeamUI) {\r\n this.originalTeam = _.cloneDeep(team);\r\n this.editMode = true;\r\n team.isEditing = true;\r\n this.showUniqueTeamNameError = false;\r\n\r\n this.navigationService.enableNavWarning(this.warningMessage);\r\n }\r\n\r\n cancelEdit(team: TeamUI) {\r\n if (!_.isUndefined(team.teamID)) {\r\n _.assign(team, this.originalTeam);\r\n this.showUniqueTeamNameError = false;\r\n team.isEditing = false;\r\n } else {\r\n _.remove(this.teams, team);\r\n }\r\n\r\n this.editMode = false;\r\n this.navigationService.disableNavWarning();\r\n }\r\n\r\n async saveTeam(teamToSave: TeamUI) {\r\n let savedTeam: TeamUI;\r\n\r\n //Check for team name uniqueness\r\n if (_.some(this.teams, team => {\r\n return team.name === teamToSave.name && team.teamID !== teamToSave.teamID;\r\n })) {\r\n this.showUniqueTeamNameError = true;\r\n return;\r\n }\r\n\r\n if (!_.isUndefined(teamToSave.teamID)) {\r\n savedTeam = await this.teamsService.editTeam(teamToSave) as TeamUI;\r\n } else {\r\n savedTeam = await this.teamsService.createTeam(teamToSave) as TeamUI;\r\n }\r\n\r\n _.assign(teamToSave, savedTeam);\r\n teamToSave.isEditing = false;\r\n this.editMode = false;\r\n this.showUniqueTeamNameError = false;\r\n this.navigationService.disableNavWarning();\r\n }\r\n\r\n async deleteTeam(team: TeamUI, unableToDeleteTemplate: TemplateRef) {\r\n if (team.teamMembers.length > 0) {\r\n this.teamMembers = [];\r\n this.unableToDeleteRef = this.modalService.show(unableToDeleteTemplate);\r\n this.teamMembersLoading = true;\r\n this.teamMembers = await this.teamsService.getMembersForTeam(team.teamID);\r\n this.teamMembersLoading = false;\r\n\r\n } else {\r\n const result = await this.messageBoxService.open({\r\n message: `Are you sure you want to delete ${team.name}?`,\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n\r\n if (result == MessageBoxResult.Yes) {\r\n team.isDeleting = true;\r\n try {\r\n await this.teamsService.deleteTeam(team);\r\n\r\n _.remove(this.teams, _.omit(team, 'isDeleting'));\r\n this.toastr.info('Team Deleted');\r\n } catch {\r\n team.isDeleting = false;\r\n }\r\n }\r\n }\r\n }\r\n}\r\n","export class UserTeam {\r\n userTeamID: number;\r\n userID: string;\r\n teamID: number;\r\n isDefault: boolean;\r\n isAssignable: boolean;\r\n numberOfClientServiceResponsibilities: number;\r\n}\r\n\r\nexport class Team {\r\n constructor() {\r\n this.practiceArea = '';\r\n }\r\n\r\n teamID: number;\r\n name: string;\r\n practiceArea: string;\r\n costCenter: string;\r\n teamMembers: UserTeam[];\r\n}\r\n","
\r\n\t\r\n\t

No Teams to Display

\r\n\t
\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\r\n\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
DefaultAssignableTeam Name
\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t
{{ team.teamName}}
\r\n\t\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\t\t\r\n\r\n\t\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t\t

\r\n\t\t\t\t\t\t\t\t\t{{team.message}}\r\n\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t

\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tADD NEW\r\n\t\t\t\t\t\t
\r\n\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t
\r\n\t\t
\r\n\r\n\t
\r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { InstanceRights, RestrictService } from 'src/app/Common/Permissions/restrict.service';\r\nimport { InstanceRepository } from 'src/app/Entity/Instance/instance.repository';\r\nimport { cloneDeep, every, filter, find, findIndex, isEqual, map, omit, reject, remove, some, sortBy } from 'lodash';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { efAction } from 'src/app/constants.new';\r\nimport { TeamService } from '../team.service';\r\n\r\ninterface UserTeamUI extends Core.UserTeamModel {\r\n chooseNew?: boolean\r\n loading?: boolean\r\n isLocked?: boolean\r\n message?: string\r\n efAction?: efAction\r\n newTeamID?: number\r\n}\r\n\r\n@Component({\r\n selector: 'team-assignment-panel',\r\n templateUrl: 'teamAssignmentPanel.component.html'\r\n})\r\n\r\nexport class TeamAssignmentPanelComponent implements OnInit {\r\n constructor(private readonly _instanceRepository: InstanceRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _teamsService: TeamService,\r\n private readonly _toastr: ToastrService\r\n ) { }\r\n\r\n @Input() user: Weissman.Model.Contacts.Contact;\r\n\r\n loading: boolean = false;\r\n isEditMode: boolean = false;\r\n canEdit: boolean = false;\r\n newTeamForTasks: UserTeamUI;\r\n newTeam: Weissman.Model.Workflow.Team;\r\n isLrpRunning: boolean = false;\r\n\r\n private _assignedTeams: UserTeamUI[];\r\n private _cleanAssignedTeams: UserTeamUI[];\r\n private _allTeams: Weissman.Model.Workflow.Team[];\r\n private _instanceId: number;\r\n\r\n async ngOnInit() {\r\n console.log(this.user);\r\n this.loading = true;\r\n\r\n try {\r\n this._instanceId = await this._instanceRepository.getEntityInstanceId('company', this.user.companyID).toPromise();\r\n this.canEdit = this._restrictService.hasInstanceRight(InstanceRights.MANAGEUSERSETUP, this._instanceId);\r\n\r\n if (!this.user.userID) return;\r\n\r\n const contactFilter = {\r\n getFullInfo: true,\r\n includeCompanyRepresentative: true\r\n };\r\n\r\n const assignedTeams = await this._teamsService.getAllContactUserTeams(this.user.contactID, contactFilter);\r\n this._assignedTeams = sortBy(assignedTeams, 'teamName');\r\n console.log(this._assignedTeams);\r\n // processAssignedTeams(teams);\r\n\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n get assignedTeams(): UserTeamUI[] {\r\n return reject(this._assignedTeams, { efAction: 'delete' });\r\n }\r\n\r\n get assignedTeamsToChoose(): UserTeamUI[] {\r\n return filter(this.assignedTeams, 'isAssignable');\r\n }\r\n\r\n get allChoosableTeams(): Weissman.Model.Workflow.Team[] {\r\n return filter(this._allTeams, team => (\r\n every(this._assignedTeams, (assignedTeam) => (\r\n assignedTeam.teamID !== team.teamID || assignedTeam.efAction === 'delete'\r\n ))\r\n ));\r\n }\r\n\r\n get isSaveDisabled(): boolean {\r\n return some(this._assignedTeams, ({ loading, chooseNew }) => loading || chooseNew);\r\n }\r\n\r\n async switchToEditMode(): Promise {\r\n this._cleanAssignedTeams = cloneDeep(this._assignedTeams);\r\n const allTeams = await this._teamsService.getAllTeamsForContact(false, this._instanceId, this.user.userID);\r\n this._allTeams = sortBy(allTeams, 'name');\r\n // this.allTeams = angular.copy(response);\r\n this.isEditMode = true;\r\n }\r\n\r\n async checkLinkedEntities(team: UserTeamUI): Promise {\r\n if (team.isAssignable) return;\r\n\r\n team.loading = true;\r\n\r\n try {\r\n const { hasLinkedEntities, message } = await this._teamsService.hasLinkedEntities(this.user.userID, team.teamID);\r\n\r\n if (!hasLinkedEntities) return;\r\n\r\n if (some(this._assignedTeams, 'isAssignable')) {\r\n team.chooseNew = true;\r\n team.message = `${message} Please choose another team to which they can be assigned.`;\r\n } else {\r\n team.isAssignable = true;\r\n\r\n this._toastr.info(`${message} Please add another team that is assignable before removing this one.`);\r\n }\r\n\r\n } finally {\r\n team.loading = false;\r\n }\r\n }\r\n\r\n updateDefault(team: UserTeamUI): void {\r\n this._assignedTeams = map(this._assignedTeams, x => {\r\n x.isDefault = x.teamID === team.teamID;\r\n return x;\r\n });\r\n }\r\n\r\n removeTeam(team: UserTeamUI): void {\r\n if (team.efAction === 'add') {\r\n remove(this._assignedTeams, team);\r\n } else {\r\n team.efAction = 'delete';\r\n }\r\n }\r\n\r\n chooseNewTeam(editedTeam: UserTeamUI) {\r\n editedTeam.chooseNew = false;\r\n editedTeam.newTeamID = this.newTeamForTasks.teamID;\r\n\r\n this.newTeamForTasks.isLocked = true;\r\n }\r\n\r\n cancelChooseNewTeam(team: UserTeamUI) {\r\n team.isAssignable = true;\r\n team.chooseNew = false;\r\n }\r\n\r\n addTeam() {\r\n if(!this.newTeam) return;\r\n\r\n console.log(this.newTeam);\r\n\r\n const deletedTeamIdx = findIndex(this._assignedTeams, { teamID: this.newTeam.teamID });\r\n\r\n if (deletedTeamIdx !== -1) {\r\n this._assignedTeams[deletedTeamIdx].efAction = null;\r\n this._assignedTeams[deletedTeamIdx].isDefault = false;\r\n\r\n return;\r\n }\r\n\r\n const isDefault = this._assignedTeams.length === 0 || findIndex(this._assignedTeams, 'isDefault') === -1;\r\n const addedTeam = {\r\n isAssignable: true,\r\n isDefault,\r\n teamID: this.newTeam.teamID,\r\n userID: this.user.userID,\r\n teamName: this.newTeam.name,\r\n efAction: 'add',\r\n firstName: this.user.firstName,\r\n lastName: this.user.lastName,\r\n numberOfClientServiceResponsibilities: 0,\r\n newTeamID: null\r\n } as UserTeamUI;\r\n\r\n this._assignedTeams.push(addedTeam);\r\n }\r\n\r\n async save() {\r\n const teamsToSave = map(this._assignedTeams, team => {\r\n const strippedTeam = omit(team, 'isLocked', 'loading', 'chooseNew');\r\n\r\n if(!team.efAction) {\r\n const cleanTeam = find(this._cleanAssignedTeams, {teamID: strippedTeam.teamID});\r\n\r\n if(!isEqual(strippedTeam, cleanTeam)) {\r\n strippedTeam.efAction = 'update';\r\n }\r\n }\r\n\r\n return strippedTeam;\r\n });\r\n\r\n this.loading = true;\r\n try {\r\n const thing = await this._teamsService.saveTeamAssignmentTab(teamsToSave as Core.UserTeamModel[]);\r\n console.log(thing);\r\n this.isEditMode = false;\r\n this.isLrpRunning = true;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n cancel() {\r\n this._assignedTeams = this._cleanAssignedTeams;\r\n this.isEditMode = false;\r\n }\r\n}","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { TeamPickerComponent } from './teamPicker.component';\r\nimport { TeamsPageComponent } from './teams.page.component';\r\nimport { TeamAssignmentPanelComponent } from './Assignment/teamAssignmentPanel.component';\r\nimport { TeamService } from './team.service';\r\n\r\n@NgModule({\r\n imports: [ WeissmanSharedModule ],\r\n declarations: [\r\n TeamsPageComponent,\r\n TeamPickerComponent,\r\n TeamAssignmentPanelComponent\r\n ],\r\n exports: [\r\n TeamsPageComponent,\r\n TeamPickerComponent\r\n ],\r\n providers: [TeamService]\r\n})\r\nexport class TeamModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('teamsPage', TeamsPageComponent);\r\n hybridAdapterUtility.downgradeNg2Component('teamAssignmentPanel', TeamAssignmentPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('teamsService', TeamService);\r\n }\r\n}\r\n","import { ContactShortDTO } from '../User/contact.short.dto.model';\r\nimport { Team } from '../Team/team.model';\r\n\r\nexport class TaskType {\r\n taskTypeID: number;\r\n taskSeriesTypeID: number;\r\n sequence: number;\r\n name: string;\r\n completedName: string;\r\n currentName: string;\r\n anticipatedItem: boolean;\r\n deliverableName: string;\r\n authorizationRequired: boolean;\r\n}\r\n\r\nexport interface TaskSeriesType {\r\n anticipatedAttachmentTypeID: number;\r\n authorizationRequired: boolean;\r\n columnIds: number[];\r\n completedName: string;\r\n currentName: string;\r\n deliverableName: string;\r\n efAction: string;\r\n name: string;\r\n sequence: number;\r\n systemCompletes: boolean;\r\n systemDeletes: boolean;\r\n systemReassigns: boolean;\r\n systemRescinds: boolean;\r\n systemSkips: boolean;\r\n taskSeriesTypeAdvancedSearchDepthID: number;\r\n taskSeriesTypeAdvancedSearchDepthValue: number;\r\n taskSeriesTypeID: number;\r\n taskSeriesTypeSequence: number;\r\n taskTypeID: number;\r\n depthValuesToEnable: number[];\r\n fieldIdsToEnable: number[];\r\n}\r\n\r\nexport class TaskSummary {\r\n completedDateTime: string;\r\n entityID: number;\r\n entityTypeID: number;\r\n seriesIsComplete: boolean;\r\n status: string;\r\n taskSeriesID: number;\r\n}\r\n\r\nexport class TaskAuthorizationInfo {\r\n completeTask: boolean;\r\n rescindTask: boolean;\r\n reassignTask: boolean;\r\n insertTaskBefore: boolean;\r\n insertTaskAfter: boolean;\r\n deleteTask: boolean;\r\n skipTask: boolean;\r\n}\r\n\r\nexport class Task {\r\n taskID: number;\r\n taskSeriesID: number;\r\n taskTypeID: number;\r\n dueDate: Date;\r\n assignedUserID: string;\r\n assignedTeamID: number;\r\n responsibleUserID: string;\r\n responsibleTeamID: number;\r\n workflowUserTypeID: number;\r\n completedDateTime: Date;\r\n completedByUserID: string;\r\n skipped: boolean;\r\n sequence: number;\r\n name: string;\r\n isOpen: boolean;\r\n assignedUser: ContactShortDTO;\r\n responsibleUser: ContactShortDTO;\r\n completedByUser: ContactShortDTO;\r\n taskType: TaskType;\r\n assignedTeam: Team;\r\n responsibleTeam: Team;\r\n taskAuthorizationInfo: TaskAuthorizationInfo;\r\n pointsTo: number[];\r\n entityId: number;\r\n entityTypeID: number;\r\n deliverableName: string;\r\n assignedUserIsOverridden: boolean;\r\n assignedTeamIsOverridden: boolean;\r\n deliverableTaskID: number;\r\n isReady: boolean;\r\n rowVersion: string;\r\n userIsAuthorizedToChangeTask: boolean;\r\n //intakeBatch: IntakeBatch;\r\n //intakeItem: IntakeItem;\r\n}\r\n\r\nexport class TaskDeadlineDTO {\r\n name: string;\r\n dateTime: Date;\r\n}\r\n\r\nexport class TasksByEntityDTO {\r\n entityTypeID: number;\r\n entityID: number;\r\n tasks: Task[];\r\n deadlines: TaskDeadlineDTO;\r\n}\r\n\r\n\r\n//export class IntakeBatch {\r\n//\tintakeBatchID: number;\r\n//\tcontactUserID: string; // GUID\r\n//\tcontactTeamID: number;\r\n//\tbatchNumber: string;\r\n//}\r\n\r\n\r\n//export class IntakeItem {\r\n//\tintakeItemID: number;\r\n//\tintakeBatchID: number;\r\n//\titemNumber: string;\r\n//\tdueDate: Date;\r\n//\tcompanyID: number;\r\n//\tstateID: number;\r\n//\tassessorID: number;\r\n//\tcollectorID: number;\r\n//\ttaxYear: number;\r\n//\tentityTypeID: number;\r\n//\tentityID: number;\r\n//\texceptionStatusID: number;\r\n//}\r\n\r\n\r\n// This enumeration should probably be defined in some sort of global constant system\r\n// Also note, this is not all task types, just the ones we have special logic for in the UI\r\nexport enum TaskTypeID {\r\n ObtainDataEnterValueNotice = 1,\r\n FileAppeal = 6,\r\n ObtainHearingNotice = 7,\r\n ObtainDataEnterTaxBill = 11,\r\n ReviewPaymentDetails = 13,\r\n FilePPReturn = 21,\r\n TrackDataEnterRefund = 22,\r\n PrintApplication = 24,\r\n SubmitEvidence = 27,\r\n ObtainMagistrateRecommendation = 28,\r\n ObtainPaymentReceipt = 29,\r\n ObtainFinalDecision = 30,\r\n FileMiscFiling = 33,\r\n FileFreeport = 38,\r\n FileAbatement = 39,\r\n FilePollutionControl = 40,\r\n ObtainPostDeterminationValueNotice = 42,\r\n ConfirmHearing = 54\r\n}\r\n\r\nexport interface EntityDeactivationValidation {\r\n canBeDeactivated: boolean;\r\n openAssessmentTaskCount: number;\r\n openFilingTaskCount: number;\r\n openTaxBillTaskCount: number;\r\n openPaymentBatchTaskCount: number;\r\n openInvoiceTaskCount: number;\r\n}","import { Injectable } from '@angular/core';\r\nimport { BillClusterService, BillViewModel } from '../../../../Annual-Details/Taxes/bill-cluster.service';\r\nimport { Payment } from '../../../../Annual-Details/Taxes/payment.model';\r\n\r\nimport * as moment from 'moment/moment';\r\nimport { cloneDeep, every, filter, find, findIndex, flatMap, isNumber, minBy, reduce, some } from 'lodash';\r\n\r\nimport DetailsInstallmentMessageItem = Weissman.Model.Workflow.DocumentIntake.OcrResponse.Message.DetailsInstallmentMessageItem;\r\nimport { Bill } from 'src/app/Annual-Details/Taxes/bill.model';\r\nimport { AssessmentViewModel } from 'src/app/Annual-Details/Assessments/assessment.service';\r\nimport { AssessmentComponent } from 'src/app/Annual-Details/Assessments/assessment.component';\r\nimport { PropertyType } from 'src/app/constants.new';\r\n\r\ninterface PostMappingFlags {\r\n disableApplyAll: boolean;\r\n lowerConfidence: boolean;\r\n}\r\n\r\nconst IMPS_ASSESSMENT_COMPONENT_ID = 2;\r\nconst PP_ASSESSMENT_COMPONENT_ID = 4;\r\nconst OTHER_ASSESSMENT_COMPONENT_ID = 3;\r\nconst EXEM_ASSESSMENT_COMPONENT_ID = 5;\r\n\r\nconst NORMAL_COMPONENT_TYPE = 1;\r\nconst EXEM_COMPONENT_TYPE = 2;\r\n\r\nconst PROP_TYPE_COMP_MAP = {\r\n [PropertyType.RealEstate]: IMPS_ASSESSMENT_COMPONENT_ID,\r\n [PropertyType.Personal]: PP_ASSESSMENT_COMPONENT_ID,\r\n [PropertyType.Mineral]: OTHER_ASSESSMENT_COMPONENT_ID,\r\n [PropertyType.CentrallyAssessed]: OTHER_ASSESSMENT_COMPONENT_ID\r\n}\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class IdpService {\r\n\r\n constructor(private readonly _billClusterService: BillClusterService) { }\r\n\r\n billAmountDoesntAddUp(billDetail: BillViewModel, idpResults: Weissman.Model.Workflow.DocumentIntake.OcrResponse.API.TaxBillAPIResponse): boolean {\r\n const billDetailCopy = cloneDeep(billDetail);\r\n\r\n return some(billDetailCopy.model, bill => {\r\n this._mapBillFromIdp(bill, idpResults);\r\n\r\n const grossPaymentSum = reduce(bill.payments, (sum, payment) =>\r\n new Decimal(sum).plus(payment.grossPayment).toNumber(),\r\n 0);\r\n\r\n return bill.billAmount !== grossPaymentSum;\r\n });\r\n }\r\n\r\n isDueDateMismatch(billDetail: BillViewModel, installments: Weissman.Model.Workflow.DocumentIntake.OcrResponse.API.InstallmentAPIItem[]): boolean {\r\n return some(billDetail.model, bill => {\r\n const { installment, discountIndex } = this._getInstallmentAndDiscountIdx(installments, bill);\r\n\r\n return some(bill.payments, (payment: Payment, pmtIdx: number) => {\r\n const ocrPayment = installment?.details[pmtIdx];\r\n const possibleDueDate = ocrPayment?.discount[discountIndex]?.dueDate || ocrPayment?.dueDate;\r\n // If there is a payment due date, but it's not the same as the possible one\r\n // Do not overwrite, and lower the confidence\r\n return payment.dueDate && !moment(possibleDueDate).isSame(moment(payment.dueDate));\r\n });\r\n });\r\n }\r\n\r\n isMissingPaymentDueDate(installments: Weissman.Model.Workflow.DocumentIntake.OcrResponse.API.InstallmentAPIItem[]): boolean {\r\n return some(installments, installment => {\r\n if (!installment.details.length) {\r\n return true;\r\n }\r\n\r\n return some(installment.details, detail =>\r\n !detail.dueDate && every(detail.discount, x => !x.dueDate)\r\n );\r\n });\r\n }\r\n\r\n mapBillVMFromIDP(billVM: BillViewModel, idpResults: Weissman.Model.Workflow.DocumentIntake.OcrResponse.API.TaxBillAPIResponse): void {\r\n billVM.model.forEach(bill => this._mapBillFromIdp(bill, idpResults));\r\n }\r\n\r\n getDiscount(ocrPayment: DetailsInstallmentMessageItem, discountIndex: number): number {\r\n const discount = ocrPayment?.discount[discountIndex];\r\n\r\n if (discount?.discountAmount) {\r\n return discount?.discountAmount;\r\n } else if (discount?.netAmount && ocrPayment.amount) {\r\n return new Decimal(ocrPayment.amount).minus(discount?.netAmount ?? 0).toNumber();\r\n } else {\r\n return 0;\r\n }\r\n }\r\n\r\n async mapAssessmentVMFromIDP(\r\n assessmentVM: AssessmentViewModel,\r\n {\r\n appealDeadline,\r\n assessedValue,\r\n fairMarketValue,\r\n exemptions\r\n }: Weissman.Model.Workflow.DocumentIntake.Idp.Assessment.AssessmentRevisionItem,\r\n assessmentChild: AssessmentComponent,\r\n force?: boolean\r\n ): Promise {\r\n assessmentVM.currentYear.calcProjected = false;\r\n assessmentVM.model.appealDeadline = appealDeadline ?? assessmentVM.model.appealDeadline;\r\n\r\n let postMappingFlags = {\r\n disableApplyAll: false,\r\n lowerConfidence: false\r\n }\r\n\r\n const propertyTypeId: number = assessmentVM.components[0]?.propertyTypeID ?? 0;\r\n const enabledComponents = assessmentVM.components.filter(x => x.enabled)\r\n const { idpComponents, valueStr } = assessedValue?.components.length\r\n ? { idpComponents: assessedValue.components, valueStr: 'av' }\r\n : { idpComponents: fairMarketValue?.components, valueStr: 'fairMarketValue' }\r\n\r\n const nonZeroIdpComponents = filter(idpComponents, x => x.amount)\r\n\r\n if(force) {\r\n if (isNumber(assessedValue?.amount)) {\r\n await this._divvyUpIdpTotal(\r\n assessedValue.amount,\r\n assessmentVM,\r\n enabledComponents,\r\n assessmentChild,\r\n 'av',\r\n 'assessedValue',\r\n propertyTypeId,\r\n NORMAL_COMPONENT_TYPE\r\n )\r\n } else if (isNumber(fairMarketValue?.amount)) {\r\n await this._divvyUpIdpTotal(\r\n fairMarketValue.amount,\r\n assessmentVM,\r\n enabledComponents,\r\n assessmentChild,\r\n 'fairMarketValue',\r\n 'fairMarketValue',\r\n propertyTypeId,\r\n NORMAL_COMPONENT_TYPE\r\n )\r\n }\r\n\r\n if (nonZeroIdpComponents?.length) {\r\n await this._mapComponents(\r\n nonZeroIdpComponents,\r\n valueStr,\r\n assessmentVM,\r\n assessmentChild,\r\n enabledComponents,\r\n assessedValue?.amount,\r\n force\r\n );\r\n }\r\n } else {\r\n if (nonZeroIdpComponents?.length) {\r\n postMappingFlags = await this._mapComponents(\r\n nonZeroIdpComponents,\r\n valueStr,\r\n assessmentVM,\r\n assessmentChild,\r\n enabledComponents,\r\n assessedValue?.amount\r\n );\r\n } else if (isNumber(assessedValue?.amount)) {\r\n postMappingFlags.disableApplyAll = await this._divvyUpIdpTotal(\r\n assessedValue.amount,\r\n assessmentVM,\r\n enabledComponents,\r\n assessmentChild,\r\n 'av',\r\n 'assessedValue',\r\n propertyTypeId,\r\n NORMAL_COMPONENT_TYPE\r\n )\r\n } else if (isNumber(fairMarketValue?.amount)) {\r\n postMappingFlags.disableApplyAll = await this._divvyUpIdpTotal(\r\n fairMarketValue.amount,\r\n assessmentVM,\r\n enabledComponents,\r\n assessmentChild,\r\n 'fairMarketValue',\r\n 'fairMarketValue',\r\n propertyTypeId,\r\n NORMAL_COMPONENT_TYPE\r\n )\r\n }\r\n }\r\n\r\n const nonZeroIdpExemComponents = filter(exemptions[0]?.components ?? [], x => x.amount)\r\n\r\n if (nonZeroIdpExemComponents.length) {\r\n postMappingFlags = await this._mapComponents(\r\n nonZeroIdpExemComponents,\r\n 'av',\r\n assessmentVM,\r\n assessmentChild,\r\n enabledComponents,\r\n assessedValue?.amount\r\n );\r\n } else if (isNumber(exemptions[0]?.amount)) {\r\n postMappingFlags.disableApplyAll = await this._divvyUpIdpTotal(\r\n exemptions[0].amount,\r\n assessmentVM,\r\n enabledComponents,\r\n assessmentChild,\r\n 'av',\r\n 'assessedValue',\r\n propertyTypeId,\r\n EXEM_COMPONENT_TYPE\r\n )\r\n }\r\n\r\n return postMappingFlags\r\n }\r\n\r\n private async _mapComponents(\r\n idpComponents:Weissman.Model.Workflow.DocumentIntake.Idp.Assessment.ComponentItem[],\r\n valueStr: string,\r\n assessmentVM: AssessmentViewModel,\r\n assessmentChild: AssessmentComponent,\r\n enabledComponents: any[],\r\n assessedValueAmount: number | undefined,\r\n force?: boolean\r\n ): Promise {\r\n\r\n let disableApplyAll = false;\r\n let lowerConfidence = false;\r\n\r\n for (const idpComponent of idpComponents) {\r\n const inUseComponent = find(assessmentVM.model.annualAssessmentDetails, {\r\n componentName: idpComponent.name\r\n })\r\n \r\n if (inUseComponent) {\r\n const fmvAddsUp = new Decimal(assessedValueAmount ?? inUseComponent.assessedValue)\r\n .dividedBy(idpComponent.amount)\r\n .equals(inUseComponent.ratio)\r\n\r\n if(valueStr === 'fairMarketValue' && !fmvAddsUp) {\r\n if(force) {\r\n inUseComponent.fairMarketValue = idpComponent.amount\r\n inUseComponent.fmvOverridden = true\r\n } else {\r\n lowerConfidence = true;\r\n }\r\n } else {\r\n assessmentChild.calculate(valueStr, inUseComponent, idpComponent.amount)\r\n }\r\n } else {\r\n const availableComponent = find(enabledComponents, {\r\n componentName: idpComponent.name\r\n })\r\n\r\n if (availableComponent) {\r\n await assessmentChild.addRow(availableComponent, { [valueStr]: idpComponent.amount }, assessmentVM)\r\n } else {\r\n disableApplyAll = true;\r\n }\r\n }\r\n }\r\n\r\n assessmentVM.model.annualAssessmentDetails = filter(assessmentVM.model.annualAssessmentDetails, x => {\r\n return some(idpComponents, { name: x.componentName })\r\n })\r\n\r\n return { disableApplyAll, lowerConfidence }\r\n }\r\n\r\n private async _divvyUpIdpTotal(\r\n totalAmount: number,\r\n assessmentVM: AssessmentViewModel,\r\n enabledComponents: any[],\r\n assessmentChild: AssessmentComponent,\r\n calculateStr: string,\r\n componentStr: string,\r\n propertyTypeId: number,\r\n componentType: number\r\n ): Promise {\r\n let disableApplyAll = false;\r\n // filter by component type (either normal or Exem)\r\n const componentsOfCertainType = filter(assessmentVM.model.annualAssessmentDetails, {\r\n assessmentComponentTypeID: componentType\r\n })\r\n\r\n switch (componentsOfCertainType.length) {\r\n case 0:\r\n let propTypeComponent;\r\n\r\n if (componentType === NORMAL_COMPONENT_TYPE) {\r\n // if there are no current components, add component based on property type and apply total to that\r\n propTypeComponent = find(enabledComponents, {\r\n assessmentComponentID: PROP_TYPE_COMP_MAP[propertyTypeId]\r\n })\r\n } else {\r\n propTypeComponent = find(enabledComponents, {\r\n assessmentComponentID: EXEM_ASSESSMENT_COMPONENT_ID\r\n })\r\n }\r\n\r\n if (propTypeComponent) {\r\n await assessmentChild.addRow(propTypeComponent, { [calculateStr]: totalAmount }, assessmentVM)\r\n } else {\r\n // there is no enabled prop type component. Unclear what to do\r\n disableApplyAll = true\r\n }\r\n break;\r\n\r\n case 1:\r\n // if there is only one component existing in the assessment revision map the total value from IDP to that component. \r\n assessmentChild.calculate(calculateStr, componentsOfCertainType[0], totalAmount);\r\n break;\r\n\r\n default:\r\n if (propertyTypeId === PropertyType.RealEstate && componentType === NORMAL_COMPONENT_TYPE) {\r\n // If there are two or more components existing in the assessment revision and one is \"Land\", \r\n // keep land the same value and make the other components (normally just Imps) = Total from IDP - the value on Land. \r\n const landComponent = find(componentsOfCertainType, {\r\n componentName: 'Land'\r\n })\r\n\r\n if (landComponent) {\r\n const totalMinusLand = new Decimal(totalAmount)\r\n .minus(landComponent[componentStr] ?? 0)\r\n .toNumber();\r\n\r\n if (totalMinusLand >= 0) {\r\n const dividedLeftoverAmountWholeNumber = new Decimal(totalMinusLand)\r\n .dividedBy(componentsOfCertainType.length - 1)\r\n .floor()\r\n .toNumber()\r\n\r\n let remainder = totalMinusLand % (componentsOfCertainType.length - 1)\r\n\r\n componentsOfCertainType.forEach(component => {\r\n let remainderToAdd = 0\r\n if (remainder > 0) {\r\n remainder--\r\n remainderToAdd++\r\n }\r\n if (component.componentName !== 'Land') {\r\n assessmentChild.calculate(calculateStr, component, new Decimal(dividedLeftoverAmountWholeNumber).add(remainderToAdd).toNumber())\r\n }\r\n })\r\n } else {\r\n // If somehow the Land > Total from IDP then do nothing. \r\n disableApplyAll = true\r\n }\r\n } else {\r\n // There is no land component. Unclear what to do\r\n disableApplyAll = true\r\n }\r\n } else {\r\n assessmentVM.model.annualAssessmentDetails = [];\r\n\r\n let propTypeComponent;\r\n\r\n if (componentType === NORMAL_COMPONENT_TYPE) {\r\n propTypeComponent = find(enabledComponents, {\r\n assessmentComponentID: PROP_TYPE_COMP_MAP[propertyTypeId]\r\n })\r\n } else {\r\n propTypeComponent = find(enabledComponents, {\r\n assessmentComponentID: EXEM_ASSESSMENT_COMPONENT_ID\r\n })\r\n }\r\n\r\n if (propTypeComponent) {\r\n await assessmentChild.addRow(propTypeComponent, { [calculateStr]: totalAmount }, assessmentVM)\r\n } else {\r\n // there is no enabled prop type component. Unclear what to do\r\n disableApplyAll = true\r\n }\r\n }\r\n\r\n break;\r\n }\r\n\r\n return disableApplyAll;\r\n }\r\n\r\n // private async _addOrApplyComponentValue(\r\n // availableComponent: any, \r\n // valueObj: ValueMessagePayload, \r\n // annualAssessmentDetails: AnnualAssessmentDetail[],\r\n // assessmentChild: AssessmentComponent,\r\n // valueStr: string\r\n // ): Promise {\r\n // const idpComponent = find(valueObj.components, {\r\n // name: availableComponent.componentName\r\n // })\r\n\r\n // if(isNumber(idpComponent?.amount)) {\r\n // const inUseComponent = find(annualAssessmentDetails, { \r\n // componentName: idpComponent.name \r\n // })\r\n\r\n // if(inUseComponent) {\r\n // assessmentChild.calculate(valueStr, inUseComponent, idpComponent.amount)\r\n // } else {\r\n // await assessmentChild.addRow(availableComponent, { [valueStr]: idpComponent.amount })\r\n // }\r\n // }\r\n // }\r\n\r\n private _mapBillFromIdp(bill: Bill, idpResults: Weissman.Model.Workflow.DocumentIntake.OcrResponse.API.TaxBillAPIResponse): void {\r\n if (bill.payments.length === 1 && !some(idpResults.installments, x => x.details.length === 1)) {\r\n const idpPayments = flatMap(idpResults.installments, 'details') as DetailsInstallmentMessageItem[];\r\n const idpPayment = minBy(idpPayments, x => new Date(x.dueDate));\r\n\r\n if (!idpPayment) return;\r\n\r\n bill.calcProjected = false;\r\n\r\n bill.billAmount = idpResults.totalAmount || 0;\r\n bill.directAsmt = idpResults.directAssessmentAmount || 0;\r\n\r\n bill.payments[0].dueDate = idpPayment.dueDate;\r\n bill.payments[0].grossPayment = idpResults.totalAmount;\r\n bill.payments[0].paymentAmount = this._billClusterService.paymentPropChanged(bill.payments[0]);\r\n\r\n return;\r\n }\r\n\r\n bill.billAmount = idpResults.totalAmount || 0;\r\n bill.directAsmt = idpResults.directAssessmentAmount || 0;\r\n\r\n const { installment, discountIndex } = this._getInstallmentAndDiscountIdx(idpResults.installments, bill);\r\n\r\n bill.payments.forEach((payment: Payment, pmtIdx: number) => {\r\n const ocrPayment = installment?.details[pmtIdx];\r\n\r\n if (!ocrPayment) return;\r\n\r\n bill.calcProjected = false;\r\n\r\n payment.dueDate = ocrPayment?.discount[discountIndex]?.dueDate || ocrPayment.dueDate;\r\n payment.grossPayment = ocrPayment?.amount || 0;\r\n payment.discountAmount = -this.getDiscount(ocrPayment, discountIndex);\r\n payment.interestAmount = ocrPayment?.interest[discountIndex]?.interestAmount || 0;\r\n payment.penaltyAmount = ocrPayment?.penalty[discountIndex]?.penaltyAmount || 0;\r\n\r\n payment.paymentAmount = this._billClusterService.paymentPropChanged(payment);\r\n });\r\n }\r\n\r\n private _getInstallmentAndDiscountIdx(installments: Weissman.Model.Workflow.DocumentIntake.OcrResponse.API.InstallmentAPIItem[], bill: Bill): {\r\n installment: Weissman.Model.Workflow.DocumentIntake.OcrResponse.API.InstallmentAPIItem,\r\n discountIndex: number\r\n } {\r\n const installment = installments.find(x => x.details.length === bill.payments.length);\r\n let discountIndex = 0;\r\n\r\n if (bill.payments.length === 1) {\r\n const ocrPayment = installment?.details.find(x => moment(x.dueDate).isSame(moment(bill.payments[0].dueDate)));\r\n discountIndex = ocrPayment?.discount.findIndex(x => x.dueDate === bill.payments[0].dueDate) || 0;\r\n }\r\n\r\n return { installment, discountIndex };\r\n }\r\n\r\n // private _getDirectAssessment(idpResults: Core.TaxBillPushMessageDto): number {\r\n // if(idpResults.directAssessmentAmount) {\r\n // return idpResults.directAssessmentAmount;\r\n // } else {\r\n // return reduce(idpResults.taxAuthorities, (sum, ta) => {\r\n // if(!ta.taxRate) {\r\n // sum += ta.taxAmount;\r\n // }\r\n\r\n // return sum;\r\n // }, 0);\r\n // }\r\n // }\r\n}\r\n","
\r\n
\r\n

{{detail.title}}

\r\n
\r\n
\r\n
\r\n {{detail.total.name}}\r\n {{detail.total.value | currency: 'USD':'symbol'}}\r\n
\r\n
\r\n \r\n
\r\n {{item.name}}\r\n {{item.value}}\r\n {{item.value | currency: 'USD':'symbol'}}\r\n {{item.value | weissmanDateFormat: true}}\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input } from '@angular/core';\r\n\r\ninterface IdpCardDetail {\r\n name: string;\r\n value: any;\r\n type?: string;\r\n}\r\n\r\nexport interface IdpCard {\r\n title: string;\r\n total: IdpCardDetail;\r\n details: IdpCardDetail[];\r\n}\r\n\r\n@Component({\r\n selector: 'idp-detail-card',\r\n templateUrl: './idpDetailCard.component.html',\r\n styleUrls: ['./idpDetailCard.component.scss']\r\n})\r\nexport class IdpDetailCardComponent {\r\n @Input() detail: IdpCard;\r\n}\r\n","\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { AfterViewInit, Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BillClusterService, BillViewModel } from '../../../../../Annual-Details/Taxes/bill-cluster.service';\r\nimport { Bill } from '../../../../../Annual-Details/Taxes/bill.model';\r\nimport { IWeissmanModalComponent } from '../../../../../Compliance/WeissmanModalService';\r\nimport { IdpService } from '../idp.service';\r\nimport { IdpCard } from './Card/idpDetailCard.component';\r\n\r\nimport * as moment from 'moment';\r\n\r\nimport DetailsInstallmentMessageItem = Weissman.Model.Workflow.DocumentIntake.OcrResponse.Message.DetailsInstallmentMessageItem;\r\nimport { flatMap, minBy, some } from 'lodash';\r\nimport { Payment } from 'src/app/Annual-Details/Taxes/payment.model';\r\nimport { ProductAnalyticsService } from 'src/app/Common/Amplitude/productAnalytics.service';\r\n\r\nexport interface IdpBillDetailModalParams {\r\n confidence: string;\r\n idpResults: Weissman.Model.Workflow.DocumentIntake.OcrResponse.API.TaxBillAPIResponse;\r\n billDetail: BillViewModel;\r\n disableApplyAll: boolean\r\n}\r\n\r\n@Component({\r\n selector: 'idp-bill-detail-modal',\r\n templateUrl: './idpBillDetailModal.component.html',\r\n styleUrls: ['./idpBillDetailModal.component.scss']\r\n})\r\nexport class IdpBillDetailModalComponent implements OnInit, AfterViewInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _billClusterService: BillClusterService,\r\n private readonly _idpService: IdpService) {\r\n }\r\n\r\n params: IdpBillDetailModalParams;\r\n result: Bill[];\r\n\r\n billCard: IdpCard;\r\n payments: IdpCard[] = [];\r\n\r\n // todo update the value keys once we know the correct values\r\n private _cardValues = [\r\n { name: 'Base Pay Amt', field: 'grossPayment', type: 'currency' },\r\n { name: 'Discount Amt', field: 'discountAmount', type: 'currency' },\r\n { name: 'Interest', field: 'interestAmount', type: 'currency' },\r\n { name: 'Penalty', field: 'penaltyAmount', type: 'currency' },\r\n { name: 'Due Date', field: 'dueDate', type: 'date' }\r\n ];\r\n\r\n private _billDetail: BillViewModel;\r\n private _idpResults: Weissman.Model.Workflow.DocumentIntake.OcrResponse.API.TaxBillAPIResponse;\r\n\r\n get title(): string {\r\n return `Detected Values: ${this.params?.confidence} Confidence`;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._billDetail = this.params.billDetail;\r\n this._idpResults = this.params.idpResults;\r\n\r\n const bill = this._billDetail.model[0];\r\n\r\n this.billCard = {\r\n title: 'Bill',\r\n total: { name: 'Bill Amt', value: this._idpResults.totalAmount },\r\n details: [\r\n // { name: 'Assoc. Revision', value: this._getAssocRevisionDesc(bill), type: 'string' },\r\n // { name: 'Payment Option', value: this._getBillPaymentOptionName(bill), type: 'string' }\r\n { name: 'Direct Asmt', value: this._idpResults.directAssessmentAmount || 0, type: 'currency'}\r\n ]\r\n };\r\n\r\n // If the PropertyPoint bill has one payment and there is no canonical installment for just one payment,\r\n // use the canonical bill's totalAmount due and the earliest payment's due date within the canonical bill.\r\n // This is basically paying the full amount due by the first payment due date.\r\n if(bill.payments.length === 1 && !some(this._idpResults.installments, x => x.details.length === 1)) {\r\n const idpPayments = flatMap(this._idpResults.installments, 'details') as DetailsInstallmentMessageItem[];\r\n const idpPayment = minBy(idpPayments, x => new Date(x.dueDate));\r\n\r\n if(!idpPayment) return;\r\n\r\n bill.payments[0].dueDate = idpPayment.dueDate;\r\n bill.payments[0].grossPayment = this._idpResults.totalAmount;\r\n bill.payments[0].paymentAmount = this._billClusterService.paymentPropChanged(bill.payments[0]);\r\n\r\n this.payments = [{\r\n title: 'Payment 1 of 1',\r\n total: { name: 'Payment Amt', value: bill.payments[0].paymentAmount },\r\n details: [{\r\n name: 'Base Pay Amt', value: this._idpResults.totalAmount, type: 'currency'\r\n }, {\r\n name: 'Due Date', value: idpPayment.dueDate, type: 'date'\r\n }]\r\n }];\r\n\r\n return;\r\n }\r\n\r\n\r\n const installment = this._idpResults.installments.find(x => x.details.length === bill.payments.length);\r\n let discountIndex = 0;\r\n if (bill.payments.length === 1) {\r\n // if bill payment has one payment, find installment with one detail\r\n // find the payment that matches the due date\r\n const payment = installment?.details.find(x => moment(x.dueDate).isSame(moment(bill.payments[0].dueDate)));\r\n discountIndex = payment?.discount.findIndex(x => x.dueDate === bill.payments[0].dueDate) || 0;\r\n }\r\n // if the bill payment option has multiple payments, find the installment with the same number of details\r\n // we need to show all the payments available, regardless of due date\r\n bill.payments.forEach((payment: Payment, pmtIdx: number) => {\r\n const ocrPayment = installment?.details[pmtIdx];\r\n\r\n if(!ocrPayment) return;\r\n\r\n payment.grossPayment = ocrPayment?.amount || 0;\r\n payment.discountAmount = -this._idpService.getDiscount(ocrPayment, discountIndex);\r\n payment.interestAmount = ocrPayment?.interest[discountIndex]?.interestAmount || 0;\r\n payment.penaltyAmount = ocrPayment?.penalty[discountIndex]?.penaltyAmount || 0;\r\n payment.dueDate = ocrPayment?.discount[discountIndex]?.dueDate || ocrPayment.dueDate;\r\n\r\n payment.paymentAmount = this._billClusterService.paymentPropChanged(payment);\r\n\r\n this.payments.push({\r\n title: `Payment ${pmtIdx + 1} of ${installment.details.length}`,\r\n total: { name: 'Payment Amt', value: payment.paymentAmount },\r\n details: this._cardValues.map(card => {\r\n return { name: card.name, value: payment[card.field], type: card.type };\r\n })\r\n });\r\n });\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n const modalContainer = document.querySelector('modal-container');\r\n if (modalContainer) {\r\n modalContainer.classList.add('no-modal-backdrop');\r\n }\r\n }\r\n\r\n applyAll(): void {\r\n this._productAnalyticsService.logEvent('apply-detected-values', { OcrApplyAll: 'Apply' });\r\n this._idpService.mapBillVMFromIDP(this._billDetail, this._idpResults);\r\n\r\n this.result = this._billDetail.model;\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._productAnalyticsService.logEvent('apply-detected-values', { OcrApplyAll: 'Cancel' });\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _getAssocRevisionDesc(bill: Bill): string {\r\n const yearRevision = this.params.billDetail.yearRevisions.find(x => x.annualAssessmentID === bill.annualAssessmentID);\r\n\r\n return yearRevision?.revisionDesc || '';\r\n }\r\n\r\n private _getBillPaymentOptionName(bill: Bill): string {\r\n if (!bill.collectorPaymentOptionID || !bill.collectorPaymentOptions) {\r\n return '';\r\n } else if (bill.collectorPaymentOptions.length === 0) {\r\n return bill.collectorPaymentOption.name || 'N/A';\r\n }\r\n\r\n const option = bill.collectorPaymentOptions.find(x => x.collectorPaymentOptionID === bill.collectorPaymentOptionID);\r\n\r\n return option?.name || 'N/A';\r\n }\r\n}\r\n","\r\n
\r\n
Appeal Deadline: {{appealDeadline | date:'M/d/yyyy':'utc'}}
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n {{ col.name }}\r\n
\r\n
\r\n {{row.type}}\r\n
\r\n
\r\n
\r\n {{row.name}}\r\n
\r\n
\r\n
\r\n {{row.av | currency:'USD':'symbol':'1.0-0'}}\r\n
\r\n
\r\n
\r\n {{row.ratio}}\r\n
\r\n
\r\n
\r\n {{row.fmv | currency:'USD':'symbol':'1.0-0'}}\r\n
\r\n
\r\n
\r\n
\r\n","import { AfterViewInit, Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../../Compliance/WeissmanModalService';\r\nimport { IdpService } from '../idp.service';\r\nimport { ProductAnalyticsService } from 'src/app/Common/Amplitude/productAnalytics.service';\r\nimport { assign, chain, forEach, isNumber, isUndefined, map } from 'lodash';\r\nimport { AssessmentViewModel } from 'src/app/Annual-Details/Assessments/assessment.service';\r\nimport { AssessmentComponent } from 'src/app/Annual-Details/Assessments/assessment.component';\r\n\r\nexport interface IdpAssessmentDetailModalParams {\r\n confidence: string;\r\n idpResults: Weissman.Model.Workflow.DocumentIntake.Idp.Assessment.TaxAssessmentAPIResponse;\r\n assessmentVM: AssessmentViewModel;\r\n disableApplyAll: boolean;\r\n assessmentChild: AssessmentComponent\r\n}\r\n\r\ntype ComponentRow = {\r\n name: string;\r\n av: number;\r\n ratio: number\r\n fmv: number;\r\n type: string;\r\n}\r\n\r\n@Component({\r\n selector: 'idp-assessment-detail-modal',\r\n templateUrl: './idpAssessmentDetailModal.component.html',\r\n styleUrls: ['./idpAssessmentDetailModal.component.scss']\r\n})\r\nexport class IdpAssessmentDetailModalComponent implements OnInit, AfterViewInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _idpService: IdpService) {\r\n }\r\n\r\n params: IdpAssessmentDetailModalParams;\r\n result: AssessmentViewModel;\r\n\r\n tableColumns = [{\r\n name: 'Component Type',\r\n }, {\r\n name: 'Component'\r\n }, {\r\n name: 'Assessed Value',\r\n isNum: true\r\n }, {\r\n name: 'Ratio',\r\n isNum: true\r\n },{\r\n name: 'FM Value',\r\n isNum: true\r\n }]\r\n rows: {\r\n // type: string;\r\n // total: number;\r\n // components: {\r\n name: string;\r\n av: number;\r\n ratio: number\r\n fmv: number;\r\n type: string;\r\n // }[]\r\n }[]\r\n hoveredRow: ComponentRow\r\n appealDeadline: Date;\r\n\r\n private _assessmentVM: AssessmentViewModel;\r\n private _assessmentRevision: Weissman.Model.Workflow.DocumentIntake.Idp.Assessment.AssessmentRevisionItem;\r\n\r\n get title(): string {\r\n return `Detected Values: ${this.params?.confidence} Confidence`;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._assessmentVM = this.params.assessmentVM;\r\n this._assessmentRevision = this.params.idpResults.assessmentRevision;\r\n\r\n this.appealDeadline = this._assessmentRevision.appealDeadline\r\n\r\n const avComponents = chain(this._assessmentRevision.assessedValue?.components ?? [])\r\n .filter('amount')\r\n .map(x => ({\r\n name: x.name,\r\n av: x.amount\r\n }))\r\n .value()\r\n\r\n const fmvComponents = chain(this._assessmentRevision.fairMarketValue?.components ?? [])\r\n .filter('amount')\r\n .map(x => ({\r\n name: x.name,\r\n fmv: x.amount\r\n }))\r\n .value()\r\n\r\n const ratioComponents = chain(this._assessmentRevision.components ?? [])\r\n .filter('ratio')\r\n .map(x => ({\r\n name: x.componentName,\r\n ratio: x.ratio\r\n }))\r\n .value()\r\n\r\n this.rows = chain([...avComponents, ...fmvComponents, ...ratioComponents])\r\n .groupBy('name')\r\n .map((vallArra, componentName) => {\r\n const comp = {\r\n name: componentName,\r\n type: 'Normal'\r\n }\r\n\r\n forEach(vallArra, val => {\r\n assign(comp, val)\r\n })\r\n\r\n return comp\r\n })\r\n .value() as any[]\r\n\r\n const fmvTotal = this.rows.reduce((total, comp) =>\r\n isUndefined(comp.fmv) ? null : total += comp.fmv,\r\n 0)\r\n const avTotal = this.rows.reduce((total, comp) =>\r\n isUndefined(comp.av) ? null : total += comp.av,\r\n 0)\r\n\r\n const totalRow = {\r\n type: 'Total',\r\n name: '',\r\n ratio: null,\r\n fmv: fmvTotal || null,\r\n av: avTotal || null,\r\n }\r\n\r\n if (this._assessmentRevision.assessedValue?.components.length === 0\r\n && this._assessmentRevision.assessedValue?.amount) {\r\n totalRow.av = this._assessmentRevision.assessedValue.amount\r\n }\r\n\r\n if (this._assessmentRevision.fairMarketValue?.components.length === 0\r\n && this._assessmentRevision.fairMarketValue?.amount) {\r\n totalRow.fmv = this._assessmentRevision.fairMarketValue.amount\r\n }\r\n\r\n this.rows.push(totalRow)\r\n\r\n const exemRows = chain(this._assessmentRevision.exemptions[0]?.components ?? [])\r\n .filter('amount')\r\n .map(x => ({\r\n type: 'Exem',\r\n name: x.name,\r\n av: x.amount,\r\n ratio: null,\r\n fmv: null\r\n }))\r\n .value()\r\n\r\n if (this._assessmentRevision.exemptions[0]?.components.length === 0\r\n && this._assessmentRevision.exemptions[0]?.amount) {\r\n exemRows.push({\r\n type: 'Exem',\r\n name: 'Exem',\r\n av: this._assessmentRevision.exemptions[0].amount,\r\n ratio: null,\r\n fmv: null\r\n })\r\n }\r\n\r\n const exemTotal = exemRows.reduce((total, comp) =>\r\n isUndefined(comp.av) ? null : total += comp.av,\r\n 0)\r\n\r\n const exemTotalRow = {\r\n type: 'Total',\r\n name: '',\r\n ratio: null,\r\n fmv: null,\r\n av: avTotal - exemTotal,\r\n }\r\n\r\n\r\n if(exemTotalRow.av) {\r\n this.rows[this.rows.length - 1].name = 'Pre Adj Total'\r\n exemRows.push(exemTotalRow)\r\n }\r\n\r\n this.rows = [...this.rows, ...exemRows]\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n const modalContainer = document.querySelector('modal-container');\r\n if (modalContainer) {\r\n modalContainer.classList.add('no-modal-backdrop');\r\n }\r\n }\r\n\r\n applyAll(): void {\r\n this._productAnalyticsService.logEvent('apply-detected-values', { OcrApplyAll: 'Apply' });\r\n this._idpService.mapAssessmentVMFromIDP(this._assessmentVM, this._assessmentRevision, this.params.assessmentChild, true);\r\n this.result = this._assessmentVM;\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._productAnalyticsService.logEvent('apply-detected-values', { OcrApplyAll: 'Cancel' });\r\n\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","
\r\n
\r\n

OCR Detected Values

\r\n
\r\n
\r\n
\r\n
\r\n \r\n {{confidenceLevel}}\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Inject, Input, Output } from '@angular/core';\r\nimport { ModalOptions } from 'ngx-bootstrap/modal';\r\nimport { BillViewModel } from '../../../../Annual-Details/Taxes/bill-cluster.service';\r\nimport { Bill } from '../../../../Annual-Details/Taxes/bill.model';\r\nimport { WeissmanModalService } from '../../../../Compliance/WeissmanModalService';\r\nimport { IdpBillDetailModalComponent, IdpBillDetailModalParams } from './Detail-Modal/idpBillDetailModal.component';\r\nimport { cloneDeep, omit, pick, some } from 'lodash';\r\nimport { IdpService } from './idp.service';\r\nimport { ProductAnalyticsService } from 'src/app/Common/Amplitude/productAnalytics.service';\r\nimport { AssessmentViewModel } from 'src/app/Annual-Details/Assessments/assessment.service';\r\nimport { IdpAssessmentDetailModalComponent, IdpAssessmentDetailModalParams } from './Detail-Modal/idpAssessmentDetailModal.component';\r\nimport { AssessmentComponent } from 'src/app/Annual-Details/Assessments/assessment.component';\r\n\r\n@Component({\r\n selector: 'idp-confidence-panel',\r\n templateUrl: './idpConfidencePanel.component.html',\r\n styleUrls: ['./idpConfidencePanel.component.scss']\r\n})\r\nexport class IdpConfidencePanelComponent {\r\n constructor(\r\n private readonly _weissmanModalService: WeissmanModalService,\r\n private readonly _idpService: IdpService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n\t\t@Inject('$scope') private _scope: any\r\n ) {\r\n _scope.$on('changeProcessingDocument', () => {\r\n this.canSeeDetails = true;\r\n });\r\n }\r\n\r\n @Input() currentDocument: Core.IntakeItemInfo;\r\n @Input() billDetail: BillViewModel;\r\n @Input() billAmountDoesntAddUp: boolean;\r\n @Input() assessmentDetail: AssessmentViewModel\r\n @Input() assessmentChild: AssessmentComponent;\r\n @Input() disableAssessmentApplyAll: boolean;\r\n\r\n @Output() idpAcceptedAssessmentDetail: EventEmitter = new EventEmitter();\r\n @Output() idpAcceptedBill: EventEmitter = new EventEmitter();\r\n\r\n canSeeDetails = true;\r\n\r\n private _originalBillDetail: Bill[];\r\n private _originalAssessmentDetail: AssessmentViewModel;\r\n\r\n get confidenceLevel(): 'Low' | 'Medium' | 'High' {\r\n if(this.currentDocument.idpConfidence) {\r\n return this.currentDocument.idpConfidence <= 0.3 ? 'Low'\r\n : this.currentDocument.idpConfidence <= 0.3 ? 'Medium'\r\n : 'High';\r\n } else {\r\n return 'Low';\r\n }\r\n }\r\n\r\n seeDetails(): void {\r\n this._productAnalyticsService.logEvent('click-see-details');\r\n if(this.billDetail) {\r\n this._seeBillDetails()\r\n } else if(this.assessmentDetail) {\r\n this._seeAssessmentDetails();\r\n }\r\n }\r\n\r\n reset(): void {\r\n this._productAnalyticsService.logEvent('revert-applied-values');\r\n if(this.billDetail) {\r\n this.idpAcceptedBill.emit(this._originalBillDetail);\r\n } else if(this.assessmentDetail) {\r\n this.idpAcceptedAssessmentDetail.emit(this._originalAssessmentDetail);\r\n }\r\n this.canSeeDetails = true;\r\n }\r\n\r\n private async _seeBillDetails(): Promise {\r\n const disableApplyAll = this.billAmountDoesntAddUp\r\n || some(this.billDetail.model[0].payments, x => x.taskSummary?.TransmitComplete)\r\n || this._idpService.isMissingPaymentDueDate(this.currentDocument.taxBillOcrResults.installments);\r\n\r\n const params: IdpBillDetailModalParams = {\r\n confidence: this.confidenceLevel,\r\n idpResults: this.currentDocument.taxBillOcrResults,\r\n billDetail: cloneDeep(this.billDetail),\r\n disableApplyAll\r\n };\r\n\r\n const updatedBillModel = await this._weissmanModalService.showAsync(IdpBillDetailModalComponent, params, 'modal-lg');\r\n\r\n if (updatedBillModel) {\r\n this._originalBillDetail = structuredClone(this.billDetail.model);\r\n this.canSeeDetails = false;\r\n this.idpAcceptedBill.emit(updatedBillModel);\r\n }\r\n }\r\n\r\n private async _seeAssessmentDetails(): Promise {\r\n const disableApplyAll = this.assessmentDetail.isActual() || this.disableAssessmentApplyAll;\r\n\r\n const params: IdpAssessmentDetailModalParams = {\r\n confidence: this.confidenceLevel,\r\n idpResults: this.currentDocument.assessmentNoticeOcrResults,\r\n assessmentVM: cloneDeep(pick(this.assessmentDetail, ['components', 'model', 'currentYear'])) as AssessmentViewModel, // Needed to pick because object was too large and caused performance issues\r\n disableApplyAll,\r\n assessmentChild: this.assessmentChild\r\n };\r\n\r\n const updatedAssessmentVM = await this._weissmanModalService.showAsync(IdpAssessmentDetailModalComponent, params, 'modal-lg');\r\n\r\n if (updatedAssessmentVM) {\r\n const clonedAssessment = cloneDeep(omit(this.assessmentDetail, ['assessmentService', 'decimalPipe'])) as AssessmentViewModel // structedClone doesn't work on angular services\r\n this._originalAssessmentDetail = clonedAssessment;\r\n this.canSeeDetails = false;\r\n this.idpAcceptedAssessmentDetail.emit(updatedAssessmentVM);\r\n }\r\n }\r\n}\r\n","\r\n\r\n
\r\n
\r\n

Entity Edit

\r\n
\r\n
\r\n

\r\n The entity this document is associated with has changed since the association\r\n was made. You will not be able to complete this task until the entity is\r\n reloaded.\r\n

\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnChanges, SimpleChanges, Input, Output, EventEmitter, ViewChild } from '@angular/core';\r\nimport { AppealService, AppealViewModel } from '../../../Annual-Details/Appeals/appeal.service';\r\nimport { BillClusterService, BillViewModel, RefundViewModel } from '../../../Annual-Details/Taxes/bill-cluster.service';\r\nimport { Appeal } from '../../../Annual-Details/Appeals/appeal.model';\r\nimport { AnnualDetailEditState } from '../../../Annual-Details/annual-details-navigation.service';\r\nimport { Bill } from '../../../Annual-Details/Taxes/bill.model';\r\nimport { Refund } from '../../../Annual-Details/Taxes/refund.model';\r\nimport { AssessmentService, AssessmentViewModel } from '../../../Annual-Details/Assessments/assessment.service';\r\nimport { Assessment } from '../../../Annual-Details/Assessments/assessment.model';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\nimport { Task, TaskTypeID } from '../../../Task/Task.Model';\r\nimport { TaskService } from '../../../Task/task.service.upgrade';\r\nimport { AttachmentTypeID } from '../../../Attachment/attachment.model';\r\nimport { CommentModalData, CommentsService } from '../../../Comments/comments.service';\r\nimport { AttachmentModalData, AttachmentModalEntityData } from '../../../Attachment/attachment.modal.model';\r\nimport { ComplianceViewModel, ComplianceService } from '../../../Annual-Details/Compliance/compliance.service';\r\nimport { Filing } from '../../../Annual-Details/Compliance/compliance.model';\r\nimport { AnnualDetailAssessment } from '../../../Annual-Details/Annual-Year/annual-year.model';\r\nimport { UtilitiesService } from '../../../UI-Lib/Utilities';\r\nimport { BillClusterTaxRateSetupModalResult } from '../../../Entity/Parcel/TaxRateSetup/billClusterTaxRateSetupModal.component';\r\nimport { TaxSetupMinimumDTO, FirstEncounterSaveResult } from '../../../Entity/Parcel/TaxRateSetup/parcelTaxRateService';\r\nimport { AttachmentService } from 'src/app/Attachment/attachment.service';\r\nimport { IdpService } from './IDP/idp.service';\r\nimport { assign, cloneDeep, some } from 'lodash';\r\nimport { AssessmentComponent } from 'src/app/Annual-Details/Assessments/assessment.component';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\ndeclare const _: any;\r\n\r\n// TODO: Create a const system and reference these from there\r\nconst COMPANY_ENTITY_TYPE_ID = 1;\r\nconst SITE_ENTITY_TYPE_ID = 5;\r\nconst PARCEL_ENTITY_TYPE_ID = 6;\r\nconst ASSESSMENT_ENTITY_TYPE_ID = 7;\r\nconst APPEAL_ENTITY_TYPE_ID = 8;\r\nconst TAXBILL_ENTITY_TYPE_ID = 9;\r\nconst REFUND_ENTITY_TYPE_ID = 14;\r\nconst FILING_ENTITY_TYPE_ID = 10;\r\n\r\n// TODO: This definition is pretty generic and should probably be in a shared module somewhere\r\n// Also, the name 'EntityIdentifier' is questionable since ID is short for Identifier; by convention,\r\n// things named [thing]ID is usually a number, still... this is kinda awkward.\r\nexport class EntityIdentifier {\r\n entityId: number;\r\n entityTypeId: number;\r\n}\r\n\r\nexport interface DataEntryJSONHandler {\r\n retrieveDataEntryJSON: () => string;\r\n}\r\n\r\nexport interface ValidationHandler {\r\n validate: (boolean, string) => void;\r\n}\r\n\r\nexport class DataEntry {\r\n constructor(\r\n public entity: T,\r\n public attachmentDescription: string,\r\n public completeReadyTask: boolean,\r\n public useDocumentAsBillImage: boolean,\r\n public readyTaskID: number,\r\n public dataEntryChanged: boolean,\r\n public searchAnticipated: boolean,\r\n // This is a sort of dirty flag specifically for the complete task checkbox;\r\n // if the user has manually checked or unchecked it, we want to stop invoking\r\n // the checked or unchecked by default logic\r\n public completeReadyTaskChanged: boolean,\r\n public calcProjected: boolean,\r\n public taxSetup: BillClusterTaxRateSetupModalResult) {\r\n this.resetOnLoad = false;\r\n }\r\n\r\n // When the reload entity button is pressed, we want to wipe out\r\n // the entity object but leave everything else; use this property\r\n // as a flag to do that when the entity association is processed\r\n // (in all other circumstances should be false)\r\n resetOnLoad: boolean;\r\n // attachmentYear being present is actually the exception; it's\r\n // usually null for entities below parcel where it's implied by\r\n // the annual year, but for company/site/parcel it may be\r\n // specified\r\n attachmentYear: string;\r\n}\r\n\r\n// Appeals, assessments, bills, and refunds all have their own edit panels\r\n// that include comments and attachments; for company, site, and parcel\r\n// we need to add comments and attachments for document processing\r\nclass GenericEntityVM {\r\n hasComments: boolean;\r\n hasAttachments: boolean;\r\n commentModalData: CommentModalData;\r\n attachmentModalData: AttachmentModalData;\r\n}\r\n\r\n@Component({\r\n selector: 'processing-entity-edit',\r\n templateUrl: './entity-edit.component.html'\r\n})\r\nexport class EntityEditComponent implements OnInit, OnChanges {\r\n constructor(private readonly _appealService: AppealService,\r\n private readonly _billClusterService: BillClusterService,\r\n private readonly _assessmentService: AssessmentService,\r\n private readonly _taskService: TaskService,\r\n private readonly _commentsService: CommentsService,\r\n private readonly _attachmentService: AttachmentService,\r\n private readonly _complianceService: ComplianceService,\r\n private readonly _util: UtilitiesService,\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _idpService: IdpService) {\r\n this.warnOnEntityReloadChanged = new EventEmitter();\r\n this.populateYears();\r\n }\r\n\r\n @Input() intakeDocumentInfo: Core.IntakeItemInfo;\r\n @Input('dataEntryJson') dataEntryJSON: string;\r\n @Input() firstEncounterSavedCallback: (result: FirstEncounterSaveResult) => Promise;\r\n @Input() entityIdentifier: EntityIdentifier;\r\n @Input('attachmentId') attachmentID: string;\r\n @Input('dataEntryJsonHandler') dataEntryJSONHandler: DataEntryJSONHandler;\r\n @Input() validationHandler: ValidationHandler;\r\n @Input('attachmentTypeId') attachmentTypeID: number;\r\n @Input() setDirty: (boolean) => void;\r\n @Input('parcelId') parcelID: number;\r\n @Input() parcelAcctNum: string;\r\n @Input() companyName: string;\r\n @Input() companyId: number;\r\n @Input() siteName: string;\r\n @Input() intakeBatchItemNumber: string;\r\n @Input() stateId: number;\r\n @Output() warnOnEntityReloadChanged: EventEmitter;\r\n @Input() searchAnticipated: boolean;\r\n @Output() billRevisionChangedX: EventEmitter = new EventEmitter();\r\n @Input() associatedEntityChanged: boolean;\r\n @Input() parcelChanges: { newTaxSetup: TaxSetupMinimumDTO };\r\n\r\n @ViewChild('assessmentChild') assessmentChild: AssessmentComponent;\r\n\r\n wrappedFirstEncounterSavedCallback: (result: FirstEncounterSaveResult) => Promise;\r\n dataEntryChanged: boolean;\r\n entityTypeName: string;\r\n genericEntityVM: GenericEntityVM;\r\n appealVM: AppealViewModel;\r\n billVM: BillViewModel;\r\n refundVM: RefundViewModel;\r\n assessmentVM: AssessmentViewModel;\r\n complianceVM: ComplianceViewModel;\r\n editState: ProcessingDetailEditState;\r\n // This panel should be displayed for certain entity type IDs and not others\r\n displayEditPanel: boolean;\r\n attachmentDescription: string;\r\n targetEntityTasks: Task[];\r\n readyTaskName: string;\r\n isReadyTaskAnticipated: boolean;\r\n isReadyTaskReviewBill: boolean;\r\n useDocumentAsBillImage: boolean = false;\r\n completeReadyTask: boolean;\r\n completeReadyTaskChanged: boolean;\r\n readyTaskID: number;\r\n years: number[];\r\n year: string;\r\n showExtraBillFields: {bill: boolean, payment: boolean};\r\n verifiedChangedEntity: boolean;\r\n hasIdpFeature: boolean;\r\n showOcrResults: boolean;\r\n billAmountDoesntAddUp: boolean = false;\r\n disableAssessmentApplyAll: boolean = false;\r\n\r\n private inProcessTaxSetupChanges: BillClusterTaxRateSetupModalResult;\r\n\r\n ngOnInit(): void {\r\n this.hasIdpFeature = this._featureFlagsService.featureFlags.enableIdp;\r\n\r\n this.verifiedChangedEntity = false;\r\n this.editState = this._getInitEditState();\r\n\r\n if (this.dataEntryJSONHandler) {\r\n this.dataEntryJSONHandler.retrieveDataEntryJSON = () => {\r\n return this.retrieveEntityJSON();\r\n };\r\n } else {\r\n console.log('Skipping step to set dataEntryJSONHandler');\r\n }\r\n\r\n if (this.validationHandler) {\r\n this.validationHandler.validate = (callback: (boolean, string) => void, forComplete: boolean) => {\r\n return this.validate(callback, forComplete);\r\n };\r\n } else {\r\n console.log('Skipping step to set validationHandler');\r\n }\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if(!this.editState) {\r\n this.editState = this._getInitEditState();\r\n }\r\n\r\n if (Object.keys(changes).indexOf('firstEncounterSavedCallback') >= 0) {\r\n this.wrappedFirstEncounterSavedCallback = async (result) => {\r\n if (result.updateVersion) {\r\n const model = this.billVM.model[0];\r\n if (model.rowVersion === result.initialBillRowVersion) {\r\n model.rowVersion = result.finalBillRowVersion;\r\n }\r\n if (model.billClusterRowVersion === result.initialBillClusterRowVersion) {\r\n model.billClusterRowVersion = result.finalBillClusterRowVersion;\r\n }\r\n }\r\n\r\n if (result.inProcessTaxSetupChanges) {\r\n this.inProcessTaxSetupChanges = result.inProcessTaxSetupChanges;\r\n }\r\n await this.firstEncounterSavedCallback(result);\r\n };\r\n }\r\n if (Object.keys(changes).indexOf('entityIdentifier') >= 0) {\r\n this.verifiedChangedEntity = false;\r\n this.completeReadyTaskChanged = false;\r\n const anticipatedTaskPromise = this._handleAnticipatedTask();\r\n this.dataEntryChanged = false;\r\n this.year = null;\r\n if (this.entityIdentifier) {\r\n this.displayEditPanel = true;\r\n let buildVMPromise: Promise = null;\r\n switch (this.entityIdentifier.entityTypeId) {\r\n case FILING_ENTITY_TYPE_ID:\r\n this.entityTypeName = 'filing';\r\n let dataEntryFiling: DataEntry = null;\r\n if (this.dataEntryJSON) {\r\n dataEntryFiling = this._parseJSON>(this.dataEntryJSON);\r\n this.dataEntryChanged = !dataEntryFiling.resetOnLoad && dataEntryFiling.dataEntryChanged;\r\n }\r\n buildVMPromise = this._complianceService.getComplianceViewModelByFilingId(this.entityIdentifier.entityId)\r\n .then((complianceVM) => {\r\n if (dataEntryFiling && !dataEntryFiling.resetOnLoad) {\r\n complianceVM.assignFromExistingFiling(dataEntryFiling.entity);\r\n }\r\n this._processDataEntry(dataEntryFiling);\r\n if (this.parcelID && this.parcelAcctNum) {\r\n complianceVM.setParcelDetails(this.parcelID, this.parcelAcctNum);\r\n }\r\n this._resetVMs();\r\n this.complianceVM = complianceVM;\r\n });\r\n break;\r\n case APPEAL_ENTITY_TYPE_ID:\r\n this.entityTypeName = 'appeal';\r\n let dataEntry: DataEntry = null;\r\n if (this.dataEntryJSON) {\r\n dataEntry = this._parseJSON>(this.dataEntryJSON);\r\n this.dataEntryChanged = !dataEntry.resetOnLoad && dataEntry.dataEntryChanged;\r\n }\r\n buildVMPromise = this._appealService.getAppealViewModelByAppealID(this.entityIdentifier.entityId)\r\n .then((appealVM) => {\r\n if (dataEntry && !dataEntry.resetOnLoad) {\r\n appealVM.assignFromExistingAppeal(dataEntry.entity);\r\n }\r\n this._processDataEntry(dataEntry);\r\n if (this.parcelID && this.parcelAcctNum) {\r\n appealVM.setParcelDetails(this.parcelID, this.parcelAcctNum);\r\n }\r\n this._resetVMs();\r\n this.appealVM = appealVM;\r\n });\r\n break;\r\n case TAXBILL_ENTITY_TYPE_ID:\r\n this.entityTypeName = 'bill';\r\n let dataEntryBill: DataEntry = null;\r\n if (this.dataEntryJSON) {\r\n dataEntryBill = this._parseJSON>(this.dataEntryJSON);\r\n this.dataEntryChanged = !dataEntryBill.resetOnLoad && dataEntryBill.dataEntryChanged;\r\n }\r\n buildVMPromise = this._billClusterService.getBillViewModelByBillID(this.entityIdentifier.entityId)\r\n .then((billVM: BillViewModel) => {\r\n if (dataEntryBill && !dataEntryBill.resetOnLoad) {\r\n billVM.assignFromExistingBill(dataEntryBill.entity);\r\n billVM.processingTaxSetupResult = dataEntryBill.taxSetup;\r\n }\r\n this._processDataEntry(dataEntryBill);\r\n billVM.parcelID = this.parcelID;\r\n billVM.parcelAcctNum = this.parcelAcctNum;\r\n billVM.hasWritePermission = this.editState.hasWritePermission;\r\n billVM.intakeAttachmentId = this.attachmentID;\r\n billVM.model[0].annualAssessmentID = billVM.model[0].annualAssessmentID || _.maxBy(billVM.yearRevisions, 'revisionNum').annualAssessmentID;\r\n this.showExtraBillFields = this._billClusterService.getShowExtraFields(billVM.model);\r\n\r\n this._resetVMs();\r\n this.billVM = billVM;\r\n\r\n if (this.inProcessTaxSetupChanges) {\r\n billVM.processingTaxSetupResult = this.inProcessTaxSetupChanges;\r\n this.inProcessTaxSetupChanges = null;\r\n this.editState.setDirty(true);\r\n }\r\n\r\n this.showOcrResults = !!this.intakeDocumentInfo.taxBillOcrResults?.installments;\r\n\r\n if(!this.showOcrResults) {\r\n return;\r\n }\r\n\r\n this.billVM.taskSummariesPromise.then(() => {\r\n this.billAmountDoesntAddUp = this._idpService.billAmountDoesntAddUp(this.billVM, this.intakeDocumentInfo.taxBillOcrResults);\r\n const isDueDateMismatch = this._idpService.isDueDateMismatch(billVM, this.intakeDocumentInfo.taxBillOcrResults.installments);\r\n const hasBeenReceived = some(this.billVM.model[0].payments, x => x.taskSummary?.TaxBillReceived);\r\n\r\n if(this.billAmountDoesntAddUp || isDueDateMismatch || hasBeenReceived) {\r\n this.intakeDocumentInfo.idpConfidence = 0.2;\r\n }\r\n\r\n const hasBeenTransmitted = some(this.billVM.model[0].payments, x => x.taskSummary?.TransmitComplete);\r\n\r\n if(this.intakeDocumentInfo.idpConfidence > 0.33\r\n && !this.intakeDocumentInfo.intakeItem.savedByUser\r\n && !hasBeenTransmitted\r\n ) {\r\n this._idpService.mapBillVMFromIDP(billVM, this.intakeDocumentInfo.taxBillOcrResults);\r\n this.editState.setDirty(true);\r\n }\r\n });\r\n });\r\n break;\r\n\r\n case REFUND_ENTITY_TYPE_ID:\r\n this.entityTypeName = 'refund';\r\n let dataEntryRefund: DataEntry = null;\r\n if (this.dataEntryJSON) {\r\n dataEntryRefund = this._parseJSON>(this.dataEntryJSON);\r\n this.dataEntryChanged = !dataEntryRefund.resetOnLoad && dataEntryRefund.dataEntryChanged;\r\n }\r\n buildVMPromise = this._billClusterService.getRefundViewModelByRefundID(this.entityIdentifier.entityId)\r\n .then((refundVM: RefundViewModel) => {\r\n if (dataEntryRefund && !dataEntryRefund.resetOnLoad) {\r\n refundVM.assignFromExistingRefund(dataEntryRefund.entity);\r\n }\r\n this._processDataEntry(dataEntryRefund);\r\n refundVM.parcelID = this.parcelID;\r\n refundVM.parcelAcctNum = this.parcelAcctNum;\r\n refundVM.hasWritePermission = this.editState.hasWritePermission;\r\n // refundVM.year =\r\n\r\n this._resetVMs();\r\n this.refundVM = refundVM;\r\n });\r\n break;\r\n\r\n case ASSESSMENT_ENTITY_TYPE_ID:\r\n this.entityTypeName = 'assessment';\r\n let dataEntryAssessment: DataEntry = null;\r\n if (this.dataEntryJSON) {\r\n dataEntryAssessment = this._parseJSON>(this.dataEntryJSON);\r\n this.dataEntryChanged = !dataEntryAssessment.resetOnLoad && dataEntryAssessment.dataEntryChanged;\r\n }\r\n buildVMPromise = this._assessmentService.getAssessmentViewModelByAssessmentID(this.entityIdentifier.entityId)\r\n .then(async (assessmentVM) => {\r\n if (dataEntryAssessment && !dataEntryAssessment.resetOnLoad) {\r\n assessmentVM.assignFromExistingAssessment(dataEntryAssessment.entity);\r\n assessmentVM.currentYear.calcProjected = dataEntryAssessment.calcProjected;\r\n }\r\n this._processDataEntry(dataEntryAssessment);\r\n assessmentVM.parcelAcctNum = this.parcelAcctNum;\r\n assessmentVM.parcelID = this.parcelID;\r\n this._resetVMs();\r\n this.assessmentVM = assessmentVM;\r\n\r\n this.showOcrResults = !!this.intakeDocumentInfo.assessmentNoticeOcrResults\r\n\r\n if(!this._featureFlagsService.featureFlags.enableIdpAssessment || !this.showOcrResults) {\r\n console.log(cloneDeep(this._featureFlagsService.featureFlags.enableIdpAssessment), cloneDeep(this.showOcrResults))\r\n return;\r\n }\r\n\r\n if(this.assessmentVM.isActual()) {\r\n this._toastr.warning('The values are actualized. In order to apply OCR values, tasks need to be rescinded');\r\n this.editState.setEditMode(false)\r\n return;\r\n }\r\n\r\n if(this.intakeDocumentInfo.idpConfidence > 0.33 \r\n && !this.intakeDocumentInfo.intakeItem.savedByUser\r\n ) {\r\n let { disableApplyAll, lowerConfidence } = await this._idpService.mapAssessmentVMFromIDP(\r\n assessmentVM, \r\n this.intakeDocumentInfo.assessmentNoticeOcrResults.assessmentRevision, \r\n this.assessmentChild\r\n );\r\n\r\n this.disableAssessmentApplyAll = disableApplyAll;\r\n \r\n if(this.disableAssessmentApplyAll || lowerConfidence) {\r\n this.intakeDocumentInfo.idpConfidence = .2\r\n } \r\n\r\n this.editState.setDirty(!this.disableAssessmentApplyAll)\r\n }\r\n });\r\n break;\r\n default:\r\n buildVMPromise = this._setGenericEntityVM().then(() => {\r\n // Maybe we should restructure this so entities that aren't really editable\r\n // get a different panel that just has the attachment description and anticipated\r\n // task stuff\r\n this.displayEditPanel = true;\r\n this.dataEntryChanged = false;\r\n\r\n let dataEntryFallback: DataEntry = null;\r\n if (this.dataEntryJSON) {\r\n dataEntryFallback = this._parseJSON>(this.dataEntryJSON);\r\n }\r\n\r\n this._processDataEntry(dataEntryFallback);\r\n });\r\n break;\r\n }\r\n\r\n Promise.all([anticipatedTaskPromise, buildVMPromise]).then(() => {\r\n // If there isn't a ready task, the checkbox will not show up, and we\r\n // should treat it as unchecked\r\n if (!this.isReadyTaskAnticipated) {\r\n this.completeReadyTask = false;\r\n }\r\n // If the user has touched the complete ready task checkbox, don't do anything\r\n else if (!this.completeReadyTaskChanged) {\r\n // If the user is on an anticipated search, default to complete being true\r\n this.completeReadyTask = this.searchAnticipated;\r\n }\r\n });\r\n\r\n this.warnOnEntityReloadChanged.emit(this.dataEntryChanged);\r\n }\r\n else {\r\n this.displayEditPanel = false;\r\n }\r\n }\r\n\r\n // When the document processing page loads, we expect that the entity tree and entity edit UIs will be loaded\r\n // independently; when the entity tree finishes, we'll know the parcel account number, so we should go update\r\n // the entity edit UI at that time.\r\n if (Object.keys(changes).indexOf('parcelAcctNum') >= 0 ||\r\n Object.keys(changes).indexOf('parcelID') >= 0) {\r\n switch (this.entityIdentifier.entityTypeId) {\r\n case PARCEL_ENTITY_TYPE_ID:\r\n if (this.genericEntityVM) {\r\n this.genericEntityVM.commentModalData.description = this.parcelAcctNum;\r\n this.genericEntityVM.commentModalData.parcelAcctNum = this.parcelAcctNum;\r\n this.genericEntityVM.commentModalData.parcelID = this.parcelID;\r\n this.genericEntityVM.attachmentModalData.entityName = this.parcelAcctNum;\r\n this.genericEntityVM.attachmentModalData.entityData.name = this.parcelAcctNum;\r\n }\r\n break;\r\n case APPEAL_ENTITY_TYPE_ID:\r\n if (this.appealVM) {\r\n this.appealVM.setParcelDetails(this.parcelID, this.parcelAcctNum);\r\n }\r\n break;\r\n case FILING_ENTITY_TYPE_ID:\r\n if(this.complianceVM) {\r\n this.complianceVM.setParcelDetails(this.parcelID, this.parcelAcctNum);\r\n }\r\n break;\r\n }\r\n }\r\n\r\n if (Object.keys(changes).indexOf('siteName') >= 0 &&\r\n this.genericEntityVM &&\r\n this.entityIdentifier.entityTypeId === SITE_ENTITY_TYPE_ID) {\r\n this.genericEntityVM.commentModalData.description = this.siteName;\r\n this.genericEntityVM.attachmentModalData.entityName = this.siteName;\r\n this.genericEntityVM.attachmentModalData.entityData.name = this.siteName;\r\n }\r\n\r\n if (Object.keys(changes).indexOf('companyName') >= 0 &&\r\n this.genericEntityVM &&\r\n this.entityIdentifier.entityTypeId === COMPANY_ENTITY_TYPE_ID) {\r\n this.genericEntityVM.commentModalData.description = this.companyName;\r\n this.genericEntityVM.attachmentModalData.entityName = this.companyName;\r\n this.genericEntityVM.attachmentModalData.entityData.name = this.companyName;\r\n }\r\n }\r\n\r\n get shouldShowConfidencePanel(): boolean {\r\n return this.showOcrResults && this.hasIdpFeature \r\n && !!(this.billVM || (this.assessmentVM && this._featureFlagsService.featureFlags.enableIdpAssessment));\r\n }\r\n\r\n populateYears(): void {\r\n const now = new Date();\r\n const currentYear = now.getFullYear();\r\n\r\n this.years = [];\r\n\r\n for (let i = currentYear + 3; i >= currentYear - 10; i--) {\r\n this.years.push(i);\r\n }\r\n }\r\n\r\n billRevisionChanged(revision: AnnualDetailAssessment): void {\r\n this.billRevisionChangedX.emit(revision);\r\n }\r\n\r\n verifyChangedEntity(): void {\r\n this.verifiedChangedEntity = true;\r\n }\r\n\r\n validate(callback: (boolean, string) => void, forComplete: boolean): void {\r\n if (this.entityIdentifier && this.entityIdentifier.entityTypeId) {\r\n switch (this.entityIdentifier.entityTypeId) {\r\n case ASSESSMENT_ENTITY_TYPE_ID:\r\n if (forComplete && this.completeReadyTask && this.assessmentVM.currentYear.calcProjected) {\r\n callback(false, 'Cannot complete Auto Calculated assessment');\r\n return;\r\n }\r\n break;\r\n case APPEAL_ENTITY_TYPE_ID:\r\n this.appealVM.validate(callback);\r\n return;\r\n case FILING_ENTITY_TYPE_ID:\r\n this.complianceVM.validate(callback);\r\n return;\r\n case TAXBILL_ENTITY_TYPE_ID:\r\n const anyCalcProjected = _.some(this.billVM.model, (bill: Bill) => {\r\n return bill.calcProjected;\r\n }) as boolean;\r\n if (forComplete && this.completeReadyTask && anyCalcProjected) {\r\n callback(false, 'Cannot complete Auto Calculated bill');\r\n }\r\n else {\r\n this.billVM.validate(callback);\r\n }\r\n return;\r\n }\r\n }\r\n\r\n callback(true, '');\r\n }\r\n\r\n retrieveEntityJSON(): string {\r\n if (!this.entityIdentifier || !this.entityIdentifier.entityTypeId) {\r\n return null;\r\n }\r\n\r\n let completeReadyTask = this.isReadyTaskAnticipated && this.completeReadyTask;\r\n\r\n switch (this.entityIdentifier.entityTypeId) {\r\n case APPEAL_ENTITY_TYPE_ID:\r\n return JSON.stringify(new DataEntry(this.appealVM.currentAppeal, this.attachmentDescription, completeReadyTask, false,\r\n this.readyTaskID, this.dataEntryChanged, this.searchAnticipated, this.completeReadyTaskChanged, null, null));\r\n case FILING_ENTITY_TYPE_ID:\r\n return JSON.stringify(new DataEntry(this.complianceVM.currentFiling, this.attachmentDescription, completeReadyTask, false,\r\n this.readyTaskID, this.dataEntryChanged, this.searchAnticipated, this.completeReadyTaskChanged, null, null));\r\n case TAXBILL_ENTITY_TYPE_ID:\r\n return JSON.stringify(new DataEntry(this.billVM.model[0], this.attachmentDescription, completeReadyTask, this.useDocumentAsBillImage,\r\n this.readyTaskID, this.dataEntryChanged, this.searchAnticipated, this.completeReadyTaskChanged, null, this.billVM.processingTaxSetupResult));\r\n case REFUND_ENTITY_TYPE_ID:\r\n return JSON.stringify(new DataEntry(this.refundVM.model, this.attachmentDescription, completeReadyTask, false,\r\n this.readyTaskID, this.dataEntryChanged, this.searchAnticipated, this.completeReadyTaskChanged, null, null));\r\n case ASSESSMENT_ENTITY_TYPE_ID:\r\n if (this.assessmentVM.currentYear.calcProjected) {\r\n completeReadyTask = false;\r\n }\r\n // We have a little extra handling for overriding the FMV in components for assessments that needs to be done prior to save\r\n const assessmentModel: Assessment = this._assessmentService.prepareAssessmentForSave(this.assessmentVM.model);\r\n return JSON.stringify(new DataEntry(assessmentModel, this.attachmentDescription, completeReadyTask, false,\r\n this.readyTaskID, this.dataEntryChanged, this.searchAnticipated, this.completeReadyTaskChanged,\r\n this.assessmentVM.currentYear.calcProjected, null));\r\n default:\r\n const newEntry = new DataEntry(null, this.attachmentDescription, false, false, null, false, false, false, null, null);\r\n newEntry.attachmentYear = this.year;\r\n return JSON.stringify(newEntry);\r\n }\r\n }\r\n\r\n onCompleteReadyTaskChange(): void {\r\n this.completeReadyTaskChanged = true;\r\n }\r\n\r\n idpAcceptedBill(updatedIdpBillModel: Bill[]): void {\r\n assign(this.billVM.model, updatedIdpBillModel);\r\n this.editState.setDirty(true);\r\n }\r\n\r\n idpAcceptedAssessment(updatedIdpAssessmentVM: AssessmentViewModel): void {\r\n assign(this.assessmentVM, updatedIdpAssessmentVM);\r\n this.editState.setDirty(true);\r\n }\r\n\r\n private _setGenericEntityVM(): Promise {\r\n const commentModalData = new CommentModalData();\r\n commentModalData.entityID = this.entityIdentifier.entityId;\r\n commentModalData.entityTypeID = this.entityIdentifier.entityTypeId;\r\n commentModalData.canEdit = true;\r\n\r\n const attachmentModalData = new AttachmentModalData();\r\n attachmentModalData.entityData = new AttachmentModalEntityData();\r\n attachmentModalData.entityData.id = this.entityIdentifier.entityId;\r\n attachmentModalData.entityData.typeId = this.entityIdentifier.entityTypeId;\r\n\r\n const checkForComments = () => {\r\n return this._commentsService.checkForComments(this.entityIdentifier.entityTypeId, this.entityIdentifier.entityId);\r\n };\r\n\r\n const checkForAttachments = () => {\r\n return this._attachmentService.checkForAttachments(this.entityIdentifier.entityTypeId, this.entityIdentifier.entityId);\r\n };\r\n\r\n this._resetVMs();\r\n switch (this.entityIdentifier.entityTypeId) {\r\n case COMPANY_ENTITY_TYPE_ID:\r\n return Promise.all([checkForComments(), checkForAttachments()]).then(checkResult => {\r\n const hasComments = checkResult[0];\r\n const hasAttachments = checkResult[1];\r\n\r\n this.entityTypeName = 'Company';\r\n this.genericEntityVM = new GenericEntityVM();\r\n this.genericEntityVM.hasComments = hasComments;\r\n commentModalData.description = this.companyName;\r\n this.genericEntityVM.commentModalData = commentModalData;\r\n\r\n this.genericEntityVM.hasAttachments = hasAttachments;\r\n attachmentModalData.entityType = 'company';\r\n attachmentModalData.entityName = this.companyName;\r\n attachmentModalData.entityData.name = this.companyName;\r\n // I don't think we need to set attachmentModalData.parentId or parentType\r\n // since you can't navigate to a parent from parcel/site/company\r\n this.genericEntityVM.attachmentModalData = attachmentModalData;\r\n });\r\n case SITE_ENTITY_TYPE_ID:\r\n return Promise.all([checkForComments(), checkForAttachments()]).then(checkResult => {\r\n const hasComments = checkResult[0];\r\n const hasAttachments = checkResult[1];\r\n\r\n this.entityTypeName = 'Site';\r\n this.genericEntityVM = new GenericEntityVM();\r\n this.genericEntityVM.hasComments = hasComments;\r\n commentModalData.description = this.siteName;\r\n this.genericEntityVM.commentModalData = commentModalData;\r\n\r\n this.genericEntityVM.hasAttachments = hasAttachments;\r\n attachmentModalData.entityType = 'site';\r\n attachmentModalData.entityName = this.siteName;\r\n attachmentModalData.entityData.name = this.siteName;\r\n // I don't think we need to set attachmentModalData.parentId or parentType\r\n // since you can't navigate to a parent from parcel/site/company\r\n this.genericEntityVM.attachmentModalData = attachmentModalData;\r\n });\r\n case PARCEL_ENTITY_TYPE_ID:\r\n return Promise.all([checkForComments(), checkForAttachments()]).then(checkResult => {\r\n const hasComments = checkResult[0];\r\n const hasAttachments = checkResult[1];\r\n\r\n this.entityTypeName = 'Parcel';\r\n this.genericEntityVM = new GenericEntityVM();\r\n this.genericEntityVM.hasComments = hasComments;\r\n commentModalData.parcelID = this.entityIdentifier.entityId;\r\n commentModalData.parcelAcctNum = this.parcelAcctNum;\r\n commentModalData.description = this.parcelAcctNum;\r\n this.genericEntityVM.commentModalData = commentModalData;\r\n\r\n this.genericEntityVM.hasAttachments = hasAttachments;\r\n attachmentModalData.entityType = 'parcel';\r\n attachmentModalData.entityName = this.parcelAcctNum;\r\n attachmentModalData.entityData.name = this.parcelAcctNum;\r\n // I don't think we need to set attachmentModalData.parentId or parentType\r\n // since you can't navigate to a parent from parcel/site/company\r\n this.genericEntityVM.attachmentModalData = attachmentModalData;\r\n });\r\n default:\r\n this.entityTypeName = 'entity';\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n private _processDataEntry(dataEntry: DataEntry): void {\r\n // Don't reload the readyTaskID from the dataEntry object; let handleAnticipatedTask do that\r\n if (dataEntry) {\r\n this.attachmentDescription = dataEntry.attachmentDescription;\r\n this.completeReadyTask = dataEntry.completeReadyTask;\r\n dataEntry.resetOnLoad = false;\r\n this.completeReadyTaskChanged = dataEntry.completeReadyTaskChanged;\r\n this.useDocumentAsBillImage = dataEntry.useDocumentAsBillImage;\r\n this.searchAnticipated = dataEntry.searchAnticipated;\r\n this.year = dataEntry.attachmentYear;\r\n }\r\n else {\r\n this.attachmentDescription = this.intakeBatchItemNumber;\r\n this.completeReadyTask = false;\r\n }\r\n }\r\n\r\n private _handleAnticipatedTask(): Promise {\r\n this.targetEntityTasks = null;\r\n this.readyTaskName = null;\r\n this.isReadyTaskAnticipated = false;\r\n this.isReadyTaskReviewBill = false;\r\n this.readyTaskID = null;\r\n this.entityTypeName = null;\r\n\r\n if (this.entityIdentifier) {\r\n return this._taskService.getByEntity(this.entityIdentifier.entityId, this.entityIdentifier.entityTypeId).then((result) => {\r\n const tasks = result.tasks;\r\n this.targetEntityTasks = tasks;\r\n const aid = this.attachmentTypeID;\r\n\r\n let isMatchAnticipated = false;\r\n let isMatchReviewBill = false;\r\n\r\n _.forEach(_.filter(tasks, (task: Task) => {\r\n return task.isReady && !task.completedDateTime;\r\n }), (readyTask: Task): boolean => {\r\n const tid = readyTask.taskTypeID;\r\n\r\n //this.isReadyTaskAnticipated\r\n isMatchAnticipated = ((tid === TaskTypeID.ObtainDataEnterValueNotice && aid === AttachmentTypeID.ValueNotice) ||\r\n (tid === TaskTypeID.ObtainPostDeterminationValueNotice && aid === AttachmentTypeID.ValueNotice) ||\r\n (tid === TaskTypeID.ObtainHearingNotice && aid === AttachmentTypeID.HearingNotice) ||\r\n (tid === TaskTypeID.ObtainDataEnterTaxBill && aid === AttachmentTypeID.TaxBill) ||\r\n (tid === TaskTypeID.TrackDataEnterRefund && aid === AttachmentTypeID.Refund) ||\r\n (tid === TaskTypeID.PrintApplication && aid === AttachmentTypeID.AppealApplication) ||\r\n (tid === TaskTypeID.FileAppeal && aid === AttachmentTypeID.AppealApplication) ||\r\n (tid === TaskTypeID.SubmitEvidence && aid === AttachmentTypeID.AppealDocumentExchange) ||\r\n (tid === TaskTypeID.ObtainMagistrateRecommendation && aid === AttachmentTypeID.AppealDecision) ||\r\n (tid === TaskTypeID.ObtainPaymentReceipt && aid === AttachmentTypeID.TaxReceipt) ||\r\n (tid === TaskTypeID.ObtainFinalDecision && aid === AttachmentTypeID.AppealDecision) ||\r\n (tid === TaskTypeID.FileMiscFiling && aid === AttachmentTypeID.MiscFiling) ||\r\n (tid === TaskTypeID.FilePPReturn && aid === AttachmentTypeID.PPReturn) ||\r\n (tid === TaskTypeID.FileFreeport && aid === AttachmentTypeID.FreeportApplication) ||\r\n (tid === TaskTypeID.FileAbatement && aid === AttachmentTypeID.AbatementApplication) ||\r\n (tid === TaskTypeID.FilePollutionControl && aid === AttachmentTypeID.PollutionControlApplication) ||\r\n (tid === TaskTypeID.ConfirmHearing && aid === AttachmentTypeID.AppealConfirmation));\r\n\r\n if (isMatchAnticipated) {\r\n this.readyTaskID = readyTask.taskID;\r\n this.readyTaskName = readyTask.name;\r\n this.isReadyTaskAnticipated = true;\r\n }\r\n\r\n isMatchReviewBill = tid == TaskTypeID.ReviewPaymentDetails && aid == AttachmentTypeID.TaxBill;\r\n\r\n if(isMatchReviewBill) {\r\n this.isReadyTaskReviewBill = true;\r\n }\r\n\r\n return !isMatchAnticipated || !isMatchReviewBill;\r\n });\r\n });\r\n }\r\n else {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n private _parseJSON(inputJSON: string): T {\r\n const result = JSON.parse(inputJSON) as T;\r\n this._util.convertDateStringsToDates(result);\r\n return result;\r\n }\r\n\r\n private _resetVMs(): void {\r\n this.appealVM = null;\r\n this.assessmentVM = null;\r\n this.billVM = null;\r\n this.refundVM = null;\r\n this.complianceVM = null;\r\n this.genericEntityVM = null;\r\n }\r\n\r\n private _getInitEditState(): ProcessingDetailEditState {\r\n return new ProcessingDetailEditState((isDirty: boolean) => {\r\n this.setDirty(isDirty);\r\n this.warnOnEntityReloadChanged.emit(true);\r\n this.dataEntryChanged = true;\r\n });\r\n }\r\n}\r\n\r\nexport class ProcessingDetailEditState implements AnnualDetailEditState {\r\n constructor(private setDirtyHandler: (boolean) => void) {\r\n this.editMode = true;\r\n this.isDirty = false;\r\n this.hasWritePermission = true;\r\n }\r\n\r\n showEditControls: boolean;\r\n editMode: boolean;\r\n hasWritePermission: boolean;\r\n refreshGrid: boolean;\r\n refreshActivity: boolean;\r\n entityLoading: boolean;\r\n validationMessage: string;\r\n staleAppealSavings: boolean;\r\n staleAppealStatus: boolean;\r\n validationHandler: (callback: (boolean, string) => void) => void;\r\n cancelHandler: () => void;\r\n saveHandler: () => Promise;\r\n // TODO: Wire this up to the document processing page's dirty indicator instead\r\n isDirty: boolean;\r\n\r\n setDirty(isDirty: boolean): void {\r\n this.setDirtyHandler(isDirty);\r\n if (this.isDirty !== isDirty) {\r\n this.isDirty = isDirty;\r\n }\r\n }\r\n\r\n getDirty(): boolean {\r\n return this.isDirty;\r\n }\r\n\r\n setEditMode(editMode: boolean): void {\r\n this.editMode = editMode;\r\n }\r\n}\r\n","import { CommonModule, CurrencyPipe } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { AnnualDetailsModule } from '../../Annual-Details/annual-details.module';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { UILibModule } from '../../UI-Lib/UILib.module';\r\nimport { EntityEditComponent } from './Entity-Edit/entity-edit.component';\r\nimport { IdpDetailCardComponent } from './Entity-Edit/IDP/Detail-Modal/Card/idpDetailCard.component';\r\nimport { IdpBillDetailModalComponent } from './Entity-Edit/IDP/Detail-Modal/idpBillDetailModal.component';\r\nimport { IdpConfidencePanelComponent } from './Entity-Edit/IDP/idpConfidencePanel.component';\r\nimport { DocumentProcessingExceptionModalComponent } from './Modals/documentProcessingExceptionModal.component';\r\nimport { DuplicateIntakeItemModalComponent } from './Modals/duplicateIntakeItemModal.component';\r\nimport { IdpAssessmentDetailModalComponent } from './Entity-Edit/IDP/Detail-Modal/idpAssessmentDetailModal.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n WeissmanSharedModule,\r\n UILibModule,\r\n CurrencyPipe,\r\n AnnualDetailsModule\r\n ],\r\n declarations: [\r\n EntityEditComponent,\r\n IdpConfidencePanelComponent,\r\n IdpBillDetailModalComponent,\r\n IdpDetailCardComponent,\r\n DuplicateIntakeItemModalComponent,\r\n DocumentProcessingExceptionModalComponent,\r\n IdpAssessmentDetailModalComponent\r\n ],\r\n exports: [IdpConfidencePanelComponent]\r\n})\r\nexport class DocumentProcessingModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('processingEntityEdit', EntityEditComponent);\r\n hybridAdapterUtility.downgradeNg2Component('idpConfidencePanel', IdpConfidencePanelComponent);\r\n }\r\n}\r\n","// Note that only the functions that happen to be needed in TypeScript are\r\nimport { DocumentExceptionActions } from '../constants.new';\r\n// included here; the processing service in JavaScript has many more functions\r\n// that can be included here as needed\r\nimport { ProcessAppealWarrantedForm } from './Process-Appeal-Warranted-Modal/processAppealWarranted.component';\r\nimport { ProcessNoAppealForm } from './Process-No-Appeal-Modal/processNoAppeal.component';\r\n\r\nexport abstract class ProcessingService {\r\n abstract changeDueDate(taskIDs: number[], dueDate: Date, searchTimeStamp: Date): Promise;\r\n abstract getEntityTree(entityTypeId: number, entityId : number, extended: boolean): Promise;\r\n abstract getResultTypesByDocumentType(documentType: string): any[];\r\n abstract processAppealWarranted(payload: ProcessAppealWarrantedForm): Promise;\r\n abstract processNoAppealWarranted(payload: ProcessNoAppealForm): Promise;\r\n abstract getAppealLevels(taskIDs: number[]): Promise;\r\n abstract processPaymentReviewed(payload: { taskIDs: number[], searchTimestamp: Date }): Promise;\r\n abstract createDuplicateIntakeItemBulk(duplicate: any): Promise;\r\n abstract createDuplicateIntakeItem(duplicate: any): Promise;\r\n abstract completeFileAppeal(payload: any): Promise;\r\n abstract getBulkDocumentExceptionData(taskIDs: number[]): Promise;\r\n abstract processDocumentBulkException(payload: any): Promise;\r\n abstract performOCR(taskIDs: number[]): Promise;\r\n abstract processDocumentException(documentIntakeID: number, taskID: number, selectedEntity: any,\r\n actionType: DocumentExceptionActions, getNewAssignment, commentBody: string, newDocumentTypeID: number,\r\n dataEntryJSON: string, rowVersion, parcelChanges): Promise;\r\n}\r\n","\r\n \r\n
\r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../Compliance/WeissmanModalService';\r\nimport { ProcessingService } from './processing.service.upgrade';\r\n\r\nexport interface ChangeDueDateModalParams {\r\n taskIDs: number[];\r\n optionID: number;\r\n searchTimestamp: Date;\r\n parentCallsService?: boolean\r\n}\r\n\r\n@Component({\r\n selector: 'change-due-date-modal',\r\n templateUrl: './change-due-date.modal.component.html'\r\n})\r\nexport class ChangeDueDateModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _processingService: ProcessingService) {\r\n }\r\n\r\n params: ChangeDueDateModalParams;\r\n result: any;\r\n\r\n loading: boolean;\r\n dueDateText: string;\r\n dueDateTextOptions = {\r\n 9: 'Appeal Deadline',\r\n 10: 'Appeal Deadline',\r\n 11: 'Submit Evidence Date',\r\n 12: 'Informal Hearing Date',\r\n 13: 'Formal Hearing Date',\r\n 14: 'Payment Due Date',\r\n 15: 'Intake Item Due Date',\r\n 16: 'Filing Due Date',\r\n 25: 'Invoice Due Date',\r\n 35: 'Confirm Hearing Date'\r\n };\r\n dateOnly: boolean;\r\n dueDate: Date;\r\n taskIDs: number[];\r\n searchTimestamp: Date;\r\n parentCallsService: boolean;\r\n\r\n ngOnInit(): void {\r\n const optionID = this.params.optionID;\r\n this.parentCallsService = this.params.parentCallsService;\r\n this.dueDateText = this.dueDateTextOptions[optionID] || 'Due Date';\r\n this.dateOnly = optionID != 11 && optionID != 12 && optionID != 13;\r\n this.taskIDs = this.params.taskIDs;\r\n this.searchTimestamp = this.params.searchTimestamp;\r\n }\r\n\r\n showModalInit(): void {\r\n this.loading = false;\r\n }\r\n\r\n async save(): Promise {\r\n if (this.parentCallsService) {\r\n this.result = async () => await this._processingService.changeDueDate(this.taskIDs, this.dueDate, this.searchTimestamp);\r\n this.cancel();\r\n }\r\n else {\r\n this.loading = true;\r\n\r\n try {\r\n this.result = await this._processingService.changeDueDate(this.taskIDs, this.dueDate, this.searchTimestamp);\r\n this.cancel();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\nexport class RetrievalStatus {\r\n retrievalStatusId: number;\r\n name: string;\r\n}\r\n\r\nexport class RetrievalStatusPayload {\r\n constructor() {\r\n this.ignoreRetrievalStatus = false;\r\n this.ignoreFollowUpDate = true;\r\n this.followUpDate = null;\r\n this.newAssignment = {} as Core.UserTeamModel;\r\n }\r\n\r\n taskIds: number[];\r\n retrievalStatusId: number;\r\n ignoreRetrievalStatus: boolean;\r\n followUpDate: Date;\r\n ignoreFollowUpDate: boolean;\r\n newAssignment: Core.UserTeamModel;\r\n comment: string;\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { RetrievalStatus, RetrievalStatusPayload } from './retrieval-status.model';\r\nimport { BulkOperationResult } from '../../Common/Models/bulk-operation-result.model';\r\n\r\n@Injectable()\r\nexport class RetrievalStatusService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n getRetrievalStatuses(): Promise {\r\n return this.http.get('/api/DocumentRetrieval/RetrievalStatuses');\r\n }\r\n\r\n getRetrievalStatusIdsByTaskIds(taskIds: number[]): Promise {\r\n return this.http.post('/api/DocumentRetrieval/RetrievalStatusSearch', taskIds);\r\n }\r\n\r\n setStatus(payload: RetrievalStatusPayload): Promise {\r\n return this.http.post('/api/DocumentRetrieval/SetDocumentRetrievalStatusBulk', payload);\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, Output, OnChanges, SimpleChanges, HostListener } from '@angular/core';\r\nimport { TeamService } from 'src/app/Team/team.service';\r\n\r\ninterface UserTeamModel extends Core.UserTeamModel {\r\n label: string;\r\n}\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'user-team-picker',\r\n templateUrl: './user-team-picker.component.html',\r\n styles: [`\r\n .ng-invalid.ng-touched {\r\n border-color: var(--ace-danger);\r\n box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.08);\r\n }\r\n `]\r\n})\r\nexport class UserTeamPickerComponent implements OnChanges {\r\n constructor(private teamService: TeamService) {}\r\n\r\n @Input() user: Core.UserTeamModel;\r\n @Input() userId: System.Guid | string;\r\n @Input() teamId: number;\r\n @Input() isReassign: boolean = false;\r\n @Input() entityIdScope: number;\r\n @Input() instanceIdScope: number;\r\n @Input() entityTypeScope: string;\r\n @Input() restrictToRyanInstance: boolean = false;\r\n @Input() required: boolean = false;\r\n @Input() showInvalidState: boolean = false;\r\n @Input() disabled: boolean = false;\r\n @Input() revertIfEmptyOnBlur: boolean = false;\r\n @Input() parentUsers: Core.UserTeamModel[];\r\n @Input() placeholder: string;\r\n @Input() isConsultantPerspective: boolean = false;\r\n @Input() entityIdsMultiselectScope: number[] = [];\r\n @Input() showDocumentIntakeUserTeamsOnly: boolean = false;\r\n @Output() userChange = new EventEmitter();\r\n\r\n @HostListener('keyup.enter', ['$event'])\r\n onDocumentKeydownEnter(event: Event) {\r\n event.stopPropagation();\r\n }\r\n\r\n users: UserTeamModel[] = [];\r\n selectedUserName: string = '';\r\n\r\n\r\n ngOnInit(): void {\r\n if (!this.placeholder) {\r\n this.placeholder = 'Search User...';\r\n }\r\n }\r\n\r\n async ngOnChanges(changes: SimpleChanges): Promise {\r\n if (changes['placeholder']) {\r\n if (!this.placeholder) {\r\n this.placeholder = 'Search User...';\r\n }\r\n }\r\n\r\n const isUserObjRemoved = changes['user']\r\n && (!changes['user'].currentValue || !changes['user'].currentValue.userID);\r\n const areIdsRemoved = (changes['userId'] && !changes['userId'].currentValue)\r\n || (changes['teamId'] && !changes['teamId'].currentValue);\r\n\r\n if (isUserObjRemoved || areIdsRemoved) {\r\n this.selectedUserName = '';\r\n this.user = undefined;\r\n }\r\n\r\n if(!this.users.length) {\r\n const users = this.parentUsers || await this._getUsers();\r\n this.users = _.map(users, userTeam => {\r\n return {\r\n ...userTeam,\r\n label: this.formatInput(userTeam)\r\n };\r\n });\r\n } else if (changes['parentUsers']) {\r\n this.users = _.map(this.parentUsers, userTeam => {\r\n return {\r\n ...userTeam,\r\n label: this.formatInput(userTeam)\r\n };\r\n });\r\n }\r\n\r\n let selectedUser: UserTeamModel;\r\n\r\n if (this.user) {\r\n selectedUser = _.find(this.users, {\r\n userID: this.user.userID,\r\n teamID: this.user.teamID\r\n });\r\n } else if(this.userId && this.teamId) {\r\n selectedUser = _.find(this.users, {\r\n userID: this.userId,\r\n teamID: this.teamId\r\n });\r\n\r\n if(selectedUser) {\r\n this.user = _.omit(selectedUser, 'label');\r\n }\r\n }\r\n\r\n if(selectedUser) {\r\n this.selectedUserName = selectedUser.label;\r\n }\r\n }\r\n\r\n formatInput(model: Core.UserTeamModel): string {\r\n if (_.isEmpty(model)) {\r\n return;\r\n }\r\n\r\n return `${model.lastName}, ${model.firstName} (${model.teamName})`;\r\n }\r\n\r\n changed(): void {\r\n if(!_.trim(this.selectedUserName) && !this.revertIfEmptyOnBlur) {\r\n this.user = undefined;\r\n this.userChange.emit(this.user);\r\n }\r\n }\r\n\r\n onBlur(): void {\r\n if (!_.trim(this.selectedUserName) && this.revertIfEmptyOnBlur) {\r\n this.selectedUserName = this.formatInput(this.user);\r\n return;\r\n }\r\n\r\n // If a user is copy-pasted into the input, we need to find the user in the list and select it\r\n // The username must be an exact match\r\n if (this.selectedUserName.trim() && !this.user) {\r\n const user = this.users.find(x => x.label === this.selectedUserName);\r\n if (user) {\r\n this.selectItem(user);\r\n return;\r\n }\r\n }\r\n\r\n if(this.user) { // only emit if there's a user. we already emitted onchange if there's no user\r\n this.userChange.emit(this.user);\r\n }\r\n }\r\n\r\n selectItem(selectedUser: UserTeamModel): void {\r\n this.user = selectedUser;\r\n this.selectedUserName = selectedUser.label;\r\n this.userChange.emit(this.user);\r\n }\r\n\r\n select(eventTarget: EventTarget): void {\r\n (eventTarget as HTMLInputElement).select();\r\n }\r\n\r\n private _getUsers(): Promise {\r\n return this.restrictToRyanInstance\r\n ? this.teamService.getAllAssignableRyanUsers(false, this.entityIdScope, this.entityTypeScope)\r\n : (this.entityIdsMultiselectScope && this.entityIdsMultiselectScope.length > 0)\r\n ? this.teamService.getAllAssignableUsers(this.isReassign,\r\n false,\r\n null,\r\n this.entityTypeScope,\r\n this.instanceIdScope,\r\n null,\r\n this.entityIdsMultiselectScope,\r\n this.showDocumentIntakeUserTeamsOnly) //there is currently no DI multiselect, but included this here anyway\r\n : this.teamService.getAllAssignableUsers(this.isReassign,\r\n false,\r\n this.entityIdScope,\r\n this.entityTypeScope,\r\n this.instanceIdScope,\r\n this.showDocumentIntakeUserTeamsOnly);\r\n }\r\n}\r\n","
\r\n

Set Document Retrieval Status

\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BulkOperationResult } from '../../Common/Models/bulk-operation-result.model';\r\nimport { RetrievalStatusService } from './retrieval-status.service';\r\nimport { RetrievalStatus, RetrievalStatusPayload } from './retrieval-status.model';\r\nimport * as _ from 'lodash';\r\nimport { WeissmanDatetimeComponent } from '../../UI-Lib/Weiss-Datepicker/weissman-datetime.component';\r\nimport {WeissmanDateFormatPipe} from '../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\n\r\ndeclare const moment: any;\r\n\r\nexport enum FollowUpChoice {\r\n DAYS,\r\n DATE,\r\n NO_FOLLOWUP,\r\n NO_CHANGE\r\n}\r\n\r\n@Component({\r\n selector: 'set-document-retrieval-status-modal',\r\n templateUrl: './set-document-retrieval-status.modal.component.html'\r\n})\r\nexport class SetDocumentRetrievalStatusModalComponent implements OnInit {\r\n constructor(private bsModalRef: BsModalRef, private retrievalStatusService: RetrievalStatusService, private datePipe: WeissmanDateFormatPipe) { }\r\n\r\n // These will be initialized by the service which opens the modal\r\n taskIds: number[];\r\n instanceId: number;\r\n callback: (result: () => Promise) => void;\r\n // (end service-initialized properties)\r\n retrievalStatuses: RetrievalStatus[];\r\n retrievalStatusPayload: RetrievalStatusPayload = new RetrievalStatusPayload();\r\n followUpChoice: number;\r\n followUpChoices = FollowUpChoice;\r\n daysOptions: number[];\r\n computedDate: Date;\r\n selectedDate: Date;\r\n generatedComment: string;\r\n selectedUserInfo: string;\r\n followUpInXdays: number;\r\n\r\n\r\n ngOnInit() {\r\n this.daysOptions = _.range(1, 20);\r\n this.setComputedDate(this.daysOptions[0]);\r\n this.followUpChoice = this.followUpChoices.NO_CHANGE;\r\n\r\n this.retrievalStatusService.getRetrievalStatuses()\r\n .then((retrievalStatuses: RetrievalStatus[]) => {\r\n retrievalStatuses = _.sortBy(retrievalStatuses, 'name');\r\n\r\n const extraStatuses: RetrievalStatus[] = [{\r\n name: 'Set to Blank',\r\n retrievalStatusId: null\r\n }];\r\n\r\n this.retrievalStatuses = _.union(extraStatuses, retrievalStatuses);\r\n });\r\n\r\n // setTimeout is necessary, because taskIds aren't immediately available for some reason\r\n setTimeout(() => {\r\n this.retrievalStatusService.getRetrievalStatusIdsByTaskIds(this.taskIds)\r\n .then((uniqueRetrievalStatuses: number[]) => {\r\n if(uniqueRetrievalStatuses.length === 1) {\r\n this.retrievalStatusPayload.retrievalStatusId = uniqueRetrievalStatuses[0];\r\n } else {\r\n this.retrievalStatuses.unshift({\r\n name: 'Take no Action',\r\n retrievalStatusId: 999\r\n });\r\n this.retrievalStatusPayload.retrievalStatusId = 999;\r\n }\r\n });\r\n });\r\n }\r\n\r\n setUser(e: Core.UserTeamModel): void {\r\n if ( !e ) {\r\n // No User Team picked. Clear user info so it's not included in the Comment.\r\n this.selectedUserInfo = undefined;\r\n //console.log('ClearUser!');\r\n }\r\n else\r\n {\r\n this.retrievalStatusPayload.newAssignment = _.pick(e, ['userID', 'teamID']) as Core.UserTeamModel;\r\n //console.log('SetUser!');\r\n this.selectedUserInfo = `${e.lastName }, ${ e.firstName } (${ e.teamName })`;\r\n //console.log(this.retrievalStatusPayload.newAssignment);\r\n }\r\n }\r\n\r\n setComputedDataFromSelect(eventTarget: EventTarget) {\r\n const days = (eventTarget as HTMLSelectElement).value;\r\n this.setComputedDate(Number(days));\r\n }\r\n\r\n // https://stackoverflow.com/a/20948347\r\n setComputedDate(days: number): void {\r\n\r\n this.followUpInXdays = days;\r\n //let date = moment(); // use a clone\r\n // using moment() will get the current date/time; we just want the current date midnight UTC\r\n let date = WeissmanDatetimeComponent.getMidnightMoment(new Date(), false, 'utc');\r\n\r\n while (days > 0) {\r\n date = date.add(1, 'days');\r\n // decrease \"days\" only if it's a weekday.\r\n if (date.isoWeekday() !== 6 && date.isoWeekday() !== 7) {\r\n days -= 1;\r\n }\r\n }\r\n\r\n this.computedDate = date.toDate();\r\n }\r\n\r\n\r\n submit(): void {\r\n this._setPayload();\r\n this.bsModalRef.hide();\r\n this.callback(() => {\r\n return this.retrievalStatusService.setStatus(this.retrievalStatusPayload);\r\n });\r\n //this.retrievalStatusService.setStatus(this.retrievalStatusPayload)\r\n // .then((result: BulkOperationResult[]) => {\r\n // this.callback(result);\r\n\r\n // this.bsModalRef.hide();\r\n // });\r\n }\r\n\r\n recreateComment(): void {\r\n if (!this.retrievalStatusPayload.comment || ( this.retrievalStatusPayload.comment == this.generatedComment ))\r\n {\r\n this.retrievalStatusPayload.comment = this._getCommentBody();\r\n this.generatedComment = this.retrievalStatusPayload.comment;\r\n }\r\n }\r\n\r\n closeModal(): void {\r\n this.bsModalRef.hide();\r\n }\r\n\r\n private _setPayload(): void {\r\n this.retrievalStatusPayload.taskIds = this.taskIds;\r\n\r\n if(this.retrievalStatusPayload.retrievalStatusId === 999) {\r\n this.retrievalStatusPayload.retrievalStatusId = null;\r\n this.retrievalStatusPayload.ignoreRetrievalStatus = true;\r\n }\r\n\r\n switch(this.followUpChoice) {\r\n case this.followUpChoices.DAYS:\r\n this.retrievalStatusPayload.followUpDate = this.computedDate;\r\n this.retrievalStatusPayload.ignoreFollowUpDate = false;\r\n break;\r\n case this.followUpChoices.DATE:\r\n this.retrievalStatusPayload.followUpDate = this.selectedDate;\r\n this.retrievalStatusPayload.ignoreFollowUpDate = false;\r\n break;\r\n case this.followUpChoices.NO_CHANGE:\r\n this.retrievalStatusPayload.ignoreFollowUpDate = true;\r\n break;\r\n case this.followUpChoices.NO_FOLLOWUP:\r\n this.retrievalStatusPayload.followUpDate = null;\r\n this.retrievalStatusPayload.ignoreFollowUpDate = false;\r\n break;\r\n }\r\n }\r\n\r\n\r\n private _getCommentBody(): string {\r\n\r\n let result = 'Retrieval status has been updated: \\n';\r\n\r\n console.log('this.retrievalStatusPayload.retrievalStatusId', this.retrievalStatusPayload.retrievalStatusId);\r\n\r\n if (this.retrievalStatusPayload.retrievalStatusId){\r\n result += ` Retrieval Status: ${ this.retrievalStatuses.find(x => x.retrievalStatusId == this.retrievalStatusPayload.retrievalStatusId).name }\\n`;\r\n }\r\n\r\n result += ' Follow Up: ';\r\n\r\n switch(this.followUpChoice) {\r\n case this.followUpChoices.DAYS:\r\n result += `In ${ this.followUpInXdays } weekdays which is ${ this.datePipe.transform(this.computedDate, true)}`;\r\n break;\r\n case this.followUpChoices.DATE:\r\n result += `On ${ this.datePipe.transform(this.selectedDate, true)}`;\r\n break;\r\n case this.followUpChoices.NO_CHANGE:\r\n result += 'No Change';\r\n break;\r\n case this.followUpChoices.NO_FOLLOWUP:\r\n result += 'No Follow Up';\r\n break;\r\n }\r\n if (this.selectedUserInfo){\r\n result += '\\n';\r\n result += `Re-Assign To: ${ this.selectedUserInfo}`;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n}\r\n","import {TaskSummary} from '../../Task/Task.Model';\r\nimport {UserTeamMember, Address} from '../../Common/Models/common.model';\r\nimport {Team} from '../../Team/team.model';\r\nimport { PropertyType, ContractServiceType } from '../../constants.new';\r\n\r\nexport class Invoice {\r\n //Details and info\r\n invoiceId: number;\r\n companyId: number;\r\n companyName: string;\r\n siteId: number;\r\n siteName: string;\r\n siteAddress: Address;\r\n siteState: InvoiceState;\r\n invoiceType: number;\r\n invoiceTypeName: string;\r\n isAdHoc: boolean;\r\n contractServiceType: ContractServiceType;\r\n defaultContractServiceType: ContractServiceType;\r\n dueDate: Date;\r\n invoiceNumber: number;\r\n invoiceUBRNumber: number;\r\n recipientName: string;\r\n invoiceAmount: number;\r\n invoiceRowVersion: string;\r\n annualYear: number;\r\n appeals: InvoiceAppeal[];\r\n recipientMailingAddress: string;\r\n thirdPartyApprovalDate: Date;\r\n recipientCdsContactId: string;\r\n isRyanLegalServices: boolean;\r\n\r\n //Booleans\r\n includeOtherParcels: boolean;\r\n automaticallyUpdateNotes: boolean;\r\n hasComments: boolean;\r\n hasAttachments: boolean;\r\n canBeDeleted: boolean;\r\n isUBR: boolean;\r\n\r\n //Overrides\r\n previousFMVStatus: OverrideStatus;\r\n invoiceFMVStatus: OverrideStatus;\r\n fmvChangeStatus: OverrideStatus;\r\n savingsStatus: OverrideStatus;\r\n taxRateStatus: OverrideStatus;\r\n contingencyPctStatus: OverrideStatus;\r\n feeAmountStatus: OverrideStatus;\r\n fixedFeeStatus: OverrideStatus;\r\n contingencyCapStatus: OverrideStatus;\r\n invoiceAmountStatus: OverrideStatus;\r\n\r\n isSavingsOverridden: boolean;\r\n\r\n //Tasks\r\n taskSummary: TaskSummary;\r\n readyTaskId: number;\r\n readyTaskTypeId: number;\r\n hasUBRTasks: boolean;\r\n\r\n //Fee Allocation\r\n contingencyInvoiceRowVersion: string;\r\n invoiceRevenueShareCodes: RevenueShare [];\r\n\r\n //Detail Fields\r\n otherParcelFMV: number;\r\n contingencyPct: number;\r\n displayContingencyPct: number;\r\n contingencyCap: number;\r\n previousFMV: number;\r\n invoiceFMV: number;\r\n taxRate: number;\r\n displayTaxRate: number;\r\n savings: number;\r\n feeAmount: number;\r\n fixedFee: number;\r\n expenseAmount: number;\r\n expenseIndex: number;\r\n fmvChange: number;\r\n propertyTypeID: number;\r\n totalFeeAmount: number;\r\n contractTermDetailRemarks: string;\r\n\r\n //Calculated Detail Fields\r\n calculatedPreviousFMV: number;\r\n calculatedInvoiceFMV: number;\r\n calculatedTaxRate: number;\r\n calculatedSavings: number;\r\n calculatedFeeAmount: number;\r\n\r\n backupContingencyPct: number;\r\n contingencyCapOriginal: number;\r\n contingencyPctOriginal: number;\r\n fixedFeeOriginal: number;\r\n\r\n processingInstructions: string;\r\n notes: string;\r\n\r\n //Account Handler\r\n accountHandler: UserTeamMember;\r\n accountHandlerTeam: Team;\r\n accountHandlerTeamID: number;\r\n accountHandlerUserID: string;\r\n}\r\n\r\nexport enum InvoiceTypes {\r\n Contingency = 1\r\n}\r\n\r\nexport enum InvoiceRouteNames {\r\n Processing = 'processInvoice',\r\n Site = 'siteInvoice',\r\n Company = 'companyInvoice'\r\n}\r\n\r\nexport enum OverrideStatus {\r\n Default= 'black',\r\n Recalculated = 'blue',\r\n Overridden = 'red'\r\n}\r\n\r\nexport class InvoiceAppeal {\r\n parcelID: number;\r\n parcelAcctNum: string;\r\n appealLevelName: string;\r\n appealLevelAbbr: string;\r\n annualYear: number;\r\n appealID: number;\r\n invoiceFMV: number;\r\n previousFMV: number;\r\n finalFMV: number;\r\n fmvChange: number;\r\n revisionDesc: string;\r\n savings: number;\r\n savingsOverridden: boolean;\r\n taxRate: number;\r\n}\r\n\r\nexport class InvoiceAppealSearchResult {\r\n otherParcelFMV: number;\r\n appeals: InvoiceAppeal[];\r\n}\r\n\r\nexport class InvoiceState {\r\n abbr: string;\r\n assessorCount: 0;\r\n collectorCount: 0;\r\n country: string;\r\n countryId: number;\r\n fiscalDateMonthDay: string;\r\n fiscalDateYearID: number;\r\n fullName: string;\r\n hasAttachments: boolean;\r\n hasComments: boolean;\r\n lienDateMonthDay: string;\r\n lienDateYearID: number;\r\n personalPropTaxable: boolean;\r\n stateID: number;\r\n website: string;\r\n}\r\n\r\nexport class CreateAdHocInvoiceRequest {\r\n companyId: number;\r\n siteId: number;\r\n annualYear: number;\r\n contractServiceType: ContractServiceType;\r\n propertyType: PropertyType;\r\n}\r\n\r\nexport class BulkInvoicePreCheckResult {\r\n existingInvoiceCount: number;\r\n siteCount: number;\r\n}\r\n\r\nexport class RevenueShare {\r\n constructor(invoiceId: number) {\r\n this.allocationPct = 0;\r\n this.displayAllocationPct = 0;\r\n this.costCenter = null;\r\n this.costCenterTeamId = null;\r\n this.engagementNum = '';\r\n this.invoiceId = invoiceId;\r\n this.isAccountHandler = false;\r\n this.optionalIdentifier = null;\r\n this.feeAmount = 0;\r\n this.invoiceAmount = 0;\r\n }\r\n\r\n allocationPct: number;\r\n displayAllocationPct: number;\r\n costCenter: string;\r\n costCenterTeamId: number;\r\n engagementNum: string;\r\n invoiceRevenueShareCodeId: number;\r\n invoiceId: number;\r\n isAccountHandler: boolean;\r\n optionalIdentifier: string;\r\n rowVersion: string;\r\n sequence: number;\r\n feeAmount: number;\r\n invoiceAmount: number;\r\n isTotal: boolean;\r\n}\r\n","\r\n","import { Injectable } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { SetDocumentRetrievalStatusModalComponent } from './set-document-retrieval-status.modal.component';\r\nimport { BulkOperationResult } from '../../Common/Models/bulk-operation-result.model';\r\n\r\n@Injectable()\r\nexport class RetrievalStatusModalService {\r\n constructor(private modalService: BsModalService) { }\r\n\r\n setDocumentRetrievalStatusModalRef: BsModalRef;\r\n\r\n launchSetDocumentRetrievalStatusModal(taskIds: number[], instanceId: number): Promise<() => void> {\r\n return new Promise<() => Promise>((resolve, reject) => {\r\n const initialState = {\r\n taskIds: taskIds,\r\n instanceId: instanceId,\r\n callback: (result: () => Promise) => {\r\n resolve(result);\r\n }\r\n };\r\n\r\n this.setDocumentRetrievalStatusModalRef = this.modalService.show(SetDocumentRetrievalStatusModalComponent, {initialState});\r\n });\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport {\r\n BulkInvoicePreCheckResult,\r\n CreateAdHocInvoiceRequest,\r\n Invoice,\r\n InvoiceAppeal,\r\n InvoiceAppealSearchResult,\r\n OverrideStatus\r\n} from './invoice.model';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { Decimal } from 'decimal.js';\r\nimport * as _ from 'lodash';\r\nimport { CurrencyPipe, DecimalPipe } from '@angular/common';\r\nimport { Constants, ContractServiceType } from '../../constants.new';\r\n\r\n@Injectable()\r\nexport class InvoiceService {\r\n constructor(private http: SDHttpService,\r\n private numberPipe: DecimalPipe,\r\n private currencyPipe: CurrencyPipe,\r\n private constants: Constants) {\r\n }\r\n\r\n contractServiceName(contractServiceType: ContractServiceType): string {\r\n return Object.keys(this.constants.ContractServiceTypes)\r\n .map(k => this.constants.ContractServiceTypes[k])\r\n .filter(t => t.id == contractServiceType)\r\n .map(t => t.name)[0];\r\n }\r\n\r\n getInvoice(invoiceId: string): Promise {\r\n return this.http.get(`/api/Invoice/${ invoiceId}`).then((invoice: Invoice) => {\r\n const finalInvoice = this.calculateInvoiceData(invoice);\r\n return finalInvoice;\r\n });\r\n }\r\n\r\n getInvoiceForTask(taskId: number): Promise {\r\n return this.http.get(`/api/Invoice/Task/${ taskId}`).then((invoice: Invoice) => {\r\n const finalInvoice = this.calculateInvoiceData(invoice);\r\n return finalInvoice;\r\n });\r\n }\r\n\r\n refreshInvoice(originalInvoice: Invoice): Promise {\r\n const appealIDs = _.map(originalInvoice.appeals, 'appealID');\r\n return this.http.post(`/api/Invoice/${ originalInvoice.invoiceId }/appeal/search`, appealIDs)\r\n .then((result: InvoiceAppealSearchResult) => {\r\n let finalInvoice: Invoice = originalInvoice;\r\n\r\n //Need to manually map over the fields we are refreshing. This is so far just appeals and recalculating the data.\r\n finalInvoice.appeals = result.appeals;\r\n finalInvoice.otherParcelFMV = result.otherParcelFMV;\r\n finalInvoice.includeOtherParcels = true;\r\n finalInvoice = this.resetFromAppealData(finalInvoice);\r\n\r\n return finalInvoice;\r\n });\r\n }\r\n\r\n saveInvoice(invoice: Invoice): Promise {\r\n return this.http.put(`/api/Invoice/${invoice.invoiceId}`, invoice);\r\n }\r\n\r\n completeInvoice(invoice: Invoice): Promise {\r\n return this.http.put(`/api/Invoice/${ invoice.invoiceId }/readytask`, invoice, { handleCode: 400 });\r\n }\r\n\r\n deleteInvoice(invoiceId: number): Promise {\r\n return this.http.delete(`/api/invoice/${ invoiceId}`);\r\n }\r\n\r\n getInvoices(companyId: number, siteId: number, fromDate: Date, toDate: Date): Promise{\r\n let url = '';\r\n\r\n if (siteId){\r\n url = `/api/site/${ siteId }/invoices`;\r\n }\r\n else{\r\n url = `/api/company/${ companyId }/invoices`;\r\n }\r\n\r\n return this.http.post(url, {fromDate: fromDate, toDate: toDate});\r\n }\r\n\r\n getReadyInvoiceAppealSavingTasksCount(siteId: number) {\r\n return this.http.get(`/api/site/${ siteId }/getParcelsReadyForInvoiceCount`);\r\n }\r\n\r\n getReadyAdminFeeInvoiceCount(companyId: number): Promise {\r\n return this.http.get(`/api/company/${ companyId }/getReadyAdminFeeInvoiceCount`);\r\n }\r\n\r\n bulkInvoicePreCheck(companyId: number, annualYear: number): Promise {\r\n return this.http.get(`/api/company/${ companyId }/year/${ annualYear }/bulkInvoicePreCheck`);\r\n }\r\n\r\n createInvoices(siteId: number) {\r\n return this.http.post(`/api/invoice/${ siteId }/createInvoices`);\r\n }\r\n\r\n createCompanyAdminInvoices(companyId: number, annualYear: number) {\r\n return this.http.post('/api/invoice/adminbulk', {\r\n companyId: companyId,\r\n annualYear: annualYear\r\n });\r\n }\r\n\r\n removeAppeal(invoice: Invoice, appealIndex: number): Invoice {\r\n const removedAppeal: InvoiceAppeal = invoice.appeals.splice(appealIndex, 1)[0];\r\n\r\n if (!_.some(invoice.appeals, (appeal: InvoiceAppeal) => { return appeal.parcelID === removedAppeal.parcelID; })) {\r\n // Now that this appeal is no longer included, it's final FMV is \"another parcel's\" FMV (as long\r\n // as that parcel is not also linked to another appeal on this invoice)\r\n invoice.otherParcelFMV = new Decimal(invoice.otherParcelFMV).plus(removedAppeal.finalFMV).toNumber();\r\n }\r\n\r\n return this.resetFromAppealData(invoice);\r\n }\r\n\r\n resetFromAppealData(invoice: Invoice, preserveOverrides: boolean = false): Invoice {\r\n const savingsTotal: number = this._appealsSum(invoice.appeals, 'savings').toNumber();\r\n\r\n invoice = this.calculateFMVFields(invoice);\r\n\r\n if (!preserveOverrides) {\r\n invoice.previousFMVStatus = OverrideStatus.Default;\r\n invoice.invoiceFMVStatus = OverrideStatus.Default;\r\n invoice.fmvChangeStatus = OverrideStatus.Default;\r\n invoice.savingsStatus = OverrideStatus.Default;\r\n invoice.taxRateStatus = OverrideStatus.Default;\r\n invoice.contingencyPctStatus = OverrideStatus.Default;\r\n invoice.feeAmountStatus = OverrideStatus.Default;\r\n invoice.contingencyCapStatus = OverrideStatus.Default;\r\n invoice.invoiceAmountStatus = OverrideStatus.Default;\r\n invoice.isSavingsOverridden = false;\r\n\r\n invoice.previousFMV = invoice.calculatedPreviousFMV;\r\n invoice.invoiceFMV = invoice.calculatedInvoiceFMV;\r\n\r\n invoice.calculatedSavings = savingsTotal;\r\n invoice.savings = savingsTotal;\r\n\r\n invoice.contingencyPct = invoice.contingencyPctOriginal;\r\n invoice.contingencyCap = invoice.contingencyCapOriginal;\r\n\r\n invoice.taxRate = this.calculateTaxRate(invoice);\r\n invoice.calculatedTaxRate = invoice.taxRate;\r\n\r\n invoice.feeAmount = this.calculateFeeAmount(invoice);\r\n invoice.calculatedFeeAmount = invoice.feeAmount;\r\n }\r\n else {\r\n if (invoice.previousFMVStatus === OverrideStatus.Default) {\r\n invoice.previousFMV = invoice.calculatedPreviousFMV;\r\n }\r\n if (invoice.invoiceFMVStatus === OverrideStatus.Default) {\r\n invoice.invoiceFMV = invoice.calculatedInvoiceFMV;\r\n }\r\n\r\n invoice.fmvChange = invoice.previousFMV - invoice.invoiceFMV;\r\n // fmvChangeStatus should already be right, since we're not changing FMVStatuses here\r\n }\r\n\r\n // Re-run the calculate step; if we did our job right, statuses will remain the way we set them here,\r\n // but any side-effects of changing values will also happen as expected\r\n return this.calculateInvoiceData(invoice);\r\n }\r\n\r\n calculateInvoiceData(invoice: Invoice): Invoice {\r\n const savingsTotal: number = this._appealsSum(invoice.appeals, 'savings').toNumber();\r\n\r\n invoice = this.calculateFMVFields(invoice);\r\n\r\n //Set invoice contingency percent status\r\n if ((invoice.contingencyPct || 0) === (invoice.contingencyPctOriginal || 0)) {\r\n invoice.contingencyPctStatus = OverrideStatus.Default;\r\n } else {\r\n invoice.contingencyPctStatus = OverrideStatus.Overridden;\r\n }\r\n\r\n //Set invoice contingency cap status\r\n if (invoice.contingencyCap === invoice.contingencyCapOriginal) {\r\n invoice.contingencyCapStatus = OverrideStatus.Default;\r\n } else {\r\n invoice.contingencyCapStatus = OverrideStatus.Overridden;\r\n }\r\n\r\n //Set fixed fee status\r\n if (invoice.fixedFee === invoice.fixedFeeOriginal) {\r\n invoice.fixedFeeStatus = OverrideStatus.Default;\r\n } else {\r\n invoice.fixedFeeStatus = OverrideStatus.Overridden;\r\n }\r\n\r\n //Set previous FMV status and replace value if it's default\r\n if(invoice.previousFMV === invoice.calculatedPreviousFMV) {\r\n invoice.previousFMVStatus = OverrideStatus.Default;\r\n } else {\r\n invoice.previousFMVStatus = OverrideStatus.Overridden;\r\n }\r\n\r\n //Set invoice FMV status and replace value if it's default\r\n if(invoice.invoiceFMV === invoice.calculatedInvoiceFMV) {\r\n invoice.invoiceFMVStatus = OverrideStatus.Default;\r\n } else {\r\n invoice.invoiceFMVStatus = OverrideStatus.Overridden;\r\n }\r\n\r\n invoice.fmvChangeStatus = (invoice.invoiceFMVStatus === OverrideStatus.Overridden ||\r\n invoice.previousFMVStatus === OverrideStatus.Overridden ?\r\n OverrideStatus.Recalculated : OverrideStatus.Default);\r\n\r\n invoice = this.calculateSavingsTaxRate(invoice, savingsTotal);\r\n\r\n invoice.backupContingencyPct = invoice.contingencyPct;\r\n\r\n if(!invoice.contingencyPct) {\r\n invoice.contingencyPct = 0;\r\n }\r\n\r\n invoice.calculatedFeeAmount = this.calculateFeeAmount(invoice);\r\n\r\n //Set invoice fee amount status\r\n //This code block causes some problems when recalculating fee amount\r\n //There is code to handle this in the details component to combat the problems\r\n if ((invoice.feeAmount || 0) === invoice.calculatedFeeAmount) {\r\n invoice.feeAmountStatus = OverrideStatus.Default;\r\n } else {\r\n if(invoice.contingencyCapStatus !== OverrideStatus.Overridden &&\r\n invoice.contingencyPctStatus !== OverrideStatus.Overridden &&\r\n invoice.savingsStatus !== OverrideStatus.Overridden &&\r\n invoice.invoiceFMVStatus !== OverrideStatus.Overridden &&\r\n invoice.feeAmountStatus !== OverrideStatus.Recalculated &&\r\n invoice.previousFMVStatus !== OverrideStatus.Overridden) {\r\n\r\n invoice.feeAmountStatus = OverrideStatus.Overridden;\r\n } else if(invoice.feeAmountStatus !== OverrideStatus.Overridden) {\r\n invoice.feeAmountStatus = OverrideStatus.Recalculated;\r\n invoice.feeAmount = invoice.calculatedFeeAmount;\r\n }\r\n }\r\n\r\n this.setDisplayPercentages(invoice);\r\n\r\n this.setInvoiceStatus(invoice);\r\n\r\n invoice.totalFeeAmount = (invoice.feeAmount || 0) + (invoice.fixedFee || 0);\r\n invoice.invoiceAmount = invoice.totalFeeAmount + invoice.expenseAmount;\r\n\r\n //This should always go last, so all variables are present\r\n if(invoice.automaticallyUpdateNotes) {\r\n invoice.notes = this.generateNotes(invoice);\r\n }\r\n\r\n return invoice;\r\n }\r\n\r\n calculateTaxRate(invoice: Invoice): number {\r\n if (invoice.fmvChange == 0) {\r\n return 0;\r\n }\r\n const savingsDec: Decimal = new Decimal(invoice.savings);\r\n\r\n const taxRateTotal = savingsDec.dividedBy(invoice.fmvChange).toDecimalPlaces(8).toNumber();\r\n\r\n return taxRateTotal;\r\n }\r\n\r\n calculateSavings(invoice: Invoice): number {\r\n const fmvChangeDec: Decimal = new Decimal(invoice.fmvChange);\r\n return fmvChangeDec.times(invoice.taxRate).toDecimalPlaces(2).toNumber();\r\n }\r\n\r\n resetTotalSavings(invoice: Invoice): Invoice {\r\n invoice.savings = this._appealsSum(invoice.appeals, 'savings').toNumber();\r\n\r\n return invoice;\r\n }\r\n\r\n // \"Initial Tax Rate\" means what the tax rate would be if the fmvChange were not overridden\r\n // and everything was at defaults\r\n calculateInitialTaxRate(invoice: Invoice, totalSavings?: number): number {\r\n if (invoice.calculatedPreviousFMV == invoice.calculatedInvoiceFMV) {\r\n return 0;\r\n }\r\n totalSavings = totalSavings || this._appealsSum(invoice.appeals, 'savings').toNumber();\r\n\r\n const initialTaxRate: number = (new Decimal(totalSavings)).dividedBy(\r\n (new Decimal(invoice.calculatedPreviousFMV - invoice.calculatedInvoiceFMV)))\r\n .toDecimalPlaces(8).toNumber();\r\n return initialTaxRate;\r\n }\r\n\r\n calculateSavingsTaxRate(invoice: Invoice, totalSavings: number): Invoice {\r\n // It is the responsibility of this function to set the status, real value, and calculated value\r\n // for tax rate and savings; every if block must account for all six values\r\n\r\n if (invoice.fmvChangeStatus === OverrideStatus.Recalculated) {\r\n // initialTaxRate = totalSavings / (calculatedPreviousFMV - calculatedInvoiceFMV)\r\n const initialTaxRate: number = this.calculateInitialTaxRate(invoice, totalSavings);\r\n\r\n if (invoice.isSavingsOverridden) {\r\n invoice.savingsStatus = OverrideStatus.Overridden;\r\n invoice.taxRateStatus = OverrideStatus.Recalculated;\r\n // invoice.savings is already set\r\n invoice.taxRate = this.calculateTaxRate(invoice);\r\n invoice.calculatedSavings = (new Decimal(invoice.fmvChange).times(\r\n new Decimal(initialTaxRate).toDecimalPlaces(8))).toNumber();\r\n invoice.calculatedTaxRate = invoice.taxRate;\r\n }\r\n else if (invoice.taxRate !== initialTaxRate) { // Tax rate is overridden\r\n invoice.savingsStatus = OverrideStatus.Recalculated;\r\n invoice.taxRateStatus = OverrideStatus.Overridden;\r\n invoice.savings = this.calculateSavings(invoice);\r\n // invoice.taxRate is already set\r\n invoice.calculatedSavings = invoice.savings;\r\n invoice.calculatedTaxRate = initialTaxRate;\r\n }\r\n else { // Neither is overridden\r\n invoice.savingsStatus = OverrideStatus.Recalculated;\r\n invoice.taxRateStatus = OverrideStatus.Default;\r\n invoice.taxRate = initialTaxRate;\r\n invoice.savings = this.calculateSavings(invoice);\r\n invoice.calculatedSavings = invoice.savings;\r\n invoice.calculatedTaxRate = invoice.taxRate;\r\n }\r\n }\r\n else {\r\n if (invoice.isSavingsOverridden) {\r\n invoice.savingsStatus = OverrideStatus.Overridden;\r\n invoice.taxRateStatus = OverrideStatus.Recalculated;\r\n // invoice.savings is already set\r\n invoice.taxRate = this.calculateTaxRate(invoice);\r\n invoice.calculatedSavings = totalSavings;\r\n invoice.calculatedTaxRate = invoice.taxRate;\r\n }\r\n else if (invoice.savings === totalSavings) { // Neither is overridden\r\n invoice.savingsStatus = OverrideStatus.Default;\r\n invoice.taxRateStatus = OverrideStatus.Default;\r\n // invoice.savings is already set\r\n invoice.taxRate = this.calculateTaxRate(invoice);\r\n invoice.calculatedSavings = totalSavings;\r\n invoice.calculatedTaxRate = invoice.taxRate;\r\n }\r\n else { // Tax rate is overridden\r\n invoice.savingsStatus = OverrideStatus.Recalculated;\r\n invoice.taxRateStatus = OverrideStatus.Overridden;\r\n invoice.savings = this.calculateSavings(invoice);\r\n // invoice.taxRate is already set\r\n invoice.calculatedSavings = invoice.savings;\r\n invoice.calculatedTaxRate = (new Decimal(totalSavings)).dividedBy(new Decimal(invoice.fmvChange))\r\n .toDecimalPlaces(8).toNumber();\r\n }\r\n }\r\n\r\n return invoice;\r\n }\r\n\r\n getCompanyInvoiceDefaults(companyId: number): Promise {\r\n return this.http.get(`/api/invoice/company/${ companyId }/adhocdefaults`) as Promise;\r\n }\r\n\r\n getSiteInvoiceDefaults(siteId: number): Promise {\r\n return this.http.get(`/api/invoice/site/${ siteId }/adhocdefaults`) as Promise;\r\n }\r\n\r\n createAdHocInvoice(request: CreateAdHocInvoiceRequest): Promise {\r\n return this.http.post('/api/invoice/adhoc', request) as Promise;\r\n }\r\n\r\n getDisplayPercent(sourceNum: number): number {\r\n if(sourceNum) {\r\n const sourceDec = new Decimal(sourceNum);\r\n return sourceDec.times(100).toNumber();\r\n } else {\r\n return 0;\r\n }\r\n }\r\n\r\n getRealPercentFromDisplay(sourceNum: number): number {\r\n if(sourceNum) {\r\n const sourceDec = new Decimal(sourceNum);\r\n return sourceDec.dividedBy(100).toNumber();\r\n } else {\r\n return 0;\r\n }\r\n }\r\n\r\n generateNotes(invoice: Invoice): string{\r\n let tempNotes: string = '';\r\n const uncappedFeeAmount: number = invoice.feeAmountStatus === OverrideStatus.Overridden ?\r\n invoice.feeAmount : this.calculateFeeAmount(invoice, true);\r\n\r\n const litigationPostfix = +invoice.contractServiceType === ContractServiceType.Litigation\r\n ? ' - Litigation'\r\n : '';\r\n tempNotes += `${invoice.annualYear } Property Tax Services${litigationPostfix}\\n`;\r\n if (invoice.siteName) {\r\n tempNotes += `${invoice.siteName }\\n`;\r\n }\r\n if (invoice.siteAddress) {\r\n if (invoice.siteAddress.address1){\r\n tempNotes += `${invoice.siteAddress.address1 }\\n`;\r\n }\r\n if (invoice.siteAddress.address2){\r\n tempNotes += `${invoice.siteAddress.address2 }\\n`;\r\n }\r\n if (invoice.siteAddress.city){\r\n tempNotes += invoice.siteAddress.city;\r\n if (invoice.siteState || invoice.siteAddress.zip)\r\n {\r\n tempNotes += ', ';\r\n }\r\n else\r\n {\r\n tempNotes += '\\n';\r\n }\r\n }\r\n if (invoice.siteState.abbr){\r\n tempNotes += invoice.siteState.abbr;\r\n if (invoice.siteAddress.zip)\r\n {\r\n tempNotes += ' ';\r\n }\r\n else\r\n {\r\n tempNotes += '\\n';\r\n }\r\n }\r\n if (invoice.siteAddress.zip){\r\n tempNotes += `${invoice.siteAddress.zip }\\n`;\r\n }\r\n }\r\n\r\n\r\n tempNotes += '\\n';\r\n\r\n if (!invoice.isAdHoc) {\r\n if (invoice.includeOtherParcels) {\r\n tempNotes += `Site Previous FMV: ${ this.numberPipe.transform(invoice.previousFMV, '1.0-0') }\\n`;\r\n tempNotes += `Site Billing FMV: ${ this.numberPipe.transform(invoice.invoiceFMV, '1.0-0') }\\n`;\r\n\r\n } else {\r\n tempNotes += `Parcel(s) Previous FMV: ${ this.numberPipe.transform(invoice.previousFMV, '1.0-0') }\\n`;\r\n tempNotes += `Parcel(s) Billing FMV: ${ this.numberPipe.transform(invoice.invoiceFMV, '1.0-0') }\\n`;\r\n }\r\n }\r\n\r\n if (invoice.displayTaxRate) {\r\n tempNotes += `Billable Rate: ${invoice.displayTaxRate}%\\n`;\r\n }\r\n if (!invoice.isAdHoc) {\r\n tempNotes += `Tax Savings: ${ this.currencyPipe.transform(invoice.savings, 'USD', 'symbol') }\\n`;\r\n }\r\n if (invoice.feeAmount) {\r\n tempNotes += `Contingency: ${ invoice.displayContingencyPct }%\\n`;\r\n tempNotes += `${this._showCapOnFees(invoice, uncappedFeeAmount) ? 'Uncapped ' : '' }Contingency Fee Amount: ${ this.currencyPipe.transform(uncappedFeeAmount, 'USD', 'symbol') }\\n`;\r\n tempNotes += this._showCapOnFees(invoice, uncappedFeeAmount) ? `Cap on Fees: ${ this.currencyPipe.transform(invoice.contingencyCap, 'USD', 'symbol') }\\n` : '';\r\n }\r\n if (invoice.fixedFee) {\r\n const contractServiceType = Object\r\n .keys(this.constants.ContractServiceTypes)\r\n .map(key => this.constants.ContractServiceTypes[key])\r\n .filter(t => t.id == invoice.contractServiceType)[0];\r\n\r\n const fixedFeeLabel = `${contractServiceType.fullDisplayName || contractServiceType.name } Fixed Fee: `;\r\n\r\n tempNotes += `${fixedFeeLabel + this.currencyPipe.transform(invoice.fixedFee, 'USD', 'symbol') }\\n`;\r\n }\r\n tempNotes += invoice.expenseAmount && invoice.expenseAmount != 0 ? `Expenses: ${ this.currencyPipe.transform(invoice.expenseAmount, 'USD', 'symbol') }\\n` : '';\r\n\r\n if(uncappedFeeAmount != invoice.invoiceAmount) {\r\n tempNotes += `Invoice Amount: ${ this.currencyPipe.transform(invoice.invoiceAmount, 'USD', 'symbol') }\\n`;\r\n }\r\n\r\n tempNotes += `\\nInternal ID: ${ invoice.invoiceId.toString()}`;\r\n\r\n return tempNotes;\r\n }\r\n\r\n calculateFeeAmount(invoice: Invoice, excludeCap?: boolean): number {\r\n if (!invoice.contingencyPct) {\r\n return 0;\r\n }\r\n const totalSavingsDec: Decimal = new Decimal(invoice.savings);\r\n let calcFee: number = totalSavingsDec.times(invoice.contingencyPct).toNumber();\r\n\r\n if(!excludeCap && (invoice.contingencyCap !== undefined && invoice.contingencyCap !== null) && calcFee > invoice.contingencyCap) {\r\n calcFee = invoice.contingencyCap;\r\n }\r\n\r\n return new Decimal(calcFee).toDecimalPlaces(2).toNumber();\r\n }\r\n\r\n private _showCapOnFees(invoice: Invoice, uncappedFeeAmount: number): boolean {\r\n return invoice.contingencyCap && invoice.contingencyCap < uncappedFeeAmount;\r\n }\r\n\r\n\r\n private calculateFMVFields(invoice: Invoice): Invoice {\r\n let previousFmvTotal: Decimal = this._appealsSum(invoice.appeals, 'previousFMV');\r\n let invoiceFmvTotal: Decimal = this._appealsSum(invoice.appeals, 'invoiceFMV');\r\n\r\n if(invoice.includeOtherParcels) {\r\n previousFmvTotal = previousFmvTotal.plus(invoice.otherParcelFMV);\r\n invoiceFmvTotal = invoiceFmvTotal.plus(invoice.otherParcelFMV);\r\n }\r\n\r\n //set calculated FMV fields\r\n invoice.calculatedPreviousFMV = previousFmvTotal.toNumber();\r\n invoice.calculatedInvoiceFMV = invoiceFmvTotal.toNumber();\r\n\r\n invoice.fmvChange = new Decimal(invoice.previousFMV).minus(invoice.invoiceFMV).toNumber();\r\n\r\n return invoice;\r\n }\r\n\r\n private setInvoiceStatus(invoice: Invoice) {\r\n\r\n //set fee amount status\r\n if (invoice.fmvChangeStatus === OverrideStatus.Recalculated ||\r\n invoice.taxRateStatus === OverrideStatus.Overridden ||\r\n invoice.savingsStatus === OverrideStatus.Overridden ||\r\n invoice.contingencyCapStatus === OverrideStatus.Overridden ||\r\n invoice.contingencyPctStatus === OverrideStatus.Overridden\r\n ) {\r\n if (invoice.feeAmount === invoice.calculatedFeeAmount) {\r\n invoice.feeAmountStatus = OverrideStatus.Recalculated;\r\n }\r\n } else if(invoice.fmvChangeStatus === OverrideStatus.Default &&\r\n invoice.invoiceFMVStatus === OverrideStatus.Default &&\r\n invoice.taxRateStatus === OverrideStatus.Default &&\r\n invoice.savingsStatus === OverrideStatus.Default &&\r\n invoice.contingencyCapStatus === OverrideStatus.Default &&\r\n invoice.contingencyPctStatus === OverrideStatus.Default &&\r\n invoice.feeAmountStatus !== OverrideStatus.Overridden) {\r\n\r\n //Reset default status\r\n invoice.feeAmountStatus = OverrideStatus.Default;\r\n } else {\r\n if (invoice.feeAmount === invoice.calculatedFeeAmount) {\r\n invoice.feeAmountStatus = OverrideStatus.Default;\r\n }\r\n }\r\n\r\n if (invoice.fmvChangeStatus === OverrideStatus.Recalculated ||\r\n invoice.taxRateStatus === OverrideStatus.Overridden ||\r\n invoice.savingsStatus === OverrideStatus.Overridden ||\r\n invoice.contingencyCapStatus === OverrideStatus.Overridden ||\r\n invoice.contingencyPctStatus === OverrideStatus.Overridden ||\r\n invoice.feeAmountStatus === OverrideStatus.Overridden ||\r\n invoice.fixedFeeStatus === OverrideStatus.Overridden\r\n ) {\r\n invoice.invoiceAmountStatus = OverrideStatus.Recalculated;\r\n } else {\r\n invoice.invoiceAmountStatus = OverrideStatus.Default;\r\n }\r\n\r\n\r\n }\r\n\r\n private setDisplayPercentages(invoice: Invoice) {\r\n invoice.displayContingencyPct = this.getDisplayPercent(invoice.contingencyPct);\r\n invoice.displayTaxRate = this.getDisplayPercent(invoice.taxRate);\r\n invoice.invoiceRevenueShareCodes = _.map(invoice.invoiceRevenueShareCodes, x => {\r\n x.displayAllocationPct = this.getDisplayPercent(x.allocationPct);\r\n x.feeAmount = x.invoiceAmount = 0;\r\n return x;\r\n });\r\n }\r\n\r\n private _appealsSum(appeals: InvoiceAppeal[], property): Decimal {\r\n return _.reduce(appeals, (result, appeal) => {\r\n return result.plus(appeal[property]);\r\n }, new Decimal(0));\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { RevenueShare } from '../invoice.model';\r\n\r\nexport interface ICellRendererParamsForRevenueShareGridAction extends ICellRendererParams {\r\n canDelete: (params: ICellRendererParamsForRevenueShareGridAction) => boolean;\r\n delete: (params: ICellRendererParamsForRevenueShareGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n ``\r\n})\r\nexport class RevenueShareGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForRevenueShareGridAction;\r\n revenueShare: RevenueShare;\r\n canDelete: boolean;\r\n\r\n agInit(params: ICellRendererParamsForRevenueShareGridAction): void {\r\n this.params = params;\r\n this.revenueShare = params.data as RevenueShare;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onDeleteClicked(): void {\r\n this.params.delete(this.params);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { RevenueShare } from '../invoice.model';\r\n\r\nexport interface ICellRendererParamsForEngagementNumber extends ICellRendererParams {\r\n onClick: (params: ICellRendererParamsForEngagementNumber) => void;\r\n editMode: () => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'Renderer-cell',\r\n template: `\r\n \r\n {{revenueShare.engagementNum}}\r\n \r\n \r\n `,\r\n})\r\nexport class AgGridEngagementNumberCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForEngagementNumber;\r\n revenueShare: RevenueShare;\r\n\r\n agInit(params: ICellRendererParamsForEngagementNumber): void {\r\n this.params = params;\r\n this.revenueShare = params.data as RevenueShare;\r\n }\r\n\r\n refresh() {\r\n return false;\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { RestrictService, InstanceRights } from '../Common/Permissions/restrict.service';\r\nimport { Team } from './team.model';\r\nimport * as _ from 'lodash';\r\nimport { TeamService } from './team.service';\r\n\r\nexport interface CostCenterTeam extends Team {\r\n costCenterString: string;\r\n}\r\n\r\n@Component({\r\n selector: 'team-picker',\r\n template: `\r\n \r\n \r\n {{team.costCenterString}}\r\n {{team.name}}\r\n \r\n `\r\n})\r\nexport class TeamPickerComponent implements OnInit {\r\n constructor(private teamsService: TeamService,\r\n private restrictService: RestrictService) { }\r\n\r\n @Input() useCostCenter: boolean;\r\n @Input() team: CostCenterTeam;\r\n @Input() costCenter: string;\r\n @Input() costCenterTeamId: number;\r\n @Input() editMode = true;\r\n @Input() canEdit: boolean = false;\r\n @Output() teamChange: EventEmitter = new EventEmitter();\r\n @Output() costCenterChange: EventEmitter = new EventEmitter();\r\n @Output() costCenterTeamIdChange: EventEmitter = new EventEmitter();\r\n\r\n hasEditPermission: boolean = false;\r\n dataLoading: boolean = false;\r\n teams: CostCenterTeam[];\r\n placeHolder: string = '';\r\n typeaheadField: string = '';\r\n typeaheadString: string = '';\r\n\r\n async ngOnInit() {\r\n try {\r\n this.dataLoading = true;\r\n const teams = await this.teamsService.getAllTeams(false) as CostCenterTeam[];\r\n this.teams = _.sortBy(teams, 'name');\r\n\r\n if(this.useCostCenter) {\r\n this.teams = _.chain(this.teams)\r\n .filter('costCenter')\r\n .map(x => {\r\n x.costCenterString = `${x.costCenter || ''} (${x.name})`;\r\n return x;\r\n })\r\n .value();\r\n\r\n this.placeHolder = 'Search Cost Center';\r\n this.typeaheadField = 'costCenterString';\r\n this.typeaheadString = this.costCenter;\r\n\r\n if(this.costCenterTeamId) {\r\n this.team = _.find(this.teams, {teamID: this.costCenterTeamId});\r\n }\r\n else if(this.costCenter) {\r\n this.team = _.find(this.teams, {costCenter: this.costCenter});\r\n this.costCenterTeamId = this.team.teamID;\r\n this.costCenterTeamIdChange.emit(this.costCenterTeamId);\r\n }\r\n this.typeaheadString = this.team?.costCenterString;\r\n\r\n this.hasEditPermission = true;\r\n } else {\r\n this.placeHolder = 'Search Teams';\r\n this.typeaheadField = 'name';\r\n\r\n if(this.team) {\r\n this.typeaheadString = this.team.name;\r\n }\r\n\r\n this.hasEditPermission = this.restrictService.hasInstanceRight(InstanceRights.TEAMSETUPSEDIT) || this.canEdit;\r\n }\r\n\r\n } finally {\r\n this.dataLoading = false;\r\n }\r\n }\r\n\r\n itemSelected(team: CostCenterTeam) {\r\n this.team = team;\r\n this.costCenter = this.team.costCenter;\r\n this.typeaheadString = this.useCostCenter ? this.team.costCenterString : this.team.name;\r\n\r\n this.teamChange.emit(team);\r\n this.costCenterChange.emit(this.team.costCenter);\r\n this.costCenterTeamIdChange.emit(this.team.teamID);\r\n }\r\n\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\n\r\nexport interface ICellRendererParamsForCostCenter extends ICellRendererParams {\r\n editMode: () => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'Renderer-cell',\r\n template: `\r\n \r\n `,\r\n})\r\nexport class AgGridCostCenterCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForCostCenter;\r\n\r\n agInit(params: ICellRendererParamsForCostCenter): void {\r\n this.params = params;\r\n }\r\n\r\n refresh() {\r\n return false;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\n\r\nexport interface ICellRendererParamsForPercentAllocation extends ICellRendererParams {\r\n editMode: () => boolean;\r\n onBlur: (params: ICellRendererParamsForPercentAllocation) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'Renderer-cell',\r\n template: `\r\n
\r\n \r\n \r\n {{params.data.allocationPct | percent:'1.4-4'}}\r\n \r\n TOTAL:\r\n
\r\n `,\r\n})\r\nexport class AgGridPercentAllocationCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForPercentAllocation;\r\n\r\n agInit(params: ICellRendererParamsForPercentAllocation): void {\r\n this.params = params;\r\n }\r\n\r\n refresh() {\r\n return false;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { RevenueShare, Invoice } from '../invoice.model';\r\n\r\nexport interface ICellRendererParamsForExpenseAmount extends ICellRendererParams {\r\n onClick: (params: ICellRendererParamsForExpenseAmount) => void;\r\n editMode: () => boolean;\r\n currentInvoice: () => Invoice;\r\n}\r\n\r\n@Component({\r\n selector: 'Renderer-cell',\r\n template: `\r\n
\r\n
\r\n \r\n
\r\n {{currentInvoice.expenseAmount | currency: 'USD'}}\r\n
\r\n `\r\n})\r\nexport class AgGridExpenseAmountCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForExpenseAmount;\r\n revenueShare: RevenueShare;\r\n\r\n get currentInvoice() {\r\n return this.params.currentInvoice();\r\n }\r\n\r\n agInit(params: ICellRendererParamsForExpenseAmount): void {\r\n this.params = params;\r\n this.revenueShare = params.data as RevenueShare;\r\n }\r\n\r\n refresh() {\r\n return false;\r\n }\r\n}\r\n","
\r\n\t
\r\n\t\t
\r\n\t\t

Fee Allocation

\r\n\t
\r\n\t
\r\n\t\t
\r\n\t\t\t\r\n\t\t
\r\n\t\t
\r\n \r\n \r\n
\r\n\t
\r\n
\r\n","import { Component, Input, EventEmitter, Output, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { Invoice, RevenueShare } from '../invoice.model';\r\nimport { GridApi, GridOptions, GridReadyEvent, ColDef } from 'ag-grid-community';\r\nimport { RevenueShareGridActionCellRendererComponent, ICellRendererParamsForRevenueShareGridAction } from './agGridActionCellRendererComponent';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from '../../../Compliance/AgGrid';\r\nimport { Engagement } from '../../../Common/Contracts-Invoices/contract-invoices.model';\r\nimport { AgGridEngagementNumberCellRendererComponent, ICellRendererParamsForEngagementNumber } from './agGridEngagementNumberCellRenderer';\r\nimport { AgGridCostCenterCellRendererComponent, ICellRendererParamsForCostCenter } from './agGridCostCenterCellRenderer';\r\nimport { AgGridPercentAllocationCellRendererComponent, ICellRendererParamsForPercentAllocation } from './agGridPercentAllocationCellRenderer';\r\nimport { CurrencyPipe } from '@angular/common';\r\nimport { AgGridExpenseAmountCellRendererComponent, ICellRendererParamsForExpenseAmount } from './agGridExpenseAmountCellRenderer';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { EngagementNumberLookupModalComponent } from '../../../Common/Contracts-Invoices/engagement-number-lookup-modal.component';\r\nimport * as _ from 'lodash';\r\nimport { InvoiceService } from '../invoice.service';\r\n\r\n@Component({\r\n selector: 'fee-allocation',\r\n templateUrl: './fee-allocation.component.html'\r\n})\r\nexport class FeeAllocationComponent implements OnChanges {\r\n constructor(private readonly _currencyPipe: CurrencyPipe,\r\n private readonly _bsModalService: BsModalService,\r\n private readonly invoiceService: InvoiceService) {}\r\n\r\n @Input() currentInvoice: Invoice;\r\n @Input() editMode: boolean;\r\n @Input() currentInvoiceAmount: number;\r\n\r\n @Output() engagementChanged: EventEmitter = new EventEmitter();\r\n\r\n gridId: System.Guid = '7D485CAC-59F4-4CAE-AE56-B8948DE60508'; // need new guid\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n refreshing: boolean;\r\n\r\n private _gridApi: GridApi;\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n const changedKeys = Object.keys(changes);\r\n // Look for changes to input properties\r\n if (changedKeys.indexOf('currentInvoiceAmount') >= 0) {\r\n this._allocationChange();\r\n }\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Allocation Type',\r\n field: 'name',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n valueGetter: params => {\r\n const rSC = params.data as RevenueShare;\r\n\r\n if (rSC.isTotal) {\r\n return '';\r\n }\r\n else if (rSC.isAccountHandler) {\r\n return 'Account Handler';\r\n } else {\r\n return `Revenue Share ${rSC.sequence}`;\r\n }\r\n },\r\n comparator: (valueA, valueB, nodeA, nodeB) => nodeA.data.sequence - nodeB.data.sequence\r\n },\r\n {\r\n headerName: 'Engagement #',\r\n field: 'engagementNum',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n cellRendererFramework: AgGridEngagementNumberCellRendererComponent,\r\n cellRendererParams: {\r\n editMode: () => this.editMode,\r\n onClick: this._lookupEngagementNumber.bind(this)\r\n } as ICellRendererParamsForEngagementNumber\r\n },\r\n {\r\n headerName: 'Optional Identifier',\r\n field: 'optionalIdentifier',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Cost Center',\r\n field: 'costCenter',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridCostCenterCellRendererComponent,\r\n cellRendererParams: {\r\n editMode: () => false //this.editMode,\r\n } as ICellRendererParamsForCostCenter\r\n },\r\n {\r\n headerName: '% Allocation',\r\n field: 'allocationPct',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellRendererFramework: AgGridPercentAllocationCellRendererComponent,\r\n cellRendererParams: {\r\n editMode: () => this.editMode,\r\n onBlur: params => {\r\n const revenueShare = params.data as RevenueShare;\r\n this._allocationChange(revenueShare);\r\n }\r\n } as ICellRendererParamsForPercentAllocation\r\n },\r\n {\r\n headerName: 'Fee Amount',\r\n field: 'feeAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: params => {\r\n const revenueShare = params.data as RevenueShare;\r\n return this._currencyPipe.transform(revenueShare.feeAmount, 'USD', 'symbol', '1.2-2');\r\n }\r\n },\r\n {\r\n headerName: 'Expense Amount',\r\n field: 'expenseAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellRendererFramework: AgGridExpenseAmountCellRendererComponent,\r\n cellRendererParams: {\r\n onClick: (params: ICellRendererParamsForExpenseAmount) => {\r\n const revenueShare = params.data as RevenueShare;\r\n this.currentInvoice.expenseIndex = revenueShare.sequence + 1;\r\n this._calculateInvoiceAmounts();\r\n },\r\n editMode: () => this.editMode,\r\n currentInvoice: () => this.currentInvoice\r\n }\r\n },\r\n {\r\n headerName: 'Invoice Amount',\r\n field: 'invoiceAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: params => {\r\n const revenueShare = params.data as RevenueShare;\r\n return this._currencyPipe.transform(revenueShare.invoiceAmount, 'USD', 'symbol', '1.2-2');\r\n }\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: RevenueShareGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canDelete: params => {\r\n const revenueShare = params.data as RevenueShare;\r\n if(!revenueShare) {\r\n return;\r\n }\r\n\r\n return this.editMode && !revenueShare.isAccountHandler && revenueShare.allocationPct === 0 && !revenueShare.isTotal;\r\n },\r\n delete: this._delete.bind(this)\r\n } as ICellRendererParamsForRevenueShareGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'name',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._gridApi.sizeColumnsToFit();\r\n\r\n this._setRowData();\r\n }\r\n\r\n addNew(): void {\r\n const newRevenueShare = new RevenueShare(this.currentInvoice.invoiceId);\r\n newRevenueShare.sequence = this.currentInvoice.invoiceRevenueShareCodes.length;\r\n this.currentInvoice.invoiceRevenueShareCodes.push(newRevenueShare);\r\n this._gridApi.updateRowData({add: [newRevenueShare]});\r\n this._allocationChange();\r\n }\r\n\r\n private _lookupEngagementNumber(params: ICellRendererParamsForRevenueShareGridAction): void {\r\n const revenueShare = params.data as RevenueShare;\r\n\r\n const bsModalRef = this._bsModalService.show(EngagementNumberLookupModalComponent, {class: 'modal-lg'});\r\n bsModalRef.content.title = 'Lookup Engagement Number';\r\n\r\n bsModalRef.content.onClose = (engagement: Engagement) => {\r\n revenueShare.engagementNum = engagement.engagementID;\r\n revenueShare.optionalIdentifier = engagement.optionalIdentifier;\r\n\r\n if (revenueShare.isAccountHandler) {\r\n this.engagementChanged.emit(engagement);\r\n }\r\n else if (revenueShare.sequence == 1) {\r\n // WK-4781: When the RS1 percentage is first set, if the AH percentage is 100%, change it to AH 30% RS1 70%\r\n const aHIdx = _.findIndex(this.currentInvoice.invoiceRevenueShareCodes, 'isAccountHandler');\r\n if (this.currentInvoice.invoiceRevenueShareCodes[aHIdx].allocationPct === 1) {\r\n revenueShare.displayAllocationPct = 70;\r\n this._allocationChange(revenueShare);\r\n }\r\n }\r\n };\r\n }\r\n\r\n private _delete(params: ICellRendererParamsForRevenueShareGridAction): void {\r\n const revenueShare = params.data as RevenueShare;\r\n if (!revenueShare) {\r\n return;\r\n }\r\n _.remove(this.currentInvoice.invoiceRevenueShareCodes, revenueShare);\r\n this._gridApi.updateRowData({remove: [revenueShare]});\r\n\r\n this.currentInvoice.invoiceRevenueShareCodes = _.map(this.currentInvoice.invoiceRevenueShareCodes, (x, i) => {\r\n x.sequence = i;\r\n return x;\r\n });\r\n\r\n this._allocationChange();\r\n }\r\n\r\n private _allocationChange(rs?: RevenueShare): void {\r\n // Validate the input allocation; it must be a number between 0 and 100 inclusive.\r\n if (rs && (rs.displayAllocationPct < 0 || rs.displayAllocationPct > 100)) {\r\n rs.displayAllocationPct = this.invoiceService.getDisplayPercent(rs.allocationPct);\r\n return;\r\n }\r\n\r\n if(rs) {\r\n this._normalizeAllocationPercent(rs);\r\n }\r\n\r\n this.currentInvoice.invoiceRevenueShareCodes = _.map(this.currentInvoice.invoiceRevenueShareCodes, x => {\r\n x.allocationPct = this.invoiceService.getRealPercentFromDisplay(x.displayAllocationPct);\r\n x.feeAmount = this._calculateFeeAmountPercent(x.allocationPct);\r\n return x;\r\n });\r\n\r\n this._ensureFeeAmountsAddUp(); // https://weissmandemo.atlassian.net/browse/PT-1423\r\n this._calculateInvoiceAmounts();\r\n\r\n if(this._gridApi) {\r\n this._gridApi.refreshCells();\r\n this._setTotalRow();\r\n }\r\n }\r\n\r\n private _setRowData() {\r\n this._gridApi.setRowData(this.currentInvoice.invoiceRevenueShareCodes);\r\n this._setTotalRow();\r\n }\r\n\r\n private _setTotalRow() {\r\n const totalRow: RevenueShare = new RevenueShare(null);\r\n totalRow.isTotal = true;\r\n totalRow.feeAmount = this.currentInvoice.totalFeeAmount;\r\n totalRow.invoiceAmount = this.currentInvoice.invoiceAmount;\r\n\r\n this._gridApi.setPinnedBottomRowData([totalRow]);\r\n }\r\n\r\n private _normalizeAllocationPercent(rs: RevenueShare): void {\r\n //Clamp changed value to [0, 100]\r\n rs.displayAllocationPct = _.clamp(rs.displayAllocationPct, 0, 100);\r\n\r\n const totalAllocation = _.reduce(this.currentInvoice.invoiceRevenueShareCodes, (sum, x) => {\r\n return new Decimal(sum).plus(x.displayAllocationPct).toNumber();\r\n }, 0);\r\n\r\n if(totalAllocation === 100) {\r\n //We're at 100. Great!\r\n return;\r\n }\r\n\r\n //We've either got a surplus or deficit\r\n let difference: number = totalAllocation - 100;\r\n\r\n _.forEach(this.currentInvoice.invoiceRevenueShareCodes, x => {\r\n if(x.sequence == rs.sequence) {\r\n return;\r\n }\r\n\r\n if (difference !== 0) {\r\n x.displayAllocationPct -= difference;\r\n difference = 0;\r\n\r\n if (x.displayAllocationPct < 0) {\r\n difference = -x.displayAllocationPct;\r\n x.displayAllocationPct = 0;\r\n }\r\n\r\n if (x.displayAllocationPct > 100) {\r\n difference = x.displayAllocationPct - 100;\r\n x.displayAllocationPct = 100;\r\n }\r\n }\r\n });\r\n }\r\n\r\n private _calculateFeeAmountPercent(percentage: number): number {\r\n const amount = new Decimal(this.currentInvoice.feeAmount || 0).plus(this.currentInvoice.fixedFee || 0).toNumber();\r\n return new Decimal(percentage).times(amount).toNumber();\r\n }\r\n\r\n private _calculateInvoiceAmounts(): void {\r\n this.currentInvoice.invoiceRevenueShareCodes = _.map(this.currentInvoice.invoiceRevenueShareCodes, x => {\r\n x.invoiceAmount = x.feeAmount;\r\n return x;\r\n });\r\n\r\n this.currentInvoice.invoiceRevenueShareCodes[this.currentInvoice.expenseIndex - 1].invoiceAmount = new Decimal(this.currentInvoice.invoiceRevenueShareCodes[this.currentInvoice.expenseIndex - 1].invoiceAmount)\r\n .plus(this.currentInvoice.expenseAmount || 0)\r\n .toNumber();\r\n }\r\n\r\n private _ensureFeeAmountsAddUp() {\r\n const feeAmountSum = _.reduce(this.currentInvoice.invoiceRevenueShareCodes, (sum, rs) => {\r\n return new Decimal(sum).plus(rs.feeAmount).toDecimalPlaces(2).toNumber();\r\n }, 0);\r\n\r\n let feeAmountDiff = new Decimal(feeAmountSum).sub(this.currentInvoice.totalFeeAmount).toNumber();\r\n\r\n _.forEachRight(this.currentInvoice.invoiceRevenueShareCodes, x => {\r\n if(feeAmountDiff === 0) {\r\n return;\r\n }\r\n\r\n const feeAmountDecimal = new Decimal(x.feeAmount).toDecimalPlaces(2);\r\n\r\n if(feeAmountDecimal.toNumber() > 0) {\r\n if(feeAmountDiff > 0) {\r\n x.feeAmount = feeAmountDecimal.sub(0.01).toNumber();\r\n feeAmountDiff -= 0.01;\r\n } else {\r\n x.feeAmount = feeAmountDecimal.add(0.01).toNumber();\r\n feeAmountDiff += 0.01;\r\n }\r\n }\r\n });\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

Invoice Details

\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Parcel Acct NumAppeal LevelTax YearRevisionPrevious FMV\r\n \r\n Invoice FMV\r\n \r\n FMV ChangeTax Rate\r\n \r\n Savings\r\n \r\n
{{appeal.parcelAcctNum}}{{appeal.appealLevelAbbr}}{{appeal.annualYear}}{{appeal.revisionDesc}}{{appeal.previousFMV | number: '1.0-0'}}{{appeal.invoiceFMV | number: '1.0-0'}}\r\n {{appeal.previousFMV - appeal.invoiceFMV | number: '1.0-0'}}\r\n {{appeal.taxRate | percent:'1.6-6'}}\r\n \r\n ${{appeal.savings | number:'1.2-2'}}\r\n \r\n \r\n 1 ? 'block' : 'none'\">\r\n 1\">\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n {{currentInvoice.otherParcelFMV | number: '1.0-0'}}\r\n -\r\n \r\n {{currentInvoice.otherParcelFMV | number: '1.0-0'}}\r\n -\r\n
\r\n Total: \r\n \r\n \r\n \r\n {{currentInvoice.previousFMV | number: '1.0-0'}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n {{currentInvoice.invoiceFMV | number: '1.0-0' }}\r\n \r\n \r\n \r\n {{currentInvoice.fmvChange | number: '1.0-0'}}\r\n \r\n \r\n {{currentInvoice.displayTaxRate | number: '1.6-6'}}%\r\n \r\n \r\n \r\n \r\n \r\n \r\n ${{currentInvoice.savings | number: '1.2-2'}}\r\n \r\n \r\n \r\n
\r\n Notes on Invoice:\r\n \r\n Automatically Update\r\n \r\n Contingency %: \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{currentInvoice.contingencyPct | percent: '1.2-2'}}\r\n \r\n \r\n \r\n
\r\n \r\n \r\n Contingency Cap:\r\n \r\n \r\n \r\n {{currentInvoice.contingencyCap | currency:'USD'}}\r\n \r\n \r\n \r\n
\r\n Contingency Fee Amount:\r\n \r\n \r\n \r\n {{currentInvoice.feeAmount | currency:'USD'}}\r\n \r\n \r\n \r\n
\r\n Fixed Fee Amount:\r\n \r\n \r\n \r\n {{currentInvoice.fixedFee | currency:'USD'}}\r\n \r\n \r\n \r\n
\r\n Expense Amount:\r\n \r\n \r\n {{currentInvoice.expenseAmount | currency:'USD'}}\r\n \r\n \r\n
\r\n Invoice Amount:\r\n \r\n \r\n {{currentInvoice.invoiceAmount | currency:'USD'}}\r\n \r\n
\r\n
\r\n
\r\n","import { Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport {Invoice, InvoiceAppeal, OverrideStatus} from './invoice.model';\r\nimport {InvoiceService} from './invoice.service';\r\nimport {UpgradeNavigationServiceHandler} from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport {DecimalPipe} from '@angular/common';\r\nimport {Constants} from '../../constants.new';\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'invoice-details',\r\n templateUrl: './invoice-details.component.html'\r\n})\r\nexport class InvoiceDetailsComponent implements OnChanges {\r\n constructor(private invoiceService: InvoiceService,\r\n private navigationService: UpgradeNavigationServiceHandler,\r\n private numberPipe: DecimalPipe,\r\n public constants: Constants) {}\r\n\r\n @Input() currentInvoice: Invoice;\r\n @Input() cachedInvoice: Invoice;\r\n @Input() editMode: boolean;\r\n @Input() loading: boolean;\r\n\r\n CalculatedFields = CalculatedFields;\r\n Constant = Constants;\r\n\r\n calculatedFieldChanged(fieldChanged: number): void {\r\n switch(fieldChanged) {\r\n case CalculatedFields.PreviousFMV:\r\n if(!this.currentInvoice.previousFMV) {\r\n this.revertPreviousFMV(false);\r\n }\r\n\r\n break;\r\n case CalculatedFields.InvoiceFMV:\r\n if(!this.currentInvoice.invoiceFMV) {\r\n this.revertInvoiceFMV(false);\r\n } else if(this.currentInvoice.feeAmountStatus === OverrideStatus.Default) {\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Recalculated;\r\n }\r\n\r\n break;\r\n case CalculatedFields.FeeAmount:\r\n if(!this.currentInvoice.feeAmount && this.currentInvoice.feeAmount !== 0) {\r\n this.currentInvoice.feeAmount = this.currentInvoice.calculatedFeeAmount;\r\n }\r\n\r\n if(this.currentInvoice.feeAmount === this.currentInvoice.calculatedFeeAmount) {\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Default;\r\n } else {\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Overridden;\r\n }\r\n\r\n\r\n break;\r\n case CalculatedFields.Savings:\r\n\r\n //if savings is removed, set overridden to false and revert value\r\n if(!this.currentInvoice.savings) {\r\n this.currentInvoice.isSavingsOverridden = false;\r\n this.currentInvoice.savingsStatus = OverrideStatus.Default;\r\n this.currentInvoice.savings = this.currentInvoice.calculatedSavings;\r\n if (this.currentInvoice.taxRateStatus === OverrideStatus.Recalculated ||\r\n this.currentInvoice.taxRateStatus === OverrideStatus.Default) {\r\n if (this.currentInvoice.fmvChangeStatus === OverrideStatus.Recalculated) {\r\n this.currentInvoice.taxRate = this.invoiceService.calculateInitialTaxRate(this.currentInvoice);\r\n }\r\n else {\r\n this.currentInvoice.taxRate =\r\n parseFloat(this.numberPipe.transform(this.currentInvoice.calculatedTaxRate, '1.8-8'));\r\n }\r\n }\r\n } else if (this.currentInvoice.savings !== this.currentInvoice.calculatedSavings) {\r\n //else we're overridden\r\n this.currentInvoice.isSavingsOverridden = true;\r\n this.currentInvoice.savingsStatus = OverrideStatus.Overridden;\r\n\r\n if(this.currentInvoice.feeAmountStatus !== OverrideStatus.Overridden) {\r\n this.currentInvoice.feeAmount = this.invoiceService.calculateFeeAmount(this.currentInvoice);\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Overridden;\r\n }\r\n }\r\n\r\n if(this.currentInvoice.contingencyPctStatus === OverrideStatus.Default &&\r\n this.currentInvoice.contingencyCapStatus === OverrideStatus.Default &&\r\n this.currentInvoice.savingsStatus === OverrideStatus.Default &&\r\n this.currentInvoice.feeAmountStatus !== OverrideStatus.Overridden) {\r\n\r\n this.currentInvoice.feeAmount = this.invoiceService.calculateFeeAmount(this.currentInvoice);\r\n }\r\n\r\n break;\r\n case CalculatedFields.TaxRate:\r\n if(!this.currentInvoice.displayTaxRate) {\r\n this.revertTaxRate(false);\r\n } else {\r\n const newTaxRate = this.invoiceService.getRealPercentFromDisplay(this.currentInvoice.displayTaxRate);\r\n if (newTaxRate !== this.currentInvoice.taxRate) {\r\n this.currentInvoice.taxRate = newTaxRate;\r\n this.currentInvoice.taxRateStatus = OverrideStatus.Overridden;\r\n this.currentInvoice.isSavingsOverridden = false;\r\n // Since we know we're overriding the tax status, go redo the savings and set its status\r\n // to recalculated (that's the only possible outcome of this operation at this point)\r\n this.currentInvoice.savingsStatus = OverrideStatus.Recalculated;\r\n this.currentInvoice.savings = this.invoiceService.calculateSavings(this.currentInvoice);\r\n if(this.currentInvoice.feeAmountStatus !== OverrideStatus.Overridden) {\r\n this.currentInvoice.feeAmount = this.invoiceService.calculateFeeAmount(this.currentInvoice);\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Overridden;\r\n }\r\n }\r\n }\r\n\r\n break;\r\n case CalculatedFields.ContingencyPct:\r\n const clearContingencyPct = !this.currentInvoice.displayContingencyPct && this.currentInvoice.displayContingencyPct !== 0;\r\n // Get the real data from the display data\r\n if(!clearContingencyPct) {\r\n this.currentInvoice.contingencyPct = this.invoiceService.getRealPercentFromDisplay(this.currentInvoice.displayContingencyPct);\r\n }\r\n\r\n // Revert to original values if empty\r\n if(clearContingencyPct) {\r\n this.currentInvoice.contingencyPct = this.currentInvoice.contingencyPctOriginal;\r\n this.currentInvoice.displayContingencyPct = this.invoiceService.getDisplayPercent(this.currentInvoice.contingencyPct);\r\n }\r\n\r\n // Set override status\r\n if(this.currentInvoice.contingencyPct === this.currentInvoice.contingencyPctOriginal) {\r\n this.currentInvoice.contingencyPctStatus = OverrideStatus.Default;\r\n\r\n //If this AND cap are reverted, then also set the fee amount\r\n if(this.currentInvoice.contingencyCapStatus === OverrideStatus.Default &&\r\n this.currentInvoice.savingsStatus === OverrideStatus.Default &&\r\n this.currentInvoice.feeAmountStatus !== OverrideStatus.Overridden) {\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Default;\r\n this.currentInvoice.feeAmount = this.invoiceService.calculateFeeAmount(this.currentInvoice);\r\n }\r\n } else {\r\n this.currentInvoice.contingencyPctStatus = OverrideStatus.Overridden;\r\n }\r\n\r\n break;\r\n case CalculatedFields.ContingencyCap:\r\n if(!this.currentInvoice.contingencyCap) {\r\n this.currentInvoice.contingencyCap = this.currentInvoice.contingencyCapOriginal;\r\n }\r\n\r\n if(this.currentInvoice.contingencyCap === this.currentInvoice.contingencyCapOriginal) {\r\n this.currentInvoice.contingencyCapStatus = OverrideStatus.Default;\r\n //If this, savings, AND cap are reverted, then also set the fee amount\r\n if(this.currentInvoice.contingencyPctStatus === OverrideStatus.Default &&\r\n this.currentInvoice.savingsStatus === OverrideStatus.Default &&\r\n this.currentInvoice.feeAmountStatus !== OverrideStatus.Overridden) {\r\n\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Default;\r\n this.currentInvoice.feeAmount = this.invoiceService.calculateFeeAmount(this.currentInvoice);\r\n }\r\n } else {\r\n this.currentInvoice.contingencyCapStatus = OverrideStatus.Overridden;\r\n }\r\n break;\r\n case this.CalculatedFields.ExpenseAmount:\r\n if(!this.currentInvoice.expenseAmount) {\r\n this.currentInvoice.expenseAmount = 0;\r\n }\r\n case this.CalculatedFields.FixedFee:\r\n if (!this.currentInvoice.fixedFee && this.currentInvoice.fixedFee !== 0) {\r\n this.currentInvoice.fixedFee = this.currentInvoice.fixedFeeOriginal;\r\n }\r\n\r\n if (this.currentInvoice.fixedFee === this.currentInvoice.fixedFeeOriginal) {\r\n this.currentInvoice.fixedFeeStatus = OverrideStatus.Default;\r\n }\r\n else {\r\n this.currentInvoice.fixedFeeStatus = OverrideStatus.Overridden;\r\n }\r\n default:\r\n break;\r\n }\r\n\r\n this.currentInvoice = this.invoiceService.calculateInvoiceData(this.currentInvoice);\r\n }\r\n\r\n revertPreviousFMV(shouldCalcInvoiceData: boolean): void {\r\n if (this.currentInvoice.previousFMVStatus === OverrideStatus.Overridden &&\r\n this.currentInvoice.invoiceFMVStatus === OverrideStatus.Default) {\r\n if (this.currentInvoice.taxRateStatus === OverrideStatus.Recalculated &&\r\n this.currentInvoice.savingsStatus === OverrideStatus.Recalculated) {\r\n // The basis for the tax rate/savings calculations changes when we switch from overriden FMV change\r\n // back to default; if the tax rate and savings are already both in a recalculated state, we want\r\n // to restore to a \"pristine\" state, so restore the savings here\r\n this.currentInvoice = this.invoiceService.resetTotalSavings(this.currentInvoice);\r\n }\r\n }\r\n\r\n this.currentInvoice.previousFMV = this.currentInvoice.calculatedPreviousFMV;\r\n\r\n if(shouldCalcInvoiceData) {\r\n this.currentInvoice = this.invoiceService.calculateInvoiceData(this.currentInvoice);\r\n }\r\n }\r\n\r\n revertInvoiceFMV(shouldCalcInvoiceData: boolean): void {\r\n if (this.currentInvoice.invoiceFMVStatus === OverrideStatus.Overridden &&\r\n this.currentInvoice.previousFMVStatus === OverrideStatus.Default) {\r\n if (this.currentInvoice.taxRateStatus === OverrideStatus.Recalculated &&\r\n this.currentInvoice.savingsStatus === OverrideStatus.Recalculated) {\r\n // (same as above)\r\n this.currentInvoice = this.invoiceService.resetTotalSavings(this.currentInvoice);\r\n }\r\n }\r\n\r\n this.currentInvoice.invoiceFMV = this.currentInvoice.calculatedInvoiceFMV;\r\n\r\n if(shouldCalcInvoiceData) {\r\n this.currentInvoice = this.invoiceService.calculateInvoiceData(this.currentInvoice);\r\n }\r\n\r\n }\r\n\r\n revertFeeAmount(): void {\r\n this.currentInvoice.feeAmount = this.currentInvoice.calculatedFeeAmount;\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Default;\r\n\r\n this.currentInvoice = this.invoiceService.calculateInvoiceData(this.currentInvoice);\r\n }\r\n\r\n revertSavings(): void {\r\n this.currentInvoice.isSavingsOverridden = false;\r\n this.currentInvoice.savingsStatus = OverrideStatus.Default;\r\n this.currentInvoice.savings = this.currentInvoice.calculatedSavings;\r\n if (this.currentInvoice.taxRateStatus === OverrideStatus.Recalculated ||\r\n this.currentInvoice.taxRateStatus === OverrideStatus.Default) {\r\n if (this.currentInvoice.fmvChangeStatus === OverrideStatus.Recalculated) {\r\n this.currentInvoice.taxRate = this.invoiceService.calculateInitialTaxRate(this.currentInvoice);\r\n }\r\n else {\r\n this.currentInvoice.taxRate =\r\n parseFloat(this.numberPipe.transform(this.currentInvoice.calculatedTaxRate, '1.8-8'));\r\n }\r\n }\r\n\r\n if(this.currentInvoice.contingencyPctStatus === OverrideStatus.Default &&\r\n this.currentInvoice.contingencyCapStatus === OverrideStatus.Default &&\r\n this.currentInvoice.savingsStatus === OverrideStatus.Default &&\r\n this.currentInvoice.feeAmountStatus !== OverrideStatus.Overridden) {\r\n\r\n this.currentInvoice.feeAmount = this.invoiceService.calculateFeeAmount(this.currentInvoice);\r\n }\r\n\r\n this.currentInvoice = this.invoiceService.calculateInvoiceData(this.currentInvoice);\r\n }\r\n\r\n revertTaxRate(shouldCalcInvoiceData: boolean): void {\r\n this.currentInvoice.taxRate = parseFloat(this.numberPipe.transform(this.currentInvoice.calculatedTaxRate, '1.8-8'));\r\n this.currentInvoice.displayTaxRate = this.invoiceService.getDisplayPercent(this.currentInvoice.taxRate);\r\n if (this.currentInvoice.savingsStatus === OverrideStatus.Default ||\r\n this.currentInvoice.savingsStatus === OverrideStatus.Recalculated) {\r\n this.currentInvoice = this.invoiceService.resetTotalSavings(this.currentInvoice);\r\n }\r\n\r\n if(shouldCalcInvoiceData) {\r\n this.currentInvoice = this.invoiceService.calculateInvoiceData(this.currentInvoice);\r\n }\r\n }\r\n\r\n revertContingencyPct(): void {\r\n this.currentInvoice.contingencyPct = this.currentInvoice.contingencyPctOriginal;\r\n this.currentInvoice.displayContingencyPct = this.invoiceService.getDisplayPercent(this.currentInvoice.contingencyPct);\r\n\r\n this.currentInvoice.contingencyPctStatus = OverrideStatus.Default;\r\n\r\n //If this AND cap are reverted, then also set the fee amount\r\n if(this.currentInvoice.contingencyCapStatus === OverrideStatus.Default &&\r\n this.currentInvoice.savingsStatus === OverrideStatus.Default &&\r\n this.currentInvoice.feeAmountStatus !== OverrideStatus.Overridden) {\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Default;\r\n this.currentInvoice.feeAmount = this.invoiceService.calculateFeeAmount(this.currentInvoice);\r\n }\r\n\r\n this.currentInvoice = this.invoiceService.calculateInvoiceData(this.currentInvoice);\r\n }\r\n\r\n revertContingencyCap(): void {\r\n this.currentInvoice.contingencyCap = this.currentInvoice.contingencyCapOriginal;\r\n\r\n this.currentInvoice.contingencyCapStatus = OverrideStatus.Default;\r\n //If this, savings, AND cap are reverted, then also set the fee amount\r\n if(this.currentInvoice.contingencyPctStatus === OverrideStatus.Default &&\r\n this.currentInvoice.savingsStatus === OverrideStatus.Default &&\r\n this.currentInvoice.feeAmountStatus !== OverrideStatus.Overridden) {\r\n\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Default;\r\n this.currentInvoice.feeAmount = this.invoiceService.calculateFeeAmount(this.currentInvoice);\r\n }\r\n\r\n this.currentInvoice = this.invoiceService.calculateInvoiceData(this.currentInvoice);\r\n }\r\n\r\n revertFixedFee(): void {\r\n this.currentInvoice.fixedFee = this.currentInvoice.fixedFeeOriginal;\r\n this.currentInvoice.fixedFeeStatus = OverrideStatus.Default;\r\n\r\n this.currentInvoice = this.invoiceService.calculateInvoiceData(this.currentInvoice);\r\n }\r\n\r\n includeOtherParcelChange(): void {\r\n this.currentInvoice = this.invoiceService.resetFromAppealData(this.currentInvoice, true);\r\n }\r\n\r\n async refreshCurrentInvoice(): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n this.currentInvoice = await this.invoiceService.refreshInvoice(this.currentInvoice);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n automatedNoteChange(): void {\r\n if(this.currentInvoice.automaticallyUpdateNotes) {\r\n this.currentInvoice.notes = this.invoiceService.generateNotes(this.currentInvoice);\r\n }\r\n }\r\n\r\n removeAppeal(appealIndex: number): void {\r\n this.currentInvoice = this.invoiceService.removeAppeal(this.currentInvoice, appealIndex);\r\n }\r\n\r\n navigateToParcel(appeal: InvoiceAppeal): void {\r\n const parcelHref = this.navigationService.getHrefFromState('parcel', { parcelId: appeal.parcelID, siteId: this.currentInvoice.siteId, companyId: this.currentInvoice.companyId});\r\n window.open(parcelHref, '_blank');\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.currentInvoice) {\r\n this.currentInvoice = changes.currentInvoice.currentValue;\r\n this.automatedNoteChange();\r\n }\r\n }\r\n}\r\n\r\n\r\nexport enum CalculatedFields {\r\n PreviousFMV = 1,\r\n InvoiceFMV = 2,\r\n Savings = 3,\r\n TaxRate = 4,\r\n FeeAmount = 5,\r\n ExpenseAmount = 6,\r\n ContingencyPct = 7,\r\n ContingencyCap = 8,\r\n FixedFee = 9\r\n}\r\n","\r\n \r\n\r\n\r\n\r\n No recipient selected\r\n
\r\n {{selectedRecipient.clientName}}\r\n
{{selectedRecipient.name}}\r\n
{{selectedRecipient.title}}\r\n
{{selectedRecipient.address1}}\r\n
{{selectedRecipient.address2}}\r\n
{{selectedRecipient.city}}\r\n , {{selectedRecipient.state}} {{selectedRecipient.postalCode}}\r\n
\r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ContractsInvoicesService } from './contract-invoices.service';\r\nimport { InvoiceRecipient } from './contract-invoices.model';\r\nimport { Invoice } from '../../Processing/Invoice/invoice.model';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'invoice-recipient-lookup',\r\n templateUrl: './invoice-recipient-lookup.component.html'\r\n})\r\nexport class InvoiceRecipientLookupComponent implements OnInit {\r\n constructor(private contractsInvoicesService: ContractsInvoicesService) { }\r\n\r\n @Input() invoice: Invoice;\r\n @Input() editMode: boolean;\r\n\r\n recipients: InvoiceRecipient[] = [];\r\n selectedRecipient: InvoiceRecipient;\r\n\r\n ngOnInit() {\r\n if(this.invoice.invoiceRevenueShareCodes[0] && this.invoice.invoiceRevenueShareCodes[0].engagementNum) {\r\n this.getRecipientList();\r\n }\r\n }\r\n\r\n getRecipientList(): void {\r\n this.contractsInvoicesService.getInvoiceRecipientsByEngagement(this.invoice.invoiceRevenueShareCodes[0].engagementNum)\r\n .then((result: InvoiceRecipient[]) => {\r\n this.recipients = result;\r\n\r\n this.setSelectedRecipient();\r\n this.recipientChanged();\r\n });\r\n }\r\n\r\n recipientChanged(): void {\r\n if(!this.selectedRecipient) {\r\n this.invoice.recipientName = '';\r\n\r\n return;\r\n }\r\n\r\n this.invoice.recipientName = this.selectedRecipient.name;\r\n\r\n let recipientMailingAddress: string = `${this.selectedRecipient.address1 }, `;\r\n recipientMailingAddress += this.selectedRecipient.address2 ? (`${this.selectedRecipient.address2 }, `) : '';\r\n recipientMailingAddress += `${this.selectedRecipient.city }, ${ this.selectedRecipient.state } ${ this.selectedRecipient.postalCode}`;\r\n\r\n this.invoice.recipientMailingAddress = recipientMailingAddress;\r\n this.invoice.recipientCdsContactId = this.selectedRecipient.cdsBillingContactID;\r\n }\r\n\r\n setSelectedRecipient(): void {\r\n this.selectedRecipient = _.find(this.recipients, { name: this.invoice.recipientName }) as InvoiceRecipient;\r\n }\r\n}","
\r\n
\r\n
\r\n
    \r\n
  1. \r\n {{currentInvoice.companyName}}\r\n
  2. \r\n
  3. \r\n {{currentInvoice.siteName}}\r\n
  4. \r\n
  5. Invoice
  6. \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Invoice

\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n {{ invoiceService.contractServiceName(currentInvoice.contractServiceType) }}\r\n (ad hoc)\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n {{ currentInvoice.companyName }}\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n {{ currentInvoice.accountHandler.firstName }} {{currentInvoice.accountHandler.lastName}}\r\n
\r\n
\r\n
\r\n
\r\n \r\n {{ currentInvoice.invoiceUBRNumber }}\r\n Draft\r\n
\r\n
\r\n
\r\n
\r\n \r\n {{ currentInvoice.invoiceNumber }}\r\n Draft\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnInit, ViewChild } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { Invoice, InvoiceRouteNames, InvoiceTypes, OverrideStatus } from './invoice.model';\r\nimport {InvoiceService} from './invoice.service';\r\nimport {TaskService} from '../../Task/task.service.upgrade';\r\nimport {Constants, EntityType, TaskType, ContractServiceType} from '../../constants.new';\r\nimport {MessageBoxButtons, MessageBoxService} from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { InvoiceRecipientLookupComponent } from '../../Common/Contracts-Invoices/invoice-recipient-lookup.component';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport {AttachmentModalData, AttachmentModalEntityData} from '../../Attachment/attachment.modal.model';\r\nimport {CommentModalData} from '../../Comments/comments.service';\r\nimport {NavigationService} from '../../Layout/navigation.service';\r\nimport { ActionViewPersistenceService } from '../../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport {RestrictService, Roles} from '../../Common/Permissions/restrict.service';\r\nimport * as _ from 'lodash';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { ContractTerm, SiteContractTerm, TermItem } from 'src/app/Common/Contracts-Invoices/contract-invoices.model';\r\nimport { ContractsInvoicesService } from '../../Common/Contracts-Invoices/contract-invoices.service';\r\n\r\n@Component({\r\n selector: 'invoice',\r\n templateUrl: './invoice.component.html'\r\n})\r\nexport class ProcessInvoiceComponent implements OnInit {\r\n constructor(public invoiceService: InvoiceService,\r\n private navigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private navigationService: NavigationService,\r\n private actionViewPersistenceService: ActionViewPersistenceService,\r\n private taskService: TaskService,\r\n private constants: Constants,\r\n private messageBox: MessageBoxService,\r\n private toastr: ToastrService,\r\n restrictService: RestrictService,\r\n featureFlagsService: FeatureFlagsService,\r\n private readonly _contractsInvoicesService: ContractsInvoicesService\r\n ) {\r\n this.canTransferToRIBS = restrictService.isInRole(Roles.FINANCIALANALYST);\r\n this.enableInvoiceUBR = featureFlagsService.featureFlags.enableInvoiceUBR;\r\n this.isRyanLegalServiceEnabled = featureFlagsService.featureFlags.enableInvoiceRLS;\r\n }\r\n\r\n @ViewChild('invoiceRecipientLookup') invoiceRecipientLookup: InvoiceRecipientLookupComponent;\r\n\r\n canTransferToRIBS: boolean;\r\n // Primary invoice object\r\n currentInvoice: Invoice;\r\n cachedInvoice: Invoice;\r\n\r\n //If there's a queue, this will be populated (aka from Action View)\r\n taskList: number[];\r\n taskIndex: number = 0;\r\n\r\n InvoiceTypes = InvoiceTypes;\r\n ContractServiceType = ContractServiceType;\r\n\r\n editMode: boolean = false;\r\n taskOnlyEditMode: boolean = false;\r\n isInvoiceCompleted: boolean = false;\r\n loading: boolean = true;\r\n callInProgress: boolean = false;\r\n\r\n attachmentData: AttachmentModalData;\r\n commentData: CommentModalData;\r\n\r\n companyUrl: string;\r\n siteUrl: string;\r\n\r\n completeText: string;\r\n closeText: string;\r\n currentState: any;\r\n navigationWarningText: string = 'If you continue you will lose your unsaved changes. Do you wish to continue?';\r\n\r\n enableInvoiceUBR: boolean;\r\n isRyanLegalServiceEnabled: boolean;\r\n\r\n canChangeContractType: boolean = false;\r\n isAppealSavingsInvoice: boolean = false;\r\n appealContractTypes: Compliance.NameValuePair[] = [];\r\n companyAppealContractTerms: ContractTerm[] = [];\r\n currentContractTermDetailId: number;\r\n\r\n private _siteAppealContractTerms: SiteContractTerm[];\r\n private _currentContractTerm: ContractTerm;\r\n private _isContractTermOverridden: boolean = false;\r\n\r\n get contractTerm(): ContractTerm {\r\n return this._currentContractTerm;\r\n }\r\n\r\n get isContractTermOverridden(): boolean {\r\n return this._isContractTermOverridden;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n await this.setupPage();\r\n }\r\n\r\n async setupPage(): Promise {\r\n const state: any = this.navigationServiceHandler.getCurrentState();\r\n let invoiceId: string;\r\n\r\n this.currentState = state;\r\n\r\n if(state.name === InvoiceRouteNames.Company || state.name === InvoiceRouteNames.Site) {\r\n invoiceId = this.navigationServiceHandler.getQuerystringParam('invoiceID');\r\n await this.getInvoiceById(invoiceId);\r\n } else if(state.name === InvoiceRouteNames.Processing) {\r\n const draftId = this.navigationServiceHandler.getQuerystringParam('draftId');\r\n const taskString: string = sessionStorage[`InvoiceDrafts${ draftId}`];\r\n this.taskList = JSON.parse(taskString);\r\n this.editMode = true;\r\n this.navigationService.enableNavWarning(this.navigationWarningText);\r\n await this.getInvoiceForTask(this.taskList[this.taskIndex]);\r\n }\r\n\r\n this.isAppealSavingsInvoice = !this.currentInvoice.isAdHoc && (this.currentInvoice.contractServiceType === ContractServiceType.Appeal ||\r\n this.currentInvoice.contractServiceType === ContractServiceType.Litigation);\r\n\r\n if (this.isAppealSavingsInvoice) {\r\n this.appealContractTypes = Object\r\n .keys(this.constants.ContractServiceTypes)\r\n .map(key => { return { value: this.constants.ContractServiceTypes[key].id, name: this.constants.ContractServiceTypes[key].name }; })\r\n .filter(t => t.value === ContractServiceType.Appeal || t.value === ContractServiceType.Litigation);\r\n\r\n this._siteAppealContractTerms = await this._contractsInvoicesService.getContractTermsBySite(this.currentInvoice.siteId);\r\n\r\n const hasLitigationContractTypes = this._siteAppealContractTerms.some(x => x.serviceId === ContractServiceType.Litigation &&\r\n (!x.taxYear || x.taxYear === this.currentInvoice.annualYear));\r\n const hasAppealContractTypes = this._siteAppealContractTerms.some(x => x.serviceId === ContractServiceType.Appeal &&\r\n (!x.taxYear || x.taxYear === this.currentInvoice.annualYear));\r\n this.canChangeContractType = hasLitigationContractTypes && hasAppealContractTypes;\r\n\r\n const companyContractTerms = await this._contractsInvoicesService.getContractTermsByCompany(this.currentInvoice.companyId);\r\n const currentCompanyContractTerms = companyContractTerms.currentContractTerms?.length > 0\r\n ? companyContractTerms.currentContractTerms\r\n : companyContractTerms.topLevelCompanyContractTerms;\r\n this.companyAppealContractTerms = currentCompanyContractTerms\r\n .filter(x => x.contractServiceTypeId === this.currentInvoice.contractServiceType &&\r\n (!x.taxYear || x.taxYear === this.currentInvoice.annualYear));\r\n this._calculateCurrentTermId();\r\n }\r\n\r\n this._currentContractTerm = {\r\n contingencyPct: this.currentInvoice?.contingencyPctOriginal,\r\n contingencyCap: this.currentInvoice?.contingencyCapOriginal,\r\n flatFee: this.currentInvoice?.fixedFeeOriginal\r\n } as ContractTerm;\r\n }\r\n\r\n async getInvoiceById(invoiceId: string): Promise {\r\n this.loading = true;\r\n const companyIDErrMsg = 'Company ID does not match Invoice';\r\n const siteIDErrMsg = 'Site ID does not match Invoice';\r\n const notFoundErrMsg = 'Invoice not found';\r\n\r\n try {\r\n const resultInvoice = await this.invoiceService.getInvoice(invoiceId);\r\n const companyIDParam = this.navigationServiceHandler.getQuerystringParam('companyID');\r\n const siteIDParam = this.navigationServiceHandler.getQuerystringParam('siteID');\r\n if (companyIDParam && +companyIDParam != resultInvoice.companyId) {\r\n throw new Error(companyIDErrMsg);\r\n }\r\n if (siteIDParam && +siteIDParam != resultInvoice.siteId) {\r\n throw new Error(siteIDErrMsg);\r\n }\r\n\r\n this.currentInvoice = resultInvoice;\r\n this.stashCurrentInvoice(resultInvoice);\r\n\r\n this.setButtonText();\r\n this.setAttachmentAndComments();\r\n this.isInvoiceCompleted = !this.currentInvoice.readyTaskId;\r\n\r\n this.companyUrl = this.navigationServiceHandler.getHrefFromState('company', { companyId: this.currentInvoice.companyId });\r\n this.siteUrl = this.navigationServiceHandler.getHrefFromState('site', { companyId: this.currentInvoice.companyId, siteId: this.currentInvoice.siteId });\r\n\r\n return this.currentInvoice;\r\n } catch (err: any) {\r\n if ([companyIDErrMsg, siteIDErrMsg, notFoundErrMsg].indexOf(err.message) >= 0) {\r\n this.toastr.error(err.message);\r\n }\r\n throw err;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async getInvoiceForTask(taskId: number): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n const resultInvoice = await this.invoiceService.getInvoiceForTask(taskId);\r\n this.currentInvoice = resultInvoice;\r\n this.stashCurrentInvoice(resultInvoice);\r\n\r\n this.setButtonText();\r\n this.setAttachmentAndComments();\r\n\r\n this.companyUrl = this.navigationServiceHandler.getHrefFromState('company', {companyId: this.currentInvoice.companyId});\r\n this.siteUrl = this.navigationServiceHandler.getHrefFromState('site', {companyId: this.currentInvoice.companyId, siteId: this.currentInvoice.siteId});\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n setAttachmentAndComments(): void {\r\n this.attachmentData = new AttachmentModalData();\r\n this.commentData = new CommentModalData();\r\n\r\n this.commentData.entityID = this.currentInvoice.invoiceId;\r\n this.commentData.entityTypeID = EntityType.Invoice;\r\n this.commentData.description = 'Invoice';\r\n this.commentData.year = this.currentInvoice.annualYear.toString();\r\n this.commentData.canEdit = true;\r\n //TODO: Permission?\r\n\r\n this.attachmentData.entityData = new AttachmentModalEntityData();\r\n this.attachmentData.entityData.id = this.currentInvoice.invoiceId;\r\n this.attachmentData.entityData.typeId = EntityType.Invoice;\r\n this.attachmentData.entityData.name = 'invoice';\r\n // vvvv WK-9232 Invoice attachments can have no year\r\n // this.attachmentData.disableYears = true;\r\n // this.attachmentData.year = this.currentInvoice.annualYear;\r\n this.attachmentData.singleYear = true;\r\n //this.attachmentData.entityName = this.currentInvoice.invoiceNumber ? this.currentInvoice.invoiceNumber.toString() : '(draft)';\r\n this.attachmentData.entityType = 'Invoice';\r\n this.attachmentData.readOnly = !this.currentInvoice.readyTaskId;\r\n }\r\n\r\n setEditMode(): void {\r\n // Normally hitting \"edit\" means you can edit the invoice; however if it's completed, we still want an edit button\r\n // so the user can change tasks (WK-4287). Instead of trying to lock down parts of the interface in edit mode\r\n // when the invoice is complete, we'll use a single flag to indicate we're just allowing status edits\r\n if (!this.isInvoiceCompleted) {\r\n this.editMode = true;\r\n this.navigationService.enableNavWarning(this.navigationWarningText);\r\n\r\n //stash the current invoice in case of cancel\r\n this.cachedInvoice = _.cloneDeep(this.currentInvoice);\r\n }\r\n else {\r\n this.taskOnlyEditMode = true;\r\n this.navigationService.enableNavWarning(this.navigationWarningText);\r\n }\r\n }\r\n\r\n showCompleteButton(): boolean {\r\n return this.editMode && this.currentInvoice && (this.currentInvoice.readyTaskTypeId !== TaskType.TransferInvoiceToRIBS || this.canTransferToRIBS);\r\n }\r\n\r\n setButtonText(): void {\r\n switch(this.currentInvoice.readyTaskTypeId) {\r\n case TaskType.PrepareDraftInvoice:\r\n this.completeText = 'Complete Draft (Request Review)';\r\n break;\r\n case TaskType.ReviewDraftInvoice:\r\n this.completeText = `Complete Review (Request ${this.currentInvoice.isUBR ? 'UBR ' : ''}RIBS Transfer)`;\r\n break;\r\n case TaskType.TransferUBRToRIBS:\r\n this.completeText = 'Transfer UBR to RIBS (Request Relief of UBR)';\r\n break;\r\n case TaskType.RequestReliefOfUBR:\r\n this.completeText = 'Request Relief of UBR (Request RIBS Transfer)';\r\n break;\r\n case TaskType.TransferInvoiceToRIBS:\r\n this.completeText = 'Transfer to RIBS';\r\n break;\r\n case TaskType.AdjustInvoice:\r\n this.completeText = 'Complete Adjust Invoice';\r\n break;\r\n }\r\n\r\n if(this.taskList && this.taskList.length > 1 && (this.taskIndex < (this.taskList.length-1))) {\r\n this.completeText += ' and Show Next';\r\n this.closeText = 'Skip';\r\n } else {\r\n this.closeText = 'Close';\r\n }\r\n }\r\n\r\n cancelEdit(): void {\r\n if (this.taskOnlyEditMode) {\r\n this.taskOnlyEditMode = false;\r\n }\r\n else {\r\n //Warn users if there's data lost\r\n //Reset the currentInvoice from cache if necessary\r\n _.assign(this.currentInvoice, _.cloneDeep(this.cachedInvoice));\r\n\r\n // Reset the selected recipient\r\n this.invoiceRecipientLookup.setSelectedRecipient();\r\n\r\n //Clear cache version\r\n this.cachedInvoice = null;\r\n\r\n //Set edit mode false\r\n this.editMode = false;\r\n\r\n this._calculateCurrentTermId();\r\n }\r\n\r\n this.navigationService.disableNavWarning();\r\n }\r\n\r\n nextTask(): void {\r\n //TODO: If there are more tasks, get the next invoice\r\n console.log('Next task');\r\n }\r\n\r\n goToSite(): void {\r\n this.navigationServiceHandler.transitionTo('site', {companyId: this.currentInvoice.companyId, siteId: this.currentInvoice.siteId});\r\n }\r\n\r\n goToCompany(): void {\r\n const href: string = this.navigationServiceHandler.getHrefFromState('company', {companyId: this.currentInvoice.companyId});\r\n window.open(href, '_blank');\r\n }\r\n\r\n async launchTaskModal(): Promise {\r\n // if not in edit mode just open the tasks modal\r\n if (!this.editMode) {\r\n if (this.taskOnlyEditMode) {\r\n // In this case, the invoice is complete; if the user opens the task modal and rescinds a task, it's likely that the page\r\n // was originally loaded with the assumption that the invoice was complete, and that is now not true. Just reload the data\r\n // in that case so we can rebuild the page under the correct assumption about the invoice's complete status\r\n this.taskService.launchTaskModal(this.currentInvoice.invoiceId, EntityType.Invoice, false, null, false).then(shouldReload => {\r\n if (shouldReload) {\r\n this.taskOnlyEditMode = false;\r\n this.setupPage();\r\n }\r\n });\r\n }\r\n else {\r\n await this.taskService.launchTaskModal(this.currentInvoice.invoiceId, EntityType.Invoice, true, null, true);\r\n }\r\n return;\r\n }\r\n\r\n try {\r\n // in edit mode, check to see if there have been any changes\r\n // if there have been changes save them otherwise keep current invoice\r\n await (this._hasChanges() ? this.save() : Promise.resolve(this.currentInvoice));\r\n\r\n // open tasks modal\r\n const hasChanges = await this.taskService.launchTaskModal(this.currentInvoice.invoiceId, EntityType.Invoice, false, null, false);\r\n // if any changes were made in the modal then reload the current invoice so we can get the updated status\r\n if (hasChanges) {\r\n await this.setupPage();\r\n // done reloading, if we're still in edit mode (no changes were previously saved) then exit edit mode\r\n if (this.editMode) {\r\n this.cancelEdit();\r\n }\r\n }\r\n } catch (err) {\r\n this._rejectHandler(err);\r\n }\r\n }\r\n\r\n save(): Promise {\r\n const validationMessage: string = this._getValidationMessage();\r\n\r\n if(validationMessage) {\r\n this.toastr.error(validationMessage);\r\n\r\n return;\r\n }\r\n\r\n this.loading = true;\r\n return this.invoiceService.saveInvoice(this.currentInvoice).then((newInvoice: Invoice) => {\r\n const calcInvoice: Invoice = this.invoiceService.calculateInvoiceData(newInvoice);\r\n this.currentInvoice = calcInvoice;\r\n this.cachedInvoice = calcInvoice;\r\n\r\n this.editMode = false;\r\n this.navigationService.disableNavWarning();\r\n\r\n this.loading = false;\r\n this.toastr.success('Your invoice has successfully been saved', 'Success');\r\n\r\n this._calculateCurrentTermId();\r\n\r\n return Promise.resolve(this.currentInvoice);\r\n }).catch((error) => {\r\n this.loading = false;\r\n return Promise.reject(error);\r\n });\r\n }\r\n\r\n _getValidationMessage(): string {\r\n if( (this.currentInvoice.previousFMV || this.currentInvoice.previousFMV == 0)\r\n && (this.currentInvoice.invoiceFMV || this.currentInvoice.previousFMV == 0)\r\n && this.currentInvoice.previousFMV < this.currentInvoice.invoiceFMV) {\r\n return 'Previous FMV cannot be less than Invoice FMV!';\r\n }\r\n\r\n if(this.currentInvoice.feeAmountStatus == 'red'\r\n && (this.currentInvoice.feeAmount || this.currentInvoice.previousFMV == 0)\r\n && (this.currentInvoice.contingencyCap || this.currentInvoice.previousFMV == 0)\r\n && this.currentInvoice.feeAmount > this.currentInvoice.contingencyCap) {\r\n return 'Fee Amount cannot be greater than Contingency Cap!';\r\n }\r\n\r\n return '';\r\n }\r\n\r\n delete(): void {\r\n this.messageBox.confirm('Are you sure you wish to delete this invoice?').then(async () => {\r\n this.navigationService.disableNavWarning();\r\n this.loading = true;\r\n\r\n try {\r\n await this.invoiceService.deleteInvoice(this.currentInvoice.invoiceId);\r\n this.navigateBackHandler();\r\n } finally {\r\n this.loading = false;\r\n }\r\n });\r\n }\r\n\r\n complete(): void {\r\n if(this.currentInvoice.readyTaskTypeId == TaskType.TransferInvoiceToRIBS && !this.currentInvoice.thirdPartyApprovalDate) {\r\n this.toastr.error('Third Party Approval Date required for transfer to RIBS');\r\n\r\n return;\r\n }\r\n\r\n this.callInProgress = true;\r\n\r\n this.invoiceService.completeInvoice(this.currentInvoice).then((returnedInvoice: Invoice) => {\r\n this.currentInvoice = returnedInvoice;\r\n this.cachedInvoice = returnedInvoice;\r\n\r\n this.toastr.success('Invoice successfully completed', 'Success!');\r\n this.setButtonText();\r\n\r\n this.callInProgress = false;\r\n\r\n const state: any = this.navigationServiceHandler.getCurrentState();\r\n if(state.name === InvoiceRouteNames.Processing) {\r\n\r\n if(this.taskIndex < this.taskList.length-1) {\r\n this.taskIndex++;\r\n this.currentInvoice = null;\r\n this.cachedInvoice = null;\r\n this.getInvoiceForTask(this.taskList[this.taskIndex]);\r\n } else {\r\n this.loading = true;\r\n this.currentInvoice = null;\r\n this.cachedInvoice = null;\r\n\r\n this.messageBox.open({\r\n title: 'SUCCESS',\r\n message: 'You have successfully completed all invoices. Click ok to return',\r\n buttons: MessageBoxButtons.OK}).then(() => {\r\n this.navigationService.disableNavWarning();\r\n this.navigateBackHandler();\r\n });\r\n }\r\n } else {\r\n this.messageBox.open({\r\n title: 'SUCCESS',\r\n message: 'You have successfully completed your invoice. Click ok to return',\r\n buttons: MessageBoxButtons.OK}).then(() => {\r\n this.navigationService.disableNavWarning();\r\n this.navigateBackHandler();\r\n });\r\n }\r\n }, (error:any) => {\r\n // If a 400 returns an array, they're validation errors\r\n if (error.status === 400 && _.isArray(error.data)) {\r\n this.toastr.warning(error.data.join(', '), 'Problem completing invoice');\r\n }\r\n\r\n this.callInProgress = false;\r\n });\r\n }\r\n\r\n skipInvoice(): void {\r\n const hasChangesPromise: Promise = this._hasChanges() ? this.messageBox.confirm(this.navigationWarningText) : Promise.resolve();\r\n\r\n hasChangesPromise.then(() => {\r\n if(this.taskIndex < this.taskList.length-1) {\r\n this.taskIndex++;\r\n this.currentInvoice = null;\r\n this.cachedInvoice = null;\r\n this.toastr.info('', 'Skipping Invoice...');\r\n this.callInProgress = true;\r\n this.getInvoiceForTask(this.taskList[this.taskIndex]).then(() => this.callInProgress = false);\r\n } else {\r\n this.messageBox.open({\r\n title: 'SUCCESS',\r\n message: 'You have completed or skipped all invoices. Click ok to return',\r\n buttons: MessageBoxButtons.OK}).then(() => {\r\n this.navigationService.disableNavWarning();\r\n this.navigateBackHandler();\r\n });\r\n }\r\n });\r\n }\r\n\r\n navigateBackHandler(): void {\r\n if(!this.currentState) {\r\n return;\r\n }\r\n\r\n if(this.currentState.name === InvoiceRouteNames.Site) {\r\n this.navigationServiceHandler.go('site', { companyId: this.currentInvoice.companyId, siteId: this.currentInvoice.siteId });\r\n } else if(this.currentState.name === InvoiceRouteNames.Company) {\r\n this.navigationServiceHandler.go('company', { companyId: this.currentInvoice.companyId });\r\n } else {\r\n this.navigationServiceHandler.go('actionview', this.actionViewPersistenceService.routeParams);\r\n }\r\n }\r\n\r\n onContractServiceTypeChange(): void {\r\n const term = this._siteAppealContractTerms.find(x => x.serviceId === +this.currentInvoice.contractServiceType &&\r\n (x.taxYear === this.currentInvoice.annualYear || !x.taxYear));\r\n this._updateInvoice(term.currentTermItem);\r\n }\r\n\r\n onContractTermChange(contractTermDetailId: number) {\r\n const contractTermDetail = this.companyAppealContractTerms\r\n .find(x => x.contractTermDetailId === +contractTermDetailId);\r\n this._updateInvoice(contractTermDetail);\r\n\r\n this._isContractTermOverridden = !contractTermDetail.siteDefault;\r\n }\r\n\r\n private _rejectHandler(error?: any) {\r\n return null;\r\n }\r\n\r\n private _hasChanges(): boolean {\r\n return this.editMode && !_.isEqual(this.currentInvoice, this.cachedInvoice);\r\n }\r\n\r\n private _updateInvoice(term: TermItem | ContractTerm) {\r\n this.currentInvoice.contingencyPctOriginal = term.contingencyPct;\r\n this.currentInvoice.contingencyPct = term.contingencyPct;\r\n this.currentInvoice.contingencyCapOriginal = term.contingencyCap;\r\n this.currentInvoice.contingencyCap = term.contingencyCap;\r\n this.currentInvoice.fixedFee = term.flatFee;\r\n this.currentInvoice.fixedFeeOriginal = term.flatFee;\r\n\r\n this._currentContractTerm = {\r\n contingencyPct: this.currentInvoice.contingencyPct,\r\n contingencyCap: this.currentInvoice.contingencyCap,\r\n flatFee: this.currentInvoice.fixedFee\r\n } as ContractTerm;\r\n\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Recalculated;\r\n this.currentInvoice = this.invoiceService.calculateInvoiceData(this.currentInvoice);\r\n this.currentInvoice.feeAmountStatus = OverrideStatus.Default;\r\n this.currentInvoice = {...this.currentInvoice};\r\n }\r\n\r\n private stashCurrentInvoice(invoice: Invoice) {\r\n invoice.invoiceRevenueShareCodes = _.map(invoice.invoiceRevenueShareCodes, x => {\r\n x.allocationPct = x.allocationPct || 0;\r\n return x;\r\n });\r\n\r\n this.cachedInvoice = _.cloneDeep(invoice);\r\n }\r\n\r\n private _calculateCurrentTermId() {\r\n const selectedContractTermDetail = this.companyAppealContractTerms\r\n .find(x => x.contractServiceTypeId === this.currentInvoice.contractServiceType &&\r\n (x.propertyTypeId && x.propertyTypeId === this.currentInvoice.propertyTypeID || !x.propertyTypeId) &&\r\n (x.taxYear === this.currentInvoice.annualYear || !x.taxYear) &&\r\n ((!x.contingencyPct && !this.currentInvoice.contingencyPctOriginal || x.contingencyPct === this.currentInvoice.contingencyPctOriginal) &&\r\n (!x.contingencyCap && !this.currentInvoice.contingencyCapOriginal || x.contingencyCap === this.currentInvoice.contingencyCapOriginal) &&\r\n (!x.flatFee && !this.currentInvoice.fixedFeeOriginal || x.flatFee === this.currentInvoice.fixedFeeOriginal)));\r\n if (selectedContractTermDetail) {\r\n this.currentContractTermDetailId = selectedContractTermDetail.contractTermDetailId;\r\n }\r\n\r\n this._isContractTermOverridden = !selectedContractTermDetail || !selectedContractTermDetail.siteDefault;\r\n }\r\n}\r\n","
\r\n

Create Invoice

\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n {{validationMessages.contractServiceType}}\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n {{validationMessages.propertyType}}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { Constants, ContractServiceType, PropertyType } from '../../constants.new';\r\nimport { InvoiceService } from '../../Processing/Invoice/invoice.service';\r\nimport { CreateAdHocInvoiceRequest } from '../../Processing/Invoice/invoice.model';\r\n\r\n@Component({\r\n selector: 'create-invoice-modal',\r\n templateUrl: './create-invoice-modal.component.html'\r\n})\r\nexport class InvoiceModalComponent implements OnInit {\r\n constructor(public bsModalRef: BsModalRef,\r\n private constants: Constants,\r\n private invoiceService: InvoiceService) {\r\n this.ContractServiceType = ContractServiceType;\r\n this.contractServiceTypes = Object.keys(constants.ContractServiceTypes).filter(z => z !== 'HOURLY' && z !== 'LITIGATION')\r\n .map(key => constants.ContractServiceTypes[key])\r\n .sort((a, b) => {\r\n if (a.name < b.name) {\r\n return -1;\r\n }\r\n if (a.name > b.name) {\r\n return 1;\r\n }\r\n\r\n // names must be equal\r\n return 0;\r\n });\r\n //need to remove ContractServiceType.Hourly from list here\r\n //this.contractServiceTypes = this.contractServiceTypes.filter(z => z !== ContractServiceType.Hourly);\r\n\r\n this.propertyTypes = Object.keys(constants.PropertyTypes).map(key => constants.PropertyTypes[key]).filter(x => x.id);\r\n }\r\n\r\n loading: boolean = false;\r\n siteId: number;\r\n companyId: number;\r\n years: number[];\r\n year: number;\r\n contractServiceTypeId: number;\r\n contractServiceTypes: any[];\r\n ContractServiceType: typeof ContractServiceType;\r\n propertyTypeId: number;\r\n propertyTypes: any[];\r\n onCreate: any;\r\n validationMessages: any;\r\n\r\n async ngOnInit() {\r\n this.contractServiceTypeId = 0; // ContractServiceType.Admin;\r\n\r\n this.validationMessages = {};\r\n this.year = (new Date()).getFullYear();\r\n this.years = [];\r\n for (let i = this.year + 5; i > this.year - 11; i--) {\r\n this.years.push(i);\r\n }\r\n\r\n this.loading = true;\r\n\r\n try {\r\n let defaultRequest: Promise;\r\n if (this.siteId) {\r\n defaultRequest = this.invoiceService.getSiteInvoiceDefaults(this.siteId);\r\n }\r\n else {\r\n defaultRequest = this.invoiceService.getCompanyInvoiceDefaults(this.companyId);\r\n }\r\n\r\n const request = await defaultRequest;\r\n\r\n if (request.propertyType) {\r\n this.propertyTypeId = request.propertyType;\r\n }\r\n else {\r\n this.propertyTypeId = null;\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async createInvoice(): Promise {\r\n this.validationMessages = {};\r\n if (!this.contractServiceTypeId) {\r\n this.validationMessages = {\r\n contractServiceType: 'Service is required'\r\n };\r\n return;\r\n }\r\n if (this.contractServiceTypeId == ContractServiceType.Appeal && !this.propertyTypeId) {\r\n this.validationMessages = {\r\n propertyType: 'Property type is required'\r\n };\r\n return;\r\n }\r\n this.loading = true;\r\n\r\n try {\r\n let propertyType: PropertyType = null;\r\n if (this.contractServiceTypeId == ContractServiceType.Appeal) {\r\n propertyType = this.propertyTypeId;\r\n }\r\n\r\n this.invoiceService.createAdHocInvoice({\r\n annualYear: this.year,\r\n companyId: this.companyId,\r\n siteId: this.siteId,\r\n contractServiceType: this.contractServiceTypeId,\r\n propertyType: propertyType\r\n }).then(invoiceId => {\r\n this.bsModalRef.hide();\r\n this.onCreate(invoiceId);\r\n }\r\n );\r\n\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n closeModal(): void {\r\n this.bsModalRef.hide();\r\n }\r\n\r\n identify(item) {\r\n return item.id;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { InvoiceModalComponent } from './create-invoice-modal.component';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class CreateInvoiceModalLaunchService {\r\n constructor(private modalService: BsModalService) { }\r\n\r\n customTemplateModalRef: BsModalRef;\r\n\r\n openCreateInvoiceModal(onCreate: any, companyId: number, siteId: number) {\r\n const initialState = {\r\n companyId: companyId,\r\n siteId: siteId,\r\n onCreate: onCreate\r\n };\r\n\r\n this.modalService.show(InvoiceModalComponent, { initialState, class: 'modal-create-invoice' });\r\n }\r\n}\r\n","
\r\n
\r\n \r\n

Invoices

\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n to\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
RIBS Due Date
\r\n
\r\n
Site
\r\n
\r\n
Contract Type
\r\n
\r\n
Tax Year
\r\n
\r\n
RIBS Request #
\r\n
\r\n
Invoice Amt
\r\n
\r\n
Status
\r\n
\r\n
RIBS Due Date
\r\n
\r\n
Site
\r\n
\r\n
Contract Type
\r\n
\r\n
Tax Year
\r\n
\r\n
RIBS Request #
\r\n
\r\n
Invoice Amt
\r\n
\r\n
Status
\r\n
{{invoice.dueDate | weissmanDateFormat}}{{invoice.siteName}}\r\n {{invoiceService.contractServiceName(invoice.contractServiceType)}}\r\n (ad hoc)\r\n {{invoice.annualYear}}{{invoice.invoiceNumber ? invoice.invoiceNumber : 'Draft'}}{{invoice.invoiceAmount | currency:'USD'}}
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { Component, Input, OnInit, OnDestroy } from '@angular/core';\r\nimport { Subject, Subscription } from 'rxjs';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport {Invoice} from './invoice.model';\r\nimport {InvoiceService} from './invoice.service';\r\nimport {MessageBoxService, MessageBoxButtons, MessageBoxResult} from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { WeissmanDatetimeComponent } from '../../UI-Lib/Weiss-Datepicker/weissman-datetime.component';\r\nimport {UpgradeNavigationServiceHandler} from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { EntityType, ContractServiceType } from '../../constants.new';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { CreateInvoiceModalLaunchService } from '../../Common/Invoice/create-invoice-modal-launch.service';\r\nimport { ContractsInvoicesService } from '../../Common/Contracts-Invoices/contract-invoices.service';\r\n\r\ndeclare const _: any;\r\ndeclare const moment: any;\r\n\r\n@Component({\r\n selector: 'invoice-panel',\r\n templateUrl: './invoice-panel.component.html'\r\n})\r\nexport class InvoicePanelComponent implements OnInit, OnDestroy {\r\n constructor(public invoiceService: InvoiceService,\r\n private contractsInvoicesService: ContractsInvoicesService,\r\n private messageBoxService: MessageBoxService,\r\n private navigationService : UpgradeNavigationServiceHandler,\r\n private taskService: TaskService,\r\n private createInvoiceModalLaunchService: CreateInvoiceModalLaunchService,\r\n private toastr: ToastrService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) { }\r\n\r\n @Input() company: {id: number};\r\n @Input() site: {siteID: number, companyID: number};\r\n @Input() allowEdit: boolean;\r\n\r\n editLock: boolean = false;\r\n isLoading: boolean = false;\r\n showBody: boolean = false;\r\n hasViewPermission: boolean = true;\r\n invoices: Invoice[];\r\n companyId: number;\r\n siteId: number;\r\n fromDate: Date;\r\n toDate: Date;\r\n parcelsReadyForInvoiceCount: number;\r\n sitesReadyForInvoiceCount: number;\r\n creatingAdminInvoices: boolean;\r\n annualYear: number;\r\n years: number[];\r\n ContractServiceType = ContractServiceType;\r\n contractTermsUpdateSubscription: Subscription;\r\n showSiteColumn: boolean = false;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n //Dima: for some reason [companyId]=\"vm.entity.id\" binding does not work on Company page, so this is a workaround.\r\n this.companyId = this.company ? this.company.id : this.site.companyID;\r\n this.siteId = this.site ? this.site.siteID : null;\r\n this.creatingAdminInvoices = false;\r\n this.contractTermsUpdateSubscription = null;\r\n\r\n if (this.siteId){\r\n this.fromDate = null;\r\n this.toDate = null;\r\n }\r\n else{\r\n this.fromDate = WeissmanDatetimeComponent.getMidnight(moment().subtract(90, 'day').toDate(), false, 'Central');\r\n\r\n //WK-4406 - changed this to null to prevent an issue where it looks like company page\r\n //isn't seeing site invoices due to due date range issues\r\n this.toDate = null;\r\n }\r\n\r\n this.years = [];\r\n this.annualYear = (new Date()).getFullYear();\r\n\r\n for (let i = this.annualYear + 5; i > this.annualYear - 11; i--) {\r\n this.years.push(i);\r\n }\r\n\r\n this._navigationService.globalEditMode$.pipe(takeUntil(this._destroy$)).subscribe(editMode => {\r\n this.editLock = editMode;\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n\r\n if (this.contractTermsUpdateSubscription !== null) {\r\n console.log('Destroying');\r\n this.contractTermsUpdateSubscription.unsubscribe();\r\n }\r\n }\r\n\r\n\r\n expandOrCollapse(): void {\r\n this.showBody = !this.showBody;\r\n this._productAnalyticsService.logEvent('company-toggle-panel', {\r\n panel: 'Invoices',\r\n isOpen: this.showBody\r\n });\r\n\r\n if(this.showBody) {\r\n this.loadPanel();\r\n }\r\n }\r\n\r\n loadPanel(): void {\r\n this.isLoading = true;\r\n\r\n const actions = [this.invoiceService.getInvoices(this.companyId, this.siteId, this.fromDate, this.toDate).then(result => {\r\n this.invoices = result;\r\n\r\n this.showSiteColumn = _.some(this.invoices, 'siteName');\r\n })];\r\n\r\n if (this.contractTermsUpdateSubscription !== null) {\r\n this.contractTermsUpdateSubscription.unsubscribe();\r\n }\r\n if (this.siteId) {\r\n this.contractTermsUpdateSubscription = this.contractsInvoicesService.contractTermsUpdateObservable.pipe(\r\n filter(event => event.entityId == this.siteId && event.entityType == EntityType.Site))\r\n .subscribe(() => this.updateSiteReadyCounts());\r\n actions.push(this.updateSiteReadyCounts());\r\n }\r\n else {\r\n this.contractTermsUpdateSubscription = this.contractsInvoicesService.contractTermsUpdateObservable.pipe(\r\n filter(event => event.entityId == this.companyId && event.entityType == EntityType.Company))\r\n .subscribe(() => this.updateCompanyReadyCounts());\r\n actions.push(this.updateCompanyReadyCounts());\r\n }\r\n\r\n Promise.all(actions).then(result => {\r\n this.isLoading = false;\r\n }).catch(() => { this.isLoading = false; });\r\n }\r\n\r\n cancelCreateAdminInvoices(): void {\r\n this.creatingAdminInvoices = false;\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n startCreateAdminInvoices(): void {\r\n this.creatingAdminInvoices = true;\r\n this._navigationService.enableNavWarning('You are in the process of creating invoices. Are you sure you want to leave this page?');\r\n }\r\n\r\n createAdminInvoices(): void {\r\n this.isLoading = true;\r\n this.invoiceService.bulkInvoicePreCheck(this.companyId, this.annualYear).then(preCheckResult => {\r\n if (preCheckResult.siteCount < 1) {\r\n this.toastr.warning('No sites can be invoiced for that tax year (most likely there are no matching contract terms available)');\r\n this.isLoading = false;\r\n }\r\n else {\r\n let title: string = undefined;\r\n let message = `Are you sure you want to create ${ preCheckResult.siteCount } invoice(s)?`;\r\n if (preCheckResult.existingInvoiceCount > 0) {\r\n title = 'Existing admin invoices detected';\r\n message = `WARNING: There appear to be ${ preCheckResult.existingInvoiceCount } existing admin invoice(s). ${ message}`;\r\n }\r\n this.messageBoxService.open({\r\n message: message,\r\n buttons: MessageBoxButtons.YesNo,\r\n title: title\r\n }).then(result => {\r\n if (result == MessageBoxResult.Yes) {\r\n this.creatingAdminInvoices = false;\r\n this._navigationService.disableNavWarning();\r\n this.invoiceService.createCompanyAdminInvoices(this.companyId, this.annualYear)\r\n .then(x => this.handleInvoiceCreate(x, false))\r\n .catch(() => this.loadPanel());\r\n }\r\n else {\r\n this.isLoading = false;\r\n }\r\n });\r\n }\r\n //this.messageBoxService.confirmYesNo(\"Are you sure you want to create \" + readyCount + \" invoices?\")\r\n });\r\n }\r\n\r\n createInvoices() : void {\r\n this.messageBoxService.open({\r\n title: 'WARNING',\r\n message: 'Selected Invoice Appeal Task(s) will be marked complete and their related appeal savings converted into saved contingency invoices ready to process as drafts. Proceed?',\r\n buttons: MessageBoxButtons.OKCancel\r\n }).then((result) => {\r\n switch(result) {\r\n case MessageBoxResult.OK:\r\n this.invoiceService.createInvoices(this.siteId)\r\n .then((x : any) => this.handleInvoiceCreate(x, true))\r\n .catch(() => this.loadPanel());\r\n break;\r\n case MessageBoxResult.No:\r\n break;\r\n }\r\n });\r\n }\r\n\r\n createAdHocInvoice(): void {\r\n this.createInvoiceModalLaunchService.openCreateInvoiceModal((invoiceId: number) => {\r\n // Redirect to new invoice on create. If we change our minds and want it to just reload the invoice\r\n // panel afterwards, we could remove the nav code and replace it with this:\r\n //this.toastr.success('Ad Hoc Invoice Created');\r\n //this.loadPanel();\r\n if (this.siteId) {\r\n this.navigationService.go('siteInvoice', {\r\n companyID: this.companyId,\r\n siteID: this.siteId,\r\n invoiceID: invoiceId\r\n });\r\n }\r\n else {\r\n this.navigationService.go('companyInvoice', {\r\n companyID: this.companyId,\r\n invoiceID: invoiceId\r\n });\r\n }\r\n }, this.companyId, this.siteId);\r\n }\r\n\r\n rowSelected(invoice: Invoice) : void {\r\n if (this.siteId){\r\n this.navigationService.go('siteInvoice', {companyID: this.companyId, siteID: this.siteId, invoiceID: invoice.invoiceId});\r\n }\r\n else{\r\n console.log('navigate to company');\r\n this.navigationService.go('companyInvoice', {companyID: this.companyId, invoiceID: invoice.invoiceId});\r\n }\r\n }\r\n\r\n launchTaskModal($event, invoice: Invoice) : void{\r\n event.stopPropagation();\r\n this.taskService.launchTaskModal(invoice.invoiceId, EntityType.Invoice, true);\r\n }\r\n\r\n private updateSiteReadyCounts(): Promise {\r\n this.parcelsReadyForInvoiceCount = null;\r\n return this.invoiceService.getReadyInvoiceAppealSavingTasksCount(this.siteId).then(result => {\r\n this.parcelsReadyForInvoiceCount = result;\r\n });\r\n }\r\n private updateCompanyReadyCounts(): Promise {\r\n this.sitesReadyForInvoiceCount = null;\r\n return this.invoiceService.getReadyAdminFeeInvoiceCount(this.companyId).then(result => {\r\n this.sitesReadyForInvoiceCount = result;\r\n });\r\n }\r\n\r\n private handleInvoiceCreate(result: any, isTask: boolean): void {\r\n const successfulResults = _.filter(result.operationResult, function (x : any) {\r\n return !x.errorMessage && !x.warningMessage;\r\n });\r\n const errorResults = _.filter(result.operationResult, function (x : any) {\r\n return x.errorMessage || x.warningMessage;\r\n });\r\n\r\n if (errorResults.length < 1) {\r\n if (isTask) {\r\n this.toastr.success(`Successfully processed ${ successfulResults.length } tasks`);\r\n }\r\n else {\r\n this.toastr.success(`Successfully created ${ successfulResults.length } invoices`);\r\n }\r\n }\r\n else {\r\n const warnings: string[] = _.uniqBy(_.map(_.filter(errorResults, function (error) {\r\n return !!error.warningMessage;\r\n }), 'warningMessage'));\r\n\r\n let errors: string[] = _.uniqBy(_.map(_.filter(errorResults, function (error) {\r\n return !error.warningMessage;\r\n }), 'errorMessage'));\r\n\r\n let showError = true;\r\n // If we got error messages but no user-friendly warning messages, don't bother with the\r\n // error-notification modal; the toast will be sufficient for that case\r\n if (_.some(warnings)) {\r\n // Do not show the original message for an error; any user-readable errors should come back\r\n // as warnings\r\n if (_.some(errors)) {\r\n errors = ['An unexpected error has occurred'];\r\n }\r\n this.taskService.showErrorNotificationModal(errors, warnings,\r\n 'The following error(s) were encountered attempting to create invoices');\r\n showError = false;\r\n }\r\n\r\n if (_.some(successfulResults)) {\r\n if (isTask) {\r\n this.toastr.warning(`Only some task(s) successfully processed; ${ successfulResults.length } succeeded and ${ errorResults.length } failed`);\r\n }\r\n else {\r\n this.toastr.warning(`Only some invoices(s) successfully created; ${ successfulResults.length } succeeded and ${ errorResults.length } failed`);\r\n }\r\n showError = false;\r\n }\r\n\r\n if(showError) {\r\n this.toastr.error('An unexpected error has occurred');\r\n }\r\n }\r\n\r\n this.loadPanel();\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { CommonModule, CurrencyPipe, DecimalPipe } from '@angular/common';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { TeamModule } from '../Team/team.module';\r\nimport { CompleteFileAppealModalComponent } from './Complete-File-Appeal-Modal/completeFileAppealModal.component';\r\nimport { DocumentProcessingModule } from './Documents/documentProcessing.module';\r\nimport { ChangeDueDateModalComponent } from './change-due-date.modal.component';\r\nimport { ProcessAppealWarrantedComponent } from './Process-Appeal-Warranted-Modal/processAppealWarranted.component';\r\nimport { ProcessNoAppealComponent } from './Process-No-Appeal-Modal/processNoAppeal.component';\r\nimport { RetrievalStatusModalService } from './RetrievalStatus/retrieval-status-modal.service';\r\nimport { ModalModule } from 'ngx-bootstrap/modal';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { Constants } from '../constants.new';\r\nimport { SharedPipesModule } from '../UI-Lib/Pipes/shared-pipes.module';\r\nimport { ProcessInvoiceComponent } from './Invoice/invoice.component';\r\nimport { InvoiceDetailsComponent } from './Invoice/invoice-details.component';\r\nimport { InvoiceService } from './Invoice/invoice.service';\r\nimport { InvoiceRecipientLookupComponent } from '../Common/Contracts-Invoices/invoice-recipient-lookup.component';\r\nimport { SetDocumentRetrievalStatusModalComponent } from './RetrievalStatus/set-document-retrieval-status.modal.component';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { RetrievalStatusService } from './RetrievalStatus/retrieval-status.service';\r\nimport { FeeAllocationComponent } from './Invoice/Fee-Allocation/fee-allocation.component';\r\nimport { AgGridExtensionsModule } from '../Compliance/AgGrid/agGridExtensions.module';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { RevenueShareGridActionCellRendererComponent } from './Invoice/Fee-Allocation/agGridActionCellRendererComponent';\r\nimport { AgGridCostCenterCellRendererComponent } from './Invoice/Fee-Allocation/agGridCostCenterCellRenderer';\r\nimport { AgGridEngagementNumberCellRendererComponent } from './Invoice/Fee-Allocation/agGridEngagementNumberCellRenderer';\r\nimport { AgGridExpenseAmountCellRendererComponent } from './Invoice/Fee-Allocation/agGridExpenseAmountCellRenderer';\r\nimport { AgGridPercentAllocationCellRendererComponent } from './Invoice/Fee-Allocation/agGridPercentAllocationCellRenderer';\r\nimport { TransmittalModule } from './Transmittal/transmittal.module';\r\nimport { InvoicePanelComponent } from './Invoice/invoice-panel.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n WeissmanSharedModule,\r\n TransmittalModule,\r\n SharedPipesModule,\r\n ModalModule,\r\n PopoverModule,\r\n TooltipModule,\r\n TypeaheadModule.forRoot(),\r\n CurrencyMaskModule,\r\n AgGridExtensionsModule,\r\n TeamModule,\r\n DocumentProcessingModule,\r\n AgGridModule.withComponents([\r\n RevenueShareGridActionCellRendererComponent,\r\n AgGridCostCenterCellRendererComponent,\r\n AgGridEngagementNumberCellRendererComponent,\r\n AgGridExpenseAmountCellRendererComponent,\r\n AgGridPercentAllocationCellRendererComponent\r\n ]),\r\n ],\r\n declarations: [\r\n ChangeDueDateModalComponent,\r\n ProcessInvoiceComponent,\r\n FeeAllocationComponent,\r\n InvoiceDetailsComponent,\r\n InvoiceRecipientLookupComponent,\r\n SetDocumentRetrievalStatusModalComponent,\r\n RevenueShareGridActionCellRendererComponent,\r\n AgGridCostCenterCellRendererComponent,\r\n AgGridEngagementNumberCellRendererComponent,\r\n AgGridExpenseAmountCellRendererComponent,\r\n AgGridPercentAllocationCellRendererComponent,\r\n InvoicePanelComponent,\r\n ProcessAppealWarrantedComponent,\r\n ProcessNoAppealComponent,\r\n CompleteFileAppealModalComponent\r\n ],\r\n providers: [\r\n RetrievalStatusModalService,\r\n RetrievalStatusService,\r\n Constants,\r\n InvoiceService,\r\n DecimalPipe,\r\n CurrencyPipe\r\n ],\r\n exports: [\r\n InvoicePanelComponent\r\n ]\r\n})\r\nexport class ProcessingModule {\r\n static setupModule(): void {\r\n TransmittalModule.setupModule();\r\n DocumentProcessingModule.setupModule();\r\n\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Provider('retrievalStatusModalService', RetrievalStatusModalService);\r\n // Angular 2+ components we're making available for AngularJS\r\n hybridAdapterUtility.downgradeNg2Component('changeDueDateModal', ChangeDueDateModalComponent);\r\n hybridAdapterUtility.downgradeNg2Component('invoice', ProcessInvoiceComponent);\r\n hybridAdapterUtility.downgradeNg2Component('invoicePanel', InvoicePanelComponent);\r\n\r\n }\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { BulkSaveExceptionResult } from '../Client-Services/Exceptions/client-service-exception.models';\r\nimport { BaseRepository } from '../Common/Data/base.repository';\r\n\r\n@Injectable()\r\nexport class ConsultingEngagementsRepository extends BaseRepository {\r\n constructor(\r\n httpClient: HttpClient\r\n ) {\r\n super(httpClient);\r\n }\r\n\r\n\r\n private _pathPrefix = 'api/ce';\r\n\r\n //get list of engagements for the current instance\r\n getList(): Promise {\r\n return lastValueFrom(this.httpGet(`${this._pathPrefix}`)) as Promise;\r\n }\r\n\r\n getAcceptedEngagements(entityTypeId: number, entityId: number): Promise {\r\n return lastValueFrom(this.httpClient.get(`${this._pathPrefix}/${entityTypeId}/${entityId}`)) as Promise;\r\n }\r\n\r\n getEngagements(entityTypeId: number, entityId: number): Promise {\r\n return lastValueFrom(this.httpClient.get(`${this._pathPrefix}/${entityTypeId}/${entityId}?includeUnaccepted=true`)) as Promise;\r\n }\r\n\r\n getEngagementInfo(consultingEngagementId: number): Promise {\r\n return lastValueFrom(this.httpGet(`${this._pathPrefix}/engagementInfo/${consultingEngagementId}`)) as Promise;\r\n }\r\n\r\n getConsultants(): Promise {\r\n return lastValueFrom(this.httpGet(`${this._pathPrefix}/consultants`)) as Promise;\r\n }\r\n\r\n //accept engagement offer\r\n async accept( request: Core.ConsultingEngagementDetails) {\r\n const result = await lastValueFrom(this.httpPost(`${this._pathPrefix}/accept`, request));\r\n\r\n if(result === false) {\r\n throw 'Consulting engagement could not be accepted';\r\n }\r\n return result;\r\n }\r\n\r\n //update engagement offer\r\n async update( request: Core.ConsultingEngagementDetails): Promise {\r\n return await lastValueFrom(this.httpPut(`${this._pathPrefix}/update`, request));\r\n }\r\n\r\n async delete(consultingEngagementId: number) {\r\n await lastValueFrom(this.httpDelete(`${this._pathPrefix}/${consultingEngagementId}`));\r\n }\r\n\r\n async invite(companyId: number, instanceId: number, permissions: number[]) {\r\n const req : Core.CreateConsultingEngagementRequest = {\r\n instanceId,\r\n companyId,\r\n permissions\r\n };\r\n await lastValueFrom(this.httpPost(`${this._pathPrefix}/invite`, req));\r\n }\r\n\r\n async updatePermissions(consultingEngagementId: number, updatedPermissions: number[]) {\r\n\r\n const request = {consultingEngagementId: consultingEngagementId, permissions: updatedPermissions};\r\n await lastValueFrom(this.httpPost(`${this._pathPrefix}/implicitPermissions`, request));\r\n }\r\n\r\n async getUserGroups(): Promise{\r\n return lastValueFrom(this.httpGet(`${this._pathPrefix}/userGroups`));\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class InstancePermissionService {\r\n constructor(private http: HttpClient) {\r\n }\r\n\r\n\tCONTACT_API_FRAGMENT: string = '/api/contact/';\r\n\tGROUP_API_FRAGMENT: string = '/api/usergroup/';\r\n\tINSTANCE_RIGHTS_API_FRAGMENT: string = '/api/InstanceRight/';\r\n\r\n async getAllByContactId(contactId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `${this.CONTACT_API_FRAGMENT}${contactId}/rights-available`\r\n ));\r\n }\r\n\r\n async getByContactId(contactId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `${this.CONTACT_API_FRAGMENT}${contactId}/rights`\r\n ));\r\n }\r\n\r\n async getAllByGroup(groupId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `${this.GROUP_API_FRAGMENT}${groupId}/rights-available`\r\n ));\r\n }\r\n\r\n async getByGroupId(groupId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `${this.GROUP_API_FRAGMENT}${groupId}/rights`\r\n ));\r\n }\r\n\r\n async getForConsultingEngagement(companyId: number) {\r\n return await lastValueFrom(this.http.get(\r\n `${this.INSTANCE_RIGHTS_API_FRAGMENT}company/${companyId}/ForConsultingEngagement`\r\n ));\r\n }\r\n}\r\n","

{{engagement.name}} Permissions

\r\n
\r\n\r\n\r\n
\r\n \r\n \r\n \r\n {{permission.rights}}\r\n\r\n \r\n {{permission.screenType}}\r\n\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n \r\n
\r\n\r\n
\r\n
0\">\r\n \r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n No additional permissions to add close\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { AccountService } from '../../User/account.service';\r\nimport { RestrictService } from '../../Common/Permissions/restrict.service';\r\n\r\n@Component({\r\n selector: 'instance-rights-list',\r\n templateUrl: './instanceRightsList.component.html',\r\n styleUrls: ['./instanceRightsList.component.scss']\r\n\r\n})\r\nexport class InstanceRightsListComponent {\r\n constructor(private accountService: AccountService, private _restrictService: RestrictService) {\r\n }\r\n\r\n @Input() availableInstanceRights: Core.InstanceRightModel[];\r\n @Input() engagement: Core.ConsultingEngagementResponse; // current permissions hangs off this\r\n @Output() editModeEvent = new EventEmitter();\r\n\r\n editMode: boolean = false;\r\n permissionToAdd: {screenTypeID: number, permission: number} = {screenTypeID: null, permission: null};\r\n screenTypePermissions = [];\r\n\r\n onUpdateEditMode() {\r\n this.editModeEvent.emit(this.editMode);\r\n }\r\n\r\n //get remaining screen type names that can be assigned\r\n getUniqueAvailableScreenTypes():Core.InstanceRightModel[] {\r\n const unique= _.uniqBy(this.availableInstanceRights.filter(p => this.isPermissionUsable(p)), 'screenTypeID');\r\n return _.sortBy(unique, (p) => {return p.screenType;});\r\n }\r\n\r\n //add permission button handler\r\n selectPermissionToAdd(): void {\r\n this.permissionToAdd = {screenTypeID: null, permission: null};\r\n this.editMode = true;\r\n this.onUpdateEditMode();\r\n }\r\n\r\n //cancel add operation\r\n closeAddPermission(): void {\r\n this.permissionToAdd = {screenTypeID: null, permission: null};\r\n this.editMode = false;\r\n this.onUpdateEditMode();\r\n }\r\n\r\n //new permisison added\r\n addPermission(): void{\r\n this.engagement.permissions.push(this.lookupPermission(this.permissionToAdd.screenTypeID, this.permissionToAdd.permission));\r\n this.closeAddPermission();\r\n }\r\n\r\n //screen type selected in the add permission section\r\n screenTypeSelected(): void {\r\n this.screenTypePermissions = this.availablePermissionRights(this.permissionToAdd.screenTypeID);\r\n this.permissionToAdd.permission = _.minBy(this.screenTypePermissions, 'rightsID').rightsID;\r\n }\r\n\r\n //right is seleled in the add permission section\r\n rightSelected(permission): void {\r\n const p = this.availableInstanceRights.find(r => r.instanceRightID == permission.instanceRightID);\r\n permission.rights = p.rights;\r\n permission.rightsID = p.rightsID;\r\n }\r\n\r\n //get current users rights for a screen type\r\n availablePermissionRights(screenTypeId) {\r\n if (this.availableInstanceRights === undefined || this.availableInstanceRights.length === 0) {\r\n return;\r\n }\r\n\r\n return _.filter(this.availableInstanceRights, (ap) => {\r\n return ap.screenTypeID == screenTypeId;\r\n });\r\n }\r\n\r\n //remove permission from engagement\r\n deletePermission(permission):void {\r\n _.remove(this.engagement.permissions, permission);\r\n }\r\n\r\n //checks to see if user has the permission right\r\n userHasInstanceRight(permission):boolean {\r\n return this._restrictService.hasInstanceRight(permission.name, this.engagement.companyInstanceId);\r\n }\r\n\r\n //look up permission\r\n private lookupPermission(screenTypeID:number, rightsId:number) {\r\n const perm = this.availableInstanceRights.filter(ir => ir.rightsID === rightsId && ir.screenTypeID === screenTypeID)[0] || null;\r\n if(perm !== null) return perm;\r\n throw 'Permission cannot be assigned';\r\n }\r\n\r\n //check to see if a screen type is not already assigned and if user has rights to it in this instance\r\n private isPermissionUsable(permission):boolean {\r\n\r\n const rightHasAlreadyAssigned = !_.some(this.engagement.permissions, { screenTypeID: permission.screenTypeID});\r\n let userInstanceRights = [];\r\n\r\n const engagementInstanceRights = this.accountService.userData.instanceRights.find(i => i.instanceId == this.engagement.companyInstanceId);\r\n if(engagementInstanceRights) userInstanceRights = engagementInstanceRights.rights.map(r => r.name);\r\n\r\n const rightsWithSameScreenType = this.availableInstanceRights.filter(ap => ap.screenTypeID == permission.screenTypeID);\r\n const userHasRightWithScreenTypeInThisInstance = userInstanceRights.some(r => rightsWithSameScreenType.some(s => s.name === r));\r\n return rightHasAlreadyAssigned && userHasRightWithScreenTypeInThisInstance;\r\n }\r\n\r\n}\r\n","
\r\n \r\n
\r\n \r\n
\r\n
0 || availableConsultants.length > 0) && !isLoading\">\r\n \r\n
\r\n \r\n
\r\n

There are currently no consultants available

\r\n
\r\n \r\n 0 || availableConsultants.length > 0)\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
CompanyStatus
Actions
{{engagement.name}}{{getEngagementStatus(engagement)}}\r\n
\r\n \r\n \r\n \r\n
\r\n
{{consultant.consultantName}}\r\n
\r\n \r\n
\r\n
\r\n\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { InstancePermissionService } from '../../Permission/Instance/Instance.Permission.Service';\r\nimport { ConsultingEngagementsRepository } from '../consultingEngagements.repository';\r\n\r\nexport class CompanyContractsModalParams {\r\n company: CompanyModel;\r\n}\r\n\r\n//visual states for this modal\r\nexport enum VisualState {\r\n 'List' = 'List',\r\n 'Invite' = 'Invite',\r\n 'Edit' = 'Edit'\r\n}\r\n\r\ninterface CompanyModel extends Weissman.Model.Domain.Company {\r\n parentId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'company-contracts-modal',\r\n templateUrl: './companyContractsModal.component.html',\r\n styleUrls: ['./companyContractsModal.component.scss']\r\n})\r\nexport class CompanyContractsModalComponent implements IWeissmanModalComponent, OnInit{\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _consultingEngagementsRepository: ConsultingEngagementsRepository,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly instancePermissionService: InstancePermissionService,\r\n private readonly _messageModalService: MessageModalService\r\n ) {\r\n\r\n }\r\n\r\n params: CompanyContractsModalParams;\r\n result: void;\r\n isEditMode: boolean = false;\r\n\r\n isLoading = false;\r\n consultingEngagements: Core.ConsultingEngagementResponse[]=[];\r\n availableConsultants: Core.Consultant[] = [];\r\n visualState: VisualState = VisualState.List;\r\n\r\n selectedEngagement: Core.ConsultingEngagementResponse;\r\n selectedConsultant: Core.Consultant;\r\n availableInstanceRights: Core.InstanceRightModel[];\r\n\r\n permsBeingEdited: boolean = false;\r\n\r\n async ngOnInit() {\r\n await this.reload();\r\n }\r\n\r\n async reload() {\r\n this.isLoading = true;\r\n try {\r\n this.consultingEngagements = await this._consultingEngagementsRepository.getEngagements(Core.EntityTypes.Company, this.params.company.companyID);\r\n\r\n //get available consultants and filter out consultant from companies instance - can't invite self\r\n const consultants = (await this._consultingEngagementsRepository.getConsultants()).filter(c => c.instanceId !== this.params.company.instanceID);\r\n this.availableConsultants = consultants.filter(ac => !this.consultingEngagements.some(ce => ce.instanceId === ac.instanceId));\r\n } finally {\r\n this.isLoading = false;\r\n }\r\n }\r\n\r\n toggleEdit() {\r\n this.isEditMode = !this.isEditMode;\r\n }\r\n\r\n done() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n getEngagementStatus(engagement: Core.ConsultingEngagementResponse ) {\r\n if (engagement.accepted) {\r\n return 'Accepted';\r\n }\r\n\r\n return 'Pending';\r\n }\r\n\r\n editModeEventHander($event: any) {\r\n this.permsBeingEdited = $event;\r\n }\r\n\r\n //edit existing engagement and adjust instance rights\r\n async editEngagement(engagement: Core.ConsultingEngagementResponse) {\r\n this.selectedEngagement = engagement;\r\n\r\n await this.setAvailableInstanceRights();\r\n\r\n this.visualState = VisualState.Edit;\r\n }\r\n\r\n //consultant selected to invite\r\n async invite(consultant: Core.Consultant) {\r\n this.selectedConsultant = consultant;\r\n\r\n await this.setAvailableInstanceRights();\r\n\r\n //create temporary engagement for purposes of instance rights modal\r\n this.selectedEngagement = {\r\n accepted: false,\r\n accountHandler: null,\r\n consultingEngagementId: -1,\r\n instanceId: consultant.instanceId,\r\n companyInstanceId: this.params.company.instanceID,\r\n name: this.selectedConsultant.consultantName,\r\n permissions: [],\r\n };\r\n this.visualState = VisualState.Invite;\r\n }\r\n\r\n //send invite for consultant\r\n async confirmInvite() {\r\n const updatedPermissions = this.getPermissionPayload();\r\n await this._consultingEngagementsRepository.invite(this.params.company.companyID, this.selectedConsultant.instanceId, updatedPermissions);\r\n await this.reload();\r\n this.selectedEngagement = null;\r\n this.selectedConsultant = null;\r\n this.visualState = VisualState.List;\r\n }\r\n\r\n //update accepted consulting engagement's permission\r\n async updatePermissions() {\r\n const updatedPermissions = this.getPermissionPayload();\r\n await this._consultingEngagementsRepository.updatePermissions(this.selectedEngagement.consultingEngagementId, updatedPermissions);\r\n await this.reload();\r\n this.selectedEngagement = null;\r\n this.visualState = VisualState.List;\r\n }\r\n\r\n //cancel accepted engagement\r\n async cancelEngagement(consultingEngagementId: number) {\r\n const engagementInfo = await this._consultingEngagementsRepository.getEngagementInfo(consultingEngagementId);\r\n\r\n if(engagementInfo.consultingEngagementCSRs.length > 0){\r\n await this._messageModalService.alert(`This consulting engagement cannot be cancelled. There are ${engagementInfo.consultingEngagementCSRs.length} CSRs assigned.`);\r\n }\r\n else {\r\n try {\r\n await this._messageBoxService.confirm('Are you sure you want to cancel this engagement?');\r\n } catch(e) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._consultingEngagementsRepository.delete(consultingEngagementId);\r\n await this.reload();\r\n }\r\n }\r\n\r\n //cancel invite/edit\r\n async cancel() {\r\n this.visualState = VisualState.List;\r\n this.reload();\r\n this.selectedEngagement = null;\r\n this.selectedConsultant = null;\r\n }\r\n\r\n //get permission list for sending back to the server\r\n private getPermissionPayload() {\r\n return this.selectedEngagement.permissions.map(p => p.instanceRightID);\r\n }\r\n\r\n private async setAvailableInstanceRights() {\r\n this.availableInstanceRights = await this.instancePermissionService.getForConsultingEngagement(this.params.company.companyID);\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class DXPService {\r\n constructor(private httpClient: HttpClient) { }\r\n\r\n async getDXPMode() {\r\n return await lastValueFrom(this.httpClient.get('/api/DXPState/mode')) as Promise;\r\n }\r\n\r\n async testDXPSync() {\r\n return await lastValueFrom(this.httpClient.post('/api/DXPState/testsync', null)) as Promise;\r\n }\r\n\r\n async IsSyncDxpLocked(companyId) {\r\n return await lastValueFrom(this.httpClient.get(`/api/company/${companyId}/SyncDxpLocked`)) as Promise;\r\n }\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom, Observable } from 'rxjs';\r\nimport { BaseRepository } from '../Common/Data/base.repository';\r\n\r\nconst baseUrl = '/api/descriptor/';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class DescriptorService extends BaseRepository {\r\n constructor(httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n getByCategoryId(categoryId: number, useCache?: boolean): Promise {\r\n const url = baseUrl + categoryId;\r\n const config = {\r\n cache: useCache || false\r\n };\r\n\r\n return lastValueFrom(this.httpGet(url, config)) as Promise;\r\n }\r\n\r\n update(descriptor: Core.DescriptorDTO) {\r\n return lastValueFrom(this.httpPut(baseUrl, descriptor));\r\n }\r\n\r\n create(descriptor: Core.DescriptorDTO): Promise {\r\n return lastValueFrom(this.httpPost(baseUrl, descriptor));\r\n }\r\n\r\n deleteById(id: number) {\r\n const url = baseUrl + id;\r\n\r\n return lastValueFrom(this.httpDelete(url, {}));\r\n }\r\n\r\n getAvailable(companyId: number, entityTypeId: number): Promise {\r\n return lastValueFrom(this.httpGet(`${baseUrl}available/${companyId}`, { params: { usageEntityType: entityTypeId } })) as Promise;\r\n }\r\n\r\n searchAvailableOverrides(companyId: number, searchModel: Core.EntityDescriptorSearchModel): Observable {\r\n return this.httpPost(`/api/companydescriptoroverride/company/${companyId}/available`, searchModel);\r\n }\r\n\r\n getUsedBySite(companyId: number): Promise {\r\n return lastValueFrom(this.httpGet(`/api/companydescriptoroverride/company/${companyId}/usedBySite`));\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { DescriptorService } from './descriptor.service';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'descriptor-picker',\r\n template: `\r\n \r\n `\r\n})\r\nexport class DescriptorPickerComponent implements OnInit {\r\n constructor(private descriptorService: DescriptorService) {}\r\n\r\n @Input() companyId: number;\r\n @Input() entityTypeId: number;\r\n @Input() descriptorId: number;\r\n @Input() disabled: boolean;\r\n @Output() selected: EventEmitter = new EventEmitter();\r\n\r\n descriptors: Core.AvailableDescriptorModel[];\r\n selectedDescriptorName: string;\r\n\r\n async ngOnInit() {\r\n this.descriptors = (await this.descriptorService.getAvailable(this.companyId, this.entityTypeId)).descriptors;\r\n\r\n if(this.descriptorId) {\r\n const selectedDescriptor = _.find(this.descriptors, {descriptorId: this.descriptorId});\r\n if(selectedDescriptor) {\r\n this.selectedDescriptorName = selectedDescriptor.descriptorName;\r\n } else {\r\n console.warn('Descriptor not found!');\r\n }\r\n }\r\n }\r\n\r\n onSelect(e: TypeaheadMatch) {\r\n const descriptor = e.item as Core.AvailableDescriptorModel;\r\n this.selected.emit(descriptor);\r\n }\r\n\r\n}\r\n","import { efAction } from '../../../../constants.new';\r\n\r\nexport class CompanyAccounting {\r\n companyId: number;\r\n defaultFiscalYearStart: string;\r\n defaultAccountingDurationTypeId: number;\r\n companyRowVersion: string;\r\n // companyFiscalYears can be empty (UI must account for that)\r\n companyFiscalYears: CompanyFiscalYear[];\r\n}\r\n\r\nexport class CompanyFiscalYear {\r\n companyFiscalYearId: number;\r\n companyId: number;\r\n name: string;\r\n startDate: Date;\r\n endDate: Date;\r\n accountingDurationTypeId: number;\r\n accountingPeriods: AccountingPeriod[];\r\n}\r\n\r\nexport class AccountingPeriod {\r\n accountingPeriodId: number;\r\n companyFiscalYearId: number;\r\n name: string;\r\n startDate: Date;\r\n endDate: Date;\r\n isFrozen: boolean;\r\n efAction: efAction;\r\n durationText: string;\r\n}\r\n\r\nexport class AccountingPeriodsRequest {\r\n companyRowVersion: string;\r\n companyFiscalYearId: number;\r\n fiscalYearName: string;\r\n efAction: efAction;\r\n accountingPeriods: AccountingPeriod[];\r\n}\r\n\r\nexport class NewFiscalYearRequest {\r\n companyRowVersion: string;\r\n name: string;\r\n startDate: Date;\r\n endDate: Date;\r\n accountingDurationTypeId: number;\r\n\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AccountingPeriodsRequest, CompanyAccounting, NewFiscalYearRequest } from './accounting.periods.model';\r\n\r\n@Injectable()\r\nexport class AccountingPeriodsService {\r\n\r\n constructor(private httpService: HttpClient) {}\r\n\r\n getAccountingPeriods(companyId: number): Promise {\r\n return lastValueFrom(this.httpService.get(`/api/company/${companyId}/accountingperiods`)) as Promise;\r\n }\r\n\r\n updateAccountingPeriods(companyId: number, request: AccountingPeriodsRequest): Promise {\r\n return lastValueFrom(this.httpService.put(`/api/company/${companyId}/accountingperiods`, request));\r\n }\r\n\r\n addNewFiscalYear(companyId: number, request: NewFiscalYearRequest): Promise {\r\n return lastValueFrom(this.httpService.post(`/api/company/${companyId}/companyfiscalyear`, request));\r\n }\r\n\r\n deleteFiscalYear(companyId: number, companyFiscalYearId: number, companyRowVersion: string): Promise {\r\n return lastValueFrom(this.httpService.post(`/api/company/${companyId}/fiscalYear/remove`, {\r\n companyRowVersion: companyRowVersion,\r\n companyFiscalYearId: companyFiscalYearId,\r\n accountingPeriods: null\r\n }));\r\n }\r\n}\r\n","\r\n
\r\n \r\n
\r\n
\r\n
Are you sure you want to delete this fiscal year?
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n - \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
PeriodBegin DateEnd DateDurationFrozen
\r\n {{period.name}}\r\n \r\n {{period.durationText}}{{period.isFrozen ? 'Yes' : 'No'}}\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n

Add fiscal year to display periods

\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n Add to...\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Name:
Begin Date:
End Date:
Duration Type:\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AccountingPeriod, AccountingPeriodsRequest, CompanyAccounting, CompanyFiscalYear, NewFiscalYearRequest } from './accounting.periods.model';\r\nimport { AccountingPeriodsService } from './accounting.periods.service';\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment';\r\nimport { Constants } from '../../../../constants.new';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\n@Component({\r\n selector: 'accounting-periods-modal',\r\n templateUrl: './accounting.periods.modal.component.html',\r\n styleUrls: ['./accounting.periods.modal.component.scss']\r\n})\r\nexport class AccountingPeriodsModalComponent implements OnInit {\r\n constructor(private bsModalRef: BsModalRef,\r\n private accountingPeriodsService: AccountingPeriodsService,\r\n private constants: Constants,\r\n private toastr: ToastrService) {}\r\n\r\n //initialState\r\n companyId: number;\r\n canEdit: boolean;\r\n\r\n loading: boolean = false;\r\n editMode: boolean = false;\r\n canDelete: boolean = false;\r\n deleting: boolean = false;\r\n companyAccounting: CompanyAccounting;\r\n selectedFiscalYear: CompanyFiscalYear;\r\n selectedFiscalYearDurationText: string;\r\n originalSelectedFiscalYear: CompanyFiscalYear;\r\n\r\n showAddToBeginningCheckbox: boolean = false;\r\n durationTypes: {label: string, id: number}[];\r\n\r\n placementChosen: boolean = false;\r\n beginningChosen: boolean = false;\r\n forcePlacement: boolean = false;\r\n newFiscalYearRequest: NewFiscalYearRequest;\r\n\r\n\r\n async ngOnInit() {\r\n this.loading = true;\r\n\r\n try {\r\n this.durationTypes = _.map(this.constants.AccountingDurationTypes, (label: string, id: string) => {\r\n return {label: label, id: Number(id)};\r\n });\r\n await this._initPeriodData(0);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async _initPeriodData(fiscalYearIdx: number): Promise {\r\n this.companyAccounting = await this.accountingPeriodsService.getAccountingPeriods(this.companyId);\r\n this.companyAccounting.companyFiscalYears = _.chain(this.companyAccounting.companyFiscalYears)\r\n .map(year => {\r\n year.accountingPeriods = _.map(year.accountingPeriods, period => {\r\n period.durationText = this._getDurationText(year, period);\r\n return period;\r\n });\r\n\r\n return year;\r\n })\r\n .orderBy('startDate', 'desc')\r\n .value();\r\n\r\n if(this.companyAccounting.companyFiscalYears.length) {\r\n this.selectedFiscalYear = fiscalYearIdx == 999 ? _.last(this.companyAccounting.companyFiscalYears) : this.companyAccounting.companyFiscalYears[fiscalYearIdx];\r\n } else {\r\n this.selectedFiscalYear = undefined;\r\n }\r\n }\r\n\r\n goToEditMode(): void {\r\n this.originalSelectedFiscalYear = _.cloneDeep(this.selectedFiscalYear);\r\n this.editMode = true;\r\n const firstYear = _.first(this.companyAccounting.companyFiscalYears);\r\n this.canDelete = firstYear === this.selectedFiscalYear && !this.selectedFiscalYear.accountingPeriods.some(ap => ap.isFrozen);\r\n }\r\n\r\n beginDelete(): void {\r\n this.deleting = true;\r\n }\r\n\r\n cancelDelete(): void {\r\n this.deleting = false;\r\n }\r\n\r\n async delete(): Promise {\r\n this.loading = true;\r\n this.cancel();\r\n this.deleting = false;\r\n try {\r\n await this.accountingPeriodsService.deleteFiscalYear(\r\n this.selectedFiscalYear.companyId,\r\n this.selectedFiscalYear.accountingPeriods[0].companyFiscalYearId,\r\n this.companyAccounting.companyRowVersion\r\n );\r\n }\r\n finally {\r\n await this._initPeriodData(0);\r\n this.loading = false;\r\n }\r\n }\r\n\r\n cancel(): void {\r\n _.assign(this.selectedFiscalYear, this.originalSelectedFiscalYear);\r\n this.editMode = false;\r\n }\r\n\r\n async save(): Promise {\r\n if(this._arePeriodsInvalid()) {\r\n return;\r\n }\r\n\r\n const request = new AccountingPeriodsRequest();\r\n\r\n request.companyRowVersion = this.companyAccounting.companyRowVersion;\r\n request.companyFiscalYearId = this.selectedFiscalYear.companyFiscalYearId;\r\n if(this.selectedFiscalYear.name !== this.originalSelectedFiscalYear.name) {\r\n request.fiscalYearName = this.selectedFiscalYear.name;\r\n request.efAction = 'update';\r\n }\r\n request.accountingPeriods = _.map(this.selectedFiscalYear.accountingPeriods, period => {\r\n const originalPeriod = _.find(this.originalSelectedFiscalYear.accountingPeriods, {accountingPeriodId: period.accountingPeriodId});\r\n if(!period.efAction && !_.isEqual(period, originalPeriod)) {\r\n period.efAction = 'update';\r\n }\r\n\r\n return period;\r\n });\r\n\r\n this.loading = true;\r\n\r\n try {\r\n await this.accountingPeriodsService.updateAccountingPeriods(this.companyId, request);\r\n const fiscalYearIdx = _.findIndex(this.companyAccounting.companyFiscalYears, {companyFiscalYearId: this.selectedFiscalYear.companyFiscalYearId});\r\n await this._initPeriodData(fiscalYearIdx);\r\n this.editMode = false;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n dateChange(type: 'start' | 'end', i: number): void {\r\n // let periods = this.undeletedPeriods();\r\n\r\n // if(type == 'start' && i > 0) {\r\n // periods[i-1].endDate = moment(periods[i].startDate).subtract(1, 'days').toDate();\r\n // } else if(i < periods.length - 1) {\r\n // periods[i+1].startDate = moment(periods[i].endDate).add(1, 'days').toDate();\r\n // }\r\n }\r\n\r\n addSinglePeriod(): void {\r\n // if(_.last(this.undeletedPeriods()).endDate >= this.selectedFiscalYear.endDate) {\r\n // this.toastr.error(\"Latest period's End Date must be before Fiscal year's End Date to add new period.\");\r\n // return;\r\n // }\r\n\r\n const periodToAdd = new AccountingPeriod();\r\n const lastExistingPeriod = _.last(this.undeletedPeriods());\r\n periodToAdd.startDate = moment(lastExistingPeriod.endDate).add(1, 'days').toDate();\r\n // periodToAdd.endDate = this.selectedFiscalYear.endDate;\r\n periodToAdd.efAction = 'add';\r\n periodToAdd.companyFiscalYearId = this.selectedFiscalYear.companyFiscalYearId;\r\n this.selectedFiscalYear.accountingPeriods.push(periodToAdd);\r\n }\r\n\r\n undeletedPeriods(): AccountingPeriod[] {\r\n return _.reject(this.selectedFiscalYear.accountingPeriods, {efAction: 'delete'});\r\n }\r\n\r\n remove(period: AccountingPeriod): void {\r\n if(period.efAction == 'add') {\r\n this.selectedFiscalYear.accountingPeriods.pop();\r\n } else {\r\n period.efAction = 'delete';\r\n }\r\n\r\n //removing bottom period has to change date of the new last period to end of fiscal year\r\n // _.last(this.undeletedPeriods()).endDate = this.selectedFiscalYear.endDate;\r\n }\r\n\r\n choosePlacement(placement: 'beginning' | 'end' | 'new', e?): void {\r\n if(e) {\r\n e.stopPropagation();\r\n }\r\n\r\n this.newFiscalYearRequest = new NewFiscalYearRequest();\r\n this.newFiscalYearRequest.accountingDurationTypeId = this.durationTypes[0].id;\r\n this.newFiscalYearRequest.companyRowVersion = this.companyAccounting.companyRowVersion;\r\n\r\n this.placementChosen = true;\r\n\r\n switch(placement) {\r\n case 'beginning':\r\n this.newFiscalYearRequest.endDate = moment(_.last(this.companyAccounting.companyFiscalYears).startDate).subtract(1, 'days').toDate();\r\n this.beginningChosen = true;\r\n break;\r\n case 'end':\r\n this.newFiscalYearRequest.startDate = moment(_.first(this.companyAccounting.companyFiscalYears).endDate).add(1, 'days').toDate();\r\n this.beginningChosen = false;\r\n break;\r\n case 'new':\r\n this.beginningChosen = true;\r\n break;\r\n }\r\n }\r\n\r\n addFiscalYearClicked(): void {\r\n this.beginningChosen = false;\r\n this.forcePlacement = false;\r\n this.placementChosen = false;\r\n\r\n if(!this.companyAccounting.companyFiscalYears.length) {\r\n this.forcePlacement = true;\r\n this.choosePlacement('new');\r\n return;\r\n }\r\n\r\n const allowAddToBeginning = _.every(this.companyAccounting.companyFiscalYears, year => _.every(year.accountingPeriods, ['isFrozen', false]));\r\n\r\n if(!allowAddToBeginning) {\r\n this.forcePlacement = true;\r\n this.choosePlacement('end');\r\n }\r\n }\r\n\r\n async addFiscalYear(): Promise {\r\n if(this.newFiscalYearRequest.startDate >= this.newFiscalYearRequest.endDate) {\r\n this.toastr.error('Begin Date must be before End Date');\r\n return;\r\n }\r\n\r\n const duplicateName = _.some(this.companyAccounting.companyFiscalYears, fiscalYear => _.lowerCase(fiscalYear.name) == _.lowerCase(this.newFiscalYearRequest.name));\r\n\r\n if(duplicateName) {\r\n this.toastr.error('Name already exists');\r\n return;\r\n }\r\n\r\n this.loading = true;\r\n\r\n try {\r\n await this.accountingPeriodsService.addNewFiscalYear(this.companyId, this.newFiscalYearRequest);\r\n } catch(e) {\r\n if(e.error && e.error.message) {\r\n this.toastr.error(e.error.message);\r\n }\r\n } finally {\r\n await this._initPeriodData(this.beginningChosen ? 999 : 0);\r\n this.loading = false;\r\n }\r\n }\r\n\r\n close(): void {\r\n this.bsModalRef.hide();\r\n // this.onClose();\r\n }\r\n\r\n private _getDurationText(year: CompanyFiscalYear, period: AccountingPeriod): string {\r\n switch (year.accountingDurationTypeId) {\r\n case Core.AccountingDurationTypeEnum.Monthly:\r\n return '1 Mo';\r\n case Core.AccountingDurationTypeEnum.Quarterly:\r\n return '1 Qtr';\r\n default:\r\n return `${moment(period.endDate).diff(period.startDate, 'days') + 1} days`;\r\n }\r\n }\r\n\r\n private _arePeriodsInvalid(): boolean {\r\n const periods = this.undeletedPeriods();\r\n\r\n if(!periods.length) {\r\n return false;\r\n }\r\n\r\n if(!moment(periods[0].startDate).isSame(this.selectedFiscalYear.startDate)) {\r\n this.toastr.error('The first period\\'s Begin Date must match the Fiscal Year\\'s Begin Date');\r\n return true;\r\n }\r\n\r\n if(!moment(_.last(periods).endDate).isSame(this.selectedFiscalYear.endDate)) {\r\n this.toastr.error('The last period\\'s End Date must match the Fiscal Year\\'s End Date');\r\n return true;\r\n }\r\n\r\n if(!_.every(periods, 'name')) {\r\n this.toastr.error('\\'Name\\' is required on all periods');\r\n return true;\r\n }\r\n\r\n const isContinuous = _.every(periods, (period, i) => {\r\n if(i < periods.length - 1) {\r\n return moment(period.endDate).add(1, 'days').isSame(periods[i+1].startDate);\r\n } else {\r\n return true;\r\n }\r\n });\r\n\r\n if(!isContinuous) {\r\n this.toastr.error('There cannot be any gaps or overlaps between periods');\r\n return true;\r\n }\r\n\r\n return false;\r\n }\r\n\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { AccountingPeriodsModalComponent } from './accounting.periods.modal.component';\r\n\r\n@Component({\r\n selector: 'accounting-periods-link',\r\n template: `\r\n Accounting Periods\r\n `\r\n})\r\nexport class AccountingPeriodsLinkComponent {\r\n constructor(private modalService: BsModalService) {}\r\n\r\n @Input() companyId: number;\r\n @Input() editMode: boolean;\r\n\r\n launchModal() {\r\n const initialState = {\r\n companyId: this.companyId,\r\n canEdit: this.editMode\r\n };\r\n\r\n this.modalService.show(AccountingPeriodsModalComponent, { initialState, ignoreBackdropClick: true, class: 'modal-lg' });\r\n }\r\n\r\n}\r\n","import { Component, Input, Output, EventEmitter, OnChanges, SimpleChanges } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { TypeaheadOrder } from 'ngx-bootstrap/typeahead';\r\n\r\n@Component({\r\n selector: 'accruals-descriptor-selector',\r\n template: `\r\n \r\n `\r\n})\r\nexport class AccrualsDescriptorSelectorComponent implements OnChanges {\r\n @Input() inUseDescriptors: Core.CompanyFeatureDescriptorModel[];\r\n @Input() selectedDescriptorId: number;\r\n @Input() placeholder: string = '';\r\n @Input() disabled: boolean;\r\n @Output() onDescriptorSelected: EventEmitter = new EventEmitter();\r\n @Output() selectedDescriptorIdChange: EventEmitter = new EventEmitter();\r\n\r\n descriptorName: string = '';\r\n sortConfig: TypeaheadOrder = {\r\n direction: 'asc',\r\n field: 'categoryName'\r\n };\r\n\r\n ngOnChanges(changes: SimpleChanges) {\r\n if(changes.selectedDescriptorId) {\r\n if(changes.selectedDescriptorId.currentValue) {\r\n const selectedDescriptor = _.find(this.inUseDescriptors || [], {descriptorId: this.selectedDescriptorId});\r\n this.descriptorName = selectedDescriptor ? selectedDescriptor.descriptorName : '';\r\n } else {\r\n this.descriptorName = '';\r\n }\r\n }\r\n }\r\n\r\n descriptorSelected(descriptor: Core.CompanyFeatureDescriptorModel) {\r\n if(!this.selectedDescriptorId) {\r\n this.descriptorName = '';\r\n }\r\n\r\n this.onDescriptorSelected.emit(descriptor);\r\n this.selectedDescriptorIdChange.emit(descriptor.descriptorId);\r\n }\r\n}\r\n","\r\n
\r\n \r\n
\r\n
\r\n Company does not have any characteristics in use.\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
NameCategoryEntity
{{item.descriptorName}}{{item.categoryName}}\r\n Site\r\n Parcel\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n List Empty\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport { EntityTypeIds } from '../../../../constants.new';\r\n\r\n@Component({\r\n selector: 'accruals-descriptors-modal',\r\n templateUrl: './accruals.descriptors.modal.component.html',\r\n})\r\nexport class AccrualsDescriptorsModalComponent implements OnInit {\r\n constructor(private bsModalRef: BsModalRef) { }\r\n\r\n //initialState\r\n companyId: number;\r\n accrualDescriptors: Core.CompanyFeatureDescriptorModel[];\r\n canEdit: boolean;\r\n flatInUseDescriptors: Core.CompanyFeatureDescriptorModel[];\r\n onClose: (accrualDescriptors?: Core.CompanyFeatureDescriptorModel[]) => void;\r\n\r\n loading: boolean = false;\r\n inUseDescriptors: _.Dictionary;\r\n EntityTypeIds = EntityTypeIds;\r\n\r\n\r\n async ngOnInit() {\r\n this.accrualDescriptors = _.sortBy(this.accrualDescriptors, ['entityTypeId', 'descriptorName']) || [];\r\n this.updateInUseDescriptors();\r\n }\r\n\r\n descriptorSelected(descriptor: any): void {\r\n descriptor = descriptor as Core.CompanyFeatureDescriptorModel;\r\n\r\n this.accrualDescriptors.push(descriptor);\r\n\r\n this.updateInUseDescriptors();\r\n }\r\n\r\n removeDescriptor(descriptor: Core.CompanyFeatureDescriptorModel): void {\r\n _.remove(this.accrualDescriptors, descriptor);\r\n\r\n this.updateInUseDescriptors();\r\n }\r\n\r\n updateInUseDescriptors(): void {\r\n this.inUseDescriptors = _.chain(this.flatInUseDescriptors)\r\n .reject(x => _.some(this.accrualDescriptors, {descriptorId: x.descriptorId, entityTypeId: x.entityTypeId}))\r\n .sortBy('descriptorName')\r\n .groupBy(x => x.entityTypeId == EntityTypeIds.SITE ? 'site' : 'parcel')\r\n .value();\r\n }\r\n\r\n cancel(): void {\r\n this.bsModalRef.hide();\r\n }\r\n\r\n save(): void {\r\n this.bsModalRef.hide();\r\n this.onClose(this.accrualDescriptors);\r\n }\r\n\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { AccrualsDescriptorsModalComponent } from './accruals.descriptors.modal.component';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'accruals-descriptors-link',\r\n template: `\r\n Site/Parcel Characteristics\r\n `\r\n})\r\nexport class AccrualsDescriptorsLinkComponent {\r\n constructor(private modalService: BsModalService) { }\r\n\r\n @Input() companyId: number;\r\n @Input() options: any;\r\n @Input() editMode: boolean;\r\n @Input() flatInUseDescriptors: Core.CompanyFeatureDescriptorModel[];\r\n\r\n launchModal() {\r\n const initialState = {\r\n companyId: this.companyId,\r\n accrualDescriptors: _.cloneDeep(this.options.accrualDescriptors),\r\n canEdit: this.editMode,\r\n flatInUseDescriptors: this.flatInUseDescriptors\r\n };\r\n\r\n const modalRef = this.modalService.show(AccrualsDescriptorsModalComponent, { initialState, ignoreBackdropClick: true });\r\n\r\n modalRef.content.onClose = (descriptors: Core.CompanyFeatureDescriptorModel[]) => {\r\n console.log(descriptors);\r\n this.options.accrualDescriptors = descriptors;\r\n };\r\n }\r\n\r\n}\r\n","import { Component, Input, Output, EventEmitter, OnChanges, SimpleChanges } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { TypeaheadOrder } from 'ngx-bootstrap/typeahead';\r\n\r\n@Component({\r\n selector: 'budget-descriptor-selector',\r\n template: `\r\n \r\n `\r\n})\r\nexport class BudgetDescriptorSelectorComponent implements OnChanges {\r\n @Input() inUseDescriptors: Core.CompanyFeatureDescriptorModel[];\r\n @Input() selectedDescriptorId: number;\r\n @Input() placeholder: string = '';\r\n @Input() disabled: boolean;\r\n @Output() onDescriptorSelected: EventEmitter = new EventEmitter();\r\n @Output() selectedDescriptorIdChange: EventEmitter = new EventEmitter();\r\n\r\n descriptorName: string = '';\r\n sortConfig: TypeaheadOrder = {\r\n direction: 'asc',\r\n field: 'categoryName'\r\n };\r\n\r\n ngOnChanges(changes: SimpleChanges) {\r\n if(changes.selectedDescriptorId) {\r\n if(changes.selectedDescriptorId.currentValue) {\r\n const selectedDescriptor = _.find(this.inUseDescriptors || [], {descriptorId: this.selectedDescriptorId});\r\n this.descriptorName = selectedDescriptor ? selectedDescriptor.descriptorName : '';\r\n } else {\r\n this.descriptorName = '';\r\n }\r\n }\r\n }\r\n\r\n descriptorSelected(descriptor: Core.CompanyFeatureDescriptorModel) {\r\n if(!this.selectedDescriptorId) {\r\n this.descriptorName = '';\r\n }\r\n\r\n this.onDescriptorSelected.emit(descriptor);\r\n this.selectedDescriptorIdChange.emit(descriptor.descriptorId);\r\n }\r\n}\r\n","\r\n
\r\n \r\n
\r\n
\r\n Company does not have any characteristics in use.\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
NameCategoryEntity
{{item.descriptorName}}{{item.categoryName}}\r\n Site\r\n Parcel\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n List Empty\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport { EntityTypeIds } from '../../../../constants.new';\r\n\r\n@Component({\r\n selector: 'budget-descriptors-modal',\r\n templateUrl: './budget.descriptors.modal.component.html',\r\n})\r\nexport class BudgetDescriptorsModalComponent implements OnInit {\r\n constructor(private bsModalRef: BsModalRef) { }\r\n\r\n //initialState\r\n companyId: number;\r\n budgetDescriptors: Core.CompanyFeatureDescriptorModel[];\r\n canEdit: boolean;\r\n flatInUseDescriptors: Core.CompanyFeatureDescriptorModel[];\r\n onClose: (budgetDescriptors?: Core.CompanyFeatureDescriptorModel[]) => void;\r\n\r\n loading: boolean = false;\r\n inUseDescriptors: _.Dictionary;\r\n EntityTypeIds = EntityTypeIds;\r\n\r\n\r\n async ngOnInit() {\r\n this.budgetDescriptors = _.sortBy(this.budgetDescriptors, ['entityTypeId', 'descriptorName']) || [];\r\n this.updateInUseDescriptors();\r\n }\r\n\r\n descriptorSelected(descriptor: any): void {\r\n descriptor = descriptor as Core.CompanyFeatureDescriptorModel;\r\n\r\n this.budgetDescriptors.push(descriptor);\r\n\r\n this.updateInUseDescriptors();\r\n }\r\n\r\n removeDescriptor(descriptor: Core.CompanyFeatureDescriptorModel): void {\r\n _.remove(this.budgetDescriptors, descriptor);\r\n\r\n this.updateInUseDescriptors();\r\n }\r\n\r\n updateInUseDescriptors(): void {\r\n this.inUseDescriptors = _.chain(this.flatInUseDescriptors)\r\n .reject(x => _.some(this.budgetDescriptors, {descriptorId: x.descriptorId, entityTypeId: x.entityTypeId}))\r\n .sortBy('descriptorName')\r\n .groupBy(x => x.entityTypeId == EntityTypeIds.SITE ? 'site' : 'parcel')\r\n .value();\r\n }\r\n\r\n cancel(): void {\r\n this.bsModalRef.hide();\r\n }\r\n\r\n save(): void {\r\n this.bsModalRef.hide();\r\n this.onClose(this.budgetDescriptors);\r\n }\r\n\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { BudgetDescriptorsModalComponent } from './budget.descriptors.modal.component';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'budget-descriptors-link',\r\n template: `\r\n Site/Parcel Characteristics\r\n `\r\n})\r\nexport class BudgetDescriptorsLinkComponent {\r\n constructor(private modalService: BsModalService) { }\r\n\r\n @Input() companyId: number;\r\n @Input() options: any;\r\n @Input() editMode: boolean;\r\n @Input() flatInUseDescriptors: Core.CompanyFeatureDescriptorModel[];\r\n\r\n launchModal() {\r\n const initialState = {\r\n companyId: this.companyId,\r\n budgetDescriptors: _.cloneDeep(this.options.budgetDescriptors),\r\n canEdit: this.editMode,\r\n flatInUseDescriptors: this.flatInUseDescriptors\r\n };\r\n\r\n const modalRef = this.modalService.show(BudgetDescriptorsModalComponent, { initialState, ignoreBackdropClick: true });\r\n\r\n modalRef.content.onClose = (descriptors: Core.CompanyFeatureDescriptorModel[]) => {\r\n console.log(descriptors);\r\n this.options.budgetDescriptors = descriptors;\r\n };\r\n }\r\n\r\n}\r\n","
\r\n
\r\n \r\n

Company Settings

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n Company Collectors:\r\n \r\n \r\n Manage ({{company.collectorCount || 0}})\r\n \r\n {{company.collectorCount || 0}}\r\n \r\n
\r\n
\r\n
\r\n \r\n Use Top Level Company's Vendor Code Mapping:\r\n \r\n \r\n \r\n
\r\n\r\n \r\n Company Vendor Code Mapping: \r\n Manage ({{ company.vendorCodeCount || 0 }})\r\n {{ company.vendorCodeCount || 0 }}\r\n \r\n
\r\n
\r\n \r\n Fiscal Year Start:\r\n \r\n \r\n
\r\n
\r\n \r\n Sync with Ryan.com Platform:\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n Invoice Appeal Savings:\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n Require Client Approval:\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n Budgets Enabled:\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Accruals Enabled:\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Exclude Company From Accruals:\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n Use Top-Level Company Chart of Accounts:\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n Consultants: Manage\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n

Utilities

\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n

Allocations

\r\n
\r\n \r\n
\r\n
\r\n
\r\n

Data Hub Settings

\r\n
\r\n
\r\n
\r\n \r\n Data Hub Enabled:\r\n \r\n \r\n \r\n {{options.dataHubEnabled ? 'Yes' : 'No'}}\r\n
\r\n
\r\n \r\n Data Hub Client Tenant Id:\r\n \r\n \r\n {{options.dataHubClientTenantId}}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { CompanyModel, CompanyService } from '../company.service';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { MessageBoxButtons, MessageBoxResult, MessageBoxService } from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { DXPService } from '../../../Admin/DXP/dxp.service';\r\nimport { StateService } from '../../../Common/States/States.Service';\r\nimport { UserInstanceService } from '../../../User/userInstance.service';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { CompanyContractsModalParams, CompanyContractsModalComponent } from '../../../Consulting/CompanyContracts/companyContractsModal.component';\r\nimport { EntityTypeIds } from '../../../constants.new';\r\nimport { InstanceRights, RestrictService } from '../../../Common/Permissions/restrict.service';\r\nimport { SnackBarService } from '../../../Busy-Indicator';\r\n\r\nimport * as _ from 'lodash';\r\nimport * as Moment from 'moment';\r\nimport { UserService } from '../../../Account/user.service';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\n\r\n@Component({\r\n selector: 'company-settings',\r\n templateUrl: './companySettings.component.html',\r\n styleUrls: ['./companySettings.component.scss']\r\n})\r\nexport class CompanySettingsComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _companyService: CompanyService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _dxpService: DXPService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _statesService: StateService,\r\n private readonly _modalService: WeissmanModalService,\r\n public readonly _snackBarService: SnackBarService,\r\n private readonly _userService: UserService,\r\n private readonly _featureFlagService: FeatureFlagsService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n @Input() company: CompanyModel;\r\n @Input() companyId: number;\r\n @Input() allowEdit: boolean;\r\n @Input() isTopLevelCompany: boolean;\r\n @Input() parentCompany: Weissman.Model.Domain.Company;\r\n\r\n editMode: boolean;\r\n editLock: boolean;\r\n addingYear: boolean;\r\n isShowSettings: boolean;\r\n isLoading: boolean;\r\n useParentVendorFlag: boolean = true;\r\n dxpSyncDisabled: boolean = true;\r\n syncDxpLocked: boolean;\r\n selectingState: boolean;\r\n accrualsEnabled: boolean;\r\n flatInUseDescriptors: Core.CompanyFeatureDescriptorModel[];\r\n inUseDescriptors: _.Dictionary;\r\n canImportData: boolean;\r\n hasManageConsultingEngagements: boolean;\r\n showAllocations: boolean = false;\r\n\r\n taxAmountAdjustments: Compliance.NameValuePair[] = [\r\n { name: 'Amortize', value: 2 },\r\n { name: 'Single Period', value: 1 }\r\n ];\r\n\r\n exportFileTypes: Core.AllowedAccrualFileTypeModel[] = [];\r\n\r\n budgetBasisOptions: Compliance.NameValuePair[] = [\r\n { name: 'Accrual', value: 1 },\r\n { name: 'Cash', value: 2 },\r\n { name: 'Accrual and Cash', value: 3 },\r\n ];\r\n\r\n exportProperties: Compliance.NameValuePair[] = [\r\n { name: 'Site Number', value: Core.AccrualExportPropertyIdentificationEnum.SiteNumber}\r\n ];\r\n\r\n options;\r\n companyStateModel = {\r\n stateNames: []\r\n };\r\n\r\n yearToAdd: number;\r\n yearsToAdd: number[];\r\n economicUnitTypes: Core.EconomicUnitTypeModel[];\r\n companyStates: string[] = [];\r\n\r\n siteCodeEconUnitTypeId = 0;\r\n\r\n entityIsInRyanInstance = false;\r\n showInvoiceAppealSavingsSetting = false;\r\n enablePaymentBatchDataHub = false\r\n\r\n private _originalOptions;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get siteCharSelectedForExport(): boolean {\r\n return this.options.accrualExportPropertyIdentificationId === Core.AccrualExportPropertyIdentificationEnum.SiteCharacteristic;\r\n }\r\n\r\n get siteNumberSelectedForExport(): boolean {\r\n return this.options.accrualExportPropertyIdentificationId === Core.AccrualExportPropertyIdentificationEnum.SiteNumber;\r\n }\r\n\r\n get canChangeUseTopLevelCompanyCOA(): boolean {\r\n return this.company.topLevelCompanyId === this.company.companyID ||\r\n !this.company.hasIncomeStatements;\r\n }\r\n\r\n get useTopLevelCompanyCOATitle(): string {\r\n let result: string;\r\n\r\n if (this.editMode && !this.canChangeUseTopLevelCompanyCOA) {\r\n result = this.company.useTopLevelCompanyCOA\r\n ? 'Income Statements exist that use the Top-Level Company Chart of Accounts. Income Statements must be deleted in order to proceed.'\r\n : 'Income Statements exist that use the Subsidiary Chart of Accounts. Income Statements must be deleted in order to proceed.';\r\n }\r\n\r\n return result;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this.showAllocations = this._featureFlagService.featureFlags.enableResponsibleEntityFeature;\r\n this.enablePaymentBatchDataHub = this._featureFlagService.featureFlags.enablePaymentBatchDataHub\r\n\r\n this.options = {\r\n useParentVendorFlag: this.company.useParentVendorCodes,\r\n invoiceAppealSavingsFlag: this.company.invoiceAppealSavings,\r\n syncDXPFlag: this.company.syncDXP,\r\n fiscalYearStart: this.company.fiscalYearStart,\r\n budgetsEnabled: this.company.budgetsEnabled,\r\n budgetBasis: this.company.budgetBasis,\r\n budgetDescriptors: this.company.budgetDescriptors,\r\n accrualsEnabled: this.company.accrualsEnabled,\r\n defaultAccrualAdjustmentMethodId: this.company.defaultAccrualAdjustmentMethodId,\r\n accrualEconUnitTypeId: this.company.accrualEconUnitTypeId,\r\n accrualEconUnitDescriptorId: this.company.accrualEconUnitDescriptorId,\r\n useTopLevelCompanyCOA: this.company.useTopLevelCompanyCOA,\r\n accrualFileTypeId: this.company.accrualFileTypeId,\r\n excludeFromAccruals: this.company.excludeFromAccruals,\r\n accrualDescriptors: this.company.accrualDescriptors,\r\n tlCompanyAccrualsEnabled: this.company.tlCompanyAccrualsEnabled,\r\n accrualExportPropertyIdentificationId: this.company.accrualExportPropertyIdentificationId,\r\n accrualExportPropIdentDescriptorId: this.company.accrualExportPropIdentDescriptorId,\r\n requireClientApprovalFlag: this.company.requireClientApproval,\r\n enableAllocations: this.company.enableAllocations,\r\n dataHubEnabled: this.company.dataHubEnabled,\r\n dataHubClientTenantId: this.company.dataHubClientTenantId\r\n };\r\n\r\n const promises: [Promise, Promise, Promise?] = [\r\n this._companyService.getEconomicUnitTypes(),\r\n this._companyService.getAllowedAccrualFileTypes(this.companyId)\r\n ];\r\n\r\n if (this.options.budgetsEnabled || this.options.accrualsEnabled) {\r\n promises.push(this._getInUseDescriptors());\r\n }\r\n\r\n const initialCalls = await Promise.all(promises);\r\n\r\n this.economicUnitTypes = (initialCalls[0] as Core.GetEconomicUnitTypesResult).types;\r\n if(this.economicUnitTypes.length) {\r\n // Make sure economic unit types are sorted in ascending Name order\r\n this.economicUnitTypes = this.economicUnitTypes.sort((a, b) => a.name.localeCompare(b.name));\r\n // Default Economic Unit to first in list if one hasn't been selected.\r\n this.options.accrualEconUnitTypeId = this.options.accrualEconUnitTypeId || this.economicUnitTypes[0].economicUnitTypeId;\r\n const entry = this.economicUnitTypes.find(x => x.name === 'Site Code');\r\n this.siteCodeEconUnitTypeId = entry ? entry.economicUnitTypeId : 0;\r\n }\r\n\r\n this.exportFileTypes = (initialCalls[1] as Core.AllowedAccrualFileTypesResultModel).entries;\r\n if(this.exportFileTypes.length) {\r\n // Make sure types are sorted in ascending Accrual File Type Id order\r\n this.exportFileTypes = this.exportFileTypes.sort((a, b) => a.accrualFileTypeId - b.accrualFileTypeId);\r\n }\r\n\r\n this.entityIsInRyanInstance = this.company.instanceID == this._userInstanceService.RyanInstanceId;\r\n this.canImportData = this._restrictService.hasInstanceRight(InstanceRights.COMPANYDATAIMPORTSVIEW, this.company.instanceID);\r\n this.hasManageConsultingEngagements = this._restrictService.hasInstanceRight(InstanceRights.MANAGECONSULTINGENGAGEMENT, this.company.instanceID);\r\n this.showInvoiceAppealSavingsSetting = this.company.instanceID == this._userInstanceService.RyanInstanceId ||\r\n this._userService.hasRyanInstanceMembership() && this._userInstanceService.isCurrentInstanceRyan();\r\n\r\n this._navigationService.globalEditMode$.pipe(takeUntil(this._destroy$)).subscribe(editMode => {\r\n this.editLock = editMode;\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n setEditMode(): void {\r\n this._originalOptions = _.cloneDeep(this.options);\r\n this.editMode = true;\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n this._productAnalyticsService.logEvent('edit-company-settings');\r\n }\r\n\r\n cancelEdit() {\r\n this.options = this._originalOptions;\r\n this.editMode = false;\r\n this.selectingState = false;\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n async save(): Promise {\r\n if (!this.options.fiscalYearStart) {\r\n this._toastr.warning('Please enter Fiscal Year Start in the format MM/DD (for example 10/30 for October 30th)', 'Invalid Fiscal Year Start entered');\r\n return;\r\n }\r\n else{\r\n const dateSlashValid = Moment(this.options.fiscalYearStart, 'M/D', true).isValid();\r\n const dateDashValid = Moment(this.options.fiscalYearStart, 'M-D', true).isValid();\r\n\r\n if (!(dateSlashValid || dateDashValid)){\r\n this._toastr.warning(`${this.options.fiscalYearStart } is not valid date`, 'Invalid Fiscal Year Start entered');\r\n return;\r\n }\r\n }\r\n if ( !this.options.accrualsEnabled || !this.isTopLevelCompany )\r\n {\r\n this.options.accrualEconUnitTypeId = null;\r\n this.options.accrualEconUnitDescriptorId = null;\r\n this.options.accrualFileTypeId = null;\r\n }\r\n else if ( this.options.accrualEconUnitTypeId )\r\n {\r\n if (this.options.accrualEconUnitTypeId == this.siteCodeEconUnitTypeId) {\r\n if (!this.options.accrualEconUnitDescriptorId) {\r\n this._toastr.error('Economic Unit Site Code is required');\r\n return;\r\n }\r\n } else {\r\n // Descriptor Id is non-applicable unless Econ Unit is SiteCode.\r\n this.options.accrualEconUnitDescriptorId = null;\r\n }\r\n }\r\n if (this.isTopLevelCompany && this.options.dataHubEnabled && !this.options.dataHubClientTenantId) {\r\n this._toastr.warning('Please enter a non-empty value for Data Hub Client Tenant Id', 'Invalid Data Hub Client Tenant Id entered');\r\n return;\r\n }\r\n\r\n this.isLoading = true;\r\n try {\r\n const result = await this._companyService.updateCompanySetting(\r\n this.companyId,\r\n this.options.useParentVendorFlag,\r\n this.options.invoiceAppealSavingsFlag,\r\n this.options.fiscalYearStart,\r\n this.options.syncDXPFlag,\r\n this.options.budgetsEnabled,\r\n this.options.budgetBasis,\r\n this.options.budgetDescriptors,\r\n this.options.accrualsEnabled,\r\n this.options.defaultAccrualAdjustmentMethodId,\r\n this.options.useTopLevelCompanyCOA,\r\n this.options.accrualEconUnitTypeId,\r\n this.options.accrualEconUnitDescriptorId,\r\n this.options.accrualFileTypeId,\r\n this.options.accrualDescriptors,\r\n this.options.excludeFromAccruals,\r\n this.options.accrualExportPropertyIdentificationId,\r\n this.options.accrualExportPropIdentDescriptorId,\r\n this.options.requireClientApprovalFlag,\r\n this.options.enableAllocations,\r\n this.options.dataHubEnabled,\r\n this.options.dataHubClientTenantId\r\n );\r\n\r\n if (this.company.useParentVendorCodes !== this.options.useParentVendorFlag) {\r\n this.company.vendorCodeCount = result.vendorCodeCount;\r\n }\r\n this.company.useParentVendorCodes = result.useParentVendorCodes;\r\n this.company.invoiceAppealSavings = result.invoiceAppealSavings;\r\n this.company.rowVersion = result.rowVersion;\r\n this.company.budgetsEnabled = result.budgetsEnabled;\r\n this.company.budgetBasis = this.options.budgetBasis;\r\n this.company.budgetDescriptors = result.budgetDescriptors;\r\n this.company.accrualsEnabled = result.accrualsEnabled;\r\n this.company.defaultAccrualAdjustmentMethodId = this.options.defaultAccrualAdjustmentMethodId;\r\n this.company.useTopLevelCompanyCOA = this.options.useTopLevelCompanyCOA;\r\n this.company.accrualEconUnitTypeId = this.options.accrualEconUnitTypeId;\r\n this.company.accrualEconUnitDescriptorId = this.options.accrualEconUnitDescriptorId;\r\n this.company.accrualFileTypeId = this.options.accrualFileTypeId;\r\n this.company.accrualDescriptors = result.accrualDescriptors;\r\n this.company.excludeFromAccruals = this.options.excludeFromAccruals;\r\n this.company.accrualExportPropertyIdentificationId = result.accrualExportPropertyIdentificationId;\r\n this.company.accrualExportPropIdentDescriptorId = result.accrualExportPropIdentDescriptorId;\r\n this.company.requireClientApproval = result.requireClientApproval;\r\n this.company.enableAllocations = result.enableAllocations;\r\n this.company.dataHubEnabled = result.dataHubEnabled;\r\n this.company.dataHubClientTenantId = result.dataHubClientTenantId;\r\n\r\n this.editMode = false;\r\n } finally {\r\n this.isLoading = false;\r\n this._navigationService.disableNavWarning();\r\n }\r\n }\r\n\r\n expandOrCollapse() {\r\n if(this.editMode) {\r\n return;\r\n }\r\n\r\n this.isShowSettings = !this.isShowSettings;\r\n this._productAnalyticsService.logEvent('company-toggle-panel', {\r\n panel: 'Company Settings',\r\n isOpen: this.isShowSettings\r\n });\r\n\r\n if(this.isShowSettings) {\r\n this.showSettings();\r\n }\r\n }\r\n\r\n async showSettings(): Promise {\r\n this.isLoading = true;\r\n\r\n const results = await Promise.all([\r\n this._companyService.getCompanyVendorCodesCount(this.companyId),\r\n this._companyService.getCompanyYears(this.companyId),\r\n this._companyService.getStatesWithSites(this.companyId, true, true),\r\n this._dxpService.getDXPMode(),\r\n this.isTopLevelCompany ? this._dxpService.IsSyncDxpLocked(this.companyId) : Promise.resolve(false),\r\n this._companyService.checkAccrualsEnabled()\r\n ]);\r\n\r\n // Company vendor code count\r\n this.company.vendorCodeCount = results[0];\r\n\r\n // Company years\r\n let companyYears = results[1];\r\n const currentYear = new Date().getFullYear();\r\n\r\n if (!companyYears)\r\n {\r\n companyYears = [];\r\n }\r\n else if (companyYears.length === 0){\r\n companyYears.push(currentYear);\r\n }\r\n\r\n const startingYear = companyYears.reduce((acc, x) => !acc || x < acc ? x : acc) - 5;\r\n\r\n this.yearToAdd = currentYear;\r\n this.yearsToAdd = Array\r\n .from({ length: companyYears.length + 10 }, (x, i) => i + startingYear)\r\n .sort()\r\n .reverse();\r\n\r\n // States with sites\r\n this.companyStates = results[2] || [];\r\n\r\n // DXP mode\r\n this.dxpSyncDisabled = results[3] === Core.DXPSyncModes.Disabled;\r\n\r\n // Sync DXP locked\r\n this.syncDxpLocked = results[4];\r\n\r\n // Check Accruals Enabled\r\n this.accrualsEnabled = results[5];\r\n\r\n this.isLoading = false;\r\n }\r\n\r\n startAddYear(): void {\r\n this.addingYear = true;\r\n }\r\n\r\n cancelAddYear(): void {\r\n this.addingYear = false;\r\n }\r\n\r\n async addYear(year): Promise {\r\n // Exit if the user said they wanted to select states but has nothing selected\r\n if (this.selectingState && this.companyStateModel.stateNames.length < 1) {\r\n return;\r\n }\r\n let message = 'Confirm adding the given year to all the active parcels under the company?';\r\n if (this.selectingState) {\r\n message = 'Confirm adding the given year to all the active parcels under the company for the selected states?';\r\n }\r\n const result = await this._messageBoxService.open({\r\n title: 'Add Year',\r\n message: message,\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n\r\n if (result === MessageBoxResult.Yes) {\r\n const stateSummary = await this._statesService.getSummary();\r\n\r\n let selectedStates;\r\n if (this.selectingState) {\r\n selectedStates = stateSummary\r\n .filter((st) => this.companyStateModel.stateNames.indexOf(st.abbr) >= 0)\r\n .map((st) => st.stateID);\r\n }\r\n\r\n try {\r\n const lrp = await this._companyService.addYear(this.companyId, year, selectedStates);\r\n this._snackBarService.addById(lrp.longRunningProcessId, Compliance.LongRunningProcessTypeEnum.AddYearToCompanyPortfolio);\r\n } catch(error) {\r\n // If we get a forbidden error, just let default handling happen\r\n if (error.status !== 403) {\r\n this._toastr.error('An error occurred.');\r\n }\r\n console.warn(error);\r\n } finally {\r\n this.addingYear = false;\r\n }\r\n }\r\n }\r\n\r\n invoiceAppealSavingsOverridden(){\r\n return this.companyId !== this.company.topLevelCompanyId\r\n && (!this.editMode && this.company.invoiceAppealSavings !== this.company.topLevelCompanyInvoiceAppealSavings\r\n || this.editMode && this.options.invoiceAppealSavingsFlag !== this.company.topLevelCompanyInvoiceAppealSavings);\r\n }\r\n\r\n requireClientApprovalOverridden(){\r\n return this.companyId !== this.company.topLevelCompanyId\r\n && (!this.editMode && this.company.requireClientApproval !== this.company.topLevelCompanyRequireClientApproval\r\n || this.editMode && this.options.requireClientApprovalFlag !== this.company.topLevelCompanyRequireClientApproval);\r\n }\r\n\r\n toggleSelectingState(): void {\r\n if (!this.editMode) { return; }\r\n this.selectingState = !this.selectingState;\r\n }\r\n\r\n descriptorSelected(descriptor) {\r\n this.options.accrualEconUnitDescriptorId = descriptor.descriptorId;\r\n }\r\n\r\n async showContracts() {\r\n const params: CompanyContractsModalParams = {company: this.company};\r\n await this._modalService.showAsync(CompanyContractsModalComponent, params, 'modal-lg');\r\n }\r\n\r\n budgetEnabledChanged( budgetEnabled: boolean): void {\r\n if(budgetEnabled && !this.inUseDescriptors) {\r\n this._getInUseDescriptors();\r\n }\r\n }\r\n\r\n accrualsEnabledChanged(accrualsEnabled: boolean): void {\r\n if(accrualsEnabled && !this.inUseDescriptors) {\r\n this._getInUseDescriptors();\r\n }\r\n }\r\n\r\n exportPropertyChanged(id: Core.AccrualExportPropertyIdentificationEnum): void {\r\n if(id !== this.options.accrualExportPropertyIdentificationId) {\r\n this.options.accrualExportPropIdentDescriptorId = null;\r\n }\r\n\r\n this.options.accrualExportPropertyIdentificationId = id;\r\n }\r\n\r\n enableAllocationsOverridden(): boolean {\r\n return this.companyId !== this.company.topLevelCompanyId\r\n && (!this.editMode && this.company.enableAllocations !== this.company.topLevelCompanyEnableAllocations\r\n || this.editMode && this.options.enableAllocations !== this.company.topLevelCompanyEnableAllocations);\r\n }\r\n\r\n logAnalyticsEvent(eventName: string): void {\r\n this._productAnalyticsService.logEvent(eventName);\r\n }\r\n\r\n private async _getInUseDescriptors(): Promise {\r\n this.flatInUseDescriptors = await this._companyService.getInUseCharacteristics(this.companyId, true);\r\n this.inUseDescriptors = _.chain(this.flatInUseDescriptors)\r\n .cloneDeep()\r\n .filter(x => _.includes([Core.DescriptorFieldTypes.Number, Core.DescriptorFieldTypes.Text], x.descriptorFieldTypeId))\r\n .sortBy('descriptorName')\r\n .groupBy(x => EntityTypeIds[x.entityTypeId])\r\n .value();\r\n\r\n if(this.inUseDescriptors.SITE) {\r\n this.exportProperties.push({ name: 'Site Characteristic', value: Core.AccrualExportPropertyIdentificationEnum.SiteCharacteristic});\r\n }\r\n if(this.inUseDescriptors.PARCEL) {\r\n this.exportProperties.push({ name: 'Parcel Characteristic', value: Core.AccrualExportPropertyIdentificationEnum.ParcelCharacteristic});\r\n }\r\n }\r\n}\r\n","\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\n\r\n@Component({\r\n selector: 'company-compliance',\r\n templateUrl: './companyCompliance.component.html',\r\n styleUrls: ['./companyCompliance.component.scss']\r\n})\r\nexport class CompanyComplianceComponent implements OnInit {\r\n constructor(private readonly _featureFlagService: FeatureFlagsService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {}\r\n\r\n @Input() company;\r\n @Input() parentCompany;\r\n @Input() isTopLevelCompany: boolean;\r\n\r\n isShowInfo: boolean = false;\r\n hasAllocationFeature: boolean = false;\r\n\r\n get isLoading(): boolean {\r\n return !this.company;\r\n }\r\n\r\n ngOnInit(): void {\r\n this.hasAllocationFeature = this._featureFlagService.featureFlags.enableAllocationFeature;\r\n }\r\n\r\n expandOrCollapse() {\r\n this.isShowInfo = !this.isShowInfo;\r\n this._productAnalyticsService.logEvent('company-toggle-panel', {\r\n panel: 'Compliance Info',\r\n isOpen: this.isShowInfo\r\n });\r\n }\r\n\r\n emitAnalyticsEvent(eventName: string): void {\r\n this._productAnalyticsService.logEvent(eventName);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { CollectorVendorCode } from './vendorCodeMapping.component';\r\n\r\n@Injectable()\r\nexport class VendorCodeService {\r\n constructor(private readonly _http: HttpClient) { }\r\n\r\n private readonly _baseUrl: string = '/api';\r\n\r\n getCompanyCollectorVendorCodes(companyId: number, getAll: boolean): Promise {\r\n const url = `${this._baseUrl}/collector/company/${companyId}/collectorvendor`;\r\n const params = new HttpParams().set('getAll', getAll.toString());\r\n\r\n return lastValueFrom(this._http.get(url, { params })) as Promise;\r\n }\r\n\r\n createCollectorVendorCode(vendorCode: CollectorVendorCode): Promise {\r\n return lastValueFrom(this._http.post(`${this._baseUrl}/vendorcode`, vendorCode)) as Promise;\r\n }\r\n\r\n updateCollectorVendorCode(vendorCode: CollectorVendorCode): Promise {\r\n return lastValueFrom(this._http.put(`${this._baseUrl}/vendorcode`, vendorCode)) as Promise;\r\n }\r\n\r\n deleteCollectorVendorCode(vendorCodeId: number): Promise {\r\n return lastValueFrom(this._http.delete(`${this._baseUrl}/vendorcode/${vendorCodeId}`)) as Promise;\r\n }\r\n\r\n}\r\n","\r\n \r\n {{ prefix }}{{ selectedRowCount | number }} of {{ totalRowCount | number }} row{{ totalRowCount === 1 ? '': 's' }} selected{{ suffix }}\r\n \r\n \r\n {{ prefix }}{{ totalRowCount | number }} row{{ totalRowCount === 1 ? '': 's' }}{{ suffix }}\r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { GridOptions } from 'ag-grid-community';\r\nimport { AgGridMultiSelectTracker } from '../MultiSelectTracker';\r\n\r\n@Component({\r\n selector: 'ag-grid-row-count',\r\n templateUrl: './agGridRowCount.component.html',\r\n styleUrls: ['./agGridRowCount.component.scss']\r\n})\r\nexport class AgGridRowCountComponent {\r\n @Input() gridTracker: AgGridMultiSelectTracker;\r\n @Input() gridOptions: GridOptions;\r\n @Input() prefix: string = '(';\r\n @Input() suffix: string = ')';\r\n @Input() cssClass: string = 'ag-grid-row-count-text';\r\n @Input() useWhiteText: boolean;\r\n\r\n get supportsSelect(): boolean {\r\n return this.gridTracker ||\r\n (this.gridOptions && (this.gridOptions.rowSelection === 'single' || this.gridOptions.rowSelection === 'multiple')) ? true : false;\r\n }\r\n\r\n get selectedRowCount(): number {\r\n if (this.gridTracker) {\r\n return this.gridTracker.getSelectedRowsCount();\r\n }\r\n\r\n if (this.gridOptions && this.gridOptions.api) {\r\n return this.gridOptions.api.getSelectedRows().length;\r\n }\r\n\r\n return 0;\r\n }\r\n\r\n get totalRowCount(): number {\r\n if (!(this.gridOptions && this.gridOptions.api)) {\r\n return 0;\r\n }\r\n\r\n if (this.gridOptions.rowModelType === 'infinite') {\r\n return this.gridOptions.api.isMaxRowFound() ? this.gridOptions.api.getInfiniteRowCount() : 0;\r\n } else {\r\n return this.gridOptions.api.getDisplayedRowCount();\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n

\r\n Vendor Code Mapping\r\n \r\n

\r\n
\r\n
\r\n Show All Collectors\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GridApi, GridOptions, GridReadyEvent, ColDef, CellValueChangedEvent } from 'ag-grid-community';\r\nimport { BreadCrumb } from 'src/app/UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from 'src/app/Compliance/AgGrid';\r\nimport { CompanyService } from '../company.service';\r\nimport { VendorCodeService } from './vendorCode.service';\r\nimport * as _ from 'lodash';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\nexport interface CollectorVendorCode {\r\n state: string;\r\n collectorName: string;\r\n collectorID: number;\r\n collectorAddressID: number;\r\n collectorAddress: Core.AddressModel;\r\n vendorCodeID: number;\r\n vendorCode: string;\r\n companyID: number;\r\n stateID: number;\r\n rowVersion: string;\r\n}\r\n\r\n@Component({\r\n selector: 'vendor-code-mapping',\r\n templateUrl: './vendorCodeMapping.component.html',\r\n styles: [`\r\n :host {\r\n display: flex;\r\n flex-flow: column;\r\n height: 100%;\r\n width: 100%;\r\n }\r\n `]\r\n})\r\n\r\nexport class VendorCodeMappingComponent implements OnInit {\r\n constructor(\r\n private readonly _vendorCodeService: VendorCodeService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler) { }\r\n\r\n companyId: number;\r\n showAllCollectors: boolean = false;\r\n breadcrumbs: BreadCrumb[];\r\n\r\n gridId: System.Guid = '7D885CAC-39F4-4CAE-AE56-B8948DE60508'; // need new guid\r\n isInitialized: boolean = false;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n refreshing: boolean;\r\n\r\n private _gridApi: GridApi;\r\n private _vendorCodes: CollectorVendorCode[];\r\n\r\n async ngOnInit(): Promise {\r\n this.companyId = +this._upgradeNavigationServiceHandler.getQuerystringParam('companyId');\r\n const companyName = await this._companyService.getCompanyName(this.companyId);\r\n this.breadcrumbs = [\r\n {\r\n name: companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n }\r\n ];\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Collector Name',\r\n field: 'collectorName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Collector Abbr',\r\n field: 'collectorAbbr',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Vendor Code',\r\n field: 'vendorCode',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n editable: true,\r\n onCellValueChanged: this._cellValueChanged.bind(this)\r\n },\r\n {\r\n headerName: 'Address1',\r\n field: 'collectorAddress.address1',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Address2',\r\n field: 'collectorAddress.address2',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'City',\r\n field: 'collectorAddress.city',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'State Abbr',\r\n field: 'collectorAddress.abbr',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.stateAbbreviationColumnWidth\r\n },\r\n {\r\n headerName: 'Zip',\r\n field: 'collectorAddress.zip',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'state',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._gridApi.sizeColumnsToFit();\r\n\r\n await this._refresh();\r\n }\r\n\r\n async refresh(): Promise {\r\n await this._refresh();\r\n }\r\n\r\n private async _cellValueChanged(params: CellValueChangedEvent) {\r\n if (params.newValue === params.oldValue) {\r\n return;\r\n }\r\n\r\n let newValue = params.newValue;\r\n const collector = params.data as CollectorVendorCode;\r\n newValue = _.trim(newValue);\r\n\r\n if (newValue.length > 50) {\r\n this._toastr.error('Vendor Code must be 50 characters or less');\r\n params.node.setDataValue('vendorCode', params.oldValue);\r\n\r\n return;\r\n }\r\n\r\n if (!collector.vendorCode) {\r\n if (!collector.vendorCodeID) {\r\n return;\r\n }\r\n\r\n await this._vendorCodeService.deleteCollectorVendorCode(collector.vendorCodeID);\r\n this._toastr.info('Vendor Code Deleted!');\r\n } else {\r\n const payload = {\r\n companyID: collector.companyID || this.companyId,\r\n collectorID: collector.collectorID,\r\n vendorCodeValue: collector.vendorCode,\r\n vendorCodeID: collector.vendorCodeID || 0,\r\n rowVersion: collector.rowVersion\r\n } as unknown as CollectorVendorCode;\r\n\r\n if(payload.vendorCodeID) {\r\n await this._vendorCodeService.updateCollectorVendorCode(payload);\r\n } else {\r\n await this._vendorCodeService.createCollectorVendorCode(payload);\r\n }\r\n\r\n this._toastr.info('Vendor Code Saved!');\r\n await this._refresh();\r\n }\r\n\r\n }\r\n\r\n private async _refresh(): Promise {\r\n this.refreshing = true;\r\n\r\n this._vendorCodes = [];\r\n\r\n try {\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n this._vendorCodes = await this._vendorCodeService.getCompanyCollectorVendorCodes(this.companyId, this.showAllCollectors);\r\n } finally {\r\n this._gridApi && this._gridApi.hideOverlay();\r\n }\r\n\r\n this._setRowData();\r\n this.refreshing = false;\r\n }\r\n\r\n private _setRowData() {\r\n if (!(this._gridApi && this._vendorCodes)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._vendorCodes);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from 'src/app/Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from 'src/app/Hybrid/hybrid-adapter.utility';\r\nimport { VendorCodeService } from './vendorCode.service';\r\nimport { VendorCodeMappingComponent } from './vendorCodeMapping.component';\r\n\r\n@NgModule({\r\n imports: [WeissmanSharedModule],\r\n exports: [],\r\n declarations: [VendorCodeMappingComponent],\r\n providers: [VendorCodeService],\r\n})\r\nexport class VendorCodeModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('vendorCodeMapping', VendorCodeMappingComponent);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { CacheManager, CacheManagerService } from '../../Common/Routing/cache-manager.service';\r\nimport { SiteClassRepository } from '../../Core-Repositories';\r\nimport { SiteClassPrimary } from '../../Core-Repositories/siteClass.repository';\r\n\r\n// TODO export from back end\r\nexport interface SiteClassSecondary {\r\n siteClassSecondaryID: number;\r\n siteClassDesc: string;\r\n siteClassPrimaryID: number;\r\n}\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class SiteClassService {\r\n constructor(\r\n private readonly _cacheManagerService: CacheManagerService,\r\n private readonly _siteClassRepository: SiteClassRepository\r\n ) {\r\n this.cacheManager = _cacheManagerService.createCacheManager();\r\n this.cacheManager.registerKeyedStaticCache('siteClassSecondary', {\r\n cacheKey: 'siteclasssecondary',\r\n endpoint: '/api/siteclasssecondary',\r\n cacheDisabled: false\r\n });\r\n }\r\n\r\n cacheManager: CacheManager;\r\n\r\n getSecondaries(): Promise {\r\n return this.cacheManager.keyedStaticGet('siteClassSecondary');\r\n }\r\n\r\n getPrimaries(): Promise {\r\n return lastValueFrom(this._siteClassRepository.getPrimaries());\r\n }\r\n}\r\n","export interface ReportingParcelTile extends Core.ParcelTileDTO {\r\n isExternalReportingParcel?: boolean;\r\n isReportingParcel?: boolean;\r\n}\r\n\r\nexport interface ParcelListControlRow extends ReportingParcelTile {\r\n isTotalRow: boolean;\r\n returnCount: number;\r\n totalFMV: number;\r\n totalTaxes: number;\r\n totalComponents: {[componentName: string]: number};\r\n siteID?: number;\r\n companyID?: number;\r\n originalIsReportingParcel?: boolean;\r\n originalConsolidatingTypeId?: number;\r\n originalConsolidatedParcelId?: number;\r\n}\r\n\r\nexport class ParcelList {\r\n constructor(\r\n private readonly _incomingParcels: Core.ParcelTileDTO[]) {\r\n this._initialize();\r\n }\r\n\r\n private _tiles: ParcelListControlRow[] = [];\r\n private _parcels: ParcelListControlRow[] = [];\r\n\r\n private _parcelsRepository: ParcelListControlRow[] = [];\r\n\r\n get tiles(): ParcelListControlRow[] {\r\n return this._tiles;\r\n }\r\n\r\n get parcels(): ParcelListControlRow[] {\r\n return this._parcels;\r\n }\r\n\r\n filterInactive(show: boolean): void {\r\n if (show) {\r\n const filtered = this._parcelsRepository.filter((p) => p.activityStatusID !== 0);\r\n this._tiles = filtered;\r\n this._parcels = [...filtered, this._getTotalsRow(filtered)];\r\n } else {\r\n this._tiles = [...this._parcelsRepository];\r\n this._parcels = [...this._parcelsRepository, this._getTotalsRow(this._parcelsRepository)];\r\n }\r\n }\r\n\r\n private _initialize() {\r\n const parcels = this._incomingParcels.map(parcel => {\r\n return {\r\n ...parcel,\r\n ...{\r\n isTotalRow: false,\r\n returnCount: 1,\r\n originalConsolidatingTypeId: parcel.consolidatingTypeId,\r\n originalConsolidatedParcelId: parcel.consolidatedParcelId\r\n }\r\n } as ParcelListControlRow;\r\n }).sort((i1, i2) => {\r\n return i1.acctNum.localeCompare(i2.acctNum);\r\n });\r\n\r\n this._parcelsRepository = parcels;\r\n this._tiles = parcels;\r\n this._parcels = [\r\n ...parcels,\r\n this._getTotalsRow(parcels)\r\n ];\r\n }\r\n\r\n private _getTotalsRow(parcels: ParcelListControlRow[]): ParcelListControlRow {\r\n const totalComponents = {};\r\n parcels.forEach(p => {\r\n if (p.components && p.components.length) {\r\n p.components.forEach(c => {\r\n if (!totalComponents[c.componentName]) {\r\n totalComponents[c.componentName] = 0;\r\n }\r\n totalComponents[c.componentName] += c.fairMarketValue;\r\n });\r\n }\r\n });\r\n return {\r\n isFmvInclude: true,\r\n isTotalRow: true,\r\n returnCount: parcels.length,\r\n totalFMV: parcels.reduce(\r\n (acc: number, x: ParcelListControlRow) => (x.totalFMV && x.isFmvInclude) ? (acc += x.totalFMV) : acc,\r\n 0),\r\n totalTaxes: parcels.reduce(\r\n (acc: number, x: ParcelListControlRow) => (x.totalTaxes) ? (acc += x.totalTaxes) : acc,\r\n 0),\r\n totalComponents\r\n } as ParcelListControlRow;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, lastValueFrom, Observable } from 'rxjs';\r\nimport { ParcelRepository } from '../../Core-Repositories';\r\nimport { Site } from '../Site/Site.Model';\r\nimport { ParcelCollectorTaxAuthorities } from './Info/Tax-Rates/collectorTaxRateArea.component';\r\n\r\n@Injectable()\r\nexport class ParcelService {\r\n constructor(private readonly _parcelRepository: ParcelRepository) {}\r\n\r\n private _parcelCollectorTaxAuthoritiesSubject: BehaviorSubject = new BehaviorSubject([]);\r\n private _parcelCount: number;\r\n\r\n get parcelCount(): number {\r\n return this._parcelCount;\r\n }\r\n\r\n set parcelCount(parcelCount: number) {\r\n this._parcelCount = parcelCount;\r\n }\r\n\r\n get parcelCollectorTaxAuthorities$(): Observable {\r\n return this._parcelCollectorTaxAuthoritiesSubject.asObservable();\r\n }\r\n\r\n setParcelCollectorTaxAuthorities(parcelCollectorTaxAuthorities: ParcelCollectorTaxAuthorities[]): void {\r\n this._parcelCollectorTaxAuthoritiesSubject.next(parcelCollectorTaxAuthorities);\r\n }\r\n\r\n resolveView(result) {\r\n result.taxRateSetup.forEach((trs) => {\r\n const pc = result.parcel.parcelCollectors.find(x => x.parcelCollectorID === trs.parcelCollectorId);\r\n Object.assign(pc, trs);\r\n pc.hasTaxRateSetup = !!(trs.taxRateAreaName || trs.taxAuthorityCount > 0);\r\n pc.hasAvailableTaxSetup = trs.hasAvailableTaxSetup;\r\n });\r\n return result;\r\n }\r\n\r\n getView(parcelId: number, navigationRequest: boolean): Promise {\r\n return lastValueFrom(this._parcelRepository.getView(parcelId, navigationRequest)).then(result => this.resolveView(result));\r\n }\r\n\r\n get(callParams: any): Promise {\r\n return lastValueFrom(this._parcelRepository.get(callParams));\r\n }\r\n\r\n getAvailableYears(siteId: number): Promise {\r\n return lastValueFrom(this._parcelRepository.getAvailableYears(siteId));\r\n }\r\n\r\n getParcelLatestAssessmentYear(parcelId: number): Promise {\r\n return lastValueFrom(this._parcelRepository.getParcelLatestAssessmentYear(parcelId));\r\n }\r\n\r\n // yearValue will be 0 fo rthe most recent one\r\n //\r\n getParcelsInfoForSingleYear(siteId: number, yearValue: number) {\r\n return lastValueFrom(this._parcelRepository.getParcelsInfoForSingleYear(siteId, yearValue))\r\n .then(result => {\r\n // Hack to set the parcel count from angularjs.\r\n // Needed for site state readonly/edit logic\r\n this.parcelCount = result.length;\r\n return result;\r\n });\r\n }\r\n\r\n update(parcel: Weissman.Model.Domain.Parcel): Promise {\r\n return lastValueFrom(this._parcelRepository.update(parcel)).then(result => {\r\n return this.resolveView(result);\r\n });\r\n }\r\n\r\n post(parcel: Core.ParcelModel): Promise {\r\n return lastValueFrom(this._parcelRepository.post(parcel));\r\n }\r\n\r\n getNavigationInfo(parcelId: number): Promise {\r\n return lastValueFrom(this._parcelRepository.getNavigationInfo(parcelId));\r\n }\r\n\r\n getParcelLinkageTypes(): Promise {\r\n return lastValueFrom(this._parcelRepository.getParcelLinkageTypes());\r\n }\r\n\r\n getLinkedParcels(parcelId: number, includeUnlinked: boolean): Promise {\r\n return lastValueFrom(this._parcelRepository.getLinkedParcels(parcelId, includeUnlinked));\r\n }\r\n\r\n addNewLinks(payload: any): Promise {\r\n return lastValueFrom(this._parcelRepository.addNewLinks(payload));\r\n }\r\n\r\n updateLinks(payload: any): Promise {\r\n return lastValueFrom(this._parcelRepository.updateLinks(payload));\r\n }\r\n\r\n getParcelListBySiteId(siteId: number, excludeInactive: boolean): Promise {\r\n return lastValueFrom(this._parcelRepository.getParcelListBySiteId(siteId, excludeInactive));\r\n }\r\n\r\n getParcelYears(parcelId: number): Promise {\r\n return lastValueFrom(this._parcelRepository.getParcelYears(parcelId));\r\n }\r\n\r\n getOptimusLinkInfo(parcelId: number): Promise {\r\n return lastValueFrom(this._parcelRepository.getOptimusLinkInfo(parcelId));\r\n }\r\n\r\n bulkUpdate(bulkUpdateModel: Core.ParcelBulkUpdateModel): Promise {\r\n return lastValueFrom(this._parcelRepository.bulkUpdate(bulkUpdateModel));\r\n }\r\n\r\n getParcelAssessmentClasses(parcelId: number): Promise {\r\n return lastValueFrom(this._parcelRepository.getParcelAssessmentClasses(parcelId));\r\n }\r\n\r\n deleteParcel(parcelId: number): Promise {\r\n return lastValueFrom(this._parcelRepository.deleteParcel(parcelId));\r\n }\r\n\r\n getAcctNumberTypes(): Promise {\r\n return lastValueFrom(this._parcelRepository.getAcctNumberTypes());\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { IExpandableComponentContainer } from '../../UI-Lib/Expandable-Component/expandableComponentContainer.model';\r\nimport { IExpandableComponent } from '../../UI-Lib/Expandable-Component/expandableComponent.model';\r\nimport { Site, SiteSummary } from './Site.Model';\r\nimport { ParcelList, ParcelListControlRow } from './Models/parcelList';\r\nimport { ParcelService } from '../Parcel/parcel.service.upgrade';\r\nimport { BehaviorSubject, lastValueFrom, Observable } from 'rxjs';\r\nimport { SiteRepository } from '../../Core-Repositories';\r\n\r\n@Injectable()\r\nexport class SiteService implements IExpandableComponentContainer {\r\n constructor(\r\n private readonly _siteRepository: SiteRepository,\r\n private readonly _parcelService: ParcelService\r\n ) { }\r\n\r\n private _site: Site;\r\n private _latestTaxYearLabel: string = 'Latest';\r\n private _currentTaxYear: number = 0;\r\n private _expandedComponent: IExpandableComponent = null;\r\n private _parcelCount: number;\r\n private _stateId: number;\r\n\r\n private _parcelListSubject: BehaviorSubject = new BehaviorSubject(null);\r\n parcelList$: Observable = this._parcelListSubject.asObservable();\r\n\r\n private _siteSubject: BehaviorSubject = new BehaviorSubject(null);\r\n site$: Observable = this._siteSubject.asObservable();\r\n\r\n set site(site: Site) {\r\n this._site = site;\r\n this._siteSubject.next(site);\r\n }\r\n\r\n get site(): Site { return this._site; }\r\n\r\n memoryStorage = {\r\n siteClassSecondaryID: null,\r\n stateID: null\r\n };\r\n\r\n // AngularJS downgrade does not provide this as an instance service so a reset is required when leaving the page\r\n reset(): void {\r\n this.site = null;\r\n this._parcelListSubject.next(null);\r\n }\r\n\r\n setParcelCount(newCount: number): void {\r\n this._parcelCount = newCount;\r\n }\r\n\r\n getParcelCount(): number {\r\n if (!this._parcelCount) {\r\n this._parcelCount = this._parcelService.parcelCount;\r\n }\r\n return this._parcelCount;\r\n }\r\n\r\n setExpandedComponent(component: IExpandableComponent): void {\r\n this._expandedComponent = component;\r\n }\r\n\r\n isComponentExpanded(component: IExpandableComponent): boolean {\r\n return this._expandedComponent === component;\r\n }\r\n\r\n isExpanded(componentName: string): boolean {\r\n return this._expandedComponent && (this._expandedComponent.getName() === componentName);\r\n }\r\n\r\n isOtherComponentExpanded(componentName: string): boolean {\r\n return this._expandedComponent && (this._expandedComponent.getName() !== componentName);\r\n }\r\n\r\n post(parcel: Core.ParcelModel): Promise {\r\n return lastValueFrom(this._siteRepository.post(parcel));\r\n }\r\n\r\n async update(site, companyId): Promise {\r\n this.site = await lastValueFrom(this._siteRepository.update(site, companyId));\r\n return this.site;\r\n }\r\n\r\n getReportingParcelBySiteId(siteId: number): Promise {\r\n return lastValueFrom(this._siteRepository.getReportingParcelBySiteId(siteId));\r\n }\r\n\r\n async getNavigationInfo(siteId: number): Promise {\r\n return await lastValueFrom(this._siteRepository.getNavigationInfo(siteId));\r\n }\r\n\r\n hasParcels(): boolean {\r\n // If it hasn't been set, assume it has them. Prevents changing site state value when parcels are unknown\r\n return this._parcelCount > 0 || this._parcelCount === undefined;\r\n }\r\n\r\n async updateParcelList(year?: number | string): Promise {\r\n if (year) {\r\n this._currentTaxYear = (year === this._latestTaxYearLabel || !year) ? 0 : +year;\r\n }\r\n const parcels = await this._parcelService.getParcelsInfoForSingleYear(this.site.siteID, this._currentTaxYear);\r\n const parcelList = new ParcelList((parcels) ? parcels as Core.ParcelTileDTO[] : []);\r\n\r\n if (this._currentTaxYear === 0) {\r\n this._parcelCount = parcels.length;\r\n }\r\n\r\n // Check and set the reporting parcel\r\n const result = await this._setReportingParcel(parcelList);\r\n this._parcelListSubject.next(result);\r\n\r\n }\r\n\r\n private async _setReportingParcel(parcelList: ParcelList): Promise {\r\n // Need to ensure site exists before dereferencing.\r\n // If updateParcelList() is invoked, and the parcelListPanel is destroyed\r\n // (due to reload) before this method is called, site can be null.\r\n if (this.site && this.site.ppReturnPreparationAllowed) {\r\n const reportingParcel = await this.getReportingParcelBySiteId(this.site.siteID);\r\n if (reportingParcel) {\r\n const currentReportingParcel = parcelList.tiles.find(parcel => parcel.parcelID === reportingParcel.parcelID);\r\n if (currentReportingParcel) {\r\n currentReportingParcel.isReportingParcel = true;\r\n currentReportingParcel.originalIsReportingParcel = true;\r\n } else if (this.site.siteID !== reportingParcel.siteID) {\r\n const externalReportingParcel = this._getParcelControlRow(reportingParcel);\r\n parcelList.tiles.push(externalReportingParcel);\r\n parcelList.tiles.sort((i1, i2) => {\r\n return i1.acctNum.localeCompare(i2.acctNum);\r\n });\r\n }\r\n }\r\n }\r\n\r\n return parcelList;\r\n }\r\n\r\n private _getParcelControlRow(reportingParcel: Core.ParcelModel): ParcelListControlRow {\r\n return {\r\n acctNum: reportingParcel.acctNum,\r\n activityStatusID: reportingParcel.activityStatusID,\r\n address: null,\r\n altAcctNum: null,\r\n altParcel2: null,\r\n annualYear: null,\r\n assesseeName: null,\r\n assessorAbbr: null,\r\n calcProjected: null,\r\n companyID: null,\r\n components: null,\r\n description: reportingParcel.description,\r\n fmvChange: null,\r\n isFmvInclude: false,\r\n isLinked: false,\r\n isMasterParcel: false,\r\n parcelID: reportingParcel.parcelID,\r\n propTypeAbbr: 'PP',\r\n propertyTypeId: reportingParcel.propertyTypeID,\r\n siteID: reportingParcel.siteID,\r\n status: null,\r\n taxIsEstimated: false,\r\n taxPercentDiff: null,\r\n totalFMV: null,\r\n totalTaxes: null,\r\n isExternalReportingParcel: true,\r\n isReportingParcel: true,\r\n originalIsReportingParcel: true,\r\n consolidatedParcelId: null,\r\n originalConsolidatedParcelId: null,\r\n consolidatingTypeId: null,\r\n originalConsolidatingTypeId: null,\r\n isTotalRow: false,\r\n returnCount: 1\r\n } as ParcelListControlRow;\r\n }\r\n\r\n get(): Site {\r\n return this._site;\r\n }\r\n\r\n setStateId(newId: number): void {\r\n this._stateId = newId;\r\n }\r\n\r\n getStateId(): number {\r\n return this._stateId;\r\n }\r\n\r\n async load(siteId: number, companyId: number, noCache?: boolean, navigationRequest?: boolean): Promise {\r\n const site = await lastValueFrom(this._siteRepository.loadSite(siteId, companyId, navigationRequest));\r\n\r\n if (!noCache) {\r\n this._site = site;\r\n }\r\n\r\n return site;\r\n }\r\n\r\n getCompanyId(siteId: number): Promise {\r\n return lastValueFrom(this._siteRepository.getCompanyId(siteId));\r\n }\r\n\r\n getSiteName(siteId: number): Promise {\r\n return lastValueFrom(this._siteRepository.getSiteName(siteId));\r\n }\r\n\r\n loadByCompanyId(companyId: number): Promise {\r\n return lastValueFrom(this._siteRepository.loadByCompanyId(companyId));\r\n }\r\n\r\n getParcelIdsBySiteId(siteId: number): Promise {\r\n return lastValueFrom(this._siteRepository.getParcelIdsBySiteId(siteId));\r\n }\r\n\r\n updateSite(site: Site, companyId: number): Promise {\r\n return lastValueFrom(this._siteRepository.updateSite(site, companyId));\r\n }\r\n\r\n deleteSite(siteId: number): Promise {\r\n return lastValueFrom(this._siteRepository.deleteSite(siteId));\r\n }\r\n\r\n add(site: Site): Promise {\r\n return lastValueFrom(this._siteRepository.addSite(site));\r\n }\r\n\r\n getParcelsBySiteId(siteId: number): Promise {\r\n return lastValueFrom(this._siteRepository.getParcelsForSiteId(siteId));\r\n }\r\n\r\n getSiteListByCompanyId(companyId: number, excludeInactive: boolean): Promise {\r\n return lastValueFrom(this._siteRepository.getSiteListByCompanyId(companyId, excludeInactive));\r\n }\r\n\r\n searchSites(companyId: number, searchModel: Core.SiteSearchModel): Promise {\r\n return lastValueFrom(this._siteRepository.searchSites(companyId, searchModel));\r\n }\r\n}\r\n","\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { AfterViewInit, Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { SiteClassService } from '../../Site/siteClass.service';\r\nimport * as _ from 'lodash';\r\nimport { map, sortBy } from 'lodash/fp';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { SiteService } from '../../Site/Site.Service.upgrade';\r\nimport { Site } from '../../Site/Site.Model';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\n\r\nexport interface AddSiteModalParams {\r\n companyId: number;\r\n}\r\n\r\ninterface SiteClassUI extends Weissman.Model.Domain.SiteClassSecondary {\r\n fullName: string;\r\n}\r\n\r\n@Component({\r\n selector: 'add-site-modal',\r\n templateUrl: 'addSiteModal.component.html'\r\n})\r\n\r\nexport class AddSiteModalComponent implements OnInit, AfterViewInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _siteClassService: SiteClassService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _siteService: SiteService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _bsModalRef: BsModalRef\r\n ) { }\r\n\r\n @ViewChild('siteName') siteName: ElementRef;\r\n\r\n params: AddSiteModalParams;\r\n result: void;\r\n\r\n serverAction: boolean = false;\r\n addSiteForm: UntypedFormGroup;\r\n siteClasses: SiteClassUI[];\r\n\r\n async ngOnInit() {\r\n this.addSiteForm = this._fb.group({\r\n name: ['', Validators.required],\r\n siteNumber: [''],\r\n siteClassSecondaryID: [this._siteService.memoryStorage.siteClassSecondaryID, Validators.required],\r\n stateID: [this._siteService.memoryStorage.stateID, Validators.required]\r\n });\r\n\r\n this.serverAction = true;\r\n\r\n try {\r\n const siteClasses = await this._siteClassService.getSecondaries();\r\n this.siteClasses = _.flow([\r\n map((x: Weissman.Model.Domain.SiteClassSecondary) => {\r\n const fullName = `${x.siteClassPrimary.siteClassPrimaryDesc} - ${x.siteClassDesc}`;\r\n return {fullName, ...x};\r\n }),\r\n sortBy('fullName')\r\n ])(siteClasses);\r\n\r\n\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n setTimeout(() => {\r\n this.siteName.nativeElement.focus();\r\n });\r\n }\r\n\r\n async save(): Promise {\r\n const isSiteNameNonAscii = !(/^[ -~\\t\\n\\r]+$/.test(this.addSiteForm.controls.name.value));\r\n if (isSiteNameNonAscii) {\r\n this._toastr.error('Site Name contains invalid character(s)');\r\n return;\r\n }\r\n\r\n const siteToAdd = {\r\n siteID: 0,\r\n name: this.addSiteForm.value.name,\r\n\t\t\tcompanyID: this.params.companyId,\r\n property: this.addSiteForm.value.siteNumber,\r\n siteClassSecondaryID: this.addSiteForm.value.siteClassSecondaryID,\r\n\t\t\tactivityStatusID: 2, // should new site be active or inactive?\r\n\t\t\tdeleted: false,\r\n\t\t\taddress: {\r\n stateID: this.addSiteForm.value.stateID\r\n }\r\n };\r\n\r\n this.serverAction = true;\r\n\r\n try {\r\n const newSite = await this._siteService.add(siteToAdd as Site);\r\n\r\n this._siteService.memoryStorage = {\r\n siteClassSecondaryID: siteToAdd.siteClassSecondaryID,\r\n stateID: siteToAdd.address.stateID\r\n };\r\n\r\n this._upgradeNavigationServiceHandler.go('site', {\r\n siteId: newSite.siteID,\r\n companyId: newSite.companyID\r\n }, true);\r\n\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\n
\r\n\t
\r\n\t\t

Site and Parcel Exploration

\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t\t\t Processing...\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t
\r\n\t
\r\n\t
\r\n\t\t\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t

{{sitesTitle}}

\r\n\t\t\t\t
\r\n\t\t\t\t\t\r\n\t\t\t\t
\r\n\t\t\t
\r\n\r\n\t\t\t
\r\n\r\n\t\t\t\r\n\t\t
\r\n\t
\r\n
\r\n","import { Component, Inject, Input, OnInit } from '@angular/core';\r\nimport { UserSettingsService } from 'src/app/Account/userSettings.service';\r\nimport { RestrictData, RestrictService } from 'src/app/Common/Permissions/restrict.service';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { CompanyModel, CompanyService } from '../company.service';\r\nimport * as _ from 'lodash';\r\nimport { NavigationService } from 'src/app/Layout/navigation.service';\r\nimport { AddSiteModalComponent, AddSiteModalParams } from './addSiteModal.component';\r\nimport { WeissmanModalService } from 'src/app/Compliance/WeissmanModalService';\r\nimport { Settings } from 'src/app/User/account.service';\r\nimport { UserInstanceService } from 'src/app/User/userInstance.service';\r\n\r\n@Component({\r\n selector: 'company-exploration',\r\n templateUrl: 'companyExploration.component.html'\r\n})\r\n\r\nexport class CompanyExplorationComponent implements OnInit {\r\n constructor(@Inject('$rootScope') private _rootScope: any,\r\n private _userSettingsService: UserSettingsService,\r\n private _restrictService: RestrictService,\r\n private _nagivationService: NavigationService,\r\n private _modalService: WeissmanModalService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private _companyService: CompanyService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {\r\n }\r\n @Input() company: CompanyModel;\r\n\r\n hasWritePermission: boolean = false;\r\n activeOnly: boolean = true;\r\n serverAction: boolean = false;\r\n states: string[];\r\n refreshingSites: boolean;\r\n includeSubsidiarySites: boolean = false;\r\n isConsultantPerspective: boolean = false;\r\n\r\n private readonly _COMPANY_VIEW_USER_SETTINGS_GROUP = 23;\r\n private readonly _COMPANY_VIEW_USER_SETTINGS_NAME = 'Company-View-Settings';\r\n\r\n async ngOnInit() {\r\n this._retrieveUserSettings();\r\n\r\n this.serverAction = true;\r\n try {\r\n const dataPromises: [Promise, Promise] = [\r\n this._getWritePermission(),\r\n this._companyService.getStatesWithSites(this.company.companyID, this.activeOnly, this.includeSubsidiarySites)\r\n ];\r\n\r\n [this.hasWritePermission, this.states] = await Promise.all(dataPromises);\r\n\r\n this.isConsultantPerspective = this._userInstanceService.isCrossInstancePerspective(this.company.instanceID);\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n get sitesTitle(): string {\r\n const str = 'Sites by State';\r\n return this.activeOnly ? `Active ${str}` : str;\r\n }\r\n\r\n get isTopLevel(): boolean {\r\n return !this.company.parentId;\r\n }\r\n\r\n get companyHasSubsidiaries(): boolean {\r\n return this.company.childCompanies?.length > 0;\r\n }\r\n\r\n doQuickSearch(state: string): void {\r\n let includeSubsidiaryFlag: boolean = true;\r\n if (this.isTopLevel || this.companyHasSubsidiaries) {\r\n includeSubsidiaryFlag = this.includeSubsidiarySites;\r\n }\r\n this._productAnalyticsService.logEvent('click-state-tile');\r\n this._nagivationService.openQuickSearch(false, 'company-site');\r\n this._rootScope.$broadcast('quickSearch:getSitesForCompany', state, this.company, this.activeOnly, includeSubsidiaryFlag);\r\n }\r\n\r\n async addSite(): Promise {\r\n const params: AddSiteModalParams = { companyId: this.company.companyID };\r\n await this._modalService.showAsync(AddSiteModalComponent, params, 'modal-md');\r\n }\r\n\r\n async includeSubsidiarySitesChanged() {\r\n const companyViewSettings = this._userSettingsService.getSettingsByGroup(this._COMPANY_VIEW_USER_SETTINGS_GROUP);\r\n let settings = _.find(companyViewSettings, { name: this._COMPANY_VIEW_USER_SETTINGS_NAME });\r\n\r\n if (settings) {\r\n // Update user's settings.\r\n settings.value = { includeSubsidiarySites: this.includeSubsidiarySites };\r\n } else {\r\n // First time saving for user.\r\n settings = this._getNewUserSettings();\r\n }\r\n\r\n this._userSettingsService.save(settings);\r\n\r\n return this.getStatesWithSites();\r\n }\r\n\r\n async getStatesWithSites() {\r\n this.serverAction = true;\r\n try {\r\n this.states = await this._companyService.getStatesWithSites(this.company.companyID, this.activeOnly, this.includeSubsidiarySites);\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n private _retrieveUserSettings() {\r\n const companyViewSettings = this._userSettingsService.getSettingsByGroup(this._COMPANY_VIEW_USER_SETTINGS_GROUP);\r\n const settings = _.find(companyViewSettings, { name: this._COMPANY_VIEW_USER_SETTINGS_NAME });\r\n\r\n if (settings?.value) {\r\n const userSettings = _.clone(settings.value);\r\n this.includeSubsidiarySites = userSettings.includeSubsidiarySites === true;\r\n } else {\r\n // Save default for user when user doesn't have setting\r\n this._userSettingsService.save(this._getNewUserSettings());\r\n }\r\n }\r\n\r\n private _getNewUserSettings(): Settings {\r\n return {\r\n id: 0,\r\n name: this._COMPANY_VIEW_USER_SETTINGS_NAME,\r\n value: _.cloneDeep({ includeSubsidiarySites: this.includeSubsidiarySites }),\r\n groupId: this._COMPANY_VIEW_USER_SETTINGS_GROUP,\r\n groupName: this._COMPANY_VIEW_USER_SETTINGS_NAME,\r\n folderId: 20,\r\n folderName: this._COMPANY_VIEW_USER_SETTINGS_NAME\r\n };\r\n }\r\n\r\n private async _getWritePermission(): Promise {\r\n const restrictionData = {\r\n isCompany: true,\r\n entityId: this.company.companyID,\r\n flag: Core.AccessRightsEnum.Write,\r\n roles: []\r\n } as RestrictData;\r\n\r\n return this._restrictService.hasPermission(restrictionData);\r\n }\r\n}\r\n","\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { AfterViewInit, Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { UserInstanceService } from 'src/app/User/userInstance.service';\r\nimport { CompanyModel, CompanyService } from '../company.service';\r\n\r\nexport interface AddCompanyModalParams {\r\n parentCompany: any;\r\n}\r\n\r\n@Component({\r\n selector: 'add-company-modal',\r\n templateUrl: 'addCompanyModal.component.html'\r\n})\r\n\r\nexport class AddCompanyModalComponent implements OnInit, AfterViewInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _toastr: ToastrService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _bsModalRef: BsModalRef\r\n ) { }\r\n\r\n @ViewChild('companyName') companyName: ElementRef;\r\n\r\n params: AddCompanyModalParams;\r\n result: void;\r\n\r\n serverAction: boolean = false;\r\n addCompanyForm: UntypedFormGroup;\r\n entityIdScope: number;\r\n entityTypeScope: 'instance';\r\n\r\n async ngOnInit() {\r\n this.entityIdScope = this._userInstanceService.getSelectedInstance().instanceId;\r\n\r\n const companyCodeControl: any[] = [''];\r\n if (this.params.parentCompany?.ppReturnPreparationAllowed) {\r\n companyCodeControl.push(Validators.required);\r\n }\r\n\r\n this.addCompanyForm = this._fb.group({\r\n companyName: ['', Validators.required],\r\n companyCode: companyCodeControl,\r\n accountHandlerUserID: [null, Validators.required],\r\n accountHandlerTeamID: [null, Validators.required]\r\n });\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n setTimeout(() => {\r\n this.companyName.nativeElement.focus();\r\n });\r\n }\r\n\r\n accountHandlerSelected(newAccountHandler: Core.UserTeamModel) {\r\n this.addCompanyForm.controls.accountHandlerUserID.patchValue(newAccountHandler?.userID);\r\n this.addCompanyForm.controls.accountHandlerTeamID.patchValue(newAccountHandler?.teamID);\r\n\r\n this.addCompanyForm.controls.accountHandlerUserID.markAsTouched();\r\n }\r\n\r\n async save(): Promise {\r\n const isCompanyNameNonAscii = !(/^[ -~\\t\\n\\r]+$/.test(this.addCompanyForm.controls.companyName.value));\r\n if (isCompanyNameNonAscii) {\r\n this._toastr.error('Company Name contains invalid character(s)');\r\n return;\r\n }\r\n\r\n const companyToAdd = {\r\n activityStatusID: 2,\r\n invoiceAppealSavings: true\r\n } as CompanyModel;\r\n\r\n _.assign(companyToAdd, this.addCompanyForm.value);\r\n\r\n this.serverAction = true;\r\n\r\n try {\r\n const topLevelCompanyId = this.params.parentCompany ? this.params.parentCompany.topLevelCompanyId : null;\r\n const ppReturnPreparationAllowed = this.params.parentCompany ? this.params.parentCompany.ppReturnPreparationAllowed : false;\r\n\r\n const validationPromises = [\r\n this._companyService.isCompanyNameInUseAlready(companyToAdd.companyName, topLevelCompanyId, null),\r\n this._companyService.isCompanyCodeInUseAlready(companyToAdd.companyCode, topLevelCompanyId, null, ppReturnPreparationAllowed)\r\n ];\r\n\r\n const [isCompanyNameInUse, isCompanyCodeInUse] = await Promise.all(validationPromises);\r\n\r\n if(isCompanyNameInUse || isCompanyCodeInUse) {\r\n if(isCompanyNameInUse) {\r\n this._toastr.error('Company Name must be unique, please enter another value');\r\n }\r\n if(isCompanyCodeInUse) {\r\n this._toastr.error('Company Code must be unique, please enter another value');\r\n }\r\n\r\n return;\r\n }\r\n\r\n // TL Company Id msut be set to 0 when adding a TL Company.\r\n // TL Company Id must set to the parent Company if adding a Subsidiary.\r\n companyToAdd.topLevelCompanyId = 0;\r\n if (this.params.parentCompany) {\r\n // Adding a Subsidiary\r\n companyToAdd.topLevelCompanyId = this.params.parentCompany.topLevelCompanyId;\r\n companyToAdd.useTopLevelCompanyCOA = true;\r\n companyToAdd.enableAllocations = this.params.parentCompany.enableAllocations;\r\n }\r\n\r\n const newCompany = await this._companyService.create(companyToAdd);\r\n\r\n this._upgradeNavigationServiceHandler.go('company', {\r\n companyId: newCompany.companyID\r\n }, true);\r\n\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { WeissmanModalService } from 'src/app/Compliance/WeissmanModalService';\r\nimport { CompanyModel } from '../company.service';\r\nimport { AddCompanyModalParams, AddCompanyModalComponent } from './addCompanyModal.component';\r\n\r\n@Injectable()\r\nexport class LaunchAddCompanyModalService {\r\n constructor(private _modalService: WeissmanModalService) { }\r\n\r\n async addCompany(parentCompany?: CompanyModel): Promise {\r\n const params: AddCompanyModalParams = { parentCompany };\r\n return this._modalService.showAsync(AddCompanyModalComponent, params, 'modal-md');\r\n }\r\n}","
\r\n
\r\n

Company Info

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n\r\n
company.inactivatedDateTime\">\r\n
\r\n Activated by {{ company.activatedBy }}
\r\n Date: {{ company.activatedDateTime | date:'shortDate' }}\r\n
\r\n
\r\n Inactivated by {{ company.inactivatedBy }}
\r\n Date: {{ company.inactivatedDateTime | date:'shortDate' }}\r\n
\r\n
\r\n
\r\n
\r\n Inactivated by {{ company.inactivatedBy }}
\r\n Date: {{ company.inactivatedDateTime | date:'shortDate' }}\r\n
\r\n
\r\n Activated by {{ company.activatedBy }}
\r\n Date: {{ company.activatedDateTime | date:'shortDate' }}\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { CompanyModel, CompanyService } from '../company.service';\r\nimport * as _ from 'lodash';\r\nimport { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { CompanyEntity } from '../../entity.model';\r\nimport { RestrictData, RestrictService } from '../../../Common/Permissions/restrict.service';\r\nimport { TaskService } from '../../../Task/task.service.upgrade';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { UserInstanceService } from '../../../User/userInstance.service';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { Address } from '../../../Common/Models/common.model';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\nimport { ValidatorService } from '../../../UI-Lib/Utilities';\r\n\r\nexport interface ParentCompanyModel extends CompanyModel {\r\n noPermission: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'company-info-panel',\r\n templateUrl: 'companyInfoPanel.component.html',\r\n styles: [`\r\n .header-button-container button {\r\n margin-bottom: 0;\r\n }\r\n `]\r\n})\r\n\r\nexport class CompanyInfoPanelComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _restrictService: RestrictService,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _toastr: ToastrService,\r\n private readonly _taskService: TaskService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _validationService: ValidatorService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {\r\n }\r\n\r\n @Input() company: CompanyModel;\r\n @Input() entity: CompanyEntity;\r\n\r\n editMode: boolean = false;\r\n hasEditPermission: boolean = false;\r\n serverAction: boolean = false;\r\n parentCompany: ParentCompanyModel;\r\n infoForm: UntypedFormGroup = new UntypedFormGroup({});\r\n isIAMEnabled: boolean = false;\r\n editLocked: boolean;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n get isTopLevel(): boolean {\r\n return !this.company.parentId;\r\n }\r\n\r\n get defaultAddress(): Address {\r\n const defaultAddress = _.find(this.company.entityAddresses, 'isDefault');\r\n return defaultAddress?.address as unknown as Address;\r\n }\r\n\r\n get saveFunc() {\r\n return this.save.bind(this);\r\n }\r\n\r\n async ngOnInit() {\r\n const restrictionData = {\r\n isCompany: true,\r\n entityId: this.company.companyID,\r\n flag: Core.AccessRightsEnum.Write\r\n } as RestrictData;\r\n\r\n const permissionResult = this._restrictService.hasPermission(restrictionData);\r\n this.hasEditPermission = permissionResult && this.company.canEditCompany;\r\n this.isIAMEnabled = this._featureFlagsService.featureFlags.enableIAM;\r\n\r\n if (!this.isTopLevel) {\r\n this.parentCompany = await this._companyService.loadCompanyParent(this.company.companyID, this.company.parentId);\r\n }\r\n\r\n this._navigationService.globalEditMode$.pipe(takeUntil(this._destroy$)).subscribe(editMode => {\r\n this.editLocked = editMode;\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n\r\n edit(): void {\r\n const isImplicitAccess = !this._userInstanceService.isInstanceExplicit(this.company.instanceID);\r\n const companyCode = [this.company.companyCode] as any[];\r\n if (this.company.ppReturnPreparationAllowed) {\r\n companyCode.push(Validators.required);\r\n }\r\n this.infoForm = this._fb.group({\r\n companyName: [this.company.companyName, Validators.required],\r\n companyCode,\r\n activityStatusID: [{\r\n value: this.company.activityStatusID,\r\n disabled: this.company.isCustomer || isImplicitAccess\r\n }, Validators.required],\r\n url: [this.company.address.url],\r\n crmNumber: [this.company.crmNumber],\r\n iamTenantId: [this.company.iamTenantId],\r\n entityAddresses: [this.company.entityAddresses]\r\n });\r\n\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n this.editMode = true;\r\n this._productAnalyticsService.logEvent('edit-company-info');\r\n }\r\n\r\n cancel(): void {\r\n this._navigationService.disableNavWarning();\r\n this.editMode = false;\r\n }\r\n\r\n async save(): Promise {\r\n const isCompanyNameNonAscii = !(/^[ -~\\t\\n\\r]+$/.test(this.infoForm.value.companyName));\r\n if (isCompanyNameNonAscii) {\r\n this._toastr.error('Company Name contains invalid character(s)');\r\n return;\r\n }\r\n\r\n if (this.isIAMEnabled && this.infoForm.value.iamTenantId) {\r\n if (!this._validationService.isGuid(this.infoForm.value.iamTenantId)) {\r\n this._toastr.error('tax.com Tenant must have a valid UUID/GUID value');\r\n return;\r\n }\r\n }\r\n\r\n if (this.infoForm.controls['activityStatusID'].value !== this.company.activityStatusID) {\r\n if (this.infoForm.value.activityStatusID === Core.ActivityStatuses.Inactive) {\r\n const canBeDeactivatedResult = await this._taskService.checkIfEntityMayBeDeactivated(this.company.companyID, Core.EntityTypes.Company);\r\n\r\n if (canBeDeactivatedResult.canBeDeactivated) {\r\n try {\r\n let msg = 'Changing the company\\'s status to Inactive will result in all client service responsibilities being changed to N/A on the company and all of its subsidiaries, sites and parcels. ';\r\n msg += ` This will result in ${canBeDeactivatedResult.openFilingTaskCount} filing task(s) `;\r\n msg += ` and ${canBeDeactivatedResult.openAssessmentTaskCount} assessment task(s) `;\r\n msg += ` and ${canBeDeactivatedResult.openTaxBillTaskCount} tax bill task(s) to no longer be scheduled. `;\r\n msg += ' NO FURTHER WORK OF ANY KIND WILL BE SCHEDULED FOR THIS ENTITY. ';\r\n\r\n await this._messageModalService.confirm(msg, 'Are you sure you want to proceed?');\r\n this._saveToServer();\r\n\r\n } catch (e3) {\r\n this._resetActivityStatus();\r\n\r\n }\r\n } else {\r\n let message = '';\r\n if (canBeDeactivatedResult.openPaymentBatchTaskCount > 0) {\r\n message = 'This company\\'s status cannot be changed to Inactive because at least some of its batches have open payments.';\r\n } else {\r\n message = 'This company\\'s status cannot be changed to Inactive because at least some of its parcels have open appeals or refunds.';\r\n }\r\n\r\n try {\r\n await this._messageModalService.alert(message);\r\n } finally {\r\n this._resetActivityStatus();\r\n }\r\n\r\n }\r\n } else {\r\n if (this.company.activityStatusID !== Core.ActivityStatuses.Inactive) {\r\n try {\r\n await this._messageModalService.confirm('Changing the company\\'s status will cascade to all subsidiaries, sites and parcels.', 'Are you sure you want to proceed?');\r\n this._saveToServer();\r\n } catch {\r\n this._resetActivityStatus();\r\n\r\n }\r\n } else {\r\n this._saveToServer();\r\n }\r\n }\r\n } else {\r\n this._saveToServer();\r\n }\r\n }\r\n\r\n private async _saveToServer(): Promise {\r\n const companyToSave = _.cloneDeep(this.company);\r\n _.assign(companyToSave, _.omit(this.infoForm.value, 'url'));\r\n companyToSave.address.url = this.infoForm.value.url;\r\n\r\n this.serverAction = true;\r\n try {\r\n const savedCompany = await this._companyService.update(companyToSave);\r\n _.assign(this.company, savedCompany);\r\n\r\n this.entity.isInactive = this.company.activityStatusID === Core.ActivityStatuses.Inactive;\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n private _resetActivityStatus(): void {\r\n const { activityStatusID } = this.company;\r\n this.infoForm.patchValue({ activityStatusID });\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const COMPANY_INFO_PANEL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'company-info-panel.attachments',\r\n tooltipText: 'Attachments'\r\n },\r\n {\r\n helpContentId: 'company-info-panel.comments',\r\n tooltipText: 'Comments'\r\n },\r\n {\r\n helpContentId: 'company-info-panel.images',\r\n tooltipText: 'Images'\r\n },\r\n {\r\n helpContentId: 'company-info-panel.favorite',\r\n tooltipText: 'Favorite'\r\n }, \r\n]\r\n","
\r\n
\r\n
\r\n
\r\n \"Inactive\"\r\n\r\n

\r\n \r\n {{ company.companyName }}\r\n \r\n

\r\n

{{subHeader}}

\r\n
\r\n Company Code: {{company.companyCode}}\r\n
\r\n
\r\n
\r\n
\r\n

Additional Information:

\r\n
0\">\r\n Payment Packages\r\n
\r\n \r\n \r\n
\r\n Accruals\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n

External Connections

\r\n
\r\n CRM Number: {{company.crmNumber}}\r\n
\r\n
\r\n tax.com Tenant: {{company.iamTenantName}}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n\r\n \r\n\r\n","import { Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges, TemplateRef } from '@angular/core';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { CompanyModel, CompanyService } from '../company.service';\r\nimport * as _ from 'lodash';\r\nimport { Address } from 'src/app/Common/Models/common.model';\r\nimport {\r\n AddressDetailsModalLaunchService\r\n} from 'src/app/Common/Address/Address-View-Edit/address.details.modal.launch.service';\r\nimport { EntityTypeIds } from 'src/app/constants.new';\r\nimport { EntityAddress } from 'src/app/Common/Address/Address-View-Edit/address.model';\r\nimport { InstanceRights, RestrictData, RestrictService } from 'src/app/Common/Permissions/restrict.service';\r\nimport { CommentModalData } from 'src/app/Comments/comments.service';\r\nimport { AttachmentModalData } from 'src/app/Attachment/attachment.modal.model';\r\nimport { ParentCompanyModel } from './companyInfoPanel.component';\r\nimport { HelpService } from 'src/app/UI-Lib/Help-Tooltip';\r\nimport { COMPANY_INFO_PANEL_HELP } from './companyInfoPanel.component.help';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\nimport { UserInstanceService } from 'src/app/User/userInstance.service';\r\n\r\n@Component({\r\n selector: 'company-info-panel-view',\r\n templateUrl: 'companyInfoPanelView.component.html',\r\n styleUrls: ['companyInfoPanelView.component.scss']\r\n})\r\n\r\nexport class CompanyInfoPanelViewComponent implements OnInit, OnChanges {\r\n constructor(private readonly _addressDetailsModalLaunchService: AddressDetailsModalLaunchService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _helpService: HelpService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {\r\n this._helpService.setContent(COMPANY_INFO_PANEL_HELP);\r\n }\r\n\r\n @Input() company: CompanyModel;\r\n @Input() defaultAddress: Address;\r\n @Input() parentCompany: ParentCompanyModel;\r\n @Input() activatedByPopover: TemplateRef;\r\n @Output() serverActionChange: EventEmitter = new EventEmitter();\r\n\r\n addressPopoverOpened: boolean = false;\r\n numInactiveSubsidiaries: number = 0;\r\n subsidiaries: Weissman.Model.Domain.SubsidiaryCompanyDTO[];\r\n subHeader: string;\r\n showInactiveSubsidiaries: boolean = false;\r\n hasInstancePrivateViewPermission: boolean = false;\r\n hasInstancePrivateEditPermission: boolean = false;\r\n accrualsEnabled: boolean = false;\r\n hasWritePermission: boolean = false;\r\n isFavoriting: boolean = false;\r\n isIAMEnabled: boolean = false;\r\n analyticsCategory: string = 'company';\r\n\r\n get companyIsActive(): boolean {\r\n return this.company.activityStatusID === Core.ActivityStatuses.Active;\r\n }\r\n\r\n get inactiveUrl(): string {\r\n return this.company.activityStatusID === Core.ActivityStatuses.Inactive ? '/images/inactive.jpg' : '/images/active-pending.jpg';\r\n }\r\n\r\n get isTopLevel(): boolean {\r\n return !this.company.parentId;\r\n }\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.company) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: 'Company',\r\n entityName: this.company.companyName,\r\n entityData: {\r\n typeId: Core.EntityTypes.Company,\r\n id: this.company.companyID,\r\n name: this.company.companyName\r\n },\r\n readOnly: !this.hasWritePermission\r\n } as AttachmentModalData;\r\n }\r\n\r\n get commentsModel(): CommentModalData {\r\n if (!this.company) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityID: this.company.companyID,\r\n entityTypeID: Core.EntityTypes.Company,\r\n description: `Company: ${this.company.companyName}`,\r\n canEdit: this.hasWritePermission\r\n } as CommentModalData;\r\n }\r\n\r\n get isCompanyInRyanInstance(): boolean {\r\n return this.company.instanceID == this._userInstanceService.RyanInstanceId;\r\n }\r\n\r\n get isRyanInsanceSelected(): boolean {\r\n return this._userInstanceService.isCurrentInstanceRyan();\r\n }\r\n\r\n get shouldDisplayPaymentBatches(): boolean {\r\n return this._featureFlagsService.featureFlags.enablePaymentBatch\r\n && this.isTopLevel\r\n && this.isCompanyInRyanInstance\r\n && this.isRyanInsanceSelected\r\n && this.hasInstancePrivateEditPermission\r\n && this.hasWritePermission;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this.isIAMEnabled = this._featureFlagsService.featureFlags.enableIAM;\r\n }\r\n\r\n async ngOnChanges(changes: SimpleChanges): Promise {\r\n if (changes.company?.currentValue) {\r\n this.numInactiveSubsidiaries = this.company.childCompanies.length - this.company.childCompaniesNotInactive.length;\r\n this._setSubHeader();\r\n this._setSubsidiaries();\r\n\r\n if (changes.company.firstChange) {\r\n this.hasInstancePrivateViewPermission = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, this.company.instanceID)\r\n || this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW, this.company.instanceID);\r\n\r\n this.hasInstancePrivateEditPermission = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, this.company.instanceID);\r\n\r\n this.serverActionChange.emit(true);\r\n try {\r\n const restrictionData = {\r\n isCompany: true,\r\n entityId: this.company.companyID,\r\n roles: [],\r\n flag: Core.AccessRightsEnum.Write\r\n } as RestrictData;\r\n\r\n const dataPromises = [\r\n this._companyService.checkAccrualsEnabled(),\r\n this._restrictService.hasPermission(restrictionData)];\r\n\r\n [this.accrualsEnabled, this.hasWritePermission] = await Promise.all(dataPromises);\r\n } finally {\r\n this.serverActionChange.emit(false);\r\n }\r\n }\r\n }\r\n }\r\n\r\n launchAddressModal(): void {\r\n this._addressDetailsModalLaunchService.openAddressDetailsModal(\r\n this.company.companyID,\r\n EntityTypeIds.COMPANY,\r\n _.cloneDeep(this.company.entityAddresses) as unknown as EntityAddress[],\r\n false\r\n );\r\n }\r\n\r\n showInactiveSubsidiariesClicked(): void {\r\n this.showInactiveSubsidiaries = true;\r\n this._setSubsidiaries();\r\n }\r\n\r\n analyticsEvent(event: string): void {\r\n this._productAnalyticsService.logEvent(event);\r\n }\r\n\r\n async toggleFavorite(): Promise {\r\n this.isFavoriting = true;\r\n\r\n try {\r\n await this._companyService.setIsCompanyFavorite(this.company.companyID, !this.company.isFavorite);\r\n this.company.isFavorite = !this.company.isFavorite;\r\n } finally {\r\n this.isFavoriting = false;\r\n }\r\n }\r\n\r\n goToPBCC(): void {\r\n this.analyticsEvent('click-pmt-batches-link');\r\n sessionStorage['fromTlCompany'] = this.company.companyName;\r\n sessionStorage['pbccFilters'] = JSON.stringify({ tlCompanyIds: [this.company.topLevelCompanyId] });\r\n this._routerService.go('paymentBatchCommandCenter', null);\r\n }\r\n\r\n private _setSubHeader(): void {\r\n let subHeader = this.company.parentId ? 'Subsidiary; ' : 'Top Level; ';\r\n\r\n if (this.company.siteCount > 0) {\r\n subHeader += `${this.company.siteCount} site`;\r\n if (this.company.siteCount > 1) {\r\n subHeader += 's';\r\n }\r\n\r\n if (this.company.subCompSiteCount) {\r\n subHeader += ' plus ';\r\n }\r\n }\r\n if (this.company.subCompSiteCount) {\r\n subHeader += `${this.company.subCompSiteCount} subsidiary site`;\r\n if (this.company.subCompSiteCount > 1) {\r\n subHeader += 's';\r\n }\r\n }\r\n if (!this.company.siteCount && !this.company.subCompSiteCount) {\r\n subHeader += '0 sites';\r\n }\r\n\r\n this.subHeader = subHeader;\r\n }\r\n\r\n private _setSubsidiaries(): void {\r\n if (this.numInactiveSubsidiaries > 0 && !this.showInactiveSubsidiaries) {\r\n this.subsidiaries = this.company.childCompaniesNotInactive;\r\n } else {\r\n this.subsidiaries = this.company.childCompanies;\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n {{company.iamTenantName}}\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Input, TemplateRef, Output, EventEmitter } from '@angular/core';\r\nimport { UntypedFormGroup } from '@angular/forms';\r\nimport * as _ from 'lodash';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { LaunchAddCompanyModalService } from '../Add/launchAddCompanyModal.service';\r\nimport { CompanyModel, CompanyService } from '../company.service';\r\nimport { ParentCompanyModel } from './companyInfoPanel.component';\r\nimport { Address } from '../../../Common/Models/common.model';\r\nimport {\r\n AddressDetailsModalLaunchService\r\n} from '../../../Common/Address/Address-View-Edit/address.details.modal.launch.service';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { InstanceRights, RestrictService } from '../../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { EntityAddress } from '../../../Common/Address/Address-View-Edit/address.model';\r\nimport { MessageBoxButtons, MessageBoxResult, MessageBoxService } from 'src/app/UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\n\r\n@Component({\r\n selector: 'company-info-panel-edit',\r\n templateUrl: 'companyInfoPanelEdit.component.html'\r\n})\r\n\r\nexport class CompanyInfoPanelEditComponent implements OnInit {\r\n constructor(\r\n private readonly _addressDetailsModalLaunchService: AddressDetailsModalLaunchService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _launchAddCompanyModalService: LaunchAddCompanyModalService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _featureFlagsService: FeatureFlagsService) { }\r\n\r\n @Input() company: CompanyModel;\r\n @Input() defaultAddress: Address;\r\n @Input() parentCompany: ParentCompanyModel;\r\n @Input() infoForm: UntypedFormGroup;\r\n @Input() saveFunc: () => Promise;\r\n @Input() activatedByPopover: TemplateRef;\r\n @Output() serverActionChange: EventEmitter = new EventEmitter();\r\n\r\n showAddSubsidiary: boolean = false;\r\n statuses: {id: number; value: string}[];\r\n hasMoveCopyPermission: boolean = false;\r\n isIAMEnabled: boolean = false;\r\n\r\n private readonly _navWarning = 'Editing is in progress. Are you sure you want to leave?';\r\n\r\n get isTopLevel(): boolean {\r\n return !this.company.parentId;\r\n }\r\n\r\n get nonDeletedEntityAddresses(): Weissman.Model.Misc.EntityAddress[] {\r\n return _.reject(this.company.entityAddresses, {efAction: 'delete'});\r\n }\r\n\r\n async ngOnInit() {\r\n this.hasMoveCopyPermission = this._restrictService.hasInstanceRight(InstanceRights.ALLOWMOVECOPY, this.company.instanceID);\r\n this.isIAMEnabled = this._featureFlagsService.featureFlags.enableIAM;\r\n\r\n if(this.isTopLevel) {\r\n this.showAddSubsidiary = this._restrictService.hasInstanceRight(InstanceRights.ADDNEWCOMPANY, this.company.instanceID);\r\n }\r\n\r\n this.statuses = [{\r\n id: Core.ActivityStatuses.Active,\r\n value: 'Active'\r\n }, {\r\n id: Core.ActivityStatuses.ActivePending,\r\n value: 'Active (Pending)'\r\n }, {\r\n id: Core.ActivityStatuses.Inactive,\r\n value: 'Inactive'\r\n }];\r\n }\r\n\r\n async launchAddressDetailsModal(): Promise {\r\n this._navigationService.disableNavWarning();\r\n const entityAddresses = await this._addressDetailsModalLaunchService.openAddressDetailsModal(\r\n this.company.companyID,\r\n Core.EntityTypes.Company,\r\n _.cloneDeep(this.company.entityAddresses) as unknown as EntityAddress[],\r\n true\r\n );\r\n this.infoForm.patchValue({entityAddresses});\r\n\r\n this._navigationService.enableNavWarning(this._navWarning);\r\n }\r\n\r\n async addSubsidiary(): Promise {\r\n if(this.infoForm.dirty) {\r\n const result = await this._messageBoxService.open({\r\n message: 'There is unsaved data! Save before continuing?',\r\n buttons: MessageBoxButtons.YesNo\r\n }, true);\r\n\r\n if (result === MessageBoxResult.Yes) {\r\n await this.saveFunc();\r\n }\r\n }\r\n\r\n this._navigationService.disableNavWarning();\r\n await this._launchAddCompanyModalService.addCompany(this.company);\r\n }\r\n\r\n goToMoveCopy(isMove?: boolean): void {\r\n const state = isMove ? 'moveCompany' : 'copyCompany';\r\n\r\n this._upgradeNavigationServiceHandler.go(state, {\r\n companyID: this.company.companyID,\r\n isInactive: this.company.activityStatusID === Core.ActivityStatuses.Inactive\r\n });\r\n }\r\n\r\n async deleteCompany(): Promise {\r\n const result = await this._messageBoxService.open({\r\n message: 'Confirm Deleting Company',\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (result === MessageBoxResult.OK) {\r\n this.serverActionChange.emit(true);\r\n\r\n try {\r\n await this._companyService.deleteCompany(this.company.companyID);\r\n this._toastr.info('Company Deleted!');\r\n this._navigationService.disableNavWarning();\r\n this._upgradeNavigationServiceHandler.go('home', {});\r\n } finally {\r\n this.serverActionChange.emit(false);\r\n }\r\n }\r\n }\r\n}\r\n","import { EntityType, ClientServiceType, PropertyType as PropertyTypeType } from '../../constants.new';\r\n\r\nexport class HistoryResultWrapper {\r\n results: HistoryOperation[];\r\n}\r\n\r\nexport class HistoryOperation {\r\n historyId: number;\r\n operationDate: string;\r\n itemId: number;\r\n operation: OperationType;\r\n userId: string;\r\n userFirstName: string;\r\n userLastName: string;\r\n changes: HistoryChange[];\r\n expanded: boolean;\r\n}\r\n\r\nexport class HistoryChange {\r\n fieldName: string;\r\n oldValue: any;\r\n newValue: any;\r\n historyFieldType: number;\r\n // The actual type for property fields depends on the change type. If we want to get fancier later, we can maybe\r\n // make HistoryChange a generic class and use new types to represent what we expect to see in properties, but for\r\n // now this works OK.\r\n properties: any;\r\n newValueProperties: any;\r\n oldValueProperties: any;\r\n expanded?: boolean;\r\n}\r\n\r\nexport class CSRChangeProperties {\r\n clientServiceType: ClientServiceType;\r\n propertyType: PropertyTypeType;\r\n}\r\n\r\nexport class CSRChangeValueProperties {\r\n relatedEntityType: EntityType;\r\n relatedEntityName: string;\r\n isTopLevel: boolean;\r\n}\r\n\r\nexport class TaxAuthorityChangeProperties {\r\n taxAuthorityId: number;\r\n taxAuthorityName: string;\r\n taxAuthorityCode: string;\r\n}\r\n\r\nexport enum HistoryFieldType {\r\n Hidden = 1,\r\n String = 2,\r\n Number = 3,\r\n DateTime = 4,\r\n YesNo = 5,\r\n Descriptor = 6,\r\n Currency = 7,\r\n Value = 8,\r\n ActivityStatus = 9,\r\n Date = 10,\r\n PropertyType = 11,\r\n ClientServiceResponsibility = 12,\r\n TaxAuthority = 13\r\n}\r\n\r\nexport enum OperationType {\r\n Insert = 1,\r\n Update = 2,\r\n Delete = 3,\r\n Snapshot = 4,\r\n Unknown = 99\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Routing/sd-http.service';\r\nimport { HistoryResultWrapper, HistoryOperation } from './change-history.model';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class ChangeHistoryService {\r\n\r\n constructor(private http: SDHttpService) { }\r\n\r\n getChangeHistoryByEntity(id: number, entityTypeId: number, subType: string, startDateTime: Date, endDateTime: Date): Promise {\r\n const config = {\r\n params: {\r\n startDateTime: startDateTime,\r\n endDateTime: endDateTime\r\n }\r\n };\r\n\r\n let subTypeArg = '';\r\n if (subType) {\r\n subTypeArg = `/${ subType}`;\r\n }\r\n\r\n return this.http.get(`/api/history/entityType/${ entityTypeId }${subTypeArg }/entity/${ id}`, config).then((h: HistoryResultWrapper) => {\r\n return h.results;\r\n });\r\n }\r\n}\r\n","
\r\n

Change History

\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n to\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 3 && !operation.expanded\">\r\n \r\n \r\n \r\n \r\n
Date/Time *UserField NameOld ValueNew Value
\r\n {{calendarDisplayDate(operation.operationDate)}}\r\n \r\n {{operation.userFirstName}} {{operation.userLastName}}\r\n System Update\r\n {{originalTitle}} Created
(history not available before {{displayDate(operation.operationDate)}})
\r\n {{calendarDisplayDate(operation.operationDate)}}\r\n \r\n {{operation.userFirstName}} {{operation.userLastName}}\r\n System Update\r\n 2 && !operation.expanded\" style=\"white-space: nowrap;\">\r\n \r\n {{change.fieldName}}\r\n \r\n \r\n {{change.fieldName}}\r\n \r\n 2 && !operation.expanded\" style=\"word-break: break-word;\">\r\n blank\r\n \r\n \r\n \r\n \r\n {{getDisplayValue(change.oldValue, change.historyFieldType)}}\r\n \r\n \r\n (from {{resolveCSRRelationship(change.oldValueProperties)}})\r\n \r\n \r\n \r\n {{getDisplayValue(change.oldValue, change.historyFieldType)}}\r\n (details...)\r\n \r\n \r\n
{{getExpandedDisplayValue(change.oldValue, change.historyFieldType)}}
\r\n (hide...)\r\n
\r\n
\r\n
\r\n
2 && !operation.expanded\" style=\"text-align: center; padding: 0 10px; vertical-align: middle;\"> 2 && !operation.expanded\" style=\"word-break: break-word;\">\r\n blank\r\n \r\n \r\n \r\n \r\n {{getDisplayValue(change.newValue, change.historyFieldType)}}\r\n \r\n \r\n (from {{resolveCSRRelationship(change.newValueProperties)}})\r\n \r\n \r\n \r\n {{getDisplayValue(change.newValue, change.historyFieldType)}}\r\n (details...)\r\n \r\n \r\n
{{getExpandedDisplayValue(change.newValue, change.historyFieldType)}}
\r\n (hide...)\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
* All times CST
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ChangeHistoryService } from './change-history.service';\r\nimport { HistoryOperation, HistoryFieldType, OperationType, CSRChangeValueProperties, TaxAuthorityChangeProperties, HistoryChange } from './change-history.model';\r\nimport { EntityType, EmptyGuid } from '../../constants.new';\r\n// We tried importing this from bower_components, but there are two problems with that:\r\n// 1. This bloats the client library loading (since it has to load moment in two bundles)\r\n// 2. Moment-timezone isn't available (it doesn't have TypeScript definitions built in)\r\n// TODO: Import moment and moment-timezone from TypeScript and export it as a global for JavaScript to use\r\n//import * as moment from '../../../../bower_components/moment/moment';\r\ndeclare const moment: any;\r\n\r\nconst momentDateFormat: string = 'MM/DD/YYYY h:mm a';\r\n\r\n@Component({\r\n selector: 'change-history-modal',\r\n templateUrl: './change-history-modal.component.html'\r\n})\r\nexport class ChangeHistoryModalComponent implements OnInit {\r\n constructor(public bsModalRef: BsModalRef,\r\n private changeHistoryService: ChangeHistoryService) { }\r\n\r\n operations: HistoryOperation[];\r\n loading: boolean = false;\r\n NullUserId: string = EmptyGuid;\r\n HistoryFieldType = HistoryFieldType;\r\n ActivityStatus: string[] = ['Inactive', 'Active Pending', 'Active'];\r\n PropertyType: string[] = [null, 'Real Estate', 'Personal', 'Mineral', 'CentrallyAssessed'];\r\n id: number;\r\n entityTypeId: number;\r\n subType: string;\r\n title: string;\r\n startDateTime: Date = null; //moment().subtract(1, 'month').toDate();\r\n endDateTime: Date = null; //moment().toDate();\r\n OperationType = OperationType;\r\n originalTitle: string;\r\n originalTitlePresent: boolean;\r\n\r\n ngOnInit() {\r\n this.getHistory();\r\n }\r\n\r\n async getHistory(): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n const result = await this.changeHistoryService.getChangeHistoryByEntity(this.id, this.entityTypeId, this.subType, this.startDateTime, this.endDateTime);\r\n\r\n this.operations = result.map(r => {\r\n r.changes = r.changes.map(c => {\r\n if (c.historyFieldType === HistoryFieldType.TaxAuthority) {\r\n c.oldValue = this.deserializeTaxAuthorityValue(c.oldValue);\r\n c.newValue = this.deserializeTaxAuthorityValue(c.newValue);\r\n }\r\n else if(c.fieldName === 'Site Name' || c.fieldName === 'Parcel Acct Num') {\r\n this.originalTitlePresent = true;\r\n if(c.oldValue === null && c.newValue !== null) {\r\n this.originalTitle = c.newValue;\r\n }\r\n }\r\n\r\n return c;\r\n });\r\n return r;\r\n });\r\n if(this.originalTitlePresent && !this.originalTitle) {\r\n for(let i=result.length-1; i>=0; i--) {\r\n const tmpResult = result[i].changes.filter(r => (r.fieldName === 'Site Name' || r.fieldName === 'Parcel Acct Num')\r\n && (r.oldValue !==null && r.newValue !== null ));\r\n if(tmpResult && tmpResult.length > 0){\r\n this.originalTitle = tmpResult[0].oldValue;\r\n break;\r\n }\r\n }\r\n }\r\n if(!this.originalTitle) {\r\n this.originalTitle = this.title;\r\n }\r\n // HACK: Make a digest cycle fire (no idea why this isn't always happening anyway; see WK-6030)\r\n (window as any).$('.fa-spinner:visible').click();\r\n } finally {\r\n this.loading = false;\r\n }\r\n\r\n }\r\n\r\n calendarDisplayDate(date: string): string {\r\n // Central time\r\n return moment(date).tz('America/Chicago').calendar(null, {\r\n sameElse: momentDateFormat\r\n });\r\n }\r\n\r\n displayDate(date: string): string {\r\n return moment(date).tz('America/Chicago').format(momentDateFormat);\r\n }\r\n\r\n isCalendarDisplay(date: string): boolean {\r\n // Check if the calendarDisplayDate function produces the format string or something else (like \"moments ago\")\r\n return !moment(this.calendarDisplayDate(date), momentDateFormat).isValid();\r\n }\r\n\r\n getDisplayValue(value: any, historyFieldTypeId: number): string {\r\n switch(historyFieldTypeId) {\r\n case HistoryFieldType.ActivityStatus:\r\n return this.ActivityStatus[value];\r\n case HistoryFieldType.PropertyType:\r\n return this.PropertyType[value];\r\n case HistoryFieldType.TaxAuthority:\r\n const valueLength = (value).length;\r\n return valueLength === 1 ? '1 Tax Authority' : (`${valueLength } Tax Authorities`);\r\n default:\r\n return value;\r\n }\r\n }\r\n\r\n getExpandedDisplayValue(value: any, historyFieldTypeId: number): string {\r\n switch(historyFieldTypeId) {\r\n case HistoryFieldType.TaxAuthority:\r\n return (value).map(v => {\r\n if (v.taxAuthorityCode) {\r\n return `${v.taxAuthorityName} (${v.taxAuthorityCode})`;\r\n }\r\n return v.taxAuthorityName;\r\n }).join('\\n');\r\n default:\r\n return value;\r\n }\r\n }\r\n\r\n resolveCSRRelationship(csrProperties: CSRChangeValueProperties): string {\r\n if (csrProperties.relatedEntityType === EntityType.Site) {\r\n return 'site';\r\n }\r\n else if (csrProperties.relatedEntityType == EntityType.Company) {\r\n return csrProperties.isTopLevel ? 'top-level company' : 'company';\r\n }\r\n }\r\n\r\n closeModal(): void {\r\n this.bsModalRef.hide();\r\n }\r\n\r\n private deserializeTaxAuthorityValue(value: string): TaxAuthorityChangeProperties[] {\r\n if (value === null || value === undefined) {\r\n return null;\r\n }\r\n\r\n const parsed = <{\r\n TaxAuthorityId: number,\r\n TaxAuthorityName: string,\r\n TaxAuthorityCode: string\r\n }[]>JSON.parse(value);\r\n\r\n if (parsed.length === 0) {\r\n return null;\r\n }\r\n\r\n return parsed.map(p => {\r\n return {\r\n taxAuthorityId: p.TaxAuthorityId,\r\n taxAuthorityName: p.TaxAuthorityName,\r\n taxAuthorityCode: p.TaxAuthorityCode,\r\n };\r\n });\r\n }\r\n}","import { Injectable } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ChangeHistoryModalComponent } from './change-history-modal.component';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class ChangeHistoryModalLaunchService {\r\n constructor(private modalService: BsModalService) { }\r\n\r\n customTemplateModalRef: BsModalRef;\r\n\r\n openChangeHistoryModal(title: string, id: number, entityTypeId: number, subType: string) {\r\n const initialState = {\r\n title: title,\r\n id: id,\r\n entityTypeId: entityTypeId,\r\n subType: subType\r\n };\r\n\r\n this.modalService.show(ChangeHistoryModalComponent, {initialState, class: 'modal-change-history'});\r\n }\r\n}\r\n","\r\nexport abstract class PropertyTypeService {\r\n abstract get();\r\n abstract getById(id: number);\r\n}\r\n","import {UserTeamMember} from '../../Common/Models/common.model';\r\n\r\nexport class ClientServiceExceptionRequest {\r\n constructor(pEntityId: number, pEntityTypeId: number, pClientServiceIds: number[], pPropertyTypeIds: number[], pIncludeAll: boolean) {\r\n this.entityId = pEntityId;\r\n this.entityTypeId = pEntityTypeId;\r\n this.clientServiceIds = pClientServiceIds;\r\n this.propertyTypeIds = pPropertyTypeIds;\r\n this.includeAll = pIncludeAll;\r\n }\r\n\r\n entityId: number;\r\n entityTypeId: number;\r\n clientServiceIds: number[];\r\n propertyTypeIds: number[];\r\n includeAll: boolean;\r\n}\r\n\r\nexport class ClientServiceExceptionResponse {\r\n entityName: string;\r\n entityId: number;\r\n entityTypeId: number;\r\n parentEntityId: number;\r\n parentEntityTypeId: number;\r\n isTopLevel: boolean;\r\n entityResponsibilities: EntityResponsibility[];\r\n children: ChildEntityResponsibility[];\r\n}\r\n\r\nexport class EntityResponsibility {\r\n clientServiceId: number;\r\n clientServiceName: string;\r\n propertyTypeId: number;\r\n propertyTypeName: string;\r\n workflowUserTypeId: number;\r\n assignee: UserTeamMember;\r\n}\r\n\r\nexport class ChildEntityResponsibility extends EntityResponsibility{\r\n entityId: number;\r\n entityTypeId: number;\r\n companyId: number;\r\n companyName: string;\r\n siteId: number;\r\n siteName: string;\r\n parcelId: number;\r\n parcelAcctNum: string;\r\n state: string;\r\n hasExceptions: boolean;\r\n isSelected: boolean;\r\n consultingEngagementId: number;\r\n}\r\n\r\nexport class EntityResponsibilityAssignmentChange {\r\n constructor(entityId: number, entityTypeId: number, clientServiceId: number, propertyTypeId: number, workflowUserTypeId: number, dateFrom: Date, assignee: Core.UserTeamModel, consultingEngagementId?: number) {\r\n this.entityId = entityId;\r\n this.entityTypeId = entityTypeId;\r\n this.clientServiceId = clientServiceId;\r\n this.propertyTypeId = propertyTypeId;\r\n this.workflowUserTypeId = workflowUserTypeId;\r\n this.dateFrom = dateFrom;\r\n this.assignee = assignee;\r\n this.consultingEngagementId = consultingEngagementId;\r\n }\r\n\r\n entityId: number;\r\n entityTypeId: number;\r\n clientServiceId: number;\r\n propertyTypeId: number;\r\n workflowUserTypeId: number;\r\n dateFrom: Date;\r\n assignee: Core.UserTeamModel;\r\n consultingEngagementId?: number;\r\n}\r\n\r\nexport class BulkSaveExceptionResult {\r\n clientServiceId: number;\r\n entityId: number;\r\n entityTypeId: number;\r\n errorMessage: string;\r\n isAuthorized: boolean;\r\n isConcurrencyCheckFailed: boolean;\r\n propertyTypeId: number;\r\n warningMessage: string;\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport {SDHttpService} from '../../Common/Routing/sd-http.service';\r\nimport {\r\n ClientServiceExceptionRequest,\r\n ClientServiceExceptionResponse,\r\n EntityResponsibilityAssignmentChange,\r\n} from './client-service-exception.models';\r\n\r\n\r\n@Injectable()\r\nexport class ClientServicesExceptionService {\r\n\r\n constructor(private http: SDHttpService) { }\r\n\r\n\r\n getClientServiceExceptionsForEntity(exceptionInput: ClientServiceExceptionRequest): Promise {\r\n return this.http.post('/api/ClientServiceResponsibility/Exception/Search', exceptionInput);\r\n }\r\n\r\n saveClientServiceExceptions(updatedExceptions: EntityResponsibilityAssignmentChange[]): Promise {\r\n return this.http.put('/api/ClientServiceResponsibility/BulkExceptionSet', updatedExceptions);\r\n }\r\n}\r\n","
\r\n

Responsibility Setup Exceptions

\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n {{ clientServiceExceptions.entityName }}\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n

{{ clientServiceExceptions.entityName }} Info

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Client ServiceProperty TypeResponsibility
{{ responsibility.clientServiceName }}{{ responsibility.propertyTypeName }}{{ getAssigneeLabelForResponsibility(responsibility) }}
\r\n
\r\n
\r\n\r\n
\r\n
\r\n

Overrides (Exceptions)

\r\n \r\n \r\n Include All\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n 0 && selectedCount < clientServiceExceptions.children.length\"\r\n [checked]=\"selectedCount === clientServiceExceptions.children.length\"\r\n (click)=\"toggleAllResponsibilitySelections()\" />\r\n Company NameSite NameParcel NameStateClient ServiceResponsibility
\r\n \r\n \r\n \r\n {{ exception.companyName }}\r\n \r\n \r\n \r\n \r\n {{ exception.siteName }}\r\n \r\n \r\n --\r\n \r\n \r\n \r\n {{ exception.parcelAcctNum }}\r\n \r\n \r\n --\r\n \r\n {{ exception.state }}\r\n \r\n {{exception.clientServiceName}}\r\n \r\n \r\n {{ getAssigneeLabelForChildResponsibility(exception) }}\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n\r\n\r\n \r\n
\r\n \r\n
\r\n\r\n\t\r\n
\r\n \r\n
\r\n\r\n \r\n\t
\r\n\t\t\r\n \r\n\t\t
1\" class=\"consultant-selector\">\r\n\t\t\t\r\n\t\t
\r\n\t
\r\n\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n \r\n
\r\n \r\n
\r\n
\r\n\r\n","import {\r\n Component,\r\n OnInit,\r\n ViewChild\r\n} from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { ClientServicesExceptionService } from './client-services-exception.service';\r\nimport {\r\n ChildEntityResponsibility,\r\n ClientServiceExceptionRequest,\r\n ClientServiceExceptionResponse,\r\n EntityResponsibilityAssignmentChange,\r\n BulkSaveExceptionResult,\r\n EntityResponsibility\r\n} from './client-service-exception.models';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Constants, EntityType } from '../../constants.new';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { PopoverDirective } from 'ngx-bootstrap/popover';\r\nimport { InstanceRepository} from '../../Entity/Instance/instance.repository';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { ConsultingEngagementsRepository } from '../../Consulting/consultingEngagements.repository';\r\nimport { RestrictService, InstanceRights } from '../../Common/Permissions/restrict.service';\r\n\r\n@Component({\r\n selector: 'client-services-exception-modal',\r\n templateUrl: './client-service-exception.modal.html',\r\n styleUrls: ['./client-service-exception.modal.scss']\r\n})\r\nexport class ClientServicesExceptionModalComponent implements OnInit {\r\n constructor(\r\n public bsModalRef: BsModalRef,\r\n private clientServicesExceptionService: ClientServicesExceptionService,\r\n private constants: Constants,\r\n private NavigationService: UpgradeNavigationServiceHandler,\r\n private toastr: ToastrService,\r\n private instanceRepository: InstanceRepository,\r\n private userInstanceService : UserInstanceService,\r\n private consultingEngagementsRepository: ConsultingEngagementsRepository,\r\n private restrictService: RestrictService,\r\n ) { }\r\n\r\n @ViewChild('assignmentPopover') assignmentPopover: PopoverDirective;\r\n\r\n public entityId: number = 0;\r\n public entityTypeId: number = 0;\r\n public clientServiceIds: number[] = [];\r\n public propertyTypeIds: number[] = [];\r\n public isInactive: boolean = false;\r\n\r\n propertyTypes: any[];\r\n clientServicesTypes: any[];\r\n workflowUserTypes: any[];\r\n EntityTypes = EntityType;\r\n WorkflowUserTypes = this.constants.WorkflowUserTypes;\r\n updateUser: Core.UserTeamModel;\r\n updateWorkflowType: number;\r\n\r\n enableSaveButton: boolean = false;\r\n selectedCount: number = 0;\r\n isLoading: boolean = true;\r\n instanceId: number;\r\n includeAll: boolean = false;\r\n showDatePicker: boolean = false;\r\n setDateFrom: Date;\r\n showPopover: boolean = false;\r\n isRyanInstance: boolean = false;\r\n clientServiceExceptions: ClientServiceExceptionResponse;\r\n\r\n isCurrentInstanceRyan: boolean = false;\r\n consultingEngagements: Core.ConsultingEngagementResponse[] = [];\r\n consultantsEngagement: Core.ConsultingEngagementResponse = null;\r\n consultantsInstanceId: number = null;\r\n consultingEngagementId: number = null;\r\n CONSULTING_ENGAGEMENT = -1;\r\n isConsultantPerspective = false;\r\n canEditCompanySetup = false;\r\n assignmentSaved: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this.propertyTypes = _.toArray(this.constants.PropertyTypes);\r\n this.clientServicesTypes = _.toArray(this.constants.ClientServiceTypes);\r\n this.workflowUserTypes = _.toArray(this.constants.WorkflowUserTypes);\r\n this.isRyanInstance = this.userInstanceService.isCurrentInstanceRyan();\r\n }\r\n\r\n public initModal(): void {\r\n this.isLoading = true;\r\n this.selectedCount = 0;\r\n this.clientServiceExceptions = null;\r\n\r\n const exceptionInput: ClientServiceExceptionRequest = new ClientServiceExceptionRequest(\r\n this.entityId,\r\n this.entityTypeId,\r\n this.clientServiceIds,\r\n this.propertyTypeIds,\r\n this.includeAll\r\n );\r\n\r\n Promise.all([\r\n //csr exceptions for entity\r\n this.clientServicesExceptionService\r\n .getClientServiceExceptionsForEntity(exceptionInput)\r\n .then(response => {\r\n this.clientServiceExceptions = response;\r\n this.clientServiceExceptions.children = _.sortBy(this.clientServiceExceptions.children, ['companyName', 'siteName', 'parcelAcctNum']);\r\n }),\r\n //entity instance id\r\n lastValueFrom(this.instanceRepository.getEntityInstanceId(this.EntityTypes[this.entityTypeId], this.entityId)).then(i => {\r\n this.instanceId = i;\r\n if (i === 1) {\r\n this.isRyanInstance = true;\r\n }\r\n }),\r\n //consulting engagements for entity\r\n this.loadConsultingEngagements()\r\n ]).then(() => {\r\n this.isLoading = false;\r\n this.isConsultantPerspective = this.userInstanceService.isCrossInstancePerspective(this.instanceId);\r\n });\r\n\r\n this.canEditCompanySetup = this.restrictService.hasInstanceRight(InstanceRights.EDITCOMPANYSETUP);\r\n }\r\n\r\n changeConsultingEngagementFromSelect(eventTarget: EventTarget) {\r\n const consultingEngagementId = Number((eventTarget as HTMLSelectElement).selectedOptions[0].value);\r\n this.changeConsultingEngagement(consultingEngagementId);\r\n }\r\n\r\n changeConsultingEngagement(consultingEngagementId: number) {\r\n const ce = this.consultingEngagements.find(e => e.consultingEngagementId === consultingEngagementId);\r\n this.updateUser = {\r\n userID: ce.accountHandler.userId as string,\r\n teamID: ce.accountHandler.teamId,\r\n firstName: ce.accountHandler.firstName,\r\n lastName: ce.accountHandler.lastName,\r\n teamName: ce.accountHandler.teamName\r\n } as unknown as Core.UserTeamModel;\r\n\r\n this.consultingEngagementId = ce.consultingEngagementId;\r\n this.changeAssignmentSelection();\r\n }\r\n\r\n changeAssignmentSelection(){\r\n this.determineShowDatepicker();\r\n this.assignmentSaved = false;\r\n }\r\n\r\n isConsultingClient():boolean {\r\n return this.consultingEngagements.length && this.instanceId && !this.userInstanceService.isInstanceImplicit(this.instanceId);\r\n }\r\n\r\n propertyTypesChanged(eventTarget: EventTarget): void {\r\n // TODO: Why are we calling \".value\" here? Is selectedOptions not really a string[] type?\r\n this.propertyTypeIds = _.map((eventTarget as HTMLSelectElement).selectedOptions, (option: any) => Number(option.value)) as number[];\r\n }\r\n\r\n clientServicesChanged(eventTarget: EventTarget): void {\r\n this.clientServiceIds = _.map((eventTarget as HTMLSelectElement).selectedOptions, (option: any) => Number(option.value)) as number[];\r\n }\r\n\r\n getAssigneeLabelForChildResponsibility(exception: ChildEntityResponsibility ): string {\r\n if(exception.assignee && exception.workflowUserTypeId === this.constants.WorkflowUserTypes['USER'].id) {\r\n return `${exception.assignee.firstName } ${ exception.assignee.lastName } (${ exception.assignee.teamName })`;\r\n }\r\n else if(exception.consultingEngagementId) {\r\n return 'Consultant';\r\n }\r\n else {\r\n const userValue = _.find(this.workflowUserTypes, (user) => user.id === exception.workflowUserTypeId);\r\n return userValue ? userValue.name : '';\r\n }\r\n }\r\n\r\n getAssigneeLabelForResponsibility(exception: EntityResponsibility ): string {\r\n if(exception.assignee && exception.workflowUserTypeId === this.constants.WorkflowUserTypes['USER'].id) {\r\n return `${exception.assignee.firstName } ${ exception.assignee.lastName } (${ exception.assignee.teamName })`;\r\n }\r\n else {\r\n const userValue = _.find(this.workflowUserTypes, (user) => user.id === exception.workflowUserTypeId);\r\n return userValue ? userValue.name : '';\r\n }\r\n }\r\n\r\n changeEntityContext(entityId: number, entityTypeId: number): void {\r\n this.entityId = entityId;\r\n this.entityTypeId = entityTypeId;\r\n this.initModal();\r\n }\r\n\r\n toggleResponsibilitySelection(responsibility: ChildEntityResponsibility) {\r\n responsibility.isSelected = !responsibility.isSelected;\r\n this.selectedCount = _.filter(this.clientServiceExceptions.children, item => item.isSelected).length;\r\n\r\n this.enableSaveButton = this.selectedCount === 0 ? false : true;\r\n this.determineShowDatepicker();\r\n\r\n event.stopPropagation();\r\n }\r\n\r\n toggleAllResponsibilitySelections(): void {\r\n const updateValue = this.selectedCount !== this.clientServiceExceptions.children.length;\r\n\r\n this.clientServiceExceptions.children = _.map(this.clientServiceExceptions.children, (exception: ChildEntityResponsibility) => {\r\n exception.isSelected = updateValue;\r\n return exception;\r\n });\r\n\r\n this.selectedCount = _.filter(this.clientServiceExceptions.children, item => item.isSelected).length;\r\n\r\n this.enableSaveButton = this.selectedCount !== 0;\r\n this.determineShowDatepicker();\r\n }\r\n\r\n assignUserValue(): void {\r\n this.updateWorkflowType = this.WorkflowUserTypes['USER'].id;\r\n }\r\n\r\n async applyChanges(): Promise {\r\n const updatedExceptions: EntityResponsibilityAssignmentChange[] = new Array();\r\n const dateToSave = this.showDatePicker ? this.setDateFrom : null;\r\n const selectedExceptions = _.filter(this.clientServiceExceptions.children, { isSelected: true });\r\n\r\n //reset the consulting engagementId if final selection is not a CE or changes being made by a non-consultant\r\n if(this.updateWorkflowType !== this.CONSULTING_ENGAGEMENT && !this.isConsultantPerspective) {\r\n this.consultingEngagementId = null;\r\n }\r\n\r\n //if CE then mark workflow user type as direct User assignment\r\n if (this.updateWorkflowType === this.CONSULTING_ENGAGEMENT) {\r\n this.updateWorkflowType = this.WorkflowUserTypes['USER'].id;\r\n }\r\n\r\n const assignee = this.updateWorkflowType === this.WorkflowUserTypes['USER'].id ? this.updateUser : null;\r\n\r\n //if consultant selects account handler then need to set workflow user type to Consultant, otherwise leave it alone\r\n const workflowUserType = this.isConsultantPerspective && this.updateWorkflowType === this.WorkflowUserTypes['ACCOUNTHANDLER'].id ? this.WorkflowUserTypes['CONSULTANT'].id : this.updateWorkflowType;\r\n const enagagementId = this.isConsultantPerspective ? this.consultantsEngagement.consultingEngagementId : this.consultingEngagementId;\r\n\r\n\r\n _.forEach(selectedExceptions, (exception: ChildEntityResponsibility) => {\r\n const changeData = new EntityResponsibilityAssignmentChange(exception.entityId,\r\n exception.entityTypeId,\r\n exception.clientServiceId,\r\n exception.propertyTypeId,\r\n workflowUserType,\r\n dateToSave,\r\n assignee,\r\n enagagementId);\r\n\r\n updatedExceptions.push(changeData);\r\n });\r\n\r\n this.isLoading = true;\r\n try {\r\n const result = await this.clientServicesExceptionService.saveClientServiceExceptions(updatedExceptions);\r\n const bulkExceptionSetResponse = result.results;\r\n const areNotAuthorized = (x: BulkSaveExceptionResult) => !x?.isAuthorized;\r\n const haveErrors = (x: BulkSaveExceptionResult) => !!x?.errorMessage;\r\n\r\n if (_.every(bulkExceptionSetResponse, areNotAuthorized)) {\r\n this.toastr.error('You are not authorized to perform this operation');\r\n }\r\n else if (_.some(bulkExceptionSetResponse, areNotAuthorized)) {\r\n this.toastr.error('Some exceptions could not be saved because you are not authorized to perform this operation');\r\n }\r\n\r\n if (_.every(bulkExceptionSetResponse, haveErrors)) {\r\n this.toastr.error('There was an unexpected error processing your request');\r\n }\r\n else if (_.some(bulkExceptionSetResponse, haveErrors)) {\r\n this.toastr.error('Some exceptions could not be saved because there was an error processing your request');\r\n }\r\n\r\n this.setDateFrom = null;\r\n this.initModal();\r\n } catch(err) {\r\n this.isLoading = false;\r\n }\r\n\r\n this.assignmentSaved = true;\r\n }\r\n\r\n determineShowDatepicker(): void {\r\n const selectedExceptions: ChildEntityResponsibility[] = _.filter(this.clientServiceExceptions.children, { isSelected: true });\r\n const existingNA: boolean = _.some(selectedExceptions, { 'workflowUserTypeId': this.WorkflowUserTypes['NA'].id });\r\n\r\n if(existingNA && this.updateWorkflowType !== this.WorkflowUserTypes['NA'].id) {\r\n this.showDatePicker = true;\r\n } else {\r\n this.showDatePicker = false;\r\n this.setDateFrom = null;\r\n }\r\n }\r\n\r\n setUser($event: any): void {\r\n this.updateUser = $event;\r\n }\r\n\r\n navigateToEntity(exception: ChildEntityResponsibility, entityTypeId): void {\r\n switch (entityTypeId) {\r\n case EntityType.Company:\r\n this.NavigationService.go('company', {companyId: exception.companyId});\r\n break;\r\n case EntityType.Site:\r\n this.NavigationService.go('siteRedirect', {entityID: exception.siteId});\r\n break;\r\n case EntityType.Parcel:\r\n this.NavigationService.go('parcelRedirect', {entityID: exception.parcelId});\r\n }\r\n\r\n this.bsModalRef.hide();\r\n }\r\n\r\n //consultants are defined by implicit instance membership\r\n shouldUseConsultingEngagementInstanceId():boolean {\r\n return this.userInstanceService.isInstanceImplicit(this.instanceId);\r\n }\r\n\r\n private async loadConsultingEngagements() {\r\n this.consultingEngagements = await this.consultingEngagementsRepository.getAcceptedEngagements(this.entityTypeId, this.entityId);\r\n\r\n if(this.shouldUseConsultingEngagementInstanceId()) {\r\n this.consultantsEngagement = this.consultingEngagements.find(ce => this.userInstanceService.isInstanceExplicit(ce.instanceId));\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport {ClientServicesExceptionModalComponent} from './client-service-exception.modal';\r\n\r\n//This is a separate service because if it was in the normal exception service,\r\n//there's a circular dependency which causes DI to go berserk\r\n@Injectable()\r\nexport class ClientServicesExceptionModalService {\r\n constructor(private modalService: BsModalService) { }\r\n\r\n exceptionsModalRef: BsModalRef;\r\n\r\n openExceptionsModal(entityId: number, entityTypeId: number, clientServiceIds: number[], propertyTypeIds: number[], isInactive: boolean): void {\r\n this.exceptionsModalRef = this.modalService.show(ClientServicesExceptionModalComponent, {class: 'responsibility-exceptions modal-lg'});\r\n const modalComponent: ClientServicesExceptionModalComponent = this.exceptionsModalRef.content;\r\n modalComponent.entityId = entityId;\r\n modalComponent.entityTypeId = entityTypeId;\r\n modalComponent.clientServiceIds = clientServiceIds;\r\n modalComponent.propertyTypeIds = propertyTypeIds;\r\n modalComponent.isInactive = isInactive;\r\n modalComponent.initModal();\r\n }\r\n}","import { Injectable } from '@angular/core';\r\nimport { BaseRepository } from '../Common/Data/base.repository';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class TaxFeedSettingRepository extends BaseRepository {\r\n constructor(httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n private _pathPrefix = 'api/taxFeedSetting';\r\n\r\n getByEntity(entityId: number, entityType: Core.EntityTypes): Observable {\r\n return this.httpGet(`${this._pathPrefix}/${entityId}/${entityType}`);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BaseRepository } from '../../Common/Data/base.repository';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class DocumentIntakeLicensedClientDetailRepository extends BaseRepository {\r\n constructor(\r\n httpClient: HttpClient\r\n ) {\r\n super(httpClient);\r\n }\r\n\r\n private _pathPrefix = 'api/documentIntakeLicensedClientDetail';\r\n\r\n getList(): Observable {\r\n return this.httpGet(`${this._pathPrefix}/list`);\r\n }\r\n\r\n get(instanceId: number): Observable {\r\n return this.httpGet(`${this._pathPrefix}/${instanceId}`);\r\n }\r\n\r\n getDocumentGroupList(): Observable {\r\n return this.httpGet(`${this._pathPrefix}/documentGroups`);\r\n }\r\n\r\n updateSettings(clientDetail: Core.DocumentIntakeLicensedClientModel): Observable {\r\n return this.httpPut(`${this._pathPrefix}`, clientDetail);\r\n }\r\n\r\n getListAccepted(): Observable {\r\n return this.httpGet(`${this._pathPrefix}/listAccepted`);\r\n }\r\n\r\n getListAcceptedForDI(): Observable {\r\n return this.httpGet(`${this._pathPrefix}/listAcceptedForDI`);\r\n }\r\n}\r\n","import UserGroup = Weissman.Model.Authentication.UserGroup;\r\n\r\nexport abstract class UserGroupService {\r\n abstract isUserInGroup(groupName: string): Promise;\r\n abstract isUserSuperUser(): Promise;\r\n abstract getForMember(userId: string) : Promise;\r\n abstract getForSetup(contactId: number): Promise;\r\n}\r\n","
\r\n\tPrepare PP Returns:\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n\t
\r\n\t\t
{{userType.name}}:
\r\n
\r\n \r\n \r\n
\r\n
\r\n {{getDisplayName(currentData[userType.prefix + 'User'], currentData[userType.prefix + 'Team'])}}\r\n
\r\n\t
\r\n
\r\n","import { Component, OnInit, Input, Output, EventEmitter, OnChanges } from '@angular/core';\r\nimport { EntityClientService, ComplianceDeliveryDetail } from '../../clientServices.model';\r\nimport { EntityTypeIds, EmptyGuid } from 'src/app/constants.new';\r\nimport { RestrictService, InstanceRights } from 'src/app/Common/Permissions/restrict.service';\r\nimport * as _ from 'lodash';\r\nimport { CompanyEntity } from 'src/app/Entity/entity.model';\r\nimport { TeamService } from 'src/app/Team/team.service';\r\n\r\ninterface DRUserType {\r\n name: string;\r\n prefix: string;\r\n required: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'delivery-details-compliance-returns',\r\n templateUrl: './deliveryDetailsComplianceReturns.component.html'\r\n})\r\nexport class DeliveryDetailsComplianceReturnsComponent implements OnInit, OnChanges {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _teamService: TeamService\r\n ) {}\r\n\r\n @Input() editMode: boolean;\r\n @Input() entity: CompanyEntity;\r\n @Input() currentData: ComplianceDeliveryDetail;\r\n @Input() service: EntityClientService;\r\n @Input() ces: Core.ConsultingEngagementResponse[];\r\n @Input() entityInstanceId: number;\r\n @Input() isConsultantPerspective: boolean;\r\n @Input() userSearchInstanceId: number;\r\n\r\n @Output() currentDataChange: EventEmitter = new EventEmitter();\r\n\r\n readonly DR_USERS: DRUserType[] = [\r\n {\r\n name: 'Batch Data Loader',\r\n prefix: 'batchDataLoader',\r\n required: false\r\n },\r\n {\r\n name: 'Batch Data Preparer',\r\n prefix: 'batchPreparer',\r\n required: true\r\n },\r\n {\r\n name: 'Batch Data Reviewer',\r\n prefix: 'batchReviewer',\r\n required: true\r\n },\r\n {\r\n name: 'Batch Approver',\r\n prefix: 'batchApprover',\r\n required: false\r\n },\r\n {\r\n name: 'Batch Processor',\r\n prefix: 'batchProcessor',\r\n required: true\r\n }\r\n ];\r\n\r\n EntityTypeIds = EntityTypeIds;\r\n hasCompliancePermission: boolean = false;\r\n users: Core.UserTeamModel[] = null;\r\n\r\n ngOnInit() {\r\n this.hasCompliancePermission = this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, this.entityInstanceId);\r\n\r\n this.currentData = this.currentData || {} as ComplianceDeliveryDetail;\r\n\r\n if (this.entity.typeId !== this.EntityTypeIds.COMPANY) {\r\n this.currentData.ppReturnPreparationAllowed = this.currentData.ppReturnPreparationAllowed || false;\r\n }\r\n }\r\n\r\n async ngOnChanges() {\r\n if (this.editMode && !this.users) {\r\n this.users = await this._teamService.getAllAssignableUsers(false, false, this.entity.id, this.entity.type, this.userSearchInstanceId);\r\n }\r\n }\r\n\r\n maybePopulateBatchUsers(): void {\r\n // if switching from off to on\r\n // and ALL data is blank\r\n // and compliance returns reponsibility set to real user\r\n // copy existing single user to all 5 users\r\n\r\n const ppReturnPreparationAllowed = this.entity.typeId === EntityTypeIds.COMPANY ? this.entity.ppReturnPreparationAllowed : this.currentData.ppReturnPreparationAllowed;\r\n\r\n if (ppReturnPreparationAllowed && _.every(this.DR_USERS, this._isUserEmpty.bind(this))) {\r\n const personalResponsibility = _.find(this.service.responsibilities, {propertyTypeID: Core.PropertyTypes.Personal});\r\n\r\n if (!personalResponsibility.assignee || !personalResponsibility.team)\r\n return;\r\n\r\n _.forEach(this.DR_USERS, drUserType => {\r\n if (personalResponsibility) {\r\n this.currentData[`${drUserType.prefix }User`] = _.cloneDeep(personalResponsibility.assignee);\r\n this.currentData[`${drUserType.prefix }Team`] = _.cloneDeep(personalResponsibility.team);\r\n this.currentData[`${drUserType.prefix }UserId`] = personalResponsibility.userID;\r\n this.currentData[`${drUserType.prefix }TeamId`] = personalResponsibility.teamID;\r\n }\r\n else {\r\n this._removeUser(drUserType.prefix);\r\n }\r\n });\r\n\r\n this.currentDataChange.emit(this.currentData);\r\n }\r\n }\r\n\r\n userChanged(newUser: Core.UserTeamModel, userTypePrefix: string): void {\r\n if (!newUser) {\r\n this._removeUser(userTypePrefix);\r\n } else {\r\n this.currentData[`${userTypePrefix }UserId`] = newUser.userID;\r\n this.currentData[`${userTypePrefix }TeamId`] = newUser.teamID;\r\n\r\n this.currentData[`${userTypePrefix }Team`] = {\r\n name: newUser.teamName,\r\n teamID: newUser.teamID\r\n } as Weissman.Model.Workflow.Team;\r\n this.currentData[`${userTypePrefix }User`] = {\r\n efAction: null,\r\n firstName: newUser.firstName,\r\n lastName: newUser.lastName,\r\n userID: newUser.userID\r\n };\r\n }\r\n\r\n this.currentDataChange.emit(this.currentData);\r\n }\r\n\r\n getDisplayName(user: Core.ContactShortDTO, team: Weissman.Model.Workflow.Team): string {\r\n //consultant person assigned - show consulting company name if not consultant viewing\r\n if (team.instanceID !== this.entityInstanceId && this.isConsultantPerspective === false) {\r\n //look up consultant's name\r\n const consultantName = this.ces.find(ce => ce.instanceId === team.instanceID)?.name;\r\n return consultantName ? `Consultant- ${consultantName}` : '';\r\n }\r\n //client person assigned - show person's name\r\n else {\r\n return `${user.lastName}, ${user.firstName} (${team.name})`;\r\n }\r\n }\r\n\r\n private _removeUser(userTypePrefix: string): void {\r\n this.currentData[`${userTypePrefix }User`] = {};\r\n this.currentData[`${userTypePrefix }Team`] = {};\r\n\r\n if (userTypePrefix == 'batchDataLoader' || userTypePrefix == 'batchApprover') {\r\n this.currentData[`${userTypePrefix }UserId`] = null;\r\n this.currentData[`${userTypePrefix }TeamId`] = null;\r\n }\r\n else {\r\n this.currentData[`${userTypePrefix }UserId`] = 0;\r\n this.currentData[`${userTypePrefix }TeamId`] = 0;\r\n }\r\n }\r\n\r\n private _isUserEmpty(drUserType: DRUserType): boolean {\r\n if ((this.currentData[`${drUserType.prefix }UserId`]) && (this.currentData[`${drUserType.prefix }UserId`] != EmptyGuid))\r\n return false;\r\n if (this.currentData[`${drUserType.prefix }TeamId`])\r\n return false;\r\n if (!_.isEmpty(this.currentData[`${drUserType.prefix }User`]))\r\n return false;\r\n if (!_.isEmpty(this.currentData[`${drUserType.prefix }Team`]))\r\n return false;\r\n\r\n // all properties are empty\r\n return true;\r\n }\r\n}\r\n","
\r\n
\r\n DR Team Retrieves\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n TaxFeed:\r\n \r\n \r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { CompanyService } from 'src/app/Entity/Company/company.service';\r\nimport { DRTeamRetrievesDeliveryDetail } from '../../clientServices.model';\r\nimport { CompanyEntity } from 'src/app/Entity/entity.model';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\n\r\n@Component({\r\n selector: 'delivery-details-team-retrieves',\r\n templateUrl: './deliveryDetailsTeamRetrieves.component.html'\r\n})\r\nexport class DeliveryDetailsTeamRetrievesComponent implements OnInit{\r\n constructor(\r\n private readonly _companyService: CompanyService,\r\n private readonly _toasr: ToastrService,\r\n private readonly _featureFlagsService: FeatureFlagsService) { }\r\n\r\n @Input() editMode: boolean;\r\n @Input() topLevelData: DRTeamRetrievesDeliveryDetail;\r\n @Input() currentData: DRTeamRetrievesDeliveryDetail = {} as DRTeamRetrievesDeliveryDetail;\r\n @Input() entity: CompanyEntity;\r\n @Input() taxFeedIsEnabled: boolean;\r\n @Input() taxFeedEnablingMessage: string;\r\n @Input() taxFeedDisablingMessage: string;\r\n @Input() taxFeedToggleVisible: boolean;\r\n @Input() taxFeedToggleEnabled: boolean;\r\n @Input() isEntityInRyanInstance: boolean;\r\n\r\n @Output() currentDataChange: EventEmitter = new EventEmitter();\r\n\r\n @Output() taxFeedIsEnabledChange: EventEmitter = new EventEmitter();\r\n\r\n showTaxFeedToggle: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this.showTaxFeedToggle = this.taxFeedToggleVisible;\r\n }\r\n\r\n get isCompany(): boolean {\r\n return this.entity.type === 'company';\r\n }\r\n\r\n get isSubsidiary(): boolean {\r\n return this.isCompany && !this._companyService.isTopLevel();\r\n }\r\n\r\n useTopLevelChanged(): void {\r\n if (!this.currentData?.useTopLevelCompanySettings) {\r\n this.currentData.ownerEntityID = this.entity.id;\r\n }\r\n else {\r\n // This covers both Assessments and Tax bills using this one directive.\r\n _.assign(this.currentData, _.omit(this.topLevelData, 'useTopLevelCompanySettings', 'deliveryDetailAssessmentID', 'deliveryDetailsBillID'));\r\n }\r\n this.currentDataChange.emit(this.currentData);\r\n }\r\n\r\n taxFeedEnabledChanged(value) {\r\n this._toasr.success(value ? this.taxFeedEnablingMessage : this.taxFeedDisablingMessage);\r\n this.taxFeedIsEnabledChange.emit(value);\r\n }\r\n\r\n get taxFeedToggleDisabled(): boolean {\r\n return !this.editMode || !this.taxFeedToggleEnabled;\r\n }\r\n}\r\n","import { HelpContent } from 'src/app/UI-Lib/Help-Tooltip';\r\n\r\nexport const DELIVERY_DETAILS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'delivery-details.payment-batch-modal',\r\n tooltipText: 'Please select workflow and assign required tasks.',\r\n hasIcon: true\r\n }\r\n];\r\n","\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Data Hub Enabled:\r\n {{dataHubEnabled ? 'Yes' : 'No'}}\r\n
Workflow:\r\n \r\n
{{task.taskName}}:\r\n \r\n \r\n \r\n \r\n {{getDisplayName(currentData[prefixMap[task.taskTypeId] + 'User'], currentData[prefixMap[task.taskTypeId] + 'Team'])}}\r\n
","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { CompanyEntity } from 'src/app/Entity/entity.model';\r\nimport { HelpService } from 'src/app/UI-Lib/Help-Tooltip';\r\nimport { DELIVERY_DETAILS_HELP } from './deliveryDetails.help';\r\nimport { PaymentBatchService } from 'src/app/Payment-Batch/paymentBatch.service';\r\nimport { endsWith, find, isEmpty, mapValues } from 'lodash';\r\nimport { efAction } from 'src/app/constants.new';\r\nimport { TeamService } from 'src/app/Team/team.service';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\nexport type DeliveryDetailsPaymentBatchResult = [Weissman.Model.Domain.DeliveryDetailPaymentBatchDTOIn, Core.PaymentBatchDeliveryDetail];\r\n\r\n@Component({\r\n selector: 'payment-batch-workflow',\r\n templateUrl: './deliveryDetailsPaymentBatchWorkflow.component.html',\r\n styleUrls: ['./deliveryDetailsPaymentBatchWorkflow.component.scss']\r\n})\r\nexport class DeliveryDetailsPaymentBatchWorkflowComponent implements OnInit {\r\n constructor(\r\n private readonly _helpService: HelpService,\r\n private readonly _teamService: TeamService,\r\n private readonly _paymentBatchService: PaymentBatchService\r\n ) { }\r\n\r\n @Input() editMode: boolean;\r\n @Input() entity: CompanyEntity;\r\n @Input() userSearchInstanceId: number;\r\n @Input() currentPaymentBatchData: Core.PaymentBatchDeliveryDetail;\r\n @Input() dataHubEnabled: boolean;\r\n @Input() shouldDisplayDataHub: boolean;\r\n @Output() setEfAction: EventEmitter = new EventEmitter();\r\n @Output() setCurrentData: EventEmitter = new EventEmitter();\r\n @Output() setIsDirty: EventEmitter = new EventEmitter();\r\n // params: DeliveryDetailsPaymentBatchParams;\r\n // result: DeliveryDetailsPaymentBatchResult = [undefined, undefined] as DeliveryDetailsPaymentBatchResult;\r\n\r\n availableWorkflows: Core.PaymentBatchConfigModel[];\r\n selectedWorkflow: Core.PaymentBatchConfigModel;\r\n currentData: Core.PaymentBatchDeliveryDetail = {} as Core.PaymentBatchDeliveryDetail;\r\n parentUsers: Core.UserTeamModel[];\r\n\r\n readonly prefixMap: { [taskTypeId: number]: string; } = {\r\n 61: 'preparePreliminaryAPFeed',\r\n 62: 'reviewPreliminaryAPFeed',\r\n 64: 'requestFundingApproval',\r\n 65: 'prepareCheckFeed',\r\n 66: 'prepareFinalAPFeed',\r\n 67: 'confirmFunding',\r\n 68: 'reviewJurisProtocols',\r\n 69: 'printChecks',\r\n 70: 'mailChecks',\r\n 71: 'archiveChecks',\r\n 72: 'sendPaymentsToDataHub',\r\n 74: 'approvePayments'\r\n };\r\n\r\n loading: boolean = false;\r\n\r\n async ngOnInit() {\r\n this._helpService.setContent(DELIVERY_DETAILS_HELP);\r\n\r\n this.loading = true;\r\n\r\n try {\r\n this.availableWorkflows = await this._paymentBatchService.getAvailableWorkflows(this.entity.id);\r\n this.currentData = this.currentPaymentBatchData\r\n || await this._paymentBatchService.getDeliveryDetailPaymentBatch(this.entity.id)\r\n || {} as Core.PaymentBatchDeliveryDetail;\r\n\r\n this.setCurrentData.emit(this.currentData);\r\n\r\n this.selectedWorkflow = undefined;\r\n if(!isEmpty(this.currentData)) {\r\n this.selectedWorkflow = find(this.availableWorkflows, { paymentBatchTaskSeriesOptionId: this.currentData.paymentBatchTaskSeriesOptionId });\r\n }\r\n if (this.selectedWorkflow) {\r\n this.setEfAction.emit('update');\r\n } else {\r\n this.selectedWorkflow = this.availableWorkflows[0];\r\n this.workflowChanged();\r\n this.setEfAction.emit('add');\r\n }\r\n\r\n if (this.editMode) {\r\n this.parentUsers = await this._teamService.getAllAssignableUsers(false, false, this.entity.id, this.entity.type, this.userSearchInstanceId);\r\n }\r\n\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n userChanged(newUser: Core.UserTeamModel, userTypePrefix: string, isRequired: boolean): void {\r\n if (!newUser) {\r\n this._removeUser(userTypePrefix, isRequired);\r\n } else {\r\n this.currentData[`${userTypePrefix}UserId`] = newUser.userID;\r\n this.currentData[`${userTypePrefix}TeamId`] = newUser.teamID;\r\n\r\n this.currentData[`${userTypePrefix}Team`] = {\r\n name: newUser.teamName,\r\n teamID: newUser.teamID\r\n } as Weissman.Model.Workflow.Team;\r\n this.currentData[`${userTypePrefix}User`] = {\r\n efAction: null,\r\n firstName: newUser.firstName,\r\n lastName: newUser.lastName,\r\n userID: newUser.userID\r\n };\r\n }\r\n\r\n this.setCurrentData.emit(this.currentData);\r\n this.setIsDirty.emit(true);\r\n }\r\n\r\n getDisplayName(user: Core.ContactShortDTO, team: Weissman.Model.Workflow.Team): string {\r\n //consultant person assigned - show consulting company name if not consultant viewing\r\n // if (team.instanceID !== this.entityInstanceId && this.isConsultantPerspective === false) {\r\n // //look up consultant's name\r\n // const consultantName = this.ces.find(ce => ce.instanceId === team.instanceID)?.name;\r\n // return consultantName ? `Consultant- ${consultantName}` : '';\r\n // }\r\n //client person assigned - show person's name\r\n // else {\r\n return `${user.lastName}, ${user.firstName} (${team.name})`;\r\n // }\r\n }\r\n\r\n workflowChanged() {\r\n // this.currentData = mapValues(this.currentData, (val, key) => {\r\n // if(endsWith(key, 'UserId') || endsWith(key, 'TeamId')) {\r\n // return undefined;\r\n // } else {\r\n // return val;\r\n // }\r\n // }) as Core.PaymentBatchDeliveryDetail;\r\n\r\n this.currentData.paymentBatchTaskSeriesOptionId = this.selectedWorkflow.paymentBatchTaskSeriesOptionId;\r\n\r\n this.setCurrentData.emit(this.currentData);\r\n this.setIsDirty.emit(true);\r\n }\r\n\r\n private _removeUser(userTypePrefix: string, isRequired: boolean): void {\r\n this.currentData[`${userTypePrefix}User`] = {};\r\n this.currentData[`${userTypePrefix}Team`] = {};\r\n\r\n this.currentData[`${userTypePrefix}UserId`] = null;\r\n this.currentData[`${userTypePrefix}TeamId`] = null;\r\n }\r\n}","\r\n\r\n
\r\n
\r\n
\r\n
Client Abbreviation:
\r\n \r\n
\r\n
\r\n
Data Hub Enabled:
\r\n
{{dataHubEnabled ? 'Yes' : 'No'}}
\r\n
\r\n
\r\n
\r\n Click to Add Feed Specifications\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n
NameIncluded in EmailFeed Applicability
{{spec.feedSpecification.name}}\r\n
\r\n \r\n
\r\n
\r\n {{getFeedApplicability(spec)}}\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { ClientServiceResponsibilityService } from '../../clientServiceResponsibility.service';\r\nimport { DeliveryDetailFeedSpecification, FeedSpecification } from '../../clientServices.model';\r\nimport { CompanyEntity } from 'src/app/Entity/entity.model';\r\nimport { cloneDeep, reject, remove, some, sortBy } from 'lodash';\r\n\r\n@Component({\r\n selector: 'delivery-details-feed-specs',\r\n templateUrl: 'deliveryDetailsFeedSpecs.component.html'\r\n})\r\n\r\nexport class deliveryDetailsFeedSpecsComponent implements OnInit {\r\n constructor(\r\n private readonly _clientServicesService: ClientServiceResponsibilityService\r\n ) { }\r\n\r\n @Input() editMode: boolean;\r\n @Input() feedSpecifications: DeliveryDetailFeedSpecification[];\r\n @Input() clientAbbreviation: string;\r\n @Input() entity: CompanyEntity;\r\n @Input() isBillPay: boolean;\r\n @Input() dataHubEnabled: boolean;\r\n @Input() shouldDisplayDataHub: boolean;\r\n\r\n @Output() feedSpecificationsChange: EventEmitter = new EventEmitter();\r\n @Output() clientAbbreviationChange: EventEmitter = new EventEmitter();\r\n\r\n availableFeedSpecs: FeedSpecification[];\r\n hoveredSpecId: number;\r\n chosenSpec: FeedSpecification;\r\n disableSave: boolean = false;\r\n loading: boolean = false;\r\n\r\n async ngOnInit() {\r\n this.loading = true;\r\n\r\n try {\r\n const availableFeedSpecs = await this._clientServicesService.getAvailableFeedSpecs(this.entity.typeId, this.entity.id);\r\n this.availableFeedSpecs = reject(availableFeedSpecs, spec => {\r\n return some(this.feedSpecifications, { feedSpecificationID: spec.feedSpecificationID });\r\n });\r\n\r\n this._sortAvailableFeedSpecs();\r\n\r\n if (this.isBillPay)\r\n {\r\n if (this.feedSpecifications.length < 1)\r\n this.disableSave = true;\r\n }\r\n\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n getFeedApplicability(spec: DeliveryDetailFeedSpecification): string {\r\n let feedApplicability: string = '';\r\n\r\n if (spec.feedSpecification.apFeed) {\r\n feedApplicability += 'AP';\r\n }\r\n\r\n if (spec.feedSpecification.checkFeed) {\r\n if (feedApplicability !== '') {\r\n feedApplicability += ', ';\r\n }\r\n feedApplicability += 'Check';\r\n }\r\n\r\n if (this.shouldDisplayDataHub &&\r\n this.dataHubEnabled &&\r\n spec.feedSpecification.dataHub) {\r\n if (feedApplicability !== '') {\r\n feedApplicability += ', ';\r\n }\r\n feedApplicability += 'Data Hub';\r\n }\r\n\r\n return feedApplicability;\r\n }\r\n\r\n addSpec(): void {\r\n const specToadd = {\r\n feedSpecification: cloneDeep(this.chosenSpec),\r\n feedSpecificationID: this.chosenSpec.feedSpecificationID,\r\n includedInEmail: false,\r\n } as DeliveryDetailFeedSpecification;\r\n\r\n this.feedSpecifications.push(specToadd);\r\n this.feedSpecificationsChange.emit(this.feedSpecifications);\r\n remove(this.availableFeedSpecs, this.chosenSpec);\r\n this.disableSave = false;\r\n\r\n setTimeout(() => {\r\n this.chosenSpec = undefined;\r\n });\r\n }\r\n\r\n removeSpec(spec: DeliveryDetailFeedSpecification) : void{\r\n this.availableFeedSpecs.push(spec.feedSpecification);\r\n this._sortAvailableFeedSpecs();\r\n\r\n remove(this.feedSpecifications, spec);\r\n this.feedSpecificationsChange.emit(this.feedSpecifications);\r\n\r\n if (this.isBillPay) {\r\n if (this.feedSpecifications.length < 1)\r\n this.disableSave = true;\r\n }\r\n }\r\n\r\n private _sortAvailableFeedSpecs() {\r\n this.availableFeedSpecs = sortBy(this.availableFeedSpecs, 'name');\r\n }\r\n}","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { DeliveryDetailFeedSpecification } from '../../clientServices.model';\r\nimport { CompanyEntity } from 'src/app/Entity/entity.model';\r\nimport { endsWith, omitBy } from 'lodash';\r\nimport { RyanInstanceId } from 'src/app/constants.new';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\nexport interface DeliveryDetailsConfigureParams {\r\n editMode: boolean;\r\n feedSpecifications: DeliveryDetailFeedSpecification[];\r\n clientAbbreviation: string;\r\n entity: CompanyEntity;\r\n isBillPay: boolean;\r\n userSearchInstanceId: number;\r\n currentPaymentBatchData: Core.PaymentBatchDeliveryDetail\r\n isTopLevelCompany: boolean;\r\n dataHubEnabled: boolean;\r\n isEntityInRyanInstance: boolean;\r\n}\r\n\r\ninterface DeliveryDetailsFeedSpecResult {\r\n clientAbbreviation: string;\r\n feedSpecifications: DeliveryDetailFeedSpecification[];\r\n}\r\n\r\ntype DeliveryDetailsPaymentBatchResult = [Weissman.Model.Domain.DeliveryDetailPaymentBatchDTOIn, Core.PaymentBatchDeliveryDetail];\r\n\r\nexport interface DeliveryDetailsConfigureResult {\r\n feedSpecResult?: DeliveryDetailsFeedSpecResult;\r\n paymentBatchResult?: DeliveryDetailsPaymentBatchResult\r\n}\r\n\r\n@Component({\r\n selector: 'delivery-details-configure-modal',\r\n templateUrl: './deliveryDetailsConfigureModal.component.html'\r\n})\r\nexport class DeliveryDetailsConfigureModalComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _featureFlagService: FeatureFlagsService\r\n ) { }\r\n\r\n params: DeliveryDetailsConfigureParams;\r\n result: DeliveryDetailsConfigureResult;\r\n\r\n paymentBatchData = {\r\n efAction: 'add',\r\n currentData: {} as Core.PaymentBatchDeliveryDetail,\r\n isDirty: false\r\n };\r\n\r\n get shouldDisplayPaymentBatch() {\r\n return this.params.userSearchInstanceId === RyanInstanceId \r\n && this.params.isBillPay\r\n && this.params.isTopLevelCompany\r\n }\r\n\r\n get shouldDisplayDataHub() {\r\n return this.params.isTopLevelCompany && this._featureFlagService.featureFlags.enablePaymentBatchDataHub && this.params.isEntityInRyanInstance\r\n }\r\n\r\n get isSaveDisabled() {\r\n return this.params.isBillPay && this.params.feedSpecifications.length === 0;\r\n }\r\n\r\n save() {\r\n let paymentBatchResult;\r\n\r\n const feedSpecResult = {\r\n feedSpecifications: this.params.feedSpecifications,\r\n clientAbbreviation: this.params.clientAbbreviation\r\n };\r\n\r\n if(this.paymentBatchData.isDirty) {\r\n const idsOnly = omitBy(this.paymentBatchData.currentData, (val, key) => {\r\n return endsWith(key, 'User') || endsWith(key, 'Team');\r\n });\r\n paymentBatchResult = [{\r\n ...idsOnly,\r\n efAction: this.paymentBatchData.efAction,\r\n ownerEntityID: this.params.entity.id,\r\n paymentBatchTaskSeriesOptionId: this.paymentBatchData.currentData.paymentBatchTaskSeriesOptionId\r\n } as Weissman.Model.Domain.DeliveryDetailPaymentBatchDTOIn,\r\n this.paymentBatchData.currentData];\r\n }\r\n\r\n this.result = {feedSpecResult, paymentBatchResult};\r\n this.close();\r\n }\r\n\r\n close() {\r\n this._bsModalRef.hide();\r\n }\r\n}","
\r\n

Custom Email Template

\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { CustomeEmailTemplateService } from './custom-email-template.service';\r\nimport {PackageEmailTemplate} from '../../Processing/Transmittal/transmittal.models';\r\nimport { TimerService } from '../../UI-Lib/Utilities/timer.service';\r\n\r\ndeclare const $: any;\r\n\r\n@Component({\r\n selector: 'custom-email-template-modal',\r\n templateUrl: './custom-email-template-modal.component.html'\r\n})\r\nexport class CustomEmailTemplateModalComponent implements OnInit {\r\n constructor(public bsModalRef: BsModalRef,\r\n private readonly _customEmailTemplateService: CustomeEmailTemplateService,\r\n private readonly _timer: TimerService) { }\r\n\r\n onClose: any;\r\n template: any;\r\n packageEmailTemplates: PackageEmailTemplate[];\r\n selectedEmailTemplate: PackageEmailTemplate;\r\n emailTemplateFields: any = {};\r\n editorInstance: any;\r\n\r\n\r\n ngOnInit() {\r\n this._customEmailTemplateService.getEmailTemplateFields()\r\n .then((result) => {\r\n const sortedResults = _.sortBy(result, 'name');\r\n\r\n this.emailTemplateFields.body = sortedResults;\r\n this.emailTemplateFields.subject = _.filter(sortedResults, 'validInSubject');\r\n });\r\n\r\n this._timer.setTimeout(() => {\r\n $('#custom-template-subject').focus();\r\n });\r\n }\r\n\r\n addBindingCreated(quillInstance): void {\r\n this.editorInstance = quillInstance;\r\n }\r\n\r\n insertFieldInBody(field): void {\r\n const cursorPosition: number = this.editorInstance.getSelection(true).index;\r\n const fieldName: string = `{{ ${ field.name } }}`;\r\n\r\n this.editorInstance.insertText(cursorPosition, fieldName);\r\n }\r\n\r\n // http://jsfiddle.net/4abr7jc5/2/\r\n insertFieldInSubject(field): void {\r\n const cursorPosStart = $('#custom-template-subject').prop('selectionStart');\r\n const cursorPosEnd = $('#custom-template-subject').prop('selectionEnd');\r\n const v = $('#custom-template-subject').val();\r\n const textBefore = v.substring(0, cursorPosStart);\r\n const textAfter = v.substring(cursorPosEnd, v.length);\r\n const fieldName = `{{ ${ field.name } }}`;\r\n\r\n $('#custom-template-subject').val(textBefore + fieldName + textAfter);\r\n this.template.packageEmailCustomTemplateSubject = $('#custom-template-subject').val();\r\n\r\n $('#custom-template-subject').focus();\r\n }\r\n\r\n baseTemplateChange(event): void {\r\n const oldSelectedTemplate: PackageEmailTemplate = _.cloneDeep(this.selectedEmailTemplate);\r\n\r\n if (this.template.packageEmailCustomTemplateBody || this.template.packageEmailCustomTemplateSubject) {\r\n if (confirm('Changing the base template will overwrite any current values. Do you wish to continue?')) {\r\n this.selectedEmailTemplate = event;\r\n this.copySelectedTemplateFields();\r\n } else {\r\n this.selectedEmailTemplate = _.cloneDeep(oldSelectedTemplate);\r\n }\r\n } else {\r\n this.selectedEmailTemplate = event;\r\n this.copySelectedTemplateFields();\r\n }\r\n }\r\n\r\n copySelectedTemplateFields(): void {\r\n this.template.packageEmailCustomTemplateSubject = this.selectedEmailTemplate.subjectTemplate;\r\n this.template.packageEmailCustomTemplateBody = this.selectedEmailTemplate.bodyTemplate;\r\n }\r\n\r\n closeModal(template?): void {\r\n this.onClose(template);\r\n this.bsModalRef.hide();\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport {PackageEmailTemplate} from '../../Processing/Transmittal/transmittal.models';\r\n\r\n\r\ndeclare const $: any;\r\n\r\n@Component({\r\n selector: 'custom-email-template-modal',\r\n templateUrl: './preview-email-template-modal.component.html'\r\n})\r\nexport class PreviewEmailTemplateModalComponent implements OnInit {\r\n constructor(public modalRef: BsModalRef) {}\r\n\r\n template: PackageEmailTemplate;\r\n modules: any;\r\n\r\n ngOnInit() {\r\n this.modules = {\r\n toolbar: false\r\n };\r\n }\r\n}","
\r\n

{{ template.name }} Template

\r\n
\r\n
\r\n \r\n
{{ template.subjectTemplate }}
\r\n\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Routing/sd-http.service';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { CustomEmailTemplateModalComponent } from './custom-email-template-modal.component';\r\nimport {PreviewEmailTemplateModalComponent} from './preview-email-template-modal.component';\r\nimport * as _ from 'lodash';\r\nimport {PackageEmailTemplate} from '../../Processing/Transmittal/transmittal.models';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class LaunchEmailTemplateModalService {\r\n constructor(private http: SDHttpService,\r\n private modalService: BsModalService) { }\r\n\r\n customTemplateModalRef: BsModalRef;\r\n\r\n openCustomTemplateModal(onCloseFn, templateSubject, templateBody, packageEmailTemplates) {\r\n const filteredPackageEmailTemplates: PackageEmailTemplate[] =\r\n _.filter(packageEmailTemplates, function(item: PackageEmailTemplate) { return item.name != 'Custom'; });\r\n\r\n const initialState = {\r\n template: {\r\n packageEmailCustomTemplateSubject: templateSubject,\r\n packageEmailCustomTemplateBody: templateBody\r\n },\r\n packageEmailTemplates: filteredPackageEmailTemplates,\r\n onClose: onCloseFn\r\n };\r\n\r\n this.modalService.show(CustomEmailTemplateModalComponent, { initialState, class: 'modal-lg' });\r\n }\r\n\r\n openPreviewTemplateModal(template) {\r\n const initialState = {\r\n template: template\r\n };\r\n\r\n this.modalService.show(PreviewEmailTemplateModalComponent, { initialState, class: 'modal-lg' });\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { Observable, of as observableOf } from 'rxjs';\r\nimport { mergeMap } from 'rxjs/operators';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\n\r\n@Component({\r\n selector: 'site-descriptor-selector',\r\n templateUrl: './siteDescriptorSelector.component.html',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: SiteDescriptorSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class SiteDescriptorSelectorComponent implements OnInit, ControlValueAccessor{\r\n @Input() descriptors: Compliance.NameValuePair[];\r\n @Input() descriptorId: number;\r\n @Input() selectedDescriptors: number[];\r\n @Input() disabled: boolean;\r\n @Output() descriptorChange = new EventEmitter();\r\n\r\n descriptorFilter: string = '';\r\n descriptorIsLoading: boolean = false;\r\n\r\n descriptors$: Observable[]> = (Observable\r\n .create((observer: any) => { observer.next(this.descriptorFilter); }) as Observable)\r\n .pipe(mergeMap((token: string) => this._filterDescriptors(token)));\r\n\r\n private _onChangeFn: any;\r\n private _onTouchedFn: any;\r\n private _descriptorNoResult: boolean = false;\r\n\r\n async ngOnInit(): Promise {\r\n if (this.descriptorId) {\r\n const selectedDescriptor = this.descriptors.find(x => x.value === this.descriptorId);\r\n if (selectedDescriptor) {\r\n this.descriptorFilter = selectedDescriptor.name;\r\n }\r\n }\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n writeValue(descriptorId: number): void {\r\n this._selectDescriptor(descriptorId);\r\n }\r\n\r\n onBlur(): void {\r\n this._selectDescriptor(this.descriptorFilter ? this.descriptorId : null);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const descriptor = match.item as Compliance.NameValuePair;\r\n this._selectDescriptor(descriptor.value);\r\n }\r\n }\r\n\r\n onNoResults(event: boolean): void {\r\n this._descriptorNoResult = event;\r\n }\r\n\r\n onLoadingChange(isLoading: boolean): void {\r\n this.descriptorIsLoading = isLoading;\r\n }\r\n\r\n private _selectDescriptor(descriptorId: number): void {\r\n const descriptor = this.descriptors.find(x => x.value === descriptorId);\r\n\r\n if (descriptor) {\r\n this.descriptorId = descriptor.value;\r\n this.descriptorFilter = descriptor.name;\r\n } else {\r\n this.descriptorId = null;\r\n this.descriptorFilter = null;\r\n }\r\n\r\n this._onChangeFn && this._onChangeFn(this.descriptorId);\r\n this.descriptorChange.emit(this.descriptorId);\r\n }\r\n\r\n private _filterDescriptors(token: string): Observable[]> {\r\n return observableOf(this.descriptors.filter(x =>\r\n (!this.selectedDescriptors.some(y => y === x.value) || x.value === this.descriptorId) &&\r\n (!token || x.name.toLowerCase().includes(token.toLowerCase()))));\r\n }\r\n}\r\n"," 0\">\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
Characteristic {{numToWord(i + 1)}}\r\n \r\n
\r\n
\r\n
\r\n","
\r\n \r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { DescriptorService } from '../../Property-Characteristics/descriptor.service';\r\nimport { fill } from 'lodash';\r\n\r\nexport interface SiteDescriptorsSelectorParams {\r\n companyId: number;\r\n isEditMode: boolean;\r\n selectedDescriptors: number[];\r\n}\r\n\r\n@Component({\r\n selector: 'site-descriptors-list',\r\n templateUrl: 'siteDescriptorsList.component.html'\r\n})\r\nexport class SiteDescriptorsListComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private _busyIndicatorService: BusyIndicatorService,\r\n private readonly _descriptorService: DescriptorService,\r\n private readonly _modalRef: BsModalRef,\r\n ) {\r\n }\r\n\r\n _numberOfDescriptorsToSelect: number = 5;\r\n\r\n _numberWord = ['', 'One', 'Two', 'Three', 'Four', 'Five'];\r\n\r\n params: SiteDescriptorsSelectorParams;\r\n result: number[];\r\n\r\n isInitialized: boolean = false;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n selectedDescriptors: number[];\r\n siteDescriptors: Compliance.NameValuePair[];\r\n isEditMode: boolean = false;\r\n\r\n async ngOnInit(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n try {\r\n const availableDescriptorsCount = Math.max(this._numberOfDescriptorsToSelect, (this.params.selectedDescriptors ?? []).length);\r\n\r\n this.selectedDescriptors = fill(Array(availableDescriptorsCount), 3);\r\n (this.params.selectedDescriptors ?? []).forEach((x, i) => this.selectedDescriptors[i] = x);\r\n\r\n const allDescriptors = await this._descriptorService.getUsedBySite(this.params.companyId);\r\n this.siteDescriptors = allDescriptors\r\n .map(x => { return {name: x.name, value: x.descriptorID} as Compliance.NameValuePair;})\r\n .sort((x, y) => x.name > y.name ? 1 : -1);\r\n\r\n this.isEditMode = this.params.isEditMode;\r\n this.isInitialized = true;\r\n }\r\n finally{\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n save(): void {\r\n this.result = this.selectedDescriptors;\r\n this._modalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n numToWord(val: number): string {\r\n return this._numberWord[val];\r\n }\r\n\r\n onDescriptorChange(descriptorId: number, i: number) {\r\n this.selectedDescriptors[i] = descriptorId;\r\n }\r\n\r\n trackByIndex(i, item) : number {\r\n return i;\r\n }\r\n\r\n removeAllSelectedDescriptors(): void {\r\n this.result = [];\r\n this._modalRef.hide();\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, Output, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport {\r\n SiteDescriptorsListComponent,\r\n SiteDescriptorsSelectorParams\r\n} from '../Site-Descriptors-List/siteDescriptorsList.component';\r\nimport { CompanyService } from 'src/app/Entity/Company/company.service';\r\n\r\n@Component({\r\n selector: 'site-descriptors-edit',\r\n templateUrl: './siteDescriptorsEdit.component.html',\r\n styleUrls: ['./siteDescriptorsEdit.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class SiteDescriptorsEditComponent {\r\n\r\n constructor(\r\n private readonly _bsModalService: BsModalService,\r\n private readonly _wsModalService: WeissmanModalService,\r\n private readonly _companyService: CompanyService\r\n ) {\r\n }\r\n\r\n @Input() isEditMode: boolean;\r\n @Input() companyId: number;\r\n @Input() siteDescriptors: number[];\r\n\r\n @Output() siteDescriptorsChanged: EventEmitter = new EventEmitter();\r\n\r\n isTopLevelCompany: boolean = this._companyService.isTopLevel();\r\n\r\n async view(): Promise {\r\n try {\r\n const params: SiteDescriptorsSelectorParams = {\r\n isEditMode: this.isEditMode,\r\n companyId: this.companyId,\r\n selectedDescriptors: this.siteDescriptors\r\n };\r\n\r\n const bsModalParcelsRef = await this._wsModalService.show(() => {\r\n return this._bsModalService.show(SiteDescriptorsListComponent,\r\n {\r\n class: 'modal-md',\r\n initialState: {\r\n params: params\r\n },\r\n ignoreBackdropClick: true\r\n });\r\n }).whenClosed;\r\n\r\n const result = (bsModalParcelsRef.content as SiteDescriptorsListComponent).result;\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.siteDescriptorsChanged.next(result);\r\n\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n get title(): string {\r\n let result: string;\r\n if (this.siteDescriptors && this.siteDescriptors.length) {\r\n if (this.isEditMode) {\r\n result = 'Edit / Remove Site Characteristics';\r\n } else {\r\n result = 'View Site Characteristics';\r\n }\r\n } else {\r\n result = 'Site Characteristics';\r\n }\r\n return result;\r\n }\r\n}\r\n","\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Output Type:\r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n MB package size\r\n
Transmit Cover:\r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n payment items per transmittal\r\n
Package Cover:\r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n per package\r\n
Group By:\r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
Message:\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n","\r\n \r\n\r\n\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { CompanyService } from 'src/app/Entity/Company/company.service';\r\nimport { TransmittalOutputType, TransmittalGroupBy } from 'src/app/Processing/Transmittal/transmittal.models';\r\nimport { ClientServiceResponsibilityService } from '../../clientServiceResponsibility.service';\r\nimport { LaunchEmailTemplateModalService } from 'src/app/Common/Custom-Email-Template/launch.email.template.modal.service';\r\nimport { WeissmanModalService } from 'src/app/Compliance/WeissmanModalService';\r\nimport { DeliveryDetailsConfigureParams, DeliveryDetailsConfigureModalComponent } from './deliveryDetailsConfigureModal.component';\r\nimport { TransmitDeliveryDetail } from '../../clientServices.model';\r\nimport { CompanyEntity } from 'src/app/Entity/entity.model';\r\nimport { map, sortBy } from 'lodash/fp';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\ninterface DDOption {\r\n id: number;\r\n name: string;\r\n}\r\n\r\ninterface PackageEmailTemplate {\r\n name: string;\r\n packageEmailTemplateID: number;\r\n bodyTemplate: string;\r\n subjectTemplate: string;\r\n}\r\n\r\n@Component({\r\n selector: 'delivery-details-transmit',\r\n templateUrl: './deliveryDetailsTransmit.component.html'\r\n})\r\nexport class DeliveryDetailsTransmitComponent implements OnInit {\r\n constructor(private readonly _companyService: CompanyService,\r\n private readonly _launchEmailTemplateModalService: LaunchEmailTemplateModalService,\r\n private readonly _modalService: WeissmanModalService,\r\n public readonly featureFlagsService: FeatureFlagsService,\r\n private readonly _clientServiceResponsibilityService: ClientServiceResponsibilityService) { }\r\n\r\n @Input() editMode: boolean;\r\n @Input() currentData: TransmitDeliveryDetail;\r\n @Input() topLevelData: TransmitDeliveryDetail;\r\n @Input() entity: CompanyEntity;\r\n @Input() userSearchInstanceId: number;\r\n @Input() isEntityInRyanInstance: boolean;\r\n\r\n @Output() currentDataChange: EventEmitter = new EventEmitter();\r\n @Output() currentPaymentBatchDataChange: EventEmitter = new EventEmitter();\r\n\r\n transmittalOutputTypes: DDOption[];\r\n transmittalFormats: DDOption[];\r\n transmittalGroupBys: DDOption[];\r\n deliveryDetailPerPackageLimitTypes: DDOption[];\r\n packageEmailTemplates: PackageEmailTemplate[];\r\n transmittalPackageCovers: DDOption[];\r\n TransmittalOutputType = TransmittalOutputType;\r\n currentPaymentBatchData: Core.PaymentBatchDeliveryDetail;\r\n\r\n ngOnInit() {\r\n this._setTransmittalDropdowns();\r\n this._setDeliveryDetailsDefaults();\r\n this._setCheckboxes();\r\n this.currentDataChange.emit(this.currentData);\r\n }\r\n\r\n get isCompany(): boolean {\r\n return this.entity.type === 'company';\r\n }\r\n\r\n get isSubsidiary(): boolean {\r\n return this.isCompany && !this._companyService.isTopLevel();\r\n }\r\n\r\n get areNoTopLevelSettings(): boolean {\r\n return !this.topLevelData.taxBillDeliveryDetailID;\r\n }\r\n\r\n get showSiteDescriptorsSelector(): boolean {\r\n return this.currentData.transmittalFormatID === 6 && (\r\n this.currentData.transmittalGroupByID === TransmittalGroupBy.Subsidiary_Site ||\r\n this.currentData.transmittalGroupByID === TransmittalGroupBy.Collector_Site);\r\n }\r\n\r\n useTopLevelChanged() {\r\n if (!this.currentData.useTopLevelCompanySettings) {\r\n this.currentData.ownerEntityID = this.entity.id;\r\n }\r\n else {\r\n _.assign(this.currentData, _.omit(this.topLevelData, 'useTopLevelCompanySettings', 'taxBillDeliveryDetailID'));\r\n this._setCheckboxes();\r\n }\r\n }\r\n\r\n async launchConfigureModal() {\r\n const params: DeliveryDetailsConfigureParams = {\r\n editMode: this.editMode && !this.currentData.useTopLevelCompanySettings,\r\n feedSpecifications: _.cloneDeep(this.currentData.feedSpecifications),\r\n clientAbbreviation: this.currentData.clientAbbreviation,\r\n entity: this.entity,\r\n isBillPay: this.currentData.transmittalOutputTypeID === TransmittalOutputType.BillPay,\r\n userSearchInstanceId: this.userSearchInstanceId,\r\n currentPaymentBatchData: this.currentPaymentBatchData,\r\n isTopLevelCompany: this.isCompany &&\r\n (!this.isSubsidiary || !this.currentData.useTopLevelCompanySettings),\r\n dataHubEnabled: this.currentData.dataHubEnabled,\r\n isEntityInRyanInstance: this.isEntityInRyanInstance\r\n };\r\n\r\n const result = await this._modalService.showAsync(DeliveryDetailsConfigureModalComponent, params, 'modal-lg');\r\n console.log(result);\r\n\r\n if(result?.feedSpecResult) {\r\n _.assign(this.currentData, result.feedSpecResult);\r\n this.currentDataChange.emit(this.currentData);\r\n }\r\n\r\n if(result?.paymentBatchResult) {\r\n let paymentBatchDataToSave;\r\n [ paymentBatchDataToSave, this.currentPaymentBatchData ] = result.paymentBatchResult;\r\n\r\n if (paymentBatchDataToSave) {\r\n this.currentPaymentBatchDataChange.emit(paymentBatchDataToSave);\r\n }\r\n }\r\n\r\n }\r\n\r\n maybeNullInputs(): void {\r\n this.currentData.maxPackageSize = this.currentData.isMaxPackageSize\r\n ? this.currentData.maxPackageSize\r\n : null;\r\n this.currentData.maxPaymentItemsPerTransmittal = this.currentData.isMaxPaymentItems\r\n ? this.currentData.maxPaymentItemsPerTransmittal\r\n : null;\r\n\r\n if (this.currentData.isOne) {\r\n this.currentData.deliveryDetailPerPackageLimitTypeID = this.currentData.deliveryDetailPerPackageLimitTypeID\r\n || this.deliveryDetailPerPackageLimitTypes[0].id;\r\n } else {\r\n this.currentData.deliveryDetailPerPackageLimitTypeID = null;\r\n }\r\n\r\n this.currentDataChange.emit(this.currentData);\r\n }\r\n\r\n onSiteDescriptorsChanged(siteDescriptorIds: number[]): void {\r\n this.currentData.siteDescriptors = siteDescriptorIds.filter(x => x);\r\n this.currentDataChange.emit(this.currentData);\r\n }\r\n\r\n maybeLaunchCustomModal(newPackageEmailTemplateID?: number) {\r\n let oldPackageEmailTemplateID: number;\r\n\r\n if(newPackageEmailTemplateID !== undefined) {\r\n oldPackageEmailTemplateID = this.currentData.packageEmailTemplateID;\r\n this.currentData.packageEmailTemplateID = newPackageEmailTemplateID;\r\n }\r\n\r\n if (this.currentData.packageEmailTemplateID) {\r\n return;\r\n }\r\n\r\n const customTemplateModalCloseFn = template => {\r\n if (template) {\r\n _.assign(this.currentData, template);\r\n }\r\n\r\n if (!this.currentData.packageEmailCustomTemplateBody && oldPackageEmailTemplateID) {\r\n this.currentData.packageEmailTemplateID = Number(oldPackageEmailTemplateID);\r\n }\r\n this.currentDataChange.emit(this.currentData);\r\n };\r\n\r\n this._launchEmailTemplateModalService.openCustomTemplateModal(customTemplateModalCloseFn, this.currentData.packageEmailCustomTemplateSubject,\r\n this.currentData.packageEmailCustomTemplateBody, this.packageEmailTemplates);\r\n }\r\n\r\n previewTemplate(): void {\r\n const selectedTemplate = _.find(this.packageEmailTemplates, { packageEmailTemplateID: this.currentData.packageEmailTemplateID });\r\n\r\n if (selectedTemplate) {\r\n this._launchEmailTemplateModalService.openPreviewTemplateModal(selectedTemplate);\r\n }\r\n }\r\n\r\n private async _setTransmittalDropdowns(): Promise {\r\n this.transmittalOutputTypes = [{\r\n id: null,\r\n name: ''\r\n }, {\r\n name: 'AP Feed',\r\n id: TransmittalOutputType.APFeed\r\n }, {\r\n name: 'Bill Pay',\r\n id: TransmittalOutputType.BillPay\r\n }, {\r\n name: 'Digital Transmittal',\r\n id: TransmittalOutputType.DigitalTransmittal\r\n }, {\r\n name: 'Paper Transmittal',\r\n id: TransmittalOutputType.PaperTransmittal\r\n }];\r\n\r\n const result = await this._clientServiceResponsibilityService.getAvailableTransmittalFormats(this.entity.typeId, this.entity.id);\r\n this.transmittalFormats = _.flow([\r\n map(format => {\r\n return {id: format.transmittalFormatID, name: format.name};\r\n }),\r\n sortBy('name')\r\n ])(result);\r\n\r\n this.transmittalGroupBys = [{\r\n id: TransmittalGroupBy.Collector,\r\n name: 'Collector / Due Date'\r\n }, {\r\n id: TransmittalGroupBy.Collector_Site,\r\n name: 'Collector / Site / Due Date'\r\n }, {\r\n id: TransmittalGroupBy.Subsidiary,\r\n name: 'Subsidiary / Collector / Due Date'\r\n }, {\r\n id: TransmittalGroupBy.Subsidiary_Site,\r\n name: 'Subsidiary / Collector / Site / Due Date'\r\n }];\r\n\r\n this.deliveryDetailPerPackageLimitTypes = [{\r\n id: null,\r\n name: ''\r\n }, {\r\n id: 1,\r\n name: 'State'\r\n }, {\r\n id: 2,\r\n name: 'Transmittal'\r\n }];\r\n\r\n this.packageEmailTemplates = await this._clientServiceResponsibilityService.getPackageEmailTemplates(this.entity.typeId, this.entity.id);\r\n this.packageEmailTemplates = _.sortBy(this.packageEmailTemplates, 'name');\r\n\r\n this.packageEmailTemplates.push({\r\n name: 'Custom',\r\n packageEmailTemplateID: null,\r\n bodyTemplate: this.currentData.packageEmailCustomTemplateBody,\r\n subjectTemplate: this.currentData.packageEmailCustomTemplateSubject\r\n });\r\n\r\n if (!this.currentData.packageEmailTemplateID) {\r\n if (this.currentData.packageEmailCustomTemplateSubject) {\r\n this.currentData.packageEmailTemplateID = null;\r\n } else {\r\n this.currentData.packageEmailTemplateID = 1;\r\n }\r\n }\r\n\r\n const packageCovers = await this._clientServiceResponsibilityService.getPackageCovers();\r\n this.transmittalPackageCovers = _.flow([\r\n map(x => { return { id: x.transmittalPackageCoverId, name: x.name }; }),\r\n sortBy('id')\r\n ])(packageCovers);\r\n\r\n this.currentDataChange.emit(this.currentData);\r\n }\r\n\r\n private _setDeliveryDetailsDefaults(): void {\r\n if (!this.currentData.taxBillDeliveryDetailID) {\r\n this.currentData.maxPackageSize = 50;\r\n }\r\n\r\n this.currentData.ownerEntityID = this.entity.id;\r\n }\r\n\r\n private _setCheckboxes(): void {\r\n this.currentData.isMaxPackageSize = !!this.currentData.maxPackageSize;\r\n this.currentData.isMaxPaymentItems = !!this.currentData.maxPaymentItemsPerTransmittal;\r\n this.currentData.isOne = !!this.currentData.deliveryDetailPerPackageLimitTypeID;\r\n }\r\n}\r\n","
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n {{getDisplayName(currentData.allocationReviewerUser, currentData.allocationReviewerTeam)}}\r\n \r\n
\r\n
\r\n","import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';\r\nimport { EntityClientService, DRTeamRetrievesWPDeliveryDetail } from '../../clientServices.model';\r\nimport * as _ from 'lodash';\r\nimport { CompanyEntity } from 'src/app/Entity/entity.model';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\n\r\n@Component({\r\n selector: 'delivery-details-assessment-allocation',\r\n templateUrl: './deliveryDetailsAssessmentAllocation.component.html',\r\n styleUrls: ['./deliveryDetailsAssessmentAllocation.component.scss']\r\n})\r\nexport class DeliveryDetailsAssessmentAllocationComponent implements OnInit {\r\n constructor(private _companyService: CompanyService){}\r\n\r\n @Input() editMode: boolean;\r\n @Input() entity: CompanyEntity;\r\n @Input() currentData: DRTeamRetrievesWPDeliveryDetail;\r\n @Input() ces: Core.ConsultingEngagementResponse[];\r\n @Input() service: EntityClientService;\r\n @Input() entityInstanceId: number;\r\n @Input() isConsultantPerspective: boolean;\r\n @Input() userSearchInstanceId: number;\r\n\r\n @Output() currentDataChange: EventEmitter = new EventEmitter();\r\n\r\n ngOnInit() {\r\n this.currentData = this.currentData || {} as DRTeamRetrievesWPDeliveryDetail;\r\n this.currentDataChange.emit(this.currentData);\r\n }\r\n\r\n userChanged(newUser: Core.UserTeamModel): void {\r\n if(newUser){\r\n this._updateAllocationReviewer(newUser);\r\n }else{\r\n this._removeAllocationReviewer();\r\n }\r\n\r\n this.currentDataChange.emit(this.currentData);\r\n }\r\n\r\n allowEdit() {\r\n return this.entity.type === 'company' && this.editMode && this._companyService.isTopLevel();\r\n }\r\n\r\n getDisplayName(user: Core.UserTeamModel, team: Weissman.Model.Workflow.Team): string {\r\n //consultant person assigned - show consulting company name if not consultant viewing\r\n if(user && team){\r\n if (team.instanceID !== this.entityInstanceId && this.isConsultantPerspective === false) {\r\n //look up consultant's name\r\n const consultantName = this.ces.find(ce => ce.instanceId === team.instanceID)?.name;\r\n return consultantName ? `Consultant- ${consultantName}` : '';\r\n }\r\n //client person assigned - show person's name\r\n else if (user.lastName || user.firstName) {\r\n return `${user.lastName}, ${user.firstName} (${team.name})`;\r\n }\r\n }\r\n\r\n return '';\r\n }\r\n\r\n private _removeAllocationReviewer(): void {\r\n this.currentData.allocationReviewerUser = null;\r\n this.currentData.allocationReviewerTeam = null;\r\n this.currentData.allocationReviewerUserID = null;\r\n this.currentData.allocationReviewerTeamID = null;\r\n }\r\n\r\n private _updateAllocationReviewer(newUser: Core.UserTeamModel): void{\r\n this.currentData.allocationReviewerUserID = newUser.userID;\r\n this.currentData.allocationReviewerTeamID = newUser.teamID;\r\n\r\n this.currentData.allocationReviewerTeam = {\r\n name: newUser.teamName,\r\n teamID: newUser.teamID\r\n } as Weissman.Model.Workflow.Team;\r\n\r\n this.currentData.allocationReviewerUser = newUser;\r\n }\r\n}\r\n","
\r\n
\r\n \r\n

Client Services

\r\n
\r\n
\r\n Update in progress\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n Account Handler:\r\n
\r\n {{accountHandlerTitle}}\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n Command Center\r\n \r\n
\r\n
\r\n
\r\n

Responsibilities:

\r\n
\r\n
\r\n

Delivery Details:

\r\n
\r\n
\r\n\r\n
\r\n
\r\n

{{service.name}}

\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n {{responsibility.propTypeAbbr}}\r\n
\r\n
\r\n {{(responsibility.placeholderText) ? responsibility.placeholderText : responsibility.assigneeDisplay}}\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
- {{consultingEngagements[0].name}}
\r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n Exceptions\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Inject, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { ConsultingEngagementsRepository } from 'src/app/Consulting/consultingEngagements.repository';\r\nimport { ClientServiceType, EntityTypeIds, PropertyType, RyanInstanceId } from 'src/app/constants.new';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { ClientServiceResponsibilityService } from '../clientServiceResponsibility.service';\r\nimport { ClientServiceResponsibility, ClientServicesPanelData, EntityClientService, ClientServicePanelWorkflowUserTypes, WorkflowUserTypesUI } from '../clientServices.model';\r\nimport { InstanceRepository } from 'src/app/Entity/Instance/instance.repository';\r\nimport { InstanceRights, RestrictService } from 'src/app/Common/Permissions/restrict.service';\r\nimport { UserInstanceService } from 'src/app/User/userInstance.service';\r\nimport { ChangeHistoryModalLaunchService } from 'src/app/Common/Change-History/change-history-modal-launch.service';\r\nimport { CompanyService } from 'src/app/Entity/Company/company.service';\r\nimport { NavigationService } from 'src/app/Layout/navigation.service';\r\nimport { PropertyTypeService } from 'src/app/Common/Services/propertyType.service.upgrade';\r\nimport { ClientServicesExceptionModalService } from '../Exceptions/client-service-exception-modal.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AnnualDetailsNavigationEventService } from 'src/app/Annual-Details/annual-details-event.service';\r\nimport { lastValueFrom, Subject, Subscription, takeUntil } from 'rxjs';\r\nimport { CompanyEntity } from 'src/app/Entity/entity.model';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { ProcessingService } from '../../Processing/processing.service.upgrade';\r\nimport { LongRunningProcessRepository } from '../../Compliance/Repositories';\r\nimport { WebsocketListenerService } from '../../Compliance/websocketListener.service';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from 'src/app/Busy-Indicator';\r\nimport { TaxFeedSettingRepository } from '../../Entity/taxFeedSettingRepository';\r\nimport {\r\n DocumentIntakeLicensedClientDetailRepository\r\n} from '../../Documents/Document-Intake-Licensed-Clients/documentIntakeLicensedClient.repository';\r\nimport { UserGroupService } from '../../User-Group/user-group-service.upgrade';\r\nimport { UserService } from '../../Account/user.service';\r\nimport { TransmittalOutputType } from 'src/app/Processing/Transmittal/transmittal.models';\r\nimport { EmptyGuid } from '../../constants.new';\r\n\r\nimport EntityTypes = Core.EntityTypes;\r\nimport ClientServiceResponsibilityUpdateQueueStatusEnum = Core.ClientServiceResponsibilityUpdateQueueStatusEnum;\r\n\r\nimport * as _ from 'lodash';\r\nimport { cloneDeep, compact, filter, flatMap, groupBy, map, reject, sortBy } from 'lodash/fp';\r\nimport { TeamService } from 'src/app/Team/team.service';\r\n\r\n@Component({\r\n selector: 'client-services-panel',\r\n templateUrl: 'clientServicesPanel.component.html',\r\n styles: [`\r\n option[disabled] {\r\n color: lightgray;\r\n }\r\n `]\r\n})\r\nexport class ClientServicesPanelComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _consultingEngagementsRepository: ConsultingEngagementsRepository,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _changeHistoryModalLaunchService: ChangeHistoryModalLaunchService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _annualDetailsNavigationEventService: AnnualDetailsNavigationEventService,\r\n private readonly _propertyTypeService: PropertyTypeService,\r\n private readonly _clientServicesExceptionModalService: ClientServicesExceptionModalService,\r\n private readonly _featureFlagService: FeatureFlagsService,\r\n @Inject('$rootScope') private _rootScope: any,\r\n private readonly _csrService: ClientServiceResponsibilityService,\r\n private readonly _processingService: ProcessingService,\r\n private readonly _longRunningProcessRepository: LongRunningProcessRepository,\r\n private readonly _websocketListenerService: WebsocketListenerService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _teamService: TeamService,\r\n private readonly _taxFeedSettingRepository: TaxFeedSettingRepository,\r\n private readonly _documentIntakeLicensedClientRepository: DocumentIntakeLicensedClientDetailRepository,\r\n private readonly _userGroupService: UserGroupService,\r\n private readonly _userService: UserService,\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {\r\n this._rootScope.$on('WS.COMPANY.ROWVERSION.CHANGED', (event, companyRowVersion) => {\r\n if (this.panelData) {\r\n this.panelData.companyRowVersion = companyRowVersion;\r\n }\r\n });\r\n }\r\n\r\n @Input() entity: CompanyEntity;\r\n @Input() company: Weissman.Model.Domain.Company;\r\n @Input() getAnnualGridCallback: (getCompTypesOnly: boolean) => void;\r\n @Input() externalLoad$: Subject;\r\n @Output() ppReturnPreparationAllowedChanged: EventEmitter = new EventEmitter();\r\n\r\n serverAction: boolean = false;\r\n enteringEditMode: boolean = false;\r\n editMode: boolean = false;\r\n editLocked: boolean = false;\r\n showBody: boolean = false;\r\n loadingDropdownData: boolean = false;\r\n panelLoading: boolean = false;\r\n isLongRunningProcessRunning: boolean = false;\r\n externalLoadSub: Subscription;\r\n\r\n entityInstanceId: number;\r\n topLevelCompanyId: number;\r\n hasEditPermission: boolean;\r\n hasComplianceFeatureView: boolean;\r\n isExplicitView: boolean;\r\n isConsultantPerspective: boolean;\r\n consultantsInstanceId: number;\r\n hasTaxFeeds: boolean;\r\n canEditCompany: boolean;\r\n isLicensedDIUser: boolean;\r\n\r\n panelData: ClientServicesPanelData;\r\n consultingEngagements: Core.ConsultingEngagementResponse[];\r\n availableClientServices: Weissman.Model.Workflow.ClientService[];\r\n newClientService: Weissman.Model.Workflow.ClientService;\r\n availablePropertyTypes: Weissman.Model.Assessments.PropertyType[];\r\n newPropertyType: Weissman.Model.Assessments.PropertyType;\r\n ClientServiceType = ClientServiceType;\r\n entityTree: Core.EntityTree;\r\n taxFeedSettings: Core.TaxFeedSettingModel;\r\n topLevelCompanyTaxFeedSettings: Core.TaxFeedSettingModel;\r\n ahAvailableUsers: Core.UserTeamModel[];\r\n csrAvailableUsers: Core.UserTeamModel[];\r\n paymentBatchData: Weissman.Model.Domain.DeliveryDetailPaymentBatchDTOIn;\r\n workflowUserTypes: Compliance.NameValuePair[] = [\r\n { value: Core.WorkflowUserTypes.AccountHandler, name: 'Account Handler' },\r\n { value: WorkflowUserTypesUI.ConsultingEngagement, name: 'Consultant' },\r\n { value: Core.WorkflowUserTypes.JurisdictionSpecialist, name: 'Jurisdiction Specialist' },\r\n { value: Core.WorkflowUserTypes.User, name: 'Specific Individual' },\r\n { value: Core.WorkflowUserTypes.NA, name: 'N/A' },\r\n { value: Core.WorkflowUserTypes.ConsultantAccountHandler, name: 'Account Handler' }, //isn't shown as a dropdown option, but is shown for consultants when their account handler is chosen\r\n ]; //order is intentional\r\n\r\n private _consultingEngagementAccountHandlerTitle: string;\r\n private _originalPanelData: ClientServicesPanelData;\r\n private _propertyTypes: Weissman.Model.Assessments.PropertyType[];\r\n private _originalPPReturnPreparationAllowed: boolean;\r\n private readonly COMPLIANCE_PREFIX = 'batch';\r\n private readonly ALLOCATIONS_PREFIX = 'allocation';\r\n private _destroy$: Subject = new Subject();\r\n private _busyDestroy$: Subject = new Subject();\r\n private _busyRef: BusyIndicatorRef;\r\n private _instanceLicensedDISettings: Core.DocumentIntakeLicensedClientModel;\r\n\r\n get isCompany() {\r\n return this.entity.type === 'company';\r\n }\r\n\r\n get isTopLevelCompany() {\r\n return this.isCompany && this._companyService.isTopLevel();\r\n }\r\n\r\n get accountHandlerTitle() {\r\n //explicit instance access\r\n if (this.isExplicitView) {\r\n if (!this.panelData.accountHandler || !this.panelData.accountHandlerTeam) {\r\n return 'None Assigned';\r\n }\r\n\r\n return this._formatPersonsName(this.panelData.accountHandler.lastName, this.panelData.accountHandler.firstName, this.panelData.accountHandlerTeam.name);\r\n }\r\n //implicit instance access - show consultant account handler\r\n else {\r\n return this._consultingEngagementAccountHandlerTitle;\r\n }\r\n }\r\n\r\n get isAccountHandlerOverridden() {\r\n //a subsidiary company/site/parcel cannot override the consultant's account handler\r\n //the account handler is controlled only through the manage consulting engagment menu\r\n\r\n return this.isExplicitView && this.panelData.accountHandlerIsOverridden;\r\n }\r\n\r\n get canLaunchHistory() {\r\n return !this.editMode\r\n && !this.panelLoading\r\n && this.entity.canEditCompanySetups\r\n && (!this.isCompany || this.entity.canEditCompany)\r\n && this.entity.hasWritePermission;\r\n }\r\n\r\n get canEdit() {\r\n return !this.editMode\r\n && !this.editLocked\r\n && !this.panelLoading\r\n && !this.isLongRunningProcessRunning\r\n && (\r\n !this.isExplicitView\r\n || (\r\n this.hasEditPermission\r\n && this.entity.canEditCompanySetups\r\n && (!this.isCompany || this.entity.canEditCompany)\r\n && this.entity.hasWritePermission\r\n && !this.entity.isInactive\r\n )\r\n );\r\n }\r\n\r\n get canSave(): boolean {\r\n return this.editMode\r\n && (\r\n !this.isExplicitView\r\n || (\r\n this.entity.canEditCompanySetups\r\n && (!this.isCompany || this.entity.canEditCompany)\r\n && this.entity.hasWritePermission\r\n )\r\n );\r\n }\r\n\r\n get isEntityInRyanInstance(): boolean {\r\n return this.entityInstanceId === RyanInstanceId;\r\n }\r\n\r\n get showJurisdictionSpecialistOption(): boolean {\r\n return this._userInstanceService.isCurrentInstanceRyan();\r\n }\r\n\r\n get isConsultingClient(): boolean {\r\n return this.consultingEngagements.length\r\n && this.entityInstanceId\r\n && !this._userInstanceService.isInstanceImplicit(this.entityInstanceId);\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n const validProcessTypes = [Compliance.LongRunningProcessTypeEnum.UpdateCsrBulk, Compliance.LongRunningProcessTypeEnum.UpdateCsr];\r\n this._websocketListenerService.longRunningProcessStatusChange$.pipe(takeUntil(this._destroy$)).subscribe(\r\n async (x) => {\r\n if ((!validProcessTypes.includes(x.processType)) || x.entityId !== this.topLevelCompanyId) {\r\n return;\r\n }\r\n if (x.isCanceled || x.isError || x.isCompleted) {\r\n this.isLongRunningProcessRunning = false;\r\n this.panelLoading = true;\r\n\r\n await this._loadPanel();\r\n this.editMode = false;\r\n\r\n this.panelLoading = false;\r\n if (this._busyRef) {\r\n this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._csrService.notifyClientServicesChange();\r\n const lrp = await lastValueFrom(this._longRunningProcessRepository.get(x.longRunningProcessId));\r\n if (lrp.result) {\r\n const result = JSON.parse(lrp.result);\r\n if (result?.result?.companyRowVersion) {\r\n this._broadcastRowVersionChange(result.result.companyRowVersion);\r\n }\r\n }\r\n } else {\r\n this.isLongRunningProcessRunning = true;\r\n }\r\n });\r\n\r\n this._navigationService.globalEditMode$.pipe(takeUntil(this._destroy$)).subscribe(editMode => {\r\n this.editLocked = editMode;\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async expandOrCollapse(): Promise {\r\n if (this.editMode) {\r\n return;\r\n }\r\n\r\n this.showBody = !this.showBody;\r\n this._productAnalyticsService.logEvent('company-toggle-panel', {\r\n panel: 'Client Services',\r\n isOpen: this.showBody\r\n });\r\n\r\n if (this.showBody) {\r\n this.panelLoading = true;\r\n await this._loadPanel();\r\n\r\n this.panelLoading = false;\r\n this.externalLoadSub = this.externalLoad$?.subscribe(() => this._loadPanel());\r\n }\r\n else {\r\n this.externalLoadSub?.unsubscribe();\r\n }\r\n }\r\n\r\n launchHistoryModal(): void {\r\n this._changeHistoryModalLaunchService.openChangeHistoryModal(this.entity.name, this.entity.id, this.entity.typeId, 'CSR');\r\n }\r\n\r\n async goToEditMode(): Promise {\r\n this.enteringEditMode = true;\r\n this.loadingDropdownData = true;\r\n\r\n try {\r\n const clientServices = await this._csrService.getAll();\r\n\r\n this.availableClientServices = _.reject(clientServices, (x: Weissman.Model.Workflow.ClientService) => {\r\n return (x.name === 'Allocations' && !this._featureFlagService.featureFlags.enableAllocationFeature)\r\n || _.some(this.panelData.entityClientServices, { clientServiceID: x.clientServiceID });\r\n });\r\n\r\n this.availablePropertyTypes = _.reject(this._propertyTypes, x => {\r\n return _.some(this.panelData.entityClientServices[0].responsibilities, { propertyTypeID: x.propertyTypeID });\r\n });\r\n } catch {\r\n throw('Error loading services or property types');\r\n } finally {\r\n this.loadingDropdownData = false;\r\n }\r\n\r\n this._originalPPReturnPreparationAllowed = this.entity.ppReturnPreparationAllowed;\r\n\r\n this._originalPanelData = _.cloneDeep(this.panelData);\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n\r\n this.ahAvailableUsers = await this._teamService.getAllAssignableUsers(false, false, this.entity.id, this.entity.type);\r\n\r\n if (this.isConsultantPerspective) {\r\n this.csrAvailableUsers = await this._teamService.getAllAssignableUsers(false, false, this.entity.id, this.entity.type, this.consultantsInstanceId);\r\n }\r\n else {\r\n this.csrAvailableUsers = this.ahAvailableUsers;\r\n }\r\n\r\n this.panelData.entityClientServices.forEach((service: EntityClientService) => {\r\n service.responsibilities.forEach(async(responsibility: ClientServiceResponsibility) => {\r\n responsibility.placeholderText = await this._getPlaceholderText(responsibility);\r\n });\r\n });\r\n\r\n this.enteringEditMode = false;\r\n this.editMode = true;\r\n this._productAnalyticsService.logEvent('edit-company-client-services');\r\n }\r\n\r\n cancelEdit() {\r\n if (this.isTopLevelCompany) {\r\n this.entity.ppReturnPreparationAllowed = this._originalPPReturnPreparationAllowed;\r\n }\r\n\r\n this._navigationService.disableNavWarning();\r\n this.panelData = this._originalPanelData;\r\n this.editMode = false;\r\n }\r\n\r\n async savePanel(): Promise {\r\n if (this.panelData.companyIsActive && (!this.panelData.accountHandlerUserID || this.panelData.accountHandlerTeamID === undefined)) {\r\n this._toastr.error('Account Handler is required for active companies', 'Error');\r\n return;\r\n }\r\n\r\n const panelToSave: any = _.pick(this.panelData, 'accountHandlerUserID', 'accountHandlerTeamID', 'entityID', 'entityTypeID', 'companyRowVersion');\r\n\r\n if (this.isCompany && this.entity.isTopLevel) {\r\n panelToSave.ppReturnPreparationAllowed = this.entity.ppReturnPreparationAllowed;\r\n }\r\n\r\n if (this.isCompany && this.entity.isTopLevel || this.isParcel) {\r\n panelToSave.assessmentsTaxFeedEnabled = this.taxFeedSettings.assessmentsTaxFeedsEnabled;\r\n panelToSave.taxBillsTaxFeedEnabled = this.taxFeedSettings.taxBillsTaxFeedsEnabled;\r\n }\r\n\r\n const originalResponsibilities = _.flatMap(this._originalPanelData.entityClientServices, 'responsibilities');\r\n\r\n panelToSave.responsibilities = _.flow([\r\n cloneDeep,\r\n flatMap('responsibilities'),\r\n map(resp => {\r\n const originalResp = _.find(originalResponsibilities, {clientServiceResponsibilityID: resp.clientServiceResponsibilityID});\r\n\r\n if (!resp.clientServiceResponsibilityID) {\r\n resp.efAction = 'add';\r\n } else if (originalResp &&\r\n (originalResp.workflowUserTypeID !== resp.workflowUserTypeID ||\r\n originalResp.userID !== resp.userID ||\r\n originalResp.teamID !== resp.teamID ||\r\n originalResp.consultingEngagementId !== resp.consultingEngagementId ||\r\n (originalResp.dateFrom - resp.dateFrom !== 0))) {\r\n if (resp.entityID !== this.entity.id) {\r\n resp.entityID = this.entity.id;\r\n resp.entityTypeID = EntityTypeIds[this.entity.type.toUpperCase()];\r\n resp.addingOverride = true;\r\n\r\n delete resp.isException;\r\n delete resp.isTopCompany;\r\n delete resp.clientServiceResponsibilityID;\r\n\r\n resp.efAction = 'add';\r\n } else {\r\n resp.efAction = 'update';\r\n }\r\n }\r\n\r\n resp.clientService = null;\r\n resp.assignee = null;\r\n resp.workflowUserType = null;\r\n resp.team = null;\r\n\r\n return resp;\r\n }),\r\n filter('efAction')\r\n ])(this.panelData.entityClientServices);\r\n\r\n // now check which details were changed\r\n //\r\n const editedDeliveryDetails = this._extractDeliveryDetails(this.panelData.entityClientServices);\r\n const originalDeliveryDetails = this._extractDeliveryDetails(this._originalPanelData.entityClientServices);\r\n\r\n // We now allow an incomplete Payment Batch configuration to be saved, deferring\r\n // validation to creation of a Payment Batch, so we don't need to ensure the\r\n // Payment Batch/ configuration is present or feed specifications have been selected.\r\n\r\n const invalidInputFound = _.some(editedDeliveryDetails, detail => {\r\n return detail\r\n && ((detail.isMaxPackageSize && !detail.maxPackageSize)\r\n || (detail.isMaxPaymentItems && !detail.maxPaymentItemsPerTransmittal));\r\n });\r\n\r\n if (invalidInputFound) {\r\n this._toastr.error('Maximum values must be between 1 and 1000', 'Error');\r\n return;\r\n }\r\n\r\n let removePaymentBatchDataFlag = false;\r\n\r\n // // so, which deliveryDetails are we going to save?\r\n // //\r\n const deliveryDetailsToSave = _.flow([\r\n map(editedDeliveryDetail => {\r\n\r\n // update editedDeliveryDetail if necessary\r\n //\r\n let originalDeliveryDetail = this._getOriginalDeliveryDetail(originalDeliveryDetails, editedDeliveryDetail);\r\n\r\n if (!originalDeliveryDetail) { // if compliance return or assessment allocation, then editedDeliveryDetail can be null\r\n if (this._isComplianceReturns(editedDeliveryDetail) || this._isAllocations(editedDeliveryDetail )) {\r\n originalDeliveryDetail = {};\r\n } else {\r\n console.warn('Could not find a matching original delivery detail');\r\n return {};\r\n }\r\n }\r\n\r\n if (!originalDeliveryDetail.useTopLevelCompanySettings && editedDeliveryDetail.useTopLevelCompanySettings) {\r\n originalDeliveryDetail.efAction = 'delete';\r\n\r\n return _.omit(originalDeliveryDetail, 'isMaxPackageSize', 'isMaxPaymentItems', 'isOne');\r\n }\r\n\r\n //console.log('editedDeliveryDetail - before checking', editedDeliveryDetail);\r\n\r\n // useTopLevelCompanySettings - if original is different from edited\r\n //\r\n if (originalDeliveryDetail.useTopLevelCompanySettings && !editedDeliveryDetail.useTopLevelCompanySettings) {\r\n if (editedDeliveryDetail.taxBillDeliveryDetailID !== undefined) {\r\n editedDeliveryDetail.taxBillDeliveryDetailID = 0;\r\n }\r\n else if (editedDeliveryDetail.deliveryDetailAssessmentID !== undefined) {\r\n editedDeliveryDetail.deliveryDetailAssessmentID = 0;\r\n }\r\n else if (editedDeliveryDetail.deliveryDetailBillID !== undefined) {\r\n editedDeliveryDetail.deliveryDetailBillID = 0;\r\n }\r\n\r\n editedDeliveryDetail.efAction = 'add';\r\n }\r\n else if (!_.isEqual(originalDeliveryDetail, editedDeliveryDetail)) {\r\n // WK-6116: If there was no existing entry for tax bill delivery detail but the user made changes,\r\n // we need to add a new delivery detail\r\n if ((originalDeliveryDetail.taxBillDeliveryDetailID === 0 && editedDeliveryDetail.taxBillDeliveryDetailID === 0) || _.isEmpty(originalDeliveryDetail)) {\r\n editedDeliveryDetail.efAction = 'add';\r\n }\r\n else {\r\n editedDeliveryDetail.efAction = 'update';\r\n }\r\n }\r\n\r\n // user did not change batch users/ teams, but switched on the whole thing\r\n //\r\n if (\r\n this._isComplianceReturns(editedDeliveryDetail)\r\n && this._originalPPReturnPreparationAllowed != this.entity.ppReturnPreparationAllowed\r\n && this.isTopLevelCompany\t\t\t// this info can be saved for top-level company only\r\n ) {\r\n editedDeliveryDetail.efAction = editedDeliveryDetail.deliveryDetails_PPBatchReturnsId\r\n ? 'update'\r\n : 'add';\r\n }\r\n\r\n // Prepare PP Returns is set to Off, but the panel still creates the detail with all properties empty and efAction = add. This caused PT-3826\r\n // https://weissmandemo.atlassian.net/browse/PT-3826\r\n if (this._isComplianceReturns(editedDeliveryDetail) &&\r\n !this.entity.ppReturnPreparationAllowed &&\r\n editedDeliveryDetail.efAction === 'add') {\r\n editedDeliveryDetail.efAction = null;\r\n }\r\n\r\n // if an ef action hasn't been determined yet, check the feed specification\r\n if (\r\n !editedDeliveryDetail.efAction\r\n && editedDeliveryDetail.taxBillDeliveryDetailID\r\n && (this._isFeedSpecificationsUpdated(originalDeliveryDetail, editedDeliveryDetail)\r\n || this.paymentBatchData) // need to send feed spec data if payment batch has been updated\r\n ) {\r\n editedDeliveryDetail.efAction = 'update';\r\n }\r\n\r\n if (originalDeliveryDetail.transmittalOutputTypeID === TransmittalOutputType.BillPay\r\n && editedDeliveryDetail.transmittalOutputTypeID !== TransmittalOutputType.BillPay) {\r\n removePaymentBatchDataFlag = true;\r\n }\r\n\r\n return _.omit(editedDeliveryDetail, 'isMaxPackageSize', 'isMaxPaymentItems', 'isOne');\r\n }),\r\n filter('efAction'),\r\n groupBy(detail => {\r\n if (detail.taxBillDeliveryDetailID !== undefined) {\r\n return 'deliveryDetails';\r\n }\r\n else if (detail.deliveryDetailAssessmentID !== undefined) {\r\n return 'deliveryDetailAssessments';\r\n }\r\n else if (detail.deliveryDetailBillID !== undefined) {\r\n return 'deliveryDetailBills';\r\n }\r\n else if (this._isComplianceReturns(detail)) {\r\n return 'DeliveryDetailPPReturnBatches';\r\n }\r\n else if (this._isAllocations(detail)) {\r\n return 'deliveryDetailAssessmentAllocation';\r\n }\r\n else {\r\n return 'errorNoID';\r\n }\r\n })\r\n ])(editedDeliveryDetails);\r\n\r\n if (this._featureFlagsService.featureFlags.enablePaymentBatch &&\r\n this.isEntityInRyanInstance &&\r\n this.isCompany) {\r\n\r\n if(this.paymentBatchData) {\r\n deliveryDetailsToSave.deliveryDetailPaymentBatch = [this.paymentBatchData];\r\n }\r\n\r\n if(removePaymentBatchDataFlag) {\r\n deliveryDetailsToSave.deliveryDetailPaymentBatch = deliveryDetailsToSave.deliveryDetailPaymentBatch || [{ ownerEntityID: this.entity.id}];\r\n deliveryDetailsToSave.deliveryDetailPaymentBatch[0].efAction = 'delete';\r\n }\r\n }\r\n\r\n _.assign(panelToSave, deliveryDetailsToSave);\r\n\r\n //Check if all fields that require a date contain the date, otherwise throw toast\r\n const invalidDate = _.some(panelToSave.responsibilities, resp => resp.showDatePicker && !resp.dateFrom);\r\n if (invalidDate) {\r\n this._toastr.error('Please fill in all start dates', 'Missing date');\r\n return;\r\n }\r\n\r\n //Check invoice tasks under appeals\r\n const invalidAppeal = _.some(panelToSave.responsibilities, resp => {\r\n return resp.clientServiceID === ClientServiceType.Appeals\r\n && resp.workflowUserTypeID === Core.WorkflowUserTypes.NA\r\n && resp.hasOpenPrepareDraftInvoiceTasks;\r\n });\r\n\r\n if (invalidAppeal) {\r\n this._toastr.error('Appeals responsibility can not be set to N/A if there is at least one unfinished \"Prepare Draft Invoice\" task ', 'Validation error');\r\n return;\r\n }\r\n\r\n\r\n if (!this.isTopLevelCompany && panelToSave.DeliveryDetailPPReturnBatches)\r\n delete panelToSave.DeliveryDetailPPReturnBatches;\r\n\r\n // Prepare PP Return is on, but DeliveryDetailPPReturnBatches is empty because no batch responsibilities have been entered.\r\n if(this.entity.ppReturnPreparationAllowed && !this._originalPPReturnPreparationAllowed && !panelToSave.DeliveryDetailPPReturnBatches) {\r\n this._toastr.error('Please enter Batch Responsibilities', 'Validation error');\r\n return;\r\n }\r\n\r\n if (panelToSave.DeliveryDetailPPReturnBatches && panelToSave.DeliveryDetailPPReturnBatches.length && panelToSave.ppReturnPreparationAllowed) {\r\n if (this._isUserEmpty('batchPreparer', panelToSave.DeliveryDetailPPReturnBatches[0])) {\r\n this._toastr.error('Please select Batch Preparer', 'Validation error');\r\n return;\r\n }\r\n\r\n if (this._isUserEmpty('batchProcessor', panelToSave.DeliveryDetailPPReturnBatches[0])) {\r\n this._toastr.error('Please select Batch Processor', 'Validation error');\r\n return;\r\n }\r\n\r\n if (this._isUserEmpty('batchReviewer', panelToSave.DeliveryDetailPPReturnBatches[0])) {\r\n this._toastr.error('Please select Batch Reviewer', 'Validation error');\r\n return;\r\n }\r\n }\r\n\r\n this.serverAction = true;\r\n\r\n try {\r\n const result = await this._csrService.saveEntity(panelToSave);\r\n\r\n if (result.longRunningProcessId) {\r\n //Show busy indicator\r\n this._busyRef = this._busyService.show({\r\n longRunningProcessId: result.longRunningProcessId,\r\n title: 'Updating Client Service Responsibility',\r\n canDismiss: true,\r\n message: '',\r\n captureFocus: true,\r\n restoreFocus: true,\r\n });\r\n\r\n this._busyRef.onDismiss().pipe(takeUntil(this._busyDestroy$)).subscribe(() => {\r\n this._busyRef.hide();\r\n this._busyDestroy$.next();\r\n this._busyRef = null;\r\n this.panelLoading = true;\r\n });\r\n\r\n this._navigationService.disableNavWarning();\r\n }\r\n else {\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n if (this.isCompany) {\r\n this.ppReturnPreparationAllowedChanged.emit(this.entity.ppReturnPreparationAllowed);\r\n this._broadcastRowVersionChange(result.companyRowVersion);\r\n }\r\n\r\n if (this.getAnnualGridCallback) {\r\n this._annualDetailsNavigationEventService.goToGrid();\r\n this.getAnnualGridCallback(false);\r\n }\r\n\r\n this._loadPanel();\r\n }\r\n } catch(err) {\r\n if(err) {\r\n this._toastr.error(err.error.message);\r\n }\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n\r\n }\r\n\r\n accountHandlerSelected(newAccountHandler: Core.UserTeamModel) {\r\n if(newAccountHandler) {\r\n this.panelData.accountHandlerUserID = newAccountHandler.userID;\r\n this.panelData.accountHandlerTeamID = newAccountHandler.teamID;\r\n this.panelData.accountHandlerTeam = {\r\n name: newAccountHandler.teamName,\r\n teamID: newAccountHandler.teamID\r\n } as Weissman.Model.Workflow.Team;\r\n this.panelData.accountHandler = {\r\n efAction: null,\r\n firstName: newAccountHandler.firstName,\r\n lastName: newAccountHandler.lastName,\r\n userID: newAccountHandler.userID\r\n };\r\n } else {\r\n this.panelData.accountHandlerUserID = null;\r\n this.panelData.accountHandlerTeamID = null;\r\n this.panelData.accountHandlerTeam = {} as Weissman.Model.Workflow.Team;\r\n this.panelData.accountHandler = {} as Core.ContactShortDTO;\r\n }\r\n }\r\n\r\n addClientService(): void {\r\n const serviceToAdd = _.pick(this.newClientService, ['clientServiceID', 'name', 'sequence']) as EntityClientService;\r\n const entityResponsibilities = this.panelData.entityClientServices.length ? _.cloneDeep(this.panelData.entityClientServices[0].responsibilities) : [];\r\n\r\n serviceToAdd.responsibilities = _.map(entityResponsibilities, resp => {\r\n _.assign(resp, this._getInitialValues());\r\n resp.clientServiceID = this.newClientService.clientServiceID;\r\n resp.disabledWorkflowUserTypes = this._getDisabledWorkflowUserTypes({ propertyTypeID: resp.propertyTypeID, clientServiceResponsibilityUpdateStatus: ClientServiceResponsibilityUpdateQueueStatusEnum.Created }, serviceToAdd);\r\n resp.translatedWorkflowUserTypeId = this._getTranslatedWorkflowUserTypeId(resp);\r\n\r\n return _.omit(resp, 'workflowUserType', 'clientServiceResponsibilityID') as ClientServiceResponsibility;\r\n });\r\n\r\n this.panelData.entityClientServices.push(serviceToAdd);\r\n _.remove(this.availableClientServices, this.newClientService);\r\n }\r\n\r\n addPropertyType(): void {\r\n const propTypeToAdd = _.pick(this.newPropertyType, ['propTypeAbbr', 'propertyTypeID']) as any;\r\n _.assign(propTypeToAdd, this._getInitialValues());\r\n\r\n this.panelData.entityClientServices = _.map(this.panelData.entityClientServices, service => {\r\n const respToAdd = _.cloneDeep(propTypeToAdd);\r\n\r\n respToAdd.clientServiceID = service.clientServiceID;\r\n respToAdd.disabledWorkflowUserTypes = this._getDisabledWorkflowUserTypes({ propertyTypeID: respToAdd.propertyTypeID, clientServiceResponsibilityUpdateStatus: ClientServiceResponsibilityUpdateQueueStatusEnum.Created }, service);\r\n respToAdd.translatedWorkflowUserTypeId = this._getTranslatedWorkflowUserTypeId(respToAdd);\r\n\r\n //does not have all fields of ClientServiceResponsibility\r\n service.responsibilities.push(respToAdd as ClientServiceResponsibility);\r\n return service;\r\n });\r\n\r\n _.remove(this.availablePropertyTypes, this.newPropertyType);\r\n }\r\n\r\n canEditResponsibility(responsibility: any): boolean {\r\n return this.editMode\r\n && (responsibility.clientServiceResponsibilityUpdateStatus === null\r\n || responsibility.clientServiceResponsibilityUpdateStatus === ClientServiceResponsibilityUpdateQueueStatusEnum.Errant)\r\n && (!this.isConsultantPerspective\r\n && !this.isLicensedDIUser\r\n || (responsibility.consultingEngagementId && responsibility.isMyConsultingCompany));\r\n }\r\n\r\n\r\n showSpecificIndividualUserTeamPicker(responsibility: ClientServiceResponsibility): boolean {\r\n return responsibility.translatedWorkflowUserTypeId === Core.WorkflowUserTypes.User\r\n && this.canEditResponsibility(responsibility);\r\n }\r\n\r\n showConsultingEngagementsList(responsibility: ClientServiceResponsibility): boolean {\r\n return responsibility.translatedWorkflowUserTypeId === WorkflowUserTypesUI.ConsultingEngagement\r\n && this.canEditResponsibility(responsibility);\r\n }\r\n\r\n showWorkflowUserTypeOption(userTypeValue: number){\r\n switch(userTypeValue){\r\n case Core.WorkflowUserTypes.JurisdictionSpecialist:\r\n return this.isEntityInRyanInstance || this.showJurisdictionSpecialistOption;\r\n case Core.WorkflowUserTypes.ConsultantAccountHandler:\r\n return false;\r\n case WorkflowUserTypesUI.ConsultingEngagement:\r\n return this.isConsultingClient\r\n && this.consultingEngagements\r\n && this.consultingEngagements.length\r\n && !this.isConsultantPerspective;\r\n default:\r\n return true;\r\n }\r\n }\r\n\r\n async retryResponsibilityUpdate(responsibility: any): Promise {\r\n this._busyRef = this._busyService.show({\r\n title: 'Retrying task updates',\r\n canDismiss: true,\r\n message: '',\r\n captureFocus: true,\r\n restoreFocus: true,\r\n });\r\n try {\r\n await this._csrService.retryWorkflowUpdateFromQueue({entityTypeId: responsibility.entityTypeID, entityId: responsibility.entityID, clientServiceId: responsibility.clientServiceID, propertyTypeId: responsibility.propertyTypeID});\r\n } finally {\r\n this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n\r\n responsibility.clientServiceResponsibilityUpdateStatus = null;\r\n }\r\n\r\n showResponsibilityUpdatingInfoIcon(status: number): boolean{\r\n return status === ClientServiceResponsibilityUpdateQueueStatusEnum.Created\r\n || status === ClientServiceResponsibilityUpdateQueueStatusEnum.Running\r\n || status === ClientServiceResponsibilityUpdateQueueStatusEnum.Completed;\r\n }\r\n\r\n showRetryResponsibilityUpdateIcon(status: number): boolean{\r\n return status === ClientServiceResponsibilityUpdateQueueStatusEnum.Errant;\r\n }\r\n\r\n userTypeChanged(workflowUserTypeId: ClientServicePanelWorkflowUserTypes, responsibility: ClientServiceResponsibility): void {\r\n const previousWorkflowUserTypeId = responsibility.translatedWorkflowUserTypeId;\r\n responsibility.translatedWorkflowUserTypeId = workflowUserTypeId;\r\n\r\n switch(responsibility.translatedWorkflowUserTypeId) {\r\n case WorkflowUserTypesUI.ConsultingEngagement:\r\n responsibility.workflowUserTypeID = Core.WorkflowUserTypes.ConsultantAccountHandler;\r\n // Note that there is a select component bound to responsibility.consultingEngagementID when there\r\n // is more than one consulting engagement; it does not exist when only one is available, so it needs\r\n // to be populated here\r\n if(this.consultingEngagements.length === 1) {\r\n responsibility.consultingEngagementId = this.consultingEngagements[0].consultingEngagementId;\r\n }\r\n break;\r\n case Core.WorkflowUserTypes.AccountHandler:\r\n //special handling of account handler when consultant looking at it\r\n if(this.isConsultantPerspective) {\r\n responsibility.workflowUserTypeID = Core.WorkflowUserTypes.ConsultantAccountHandler;\r\n responsibility.consultingEngagementId = this.consultingEngagements.find(ce => this._userInstanceService.isInstanceExplicit(ce.instanceId)).consultingEngagementId;\r\n }\r\n //client perspective of account handler\r\n else {\r\n responsibility.workflowUserTypeID = responsibility.translatedWorkflowUserTypeId;\r\n responsibility.consultingEngagementId = null;\r\n }\r\n break;\r\n case Core.WorkflowUserTypes.JurisdictionSpecialist:\r\n responsibility.workflowUserTypeID = Core.WorkflowUserTypes.JurisdictionSpecialist;\r\n\r\n if(this.isConsultantPerspective) {\r\n responsibility.consultingEngagementId = this.consultingEngagements.find(ce => this._userInstanceService.isInstanceExplicit(ce.instanceId)).consultingEngagementId;\r\n }\r\n else {\r\n responsibility.consultingEngagementId = null;\r\n }\r\n break;\r\n case Core.WorkflowUserTypes.User:\r\n //consultant person selected\r\n if (this.isConsultantPerspective) {\r\n responsibility.consultingEngagementId = this.consultingEngagements.find(ce => this._userInstanceService.isInstanceExplicit(ce.instanceId)).consultingEngagementId;\r\n }\r\n //client person selected\r\n else {\r\n responsibility.consultingEngagementId = null;\r\n }\r\n\r\n responsibility.workflowUserTypeID = responsibility.translatedWorkflowUserTypeId;\r\n\r\n if (previousWorkflowUserTypeId === WorkflowUserTypesUI.ConsultingEngagement ||\r\n previousWorkflowUserTypeId === Core.WorkflowUserTypes.AccountHandler) {\r\n responsibility.userID = null;\r\n responsibility.teamID = null;\r\n responsibility.team = {} as Weissman.Model.Workflow.Team;\r\n responsibility.assignee = {} as Core.ContactShortDTO;\r\n }\r\n break;\r\n //NA selected\r\n default:\r\n responsibility.workflowUserTypeID = responsibility.translatedWorkflowUserTypeId;\r\n if (this.isConsultantPerspective) {\r\n responsibility.consultingEngagementId = this.consultingEngagements.find(ce => this._userInstanceService.isInstanceExplicit(ce.instanceId)).consultingEngagementId;\r\n }\r\n else {\r\n responsibility.consultingEngagementId = null;\r\n }\r\n }\r\n\r\n //changing from NA to another user type\r\n if (previousWorkflowUserTypeId === Core.WorkflowUserTypes.NA && responsibility.workflowUserTypeID !== Core.WorkflowUserTypes.NA) {\r\n responsibility.showDatePicker = true;\r\n }\r\n //changing to NA\r\n else if (responsibility.workflowUserTypeID === Core.WorkflowUserTypes.NA) {\r\n responsibility.showDatePicker = false;\r\n responsibility.dateFrom = null;\r\n }\r\n\r\n //no specific user\r\n if (responsibility.workflowUserTypeID !== Core.WorkflowUserTypes.User) {\r\n responsibility.userID = null;\r\n responsibility.teamID = null;\r\n responsibility.team = {} as Weissman.Model.Workflow.Team;\r\n responsibility.assignee = {} as Core.ContactShortDTO;\r\n }\r\n\r\n this.panelData.entityClientServices = _.map(this.panelData.entityClientServices, service => {\r\n service.responsibilities = _.map(service.responsibilities, resp => {\r\n resp.disabledWorkflowUserTypes = this._getDisabledWorkflowUserTypes(resp, service);\r\n return resp;\r\n });\r\n\r\n return service;\r\n });\r\n\r\n // Initially seed data from selected consulting engagement (this might not get called otherwise if there's no dropdown)\r\n if (responsibility.workflowUserTypeID === Core.WorkflowUserTypes.ConsultantAccountHandler) {\r\n this.changeConsultingEngagement(responsibility);\r\n }\r\n }\r\n\r\n showExceptionsLink(status: number): boolean{\r\n return !(this.editMode && (status === null || status === ClientServiceResponsibilityUpdateQueueStatusEnum.Errant));\r\n }\r\n\r\n openExceptionsModal(responsibility: ClientServiceResponsibility, service: EntityClientService) {\r\n this._clientServicesExceptionModalService.openExceptionsModal(this.entity.id, +EntityTypeIds[this.entity.type.toUpperCase()], [service.clientServiceID], [responsibility.propertyTypeID], this.entity.isInactive);\r\n }\r\n\r\n specificIndividualSelected(newIndividual: Core.UserTeamModel, responsibility: ClientServiceResponsibility) {\r\n responsibility.userID = newIndividual.userID;\r\n responsibility.teamID = newIndividual.teamID;\r\n\r\n responsibility.team = {\r\n name: newIndividual.teamName,\r\n teamID: newIndividual.teamID\r\n } as Weissman.Model.Workflow.Team;\r\n\r\n responsibility.assignee = {\r\n efAction: null,\r\n firstName: newIndividual.firstName,\r\n lastName: newIndividual.lastName,\r\n userID: newIndividual.userID\r\n };\r\n }\r\n\r\n changeConsultingEngagement(responsibility: ClientServiceResponsibility): void {\r\n const engagement = _.find(this.consultingEngagements, {consultingEngagementId: responsibility.consultingEngagementId});\r\n\r\n responsibility.userID = engagement.accountHandler?.userId;\r\n responsibility.teamID = engagement.accountHandler?.teamId;\r\n }\r\n\r\n get isParcel(): boolean {\r\n return this.entity.type === 'parcel';\r\n }\r\n\r\n isTaxFeedToggleEnabled(topLevelTaxFeedSetting: boolean): boolean {\r\n return this.isTopLevelCompany\r\n && this.hasTaxFeeds\r\n || (this.isParcel\r\n && this.canEditCompany\r\n && topLevelTaxFeedSetting);\r\n }\r\n\r\n get currentInstanceId(): number{\r\n return this.isConsultantPerspective ? this.consultantsInstanceId : this.entityInstanceId;\r\n }\r\n\r\n private _getInitialValues(): ClientServiceResponsibility {\r\n return {\r\n teamID: null,\r\n userID: null,\r\n assignee: {},\r\n team: {},\r\n workflowUserTypeID: Core.WorkflowUserTypes.NA,\r\n propertyTypeXServiceHasChildExceptions: false,\r\n entityID: this.entity.id,\r\n entityTypeID: EntityTypeIds[this.entity.type.toUpperCase()],\r\n isException: !this.isTopLevelCompany\r\n } as ClientServiceResponsibility;\r\n }\r\n\r\n private async _loadPanel(): Promise {\r\n this.paymentBatchData = undefined;\r\n\r\n this.serverAction = true;\r\n try {\r\n const [aeEntityTypeId, aeEntityId] = this.company\r\n ? [EntityTypeIds.COMPANY, this.company.topLevelCompanyId]\r\n : [this.entity.typeId, this.entity.id];\r\n\r\n [\r\n this.consultingEngagements,\r\n this._propertyTypes,\r\n this.panelData,\r\n this.entityInstanceId,\r\n this.entityTree,\r\n this.taxFeedSettings\r\n ] = await Promise.all(\r\n [\r\n this._consultingEngagementsRepository.getAcceptedEngagements(aeEntityTypeId, aeEntityId),\r\n this._propertyTypeService.get(),\r\n this._csrService.getByEntity(this.entity),\r\n lastValueFrom(this._instanceRepository.getEntityInstanceId(this.entity.type, this.entity.id)),\r\n this._processingService.getEntityTree(this.entity.typeId, this.entity.id, false),\r\n lastValueFrom(this._taxFeedSettingRepository.getByEntity(this.entity.id, this.entity.typeId))\r\n ]\r\n );\r\n\r\n this.topLevelCompanyId = this.entityTree.topLevelCompany\r\n ? this.entityTree.topLevelCompany.entityId\r\n : this.entityTree.subsidiaryCompany.entityId;\r\n\r\n if (this.entity.typeId === EntityTypes.Parcel) {\r\n this.topLevelCompanyTaxFeedSettings = await lastValueFrom(this._taxFeedSettingRepository.getByEntity(this.topLevelCompanyId, EntityTypes.Company));\r\n }\r\n const currentlyRunningUpdates = await lastValueFrom(this._longRunningProcessRepository.getList({\r\n columnFilters: [\r\n {filterProperty: Compliance.LongRunningProcessPropertyEnum.EntityId, filterConditionType: Core.FilterConditionTypeEnum.And, filterValues: [{filterType: Core.FilterTypeEnum.Equals, filterValue: this.topLevelCompanyId.toString() }]},\r\n {filterProperty: Compliance.LongRunningProcessPropertyEnum.LongRunningProcessTypeName, filterConditionType: Core.FilterConditionTypeEnum.And, filterValues: [{filterType: Core.FilterTypeEnum.EndsWith, filterValue: 'Update CSR' }]},\r\n {filterProperty: Compliance.LongRunningProcessPropertyEnum.End, filterConditionType: Core.FilterConditionTypeEnum.And, filterValues: [{filterType: Core.FilterTypeEnum.Blank, filterValue: '' }]},\r\n ],\r\n pagination: {\r\n noPagination: true,\r\n },\r\n allUsers: true,\r\n notAcknowledged: true,\r\n }));\r\n\r\n this.isLongRunningProcessRunning = !!currentlyRunningUpdates.totalRows;\r\n this.hasEditPermission = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, this.entityInstanceId);\r\n this.hasComplianceFeatureView = this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, this.entityInstanceId);\r\n this.isExplicitView = !this._userInstanceService.isCrossInstancePerspective(this.entityInstanceId);\r\n this.isConsultantPerspective = this._userInstanceService.isCrossInstancePerspective(this.entityInstanceId);\r\n this.hasTaxFeeds = this._restrictService.hasInstanceRight(InstanceRights.ALLOWTAXFEEDS);\r\n this.canEditCompany = await this._restrictService.hasCompanyPermission(this.topLevelCompanyId, Core.AccessRightsEnum.Write);\r\n\r\n if (this.entityInstanceId !== RyanInstanceId) {\r\n const instanceInfo = await lastValueFrom(this._instanceRepository.get(this.entityInstanceId));\r\n\r\n if (instanceInfo && instanceInfo.documentIntakeAndProcessingAssignToRyan) {\r\n const responses = await Promise.all([\r\n lastValueFrom(this._documentIntakeLicensedClientRepository.get(this.entityInstanceId)),\r\n this._userGroupService.getForMember(this._userService.getUser().id)\r\n ]);\r\n this._instanceLicensedDISettings = responses[0];\r\n const userGroups = responses[1];\r\n\r\n this.isLicensedDIUser = this._instanceLicensedDISettings\r\n && this._instanceLicensedDISettings.ryanUserGroupId\r\n && userGroups.some(x => x.groupID === this._instanceLicensedDISettings.ryanUserGroupId);\r\n }\r\n }\r\n\r\n if(!this.isExplicitView) {\r\n const ce = this.consultingEngagements.find(x => x.instanceId === this._userInstanceService.getSelectedInstance().instanceId);\r\n if (ce) {\r\n this._consultingEngagementAccountHandlerTitle = this._formatPersonsName(ce.accountHandler.lastName, ce.accountHandler.firstName, ce.accountHandler.teamName);\r\n }\r\n }\r\n\r\n if (this.isConsultantPerspective) {\r\n const ce = this.consultingEngagements.find(x => this._userInstanceService.isInstanceExplicit(x.instanceId));\r\n\r\n if (ce) {\r\n this.consultantsInstanceId = ce.instanceId;\r\n } else {\r\n this.consultantsInstanceId = this.entityInstanceId;\r\n this.isConsultantPerspective = false;\r\n }\r\n }\r\n\r\n this.panelData.entityClientServices = _.flow([\r\n map((service: EntityClientService) => {\r\n service.responsibilities = _.flow([\r\n map((resp: ClientServiceResponsibility) => {\r\n const propType = _.find(this._propertyTypes, {propertyTypeID: resp.propertyTypeID});\r\n resp.propTypeAbbr = propType.propTypeAbbr;\r\n\r\n resp.isException = this._getIsException(resp);\r\n resp.customerHasChildExceptions = this._getHasChildExceptions(resp);\r\n resp.isMyConsultingCompany = this._getIsMyConsultingCompany(resp);\r\n resp.assigneeDisplay = this._getAssigneeDisplay(resp);\r\n resp.translatedWorkflowUserTypeId = this._getTranslatedWorkflowUserTypeId(resp);\r\n resp.disabledWorkflowUserTypes = this._getDisabledWorkflowUserTypes(resp, service);\r\n\r\n return resp;\r\n }),\r\n sortBy('propertyTypeID')\r\n ])(service.responsibilities);\r\n\r\n return service;\r\n }),\r\n sortBy('sequence')\r\n ])(this.panelData.entityClientServices);\r\n }\r\n finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n private _getIsException(responsibility: ClientServiceResponsibility): boolean {\r\n if (!this._userInstanceService.isInstanceImplicit(this.entityInstanceId)\r\n && responsibility.consultingEngagementId) {\r\n return responsibility.customerIsException;\r\n }\r\n\r\n return responsibility.isException;\r\n }\r\n\r\n private _getHasChildExceptions(responsibility: ClientServiceResponsibility): boolean {\r\n if (!this._userInstanceService.isInstanceImplicit(this.entityInstanceId)\r\n && responsibility.consultingEngagementId) {\r\n return responsibility.customerHasChildExceptions;\r\n }\r\n\r\n return responsibility.propertyTypeXServiceHasChildExceptions;\r\n }\r\n\r\n private _getIsMyConsultingCompany(responsibility: ClientServiceResponsibility): boolean {\r\n if (\r\n !responsibility.consultingEngagementId\r\n || this.consultingEngagements.length == 0\r\n || !this.isConsultantPerspective\r\n ) {\r\n return false;\r\n }\r\n\r\n const consultingEngagement = this.consultingEngagements.find(ce => ce.consultingEngagementId === responsibility.consultingEngagementId);\r\n return this._userInstanceService.isInstanceExplicit(consultingEngagement.instanceId);\r\n }\r\n\r\n private _getAssigneeDisplay(responsibility: ClientServiceResponsibility): string {\r\n const workflowUserTypeId = this._lookupWorkflowUserType(responsibility.workflowUserTypeID).value;\r\n\r\n //user is consultant and is looking at company they are consulting on\r\n if (this.isConsultantPerspective && workflowUserTypeId == Core.WorkflowUserTypes.AccountHandler) {\r\n return 'Client Account Handler';\r\n }\r\n\r\n //responsibility is part of a consulting engagement (consultant responsibility)\r\n if (responsibility.consultingEngagementId && this.consultingEngagements.length > 0) {\r\n //client perspective or assigned to different consulting company\r\n if (!this.isConsultantPerspective || !responsibility.isMyConsultingCompany) {\r\n //look up engagement\r\n const engagement = _.find(this.consultingEngagements, (ce) => ce.consultingEngagementId === responsibility.consultingEngagementId);\r\n\r\n if (engagement)\r\n {\r\n return `Consultant- ${engagement.name}`;\r\n }\r\n\r\n return 'Loading...';\r\n }\r\n }\r\n\r\n return this._getResponsibilityLabel(responsibility, workflowUserTypeId);\r\n }\r\n\r\n private _getPlaceholderText(responsibility: ClientServiceResponsibility): string {\r\n const csrUser = this.csrAvailableUsers.find(u => u.userID === responsibility.userID);\r\n const ahUser = this.ahAvailableUsers.find(u => u.userID === responsibility.userID);\r\n const userType = this._lookupWorkflowUserType(responsibility.workflowUserTypeID);\r\n\r\n if(responsibility.assigneeDisplay\r\n && responsibility.userID\r\n && responsibility.teamID\r\n && userType.value != Core.WorkflowUserTypes.ConsultantAccountHandler\r\n && (!csrUser && (!ahUser || this.isConsultantPerspective))) {\r\n return `${responsibility.assigneeDisplay} INACTIVE`;\r\n } else {\r\n return null;\r\n }\r\n }\r\n\r\n private _lookupWorkflowUserType(workflowUserTypeId: number): {value: number; name: string;} {\r\n return this.workflowUserTypes.find( x => x.value == workflowUserTypeId); //lodash find may be faster\r\n }\r\n\r\n private _getResponsibilityLabel(responsibility: ClientServiceResponsibility, workflowUserTypeId: number): string {\r\n\r\n if (workflowUserTypeId == Core.WorkflowUserTypes.User) {\r\n if (!_.isEmpty(responsibility.assignee) && !_.isEmpty(responsibility.team)) {\r\n return this._formatPersonsName(responsibility.assignee.lastName, responsibility.assignee.firstName, responsibility.team.name);\r\n }\r\n //i'm unsure of what should happen if the responsibility is assigned to a user, but there is no assignee and team on the responsibility\r\n }\r\n else {\r\n return this._lookupWorkflowUserType(workflowUserTypeId).name;\r\n }\r\n }\r\n\r\n private _getTranslatedWorkflowUserTypeId(responsibility: ClientServiceResponsibility): number {\r\n if (this.isConsultantPerspective && responsibility.workflowUserTypeID === Core.WorkflowUserTypes.ConsultantAccountHandler) {\r\n return Core.WorkflowUserTypes.AccountHandler;\r\n }\r\n\r\n if (responsibility.consultingEngagementId && !this.isConsultantPerspective && this.isConsultingClient) {\r\n return WorkflowUserTypesUI.ConsultingEngagement;\r\n }\r\n\r\n return responsibility.workflowUserTypeID;\r\n }\r\n\r\n private _checkIfNASelected(service: EntityClientService, propertyTypeId: number): boolean {\r\n // find a certain service among all available client services and check, if this client service has a certain user type selected\r\n // use propertyTypeID for currently edited responsibility as an additional filter\r\n //\r\n return _.some(service?.responsibilities, {\r\n propertyTypeID: propertyTypeId,\r\n workflowUserTypeID: Core.WorkflowUserTypes.NA\r\n });\r\n }\r\n\r\n private _checkServiceHasUserSelected(clientServiceId: number, propertyTypeId: number): boolean {\r\n const service = _.find(this.panelData.entityClientServices, {clientServiceID: clientServiceId});\r\n return !!service && !this._checkIfNASelected(service, propertyTypeId);\r\n }\r\n\r\n private _getDisabledWorkflowUserTypes(clientServiceResponsibility, service: EntityClientService): ClientServicePanelWorkflowUserTypes[] {\r\n let rslt=[];\r\n switch(service.clientServiceID){\r\n case ClientServiceType.ComplianceReturns:\r\n rslt = this._getComplianceReturnsDisabledWorkflowUserTypes(clientServiceResponsibility.propertyTypeID);\r\n break;\r\n case ClientServiceType.Assessments:\r\n rslt = this._getAssessmentsDisabledWorkflowUserTypes(clientServiceResponsibility.propertyTypeID);\r\n break;\r\n case ClientServiceType.TaxBills:\r\n rslt = this._getTaxBillsDisabledWorkflowUserTypes(clientServiceResponsibility.propertyTypeID);\r\n break;\r\n case ClientServiceType.TaxBillTransmit:\r\n rslt = this._getTaxBillTransmitDisabledWorkflowUserTypes(clientServiceResponsibility.propertyTypeID);\r\n break;\r\n case ClientServiceType.Appeals:\r\n rslt = this._getAppealsDisabledWorkflowUserTypes(clientServiceResponsibility.propertyTypeID);\r\n break;\r\n case ClientServiceType.Allocation:\r\n rslt = this._getAllocationDisabledWorkflowUserTypes(clientServiceResponsibility.propertyTypeID);\r\n break;\r\n }\r\n\r\n if (clientServiceResponsibility?.clientServiceResponsibilityUpdateStatus == ClientServiceResponsibilityUpdateQueueStatusEnum.Errant) {\r\n rslt = rslt.concat([Core.WorkflowUserTypes.AccountHandler,\r\n Core.WorkflowUserTypes.ConsultantAccountHandler,\r\n WorkflowUserTypesUI.ConsultingEngagement,\r\n Core.WorkflowUserTypes.JurisdictionSpecialist,\r\n Core.WorkflowUserTypes.User]);\r\n }\r\n\r\n if (this.isConsultantPerspective) {\r\n rslt = rslt.concat([Core.WorkflowUserTypes.NA]);\r\n }\r\n\r\n return rslt;\r\n }\r\n\r\n private _getComplianceReturnsDisabledWorkflowUserTypes(propertyTypeId: number): ClientServicePanelWorkflowUserTypes[] {\r\n const hasAllocationUser = this._checkServiceHasUserSelected(ClientServiceType.Allocation, propertyTypeId);\r\n\r\n return hasAllocationUser ? [Core.WorkflowUserTypes.NA] : [];\r\n }\r\n\r\n private _getTaxBillTransmitDisabledWorkflowUserTypes(propertyTypeId: number): ClientServicePanelWorkflowUserTypes[] {\r\n const hasTaxBillUser = this._checkServiceHasUserSelected(ClientServiceType.TaxBills, propertyTypeId);\r\n\r\n return !hasTaxBillUser\r\n ? [\r\n Core.WorkflowUserTypes.AccountHandler,\r\n Core.WorkflowUserTypes.JurisdictionSpecialist,\r\n Core.WorkflowUserTypes.User,\r\n WorkflowUserTypesUI.ConsultingEngagement\r\n ]\r\n : [];\r\n\r\n }\r\n\r\n private _getTaxBillsDisabledWorkflowUserTypes(propertyTypeId: number) : ClientServicePanelWorkflowUserTypes[] {\r\n const hasTaxBillTransmitUser = this._checkServiceHasUserSelected(ClientServiceType.TaxBillTransmit, propertyTypeId);\r\n const hasAssessmentsUser = this._checkServiceHasUserSelected(ClientServiceType.Assessments, propertyTypeId);\r\n\r\n if(!hasAssessmentsUser) {\r\n return [\r\n Core.WorkflowUserTypes.AccountHandler,\r\n Core.WorkflowUserTypes.JurisdictionSpecialist,\r\n Core.WorkflowUserTypes.User,\r\n WorkflowUserTypesUI.ConsultingEngagement\r\n ];\r\n }\r\n\r\n //an assessments workflow user must be set to be able to have a tax bill transmit user set\r\n if(hasAssessmentsUser && hasTaxBillTransmitUser) {\r\n return [Core.WorkflowUserTypes.NA];\r\n }\r\n\r\n return [];\r\n }\r\n\r\n private _getAllocationDisabledWorkflowUserTypes(propertyTypeId: number): ClientServicePanelWorkflowUserTypes[] {\r\n const hasComplianceUser = this._checkServiceHasUserSelected(ClientServiceType.ComplianceReturns, propertyTypeId);\r\n const hasAssessmentsUser = this._checkServiceHasUserSelected(ClientServiceType.Assessments, propertyTypeId);\r\n\r\n const canAssignPPWorkflowUser = propertyTypeId == PropertyType.Personal\r\n && hasComplianceUser\r\n && hasAssessmentsUser;\r\n\r\n return (propertyTypeId != PropertyType.Personal || !canAssignPPWorkflowUser)\r\n ? [\r\n Core.WorkflowUserTypes.AccountHandler,\r\n Core.WorkflowUserTypes.JurisdictionSpecialist,\r\n Core.WorkflowUserTypes.User,\r\n WorkflowUserTypesUI.ConsultingEngagement,\r\n Core.WorkflowUserTypes.ConsultantAccountHandler\r\n ]\r\n : [];\r\n }\r\n\r\n private _getAssessmentsDisabledWorkflowUserTypes(propertyTypeId: number): ClientServicePanelWorkflowUserTypes[] {\r\n const hasAppealsUser = this._checkServiceHasUserSelected(ClientServiceType.Appeals, propertyTypeId);\r\n const hasTaxBillsUser = this._checkServiceHasUserSelected(ClientServiceType.TaxBills, propertyTypeId);\r\n const hasAllocationsUser = this._checkServiceHasUserSelected(ClientServiceType.Allocation, propertyTypeId);\r\n\r\n return (hasAppealsUser || hasTaxBillsUser || hasAllocationsUser)\r\n ? [Core.WorkflowUserTypes.NA]\r\n : [];\r\n }\r\n\r\n private _getAppealsDisabledWorkflowUserTypes(propertyTypeId: number): ClientServicePanelWorkflowUserTypes[] {\r\n const hasAssessmentsUser = this._checkServiceHasUserSelected(ClientServiceType.Assessments, propertyTypeId);\r\n\r\n return !hasAssessmentsUser\r\n ? [\r\n Core.WorkflowUserTypes.AccountHandler,\r\n Core.WorkflowUserTypes.JurisdictionSpecialist,\r\n Core.WorkflowUserTypes.User,\r\n WorkflowUserTypesUI.ConsultingEngagement\r\n ]\r\n : [];\r\n }\r\n\r\n private _extractDeliveryDetails(entityClientServices: EntityClientService[]): any[] {\r\n return _.flow([\r\n flatMap(x => [\r\n x.taxBillDeliveryDetailsCurrent,\r\n x.deliveryDetailAssessmentCurrent,\r\n x.deliveryDetailBillCurrent,\r\n x.deliveryDetailPPReturnBatchCurrent,\r\n x.deliveryDetailAssessmentAllocationTop\r\n ]),\r\n compact,\r\n reject(x => _.isEmpty(x))\r\n ])(entityClientServices);\r\n }\r\n\r\n private _isFeedSpecificationsUpdated({ feedSpecifications: originalFeedSpecs }, {feedSpecifications: editedFeedSpecs}): boolean {\r\n if(originalFeedSpecs && editedFeedSpecs) {\r\n if (originalFeedSpecs.length !== editedFeedSpecs.length) {\r\n return true;\r\n } else {\r\n return _.some(originalFeedSpecs, (x, i) => (\r\n x.feedSpecificationID !== editedFeedSpecs[i].feedSpecificationID\r\n || x.includedInEmail !== editedFeedSpecs[i].includedInEmail\r\n ));\r\n }\r\n } else {\r\n return true;\r\n }\r\n }\r\n\r\n private _isUserEmpty(prefix: string, userObj: Core.ContactShortDTO): boolean {\r\n if (userObj[`${prefix }UserId`] && userObj[`${prefix }UserId`] != EmptyGuid)\r\n return false;\r\n\r\n return true;\r\n }\r\n\r\n private _getOriginalDeliveryDetail(originalDeliveryDetails, editedDeliveryDetail): any {\r\n if (editedDeliveryDetail.taxBillDeliveryDetailID !== undefined) {\r\n return _.find(originalDeliveryDetails, {\r\n taxBillDeliveryDetailID: editedDeliveryDetail.taxBillDeliveryDetailID\r\n });\r\n }\r\n if (editedDeliveryDetail.deliveryDetailAssessmentID !== undefined) {\r\n return _.find(originalDeliveryDetails, {\r\n deliveryDetailAssessmentID: editedDeliveryDetail.deliveryDetailAssessmentID\r\n });\r\n }\r\n if (editedDeliveryDetail.deliveryDetailBillID !== undefined) {\r\n\r\n // PROBLEM - IS THIS HE WAY IT SHOULD WORK???\r\n // TODO\r\n // WK-6869\r\n const result = _.find(originalDeliveryDetails, item => {\r\n return item.deliveryDetailBillID !== undefined;\r\n });\r\n\r\n // this is how this item was found before, hovwever, somewhere else deliveryDetailBillID is replaced (by parent?)\r\n //{ deliveryDetailBillID: editedDeliveryDetail.deliveryDetailBillID });\r\n\r\n return result;\r\n }\r\n\r\n if (this._isComplianceReturns(editedDeliveryDetail)) {\r\n return _.find(originalDeliveryDetails, x => this._isComplianceReturns(x));\r\n }\r\n\r\n if (this._isAllocations(editedDeliveryDetail)) {\r\n return _.find(originalDeliveryDetails, x => this._isAllocations(x));\r\n }\r\n }\r\n\r\n private _isComplianceReturns(clientService: any): boolean {\r\n if(clientService.deliveryDetails_PPBatchReturnsId) {\r\n return true;\r\n }\r\n\r\n const keys = _.keys(clientService);\r\n const prefixKey = _.find(keys, key => key !== 'efAction');\r\n\r\n return _.startsWith(prefixKey, this.COMPLIANCE_PREFIX);\r\n }\r\n\r\n private _isAllocations(clientService: any): boolean {\r\n if(_.has(clientService, 'drTeamRetrievesWP')) {\r\n return true;\r\n }\r\n\r\n const keys = _.keys(clientService);\r\n const prefixKey = _.find(keys, key => key !== 'efAction');\r\n\r\n return _.startsWith(prefixKey, this.ALLOCATIONS_PREFIX);\r\n }\r\n\r\n private _broadcastRowVersionChange(newRowVersion) {\r\n this._rootScope.$broadcast('WS.COMPANY.ROWVERSION.CHANGED', newRowVersion);\r\n }\r\n\r\n private _formatPersonsName(lastName: string, firstName: string, teamName: string){\r\n return `${lastName}, ${firstName} (${teamName})`;\r\n }\r\n}\r\n\r\n","export enum ReturnSettingsViewModelEnum {\r\n ReturnValues,\r\n Settings\r\n}\r\n\r\nexport enum GeneralReturnSettingLookupTypeEnum {\r\n EntityName = Compliance.GeneralReturnSettingLookupTypeEnum.EntityName as number,\r\n ContactAddress = Compliance.GeneralReturnSettingLookupTypeEnum.ContactAddress as number,\r\n EntityAddress = Compliance.GeneralReturnSettingLookupTypeEnum.EntityAddress as number,\r\n ContactPhone = Compliance.GeneralReturnSettingLookupTypeEnum.ContactPhone as number\r\n}\r\n\r\nexport enum GeneralReturnSettingStateEnum {\r\n Nominal = Compliance.GeneralReturnSettingStateEnum.Nominal as number,\r\n VariesBetweenParcels = Compliance.GeneralReturnSettingStateEnum.VariesBetweenParcels as number,\r\n DifferentForTopCompany = Compliance.GeneralReturnSettingStateEnum.DifferentForTopCompany as number\r\n}\r\n\r\nexport enum ReturnSettingsLookupType {\r\n Name,\r\n Address,\r\n Phone\r\n}\r\n\r\nexport enum ReturnSettingsSettingTypeEnum {\r\n OwnerContact = Compliance.ReturnSettingsSettingTypeEnum.OwnerContact as number,\r\n AccountingContact = Compliance.ReturnSettingsSettingTypeEnum.AccountingContact as number,\r\n PreparerContact = Compliance.ReturnSettingsSettingTypeEnum.PreparerContact as number,\r\n SignerContact = Compliance.ReturnSettingsSettingTypeEnum.SignerContact as number,\r\n Entity = Compliance.ReturnSettingsSettingTypeEnum.Entity as number\r\n}\r\n\r\nexport enum ReturnSettingsEntityTypeEnum {\r\n Company = Compliance.ReturnSettingsEntityTypeEnum.Company as number,\r\n Parcel = Compliance.ReturnSettingsEntityTypeEnum.Parcel as number,\r\n Return = Compliance.ReturnSettingsEntityTypeEnum.Return as number\r\n}\r\n\r\nexport enum GeneralReturnSettingLookupEnum {\r\n EntityNameTopLevelCompany = Compliance.GeneralReturnSettingLookupEnum.EntityNameTopLevelCompany as number,\r\n EntityNameCompany = Compliance.GeneralReturnSettingLookupEnum.EntityNameCompany as number,\r\n EntityNameSite = Compliance.GeneralReturnSettingLookupEnum.EntityNameSite as number,\r\n EntityNameParcelAssessee = Compliance.GeneralReturnSettingLookupEnum.EntityNameParcelAssessee as number,\r\n ContactAddressSettingName = Compliance.GeneralReturnSettingLookupEnum.ContactAddressSettingName as number,\r\n ContactAddressTopLevelCompany = Compliance.GeneralReturnSettingLookupEnum.ContactAddressTopLevelCompany as number,\r\n ContactAddressCompany = Compliance.GeneralReturnSettingLookupEnum.ContactAddressCompany as number,\r\n ContactAddressSite = Compliance.GeneralReturnSettingLookupEnum.ContactAddressSite as number,\r\n ContactAddressParcel = Compliance.GeneralReturnSettingLookupEnum.ContactAddressParcel as number,\r\n ContactAddressBlank = Compliance.GeneralReturnSettingLookupEnum.ContactAddressBlank as number,\r\n EntityAddressTopLevelCompany = Compliance.GeneralReturnSettingLookupEnum.EntityAddressTopLevelCompany as number,\r\n EntityAddressCompany = Compliance.GeneralReturnSettingLookupEnum.EntityAddressCompany as number,\r\n EntityAddressSite = Compliance.GeneralReturnSettingLookupEnum.EntityAddressSite as number,\r\n EntityAddressParcel = Compliance.GeneralReturnSettingLookupEnum.EntityAddressParcel as number,\r\n EntityAddressBlank = Compliance.GeneralReturnSettingLookupEnum.EntityAddressBlank as number,\r\n ContactPhoneSettingName = Compliance.GeneralReturnSettingLookupEnum.ContactPhoneSettingName as number,\r\n ContactPhoneBlank = Compliance.GeneralReturnSettingLookupEnum.ContactPhoneBlank as number,\r\n ContactAddressCompanyAlternateAddress = Compliance.GeneralReturnSettingLookupEnum.ContactAddressCompanyAlternateAddress as number,\r\n EntityAddressCompanyAlternateAddress = Compliance.GeneralReturnSettingLookupEnum.EntityAddressCompanyAlternateAddress as number,\r\n ContactAddressAgent = Compliance.GeneralReturnSettingLookupEnum.ContactAddressAgent as number,\r\n EntityAddressAgent = Compliance.GeneralReturnSettingLookupEnum.EntityAddressAgent as number,\r\n ContactPhoneAgent = Compliance.GeneralReturnSettingLookupEnum.ContactPhoneAgent as number\r\n}\r\n\r\nexport enum TaskTypes {\r\n PPBatchReturnFileReturns = Core.TaskTypes.PPBatchReturnFileReturns as number,\r\n PPBatchReturnLoadData = Core.TaskTypes.PPBatchReturnLoadData as number,\r\n PPBatchReturnPrepareReturns = Core.TaskTypes.PPBatchReturnPrepareReturns as number,\r\n PPBatchReturnDigitiallySignReturns = Core.TaskTypes.PPBatchReturnDigitiallySignReturns as number,\r\n PPBatchReturnReviewReturns = Core.TaskTypes.PPBatchReturnReviewReturns as number,\r\n PPBatchReturnApproveReturns = Core.TaskTypes.PPBatchReturnApproveReturns as number,\r\n PPBatchReturnFinalizeReturns = Core.TaskTypes.PPBatchReturnFinalizeReturns as number,\r\n PPReturnFiling = Core.TaskTypes.PPReturnFiling as number\r\n}\r\n\r\nexport enum TaskProcessingActions {\r\n RescindTask = Core.TaskProcessingActions.RescindTask as number,\r\n ReassignTask = Core.TaskProcessingActions.ReassignTask as number\r\n}\r\n\r\nexport enum ReturnSignActions {\r\n Sign = 1,\r\n Skip = 2\r\n}\r\n","export class ExtendedModelBase {\r\n constructor(model: T) {\r\n this._model = model;\r\n }\r\n\r\n private _model: T;\r\n\r\n get model(): T {\r\n return this._model;\r\n }\r\n}","import { ExtendedModelBase } from '../../Models/extendedModelBase';\r\n\r\nexport class ExtendedContactModel extends ExtendedModelBase {\r\n constructor(model: Core.ContactModel) {\r\n super(model);\r\n }\r\n\r\n get displayName(): string {\r\n return `${this.model.firstName} ${this.model.lastName}`;\r\n }\r\n}\r\n\r\nexport class ExtendedContactShortModel extends ExtendedModelBase {\r\n constructor(model: Core.ContactShortModel) {\r\n super(model);\r\n }\r\n\r\n get displayName(): string {\r\n return `${this.model.firstName} ${this.model.lastName}`;\r\n }\r\n}\r\n\r\nexport class ExtendedUserTeamModel extends ExtendedModelBase {\r\n constructor(model: Core.UserTeamModel) {\r\n super(model);\r\n }\r\n\r\n get displayName(): string {\r\n return `${this.model.firstName} ${this.model.lastName} ${this.model.teamName ? ` (${this.model.teamName})`: ''}`;\r\n }\r\n}\r\n","import { HelpContent } from '../../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const RETURN_SETTINGS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'return-info.return-values',\r\n tooltipText: 'Values that will appear on the return form. Order of precedence: Return Override, Parcel, Sub Company, Company.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'return-info.settings',\r\n tooltipText: 'View and edit values that will appear on the return form. Order of precedence: Return Override, Parcel, Sub Company, Company.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'return-info.legal-entity',\r\n tooltipText: 'Legal entity name and address as it will appear on return form.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'return-info.business-dba',\r\n tooltipText: 'Business/DBA name and address as it will appear on return form.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'return-info.taxpayer',\r\n tooltipText: 'Taxpayer name and address as it will appear on return form.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'return-info.owner',\r\n tooltipText: 'Owner name and address as it will appear on return form.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'return-info.accounting',\r\n tooltipText: 'Accounting representatives\\' name and address as it will appear on return form.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'return-info.preparer',\r\n tooltipText: 'Preparers\\' name and address as it will appear on return form.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'return-info.signer',\r\n tooltipText: 'Signers\\' name and address as it will appear on return form. If wet signature not required, signature will also be used from this entity.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'return-info.allow-wet-signature-override',\r\n tooltipText: 'Permit electronic signature in jurisdictions that require a wet signature.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'return-info.sc-alt-lien-date',\r\n tooltipText: 'Please select an alternate lien date for South Carolina returns if the company fiscal close date is not 12/31. This date may not be overridden at the subsidiary, parcel, or return batch.\\n\\nSouth Carolina BPP Returns are due four months after the accounting closing period. The accounting closing period refers to the fiscal year end, when the accounting books are closed for Income Tax purposes.',\r\n isMultiLine: true,\r\n hasIcon: false\r\n }\r\n];\r\n","
\r\n{{lookupValue}}\r\n
\r\n\r\n \r\n\r\n","import { Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges } from '@angular/core';\r\nimport { GeneralReturnSettingLookupEnum, ReturnSettingsEntityTypeEnum, ReturnSettingsLookupType, ReturnSettingsSettingTypeEnum, ReturnSettingsViewModelEnum } from '../../../Models/enums';\r\n\r\n@Component({\r\n selector: 'return-settings-entity-attribute',\r\n templateUrl: './returnSettingsEntityAttribute.component.html'\r\n})\r\nexport class ReturnSettingsEntityAttributeComponent implements OnInit, OnChanges{\r\n @Input() lookupOptions: Compliance.GeneralReturnSettingLookupModel[];\r\n @Input() isTopLevelCompany: boolean;\r\n @Input() currentLookupId: string;\r\n @Input() parentLookupId: string;\r\n @Input() isReadonly: boolean;\r\n @Input() viewMode: ReturnSettingsViewModelEnum;\r\n @Input() currentValue: string;\r\n @Input() parentValue: string;\r\n @Input() currentSettings: Compliance.GeneralReturnSettingModel;\r\n @Input() parentSettings: Compliance.GeneralReturnSettingModel;\r\n @Input() lookupType: ReturnSettingsLookupType;\r\n @Input() settingType: ReturnSettingsSettingTypeEnum;\r\n @Input() entityType: ReturnSettingsEntityTypeEnum;\r\n @Input() contactName: string;\r\n @Input() optionSettingNameId?: GeneralReturnSettingLookupEnum;\r\n @Input() optionBlankId?: GeneralReturnSettingLookupEnum;\r\n\r\n @Output() changed: EventEmitter = new EventEmitter();\r\n\r\n ViewModelEnum = ReturnSettingsViewModelEnum;\r\n ReturnSettingsEntityTypeEnum = ReturnSettingsEntityTypeEnum;\r\n options: Compliance.GeneralReturnSettingLookupModel[];\r\n\r\n ngOnInit(): void {\r\n this.options = this.lookupOptions.map(i => ({... i}));\r\n this.renameSettingNameOption(this.contactName);\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.contactName && changes.contactName.previousValue !== changes.contactName.currentValue && this.options) {\r\n this.renameSettingNameOption(changes.contactName.currentValue);\r\n }\r\n }\r\n\r\n private renameSettingNameOption(contactName: string): void{\r\n if (this.options) {\r\n const settingNameOption = this.options.find(i => i.lookupId === (+this.optionSettingNameId || 0).toLocaleString());\r\n if (settingNameOption){\r\n contactName = (contactName || '').trim();\r\n if (contactName === '[Blank]' || contactName === '' || !contactName || this.entityType === ReturnSettingsEntityTypeEnum.Return){\r\n switch (this.settingType){\r\n case ReturnSettingsSettingTypeEnum.OwnerContact:\r\n contactName = 'Owner Contact';\r\n break;\r\n case ReturnSettingsSettingTypeEnum.AccountingContact:\r\n contactName = 'Accounting Contact';\r\n break;\r\n case ReturnSettingsSettingTypeEnum.PreparerContact:\r\n contactName = 'Preparer Contact';\r\n break;\r\n case ReturnSettingsSettingTypeEnum.SignerContact:\r\n contactName = 'Signer Contact';\r\n break;\r\n }\r\n }\r\n\r\n settingNameOption.name = `${contactName}'s`;\r\n }\r\n }\r\n }\r\n\r\n private _hasChanges: boolean;\r\n\r\n get lookupHasOverride(): boolean{\r\n return !this.isTopLevelCompany && this.currentLookupId && this.currentLookupId !== this.parentLookupId;\r\n }\r\n\r\n get lookupId(): string {\r\n return (this.isTopLevelCompany || this.lookupHasOverride || this.entityType === ReturnSettingsEntityTypeEnum.Return) ? this.currentLookupId : this.parentLookupId;\r\n }\r\n\r\n set lookupId(value: string) {\r\n if (value === this.parentLookupId && this.entityType !== ReturnSettingsEntityTypeEnum.Return && !this.isTopLevelCompany){\r\n value = null;\r\n }\r\n\r\n this._hasChanges = true;\r\n this.currentLookupId = value;\r\n\r\n this.changed.emit(value);\r\n }\r\n\r\n get hasChanges(): boolean {\r\n return this._hasChanges;\r\n }\r\n\r\n get lookupValue(): string{\r\n return (this.isTopLevelCompany || this.lookupHasOverride || this.parentLookupId === (+this.optionSettingNameId || 0).toLocaleString()) ? this.currentValue : this.parentValue;\r\n }\r\n}\r\n","
\r\n{{lookupValue}}\r\n
\r\n\r\n \r\n\r\n","import { Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges } from '@angular/core';\r\nimport { GeneralReturnSettingLookupEnum, ReturnSettingsEntityTypeEnum, ReturnSettingsLookupType, ReturnSettingsSettingTypeEnum, ReturnSettingsViewModelEnum } from '../../../Models/enums';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\n@Component({\r\n selector: 'return-settings-name-attribute',\r\n templateUrl: './returnSettingsNameAttribute.component.html'\r\n})\r\nexport class ReturnSettingsNameAttributeComponent implements OnInit, OnChanges{\r\n\r\n constructor(private readonly _toastsManager: ToastrService) {\r\n }\r\n\r\n @Input() lookupOptions: Compliance.GeneralReturnSettingLookupModel[];\r\n @Input() isTopLevelCompany: boolean;\r\n @Input() currentLookupId: number;\r\n @Input() parentLookupId: number;\r\n @Input() isReadonly: boolean;\r\n @Input() viewMode: ReturnSettingsViewModelEnum;\r\n @Input() currentValue: string;\r\n @Input() parentValue: string;\r\n @Input() currentSettings: Compliance.GeneralReturnSettingModel;\r\n @Input() parentSettings: Compliance.GeneralReturnSettingModel;\r\n @Input() lookupType: ReturnSettingsLookupType;\r\n @Input() settingType: ReturnSettingsSettingTypeEnum;\r\n @Input() entityType: ReturnSettingsEntityTypeEnum;\r\n @Input() contactName: string;\r\n @Input() optionSettingNameId?: GeneralReturnSettingLookupEnum;\r\n @Input() optionBlankId?: GeneralReturnSettingLookupEnum;\r\n\r\n @Output() changed: EventEmitter = new EventEmitter();\r\n\r\n ViewModelEnum = ReturnSettingsViewModelEnum;\r\n ReturnSettingsEntityTypeEnum = ReturnSettingsEntityTypeEnum;\r\n options: Compliance.GeneralReturnSettingLookupModel[];\r\n\r\n ngOnInit(): void {\r\n this.options = this.lookupOptions.map(i => ({... i}));\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n }\r\n\r\n private _hasChanges: boolean;\r\n\r\n get lookupHasOverride(): boolean{\r\n return !this.isTopLevelCompany && this.currentLookupId && this.currentLookupId !== this.parentLookupId;\r\n }\r\n\r\n get lookupId(): string {\r\n const result = (this.isTopLevelCompany || this.lookupHasOverride || this.entityType === ReturnSettingsEntityTypeEnum.Return) ? this.currentLookupId : this.parentLookupId;\r\n return (result || 0).toLocaleString();\r\n }\r\n\r\n set lookupId(value: string) {\r\n if (+value === this.parentLookupId && this.entityType !== ReturnSettingsEntityTypeEnum.Return && !this.isTopLevelCompany){\r\n value = null;\r\n }\r\n\r\n this._hasChanges = true;\r\n this.currentLookupId = value ? +value : null;\r\n\r\n this.changed.emit(this.currentLookupId);\r\n }\r\n\r\n get hasChanges(): boolean {\r\n return this._hasChanges;\r\n }\r\n\r\n get lookupValue(): string{\r\n return (this.isTopLevelCompany || this.lookupHasOverride || this.parentLookupId === this.optionSettingNameId) ? this.currentValue : this.parentValue;\r\n }\r\n\r\n selectionChanged(selectedValue: number) {\r\n if (+selectedValue === Compliance.GeneralReturnSettingLookupEnum.SiteSiteCharacteristicDBA) {\r\n this._toastsManager.success('Site will be used when DBA is not available');\r\n }\r\n }\r\n}\r\n","\r\n {{ model.displayName }} \r\n\r\n\r\n
\r\n {{contactDisplay}}{{representationDisplay}}\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n","import { from as observableFrom, lastValueFrom, Observable } from 'rxjs';\r\nimport { map, mergeMap } from 'rxjs/operators';\r\nimport { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { Constants } from '../../../../../constants.new';\r\nimport { ExtendedContactModel } from '../../../Models/extendedContactModel';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { ReturnSettingsEntityTypeEnum, ReturnSettingsViewModelEnum } from '../../../Models/enums';\r\nimport { ReturnSettingsRepository } from '../../../../Repositories';\r\n\r\n@Component({\r\n selector: 'return-settings-contact-attribute',\r\n templateUrl: './returnSettingsContactAttribute.component.html'\r\n})\r\nexport class ReturnSettingsContactAttributeComponent implements OnInit{\r\n constructor(\r\n private readonly _constants: Constants,\r\n private readonly _returnSettingsRepository: ReturnSettingsRepository\r\n ) { }\r\n\r\n @Input() isTopLevelCompany: boolean;\r\n @Input() currentContact: Core.ContactModel;\r\n @Input() parentContact: Core.ContactModel;\r\n @Input() currentRepresentationId: Compliance.RepresentationTypeEnum;\r\n @Input() parentRepresentationId: Compliance.RepresentationTypeEnum;\r\n @Input() currentRepresentationValue: string;\r\n @Input() parentRepresentationValue: string;\r\n @Input() isReadonly: boolean;\r\n @Input() viewMode: ReturnSettingsViewModelEnum;\r\n @Input() currentContactId: number;\r\n @Input() parentContactId: number;\r\n @Input() entityType: ReturnSettingsEntityTypeEnum;\r\n @Input() entityId: ReturnSettingsEntityTypeEnum;\r\n @Input() parentContactNameLookupValue: string;\r\n\r\n @Output() contactChanged: EventEmitter = new EventEmitter();\r\n @Output() representationChanged: EventEmitter = new EventEmitter();\r\n\r\n representationTypes: Compliance.NameValuePair[];\r\n contactFilter: string = '';\r\n contacts$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.contactFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterContacts(token)));\r\n ViewModelEnum = ReturnSettingsViewModelEnum;\r\n ReturnSettingsEntityTypeEnum = ReturnSettingsEntityTypeEnum;\r\n\r\n private _hasChanges: boolean;\r\n private _contactNoResult: boolean = false;\r\n\r\n ngOnInit(): void {\r\n let representationTypes = this._constants.RepresentationTypes;\r\n if (this.entityType === ReturnSettingsEntityTypeEnum.Return){\r\n representationTypes = [{ name: '', value: null }].concat(representationTypes);\r\n }\r\n this.representationTypes = representationTypes;\r\n\r\n this._setContactFilterToCurrentValue();\r\n }\r\n\r\n get contactHasOverride(): boolean{\r\n return !this.isTopLevelCompany && this.currentContactId && this.currentContactId !== this.parentContactId;\r\n }\r\n\r\n get contact(): Core.ContactModel {\r\n return (this.isTopLevelCompany || this.contactHasOverride || this.entityType === ReturnSettingsEntityTypeEnum.Return)\r\n ? this.currentContact\r\n : this.parentContact;\r\n }\r\n\r\n set contact(value: Core.ContactModel) {\r\n let contactId: number;\r\n\r\n if (value){\r\n if (this.parentContact && value.contactID === this.parentContact.contactID)\r\n {\r\n contactId = null;\r\n }\r\n else{\r\n contactId = value.contactID;\r\n }\r\n }\r\n else{\r\n contactId = null;\r\n }\r\n\r\n if (this.currentContactId !== contactId) {\r\n const extendedContact = new ExtendedContactModel({\r\n contactID: contactId,\r\n firstName: value ? value.firstName : '',\r\n lastName: value ? value.lastName : ''\r\n } as Core.ContactModel);\r\n this.contactChanged.emit(extendedContact);\r\n }\r\n\r\n this._hasChanges = true;\r\n this.currentContact = value;\r\n this.currentContactId = contactId;\r\n }\r\n\r\n get representationHasOverride(): boolean {\r\n // owner representation type is 0, so unable to use truthy check\r\n return !this.isTopLevelCompany &&\r\n this.currentRepresentationId !== null &&\r\n this.currentRepresentationId !== undefined &&\r\n this.currentRepresentationId !== this.parentRepresentationId;\r\n }\r\n\r\n get representationId(): Compliance.RepresentationTypeEnum {\r\n return (this.isTopLevelCompany || this.representationHasOverride || this.entityType === ReturnSettingsEntityTypeEnum.Return)\r\n ? this.currentRepresentationId\r\n : this.parentRepresentationId;\r\n }\r\n\r\n set representationId(value: Compliance.RepresentationTypeEnum) {\r\n if (value === this.parentRepresentationId && this.entityType !== ReturnSettingsEntityTypeEnum.Return){\r\n value = null;\r\n }\r\n\r\n this._hasChanges = true;\r\n this.currentRepresentationId = value;\r\n\r\n this.representationChanged.emit(value);\r\n }\r\n\r\n get hasChanges(): boolean {\r\n return this._hasChanges;\r\n }\r\n\r\n onContactSelected(match: TypeaheadMatch): void {\r\n this.contact = (match.item as ExtendedContactModel).model;\r\n this.contactFilter = match.value;\r\n this._hasChanges = true;\r\n }\r\n\r\n onContactBlur(): void {\r\n if (this.contactFilter.trim() === ''){\r\n if (this.entityType === ReturnSettingsEntityTypeEnum.Return) {\r\n this.contact = null;\r\n }\r\n else {\r\n this._setContactFilterToCurrentValue();\r\n }\r\n }\r\n else if (this._contactNoResult) {\r\n this._setContactFilterToCurrentValue();\r\n }\r\n }\r\n\r\n get contactDisplay(): string {\r\n if (this.entityType === ReturnSettingsEntityTypeEnum.Return && !this.contactHasOverride){\r\n return this.parentContactNameLookupValue;\r\n }\r\n else {\r\n const contact = (this.isTopLevelCompany || this.contactHasOverride) ? this.currentContact : this.parentContact;\r\n return contact ? `${contact.firstName} ${contact.lastName}` : '';\r\n }\r\n }\r\n\r\n onRemoveContactOverride(): void {\r\n this.contact = null;\r\n this._setContactFilterToCurrentValue();\r\n }\r\n\r\n get contactInfo(): string{\r\n let result = this.contactDisplay;\r\n\r\n const representationValue = (this.representationHasOverride || this.entityType === ReturnSettingsEntityTypeEnum.Return)? this.currentRepresentationValue : this.parentRepresentationValue;\r\n if (result && representationValue) {\r\n result += ` (${representationValue})`;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n get representationDisplay(): string{\r\n let result = '';\r\n\r\n const representationValue = this.representationHasOverride ? this.currentRepresentationValue : this.parentRepresentationValue;\r\n if (this.contactDisplay && representationValue) {\r\n result = ` (${representationValue})`;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n private _filterContacts(filter: string): Observable {\r\n\r\n const searchModel: Compliance.GeneralReturnSettingsContactSearchModel = {\r\n filter: filter,\r\n entityId: this.entityId,\r\n entityType: this.entityType as unknown as Compliance.ReturnSettingsEntityTypeEnum,\r\n includeInactive: false,\r\n pageNumber: 1,\r\n pageSize: 50\r\n };\r\n\r\n\r\n return observableFrom(lastValueFrom(this._returnSettingsRepository.searchContacts(searchModel))).pipe(\r\n map(contacts => {\r\n if (contacts && contacts.length === 0){\r\n this._contactNoResult = true;\r\n }\r\n\r\n contacts.unshift({contactID: -1, firstName: '[Blank]', lastName: ''} as Core.ContactModel);\r\n\r\n return contacts.map(contact =>\r\n new ExtendedContactModel({\r\n contactID: contact.contactID,\r\n firstName: contact.firstName,\r\n lastName: contact.lastName\r\n } as Core.ContactModel));\r\n }));\r\n }\r\n\r\n private _setContactFilterToCurrentValue(): void {\r\n let result = '';\r\n\r\n if(this.isTopLevelCompany || this.contactHasOverride || this.entityType === ReturnSettingsEntityTypeEnum.Return) {\r\n if (this.currentContactId === -1) {\r\n result = '[Blank]'\r\n } else if (this.currentContact) {\r\n result = this.contactDisplay;\r\n }\r\n } else {\r\n if (this.parentContactId === -1) {\r\n result = '[Blank]'\r\n } else if (this.parentContact) {\r\n result = this.contactDisplay;\r\n }\r\n }\r\n\r\n this.contactFilter = result;\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
Show
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Wet Signature Override\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n (Various between returns)\r\n
\r\n
\r\n
0\">\r\n
\r\n \r\n SC Alternative Lien Date\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
Owner
\r\n
Name
\r\n
Mailing Address
\r\n
 
\r\n
\r\n
\r\n
Legal Entity
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
Business/DBA
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
Taxpayer
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
Contact
\r\n
Name
\r\n
Mailing Address
\r\n
Phone / Fax / Email
\r\n
\r\n
\r\n
Owner
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
Accounting
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
Preparer
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
Signer
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy, Input, Output, EventEmitter } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { ReturnSettingsRepository } from '../../../../Repositories';\r\nimport { GeneralReturnSettingLookupEnum, GeneralReturnSettingLookupTypeEnum, GeneralReturnSettingStateEnum, ReturnSettingsEntityTypeEnum, ReturnSettingsLookupType, ReturnSettingsSettingTypeEnum, ReturnSettingsViewModelEnum } from '../../../Models/enums';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { IComponentRef } from '../../../Models/iComponentRef';\r\nimport { ExtendedContactModel } from '../../../Models/extendedContactModel';\r\nimport { RETURN_SETTINGS_HELP } from './returnSettings.component.help';\r\nimport { HelpService } from '../../../../../UI-Lib/Help-Tooltip';\r\n\r\n@Component({\r\n selector: 'return-settings',\r\n templateUrl: './returnSettings.component.html',\r\n styleUrls: ['./returnSettings.component.scss']\r\n})\r\nexport class ReturnSettingsComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _returnSettingsRepository: ReturnSettingsRepository,\r\n private readonly _toastsManager: ToastrService,\r\n private readonly _helpService: HelpService) { }\r\n\r\n @Input() entityId: number;\r\n @Input() entityType: ReturnSettingsEntityTypeEnum;\r\n\r\n @Output() changed: EventEmitter = new EventEmitter();\r\n @Output() onInitialized: EventEmitter = new EventEmitter();\r\n\r\n settings: Compliance.GeneralReturnSettingsEntityModel;\r\n\r\n LookupTypeEnum: typeof GeneralReturnSettingLookupTypeEnum = GeneralReturnSettingLookupTypeEnum;\r\n\r\n ViewModelEnum: typeof ReturnSettingsViewModelEnum = ReturnSettingsViewModelEnum;\r\n viewMode: ReturnSettingsViewModelEnum = ReturnSettingsViewModelEnum.ReturnValues;\r\n ReturnSettingsLookupType: typeof ReturnSettingsLookupType = ReturnSettingsLookupType;\r\n ReturnSettingsSettingTypeEnum: typeof ReturnSettingsSettingTypeEnum = ReturnSettingsSettingTypeEnum;\r\n GeneralReturnSettingLookupEnum: typeof GeneralReturnSettingLookupEnum = GeneralReturnSettingLookupEnum;\r\n GeneralReturnSettingStateEnum: typeof GeneralReturnSettingStateEnum = GeneralReturnSettingStateEnum;\r\n\r\n hideWetSignatureOverrideWarning: boolean = true;\r\n redWetSignatureOverrideLabelText: boolean = false;\r\n\r\n private _lookupOptions: Compliance.GeneralReturnSettingLookupModel[] = [];\r\n private _editMode: boolean = false;\r\n private _currentSettingsCopy: Compliance.GeneralReturnSettingModel;\r\n private _ownerContactName: string;\r\n private _accountingContactName: string;\r\n private _preparerContactName: string;\r\n private _signerContactName: string;\r\n private _isDisabled: boolean = false;\r\n\r\n async ngOnInit(): Promise {\r\n await this._loadSettings();\r\n this._helpService.setContent(RETURN_SETTINGS_HELP);\r\n\r\n const ref: IComponentRef = {\r\n save: this.save.bind(this),\r\n cancel: this.cancel.bind(this),\r\n edit: this.edit.bind(this),\r\n getSaveModel: this._getSaveModel.bind(this),\r\n load: this._loadSettings.bind(this),\r\n isDisabled: this.isDisabled.bind(this)\r\n };\r\n\r\n this.onInitialized.emit(ref);\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n async save(): Promise {\r\n switch(this.entityType) {\r\n case ReturnSettingsEntityTypeEnum.Company:\r\n this.settings = await lastValueFrom(this._returnSettingsRepository.saveByCompany(this.entityId, this.settings));\r\n break;\r\n case ReturnSettingsEntityTypeEnum.Parcel:\r\n this.settings = await lastValueFrom(this._returnSettingsRepository.saveByParcel(this.entityId, this.settings));\r\n break;\r\n case ReturnSettingsEntityTypeEnum.Return:\r\n this.settings = await lastValueFrom(this._returnSettingsRepository.saveByReturn(this.entityId, this.settings));\r\n break;\r\n }\r\n this._currentSettingsCopy = null;\r\n this.hasChanges = false;\r\n this.editMode = false;\r\n\r\n this._refreshWetSignatureOverrideSwitch();\r\n }\r\n\r\n getLookupOptions(lookupType: GeneralReturnSettingLookupTypeEnum){\r\n const lookupTypeId = +lookupType as Compliance.GeneralReturnSettingLookupTypeEnum;\r\n\r\n const options = this._lookupOptions.filter(i => i.lookupTypeId === lookupTypeId);\r\n\r\n if (this.entityType === ReturnSettingsEntityTypeEnum.Return){\r\n options.unshift({lookupId: null, name: '', lookupTypeId: lookupTypeId});\r\n }\r\n\r\n return options;\r\n }\r\n\r\n set hasChanges(value: boolean){\r\n this.changed.emit(value);\r\n }\r\n\r\n async cancel(): Promise {\r\n this.settings.currentGeneralReturnSetting = this._currentSettingsCopy;\r\n this._currentSettingsCopy = null;\r\n this.editMode = false;\r\n }\r\n\r\n async edit(): Promise{\r\n this._currentSettingsCopy = {... this.settings.currentGeneralReturnSetting};\r\n this.editMode = true;\r\n }\r\n\r\n get editMode(): boolean{\r\n return this._editMode;\r\n }\r\n\r\n set editMode(value: boolean){\r\n this._editMode = value;\r\n\r\n if (value) {\r\n this.viewMode = ReturnSettingsViewModelEnum.Settings;\r\n }\r\n }\r\n\r\n private _getSaveModel(): Compliance.GeneralReturnSettingsEntityModel{\r\n return this.settings;\r\n }\r\n\r\n private async _loadSettings(): Promise {\r\n let response: Compliance.GeneralReturnSettingsEntityModel = {} as Compliance.GeneralReturnSettingsEntityModel;\r\n\r\n try {\r\n const promises: Promise[] = [\r\n lastValueFrom(this._returnSettingsRepository.getLookupOptions({\r\n entityType: +this.entityType,\r\n entityId: this.entityId\r\n } as Compliance.GeneralReturnSettingsGetOptionsModel)),\r\n ];\r\n\r\n switch (this.entityType) {\r\n case ReturnSettingsEntityTypeEnum.Company:\r\n promises.push(lastValueFrom(this._returnSettingsRepository.getByCompany(this.entityId)));\r\n break;\r\n case ReturnSettingsEntityTypeEnum.Parcel:\r\n promises.push(lastValueFrom(this._returnSettingsRepository.getByParcel(this.entityId)));\r\n break;\r\n case ReturnSettingsEntityTypeEnum.Return:\r\n promises.push(lastValueFrom(this._returnSettingsRepository.getByReturn(this.entityId)));\r\n break;\r\n }\r\n\r\n const results = await Promise.all(promises);\r\n this._lookupOptions = results[0];\r\n response = results[1];\r\n } catch (e) {\r\n if (e && e.status === 404) {\r\n // handled exception; general return settings are not set (hence the 404)\r\n } else {\r\n throw e;\r\n }\r\n }\r\n\r\n this.settings = response;\r\n\r\n if (!this.settings.parentGeneralReturnSetting) {\r\n this.settings.parentGeneralReturnSetting = {};\r\n }\r\n\r\n if (!this.settings.currentGeneralReturnSetting) {\r\n this.settings.currentGeneralReturnSetting = {};\r\n }\r\n\r\n const ownerContact = this.settings.currentGeneralReturnSetting.ownerContact || this.settings.parentGeneralReturnSetting.ownerContact;\r\n if (ownerContact) {\r\n this._ownerContactName = new ExtendedContactModel(ownerContact).displayName;\r\n }\r\n\r\n const accountingContact = this.settings.currentGeneralReturnSetting.accountingContact || this.settings.parentGeneralReturnSetting.accountingContact;\r\n if (accountingContact) {\r\n this._accountingContactName = new ExtendedContactModel(accountingContact).displayName;\r\n }\r\n\r\n const preparerContact = this.settings.currentGeneralReturnSetting.preparerContact || this.settings.parentGeneralReturnSetting.preparerContact;\r\n if (preparerContact) {\r\n this._preparerContactName = new ExtendedContactModel(preparerContact).displayName;\r\n }\r\n\r\n const signerContact = this.settings.currentGeneralReturnSetting.signerContact || this.settings.parentGeneralReturnSetting.signerContact;\r\n if (signerContact) {\r\n this._signerContactName = new ExtendedContactModel(signerContact).displayName;\r\n }\r\n\r\n this._refreshWetSignatureOverrideSwitch();\r\n }\r\n\r\n private _refreshWetSignatureOverrideSwitch(): void {\r\n switch (this.settings.currentGeneralReturnSetting.allowWetSignatureOverrideSettingState) {\r\n case Compliance.GeneralReturnSettingStateEnum.VariesBetweenParcels:\r\n this.hideWetSignatureOverrideWarning = false;\r\n break;\r\n case Compliance.GeneralReturnSettingStateEnum.DifferentForTopCompany:\r\n this.redWetSignatureOverrideLabelText = true;\r\n break;\r\n default:\r\n this.hideWetSignatureOverrideWarning = true;\r\n this.redWetSignatureOverrideLabelText = false;\r\n break;\r\n }\r\n }\r\n\r\n private isDisabled(): boolean{\r\n return this._isDisabled;\r\n }\r\n get ownerContactName(): string{\r\n return this._ownerContactName;\r\n }\r\n\r\n set ownerContact(value: ExtendedContactModel){\r\n this.settings.currentGeneralReturnSetting.ownerContactId = value.model.contactID;\r\n this._ownerContactName = value.displayName;\r\n this.hasChanges = true;\r\n }\r\n\r\n get accountingContactName(): string{\r\n return this._accountingContactName;\r\n }\r\n\r\n set accountingContact(value: ExtendedContactModel){\r\n this.settings.currentGeneralReturnSetting.accountingContactId = value.model.contactID;\r\n this._accountingContactName = value.displayName;\r\n this.hasChanges = true;\r\n }\r\n\r\n get preparerContactName(): string{\r\n return this._preparerContactName;\r\n }\r\n\r\n set preparerContact(value: ExtendedContactModel){\r\n this.settings.currentGeneralReturnSetting.preparerContactId = value.model.contactID;\r\n this._preparerContactName = value.displayName;\r\n this.hasChanges = true;\r\n }\r\n\r\n get signerContactName(): string{\r\n return this._signerContactName;\r\n }\r\n\r\n set signerContact(value: ExtendedContactModel){\r\n this.settings.currentGeneralReturnSetting.signerContactId = value.model.contactID;\r\n this._signerContactName = value.displayName;\r\n this.hasChanges = true;\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n

Return Settings

\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n 0\">\r\n \r\n \r\n
\r\n
\r\n","import { Component, Input, OnDestroy, OnInit, ViewChild } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { ReturnSettingsEntityTypeEnum } from '../../Return/Models/enums';\r\nimport { ReturnSettingsComponent } from '../../Return/Return-Parts/Settings/Return-Settings/returnSettings.component';\r\n\r\n@Component({\r\n selector: 'compliance-company-return-settings-panel',\r\n templateUrl: './companyReturnSettingsPanel.component.html'\r\n})\r\nexport class CompanyReturnSettingsPanelComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _navigationService: NavigationService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {\r\n }\r\n\r\n @Input() companyId: number;\r\n @Input() allowEdit: boolean;\r\n\r\n @ViewChild(ReturnSettingsComponent) returnSettingsComponent: ReturnSettingsComponent;\r\n\r\n isShowInfo: boolean = false;\r\n editMode: boolean = false;\r\n editLock: boolean = false;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n ReturnSettingsEntityTypeEnum = ReturnSettingsEntityTypeEnum;\r\n hasChanges: boolean;\r\n isLoading: boolean;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._navigationService.globalEditMode$.pipe(takeUntil(this._destroy$)).subscribe(editMode => {\r\n this.editLock = editMode;\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n expandOrCollapse(): boolean {\r\n if(this.editMode) {\r\n return true;\r\n }\r\n\r\n this.isShowInfo = !this.isShowInfo;\r\n this._productAnalyticsService.logEvent('company-toggle-panel', {\r\n panel: 'Return Settings',\r\n isOpen: this.isShowInfo\r\n });\r\n\r\n if(this.isShowInfo) {\r\n this.showInfo();\r\n }\r\n return false;\r\n }\r\n\r\n showInfo(): void {\r\n this.isLoading = true;\r\n }\r\n\r\n async save(): Promise {\r\n try{\r\n if (this.returnSettingsComponent){\r\n this.busyIndicatorMessageManager.add('Saving', 'saving');\r\n await this.returnSettingsComponent.save();\r\n this.busyIndicatorMessageManager.remove('saving');\r\n }\r\n this.editMode = false;\r\n }\r\n finally{\r\n this.busyIndicatorMessageManager.remove('saving');\r\n this._navigationService.disableNavWarning();\r\n }\r\n }\r\n\r\n async setEditMode(): Promise {\r\n this.editMode = true;\r\n this._navigationService.enableNavWarning('You have unsaved changes. Are you sure you want to leave this page?');\r\n await this.returnSettingsComponent.edit();\r\n this._productAnalyticsService.logEvent('edit-return-settings');\r\n }\r\n\r\n async cancelEdit(): Promise {\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n await this.returnSettingsComponent.cancel();\r\n }\r\n\r\n onReturnSettingsInitialized() {\r\n this.isLoading = false;\r\n }\r\n\r\n onReturnSettingsChanged(value: boolean){\r\n this.hasChanges = value;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface AgGridActionButtonConfig {\r\n iconClass: string;\r\n onClick: (params: AgGridActionCellRendererParams) => void;\r\n isShown: (params?: AgGridActionCellRendererParams) => boolean;\r\n buttonClass?: string;\r\n helpContentId?: string;\r\n disabled?: () => boolean;\r\n}\r\n\r\nexport interface AgGridActionCellRendererParams extends ICellRendererParams {\r\n buttonConfigs: AgGridActionButtonConfig[];\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n `\r\n})\r\nexport class AgGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: AgGridActionCellRendererParams;\r\n\r\n agInit(params: AgGridActionCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","
\r\n\r\n \r\n \r\n\r\n
\r\n
    \r\n
  • \r\n
    \r\n {{option[labelProperty]}}\r\n \r\n \r\n
    \r\n
  • \r\n
\r\n\r\n
\r\n \r\n \r\n \r\n
\r\n\r\n
\r\n
\r\n","import { Component, Input, forwardRef, Output, EventEmitter, OnInit, OnDestroy } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR, UntypedFormControl } from '@angular/forms';\r\nimport {\r\n trigger,\r\n state,\r\n style,\r\n animate,\r\n transition\r\n} from '@angular/animations';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\nimport { TimerService } from '../Utilities/timer.service';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n/**\r\n * Picklist\r\n *\r\n * Allows the user to select multiple items from the dropdown\r\n * The values selected can be reorganized after selection\r\n *\r\n * Tied into ControlValueAccessor for integration with native Angular FormControls and ngModel\r\n *\r\n * The input options can be any model. The properties to use as the selectors for each option in the dropdown are set using\r\n * labelProperty and valueProperty.\r\n *\r\n * Example usage:\r\n * \r\n * \r\n *\r\n */\r\n@Component({\r\n selector: 'ws-picklist',\r\n templateUrl: './picklist.component.html',\r\n styleUrls: ['./picklist.component.scss'],\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => PicklistComponent),\r\n multi: true\r\n }\r\n ],\r\n animations: [\r\n trigger('picklistVisible', [\r\n state('show', style({\r\n height: '*',\r\n opacity: 1\r\n })),\r\n state('hide', style({\r\n height: '0',\r\n opacity: 0\r\n })),\r\n transition('show => hide', animate('200ms ease')),\r\n transition('hide => show', animate('200ms ease'))\r\n ])\r\n ]\r\n})\r\nexport class PicklistComponent implements OnInit, OnDestroy, ControlValueAccessor {\r\n constructor(private readonly _timer: TimerService) {}\r\n\r\n @Input() labelProperty: string = 'label';\r\n @Input() valueProperty: string = 'value';\r\n @Input() placeholder: string;\r\n @Input() canReorganize: boolean = true;\r\n @Input() returnEntireOption: boolean = false;\r\n @Input() canRemove: boolean = true;\r\n @Input() mustHaveOne: boolean = false;\r\n\r\n @Input()\r\n set options(options: any[]) {\r\n this.availableOptions = [...options];\r\n this._allOptions = [...options];\r\n }\r\n\r\n @Output() picklistChanged: EventEmitter = new EventEmitter();\r\n @Output() picklistItemAdded: EventEmitter = new EventEmitter();\r\n @Output() picklistItemRemoved: EventEmitter = new EventEmitter();\r\n\r\n value: any[] = [];\r\n disabled: boolean;\r\n animationComplete: boolean;\r\n availableOptions: any[];\r\n picklist: any[] = [];\r\n selectedOption: any;\r\n selectedOptionIndex: number;\r\n listSelection: UntypedFormControl = new UntypedFormControl(null);\r\n\r\n private _allOptions: any[] = [];\r\n private _destroy$: Subject = new Subject();\r\n\r\n onChange: (val: any[]) => void = (val) => { return null; };\r\n onTouched: () => void = () => { return null; };\r\n\r\n // Angular Form methods\r\n writeValue(value: any[]) {\r\n this.value = value;\r\n if (this.value && this.value.length) {\r\n this.value.forEach(v => {\r\n const option = this.availableOptions.find(o => (this.returnEntireOption) ? _.isEqual(o, v) : o[this.valueProperty] === v);\r\n if (option) {\r\n this.picklist.push(option);\r\n const optionIndex = this.availableOptions.indexOf(option);\r\n this.availableOptions.splice(optionIndex, 1);\r\n } else {\r\n this.picklist.push(v);\r\n }\r\n });\r\n }\r\n }\r\n\r\n setDisabledState(disabled: boolean) {\r\n this.disabled = disabled;\r\n if (this.disabled) {\r\n this._disableDropdown();\r\n } else {\r\n this._enableDropdown();\r\n }\r\n }\r\n\r\n next(): void {\r\n this.onChange(this.value = this.picklist.map(p => (this.returnEntireOption) ? p : p[this.valueProperty]));\r\n this.picklistChanged.emit(this.picklist.map(p => (this.returnEntireOption) ? p : p[this.valueProperty]));\r\n this.onTouched();\r\n }\r\n\r\n registerOnChange(fn: any) {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any) {\r\n this.onTouched = fn;\r\n }\r\n\r\n // Custom methods\r\n\r\n ngOnInit(): void {\r\n this.listSelection.valueChanges.pipe(takeUntil(this._destroy$)).subscribe(option => {\r\n if (option) {\r\n this.addOption(option);\r\n }\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n addOption(option: any): void {\r\n if (this.picklist.indexOf(option) === -1) {\r\n this.picklist.push(option);\r\n const optionIndex = this.availableOptions.indexOf(option);\r\n this.availableOptions.splice(optionIndex, 1);\r\n this.listSelection.setValue(null);\r\n this.unsetSelected();\r\n this.next();\r\n this.picklistItemAdded.emit(option);\r\n\r\n if (this.picklist.length) {\r\n this._timer.setTimeout(() => this.animationComplete = true, 200);\r\n }\r\n\r\n if (!this.availableOptions.length) {\r\n this._disableDropdown();\r\n }\r\n }\r\n }\r\n\r\n removeOption(option?: any): void {\r\n const selected = (option) ? option : this.selectedOption;\r\n const index = this.picklist.indexOf(selected);\r\n if (index !== -1) {\r\n this.picklist.splice(index, 1);\r\n const optionIndex = this._allOptions.indexOf(selected);\r\n this.availableOptions.push(this._allOptions[optionIndex]);\r\n this.unsetSelected();\r\n this.next();\r\n this.picklistItemRemoved.emit(option);\r\n\r\n if (!this.picklist.length) {\r\n this.animationComplete = false;\r\n }\r\n\r\n if (this.availableOptions.length) {\r\n this._enableDropdown();\r\n }\r\n }\r\n }\r\n\r\n shiftOptionUp(): void {\r\n const index = this.picklist.indexOf(this.selectedOption);\r\n const newIndex = index - 1;\r\n if (index !== -1 && newIndex > -1) {\r\n this.picklist.splice(index, 1);\r\n this.picklist.splice(newIndex, 0, this.selectedOption);\r\n this.selectedOptionIndex = newIndex;\r\n this.next();\r\n }\r\n }\r\n\r\n shiftOptionDown(): void {\r\n const index = this.picklist.indexOf(this.selectedOption);\r\n const newIndex = index + 1;\r\n if (index !== -1 && newIndex !== this.picklist.length) {\r\n this.picklist.splice(index, 1);\r\n this.picklist.splice(newIndex, 0, this.selectedOption);\r\n this.selectedOptionIndex = newIndex;\r\n this.next();\r\n }\r\n }\r\n\r\n setSelected(option: any, index: number): void {\r\n this.selectedOption = option;\r\n this.selectedOptionIndex = index;\r\n }\r\n\r\n unsetSelected(): void {\r\n this.selectedOption = null;\r\n this.selectedOptionIndex = null;\r\n }\r\n\r\n private _disableDropdown(): void {\r\n this.listSelection.disable();\r\n }\r\n\r\n private _enableDropdown(): void {\r\n this.listSelection.enable();\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ContactsUpgradeService } from '../../../contacts.service.upgrade';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\nexport interface EditRoleModalParams {\r\n contact: Weissman.Model.Contacts.Contact;\r\n entity;\r\n roles: Weissman.Model.Contacts.ContactRole[];\r\n}\r\n\r\n@Component({\r\n selector: 'edit-role-modal',\r\n templateUrl: './editRoleModal.component.html'\r\n})\r\nexport class EditRoleModalComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _contactsService: ContactsUpgradeService,\r\n private readonly _toastr: ToastrService\r\n ) {}\r\n\r\n params: EditRoleModalParams;\r\n result: boolean;\r\n\r\n contact: Weissman.Model.Contacts.Contact;\r\n entity;\r\n availableRoles: Weissman.Model.Contacts.ContactRole[];\r\n associatedRoles: number[];\r\n originalRoles: number[];\r\n saving: boolean;\r\n\r\n get isLastAssociatedRole(): boolean {\r\n return this.contact['entityID'] === this.entity?.id && this.contact?.contactRoleAssociations?.filter(x => x.entityType === this.entity.type).length === 1;\r\n }\r\n\r\n ngOnInit(): void {\r\n this.contact = this.params.contact;\r\n this.entity = this.params.entity;\r\n this.availableRoles = this.params.roles.sort((x, y) => x.roleDesc.localeCompare(y.roleDesc));\r\n this.associatedRoles = this.contact.contactRoleAssociations.map(x => x.contactRole?.contactRoleID || x.contactRoleID);\r\n\r\n this.originalRoles = [...this.associatedRoles];\r\n }\r\n\r\n get modalHeader(): string {\r\n return `${this.params.contact.lastName}, ${this.params.contact.firstName} Roles`;\r\n }\r\n\r\n async save(): Promise {\r\n this.saving = true;\r\n\r\n const promises = [];\r\n\r\n const rolesToAdd = this.associatedRoles.filter(x => !this.originalRoles.includes(x))\r\n .map(x => this.availableRoles.find(y => y.contactRoleID === x));\r\n rolesToAdd.forEach(x => promises.push(this.addRole(x)));\r\n\r\n const rolesToRemove = this.originalRoles.filter(x => !this.associatedRoles.includes(x))\r\n .map(x => this.contact.contactRoleAssociations.find(y => y.contactRoleID === x));\r\n rolesToRemove.forEach(x => promises.push(this.removeRole(x)));\r\n\r\n await Promise.all(promises);\r\n\r\n this.saving = false;\r\n this.result = true;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async addRole(selectedRole: Weissman.Model.Contacts.ContactRole): Promise {\r\n const newRole = {\r\n contactID: this.contact.contactID,\r\n contactRoleID: selectedRole.contactRoleID,\r\n entityID: this.entity.id,\r\n entityType: this.entity.type\r\n };\r\n\r\n try {\r\n const result = await this._contactsService.addContactRoleAssociation(newRole);\r\n\r\n result.roleDesc = selectedRole.roleDesc;\r\n this.contact.contactRoleAssociations.push(result);\r\n\r\n // Now check if our contact list has this contact or not.\r\n const existingContactsWithThisId = this._contactsService.contacts.filter(x => x.contactID === this.contact.contactID);\r\n if (existingContactsWithThisId.length == 0) {\r\n if (!this.contact.address) {\r\n // todo This was from the old code - phone and mobile phone don't exist on the contact model so not sure it does anything\r\n this.contact.address = {\r\n phone: this.contact['phone'],\r\n mobilePhone: this.contact['mobilePhone']\r\n } as Weissman.Model.Misc.Address;\r\n }\r\n\r\n this._contactsService.addToCache(this.contact);\r\n }\r\n this._contactsService.updateContactInCache(this.contact);\r\n } catch(err) {\r\n this._toastr.error(`There was an error adding ${selectedRole.roleDesc}`);\r\n }\r\n }\r\n\r\n async removeRole(selectedRole: Weissman.Model.Contacts.ContactRoleAssociation): Promise {\r\n await this._contactsService.deleteContactRoleAssociation(selectedRole.contactRoleAssociationID);\r\n this._contactsService.updateContactInCache(this.contact);\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\n Roles:\r\n \r\n \r\n\r\n","import { Component, EventEmitter, Input, OnChanges, Output, SimpleChanges } from '@angular/core';\r\nimport { ContactModalOrigin, EntityTypeIds } from '../../../constants.new';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../Compliance/AgGrid';\r\nimport { ColDef, GridApi, GridReadyEvent } from 'ag-grid-community';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../../Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport {\r\n AgGridActionCellRendererComponent,\r\n AgGridActionCellRendererParams\r\n} from '../../../Compliance/AgGrid/CellRenderers/agGridActionCellRenderer.component';\r\nimport { ContactModalService } from '../../contactModal.service';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { EditRoleModalComponent, EditRoleModalParams } from './Edit-Role/editRoleModal.component';\r\n\r\n@Component({\r\n selector: 'entity-contact-list',\r\n templateUrl: './contactList.component.html',\r\n styleUrls: ['./contactList.component.scss']\r\n})\r\nexport class ContactListComponent implements OnChanges {\r\n constructor(\r\n private readonly _contactModalService: ContactModalService,\r\n private readonly _weissmanModalService: WeissmanModalService\r\n ) {\r\n }\r\n\r\n @Input() entity;\r\n @Input() roles;\r\n @Input() hasEditPermission: boolean;\r\n @Input() hasViewPermission: boolean;\r\n @Input() editMode: boolean;\r\n @Input() contacts: any[];\r\n\r\n @Output() contactsUpdated: EventEmitter = new EventEmitter();\r\n\r\n gridOptions = new AgGridOptionsBuilder()\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .withFirstDataRendered(x => {\r\n x.api.sizeColumnsToFit();\r\n })\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _contacts: any[];\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.contacts && changes.contacts.currentValue) {\r\n this._contacts = changes.contacts.currentValue;\r\n this._setRowData();\r\n } else if (changes.editMode && changes.editMode.currentValue && this._gridApi) {\r\n this._gridApi.redrawRows();\r\n }\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const worksForColumn = {\r\n field: 'lastName',\r\n lockVisible: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => '',\r\n getButtonLink: (params: AgGridLinkCellRendererParams) => {\r\n const contact = params.data;\r\n return `${contact.lastName}, ${contact.firstName}`;\r\n },\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const contact = params.data;\r\n this._openContactModal(contact);\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n return !((!this.editMode) ? this.hasViewPermission : this.hasEditPermission);\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n };\r\n\r\n let columns: ColDef[] = [\r\n {\r\n headerName: 'Contact',\r\n field: 'lastName',\r\n lockVisible: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => '',\r\n getButtonLink: (params: AgGridLinkCellRendererParams) => {\r\n const contact = params.data;\r\n return `${contact.lastName}, ${contact.firstName}`;\r\n },\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const contact = params.data;\r\n this._openContactModal(contact);\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n return !((!this.editMode) ? this.hasViewPermission : this.hasEditPermission);\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: (params) => {\r\n const contact = params.data;\r\n return `${contact.lastName}, ${contact.firstName}`;\r\n }\r\n },\r\n {\r\n headerName: 'Roles',\r\n field: 'contactRoleAssociations',\r\n valueFormatter: (params) => {\r\n const contact = params.data;\r\n return contact.contactRoleAssociations.map(x => x.roleDesc).join(', ');\r\n }\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: AgGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n buttonConfigs: [\r\n {\r\n iconClass: 'fa-pencil',\r\n onClick: (params: AgGridActionCellRendererParams) => {\r\n const contact = params.data;\r\n this._openRoleModal(contact);\r\n },\r\n isShown: () => this.editMode,\r\n helpContentId: 'contact-list.edit-roles',\r\n disabled: () => !this.editMode\r\n }\r\n ]\r\n } as AgGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'lastName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n if (this._hasWorksFor()) {\r\n columns = [worksForColumn, ...columns];\r\n }\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n\r\n this._setRowData();\r\n }\r\n\r\n worksFor(contact): boolean {\r\n return contact\r\n && this.entity\r\n && !(contact.entityTypeID !== EntityTypeIds[this.entity.type.toUpperCase()]\r\n || contact.entityID !== this.entity.id);\r\n }\r\n\r\n private _hasWorksFor(): boolean {\r\n return this._contacts.some(x => this.worksFor(x));\r\n }\r\n\r\n private async _openContactModal(contact): Promise {\r\n await this._contactModalService.openContactDialog(contact.contactID, ContactModalOrigin.EntityContact, null, this.entity);\r\n }\r\n\r\n private async _openRoleModal(contact): Promise {\r\n const params = {\r\n contact,\r\n entity: this.entity,\r\n roles: this.roles\r\n } as EditRoleModalParams;\r\n const result = await this._weissmanModalService.showAsync(EditRoleModalComponent, params, 'modal-md');\r\n\r\n if (result) {\r\n this.contactsUpdated.emit();\r\n }\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n this._contacts.forEach(x => {\r\n x.contactRoleAssociations = x.contactRoleAssociations.filter(y => {\r\n return y.entityID === this.entity.id\r\n && y.entityType.toLowerCase() === this.entity.type.toLowerCase();\r\n });\r\n x.contactRoleAssociations.sort((a, b) => a.roleDesc.localeCompare(b.roleDesc));\r\n });\r\n\r\n this._gridApi.setRowData(this._contacts);\r\n }\r\n}\r\n","
\r\n \r\n \r\n
\r\n","\r\n\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { ContactsUpgradeService } from '../../contacts.service.upgrade';\r\nimport { RestrictService } from '../../../Common/Permissions/restrict.service';\r\nimport { ContactModalOrigin } from '../../../constants.new';\r\nimport {\r\n ContactListModalComponent,\r\n ContactListModalParams\r\n} from '../List/Associate-Contact/contactListModal.component';\r\nimport { ContactModalService } from '../../contactModal.service';\r\nimport { GridOptions } from 'ag-grid-community';\r\n\r\n@Component({\r\n selector: 'contacts-panel-body-actions',\r\n templateUrl: './panelBodyActions.component.html'\r\n})\r\nexport class ContactPanelBodyActionsComponent implements OnInit {\r\n constructor(\r\n private readonly _contactsService: ContactsUpgradeService,\r\n private readonly _contactModalService: ContactModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _weissmanModalService: WeissmanModalService\r\n ) {}\r\n\r\n @Input() entity;\r\n @Input() contacts;\r\n @Input() roles;\r\n @Input() hasAssociateExistingPermission: boolean;\r\n @Input() isConsultantUser: boolean = false;\r\n @Input() gridOptions: GridOptions & { api?: { appliedFilter?: any }};\r\n\r\n newAllowed = false;\r\n hasNewContactPermission = false;\r\n notAllowedRoles = [];\r\n singleRoles = [26];\r\n\r\n ngOnInit(): void {\r\n this.newAllowed = this.entity.newAllowed;\r\n\r\n this.getNewContactPermission();\r\n }\r\n\r\n async newContact(): Promise {\r\n await this._contactModalService.openContactDialog(null, ContactModalOrigin.NewContact, this.contacts, this.entity, this.roles);\r\n }\r\n\r\n async associateExisting(): Promise {\r\n this.notAllowedRoles = [];\r\n\r\n this.contacts.forEach(x => {\r\n x.contactRoleAssociations.forEach(y => {\r\n if (this.singleRoles.indexOf(y.contactRoleID) !== -1) {\r\n if (this.notAllowedRoles.indexOf(y.contactRoleID) === -1) {\r\n this.notAllowedRoles.push(y.contactRoleID);\r\n }\r\n }\r\n });\r\n });\r\n\r\n const params = {\r\n entityInfo: this.entity,\r\n notAllowedRoles: this.notAllowedRoles\r\n } as ContactListModalParams;\r\n\r\n const result = await this._weissmanModalService.showAsync(ContactListModalComponent, params, 'modal-lg');\r\n\r\n if (result && result.contact) {\r\n // ok, now we have to save new relationship, lets get a contact from our grid (if we have this contact).\r\n let contact = result.contact;\r\n\r\n const existingContactsWithThisId = this._contactsService.getCached().filter(x => x.contactID === contact.contactID);\r\n\r\n if (existingContactsWithThisId.length > 0) {\r\n contact = existingContactsWithThisId[0];\r\n } else {\r\n // we have contact with ALL roles - either relevant to this entity or not.\r\n contact.contactRoleAssociations = contact.contactRoleAssociations\r\n ? contact.contactRoleAssociations.filter(x => {\r\n return (x.entityID === this.entity.id);\r\n })\r\n : [];\r\n }\r\n\r\n await this.saveAssociation(contact, result.selectedRole);\r\n }\r\n }\r\n\r\n async saveAssociation(contact, selectedRole): Promise {\r\n const newAssociation = {\r\n contactID: contact.contactID,\r\n contactRoleID: selectedRole.contactRoleID,\r\n entityID: this.entity.id,\r\n entityType: this.entity.type\r\n };\r\n\r\n const result = await this._contactsService.addContactRoleAssociation(newAssociation);\r\n\r\n result.roleDesc = selectedRole.roleDesc;\r\n\r\n contact.contactRoleAssociations.push(result);\r\n\r\n // now check if our contact list does have this contact or not.\r\n const existingContactsWithThisId = this._contactsService.getCached().filter(x => x.contactID === contact.contactID);\r\n if (existingContactsWithThisId.length === 0) {\r\n if (!contact.address) {\r\n contact.address = {\r\n phone: contact.phone,\r\n mobilePhone: contact.mobilePhone\r\n };\r\n }\r\n\r\n this._contactsService.addToCache(contact);\r\n }\r\n }\r\n\r\n async getNewContactPermission(): Promise {\r\n const restrictionData = this._restrictService.getRestrictionDataForEntity(this.entity, Core.AccessRightsEnum.Write);\r\n\r\n try {\r\n const hasContactPermission = await this._restrictService.hasPermission(restrictionData);\r\n this.hasNewContactPermission = hasContactPermission || !this.isConsultantUser;\r\n } catch(err) {\r\n console.warn('checkEntity - error', err);\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n \r\n

Contacts

\r\n\r\n
\r\n\r\n \r\n\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n 0\"\r\n [entity]=\"entity\"\r\n [contacts]=\"contacts\"\r\n [hasEditPermission]=\"hasEditPermission || isConsultantUser\"\r\n [hasViewPermission]=\"hasViewOrEditPermission\"\r\n [editMode]=\"isEdit\"\r\n [roles]=\"roles\"\r\n (contactsUpdated)=\"load()\">\r\n \r\n
\r\n

No contacts.

\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { ContactRoleService } from '../../Role/contact.role.service';\r\nimport { ContactsUpgradeService } from '../contacts.service.upgrade';\r\nimport { RestrictData, RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'contacts-panel',\r\n templateUrl: './contactPanel.component.html',\r\n styleUrls: ['./contactPanel.component.scss']\r\n})\r\nexport class ContactPanelComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _roleService: ContactRoleService,\r\n private readonly _contactsService: ContactsUpgradeService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _navigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {\r\n }\r\n\r\n @Input() entity;\r\n\r\n isEntityCompanyBased: boolean = false;\r\n\r\n contacts = [];\r\n roles = [];\r\n isLoading: boolean = false;\r\n showBody: boolean = false;\r\n isEdit: boolean = false;\r\n editLock: boolean = false;\r\n hasEditPermission: boolean = false;\r\n hasViewOrEditPermission: boolean = false;\r\n isConsultantUser: boolean = false;\r\n isCompany: boolean = false;\r\n showAll: boolean = false;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._contactsService.contactCache$.pipe(takeUntil(this._destroy$))\r\n .subscribe(contacts => {\r\n this.contacts = contacts;\r\n });\r\n\r\n this.isEntityCompanyBased = this.entity && (this.entity.type === 'site' || this.entity.type === 'company' || this.entity.type === 'parcel');\r\n this.showAll = false;\r\n this.getViewPermission();\r\n this.getEditPermissionForContactAndEntity();\r\n\r\n this._navigationService.globalEditMode$.pipe(takeUntil(this._destroy$)).subscribe(editMode => {\r\n this.editLock = editMode;\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n expandOrCollapse(): void {\r\n if (this.isEdit) {\r\n return;\r\n }\r\n\r\n this.showBody = !this.showBody;\r\n if (this.entity.type === 'company') {\r\n this._productAnalyticsService.logEvent('company-toggle-panel', {\r\n panel: 'Contacts',\r\n isOpen: this.showBody\r\n });\r\n }\r\n\r\n if (this.showBody) {\r\n this.load();\r\n }\r\n }\r\n\r\n async load(): Promise {\r\n this.isLoading = true;\r\n\r\n if (!this.entity) {\r\n this.showBody = false;\r\n this.isLoading = false;\r\n return false;\r\n } else {\r\n this.isCompany = this.entity.type === 'company';\r\n }\r\n\r\n try {\r\n if (this.isCompany) {\r\n this.isConsultantUser = await this._restrictService.isConsultantUser(this.entity.id);\r\n }\r\n\r\n const contacts = await this._contactsService.getByEntity(this.entity.id, this.entity.type, this.showAll);\r\n\r\n const roles = await this._roleService.get();\r\n this.roles = roles.filter(x => !!x[this.entity.type]);\r\n\r\n contacts.forEach(x => {\r\n x.contactRoleAssociations = x.contactRoleAssociations || [];\r\n });\r\n\r\n this._contactsService.contacts = contacts;\r\n } catch (err) {\r\n this.showBody = false;\r\n } finally {\r\n this.isLoading = false;\r\n }\r\n }\r\n\r\n edit(): void {\r\n this.isEdit = true;\r\n this._navigationService.enableNavWarning('You have unsaved changes. Are you sure you want to leave this page?');\r\n if (this.entity.type === 'company') {\r\n this._productAnalyticsService.logEvent('edit-company-contacts');\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this.isEdit = false;\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n showAllContacts(): void {\r\n this.showAll = !this.showAll;\r\n this.load();\r\n }\r\n\r\n async getEditPermissionForContactAndEntity(): Promise {\r\n //contacts for company, site and parcel\r\n if (this.isEntityCompanyBased) {\r\n const restrictionData = {\r\n isCompany: this.entity.type.toLowerCase() === 'company',\r\n entityId: this.entity.id,\r\n flag: Core.AccessRightsEnum.Write\r\n } as RestrictData;\r\n\r\n if (this.entity.type === 'parcel') {\r\n restrictionData.entityId = +this._navigationServiceHandler.getQuerystringParam('siteId');\r\n }\r\n\r\n try {\r\n this.hasEditPermission = await this._restrictService.hasPermission(restrictionData, true);\r\n } catch (err) {\r\n console.warn('checkEntity - error', err);\r\n }\r\n } else {\r\n const key = `${this.entity.type.toUpperCase()}EDIT`;\r\n\r\n this.hasEditPermission = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT)\r\n && this._restrictService.isInRole(Roles[key]);\r\n }\r\n }\r\n\r\n async getViewPermission(): Promise {\r\n const restrictionData = this._restrictService.getRestrictionDataForEntity(this.entity, Core.AccessRightsEnum.Read);\r\n try {\r\n const result = await this._restrictService.hasPermission(restrictionData);\r\n this.hasViewOrEditPermission = result && (this.isEntityCompanyBased || this._userInstanceService.isCurrentInstanceRyan());\r\n } catch (err) {\r\n console.warn('checkEntity - error', err);\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\nimport { DescriptorOverride } from './descriptor.model';\r\n\r\nconst baseUrl = '/api/descriptoroverride/';\r\n\r\n@Injectable()\r\nexport class DescriptorOverridesService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n getByCompanyId(companyId: number): Promise {\r\n const url = `${baseUrl}company/${companyId}`;\r\n\r\n return this.http.get(url);\r\n }\r\n\r\n createBatch(descriptorOverrides: DescriptorOverride[]): Promise {\r\n return this.http.post(baseUrl, {descriptorOverrides});\r\n }\r\n\r\n update(override: any) {\r\n return this.http.put(baseUrl, override);\r\n }\r\n\r\n deleteById(id) {\r\n const url = baseUrl + id;\r\n const config = {};\r\n\r\n return this.http.delete(url, config);\r\n }\r\n\r\n getAssetUsage(companyId: number, descriptorIds: number[]): Promise {\r\n const url = `${baseUrl}getAssetUsage/${companyId}`;\r\n\r\n return this.http.post(url, descriptorIds);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { CacheManagerService } from '../Common/Routing/cache-manager.service';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\n\r\n@Injectable()\r\nexport class DescriptorHelperService {\r\n constructor(private http: SDHttpService, private cacheManagerService: CacheManagerService) { }\r\n\r\n private readonly _SetupColumns = ['Characteristic Name', 'Company Usage', 'Site Usage', 'Parcel Usage', 'Assessor Usage', 'Asset Usage', 'ARCC Usage', 'Type', 'Comments', 'Enabled'];\r\n\r\n getCategories(): Promise {\r\n return this.cacheManagerService.buildCacheGet('/api/descriptorcategory', false);\r\n }\r\n\r\n getFieldTypes(): Promise {\r\n return this.cacheManagerService.buildCacheGet('/api/descriptorfieldtype', false);\r\n }\r\n\r\n getUsages(): Promise {\r\n return this.cacheManagerService.buildCacheGet('/api/descriptorusage/', false);\r\n }\r\n\r\n getFormats(): Promise {\r\n return this.cacheManagerService.buildCacheGet('/api/descriptorformat', false);\r\n }\r\n\r\n getSetup(): string[] {\r\n return this._SetupColumns;\r\n }\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom, Observable } from 'rxjs';\r\nimport { BaseRepository } from '../../Common/Data/base.repository';\r\n\r\n@Injectable()\r\nexport class EntityPropertyCharacteristicsService extends BaseRepository {\r\n constructor(httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n get(entityId: number, entityName: string): Promise {\r\n return lastValueFrom(this.httpGet(`api/${entityName}characteristic/${entityName}/${entityId}`));\r\n }\r\n\r\n searchAvailable(entityId: number, entityName: string, searchModel: Core.EntityDescriptorSearchModel): Observable {\r\n return this.httpPost(`api/${entityName}characteristic/${entityName}/${entityId}/available`, searchModel);\r\n }\r\n\r\n update(entityId: number, entityName: string, descriptors: Core.EntityDescriptorModel[]): Promise {\r\n return lastValueFrom(this.httpPut(`api/${entityName}characteristic/${entityName}/${entityId}`, descriptors));\r\n }\r\n\r\n}\r\n","
\r\n \r\n \r\n \r\n
\r\n\r\n\r\n
\r\n

Browse Characteristics

\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n {{category.name}}{{category.checkedCount}}\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output, TemplateRef } from '@angular/core';\r\nimport { BsModalRef, BsModalService } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom, Observable, Subscriber } from 'rxjs';\r\nimport { map, mergeMap } from 'rxjs/operators';\r\nimport { EntityPropertyCharacteristicsService } from '../Entity-Property-Characteristics/entity.property.characteristics.service';\r\nimport { DescriptorService } from '../descriptor.service';\r\nimport { DescriptorEntityType, EntityDescriptorModelUI, TypeaheadDescriptorDTO } from '../descriptor.model';\r\n\r\nimport { groupBy, map as _map, toArray, sortBy } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'property-characteristics-picker',\r\n templateUrl: './property.characteristics.picker.component.html'\r\n})\r\nexport class PropertyCharacteristicsPickerComponent implements OnInit {\r\n constructor(private readonly _entityDescriptorService: EntityPropertyCharacteristicsService,\r\n private readonly _descriptorService: DescriptorService,\r\n private readonly _modalService: BsModalService) { }\r\n\r\n @Input() entityId: number;\r\n @Input() entityName: DescriptorEntityType;\r\n @Input() descriptorsToExclude: EntityDescriptorModelUI[];\r\n @Input() disabled: boolean = false;\r\n @Input() isForCompanyOverrides: boolean = false;\r\n @Output() descriptorsSelected: EventEmitter = new EventEmitter();\r\n typeaheadLoading: boolean;\r\n selectedDescriptorName: string;\r\n dataSource: Observable;\r\n descriptorsToAdd: Core.DescriptorDTO[] = [];\r\n descriptorCategories: any[];\r\n private _browseModalRef: BsModalRef;\r\n\r\n async ngOnInit() {\r\n this.dataSource = new Observable((observer: Subscriber) => observer.next(this.selectedDescriptorName))\r\n .pipe(\r\n mergeMap((token) => {\r\n return this.searchAvailable({\r\n filter: token,\r\n descriptorIdsToExclude: _.map(this.descriptorsToExclude, 'descriptorID'),\r\n pageSize: 10\r\n });\r\n }),\r\n map((descriptors: Core.DescriptorDTO[]) => {\r\n return _.map(descriptors, x => {\r\n return {\r\n ...x,\r\n typeaheadField: `${x.categoryName}: ${x.name}`\r\n } as TypeaheadDescriptorDTO;\r\n });\r\n })\r\n );\r\n }\r\n\r\n descriptorSelected(descriptor: Core.DescriptorDTO) {\r\n this.descriptorsSelected.emit([descriptor]);\r\n this.selectedDescriptorName = '';\r\n }\r\n\r\n changeTypeaheadLoading(e: boolean): void {\r\n this.typeaheadLoading = e;\r\n }\r\n\r\n async openBrowseModal(template: TemplateRef): Promise {\r\n this._browseModalRef = this._modalService.show(template, { class: 'modal-lg', ignoreBackdropClick: true });\r\n\r\n const searchModel = {\r\n filter: '',\r\n descriptorIdsToExclude: _.map(this.descriptorsToExclude, 'descriptorID'),\r\n pageSize: null\r\n };\r\n const availableDescriptors = await lastValueFrom(this.searchAvailable(searchModel));\r\n this.descriptorCategories = _.flow([\r\n groupBy('categoryID'),\r\n toArray,\r\n _map((descriptors: Core.DescriptorDTO[]) => {\r\n return {\r\n name: descriptors[0].categoryName,\r\n categoryId: descriptors[0].categoryID,\r\n descriptors: descriptors,\r\n checkedCount: 0\r\n };\r\n }),\r\n sortBy('name')\r\n ])(availableDescriptors);\r\n }\r\n\r\n descriptorClicked(descriptor: Core.DescriptorDTO, category: any, e): void {\r\n const categoryIdx = _.findIndex(this.descriptorCategories, {categoryId: category.categoryId});\r\n\r\n if (e.target.checked) {\r\n this.descriptorsToAdd.push(descriptor);\r\n this.descriptorCategories[categoryIdx].checkedCount++;\r\n } else {\r\n _.pull(this.descriptorsToAdd, descriptor);\r\n this.descriptorCategories[categoryIdx].checkedCount--;\r\n }\r\n }\r\n\r\n isDescriptorChecked(descriptor: Core.DescriptorDTO): boolean {\r\n return _.some(this.descriptorsToAdd, { descriptorID: descriptor.descriptorID });\r\n }\r\n\r\n clearSelection(): void {\r\n this.descriptorsToAdd = [];\r\n\r\n this.descriptorCategories = _.map(this.descriptorCategories, x => {\r\n x.checkedCount = 0;\r\n return x;\r\n });\r\n }\r\n\r\n addDescriptors(): void {\r\n this.descriptorsSelected.emit(this.descriptorsToAdd);\r\n this.closeModal();\r\n }\r\n\r\n closeModal(): void {\r\n this.descriptorsToAdd = [];\r\n this._browseModalRef.hide();\r\n }\r\n\r\n searchAvailable(searchModel: Core.EntityDescriptorSearchModel): Observable {\r\n if(this.entityName == 'company' && this.isForCompanyOverrides) {\r\n return this._descriptorService.searchAvailableOverrides(this.entityId, searchModel);\r\n } else {\r\n return this._entityDescriptorService.searchAvailable(this.entityId, this.entityName, searchModel);\r\n }\r\n }\r\n}\r\n","
\r\n \r\n

Company Property Characteristics Overrides

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
CategoryCharacteristic NameCompany UsageSite UsageParcel UsageAsset UsageComments
\r\n {{descriptorOverride.categoryName}}\r\n \r\n {{descriptorOverride.descriptorName}}\r\n \r\n \r\n {{getDescriptorUsage(descriptorOverride.descriptorOverride.companyUsageId)}}\r\n \r\n \r\n \r\n \r\n {{getDescriptorUsage(descriptorOverride.descriptorOverride.siteUsageID)}}\r\n \r\n \r\n \r\n \r\n {{getDescriptorUsage(descriptorOverride.descriptorOverride.parcelUsageID)}}\r\n \r\n \r\n \r\n
\r\n \r\n {{getAssetDescriptorUsage(descriptorOverride.descriptorOverride.assetUsageID)}}\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n","import { Component } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { ProductAnalyticsService } from '../Common/Amplitude/productAnalytics.service';\r\nimport { InstanceRights, RestrictData, RestrictService } from '../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { InstanceRepository } from '../Entity/Instance/instance.repository';\r\nimport { DescriptorHelperService } from './descriptor.helper.service';\r\nimport { DescriptorOverridesService } from './descriptor.overrides.service';\r\nimport { DescriptorOverride } from './descriptor.model';\r\nimport { NavigationService } from '../Layout/navigation.service';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport DescriptorUsageEnum = Core.DescriptorUsageEnum;\r\n\r\nconst warningMessage = 'Editing is in progress. Are you sure you want to leave?';\r\n\r\n@Component({\r\n selector: 'property-characteristics-overrides',\r\n templateUrl: './property.characteristics.overrides.component.html',\r\n styleUrls: ['./property.characteristics.overrides.component.scss']\r\n})\r\nexport class PropertyCharacteristicsOverridesComponent {\r\n constructor(private descriptorOverridesService: DescriptorOverridesService,\r\n private helperService: DescriptorHelperService,\r\n private upgradeNavigationService: UpgradeNavigationServiceHandler,\r\n private navigationService: NavigationService,\r\n private instanceRepository: InstanceRepository,\r\n private messageBoxService: MessageBoxService,\r\n private restrictService: RestrictService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {\r\n }\r\n\r\n _assetUsages: Weissman.Model.Descriptors.DescriptorUsage[];\r\n _assetUsagesMinusNever: Weissman.Model.Descriptors.DescriptorUsage[] = [];\r\n companyId: number;\r\n hasWritePermission: boolean = false;\r\n hideComplianceFeatures: boolean = false;\r\n usages: Weissman.Model.Descriptors.DescriptorUsage[];\r\n descriptorOverrides: DescriptorOverride[];\r\n descriptorOverrideToEdit: DescriptorOverride;\r\n initialGet: boolean = false;\r\n addingDescriptor: boolean = false;\r\n serverActionSingle: object = {};\r\n showBody: boolean = false;\r\n isLoadingAssetUsage: object = {};\r\n\r\n async expandOrCollapse() {\r\n this.showBody = !this.showBody;\r\n this._productAnalyticsService.logEvent('company-toggle-panel', {\r\n panel: 'Company Property Characteristics',\r\n isOpen: this.showBody\r\n });\r\n\r\n if (this.showBody) {\r\n this.companyId = +this.upgradeNavigationService.getQuerystringParam('companyId');\r\n await this._doPermissionCheck();\r\n await this._getData();\r\n }\r\n }\r\n\r\n getAssetUsages(canAssetUsageBeRemoved: boolean): Weissman.Model.Descriptors.DescriptorUsage[] {\r\n return canAssetUsageBeRemoved ? this._assetUsages : this._assetUsagesMinusNever;\r\n }\r\n\r\n getDescriptorUsage(id: number): string {\r\n return _.find(this.usages, { descriptorUsageID: id }).name;\r\n }\r\n\r\n getAssetDescriptorUsage(id: number): string {\r\n return _.find(this._assetUsages, { descriptorUsageID: id }).name;\r\n }\r\n\r\n isOverridden(descriptorOverride: DescriptorOverride, usageIdKey: string): boolean {\r\n return descriptorOverride.descriptorDTO[usageIdKey] !== descriptorOverride.descriptorOverride[usageIdKey];\r\n }\r\n\r\n isEditMode(descriptorOverride: DescriptorOverride): boolean {\r\n return this.descriptorOverrideToEdit && descriptorOverride.descriptorOverride.descriptorOverrideID == this.descriptorOverrideToEdit.descriptorOverride.descriptorOverrideID;\r\n }\r\n\r\n editDescriptorOverride(descriptorOverride: DescriptorOverride): void {\r\n this.descriptorOverrideToEdit = _.cloneDeep(descriptorOverride);\r\n this.navigationService.enableNavWarning(warningMessage);\r\n }\r\n\r\n cancelEdit(): void {\r\n this.descriptorOverrideToEdit = undefined;\r\n this.navigationService.disableNavWarning();\r\n }\r\n\r\n async saveDescriptorOverride(idx: number): Promise {\r\n this.serverActionSingle[idx] = true;\r\n\r\n await this.descriptorOverridesService.update(this.descriptorOverrideToEdit.descriptorOverride);\r\n this.descriptorOverrides[idx] = this.descriptorOverrideToEdit;\r\n\r\n this.descriptorOverrideToEdit = undefined;\r\n this.navigationService.disableNavWarning();\r\n\r\n this.serverActionSingle[idx] = false;\r\n }\r\n\r\n async deleteDescriptorOverride(descriptorOverride: DescriptorOverride, idx: number): Promise {\r\n const result = await this.messageBoxService.open({\r\n message: `Are you sure you want to delete ${descriptorOverride.descriptorName}?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (result === MessageBoxResult.OK) {\r\n this.serverActionSingle[idx] = true;\r\n\r\n await this.descriptorOverridesService.deleteById(descriptorOverride.descriptorOverride.descriptorOverrideID);\r\n\r\n _.remove(this.descriptorOverrides, descriptorOverride);\r\n this.serverActionSingle[idx] = false;\r\n }\r\n }\r\n\r\n async descriptorsSelected(descriptors: Core.DescriptorDTO[]): Promise {\r\n const descriptorsToAdd = _.map(descriptors, x => {\r\n const descriptorToAdd: any = _.pick(x, ['descriptorID', 'siteUsageID', 'parcelUsageID', 'assetUsageID', 'companyUsageId']);\r\n descriptorToAdd.companyID = this.companyId;\r\n\r\n return descriptorToAdd;\r\n });\r\n\r\n this.addingDescriptor = true;\r\n try {\r\n await this.descriptorOverridesService.createBatch(descriptorsToAdd);\r\n this.descriptorOverrides = await this._getDescriptorOverrides();\r\n } finally {\r\n this.addingDescriptor = false;\r\n }\r\n\r\n }\r\n\r\n private async _doPermissionCheck(): Promise {\r\n const restrictionData: RestrictData = new RestrictData();\r\n restrictionData.isCompany = true;\r\n restrictionData.entityId = this.companyId;\r\n restrictionData.flag = Core.AccessRightsEnum.Write;\r\n\r\n this.hasWritePermission = await this.restrictService.hasPermission(restrictionData);\r\n\r\n const instanceId = await lastValueFrom(this.instanceRepository.getEntityInstanceId('company', this.companyId));\r\n this.hideComplianceFeatures = !this.restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, instanceId);\r\n }\r\n\r\n private async _getData(): Promise {\r\n this.initialGet = true;\r\n\r\n this._assetUsagesMinusNever = [];\r\n this.usages = await this.helperService.getUsages();\r\n this.descriptorOverrides = await this._getDescriptorOverrides();\r\n\r\n this._assetUsages = JSON.parse(JSON.stringify(this.usages));\r\n this._assetUsages.forEach(assetUsage => {\r\n if (assetUsage.name == 'Frequent') {\r\n assetUsage.name = 'Required';\r\n } else if (assetUsage.name == 'Occasional') {\r\n assetUsage.name = 'Optional';\r\n }\r\n\r\n if (assetUsage.name != 'Never') {\r\n this._assetUsagesMinusNever.push(assetUsage);\r\n }\r\n });\r\n\r\n if (!this.hideComplianceFeatures) {\r\n const assetDescriptorIdsToCheck = this.descriptorOverrides\r\n .filter(x => x.descriptorOverride.assetUsageID !== DescriptorUsageEnum.Never && x.canAssetUsageBeRemoved)\r\n .map(x => x.descriptorDTO.descriptorID);\r\n\r\n this.isLoadingAssetUsage = assetDescriptorIdsToCheck.reduce((acc, key) => ({ ...acc, [key]: 1 }), {});\r\n\r\n this.descriptorOverridesService.getAssetUsage(this.companyId, assetDescriptorIdsToCheck).then(descriptorsInfo => {\r\n descriptorsInfo.forEach(x => {\r\n const descriptor = this.descriptorOverrides.find(y => y.descriptorOverride.descriptorID === x.descriptorId);\r\n descriptor.canAssetUsageBeRemoved = x.canAssetUsageBeRemoved;\r\n delete this.isLoadingAssetUsage[x.descriptorId];\r\n });\r\n });\r\n }\r\n\r\n this.initialGet = false;\r\n }\r\n\r\n private async _getDescriptorOverrides(): Promise {\r\n const descriptorOverrides = await this.descriptorOverridesService.getByCompanyId(this.companyId);\r\n return _.sortBy(descriptorOverrides, ['categoryName', 'descriptorDTO.sequenceNumber']);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\n\r\nconst baseUrl = '/api/descriptorpicklist/';\r\n\r\n@Injectable()\r\nexport class DescriptorPicklistService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n getByPicklistGroupId(id: number): Promise {\r\n if (id) {\r\n const url = baseUrl + id;\r\n const config = {};\r\n\r\n return this.http.get(url, config);\r\n } else {\r\n return Promise.resolve([]);\r\n }\r\n }\r\n\r\n updateItem(item: Weissman.Model.Descriptors.DescriptorPickList) {\r\n return this.http.put(baseUrl, item, {});\r\n }\r\n\r\n createItem(item: Weissman.Model.Descriptors.DescriptorPickList) {\r\n return this.http.post(baseUrl, item, {});\r\n }\r\n\r\n deleteItemById(id: number) {\r\n const url = baseUrl + id;\r\n\r\n return this.http.delete(url, {});\r\n }\r\n\r\n canLimitToList(descriptorId: number, picklistGroupId: number) {\r\n const url = `${baseUrl }canlimittolist/`;\r\n const config = {\r\n params: {\r\n descriptorID: descriptorId,\r\n groupID: picklistGroupId\r\n }\r\n };\r\n\r\n return this.http.get(url, config);\r\n }\r\n}\r\n","
\r\n {{descriptor.value | currency: 'USD'}}\r\n \r\n {{descriptor.value}}\r\n Empty\r\n \r\n \r\n \r\n {{descriptor.value}}\r\n {{descriptor.value | number}}\r\n {{descriptor.value | number: '1.2-2'}}\r\n {{descriptor.value | number: '1.3-3'}}\r\n \r\n Empty\r\n \r\n \r\n Empty\r\n \r\n \r\n \r\n {{descriptor.value ? 'Yes' : 'No'}}\r\n {{descriptor.value || 'Not Set'}}\r\n
\r\n\r\n
\r\n \r\n 0 ? descriptor.descriptor.validation.maxLength : null\">\r\n 0 ? descriptor.descriptor.validation.minValue : null\"\r\n [attr.max]=\"descriptor.descriptor.validation.maxValue > 0 ? descriptor.descriptor.validation.maxValue : null\"\r\n [options]=\"numberOptions\">\r\n \r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n","import { Component, Input, OnChanges, OnInit, SimpleChanges } from '@angular/core';\r\nimport { CurrencyMaskConfig } from 'ng2-currency-mask';\r\nimport { EntityDescriptorModelUI } from '../../descriptor.model';\r\nimport { DescriptorPicklistService } from '../../descriptor.picklist.service';\r\n\r\nimport * as _ from 'lodash';\r\nimport { filter, sortBy } from 'lodash/fp';\r\nimport * as moment from 'moment';\r\n\r\nenum DescriptorFieldTypes {\r\n Text = Core.DescriptorFieldTypes.Text as number,\r\n Number = Core.DescriptorFieldTypes.Number as number,\r\n Date = Core.DescriptorFieldTypes.Date as number,\r\n Picklist = Core.DescriptorFieldTypes.Picklist as number,\r\n YesNo = Core.DescriptorFieldTypes.YesNo as number,\r\n Currency = Core.DescriptorFieldTypes.Currency as number,\r\n}\r\n\r\nenum DescriptorFormats {\r\n NoSeparators = 1,\r\n CommaSeparators = 2,\r\n CommaSeparatorsDupe = 3,\r\n CommaSeparatorsPrecision2 = 4,\r\n CommaSeparatorsPrecision3 = 5\r\n}\r\n\r\n@Component({\r\n selector: 'entity-property-characteristics-input',\r\n templateUrl: './entity.property.characteristics.input.component.html',\r\n styles: [`\r\n .ng-invalid.ng-touched {\r\n border-color: var(--ace-danger);\r\n box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.08);\r\n }\r\n `]\r\n})\r\nexport class EntityPropertyCharacteristicsInputComponent implements OnInit, OnChanges {\r\n constructor( private readonly _picklistService: DescriptorPicklistService) { }\r\n\r\n @Input() descriptor: EntityDescriptorModelUI;\r\n @Input() isEditMode: boolean;\r\n @Input() disabled: boolean = false;\r\n @Input() set saveAttempted(attempted: boolean) {\r\n this.wasSaveAttempted = attempted;\r\n if (attempted) {\r\n this._validate();\r\n }\r\n }\r\n\r\n wasSaveAttempted: boolean = false;\r\n FieldTypeEnum: typeof DescriptorFieldTypes = DescriptorFieldTypes;\r\n picklistOptions: Core.DescriptorPickListModel[] = [];\r\n numberOptions: CurrencyMaskConfig;\r\n DescriptorFormats = DescriptorFormats;\r\n isValid: boolean = true;\r\n\r\n ngOnInit() {\r\n this.descriptor.descriptor.validation = this.descriptor.descriptor.validation || {};\r\n\r\n switch (this.descriptor.descriptor.fieldTypeID) {\r\n case Core.DescriptorFieldTypes.Date:\r\n const dateMatch = /(\\d\\d\\d\\d)-(\\d\\d)-(\\d\\d)/.exec(this.descriptor.value);\r\n if (dateMatch) {\r\n this.descriptor.value = moment.utc([+dateMatch[1], +dateMatch[2] - 1, +dateMatch[3]]).toDate() as unknown as string; // hack to get around descriptor.value having multiple types\r\n }\r\n\r\n break;\r\n\r\n case Core.DescriptorFieldTypes.YesNo:\r\n if (typeof this.descriptor.value === 'string') {\r\n if (this.descriptor.value.toLowerCase() === 'true') {\r\n this.descriptor.value = true as unknown as string;\r\n } else {\r\n this.descriptor.value = false as unknown as string;\r\n }\r\n } else {\r\n this.descriptor.value = false as unknown as string;\r\n }\r\n\r\n break;\r\n\r\n case Core.DescriptorFieldTypes.Number:\r\n case Core.DescriptorFieldTypes.Currency:\r\n if(typeof this.descriptor.value === 'string') {\r\n this.descriptor.value = +this.descriptor.value as unknown as string;\r\n }\r\n\r\n break;\r\n }\r\n\r\n if(this.descriptor.descriptor.fieldTypeID == Core.DescriptorFieldTypes.Number) {\r\n this.numberOptions = {\r\n allowNegative: true,\r\n align: 'right',\r\n decimal: '.',\r\n precision: 0,\r\n prefix: '',\r\n suffix: '',\r\n thousands: ','\r\n };\r\n\r\n switch(this.descriptor.descriptor.formatID) {\r\n case DescriptorFormats.NoSeparators:\r\n this.numberOptions.thousands = '';\r\n break;\r\n case DescriptorFormats.CommaSeparatorsPrecision2:\r\n this.numberOptions.precision = 2;\r\n break;\r\n case DescriptorFormats.CommaSeparatorsPrecision3:\r\n this.numberOptions.precision = 3;\r\n break;\r\n }\r\n }\r\n }\r\n\r\n async ngOnChanges(changes: SimpleChanges): Promise {\r\n if(this.isEditMode\r\n && (changes.descriptor || changes.isEditMode)\r\n && this.descriptor.descriptor.fieldTypeID == Core.DescriptorFieldTypes.Picklist) {\r\n const picklistOptions = await this._picklistService.getByPicklistGroupId(this.descriptor.descriptor.pickListGroupID);\r\n this.picklistOptions = _.flow([\r\n filter((x: any) => !x.disabled || x.name == this.descriptor.value),\r\n sortBy('name')\r\n ])(picklistOptions);\r\n }\r\n }\r\n\r\n private _validate(): boolean {\r\n const validation = this.descriptor.descriptor.validation;\r\n if (!validation) {\r\n return;\r\n }\r\n\r\n switch(this.descriptor.descriptor.fieldTypeID) {\r\n case Core.DescriptorFieldTypes.Text:\r\n this.isValid = this.descriptor.value\r\n && (!validation.maxLength || this.descriptor.value.length <= validation.maxLength);\r\n break;\r\n case Core.DescriptorFieldTypes.Number:\r\n this.isValid = this.descriptor.value\r\n && (!validation.minValue || this.descriptor.value >= validation.minValue)\r\n && (!validation.maxValue || this.descriptor.value <= validation.maxValue);\r\n break;\r\n case Core.DescriptorFieldTypes.Date:\r\n this.isValid = this.descriptor.value && moment(this.descriptor.value).isValid()\r\n && (!validation.minValue || moment(this.descriptor.value).year() >= validation.minValue)\r\n && (!validation.maxValue || moment(this.descriptor.value).year() <= validation.maxValue);\r\n break;\r\n case Core.DescriptorFieldTypes.Picklist:\r\n this.isValid = this.descriptor.value;\r\n break;\r\n case Core.DescriptorFieldTypes.Currency:\r\n this.isValid = this.descriptor.value\r\n && (!validation.minValue || this.descriptor.value >= validation.minValue)\r\n && (!validation.maxValue || this.descriptor.value <= validation.maxValue);\r\n break;\r\n }\r\n }\r\n\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { EntityDescriptorModelUI } from '../descriptor.model';\r\n\r\n@Component({\r\n selector: 'entity-property-characteristics-list',\r\n template: `\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n `,\r\n styles: [`\r\n .entity-descriptor-table td {\r\n vertical-align: middle;\r\n }\r\n\r\n .entity-descriptor-table td:first-child {\r\n padding-right: 15px;\r\n }\r\n\r\n .entity-descriptor-table label {\r\n margin: 0;\r\n }\r\n\r\n .edit-mode-table td {\r\n padding-bottom: 3px;\r\n }\r\n `]\r\n})\r\nexport class EntityPropertyCharacteristicsListComponent {\r\n @Input() descriptors: EntityDescriptorModelUI[];\r\n @Input() isEditMode: boolean;\r\n @Input() saveAttempted: boolean;\r\n\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n \r\n

{{ isCompany ? 'Company' : currentEntity.name }} Characteristics

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import {\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n Inject,\r\n Input, OnDestroy,\r\n OnInit,\r\n QueryList,\r\n ViewChildren\r\n} from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { ChangeHistoryModalLaunchService } from '../../Common/Change-History/change-history-modal-launch.service';\r\nimport { RestrictService, InstanceRights, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { EntityType } from '../../constants.new';\r\nimport { InstanceRepository } from '../../Entity/Instance/instance.repository';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { EntityPropertyCharacteristicsService } from './entity.property.characteristics.service';\r\nimport { DescriptorEntity, EntityDescriptorModelUI } from '../descriptor.model';\r\n\r\nconst warningMessage = 'Editing is in progress. Are you sure you want to leave?';\r\n\r\n@Component({\r\n selector: 'entity-property-characteristics',\r\n templateUrl: './entity.property.characteristics.component.html'\r\n})\r\nexport class EntityPropertyCharacteristicsComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _navigationService: NavigationService,\r\n private readonly _upgradeNavService: UpgradeNavigationServiceHandler,\r\n private readonly _entityDescriptorService: EntityPropertyCharacteristicsService,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private readonly _changeHistoryService: ChangeHistoryModalLaunchService,\r\n @Inject('$rootScope') private _rootScope: any,\r\n private readonly _toastr: ToastrService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _changeDetectorRef: ChangeDetectorRef,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {\r\n }\r\n\r\n @Input() instanceId: number;\r\n @Input() isCompany?: boolean;\r\n @Input() isParcel?: boolean;\r\n\r\n @ViewChildren('formRow') rows: QueryList;\r\n currentEntity: DescriptorEntity;\r\n allowMaximize: boolean = true;\r\n isMaximized: boolean = false;\r\n searchModel: Core.EntityDescriptorSearchModel;\r\n EntityTypes = EntityType;\r\n hasInstancePrivateView: boolean = false;\r\n hasWritePermission: boolean = false;\r\n\r\n descriptorsAlpha: EntityDescriptorModelUI[];\r\n descriptorCategories: {\r\n name: string;\r\n descriptors: EntityDescriptorModelUI[];\r\n isOpen: boolean;\r\n categoryId: number\r\n }[];\r\n originalDescriptorsAlpha: EntityDescriptorModelUI[];\r\n originalDescriptorCategories: {\r\n name: string;\r\n descriptors: EntityDescriptorModelUI[];\r\n isOpen: boolean;\r\n categoryId: number\r\n }[];\r\n\r\n isEditMode: boolean = false;\r\n editLock: boolean = false;\r\n sortByCategory: boolean = false;\r\n loading: boolean = false;\r\n saveAttempted: boolean = false;\r\n showBody: boolean = false;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n async ngOnInit() {\r\n if (!this.isCompany) {\r\n await this._loadPanel();\r\n this.showBody = true;\r\n }\r\n\r\n this._navigationService.globalEditMode$.pipe(takeUntil(this._destroy$)).subscribe(editMode => {\r\n this.editLock = editMode;\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n descriptorsSelected(descriptors: Core.DescriptorDTO[]): void {\r\n // let addedDescriptorId: number;\r\n\r\n // if (descriptors.length == 1) {\r\n // addedDescriptorId = descriptors[0].descriptorID;\r\n // }\r\n\r\n _.forEach(descriptors, x => {\r\n this.descriptorsAlpha.push({\r\n descriptorID: x.descriptorID,\r\n entityID: this.currentEntity.entityId,\r\n value: undefined,\r\n descriptor: x,\r\n rowVersion: [],\r\n isDeleted: false\r\n });\r\n });\r\n\r\n this._setDescriptorViews(this.descriptorsAlpha);\r\n }\r\n\r\n goToEditMode(event: MouseEvent): void {\r\n event.stopPropagation();\r\n\r\n this.originalDescriptorsAlpha = _.cloneDeep(this.descriptorsAlpha);\r\n this.originalDescriptorCategories = _.cloneDeep(this.descriptorCategories);\r\n this.isEditMode = true;\r\n\r\n this._navigationService.enableNavWarning(warningMessage);\r\n if (this.isCompany) {\r\n this._productAnalyticsService.logEvent('edit-company-characteristics');\r\n }\r\n }\r\n\r\n cancel(event: MouseEvent): void {\r\n event.stopPropagation();\r\n\r\n this.descriptorsAlpha = this.originalDescriptorsAlpha;\r\n this.descriptorCategories = this.originalDescriptorCategories;\r\n this.isEditMode = false;\r\n\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n async save(event: MouseEvent): Promise {\r\n event.stopPropagation();\r\n\r\n this.saveAttempted = false;\r\n this._changeDetectorRef.detectChanges();\r\n let descriptorsToSave = this.sortByCategory ? _.flatMap(this.descriptorCategories, 'descriptors') : this.descriptorsAlpha;\r\n descriptorsToSave = _.reject(descriptorsToSave, 'isDeleted');\r\n\r\n const validationMessage = this._getValidationMessage(descriptorsToSave);\r\n\r\n if (validationMessage) {\r\n this.saveAttempted = true;\r\n this._toastr.error(validationMessage, '', { enableHtml: true });\r\n return;\r\n }\r\n\r\n try {\r\n this.loading = true;\r\n const descriptors = await this._entityDescriptorService.update(this.currentEntity.entityId, this.currentEntity.name, descriptorsToSave) as EntityDescriptorModelUI[];\r\n this._setDescriptorViews(descriptors);\r\n this.isEditMode = false;\r\n this._navigationService.disableNavWarning();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n maximize(): void {\r\n this.isMaximized = true;\r\n this._broadcastMaximize();\r\n }\r\n\r\n unmaximize(): void {\r\n this.isMaximized = false;\r\n this._broadcastMaximize();\r\n }\r\n\r\n\r\n launchChangeHistoryModal(event: MouseEvent): void {\r\n event.stopPropagation();\r\n\r\n switch (this.currentEntity.entityTypeId) {\r\n case Core.EntityTypes.Site:\r\n this._changeHistoryService.openChangeHistoryModal('Site Characteristics', this.currentEntity.entityId, Core.EntityTypes.Site, 'descriptor');\r\n break;\r\n case Core.EntityTypes.Parcel:\r\n this._changeHistoryService.openChangeHistoryModal('Parcel Characteristics', this.currentEntity.entityId, Core.EntityTypes.Parcel, 'descriptor');\r\n break;\r\n case Core.EntityTypes.Assessor:\r\n this._changeHistoryService.openChangeHistoryModal('Assessor Characteristics', this.currentEntity.entityId, Core.EntityTypes.Assessor, 'descriptor');\r\n break;\r\n case Core.EntityTypes.Company:\r\n this._changeHistoryService.openChangeHistoryModal('Company Characteristics', this.currentEntity.entityId, Core.EntityTypes.Company, 'descriptor');\r\n break;\r\n }\r\n }\r\n\r\n async expandOrCollapse() {\r\n if (!this.isCompany) {\r\n return;\r\n }\r\n\r\n this.showBody = !this.showBody;\r\n if (this.isCompany) {\r\n this._productAnalyticsService.logEvent('company-toggle-panel', {\r\n panel: 'Company Characteristics',\r\n isOpen: this.showBody\r\n });\r\n }\r\n\r\n if (this.showBody) {\r\n await this._loadPanel();\r\n }\r\n }\r\n\r\n private _setDescriptorViews(descriptors: EntityDescriptorModelUI[]): void {\r\n this.descriptorsAlpha = _.sortBy(descriptors, [x => x.descriptor.name.toLowerCase()]);\r\n this.descriptorCategories = _.chain(this.descriptorsAlpha)\r\n .groupBy(x => x.descriptor.categoryID)\r\n .toArray()\r\n .map(x => {\r\n const isOpenCategory = _.find(this.descriptorCategories, { categoryId: x[0].descriptor.categoryID });\r\n\r\n return {\r\n categoryId: x[0].descriptor.categoryID,\r\n name: x[0].descriptor.categoryName,\r\n descriptors: x,\r\n isOpen: isOpenCategory ? isOpenCategory.isOpen : true\r\n };\r\n })\r\n .sortBy('name')\r\n .value();\r\n }\r\n\r\n private _getCurrentEntity(): DescriptorEntity {\r\n const parcelId = +this._upgradeNavService.getQuerystringParam('parcelId');\r\n const siteId = +this._upgradeNavService.getQuerystringParam('siteId');\r\n const assessorId = +this._upgradeNavService.getQuerystringParam('id');\r\n const companyId = +this._upgradeNavService.getQuerystringParam('companyId');\r\n\r\n if (parcelId) {\r\n return {\r\n name: 'parcel',\r\n entityTypeId: Core.EntityTypes.Parcel,\r\n entityId: parcelId\r\n };\r\n } else if (siteId) {\r\n return {\r\n name: 'site',\r\n entityTypeId: Core.EntityTypes.Site,\r\n entityId: siteId\r\n };\r\n } else if (assessorId) {\r\n this.allowMaximize = false;\r\n return {\r\n name: 'assessor',\r\n entityTypeId: Core.EntityTypes.Assessor,\r\n entityId: assessorId\r\n };\r\n } else if (companyId) {\r\n this.allowMaximize = false;\r\n return {\r\n name: 'company',\r\n entityTypeId: Core.EntityTypes.Company,\r\n entityId: companyId\r\n };\r\n }\r\n }\r\n\r\n private async _doPermissionsCheck(): Promise {\r\n if (this.currentEntity.entityTypeId == Core.EntityTypes.Site || this.currentEntity.entityTypeId == Core.EntityTypes.Parcel ||\r\n this.currentEntity.entityTypeId === Core.EntityTypes.Company) {\r\n this.instanceId = this.instanceId || await lastValueFrom(this._instanceRepository.getEntityInstanceId(this.currentEntity.name, this.currentEntity.entityId));\r\n const hasPrivateView = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW, this.instanceId);\r\n const hasPrivateEdit = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, this.instanceId);\r\n\r\n this.hasInstancePrivateView = hasPrivateEdit || hasPrivateView;\r\n\r\n if (hasPrivateEdit) {\r\n if (this.currentEntity.entityTypeId != Core.EntityTypes.Company) {\r\n // check if user has site write permission\r\n this.hasWritePermission = await this._restrictService.hasSitePermission(+this._upgradeNavService.getQuerystringParam('siteId'), Core.AccessRightsEnum.Write);\r\n } else {\r\n this.hasWritePermission = await this._restrictService.hasCompanyPermission(+this._upgradeNavService.getQuerystringParam('companyId'), Core.AccessRightsEnum.Write);\r\n }\r\n }\r\n } else if (this.currentEntity.entityTypeId == Core.EntityTypes.Assessor) {\r\n this.hasWritePermission = this._restrictService.isInRole(Roles.ASSESSOREDIT);\r\n } else if (this.currentEntity.entityTypeId == Core.EntityTypes.Collector) {\r\n this.hasWritePermission = this._restrictService.isInRole(Roles.COLLECTOREDIT);\r\n }\r\n }\r\n\r\n private _getValidationMessage(descriptorsToSave: EntityDescriptorModelUI[]): string {\r\n const missingFields = _.some(descriptorsToSave, x => x.descriptor.fieldTypeID != Core.DescriptorFieldTypes.YesNo && !x.value && Number(x.value) !== 0);\r\n\r\n if (missingFields) {\r\n return 'Please fill in the missing fields';\r\n }\r\n\r\n const errors: string[] = [];\r\n\r\n const numberOutOfRange = _.chain(descriptorsToSave)\r\n .filter(x => x.descriptor.fieldTypeID == Core.DescriptorFieldTypes.Number)\r\n .some(y => {\r\n return (y.descriptor.validation.minValue && +y.value < y.descriptor.validation.minValue)\r\n || (y.descriptor.validation.maxValue && +y.value > y.descriptor.validation.maxValue);\r\n })\r\n .value();\r\n\r\n if (numberOutOfRange) {\r\n errors.push('At least one number is out of range');\r\n }\r\n\r\n const datesOutOfRange = _.chain(descriptorsToSave)\r\n .filter(x => x.descriptor.fieldTypeID == Core.DescriptorFieldTypes.Date)\r\n .some(y => {\r\n return (y.descriptor.validation.minValue && new Date(y.value).getUTCFullYear() < y.descriptor.validation.minValue)\r\n || (y.descriptor.validation.maxValue && new Date(y.value).getUTCFullYear() > y.descriptor.validation.maxValue);\r\n })\r\n .value();\r\n\r\n if (datesOutOfRange) {\r\n errors.push('At least one date is out of range');\r\n }\r\n\r\n return errors.join('
');\r\n }\r\n\r\n private _broadcastMaximize(): void {\r\n this._rootScope.$broadcast('maximize_change', {\r\n panelName: 'propertyCharacteristics',\r\n maximized: this.isMaximized\r\n });\r\n }\r\n\r\n private async _loadPanel() {\r\n this.currentEntity = this._getCurrentEntity();\r\n await this._doPermissionsCheck();\r\n\r\n this.loading = true;\r\n\r\n try {\r\n const descriptors = await this._entityDescriptorService.get(this.currentEntity.entityId, this.currentEntity.name) as EntityDescriptorModelUI[];\r\n this._setDescriptorViews(descriptors);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n\t
\r\n\t\t
\r\n\t\t\t\r\n\t\t
\r\n\t\t
\r\n\t\t\t\r\n\t\t
\r\n\t
\r\n\t
\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t
\r\n
\r\n
\r\n \r\n\t\t\t\t\r\n
\r\n
\r\n
\r\n
\r\n \r\n\t\t\t\t\r\n
\r\n
\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t
\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t
\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t
\r\n\t\t\t\t\t\r\n\t\t\t\t
\r\n\t\t\t
\r\n\t\t
\r\n
\r\n
\r\n \r\n
\r\n
\r\n\t
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { CompanyModel, CompanyService } from './company.service';\r\nimport { ParentCompanyModel } from './Info/companyInfoPanel.component';\r\nimport { CompanyEntity } from '../entity.model';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { CurrentEntityService } from '../../Common/Entity/CurrentEntityService';\r\nimport { InstanceRights, RestrictData, RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { EntityTypeIds, RyanInstanceId } from '../../constants.new';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\n\r\n@Component({\r\n selector: 'company-page',\r\n templateUrl: 'companyPage.component.html'\r\n})\r\n\r\nexport class CompanyPageComponent implements OnInit {\r\n constructor(private readonly _companyService: CompanyService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _currentEntityService: CurrentEntityService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _featureFlagService: FeatureFlagsService,\r\n private readonly _userInstanceService: UserInstanceService) { }\r\n\r\n serverAction: boolean = true;\r\n company: CompanyModel;\r\n parentCompany: ParentCompanyModel;\r\n entity: CompanyEntity;\r\n showComplianceInfo: boolean;\r\n hasWritePermission: boolean;\r\n\r\n private _hasRyanPrivateItemsEdit: boolean;\r\n private _hasRyanPrivateItemsView: boolean;\r\n\r\n get isTopLevel(): boolean {\r\n return !this.company.parentId;\r\n }\r\n\r\n get hasPrivateItemsPermission(): boolean {\r\n return this._featureFlagService.featureFlags.enableLicensedConsultingInvoicing\r\n ? (this._hasRyanPrivateItemsView || this._hasRyanPrivateItemsEdit) && this._userInstanceService.getSelectedInstance().instanceId === RyanInstanceId\r\n : ((this._hasRyanPrivateItemsView || this._hasRyanPrivateItemsEdit) && this.company.instanceID === RyanInstanceId);\r\n }\r\n\r\n get allowInvoiceEdit(): boolean {\r\n return this._hasRyanPrivateItemsEdit;\r\n }\r\n\r\n async ngOnInit() {\r\n this._hasRyanPrivateItemsView = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW) ||\r\n this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT);\r\n\t\tthis._hasRyanPrivateItemsEdit = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT);\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading company' });\r\n try {\r\n const companyId = +this._upgradeNavigationServiceHandler.getQuerystringParam('companyId');\r\n this.company = await this._companyService.load(companyId, false, true);\r\n\r\n this.entity = {\r\n id: this.company.companyID,\r\n type: 'company',\r\n typeId: Core.EntityTypes.Company,\r\n newAllowed: true,\r\n name: this.company.companyName,\r\n canEditCompanySetups: this.company.canEditCompanySetups,\r\n ppReturnPreparationAllowed: this.company.ppReturnPreparationAllowed,\r\n isTopLevel: this.isTopLevel,\r\n canEditCompany: this.company.canEditCompany,\r\n isInactive: this.company.activityStatusID === Core.ActivityStatuses.Inactive\r\n };\r\n this._currentEntityService.set(this.company, EntityTypeIds.COMPANY);\r\n\r\n this.setShowComplianceInfo(this.entity.ppReturnPreparationAllowed);\r\n\r\n const restrictionData = {\r\n isCompany: true,\r\n entityId: this.company.companyID,\r\n flag: Core.AccessRightsEnum.Write\r\n } as RestrictData;\r\n\r\n this.entity.hasWritePermission = await this._restrictService.hasPermission(restrictionData);\r\n this.hasWritePermission = this.entity.hasWritePermission && this.company.canEditCompany;\r\n\r\n if(!this.isTopLevel) {\r\n this.parentCompany = await this._companyService.loadCompanyParent(this.company.companyID, this.company.parentId, );\r\n }\r\n } finally {\r\n busyRef.hide();\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n setShowComplianceInfo(ppReturnPreparationAllowed: boolean): void {\r\n this.showComplianceInfo = ppReturnPreparationAllowed && this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, this.company.instanceID);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { SiteDescriptorsListComponent } from './Site-Descriptors-List/siteDescriptorsList.component';\r\nimport { SiteDescriptorSelectorComponent } from './Site-Descriptor-Selector/siteDescriptorSelector.component';\r\nimport { SiteDescriptorsEditComponent } from './Site-Descriptors-Edit/siteDescriptorsEdit.component';\r\nimport { ClientServicesPanelComponent } from './Panel/clientServicesPanel.component';\r\nimport { DeliveryDetailsComplianceReturnsComponent } from './Panel/Delivery-Details/deliveryDetailsComplianceReturns.component';\r\nimport { DeliveryDetailsTeamRetrievesComponent } from './Panel/Delivery-Details/deliveryDetailsTeamRetrieves.component';\r\nimport { DeliveryDetailsTransmitComponent } from './Panel/Delivery-Details/deliveryDetailsTransmit.component';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { DeliveryDetailsConfigureModalComponent } from './Panel/Delivery-Details/deliveryDetailsConfigureModal.component';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { DeliveryDetailsAssessmentAllocationComponent } from './Panel/Delivery-Details/deliveryDetailsAssessmentAllocation.component';\r\nimport { DeliveryDetailsPaymentBatchWorkflowComponent } from './Panel/Delivery-Details/deliveryDetailsPaymentBatchWorkflow.component';\r\nimport { deliveryDetailsFeedSpecsComponent } from './Panel/Delivery-Details/deliveryDetailsFeedSpecs.component';\r\n\r\n@NgModule({\r\n imports: [\r\n BusyIndicatorModule,\r\n CommonModule,\r\n WeissmanSharedModule,\r\n TypeaheadModule,\r\n CurrencyMaskModule,\r\n PopoverModule\r\n ],\r\n declarations: [\r\n SiteDescriptorsListComponent,\r\n SiteDescriptorsEditComponent,\r\n SiteDescriptorSelectorComponent,\r\n ClientServicesPanelComponent,\r\n DeliveryDetailsComplianceReturnsComponent,\r\n DeliveryDetailsTeamRetrievesComponent,\r\n DeliveryDetailsTransmitComponent,\r\n DeliveryDetailsConfigureModalComponent,\r\n DeliveryDetailsAssessmentAllocationComponent,\r\n DeliveryDetailsPaymentBatchWorkflowComponent,\r\n deliveryDetailsFeedSpecsComponent\r\n ],\r\n exports: [ClientServicesPanelComponent]\r\n})\r\nexport class ClientServicesModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('siteDescriptorsEdit', SiteDescriptorsEditComponent);\r\n hybridAdapterUtility.downgradeNg2Component('clientServicesPanel', ClientServicesPanelComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../../../Common/weissman-shared.module';\r\nimport { AssetClassSelectorComponent } from './assetClassSelector.component';\r\n\r\n@NgModule({\r\n imports: [WeissmanSharedModule],\r\n declarations: [AssetClassSelectorComponent],\r\n exports: [AssetClassSelectorComponent]\r\n})\r\nexport class AssetClassSelectorModule {\r\n}\r\n","import * as _ from 'lodash';\r\n\r\nexport interface IReturnPartComponent {\r\n onReturnPartServiceActivated: () => void;\r\n onReturnPartServiceDeactivated: () => void;\r\n}\r\n\r\n/**\r\n * A base class that all return part services must extend.\r\n * Gives each return part service an opportunity to notify subscribed components when that service is activated/deactivate.\r\n */\r\nexport abstract class ReturnPartServiceBase {\r\n private _subscribers: IReturnPartComponent[] = [];\r\n private _isActive: boolean = false;\r\n\r\n /**\r\n * Retrieves the shared state that is tracked in the service.\r\n */\r\n protected abstract get sharedState(): any;\r\n\r\n get isActive(): boolean {\r\n return this._isActive;\r\n }\r\n\r\n /**\r\n * Returns a clone of the shared state.\r\n */\r\n getSharedStateClone(): any {\r\n return _.cloneDeep(this.sharedState);\r\n }\r\n\r\n /**\r\n * Compares the specified state with the current shared state to determinie equality.\r\n * @param state The state to compare the current shared state to.\r\n * @param paths The paths to narrow down the comparison for.\r\n */\r\n hasSharedStateChanged(state: any, paths?: string[]): boolean {\r\n const o1 = paths ? _.pick(state, paths) : state;\r\n const o2 = paths ? _.pick(this.sharedState, paths) : this.sharedState;\r\n return _.isEqual(o1, o2);\r\n }\r\n\r\n /**\r\n * Subscribes a component to the service activation lifecycle.\r\n * @param handler The component that will handle service activation lifecycle events.\r\n */\r\n subscribeToServiceActivationCycle(handler: IReturnPartComponent) {\r\n this._subscribers.push(handler);\r\n // if they subscribe after the service is activate then notify activation immediately\r\n if (this._isActive) handler.onReturnPartServiceActivated();\r\n }\r\n\r\n /**\r\n * Unsubscribes a component from handling any events related to the lifecycle of the service.\r\n * @param handler The component that will stop handling service activation lifecycle events.\r\n */\r\n unsubscribeFromServiceActivationCycle(handler: IReturnPartComponent) {\r\n const index = this._subscribers.indexOf(handler);\r\n this._subscribers.splice(index, 1);\r\n handler.onReturnPartServiceDeactivated();\r\n }\r\n\r\n /**\r\n * Notifies that the service life cyle status has changes.\r\n * @param isActive Indicates if the service is active or not.\r\n */\r\n notifyServiceActivationChange(isActive: boolean): void {\r\n this._isActive = isActive;\r\n this._subscribers.forEach(x => this._isActive\r\n ? x.onReturnPartServiceActivated()\r\n : x.onReturnPartServiceDeactivated());\r\n }\r\n\r\n /**\r\n * Enables the service to initialize state\r\n */\r\n initialize(): void {\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpResponse } from '@angular/common/http';\r\nimport { BehaviorSubject, lastValueFrom, Observable, Subject } from 'rxjs';\r\nimport { ReturnAssetRepository, ReturnRepository } from '../../../Repositories';\r\nimport { ReturnService } from '../../return.service';\r\nimport { ReturnPartServiceBase } from '../../Models/returnPartServiceBase';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nexport enum AssessorFactorsEnum {\r\n SpecificAssessor = 0,\r\n AnyAssessor = -1,\r\n AssessorsUsingDefaultFactors = -2\r\n}\r\n\r\nexport interface AssessorFactorsFilter {\r\n assessorFactor: AssessorFactorsEnum;\r\n // a collection of IDs for all assessors that fall under the specified assessor factors filter\r\n assessorIds: number[];\r\n}\r\n\r\nexport interface ScheduleAndFactorFilter {\r\n showOnlyNotAssignedToASchedule: boolean;\r\n showOnlyAssignedToNonReportableSchedule: boolean;\r\n showOnlyAssignedToReportableSchedule: boolean;\r\n depreciationFactorId: number;\r\n scheduleAge: number;\r\n formRevisionScheduleIds: number[];\r\n userSelectedEmptySchedule?: boolean;\r\n}\r\n\r\nexport interface ReturnAssetsServiceSharedState {\r\n formRevisionId?: number;\r\n assetStatusesFilter: Compliance.ReturnAssetPriorReturnStatusEnum[];\r\n assessorFactorsFilter: AssessorFactorsFilter;\r\n scheduleAndFactorFilter: ScheduleAndFactorFilter;\r\n assetDetailsUpdatedTimestamp: number;\r\n assetMappingsUpdatedTimestamp: number;\r\n hideEmptySchedulesFilter: boolean;\r\n separateFactorTablesFilter: boolean;\r\n}\r\n\r\n@Injectable()\r\nexport class ReturnAssetsService extends ReturnPartServiceBase {\r\n constructor(\r\n private _returnAssetRepository: ReturnAssetRepository,\r\n private _returnRepository: ReturnRepository,\r\n private _returnService: ReturnService\r\n ) { super(); }\r\n\r\n private _sharedState: ReturnAssetsServiceSharedState = {\r\n assetStatusesFilter: [],\r\n assessorFactorsFilter: {\r\n assessorFactor: AssessorFactorsEnum.AnyAssessor,\r\n assessorIds: []\r\n },\r\n scheduleAndFactorFilter: {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n },\r\n assetDetailsUpdatedTimestamp: Date.now(),\r\n assetMappingsUpdatedTimestamp: Date.now(),\r\n hideEmptySchedulesFilter: true,\r\n separateFactorTablesFilter: false\r\n };\r\n private _hasResetNoDataFilterApplied: boolean;\r\n\r\n private _assetDetailsUpdatedSubject: Subject = new Subject();\r\n private _assetMappingsUpdatedSubject: Subject = new Subject();\r\n private _requestUpdatedSchedules: Subject = new Subject();\r\n private _assetStatusesFilterSubject: Subject = new Subject();\r\n private _assessorFactorsFilterSubject: Subject = new Subject();\r\n private _scheduleAndFactorFilterSubject: Subject = new BehaviorSubject(this._sharedState.scheduleAndFactorFilter);\r\n\r\n get sharedState(): ReturnAssetsServiceSharedState { return this._sharedState; }\r\n get hasResetNoDataFilterApplied(): boolean { return this._hasResetNoDataFilterApplied; }\r\n\r\n assetDetailsUpdated$: Observable = this._assetDetailsUpdatedSubject.asObservable();\r\n assetMappingsUpdated$: Observable = this._assetMappingsUpdatedSubject.asObservable();\r\n requestUpdatedSchedules$: Observable = this._requestUpdatedSchedules.asObservable();\r\n assetStatusesFilter$: Observable = this._assetStatusesFilterSubject.asObservable();\r\n assessorFactorsFilter$: Observable = this._assessorFactorsFilterSubject.asObservable();\r\n scheduleAndFactorFilter$: Observable = this._scheduleAndFactorFilterSubject.asObservable();\r\n\r\n initialize(): void {\r\n this._sharedState = {\r\n assetStatusesFilter: [],\r\n assessorFactorsFilter: {\r\n assessorFactor: AssessorFactorsEnum.AnyAssessor,\r\n assessorIds: []\r\n },\r\n scheduleAndFactorFilter: {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n },\r\n assetDetailsUpdatedTimestamp: Date.now(),\r\n assetMappingsUpdatedTimestamp: Date.now(),\r\n hideEmptySchedulesFilter: true,\r\n separateFactorTablesFilter: false\r\n };\r\n }\r\n\r\n notifyServiceActivationChange(isActive: boolean, state?: ReturnAssetsServiceSharedState): void {\r\n if (state) {\r\n this._sharedState = _.cloneDeep(state);\r\n }\r\n super.notifyServiceActivationChange(isActive);\r\n }\r\n\r\n requestUpdatedSchedules(): void {\r\n this._requestUpdatedSchedules.next();\r\n }\r\n\r\n setAssessorFactorsFilter(assessorFactor: AssessorFactorsEnum, assessorIds: number[]): void {\r\n this._sharedState.assessorFactorsFilter = {\r\n assessorFactor: assessorFactor,\r\n assessorIds: assessorIds\r\n };\r\n this._assessorFactorsFilterSubject.next(this._sharedState.assessorFactorsFilter);\r\n }\r\n\r\n setScheduleAndFactorFilter(scheduleFactorFilter: ScheduleAndFactorFilter): void {\r\n this._sharedState.scheduleAndFactorFilter = scheduleFactorFilter;\r\n\r\n this._hasResetNoDataFilterApplied = !scheduleFactorFilter.userSelectedEmptySchedule\r\n && (scheduleFactorFilter.showOnlyNotAssignedToASchedule\r\n || (scheduleFactorFilter.formRevisionScheduleIds.length && !(scheduleFactorFilter.showOnlyAssignedToReportableSchedule || scheduleFactorFilter.showOnlyAssignedToNonReportableSchedule))\r\n || !!scheduleFactorFilter.depreciationFactorId\r\n || !!scheduleFactorFilter.scheduleAge);\r\n this._scheduleAndFactorFilterSubject.next(this._sharedState.scheduleAndFactorFilter);\r\n }\r\n\r\n setAssetStatusesFilter(assetStatusesFilter: Compliance.ReturnAssetPriorReturnStatusEnum[]): void {\r\n this._sharedState.assetStatusesFilter = assetStatusesFilter;\r\n this._assetStatusesFilterSubject.next(undefined);\r\n }\r\n\r\n setHideEmptySchedulesFilter(value: boolean): void {\r\n this._sharedState.hideEmptySchedulesFilter = value;\r\n }\r\n\r\n setSeparateFactorTablesFilter(value: boolean): void {\r\n this._sharedState.separateFactorTablesFilter = value;\r\n }\r\n\r\n async getScheduleDetails(forAllFormRevisions: boolean = false): Promise {\r\n const searchModel: Compliance.ReturnAssetScheduleDetailsSearchModel = {\r\n assessorFilter: this._getAssessorFilterForSelectedAssessorFactors(),\r\n formRevisionIds: forAllFormRevisions ? this._returnService.getUniqueAssociatedReturnFormRevisions().map(x => x.formRevisionId) : [this._returnService.sharedState.formRevisionId],\r\n parcelIds: this._returnService.sharedState.returns.map(x => x.parcelId),\r\n formScheduleIds: [],\r\n formFactorTableId: 0,\r\n priorReturnStatuses: this._sharedState.assetStatusesFilter,\r\n aggregationLevel: Compliance.ScheduleDetailsAggregationLevelEnum.FactorTable,\r\n includeMergedParcels: false\r\n };\r\n\r\n // form revision selection is required\r\n if ((this._returnService.sharedState.formRevisionId || forAllFormRevisions) && searchModel.parcelIds.length) {\r\n return await lastValueFrom(this._returnAssetRepository.getScheduleDetailsByFilingBatch(this._returnService.filingBatchId, searchModel));\r\n } else {\r\n return [] as Compliance.ReturnAssetScheduleDetailsAssignedItemModel[];\r\n }\r\n }\r\n\r\n async getUnassignedScheduleDetails(): Promise {\r\n const searchModel: Compliance.ReturnAssetScheduleDetailsSearchModel = {\r\n assessorFilter: this._getAssessorFilterForSelectedAssessorFactors(),\r\n formRevisionIds: [this._returnService.sharedState.formRevisionId],\r\n parcelIds: this._returnService.sharedState.returns.map(x => x.parcelId),\r\n formScheduleIds: [],\r\n formFactorTableId: 0,\r\n priorReturnStatuses: this._sharedState.assetStatusesFilter,\r\n aggregationLevel: Compliance.ScheduleDetailsAggregationLevelEnum.Schedule,\r\n includeMergedParcels: false\r\n };\r\n\r\n // form revision selection is required\r\n if (this._returnService.sharedState.formRevisionId && searchModel.parcelIds.length) {\r\n return await lastValueFrom(this._returnAssetRepository.getUnassignedScheduleDetailsByFilingBatch(this._returnService.filingBatchId, searchModel));\r\n } else {\r\n return [] as Compliance.ReturnAssetScheduleDetailsUnassignedItemModel[];\r\n }\r\n }\r\n\r\n async exportAssets(exportModel: Compliance.ReturnAssetExportModel) : Promise{\r\n return await lastValueFrom(this._returnAssetRepository.exportReturnAssets(this._returnService.filingBatchId, exportModel));\r\n }\r\n\r\n getAssetExport(longRunningProcessId: number): Observable> {\r\n if (this._returnService.sharedState.formRevisionId) {\r\n return this._returnAssetRepository.getReturnAssetsExport(this._returnService.filingBatchId, longRunningProcessId);\r\n }\r\n }\r\n\r\n async updateAssetMappings(updateModel: Compliance.ReturnAssetUpdateModel): Promise {\r\n await lastValueFrom(this._returnAssetRepository.updateByFilingBatch(this._returnService.filingBatchId, updateModel));\r\n this._sharedState.assetMappingsUpdatedTimestamp = Date.now();\r\n this._assetMappingsUpdatedSubject.next();\r\n return Promise.resolve();\r\n }\r\n\r\n async notifyAssetDetailsUpdated(reportingAssetIds = [], recalculateWorkingSet: boolean = true): Promise {\r\n if (recalculateWorkingSet) {\r\n await lastValueFrom(this._returnRepository.updateWorkingSet(this._returnService.filingBatchId, reportingAssetIds));\r\n }\r\n this._sharedState.assetDetailsUpdatedTimestamp = Date.now();\r\n this._assetDetailsUpdatedSubject.next();\r\n return Promise.resolve();\r\n }\r\n\r\n async updateWorkingSet(reportingAssetIds = [], recalculateWorkingSet: boolean = true): Promise {\r\n if (recalculateWorkingSet) {\r\n await lastValueFrom(this._returnRepository.updateWorkingSet(this._returnService.filingBatchId, reportingAssetIds));\r\n }\r\n return Promise.resolve();\r\n }\r\n\r\n async getAssessors(reportingAssetIds: number[]): Promise {\r\n return await lastValueFrom(this._returnAssetRepository.getAssessorsByFilingBatch(this._returnService.filingBatchId, {\r\n parcelIds: this._returnService.sharedState.returns.map(x => x.parcelId) || [],\r\n formRevisionId: this._returnService.sharedState.formRevisionId,\r\n reportingAssetIds: reportingAssetIds\r\n } as Compliance.ReturnAssetAssessorModel));\r\n }\r\n\r\n async getWorkingSetAssessors(reportingAssetIds: number[]): Promise {\r\n return await lastValueFrom(this._returnAssetRepository.getWorkingSetAssessorsByFilingBatch(this._returnService.filingBatchId, {\r\n formRevisionId: this._returnService.sharedState.formRevisionId,\r\n reportingAssetIds: reportingAssetIds\r\n } as Compliance.ReturnAssetAssessorModel));\r\n }\r\n\r\n clearScheduleAndFactorFilter(): void {\r\n const scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n this.setScheduleAndFactorFilter(scheduleAndFactorFilter);\r\n }\r\n\r\n getAssessorsByFilingBatch(filingBatchId: number, searchModel: Compliance.ReturnAssetAssessorModel): Promise {\r\n return lastValueFrom(this._returnAssetRepository.getAssessorsByFilingBatch(filingBatchId, searchModel));\r\n }\r\n\r\n /**\r\n * Based on the Assessor Factors selection it will return the correct assessor filter.\r\n * If a specific assessor is specified it will return the ID of that assessor. If not, it will return the value * of the assessor factor filter.\r\n */\r\n private _getAssessorFilterForSelectedAssessorFactors(): number {\r\n switch (this._sharedState.assessorFactorsFilter.assessorFactor) {\r\n case AssessorFactorsEnum.AnyAssessor: return AssessorFactorsEnum.AnyAssessor;\r\n case AssessorFactorsEnum.AssessorsUsingDefaultFactors: return AssessorFactorsEnum.AssessorsUsingDefaultFactors;\r\n case AssessorFactorsEnum.SpecificAssessor: return this._sharedState.assessorFactorsFilter.assessorIds[0];\r\n default: throw new Error('ReturnAssetsService._getAssessorFilterForSelectedAssessorFactors - Unexpected parameters.');\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ReturnPartServiceBase } from '../../Models/returnPartServiceBase';\r\nimport { ReturnService } from '../../return.service';\r\nimport { AssessorFactorsEnum, ReturnAssetsServiceSharedState } from '../Assets/returnAssets.service';\r\nimport { ReturnAssetRepository, ReturnRepository } from '../../../Repositories';\r\nimport { ScheduleAdditionsDisposalsReconciliationReport } from '../../Models/scheduleAdditionsDisposalsReconciliationReport';\r\nimport { ReturnSummaryReconciliationReport } from '../../Models/returnSummaryReconciliationReport';\r\nimport { Subject, Observable, lastValueFrom } from 'rxjs';\r\nimport { FilingControlReconciliationReport } from '../../Models/filingControlReconciliationReport';\r\nimport { ReconciliationReport } from '../../Models/reconciliationReport';\r\nimport { ReturnPreviewServiceSharedState } from '../Preview/returnPreview.service';\r\n\r\nexport interface ReturnOverviewServiceSharedState {\r\n reconciliationReport: ReconciliationReport;\r\n firstLoad: boolean;\r\n}\r\n\r\nexport enum FilingControlGroupBy {\r\n None,\r\n Assessor,\r\n Consolidated\r\n}\r\n\r\n@Injectable()\r\nexport class ReturnOverviewService extends ReturnPartServiceBase {\r\n constructor(\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _returnAssetRepository: ReturnAssetRepository,\r\n private readonly _returnService: ReturnService\r\n ) { super(); }\r\n\r\n private _sharedState: ReturnOverviewServiceSharedState = {\r\n reconciliationReport: null\r\n } as ReturnOverviewServiceSharedState;\r\n\r\n private readonly returnSummaryReconciliationReport: ReconciliationReport = {\r\n name: 'Return Summary',\r\n value: 0,\r\n allowPrimaryForReturn: true\r\n };\r\n\r\n private readonly scheduleAdditionsDisposalsReconciliationReport: ReconciliationReport = {\r\n name: 'Schedule Additions and Disposals',\r\n value: 1,\r\n allowPrimaryForReturn: false\r\n };\r\n\r\n private readonly filingControlReconciliationReport: ReconciliationReport = {\r\n name: 'Filing Control',\r\n value: 2,\r\n allowPrimaryForReturn: true\r\n };\r\n\r\n private _reconciliationReports: ReconciliationReport[] = [\r\n this.returnSummaryReconciliationReport,\r\n this.scheduleAdditionsDisposalsReconciliationReport,\r\n this.filingControlReconciliationReport\r\n ];\r\n\r\n private _reconciliationReportSubject: Subject = new Subject();\r\n private _returnAssetsSelectedSubject: Subject = new Subject();\r\n private _returnPreviewSelectedSubject: Subject = new Subject();\r\n\r\n get sharedState(): ReturnOverviewServiceSharedState { return this._sharedState; }\r\n get reconciliationReports(): ReconciliationReport[] { return this._reconciliationReports; }\r\n get availableReconciliationReports(): ReconciliationReport[] {\r\n return this._reconciliationReports.filter(x => x.allowPrimaryForReturn || !!this._returnService.getUniqueAssociatedReturnFormRevisions().length);\r\n }\r\n\r\n get reconciliationReport$(): Observable { return this._reconciliationReportSubject.asObservable(); }\r\n get returnAssetsSelected$(): Observable { return this._returnAssetsSelectedSubject.asObservable(); }\r\n get returnPreviewSelected$(): Observable { return this._returnPreviewSelectedSubject.asObservable(); }\r\n\r\n initialize(): void {\r\n this._sharedState = {\r\n reconciliationReport: null,\r\n firstLoad: true // on first load, do not load the report because it is part of the filing batch start payload\r\n } as ReturnOverviewServiceSharedState;\r\n }\r\n\r\n setReconciliationReport(reconciliationReport: ReconciliationReport): void {\r\n this._sharedState.reconciliationReport = reconciliationReport;\r\n\r\n // if the report doesn't support primary for return and primary for return is selected, select a form\r\n if ((!reconciliationReport.allowPrimaryForReturn) && (!this._returnService.sharedState.formRevisionId)) {\r\n this._returnService.setFirstFormRevisionId();\r\n }\r\n\r\n this._reconciliationReportSubject.next(this._sharedState.reconciliationReport);\r\n }\r\n\r\n notifyReturnAssetsSelected(value: ReturnAssetsServiceSharedState): void {\r\n this._returnAssetsSelectedSubject.next(value);\r\n }\r\n\r\n notifyReturnPreviewSelected(value: ReturnPreviewServiceSharedState): void {\r\n this._returnPreviewSelectedSubject.next(value);\r\n }\r\n\r\n async getScheduleAdditionsDisposalReconciliationReport(): Promise {\r\n // the schedule summary returns information about assets not assigned to a schedule\r\n // using this API call to put together a list of all the schedules that needs to be passed to schedule details\r\n const searchModel = {\r\n assessorFilter: AssessorFactorsEnum.AnyAssessor,\r\n formRevisionIds: [this._returnService.sharedState.formRevisionId],\r\n parcelIds: this._returnService.sharedState.returns.map(x => x.parcelId),\r\n priorReturnStatuses: [],\r\n aggregationLevel: Compliance.ScheduleDetailsAggregationLevelEnum.Schedule\r\n } as Compliance.ReturnAssetScheduleDetailsSearchModel;\r\n\r\n const responses = await Promise.all([\r\n lastValueFrom(this._returnAssetRepository.getScheduleDetailsByFilingBatch(this._returnService.filingBatchId, searchModel)),\r\n lastValueFrom(this._returnAssetRepository.getUnassignedScheduleDetailsByFilingBatch(this._returnService.filingBatchId, searchModel))\r\n ]);\r\n\r\n const assignedScheduleDetails = responses[0] as Compliance.ReturnAssetScheduleDetailsAssignedItemModel[];\r\n const unassignedScheduleDetails: Compliance.ReturnAssetScheduleDetailsUnassignedItemModel[] = responses[1];\r\n\r\n return new ScheduleAdditionsDisposalsReconciliationReport(assignedScheduleDetails, unassignedScheduleDetails);\r\n }\r\n\r\n async getReturnSummaryReconciliationReport(): Promise {\r\n let returnSummaryResult: Compliance.ReturnSummaryModel;\r\n\r\n /* Initial state is null, so since first load, we'll assume the first one is ok.*/\r\n if (this._sharedState?.firstLoad && this._returnService.returnSummary) {\r\n returnSummaryResult = this._returnService.returnSummary;\r\n this._sharedState.firstLoad = false;\r\n } else {\r\n const inUseReturnFormRevisions = this._returnService.getAssociatedReturnFormRevisions();\r\n const formRevisions = inUseReturnFormRevisions.filter(x => x.formRevisionId === this._returnService.sharedState.formRevisionId);\r\n let parcelIds: number[];\r\n\r\n //Check if a specific form is selected\r\n if (formRevisions.length !== 0) {\r\n parcelIds = this._returnService.sharedState.returns\r\n .filter(x => formRevisions.map(y => y.returnId).includes(x.returnId))\r\n .map(x => x.parcelId);\r\n } else { //Primary for return form is selected\r\n parcelIds = this._returnService.sharedState.returns.map(x => x.parcelId);\r\n }\r\n\r\n returnSummaryResult = await lastValueFrom(this._returnRepository.getReturnSummary(\r\n this._returnService.filingBatchId,\r\n this._returnService.sharedState.formRevisionId,\r\n parcelIds\r\n ));\r\n }\r\n return new ReturnSummaryReconciliationReport(returnSummaryResult);\r\n }\r\n\r\n async getFilingControlReconciliationReport(): Promise {\r\n const filingControlSummaryResult: Compliance.ReturnFilingControlSummaryModel = await lastValueFrom(this._returnRepository.getReturnFilingControlSummary(\r\n this._returnService.filingBatchId,\r\n this._returnService.sharedState.formRevisionId,\r\n this._returnService.sharedState.returns.map(x => x.parcelId)\r\n ));\r\n\r\n return new FilingControlReconciliationReport(filingControlSummaryResult, this._returnService.getAssociatedReturnFormRevisions(),\r\n this._returnService.sharedState.returns);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable, Subject, Subscription, BehaviorSubject, lastValueFrom } from 'rxjs';\r\nimport { FormRepository, FilingBatchRepository, ReturnRepository, ReturnFormRevisionRepository } from '../Repositories';\r\nimport { WebsocketListenerService } from '../websocketListener.service';\r\nimport { ReturnPartServiceBase } from './Models/returnPartServiceBase';\r\nimport { HttpResponse } from '@angular/common/http';\r\nimport { FilingBatchService } from '../Filing-Batch/filingBatch.service';\r\nimport * as _ from 'lodash';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { AgGridColumns, AgGridFilterParams } from '../AgGrid';\r\nimport {\r\n AgGridCheckboxCellRendererComponent,\r\n ICellRendererParamsForAgGridCheckbox\r\n} from '../AgGrid/CellRenderers/agGridCheckboxCellRender.component';\r\nimport { ColDef } from 'ag-grid-community';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { WeissmanDateFormatPipe } from '../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\n\r\nexport interface ReturnServiceSharedState {\r\n returns: Compliance.ReturnTotalsModel[];\r\n reports?: Compliance.FilingBatchReportModel[];\r\n formRevisionId: number;\r\n returnFormRevisionsUpdatedTimestamp: number;\r\n}\r\n\r\n@Injectable()\r\nexport class ReturnService extends ReturnPartServiceBase {\r\n constructor(\r\n private readonly _formRepository: FormRepository,\r\n private readonly _filingBatchRepository: FilingBatchRepository,\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _websocketListenerService: WebsocketListenerService,\r\n private readonly _returnFormRevisionRepository: ReturnFormRevisionRepository,\r\n private readonly _filingBatchService: FilingBatchService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _datePipe: WeissmanDateFormatPipe\r\n ) { super(); }\r\n\r\n private _sharedState: ReturnServiceSharedState = {\r\n returns: [],\r\n reports: [],\r\n formRevisionId: null,\r\n returnFormRevisionsUpdatedTimestamp: null\r\n };\r\n\r\n // a list of available form revision for each assessor in the selected returns\r\n private _associatedReturnFormRevisions: Compliance.ReturnFormRevisionModel[] = [];\r\n private _notAssociatedReturnFormRevisions: Compliance.ReturnFormRevisionModel[] = [];\r\n\r\n // a dictionary of key/value pairs tracking the latest selected form revision for each filing or filing batch\r\n // the filing (or filing batch) ID is the key and the form revision ID is the value\r\n private _lastSelectedFormRevisionIds = {\r\n filingBatch: {}\r\n };\r\n\r\n private _filingBatch: Compliance.FilingBatchModel;\r\n private _lienDate: Date;\r\n private _tasks: Core.TaskModel[] = [];\r\n private _priorCompletedTask: Core.TaskModel;\r\n private _currentTask: Core.TaskModel;\r\n private _nextTask: Core.TaskModel;\r\n private _company: Core.CompanyModel;\r\n private _canEditCompany: boolean;\r\n private _canViewRyanPrivateItems: boolean;\r\n private _companyAssetDescriptorMappings: Compliance.CompanyAssetDescriptorMappingModel[];\r\n private _formRevisionId: number;\r\n private _validateFormsResult: Compliance.ReturnValidateFormsResultModel;\r\n private _compareFormsResult: Compliance.ReturnCompareFormsResultModel;\r\n private _returnSummary: Compliance.ReturnSummaryModel;\r\n private _isReturnInReadOnly: boolean = true;\r\n private _returnGroupDetails: Compliance.ReturnTotalsModel[] = [];\r\n private _consolidatedReturns: Set = new Set();\r\n private _isConsolidatedReturn: boolean;\r\n private _cutOffDate: Date;\r\n private _changeDetection: string;\r\n private _ages: string[];\r\n\r\n private _startSubject: Subject = new Subject();\r\n private _returnsSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _formRevisionIdSubject: Subject = new Subject();\r\n private _filingBatchProcessStatusSubject: Subject = new Subject();\r\n private _filingBatchProgressSubject: Subject = new Subject();\r\n private _isReturnInReadOnlyModeSubject: BehaviorSubject = new BehaviorSubject(this.isReturnInReadOnly);\r\n private _tasksSubject: Subject = new Subject();\r\n private _compareFormsSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _validateFormsSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _returnBatchFilterSubject: Subject = new Subject();\r\n private _longRunningProcessIdSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _parcelsChangedSubject: BehaviorSubject = new BehaviorSubject(null);\r\n\r\n // subscriptions\r\n private _filingBatchStatusChangeSub: Subscription;\r\n private _filingBatchProgressChangeSub: Subscription;\r\n\r\n get sharedState(): ReturnServiceSharedState { return this._sharedState; }\r\n get editGroup(): string { return 'return-edit-group'; }\r\n get company(): Core.CompanyModel { return this._company; }\r\n get companyId(): number { return this._company && this._company.companyID; }\r\n get canEditCompany(): boolean { return this._canEditCompany; }\r\n get canViewRyanPrivateItems(): boolean { return this._canViewRyanPrivateItems; }\r\n get companyAssetDescriptorMappings(): Compliance.CompanyAssetDescriptorMappingModel[] { return this._companyAssetDescriptorMappings; }\r\n get filingBatch(): Compliance.FilingBatchModel { return this._filingBatch; }\r\n get filingBatchId(): number { return this._filingBatch ? this.filingBatch.filingBatchId : null; }\r\n get longRunningProcessId(): number { return this._filingBatch && this._filingBatch.longRunningProcessId; }\r\n get tasks(): Core.TaskModel[] { return this._tasks; }\r\n get priorCompletedTask(): Core.TaskModel { return this._priorCompletedTask; }\r\n get currentTask(): Core.TaskModel { return this._currentTask; }\r\n get nextTask(): Core.TaskModel { return this._nextTask; }\r\n get taxYear(): number { return this._filingBatch ? this.filingBatch.taxYear : null; }\r\n get stateId(): number { return this._filingBatch ? this.filingBatch.stateId : null; }\r\n get lienDate(): Date { return this._lienDate; }\r\n get formRevisionId(): number { return this._formRevisionId; }\r\n get processStatus(): Compliance.FilingBatchProcessStatusEnum { return this._filingBatch && this._filingBatch.processStatus; }\r\n get processStatusError(): string { return this._filingBatch && this._filingBatch.longRunningProcessError; }\r\n get isReturnInReadOnlyMode(): boolean { return this._isReturnInReadOnlyMode(); }\r\n get isReturnInReadOnlyMode$(): Observable { return this._isReturnInReadOnlyModeSubject.asObservable(); }\r\n get isLongRunningProcessActive(): boolean { return this._filingBatchService.isLongRunningProcessActive(this._filingBatch && this._filingBatch.processStatus); }\r\n get isNotStarted(): boolean { return this._filingBatchService.isNotStarted(this._filingBatch && this._filingBatch.processStatus); }\r\n get isLocking(): boolean { return this._filingBatchService.isLocking(this._filingBatch && this._filingBatch.processStatus); }\r\n get isUnlocking(): boolean { return this._filingBatchService.isUnlocking(this._filingBatch && this._filingBatch.processStatus); }\r\n get isLocked(): boolean { return this._filingBatchService.isLocked(this._filingBatch && this._filingBatch.processStatus); }\r\n get isFinalizing(): boolean { return this._filingBatchService.isFinalizing(this._filingBatch && this._filingBatch.processStatus); };\r\n get isFinalized(): boolean { return this._filingBatchService.isFinalized(this._filingBatch && this._filingBatch.processStatus); };\r\n get isSigning(): boolean { return this._filingBatchService.isSigning(this._filingBatch && this._filingBatch.processStatus); };\r\n get isUnsigning(): boolean { return this._filingBatchService.isUnsigning(this._filingBatch && this._filingBatch.processStatus); };\r\n get isSigned(): boolean { return this._filingBatchService.isSigned(this._filingBatch && this._filingBatch.processStatus); };\r\n get parcelName(): string { return this._sharedState.returns.length && this._sharedState.returns[0].parcelAcctNumber; }\r\n get parcelId(): number { return this._sharedState.returns.length && this._sharedState.returns[0].parcelId; }\r\n get returnGroupDetails(): Compliance.ReturnTotalsModel[] { return this._returnGroupDetails }\r\n get validateFormsResult(): Compliance.ReturnValidateFormsResultModel { return this._validateFormsResult; }\r\n get compareFormsResult(): Compliance.ReturnCompareFormsResultModel { return this._compareFormsResult; }\r\n get returnSummary(): Compliance.ReturnSummaryModel { return this._returnSummary; }\r\n get isReturnInReadOnly(): boolean { return this._isReturnInReadOnly; }\r\n get isConsolidatedReturn(): boolean { return this._isConsolidatedReturn; } //todo: a batch has many returns and could be a mix of consolidated and not consolidated, so it doesn't make sense to have a single flag here\r\n\r\n get start$(): Observable { return this._startSubject.asObservable(); }\r\n get returns$(): Observable { return this._returnsSubject.asObservable() }\r\n get formRevisionId$(): Observable { return this._formRevisionIdSubject.asObservable(); }\r\n get processStatus$(): Observable { return this._filingBatchProcessStatusSubject.asObservable(); }\r\n get progress$(): Observable { return this._filingBatchProgressSubject.asObservable(); }\r\n get tasks$(): Observable { return this._tasksSubject.asObservable(); }\r\n get compareForms$(): Observable { return this._compareFormsSubject.asObservable(); }\r\n get validateForms$(): Observable { return this._validateFormsSubject.asObservable(); }\r\n get returnBatchFilter$(): Observable { return this._returnBatchFilterSubject.asObservable(); };\r\n get longRunningProcessId$(): Observable { return this._longRunningProcessIdSubject.asObservable(); }\r\n get parcelsChanged$(): Observable { return this._parcelsChangedSubject.asObservable(); }\r\n\r\n async prepareData(filingBatchId: number, onlyReloadFilingBatchDetails: boolean = false): Promise {\r\n this._sharedState.returns = [];\r\n this._sharedState.reports = [];\r\n\r\n const startRequest: Compliance.ReturnPrepareDataRequestModel = {\r\n filingBatchId: filingBatchId,\r\n forceCurrent: false,\r\n formRevisionId: this._getLastSelectedFormRevisionId(filingBatchId)\r\n };\r\n\r\n const result = await lastValueFrom(this._returnRepository.prepareData(startRequest));\r\n this._setData(result, onlyReloadFilingBatchDetails);\r\n }\r\n\r\n async startPrepareData(filingBatchId: number): Promise {\r\n this._sharedState.returns = [];\r\n this._sharedState.reports = [];\r\n this._filingBatch.processStatus = Compliance.FilingBatchProcessStatusEnum.PreparingData;\r\n\r\n const startRequest: Compliance.ReturnPrepareDataRequestModel = {\r\n filingBatchId: filingBatchId,\r\n forceCurrent: false,\r\n formRevisionId: this._getLastSelectedFormRevisionId(filingBatchId)\r\n };\r\n\r\n const result = await lastValueFrom(this._returnRepository.startPrepareData(startRequest));\r\n\r\n this._filingBatch.longRunningProcessId = result.longRunningProcessId;\r\n this._filingBatch.processStatus = result.filingBatchProcessStatus;\r\n this._longRunningProcessIdSubject.next(result.longRunningProcessId);\r\n this.notifyProcessStatusChange(result.filingBatchProcessStatus);\r\n }\r\n\r\n async loadPreparedData(filingBatchId: number, onlyReloadFilingBatchDetails: boolean = false): Promise {\r\n this._sharedState.returns = [];\r\n this._sharedState.reports = [];\r\n\r\n const result = await lastValueFrom(this._returnRepository.getPreparedData(filingBatchId));\r\n\r\n this._setData(result, onlyReloadFilingBatchDetails);\r\n }\r\n\r\n stop(): void {\r\n this._sharedState = {\r\n returns: [],\r\n reports: [],\r\n formRevisionId: null,\r\n returnFormRevisionsUpdatedTimestamp: null\r\n };\r\n this._associatedReturnFormRevisions = [];\r\n this._notAssociatedReturnFormRevisions = [];\r\n this._filingBatch = null;\r\n this._lienDate = null;\r\n this._tasks = [];\r\n this._priorCompletedTask = null;\r\n this._currentTask = null;\r\n this._nextTask = null;\r\n this._company = null;\r\n this._canEditCompany = false\r\n this._canViewRyanPrivateItems = false;\r\n this._companyAssetDescriptorMappings = null;\r\n this._formRevisionId = null;\r\n this._validateFormsResult = null;\r\n this._compareFormsResult = null;\r\n this._returnSummary = null;\r\n this._isReturnInReadOnly = true;\r\n this._returnGroupDetails = [];\r\n this._consolidatedReturns = new Set();\r\n this._isConsolidatedReturn = false;\r\n\r\n this._returnsSubject.next(null);\r\n this._isReturnInReadOnlyModeSubject.next(this._isReturnInReadOnly);\r\n this._compareFormsSubject.next(null);\r\n this._validateFormsSubject.next(null);\r\n this._longRunningProcessIdSubject.next(null);\r\n this._parcelsChangedSubject.next(null);\r\n\r\n this._filingBatchStatusChangeSub && this._filingBatchStatusChangeSub.unsubscribe();\r\n this._filingBatchProgressChangeSub && this._filingBatchProgressChangeSub.unsubscribe();\r\n }\r\n\r\n /**\r\n * Sets the collection of returns that the user has selected as part of the working set.\r\n * Loads all the available forms for the assessors on the selected returns.\r\n * @param returns Returns\r\n */\r\n setReturns(returns: Compliance.ReturnTotalsModel[]): void {\r\n this._sharedState.returns = returns || [];\r\n\r\n // get the last used form revision\r\n const lastSelectedFormRevisionId = this._getLastSelectedFormRevisionId(this._filingBatch.filingBatchId);\r\n this._setFormRevisionId(lastSelectedFormRevisionId);\r\n returns.forEach(x => {\r\n if(x.isMergedParcel|| x.isConsolidatedParcel) {\r\n this._consolidatedReturns.add(x.returnId)\r\n }\r\n });\r\n\r\n this._isConsolidatedReturn = returns.some(x => x.isMergedParcel);\r\n\r\n this._sharedState.returnFormRevisionsUpdatedTimestamp = Date.now();\r\n\r\n this._returnsSubject.next(this._sharedState.returns);\r\n }\r\n\r\n\r\n /**\r\n * Basically the same as setReturns but makes a request to update the return forms\r\n * This is only used when the user changes the checkboxes in the return batch list\r\n * @param returns\r\n */\r\n async setReturnFilterChanged(returns: Compliance.ReturnTotalsModel[]): Promise {\r\n this._sharedState.returns = returns || [];\r\n\r\n // get the last used form revision\r\n const lastSelectedFormRevisionId = this._getLastSelectedFormRevisionId(this._filingBatch.filingBatchId);\r\n this._setFormRevisionId(lastSelectedFormRevisionId);\r\n returns.forEach(x => {\r\n if(x.isMergedParcel|| x.isConsolidatedParcel) {\r\n this._consolidatedReturns.add(x.returnId)\r\n }\r\n });\r\n this._isConsolidatedReturn = returns.some(x => x.isMergedParcel);\r\n\r\n this._sharedState.returnFormRevisionsUpdatedTimestamp = Date.now();\r\n\r\n await this.loadReturnFormRevisions();\r\n this._returnsSubject.next(this._sharedState.returns);\r\n }\r\n\r\n setReturnTotals(returnDetails: Compliance.ReturnTotalsModel[]): void {\r\n this._returnGroupDetails = returnDetails;\r\n }\r\n\r\n setFirstFormRevisionId(saveToSharedState = false): void {\r\n const primaryFormCount = this._associatedReturnFormRevisions.reduce((acc, x) => {\r\n if (!acc[x.formRevisionId]) {\r\n acc.count += x.isPrimary ? 1 : 0;\r\n acc[x.formRevisionId] = true;\r\n }\r\n return acc;\r\n }, { count: 0 }).count;\r\n const firstFormRevision = _.find(this._associatedReturnFormRevisions);\r\n const formRevisionId = (primaryFormCount <= 1 && firstFormRevision) ? firstFormRevision.formRevisionId : null;\r\n if (saveToSharedState) {\r\n this.setFormRevisionId(formRevisionId);\r\n } else {\r\n this._formRevisionId = formRevisionId;\r\n this._formRevisionIdSubject.next(this._formRevisionId);\r\n }\r\n }\r\n\r\n /**\r\n * Sets the form revision that the user has selected for the specified working set.\r\n * @param formRevisionId The form revision ID.\r\n */\r\n setFormRevisionId(formRevisionId: number): void {\r\n this._formRevisionId = formRevisionId;\r\n this._setFormRevisionId(formRevisionId);\r\n this._formRevisionIdSubject.next(formRevisionId);\r\n }\r\n\r\n getDefaultFactorTables(): Promise {\r\n return lastValueFrom(this._formRepository.getFactorTableList({\r\n taxYear: this.taxYear,\r\n stateId: this.stateId,\r\n tableType: null,\r\n includeRetiredTables: false\r\n } as Compliance.FactorTableSearchModel))\r\n .then(x => x.filter(item => item.assessorName === null));\r\n }\r\n\r\n /**\r\n * Returns all the form revisions that are associated with the selected returns.\r\n */\r\n getAssociatedReturnFormRevisions(): Compliance.ReturnFormRevisionModel[] {\r\n return this._associatedReturnFormRevisions;\r\n }\r\n\r\n getUniqueAssociatedReturnFormRevisions(): Compliance.ReturnFormRevisionModel[] {\r\n return _.uniqBy(this._associatedReturnFormRevisions, x => x.formRevisionId);\r\n }\r\n\r\n /**\r\n * Gets all the form revisions that are available to be associated with the selected returns.\r\n */\r\n getNotAssociatedReturnFormRevisions(): Compliance.ReturnFormRevisionModel[] {\r\n return this._notAssociatedReturnFormRevisions;\r\n }\r\n\r\n notifyReportsUpdate(reports: Compliance.FilingBatchReportModel[]): void {\r\n this._sharedState.reports = reports;\r\n }\r\n\r\n notifyProcessStatusChange(processStatus: Compliance.FilingBatchProcessStatusEnum): void {\r\n this._filingBatchProcessStatusSubject.next(processStatus);\r\n }\r\n\r\n isReturnConsolidated(returnId: number): boolean {\r\n return this._consolidatedReturns.has(returnId);\r\n }\r\n\r\n /**\r\n * Associates new Return Form Revisions to a Return (ReturnFormRevisionId of zero).\r\n * Disassociated existing Return Form Revisions from a Return (ReturnFormRevisionId greater than zero).\r\n * @param models The Return Form Revision models.\r\n */\r\n async associateOrDisassociateReturnFormRevisions(models: Compliance.ReturnFormRevisionModel[]): Promise {\r\n await lastValueFrom(this._returnFormRevisionRepository.update(this.filingBatchId, models));\r\n await this.loadReturnFormRevisions();\r\n await lastValueFrom(this._returnRepository.updateWorkingSet(this._filingBatch.filingBatchId, []));\r\n }\r\n\r\n async startLocking(lockRequestModel: Compliance.ReturnLockRequestModel): Promise {\r\n this._filingBatch.longRunningProcessId = await lastValueFrom(this._returnRepository.lockReturn(lockRequestModel));\r\n this._longRunningProcessIdSubject.next(this.longRunningProcessId);\r\n }\r\n\r\n async startUnlocking(unlockRequestModel: Compliance.ReturnUnlockRequestModel): Promise {\r\n this._filingBatch.longRunningProcessId = await lastValueFrom(this._returnRepository.unlockReturn(unlockRequestModel));\r\n }\r\n\r\n async startSigning(signRequestModel: Compliance.ReturnSignRequestModel): Promise {\r\n this._filingBatch.longRunningProcessId = await lastValueFrom(this._returnRepository.signReturn(signRequestModel));\r\n }\r\n\r\n async startUnsigning(unsignRequestModel: Compliance.ReturnUnsignRequestModel): Promise {\r\n this._filingBatch.longRunningProcessId = await lastValueFrom(this._returnRepository.unsignReturn(unsignRequestModel));\r\n }\r\n\r\n async startFinalizing(finalizeRequestModel: Compliance.ReturnFinalizeRequestModel): Promise {\r\n this._filingBatch.longRunningProcessId = await lastValueFrom(this._returnRepository.finalizeReturn(finalizeRequestModel));\r\n }\r\n\r\n async viewTasks(): Promise {\r\n await this._filingBatchService.viewTasks(this._filingBatch);\r\n }\r\n\r\n async completeTask(taskUpdateModel: Compliance.ReturnTaskUpdateModel): Promise {\r\n await lastValueFrom(this._returnRepository.completeTask(this.filingBatchId, taskUpdateModel));\r\n await this._loadTasks();\r\n this._filingBatch = await lastValueFrom(this._filingBatchRepository.get(this.filingBatchId));\r\n }\r\n\r\n async rescindToTask(taskUpdateModel: Compliance.ReturnTaskUpdateModel): Promise {\r\n await lastValueFrom(this._returnRepository.rescindToTask(this.filingBatchId, taskUpdateModel));\r\n await this._loadTasks();\r\n this._filingBatch = await lastValueFrom(this._filingBatchRepository.get(this.filingBatchId));\r\n }\r\n\r\n async skipTask(taskUpdateModel: Compliance.ReturnTaskUpdateModel): Promise {\r\n await lastValueFrom(this._returnRepository.skipTask(this.filingBatchId, taskUpdateModel));\r\n await this._loadTasks();\r\n this._filingBatch = await lastValueFrom(this._filingBatchRepository.get(this.filingBatchId));\r\n }\r\n\r\n async reassignTask(taskUpdateModel: Compliance.ReturnTaskUpdateModel): Promise {\r\n await lastValueFrom(this._returnRepository.reassignTask(this.filingBatchId, taskUpdateModel));\r\n await this._loadTasks();\r\n this._filingBatch = await lastValueFrom(this._filingBatchRepository.get(this.filingBatchId));\r\n }\r\n\r\n async resetForms(filingBatchId: number): Promise {\r\n const startResult = await lastValueFrom(this._returnRepository.resetForms(filingBatchId));\r\n await this._start(startResult);\r\n }\r\n\r\n async validateForms(filingBatchId: number): Promise {\r\n const compareResult = await lastValueFrom(this._returnRepository.compareForms(filingBatchId));\r\n this._setCompareFormsResult(compareResult);\r\n }\r\n\r\n async nextYearInfo(filingBatchId: number): Promise {\r\n return await lastValueFrom(this._filingBatchRepository.getNextYearInfo(filingBatchId));\r\n }\r\n\r\n async getFinalizeSyncOptions(filingBatchId: number): Promise {\r\n return await lastValueFrom(this._returnRepository.getFinalizeSyncOptions(filingBatchId));\r\n }\r\n\r\n getFilenameFromResponseContentDisposition(response: HttpResponse): string {\r\n const contentDisposition = response.headers.get('content-disposition') || '';\r\n const matches = /filename=\"?([^;\"]+)\"?/ig.exec(contentDisposition);\r\n const filename = (matches[1] || 'untitled').trim();\r\n return filename;\r\n }\r\n\r\n saveFileAsPdf(data: Blob, filename: string): void {\r\n const blob = new Blob([data], { type: 'application/pdf' });\r\n const link = document.createElement('a');\r\n link.href = window.URL.createObjectURL(blob);\r\n link.download = filename;\r\n link.click();\r\n }\r\n\r\n getReturnFormRevisionDisplayName(returnFormRevision: Compliance.ReturnFormRevisionModel): string {\r\n return `${returnFormRevision.formRevisionName}${returnFormRevision.isInDevelopment ? ' (DEV)' : ''}`;\r\n }\r\n\r\n getProgressStatusDisplay(): string {\r\n return this._filingBatchService.getProgressStatusDisplay(this._filingBatch && this._filingBatch.processStatus);\r\n }\r\n\r\n getRepresentationType(representationType: Compliance.RepresentationTypeEnum): string {\r\n switch (representationType) {\r\n case Compliance.RepresentationTypeEnum.Agent: return 'Agent';\r\n case Compliance.RepresentationTypeEnum.Appraiser: return 'Appraiser';\r\n case Compliance.RepresentationTypeEnum.Attorney: return 'Attorney';\r\n case Compliance.RepresentationTypeEnum.Broker: return 'Broker';\r\n case Compliance.RepresentationTypeEnum.CPA: return 'CPA';\r\n case Compliance.RepresentationTypeEnum.Employee: return 'Employee';\r\n case Compliance.RepresentationTypeEnum.Fiduciary: return 'Fiduciary';\r\n case Compliance.RepresentationTypeEnum.Other: return 'Other';\r\n case Compliance.RepresentationTypeEnum.Owner: return 'Owner';\r\n case Compliance.RepresentationTypeEnum.SecuredParty: return 'Secured Party';\r\n default: return '';\r\n }\r\n }\r\n\r\n getReportType(filingBatchReport: Compliance.FilingBatchReportModel): string {\r\n if (!filingBatchReport) {\r\n return '';\r\n }\r\n\r\n return filingBatchReport.isSystem ? 'System' : 'Custom';\r\n }\r\n\r\n getReportName(filingBatchReport: Compliance.FilingBatchReportModel): string {\r\n if (!filingBatchReport) {\r\n return '';\r\n }\r\n\r\n return `${filingBatchReport.name}${(filingBatchReport.variantName ? ` - ${filingBatchReport.variantName}` : '')}`;\r\n }\r\n\r\n getSavedSearchReportType(savedSearch: Core.SavedSearchModel): string {\r\n if (!savedSearch) {\r\n return '';\r\n }\r\n\r\n return savedSearch.isSystemSearch ? 'System ' : 'Custom';\r\n }\r\n\r\n getSavedSearchReportName(savedSearch: Core.SavedSearchModel): string {\r\n if (!savedSearch) {\r\n return '';\r\n }\r\n\r\n return `${savedSearch.searchName}${(savedSearch.variantName ? ` - ${savedSearch.variantName}` : '')}`;\r\n }\r\n\r\n getReturnReportName(returnFormRevisionReport: Compliance.ReturnFormRevisionReportModel): string {\r\n if (!returnFormRevisionReport) {\r\n return '';\r\n }\r\n\r\n return `${returnFormRevisionReport.name}${(returnFormRevisionReport.variantName ? ` - ${returnFormRevisionReport.variantName}` : '')}`;\r\n }\r\n\r\n applyRemoteReturnBatchFilter(returnIds: number[]): void {\r\n this._returnBatchFilterSubject.next(returnIds);\r\n }\r\n\r\n exportReturnFilingControlSummary(searchParams: Core.SearchModel, columnsToReturn: Compliance.NameValuePair[]): Observable {\r\n const exportModel: Compliance.ReturnFilingControlSearchModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn,\r\n formRevisionId: this.sharedState.formRevisionId,\r\n parcelIds: this.sharedState.returns.map(x => x.parcelId)\r\n };\r\n\r\n return this._returnRepository.exportReturnFilingControlSummary(this.filingBatchId, exportModel);\r\n }\r\n\r\n getExportedReturnFilingControlSummary(longRunningProcessId: number): Observable> {\r\n return this._returnRepository.getExportedReturnFilingControlSummary(this.filingBatchId, longRunningProcessId);\r\n }\r\n\r\n getFilingBatchGeneralReturnSettings(): Observable {\r\n return this._returnRepository.getFilingBatchGeneralReturnSettings(this.filingBatchId);\r\n }\r\n\r\n updateFilingBatchGeneralReturnSettings(updateModel: Compliance.FilingBatchGeneralReturnSettings): Observable {\r\n return this._returnRepository.updateFilingBatchGeneralReturnSettings(this.filingBatchId, updateModel);\r\n }\r\n\r\n getCompanyAssetDescriptorMappingsAsColDefs(mappings: Compliance.CompanyAssetDescriptorMappingModel[]): ColDef[] {\r\n return mappings.map(mapping => {\r\n let typeSpecificAttributes;\r\n let cellStyle = '';\r\n switch (mapping.descriptor.fieldType) {\r\n case Core.DescriptorFieldTypes.Currency:\r\n typeSpecificAttributes = {\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n if (!x.value) {\r\n return null;\r\n }\r\n\r\n return this._decimalPipe.transform(x.value, '1.2-2')\r\n }\r\n };\r\n cellStyle = 'ag-numeric-cell';\r\n break;\r\n case Core.DescriptorFieldTypes.Date:\r\n typeSpecificAttributes = {\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => {\r\n if (!x.value) {\r\n return null;\r\n }\r\n\r\n const d = new Date(x.value);\r\n return this._datePipe.transform(d, true);\r\n }\r\n };\r\n break;\r\n case Core.DescriptorFieldTypes.YesNo:\r\n typeSpecificAttributes = {\r\n width: AgGridColumns.textColumnMedWidth,\r\n mindWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n isVisible: (params: ICellRendererParamsForAgGridCheckbox) => params.value !== null,\r\n canEdit: (params: ICellRendererParamsForAgGridCheckbox) => false,\r\n canEnterEditMode: () => false,\r\n onValueChanged: null,\r\n } as ICellRendererParamsForAgGridCheckbox,\r\n filter: false,\r\n };\r\n break;\r\n case Core.DescriptorFieldTypes.Number:\r\n typeSpecificAttributes = {\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => (x && x.value) ? `${this._decimalPipe.transform(x.value, '1.2-5')}` : ''\r\n };\r\n break;\r\n case Core.DescriptorFieldTypes.Text:\r\n typeSpecificAttributes = {\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n };\r\n break;\r\n }\r\n\r\n return {\r\n headerName: mapping.descriptor.name,\r\n field: _.camelCase(mapping.columnName),\r\n toolPanelClass: 'Asset',\r\n ...typeSpecificAttributes,\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n if (mapping.descriptor.fieldType === Core.DescriptorFieldTypes.Date) {\r\n return (rowData\r\n && rowData[_.camelCase(mapping.columnName)] != null\r\n && rowData[_.camelCase('source' + mapping.columnName)] != null\r\n && rowData[_.camelCase(mapping.columnName)].getTime() === rowData[_.camelCase('source' + mapping.columnName)].getTime()) ? cellStyle : cellStyle + ' overridden';\r\n } else {\r\n return (rowData && rowData[_.camelCase(mapping.columnName)] === rowData[_.camelCase('source' + mapping.columnName)]) ? cellStyle : cellStyle + ' overridden';\r\n }\r\n },\r\n hide: mapping.descriptor.assetUsage !== Core.DescriptorUsageEnum.Frequent\r\n }\r\n })\r\n }\r\n\r\n notifyParcelsChanged(): void {\r\n this._parcelsChangedSubject.next(new Date());\r\n }\r\n\r\n get cutOffDate(): Date {\r\n return this._cutOffDate;\r\n }\r\n\r\n get changeDetection(): string {\r\n return this._changeDetection;\r\n }\r\n\r\n get ages(): string[] {\r\n return this._ages;\r\n }\r\n\r\n async loadFilingBatchInfo(filingBatchId: number): Promise {\r\n this._filingBatch = await this._filingBatchService.getInfo(filingBatchId);\r\n }\r\n\r\n private _getLastSelectedFormRevisionId(filingBatchId: number): number {\r\n const lastSelectedFormRevisionId = this._lastSelectedFormRevisionIds.filingBatch[filingBatchId];\r\n\r\n const lastSelectedFormRevision = this._associatedReturnFormRevisions.find(x => x.formRevisionId === lastSelectedFormRevisionId);\r\n\r\n // if we have the last used form revision set it to that one\r\n // if last used form revision, set it to the first available one from the list\r\n // if cannot set the form revision, set it to NULL\r\n return lastSelectedFormRevision && lastSelectedFormRevision.formRevisionId;\r\n }\r\n\r\n /**\r\n * Sets the form revision ID without notifying via the Observable.\r\n * @param value The form revision ID.\r\n */\r\n private _setFormRevisionId(value: number): void {\r\n this._sharedState.formRevisionId = value;\r\n // store the selected form revision ID as the last selected one for that filing (or filing batch)\r\n this._lastSelectedFormRevisionIds.filingBatch[this._filingBatch.filingBatchId] = this._sharedState.formRevisionId;\r\n }\r\n\r\n private async _loadTasks(): Promise {\r\n const tasksByEntity = await lastValueFrom(this._filingBatchRepository.getTasks(this.filingBatch.filingBatchId));\r\n\r\n this._setTasks(tasksByEntity.tasks);\r\n }\r\n\r\n private _setCompareFormsResult(formResult: Compliance.ReturnCompareFormsResultModel): void {\r\n this._compareFormsResult = formResult;\r\n this._compareFormsSubject.next(formResult);\r\n }\r\n\r\n private _setTasks(tasks: Core.TaskModel[]): void {\r\n this._tasks = _.sortBy(tasks, x => x.sequence);\r\n\r\n // set the current task\r\n this._currentTask = _.find(this.tasks, x => x.isReady);\r\n\r\n // set the prior completed task\r\n this._priorCompletedTask = _.find(_.orderBy(this._tasks, x => x.sequence, 'desc'), x => x.completedDateTime && this._currentTask && x.sequence < this._currentTask.sequence);\r\n\r\n // set the next task\r\n this._nextTask = _.find(this.tasks, x => this._currentTask && x.sequence > this._currentTask.sequence);\r\n\r\n this._tasksSubject.next();\r\n }\r\n\r\n /**\r\n * Updates the the internal copy of return form revision that are associated or can be associated with a Return.\r\n */\r\n async loadReturnFormRevisions(): Promise {\r\n const returnIds = this._sharedState.returns.reduce((acc, x) => acc.includes(x.returnId) ? acc : [...acc, x.returnId], []);\r\n\r\n const response = await Promise.all([\r\n lastValueFrom(this._returnFormRevisionRepository.getByAssociatedWithReturns(this.filingBatchId, returnIds)),\r\n lastValueFrom(this._returnFormRevisionRepository.getByNotAssociatedWithReturns(this.filingBatchId, returnIds))\r\n ]);\r\n\r\n this._associatedReturnFormRevisions = response[0];\r\n this._notAssociatedReturnFormRevisions = response[1];\r\n\r\n this._sharedState.returnFormRevisionsUpdatedTimestamp = Date.now();\r\n }\r\n\r\n private _isReturnInReadOnlyMode(): boolean {\r\n return this._filingBatchService.isReadOnly(this._filingBatch && this._filingBatch.processStatus);\r\n }\r\n\r\n /**\r\n * Handles WebSocket message related to filing batch status changes.\r\n * Notifies with the updated status if the filing batch that was changed matches that of the return.\r\n * @param filingBatchId The ID of the filing batch that was changed.\r\n */\r\n private async _wsHandleFilingBatchStatusChange(statusChange: Compliance.LongRunningProcessStatusChangeModel): Promise {\r\n if (!(this._filingBatch && this._filingBatch.longRunningProcessId === statusChange.longRunningProcessId && statusChange.isCompleted)) {\r\n return;\r\n }\r\n\r\n // reload filing batch\r\n this._filingBatch = await lastValueFrom(this._filingBatchRepository.get(this._filingBatch.filingBatchId));\r\n\r\n if (this._filingBatch.processStatus === Compliance.FilingBatchProcessStatusEnum.Locked) {\r\n this._validateFormsResult = this._filingBatch.validateFormsResult;\r\n this._validateFormsSubject.next(this._validateFormsResult);\r\n }\r\n\r\n await this._loadTasks();\r\n\r\n // determine status\r\n this._filingBatchProcessStatusSubject.next(this._filingBatch.processStatus);\r\n\r\n this._isReturnInReadOnly = this._isReturnInReadOnlyMode();\r\n this._isReturnInReadOnlyModeSubject.next(this._isReturnInReadOnly);\r\n }\r\n\r\n /**\r\n * Handles WebSocket message related to filing batch status change progress changes.\r\n * Notifies with the updated progress if the filing batch that was changed matches that of the return.\r\n * @param data The websocket message payload.\r\n */\r\n private async _wsHandleFilingBatchProgressChange(progressChange: Compliance.LongRunningProcessProgressChangeModel): Promise {\r\n if (!(this._filingBatch && this._filingBatch.longRunningProcessId === progressChange.longRunningProcessId)) {\r\n return;\r\n }\r\n\r\n this._filingBatchProgressSubject.next(progressChange);\r\n }\r\n\r\n private _start(startResult: Compliance.ReturnPrepareDataResultModel): void {\r\n this._sharedState.returns = [];\r\n this._sharedState.reports = [];\r\n this._filingBatch = startResult.filingBatch;\r\n this._lienDate = startResult.lienDate;\r\n this._company = startResult.company;\r\n this._canEditCompany = startResult.canEditCompany;\r\n this._companyAssetDescriptorMappings = startResult.companyAssetDescriptors;\r\n this._associatedReturnFormRevisions = startResult.formsAssociatedWithReturns;\r\n this._notAssociatedReturnFormRevisions = startResult.formsNotAssociatedWithReturns;\r\n this._returnGroupDetails = startResult.returnTotalsDetails;\r\n this._sharedState.returnFormRevisionsUpdatedTimestamp = Date.now();\r\n this._validateFormsResult = startResult.validateFormsResult;\r\n this._validateFormsSubject.next(this._validateFormsResult);\r\n this._setCompareFormsResult(startResult.compareFormsResult);\r\n this._setTasks(startResult.tasks);\r\n this._isReturnInReadOnly = this._isReturnInReadOnlyMode();\r\n this._isReturnInReadOnlyModeSubject.next(this.isReturnInReadOnly);\r\n this._filingBatchStatusChangeSub && this._filingBatchStatusChangeSub.unsubscribe();\r\n this._filingBatchProgressChangeSub && this._filingBatchProgressChangeSub.unsubscribe();\r\n this._filingBatchStatusChangeSub = this._websocketListenerService.longRunningProcessStatusChange$.subscribe(x => this._wsHandleFilingBatchStatusChange(x));\r\n this._filingBatchProgressChangeSub = this._websocketListenerService.longRunningProcessProgressChange$.subscribe(x => this._wsHandleFilingBatchProgressChange(x));\r\n this._startSubject.next();\r\n }\r\n\r\n private _setData(result: Compliance.ReturnPrepareDataResultModel, onlyReloadFilingBatchDetails: boolean) {\r\n this._filingBatch = result.filingBatch;\r\n this._lienDate = result.lienDate;\r\n this._company = result.company;\r\n this._canEditCompany = result.canEditCompany;\r\n this._canViewRyanPrivateItems = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n this._companyAssetDescriptorMappings = result.companyAssetDescriptors;\r\n this._validateFormsResult = result.validateFormsResult;\r\n this._validateFormsSubject.next(this._validateFormsResult);\r\n this._associatedReturnFormRevisions = result.formsAssociatedWithReturns;\r\n this._notAssociatedReturnFormRevisions = result.formsNotAssociatedWithReturns;\r\n this._sharedState.returnFormRevisionsUpdatedTimestamp = Date.now();\r\n this._returnGroupDetails = result.returnTotalsDetails;\r\n this._returnSummary = result.returnSummary;\r\n this._cutOffDate = result.cutOffDate;\r\n this._changeDetection = result.changeDetection;\r\n this._ages = result.ages;\r\n\r\n if (!onlyReloadFilingBatchDetails) {\r\n this._setCompareFormsResult(result.compareFormsResult);\r\n this._setTasks(result.tasks);\r\n\r\n this._isReturnInReadOnly = this._isReturnInReadOnlyMode();\r\n this._isReturnInReadOnlyModeSubject.next(this.isReturnInReadOnly);\r\n\r\n this._filingBatchStatusChangeSub = this._websocketListenerService.longRunningProcessStatusChange$.subscribe(x => this._wsHandleFilingBatchStatusChange(x));\r\n this._filingBatchProgressChangeSub = this._websocketListenerService.longRunningProcessProgressChange$.subscribe(x => this._wsHandleFilingBatchProgressChange(x));\r\n\r\n this.setFirstFormRevisionId();\r\n this._startSubject.next();\r\n }\r\n }\r\n}\r\n","export class ScheduleAdditionsDisposalReconciliationReportRow {\r\n constructor(formRevisionScheduleId: number, scheduleName: string) {\r\n this.formRevisionScheduleId = formRevisionScheduleId;\r\n this.scheduleName = scheduleName;\r\n }\r\n\r\n formRevisionScheduleId: number = null;\r\n scheduleName: string = null;\r\n\r\n assetsCount: number = 0;\r\n\r\n cost: number = 0;\r\n priorCost: number = 0;\r\n additions: number = 0;\r\n disposals: number = 0;\r\n\r\n disposalsCost: number = 0;\r\n disposedAssetCount: number = 0;\r\n\r\n get netChange(): number {\r\n return (this.cost - this.priorCost) || 0;\r\n }\r\n\r\n get percentChange(): number {\r\n return this.priorCost === 0 ? null : (this.cost - this.priorCost) / this.priorCost;\r\n };\r\n}\r\n\r\nexport class ScheduleAdditionsDisposalsReconciliationReport {\r\n constructor(\r\n private _assignedScheduleDetails: Compliance.ReturnAssetScheduleDetailsAssignedItemModel[],\r\n private _unassignedScheduleDetails: Compliance.ReturnAssetScheduleDetailsUnassignedItemModel[]\r\n ) {\r\n this._initialize();\r\n }\r\n\r\n reportableSchedules: ScheduleAdditionsDisposalReconciliationReportRow[] = [];\r\n totalReportable: ScheduleAdditionsDisposalReconciliationReportRow;\r\n totalNonReportable: ScheduleAdditionsDisposalReconciliationReportRow;\r\n total: ScheduleAdditionsDisposalReconciliationReportRow;\r\n notAssignedToASchedule: ScheduleAdditionsDisposalReconciliationReportRow;\r\n\r\n private _initialize(): void {\r\n this.notAssignedToASchedule = new ScheduleAdditionsDisposalReconciliationReportRow(null, null);\r\n\r\n this._unassignedScheduleDetails.forEach(scheduleDetail => {\r\n this.notAssignedToASchedule.cost += scheduleDetail.cost;\r\n this.notAssignedToASchedule.assetsCount += scheduleDetail.assetCount;\r\n this.notAssignedToASchedule.disposalsCost += scheduleDetail.disposalsCost;\r\n this.notAssignedToASchedule.disposedAssetCount += scheduleDetail.disposedAssetCount;\r\n });\r\n\r\n // for each schedule detail update the report model\r\n this._assignedScheduleDetails.forEach(scheduleDetail => {\r\n const scheduleData = new ScheduleAdditionsDisposalReconciliationReportRow(scheduleDetail.formRevisionScheduleId, scheduleDetail.name);\r\n scheduleData.assetsCount = scheduleDetail.assetCount;\r\n scheduleData.cost = scheduleDetail.cost;\r\n scheduleData.priorCost = scheduleDetail.priorCost;\r\n scheduleData.additions = scheduleDetail.additions;\r\n scheduleData.disposals = scheduleDetail.disposals;\r\n\r\n // differentiate between the reportable and non-reportable schedules (tracked separately in the model)\r\n scheduleDetail.isReportable ? this.reportableSchedules.push(scheduleData) : this.totalNonReportable = scheduleData;\r\n });\r\n\r\n // populate totals for the reported schedules\r\n this.totalReportable = new ScheduleAdditionsDisposalReconciliationReportRow(null, null);\r\n this.reportableSchedules.forEach(x => {\r\n this.totalReportable.assetsCount += x.assetsCount;\r\n this.totalReportable.cost += x.cost;\r\n this.totalReportable.priorCost += x.priorCost;\r\n this.totalReportable.additions += x.additions;\r\n this.totalReportable.disposals += x.disposals;\r\n });\r\n\r\n // populate totals for all schedules\r\n this.total = new ScheduleAdditionsDisposalReconciliationReportRow(null, null);\r\n this.total.assetsCount = this.totalReportable.assetsCount + this.totalNonReportable.assetsCount;\r\n this.total.priorCost = this.totalReportable.priorCost + this.totalNonReportable.priorCost,\r\n this.total.additions = this.totalReportable.additions + this.totalNonReportable.additions,\r\n this.total.disposals = this.totalReportable.disposals + this.totalNonReportable.disposals,\r\n this.total.cost = this.totalReportable.cost + this.totalNonReportable.cost;\r\n }\r\n}\r\n","export class ReturnSummaryReconciliationReportRow {\r\n reportableCost: number = 0;\r\n nonReportableCost: number = 0;\r\n unassignedCost: number = 0;\r\n\r\n get cost(): number {\r\n return this.reportableCost + this.nonReportableCost + this.unassignedCost;\r\n }\r\n}\r\n\r\nexport class ReturnSummaryReconciliationReportAdditions {\r\n acquisitions: ReturnSummaryReconciliationReportRow = new ReturnSummaryReconciliationReportRow();\r\n transferIns: ReturnSummaryReconciliationReportRow = new ReturnSummaryReconciliationReportRow();\r\n costChanges: ReturnSummaryReconciliationReportRow = new ReturnSummaryReconciliationReportRow();\r\n reportabilityChanges: ReturnSummaryReconciliationReportRow = new ReturnSummaryReconciliationReportRow();\r\n reportableCost: number;\r\n nonReportableCost: number;\r\n unassignedCost: number;\r\n\r\n get cost(): number {\r\n return this.reportableCost + this.nonReportableCost + this.unassignedCost;\r\n }\r\n}\r\n\r\nexport class ReturnSummaryReconciliationReportDeductions {\r\n disposals: ReturnSummaryReconciliationReportRow = new ReturnSummaryReconciliationReportRow();\r\n transferOuts: ReturnSummaryReconciliationReportRow = new ReturnSummaryReconciliationReportRow();\r\n costChanges: ReturnSummaryReconciliationReportRow = new ReturnSummaryReconciliationReportRow();\r\n reportabilityChanges: ReturnSummaryReconciliationReportRow = new ReturnSummaryReconciliationReportRow();\r\n suppressedAssets: ReturnSummaryReconciliationReportRow = new ReturnSummaryReconciliationReportRow();\r\n reportableCost: number;\r\n nonReportableCost: number;\r\n unassignedCost: number;\r\n estimatedFMV: number;\r\n\r\n get cost(): number {\r\n return this.reportableCost + this.nonReportableCost + this.unassignedCost;\r\n }\r\n}\r\n\r\nexport class ReturnSummaryReconciliationReport {\r\n constructor(private _returnSummaryResult: Compliance.ReturnSummaryModel) {\r\n this._initialize();\r\n }\r\n\r\n priorReturnCostForward: ReturnSummaryReconciliationReportRow;\r\n existingOverridesTrueUp: ReturnSummaryReconciliationReportRow;\r\n existingDeductionsTrueUp: ReturnSummaryReconciliationReportRow;\r\n priorReturn: ReturnSummaryReconciliationReportRow;\r\n currentReturn: ReturnSummaryReconciliationReportRow;\r\n additions: ReturnSummaryReconciliationReportAdditions;\r\n deductions: ReturnSummaryReconciliationReportDeductions;\r\n notAssignedToAScheduleCost: number = 0;\r\n priorReportedValue: number = 0;\r\n currentReportedValue: number = 0;\r\n currentEstimatedFMV: number = 0;\r\n priorEstimatedFMV: number = 0;\r\n showEstimatedFMV: boolean = false;\r\n\r\n private _initialize(): void {\r\n // get reportable vs non-reportable data from the return summary\r\n const reportableSummary = this._returnSummaryResult.addsAndDeletes.find(x => x.scheduleType === 'Reported');\r\n const nonReportableSummary = this._returnSummaryResult.addsAndDeletes.find(x => x.scheduleType === 'Unreported');\r\n const unassignedSummary = this._returnSummaryResult.addsAndDeletes.find(x => x.scheduleType === 'Unassigned');\r\n\r\n // additions\r\n this.additions = new ReturnSummaryReconciliationReportAdditions();\r\n\r\n this.additions.acquisitions.reportableCost = reportableSummary.addAcquisitionsCost || 0;\r\n this.additions.acquisitions.nonReportableCost = nonReportableSummary.addAcquisitionsCost || 0;\r\n this.additions.acquisitions.unassignedCost = unassignedSummary.addAcquisitionsCost || 0;\r\n\r\n this.additions.transferIns.reportableCost = reportableSummary.addTransfersInCost || 0;\r\n this.additions.transferIns.nonReportableCost = nonReportableSummary.addTransfersInCost || 0;\r\n this.additions.transferIns.unassignedCost = unassignedSummary.addTransfersInCost || 0;\r\n\r\n this.additions.costChanges.reportableCost = reportableSummary.addCostChangesCost || 0;\r\n this.additions.costChanges.nonReportableCost = nonReportableSummary.addCostChangesCost || 0;\r\n this.additions.costChanges.unassignedCost = unassignedSummary.addCostChangesCost || 0;\r\n\r\n this.additions.reportabilityChanges.reportableCost = reportableSummary.addReportabilityChangesCost || 0;\r\n this.additions.reportabilityChanges.nonReportableCost = nonReportableSummary.addReportabilityChangesCost || 0;\r\n this.additions.reportabilityChanges.unassignedCost = unassignedSummary.addReportabilityChangesCost || 0;\r\n\r\n this.additions.reportableCost = reportableSummary.addCost || 0;\r\n this.additions.nonReportableCost = nonReportableSummary.addCost || 0;\r\n this.additions.unassignedCost = unassignedSummary.addCost || 0;\r\n\r\n // deductions\r\n this.deductions = new ReturnSummaryReconciliationReportDeductions();\r\n\r\n this.deductions.disposals.reportableCost = reportableSummary.deductionDisposalCost || 0;\r\n this.deductions.disposals.nonReportableCost = nonReportableSummary.deductionDisposalCost || 0;\r\n this.deductions.disposals.unassignedCost = unassignedSummary.deductionDisposalCost || 0;\r\n\r\n this.deductions.transferOuts.reportableCost = reportableSummary.deductionTransferOutCost || 0;\r\n this.deductions.transferOuts.nonReportableCost = nonReportableSummary.deductionTransferOutCost || 0;\r\n this.deductions.transferOuts.unassignedCost = unassignedSummary.deductionTransferOutCost || 0;\r\n\r\n this.deductions.costChanges.reportableCost = reportableSummary.deductionCostChangesCost || 0;\r\n this.deductions.costChanges.nonReportableCost = nonReportableSummary.deductionCostChangesCost || 0;\r\n this.deductions.costChanges.unassignedCost = unassignedSummary.deductionCostChangesCost || 0;\r\n\r\n this.deductions.reportabilityChanges.reportableCost = reportableSummary.deductionReportabilityChangesCost || 0;\r\n this.deductions.reportabilityChanges.nonReportableCost = nonReportableSummary.deductionReportabilityChangesCost || 0;\r\n this.deductions.reportabilityChanges.unassignedCost = unassignedSummary.deductionReportabilityChangesCost || 0;\r\n\r\n this.deductions.suppressedAssets.reportableCost = reportableSummary.suppressedAssetsCost || 0;\r\n this.deductions.suppressedAssets.nonReportableCost = nonReportableSummary.suppressedAssetsCost || 0;\r\n this.deductions.suppressedAssets.unassignedCost = unassignedSummary.suppressedAssetsCost || 0;\r\n\r\n this.deductions.reportableCost = reportableSummary.deductionCost || 0;\r\n this.deductions.nonReportableCost = nonReportableSummary.deductionCost || 0;\r\n this.deductions.unassignedCost = unassignedSummary.deductionCost || 0;\r\n\r\n // current return\r\n this.currentReturn = new ReturnSummaryReconciliationReportRow();\r\n this.currentReturn.reportableCost = reportableSummary.currentCost;\r\n this.currentReturn.nonReportableCost = nonReportableSummary.currentCost;\r\n this.currentReturn.unassignedCost = unassignedSummary.currentCost;\r\n\r\n // prior return cost forward\r\n this.priorReturnCostForward = new ReturnSummaryReconciliationReportRow();\r\n this.priorReturnCostForward.reportableCost = reportableSummary.priorCost;\r\n this.priorReturnCostForward.nonReportableCost = nonReportableSummary.priorCost;\r\n this.priorReturnCostForward.unassignedCost = unassignedSummary.priorCost;\r\n\r\n // existing overrides true up\r\n this.existingOverridesTrueUp = new ReturnSummaryReconciliationReportRow();\r\n this.existingOverridesTrueUp.reportableCost = reportableSummary.existingOverridesTrueUpCost;\r\n this.existingOverridesTrueUp.nonReportableCost = nonReportableSummary.existingOverridesTrueUpCost;\r\n this.existingOverridesTrueUp.unassignedCost = unassignedSummary.existingOverridesTrueUpCost;\r\n\r\n // existing disposals true up\r\n this.existingDeductionsTrueUp = new ReturnSummaryReconciliationReportRow();\r\n this.existingDeductionsTrueUp.reportableCost = reportableSummary.existingDeductionsTrueUpCost;\r\n this.existingDeductionsTrueUp.nonReportableCost = nonReportableSummary.existingDeductionsTrueUpCost;\r\n this.existingDeductionsTrueUp.unassignedCost = unassignedSummary.existingDeductionsTrueUpCost;\r\n\r\n // prior return\r\n this.priorReturn = new ReturnSummaryReconciliationReportRow();\r\n this.priorReturn.reportableCost = reportableSummary.priorCost + reportableSummary.existingOverridesTrueUpCost + reportableSummary.existingDeductionsTrueUpCost;\r\n this.priorReturn.nonReportableCost = nonReportableSummary.priorCost + nonReportableSummary.existingOverridesTrueUpCost + nonReportableSummary.existingDeductionsTrueUpCost;\r\n this.priorReturn.unassignedCost = unassignedSummary.priorCost + unassignedSummary.existingOverridesTrueUpCost + unassignedSummary.existingDeductionsTrueUpCost;\r\n\r\n // remaining values\r\n this.priorReportedValue = this._returnSummaryResult.priorRenderedValue;\r\n this.currentEstimatedFMV = this._returnSummaryResult.currentEstimatedFMV;\r\n this.priorEstimatedFMV = this._returnSummaryResult.priorEstimatedFMV;\r\n this.currentReportedValue = this._returnSummaryResult.currentRenderedValue;\r\n this.notAssignedToAScheduleCost = this._returnSummaryResult.unAssignedCost;\r\n this.showEstimatedFMV = this._returnSummaryResult.showEstimatedFMV;\r\n }\r\n}\r\n","import * as _ from 'lodash';\r\n\r\nexport interface ReturnFormRevisionInfo {\r\n returnFormRevisionId: number;\r\n formRevisionId: number;\r\n}\r\n\r\nexport interface ReturnFilingControlRow extends Partial {\r\n isGroupRow: boolean;\r\n isTotalRow: boolean;\r\n isSubTotalRow: boolean;\r\n isMerged?: boolean;\r\n returnCount: number;\r\n isExpanded: boolean;\r\n returnFormRevisions?: ReturnFormRevisionInfo[];\r\n reportableCost: number;\r\n cost: number;\r\n depreciatedCost: number;\r\n taxLiability: number;\r\n reportedAssetCount?: number;\r\n notReportedAssetCount?: number;\r\n priorYearReportedCost: number;\r\n priorYearDepreciatedValue: number;\r\n isSelectedTotalsRow: boolean;\r\n}\r\n\r\nexport interface ReturnFilingControlAssetFilter {\r\n primaryFormRevisionId: number;\r\n showOnlyAssignedToReportableSchedule: boolean;\r\n returnIds: number[];\r\n}\r\n\r\nexport class FilingControlReconciliationReport {\r\n constructor(\r\n private readonly _returnFilingControlSummary: Compliance.ReturnFilingControlSummaryModel,\r\n private readonly _returnFormRevisions: Compliance.ReturnFormRevisionModel[],\r\n private readonly _returnTotals: Compliance.ReturnTotalsModel[]) {\r\n this._initialize();\r\n }\r\n\r\n returns: ReturnFilingControlRow[];\r\n groupedReturns: ReturnFilingControlRow[];\r\n consolidatedReturnGroups: ReturnFilingControlRow[];\r\n\r\n private _initialize(): void {\r\n // Group revisions by return ID\r\n const revisionsByReturn: { [returnId: string]: ReturnFormRevisionInfo[] } = this._returnFormRevisions.reduce((acc, x) => {\r\n if (!acc[x.returnId]) {\r\n acc[x.returnId] = [];\r\n }\r\n acc[x.returnId].push({\r\n formRevisionId: x.formRevisionId,\r\n returnFormRevisionId: x.returnFormRevisionId\r\n } as ReturnFormRevisionInfo);\r\n return acc;\r\n }, {});\r\n\r\n // Group filings by parcelId\r\n const filingControlMap: { [parcelId: string]: Compliance.ReturnFilingControlModel } = this._returnFilingControlSummary.returns.reduce((acc, x) => {\r\n acc[x.parcelId] = x;\r\n return acc;\r\n }, {});\r\n\r\n const returns: ReturnFilingControlRow[] = _.orderBy(this._returnFilingControlSummary.returns, x => x.parcelAcctNumber)\r\n .map(x => ({\r\n isGroupRow: false,\r\n isSubTotalRow: false,\r\n isTotalRow: false,\r\n isExpanded: false,\r\n returnCount: 1,\r\n returnFormRevisions: revisionsByReturn[x.returnId],\r\n ...x\r\n } as ReturnFilingControlRow));\r\n\r\n returns.push(this._getTotalRow(returns));\r\n this.returns = returns;\r\n\r\n this.consolidatedReturnGroups = this._returnTotals\r\n .map(x => ({\r\n ...x,\r\n isGroupRow: !x.isMergedParcel,\r\n isSubTotalRow: false,\r\n isTotalRow: false,\r\n isExpanded: false,\r\n isMerged: x.isMergedParcel,\r\n returnCount: 1,\r\n returnFormRevisions: revisionsByReturn[x.returnId],\r\n ...filingControlMap[x.parcelId]\r\n } as ReturnFilingControlRow))\r\n .sort((x, y) => y.returnId - x.returnId ||\r\n (y.isMerged === x.isMerged ? 0 : x.isMerged ? 1 : -1) ||\r\n y.parcelAcctNumberDisplay.localeCompare(x.parcelAcctNumberDisplay, undefined, { numeric: true }))\r\n .reduce((acc, x, i, ar) => {\r\n // Create subtotal rows\r\n if (!x.isMerged) {\r\n if (i !== 0) {\r\n acc.list.push(acc.subtotal);\r\n }\r\n acc.subtotal = this._getBlankSubtotalRow();\r\n }\r\n this._addToSubtotalRow(acc.subtotal, x);\r\n acc.list.push(x);\r\n if (i === ar.length - 1) {\r\n acc.list.push(acc.subtotal);\r\n acc.list.push(this._getTotalRow(acc.list));\r\n }\r\n return acc;\r\n }, { subtotal: this._getBlankSubtotalRow(), list: [] as ReturnFilingControlRow[] }).list;\r\n\r\n const groups = _.chain(this._returnFilingControlSummary.returns)\r\n .map(x => ({\r\n isGroupRow: false,\r\n isSubTotalRow: false,\r\n isTotalRow: false,\r\n isExpanded: false,\r\n returnCount: 1,\r\n returnFormRevisions: revisionsByReturn[x.returnId],\r\n ...x\r\n } as ReturnFilingControlRow))\r\n .groupBy(x => x.assessorId)\r\n .orderBy((values: ReturnFilingControlRow[]) => values[0].assessorName)\r\n .map((values: ReturnFilingControlRow[], key: number) => ({ assessorId: key, rows: _.orderBy(values, x => x.parcelAcctNumber) }))\r\n .value();\r\n\r\n const groupedRows: ReturnFilingControlRow[] = [];\r\n\r\n // create a flat list of rows with an assessor group row at the start of each assessor\r\n groups.forEach(x => {\r\n groupedRows.push(_.extend({} as ReturnFilingControlRow, x.rows[0],\r\n {\r\n isGroupRow: true,\r\n returnCount: x.rows.length\r\n }));\r\n groupedRows.push.apply(groupedRows, x.rows);\r\n\r\n groupedRows.push(\r\n {\r\n isGroupRow: false,\r\n isSubTotalRow: true,\r\n isTotalRow: false,\r\n isExpanded: false,\r\n returnCount: x.rows.length,\r\n reportableCost: x.rows.reduce((acc, y) => (acc += y.reportableCost || 0), 0),\r\n cost: x.rows.reduce((acc, y) => (acc += y.cost || 0), 0),\r\n depreciatedCost: x.rows.reduce((acc, y) => (acc += y.depreciatedCost || 0), 0),\r\n taxLiability: x.rows.reduce((acc, y) => (acc += y.taxLiability || 0), 0),\r\n estimatedFMV: x.rows.reduce((acc, y) => (acc += y.estimatedFMV || 0), 0),\r\n priorYearReportedCost: x.rows.reduce((acc, y) => (acc += y.priorYearReportedCost || 0), 0),\r\n priorYearDepreciatedValue: x.rows.reduce((acc, y) => (acc += y.priorYearDepreciatedValue || 0), 0)\r\n } as ReturnFilingControlRow\r\n );\r\n });\r\n\r\n groupedRows.push(\r\n {\r\n isGroupRow: false,\r\n isSubTotalRow: false,\r\n isTotalRow: true,\r\n isExpanded: false,\r\n returnCount: groupedRows.length,\r\n reportableCost: groupedRows.filter(x => !(x.isSubTotalRow || x.isTotalRow || x.isGroupRow)).reduce((acc, x) => (acc += x.reportableCost || 0), 0),\r\n cost: groupedRows.filter(x => !(x.isSubTotalRow || x.isTotalRow || x.isGroupRow)).reduce((acc, x) => (acc += x.cost || 0), 0),\r\n depreciatedCost: groupedRows.filter(x => !(x.isSubTotalRow || x.isTotalRow || x.isGroupRow)).reduce((acc, x) => (acc += x.depreciatedCost || 0), 0),\r\n taxLiability: groupedRows.filter(x => !(x.isSubTotalRow || x.isTotalRow || x.isGroupRow)).reduce((acc, x) => (acc += x.taxLiability || 0), 0),\r\n estimatedFMV: groupedRows.filter(x => !(x.isSubTotalRow || x.isTotalRow || x.isGroupRow)).reduce((acc, x) => (acc += x.estimatedFMV || 0), 0),\r\n priorYearReportedCost: groupedRows.filter(x => !(x.isSubTotalRow || x.isTotalRow || x.isGroupRow)).reduce((acc, x) => (acc += x.priorYearReportedCost || 0), 0),\r\n priorYearDepreciatedValue: groupedRows.filter(x => !(x.isSubTotalRow || x.isTotalRow || x.isGroupRow)).reduce((acc, x) => (acc += x.priorYearDepreciatedValue || 0), 0)\r\n } as ReturnFilingControlRow\r\n );\r\n\r\n this.groupedReturns = groupedRows;\r\n }\r\n\r\n private _getTotalRow(data: ReturnFilingControlRow[]): ReturnFilingControlRow {\r\n return {\r\n isGroupRow: false,\r\n isSubTotalRow: false,\r\n isTotalRow: true,\r\n isExpanded: false,\r\n returnCount: data.length,\r\n reportableCost: data.reduce((acc, x) => (acc += (!x.isSubTotalRow) ? x.reportableCost || 0 : 0), 0),\r\n cost: data.reduce((acc, x) => (acc += (!x.isSubTotalRow) ? x.cost || 0 : 0), 0),\r\n depreciatedCost: data.reduce((acc, x) => (acc += (!x.isSubTotalRow) ? x.depreciatedCost || 0 : 0), 0),\r\n taxLiability: data.reduce((acc, x) => (acc += (!x.isSubTotalRow) ? x.taxLiability || 0 : 0), 0),\r\n estimatedFMV: data.reduce((acc, x) => (acc += (!x.isSubTotalRow) ? x.estimatedFMV || 0 : 0), 0),\r\n reportedAssetCount: data.reduce((acc, x) => (acc += (!x.isSubTotalRow) ? x.reportedAssetCount || 0 : 0), 0),\r\n notReportedAssetCount: data.reduce((acc, x) => (acc += (!x.isSubTotalRow) ? x.notReportedAssetCount || 0 : 0), 0),\r\n priorYearReportedCost: data.reduce((acc, x) => (acc += (!x.isSubTotalRow) ? x.priorYearReportedCost || 0 : 0), 0),\r\n priorYearDepreciatedValue: data.reduce((acc, x) => (acc += (!x.isSubTotalRow) ? x.priorYearDepreciatedValue || 0 : 0), 0),\r\n isSelectedTotalsRow: false\r\n };\r\n }\r\n\r\n private _getBlankSubtotalRow(): ReturnFilingControlRow {\r\n return {\r\n isGroupRow: false,\r\n isSubTotalRow: true,\r\n isTotalRow: false,\r\n isExpanded: false,\r\n isMerged: false,\r\n returnCount: 0,\r\n reportableCost: 0,\r\n cost: 0,\r\n depreciatedCost: 0,\r\n taxLiability: 0,\r\n estimatedFMV: 0,\r\n priorYearReportedCost: 0,\r\n priorYearDepreciatedValue: 0,\r\n isSelectedTotalsRow: false\r\n }\r\n }\r\n\r\n private _addToSubtotalRow(subtotal: ReturnFilingControlRow, row: ReturnFilingControlRow): void {\r\n subtotal.returnCount += row.returnCount;\r\n subtotal.reportableCost += row.reportableCost;\r\n subtotal.cost += row.cost;\r\n subtotal.depreciatedCost += row.depreciatedCost;\r\n subtotal.taxLiability += row.taxLiability;\r\n subtotal.estimatedFMV += row.estimatedFMV;\r\n subtotal.priorYearReportedCost += row.priorYearReportedCost;\r\n subtotal.priorYearDepreciatedValue += row.priorYearDepreciatedValue;\r\n }\r\n}\r\n","import { Injectable} from '@angular/core';\r\nimport { ReturnPartServiceBase } from '../../Models/returnPartServiceBase';\r\nimport { UserSettingsService } from '../../../../Account/userSettings.service';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface ReturnOutputServiceSharedState {\r\n returnOutputModel: Compliance.ReturnOutputModel;\r\n }\r\n\r\n@Injectable()\r\nexport class ReturnOutputService extends ReturnPartServiceBase {\r\n constructor(\r\n private readonly _userSettingsService: UserSettingsService) {\r\n super();\r\n }\r\n\r\n private readonly _outputSettingName: string = 'Compliance-Return-Output-Settings';\r\n\r\n private _sharedState: ReturnOutputServiceSharedState = {\r\n returnOutputModel: null\r\n } as ReturnOutputServiceSharedState;\r\n\r\n get sharedState(): ReturnOutputServiceSharedState { return this._sharedState; }\r\n\r\n initialize(): void {\r\n this._sharedState = {\r\n returnOutputModel: null\r\n } as ReturnOutputServiceSharedState;\r\n }\r\n\r\n async loadSharedState(filingBatchId: number): Promise {\r\n let returnOutputModel = {\r\n filingBatchId: filingBatchId,\r\n packageIds: [],\r\n includeFilingControlReport: false,\r\n includeUSPSCertificateOfMailingLog: true,\r\n includeUSPSCertificateOfMailingIndividual: true,\r\n includeEnvelopeInserts: true,\r\n includePackageCoverSheets: false,\r\n includeReturns: true,\r\n organizeForMailing: true,\r\n embedExcelReportsInPdf: false\r\n } as Compliance.ReturnOutputModel;\r\n\r\n const settings = this._userSettingsService.getSettingsByGroup(Core.UserSettingGroup.ReturnPackageDownloadSettings);\r\n const setting = _.find(settings, (x: any) => x.name === this._outputSettingName);\r\n\r\n if (setting) {\r\n returnOutputModel = _.extend(returnOutputModel, setting.value, { filingBatchId });\r\n }\r\n\r\n if (this._sharedState && this._sharedState.returnOutputModel && this._sharedState.returnOutputModel.filingBatchId === filingBatchId) {\r\n returnOutputModel.packageIds = this._sharedState.returnOutputModel.packageIds;\r\n }\r\n\r\n this._sharedState.returnOutputModel = returnOutputModel;\r\n }\r\n\r\n async saveSharedState(): Promise {\r\n const settings = this._userSettingsService.getSettingsByGroup(Core.UserSettingGroup.ReturnPackageDownloadSettings);\r\n let setting = _.find(settings, (x: any) => x.name === this._outputSettingName);\r\n\r\n if (!setting) {\r\n setting = {\r\n id: 0,\r\n name: this._outputSettingName,\r\n value: null,\r\n groupId: Core.UserSettingGroup.ReturnPackageDownloadSettings,\r\n folderId: Core.UserSettingFolder.Default\r\n };\r\n }\r\n\r\n setting.value = _.extend(\r\n {},\r\n this._sharedState.returnOutputModel,\r\n { packageIds: [], filingBatchId: null });\r\n\r\n await this._userSettingsService.save(setting);\r\n }\r\n}\r\n","import { Injectable} from '@angular/core';\r\nimport { ReturnPartServiceBase } from '../../Models/returnPartServiceBase';\r\n\r\nexport interface ReturnSettingsServiceSharedState { }\r\n\r\n@Injectable()\r\nexport class ReturnSettingsService extends ReturnPartServiceBase {\r\n constructor () { super(); }\r\n\r\n private _sharedState: ReturnSettingsServiceSharedState = { };\r\n\r\n get sharedState(): ReturnSettingsServiceSharedState { return this._sharedState; }\r\n}\r\n","import { debounceTime } from 'rxjs/operators';\r\nimport { Injectable } from '@angular/core';\r\nimport { Observable, BehaviorSubject } from 'rxjs';\r\n\r\n/**\r\n * An interface for all handlers acquiring the lock for a resource group.\r\n */\r\nexport interface IMutexServiceHandler {\r\n /**\r\n * A method that each handler must implement in order to support releasing the lock for a resource group when requested.\r\n */\r\n wsMutexRelease: (groupId: string) => Promise;\r\n}\r\n\r\nexport interface IWeissmanMutexService {\r\n lockChanged$: Observable<{ [groupId: string]: boolean }>;\r\n acquire: (handler: IMutexServiceHandler, groupId: string) => Promise;\r\n canAcquire: (groupId: string) => boolean;\r\n release: (handler: IMutexServiceHandler, groupId: string) => void;\r\n}\r\n\r\n/**\r\n * A services used as a mutex to ensure access to a resource group one handler at a time.\r\n */\r\n@Injectable()\r\nexport class WeissmanMutexService implements IWeissmanMutexService {\r\n constructor() {\r\n }\r\n\r\n private _registrations: { [groupId: string]: IMutexServiceHandler } = {};\r\n\r\n private _lockChangedSubject = new BehaviorSubject<{ [groupId: string]: boolean }>({});\r\n\r\n /**\r\n * An observable notifying the state of the locks.\r\n * It publishes an object containing the group names as the keys and a boolean value for each key indicating if a lock for that group is acquired or not.\r\n */\r\n get lockChanged$(): Observable<{ [groupId: string]: boolean }> {\r\n return this._lockChangedSubject.pipe(debounceTime(250));\r\n }\r\n\r\n /**\r\n * Tries to acquire a resource group under for the specified handler.\r\n * If the resource group is locked under another handler, the handler currently holding the lock will have to decide whether to unlock the resource or not.\r\n * @param handler The handler that is trying to acquire the lock.\r\n * @param groupId The name of the resource group that the handler is trying to lock.\r\n */\r\n async acquire(handler: IMutexServiceHandler, groupId: string): Promise {\r\n const existingHandler = this._registrations[groupId];\r\n if (existingHandler) {\r\n try {\r\n await existingHandler.wsMutexRelease(groupId);\r\n } catch (e) {\r\n return false;\r\n }\r\n }\r\n this._registrations[groupId] = handler;\r\n this._publishLockState();\r\n return true;\r\n }\r\n\r\n /**\r\n * Checks to see if a resource group is unlocked and a lock can be acquired for it.\r\n * @param groupId The name of the resource group to check.\r\n */\r\n canAcquire(groupId: string): boolean {\r\n const existingHandler = this._registrations[groupId];\r\n return existingHandler === undefined || existingHandler === null;\r\n }\r\n\r\n /**\r\n * Releases a resource group.\r\n * @param handler The handler of the resource group.\r\n * @param groupId The name of the resource group to release.\r\n */\r\n release(handler: IMutexServiceHandler, groupId: string): void {\r\n const existingHandler = this._registrations[groupId];\r\n if (handler === existingHandler) {\r\n delete this._registrations[groupId];\r\n }\r\n this._publishLockState();\r\n }\r\n\r\n private _publishLockState(): void {\r\n const lockState = {};\r\n Object.keys(this._registrations).forEach(x => lockState[x] = !!this._registrations[x]);\r\n this._lockChangedSubject.next(lockState);\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n {{aggregate[errorType].label}}:\r\n
\r\n
\r\n
\r\n
\r\n \r\n {{ error.assessor }}\r\n {{ error.descriptor }}\r\n
\r\n
    \r\n
  • {{ parcel }}
  • \r\n
\r\n
\r\n
\r\n
\r\n {{ aggregate[errorType].warning }}\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\ninterface FormErrorTitles {\r\n modalTitle: string;\r\n label: string;\r\n warning: string;\r\n}\r\n\r\ninterface ValidateFormError {\r\n assessor: string;\r\n forms: string[];\r\n showForms: boolean;\r\n descriptor: string;\r\n}\r\n\r\ninterface ValidateFormAggregate {\r\n label: string;\r\n warning: string;\r\n type: Compliance.ReturnValidateFormResultEnum;\r\n errors: ValidateFormError[];\r\n}\r\n\r\nexport interface ReturnFormsErrorResult {\r\n errorTypes: Compliance.ReturnValidateFormResultEnum[];\r\n accepted: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'return-forms-error',\r\n templateUrl: './returnFormsError.component.html',\r\n styleUrls: ['./returnFormsError.component.scss']\r\n})\r\nexport class ReturnFormsErrorComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: Compliance.ReturnValidateFormsResultModel;\r\n result: ReturnFormsErrorResult;\r\n modalTitle: string;\r\n showCancel: boolean;\r\n\r\n aggregate: {\r\n [key: number]: ValidateFormAggregate\r\n };\r\n errorTypes: Compliance.ReturnValidateFormResultEnum[];\r\n\r\n private _titlesByErrorType: { [key in Compliance.ReturnValidateFormResultEnum]?: FormErrorTitles } = {\r\n [Compliance.ReturnValidateFormResultEnum.FormYearAssessorIsNotCertified]: {\r\n modalTitle: 'One or more forms have not been certified.',\r\n label: 'The following forms have not been certified',\r\n warning: 'By clicking OK you acknowledge that these forms are not yet certified and subject to change. Reported filing values may be impacted.'\r\n },\r\n [Compliance.ReturnValidateFormResultEnum.OneOrMoreFormsAreNotAvailable]: {\r\n modalTitle: 'One or more forms are not available.',\r\n label: 'Forms are not available for',\r\n warning: 'Remove filings or try again when the forms are available.'\r\n },\r\n [Compliance.ReturnValidateFormResultEnum.FormsAvailableButNoneArePrimary]: {\r\n modalTitle: 'Forms not automatically added.',\r\n label: 'Forms are not automatically added for',\r\n warning: 'Manually add forms to returns.'\r\n }\r\n };\r\n\r\n ngOnInit(): void {\r\n this.errorTypes = [...new Set(this.params.formErrors.map(p => p.errorType))].sort();\r\n const errorType = this.errorTypes.length === 1 && this.errorTypes[0];\r\n\r\n this.showCancel = errorType === Compliance.ReturnValidateFormResultEnum.FormYearAssessorIsNotCertified;\r\n\r\n this.modalTitle = this.errorTypes.length > 1\r\n ? 'Multiple errors have been discovered.'\r\n : this._titlesByErrorType[errorType].modalTitle;\r\n\r\n this.aggregate = this.errorTypes.reduce((acc, key) => {\r\n const grouped = this.params.formErrors.filter(x => x.errorType === key)\r\n .reduce((acc2, p) => {\r\n const groupingValue = this._getErrorGroupingValue(p);\r\n const displayValue = this._getErrorDisplayValue(p);\r\n acc2[groupingValue] = new Set((acc2[groupingValue])\r\n ? [...acc2[groupingValue], displayValue]\r\n : [displayValue]);\r\n return acc2;\r\n }, {});\r\n\r\n acc[key] = {\r\n label: this._titlesByErrorType[key].label,\r\n warning: this._titlesByErrorType[key].warning,\r\n type: key,\r\n errors: Object.keys(grouped).map((group) => ({\r\n assessor: group,\r\n forms: [...grouped[group]],\r\n showForms: false,\r\n descriptor: this._getListDescriptor(grouped[group].size, key)\r\n }))\r\n };\r\n return acc;\r\n }, {});\r\n }\r\n\r\n /**\r\n * Toggle the forms associated with the assessor\r\n * @param error\r\n */\r\n toggleParcels(error: ValidateFormError): void {\r\n error.showForms = !error.showForms;\r\n }\r\n\r\n /**\r\n * Accept and close the modal\r\n */\r\n accept(): void {\r\n this.result = {\r\n errorTypes: this.errorTypes,\r\n accepted: true\r\n };\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _getErrorGroupingValue(model: Compliance.ReturnValidateFormResultModel) {\r\n switch (model.errorType) {\r\n case Compliance.ReturnValidateFormResultEnum.FormYearAssessorIsNotCertified:\r\n return (model.formRevisionName) ? model.formRevisionName : 'Form not available';\r\n case Compliance.ReturnValidateFormResultEnum.OneOrMoreFormsAreNotAvailable:\r\n case Compliance.ReturnValidateFormResultEnum.FormsAvailableButNoneArePrimary:\r\n return model.assessorName;\r\n }\r\n }\r\n\r\n private _getErrorDisplayValue(model: Compliance.ReturnValidateFormResultModel) {\r\n switch (model.errorType) {\r\n case Compliance.ReturnValidateFormResultEnum.FormYearAssessorIsNotCertified:\r\n return model.assessorName;\r\n case Compliance.ReturnValidateFormResultEnum.OneOrMoreFormsAreNotAvailable:\r\n return (model.formRevisionName) ? model.formRevisionName : 'Form not available';\r\n case Compliance.ReturnValidateFormResultEnum.FormsAvailableButNoneArePrimary:\r\n return (model.formRevisionName) ? model.formRevisionName : 'Form not automatically added';\r\n }\r\n }\r\n\r\n private _getListDescriptor(length: number, errorType: Compliance.ReturnValidateFormResultEnum): string {\r\n switch (errorType) {\r\n case Compliance.ReturnValidateFormResultEnum.FormYearAssessorIsNotCertified:\r\n return `${length} Assessors Not Certified`;\r\n case Compliance.ReturnValidateFormResultEnum.OneOrMoreFormsAreNotAvailable:\r\n case Compliance.ReturnValidateFormResultEnum.FormsAvailableButNoneArePrimary:\r\n return `${length} + ${(length > 1 ? ' Forms' : ' Form')}`;\r\n }\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const RETURN_PAGE_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'return-page.merged',\r\n tooltipText: 'This parcel is part of a consolidated form.'\r\n },\r\n {\r\n helpContentId: 'return-page.form-setup',\r\n tooltipText: 'View the form setup in a new tab.'\r\n },\r\n {\r\n helpContentId: 'return-page.view-depreciation-table',\r\n tooltipText: 'View depreciation table'\r\n },\r\n {\r\n helpContentId: 'return-page.view-index-table',\r\n tooltipText: 'View index table'\r\n }\r\n];\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { ReconciliationReport } from './Models/reconciliationReport';\r\nimport { ReturnSummaryReconciliationReport } from './Models/returnSummaryReconciliationReport';\r\nimport { ReturnAssetsService, ReturnAssetsServiceSharedState } from './Return-Parts/Assets/returnAssets.service';\r\nimport {\r\n ReturnOverviewService,\r\n ReturnOverviewServiceSharedState\r\n} from './Return-Parts/Overview/returnOverview.service';\r\nimport { ReturnService, ReturnServiceSharedState } from './return.service';\r\nimport * as _ from 'lodash';\r\n\r\ninterface TabSharedState {\r\n returnService: ReturnServiceSharedState;\r\n returnAssetsService: ReturnAssetsServiceSharedState;\r\n returnOverviewService: ReturnOverviewServiceSharedState;\r\n}\r\n\r\ninterface TabSharedStates {\r\n [key: string]: TabSharedState;\r\n}\r\n\r\nexport interface ReturnFormRevisionListItem extends Compliance.ReturnFormRevisionModel {\r\n displayName?: string;\r\n}\r\n\r\n@Injectable()\r\nexport class ReturnUpdateLogicService {\r\n constructor(private readonly _returnService: ReturnService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _returnOverviewService: ReturnOverviewService) { }\r\n\r\n private readonly OVERVIEW_TAB = 'Overview';\r\n private readonly ASSETS_TAB = 'Assets';\r\n\r\n private _activeTab: string = this.OVERVIEW_TAB;\r\n\r\n private _sharedStates: TabSharedStates = {\r\n [this.OVERVIEW_TAB]: {\r\n returnService: null,\r\n returnAssetsService: null,\r\n returnOverviewService: null\r\n },\r\n [this.ASSETS_TAB]: {\r\n returnService: null,\r\n returnAssetsService: null,\r\n returnOverviewService: null\r\n }\r\n };\r\n\r\n private _loadingSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _loading$: Observable = this._loadingSubject.asObservable();\r\n\r\n private _returnFormRevisionsSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _returnFormRevision$: Observable = this._returnFormRevisionsSubject.asObservable();\r\n\r\n private _returnOverviewSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _returnOverview$: Observable = this._returnOverviewSubject.asObservable();\r\n\r\n private _returnSummarySubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _returnSummary$: Observable = this._returnSummarySubject.asObservable();\r\n\r\n private _returnAssessorsSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _returnAssessors$: Observable = this._returnAssessorsSubject.asObservable();\r\n\r\n get loading$(): Observable { return this._loading$; }\r\n get returnFormRevisions$(): Observable { return this._returnFormRevision$; }\r\n get returnOverviewReport$(): Observable { return this._returnOverview$; }\r\n get returnSummaryReport$(): Observable { return this._returnSummary$; }\r\n get returnAssessors$(): Observable { return this._returnAssessors$; }\r\n\r\n setActiveTab(activeTab: string): void {\r\n this._activeTab = activeTab;\r\n }\r\n\r\n startLoading(): void {\r\n if (!this._loadingSubject.value) {\r\n this._loadingSubject.next(true);\r\n }\r\n }\r\n\r\n stopLoading(): void {\r\n if (this._loadingSubject.value) {\r\n this._loadingSubject.next(false);\r\n }\r\n }\r\n\r\n async start(): Promise {\r\n this.startLoading();\r\n await this._refreshActiveTab();\r\n this.stopLoading();\r\n }\r\n\r\n async parcelFilterChanged(): Promise {\r\n await this._refreshActiveTab();\r\n }\r\n\r\n async returnFormRevisionChanged(): Promise {\r\n switch(this._activeTab) {\r\n case this.OVERVIEW_TAB:\r\n await this.refreshReturnOverview();\r\n break;\r\n case this.ASSETS_TAB:\r\n await this.refreshAssetFormDetails();\r\n break;\r\n default:\r\n break;\r\n }\r\n }\r\n\r\n async refreshReturnFormRevisions(): Promise {\r\n this._refreshReturnFormRevisions();\r\n }\r\n\r\n async refreshOverview(): Promise {\r\n this._refreshReturnFormRevisions();\r\n await this.refreshReturnOverview();\r\n this.stopLoading();\r\n }\r\n\r\n async refreshReturnOverview(): Promise {\r\n this._refreshReturnOverview();\r\n await this.refreshReturnSummary();\r\n this.stopLoading();\r\n }\r\n\r\n async refreshReturnSummary(): Promise {\r\n await this._refreshReturnSummary();\r\n this._persistLocalState();\r\n this.stopLoading();\r\n }\r\n\r\n async refreshAssetFormDetails(): Promise {\r\n this.startLoading();\r\n this._refreshReturnFormRevisions();\r\n await this.refreshAssessors();\r\n this.stopLoading();\r\n }\r\n\r\n async refreshAssessors(): Promise {\r\n await this._refreshAssessors();\r\n this._persistLocalState();\r\n this.stopLoading();\r\n }\r\n\r\n private async _refreshActiveTab(): Promise {\r\n switch(this._activeTab) {\r\n case this.OVERVIEW_TAB:\r\n await this.refreshOverview();\r\n break;\r\n case this.ASSETS_TAB:\r\n await this.refreshAssetFormDetails();\r\n break;\r\n default:\r\n break;\r\n }\r\n }\r\n\r\n private _refreshReturnFormRevisions(): void {\r\n const returnServiceSharedState: ReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n const localSharedState = this._sharedStates[this._activeTab]?.returnService;\r\n\r\n // get input parameters for comparison\r\n const localReturnIds = (localSharedState?.returns && localSharedState.returns.map(x => x.returnId)) || [];\r\n const sharedReturnIds = returnServiceSharedState.returns.map(x => x.returnId);\r\n\r\n const localReturnFormRevisionsUpdatedTimestamp = localSharedState?.returnFormRevisionsUpdatedTimestamp;\r\n const sharedReturnFormRevisionsUpdatedTimestamp = returnServiceSharedState.returnFormRevisionsUpdatedTimestamp;\r\n\r\n // check to see if input parameters have changed\r\n if (\r\n !_.isEqual(localReturnIds, sharedReturnIds) ||\r\n !_.isEqual(localReturnFormRevisionsUpdatedTimestamp, sharedReturnFormRevisionsUpdatedTimestamp)\r\n ) {\r\n const uniqueRevisions = this._returnService.getUniqueAssociatedReturnFormRevisions() as ReturnFormRevisionListItem[];\r\n const returnFormRevisions = _.sortBy(uniqueRevisions.map(x => {\r\n x.displayName = this._returnService.getReturnFormRevisionDisplayName(x);\r\n return x;\r\n }), (i: Compliance.ReturnFormRevisionModel) => i.formRevisionName);\r\n\r\n this._returnFormRevisionsSubject.next(returnFormRevisions);\r\n }\r\n }\r\n\r\n private _refreshReturnOverview(): void {\r\n const returnServiceSharedState: ReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n const returnAssetsServiceSharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n\r\n const localReturnSharedState = this._sharedStates[this._activeTab]?.returnService;\r\n const localReturnAssetsSharedState = this._sharedStates[this._activeTab]?.returnAssetsService;\r\n const localReturnOverviewServiceSharedState = this._sharedStates[this._activeTab]?.returnOverviewService;\r\n\r\n // get input parameters for comparison\r\n const localReturnIds = (localReturnSharedState?.returns && localReturnSharedState.returns.map(x => x.returnId)) || [];\r\n const sharedReturnIds = returnServiceSharedState.returns.map(x => x.returnId);\r\n\r\n const localFormRevisionId = localReturnSharedState?.formRevisionId;\r\n const sharedFormRevisionId = returnServiceSharedState.formRevisionId;\r\n\r\n const localReturnFormRevisionsUpdatedTimestamp = localReturnSharedState?.returnFormRevisionsUpdatedTimestamp;\r\n const sharedReturnFormRevisionsUpdatedTimestamp = returnServiceSharedState.returnFormRevisionsUpdatedTimestamp;\r\n\r\n const localReconciliationReport = localReturnOverviewServiceSharedState?.reconciliationReport;\r\n const sharedReconciliationReport = this._returnOverviewService.sharedState.reconciliationReport;\r\n\r\n const localAssetsUpdatedTimestamp = localReturnAssetsSharedState?.assetDetailsUpdatedTimestamp;\r\n const sharedAssetsUpdatedTimestamp = returnAssetsServiceSharedState?.assetDetailsUpdatedTimestamp;\r\n\r\n const localAssetMappingsUpdatedTimestamp = localReturnAssetsSharedState?.assetMappingsUpdatedTimestamp;\r\n const sharedAssetMappingsUpdatedTimestamp = returnAssetsServiceSharedState?.assetMappingsUpdatedTimestamp;\r\n\r\n // check to see if input parameters have changed\r\n if (!_.isEqual(localReturnIds, sharedReturnIds) ||\r\n !_.isEqual(localFormRevisionId, sharedFormRevisionId) ||\r\n !_.isEqual(localReturnFormRevisionsUpdatedTimestamp, sharedReturnFormRevisionsUpdatedTimestamp) ||\r\n !_.isEqual(localReconciliationReport, sharedReconciliationReport) ||\r\n !_.isEqual(localAssetsUpdatedTimestamp, sharedAssetsUpdatedTimestamp) ||\r\n !_.isEqual(localAssetMappingsUpdatedTimestamp, sharedAssetMappingsUpdatedTimestamp)) {\r\n const selectedReconciliationReport = this._returnOverviewService.availableReconciliationReports\r\n .find(x => x === this._returnOverviewService.sharedState.reconciliationReport) || this._returnOverviewService.reconciliationReports[0];\r\n\r\n this._returnOverviewSubject.next(selectedReconciliationReport);\r\n }\r\n }\r\n\r\n private async _refreshReturnSummary(): Promise {\r\n const returnServiceSharedState: ReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n const returnAssetsServiceSharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n const returnOverviewServiceSharedState: ReturnOverviewServiceSharedState = this._returnOverviewService.getSharedStateClone();\r\n\r\n const localReturnSharedState = this._sharedStates[this._activeTab]?.returnService;\r\n const localReturnAssetsSharedState = this._sharedStates[this._activeTab]?.returnAssetsService;\r\n const localReturnOverviewServiceSharedState = this._sharedStates[this._activeTab]?.returnOverviewService;\r\n\r\n // get input parameters for comparison\r\n const localFormRevisionId = localReturnSharedState?.formRevisionId;\r\n const sharedFormRevisionId = returnServiceSharedState.formRevisionId;\r\n\r\n const localReturnIds = (localReturnSharedState?.returns && localReturnSharedState?.returns.map(x => x.returnId)) || [];\r\n const sharedReturnIds = returnServiceSharedState.returns.map(x => x.returnId);\r\n\r\n const localReconciliationReport = localReturnOverviewServiceSharedState?.reconciliationReport;\r\n const sharedReconciliationReport = returnOverviewServiceSharedState.reconciliationReport;\r\n\r\n const localAssetDetailsUpdatedTimestamp = localReturnAssetsSharedState?.assetDetailsUpdatedTimestamp;\r\n const sharedAssetDetailsUpdatedTimestamp = returnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n\r\n const localAssetMappingsUpdatedTimestamp = localReturnAssetsSharedState?.assetMappingsUpdatedTimestamp;\r\n const sharedAssetMappingsUpdatedTimestamp = returnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n\r\n // check to see if input parameters are available\r\n if (!sharedReturnIds.length || sharedReconciliationReport === null) {\r\n this._returnSummarySubject.next(null);\r\n return;\r\n }\r\n\r\n // check to see if input parameters have changed\r\n if (\r\n !_.isEqual(localFormRevisionId, sharedFormRevisionId) ||\r\n !_.isEqual(localReturnIds, sharedReturnIds) ||\r\n !_.isEqual(localReconciliationReport, sharedReconciliationReport) ||\r\n !_.isEqual(localAssetDetailsUpdatedTimestamp, sharedAssetDetailsUpdatedTimestamp) ||\r\n !_.isEqual(localAssetMappingsUpdatedTimestamp, sharedAssetMappingsUpdatedTimestamp)\r\n ) {\r\n this.startLoading();\r\n const data = await this._returnOverviewService.getReturnSummaryReconciliationReport();\r\n this._returnSummarySubject.next(data);\r\n return;\r\n }\r\n\r\n this._returnSummarySubject.next(this._returnSummarySubject.getValue());\r\n }\r\n\r\n private async _refreshAssessors(): Promise {\r\n const returnServiceSharedState: ReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n\r\n const localReturnSharedState = this._sharedStates[this._activeTab]?.returnService;\r\n\r\n // get input parameters for comparison\r\n const localReturnIds = (localReturnSharedState?.returns && localReturnSharedState?.returns.map(x => x.returnId)) || [];\r\n const sharedReturnIds = returnServiceSharedState.returns.map(x => x.returnId);\r\n\r\n const localFormRevisionId = localReturnSharedState?.formRevisionId;\r\n const sharedFormRevisionId = returnServiceSharedState.formRevisionId;\r\n\r\n // check to see if input parameters are available\r\n if (!sharedReturnIds.length || !sharedFormRevisionId) {\r\n this._returnAssessorsSubject.next([]);\r\n return;\r\n } else {\r\n // check to see if input parameters have changed\r\n if (!this._returnAssessorsSubject.getValue()\r\n ||!_.isEqual(localReturnIds, sharedReturnIds)\r\n || !_.isEqual(localFormRevisionId, sharedFormRevisionId)) {\r\n this.startLoading();\r\n const assessors = await this._returnAssetsService.getAssessorsByFilingBatch(this._returnService.filingBatchId, {\r\n parcelIds: this._returnService.sharedState.returns.map(x => x.parcelId),\r\n formRevisionId: this._returnService.sharedState.formRevisionId,\r\n reportingAssetIds: []\r\n }) || [];\r\n\r\n this._returnAssessorsSubject.next(assessors);\r\n return;\r\n }\r\n }\r\n\r\n this._returnAssessorsSubject.next(this._returnAssessorsSubject.getValue());\r\n }\r\n\r\n private _persistLocalState(): void {\r\n if (!this._sharedStates[this._activeTab]) {\r\n this._sharedStates[this._activeTab] = {\r\n returnService: null,\r\n returnAssetsService: null,\r\n returnOverviewService: null\r\n };\r\n }\r\n this._sharedStates[this._activeTab].returnService = this._returnService.getSharedStateClone();\r\n this._sharedStates[this._activeTab].returnAssetsService = this._returnAssetsService.getSharedStateClone();\r\n this._sharedStates[this._activeTab].returnOverviewService = this._returnOverviewService.getSharedStateClone();\r\n }\r\n}\r\n","
    \r\n
  • \r\n {{ step.name }}\r\n
  • \r\n
\r\n","import { Component, Input } from '@angular/core';\r\n\r\nexport class StepProgressIndicatorStep {\r\n name: string;\r\n title: () => string;\r\n isError: () => boolean;\r\n isCurrent: () => boolean;\r\n isComplete: () => boolean;\r\n isWorking: () => boolean;\r\n click?: () => void;\r\n}\r\n\r\n@Component({\r\n selector: 'step-progress-indicator',\r\n templateUrl: './stepProgressIndicator.component.html',\r\n styleUrls: ['./stepProgressIndicator.component.scss']\r\n})\r\nexport class StepProgressIndicatorComponent {\r\n @Input() steps: StepProgressIndicatorStep[];\r\n @Input() clickable: boolean = true;\r\n @Input() showStepName: boolean = true;\r\n\r\n click(step: StepProgressIndicatorStep): void {\r\n if (!this.clickable) {\r\n return;\r\n }\r\n\r\n if (!step.isCurrent()) {\r\n return;\r\n }\r\n\r\n if (!step.click) {\r\n return;\r\n }\r\n\r\n step.click();\r\n }\r\n\r\n getClass(step: StepProgressIndicatorStep): string {\r\n let classString = 'step';\r\n\r\n if (step.isError()) {\r\n classString += ' error';\r\n }\r\n\r\n if (step.isCurrent()) {\r\n classString += ' current';\r\n\r\n if (this.clickable && step.click) {\r\n classString += ' clickable';\r\n }\r\n }\r\n\r\n if (step.isWorking()) {\r\n classString += ' working';\r\n }\r\n\r\n if (step.isComplete()) {\r\n classString += ' complete';\r\n }\r\n\r\n return classString;\r\n }\r\n}\r\n","import { Component, Input, Output, EventEmitter } from '@angular/core';\r\nimport { StepProgressIndicatorStep } from '../../../Common/Step-Progress-Indicator/stepProgressIndicator.component';\r\nimport { FilingBatchService } from '../filingBatch.service';\r\n\r\n@Component({\r\n selector: 'filing-batch-progress',\r\n template: ''\r\n})\r\nexport class FilingBatchProgressComponent {\r\n constructor(\r\n private readonly _filingBatchService: FilingBatchService\r\n ) { }\r\n\r\n @Input() filingBatch: Compliance.FilingBatchModel;\r\n @Input() showStepName: boolean = true;\r\n @Input() clickable: boolean = true;\r\n @Output() click: EventEmitter = new EventEmitter();\r\n \r\n steps: StepProgressIndicatorStep[] = [\r\n {\r\n name: 'BEGIN',\r\n title: this._getBeginTitle.bind(this),\r\n isError: this._beginIsError.bind(this),\r\n isCurrent: this._beginIsCurrent.bind(this),\r\n isWorking: this._beginIsWorking.bind(this),\r\n isComplete: this._beginIsComplete.bind(this),\r\n click: this._click.bind(this)\r\n },\r\n {\r\n name: 'LOCK',\r\n title: this._getLockTitle.bind(this),\r\n isError: this._lockIsError.bind(this),\r\n isCurrent: this._lockIsCurrent.bind(this),\r\n isWorking: this._lockIsWorking.bind(this),\r\n isComplete: this._lockIsComplete.bind(this),\r\n click: this._click.bind(this)\r\n },\r\n {\r\n name: 'FINALIZE',\r\n title: this._getFinalizeTitle.bind(this),\r\n isError: this._finalizeIsError.bind(this),\r\n isCurrent: this._finalizeIsCurrent.bind(this),\r\n isWorking: this._finalizeIsWorking.bind(this),\r\n isComplete: this._finalizeIsComplete.bind(this),\r\n click: this._click.bind(this)\r\n }\r\n ];\r\n\r\n private _getBeginTitle(): string {\r\n return 'Begin preparation';\r\n }\r\n\r\n private _beginIsError(): boolean {\r\n return false;\r\n }\r\n\r\n private _beginIsCurrent(): boolean {\r\n return this.filingBatch && this._filingBatchService.isNotStarted(this.filingBatch.processStatus);\r\n }\r\n\r\n private _beginIsWorking(): boolean {\r\n return false;\r\n }\r\n\r\n private _beginIsComplete(): boolean {\r\n return this.filingBatch && !this._filingBatchService.isNotStarted(this.filingBatch.processStatus);\r\n }\r\n\r\n private _getLockTitle(): string {\r\n return this.filingBatch && this._filingBatchService.hasLockError(this.filingBatch) ?\r\n this.filingBatch.longRunningProcessError :\r\n 'Lock';\r\n }\r\n\r\n private _lockIsError(): boolean {\r\n return this.filingBatch && this._filingBatchService.hasLockError(this.filingBatch);\r\n }\r\n\r\n private _lockIsCurrent(): boolean {\r\n return this.filingBatch && this._filingBatchService.isStarted(this.filingBatch.processStatus);\r\n }\r\n\r\n private _lockIsWorking(): boolean {\r\n return this.filingBatch &&\r\n (this._filingBatchService.isLocking(this.filingBatch.processStatus) ||\r\n this._filingBatchService.isUnlocking(this.filingBatch.processStatus) ||\r\n this._filingBatchService.isSigning(this.filingBatch.processStatus) ||\r\n this._filingBatchService.isUnsigning(this.filingBatch.processStatus));\r\n }\r\n\r\n private _lockIsComplete(): boolean {\r\n return this.filingBatch &&\r\n (this._filingBatchService.isLocked(this.filingBatch.processStatus) ||\r\n this._filingBatchService.isSigned(this.filingBatch.processStatus) ||\r\n this._filingBatchService.isFinalizing(this.filingBatch.processStatus) ||\r\n this._filingBatchService.isFinalized(this.filingBatch.processStatus));\r\n }\r\n\r\n private _getFinalizeTitle(): string {\r\n return this.filingBatch && this._filingBatchService.hasFinalizeError(this.filingBatch) ?\r\n this.filingBatch.longRunningProcessError :\r\n 'Finalize';\r\n }\r\n\r\n private _finalizeIsError(): boolean {\r\n return this.filingBatch && this._filingBatchService.hasFinalizeError(this.filingBatch);\r\n }\r\n\r\n private _finalizeIsCurrent(): boolean {\r\n return this.filingBatch && (this._filingBatchService.isLocked(this.filingBatch.processStatus) || this._filingBatchService.isSigned(this.filingBatch.processStatus));\r\n }\r\n\r\n private _finalizeIsWorking(): boolean {\r\n return this.filingBatch && this._filingBatchService.isFinalizing(this.filingBatch.processStatus);\r\n }\r\n\r\n private _finalizeIsComplete(): boolean {\r\n return this.filingBatch && this._filingBatchService.isFinalized(this.filingBatch.processStatus);\r\n }\r\n\r\n private _click(): void {\r\n if (!this.filingBatch) {\r\n return;\r\n }\r\n\r\n this.click.emit(this.filingBatch);\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const RETURN_LOCK_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'return-lock.validate-reports',\r\n tooltipText: 'Use for large batches to validate attachment sizes before starting to lock returns. Any attachments that are too large for PDF must be formatted as Excel.'\r\n }\r\n];\r\n","\r\n

Package Organization:

\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n

Additional Options:

\r\n
\r\n
\r\n \r\n\r\n \r\n \r\n
\r\n
\r\n \r\n\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { RETURN_LOCK_HELP } from './returnLockModal.component.help';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\n\r\nclass ReturnLockDropdownItem {\r\n name: string;\r\n label: string;\r\n value: number;\r\n}\r\n\r\nexport interface ReturnLockModalParams {\r\n filingBatchId: number;\r\n companyId: number;\r\n returnTaskUpdate: Compliance.ReturnTaskUpdateModel;\r\n}\r\n\r\n@Component({\r\n selector: 'return-lock-modal',\r\n templateUrl: './returnLockModal.component.html',\r\n styleUrls: ['./returnLockModal.component.scss']\r\n})\r\nexport class ReturnLockModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private _bsModalRef: BsModalRef,\r\n private readonly _helpService: HelpService) { }\r\n\r\n onClose: any;\r\n packageStrategies: ReturnLockDropdownItem[];\r\n selectedPackageStrategy: ReturnLockDropdownItem;\r\n returnInOwnPackageThresholdSelected: boolean = true;\r\n returnInOwnPackageThreshold: number;\r\n certifiedMailPackageThresholdSelected: boolean = true;\r\n certifiedMailPackageThreshold: number;\r\n\r\n params: ReturnLockModalParams;\r\n result: Compliance.ReturnLockRequestModel;\r\n\r\n ngOnInit() {\r\n this._helpService.setContent(RETURN_LOCK_HELP);\r\n\r\n this.packageStrategies = [\r\n { name: 'Assessor', value: Compliance.ReturnLockPackageStrategyEnum.PackageByAssessor, label: 'Package by Assessor' },\r\n { name: 'Company', value: Compliance.ReturnLockPackageStrategyEnum.PackageByCompany, label: 'Package by Company and Assessor' },\r\n { name: 'Return', value: Compliance.ReturnLockPackageStrategyEnum.PackageByReturn, label: 'One Return Per Package' }\r\n ];\r\n\r\n this.selectedPackageStrategy = this.packageStrategies[0];\r\n this.returnInOwnPackageThreshold = 250000;\r\n this.certifiedMailPackageThreshold = 50000;\r\n }\r\n\r\n async save(): Promise {\r\n this.result = {\r\n companyId: this.params.companyId,\r\n filingBatchId: this.params.filingBatchId,\r\n returnLockPackageStrategy: this.selectedPackageStrategy.value,\r\n returnTaskUpdate: this.params.returnTaskUpdate\r\n };\r\n\r\n if (this.certifiedMailPackageThresholdSelected) {\r\n this.result.certifiedMailPackageThreshold = this.certifiedMailPackageThreshold;\r\n }\r\n\r\n if (this.returnInOwnPackageThresholdSelected) {\r\n this.result.returnInOwnPackageThreshold = this.returnInOwnPackageThreshold;\r\n }\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n packageStrategyChanged(): void {\r\n if (this.selectedPackageStrategy == this.packageStrategies[2]){\r\n this.returnInOwnPackageThresholdSelected = false;\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const RETURN_SIGN_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'return-sign.skip-button',\r\n tooltipText: 'Skip applying digital signatures.'\r\n }\r\n];\r\n","import { Component, Input, Output, EventEmitter, ViewChild, ElementRef } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'warning-message',\r\n styleUrls: ['./warningMessage.component.scss'],\r\n template: `\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n {{message}}\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n `\r\n})\r\nexport class WarningMessageComponent {\r\n\r\n @Input() message: string;\r\n @Input() show: boolean;\r\n @Input() hasDetails: boolean;\r\n @Input() showDetails: boolean = false;\r\n @Output() showDetailsChange: EventEmitter = new EventEmitter();\r\n\r\n @ViewChild('details') warningDetails: ElementRef;\r\n\r\n edgeOffsetPercent: number = -50;\r\n\r\n /**\r\n * Toggle the message details open and closed\r\n */\r\n toggleDetails(): void {\r\n this.showDetails = !this.showDetails;\r\n this.showDetailsChange.emit(this.showDetails);\r\n if (this.showDetails) {\r\n this._calculateEdgeDistance();\r\n }\r\n }\r\n\r\n /**\r\n * Close the message details\r\n */\r\n closeDetails(): void {\r\n this.showDetails = false;\r\n this.showDetailsChange.emit(this.showDetails);\r\n }\r\n\r\n private _calculateEdgeDistance(): void {\r\n const position: DOMRect = this.warningDetails.nativeElement.getBoundingClientRect();\r\n const isOutsideEdgeBuffer = position.x < 40;\r\n if (isOutsideEdgeBuffer) {\r\n this.edgeOffsetPercent = -50 + (((40 - position.x) / position.width) * 100);\r\n }\r\n }\r\n}\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { ReturnSignActions } from '../../Models/enums';\r\nimport { GridOptions, GridReadyEvent, ColDef, GridApi } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams } from '../../../AgGrid';\r\nimport { ReturnService } from '../../return.service';\r\nimport { ReturnRepository } from '../../../Repositories';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from '../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { RETURN_SIGN_HELP } from './returnSignModal.component.help';\r\nimport { DecimalPipe } from '@angular/common';\r\n\r\nexport interface ReturnFormSignInfoRowModel extends Compliance.ReturnFormSignInfoModel {\r\n isError: boolean;\r\n isWarning: boolean;\r\n applicable: string;\r\n signerContactDisplay: string;\r\n}\r\n\r\nexport interface ReturnSignModalResult {\r\n action: ReturnSignActions;\r\n}\r\n\r\n@Component({\r\n selector: 'return-sign-modal',\r\n templateUrl: './returnSignModal.component.html',\r\n styleUrls: ['./returnSignModal.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ReturnSignModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _helpService: HelpService,\r\n private readonly _decimalPipe: DecimalPipe) { }\r\n\r\n private _gridApi: GridApi;\r\n private _signInfos: ReturnFormSignInfoRowModel[];\r\n\r\n isValid: boolean = false;\r\n agGridReady: boolean = false;\r\n params: void;\r\n result: ReturnSignModalResult;\r\n gridId: System.Guid = \"87B28C65-7868-495F-9C08-361D9477DD87\";\r\n wetSignatureOverrideWarning: string = \"\";\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(RETURN_SIGN_HELP);\r\n\r\n const signInfos = await lastValueFrom(this._returnRepository.getReturnSignInfo(this._returnService.filingBatchId));\r\n\r\n this._signInfos = signInfos.map(x => ({\r\n ...{\r\n isError: this._getIsError(x.status),\r\n isWarning: this._getIsWarning(x.status),\r\n applicable: this._getApplicable(x.status),\r\n signerContactDisplay: x.signerContactName ? `${x.signerContactName} (${this._returnService.getRepresentationType(x.representationType)})` : ''\r\n } as ReturnFormSignInfoRowModel,\r\n ...x\r\n }));\r\n\r\n if (this._signInfos.find(x => x.status === Compliance.ReturnFormSignInfoStatusEnum.WetSignatureOverrideAllowed)) {\r\n this.wetSignatureOverrideWarning = \"One or more jurisdictions require a wet signature.\";\r\n }\r\n\r\n this.isValid = !this._signInfos.find(x => x.isError);\r\n this._setRowData();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Parcel',\r\n field: 'parcelAcctNum',\r\n lockVisible: true,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n if (!signInfo) {\r\n return '';\r\n }\r\n return `#/parcel/${signInfo.parcelId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Form',\r\n field: 'formRevisionName',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n if (!signInfo) {\r\n return '';\r\n }\r\n return `#/assessor/${signInfo.assessorId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Wet Signature',\r\n field: 'assessorWetSignatureRequired',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n return signInfo && signInfo.assessorWetSignatureRequired ? 'Yes' : 'No';\r\n },\r\n filterValueGetter: params => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n return signInfo && signInfo.assessorWetSignatureRequired ? 'Yes' : 'No';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Signer',\r\n field: 'signerContactDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-contact',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n if (!signInfo) {\r\n return '';\r\n }\r\n return `#/contacts/${signInfo.signerContactId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Owner Signer',\r\n field: 'ownerContactName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-contact',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n if (!signInfo) {\r\n return '';\r\n }\r\n return `#/contacts/${signInfo.ownerContactId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: '# Signature Fields',\r\n field: 'signatureFieldsCount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell',\r\n valueFormatter: (params) => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n if (!signInfo) {\r\n return '';\r\n }\r\n return this._decimalPipe.transform(signInfo.signatureFieldsCount, '1.0-0');\r\n },\r\n filterValueGetter: params => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n if (!signInfo) {\r\n return '';\r\n }\r\n return this._decimalPipe.transform(signInfo.signatureFieldsCount, '1.0-0');\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: '# Date Fields',\r\n field: 'dateFieldsCount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell',\r\n valueFormatter: (params) => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n if (!signInfo) {\r\n return '';\r\n }\r\n return this._decimalPipe.transform(signInfo.dateFieldsCount, '1.0-0');\r\n },\r\n filterValueGetter: params => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n if (!signInfo) {\r\n return '';\r\n }\r\n return this._decimalPipe.transform(signInfo.dateFieldsCount, '1.0-0');\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Applicable',\r\n field: 'applicable',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: params => {\r\n const signInfo = params.data as ReturnFormSignInfoRowModel;\r\n return (signInfo && signInfo.isError) ? 'cell-validation-error' : (signInfo.isWarning ? 'cell-validation-warning' : null);\r\n }\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'parcelAcctNum',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this.agGridReady = true;\r\n this._setRowData();\r\n }\r\n\r\n selectedActionChanged(action: ReturnSignActions): void {\r\n this._gridApi.redrawRows();\r\n }\r\n\r\n save(): void {\r\n this.result = {\r\n action: ReturnSignActions.Sign\r\n };\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n skip(): void {\r\n this.result = {\r\n action: ReturnSignActions.Skip\r\n };\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _getApplicable(status: Compliance.ReturnFormSignInfoStatusEnum): string {\r\n switch (status) {\r\n case Compliance.ReturnFormSignInfoStatusEnum.NotApplicable: return 'No';\r\n case Compliance.ReturnFormSignInfoStatusEnum.Applicable: return 'Yes';\r\n case Compliance.ReturnFormSignInfoStatusEnum.DatesOnly: return 'Only Date Fields';\r\n case Compliance.ReturnFormSignInfoStatusEnum.InvalidSigner: return 'Invalid Signer';\r\n case Compliance.ReturnFormSignInfoStatusEnum.InvalidSignerSignature: return 'Missing Signature';\r\n case Compliance.ReturnFormSignInfoStatusEnum.NotAuthorizedSignerSignature: return 'Not Authorized';\r\n case Compliance.ReturnFormSignInfoStatusEnum.InvalidOwner: return 'Invalid Owner';\r\n case Compliance.ReturnFormSignInfoStatusEnum.InvalidOwnerSignature: return 'Missing Owner Signature';\r\n case Compliance.ReturnFormSignInfoStatusEnum.NotAuthorizedOwnerSignature: return 'Not Authorized Owner';\r\n case Compliance.ReturnFormSignInfoStatusEnum.WetSignatureOverrideAllowed: return 'Wet Signature Required';\r\n default: return '';\r\n }\r\n }\r\n\r\n private _getIsError(status: Compliance.ReturnFormSignInfoStatusEnum): boolean {\r\n switch (status) {\r\n case Compliance.ReturnFormSignInfoStatusEnum.InvalidSigner: return true;\r\n case Compliance.ReturnFormSignInfoStatusEnum.InvalidSignerSignature: return true;\r\n case Compliance.ReturnFormSignInfoStatusEnum.NotAuthorizedSignerSignature: return true;\r\n case Compliance.ReturnFormSignInfoStatusEnum.InvalidOwner: return true;\r\n case Compliance.ReturnFormSignInfoStatusEnum.InvalidOwnerSignature: return true;\r\n case Compliance.ReturnFormSignInfoStatusEnum.NotAuthorizedOwnerSignature: return true;\r\n default: return false;\r\n }\r\n }\r\n\r\n private _getIsWarning(status: Compliance.ReturnFormSignInfoStatusEnum): boolean {\r\n switch (status) {\r\n case Compliance.ReturnFormSignInfoStatusEnum.WetSignatureOverrideAllowed: return true;\r\n default: return false;\r\n }\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._signInfos && this.agGridReady)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._signInfos);\r\n }\r\n}\r\n","\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
Please provide a filing batch description.
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n
Please provide a due date.
\r\n
\r\n
\r\n\r\n \r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { UntypedFormControl, UntypedFormGroup, ValidationErrors, Validators } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport ReturnFinalizeSyncValueOptionEnum = Compliance.ReturnFinalizeSyncValueOptionEnum;\r\n\r\nexport interface ReturnFinalizeModalParams {\r\n filingBatchId: number;\r\n companyId: number;\r\n taskUpdateModel: Compliance.ReturnTaskUpdateModel;\r\n nextYearBatch: Compliance.FilingBatchCreateModel;\r\n finalizeSyncOptions: Compliance.ReturnFinalizeSyncValueOptionEnum[];\r\n}\r\n\r\n@Component({\r\n selector: 'return-finalize-modal',\r\n templateUrl: './returnFinalizeModal.component.html',\r\n styleUrls: ['./returnFinalizeModal.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ReturnFinalizeModalComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef) {}\r\n\r\n params: ReturnFinalizeModalParams;\r\n result: Compliance.ReturnFinalizeRequestModel;\r\n\r\n finalizeOptionsForm: UntypedFormGroup;\r\n filingBatchGroup: UntypedFormGroup;\r\n createNextYear: UntypedFormControl = new UntypedFormControl(false);\r\n nextYear: number;\r\n minDate: Date;\r\n\r\n private _attachReturns = new UntypedFormControl(true);\r\n private _embedExcelReportsInPdf = new UntypedFormControl(false);\r\n private _syncTargetValue = new UntypedFormControl(ReturnFinalizeSyncValueOptionEnum.No);\r\n private _syncEstimatedFMV = new UntypedFormControl(ReturnFinalizeSyncValueOptionEnum.No);\r\n private _destroy$: Subject = new Subject();\r\n\r\n syncOptions: System.Collections.Generic.KeyValuePair[] = [{ key: ReturnFinalizeSyncValueOptionEnum.No, value: 'No' }];\r\n\r\n // validators\r\n nameValidation = (control: UntypedFormControl): ValidationErrors | null => (control.value && control.value.length) ? null : { nameInvalid: true };\r\n formValidation = (control: UntypedFormGroup): ValidationErrors | null => {\r\n if (this.createNextYear.value) {\r\n const subGroup = control.get('nextYearBatchModel');\r\n return (subGroup.get('description').valid\r\n && subGroup.get('dueDate').valid) ? null : { formInvalid: true };\r\n }\r\n return null;\r\n };\r\n\r\n ngOnInit(): void {\r\n this.nextYear = this.params.nextYearBatch.taxYear;\r\n const day = this.params.nextYearBatch.dueDate.getDate();\r\n const month = this.params.nextYearBatch.dueDate.getMonth();\r\n this.minDate = new Date(this.nextYear, month, day);\r\n\r\n let initialFinalizeOption = ReturnFinalizeSyncValueOptionEnum.No;\r\n\r\n this.params.finalizeSyncOptions.forEach(x => {\r\n switch(x) {\r\n case ReturnFinalizeSyncValueOptionEnum.ReportedValue:\r\n this.syncOptions.push({ key: ReturnFinalizeSyncValueOptionEnum.ReportedValue, value: 'Dep. Value' });\r\n initialFinalizeOption = ReturnFinalizeSyncValueOptionEnum.ReportedValue;\r\n break;\r\n case ReturnFinalizeSyncValueOptionEnum.EstimatedFMV:\r\n this.syncOptions.push({ key: ReturnFinalizeSyncValueOptionEnum.EstimatedFMV, value: 'Est. FMV' });\r\n break;\r\n case ReturnFinalizeSyncValueOptionEnum.FinalAssessedValue:\r\n this.syncOptions.push({ key: ReturnFinalizeSyncValueOptionEnum.FinalAssessedValue, value: 'Final Assessed Value' });\r\n initialFinalizeOption = ReturnFinalizeSyncValueOptionEnum.FinalAssessedValue;\r\n break;\r\n default:\r\n break;\r\n }\r\n });\r\n\r\n this._syncTargetValue.setValue(initialFinalizeOption);\r\n this._syncEstimatedFMV.setValue(initialFinalizeOption);\r\n\r\n this.filingBatchGroup = new UntypedFormGroup({\r\n description: new UntypedFormControl({ value: null, disabled: true }, this.nameValidation),\r\n dueDate: new UntypedFormControl({ value: this.minDate, disabled: true }, [Validators.required]),\r\n createFilingsAsNecessary: new UntypedFormControl({ value: false, disabled: true }),\r\n taxYear: new UntypedFormControl(this.nextYear)\r\n });\r\n\r\n this.filingBatchGroup.patchValue(this.params.nextYearBatch);\r\n this.filingBatchGroup.disable();\r\n\r\n this.finalizeOptionsForm = new UntypedFormGroup({\r\n attachReturns: this._attachReturns,\r\n embedExcelReportsInPdf: this._embedExcelReportsInPdf,\r\n syncTargetValue: this._syncTargetValue,\r\n syncEstimatedFMV: this._syncEstimatedFMV,\r\n nextYearBatchModel: this.filingBatchGroup\r\n }, this.formValidation);\r\n\r\n this.createNextYear.valueChanges.pipe(takeUntil(this._destroy$))\r\n .subscribe(checked => this._toggleNextYearGroup(checked));\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n /**\r\n * Submit the form\r\n * */\r\n submit(): void {\r\n this.result = {\r\n filingBatchId: this.params.filingBatchId,\r\n companyId: this.params.companyId,\r\n taskUpdateModel: this.params.taskUpdateModel,\r\n attachReturns: this.finalizeOptionsForm.get('attachReturns').value,\r\n embedExcelReportsInPdf: this.finalizeOptionsForm.get('embedExcelReportsInPdf').value,\r\n syncEstimatedFMV: this.finalizeOptionsForm.get('syncEstimatedFMV').value,\r\n syncTargetValue: this.finalizeOptionsForm.get('syncTargetValue').value,\r\n nextYearBatchModel: this.createNextYear.value ? this.finalizeOptionsForm.get('nextYearBatchModel').value : null,\r\n force: false\r\n };\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n /**\r\n * Close the modal\r\n * */\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n /**\r\n * Set the due date value from the date picker\r\n * @param date\r\n */\r\n onDueDateChanged(date: Date): void {\r\n this.filingBatchGroup.get('dueDate').setValue(date);\r\n }\r\n\r\n private _toggleNextYearGroup(enabled: boolean): void {\r\n if (enabled) {\r\n this.filingBatchGroup.enable();\r\n } else {\r\n this.filingBatchGroup.disable();\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy, Output, EventEmitter } from '@angular/core';\r\nimport { ReturnService } from '../return.service';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { ReturnLockModalComponent, ReturnLockModalParams } from './Return-Lock-Modal/returnLockModal.component';\r\nimport { IMutexServiceHandler, WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { Subscription } from 'rxjs';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { TaskTypes, ReturnSignActions } from '../Models/enums';\r\nimport { TaskError } from '../Models/taskError';\r\nimport { ReturnSignModalComponent } from './Return-Sign-Modal/returnSignModal.component';\r\nimport { ReturnFinalizeModalComponent, ReturnFinalizeModalParams } from './Return-Finalize-Modal/returnFinalizeModal.component';\r\n\r\ninterface TaskMapping {\r\n active: string;\r\n next: string;\r\n title: string;\r\n action: () => Promise;\r\n confirm: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'return-task',\r\n templateUrl: './returnTask.component.html'\r\n})\r\nexport class ReturnTaskComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyService: BusyIndicatorService) { }\r\n\r\n @Output() taskError: EventEmitter = new EventEmitter();\r\n\r\n currentTask: TaskMapping;\r\n nextTask: TaskMapping;\r\n canEdit: boolean;\r\n currentTaskId: number;\r\n\r\n private _tasksSub: Subscription;\r\n private _taskMap = new Map(\r\n [\r\n [TaskTypes.PPBatchReturnLoadData, { title: 'Mark Load Data Complete', next: 'and requests data load', active: 'Completes the load data task', action: this._completeTask.bind(this), confirm: true }],\r\n [TaskTypes.PPBatchReturnPrepareReturns, { title: 'Mark Preparation Complete (Lock)', next: 'allowing return preparation to begin', active: 'Locks the returns, completes the prepare returns task', action: this._prepareReturns.bind(this), confirm: false }],\r\n [TaskTypes.PPBatchReturnReviewReturns, { title: 'Mark Review Complete', next: 'and requests review', active: 'Completes the review task', action: this._completeTask.bind(this), confirm: true }],\r\n [TaskTypes.PPBatchReturnApproveReturns, { title: 'Approve Returns for Filing', next: 'and requests approval', active: 'Completes the approve returns task', action: this._completeTask.bind(this), confirm: true }],\r\n [TaskTypes.PPBatchReturnDigitiallySignReturns, { title: 'Apply Applicable Digital Signatures', next: 'and requests digital signature be applied', active: 'Applies digital signature', action: this._digitallySignReturns.bind(this), confirm: false }],\r\n [TaskTypes.PPBatchReturnFileReturns, { title: 'Mark Return Filing Complete', next: 'and requests returns be filed', active: 'Completes the file PP returns task', action: this._completeTask.bind(this), confirm: true }],\r\n [TaskTypes.PPBatchReturnFinalizeReturns, { title: 'Finalize Returns (No Undo)', next: 'and requests finalization', active: 'Finalizes returns optionally copying return content to the individual filings under parcel accounts. This process cannot be undone', action: this._finalizeReturns.bind(this), confirm: false }],\r\n [TaskTypes.PPReturnFiling, { title: 'Mark Return Filing Complete', next: 'and requests the return be filed', active: 'Completes the file PP return task', action: this._completeTask.bind(this), confirm: true }]\r\n ]\r\n );\r\n\r\n get canEnterEditMode(): boolean { return this._mutexService.canAcquire(this._returnService.editGroup); }\r\n get isLongRunningProcessActive(): boolean { return this._returnService.isLongRunningProcessActive; }\r\n\r\n get currentTaskTooltip(): string {\r\n if (!this.currentTask) {\r\n return '';\r\n }\r\n\r\n if (!this.canEnterEditMode) {\r\n return 'Not available in edit mode. Save changes or cancel.';\r\n }\r\n\r\n if (this.isLongRunningProcessActive) {\r\n return 'Not available because a process is busy.';\r\n }\r\n\r\n if (!this.canEdit) {\r\n return 'Not available to complete.';\r\n }\r\n\r\n return `${this.currentTask.active}${this.nextTask ? ` ${ this.nextTask.next}` : ''}.`;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._refreshTasks();\r\n this._tasksSub = this._returnService.tasks$.subscribe(() => this._refreshTasks());\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._tasksSub && this._tasksSub.unsubscribe();\r\n }\r\n\r\n async completeCurrentTask(): Promise {\r\n if (this.currentTask.confirm) {\r\n try {\r\n await this._messageModalService.prompt(`Are you sure you wish to ${this.currentTask.title.toLowerCase()}?`, 'Confirm');\r\n } catch (e) {\r\n return;\r\n }\r\n }\r\n\r\n try {\r\n await this.currentTask.action();\r\n } catch (e2) {\r\n this.taskError.next({\r\n error: e2,\r\n message: `Failed to ${this.currentTask.title.toLowerCase()}.`\r\n } as TaskError);\r\n }\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n private _refreshTasks(): void {\r\n // set the current task\r\n let currentTask: TaskMapping = null;\r\n let canEdit: boolean = false;\r\n let currentTaskId: number = null;\r\n\r\n if (this._returnService.currentTask) {\r\n currentTask = this._taskMap.get(this._returnService.currentTask.taskTypeID);\r\n canEdit = this._returnService.currentTask.taskAuthorizationInfo.completeTask;\r\n currentTaskId = this._returnService.currentTask.taskID;\r\n }\r\n\r\n this.currentTask = currentTask;\r\n this.canEdit = canEdit;\r\n this.currentTaskId = currentTaskId;\r\n\r\n // set the next task\r\n let nextTask: TaskMapping = null;\r\n\r\n if (this._returnService.nextTask) {\r\n nextTask = this._taskMap.get(this._returnService.nextTask.taskTypeID);\r\n }\r\n\r\n this.nextTask = nextTask;\r\n }\r\n\r\n private async _completeTask(): Promise {\r\n const busyRef = this._busyService.show({ message: 'Completing Task' });\r\n\r\n try {\r\n const taskUpdateModel = {\r\n taskId: this.currentTaskId\r\n } as Compliance.ReturnTaskUpdateModel;\r\n\r\n await this._returnService.completeTask(taskUpdateModel);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n private async _skipTask(): Promise {\r\n const busyRef = this._busyService.show({ message: 'Skipping Task' });\r\n\r\n try {\r\n const taskUpdateModel = {\r\n taskId: this.currentTaskId\r\n } as Compliance.ReturnTaskUpdateModel;\r\n\r\n await this._returnService.skipTask(taskUpdateModel);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n private async _prepareReturns(): Promise {\r\n const params: ReturnLockModalParams = {\r\n filingBatchId: this._returnService.filingBatchId,\r\n companyId: this._returnService.companyId,\r\n returnTaskUpdate: {\r\n taskId: this.currentTaskId\r\n } as Compliance.ReturnTaskUpdateModel\r\n };\r\n\r\n const result = await this._modalService.showAsync(ReturnLockModalComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyService.show({ message: 'Locking' });\r\n\r\n try {\r\n await this._returnService.startLocking(result);\r\n this._returnService.notifyProcessStatusChange(Compliance.FilingBatchProcessStatusEnum.Locking);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private async _digitallySignReturns(): Promise {\r\n const result = await this._modalService.showAsync(ReturnSignModalComponent, null, 'modal-xl');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (result.action === ReturnSignActions.Skip) {\r\n await this._skipTask();\r\n } else {\r\n const returnSignRequestModel: Compliance.ReturnSignRequestModel =\r\n {\r\n filingBatchId: this._returnService.filingBatchId,\r\n companyId: this._returnService.companyId,\r\n returnTaskUpdate: {\r\n taskId: this.currentTaskId\r\n }\r\n };\r\n\r\n const busyRef = this._busyService.show({ message: 'Signing Applicable Returns' });\r\n\r\n try {\r\n await this._returnService.startSigning(returnSignRequestModel);\r\n this._returnService.notifyProcessStatusChange(Compliance.FilingBatchProcessStatusEnum.Signing);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n }\r\n\r\n private async _finalizeReturns(): Promise {\r\n let busyRef = this._busyService.show({ message: 'Loading' });\r\n let nextYearBatch: Compliance.FilingBatchCreateModel;\r\n let finalizeSyncOptions: Compliance.ReturnFinalizeSyncValueOptionEnum[];\r\n\r\n try {\r\n nextYearBatch = await this._returnService.nextYearInfo(this._returnService.filingBatchId);\r\n finalizeSyncOptions = await this._returnService.getFinalizeSyncOptions(this._returnService.filingBatchId);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n const params: ReturnFinalizeModalParams = {\r\n filingBatchId: this._returnService.filingBatchId,\r\n companyId: this._returnService.companyId,\r\n taskUpdateModel: {\r\n taskId: this.currentTaskId\r\n },\r\n nextYearBatch: nextYearBatch,\r\n finalizeSyncOptions: finalizeSyncOptions\r\n };\r\n\r\n const result = await this._modalService.showAsync(ReturnFinalizeModalComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n busyRef = this._busyService.show({ message: 'Finalizing' });\r\n\r\n try {\r\n await this._returnService.startFinalizing(result);\r\n busyRef.hide();\r\n\r\n this._returnService.notifyProcessStatusChange(Compliance.FilingBatchProcessStatusEnum.Finalizing);\r\n } catch (e) {\r\n busyRef.hide();\r\n\r\n // service returns a 422 and a message if user confirmation needed\r\n if (e && e.status !== 422) {\r\n return Promise.reject(e);\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(e.error.message, 'Confirm');\r\n } catch (e2) {\r\n return Promise.resolve();\r\n }\r\n\r\n busyRef = this._busyService.show({ message: 'Finalizing' });\r\n\r\n // force\r\n result.force = true;\r\n await this._returnService.startFinalizing(result);\r\n busyRef.hide();\r\n\r\n this._returnService.notifyProcessStatusChange(Compliance.FilingBatchProcessStatusEnum.Finalizing);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n No options available\r\n
\r\n
\r\n
\r\n","import { from as observableFrom, lastValueFrom, Observable } from 'rxjs';\r\nimport {map, mergeMap} from 'rxjs/operators';\r\nimport { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { ReturnService } from '../../return.service';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../../Busy-Indicator';\r\nimport { TaskTypes, TaskProcessingActions } from '../../Models/enums';\r\nimport * as _ from 'lodash';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { ExtendedUserTeamModel } from '../../Models/extendedContactModel';\r\nimport { ReturnRepository } from '../../../Repositories';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { ProductAnalyticsService } from \"../../../../Common/Amplitude/productAnalytics.service\";\r\n\r\ninterface TaskMapping {\r\n rescindLevels: TaskTypes[];\r\n rescindAction: () => Promise;\r\n reassignAction: () => Promise;\r\n includeCompanyRepresentative: boolean;\r\n}\r\n\r\ninterface TaskExceptionOption {\r\n taskId: number;\r\n taskTypeId: number;\r\n action: TaskProcessingActions;\r\n title: string;\r\n taskName: string;\r\n assignedUser: ExtendedUserTeamModel;\r\n includeCompanyRepresentative: boolean;\r\n isAuthorized?: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'return-task-exception-modal',\r\n templateUrl: './returnTaskExceptionModal.component.html'\r\n})\r\nexport class ReturnTaskExceptionModalComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) { }\r\n\r\n private _taskMap = new Map(\r\n [\r\n [TaskTypes.PPBatchReturnLoadData, { rescindLevels: [], includeCompanyRepresentative: false, rescindAction: this._unlock.bind(this), reassignAction: this._reassign.bind(this) }],\r\n [TaskTypes.PPBatchReturnPrepareReturns, { rescindLevels: [TaskTypes.PPBatchReturnLoadData], includeCompanyRepresentative: false, rescindAction: this._unlock.bind(this), reassignAction: this._reassign.bind(this) }],\r\n [TaskTypes.PPBatchReturnReviewReturns, { rescindLevels: [TaskTypes.PPBatchReturnPrepareReturns], includeCompanyRepresentative: false, rescindAction: this._unsign.bind(this), reassignAction: this._reassign.bind(this) }],\r\n [TaskTypes.PPBatchReturnApproveReturns, { rescindLevels: [TaskTypes.PPBatchReturnReviewReturns], includeCompanyRepresentative: true, rescindAction: this._unsign.bind(this), reassignAction: this._reassign.bind(this) }],\r\n [TaskTypes.PPBatchReturnDigitiallySignReturns, { rescindLevels: [TaskTypes.PPBatchReturnReviewReturns, TaskTypes.PPBatchReturnPrepareReturns], includeCompanyRepresentative: false, rescindAction: this._unsign.bind(this), reassignAction: this._reassign.bind(this) }],\r\n [TaskTypes.PPBatchReturnFileReturns, { rescindLevels: [TaskTypes.PPBatchReturnDigitiallySignReturns, TaskTypes.PPBatchReturnApproveReturns, TaskTypes.PPBatchReturnReviewReturns, TaskTypes.PPBatchReturnPrepareReturns], includeCompanyRepresentative: false, rescindAction: this._unsign.bind(this), reassignAction: this._reassign.bind(this) }],\r\n [TaskTypes.PPBatchReturnFinalizeReturns, { rescindLevels: [TaskTypes.PPBatchReturnFileReturns], includeCompanyRepresentative: false, rescindAction: this._rescindToTask.bind(this), reassignAction: this._reassign.bind(this) }],\r\n [TaskTypes.PPReturnFiling, { rescindLevels: [], includeCompanyRepresentative: false, rescindAction: this._rescindToTask.bind(this), reassignAction: this._reassign.bind(this) }]\r\n ]\r\n );\r\n\r\n params: void;\r\n result: boolean;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n options: TaskExceptionOption[] = [];\r\n selectedOption: TaskExceptionOption;\r\n comment: string;\r\n selectedUserTeam: ExtendedUserTeamModel;\r\n userTeamFilter: string = '';\r\n userTeamsLoading: boolean = false;\r\n userTeams$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.userTeamFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterUserTeams(token)));\r\n\r\n async ngOnInit(): Promise {\r\n\r\n const options: TaskExceptionOption[] = [];\r\n\r\n const currentTaskMapping = this._taskMap.get(this._returnService && this._returnService.currentTask.taskTypeID);\r\n\r\n if (currentTaskMapping) {\r\n options.push({\r\n action: TaskProcessingActions.ReassignTask,\r\n taskId: this._returnService.currentTask.taskID,\r\n title: `Reassign ${this._returnService.currentTask.taskType.name}`,\r\n taskName: this._returnService.currentTask.taskType.name,\r\n taskTypeId: this._returnService.currentTask.taskTypeID,\r\n assignedUser: null,\r\n includeCompanyRepresentative: currentTaskMapping.includeCompanyRepresentative,\r\n isAuthorized: this._returnService.currentTask && this._returnService.currentTask.taskAuthorizationInfo.reassignTask\r\n });\r\n\r\n _.forEach(currentTaskMapping.rescindLevels, (x) => {\r\n const task = _.find(this._returnService.tasks, y => y.taskTypeID === x as number);\r\n if (task) {\r\n const userTeamModel: Core.UserTeamModel = _.extend(\r\n {} as Core.UserTeamModel,\r\n task.assignedUser,\r\n {\r\n teamID: task.assignedTeamID,\r\n teamName: task.assignedTeam && task.assignedTeam.name\r\n });\r\n\r\n options.push({\r\n action: TaskProcessingActions.RescindTask,\r\n title: `Rescind to ${task.taskType.name}`,\r\n taskName: task.taskType.name,\r\n taskId: task.taskID,\r\n taskTypeId: task.taskTypeID,\r\n assignedUser: new ExtendedUserTeamModel(userTeamModel),\r\n includeCompanyRepresentative: currentTaskMapping.includeCompanyRepresentative,\r\n isAuthorized: this._returnService.priorCompletedTask && this._returnService.priorCompletedTask.taskAuthorizationInfo.rescindTask\r\n });\r\n }\r\n });\r\n }\r\n\r\n this.options = options;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n }\r\n\r\n onUserTeamSelected(match: TypeaheadMatch): void {\r\n this.selectedUserTeam = match.item as ExtendedUserTeamModel;\r\n this.userTeamFilter = match.value;\r\n }\r\n\r\n onUserTeamBlur(): void {\r\n if (!this.userTeamFilter || this.userTeamFilter.trim() === '') {\r\n this.selectedUserTeam = this.selectedOption && this.selectedOption.assignedUser;\r\n this.userTeamFilter = this.selectedOption && this.selectedOption.assignedUser && this.selectedOption.assignedUser.displayName;\r\n }\r\n }\r\n\r\n selectedOptionChanged(option: TaskExceptionOption): void {\r\n this.selectedUserTeam = option && option.assignedUser;\r\n this.userTeamFilter = option && option.assignedUser && option.assignedUser.displayName;\r\n\r\n if (this.selectedUserTeam == null) {\r\n this.userTeamFilter = '';\r\n }\r\n }\r\n\r\n onUserTeamsLoadingChange(isLoading: boolean): void {\r\n this.userTeamsLoading = isLoading;\r\n if (isLoading) {\r\n this.selectedUserTeam = null;\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsg = 'saving';\r\n\r\n const taskMapping = this._taskMap.get(this.selectedOption.taskTypeId);\r\n let message: string;\r\n let action: () => void;\r\n\r\n switch (this.selectedOption.action) {\r\n case TaskProcessingActions.RescindTask:\r\n action = taskMapping.rescindAction;\r\n message = 'Rescinding';\r\n this._productAnalyticsService.logEvent('click-exception-rescind-ok', {\r\n rescindTask: this.selectedOption.taskName\r\n })\r\n break;\r\n case TaskProcessingActions.ReassignTask:\r\n action = taskMapping.reassignAction;\r\n message = 'Reassigning';\r\n break;\r\n default:\r\n message = 'Saving';\r\n action = () => { }\r\n break;\r\n }\r\n\r\n this.busyIndicatorMessageManager.add(message, busyMsg);\r\n\r\n try {\r\n await action();\r\n\r\n this.result = true;\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private async _rescindToTask(): Promise {\r\n const taskUpdateModel: Compliance.ReturnTaskUpdateModel = {\r\n taskId: this.selectedOption.taskId,\r\n comment: this.comment,\r\n assignedUserId: this.selectedUserTeam && this.selectedUserTeam.model.userID,\r\n assignedTeamId: this.selectedUserTeam && this.selectedUserTeam.model.teamID,\r\n };\r\n\r\n await this._returnService.rescindToTask(taskUpdateModel);\r\n }\r\n\r\n private async _unlock(): Promise {\r\n const taskUpdateModel: Compliance.ReturnTaskUpdateModel = {\r\n taskId: this.selectedOption.taskId,\r\n comment: this.comment,\r\n assignedUserId: this.selectedUserTeam && this.selectedUserTeam.model.userID,\r\n assignedTeamId: this.selectedUserTeam && this.selectedUserTeam.model.teamID\r\n };\r\n\r\n if (this._returnService.isLocked || this._returnService.isSigned) {\r\n const unlockRequestModel: Compliance.ReturnUnlockRequestModel = {\r\n filingBatchId: this._returnService.filingBatchId,\r\n companyId: this._returnService.companyId,\r\n returnTaskUpdate: taskUpdateModel\r\n };\r\n\r\n await this._returnService.startUnlocking(unlockRequestModel);\r\n this._returnService.notifyProcessStatusChange(Compliance.FilingBatchProcessStatusEnum.Unlocking);\r\n } else {\r\n await this._returnService.rescindToTask(taskUpdateModel);\r\n }\r\n }\r\n\r\n private async _unsign(): Promise {\r\n const taskUpdateModel: Compliance.ReturnTaskUpdateModel = {\r\n taskId: this.selectedOption.taskId,\r\n comment: this.comment,\r\n assignedUserId: this.selectedUserTeam && this.selectedUserTeam.model.userID,\r\n assignedTeamId: this.selectedUserTeam && this.selectedUserTeam.model.teamID\r\n };\r\n\r\n if (this._returnService.isSigned) {\r\n const unsignRequestModel: Compliance.ReturnUnsignRequestModel = {\r\n filingBatchId: this._returnService.filingBatchId,\r\n companyId: this._returnService.companyId,\r\n returnTaskUpdate: taskUpdateModel\r\n };\r\n\r\n await this._returnService.startUnsigning(unsignRequestModel);\r\n this._returnService.notifyProcessStatusChange(Compliance.FilingBatchProcessStatusEnum.Unsigning);\r\n } else {\r\n await this._returnService.rescindToTask(taskUpdateModel);\r\n }\r\n }\r\n\r\n private async _reassign(): Promise {\r\n const taskUpdateModel: Compliance.ReturnTaskUpdateModel = {\r\n taskId: this.selectedOption.taskId,\r\n comment: this.comment,\r\n assignedUserId: this.selectedUserTeam && this.selectedUserTeam.model.userID,\r\n assignedTeamId: this.selectedUserTeam && this.selectedUserTeam.model.teamID\r\n };\r\n\r\n await this._returnService.reassignTask(taskUpdateModel);\r\n }\r\n\r\n private _filterUserTeams(filter: string): Observable {\r\n const searchModel: Compliance.ReturnTaskUserTeamSearchModel = {\r\n filter: filter,\r\n pageSize: 50,\r\n includeCompanyRepresentative: this.selectedOption && this.selectedOption.includeCompanyRepresentative\r\n };\r\n\r\n return observableFrom(lastValueFrom(this._returnRepository.getTaskUserTeams(\r\n this._returnService.filingBatchId,\r\n searchModel))).pipe(\r\n map(userTeams => {\r\n return userTeams.map(userTeam => {\r\n return new ExtendedUserTeamModel(userTeam);\r\n })\r\n }));\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const RETURN_TASK_EXCEPTION_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'return-task-exception.exception-button',\r\n tooltipText: 'Re-assign or rescind the current task.'\r\n }\r\n];\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { ReturnService } from '../.././return.service';\r\nimport { WeissmanModalService } from '../../../WeissmanModalService';\r\nimport { IMutexServiceHandler, WeissmanMutexService } from '../../../WeissmanMutexService';\r\nimport * as _ from 'lodash';\r\nimport { Subscription } from 'rxjs';\r\nimport { ReturnTaskExceptionModalComponent } from '../Return-Task-Exception-Modal/returnTaskExceptionModal.component';\r\nimport { RETURN_TASK_EXCEPTION_HELP } from './returnTaskException.component.help';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\n@Component({\r\n selector: 'return-task-exception',\r\n templateUrl: './returnTaskException.component.html'\r\n})\r\nexport class ReturnTaskExceptionComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService) { }\r\n\r\n private _tasksSub: Subscription;\r\n\r\n get exceptionButtonHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n if (this.isLongRunningProcessActive) {\r\n return 'app.disabled-busy';\r\n }\r\n\r\n return 'return-task-exception.exception-button';\r\n }\r\n\r\n get canEnterEditMode(): boolean { return this._mutexService.canAcquire(this._returnService.editGroup); }\r\n get isLongRunningProcessActive(): boolean { return this._returnService.isLongRunningProcessActive; }\r\n\r\n canEdit: boolean;\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(RETURN_TASK_EXCEPTION_HELP);\r\n\r\n this._refreshTasks();\r\n this._tasksSub = this._returnService.tasks$.subscribe(() => this._refreshTasks());\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._tasksSub && this._tasksSub.unsubscribe();\r\n }\r\n\r\n async showException(): Promise {\r\n await this._modalService.showAsync(ReturnTaskExceptionModalComponent, null, 'modal-md');\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n private _refreshTasks(): void {\r\n this.canEdit = (this._returnService.currentTask && this._returnService.currentTask.taskAuthorizationInfo.reassignTask) ||\r\n (this._returnService.priorCompletedTask && this._returnService.priorCompletedTask.taskAuthorizationInfo.rescindTask);\r\n }\r\n}\r\n","import { HelpContentComponent, HelpContentRendererValue } from '../../../UI-Lib/Help-Tooltip';\r\nimport { Component } from '@angular/core';\r\n\r\nexport interface ReturnBatchTaxYearAdditionalInfoComponentParams extends HelpContentRendererValue {\r\n lienDate: Date;\r\n cutOffDate: Date;\r\n changeDetection: string;\r\n ages: string[];\r\n}\r\n\r\n@Component({\r\n selector: 'return-batch-tax-year-additional-info',\r\n template: `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Lien Date:{{ params.lienDate | weissmanDateFormat }}
Cut Off Date:{{ params.cutOffDate | weissmanDateFormat }}
Change:{{ params.changeDetection }}
Age {{i + 1}}:{{ age }}
\r\n `,\r\n styles: ['.info-label {font-weight: bold; padding-right: 5px;}']\r\n})\r\nexport class ReturnBatchTaxYearAdditionalInfoComponent implements HelpContentComponent {\r\n params: ReturnBatchTaxYearAdditionalInfoComponentParams;\r\n\r\n helpInit(params: ReturnBatchTaxYearAdditionalInfoComponentParams): void {\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n \r\n {{ node?.totalsInfo?.returnCount | number }}\r\n {{ node?.totalsInfo?.assetCount | number }}\r\n {{ node?.totalsInfo?.cost | currency: 'USD' : 'symbol' }}\r\n \r\n
\r\n\r\n 0 && !isPageLoading) || !isInitialized\">\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n Batch #:\r\n
\r\n
{{ filingBatch?.displayId }}
\r\n
\r\n
\r\n
\r\n State:\r\n
\r\n
{{ filingBatch?.stateName }}
\r\n
\r\n
\r\n
\r\n Tax Year:\r\n
\r\n {{ filingBatch?.taxYear }}
\r\n
\r\n
\r\n
\r\n Due Date:\r\n
\r\n
{{ filingBatch?.dueDate | weissmanDateFormat: true }}
\r\n
\r\n
\r\n
\r\n\r\n
\r\n

Showing {{ selectedReturnsCount | number }} of {{ returns?.length | number }} return(s)

\r\n \r\n\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
ReturnsAssetsCost
\r\n
\r\n {{ widestListItem?.name }}\r\n
\r\n
{{ widestListItem?.totalsInfo?.returnCount | number }}{{ widestListItem?.totalsInfo?.assetCount | number }}{{ widestListItem?.totalsInfo?.cost | currency: 'USD' : 'symbol' }}
\r\n
\r\n\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n
ReturnsAssetsCost
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n Component,\r\n ElementRef,\r\n HostListener,\r\n OnDestroy,\r\n OnInit,\r\n ViewChild\r\n} from '@angular/core';\r\nimport { lastValueFrom, Subject, Subscription } from 'rxjs';\r\nimport { ReturnRepository } from '../../Repositories';\r\nimport { ReturnService } from '../return.service';\r\nimport { ReturnAssetsService } from '../Return-Parts/Assets/returnAssets.service';\r\nimport { IReturnPartComponent } from '../Models/returnPartServiceBase';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { CdkVirtualScrollViewport } from '@angular/cdk/scrolling';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { HelpContentComponentConfig } from '../../../UI-Lib/Help-Tooltip';\r\nimport { ReturnUpdateLogicService } from '../returnUpdateLogic.service';\r\nimport { ReturnBatchTaxYearAdditionalInfoComponent, ReturnBatchTaxYearAdditionalInfoComponentParams } from './returnBatchTaxYearAdditionalInfo.component';\r\n\r\ninterface TreeNode {\r\n id: number;\r\n name: string;\r\n level: number;\r\n groupSelection: GroupingType;\r\n totalsInfo: Totals;\r\n returnInfo: Compliance.ReturnTotalsModel;\r\n parent: () => TreeNode;\r\n children: TreeNode[];\r\n isChecked: boolean;\r\n isExpanded: boolean;\r\n isVisible: boolean;\r\n}\r\n\r\ninterface Totals {\r\n assetCount: number;\r\n cost: number;\r\n id: number;\r\n returnCount: number;\r\n value: any;\r\n}\r\n\r\ninterface GroupingType {\r\n returnGroupType: Compliance.ReturnGroupType;\r\n idParam: string;\r\n nameParam: string;\r\n}\r\n\r\n@Component({\r\n selector: 'return-batch',\r\n templateUrl: './returnBatch.component.html',\r\n styleUrls: ['./returnBatch.component.scss']\r\n})\r\nexport class ReturnBatchComponent implements OnInit, AfterViewInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService\r\n ) { }\r\n\r\n @ViewChild('listRow', { static: true }) listRow: ElementRef;\r\n @ViewChild(CdkVirtualScrollViewport) viewport: CdkVirtualScrollViewport;\r\n\r\n @HostListener('window:resize', ['$event'])\r\n onResize(event) {\r\n if (this.viewport) {\r\n this.viewport.checkViewportSize();\r\n }\r\n }\r\n\r\n taxYearAdditionalInfoComponent: HelpContentComponentConfig;\r\n\r\n private readonly _GROUP_SELECTION_NONE: Compliance.NameValuePair = {\r\n name: 'None',\r\n value: { returnGroupType: null, idParam: null, nameParam: 'parcelAcctNumberDisplay' }\r\n };\r\n private readonly _GROUP_SELECTION_ASSESSOR: Compliance.NameValuePair = {\r\n name: 'Assessor',\r\n value: { returnGroupType: Compliance.ReturnGroupType.Assessor, idParam: 'assessorId', nameParam: 'assessorName' }\r\n };\r\n private readonly _GROUP_SELECTION_COMPANY: Compliance.NameValuePair = {\r\n name: 'Company',\r\n value: { returnGroupType: Compliance.ReturnGroupType.Company, idParam: 'companyId', nameParam: 'companyName' }\r\n };\r\n private _assetDetailsUpdatedSub: Subscription;\r\n private _assetMappingUpdatedSub: Subscription;\r\n private _root: TreeNode;\r\n private _destroy$: Subject = new Subject();\r\n private _parcelsChangeDate: Date = null;\r\n\r\n // a number that keep track of all async requests fired when zero, it means the component is not busy and the busy indicator overlay is turned off\r\n busyCounter: number = 0;\r\n\r\n filingBatch: Compliance.FilingBatchModel;\r\n\r\n group1Option: UntypedFormControl = new UntypedFormControl(this._GROUP_SELECTION_ASSESSOR.value);\r\n selectOptionsForGroup1: Compliance.NameValuePair[] = [\r\n this._GROUP_SELECTION_ASSESSOR,\r\n this._GROUP_SELECTION_COMPANY\r\n ];\r\n\r\n group2Option: UntypedFormControl = new UntypedFormControl(this._GROUP_SELECTION_NONE.value);\r\n selectOptionsForGroup2: Compliance.NameValuePair[] = [\r\n this._GROUP_SELECTION_NONE,\r\n this._GROUP_SELECTION_COMPANY\r\n ];\r\n\r\n flatTree: TreeNode[] = [];\r\n returns: Compliance.ReturnTotalsModel[] = [];\r\n widestListItem: TreeNode;\r\n isExpanded: boolean = false;\r\n automaticRefresh: boolean = true;\r\n returnsSelectionApplied: boolean = true;\r\n selectedReturnsCount: number;\r\n isFiltered: boolean = false;\r\n returnsFilter: string = null;\r\n isPageLoading: boolean = false;\r\n isInitialized: boolean = false;\r\n batchListWidth: number = 175;\r\n\r\n ngOnInit(): void {\r\n this._returnService.start$.pipe(takeUntil(this._destroy$))\r\n .subscribe((x) => this._initialize());\r\n\r\n this._returnService.returnBatchFilter$.pipe(takeUntil(this._destroy$))\r\n .subscribe(returnIds => this._applyRemoteFilter(returnIds));\r\n\r\n this._busyIndicatorService.indicatorActive$.pipe(takeUntil(this._destroy$))\r\n .subscribe(active => this.isPageLoading = active);\r\n\r\n this._returnAssetsService.subscribeToServiceActivationCycle(this);\r\n\r\n this._returnService.parcelsChanged$.pipe(takeUntil(this._destroy$)).subscribe((x) => {\r\n if (x) {\r\n if (this._parcelsChangeDate !== x){\r\n this._parcelsChangeDate = x;\r\n this._initialize();\r\n }\r\n }\r\n });\r\n }\r\n\r\n ngAfterViewInit() {\r\n // There is a bug in the virtual scroll viewport that causes it to jump around. Moving the spacer to the top fixes it.\r\n if (this.viewport) {\r\n // @ts-ignore\r\n const scrollable = this.viewport.scrollable.elementRef.nativeElement;\r\n if (scrollable && scrollable.children) {\r\n const spacer = scrollable.children[1];\r\n if (spacer && spacer.classList.contains('cdk-virtual-scroll-spacer')) {\r\n // Move spacer as first child\r\n scrollable.insertBefore(spacer, scrollable.firstChild);\r\n } else {\r\n console.warn(\"Could not find spacer\");\r\n }\r\n } else {\r\n console.warn(\"Could not find scrollable\");\r\n }\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._returnAssetsService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n this._assetDetailsUpdatedSub = this._returnAssetsService.assetDetailsUpdated$\r\n .subscribe(() => this._updateReturnTotals());\r\n this._assetMappingUpdatedSub = this._returnAssetsService.assetMappingsUpdated$\r\n .subscribe(() => this._updateReturnTotals());\r\n\r\n if (this.viewport) {\r\n this.viewport.checkViewportSize();\r\n }\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._assetDetailsUpdatedSub && this._assetDetailsUpdatedSub.unsubscribe();\r\n this._assetMappingUpdatedSub && this._assetMappingUpdatedSub.unsubscribe();\r\n }\r\n\r\n nodeCheckChanged(node: TreeNode): void {\r\n this._applyIsCheckedStatusToTreePathDown(node);\r\n this._applyIsCheckedStatusToTreePathUp(node);\r\n // update selected returns\r\n if (this.automaticRefresh) {\r\n this._setSelectedReturns(true);\r\n } else {\r\n this.returnsSelectionApplied = false;\r\n }\r\n }\r\n\r\n // re-apply change when auto refresh turned back on\r\n onAutoRefreshChanged(checked: boolean) {\r\n if (checked) {\r\n this.refreshReturns();\r\n }\r\n }\r\n\r\n getWorkflowStatusDisplay(): string {\r\n return this._returnService.getProgressStatusDisplay();\r\n }\r\n\r\n toggleNodeIsExpanded(node: TreeNode): void {\r\n // flip isExpanded value for current node\r\n node.isExpanded = !node.isExpanded;\r\n\r\n if (node.isExpanded) {\r\n node.children.forEach(x => x.isVisible = true);\r\n }\r\n if (!node.isExpanded) {\r\n this._collapseAndHideChildren(node);\r\n }\r\n\r\n this.flatTree = this._getFlatChildren(this._root, true);\r\n if (this.viewport) {\r\n this.viewport.checkViewportSize();\r\n }\r\n }\r\n\r\n selectOptionChanged(): void {\r\n // all possible options for group 2\r\n const group2SelectOptions = [\r\n this._GROUP_SELECTION_NONE,\r\n this._GROUP_SELECTION_ASSESSOR,\r\n this._GROUP_SELECTION_COMPANY\r\n ];\r\n\r\n // remove the item that is selected in group 1\r\n group2SelectOptions.splice(group2SelectOptions.findIndex(x => x.value === this.group1Option.value), 1);\r\n\r\n // if the currently selected group 2 option is not available then set to empty\r\n if (group2SelectOptions.findIndex(x => x.value === this.group2Option.value) === -1) {\r\n this.group2Option.setValue(this._GROUP_SELECTION_NONE.value);\r\n }\r\n\r\n this.selectOptionsForGroup2 = group2SelectOptions;\r\n\r\n this._initializeTree();\r\n }\r\n\r\n refreshReturns(): void {\r\n this.returnsSelectionApplied = true;\r\n this._setSelectedReturns();\r\n }\r\n\r\n async selectAllReturns(selectPositive: boolean = true): Promise {\r\n const nodes = this._root.children;\r\n nodes.forEach(node => {\r\n node.isChecked = selectPositive;\r\n this._applyIsCheckedStatusToTreePathDown(node);\r\n });\r\n if (this.automaticRefresh) {\r\n this._setSelectedReturns(true);\r\n } else {\r\n this.returnsSelectionApplied = false;\r\n }\r\n }\r\n\r\n async filterReturns(): Promise {\r\n this.returns = await this._fetchReturnTotals();\r\n this._initializeTree();\r\n this.isFiltered = !!this.returnsFilter;\r\n }\r\n\r\n async resetReturnFilter(): Promise {\r\n this.returnsFilter = null;\r\n await this.filterReturns();\r\n }\r\n\r\n trackDataNodes(index: number, item: TreeNode): number {\r\n return item.id;\r\n }\r\n\r\n private async _initialize(): Promise {\r\n this.returns = this._returnService.returnGroupDetails;\r\n this.filingBatch = this._returnService.filingBatch;\r\n\r\n this._initializeTree();\r\n\r\n this.taxYearAdditionalInfoComponent = {\r\n component: ReturnBatchTaxYearAdditionalInfoComponent,\r\n componentParams: {\r\n lienDate: this._returnService.lienDate,\r\n cutOffDate: this._returnService.cutOffDate,\r\n changeDetection: this._returnService.changeDetection,\r\n ages: this._returnService.ages\r\n }\r\n };\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n private async _fetchReturnTotals(): Promise {\r\n this.busyCounter++;\r\n let totals = [] as Compliance.ReturnTotalsModel[];\r\n try {\r\n const returnTotals = await lastValueFrom(this._returnRepository.getReturnTotals(this._returnService.filingBatchId, this.returnsFilter));\r\n totals = returnTotals.returnTotals || [];\r\n } finally {\r\n this.busyCounter--;\r\n }\r\n return totals;\r\n }\r\n\r\n private async _updateReturnTotals(): Promise {\r\n const updatedReturns = await this._fetchReturnTotals();\r\n const returnTotalsMap = updatedReturns.reduce((acc, x) => {\r\n const total = (acc.has(x.assessorId))\r\n ? acc.get(x.assessorId)\r\n : { assetCount: 0, cost: 0, id: null, returnCount: 0, value: null };\r\n total.assetCount += x.reportedAssetCount;\r\n total.cost += x.reportedCost;\r\n total.returnCount += 1;\r\n acc.set(x.assessorId, total);\r\n return acc;\r\n }, new Map());\r\n this.flatTree.forEach(x => {\r\n if (x.groupSelection === this._GROUP_SELECTION_ASSESSOR.value) {\r\n x.totalsInfo = returnTotalsMap.get(x.id);\r\n }\r\n });\r\n this._setSelectedReturns();\r\n }\r\n\r\n private _initializeTree(): void {\r\n this._root = {\r\n level: 0,\r\n isChecked: false,\r\n isExpanded: false\r\n } as TreeNode;\r\n\r\n const levels = [this.group1Option.value, this.group2Option.value];\r\n if (this.group2Option.value !== this._GROUP_SELECTION_NONE) {\r\n levels.push(this._GROUP_SELECTION_NONE.value);\r\n }\r\n\r\n this._root.children = this._getChildren(this._root, levels);\r\n\r\n this.flatTree = this._getFlatChildren(this._root, true);\r\n\r\n // automatically select all items\r\n this._root.isChecked = true;\r\n this._applyIsCheckedStatusToTreePath(this._root);\r\n\r\n // expand root node\r\n this.toggleNodeIsExpanded(this._root);\r\n }\r\n\r\n /**\r\n * This is in a recursive call where we know all the returns are loaded ahead of time\r\n * and the return information is being used to populate the tree nodes.\r\n * As we keep traversing down the tree, going multiple levels deep, in the following manner:\r\n * (0) root > (1) get root children > (2) for each root child get its children > (3) ...\r\n * we must make sure that when querying the existing \"returns\" for a specific level.\r\n * The returns that we are looking at are filtered by the node values in the path that we're traversing, ie:\r\n * Imagine the following path: company > assessor > parcel\r\n * We query the returns and find two companies, \"company_1\" and \"company_2\".\r\n * Now, next step, for \"company_1\" we have to find all assessor, again, we query the returns (data already loaded there)\r\n * however, we must first filter them down by only returns that match \"company_1\" (as that is the path being traversed).\r\n *\r\n * While this filter path can be calculated as each node has a reference to its parent. For speed purposes, it is being passed as a parameter.\r\n * The filters path is an array of object, each object has got a key that matches the selected option and a value which is the Id of the selected option.\r\n * For the example above, if we made it all the way down to the parcel by going \"company_1\" > \"assessor_1\" > ...\r\n * The filters, when getting the children for \"assessor_1\" would be (in Tuple fashion)\r\n * [ ['company',1], ['assessor',1] ]\r\n */\r\n private _getChildren(node: TreeNode, levels: GroupingType[], filtersForPathToNode: [string, number][] = []): TreeNode[] {\r\n const children: TreeNode[] = [];\r\n\r\n // filter the returns based on the collection of filters for the path that we are traversing\r\n const filteredReturns = this.returns.filter(x => {\r\n let matchesFiltersForPathToNode: boolean = true;\r\n for (let i = 0; i < filtersForPathToNode.length && matchesFiltersForPathToNode; i++) {\r\n matchesFiltersForPathToNode = x[filtersForPathToNode[i][0]] === filtersForPathToNode[i][1];\r\n }\r\n return matchesFiltersForPathToNode;\r\n });\r\n\r\n // building the children for the specified node\r\n const selectedOption = levels[node.level] || this._GROUP_SELECTION_NONE.value;\r\n const treeNodesForReturns = filteredReturns.map(x => {\r\n let totals = null;\r\n if (selectedOption && selectedOption.returnGroupType === Compliance.ReturnGroupType.Assessor) {\r\n totals = this.returns.reduce((acc, y) => {\r\n if (y.assessorId === x.assessorId) {\r\n acc.assetCount += y.reportedAssetCount;\r\n acc.cost += y.reportedCost;\r\n acc.returnCount += 1;\r\n }\r\n return acc;\r\n },\r\n { assetCount: 0, cost: 0, id: null, returnCount: 0, value: null });\r\n }\r\n\r\n const newNode = {\r\n id: selectedOption && selectedOption.idParam && x[selectedOption.idParam],\r\n name: selectedOption && selectedOption.nameParam && x[selectedOption.nameParam],\r\n level: node.level + 1,\r\n groupSelection: selectedOption,\r\n totalsInfo: totals,\r\n returnInfo: (!selectedOption || selectedOption.returnGroupType === null) && x,\r\n parent: () => node,\r\n children: [],\r\n isVisible: node.level === 0,\r\n isExpanded: false,\r\n isChecked: false\r\n };\r\n\r\n if (!this.widestListItem || (newNode.name && newNode.name.length > this.widestListItem.name.length)) {\r\n this.widestListItem = newNode;\r\n }\r\n\r\n return newNode;\r\n });\r\n // add returns to children array (they are filtered so add them all as they all match the filter path)\r\n if (!selectedOption || selectedOption.returnGroupType === null) {\r\n children.push(...treeNodesForReturns);\r\n } else {\r\n treeNodesForReturns.forEach(x => (children.findIndex(y => y.id === x.id) === -1) && children.push(x));\r\n }\r\n\r\n // for each child record, set it's own children collection; add to the path filters object the values for the current node\r\n // make sure to skip \"last level\" (return) records -- for those there will be no group selection\r\n children\r\n .sort((a, b) => (a.name.localeCompare(b.name, undefined, { numeric: true })))\r\n .filter(x => x.groupSelection && x.id)\r\n .forEach(x => {\r\n const filter = filtersForPathToNode.slice();\r\n filter.push([x.groupSelection.idParam, x.id]);\r\n x.children = this._getChildren(x, levels, filter);\r\n });\r\n\r\n return children;\r\n }\r\n\r\n private _getFlatChildren(node: TreeNode, onlyVisible: boolean): TreeNode[] {\r\n const flatTree: TreeNode[] = [];\r\n node.children.forEach(x => {\r\n if (onlyVisible) {\r\n if (x.isVisible) {\r\n flatTree.push(x, ...this._getFlatChildren(x, onlyVisible));\r\n }\r\n }\r\n else { flatTree.push(x, ...this._getFlatChildren(x, onlyVisible)); }\r\n });\r\n return flatTree;\r\n }\r\n\r\n private _getSelectedChildren(node: TreeNode): TreeNode[] {\r\n const checkedNodes: TreeNode[] = [];\r\n if (node && Array.isArray(node.children)) {\r\n node.children.forEach(x => {\r\n // if a node is checked and has return info (only want the deepest nodes; skipping other level nodes)\r\n x.isChecked && x.returnInfo && checkedNodes.push(x);\r\n checkedNodes.push(...this._getSelectedChildren(x));\r\n });\r\n }\r\n return checkedNodes;\r\n }\r\n\r\n private async _setSelectedReturns(fromFilterChange: boolean = false): Promise {\r\n const selectedNodes = this._getSelectedChildren(this._root);\r\n const selectedReturns = selectedNodes.map(x => x.returnInfo);\r\n this.selectedReturnsCount = selectedReturns.length;\r\n if (fromFilterChange) {\r\n this._returnUpdateLogicService.startLoading();\r\n await this._returnService.setReturnFilterChanged(selectedReturns);\r\n await this._returnUpdateLogicService.parcelFilterChanged();\r\n } else {\r\n this._returnService.setReturns(selectedReturns);\r\n }\r\n }\r\n\r\n private _applyIsCheckedStatusToTreePath(node: TreeNode): void {\r\n this._applyIsCheckedStatusToTreePathDown(node);\r\n this._applyIsCheckedStatusToTreePathUp(node);\r\n // update selected returns\r\n if (this.automaticRefresh) {\r\n this._setSelectedReturns();\r\n } else {\r\n this.returnsSelectionApplied = false;\r\n }\r\n }\r\n\r\n // using in the recursion but don't set the returns\r\n private _applyIsCheckedStatusToTreePathUp(node: TreeNode): void {\r\n if (node.parent) {\r\n const parent = node.parent();\r\n const checkedNodeCount = parent.children.reduce((acc: number, x) => (x.isChecked) ? (acc += 1) : acc, 0);\r\n const indeterminateNodeCount = parent.children.reduce((acc: number, x) => (x.isChecked === null) ? (acc += 1) : acc, 0);\r\n if (checkedNodeCount === 0 && !indeterminateNodeCount) {\r\n parent.isChecked = false;\r\n } else if (checkedNodeCount === parent.children.length) {\r\n parent.isChecked = true;\r\n } else {\r\n parent.isChecked = null;\r\n }\r\n this._applyIsCheckedStatusToTreePathUp(parent);\r\n }\r\n }\r\n\r\n // using in the recursion but don't set the returns\r\n private _applyIsCheckedStatusToTreePathDown(node: TreeNode): void {\r\n node.children.forEach(x => {\r\n x.isChecked = node.isChecked;\r\n this._applyIsCheckedStatusToTreePathDown(x);\r\n });\r\n }\r\n\r\n private _collapseAndHideChildren(node: TreeNode): void {\r\n node.children.forEach(x => {\r\n x.isExpanded = false;\r\n x.isVisible = false;\r\n this._collapseAndHideChildren(x);\r\n });\r\n }\r\n\r\n // apply a filter supplied by the return service\r\n private _applyRemoteFilter(returnIds: number[]): void {\r\n const nodes = this._root.children;\r\n nodes.forEach(node => {\r\n node.isChecked = false;\r\n this._applyIsCheckedStatusToTreePathDown(node);\r\n });\r\n nodes.forEach(n => this._collapseAndHideChildren(n));\r\n const flatNodes = nodes.reduce((acc, x) => [...acc, ...this._getFlatChildren(x, false)], []);\r\n returnIds.forEach(id => {\r\n const node: TreeNode = flatNodes.find(n => (n.returnInfo && n.returnInfo.returnId) ? n.returnInfo.returnId === id : false);\r\n if (node) {\r\n if (node.parent && !node.parent().isExpanded) {\r\n this._toggleNodeIsExpandedUp(node.parent());\r\n }\r\n node.isChecked = true;\r\n this._applyIsCheckedStatusToTreePath(node);\r\n }\r\n });\r\n }\r\n\r\n private _toggleNodeIsExpandedUp(node: TreeNode, toggleState?: boolean): void {\r\n if (node.parent) {\r\n this._toggleNodeIsExpandedUp(node.parent(), (toggleState) ? toggleState : !node.isExpanded);\r\n if (!toggleState) {\r\n this.toggleNodeIsExpanded(node);\r\n } else {\r\n node.isExpanded = !node.isExpanded;\r\n node.children.forEach(x => x.isVisible = toggleState);\r\n }\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\n@Component({\r\n selector: 'return-comparison-modal',\r\n template: `\r\n \r\n Are you sure you wish to reset returns using non-default forms?\r\n \r\n `\r\n})\r\nexport class ReturnCompareConfirmationModalComponent implements IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef) { }\r\n\r\n params: void;\r\n result: boolean;\r\n \r\n /**\r\n * Submit the reset request\r\n * */\r\n submitReset() {\r\n this.result = true;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n /**\r\n * Cancel the modal\r\n * */\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\n
\r\n
\r\n If you reset to default, the following changes will be applied:\r\n
\r\n
\r\n
\r\n {{ customReturn.parcelAcctNum }}:\r\n
\r\n
    \r\n
  • \r\n
    \r\n \r\n \r\n \r\n \r\n {{ customForm.name }}\r\n \r\n
    \r\n
    \r\n
      \r\n
    • \r\n \r\n \r\n \r\n {{ customReport.name + ' ' + customForm.name }}\r\n \r\n
    • \r\n
    \r\n
    \r\n
  • \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Output, EventEmitter, OnInit, OnDestroy } from '@angular/core';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { ReturnCompareConfirmationModalComponent } from './returnCompareConfirmationModal.component';\r\nimport { ReturnService } from '../return.service';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'return-compare-message',\r\n styleUrls: ['./returnCompareMessage.component.scss'],\r\n templateUrl: './returnCompareMessage.component.html'\r\n})\r\nexport class ReturnCompareMessageComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _returnService: ReturnService) {}\r\n\r\n @Output() reset: EventEmitter = new EventEmitter();\r\n\r\n customReturns: Compliance.ReturnCustomReturnModel[] = [];\r\n isDefault: boolean = true;\r\n confirmation: boolean = false;\r\n showMessageDetails: boolean = false;\r\n isReadOnlyMode: boolean;\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._setComparisonValue(this._returnService.compareFormsResult);\r\n this.isReadOnlyMode = this._returnService.isReturnInReadOnly;\r\n\r\n this._returnService.isReturnInReadOnlyMode$.pipe(takeUntil(this.destroy$))\r\n .subscribe((isReadOnly: boolean) => this.isReadOnlyMode = isReadOnly);\r\n\r\n this._returnService.compareForms$.pipe(takeUntil(this.destroy$))\r\n .subscribe((comparison: Compliance.ReturnCompareFormsResultModel) => {\r\n if(comparison) {\r\n this._setComparisonValue(comparison);\r\n }\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n /**\r\n * Toggle the reports list open and closed\r\n * @param form\r\n */\r\n toggleReports(form: Compliance.ReturnCustomFormModel): void {\r\n form['showReports'] = (form['showReports']) ? false : true;\r\n }\r\n\r\n /**\r\n * Toggle the confirmation panel\r\n */\r\n async showConfirmation(): Promise {\r\n const result = await this._modalService.showAsync(ReturnCompareConfirmationModalComponent, null, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.reset.emit();\r\n this.showMessageDetails = false;\r\n }\r\n\r\n /**\r\n * Display the correct icon\r\n * @param val\r\n */\r\n getIconClass(val: number): string {\r\n switch (val) {\r\n case Compliance.ReturnCompareActionEnum.None:\r\n return 'fa-ban';\r\n case Compliance.ReturnCompareActionEnum.Remove:\r\n return 'fa-trash';\r\n case Compliance.ReturnCompareActionEnum.Add:\r\n return 'fa-plus';\r\n }\r\n }\r\n\r\n /**\r\n * Display a tooltip\r\n * @param val\r\n */\r\n getIconTitle(val: number): string {\r\n switch (val) {\r\n case Compliance.ReturnCompareActionEnum.None:\r\n return 'No change';\r\n case Compliance.ReturnCompareActionEnum.Remove:\r\n return 'Remove from the return';\r\n case Compliance.ReturnCompareActionEnum.Add:\r\n return 'Add to the return';\r\n }\r\n }\r\n\r\n /**\r\n * Trackby to help with nested loops\r\n * @param index\r\n * @param item\r\n */\r\n trackByReturnId(index: number,\r\n item: Compliance.ReturnCustomReturnModel | Compliance.ReturnCustomFormModel | Compliance.ReturnCustomReportModel): number {\r\n return item.returnId;\r\n }\r\n\r\n private _setComparisonValue(compareResult: Compliance.ReturnCompareFormsResultModel): void {\r\n if (compareResult) {\r\n this.isDefault = compareResult.isDefault;\r\n this.customReturns = compareResult.customReturns;\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable, BehaviorSubject, Subject, lastValueFrom } from 'rxjs';\r\nimport { ReturnFormRepository, ReturnFormRevisionReportRepository, ReturnReportRepository } from '../../../Repositories';\r\nimport { ReturnService } from '../../return.service';\r\nimport { ReturnPartServiceBase } from '../../Models/returnPartServiceBase';\r\nimport { TaskTypes } from '../../Models/enums';\r\nimport * as _ from 'lodash';\r\nimport { ReturnPreviewFormOverrideListResult } from './Form-Overrides-List/returnPreviewFormOverrideList.component';\r\nimport { FieldOverride, FieldOverrideHolder } from '../../../../Common/PDFViewer/pdfViewerBase';\r\n\r\nexport interface ReturnFormModel {\r\n mergeParcelId: number;\r\n returnId: number;\r\n returnFormRevisionId: number;\r\n returnFormRevisionReportId: number;\r\n formRevisionId: number;\r\n reportId: number; // saved search ID\r\n isExcel: boolean;\r\n}\r\n\r\nexport interface ReturnPreviewServiceSharedState {\r\n returnForm: ReturnFormModel;\r\n navigateToOverride: Compliance.ReturnFormOverrideDetailModel;\r\n}\r\n\r\nexport interface FieldOverrideWithRowVersion extends FieldOverride {\r\n rowVersion: number[];\r\n}\r\n\r\nexport interface FormChanges {\r\n formRevisionId: number;\r\n returnMergedParcelIds: Compliance.ReturnMergedParcelIdModel[];\r\n overrides: FieldOverrideWithRowVersion[];\r\n}\r\n\r\nclass HTTPStatusError extends Error {\r\n constructor(statusCode: number, message: string, ...params) {\r\n super(...params);\r\n\r\n // V8 only so cast as any\r\n if ((Error as any).captureStackTrace) {\r\n (Error as any).captureStackTrace(this, HTTPStatusError);\r\n }\r\n\r\n this.status = statusCode;\r\n this.message = message;\r\n }\r\n\r\n status: number;\r\n message: string;\r\n}\r\n\r\n@Injectable()\r\nexport class ReturnPreviewService extends ReturnPartServiceBase {\r\n constructor(\r\n private readonly _returnFormRepository: ReturnFormRepository,\r\n private readonly _returnFormRevisionReportRepository: ReturnFormRevisionReportRepository,\r\n private readonly _returnReportRepository: ReturnReportRepository,\r\n private readonly _returnService: ReturnService\r\n ) { super(); }\r\n\r\n private _sharedState: ReturnPreviewServiceSharedState = {\r\n returnForm: null\r\n } as ReturnPreviewServiceSharedState;\r\n\r\n private _formOverridesSubject: BehaviorSubject = new BehaviorSubject([]);\r\n private _returnFormSubject: BehaviorSubject = new BehaviorSubject(this._sharedState.returnForm);\r\n private _openPreviewByOverrideSubject: Subject = new Subject();\r\n private _returnFormOverrideListSubject: Subject = new Subject();\r\n private _fieldOverrideHolder: FieldOverrideHolder;\r\n\r\n set fieldOverrideHolder(fieldOverrideHolder: FieldOverrideHolder) {\r\n this._fieldOverrideHolder = fieldOverrideHolder;\r\n }\r\n\r\n get fieldOverrideHolder(): FieldOverrideHolder { return this._fieldOverrideHolder; }\r\n get sharedState(): ReturnPreviewServiceSharedState { return this._sharedState; }\r\n get returnForm$(): Observable { return this._returnFormSubject.asObservable(); }\r\n get formOverrides$(): Observable { return this._formOverridesSubject.asObservable(); }\r\n get returnFormOverrideList$(): Observable { return this._returnFormOverrideListSubject.asObservable(); }\r\n get openPreviewByOverrides$(): Observable { return this._openPreviewByOverrideSubject.asObservable(); }\r\n\r\n initialize(): void {\r\n this._sharedState = {\r\n returnForm: null,\r\n navigateToOverride: null\r\n };\r\n }\r\n\r\n notifyServiceActivationChange(isActive: boolean, state?: ReturnPreviewServiceSharedState): void {\r\n if (state) {\r\n this._sharedState = _.cloneDeep(state);\r\n }\r\n super.notifyServiceActivationChange(isActive);\r\n }\r\n\r\n notifyReturnFormOverrideListChanged(result: ReturnPreviewFormOverrideListResult) {\r\n this._returnFormOverrideListSubject.next(result);\r\n }\r\n\r\n setReturnForm(returnForm: ReturnFormModel, navigateToOverride: Compliance.ReturnFormOverrideDetailModel = null): void {\r\n this._sharedState.returnForm = returnForm;\r\n this._sharedState.navigateToOverride = navigateToOverride;\r\n this._returnFormSubject.next(this._sharedState.returnForm);\r\n }\r\n\r\n openPreviewByOverrides(overrideModel: Compliance.ReturnFormOverrideDetailModel) {\r\n this._openPreviewByOverrideSubject.next(overrideModel);\r\n }\r\n\r\n async getFormData(forceGetFieldData: boolean): Promise {\r\n const request: Compliance.ReturnFormRequestModel = {\r\n mergeParcelId: this._returnService.isConsolidatedReturn ? this.sharedState.returnForm.mergeParcelId : null,\r\n returnId: this.sharedState.returnForm.returnId,\r\n formRevisionId: this.sharedState.returnForm.formRevisionId,\r\n reportOptions: null,\r\n requestType: Compliance.ReturnFormRequestTypeEnum.FieldData,\r\n flattenFields: false,\r\n forceGetFieldData: this._getFieldDataType(forceGetFieldData)\r\n };\r\n\r\n return await lastValueFrom(this._returnFormRepository.getFormData(this._returnService.filingBatchId, request));\r\n }\r\n\r\n async getFormTemplateAndData(forceGetFieldData: boolean): Promise<{ form: Blob, data: Compliance.ReturnFormResultModel }> {\r\n const request: Compliance.ReturnFormRequestModel = {\r\n mergeParcelId: this._returnService.isConsolidatedReturn ? this.sharedState.returnForm.mergeParcelId : null,\r\n returnId: this.sharedState.returnForm.returnId,\r\n formRevisionId: this.sharedState.returnForm.formRevisionId,\r\n reportOptions: null,\r\n requestType: (this.isFormInReviewMode()) ? Compliance.ReturnFormRequestTypeEnum.FieldData : Compliance.ReturnFormRequestTypeEnum.TemplateAndOverflowReports,\r\n flattenFields: false,\r\n forceGetFieldData: this._getFieldDataType(forceGetFieldData)\r\n };\r\n\r\n return await lastValueFrom(this._returnFormRepository.getFormAndData(this._returnService.filingBatchId, request));\r\n }\r\n\r\n async getReturnFormReport(returnId: number, formRevisionId: number, reportId: number): Promise {\r\n try {\r\n const request: Compliance.ReturnReportRequestModel = {\r\n returnId: returnId,\r\n formRevisionId: formRevisionId,\r\n reportId: reportId\r\n };\r\n\r\n const response = await lastValueFrom(this._returnReportRepository.getReport(this._returnService.filingBatchId, request));\r\n return response.body;\r\n }\r\n catch (e) {\r\n throw new HTTPStatusError(e.status, e.error.message);\r\n }\r\n }\r\n\r\n isFormDataNeededOnPdf(): boolean {\r\n const status: Compliance.FilingBatchProcessStatusEnum = this._returnService.processStatus;\r\n const liveDataStatuses = [\r\n Compliance.FilingBatchProcessStatusEnum.NotStarted,\r\n Compliance.FilingBatchProcessStatusEnum.Started,\r\n Compliance.FilingBatchProcessStatusEnum.Locking\r\n ];\r\n\r\n return liveDataStatuses.includes(status) || this.isFormInReviewMode();\r\n }\r\n\r\n isFormInReviewMode(): boolean {\r\n const taskStatus: Core.TaskModel = this._returnService.currentTask;\r\n return (taskStatus && taskStatus.taskTypeID === TaskTypes.PPBatchReturnReviewReturns);\r\n }\r\n\r\n async updateFormFieldOverrides({formRevisionId, overrides, returnMergedParcelIds}: FormChanges): Promise {\r\n const update: Compliance.ReturnFormOverridesRequestModel = {\r\n formRevisionId,\r\n overrides: overrides.map(({fieldName, overrideValue, rowVersion}: FieldOverrideWithRowVersion) => ({ fieldName, value: overrideValue, rowVersion })),\r\n returnMergedParcelIds\r\n }\r\n const result = await lastValueFrom(this._returnFormRepository.updateFormFieldOverrides(this._returnService.filingBatchId, update));\r\n await this.loadFormOverrides();\r\n return result;\r\n }\r\n\r\n async deleteFormFieldOverrides(formOverrideRequestModel: Compliance.ReturnFormOverrideRequestModel): Promise {\r\n await lastValueFrom(this._returnFormRepository.deleteFormFieldOverrides(this._returnService.filingBatchId, formOverrideRequestModel));\r\n await this.loadFormOverrides();\r\n }\r\n\r\n async getFormFieldOverrides(formRevisionId, paginationModel: Core.PaginationModel, sortModel: Core.SortModel[], returnIds: number[]): Promise> {\r\n const searchModel: Compliance.ReturnFormOverrideSearchModel = {\r\n formRevisionId: formRevisionId,\r\n returnIds: returnIds,\r\n pagination: paginationModel,\r\n sortColumns: sortModel\r\n }\r\n\r\n return await lastValueFrom(this._returnFormRepository.getFormFieldOverrides(this._returnService.filingBatchId, searchModel));\r\n }\r\n\r\n async loadFormOverrides(): Promise {\r\n const overrides: Compliance.ReturnFormRevisionModel[] = await lastValueFrom(this._returnFormRepository.getFormOverrides(this._returnService.filingBatchId));\r\n\r\n this._formOverridesSubject.next(overrides);\r\n }\r\n\r\n getAssociatedReportsForReturns(): Observable {\r\n const returnIds = _.map(_.filter(this._returnService.sharedState.returns, x => !!x.returnId), x => x.returnId);\r\n return this._returnFormRevisionReportRepository.getAssociatedWithReturns(this._returnService.filingBatchId, returnIds);\r\n }\r\n\r\n getNotAssociatedReportsForReturns(): Observable {\r\n const returnIds = _.map(_.filter(this._returnService.sharedState.returns, x => !!x.returnId), x => x.returnId);\r\n return this._returnFormRevisionReportRepository.getNotAssociatedWithReturns(this._returnService.filingBatchId, returnIds);\r\n }\r\n\r\n async startDownloadForm(returnId: number, formRevisionId: number, mergeParcelId: number): Promise {\r\n const request: Compliance.ReturnFormRequestModel = {\r\n mergeParcelId: mergeParcelId,\r\n returnId: returnId,\r\n formRevisionId: formRevisionId,\r\n reportOptions: null,\r\n requestType: Compliance.ReturnFormRequestTypeEnum.FormAndOverflowReports,\r\n flattenFields: this._returnService.isReturnInReadOnlyMode,\r\n forceGetFieldData: this._getFieldDataType(false)\r\n };\r\n\r\n return await lastValueFrom(this._returnFormRepository.startDownloadForm(this._returnService.filingBatchId, request));\r\n }\r\n\r\n async startDownloadReport(returnId: number, formRevisionId: number, reportId: number): Promise {\r\n const request: Compliance.ReturnReportRequestModel = {\r\n returnId: returnId,\r\n formRevisionId: formRevisionId,\r\n reportId: reportId\r\n };\r\n\r\n return await lastValueFrom(this._returnReportRepository.startDownloadReport(this._returnService.filingBatchId, request));\r\n }\r\n\r\n private _getFieldDataType(force: boolean): Compliance.ReturnFormRequestDataTypeEnum {\r\n if (force) {\r\n return Compliance.ReturnFormRequestDataTypeEnum.FieldData;\r\n } else if (this.isFormInReviewMode()) {\r\n return Compliance.ReturnFormRequestDataTypeEnum.Overrides;\r\n } else {\r\n return Compliance.ReturnFormRequestDataTypeEnum.None;\r\n }\r\n }\r\n}\r\n","\r\n\r\n\r\n
\r\n
Apply changes to:
\r\n
\r\n \r\n
\r\n
\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n {{ item.formRevisionDisplayName }}{{ getMessage(item) }}
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { ReturnFormRevisionAssociation } from '../../../Models/returnFormRevisionAssociation';\r\nimport * as _ from 'lodash';\r\nimport { IWeissmanModalComponent } from '../../../../WeissmanModalService';\r\nimport { ProductAnalyticsService } from '../../../../../Common/Amplitude/productAnalytics.service';\r\nimport { ReturnUpdateLogicService } from '../../../returnUpdateLogic.service';\r\n\r\nexport interface ReturnPreviewFormAssociationsParams {\r\n returnId?: number;\r\n parcelId?: number;\r\n}\r\n\r\n@Component({\r\n selector: 'return-preview-form-associations',\r\n templateUrl: './returnPreviewFormAssociations.component.html'\r\n})\r\nexport class ReturnPreviewFormAssociationsComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n private readonly _APPLY_CHANGES_SCOPE_OPTION_ALL_SELECTED_RETURNS: Compliance.NameValuePair = {\r\n name: 'all-selected-returns',\r\n value: 'All selected returns'\r\n };\r\n\r\n private readonly _APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN: Compliance.NameValuePair = {\r\n name: 'selected-return',\r\n value: null\r\n };\r\n\r\n params: ReturnPreviewFormAssociationsParams;\r\n result: boolean;\r\n\r\n isBusy: boolean = false;\r\n applyChangesScopeOptions: Compliance.NameValuePair[] = [];\r\n selectedApplyChangesScopeOption: Compliance.NameValuePair;\r\n formRevisionAssociations: ReturnFormRevisionAssociation[] = [];\r\n hasChanges: boolean = false;\r\n\r\n ngOnInit(): void {\r\n // determine if we are applying changes to multiple returns or a single one\r\n this.applyChangesScopeOptions.push(this._APPLY_CHANGES_SCOPE_OPTION_ALL_SELECTED_RETURNS);\r\n\r\n if (this.params && this.params.returnId && this.params.parcelId) {\r\n const selectedReturn = this._returnService.sharedState.returns.find(x => x.returnId === this.params.returnId && x.parcelId === this.params.parcelId);\r\n if (selectedReturn) {\r\n this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN.value = selectedReturn.parcelAcctNumberDisplay;\r\n this.applyChangesScopeOptions.push(this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN);\r\n }\r\n }\r\n\r\n this.selectedApplyChangesScopeOption = this.applyChangesScopeOptions.indexOf(this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN) === -1 ?\r\n this.applyChangesScopeOptions[this.applyChangesScopeOptions.indexOf(this._APPLY_CHANGES_SCOPE_OPTION_ALL_SELECTED_RETURNS)] :\r\n this.applyChangesScopeOptions[this.applyChangesScopeOptions.indexOf(this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN)];\r\n\r\n this._refreshReturnFormRevisions();\r\n }\r\n\r\n onSelectedApplyChangesScopeFilterChange(): void {\r\n this._refreshReturnFormRevisions();\r\n }\r\n\r\n onFormSelectedChange(form: ReturnFormRevisionAssociation): void {\r\n form.isSelected = !form.isSelected;\r\n form.hasChanges = this.selectedApplyChangesScopeOption === this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN\r\n ? form.isSelected !== form.isSelectedInitial\r\n : (form.isSelected && form.totalReturnsAvailableToUse !== 0) || !form.isSelected;\r\n\r\n this.hasChanges = !!this.formRevisionAssociations.find(x => x.hasChanges);\r\n }\r\n\r\n async save(): Promise {\r\n // create the collection of return form revision that will be Created or Removed\r\n const createOrUpdateReturnFormRevisions: Compliance.ReturnFormRevisionModel[] = [];\r\n\r\n let returnIds = this._returnService.sharedState.returns\r\n .reduce((acc, x) => (acc.includes(x.returnId)) ? acc : [...acc, x.returnId], []);\r\n let inUseReturnFormRevisions = this._returnService.getAssociatedReturnFormRevisions();\r\n let canUseReturnFormRevisions = this._returnService.getNotAssociatedReturnFormRevisions();\r\n\r\n if (this.selectedApplyChangesScopeOption === this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN) {\r\n returnIds = returnIds.filter(x => x === this.params.returnId);\r\n inUseReturnFormRevisions = inUseReturnFormRevisions.filter(x => x.returnId === this.params.returnId);\r\n canUseReturnFormRevisions = canUseReturnFormRevisions.filter(x => x.returnId === this.params.returnId);\r\n }\r\n\r\n this.formRevisionAssociations.forEach(formRevisionAssociation => {\r\n if (formRevisionAssociation.isSelected) {\r\n returnIds.forEach(returnId => {\r\n // if currently in use then do nothing\r\n const currentlyInUse = inUseReturnFormRevisions.filter(x => x.returnId === returnId && x.formRevisionId === formRevisionAssociation.formRevisionId).length > 0;\r\n if (currentlyInUse) {\r\n return;\r\n }\r\n\r\n // find all return form revisions that can be used and add them to the list (for addition)\r\n canUseReturnFormRevisions\r\n .filter(x => x.returnId === returnId && x.formRevisionId === formRevisionAssociation.formRevisionId)\r\n .forEach(() => {\r\n const rfr: Compliance.ReturnFormRevisionModel = {\r\n returnFormRevisionId: 0, // leave as zero so for API to add association\r\n returnId: returnId,\r\n formRevisionId: formRevisionAssociation.formRevisionId,\r\n formRevisionName: null\r\n } as Compliance.ReturnFormRevisionModel;\r\n createOrUpdateReturnFormRevisions.push(rfr);\r\n });\r\n });\r\n }\r\n\r\n if (!formRevisionAssociation.isSelected) {\r\n returnIds.forEach(returnId => {\r\n // if currently not in use (is available to add) the do nothing\r\n const currentlyNotInUse = canUseReturnFormRevisions.filter(x => x.returnId === returnId && x.formRevisionId === formRevisionAssociation.formRevisionId).length > 0;\r\n if (currentlyNotInUse) {\r\n return;\r\n }\r\n\r\n // find all return form revisions that are currently in use and add them to the list (for removal)\r\n inUseReturnFormRevisions\r\n .filter(x => x.returnId === returnId && x.formRevisionId === formRevisionAssociation.formRevisionId)\r\n .forEach(x => createOrUpdateReturnFormRevisions.push(x));\r\n });\r\n }\r\n });\r\n\r\n this.isBusy = true;\r\n\r\n if (!createOrUpdateReturnFormRevisions.length) {\r\n this._bsModalRef.hide();\r\n } else {\r\n try {\r\n await this._returnService.associateOrDisassociateReturnFormRevisions(createOrUpdateReturnFormRevisions);\r\n await this._returnUpdateLogicService.refreshReturnFormRevisions();\r\n this.result = true;\r\n this._bsModalRef.hide();\r\n } finally {\r\n this._productAnalyticsService.logEvent('click-edit-forms-ok', {\r\n updateReturnForms: this.selectedApplyChangesScopeOption === this._APPLY_CHANGES_SCOPE_OPTION_ALL_SELECTED_RETURNS ? 'all returns' : 'specific return'\r\n });\r\n this.isBusy = false;\r\n }\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n disableSave(): boolean{\r\n return !this.hasChanges || this.hasOrphanedSupplementalForms();\r\n }\r\n\r\n hasOrphanedSupplementalForms(): boolean{\r\n const items = this.formRevisionAssociations.filter(x => x.isSelected);\r\n const parentIds = items.map(x => x.parentFormRevisionId).filter(x => x);\r\n const itemIds = items.map(x => x.formRevisionId);\r\n return !parentIds.every( x => itemIds.includes(x));\r\n }\r\n\r\n getMessage(form: ReturnFormRevisionAssociation): string {\r\n let message: string;\r\n\r\n if (this.selectedApplyChangesScopeOption === this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN) {\r\n if (form.isSelected) {\r\n message = form.hasChanges\r\n ? `Adding to ${this.selectedApplyChangesScopeOption.value}`\r\n : `No changes. (added to ${this.selectedApplyChangesScopeOption.value})`;\r\n } else {\r\n message = form.hasChanges\r\n ? `Removing from ${this.selectedApplyChangesScopeOption.value}`\r\n : `No changes. (not added to ${this.selectedApplyChangesScopeOption.value})`;\r\n }\r\n } else {\r\n if (form.isSelected) {\r\n message = form.hasChanges\r\n ? `Adding to ${form.totalReturnsAvailableToUse} of ${form.totalReturns} selected returns`\r\n : `No changes. (added to ${form.totalReturns - form.totalReturnsAvailableToUse} of ${form.totalReturns} selected returns)`;\r\n } else {\r\n message = form.hasChanges\r\n ? `Removing from ${form.totalReturns - form.totalReturnsAvailableToUse} of ${form.totalReturns} selected returns`\r\n : `No changes. (added to ${form.totalReturns - form.totalReturnsAvailableToUse} of ${form.totalReturns} selected returns)`;\r\n }\r\n }\r\n\r\n return message;\r\n }\r\n\r\n getReturnFormRevisionDisplayName(returnFormRevision: Compliance.ReturnFormRevisionModel): string {\r\n return this._returnService.getReturnFormRevisionDisplayName(returnFormRevision);\r\n }\r\n\r\n private _refreshReturnFormRevisions(): void {\r\n const selectedReturnIds = this._returnService.sharedState.returns\r\n .reduce((acc, x) => (acc.includes(x.returnId)) ? acc : [...acc, x.returnId], []);\r\n\r\n let inUseReturnFormRevisions = this._returnService.getAssociatedReturnFormRevisions();\r\n let canUseReturnFormRevisions = this._returnService.getNotAssociatedReturnFormRevisions();\r\n\r\n if (this.selectedApplyChangesScopeOption === this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN) {\r\n inUseReturnFormRevisions = inUseReturnFormRevisions.filter(x => x.returnId === this.params.returnId);\r\n canUseReturnFormRevisions = canUseReturnFormRevisions.filter(x => x.returnId === this.params.returnId);\r\n }\r\n\r\n this.formRevisionAssociations = [];\r\n\r\n // take all return form revisions (available and not available)\r\n // group by the form revision ID as we need to separate at the form revision ID level\r\n // and then determine how many returns it is in use vs not in use by the ReturnFormRevisionId being populated\r\n // all in use one will have a ReturnFormRevisionId set to a number higher than zero\r\n const allReturnFormRevisions = inUseReturnFormRevisions.concat(canUseReturnFormRevisions);\r\n const returnFormRevisionsGroupedByFormRevisionId = _.groupBy(allReturnFormRevisions, x => x.formRevisionId);\r\n\r\n for (const key in returnFormRevisionsGroupedByFormRevisionId) {\r\n const returnFormRevisions = returnFormRevisionsGroupedByFormRevisionId[key];\r\n // they're all grouped by formRevisionID so they all share the same Id and Name; read those off the first one\r\n const formRevisionId = returnFormRevisions[0].formRevisionId;\r\n const formRevisionName = returnFormRevisions[0].formRevisionName;\r\n const totalReturnsAvailableToUse = returnFormRevisions.filter(x => !x.returnFormRevisionId).length;\r\n const allReturnsAdded = totalReturnsAvailableToUse === 0;\r\n const formRevisionDisplayName = this._returnService.getReturnFormRevisionDisplayName(returnFormRevisions[0]);\r\n const parentFormRevisionId = returnFormRevisions[0].parentFormRevisionId;\r\n\r\n const fra: ReturnFormRevisionAssociation = {\r\n formRevisionId: formRevisionId,\r\n formRevisionName: formRevisionName,\r\n isSelected: allReturnsAdded,\r\n isSelectedInitial: allReturnsAdded,\r\n hasChanges: this.selectedApplyChangesScopeOption === this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_RETURN ? false : !allReturnsAdded,\r\n totalReturns: selectedReturnIds.length,\r\n totalReturnsAvailableToUse: totalReturnsAvailableToUse,\r\n formRevisionDisplayName: formRevisionDisplayName,\r\n parentFormRevisionId: parentFormRevisionId\r\n };\r\n\r\n this.formRevisionAssociations.push(fra);\r\n }\r\n\r\n //sort forms: form revision first, then its supplemental forms next\r\n const sortedForms = [];\r\n const parentFormRevisionAssociations = this.formRevisionAssociations\r\n .filter(x => x.parentFormRevisionId === null)\r\n .sort((a, b) => a.formRevisionName.localeCompare(b.formRevisionName));\r\n const childFormRevisionAssociations = this.formRevisionAssociations\r\n .filter(x => x.parentFormRevisionId !== null)\r\n .sort((a, b) => a.formRevisionName.localeCompare(b.formRevisionName));\r\n const childDictionary: { [id: string]: ReturnFormRevisionAssociation[]; } = {};\r\n\r\n childFormRevisionAssociations.forEach(child => {\r\n if (!childDictionary[child.parentFormRevisionId]) {\r\n childDictionary[child.parentFormRevisionId] = [];\r\n }\r\n childDictionary[child.parentFormRevisionId].push(child);\r\n });\r\n\r\n parentFormRevisionAssociations.forEach(parent => {\r\n sortedForms.push(parent);\r\n if (childDictionary[parent.formRevisionId] != null) {\r\n sortedForms.push(...childDictionary[parent.formRevisionId]);\r\n }\r\n });\r\n\r\n this.formRevisionAssociations = sortedForms;\r\n\r\n this.hasChanges = !!this.formRevisionAssociations.find(x => x.hasChanges);\r\n }\r\n}\r\n","\r\n\r\n\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal'\r\nimport { ReturnService } from '../../../return.service';\r\nimport * as _ from 'lodash';\r\nimport { ReturnPreviewService } from '../returnPreview.service';\r\nimport { IWeissmanModalComponent } from '../../../../WeissmanModalService';\r\nimport { SnackBarService } from \"../../../../../Busy-Indicator\";\r\n\r\nexport interface ReturnPreviewFormDownloadParams {\r\n returnId: number;\r\n returnFormRevisions: Compliance.ReturnFormRevisionModel[];\r\n returnFormRevisionReports: Compliance.ReturnFormRevisionReportModel[]\r\n}\r\n\r\n@Component({\r\n selector: 'return-preview-form-download',\r\n templateUrl: './returnPreviewFormDownload.component.html'\r\n})\r\nexport class ReturnPreviewFormDownloadComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private _bsModalRef: BsModalRef,\r\n private _returnService: ReturnService,\r\n private _returnPreviewService: ReturnPreviewService,\r\n private _snackBarService: SnackBarService\r\n ) {}\r\n\r\n params: ReturnPreviewFormDownloadParams;\r\n result: void;\r\n\r\n returnFormRevisions: Compliance.ReturnFormRevisionModel[] = [];\r\n selectedReturnFormRevision: Compliance.ReturnFormRevisionModel;\r\n returnFormRevisionReports: Compliance.ReturnFormRevisionReportModel[] = []\r\n selectedReturnFormRevisionReport: Compliance.ReturnFormRevisionReportModel;\r\n isBusy: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this.returnFormRevisions = this.params.returnFormRevisions;\r\n this.selectedReturnFormRevision = this.returnFormRevisions[0];\r\n \r\n this._refreshReports();\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n getReportName(report: Compliance.ReturnFormRevisionReportModel): string {\r\n return this._returnService.getReturnReportName(report);\r\n }\r\n\r\n getReturnFormRevisionDisplayName(returnFormRevision: Compliance.ReturnFormRevisionModel): string {\r\n return this._returnService.getReturnFormRevisionDisplayName(returnFormRevision);\r\n }\r\n\r\n async onSelectedReturnFormRevisionChange(): Promise {\r\n await this._refreshReports();\r\n }\r\n\r\n async downloadForm(): Promise {\r\n this.isBusy = true;\r\n\r\n try {\r\n const lrpId = await this._returnPreviewService.startDownloadForm(\r\n this.selectedReturnFormRevision.returnId,\r\n this.selectedReturnFormRevision.formRevisionId,\r\n null);\r\n this._snackBarService.addById(lrpId, Compliance.LongRunningProcessTypeEnum.ReturnFormDownload);\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async downloadReport(): Promise {\r\n this.isBusy = true;\r\n\r\n try {\r\n const lrpId = await this._returnPreviewService.startDownloadReport(\r\n this.selectedReturnFormRevision.returnId,\r\n this.selectedReturnFormRevision.formRevisionId,\r\n this.selectedReturnFormRevisionReport.savedSearchId);\r\n this._snackBarService.addById(lrpId, Compliance.LongRunningProcessTypeEnum.ReturnReportDownload);\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private async _refreshReports(): Promise {\r\n const reports: Compliance.ReturnFormRevisionReportModel[] = [];\r\n if (this.selectedReturnFormRevision) {\r\n this.params.returnFormRevisionReports.forEach(x => {\r\n if (x.returnFormRevisionId === this.selectedReturnFormRevision.returnFormRevisionId) {\r\n reports.push(x);\r\n }\r\n })\r\n }\r\n\r\n this.returnFormRevisionReports = reports;\r\n this.selectedReturnFormRevisionReport = this.returnFormRevisionReports[0];\r\n }\r\n}\r\n","import { HelpContent } from '../../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const RETURN_PREVIEW_FORM_LIST_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'return-preview-form-list.edit-reports',\r\n tooltipText: 'Edit reports'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.forms-reports',\r\n tooltipText: 'Select a form or report from the list to preview it.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.forms-reports-no-returns',\r\n tooltipText: 'No returns selected.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.forms-reports-edit',\r\n tooltipText: 'Check or uncheck reports to be included with each form.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.edit-reports-no-returns',\r\n tooltipText: 'No returns selected.'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.download',\r\n tooltipText: 'Download forms and reports.'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.edit-forms',\r\n tooltipText: 'Edit forms'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.preview-form',\r\n tooltipText: 'Preview form'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.preview-form-has-override',\r\n tooltipText: 'Preview form (contains overrides).'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.preview-report',\r\n tooltipText: 'Preview report'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.preview-excel-report',\r\n tooltipText: 'Preview Excel report. The report will be displayed as PDF but will download in Excel format.'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.primary',\r\n tooltipText: 'Primary form for the return. When there are multiple forms, only one is primary.'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.return',\r\n tooltipText: 'Return'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.return-forms-custom',\r\n tooltipText: 'Return (using different forms than the default setup).'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.orphan-supplemental',\r\n tooltipText: 'Supplemental forms cannot be chosen without their parent form revision.'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.unchanged',\r\n tooltipText: 'No change has been made.'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.view-form-setup',\r\n tooltipText: 'View form setup.'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.priorReturnUsedAnotherForm',\r\n tooltipText: 'The prior year return cannot be used to detect year over year asset changes because the prior year form is different. Please configure the filing batch to use the company asset list for change detection.'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-list.electronic-filing-is-supported',\r\n tooltipText: 'Electronic filing of this form is supported.'\r\n }\r\n];\r\n","import { HelpContent } from '../../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const RETURN_PREVIEW_FORM_OVERRIDES_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'return-preview-form-overrides.show-all-overrides',\r\n tooltipText: 'Shows the list of overrides for any form in the list.'\r\n }\r\n];\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../../AgGrid';\r\nimport { ReturnPreviewService } from '../returnPreview.service';\r\n\r\nexport interface FormOverridesListDataSourceParams {\r\n filingBatchId: number;\r\n returnIds: number[];\r\n}\r\n\r\nexport class FormOverridesListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private _gridApi: GridApi,\r\n private _returnPreviewService: ReturnPreviewService,\r\n protected _dataSourceParamsFn: () => FormOverridesListDataSourceParams\r\n ) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'fieldName', value: Compliance.ReturnFormOverridePropertyEnum.FieldName },\r\n { name: 'fieldNameDisplay', value: Compliance.ReturnFormOverridePropertyEnum.FieldNameDisplay },\r\n { name: 'formRevisionId', value: Compliance.ReturnFormOverridePropertyEnum.FormRevisionId },\r\n { name: 'value', value: Compliance.ReturnFormOverridePropertyEnum.Value },\r\n { name: 'formRevisionName', value: Compliance.ReturnFormOverridePropertyEnum.FormRevisionName },\r\n { name: 'parcelAcctNumberDisplay', value: Compliance.ReturnFormOverridePropertyEnum.ParcelAcctNumberDisplay},\r\n { name: 'parcelAssessorName', value: Compliance.ReturnFormOverridePropertyEnum.AssessorName}\r\n ];\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const paginationModel = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const sortModel = this.getSortColumns(this._propertyMap);\r\n\r\n const result: Compliance.QueryResultModel = await this._returnPreviewService.getFormFieldOverrides(this._dataSourceParams.filingBatchId, paginationModel, sortModel, this._dataSourceParams.returnIds);\r\n if (result) {\r\n // If a form is currently displayed, match the ordering of the overrides with what is displayed on the form\r\n const overrides = this._returnPreviewService.fieldOverrideHolder.overrides;\r\n if (overrides && overrides.length) {\r\n result.data.sort((a, b) => {\r\n return overrides.findIndex(x => x.fieldName === a.fieldName) - overrides.findIndex(x => x.fieldName === b.fieldName);\r\n })\r\n }\r\n\r\n return { rows: result.data, totalRows: result.totalRows } as AgGridDataSourceResult;\r\n }\r\n\r\n return { rows: [], totalRows: 0 } as AgGridDataSourceResult;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { AgGridLinkCellRendererParams } from '../../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\n\r\nexport interface ReturnPreviewFormOverridesListActionCellRendererParams extends AgGridLinkCellRendererParams {\r\n deleteOverride: (params: ReturnPreviewFormOverridesListActionCellRendererParams) => void;\r\n viewReturn: (params: ReturnPreviewFormOverridesListActionCellRendererParams) => void;\r\n isReadOnly: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n `\r\n})\r\nexport class ReturnPreviewFormOverridesListActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ReturnPreviewFormOverridesListActionCellRendererParams;\r\n\r\n agInit(params: ReturnPreviewFormOverridesListActionCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { GridReadyEvent, GridApi, ColDef, GridOptions } from 'ag-grid-community';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { FormOverridesListAgGridDataSource, FormOverridesListDataSourceParams } from './agGridDataSource';\r\nimport { AgGridColumns, AgGridOptionsBuilder } from '../../../../AgGrid';\r\nimport { ReturnPreviewService } from '../returnPreview.service';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { AgGridLinkCellRendererComponent } from '../../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AgGridLinkCellRendererParams } from '../../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { ReturnPreviewFormOverridesListActionCellRendererParams, ReturnPreviewFormOverridesListActionCellRendererComponent } from './agGridActionCellRenderer.component';\r\nimport { IWeissmanModalComponent } from '../../../../WeissmanModalService';\r\n\r\nexport interface ReturnPreviewFormOverrideListParams {\r\n formRevisionScheduleId: number;\r\n filingBatchId: number;\r\n returnIds: number[];\r\n isReadOnly: boolean;\r\n}\r\n\r\nexport interface ReturnPreviewFormOverrideListResult {\r\n deletedOverrides: Compliance.ReturnFormOverrideDetailModel[];\r\n clickedOverride: Compliance.ReturnFormOverrideDetailModel;\r\n}\r\n\r\n@Component({\r\n selector: 'return-preview-form-override-list',\r\n templateUrl: './returnPreviewFormOverrideList.component.html',\r\n styleUrls: ['./returnPreviewFormOverrideList.component.scss']\r\n})\r\nexport class ReturnPreviewFormOverrideListComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _returnPreviewService: ReturnPreviewService,\r\n private readonly _returnService: ReturnService) { }\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: FormOverridesListAgGridDataSource;\r\n\r\n params: ReturnPreviewFormOverrideListParams;\r\n result: ReturnPreviewFormOverrideListResult = {\r\n deletedOverrides: [],\r\n clickedOverride: null\r\n };\r\n\r\n gridTotalsRow: any;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withInfiniteScroll()\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .withContext(this)\r\n .build();\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n const actionButtonCount = this.params.isReadOnly ? 1 : 2;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Assessor',\r\n field: 'parcelAssessorName',\r\n lockVisible: true,\r\n lockPosition: true,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const override = params.data as Compliance.ReturnFormOverrideDetailModel;\r\n if (!(override && override.parcelAssessorId)) {\r\n return '';\r\n }\r\n return `#/assessor/${override.parcelAssessorId}`;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n return false;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n headerName: 'Parcel',\r\n field: 'parcelAcctNumberDisplay',\r\n lockVisible: true,\r\n lockPosition: true,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const override = params.data as Compliance.ReturnFormOverrideDetailModel;\r\n if (!(override && override.parcelId)) {\r\n return '';\r\n }\r\n return `#/parcel/${override.parcelId}`;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n return false;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n headerName: 'Form',\r\n field: 'formRevisionName',\r\n lockVisible: true,\r\n lockPosition: true,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Field',\r\n field: 'fieldNameDisplay',\r\n lockVisible: true,\r\n lockPosition: true,\r\n width: AgGridColumns.textColumnWidth,\r\n sortable: false\r\n },\r\n {\r\n headerName: 'Override Value',\r\n field: 'value',\r\n lockVisible: true,\r\n lockPosition: true,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: '',\r\n field: 'returnId',\r\n lockVisible: true,\r\n lockPosition: true,\r\n sortable: false,\r\n width: AgGridColumns.getActionColumnWidth(actionButtonCount),\r\n minWidth: AgGridColumns.getActionColumnWidth(actionButtonCount),\r\n maxWidth: AgGridColumns.getActionColumnWidth(actionButtonCount),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n pinned: 'right',\r\n cellRendererFramework: ReturnPreviewFormOverridesListActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewReturn: this._viewReturn.bind(this),\r\n deleteOverride: this._deleteOverride.bind(this),\r\n isReadOnly: this.params.isReadOnly\r\n } as ReturnPreviewFormOverridesListActionCellRendererParams\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n\r\n this._gridApi.setSortModel({\r\n colId: 'formRevisionName',\r\n sort: 'asc'\r\n });\r\n\r\n this._setDataSource();\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const dataSourceParams = (): FormOverridesListDataSourceParams => {\r\n return {\r\n filingBatchId: this.params.filingBatchId,\r\n returnIds: this._returnService.sharedState.returns.map(r => r.returnId)\r\n };\r\n };\r\n\r\n this._gridDataSource = new FormOverridesListAgGridDataSource(\r\n this._gridApi,\r\n this._returnPreviewService,\r\n dataSourceParams\r\n );\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private async _viewReturn(params: AgGridLinkCellRendererParams): Promise {\r\n this.result.clickedOverride = params.data as Compliance.ReturnFormOverrideDetailModel;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private async _deleteOverride(params: ReturnPreviewFormOverridesListActionCellRendererParams): Promise {\r\n const data = params.data as Compliance.ReturnFormOverrideDetailModel;\r\n\r\n const returnMergedParcelIds: Compliance.ReturnMergedParcelIdModel = {\r\n returnId: data.returnId,\r\n mergedParcelId: (this._returnService.isReturnConsolidated(data.returnId)) ? data.parcelId : null\r\n };\r\n\r\n const returnFormOverrideDeleteRequestModel: Compliance.ReturnFormOverrideRequestModel = {\r\n formRevisionId: data.formRevisionId,\r\n fieldName: data.fieldName,\r\n returnMergedParcelIds: [returnMergedParcelIds],\r\n value: null,\r\n rowVersion: data.rowVersion\r\n };\r\n\r\n await this._returnPreviewService.deleteFormFieldOverrides(returnFormOverrideDeleteRequestModel);\r\n\r\n this.result.deletedOverrides.push(data);\r\n this._refreshDataSource();\r\n }\r\n}\r\n","\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { ReturnPreviewService } from '../returnPreview.service';\r\nimport { RETURN_PREVIEW_FORM_OVERRIDES_HELP } from './returnPreviewFormOverrides.component.help';\r\nimport { HelpService } from '../../../../../UI-Lib/Help-Tooltip';\r\nimport { WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport { ReturnPreviewFormOverrideListParams, ReturnPreviewFormOverrideListComponent } from '../Form-Overrides-List/returnPreviewFormOverrideList.component';\r\n\r\n@Component({\r\n selector: 'return-preview-form-overrides',\r\n templateUrl: './returnPreviewFormOverrides.component.html',\r\n styleUrls: ['./returnPreviewFormOverrides.component.scss']\r\n})\r\nexport class ReturnPreviewFormOverridesComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnPreviewService: ReturnPreviewService,\r\n private readonly _helpService: HelpService,\r\n private readonly _modalService: WeissmanModalService) { }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(RETURN_PREVIEW_FORM_OVERRIDES_HELP);\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n async openOverridesModal(): Promise {\r\n const params: ReturnPreviewFormOverrideListParams = {\r\n formRevisionScheduleId: null,\r\n filingBatchId: this._returnService.filingBatchId,\r\n returnIds: this._returnService.sharedState.returns.map(x => x.returnId),\r\n isReadOnly: this._returnService.isReturnInReadOnlyMode || !this._returnService.canEditCompany\r\n }\r\n\r\n const result = await this._modalService.showAsync(ReturnPreviewFormOverrideListComponent, params, 'modal-xl');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._returnPreviewService.notifyReturnFormOverrideListChanged(result);\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","\r\n","\r\n
\r\n
\r\n
\r\n \r\n {{ r.parcelAcctNumDisplay }}\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n {{ r.parcelAcctNumDisplay }}\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n
\r\n Forms and Reports\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import {\r\n Component,\r\n OnInit,\r\n OnDestroy,\r\n ElementRef,\r\n ViewChild,\r\n HostListener,\r\n AfterViewInit,\r\n TemplateRef\r\n} from '@angular/core';\r\nimport { trigger, transition, style, animate } from '@angular/animations';\r\nimport { ModalOptions } from 'ngx-bootstrap/modal';\r\nimport { BehaviorSubject, lastValueFrom, Subject } from 'rxjs';\r\nimport { RestrictService, Roles } from '../../../../../Common/Permissions/restrict.service';\r\nimport { ReturnFormRevisionReportRepository } from '../../../../Repositories';\r\nimport { WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport { ReturnService, ReturnServiceSharedState } from '../../../return.service';\r\nimport { ReturnUpdateLogicService } from '../../../returnUpdateLogic.service';\r\nimport { ReturnPreviewService, ReturnFormModel } from '../returnPreview.service';\r\nimport { ReturnPreviewFormAssociationsParams, ReturnPreviewFormAssociationsComponent } from '../Form-Associations/returnPreviewFormAssociations.component';\r\nimport { ReturnPreviewFormDownloadParams, ReturnPreviewFormDownloadComponent } from '../Form-Download/returnPreviewFormDownload.component';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport { BusyIndicatorService } from '../../../../../Busy-Indicator';\r\nimport { IMutexServiceHandler, WeissmanMutexService } from '../../../../WeissmanMutexService';\r\nimport { UpgradeNavigationServiceHandler } from '../../../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { HelpService } from '../../../../../UI-Lib/Help-Tooltip';\r\nimport { RETURN_PREVIEW_FORM_LIST_HELP } from './returnPreviewFormList.component.help';\r\nimport { CdkVirtualScrollViewport } from '@angular/cdk/scrolling';\r\n\r\nimport { sortBy, reduce, forEach } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\nimport { ProductAnalyticsService } from '../../../../../Common/Amplitude/productAnalytics.service';\r\n\r\nenum ReturnTemplateTypes {\r\n Return,\r\n Form,\r\n Report,\r\n Merged\r\n}\r\n\r\ninterface ReturnInfo {\r\n template: ReturnTemplateTypes;\r\n returnId: number;\r\n parcelId: number;\r\n hasOverride?: boolean;\r\n selected?: boolean;\r\n formsLength?: number;\r\n parcelAcctNum?: string;\r\n parcelAcctNumDisplay?: string;\r\n form?: ReturnForm;\r\n report?: Compliance.ReturnFormRevisionReportModel;\r\n priorReturnUsedAnotherForm: boolean;\r\n hasElectronicFileType: boolean;\r\n}\r\n\r\ninterface ReturnInfoTree extends ReturnInfo {\r\n forms?: ReturnInfoTree[];\r\n merged?: ReturnInfoTree[];\r\n reports?: ReturnInfo[];\r\n}\r\n\r\ninterface ReturnForm extends Compliance.ReturnFormRevisionModel {\r\n parcelId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'return-preview-form-list',\r\n templateUrl: './returnPreviewFormList.component.html',\r\n styleUrls: ['./returnPreviewFormList.component.scss'],\r\n animations: [\r\n trigger('reportEnter', [\r\n transition(':enter', [\r\n style({ opacity: 0, transform: 'translateY(-10px)' }),\r\n animate(60, style({ opacity: 1, transform: 'translateY(0)' }))\r\n ]),\r\n transition(':leave', [\r\n animate(60, style({ opacity: 0, transform: 'translateY(-10px)' }))\r\n ])\r\n ])\r\n ]\r\n})\r\nexport class ReturnPreviewFormListComponent implements OnInit, AfterViewInit, OnDestroy, IReturnPartComponent, IMutexServiceHandler {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnPreviewService: ReturnPreviewService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _returnFormRevisionReportRepository: ReturnFormRevisionReportRepository,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _helpService: HelpService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService\r\n ) { }\r\n\r\n @ViewChild('returnTemplate', { static: true }) returnTemplate: TemplateRef;\r\n @ViewChild('formTemplate', { static: true }) formTemplate: TemplateRef;\r\n @ViewChild('reportTemplate', { static: true }) reportTemplate: TemplateRef;\r\n @ViewChild('mergedTemplate', { static: true }) mergedTemplate: TemplateRef;\r\n\r\n @ViewChild(CdkVirtualScrollViewport) viewport: CdkVirtualScrollViewport;\r\n\r\n @HostListener('window:resize', ['$event'])\r\n onResize(event) {\r\n if (this.viewport) {\r\n this.viewport.checkViewportSize();\r\n }\r\n }\r\n\r\n flatReturns: ReturnInfo[] = [];\r\n returnTemplateTypes = ReturnTemplateTypes;\r\n selectedReturnId: number;\r\n selectedReturnFormRevisionId: number;\r\n selectedReturnFormRevisionReportId: number;\r\n selectedFormRevisionId: number;\r\n selectedReportId: number; // saved search ID\r\n selectedMergeParcelId: number;\r\n selectedIsExcel: boolean;\r\n\r\n editMode: boolean = false;\r\n isBusy: boolean = false;\r\n showList = true;\r\n hasLongName = true;\r\n\r\n showOnlyFrequentlyUsedReports: boolean = true;\r\n applySelectionsToAllReports: boolean = false;\r\n isReturnInReadOnlyMode: boolean;\r\n filingBatchId: number;\r\n\r\n returnNotDefaultMap: { [returnId: number]: boolean; };\r\n\r\n private _localReturnServiceSharedState: ReturnServiceSharedState;\r\n\r\n private _editModeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n private _returnsPreEditModeCopy: ReturnInfo[];\r\n\r\n private _loadingFormRevisions: boolean = false;\r\n private _tabChangedReload: boolean = true;\r\n\r\n private _destroyTabSubs$: Subject = new Subject();\r\n\r\n private _returns: ReturnInfoTree[] = [];\r\n private _templateMap: Map>;\r\n private _parcelsChangeDate: Date = null;\r\n\r\n private _isFormOverridden =\r\n (x: ReturnInfo, y: ReturnInfo) =>\r\n (z: Compliance.ReturnFormRevisionModel) => z.returnId === x.returnId && z.formRevisionId === y.form.formRevisionId && (!z.mergedParcelId || z.mergedParcelId === y.parcelId);\r\n\r\n private _isReportOverridden =\r\n (x: ReturnInfo, y: ReturnInfo) =>\r\n (z: Compliance.ReturnFormRevisionModel) => z.returnId === x.returnId && (!z.mergedParcelId || z.mergedParcelId === y.parcelId);\r\n\r\n get taxYear(): number {\r\n return this._returnService.taxYear;\r\n }\r\n\r\n get editReportsHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n if (!this._returns.length) {\r\n return 'return-preview-form-list.edit-reports-no-returns';\r\n }\r\n\r\n return 'return-preview-form-list.edit-reports';\r\n }\r\n\r\n get formsAndReportsHelpContentId(): string {\r\n if (this.editMode) {\r\n return 'return-preview-form-list.forms-reports-edit';\r\n }\r\n\r\n if (this._returns.length) {\r\n return 'return-preview-form-list.forms-reports';\r\n } else {\r\n return 'return-preview-form-list.forms-reports-no-returns';\r\n }\r\n }\r\n\r\n get canEdit(): boolean {\r\n return !this._returnService.isReturnInReadOnlyMode && this._returnService.canEditCompany;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._returnService.editGroup);\r\n }\r\n\r\n get hasEditComplianceSetupsPermission(): boolean {\r\n return this._restrictService.isInRole(Roles.COMPLIANCESETUPSEDIT);\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(RETURN_PREVIEW_FORM_LIST_HELP);\r\n\r\n const filingBatchIdParam = this._routerService.getQuerystringParam('filingBatchId');\r\n this.filingBatchId = parseInt(filingBatchIdParam);\r\n\r\n this._templateMap = new Map([\r\n [ReturnTemplateTypes.Return, this.returnTemplate],\r\n [ReturnTemplateTypes.Form, this.formTemplate],\r\n [ReturnTemplateTypes.Report, this.reportTemplate],\r\n [ReturnTemplateTypes.Merged, this.mergedTemplate]\r\n ]);\r\n\r\n this._returnPreviewService.subscribeToServiceActivationCycle(this);\r\n this._createComparisonMap(this._returnService.compareFormsResult);\r\n this._returnService.compareForms$.pipe(takeUntil(this._destroyTabSubs$))\r\n .subscribe((comparison: Compliance.ReturnCompareFormsResultModel) => {\r\n if(comparison) {\r\n this._createComparisonMap(comparison);\r\n }\r\n });\r\n this._returnPreviewService.openPreviewByOverrides$.pipe(takeUntil(this._destroyTabSubs$))\r\n .subscribe((overrideModel: Compliance.ReturnFormOverrideDetailModel) => {\r\n this._openPreviewByOverrideClick(overrideModel);\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroyTabSubs$.next();\r\n this._destroyTabSubs$.complete();\r\n this._returnPreviewService.unsubscribeFromServiceActivationCycle(this);\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n if (this.viewport) {\r\n this.viewport.checkViewportSize();\r\n }\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n this._returnService.returns$.pipe(takeUntil(this._destroyTabSubs$))\r\n .subscribe((returns) => {\r\n if (returns) {\r\n this._refreshFormRevisions();\r\n this._tabChangedReload = false;\r\n this.showList = true;\r\n }\r\n });\r\n\r\n this._returnService.isReturnInReadOnlyMode$.pipe(takeUntil(this._destroyTabSubs$))\r\n .subscribe(async (isReadonly) => {\r\n if (this.isReturnInReadOnlyMode === isReadonly) { return; }\r\n this.isReturnInReadOnlyMode = isReadonly;\r\n await this._refreshFormRevisions(true); // force reload of forms and reports\r\n });\r\n\r\n this._returnPreviewService.formOverrides$.pipe(takeUntil(this._destroyTabSubs$))\r\n .subscribe(overrides => {\r\n this._returns.forEach(x => {\r\n x.forms.forEach(y => y.hasOverride = overrides.some(this._isFormOverridden(x, y)));\r\n x.merged.forEach(y => {\r\n y.hasOverride = overrides.some(this._isReportOverridden(x, y));\r\n y.forms.forEach(z => z.hasOverride = overrides.some(this._isFormOverridden(x, z)));\r\n });\r\n });\r\n });\r\n\r\n this._returnPreviewService.returnForm$.pipe(takeUntil(this._destroyTabSubs$))\r\n .subscribe(x => {\r\n this.selectedReturnId = x && x.returnId;\r\n this.selectedReturnFormRevisionId = x && x.returnFormRevisionId;\r\n this.selectedReturnFormRevisionReportId = x && x.returnFormRevisionReportId;\r\n this.selectedFormRevisionId = x && x.formRevisionId;\r\n this.selectedReportId = x && x.reportId;\r\n this.selectedMergeParcelId = x && x.mergeParcelId;\r\n this.selectedIsExcel = x && x.isExcel;\r\n });\r\n\r\n this._editModeSubject.asObservable().pipe(takeUntil(this._destroyTabSubs$))\r\n .subscribe(x => {\r\n this.editMode = x;\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n }\r\n });\r\n\r\n this._returnService.parcelsChanged$.pipe(takeUntil(this._destroyTabSubs$)).subscribe((x) => {\r\n if (x) {\r\n if (this._parcelsChangeDate !== x && this.viewport) {\r\n this._parcelsChangeDate = x;\r\n this._refreshFormRevisions(true);\r\n }\r\n }\r\n });\r\n\r\n if (this.viewport) {\r\n this.viewport.checkViewportSize();\r\n }\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._destroyTabSubs$.next();\r\n this._tabChangedReload = true;\r\n this.showList = false;\r\n }\r\n\r\n getTemplate(template: ReturnTemplateTypes): TemplateRef {\r\n return this._templateMap.get(template) as TemplateRef;\r\n }\r\n\r\n getReportName(report: Compliance.ReturnFormRevisionReportModel): string {\r\n return this._returnService.getReturnReportName(report);\r\n }\r\n\r\n getReturnFormRevisionDisplayName(returnFormRevision: Compliance.ReturnFormRevisionModel): string {\r\n return this._returnService.getReturnFormRevisionDisplayName(returnFormRevision);\r\n }\r\n\r\n getReportSource(report: Compliance.ReturnFormRevisionReportModel): string {\r\n return report.source === Compliance.ReturnFormRevisionSourceEnum.FilingBatchReport\r\n ? ' Source: Filing Batch Additional Reports'\r\n : ' Source: Default Form Setup';\r\n }\r\n\r\n async downloadReturnDocument(returnId: number): Promise {\r\n const returnInfo = this._returns\r\n .find(x => x.returnId === returnId);\r\n\r\n const forms = returnInfo.forms\r\n .map(x => x.form);\r\n\r\n const reports = returnInfo.forms\r\n .map(x => x.reports)\r\n .reduce((prev, cur) => prev.concat(cur))\r\n .map(x => x.report);\r\n\r\n const params: ReturnPreviewFormDownloadParams = {\r\n returnId: returnId,\r\n returnFormRevisions: forms,\r\n returnFormRevisionReports: reports\r\n };\r\n\r\n await this._modalService.showAsync(ReturnPreviewFormDownloadComponent, params, 'modal-md');\r\n }\r\n\r\n async manageReturnFormRevisions(r: ReturnInfo): Promise {\r\n const params: ReturnPreviewFormAssociationsParams = {\r\n returnId: r.returnId,\r\n parcelId: r.parcelId\r\n };\r\n\r\n const modalOptions = {\r\n class: 'modal-md',\r\n initialState: { params },\r\n ignoreBackdropClick: true,\r\n keyboard: false,\r\n providers: [{ provide: ReturnUpdateLogicService, useValue: this._returnUpdateLogicService }]\r\n } as ModalOptions;\r\n\r\n const result = await this._modalService.showAsync(ReturnPreviewFormAssociationsComponent, params, 'modal-md', modalOptions);\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._refreshFormRevisions();\r\n this._returnService.validateForms(this.filingBatchId);\r\n }\r\n\r\n showPreview(returnId: number, returnFormRevisionId: number, formRevisionId: number, returnFormRevisionReportId: number, reportId: number, mergedParcelId: number, isExcel: boolean, navigateToOverride: Compliance.ReturnFormOverrideDetailModel = null): void {\r\n this.selectedReturnId = returnId;\r\n this.selectedReturnFormRevisionId = returnFormRevisionId;\r\n this.selectedReturnFormRevisionReportId = returnFormRevisionReportId;\r\n this.selectedFormRevisionId = formRevisionId;\r\n this.selectedReportId = reportId;\r\n this.selectedMergeParcelId = mergedParcelId;\r\n this.selectedIsExcel = isExcel;\r\n\r\n this._onSelectedFormListItemChanged(navigateToOverride);\r\n }\r\n\r\n selectReport(report: ReturnInfo, form: ReturnInfo) {\r\n report.selected = !report.selected;\r\n\r\n if (this.applySelectionsToAllReports) {\r\n const savedSearchId = report.report.savedSearchId;\r\n\r\n const forms = this._returns.reduce((acc, r) => [...acc, ...r.forms], []);\r\n const reports = forms.reduce((acc, formInfo: ReturnInfoTree) => [...acc, ...formInfo.reports], [])\r\n .filter((returnFormReportInfo: ReturnInfoTree) => returnFormReportInfo.report.savedSearchId === savedSearchId);\r\n\r\n reports.forEach((returnFormInfo: ReturnInfoTree) => {\r\n returnFormInfo.selected = report.selected;\r\n });\r\n }\r\n }\r\n\r\n enterEditMode(): void {\r\n this._mutexService.acquire(this, this._returnService.editGroup);\r\n this._editModeSubject.next(true);\r\n this._returnsPreEditModeCopy = _.cloneDeep(this._returns);\r\n this._setFlatReturns();\r\n }\r\n\r\n cancelEditMode(): void {\r\n this._returns = this._returnsPreEditModeCopy;\r\n this._editModeSubject.next(false);\r\n this._setFlatReturns();\r\n }\r\n\r\n async saveFormReports(): Promise {\r\n this.isBusy = true;\r\n const modelsToPersist: Compliance.ReturnFormRevisionReportModel[] = [];\r\n this._returns.forEach(x => {\r\n x.forms.forEach(y => {\r\n y.reports.forEach(({ selected, report }) => {\r\n if ((selected && report.returnFormRevisionReportId === 0) || (!selected && report.returnFormRevisionReportId !== 0)) {\r\n modelsToPersist.push(report);\r\n }\r\n });\r\n });\r\n });\r\n\r\n try {\r\n await lastValueFrom(this._returnFormRevisionReportRepository.update(this.filingBatchId, modelsToPersist));\r\n this._editModeSubject.next(false);\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n\r\n await this._loadFormRevisions();\r\n this._returnService.validateForms(this.filingBatchId);\r\n this._setFlatReturns();\r\n this._productAnalyticsService.logEvent('click-edit-reports-save-changes', {\r\n updateReturnReports: modelsToPersist.map(x => x.name + (x.variantName ? (` - ${ x.variantName}`) : ''))\r\n });\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n private _openPreviewByOverrideClick = (overrideModel: Compliance.ReturnFormOverrideDetailModel) => {\r\n if (this._returns) {\r\n const returnInfo = this._returns.find(x => x.returnId === overrideModel.returnId);\r\n const formInfo = returnInfo && returnInfo.forms.find(({ form }) => form.formRevisionId === overrideModel.formRevisionId);\r\n\r\n if (returnInfo && formInfo) {\r\n this.showPreview(returnInfo.returnId, formInfo.form.returnFormRevisionId, formInfo.form.formRevisionId, null, null, overrideModel.parcelId, false, overrideModel);\r\n }\r\n }\r\n };\r\n\r\n private _checkForReportChanges(currentReports: Compliance.FilingBatchReportModel[]): boolean {\r\n let hasUpdates: boolean;\r\n const lastUsedReports = this._localReturnServiceSharedState.reports;\r\n if (lastUsedReports.length !== currentReports.length) {\r\n hasUpdates = true;\r\n } else {\r\n hasUpdates = !currentReports.every((currentReport: Compliance.FilingBatchReportModel) => {\r\n return (lastUsedReports.some((prevReport: Compliance.FilingBatchReportModel) => {\r\n return (prevReport.changeDate === currentReport.changeDate &&\r\n prevReport.filingBatchReportId === currentReport.filingBatchReportId);\r\n }));\r\n });\r\n }\r\n return hasUpdates;\r\n }\r\n\r\n private async _refreshFormRevisions(force: boolean = false): Promise {\r\n const returnServiceSharedState: ReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n\r\n // get input parameters for comparison\r\n const localReturnIds = (this._localReturnServiceSharedState && this._localReturnServiceSharedState.returns && this._localReturnServiceSharedState.returns.map(x => x.returnId)) || [];\r\n const sharedReturnIds = returnServiceSharedState.returns.map(x => x.returnId);\r\n\r\n const localReturnFormRevisionsUpdatedTimestamp = this._localReturnServiceSharedState && this._localReturnServiceSharedState.returnFormRevisionsUpdatedTimestamp;\r\n const sharedReturnFormRevisionsUpdatedTimestamp = returnServiceSharedState.returnFormRevisionsUpdatedTimestamp;\r\n\r\n // check to see if the input parameters are available\r\n if (!sharedReturnIds) {\r\n return;\r\n }\r\n\r\n // check to see if the input parameters have changed\r\n if (force ||\r\n !_.isEqual(localReturnIds, sharedReturnIds) ||\r\n !_.isEqual(localReturnFormRevisionsUpdatedTimestamp, sharedReturnFormRevisionsUpdatedTimestamp) ||\r\n this._checkForReportChanges(returnServiceSharedState.reports)\r\n ) {\r\n if (this._loadingFormRevisions) { return; }\r\n await this._loadFormRevisions(!_.isEqual(localReturnIds, sharedReturnIds));\r\n }\r\n\r\n // auto-select the return/returnForm/returnFormReport\r\n this.selectedReturnId = null;\r\n this.selectedReturnFormRevisionId = null;\r\n this.selectedReturnFormRevisionReportId = null;\r\n this.selectedFormRevisionId = null;\r\n this.selectedMergeParcelId = null;\r\n\r\n const returnForm = this._returnPreviewService.sharedState.returnForm;\r\n const currentReturn = returnForm ? this.flatReturns.find(x => x.returnId === returnForm.returnId && x.parcelId === returnForm.mergeParcelId) : null;\r\n\r\n if (currentReturn) {\r\n this.selectedReturnId = returnForm.returnId;\r\n this.selectedReturnFormRevisionId = returnForm.returnFormRevisionId;\r\n this.selectedReturnFormRevisionReportId = returnForm.returnFormRevisionReportId;\r\n this.selectedFormRevisionId = returnForm.formRevisionId;\r\n this.selectedMergeParcelId = (!this.selectedReturnFormRevisionReportId && returnForm.mergeParcelId) || null;\r\n }\r\n\r\n this._onSelectedFormListItemChanged();\r\n }\r\n\r\n private async _loadFormRevisions(updateFormRevisions?: boolean): Promise {\r\n this._loadingFormRevisions = true;\r\n // persist local state for future checks\r\n this._localReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading Returns' });\r\n\r\n try {\r\n // consists of a list of accounts and forms for each account to display in sequential order\r\n // on the UI, if an item in this list does not have a form revision ID then it is the account label and it will show differently\r\n // if it does have a form revision ID then a click event is made available and we will get notified when that item is selected for (rendering) preview\r\n const [reportsForReturns, reportsAvailable]: [Compliance.ReturnFormRevisionReportModel[], Compliance.ReturnFormRevisionReportModel[], void] = await Promise.all([\r\n lastValueFrom(this._returnPreviewService.getAssociatedReportsForReturns()),\r\n lastValueFrom(this._returnPreviewService.getNotAssociatedReportsForReturns()),\r\n updateFormRevisions ? this._returnService.loadReturnFormRevisions() : Promise.resolve()\r\n ]);\r\n\r\n const reportsAvailableForReturns = reportsAvailable.reduce((acc, x) => {\r\n if (!acc.find(y => y.savedSearchId === x.savedSearchId && y.returnFormRevisionId === x.returnFormRevisionId)) {\r\n acc.push(x);\r\n }\r\n return acc;\r\n }, [] as Compliance.ReturnFormRevisionReportModel[]);\r\n\r\n this._returns = [];\r\n\r\n // Create the consolidated parcel groupings first, then add the forms and reports\r\n this._returnService.sharedState.returns.reduce((acc, x) => {\r\n const returnId = (x.returnId !== null && x.returnId);\r\n const returnInfo = (acc.has(returnId))\r\n ? acc.get(returnId)\r\n : {\r\n template: ReturnTemplateTypes.Return,\r\n level: 0,\r\n returnId: returnId,\r\n parcelId: null,\r\n parcelAcctNum: null,\r\n parcelAcctNumDisplay: null,\r\n returnFormRevisionId: null,\r\n forms: [],\r\n merged: [],\r\n priorReturnUsedAnotherForm: false,\r\n hasElectronicFileType: false\r\n };\r\n\r\n if (!x.isMergedParcel) {\r\n returnInfo.parcelId = x.parcelId;\r\n returnInfo.parcelAcctNum = x.parcelAcctNumber;\r\n returnInfo.parcelAcctNumDisplay = x.parcelAcctNumberDisplay;\r\n } else {\r\n returnInfo.merged.push({\r\n template: ReturnTemplateTypes.Merged,\r\n returnId: returnId,\r\n parcelId: x.parcelId,\r\n parcelAcctNum: x.parcelAcctNumber,\r\n parcelAcctNumDisplay: x.parcelAcctNumberDisplay,\r\n hasOverride: false,\r\n forms: [],\r\n priorReturnUsedAnotherForm: false,\r\n hasElectronicFileType: false\r\n });\r\n }\r\n\r\n // If any parcel has a long name, make the panel a bit wider\r\n if (returnInfo.parcelAcctNumDisplay && returnInfo.parcelAcctNumDisplay.length > 43) {\r\n this.hasLongName = true;\r\n }\r\n\r\n acc.set(returnId, returnInfo);\r\n return acc;\r\n }, new Map()).forEach(x => {\r\n this._returnService\r\n .getAssociatedReturnFormRevisions()\r\n .filter(item => item.returnId === x.returnId)\r\n .forEach((y: Compliance.ReturnFormRevisionModel, i, ar) => {\r\n const form = { ...y, parcelId: x.parcelId };\r\n const returnFormInfo: ReturnInfoTree = {\r\n template: ReturnTemplateTypes.Form,\r\n returnId: x.returnId,\r\n parcelId: x.parcelId,\r\n form,\r\n formsLength: ar.length,\r\n hasOverride: false,\r\n reports: [],\r\n priorReturnUsedAnotherForm: y.priorReturnUsedAnotherForm,\r\n hasElectronicFileType: y.hasElectronicFileType\r\n };\r\n\r\n // add in-use form revision reports to return form revision\r\n reportsForReturns\r\n .filter(x => x.returnFormRevisionId === y.returnFormRevisionId)\r\n .forEach(z => {\r\n const returnFormReportInfo: ReturnInfo = {\r\n template: ReturnTemplateTypes.Report,\r\n returnId: x.returnId,\r\n parcelId: null,\r\n selected: true,\r\n form,\r\n report: z,\r\n priorReturnUsedAnotherForm: false,\r\n hasElectronicFileType: false\r\n };\r\n returnFormInfo.reports.push(returnFormReportInfo);\r\n });\r\n\r\n // add available form revision reports to return form revisions\r\n reportsAvailableForReturns\r\n .filter(x => x.returnFormRevisionId === y.returnFormRevisionId)\r\n .forEach(z => {\r\n const returnFormReportInfo: ReturnInfo = {\r\n template: ReturnTemplateTypes.Report,\r\n returnId: x.returnId,\r\n parcelId: null,\r\n selected: false,\r\n form,\r\n report: z,\r\n priorReturnUsedAnotherForm: false,\r\n hasElectronicFileType: false\r\n };\r\n returnFormInfo.reports.push(returnFormReportInfo);\r\n });\r\n\r\n returnFormInfo.reports = _.orderBy(returnFormInfo.reports,\r\n [({ report }) => report.sequence, ({ report }) => report.name, ({ report }) => report.variantName]);\r\n\r\n x.forms.push(returnFormInfo);\r\n x.merged.forEach(z => {\r\n if (y.isFormConsolidated) {\r\n const mergedForm = { ...returnFormInfo, isMergedForm: true, parcelId: z.parcelId };\r\n z.forms.push(mergedForm);\r\n }\r\n });\r\n });\r\n\r\n //sort forms: form revision first, then its supplemental forms next\r\n const sortedForms = [];\r\n const parentFormRevisionAssociations = x.forms\r\n .filter(y => y.form.parentFormRevisionId === null)\r\n .sort((a, b) => a.form.formRevisionName.localeCompare(b.form.formRevisionName));\r\n const childFormRevisionAssociations = x.forms\r\n .filter(y => y.form.parentFormRevisionId !== null)\r\n .sort((a, b) => a.form.formRevisionName.localeCompare(b.form.formRevisionName));\r\n const childDict: { [id: string]: ReturnInfoTree[]; } = {};\r\n\r\n childFormRevisionAssociations.forEach(child => {\r\n if (!childDict[child.form.parentFormRevisionId]) {\r\n childDict[child.form.parentFormRevisionId] = [];\r\n }\r\n childDict[child.form.parentFormRevisionId].push(child);\r\n });\r\n\r\n parentFormRevisionAssociations.forEach(parent => {\r\n sortedForms.push(parent);\r\n if (childDict[parent.form.formRevisionId] != null) {\r\n sortedForms.push(...childDict[parent.form.formRevisionId]);\r\n }\r\n });\r\n\r\n x.forms = sortedForms;\r\n\r\n // If a merged parcel has no forms remove it\r\n if (x.merged.length) {\r\n x.merged = x.merged.reduce((acc, y) => {\r\n if (y.forms.length) {\r\n acc.push(y);\r\n }\r\n return acc;\r\n }, []);\r\n }\r\n\r\n this._returns.push(x);\r\n });\r\n\r\n this._setFlatReturns();\r\n this.viewport.checkViewportSize();\r\n\r\n // load the overrides then filter the list of all items\r\n await this._returnPreviewService.loadFormOverrides();\r\n } finally {\r\n this._loadingFormRevisions = false;\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _setFlatReturns(): void {\r\n this.flatReturns = this._returns.reduce((acc, r) => {\r\n if (r.parcelAcctNumDisplay) {\r\n acc.push(r);\r\n r.forms.forEach(x => {\r\n acc.push(x);\r\n x.reports.forEach(y => {\r\n if ((this.editMode && (y.report.isFrequentlyUsed || !this.showOnlyFrequentlyUsedReports)) ||\r\n ((!this.isReturnInReadOnlyMode && y.selected) || (this.isReturnInReadOnlyMode && y.selected && y.report.hasReturnFile))) {\r\n acc.push(y);\r\n }\r\n });\r\n });\r\n }\r\n _.flow([\r\n sortBy(['parcelAcctNumDisplay']),\r\n forEach(x => {\r\n acc.push(x);\r\n x.forms.forEach(y => acc.push(y));\r\n })\r\n ])(r.merged);\r\n return acc;\r\n }, []);\r\n }\r\n\r\n private _onSelectedFormListItemChanged(navigateToOverride: Compliance.ReturnFormOverrideDetailModel = null): void {\r\n if (this.selectedReturnId && (this.selectedReturnFormRevisionId || this.selectedReturnFormRevisionReportId)) {\r\n this._returnPreviewService.setReturnForm({\r\n mergeParcelId: this.selectedMergeParcelId,\r\n returnId: this.selectedReturnId,\r\n returnFormRevisionId: this.selectedReturnFormRevisionId,\r\n returnFormRevisionReportId: this.selectedReturnFormRevisionReportId,\r\n formRevisionId: this.selectedFormRevisionId,\r\n reportId: this.selectedReportId,\r\n isExcel: this.selectedIsExcel\r\n } as ReturnFormModel, navigateToOverride);\r\n } else this._returnPreviewService.setReturnForm(null);\r\n }\r\n\r\n private _createComparisonMap(comparison: Compliance.ReturnCompareFormsResultModel): void {\r\n this.returnNotDefaultMap = comparison.customReturns.reduce((acc, r) => { acc[r.returnId] = true; return acc; }, {});\r\n }\r\n}\r\n","\r\n
\r\n System-determined value: {{ oldValue !== \"\" ? oldValue : \"not found\" }}\r\n
\r\n {{ result.match ? 'Used value found in' : 'Tried to use'}}\r\n \r\n {{ getFieldEntityName(result.entityType) }} {{ result.entityField }} field of\r\n {{ result.entityName }}\r\n {{ result.entityName }}.\r\n \r\n \r\n {{ result.entityField }} return settings.\r\n \r\n
\r\n
\r\n\r\n
\r\n This field has been overridden.
\r\n System Value: {{ oldValue }}
\r\n Override Value: {{ newValue }}\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../../../../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { Subscription } from 'rxjs';\r\nimport { ReturnService } from '../../../../return.service';\r\nimport { FieldOverride } from '../../../../../../Common/PDFViewer/pdfViewerBase';\r\nimport { Constants } from '../../../../../../constants.new';\r\nimport * as _ from 'lodash';\r\nimport { IWeissmanModalComponent } from '../../../../../WeissmanModalService';\r\n\r\nexport interface ReturnPreviewFormOverrideEditParams {\r\n override: FieldOverride;\r\n oldValue: string;\r\n rowVersion: number[];\r\n ruleResults: Compliance.ReturnFormFieldRuleResultModel[];\r\n canEdit: boolean;\r\n}\r\n\r\nexport interface ReturnPreviewFormOverrideEditResult {\r\n deleteConfirmed: boolean;\r\n rowVersion: number[];\r\n override: FieldOverride;\r\n}\r\n\r\n@Component({\r\n selector: 'return-preview-form-override-edit',\r\n templateUrl: './returnPreviewFormOverrideEdit.component.html',\r\n styleUrls: ['./returnPreviewFormOverrideEdit.component.scss']\r\n})\r\nexport class ReturnPreviewFormOverrideEditComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _modalRef: BsModalRef,\r\n private readonly _returnService: ReturnService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _constants: Constants) { }\r\n\r\n private _returnReadOnlyFlagSub: Subscription;\r\n\r\n params: ReturnPreviewFormOverrideEditParams;\r\n result: ReturnPreviewFormOverrideEditResult;\r\n\r\n canEdit: boolean = false;\r\n oldValue: string;\r\n newValue: string;\r\n fieldName: string;\r\n rowVersion: number[];\r\n override: FieldOverride;\r\n deleteConfirmed: boolean = false;\r\n fieldEntityTypes = this._constants.ReturnFormFieldEntityTypes;\r\n\r\n modalTitle: string = 'Form Field Override';\r\n\r\n ruleResults: Compliance.ReturnFormFieldRuleResultModel[] = [];\r\n\r\n ngOnInit(): void {\r\n if (this.params.override) {\r\n this.newValue = this.params.override.overrideValue;\r\n this.fieldName = this.params.override.fieldName;\r\n this.override = this.params.override;\r\n this.rowVersion = this.params.rowVersion;\r\n }\r\n\r\n this.oldValue = this.params.oldValue;\r\n this.ruleResults = this.params.ruleResults;\r\n this.canEdit = this.override && (this.params.canEdit || (this._returnService.canEditCompany && !this._returnService.isReturnInReadOnlyMode));\r\n\r\n this._returnReadOnlyFlagSub = this._returnService.isReturnInReadOnlyMode$.subscribe(x => {\r\n this.canEdit = this.override && (this.params.canEdit || (this._returnService.canEditCompany && !x));\r\n });\r\n\r\n if (!this.override) {\r\n this.modalTitle = 'Form Field';\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnReadOnlyFlagSub && this._returnReadOnlyFlagSub.unsubscribe();\r\n }\r\n\r\n isFilingRuleResult(ruleResult: Compliance.ReturnFormFieldRuleResultModel): boolean {\r\n return ruleResult.entityType === Compliance.ReturnFormFieldEntityType.Filing ||\r\n ruleResult.entityType === Compliance.ReturnFormFieldEntityType.FilingBatch;\r\n }\r\n\r\n hasLink(ruleResult: Compliance.ReturnFormFieldRuleResultModel): boolean {\r\n return [Compliance.ReturnFormFieldEntityType.Company,\r\n Compliance.ReturnFormFieldEntityType.Assessor,\r\n Compliance.ReturnFormFieldEntityType.Parcel,\r\n Compliance.ReturnFormFieldEntityType.ParcelDescriptor,\r\n Compliance.ReturnFormFieldEntityType.GeneralReturnSetting,\r\n Compliance.ReturnFormFieldEntityType.Site,\r\n Compliance.ReturnFormFieldEntityType.SiteDescriptor].includes(ruleResult.entityType);\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n revert(): void {\r\n this.result = {\r\n deleteConfirmed: true,\r\n override: this.override,\r\n rowVersion: this.rowVersion\r\n };\r\n\r\n this._modalRef.hide();\r\n }\r\n\r\n getFieldEntityName(typeEnumVal : Compliance.ReturnFormFieldEntityType) : string{\r\n return _.find(this.fieldEntityTypes, x => x.value === typeEnumVal).name;\r\n }\r\n\r\n getEntityUrl(ruleResult: Compliance.ReturnFormFieldRuleResultModel): string {\r\n let url = '';\r\n\r\n if ([Compliance.ReturnFormFieldEntityType.Company,\r\n Compliance.ReturnFormFieldEntityType.GeneralReturnSetting,\r\n Compliance.ReturnFormFieldEntityType.SupplementalField].includes(ruleResult.entityType)) {\r\n url = this._routerService.getHrefFromState('company', { 'companyId': ruleResult.entityId });\r\n } else if (ruleResult.entityType === Compliance.ReturnFormFieldEntityType.Assessor) {\r\n url = this._routerService.getHrefFromState('assessorRedirect', { 'entityID': ruleResult.entityId });\r\n } else if (ruleResult.entityType === Compliance.ReturnFormFieldEntityType.Parcel ||\r\n ruleResult.entityType === Compliance.ReturnFormFieldEntityType.ParcelDescriptor) {\r\n url = this._routerService.getHrefFromState('parcelRedirect', { 'entityID': ruleResult.entityId });\r\n } else if (ruleResult.entityType === Compliance.ReturnFormFieldEntityType.Site ||\r\n ruleResult.entityType === Compliance.ReturnFormFieldEntityType.SiteDescriptor) {\r\n url = this._routerService.getHrefFromState('siteRedirect', { 'entityID': ruleResult.entityId });\r\n }\r\n\r\n return url;\r\n }\r\n}\r\n","import { ElementRef, NgZone, Renderer2 } from '@angular/core';\r\nimport { Subscription, timer } from 'rxjs';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { ReturnPreviewFormOverrideEditComponent, ReturnPreviewFormOverrideEditParams } from '../../Compliance/Return/Return-Parts/Preview/Form-Viewer/Override-Edit/returnPreviewFormOverrideEdit.component';\r\nimport { ScriptLoaderService, ScriptLocations } from 'src/app/UI-Lib/Utilities/scriptLoader.service';\r\nimport { Constants } from 'src/app/constants.new';\r\n//todo: de-couple the override edit component from compliance return module\r\n\r\ndeclare const pdfjsLib: any;\r\ndeclare const pdfjsViewer: any;\r\n\r\nconst MAX_RENDERED_PAGES: number = 80; // number to render at once, after double this, truncate\r\nconst FULL_FIELD_NAME_REGEX = /\\]\\.([^\\]]*)(\\[\\d+\\])?$/;\r\nconst ACCOUNT_PARAMETER_REGEX = /^account-\\d+$/i;\r\nconst UI_ACCOUNT_INDEX_PARAMETER_REGEX = /^uiaccountindex-(\\d+)$/i;\r\n\r\nexport interface FieldOverride {\r\n formElements: Element[];\r\n fieldName: string;\r\n overrideValue: string;\r\n}\r\n\r\nexport class FieldOverrideHolder {\r\n private _savedOverrides: Map = new Map();\r\n private _overrides: Map = new Map();\r\n\r\n get overrides(): FieldOverride[] {\r\n return Array\r\n .from(this._overrides.values())\r\n .sort((a, b) => {\r\n const aR = a.formElements[0].getBoundingClientRect();\r\n const bR = b.formElements[0].getBoundingClientRect();\r\n if (aR.top < bR.top) {\r\n return -1;\r\n } else if (aR.top > bR.top) {\r\n return 1;\r\n } else {\r\n return (aR.left < bR.left) ? -1 : 1;\r\n }\r\n });\r\n }\r\n\r\n getSaved(fieldName: string): Compliance.FormOverrideModel {\r\n return this._savedOverrides.get(fieldName);\r\n }\r\n\r\n getFieldOverride(fieldName: string): FieldOverride {\r\n return this._overrides.get(fieldName);\r\n }\r\n\r\n saveOverride(override: Compliance.FormOverrideModel, fieldName?: string): void {\r\n this._savedOverrides.set(fieldName || override.fieldName, override);\r\n }\r\n\r\n addOverride(override: FieldOverride): FieldOverride {\r\n const existingOverride = this._overrides.get(override.fieldName);\r\n if (existingOverride) {\r\n override.formElements = [...existingOverride.formElements, ...override.formElements];\r\n }\r\n this._overrides.set(override.fieldName, override);\r\n return override;\r\n }\r\n\r\n deleteOverride(override: FieldOverride): void {\r\n this._overrides.delete(override.fieldName);\r\n }\r\n\r\n renumberOverrides(): void {\r\n const overrides = this.overrides;\r\n for (let i = 0, len = overrides.length; i < len; i++) {\r\n overrides[i].formElements.forEach(elem => {\r\n //const elem: Element = this.overrides[i].formElement;\r\n const followingElement = elem.parentElement.querySelector('.overrideInfo');\r\n if (followingElement) {\r\n followingElement.innerHTML = `${i + 1}`;\r\n }\r\n });\r\n }\r\n }\r\n\r\n reset(): void {\r\n this._overrides = new Map();\r\n }\r\n}\r\n\r\nexport abstract class PDFViewerBase {\r\n\r\n constructor(\r\n protected _PDF_OUTPUT_HOLDER_QUERY_SELECTOR: string,\r\n protected _modalService: WeissmanModalService,\r\n protected _scriptLoaderService: ScriptLoaderService,\r\n protected _constants: Constants,\r\n protected _renderer: Renderer2,\r\n protected _zone: NgZone\r\n ) { }\r\n\r\n public overrideHolder: FieldOverrideHolder = new FieldOverrideHolder();\r\n public showPreviousPagesVisible: boolean = false;\r\n public showNextPagesVisible: boolean = false;\r\n public zoomPercentage: number = 100;\r\n public zoomScaleUpdating: boolean;\r\n protected _pdfPageViews: any = {};\r\n protected _annotations: any = {};\r\n protected _fieldIdMap: { [field: string]: string } = {};\r\n protected _idFieldMap: { [id: string]: { fieldName: string, fullName: string, elements: Element[] } } = {};\r\n protected _oldFormatOverrides: { [shortFieldName: string]: { override: FieldOverride, rowVersion: number[] } } = {};\r\n protected _accountlessNameIdMap: { [accountlessName: string]: string[] };\r\n protected _multiAccountFieldMap: { [fieldName: string]: number } = {};\r\n protected readonly MODIFIED_FIELD_CSS_CLASS: string = 'pdf-modified-field';\r\n //protected _fieldDataLookup: Map = new Map();\r\n protected _fieldDataLookup: { [fullName: string]: Compliance.ReturnFormFieldDataModel } = {};\r\n protected _fieldDataLookupByShortName: { [shortName: string]: Compliance.ReturnFormFieldDataModel } = {};\r\n protected _originalValues: { [fullName: string]: string } = {};\r\n protected _originalValuesByShortName: { [shortName: string]: string; } = {};\r\n protected isReadOnly: boolean = true;\r\n protected isAppealForm: boolean = false;\r\n private pdfDocument: any;\r\n private pageDivs: any = {};\r\n private scrollExtentSubscription: Subscription;\r\n private currentlyRenderedPageNums: Set = new Set();\r\n private _zoomScale: number = 1.0;\r\n\r\n calculateLowestRenderedPage(): number {\r\n let lowestRenderedPage;\r\n const highestPageNumberInDoc = this.pdfDocument.numPages;\r\n for (let pageNum = 1; pageNum < highestPageNumberInDoc; pageNum++) {\r\n if (this.currentlyRenderedPageNums.has(pageNum)) {\r\n lowestRenderedPage = pageNum;\r\n break;\r\n }\r\n }\r\n return lowestRenderedPage;\r\n }\r\n\r\n calculateHighestRenderedPage() {\r\n let highestRenderedPage = 1;\r\n const highestPageNumberInDoc = this.pdfDocument.numPages;\r\n for (let pageNum = highestPageNumberInDoc; pageNum > 0; pageNum--) {\r\n if (this.currentlyRenderedPageNums.has(pageNum)) {\r\n highestRenderedPage = pageNum;\r\n break;\r\n }\r\n }\r\n return highestRenderedPage;\r\n }\r\n\r\n showPreviousPages() {\r\n let lowestRenderedPage = this.calculateLowestRenderedPage();\r\n const highestPageNumberInDoc = this.pdfDocument.numPages;\r\n for (let pageNum = 1; pageNum < highestPageNumberInDoc; pageNum++) {\r\n if (this.currentlyRenderedPageNums.has(pageNum)) {\r\n lowestRenderedPage = pageNum;\r\n break;\r\n }\r\n }\r\n if (lowestRenderedPage > 1) {\r\n let lowestPageToRender;\r\n if (lowestRenderedPage <= MAX_RENDERED_PAGES) {\r\n lowestPageToRender = 1;\r\n } else {\r\n lowestPageToRender = lowestRenderedPage - MAX_RENDERED_PAGES;\r\n }\r\n this.renderPagesWithAnnotations(lowestPageToRender, lowestRenderedPage - 1).then(() => {\r\n this.updateNextPageVisibility();\r\n }).then(() => {\r\n this.checkForPageDeletions(true);\r\n });\r\n }\r\n }\r\n\r\n showNextPages() {\r\n //calculate final page\r\n const highestRenderedPage = this.calculateHighestRenderedPage();\r\n const highestPageNumberInDoc = this.pdfDocument.numPages;\r\n if (highestRenderedPage < highestPageNumberInDoc) {\r\n let topPageToRender;\r\n if ((highestPageNumberInDoc - highestRenderedPage) > MAX_RENDERED_PAGES) {\r\n topPageToRender = highestRenderedPage + MAX_RENDERED_PAGES;\r\n } else {\r\n topPageToRender = highestPageNumberInDoc;\r\n }\r\n this.renderPagesWithAnnotations(highestRenderedPage + 1, topPageToRender).then(() => {\r\n this.updateNextPageVisibility();\r\n }).then(() => {\r\n this.checkForPageDeletions(false);\r\n });\r\n }\r\n }\r\n\r\n\r\n checkForPageDeletions(deleteFromUpperEnd: boolean): void {\r\n if (this.currentlyRenderedPageNums.size > MAX_RENDERED_PAGES * 2) {\r\n if (!deleteFromUpperEnd) {\r\n const lowestRenderedPage = this.calculateLowestRenderedPage();\r\n this.deletePages(lowestRenderedPage, lowestRenderedPage + MAX_RENDERED_PAGES - 1);\r\n } else {\r\n const highestRenderedPage = this.calculateHighestRenderedPage();\r\n this.deletePages(highestRenderedPage - MAX_RENDERED_PAGES + 1, highestRenderedPage);\r\n }\r\n this.updateNextPageVisibility();\r\n }\r\n }\r\n\r\n deletePages(lowestPageToDelete, highestPageToDelete) {\r\n for (let pageNum = lowestPageToDelete; pageNum <= highestPageToDelete; pageNum++) {\r\n this.pageDivs[pageNum].innerHTML = '';\r\n const pdfPage = this._pdfPageViews[pageNum];\r\n this._pdfPageViews[pageNum] = null;\r\n pdfPage.destroy();\r\n this.currentlyRenderedPageNums.delete(pageNum);\r\n }\r\n }\r\n\r\n updateZoomScale(value: number): void {\r\n this._zoomScale = value;\r\n this.zoomScaleUpdating = true;\r\n this.zoomPercentage = Math.floor(value * 100);\r\n const lowest = this.calculateLowestRenderedPage() || 1;\r\n const highest = this.calculateHighestRenderedPage();\r\n let finished = lowest === highest ? (highest + 1) : highest;\r\n for (let i = lowest, len = highest; i <= len; i++) {\r\n const pdfPageView = this._pdfPageViews[i];\r\n pdfPageView.update({ scale: this._zoomScale });\r\n this._annotations[i].forEach(annotation => {\r\n if (annotation.fieldName) {\r\n this._fieldIdMap[annotation.fieldName] = annotation.id;\r\n }\r\n });\r\n\r\n this._zone.runOutsideAngular(() => {\r\n pdfPageView.draw().then(() => {\r\n finished -= 1;\r\n if (finished === lowest) {\r\n this._zone.run(() => this.zoomScaleUpdating = false);\r\n }\r\n });\r\n });\r\n }\r\n }\r\n\r\n scrollToElement(element: Element) {\r\n element.scrollIntoView({ behavior: 'smooth' });\r\n }\r\n\r\n public abstract onPdfFieldChange(event): void;\r\n\r\n // render n, offer a next n - add a paginator or do infinite scroll?\r\n protected async loadPdfDocument(params): Promise {\r\n await this.addPdfViewer();\r\n\r\n if (this.scrollExtentSubscription) {\r\n this.scrollExtentSubscription.unsubscribe();\r\n }\r\n\r\n this.pdfDocument = await pdfjsLib.getDocument(params).promise;\r\n this.currentlyRenderedPageNums = new Set();\r\n const numPages = this.pdfDocument.numPages;\r\n const lastPageToRender = numPages > MAX_RENDERED_PAGES ? MAX_RENDERED_PAGES : numPages;\r\n this.renderPageDivs(numPages);\r\n return this.renderPagesWithAnnotations(1, lastPageToRender).then(() => {\r\n this.setupScrollObservable();\r\n });\r\n }\r\n\r\n protected updateNextPageVisibility() {\r\n this.showNextPagesVisible = (!this.currentlyRenderedPageNums.has(this.pdfDocument.numPages));\r\n this.showPreviousPagesVisible = (!this.currentlyRenderedPageNums.has(1));\r\n }\r\n\r\n protected disposePdfDocument(): void {\r\n if (this.scrollExtentSubscription) {\r\n this.scrollExtentSubscription.unsubscribe();\r\n }\r\n this.getElementRef().nativeElement.querySelector(this._PDF_OUTPUT_HOLDER_QUERY_SELECTOR).textContent = '';\r\n if (this._pdfPageViews) {\r\n this.currentlyRenderedPageNums.forEach(pageNum => {\r\n if (this._pdfPageViews[pageNum]) {\r\n this._pdfPageViews[pageNum].destroy();\r\n }\r\n });\r\n }\r\n this._pdfPageViews = {};\r\n this.overrideHolder.reset();\r\n }\r\n\r\n protected _createOverrideUI(overrideUIElement: FieldOverride) {\r\n const override = this.overrideHolder.addOverride(overrideUIElement);\r\n this._deleteOverrideMarker(override);\r\n this._createOverrideMarker(override);\r\n }\r\n\r\n protected _createOverrideMarker(override: FieldOverride, isSaved: boolean = true) {\r\n override.formElements.forEach(formElement => {\r\n let elem;\r\n if (!formElement.parentElement.querySelector('.overrideInfo')) {\r\n elem = formElement.ownerDocument.createElement('div');\r\n const fieldInfo = this._getFieldData(override.fieldName);\r\n const ruleResults = fieldInfo ? fieldInfo.ruleResults : null;\r\n elem.innerHTML = 'i';\r\n elem.className = `overrideInfo ${(isSaved ? 'saved' : 'unsaved')}`;\r\n elem.addEventListener('click', () => { this._clickOverride(override, ruleResults); });\r\n } else {\r\n elem = formElement.parentElement.querySelector('.overrideInfo');\r\n elem.className = `overrideInfo ${(isSaved ? 'saved' : 'unsaved')}`;\r\n }\r\n this._renderer.appendChild(formElement.parentElement, elem);\r\n });\r\n }\r\n\r\n // The fieldName can be a full name or a short name\r\n protected _getOriginalValue(fieldName: string) {\r\n if (this._originalValues[fieldName]) {\r\n return this._originalValues[fieldName];\r\n }\r\n else {\r\n return this._originalValuesByShortName[fieldName];\r\n }\r\n }\r\n\r\n // The fieldName can be a full name or a short name\r\n protected _getFieldData(fieldName: string) {\r\n if (this._fieldDataLookup[fieldName]) {\r\n return this._fieldDataLookup[fieldName];\r\n }\r\n else {\r\n return this._fieldDataLookupByShortName[fieldName];\r\n }\r\n }\r\n\r\n protected async _clickOverride(override: FieldOverride, ruleResults: Compliance.ReturnFormFieldRuleResultModel[] = null, inputElem: HTMLInputElement = null): Promise {\r\n const saved = override ? this.overrideHolder.getSaved(override.fieldName) : null;\r\n\r\n // The click event creates a closure when it is first created, this can lead to loading stale data\r\n // Try to retrieve the latest stored values if they are available\r\n const storedOverride = override ? this.overrideHolder.getFieldOverride(override.fieldName) : null;\r\n\r\n const params: ReturnPreviewFormOverrideEditParams = {\r\n override: storedOverride || override,\r\n oldValue: override ? this._getOriginalValue(override.fieldName) : inputElem.value,\r\n rowVersion: override && saved ? saved.rowVersion : null,\r\n ruleResults: ruleResults,\r\n canEdit: this.isAppealForm\r\n };\r\n\r\n const result = await this._modalService.showAsync(ReturnPreviewFormOverrideEditComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (result.deleteConfirmed) {\r\n this._deleteOverride(result.override, result.rowVersion);\r\n }\r\n }\r\n\r\n protected _deleteInfoMarker(overrideUIElement: FieldOverride) {\r\n overrideUIElement.formElements.forEach(formElement => {\r\n const followingElement = formElement.parentElement.querySelector('.fieldInfo');\r\n if (followingElement) {\r\n this._renderer.removeChild(followingElement.parentNode, followingElement);\r\n }\r\n });\r\n }\r\n\r\n protected _deleteOverrideUI(overrideUIElement: FieldOverride) {\r\n const displayValue = this._getOriginalValue(overrideUIElement.fieldName);\r\n (overrideUIElement.formElements as any[]).forEach(formElement => {\r\n // restore original value\r\n if (formElement.type === 'checkbox') {\r\n formElement.checked = this._isCheckedValue(displayValue);\r\n } else {\r\n formElement.value = displayValue;\r\n }\r\n this.overrideHolder.deleteOverride(overrideUIElement);\r\n this._deleteOverrideMarker(overrideUIElement);\r\n const fieldInfo = this._getFieldData(overrideUIElement.fieldName);\r\n this._createInfoMarker(formElement, fieldInfo);\r\n });\r\n this.overrideHolder.renumberOverrides();\r\n }\r\n\r\n protected _createInfoMarker(element: HTMLInputElement, fieldInfo: Compliance.ReturnFormFieldDataModel) {\r\n const doc = element.ownerDocument;\r\n const elem = doc.createElement('div');\r\n elem.innerHTML = 'i';\r\n elem.className = 'fieldInfo';\r\n elem.addEventListener('click', () => { this._clickFieldInfo(fieldInfo, element); });\r\n this._renderer.appendChild(element.parentElement, elem);\r\n }\r\n\r\n protected isFullFieldName(fieldName: string) {\r\n return fieldName.indexOf(']') > -1;\r\n }\r\n\r\n protected shortenFullFieldName(fullName: string, skipUIAccountIndex?: boolean) {\r\n if (this.isFullFieldName(fullName)) {\r\n const match = FULL_FIELD_NAME_REGEX.exec(fullName);\r\n if (match && match[1]) {\r\n // After shortening, we need to account for collisions based on the \"Account\" parameter. It's possible for the first\r\n // page of a form to have something like Account-1 and Account-2 parameters, refering to per-account fields that occur\r\n // before the repeating portion of a multi-account form, then see those same parameters again later. To deal with this,\r\n // remove the account parameter when shortening a full name and add back an artificial parameter called UIAccountIndex\r\n // so we can link this field back to it's multi-account data later\r\n const accountIndex = this._multiAccountFieldMap[fullName];\r\n if (accountIndex !== undefined) {\r\n let result = match[1]\r\n .split('\\\\.')\r\n .filter(x => !ACCOUNT_PARAMETER_REGEX.test(x))\r\n .join('\\\\.');\r\n if (!skipUIAccountIndex) {\r\n result = `${result }\\\\.UIAccountIndex-${ accountIndex}`;\r\n }\r\n return result;\r\n } else {\r\n return match[1];\r\n }\r\n\r\n }\r\n }\r\n\r\n return fullName;\r\n }\r\n\r\n protected getUIAccountIndex(shortName: string): number {\r\n const paramMatch = shortName\r\n .split('\\\\.')\r\n .map(x => UI_ACCOUNT_INDEX_PARAMETER_REGEX.exec(x))\r\n .filter(x => x)[0];\r\n\r\n return paramMatch ? +paramMatch[1] : null;\r\n }\r\n\r\n protected removeUIAccountIndex(shortName: string): string {\r\n return shortName\r\n .split('\\\\.')\r\n .filter(x => !UI_ACCOUNT_INDEX_PARAMETER_REGEX.test(x))\r\n .join('\\\\.');\r\n }\r\n\r\n protected setUIAccountIndex(shortName: string, index: number): string {\r\n return `${this.removeUIAccountIndex(shortName) }\\\\.UIAccountIndex-${ index}`;\r\n }\r\n\r\n // review mode is a special case where we want to still see overrides (and hence calculate data, even though we're only showing the flattened form and are in read only)\r\n protected async _loadPreviewForForm(blob: Blob, formData: Compliance.ReturnFormResultModel, overrides: Compliance.FormOverrideModel[], showFormForReviewOnly: boolean = false): Promise {\r\n return new Promise((resolve, reject) => {\r\n if (formData) {\r\n this._multiAccountFieldMap = {};\r\n if (formData.perAccountFieldLookup) {\r\n Object.keys(formData.perAccountFieldLookup).forEach(accountIndex => {\r\n formData.perAccountFieldLookup[accountIndex].forEach(fieldName => {\r\n this._multiAccountFieldMap[fieldName] = +accountIndex;\r\n });\r\n });\r\n }\r\n }\r\n\r\n const fileReader = new FileReader();\r\n fileReader.onload = async () => {\r\n this.showNextPagesVisible = false;\r\n this.showPreviousPagesVisible = false;\r\n\r\n await this.loadPdfDocument({ data: fileReader.result });\r\n\r\n await this._loadFormData(formData, overrides, showFormForReviewOnly);\r\n\r\n this._postFormLoadAction();\r\n resolve();\r\n\r\n };\r\n fileReader.readAsArrayBuffer(blob);\r\n });\r\n }\r\n\r\n protected async _loadFormData(formData: Compliance.ReturnFormResultModel, overrides: Compliance.FormOverrideModel[], showFormForReviewOnly: boolean = false): Promise {\r\n this.updateNextPageVisibility();\r\n this.overrideHolder.reset();\r\n this._fieldDataLookup = {};\r\n if (!formData) {\r\n return;\r\n }\r\n\r\n // let overrideLookup: { [accountIndex: number]: { [fieldName: string]: Compliance.FormOverrideModel } };\r\n const overrideLookup = overrides.reduce((acc, override) => {\r\n const accountIndex = this.isFullFieldName(override.fieldName) ? 0 : this.resolveAccountIndex(override);\r\n acc[accountIndex] = acc[accountIndex] || {};\r\n acc[accountIndex][override.fieldName] = override;\r\n return acc;\r\n }, {});\r\n\r\n // const overrideMap: Map = overrides.reduce((acc, override) => {\r\n // acc.set(override.fieldName, override);\r\n // return acc;\r\n // }, new Map());\r\n\r\n // create info markers as well as overrides, include info in overrides for locations\r\n formData.fieldData.forEach((x: Compliance.ReturnFormFieldDataModel) => {\r\n const inputElem: HTMLInputElement = this._getInputByFieldName(x.fullName);\r\n\r\n if (inputElem && !(formData.fieldsToHide && formData.fieldsToHide.find(i => i === x.fullName))) {\r\n const shortName = this.shortenFullFieldName(x.fullName);\r\n this._originalValues[x.fullName] = x.value;\r\n this._originalValuesByShortName[shortName] = x.value;\r\n let displayValue = x.value;\r\n\r\n // fieldInfos\r\n this._fieldDataLookup[x.fullName] = x;\r\n this._fieldDataLookupByShortName[shortName] = x;\r\n\r\n const fieldIndex = this._multiAccountFieldMap[x.fullName] || 0;\r\n\r\n let savedOverride: Compliance.FormOverrideModel = undefined;\r\n\r\n if (overrideLookup[fieldIndex]) {\r\n\r\n const shortNameWithoutAccountIndex = this.shortenFullFieldName(x.fullName, true);\r\n const fullNameOverride = overrideLookup[fieldIndex][x.fullName];\r\n const shortNameOverride = overrideLookup[fieldIndex][shortNameWithoutAccountIndex];\r\n\r\n savedOverride = fullNameOverride || shortNameOverride;\r\n }\r\n\r\n if (savedOverride) {\r\n if (!this.isFullFieldName(savedOverride.fieldName) && this._multiAccountFieldMap[x.fullName] !== undefined) {\r\n savedOverride.fieldName = this.setUIAccountIndex(savedOverride.fieldName, fieldIndex);\r\n }\r\n\r\n const overrideUIElement: FieldOverride = {\r\n formElements: [inputElem],\r\n overrideValue: savedOverride.value,\r\n fieldName: savedOverride.fieldName\r\n };\r\n\r\n if (this.isFullFieldName(savedOverride.fieldName)) {\r\n const shortFieldName = this.shortenFullFieldName(savedOverride.fieldName);\r\n if (shortFieldName !== savedOverride.fieldName) {\r\n this._oldFormatOverrides[shortFieldName] = {\r\n override: overrideUIElement,\r\n rowVersion: savedOverride.rowVersion\r\n };\r\n }\r\n }\r\n\r\n this.overrideHolder.saveOverride(savedOverride, savedOverride.fieldName);\r\n this._createOverrideUI(overrideUIElement);\r\n displayValue = savedOverride.value;\r\n inputElem.classList.add(this.MODIFIED_FIELD_CSS_CLASS);\r\n } else {\r\n if (x.ruleResults && x.ruleResults.length > 0 && x.ruleResults[0].entityName) {\r\n // need rule result info\r\n this._createInfoMarker(inputElem, x);\r\n }\r\n }\r\n\r\n // update value from data unless in locked mode\r\n if (!showFormForReviewOnly) {\r\n if (inputElem.type === 'checkbox') {\r\n inputElem.checked = this._isCheckedValue(displayValue);\r\n } else {\r\n inputElem.value = displayValue;\r\n }\r\n }\r\n\r\n if ((x.fullName.indexOf('SignatureImage') > 0) && x.value !== '') {\r\n const signatureDiv = inputElem.ownerDocument.createElement('div');\r\n signatureDiv.setAttribute('style', `width: 100%; position: absolute; display: block; left: 0px; top: 0px; overflow: visible; height: ${inputElem.parentElement.style.height};`);\r\n signatureDiv.innerHTML = ``;\r\n this._renderer.appendChild(inputElem.parentElement, signatureDiv);\r\n inputElem.style.visibility = 'hidden';\r\n }\r\n }\r\n });\r\n\r\n this.overrideHolder.renumberOverrides();\r\n this._updateInputFieldReadOnlyAttributes();\r\n }\r\n\r\n protected _isCheckedValue(value: string): boolean {\r\n return ['1', 'on', 'yes'].some(x => (value && value.toLowerCase()) === x);\r\n }\r\n\r\n protected _updateInputFieldReadOnlyAttributes() {\r\n this.getElementRef().nativeElement.querySelectorAll('.annotationLayer input, .annotationLayer textarea').forEach(element => {\r\n // WR-6574 readonly properties do not work on checkboxes/radio buttons so changed to disabled on all inputs\r\n element.disabled = this.isReadOnly;\r\n });\r\n }\r\n\r\n // Overload this to take action after form loaded\r\n protected _postFormLoadAction() {\r\n return null;\r\n }\r\n\r\n protected _deleteOverrideMarker(override: FieldOverride) {\r\n override.formElements.forEach(formElement => {\r\n const followingElement = formElement.parentElement.querySelector('.overrideInfo');\r\n if (followingElement) {\r\n this._renderer.removeChild(followingElement.parentNode, followingElement);\r\n }\r\n });\r\n }\r\n\r\n protected abstract getElementRef(): ElementRef;\r\n protected abstract isShowingAnnotations(): boolean;\r\n protected abstract _deleteOverride(override: FieldOverride, rowVersion: number[]): Promise;\r\n protected abstract resolveAccountIndex(override: Compliance.FormOverrideModel): number;\r\n\r\n private async addPdfViewer() {\r\n if (await this._scriptLoaderService.loadScript(ScriptLocations.PDFJSLib, true))\r\n {\r\n pdfjsLib.GlobalWorkerOptions.workerSrc = `${this._constants.PdfJsBase}build/pdf.worker.mjs`;\r\n await this._scriptLoaderService.loadScript(ScriptLocations.PDFJSViewer, true);\r\n }\r\n }\r\n\r\n private setupScrollObservable() {\r\n this.scrollExtentSubscription = timer(200, 50).subscribe(() => {\r\n if (!this.showNextPagesVisible && !this.showPreviousPagesVisible) {\r\n return;\r\n }\r\n const showPreviousPagesButton: Element = this.getElementRef().nativeElement.querySelector('#showPreviousPagesButton');\r\n const showNextPagesButton: Element = this.getElementRef().nativeElement.querySelector('#showNextPagesButton');\r\n if (showPreviousPagesButton && this.showPreviousPagesVisible && showPreviousPagesButton.getBoundingClientRect().top > 0) {\r\n this.showNextPagesVisible = false;\r\n this.showPreviousPagesVisible = false;\r\n this.showPreviousPages();\r\n } else if (showNextPagesButton && this.showNextPagesVisible && showNextPagesButton.getBoundingClientRect().top < window.innerHeight) {\r\n this.showNextPagesVisible = false;\r\n this.showPreviousPagesVisible = false;\r\n this.showNextPages();\r\n }\r\n });\r\n\r\n }\r\n\r\n // split out div creation, keep index\r\n private renderPagesWithAnnotations(firstPage: number, lastPage: number): Promise {\r\n const annotationsPromise: Promise[] = [];\r\n this._fieldIdMap = {};\r\n for (let pageNum = firstPage; pageNum <= lastPage; pageNum++) {\r\n //pageNums.forEach(pageNum => {\r\n annotationsPromise.push(\r\n this.pdfDocument.getPage(pageNum).then(pdfPage => {\r\n // creating the page view with default parameters.\r\n const pdfPageViewParams: any = {\r\n container: this.pageDivs[pageNum],\r\n id: pageNum,\r\n scale: this._zoomScale,\r\n defaultViewport: pdfPage.getViewport({ scale: this._zoomScale }),\r\n eventBus: new pdfjsViewer.EventBus(),\r\n // Note we used to set textLayerMode to 0 (disable), but that controls copy/paste\r\n // functionality; there isn't a good reason to disable that\r\n textLayerMode: 1, // ENABLE\r\n annotationMode: 1 // ENABLE\r\n };\r\n\r\n if (this.isShowingAnnotations()) {\r\n pdfPageViewParams.annotationMode = 2; // ENABLE_FORMS\r\n // In pdf.js v2 this is how interactive forms were turned on; it seems in v4 the\r\n // annotationMode setting controls it.\r\n //pdfPageViewParams.renderInteractiveForms = true;\r\n }\r\n\r\n const pdfPageView = new pdfjsViewer.PDFPageView(pdfPageViewParams);\r\n\r\n this._pdfPageViews[pageNum] = (pdfPageView);\r\n this.currentlyRenderedPageNums.add(pageNum);\r\n\r\n // associates the actual page with the view, and drawing it\r\n pdfPageView.setPdfPage(pdfPage);\r\n\r\n return pdfPage.getAnnotations().then(result => {\r\n this._annotations[pageNum] = result;\r\n result.forEach(annotation => {\r\n if (annotation.fieldName) {\r\n this._fieldIdMap[annotation.fieldName] = annotation.id;\r\n }\r\n });\r\n return pdfPageView.draw();\r\n });\r\n })\r\n\r\n );\r\n }\r\n\r\n return Promise.all(annotationsPromise).then(result => {\r\n this._idFieldMap = {};\r\n this._accountlessNameIdMap = {};\r\n const fieldElementMaps: { [shortName: string]: Element[] } = {};\r\n\r\n Object.keys(this._fieldIdMap).forEach(fullName => {\r\n const id = this._fieldIdMap[fullName];\r\n const shortName = this.shortenFullFieldName(fullName);\r\n fieldElementMaps[shortName] = fieldElementMaps[shortName] || [];\r\n fieldElementMaps[shortName].push(\r\n this.getElementRef().nativeElement.querySelector(`[data-annotation-id='${ id }']>input, [data-annotation-id='${ id }']>textarea`)\r\n );\r\n\r\n const accountIndex = this.getUIAccountIndex(shortName);\r\n if (accountIndex !== null) {\r\n const accountlessName = this.removeUIAccountIndex(shortName);\r\n this._accountlessNameIdMap[accountlessName] = this._accountlessNameIdMap[accountlessName] || [];\r\n this._accountlessNameIdMap[accountlessName].push(id);\r\n }\r\n\r\n this._idFieldMap[id] = {\r\n fieldName: shortName,\r\n fullName: fullName,\r\n elements: fieldElementMaps[shortName]\r\n };\r\n });\r\n\r\n return result;\r\n });\r\n }\r\n\r\n // split out div creation, keep index\r\n private renderPageDivs(numberOfPages: number): void {\r\n this.pageDivs = {};\r\n const outerHolder: Element = this.getElementRef().nativeElement.querySelector(this._PDF_OUTPUT_HOLDER_QUERY_SELECTOR);\r\n outerHolder.innerHTML = '';\r\n for (let pageNum = 1; pageNum <= numberOfPages; pageNum++) {\r\n const div: Element = outerHolder.ownerDocument.createElement('div');\r\n div.className = 'pageHolderDiv';\r\n this._renderer.appendChild(outerHolder, div);\r\n this.pageDivs[pageNum] = div;\r\n }\r\n }\r\n\r\n private _getInputByFieldName(fieldName: string): any {\r\n const id = this._fieldIdMap[fieldName];\r\n if (id) {\r\n const element = this.getElementRef().nativeElement.querySelector(`section[data-annotation-id='${id}'] input, section[data-annotation-id='${id}'] textarea, section[data-annotation-id='${id}'] image`);\r\n return element;\r\n }\r\n return null;\r\n }\r\n\r\n private _clickFieldInfo(fieldInfo: Compliance.ReturnFormFieldDataModel, inputElem: HTMLInputElement) {\r\n this._clickOverride(null, fieldInfo.ruleResults, inputElem);\r\n }\r\n}\r\n","import { HelpContent } from '../../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const RETURN_PREVIEW_FORM_VIEWER_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'return-preview-form-viewer.show-field-locations',\r\n tooltipText: 'Shows where the data came from for each field populated by the system.'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-viewer.apply-override',\r\n tooltipText: 'Determines if overrides are applied only to this form or to all forms in the list.'\r\n },\r\n {\r\n helpContentId: 'return-preview-form-viewer.existing-override',\r\n tooltipText: 'Overrides the existing override'\r\n }\r\n];\r\n","
\r\n
\r\n Zoom:\r\n \r\n \r\n %\r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n","import { Component, EventEmitter, HostListener, Input, Output } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'ws-pdf-controls',\r\n templateUrl: './pdfControls.component.html',\r\n styleUrls: ['./pdfControls.component.scss']\r\n})\r\nexport class PDFControlsComponent {\r\n @Input() canZoom: boolean = true;\r\n @Input() zoomScaleUpdating: boolean;\r\n @Input() zoomStep: number = 10;\r\n @Input() min: number = 10;\r\n @Input() max: number = 300;\r\n @Input()\r\n set zoomPercentage(pct: number) {\r\n this._zoomValue = pct;\r\n }\r\n get zoomPercentage(): number {\r\n return this._zoomValue;\r\n }\r\n\r\n @Output() zoomChanged: EventEmitter = new EventEmitter();\r\n\r\n private _zoomValue = 100;\r\n\r\n @HostListener('keyup', ['$event'])\r\n keyEvent(event: KeyboardEvent) {\r\n if (event.keyCode === 13) {\r\n this.submitZoomValue();\r\n }\r\n event.stopPropagation();\r\n }\r\n\r\n\r\n zoomOut(): void {\r\n const newValue = this._zoomValue % 10 === 0 ? this._zoomValue - this.zoomStep : this._zoomValue;\r\n this.setZoomValue(Math.floor(newValue / 10) * 10);\r\n this.submitZoomValue();\r\n }\r\n\r\n zoomIn(): void {\r\n this.setZoomValue(Math.floor((this._zoomValue + this.zoomStep) / 10) * 10);\r\n this.submitZoomValue();\r\n }\r\n\r\n setZoomValue(value: number): void {\r\n this._zoomValue = value;\r\n }\r\n\r\n submitZoomValue(): void {\r\n if (!this._zoomValue) {\r\n this._zoomValue = 100;\r\n }\r\n this._zoomValue = this._zoomValue >= this.max ? this.max : this._zoomValue;\r\n this._zoomValue = this._zoomValue <= this.min ? this.min : this._zoomValue;\r\n this.zoomChanged.next(Math.floor(this._zoomValue) / 100);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n

Unsaved Overrides ({{unsaved.length}})

\r\n
\r\n {{override.index}} -\r\n {{ (override.overrideValue ? override.overrideValue : '(value cleared)') }}\r\n
\r\n
\r\n
\r\n
\r\n

Form Overrides ({{overrideHolder.overrides.length}})

\r\n
\r\n {{i + 1}} - {{ (override.overrideValue ? override.overrideValue : '(value cleared)') }}\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { FieldOverrideHolder } from '../../../../../../Common/PDFViewer/pdfViewerBase';\r\nimport { FieldOverrideWithRowVersion } from '../../returnPreview.service';\r\n\r\nimport { reduce, map } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\n\r\ninterface UnsavedOverride extends FieldOverrideWithRowVersion {\r\n index: number;\r\n isExisting: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'override-changes',\r\n templateUrl: './returnPreviewOverrideChanges.component.html',\r\n styleUrls: ['./returnPreviewOverrideChanges.component.scss']\r\n})\r\nexport class ReturnPreviewOverrideChangesComponent {\r\n @Input() overrideHolder: FieldOverrideHolder;\r\n @Input() canPreview: boolean;\r\n @Input() set unsavedOverrides(overrides: FieldOverrideWithRowVersion[]) {\r\n if (overrides && overrides.length) {\r\n this._setUnsavedOverrides(overrides);\r\n } else {\r\n this.unsaved = [];\r\n }\r\n };\r\n\r\n @Output() scrollToElement: EventEmitter = new EventEmitter();\r\n @Output() saveClicked: EventEmitter = new EventEmitter();\r\n @Output() resetClicked: EventEmitter = new EventEmitter();\r\n\r\n unsaved: UnsavedOverride[] = [];\r\n\r\n private _setUnsavedOverrides(newOverrides: FieldOverrideWithRowVersion[]): void {\r\n const overrides = this.overrideHolder.overrides;\r\n const split = newOverrides.reduce((acc, x) => {\r\n const savedIndex = overrides.findIndex(y => y.fieldName === x.fieldName);\r\n if (savedIndex > -1) {\r\n acc.exists.push({ ...x, index: savedIndex, isExisting: true });\r\n } else {\r\n acc.newChanges.push(x);\r\n }\r\n return acc;\r\n }, { exists: [], newChanges: [] } as { exists: UnsavedOverride[], newChanges: FieldOverrideWithRowVersion[]});\r\n\r\n this.unsaved = _.flow([\r\n reduce((acc, x) => {\r\n acc.splice(x.index, 0, x);\r\n return acc;\r\n }, split.newChanges),\r\n map.convert({cap: false})((x, i) => ({ ...x, index: (x.index >= 0 ? x.index : i) + 1 }))\r\n ])(split.exists);\r\n }\r\n}\r\n","\r\n
\r\n
\r\n
\r\n Apply form overrides to:\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n
\r\n

Select a form or report to preview it.

\r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n
\r\n

{{(hasTooManyRows ? 'Please change the report output to Excel' : 'An error occurred.')}}

\r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n
\r\n

The report doesn't contain any data.

\r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n
\r\n

\r\n Excel reports can't be previewed.\r\n Click here to download the report.\r\n

\r\n
\r\n\r\n\r\n\r\n\r\n\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy, ElementRef, ChangeDetectorRef, Renderer2, NgZone } from '@angular/core';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { ReturnAssetsService, ReturnAssetsServiceSharedState } from '../../Assets/returnAssets.service';\r\nimport { ReturnPreviewService, ReturnFormModel, ReturnPreviewServiceSharedState, FormChanges } from '../returnPreview.service';\r\nimport { WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport { FieldOverride, PDFViewerBase } from '../../../../../Common/PDFViewer/pdfViewerBase';\r\nimport { BusyIndicatorService } from '../../../../../Busy-Indicator';\r\nimport { RETURN_PREVIEW_FORM_VIEWER_HELP } from './returnPreviewFormViewer.component.help';\r\nimport { HelpService } from '../../../../../UI-Lib/Help-Tooltip';\r\nimport { ReturnPreviewFormOverrideListResult } from '../Form-Overrides-List/returnPreviewFormOverrideList.component';\r\nimport { RestrictService, Roles } from '../../../../../Common/Permissions/restrict.service';\r\nimport { ProductAnalyticsService } from \"../../../../../Common/Amplitude/productAnalytics.service\";\r\nimport { ToastrService } from \"ngx-toastr\";\r\nimport { Subject, Subscription } from 'rxjs';\r\nimport { takeUntil } from \"rxjs/operators\";\r\nimport * as _ from 'lodash';\r\nimport { ScriptLoaderService } from 'src/app/UI-Lib/Utilities/scriptLoader.service';\r\nimport { Constants } from 'src/app/constants.new';\r\n\r\nconst PDF_SELECTOR = '#return-output';\r\n\r\n@Component({\r\n selector: 'return-preview-form-viewer',\r\n templateUrl: './returnPreviewFormViewer.component.html',\r\n styleUrls: ['./returnPreviewFormViewer.component.scss']\r\n})\r\nexport class ReturnPreviewFormViewerComponent extends PDFViewerBase implements OnInit, OnDestroy, IReturnPartComponent {\r\n // The form preview uses pdfjs, and extends a base class in order to share a lot of logic with the Core application's page. A very large method\r\n // \"loadPreviewForForm\" contains a lot of the basic logic, in terms of setting up fields and lookups and UI components for overrides. The pdf viewer\r\n // cannot create all the pages at once, without risking crashing chrome by using too much memory. The amount already set may be high, but was done to\r\n // help the non-compliance portion cope with larger documents - forms are inherently not as long. The value is set in MAX_RENDERED_PAGES\r\n\r\n // Scrolling to unrendered pages works by placeholders in the dom and using a timer to check if it has become visible to the user (meaning it should\r\n // cause the next pagination to happen). What is missing from this - and not yet needed - is that some of the logic to set up the annotations and\r\n // lookups in the UI happens on the original render. To expand this to handle scrolling a longer doc and coping with changes to fields,\r\n // some logic would need extracting from that into a place that could be called when each new area is rendered.\r\n\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnPreviewService: ReturnPreviewService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _elementRef: ElementRef,\r\n private readonly _helpService: HelpService,\r\n private readonly _cdRef: ChangeDetectorRef,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _toastr: ToastrService,\r\n public _zone: NgZone,\r\n public _renderer: Renderer2,\r\n public _modalService: WeissmanModalService,\r\n _scriptLoaderService: ScriptLoaderService,\r\n _constants: Constants\r\n ) {\r\n super(PDF_SELECTOR, _modalService, _scriptLoaderService, _constants, _renderer, _zone);\r\n }\r\n\r\n isBusy: boolean = false;\r\n isPageLoading: boolean = false;\r\n isError: boolean = false;\r\n hasTooManyRows: boolean = false;\r\n showFieldLocation: boolean = false;\r\n applyEditsToAll: boolean = false;\r\n returnForm: ReturnFormModel;\r\n canEditComplianceSetups: boolean;\r\n formChanges: FormChanges;\r\n\r\n protected readonly _PDF_OUTPUT_HOLDER_QUERY_SELECTOR: string = '#return-output';\r\n\r\n private _localReturnPreviewServiceSharedState: ReturnPreviewServiceSharedState;\r\n private _localReturnAssetsServiceSharedState: ReturnAssetsServiceSharedState;\r\n\r\n private _returnFormSub: Subscription;\r\n private _returnReadOnlyFlagSub: Subscription;\r\n private _returnFormOverrideListSub: Subscription;\r\n private _isReportEmpty: boolean = false;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get isExcelReport(): boolean {\r\n return this.returnForm && this.returnForm.isExcel;\r\n }\r\n\r\n get isReportEmpty(): boolean {\r\n return this.returnForm && this._isReportEmpty;\r\n }\r\n\r\n get canPreview(): boolean {\r\n return this.returnForm && (!this.returnForm.isExcel) && (!this._isReportEmpty) && (!this.isError);\r\n }\r\n\r\n get canShowFieldLocations(): boolean {\r\n return this._returnService.processStatus === Compliance.FilingBatchProcessStatusEnum.Started\r\n || (this._returnService.processStatus === Compliance.FilingBatchProcessStatusEnum.Locked && this._returnPreviewService.isFormInReviewMode());\r\n }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(RETURN_PREVIEW_FORM_VIEWER_HELP);\r\n this._returnPreviewService.fieldOverrideHolder = this.overrideHolder;\r\n\r\n this.canEditComplianceSetups = this._restrictService.isInRole(Roles.COMPLIANCESETUPSEDIT);\r\n\r\n this._returnPreviewService.subscribeToServiceActivationCycle(this);\r\n this._returnService.tasks$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n if (!this._returnService.isLongRunningProcessActive) {\r\n this._refreshPreview(true);\r\n }\r\n });\r\n\r\n this._busyIndicatorService.indicatorActive$.pipe(takeUntil(this._destroy$))\r\n .subscribe(active => this.isPageLoading = active);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnPreviewService.unsubscribeFromServiceActivationCycle(this);\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n\r\n this.disposePdfDocument();\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n this.isReadOnly = this._returnService.isReturnInReadOnlyMode || !this._returnService.canEditCompany;\r\n\r\n await this._refreshPreview();\r\n\r\n this._returnReadOnlyFlagSub = this._returnService.isReturnInReadOnlyMode$.subscribe(async (x) => {\r\n await this._handleReturnReadOnlyFlagChange(x);\r\n });\r\n\r\n this._returnFormSub = this._returnPreviewService.returnForm$.subscribe(() => {\r\n this._refreshPreview();\r\n });\r\n\r\n this._returnFormOverrideListSub = this._returnPreviewService.returnFormOverrideList$.subscribe(async (x) => {\r\n await this._returnFormOverridesListChanged(x);\r\n });\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._returnFormSub && this._returnFormSub.unsubscribe();\r\n this._returnReadOnlyFlagSub && this._returnReadOnlyFlagSub.unsubscribe();\r\n this._returnFormOverrideListSub && this._returnFormOverrideListSub.unsubscribe();\r\n }\r\n\r\n refresh(): void {\r\n this._loadPreview();\r\n }\r\n\r\n onApplyEditsToAllChange(value: boolean): void {\r\n this.applyEditsToAll = value;\r\n }\r\n\r\n setShowFieldLocation(showFieldLocation: boolean): void {\r\n this.showFieldLocation = showFieldLocation;\r\n if (showFieldLocation) {\r\n this._loadPreview(false);\r\n }\r\n }\r\n\r\n private async _returnFormOverridesListChanged(result: ReturnPreviewFormOverrideListResult): Promise {\r\n // if this page has a deleted override, just reload, could optimize later by finding UI element(s)\r\n let thisPageNeedsRefreshForDeletes = false;\r\n if (result.deletedOverrides && this.returnForm) {\r\n if (result.deletedOverrides.find((overrideDetail: Compliance.ReturnFormOverrideDetailModel) => {\r\n return overrideDetail.formRevisionId === this.returnForm.formRevisionId && overrideDetail.returnId === this.returnForm.returnId;\r\n }) !== undefined) {\r\n thisPageNeedsRefreshForDeletes = true;\r\n }\r\n }\r\n\r\n if (result.clickedOverride) {\r\n // check if we're already on the return, if so just scroll to it\r\n const target = result.clickedOverride;\r\n if (this.returnForm && this.returnForm.formRevisionId === target.formRevisionId\r\n && this.returnForm.returnId === target.returnId\r\n && this.returnForm.mergeParcelId === target.parcelId) {\r\n if (thisPageNeedsRefreshForDeletes) {\r\n await this._loadPreview(); // refresh for deletions\r\n }\r\n const elem = this.overrideHolder.overrides.find(override => override.fieldName === target.fieldName);\r\n if (elem && elem.formElements && elem.formElements.length > 0) {\r\n this.scrollToElement(elem.formElements[0]);\r\n }\r\n } else {\r\n this._returnPreviewService.openPreviewByOverrides(result.clickedOverride);\r\n }\r\n } else {\r\n if (thisPageNeedsRefreshForDeletes) {\r\n // no navigation but still refresh the preview for deletions;\r\n this._loadPreview();\r\n }\r\n }\r\n }\r\n\r\n async download(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Downloading' });\r\n\r\n try {\r\n await (this.returnForm.reportId ?\r\n this._returnPreviewService.startDownloadReport(\r\n this.returnForm.returnId,\r\n this.returnForm.formRevisionId,\r\n this.returnForm.reportId) :\r\n this._returnPreviewService.startDownloadForm(\r\n this.returnForm.returnId,\r\n this.returnForm.formRevisionId,\r\n this.returnForm.mergeParcelId));\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n removeUnsavedOverrides(): void {\r\n this.formChanges.overrides.forEach(x => {\r\n this._deleteOverrideMarker(x);\r\n x.formElements.forEach(y => y.classList.remove(this.MODIFIED_FIELD_CSS_CLASS));\r\n const saved = this.overrideHolder.getSaved(x.fieldName);\r\n if (saved) {\r\n this._createOverrideMarker(x);\r\n }\r\n });\r\n\r\n this.formChanges.overrides = [];\r\n this._loadPreview(false);\r\n }\r\n\r\n async submitPdfChanges(): Promise {\r\n try {\r\n this.formChanges.returnMergedParcelIds = this._getReturnAndParcelIdsForEdits();\r\n const result = await this._returnPreviewService.updateFormFieldOverrides(this.formChanges);\r\n for (const x of this.formChanges.overrides) {\r\n (x.formElements as any[]).forEach(element => {\r\n element.classList.add(this.MODIFIED_FIELD_CSS_CLASS);\r\n });\r\n\r\n this._createOverrideUI(x);\r\n this._deleteInfoMarker(x);\r\n this.overrideHolder.renumberOverrides();\r\n\r\n const persistedResult = result.find(override => override.returnId === this.returnForm.returnId\r\n && override.fieldName === x.fieldName);\r\n if (persistedResult) {\r\n this.overrideHolder.saveOverride(persistedResult, x.fieldName);\r\n }\r\n }\r\n\r\n await this._loadPreview(false);\r\n } finally {\r\n this._productAnalyticsService.logEvent('click-unsaved-overrides-save-changes', {});\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n async onPdfFieldChange(event): Promise {\r\n if (!event.target) {\r\n return;\r\n }\r\n const id = event.target.parentElement.getAttribute('data-annotation-id');\r\n const fieldData = this._idFieldMap[id];\r\n\r\n //todo: is there an annotation or configuration to do this automatically?\r\n // set checkbox field value based on checked state\r\n if (event.target.type === 'checkbox') {\r\n event.target.value = event.target.checked ? 'On' : 'Off';\r\n }\r\n\r\n const newValue = event.target.value;\r\n\r\n const oldFormatOverride = this._oldFormatOverrides[fieldData.fieldName];\r\n if (oldFormatOverride) {\r\n await this._deleteOverride(oldFormatOverride.override, oldFormatOverride.rowVersion);\r\n }\r\n\r\n fieldData.elements.forEach(element => (element as any).value = newValue);\r\n\r\n const override = this.formChanges.overrides.find(x => x.fieldName === fieldData.fieldName);\r\n\r\n if (override) {\r\n override.overrideValue = newValue;\r\n this.formChanges.overrides = [ ...this.formChanges.overrides ];\r\n } else {\r\n const override = {\r\n fieldName: fieldData.fieldName,\r\n overrideValue: newValue,\r\n formElements: fieldData.elements,\r\n rowVersion: this.overrideHolder.getSaved(fieldData.fieldName) ? this.overrideHolder.getSaved(fieldData.fieldName).rowVersion : null\r\n }\r\n this.formChanges.overrides = [ ...this.formChanges.overrides, override ];\r\n this._deleteOverrideMarker(override);\r\n this._createOverrideMarker(override, false);\r\n override.formElements.forEach(x => this._renderer.addClass(x, this.MODIFIED_FIELD_CSS_CLASS));\r\n }\r\n }\r\n\r\n private async _refreshPreview(force: boolean = false): Promise {\r\n const returnPreviewServiceSharedState: ReturnPreviewServiceSharedState = this._returnPreviewService.getSharedStateClone();\r\n const returnAssetsServiceSharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n\r\n // get input parameters for comparison\r\n const localReturnForm = this._localReturnPreviewServiceSharedState && this._localReturnPreviewServiceSharedState.returnForm;\r\n const sharedReturnForm = returnPreviewServiceSharedState.returnForm;\r\n\r\n const localAssetDetailsUpdatedTimestamp = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n const sharedAssetDetailsUpdatedTimestamp = returnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n\r\n const localAssetMappingsUpdatedTimestamp = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n const sharedAssetMappingsUpdatedTimestamp = returnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n\r\n // check to see if the input parameters have changed\r\n if (force ||\r\n !_.isEqual(localReturnForm, sharedReturnForm) ||\r\n !_.isEqual(localAssetDetailsUpdatedTimestamp, sharedAssetDetailsUpdatedTimestamp) ||\r\n !_.isEqual(localAssetMappingsUpdatedTimestamp, sharedAssetMappingsUpdatedTimestamp)\r\n ) {\r\n await this._loadPreview();\r\n }\r\n }\r\n\r\n private async _loadPreview(reloadTemplate: boolean = true): Promise {\r\n // persist local state for future checks\r\n this._persistState();\r\n\r\n if (reloadTemplate) {\r\n this.disposePdfDocument();\r\n }\r\n\r\n this.returnForm = this._localReturnPreviewServiceSharedState.returnForm;\r\n this._isReportEmpty = false;\r\n this.isError = false;\r\n this.hasTooManyRows = false;\r\n\r\n if ((!this.returnForm) || this.returnForm.isExcel) {\r\n return;\r\n }\r\n\r\n this.formChanges = {\r\n formRevisionId: this.returnForm.formRevisionId,\r\n returnMergedParcelIds: this._getReturnAndParcelIdsForEdits(),\r\n overrides: []\r\n }\r\n\r\n this.isBusy = true;\r\n\r\n try {\r\n // figure out if loading report or form\r\n if (this.returnForm.reportId) {\r\n const report = await this._returnPreviewService.getReturnFormReport(this.returnForm.returnId, this.returnForm.formRevisionId, this.returnForm.reportId);\r\n if (report) {\r\n await this._zone.runOutsideAngular(async () => await this._loadPreviewForReport(report));\r\n } else {\r\n this._isReportEmpty = true;\r\n }\r\n } else {\r\n if (reloadTemplate) {\r\n const { form, data } = await this._returnPreviewService.getFormTemplateAndData(this.canShowFieldLocations && this.showFieldLocation);\r\n await this._zone.runOutsideAngular(async () => await this._loadPreviewForForm(form, data, data && data.formRevisionOverrides, this._returnPreviewService.isFormInReviewMode()));\r\n } else {\r\n const data = await this._returnPreviewService.getFormData(this.canShowFieldLocations && this.showFieldLocation);\r\n await this._loadFormData(data, data && data.formRevisionOverrides, this._returnPreviewService.isFormInReviewMode());\r\n }\r\n }\r\n }\r\n catch (err) {\r\n if (err.status === 413) {\r\n this.hasTooManyRows = true;\r\n }\r\n this.isError = true;\r\n if (err.error?.message) {\r\n this._toastr.error(err.error.message);\r\n } else {\r\n throw err;\r\n }\r\n }\r\n finally {\r\n this.isBusy = false;\r\n this._cdRef.detectChanges();\r\n }\r\n }\r\n\r\n private _persistState(): void {\r\n this._localReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n this._localReturnPreviewServiceSharedState = this._returnPreviewService.getSharedStateClone();\r\n }\r\n\r\n private async _loadPreviewForReport(blob: Blob): Promise {\r\n const fileReader = new FileReader();\r\n fileReader.onload = async () => {\r\n this.loadPdfDocument({\r\n data: fileReader.result\r\n }).then(() => {\r\n this.updateNextPageVisibility();\r\n });\r\n };\r\n fileReader.readAsArrayBuffer(blob);\r\n }\r\n\r\n private _getReturnAndParcelIdsForEdits(): Compliance.ReturnMergedParcelIdModel[] {\r\n if (this.applyEditsToAll) {\r\n // Map the associated form revision IDs to the return ID\r\n const formRevisions = this._returnService.getAssociatedReturnFormRevisions()\r\n .reduce((acc, x) => {\r\n if (!acc.has(x.returnId)) {\r\n acc.set(x.returnId, new Set());\r\n }\r\n acc.get(x.returnId).add(x.formRevisionId);\r\n return acc;\r\n }, new Map>());\r\n // Return any returns that have a form revision ID that matches the selected ID\r\n return this._returnService.sharedState.returns\r\n .filter(x => formRevisions.has(x.returnId) && formRevisions.get(x.returnId).has(this.returnForm.formRevisionId))\r\n .map(x => ({\r\n mergedParcelId: this._returnService.isReturnConsolidated(x.returnId) ? x.parcelId : null,\r\n returnId: x.returnId\r\n }));\r\n } else {\r\n return [\r\n {\r\n mergedParcelId: (this._returnService.isReturnConsolidated(this.returnForm.returnId)) ? this.returnForm.mergeParcelId : null,\r\n returnId: this.returnForm.returnId\r\n }\r\n ];\r\n }\r\n }\r\n\r\n protected async _deleteOverride(override: FieldOverride, rowVersion: number[]): Promise {\r\n this.isBusy = true;\r\n\r\n try {\r\n const oldFormatShortName = Object.keys(this._oldFormatOverrides).find(shortName => this._oldFormatOverrides[shortName].override === override);\r\n if (oldFormatShortName) {\r\n delete this._oldFormatOverrides[oldFormatShortName];\r\n }\r\n\r\n const overrideModel: Compliance.ReturnFormOverrideRequestModel = {\r\n formRevisionId: this.returnForm.formRevisionId,\r\n fieldName: override.fieldName,\r\n value: null,\r\n returnMergedParcelIds: this._getReturnAndParcelIdsForEdits(),\r\n rowVersion: rowVersion\r\n };\r\n\r\n await this._returnPreviewService.deleteFormFieldOverrides(overrideModel);\r\n\r\n (override.formElements as any[]).forEach(formElement => {\r\n formElement.disabled = false;\r\n formElement.classList.remove(this.MODIFIED_FIELD_CSS_CLASS);\r\n });\r\n\r\n this._deleteOverrideUI(override);\r\n\r\n await this._loadPreview(false);\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n protected _postFormLoadAction() {\r\n const overrideToScrollTo = this._returnPreviewService.sharedState.navigateToOverride;\r\n if (overrideToScrollTo) {\r\n const elem = this.overrideHolder.overrides.find(override => override.fieldName === overrideToScrollTo.fieldName);\r\n if (elem && elem.formElements && elem.formElements.length > 0) {\r\n this.scrollToElement(elem.formElements[0]);\r\n }\r\n }\r\n }\r\n\r\n protected getElementRef(): ElementRef {\r\n return this._elementRef;\r\n }\r\n\r\n protected isShowingAnnotations(): boolean {\r\n return !(this.returnForm && this.returnForm.reportId) && this._returnPreviewService.isFormDataNeededOnPdf();\r\n }\r\n\r\n private async _handleReturnReadOnlyFlagChange(isReadOnly: boolean): Promise {\r\n this.isReadOnly = isReadOnly || !this._returnService.canEditCompany;\r\n this._updateInputFieldReadOnlyAttributes();\r\n }\r\n\r\n protected resolveAccountIndex(override: Compliance.FormOverrideModel): number {\r\n return 0;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'return-preview',\r\n templateUrl: './returnPreview.component.html',\r\n styleUrls: ['./returnPreview.component.scss']\r\n})\r\nexport class ReturnPreviewComponent {}\r\n","
\r\n \r\n
\r\n
\r\n \r\n
","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const RETURN_OVERVIEW_COMPONENT_HELP: HelpContent[] = [\r\n];\r\n","import { Component, OnInit, OnDestroy, Input } from '@angular/core';\r\nimport { Subscription } from 'rxjs';\r\nimport { ReturnService } from '../return.service';\r\nimport { IReturnPartComponent, ReturnPartServiceBase } from '../Models/returnPartServiceBase';\r\nimport { ReturnFormRevisionListItem, ReturnUpdateLogicService } from '../returnUpdateLogic.service';\r\n\r\n@Component({\r\n selector: 'return-form-selector',\r\n templateUrl: './returnFormSelector.component.html'\r\n})\r\nexport class ReturnFormSelectorComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor (private readonly _returnService: ReturnService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService) { }\r\n\r\n @Input() returnPartService: ReturnPartServiceBase;\r\n @Input() allowPrimaryForReturn: boolean;\r\n\r\n returnFormRevisions: ReturnFormRevisionListItem[] = [];\r\n selectedReturnFormRevision: ReturnFormRevisionListItem = null;\r\n\r\n private _returnsSub: Subscription;\r\n\r\n ngOnInit(): void {\r\n this.returnPartService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.returnPartService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n this._returnsSub = this._returnUpdateLogicService.returnFormRevisions$.subscribe((returnFormRevisions) => {\r\n if (returnFormRevisions) {\r\n this._refreshReturnFormRevisions(returnFormRevisions);\r\n }\r\n });\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._returnsSub && this._returnsSub.unsubscribe();\r\n }\r\n\r\n async onSelectedReturnFormRevisionChange(returnFormRevision: Compliance.ReturnFormRevisionModel): Promise {\r\n this.selectedReturnFormRevision = returnFormRevision;\r\n this._returnService.setFormRevisionId(this.selectedReturnFormRevision && this.selectedReturnFormRevision.formRevisionId);\r\n await this._returnUpdateLogicService.returnFormRevisionChanged();\r\n }\r\n\r\n private _refreshReturnFormRevisions(formRevisions: ReturnFormRevisionListItem[]) {\r\n this.returnFormRevisions = formRevisions || [];\r\n\r\n // If there is only one form revision, select it\r\n if (!this._returnService.sharedState.formRevisionId && this._returnService.getUniqueAssociatedReturnFormRevisions().length === 1) {\r\n this._returnService.setFirstFormRevisionId(true);\r\n }\r\n\r\n // auto-select the form revision if one is selected\r\n this.selectedReturnFormRevision = this.returnFormRevisions.find(x => x.formRevisionId === this._returnService.sharedState.formRevisionId) || null;\r\n\r\n this._returnService.setFormRevisionId(\r\n this.selectedReturnFormRevision\r\n ? this.selectedReturnFormRevision.formRevisionId\r\n : null);\r\n }\r\n}\r\n","
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../../AgGrid';\r\nimport { ReturnAssetsService } from '../returnAssets.service';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { ReturnAssetRepository } from \"../../../../Repositories\";\r\n\r\nexport interface ReturnAssetDisposalsListDataSourceParams {\r\n priorReturnStatuses: Compliance.ReturnAssetPriorReturnStatusEnum[];\r\n formRevisionScheduleId: number;\r\n targetNonReportableSchedule: boolean;\r\n targetReportableSchedule: boolean;\r\n scheduleGroupType?: Compliance.ScheduleGroupTypeEnum;\r\n}\r\n\r\nexport class ReturnAssetDisposalsListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private _gridApi: GridApi,\r\n private _returnService: ReturnService,\r\n private _returnAssetsService: ReturnAssetsService,\r\n private _returnAssetRepository: ReturnAssetRepository,\r\n protected _dataSourceParamsFn: () => ReturnAssetDisposalsListDataSourceParams,\r\n private _totalsUpdateCallback: (totals: Compliance.ReturnAssetSearchTotalsModel) => void\r\n ) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'assetNumber', value: Compliance.ReturnAssetPropertyEnum.AssetNumber },\r\n { name: 'description', value: Compliance.ReturnAssetPropertyEnum.Description },\r\n { name: 'classificationName', value: Compliance.ReturnAssetPropertyEnum.ClassificationName },\r\n { name: 'parcelAccountNumber', value: Compliance.ReturnAssetPropertyEnum.ParcelAccountNumber },\r\n { name: 'acqDate', value: Compliance.ReturnAssetPropertyEnum.AcqDate },\r\n { name: 'priorAcqDate', value: Compliance.ReturnAssetPropertyEnum.PriorAcqDate },\r\n { name: 'cost', value: Compliance.ReturnAssetPropertyEnum.Cost },\r\n { name: 'priorCost', value: Compliance.ReturnAssetPropertyEnum.PriorCost },\r\n { name: 'costChange', value: Compliance.ReturnAssetPropertyEnum.CostChange },\r\n { name: 'scheduleName', value: Compliance.ReturnAssetPropertyEnum.Schedule },\r\n { name: 'priorScheduleName', value: Compliance.ReturnAssetPropertyEnum.PriorSchedule },\r\n { name: 'depreciationFactorTableName', value: Compliance.ReturnAssetPropertyEnum.DepreciationFactorTableName },\r\n { name: 'priorDepreciationFactorTableName', value: Compliance.ReturnAssetPropertyEnum.PriorDepreciationFactorTableName},\r\n { name: 'factor', value: Compliance.ReturnAssetPropertyEnum.Factor },\r\n { name: 'reportedValue', value: Compliance.ReturnAssetPropertyEnum.DepreciationCost },\r\n { name: 'disposedDate', value: Compliance.ReturnAssetPropertyEnum.DisposedDate },\r\n { name: 'site', value: Compliance.ReturnAssetPropertyEnum.Site },\r\n { name: 'siteName', value: Compliance.ReturnAssetPropertyEnum.SiteName },\r\n { name: 'siteProperty', value: Compliance.ReturnAssetPropertyEnum.SiteProperty },\r\n { name: 'priorSiteProperty', value: Compliance.ReturnAssetPropertyEnum.PriorSiteProperty },\r\n { name: 'priorSiteName', value: Compliance.ReturnAssetPropertyEnum.PriorSiteName },\r\n { name: 'disposalAssetNumber', value: Compliance.ReturnAssetPropertyEnum.DisposalAssetNumber },\r\n { name: 'disposalDescription', value: Compliance.ReturnAssetPropertyEnum.DisposalDescription },\r\n { name: 'disposalClassification', value: Compliance.ReturnAssetPropertyEnum.DisposalClassification },\r\n { name: 'assessorAbbr', value: Compliance.ReturnAssetPropertyEnum.AssessorAbbr }\r\n ];\r\n\r\n private _lastFilterUsedInTotals: string;\r\n lastFetchedTotals: Compliance.ReturnAssetSearchTotalsModel;\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n const searchParamsString = JSON.stringify(searchParams);\r\n const fetchTotals: boolean = (!this.lastFetchedTotals) || (this._lastFilterUsedInTotals != searchParamsString);\r\n\r\n this._lastFilterUsedInTotals = searchParamsString;\r\n\r\n if (fetchTotals) {\r\n searchParams.includeTotals = true;\r\n }\r\n\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const result = await lastValueFrom(this._returnAssetRepository.getListByFilingBatch(this._returnService.filingBatchId, searchParams));\r\n\r\n if (fetchTotals) {\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals);\r\n }\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows,\r\n lastModifiedTimestamp: result.lastModifiedTimestamp\r\n };\r\n }\r\n\r\n clearTotals(): void {\r\n this._lastFilterUsedInTotals = '';\r\n }\r\n\r\n getSearchParamsWithoutPagination(): Compliance.ReturnAssetSearchModel {\r\n const getPriorReturnFromAssetList = this._returnService.filingBatch.getPriorReturnFromAssetList;\r\n\r\n let searchModel: Compliance.ReturnAssetSearchModel = {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n formRevisionIds: this._returnService.sharedState.formRevisionId ? [this._returnService.sharedState.formRevisionId] : [],\r\n parcelIds: this._returnService.sharedState.returns.map(x => x.parcelId),\r\n assessorIds: getPriorReturnFromAssetList ? [] : this._returnAssetsService.sharedState.assessorFactorsFilter.assessorIds || [],\r\n formRevisionScheduleIds: this._dataSourceParams.formRevisionScheduleId ? [this._dataSourceParams.formRevisionScheduleId] : [],\r\n formFactorTableId: null,\r\n age: null,\r\n priorReturnStatuses: this._dataSourceParams.priorReturnStatuses || [],\r\n scheduleGroupType: Compliance.ScheduleGroupTypeEnum.Unrestricted,\r\n priorScheduleGroupType: Compliance.ScheduleGroupTypeEnum.Unrestricted,\r\n selectedRows: null,\r\n includeTotals: false,\r\n includeOnlyTotals: false,\r\n includeMergedParcels: this._returnService.isConsolidatedReturn,\r\n includeUnassigned: false,\r\n includeDisposed: true\r\n };\r\n\r\n if (this._dataSourceParams.priorReturnStatuses.findIndex(x => x === Compliance.ReturnAssetPriorReturnStatusEnum.Retired) !== -1 ||\r\n this._dataSourceParams.priorReturnStatuses.findIndex(x => x === Compliance.ReturnAssetPriorReturnStatusEnum.TransferOut) !== -1) {\r\n if (this._dataSourceParams.targetNonReportableSchedule && this._dataSourceParams.targetReportableSchedule) {\r\n searchModel.priorScheduleGroupType = Compliance.ScheduleGroupTypeEnum.Unrestricted;\r\n }\r\n else if (this._dataSourceParams.targetNonReportableSchedule) {\r\n searchModel.priorScheduleGroupType = Compliance.ScheduleGroupTypeEnum.NonReportable;\r\n } else if (this._dataSourceParams.targetReportableSchedule) {\r\n searchModel.priorScheduleGroupType = Compliance.ScheduleGroupTypeEnum.ReportableTaxableNotTaxable;\r\n } else {\r\n searchModel.priorScheduleGroupType = Compliance.ScheduleGroupTypeEnum.OnlyNotAssignedToASchedule;\r\n }\r\n } else {\r\n if (this._dataSourceParams.scheduleGroupType >= 0) {\r\n searchModel.scheduleGroupType = this._dataSourceParams.scheduleGroupType\r\n } else {\r\n if (this._dataSourceParams.targetNonReportableSchedule) {\r\n searchModel.scheduleGroupType = Compliance.ScheduleGroupTypeEnum.NonReportable;\r\n }\r\n\r\n if (this._dataSourceParams.targetReportableSchedule) {\r\n searchModel.scheduleGroupType = Compliance.ScheduleGroupTypeEnum.ReportableTaxableNotTaxable;\r\n }\r\n }\r\n }\r\n\r\n return searchModel;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.pagination = {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n };\r\n\r\n return await lastValueFrom(this._returnAssetRepository.getRowIdsByFilingBatch(this._returnService.filingBatchId, searchParams));\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\n@Component({\r\n selector: 'return-asset-change-icon-cell',\r\n template: `\r\n \r\n \r\n -`\r\n})\r\nexport class ReturnAssetChangeIconCellRendererComponent implements ICellRendererAngularComp {\r\n asset: Compliance.AssetChangeStatusEnum[];\r\n params: ICellRendererParams;\r\n total: boolean = false;\r\n toolTipTitle: string;\r\n iconClass: string;\r\n statusChanged: boolean = false;\r\n initialized: boolean = false;\r\n\r\n agInit(params: ICellRendererParams): void {\r\n const rowModel: Compliance.ReturnAssetModel = params.data;\r\n if (rowModel) {\r\n this.statusChanged = rowModel.assetReturnStatus !== rowModel.calculatedAssetReturnStatus;\r\n\r\n switch (rowModel.assetReturnStatus) {\r\n case 'New':\r\n this.iconClass = 'fa-plus';\r\n this.toolTipTitle = (rowModel.calculatedAssetReturnStatus === 'TransferIn') ?\r\n 'Changed from Transferred In to Added' : 'Added';\r\n break;\r\n case 'TransferIn':\r\n this.iconClass = 'fa-plus-square';\r\n this.toolTipTitle = (rowModel.calculatedAssetReturnStatus === 'New') ?\r\n 'Changed from Added to Transferred In' : 'Added';\r\n break;\r\n case 'TransferOut':\r\n this.iconClass = 'fa-minus-square';\r\n this.toolTipTitle = (rowModel.calculatedAssetReturnStatus === 'Retired') ?\r\n 'Changed from Disposed to Transferred Out' : 'Transferred Out';\r\n break;\r\n case 'Retired':\r\n this.iconClass = 'fa-trash';\r\n this.toolTipTitle = (rowModel.calculatedAssetReturnStatus === 'TransferOut') ?\r\n 'Changed from Transferred Out to Disposed' : 'Disposed';\r\n break;\r\n case 'NotChanged':\r\n this.iconClass = 'fa-refresh';\r\n if (rowModel.calculatedAssetReturnStatus === 'New') {\r\n this.toolTipTitle = 'Suppressed to Existing from Added';\r\n } else if (rowModel.calculatedAssetReturnStatus === 'TransferIn') {\r\n this.toolTipTitle = 'Suppressed to Existing from Transferred In';\r\n } else if (rowModel.calculatedAssetReturnStatus === 'Retired') {\r\n this.toolTipTitle = 'Suppressed to Present from Disposed';\r\n } else if (rowModel.calculatedAssetReturnStatus === 'TransferOut') {\r\n this.toolTipTitle = 'Suppressed to Existing from Transferred Out';\r\n } else {\r\n this.iconClass = 'fa-circle-thin';\r\n this.toolTipTitle = 'Not changed';\r\n }\r\n break;\r\n case 'ChangedCostIncreased':\r\n case 'ChangedCostDecreased':\r\n case 'Changed':\r\n case 'ChangedScheduleNonReportableToReportable':\r\n this.iconClass = 'fa-pencil';\r\n this.toolTipTitle = 'Changed';\r\n break;\r\n case 'Indefinable':\r\n this.iconClass = 'fa-question';\r\n this.toolTipTitle = 'The prior year return cannot be used to detect year over year asset changes because the prior year form is different. Please configure the filing batch to use the company asset list for change detection.';\r\n break;\r\n default:\r\n this.iconClass = 'fa-circle-thin';\r\n this.toolTipTitle = 'Not changed';\r\n }\r\n\r\n this.total = rowModel.assetNumber === 'TOTAL' || rowModel.assetNumber === 'SELECTED';\r\n this.initialized = true;\r\n }\r\n\r\n\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","\r\n\r\n\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
AssessorDepreciationIndex
State-level factor tables\r\n \r\n \r\n \r\n
{{ assessor.assessorName }}\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormControl } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../WeissmanModalService';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface LockedAssessorAssignments {\r\n depreciationTableId:number;\r\n indexTableId:number;\r\n}\r\nexport interface AssessorTablePickerParams {\r\n reportingAssetIds: number[];\r\n assessors: Compliance.FormRevisionAssessorModel[];\r\n defaultAssessor: Compliance.FormRevisionAssessorModel;\r\n defaultFactorTables: Compliance.AssessorFactorTableListItemModel[];\r\n assessorFactorTables: Compliance.AssessorFactorTableModel[];\r\n lockedAssessorAssignments: {[assessorId:number]: LockedAssessorAssignments};\r\n}\r\n\r\nexport interface AssessorTablePickerResult {\r\n selection: { [assessorId: number ]: {\r\n depreciationTableId: number;\r\n indexTableId: number;\r\n }}\r\n}\r\n\r\n@Component({\r\n selector: 'asset-class-picker-modal',\r\n templateUrl: './assessorTablePicker.component.html',\r\n\r\n})\r\nexport class AssessorTablePickerComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private _modalRef: BsModalRef,\r\n private _formBuilder: UntypedFormBuilder\r\n ) { }\r\n\r\n private _assessorFactorTables: { [assessorId: number]: Compliance.AssessorFactorTableListItemModel[] } = {};\r\n private _destroy$: Subject = new Subject();\r\n\r\n params: AssessorTablePickerParams;\r\n result: AssessorTablePickerResult;\r\n\r\n isBusy: boolean;\r\n form: UntypedFormGroup;\r\n\r\n assessors: Compliance.FormRevisionAssessorModel[] = [];\r\n defaultAssessor: Compliance.FormRevisionAssessorModel; // the nominal default for getting tables\r\n defaultAssessors: Compliance.FormRevisionAssessorModel[] = []; // assessors using default tables\r\n\r\n defaultDepreciationTables: Compliance.AssessorFactorTableListItemModel[] = [];\r\n defaultIndexTables: Compliance.AssessorFactorTableListItemModel[] = [];\r\n defaultDepreciationUsedTables: Compliance.AssessorFactorTableListItemModel[] = [];\r\n defaultIndexUsedTables: Compliance.AssessorFactorTableListItemModel[] = [];\r\n\r\n assessorDepreciationTables: { [assessorId: number]: Compliance.AssessorFactorTableListItemModel[] } = {};\r\n assessorIndexTables: { [assessorId: number]: Compliance.AssessorFactorTableListItemModel[] } = {};\r\n assessorDepreciationUsedTables: { [assessorId: number]: Compliance.AssessorFactorTableListItemModel[] } = {};\r\n assessorIndexUsedTables: { [assessorId: number]: Compliance.AssessorFactorTableListItemModel[] } = {};\r\n\r\n defaultFactorTables: Compliance.FormFactorTableModel[];\r\n\r\n assessorDepreciationControls = {};\r\n assessorIndexControls = {};\r\n defaultDepreciationControl: any;\r\n defaultIndexControl: any;\r\n\r\n showDefaultAssessor: boolean = false;\r\n showAllAvailableFactors: UntypedFormControl;\r\n\r\n async ngOnInit(): Promise {\r\n this.isBusy = true;\r\n try {\r\n this.defaultAssessor = this.params.defaultAssessor;\r\n\r\n const assessors = this.params.assessors;\r\n this.assessors = assessors.filter(x => {\r\n const hasCompanyAssessorFactorTable = this.params.assessorFactorTables.filter((item: Compliance.AssessorFactorTableModel) => item.assessorId == x.assessorId && item.factorTables.length > 0).length > 0;\r\n\r\n return x.formRevisionYearAssessorId && (!x.isUsingDefaultTables || hasCompanyAssessorFactorTable);\r\n });\r\n\r\n // also need default assessors\r\n this.defaultAssessors = assessors.filter(x => x.formRevisionYearAssessorId && x.isUsingDefaultTables && !this.params.lockedAssessorAssignments[x.assessorId]);\r\n if (this.defaultAssessors.length > 0) {\r\n this.showDefaultAssessor = true;\r\n }\r\n\r\n this.defaultDepreciationTables = this.params.defaultFactorTables.filter((item: Compliance.AssessorFactorTableListItemModel) => item.tableType === Compliance.FactorTableTypeEnum.Depreciation);\r\n this.defaultDepreciationUsedTables = this.params.defaultFactorTables.filter((item: Compliance.AssessorFactorTableListItemModel) => item.tableType === Compliance.FactorTableTypeEnum.Depreciation && item.isUsed);\r\n this.defaultIndexTables = this.params.defaultFactorTables.filter((item: Compliance.AssessorFactorTableListItemModel) => item.tableType === Compliance.FactorTableTypeEnum.Index);\r\n this.defaultIndexUsedTables = this.params.defaultFactorTables.filter((item: Compliance.AssessorFactorTableListItemModel) => item.tableType === Compliance.FactorTableTypeEnum.Index && item.isUsed);\r\n\r\n this.assessors.forEach((item) => {\r\n this._assessorFactorTables[item.assessorId] = _.flatMap(_.filter(this.params.assessorFactorTables, x => !x.assessorId || x.assessorId === item.assessorId), x => x.factorTables);\r\n });\r\n\r\n // separate the depreciation tables and the index tables\r\n this.assessors.forEach(assessor => {\r\n this.assessorDepreciationTables[assessor.assessorId] =\r\n this._assessorFactorTables[assessor.assessorId]\r\n .filter(table => table.tableType === Compliance.FactorTableTypeEnum.Depreciation)\r\n .concat(this.defaultDepreciationTables.filter(table => table.companyId === null && table.companyName === null));\r\n this.assessorDepreciationUsedTables[assessor.assessorId] = this._assessorFactorTables[assessor.assessorId].filter(table => table.tableType === Compliance.FactorTableTypeEnum.Depreciation && table.isUsed);\r\n this.assessorIndexTables[assessor.assessorId] =\r\n this._assessorFactorTables[assessor.assessorId].filter(table => table.tableType ===\r\n Compliance.FactorTableTypeEnum.Index);\r\n this.assessorIndexUsedTables[assessor.assessorId] =\r\n this._assessorFactorTables[assessor.assessorId].filter(\r\n table => table.tableType === Compliance.FactorTableTypeEnum.Index && table.isUsed);\r\n });\r\n\r\n let defaultDepreciationValue = null;\r\n const defaultFactorTable = this.params.defaultFactorTables.find((dft: Compliance.AssessorFactorTableListItemModel) => dft.isDefaultForSchedule);\r\n if (defaultFactorTable) {\r\n if (defaultFactorTable.isLockedForSchedule) {\r\n defaultDepreciationValue = { value: defaultFactorTable.factorTableId, disabled: true }\r\n } else {\r\n defaultDepreciationValue = defaultFactorTable.factorTableId;\r\n }\r\n }\r\n\r\n const formGroupMap = {};\r\n\r\n this.defaultDepreciationControl = this._formBuilder.control(defaultDepreciationValue, [Validators.required]);\r\n this.defaultIndexControl = this._formBuilder.control(null);\r\n\r\n // create form controls and define form\r\n this.showAllAvailableFactors = this._formBuilder.control(true);\r\n formGroupMap['showAvailable'] = this.showAllAvailableFactors;\r\n const depControls = this.assessors.map(x => {\r\n let controlValue = null;\r\n\r\n const assessorDepreciationTables = this.assessorDepreciationTables[x.assessorId];\r\n if (assessorDepreciationTables) {\r\n const defaultTable: Compliance.AssessorFactorTableListItemModel =\r\n assessorDepreciationTables.find(adt => adt.isDefaultForSchedule);\r\n if (defaultTable) {\r\n if (defaultTable.isLockedForSchedule) {\r\n controlValue = { value: defaultTable.factorTableId, disabled: true };\r\n } else {\r\n controlValue = defaultTable.factorTableId;\r\n }\r\n }\r\n }\r\n\r\n const control = this._formBuilder.control(controlValue, [Validators.required]);\r\n this.assessorDepreciationControls[x.assessorId] = control;\r\n formGroupMap[`dep${x.assessorId}`] = control;\r\n return control;\r\n });\r\n\r\n this.addUnlistedOptionsToShortlist();\r\n\r\n [this.showAllAvailableFactors].concat(depControls);\r\n\r\n this.assessors.map(x => {\r\n const control = this._formBuilder.control(null);\r\n this.assessorIndexControls[x.assessorId] = control;\r\n formGroupMap[`index${x.assessorId}`] = control;\r\n return control;\r\n });\r\n\r\n if (this.showDefaultAssessor) {\r\n formGroupMap['defDep'] = this.defaultDepreciationControl;\r\n formGroupMap['defIndex'] = this.defaultIndexControl;\r\n }\r\n\r\n this.form = this._formBuilder.group(formGroupMap);\r\n\r\n this.form.valueChanges.pipe(takeUntil(this._destroy$)).subscribe(x => this._updateDropdownState(x));\r\n this._updateDropdownState(this.form.value);\r\n }\r\n finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n submit(): void {\r\n this.result = {\r\n selection: this.params.lockedAssessorAssignments || {}\r\n };\r\n\r\n this.assessors.forEach(x => {\r\n this.result.selection[x.assessorId] = {\r\n depreciationTableId: this.assessorDepreciationControls[x.assessorId].value,\r\n indexTableId: this.assessorIndexControls[x.assessorId].value\r\n }\r\n });\r\n\r\n if (this.showDefaultAssessor) {\r\n this.defaultAssessors.forEach(x => {\r\n if (this.defaultDepreciationControl.value || this.defaultIndexControl.value) {\r\n this.result.selection[x.assessorId] = {\r\n depreciationTableId: this.defaultDepreciationControl.value,\r\n indexTableId: this.defaultIndexControl.value\r\n }\r\n }\r\n });\r\n }\r\n\r\n this._modalRef.hide();\r\n }\r\n\r\n optionIdentify(index, factorTable): number {\r\n return factorTable.factorTableId;\r\n }\r\n\r\n compareFn(obj1, obj2): boolean {\r\n return obj1 === obj2;\r\n }\r\n\r\n switchFactorList(event: any): void {\r\n this.addUnlistedOptionsToShortlist();\r\n }\r\n\r\n addUnlistedOptionsToShortlist(): void {\r\n const defaultControl: UntypedFormControl = this.defaultDepreciationControl;\r\n if (this.showDefaultAssessor && defaultControl.value) {\r\n if (!this.defaultDepreciationUsedTables.find((table: Compliance.AssessorFactorTableListItemModel) => table.factorTableId === defaultControl.value)) {\r\n // add to table\r\n const table = this.defaultDepreciationTables.find((table: Compliance.AssessorFactorTableListItemModel) => table.factorTableId === defaultControl.value);\r\n if (table) {\r\n this.defaultDepreciationUsedTables.push(table);\r\n }\r\n }\r\n }\r\n this.assessors.forEach((assessor: Compliance.FormRevisionAssessorModel) => {\r\n const control: UntypedFormControl = this.assessorDepreciationControls[assessor.assessorId];\r\n if (control.value) {\r\n if (!this.assessorDepreciationUsedTables[assessor.assessorId].find(\r\n (table: Compliance.AssessorFactorTableListItemModel) => table.factorTableId === control.value)) {\r\n // add to table\r\n const table = this.assessorDepreciationTables[assessor.assessorId].find(\r\n (table: Compliance.AssessorFactorTableListItemModel) => table.factorTableId === control.value);\r\n if (table) {\r\n this.assessorDepreciationUsedTables[assessor.assessorId].push(table);\r\n }\r\n }\r\n }\r\n });\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n private _updateDropdownState(formControlValues: any): void {\r\n if (this.assessors.some(y => formControlValues[`index${y.assessorId}`] || formControlValues[`dep${y.assessorId}`])) {\r\n this._toggleDefaultOptions(false);\r\n } else if (formControlValues.defDep || formControlValues.defIndex) {\r\n this._toggleAssessorOptions(false);\r\n } else {\r\n this._toggleDefaultOptions(true);\r\n this._toggleAssessorOptions(true);\r\n }\r\n }\r\n\r\n private _toggleAssessorOptions(enable: boolean): void {\r\n this.assessors.forEach(x => {\r\n const dep = this.form.get(`dep${x.assessorId}`);\r\n const index = this.form.get(`index${x.assessorId}`)\r\n if (enable) {\r\n if (dep.disabled) {\r\n dep.enable();\r\n }\r\n if (index.disabled) {\r\n index.enable();\r\n }\r\n } else {\r\n if (dep.enabled) {\r\n dep.disable();\r\n }\r\n if (index.enabled) {\r\n index.disable();\r\n }\r\n }\r\n })\r\n }\r\n\r\n private _toggleDefaultOptions(enable: boolean): void {\r\n const defDep = this.form.get(`defDep`);\r\n const defIndex = this.form.get('defIndex')\r\n\r\n if (defDep) {\r\n if (enable) {\r\n if (defDep.disabled) {\r\n defDep.enable();\r\n }\r\n if (defIndex.disabled) {\r\n defIndex.enable();\r\n }\r\n } else {\r\n if (defDep.enabled) {\r\n defDep.disable();\r\n }\r\n if (defIndex.enabled) {\r\n defIndex.disable();\r\n }\r\n }\r\n }\r\n }\r\n}\r\n","\r\n
\r\n
    \r\n
  • \r\n
    \r\n 0 ? '' : 'empty-tree-node'\" *ngIf=\"!isExpanded(topLevel); else collapse\" (click)=\"expandClass(topLevel)\">\r\n \r\n 0 ? '' : 'empty-tree-node'\" (click)=\"collapseClass(topLevel)\">\r\n \r\n {{ topLevel.name }}\r\n
    \r\n
      \r\n
    • \r\n
      \r\n 0 ? '' : 'empty-tree-node'\" *ngIf=\"!isExpanded(secondLevel); else collapseSecondLevel\" (click)=\"expandClass(secondLevel)\">\r\n \r\n 0 ? '' : 'empty-tree-node'\" (click)=\"collapseClass(secondLevel)\">\r\n \r\n {{ secondLevel.name }}\r\n
      \r\n
        \r\n
      • \r\n
        \r\n {{ thirdLevel.name }}\r\n
        \r\n
      • \r\n
      \r\n
    • \r\n
    \r\n
  • \r\n
\r\n
\r\n
\r\n","import { Component, ViewChild, ElementRef, OnInit } from '@angular/core';\r\nimport { animate, trigger, transition, style } from '@angular/animations';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AssetClassificationRepository } from '../../Repositories/assetClassification.repository';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\nexport interface AssetClassPickerParams {\r\n assetClassificationId: number;\r\n assetClassifications: Compliance.AssetClassificationModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'asset-class-picker-modal',\r\n templateUrl: './assetClassPicker.component.html',\r\n animations: [\r\n trigger('pickerEnter', [\r\n transition(':enter', [\r\n style({ opacity: 0, transform: 'translateX(-2%)' }),\r\n animate(125, style({ opacity: 1, transform: 'translateX(0)' }))\r\n ]),\r\n transition(':leave', [\r\n animate(100, style({ opacity: 0, transform: 'translateX(-2%)' }))\r\n ])\r\n ])\r\n ]\r\n})\r\nexport class AssetClassPickerComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private _modalRef: BsModalRef,\r\n private _assetClassificationRepository: AssetClassificationRepository,\r\n private _elem: ElementRef\r\n ) { }\r\n\r\n @ViewChild('.active-class-picker') selectedAssetClass: ElementRef;\r\n params: AssetClassPickerParams;\r\n result: Compliance.AssetClassificationModel;\r\n assetClassifications: Compliance.AssetClassificationModel[];\r\n\r\n private _expandedAssetClassifications: Set = new Set();\r\n\r\n async ngOnInit(): Promise {\r\n const result = this.params.assetClassifications || await lastValueFrom(this._assetClassificationRepository.getAssetClassifications());\r\n\r\n this.assetClassifications = result;\r\n if (this.params.assetClassificationId) {\r\n this.assetClassifications.forEach(topLevel => {\r\n if (topLevel.childClassifications) {\r\n topLevel.childClassifications.forEach(secondLevel => {\r\n if (secondLevel.assetClassificationId === this.params.assetClassificationId) {\r\n this._expandedAssetClassifications.add(topLevel.assetClassificationId);\r\n } else if (secondLevel.childClassifications &&\r\n secondLevel.childClassifications.find(ac => ac.assetClassificationId === this.params.assetClassificationId)) {\r\n this._expandedAssetClassifications.add(topLevel.assetClassificationId);\r\n this._expandedAssetClassifications.add(secondLevel.assetClassificationId);\r\n }\r\n });\r\n }\r\n });\r\n }\r\n\r\n setTimeout(() => {\r\n const elem = this._elem.nativeElement.querySelector('.active-class-link');\r\n if (elem) {\r\n elem.scrollIntoView({ behavior: 'smooth' });\r\n }\r\n }, 0);\r\n }\r\n\r\n selectAssetClass(assetClassification: Compliance.AssetClassificationModel): void {\r\n this.result = assetClassification;\r\n this._modalRef.hide();\r\n }\r\n\r\n isSelected(assetClassification: Compliance.AssetClassificationModel): boolean {\r\n return assetClassification.assetClassificationId === this.params.assetClassificationId;\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n isExpanded(classification: Compliance.AssetClassificationModel): boolean {\r\n return this._expandedAssetClassifications.has(classification.assetClassificationId);\r\n }\r\n\r\n expandClass(classification: Compliance.AssetClassificationModel): void {\r\n this._expandedAssetClassifications.add(classification.assetClassificationId);\r\n }\r\n\r\n collapseClass(classification: Compliance.AssetClassificationModel): void {\r\n this._expandedAssetClassifications.delete(classification.assetClassificationId);\r\n }\r\n}\r\n","\r\n\r\n {{model.extraPath}}{{model.name}}\r\n\r\n\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n","import { Component, OnDestroy, OnInit, OnChanges, Input, Output, EventEmitter, SimpleChanges, SimpleChange } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { AssetClassificationRepository } from '../../Repositories';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { AssetClassPickerComponent, AssetClassPickerParams } from './assetClassPicker.component';\r\nimport { of as observableOf, Observable, Subscription } from 'rxjs';\r\nimport { first, mergeMap } from 'rxjs/operators';\r\n\r\ninterface AssetClassSelectorComponentChanges extends SimpleChanges {\r\n assetClassificationId: SimpleChange\r\n}\r\n\r\n@Component({\r\n selector: 'asset-class-selector',\r\n templateUrl: './assetClassSelector.component.html',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: AssetClassSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class AssetClassSelectorComponent implements OnInit, OnDestroy, OnChanges, ControlValueAccessor {\r\n constructor(\r\n private readonly _assetClassificationRepository: AssetClassificationRepository,\r\n private readonly _modalService: WeissmanModalService\r\n ) { }\r\n\r\n @Input() assetClassificationId: number;\r\n @Input() assetClassificationName: string;\r\n @Input() isDisabled: boolean = false;\r\n @Input() isRequiredField: boolean = true;\r\n @Input() isOverridden: boolean = false;\r\n @Input() assetClassifications: Compliance.AssetClassificationModel[] = null;\r\n @Input() container: string = 'body';\r\n\r\n @Output() assetClassificationIdChange = new EventEmitter();\r\n @Output() assetClassificationChange = new EventEmitter();\r\n\r\n assetClassificationFilter: string = '';\r\n\r\n // this component will be considered initialized when the asset classifications have been loaded\r\n // in the meanwhile, any select asset classification attempts will be skipped\r\n isInitialized: boolean = false;\r\n\r\n assetClassifications$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.assetClassificationFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterAssetClassifications(token)));\r\n\r\n private _assetClassificationSubscription: Subscription;\r\n private _onChangeFn: any;\r\n private _onTouchedFn: any;\r\n\r\n\r\n private _assetClassifications: Compliance.AssetClassificationModel[] = [];\r\n\r\n ngOnInit(): void {\r\n if (this.assetClassifications){\r\n this._populateAssetClassifications(this.assetClassifications);\r\n } else {\r\n this._assetClassificationSubscription = this._assetClassificationRepository\r\n .getAssetClassifications().pipe(\r\n first())\r\n .subscribe(data => {\r\n const assetClassifications: any = data;\r\n this._populateAssetClassifications(assetClassifications);\r\n });\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._assetClassificationSubscription && this._assetClassificationSubscription.unsubscribe();\r\n }\r\n\r\n ngOnChanges(changes: AssetClassSelectorComponentChanges): void {\r\n if (changes.assetClassificationId) {\r\n this._selectAssetClass(this.assetClassificationId);\r\n }\r\n }\r\n\r\n writeValue(assetClassificationId: number): void {\r\n this._selectAssetClass(assetClassificationId);\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState?(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n onAssetClassificationBlur(): void {\r\n if (!this.isRequiredField && this.assetClassificationFilter === '') {\r\n this.assetClassificationId = null;\r\n this.assetClassificationName = null;\r\n this.assetClassificationChange.emit(null);\r\n }\r\n\r\n this._selectAssetClass(this.assetClassificationId);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onAssetClassificationSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const assetClass = match.item as Compliance.AssetClassificationModel;\r\n this._selectAssetClass(assetClass.assetClassificationId);\r\n this.assetClassificationIdChange.emit(assetClass.assetClassificationId);\r\n this.assetClassificationChange.emit(assetClass);\r\n }\r\n }\r\n\r\n async openPickerModal(): Promise {\r\n const params: AssetClassPickerParams = {\r\n assetClassificationId: this.assetClassificationId,\r\n assetClassifications: this.assetClassifications\r\n };\r\n\r\n const result = await this._modalService.showAsync(AssetClassPickerComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._selectAssetClass(result.assetClassificationId);\r\n this.assetClassificationIdChange.emit(this.assetClassificationId);\r\n this.assetClassificationChange.emit(result);\r\n }\r\n\r\n private _filterAssetClassifications(filter: string): Observable {\r\n if (filter === null || filter === undefined) filter = '';\r\n\r\n return observableOf(\r\n (this._assetClassifications || []).filter(i => i.name.toLowerCase().includes(filter.toLowerCase()))\r\n );\r\n }\r\n\r\n private _selectAssetClass(assetClassificationId: number, assetClassificationName?: string): void {\r\n // keep track of the value that the classification is being set to\r\n this.assetClassificationId = assetClassificationId;\r\n\r\n // if not initialized then return\r\n // when initialized the asset class ID that is being tracked (above) will be selected\r\n if (!this.isInitialized) {\r\n return;\r\n }\r\n\r\n const assetClass = this._assetClassifications.find(ac => ac.assetClassificationId === assetClassificationId || ac.name === assetClassificationName);\r\n if (assetClass) {\r\n this.assetClassificationId = assetClass.assetClassificationId;\r\n this.assetClassificationFilter = assetClass.name;\r\n } else {\r\n this.assetClassificationId = null;\r\n this.assetClassificationFilter = assetClassificationName;\r\n }\r\n\r\n this._onChangeFn && this._onChangeFn(this.assetClassificationId);\r\n }\r\n\r\n private _populateAssetClassifications(assetClassifications: any){\r\n if (assetClassifications) {\r\n assetClassifications.forEach(outerItem => {\r\n this._assetClassifications.push(outerItem);\r\n if (outerItem.childClassifications) {\r\n outerItem.childClassifications.forEach(secondLevelItem => {\r\n secondLevelItem.extraPath = `${outerItem.name } > `;\r\n this._assetClassifications.push(secondLevelItem);\r\n if (secondLevelItem.childClassifications) {\r\n secondLevelItem.childClassifications.forEach(thirdLevelItem => {\r\n thirdLevelItem.extraPath = `${secondLevelItem.extraPath + secondLevelItem.name } > `;\r\n this._assetClassifications.push(thirdLevelItem);\r\n });\r\n }\r\n });\r\n }\r\n });\r\n }\r\n\r\n this.isInitialized = true;\r\n this._selectAssetClass(this.assetClassificationId, this.assetClassificationName);\r\n }\r\n}\r\n","\r\n","import { Component, EventEmitter, Input, OnInit, Output } from \"@angular/core\";\r\n\r\n@Component({\r\n selector: 'return-asset-bulk-update-action',\r\n templateUrl: './returnAssetBulkUpdateAction.component.html',\r\n styles: ['select {width:120px}']\r\n})\r\nexport class ReturnAssetBulkUpdateActionComponent implements OnInit{\r\n constructor(\r\n ){\r\n this.possibleActions = [\r\n { name: 'No Change', value: Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange },\r\n { name: 'Change To', value: Compliance.ReturnAssetBulkUpdateFieldActionEnum.ChangeTo },\r\n { name: 'Remove Override', value: Compliance.ReturnAssetBulkUpdateFieldActionEnum.RemoveOverride },\r\n { name: 'Set To Classification Default', value: Compliance.ReturnAssetBulkUpdateFieldActionEnum.SetToClassificationDefault }\r\n ];\r\n }\r\n\r\n @Input() fieldAction: Compliance.ReturnAssetBulkUpdateFieldActionEnum;\r\n @Output() fieldActionChange = new EventEmitter();\r\n @Input() disabled: boolean;\r\n @Input() fieldHasOverrides: boolean = false;\r\n @Input() onlyAllowRemoveOverrides: boolean = false;\r\n @Input() fieldHasClassificationDefault: boolean = false;\r\n @Output() fieldActionNameChange: EventEmitter = new EventEmitter();\r\n\r\n possibleActions: Compliance.NameValuePair[];\r\n enabledActions: Compliance.NameValuePair[];\r\n selectedAction: Compliance.NameValuePair;\r\n\r\n ngOnInit(): void {\r\n this.selectedAction = this.possibleActions[0];\r\n this.refresh(this.onlyAllowRemoveOverrides, this.fieldHasOverrides, this.fieldHasClassificationDefault);\r\n }\r\n\r\n refresh(onlyAllowRemoveOverrides: boolean, fieldHasOverrides: boolean, fieldHasClassificationDefault: boolean): void {\r\n if(onlyAllowRemoveOverrides) {\r\n this.enabledActions = this.possibleActions.filter(i => i.value === Compliance.ReturnAssetBulkUpdateFieldActionEnum.RemoveOverride || i.value === Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange);\r\n } else if (!fieldHasOverrides) {\r\n this.enabledActions = this.possibleActions.filter(i => i.value !== Compliance.ReturnAssetBulkUpdateFieldActionEnum.RemoveOverride);\r\n } else {\r\n this.enabledActions = this.possibleActions;\r\n }\r\n\r\n if (!fieldHasClassificationDefault) {\r\n this.enabledActions = this.enabledActions.filter(i => i.value !== Compliance.ReturnAssetBulkUpdateFieldActionEnum.SetToClassificationDefault);\r\n }\r\n }\r\n\r\n fieldActionChanged(action: Compliance.NameValuePair) : void{\r\n this.selectedAction = action;\r\n this.fieldActionChange.next(action.value);\r\n this.fieldActionNameChange.next(action.name);\r\n }\r\n\r\n isSelected(action: Compliance.ReturnAssetBulkUpdateFieldActionEnum): boolean{\r\n return action === Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n}\r\n","\r\n\r\n {{ model.extraPath }}{{ model.name }} {{ model.description?.length ? '(' + model.description + ')' : '' }} {{ model.depreciationTableName}} ({{ model.depreciationTableLife }} year life)\r\n\r\n\r\n
\r\n \r\n
\r\n","import { of as observableOf, Observable } from 'rxjs';\r\nimport { mergeMap } from 'rxjs/operators';\r\nimport { Component, OnInit, OnChanges, Input, Output, EventEmitter, SimpleChanges, SimpleChange } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { ReturnAssetsService } from '../returnAssets.service';\r\n\r\ninterface ScheduleSelectorComponentChanges extends SimpleChanges {\r\n formRevisionScheduleId: SimpleChange\r\n}\r\n\r\n@Component({\r\n selector: 'schedule-selector',\r\n templateUrl: './scheduleSelector.component.html',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: ScheduleSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class ScheduleSelectorComponent implements OnInit, OnChanges, ControlValueAccessor {\r\n constructor(\r\n private readonly _returnAssetsService: ReturnAssetsService\r\n ) { }\r\n\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n @Input() formRevisionScheduleId: number;\r\n @Input() formRevisionScheduleName: string;\r\n @Input() isDisabled: boolean = false;\r\n @Input() isRequiredField: boolean = true;\r\n @Input() isOverridden: boolean = false;\r\n @Input() reportingAssetIds: number[];\r\n\r\n @Output() formRevisionScheduleIdChange = new EventEmitter();\r\n @Output() formRevisionScheduleChange = new EventEmitter();\r\n \r\n scheduleFilter: string = '';\r\n\r\n isInitialized: boolean = false;\r\n\r\n schedules$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.scheduleFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterSchedules(token)));\r\n\r\n private _schedules: Compliance.ReturnAssetScheduleDetailsAssignedItemModel[] = [];\r\n private _scheduleData: Compliance.ReturnAssetScheduleDetailsAssignedItemModel[] = [];\r\n\r\n async ngOnInit(): Promise {\r\n this._scheduleData = await this._returnAssetsService.getScheduleDetails();\r\n\r\n // Filter out non-reportable schedules\r\n this._scheduleData = this._scheduleData.filter(x => x.formRevisionScheduleId !== null);\r\n\r\n this._scheduleData\r\n .forEach(i => {\r\n const schedule = this._schedules.find(x => x.formRevisionScheduleId === i.formRevisionScheduleId && x.depreciationTableId === i.depreciationTableId); \r\n\r\n if (!schedule) {\r\n this._schedules.push(i);\r\n }\r\n });\r\n\r\n this.isInitialized = true;\r\n this._selectSchedule(this.formRevisionScheduleId, this.formRevisionScheduleName);\r\n }\r\n\r\n ngOnChanges(changes: ScheduleSelectorComponentChanges): void {\r\n if (changes.formRevisionScheduleId) {\r\n this._selectSchedule(this.formRevisionScheduleId);\r\n }\r\n }\r\n\r\n writeValue(formRevisionScheduleId: number): void {\r\n this._selectSchedule(formRevisionScheduleId);\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState?(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n onScheduleBlur(): void {\r\n if (!this.isRequiredField && this.scheduleFilter === '') {\r\n this.formRevisionScheduleId = null;\r\n this.formRevisionScheduleName = null;\r\n this.formRevisionScheduleChange.emit(null);\r\n }\r\n\r\n this._selectSchedule(this.formRevisionScheduleId);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onScheduleSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const schedule = match.item as Compliance.ReturnAssetScheduleDetailsAssignedItemModel;\r\n this._selectSchedule(schedule.formRevisionScheduleId);\r\n this.formRevisionScheduleIdChange.emit(schedule.formRevisionScheduleId);\r\n this.formRevisionScheduleChange.emit(schedule);\r\n }\r\n }\r\n\r\n private _filterSchedules(filter: string): Observable {\r\n if (filter === null || filter === undefined) filter = '';\r\n\r\n return observableOf(\r\n (this._schedules || []).filter(i => i.name.toLowerCase().includes(filter.toLowerCase()))\r\n );\r\n }\r\n\r\n private _selectSchedule(formRevisionScheduleId: number, scheduleName?: string): void {\r\n // keep track of the value that the classification is being set to\r\n this.formRevisionScheduleId = formRevisionScheduleId;\r\n\r\n // if not initialized then return\r\n // when initialized the asset class ID that is being tracked (above) will be selected\r\n if (!this.isInitialized) {\r\n return;\r\n }\r\n\r\n const schedule = this._schedules.find(s => s.formRevisionScheduleId === formRevisionScheduleId || s.name === scheduleName);\r\n if (schedule) {\r\n this.formRevisionScheduleId = schedule.formRevisionScheduleId;\r\n this.scheduleFilter = schedule.name;\r\n } else {\r\n this.formRevisionScheduleId = null;\r\n this.scheduleFilter = null;\r\n }\r\n\r\n this._onChangeFn && this._onChangeFn(this.formRevisionScheduleId);\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n Asset Return Status \r\n \r\n \r\n \r\n \r\n \r\n
Classification\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
Schedule Assignment\r\n \r\n
Prior Schedule\r\n \r\n \r\n \r\n
Additional Depreciation\r\n \r\n \r\n
\r\n \r\n
\r\n
Estimated FMV\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, ViewChild } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorService, BusyIndicatorRef } from '../../../../../Busy-Indicator';\r\nimport { FormRepository, ReturnAssetRepository } from '../../../../Repositories';\r\nimport { ReturnAssetBulkUpdateActionComponent } from './returnAssetBulkUpdateAction.component';\r\nimport { IWeissmanModalComponent, WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport { ReturnAssetsService } from '../returnAssets.service';\r\nimport {\r\n AssessorTablePickerComponent,\r\n AssessorTablePickerParams,\r\n AssessorTablePickerResult,\r\n LockedAssessorAssignments\r\n} from '../Assessor-Table-Picker/assessorTablePicker.component';\r\nimport { ReturnService } from '../../../return.service';\r\nimport ReturnAssetBulkUpdateFieldActionEnum = Compliance.ReturnAssetBulkUpdateFieldActionEnum;\r\nimport { ProductAnalyticsService } from \"../../../../../Common/Amplitude/productAnalytics.service\";\r\nimport { lastValueFrom } from \"rxjs\";\r\n\r\nexport interface ReturnAssetBulkUpdateParams {\r\n filingBatchId: number;\r\n searchModel: Compliance.ReturnAssetSearchModel;\r\n selectedCount: number;\r\n showPriorScheduleField: boolean;\r\n}\r\n\r\nexport interface ReturnAssetBulkUpdateResult {\r\n requestSchedules: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'return-asset-bulk-update',\r\n templateUrl: './returnAssetBulkUpdate.component.html'\r\n})\r\nexport class ReturnAssetBulkUpdateComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnAssetRepository: ReturnAssetRepository,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {\r\n this.possibleReturnStatuses = [\r\n { name: 'Suppress', value: Compliance.ReturnAssetPriorReturnStatusEnum.NotChanged },\r\n { name: 'Transfer In', value: Compliance.ReturnAssetPriorReturnStatusEnum.TransferIn },\r\n { name: 'Acquisition', value: Compliance.ReturnAssetPriorReturnStatusEnum.New },\r\n { name: 'Transfer Out', value: Compliance.ReturnAssetPriorReturnStatusEnum.TransferOut },\r\n { name: 'Disposal', value: Compliance.ReturnAssetPriorReturnStatusEnum.Retired }\r\n ];\r\n }\r\n\r\n private _busyRef: BusyIndicatorRef;\r\n private _busyRefId = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n\r\n @ViewChild('returnStatusActionField', { static: true }) returnStatusActionField: ReturnAssetBulkUpdateActionComponent;\r\n\r\n params: ReturnAssetBulkUpdateParams;\r\n result: ReturnAssetBulkUpdateResult;\r\n\r\n bulkUpdateMetadata: Compliance.ReturnAssetBulkUpdateMetadataModel;\r\n selectedRowsReturnStatus: Compliance.ReturnAssetPriorReturnStatusEnum;\r\n assetReturnStatusTooltipText: string;\r\n isAssetReturnStatusFieldDisabled: boolean = true;\r\n showAssetReturnStatusTooltip: boolean = false;\r\n allowAssetReturnStatusRemoveOverride: boolean = false;\r\n classificationId?: number;\r\n classificationIdAction?: Compliance.ReturnAssetBulkUpdateFieldActionEnum = Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange;\r\n returnStatus?: Compliance.ReturnAssetPriorReturnStatusEnum = Compliance.ReturnAssetPriorReturnStatusEnum.NotChanged;\r\n returnStatusAction?: Compliance.ReturnAssetBulkUpdateFieldActionEnum = Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange;\r\n scheduleAssignmentAction?: Compliance.ReturnAssetBulkUpdateFieldActionEnum = Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange;\r\n formRevisionSchedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel;\r\n priorScheduleAction?: Compliance.ReturnAssetBulkUpdateFieldActionEnum = Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange;\r\n possibleReturnStatuses: Compliance.NameValuePair[];\r\n assessorFactorTableAssignments: Compliance.ReturnAssetAssessorFactorTableAssignment[] = [];\r\n additionalDepreciationAction?: Compliance.ReturnAssetBulkUpdateFieldActionEnum = Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange;\r\n additionalDepreciation?: number;\r\n estimatedFMVAction?: Compliance.ReturnAssetBulkUpdateFieldActionEnum = Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange;\r\n estimatedFMV?: number;\r\n\r\n // Display value collected for Amplitude analytics\r\n classificationName: string;\r\n scheduleAssignmentName: string;\r\n\r\n async ngOnInit(): Promise {\r\n await this._loadBulkUpdateMetadata();\r\n }\r\n\r\n formRevisionScheduleChange(schedule) {\r\n this.formRevisionSchedule = schedule;\r\n }\r\n\r\n async save(): Promise {\r\n this._showBusyIndicator('Saving');\r\n\r\n try {\r\n\r\n if (this.priorScheduleAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.ChangeTo && this.formRevisionSchedule) {\r\n const success = await this._populateAssessorFactorTableAssignments();\r\n\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n const returnAssetBulkUpdateModel: Compliance.ReturnAssetBulkUpdateModel = {\r\n classificationId: this.classificationId,\r\n classificationIdAction: this.classificationIdAction,\r\n filingBatchId: this.params.filingBatchId,\r\n returnStatus: this.returnStatus,\r\n returnStatusAction: this.returnStatusAction,\r\n scheduleAssignmentAction: this.scheduleAssignmentAction,\r\n searchModel: this.params.searchModel,\r\n priorScheduleAssignmentAction: this.priorScheduleAction,\r\n priorScheduleId: this.formRevisionSchedule && this.formRevisionSchedule.formRevisionScheduleId,\r\n assessorFactorTableAssignments: this.assessorFactorTableAssignments,\r\n additionalDepreciation: this.additionalDepreciation,\r\n additionalDepreciationAction: this.additionalDepreciationAction,\r\n estimatedFMV: this.estimatedFMV,\r\n estimatedFMVAction: this.estimatedFMVAction,\r\n parcelIds: this._returnService.sharedState.returns.map(x => x.parcelId),\r\n taxYear: this._returnService.taxYear,\r\n formRevisionId: this._returnService.sharedState.formRevisionId,\r\n lienDate: this._returnService.lienDate\r\n };\r\n\r\n await lastValueFrom(this._returnAssetRepository.bulkUpdate(returnAssetBulkUpdateModel));\r\n\r\n this.result = { requestSchedules: !!(this.scheduleAssignmentAction || this.classificationIdAction) };\r\n\r\n const analytics = {};\r\n const removeOverride = 'Remove Override';\r\n if (this.returnStatusAction !== Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange) {\r\n const assetReturnStatus = this.possibleReturnStatuses.find(x => x.value === this.returnStatus);\r\n analytics['assetReturnStatus'] = this.returnStatusAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.ChangeTo ? assetReturnStatus.name : removeOverride;\r\n }\r\n if (this.classificationIdAction !== Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange) {\r\n analytics['classificationName'] = this.classificationIdAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.ChangeTo ? this.classificationName : removeOverride;\r\n }\r\n if (this.scheduleAssignmentAction !== Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange) {\r\n analytics['scheduleAssignment'] = this.scheduleAssignmentAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.ChangeTo ? this.scheduleAssignmentName : removeOverride;\r\n }\r\n if (this.additionalDepreciationAction !== Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange) {\r\n analytics['additionalDepreciation'] = this.additionalDepreciationAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.ChangeTo ? `${this.additionalDepreciation}%` : removeOverride;\r\n }\r\n if (this.estimatedFMVAction !== Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange) {\r\n analytics['estimatedFMV'] = this.estimatedFMVAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.ChangeTo ? `$${this.estimatedFMV}` : removeOverride;\r\n }\r\n this._productAnalyticsService.logEvent('click-bulk-update-OK', analytics);\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this._hideBusyIndicator();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n validateForm(): boolean {\r\n const isValid = this.returnStatusAction !== Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange\r\n || this.scheduleAssignmentAction !== Compliance.ReturnAssetBulkUpdateFieldActionEnum.NoChange\r\n || this.priorScheduleAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.ChangeTo && this.formRevisionSchedule != null\r\n || this.priorScheduleAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.RemoveOverride\r\n || this.priorScheduleAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.SetToClassificationDefault\r\n || this.classificationIdAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.ChangeTo && this.classificationId >= 0\r\n || this.classificationIdAction === Compliance.ReturnAssetBulkUpdateFieldActionEnum.RemoveOverride\r\n || this.additionalDepreciationAction === ReturnAssetBulkUpdateFieldActionEnum.RemoveOverride\r\n || this.additionalDepreciationAction === ReturnAssetBulkUpdateFieldActionEnum.ChangeTo && this.additionalDepreciation >= 0.01 && this.additionalDepreciation <= 100\r\n || this.estimatedFMVAction === ReturnAssetBulkUpdateFieldActionEnum.RemoveOverride\r\n || this.estimatedFMVAction === ReturnAssetBulkUpdateFieldActionEnum.ChangeTo && this.estimatedFMV >= 0.01;\r\n\r\n return isValid;\r\n }\r\n\r\n isDisabled(action: Compliance.ReturnAssetBulkUpdateFieldActionEnum): boolean{\r\n return action !== Compliance.ReturnAssetBulkUpdateFieldActionEnum.ChangeTo;\r\n }\r\n\r\n setClassificationName(classification: Compliance.AssetClassificationModel): void {\r\n if (classification && classification.name) {\r\n this.classificationName = classification.name;\r\n }\r\n }\r\n\r\n setScheduleAssignmentName(scheduleAssignmentName: string) {\r\n if (scheduleAssignmentName) {\r\n this.scheduleAssignmentName = scheduleAssignmentName;\r\n }\r\n }\r\n\r\n private async _loadBulkUpdateMetadata(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n const returnAssetBulkUpdateModel: Compliance.ReturnAssetBulkUpdateModel = {\r\n classificationId: this.classificationId,\r\n classificationIdAction: this.classificationIdAction,\r\n filingBatchId: this.params.filingBatchId,\r\n returnStatus: this.returnStatus,\r\n returnStatusAction: this.returnStatusAction,\r\n scheduleAssignmentAction: this.scheduleAssignmentAction,\r\n searchModel: this.params.searchModel,\r\n priorScheduleAssignmentAction: this.priorScheduleAction,\r\n priorScheduleId: this.formRevisionSchedule && this.formRevisionSchedule.formRevisionScheduleId,\r\n assessorFactorTableAssignments: this.assessorFactorTableAssignments,\r\n additionalDepreciation: this.additionalDepreciation,\r\n additionalDepreciationAction: this.additionalDepreciationAction,\r\n estimatedFMV: this.estimatedFMV,\r\n estimatedFMVAction: this.estimatedFMVAction,\r\n parcelIds: this._returnService.sharedState.returns.map(x => x.parcelId),\r\n taxYear: this._returnService.taxYear,\r\n formRevisionId: this._returnService.sharedState.formRevisionId,\r\n lienDate: this._returnService.lienDate\r\n };\r\n\r\n try {\r\n this.bulkUpdateMetadata = await lastValueFrom(this._returnAssetRepository\r\n .getBulkUpdateMetadata(returnAssetBulkUpdateModel));\r\n this._validateSelectedRecords();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _validateSelectedRecords(): void {\r\n const validReturnStatuses = [ Compliance.ReturnAssetPriorReturnStatusEnum.New,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.TransferIn,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.Retired,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.TransferOut];\r\n\r\n if (this.bulkUpdateMetadata.assetReturnStatuses.length === 0) {\r\n this.isAssetReturnStatusFieldDisabled = true;\r\n return;\r\n }\r\n\r\n if (this.bulkUpdateMetadata.assetReturnStatuses.length > 1) {\r\n this.assetReturnStatusTooltipText = 'This field cannot be updated because the selected records do not have the same Asset Return Status';\r\n this.isAssetReturnStatusFieldDisabled = true;\r\n this.showAssetReturnStatusTooltip = true;\r\n return;\r\n }\r\n\r\n if (this.bulkUpdateMetadata.assetReturnStatuses[0] === Compliance.ReturnAssetPriorReturnStatusEnum.NotChanged) {\r\n this.isAssetReturnStatusFieldDisabled = false;\r\n this.allowAssetReturnStatusRemoveOverride = true;\r\n\r\n for(let i = 0; i < this.bulkUpdateMetadata.calculatedAssetReturnStatuses.length; i++) {\r\n if(!validReturnStatuses.includes(this.bulkUpdateMetadata.calculatedAssetReturnStatuses[i])) {\r\n this.isAssetReturnStatusFieldDisabled = true;\r\n this.allowAssetReturnStatusRemoveOverride = false;\r\n this.showAssetReturnStatusTooltip = true;\r\n this.assetReturnStatusTooltipText = 'This field cannot be updated because the selected records do not have an Asset Return Status which allows it';\r\n break;\r\n }\r\n }\r\n\r\n this.returnStatusActionField.refresh(this.allowAssetReturnStatusRemoveOverride, false, false);\r\n } else if (!validReturnStatuses.includes(this.bulkUpdateMetadata.assetReturnStatuses[0])) {\r\n this.assetReturnStatusTooltipText = 'This field cannot be updated because the selected records do not have an Asset Return Status which allows it';\r\n this.isAssetReturnStatusFieldDisabled = true;\r\n this.showAssetReturnStatusTooltip = true;\r\n } else {\r\n this.isAssetReturnStatusFieldDisabled = false;\r\n this.allowAssetReturnStatusRemoveOverride = false;\r\n\r\n switch(this.bulkUpdateMetadata.assetReturnStatuses[0]) {\r\n case Compliance.ReturnAssetPriorReturnStatusEnum.New:\r\n this.possibleReturnStatuses = this.possibleReturnStatuses.filter(i => i.value === Compliance.ReturnAssetPriorReturnStatusEnum.TransferIn || i.value === Compliance.ReturnAssetPriorReturnStatusEnum.NotChanged);\r\n break;\r\n case Compliance.ReturnAssetPriorReturnStatusEnum.TransferIn:\r\n this.possibleReturnStatuses = this.possibleReturnStatuses.filter(i => i.value === Compliance.ReturnAssetPriorReturnStatusEnum.New || i.value === Compliance.ReturnAssetPriorReturnStatusEnum.NotChanged);\r\n break;\r\n case Compliance.ReturnAssetPriorReturnStatusEnum.Retired:\r\n this.possibleReturnStatuses = this.possibleReturnStatuses.filter(i => i.value === Compliance.ReturnAssetPriorReturnStatusEnum.TransferOut || i.value === Compliance.ReturnAssetPriorReturnStatusEnum.NotChanged);\r\n break;\r\n case Compliance.ReturnAssetPriorReturnStatusEnum.TransferOut:\r\n this.possibleReturnStatuses = this.possibleReturnStatuses.filter(i => i.value === Compliance.ReturnAssetPriorReturnStatusEnum.Retired || i.value === Compliance.ReturnAssetPriorReturnStatusEnum.NotChanged);\r\n break;\r\n }\r\n\r\n for(let i = 0; i < this.bulkUpdateMetadata.calculatedAssetReturnStatuses.length; i++) {\r\n if(this.bulkUpdateMetadata.assetReturnStatuses[0] !== this.bulkUpdateMetadata.calculatedAssetReturnStatuses[i]) {\r\n this.returnStatusActionField.refresh(false, true, false);\r\n break;\r\n }\r\n }\r\n }\r\n }\r\n\r\n private async _populateAssessorFactorTableAssignments(): Promise {\r\n const allAssessors: Compliance.FormRevisionAssessorModel[] = await this._returnAssetsService.getWorkingSetAssessors(this.bulkUpdateMetadata.reportingAssetIds);\r\n\r\n const assessors = allAssessors.filter((assessor: Compliance.FormRevisionAssessorModel) => assessor.assessorId !== null);\r\n\r\n if (!this.formRevisionSchedule.isDepreciable) {\r\n // schedule is not depreciable, do not prompt for factor table\r\n return await this._updateNonDepreciableSchedule(assessors);\r\n } else if (this.formRevisionSchedule.depreciationTableId) {\r\n // update when schedule broken out by factor table\r\n return await this._updateForExpandedScheduleDetail(this.formRevisionSchedule, assessors);\r\n } else if (this.formRevisionSchedule.lockedAssessors && this.formRevisionSchedule.lockedAssessors.some(la => la.isLocked)) {\r\n // update when schedule is locked\r\n return await this._updateLockedSchedule(this.bulkUpdateMetadata.reportingAssetIds, this.formRevisionSchedule, assessors, allAssessors);\r\n } else {\r\n // otherwise user to select a factor table\r\n return await this._askForFactorAndUpdate(this.bulkUpdateMetadata.reportingAssetIds, this.formRevisionSchedule, assessors, allAssessors);\r\n }\r\n }\r\n\r\n private async _updateAssessorFactorTableAssignments(assessorPickerResult: AssessorTablePickerResult): Promise {\r\n this.assessorFactorTableAssignments = [];\r\n\r\n for (let key in assessorPickerResult.selection) {\r\n if (assessorPickerResult.selection.hasOwnProperty(key)) {\r\n this.assessorFactorTableAssignments.push({\r\n assessorId: parseInt(key),\r\n depreciationTableId: assessorPickerResult.selection[key].depreciationTableId,\r\n indexTableId: assessorPickerResult.selection[key].indexTableId,\r\n });\r\n }\r\n }\r\n\r\n return true;\r\n }\r\n\r\n private async _updateForExpandedScheduleDetail(schedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel, assessors) : Promise {\r\n const selection = {}; // mirrors modal structure\r\n assessors.forEach((assessor: Compliance.FormRevisionAssessorModel) => {\r\n selection[assessor.assessorId] = {\r\n depreciationTableId: schedule.depreciationTableId,\r\n indexTableId: null\r\n }\r\n });\r\n\r\n const result: AssessorTablePickerResult = {\r\n selection: selection\r\n };\r\n\r\n // save assets with all assessors associated to factor table\r\n return await this._updateAssessorFactorTableAssignments(result);\r\n }\r\n\r\n private async _updateNonDepreciableSchedule(assessors): Promise {\r\n const selection = {}; // mirrors modal structure\r\n assessors.forEach((assessor: Compliance.FormRevisionAssessorModel) => {\r\n selection[assessor.assessorId] = {\r\n depreciationTableId: null,\r\n indexTableId: null\r\n }\r\n });\r\n\r\n const result: AssessorTablePickerResult = {\r\n selection: selection\r\n };\r\n\r\n // save assets with all assessors\r\n return await this._updateAssessorFactorTableAssignments(result);\r\n }\r\n\r\n private async _updateLockedSchedule(reportingAssetIds: number[], schedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel, assessors, allAssessors) : Promise{\r\n const reportingAssetAssessorMap = await lastValueFrom(this._returnAssetRepository.getWorkingSetReportingAssetAssessorsByFilingBatch(this._returnService.filingBatchId, {\r\n reportingAssetIds: reportingAssetIds,\r\n formRevisionId: this._returnService.formRevisionId,\r\n parcelIds: [],\r\n }));\r\n\r\n // check to see if all are locked. If so, setup the update.\r\n const nullAssessor = schedule.lockedAssessors.find(x => x.assessorId === null);\r\n const areAllLocked = reportingAssetAssessorMap.every(x => {\r\n let assessorAssignment = schedule.lockedAssessors.find(la => la.assessorId === x.assessorId);\r\n if (!assessorAssignment) assessorAssignment = nullAssessor;\r\n return assessorAssignment.isLocked;\r\n });\r\n\r\n const selection: { [assessorId: number]: LockedAssessorAssignments } = {}; // mirrors modal structure\r\n reportingAssetAssessorMap.forEach((x: Compliance.ReportingAssetAssessorModel) => {\r\n let assessorAssignment = schedule.lockedAssessors.find(la => la.assessorId === x.assessorId);\r\n if (!assessorAssignment) assessorAssignment = nullAssessor;\r\n\r\n if (assessorAssignment.isLocked) {\r\n selection[x.assessorId] = {\r\n depreciationTableId: assessorAssignment.depreciationFactorTableId,\r\n indexTableId: null\r\n }\r\n }\r\n });\r\n\r\n const result: AssessorTablePickerResult = {\r\n selection: selection\r\n };\r\n\r\n if (areAllLocked) {\r\n // update assignments with all assessors associated to factor table\r\n return await this._updateAssessorFactorTableAssignments(result);\r\n } else {\r\n // open dialog, with locked assets already assigned.\r\n return await this._askForFactorAndUpdate(reportingAssetIds, schedule, assessors, allAssessors, selection);\r\n }\r\n }\r\n\r\n private async _askForFactorAndUpdate(\r\n reportingAssetIds: number[],\r\n schedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel,\r\n assessors,\r\n allAssessors,\r\n lockedAssessorAssignments: { [assessorId: number]: LockedAssessorAssignments } = {}): Promise {\r\n const model: Compliance.AssessorFactorTableSearchModel = {\r\n assessorIds: assessors.map(assessor => assessor.assessorId),\r\n formRevisionScheduleId: schedule.formRevisionScheduleId\r\n };\r\n\r\n const assessorFactorTableResult: Compliance.AssessorFactorTableModel[] = await lastValueFrom(this._returnAssetRepository.getAssessorFactorTables(this._returnService.filingBatchId, model));\r\n\r\n const assessorFactorTables = assessorFactorTableResult.filter(x => x.assessorId !== null && !x.isCompany);\r\n const defaultAssessorFactorTables = assessorFactorTableResult.find(x => x.assessorId === null && !x.isCompany);\r\n const defaultFactorTables = defaultAssessorFactorTables ? defaultAssessorFactorTables.factorTables : [];\r\n const defaultAssessor = allAssessors.find((x: Compliance.FormRevisionAssessorModel) => x.assessorId === null);\r\n const companyDefaultAssessorTables = assessorFactorTableResult.filter(x => x.isCompany && x.assessorId === null);\r\n const companyAssessorTables = assessorFactorTableResult.filter(x => x.isCompany && x.assessorId !== null);\r\n\r\n const params: AssessorTablePickerParams = {\r\n defaultAssessor: defaultAssessor,\r\n reportingAssetIds: reportingAssetIds,\r\n assessors: assessors,\r\n defaultFactorTables: [...companyDefaultAssessorTables.reduce((acc, x) => [...acc, ...x.factorTables], []), ...defaultFactorTables],\r\n assessorFactorTables: [...companyAssessorTables, ...assessorFactorTables],\r\n lockedAssessorAssignments: lockedAssessorAssignments\r\n };\r\n\r\n this._hideBusyIndicator();\r\n\r\n const result = await this._modalService.showAsync(AssessorTablePickerComponent, params, 'modal-xl');\r\n\r\n if (result && result.selection) {\r\n this._showBusyIndicator('Saving');\r\n\r\n return await this._updateAssessorFactorTableAssignments(result);\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n private _showBusyIndicator(message: string): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this._busyRefId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this._busyRefId,\r\n message\r\n });\r\n\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const ASSET_DETAILS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'asset-info.source-column',\r\n tooltipText: 'Values for the asset from the applicable asset import.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-info.reporting-column',\r\n tooltipText: 'Values for the asset including overrides by the user. Red text in the Reported Value column indicates an override of the Source Value.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-info.new-split',\r\n tooltipText: 'Create a new split of the asset sharing the same import source.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'asset-info.delete-split',\r\n tooltipText: 'Delete this split of the asset. Other asset(s) from the same import source will be unaffected.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'asset-info.acquisition-date-field',\r\n tooltipText: 'The acquisition date is used to determine the earliest lien date at which the asset will appear.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-info.acqDateAssetDescriptors', // dynamically added so doesn't follow typical convention\r\n tooltipText: 'Select which field will be used to determine the effective acqusition date for this asset and any asset splits.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'asset-info.disposed-date-field',\r\n tooltipText: 'Date at which asset is no longer considered for tax purposes.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-info.cost-field',\r\n tooltipText: 'Cost of asset is used for purposes of calculations.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-info.net-book-value-row-label',\r\n tooltipText: 'Net Book Value of asset is used for purposes of calculations.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-info.costAssetDescriptors', // dynamically added so doesn't follow typical convention\r\n tooltipText: 'Select which field will be used to determine the cost for this asset and any asset splits.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'asset-info.cost-selector-arrow',\r\n tooltipText: 'Alternative cost field has been selected for this asset.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'asset-info.acquisition-date-selector-arrow',\r\n tooltipText: 'Alternative acquisition date field has been selected for this asset.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'asset-info.add-cost-adjustment',\r\n tooltipText: 'Cost adjustments can be added to the source cost value for the asset. If the cost is overridden it will ignore these adjustments.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'asset-info.adjusted-source-cost',\r\n tooltipText: 'Cost adjustments are applied to the source cost value for the asset. If the source cost is overridden it will ignore these adjustments.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-info.site-calculated-parcel',\r\n tooltipText: 'Assets are automatically associated with parcels for taxation based upon their site. If overridden, the chosen parcel will replace this behavior for tax return inclusion.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-info.allocate-cost-by-percentage',\r\n tooltipText: 'Open a tool to set the costs of individual split assets using percentages of the source value.',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'asset-info.unattributed-percent',\r\n tooltipText: 'This shows the source percentage amount which still needs to be allocated. When this is zero you can click OK to apply your allocation.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-info.override-all',\r\n tooltipText: 'Override all fields.',\r\n hasIcon: false\r\n },\r\n];\r\n","import { WeissmanKeyValueDisplayPipe } from '../../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe';\r\n\r\nexport class AssetSummary {\r\n constructor(\r\n model: Compliance.AssetModel,\r\n displayPipe: WeissmanKeyValueDisplayPipe, idx: number) {\r\n this._displayPipe = displayPipe;\r\n this._setModel(model, idx);\r\n }\r\n\r\n private _model: Compliance.AssetModel;\r\n private _overrides: Compliance.ReportingAssetOverrideModel;\r\n private readonly _displayPipe: WeissmanKeyValueDisplayPipe;\r\n private _rowIndex: number;\r\n private _transientReportedCost: number = 0;\r\n private _isLocked: boolean = false;\r\n\r\n private _setModel(model: Compliance.AssetModel, idx: number): void {\r\n this._model = model;\r\n this._overrides = (model && model.reportingAssetOverride) || {\r\n reportingAssetId: (model && model.reportingAsset && model.reportingAsset.reportingAssetId) || 0,\r\n reportingAssetOverrideId: (model && model.reportingAssetOverride && model.reportingAssetOverride.reportingAssetOverrideId) || 0,\r\n rowVersion: (model && model.reportingAssetOverride && model.reportingAssetOverride.rowVersion) || null,\r\n isGLAccountIdBlank: false\r\n };\r\n this._isLocked = model.reportingAsset.isLocked;\r\n this._rowIndex = idx;\r\n }\r\n\r\n get isPrimary(): boolean {\r\n return !(this._model.reportingAsset && this._model.reportingAsset && !this._model.reportingAsset.isPrimary);\r\n }\r\n\r\n get alternativeCostDescriptorId(): number {\r\n return this._model.alternativeCostDescriptorId;\r\n }\r\n\r\n // asset number\r\n get sourceAssetNumber(): string {\r\n return this._model && this._model.assetNumber;\r\n }\r\n\r\n get reportedAssetNumber(): string {\r\n return this.reportedAssetNumberHasOverride ? this._overrides.assetNumber : this.sourceAssetNumber;\r\n }\r\n\r\n set reportedAssetNumber(value: string) {\r\n this._overrides.assetNumber = value;\r\n }\r\n\r\n get reportedAssetNumberHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.assetNumber) === -1;\r\n }\r\n\r\n get reportedAssetNumberHasOverrideWithBlank(): boolean {\r\n return this.reportedAssetNumberHasOverride && this.reportedAssetNumber.trim() === '';\r\n }\r\n\r\n get reportedAssetId(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.reportingAssetId;\r\n }\r\n\r\n // rolled up field that takes into account both alternative costs and cost adjustments\r\n get cost(): number {\r\n return this._model ? this._model.cost : null;\r\n }\r\n\r\n get acqDate(): Date {\r\n return this._model ? this._model.acqDate : null;\r\n }\r\n\r\n // acquisition date\r\n get sourceAcqDate(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.acqDate;\r\n }\r\n\r\n get reportedAcqDate(): Date {\r\n return this.reportedAcqDateHasOverride ? this._overrides.acqDate : this.sourceAcqDate;\r\n }\r\n\r\n set reportedAcqDate(value: Date) {\r\n this._overrides.acqDate = value;\r\n }\r\n\r\n get reportedAcqDateHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.acqDate) === -1;\r\n }\r\n\r\n // description\r\n get sourceDescription(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.description;\r\n }\r\n\r\n get reportedDescription(): string {\r\n return this._overrides.description === '' ? this._overrides.description : (this._overrides.description || this.sourceDescription);\r\n }\r\n\r\n set reportedDescription(value: string) {\r\n this._overrides.description = value;\r\n }\r\n\r\n get reportedDescriptionHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.description) === -1;\r\n }\r\n\r\n get reportedDescriptionHasOverrideWithBlank(): boolean {\r\n return this.reportedDescriptionHasOverride && this.reportedDescription.trim() === '';\r\n }\r\n\r\n // company code\r\n get companyId(): number {\r\n return this._model && this._model.companyId;\r\n }\r\n\r\n // company code\r\n get companyCode(): string {\r\n return this._model && this._model.companyCode;\r\n }\r\n\r\n // company name\r\n get companyName(): string {\r\n return this._model && this._model.companyName;\r\n }\r\n\r\n // company calculated\r\n get isCompanyCalculated(): boolean {\r\n return this._model && this._model.sourceAsset && this._model.companyName !== this._model.sourceAsset.sourceCompanyName;\r\n //return true;\r\n }\r\n\r\n // asset verification reason\r\n get assetVerificationReason(): string {\r\n return this._model && this._model.assetVerificationReason;\r\n }\r\n\r\n // asset ownership type\r\n get assetOwnershipType(): string {\r\n return this._model && this._model.assetOwnershipType;\r\n }\r\n\r\n // asset ownership type id\r\n get assetOwnershipTypeId(): number {\r\n return this._model && this._model.assetOwnershipTypeId;\r\n }\r\n\r\n set assetOwnershipTypeId(value: number) {\r\n this._model.assetOwnershipTypeId = value;\r\n }\r\n\r\n // is leasing, in either a from or to capacity\r\n get isLeasedAsset(): boolean {\r\n return this.isLeasedFromOther || this.isLeasedToOther;\r\n }\r\n\r\n // asset is leased to another entity\r\n get isLeasedToOther(): boolean {\r\n if (this._model && this._model.assetOwnershipTypeId == 1) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n // asset is leased from another entity\r\n get isLeasedFromOther(): boolean {\r\n if (this._model && this._model.assetOwnershipTypeId == -1) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n // assessor name\r\n get assessorName(): string {\r\n return this._model && this._model.reportingAsset && (`${this._model.reportingAsset.assessorName || ' ' } ${ this._model.reportingAsset.municipalityName || ' '}`);\r\n }\r\n\r\n // state\r\n get state(): string {\r\n return this._model && this._model.reportingAsset && (this._model.reportingAsset.parcelState ? this._model.reportingAsset.parcelState : this._model.reportingAsset.siteState);\r\n }\r\n\r\n // source state\r\n get sourceState(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.state;\r\n }\r\n\r\n // cost\r\n get sourceCost(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.cost;\r\n }\r\n\r\n get sourceAdjustedCost(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.sourceAdjustedCost;\r\n }\r\n\r\n get reportedCost(): number {\r\n return this.reportedCostHasOverride ? this._overrides.cost : this.sourceCost;\r\n }\r\n\r\n set reportedCost(value: number) {\r\n this._overrides.cost = value;\r\n }\r\n\r\n get reportedCostHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.cost) === -1;\r\n }\r\n\r\n reportedColumnHasOverride(columnName: string): boolean {\r\n return [null, undefined].indexOf(this._overrides[ columnName.toLowerCase() ]) === -1;\r\n }\r\n\r\n get reportedCostHasOverrideWithBlank(): boolean {\r\n return this.reportedCostHasOverride && isNaN(this.reportedCost);\r\n }\r\n\r\n get sourcePriorCost(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.priorCost;\r\n }\r\n\r\n get priorCost(): number {\r\n return this.priorCostHasOverride ? this._overrides.priorCost : this.sourcePriorCost;\r\n }\r\n\r\n get priorCostHasOverride(): boolean {\r\n return this._overrides && this._model.sourceAsset && this._overrides.priorCost !== this._model.sourceAsset.priorCost;\r\n }\r\n\r\n get sourceCostChange(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.costChange;\r\n }\r\n\r\n get costChange(): number {\r\n return this.costChangeHasOverride ? this._overrides.costChange : this.sourceCostChange;\r\n }\r\n\r\n get costChangeHasOverride(): boolean {\r\n return this._overrides && this._model.sourceAsset && this._overrides.costChange !== this._model.sourceAsset.costChange;\r\n }\r\n\r\n // gl account\r\n get sourceGlAccount(): Compliance.GLAccountModel {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.glAccount;\r\n }\r\n\r\n get sourceGlAccountDisplay(): string {\r\n return this.sourceGlAccount ? this._displayPipe.transform(this.sourceGlAccount, this.sourceGlAccount.accountNumber, this.sourceGlAccount.accountName) : '';\r\n }\r\n\r\n get sourceGlAccountNumber(): string {\r\n return this.sourceGlAccount ? this.sourceGlAccount.accountNumber : '';\r\n }\r\n\r\n get sourceGlAccountClassificationId(): number {\r\n return this.sourceGlAccount && this.sourceGlAccount.assetClassificationId;\r\n }\r\n\r\n get reportedGlAccount(): Compliance.GLAccountModel {\r\n return this.reportedGlAccountHasOverride ? this._overrides.glAccount : this.sourceGlAccount;\r\n }\r\n\r\n set reportedGlAccount(value: Compliance.GLAccountModel) {\r\n this._overrides.glAccount = value;\r\n }\r\n\r\n set isReportedGlAccountBlank(value: boolean) {\r\n this._overrides.isGLAccountIdBlank = value;\r\n }\r\n\r\n get reportedGlAccountDisplay(): string {\r\n return this.reportedGlAccount ? this._displayPipe.transform(this.reportedGlAccount, this.reportedGlAccount.accountNumber, this.reportedGlAccount.accountName) : '';\r\n }\r\n\r\n get reportedGlAccountNumber(): string {\r\n return this.reportedGlAccount ? this.reportedGlAccount.accountNumber : '';\r\n }\r\n\r\n get reportedGlAccountHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.glAccount) === -1 || (this.sourceGlAccount && this._overrides.isGLAccountIdBlank);\r\n }\r\n\r\n get reportedGlAccountClassificationId(): number {\r\n return this.reportedGlAccount && this.reportedGlAccount.assetClassificationId;\r\n }\r\n\r\n // site\r\n get sourceSite(): Core.SiteModel {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.site;\r\n }\r\n\r\n get sourceSiteDisplay(): string {\r\n return this.sourceSite ? this._displayPipe.transform(this.sourceSite, this.sourceSite.property, this.sourceSite.name) : '';\r\n }\r\n\r\n get sourceSiteName(): string {\r\n return this.sourceSite ? this.sourceSite.name : '';\r\n }\r\n\r\n get sourceSiteNumber(): string {\r\n return this.sourceSite ? this.sourceSite.property : '';\r\n }\r\n\r\n get reportedSite(): Core.SiteModel {\r\n return this.reportedSiteHasOverride ? this._overrides.site : this.sourceSite;\r\n }\r\n\r\n set reportedSite(value: Core.SiteModel) {\r\n this._overrides.site = value;\r\n }\r\n\r\n get reportedSiteId(): number {\r\n return this.reportedSite && this.reportedSite.siteID;\r\n }\r\n\r\n get reportedSiteDisplay(): string {\r\n return this.reportedSite ? this._displayPipe.transform(this.reportedSite, this.reportedSite.property, this.reportedSite.name) : '';\r\n }\r\n\r\n get reportedSiteName(): string {\r\n return this.reportedSite ? this.reportedSite.name : '';\r\n }\r\n\r\n get reportedSiteNumber(): string {\r\n return this.reportedSite ? this.reportedSite.property : '';\r\n }\r\n\r\n get reportedSiteHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.site) === -1;\r\n }\r\n\r\n get sourceSiteReportingParcelId(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.sourceSiteReportingParcelId;\r\n }\r\n\r\n get reportedParcelId(): number {\r\n return this._model.reportingAsset.assetReportingParcelId ? this._model.reportingAsset.assetReportingParcelId : this._model.reportingAsset.siteReportingParcelId;\r\n }\r\n\r\n set reportedParcelId(value: number) {\r\n this._model.reportingAsset.assetReportingParcelId = value;\r\n }\r\n\r\n get reportedParcelName(): string {\r\n return this._model.reportingAsset.assetReportingParcelAcctNum ? this._model.reportingAsset.assetReportingParcelAcctNum : this.siteReportingParcelName;\r\n }\r\n\r\n set reportedParcelName(value: string) {\r\n this._model.reportingAsset.assetReportingParcelAcctNum = value;\r\n }\r\n\r\n get reportedParcelHasOverride(): boolean {\r\n return this._model.reportingAsset.assetReportingParcelId && (this._model.reportingAsset.assetReportingParcelId !== this._model.reportingAsset.siteReportingParcelId);\r\n }\r\n\r\n // parcel\r\n get siteReportedParcelId(): number {\r\n return this._model.reportingAsset.siteReportingParcelId;\r\n }\r\n\r\n get parcelDisplay(): string {\r\n return this._model.reportingAsset.assetReportingParcelAcctNum ? this._model.reportingAsset.assetReportingParcelAcctNum : this.siteReportingParcelName;\r\n }\r\n\r\n get parcelHasOverride(): boolean {\r\n return this._model && this._model.reportingAsset && [null, undefined].indexOf(this._model.reportingAsset.assetReportingParcelId) === -1;\r\n }\r\n\r\n // site parcel\r\n get siteReportingParcelName(): string {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.siteReportingParcelAcctNum;\r\n }\r\n\r\n // disposed date\r\n get sourceDisposedDate(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.disposedDate;\r\n }\r\n\r\n get reportedDisposedDate(): Date {\r\n return this.reportedDisposedDateHasOverride ? this._overrides.disposedDate : this.sourceDisposedDate;\r\n }\r\n\r\n set reportedDisposedDate(value: Date) {\r\n this._overrides.disposedDate = value;\r\n }\r\n\r\n get reportedDisposedDateHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.disposedDate) === -1;\r\n }\r\n\r\n get rowIndex(): number {\r\n return this._rowIndex;\r\n }\r\n\r\n // effective date\r\n get effectiveDate(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.effectiveDate;\r\n }\r\n\r\n // asset classification\r\n get reportedAssetClassificationDisplay(): string {\r\n return this._model.reportingAsset.assetClassification && this._model.reportingAsset.assetClassification.name;\r\n }\r\n\r\n // asset classification\r\n get reportedAssetClassificationId(): number {\r\n return this._model.reportingAsset.assetClassification && this._model.reportingAsset.assetClassification.assetClassificationId;\r\n }\r\n\r\n set reportedAssetClassificationId(value: number) {\r\n this._model.reportingAsset.assetClassification = {\r\n assetClassificationId: value,\r\n name: '',\r\n allowPerpetual: false,\r\n childClassifications: [],\r\n isInventory: false\r\n };\r\n }\r\n\r\n get assetClassificationHasOverride(): boolean {\r\n const assetClassificationId = this.reportedGlAccountClassificationId || this.sourceGlAccountClassificationId;\r\n return (this._model.reportingAsset.assetClassification &&\r\n this._model.reportingAsset.assetClassification.assetClassificationId !== assetClassificationId)\r\n || (assetClassificationId && !this._model.reportingAsset.assetClassification);\r\n }\r\n\r\n get assetId(): number {\r\n return this._model && this._model && this._model.assetId;\r\n }\r\n\r\n get reportingAssetId(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.reportingAssetId;\r\n }\r\n\r\n // is perpetual\r\n set classificationAllowsPerpetual(allowPerpetual: boolean) {\r\n this._model.reportingAsset.assetClassification.allowPerpetual = allowPerpetual;\r\n }\r\n\r\n get reportingIsPerpetual(): boolean {\r\n let result: boolean = null;\r\n if (this._model.reportingAsset.assetClassification && this._model.reportingAsset.assetClassification.allowPerpetual ||\r\n this._model.reportingAssetOverride && this._model.reportingAssetOverride.glAccount && this._model.reportingAssetOverride.glAccount.allowPerpetual) {\r\n result = this._model.reportingAsset.isPerpetual;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n set reportingIsPerpetual(isPerpetual: boolean) {\r\n this._model.reportingAsset.isPerpetual = isPerpetual;\r\n }\r\n\r\n // is user created\r\n get isUserCreated(): boolean {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.isUserCreated;\r\n }\r\n\r\n // has imported source (for user created asset)\r\n get hasImportedSource(): boolean {\r\n return this._model && this._model.hasImportedSource;\r\n }\r\n\r\n get areSplitAllocationsValid(): boolean {\r\n return this._model && this._model.areSplitAllocationsValid;\r\n }\r\n\r\n get splitAllocationPercentage(): number {\r\n return this._model && this._model.splitAllocationPercentage;\r\n }\r\n\r\n updateModel(model: Compliance.AssetModel): void {\r\n this._setModel(model, this.rowIndex);\r\n }\r\n\r\n getModel(): Compliance.AssetModel {\r\n return this._model;\r\n }\r\n\r\n getOverrides(): Compliance.ReportingAssetOverrideModel {\r\n return this._overrides;\r\n }\r\n\r\n // LeaseClientId\r\n get sourceLeaseClientId(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseClientId;\r\n }\r\n\r\n get reportedLeaseClientId(): string {\r\n return this.isOverride(this._overrides.leaseClientId) ? this._overrides.leaseClientId : this.sourceLeaseClientId;\r\n }\r\n\r\n set reportedLeaseClientId(value: string) {\r\n this._overrides.leaseClientId = value;\r\n }\r\n\r\n get reportedLeaseClientIdHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseClientId) === -1;\r\n }\r\n\r\n // LeaseLocationName\r\n get sourceLeaseLocationName(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseLocationName;\r\n }\r\n\r\n get reportedLeaseLocationName(): string {\r\n return this.isOverride(this._overrides.leaseLocationName) ? this._overrides.leaseLocationName : this.sourceLeaseLocationName;\r\n }\r\n\r\n set reportedLeaseLocationName(value: string) {\r\n this._overrides.leaseLocationName = value;\r\n }\r\n\r\n get reportedLeaseLocationNameHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseLocationName) === -1;\r\n }\r\n\r\n // LeaseAddress\r\n get sourceLeaseAddress(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseAddress;\r\n }\r\n\r\n get reportedLeaseAddress(): string {\r\n return this.isOverride(this._overrides.leaseAddress) ? this._overrides.leaseAddress : this.sourceLeaseAddress;\r\n }\r\n\r\n set reportedLeaseAddress(value: string) {\r\n this._overrides.leaseAddress = value;\r\n }\r\n\r\n get reportedLeaseAddressHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseAddress) === -1;\r\n }\r\n\r\n // LeaseCity\r\n get sourceLeaseCity(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseCity;\r\n }\r\n\r\n get reportedLeaseCity(): string {\r\n return this.isOverride(this._overrides.leaseCity) ? this._overrides.leaseCity : this.sourceLeaseCity;\r\n }\r\n\r\n set reportedLeaseCity(value: string) {\r\n this._overrides.leaseCity = value;\r\n }\r\n\r\n get reportedLeaseCityHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseCity) === -1;\r\n }\r\n\r\n // LeaseState\r\n get sourceLeaseState(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseState;\r\n }\r\n\r\n get reportedLeaseState(): string {\r\n return this.isOverride(this._overrides.leaseState) ? this._overrides.leaseState : this.sourceLeaseState;\r\n }\r\n\r\n set reportedLeaseState(value: string) {\r\n this._overrides.leaseState = value;\r\n }\r\n\r\n get reportedLeaseStateHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseState) === -1;\r\n }\r\n\r\n // LeaseZip\r\n get sourceLeaseZip(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseZip;\r\n }\r\n\r\n get reportedLeaseZip(): string {\r\n return this.isOverride(this._overrides.leaseZip) ? this._overrides.leaseZip : this.sourceLeaseZip;\r\n }\r\n\r\n set reportedLeaseZip(value: string) {\r\n this._overrides.leaseZip = value;\r\n }\r\n\r\n get reportedLeaseZipHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseZip) === -1;\r\n }\r\n\r\n // LeaseTermInMonths\r\n get sourceLeaseTermInMonths(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseTermInMonths;\r\n }\r\n\r\n get reportedLeaseTermInMonths(): number {\r\n return this.isOverride(this._overrides.leaseTermInMonths) ? this._overrides.leaseTermInMonths : this.sourceLeaseTermInMonths;\r\n }\r\n\r\n set reportedLeaseTermInMonths(value: number) {\r\n this._overrides.leaseTermInMonths = value;\r\n }\r\n\r\n get reportedLeaseTermInMonthsHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseTermInMonths) === -1;\r\n }\r\n\r\n // LeaseMonthlyPayment\r\n get sourceLeaseMonthlyPayment(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseMonthlyPayment;\r\n }\r\n\r\n get reportedLeaseMonthlyPayment(): number {\r\n return this.isOverride(this._overrides.leaseMonthlyPayment) ? this._overrides.leaseMonthlyPayment : this.sourceLeaseMonthlyPayment;\r\n }\r\n\r\n set reportedLeaseMonthlyPayment(value: number) {\r\n this._overrides.leaseMonthlyPayment = value;\r\n }\r\n\r\n get reportedLeaseMonthlyPaymentHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseMonthlyPayment) === -1;\r\n }\r\n\r\n // LeaseTypeId\r\n get sourceLeaseTypeId(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseTypeId;\r\n }\r\n\r\n get reportedLeaseTypeId(): string {\r\n return this.isOverride(this._overrides.leaseTypeId) ? this._overrides.leaseTypeId : this.sourceLeaseTypeId;\r\n }\r\n\r\n set reportedLeaseTypeId(value: string) {\r\n this._overrides.leaseTypeId = value;\r\n }\r\n\r\n get reportedLeaseTypeIdHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseTypeId) === -1;\r\n }\r\n\r\n // LeaseAssetId\r\n get sourceLeaseAssetId(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseAssetId;\r\n }\r\n\r\n get reportedLeaseAssetId(): string {\r\n return this.isOverride(this._overrides.leaseAssetId) ? this._overrides.leaseAssetId : this.sourceLeaseAssetId;\r\n }\r\n\r\n set reportedLeaseAssetId(value: string) {\r\n this._overrides.leaseAssetId = value;\r\n }\r\n\r\n get reportedLeaseAssetIdHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseAssetId) === -1;\r\n }\r\n\r\n // LeaseNumber\r\n get sourceLeaseNumber(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseNumber;\r\n }\r\n\r\n get reportedLeaseNumber(): string {\r\n return this.isOverride(this._overrides.leaseNumber) ? this._overrides.leaseNumber : this.sourceLeaseNumber;\r\n }\r\n\r\n set reportedLeaseNumber(value: string) {\r\n this._overrides.leaseNumber = value;\r\n }\r\n\r\n get reportedLeaseNumberHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseNumber) === -1;\r\n }\r\n\r\n // LeaseBillingName\r\n get sourceLeaseBillingName(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseBillingName;\r\n }\r\n\r\n get reportedLeaseBillingName(): string {\r\n return this.isOverride(this._overrides.leaseBillingName) ? this._overrides.leaseBillingName : this.sourceLeaseBillingName;\r\n }\r\n\r\n set reportedLeaseBillingName(value: string) {\r\n this._overrides.leaseBillingName = value;\r\n }\r\n\r\n get reportedLeaseBillingNameHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseBillingName) === -1;\r\n }\r\n\r\n\r\n // LeaseBillingAddress\r\n get sourceLeaseBillingAddress(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseBillingAddress;\r\n }\r\n\r\n get reportedLeaseBillingAddress(): string {\r\n return this.isOverride(this._overrides.leaseBillingAddress) ? this._overrides.leaseBillingAddress : this.sourceLeaseBillingAddress;\r\n }\r\n\r\n set reportedLeaseBillingAddress(value: string) {\r\n this._overrides.leaseBillingAddress = value;\r\n }\r\n\r\n get reportedLeaseBillingAddressHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseBillingAddress) === -1;\r\n }\r\n\r\n // LeaseBillingCity\r\n get sourceLeaseBillingCity(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseBillingCity;\r\n }\r\n\r\n get reportedLeaseBillingCity(): string {\r\n return this.isOverride(this._overrides.leaseBillingCity) ? this._overrides.leaseBillingCity : this.sourceLeaseBillingCity;\r\n }\r\n\r\n set reportedLeaseBillingCity(value: string) {\r\n this._overrides.leaseBillingCity = value;\r\n }\r\n\r\n get reportedLeaseBillingCityHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseBillingCity) === -1;\r\n }\r\n\r\n // LeaseBillingState\r\n get sourceLeaseBillingState(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseBillingState;\r\n }\r\n\r\n get reportedLeaseBillingState(): string {\r\n return this.isOverride(this._overrides.leaseBillingState) ? this._overrides.leaseBillingState : this.sourceLeaseBillingState;\r\n }\r\n\r\n set reportedLeaseBillingState(value: string) {\r\n this._overrides.leaseBillingState = value;\r\n }\r\n\r\n get reportedLeaseBillingStateHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseBillingState) === -1;\r\n }\r\n\r\n // LeaseBillingZip\r\n get sourceLeaseBillingZip(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseBillingZip;\r\n }\r\n\r\n get reportedLeaseBillingZip(): string {\r\n return this.isOverride(this._overrides.leaseBillingZip) ? this._overrides.leaseBillingZip : this.sourceLeaseBillingZip;\r\n }\r\n\r\n set reportedLeaseBillingZip(value: string) {\r\n this._overrides.leaseBillingZip = value;\r\n }\r\n\r\n get reportedLeaseBillingZipHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseBillingZip) === -1;\r\n }\r\n\r\n // LeaseStartDate\r\n get sourceLeaseStartDate(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseStartDate;\r\n }\r\n\r\n get reportedLeaseStartDate(): Date {\r\n return this.isOverride(this._overrides.leaseStartDate) ? this._overrides.leaseStartDate : this.sourceLeaseStartDate;\r\n }\r\n\r\n set reportedLeaseStartDate(value: Date) {\r\n this._overrides.leaseStartDate = value;\r\n }\r\n\r\n get reportedLeaseStartDateHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseStartDate) === -1;\r\n }\r\n\r\n // LeaseEndDate\r\n get sourceLeaseEndDate(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.leaseEndDate;\r\n }\r\n\r\n get reportedLeaseEndDate(): Date {\r\n return this.isOverride(this._overrides.leaseEndDate) ? this._overrides.leaseEndDate : this.sourceLeaseEndDate;\r\n }\r\n\r\n set reportedLeaseEndDate(value: Date) {\r\n this._overrides.leaseEndDate = value;\r\n }\r\n\r\n get reportedLeaseEndDateHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.leaseEndDate) === -1;\r\n }\r\n\r\n // T1\r\n get sourceT1(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t1;\r\n }\r\n\r\n get reportedT1(): string {\r\n return this.isOverride(this._overrides.t1) ? this._overrides.t1 : this.sourceT1;\r\n }\r\n\r\n set reportedT1(value: string) {\r\n this._overrides.t1 = value;\r\n }\r\n\r\n // T2\r\n get sourceT2(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t2;\r\n }\r\n\r\n get reportedT2(): string {\r\n return this.isOverride(this._overrides.t2) ? this._overrides.t2 : this.sourceT2;\r\n }\r\n\r\n set reportedT2(value: string) {\r\n this._overrides.t2 = value;\r\n }\r\n\r\n // T3\r\n get sourceT3(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t3;\r\n }\r\n\r\n get reportedT3(): string {\r\n return this.isOverride(this._overrides.t3) ? this._overrides.t3 : this.sourceT3;\r\n }\r\n\r\n set reportedT3(value: string) {\r\n this._overrides.t3 = value;\r\n }\r\n\r\n // T4\r\n get sourceT4(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t4;\r\n }\r\n\r\n get reportedT4(): string {\r\n return this.isOverride(this._overrides.t4) ? this._overrides.t4 : this.sourceT4;\r\n }\r\n\r\n set reportedT4(value: string) {\r\n this._overrides.t4 = value;\r\n }\r\n\r\n // T5\r\n get sourceT5(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t5;\r\n }\r\n\r\n get reportedT5(): string {\r\n return this.isOverride(this._overrides.t5) ? this._overrides.t5 : this.sourceT5;\r\n }\r\n\r\n set reportedT5(value: string) {\r\n this._overrides.t5 = value;\r\n }\r\n\r\n // T6\r\n get sourceT6(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t6;\r\n }\r\n\r\n get reportedT6(): string {\r\n return this.isOverride(this._overrides.t6) ? this._overrides.t6 : this.sourceT6;\r\n }\r\n\r\n set reportedT6(value: string) {\r\n this._overrides.t6 = value;\r\n }\r\n\r\n // T7\r\n get sourceT7(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t7;\r\n }\r\n\r\n get reportedT7(): string {\r\n return this.isOverride(this._overrides.t7) ? this._overrides.t7 : this.sourceT7;\r\n }\r\n\r\n set reportedT7(value: string) {\r\n this._overrides.t7 = value;\r\n }\r\n\r\n // T8\r\n get sourceT8(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t8;\r\n }\r\n\r\n get reportedT8(): string {\r\n return this.isOverride(this._overrides.t8) ? this._overrides.t8 : this.sourceT8;\r\n }\r\n\r\n set reportedT8(value: string) {\r\n this._overrides.t8 = value;\r\n }\r\n\r\n // T9\r\n get sourceT9(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t9;\r\n }\r\n\r\n get reportedT9(): string {\r\n return this.isOverride(this._overrides.t9) ? this._overrides.t9 : this.sourceT9;\r\n }\r\n\r\n set reportedT9(value: string) {\r\n this._overrides.t9 = value;\r\n }\r\n\r\n // T10\r\n get sourceT10(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t10;\r\n }\r\n\r\n get reportedT10(): string {\r\n return this.isOverride(this._overrides.t10) ? this._overrides.t10 : this.sourceT10;\r\n }\r\n\r\n set reportedT10(value: string) {\r\n this._overrides.t10 = value;\r\n }\r\n\r\n // T11\r\n get sourceT11(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t11;\r\n }\r\n\r\n get reportedT11(): string {\r\n return this.isOverride(this._overrides.t11) ? this._overrides.t11 : this.sourceT11;\r\n }\r\n\r\n set reportedT11(value: string) {\r\n this._overrides.t11 = value;\r\n }\r\n\r\n // T12\r\n get sourceT12(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t12;\r\n }\r\n\r\n get reportedT12(): string {\r\n return this.isOverride(this._overrides.t12) ? this._overrides.t12 : this.sourceT12;\r\n }\r\n\r\n set reportedT12(value: string) {\r\n this._overrides.t12 = value;\r\n }\r\n\r\n // T13\r\n get sourceT13(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t13;\r\n }\r\n\r\n get reportedT13(): string {\r\n return this.isOverride(this._overrides.t13) ? this._overrides.t13 : this.sourceT13;\r\n }\r\n\r\n set reportedT13(value: string) {\r\n this._overrides.t13 = value;\r\n }\r\n\r\n // T14\r\n get sourceT14(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t14;\r\n }\r\n\r\n get reportedT14(): string {\r\n return this.isOverride(this._overrides.t14) ? this._overrides.t14 : this.sourceT14;\r\n }\r\n\r\n set reportedT14(value: string) {\r\n this._overrides.t14 = value;\r\n }\r\n\r\n // T15\r\n get sourceT15(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t15;\r\n }\r\n\r\n get reportedT15(): string {\r\n return this.isOverride(this._overrides.t15) ? this._overrides.t15 : this.sourceT15;\r\n }\r\n\r\n set reportedT15(value: string) {\r\n this._overrides.t15 = value;\r\n }\r\n\r\n // T6\r\n get sourceT16(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t16;\r\n }\r\n\r\n get reportedT16(): string {\r\n return this.isOverride(this._overrides.t16) ? this._overrides.t16 : this.sourceT16;\r\n }\r\n\r\n set reportedT16(value: string) {\r\n this._overrides.t16 = value;\r\n }\r\n\r\n // T7\r\n get sourceT17(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t17;\r\n }\r\n\r\n get reportedT17(): string {\r\n return this.isOverride(this._overrides.t17) ? this._overrides.t17 : this.sourceT17;\r\n }\r\n\r\n set reportedT17(value: string) {\r\n this._overrides.t17 = value;\r\n }\r\n\r\n // T8\r\n get sourceT18(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t18;\r\n }\r\n\r\n get reportedT18(): string {\r\n return this.isOverride(this._overrides.t18) ? this._overrides.t18 : this.sourceT18;\r\n }\r\n\r\n set reportedT18(value: string) {\r\n this._overrides.t18 = value;\r\n }\r\n\r\n // T9\r\n get sourceT19(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t19;\r\n }\r\n\r\n get reportedT19(): string {\r\n return this.isOverride(this._overrides.t19) ? this._overrides.t19 : this.sourceT19;\r\n }\r\n\r\n set reportedT19(value: string) {\r\n this._overrides.t19 = value;\r\n }\r\n\r\n // T20\r\n get sourceT20(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t20;\r\n }\r\n\r\n get reportedT20(): string {\r\n return this.isOverride(this._overrides.t20) ? this._overrides.t20 : this.sourceT20;\r\n }\r\n\r\n set reportedT20(value: string) {\r\n this._overrides.t20 = value;\r\n }\r\n\r\n // T21\r\n get sourceT21(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t21;\r\n }\r\n\r\n get reportedT21(): string {\r\n return this.isOverride(this._overrides.t21) ? this._overrides.t21 : this.sourceT21;\r\n }\r\n\r\n set reportedT21(value: string) {\r\n this._overrides.t21 = value;\r\n }\r\n\r\n // T22\r\n get sourceT22(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t22;\r\n }\r\n\r\n get reportedT22(): string {\r\n return this.isOverride(this._overrides.t22) ? this._overrides.t22 : this.sourceT22;\r\n }\r\n\r\n set reportedT22(value: string) {\r\n this._overrides.t22 = value;\r\n }\r\n\r\n // T23\r\n get sourceT23(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t23;\r\n }\r\n\r\n get reportedT23(): string {\r\n return this.isOverride(this._overrides.t23) ? this._overrides.t23 : this.sourceT23;\r\n }\r\n\r\n set reportedT23(value: string) {\r\n this._overrides.t23 = value;\r\n }\r\n\r\n // T24\r\n get sourceT24(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t24;\r\n }\r\n\r\n get reportedT24(): string {\r\n return this.isOverride(this._overrides.t24) ? this._overrides.t24 : this.sourceT24;\r\n }\r\n\r\n set reportedT24(value: string) {\r\n this._overrides.t24 = value;\r\n }\r\n\r\n // T25\r\n get sourceT25(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t25;\r\n }\r\n\r\n get reportedT25(): string {\r\n return this.isOverride(this._overrides.t25) ? this._overrides.t25 : this.sourceT25;\r\n }\r\n\r\n set reportedT25(value: string) {\r\n this._overrides.t25 = value;\r\n }\r\n\r\n // T26\r\n get sourceT26(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t26;\r\n }\r\n\r\n get reportedT26(): string {\r\n return this.isOverride(this._overrides.t26) ? this._overrides.t26 : this.sourceT26;\r\n }\r\n\r\n set reportedT26(value: string) {\r\n this._overrides.t26 = value;\r\n }\r\n\r\n // T27\r\n get sourceT27(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t27;\r\n }\r\n\r\n get reportedT27(): string {\r\n return this.isOverride(this._overrides.t27) ? this._overrides.t27 : this.sourceT27;\r\n }\r\n\r\n set reportedT27(value: string) {\r\n this._overrides.t27 = value;\r\n }\r\n\r\n // T28\r\n get sourceT28(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t28;\r\n }\r\n\r\n get reportedT28(): string {\r\n return this.isOverride(this._overrides.t28) ? this._overrides.t28 : this.sourceT28;\r\n }\r\n\r\n set reportedT28(value: string) {\r\n this._overrides.t28 = value;\r\n }\r\n\r\n // T29\r\n get sourceT29(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t29;\r\n }\r\n\r\n get reportedT29(): string {\r\n return this.isOverride(this._overrides.t29) ? this._overrides.t29 : this.sourceT29;\r\n }\r\n\r\n set reportedT29(value: string) {\r\n this._overrides.t29 = value;\r\n }\r\n\r\n // T30\r\n get sourceT30(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.t30;\r\n }\r\n\r\n get reportedT30(): string {\r\n return this.isOverride(this._overrides.t30) ? this._overrides.t30 : this.sourceT30;\r\n }\r\n\r\n set reportedT30(value: string) {\r\n this._overrides.t30 = value;\r\n }\r\n\r\n // N1\r\n get sourceN1(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.n1;\r\n }\r\n\r\n get reportedN1(): number {\r\n return this.isOverride(this._overrides.n1) ? this._overrides.n1 : this.sourceN1;\r\n }\r\n\r\n set reportedN1(value: number) {\r\n this._overrides.n1 = value;\r\n }\r\n\r\n // N2\r\n get sourceN2(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.n2;\r\n }\r\n\r\n get reportedN2(): number {\r\n return this.isOverride(this._overrides.n2) ? this._overrides.n2 : this.sourceN2;\r\n }\r\n\r\n set reportedN2(value: number) {\r\n this._overrides.n2 = value;\r\n }\r\n\r\n // N3\r\n get sourceN3(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.n3;\r\n }\r\n\r\n get reportedN3(): number {\r\n return this.isOverride(this._overrides.n3) ? this._overrides.n3 : this.sourceN3;\r\n }\r\n\r\n set reportedN3(value: number) {\r\n this._overrides.n3 = value;\r\n }\r\n\r\n // N4\r\n get sourceN4(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.n4;\r\n }\r\n\r\n get reportedN4(): number {\r\n return this.isOverride(this._overrides.n4) ? this._overrides.n4 : this.sourceN4;\r\n }\r\n\r\n set reportedN4(value: number) {\r\n this._overrides.n4 = value;\r\n }\r\n\r\n // N5\r\n get sourceN5(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.n5;\r\n }\r\n\r\n get reportedN5(): number {\r\n return this.isOverride(this._overrides.n5) ? this._overrides.n5 : this.sourceN5;\r\n }\r\n\r\n set reportedN5(value: number) {\r\n this._overrides.n5 = value;\r\n }\r\n\r\n // N6\r\n get sourceN6(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.n6;\r\n }\r\n\r\n get reportedN6(): number {\r\n return this.isOverride(this._overrides.n6) ? this._overrides.n6 : this.sourceN6;\r\n }\r\n\r\n set reportedN6(value: number) {\r\n this._overrides.n6 = value;\r\n }\r\n\r\n // N7\r\n get sourceN7(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.n7;\r\n }\r\n\r\n get reportedN7(): number {\r\n return this.isOverride(this._overrides.n7) ? this._overrides.n7 : this.sourceN7;\r\n }\r\n\r\n set reportedN7(value: number) {\r\n this._overrides.n7 = value;\r\n }\r\n\r\n // N8\r\n get sourceN8(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.n8;\r\n }\r\n\r\n get reportedN8(): number {\r\n return this.isOverride(this._overrides.n8) ? this._overrides.n8 : this.sourceN8;\r\n }\r\n\r\n set reportedN8(value: number) {\r\n this._overrides.n8 = value;\r\n }\r\n\r\n // N9\r\n get sourceN9(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.n9;\r\n }\r\n\r\n get reportedN9(): number {\r\n return this.isOverride(this._overrides.n9) ? this._overrides.n9 : this.sourceN9;\r\n }\r\n\r\n set reportedN9(value: number) {\r\n this._overrides.n9 = value;\r\n }\r\n\r\n // N10\r\n get sourceN10(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.n10;\r\n }\r\n\r\n get reportedN10(): number {\r\n return this.isOverride(this._overrides.n10) ? this._overrides.n10 : this.sourceN10;\r\n }\r\n\r\n set reportedN10(value: number) {\r\n this._overrides.n10 = value;\r\n }\r\n\r\n slotColumnHasOverride(columnName: string): boolean {\r\n return this.isOverride(this._overrides[columnName.toLocaleLowerCase()]);\r\n }\r\n\r\n slotColumnHasOverrideWithBlank(columnName: string): boolean {\r\n return this.isOverride(this._overrides[columnName.toLocaleLowerCase()]) && typeof this._overrides[columnName.toLocaleLowerCase()] === 'string' && this._overrides[columnName.toLocaleLowerCase()].trim() === '';\r\n }\r\n\r\n // D1\r\n get sourceD1(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.d1;\r\n }\r\n\r\n get reportedD1(): Date {\r\n return this.isOverride(this._overrides.d1) ? this._overrides.d1 : this.sourceD1;\r\n }\r\n\r\n set reportedD1(value: Date) {\r\n this._overrides.d1 = value;\r\n }\r\n\r\n // D2\r\n get sourceD2(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.d2;\r\n }\r\n\r\n get reportedD2(): Date {\r\n return this.isOverride(this._overrides.d2) ? this._overrides.d2 : this.sourceD2;\r\n }\r\n\r\n set reportedD2(value: Date) {\r\n this._overrides.d2 = value;\r\n }\r\n\r\n // D3\r\n get sourceD3(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.d3;\r\n }\r\n\r\n get reportedD3(): Date {\r\n return this.isOverride(this._overrides.d3) ? this._overrides.d3 : this.sourceD3;\r\n }\r\n\r\n set reportedD3(value: Date) {\r\n this._overrides.d3 = value;\r\n }\r\n\r\n // D4\r\n get sourceD4(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.d4;\r\n }\r\n\r\n get reportedD4(): Date {\r\n return this.isOverride(this._overrides.d4) ? this._overrides.d4 : this.sourceD4;\r\n }\r\n\r\n set reportedD4(value: Date) {\r\n this._overrides.d4 = value;\r\n }\r\n\r\n // D5\r\n get sourceD5(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.d5;\r\n }\r\n\r\n get reportedD5(): Date {\r\n return this.isOverride(this._overrides.d5) ? this._overrides.d5 : this.sourceD5;\r\n }\r\n\r\n set reportedD5(value: Date) {\r\n this._overrides.d5 = value;\r\n }\r\n\r\n // D6\r\n get sourceD6(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.d6;\r\n }\r\n\r\n get reportedD6(): Date {\r\n return this.isOverride(this._overrides.d6) ? this._overrides.d6 : this.sourceD6;\r\n }\r\n\r\n set reportedD6(value: Date) {\r\n this._overrides.d6 = value;\r\n }\r\n\r\n // D7\r\n get sourceD7(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.d7;\r\n }\r\n\r\n get reportedD7(): Date {\r\n return this.isOverride(this._overrides.d7) ? this._overrides.d7 : this.sourceD7;\r\n }\r\n\r\n set reportedD7(value: Date) {\r\n this._overrides.d7 = value;\r\n }\r\n\r\n // D8\r\n get sourceD8(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.d8;\r\n }\r\n\r\n get reportedD8(): Date {\r\n return this.isOverride(this._overrides.d8) ? this._overrides.d8 : this.sourceD8;\r\n }\r\n\r\n set reportedD8(value: Date) {\r\n this._overrides.d8 = value;\r\n }\r\n\r\n // D9\r\n get sourceD9(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.d9;\r\n }\r\n\r\n get reportedD9(): Date {\r\n return this.isOverride(this._overrides.d9) ? this._overrides.d9 : this.sourceD9;\r\n }\r\n\r\n set reportedD9(value: Date) {\r\n this._overrides.d9 = value;\r\n }\r\n\r\n // D10\r\n get sourceD10(): Date {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.d10;\r\n }\r\n\r\n get reportedD10(): Date {\r\n return this.isOverride(this._overrides.d10) ? this._overrides.d10 : this.sourceD10;\r\n }\r\n\r\n set reportedD10(value: Date) {\r\n this._overrides.d10 = value;\r\n }\r\n\r\n get reportedCostAdjustmentAmount1(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.costAdjustmentAmount1;\r\n }\r\n\r\n get reportedCostAdjustmentAmount2(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.costAdjustmentAmount2;\r\n }\r\n\r\n get reportedCostAdjustmentAmount3(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.costAdjustmentAmount3;\r\n }\r\n\r\n get reportedCostAdjustmentAmount4(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.costAdjustmentAmount4;\r\n }\r\n\r\n get reportedCostAdjustmentAmount5(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.costAdjustmentAmount5;\r\n }\r\n\r\n get reportedCostAdjustmentAmount6(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.costAdjustmentAmount6;\r\n }\r\n\r\n get reportedCostAdjustmentAmount7(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.costAdjustmentAmount7;\r\n }\r\n\r\n get reportedCostAdjustmentAmount8(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.costAdjustmentAmount8;\r\n }\r\n\r\n get reportedCostAdjustmentAmount9(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.costAdjustmentAmount9;\r\n }\r\n\r\n get reportedCostAdjustmentAmount10(): number {\r\n return this._model && this._model.reportingAsset && this._model.reportingAsset.costAdjustmentAmount10;\r\n }\r\n\r\n isOverride(value: any) {\r\n return [null, undefined].indexOf(value) === -1;\r\n }\r\n\r\n hasCostAdjustment(): boolean {\r\n return !!(this.reportedCostAdjustmentAmount1 ||\r\n this.reportedCostAdjustmentAmount2 ||\r\n this.reportedCostAdjustmentAmount3 ||\r\n this.reportedCostAdjustmentAmount4 ||\r\n this.reportedCostAdjustmentAmount5 ||\r\n this.reportedCostAdjustmentAmount6 ||\r\n this.reportedCostAdjustmentAmount7 ||\r\n this.reportedCostAdjustmentAmount8 ||\r\n this.reportedCostAdjustmentAmount9 ||\r\n this.reportedCostAdjustmentAmount10);\r\n }\r\n\r\n get sourceAssetId(): number {\r\n return this._model.sourceAsset.sourceAssetId;\r\n }\r\n\r\n // special versions of cost to bind to but only affecting real reported cost in limited situations\r\n get transientReportedCost(): number {\r\n return this.reportedCostHasOverride ? this._overrides.cost : this._transientReportedCost;\r\n }\r\n\r\n set transientReportedCost(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n set transientReportedN1(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n get transientReportedN1(): number {\r\n return this.reportedColumnHasOverride('N1') ? this._overrides.n1 : this._transientReportedCost;\r\n }\r\n\r\n set transientReportedN2(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n get transientReportedN2(): number {\r\n return this.reportedColumnHasOverride('N2') ? this._overrides.n2 : this._transientReportedCost;\r\n }\r\n\r\n set transientReportedN3(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n get transientReportedN3(): number {\r\n return this.reportedColumnHasOverride('N3') ? this._overrides.n3 : this._transientReportedCost;\r\n }\r\n\r\n set transientReportedN4(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n get transientReportedN4(): number {\r\n return this.reportedColumnHasOverride('N4') ? this._overrides.n4 : this._transientReportedCost;\r\n }\r\n\r\n set transientReportedN5(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n get transientReportedN5(): number {\r\n return this.reportedColumnHasOverride('N5') ? this._overrides.n5 : this._transientReportedCost;\r\n }\r\n\r\n set transientReportedN6(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n get transientReportedN6(): number {\r\n return this.reportedColumnHasOverride('N6') ? this._overrides.n6 : this._transientReportedCost;\r\n }\r\n\r\n set transientReportedN7(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n get transientReportedN7(): number {\r\n return this.reportedColumnHasOverride('N7') ? this._overrides.n7 : this._transientReportedCost;\r\n }\r\n\r\n set transientReportedN8(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n get transientReportedN8(): number {\r\n return this.reportedColumnHasOverride('N8') ? this._overrides.n8 : this._transientReportedCost;\r\n }\r\n\r\n set transientReportedN9(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n get transientReportedN9(): number {\r\n return this.reportedColumnHasOverride('N9') ? this._overrides.n9 : this._transientReportedCost;\r\n }\r\n\r\n set transientReportedN10(value: number) {\r\n this._transientReportedCost = value;\r\n }\r\n\r\n get transientReportedN10(): number {\r\n return this.reportedColumnHasOverride('N10') ? this._overrides.n10 : this._transientReportedCost;\r\n }\r\n\r\n get changeStatus(): any {\r\n return this._model.changeStatus;\r\n }\r\n\r\n get sourceOldAssetNumber(): string {\r\n return this._model && this._model.oldAssetNumber;\r\n }\r\n\r\n get reportedOldAssetNumber(): string {\r\n return this.reportedOldAssetNumberHasOverride || this.reportedOldAssetNumberHasOverrideWithBlank\r\n ? this._model.reportingAsset.oldAssetNumber\r\n : this.sourceOldAssetNumber;\r\n }\r\n\r\n set reportedOldAssetNumber(value: string) {\r\n this._model.reportingAsset.oldAssetNumber = value;\r\n }\r\n\r\n get reportedOldAssetNumberHasOverride(): boolean {\r\n return this.sourceOldAssetNumber !== this._model.reportingAsset.oldAssetNumber;\r\n }\r\n\r\n get reportedOldAssetNumberHasOverrideWithBlank(): boolean {\r\n return this.reportedOldAssetNumberHasOverride && !this._model.reportingAsset.oldAssetNumber;\r\n }\r\n\r\n get sourceInventoryJan(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryJan;\r\n }\r\n\r\n get reportedInventoryJan(): number {\r\n return this.isOverride(this._overrides.inventoryJan) ? this._overrides.inventoryJan : this.sourceInventoryJan;\r\n }\r\n\r\n set reportedInventoryJan(value: number) {\r\n this._overrides.inventoryJan = value;\r\n }\r\n\r\n get reportedInventoryJanHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryJan);\r\n }\r\n\r\n get sourceInventoryFeb(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryFeb;\r\n }\r\n\r\n get reportedInventoryFeb(): number {\r\n return this.isOverride(this._overrides.inventoryFeb) ? this._overrides.inventoryFeb : this.sourceInventoryFeb;\r\n }\r\n\r\n set reportedInventoryFeb(value: number) {\r\n this._overrides.inventoryFeb = value;\r\n }\r\n\r\n get reportedInventoryFebHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryFeb);\r\n }\r\n\r\n get sourceInventoryMar(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryMar;\r\n }\r\n\r\n get reportedInventoryMar(): number {\r\n return this.isOverride(this._overrides.inventoryMar) ? this._overrides.inventoryMar : this.sourceInventoryMar;\r\n }\r\n\r\n set reportedInventoryMar(value: number) {\r\n this._overrides.inventoryMar = value;\r\n }\r\n\r\n get reportedInventoryMarHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryMar);\r\n }\r\n\r\n get sourceInventoryApr(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryApr;\r\n }\r\n\r\n get reportedInventoryApr(): number {\r\n return this.isOverride(this._overrides.inventoryApr) ? this._overrides.inventoryApr : this.sourceInventoryApr;\r\n }\r\n\r\n set reportedInventoryApr(value: number) {\r\n this._overrides.inventoryApr = value;\r\n }\r\n\r\n get reportedInventoryAprHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryApr);\r\n }\r\n\r\n get sourceInventoryMay(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryMay;\r\n }\r\n\r\n get reportedInventoryMay(): number {\r\n return this.isOverride(this._overrides.inventoryMay) ? this._overrides.inventoryMay : this.sourceInventoryMay;\r\n }\r\n\r\n set reportedInventoryMay(value: number) {\r\n this._overrides.inventoryMay = value;\r\n }\r\n\r\n get reportedInventoryMayHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryMay);\r\n }\r\n\r\n get sourceInventoryJun(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryJun;\r\n }\r\n\r\n get reportedInventoryJun(): number {\r\n return this.isOverride(this._overrides.inventoryJun) ? this._overrides.inventoryJun : this.sourceInventoryJun;\r\n }\r\n\r\n set reportedInventoryJun(value: number) {\r\n this._overrides.inventoryJun = value;\r\n }\r\n\r\n get reportedInventoryJunHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryJun);\r\n }\r\n\r\n get sourceInventoryJul(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryJul;\r\n }\r\n\r\n get reportedInventoryJul(): number {\r\n return this.isOverride(this._overrides.inventoryJul) ? this._overrides.inventoryJul : this.sourceInventoryJul;\r\n }\r\n\r\n set reportedInventoryJul(value: number) {\r\n this._overrides.inventoryJul = value;\r\n }\r\n\r\n get reportedInventoryJulHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryJul);\r\n }\r\n\r\n get sourceInventoryAug(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryAug;\r\n }\r\n\r\n get reportedInventoryAug(): number {\r\n return this.isOverride(this._overrides.inventoryAug) ? this._overrides.inventoryAug : this.sourceInventoryAug;\r\n }\r\n\r\n set reportedInventoryAug(value: number) {\r\n this._overrides.inventoryAug = value;\r\n }\r\n\r\n get reportedInventoryAugHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryAug);\r\n }\r\n\r\n get sourceInventorySep(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventorySep;\r\n }\r\n\r\n get reportedInventorySep(): number {\r\n return this.isOverride(this._overrides.inventorySep) ? this._overrides.inventorySep : this.sourceInventorySep;\r\n }\r\n\r\n set reportedInventorySep(value: number) {\r\n this._overrides.inventorySep = value;\r\n }\r\n\r\n get reportedInventorySepHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventorySep);\r\n }\r\n\r\n get sourceInventoryOct(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryOct;\r\n }\r\n\r\n get reportedInventoryOct(): number {\r\n return this.isOverride(this._overrides.inventoryOct) ? this._overrides.inventoryOct : this.sourceInventoryOct;\r\n }\r\n\r\n set reportedInventoryOct(value: number) {\r\n this._overrides.inventoryOct = value;\r\n }\r\n\r\n get reportedInventoryOctHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryOct);\r\n }\r\n\r\n get sourceInventoryNov(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryNov;\r\n }\r\n\r\n get reportedInventoryNov(): number {\r\n return this.isOverride(this._overrides.inventoryNov) ? this._overrides.inventoryNov : this.sourceInventoryNov;\r\n }\r\n\r\n set reportedInventoryNov(value: number) {\r\n this._overrides.inventoryNov = value;\r\n }\r\n\r\n get reportedInventoryNovHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryNov);\r\n }\r\n\r\n get sourceInventoryDec(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryDec;\r\n }\r\n\r\n get reportedInventoryDec(): number {\r\n return this.isOverride(this._overrides.inventoryDec) ? this._overrides.inventoryDec : this.sourceInventoryDec;\r\n }\r\n\r\n set reportedInventoryDec(value: number) {\r\n this._overrides.inventoryDec = value;\r\n }\r\n\r\n get reportedInventoryDecHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryDec);\r\n }\r\n\r\n get sourceInventoryAggregatedString(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryAggregatedString;\r\n }\r\n\r\n get reportedInventoryAggregatedString(): string {\r\n return this._model && (this._overrides.inventoryAggregatedString || this._model.sourceAsset.inventoryAggregatedString);\r\n }\r\n\r\n get sourceInventoryAvr(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.inventoryAvr;\r\n }\r\n\r\n get reportedInventoryAvr(): number {\r\n let result: number;\r\n\r\n if (this.isOverride(this._overrides.inventoryAvr)) {\r\n result = this._overrides.inventoryAvr;\r\n } else if (!this.sourceInventoryAvr) {\r\n result = this._getInventorySupplyAggregateInfo(this.reportedInventoryJan, this.reportedInventoryFeb,\r\n this.reportedInventoryMar, this.reportedInventoryApr, this.reportedInventoryMay,\r\n this.reportedInventoryJun, this.reportedInventoryJul, this.reportedInventoryAug,\r\n this.reportedInventorySep, this.reportedInventoryOct, this.reportedInventoryNov,\r\n this.reportedInventoryDec);\r\n } else { result = this.sourceInventoryAvr; }\r\n\r\n return result;\r\n }\r\n\r\n set reportedInventoryAvr(value: number) {\r\n this._overrides.inventoryAvr = value;\r\n }\r\n\r\n get reportedInventoryAvrHasOverride(): boolean {\r\n return this.isOverride(this._overrides.inventoryAvr);\r\n }\r\n\r\n get reportedInventoryAvrCalculated(): number {\r\n return this._overrides.inventoryAvrCalculated;\r\n }\r\n\r\n get reportedInventoryAvrIsCalculated(): boolean {\r\n return !this.reportedInventoryAvrHasOverride && !!this.reportedInventoryAvrCalculated && this.reportedInventoryAvr !== this.sourceInventoryAvr;\r\n }\r\n\r\n get sourceNetBookValue(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.netBookValue;\r\n }\r\n\r\n get reportedNetBookValue(): number {\r\n return this.isOverride(this._overrides.netBookValue) ? this._overrides.netBookValue : this.sourceNetBookValue;\r\n }\r\n\r\n set reportedNetBookValue(value: number) {\r\n this._overrides.netBookValue = value;\r\n }\r\n\r\n get reportedNetBookValueHasOverride(): boolean {\r\n return this.isOverride(this._overrides.netBookValue);\r\n }\r\n\r\n get alternativeAcqDateDescriptorName(): string {\r\n return this._model && this._model.alternativeAcqDateDescriptorName;\r\n }\r\n\r\n get alternativeCostDescriptorName(): string {\r\n return this._model && this._model.alternativeCostDescriptorName;\r\n }\r\n\r\n get sourceCompanyId(): number {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.sourceCompanyId;\r\n }\r\n\r\n get sourceCompanyName(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.sourceCompanyName;\r\n }\r\n\r\n get sourceCompanyCode(): string {\r\n return this._model && this._model.sourceAsset && this._model.sourceAsset.sourceCompanyCode;\r\n }\r\n\r\n get reportedIsAnchored(): boolean {\r\n return this._model && this._model.reportingAsset.isAnchored;\r\n }\r\n\r\n set reportedIsAnchored(value: boolean) {\r\n this._model.reportingAsset.isAnchored = value;\r\n }\r\n\r\n get reportedDoNotPotentiallyDispose(): boolean {\r\n return this._model && this._model.reportingAsset.doNotPotentiallyDispose;\r\n }\r\n\r\n set reportedDoNotPotentiallyDispose(value: boolean) {\r\n this._model.reportingAsset.doNotPotentiallyDispose = value;\r\n }\r\n\r\n get reportedIsLocked(): boolean {\r\n return this._model && this._model.reportingAsset.isLocked;\r\n }\r\n\r\n set reportedIsLocked(value: boolean) {\r\n this._model.reportingAsset.isLocked = value;\r\n\r\n if (!value) {\r\n this._isLocked = value;\r\n }\r\n }\r\n\r\n get isLocked(): boolean {\r\n return this._isLocked;\r\n }\r\n\r\n get lastReturnDescription(): string {\r\n return this._model.lastReturnDescription;\r\n }\r\n\r\n get lastReturnId(): number {\r\n return this._model.lastReturnId;\r\n }\r\n\r\n get siteAddress(): string {\r\n return this._model.siteAddress;\r\n }\r\n\r\n get reportedSiteAddressHasOverride(): boolean {\r\n return [null, undefined].indexOf(this._overrides.reportingSiteAddress) === -1;\r\n }\r\n\r\n get sourceSiteAddress(): string {\r\n return this._model.sourceAsset.sourceSiteAddress;\r\n }\r\n\r\n get assessorId(): number {\r\n return this._model.reportingAsset.assessorId;\r\n }\r\n\r\n private _getInventorySupplyAggregateInfo(jan: number, feb: number, mar: number, apr: number, may: number, jun: number,\r\n jul: number, aug: number, sep: number, oct: number, nov: number, dec: number): number {\r\n let monthWithValue = 0;\r\n let totalMonthsValue = 0;\r\n\r\n function populateMonthInfo(monthValue: number | string) {\r\n if (typeof(monthValue) === 'string'){\r\n monthValue = +(monthValue || '').replace(new RegExp(',', 'g'), '');\r\n }\r\n\r\n if (monthValue || monthValue === 0) {\r\n totalMonthsValue += monthValue;\r\n monthWithValue++;\r\n }\r\n }\r\n\r\n populateMonthInfo.call(this, jan);\r\n populateMonthInfo.call(this, feb);\r\n populateMonthInfo.call(this, mar);\r\n populateMonthInfo.call(this, apr);\r\n populateMonthInfo.call(this, may);\r\n populateMonthInfo.call(this, jun);\r\n populateMonthInfo.call(this, jul);\r\n populateMonthInfo.call(this, aug);\r\n populateMonthInfo.call(this, sep);\r\n populateMonthInfo.call(this, oct);\r\n populateMonthInfo.call(this, nov);\r\n populateMonthInfo.call(this, dec);\r\n\r\n const average = totalMonthsValue / monthWithValue;\r\n return monthWithValue != 0 && !isNaN(average) ? average : null;\r\n }\r\n}\r\n","import { Injectable, EventEmitter } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { ExtendedCostAdjustmentTypeModel} from './assetInfo.component';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { AssetSummary } from '../../Models/assetSummary';\r\nimport { Decimal } from 'decimal.js';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Injectable()\r\nexport class AssetInfoService {\r\n constructor( private _decimalPipe: DecimalPipe ) {\r\n }\r\n get calculatedCostUpdated$(): Observable { return this._calculatedCostEventEmitter.asObservable(); }\r\n\r\n allocatedTotal: number;\r\n assetValueMatched: boolean;\r\n calculatedCost: string;\r\n calculatedCostValue: number;\r\n costAdjustmentDescription: string;\r\n\r\n costCompanyAssetDescriptorMappingModel: Compliance.CompanyAssetDescriptorMappingModel;\r\n extendedCostAdjustmentTypes: ExtendedCostAdjustmentTypeModel[] = [];\r\n hasSourceValue: boolean;\r\n hasAdjustments: boolean;\r\n //sourceFieldValue: number;\r\n costAdjustmentCalculations;\r\n\r\n private _costAdjustments: { [s: string]: Compliance.AssetCostAdjustmentModel; } = {};\r\n private _selectedCompanyId: number;\r\n private _calculatedCostEventEmitter = new EventEmitter();\r\n\r\n set costAdjustments(costAdjustments: { [s: string]: Compliance.AssetCostAdjustmentModel; }) {\r\n this._costAdjustments = costAdjustments;\r\n }\r\n\r\n get costAdjustments(): { [s: string]: Compliance.AssetCostAdjustmentModel; } {\r\n return this._costAdjustments;\r\n }\r\n\r\n set selectedCompanyId(id: number) {\r\n this._selectedCompanyId = id;\r\n }\r\n\r\n get selectedCompanyId(): number {\r\n return this._selectedCompanyId;\r\n }\r\n\r\n clearValues(): void {\r\n this.calculatedCost = '';\r\n this.costAdjustmentDescription = '';\r\n this.costAdjustmentCalculations = {};\r\n }\r\n\r\n calculateCostsAndCheckTotals(sourceFieldValue: number, costAdjustments: { [s: string]: Compliance.AssetCostAdjustmentModel }, assets: AssetSummary[]): void {\r\n this._calculateCosts(sourceFieldValue, costAdjustments);\r\n this._checkAssetsMatchCalculatedSourceCost(assets);\r\n }\r\n\r\n private _calculateCosts(sourceFieldValue: number, costAdjustments: { [s: string]: Compliance.AssetCostAdjustmentModel }): void {\r\n\r\n let runningTotal = sourceFieldValue ? sourceFieldValue : 0;\r\n // sets flag to understand if we have a source\r\n this.hasSourceValue = !!sourceFieldValue;\r\n\r\n const adjustmentsFound: string[] = [];\r\n\r\n this.extendedCostAdjustmentTypes.forEach(x => {\r\n const adjustment: Compliance.AssetCostAdjustmentModel = costAdjustments[x.costAdjustmentTypeId];\r\n\r\n if (adjustment) {\r\n if (adjustment.adjustmentAmount !== null && adjustment.adjustmentAmount !== undefined && adjustment.adjustmentAmount !== 0) {\r\n runningTotal += adjustment.adjustmentAmount;\r\n adjustmentsFound.push(`$${this._decimalPipe.transform(adjustment.adjustmentAmount, '1.2-2')} ${x.typeName}`);\r\n } else if (adjustment.adjustmentPercentage !== null && adjustment.adjustmentPercentage !== undefined && adjustment.adjustmentPercentage !== 0) {\r\n\r\n const percentCalcRh = x.applyToSource ? sourceFieldValue : runningTotal;\r\n const adjustmentAmountFromPercentage = _.round(adjustment.adjustmentPercentage * percentCalcRh / 100, 2);\r\n\r\n runningTotal += adjustmentAmountFromPercentage;\r\n adjustmentsFound.push(`${adjustment.adjustmentPercentage }%` + ` ($${ this._decimalPipe.transform(adjustmentAmountFromPercentage, '1.2-2') }) ${ x.typeName}`);\r\n }\r\n this.costAdjustmentCalculations[x.costAdjustmentTypeId] = `$${this._decimalPipe.transform(runningTotal, '1.2-2')}`;\r\n }\r\n });\r\n\r\n this.calculatedCostValue = parseFloat(runningTotal.toFixed(2));\r\n this._calculatedCostEventEmitter.next(this.calculatedCostValue);\r\n this.calculatedCost = `$ ${this._decimalPipe.transform(runningTotal, '1.2-2')}`;\r\n\r\n let adjustmentDescription = '';\r\n if (adjustmentsFound.length === 0) {\r\n this.hasAdjustments = false;\r\n } else {\r\n this.hasAdjustments = true;\r\n adjustmentDescription = `* Adjusted source ${ this.calculatedCost } using `;\r\n for (let i = 0; i < adjustmentsFound.length; i++) {\r\n adjustmentDescription += adjustmentsFound[i];\r\n if (i === adjustmentsFound.length - 1) {\r\n adjustmentDescription += '.';\r\n } else {\r\n adjustmentDescription += ((i < adjustmentsFound.length - 2) ? ', ' : ' and ');\r\n }\r\n }\r\n }\r\n this.costAdjustmentDescription = adjustmentDescription;\r\n }\r\n\r\n private _checkAssetsMatchCalculatedSourceCost(assets: AssetSummary[]): void {\r\n const expectedTotal = this.calculatedCostValue;\r\n let allocatedTotal = new Decimal(0);\r\n assets.forEach((asset: AssetSummary) => {\r\n if (asset.transientReportedCost != null) {\r\n allocatedTotal = allocatedTotal.add(asset.transientReportedCost);\r\n }\r\n });\r\n this.allocatedTotal = allocatedTotal.toDecimalPlaces(2).toNumber();\r\n this.assetValueMatched = (expectedTotal == this.allocatedTotal);\r\n }\r\n\r\n}\r\n","\r\n 0\">\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

Asset Info (Displayed values may differ from locked values shown in {{isFromLockedReturn ? 'return' : 'allocation'}})

\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
The date selection was adjusted based on the saved asset info
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

Return Filings

\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

Source Value Activity Log

\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ViewChild } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AssetInfoComponent, ExtendedCostAdjustmentTypeModel } from './Asset-Info/assetInfo.component';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { AssetRepository } from '../../Repositories';\r\nimport { ModalComponentBase } from '../../modalComponentBase';\r\nimport { CommentModalData } from '../../../Comments/comments.service';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { ASSET_DETAILS_HELP } from './assetDetails.component.help';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { AssetSummary } from '../Models/assetSummary';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../../UI-Lib/Pipes';\r\nimport { StateService } from '../../../Common/States/States.Service';\r\nimport { StateSummary } from '../../../Common/States/state.model';\r\nimport { AssetInfoService } from './Asset-Info/assetInfo.service';\r\nimport { AssetLienDate } from '../Asset-Lien-Date/assetLienDate.component';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface AssetDetailsParams {\r\n reportingAssetId: number;\r\n assetId: number;\r\n lienDate: Date;\r\n canEdit: boolean;\r\n createNewAsset?: boolean;\r\n topLevelCompanyId: number;\r\n newAssetCompanyId?: number;\r\n assetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[];\r\n canViewRyanPrivateItems: boolean;\r\n fromLockedReturn?: boolean;\r\n fromLockedAllocation?: boolean;\r\n}\r\n\r\nexport interface AssetDetailsResult {\r\n hasChanges: boolean;\r\n savedModels: Compliance.AssetModel[];\r\n newAssetCompanyId: number;\r\n initialReportingAssetIds: number[];\r\n totalsModel: Compliance.AssetSearchTotalsModel;\r\n}\r\n\r\nexport interface AssetDescriptors {\r\n acqDateAssetDescriptors: number;\r\n costAssetDescriptors: number;\r\n}\r\n\r\n@Component({\r\n selector: 'asset-details',\r\n templateUrl: './assetDetails.component.html',\r\n styleUrls: ['./assetDetails.component.scss'],\r\n providers: [AssetInfoService]\r\n})\r\nexport class AssetDetailsComponent extends ModalComponentBase implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _assetRepository: AssetRepository,\r\n private readonly _assetInfoService: AssetInfoService,\r\n private readonly _helpService: HelpService,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe,\r\n private readonly _stateService: StateService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _navigationService: UpgradeNavigationServiceHandler\r\n ) {\r\n super();\r\n }\r\n\r\n @ViewChild('assetInfo') assetInfo: AssetInfoComponent;\r\n\r\n assetDetailModel: Compliance.AssetDetailModel;\r\n assetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[];\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n assets: AssetSummary[] = [];\r\n states: StateSummary[] = [];\r\n changeDates: Date[] = [];\r\n\r\n params: AssetDetailsParams;\r\n\r\n result: AssetDetailsResult = {\r\n hasChanges: false,\r\n savedModels: [],\r\n newAssetCompanyId: 0,\r\n initialReportingAssetIds: [],\r\n totalsModel: null\r\n };\r\n\r\n canEdit: boolean = false;\r\n isExpandedAssetInfoPanel: boolean = true;\r\n isMaximizedAssetInfoPanel: boolean = false;\r\n isExpandedAssetActivityPanel: boolean = false;\r\n isMaximizedAssetActivityPanel: boolean = false;\r\n isExpandedReturnFilingsPanel: boolean = false;\r\n isMaximizedReturnFilingsPanel: boolean = false;\r\n isReadyAssetInfoComponent: boolean = false;\r\n isAssetInfoComponentInEditState: boolean = false;\r\n createNewAsset: boolean = false;\r\n newAssetCompanyId: number;\r\n topLevelCompanyId: number;\r\n assetId: number;\r\n reportingAssetId: number;\r\n assetListLienDate: Date;\r\n updatedOverrideLienDates: Record = {};\r\n lienDate: Date;\r\n commentModalData: CommentModalData;\r\n isFromLockedReturn: boolean = false;\r\n isFromLockedAllocation: boolean = false;\r\n currentAsset: AssetSummary;\r\n selectedAssetDescriptors: AssetDescriptors;\r\n minLienDate: Date;\r\n maxLienDate: Date;\r\n\r\n isInitialized: boolean = false;\r\n isLoading: boolean = false;\r\n isReturnAsset: boolean; //Are we on the return page?\r\n\r\n private _lienDateChanged: boolean = false;\r\n\r\n get assetTitle(): string {\r\n return this.createNewAsset ? 'New Asset' : 'Asset Details';\r\n }\r\n\r\n get hasComments(): boolean {\r\n return this.assetDetailModel\r\n && (this.assetDetailModel.assets.some(x => x.hasNonRyanInternalComments)\r\n || (this.params.canViewRyanPrivateItems && this.assetDetailModel.assets.some(x => x.hasRyanInternalComments)));\r\n }\r\n\r\n set hasComments(value: boolean) {\r\n if (this.assetDetailModel && value) {\r\n this.assetDetailModel.assets[0].hasNonRyanInternalComments = true;\r\n this.result.hasChanges = true;\r\n this.result.savedModels = this.assetDetailModel.assets;\r\n }\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this.isReturnAsset = this._navigationService.getCurrentState().name === 'returnFilingBatchPage';\r\n this._helpService.setContent(ASSET_DETAILS_HELP);\r\n this.canEdit = this.params.canEdit;\r\n this.assetId = this.params.assetId;\r\n this.reportingAssetId = this.params.reportingAssetId;\r\n this.assetListLienDate = this.params.lienDate;\r\n this.lienDate = this.params.lienDate;\r\n this.assetDescriptors = this.params.assetDescriptors;\r\n this.isFromLockedReturn = this.params.fromLockedReturn;\r\n this.topLevelCompanyId = this.params.topLevelCompanyId;\r\n this.isFromLockedAllocation = this.params.fromLockedAllocation;\r\n\r\n this.createNewAsset = this.params.createNewAsset;\r\n if (this.createNewAsset) {\r\n this.newAssetCompanyId = this.params.newAssetCompanyId;\r\n this.assetDetailModel = {\r\n assetId: null,\r\n companyId: this.newAssetCompanyId,\r\n assets: [],\r\n alternativeCostDescriptorId: null,\r\n alternativeAcqDateDescriptorId: null\r\n };\r\n }\r\n\r\n if (this.assetId) {\r\n const busyMsgLoadAsset = 'load-asset';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsgLoadAsset);\r\n\r\n try {\r\n const resultFromRepository = await lastValueFrom(this._assetRepository.get(this.assetId, this.lienDate, false, true, !this.assetDescriptors));\r\n this.assetDetailModel = resultFromRepository.assetDetailModel;\r\n this.result.initialReportingAssetIds = this.assetDetailModel.assets.map((model: Compliance.AssetModel) => model.reportingAsset.reportingAssetId);\r\n this.changeDates = resultFromRepository.changeDates;\r\n this.minLienDate = resultFromRepository.minLienDate;\r\n this.maxLienDate = resultFromRepository.maxLienDate;\r\n this.assetDescriptors = resultFromRepository.assetDescriptors || this.assetDescriptors;\r\n this.updatedOverrideLienDates[this.lienDate.getTime()] = resultFromRepository.assetDetailModel.assets;\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgLoadAsset);\r\n }\r\n\r\n this.commentModalData = {\r\n entityID: this.assetDetailModel.assetId,\r\n entityTypeID: Core.EntityTypes.Asset,\r\n parcelAcctNum: null,\r\n canEdit: true,\r\n description: null,\r\n parcelID: null,\r\n year: null\r\n };\r\n }\r\n\r\n this.states = await this._stateService.getSummary();\r\n this._setAssets();\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n commentCountChange(value: number) {\r\n if (this.assetDetailModel && value === 0) {\r\n this.assetDetailModel.assets[0].hasNonRyanInternalComments = false;\r\n this.assetDetailModel.assets[0].hasRyanInternalComments = false;\r\n this.result.hasChanges = true;\r\n this.result.savedModels = this.assetDetailModel.assets;\r\n }\r\n }\r\n\r\n isDirty(): boolean {\r\n return this.assetInfo && this.assetInfo.isFormDirty();\r\n }\r\n\r\n toggleIsExpandedForAssetInfoPanel(): void {\r\n if (!this.isMaximizedAssetInfoPanel) {\r\n this.isExpandedAssetInfoPanel = !this.isExpandedAssetInfoPanel;\r\n }\r\n }\r\n\r\n toggleIsMaximizedForAssetInfoPanel(): void {\r\n this.isExpandedAssetInfoPanel = true;\r\n this.isMaximizedAssetInfoPanel = !this.isMaximizedAssetInfoPanel;\r\n }\r\n\r\n toggleIsExpandedReturnFilingsPanel(): void {\r\n if (!this.isMaximizedReturnFilingsPanel) {\r\n this.isExpandedReturnFilingsPanel = !this.isExpandedReturnFilingsPanel;\r\n }\r\n }\r\n\r\n toggleIsMaximizedReturnFilingsPanel(): void {\r\n this.isExpandedReturnFilingsPanel = true;\r\n this.isMaximizedReturnFilingsPanel = !this.isMaximizedReturnFilingsPanel;\r\n }\r\n\r\n toggleIsExpandedForAssetActivityPanel(): void {\r\n if (!this.isMaximizedAssetActivityPanel) {\r\n this.isExpandedAssetActivityPanel = !this.isExpandedAssetActivityPanel;\r\n }\r\n }\r\n\r\n toggleIsMaximizedForAssetActivityPanel(): void {\r\n this.isExpandedAssetActivityPanel = true;\r\n this.isMaximizedAssetActivityPanel = !this.isMaximizedAssetActivityPanel;\r\n }\r\n\r\n enterAssetInfoEdit(): void {\r\n this.isAssetInfoComponentInEditState = true;\r\n }\r\n\r\n cancelAssetInfoEdit(): void {\r\n this.isAssetInfoComponentInEditState = false;\r\n this._setAssets();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n close(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n updateAssetDescriptors(assetDescriptors: AssetDescriptors): void {\r\n this.selectedAssetDescriptors = assetDescriptors;\r\n }\r\n\r\n setCurrentAssetModel(asset: AssetSummary): void {\r\n this.currentAsset = asset;\r\n }\r\n\r\n assetInfoIsReady(ready: boolean): void {\r\n this.isReadyAssetInfoComponent = ready;\r\n }\r\n\r\n async saveAssetInfoEdit(): Promise {\r\n if (this.createNewAsset) {\r\n return await this.saveNewUserCreatedAsset();\r\n }\r\n\r\n const updateModels = this.assets.map(\r\n x => {\r\n const updateModel = x.getOverrides() as Compliance.ReportingAssetUpdateModel;\r\n updateModel.classificationId = x.reportedAssetClassificationId;\r\n updateModel.lienDate = this.lienDate;\r\n updateModel.sourceAssetId = x.sourceAssetId;\r\n updateModel.isPerpetual = x.reportingIsPerpetual;\r\n updateModel.ownershipTypeId = x.assetOwnershipTypeId;\r\n updateModel.oldAssetNumber = x.reportedOldAssetNumber;\r\n updateModel.isAnchored = x.reportedIsAnchored;\r\n updateModel.isLocked = x.reportedIsLocked;\r\n updateModel.doNotPotentiallyDispose = x.reportedDoNotPotentiallyDispose;\r\n updateModel.reportingAssetId = x.reportingAssetId;\r\n\r\n if (x.reportedParcelHasOverride) {\r\n updateModel.reportingParcelId = x.reportedParcelId;\r\n }\r\n\r\n return updateModel;\r\n });\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n\r\n const updateModel: Compliance.AssetUpdateModel = {\r\n reportingAssets: updateModels,\r\n lienDate: this.lienDate\r\n };\r\n\r\n updateModel.alternativeAcqDateDescriptorId = this.selectedAssetDescriptors.acqDateAssetDescriptors > 0 ? this.selectedAssetDescriptors.acqDateAssetDescriptors : null;\r\n updateModel.alternativeCostDescriptorId = this.selectedAssetDescriptors.costAssetDescriptors > 0 ? this.selectedAssetDescriptors.costAssetDescriptors : null;\r\n\r\n const nonNullAdjustments = _.cloneDeep(this._assetInfoService.extendedCostAdjustmentTypes\r\n .map((cat: ExtendedCostAdjustmentTypeModel) => this._assetInfoService.costAdjustments[cat.costAdjustmentTypeId])\r\n .filter((ca: Compliance.AssetCostAdjustmentModel) => ca && (ca.adjustmentAmount !== null || ca.adjustmentPercentage !== null)));\r\n\r\n // convert percents to fractions of 100\r\n nonNullAdjustments.forEach(\r\n (adjustment: Compliance.AssetCostAdjustmentModel) => {\r\n if (adjustment.adjustmentPercentage !== null) {\r\n adjustment.adjustmentPercentage = adjustment.adjustmentPercentage / 100;\r\n }\r\n });\r\n\r\n updateModel.costAdjustments = nonNullAdjustments;\r\n\r\n const stateAbbr = this.currentAsset ? this.currentAsset.state : null;\r\n if (stateAbbr) {\r\n const state = this.states.find(x => x.abbr === stateAbbr);\r\n updateModel.stateId = state && state.stateID;\r\n }\r\n\r\n await lastValueFrom(this._assetRepository\r\n .update(this.assetDetailModel.assetId, updateModel));\r\n\r\n updateModel.costAdjustments = [];\r\n\r\n // Save and close if the acquisition date was changed and will cause the asset to be removed from the modal\r\n if (updateModels.some(x => x.acqDate > this.lienDate)) {\r\n this.result.hasChanges = true;\r\n this.cancelAssetInfoEdit();\r\n this.close();\r\n return;\r\n }\r\n\r\n const resultsFromRepository = await lastValueFrom(this._assetRepository\r\n .get(this.assetDetailModel.assetId, this.lienDate, true, true, true));\r\n this.assetDetailModel = resultsFromRepository.assetDetailModel;\r\n this.result.totalsModel = resultsFromRepository.assetSearchTotalsModel;\r\n this.changeDates = resultsFromRepository.changeDates;\r\n this.maxLienDate = resultsFromRepository.maxLienDate;\r\n this.updatedOverrideLienDates[this.lienDate.getTime()] = this.assetDetailModel.assets;\r\n\r\n this._setAssets();\r\n } finally {\r\n if (this.isReturnAsset) {\r\n const propertyUpdates = this.assets.reduce((acc, x) => {\r\n acc.isLocked.push(x.isLocked);\r\n acc.ownershipType.push(x.assetOwnershipType);\r\n acc.assetNumber.push(x.reportedAssetNumber);\r\n acc.acquisitionDate.push(x.acqDate ? x.acqDate.toISOString() : null);\r\n acc.disposedDate.push(x.reportedDisposedDate ? x.reportedDisposedDate.toISOString() : null);\r\n acc.description.push(x.reportedDescription || null);\r\n acc.cost.push(x.reportedCostHasOverride ? `$${x.reportedCost}` : null);\r\n acc.netBookValue.push(x.reportedNetBookValueHasOverride ? `$${x.reportedNetBookValue}` : null);\r\n acc.glAccount.push(x.reportedGlAccount && x.reportedGlAccount.accountName || null);\r\n acc.site.push(x.reportedSite ? x.reportedSite.name : null);\r\n acc.assetClass.push(x.reportedAssetClassificationDisplay ? x.reportedAssetClassificationDisplay : null);\r\n acc.parcel.push(x.parcelDisplay ? x.parcelDisplay : null);\r\n return acc;\r\n }, {\r\n isLocked: [],\r\n ownershipType: [],\r\n assetNumber: [],\r\n acquisitionDate: [],\r\n disposedDate: [],\r\n description: [],\r\n cost: [],\r\n netBookValue: [],\r\n glAccount: [],\r\n site: [],\r\n assetClass: [],\r\n parcel: []\r\n });\r\n this._productAnalyticsService.logEvent('click-asset-details-save', propertyUpdates);\r\n }\r\n busyRef.hide();\r\n }\r\n\r\n this.result.hasChanges = true;\r\n this.result.savedModels = this.updatedOverrideLienDates[this.assetListLienDate.getTime()];\r\n this.cancelAssetInfoEdit();\r\n this.isAssetInfoComponentInEditState = false;\r\n this._lienDateChanged = false;\r\n }\r\n\r\n async saveNewUserCreatedAsset(): Promise {\r\n if (!this.createNewAsset) { return; }\r\n\r\n const busyMsgSaveAsset = 'save-asset';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgSaveAsset);\r\n\r\n try {\r\n const addModel: Compliance.UserCreatedAssetAddModel = {\r\n acqDate: this.currentAsset.reportedAcqDate,\r\n assetNumber: this.currentAsset.reportedAssetNumber,\r\n topLevelCompanyId: this.topLevelCompanyId,\r\n companyId: this._assetInfoService.selectedCompanyId,\r\n cost: this.currentAsset.reportedCost,\r\n siteId: this.currentAsset.reportedSiteId,\r\n assetOwnershipTypeId: this.currentAsset.assetOwnershipTypeId,\r\n leaseTypeId: this.currentAsset.reportedLeaseTypeId,\r\n oldAssetNumber: this.currentAsset.reportedOldAssetNumber\r\n };\r\n\r\n const result = await lastValueFrom(this._assetRepository.createUserCreatedAsset(addModel));\r\n\r\n if (this.lienDate.getTime() !== result.minLienDate.getTime() &&\r\n this.lienDate.getTime() <= result.minLienDate.getTime()) {\r\n this._lienDateChanged = true;\r\n this.lienDate = result.minLienDate;\r\n this.minLienDate = result.minLienDate;\r\n this.changeDates = [result.minLienDate];\r\n } else {\r\n this.minLienDate = this.lienDate;\r\n this.changeDates = [this.lienDate];\r\n }\r\n\r\n const resultsFromRepository = await lastValueFrom(this._assetRepository.get(result.assetDetailsModel.assetId, this.lienDate));\r\n resultsFromRepository.assetDetailModel.assets[0].reportingAsset.doNotPotentiallyDispose = true;\r\n this.assetDetailModel = resultsFromRepository.assetDetailModel;\r\n this.createNewAsset = false;\r\n this._setAssets();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgSaveAsset);\r\n }\r\n\r\n this.result.hasChanges = true;\r\n this.result.newAssetCompanyId = this.assetDetailModel.companyId;\r\n\r\n this.createNewAsset = false;\r\n this.reportingAssetId = this.assetDetailModel.assets[0].reportingAsset.reportingAssetId;\r\n this.assetId = this.assetDetailModel.assetId;\r\n\r\n this.commentModalData = {\r\n entityID: this.assetDetailModel.assetId,\r\n entityTypeID: Core.EntityTypes.Asset,\r\n parcelAcctNum: null,\r\n canEdit: true,\r\n description: null,\r\n parcelID: null,\r\n year: null\r\n };\r\n\r\n this.enterAssetInfoEdit();\r\n this.isAssetInfoComponentInEditState = true;\r\n }\r\n\r\n async onLienDateChanged(lienDate: AssetLienDate): Promise {\r\n if (!this.createNewAsset) {\r\n if (this.isAssetInfoComponentInEditState) {\r\n const lienDateDate = new Date(this.lienDate);\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Editing is in progress. If you change the date, you will lose all your changes. Are you sure you want to proceed?',\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n this.lienDate = lienDateDate;\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n this.isLoading = true;\r\n const busyMsgLoadAsset = 'load-asset';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsgLoadAsset);\r\n\r\n try {\r\n const resultFromRepository = await lastValueFrom(this._assetRepository.get(this.assetDetailModel.assetId, lienDate.date, false, false));\r\n this.assetDetailModel = resultFromRepository.assetDetailModel;\r\n this.result.initialReportingAssetIds = this.assetDetailModel.assets.map((model: Compliance.AssetModel) => model.reportingAsset.reportingAssetId);\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgLoadAsset);\r\n this.isLoading = false;\r\n }\r\n\r\n this.commentModalData = {\r\n entityID: this.assetDetailModel.assetId,\r\n entityTypeID: Core.EntityTypes.Asset,\r\n parcelAcctNum: null,\r\n canEdit: true,\r\n description: null,\r\n parcelID: null,\r\n year: null\r\n };\r\n\r\n this._setAssets();\r\n }\r\n\r\n this.lienDate = lienDate.date;\r\n }\r\n\r\n get lienDateChanged(): boolean {\r\n return this._lienDateChanged;\r\n }\r\n\r\n private _setAssets(): void {\r\n if (this.createNewAsset) {\r\n this._assetInfoService.selectedCompanyId = this.newAssetCompanyId;\r\n\r\n const reportingAsset: Compliance.ReportingAssetModel = {\r\n assetClassification: null,\r\n assetId: null,\r\n reportingAssetId: null,\r\n isPerpetual: false,\r\n isPrimary: true,\r\n isAnchored: false,\r\n doNotPotentiallyDispose: false,\r\n isLocked: false,\r\n rowVersion: null\r\n };\r\n\r\n const assetModel: Compliance.AssetModel = {\r\n acqDate: null,\r\n cost: null,\r\n assetId: null,\r\n assetNumber: null,\r\n companyId: this.newAssetCompanyId,\r\n companyCode: null,\r\n companyName: null,\r\n assetOwnershipType: null,\r\n hasNonRyanInternalComments: false,\r\n hasRyanInternalComments: false,\r\n hasImportedSource: false,\r\n reportingAsset: reportingAsset,\r\n reportingAssetOverride: null,\r\n sourceAsset: null,\r\n alternativeAcqDateDescriptorId: null,\r\n alternativeCostDescriptorId: null,\r\n costAdjustments: null,\r\n areSplitAllocationsValid: true,\r\n assetAdjustmentSetId: null,\r\n changeStatus: null,\r\n assetOwnershipTypeId: 0,\r\n splitAllocationPercentage: null,\r\n assetVerificationReason: null,\r\n alternativeAcqDateDescriptorName: null,\r\n alternativeCostDescriptorName: null\r\n };\r\n\r\n this.assets = [\r\n new AssetSummary(assetModel, this._keyValueDisplayPipe, null)\r\n ];\r\n\r\n this.currentAsset = this.assets[0];\r\n } else {\r\n\r\n if (!(this.assetDetailModel && this.assetDetailModel.assets)) {\r\n return;\r\n }\r\n\r\n // map the assets\r\n this.assets = this.assetDetailModel.assets.map((x) => {\r\n return new AssetSummary(_.cloneDeep(x), this._keyValueDisplayPipe, null);\r\n }).sort((a, b) => a.isPrimary ? -1 : 1);\r\n\r\n let assetIndex = this.assets.findIndex(x => x.isPrimary);\r\n\r\n if (assetIndex === -1) {\r\n assetIndex = 0;\r\n }\r\n\r\n this.currentAsset = this.assets[assetIndex];\r\n }\r\n }\r\n}\r\n","const confirmMessage: string = 'Are you sure you want to cancel and discard all changes?';\r\n\r\nexport abstract class ModalComponentBase {\r\n protected abstract isDirty(): boolean;\r\n protected abstract close(): void;\r\n public closeWithDirtyCheck(): void {\r\n if (this.isDirty()) {\r\n if (window.confirm(confirmMessage)) {\r\n this.close();\r\n }\r\n } else {\r\n this.close();\r\n }\r\n }\r\n}","import { Component, OnDestroy } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { Subscription } from 'rxjs';\r\n\r\nexport interface ICellRendererParamsForReturnAssetDisposalsListGridAction extends ICellRendererParams {\r\n viewDetails: (params: ICellRendererParamsForReturnAssetDisposalsListGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n ``\r\n})\r\n\r\nexport class ReturnAssetDisposalsListGridActionCellRendererComponent implements ICellRendererAngularComp, OnDestroy {\r\n constructor(\r\n private _returnService: ReturnService) { }\r\n\r\n private _params: ICellRendererParamsForReturnAssetDisposalsListGridAction;\r\n private _returnReadOnlyFlagSub: Subscription;\r\n\r\n returnAsset: Compliance.ReturnAssetModel;\r\n isReadOnly: boolean = false;\r\n\r\n agInit(params: ICellRendererParamsForReturnAssetDisposalsListGridAction): void {\r\n this._returnReadOnlyFlagSub = this._returnService.isReturnInReadOnlyMode$.subscribe(x => this.isReadOnly = x);\r\n this.isReadOnly = this._returnService.isReturnInReadOnlyMode;\r\n this._params = params;\r\n this.returnAsset = params.data as Compliance.ReturnAssetModel;\r\n\r\n if (!this.returnAsset) {\r\n\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnReadOnlyFlagSub.unsubscribe();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this._params.viewDetails(this._params);\r\n }\r\n}\r\n"," 0\" [message]=\"busyMessageManager.message\">\r\n\r\n\r\n \r\n \r\n \r\n\r\n","import { Component, OnDestroy, ViewEncapsulation } from '@angular/core';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { WeissmanDateFormatPipe } from '../../../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { ReturnAssetDisposalsListAgGridDataSource, ReturnAssetDisposalsListDataSourceParams } from './agGridDataSource';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../../AgGrid';\r\nimport { ReturnAssetsService } from '../returnAssets.service';\r\nimport { ReturnAssetChangeIconCellRendererComponent } from '../Asset-List/agGridChangeIconCellRenderer.component';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../../../AgGrid/MultiSelectTracker';\r\nimport { BehaviorSubject, Subscription } from 'rxjs';\r\nimport { ReturnService } from '../../../return.service';\r\nimport {\r\n ReturnAssetBulkUpdateComponent,\r\n ReturnAssetBulkUpdateParams\r\n} from '../Return-Asset-Bulk-Update/returnAssetBulkUpdate.component';\r\nimport { IWeissmanModalComponent, WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../../../AgGrid/ToolPanel/models';\r\nimport { AssetDetailsComponent, AssetDetailsParams } from '../../../../Asset/Asset-Details/assetDetails.component';\r\nimport {\r\n ICellRendererParamsForReturnAssetDisposalsListGridAction,\r\n ReturnAssetDisposalsListGridActionCellRendererComponent\r\n} from './agGridActionCellRenderer.component';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../../../Busy-Indicator';\r\nimport { ReturnAssetRepository } from '../../../../Repositories';\r\nimport {\r\n AgGridCheckboxCellRendererComponent,\r\n ICellRendererParamsForAgGridCheckbox\r\n} from '../../../../AgGrid/CellRenderers/agGridCheckboxCellRender.component';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { TimerService } from '../../../../../UI-Lib/Utilities/timer.service';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nexport interface ReturnAssetDisposalsListParams {\r\n title?: string;\r\n priorReturnStatuses: Compliance.ReturnAssetPriorReturnStatusEnum[];\r\n formRevisionScheduleId: number;\r\n targetNonReportableSchedule: boolean;\r\n targetReportableSchedule: boolean;\r\n isDisposalOrTransferOut: boolean;\r\n scheduleGroupType?: Compliance.ScheduleGroupTypeEnum;\r\n}\r\n\r\n@Component({\r\n selector: 'return-asset-disposals-list',\r\n templateUrl: './returnAssetDisposalsList.component.html',\r\n styleUrls: ['./returnAssetDisposalsList.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ReturnAssetDisposalsListComponent implements OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnAssetRepository: ReturnAssetRepository,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _timer: TimerService\r\n ) { }\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: ReturnAssetDisposalsListAgGridDataSource;\r\n private _gridMultiSelectSub: Subscription;\r\n private _assetDetailsUpdatedSub: Subscription;\r\n private _refreshNeeded: boolean = false;\r\n private _updateOccurred: boolean;\r\n\r\n params: ReturnAssetDisposalsListParams;\r\n result: boolean;\r\n\r\n busyMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n gridTotalsRow: any;\r\n gridId: System.Guid = '47998435-E1D5-4087-979B-F6A0F8DF93E1';\r\n gridTracker: AgGridMultiSelectTracker;\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n get title(): string {\r\n return this.params.title || 'Return Disposals';\r\n }\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.ReportingAssetModel).reportingAssetId),\r\n 'totals-row': (params) => params.data && params.data.totalsRow\r\n }\r\n }).withContext(this)\r\n .withInfiniteScroll()\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .withColumnPinning()\r\n .build();\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[]): Promise => {\r\n const searchParams = this._gridDataSource.getSearchParamsWithoutPagination();\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: this._gridDataSource.totalRows\r\n };\r\n\r\n searchParams.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n\r\n if (!searchParams.selectedRows.selectAllRows && searchParams.selectedRows.selectedRows.length === 0) {\r\n searchParams.selectedRows.selectAllRows = true;\r\n }\r\n\r\n const exportModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn\r\n } as Compliance.ReturnAssetExportModel;\r\n\r\n const longRunningProcessId = await this._returnAssetsService.exportAssets(exportModel);\r\n return { longRunningProcessId, longRunningProcessTypeId: Compliance.LongRunningProcessTypeEnum.ExportReturnAssets };\r\n },\r\n canCancel: true\r\n };\r\n\r\n ngOnDestroy() {\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n }\r\n\r\n cancel(): void {\r\n this.result = this._updateOccurred;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n createMultiSelectSubs(): void {\r\n // notify the bulk update button every time the grid selection changes (if return not in read-only mode)\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(() => {\r\n const isClassificationUpdateButtonVisible = !this._returnService.isReturnInReadOnlyMode && this._returnService.canEditCompany && this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isClassificationUpdateButtonVisible);\r\n });\r\n }\r\n\r\n private async _viewAssetDetails(params: ICellRendererParamsForReturnAssetDisposalsListGridAction): Promise {\r\n const asset = params.data as Compliance.ReturnAssetModel;\r\n if (!asset) {\r\n return Promise.resolve();\r\n }\r\n\r\n const inputParams: AssetDetailsParams = {\r\n reportingAssetId: asset.reportingAssetId,\r\n assetId: asset.assetId,\r\n lienDate: this._returnService.lienDate,\r\n canEdit: this._returnService.canEditCompany && !this._returnService.isReturnInReadOnly,\r\n createNewAsset: false,\r\n topLevelCompanyId: this._returnService.companyId,\r\n assetDescriptors: this._returnService.companyAssetDescriptorMappings,\r\n newAssetCompanyId: null,\r\n canViewRyanPrivateItems: this._returnService.canViewRyanPrivateItems\r\n };\r\n\r\n const result = await this._modalService.showAsync(AssetDetailsComponent, inputParams, 'modal-xl');\r\n\r\n if (!(result && result.hasChanges)) {\r\n return Promise.resolve();\r\n }\r\n\r\n const initialIds = result.initialReportingAssetIds;\r\n const savedReportingAssetIds = result.savedModels.map((model: Compliance.AssetModel) => model.reportingAsset.reportingAssetId);\r\n const reportingAssetIds = Array.from(new Set(initialIds.concat(savedReportingAssetIds)));\r\n\r\n this.busyMessageManager.add('Working on it', 'loading');\r\n\r\n try {\r\n await this._returnAssetsService.notifyAssetDetailsUpdated(reportingAssetIds);\r\n } finally {\r\n this.busyMessageManager.remove('loading');\r\n }\r\n\r\n this._refreshDataSource();\r\n\r\n this._refreshNeeded = true;\r\n this._updateOccurred = true;\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this.createMultiSelectSubs();\r\n\r\n this._assetDetailsUpdatedSub = this._returnAssetsService.assetDetailsUpdated$.subscribe(() => {\r\n if (this._refreshNeeded) {\r\n this._refreshDataSource();\r\n this._refreshNeeded = false;\r\n }\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: '',\r\n field: 'reportingAssetId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n },\r\n {\r\n headerName: 'Asset Number',\r\n field: 'disposalAssetNumber',\r\n lockVisible: true,\r\n lockPosition: true,\r\n lockPinned: true,\r\n pinned: 'left',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Status',\r\n field: 'assetReturnStatus',\r\n sortable: false,\r\n width: AgGridColumns.textColumnExtraSmallWidth,\r\n minWidth: AgGridColumns.textColumnExtraSmallWidth,\r\n cellRendererFramework: ReturnAssetChangeIconCellRendererComponent\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'disposalDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Classification',\r\n field: 'disposalClassification',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Parcel Account',\r\n field: 'parcelAccountNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorAbbr',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Prior Site',\r\n field: 'priorSiteName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Prior Acq. Date',\r\n field: 'priorAcqDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n cellClass: 'grid-cell-readonly',\r\n hide: true\r\n },\r\n {\r\n headerName: 'Acq. Date',\r\n field: 'acqDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n hide: true\r\n },\r\n {\r\n headerName: 'Disp. Date',\r\n field: 'disposedDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n cellClass: x => {\r\n const data = x.data as Compliance.ReturnAssetModel;\r\n return (data.disposedDate && !data.sourceDisposedDate)\r\n || (data.sourceDisposedDate && data.disposedDate && data.sourceDisposedDate !== data.disposedDate)\r\n ? 'overridden' : '';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Prior Cost',\r\n field: 'priorCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n suppressMenu: true,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2')\r\n },\r\n {\r\n headerName: 'Cost',\r\n field: 'cost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n suppressMenu: true,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2')\r\n },\r\n {\r\n headerName: 'Cost Change',\r\n field: 'costChange',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n suppressMenu: true,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2')\r\n },\r\n {\r\n headerName: 'Prior Schedule',\r\n field: 'priorScheduleName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Schedule',\r\n field: 'scheduleName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Form',\r\n field: 'form',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Prior Factor Table',\r\n field: 'priorDepreciationFactorTableName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.priorDepreciationFactorTableName) ? `${rowData.priorDepreciationFactorTableName} (${rowData.priorDepreciationFactorTableLife} year life)` : '';\r\n }\r\n },\r\n {\r\n headerName: 'Factor Table',\r\n field: 'depreciationFactorTableName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.depreciationFactorTableName) ? `${rowData.depreciationFactorTableName} (${rowData.depreciationFactorTableLife} year life)` : '';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Factor',\r\n field: 'factor',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => (x && x.value) ? `${this._decimalPipe.transform(x.value * 100, '1.2-5')}%` : '',\r\n hide: true\r\n },\r\n {\r\n headerName: 'Details',\r\n field: 'calculatedAssetReturnStatus',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n sortable: false,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n if (!rowData) {\r\n return '';\r\n }\r\n\r\n switch (rowData.assetReturnStatus) {\r\n case 'Retired':\r\n return `The asset was disposed on ${this._datePipe.transform(rowData.disposedDate)}`;\r\n case 'TransferOut':\r\n return `The asset was transferred from ${rowData.priorSiteName} to ${rowData.site}`;\r\n case 'Changed':\r\n const changes: string[] = [];\r\n if (rowData.priorAcqDate && rowData.acqDate && rowData.priorAcqDate.getTime() !== rowData.acqDate.getTime()) {\r\n changes.push('the acquisition date changed');\r\n }\r\n\r\n if (rowData.priorCost > rowData.cost) {\r\n changes.push('the cost was reduced');\r\n }\r\n\r\n if (rowData.priorScheduleName !== rowData.scheduleName) {\r\n changes.push('the schedule was changed');\r\n }\r\n\r\n let changeText = '';\r\n for (let i = 0; i < changes.length; i++) {\r\n if (i > 0) {\r\n changeText += ', ';\r\n }\r\n\r\n if (changes.length - 1 === i && changes.length > 1) {\r\n changeText += 'and ';\r\n }\r\n\r\n changeText += changes[i];\r\n }\r\n\r\n return `This asset has changed since the prior return as ${changeText}`;\r\n }\r\n\r\n return rowData.calculatedAssetReturnStatus;\r\n }\r\n }\r\n ];\r\n\r\n const assetDescriptorColumns = this._returnService.companyAssetDescriptorMappings.map(mapping => {\r\n let typeSpecificAttributes;\r\n let cellStyle = '';\r\n switch (mapping.descriptor.fieldType) {\r\n case Core.DescriptorFieldTypes.Currency:\r\n typeSpecificAttributes = {\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2')\r\n };\r\n cellStyle = 'ag-numeric-cell';\r\n break;\r\n case Core.DescriptorFieldTypes.Date:\r\n\r\n typeSpecificAttributes = {\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => {\r\n if (!x.value) {\r\n return null;\r\n }\r\n\r\n const d = new Date(x.value);\r\n return this._datePipe.transform(d, true);\r\n }\r\n };\r\n break;\r\n case Core.DescriptorFieldTypes.YesNo:\r\n typeSpecificAttributes = {\r\n width: AgGridColumns.textColumnMedWidth,\r\n mindWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n isVisible: (params: ICellRendererParamsForAgGridCheckbox) => params.value !== null,\r\n canEdit: (params: ICellRendererParamsForAgGridCheckbox) => false,\r\n canEnterEditMode: () => false,\r\n onValueChanged: null\r\n } as ICellRendererParamsForAgGridCheckbox,\r\n filter: false\r\n };\r\n break;\r\n case Core.DescriptorFieldTypes.Number:\r\n typeSpecificAttributes = {\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => (x && x.value) ? `${this._decimalPipe.transform(x.value, '1.2-5')}` : ''\r\n };\r\n break;\r\n case Core.DescriptorFieldTypes.Text:\r\n typeSpecificAttributes = {\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n };\r\n break;\r\n }\r\n\r\n return {\r\n headerName: mapping.descriptor.name,\r\n field: _.camelCase(mapping.columnName),\r\n ...typeSpecificAttributes,\r\n hide: true,\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n if (mapping.descriptor.fieldType === Core.DescriptorFieldTypes.Date) {\r\n return (rowData\r\n && rowData[_.camelCase(mapping.columnName)] != null\r\n && rowData[_.camelCase(`source${ mapping.columnName}`)] != null\r\n && rowData[_.camelCase(mapping.columnName)].getTime() === rowData[_.camelCase(`source${ mapping.columnName}`)].getTime()) ? cellStyle : `${cellStyle } overridden`;\r\n } else {\r\n return (rowData && rowData[_.camelCase(mapping.columnName)] === rowData[_.camelCase(`source${ mapping.columnName}`)]) ? cellStyle : `${cellStyle } overridden`;\r\n }\r\n }\r\n };\r\n });\r\n\r\n const actionColumn = {\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n pinned: 'right',\r\n cellRendererFramework: ReturnAssetDisposalsListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this._viewAssetDetails.bind(this)\r\n } as ICellRendererParamsForReturnAssetDisposalsListGridAction,\r\n pinnedRowCellRenderer: () => {return '';}\r\n };\r\n\r\n const finalColumnDefs = [...columns, ...assetDescriptorColumns, actionColumn];\r\n\r\n this._gridApi.setColumnDefs(finalColumnDefs);\r\n\r\n this._gridApi.setSortModel([{\r\n colId: 'disposalAssetNumber',\r\n sort: 'asc'\r\n }]);\r\n\r\n this._setDataSource();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n const dataSourceParams = (): ReturnAssetDisposalsListDataSourceParams => {\r\n return {\r\n priorReturnStatuses: this.params.priorReturnStatuses,\r\n formRevisionScheduleId: this.params.formRevisionScheduleId,\r\n targetNonReportableSchedule: this.params.targetNonReportableSchedule,\r\n targetReportableSchedule: this.params.targetReportableSchedule,\r\n scheduleGroupType: this.params.scheduleGroupType\r\n };\r\n };\r\n\r\n this._gridDataSource = new ReturnAssetDisposalsListAgGridDataSource(\r\n this._gridApi,\r\n this._returnService,\r\n this._returnAssetsService,\r\n this._returnAssetRepository,\r\n dataSourceParams,\r\n this.handleTotalsUpdate\r\n );\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n handleTotalsUpdate = (totals: Compliance.ReturnAssetSearchTotalsModel) => {\r\n const assetModelRow: any = {\r\n disposalAssetNumber: 'TOTAL',\r\n cost: totals.totalCost,\r\n reportedValue: totals.totalReportedValue,\r\n priorCost: totals.totalPriorCost,\r\n costChange: totals.totalCostChange,\r\n assetNumber: 'TOTAL'\r\n };\r\n\r\n assetModelRow.totalsRow = true;\r\n this.gridTotalsRow = assetModelRow;\r\n\r\n const totalRows = [this.gridTotalsRow];\r\n\r\n this._timer.setTimeout(() => this._gridApi.setPinnedBottomRowData(totalRows), 100);\r\n };\r\n\r\n async bulkUpdate(): Promise {\r\n // form revision selection is required\r\n if (!this._returnService.sharedState.formRevisionId) {\r\n this._toastr.warning('Bulk update cannot be used with \\'Primary for Return\\' selected. Please select a form revision from the return overview settings panel.');\r\n return;\r\n }\r\n\r\n const searchModel = this._gridDataSource.getSearchParamsWithoutPagination();\r\n searchModel.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n\r\n const params: ReturnAssetBulkUpdateParams = {\r\n filingBatchId: this._returnService.filingBatchId,\r\n searchModel: searchModel,\r\n selectedCount: this.gridTracker.getSelectedRowsCount(),\r\n showPriorScheduleField: this._returnService.filingBatch.getPriorReturnFromAssetList\r\n };\r\n\r\n const result = await this._modalService.showAsync(ReturnAssetBulkUpdateComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Working on it' });\r\n try {\r\n let updateWorkingSetReportingAssetIds: number[] = [];\r\n\r\n if (!searchModel.selectedRows.selectAllRows) {\r\n updateWorkingSetReportingAssetIds = searchModel.selectedRows.selectedRows;\r\n }\r\n\r\n await this._returnAssetsService.notifyAssetDetailsUpdated(updateWorkingSetReportingAssetIds);\r\n\r\n this._refreshDataSource();\r\n this._updateOccurred = true;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n this.gridTracker.clear(false);\r\n this._gridDataSource.clearTotals();\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n}\r\n","\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0 || data.existingDeductionsTrueUp.cost > 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
TotalReportedNot ReportedNot Assigned
Prior Return Cost Forward{{ data.priorReturnCostForward.cost | currency: 'USD' : 'symbol' }}{{ data.priorReturnCostForward.reportableCost | currency: 'USD' : 'symbol' }}{{ data.priorReturnCostForward.nonReportableCost | currency: 'USD' : 'symbol' }}{{ data.priorReturnCostForward.unassignedCost | currency: 'USD' : 'symbol' }}
Existing Overrides True Up{{ data.existingOverridesTrueUp.cost | currency: 'USD' : 'symbol' }}{{ data.existingOverridesTrueUp.reportableCost | currency: 'USD' : 'symbol' }}{{ data.existingOverridesTrueUp.nonReportableCost | currency: 'USD' : 'symbol' }}{{ data.existingOverridesTrueUp.unassignedCost | currency: 'USD' : 'symbol' }}
Existing Deductions True Up{{ data.existingDeductionsTrueUp.cost | currency: 'USD' : 'symbol' }}{{ data.existingDeductionsTrueUp.reportableCost | currency: 'USD' : 'symbol' }}{{ data.existingDeductionsTrueUp.nonReportableCost | currency: 'USD' : 'symbol' }}{{ data.existingDeductionsTrueUp.unassignedCost | currency: 'USD' : 'symbol' }}
Prior Return Cost 0 || data.existingDeductionsTrueUp.cost > 0\"> Plus True Ups{{ data.priorReturn.cost | currency: 'USD' : 'symbol' }}{{ data.priorReturn.reportableCost | currency: 'USD' : 'symbol' }}{{ data.priorReturn.nonReportableCost | currency: 'USD' : 'symbol' }}{{ data.priorReturn.unassignedCost | currency: 'USD' : 'symbol' }}
 
Acquisitions\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Transfers In\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Cost Increases\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Changed to Reported\r\n \r\n \r\n \r\n \r\n -\r\n \r\n -\r\n
Total Additions \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
 
Disposals\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Transfers Out\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Cost Decreases\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Changed to Not Reported\r\n \r\n \r\n -\r\n \r\n \r\n \r\n -\r\n
Suppressed Assets\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Total Deductions {{ data.deductions.cost | currency: 'USD' : 'symbol' }}{{ data.deductions.reportableCost | currency: 'USD' : 'symbol' }}{{ data.deductions.nonReportableCost | currency: 'USD' : 'symbol' }}{{ data.deductions.unassignedCost | currency: 'USD' : 'symbol' }}
 
Current Return Cost\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Not Assigned to a Schedule\r\n \r\n
 
Prior Rendered Value{{ data.priorReportedValue | currency: 'USD' : 'symbol' }}
Current Rendered Value{{ data.currentReportedValue | currency: 'USD' : 'symbol' }}
Est. FMV{{ data.currentEstimatedFMV | currency: 'USD' : 'symbol' }}
\r\n","import { Component, OnInit, OnDestroy} from '@angular/core';\r\nimport { ReturnSummaryReconciliationReport } from '../../../Models/returnSummaryReconciliationReport';\r\nimport { ReturnService, ReturnServiceSharedState } from '../../../return.service';\r\nimport { ReturnUpdateLogicService } from '../../../returnUpdateLogic.service';\r\nimport { ReturnAssetsService, ReturnAssetsServiceSharedState } from '../../Assets/returnAssets.service';\r\nimport { ReturnOverviewService, ReturnOverviewServiceSharedState } from '../returnOverview.service';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport { ReturnAssetDisposalsListParams, ReturnAssetDisposalsListComponent } from '../../Assets/Asset-Disposals-List/returnAssetDisposalsList.component';\r\nimport { Subject } from 'rxjs';\r\nimport { WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'return-summary-reconciliation-report',\r\n templateUrl: './returnSummary.component.html'\r\n})\r\nexport class ReturnSummaryReconciliationReportComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _returnOverviewService: ReturnOverviewService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService) {\r\n }\r\n data: ReturnSummaryReconciliationReport;\r\n isBusy: boolean;\r\n\r\n private _localReturnServiceSharedState: ReturnServiceSharedState;\r\n private _localReturnOverviewServiceSharedState: ReturnOverviewServiceSharedState;\r\n private _localReturnAssetsServiceSharedState: ReturnAssetsServiceSharedState;\r\n private _showEstimatedFMV: boolean = true;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get showEstimatedFMV(): boolean {\r\n return this._showEstimatedFMV;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._returnOverviewService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._returnOverviewService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n onReturnPartServiceActivated(): void {\r\n this._returnUpdateLogicService.loading$.pipe(takeUntil(this._destroy$))\r\n .subscribe((loading) => this.isBusy = loading);\r\n\r\n this._returnUpdateLogicService.returnSummaryReport$.pipe(takeUntil(this._destroy$))\r\n .subscribe((report) => {\r\n this.data = report;\r\n this._showEstimatedFMV = this.data?.showEstimatedFMV;\r\n });\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._destroy$.next();\r\n }\r\n\r\n navigateToAssets(): void {\r\n const sharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n sharedState.assetStatusesFilter = [];\r\n this._returnAssetsService.setScheduleAndFactorFilter(sharedState.scheduleAndFactorFilter);\r\n this._returnOverviewService.notifyReturnAssetsSelected(sharedState);\r\n }\r\n\r\n navigateToAssetsAssignedToNoSchedule(\r\n filterAcquisition: boolean = false,\r\n filterTransferIn: boolean = false,\r\n filterCostChange: boolean = false\r\n ): void {\r\n const sharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: true,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n sharedState.assetStatusesFilter = [];\r\n\r\n if (filterAcquisition) sharedState.assetStatusesFilter.push(Compliance.ReturnAssetPriorReturnStatusEnum.New);\r\n if (filterTransferIn) sharedState.assetStatusesFilter.push(Compliance.ReturnAssetPriorReturnStatusEnum.TransferIn);\r\n if (filterCostChange) sharedState.assetStatusesFilter.push(Compliance.ReturnAssetPriorReturnStatusEnum.ChangedCostIncreased);\r\n\r\n this._returnAssetsService.setScheduleAndFactorFilter(sharedState.scheduleAndFactorFilter);\r\n this._returnOverviewService.notifyReturnAssetsSelected(sharedState);\r\n }\r\n\r\n navigateToAssetsAssignedToNonReportableSchedule(): void {\r\n const sharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: true,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n sharedState.assetStatusesFilter = [];\r\n this._returnAssetsService.setScheduleAndFactorFilter(sharedState.scheduleAndFactorFilter);\r\n this._returnOverviewService.notifyReturnAssetsSelected(sharedState);\r\n }\r\n\r\n navigateToAssetsAssignedToReportableSchedule(): void {\r\n const sharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: true,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n sharedState.assetStatusesFilter = [];\r\n this._returnAssetsService.setScheduleAndFactorFilter(sharedState.scheduleAndFactorFilter);\r\n this._returnOverviewService.notifyReturnAssetsSelected(sharedState);\r\n }\r\n\r\n navigateToAdditions(\r\n targetNonReportableSchedule: boolean,\r\n targetReportableSchedule: boolean,\r\n filterAcquisition: boolean,\r\n filterTransferIn: boolean,\r\n filterCostChange: boolean,\r\n filterReportabilityChange: boolean\r\n ): void {\r\n const sharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: targetNonReportableSchedule,\r\n showOnlyAssignedToReportableSchedule: targetReportableSchedule,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n sharedState.assetStatusesFilter = [];\r\n\r\n if (filterAcquisition) sharedState.assetStatusesFilter.push(Compliance.ReturnAssetPriorReturnStatusEnum.New);\r\n if (filterTransferIn) sharedState.assetStatusesFilter.push(Compliance.ReturnAssetPriorReturnStatusEnum.TransferIn);\r\n if (filterCostChange) sharedState.assetStatusesFilter.push(Compliance.ReturnAssetPriorReturnStatusEnum.ChangedCostIncreased);\r\n if (filterReportabilityChange) sharedState.assetStatusesFilter.push(Compliance.ReturnAssetPriorReturnStatusEnum.ChangedScheduleNonReportableToReportable);\r\n\r\n this._returnAssetsService.setScheduleAndFactorFilter(sharedState.scheduleAndFactorFilter);\r\n this._returnOverviewService.notifyReturnAssetsSelected(sharedState);\r\n }\r\n\r\n async navigateToDeductions(\r\n title: string,\r\n targetReportableSchedule: boolean,\r\n targetNonReportableSchedule: boolean,\r\n filterDisposed: boolean,\r\n filterTransferOut: boolean,\r\n filterCostChange: boolean,\r\n filterReportabilityChange: boolean\r\n ): Promise {\r\n\r\n const params: ReturnAssetDisposalsListParams = {\r\n title: title,\r\n priorReturnStatuses: [],\r\n formRevisionScheduleId: null,\r\n targetNonReportableSchedule: targetNonReportableSchedule,\r\n targetReportableSchedule: targetReportableSchedule,\r\n isDisposalOrTransferOut: filterDisposed || filterTransferOut\r\n };\r\n\r\n if (filterDisposed) params.priorReturnStatuses.push(Compliance.ReturnAssetPriorReturnStatusEnum.Retired);\r\n if (filterTransferOut) params.priorReturnStatuses.push(Compliance.ReturnAssetPriorReturnStatusEnum.TransferOut);\r\n if (filterCostChange) params.priorReturnStatuses.push(Compliance.ReturnAssetPriorReturnStatusEnum.ChangedCostDecreased);\r\n if (filterReportabilityChange) params.priorReturnStatuses.push(Compliance.ReturnAssetPriorReturnStatusEnum.ChangedScheduleReportableToNonReportable);\r\n\r\n await this._modalService.showAsync(ReturnAssetDisposalsListComponent, params, 'modal-xl');\r\n\r\n await this._returnUpdateLogicService.refreshReturnSummary();\r\n }\r\n}\r\n","\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Prior ReturnAdditionsDisposalsCurrent ReturnNet Change% Change
{{ schedule.scheduleName }}{{ schedule.priorCost | currency: 'USD' : 'symbol' }}\r\n \r\n \r\n \r\n \r\n \r\n {{ schedule.netChange | currency: 'USD' : 'symbol' }}{{ schedule.percentChange === null ? '' : (schedule.percentChange | percent: '1.2') }}
Reported Cost{{ data.totalReportable.priorCost | currency: 'USD' : 'symbol' }}\r\n \r\n \r\n \r\n \r\n \r\n {{ data.totalReportable.netChange | currency: 'USD' : 'symbol' }}{{ data.totalReportable.percentChange === null ? '' : (data.totalReportable.percentChange | percent: '1.2') }}
 
Not Reported Cost{{ data.totalNonReportable.priorCost | currency: 'USD' : 'symbol' }}\r\n \r\n \r\n \r\n \r\n \r\n {{ data.totalNonReportable.netChange | currency: 'USD' : 'symbol' }}{{ data.totalNonReportable.percentChange === null ? '' : (data.totalNonReportable.percentChange | percent: '1.2') }}
Total Cost{{ data.total.priorCost | currency: 'USD' : 'symbol' }}{{ data.total.additions | currency: 'USD' : 'symbol' }}{{ data.total.disposals | currency: 'USD' : 'symbol' }}{{ data.total.cost | currency: 'USD' : 'symbol' }}{{ data.total.netChange | currency: 'USD' : 'symbol' }}{{ data.total.percentChange === null ? '' : (data.total.percentChange | percent: '1.2') }}
Not Assigned to a Schedule\r\n \r\n \r\n \r\n
\r\n","import { Component, OnInit, OnDestroy, Input } from '@angular/core';\r\nimport { ScheduleAdditionsDisposalsReconciliationReport, ScheduleAdditionsDisposalReconciliationReportRow } from '../../../Models/scheduleAdditionsDisposalsReconciliationReport';\r\nimport { ReturnServiceSharedState, ReturnService } from '../../../return.service';\r\nimport { ReturnUpdateLogicService } from '../../../returnUpdateLogic.service';\r\nimport { ReturnAssetsService, ReturnAssetsServiceSharedState } from '../../Assets/returnAssets.service';\r\nimport { ReturnOverviewService, ReturnOverviewServiceSharedState } from '../returnOverview.service';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport { Subject } from 'rxjs';\r\nimport { WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport { ReturnAssetDisposalsListParams, ReturnAssetDisposalsListComponent } from '../../Assets/Asset-Disposals-List/returnAssetDisposalsList.component';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'schedule-additions-disposals-reconciliation-report',\r\n templateUrl: './scheduleAdditionsDisposals.component.html'\r\n})\r\nexport class ScheduleAdditionsDisposalsReconciliationReportComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _returnOverviewService: ReturnOverviewService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService) { }\r\n\r\n @Input() hideEmptySchedules: boolean;\r\n\r\n isBusy: boolean;\r\n data: ScheduleAdditionsDisposalsReconciliationReport;\r\n canNavigate: boolean = false;\r\n\r\n private _localReturnServiceSharedState: ReturnServiceSharedState;\r\n private _localReturnOverviewServiceSharedState: ReturnOverviewServiceSharedState;\r\n private _localReturnAssetsServiceSharedState: ReturnAssetsServiceSharedState;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n get reportableSchedules(): ScheduleAdditionsDisposalReconciliationReportRow[] {\r\n return this.data &&\r\n _.filter(this.data.reportableSchedules,\r\n x => {\r\n if (this.hideEmptySchedules) {\r\n return !!(x.cost || x.priorCost || x.additions || x.disposals);\r\n } else {\r\n return true;\r\n }\r\n });\r\n }\r\n\r\n ngOnInit(): void {\r\n this._returnOverviewService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._returnOverviewService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n await this._refreshReport();\r\n\r\n this._returnUpdateLogicService.returnOverviewReport$.pipe(takeUntil(this._destroy$))\r\n .subscribe(() => this._refreshReport());\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._destroy$.next();\r\n }\r\n\r\n navigateToReturnTotals(\r\n row: ScheduleAdditionsDisposalReconciliationReportRow,\r\n isForAdditions: boolean,\r\n isForNonReportableAssets: boolean,\r\n isForReportableAssets: boolean,\r\n isForUnassignedAssets: boolean\r\n ): void {\r\n const sharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n\r\n if (isForAdditions) {\r\n sharedState.assetStatusesFilter = [\r\n Compliance.ReturnAssetPriorReturnStatusEnum.New,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.TransferIn,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.ChangedCostIncreased,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.ChangedScheduleNonReportableToReportable\r\n ];\r\n } else {\r\n sharedState.assetStatusesFilter = [];\r\n }\r\n\r\n if (isForNonReportableAssets) {\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: true,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n } else if (isForReportableAssets) {\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: true,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n }\r\n else if (isForUnassignedAssets) {\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: true,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n } else if(row) {\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: row.formRevisionScheduleId ? [row.formRevisionScheduleId] : [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n sharedState.separateFactorTablesFilter = false;\r\n if (row.assetsCount === 0) sharedState.hideEmptySchedulesFilter = false;\r\n } else {\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n }\r\n\r\n this._returnAssetsService.setScheduleAndFactorFilter(sharedState.scheduleAndFactorFilter);\r\n this._returnOverviewService.notifyReturnAssetsSelected(sharedState);\r\n }\r\n\r\n async navigateToReturnDisposals(row: ScheduleAdditionsDisposalReconciliationReportRow, targetReportableSchedule: boolean, targetNonReportableSchedule: boolean): Promise {\r\n const params: ReturnAssetDisposalsListParams = {\r\n priorReturnStatuses: [\r\n Compliance.ReturnAssetPriorReturnStatusEnum.Retired,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.TransferOut,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.ChangedCostDecreased\r\n ],\r\n formRevisionScheduleId: null,\r\n targetNonReportableSchedule: targetNonReportableSchedule,\r\n targetReportableSchedule: targetReportableSchedule,\r\n isDisposalOrTransferOut: false\r\n };\r\n\r\n if (row) {\r\n params.formRevisionScheduleId = row.formRevisionScheduleId;\r\n }\r\n\r\n const result = await this._modalService.showAsync(ReturnAssetDisposalsListComponent, params, 'modal-xl');\r\n\r\n if (result) {\r\n await this._loadReport();\r\n }\r\n }\r\n\r\n private _refreshCanNavigate(): void {\r\n this.canNavigate = !!(this._localReturnServiceSharedState && this._localReturnServiceSharedState.formRevisionId);\r\n }\r\n\r\n private async _refreshReport(): Promise {\r\n const returnServiceSharedState: ReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n const returnAssetsServiceSharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n const returnOverviewServiceSharedState: ReturnOverviewServiceSharedState = this._returnOverviewService.getSharedStateClone();\r\n\r\n // get input parameters for comparison\r\n const localReturnIds = (this._localReturnServiceSharedState && this._localReturnServiceSharedState.returns && this._localReturnServiceSharedState.returns.map(x => x.returnId)) || [];\r\n const sharedReturnIds = returnServiceSharedState.returns.map(x => x.returnId);\r\n\r\n const localReconciliationReport = this._localReturnOverviewServiceSharedState && this._localReturnOverviewServiceSharedState.reconciliationReport;\r\n const sharedReconciliationReport = returnOverviewServiceSharedState.reconciliationReport;\r\n\r\n const localAssetDetailsUpdatedTimestamp = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n const sharedAssetDetailsUpdatedTimestamp = returnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n\r\n const localAssetMappingsUpdatedTimestamp = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n const sharedAssetMappingsUpdatedTimestamp = returnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n\r\n // check to see if input parameters are available\r\n if (!sharedReturnIds.length || sharedReconciliationReport === null || !returnServiceSharedState.formRevisionId) {\r\n this._blankReport();\r\n return;\r\n }\r\n\r\n // check to see if input parameters have changed\r\n if (\r\n !_.isEqual(localReturnIds, sharedReturnIds) ||\r\n !_.isEqual(localReconciliationReport, sharedReconciliationReport) ||\r\n !_.isEqual(localAssetDetailsUpdatedTimestamp, sharedAssetDetailsUpdatedTimestamp) ||\r\n !_.isEqual(localAssetMappingsUpdatedTimestamp, sharedAssetMappingsUpdatedTimestamp)\r\n ) {\r\n await this._loadReport();\r\n }\r\n }\r\n\r\n private _blankReport(): void{\r\n this._persistState();\r\n this.data = null;\r\n this._refreshCanNavigate();\r\n }\r\n\r\n private _persistState(): void {\r\n this._localReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n this._localReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n this._localReturnOverviewServiceSharedState = this._returnOverviewService.getSharedStateClone();\r\n }\r\n\r\n private async _loadReport(): Promise {\r\n this._persistState();\r\n\r\n this.isBusy = true;\r\n try {\r\n this.data = await this._returnOverviewService.getScheduleAdditionsDisposalReconciliationReport();\r\n this._refreshCanNavigate();\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n}\r\n","
\r\n \r\n \r\n \r\n \r\n
\r\n","import { Component, OnInit, OnDestroy, Input, SimpleChanges, SimpleChange } from '@angular/core';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport {\r\n FilingControlReconciliationReport,\r\n ReturnFilingControlRow,\r\n ReturnFilingControlAssetFilter\r\n} from '../../../Models/filingControlReconciliationReport';\r\nimport { ReturnService, ReturnServiceSharedState } from '../../../return.service';\r\nimport { ReturnUpdateLogicService } from '../../../returnUpdateLogic.service';\r\nimport { ReturnAssetsService, ReturnAssetsServiceSharedState } from '../../Assets/returnAssets.service';\r\nimport {\r\n FilingControlGroupBy,\r\n ReturnOverviewService,\r\n ReturnOverviewServiceSharedState\r\n} from '../returnOverview.service';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport { Subject } from 'rxjs';\r\nimport {\r\n ReturnPreviewService,\r\n ReturnPreviewServiceSharedState,\r\n ReturnFormModel\r\n} from '../../Preview/returnPreview.service';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface FilingControlComponentChanges extends SimpleChanges {\r\n data: SimpleChange;\r\n refreshing: SimpleChange;\r\n}\r\n\r\n@Component({\r\n selector: 'filing-control-reconciliation-report',\r\n templateUrl: './filingControl.component.html'\r\n})\r\nexport class FilingControlReconciliationReportComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _returnOverviewService: ReturnOverviewService,\r\n private readonly _returnPreviewService: ReturnPreviewService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService) {\r\n }\r\n\r\n @Input() groupBy: FilingControlGroupBy;\r\n\r\n data: FilingControlReconciliationReport;\r\n filingControlGroupBy = FilingControlGroupBy;\r\n refreshing: boolean;\r\n\r\n private _localReturnServiceSharedState: ReturnServiceSharedState;\r\n private _localReturnOverviewServiceSharedState: ReturnOverviewServiceSharedState;\r\n private _localReturnAssetsServiceSharedState: ReturnAssetsServiceSharedState;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n get formRevisionId(): number {\r\n return this._localReturnServiceSharedState && this._localReturnServiceSharedState.formRevisionId;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._returnOverviewService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._returnOverviewService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n await this._refreshReport();\r\n\r\n this._returnUpdateLogicService.loading$.pipe(takeUntil(this._destroy$))\r\n .subscribe((loading) => this.refreshing = loading);\r\n\r\n this._returnUpdateLogicService.returnOverviewReport$.pipe(takeUntil(this._destroy$))\r\n .subscribe((report) => {\r\n if (report) {\r\n this._refreshReport();\r\n }\r\n });\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._destroy$.next();\r\n }\r\n\r\n async refresh(): Promise {\r\n await this._loadReport();\r\n }\r\n\r\n navigateToAssets(assetFilter: ReturnFilingControlAssetFilter): void {\r\n const sharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n sharedState.formRevisionId = this.formRevisionId || assetFilter.primaryFormRevisionId;\r\n sharedState.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: assetFilter.showOnlyAssignedToReportableSchedule,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n\r\n sharedState.assetStatusesFilter = [];\r\n\r\n this._returnAssetsService.setScheduleAndFactorFilter(sharedState.scheduleAndFactorFilter);\r\n this._returnOverviewService.notifyReturnAssetsSelected(sharedState);\r\n this._returnService.applyRemoteReturnBatchFilter(assetFilter.returnIds);\r\n }\r\n\r\n // if a form is selected, use that else use primary for return\r\n navigateToPreview(filingControl: ReturnFilingControlRow): void {\r\n if (!(this.formRevisionId || filingControl.primaryFormRevisionId)) {\r\n console.warn('Expected form revision or primary form revision.');\r\n return;\r\n }\r\n\r\n // if a form is selected, use that, otherwise use primary for return\r\n const formRevisionId = this.formRevisionId || filingControl.primaryFormRevisionId;\r\n if (!formRevisionId) {\r\n return;\r\n }\r\n\r\n const returnFormRevision = _.find(filingControl.returnFormRevisions, x => x.formRevisionId === formRevisionId);\r\n\r\n if (!returnFormRevision) {\r\n console.warn('Expected to find return form revision.');\r\n return;\r\n }\r\n\r\n const sharedState: ReturnPreviewServiceSharedState = this._returnPreviewService.getSharedStateClone();\r\n sharedState.returnForm = {\r\n mergeParcelId: filingControl.parcelId,\r\n returnId: filingControl.returnId,\r\n returnFormRevisionId: returnFormRevision.returnFormRevisionId,\r\n returnFormRevisionReportId: null,\r\n formRevisionId: returnFormRevision.formRevisionId,\r\n reportId: null,\r\n isExcel: null\r\n } as ReturnFormModel;\r\n\r\n this._returnOverviewService.notifyReturnPreviewSelected(sharedState);\r\n }\r\n\r\n private async _refreshReport(): Promise {\r\n const returnServiceSharedState: ReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n const returnAssetsServiceSharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n const returnOverviewServiceSharedState: ReturnOverviewServiceSharedState = this._returnOverviewService.getSharedStateClone();\r\n\r\n // get input parameters for comparison\r\n const localFormRevisionId = this._localReturnServiceSharedState && this._localReturnServiceSharedState.formRevisionId;\r\n const sharedFormRevisionId = returnServiceSharedState.formRevisionId;\r\n\r\n const localReturnIds = (this._localReturnServiceSharedState && this._localReturnServiceSharedState.returns && this._localReturnServiceSharedState.returns.map(x => x.returnId)) || [];\r\n const sharedReturnIds = returnServiceSharedState.returns.map(x => x.returnId);\r\n\r\n const localReconciliationReport = this._localReturnOverviewServiceSharedState && this._localReturnOverviewServiceSharedState.reconciliationReport;\r\n const sharedReconciliationReport = returnOverviewServiceSharedState.reconciliationReport;\r\n\r\n const localAssetDetailsUpdatedTimestamp = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n const sharedAssetDetailsUpdatedTimestamp = returnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n\r\n const localAssetMappingsUpdatedTimestamp = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n const sharedAssetMappingsUpdatedTimestamp = returnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n\r\n const localFormRevisionsTimestamp = this._localReturnServiceSharedState && this._localReturnServiceSharedState.returnFormRevisionsUpdatedTimestamp;\r\n const sharedFormRevisionsTimestamp = returnServiceSharedState.returnFormRevisionsUpdatedTimestamp;\r\n\r\n // check to see if input parameters are available\r\n if (!sharedReturnIds.length || sharedReconciliationReport === null) {\r\n this._blankReport();\r\n return;\r\n }\r\n\r\n // check to see if input parameters have changed\r\n if (\r\n !_.isEqual(localFormRevisionId, sharedFormRevisionId) ||\r\n !_.isEqual(localReturnIds, sharedReturnIds) ||\r\n !_.isEqual(localReconciliationReport, sharedReconciliationReport) ||\r\n !_.isEqual(localAssetDetailsUpdatedTimestamp, sharedAssetDetailsUpdatedTimestamp) ||\r\n !_.isEqual(localAssetMappingsUpdatedTimestamp, sharedAssetMappingsUpdatedTimestamp) ||\r\n !_.isEqual(localFormRevisionsTimestamp, sharedFormRevisionsTimestamp)\r\n ) {\r\n await this._loadReport();\r\n }\r\n }\r\n\r\n private _blankReport(): void {\r\n this._persistState();\r\n\r\n this.data = new FilingControlReconciliationReport({ returns: [] } as Compliance.ReturnFilingControlSummaryModel,\r\n this._returnService.getAssociatedReturnFormRevisions(),\r\n this._returnService.sharedState.returns);\r\n }\r\n\r\n private _persistState(): void {\r\n this._localReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n this._localReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n this._localReturnOverviewServiceSharedState = this._returnOverviewService.getSharedStateClone();\r\n }\r\n\r\n private async _loadReport(): Promise {\r\n this._persistState();\r\n this.refreshing = true;\r\n\r\n try {\r\n this.data = await this._returnOverviewService.getFilingControlReconciliationReport();\r\n } finally {\r\n this.refreshing = false;\r\n }\r\n }\r\n}\r\n","
\r\n \r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n
\r\n\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n \r\n \r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n","import { Component, OnInit, OnDestroy} from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { ReturnService } from '../../return.service';\r\nimport { ReturnUpdateLogicService } from '../../returnUpdateLogic.service';\r\nimport { FilingControlGroupBy, ReturnOverviewService } from './returnOverview.service';\r\nimport { IReturnPartComponent, ReturnPartServiceBase } from '../../Models/returnPartServiceBase';\r\nimport { ReconciliationReport } from '../../Models/reconciliationReport';\r\nimport { RETURN_OVERVIEW_COMPONENT_HELP } from './returnOverview.component.help';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'return-overview',\r\n templateUrl: './returnOverview.component.html',\r\n styleUrls: ['./returnOverview.component.scss']\r\n})\r\nexport class ReturnOverviewComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnOverviewService: ReturnOverviewService,\r\n private readonly _helpService: HelpService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService\r\n ) {}\r\n\r\n selectedReconciliationReport: ReconciliationReport = null;\r\n\r\n hideEmptySchedules: boolean = true;\r\n\r\n groupBy: UntypedFormControl = new UntypedFormControl(FilingControlGroupBy.None);\r\n groupOptions: Compliance.NameValuePair[] = [\r\n { name: 'None', value: FilingControlGroupBy.None },\r\n { name: 'Assessor', value: FilingControlGroupBy.Assessor }\r\n ];\r\n\r\n returnSummaryReconciliationReport: ReconciliationReport;\r\n scheduleAdditionsDisposalsReconciliationReport: ReconciliationReport;\r\n filingControlReconciliationReport: ReconciliationReport;\r\n\r\n private _reconciliationReports: ReconciliationReport[];\r\n\r\n private _hasForms: boolean = false;\r\n private _consolidatedOption: Compliance.NameValuePair = { name: 'Consolidated Returns', value: FilingControlGroupBy.Consolidated };\r\n private _destroy$: Subject = new Subject();\r\n\r\n get returnPartServiceForInterPartComponent(): ReturnPartServiceBase { return this._returnOverviewService; }\r\n\r\n get reconciliationReports(): ReconciliationReport[] {\r\n return _.filter(this._reconciliationReports, x => x.allowPrimaryForReturn || this._hasForms);\r\n }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(RETURN_OVERVIEW_COMPONENT_HELP);\r\n this._reconciliationReports = this._returnOverviewService.reconciliationReports;\r\n this.returnSummaryReconciliationReport = this._reconciliationReports[0];\r\n this.scheduleAdditionsDisposalsReconciliationReport = this._reconciliationReports[1];\r\n this.filingControlReconciliationReport = this._reconciliationReports[2];\r\n\r\n this._returnOverviewService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnOverviewService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n this._returnUpdateLogicService.returnOverviewReport$.pipe(takeUntil(this._destroy$)).subscribe((report) => {\r\n if (report) {\r\n this.selectedReconciliationReport = report;\r\n this._hasForms = !!this._returnService.getUniqueAssociatedReturnFormRevisions().length;\r\n\r\n this._returnOverviewService.setReconciliationReport(this.selectedReconciliationReport);\r\n }\r\n });\r\n\r\n this._returnService.returns$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe((returns) => {\r\n if (returns) {\r\n if (this._returnService.isConsolidatedReturn && !this.groupOptions.includes(this._consolidatedOption)) {\r\n this.groupOptions.push(this._consolidatedOption);\r\n }\r\n }\r\n });\r\n\r\n await this._returnUpdateLogicService.refreshOverview();\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async onSelectedReconciliationReportChange(report: ReconciliationReport): Promise {\r\n this.selectedReconciliationReport = report;\r\n this._returnOverviewService.setReconciliationReport(this.selectedReconciliationReport);\r\n await this._returnUpdateLogicService.refreshReturnOverview();\r\n }\r\n}\r\n","import { AbstractControl, ValidatorFn } from '@angular/forms';\r\nimport * as _ from 'lodash';\r\n\r\nexport function WsUniqueYearValidator(yearControls: AbstractControl[]): ValidatorFn {\r\n return (control: AbstractControl): { [key: string]: boolean }| null => {\r\n const values: number[] = yearControls.map(x => x.value);\r\n if (_.uniq(values).length !== values.length) {\r\n return { 'wsUniqueYear': true };\r\n }\r\n return null;\r\n }\r\n}\r\n","import { IExpandableComponent } from './expandableComponent.model';\r\nimport { IExpandableComponentContainer } from './expandableComponentContainer.model';\r\n\r\nexport class BaseExpandableComponent implements IExpandableComponent {\r\n protected constructor(\r\n protected expandableComponentContainer: IExpandableComponentContainer,\r\n protected name: string) {\r\n }\r\n\r\n getName(): string {\r\n return this.name;\r\n }\r\n\r\n get isExpanded(): boolean {\r\n return this.expandableComponentContainer.isComponentExpanded(this);\r\n }\r\n\r\n expandComponent():void {\r\n this.expandableComponentContainer.setExpandedComponent(this);\r\n }\r\n\r\n collapseComponent():void {\r\n this.expandableComponentContainer.setExpandedComponent(null);\r\n }\r\n}\r\n","import { Assessor } from '../assessor.model';\r\n\r\n// This only contains some functionality from the task service; please add more to the definition as needed\r\nexport abstract class AssessorService {\r\n // At some point we should define this so it doesn't have to be \"any\" (for what it's worth, this isn't well-defined on the server either)\r\n //abstract getTaskSummaryByEntity(entityID: number, entityTypeID: number): Promise;\r\n //abstract launchTaskModal(entityID: number, entityTypeID: number): void;\r\n abstract getByStateId(stateId: number): Promise ;\r\n}\r\n","import { Pipe, PipeTransform } from '@angular/core'\r\nimport { Constants } from \"../../../constants.new\";\r\n\r\n@Pipe({ name: 'wsFactorTableTypeName' })\r\nexport class WeissmanFactorTableTypeNamePipe implements PipeTransform {\r\n constructor(private _constants: Constants) { }\r\n transform(tableType: number): string {\r\n let factorTableType = this._constants.FactorTableTypes.find(x => x.value === tableType);\r\n return (factorTableType && factorTableType.name) || (tableType && tableType.toString());\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n
\r\n TABLE INFO\r\n
\r\n
\r\n FACTORS\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
{{ fCore.controls.tableName.value }}
\r\n \r\n
\r\n
Table name is required.
\r\n
Table name is too long.
\r\n
\r\n
\r\n\r\n
\r\n \r\n
{{ fCore.controls.tableLife.value }}
\r\n \r\n
\r\n
Life is required.
\r\n
\r\n
\r\n\r\n
\r\n \r\n
{{ fCore.controls.tableType.value | wsFactorTableTypeName }}
\r\n
\r\n \r\n
\r\n
Table type is required.
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
{{ fCoreState.controls.stateName.value }}
\r\n \r\n
\r\n
State is required.
\r\n
\r\n
\r\n\r\n
\r\n \r\n
{{ fCoreCompany.controls.companyName.value }}
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
Company is required.
\r\n
\r\n
\r\n\r\n
\r\n \r\n
{{ fCoreAssessor.controls.assessorName.value || 'None' }}
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n \r\n
{{ fCore.controls.tableRetiredTaxYear.value }}
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
Floor Values
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
${{ floorControl.value }}
\r\n
\r\n
\r\n $\r\n \r\n
\r\n
\r\n
Must be grater than 0.
\r\n
Value is too big.
\r\n
Invalid value.
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
Factors
\r\n
\r\n
\r\n Add Age\r\n
\r\n
\r\n Add Year\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
{{ yearControl.value }}
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n Age {{ ageIndex + 1 }}\r\n \r\n
\r\n
\r\n
{{ factorControl.value }}%
\r\n
\r\n
\r\n \r\n %\r\n
\r\n
\r\n
Must be grater than 0.
\r\n
\r\n
\r\n
\r\n
\r\n\r\n \r\n
\r\n
Tax years are required and cannot be left empty.
\r\n
Tax year values must be unique and cannot be duplicated.
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy, ChangeDetectorRef } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { FactorTableRepository } from '../../Repositories';\r\nimport { StateService } from '../../../Common/States/States.Service';\r\nimport { StateSummary } from '../../../Common/States/state.model';\r\nimport { AssessorService } from '../../../Assessor-Collector/Assessor/assessor-service';\r\nimport { Constants } from '../../../constants.new';\r\nimport { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormArray, UntypedFormControl } from '@angular/forms';\r\nimport { WsUniqueYearValidator } from './validators';\r\nimport { Subscription, Observable, lastValueFrom } from 'rxjs';\r\nimport { CompanyRepository } from '../../Repositories';\r\nimport { mergeMap, map } from 'rxjs/operators';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { YearPickerMixin } from '../../../UI-Lib/Mixins';\r\nimport { BaseExpandableComponent } from '../../../UI-Lib/Expandable-Component/baseExpandableComponent';\r\n\r\nexport interface FactorTableDetailsParams {\r\n factorTableId?: number;\r\n editMode: boolean;\r\n companies?: Core.CompanyDTO[];\r\n newFactorTableParams?: {\r\n source: GridSourceOptionEnum;\r\n stateId: number;\r\n company: Core.CompanyInfoModel;\r\n isCopyFrom: boolean;\r\n }\r\n}\r\n\r\nexport interface FactorTableDetailsResult {\r\n hasChanges: boolean;\r\n}\r\n\r\nexport enum GridSourceOptionEnum {\r\n System,\r\n Company\r\n}\r\n\r\nenum DisplayMode {\r\n Add = 0,\r\n Edit = 1,\r\n View = 2,\r\n CopyFrom = 3\r\n}\r\n\r\nenum PanelView {\r\n Details = 0,\r\n List = 1\r\n}\r\n\r\n@Component({\r\n selector: 'factor-table-details',\r\n templateUrl: './factorTableDetails.component.html',\r\n styleUrls: ['./factorTableDetails.component.scss']\r\n})\r\nexport class FactorTableDetailsComponent extends YearPickerMixin(BaseExpandableComponent) implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _constants: Constants,\r\n private readonly _stateService: StateService,\r\n private readonly _assessorService: AssessorService,\r\n private readonly _factorTableRepository: FactorTableRepository,\r\n private readonly _formBuilder: UntypedFormBuilder,\r\n private readonly _companyRepository: CompanyRepository,\r\n private readonly _cdRef: ChangeDetectorRef\r\n ) {\r\n super();\r\n }\r\n\r\n params: FactorTableDetailsParams;\r\n result: FactorTableDetailsResult = {\r\n hasChanges: false\r\n };\r\n\r\n selectedView: PanelView = PanelView.Details;\r\n clearAssessorEnabled = true;\r\n form: UntypedFormGroup;\r\n source: GridSourceOptionEnum;\r\n GridSourceOptionEnum = GridSourceOptionEnum;\r\n\r\n states: StateSummary[] = [];\r\n\r\n companyFilter: string = '';\r\n companiesLoading: boolean = false;\r\n selectedCompany: Core.CompanyInfoModel;\r\n selectedCompanyId: UntypedFormControl = new UntypedFormControl(null);\r\n canEditCompany: boolean = false;\r\n companyEditing: boolean = false;\r\n\r\n companiesDataSource$: Observable = Observable\r\n .create((observer: any) => { observer.next(this.companyFilter); })\r\n .pipe(mergeMap((token: string) => this._filterCompanies(token)))\r\n .pipe(map((result: Compliance.QueryResultModel) => result.data));\r\n\r\n assessors: Core.AssessorModel[] = [];\r\n\r\n factorTableTypes: Compliance.NameValuePair[] = this._constants.FactorTableTypes;\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n protected readonly PanelView = PanelView;\r\n private _availableCompanies: Core.CompanyInfoModel[] = [];\r\n private _yearControlValueChangedSub: Subscription;\r\n private _factorTableDetailModel: Compliance.FactorTableModel = {};\r\n private _displayMode: DisplayMode = DisplayMode.View;\r\n\r\n // reactive form and helper methods for accessing parts of that form\r\n get f() { return this.form; }\r\n get fCore() { return (this.form.get('coreGroup') as UntypedFormGroup); }\r\n get fCoreState() { return (this.form.get('coreGroup.stateGroup') as UntypedFormGroup); }\r\n get fCoreCompany() { return (this.form.get('coreGroup.companyGroup') as UntypedFormGroup); }\r\n get fCoreAssessor() { return (this.form.get('coreGroup.assessorGroup') as UntypedFormGroup); }\r\n get fYears() { return (this.form.get('years') as UntypedFormArray); }\r\n get fAges() { return (this.form.get('ages') as UntypedFormArray); }\r\n get fFloors() { return (this.form.get('floors') as UntypedFormArray); }\r\n\r\n // reactive form helper methods for accession validation related to a collection of form controls\r\n get fYearsHaveValidationErrorsRequired() { return !!this.fYears.controls.find(i => i.errors && i.errors.required); }\r\n get fYearsHaveValidationErrorsUnique() { return !!this.fYears.controls.find(i => i.errors && i.errors.wsUniqueYear); }\r\n\r\n get displayMode(): DisplayMode{\r\n return this._displayMode;\r\n }\r\n\r\n set displayMode(value: DisplayMode){\r\n this._displayMode = value;\r\n switch (this._displayMode) {\r\n case DisplayMode.Edit:\r\n this.fCore.get('tableType').disable();\r\n if (this._factorTableDetailModel !== null && !this._factorTableDetailModel.usedInReturn) {\r\n this.fCoreAssessor.get('assessorName').enable();\r\n this.clearAssessorEnabled = true;\r\n } else {\r\n this.fCoreAssessor.get('assessorName').disable();\r\n this.clearAssessorEnabled = false;\r\n }\r\n break;\r\n case DisplayMode.View:\r\n this.fCore.get('tableType').disable();\r\n this.fCoreAssessor.get('assessorName').disable();\r\n this.clearAssessorEnabled = false;\r\n break;\r\n case DisplayMode.Add:\r\n this.fCoreAssessor.get('assessorName').enable();\r\n this.clearAssessorEnabled = true;\r\n break;\r\n case DisplayMode.CopyFrom:\r\n this.fCore.get('tableType').disable();\r\n this.fCoreAssessor.get('assessorName').enable();\r\n this.clearAssessorEnabled = true;\r\n break;\r\n }\r\n }\r\n\r\n get DisplayModeEnum(){\r\n return DisplayMode;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n if (!this.params.factorTableId) {\r\n if (!this.params.newFactorTableParams) {\r\n return Promise.reject('Missing parameters for adding new factor table.');\r\n }\r\n if (!(this.params.newFactorTableParams.stateId || this.params.newFactorTableParams.company)) {\r\n return Promise.reject('Missing state or company parameter for adding new factor table.');\r\n }\r\n }\r\n\r\n this.source = (this.params.newFactorTableParams) ? this.params.newFactorTableParams.source : null;\r\n\r\n this.form = this._formBuilder.group({\r\n coreGroup: this._formBuilder.group({\r\n tableName: [null, [Validators.required, Validators.maxLength(100)]],\r\n tableLife: [null, Validators.required],\r\n tableType: [Compliance.FactorTableTypeEnum.Depreciation, [Validators.required]],\r\n tableRetiredTaxYear: [null],\r\n stateGroup: this._formBuilder.group({\r\n state: null,\r\n stateName: [{ value: null, disabled: true }, [Validators.required]]\r\n }),\r\n companyGroup: this._formBuilder.group({\r\n company: null,\r\n companyName: [{ value: null, disabled: true }, [Validators.required]]\r\n }),\r\n assessorGroup: this._formBuilder.group({\r\n assessor: null,\r\n assessorName: null\r\n })\r\n }),\r\n years: this._formBuilder.array([]),\r\n ages: this._formBuilder.array([]),\r\n floors: this._formBuilder.array([])\r\n });\r\n\r\n this._yearControlValueChangedSub = this.fYears.valueChanges.subscribe(() => {\r\n this._refreshYearControls();\r\n });\r\n\r\n this.form.get('coreGroup.companyGroup.companyName').valueChanges.subscribe((companyFilter) => {\r\n this.companyFilter = companyFilter;\r\n });\r\n\r\n const busyMsgInitializing = 'initializing';\r\n this.busyIndicatorMessageManager.add('Initializing', busyMsgInitializing);\r\n\r\n try {\r\n const tableParams = this.params.newFactorTableParams;\r\n\r\n if (this.params.factorTableId) {\r\n this._factorTableDetailModel = await lastValueFrom(this._factorTableRepository.get(this.params.factorTableId));\r\n\r\n if (this.params.newFactorTableParams && this.params.newFactorTableParams.isCopyFrom) {\r\n this.displayMode = DisplayMode.CopyFrom;\r\n\r\n this._factorTableDetailModel.factorTableId = 0;\r\n this._factorTableDetailModel.name = null;\r\n this._factorTableDetailModel.life = null;\r\n this._factorTableDetailModel.changedBy = undefined;\r\n this._factorTableDetailModel.changeDate = undefined;\r\n this._factorTableDetailModel.hasAttachments = false;\r\n this._factorTableDetailModel.hasComments = false;\r\n this._factorTableDetailModel.rowVersion = [];\r\n this._factorTableDetailModel.usedInReturn = false;\r\n this._factorTableDetailModel.transferId = null;\r\n } else {\r\n this.displayMode = this.params.editMode ? DisplayMode.Edit : DisplayMode.View;\r\n }\r\n\r\n } else {\r\n this._factorTableDetailModel = {\r\n factorTableId: 0,\r\n stateId: tableParams.stateId,\r\n assessorId: null,\r\n companyId: (tableParams && tableParams.company) ? tableParams.company.companyId : null,\r\n name: null,\r\n tableType: Compliance.FactorTableTypeEnum.Depreciation,\r\n life: null,\r\n taxYears: [],\r\n taxYearValues: [],\r\n hasAttachments: false,\r\n hasComments: false,\r\n rowVersion: [],\r\n usedInReturn: false,\r\n taxYearFloors: [],\r\n retiredTaxYear: null\r\n };\r\n\r\n this.displayMode = DisplayMode.Add;\r\n }\r\n\r\n this.selectedCompany = tableParams && tableParams.company;\r\n this.canEditCompany = tableParams && tableParams.isCopyFrom && !!tableParams.company;\r\n\r\n if (this.canEditCompany) {\r\n this.editCompany();\r\n }\r\n\r\n if (this.selectedCompany) {\r\n this.selectedCompanyId.setValue(this.selectedCompany.companyId);\r\n }\r\n\r\n // load states\r\n this.states = await this._stateService.getSummary();\r\n const stateId = this.states.find(i => i.stateID === this._factorTableDetailModel.stateId).stateID;\r\n\r\n // load assessors\r\n this.assessors = await this._assessorService.getByStateId(stateId);\r\n\r\n // setup form\r\n this._updateFormFromModel(this._factorTableDetailModel);\r\n\r\n // default first year and age if creating a new factor table\r\n if (this.displayMode === DisplayMode.Add) {\r\n this.addYear();\r\n this.addAge();\r\n }\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgInitializing);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._yearControlValueChangedSub && this._yearControlValueChangedSub.unsubscribe();\r\n }\r\n\r\n onAssessorSelected(match: TypeaheadMatch): void {\r\n const assessor = match.item as Core.AssessorModel;\r\n this.fCoreAssessor.patchValue({\r\n 'assessor': assessor,\r\n 'assessorName': assessor.name\r\n });\r\n }\r\n\r\n onAssessorClear(): void {\r\n this.fCoreAssessor.patchValue({\r\n 'assessor': null,\r\n 'assessorName': null\r\n });\r\n }\r\n\r\n onAssessorBlur(): void {\r\n const assessor: Core.AssessorModel = this.fCoreAssessor.get('assessor').value;\r\n this.fCoreAssessor.patchValue({\r\n 'assessorName': assessor && assessor.name\r\n });\r\n }\r\n\r\n addYear(year?: number): void {\r\n // get current year and default that as the year that will be added\r\n year = year || (new Date()).getFullYear();\r\n\r\n this.fYears.insert(0, this._createYearControl(year));\r\n\r\n // update ages and floors with new year value\r\n this.fAges.controls.forEach(x => (x.get('factors') as UntypedFormArray).insert(0, this._createFactorControl(null)));\r\n this.fFloors.controls.forEach(x => (x.get('floors') as UntypedFormArray).insert(0, this._createFloorControl(null)));\r\n\r\n // refresh custom validators\r\n this._refreshYearControls();\r\n this._cdRef.detectChanges();\r\n }\r\n\r\n removeYear(yearIndex: number): void {\r\n this.fYears.removeAt(yearIndex);\r\n\r\n // update ages and floors by removing year value\r\n this.fAges.controls.forEach(x => (x.get('factors') as UntypedFormArray).removeAt(yearIndex));\r\n this.fFloors.controls.forEach(x => (x.get('floors') as UntypedFormArray).removeAt(yearIndex));\r\n\r\n // refresh custom validators\r\n this._refreshYearControls();\r\n }\r\n\r\n addAge(factors: number[] = []): void {\r\n // array of factor controls for the new age\r\n const factorArray = this._formBuilder.array([]);\r\n\r\n // populate that array for each available year\r\n this.fYears.controls.forEach((x, i) => {\r\n factorArray.push(this._createFactorControl(factors[i] || (factors[i] === 0 ? 0 : null)));\r\n });\r\n\r\n // assign the factor controls to the age group\r\n const ageGroup = this._formBuilder.group({\r\n ageIndex: this.fAges.length,\r\n factors: factorArray\r\n });\r\n\r\n // add age group to ages control array\r\n this.fAges.push(ageGroup);\r\n }\r\n\r\n addFloors(floors: number[] = []): void {\r\n // reverse the floors to align with the years\r\n const floorsByYear = [...floors].reverse();\r\n\r\n // array of factor controls for the new age\r\n const floorArray = this._formBuilder.array([]);\r\n\r\n // populate that array for each available year\r\n this.fYears.controls.forEach((x, i) => {\r\n floorArray.push(this._createFloorControl(floorsByYear[i] || null));\r\n });\r\n\r\n // assign the factor controls to the age group\r\n const floorGroup = this._formBuilder.group({\r\n floorIndex: this.fFloors.length,\r\n floors: floorArray\r\n });\r\n\r\n // add age group to ages control array\r\n this.fFloors.push(floorGroup);\r\n }\r\n\r\n removeAge(ageIndex: number): void {\r\n this.fAges.removeAt(ageIndex);\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n onCompanySelected(typeAheadMatch: TypeaheadMatch): void {\r\n const company = typeAheadMatch.item as Core.CompanyInfoModel;\r\n this.selectedCompanyId.setValue(company.companyId);\r\n this.fCoreCompany.patchValue({\r\n 'company': company,\r\n 'companyName': company.companyName\r\n });\r\n }\r\n\r\n onCompanyBlur(): void {\r\n if (!this.companyFilter || this.companyFilter.trim() === '') {\r\n this.selectedCompanyId.setValue(null);\r\n this.fCoreCompany.patchValue({\r\n 'company': null,\r\n 'companyName': null\r\n });\r\n } else {\r\n if (!this._availableCompanies.find(x => x.companyName === this.companyFilter)) {\r\n this.selectedCompanyId.setValue(null);\r\n this.fCoreCompany.patchValue({\r\n 'company': null,\r\n 'companyName': null\r\n });\r\n }\r\n }\r\n }\r\n\r\n onCompanyLoadingChange(isLoading: boolean): void {\r\n this.companiesLoading = isLoading;\r\n }\r\n\r\n setViewSelection(selectedView: PanelView): void {\r\n this.selectedView = selectedView;\r\n }\r\n\r\n async save(): Promise {\r\n this._updateModelFromForm(this._factorTableDetailModel);\r\n\r\n const busyMsgSaving = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving Changes', busyMsgSaving);\r\n\r\n const promise = this.displayMode === DisplayMode.Add || this.displayMode === DisplayMode.CopyFrom\r\n ? lastValueFrom(this._factorTableRepository.create(this._factorTableDetailModel))\r\n : lastValueFrom(this._factorTableRepository.update(this._factorTableDetailModel));\r\n\r\n try {\r\n await promise.then((model: Compliance.FactorTableModel) => {\r\n this.result.hasChanges = true;\r\n\r\n // close modal window\r\n this._bsModalRef.hide();\r\n });\r\n }\r\n finally{\r\n this.busyIndicatorMessageManager.remove(busyMsgSaving);\r\n }\r\n }\r\n\r\n private _filterCompanies(searchValue: string): Observable> {\r\n const searchModel = {\r\n columnFilters: [{\r\n filterProperty: Core.CompanyInfoPropertyEnum.CompanyName,\r\n filterValues: [\r\n {\r\n filterType: Core.FilterTypeEnum.Contains,\r\n filterValue: searchValue\r\n }\r\n ]\r\n }],\r\n topLevelOnly: true,\r\n preparePPReturnsOnly: true\r\n } as Core.CompanyInfoSearchModel;\r\n\r\n return this._companyRepository.searchCompanyInfo(searchModel).pipe(map((result: Compliance.QueryResultModel) => {\r\n this._availableCompanies = result.data;\r\n return result;\r\n }));\r\n }\r\n\r\n private _updateFormFromModel(model: Compliance.FactorTableModel): void {\r\n const state = this.states.find(i => i.stateID === model.stateId);\r\n const assessor = this.assessors.find(i => i.assessorID === model.assessorId) || null;\r\n\r\n (this.form.get('years') as UntypedFormArray).clear();\r\n (this.form.get('ages') as UntypedFormArray).clear();\r\n (this.form.get('floors') as UntypedFormArray).clear();\r\n\r\n this.form.patchValue({\r\n coreGroup: {\r\n tableName: model.name,\r\n tableLife: model.life,\r\n tableType: model.tableType,\r\n tableRetiredTaxYear: model.retiredTaxYear,\r\n stateGroup: {\r\n state: state || null,\r\n stateName: (state && state.fullName) ? state.fullName : null\r\n },\r\n companyGroup: {\r\n company: this.selectedCompany || null,\r\n companyName: (this.selectedCompany && this.selectedCompany.companyName) ? this.selectedCompany.companyName : null\r\n },\r\n assessorGroup: {\r\n assessor: assessor,\r\n assessorName: assessor && assessor.name\r\n }\r\n }\r\n });\r\n\r\n // populate years (before populating ages)\r\n model.taxYears.forEach(x => this.addYear(x));\r\n\r\n // populate ages\r\n // get the longest set of values for any year in order to figure out the max age\r\n // max age determines how many rows the factor table will have\r\n let maxAge = 0;\r\n\r\n const taxYearValues = [...model.taxYearValues].reverse();\r\n taxYearValues.forEach(i => maxAge = i.length > maxAge ? i.length : maxAge);\r\n\r\n for (let i = 0; i < maxAge; i++) {\r\n // for the age that is being added, get the list of the factors for each year\r\n const factors = taxYearValues.map(x => x[i]).filter(x => x !== null);\r\n\r\n // if the table is of type depreciation, the numbers represent percentages; convert decimal values to whole numbers\r\n // using toFixed: 0.55 * 100 = 55.00000000000001 ???\r\n if (model.tableType === Compliance.FactorTableTypeEnum.Depreciation) {\r\n // factors.forEach((x, i) => factors[i] = parseInt((x * 100).toFixed(2)));\r\n factors.forEach((x, i) => factors[i] = Math.round(x * 10000000) / 100000);\r\n }\r\n\r\n this.addAge(factors);\r\n }\r\n\r\n // it is possible that we do not have any factor values yet, so let's create an empty Age 1 to not break the layout\r\n if (this.displayMode !== DisplayMode.Add && maxAge === 0){\r\n const factors = model.taxYears.map(() => null);\r\n this.addAge(factors);\r\n }\r\n\r\n this.addFloors(model.taxYearFloors);\r\n }\r\n\r\n private _updateModelFromForm(model: Compliance.FactorTableModel): void {\r\n const formValues = this.form.getRawValue();\r\n const coreValues = formValues.coreGroup;\r\n\r\n model.name = coreValues.tableName;\r\n model.life = coreValues.tableLife;\r\n model.tableType = coreValues.tableType;\r\n model.retiredTaxYear = coreValues.tableRetiredTaxYear;\r\n\r\n const assessor: Core.AssessorModel = this.fCoreAssessor.get('assessor').value;\r\n model.assessorId = (assessor && assessor.assessorID) || null;\r\n\r\n const company: Core.CompanyInfoModel = this.fCoreCompany.get('company').value;\r\n model.companyId = (company && company.companyId) || null;\r\n\r\n model.taxYears = [...formValues.years].reverse();\r\n\r\n // for each year\r\n // look at all the ages in the grid\r\n // and for each age get the factors matching the year index\r\n // filter out factors that are not populated\r\n model.taxYearValues = formValues.years.map((x, i) => formValues.ages.map(y => y.factors[i]).filter(z => z !== null)).reverse();\r\n // model.taxYearValues = this.fYears.controls.map((x, i) => this.fAges.controls.map(y => (y.get('factors') as FormArray).controls[i].value).filter(z => z !== null));\r\n\r\n // if the table is of type depreciation, the numbers represent percentages; convert whole numbers to decimal values\r\n if (model.tableType === Compliance.FactorTableTypeEnum.Depreciation) {\r\n model.taxYearValues.forEach(x => x.forEach((y, i) => x[i] = Math.round(y * 100000) / 10000000));\r\n }\r\n\r\n model.taxYearFloors = [...formValues.floors[0].floors].reverse();\r\n }\r\n\r\n private _createYearControl(year: number): UntypedFormControl {\r\n return this._formBuilder.control(year, [Validators.required, WsUniqueYearValidator(this.fYears.controls)]);\r\n }\r\n\r\n private _createFactorControl(factor: number): UntypedFormControl {\r\n return this._formBuilder.control(factor, [Validators.min(0)]);\r\n }\r\n\r\n private _createFloorControl(floor: number): UntypedFormControl {\r\n return this._formBuilder.control(floor, [Validators.min(0), Validators.max(1000000), Validators.pattern('-?\\\\d+(\\\\.\\\\d{1,2})?')]);\r\n }\r\n\r\n private _refreshYearControls(): void {\r\n this.fYears.controls.forEach(x => x.updateValueAndValidity({ onlySelf: true, emitEvent: false }));\r\n this.fYears.updateValueAndValidity({ onlySelf: true, emitEvent: false });\r\n }\r\n\r\n editCompany() {\r\n this.companyEditing = true;\r\n this.fCoreCompany.get('companyName').enable();\r\n }\r\n\r\n saveCompany() {\r\n this.companyEditing = false;\r\n if (this._factorTableDetailModel.companyId) {\r\n this.fCoreCompany.get('companyName').disable();\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { DragulaService } from 'ng2-dragula';\r\nimport { Observable, BehaviorSubject, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\nexport interface ReturnAssetDroppedEvent {\r\n element: Element;\r\n draggedAssetIds: number[];\r\n};\r\n\r\n@Injectable()\r\nexport class ReturnAssetDragAndDropService {\r\n constructor(private readonly _dragulaService: DragulaService) { }\r\n\r\n private _getAssetIdsFn: () => Promise;\r\n private _getAssetsFn: () => Promise;\r\n\r\n private _activeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _draggingSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _draggingOverSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _droppedSubject: Subject = new Subject();\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n readonly BAG_NAME = 'RETURN_ASSET_DRAG_AND_DROP';\r\n readonly CONTAINER_TYPE_SOURCE = 'RETURN_ASSET_DRAG_AND_DROP_CONTAINER_TYPE_SOURCE';\r\n readonly CONTAINER_TYPE_TARGET = 'RETURN_ASSET_DRAG_AND_DROP_CONTAINER_TYPE_TARGET';\r\n\r\n active$: Observable = this._activeSubject.asObservable();\r\n\r\n /**\r\n * An observable that notifies the container being dragged.\r\n */\r\n dragging$: Observable = this._draggingSubject.asObservable();\r\n\r\n /**\r\n * An observable that notifies the container that the mouse is being dragged over.\r\n */\r\n draggingOver$: Observable = this._draggingOverSubject.asObservable();\r\n\r\n /**\r\n * An observable that notifies the container an items gets dropped in.\r\n */\r\n dropped$: Observable = this._droppedSubject.asObservable();\r\n\r\n /**\r\n * Initializes subscriptions to the dragula service and notifies about drag/drop events.\r\n * Because the drag targets are in a grid with an infinity scroll model, the service does not keep track of all available drag targets.\r\n * It takes in a function that returns a list of all selected IDs for the drag targets. This list is made available to the drop event.\r\n */\r\n start(getAssetIdsFn: () => Promise, getAssetsFn: () => Promise): void {\r\n if (this.isStarted()) {\r\n console.warn('Return Asset drag-and-drop service is already listening for events.');\r\n return;\r\n }\r\n\r\n this._getAssetIdsFn = getAssetIdsFn;\r\n this._getAssetsFn = getAssetsFn;\r\n\r\n this._dragulaService.createGroup(this.BAG_NAME, this.getDragulaOptions());\r\n\r\n this._dragulaService.drag(this.BAG_NAME).pipe(takeUntil(this._destroy$)).subscribe(() => this._draggingSubject.next(true));\r\n\r\n this._dragulaService.dragend(this.BAG_NAME).pipe(takeUntil(this._destroy$)).subscribe(() => this._draggingSubject.next(false));\r\n\r\n this._dragulaService.over(this.BAG_NAME).pipe(takeUntil(this._destroy$)).subscribe(value => this._draggingOverSubject.next(value.source));\r\n\r\n this._dragulaService.out(this.BAG_NAME).pipe(takeUntil(this._destroy$)).subscribe(() => this._draggingOverSubject.next(null));\r\n\r\n // we need to undo the drop event as we don't want the source element to actually move into the target container\r\n // there is currently no support from the library to do that\r\n // it is currently being handled via stylesheets by not displaying the dropped elements\r\n // TODO: cancel drop event or if a parameter gets exposed in the future to not \"actually\" drop the element use that\r\n this._dragulaService.drop(this.BAG_NAME).pipe(takeUntil(this._destroy$)).subscribe(value => {\r\n // fetch the asset IDs in order to make them available to the drop event\r\n this._getAssetIdsFn().then((draggedAssetIds) => {\r\n const droppedEvent: ReturnAssetDroppedEvent = {\r\n element: value.target,\r\n draggedAssetIds: draggedAssetIds\r\n };\r\n this._droppedSubject.next(droppedEvent);\r\n }, () => {});\r\n });\r\n\r\n this._activeSubject.next(true);\r\n }\r\n\r\n /**\r\n * Disposes subscriptions to the dragula service.\r\n */\r\n stop(): void {\r\n this._activeSubject.next(false);\r\n\r\n this._destroy$.next();\r\n\r\n this._draggingSubject.next(false);\r\n this._draggingOverSubject.next(null);\r\n\r\n this._getAssetIdsFn = null;\r\n\r\n const isStarted = this._dragulaService.find(this.BAG_NAME);\r\n if (isStarted) {\r\n this._dragulaService.destroy(this.BAG_NAME);\r\n }\r\n }\r\n\r\n isStarted(): boolean {\r\n return !!this._dragulaService.find(this.BAG_NAME);\r\n }\r\n\r\n /**\r\n * Gets the assets associated with the dropped IDs\r\n */\r\n async getSelectedAssets(): Promise {\r\n return await this._getAssetsFn();\r\n }\r\n\r\n getDragulaOptions(): any {\r\n return {\r\n copy: true,\r\n copyItem: (item) => ({ ...item }),\r\n revertOnSpill: true,\r\n removeOnSpill: false,\r\n accepts: (el: Element, target: Element, source: Element, sibling: Element) => target.getAttribute('dragula-container-type') !== this.CONTAINER_TYPE_SOURCE,\r\n moves: (el: Element, target: Element, source: Element, sibling: Element) => target.getAttribute('dragula-container-type') === this.CONTAINER_TYPE_SOURCE\r\n };\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ReturnAssetDragAndDropService } from './returnAssetDragAndDrop.service';\r\nimport { AgGridMultiSelectTracker } from '../../../../AgGrid/MultiSelectTracker';\r\nimport { Subject } from 'rxjs';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\nexport interface ICellRendererParamsForReturnAssetDragAndDropSource extends ICellRendererParams {\r\n tracker: AgGridMultiSelectTracker\r\n}\r\n\r\n@Component({\r\n selector: 'return-asset-drag-and-drop-source',\r\n template: `\r\n \r\n \r\n \r\n `,\r\n styleUrls: ['./returnAssetDragAndDropSource.component.scss']\r\n})\r\nexport class ReturnAssetDragAndDropSourceComponent implements ICellRendererAngularComp {\r\n constructor(\r\n private readonly _returnAssetDragAndDropService: ReturnAssetDragAndDropService,\r\n private readonly _returnService: ReturnService) {\r\n this.dragulaContainerType = this._returnAssetDragAndDropService.CONTAINER_TYPE_SOURCE;\r\n this.dragulaBagName = this._returnAssetDragAndDropService.BAG_NAME;\r\n }\r\n\r\n private _tracker: AgGridMultiSelectTracker;\r\n private _rowId: number;\r\n private _destroy$: Subject = new Subject();\r\n\r\n params: ICellRendererParamsForReturnAssetDragAndDropSource;\r\n\r\n isServiceActive: boolean;\r\n isReadOnly: boolean;\r\n canEdit: boolean;\r\n dragulaContainerType: string;\r\n dragulaBagName: string;\r\n\r\n get isRowSelected(): boolean {\r\n return this._tracker.isRowSelected(this._rowId);\r\n }\r\n\r\n agInit(params: ICellRendererParamsForReturnAssetDragAndDropSource): void {\r\n this.params = params;\r\n this._tracker = params.tracker;\r\n this._rowId = params.value;\r\n\r\n this.canEdit = this._returnService.canEditCompany;\r\n\r\n this._returnAssetDragAndDropService.active$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.isServiceActive = x);\r\n\r\n this._returnService.isReturnInReadOnlyMode$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.isReadOnly = x);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../../AgGrid';\r\nimport { ReturnAssetsService } from '../returnAssets.service';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { ReturnAssetRepository } from '../../../../Repositories';\r\nimport ReturnAssetPropertyEnum = Compliance.ReturnAssetPropertyEnum;\r\n\r\nexport class ReturnAssetListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n gridApi: GridApi,\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _returnAssetRepository: ReturnAssetRepository,\r\n private readonly _totalsUpdateCallback: (totals: Compliance.ReturnAssetSearchTotalsModel, selectedTotals?: boolean, isLoading?: boolean) => void\r\n ) {\r\n super(gridApi);\r\n }\r\n\r\n lastFetchedTotals: Compliance.ReturnAssetSearchTotalsModel;\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'assetNumber', value: Compliance.ReturnAssetPropertyEnum.AssetNumber },\r\n { name: 'description', value: Compliance.ReturnAssetPropertyEnum.Description },\r\n { name: 'glAccount', value: Compliance.ReturnAssetPropertyEnum.GLAccount },\r\n { name: 'glAccountNumber', value: Compliance.ReturnAssetPropertyEnum.GLAccountNumber },\r\n { name: 'classificationName', value: Compliance.ReturnAssetPropertyEnum.ClassificationName },\r\n { name: 'parcelAccountNumber', value: Compliance.ReturnAssetPropertyEnum.ParcelAccountNumber },\r\n { name: 'parcelDescription', value: Compliance.ReturnAssetPropertyEnum.ParcelDescription },\r\n { name: 'assessorAbbr', value: Compliance.ReturnAssetPropertyEnum.AssessorAbbr },\r\n { name: 'acqDate', value: Compliance.ReturnAssetPropertyEnum.AcqDate },\r\n { name: 'age', value: Compliance.ReturnAssetPropertyEnum.Age },\r\n { name: 'priorAcqDate', value: Compliance.ReturnAssetPropertyEnum.PriorAcqDate },\r\n { name: 'cost', value: Compliance.ReturnAssetPropertyEnum.Cost },\r\n { name: 'costChange', value: Compliance.ReturnAssetPropertyEnum.CostChange },\r\n { name: 'priorCost', value: Compliance.ReturnAssetPropertyEnum.PriorCost },\r\n { name: 'scheduleName', value: Compliance.ReturnAssetPropertyEnum.Schedule },\r\n { name: 'site', value: Compliance.ReturnAssetPropertyEnum.Site },\r\n { name: 'siteName', value: Compliance.ReturnAssetPropertyEnum.SiteName },\r\n { name: 'siteProperty', value: Compliance.ReturnAssetPropertyEnum.SiteProperty },\r\n { name: 'parcelSiteProperty', value: Compliance.ReturnAssetPropertyEnum.ParcelSiteProperty },\r\n { name: 'parcelSiteName', value: Compliance.ReturnAssetPropertyEnum.ParcelSiteName },\r\n { name: 'priorScheduleName', value: Compliance.ReturnAssetPropertyEnum.PriorSchedule },\r\n { name: 'depreciationFactorTableName', value: Compliance.ReturnAssetPropertyEnum.DepreciationFactorTableName },\r\n { name: 'priorDepreciationFactorTableName', value: Compliance.ReturnAssetPropertyEnum.PriorDepreciationFactorTableName},\r\n { name: 'factor', value: Compliance.ReturnAssetPropertyEnum.Factor },\r\n { name: 'reportedValue', value: Compliance.ReturnAssetPropertyEnum.DepreciationCost },\r\n { name: 'acqYear', value: Compliance.ReturnAssetPropertyEnum.AcqYear },\r\n { name: 'linkedParcelAccountNumber', value: Compliance.ReturnAssetPropertyEnum.LinkedParcelAccountNumber },\r\n { name: 'linkedParcelDescription', value: Compliance.ReturnAssetPropertyEnum.LinkedParcelDescription },\r\n { name: 'linkedParcelAssessorAbbr', value: Compliance.ReturnAssetPropertyEnum.LinkedParcelAssessorAbbr },\r\n { name: 'acqYear', value: Compliance.ReturnAssetPropertyEnum.AcqYear },\r\n { name: 'acqYear', value: Compliance.ReturnAssetPropertyEnum.AcqYear },\r\n { name: 't1', value: Compliance.ReturnAssetPropertyEnum.T1 },\r\n { name: 't2', value: Compliance.ReturnAssetPropertyEnum.T2 },\r\n { name: 't3', value: Compliance.ReturnAssetPropertyEnum.T3 },\r\n { name: 't4', value: Compliance.ReturnAssetPropertyEnum.T4 },\r\n { name: 't5', value: Compliance.ReturnAssetPropertyEnum.T5 },\r\n { name: 't6', value: Compliance.ReturnAssetPropertyEnum.T6 },\r\n { name: 't7', value: Compliance.ReturnAssetPropertyEnum.T7 },\r\n { name: 't8', value: Compliance.ReturnAssetPropertyEnum.T8 },\r\n { name: 't9', value: Compliance.ReturnAssetPropertyEnum.T9 },\r\n { name: 't10', value: Compliance.ReturnAssetPropertyEnum.T10 },\r\n { name: 't11', value: Compliance.ReturnAssetPropertyEnum.T11 },\r\n { name: 't12', value: Compliance.ReturnAssetPropertyEnum.T12 },\r\n { name: 't13', value: Compliance.ReturnAssetPropertyEnum.T13 },\r\n { name: 't14', value: Compliance.ReturnAssetPropertyEnum.T14 },\r\n { name: 't15', value: Compliance.ReturnAssetPropertyEnum.T15 },\r\n { name: 't16', value: Compliance.ReturnAssetPropertyEnum.T16 },\r\n { name: 't17', value: Compliance.ReturnAssetPropertyEnum.T17 },\r\n { name: 't18', value: Compliance.ReturnAssetPropertyEnum.T18 },\r\n { name: 't19', value: Compliance.ReturnAssetPropertyEnum.T19 },\r\n { name: 't20', value: Compliance.ReturnAssetPropertyEnum.T20 },\r\n { name: 't20', value: Compliance.ReturnAssetPropertyEnum.T20 },\r\n { name: 't21', value: Compliance.ReturnAssetPropertyEnum.T21 },\r\n { name: 't22', value: Compliance.ReturnAssetPropertyEnum.T22 },\r\n { name: 't23', value: Compliance.ReturnAssetPropertyEnum.T23 },\r\n { name: 't24', value: Compliance.ReturnAssetPropertyEnum.T24 },\r\n { name: 't25', value: Compliance.ReturnAssetPropertyEnum.T25 },\r\n { name: 't26', value: Compliance.ReturnAssetPropertyEnum.T26 },\r\n { name: 't27', value: Compliance.ReturnAssetPropertyEnum.T27 },\r\n { name: 't28', value: Compliance.ReturnAssetPropertyEnum.T28 },\r\n { name: 't29', value: Compliance.ReturnAssetPropertyEnum.T29 },\r\n { name: 't30', value: Compliance.ReturnAssetPropertyEnum.T30 },\r\n { name: 'n1', value: Compliance.ReturnAssetPropertyEnum.N1 },\r\n { name: 'n2', value: Compliance.ReturnAssetPropertyEnum.N2 },\r\n { name: 'n3', value: Compliance.ReturnAssetPropertyEnum.N3 },\r\n { name: 'n4', value: Compliance.ReturnAssetPropertyEnum.N4 },\r\n { name: 'n5', value: Compliance.ReturnAssetPropertyEnum.N5 },\r\n { name: 'n6', value: Compliance.ReturnAssetPropertyEnum.N6 },\r\n { name: 'n7', value: Compliance.ReturnAssetPropertyEnum.N7 },\r\n { name: 'n8', value: Compliance.ReturnAssetPropertyEnum.N8 },\r\n { name: 'n9', value: Compliance.ReturnAssetPropertyEnum.N9 },\r\n { name: 'n10', value: Compliance.ReturnAssetPropertyEnum.N10 },\r\n { name: 'd1', value: Compliance.ReturnAssetPropertyEnum.D1 },\r\n { name: 'd2', value: Compliance.ReturnAssetPropertyEnum.D2 },\r\n { name: 'd3', value: Compliance.ReturnAssetPropertyEnum.D3 },\r\n { name: 'd4', value: Compliance.ReturnAssetPropertyEnum.D4 },\r\n { name: 'd5', value: Compliance.ReturnAssetPropertyEnum.D5 },\r\n { name: 'd6', value: Compliance.ReturnAssetPropertyEnum.D6 },\r\n { name: 'd7', value: Compliance.ReturnAssetPropertyEnum.D7 },\r\n { name: 'd8', value: Compliance.ReturnAssetPropertyEnum.D8 },\r\n { name: 'd9', value: Compliance.ReturnAssetPropertyEnum.D9 },\r\n { name: 'd10', value: Compliance.ReturnAssetPropertyEnum.D10 },\r\n { name: 'inventoryJan', value: Compliance.ReturnAssetPropertyEnum.InventoryJan },\r\n { name: 'inventoryFeb', value: Compliance.ReturnAssetPropertyEnum.InventoryFeb },\r\n { name: 'inventoryMar', value: Compliance.ReturnAssetPropertyEnum.InventoryMar },\r\n { name: 'inventoryApr', value: Compliance.ReturnAssetPropertyEnum.InventoryApr },\r\n { name: 'inventoryMay', value: Compliance.ReturnAssetPropertyEnum.InventoryMay },\r\n { name: 'inventoryJun', value: Compliance.ReturnAssetPropertyEnum.InventoryJun },\r\n { name: 'inventoryJul', value: Compliance.ReturnAssetPropertyEnum.InventoryJul },\r\n { name: 'inventoryAug', value: Compliance.ReturnAssetPropertyEnum.InventoryAug },\r\n { name: 'inventorySep', value: Compliance.ReturnAssetPropertyEnum.InventorySep },\r\n { name: 'inventoryOct', value: Compliance.ReturnAssetPropertyEnum.InventoryOct },\r\n { name: 'inventoryNov', value: Compliance.ReturnAssetPropertyEnum.InventoryNov },\r\n { name: 'inventoryDec', value: Compliance.ReturnAssetPropertyEnum.InventoryDec },\r\n { name: 'inventoryAvrCalculated', value: Compliance.ReturnAssetPropertyEnum.InventoryAvr },\r\n { name: 'splitAllocationPercentage', value: Compliance.ReturnAssetPropertyEnum.SplitAllocationPercentage },\r\n { name: 'additionalDepreciation', value: Compliance.ReturnAssetPropertyEnum.AdditionalDepreciation },\r\n { name: 'estimatedFMV', value: Compliance.ReturnAssetPropertyEnum.EstimatedFMV },\r\n { name: 'isReportable', value: Compliance.ReturnAssetPropertyEnum.IsReportable },\r\n { name: 'isTaxable', value: Compliance.ReturnAssetPropertyEnum.IsTaxable },\r\n { name: 'parcelAddressComplete', value: Compliance.ReturnAssetPropertyEnum.ParcelAddressComplete },\r\n { name: 'companyCode', value: Compliance.ReturnAssetPropertyEnum.CompanyCode },\r\n { name: 'netBookValue', value: Compliance.ReturnAssetPropertyEnum.NetBookValue },\r\n { name: 'indexFactorTableName', value: Compliance.ReturnAssetPropertyEnum.IndexFactorTableName },\r\n { name: 'form', value: Compliance.ReturnAssetPropertyEnum.Form },\r\n { name: 'assetOwnershipType', value: Compliance.ReturnAssetPropertyEnum.AssetOwnershipType },\r\n { name: 'alternativeCostDescriptor', value: Compliance.ReturnAssetPropertyEnum.AlternativeCostDescriptor },\r\n { name: 'alternativeAcquisitionDateDescriptor', value: Compliance.ReturnAssetPropertyEnum.AlternativeAcquisitionDateDescriptor },\r\n { name: 'doNotPotentiallyDispose', value: Compliance.ReturnAssetPropertyEnum.DoNotPotentiallyDispose },\r\n { name: 'isAnchored', value: Compliance.ReturnAssetPropertyEnum.IsAnchored },\r\n { name: 'isAssetLocked', value: Compliance.ReturnAssetPropertyEnum.IsLocked },\r\n { name: 'leaseStartDate', value: Compliance.ReturnAssetPropertyEnum.LeaseStartDate },\r\n { name: 'leaseEndDate', value: Compliance.ReturnAssetPropertyEnum.LeaseEndDate },\r\n { name: 'leaseClientId', value: Compliance.ReturnAssetPropertyEnum.LeaseClientId },\r\n { name: 'leaseTermInMonths', value: Compliance.ReturnAssetPropertyEnum.LeaseTermInMonths },\r\n { name: 'leaseMonthlyPayment', value: Compliance.ReturnAssetPropertyEnum.LeaseMonthlyPayment },\r\n { name: 'leaseTypeId', value: Compliance.ReturnAssetPropertyEnum.LeaseTypeId },\r\n { name: 'leaseAssetId', value: Compliance.ReturnAssetPropertyEnum.LeaseAssetId },\r\n { name: 'leaseNumber', value: Compliance.ReturnAssetPropertyEnum.LeaseNumber },\r\n { name: 'siteAddress', value: Compliance.ReturnAssetPropertyEnum.SiteAddress }\r\n ];\r\n private _lastFilterUsedInTotals: string;\r\n\r\n async getSelectedRowTotals(selectedRowsModel: Compliance.SelectedRowsModel): Promise {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.selectedRows = selectedRowsModel;\r\n searchParams.includeTotals = true;\r\n searchParams.includeOnlyTotals = true;\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: 100\r\n };\r\n\r\n const result = await lastValueFrom(this._returnAssetRepository\r\n .getListByFilingBatch(this._returnService.filingBatchId, searchParams));\r\n\r\n return result.totals;\r\n }\r\n\r\n clearTotals(): void {\r\n this._lastFilterUsedInTotals = '';\r\n this._totalsUpdateCallback({}, false, false);\r\n }\r\n\r\n getSearchParamsWithoutPagination(): Compliance.ReturnAssetSearchModel {\r\n const searchModel: Compliance.ReturnAssetSearchModel = {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n formRevisionIds: this._returnService.sharedState.formRevisionId ? [this._returnService.sharedState.formRevisionId] : [],\r\n parcelIds: this._returnService.sharedState.returns.map(x => x.parcelId),\r\n assessorIds: this._returnAssetsService.sharedState.assessorFactorsFilter.assessorIds || [],\r\n formRevisionScheduleIds: this._returnAssetsService.sharedState.scheduleAndFactorFilter.formRevisionScheduleIds,\r\n formFactorTableId: this._returnAssetsService.sharedState.scheduleAndFactorFilter.depreciationFactorId,\r\n age: this._returnAssetsService.sharedState.scheduleAndFactorFilter.scheduleAge,\r\n priorReturnStatuses: this._returnAssetsService.sharedState.assetStatusesFilter,\r\n scheduleGroupType: Compliance.ScheduleGroupTypeEnum.Unrestricted,\r\n priorScheduleGroupType: Compliance.ScheduleGroupTypeEnum.Unrestricted,\r\n selectedRows: null,\r\n includeTotals: false,\r\n includeOnlyTotals: false,\r\n includeMergedParcels: this._returnService.isConsolidatedReturn,\r\n includeUnassigned: false,\r\n includeDisposed: false\r\n };\r\n\r\n if (this._returnAssetsService.sharedState.scheduleAndFactorFilter.showOnlyAssignedToNonReportableSchedule) {\r\n searchModel.scheduleGroupType = Compliance.ScheduleGroupTypeEnum.NonReportable;\r\n }\r\n\r\n if (this._returnAssetsService.sharedState.scheduleAndFactorFilter.showOnlyAssignedToReportableSchedule) {\r\n searchModel.scheduleGroupType = Compliance.ScheduleGroupTypeEnum.ReportableTaxableNotTaxable;\r\n }\r\n\r\n if (this._returnAssetsService.sharedState.scheduleAndFactorFilter.showOnlyNotAssignedToASchedule) {\r\n searchModel.scheduleGroupType = Compliance.ScheduleGroupTypeEnum.OnlyNotAssignedToASchedule;\r\n }\r\n\r\n return searchModel;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.pagination = {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n };\r\n\r\n return await lastValueFrom(this._returnAssetRepository.getRowIdsByFilingBatch(this._returnService.filingBatchId, searchParams));\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n return !!(searchParams && searchParams.parcelIds.length);\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n this.gridApi.setPinnedBottomRowData([]);\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n const searchParamsString = JSON.stringify(searchParams);\r\n const fetchTotals: boolean = (!this.lastFetchedTotals) || (this._lastFilterUsedInTotals !== searchParamsString);\r\n\r\n this._lastFilterUsedInTotals = searchParamsString;\r\n\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const result: Compliance.QueryResultWithTotalsModel =\r\n await lastValueFrom(this._returnAssetRepository.getListByFilingBatch(this._returnService.filingBatchId, searchParams));\r\n\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals);\r\n\r\n const dataSourceResult = {\r\n rows: result.data,\r\n totalRows: result.totalRows,\r\n lastModifiedTimestamp: result.lastModifiedTimestamp\r\n };\r\n\r\n if (fetchTotals) {\r\n this._getAllRowTotals(params);\r\n }\r\n\r\n if (!result.data.length && this._returnAssetsService.hasResetNoDataFilterApplied) {\r\n this._returnAssetsService.setScheduleAndFactorFilter({\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n depreciationFactorId: null,\r\n scheduleAge: null,\r\n formRevisionScheduleIds: []\r\n });\r\n }\r\n\r\n return dataSourceResult;\r\n }\r\n\r\n private async _getAllRowTotals(params: IGetRowsParams): Promise {\r\n this._totalsUpdateCallback(this.lastFetchedTotals, false, true);\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n\r\n searchParams.includeTotals = true;\r\n searchParams.includeOnlyTotals = true;\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n let result: Compliance.QueryResultWithTotalsModel;\r\n\r\n if (searchParams.assessorIds.length || searchParams.parcelIds.length || !searchParams.formRevisionIds.length) {\r\n result = await lastValueFrom(this._returnAssetRepository\r\n .getListByFilingBatch(this._returnService.filingBatchId, searchParams));\r\n } else {\r\n result = {\r\n totals: {} as Compliance.ReturnAssetSearchTotalsModel,\r\n data: [],\r\n totalRows: 0,\r\n totalValidRows: 0,\r\n lastModifiedTimestamp: new Date()\r\n };\r\n }\r\n\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals);\r\n\r\n return result.totals;\r\n }\r\n}\r\n","import { Component, OnDestroy } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { Subscription } from 'rxjs';\r\n\r\nexport interface ICellRendererParamsForReturnAssetListGridAction extends ICellRendererParams {\r\n viewDetails: (params: ICellRendererParamsForReturnAssetListGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n ``\r\n})\r\n\r\nexport class ReturnAssetListGridActionCellRendererComponent implements ICellRendererAngularComp, OnDestroy {\r\n constructor(\r\n private _returnService: ReturnService) { }\r\n\r\n private _params: ICellRendererParamsForReturnAssetListGridAction;\r\n private _returnReadOnlyFlagSub: Subscription;\r\n\r\n returnAsset: Compliance.ReturnAssetModel;\r\n isReadOnly: boolean = false;\r\n\r\n agInit(params: ICellRendererParamsForReturnAssetListGridAction): void {\r\n this._returnReadOnlyFlagSub = this._returnService.isReturnInReadOnlyMode$.subscribe(x => this.isReadOnly = x);\r\n this.isReadOnly = this._returnService.isReturnInReadOnlyMode;\r\n this._params = params;\r\n this.returnAsset = params.data as Compliance.ReturnAssetModel;\r\n\r\n if (!this.returnAsset) {\r\n\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnReadOnlyFlagSub.unsubscribe();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this._params.viewDetails(this._params);\r\n }\r\n}\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { BehaviorSubject, lastValueFrom, Subject } from 'rxjs';\r\nimport { RestrictService, Roles } from '../../../../../Common/Permissions/restrict.service';\r\nimport { WeissmanDateFormatPipe } from '../../../../../UI-Lib/Pipes';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, ICellRendererParams, RowNode } from 'ag-grid-community';\r\nimport {\r\n FactorTableDetailsComponent,\r\n FactorTableDetailsParams\r\n} from '../../../../Factor-Table/Factor-Table-Details/factorTableDetails.component';\r\nimport { WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport {\r\n ICellRendererParamsForReturnAssetDragAndDropSource,\r\n ReturnAssetDragAndDropSourceComponent\r\n} from '../Drag-And-Drop/returnAssetDragAndDropSource.component';\r\nimport { ReturnAssetListAgGridDataSource } from './agGridDataSource';\r\nimport { ReturnService, ReturnServiceSharedState } from '../../../return.service';\r\nimport { ReturnAssetsService, ReturnAssetsServiceSharedState } from '../returnAssets.service';\r\nimport { ReturnAssetDragAndDropService } from '../Drag-And-Drop/returnAssetDragAndDrop.service';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../../AgGrid';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../../../AgGrid/MultiSelectTracker';\r\nimport {\r\n ICellRendererParamsForReturnAssetListGridAction,\r\n ReturnAssetListGridActionCellRendererComponent\r\n} from './agGridActionCellRenderer.component';\r\nimport { ReturnAssetChangeIconCellRendererComponent } from './agGridChangeIconCellRenderer.component';\r\nimport { AssetDetailsComponent, AssetDetailsParams } from '../../../../Asset/Asset-Details/assetDetails.component';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport {\r\n ReturnAssetBulkUpdateComponent,\r\n ReturnAssetBulkUpdateParams\r\n} from '../Return-Asset-Bulk-Update/returnAssetBulkUpdate.component';\r\nimport { BusyIndicatorService } from '../../../../../Busy-Indicator';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../../../AgGrid/ToolPanel/models';\r\nimport { ReturnAssetRepository } from '../../../../Repositories';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { takeUntil } from 'rxjs/internal/operators/takeUntil';\r\nimport { TimerService } from '../../../../../UI-Lib/Utilities';\r\n\r\nimport * as _ from 'lodash';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport { ProductAnalyticsService } from '../../../../../Common/Amplitude/productAnalytics.service';\r\n\r\nexport interface ReturnAssetListColDefMetadata {\r\n isRelatedToPriorReturn: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'return-asset-list',\r\n templateUrl: './returnAssetList.component.html',\r\n styleUrls: ['./returnAssetList.component.scss']\r\n})\r\nexport class ReturnAssetListComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _returnAssetDragAndDropService: ReturnAssetDragAndDropService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _returnAssetRepository: ReturnAssetRepository,\r\n private readonly _timer: TimerService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _restrictService: RestrictService\r\n ) { }\r\n\r\n selectedTotalsLoading: boolean = true;\r\n gridTotalsRow: any;\r\n gridSelectedTotalsRow: any;\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n totalsLoading: any;\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n get companyId(): number {\r\n return this._returnService.companyId;\r\n }\r\n\r\n gridId: System.Guid = 'CFE5F117-024B-498C-879A-4B41A31087FD';\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.ReportingAssetModel).reportingAssetId),\r\n 'totals-row': (params) => params.data && params.data.totalsRow,\r\n 'selected-totals-row': (params) => params.data && params.data.selectedTotalsRow\r\n }\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const searchParams = this._gridDataSource.getSearchParamsWithoutPagination();\r\n searchParams.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n if (!searchParams.selectedRows.selectAllRows && searchParams.selectedRows.selectedRows.length === 0) {\r\n searchParams.selectedRows.selectAllRows = true;\r\n }\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: this._gridDataSource.totalRows\r\n };\r\n const exportModel: Compliance.ReturnAssetExportModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn,\r\n fileFormat\r\n };\r\n const longRunningProcessId = await this._returnAssetsService.exportAssets(exportModel);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportReturnAssets };\r\n },\r\n canCancel: true,\r\n showFileFormatSelection: true\r\n };\r\n\r\n private _localReturnServiceSharedState: ReturnServiceSharedState;\r\n private _localReturnAssetsServiceSharedState: ReturnAssetsServiceSharedState;\r\n private _gridApi: GridApi;\r\n private _gridDataSource: ReturnAssetListAgGridDataSource;\r\n private _destroy$: Subject = new Subject();\r\n private _parcelsChangeDate: Date = null;\r\n private _initialized: boolean;\r\n private _tabActive: boolean;\r\n\r\n ngOnInit(): void {\r\n this._returnAssetsService.subscribeToServiceActivationCycle(this);\r\n this._returnAssetDragAndDropService.start(this._getDraggedAssetIds.bind(this), this._getDraggedAssets.bind(this));\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnAssetsService.unsubscribeFromServiceActivationCycle(this);\r\n this._returnAssetDragAndDropService.stop();\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n if (!this._initialized) {\r\n this._setDataSource();\r\n }\r\n // if the return is in read only mode then stop the drag and drop service\r\n if (this._returnService.isReturnInReadOnlyMode) {\r\n this._returnAssetDragAndDropService.stop();\r\n }\r\n\r\n this._returnAssetsService.scheduleAndFactorFilter$.pipe(takeUntil(this._destroy$))\r\n .subscribe(async () => await this._refreshAssets());\r\n\r\n // if the return goes into read-only mode then stop; otherwise start the drag-and-drop service\r\n this._returnService.isReturnInReadOnlyMode$.pipe(takeUntil(this._destroy$)).subscribe(x => {\r\n if (x) {\r\n this._returnAssetDragAndDropService.stop();\r\n this.isBulkUpdateVisible$.next(false);\r\n } else if (!this._returnAssetDragAndDropService.isStarted()) {\r\n this._returnAssetDragAndDropService.start(this._getDraggedAssetIds.bind(this), this._getDraggedAssets.bind(this));\r\n }\r\n });\r\n\r\n // if the return goes into read-only mode then stop; otherwise start the drag-and-drop service\r\n this._returnService.formRevisionId$.pipe(takeUntil(this._destroy$)).subscribe(x => {\r\n if (!x) {\r\n this._returnAssetDragAndDropService.stop();\r\n } else if (!this._returnAssetDragAndDropService.isStarted()) {\r\n this._returnAssetDragAndDropService.start(this._getDraggedAssetIds.bind(this), this._getDraggedAssets.bind(this));\r\n }\r\n });\r\n\r\n // a different form was requested when navigating to the assets tab\r\n if (this._returnAssetsService.sharedState.formRevisionId && this._returnAssetsService.sharedState.formRevisionId !== this._returnService.sharedState.formRevisionId) {\r\n this._returnService.setFormRevisionId(this._returnAssetsService.sharedState.formRevisionId);\r\n }\r\n\r\n this._returnService.parcelsChanged$.pipe(takeUntil(this._destroy$)).subscribe((x) => {\r\n if (x) {\r\n if (this._parcelsChangeDate !== x) {\r\n this._parcelsChangeDate = x;\r\n this._refreshAssets(true);\r\n }\r\n }\r\n });\r\n\r\n this._setGridTracker();\r\n\r\n this._tabActive = true;\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._destroy$.next();\r\n this._tabActive = false;\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this.gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe(async () => {\r\n const isBulkUpdateButtonVisible = (!this._returnService.isReturnInReadOnlyMode) && this._returnService.canEditCompany && this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateButtonVisible);\r\n await this._reloadTotals();\r\n });\r\n\r\n this.gridTracker.isSelectingRange$.pipe(takeUntil(this._destroy$)).subscribe(loading => {\r\n if (!loading) {\r\n const isBulkUpdateButtonVisible = (!this._returnService.isReturnInReadOnlyMode) && this._returnService.canEditCompany && this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateButtonVisible);\r\n } else {\r\n this.isBulkUpdateVisible$.next(false);\r\n }\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: '',\r\n field: 'reportingAssetId',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n cellRendererFramework: ReturnAssetDragAndDropSourceComponent,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as ICellRendererParamsForReturnAssetDragAndDropSource\r\n },\r\n {\r\n headerName: '',\r\n field: 'reportingAssetId',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n },\r\n {\r\n headerName: 'Asset Number',\r\n field: 'assetNumber',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n lockVisible: true,\r\n lockPosition: true,\r\n lockPinned: true,\r\n pinned: 'left',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.assetNumber === rowData.sourceAssetNumber) ? null : 'overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.description === rowData.sourceDescription) ? null : 'overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Ownership Type',\r\n field: 'assetOwnershipType',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.assetOwnershipType === rowData.assetOwnershipType) ? null : 'overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Company Code',\r\n field: 'companyCode',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'G/L Account',\r\n field: 'glAccount',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.glAccountId === rowData.sourceGlAccountId) ? null : 'overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'G/L Account Number',\r\n field: 'glAccountNumber',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.glAccountId === rowData.sourceGlAccountId) ? null : 'overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Change Status',\r\n field: 'assetReturnStatus',\r\n toolPanelClass: 'Asset',\r\n cellRendererFramework: ReturnAssetChangeIconCellRendererComponent,\r\n width: 120,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n sortable: false\r\n },\r\n {\r\n headerName: 'Split Allocation %',\r\n field: 'splitAllocationPercentage',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n hide: true\r\n },\r\n {\r\n headerName: 'Classification',\r\n field: 'classificationName',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData\r\n && ((rowData.classificationId && rowData.glAccountClassificationId && rowData.classificationId === rowData.glAccountClassificationId)\r\n || (!rowData.classificationId && !rowData.glAccountClassificationId))\r\n ) ? null : 'overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Parcel',\r\n field: 'parcelAccountNumber',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as Compliance.ReturnAssetModel;\r\n if (!asset) {\r\n return '';\r\n }\r\n return `#/parcel/${asset.parcelId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n headerName: 'Parcel Address (Complete)',\r\n field: 'parcelAddressComplete',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Linked/Sub Parcel',\r\n field: 'linkedParcelAccountNumber',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Parcel Desc.',\r\n field: 'parcelDescription',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Linked/Sub Parcel Desc.',\r\n field: 'linkedParcelDescription',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorAbbr',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Linked/Sub Assessor',\r\n field: 'linkedParcelAssessorAbbr',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Prior Acq. Date',\r\n field: 'priorAcqDate',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n ws: {\r\n isRelatedToPriorReturn: true\r\n } as ReturnAssetListColDefMetadata\r\n } as ColDef,\r\n {\r\n headerName: 'Acq. Date',\r\n field: 'acqDate',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData\r\n && ((rowData.acqDate && rowData.sourceAcqDate && rowData.acqDate.toString() === rowData.sourceAcqDate.toString())\r\n || (!rowData.acqDate && !rowData.sourceAcqDate))\r\n ) ? null : 'overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Alternate Acq. Date Source',\r\n field: 'alternativeCostDescriptor',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams\r\n },\r\n {\r\n headerName: 'Do Not Potentially Dispose',\r\n toolPanelClass: 'Asset',\r\n field: 'doNotPotentiallyDispose',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return '';\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Prior Cost',\r\n field: 'priorCost',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n ws: {\r\n isRelatedToPriorReturn: true\r\n } as ReturnAssetListColDefMetadata\r\n } as ColDef,\r\n {\r\n headerName: 'Cost',\r\n field: 'cost',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.cost === rowData.sourceCost) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Cost Change',\r\n field: 'costChange',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n ws: {\r\n isRelatedToPriorReturn: true\r\n } as ReturnAssetListColDefMetadata\r\n } as ColDef,\r\n {\r\n headerName: 'Net Book Value',\r\n field: 'netBookValue',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => x.value || x.value === 0 ? this._decimalPipe.transform(x.value, '1.2-2') : null,\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.netBookValue === rowData.sourceNetBookValue) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'site',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const rowData = params.data as Compliance.ReturnAssetModel;\r\n if (!(rowData && rowData.siteId)) {\r\n return '';\r\n }\r\n return `#/site/${rowData.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as Compliance.ReturnAssetModel;\r\n return asset && asset.site !== asset.sourceSite ? 'ws-override' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Site Name',\r\n field: 'siteName',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const rowData = params.data as Compliance.ReturnAssetModel;\r\n if (!(rowData && rowData.siteId)) {\r\n return '';\r\n }\r\n return `#/site/${rowData.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as Compliance.ReturnAssetModel;\r\n return asset && asset.site !== asset.sourceSite ? 'ws-override' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'siteProperty',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const rowData = params.data as Compliance.ReturnAssetModel;\r\n if (!(rowData && rowData.siteId)) {\r\n return '';\r\n }\r\n return `#/site/${rowData.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as Compliance.ReturnAssetModel;\r\n return asset && asset.site !== asset.sourceSite ? 'ws-override' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Site Address',\r\n field: 'siteAddress',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as Compliance.ReturnAssetModel;\r\n return asset && asset.siteAddress !== asset.sourceSiteAddress ? 'ws-override' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Is Anchored',\r\n toolPanelClass: 'Asset',\r\n field: 'isAnchored',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return '';\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Is Locked',\r\n toolPanelClass: 'Asset',\r\n field: 'isAssetLocked',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return '';\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Prior Schedule',\r\n field: 'priorScheduleName',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n ws: {\r\n isRelatedToPriorReturn: true\r\n } as ReturnAssetListColDefMetadata\r\n } as ColDef,\r\n {\r\n headerName: 'Schedule',\r\n field: 'scheduleName',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return rowData && rowData.formRevisionScheduleId === rowData.defaultFormScheduleId ? null : 'overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Form',\r\n field: 'form',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Prior Dep. Table',\r\n field: 'priorDepreciationFactorTableName',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.priorDepreciationFactorTableName) ? `${rowData.priorDepreciationFactorTableName} (${rowData.priorDepreciationFactorTableLife} year life)` : '';\r\n },\r\n ws: {\r\n isRelatedToPriorReturn: true\r\n } as ReturnAssetListColDefMetadata\r\n } as ColDef,\r\n {\r\n headerName: 'Dep. Table',\r\n field: 'depreciationFactorTableName',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'return-page.view-depreciation-table',\r\n onClickAsync: async (x: AgGridLinkCellRendererParams) => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n const params: FactorTableDetailsParams = {\r\n factorTableId: rowData.depreciationFactorTableId,\r\n editMode: false\r\n };\r\n\r\n await this._modalService.showAsync(FactorTableDetailsComponent, params, 'modal-xl');\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n return !this._restrictService.isInRole(Roles.COMPLIANCESETUPSVIEW);\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.depreciationFactorTableName) ? `${rowData.depreciationFactorTableName} (${rowData.depreciationFactorTableLife} year life)` : '';\r\n },\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.depreciationFactorTableId === rowData.defaultFormDepreciationTableId) ? null : 'overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Index Table',\r\n field: 'indexFactorTableName',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'return-page.view-index-table',\r\n onClickAsync: async (x: AgGridLinkCellRendererParams) => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n const params: FactorTableDetailsParams = {\r\n factorTableId: rowData.indexFactorTableId,\r\n editMode: false\r\n };\r\n\r\n await this._modalService.showAsync(FactorTableDetailsComponent, params, 'modal-xl');\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n return !this._restrictService.isInRole(Roles.COMPLIANCESETUPSVIEW);\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.indexFactorTableName) ? `${rowData.indexFactorTableName} (${rowData.indexFactorTableLife} year life)` : '';\r\n },\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.indexFactorTableId === rowData.defaultFormIndexTableId) ? null : 'overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Factor',\r\n field: 'factor',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParamsWithEqualTo,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => (x && (x.value || x.value === 0)) ? `${this._decimalPipe.transform(x.value * 100, '1.2-5')}%` : '',\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.depreciationFactorTableId === rowData.defaultFormDepreciationTableId) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n }\r\n },\r\n {\r\n headerName: 'Rep. Value',\r\n field: 'reportedValue',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return !rowData\r\n ? null\r\n : x.value || x.value === 0\r\n ? this._decimalPipe.transform(x.value, '1.2-2')\r\n : 'N/A';\r\n }\r\n },\r\n {\r\n headerName: 'Add\\'l Dep.',\r\n field: 'additionalDepreciation',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => (x && x.value) ? `${this._decimalPipe.transform(x.value * 100, '1.2-5')}%` : '',\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.additionalDepreciation) ? 'ag-numeric-cell overridden' : 'ag-numeric-cell';\r\n }\r\n },\r\n {\r\n headerName: 'Est. FMV',\r\n field: 'estimatedFMV',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return !rowData\r\n ? null\r\n : x.value || x.value === 0 || rowData.estimatedFMVOverridden\r\n ? this._decimalPipe.transform(x.value, '1.2-2')\r\n : 'N/A';\r\n },\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.estimatedFMVOverridden) ? 'ag-numeric-cell overridden' : 'ag-numeric-cell';\r\n }\r\n },\r\n {\r\n headerName: 'Acq. Year',\r\n field: 'acqYear',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterAndEqualToParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Age',\r\n field: 'age',\r\n toolPanelClass: 'Asset',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterAndEqualToParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Location Name',\r\n field: 'leaseLocationName',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseLocationName')\r\n },\r\n {\r\n headerName: 'Location Address',\r\n field: 'leaseAddress',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseAddress')\r\n },\r\n {\r\n headerName: 'Location City',\r\n field: 'leaseCity',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseCity')\r\n },\r\n {\r\n headerName: 'Location State',\r\n field: 'leaseState',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseState')\r\n },\r\n {\r\n headerName: 'Location Zip',\r\n field: 'leaseZip',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseZip')\r\n },\r\n {\r\n headerName: 'Lease Start Date',\r\n field: 'leaseStartDate',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseStartDate')\r\n },\r\n {\r\n headerName: 'Lease End Date',\r\n field: 'leaseEndDate',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseEndDate')\r\n },\r\n {\r\n headerName: 'Lease Term In Months',\r\n field: 'leaseTermInMonths',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseTermInMonths')\r\n },\r\n {\r\n headerName: 'Lease Monthly Payment',\r\n field: 'leaseMonthlyPayment',\r\n toolPanelClass: 'Leasing',\r\n filter: 'agNumberColumnFilter',\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseMonthlyPayment'),\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2')\r\n },\r\n {\r\n headerName: 'Lease Type',\r\n field: 'leaseTypeId',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseTypeId')\r\n },\r\n {\r\n headerName: 'Lease Asset ID',\r\n field: 'leaseAssetId',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseAssetId')\r\n },\r\n {\r\n headerName: 'Lease Number',\r\n field: 'leaseNumber',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseNumber')\r\n },\r\n {\r\n headerName: 'Billing Name',\r\n field: 'leaseBillingName',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseBillingName')\r\n },\r\n {\r\n headerName: 'Billing Address',\r\n field: 'leaseBillingAddress',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseBillingAddress')\r\n },\r\n {\r\n headerName: 'Billing City',\r\n field: 'leaseBillingCity',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseBillingCity')\r\n },\r\n {\r\n headerName: 'Billing State',\r\n field: 'leaseBillingState',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseBillingState')\r\n },\r\n {\r\n headerName: 'Billing Zip',\r\n field: 'leaseBillingZip',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseBillingZip')\r\n },\r\n {\r\n headerName: 'Customer Id',\r\n field: 'leaseClientId',\r\n toolPanelClass: 'Leasing',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: this._cellClassForOverrides.bind(this, 'leaseClientId')\r\n },\r\n {\r\n headerName: 'Jan Balance',\r\n field: 'inventoryJan',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryJan === rowData.sourceInventoryJan) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Feb Balance',\r\n field: 'inventoryFeb',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryFeb === rowData.sourceInventoryFeb) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Mar Balance',\r\n field: 'inventoryMar',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryMar === rowData.sourceInventoryMar) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Apr Balance',\r\n field: 'inventoryApr',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryApr === rowData.sourceInventoryApr) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'May Balance',\r\n field: 'inventoryMay',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryMay === rowData.sourceInventoryMay) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Jun Balance',\r\n field: 'inventoryJun',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryJun === rowData.sourceInventoryJun) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Jul Balance',\r\n field: 'inventoryJul',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryJul === rowData.sourceInventoryJul) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Aug Balance',\r\n field: 'inventoryAug',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryAug === rowData.sourceInventoryAug) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Sep Balance',\r\n field: 'inventorySep',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventorySep === rowData.sourceInventorySep) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Oct Balance',\r\n field: 'inventoryOct',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryOct === rowData.sourceInventoryOct) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Nov Balance',\r\n field: 'inventoryNov',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryNov === rowData.sourceInventoryNov) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Dec Balance',\r\n field: 'inventoryDec',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryDec === rowData.sourceInventoryDec) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Avg Balance',\r\n field: 'inventoryAvrCalculated',\r\n toolPanelClass: 'Inventory',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithEqualToAndBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.inventoryAvr === rowData.sourceInventoryAvr) ? 'ag-numeric-cell' : 'ag-numeric-cell overridden';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Aggregated Balance',\r\n field: 'inventoryAggregatedString',\r\n toolPanelClass: 'Inventory',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n sortable: false,\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n },\r\n {\r\n headerName: 'Reportable',\r\n field: 'isReportable',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n cellClass: 'ag-text-cell',\r\n valueFormatter: x => {\r\n if (x.value === null || x.value === undefined) { return; }\r\n return x.value ? 'Yes' : 'No';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Taxable',\r\n field: 'isTaxable',\r\n toolPanelClass: 'Asset',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n cellClass: 'ag-text-cell',\r\n valueFormatter: x => {\r\n if (x.value === null || x.value === undefined) { return; }\r\n return x.value ? 'Yes' : 'No';\r\n },\r\n hide: true\r\n }\r\n ];\r\n\r\n const assetDescriptorColumns = this._returnService.getCompanyAssetDescriptorMappingsAsColDefs(this._returnService.companyAssetDescriptorMappings);\r\n\r\n const actionColumn = {\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n pinned: 'right',\r\n cellRendererFramework: ReturnAssetListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this._viewAssetDetails.bind(this)\r\n } as ICellRendererParamsForReturnAssetListGridAction,\r\n pinnedRowCellRenderer: () => {return '';}\r\n };\r\n\r\n const finalColumnDefs = [...columns, ...assetDescriptorColumns, actionColumn];\r\n\r\n this._gridApi.setColumnDefs(finalColumnDefs);\r\n\r\n this._gridApi.setSortModel([{\r\n colId: 'assetNumber',\r\n sort: 'asc'\r\n }]);\r\n\r\n if (this._tabActive && !this._initialized) {\r\n this._setDataSource();\r\n }\r\n }\r\n\r\n async refresh(): Promise {\r\n this._productAnalyticsService.logEvent('click-assets-refresh', {});\r\n await this._refreshDataSource();\r\n }\r\n\r\n async bulkUpdate(): Promise {\r\n const updateReturnAssetSearchModel: Compliance.ReturnAssetSearchModel = {\r\n formRevisionIds: this._returnService.sharedState.formRevisionId ? [this._returnService.sharedState.formRevisionId] : [],\r\n formRevisionScheduleIds: this._returnAssetsService.sharedState.scheduleAndFactorFilter.formRevisionScheduleIds,\r\n parcelIds: this._returnService.sharedState.returns.map(x => x.parcelId),\r\n assessorIds: this._returnAssetsService.sharedState.assessorFactorsFilter.assessorIds || [],\r\n age: this._returnAssetsService.sharedState.scheduleAndFactorFilter.scheduleAge,\r\n priorReturnStatuses: this._returnAssetsService.sharedState.assetStatusesFilter,\r\n scheduleGroupType: Compliance.ScheduleGroupTypeEnum.Unrestricted,\r\n priorScheduleGroupType: Compliance.ScheduleGroupTypeEnum.Unrestricted,\r\n selectedRows: this.gridTracker.getSelectedRowsModel(),\r\n includeTotals: false,\r\n includeOnlyTotals: false,\r\n includeMergedParcels: this._returnService.isConsolidatedReturn,\r\n includeUnassigned: false,\r\n includeDisposed: false\r\n };\r\n\r\n if (this._returnAssetsService.sharedState.scheduleAndFactorFilter.showOnlyAssignedToNonReportableSchedule) {\r\n updateReturnAssetSearchModel.scheduleGroupType = Compliance.ScheduleGroupTypeEnum.NonReportable;\r\n }\r\n\r\n if (this._returnAssetsService.sharedState.scheduleAndFactorFilter.showOnlyAssignedToReportableSchedule) {\r\n updateReturnAssetSearchModel.scheduleGroupType = Compliance.ScheduleGroupTypeEnum.ReportableTaxableNotTaxable;\r\n }\r\n\r\n if (this._returnAssetsService.sharedState.scheduleAndFactorFilter.showOnlyNotAssignedToASchedule) {\r\n updateReturnAssetSearchModel.scheduleGroupType = Compliance.ScheduleGroupTypeEnum.OnlyNotAssignedToASchedule;\r\n }\r\n\r\n const params: ReturnAssetBulkUpdateParams = {\r\n filingBatchId: this._returnService.filingBatchId,\r\n searchModel: updateReturnAssetSearchModel,\r\n selectedCount: this.gridTracker.getSelectedRowsCount(),\r\n showPriorScheduleField: false\r\n };\r\n\r\n const result = await this._modalService.showAsync(ReturnAssetBulkUpdateComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Working on it' });\r\n try {\r\n let updateWorkingSetReportingAssetIds: number[] = [];\r\n\r\n if (!updateReturnAssetSearchModel.selectedRows.selectAllRows) {\r\n updateWorkingSetReportingAssetIds = updateReturnAssetSearchModel.selectedRows.selectedRows;\r\n }\r\n await this._returnAssetsService.notifyAssetDetailsUpdated(updateWorkingSetReportingAssetIds, true);\r\n\r\n // re-load all loaded return assets\r\n const filingBatchId = this._returnService.filingBatchId;\r\n const reportingAssetIds: number[] = [];\r\n this._gridApi.forEachNode(x => {reportingAssetIds.push(x.data.reportingAssetId);});\r\n\r\n updateReturnAssetSearchModel.selectedRows = {\r\n selectAllRows: false,\r\n selectedRows: reportingAssetIds\r\n };\r\n updateReturnAssetSearchModel.includeTotals = true;\r\n\r\n const rowData = await lastValueFrom(this._returnAssetRepository.getListByFilingBatch(filingBatchId, updateReturnAssetSearchModel));\r\n\r\n await this._refreshRows(rowData);\r\n\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private async _refreshAssets(force: boolean = false): Promise {\r\n const returnServiceSharedState: ReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n const returnAssetsServiceSharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n\r\n // get input parameters for comparison\r\n const localReturnIds = (this._localReturnServiceSharedState && this._localReturnServiceSharedState.returns && this._localReturnServiceSharedState.returns.map(x => x.returnId)) || [];\r\n const sharedReturnIds = returnServiceSharedState.returns.map(x => x.returnId);\r\n\r\n const localAssetFormRevisionId = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.formRevisionId;\r\n const sharedAssetFormRevisionId = returnAssetsServiceSharedState.formRevisionId;\r\n\r\n const localFormRevisionId = this._localReturnServiceSharedState && this._localReturnServiceSharedState.formRevisionId;\r\n const sharedFormRevisionId = returnServiceSharedState.formRevisionId;\r\n\r\n const localAssetStatusFilter = (this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetStatusesFilter) || [];\r\n const sharedAssetStatusFilter = returnAssetsServiceSharedState.assetStatusesFilter;\r\n\r\n const localAssessorFactors = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assessorFactorsFilter;\r\n const sharedAssessorFactors = returnAssetsServiceSharedState.assessorFactorsFilter;\r\n\r\n const localScheduleAndFactorFilter = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.scheduleAndFactorFilter;\r\n const sharedScheduleAndFactorFilter = returnAssetsServiceSharedState.scheduleAndFactorFilter;\r\n\r\n const localAssetDetailsUpdatedTimestamp = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n const sharedAssetDetailsUpdatedTimestamp = returnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n\r\n const localAssetMappingsUpdatedTimestamp = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n const sharedAssetMappingsUpdatedTimestamp = returnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n\r\n if (\r\n force ||\r\n // check to see if the input parameters are available\r\n (!sharedReturnIds || !sharedFormRevisionId || !sharedAssetStatusFilter || !sharedAssessorFactors) ||\r\n // check to see if the input parameters have changed\r\n (!_.isEqual(localReturnIds, sharedReturnIds) ||\r\n !_.isEqual(localFormRevisionId, sharedFormRevisionId) ||\r\n !_.isEqual(localAssetFormRevisionId, sharedAssetFormRevisionId) ||\r\n !_.isEqual(localAssetStatusFilter, sharedAssetStatusFilter) ||\r\n !_.isEqual(localAssessorFactors, sharedAssessorFactors) ||\r\n !_.isEqual(localScheduleAndFactorFilter, sharedScheduleAndFactorFilter) ||\r\n !_.isEqual(localAssetDetailsUpdatedTimestamp, sharedAssetDetailsUpdatedTimestamp) ||\r\n !_.isEqual(localAssetMappingsUpdatedTimestamp, sharedAssetMappingsUpdatedTimestamp))) {\r\n await this._loadAssets();\r\n }\r\n }\r\n\r\n private async _loadAssets(): Promise {\r\n // persist local state for future checks\r\n this._persistLocalState();\r\n await this._refreshDataSource();\r\n }\r\n\r\n private async _refreshRows(rowData: Compliance.QueryResultWithTotalsModel): Promise {\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n\r\n this._gridDataSource.clearTotals();\r\n\r\n const rowNodes: RowNode[] = [];\r\n this._gridApi.forEachNode(x => {\r\n const gridRow = x.data as Compliance.ReturnAssetModel;\r\n if (gridRow && gridRow.reportingAssetId) {\r\n const row = rowData.data.find(y => y.reportingAssetId === gridRow.reportingAssetId);\r\n if (row) {\r\n _.extend(gridRow, row);\r\n rowNodes.push(x);\r\n }\r\n }\r\n });\r\n\r\n this._gridApi.redrawRows({ rowNodes: rowNodes });\r\n this.handleTotalsUpdate(rowData.totals);\r\n\r\n this._gridDataSource.lastModifiedTimestamp = rowData.lastModifiedTimestamp;\r\n }\r\n\r\n private _persistLocalState(): void {\r\n this._localReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n this._localReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n }\r\n\r\n private async _refreshDataSource(): Promise {\r\n if (!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n\r\n this._gridDataSource.clearTotals();\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): void {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n\r\n this._gridDataSource = new ReturnAssetListAgGridDataSource(\r\n this._gridApi,\r\n this._returnService,\r\n this._returnAssetsService,\r\n this._returnAssetRepository,\r\n this.handleTotalsUpdate);\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n this._persistLocalState();\r\n this._initialized = true;\r\n }\r\n\r\n private _setGridTracker(): void {\r\n if(!this.gridTracker) {\r\n return;\r\n }\r\n\r\n this.gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe(async () => {\r\n const isBulkUpdateButtonVisible = (!this._returnService.isReturnInReadOnlyMode) && this._returnService.canEditCompany && this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateButtonVisible);\r\n await this._reloadTotals();\r\n });\r\n\r\n this.gridTracker.isSelectingRange$.pipe(takeUntil(this._destroy$)).subscribe(loading => {\r\n if (!loading) {\r\n const isBulkUpdateButtonVisible = (!this._returnService.isReturnInReadOnlyMode) && this._returnService.canEditCompany && this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateButtonVisible);\r\n } else {\r\n this.isBulkUpdateVisible$.next(false);\r\n }\r\n });\r\n }\r\n\r\n private async _getDraggedAssetIds(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Working on it' });\r\n try {\r\n return await this.gridTracker.getSelectedRowIds();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private async _getDraggedAssets(): Promise {\r\n const ids = await this._getDraggedAssetIds();\r\n const rowNodes = ids.reduce((acc, x) => {\r\n const node = this._gridApi.getRowNode(`${x}`);\r\n if (node) {\r\n acc.push(node.data as Compliance.ReturnAssetModel);\r\n }\r\n return acc;\r\n }, []);\r\n return rowNodes.length ? rowNodes : [];\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private async _viewAssetDetails(params: ICellRendererParamsForReturnAssetListGridAction): Promise {\r\n const asset = params.data as Compliance.ReturnAssetModel;\r\n if (!asset) {\r\n return Promise.resolve();\r\n }\r\n\r\n const inputParams: AssetDetailsParams = {\r\n reportingAssetId: asset.reportingAssetId,\r\n assetId: asset.assetId,\r\n lienDate: this._returnService.lienDate,\r\n canEdit: this._returnService.canEditCompany && !this._returnService.isReturnInReadOnly,\r\n createNewAsset: false,\r\n topLevelCompanyId: this._returnService.companyId,\r\n assetDescriptors: this._returnService.companyAssetDescriptorMappings,\r\n newAssetCompanyId: null,\r\n canViewRyanPrivateItems: this._returnService.canViewRyanPrivateItems,\r\n fromLockedReturn: this._returnService.isReturnInReadOnly\r\n };\r\n\r\n const result = await this._modalService.showAsync(AssetDetailsComponent, inputParams, 'modal-xl');\r\n\r\n if (!(result && result.hasChanges)) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Working on it' });\r\n\r\n try {\r\n // update the working set\r\n const searchModel = this._gridDataSource.getSearchParamsWithoutPagination();\r\n searchModel.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n let updateWorkingSetReportingAssetIds: number[] = [];\r\n if (!searchModel.selectedRows.selectAllRows) {\r\n updateWorkingSetReportingAssetIds = searchModel.selectedRows.selectedRows;\r\n }\r\n await this._returnAssetsService.notifyAssetDetailsUpdated(updateWorkingSetReportingAssetIds, true);\r\n\r\n this._loadAssets();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n handleTotalsUpdate = (totals: Compliance.ReturnAssetSearchTotalsModel, selectedTotals: boolean = false, isLoading: boolean = false) => {\r\n const assetModelRow: any = {\r\n cost: totals.totalCost || 0,\r\n reportedValue: totals.totalReportedValue || 0,\r\n priorCost: totals.totalPriorCost || 0,\r\n costChange: totals.totalCostChange || 0,\r\n priorReportedValue: totals.totalPriorReportedValue || 0,\r\n n1: totals.totalN1 || 0,\r\n n2: totals.totalN2 || 0,\r\n n3: totals.totalN3 || 0,\r\n n4: totals.totalN4 || 0,\r\n n5: totals.totalN5 || 0,\r\n n6: totals.totalN6 || 0,\r\n n7: totals.totalN7 || 0,\r\n n8: totals.totalN8 || 0,\r\n n9: totals.totalN9 || 0,\r\n n10: totals.totalN10 || 0,\r\n assetNumber: 'TOTAL',\r\n sourceAssetNumber: 'TOTAL',\r\n sourceCost: totals.totalCost || 0,\r\n sourceN1: totals.totalN1 || 0,\r\n sourceN2: totals.totalN2 || 0,\r\n sourceN3: totals.totalN3 || 0,\r\n sourceN4: totals.totalN4 || 0,\r\n sourceN5: totals.totalN5 || 0,\r\n sourceN6: totals.totalN6 || 0,\r\n sourceN7: totals.totalN7 || 0,\r\n sourceN8: totals.totalN8 || 0,\r\n sourceN9: totals.totalN9 || 0,\r\n sourceN10: totals.totalN10 || 0,\r\n inventoryJan: totals.totalInventoryJan || 0,\r\n inventoryFeb: totals.totalInventoryFeb || 0,\r\n inventoryMar: totals.totalInventoryMar || 0,\r\n inventoryApr: totals.totalInventoryApr || 0,\r\n inventoryMay: totals.totalInventoryMay || 0,\r\n inventoryJun: totals.totalInventoryJun || 0,\r\n inventoryJul: totals.totalInventoryJul || 0,\r\n inventoryAug: totals.totalInventoryAug || 0,\r\n inventorySep: totals.totalInventorySep || 0,\r\n inventoryOct: totals.totalInventoryOct || 0,\r\n inventoryNov: totals.totalInventoryNov || 0,\r\n inventoryDec: totals.totalInventoryDec || 0,\r\n inventoryAvr: totals.totalInventoryAvr || 0,\r\n estimatedFMV: totals.totalEstimatedFMV || 0\r\n };\r\n\r\n if (selectedTotals) {\r\n assetModelRow.selectedTotalsRow = true;\r\n assetModelRow.assetNumber = 'SELECTED';\r\n assetModelRow.sourceAssetNumber = 'SELECTED';\r\n this.gridSelectedTotalsRow = assetModelRow;\r\n } else {\r\n assetModelRow.totalsRow = true;\r\n this.gridTotalsRow = assetModelRow;\r\n }\r\n const totalRows = [this.gridTotalsRow];\r\n if (this.gridTracker.hasAnythingSelected()) {\r\n totalRows.push(this.gridSelectedTotalsRow);\r\n }\r\n\r\n if (isLoading && !this.totalsLoading) {\r\n this.totalsLoading = this._gridDataSource.getLoadingMessage(msg => {\r\n assetModelRow.assetNumber = msg;\r\n assetModelRow.sourceAssetNumber = msg;\r\n this._gridApi.setPinnedBottomRowData(totalRows);\r\n });\r\n return;\r\n } else if (!isLoading && this.totalsLoading >= 0) {\r\n clearInterval(this.totalsLoading);\r\n this.totalsLoading = null;\r\n }\r\n\r\n this._timer.setTimeout(() => this._gridApi.setPinnedBottomRowData(totalRows), 100);\r\n };\r\n\r\n private async _reloadTotals(): Promise {\r\n const parcelIds = this._returnService.sharedState.returns.map(x => x.parcelId);\r\n const assessorIds = this._returnAssetsService.sharedState.assessorFactorsFilter.assessorIds;\r\n if (!this._gridDataSource || !(parcelIds || assessorIds)) {\r\n return;\r\n }\r\n\r\n this.handleTotalsUpdate({}, true, true);\r\n try {\r\n const result = await this._gridDataSource.getSelectedRowTotals(this.gridTracker.getSelectedRowsModel());\r\n this.handleTotalsUpdate(result || {}, true, false);\r\n } catch(e) {\r\n this.handleTotalsUpdate({}, true, false);\r\n }\r\n }\r\n\r\n private _cellClassForOverrides(colName, x: any) {\r\n if (colName.length < 1) {\r\n return '';\r\n }\r\n\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n const colNameForSource = `source${ colName.charAt(0).toUpperCase() }${colName.substring(1)}`;\r\n return (rowData && rowData[colName] && rowData[colNameForSource] && rowData[colName].toString() === rowData[colNameForSource].toString()) ? null : 'overridden';\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n Assets\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n","import { Component, ElementRef, ViewChild, OnInit, OnDestroy, Input, Output, EventEmitter } from '@angular/core';\r\nimport { Subject, Subscription } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { ReturnAssetDragAndDropService } from './returnAssetDragAndDrop.service';\r\n\r\n@Component({\r\n selector: 'return-asset-drag-and-drop-target',\r\n template: `\r\n
\r\n
\r\n
{{ getOverlayTitle() }}
\r\n
\r\n \r\n
\r\n \r\n `,\r\n styleUrls: ['./returnAssetDragAndDropTarget.component.scss']\r\n})\r\nexport class ReturnAssetDragAndDropTargetComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private _returnAssetDragAndDropService: ReturnAssetDragAndDropService,\r\n private _returnService: ReturnService\r\n ) {\r\n this.dragulaContainerType = this._returnAssetDragAndDropService.CONTAINER_TYPE_TARGET;\r\n this.dragulaBagName = this._returnAssetDragAndDropService.BAG_NAME;\r\n }\r\n\r\n @ViewChild('dragulaEl') dragulaElRef: ElementRef;\r\n\r\n @Input() scheduleName: string;\r\n @Input() scheduleDescription: string;\r\n @Input() depreciationTableLife: number;\r\n\r\n @Output() assetsDropped: EventEmitter = new EventEmitter();\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n isReadOnly: boolean;\r\n isServiceActive: boolean;\r\n\r\n dragulaContainerType: string;\r\n dragulaBagName: string;\r\n\r\n dragging: boolean = false;\r\n draggingOver: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this._returnAssetDragAndDropService.dragging$.pipe(takeUntil(this._destroy$)).subscribe(x => this.dragging = x);\r\n this._returnAssetDragAndDropService.draggingOver$.pipe(takeUntil(this._destroy$)).subscribe(x => this.draggingOver = this.dragulaElRef && (this.dragulaElRef.nativeElement === x));\r\n this._returnAssetDragAndDropService.dropped$.pipe(takeUntil(this._destroy$)).subscribe(x => {\r\n if (!this.dragulaElRef) { return; }\r\n const droppedOnMe = this.dragulaElRef.nativeElement === x.element;\r\n if (droppedOnMe) {\r\n this.assetsDropped.emit(x.draggedAssetIds);\r\n }\r\n });\r\n\r\n this._returnAssetDragAndDropService.active$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.isServiceActive = x);\r\n\r\n this._returnService.isReturnInReadOnlyMode$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.isReadOnly = x);\r\n\r\n this.isReadOnly = this._returnService.isReturnInReadOnlyMode;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n getOverlayTitle(): string {\r\n const description = this.scheduleDescription ? `(${this.scheduleDescription})` : '';\r\n if (this.depreciationTableLife) {\r\n return `${this.scheduleName} ${description}: ${this.depreciationTableLife} year life`;\r\n }\r\n return `${this.scheduleName} ${description}`;\r\n }\r\n}\r\n","import { Component, ElementRef, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport ScheduleGroupTypeEnum = Compliance.ScheduleGroupTypeEnum;\r\n\r\nexport interface ReturnAssetFilter {\r\n name: string;\r\n statuses: Compliance.ReturnAssetPriorReturnStatusEnum[];\r\n isDeduction: boolean;\r\n targetNonReportableSchedule?: boolean;\r\n targetReportableSchedule?: boolean;\r\n scheduleGroupType?: Compliance.ScheduleGroupTypeEnum\r\n}\r\n\r\n@Component({\r\n selector: 'return-asset-status-selector',\r\n templateUrl: './returnAssetStatusSelector.component.html',\r\n styleUrls: ['./returnAssetSelect.component.css'],\r\n})\r\nexport class ReturnAssetStatusSelectorComponent implements OnInit {\r\n allAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'All Assets at Lien Date',\r\n statuses: [],\r\n isDeduction: false\r\n };\r\n\r\n changedAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Changed',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.Changed],\r\n isDeduction: false\r\n };\r\n\r\n notChangedAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Not Changed',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.NotChanged],\r\n isDeduction: false\r\n };\r\n\r\n newAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Acquisitions',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.New],\r\n isDeduction: false\r\n };\r\n\r\n transferInAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Transfers In',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.TransferIn],\r\n isDeduction: false\r\n };\r\n\r\n newOrTransferInAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Acquisitions or Transfers In',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.New, Compliance.ReturnAssetPriorReturnStatusEnum.TransferIn],\r\n isDeduction: false\r\n };\r\n\r\n changedToReportedFilter: ReturnAssetFilter = {\r\n name: 'Changed to Reported',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.ChangedScheduleNonReportableToReportable],\r\n isDeduction: false\r\n };\r\n\r\n changedCostIncreasedAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Cost Increases',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.ChangedCostIncreased],\r\n isDeduction: false\r\n };\r\n\r\n allAdditionsAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Total Additions',\r\n statuses: [\r\n Compliance.ReturnAssetPriorReturnStatusEnum.New,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.TransferIn,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.ChangedCostIncreased,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.ChangedScheduleNonReportableToReportable\r\n ],\r\n isDeduction: false\r\n };\r\n\r\n disposedAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Disposals',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.Retired],\r\n isDeduction: true\r\n };\r\n\r\n transferOutAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Transfers Out',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.TransferOut],\r\n isDeduction: true\r\n };\r\n\r\n disposedOrTransferOutAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Disposals or Transfers Out',\r\n statuses: [\r\n Compliance.ReturnAssetPriorReturnStatusEnum.Retired,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.TransferOut],\r\n isDeduction: true\r\n };\r\n\r\n changedCostDecreasedAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Cost Decreases',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.ChangedCostDecreased],\r\n isDeduction: true,\r\n scheduleGroupType: ScheduleGroupTypeEnum.Unrestricted\r\n };\r\n\r\n changedToNotReportedFilter: ReturnAssetFilter = {\r\n name: 'Changed to Not Reported',\r\n statuses: [Compliance.ReturnAssetPriorReturnStatusEnum.ChangedScheduleReportableToNonReportable],\r\n isDeduction: true,\r\n targetReportableSchedule: false,\r\n targetNonReportableSchedule: true\r\n };\r\n\r\n allDeductionsAssetStatusFilter: ReturnAssetFilter = {\r\n name: 'Total Deductions',\r\n statuses: [\r\n Compliance.ReturnAssetPriorReturnStatusEnum.Retired,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.TransferOut,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.ChangedCostDecreased,\r\n Compliance.ReturnAssetPriorReturnStatusEnum.ChangedScheduleReportableToNonReportable\r\n ],\r\n isDeduction: true\r\n };\r\n\r\n assetAdditionsStatusFilter: ReturnAssetFilter[] = [\r\n this.newAssetStatusFilter,\r\n this.transferInAssetStatusFilter,\r\n this.newOrTransferInAssetStatusFilter,\r\n this.changedCostIncreasedAssetStatusFilter,\r\n this.changedToReportedFilter,\r\n this.allAdditionsAssetStatusFilter\r\n ];\r\n\r\n assetDeductionsStatusFilter: ReturnAssetFilter[] = [\r\n this.disposedAssetStatusFilter,\r\n this.transferOutAssetStatusFilter,\r\n this.disposedOrTransferOutAssetStatusFilter,\r\n this.changedCostDecreasedAssetStatusFilter,\r\n this.changedToNotReportedFilter,\r\n this.allDeductionsAssetStatusFilter\r\n ];\r\n\r\n assetStatusFilters: ReturnAssetFilter[] = [\r\n this.allAssetStatusFilter,\r\n this.changedAssetStatusFilter,\r\n this.notChangedAssetStatusFilter\r\n ].concat(this.assetAdditionsStatusFilter).concat(this.assetDeductionsStatusFilter);\r\n\r\n @Input() isDisabled: boolean = false;\r\n @Input() selectedValue: Compliance.ReturnAssetPriorReturnStatusEnum[];\r\n @Input() selectDeductions: boolean = false;\r\n\r\n @Input() reportDataSource: string = null;\r\n\r\n @Input() allowFilteringItemsBasedOnDataSource: boolean = false;\r\n\r\n @Output() selectedValueChange: EventEmitter = new EventEmitter();\r\n\r\n @ViewChild('selectedAssetStatusFilterEl', { static: true }) selectedAssetStatusFilterEl: ElementRef;\r\n\r\n selectedFilterValue: ReturnAssetFilter = this.assetStatusFilters[0];\r\n\r\n disableDeductionsDisposalsOrTransferOuts: boolean = false;\r\n disableDeductionsOtherThanDisposalsAndTransferOutOrTotalDeductions: boolean = false;\r\n\r\n ngOnInit(): void {\r\n\r\n if (!this.selectedValue) {\r\n this.selectedFilterValue = this.assetStatusFilters[0];\r\n this.selectedValueChange.emit(this.selectedFilterValue);\r\n } else {\r\n this.selectedFilterValue = this.assetStatusFilters.find(item => _.isEqual(item.statuses, this.selectedValue))\r\n }\r\n\r\n this.setOptionsToSuppress();\r\n }\r\n\r\n onSelectedAssetStatusFilterChange(filter: ReturnAssetFilter): void {\r\n // when select deductions in disabled prevent selecting the item (but emit event so modal can be displayed)\r\n if (!filter.isDeduction) {\r\n this.selectedFilterValue = filter;\r\n } else {\r\n if (this.selectDeductions) {\r\n this.selectedFilterValue = filter;\r\n }\r\n\r\n // select previously selected filter in the UI\r\n this.selectedAssetStatusFilterEl.nativeElement.selectedIndex = this.assetStatusFilters.indexOf(this.selectedFilterValue);\r\n }\r\n\r\n this.selectedValueChange.emit(filter);\r\n }\r\n\r\n private setOptionsToSuppress()\r\n {\r\n const additionalAssetDetails = 'AdditionalAssetDetails';\r\n const disposedAssetDetails = 'DisposedAssetDetails';\r\n const assetDetails = 'AssetDetails';\r\n const nonReportableAssetDetails = 'NonReportableAssetDetails';\r\n const assetSummary = 'AssetSummary';\r\n\r\n this.disableDeductionsDisposalsOrTransferOuts =\r\n this.reportDataSource == additionalAssetDetails ||\r\n this.reportDataSource == assetDetails ||\r\n this.reportDataSource == nonReportableAssetDetails ||\r\n this.reportDataSource == assetSummary;\r\n\r\n this.disableDeductionsOtherThanDisposalsAndTransferOutOrTotalDeductions =\r\n this.reportDataSource == disposedAssetDetails;\r\n }\r\n}\r\n","
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ transferOutAssetStatusFilter.name }}\r\n {{ disposedOrTransferOutAssetStatusFilter.name }}\r\n \r\n {{ changedToNotReportedFilter.name }}\r\n {{ allDeductionsAssetStatusFilter.name }}\r\n \r\n\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { Subscription } from 'rxjs';\r\nimport { ReturnService } from '../../../../return.service';\r\nimport { ReturnAssetsService } from '../../returnAssets.service';\r\nimport { IReturnPartComponent } from '../../../../Models/returnPartServiceBase';\r\nimport { ReturnAssetFilter } from '../../Asset-Status-Selector/returnAssetStatusSelector.component';\r\nimport { ReturnAssetDisposalsListComponent, ReturnAssetDisposalsListParams } from '../../Asset-Disposals-List/returnAssetDisposalsList.component';\r\nimport { WeissmanModalService } from '../../../../../WeissmanModalService';\r\n\r\n@Component({\r\n selector: 'return-asset-form-status-selector',\r\n templateUrl: './returnAssetFormStatusSelector.component.html'\r\n})\r\nexport class ReturnAssetFormStatusSelectorComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor (\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _modalService: WeissmanModalService) { }\r\n\r\n private _assessorFactorSub: Subscription;\r\n\r\n get isActive(): boolean {\r\n return this._returnAssetsService.isActive;\r\n }\r\n\r\n selectedAssetStatusFilter: Compliance.ReturnAssetPriorReturnStatusEnum[];\r\n\r\n ngOnInit(): void {\r\n this._returnAssetsService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnAssetsService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n this.selectedAssetStatusFilter = this._returnAssetsService.sharedState.assetStatusesFilter;\r\n this._assessorFactorSub = this._returnAssetsService.assessorFactorsFilter$.subscribe(() => this._refreshAssetStatusFilter());\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._assessorFactorSub && this._assessorFactorSub.unsubscribe();\r\n }\r\n\r\n async onSelectedAssetStatusFilterChange(filter: ReturnAssetFilter): Promise {\r\n if (filter.isDeduction) {\r\n const params: ReturnAssetDisposalsListParams = {\r\n title: filter.name,\r\n priorReturnStatuses: filter.statuses,\r\n formRevisionScheduleId: null,\r\n targetNonReportableSchedule: filter.targetNonReportableSchedule === null || filter.targetNonReportableSchedule === undefined ||\r\n filter.targetNonReportableSchedule,\r\n targetReportableSchedule: filter.targetReportableSchedule === null || filter.targetReportableSchedule === undefined ||\r\n filter.targetReportableSchedule,\r\n isDisposalOrTransferOut: false,\r\n scheduleGroupType: filter.scheduleGroupType\r\n };\r\n\r\n await this._modalService.showAsync(ReturnAssetDisposalsListComponent, params, 'modal-xl');\r\n }\r\n else {\r\n this.selectedAssetStatusFilter = filter.statuses;\r\n this._returnAssetsService.setAssetStatusesFilter(this.selectedAssetStatusFilter);\r\n }\r\n }\r\n\r\n private async _refreshAssetStatusFilter(): Promise {\r\n this._returnAssetsService.setAssetStatusesFilter(this.selectedAssetStatusFilter);\r\n }\r\n}\r\n","
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { of, pairwise, Subject } from 'rxjs';\r\nimport { switchMap, takeUntil } from 'rxjs/operators';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../../../../../Busy-Indicator';\r\nimport { ReturnUpdateLogicService } from '../../../../returnUpdateLogic.service';\r\nimport { ReturnAssetsService, AssessorFactorsFilter, AssessorFactorsEnum } from '../../returnAssets.service';\r\nimport { IReturnPartComponent } from '../../../../Models/returnPartServiceBase';\r\n\r\n@Component({\r\n selector: 'return-asset-form-factor-selector',\r\n templateUrl: './returnAssetFormFactorSelector.component.html'\r\n})\r\nexport class ReturnAssetFormFactorSelectorComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService,\r\n private readonly _busyIndicatorService: BusyIndicatorService\r\n ) {\r\n }\r\n\r\n assessorFilters: Compliance.FormRevisionAssessorModel[] = [];\r\n selectedAssessorFilter: Compliance.FormRevisionAssessorModel;\r\n\r\n private readonly _ANY_ASSESSOR_OPTION: Compliance.FormRevisionAssessorModel = {\r\n assessorName: 'Any Assessor',\r\n assessorId: AssessorFactorsEnum.AnyAssessor,\r\n isMappingCertified: null,\r\n isUsingDefaultMappings: null,\r\n isUsingDefaultTables: null\r\n } as Compliance.FormRevisionAssessorModel;\r\n\r\n private readonly _DEFAULT_ASSESSORS_OPTION: Compliance.FormRevisionAssessorModel = {\r\n assessorName: 'State-Provided Factor Tables',\r\n assessorId: AssessorFactorsEnum.AssessorsUsingDefaultFactors,\r\n isMappingCertified: null,\r\n isUsingDefaultMappings: null,\r\n isUsingDefaultTables: null\r\n } as Compliance.FormRevisionAssessorModel;\r\n\r\n // keep track of all the assessors for the selected form revision\r\n private _selectedFormRevisionAssessors: Compliance.FormRevisionAssessorModel[] = [];\r\n\r\n private _busyRef: BusyIndicatorRef;\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._returnAssetsService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._returnAssetsService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n this._returnUpdateLogicService.returnAssessors$.pipe(\r\n takeUntil(this._destroy$),\r\n pairwise(),\r\n switchMap(([prev, current]) => {\r\n return of((prev === current)\r\n ? this._autoSelectAssessorFilter()\r\n : this._refreshAssessors(current));\r\n })).subscribe();\r\n\r\n this._returnUpdateLogicService.loading$.pipe(takeUntil(this._destroy$))\r\n .subscribe((loading) => {\r\n if (loading) {\r\n this._busyRef = this._busyIndicatorService.show({ message: 'Loading Factors' });\r\n } else {\r\n if (this._busyRef) {\r\n this._busyRef.hide();\r\n }\r\n }\r\n });\r\n\r\n await this._returnUpdateLogicService.refreshAssessors();\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._destroy$.next();\r\n if (this._busyRef) {\r\n this._busyRef.hide();\r\n }\r\n }\r\n\r\n onSelectedAssessorFilterChange(): void {\r\n const filter = this._getAssessorFactorsFilterFromSelectedAssessor();\r\n this._returnAssetsService.setAssessorFactorsFilter(filter.assessorFactor, filter.assessorIds);\r\n }\r\n\r\n private _refreshAssessors(assessors: Compliance.FormRevisionAssessorModel[]): void {\r\n this.selectedAssessorFilter = this._ANY_ASSESSOR_OPTION;\r\n\r\n if (!assessors?.length) {\r\n this._selectedFormRevisionAssessors = [];\r\n this.assessorFilters = [];\r\n }\r\n\r\n // the api brings back the FRYA record for the default assessor\r\n // we do not care about it here so ignoring it\r\n this._selectedFormRevisionAssessors = assessors.filter(x => x.assessorId !== null);\r\n\r\n // reset assessor filters to empty array; the following logic will populate them\r\n this.assessorFilters = [];\r\n\r\n // if no assessor then select \"Any\" as the default option\r\n // if there are assessors then check how many\r\n // option 1: there is only one assessor so just make available that one assessor\r\n // if that assessor uses default tables then only make available the \"Default assessors\" option\r\n // option 2: there are multiple assessors then:\r\n // if there is more than one assessor that uses custom tables or one with custom tables and any assessor with default make available the \"Any\" option\r\n // make available any assessors that use custom tables\r\n // if there are assessors using default tables then make available the \"Default assessors\" options\r\n if (this._selectedFormRevisionAssessors.length) {\r\n if (this._selectedFormRevisionAssessors.length > 1) {\r\n // multiple assessors, examine the collection\r\n const assessorsThatUseDefaultTables = this._selectedFormRevisionAssessors.filter(x => x.isUsingDefaultTables);\r\n const assessorsThatUseCustomTables = this._selectedFormRevisionAssessors.filter(x => !x.isUsingDefaultTables);\r\n\r\n // if we have more than one assessor that uses custom tables or just one but a mix of assessors that use default tables, expose \"Any\"\r\n if (assessorsThatUseCustomTables.length > 1 || (assessorsThatUseCustomTables.length === 1 && assessorsThatUseDefaultTables.length)) {\r\n this.assessorFilters = this.assessorFilters.concat(this._ANY_ASSESSOR_OPTION);\r\n }\r\n\r\n // always show assessors that use custom tables\r\n this.assessorFilters = this.assessorFilters.concat(assessorsThatUseCustomTables);\r\n\r\n // if any assessor use default tables, show the default tables option\r\n if (assessorsThatUseDefaultTables.length) {\r\n this.assessorFilters = this.assessorFilters.concat(this._DEFAULT_ASSESSORS_OPTION);\r\n }\r\n } else {\r\n // only one assessor; if using default tables show the default tables option, otherwise show the actual assessor\r\n this.assessorFilters = this._selectedFormRevisionAssessors[0].isUsingDefaultTables ?\r\n this.assessorFilters.concat(this._DEFAULT_ASSESSORS_OPTION) :\r\n this.assessorFilters.concat(this._selectedFormRevisionAssessors);\r\n }\r\n } else {\r\n // no assessors, default \"Any\"\r\n this.assessorFilters = this.assessorFilters.concat(this._ANY_ASSESSOR_OPTION);\r\n }\r\n\r\n const filter = this._returnAssetsService.sharedState.assessorFactorsFilter;\r\n const assessor = filter &&\r\n this.assessorFilters.find(x => x.assessorId === ((filter.assessorFactor < 0) ? filter.assessorFactor : filter.assessorIds[0]));\r\n\r\n this.selectedAssessorFilter = assessor || this.assessorFilters[0];\r\n\r\n this._autoSelectAssessorFilter();\r\n }\r\n\r\n private _autoSelectAssessorFilter(): void {\r\n if (this.selectedAssessorFilter) {\r\n this.onSelectedAssessorFilterChange();\r\n }\r\n }\r\n\r\n private _getAssessorFactorsFilterFromSelectedAssessor(): AssessorFactorsFilter {\r\n switch (this.selectedAssessorFilter.assessorId) {\r\n case AssessorFactorsEnum.AnyAssessor:\r\n return {\r\n assessorFactor: AssessorFactorsEnum.AnyAssessor,\r\n assessorIds: []\r\n };\r\n\r\n case AssessorFactorsEnum.AssessorsUsingDefaultFactors:\r\n return {\r\n assessorFactor: AssessorFactorsEnum.AssessorsUsingDefaultFactors,\r\n assessorIds: this._selectedFormRevisionAssessors.filter(x => x.isUsingDefaultTables).map(x => x.assessorId)\r\n };\r\n\r\n default:\r\n return {\r\n assessorFactor: AssessorFactorsEnum.SpecificAssessor,\r\n assessorIds: [this.selectedAssessorFilter.assessorId]\r\n };\r\n }\r\n }\r\n}\r\n","\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
{{ schedule.name }} {{ schedule.description ? '(' + schedule.description + ')' : '' }}
\r\n
{{ schedule.depreciationTableName}} ({{ schedule.depreciationTableLife }} year life)
\r\n
\r\n
\r\n
\r\n
Assets
\r\n
{{ (schedule.assetCount || 0) | number }}
\r\n
\r\n
\r\n
Cost
\r\n
{{ (schedule.cost || 0) | currency: 'USD' : 'symbol' }}
\r\n
\r\n
\r\n
Value
\r\n
\r\n {{ (schedule.reportedValue || 0) | currency: 'USD' : 'symbol' }}\r\n N/A\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Sch. YearAssetsCostFactorRep. Value
{{ detail.year }}{{ detail.assetCount | number }}{{ (detail.cost || 0) | currency: 'USD' : 'symbol' }}{{ (detail.depreciationFactor * 100) | number: '1.2-5' }}{{ (detail.reportedValue || 0) | currency: 'USD' : 'symbol' }}
Total{{ (schedule.assetCount || 0) | number }}{{ (schedule.cost || 0) | currency: 'USD' : 'symbol' }}{{ (schedule.reportedValue || 0) | currency: 'USD' : 'symbol' }}
\r\n
\r\n
\r\n","import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';\r\nimport { ScheduleAndFactorFilter } from '../../returnAssets.service';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'return-asset-form-schedule',\r\n templateUrl: './returnAssetFormSchedule.component.html',\r\n styleUrls: ['./returnAssetFormSchedule.component.scss']\r\n})\r\nexport class ReturnAssetFormScheduleComponent implements OnInit {\r\n @Input() canExpand: boolean;\r\n @Input() schedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel;\r\n @Input() scheduleDetails: Compliance.ReturnAssetScheduleDetailsAssignedItemModel[];\r\n @Input() scheduleForUnassignedAssets: boolean = false;\r\n @Input() scheduleForNonReportableAssets: boolean = false;\r\n @Input() scheduleForReportableAssets: boolean = false;\r\n @Input() scheduleAndFactorFilter: ScheduleAndFactorFilter;\r\n\r\n @Output() scheduleClick: EventEmitter = new EventEmitter();\r\n @Output() scheduleAgeClick: EventEmitter = new EventEmitter();\r\n\r\n isBusy: boolean = false;\r\n isExpanded: boolean = false;\r\n scheduleFilterId: number;\r\n\r\n ngOnInit(): void {\r\n if (this.scheduleForUnassignedAssets || this.scheduleForNonReportableAssets || this.scheduleForReportableAssets) {\r\n return;\r\n }\r\n\r\n // group schedule detail information by schedule and year (it will be coming in in a more granular form)\r\n const groupedScheduleDetails: Compliance.ReturnAssetScheduleDetailsAssignedItemModel[] = [];\r\n this.scheduleDetails\r\n .filter(x => x.assetCount > 0)\r\n .forEach(x => {\r\n const schedule = groupedScheduleDetails.find(y => x.formRevisionScheduleId === y.formRevisionScheduleId && x.year === y.year);\r\n if (schedule) {\r\n schedule.assetCount += x.assetCount;\r\n schedule.priorReportedValue += x.priorReportedValue;\r\n schedule.priorCost += x.priorCost;\r\n schedule.additions += x.additions;\r\n schedule.disposals += x.disposals;\r\n schedule.cost += x.cost;\r\n schedule.reportedValue += x.reportedValue;\r\n } else {\r\n groupedScheduleDetails.push({\r\n formRevisionId: x.formRevisionId,\r\n formRevisionScheduleId: x.formRevisionScheduleId,\r\n abbr: x.abbr,\r\n name: x.name,\r\n description: x.description,\r\n year: x.year,\r\n age: x.age,\r\n isTaxable: x.isTaxable,\r\n isReportable: x.isReportable,\r\n isDepreciable: x.isDepreciable,\r\n isSystem: x.isSystem,\r\n depreciationTableId: x.depreciationTableId,\r\n depreciationTableLife: x.depreciationTableLife,\r\n depreciationTableName: x.depreciationTableName,\r\n depreciationFactor: x.depreciationFactor,\r\n assetCount: x.assetCount,\r\n priorCost: x.priorCost,\r\n priorReportedValue: x.priorReportedValue,\r\n additions: x.additions,\r\n disposals: x.disposals,\r\n cost: x.cost,\r\n exemptCost: x.exemptCost,\r\n reportedValue: x.reportedValue,\r\n lockedAssessors: x.lockedAssessors\r\n });\r\n }\r\n });\r\n this.scheduleDetails = groupedScheduleDetails;\r\n }\r\n\r\n isScheduleActive(): boolean {\r\n return (this.scheduleForUnassignedAssets && this.scheduleAndFactorFilter.showOnlyNotAssignedToASchedule) ||\r\n (this.scheduleForNonReportableAssets && this.scheduleAndFactorFilter.showOnlyAssignedToNonReportableSchedule) ||\r\n (this.scheduleForReportableAssets && this.scheduleAndFactorFilter.showOnlyAssignedToReportableSchedule) ||\r\n (\r\n !this.scheduleForUnassignedAssets &&\r\n !this.scheduleForNonReportableAssets &&\r\n !this.scheduleForReportableAssets &&\r\n _.isEqual(this.scheduleAndFactorFilter.formRevisionScheduleIds, this.schedule.formRevisionScheduleId ? [this.schedule.formRevisionScheduleId] : []) &&\r\n this.scheduleAndFactorFilter.depreciationFactorId === (this.schedule && this.schedule.depreciationTableId)\r\n );\r\n }\r\n\r\n isScheduleDetailActive(scheduleDetail: Compliance.ReturnAssetScheduleDetailsAssignedItemModel): boolean {\r\n return this.isScheduleActive() && this.scheduleAndFactorFilter.scheduleAge === scheduleDetail.age;\r\n }\r\n\r\n toggleIsExpanded(event: Event): void {\r\n event.stopPropagation();\r\n this.isExpanded = !this.isExpanded;\r\n }\r\n\r\n onScheduleClicked(event: Event): void {\r\n event.stopPropagation();\r\n this.scheduleClick.emit({\r\n showOnlyNotAssignedToASchedule: this.scheduleForUnassignedAssets,\r\n showOnlyAssignedToNonReportableSchedule: this.scheduleForNonReportableAssets,\r\n showOnlyAssignedToReportableSchedule: this.scheduleForReportableAssets,\r\n formRevisionScheduleIds: this.schedule.formRevisionScheduleId ? [this.schedule.formRevisionScheduleId] : [],\r\n depreciationFactorId: this.schedule.depreciationTableId,\r\n scheduleAge: null,\r\n userSelectedEmptySchedule: !this.schedule.assetCount\r\n });\r\n }\r\n\r\n onScheduleDetailClicked(event: Event, scheduleDetail: Compliance.ReturnAssetScheduleDetailsAssignedItemModel): void {\r\n event.stopPropagation();\r\n this.scheduleAgeClick.emit({\r\n showOnlyNotAssignedToASchedule: this.scheduleForUnassignedAssets,\r\n showOnlyAssignedToNonReportableSchedule: this.scheduleForNonReportableAssets,\r\n showOnlyAssignedToReportableSchedule: this.scheduleForReportableAssets,\r\n formRevisionScheduleIds: this.schedule.formRevisionScheduleId ? [this.schedule.formRevisionScheduleId] : [],\r\n depreciationFactorId: this.schedule.depreciationTableId,\r\n scheduleAge: scheduleDetail.age,\r\n userSelectedEmptySchedule: !this.schedule.assetCount\r\n });\r\n }\r\n}\r\n","
\r\n \r\n \r\n \r\n
\r\n\r\n
\r\n
\r\n Schedules\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n Reported\r\n
\r\n \r\n \r\n
\r\n\r\n\r\n
\r\n
\r\n Not Reported\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n\r\n
\r\n
\r\n Not Assigned to a Schedule\r\n
\r\n \r\n \r\n
\r\n","import { lastValueFrom, merge as observableMerge, Subject } from 'rxjs';\r\nimport { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport { BusyIndicatorService } from '../../../../../Busy-Indicator';\r\nimport { FormRepository, ReturnAssetRepository } from '../../../../Repositories';\r\nimport { ReturnAssetsService, ScheduleAndFactorFilter, AssessorFactorsEnum, ReturnAssetsServiceSharedState } from '../returnAssets.service';\r\nimport { AssessorTablePickerComponent, AssessorTablePickerParams, LockedAssessorAssignments, AssessorTablePickerResult } from '../Assessor-Table-Picker/assessorTablePicker.component';\r\nimport { IReturnPartComponent, ReturnPartServiceBase } from '../../../Models/returnPartServiceBase';\r\nimport { ReturnServiceSharedState, ReturnService } from '../../../return.service';\r\nimport { takeUntil } from 'rxjs/internal/operators/takeUntil';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { ReturnAssetDragAndDropService } from '../Drag-And-Drop/returnAssetDragAndDrop.service';\r\n\r\nimport * as _ from 'lodash';\r\n\r\ninterface IAggregatedSchedule {\r\n schedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel;\r\n scheduleDetails: Compliance.ReturnAssetScheduleDetailsAssignedItemModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'return-asset-form-details',\r\n templateUrl: './returnAssetFormDetails.component.html',\r\n styleUrls: ['./returnAssetFormDetails.component.scss']\r\n})\r\nexport class ReturnAssetFormDetailsComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _returnAssetRepository: ReturnAssetRepository,\r\n private readonly _returnAssetDragAndDropService: ReturnAssetDragAndDropService,\r\n private readonly _toastr: ToastrService\r\n ) { }\r\n\r\n private _localReturnServiceSharedState: ReturnServiceSharedState;\r\n private _localReturnAssetsServiceSharedState: ReturnAssetsServiceSharedState;\r\n private _scheduleData: Compliance.ReturnAssetScheduleDetailsAssignedItemModel[] = [];\r\n private _unassignedScheduleData: Compliance.ReturnAssetScheduleDetailsUnassignedItemModel[] = [];\r\n private _destroy$: Subject = new Subject();\r\n\r\n get hasSchedules(): boolean {\r\n return this._scheduleData && !!this._scheduleData.length;\r\n }\r\n\r\n scheduleAndFactorFilter: ScheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n\r\n get hideEmptySchedulesFilter(): boolean { return this._returnAssetsService.sharedState.hideEmptySchedulesFilter; }\r\n\r\n set hideEmptySchedulesFilter(value: boolean) { this._returnAssetsService.setHideEmptySchedulesFilter(value); }\r\n\r\n get separateFactorTablesFilter(): boolean { return this._returnAssetsService.sharedState.separateFactorTablesFilter; }\r\n\r\n set separateFactorTablesFilter(value: boolean) { this._returnAssetsService.setSeparateFactorTablesFilter(value); }\r\n\r\n get scheduleFilterEnabled(): boolean { return !!this._returnService.sharedState.formRevisionId; }\r\n\r\n separateFactorTablesFilterDisabled: boolean = false;\r\n\r\n aggregatedSchedules: IAggregatedSchedule[] = [];\r\n reportableSchedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel;\r\n nonReportableSchedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel;\r\n unassignedSchedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel;\r\n\r\n get returnPartServiceForInterPartComponent(): ReturnPartServiceBase { return this._returnAssetsService; }\r\n\r\n ngOnInit(): void {\r\n this._returnAssetsService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._returnAssetsService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n observableMerge(\r\n this._returnAssetsService.assetStatusesFilter$,\r\n this._returnAssetsService.assetMappingsUpdated$,\r\n this._returnAssetsService.assetDetailsUpdated$\r\n ).pipe(takeUntil(this._destroy$))\r\n .subscribe(() => {\r\n // if showing results from any assessor, the do not separate factor tables (as there will be multiple for each assessor)\r\n if (this._returnAssetsService.sharedState.assessorFactorsFilter.assessorFactor === AssessorFactorsEnum.AnyAssessor) {\r\n this.separateFactorTablesFilter = false;\r\n this.separateFactorTablesFilterDisabled = true;\r\n } else {\r\n this.separateFactorTablesFilterDisabled = false;\r\n }\r\n\r\n this._refreshSchedules();\r\n });\r\n\r\n this._returnAssetsService.requestUpdatedSchedules$.pipe(takeUntil(this._destroy$)).subscribe(async () => {\r\n await this._loadSchedules();\r\n this._applyFilters();\r\n });\r\n\r\n this._returnAssetsService.scheduleAndFactorFilter$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(filter => this.scheduleAndFactorFilter = filter);\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._destroy$.next();\r\n }\r\n\r\n /**\r\n * Checks to see if the form details component has any filters applied.\r\n * This is true if:\r\n * option 1: it is showing only unassigned assets and no other filters are selected\r\n * option 2: it is showing only assigned to non-reportable schedule\r\n * option 3: it is not showing only unassigned assets, not showing assets assigned to non-reportable schedule, and another filter is selected\r\n */\r\n hasFilters(): boolean {\r\n return this.scheduleAndFactorFilter.showOnlyNotAssignedToASchedule ||\r\n this.scheduleAndFactorFilter.showOnlyAssignedToNonReportableSchedule ||\r\n this.scheduleAndFactorFilter.showOnlyAssignedToReportableSchedule ||\r\n this.scheduleAndFactorFilter.formRevisionScheduleIds.length > 0 ||\r\n this.scheduleAndFactorFilter.depreciationFactorId !== null ||\r\n this.scheduleAndFactorFilter.scheduleAge !== null;\r\n }\r\n\r\n separateFactorTablesFilterChange(): void {\r\n this._applyFilters();\r\n }\r\n\r\n hideEmptySchedulesFilterChange(): void {\r\n this._applyFilters();\r\n }\r\n\r\n onScheduleAndFactorFilterClick(value: ScheduleAndFactorFilter): void {\r\n this.scheduleAndFactorFilter = value;\r\n this._returnAssetsService.setScheduleAndFactorFilter(this.scheduleAndFactorFilter);\r\n }\r\n\r\n onScheduleAgeFilterClick(value: ScheduleAndFactorFilter): void {\r\n this.scheduleAndFactorFilter = value;\r\n this._returnAssetsService.setScheduleAndFactorFilter(this.scheduleAndFactorFilter);\r\n }\r\n\r\n clearScheduleAndFactorFilter(): void {\r\n this.scheduleAndFactorFilter = {\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n };\r\n\r\n this._returnAssetsService.clearScheduleAndFactorFilter();\r\n }\r\n\r\n async onAssetsDropped(reportingAssetIds: number[], schedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel): Promise {\r\n if (schedule.isReportable === false || schedule.isTaxable === false || schedule.isDepreciable === false) {\r\n await this._updateNonReportable(reportingAssetIds, schedule);\r\n } else {\r\n let allAssessors: Compliance.FormRevisionAssessorModel[] = [];\r\n\r\n // We need the assessors whether or not we need the modal\r\n const busyRef = this._busyIndicatorService.show({ message: 'Processing Schedule Change' });\r\n try {\r\n allAssessors = await this._returnAssetsService.getAssessors(reportingAssetIds);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n const assessors = allAssessors.filter((assessor: Compliance.FormRevisionAssessorModel) => assessor.assessorId !== null);\r\n const assets = await this._returnAssetDragAndDropService.getSelectedAssets();\r\n const assetAssessors = assets.map(x => assessors.find(y => x.assessorAbbr === y.assessorName));\r\n const lockedAssessors = schedule.lockedAssessors.filter(la => la.isLocked);\r\n\r\n if (schedule.depreciationTableId && schedule.depreciationTableId !== null) {\r\n // we don't need to ask for factorId, we just need to go ahead and send the return\r\n await this._updateForExpandedScheduleDetail(reportingAssetIds, schedule, assessors);\r\n } else if (assets.length && schedule.lockedAssessors && assetAssessors.every(x => !!lockedAssessors.find(la => x.assessorId === la.assessorId))) {\r\n await this._updateLockedSchedule(reportingAssetIds, schedule, assessors, allAssessors);\r\n } else if (assets.length && schedule.lockedAssessors && assetAssessors.some(x => !!lockedAssessors.find(la => x.assessorId === la.assessorId))) {\r\n this._toastr.error('Cannot assign to this schedule as it contains a mix of locked and unlocked assessors.');\r\n } else {\r\n await this._askForFactorAndUpdate(reportingAssetIds, schedule, assessors, allAssessors);\r\n }\r\n }\r\n }\r\n\r\n private async _updateNonReportable(reportingAssetIds: number[], schedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel) {\r\n // the non reportable schedule should just get a single null assessor entry, with null depreciation and index\r\n const nullAssociationModel: Compliance.AssessorFactorTableAssociationModel = {\r\n assessorId: null,\r\n depreciationTableId: null,\r\n indexTableId: null\r\n };\r\n const updateModel: Compliance.ReturnAssetUpdateModel = {\r\n assessorFactorTableAssociations: [nullAssociationModel],\r\n formRevisionScheduleId: schedule.formRevisionScheduleId,\r\n reportingAssetIds: reportingAssetIds\r\n };\r\n await this._submitAssetUpdateModel(updateModel);\r\n }\r\n\r\n private async _updateForExpandedScheduleDetail(reportingAssetIds: number[], schedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel, assessors) {\r\n const selection = {}; // mirrors modal structure\r\n assessors.forEach((assessor: Compliance.FormRevisionAssessorModel) => {\r\n selection[assessor.assessorId] = {\r\n depreciationTableId: schedule.depreciationTableId,\r\n indexTableId: null\r\n };\r\n });\r\n\r\n const result: AssessorTablePickerResult = {\r\n selection: selection\r\n };\r\n\r\n // save assets with all assessors associated to factor table\r\n await this._updateAssets(reportingAssetIds, schedule.formRevisionScheduleId, result);\r\n }\r\n\r\n private async _updateLockedSchedule(reportingAssetIds: number[], schedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel, assessors, allAssessors) {\r\n const reportingAssetAssessorMap = await lastValueFrom(this._returnAssetRepository.getReportingAssetAssessorsByFilingBatch(this._returnService.filingBatchId, {\r\n reportingAssetIds: reportingAssetIds,\r\n formRevisionId: this._returnService.formRevisionId,\r\n parcelIds: []\r\n }));\r\n\r\n //Check to see if all are locked. If so, setup the update.\r\n const nullAssessor = schedule.lockedAssessors.find(x => x.assessorId === null);\r\n const areAllLocked = reportingAssetAssessorMap.every(raam => {\r\n let assessorAssignment = schedule.lockedAssessors.find(la => la.assessorId === raam.assessorId);\r\n if (!assessorAssignment) {\r\n assessorAssignment = nullAssessor;\r\n }\r\n return assessorAssignment.isLocked;\r\n });\r\n\r\n const selection: { [assessorId: number]: LockedAssessorAssignments } = {}; // mirrors modal structure\r\n reportingAssetAssessorMap.forEach((raam: Compliance.ReportingAssetAssessorModel) => {\r\n let assessorAssignment = schedule.lockedAssessors.find(la => la.assessorId === raam.assessorId);\r\n if (!assessorAssignment) {\r\n assessorAssignment = nullAssessor;\r\n }\r\n\r\n if (assessorAssignment.isLocked) {\r\n selection[raam.assessorId] = {\r\n depreciationTableId: assessorAssignment.depreciationFactorTableId,\r\n indexTableId: null\r\n };\r\n }\r\n });\r\n\r\n const result: AssessorTablePickerResult = {\r\n selection: selection\r\n };\r\n\r\n if (areAllLocked) {\r\n // save assets with all assessors associated to factor table\r\n await this._updateAssets(reportingAssetIds, schedule.formRevisionScheduleId, result);\r\n } else {\r\n // open dialog, with locked assets already assigned.\r\n await this._askForFactorAndUpdate(reportingAssetIds, schedule, assessors, allAssessors, selection);\r\n }\r\n }\r\n\r\n private async _askForFactorAndUpdate(\r\n reportingAssetIds: number[],\r\n schedule: Compliance.ReturnAssetScheduleDetailsAssignedItemModel,\r\n assessors,\r\n allAssessors,\r\n lockedAssessorAssignments: { [assessorId: number]: LockedAssessorAssignments } = {}): Promise {\r\n const model: Compliance.AssessorFactorTableSearchModel = {\r\n assessorIds: [].concat(assessors.map(assessor => assessor.assessorId)),\r\n formRevisionScheduleId: schedule.formRevisionScheduleId\r\n };\r\n\r\n let assessorFactorTableResult: Compliance.AssessorFactorTableModel[];\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading Factor Tables' });\r\n try {\r\n assessorFactorTableResult = await lastValueFrom(this._returnAssetRepository.getAssessorFactorTables(this._returnService.filingBatchId, model));\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n const assessorFactorTables = assessorFactorTableResult.filter(x => x.assessorId !== null && !x.isCompany);\r\n const defaultAssessorFactorTables = _.filter(assessorFactorTableResult, { assessorId: null, isCompany: false });\r\n const defaultFactorTables = defaultAssessorFactorTables ? _.flatMap(defaultAssessorFactorTables, x => x.factorTables) : [];\r\n const defaultAssessor = allAssessors.find((x: Compliance.FormRevisionAssessorModel) => x.assessorId === null);\r\n const companyDefaultAssessorTables = assessorFactorTableResult.filter(x => x.isCompany && x.assessorId === null);\r\n const companyAssessorTables = assessorFactorTableResult.filter(x => x.isCompany && x.assessorId !== null);\r\n\r\n const params: AssessorTablePickerParams = {\r\n defaultAssessor: defaultAssessor,\r\n reportingAssetIds: reportingAssetIds,\r\n assessors: assessors,\r\n defaultFactorTables: _.concat(_.flatMap(companyDefaultAssessorTables, x => x.factorTables), defaultFactorTables),\r\n assessorFactorTables: [...companyDefaultAssessorTables, ...companyAssessorTables, ...assessorFactorTables],\r\n lockedAssessorAssignments: lockedAssessorAssignments\r\n };\r\n\r\n const result = await this._modalService.showAsync(AssessorTablePickerComponent, params, 'modal-xl');\r\n\r\n if (result && result.selection) {\r\n await this._updateAssets(reportingAssetIds, schedule.formRevisionScheduleId, result);\r\n }\r\n }\r\n\r\n private async _refreshSchedules(): Promise {\r\n const returnServiceSharedState: ReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n const returnAssetsServiceSharedState: ReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n\r\n // get input parameters for comparison\r\n const localReturnIds = (this._localReturnServiceSharedState && this._localReturnServiceSharedState.returns && this._localReturnServiceSharedState.returns.map(x => x.returnId)) || [];\r\n const sharedReturnIds = returnServiceSharedState.returns.map(x => x.returnId);\r\n\r\n const localFormRevisionId = this._localReturnServiceSharedState && this._localReturnServiceSharedState.formRevisionId;\r\n const sharedFormRevisionId = returnServiceSharedState.formRevisionId;\r\n\r\n const localAssetStatusFilter = (this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetStatusesFilter) || [];\r\n const sharedAssetStatusFilter = returnAssetsServiceSharedState.assetStatusesFilter;\r\n\r\n const localAssessorFactors = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assessorFactorsFilter;\r\n const sharedAssessorFactors = returnAssetsServiceSharedState.assessorFactorsFilter;\r\n\r\n const localAssetDetailsUpdatedTimestamp = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n const sharedAssetDetailsUpdatedTimestamp = returnAssetsServiceSharedState.assetDetailsUpdatedTimestamp;\r\n\r\n const localAssetMappingsUpdatedTimestamp = this._localReturnAssetsServiceSharedState && this._localReturnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n const sharedAssetMappingsUpdatedTimestamp = returnAssetsServiceSharedState.assetMappingsUpdatedTimestamp;\r\n\r\n // check to see if the input parameters are available\r\n if (!sharedReturnIds || !sharedFormRevisionId || !sharedAssetStatusFilter || !sharedAssessorFactors) {\r\n this._blankSchedules();\r\n }\r\n\r\n // check to see if the input parameters have changed\r\n if (\r\n !_.isEqual(localReturnIds, sharedReturnIds) ||\r\n !_.isEqual(localFormRevisionId, sharedFormRevisionId) ||\r\n !_.isEqual(localAssetStatusFilter, sharedAssetStatusFilter) ||\r\n !_.isEqual(localAssessorFactors, sharedAssessorFactors) ||\r\n !_.isEqual(localAssetDetailsUpdatedTimestamp, sharedAssetDetailsUpdatedTimestamp) ||\r\n !_.isEqual(localAssetMappingsUpdatedTimestamp, sharedAssetMappingsUpdatedTimestamp)\r\n ) {\r\n await this._loadSchedules();\r\n }\r\n\r\n this._applyFilters();\r\n }\r\n\r\n private _blankSchedules(): void {\r\n this._persistState();\r\n\r\n this._scheduleData = [];\r\n this._unassignedScheduleData = [];\r\n }\r\n\r\n private _persistState(): void {\r\n this._localReturnServiceSharedState = this._returnService.getSharedStateClone();\r\n this._localReturnAssetsServiceSharedState = this._returnAssetsService.getSharedStateClone();\r\n }\r\n\r\n private async _loadSchedules(): Promise {\r\n this._persistState();\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading Schedules' });\r\n try {\r\n const responses = await Promise.all([\r\n this._returnAssetsService.getScheduleDetails(),\r\n this._returnAssetsService.getUnassignedScheduleDetails()\r\n ]);\r\n this._scheduleData = responses[0] as Compliance.ReturnAssetScheduleDetailsAssignedItemModel[];\r\n this._unassignedScheduleData = responses[1] as Compliance.ReturnAssetScheduleDetailsUnassignedItemModel[];\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _applyFilters(): void {\r\n // get \"schedule\" for assets that are unassigned to a schedule\r\n const unassignedSchedule = {\r\n assetCount: 0,\r\n cost: 0,\r\n reportedValue: 0,\r\n depreciationTableId: null,\r\n depreciationTableName: null,\r\n formRevisionScheduleId: null\r\n } as Compliance.ReturnAssetScheduleDetailsAssignedItemModel;\r\n\r\n this._unassignedScheduleData.forEach(x => {\r\n unassignedSchedule.assetCount = x.assetCount;\r\n unassignedSchedule.cost = x.cost;\r\n });\r\n\r\n // get non-reportable system schedule\r\n const nonReportableSchedule = {\r\n assetCount: 0,\r\n cost: 0,\r\n reportedValue: 0,\r\n depreciationTableId: null,\r\n depreciationTableName: null,\r\n formRevisionId: this._localReturnServiceSharedState.formRevisionId,\r\n formRevisionScheduleId: null,\r\n isReportable: false,\r\n isDepreciable: false,\r\n isTaxable: false\r\n } as Compliance.ReturnAssetScheduleDetailsAssignedItemModel;\r\n\r\n this._scheduleData\r\n .filter(x => !x.isReportable)\r\n .forEach(x => {\r\n // there should only be one non-reportable schedule; make sure to set ID here as it will be needed for when assets drag-and-drop on this schedule\r\n nonReportableSchedule.formRevisionScheduleId = x.formRevisionScheduleId;\r\n nonReportableSchedule.assetCount += x.assetCount;\r\n nonReportableSchedule.cost += x.cost;\r\n });\r\n\r\n // get schedule groups for assets that are assigned to a schedule\r\n const reportableSchedules: Compliance.ReturnAssetScheduleDetailsAssignedItemModel[] = [];\r\n this._scheduleData\r\n .filter(x => x.formRevisionScheduleId !== null && x.isReportable)\r\n .forEach(i => {\r\n // filter: separate factor tables (schedule and factor information comes in as separate)\r\n const schedule = this.separateFactorTablesFilter\r\n ? reportableSchedules.find(x => x.formRevisionScheduleId === i.formRevisionScheduleId && x.depreciationTableId === i.depreciationTableId)\r\n : reportableSchedules.find(x => x.formRevisionScheduleId === i.formRevisionScheduleId);\r\n\r\n if (schedule) {\r\n // schedule exists, roll factor table information into it\r\n schedule.assetCount += i.assetCount;\r\n schedule.priorReportedValue += i.priorReportedValue;\r\n schedule.priorCost += i.priorCost;\r\n schedule.additions += i.additions;\r\n schedule.disposals += i.disposals;\r\n schedule.cost += i.cost;\r\n schedule.reportedValue += i.reportedValue;\r\n } else {\r\n // schedule does not exist, add to collection without factor table information\r\n reportableSchedules.push({\r\n formRevisionId: i.formRevisionId,\r\n formRevisionScheduleId: i.formRevisionScheduleId,\r\n abbr: i.abbr,\r\n name: i.name,\r\n description: i.description,\r\n year: i.year,\r\n age: i.age,\r\n isTaxable: i.isTaxable,\r\n isReportable: i.isReportable,\r\n isDepreciable: i.isDepreciable,\r\n isSystem: i.isSystem,\r\n depreciationTableId: this.separateFactorTablesFilter ? i.depreciationTableId : null,\r\n depreciationTableLife: this.separateFactorTablesFilter ? i.depreciationTableLife : null,\r\n depreciationTableName: this.separateFactorTablesFilter ? i.depreciationTableName : null,\r\n depreciationFactor: this.separateFactorTablesFilter ? i.depreciationFactor : null,\r\n assetCount: i.assetCount,\r\n priorCost: i.priorCost,\r\n priorReportedValue: i.priorReportedValue,\r\n additions: i.additions,\r\n disposals: i.disposals,\r\n cost: i.cost,\r\n exemptCost: i.exemptCost,\r\n reportedValue: i.reportedValue,\r\n lockedAssessors: i.lockedAssessors\r\n });\r\n }\r\n });\r\n\r\n // get totals for all assets being reported\r\n const reportableSchedule = {\r\n assetCount: 0,\r\n cost: 0,\r\n reportedValue: 0,\r\n isReportable: true,\r\n depreciationTableId: null,\r\n depreciationTableName: null,\r\n formRevisionScheduleId: null\r\n } as Compliance.ReturnAssetScheduleDetailsAssignedItemModel;\r\n\r\n reportableSchedules.forEach(i => {\r\n reportableSchedule.assetCount += i.assetCount;\r\n reportableSchedule.priorReportedValue += i.priorReportedValue;\r\n reportableSchedule.priorCost += i.priorCost;\r\n reportableSchedule.additions += i.additions;\r\n reportableSchedule.disposals += i.disposals;\r\n reportableSchedule.cost += i.cost;\r\n reportableSchedule.reportedValue += i.reportedValue;\r\n });\r\n\r\n // filter: hide empty schedules\r\n if (this.hideEmptySchedulesFilter) {\r\n let i = reportableSchedules.length;\r\n while (i--) {\r\n if (reportableSchedules[i].assetCount === 0) {\r\n reportableSchedules.splice(i, 1);\r\n }\r\n }\r\n }\r\n\r\n // set values\r\n this.unassignedSchedule = unassignedSchedule;\r\n this.reportableSchedule = reportableSchedule;\r\n this.nonReportableSchedule = nonReportableSchedule;\r\n this.aggregatedSchedules = _.chain(reportableSchedules)\r\n .map(x => ({\r\n schedule: x,\r\n scheduleDetails: this.separateFactorTablesFilter\r\n ? this._scheduleData.filter(y => y.formRevisionScheduleId === x.formRevisionScheduleId && y.depreciationTableId === x.depreciationTableId)\r\n : this._scheduleData.filter(y => y.formRevisionScheduleId === x.formRevisionScheduleId)\r\n } as IAggregatedSchedule))\r\n .orderBy([(x) => x.schedule.name, (x) => x.schedule.depreciationTableLife])\r\n .value();\r\n\r\n // auto-select the schedule/factor\r\n if (this.scheduleAndFactorFilter.showOnlyNotAssignedToASchedule) {\r\n this.onScheduleAndFactorFilterClick({\r\n showOnlyNotAssignedToASchedule: true,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n });\r\n } else if (this.scheduleAndFactorFilter.showOnlyAssignedToNonReportableSchedule) {\r\n this.onScheduleAgeFilterClick({\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: true,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: this.nonReportableSchedule.formRevisionScheduleId ? [this.nonReportableSchedule.formRevisionScheduleId] : [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n });\r\n } else if (this.scheduleAndFactorFilter.showOnlyAssignedToReportableSchedule) {\r\n this.onScheduleAgeFilterClick({\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: true,\r\n formRevisionScheduleIds: [],\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n });\r\n } else {\r\n const aggregatedSchedule = this.aggregatedSchedules.find(x =>\r\n _.isEqual([x.schedule.formRevisionScheduleId], this._returnAssetsService.sharedState.scheduleAndFactorFilter.formRevisionScheduleIds) &&\r\n x.schedule.depreciationTableId === this._returnAssetsService.sharedState.scheduleAndFactorFilter.depreciationFactorId);\r\n\r\n if (aggregatedSchedule) {\r\n this.onScheduleAgeFilterClick({\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: [aggregatedSchedule.schedule.formRevisionScheduleId],\r\n depreciationFactorId: aggregatedSchedule.schedule.depreciationTableId,\r\n scheduleAge: null\r\n });\r\n } else {\r\n this.onScheduleAgeFilterClick({\r\n showOnlyNotAssignedToASchedule: false,\r\n showOnlyAssignedToNonReportableSchedule: false,\r\n showOnlyAssignedToReportableSchedule: false,\r\n formRevisionScheduleIds: this._returnAssetsService.sharedState.scheduleAndFactorFilter.formRevisionScheduleIds,\r\n depreciationFactorId: null,\r\n scheduleAge: null\r\n });\r\n }\r\n }\r\n }\r\n\r\n private async _updateAssets(assetIds: number[], formScheduleId: number, assessorPickerResult: AssessorTablePickerResult): Promise {\r\n // build the assessor-factor association model that the API expects\r\n const assessorFactorTableAssociationModel: Compliance.AssessorFactorTableAssociationModel[] = [];\r\n\r\n for (const key in assessorPickerResult.selection) {\r\n if (assessorPickerResult.selection.hasOwnProperty(key)) {\r\n assessorFactorTableAssociationModel.push({\r\n assessorId: parseInt(key),\r\n depreciationTableId: assessorPickerResult.selection[key].depreciationTableId,\r\n indexTableId: assessorPickerResult.selection[key].indexTableId\r\n });\r\n }\r\n }\r\n\r\n // build the update model\r\n const updateModel: Compliance.ReturnAssetUpdateModel = {\r\n formRevisionScheduleId: formScheduleId,\r\n reportingAssetIds: assetIds,\r\n assessorFactorTableAssociations: assessorFactorTableAssociationModel\r\n };\r\n\r\n this._submitAssetUpdateModel(updateModel);\r\n }\r\n\r\n private async _submitAssetUpdateModel(updateModel: Compliance.ReturnAssetUpdateModel) {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating Assets' });\r\n try {\r\n await this._returnAssetsService.updateAssetMappings(updateModel);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","import { Component} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'return-assets',\r\n templateUrl: './returnAssets.component.html',\r\n styleUrls: ['./returnAssets.component.scss']\r\n})\r\nexport class ReturnAssetsComponent {\r\n}\r\n","
\r\n \r\n
\r\n
\r\n \r\n
","import { Component, ViewChild, ElementRef } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { Subscription, BehaviorSubject } from 'rxjs';\r\n\r\nexport interface ICellRendererParamsForPackageListDropdownCellRenderer extends ICellRendererParams {\r\n editMode$: BehaviorSubject;\r\n canEdit: (params: ICellRendererParamsForPackageListDropdownCellRenderer) => boolean;\r\n isDisabled: (params: ICellRendererParamsForPackageListDropdownCellRenderer) => boolean;\r\n dropdownItems: () => any[];\r\n name: string;\r\n valueField: string;\r\n allowNull: boolean;\r\n originalValue: any;\r\n displayGetter: (dropdownItem: any) => string;\r\n change: (params: ICellRendererParamsForPackageListDropdownCellRenderer) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'return-output-package-list-dropdown',\r\n template: `
\r\n
{{ getDisplayValue() }}
\r\n
\r\n \r\n
\r\n
`,\r\n styles: [`\r\n .drop-down-on-hover-cell {\r\n width: 100%;\r\n min-height: 26px;\r\n\r\n .read-only-label {\r\n display: block;\r\n }\r\n\r\n div.edit-control {\r\n display: none;\r\n }\r\n\r\n &.mouseover {\r\n .read-only-label {\r\n display: none;\r\n }\r\n\r\n .edit-control {\r\n display: block;\r\n }\r\n }\r\n }\r\n `]\r\n})\r\nexport class ReturnOutputPackageListDropdownCellRenderer implements ICellRendererAngularComp {\r\n private _editModeSub: Subscription;\r\n\r\n params: ICellRendererParamsForPackageListDropdownCellRenderer;\r\n editMode: boolean = false;\r\n isHovering: boolean;\r\n @ViewChild('outerDiv', { read: ElementRef, static: true }) outerDiv: ElementRef;\r\n\r\n agInit(params: ICellRendererParamsForPackageListDropdownCellRenderer): void {\r\n this.params = params;\r\n this._editModeSub = this.params.editMode$.subscribe(x => this.editMode = x);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub.unsubscribe();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onModelChange(value: any) {\r\n this.params.originalValue = this.params.data[this.params.colDef.field];\r\n this.params.data[this.params.colDef.field] = value;\r\n this.params.change(this.params);\r\n }\r\n\r\n mouseover($event) {\r\n this.isHovering = this.editMode && this.params.canEdit(this.params);\r\n }\r\n\r\n mouseout($event) {\r\n if (this.editMode && this.params.canEdit(this.params) && $event.relatedTarget) {\r\n // protect against clicks on inner children\r\n let parent = $event.relatedTarget.parentElement;\r\n while (parent) {\r\n if (parent === this.outerDiv.nativeElement) {\r\n return;\r\n }\r\n parent = parent.parentElement;\r\n }\r\n this.isHovering = false;\r\n }\r\n }\r\n\r\n getDisplayValue(): string {\r\n if (!this.params.data) {\r\n return null;\r\n }\r\n const dropdownItem = this.params.dropdownItems().find(x => x[this.params.valueField] === this.params.data[this.params.colDef.field]);\r\n return (dropdownItem && this.params.displayGetter(dropdownItem)) || null;\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { GridOptions, GridReadyEvent, GridApi, ColDef } from 'ag-grid-community';\r\nimport { ReturnOutputService } from '../../Output/returnOutput.service';\r\nimport { AgGridOptionsBuilder } from '../../../../AgGrid/agGridOptionsBuilder';\r\nimport { AgGridColumns } from '../../../../AgGrid/agGridColumns';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer, AgGridMultiSelectTracker, AgGridMultiSelectRendererParams } from '../../../../AgGrid/MultiSelectTracker';\r\nimport { BehaviorSubject, lastValueFrom, Subscription } from 'rxjs';\r\nimport { ICellRendererParamsForPackageListDropdownCellRenderer, ReturnOutputPackageListDropdownCellRenderer } from './agGridDropdownCellRenderer.component';\r\nimport { BusyIndicatorService } from '../../../../../Busy-Indicator/busyIndicator.service';\r\nimport * as _ from 'lodash';\r\nimport { ReturnRepository } from '../../../../Repositories/return.repository';\r\nimport { ReturnService } from '../../../return.service';\r\n\r\n@Component({\r\n selector: 'return-output-package-list',\r\n templateUrl: './returnOutputPackageList.component.html',\r\n styleUrls: ['./returnOutputPackageList.component.scss']\r\n})\r\nexport class ReturnOutputPackageListComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnOutputService: ReturnOutputService,\r\n private readonly _busyIndicatorService: BusyIndicatorService\r\n ) { }\r\n\r\n private _gridApi: GridApi;\r\n private _packageData: Compliance.ReturnPackageModel[];\r\n private _gridMultiSelectSub: Subscription;\r\n private _mailingTypes: Compliance.ReturnMailingTypeModel[];\r\n private _editModeSubject = new BehaviorSubject(true);\r\n\r\n isInitialized: boolean = false;\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.ReturnPackageModel).returnPackageId)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .build();\r\n\r\n get filingBatchId(): number {\r\n return this._returnService.filingBatchId;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._returnOutputService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n this._editModeSubject && this._editModeSubject.unsubscribe();\r\n this._returnOutputService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'returnPackageId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Package ID',\r\n field: 'returnPackageId',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.textColumnMedWidth,\r\n valueFormatter: (params) => params.value ? `RP${_.padStart(params.value, 6, '0')}` : ''\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n sortable: false,\r\n width: AgGridColumns.textColumnMedWidth,\r\n },\r\n {\r\n headerName: 'Mailing Type',\r\n field: 'returnMailingTypeId',\r\n cellRendererFramework: ReturnOutputPackageListDropdownCellRenderer,\r\n cellRendererParams: {\r\n canEdit: (x) => this._returnService.canEditCompany && !this._returnService.isFinalized,\r\n isDisabled: (x) => false,\r\n editMode$: this._editModeSubject.asObservable(),\r\n dropdownItems: () => this._mailingTypes,\r\n name: 'returnMailingTypes',\r\n valueField: 'returnMailingTypeId',\r\n allowNull: false,\r\n change: this._mailingTypeChanged.bind(this),\r\n displayGetter: this._mailTypesTableRenderer.bind(this)\r\n } as ICellRendererParamsForPackageListDropdownCellRenderer\r\n },\r\n {\r\n headerName: '# Returns',\r\n field: 'numberOfReturns',\r\n sortable: false,\r\n width: AgGridColumns.numericColumnWidth\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(() => {\r\n this.gridTracker.getSelectedRowIds().then(rowIds => {\r\n this._returnOutputService.sharedState.returnOutputModel.packageIds = rowIds;\r\n });\r\n });\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n if (!this.isInitialized) {\r\n this._mailingTypes = await lastValueFrom(this._returnRepository.getMailingTypes());\r\n this._packageData = await lastValueFrom(this._returnRepository.getPackages(this.filingBatchId));\r\n this.isInitialized = true;\r\n }\r\n\r\n this._setRowData();\r\n }\r\n\r\n async onReturnPartServiceDeactivated(): Promise {\r\n }\r\n\r\n private _mailTypesTableRenderer(item: Compliance.ReturnMailingTypeModel) {\r\n return item.returnMailingTypeName;\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map(x => {\r\n const returnPackage = x.data as Compliance.ReturnPackageModel;\r\n return returnPackage && returnPackage.returnPackageId;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n\r\n private async _mailingTypeChanged(params: ICellRendererParamsForPackageListDropdownCellRenderer): Promise {\r\n const returnPackage = params.data as Compliance.ReturnPackageModel;\r\n\r\n if (!returnPackage) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n await lastValueFrom(this._returnRepository.updatePackageMailingType(returnPackage.returnPackageId, returnPackage.returnMailingTypeId));\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private async _setRowData(): Promise {\r\n if (!(this._gridApi && this.isInitialized)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._packageData);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n}\r\n","
\r\n
\r\n

Printing and Mailing

\r\n
\r\n
\r\n
\r\n
\r\n
\r\n

\r\n Files to Include\r\n

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n

\r\n Options\r\n

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","
\r\n
\r\n

\r\n Packages\r\n \r\n

\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy} from '@angular/core';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { ReturnOutputService } from '../returnOutput.service';\r\nimport { Subject, Subscription } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'return-output-printing-mailing',\r\n templateUrl: './returnOutputPrintingMailing.component.html'\r\n})\r\nexport class ReturnOutputPrintingMailingComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnOutputService: ReturnOutputService\r\n ) { }\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n get returnOutputModel(): Compliance.ReturnOutputModel {\r\n return this._returnOutputService.sharedState && this._returnOutputService.sharedState.returnOutputModel;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._returnOutputService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnOutputService.unsubscribeFromServiceActivationCycle(this);\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n this._returnService.start$.pipe(takeUntil(this._destroy$)).subscribe(async () => {\r\n await this._returnOutputService.loadSharedState(this._returnService.filingBatchId);\r\n });\r\n await this._returnOutputService.loadSharedState(this._returnService.filingBatchId);\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._destroy$.next();\r\n }\r\n\r\n async onOptionChange(): Promise {\r\n if (!this._returnOutputService.sharedState.returnOutputModel.includeReturns) {\r\n this._returnOutputService.sharedState.returnOutputModel.embedExcelReportsInPdf = false;\r\n }\r\n\r\n await this._returnOutputService.saveSharedState();\r\n }\r\n}\r\n","
\r\n\r\n
\r\n Packages are available once preparation is complete\r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n","import { Component, OnInit, OnDestroy, ViewEncapsulation } from '@angular/core';\r\nimport { IReturnPartComponent } from '../../Models/returnPartServiceBase';\r\nimport { ReturnService } from '../../return.service';\r\nimport { ReturnOutputService } from './returnOutput.service';\r\nimport { ReturnRepository } from '../../../Repositories';\r\nimport { BusyIndicatorService, SnackBarService } from '../../../../Busy-Indicator';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'return-output',\r\n templateUrl: './returnOutput.component.html',\r\n styleUrls: ['./returnOutput.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ReturnOutputComponent implements OnInit, OnDestroy, IReturnPartComponent {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnOutputService: ReturnOutputService,\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _snackBarService: SnackBarService\r\n ) { }\r\n\r\n disableDownload: boolean;\r\n\r\n get packagesSelected(): boolean {\r\n return this._returnOutputService.sharedState &&\r\n this._returnOutputService.sharedState.returnOutputModel &&\r\n this._returnOutputService.sharedState.returnOutputModel.packageIds &&\r\n this._returnOutputService.sharedState.returnOutputModel.packageIds.length > 0;\r\n }\r\n\r\n get printingOptionsSelected(): boolean {\r\n return this._returnOutputService.sharedState &&\r\n this._returnOutputService.sharedState.returnOutputModel &&\r\n (this._returnOutputService.sharedState.returnOutputModel.includeFilingControlReport ||\r\n this._returnOutputService.sharedState.returnOutputModel.includeUSPSCertificateOfMailingIndividual ||\r\n this._returnOutputService.sharedState.returnOutputModel.includeUSPSCertificateOfMailingLog ||\r\n this._returnOutputService.sharedState.returnOutputModel.includeEnvelopeInserts ||\r\n this._returnOutputService.sharedState.returnOutputModel.includePackageCoverSheets ||\r\n this._returnOutputService.sharedState.returnOutputModel.includeReturns);\r\n }\r\n\r\n get returnId(): number {\r\n return this._returnService.sharedState &&\r\n this._returnService.sharedState.returns &&\r\n this._returnService.sharedState.returns.length > 0\r\n ? this._returnService.sharedState.returns[0].returnId\r\n : null;\r\n }\r\n\r\n get showOutput(): boolean {\r\n return this._returnService.isLocked ||\r\n this._returnService.isSigned ||\r\n this._returnService.isSigning ||\r\n this._returnService.isUnsigning ||\r\n this._returnService.isFinalizing ||\r\n this._returnService.isFinalized;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._returnOutputService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnOutputService.unsubscribeFromServiceActivationCycle(this);\r\n }\r\n\r\n onReturnPartServiceActivated(): void { }\r\n\r\n onReturnPartServiceDeactivated(): void { }\r\n\r\n async download(): Promise {\r\n this.disableDownload = true;\r\n const busyRef = this._busyIndicatorService.show({ message: 'Working on it...', delay: 0 });\r\n\r\n try {\r\n const lrpId = await lastValueFrom(this._returnRepository.generateDownloadOutput(this._returnOutputService.sharedState.returnOutputModel));\r\n this._snackBarService.addById(lrpId, Compliance.LongRunningProcessTypeEnum.GenerateReturnOutput);\r\n this.disableDownload = false;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n

Return Settings Override

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { ReturnSettingsService } from '.././returnSettings.service';\r\nimport { IComponentRef } from '../../../Models/iComponentRef';\r\nimport { ReturnSettingsEntityTypeEnum } from '../../../Models/enums';\r\nimport { BusyIndicatorService } from '../../../../../Busy-Indicator';\r\nimport { WeissmanMutexService, IMutexServiceHandler } from '../../../../WeissmanMutexService';\r\nimport { Subscription, BehaviorSubject, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/internal/operators/takeUntil';\r\n\r\n@Component({\r\n selector: 'return-settings-override',\r\n templateUrl: './returnSettingsOverride.component.html',\r\n styleUrls: ['./returnSettingsOverride.component.scss']\r\n})\r\nexport class ReturnSettingsOverrideComponent implements OnInit, OnDestroy, IReturnPartComponent, IMutexServiceHandler {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnSettingsService: ReturnSettingsService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService\r\n ) { }\r\n\r\n private _editModeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _editModeSub: Subscription;\r\n private _destroy$: Subject = new Subject();\r\n private _parcelsChangeDate: Date = null;\r\n\r\n ReturnSettingsEntityTypeEnum = ReturnSettingsEntityTypeEnum;\r\n returnSettingsComponent: IComponentRef;\r\n hasChanges: boolean = false;\r\n editMode: boolean = false;\r\n isInitialized: boolean = false;\r\n\r\n get canEdit(): boolean {\r\n return !this._returnService.isReturnInReadOnlyMode && this._returnService.canEditCompany;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._returnService.editGroup);\r\n }\r\n\r\n ngOnInit(): void {\r\n this._editModeSub = this._editModeSubject.asObservable().subscribe(x => {\r\n this.editMode = x;\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n }\r\n });\r\n\r\n this._returnSettingsService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnSettingsService.unsubscribeFromServiceActivationCycle(this);\r\n this._editModeSub.unsubscribe();\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onReturnPartServiceActivated(): void {\r\n this.isInitialized = true;\r\n\r\n this._returnService.parcelsChanged$.pipe(takeUntil(this._destroy$)).subscribe(async (x) =>\r\n {\r\n if (x) {\r\n if (this._parcelsChangeDate !== x) {\r\n this._parcelsChangeDate = x;\r\n await this.returnSettingsComponent.load();\r\n }\r\n }\r\n }\r\n );\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void {\r\n this._destroy$.next();\r\n }\r\n\r\n get filingBatchId(): number {\r\n return this._returnService.sharedState ? this._returnService.filingBatchId : null;\r\n }\r\n\r\n get returnId(): number {\r\n return this._returnService.sharedState && this._returnService.sharedState.returns && this._returnService.sharedState.returns.length > 0\r\n ? this._returnService.sharedState.returns[0].returnId\r\n : null;\r\n }\r\n\r\n onReturnSettingsInitialized($ref: IComponentRef) {\r\n this.returnSettingsComponent = $ref;\r\n }\r\n\r\n onReturnSettingsChanged(value: boolean) {\r\n this.hasChanges = value;\r\n }\r\n\r\n edit(): void {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n\r\n this._mutexService.acquire(this, this._returnService.editGroup);\r\n this._editModeSubject.next(true);\r\n\r\n this.returnSettingsComponent.edit();\r\n }\r\n\r\n async save(): Promise {\r\n if (!this.returnSettingsComponent) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n await this.returnSettingsComponent.save();\r\n this._editModeSubject.next(false);\r\n this.hasChanges = false;\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._editModeSubject.next(false);\r\n this.returnSettingsComponent.cancel();\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../../../Busy-Indicator';\r\nimport { GridApi, GridReadyEvent, ColDef, GridOptions } from 'ag-grid-community';\r\nimport * as _ from 'lodash';\r\nimport { AgGridMultiSelectTracker } from '../../../../AgGrid/MultiSelectTracker/agGridMultiSelectTracker';\r\nimport { lastValueFrom, Subscription } from 'rxjs';\r\nimport { AgGridColumns } from '../../../../AgGrid/agGridColumns';\r\nimport { AgGridMultiSelectedHeaderRendererComponent } from '../../../../AgGrid/MultiSelectTracker/agGridMultiSelectHeaderRenderer.component';\r\nimport { AgGridMultiSelectedCellRendererComponent } from '../../../../AgGrid/MultiSelectTracker/agGridMultiSelectCellRenderer.component';\r\nimport { AgGridMultiSelectRendererParams } from '../../../../AgGrid/MultiSelectTracker/agGridMultiSelectTracker';\r\nimport { AgGridFilterParams } from '../../../../AgGrid/agGridFilterParams';\r\nimport { AgGridOptionsBuilder } from '../../../../AgGrid/agGridOptionsBuilder';\r\nimport { ReturnRepository } from '../../../../../Compliance/Repositories';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { IWeissmanModalComponent } from '../../../../WeissmanModalService';\r\n\r\n@Component({\r\n templateUrl: './returnSettingsReportAdd.component.html',\r\n selector: 'return-settings-report-add'\r\n})\r\nexport class ReturnSettingsReportAddComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _returnRepository: ReturnRepository) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n private _availableReports: Compliance.SavedSearchModelSelectable[];\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.SavedSearchModelSelectable).savedSearchID)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n get filingBatchId(): number {\r\n return this._returnService.sharedState ? this._returnService.filingBatchId : null;\r\n }\r\n\r\n params: Compliance.FilingBatchReportModel[];\r\n result: Compliance.FilingBatchReportModel[];\r\n\r\n rowsSelected: boolean = false;\r\n allReports: Core.SavedSearchModel[];\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n async ngOnInit(): Promise {\r\n this.allReports = await lastValueFrom(this._returnRepository.getReports());\r\n const result = _.filter(this.allReports, (ar) => !_.some(this.params, (fb) => { return ar.savedSearchID === fb.savedSearchId; }));\r\n this._availableReports = _.map(result, (r) => { return { ...r, isSelected: false } as Compliance.SavedSearchModelSelectable });\r\n\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.rowsSelected = x.selectAllRows || x.selectedRows.length > 0;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'savedSearchID',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRendererComponent,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRendererComponent,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Name',\r\n field: 'searchName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const savedSearch = params.data as Core.SavedSearchModel;\r\n return this._returnService.getSavedSearchReportName(savedSearch);\r\n },\r\n filterValueGetter: params => {\r\n const savedSearch = params.data as Core.SavedSearchModel;\r\n return this._returnService.getSavedSearchReportName(savedSearch);\r\n }\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'isSystem',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const savedSearch = params.data as Core.SavedSearchModel;\r\n return this._returnService.getSavedSearchReportType(savedSearch);\r\n },\r\n filterValueGetter: params => {\r\n const savedSearch = params.data as Core.SavedSearchModel;\r\n return this._returnService.getSavedSearchReportType(savedSearch);\r\n }\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsg = 'saving';\r\n\r\n this.busyIndicatorMessageManager.add('Saving', busyMsg);\r\n\r\n try {\r\n const rowIds = await this.gridTracker.getSelectedRowIds();\r\n this.result = _.map(_.filter(this.allReports, (x) => _.some(rowIds, (y) => x.savedSearchID === y)), (x) => {\r\n return {\r\n filingBatchReportId: 0,\r\n filingBatchId: this.filingBatchId,\r\n savedSearchId: x.savedSearchID,\r\n savedSearchCategoryId: x.savedSearchCategoryID,\r\n name: x.searchName,\r\n variantName: x.variantName,\r\n isSystem: x.isSystemSearch\r\n } as Compliance.FilingBatchReportModel;\r\n });\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!this._gridApi && this._availableReports) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._availableReports);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map((x) => {\r\n const savedSearch = x.data as Core.SavedSearchModel;\r\n return savedSearch && savedSearch.savedSearchID;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForReturnSettingsReportListComponentGridAction extends ICellRendererParams {\r\n edit: (params: ICellRendererParamsForReturnSettingsReportListComponentGridAction) => void;\r\n getEditTitle: (params: ICellRendererParamsForReturnSettingsReportListComponentGridAction) => string;\r\n canEdit: (params: ICellRendererParamsForReturnSettingsReportListComponentGridAction) => boolean;\r\n canEnterEditMode: (params: ICellRendererParamsForReturnSettingsReportListComponentGridAction) => boolean;\r\n canRemove: (params: ICellRendererParamsForReturnSettingsReportListComponentGridAction) => boolean;\r\n remove: (params: ICellRendererParamsForReturnSettingsReportListComponentGridAction) => void;\r\n canUndoRemove: (params: ICellRendererParamsForReturnSettingsReportListComponentGridAction) => boolean;\r\n undoRemove: (params: ICellRendererParamsForReturnSettingsReportListComponentGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n `\r\n})\r\nexport class ReturnSettingsReportListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForReturnSettingsReportListComponentGridAction;\r\n\r\n agInit(params: ICellRendererParamsForReturnSettingsReportListComponentGridAction): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\n\r\nexport interface ReportManagerModalInputParameters {\r\n reportId: number;\r\n reportType?: number;\r\n formRevisionId?: number;\r\n filingBatchId?: number;\r\n formRevisions?: Compliance.ReturnFormRevisionModel[];\r\n schedules?: Compliance.FormRevisionScheduleModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'report-manager-modal-component',\r\n templateUrl: './reportManagerModal.component.html'\r\n})\r\nexport class ReportManagerModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef) { }\r\n\r\n loading: boolean = false;\r\n onClose: any;\r\n params: ReportManagerModalInputParameters;\r\n savedReport: any;\r\n result: any;\r\n\r\n handleSaveModalClose(report: any) {\r\n this.savedReport = report;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}","
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n","import { Injectable } from '@angular/core';\r\nimport { BsModalService, BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { ReportManagerModalComponent, ReportManagerModalInputParameters } from './reportManagerModal.component';\r\n\r\n/**\r\n * Created as a standalone service to provide a reusable method for launching the asset detail component modal window.\r\n * This service needs to know about the asset details component.\r\n */\r\n@Injectable()\r\nexport class ReportManagerModalService {\r\n constructor(\r\n private _bsModalService: BsModalService,\r\n private _wsModalService: WeissmanModalService\r\n ) {}\r\n\r\n /**\r\n * Shows the asset detail modal window and returns a promise.\r\n * The promise resolves (with the asset details component's output parameters) when the modal closes\r\n * @param params Initial parameters for the asset details modal component.\r\n */\r\n showForFormRevision(params: ReportManagerModalInputParameters): Promise {\r\n return new Promise((resolve, reject) => {\r\n const showModalFn = (): BsModalRef => {\r\n return this._bsModalService.show(ReportManagerModalComponent, {\r\n class: 'modal-xl',\r\n initialState: {\r\n params: params\r\n },\r\n ignoreBackdropClick: true\r\n });\r\n };\r\n\r\n this._wsModalService.show(showModalFn.bind(this)).whenClosed.then(bsModalRef => {\r\n const result = (bsModalRef.content as ReportManagerModalComponent).savedReport;\r\n resolve(result);\r\n },\r\n reject);\r\n });\r\n }\r\n\r\n showForFilingBatch(params: ReportManagerModalInputParameters): Promise {\r\n return new Promise((resolve, reject) => {\r\n const showModalFn = (): BsModalRef => {\r\n return this._bsModalService.show(ReportManagerModalComponent, {\r\n class: 'modal-xl',\r\n initialState: {\r\n params: params\r\n },\r\n ignoreBackdropClick: true\r\n });\r\n };\r\n\r\n this._wsModalService.show(showModalFn.bind(this)).whenClosed.then(bsModalRef => {\r\n const result = (bsModalRef.content as ReportManagerModalComponent).savedReport;\r\n resolve(result);\r\n },\r\n reject);\r\n });\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { GridOptions } from 'ag-grid-community';\r\nimport { has } from 'lodash';\r\n\r\n@Component({\r\n selector: 'ag-grid-filter-toggle',\r\n templateUrl: './agGridFilterToggle.component.html'\r\n})\r\nexport class AgGridFilterToggleComponent {\r\n @Input() gridOptions: GridOptions & { api?: {appliedFilter?: any}};\r\n\r\n get isFilterVisible(): boolean {\r\n return this.gridOptions && this.gridOptions.floatingFilter;\r\n }\r\n\r\n onFilterClick() {\r\n this.gridOptions.floatingFilter = !this.gridOptions.floatingFilter;\r\n this.gridOptions.api.refreshHeader();\r\n\r\n // clear filter when hiding\r\n if (!this.gridOptions.floatingFilter && this._isFiltered()) {\r\n this.gridOptions.api.setFilterModel(null);\r\n this.gridOptions.api.appliedFilter = null;\r\n this.gridOptions.api.onFilterChanged();\r\n }\r\n }\r\n\r\n private _isFiltered(): boolean {\r\n const filterModel = this.gridOptions.api.getFilterModel();\r\n if (!filterModel) {\r\n return false;\r\n }\r\n\r\n // filter model is an empty object when not filtered\r\n for (const key in filterModel) {\r\n if (has(filterModel, key)) {\r\n return true;\r\n }\r\n }\r\n\r\n return false;\r\n }\r\n}","
\r\n
\r\n

\r\n Additional Reports\r\n \r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { GridOptions, GridReadyEvent, GridApi, ColDef, RowNode } from 'ag-grid-community';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { AgGridOptionsBuilder } from '../../../../AgGrid/agGridOptionsBuilder';\r\nimport { AgGridColumns } from '../../../../AgGrid/agGridColumns';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport { ReturnRepository } from '../../../../Repositories';\r\nimport { ReturnSettingsReportAddComponent } from '../Report-List-Add/returnSettingsReportAdd.component';\r\nimport { WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport * as _ from 'lodash';\r\nimport { ReturnSettingsService } from '../returnSettings.service';\r\nimport { AgGridFilterParams } from '../../../../AgGrid/agGridFilterParams';\r\nimport { ReturnSettingsReportListGridActionCellRendererComponent } from './agGridActionCellRenderer.component';\r\nimport { ICellRendererParamsForReturnSettingsReportListComponentGridAction } from './agGridActionCellRenderer.component';\r\nimport { Subscription, BehaviorSubject, lastValueFrom } from 'rxjs';\r\nimport { WeissmanMutexService, IMutexServiceHandler } from '../../../../WeissmanMutexService';\r\nimport { BusyIndicatorService } from '../../../../../Busy-Indicator/busyIndicator.service';\r\nimport { ReportManagerModalService } from '../../../../../Reporting/Manager/reportManagerModal.service';\r\nimport { ReportManagerModalInputParameters } from '../../../../../Reporting/Manager/reportManagerModal.component';\r\nimport { ReturnAssetsService } from '../../Assets/returnAssets.service';\r\nimport { ProductAnalyticsService } from '../../../../../Common/Amplitude/productAnalytics.service';\r\n\r\nexport interface FilingBatchReportRowModel extends Compliance.FilingBatchReportModel{\r\n deleted: boolean;\r\n added: boolean;\r\n changed: boolean;\r\n displayName: string;\r\n}\r\n\r\n@Component({\r\n selector: 'return-settings-report-list',\r\n templateUrl: './returnSettingsReportList.component.html',\r\n styleUrls: ['./returnSettingsReportList.component.scss']\r\n})\r\nexport class ReturnSettingsReportListComponent implements OnInit, OnDestroy, IReturnPartComponent, IMutexServiceHandler {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnSettingsService: ReturnSettingsService,\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _reportManagerModalService: ReportManagerModalService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) { }\r\n\r\n private _gridApi: GridApi;\r\n private _editModeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _editModeSub: Subscription;\r\n private _reports: FilingBatchReportRowModel[];\r\n\r\n get filingBatchId(): number {\r\n return this._returnService.sharedState ? this._returnService.filingBatchId : null;\r\n }\r\n\r\n get canEdit(): boolean {\r\n return !this._returnService.isReturnInReadOnlyMode && this._returnService.canEditCompany;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._returnService.editGroup);\r\n }\r\n\r\n get hasChanges(): boolean {\r\n let hasChanges: boolean = false;\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const report = node.data as FilingBatchReportRowModel;\r\n if (report && (report.deleted || report.added || report.changed)) {\r\n hasChanges = true;\r\n }\r\n });\r\n\r\n return hasChanges;\r\n }\r\n\r\n isInitialized: boolean = false;\r\n\r\n editMode: boolean = false;\r\n\r\n gridId: System.Guid = 'F2B32551-A795-4A16-BE55-024408596611';\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'grid-row-deleted': params => params.data && params.data.deleted\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .build();\r\n\r\n ngOnInit(): void {\r\n this._editModeSub = this._editModeSubject.asObservable().subscribe(x => {\r\n this.editMode = x;\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n }\r\n });\r\n\r\n this._returnSettingsService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnSettingsService.unsubscribeFromServiceActivationCycle(this);\r\n this._editModeSub.unsubscribe();\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Name',\r\n field: 'displayName',\r\n width: AgGridColumns.textColumnWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'isSystem',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const report = params.data as Compliance.FilingBatchReportModel;\r\n return this._returnService.getReportType(report);\r\n },\r\n filterValueGetter: params => {\r\n const report = params.data as Compliance.FilingBatchReportModel;\r\n return this._returnService.getReportType(report);\r\n }\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: ReturnSettingsReportListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canEdit: this._canEdit.bind(this),\r\n canEnterEditMode: this._canEnterEditMode.bind(this),\r\n edit: this._edit.bind(this),\r\n getEditTitle: this._getEditTitle.bind(this),\r\n canRemove: this._canRemove.bind(this),\r\n remove: this._remove.bind(this),\r\n canUndoRemove: this._canUndoRemove.bind(this),\r\n undoRemove: this._undoRemove.bind(this),\r\n } as ICellRendererParamsForReturnSettingsReportListComponentGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'displayName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n if (!this.isInitialized) {\r\n const reports = await lastValueFrom(this._returnRepository.getFilingBatchReports(this.filingBatchId));\r\n this._setReports(reports);\r\n this.isInitialized = true;\r\n }\r\n\r\n this._setRowData();\r\n }\r\n\r\n async onReturnPartServiceDeactivated(): Promise {\r\n }\r\n\r\n edit(): void {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n\r\n this._mutexService.acquire(this, this._returnService.editGroup);\r\n this._editModeSubject.next(true);\r\n }\r\n\r\n cancel(): void {\r\n const update: RowNode[] = [];\r\n const remove: FilingBatchReportRowModel[] = [];\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n\r\n const report = node.data as FilingBatchReportRowModel;\r\n\r\n if (report && !report.added) {\r\n update.push(node);\r\n report.deleted = false;\r\n } else { // if added, remove it\r\n remove.push(report);\r\n }\r\n });\r\n\r\n this._gridApi.updateRowData({ remove: remove });\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this._editModeSubject.next(false);\r\n }\r\n\r\n async add(): Promise {\r\n const reports: Compliance.FilingBatchReportModel[] = [];\r\n this._gridApi.forEachNode(x => reports.push(x.data));\r\n\r\n const result = await this._modalService.showAsync(ReturnSettingsReportAddComponent, reports, 'modal-xl');\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const newReports = _.map(result,\r\n (x) => {\r\n return _.extend(\r\n {} as Compliance.FilingBatchReportModel,\r\n x,\r\n {\r\n filingBatchId: this.filingBatchId,\r\n filingBatchReportId: 0,\r\n added: true,\r\n deleted: false,\r\n displayName: this._returnService.getReportName(x)\r\n });\r\n });\r\n\r\n this._gridApi.updateRowData({ add: newReports });\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async save(): Promise {\r\n if (!this.hasChanges) {\r\n return Promise.resolve();\r\n }\r\n\r\n const reports: Compliance.FilingBatchReportModel[] = [];\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const reportRow = node.data as FilingBatchReportRowModel;\r\n\r\n if (!reportRow.deleted) {\r\n\r\n const report = _.extend({} as Compliance.FilingBatchReportModel, reportRow);\r\n\r\n reports.push(report);\r\n }\r\n });\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n const result = await lastValueFrom(this._returnRepository.updateReports(this.filingBatchId, reports));\r\n this._setReports(result);\r\n this._setRowData();\r\n this._editModeSubject.next(false);\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n }\r\n finally {\r\n if (reports.length) {\r\n this._productAnalyticsService.logEvent('click-additional-reports-save', {\r\n selectAdditionalReports: reports.map(x => this._returnService.getReportName(x))\r\n });\r\n }\r\n busyRef.hide();\r\n }\r\n\r\n this._returnService.notifyReportsUpdate(this._reports);\r\n return Promise.resolve();\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n private _getEditTitle(params: ICellRendererParamsForReturnSettingsReportListComponentGridAction): string {\r\n const filingBatchReportRow = params.data as FilingBatchReportRowModel;\r\n if (!filingBatchReportRow) {\r\n return '';\r\n }\r\n\r\n if (filingBatchReportRow.savedSearchCategoryId !== Core.SavedSearchCategoryEnum.ComplianceReportSetup &&\r\n filingBatchReportRow.savedSearchCategoryId !== Core.SavedSearchCategoryEnum.ComplianceCustomReport) {\r\n return 'Cannot customize this type of report';\r\n }\r\n\r\n if (filingBatchReportRow.added) {\r\n return 'Cannot customize until you save changes';\r\n }\r\n\r\n if (filingBatchReportRow.deleted) {\r\n return 'Cannot customize a deleted report';\r\n }\r\n\r\n return '';\r\n }\r\n\r\n private _canEdit(params: ICellRendererParamsForReturnSettingsReportListComponentGridAction): boolean {\r\n const filingBatchReportRow = params.data as FilingBatchReportRowModel;\r\n if (!filingBatchReportRow) {\r\n return false;\r\n }\r\n\r\n return this.canEdit && this.editMode;\r\n }\r\n\r\n private _canEnterEditMode(params: ICellRendererParamsForReturnSettingsReportListComponentGridAction): boolean {\r\n const filingBatchReportRow = params.data as FilingBatchReportRowModel;\r\n if (!filingBatchReportRow) {\r\n return false;\r\n }\r\n\r\n return (!(filingBatchReportRow.added || filingBatchReportRow.deleted)) &&\r\n (filingBatchReportRow.savedSearchCategoryId === Core.SavedSearchCategoryEnum.ComplianceReportSetup ||\r\n filingBatchReportRow.savedSearchCategoryId === Core.SavedSearchCategoryEnum.ComplianceCustomReport);\r\n }\r\n\r\n private async _edit(params: ICellRendererParamsForReturnSettingsReportListComponentGridAction): Promise {\r\n const filingBatchReportRow = params.data as FilingBatchReportRowModel;\r\n\r\n const formRevisions: Compliance.ReturnFormRevisionModel[] = [];\r\n this._returnService.getAssociatedReturnFormRevisions().forEach(item => {\r\n if (!formRevisions.find(j => j.formRevisionId === item.formRevisionId)){\r\n formRevisions.push(item);\r\n }\r\n });\r\n\r\n const schedules: Compliance.FormRevisionScheduleModel[] = [];\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n (await this._returnAssetsService.getScheduleDetails(true))\r\n .filter(item => item.isReportable && !item.isSystem)\r\n .map(item => ({\r\n formRevisionScheduleId: item.formRevisionScheduleId,\r\n formRevisionId: item.formRevisionId,\r\n name: item.name\r\n } as Compliance.FormRevisionScheduleModel) as Compliance.FormRevisionScheduleModel)\r\n .forEach(item => {\r\n if (!schedules.find(j => j.formRevisionScheduleId === item.formRevisionScheduleId)) {\r\n schedules.push(item);\r\n }\r\n });\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n const modalParams: ReportManagerModalInputParameters = {\r\n reportId: filingBatchReportRow.savedSearchId,\r\n reportType: filingBatchReportRow.isSystem ? 0 : 1,\r\n formRevisionId: null,\r\n filingBatchId: this.filingBatchId,\r\n formRevisions: formRevisions,\r\n schedules: schedules\r\n };\r\n\r\n try {\r\n const filingBatchReport = await this._reportManagerModalService.showForFilingBatch(modalParams);\r\n\r\n if (!filingBatchReport) {\r\n return;\r\n }\r\n\r\n _.extend(\r\n filingBatchReportRow,\r\n filingBatchReport,\r\n { changed: true, deleted: false, added: false, displayName: this._returnService.getReportName(filingBatchReport) });\r\n\r\n this._returnService.notifyReportsUpdate(this._reports);\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n } catch (e) {\r\n\r\n }\r\n }\r\n\r\n private _canRemove(params: ICellRendererParamsForReturnSettingsReportListComponentGridAction): boolean {\r\n const filingBatchReportRow = params.data as FilingBatchReportRowModel;\r\n if (!filingBatchReportRow) {\r\n return false;\r\n }\r\n\r\n return this.editMode && !filingBatchReportRow.deleted;\r\n }\r\n\r\n private _remove(params: ICellRendererParamsForReturnSettingsReportListComponentGridAction): void {\r\n const filingBatchReportRow = params.data as FilingBatchReportRowModel;\r\n if (!filingBatchReportRow) {\r\n return;\r\n }\r\n\r\n if (!filingBatchReportRow.added) {\r\n filingBatchReportRow.deleted = true;\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n } else {\r\n this._gridApi.updateRowData({ remove: [filingBatchReportRow] });\r\n }\r\n }\r\n\r\n private _undoRemove(params: ICellRendererParamsForReturnSettingsReportListComponentGridAction): void {\r\n const filingBatchReportRow = params.data as FilingBatchReportRowModel;\r\n if (!filingBatchReportRow) {\r\n return;\r\n }\r\n\r\n filingBatchReportRow.deleted = false;\r\n\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n }\r\n\r\n private _canUndoRemove(params: ICellRendererParamsForReturnSettingsReportListComponentGridAction): boolean {\r\n const filingBatchReportRow = params.data as FilingBatchReportRowModel;\r\n if (!filingBatchReportRow) {\r\n return false;\r\n }\r\n\r\n return this.editMode && filingBatchReportRow.deleted;\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.isInitialized)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._reports);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _setReports(reports: Compliance.FilingBatchReportModel[]): void {\r\n this._reports = _.map(reports,\r\n (x: Compliance.FilingBatchReportModel) => {\r\n return _.extend({} as FilingBatchReportRowModel,\r\n x,\r\n {\r\n deleted: false,\r\n added: false,\r\n changed: false,\r\n displayName: this._returnService.getReportName(x)\r\n });\r\n });\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n General Return Settings\r\n

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
Report Net Book Value instead of factored cost:
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
Form Cost Display:
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { IReturnPartComponent } from '../../../Models/returnPartServiceBase';\r\nimport { ReturnService } from '../../../return.service';\r\nimport { ReturnSettingsService } from '.././returnSettings.service';\r\nimport { BusyIndicatorService } from '../../../../../Busy-Indicator';\r\nimport { WeissmanMutexService, IMutexServiceHandler } from '../../../../WeissmanMutexService';\r\nimport { Subscription, BehaviorSubject, lastValueFrom } from 'rxjs';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { ReturnAssetsService } from '../../Assets/returnAssets.service';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'return-settings-general',\r\n templateUrl: './returnSettingsGeneral.component.html',\r\n styleUrls: ['./returnSettingsGeneral.component.scss']\r\n})\r\nexport class ReturnSettingsGeneralComponent implements OnInit, OnDestroy, IReturnPartComponent, IMutexServiceHandler {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnSettingsService: ReturnSettingsService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _returnAssetService: ReturnAssetsService\r\n ) { }\r\n\r\n hasChanges: boolean = false;\r\n editMode: boolean = false;\r\n isInitialized: boolean = false;\r\n reportNBVInsteadOfFactoredCostControl: UntypedFormControl = new UntypedFormControl(false);\r\n returnCostReportingDisplayControl: UntypedFormControl = new UntypedFormControl(false);\r\n\r\n private _editModeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _editModeSub: Subscription;\r\n private _generalSettings: Compliance.FilingBatchGeneralReturnSettings;\r\n private _reportNBVInsteadOfFactoredCost: boolean;\r\n private _returnCostReportingDisplayId: number;\r\n\r\n\r\n get canEdit(): boolean {\r\n return !this._returnService.isReturnInReadOnlyMode && this._returnService.canEditCompany;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._returnService.editGroup);\r\n }\r\n\r\n ngOnInit(): void {\r\n this._editModeSub = this._editModeSubject.asObservable().subscribe(x => {\r\n this.editMode = x;\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n this.reportNBVInsteadOfFactoredCostControl.disable();\r\n this.returnCostReportingDisplayControl.disable();\r\n } else{\r\n this.reportNBVInsteadOfFactoredCostControl.enable();\r\n this.returnCostReportingDisplayControl.enable();\r\n }\r\n });\r\n\r\n this._returnSettingsService.subscribeToServiceActivationCycle(this);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnSettingsService.unsubscribeFromServiceActivationCycle(this);\r\n this._editModeSub.unsubscribe();\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n }\r\n\r\n async onReturnPartServiceActivated(): Promise {\r\n if (!this.isInitialized) {\r\n const settings = {\r\n reportNBVInsteadOfFactoredCost: this._returnService.filingBatch.reportNBVInsteadOfFactoredCost,\r\n returnCostReportingDisplayId: this._returnService.filingBatch.returnCostReportingDisplayId,\r\n rowVersion: this._returnService.filingBatch.rowVersion\r\n } as Compliance.FilingBatchGeneralReturnSettings;\r\n\r\n this._generalSettings = settings;\r\n this._setSettings(this._generalSettings.reportNBVInsteadOfFactoredCost, this._generalSettings.returnCostReportingDisplayId);\r\n this.isInitialized = true;\r\n }\r\n }\r\n\r\n onReturnPartServiceDeactivated(): void { }\r\n\r\n onReturnSettingsChanged(value: boolean) {\r\n this.hasChanges = value;\r\n }\r\n\r\n edit(): void {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n\r\n this._mutexService.acquire(this, this._returnService.editGroup);\r\n this._editModeSubject.next(true);\r\n }\r\n\r\n async save(): Promise {\r\n if (!this.hasChanges) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n const updateModel = {\r\n reportNBVInsteadOfFactoredCost: this._reportNBVInsteadOfFactoredCost,\r\n returnCostReportingDisplayId: this._returnCostReportingDisplayId,\r\n rowVersion: this._generalSettings.rowVersion\r\n } as Compliance.FilingBatchGeneralReturnSettings;\r\n\r\n this._generalSettings = await lastValueFrom(this._returnService.updateFilingBatchGeneralReturnSettings(updateModel));\r\n this._editModeSubject.next(false);\r\n this._mutexService.release(this, this._returnService.editGroup);\r\n\r\n await this._returnAssetService.notifyAssetDetailsUpdated(null, false);\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n this._setSettings(this._generalSettings.reportNBVInsteadOfFactoredCost, this._generalSettings.returnCostReportingDisplayId);\r\n this._editModeSubject.next(false);\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n reportNBVInsteadOfFactoredCostChanged(value: boolean): void {\r\n this._reportNBVInsteadOfFactoredCost = value;\r\n this.hasChanges = true;\r\n }\r\n\r\n returnCostReportingDisplayChanged(value: number): void{\r\n this._returnCostReportingDisplayId = value;\r\n this.hasChanges = true;\r\n }\r\n\r\n get showReportNBVInsteadOfFactoredCost(): boolean {\r\n return (!!_.find(this._returnService.getAssociatedReturnFormRevisions(), i => i.supportsNBVReporting) ||\r\n this._returnService.isReturnInReadOnlyMode && this._returnService.filingBatch.reportNBVInsteadOfFactoredCost);\r\n\r\n }\r\n\r\n get showReturnCostReportingDisplay(): boolean {\r\n return (!!_.find(this._returnService.getAssociatedReturnFormRevisions(), i => i.supportsEstFMVReporting) ||\r\n this._returnService.isReturnInReadOnlyMode &&\r\n this._returnService.filingBatch.returnCostReportingDisplayId !== Compliance.ReturnCostReportingDisplayEnum.Both);\r\n }\r\n\r\n private _setSettings(reportNBVInsteadOfFactoredCost: boolean, returnCostReportingDisplayId: number): void{\r\n this._reportNBVInsteadOfFactoredCost = reportNBVInsteadOfFactoredCost;\r\n this._returnCostReportingDisplayId = returnCostReportingDisplayId == 0 ? Compliance.ReturnCostReportingDisplayEnum.Both : returnCostReportingDisplayId;\r\n this.reportNBVInsteadOfFactoredCostControl.setValue(reportNBVInsteadOfFactoredCost);\r\n this.returnCostReportingDisplayControl.setValue(returnCostReportingDisplayId);\r\n }\r\n}\r\n","
\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n","import { Component, ViewEncapsulation } from '@angular/core';\r\nimport { ReturnService } from '../../return.service';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'return-settings-tab',\r\n templateUrl: './returnSettingsTab.component.html',\r\n styleUrls: ['./returnSettingsTab.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ReturnSettingsTabComponent {\r\n constructor(private _returnService: ReturnService) { }\r\n\r\n get showGeneralReturnSettings(): boolean {\r\n return this._returnService.filingBatch &&\r\n (!!_.find(this._returnService.getAssociatedReturnFormRevisions(), i => i.supportsNBVReporting || i.supportsEstFMVReporting) ||\r\n this._returnService.isReturnInReadOnlyMode && (this._returnService.filingBatch.reportNBVInsteadOfFactoredCost ||\r\n this._returnService.filingBatch.returnCostReportingDisplayId !== Compliance.ReturnCostReportingDisplayEnum.Both));\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, OnInit, OnDestroy, ViewChild, ViewEncapsulation } from '@angular/core';\r\nimport { TabsetComponent, TabDirective } from 'ngx-bootstrap/tabs';\r\nimport { ReturnUpdateLogicService } from '../returnUpdateLogic.service';\r\nimport { ReturnOverviewService } from './Overview/returnOverview.service';\r\nimport { ReturnAssetsService, ReturnAssetsServiceSharedState } from './Assets/returnAssets.service';\r\nimport { ReturnPreviewService, ReturnPreviewServiceSharedState } from './Preview/returnPreview.service';\r\nimport { from, Subscription } from 'rxjs';\r\nimport { ReturnOutputService } from './Output/returnOutput.service';\r\nimport { ReturnSettingsService } from './Settings/returnSettings.service';\r\nimport { ReturnService } from '../return.service';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { TimerService } from '../../../UI-Lib/Utilities/timer.service';\r\n\r\nimport * as _ from 'lodash';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\n\r\ninterface TabInfo {\r\n heading: string;\r\n activationParam?: any;\r\n select?: (param: any) => void;\r\n activate: (param: any) => void;\r\n deactivate: () => void;\r\n initialize: () => void;\r\n}\r\n\r\n@Component({\r\n selector: 'return-parts',\r\n templateUrl: './returnParts.component.html',\r\n styleUrls: ['./returnParts.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ReturnPartsComponent implements OnInit, OnDestroy {\r\n // Components in this page follow a special lifecycle. The tabs activate the individual pages, and the returnServices coordinates these pages.\r\n // OnReturnPartActivated / Deactivated contains code that would normally be in the init and destroy methods.\r\n // Components subscribe to activation lifecycle - a base method, and then have their individual logic called, so that when their tab is clicked away from they\r\n // can be passive, without needing to be destroyed and re-created. A system of shared state is used to determine whether the variables involved in the\r\n // return as a whole have changed. As an example, the returnAssetList's method : _refreshAssets().\r\n // As in other parts of the app each tab/page has its own service method to handle the data flow, but in this case they extend a base class\r\n // \"ReturnPartServiceBase\", so that they have the needed mechanism to be unregistered.\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _returnOverviewService: ReturnOverviewService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _returnPreviewService: ReturnPreviewService,\r\n private readonly _returnOutputService: ReturnOutputService,\r\n private readonly _returnSettingsService: ReturnSettingsService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _timer: TimerService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService\r\n ) { }\r\n\r\n @ViewChild('tabset') tabset: TabsetComponent;\r\n\r\n overviewTab: TabInfo = {\r\n heading: 'Overview',\r\n activate: () => this._returnOverviewService.notifyServiceActivationChange(true),\r\n deactivate: () => this._returnOverviewService.notifyServiceActivationChange(false),\r\n initialize: () => this._returnOverviewService.initialize()\r\n };\r\n\r\n assetsTab: TabInfo = {\r\n heading: 'Assets',\r\n select: (sharedState: ReturnAssetsServiceSharedState) => {\r\n this.assetsTab.activationParam = sharedState;\r\n\r\n // set the activation parameters and the tab control \"select\" will pass them to the service\r\n this._timer.setTimeout(() => this.tabset.tabs[1].active = true, 100);\r\n },\r\n activate: (sharedState: ReturnAssetsServiceSharedState) => this._returnAssetsService.notifyServiceActivationChange(true, sharedState),\r\n deactivate: () => this._returnAssetsService.notifyServiceActivationChange(false),\r\n initialize: () => this._returnAssetsService.initialize()\r\n };\r\n\r\n previewTab: TabInfo = {\r\n heading: 'Returns',\r\n select: (sharedState: ReturnPreviewServiceSharedState) => {\r\n this.previewTab.activationParam = sharedState;\r\n\r\n // set the activation parameters and the tab control \"select\" will pass them to the service\r\n this._timer.setTimeout(() => this.tabset.tabs[2].active = true, 100);\r\n },\r\n activate: (sharedState: ReturnPreviewServiceSharedState) => this._returnPreviewService.notifyServiceActivationChange(true, sharedState),\r\n deactivate: () => this._returnPreviewService.notifyServiceActivationChange(false),\r\n initialize: () => this._returnPreviewService.initialize()\r\n };\r\n\r\n settingsTab: TabInfo = {\r\n heading: 'Settings',\r\n activate: () => this._returnSettingsService.notifyServiceActivationChange(true),\r\n deactivate: () => this._returnSettingsService.notifyServiceActivationChange(false),\r\n initialize: () => this._returnSettingsService.initialize()\r\n };\r\n\r\n outputTab: TabInfo = {\r\n heading: 'Output',\r\n activate: () => this._returnOutputService.notifyServiceActivationChange(true),\r\n deactivate: () => this._returnOutputService.notifyServiceActivationChange(false),\r\n initialize: () => this._returnOutputService.initialize()\r\n };\r\n\r\n tabs = [\r\n this.overviewTab,\r\n this.assetsTab,\r\n this.previewTab,\r\n this.settingsTab,\r\n this.outputTab\r\n ];\r\n\r\n isInitialized: boolean = false;\r\n\r\n private _returnAssetsSelectedSub: Subscription;\r\n private _returnPreviewSelectedSub: Subscription;\r\n private _returnServiceStartSub: Subscription;\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._returnService.editGroup);\r\n }\r\n\r\n ngOnInit(): void {\r\n this._returnServiceStartSub = this._returnService.start$.subscribe(() => this._initialize());\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._returnServiceStartSub && this._returnServiceStartSub.unsubscribe();\r\n this._returnAssetsSelectedSub && this._returnAssetsSelectedSub.unsubscribe();\r\n this._returnPreviewSelectedSub && this._returnPreviewSelectedSub.unsubscribe();\r\n this.tabs.forEach(x => x.deactivate());\r\n }\r\n\r\n tabDeselected(tab: TabDirective): void {\r\n if (!tab) {\r\n return;\r\n }\r\n\r\n const control = this.tabs.find(x => x.heading === tab.heading);\r\n control && control.deactivate();\r\n }\r\n\r\n tabSelected(tab: TabDirective, fromClick: boolean = true): void {\r\n if (!tab) {\r\n return;\r\n }\r\n\r\n const control = this.tabs.find(x => x.heading === tab.heading);\r\n if (control) {\r\n if (fromClick) {\r\n let analyticsEvent;\r\n switch (control.heading) {\r\n case 'Overview':\r\n analyticsEvent = 'click-access-overview-tab';\r\n break;\r\n case 'Assets':\r\n analyticsEvent = 'click-assets-tab';\r\n break;\r\n case 'Returns':\r\n analyticsEvent = 'click-returns-tab';\r\n break;\r\n case 'Settings':\r\n analyticsEvent = 'click-settings-tab';\r\n break;\r\n case 'Output':\r\n analyticsEvent = 'click-output-tab';\r\n break;\r\n }\r\n this._productAnalyticsService.logEvent(analyticsEvent, {});\r\n }\r\n this._returnUpdateLogicService.setActiveTab(control.heading);\r\n control.activate(control.activationParam);\r\n delete control.activationParam;\r\n }\r\n }\r\n\r\n private _initialize(): void {\r\n _.forEach(this.tabs, x => x.initialize());\r\n\r\n if (this._returnAssetsSelectedSub) { this._returnAssetsSelectedSub.unsubscribe(); }\r\n if (this._returnPreviewSelectedSub) { this._returnPreviewSelectedSub.unsubscribe(); }\r\n\r\n this._returnAssetsSelectedSub = this._returnOverviewService.returnAssetsSelected$.subscribe(x => this.assetsTab.select(x));\r\n this._returnPreviewSelectedSub = this._returnOverviewService.returnPreviewSelected$.subscribe(x => this.previewTab.select(x));\r\n\r\n if (!this.isInitialized) {\r\n // the tab component takes an extra cycle to evaluate the headings and set the \"heading\" property; setTimeout() takes care of that\r\n this._timer.setTimeout(() => this.tabSelected(this.tabset.tabs[0], false), 0);\r\n }\r\n\r\n this.isInitialized = true;\r\n }\r\n}\r\n","\r\n
\r\n
\r\n Unlock the batch to update affected return forms with the correct certified form address:\r\n
\r\n
\r\n
\r\n {{ formRevision.formRevisionName }}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { ReturnService } from '../return.service';\r\nimport { Subject, Subscription } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'return-assessor-address-changed-message',\r\n templateUrl: './returnAssessorAddressChangedMessage.component.html',\r\n styleUrls: ['./returnAssessorAddressChangedMessage.component.scss'],\r\n})\r\nexport class ReturnAssessorAddressChangedMessageComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _returnService: ReturnService){}\r\n\r\n private _formRevisions: Compliance.ReturnValidateFormResultModel[];\r\n private _destroy$: Subject = new Subject();\r\n\r\n canShowMessage: boolean;\r\n showMessageDetails: boolean = false;\r\n\r\n get formRevisions(): Compliance.ReturnValidateFormResultModel[]{\r\n return this._formRevisions;\r\n }\r\n\r\n get showWarning(): boolean {\r\n return this.formRevisions && !!this.formRevisions.length;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._updateValidation();\r\n\r\n this._returnService.processStatus$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this._setCanShowMessage(x));\r\n\r\n this._returnService.validateForms$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => {\r\n this._updateValidation();\r\n });\r\n\r\n this._setCanShowMessage(this._returnService.processStatus);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n private async _updateValidation(): Promise {\r\n const warnings = this._returnService.validateFormsResult?.formWarnings || [];\r\n\r\n this._formRevisions = warnings.filter(x => x.errorType === +Compliance.ReturnValidateFormResultEnum.AssessorAddressChanged);\r\n }\r\n\r\n private _setCanShowMessage(status: Compliance.FilingBatchProcessStatusEnum) {\r\n this.canShowMessage = !(status === Compliance.FilingBatchProcessStatusEnum.None\r\n || status === Compliance.FilingBatchProcessStatusEnum.NotStarted\r\n || status === Compliance.FilingBatchProcessStatusEnum.Started\r\n || status === Compliance.FilingBatchProcessStatusEnum.Locking);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n

\r\n {{ filingBatch.description }}\r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n Status:\r\n
\r\n
\r\n {{ filingBatch.status }}\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { ReturnService } from './return.service';\r\nimport { BusyIndicatorService, BusyIndicatorRef, IBusyIndicatorConfig } from '../../Busy-Indicator';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Subscription, Subject, lastValueFrom } from 'rxjs';\r\nimport { IMutexServiceHandler, WeissmanMutexService } from '../WeissmanMutexService';\r\nimport { TaskError } from './Models/taskError';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { AttachmentModalData } from '../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { WeissmanModalService } from '../WeissmanModalService';\r\nimport { ReturnFormsErrorComponent } from './Return-Forms-Error/returnFormsError.component';\r\nimport { RestrictService, Roles, InstanceRights } from '../../Common/Permissions/restrict.service';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { LongRunningProcessRepository } from '../Repositories';\r\nimport { BreadCrumb } from '../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { RETURN_PAGE_HELP } from './returnPage.component.help';\r\nimport { TimerService } from '../../UI-Lib/Utilities';\r\nimport { ReturnAssetsService } from './Return-Parts/Assets/returnAssets.service';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { ReturnUpdateLogicService } from './returnUpdateLogic.service';\r\n\r\n@Component({\r\n selector: 'return-page',\r\n templateUrl: './returnPage.component.html',\r\n providers: [ReturnUpdateLogicService]\r\n})\r\nexport class ReturnPageComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _returnService: ReturnService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _toastsManager: ToastrService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _helpService: HelpService,\r\n private readonly _longRunningProcessRepository: LongRunningProcessRepository,\r\n private readonly _timer: TimerService,\r\n private readonly _returnAssetsService: ReturnAssetsService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _returnUpdateLogicService: ReturnUpdateLogicService\r\n ) { }\r\n\r\n private _busyRef: BusyIndicatorRef;\r\n private _busyRefId = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n private _progressStatusSub: Subscription;\r\n private _progressSub: Subscription;\r\n private _lockChangedSub: Subscription;\r\n private readonly _userMessages: string[] = [\r\n 'Gathering information',\r\n 'Retrieving forms and reports',\r\n 'Loading assets',\r\n 'Summarizing data',\r\n 'Calculating totals',\r\n 'Checking things over',\r\n 'Putting it all together'\r\n ];\r\n private _destroy$: Subject = new Subject();\r\n private _filingBatchId: number;\r\n private _isPrepareDataLongRunningProcess: boolean;\r\n\r\n get company(): Core.CompanyModel { return this._returnService.company; }\r\n get filingBatch(): Compliance.FilingBatchModel { return this._returnService.filingBatch; }\r\n get parcelName(): string { return this._returnService.parcelName; }\r\n get parcelId(): number { return this._returnService.parcelId; }\r\n get canEnterEditMode(): boolean { return this._mutexService.canAcquire(this._returnService.editGroup); }\r\n get canEdit(): boolean { return this._returnService.canEditCompany && !this._returnService.isReturnInReadOnlyMode; }\r\n get canEditCompany(): boolean { return this._returnService.canEditCompany; }\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.filingBatch) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: 'FilingBatch',\r\n entityName: this.filingBatch.description,\r\n entityData: {\r\n typeId: Core.EntityTypes.FilingBatch,\r\n id: this.filingBatch.filingBatchId,\r\n name: this.filingBatch.description\r\n },\r\n singleYear: true,\r\n year: this.filingBatch.taxYear,\r\n disableYears: true,\r\n readOnly: !this.canEditCompany\r\n } as AttachmentModalData;\r\n }\r\n get commentsModel(): CommentModalData {\r\n if (!this.filingBatch) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityID: this.filingBatch.filingBatchId,\r\n entityTypeID: Core.EntityTypes.FilingBatch,\r\n description: this.filingBatch.description,\r\n year: this.filingBatch.taxYear.toString(),\r\n canEdit: this.canEditCompany,\r\n parcelAcctNum: undefined,\r\n parcelID: undefined,\r\n } as CommentModalData;\r\n }\r\n\r\n get showWarning(): boolean {\r\n return this._returnService.compareFormsResult && !this._returnService.compareFormsResult.isDefault;\r\n }\r\n get customReturns(): Compliance.ReturnCustomReturnModel[] {\r\n return this._returnService.compareFormsResult.customReturns;\r\n }\r\n\r\n get attachmentsHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n return 'app.attachments';\r\n }\r\n\r\n get commentsHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n return 'app.comments';\r\n }\r\n\r\n isInitialized: boolean = false;\r\n breadcrumbs: BreadCrumb[] = [];\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(RETURN_PAGE_HELP);\r\n\r\n const filingBatchIdParam = this._routerService.getQuerystringParam('filingBatchId');\r\n\r\n this._filingBatchId = parseInt(filingBatchIdParam);\r\n\r\n try {\r\n await this._loadFilingBatchInfo();\r\n } catch (err) {\r\n this._toastsManager.error(err.error.message);\r\n if (this.company?.companyID) {\r\n this._routerService.go('filingbatchlist', { companyId: this.company.companyID });\r\n } else {\r\n this._routerService.go('home', {});\r\n }\r\n return;\r\n }\r\n\r\n this._isPrepareDataLongRunningProcess = this.filingBatch.isPrepareDataLongRunningProcess;\r\n\r\n this.breadcrumbs = [\r\n {\r\n name: this.filingBatch.companyName,\r\n target: 'company',\r\n options: { companyId: this.filingBatch.companyId }\r\n },\r\n {\r\n name: 'Filing Batches',\r\n target: 'filingBatchList',\r\n options: { companyId: this.filingBatch.companyId }\r\n },\r\n {\r\n name: this.filingBatch.description,\r\n target: 'filingBatchDetails',\r\n options: {\r\n companyId: this.filingBatch.companyId,\r\n filingBatchId: this.filingBatch.filingBatchId\r\n }\r\n }\r\n ];\r\n\r\n await this._loadData();\r\n\r\n this._progressStatusSub = this._returnService.processStatus$.subscribe(x => this._handleStatusChange(x));\r\n\r\n this._lockChangedSub = this._mutexService.lockChanged$.subscribe((x) => {\r\n const isLocked = x && x[this._returnService.editGroup];\r\n if (isLocked) {\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you wish to leave?');\r\n } else {\r\n this._navigationService.disableNavWarning();\r\n }\r\n });\r\n\r\n // get initial status and block UI if a long running process is active\r\n // this needs to run after the global busy indicator in the try/catch has been disposed\r\n this._timer.setTimeout(() => this._handleStatusChange(this._returnService.processStatus), 500);\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._progressStatusSub && this._progressStatusSub.unsubscribe();\r\n this._progressSub && this._progressSub.unsubscribe();\r\n this._lockChangedSub && this._lockChangedSub.unsubscribe();\r\n this._returnService.stop();\r\n this._returnAssetsService.clearScheduleAndFactorFilter();\r\n this._hideBusyIndicator();\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n async refreshBatch(): Promise {\r\n await this._loadData();\r\n this._productAnalyticsService.logEvent('click-batch-refresh', {});\r\n }\r\n\r\n async _loadData(): Promise {\r\n if (!this._isPrepareDataLongRunningProcess) {\r\n let intervalMessageIndex: number = 0;\r\n\r\n const busyConfig: IBusyIndicatorConfig = {\r\n identifier: this._busyIndicatorService.generateUniqueMessageIdentifier(),\r\n title: 'Preparing Returns',\r\n message: this._userMessages[intervalMessageIndex]\r\n };\r\n const busyRef = this._busyIndicatorService.show(busyConfig);\r\n\r\n const intervalId = this._timer.setInterval(() => {\r\n intervalMessageIndex < this._userMessages.length\r\n ? busyRef.updateMessage(this._userMessages[intervalMessageIndex++], busyConfig.identifier)\r\n : clearInterval(intervalId);\r\n }, 2500);\r\n\r\n try {\r\n await this._returnService.prepareData(this._filingBatchId, false);\r\n } finally {\r\n clearInterval(intervalId);\r\n await busyRef.hide();\r\n }\r\n\r\n await this._returnUpdateLogicService.start();\r\n await this._validateForms();\r\n } else {\r\n this._showBusyIndicator('Preparing Returns', 'Working on it...', false, false);\r\n await this._returnService.startPrepareData(this._filingBatchId);\r\n await this._busyRef.setLongRunningProcessId(this._returnService.longRunningProcessId);\r\n }\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n async viewTasks(): Promise {\r\n await this._returnService.viewTasks();\r\n }\r\n\r\n taskError(taskError: TaskError): void {\r\n this._hideBusyIndicator();\r\n this._handleProgressError(taskError.error, taskError.message);\r\n }\r\n\r\n navigateToFilingBatchDetails(): void {\r\n this._routerService.go('filingBatchDetails', {\r\n 'companyId': this.filingBatch.companyId,\r\n 'filingBatchId': this.filingBatch.filingBatchId\r\n });\r\n }\r\n\r\n navigateToParcel(): void {\r\n this._routerService.go('parcelRedirect', {\r\n 'entityID': this.parcelId\r\n });\r\n }\r\n\r\n async canUserEditReturns(): Promise {\r\n return !(await this._restrictService.hasCompanyPermission(this.filingBatch.companyId, Core.AccessRightsEnum.Write)\r\n && this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, this.filingBatch.instanceId));\r\n }\r\n\r\n async resetForms(): Promise {\r\n const busyConfig: IBusyIndicatorConfig = {\r\n message: 'Resetting Forms'\r\n };\r\n const busyRef = this._busyIndicatorService.show(busyConfig);\r\n try {\r\n await this._returnService.resetForms(this._filingBatchId);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private async _handleStatusChange(status: Compliance.FilingBatchProcessStatusEnum): Promise {\r\n let title: string;\r\n let canDismiss: boolean;\r\n let hasAction: boolean = true;\r\n\r\n switch (status) {\r\n case Compliance.FilingBatchProcessStatusEnum.Locking:\r\n title = 'Locking Returns';\r\n canDismiss = true;\r\n break;\r\n case Compliance.FilingBatchProcessStatusEnum.Unlocking:\r\n title = 'Unlocking Returns';\r\n break;\r\n case Compliance.FilingBatchProcessStatusEnum.Signing:\r\n title = 'Signing Applicable Returns';\r\n break;\r\n case Compliance.FilingBatchProcessStatusEnum.Unsigning:\r\n title = 'Unsigning Applicable Returns';\r\n break;\r\n case Compliance.FilingBatchProcessStatusEnum.Finalizing:\r\n title = 'Finalizing Returns';\r\n break;\r\n case Compliance.FilingBatchProcessStatusEnum.PreparingData:\r\n title = 'Preparing Returns';\r\n hasAction = false;\r\n break;\r\n default:\r\n title = null;\r\n break;\r\n }\r\n\r\n if (title && !this._busyRef) {\r\n this._showBusyIndicator(title, 'Working on it...', canDismiss, hasAction, this._returnService.longRunningProcessId);\r\n }\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', canDismiss: boolean = false, hasAction: boolean = true, longRunningProcessId?: number): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this._busyRefId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this._busyRefId,\r\n longRunningProcessId: longRunningProcessId,\r\n title: title ? title : 'Processing',\r\n message,\r\n hasProgressBar: true,\r\n hasAction: hasAction,\r\n actionMessage: (canDismiss) ? 'Cancel' : 'OK',\r\n canDismiss\r\n });\r\n\r\n this._busyRef.onAction().pipe(takeUntil(this._destroy$)).subscribe(async () => {\r\n if (canDismiss && this._returnService.longRunningProcessId) {\r\n await lastValueFrom(this._longRunningProcessRepository.cancel(this._returnService.longRunningProcessId));\r\n } else {\r\n await this._hideBusyIndicator();\r\n this.navigateToFilingBatchDetails();\r\n }\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n if (!this._returnService.company) {\r\n this._returnService.loadPreparedData(this._filingBatchId).then(async () => {\r\n this._hideBusyIndicator();\r\n await this._returnUpdateLogicService.start();\r\n await this._validateForms();\r\n });\r\n } else {\r\n this._hideBusyIndicator();\r\n }\r\n });\r\n\r\n this._busyRef.onDismiss().pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n this._hideBusyIndicator();\r\n this.navigateToFilingBatchDetails();\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._destroy$.next();\r\n }\r\n\r\n private _handleProgressError(e: any, defaultMessage: string) {\r\n let message = defaultMessage;\r\n if (e.error && e.error.message) {\r\n message = e.error.message;\r\n }\r\n\r\n this._toastsManager.error(message);\r\n }\r\n\r\n private async _validateForms(): Promise {\r\n const validateFormsResult = this._returnService.validateFormsResult;\r\n if (validateFormsResult && !validateFormsResult.isValid) {\r\n const result = await this._modalService.showAsync(ReturnFormsErrorComponent, validateFormsResult, 'modal-md');\r\n\r\n if (!result?.accepted\r\n || (result?.errorTypes.includes(Compliance.ReturnValidateFormResultEnum.OneOrMoreFormsAreNotAvailable)\r\n && !this._restrictService.isInRole(Roles.FORMSUNDERDEVELOPMENTVIEW))) {\r\n this.navigateToFilingBatchDetails();\r\n }\r\n }\r\n }\r\n\r\n private async _loadFilingBatchInfo(): Promise {\r\n const busyConfig: IBusyIndicatorConfig = {\r\n identifier: this._busyIndicatorService.generateUniqueMessageIdentifier(),\r\n message: 'Loading...'\r\n };\r\n const busyRef = this._busyIndicatorService.show(busyConfig);\r\n\r\n try {\r\n await this._returnService.loadFilingBatchInfo(this._filingBatchId);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, OnChanges, OnDestroy, Output } from '@angular/core';\r\nimport {\r\n FilingControlReconciliationReport,\r\n ReturnFilingControlAssetFilter,\r\n ReturnFilingControlRow\r\n} from '../../../../Models/filingControlReconciliationReport';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../../../AgGrid';\r\nimport {\r\n ColDef,\r\n FilterChangedEvent,\r\n GridApi,\r\n GridOptions,\r\n GridReadyEvent,\r\n ICellRendererParams,\r\n RowNode\r\n} from 'ag-grid-community';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../../../../AgGrid/ToolPanel/models';\r\nimport { ReturnService } from '../../../../return.service';\r\nimport { GridHelper } from '../../../../../AgGrid/GridHelper';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../../../../AgGrid/MultiSelectTracker';\r\nimport { takeUntil } from 'rxjs/internal/operators/takeUntil';\r\nimport { BehaviorSubject, lastValueFrom, Subject } from 'rxjs';\r\nimport { MessageModalService } from '../../../../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { BusyIndicatorService } from '../../../../../../Busy-Indicator';\r\nimport { ReturnRepository } from '../../../../../Repositories';\r\nimport { FilingControlComponentChanges } from '../filingControl.component';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\n\r\n@Component({\r\n selector: 'filing-control-list-reconciliation-report',\r\n templateUrl: './filingControlList.component.html'\r\n})\r\nexport class FilingControlListReconciliationReportComponent implements OnDestroy, OnChanges {\r\n constructor(\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _returnService: ReturnService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _returnRepository: ReturnRepository) {\r\n this._returnService.isReturnInReadOnlyMode$.pipe(takeUntil(this._destroy$)).subscribe(x => this.isBulkDeleteVisible$.next(this.isBulkUpdateVisible));\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'assessorId', value: 'AssessorId' },\r\n { name: 'assessorName', value: 'AssessorName' },\r\n { name: 'assessorPostmarkAccepted', value: 'AssessorPostmarkAccepted' },\r\n { name: 'assessorOriginalFormsRequired', value: 'AssessorOriginalFormsRequired' },\r\n { name: 'assessorWetSignatureRequired', value: 'AssessorWetSignatureRequired' },\r\n { name: 'siteId', value: 'SiteId' },\r\n { name: 'siteName', value: 'SiteName' },\r\n { name: 'siteProperty', value: 'SiteProperty' },\r\n { name: 'priorFilingId', value: 'PriorFilingId' },\r\n { name: 'priorFilingDescription', value: 'PriorFilingDescription' },\r\n { name: 'calculatedPriorFilingId', value: 'CalculatedPriorFilingId' },\r\n { name: 'calculatedPriorFilingDescription', value: 'CalculatedPriorFilingDescription' },\r\n { name: 'parcelId', value: 'ParcelId' },\r\n { name: 'parcelAcctNumber', value: 'ParcelAcctNumber' },\r\n { name: 'parcelAcctNumberDisplay', value: 'ParcelAcctNumberDisplay' },\r\n { name: 'parcelActivityStatusId', value: 'ParcelActivityStatusId' },\r\n { name: 'companyId', value: 'CompanyId' },\r\n { name: 'companyName', value: 'CompanyName' },\r\n { name: 'cost', value: 'Cost' },\r\n { name: 'depreciatedCost', value: 'DepreciatedCost' },\r\n { name: 'taxLiability', value: 'TaxLiability' },\r\n { name: 'estimatedFMV', value: 'EstimatedFMV' },\r\n { name: 'reportableCost', value: 'ReportableCost' },\r\n { name: 'primaryFormRevisionName', value: 'PrimaryFormRevisionName' },\r\n { name: 'assessorAddress1', value: 'AssessorAddress1' },\r\n { name: 'assessorAddress2', value: 'AssessorAddress2' },\r\n { name: 'assessorCity', value: 'AssessorCity' },\r\n { name: 'assessorState', value: 'AssessorState' },\r\n { name: 'assessorZipReturnId', value: 'AssessorZipReturnId' },\r\n { name: 'primaryFormRevisionId', value: 'PrimaryFormRevisionId' },\r\n { name: 'reportedAssetCount', value: 'ReportedAssetCount' },\r\n { name: 'notReportedAssetCount', value: 'NotReportedAssetCount' },\r\n { name: 'priorYearReportedCost', value: 'PriorYearReportedCost' },\r\n { name: 'priorYearDepreciatedValue', value: 'PriorYearDepreciatedValue' }\r\n ];\r\n private _destroy$: Subject = new Subject();\r\n private _isInitialLoad: boolean = true;\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridId: System.Guid = 'EC61E95D-89DB-47CD-B683-D5B7DDDCC598';\r\n isBulkDeleteVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as ReturnFilingControlRow).parcelId),\r\n 'totals-row': (params) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return false;\r\n }\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow;\r\n },\r\n 'selected-totals-row': (params) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return false;\r\n }\r\n return filingControl.isSelectedTotalsRow;\r\n }\r\n }\r\n })\r\n .withContext(this)\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withFilterChanged(this._updateTotal.bind(this))\r\n .withTextSelection()\r\n .withLoadingOverlay()\r\n .withColumnPinning()\r\n .build();\r\n\r\n @Input() formRevisionId: number;\r\n @Input() data: FilingControlReconciliationReport;\r\n @Input() refreshing: boolean;\r\n\r\n @Output() navigateToAssets: EventEmitter = new EventEmitter();\r\n @Output() navigateToPreview: EventEmitter = new EventEmitter();\r\n @Output() refreshData: EventEmitter = new EventEmitter();\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n get isBulkUpdateVisible(): boolean {\r\n return !this._returnService.isReturnInReadOnly && this.canEdit && this.gridTracker && this.gridTracker.hasSelectedRows();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n if (this._isInitialLoad){\r\n this.gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe(async (x) => {\r\n this.isBulkDeleteVisible$.next(this.isBulkUpdateVisible);\r\n await this._updateSelectedRowsTotals();\r\n });\r\n\r\n this._isInitialLoad = false;\r\n }\r\n\r\n const columns: ColDef[] = [\r\n {\r\n colId: 'grid-column-multiselect',\r\n field: 'parcelId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return null;\r\n }\r\n\r\n return `#/assessor/${filingControl.assessorId}`;\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return '-';\r\n }\r\n\r\n return filingControl.assessorName;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n },\r\n {\r\n headerName: 'Parcel',\r\n field: 'parcelAcctNumberDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n return `#/parcel/${filingControl.parcelId}`;\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow) {\r\n return 'TOTAL';\r\n } else if (filingControl.isSelectedTotalsRow) {\r\n return 'SELECTED';\r\n }\r\n\r\n return filingControl.parcelAcctNumberDisplay;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n return filingControl.parcelAcctNumberDisplay;\r\n }\r\n },\r\n {\r\n headerName: 'Filing',\r\n field: 'filingDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-filing',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n if (filingControl.isMergedParcel) {\r\n // Typically we would use a redirect route but in this case we have the data to go directly to the page\r\n return `#/company/${filingControl.companyId}/site/${filingControl.siteId}/parcel/${filingControl.parcelId}?taxYear=${this._returnService.taxYear}`;\r\n }\r\n if (filingControl.filingId) {\r\n return `#/filing/${filingControl.filingId}`;\r\n }\r\n\r\n return '';\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Address 1',\r\n field: 'assessorAddress1',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Address 2',\r\n field: 'assessorAddress2',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'City',\r\n field: 'assessorCity',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'assessorState',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Zip',\r\n field: 'assessorZip',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return null;\r\n }\r\n\r\n return `#/site/${filingControl.siteId}`;\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return '-';\r\n }\r\n\r\n return filingControl.siteName;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'siteProperty',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return null;\r\n }\r\n\r\n return `#/site/${filingControl.siteId}`;\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return '-';\r\n }\r\n\r\n return filingControl.siteProperty;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return null;\r\n }\r\n\r\n return `#/company/${filingControl.companyId}`;\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return '-';\r\n }\r\n\r\n return filingControl.companyName;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Prior Return',\r\n field: 'priorFilingDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-return',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl && filingControl.priorFilingId) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return null;\r\n }\r\n\r\n return `#/filing/${filingControl.priorFilingId}`;\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return '-';\r\n }\r\n\r\n return filingControl.priorFilingDescription;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: x => {\r\n const filingControl = x.data as ReturnFilingControlRow;\r\n return (filingControl && (!(filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow)) && filingControl.priorFilingId !== filingControl.calculatedPriorFilingId) ? 'ws-override' : null;\r\n }\r\n },\r\n {\r\n headerName: 'Return Form',\r\n field: 'primaryFormRevisionName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-return-form',\r\n newWindow: true,\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return;\r\n }\r\n\r\n this.navigateToPreview.emit(filingControl);\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return '-';\r\n }\r\n\r\n return filingControl.primaryFormRevisionName;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow) {\r\n return true;\r\n }\r\n\r\n const formRevisionId = this.formRevisionId || filingControl.primaryFormRevisionId;\r\n if (!formRevisionId) {\r\n return true;\r\n }\r\n\r\n const returnFormRevision = filingControl.returnFormRevisions?.find(x => x.formRevisionId === formRevisionId);\r\n if (!returnFormRevision) {\r\n return true;\r\n }\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return filingControl && (!(filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow)) && !filingControl.primaryFormRevisionId ? 'cell-validation-error' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Cost',\r\n field: 'cost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assets',\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return;\r\n }\r\n\r\n const assetFilter: ReturnFilingControlAssetFilter = {\r\n primaryFormRevisionId: filingControl.primaryFormRevisionId,\r\n showOnlyAssignedToReportableSchedule: false,\r\n returnIds: [filingControl.returnId]\r\n };\r\n\r\n this.navigateToAssets.emit(assetFilter);\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return this._decimalPipe.transform((filingControl && filingControl.cost) || 0, '1.2-2');\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return (filingControl && filingControl.cost) || 0;\r\n }\r\n },\r\n {\r\n headerName: 'Rep. Cost',\r\n field: 'reportableCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assets',\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return;\r\n }\r\n\r\n const assetFilter: ReturnFilingControlAssetFilter = {\r\n primaryFormRevisionId: filingControl.primaryFormRevisionId,\r\n showOnlyAssignedToReportableSchedule: true,\r\n returnIds: [filingControl.returnId]\r\n };\r\n\r\n this.navigateToAssets.emit(assetFilter);\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return this._decimalPipe.transform((filingControl && filingControl.reportableCost) || 0, '1.2-2');\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return (filingControl && filingControl.reportableCost) || 0;\r\n }\r\n },\r\n {\r\n headerName: 'Dep. Value',\r\n field: 'depreciatedCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assets',\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return;\r\n }\r\n\r\n const assetFilter: ReturnFilingControlAssetFilter = {\r\n primaryFormRevisionId: filingControl.primaryFormRevisionId,\r\n showOnlyAssignedToReportableSchedule: false,\r\n returnIds: [filingControl.returnId]\r\n };\r\n\r\n this.navigateToAssets.emit(assetFilter);\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return this._decimalPipe.transform((filingControl && filingControl.depreciatedCost) || 0, '1.2-2');\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow || filingControl.isSelectedTotalsRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return (filingControl && filingControl.depreciatedCost) || 0;\r\n }\r\n },\r\n {\r\n headerName: 'Est. Tax',\r\n field: 'taxLiability',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return (filingControl && filingControl.taxLiability) || 0;\r\n },\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2')\r\n },\r\n {\r\n headerName: 'Est. FMV',\r\n field: 'estimatedFMV',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2')\r\n },\r\n {\r\n headerName: 'Rep. Asset Count',\r\n field: 'reportedAssetCount',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.0-2')\r\n },\r\n {\r\n headerName: 'Not Rep. Asset Count',\r\n field: 'notReportedAssetCount',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.0-2')\r\n },\r\n {\r\n headerName: 'Prior Year Rep. Cost',\r\n field: 'priorYearReportedCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2')\r\n },\r\n {\r\n headerName: 'Prior Year Rep. Value',\r\n field: 'priorYearDepreciatedValue',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2')\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'parcelAcctNumberDisplay',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n\r\n this._setRowData();\r\n }\r\n\r\n ngOnChanges(changes: FilingControlComponentChanges): void {\r\n if (changes.data) {\r\n this._setRowData();\r\n }\r\n\r\n if (changes.refreshing) {\r\n if (changes.refreshing.currentValue) {\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n } else {\r\n this._gridApi && this._gridApi.hideOverlay();\r\n }\r\n }\r\n }\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const filterModel = this._gridApi.getFilterModel();\r\n const sortModel = this._gridApi.getSortModel();\r\n\r\n const searchParams: Core.SearchModel = {\r\n columnFilters: GridHelper.getFilterColumns(filterModel, this._propertyMap),\r\n sortColumns: GridHelper.getSortModel(sortModel, this._propertyMap)\r\n };\r\n\r\n const lrp$ = this._returnService.exportReturnFilingControlSummary(searchParams, columnsToReturn);\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportReturnFilingControlSummary};\r\n },\r\n canCancel: true\r\n }\r\n\r\n refresh(): void {\r\n this.refreshData.emit();\r\n }\r\n\r\n async bulkDelete(): Promise {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to remove the selected returns?',\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n const selectedRows = this._getSelectedRows();\r\n\r\n const potentiallyConsolidatedParcels = selectedRows.filter(x => x.filingId);\r\n\r\n if (this._returnService.isConsolidatedReturn) {\r\n if (potentiallyConsolidatedParcels.length !== 0) {\r\n let hasConsolidatedParcels: boolean = false;\r\n\r\n for(let potentiallyConsolidatedParcel of potentiallyConsolidatedParcels) {\r\n for(let parcel of this.data.returns) {\r\n if (parcel.isMergedParcel && parcel.filingId === potentiallyConsolidatedParcel.filingId) {\r\n hasConsolidatedParcels = true;\r\n break;\r\n }\r\n }\r\n\r\n if (hasConsolidatedParcels) {\r\n break;\r\n }\r\n }\r\n\r\n if (hasConsolidatedParcels) {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Your selection contains at least one consolidated return. Removing a consolidated return will also remove all related merged returns. Are you sure you want to proceed?',\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n }\r\n }\r\n\r\n const mergedParcels = selectedRows.filter(x => x.isMergedParcel);\r\n\r\n let isInvalidSelection: boolean = false;\r\n mergedParcels.forEach((x) => {\r\n const consolidatedParcel = potentiallyConsolidatedParcels.find(y => y.filingId === x.filingId);\r\n\r\n if (!consolidatedParcel) {\r\n isInvalidSelection = true;\r\n this._messageModalService.alert(\r\n 'Your selection contains at least one merged return without the related consolidated return. Merged returns cannot be removed on their own.');\r\n }\r\n });\r\n\r\n if (isInvalidSelection) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n let numberOfParcelsToRemove = 0;\r\n potentiallyConsolidatedParcels.forEach(x => {\r\n numberOfParcelsToRemove++;\r\n numberOfParcelsToRemove += this.data.returns.filter(y => !y.filingId && y.filingId === x.filingId).length;\r\n });\r\n\r\n if (numberOfParcelsToRemove === this.data.returns.filter(x => !x.isTotalRow).length) {\r\n await this._messageModalService.alert('The last filing can\\'t be removed from the filing control. Please return to the batch and remove it from the filings list.');\r\n return;\r\n }\r\n\r\n let busyRef = this._busyIndicatorService.show({ message: 'Removing parcels' });\r\n try {\r\n const model: Compliance.SelectedRowsModel = {\r\n selectAllRows: this.gridTracker.getSelectedRowsModel().selectAllRows,\r\n selectedRows: selectedRows.filter(x => x.filingId).map(x => x.filingId)\r\n };\r\n await lastValueFrom(this._returnRepository.removeFilings(this._returnService.filingBatchId, model));\r\n await busyRef.hide();\r\n\r\n busyRef = this._busyIndicatorService.show({ message: 'Loading returns' });\r\n\r\n await this._returnService.prepareData(this._returnService.filingBatchId, true);\r\n await this._returnService.notifyParcelsChanged();\r\n this.gridTracker.clear(true);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n get canEdit(): boolean {\r\n return this._returnService.canEditCompany;\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.data)) {\r\n return;\r\n }\r\n\r\n this.gridTracker && this.gridTracker.clear();\r\n\r\n this._gridApi.setRowData(this.data.returns.filter(x => !x.isTotalRow));\r\n this._gridApi.setPinnedBottomRowData(this.data.returns.filter(x => x.isTotalRow));\r\n }\r\n\r\n private async _updateSelectedRowsTotals(): Promise {\r\n const selectedRows = this._getSelectedRows();\r\n\r\n if (selectedRows.length === 0) {\r\n if (this._gridApi.getPinnedBottomRowCount() === 2) {\r\n this._gridApi.setPinnedBottomRowData([this._gridApi.getPinnedBottomRow(0).data]);\r\n }\r\n } else {\r\n const selectedRow: ReturnFilingControlRow = {\r\n isGroupRow: false,\r\n isSubTotalRow: false,\r\n isTotalRow: false,\r\n isExpanded: false,\r\n isSelectedTotalsRow: true,\r\n returnCount: 0,\r\n reportableCost: selectedRows.reduce((acc, y) => (acc += y.reportableCost || 0), 0),\r\n cost: selectedRows.reduce((acc, y) => (acc += y.cost || 0), 0),\r\n depreciatedCost: selectedRows.reduce((acc, y) => (acc += y.depreciatedCost || 0), 0),\r\n taxLiability: selectedRows.reduce((acc, y) => (acc += y.taxLiability || 0), 0),\r\n estimatedFMV: selectedRows.reduce((acc, y) => (acc += y.estimatedFMV || 0), 0),\r\n priorYearReportedCost: selectedRows.reduce((acc, y) => (acc += y.priorYearReportedCost || 0), 0),\r\n priorYearDepreciatedValue: selectedRows.reduce((acc, y) => (acc += y.priorYearDepreciatedValue || 0), 0),\r\n reportedAssetCount: selectedRows.reduce((acc, y) => (acc += y.reportedAssetCount || 0), 0),\r\n notReportedAssetCount: selectedRows.reduce((acc, y) => (acc += y.notReportedAssetCount || 0), 0)\r\n };\r\n\r\n this._gridApi.setPinnedBottomRowData([this._gridApi.getPinnedBottomRow(0).data, selectedRow]);\r\n }\r\n }\r\n\r\n private _getSelectedRows(): ReturnFilingControlRow[] {\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n\r\n return this.data.returns.filter(x =>\r\n selectedRowsModel.selectAllRows && selectedRowsModel.selectedRows.indexOf(x.parcelId) === -1 ||\r\n !selectedRowsModel.selectAllRows && selectedRowsModel.selectedRows.indexOf(x.parcelId) !== -1);\r\n }\r\n\r\n private _updateTotal(event: FilterChangedEvent): void {\r\n if (!this.data) {\r\n return;\r\n }\r\n\r\n let reportableCost = 0;\r\n let cost = 0;\r\n let depreciatedCost = 0;\r\n let priorYearReportedCost = 0;\r\n let priorYearDepreciationValue = 0;\r\n\r\n this._gridApi.forEachNodeAfterFilter((rowNode: RowNode) => {\r\n const filingControl = rowNode.data as ReturnFilingControlRow;\r\n if (filingControl) {\r\n reportableCost += filingControl.reportableCost || 0;\r\n cost += filingControl.cost || 0;\r\n depreciatedCost += filingControl.depreciatedCost || 0;\r\n priorYearReportedCost += filingControl.priorYearReportedCost || 0;\r\n priorYearDepreciationValue += filingControl.priorYearDepreciatedValue || 0;\r\n }\r\n });\r\n\r\n const rowNode = this._gridApi.getPinnedBottomRow(0);\r\n if (rowNode) {\r\n const filingControl = rowNode.data as ReturnFilingControlRow;\r\n if (filingControl) {\r\n filingControl.reportableCost = reportableCost;\r\n filingControl.cost = cost;\r\n filingControl.depreciatedCost = depreciatedCost;\r\n filingControl.priorYearReportedCost = priorYearReportedCost;\r\n filingControl.priorYearDepreciatedValue = priorYearDepreciationValue;\r\n }\r\n\r\n this._gridApi.redrawRows({rowNodes: [rowNode]});\r\n }\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n const queryResultModel: Compliance.QueryResultModel = {\r\n lastModifiedTimestamp: new Date(),\r\n totalRows: rows.length,\r\n totalValidRows: rows.length,\r\n data: rows.map((x) => {\r\n const row = x.data as ReturnFilingControlRow;\r\n return row && row.parcelId;\r\n })\r\n };\r\n\r\n return Promise.resolve(queryResultModel);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
{{ filingControl.assessorName }}
\r\n
\r\n
\r\n {{ filingControl.returnCount }} return{{ filingControl.returnCount == 1 ? '' : 's' }}\r\n
\r\n
\r\n
\r\n
\r\n \r\n
{{ filingControl.assessorAddress1 }}
\r\n
{{ filingControl.assessorAddress2 }}
\r\n
\r\n
{{ filingControl.assessorCity }}{{filingControl.assessorCity ? ', ': ''}}
\r\n
{{ filingControl.assessorState }}
\r\n
{{ filingControl.assessorZip }}
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
{{ 'Postmark ' + (filingControl.assessorPostmarkAccepted ? '' : 'Not ') + 'Accepted' }}
\r\n
\r\n
\r\n
{{ 'Original Forms ' + (filingControl.assessorOriginalFormsRequired ? '' : 'Not ') + 'Required' }}
\r\n
\r\n
\r\n
{{ 'Wet Signature ' + (filingControl.assessorWetSignatureRequired ? '' : 'Not ') + 'Required' }}
\r\n
\r\n
\r\n
\r\n
\r\n","
\r\n
\r\n
\r\n Returns\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ReturnFilingControlRow } from '../../../../Models/filingControlReconciliationReport';\r\n\r\nexport interface ICellRendererParamsForFilingControlReconciliationReportAssessorRenderer extends ICellRendererParams {\r\n}\r\n\r\n@Component({\r\n selector: 'filing-control-reconciliation-report-assessor',\r\n templateUrl: './agGridAssessorCellRenderer.component.html'\r\n\r\n})\r\nexport class FilingControlReconciliationReportAssessorRenderer implements ICellRendererAngularComp {\r\n constructor(\r\n ) { }\r\n\r\n filingControl: ReturnFilingControlRow;\r\n\r\n private _params: ICellRendererParamsForFilingControlReconciliationReportAssessorRenderer;\r\n \r\n agInit(params: ICellRendererParamsForFilingControlReconciliationReportAssessorRenderer): void {\r\n this._params = params;\r\n this.filingControl = params.data as ReturnFilingControlRow;\r\n }\r\n \r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n toggleExpanded(): void {\r\n this.filingControl.isExpanded = !this.filingControl.isExpanded;\r\n this._params.api.resetRowHeights();\r\n }\r\n}","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ReturnFilingControlRow } from '../../../../Models/filingControlReconciliationReport';\r\n\r\nexport interface ICellRendererParamsForConsolidatedGroupCellRenderer extends ICellRendererParams {\r\n toggleShowMergedParcels: (params: ICellRendererParamsForConsolidatedGroupCellRenderer) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'ws-ag-grid-consolidated-group',\r\n template: `\r\n \r\n \r\n \r\n Total\r\n \r\n {{filingControl.parcelAcctNumberDisplay}}\r\n \r\n `\r\n})\r\nexport class AgGridConsolidatedGroupCellRenderer implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForConsolidatedGroupCellRenderer;\r\n filingControl: ReturnFilingControlRow;\r\n link: string;\r\n\r\n agInit(params: ICellRendererParamsForConsolidatedGroupCellRenderer): void {\r\n this.params = params;\r\n this.filingControl = params.data as ReturnFilingControlRow;\r\n this.link = `#/parcel/${this.filingControl.parcelId}`;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component, Input, Output, EventEmitter, ViewEncapsulation, OnChanges } from '@angular/core';\r\nimport { FilingControlReconciliationReport, ReturnFilingControlRow, ReturnFilingControlAssetFilter } from '../../../../Models/filingControlReconciliationReport';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from '../../../../../AgGrid';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, RowNode, ICellRendererParams } from 'ag-grid-community';\r\nimport { AgGridLinkCellRendererComponent } from '../../../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AgGridLinkCellRendererParams } from '../../../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { FilingControlReconciliationReportAssessorRenderer, ICellRendererParamsForFilingControlReconciliationReportAssessorRenderer } from './agGridAssessorCellRenderer.component';\r\nimport { FilingControlGroupBy } from '../../returnOverview.service';\r\nimport { AgGridConsolidatedGroupCellRenderer, ICellRendererParamsForConsolidatedGroupCellRenderer } from './agGridConsolidatedGroupCellRenderer.component';\r\nimport { ReturnService } from '../../../../return.service';\r\nimport { FilingControlComponentChanges } from '../filingControl.component';\r\n\r\n@Component({\r\n selector: 'filing-control-grouped-reconciliation-report',\r\n templateUrl: './filingControlGrouped.component.html',\r\n styleUrls: ['./filingControlGrouped.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class FilingControlGroupedReconciliationReportComponent implements OnChanges {\r\n constructor(\r\n private readonly _returnService: ReturnService,\r\n private readonly _decimalPipe: DecimalPipe) { }\r\n\r\n @Input()\r\n set groupBy(groupBy: FilingControlGroupBy) {\r\n this._groupBy = groupBy;\r\n this._setRowData();\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _groupBy: FilingControlGroupBy;\r\n\r\n gridId: System.Guid = 'E19FB903-3CE1-445C-82EB-5756B9F7C594';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'totals-row': (params) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return false;\r\n }\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow;\r\n },\r\n 'group-row': (params) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return false;\r\n }\r\n return filingControl.isGroupRow;\r\n }\r\n }\r\n })\r\n .withContext(this)\r\n .withColumnResize()\r\n .withFullWidthCell(\r\n this._isFullWidthRow.bind(this),\r\n FilingControlReconciliationReportAssessorRenderer,\r\n {} as ICellRendererParamsForFilingControlReconciliationReportAssessorRenderer)\r\n .withRowHeight((params) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return this._groupBy === FilingControlGroupBy.Assessor && filingControl && filingControl.isExpanded ? 112 : 26;\r\n })\r\n .withTextSelection()\r\n .withLoadingOverlay()\r\n .build();\r\n\r\n @Input() formRevisionId: number;\r\n @Input() data: FilingControlReconciliationReport;\r\n @Input() refreshing: boolean;\r\n\r\n @Output() navigateToAssets: EventEmitter = new EventEmitter();\r\n @Output() navigateToPreview: EventEmitter = new EventEmitter();\r\n @Output() refreshData: EventEmitter = new EventEmitter();\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Parcel',\r\n field: 'parcelAcctNumberDisplay',\r\n width: (!this._returnService.isConsolidatedReturn) ? AgGridColumns.textColumnWidth : AgGridColumns.textColumnLargeWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n return filingControl.parcelAcctNumberDisplay;\r\n },\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n cellRendererFramework: AgGridConsolidatedGroupCellRenderer,\r\n cellRendererParams: {\r\n toggleShowMergedParcels: this._toggleShowMergedParcels.bind(this)\r\n } as ICellRendererParamsForConsolidatedGroupCellRenderer\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n return `#/site/${filingControl.siteId}`;\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow) {\r\n return '-';\r\n }\r\n\r\n return filingControl.siteName;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n return `#/company/${filingControl.companyId}`;\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow) {\r\n return '-';\r\n }\r\n\r\n return filingControl.companyName;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Prior Return',\r\n field: 'priorFilingDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-return',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl && filingControl.priorFilingId) {\r\n return '';\r\n }\r\n\r\n return `#/filing/${filingControl.priorFilingId}`;\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow) {\r\n return '-';\r\n }\r\n\r\n return filingControl.priorFilingDescription;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return (filingControl && (!(filingControl.isSubTotalRow || filingControl.isTotalRow)) && filingControl.priorFilingId !== filingControl.calculatedPriorFilingId) ? 'ws-override' : null;\r\n }\r\n },\r\n {\r\n headerName: 'Return Form',\r\n field: 'primaryFormRevisionName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-return-form',\r\n newWindow: true,\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return;\r\n }\r\n\r\n this.navigateToPreview.emit(filingControl);\r\n },\r\n getButtonLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow) {\r\n return '-';\r\n }\r\n\r\n return filingControl.primaryFormRevisionName;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n if (filingControl.isSubTotalRow || filingControl.isTotalRow) {\r\n return true;\r\n }\r\n\r\n const formRevisionId = this.formRevisionId || filingControl.primaryFormRevisionId;\r\n if (!formRevisionId) {\r\n return true;\r\n }\r\n\r\n const returnFormRevision = filingControl.returnFormRevisions.find(x => x.formRevisionId === formRevisionId);\r\n if (!returnFormRevision) {\r\n return true;\r\n }\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return filingControl && (!(filingControl.isSubTotalRow || filingControl.isTotalRow)) && !filingControl.primaryFormRevisionId ? 'cell-validation-error' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Total Cost',\r\n field: 'cost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assets',\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return;\r\n }\r\n\r\n const assetFilter: ReturnFilingControlAssetFilter = {\r\n primaryFormRevisionId: filingControl.primaryFormRevisionId,\r\n showOnlyAssignedToReportableSchedule: false,\r\n returnIds: [filingControl.returnId]\r\n };\r\n\r\n this.navigateToAssets.emit(assetFilter);\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return this._decimalPipe.transform((filingControl && filingControl.cost) || 0, '1.2-2');\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return (filingControl && filingControl.cost) || 0;\r\n },\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Reported Cost',\r\n field: 'reportableCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assets',\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return;\r\n }\r\n\r\n const assetFilter: ReturnFilingControlAssetFilter = {\r\n primaryFormRevisionId: filingControl.primaryFormRevisionId,\r\n showOnlyAssignedToReportableSchedule: true,\r\n returnIds: [filingControl.returnId]\r\n };\r\n\r\n this.navigateToAssets.emit(assetFilter);\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return this._decimalPipe.transform((filingControl && filingControl.reportableCost) || 0, '1.2-2');\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return (filingControl && filingControl.cost) || 0;\r\n },\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Depreciated Value',\r\n field: 'depreciatedCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assets',\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return;\r\n }\r\n\r\n const assetFilter: ReturnFilingControlAssetFilter = {\r\n primaryFormRevisionId: filingControl.primaryFormRevisionId,\r\n showOnlyAssignedToReportableSchedule: false,\r\n returnIds: [filingControl.returnId]\r\n };\r\n\r\n this.navigateToAssets.emit(assetFilter);\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return this._decimalPipe.transform((filingControl && filingControl.depreciatedCost) || 0, '1.2-2');\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return (filingControl && filingControl.depreciatedCost) || 0;\r\n },\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Est. Tax',\r\n field: 'taxLiability',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return (filingControl && filingControl.taxLiability) || 0;\r\n },\r\n cellClass: 'ag-numeric-cell',\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2')\r\n },\r\n {\r\n headerName: 'Est. FMV',\r\n field: 'estimatedFMV',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assets',\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return;\r\n }\r\n\r\n const assetFilter: ReturnFilingControlAssetFilter = {\r\n primaryFormRevisionId: filingControl.primaryFormRevisionId,\r\n showOnlyAssignedToReportableSchedule: true,\r\n returnIds: [filingControl.returnId]\r\n };\r\n\r\n this.navigateToAssets.emit(assetFilter);\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return this._decimalPipe.transform((filingControl && filingControl.estimatedFMV) || 0, '1.2-2');\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return true;\r\n }\r\n\r\n return filingControl.isSubTotalRow || filingControl.isTotalRow;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n return (filingControl && filingControl.cost) || 0;\r\n },\r\n cellClass: 'ag-numeric-cell'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n ngOnChanges(changes: FilingControlComponentChanges): void {\r\n if (changes.data) {\r\n this._setRowData();\r\n }\r\n\r\n if (changes.refreshing) {\r\n if (changes.refreshing.currentValue) {\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n } else {\r\n this._gridApi && this._gridApi.hideOverlay();\r\n }\r\n }\r\n }\r\n\r\n refresh(): void {\r\n this.refreshData.emit();\r\n }\r\n\r\n private _isFullWidthRow(rowNode: RowNode): boolean {\r\n const filingControl = rowNode.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return false;\r\n }\r\n return this._groupBy === FilingControlGroupBy.Assessor && filingControl.isGroupRow;\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.data)) {\r\n return;\r\n }\r\n\r\n const data = (this._groupBy === FilingControlGroupBy.Consolidated)\r\n ? this.data.consolidatedReturnGroups.filter(x => x.isGroupRow || x.isExpanded || x.isSubTotalRow || x.isTotalRow)\r\n : this.data.groupedReturns;\r\n\r\n this._gridApi.setRowData(data.filter(x => !x.isTotalRow));\r\n this._gridApi.setPinnedBottomRowData(data.filter(x => x.isTotalRow));\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _toggleShowMergedParcels(params: ICellRendererParamsForConsolidatedGroupCellRenderer): void {\r\n const filingControl = params.data as ReturnFilingControlRow;\r\n if (!filingControl) {\r\n return;\r\n }\r\n const isShown = !filingControl.isExpanded;\r\n this.data.consolidatedReturnGroups.forEach(x => {\r\n if (x.returnId === filingControl.returnId) {\r\n x.isExpanded = isShown;\r\n }\r\n });\r\n\r\n this._setRowData();\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { AttachmentModalData } from '../../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../../Comments/comments.service';\r\n\r\nexport interface ICellRendererParamsForFilingBatchListGridAction extends ICellRendererParams {\r\n canEdit: boolean;\r\n viewDetails: (params: ICellRendererParamsForFilingBatchListGridAction) => void;\r\n delete: (params: ICellRendererParamsForFilingBatchListGridAction) => void;\r\n canDelete: (params: ICellRendererParamsForFilingBatchListGridAction) => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n`\r\n})\r\nexport class FilingBatchListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForFilingBatchListGridAction;\r\n filingBatch: Compliance.FilingBatchModel;\r\n attachmentModalData: AttachmentModalData;\r\n commentModalData: CommentModalData;\r\n\r\n agInit(params: ICellRendererParamsForFilingBatchListGridAction): void {\r\n this.params = params;\r\n this.filingBatch = params.data as Compliance.FilingBatchModel;\r\n\r\n if (!this.filingBatch) {\r\n return;\r\n }\r\n this.attachmentModalData = {\r\n entityType: 'FilingBatch', //todo: make this a constant generated typescript value\r\n entityName: this.filingBatch.description,\r\n year: this.filingBatch.taxYear,\r\n disableYears: true,\r\n singleYear: true,\r\n entityData: {\r\n typeId: Core.EntityTypes.FilingBatch,\r\n id: this.filingBatch.filingBatchId,\r\n name: this.filingBatch.description\r\n },\r\n readOnly: !this.params.canEdit\r\n } as AttachmentModalData;\r\n\r\n this.commentModalData = {\r\n entityID: this.filingBatch.filingBatchId,\r\n entityTypeID: Core.EntityTypes.FilingBatch,\r\n entityName: this.filingBatch.description,\r\n parcelAcctNum: null,\r\n canEdit: this.params.canEdit,\r\n description: null,\r\n parcelID: null,\r\n year: this.filingBatch.taxYear ? this.filingBatch.taxYear.toString() : null\r\n } as CommentModalData;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this.params.viewDetails(this.params);\r\n }\r\n\r\n onDeleteClicked(): void {\r\n this.params.delete(this.params);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n Returns\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { FilingBatchRepository } from '../../Repositories';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../AgGrid';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\nexport interface FilingBatchListDataSourceParams {\r\n includeCompleted: boolean;\r\n companyId: number;\r\n}\r\n\r\nexport class FilingBatchListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _filingBatchRepository: FilingBatchRepository,\r\n protected _dataSourceParamsFn: () => FilingBatchListDataSourceParams\r\n ) { super(_gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'companyName', value: Compliance.FilingBatchPropertyEnum.Company },\r\n { name: 'taxYear', value: Compliance.FilingBatchPropertyEnum.TaxYear },\r\n { name: 'stateName', value: Compliance.FilingBatchPropertyEnum.State },\r\n { name: 'description', value: Compliance.FilingBatchPropertyEnum.Description },\r\n { name: 'filingCount', value: Compliance.FilingBatchPropertyEnum.FilingCount },\r\n { name: 'dueDate', value: Compliance.FilingBatchPropertyEnum.DueDate },\r\n { name: 'completedDate', value: Compliance.FilingBatchPropertyEnum.CompletedDate },\r\n { name: 'status', value: Compliance.FilingBatchPropertyEnum.Status },\r\n { name: 'displayId', value: Compliance.FilingBatchPropertyEnum.DisplayId }\r\n ];\r\n\r\n protected canGetRows(): boolean {\r\n return (this._dataSourceParams.companyId !== null);\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Compliance.FilingBatchSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n includeCompleted: this._dataSourceParams.includeCompleted\r\n };\r\n\r\n const result = await lastValueFrom>(this._filingBatchRepository.getList(this._dataSourceParams.companyId, searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.SearchModel = this.getSearchModel(startIndex, endIndex);\r\n\r\n return await lastValueFrom(this._filingBatchRepository.getRowIds(this._dataSourceParams.companyId, searchParams));\r\n }\r\n\r\n getSearchModel(startIndex?: number, endIndex?: number): Compliance.FilingBatchSearchModel {\r\n return {\r\n pagination: {\r\n skip: (startIndex) ? startIndex : 0,\r\n take: (endIndex) ? endIndex - startIndex + 1 : 0\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n includeCompleted: this._dataSourceParams.includeCompleted\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForFilingBatchProgressCell extends ICellRendererParams {\r\n resume: (params: ICellRendererParamsForFilingBatchProgressCell) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'filing-batch-list-progress-status',\r\n template: ''\r\n})\r\nexport class FilingBatchProgressCellRendererComponent implements ICellRendererAngularComp {\r\n filingBatch: Compliance.FilingBatchModel;\r\n params: ICellRendererParamsForFilingBatchProgressCell;\r\n\r\n agInit(params: ICellRendererParamsForFilingBatchProgressCell): void {\r\n this.filingBatch = params.data as Compliance.FilingBatchModel;\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const FILING_BATCH_LIST_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'filing-batch-list.completed',\r\n tooltipText: 'Include filing batches where all tasks have been completed.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'filing-batch-list.new-filing-batch',\r\n tooltipText: 'New filing batch'\r\n },\r\n {\r\n helpContentId: 'filing-batch-list.reconciliation-report',\r\n tooltipText: 'Export reconciliation report'\r\n },\r\n {\r\n helpContentId: 'filing-batch-list.reconciliation-report-select',\r\n tooltipText: 'Select locked or completed batches to export reconciliation report'\r\n }\r\n];\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Filing Batches\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { RestrictService, InstanceRights } from '../../../Common/Permissions/restrict.service';\r\nimport { FilingBatchRepository, LongRunningProcessRepository } from '../../Repositories';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, RowNode } from 'ag-grid-community';\r\nimport { WeissmanDateFormatPipe } from '../../../UI-Lib/Pipes';\r\nimport { FilingBatchService } from '../filingBatch.service';\r\nimport { FilingBatchListGridActionCellRendererComponent, ICellRendererParamsForFilingBatchListGridAction } from './agGridActionCellRenderer.component';\r\nimport { FilingBatchListAgGridDataSource, FilingBatchListDataSourceParams } from './agGridDataSource';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from '../../AgGrid';\r\nimport { FilingBatchProgressCellRendererComponent, ICellRendererParamsForFilingBatchProgressCell } from './agGridProgressCellRenderer.component';\r\nimport { Subscription, lastValueFrom } from 'rxjs';\r\nimport { WebsocketListenerService } from '../../websocketListener.service';\r\nimport { AgGridLinkCellRendererComponent } from '../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AgGridLinkCellRendererParams } from '../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { FILING_BATCH_LIST_HELP } from './filingBatchList.component.help';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectedCellRenderer, AgGridMultiSelectTracker, AgGridMultiSelectCellRendererParams } from '../../AgGrid/MultiSelectTracker';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { ReturnRepository } from '../../Repositories';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\n\r\n@Component({\r\n templateUrl: './filingBatchList.component.html',\r\n selector: 'filing-batch-list',\r\n styleUrls: ['./filingBatchList.component.scss']\r\n})\r\nexport class FilingBatchListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _filingBatchRepository: FilingBatchRepository,\r\n private readonly _filingBatchService: FilingBatchService,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _websocketListenerService: WebsocketListenerService,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _helpService: HelpService,\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _longRunningProcessRepository: LongRunningProcessRepository\r\n ) { }\r\n\r\n // this component needs to load initialization data before any UI can be rendered\r\n // it will be considered initialized when all ngOnInit calls have finished executing\r\n isInitialized: boolean = false;\r\n breadcrumbs: BreadCrumb[] = [];\r\n companyId: number;\r\n companyName: string;\r\n includeCompleted: boolean = false;\r\n canEdit: boolean = false;\r\n gridId: System.Guid = '083E55EF-BB1A-4D93-9782-B725C8FE3C8B';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => {\r\n const gridRow = params.data as Compliance.FilingBatchModel;\r\n return gridRow && this.gridTracker.isRowSelected(gridRow.filingBatchId);\r\n },\r\n 'row-completed': (params) => {\r\n const gridRow = params.data as Compliance.FilingBatchModel;\r\n return gridRow && gridRow.completedDate !== null;\r\n }\r\n }\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: FilingBatchListAgGridDataSource;\r\n private _filingBatchStatusChangeSub: Subscription;\r\n private _selectedRowModel: { filingBatchId: number, isLockedOrCompleted: boolean; }[] = [];\r\n\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n get reportExportHelp(): string {\r\n return (this.rowsSelected) ? 'filing-batch-list.reconciliation-report' : 'filing-batch-list.reconciliation-report-select';\r\n }\r\n\r\n get rowsSelected(): boolean {\r\n return this.gridTracker && this.gridTracker.getSelectedRowsCount() > 0;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(FILING_BATCH_LIST_HELP);\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n\r\n const responses = await Promise.all([\r\n this._companyService.getInfoForCompliance(this.companyId),\r\n this._restrictService.hasCompanyPermission(this.companyId, Core.AccessRightsEnum.Write)\r\n ]);\r\n\r\n const company = responses[0];\r\n\r\n if (!(company.ppReturnPreparationAllowed && this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, company.instanceID))) {\r\n this.navigateToUnauthorized();\r\n return Promise.resolve();\r\n }\r\n\r\n if (company.companyID !== company.topLevelCompanyId) {\r\n this.navigateToUnauthorized();\r\n return Promise.resolve();\r\n }\r\n\r\n this.companyName = company.companyName;\r\n this.canEdit = responses[1];\r\n\r\n this.breadcrumbs.push({\r\n name: this.companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n });\r\n\r\n this._filingBatchStatusChangeSub = this._websocketListenerService.longRunningProcessStatusChange$.subscribe(async (x) => {\r\n if (x.processType !== Compliance.LongRunningProcessTypeEnum.Return) {\r\n return;\r\n }\r\n\r\n if (!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const rowNode: RowNode = this._gridDataSource.getShownNodes().find(r => {\r\n const filingBatch = r.data as Compliance.FilingBatchModel;\r\n return filingBatch && filingBatch.filingBatchId === x.entityId;\r\n });\r\n\r\n if(!rowNode) {\r\n return;\r\n }\r\n\r\n await this._gridDataSource.updateRow(y => {\r\n const rowModel = y.data as Compliance.FilingBatchModel;\r\n return rowModel && rowModel.filingBatchId === x.entityId;\r\n },\r\n async (y) => {\r\n const filingBatch: Compliance.FilingBatchModel = await lastValueFrom(this._filingBatchRepository.get(x.entityId));\r\n filingBatch.dueDate = y.data.dueDate; // todo: grid is sorted by due date by default, date comparison always returns false\r\n return filingBatch;\r\n });\r\n });\r\n\r\n this.isInitialized = true;\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._filingBatchStatusChangeSub && this._filingBatchStatusChangeSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n const columns: ColDef[] = [\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'filingBatchId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n lockVisible: true,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n resizable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectCellRendererParams\r\n },\r\n {\r\n headerName: 'Batch #',\r\n field: 'displayId',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnLargeWidth\r\n },\r\n {\r\n headerName: 'Progress',\r\n field: 'statusCode',\r\n width: 175,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n sortable: false,\r\n cellRendererFramework: FilingBatchProgressCellRendererComponent,\r\n cellRendererParams: {\r\n resume: this._onProgressViewDetails.bind(this)\r\n } as ICellRendererParamsForFilingBatchProgressCell\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Tax Year',\r\n field: 'taxYear',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'stateName',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: '# Filings',\r\n field: 'filingCount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell',\r\n valueFormatter: (params) => {\r\n return this._decimalPipe.transform(params.value, '1.0-0');\r\n }\r\n },\r\n {\r\n headerName: 'Due',\r\n field: 'dueDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n return this._datePipe.transform(params.value, true);\r\n }\r\n },\r\n {\r\n headerName: 'Completed Date',\r\n field: 'completedDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: (params) => {\r\n return params.value ? this._datePipe.transform(params.value, true) : null;\r\n }\r\n },\r\n {\r\n headerName: 'Status',\r\n field: 'status',\r\n width: AgGridColumns.textColumnWidth,\r\n sortable: false,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-task-series',\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n return null;\r\n },\r\n onClick: this._viewTasks.bind(this)\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Progress Error',\r\n field: 'longRunningProcessError',\r\n width: AgGridColumns.textColumnWidth,\r\n sortable: false,\r\n hide: true\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(4),\r\n minWidth: AgGridColumns.getActionColumnWidth(4),\r\n maxWidth: AgGridColumns.getActionColumnWidth(4),\r\n lockPinned: true,\r\n suppressColumnsToolPanel: true,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n sortable: false,\r\n cellRendererFramework: FilingBatchListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this._onViewDetails.bind(this),\r\n delete: this._delete.bind(this),\r\n canDelete: this._canDelete.bind(this),\r\n canEdit: this.canEdit\r\n } as ICellRendererParamsForFilingBatchListGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'dueDate',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n addNew(): void {\r\n this._routerService.go('filingBatchDetails', {\r\n 'companyId': this.companyId,\r\n 'filingBatchId': null\r\n });\r\n }\r\n\r\n async exportReconciliationReport(): Promise {\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n const gridModel = this._gridDataSource.getSearchModel();\r\n\r\n const searchModel: Compliance.ReturnReconciliationSearchModel = {\r\n includeCompleted: this.includeCompleted,\r\n columnFilters: gridModel.columnFilters,\r\n pagination: gridModel.pagination,\r\n range: gridModel.range,\r\n sortColumns: gridModel.sortColumns,\r\n selectAllRows: selectedRowsModel.selectAllRows,\r\n selectedRows: selectedRowsModel.selectedRows\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Exporting' });\r\n\r\n try {\r\n await lastValueFrom(this._returnRepository.exportReconciliation(this.companyId, searchModel));\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n refresh(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n onIncludeCompletedChange(): void {\r\n this.refresh();\r\n }\r\n\r\n private _canDelete(params: ICellRendererParamsForFilingBatchListGridAction): boolean {\r\n const filingBatch = params.data as Compliance.FilingBatchModel;\r\n if (!filingBatch) {\r\n return false;\r\n }\r\n\r\n return this.canEdit && !this._filingBatchService.isReadOnly(filingBatch.processStatus);\r\n }\r\n\r\n private async _delete(params: ICellRendererParamsForFilingBatchListGridAction): Promise {\r\n const filingBatch = params.data as Compliance.FilingBatchModel;\r\n if (!filingBatch) {\r\n return;\r\n }\r\n\r\n const deleted = await this._deleteFilingBatch(filingBatch);\r\n if (deleted) {\r\n this._refreshDataSource();\r\n }\r\n }\r\n\r\n private _onProgressViewDetails(params: ICellRendererParamsForFilingBatchProgressCell): void {\r\n const filingBatch = params.data as Compliance.FilingBatchModel;\r\n this._navigateToFilingBatchDetails(filingBatch);\r\n }\r\n\r\n private _onViewDetails(params: ICellRendererParamsForFilingBatchListGridAction) {\r\n const filingBatch = params.data as Compliance.FilingBatchModel;\r\n this._navigateToFilingBatchDetails(filingBatch);\r\n }\r\n\r\n private _navigateToFilingBatchDetails(filingBatch: Compliance.FilingBatchModel): void {\r\n if (!filingBatch) {\r\n return;\r\n }\r\n this._productAnalyticsService.logEvent('access-filing-batch', {\r\n returnAccessPath: 'view return filing'\r\n });\r\n this._routerService.go('filingBatchDetails',\r\n {\r\n 'companyId': filingBatch.companyId,\r\n 'filingBatchId': filingBatch.filingBatchId\r\n });\r\n }\r\n\r\n private async _viewTasks(params: ICellRendererParamsForFilingBatchListGridAction): Promise {\r\n const filingBatch = params.data as Compliance.FilingBatchModel;\r\n if (!filingBatch) {\r\n return;\r\n }\r\n await this._filingBatchService.viewTasks(filingBatch);\r\n }\r\n\r\n private _refreshDataSource() {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this.gridTracker.clear();\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return false;\r\n }\r\n\r\n this.gridTracker.clear();\r\n\r\n const dataSourceParams = (): FilingBatchListDataSourceParams => {\r\n return {\r\n includeCompleted: this.includeCompleted,\r\n companyId: this.companyId\r\n };\r\n };\r\n\r\n this._gridDataSource = new FilingBatchListAgGridDataSource(this._gridApi, this._filingBatchRepository, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private async _deleteFilingBatch(filingBatch: Compliance.FilingBatchModel): Promise {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you wish to delete the filing batch?', 'Confirm Delete');\r\n }\r\n catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n let busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n\r\n try {\r\n await lastValueFrom(this._filingBatchRepository.delete(filingBatch.filingBatchId, false));\r\n }\r\n catch (e2) {\r\n // service returns a 422 and a message if user confirmation needed to force delete\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n busyRef.hide();\r\n\r\n try {\r\n await this._messageModalService.confirm(e2.error.message, 'Confirm Delete');\r\n }\r\n catch (e3) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n\r\n await lastValueFrom(this._filingBatchRepository.delete(filingBatch.filingBatchId, true));\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve(true);\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n const result = await this._gridDataSource.getRowIdsInternal(skip, take);\r\n this._selectedRowModel = [...result.data];\r\n return { ...result, data: this._selectedRowModel.map(r => r.filingBatchId) };\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const FILING_BATCH_DETAILS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'filing-batch-details.begin-preparation',\r\n tooltipText: 'Begin preparation. The necessary forms and reports will be added, and asset schedule mappings and form overrides will be copied from prior returns. The filing batch status will then be set to Started.'\r\n },\r\n {\r\n helpContentId: 'filing-batch-details.begin-preparation-no-filings',\r\n tooltipText: 'Cannot begin preparation because there are no filings. Add filings to begin.'\r\n },\r\n {\r\n helpContentId: 'filing-batch-details.continue-preparation',\r\n tooltipText: 'Continue preparation. If any filings did not have forms available when preparation started, the necessary forms and reports will be added, and asset schedule mappings and form overrides will be copied from prior returns.'\r\n },\r\n {\r\n helpContentId: 'filing-batch-details.continue-preparation',\r\n tooltipText: 'Continue preparation. If any filings did not have forms available when preparation started, the necessary forms and reports will be added, and asset schedule mappings and form overrides will be copied from prior returns.'\r\n },\r\n {\r\n helpContentId: 'filing-batch-details.view-returns',\r\n tooltipText: 'View returns'\r\n },\r\n {\r\n helpContentId: 'filing-batch-details.amend-returns',\r\n tooltipText: 'Amend Returns'\r\n }\r\n];\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const AMEND_RETURNS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'amend-returns.header',\r\n tooltipText: 'Create a batch to amend the selected returns.',\r\n hasIcon: true\r\n }\r\n];\r\n","\r\n\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { FilingRowModel } from '../filingBatchDetails.service';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../AgGrid';\r\nimport { AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectTracker } from '../../../AgGrid/MultiSelectTracker';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from '../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { WeissmanDateFormatPipe } from '../../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { FilingBatchService } from '../../filingBatch.service';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { AMEND_RETURNS_HELP } from './amendReturns.component.help';\r\n\r\nexport interface AmendReturnsModalParams {\r\n companyId: number;\r\n filingBatch: Compliance.FilingBatchModel;\r\n filings: FilingRowModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'amend-returns',\r\n templateUrl: './amendReturns.component.html'\r\n})\r\nexport class AmendReturnsComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _filingBatchService: FilingBatchService,\r\n private readonly _helpService: HelpService\r\n ) {}\r\n\r\n params: AmendReturnsModalParams;\r\n result: Compliance.FilingBatchModel;\r\n\r\n companyId: number;\r\n isSaving: boolean;\r\n selectedRows: number[] = [];\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as FilingRowModel).filingId),\r\n 'grid-row-deleted': (params) => params.data && (params.data as FilingRowModel).deleted\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .withColumnPinning()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(AMEND_RETURNS_HELP);\r\n\r\n this.companyId = this.params.companyId;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this.gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe((selected: Compliance.SelectedRowsModel) => {\r\n this.selectedRows = (selected.selectAllRows) ? this.params.filings.map(f => f.filingId) : selected.selectedRows;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'filingId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/assessor/${filing.assessorId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Filing',\r\n field: 'filingDescription',\r\n lockVisible: true,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-filing',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/filing/${filing.filingId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/company/${filing.companyId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/site/${filing.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'siteProperty',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/site/${filing.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Parcel',\r\n field: 'parcelAcctNumberDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/parcel/${filing.parcelId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n\r\n return filing.parcelAcctNumberDisplay;\r\n }\r\n },\r\n {\r\n headerName: 'Due Date',\r\n field: 'dueDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n\r\n return this._datePipe.transform(filing.dueDate, true);\r\n },\r\n filterValueGetter: (params) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n\r\n return this._datePipe.transform(filing.dueDate, true);\r\n }\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'assessorName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n\r\n this._setDataSource();\r\n }\r\n\r\n async submit(): Promise {\r\n if (!this.selectedRows) { return; }\r\n\r\n const filingIds = await this.gridTracker.getSelectedRowIds();\r\n const updateModel: Compliance.FilingBatchFilingsAmendModel = {\r\n filingIds\r\n }\r\n\r\n this.isSaving = true;\r\n\r\n try {\r\n this.result = await this._filingBatchService.amendFilings(updateModel);\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.isSaving = false;\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setDataSource(): void {\r\n if (!(this._gridApi && this.params.filings)) {\r\n return;\r\n }\r\n\r\n this.gridTracker && this.gridTracker.clear();\r\n\r\n this._gridApi.setRowData(this.params.filings);\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n const queryResultModel: Compliance.QueryResultModel = {\r\n lastModifiedTimestamp: new Date(),\r\n totalRows: rows.length,\r\n totalValidRows: rows.length,\r\n data: rows.map((x) => {\r\n const filing = x.data as FilingRowModel;\r\n return filing && filing.filingId;\r\n })\r\n };\r\n\r\n return Promise.resolve(queryResultModel);\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\nexport interface FilingRowModel extends Compliance.FilingModel {\r\n changed: boolean;\r\n deleted: boolean;\r\n added: boolean;\r\n originalValue: Compliance.FilingModel;\r\n}\r\n\r\n@Injectable()\r\nexport class FilingBatchDetailsService {\r\n private _filings: FilingRowModel[];\r\n\r\n get currentFilings(): FilingRowModel[] {\r\n return this._filings;\r\n }\r\n\r\n set currentFilings(filings: FilingRowModel[]) {\r\n this._filings = filings;\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const FILING_BATCH_INFO_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'filing-batch-info.panel',\r\n tooltipText: 'Info that is shared by all filings in the batch.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'filing-batch-info.change-detection',\r\n tooltipText: 'When no prior return is selected for a filing, determine disposals and transfers out by comparing assets at the prior year lien date.',\r\n hasIcon: true\r\n }\r\n];\r\n","import {Injectable} from \"@angular/core\";\r\nimport {BaseRepository} from \"../../Common/Data/base.repository\";\r\nimport {HttpClient} from \"@angular/common/http\";\r\nimport {Observable} from \"rxjs\";\r\n\r\n@Injectable()\r\nexport class ComplianceInfoRepository extends BaseRepository{\r\n constructor(httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n saveByParcel(parcelId: number, model: Compliance.ComplianceInfoGeneralReturnSettingsReportingSitesSaveModel): Observable {\r\n return this.httpPost(`/api/ComplianceInfo/Parcel/${parcelId}`, model);\r\n }\r\n\r\n getDeadlines(companyId: number): Observable {\r\n return this.httpGet(`api/ComplianceInfo/Deadlines/${companyId}`);\r\n }\r\n}\r\n","\r\n\r\n
\r\n
\r\n
\r\n

\r\n Filing Batch Info\r\n

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

{{ filingBatch.displayId }}

\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n

{{ f.controls.filingType.value?.name }}

\r\n \r\n \r\n
\r\n
Filing Type is required.
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n

{{ f.controls.taxYear.value }}

\r\n \r\n \r\n
\r\n
Tax Year is required.
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n

{{ fState.controls.stateName.value }}

\r\n \r\n \r\n
\r\n
State is required.
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n

\r\n \r\n {{ filingBatch.status }}\r\n \r\n

\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n

{{ f.controls.description.value }}

\r\n \r\n
\r\n
Description is required.
\r\n
Description max length is 4,000 characters.
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n

{{ f.controls.dueDate.value | weissmanDateFormat: true }}

\r\n \r\n \r\n
\r\n
Due date is required.
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n

{{ changeDetection }}

\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { of as observableOf, Subscription , Observable , BehaviorSubject, lastValueFrom } from 'rxjs';\r\nimport { Component, OnInit, OnChanges, SimpleChanges, SimpleChange, Input, Output, EventEmitter, OnDestroy } from '@angular/core';\r\nimport { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport { StateService } from '../../../../Common/States/States.Service';\r\nimport { StateSummary } from '../../../../Common/States/state.model';\r\nimport { Constants } from '../../../../constants.new';\r\nimport { FilingBatchService } from '../../filingBatch.service';\r\nimport { FilingBatchRepository } from '../../../Repositories/filingBatch.repository';\r\nimport { ComplianceInfoRepository } from '../../../Repositories/complianceInfo.repository';\r\nimport { WeissmanMutexService, IMutexServiceHandler } from '../../../WeissmanMutexService';\r\nimport { BaseExpandableComponent } from '../../../../UI-Lib/Expandable-Component/baseExpandableComponent';\r\nimport { mergeMap } from 'rxjs/operators';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { FILING_BATCH_INFO_HELP } from './filingBatchInfo.component.help';\r\nimport * as moment from 'moment-timezone'\r\nimport { YearPickerMixin } from '../../../../UI-Lib/Mixins';\r\nimport { MessageModalService } from '../../../../UI-Lib/Message-Box/messageModal.service';\r\n\r\ninterface FilingBatchInfoComponentChanges extends SimpleChanges {\r\n filingBatch: SimpleChange\r\n}\r\n\r\n@Component({\r\n selector: 'filing-batch-info',\r\n templateUrl: './filingBatchInfo.component.html',\r\n styleUrls: ['./filingBatchInfo.component.scss']\r\n})\r\nexport class FilingBatchInfoComponent extends YearPickerMixin(BaseExpandableComponent) implements OnInit, OnDestroy, OnChanges, IMutexServiceHandler {\r\n constructor(\r\n private readonly _stateService: StateService,\r\n private readonly _formBuilder: UntypedFormBuilder,\r\n private readonly _constants: Constants,\r\n private readonly _filingBatchRepository: FilingBatchRepository,\r\n private readonly _filingBatchService: FilingBatchService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _complianceInfoRepository: ComplianceInfoRepository,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _helpService: HelpService\r\n ) {\r\n super(_filingBatchService, 'filing-batch-info');\r\n }\r\n\r\n private _isInitialized: boolean = false;\r\n private _filingBatchChangeSub: Subscription;\r\n private _editModeSubject = new BehaviorSubject(false);\r\n private _editModeSub: Subscription;\r\n private _stateDeadlineMap: Map = new Map();\r\n\r\n @Input() filingBatch: Compliance.FilingBatchModel;\r\n @Input() canEdit: boolean = false;\r\n @Input() showChangeDetection: boolean = false;\r\n\r\n @Output() onFilingBatchUpdated: EventEmitter = new EventEmitter();\r\n @Output() onFilingBatchDeleted: EventEmitter = new EventEmitter();\r\n @Output() onFilingBatchChangesCancelled: EventEmitter = new EventEmitter();\r\n @Output() onFilingBatchCreated: EventEmitter = new EventEmitter();\r\n\r\n busyMessageManager = new BusyIndicatorMessageManager();\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._filingBatchService.editGroup);\r\n }\r\n\r\n editMode: boolean = false;\r\n addMode: boolean = false;\r\n states: StateSummary[] = [];\r\n statesTypeAheadDataSource: Observable;\r\n statesTypeAheadAsyncSelected: any;\r\n customStateSearch = (values: any[], searchValue: string) => {\r\n const pattern = searchValue.split('').reduce((a, b) => (a + '[^' + b + ']*' + b));\r\n const regex = new RegExp(pattern);\r\n return values.filter(o => {\r\n return regex.test(o.fullName.toLowerCase()) || regex.test(o.abbr.toLowerCase());\r\n }).sort((a, b) => {\r\n // Sort by state abbreviation exact match first\r\n const aMatch = a.abbr.toLowerCase() === searchValue.toLowerCase();\r\n const bMatch = b.abbr.toLowerCase() === searchValue.toLowerCase();\r\n if (!aMatch && bMatch) {\r\n return 1;\r\n } else if (aMatch && !bMatch) {\r\n return -1;\r\n }\r\n return a.fullName.localeCompare(b.fullName);\r\n });\r\n };\r\n\r\n // currently only supporting 'PP Return' filing type\r\n filingTypes: Compliance.NameValuePair[] = [\r\n this._constants.FilingTypes.find(x => x.value === Core.FilingTypes.PPReturn)\r\n ];\r\n\r\n changeDetectionOptions: Compliance.NameValuePair[] = [\r\n {name: 'Company Asset List', value: true},\r\n {name: 'Prior Return', value: false}\r\n ];\r\n\r\n form: UntypedFormGroup = this._formBuilder.group({\r\n filingType: [null, [Validators.required]],\r\n taxYear: [null, [Validators.required]],\r\n description: [null, [Validators.required, Validators.maxLength(4000)]],\r\n dueDate: [null, Validators.required],\r\n changeDetection: [false],\r\n stateGroup: this._formBuilder.group({\r\n state: [null, [Validators.required]],\r\n stateName: [null]\r\n })\r\n });\r\n\r\n get f() { return this.form; }\r\n get fState() { return (this.form.get('stateGroup') as UntypedFormGroup); }\r\n\r\n get changeDetection(): string {\r\n return this.form.get('changeDetection').value ? 'Company Assets' : 'Prior Return';\r\n }\r\n\r\n get isReadOnly(): boolean {\r\n return this._filingBatchService.isReadOnly(this.filingBatch && this.filingBatch.processStatus);\r\n }\r\n\r\n get editHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n return 'app.edit';\r\n }\r\n\r\n get tasksHelpContentId(): string {\r\n return this.editMode ?\r\n 'app.edit-task-series' :\r\n 'app.view-task-series';\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(FILING_BATCH_INFO_HELP);\r\n\r\n this.states = await this._stateService.getSummary();\r\n\r\n this._setModel();\r\n\r\n this._editModeSub = this._editModeSubject.asObservable().subscribe(x => {\r\n this.editMode = x;\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._filingBatchService.editGroup);\r\n }\r\n });\r\n\r\n this._filingBatchChangeSub = this._filingBatchService.filingBatchChange$.subscribe(x => {\r\n if (this.filingBatch && x && this.filingBatch.filingBatchId === x.filingBatchId) {\r\n this.filingBatch.filingCount = x.filingCount;\r\n this.filingBatch.rowVersion = x.rowVersion;\r\n this.filingBatch.processStatus = x.processStatus;\r\n this.filingBatch.status = x.status;\r\n this.filingBatch.statusDate = x.statusDate;\r\n this.filingBatch.getPriorReturnFromAssetList = x.getPriorReturnFromAssetList;\r\n\r\n this._updateFormFromModel();\r\n }\r\n });\r\n\r\n this.statesTypeAheadDataSource = (Observable.create((observer: any) => {\r\n observer.next(this.statesTypeAheadAsyncSelected);\r\n }) as Observable).pipe(mergeMap((token: string) => this.getStatesAsObservable(token)));\r\n\r\n if (this.filingBatch && this.filingBatch.filingBatchId === 0) {\r\n this.edit();\r\n }\r\n\r\n const deadlines = await lastValueFrom(this._complianceInfoRepository.getDeadlines(this.filingBatch.companyId));\r\n this.states.forEach((state: StateSummary) => {\r\n const stateDeadlines = deadlines.find((deadline: Compliance.StateDeadlinesModel) => state.stateID === deadline.stateId);\r\n if (stateDeadlines) {\r\n this._stateDeadlineMap.set(state.stateID, stateDeadlines);\r\n }\r\n });\r\n\r\n this._isInitialized = true;\r\n }\r\n\r\n private _isSecondDeadlineEarlierThanFirst(firstDeadline: Core.AppealDeadlineModel, secondDeadline: Core.AppealDeadlineModel, taxYear: number): boolean {\r\n const firstDate = (firstDeadline.deadlineMonthDay !== null) ? this._getDateFromDeadlineAndTaxYear(firstDeadline, taxYear) : firstDeadline.deadlineDate;\r\n const secondDate = (secondDeadline.deadlineMonthDay !== null) ? this._getDateFromDeadlineAndTaxYear(secondDeadline, taxYear) : secondDeadline.deadlineDate;\r\n return (secondDate < firstDate);\r\n }\r\n\r\n async ngOnDestroy(): Promise {\r\n this._filingBatchChangeSub && this._filingBatchChangeSub.unsubscribe();\r\n this._editModeSub && this._editModeSub.unsubscribe();\r\n this._mutexService.release(this, this._filingBatchService.editGroup);\r\n }\r\n\r\n getProgressStatusDisplay(): string {\r\n return this._filingBatchService.getProgressStatusDisplay(this.filingBatch && this.filingBatch.processStatus);\r\n }\r\n\r\n getStatesAsObservable(token: string): Observable {\r\n const query = new RegExp(token, 'ig');\r\n\r\n return observableOf(\r\n this.states.filter((state: StateSummary) => {\r\n return query.test(state.abbr) || query.test(state.fullName);\r\n })\r\n );\r\n }\r\n\r\n ngOnChanges(changes: FilingBatchInfoComponentChanges): void {\r\n if (changes && changes.filingBatch && this._isInitialized) {\r\n this._setModel();\r\n }\r\n }\r\n\r\n edit(): void {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n\r\n this._mutexService.acquire(this, this._filingBatchService.editGroup);\r\n this._editModeSubject.next(true);\r\n }\r\n\r\n async save(): Promise {\r\n const busyMessageId = 'saving';\r\n this.busyMessageManager.add('Saving', busyMessageId);\r\n\r\n try {\r\n await this._saveModel();\r\n }\r\n finally {\r\n this.busyMessageManager.remove(busyMessageId);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._updateFormFromModel();\r\n this._editModeSubject.next(false);\r\n this.onFilingBatchChangesCancelled.emit(this.filingBatch);\r\n }\r\n\r\n onStateSelected(state: StateSummary): void {\r\n console.log(state)\r\n this.fState.patchValue({\r\n 'state': state,\r\n 'stateName': (state && state.fullName) || null\r\n });\r\n this.updateDeadlineForStateAndTaxYear();\r\n }\r\n\r\n onStateBlur(): void {\r\n if (this.fState.controls.stateName.value) {\r\n const state = this.fState.controls.state.value as Core.StateModel;\r\n this.fState.patchValue({\r\n 'stateName': (state && state.fullName) || null\r\n });\r\n return;\r\n }\r\n this.fState.patchValue({\r\n 'state': null\r\n });\r\n }\r\n\r\n onDueDateChanged(value: Date | Event): void {\r\n this.f.controls.dueDate.markAsTouched();\r\n if (!(value instanceof Date)) {\r\n return;\r\n }\r\n\r\n this.f.patchValue({\r\n 'dueDate': value\r\n });\r\n }\r\n\r\n updateDeadlineForStateAndTaxYear(): void {\r\n const taxYear = this.f.get('taxYear').value;\r\n const state: StateSummary = this.fState.get('state').value;\r\n if (taxYear && state) {\r\n const stateId = state.stateID;\r\n const deadline = this._findEarliestDeadlineForStateAndTaxYear(stateId, taxYear);\r\n\r\n if (deadline) {\r\n const day = deadline.deadlineMonthDay;\r\n if (day) {\r\n const dueDate = this._getDateFromDeadlineAndTaxYear(deadline, taxYear);\r\n this.f.controls.dueDate.setValue(dueDate);\r\n } else if (deadline.deadlineDate) {\r\n this.f.controls.dueDate.setValue(deadline.deadlineDate);\r\n }\r\n }\r\n }\r\n }\r\n\r\n private _findEarliestDeadlineForStateAndTaxYear(stateId: number, taxYear: number): Core.AppealDeadlineModel {\r\n let earliestFoundDeadline = null;\r\n const stateDeadlines = this._stateDeadlineMap.get(stateId);\r\n if (stateDeadlines != null) {\r\n earliestFoundDeadline = stateDeadlines.stateDeadline;\r\n // find any earlier ones\r\n if (stateDeadlines.exceptionDeadlines !== null) {\r\n const exceptionsApplyingToThisYear = stateDeadlines.exceptionDeadlines.filter((ed: Core.AppealDeadlineModel) => ed.taxYear === null || ed.taxYear === taxYear);\r\n exceptionsApplyingToThisYear.forEach((ad: Core.AppealDeadlineModel) => {\r\n if (this._isSecondDeadlineEarlierThanFirst(earliestFoundDeadline, ad, taxYear)) {\r\n earliestFoundDeadline = ad;\r\n }\r\n });\r\n }\r\n }\r\n return earliestFoundDeadline;\r\n }\r\n\r\n private _getDateFromDeadlineAndTaxYear(deadline: Core.AppealDeadlineModel, taxYear: number) {\r\n const day = deadline ? deadline.deadlineMonthDay : null;\r\n if (day && taxYear) {\r\n const dueDate = moment.utc(taxYear + deadline.deadlineYearID + '/' + day, 'YYYY-MM-DD').toDate();\r\n return dueDate;\r\n } else {\r\n return null;\r\n }\r\n }\r\n\r\n async delete(): Promise {\r\n const deleted = await this._deleteFilingBatch(this.filingBatch);\r\n if (deleted) {\r\n this.onFilingBatchDeleted.emit(this.filingBatch);\r\n }\r\n }\r\n\r\n async viewTasks(): Promise {\r\n await this._filingBatchService.viewTasks(this.filingBatch, this.editMode);\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n private async _setModel(): Promise {\r\n if (!this.filingBatch) {\r\n return;\r\n }\r\n\r\n this.addMode = this.filingBatch.filingBatchId === 0;\r\n\r\n if (this.addMode) {\r\n this.filingBatch = {\r\n filingBatchId: 0,\r\n displayId: null,\r\n filingTypeId: Core.FilingTypes.PPReturn,\r\n companyId: this.filingBatch.companyId,\r\n stateId: null,\r\n taxYear: new Date().getUTCFullYear(),\r\n dueDate: new Date(),\r\n description: null,\r\n rowVersion: null,\r\n getPriorReturnFromAssetList: false,\r\n reportNBVInsteadOfFactoredCost: false,\r\n returnCostReportingDisplayId: Compliance.ReturnCostReportingDisplayEnum.Both\r\n };\r\n this.editMode = true;\r\n }\r\n\r\n // when not in add mode, model is being passed in as input parameter so use that, otherwise fetch from API\r\n\r\n this._updateFormFromModel();\r\n\r\n this._setReadOnlyFormFields();\r\n }\r\n\r\n private async _saveModel(): Promise {\r\n this._updateModelFromForm();\r\n\r\n const promise: Promise = this.addMode ?\r\n lastValueFrom(this._filingBatchRepository.create(this.filingBatch)) :\r\n lastValueFrom(this._filingBatchRepository.update(this.filingBatch));\r\n\r\n const event = this.addMode ?\r\n this.onFilingBatchCreated :\r\n this.onFilingBatchUpdated;\r\n\r\n this.filingBatch = await promise;\r\n\r\n this._editModeSubject.next(false);\r\n\r\n event.emit(this.filingBatch);\r\n\r\n this.addMode = false;\r\n\r\n this._updateFormFromModel();\r\n\r\n this.form.markAsPristine();\r\n this.form.markAsUntouched();\r\n }\r\n\r\n private _setReadOnlyFormFields(): void {\r\n // this one is always disabled as we're only allowing one filing type (PP Return) for now\r\n this.f.get('filingType').disable();\r\n\r\n if (!this.addMode) {\r\n this.f.get('taxYear').disable();\r\n this.fState.disable();\r\n }\r\n }\r\n\r\n private _updateFormFromModel(): void {\r\n const state = this.states.find(x => x.stateID === this.filingBatch.stateId) || null;\r\n\r\n this.statesTypeAheadAsyncSelected = state && state.fullName;\r\n\r\n const filingType = this.filingTypes.find(x => x.value === this.filingBatch.filingTypeId) || null;\r\n\r\n this.form.setValue({\r\n filingType: filingType,\r\n taxYear: this.filingBatch.taxYear,\r\n description: this.filingBatch.description,\r\n dueDate: this.filingBatch.dueDate,\r\n changeDetection: this.filingBatch.getPriorReturnFromAssetList,\r\n stateGroup: {\r\n state: state,\r\n stateName: state && state.fullName\r\n }\r\n });\r\n }\r\n\r\n private _updateModelFromForm(): void {\r\n this.filingBatch.filingTypeId = this.f.get('filingType').value.value; // bound to a object\r\n this.filingBatch.taxYear = this.f.get('taxYear').value;\r\n this.filingBatch.description = this.f.get('description').value;\r\n this.filingBatch.dueDate = this.f.get('dueDate').value;\r\n this.filingBatch.getPriorReturnFromAssetList = this.f.get('changeDetection').value;\r\n\r\n const state: StateSummary = this.fState.get('state').value;\r\n this.filingBatch.stateId = state.stateID;\r\n this.filingBatch.stateName = state.fullName;\r\n }\r\n\r\n private async _deleteFilingBatch(filingBatch: Compliance.FilingBatchModel): Promise {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you wish to delete the filing batch?', 'Confirm Delete');\r\n }\r\n catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n let busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n\r\n try {\r\n await lastValueFrom(this._filingBatchRepository.delete(filingBatch.filingBatchId, false));\r\n }\r\n catch (e2) {\r\n // service returns a 422 and a message if user confirmation needed to force delete\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);;\r\n }\r\n busyRef.hide();\r\n\r\n try {\r\n await this._messageModalService.confirm(e2.error.message, 'Confirm Delete');\r\n }\r\n catch (e3) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n\r\n await lastValueFrom(this._filingBatchRepository.delete(filingBatch.filingBatchId, true));\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve(true);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { Subscription, BehaviorSubject } from 'rxjs';\r\n\r\nexport interface FilingBatchAccountsGridActionCellRendererParams extends ICellRendererParams {\r\n editMode$: BehaviorSubject;\r\n canEdit(params: FilingBatchAccountsGridActionCellRendererParams): boolean;\r\n remove: (params: FilingBatchAccountsGridActionCellRendererParams) => void;\r\n undoRemove: (params: FilingBatchAccountsGridActionCellRendererParams) => void;\r\n canRemove(params: FilingBatchAccountsGridActionCellRendererParams): boolean;\r\n canUndoRemove(params: FilingBatchAccountsGridActionCellRendererParams): boolean;\r\n edit: (params: FilingBatchAccountsGridActionCellRendererParams) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class FilingBatchAccountsGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: FilingBatchAccountsGridActionCellRendererParams;\r\n private _editModeSub: Subscription;\r\n\r\n editMode: boolean;\r\n\r\n agInit(params: FilingBatchAccountsGridActionCellRendererParams): void {\r\n this.params = params;\r\n this._editModeSub = this.params.editMode$.subscribe(x => this.editMode = x);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub.unsubscribe();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onRemoveClicked(): void {\r\n this.params.remove(this.params);\r\n }\r\n\r\n onUndoRemoveClicked(): void {\r\n this.params.undoRemove(this.params);\r\n }\r\n\r\n onEditClicked(): void {\r\n this.params.edit(this.params);\r\n }\r\n}\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { FilingBatchRepository } from '../../../Repositories';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../AgGrid';\r\n\r\nexport interface FilingBatchAddAccountsDataSourceParams {\r\n filingBatchId: number;\r\n selectedIds: number[];\r\n}\r\n\r\nexport class FilingBatchAddAccountsAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private _gridApi: GridApi,\r\n private _filingBatchRepository: FilingBatchRepository,\r\n protected _dataSourceParamsFn: () => FilingBatchAddAccountsDataSourceParams\r\n ) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'companyName', value: Compliance.FilingPropertyEnum.Company },\r\n { name: 'assessorName', value: Compliance.FilingPropertyEnum.Assessor },\r\n { name: 'parcelAcctNumberDisplay', value: Compliance.FilingPropertyEnum.ParcelAcctNumberDisplay },\r\n { name: 'filingDescription', value: Compliance.FilingPropertyEnum.FilingDescription },\r\n { name: 'siteName', value: Compliance.FilingPropertyEnum.SiteName },\r\n { name: 'siteProperty', value: Compliance.FilingPropertyEnum.SiteProperty },\r\n { name: 'taxYear', value: Compliance.FilingPropertyEnum.TaxYear },\r\n { name: 'dueDate', value: Compliance.FilingPropertyEnum.DueDate }\r\n ];\r\n\r\n protected canGetRows(): boolean {\r\n return !!this._dataSourceParams.filingBatchId;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Compliance.FilingSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n filingIdsToExclude: this._dataSourceParams.selectedIds\r\n };\r\n\r\n const result = await lastValueFrom(this._filingBatchRepository.getListByBatchAvailable(this._dataSourceParams.filingBatchId, searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Compliance.FilingSearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n filingIdsToExclude: this._dataSourceParams.selectedIds\r\n };\r\n\r\n return await lastValueFrom(this._filingBatchRepository.getRowIdsByBatchAvailable(this._dataSourceParams.filingBatchId, searchParams));\r\n }\r\n\r\n destroy?(): void { }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const FILING_BATCH_ADD_ACCOUNTS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'filing-batch-add-accounts.panel',\r\n tooltipText: 'List of filings that are available to add to this batch. The filing must be in the same top-level company, state and tax year as this batch. In addition, the filing must not be in another batch or already filed.',\r\n hasIcon: true\r\n }\r\n];\r\n"," 0\">\r\n\r\n \r\n \r\n \r\n\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { GridOptions, GridReadyEvent, GridApi, ColDef } from 'ag-grid-community';\r\nimport { AgGridMultiSelectTracker, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer, AgGridMultiSelectRendererParams } from '../../../AgGrid/MultiSelectTracker';\r\nimport { AgGridColumns, AgGridOptionsBuilder } from '../../../AgGrid';\r\nimport {\r\n FilingBatchAddAccountsAgGridDataSource,\r\n FilingBatchAddAccountsDataSourceParams\r\n} from './filingBatchAddAccountsAgGridDataSource';\r\nimport { FilingBatchRepository } from '../../../Repositories';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AgGridFilterParams } from '../../../AgGrid';\r\nimport { ActiveStatuses } from '../../../../constants.new';\r\nimport { WeissmanDateFormatPipe } from '../../../../UI-Lib/Pipes';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { FILING_BATCH_ADD_ACCOUNTS_HELP } from './filingBatchAddAccounts.component.help';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../../Busy-Indicator';\r\n\r\nexport interface FilingBatchAddAccountsParams {\r\n filingBatchId: number;\r\n companyId: number;\r\n addedFilingIds: number[];\r\n}\r\n\r\nexport interface FilingBatchAddAccountsResult {\r\n totalRows: number;\r\n selectedRowIds: number[];\r\n}\r\n\r\n@Component({\r\n selector: 'filing-batch-add-accounts',\r\n templateUrl: './filingBatchAddAccounts.component.html',\r\n styleUrls: ['./filingBatchAddAccounts.component.scss']\r\n})\r\nexport class FilingBatchAddAccountsComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _filingBatchRepository: FilingBatchRepository,\r\n private readonly _modalRef: BsModalRef,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _helpService: HelpService,\r\n private _busyIndicatorService: BusyIndicatorService\r\n ) { }\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: FilingBatchAddAccountsAgGridDataSource;\r\n\r\n params: FilingBatchAddAccountsParams;\r\n result: FilingBatchAddAccountsResult;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.FilingModel).filingId)\r\n }\r\n })\r\n .withContext(this)\r\n .withInfiniteScroll()\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(FILING_BATCH_ADD_ACCOUNTS_HELP);\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: '',\r\n field: 'filingId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Filing',\r\n field: 'filingDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n valueFormatter: (params) => {\r\n const filing = params.data as Compliance.FilingModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n let result = filing.filingDescription;\r\n if (filing.parcelActivityStatusId === ActiveStatuses.Inactve) {\r\n result += ' (inactive)';\r\n }\r\n return result;\r\n },\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Due Date',\r\n field: 'dueDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'siteProperty',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Parcel',\r\n field: 'parcelAcctNumberDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'assessorName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n async save(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Adding' });\r\n\r\n try {\r\n this.result = {\r\n selectedRowIds: await this.gridTracker.getSelectedRowIds(),\r\n totalRows: this.gridTracker.getTotalRowsCount()\r\n } as FilingBatchAddAccountsResult;\r\n\r\n this._modalRef.hide();\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this.gridTracker.setSelectedRowsModel({\r\n selectAllRows: false,\r\n selectedRows: []\r\n });\r\n\r\n this._modalRef.hide();\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private _setDataSource(): void {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear();\r\n\r\n const dataSourceParams = (): FilingBatchAddAccountsDataSourceParams => {\r\n return {\r\n filingBatchId: this.params.filingBatchId,\r\n selectedIds: this.params.addedFilingIds\r\n }\r\n }\r\n\r\n this._gridDataSource = new FilingBatchAddAccountsAgGridDataSource(this._gridApi, this._filingBatchRepository, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const FILING_DETAILS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'filing-details.prior-return',\r\n tooltipText: 'The prior return is used to calculate additions, transfers and disposals. It is also used to determine which forms and reports to use as well as copying asset schedule mappings and form overrides.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'filing-details.amendment',\r\n tooltipText: 'When checked, change detection logic will use asset\\'s change status analysis against prior return\\'s prior return.',\r\n hasIcon: true\r\n }\r\n];\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n Amending Prior Return\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BusyIndicatorMessageManager } from '../../../../Busy-Indicator/busyIndicatorMessageManager'\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { FilingBatchRepository } from '../../../Repositories/filingBatch.repository';\r\nimport * as _ from 'lodash';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { FILING_DETAILS_HELP } from './filingDetails.component.help';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { lastValueFrom } from \"rxjs\";\r\n\r\nexport interface FilingDetailsParams {\r\n filingId: number;\r\n calculatedPriorReturnId: number;\r\n priorReturnId: number;\r\n isAmendment: boolean;\r\n}\r\n\r\nexport interface FilingDetailsResult {\r\n priorReturnId: number;\r\n priorReturnDescription: string;\r\n isAmendment: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'filing-details',\r\n templateUrl: './filingDetails.component.html'\r\n})\r\nexport class FilingDetailsComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _filingBatchRepository: FilingBatchRepository,\r\n private readonly _helpService: HelpService) {\r\n }\r\n\r\n params: FilingDetailsParams;\r\n result: FilingDetailsResult;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n priorReturns: Compliance.FilingModel[] = [];\r\n selectedPriorReturn: Compliance.FilingModel;\r\n isAmendment: boolean;\r\n priorReturnSelected: boolean;\r\n\r\n private _initialPriorReturn: Compliance.FilingModel;\r\n private _initialIsAmendment: boolean;\r\n\r\n get saveDisabled(): boolean {\r\n return this._initialIsAmendment === this.isAmendment && this._initialPriorReturn === this.selectedPriorReturn;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(FILING_DETAILS_HELP);\r\n\r\n const busyMsg = 'load-priorReturns';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsg);\r\n\r\n try {\r\n this.priorReturns = await lastValueFrom(this._filingBatchRepository.getListByPriorReturnAvailable(this.params.filingId));\r\n this.selectedPriorReturn = _.find(this.priorReturns, (x) => x.returnId === this.params.priorReturnId) || null;\r\n this.priorReturnSelected = this.selectedPriorReturn !== null;\r\n this.isAmendment = this.priorReturnSelected ? this.params.isAmendment : false;\r\n\r\n this._initialPriorReturn = this.selectedPriorReturn;\r\n this._initialIsAmendment = this.isAmendment;\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n this.result = {\r\n priorReturnId: this.selectedPriorReturn && this.selectedPriorReturn.returnId,\r\n priorReturnDescription: this.selectedPriorReturn && this.selectedPriorReturn.filingDescription,\r\n isAmendment: this.isAmendment\r\n }\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n priorReturnChanged(): void {\r\n this.priorReturnSelected = this.selectedPriorReturn !== null;\r\n\r\n if(!this.priorReturnSelected) {\r\n this.isAmendment = false;\r\n }\r\n }\r\n}\r\n","import { GridApi } from 'ag-grid-community';\r\nimport { BaseExpandableComponent } from './baseExpandableComponent';\r\nimport { IExpandableComponentContainer } from './expandableComponentContainer.model';\r\n\r\nexport class BaseExpandableAgGridComponent extends BaseExpandableComponent {\r\n protected constructor(\r\n expandableComponentContainer: IExpandableComponentContainer,\r\n name: string) {\r\n super(expandableComponentContainer, name);\r\n }\r\n\r\n private _api: GridApi;\r\n\r\n expandComponent() {\r\n super.expandComponent();\r\n if (this._api) {\r\n setTimeout(() => {\r\n this._api.sizeColumnsToFit();\r\n }, 500);\r\n }\r\n }\r\n\r\n collapseComponent(): void {\r\n super.collapseComponent();\r\n if (this._api) {\r\n setTimeout(() => {\r\n this._api.sizeColumnsToFit();\r\n }, 500);\r\n }\r\n }\r\n\r\n setGridApi(gridApi: GridApi) {\r\n this._api = gridApi;\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const FILING_BATCH_MOVE_MODAL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'filing-batch-move-modal.header',\r\n tooltipText: 'Move filings to a different or a new filing batch.',\r\n hasIcon: true\r\n }\r\n];\r\n"," 0\">\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
Please provide a filing batch description.
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
The date must be greater than {{ minDate | weissmanDateFormat: true }}
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation, OnDestroy } from '@angular/core';\r\nimport { UntypedFormGroup, UntypedFormControl, ValidationErrors, Validators, AbstractControl } from '@angular/forms';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { Subject } from 'rxjs';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { FILING_BATCH_MOVE_MODAL_HELP } from './filingBatchMoveModal.component.help';\r\nimport { FilingBatchService } from '../../filingBatch.service';\r\nimport { BusyIndicatorService, BusyIndicatorMessageManager } from '../../../../Busy-Indicator';\r\n\r\nenum RadioOptions {\r\n Move,\r\n Create\r\n}\r\n\r\nexport interface FilingBatchMoveModalParams {\r\n availableTargets: Compliance.FilingBatchModel[];\r\n filingIds: number[];\r\n batchInfo: Compliance.FilingBatchModel;\r\n}\r\n\r\n@Component({\r\n selector: 'filing-batch-move-modal',\r\n templateUrl: './filingBatchMoveModal.component.html',\r\n styleUrls: ['./filingBatchMoveModal.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class FilingBatchMoveModalComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _filingBatchService: FilingBatchService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _helpService: HelpService,\r\n private _busyIndicatorService: BusyIndicatorService) { }\r\n\r\n moveControl: UntypedFormControl = new UntypedFormControl();\r\n newGroup: UntypedFormGroup;\r\n radioOption: UntypedFormControl = new UntypedFormControl(RadioOptions.Move);\r\n\r\n params: FilingBatchMoveModalParams;\r\n result: Compliance.FilingBatchModel;\r\n\r\n filingBatches: Compliance.FilingBatchModel[] = [];\r\n taxYears: number[] = [];\r\n minDate: Date;\r\n RadioOptions = RadioOptions;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n // Validations\r\n dateValidation = (control: UntypedFormControl): ValidationErrors | null => (control.value && control.value >= this.minDate) ? null : { dateInvalid: true };\r\n formValidation = (control: UntypedFormGroup): ValidationErrors | null => (this.radioOption.value === RadioOptions.Move || (control.get('description').valid && control.get('dueDate').valid)) ? null : { formInvalid: true };\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(FILING_BATCH_MOVE_MODAL_HELP);\r\n this.minDate = new Date(this.params.batchInfo.taxYear, 0, 1);\r\n\r\n this.newGroup = new UntypedFormGroup({\r\n description: new UntypedFormControl({ value: this.params.batchInfo.description, disabled: true }, Validators.required),\r\n dueDate: new UntypedFormControl({ value: this.params.batchInfo.dueDate, disabled: true }, this.dateValidation)\r\n }, this.formValidation);\r\n\r\n this.radioOption.valueChanges.pipe(takeUntil(this.destroy$))\r\n .subscribe((val: RadioOptions) => {\r\n if (val === RadioOptions.Move) {\r\n this.moveControl.enable();\r\n this.newGroup.disable();\r\n } else {\r\n this.moveControl.disable();\r\n this.newGroup.enable();\r\n }\r\n });\r\n\r\n if (this.params && this.params.availableTargets.length) {\r\n this.filingBatches = this.params.availableTargets;\r\n this.moveControl.setValue(this.filingBatches[0]);\r\n } else {\r\n this.radioOption.setValue(RadioOptions.Create);\r\n this.radioOption.disable();\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n async submit(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Moving Filings' });\r\n\r\n try {\r\n const moveTo = this.moveControl.value;\r\n const moveModel: Compliance.FilingBatchFilingsMoveModel = {\r\n filingIds: this.params.filingIds,\r\n sourceBatchRowVersion: this.params.batchInfo.rowVersion,\r\n targetBatchRowVersion: (moveTo) ? moveTo.rowVersion : [],\r\n targetFilingBatch: (this.radioOption.value === RadioOptions.Create) ? this.newGroup.value : null,\r\n targetFilingBatchId: (this.radioOption.value === RadioOptions.Move) ? moveTo.filingBatchId : null\r\n };\r\n\r\n const targetFilingBatch = await this._filingBatchService.moveFilings(moveModel);\r\n\r\n this.result = targetFilingBatch;\r\n this._bsModalRef.hide();\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n onDueDateChanged(date: Date) {\r\n this.newGroup.get('dueDate').setValue(date);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UpgradeNavigationServiceHandler } from '../../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\n\r\nexport interface FilingBatchMoveResultModalParams {\r\n targetFilingBatch: Compliance.FilingBatchModel;\r\n moveCount: number;\r\n}\r\n\r\n@Component({\r\n selector: 'filing-batch-move-result-modal',\r\n template: `\r\n \r\n \r\n {{ params.moveCount }} filing(s) were successfully moved to {{ params.targetFilingBatch.description }}\r\n \r\n `\r\n})\r\nexport class FilingBatchMoveResultModalComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _routerService: UpgradeNavigationServiceHandler\r\n ) { }\r\n\r\n params: FilingBatchMoveResultModalParams;\r\n result: boolean;\r\n\r\n navigate(): void {\r\n this._routerService.go('filingBatchDetails', { companyId: this.params.targetFilingBatch.companyId, filingBatchId: this.params.targetFilingBatch.filingBatchId});\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this.result = true;\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const FILING_BATCH_ACCOUNTS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'filing-batch-accounts.panel',\r\n tooltipText: 'List of filings in this batch',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'filing-batch-accounts.move',\r\n tooltipText: 'Move selected filings to another batch.'\r\n },\r\n {\r\n helpContentId: 'filing-batch-accounts.move-no-accounts',\r\n tooltipText: 'Select filings to move to another batch.'\r\n },\r\n {\r\n helpContentId: 'filing-batch-accounts.add',\r\n tooltipText: 'Add filings to this batch.'\r\n },\r\n {\r\n helpContentId: 'filing-batch-accounts.edit',\r\n tooltipText: 'Edit to add/remove filings or to change the prior return for a filing.'\r\n },\r\n {\r\n helpContentId: 'filing-batch-accounts.edit-filing',\r\n tooltipText: 'Edit prior return.'\r\n }\r\n];\r\n","import { Component } from '@angular/core';\r\nimport { FilterUIModel } from '../Filters/filterUI.model';\r\nimport { AgGridYesNoFilterComponent } from '../Filters/YesNo/agGridYesNoFilter.component';\r\nimport { WSFloatingFilterParams } from './agGridFloatingFilterBase';\r\nimport { IFilterOptionDef } from 'ag-grid-community';\r\n\r\n@Component({\r\n selector: 'yes-no-floating-filter-component',\r\n template: `\r\n \r\n
\r\n {{ conditionValues }}\r\n
\r\n `,\r\n styleUrls: ['./agGridFloatingFilter.scss'],\r\n host: {'class': 'ag-input-wrapper'}\r\n})\r\nexport class AgGridYesNoFloatingFilterComponent {\r\n constructor() {}\r\n\r\n value: IFilterOptionDef;\r\n type: string;\r\n conditionApplied: boolean;\r\n filterOptions: IFilterOptionDef[] = [];\r\n conditionValues: string;\r\n\r\n protected _params: WSFloatingFilterParams;\r\n\r\n agInit(params: WSFloatingFilterParams): void {\r\n this._params = params;\r\n this.value = params.filterParams['defaultOption'];\r\n\r\n // This property exists but isn't on the model for some reason\r\n // Bracket notation bypasses the typechecking\r\n this.filterOptions = params.filterParams['filterOptions'];\r\n\r\n this._params.parentFilterInstance((instance) => this.onParentModelChanged((instance as unknown as AgGridYesNoFilterComponent).getModel()));\r\n }\r\n\r\n valueChange(filterType: IFilterOptionDef): void {\r\n this.value = filterType;\r\n const type = this.value.displayKey;\r\n this._params.parentFilterInstance((instance) => (instance as unknown as AgGridYesNoFilterComponent).onFloatingFilterChanged(type, this.value.displayName, true));\r\n }\r\n\r\n onParentModelChanged(parentModel: FilterUIModel): void {\r\n this.value = null;\r\n this.type = this._params.filterParams['defaultOption'];\r\n if (parentModel && parentModel.filterConditionType) {\r\n this.conditionValues = parentModel.filterValues.map(x => `${x.filterType.displayName}`)\r\n .join(parentModel.filterConditionType === Core.FilterConditionTypeEnum.And ? ' AND ' : ' OR ');\r\n this.conditionApplied = true;\r\n } else {\r\n this.value = parentModel && parentModel.filterValues[0] && parentModel.filterValues[0].filterType;\r\n this.type = parentModel && parentModel.filterValues[0] && parentModel.filterValues[0].filterType.displayKey;\r\n this.conditionApplied = false;\r\n }\r\n }\r\n\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n Filings\r\n \r\n

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, Input, OnDestroy, OnInit, Output, EventEmitter } from '@angular/core';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, RowNode } from 'ag-grid-community';\r\nimport { BehaviorSubject, Subscription, Subject, lastValueFrom } from 'rxjs';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport { FilingBatchRepository } from '../../../Repositories';\r\nimport { FilingBatchAccountsGridActionCellRendererComponent, FilingBatchAccountsGridActionCellRendererParams } from './filingBatchAccountsAgGridActionCellRenderer.component'\r\nimport { WeissmanModalService } from '../../../WeissmanModalService';\r\nimport { FilingBatchAddAccountsComponent, FilingBatchAddAccountsParams } from '../Filing-Batch-Add-Accounts/filingBatchAddAccounts.component';\r\nimport { FilingBatchService } from '../../filingBatch.service';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from '../../../AgGrid';\r\nimport { WeissmanMutexService, IMutexServiceHandler } from '../../../WeissmanMutexService';\r\nimport { AgGridLinkCellRendererComponent } from '../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AgGridLinkCellRendererParams } from '../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { FilingDetailsParams, FilingDetailsComponent } from '../Filing-Details/filingDetails.component';\r\nimport { MessageModalService } from '../../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { BaseExpandableAgGridComponent } from '../../../../UI-Lib/Expandable-Component/baseExpandableAgGridComponent';\r\nimport { FilingBatchMoveModalComponent, FilingBatchMoveModalParams } from '../Filing-Batch-Move-Modal/filingBatchMoveModal.component';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectedCellRenderer, AgGridMultiSelectTracker } from '../../../AgGrid/MultiSelectTracker';\r\nimport { WeissmanDateFormatPipe } from '../../../../UI-Lib/Pipes';\r\nimport { FilingBatchMoveResultModalComponent, FilingBatchMoveResultModalParams } from '../Filing-Batch-Move-Result-Modal/filingBatchMoveResultModal';\r\nimport { FILING_BATCH_ACCOUNTS_HELP } from './filingBatchAccounts.component.help';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { FilingBatchDetailsService, FilingRowModel } from '../filingBatchDetails.service';\r\nimport { ProductAnalyticsService } from \"../../../../Common/Amplitude/productAnalytics.service\";\r\n\r\nimport * as _ from 'lodash';\r\nimport {\r\n AgGridYesNoFloatingFilterComponent\r\n} from '../../../AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\n\r\nexport interface FilingsChangeModel {\r\n count: number;\r\n hasPriorReturns: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'filing-batch-accounts',\r\n templateUrl: './filingBatchAccounts.component.html',\r\n styleUrls: ['./filingBatchAccounts.component.scss']\r\n})\r\nexport class FilingBatchAccountsComponent extends BaseExpandableAgGridComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _filingBatchRepository: FilingBatchRepository,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _filingBatchService: FilingBatchService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _helpService: HelpService,\r\n private readonly _filingDetailsService: FilingBatchDetailsService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {\r\n super(_filingBatchService, 'filing-batch-accounts');\r\n }\r\n\r\n @Input() filingBatch: Compliance.FilingBatchModel;\r\n @Input() canEdit: boolean = false;\r\n @Input() refresh$: Subject;\r\n @Output() filingsChanged = new EventEmitter();\r\n\r\n private _filings: FilingRowModel[];\r\n private _gridApi: GridApi;\r\n private _editModeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _editModeSub: Subscription;\r\n private _selectedRowsSub: Subscription;\r\n private _refreshSub: Subscription;\r\n private _availableFilingCount = 0;\r\n\r\n selectedRows: number[] = [];\r\n availableFilingCount: number = 0;\r\n editMode: boolean;\r\n isBusy: boolean = false;\r\n isAvailableBusy: boolean = false;\r\n hasChanges: boolean = false;\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridId: System.Guid = '9C994FA8-E715-4D48-A447-529643046BBC';\r\n isBulkDeleteVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n get companyId(): number {\r\n return this.filingBatch && this.filingBatch.companyId;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._filingBatchService.editGroup);\r\n }\r\n\r\n get editHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n return 'filing-batch-accounts.edit';\r\n }\r\n\r\n get moveHelpContentId(): string {\r\n if (this.editMode || !this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n if (!(this.selectedRows && this.selectedRows.length)) {\r\n return 'filing-batch-accounts.move-no-accounts';\r\n }\r\n\r\n return 'filing-batch-accounts.move';\r\n }\r\n\r\n get addHelpContentId(): string {\r\n if (this.editMode || !this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n return 'filing-batch-accounts.add';\r\n }\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as FilingRowModel).filingId),\r\n 'grid-row-deleted': (params) => params.data && (params.data as FilingRowModel).deleted\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .withColumnPinning()\r\n .build();\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(FILING_BATCH_ACCOUNTS_HELP);\r\n\r\n this._editModeSub = this._editModeSubject.asObservable().subscribe(x => {\r\n this.editMode = x;\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._filingBatchService.editGroup);\r\n }\r\n });\r\n\r\n this._refreshSub = this.refresh$.asObservable().subscribe(async () => {\r\n await this._refresh();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub && this._editModeSub.unsubscribe();\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n this._refreshSub && this._refreshSub.unsubscribe();\r\n this._mutexService.release(this, this._filingBatchService.editGroup);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n super.setGridApi(event.api);\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe((selected: Compliance.SelectedRowsModel) => {\r\n this.selectedRows = (selected.selectAllRows)\r\n ? this._filings.map(f => f.filingId).filter(x => !selected.selectedRows.includes(x))\r\n : selected.selectedRows;\r\n this.isBulkDeleteVisible$.next(this.selectedRows.length > 0 && this.editMode);\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'filingId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n hide: !this.canEdit\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/assessor/${filing.assessorId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Filing',\r\n field: 'filingDescription',\r\n lockVisible: true,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-filing',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/filing/${filing.filingId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/company/${filing.companyId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/site/${filing.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'siteProperty',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/site/${filing.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Parcel',\r\n field: 'parcelAcctNumberDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/parcel/${filing.parcelId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n\r\n return filing.parcelAcctNumberDisplay;\r\n }\r\n },\r\n {\r\n headerName: 'Due Date',\r\n field: 'dueDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n\r\n return this._datePipe.transform(filing.dueDate, true);\r\n },\r\n filterValueGetter: (params) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n\r\n return this._datePipe.transform(filing.dueDate, true);\r\n }\r\n },\r\n {\r\n headerName: 'Prior Return',\r\n field: 'priorReturnDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: x => {\r\n const filing = x.data as FilingRowModel;\r\n return (filing && filing.priorReturnId === filing.calculatedPriorReturnId) ? null : 'ws-override';\r\n },\r\n valueFormatter: (params) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return filing.priorReturnDescription;\r\n },\r\n filterValueGetter: params => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return filing.priorReturnDescription;\r\n },\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-return',\r\n newWindow: true,\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n return !filing.priorFilingBatchId;\r\n },\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return `#/returnBatch/${filing.priorFilingBatchId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Asset Source',\r\n field: 'assetSource',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Started',\r\n field: 'isStarted',\r\n width: AgGridColumns.textColumnExtraSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return filing.isStarted ? 'Yes': 'No';\r\n },\r\n filterValueGetter: params => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return filing.isStarted ? 'Yes' : 'No';\r\n }\r\n },\r\n {\r\n headerName: 'Is Amended',\r\n field: 'isAmendment',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n hide: true,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return '';\r\n }\r\n return filing.isAmendment ? 'Yes': 'No';\r\n }\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: FilingBatchAccountsGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n remove: this.remove.bind(this),\r\n undoRemove: this.undoRemove.bind(this),\r\n edit: this._edit.bind(this),\r\n editMode$: this._editModeSubject.asObservable(),\r\n canEdit: (params: FilingBatchAccountsGridActionCellRendererParams) => {\r\n const filing = params.node.data as FilingRowModel;\r\n return this.canEdit && this.editMode && filing && !filing.deleted;\r\n },\r\n canRemove: (params: FilingBatchAccountsGridActionCellRendererParams) => {\r\n const filing = params.node.data as FilingRowModel;\r\n return this.canEdit && this.editMode && filing && !filing.deleted;\r\n },\r\n canUndoRemove: (params: FilingBatchAccountsGridActionCellRendererParams) => {\r\n const filing = params.node.data as FilingRowModel;\r\n return this.canEdit && this.editMode && filing && filing.deleted;\r\n }\r\n } as FilingBatchAccountsGridActionCellRendererParams,\r\n hide: !this.canEdit\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'assessorName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._refresh();\r\n }\r\n\r\n async moveFilings(): Promise {\r\n const availableTargets = await this._filingBatchService.getListByAvailableToMoveFilings(this.selectedRows);\r\n const params: FilingBatchMoveModalParams = {\r\n availableTargets,\r\n filingIds: this.selectedRows,\r\n batchInfo: this.filingBatch\r\n };\r\n\r\n const result = await this._modalService.showAsync(FilingBatchMoveModalComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const moveResultParams: FilingBatchMoveResultModalParams = {\r\n targetFilingBatch: result,\r\n moveCount: params.filingIds.length\r\n };\r\n\r\n const moveResult = await this._modalService.showAsync(FilingBatchMoveResultModalComponent, moveResultParams, 'modal-md');\r\n\r\n if (!moveResult) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._filingBatchService.notifyFilingBatchFilingsChange(this.filingBatch.filingBatchId);\r\n await this._refresh();\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n edit(): void {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n\r\n this._productAnalyticsService.logEvent('click-edit-filings');\r\n\r\n this._mutexService.acquire(this, this._filingBatchService.editGroup);\r\n this._editModeSubject.next(true);\r\n this.isBulkDeleteVisible$.next(this.selectedRows.length > 0 && this.editMode);\r\n }\r\n\r\n async save(): Promise {\r\n if (!this.hasChanges) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (this._filings.find((x) => x.changed && x.priorReturnId !== x.originalValue.priorReturnId)) {\r\n try {\r\n await this._messageModalService.confirm(`When the prior return is changed, any form overrides for the changed return will be removed and replaced with the overrides from the prior return form.${this.filingBatch.getPriorReturnFromAssetList ? ' Additionally, this will alter the change detection from Company Assets to Prior Return.' : ''}\\n\\n Are you sure you wish to continue?`, 'Confirm');\r\n }\r\n catch (e) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n const updateModel: Compliance.FilingBatchFilingsUpdateModel = {\r\n batchRowVersion: this.filingBatch.rowVersion,\r\n filings: []\r\n };\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const filingRow = node.data as FilingRowModel;\r\n if (!filingRow.deleted) {\r\n const filingReturnUpdateModel: Compliance.FilingReturnUpdateModel = {\r\n filingId: filingRow.filingId,\r\n priorReturnId: filingRow.priorReturnId,\r\n isAmendment: filingRow.isAmendment\r\n };\r\n\r\n updateModel.filings.push(filingReturnUpdateModel);\r\n }\r\n });\r\n\r\n const busyRef = this._busyService.show({ message: 'Saving' });\r\n\r\n try {\r\n await lastValueFrom(this._filingBatchRepository.updateFilings(this.filingBatch.filingBatchId, updateModel));\r\n\r\n await this._filingBatchService.notifyFilingBatchFilingsChange(this.filingBatch.filingBatchId);\r\n\r\n this._editModeSubject.next(false);\r\n\r\n await this._refresh();\r\n }\r\n finally {\r\n this._productAnalyticsService.logEvent('click-filings-save-changes');\r\n\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n // if added but not saved, remove it\r\n _.remove(this._filings, filing => filing.added);\r\n\r\n this._filings.forEach(filing => {\r\n filing.annualYearId = filing.originalValue.annualYearId;\r\n filing.priorReturnDescription = filing.originalValue.priorReturnDescription;\r\n filing.priorReturnId = filing.originalValue.priorReturnId;\r\n filing.changed = false;\r\n filing.deleted = false;\r\n });\r\n\r\n this.availableFilingCount = this._availableFilingCount;\r\n\r\n this._editModeSubject.next(false);\r\n\r\n this._setRowData();\r\n\r\n this.hasChanges = false;\r\n }\r\n\r\n async add(): Promise {\r\n let enteredEditMode = false;\r\n\r\n if (!this.editMode) {\r\n this.edit();\r\n enteredEditMode = true;\r\n }\r\n\r\n const params: FilingBatchAddAccountsParams = {\r\n filingBatchId: this.filingBatch.filingBatchId,\r\n companyId: this.filingBatch.companyId,\r\n addedFilingIds: this._filings.filter((x) => x.added).map((x) => x.filingId)\r\n };\r\n\r\n const result = await this._modalService.showAsync(FilingBatchAddAccountsComponent, params, 'modal-xl');\r\n\r\n if (!result) {\r\n if (enteredEditMode) {\r\n this.cancel();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n this.isBusy = true;\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n\r\n try {\r\n // because the add modal uses infinite scroll and multi-select tracker\r\n // get the new filings\r\n const filingIdsToGet = result.selectedRowIds.filter((selectedId) => !this._filings.find((y) => y.filingId === selectedId));\r\n\r\n if (!filingIdsToGet.length) {\r\n return Promise.resolve();\r\n }\r\n\r\n const filings = await lastValueFrom(this._filingBatchRepository.getListByFilingIds(filingIdsToGet));\r\n const newFilings = filings.map((x: Compliance.FilingModel) => this._getFilingRowModel(x, true));\r\n this._filings.push.apply(this._filings, newFilings);\r\n\r\n this.availableFilingCount = this.availableFilingCount - filings.length;\r\n if (this.availableFilingCount < 0) {\r\n this.availableFilingCount = 0;\r\n }\r\n\r\n this._setRowData();\r\n\r\n this.hasChanges = true;\r\n } finally {\r\n this._productAnalyticsService.logEvent('click-add-filings-ok', {\r\n numberOfFilingsAdded: result.selectedRowIds.length\r\n });\r\n this._gridApi && this._gridApi.hideOverlay();\r\n this.isBusy = false;\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n remove(params: FilingBatchAccountsGridActionCellRendererParams): void {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return;\r\n }\r\n\r\n if (!filing.added) {\r\n filing.deleted = true;\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n } else {\r\n this._removeAddedFiling(filing);\r\n }\r\n\r\n this._productAnalyticsService.logEvent('click-remove-filings', {\r\n numberOfFilingsRemoved: 1\r\n });\r\n\r\n this.hasChanges = true;\r\n }\r\n\r\n bulkDelete(): void {\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const filingRow = node.data as FilingRowModel;\r\n if (this.selectedRows.find(x => filingRow.filingId === x)) {\r\n if (!filingRow.added) {\r\n filingRow.deleted = true;\r\n this._gridApi.redrawRows({ rowNodes: [node] });\r\n } else {\r\n this._removeAddedFiling(filingRow);\r\n }\r\n }\r\n });\r\n\r\n this._productAnalyticsService.logEvent('click-remove-filings', {\r\n numberOfFilingsRemoved: this.selectedRows.length\r\n });\r\n\r\n this.gridTracker.clear();\r\n this.hasChanges = true;\r\n }\r\n\r\n undoRemove(params: FilingBatchAccountsGridActionCellRendererParams): void {\r\n const filing = params.data as FilingRowModel;\r\n if (!filing) {\r\n return;\r\n }\r\n\r\n filing.deleted = false;\r\n\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n private _removeAddedFiling(filing: FilingRowModel): void {\r\n const index = this._filings.findIndex((x) => x.filingId === filing.filingId);\r\n this._filings.splice(index, 1);\r\n this._gridApi.updateRowData({ remove: [filing] });\r\n this.availableFilingCount++;\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n const queryResultModel: Compliance.QueryResultModel = {\r\n lastModifiedTimestamp: new Date(),\r\n totalRows: rows.length,\r\n totalValidRows: rows.length,\r\n data: rows.map((x) => {\r\n const filing = x.data as FilingRowModel;\r\n return filing && filing.filingId;\r\n })\r\n };\r\n\r\n return Promise.resolve(queryResultModel);\r\n }\r\n\r\n private async _edit(params: FilingBatchAccountsGridActionCellRendererParams): Promise {\r\n const filing = params.node.data as FilingRowModel;\r\n if (!filing) {\r\n return Promise.resolve();\r\n }\r\n\r\n const inputParams: FilingDetailsParams = {\r\n filingId: filing.filingId,\r\n priorReturnId: filing.priorReturnId,\r\n calculatedPriorReturnId: filing.calculatedPriorReturnId,\r\n isAmendment: filing.isAmendment\r\n };\r\n\r\n const result = await this._modalService.showAsync(FilingDetailsComponent, inputParams, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n filing.priorReturnId = result.priorReturnId;\r\n filing.priorReturnDescription = result.priorReturnDescription;\r\n filing.isAmendment = result.isAmendment;\r\n filing.changed = true;\r\n\r\n let analyticsProperty = { priorReturn: 'none', amendingPriorReturn: result.isAmendment };\r\n if (result.priorReturnId) {\r\n analyticsProperty.priorReturn = result.priorReturnDescription;\r\n }\r\n\r\n this._productAnalyticsService.logEvent('click-edit-prior-return-OK', analyticsProperty);\r\n\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n\r\n this.hasChanges = true;\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private async _refresh(): Promise {\r\n if (!this.filingBatch) {\r\n return;\r\n }\r\n\r\n this.isBusy = true;\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n\r\n try {\r\n const searchParams: Compliance.FilingSearchModel = {\r\n filingIdsToExclude: []\r\n };\r\n\r\n const result = await lastValueFrom(this._filingBatchRepository.getListByBatch(this.filingBatch.filingBatchId, searchParams));\r\n\r\n this._filings = result.data.map((x: Compliance.FilingModel) => this._getFilingRowModel(x));\r\n this._filingDetailsService.currentFilings = this._filings;\r\n\r\n const changeModel: FilingsChangeModel = {\r\n count: this._filings.length,\r\n hasPriorReturns: this._filings.some(x => x.priorReturnId !== null)\r\n };\r\n\r\n this.filingsChanged.emit(changeModel);\r\n\r\n this._setRowData();\r\n this.hasChanges = false;\r\n this.isBusy = false;\r\n\r\n if (this.canEdit) {\r\n await this._refreshAvailableFilingCount();\r\n }\r\n\r\n } finally {\r\n this._gridApi && this._gridApi.hideOverlay();\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n private _getFilingRowModel(filing: Compliance.FilingModel, added: boolean = false): FilingRowModel {\r\n return {\r\n ...filing,\r\n ...{\r\n priorReturnDescription: added ? filing.calculatedPriorReturnDescription : filing.priorReturnDescription,\r\n priorReturnId: added ? filing.calculatedPriorReturnId : filing.priorReturnId,\r\n changed: false,\r\n deleted: false,\r\n added: added,\r\n originalValue: filing\r\n }\r\n } as FilingRowModel;\r\n }\r\n\r\n private async _refreshAvailableFilingCount(): Promise {\r\n this.isAvailableBusy = true;\r\n try {\r\n const addedFilingIds = this._filings.filter((x) => x.added).map((x) => x.filingId);\r\n this.availableFilingCount = await lastValueFrom(this._filingBatchRepository.getCountByBatchAvailable(this.filingBatch.filingBatchId, addedFilingIds));\r\n this._availableFilingCount = this.availableFilingCount;\r\n } finally {\r\n this.isAvailableBusy = false;\r\n }\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._filings)) {\r\n return;\r\n }\r\n\r\n this.gridTracker && this.gridTracker.clear();\r\n\r\n this._gridApi.setRowData(this._filings);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n

New Filing Batch

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
To get started with a new batch, populate and save the required information below.
\r\n
\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { FilingBatchRepository } from '../../Repositories';\r\nimport { RestrictService, InstanceRights } from '../../../Common/Permissions/restrict.service';\r\nimport { Subscription, Subject, lastValueFrom } from 'rxjs';\r\nimport { FilingBatchService } from '../filingBatch.service';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { AttachmentModalData } from '../../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../../Comments/comments.service';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { FILING_BATCH_DETAILS_HELP } from './filingBatchDetails.component.help';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { FilingsChangeModel } from './Filing-Batch-Accounts/filingBatchAccounts.component';\r\nimport { AmendReturnsComponent, AmendReturnsModalParams } from './Amend-Returns-Modal/amendReturns.component';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { FilingBatchDetailsService } from './filingBatchDetails.service';\r\n\r\nimport * as _ from 'lodash';\r\nimport { ReturnService } from '../../Return/return.service';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\n\r\n@Component({\r\n selector: 'filing-batch-details',\r\n templateUrl: './filingBatchDetails.component.html',\r\n styleUrls: ['./filingBatchDetails.component.scss'],\r\n providers: [FilingBatchDetailsService]\r\n})\r\nexport class FilingBatchDetailsComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _companyService: CompanyService,\r\n private readonly _filingBatchRepository: FilingBatchRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _filingBatchService: FilingBatchService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _filingDetailService: FilingBatchDetailsService,\r\n private readonly _helpService: HelpService,\r\n private readonly _returnService: ReturnService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) { }\r\n\r\n showChangeDetection: boolean = false;\r\n isInitialized: boolean = false;\r\n breadcrumbs: BreadCrumb[] = [];\r\n filingBatchId: number;\r\n companyId: number;\r\n companyName: string;\r\n filingBatch: Compliance.FilingBatchModel;\r\n addMode: boolean;\r\n canEditCompany: boolean = false;\r\n refreshing: boolean;\r\n refresh$: Subject = new Subject();\r\n\r\n private _filingBatchChangeSub: Subscription;\r\n private _lockChangedSub: Subscription;\r\n\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._filingBatchService.editGroup);\r\n }\r\n\r\n get isNotStarted(): boolean {\r\n return this._filingBatchService.isNotStarted(this.filingBatch && this.filingBatch.processStatus);\r\n }\r\n\r\n get isStarted(): boolean {\r\n return this._filingBatchService.isStarted(this.filingBatch && this.filingBatch.processStatus);\r\n }\r\n\r\n get isReadOnly(): boolean {\r\n return this._filingBatchService.isReadOnly(this.filingBatch && this.filingBatch.processStatus);\r\n }\r\n\r\n get isFinalized(): boolean {\r\n return this._filingBatchService.isFinalized(this.filingBatch && this.filingBatch.processStatus);\r\n }\r\n\r\n get canEdit(): boolean {\r\n return this.canEditCompany && !this._filingBatchService.isReadOnly(this.filingBatch && this.filingBatch.processStatus);\r\n }\r\n\r\n get hasFilings(): boolean {\r\n return this.filingBatch && this.filingBatch.filingCount ? true : false;\r\n }\r\n\r\n get beginPreparationHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n if (!this.hasFilings) {\r\n return 'filing-batch-details.begin-preparation-no-filings';\r\n }\r\n\r\n return 'filing-batch-details.begin-preparation';\r\n }\r\n\r\n get continuePreparationHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n if (!this.hasFilings) {\r\n return 'filing-batch-details.continue-preparation-no-filings';\r\n }\r\n\r\n return 'filing-batch-details.continue-preparation';\r\n }\r\n\r\n get viewReturnsHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n return 'filing-batch-details.view-returns';\r\n }\r\n\r\n get attachmentsHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n return 'app.attachments';\r\n }\r\n\r\n get commentsHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n return 'app.comments';\r\n }\r\n\r\n get refreshHelpContentId(): string {\r\n if (!this.canEnterEditMode) {\r\n return 'app.disabled-edit-mode';\r\n }\r\n\r\n return 'app.refresh';\r\n }\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.filingBatch) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: 'FilingBatch',\r\n entityName: this.filingBatch.description,\r\n entityData: {\r\n typeId: Core.EntityTypes.FilingBatch,\r\n id: this.filingBatch.filingBatchId,\r\n name: this.filingBatch.description\r\n },\r\n singleYear: true,\r\n year: this.filingBatch.taxYear,\r\n disableYears: true,\r\n readOnly: !this.canEditCompany\r\n } as AttachmentModalData;\r\n }\r\n\r\n get commentsModel(): CommentModalData {\r\n if (!this.filingBatch) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityID: this.filingBatch.filingBatchId,\r\n entityTypeID: Core.EntityTypes.FilingBatch,\r\n description: this.filingBatch.description,\r\n year: this.filingBatch.taxYear.toString(),\r\n canEdit: this.canEditCompany,\r\n parcelAcctNum: undefined,\r\n parcelID: undefined,\r\n } as CommentModalData;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(FILING_BATCH_DETAILS_HELP);\r\n\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n this.filingBatchId = parseInt(this._routerService.getQuerystringParam('filingBatchId')) || 0;\r\n this.addMode = this.filingBatchId === 0;\r\n\r\n const busyRef = this._busyService.show({ message: 'Loading' });\r\n\r\n const responses = await Promise.all([\r\n this._companyService.getInfoForCompliance(this.companyId),\r\n this._restrictService.hasCompanyPermission(this.companyId, Core.AccessRightsEnum.Write)\r\n ]);\r\n\r\n const company = responses[0];\r\n\r\n if (!(company.ppReturnPreparationAllowed && this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, company.instanceID))) {\r\n return await this.navigateToUnauthorized();\r\n }\r\n\r\n if (company.companyID !== company.topLevelCompanyId) {\r\n return await this.navigateToUnauthorized();\r\n }\r\n\r\n if (this.addMode) {\r\n this.filingBatch = {\r\n companyId: this.companyId,\r\n filingBatchId: this.filingBatchId,\r\n processStatus: Compliance.FilingBatchProcessStatusEnum.NotStarted,\r\n description: null,\r\n dueDate: null,\r\n filingTypeId: null,\r\n stateId: null,\r\n taxYear: null,\r\n rowVersion: null,\r\n getPriorReturnFromAssetList: false,\r\n reportNBVInsteadOfFactoredCost: false,\r\n returnCostReportingDisplayId: Compliance.ReturnCostReportingDisplayEnum.Both\r\n };\r\n } else {\r\n this.filingBatch = await lastValueFrom(this._filingBatchRepository.get(this.filingBatchId));\r\n\r\n if (company.companyID !== this.filingBatch.companyId) {\r\n return await this.navigateToUnauthorized();\r\n }\r\n }\r\n\r\n this.companyName = company.companyName;\r\n this.canEditCompany = responses[1];\r\n\r\n this.breadcrumbs = [\r\n {\r\n name: company.companyName,\r\n target: 'company',\r\n options: { companyId: company.companyID }\r\n },\r\n {\r\n name: 'Filing Batches',\r\n target: 'filingBatchList',\r\n options: { companyId: this.filingBatch.companyId }\r\n }\r\n ];\r\n\r\n this._filingBatchChangeSub = this._filingBatchService.filingBatchChange$.subscribe(async x => {\r\n if (this.filingBatch && x && this.filingBatch.filingBatchId === x.filingBatchId) {\r\n _.extend(this.filingBatch, x);\r\n }\r\n });\r\n\r\n this._lockChangedSub = this._mutexService.lockChanged$.subscribe((x) => {\r\n const isLocked = x && x[this._filingBatchService.editGroup];\r\n if (isLocked) {\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you wish to leave?');\r\n }\r\n else {\r\n this._navigationService.disableNavWarning();\r\n }\r\n });\r\n\r\n try {\r\n if (!this.addMode) {\r\n await this._filingBatchService.start(this.filingBatchId);\r\n }\r\n\r\n this.isInitialized = true;\r\n\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._filingBatchChangeSub && this._filingBatchChangeSub.unsubscribe();\r\n this._lockChangedSub && this._lockChangedSub.unsubscribe();\r\n this._filingBatchService.stop();\r\n }\r\n\r\n onFilingBatchCreated(filingBatchModel: Compliance.FilingBatchModel): void {\r\n this.filingBatch = filingBatchModel;\r\n if (this.addMode) {\r\n this._productAnalyticsService.logEvent('access-filing-batch', {\r\n returnAccessPath: 'new filing batch'\r\n });\r\n this._navigationService.disableNavWarning();\r\n this.navigateToFilingBatchDetails();\r\n }\r\n }\r\n\r\n onFilingBatchUpdated(filingBatchModel: Compliance.FilingBatchModel): void {\r\n this.filingBatch = filingBatchModel;\r\n }\r\n\r\n onFilingBatchDeleted(): void {\r\n this._navigationService.disableNavWarning();\r\n this.navigateToFilingBatchList();\r\n }\r\n\r\n onFilingBatchChangesCancelled(): void {\r\n if (this.addMode) {\r\n this._navigationService.disableNavWarning();\r\n this.navigateToFilingBatchList();\r\n }\r\n }\r\n\r\n async amendReturns(): Promise {\r\n const params: AmendReturnsModalParams = {\r\n companyId: this.companyId,\r\n filingBatch: this.filingBatch,\r\n filings: this._filingDetailService.currentFilings\r\n };\r\n\r\n const result = await this._modalService.showAsync(AmendReturnsComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return;\r\n }\r\n\r\n this._routerService.go('filingBatchDetails', { companyId: result.companyId, filingBatchId: result.filingBatchId });\r\n }\r\n\r\n navigateToCompany(): void {\r\n this._routerService.go('company', { 'companyId': this.filingBatch.companyId });\r\n }\r\n\r\n navigateToFilingBatchList(): void {\r\n this._routerService.go('filingBatchList',\r\n {\r\n 'companyId': this.filingBatch.companyId\r\n });\r\n }\r\n\r\n navigateToFilingBatchDetails(): void {\r\n this._routerService.go('filingBatchDetails',\r\n {\r\n 'companyId': this.filingBatch.companyId,\r\n 'filingBatchId': this.filingBatch.filingBatchId\r\n });\r\n }\r\n\r\n async navigateToReturnBatch(): Promise {\r\n this._routerService.go('returnFilingBatchPage',\r\n {\r\n 'filingBatchId': this.filingBatch.filingBatchId,\r\n });\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n async refresh(): Promise {\r\n this.refreshing = true;\r\n\r\n try {\r\n this.refresh$.next();\r\n\r\n this.filingBatch = await lastValueFrom(this._filingBatchRepository.get(this.filingBatchId));\r\n } finally {\r\n this.refreshing = false;\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n isHidden(componentName: string): boolean {\r\n return this._filingBatchService.isOtherComponentExpanded(componentName);\r\n }\r\n\r\n onFilingsChanged(changes: FilingsChangeModel): void {\r\n this.showChangeDetection = (!this.addMode) && changes.count && (!changes.hasPriorReturns);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer } from '../AgGrid/MultiSelectTracker';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { FilingBatchService } from './filingBatch.service'\r\nimport { FilingBatchListComponent } from './Filing-Batch-List/filingBatchList.component';\r\nimport { FilingBatchListGridActionCellRendererComponent } from './Filing-Batch-List/agGridActionCellRenderer.component';\r\nimport { FilingBatchDetailsComponent } from './Filing-Batch-Details/filingBatchDetails.component'\r\nimport { FilingBatchInfoComponent } from './Filing-Batch-Details/Filing-Batch-Info/filingBatchInfo.component'\r\nimport { FilingBatchAccountsComponent } from './Filing-Batch-Details/Filing-Batch-Accounts/filingBatchAccounts.component'\r\nimport { FilingBatchAccountsGridActionCellRendererComponent } from './Filing-Batch-Details/Filing-Batch-Accounts/filingBatchAccountsAgGridActionCellRenderer.component'\r\nimport { FilingBatchAddAccountsComponent } from './Filing-Batch-Details/Filing-Batch-Add-Accounts/filingBatchAddAccounts.component';\r\nimport { AgGridLinkCellRendererComponent } from '../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { FilingDetailsComponent } from './Filing-Batch-Details/Filing-Details/filingDetails.component';\r\nimport { StepProgressIndicatorModule } from '../../Common/Step-Progress-Indicator/stepProgressIndicator.module';\r\nimport { FilingBatchProgressComponent } from './Filing-Batch-Progress/filingBatchProgress.component';\r\nimport { FilingBatchProgressCellRendererComponent } from './Filing-Batch-List/agGridProgressCellRenderer.component';\r\nimport { FilingBatchMoveModalComponent } from './Filing-Batch-Details/Filing-Batch-Move-Modal/filingBatchMoveModal.component';\r\nimport { FilingBatchMoveResultModalComponent } from './Filing-Batch-Details/Filing-Batch-Move-Result-Modal/filingBatchMoveResultModal';\r\nimport { AmendReturnsComponent } from './Filing-Batch-Details/Amend-Returns-Modal/amendReturns.component';\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n ReactiveFormsModule,\r\n CommonModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n TypeaheadModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n StepProgressIndicatorModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectedCellRenderer,\r\n // filing batch list\r\n FilingBatchListGridActionCellRendererComponent,\r\n // filing batch accounts\r\n FilingBatchAccountsGridActionCellRendererComponent,\r\n AgGridLinkCellRendererComponent,\r\n FilingBatchProgressCellRendererComponent\r\n ])\r\n ],\r\n declarations: [\r\n FilingBatchListComponent,\r\n FilingBatchListGridActionCellRendererComponent,\r\n FilingBatchDetailsComponent,\r\n FilingBatchInfoComponent,\r\n FilingBatchAccountsComponent,\r\n FilingBatchAddAccountsComponent,\r\n FilingBatchAccountsGridActionCellRendererComponent,\r\n FilingDetailsComponent,\r\n FilingBatchProgressComponent,\r\n FilingBatchMoveModalComponent,\r\n FilingBatchMoveResultModalComponent,\r\n FilingBatchProgressCellRendererComponent,\r\n AmendReturnsComponent\r\n ],\r\n providers: [\r\n FilingBatchService\r\n ],\r\n exports: [\r\n FilingBatchProgressComponent\r\n ]\r\n})\r\nexport class FilingBatchModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('filingBatchList', FilingBatchListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('filingBatchDetails', FilingBatchDetailsComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { ScrollingModule } from '@angular/cdk/scrolling';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WeissmanSharedModule } from '../../../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { BusyIndicatorModule } from '../../../../Busy-Indicator';\r\nimport { ReturnPreviewComponent } from './returnPreview.component';\r\nimport { ReturnPreviewFormListComponent } from './Form-List/returnPreviewFormList.component';\r\nimport { ReturnPreviewFormAssociationsComponent } from './Form-Associations/returnPreviewFormAssociations.component';\r\nimport { ReturnPreviewFormDownloadComponent } from './Form-Download/returnPreviewFormDownload.component';\r\nimport { ReturnPreviewFormViewerComponent } from './Form-Viewer/returnPreviewFormViewer.component';\r\nimport { ReturnPreviewFormOverrideEditComponent } from './Form-Viewer/Override-Edit/returnPreviewFormOverrideEdit.component';\r\nimport { ReturnPreviewFormOverridesComponent } from './Form-Overrides/returnPreviewFormOverrides.component';\r\nimport { ReturnPreviewFormOverrideListComponent } from './Form-Overrides-List/returnPreviewFormOverrideList.component';\r\nimport { ReturnPreviewFormOverridesListActionCellRendererComponent } from './Form-Overrides-List/agGridActionCellRenderer.component';\r\nimport { ReturnPreviewOverrideChangesComponent } from './Form-Viewer/Override-Changes/returnPreviewOverrideChanges.component';\r\nimport { ReturnPreviewService } from './returnPreview.service';\r\nimport { AgGridExtensionsModule } from '../../../AgGrid/agGridExtensions.module';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridLoadingOverlayComponent } from '../../../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n ReactiveFormsModule,\r\n CommonModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BusyIndicatorModule.forRoot(),\r\n TooltipModule,\r\n ScrollingModule,\r\n AgGridExtensionsModule,\r\n BsDropdownModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent\r\n ])\r\n ],\r\n declarations: [\r\n ReturnPreviewComponent,\r\n ReturnPreviewFormListComponent,\r\n ReturnPreviewFormAssociationsComponent,\r\n ReturnPreviewFormDownloadComponent,\r\n ReturnPreviewFormViewerComponent,\r\n ReturnPreviewFormOverrideEditComponent,\r\n ReturnPreviewFormOverridesComponent,\r\n ReturnPreviewFormOverrideListComponent,\r\n ReturnPreviewFormOverridesListActionCellRendererComponent,\r\n ReturnPreviewOverrideChangesComponent\r\n ],\r\n providers: [\r\n ReturnPreviewService\r\n ],\r\n exports: [\r\n ReturnPreviewComponent\r\n ]\r\n})\r\nexport class ReturnPreviewModule{}\r\n","import { NgModule } from '@angular/core';\r\nimport { ScrollingModule } from '@angular/cdk/scrolling';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { DragulaModule } from 'ng2-dragula'\r\nimport { WeissmanSharedModule} from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule} from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { BusyIndicatorModule} from '../../Busy-Indicator';\r\nimport { AgGridLoadingOverlayComponent} from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer } from '../AgGrid/MultiSelectTracker'\r\nimport { AgGridModule} from 'ag-grid-angular';\r\nimport { AssetClassSelectorModule } from '../Asset/Asset-Class-Selector/assetClassSelector.module';\r\nimport { ReturnService } from './return.service';\r\nimport { ReturnOverviewService } from './Return-Parts/Overview/returnOverview.service';\r\nimport { ReturnAssetsService } from './Return-Parts/Assets/returnAssets.service';\r\nimport { ReturnOutputService } from './Return-Parts/Output/returnOutput.service';\r\nimport { ReturnSettingsService } from './Return-Parts/Settings/returnSettings.service';\r\nimport { ReturnPageComponent } from './returnPage.component';\r\nimport { ReturnFormSelectorComponent } from './Return-Form-Selector/returnFormSelector.component';\r\nimport { ReturnBatchComponent } from './Return-Batch/returnBatch.component';\r\nimport { ReturnPartsComponent } from './Return-Parts/returnParts.component';\r\nimport { ReturnOverviewComponent } from './Return-Parts/Overview/returnOverview.component';\r\nimport { ReturnSummaryReconciliationReportComponent } from './Return-Parts/Overview/Return-Summary/returnSummary.component';\r\nimport { ScheduleAdditionsDisposalsReconciliationReportComponent } from './Return-Parts/Overview/Schedule-Additions-Disposals/scheduleAdditionsDisposals.component';\r\nimport { FilingControlReconciliationReportComponent } from './Return-Parts/Overview/Filing-Control/filingControl.component';\r\nimport { FilingControlListReconciliationReportComponent } from './Return-Parts/Overview/Filing-Control/Filing-Control-List/filingControlList.component';\r\nimport { FilingControlGroupedReconciliationReportComponent } from './Return-Parts/Overview/Filing-Control/Filing-Control-Grouped/filingControlGrouped.component';\r\nimport { ReturnAssetsComponent } from './Return-Parts/Assets/returnAssets.component';\r\nimport { ReturnAssetDragAndDropSourceComponent } from './Return-Parts/Assets/Drag-And-Drop/returnAssetDragAndDropSource.component';\r\nimport { ReturnAssetDragAndDropTargetComponent } from './Return-Parts/Assets/Drag-And-Drop/returnAssetDragAndDropTarget.component';\r\nimport { ReturnAssetDragAndDropService } from './Return-Parts/Assets/Drag-And-Drop/returnAssetDragAndDrop.service';\r\nimport { ReturnAssetListComponent } from './Return-Parts/Assets/Asset-List/returnAssetList.component';\r\nimport { ReturnAssetDisposalsListComponent } from './Return-Parts/Assets/Asset-Disposals-List/returnAssetDisposalsList.component';\r\nimport { ReturnAssetFormDetailsComponent } from './Return-Parts/Assets/Form-Details/returnAssetFormDetails.component';\r\nimport { ReturnAssetFormStatusSelectorComponent } from './Return-Parts/Assets/Form-Details/Form-Status-Selector/returnAssetFormStatusSelector.component';\r\nimport { ReturnAssetFormFactorSelectorComponent } from './Return-Parts/Assets/Form-Details/Form-Factor-Selector/returnAssetFormFactorSelector.component';\r\nimport { ReturnAssetFormScheduleComponent } from './Return-Parts/Assets/Form-Details/Form-Schedule/returnAssetFormSchedule.component';\r\nimport { AssessorTablePickerComponent } from './Return-Parts/Assets/Assessor-Table-Picker/assessorTablePicker.component';\r\nimport { ReturnAssetListGridActionCellRendererComponent } from './Return-Parts/Assets/Asset-List/agGridActionCellRenderer.component';\r\nimport { ReturnAssetDisposalsListGridActionCellRendererComponent } from './Return-Parts/Assets/Asset-Disposals-List/agGridActionCellRenderer.component';\r\nimport { ReturnAssetChangeIconCellRendererComponent } from './Return-Parts/Assets/Asset-List/agGridChangeIconCellRenderer.component';\r\nimport { ReturnOutputComponent } from './Return-Parts/Output/returnOutput.component';\r\nimport { ReturnSettingsComponent } from './Return-Parts/Settings/Return-Settings/returnSettings.component';\r\nimport { ReturnSettingsTabComponent } from './Return-Parts/Settings/returnSettingsTab.component';\r\nimport { ReturnLockModalComponent } from './Return-Task/Return-Lock-Modal/returnLockModal.component';\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { AgGridCheckboxCellRendererComponent } from '../AgGrid/CellRenderers/agGridCheckboxCellRender.component';\r\nimport { ReturnSettingsEntityAttributeComponent } from './Return-Parts/Settings/Return-Settings-Entity-Attribute/returnSettingsEntityAttribute.component';\r\nimport { ReturnSettingsContactAttributeComponent } from './Return-Parts/Settings/Return-Settings-Contact-attribute/returnSettingsContactAttribute.component';\r\nimport { FilingBatchModule } from '../Filing-Batch/filingBatch.module';\r\nimport { ReturnOutputPackageListComponent } from './Return-Parts/Output/Package-List/returnOutputPackageList.component';\r\nimport { ReturnOutputPackageListDropdownCellRenderer } from './Return-Parts/Output/Package-List/agGridDropdownCellRenderer.component';\r\nimport { ReturnSettingsReportListComponent } from './Return-Parts/Settings/Report-List/returnSettingsReportList.component';\r\nimport { ReturnSettingsReportAddComponent } from './Return-Parts/Settings/Report-List-Add/returnSettingsReportAdd.component';\r\nimport { ReturnSettingsReportListGridActionCellRendererComponent } from './Return-Parts/Settings/Report-List/agGridActionCellRenderer.component';\r\nimport { ReturnSettingsOverrideComponent } from './Return-Parts/Settings/Settings-Override/returnSettingsOverride.component';\r\nimport { ReturnOutputPrintingMailingComponent } from './Return-Parts/Output/Printing-Mailing/returnOutputPrintingMailing.component';\r\nimport { ReturnAssetStatusSelectorComponent } from './Return-Parts/Assets/Asset-Status-Selector/returnAssetStatusSelector.component';\r\nimport { FilingControlReconciliationReportAssessorRenderer } from './Return-Parts/Overview/Filing-Control/Filing-Control-Grouped/agGridAssessorCellRenderer.component';\r\nimport { ReturnTaskComponent } from './Return-Task/returnTask.component';\r\nimport { ReturnTaskExceptionComponent } from './Return-Task/Return-Task-Exception/returnTaskException.component';\r\nimport { ReturnTaskExceptionModalComponent } from './Return-Task/Return-Task-Exception-Modal/returnTaskExceptionModal.component';\r\nimport { ReturnSignModalComponent } from './Return-Task/Return-Sign-Modal/returnSignModal.component';\r\nimport { ReturnFormsErrorComponent } from './Return-Forms-Error/returnFormsError.component';\r\nimport { ReturnCompareMessageComponent } from './Return-Compare-Message/returnCompareMessage.component';\r\nimport { ReturnCompareConfirmationModalComponent } from './Return-Compare-Message/returnCompareConfirmationModal.component';\r\nimport { ReturnFinalizeModalComponent } from './Return-Task/Return-Finalize-Modal/returnFinalizeModal.component';\r\nimport { ReturnSettingsNameAttributeComponent } from './Return-Parts/Settings/Return-Settings-Name-Attribute/returnSettingsNameAttribute.component';\r\nimport { ReturnAssetBulkUpdateComponent } from './Return-Parts/Assets/Return-Asset-Bulk-Update/returnAssetBulkUpdate.component';\r\nimport { ReturnAssetBulkUpdateActionComponent } from './Return-Parts/Assets/Return-Asset-Bulk-Update/returnAssetBulkUpdateAction.component';\r\nimport { ScheduleSelectorComponent } from './Return-Parts/Assets/Schedule-Selector/scheduleSelector.component';\r\nimport { ReturnSettingsGeneralComponent } from \"./Return-Parts/Settings/General/returnSettingsGeneral.component\";\r\nimport { AgGridConsolidatedGroupCellRenderer } from './Return-Parts/Overview/Filing-Control/Filing-Control-Grouped/agGridConsolidatedGroupCellRenderer.component';\r\nimport { ReturnPreviewModule } from './Return-Parts/Preview/returnPreview.module';\r\nimport { ReturnBatchTaxYearAdditionalInfoComponent } from './Return-Batch/returnBatchTaxYearAdditionalInfo.component';\r\nimport {\r\n ReturnAssessorAddressChangedMessageComponent\r\n} from './Return-Assessor-Address-Changed-Message/returnAssessorAddressChangedMessage.component';\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n ReactiveFormsModule,\r\n CommonModule,\r\n WeissmanSharedModule,\r\n CurrencyMaskModule,\r\n SharedPipesModule,\r\n DragulaModule,\r\n TabsModule,\r\n TypeaheadModule,\r\n BsDropdownModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n FilingBatchModule,\r\n TooltipModule,\r\n ScrollingModule,\r\n AssetClassSelectorModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectedCellRenderer,\r\n ReturnAssetListGridActionCellRendererComponent,\r\n ReturnAssetDisposalsListGridActionCellRendererComponent,\r\n AgGridCheckboxCellRendererComponent,\r\n ReturnSettingsReportListGridActionCellRendererComponent,\r\n FilingControlReconciliationReportAssessorRenderer\r\n ]),\r\n ReturnPreviewModule\r\n ],\r\n declarations: [\r\n ReturnPageComponent,\r\n ReturnTaskComponent,\r\n ReturnTaskExceptionComponent,\r\n ReturnTaskExceptionModalComponent,\r\n ReturnFinalizeModalComponent,\r\n ReturnFormSelectorComponent,\r\n ReturnBatchComponent,\r\n ReturnLockModalComponent,\r\n ReturnSignModalComponent,\r\n ReturnFormsErrorComponent,\r\n ReturnCompareMessageComponent,\r\n ReturnCompareConfirmationModalComponent,\r\n // separate tabs related to the return\r\n ReturnPartsComponent,\r\n // return overview tab\r\n ReturnOverviewComponent,\r\n ReturnSummaryReconciliationReportComponent,\r\n ScheduleAdditionsDisposalsReconciliationReportComponent,\r\n FilingControlReconciliationReportComponent,\r\n FilingControlListReconciliationReportComponent,\r\n FilingControlGroupedReconciliationReportComponent,\r\n FilingControlReconciliationReportAssessorRenderer,\r\n AgGridConsolidatedGroupCellRenderer,\r\n // return assets tab\r\n ReturnAssetsComponent,\r\n ReturnAssetDragAndDropSourceComponent,\r\n ReturnAssetDragAndDropTargetComponent,\r\n ReturnAssetListComponent,\r\n ReturnAssetDisposalsListComponent,\r\n ReturnAssetFormDetailsComponent,\r\n ReturnAssetFormStatusSelectorComponent,\r\n ReturnAssetFormFactorSelectorComponent,\r\n ReturnAssetFormScheduleComponent,\r\n ReturnAssetChangeIconCellRendererComponent,\r\n AssessorTablePickerComponent,\r\n ReturnAssetListGridActionCellRendererComponent,\r\n ReturnAssetDisposalsListGridActionCellRendererComponent,\r\n // return output tab\r\n ReturnOutputComponent,\r\n ReturnOutputPackageListComponent,\r\n ReturnOutputPackageListDropdownCellRenderer,\r\n ReturnOutputPrintingMailingComponent,\r\n // return settings\r\n ReturnSettingsTabComponent,\r\n ReturnSettingsComponent,\r\n ReturnSettingsOverrideComponent,\r\n ReturnSettingsEntityAttributeComponent,\r\n ReturnSettingsNameAttributeComponent,\r\n ReturnSettingsContactAttributeComponent,\r\n ReturnSettingsReportListComponent,\r\n ReturnSettingsReportAddComponent,\r\n ReturnSettingsReportListGridActionCellRendererComponent,\r\n ReturnAssetStatusSelectorComponent,\r\n ReturnAssetBulkUpdateComponent,\r\n ReturnAssetBulkUpdateActionComponent,\r\n ScheduleSelectorComponent,\r\n ReturnSettingsGeneralComponent,\r\n ReturnBatchTaxYearAdditionalInfoComponent,\r\n ReturnAssessorAddressChangedMessageComponent\r\n ],\r\n providers: [\r\n ReturnService,\r\n ReturnOverviewService,\r\n ReturnAssetsService,\r\n ReturnOutputService,\r\n ReturnSettingsService,\r\n ReturnAssetDragAndDropService\r\n ],\r\n exports: [\r\n ReturnSettingsComponent,\r\n ReturnSettingsEntityAttributeComponent,\r\n ReturnSettingsNameAttributeComponent,\r\n ReturnSettingsContactAttributeComponent,\r\n ReturnAssetStatusSelectorComponent\r\n ]\r\n})\r\nexport class ReturnModule{\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('returnPage', ReturnPageComponent);\r\n hybridAdapterUtility.downgradeNg2Component('complianceReturnSettingsComponent', ReturnSettingsComponent);\r\n hybridAdapterUtility.downgradeNg2Component('complianceReturnSettingsEntityAttributeComponent', ReturnSettingsEntityAttributeComponent);\r\n hybridAdapterUtility.downgradeNg2Component('complianceReturnSettingsNameAttributeComponent', ReturnSettingsNameAttributeComponent);\r\n hybridAdapterUtility.downgradeNg2Component('complianceReturnSettingsContactAttributeComponent', ReturnSettingsContactAttributeComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { CompanyReturnSettingsPanelComponent } from './Company-Return-Settings-Panel/companyReturnSettingsPanel.component';\r\nimport { ReturnModule } from '../Return/return.module';\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n CommonModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent\r\n ]),\r\n ReturnModule\r\n ],\r\n declarations: [\r\n CompanyReturnSettingsPanelComponent\r\n ],\r\n providers: [],\r\n exports: [\r\n CompanyReturnSettingsPanelComponent\r\n ]\r\n})\r\nexport class ComplianceCompanyModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('complianceCompanyReturnSettingsPanel', CompanyReturnSettingsPanelComponent);\r\n }\r\n}\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../Compliance/AgGrid';\r\nimport { ContactsUpgradeService } from '../contacts.service.upgrade';\r\n\r\nexport class ContactListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _contactService: ContactsUpgradeService\r\n ) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'name', value: Core.ContactModelPropertyEnum.ContactName },\r\n { name: 'title', value: Core.ContactModelPropertyEnum.Title },\r\n { name: 'phone', value: Core.ContactModelPropertyEnum.Phone },\r\n { name: 'entityName', value: Core.ContactModelPropertyEnum.CompanyName },\r\n { name: 'hasUser', value: Core.ContactModelPropertyEnum.HasUser },\r\n { name: 'email', value: Core.ContactModelPropertyEnum.Email }\r\n ];\r\n\r\n getSearchParamsWithoutPagination(): Core.ContactSearchModel {\r\n const model = this._contactService.currentSearchModel;\r\n\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n entityId: model?.entityId,\r\n entityType: model?.entityType,\r\n excludeInactive: model?.excludeInactive,\r\n instanceId: model?.instanceId\r\n };\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const model = this._contactService.currentSearchModel;\r\n\r\n const searchParams: Core.ContactSearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n entityId: model?.entityId,\r\n entityType: model?.entityType,\r\n excludeInactive: model?.excludeInactive,\r\n instanceId: model?.instanceId\r\n };\r\n\r\n return await this._contactService.getRowIds(searchParams);\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return this._contactService.canGetRows;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const model = this._contactService.currentSearchModel;\r\n\r\n const searchParams: Core.ContactSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n entityId: model?.entityId,\r\n entityType: model?.entityType,\r\n excludeInactive: model?.excludeInactive,\r\n instanceId: model?.instanceId\r\n };\r\n\r\n let result;\r\n\r\n if (this._contactService.dialogMode) {\r\n //TODO implement this once the other old contact lists have been converted\r\n if (model.entityType === 'assessor' || model.entityType === 'state' || model.entityType === 'collector') {\r\n // result = await this._contactService.searchRyan(searchText, this.pageNumber, this.pageSize, this.excludeInactive);\r\n } else {\r\n // result = await this._contactService.searchScoped(this.entityInfo.id, this.entityInfo.type, searchText, this.pageNumber, this.pageSize, this.excludeInactive);\r\n }\r\n } else {\r\n result = await this._contactService.getList(searchParams);\r\n }\r\n\r\n if (!result) {\r\n return null;\r\n }\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n {{header}}\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n \r\n \r\n
\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport {\r\n ColDef,\r\n ColumnApi,\r\n GridApi,\r\n GridReadyEvent\r\n} from 'ag-grid-community';\r\nimport { Subject } from 'rxjs';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { AgGridFilterParams, AgGridOptionsBuilder } from '../../Compliance/AgGrid';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from '../../Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport {\r\n AgGridYesNoFloatingFilterComponent\r\n} from '../../Compliance/AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../Compliance/AgGrid/ToolPanel/models';\r\nimport { ContactModalOrigin } from '../../constants.new';\r\nimport { ContactRoleService } from '../../Role/contact.role.service';\r\nimport { UtilitiesService } from '../../UI-Lib/Utilities';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { ContactModalService } from '../contactModal.service';\r\nimport { ContactListSearchModel, ContactsUpgradeService } from '../contacts.service.upgrade';\r\nimport { ContactListAgGridDataSource } from './agGridDataSource';\r\n\r\n@Component({\r\n selector: 'contact-list-page',\r\n templateUrl: './contactListPage.component.html',\r\n styleUrls: ['./contactListPage.component.scss']\r\n})\r\nexport class ContactListPageComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _contactService: ContactsUpgradeService,\r\n private readonly _contactModalService: ContactModalService,\r\n private readonly _upgradeNavigationService: UpgradeNavigationServiceHandler,\r\n private readonly _roleService: ContactRoleService,\r\n private readonly _utils: UtilitiesService\r\n ) {}\r\n\r\n @Input() dialogMode: boolean = false;\r\n @Input() dialogParameters: any;\r\n\r\n header: string = 'Contacts';\r\n entityInfo: any;\r\n recipientMode: boolean = false;\r\n notAllowedRoles = []; //Dima: list of roles, which needs to be removed from the drop down list.E.g. for entity contacts, we can select only one Tax Bill Recipient\r\n excludeInactive: boolean = false;\r\n\r\n gridId: System.Guid = 'c0899ab1-6634-4a4c-b9cc-f148cb781959';\r\n columnApi: ColumnApi;\r\n gridOptions = new AgGridOptionsBuilder({\r\n getRowNodeId: (data) => data.contactID.toString(),\r\n })\r\n .withColumnPinning()\r\n .withFloatingFilter()\r\n .buildDefault(this);\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[]): Promise => {\r\n const searchModel = this._gridDataSource.getSearchParamsWithoutPagination();\r\n\r\n const exportModel: Core.ContactsExportModel = {\r\n columnsToReturn: columnsToReturn,\r\n searchModel: searchModel\r\n };\r\n const longRunningProcessId = await this._contactService.exportList(exportModel);\r\n return { longRunningProcessId, longRunningProcessTypeId: Compliance.LongRunningProcessTypeEnum.ExportContacts };\r\n },\r\n getDisabled: () => !this.canGetRows,\r\n canCancel: true\r\n };\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: ContactListAgGridDataSource;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get canGetRows(): boolean {\r\n return !this._gridDataSource?.isRefreshing && this._contactService.canGetRows;\r\n }\r\n\r\n ngOnInit() {\r\n this.recipientMode = this.dialogMode && this.dialogParameters.recipientMode;\r\n if (this.recipientMode) {\r\n this.header = '';\r\n }\r\n\r\n this.excludeInactive = !this._userInstanceService.isCurrentInstanceSystem();\r\n\r\n const searchModel: ContactListSearchModel = {\r\n entityId: null,\r\n entityType: null,\r\n excludeInactive: this.excludeInactive,\r\n instanceId: null\r\n };\r\n\r\n if (this.dialogMode) {\r\n this.entityInfo = this.dialogParameters.entityInfo;\r\n\r\n searchModel.entityType = this.entityInfo.type;\r\n searchModel.entityId = this.entityInfo.id;\r\n\r\n if (!this.recipientMode) {\r\n // this.gridTracker.clear();\r\n this.notAllowedRoles = this.dialogParameters.notAllowedRoles;\r\n this.header = 'Associate Contact to '; //+ this._utils.getEntityName(this.entityInfo.id); This always will return nothing\r\n }\r\n } else {\r\n searchModel.instanceId = this._userInstanceService.getSelectedInstance().instanceId;\r\n }\r\n\r\n this._contactService.currentSearchModel = searchModel;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent) {\r\n this._gridApi = event.api;\r\n\r\n // this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._setColumnDefinitions();\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'name',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n refresh(): void {\r\n this._contactService.currentSearchModel.excludeInactive = this.excludeInactive;\r\n this._refreshDataSource();\r\n }\r\n\r\n private _setColumnDefinitions(): void {\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Name',\r\n field: 'name',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParamsSmartSearch,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Core.ContactLongDTO;\r\n if (!model) {\r\n return '';\r\n }\r\n\r\n return `${model.lastName}, ${model.firstName}`;\r\n },\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Core.ContactLongDTO;\r\n if (!model) {\r\n return;\r\n }\r\n\r\n this._openContactDialog(model.contactID);\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Title',\r\n field: 'title',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Phone',\r\n field: 'phone',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Mobile',\r\n field: 'mobilePhone',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Has User',\r\n field: 'hasUser',\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: (params) => {\r\n const model = params.data as Core.ContactLongDTO;\r\n if (!model) {\r\n return '';\r\n }\r\n\r\n return model.hasUser ? 'Yes' : 'No';\r\n }\r\n },\r\n {\r\n headerName: 'Email',\r\n field: 'email',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'entityName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => '',\r\n newWindow: true,\r\n isHelpDisabled: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const entry = params.data as Core.ContactLongDTO;\r\n if (!entry || entry.entityID === null) {\r\n return '';\r\n }\r\n return `#/company/${entry.entityID}`;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const entry = params.data as Core.ContactLongDTO;\r\n return !entry || entry.entityID === null;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n }\r\n ];\r\n\r\n if (this.dialogMode) {\r\n // TODO implement selection when the other old contact lists have been converted\r\n // columns.unshift({\r\n // colId: 'grid-column-multiselect',\r\n // headerName: '',\r\n // field: 'assessorId',\r\n // width: AgGridColumns.selectionColumnWidth,\r\n // suppressSizeToFit: true,\r\n // suppressAutoSize: true,\r\n // suppressColumnsToolPanel: true,\r\n // editable: false,\r\n // pinned: 'left',\r\n // lockPinned: true,\r\n // lockVisible: true,\r\n // lockPosition: true,\r\n // suppressMovable: true,\r\n // headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n // headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n // cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n // cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n // } as ColDef);\r\n }\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n // this.gridTracker.clear();\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n // this.gridTracker.clear();\r\n\r\n this._gridDataSource = new ContactListAgGridDataSource(this._gridApi, this._contactService);\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private async _openContactDialog(contactId: number): Promise {\r\n const result = await this._contactModalService.openContactDialog(contactId, ContactModalOrigin.ContactsList);\r\n if (result) {\r\n const rowNode = this._gridApi.getRowNode(contactId.toString());\r\n rowNode.data = { ...rowNode.data, ...result };\r\n this._gridApi.redrawRows({ rowNodes: [rowNode] });\r\n }\r\n }\r\n}\r\n","\r\nimport {from as observableFrom, Observable } from 'rxjs';\r\n\r\nimport {map, mergeMap} from 'rxjs/operators';\r\nimport {Component, EventEmitter, Input, OnInit, Output} from '@angular/core';\r\nimport { ContactsUpgradeService } from '../../Contact/contacts.service.upgrade';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { ExtendedModelBase } from '../../Compliance/Models/extendedModelBase';\r\nimport { UpgradeNavigationServiceHandler } from '../Routing/upgrade-navigation-handler.service';\r\n\r\nexport class ExtendedContactModelCore extends ExtendedModelBase {\r\n constructor(model: Core.ContactModel) {\r\n super(model);\r\n }\r\n\r\n includeCompany: boolean;\r\n\r\n get displayName(): string {\r\n let nameStr = `${this.model.lastName}, ${this.model.firstName}`;\r\n if(this.includeCompany) {\r\n nameStr += ` (${(this.model as any).entityName})`;\r\n }\r\n return nameStr;\r\n }\r\n}\r\n\r\n@Component({\r\n selector: 'user-picker',\r\n template: `\r\n \r\n `\r\n})\r\nexport class UserPickerComponent implements OnInit{\r\n constructor(private _contactService: ContactsUpgradeService, private readonly _routerService: UpgradeNavigationServiceHandler){}\r\n\r\n @Input() currentContact: Core.ContactModel;\r\n @Input() isReadonly: boolean;\r\n @Input() currentContactId: number;\r\n @Input() includeBlank: boolean;\r\n @Input() search: any;\r\n @Input() includeCompany: boolean = false;\r\n @Input() usersOnly: boolean = false;\r\n\r\n @Output() contactChanged: EventEmitter = new EventEmitter();\r\n\r\n contactFilter: string = '';\r\n contacts$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.contactFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterContacts(token)));\r\n\r\n private _hasChanges: boolean;\r\n private _contactNoResult: boolean = false;\r\n\r\n async ngOnInit(): Promise {\r\n if(this.currentContactId && (!this.currentContact || (!this.currentContact.lastName && !this.currentContact.firstName))) {\r\n this.currentContact = await this._contactService.getById(this.currentContactId);\r\n }\r\n\r\n this._setContactFilterToCurrentValue();\r\n }\r\n\r\n get contact(): Core.ContactModel {\r\n return this.currentContact;\r\n }\r\n\r\n set contact(value: Core.ContactModel) {\r\n const contactId: number = value ? value.contactID : null;\r\n\r\n if (this.currentContactId !== contactId) {\r\n const extendedContact = new ExtendedContactModelCore({\r\n ...value,\r\n ...{\r\n contactID: contactId,\r\n firstName: value ? value.firstName : '',\r\n lastName: value ? value.lastName : ''\r\n }\r\n } as Core.ContactModel);\r\n\r\n this.contactChanged.emit(extendedContact);\r\n }\r\n\r\n this._hasChanges = true;\r\n this.currentContact = value;\r\n this.currentContactId = contactId;\r\n }\r\n\r\n get hasChanges(): boolean {\r\n return this._hasChanges;\r\n }\r\n\r\n onContactSelected(match: TypeaheadMatch): void {\r\n this.contact = (match.item as ExtendedContactModelCore).model;\r\n this.contactFilter = match.value;\r\n this._hasChanges = true;\r\n }\r\n\r\n onContactBlur(): void {\r\n if (this.contactFilter.trim() === '' || this._contactNoResult){\r\n this._setContactFilterToCurrentValue();\r\n }\r\n }\r\n\r\n get contactDisplay(): string {\r\n const contact = this.currentContact;\r\n\r\n return contact ? `${contact.lastName}, ${contact.firstName}` : '';\r\n }\r\n\r\n private _filterContacts(filter: string): Observable {\r\n\r\n const result = >this.search.find(filter);\r\n return observableFrom(result).pipe(\r\n map(contacts => {\r\n if(this.usersOnly) {\r\n contacts = contacts.filter(x => x.userID);\r\n }\r\n\r\n if (contacts && contacts.length === 0){\r\n this._contactNoResult = true;\r\n }\r\n\r\n if(this.includeBlank) {\r\n contacts.unshift({contactID: -1, firstName: '[Blank]', lastName: ''});\r\n }\r\n\r\n return contacts.map(contact => {\r\n const extendedContact = new ExtendedContactModelCore({\r\n ...contact,\r\n ...{\r\n contactID: contact.contactID,\r\n firstName: contact.firstName || '',\r\n lastName: contact.lastName || '',\r\n includeCompany: this.includeCompany\r\n }\r\n } as Core.ContactModel);\r\n\r\n extendedContact.includeCompany = this.includeCompany;\r\n return extendedContact;\r\n });\r\n }));\r\n }\r\n\r\n private _setContactFilterToCurrentValue(): void {\r\n const contact = this.currentContact;\r\n\r\n this.contactFilter = (contact && this.contactDisplay) || '';\r\n }\r\n}\r\n","
\r\n\r\n
\r\n
\r\n
\r\n

{{isSignatureEditMode ? 'Create your' : ''}} Signature

\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n It doesn't look like you have a signature. Click edit to create one.\r\n \r\n
\r\n
\r\n
\r\n X\r\n
\r\n Sign Above\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n Upload Requirements\r\n
    \r\n
  • File type must be *.gif or *.png
  • \r\n
  • Use a single color transparency
  • \r\n
  • Minimum 600 pixels wide by 200 pixels tall
  • \r\n
  • Signature centered horizontally and vertically
  • \r\n
\r\n \r\n \r\n The image must be of type .gif or .png\r\n
\r\n
\r\n\r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n

Users Authorized

\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n A signature is required to add authorized users.\r\n
\r\n
\r\n There are no additional authorized users for this signature.\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Users who are granted authorization to apply the digital signature
\r\n {{ user.lastName }}, {{ user.firstName }}\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, ViewChild, ElementRef, ChangeDetectorRef } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { InstanceRights, RestrictService } from '../../Common/Permissions/restrict.service';\r\nimport { ExtendedContactModelCore } from '../../Common/User-Pickers/user.picker.component';\r\nimport { UserSettingsService } from '../../Account/userSettings.service';\r\nimport { ContactsUpgradeService } from '../../Contact/contacts.service.upgrade';\r\nimport { ImageCroppedEvent, ImageTransform } from 'ngx-image-cropper';\r\nimport SignaturePad from 'signature_pad';\r\nimport { AccountService } from '../account.service';\r\nimport { InstanceRepository } from '../../Entity/Instance/instance.repository';\r\n\r\nenum SignatureType {\r\n Create,\r\n Upload\r\n}\r\n\r\n@Component({\r\n selector: 'signature-panel',\r\n templateUrl: './signature-panel.component.html',\r\n styleUrls: ['./signature-panel.component.scss']\r\n})\r\nexport class SignaturePanelComponent {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _userService: UserSettingsService,\r\n private readonly _contactService: ContactsUpgradeService,\r\n private readonly _accountService: AccountService,\r\n private readonly _cdRef: ChangeDetectorRef,\r\n private readonly _instanceRepository: InstanceRepository\r\n\r\n ) { }\r\n\r\n @Input() contact: Core.ContactModel;\r\n @Input() search: any;\r\n\r\n @ViewChild('signatureCanvas')\r\n set canvas(el: ElementRef) {\r\n if (el && !this._signaturePad) {\r\n this._canvas = el;\r\n this._signaturePad = new SignaturePad(this._canvas.nativeElement);\r\n this._signaturePad.onEnd = () => this.signatureChanged = true;\r\n this._cdRef.detectChanges();\r\n }\r\n }\r\n\r\n contactId = null;\r\n userId = null;\r\n instanceId: number = null;\r\n canEdit: boolean;\r\n isSignatureEditMode: boolean;\r\n isAuthorizedEditMode: boolean;\r\n addNewPerson: boolean;\r\n signatureLoading: boolean;\r\n usersAuthorizedLoading: boolean;\r\n\r\n signatureOptions: Compliance.NameValuePair[] = [\r\n { name: 'Create (Preferred)', value: SignatureType.Create },\r\n { name: 'Upload', value: SignatureType.Upload }\r\n ];\r\n signatureType: SignatureType = SignatureType.Create;\r\n signatureTypes = SignatureType;\r\n signatureChanged: boolean;\r\n contactSignatureImage: string = '';\r\n newContactSignatureImage: string;\r\n userToAdd: Core.ContactShortModel;\r\n authorizedUsers: Core.ContactShortModel[] = [];\r\n authorizedUsersChanges: Core.ContactShortModel[] = [];\r\n\r\n imageFile: any;\r\n selectedFileType: string;\r\n canvasRotation: number = 0;\r\n uploadTypeError: boolean;\r\n transform: ImageTransform = {};\r\n\r\n private _signaturePad: SignaturePad;\r\n private _canvas: ElementRef;\r\n\r\n get canAddUser(): boolean {\r\n return !this.authorizedUsers.find(user => user.userID === this.userToAdd.userID);\r\n }\r\n\r\n get authorizedUsersChanged(): boolean {\r\n const original = this.authorizedUsers.map(u => u.userID).sort();\r\n const updated = this.authorizedUsersChanges.map(u => u.userID).sort();\r\n return !(updated.toString() === original.toString());\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this.signatureLoading = true;\r\n this.usersAuthorizedLoading = true;\r\n\r\n try {\r\n this.contactId = this.contact.contactID;\r\n this.userId = this.contact.userID;\r\n\r\n this.instanceId = await lastValueFrom(this._instanceRepository.getEntityInstanceId('company', this.contact.companyID));\r\n\r\n this.canEdit = this._accountService.userData.id === this.contact.userID ||\r\n this._restrictService.hasInstanceRight(InstanceRights.MANAGEUSERSETUP, this.instanceId);\r\n\r\n await this._getUserSettings();\r\n await this._getContactSig();\r\n } finally {\r\n this.signatureLoading = false;\r\n this.usersAuthorizedLoading = false;\r\n }\r\n }\r\n\r\n // Signature\r\n\r\n beginSigEditMode(): void {\r\n if (!this.canEdit) { return; }\r\n this.isSignatureEditMode = true;\r\n this.newContactSignatureImage = null;\r\n this.signatureChanged = !!this.contactSignatureImage;\r\n }\r\n\r\n clearSignature(): void {\r\n this.imageFile = null;\r\n this.selectedFileType = null;\r\n if (!this._signaturePad) { return; }\r\n this._signaturePad.clear();\r\n this.newContactSignatureImage = null;\r\n this.signatureChanged = !!this.contactSignatureImage;\r\n }\r\n\r\n async saveSignature(): Promise {\r\n this.isSignatureEditMode = false;\r\n this.signatureChanged = false;\r\n\r\n if (this.signatureType === SignatureType.Create) {\r\n this.newContactSignatureImage = (!this._signaturePad.isEmpty()) ? this._signaturePad.toDataURL() : null;\r\n }\r\n\r\n this.contactSignatureImage = this.newContactSignatureImage;\r\n this.signatureType = SignatureType.Create;\r\n\r\n this.signatureLoading = true;\r\n\r\n try {\r\n await this._contactService.saveContactSignature(this.contact.contactID, this.contactSignatureImage);\r\n\r\n this.imageFile = null;\r\n this.selectedFileType = null;\r\n this.newContactSignatureImage = null;\r\n this._signaturePad = null;\r\n\r\n } finally {\r\n this.signatureLoading = false;\r\n }\r\n }\r\n\r\n cancelSignature(): void {\r\n this.clearSignature();\r\n this.signatureType = SignatureType.Create;\r\n this.isSignatureEditMode = false;\r\n this._signaturePad = null;\r\n this.imageFile = null;\r\n this.selectedFileType = null;\r\n this.canvasRotation = 0;\r\n }\r\n\r\n signatureTypeChanged(type: Compliance.NameValuePair): void {\r\n this.clearSignature();\r\n if (type.value === SignatureType.Upload) {\r\n this._signaturePad = null;\r\n }\r\n }\r\n\r\n // Upload\r\n\r\n filePicked(files: File[]): void {\r\n const { name } = files[0];\r\n const index = name.lastIndexOf('.');\r\n if (index !== 0) {\r\n const fileExtension = name.substr(index + 1).toLowerCase();\r\n if (fileExtension === 'gif' || fileExtension === 'png') {\r\n this.selectedFileType = fileExtension;\r\n this.imageFile = { target: { files: files } };\r\n this.uploadTypeError = false;\r\n this.signatureChanged = true;\r\n this._cdRef.detectChanges();\r\n } else {\r\n this.selectedFileType = null;\r\n this.imageFile = null;\r\n this.uploadTypeError = true;\r\n }\r\n }\r\n }\r\n\r\n imageCropped(event: ImageCroppedEvent) {\r\n this.newContactSignatureImage = event.base64;\r\n this.signatureChanged = true;\r\n }\r\n\r\n loadImageFailed(): void {\r\n this.imageFile = null;\r\n this.selectedFileType = null;\r\n throw Error('There was an error uploading the ');\r\n }\r\n\r\n rotateImageLeft(): void {\r\n this.canvasRotation -= (this.canvasRotation === 0) ? -3 : 1;\r\n }\r\n\r\n rotateImageRight(): void {\r\n this.canvasRotation += (this.canvasRotation === 3) ? -3 : 1;\r\n }\r\n\r\n // Authorized users\r\n\r\n beginAuthEditMode(): void {\r\n this.isAuthorizedEditMode = true;\r\n }\r\n\r\n cancelAuthorized(): void {\r\n this.authorizedUsersChanges = [...this.authorizedUsers];\r\n this.isAuthorizedEditMode = false;\r\n }\r\n\r\n async saveAuthorized(): Promise {\r\n this.isAuthorizedEditMode = false;\r\n\r\n if (this.authorizedUsersChanged) {\r\n\r\n const authUserModel = {\r\n groupId: 21,\r\n name: 'Users-Who-Are-Granted-Authorization-To-Apply-My-Digital-Signature',\r\n userId: this.userId,\r\n value: this.authorizedUsersChanges\r\n };\r\n\r\n this.usersAuthorizedLoading = true;\r\n\r\n try {\r\n const { value } = await this._userService.save(authUserModel);\r\n this.authorizedUsers = value;\r\n this.authorizedUsersChanges = [...value];\r\n } finally {\r\n this.usersAuthorizedLoading = false;\r\n }\r\n }\r\n }\r\n\r\n addUser(): void {\r\n this.addNewPerson = true;\r\n }\r\n\r\n removeUser(user: Core.ContactShortModel): void {\r\n this.cancelAddUser();\r\n const index = this.authorizedUsersChanges.indexOf(user);\r\n if (index > -1) {\r\n this.authorizedUsersChanges.splice(index, 1);\r\n }\r\n }\r\n\r\n cancelAddUser(): void {\r\n this.userToAdd = null;\r\n this.addNewPerson = false;\r\n }\r\n\r\n assignUser(user: ExtendedContactModelCore): void {\r\n const { userID, firstName, lastName } = user.model;\r\n this.userToAdd = { userID, firstName, lastName };\r\n }\r\n\r\n saveUser(): void {\r\n if (!this.userToAdd) {\r\n return;\r\n }\r\n\r\n this.authorizedUsersChanges.push(this.userToAdd);\r\n this.cancelAddUser();\r\n }\r\n\r\n private async _getUserSettings(): Promise {\r\n const settings = await this._userService.getSettingsByGroupAndUserId(21, this.userId);\r\n\r\n if (settings && settings.length) {\r\n const user = settings[0];\r\n this.authorizedUsers = user.value;\r\n this.authorizedUsersChanges = [...user.value];\r\n }\r\n }\r\n\r\n private async _getContactSig(): Promise {\r\n const sig = await this._contactService.getContactSignature(this.contactId);\r\n\r\n if (sig) {\r\n this.contactSignatureImage = sig.signatureBase64;\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from 'src/app/Common/Routing/sd-http.service';\r\n\r\n@Injectable()\r\nexport class CompanyPermissionsService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n getCompaniesThatAreMissingPermissionsForGroup(groupId, pageNumber: number, pageSize: number, companyNameFilter, excludeCompanyIds: any): Promise {\r\n if (!pageNumber) pageNumber = 1;\r\n if (!pageSize) pageSize = 100;\r\n if (!companyNameFilter || !companyNameFilter.length) companyNameFilter = null;\r\n if (!excludeCompanyIds) excludeCompanyIds = [];\r\n\r\n const serviceUrl = `/api/usergroup/${groupId}/CompaniesWithoutPermissions`;\r\n const config = {\r\n params: {\r\n pageNumber: pageNumber,\r\n pageSize: pageSize,\r\n companyNameFilter: companyNameFilter\r\n }\r\n };\r\n\r\n return this.http.post(serviceUrl, excludeCompanyIds, config);\r\n }\r\n\r\n getCompaniesThatAreMissingPermissionsForUser(userId: string, pageNumber: number, pageSize: number, companyNameFilter, excludeCompanyIds: any): Promise {\r\n if (!pageNumber) pageNumber = 1;\r\n if (!pageSize) pageSize = 100;\r\n if (!companyNameFilter || !companyNameFilter.length) companyNameFilter = null;\r\n if (!excludeCompanyIds) excludeCompanyIds = [];\r\n\r\n const serviceUrl = `/api/user/${userId}/CompaniesWithoutPermissions`;\r\n\r\n const config = {\r\n params: {\r\n pageNumber: pageNumber,\r\n pageSize: pageSize,\r\n companyNameFilter: companyNameFilter\r\n }\r\n };\r\n\r\n return this.http.post(serviceUrl, excludeCompanyIds, config);\r\n }\r\n\r\n getForGroup(groupId, pageNumber: number, pageSize: number, companyNameFilter): Promise {\r\n if (!pageNumber) pageNumber = 1;\r\n if (!pageSize) pageSize = 100;\r\n if (!companyNameFilter || !companyNameFilter.length) companyNameFilter = null;\r\n\r\n const serviceUrl = `/api/usergroup/${groupId}/AccessibleCompanies`;\r\n\r\n const config = {\r\n params: {\r\n pageNumber: pageNumber,\r\n pageSize: pageSize,\r\n companyNameFilter: companyNameFilter\r\n }\r\n };\r\n return this.http.get(serviceUrl, config);\r\n }\r\n\r\n getForUser(userId, pageNumber?: number, pageSize?: number, companyNameFilter?): Promise {\r\n if (!pageNumber) pageNumber = 1;\r\n if (!pageSize) pageSize = 100;\r\n if (!companyNameFilter || !companyNameFilter.length) companyNameFilter = null;\r\n\r\n const serviceUrl = `/api/user/${userId}/AccessibleCompanies`;\r\n\r\n const config = {\r\n params: {\r\n pageNumber: pageNumber,\r\n pageSize: pageSize,\r\n companyNameFilter: companyNameFilter\r\n }\r\n };\r\n return this.http.get(serviceUrl, config);\r\n }\r\n}","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from 'src/app/Common/Routing/sd-http.service';\r\n\r\n@Injectable()\r\nexport class ApplicationPermissionService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n readonly SERVICE_URL = '/api/user/role/';\r\n\r\n get(): Promise {\r\n return this.http.get(this.SERVICE_URL);\r\n }\r\n\r\n getByContactId(contactId: number): Promise {\r\n return this.http.get(`${this.SERVICE_URL}${contactId}`);\r\n }\r\n\r\n getByContactIdScoped(contactId: number): Promise {\r\n return this.http.get(`${this.SERVICE_URL}${contactId}/scoped`);\r\n }\r\n\r\n getByGroupId(id): Promise {\r\n return this.http.get(`/api/usergroup/${id}/roles`);\r\n }\r\n\r\n}","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\nimport { ContactsUpgradeService } from '../Contact/contacts.service.upgrade';\r\nimport { InstancePermissionService } from '../Permission/Instance/Instance.Permission.Service';\r\nimport { UserGroupService } from '../User-Group/user-group-service.upgrade';\r\nimport { CompanyPermissionsService } from '../Permission/Company/companyPermissions.service';\r\nimport { ApplicationPermissionService } from '../Permission/Application/applicationPermission.service';\r\n\r\n@Injectable()\r\nexport class UserSetupService {\r\n constructor(private http: SDHttpService,\r\n private contactsService: ContactsUpgradeService,\r\n private instancePermissionService: InstancePermissionService,\r\n private userGroupService: UserGroupService,\r\n private companyPermissionService: CompanyPermissionsService,\r\n private applicationPermissionService: ApplicationPermissionService) {}\r\n\r\n getUserData(userId: string, contactId: number): Promise {\r\n const user = this.contactsService.getForSetup(contactId);\r\n const applicationPermissions = this.applicationPermissionService.getByContactId(contactId);\r\n const instancePermissions = this.instancePermissionService.getByContactId(contactId);\r\n const userGroups = this.userGroupService.getForSetup(contactId);\r\n const companyPermissions = this.companyPermissionService.getForUser(userId);\r\n\r\n const promises = [user, applicationPermissions, companyPermissions, userGroups, instancePermissions];\r\n return this._getData(promises);\r\n }\r\n\r\n getUserDataScoped(userId: string, contactId: number): Promise {\r\n const user = this.contactsService.getForSetupScoped(contactId);\r\n const applicationPermissions = this.applicationPermissionService.getByContactIdScoped(contactId);\r\n const instancePermissions = this.instancePermissionService.getByContactId(contactId);\r\n const userGroups = this.userGroupService.getForSetup(contactId);\r\n const companyPermissions = this.companyPermissionService.getForUser(userId);\r\n const promises = [user, applicationPermissions, companyPermissions, userGroups, instancePermissions];\r\n\r\n return this._getData(promises);\r\n }\r\n\r\n\r\n getSSODomains(contactID: number): Promise {\r\n return this.http.get(`/api/sso-integration/domains/${contactID}`);\r\n }\r\n\r\n isIAMAdmin(): Promise {\r\n return this.http.get('/api/permission/IAMAdminCheck');\r\n }\r\n\r\n private async _getData(promises: Promise[]): Promise {\r\n return Promise.all(promises)\r\n .then(([user, roles, permissions, userToGroup, instancePermissions]) => {\r\n user.roles = roles;\r\n user.permissions = permissions;\r\n user.userToGroup = userToGroup;\r\n user.instancePermissions = instancePermissions;\r\n return user;\r\n });\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { SignaturePanelComponent } from './Signature/signature-panel.component';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { ImageCropperModule } from 'ngx-image-cropper';\r\nimport { UserSetupService } from './userSetup.service';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n WeissmanSharedModule,\r\n ImageCropperModule\r\n ],\r\n declarations: [\r\n SignaturePanelComponent\r\n ],\r\n providers: [\r\n UserSetupService\r\n ],\r\n exports: [SignaturePanelComponent]\r\n})\r\nexport class UserModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('signaturePanel', SignaturePanelComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('sd.User.Setup.Service', UserSetupService);\r\n }\r\n}","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { ContactListPageComponent } from './Page/contactListPage.component';\r\nimport { ContactPanelUpgradeDirective } from './Panel/contact.panel.upgrade.component';\r\nimport { ContactPanelComponent } from './Panel/contactPanel.component';\r\nimport { ContactListComponent } from './Panel/List/contactList.component';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { UserModule } from '../User/user.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { ContactsRepository } from '../Core-Repositories';\r\nimport { ContactPanelBodyActionsComponent } from './Panel/Body-Actions/panelBodyActions.component';\r\nimport { ContactListModalComponent } from './Panel/List/Associate-Contact/contactListModal.component';\r\nimport { EditRoleModalComponent } from './Panel/List/Edit-Role/editRoleModal.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n WeissmanSharedModule,\r\n TabsModule,\r\n UserModule\r\n ],\r\n declarations: [\r\n ContactPanelComponent,\r\n ContactPanelUpgradeDirective,\r\n ContactListComponent,\r\n ContactListModalComponent,\r\n ContactListPageComponent,\r\n ContactPanelBodyActionsComponent,\r\n EditRoleModalComponent,\r\n ],\r\n providers: [\r\n ContactsRepository\r\n ],\r\n exports: [\r\n ContactPanelComponent,\r\n ContactListPageComponent\r\n ]\r\n})\r\nexport class ContactModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('sdContactsPanel', ContactPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Component('sdEntityContactList', ContactListModalComponent);\r\n hybridAdapterUtility.downgradeNg2Component('contactListPage', ContactListPageComponent);\r\n }\r\n}\r\n","
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
    \r\n
  • \r\n
    \r\n \r\n
    \r\n \r\n
  • \r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n","import { Component, ElementRef, Input, OnInit, ViewChild } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { DescriptorHelperService } from './descriptor.helper.service';\r\nimport { DescriptorPicklistService } from './descriptor.picklist.service';\r\nimport { TimerService } from '../UI-Lib/Utilities/timer.service';\r\n\r\nexport enum DescriptorFieldTypes {\r\n Text = 2,\r\n Number = 3,\r\n Date = 4,\r\n Picklist = 5,\r\n YesNo = 6,\r\n Currency = 7\r\n}\r\n\r\n@Component({\r\n selector: 'descriptor-validation',\r\n templateUrl: './descriptor.validation.component.html'\r\n})\r\nexport class DescriptorValidationComponent implements OnInit {\r\n constructor(private readonly _picklistService: DescriptorPicklistService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _helperService: DescriptorHelperService,\r\n private readonly _timer: TimerService) { }\r\n\r\n @Input() descriptor: Core.DescriptorDTO;\r\n @ViewChild('itemToAdd') itemToAdd: ElementRef;\r\n canLimitToList: boolean = false;\r\n picklist: Weissman.Model.Descriptors.DescriptorPickList[];\r\n formats: Weissman.Model.Descriptors.DescriptorFormat[];\r\n FieldTypes = DescriptorFieldTypes;\r\n picklistLoading: boolean = false;\r\n picklistSaving: boolean = false;\r\n itemToAddText: string = '';\r\n addingItem: boolean = false;\r\n\r\n async ngOnInit() {\r\n this.descriptor.validation = this.descriptor.validation || {} as Core.DescriptorValidationDTO;\r\n\r\n if (this.descriptor.pickListGroupID) {\r\n this.picklistLoading = true;\r\n this.canLimitToList = await this._picklistService.canLimitToList(this.descriptor.descriptorID, this.descriptor.pickListGroupID);\r\n const picklist = await this._picklistService.getByPicklistGroupId(this.descriptor.pickListGroupID);\r\n this.picklist = _.sortBy(picklist, 'name');\r\n this.picklistLoading = false;\r\n }\r\n\r\n if(this.descriptor.fieldTypeID == Core.DescriptorFieldTypes.Number) {\r\n this.formats = await this._helperService.getFormats();\r\n }\r\n }\r\n\r\n async savePicklistItem(item: Weissman.Model.Descriptors.DescriptorPickList): Promise {\r\n this.picklistSaving = true;\r\n await this._picklistService.updateItem(item);\r\n this.picklistSaving = false;\r\n }\r\n\r\n async deletePicklistItem(item: Weissman.Model.Descriptors.DescriptorPickList): Promise {\r\n const result = await this._picklistService.deleteItemById(item.descriptorPickListID);\r\n\r\n if (result) {\r\n item.disabled = true;\r\n } else {\r\n _.remove(this.picklist, item);\r\n }\r\n }\r\n\r\n showPicklistItemInput(): void {\r\n this.addingItem = true;\r\n\r\n this._timer.setTimeout(() => this.itemToAdd.nativeElement.focus());\r\n }\r\n\r\n async addPicklistItem(): Promise {\r\n if(!_.trim(this.itemToAddText)) {\r\n this._toastr.error('Picklist item must not be empty!');\r\n return;\r\n }\r\n\r\n const picklistItemToAdd = {\r\n disabled: false,\r\n name: this.itemToAddText,\r\n groupID: this.descriptor.pickListGroupID || 0\r\n } as Weissman.Model.Descriptors.DescriptorPickList;\r\n\r\n this.picklistSaving = true;\r\n const result = await this._picklistService.createItem(picklistItemToAdd);\r\n\r\n this.descriptor.pickListGroupID = this.descriptor.pickListGroupID || result.groupID;\r\n\r\n this.picklist = this.picklist || [];\r\n this.picklist.push(result);\r\n this.itemToAddText = '';\r\n this.addingItem = false;\r\n this.picklistSaving = false;\r\n }\r\n\r\n}\r\n","
\r\n
\r\n

Property Characteristics

\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
(columns.length - 2)\">{{column}}
{{descriptor.name}}{{getDescriptorUsage(descriptor.companyUsageId)}}{{getDescriptorUsage(descriptor.siteUsageID)}}{{getDescriptorUsage(descriptor.parcelUsageID)}}{{getDescriptorUsage(descriptor.assessorUsageID)}}{{getAssetDescriptorUsage(descriptor.assetUsageID)}}{{getARCCDescriptorUsage(descriptor.arccUsageId)}}\r\n {{getDescriptorFieldType(descriptor.fieldTypeID)}}\r\n (Values...)\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n

Picklist Items

\r\n \r\n
\r\n
\r\n
    \r\n
  • {{item.name}}
  • \r\n
\r\n Empty\r\n
\r\n
\r\n
\r\n
\r\n","import { ElementRef, QueryList, ViewChild, ViewChildren } from '@angular/core';\r\nimport { Component, OnInit } from '@angular/core';\r\nimport { ModalDirective } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { MessageBoxButtons, MessageBoxResult, MessageBoxService } from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { InstanceRights, Roles, RestrictService } from '../Common/Permissions/restrict.service';\r\nimport { NavigationService } from '../Layout/navigation.service';\r\nimport { DescriptorHelperService } from './descriptor.helper.service';\r\nimport { DescriptorPicklistService } from './descriptor.picklist.service';\r\nimport { DescriptorService } from './descriptor.service';\r\nimport { TimerService } from '../UI-Lib/Utilities';\r\n\r\nimport * as _ from 'lodash';\r\nimport { UserInstanceService } from '../User/userInstance.service';\r\n\r\nconst warningMessage = 'Editing is in progress. Are you sure you want to leave?';\r\nenum DescriptorFieldTypes {\r\n Picklist = Core.DescriptorFieldTypes.Picklist as number\r\n}\r\n\r\n@Component({\r\n selector: 'property-characteristics',\r\n templateUrl: './property.characteristics.component.html',\r\n styleUrls: ['./property.characteristics.component.scss']\r\n})\r\nexport class PropertyCharacteristicsComponent implements OnInit {\r\n constructor(\r\n private readonly _descriptorHelperService: DescriptorHelperService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _descriptorService: DescriptorService,\r\n private readonly _toastrService: ToastrService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _descriptorPicklistService: DescriptorPicklistService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _timer: TimerService,\r\n private readonly _userInstanceService: UserInstanceService,){}\r\n\r\n @ViewChildren('formRow') rows: QueryList;\r\n @ViewChild('picklistValuesModal', { static: true }) picklistValuesModal: ModalDirective;\r\n dataLoading: boolean = false;\r\n descriptorIsSaving: boolean = false;\r\n canEdit: boolean = false;\r\n hasComplianceFeatures: boolean = false;\r\n selectedCategoryId: Core.DescriptorCategoryEnum;\r\n descriptors: Core.DescriptorDTO[];\r\n descriptorToEdit: Core.DescriptorDTO;\r\n categories: Weissman.Model.Descriptors.DescriptorCategory[];\r\n usages: Weissman.Model.Descriptors.DescriptorUsage[];\r\n fieldTypes: Weissman.Model.Descriptors.DescriptorFieldType[];\r\n assetUsages: any[];\r\n aRCCUsages: any[];\r\n columns: string[];\r\n picklist: Core.DescriptorPickListModel[];\r\n FieldTypeEnum: typeof DescriptorFieldTypes = DescriptorFieldTypes;\r\n deletingDescriptorId: number;\r\n isRyanInstance: boolean;\r\n\r\n\r\n async ngOnInit(): Promise {\r\n this.dataLoading = true;\r\n this.isRyanInstance = this._userInstanceService.RyanInstanceId == this._userInstanceService.getSelectedInstance().instanceId;\r\n\r\n try {\r\n this.canEdit = this._restrictService.isInRole(Roles.PROPCHAREDIT);\r\n this.hasComplianceFeatures = this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW);\r\n\r\n this.columns = this._descriptorHelperService.getSetup();\r\n if (!this.isRyanInstance) {\r\n const arccUsageColumnId = this.columns.findIndex(x => x === 'ARCC Usage');\r\n this.columns.splice(arccUsageColumnId, 1);\r\n }\r\n\r\n const categories = await this._descriptorHelperService.getCategories();\r\n this.categories = _.sortBy(categories, 'name');\r\n this.selectedCategoryId = this.categories[0].descriptorCategoryID;\r\n\r\n if (!this.hasComplianceFeatures) {\r\n this.categories = _.reject(this.categories, x => _.startsWith(x.name, 'Asset'));\r\n this.columns.splice(this.columns.indexOf('Asset Usage'), 1);\r\n }\r\n\r\n this.fieldTypes = await this._descriptorHelperService.getFieldTypes();\r\n this.usages = await this._descriptorHelperService.getUsages();\r\n\r\n // override the select values for assets\r\n this.assetUsages = JSON.parse(JSON.stringify(this.usages));\r\n this.assetUsages = _.map(this.assetUsages,\r\n usage => {\r\n if (usage.name === 'Frequent') {\r\n usage.name = 'Required';\r\n } else if (usage.name === 'Occasional') {\r\n usage.name = 'Optional';\r\n }\r\n\r\n return usage;\r\n });\r\n\r\n this.aRCCUsages = JSON.parse(JSON.stringify(this.usages));\r\n this.aRCCUsages = this.aRCCUsages\r\n .filter(x => x.descriptorUsageID !== 2)\r\n .map(x => {\r\n x.name = x.descriptorUsageID === 1 ? 'Yes' : 'No';\r\n return x;\r\n });\r\n\r\n await this._loadDescriptors();\r\n } finally {\r\n this.dataLoading = false;\r\n }\r\n }\r\n\r\n async getDescriptors(): Promise {\r\n this.dataLoading = true;\r\n\r\n try {\r\n await this._loadDescriptors();\r\n } finally {\r\n this.dataLoading = false;\r\n }\r\n }\r\n\r\n getDescriptorUsage(id: number): string {\r\n const usage = _.find(this.usages, { descriptorUsageID: id });\r\n return usage ? usage.name : '';\r\n }\r\n\r\n getAssetDescriptorUsage(id: number): string {\r\n const assetUsage = _.find(this.assetUsages, { descriptorUsageID: id });\r\n return assetUsage ? assetUsage.name : '';\r\n }\r\n\r\n getARCCDescriptorUsage(id: number): string {\r\n const usage = _.find(this.aRCCUsages, { descriptorUsageID: id });\r\n return usage ? usage.name : '';\r\n }\r\n\r\n getDescriptorFieldType(id: number): string {\r\n const fieldType = _.find(this.fieldTypes, { descriptorFieldTypeID: id });\r\n return fieldType ? fieldType.name : '';\r\n }\r\n\r\n editDescriptor(descriptor: Core.DescriptorDTO): void {\r\n this.descriptorToEdit = _.cloneDeep(descriptor);\r\n this._navigationService.enableNavWarning(warningMessage);\r\n }\r\n\r\n cancelEdit(descriptor: Core.DescriptorDTO): void {\r\n if (!descriptor.descriptorID) {\r\n this.descriptors.pop();\r\n }\r\n\r\n this.descriptorToEdit = undefined;\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n addDescriptor(): void {\r\n const newDescriptor = {\r\n assetUsageID: Core.DescriptorUsageEnum.Never,\r\n assessorUsageID: Core.DescriptorUsageEnum.Never,\r\n collectorUsageID: Core.DescriptorUsageEnum.Never,\r\n siteUsageID: Core.DescriptorUsageEnum.Never,\r\n parcelUsageID: Core.DescriptorUsageEnum.Never,\r\n companyUsageId: Core.DescriptorUsageEnum.Never,\r\n arccUsageId: Core.DescriptorUsageEnum.Never,\r\n categoryID: this.selectedCategoryId,\r\n fieldTypeID: Core.DescriptorFieldTypes.Number,\r\n formatID: 1,\r\n pickListGroupID: null,\r\n enabled: true,\r\n sequenceNumber: _.get(_.maxBy(this.descriptors, 'sequenceNumber'), 'sequenceNumber', 0) + 1\r\n } as Core.DescriptorDTO;\r\n\r\n this.descriptors.push(newDescriptor);\r\n this.editDescriptor(newDescriptor);\r\n\r\n this._timer.setTimeout(() => this.rows.last.nativeElement.children[0].children[0].focus());\r\n }\r\n\r\n async saveDescriptor(idx: number): Promise {\r\n const message = this._getValidationError();\r\n\r\n if(message) {\r\n this._toastrService.error(message);\r\n return Promise.resolve();\r\n }\r\n\r\n this.descriptorIsSaving = true;\r\n\r\n try {\r\n if (this.descriptorToEdit.descriptorID) {\r\n await this._descriptorService.update(this.descriptorToEdit);\r\n this.descriptors[idx] = this.descriptorToEdit;\r\n } else {\r\n this.descriptors[idx] = await this._descriptorService.create(this.descriptorToEdit);\r\n }\r\n\r\n this.descriptorToEdit = undefined;\r\n this._navigationService.disableNavWarning();\r\n } finally {\r\n this.descriptorIsSaving = false;\r\n }\r\n }\r\n\r\n async deleteDescriptor(descriptor: Core.DescriptorDTO): Promise {\r\n const result: number = await this._messageBoxService.open({\r\n message: `Are you sure you want to delete ${descriptor.name}?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (result === MessageBoxResult.OK) {\r\n this.deletingDescriptorId = descriptor.descriptorID;\r\n\r\n try {\r\n const deleteResult = await this._descriptorService.deleteById(descriptor.descriptorID);\r\n\r\n if(deleteResult) {\r\n descriptor.enabled = false;\r\n } else {\r\n _.remove(this.descriptors, descriptor);\r\n }\r\n } finally {\r\n this.deletingDescriptorId = undefined;\r\n }\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async showPicklistValuesModal(descriptor: Core.DescriptorDTO): Promise {\r\n if(descriptor.pickListGroupID) {\r\n const picklist = await this._descriptorPicklistService.getByPicklistGroupId(descriptor.pickListGroupID);\r\n this.picklist = _.sortBy(picklist, 'name');\r\n }\r\n\r\n this.picklistValuesModal.show();\r\n }\r\n\r\n shouldDisableEditButtons(descriptor: Core.DescriptorDTO): boolean {\r\n return descriptor.isSystemControlled || descriptor.descriptorID === this.deletingDescriptorId || !!this.descriptorToEdit;\r\n }\r\n\r\n get canSaveDescriptor(): boolean {\r\n return !!this.descriptorToEdit.name && !!this.descriptorToEdit.companyUsageId && !!this.descriptorToEdit.siteUsageID &&\r\n !!this.descriptorToEdit.parcelUsageID && !!this.descriptorToEdit.assessorUsageID && !!this.descriptorToEdit.assetUsageID;\r\n }\r\n\r\n private async _loadDescriptors(): Promise {\r\n const descriptors = await this._descriptorService.getByCategoryId(this.selectedCategoryId);\r\n this.descriptors = _.chain(descriptors)\r\n .map(x => {\r\n x.formatID = x.formatID || 1;\r\n return x;\r\n })\r\n .sortBy('name')\r\n .value();\r\n }\r\n\r\n private _getValidationError(): string {\r\n if(this.descriptorToEdit.validation.maxValue\r\n && this.descriptorToEdit.validation.minValue\r\n && this.descriptorToEdit.validation.maxValue < this.descriptorToEdit.validation.minValue) {\r\n return 'Min Value must be less than Max!';\r\n }\r\n\r\n if(this.descriptorToEdit.validation.maxValue < 0\r\n || this.descriptorToEdit.validation.minValue < 0\r\n || this.descriptorToEdit.validation.maxLength < 0) {\r\n return 'Value cannot be negative!';\r\n }\r\n\r\n return '';\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DescriptorPickerComponent } from './descriptor.picker.component';\r\nimport { DescriptorService } from './descriptor.service';\r\nimport { DescriptorPicklistService } from './descriptor.picklist.service';\r\nimport { DescriptorHelperService } from './descriptor.helper.service';\r\nimport { PropertyCharacteristicsPickerComponent } from './Picker/property.characteristics.picker.component';\r\nimport { PropertyCharacteristicsComponent } from './property.characteristics.component';\r\nimport { DescriptorValidationComponent } from './descriptor.validation.component';\r\nimport { DescriptorOverridesService } from './descriptor.overrides.service';\r\nimport { PropertyCharacteristicsOverridesComponent } from './property.characteristics.overrides.component';\r\nimport { EntityPropertyCharacteristicsComponent } from './Entity-Property-Characteristics/entity.property.characteristics.component';\r\nimport { EntityPropertyCharacteristicsInputComponent } from './Entity-Property-Characteristics/Characteristic-Input/entity.property.characteristics.input.component';\r\nimport { EntityPropertyCharacteristicsService } from './Entity-Property-Characteristics/entity.property.characteristics.service';\r\nimport { EntityPropertyCharacteristicsListComponent } from './Entity-Property-Characteristics/entity.property.characteristics.list.component';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n WeissmanSharedModule\r\n ],\r\n declarations: [\r\n DescriptorPickerComponent,\r\n PropertyCharacteristicsComponent,\r\n DescriptorValidationComponent,\r\n PropertyCharacteristicsPickerComponent,\r\n PropertyCharacteristicsOverridesComponent,\r\n EntityPropertyCharacteristicsComponent,\r\n EntityPropertyCharacteristicsInputComponent,\r\n EntityPropertyCharacteristicsListComponent\r\n ],\r\n providers: [\r\n DescriptorPicklistService,\r\n DescriptorHelperService,\r\n DescriptorOverridesService,\r\n EntityPropertyCharacteristicsService\r\n ],\r\n exports: [\r\n DescriptorPickerComponent,\r\n PropertyCharacteristicsComponent,\r\n PropertyCharacteristicsOverridesComponent,\r\n EntityPropertyCharacteristicsComponent,\r\n EntityPropertyCharacteristicsInputComponent\r\n ]\r\n})\r\nexport class PropertyCharacteristicsModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('descriptorPicker', DescriptorPickerComponent);\r\n hybridAdapterUtility.downgradeNg2Component('propertyCharacteristics', PropertyCharacteristicsComponent);\r\n hybridAdapterUtility.downgradeNg2Component('propertyCharacteristicsOverrides', PropertyCharacteristicsOverridesComponent);\r\n hybridAdapterUtility.downgradeNg2Component('entityPropertyCharacteristics', EntityPropertyCharacteristicsComponent);\r\n\r\n hybridAdapterUtility.downgradeNg2Provider('DescriptorService', DescriptorService);\r\n hybridAdapterUtility.downgradeNg2Provider('descriptorHelperService', DescriptorHelperService);\r\n hybridAdapterUtility.downgradeNg2Provider('DescriptorPicklistService', DescriptorPicklistService);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { ProcessingModule } from '../../Processing/processing.module';\r\nimport { CompanySettingsComponent } from './Company-Settings/companySettings.component';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { AccountingPeriodsLinkComponent } from './Company-Settings/Accounting-Periods/accounting.periods.link.component';\r\nimport { StepProgressIndicatorModule } from '../../Common/Step-Progress-Indicator/stepProgressIndicator.module';\r\nimport { AccrualsDescriptorsLinkComponent } from './Company-Settings/Accruals-Descriptors/accruals.descriptors.link.component';\r\nimport { AccrualsDescriptorsModalComponent } from './Company-Settings/Accruals-Descriptors/accruals.descriptors.modal.component';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { CompanyComplianceComponent } from './Company-Compliance/companyCompliance.component';\r\nimport { CompanyPickerComponent } from './Company.Picker.Component';\r\nimport { CompanyService } from './company.service';\r\nimport { AccrualsDescriptorSelectorComponent } from './Company-Settings/Accruals-Descriptors/accruals.descriptor.selector.component';\r\nimport { VendorCodeModule } from './Vendor-Codes/vendorCode.module';\r\nimport { CompanyExplorationComponent } from './Exploration/companyExploration.component';\r\nimport { AddSiteModalComponent } from './Exploration/addSiteModal.component';\r\nimport { AddCompanyModalComponent } from './Add/addCompanyModal.component';\r\nimport { LaunchAddCompanyModalService } from './Add/launchAddCompanyModal.service';\r\nimport { CompanyInfoPanelComponent } from './Info/companyInfoPanel.component';\r\nimport { CompanyInfoPanelViewComponent } from './Info/companyInfoPanelView.component';\r\nimport { CompanyInfoPanelEditComponent } from './Info/companyInfoPanelEdit.component';\r\nimport { CompanyPageComponent } from './companyPage.component';\r\nimport { ClientServicesModule } from 'src/app/Client-Services/client-services.module';\r\nimport { ComplianceCompanyModule } from 'src/app/Compliance/Company/company.module';\r\nimport { ContactModule } from 'src/app/Contact/contact.module';\r\nimport { BusyIndicatorModule } from 'src/app/Busy-Indicator';\r\nimport { PropertyCharacteristicsModule } from '../../Property-Characteristics/propertyCharacteristics.module';\r\nimport { BudgetDescriptorsLinkComponent } from './Company-Settings/Budget-Descriptors/budget.descriptors.link.component';\r\nimport { BudgetDescriptorsModalComponent } from './Company-Settings/Budget-Descriptors/budget.descriptors.modal.component';\r\nimport { BudgetDescriptorSelectorComponent } from './Company-Settings/Budget-Descriptors/budget.descriptor.selector.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n StepProgressIndicatorModule,\r\n TypeaheadModule,\r\n VendorCodeModule,\r\n ClientServicesModule,\r\n ComplianceCompanyModule,\r\n ContactModule,\r\n BusyIndicatorModule,\r\n PropertyCharacteristicsModule,\r\n ProcessingModule\r\n ],\r\n declarations: [\r\n CompanySettingsComponent,\r\n AccountingPeriodsLinkComponent,\r\n AccrualsDescriptorsLinkComponent,\r\n AccrualsDescriptorsModalComponent,\r\n CompanyComplianceComponent,\r\n AccrualsDescriptorSelectorComponent,\r\n CompanyExplorationComponent,\r\n AddSiteModalComponent,\r\n AddCompanyModalComponent,\r\n CompanyInfoPanelComponent,\r\n CompanyInfoPanelViewComponent,\r\n CompanyInfoPanelEditComponent,\r\n CompanyPageComponent,\r\n CompanyPickerComponent,\r\n BudgetDescriptorsLinkComponent,\r\n BudgetDescriptorsModalComponent,\r\n BudgetDescriptorSelectorComponent,\r\n ],\r\n providers: [CompanyService, LaunchAddCompanyModalService],\r\n exports: [\r\n CompanySettingsComponent,\r\n CompanyPickerComponent\r\n ]\r\n})\r\nexport class CompanyModule {\r\n static setupModule(): void {\r\n VendorCodeModule.setupModule();\r\n\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('companySettings', CompanySettingsComponent);\r\n hybridAdapterUtility.downgradeNg2Component('companyCompliance', CompanyComplianceComponent);\r\n hybridAdapterUtility.downgradeNg2Component('companyExploration', CompanyExplorationComponent);\r\n hybridAdapterUtility.downgradeNg2Component('companyInfoPanel', CompanyInfoPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Component('companyPage', CompanyPageComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('sd.Company.Service', CompanyService);\r\n hybridAdapterUtility.downgradeNg2Provider('launchAddCompanyModalService', LaunchAddCompanyModalService);\r\n }\r\n}\r\n","
\r\n \r\n\r\n
\r\n \r\n \r\n

\r\n Instance name is required\r\n

\r\n
\r\n
\r\n \r\n \r\n

\r\n Instance type is required\r\n

\r\n
\r\n
\r\n \r\n \r\n

\r\n Company name is required\r\n

\r\n
\r\n
\r\n \r\n \r\n

\r\n Company code is required\r\n

\r\n
\r\n
\r\n \r\n \r\n

\r\n Team name is required\r\n

\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { UntypedFormGroup, Validators, UntypedFormBuilder } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { InstanceRepository } from '../instance.repository';\r\nimport { distinctUntilChanged, takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'add-instance-modal',\r\n templateUrl: './addInstanceModal.component.html'\r\n})\r\nexport class AddInstanceModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private _toastrService: ToastrService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: any;\r\n result: any;\r\n\r\n instanceForm: UntypedFormGroup;\r\n instanceTypes: Core.InstanceTypeModel[];\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n private _previousInstanceName: string = '';\r\n\r\n async ngOnInit(): Promise {\r\n this.instanceForm = this._fb.group({\r\n instanceName: [null, Validators.required],\r\n instanceType: [null, Validators.required],\r\n companyName: [null, Validators.required],\r\n companyCode: [null, Validators.maxLength(50)],\r\n teamName: [null, Validators.required]\r\n });\r\n\r\n this.instanceForm.get('instanceName').valueChanges\r\n .pipe(takeUntil(this._destroy$))\r\n .pipe(distinctUntilChanged())\r\n .subscribe((value) => this._instanceNameChanged(value));\r\n\r\n this.instanceTypes = await this._instanceRepository.getInstanceTypes();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async addInstance(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Creating New Instance' });\r\n const { instanceName, instanceType, companyName, companyCode, teamName } = this.instanceForm.value;\r\n\r\n const model = {\r\n instanceName: instanceName,\r\n instanceTypeId: instanceType,\r\n companyName: companyName,\r\n companyCode: companyCode,\r\n teamName: teamName\r\n };\r\n\r\n const isNameInUse = await lastValueFrom(this._instanceRepository.isInstanceNameInUse({instanceName: model.instanceName, instanceId: -1}));\r\n if(isNameInUse == true) {\r\n await busyRef.hide();\r\n this._toastrService.error(`Instance name ${model.instanceName} is already in use`);\r\n }\r\n else {\r\n try {\r\n this.result = await lastValueFrom(this._instanceRepository.create(model));\r\n this._toastrService.success(`New Instance ${model.instanceName} was created successfully. You will need to logout and log back in to see it`);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n this.cancel();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _instanceNameChanged(value: string) {\r\n const currentTeamName = this.instanceForm.get('teamName').value;\r\n\r\n if (!currentTeamName || currentTeamName === `Team ${this._previousInstanceName}`) {\r\n this.instanceForm.get('teamName').setValue(value ? `Team ${value}` : '');\r\n }\r\n\r\n this._previousInstanceName = value;\r\n }\r\n}\r\n","
\r\n
\r\n

{{ slides[currentSlide].title }}

\r\n
\r\n \r\n \r\n
\r\n \"slide\"\r\n\r\n
\r\n \r\n \r\n
\r\n

{{ slides[currentSlide].description }}

\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Prev\r\n \r\n \r\n Next\r\n \r\n
\r\n
\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\n\r\nexport interface Slide {\r\n title?: string;\r\n description?: string;\r\n imageUrl: string;\r\n}\r\n\r\n@Component({\r\n selector: 'ws-carousel',\r\n templateUrl: './carousel.component.html',\r\n styleUrls: ['./carousel.component.scss']\r\n})\r\nexport class CarouselComponent {\r\n @Input() slides: Slide[] = [];\r\n @Input() imgHeight: number = 600;\r\n @Input() imgWidth: number = 800;\r\n @Input() currentSlide: number = 0;\r\n @Input() disableControls: boolean = false;\r\n\r\n @Output() currentSlideChange: EventEmitter = new EventEmitter();\r\n\r\n goToSlide(index: number): void {\r\n this.currentSlide = index;\r\n this.currentSlideChange.emit(this.currentSlide);\r\n }\r\n\r\n nextSlide() {\r\n this.currentSlide = (this.currentSlide + 1) % this.slides.length;\r\n this.currentSlideChange.emit(this.currentSlide);\r\n }\r\n\r\n prevSlide() {\r\n this.currentSlide = (this.currentSlide - 1 + this.slides.length) % this.slides.length;\r\n this.currentSlideChange.emit(this.currentSlide);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UserService } from '../../Account/user.service';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { Slide } from '../../UI-Lib/Carousel/carousel.component';\r\nimport { AccountService } from '../../User/account.service';\r\nimport { TopNavService } from '../Top-Nav/topNav.service';\r\n\r\n@Component({\r\n selector: 'nav-onboarding',\r\n templateUrl: './navOnboarding.component.html'\r\n})\r\nexport class NavOnboardingComponent implements IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _topNavService: TopNavService,\r\n private readonly _accountService: AccountService,\r\n private readonly _userService: UserService) {}\r\n\r\n params: void;\r\n result: void;\r\n\r\n slides: Slide[] = [\r\n { imageUrl: '/images/onboarding/1.svg' },\r\n { imageUrl: '/images/onboarding/2.svg' },\r\n { imageUrl: '/images/onboarding/3.svg' }\r\n ];\r\n currentSlide: number = 0;\r\n\r\n get progressBtnLabel(): string {\r\n return this.currentSlide === this.slides.length - 1 ? 'FINISH' : 'NEXT';\r\n }\r\n\r\n progress(): void {\r\n if (this.currentSlide < this.slides.length - 1) {\r\n this.currentSlide++;\r\n } else {\r\n this.cancel();\r\n }\r\n }\r\n\r\n async cancel(fromHashChange: boolean = false): Promise {\r\n if (fromHashChange) {\r\n return;\r\n }\r\n if (this._userService.getUser().onboardingStatus === Core.UserOnboardingStatusEnum.NoAction) {\r\n await this._accountService.updateOnboardingStatus(Core.UserOnboardingStatusEnum.Completed);\r\n }\r\n this._topNavService.showOnboardingBanner();\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\n \r\n \r\n\r\n","import { Component } from '@angular/core';\r\nimport { TopNavService } from '../Top-Nav/topNav.service';\r\n\r\n@Component({\r\n selector: 'onboarding-banner',\r\n template: 'There have been updates to the interface and navigation, click to learn more.'\r\n})\r\nexport class OnboardingBannerComponent {\r\n constructor(private readonly _topNavService: TopNavService) {\r\n }\r\n\r\n async openModal(): Promise {\r\n await this._topNavService.showOnboardingModal();\r\n }\r\n}\r\n","import { IPortalBrandingConfig } from '@ace/shared';\r\nimport { ComponentType } from '@angular/cdk/overlay';\r\nimport { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, Subject } from 'rxjs';\r\nimport { InstanceRights, RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { AccountService } from '../../User/account.service';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { NavOnboardingComponent } from '../Onboarding-Modal/navOnboarding.component';\r\nimport { OnboardingBannerComponent } from '../Onboarding-Modal/onboardingBanner.component';\r\n\r\nexport const branding: IPortalBrandingConfig = {\r\n logoTitle: 'PropertyPoint\\u00AE',\r\n footerPortalTitle: 'Tax.com Portal',\r\n footerPortalHref: 'https://tax.com',\r\n footerText: '\\u00A92024 Tax.com, a division of Ryan, LLC'\r\n};\r\n\r\nexport interface TopNavRoles {\r\n hasAddNewCompanyRole: boolean;\r\n hasAddNewInstanceRole: boolean;\r\n hasContactRoles: boolean;\r\n hasPropCharsRoles: boolean;\r\n hasContactRoleRoles: boolean;\r\n hasUserGroupViewOrEdit: boolean;\r\n hasUserGroupEdit: boolean;\r\n hasTeamViewOrEdit: boolean;\r\n hasEditRyanPrivatePermissions: boolean;\r\n hasViewRyanPrivatePermissions: boolean;\r\n hasComplianceSetupsView: boolean;\r\n hasComplianceSetupsEdit: boolean;\r\n hasValuationTemplateEdit: boolean;\r\n hasAdminOperationsEdit: boolean;\r\n hasAdminOperationsView: boolean;\r\n hasAllowDataImports: boolean;\r\n hasManageAPIKeys: boolean;\r\n hasAgentInfo: boolean;\r\n hasManageConsultingEngagements: boolean;\r\n hasLicensedDocumentServices: boolean;\r\n hasSupportRole: boolean;\r\n isSingleInstanceSelected: boolean;\r\n hasAdminRole: boolean;\r\n}\r\n\r\nexport interface BannerMessage {\r\n message: T;\r\n onDismiss: () => void;\r\n}\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class TopNavService {\r\n constructor(private readonly _restrictService: RestrictService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _weissmanModalService: WeissmanModalService,\r\n private readonly _accountService: AccountService) {\r\n }\r\n\r\n private readonly _sideNavOpen: BehaviorSubject = new BehaviorSubject(false);\r\n private readonly _sideNavOpen$ = this._sideNavOpen.asObservable();\r\n\r\n private readonly _bannerMessage: Subject>> = new Subject();\r\n private readonly _bannerMessage$: Observable>> = this._bannerMessage.asObservable();\r\n\r\n get sideNavOpen$() {\r\n return this._sideNavOpen$;\r\n }\r\n\r\n set sideNavOpen(value: boolean) {\r\n this._sideNavOpen.next(value);\r\n }\r\n\r\n set bannerMessage(message: BannerMessage>) {\r\n this._bannerMessage.next(message);\r\n }\r\n\r\n get bannerMessage$(): Observable>> {\r\n return this._bannerMessage$;\r\n }\r\n\r\n roles(): TopNavRoles {\r\n const hasManageAPIKeys = this._restrictService.isInRole(Roles.MANAGEAPIKEYS);\r\n const hasAdminOperationsView = this._restrictService.isInRole(Roles.ADMINOPERATIONSVIEW);\r\n const hasComplianceSetupsView = this._restrictService.isInRole(Roles.COMPLIANCESETUPSVIEW);\r\n const hasContactRoleRoles = !this._restrictService.isNotInRoles([Roles.CONTACTROLEVIEW]);\r\n const hasViewRyanPrivatePermissions = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n const hasUserGroupViewOrEdit = this._restrictService.hasInstanceRight(InstanceRights.MANAGEUSERSETUP);\r\n const hasPropCharsRoles = !this._restrictService.isNotInRoles([Roles.PROPCHARVIEW, Roles.PROPCHAREDIT]);\r\n const hasValuationTemplateEdit = this._restrictService.hasInstanceRight(InstanceRights.VALUATIONTEMPLATEEDIT);\r\n const hasComplianceFeatureView = this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW);\r\n const hasCompanyDataImportsView = this._restrictService.hasInstanceRight(InstanceRights.COMPANYDATAIMPORTSVIEW);\r\n const hasManageConsultingEngagements = this._restrictService.hasInstanceRight(InstanceRights.MANAGECONSULTINGENGAGEMENT);\r\n const hasContactRoles = !this._restrictService.hasNoInstanceRights([InstanceRights.CONTACTVIEW, InstanceRights.CONTACTEDIT]);\r\n const hasAgentInfo = !this._restrictService.hasNoInstanceRights([InstanceRights.AGENTINFORMATIONVIEW, InstanceRights.AGENTINFORMATIONEDIT]);\r\n const hasTeamViewOrEdit = this._restrictService.hasInstanceRight(InstanceRights.TEAMSETUPSVIEW)\r\n || this._restrictService.hasInstanceRight(InstanceRights.TEAMSETUPSEDIT);\r\n const hasAllowDataImports = this._userInstanceService.isSingleInstanceSelected()\r\n && (this._restrictService.isInRole(Roles.ALLOWDATAIMPORTS)\r\n || this._restrictService.hasInstanceRight(InstanceRights.INSTANCEDATAIMPORTS));\r\n\r\n return {\r\n hasAddNewCompanyRole: this._restrictService.hasInstanceRight(InstanceRights.ADDNEWCOMPANY),\r\n hasAddNewInstanceRole: this._restrictService.isInRole(Roles.INSTANCEADMIN),\r\n hasContactRoles,\r\n hasPropCharsRoles,\r\n hasContactRoleRoles,\r\n hasUserGroupViewOrEdit,\r\n hasUserGroupEdit: this._restrictService.hasInstanceRight(InstanceRights.MANAGEUSERSETUP),\r\n hasTeamViewOrEdit,\r\n hasEditRyanPrivatePermissions: this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT),\r\n hasViewRyanPrivatePermissions,\r\n hasComplianceSetupsView,\r\n hasComplianceSetupsEdit: this._restrictService.isInRole(Roles.COMPLIANCESETUPSEDIT),\r\n hasValuationTemplateEdit,\r\n hasAdminOperationsEdit: this._restrictService.isInRole(Roles.ADMINOPERATIONSEDIT),\r\n hasAdminOperationsView,\r\n hasAllowDataImports,\r\n hasManageAPIKeys,\r\n hasAgentInfo,\r\n hasManageConsultingEngagements,\r\n hasLicensedDocumentServices: this._restrictService.isInRole(Roles.LICENSEDDOCUMENTSERVICES),\r\n hasSupportRole: this._restrictService.isInRole(Roles.SUPPORT),\r\n isSingleInstanceSelected: this._userInstanceService.isSingleInstanceSelected(),\r\n\r\n hasAdminRole: hasContactRoles ||\r\n hasPropCharsRoles ||\r\n hasContactRoleRoles ||\r\n hasUserGroupViewOrEdit ||\r\n hasTeamViewOrEdit ||\r\n hasAllowDataImports ||\r\n hasComplianceFeatureView ||\r\n hasComplianceSetupsView ||\r\n hasValuationTemplateEdit ||\r\n hasCompanyDataImportsView ||\r\n hasAgentInfo ||\r\n hasAdminOperationsView ||\r\n hasViewRyanPrivatePermissions ||\r\n hasManageAPIKeys ||\r\n hasManageConsultingEngagements\r\n };\r\n }\r\n\r\n async showOnboardingModal(): Promise {\r\n return await this._weissmanModalService.showAsync(NavOnboardingComponent, null, 'modal-lg');\r\n }\r\n\r\n showOnboardingBanner(): void {\r\n this.bannerMessage = {\r\n message: OnboardingBannerComponent,\r\n onDismiss: async () => {\r\n await this._accountService.updateOnboardingStatus(Core.UserOnboardingStatusEnum.Dismissed);\r\n }\r\n } as BannerMessage>;\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n

Manage

\r\n \r\n \r\n
\r\n   Some features are only available if you have a\r\n single instance selected\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormControl } from '@angular/forms';\r\nimport { Ng2StateDeclaration, UIRouter } from '@uirouter/angular';\r\nimport { Subject } from 'rxjs';\r\nimport { distinctUntilChanged, takeUntil } from 'rxjs/operators';\r\nimport { ProductAnalyticsService } from '../Common/Amplitude/productAnalytics.service';\r\nimport { FeatureFlagsService } from '../Common/FeatureFlags/feature-flags-service';\r\nimport { InstanceRights, RestrictService, Roles } from '../Common/Permissions/restrict.service';\r\nimport { WeissmanModalService } from '../Compliance/WeissmanModalService';\r\nimport { LaunchAddCompanyModalService } from '../Entity/Company/Add/launchAddCompanyModal.service';\r\nimport { AddInstanceModalComponent } from '../Entity/Instance/Add/addInstanceModal.component';\r\nimport { InstanceRepository } from '../Entity/Instance/instance.repository';\r\nimport { TopNavRoles, TopNavService } from '../Navigation/Top-Nav/topNav.service';\r\nimport { UserInstanceService } from '../User/userInstance.service';\r\n\r\ninterface AdminOption {\r\n name: string;\r\n route: string;\r\n isShown: () => boolean;\r\n isDisabled?: () => boolean;\r\n amplitudeProperty?: { event: string, properties?: any };\r\n}\r\n\r\ninterface AdminGroup {\r\n group: string;\r\n items: AdminOption[];\r\n}\r\n\r\n@Component({\r\n selector: 'admin',\r\n templateUrl: './admin.component.html',\r\n styleUrls: ['./admin.component.scss']\r\n})\r\nexport class AdminComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _router: UIRouter,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _launchAddCompanyModalService: LaunchAddCompanyModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _topNavService: TopNavService,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {\r\n }\r\n\r\n adminControl: FormControl = new FormControl();\r\n adminOptions: AdminGroup[] = [];\r\n\r\n roles: TopNavRoles;\r\n\r\n hasAddNewCompanyRole: boolean;\r\n hasAddNewInstanceRole: boolean;\r\n isSingleInstanceSelected: boolean;\r\n showManageInstancesMenuItem: boolean;\r\n\r\n private _enableLicensedDocumentIntakeAndProcessing: boolean;\r\n\r\n private _allManageOptions: AdminGroup[] = [\r\n {\r\n group: 'General',\r\n items: [\r\n {\r\n name: 'Action View Output Fields',\r\n route: 'manage.actionViewOutputFields',\r\n isShown: () => true,\r\n amplitudeProperty: { event: 'click-manage-AV-output' }\r\n },\r\n {\r\n name: 'Contacts',\r\n route: 'manage.contacts',\r\n isShown: () => this.roles.hasContactRoles,\r\n amplitudeProperty: { event: 'click-manage-admin-contacts' }\r\n },\r\n {\r\n name: 'Factor Tables',\r\n route: 'manage.factorTables',\r\n isShown: () => this.roles.hasComplianceSetupsView || this.roles.hasComplianceSetupsEdit,\r\n amplitudeProperty: { event: 'click-manage-admin-factor-tables' }\r\n },\r\n {\r\n name: 'Forms',\r\n route: 'manage.forms',\r\n isShown: () => this.roles.hasComplianceSetupsView || this.roles.hasComplianceSetupsEdit,\r\n amplitudeProperty: { event: 'click-manage-admin-forms' }\r\n }\r\n ]\r\n },\r\n {\r\n group: 'Imports',\r\n items: [\r\n {\r\n name: 'Data Imports',\r\n route: 'manage.dataImports',\r\n isShown: () => this.roles.hasAllowDataImports,\r\n amplitudeProperty: { event: 'click-manage-admin-import', properties: { manageAdminImport: 'data' } }\r\n },\r\n {\r\n name: 'Import Assessments',\r\n route: 'manage.importAssessments',\r\n isShown: () => this.roles.hasAllowDataImports,\r\n amplitudeProperty: { event: 'click-manage-admin-import', properties: { manageAdminImport: 'assessments' } }\r\n },\r\n {\r\n name: 'Import Parcels',\r\n route: 'manage.importParcels',\r\n isShown: () => this.roles.hasAllowDataImports,\r\n amplitudeProperty: { event: 'click-manage-admin-import', properties: { manageAdminImport: 'parcels' } }\r\n },\r\n {\r\n name: 'Import Sites',\r\n route: 'manage.importSites',\r\n isShown: () => this.roles.hasAllowDataImports,\r\n amplitudeProperty: { event: 'click-manage-admin-import', properties: { manageAdminImport: 'sites' } }\r\n }\r\n ]\r\n },\r\n {\r\n group: 'Info & Management',\r\n items: [\r\n {\r\n name: 'Agents',\r\n route: 'manage.agents',\r\n isShown: () => this.roles.hasAgentInfo,\r\n amplitudeProperty: { event: 'click-manage-admin-agents' }\r\n },\r\n {\r\n name: 'API Keys',\r\n route: 'manage.manageApiKeys',\r\n isShown: () => this.roles.hasManageAPIKeys\r\n },\r\n {\r\n name: 'Consulting Engagements',\r\n route: 'manage.manageConsultingEngagements',\r\n isShown: () => this.isSingleInstanceSelected\r\n && this._userInstanceService.getSelectedInstance().offersConsultingServices\r\n && this._restrictService.hasInstanceRight(InstanceRights.MANAGECONSULTINGENGAGEMENT, this._userInstanceService.getSelectedInstance().instanceId)\r\n },\r\n {\r\n name: 'Instance Settings',\r\n route: 'manage.manageInstanceSettings',\r\n isShown: () => this.roles.hasManageConsultingEngagements,\r\n amplitudeProperty: { event: 'click-manage-admin-instance-settings' }\r\n },\r\n {\r\n name: 'Licensed Client Documents',\r\n route: 'manage.manageLicensedClientDocuments',\r\n isShown: () => this.roles.hasLicensedDocumentServices && this._enableLicensedDocumentIntakeAndProcessing,\r\n },\r\n {\r\n name: 'My Instances',\r\n route: 'manage.manageInstances',\r\n isShown: () => this.showManageInstancesMenuItem,\r\n amplitudeProperty: { event: 'click-manage-my-instances' }\r\n },\r\n {\r\n name: 'Property Characteristics',\r\n route: 'manage.propertyCharacteristics',\r\n isShown: () => this.roles.hasPropCharsRoles,\r\n amplitudeProperty: { event: 'click-manage-admin-property-characteristics' }\r\n },\r\n {\r\n name: 'Roles',\r\n route: 'manage.roles',\r\n isShown: () => this.roles.hasContactRoleRoles,\r\n amplitudeProperty: { event: 'click-manage-admin-roles' }\r\n },\r\n {\r\n name: 'Support Instances',\r\n route: 'manage.manageSupportInstances',\r\n isShown: () => this.roles.hasSupportRole\r\n },\r\n {\r\n name: 'Teams',\r\n route: 'manage.teams',\r\n isShown: () => this.roles.hasTeamViewOrEdit,\r\n amplitudeProperty: { event: 'click-manage-admin-teams' }\r\n },\r\n {\r\n name: 'User Groups',\r\n route: 'manage.userGroups',\r\n isShown: () => this.roles.hasUserGroupViewOrEdit,\r\n isDisabled: () => !this.roles.hasUserGroupEdit,\r\n amplitudeProperty: { event: 'click-manage-admin-user-groups' }\r\n },\r\n {\r\n name: 'Valuation Templates',\r\n route: 'manage.valuationTemplates',\r\n isShown: () => this.roles.hasValuationTemplateEdit,\r\n amplitudeProperty: { event: 'click-manage-admin-valuation-templates' }\r\n }\r\n ]\r\n }\r\n ];\r\n\r\n private _destroy$: Subject = new Subject();\r\n private _destroyTransitionHook: any;\r\n\r\n async ngOnInit(): Promise {\r\n this.roles = this._topNavService.roles();\r\n this._enableLicensedDocumentIntakeAndProcessing = this._featureFlagsService.featureFlags.enableLicensedDocumentIntakeAndProcessing;\r\n\r\n this.hasAddNewCompanyRole = this._restrictService.hasInstanceRight(InstanceRights.ADDNEWCOMPANY);\r\n this.hasAddNewInstanceRole = this._restrictService.isInRole(Roles.INSTANCEADMIN);\r\n\r\n this.isSingleInstanceSelected = this._userInstanceService.isSingleInstanceSelected();\r\n\r\n if (!this.roles.hasAdminRole && !this.roles.hasAddNewCompanyRole && !this.roles.hasAddNewInstanceRole) {\r\n this._router.stateService.go('home', {});\r\n }\r\n this.showManageInstancesMenuItem = (await this._instanceRepository.getCurrentUsersContactInviteStatuses()).length > 1;\r\n\r\n this.adminOptions = this._allManageOptions.map(x => {\r\n return {\r\n group: x.group,\r\n items: x.items.filter(y => y.isShown())\r\n };\r\n });\r\n\r\n this._setAdminControlValue(this._router.globals.current);\r\n\r\n this._destroyTransitionHook = this._router.transitionService.onSuccess({}, (transition) => {\r\n this._setAdminControlValue(this._router.globals.current);\r\n });\r\n\r\n this.adminControl.valueChanges\r\n .pipe(takeUntil(this._destroy$), distinctUntilChanged())\r\n .subscribe((value) => {\r\n if (value.amplitudeProperty) {\r\n this._productAnalyticsService.logEvent(value.amplitudeProperty.event, value.amplitudeProperty.properties);\r\n }\r\n this._router.stateService.transitionTo(value.route, {});\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._destroyTransitionHook();\r\n }\r\n\r\n async newInstance(): Promise {\r\n const result = await this._modalService.showAsync(AddInstanceModalComponent, {}, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n async newCompany(): Promise {\r\n await this._launchAddCompanyModalService.addCompany();\r\n }\r\n\r\n private _setAdminControlValue(routerState: Ng2StateDeclaration): void {\r\n if (routerState.name === 'manage') {\r\n return;\r\n }\r\n const option = this.adminOptions\r\n .reduce((acc, x) => acc = [...acc, ...x.items], [])\r\n .find(y => y.route === routerState.name);\r\n if (option) {\r\n this.adminControl.setValue(option);\r\n } else {\r\n console.warn('No route found for', routerState.name);\r\n this._router.stateService.go('home', {});\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { IntegrationHmac, IntegrationHmacDetail } from './manage-api-keys.models';\r\n\r\n@Injectable()\r\nexport class ManageAPIKeysService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n getPublicKeys(): Promise {\r\n return this.http.get('/api/ExternalAPIConfig/keys') as Promise;\r\n }\r\n\r\n getPublicKey(integrationHmacId: number): Promise {\r\n return this.http.get(`/api/ExternalAPIConfig/keys/${ integrationHmacId}`) as Promise;\r\n }\r\n\r\n savePublicKey(integrationHmac: IntegrationHmacDetail): Promise {\r\n return this.http.put(`/api/ExternalAPIConfig/keys/${ integrationHmac.integrationHmacId}`, integrationHmac) as Promise;\r\n }\r\n\r\n sendKeyEmail(userId: string, integrationHmac: IntegrationHmacDetail): Promise {\r\n return this.http.post('/api/ExternalAPIConfig/KeyTransmittalRequest', {\r\n userId: userId,\r\n publicKey: integrationHmac.publicKey\r\n }) as Promise;\r\n }\r\n\r\n createNewKey(companyId: number, keyName: string): Promise {\r\n return this.http.post('/api/ExternalAPIConfig/key', {\r\n companyId: companyId,\r\n name: keyName\r\n }) as Promise;\r\n }\r\n\r\n deleteKey(integrationHmacId): Promise {\r\n return this.http.delete(`/api/ExternalAPIConfig/keys/${ integrationHmacId}`);\r\n }\r\n}\r\n","
\r\n \r\n \r\n
\r\n","import { Component, Input, EventEmitter, Output, OnInit, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { CompanyService } from './company.service';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { Observable } from 'rxjs';\r\n\r\nexport class TypeaheadCompany {\r\n companyID: number;\r\n companyName: string;\r\n isFavorite: boolean;\r\n instanceIdFilter: number;\r\n}\r\n\r\n//TODO: Make this async\r\n@Component({\r\n selector: 'company-picker',\r\n templateUrl: './Company.Picker.Component.html'\r\n})\r\nexport class CompanyPickerComponent implements OnInit, OnChanges {\r\n constructor(private companyService: CompanyService) {}\r\n\r\n @Input() company: TypeaheadCompany;\r\n @Input() topLevelOnly: boolean = false;\r\n @Input() activeOnly: boolean = false;\r\n @Input() instanceIdFilter: number;\r\n @Input() clientInstanceId: number;\r\n @Input() useExplicitCrossInstanceListForPermCheck: boolean = false;\r\n @Output() companySelected: EventEmitter = new EventEmitter();\r\n\r\n companyName: string;\r\n companiesLoading: boolean;\r\n dataSource: Observable;\r\n\r\n ngOnInit() {\r\n this.dataSource = Observable.create((observer: any) => {\r\n if(!this.companyName) {\r\n return;\r\n }\r\n\r\n this.companyService.search(this.companyName, 8, 1, this.topLevelOnly, false, this.activeOnly, this.instanceIdFilter, this.clientInstanceId, this.useExplicitCrossInstanceListForPermCheck)\r\n .then((data) => {\r\n observer.next(data);\r\n });\r\n });\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges) {\r\n this.companyName = this.company ? this.company.companyName : '';\r\n\r\n if(changes.instanceId) {\r\n this.companyName = '';\r\n this.company = undefined;\r\n }\r\n }\r\n\r\n typeaheadOnSelect(e: TypeaheadMatch) {\r\n this.company = e.item;\r\n this.companySelected.emit(e.item);\r\n }\r\n\r\n inputChanged() {\r\n if(!this.companyName) {\r\n this.companySelected.emit(new TypeaheadCompany());\r\n }\r\n }\r\n}\r\n","
\r\n\t
\r\n\t\t

API Keys

\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Public KeyNameCompanyActive
{{apiKey.publicKey}}{{apiKey.name}}{{apiKey.companyName}}YesNo
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { ManageAPIKeysService } from './manage-api-keys.service';\r\nimport { IntegrationHmac } from './manage-api-keys.models';\r\nimport { TypeaheadCompany } from '../../Entity/Company/Company.Picker.Component';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\n\r\n@Component({\r\n selector: 'manage-api-keys',\r\n templateUrl: './manage-api-keys.component.html',\r\n styleUrls: ['./manage-api-keys.component.scss']\r\n})\r\nexport class ManageAPIKeysComponent implements OnInit {\r\n constructor(private toastr: ToastrService,\r\n private manageAPIKeysService: ManageAPIKeysService,\r\n private upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler) { }\r\n\r\n loading: boolean;\r\n apiKeys: IntegrationHmac[];\r\n addingKey: boolean;\r\n // If we end up with more fields on the create form, consider making a class for the new properties instead of having them\r\n // as invididual variables\r\n newCompanyId: number;\r\n newKeyName: string;\r\n newCompanyValidationMessage: string;\r\n newKeyNameValidationMessage: string;\r\n\r\n ngOnInit() {\r\n this.addingKey = false;\r\n this.loadKeys();\r\n }\r\n\r\n async loadKeys(): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n this.apiKeys = await this.manageAPIKeysService.getPublicKeys();\r\n\r\n console.log(this.apiKeys);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n goToDetail(integrationHmacId: number) {\r\n this.upgradeNavigationServiceHandler.go('apiKeyDetail', {\r\n integrationHmacId: integrationHmacId\r\n });\r\n }\r\n\r\n addNewKey(): void {\r\n this.addingKey = true;\r\n this.newKeyName = null;\r\n this.newCompanyId = null;\r\n this.newCompanyValidationMessage = null;\r\n this.newKeyNameValidationMessage = null;\r\n }\r\n\r\n async saveKey(): Promise {\r\n let valid = true;\r\n this.newCompanyValidationMessage = null;\r\n this.newKeyNameValidationMessage = null;\r\n if (!this.newCompanyId) {\r\n valid = false;\r\n this.newCompanyValidationMessage = 'Company is required';\r\n }\r\n if (!this.newKeyName) {\r\n valid = false;\r\n this.newKeyNameValidationMessage = 'Name is required';\r\n }\r\n else if (this.newKeyName.length > 50) {\r\n valid = false;\r\n this.newKeyNameValidationMessage = 'Name cannot be longer than 50 characters';\r\n }\r\n\r\n if (valid) {\r\n this.loading = true;\r\n\r\n try {\r\n await this.manageAPIKeysService.createNewKey(this.newCompanyId, this.newKeyName);\r\n this.toastr.success('New API Key Created');\r\n this.addingKey = false;\r\n await this.loadKeys();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n\r\n companySelected(company: TypeaheadCompany): void {\r\n this.newCompanyId = company.companyID;\r\n }\r\n\r\n cancelAddKey(): void {\r\n this.addingKey = false;\r\n }\r\n\r\n identify(apiKey) {\r\n return apiKey.integrationHmacId;\r\n }\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { BaseRepository } from 'src/app/Common/Data/base.repository';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class LoginManagerService extends BaseRepository {\r\n constructor(_http: HttpClient) {\r\n super(_http);\r\n }\r\n\r\n loadUser(userId: System.Guid): Promise {\r\n return lastValueFrom(this.httpGet(`/api/admin/account/${userId}`));\r\n }\r\n\r\n getIAMUserData(userId: System.Guid): Promise {\r\n return lastValueFrom(this.httpGet(`/api/admin/account/${userId}/IAMUserInfo`));\r\n }\r\n\r\n updateLockedFields(userId: System.Guid, request: Core.UpdateUserLockedFieldsRequest): Promise {\r\n return lastValueFrom(this.httpPut(`/api/admin/account/${userId}/UpdateLockedFields`, request));\r\n }\r\n\r\n unmigrateUser(userId: System.Guid): Promise {\r\n return lastValueFrom(this.httpPost(`/api/admin/account/${userId}/UnmigrateUser`, null));\r\n }\r\n\r\n getIAMTenantData(userId: System.Guid): Promise {\r\n return lastValueFrom(this.httpGet(`/api/admin/account/${userId}/IAMTenantInfo`));\r\n }\r\n\r\n removeUserIAMTenant(userId: System.Guid): Promise {\r\n return lastValueFrom(this.httpDelete(`/api/admin/account/${userId}/IAMTenantId`));\r\n }\r\n\r\n updateUserIAMTenantId(userId: System.Guid, tenantId: System.Guid): Promise {\r\n return lastValueFrom(this.httpPut(`/api/admin/account/${userId}/UpdateIAMTenantId/${tenantId}`, null));\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

\r\n User\r\n

\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
UserName:{{user.userName}}
Email:{{user.email}}
First Name:{{user.firstName}}
Last Name:{{user.lastName}}
User Id:{{user.userId}}
Active:{{user.active}}
Home Instance:{{homeInstanceName}}
IAM Id:{{user.iamId}}
IAM Migrated:{{user.iamIsMigrated}}
IAM Tenant Id:{{user.iamTenantId}}
Created:{{user.createDate | weissmanDateTimeFormat: true: 'Central'}}
Lockout End Date:{{user.lockoutEndDateUtc | weissmanDateTimeFormat: true: 'Central'}}
Lockout Enabled:{{user.lockoutEnabled}}
Access Failed Count:{{user.accessFailedCount}}
\r\n
\r\n

Note: All times in Central Time

\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n IAM Id:\r\n (None)\r\n {{user.iamId}}\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n IAM Id:\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Tenant Id:{{iamUserData.tenantId}}
UserName:{{iamUserData.username}}
Display Name:{{iamUserData.displayName}}
First Name:{{iamUserData.firstName}}
Last Name:{{iamUserData.lastName}}
Tenant Admin:{{iamUserData.isTenantAdmin}}
Job Title:{{iamUserData.jobTitle}}
Phone:{{iamUserData.phone}}
Status:{{iamUserData.userStatus}}
\r\n
\r\n
\r\n
\r\n Tenant Id:\r\n (None)\r\n {{user.iamId}}\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n Tenant Id:\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Tenant Id:{{iamTenantData.id}}
Name:{{iamTenantData.name}}
Status:{{iamTenantData.status}}
\r\n
\r\n

\r\n Note: Normally it is not necessary for a user to have an IAM Tenant Id. The Tenant Id usually is inferred based on\r\n the company for the user's home instance contact. You only need to include an IAM Tenant Id for a user if it differs\r\n from their company's Tenant Id or if there is no such Tenant Id configured on the company. Also, the Tenant Id is\r\n only used during the migration process and is not necessary for normal logins.\r\n

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
First Name:\r\n \r\n
Last Name:\r\n \r\n
Email:\r\n \r\n
IAM Migrated:\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n

\r\n Contact\r\n

\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Contact Id:{{contact.contactID}}
Prefix:{{contact.prefix}}
First Name:{{contact.firstName}}
Last Name:{{contact.lastName}}
Title:{{contact.title}}
Company Id:{{contact.companyID}}
Company:{{contact.companyName}}
Company IAM Tenant Id:{{contact.companyIAMTenantId}}
Active:{{contact.active}}
Email:{{contact.email}}
Accepted Invite:{{contact.invite}}
Hidden:{{contact.hidden}}
Instance Id:{{contact.instanceId}}
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { BusyIndicatorService } from 'src/app/Busy-Indicator';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\nimport { BreadCrumb } from 'src/app/UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { MessageModalService } from 'src/app/UI-Lib/Message-Box/messageModal.service';\r\nimport { UserInstanceService } from 'src/app/User/userInstance.service';\r\nimport { LoginManagerService } from './loginManager.service';\r\n\r\n@Component({\r\n selector: 'login-manager',\r\n templateUrl: './loginManager.component.html'\r\n})\r\nexport class LoginManagerComponent implements OnInit {\r\n constructor(\r\n private _busyIndicatorService: BusyIndicatorService,\r\n private _userInstanceService: UserInstanceService,\r\n private _toastr: ToastrService,\r\n private _routerService: UpgradeNavigationServiceHandler,\r\n private _messageModalService: MessageModalService,\r\n private _loginManagerService: LoginManagerService) {\r\n }\r\n\r\n userId: string;\r\n user: Core.UserLoginInfoModel;\r\n contact: Core.ContactLoginInfoModel;\r\n homeInstanceName: string;\r\n pageTitle: string = 'Login Manager';\r\n instances: { name: string, id: number }[];\r\n selectedInstance: { name: string, id: number };\r\n breadcrumbs: BreadCrumb[] = [{\r\n name: 'Contacts',\r\n target: 'contacts',\r\n options: {}\r\n }];\r\n userActionState: 'None' | 'ManageIAMUser' | 'ManageIAMTenant' | 'UpdateLockedFields';\r\n iamUserData: Core.IAMUserDTO;\r\n iamTenantData: Core.IAMTenantDTO;\r\n updatingUserIAMId: boolean;\r\n newIAMId: System.Guid;\r\n updatingUserTenantId: boolean;\r\n newIAMTenantId: System.Guid;\r\n\r\n // Locked fields\r\n newFirstName: string;\r\n newLastName: string;\r\n newEmail: string;\r\n newIsMigrated: boolean;\r\n\r\n async ngOnInit() {\r\n if (!this._userInstanceService.isCurrentInstanceSystem()) {\r\n this._toastr.error('You must be in the support instance to use this page.');\r\n return;\r\n }\r\n\r\n this.userId = this._routerService.getQuerystringParam('userId');\r\n\r\n if (!/^[\\da-fA-F]{8}-[\\da-fA-F]{4}-[\\da-fA-F]{4}-[\\da-fA-F]{4}-[\\da-fA-F]{12}$/.test(this.userId)) {\r\n this._toastr.error('Invalid userId.');\r\n return;\r\n }\r\n\r\n this.selectedInstance = null;\r\n\r\n await this.loadUser();\r\n }\r\n\r\n selectedInstanceChanged() {\r\n this.loadContact();\r\n }\r\n\r\n async loadUser() {\r\n this.cancelUserAction();\r\n\r\n const busyIndicator = this._busyIndicatorService.show({ message: 'Loading User' });\r\n try {\r\n this.user = await this._loginManagerService.loadUser(this.userId);\r\n\r\n // Look for the user home instance in the list of contacts to get the instance name, default to the instance ID itself if not found\r\n this.homeInstanceName = this.user.contacts.find(c => c.instanceId == this.user.instanceId)?.instanceName ?? `${this.user.instanceId}`;\r\n\r\n this.instances = this.user.contacts.map(c => ({ name: c.instanceName, id: c.instanceId }));\r\n\r\n // Either keep the last selected instance or default to the user's home instance\r\n const instanceId = this.selectedInstance?.id ?? this.user.instanceId;\r\n this.selectedInstance = this.instances.find(i => i.id == instanceId) ?? this.instances[0];\r\n\r\n this.loadContact();\r\n\r\n this.breadcrumbs = [\r\n this.breadcrumbs[0],\r\n {\r\n name: `${this.user.firstName} ${this.user.lastName}`,\r\n target: 'contacts',\r\n options: {\r\n contactId: this.user.contacts.find(c => c.instanceId === this._userInstanceService.SystemInstanceId).contactID\r\n }\r\n }];\r\n } finally {\r\n busyIndicator.hide();\r\n }\r\n }\r\n\r\n loadContact() {\r\n this.contact = this.user.contacts.find(c => c.instanceId == this.selectedInstance.id);\r\n }\r\n\r\n cancelUserAction() {\r\n this.userActionState = 'None';\r\n }\r\n\r\n startManageIAMUser() {\r\n this.iamUserData = null;\r\n this.updatingUserIAMId = false;\r\n this.userActionState = 'ManageIAMUser';\r\n }\r\n\r\n startManageIAMTenant() {\r\n this.iamTenantData = null;\r\n this.updatingUserTenantId = false;\r\n this.userActionState = 'ManageIAMTenant';\r\n }\r\n\r\n startUpdateLockedFields() {\r\n this.newFirstName = this.user.firstName;\r\n this.newLastName = this.user.lastName;\r\n this.newEmail = this.user.email;\r\n this.newIsMigrated = this.user.iamIsMigrated;\r\n this.userActionState = 'UpdateLockedFields';\r\n }\r\n\r\n async getIAMUserData() {\r\n const busyIndicator = this._busyIndicatorService.show({ message: 'Loading User' });\r\n try {\r\n this.iamUserData = await this._loginManagerService.getIAMUserData(this.userId);\r\n } finally {\r\n busyIndicator.hide();\r\n }\r\n }\r\n\r\n startUpdateUserIAMId() {\r\n this.updatingUserIAMId = true;\r\n this.newIAMId = this.user.iamId;\r\n }\r\n\r\n async saveUserIAMId() {\r\n await this.performUserAction('Saving user', async () => {\r\n await this._loginManagerService.updateLockedFields(this.userId, {\r\n iamId: this.newIAMId,\r\n email: null,\r\n firstName: null,\r\n lastName: null,\r\n iamIsMigrated: null\r\n });\r\n });\r\n }\r\n\r\n cancelUpdateUserIAMId() {\r\n this.updatingUserIAMId = false;\r\n }\r\n\r\n async unMigrateUser() {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you want to un-migrate this user?', 'Confirm');\r\n }\r\n catch (e) {\r\n return;\r\n }\r\n\r\n await this.performUserAction('Unmigrating user', async () => {\r\n await this._loginManagerService.unmigrateUser(this.userId);\r\n });\r\n }\r\n\r\n async getIAMTenantData() {\r\n const busyIndicator = this._busyIndicatorService.show({ message: 'Loading Tenant' });\r\n try {\r\n this.iamTenantData = await this._loginManagerService.getIAMTenantData(this.userId);\r\n } finally {\r\n busyIndicator.hide();\r\n }\r\n }\r\n\r\n startUpdateUserIAMTenantId() {\r\n this.newIAMTenantId = this.user.iamTenantId;\r\n this.updatingUserTenantId = true;\r\n }\r\n\r\n async removeUserIAMTenant() {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you want to remove the IAM Tenant Id from this user?', 'Confirm');\r\n }\r\n catch (e) {\r\n return;\r\n }\r\n\r\n await this.performUserAction('Updating user', async () => {\r\n await this._loginManagerService.removeUserIAMTenant(this.userId);\r\n });\r\n }\r\n\r\n async saveUserIAMTenantId() {\r\n await this.performUserAction('Saving user', async () => {\r\n await this._loginManagerService.updateUserIAMTenantId(this.userId, this.newIAMTenantId);\r\n });\r\n }\r\n\r\n cancelUpdateUserIAMTenantId() {\r\n this.updatingUserTenantId = false;\r\n }\r\n\r\n toggleNewIsMigrated() {\r\n this.newIsMigrated = !this.newIsMigrated;\r\n }\r\n\r\n async saveLockedFields() {\r\n await this.performUserAction('Saving user', async () => {\r\n await this._loginManagerService.updateLockedFields(this.userId, {\r\n firstName: this.user.firstName === this.newFirstName ? null : this.newFirstName,\r\n lastName: this.user.lastName === this.newLastName ? null : this.newLastName,\r\n email: this.user.email === this.newEmail ? null : this.newEmail,\r\n iamId: null,\r\n iamIsMigrated: this.user.iamIsMigrated === this.newIsMigrated ? null : this.newIsMigrated\r\n });\r\n });\r\n }\r\n\r\n async performUserAction(message: string, action: () => Promise) {\r\n const busyIndicator = this._busyIndicatorService.show({ message: message });\r\n try {\r\n await action();\r\n\r\n await this.loadUser();\r\n this.updatingUserIAMId = false;\r\n this.updatingUserTenantId = false;\r\n this._toastr.success('Update complete.');\r\n } finally {\r\n busyIndicator.hide();\r\n }\r\n }\r\n}\r\n","\r\nexport class IntegrationHmac {\r\n integrationHmacId: number;\r\n name: string;\r\n publicKey: string;\r\n isActive: boolean;\r\n companyId: number;\r\n userId: string;\r\n companyName: string;\r\n rowVersion: string;\r\n}\r\n\r\nexport class IntegrationHmacDetail {\r\n integrationHmacId: number;\r\n name: string;\r\n publicKey: string;\r\n isActive: boolean;\r\n companyId: number;\r\n userId: string;\r\n companyName: string;\r\n rowVersion: string;\r\n users: IntegrationHmacUserDetail[];\r\n}\r\n\r\nexport class IntegrationHmacUserDetail {\r\n constructor(userTeamMember?: Core.UserTeamModel) {\r\n if (userTeamMember) {\r\n this.firstName = userTeamMember.firstName;\r\n this.lastName = userTeamMember.lastName;\r\n this.userId = userTeamMember.userID as string;\r\n this.integratonHmacUserId = 0;\r\n this.rowVersion = null;\r\n }\r\n }\r\n\r\n integratonHmacUserId: number;\r\n firstName: string;\r\n lastName: string;\r\n userId: string;\r\n rowVersion: string;\r\n}\r\n","
\r\n\t
\r\n\t\t

API Keys

\r\n Back to list\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

API Key

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n

Users:

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{user.lastName}}, {{user.firstName}}\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { ManageAPIKeysService } from './manage-api-keys.service';\r\nimport { IntegrationHmacDetail, IntegrationHmacUserDetail } from './manage-api-keys.models';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'api-key-detail',\r\n templateUrl: './api-key-detail.component.html'\r\n})\r\nexport class APIKeyDetailComponent implements OnInit {\r\n constructor(private toastr: ToastrService,\r\n private messageBoxService: MessageBoxService,\r\n private manageAPIKeysService: ManageAPIKeysService,\r\n private upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler) { }\r\n\r\n loading: boolean;\r\n integrationHmacId: number;\r\n integrationHmacDetail: IntegrationHmacDetail;\r\n integrationHmacDetailBackup: IntegrationHmacDetail;\r\n inEditMode: boolean;\r\n addingUser: boolean;\r\n newUser: Core.UserTeamModel;\r\n keyNameValidationMessage: string;\r\n\r\n\r\n async ngOnInit() {\r\n this.loading = true;\r\n this.addingUser = false;\r\n this.inEditMode = false;\r\n this.newUser = {} as Core.UserTeamModel;\r\n this.integrationHmacDetailBackup = null;\r\n this.integrationHmacId = +this.upgradeNavigationServiceHandler.getQuerystringParam('integrationHmacId');\r\n\r\n try {\r\n this.integrationHmacDetail = await this.manageAPIKeysService.getPublicKey(this.integrationHmacId);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n backToManage(): void {\r\n this.upgradeNavigationServiceHandler.go('manageAPIKeys', {});\r\n }\r\n\r\n edit_click(): void {\r\n this.inEditMode = true;\r\n this.integrationHmacDetailBackup = _.cloneDeep(this.integrationHmacDetail);\r\n this.keyNameValidationMessage = null;\r\n }\r\n\r\n cancel_click(): void {\r\n this.newUser = {} as Core.UserTeamModel;\r\n this.addingUser = false;\r\n this.integrationHmacDetail = this.integrationHmacDetailBackup;\r\n this.integrationHmacDetailBackup = null;\r\n this.inEditMode = false;\r\n }\r\n\r\n async save_click(): Promise {\r\n let valid = true;\r\n this.keyNameValidationMessage = null;\r\n if (!this.integrationHmacDetail.name) {\r\n valid = false;\r\n this.keyNameValidationMessage = 'Name is required';\r\n }\r\n else if (this.integrationHmacDetail.name.length > 50) {\r\n valid = false;\r\n this.keyNameValidationMessage = 'Name cannot be longer than 50 characters';\r\n }\r\n\r\n if (valid) {\r\n this.loading = true;\r\n\r\n try {\r\n this.integrationHmacDetail = await this.manageAPIKeysService.savePublicKey(this.integrationHmacDetail);\r\n this.integrationHmacDetailBackup = null;\r\n this.addingUser = false;\r\n this.inEditMode = false;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n\r\n deleteKey_click(): void {\r\n this.messageBoxService.confirmYesNo('It is generally recommended that you deactivate a key instead of deleting it. Are you really sure you want to delete this API key?').then(async () => {\r\n this.loading = true;\r\n\r\n try {\r\n await this.manageAPIKeysService.deleteKey(this.integrationHmacId);\r\n this.upgradeNavigationServiceHandler.go('manageAPIKeys', {});\r\n } finally {\r\n this.loading = false;\r\n }\r\n });\r\n }\r\n\r\n sendEmail(user: IntegrationHmacUserDetail): void {\r\n this.messageBoxService.confirmYesNo('Are you sure you want to send a private key email to this user?').then(async () => {\r\n this.loading = true;\r\n\r\n try {\r\n await this.manageAPIKeysService.sendKeyEmail(user.userId, this.integrationHmacDetail);\r\n this.toastr.success('An email has been sent to the user with instructions to retrieve the private key', 'Email Sent');\r\n } finally {\r\n this.loading = false;\r\n }\r\n });\r\n }\r\n\r\n removeUser(user: IntegrationHmacUserDetail): void {\r\n this.integrationHmacDetail.users = this.integrationHmacDetail.users.filter(u => u !== user);\r\n }\r\n\r\n beginAddUser_click(): void {\r\n // TODO: Maybe we should make a user control that doesn't have teams, since teams aren't relevant here.\r\n this.addingUser = true;\r\n this.newUser = {} as Core.UserTeamModel;\r\n }\r\n\r\n setNewUser(newUser: Core.UserTeamModel) {\r\n this.newUser = newUser;\r\n }\r\n\r\n cancelAddUser_click(): void {\r\n this.newUser = {} as Core.UserTeamModel;\r\n this.addingUser = false;\r\n }\r\n\r\n saveAddUser_click(): void {\r\n if (this.newUser.userID && !_.some(this.integrationHmacDetail.users, u => u.userId == this.newUser.userID)) {\r\n this.integrationHmacDetail.users.push(new IntegrationHmacUserDetail(this.newUser));\r\n }\r\n this.newUser = {} as Core.UserTeamModel;\r\n this.addingUser = false;\r\n }\r\n\r\n identify(user) {\r\n return user.integrationHmacUserId;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AllAppVersionInfo, VersionInfo } from './about.models';\r\n\r\n@Injectable()\r\nexport class AboutService {\r\n constructor(private http: HttpClient) { }\r\n\r\n async getAllAppVersionInfo() {\r\n return await lastValueFrom(this.http.get('/api/AppInfo/getAll'));\r\n }\r\n\r\n async GetUIVersionInfo() {\r\n return await lastValueFrom(this.http.get('/assets/UIVersionInfo.json'));\r\n }\r\n\r\n async getJSReportVersionInfo() {\r\n return await lastValueFrom(this.http.get('/api/AppInfo/JSReportVersionInfo'));\r\n }\r\n}\r\n","
\r\n\t
\r\n

ABOUT

\r\n
\r\n \r\n
\r\n\r\n
\r\n

API

\r\n

\r\n Assembly Version:\r\n {{allAppVersionInfo.apiAssemblyVersion}}\r\n

\r\n

\r\n Branch Name:\r\n {{allAppVersionInfo.apiVersionInfo.branchName}}\r\n

\r\n

\r\n Build Number:\r\n {{allAppVersionInfo.apiVersionInfo.buildNumber}}\r\n

\r\n

\r\n Build Time:\r\n {{allAppVersionInfo.apiVersionInfo.buildTime}}\r\n

\r\n

\r\n Commit:\r\n {{allAppVersionInfo.apiVersionInfo.commit}}\r\n

\r\n

\r\n Last Relevant Commit:\r\n {{allAppVersionInfo.apiVersionInfo.lastRelevantCommit}}\r\n

\r\n\r\n

DB

\r\n

\r\n Release Version:\r\n {{allAppVersionInfo.dbEpicVersion}}\r\n

\r\n

\r\n Branch Name:\r\n {{allAppVersionInfo.dbVersionInfo.branchName}}\r\n

\r\n

\r\n Build Number:\r\n {{allAppVersionInfo.dbVersionInfo.buildNumber}}\r\n

\r\n

\r\n Build Time:\r\n {{allAppVersionInfo.dbVersionInfo.buildTime}}\r\n

\r\n

\r\n Commit:\r\n {{allAppVersionInfo.dbVersionInfo.commit}}\r\n

\r\n

\r\n Last Relevant Commit:\r\n {{allAppVersionInfo.dbVersionInfo.lastRelevantCommit}}\r\n

\r\n\r\n

UI

\r\n

\r\n Branch Name:\r\n {{uiVersionInfo.branchName}}\r\n

\r\n

\r\n Build Number:\r\n {{uiVersionInfo.buildNumber}}\r\n

\r\n

\r\n Build Time:\r\n {{uiVersionInfo.buildTime}}\r\n

\r\n

\r\n Commit:\r\n {{uiVersionInfo.commit}}\r\n

\r\n

\r\n Last Relevant Commit:\r\n {{uiVersionInfo.lastRelevantCommit}}\r\n

\r\n\r\n

JSReport

\r\n \r\n

\r\n Branch Name:\r\n {{reportVersionInfo.branchName}}\r\n

\r\n

\r\n Build Number:\r\n {{reportVersionInfo.buildNumber}}\r\n

\r\n

\r\n Build Time:\r\n {{reportVersionInfo.buildTime}}\r\n

\r\n

\r\n Commit:\r\n {{reportVersionInfo.commit}}\r\n

\r\n

\r\n Last Relevant Commit:\r\n {{reportVersionInfo.lastRelevantCommit}}\r\n

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { AllAppVersionInfo, VersionInfo } from './about.models';\r\nimport { AboutService } from './about.service';\r\n\r\ndeclare const saveAs: (blob: Blob, fileName: string) => void;\r\n\r\n@Component({\r\n selector: 'about',\r\n templateUrl: './about.component.html',\r\n styleUrls: ['./about.component.scss']\r\n})\r\nexport class AboutComponent implements OnInit {\r\n constructor(\r\n private aboutService: AboutService\r\n ) { }\r\n\r\n loading: boolean;\r\n allAppVersionInfo: AllAppVersionInfo;\r\n uiVersionInfo: VersionInfo;\r\n reportVersionInfo: VersionInfo;\r\n emailButtonDisabled: boolean;\r\n\r\n\r\n async ngOnInit() {\r\n this.loading = true;\r\n try {\r\n this.reportVersionInfo = null;\r\n // We should probably use promise.all to get these in parallel\r\n this.allAppVersionInfo = await this.aboutService.getAllAppVersionInfo();\r\n this.uiVersionInfo = await this.aboutService.GetUIVersionInfo();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async getJSReportVersionInfo() {\r\n this.loading = true;\r\n\r\n try {\r\n this.reportVersionInfo = await this.aboutService.getJSReportVersionInfo();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

Test DXP

\r\n
\r\n
\r\n
\r\n
{{message}}
\r\n \r\n Sync\r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator/busyIndicator.service';\r\nimport { DXPService } from './dxp.service';\r\n\r\n@Component({\r\n selector: 'test-dxp-page',\r\n templateUrl: './testDXPPage.component.html'\r\n})\r\nexport class TestDXPPageComponent implements OnInit {\r\n constructor(\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _dxpService: DXPService\r\n ) { }\r\n\r\n message: string;\r\n isDisabled: boolean;\r\n\r\n async ngOnInit(): Promise {\r\n const busyRef = this._busyService.show({ message: 'Loading' });\r\n this.isDisabled = false;\r\n\r\n try {\r\n const dxpMode = await this._dxpService.getDXPMode();\r\n if (dxpMode === Core.DXPSyncModes.Disabled) {\r\n this.message = 'DXP Sync Test disabled';\r\n this.isDisabled = true;\r\n }\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async sync() {\r\n const busyRef = this._busyService.show({ message: 'Loading' });\r\n\r\n try {\r\n await this._dxpService.testDXPSync();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n }\r\n}","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { UIRouterUpgradeModule } from '@uirouter/angular-hybrid';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { CompanyModule } from '../Entity/Company/company.module';\r\nimport { AceModule } from '../UI-Lib/ACE/ace.module';\r\nimport { AdminComponent } from './admin.component';\r\nimport { ManageAPIKeysService } from './ManageAPIKeys/manage-api-keys.service';\r\nimport { ManageAPIKeysComponent } from './ManageAPIKeys/manage-api-keys.component';\r\nimport { LoginManagerComponent } from './LoginManager/loginManager.component';\r\nimport { APIKeyDetailComponent } from './ManageAPIKeys/api-key-detail.component';\r\nimport { AboutComponent } from './About/about.component';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { DXPService } from './DXP/dxp.service';\r\nimport { AboutService } from './About/about.service';\r\nimport { TestDXPPageComponent } from './DXP/testDXPPage.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n AceModule,\r\n CommonModule,\r\n FormsModule,\r\n CompanyModule,\r\n UIRouterUpgradeModule\r\n ],\r\n exports: [AdminComponent],\r\n declarations: [\r\n AdminComponent,\r\n ManageAPIKeysComponent,\r\n LoginManagerComponent,\r\n APIKeyDetailComponent,\r\n AboutComponent,\r\n TestDXPPageComponent\r\n ],\r\n providers: [\r\n ManageAPIKeysService,\r\n DXPService,\r\n AboutComponent,\r\n AboutService\r\n ]\r\n})\r\nexport class AdminModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('admin', AdminComponent);\r\n hybridAdapterUtility.downgradeNg2Component('manageApiKeys', ManageAPIKeysComponent);\r\n hybridAdapterUtility.downgradeNg2Component('loginManager', LoginManagerComponent);\r\n hybridAdapterUtility.downgradeNg2Component('about', AboutComponent);\r\n hybridAdapterUtility.downgradeNg2Component('apiKeyDetail', APIKeyDetailComponent);\r\n hybridAdapterUtility.downgradeNg2Component('testDxpPage', TestDXPPageComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('manageApiKeysService', ManageAPIKeysService);\r\n hybridAdapterUtility.downgradeNg2Provider('dxpService', DXPService);\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { AuthStorageService, StorageTokenKeys } from '../User/authStorage.service';\r\nimport { NavigationService } from './navigation.service';\r\nimport { AppStateService, AppStates } from './appStateService';\r\nimport { filter } from 'rxjs/operators';\r\nimport { AceAuthOidcWrapperService } from '../IAM/aceAuthOidcWrapper.service';\r\nimport { RouteService } from '../Common/Routing/route.service';\r\n\r\n@Component({\r\n selector: 'logout-message',\r\n template: `\r\n
\r\n
\r\n

Logging out...

\r\n
\r\n
\r\n

{{logoutMessage}}

\r\n Click here to log back in\r\n Log out and try again\r\n
\r\n
`\r\n})\r\nexport class LogoutMessageComponent implements OnInit {\r\n constructor(\r\n public authStorageService: AuthStorageService,\r\n private _appStateService: AppStateService,\r\n private _navigationService: NavigationService,\r\n private _aceAuthOidcWrapperService: AceAuthOidcWrapperService,\r\n private _routeService: RouteService\r\n ) { }\r\n\r\n logoutMessage: string;\r\n loggingOut: boolean;\r\n\r\n ngOnInit() {\r\n this.loggingOut = false;\r\n this._appStateService.appState$.pipe(filter(x => x === AppStates.LoggingOut)).subscribe(() => {\r\n this.loggingOut = true;\r\n });\r\n this.authStorageService.logoutMessage$.subscribe(message => {\r\n if (message) {\r\n this.loggingOut = false;\r\n // Remove all modals (note that they won't work again until page refresh)\r\n const modals = document.getElementsByClassName('modal');\r\n for (let i = 0; i < modals.length; i++) {\r\n modals[i].remove();\r\n }\r\n const backdrops = document.getElementsByClassName('modal-backdrop');\r\n for (let i = 0; i < backdrops.length; i++) {\r\n backdrops[i].remove();\r\n }\r\n document.getElementsByTagName('body')[0].classList.remove('modal-open');\r\n // Disable navigation\r\n this._navigationService.disableNavWarning();\r\n }\r\n this.logoutMessage = message;\r\n // WK-7628 We originally had the UI clear stored refresh token data any time it detected that the user\r\n // had been forcibly logged out, but actually that's not what we want. When the user refreshes the page,\r\n // if they really have invalid login data it'll detect that case and show the login screen. However, it's\r\n // equally possible that between when this current session was terminated and the time the user clicks the\r\n // log back in button, they've re-authenticated, so don't clear that auth data here.\r\n //this.authStorageService.clearAuthData();\r\n });\r\n }\r\n\r\n async loginClick() {\r\n if (this.authStorageService.resetPathOnLogout) {\r\n window.location.hash = '';\r\n }\r\n\r\n if (localStorage[StorageTokenKeys.idleTimeoutStatus]) {\r\n delete localStorage[StorageTokenKeys.idleTimeoutStatus];\r\n this._routeService.setInitialRoute(window.location.href);\r\n await this._aceAuthOidcWrapperService.logout();\r\n return;\r\n }\r\n\r\n // Apparently force reload is deprecated? And maybe Edge does not clear the cache in this case any more?\r\n // If that's true it's immensely stupid. For now just force TypeScript to complie this, but perhaps we\r\n // need to investigate yet more ridiculous hacks to work around broken browser caching behavior.\r\n (window.location).reload(true);\r\n }\r\n\r\n async iamLogoutClick() {\r\n await this._aceAuthOidcWrapperService.logout();\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const NUB_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'nub.action-view',\r\n tooltipText: 'Show Action View Results'\r\n },\r\n {\r\n helpContentId: 'nub.advanced-search',\r\n tooltipText: 'SMARTool Results'\r\n },\r\n {\r\n helpContentId: 'nub.quick-search',\r\n tooltipText: 'Show Search Results'\r\n }\r\n];\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, Subject } from 'rxjs';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\n\r\ninterface Nub {\r\n showNub: boolean;\r\n searchTooltip?: string;\r\n searchType?: 'quick-search' | 'advanced-search' | 'action-view';\r\n}\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class NubService {\r\n constructor(private readonly _navigationService: NavigationService) {\r\n }\r\n\r\n private _activeNub: BehaviorSubject = new BehaviorSubject({ showNub: false });\r\n private _activeNub$ = this._activeNub.asObservable();\r\n\r\n private _showQuickSearch: Subject = new Subject();\r\n private _showQuickSearch$ = this._showQuickSearch.asObservable();\r\n\r\n private _actionViewNub: Nub = {\r\n showNub: true,\r\n searchType: 'action-view',\r\n searchTooltip: 'nub.action-view'\r\n };\r\n\r\n private _advancedSearchNub: Nub = {\r\n showNub: true,\r\n searchType: 'advanced-search',\r\n searchTooltip: 'nub.advanced-search'\r\n };\r\n\r\n private _quickSearchNub: Nub = {\r\n showNub: true,\r\n searchType: 'quick-search',\r\n searchTooltip: 'nub.quick-search'\r\n };\r\n\r\n get activeNub$(): Observable {\r\n return this._activeNub$;\r\n }\r\n\r\n get showQuickSearch$(): Observable {\r\n return this._showQuickSearch$;\r\n }\r\n\r\n hideNub(): void {\r\n this._activeNub.next({ showNub: false });\r\n }\r\n\r\n showActionViewNub(): void {\r\n this._activeNub.next(this._actionViewNub);\r\n }\r\n\r\n showAdvancedSearchNub(): void {\r\n this._activeNub.next(this._advancedSearchNub);\r\n }\r\n\r\n showQuickSearchNub(): void {\r\n this._activeNub.next(this._quickSearchNub);\r\n }\r\n\r\n showQuickSearch(): void {\r\n this._navigationService.quickSearchInitiator = `${this._activeNub.getValue().searchType}-nub`;\r\n this._showQuickSearch.next();\r\n }\r\n}\r\n","
\r\n \r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { AdvancedSearchPersistenceService } from '../../Search/Advanced/advancedSearchPersistence.service';\r\nimport { ActionViewPersistenceService } from '../../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { NUB_HELP } from './nub.help';\r\nimport { NubService } from './nub.service';\r\n\r\n@Component({\r\n selector: 'nub',\r\n templateUrl: './nub.component.html',\r\n styleUrls: ['./nub.component.scss']\r\n})\r\nexport class NubComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _nubService: NubService,\r\n private readonly _helpService: HelpService,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _uiRouter: UIRouter\r\n ) {\r\n }\r\n\r\n showNub: boolean;\r\n searchTooltip: string;\r\n searchType: 'quick-search' | 'advanced-search' | 'action-view';\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(NUB_HELP);\r\n this._nubService.activeNub$.pipe(takeUntil(this._destroy$))\r\n .subscribe((nub) => {\r\n this.showNub = nub.showNub;\r\n this.searchType = nub?.searchType;\r\n this.searchTooltip = nub.searchTooltip;\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n toggleSearch(): void {\r\n switch (this.searchType) {\r\n case 'quick-search':\r\n this._nubService.showQuickSearch();\r\n break;\r\n case 'advanced-search':\r\n this._productAnalyticsService.logEvent('click-smart-results-tab');\r\n this._uiRouter.stateService.transitionTo('search', this._advancedSearchPersistenceService.routeParams);\r\n break;\r\n case 'action-view':\r\n this._productAnalyticsService.logEvent('click-action-view-results-tab');\r\n this._uiRouter.stateService.transitionTo('actionview', this._actionViewPersistenceService.routeParams);\r\n break;\r\n }\r\n this._nubService.hideNub();\r\n }\r\n}\r\n","import { IAuthSettings } from '@ace/shared';\r\nimport { IPortalBrandingConfig } from '@ace/shared/src/portal/config';\r\nimport { AfterViewInit, Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { FeatureFlagsService } from '../Common/FeatureFlags/feature-flags-service';\r\nimport { AceAuthOidcWrapperService, IAuthComponentApi } from './aceAuthOidcWrapper.service';\r\n\r\n@Component({\r\n selector: 'ace-auth-oidc-wrapper',\r\n template: `\r\n \r\n \r\n `\r\n})\r\nexport class AceAuthOidcWrapperComponent implements OnInit, AfterViewInit {\r\n constructor(\r\n private _featureFlagsService: FeatureFlagsService,\r\n private _aceAuthOidcWrapperService: AceAuthOidcWrapperService\r\n ) { }\r\n\r\n @ViewChild('authElement') private _authElement: ElementRef;\r\n\r\n authSettings: IAuthSettings;\r\n\r\n branding: IPortalBrandingConfig;\r\n\r\n ngOnInit(): void {\r\n let endpoint = this._featureFlagsService.featureFlags.iamEndpoint;\r\n if (endpoint.endsWith('/')) {\r\n endpoint = endpoint.substring(0, endpoint.length - 1);\r\n }\r\n\r\n // Given something like https://identity.tax.com/identitytaxcom.onmicrosoft.com/b2c_1a_v1_signup_signin/v2.0,\r\n // use https://identity.tax.com for knownAuthorities and\r\n // https://identity.tax.com/identitytaxcom.onmicrosoft.com/b2c_1a_v1_signup_signin/v2.0 for authority. This\r\n // isn't necessary for b2clogin.com domains but for some reason is required for others.\r\n const endpointMatch = /^(https:\\/\\/[^\\/]+)(\\/.*)(\\/v2.0)$/g.exec(endpoint);\r\n\r\n this.authSettings = {\r\n authApi: `${endpoint}/.well-known/openid-configuration`,\r\n clientId: this._featureFlagsService.featureFlags.iamAudience,\r\n // window.location.origin is something like http://localhost:9006 or https://propertypoint.tax\r\n redirectUri: window.location.origin,\r\n homeRealmDiscovery: true,\r\n postLogoutRedirectUri: window.location.origin,\r\n immediatelyStartAuthentication: this._aceAuthOidcWrapperService.autoStartLogin,\r\n overrideAuthResponse: true,\r\n authority: `${endpointMatch[1]}${endpointMatch[2]}`,\r\n knownAuthorities: [endpointMatch[1]]\r\n };\r\n\r\n this.branding = {\r\n logoUrl: 'https://www.ryan.com/globalassets/ryan-global-logo.png',\r\n logoTitle: 'Ryan',\r\n logoHeight: 45\r\n };\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this._aceAuthOidcWrapperService.authElement$.next(this._authElement.nativeElement);\r\n }\r\n}\r\n","\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { NavigationService } from './Layout/navigation.service';\r\nimport { AccountService } from './User/account.service';\r\nimport { setTheme } from 'ngx-bootstrap/utils';\r\nimport { HostListener } from '@angular/core';\r\nimport { FeatureFlagsService } from './Common/FeatureFlags/feature-flags-service';\r\nimport { AuthenticationResult } from '@azure/msal-browser';\r\nimport { SettingsService } from './Common/Settings/settings.service';\r\nimport { AppStateService, AppStates } from './Layout/appStateService';\r\nimport { ScriptLoaderService, ScriptLocations } from './UI-Lib/Utilities/scriptLoader.service';\r\nimport { AceAuthOidcWrapperService } from './IAM/aceAuthOidcWrapper.service';\r\nimport { filter } from 'rxjs';\r\nimport { EasyAccessService } from './Common/Services/easyAccess.service';\r\n\r\n@Component({\r\n selector: 'app-root',\r\n templateUrl: './app.component.html'\r\n})\r\nexport class AppComponent implements OnInit {\r\n constructor(\r\n public _featureFlagsService: FeatureFlagsService,\r\n private readonly _accountService: AccountService,\r\n private readonly _settingsService: SettingsService,\r\n private readonly _appStateService: AppStateService,\r\n private readonly _scriptLoaderService: ScriptLoaderService,\r\n private readonly _aceAuthOidcWrapperService: AceAuthOidcWrapperService,\r\n private readonly _easyAccessService: EasyAccessService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _router: UIRouter\r\n ) {\r\n this.aceOidcWrapperEnabled = false;\r\n this.isAttachmentPopup = window.location.href.indexOf('#/attachmentPopup') >= 0;\r\n this._appStateService.appState$.subscribe(s => this.appState = s);\r\n setTheme('bs5');\r\n }\r\n\r\n aceOidcWrapperEnabled: boolean;\r\n isAttachmentPopup: boolean;\r\n appState: AppStates;\r\n get AppStates() : typeof AppStates {\r\n return AppStates;\r\n }\r\n\r\n @HostListener('window:authResponseOverride')\r\n handleAuthResponseOverride() {\r\n this._accountService.beginHomeRealmDiscovery();\r\n }\r\n\r\n @HostListener('window:authResponse', ['$event.detail'])\r\n handleAuthresponse(result: AuthenticationResult) {\r\n if (\r\n this._featureFlagsService.featureFlags.enableIAMLogin &&\r\n this.appState === AppStates.Initializing &&\r\n result &&\r\n result.idToken\r\n ) {\r\n console.log('authResponse', result);\r\n this._accountService.loginFromAceOidc(result.idToken);\r\n }\r\n }\r\n\r\n async ngOnInit() {\r\n const windowRef = <{\r\n gmapsLoaded: () => void,\r\n weissmanNg1Bootstrap: () => void,\r\n easyAccess: EasyAccessService\r\n }>(window as any);\r\n\r\n windowRef.gmapsLoaded = () => { return null; };\r\n windowRef.easyAccess = this._easyAccessService;\r\n console.log('Debugging/troubleshooting tools are available on the window.easyAccess object');\r\n\r\n this._scriptLoaderService.loadScript(ScriptLocations.GoogleMaps, false);\r\n this._aceAuthOidcWrapperService.authWrapperEnabled$.pipe(filter(x => x)).subscribe(() => {\r\n this.aceOidcWrapperEnabled = true;\r\n });\r\n\r\n this._router.transitionService.onStart({}, (transition) => this._navigationService.onNavStart(transition));\r\n await this._settingsService.Load();\r\n await this._accountService.checkPersistedLogin();\r\n windowRef.weissmanNg1Bootstrap();\r\n }\r\n}\r\n","\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport { Constants } from '../constants.new';\r\nimport { ForecastBudgetModeType, BudgetModeViewType, ForecastBudgetEditRequest, ForecastBudgetAltAssessmentView } from './forecasting.budgeting.model';\r\n\r\n@Component({\r\n selector: 'forecasting-budgeting-bulk-update-modal',\r\n templateUrl: './forecasting.budgeting.bulk.update.modal.component.html',\r\n})\r\nexport class ForecastingBudgetingBulkUpdateModalComponent implements OnInit {\r\n constructor(\r\n public constants: Constants,\r\n private bsModalRef: BsModalRef\r\n ) { }\r\n\r\n onClose: (result?: ForecastBudgetEditRequest) => void;\r\n selectedCount: number;\r\n yearBegin: number;\r\n yearEnd: number;\r\n selectedMode: ForecastBudgetModeType;\r\n selectedView: BudgetModeViewType;\r\n isFrozen: boolean = false;\r\n selectedAltAsmtView: ForecastBudgetAltAssessmentView;\r\n\r\n headerLabel: string;\r\n fmvValueLabel: string;\r\n yoyPercentLabel: string;\r\n fmvValueDisplay: string = '';\r\n yoyPercentDisplay: string = '';\r\n\r\n editReq: ForecastBudgetEditRequest = new ForecastBudgetEditRequest();\r\n availableEditActions: Compliance.NameValuePair[];\r\n selectableTaxYears: number[];\r\n\r\n commonEditActions: Compliance.NameValuePair[] =\r\n [\r\n { name: '--select an Action--', value: Core.ForecastBudgetEditActionEnum.None }\r\n ];\r\n totalFmvEditActions: Compliance.NameValuePair[] =\r\n [\r\n { name: 'Set Total FMV', value: Core.ForecastBudgetEditActionEnum.SetTotalFMV },\r\n { name: 'Set YoY % Total FMV', value: Core.ForecastBudgetEditActionEnum.SetYoyPctTotalFMV },\r\n { name: 'Distribute Total FMV', value: Core.ForecastBudgetEditActionEnum.DistribTotalFMV }\r\n ];\r\n altFmvEditActions: Compliance.NameValuePair[] =\r\n [\r\n { name: 'Set Alt FMV', value: Core.ForecastBudgetEditActionEnum.SetAltFMV },\r\n { name: 'Set YoY % Alt FMV', value: Core.ForecastBudgetEditActionEnum.SetYoyPctAltFMV },\r\n { name: 'Distribute Alt FMV', value: Core.ForecastBudgetEditActionEnum.DistribAltFMV }\r\n ];\r\n budgetModeTaxYearSpecificEditActions: Compliance.NameValuePair[] =\r\n [\r\n { name: 'Freeze Budget', value: Core.ForecastBudgetEditActionEnum.Freeze },\r\n { name: 'Unfreeze Budget', value: Core.ForecastBudgetEditActionEnum.Unfreeze },\r\n { name: 'Create Missing Budget', value: Core.ForecastBudgetEditActionEnum.CreateMissingBudget },\r\n { name: 'Sync Budget', value: Core.ForecastBudgetEditActionEnum.SyncBudget }\r\n ];\r\n\r\n\r\n async ngOnInit() {\r\n const years = _.range(this.yearBegin,\r\n this.yearEnd + 1);\r\n this.selectableTaxYears = _.chain(years)\r\n .reverse()\r\n .value();\r\n\r\n this.editReq.details.taxYear = this.yearEnd;\r\n this.availableEditActions = _.cloneDeep(this.commonEditActions);\r\n if ( this.selectedAltAsmtView !== ForecastBudgetAltAssessmentView.ShowOnlyAlternates ) {\r\n this.availableEditActions = _.concat(this.availableEditActions, _.cloneDeep(this.totalFmvEditActions));\r\n }\r\n if ( this.selectedAltAsmtView === ForecastBudgetAltAssessmentView.Show ||\r\n this.selectedAltAsmtView === ForecastBudgetAltAssessmentView.ShowOnlyAlternates ) {\r\n this.availableEditActions = _.concat(this.availableEditActions, _.cloneDeep(this.altFmvEditActions));\r\n }\r\n if ( this.selectedMode === 'forecast' ) {\r\n this.headerLabel = `Bulk Update ${this.selectedCount} Forecasting entries`;\r\n }\r\n else if ( this.selectedMode === 'budget' && this.selectedView === 'taxYear' ) {\r\n this.headerLabel = `Bulk Update ${this.selectedCount} Budgeting entries`;\r\n if ( !this.isFrozen ) {\r\n this.availableEditActions = _.concat(this.availableEditActions, _.cloneDeep(this.budgetModeTaxYearSpecificEditActions));\r\n }\r\n }\r\n this.editReq.details.editAction = Core.ForecastBudgetEditActionEnum.None;\r\n this.editReq.details.taxYear = this.yearEnd;\r\n\r\n this.yoyPercentDisplay = new Decimal(0).toFixed(4);\r\n }\r\n\r\n editActionChanged()\r\n {\r\n switch ( this.editReq.details.editAction )\r\n {\r\n case Core.ForecastBudgetEditActionEnum.SetTotalFMV:\r\n case Core.ForecastBudgetEditActionEnum.DistribTotalFMV:\r\n {\r\n this.fmvValueLabel = 'Fair Market Value (Total):';\r\n this.yoyPercentLabel = '';\r\n }\r\n break;\r\n case Core.ForecastBudgetEditActionEnum.SetAltFMV:\r\n case Core.ForecastBudgetEditActionEnum.DistribAltFMV:\r\n {\r\n this.fmvValueLabel = 'Fair Market Value (Alt):';\r\n this.yoyPercentLabel = '';\r\n }\r\n break;\r\n case Core.ForecastBudgetEditActionEnum.SetYoyPctTotalFMV:\r\n {\r\n this.fmvValueLabel = '';\r\n this.yoyPercentLabel = 'YoY % Change (Total):';\r\n }\r\n break;\r\n case Core.ForecastBudgetEditActionEnum.SetYoyPctAltFMV:\r\n {\r\n this.fmvValueLabel = '';\r\n this.yoyPercentLabel = 'YoY % Change (Alt):';\r\n }\r\n break;\r\n\r\n case Core.ForecastBudgetEditActionEnum.Freeze:\r\n case Core.ForecastBudgetEditActionEnum.Unfreeze:\r\n case Core.ForecastBudgetEditActionEnum.CreateMissingBudget:\r\n case Core.ForecastBudgetEditActionEnum.SyncBudget:\r\n default:\r\n {\r\n this.fmvValueLabel = '';\r\n this.yoyPercentLabel = '';\r\n }\r\n break;\r\n }\r\n }\r\n\r\n isTaxYearEnabled() : boolean {\r\n return this.isFmvValueEnabled() || this.isYoYPercentEnabled();\r\n }\r\n\r\n isFmvValueEnabled() : boolean {\r\n return( this.editReq.details.editAction == Core.ForecastBudgetEditActionEnum.SetTotalFMV ||\r\n this.editReq.details.editAction == Core.ForecastBudgetEditActionEnum.SetAltFMV ||\r\n this.editReq.details.editAction == Core.ForecastBudgetEditActionEnum.DistribTotalFMV ||\r\n this.editReq.details.editAction == Core.ForecastBudgetEditActionEnum.DistribAltFMV );\r\n }\r\n\r\n isYoYPercentEnabled() : boolean {\r\n return( this.editReq.details.editAction == Core.ForecastBudgetEditActionEnum.SetYoyPctTotalFMV ||\r\n this.editReq.details.editAction == Core.ForecastBudgetEditActionEnum.SetYoyPctAltFMV );\r\n }\r\n\r\n fmvValueBlur(currentValue: string): void {\r\n if ( this._isValidNumericValue(this.fmvValueDisplay) )\r\n {\r\n this.fmvValueDisplay = new Decimal(this.fmvValueDisplay).round().toString();\r\n }\r\n else\r\n {\r\n this.fmvValueDisplay = '';\r\n }\r\n }\r\n\r\n yoyPercentBlur(currentValue: string): void {\r\n if ( !this._isValidNumericValue(this.yoyPercentDisplay) )\r\n {\r\n this.yoyPercentDisplay = '0.0';\r\n }\r\n this.yoyPercentDisplay = new Decimal(this.yoyPercentDisplay).toFixed(4);\r\n }\r\n\r\n\r\n isSaveable(): boolean {\r\n if ( this.editReq.details.editAction === Core.ForecastBudgetEditActionEnum.None )\r\n {\r\n return false;\r\n }\r\n\r\n if ( this.isTaxYearEnabled() )\r\n {\r\n return this.editReq.details.taxYear !== undefined &&\r\n this.editReq.details.taxYear !== null &&\r\n this.editReq.details.taxYear > 0;\r\n }\r\n\r\n let saveable = false;\r\n if ( this.isFmvValueEnabled() )\r\n {\r\n saveable = this._isValidNumericValue(this.fmvValueDisplay) &&\r\n (new Decimal(this.fmvValueDisplay).toNumber()) >= 0;\r\n }\r\n else if ( this.isYoYPercentEnabled() )\r\n {\r\n saveable = this._isValidNumericValue(this.yoyPercentDisplay);\r\n }\r\n else {\r\n saveable = true;\r\n }\r\n return saveable;\r\n }\r\n\r\n\r\n async save(): Promise {\r\n if ( this.isFmvValueEnabled() )\r\n {\r\n this.editReq.details.valueFMV = new Decimal(this.fmvValueDisplay).round().toNumber();\r\n }\r\n if ( this.isYoYPercentEnabled() )\r\n {\r\n this.editReq.details.yoyPercentFMV = new Decimal(this.yoyPercentDisplay).dividedBy(100).toNumber();\r\n }\r\n\r\n this.bsModalRef.hide();\r\n\r\n this.onClose(this.editReq);\r\n }\r\n\r\n cancel() {\r\n this.bsModalRef.hide();\r\n\r\n this.onClose();\r\n }\r\n\r\n private _isValidNumericValue(value: string): boolean {\r\n value = _.trim(value);\r\n\r\n if (this._isInvalidNumber(value))\r\n return false;\r\n\r\n if (isNaN(Number(value)))\r\n return false;\r\n\r\n return true;\r\n }\r\n\r\n\r\n private _isInvalidNumber(value: string): boolean {\r\n return value === undefined || value === null || value === '' || value === '.';\r\n }\r\n}\r\n","\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment';\r\nimport { Constants } from '../constants.new';\r\nimport { MessageBoxService, MessageBoxButtons } from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { ForecastingBudgetingService } from './forecasting.budgeting.service';\r\n\r\nclass FiscalPeriodEntry {\r\n year: number;\r\n period: string;\r\n}\r\n\r\n@Component({\r\n selector: 'add-company-budget-modal',\r\n templateUrl: './add.company.budget.modal.component.html'\r\n})\r\nexport class AddCompanyBudgetModalComponent implements OnInit {\r\n constructor(\r\n private bsModalRef: BsModalRef,\r\n public constants: Constants,\r\n private messageBoxService: MessageBoxService,\r\n private toastr: ToastrService,\r\n private budgetingService: ForecastingBudgetingService\r\n ) { }\r\n\r\n onClose: (result?: Core.CompanyBudgetDTO) => void;\r\n\r\n tlCompany: Core.CompanyRecordDTO;\r\n\r\n budgetName: string;\r\n fiscalStartYear: number;\r\n budgetDate: Date;\r\n\r\n addInProgress: boolean = false;\r\n availableFiscalPeriods: FiscalPeriodEntry[];\r\n existingBudgets: Core.AvailableCompanyBudget[] = [];\r\n\r\n\r\n async ngOnInit() {\r\n const currentYear: number = Number(moment().format('YYYY'));\r\n\r\n this.budgetName = '';\r\n\r\n this.fiscalStartYear = currentYear;\r\n\r\n const years = _.range(2019, currentYear + 6);\r\n this.availableFiscalPeriods = _.map(years, (year) => {\r\n const strFYBegin = `${this.tlCompany.fiscalYearStart }/${ year}`;\r\n console.log(this.tlCompany);\r\n const momFYStart = moment(strFYBegin).startOf('day').format('MM/DD/YYYY');\r\n const momFYEnd = moment(momFYStart).add(1, 'year').subtract(1, 'day').format('MM/DD/YYYY');\r\n return {\r\n year: year,\r\n period: `${momFYStart} - ${momFYEnd}`\r\n };\r\n }).reverse();\r\n\r\n // Retrieve existing Budget Names for tlCompanyId for validation\r\n console.log('tlCompanyId', this.tlCompany.companyID);\r\n this.existingBudgets = await this.budgetingService.getAvailableCompanyBudgets(this.tlCompany.companyID, false);\r\n console.log('existingBudgets', this.existingBudgets);\r\n }\r\n\r\n isSaveable(): boolean {\r\n return (this.budgetName != undefined && this.budgetName != null && _.trim(this.budgetName) !== '')\r\n && (this.fiscalStartYear >= 2019);\r\n }\r\n\r\n isBudgetNameUnique(): boolean {\r\n return _.some(this.existingBudgets, (entry) => {\r\n return entry.budgetName === _.trim(this.budgetName);\r\n });\r\n }\r\n\r\n\r\n async save(): Promise {\r\n this.budgetName = _.trim(this.budgetName);\r\n // Verify Budget Name doesn't exist for tlCompany\r\n const exists: boolean = this.isBudgetNameUnique();\r\n if ( exists )\r\n {\r\n console.error(`Company Budget ${this.budgetName} already exists!`);\r\n\r\n this.messageBoxService.open({\r\n title: 'Budget Already Exists!',\r\n message: 'You must enter a Budget Name that does NOT already exist for the Company.',\r\n buttons: MessageBoxButtons.OK\r\n });\r\n\r\n return;\r\n }\r\n\r\n let createdBudget: Core.CompanyBudgetDTO;\r\n this.addInProgress = true;\r\n // Add Company Budget\r\n try {\r\n createdBudget = await this.budgetingService.createCompanyBudget(this.tlCompany.companyID, this.budgetName, this.fiscalStartYear, this.budgetDate);\r\n }\r\n catch(err)\r\n {\r\n this.bsModalRef.hide();\r\n this.addInProgress = false;\r\n console.error(`ERROR adding Company Budget - ${err.message}`);\r\n this.toastr.error(`ERROR adding Company Budget - ${err.message}`);\r\n return this.onClose();\r\n }\r\n\r\n this.bsModalRef.hide();\r\n this.addInProgress = false;\r\n\r\n this.onClose(createdBudget);\r\n }\r\n\r\n cancel() {\r\n this.bsModalRef.hide();\r\n\r\n this.onClose();\r\n }\r\n}\r\n","
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n {{numMissingTaxYears}}\r\n \r\n \r\n
\r\n
\r\n","import {Component, EventEmitter, Input, Output} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'forecast-create-missing',\r\n templateUrl: './forecast.create.missing.component.html',\r\n styleUrls: ['./forecasting.budgeting.page.scss']\r\n})\r\nexport class ForecastCreateMissingComponent {\r\n @Input() numMissingTaxYears: number;\r\n @Input() lrUpdateInProgress: boolean = false;\r\n @Input() taxYear: number;\r\n @Input() editMode: boolean;\r\n @Output() createClick = new EventEmitter();\r\n\r\n createMissing() : void {\r\n this.createClick.next();\r\n }\r\n\r\n isMissingCreateAllowed() : boolean {\r\n return !this.lrUpdateInProgress &&\r\n this.numMissingTaxYears > 0;\r\n }\r\n}","
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n {{missingSyncData.numMissingTaxYears}}\r\n \r\n \r\n
\r\n \r\n \r\n {{missingSyncData.numMissingBudgets}}\r\n
\r\n
\r\n","import {Component, EventEmitter, Input, Output} from '@angular/core';\r\nimport {BudgetTaxYearMissingSyncData} from './forecasting.budgeting.model';\r\n\r\n@Component({\r\n selector: 'budget-taxyear-create-missing',\r\n templateUrl: './budget.taxyear.create.missing.component.html',\r\n styleUrls: ['./forecasting.budgeting.page.scss']\r\n})\r\nexport class BudgetTaxYearCreateMissingComponent {\r\n @Input() missingSyncData: BudgetTaxYearMissingSyncData;\r\n @Input() lrUpdateInProgress: boolean = false;\r\n @Input() taxYear: number;\r\n @Input() editMode: boolean;\r\n @Input() isBudgetFrozen: boolean;\r\n @Output() createClick = new EventEmitter();\r\n\r\n createMissing() : void {\r\n this.createClick.next();\r\n }\r\n\r\n isMissingCreateAllowed() : boolean {\r\n return !this.lrUpdateInProgress &&\r\n (this.missingSyncData.numMissingTaxYears > 0 || this.missingSyncData.numMissingBudgets > 0) &&\r\n !this.isBudgetFrozen;\r\n }\r\n}","
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n {{missingSyncData.numOutOfSyncBudgets}}\r\n \r\n \r\n
\r\n
\r\n","import {Component, EventEmitter, Input, Output} from '@angular/core';\r\nimport {BudgetTaxYearMissingSyncData} from './forecasting.budgeting.model';\r\n\r\n@Component({\r\n selector: 'budget-taxyear-sync-budgets',\r\n templateUrl: './budget.taxyear.sync.budgets.component.html',\r\n styleUrls: ['./forecasting.budgeting.page.scss']\r\n})\r\nexport class BudgetTaxYearSyncBudgetsComponent {\r\n @Input() missingSyncData: BudgetTaxYearMissingSyncData;\r\n @Input() lrUpdateInProgress: boolean = false;\r\n @Input() editMode: boolean;\r\n @Input() isBudgetFrozen: boolean;\r\n @Output() syncClick = new EventEmitter();\r\n\r\n syncBudgets() : void {\r\n this.syncClick.next();\r\n }\r\n\r\n isSyncBudgetsAllowed() : boolean {\r\n return !this.lrUpdateInProgress &&\r\n this.missingSyncData.numOutOfSyncBudgets > 0 &&\r\n !this.isBudgetFrozen;\r\n }\r\n}","
\r\n
\r\n
    \r\n
  1. \r\n {{parentCompany.name}}\r\n
  2. \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Forecasting and Budgeting

\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n

\r\n {{selectedBudget.fiscalPeriodBegin | date:'MM/dd/yyyy':'utc'}} - {{selectedBudget.fiscalPeriodEnd | date:'MM/dd/yyyy':'utc'}}\r\n

\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n\r\n \r\n \r\n \r\n \r\n \r\n
\r\n FROZEN\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Bulk Updating {{bulkUpdateEntityType}}s

\r\n

Done

\r\n \r\n

{{getCurrentBulkUpdateIdentity()}}

\r\n
\r\n
\r\n

Canceled

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n {{bulkUpdateProgress.missingTaxYearCount}}
\r\n \r\n {{bulkUpdateProgress.emptyAssessmentCount}}
\r\n \r\n {{bulkUpdateProgress.actualizedAssessmentCount}}
\r\n \r\n {{bulkUpdateProgress.parcelCount}}
\r\n \r\n {{bulkUpdateProgress.siteCount}}
\r\n \r\n {{bulkUpdateProgress.assessmentCount}}
\r\n \r\n {{bulkUpdateProgress.billCount}}
\r\n \r\n {{bulkUpdateProgress.paymentCount}}
\r\n \r\n {{bulkUpdateProgress.missingBudgetCount}}
\r\n \r\n {{bulkUpdateProgress.budgetFrozenCount}}
\r\n \r\n {{bulkUpdateProgress.budgetUnfrozenCount}}
\r\n \r\n {{bulkUpdateProgress.budgetCreatedCount}}
\r\n \r\n {{bulkUpdateProgress.budgetSyncedCount}}
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { AgGridEvent, ColumnApi, GridReadyEvent } from 'ag-grid-community';\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { BehaviorSubject, lastValueFrom, Subject, Subscription } from 'rxjs';\r\nimport { AgGridOptionsBuilder } from '../Compliance/AgGrid';\r\nimport { ForecastingBudgetingService } from './forecasting.budgeting.service';\r\nimport { CompanyService } from '../Entity/Company/company.service';\r\nimport {\r\n BudgetTaxYearMissingSyncData,\r\n CompanyBudgetBasisEnum,\r\n ForecastBudgetAltAssessmentView,\r\n ForecastBudgetAvailableFiltersUI,\r\n ForecastBudgetBulkUpdateProgress,\r\n ForecastBudgetEditRequest,\r\n ForecastBudgetScreenModeEnum,\r\n ShowAssessmentsTaxesEnum\r\n} from './forecasting.budgeting.model';\r\nimport { ForecastingBudgetingBulkUpdateModalComponent } from './forecasting.budgeting.bulk.update.modal.component';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { AddCompanyBudgetModalComponent } from './add.company.budget.modal.component';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../Compliance/AgGrid/ToolPanel/models';\r\nimport { InstanceRights, RestrictService } from '../Common/Permissions/restrict.service';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../Busy-Indicator';\r\nimport { LongRunningProcessRepository } from '../Compliance/Repositories';\r\nimport { AccountService } from '../User/account.service';\r\nimport { ColumnState } from 'ag-grid-community/dist/lib/columnController/columnController';\r\nimport { InstanceRepository } from '../Entity/Instance/instance.repository';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\nexport type ForecastingBudgetingView = 'taxYear' | 'accrualAndCash';\r\n\r\n@Component({\r\n selector: 'forecasting-budgeting-page',\r\n templateUrl: './forecasting.budgeting.page.component.html',\r\n styleUrls: ['./forecasting.budgeting.page.scss'],\r\n providers: [ForecastingBudgetingService]\r\n})\r\nexport class ForecastingBudgetingPageComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private modalService: BsModalService,\r\n private toastr: ToastrService,\r\n private messageBoxService: MessageBoxService,\r\n public forecastingBudgetingService: ForecastingBudgetingService,\r\n public companyService: CompanyService,\r\n private restrictService: RestrictService,\r\n private upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private _busyIndicatorService: BusyIndicatorService,\r\n private longRunningProcessRepository: LongRunningProcessRepository,\r\n private accountService: AccountService,\r\n private instanceRepository: InstanceRepository\r\n ) {\r\n this._lrTypeMapping[Compliance.LongRunningProcessTypeEnum.SyncBudgets] = 'Syncing parcel budgets';\r\n this._lrTypeMapping[Compliance.LongRunningProcessTypeEnum.AddMissingForecastTaxYear] = 'Creating missing forecast tax years';\r\n this._lrTypeMapping[Compliance.LongRunningProcessTypeEnum.AddTaxYearAndAnnualBudget] = 'Creating missing budget tax years';\r\n }\r\n\r\n subscriptions: Subscription[];\r\n isMaximized: boolean = false;\r\n isInitialized: boolean = false;\r\n budgetsEnabled: boolean = false;\r\n hasEditPermission: boolean = false;\r\n showBudgetApplyButton: boolean = false;\r\n savingBudget: boolean = false;\r\n showFilterApplyButton: boolean = true;\r\n\r\n ForecastBudgetScreenModeEnum = ForecastBudgetScreenModeEnum;\r\n CompanyBudgetBasisEnum = CompanyBudgetBasisEnum;\r\n\r\n scopeEntityTypeId: number = Core.EntityTypes.Company;\r\n scopeEntityId: number = 0;\r\n\r\n taxYears: number[] = _.range(new Date().getFullYear() + 5, new Date().getFullYear() - 11);\r\n priorOptions: number[] = [1, 2, 3, 4];\r\n priorYears: number;\r\n\r\n availableBudgets: Core.AvailableCompanyBudget[] = [];\r\n\r\n ShowAssessmentsTaxesEnum = ShowAssessmentsTaxesEnum;\r\n ForecastBudgetAltAssessmentView = ForecastBudgetAltAssessmentView;\r\n\r\n availableFilters: ForecastBudgetAvailableFiltersUI = new ForecastBudgetAvailableFiltersUI();\r\n parentCompany: Core.NameIdPair;\r\n\r\n lrUpdateInProgress: boolean = false;\r\n\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n bulkUpdateInProgress: boolean = false;\r\n bulkUpdateCanceled: boolean = false;\r\n bulkUpdateProgress: ForecastBudgetBulkUpdateProgress = new ForecastBudgetBulkUpdateProgress();\r\n bulkUpdateEntityType: string = '';\r\n\r\n LARGE_BULK_UPDATE_THRESHOLD: number = 100;\r\n\r\n filterModel: any;\r\n columnState: ColumnState[];\r\n columnApi: ColumnApi;\r\n\r\n gridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true,\r\n singleClickEdit: true,\r\n suppressRowClickSelection: true,\r\n suppressMovableColumns: true,\r\n onGridColumnsChanged: () => {\r\n this.gridApi.sizeColumnsToFit();\r\n },\r\n onSelectionChanged: () => {\r\n this.forecastingBudgetingService.updateTotals();\r\n },\r\n onFilterChanged: () => {\r\n this.forecastingBudgetingService.updateTotals();\r\n },\r\n onCellEditingStarted: () => {\r\n this.forecastingBudgetingService.isEditingCell = true;\r\n },\r\n onCellEditingStopped: () => {\r\n this.forecastingBudgetingService.isEditingCell = false;\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .withVerticalScrollBar()\r\n .withoutCellEditingStoppedOnGridLostFocus()\r\n .withColumnPinning()\r\n .build();\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[]): Promise => {\r\n\r\n // Find the first dynamic column (which contains a number) and slice off the rest of the array.\r\n const dynamicColIdx = _.findIndex(columnsToReturn, col => /\\d/.test(col.name));\r\n columnsToReturn = _.slice(columnsToReturn, 0, dynamicColIdx);\r\n\r\n const request = {\r\n columnFilters: [],\r\n sortColumns: [],\r\n columnsToReturn: columnsToReturn,\r\n ...this.forecastGridSearchModel\r\n } as any;\r\n\r\n const longRunningProcessId = await this.forecastingBudgetingService.exportToExcel(request);\r\n\r\n return { longRunningProcessId, longRunningProcessTypeId: Compliance.LongRunningProcessTypeEnum.ExportBudgetGridToExcel };\r\n },\r\n canCancel: true\r\n };\r\n\r\n private _busyRef: BusyIndicatorRef = null;\r\n private busyRefId: string;\r\n private longRunningProcessId: number;\r\n private _lrTypeMapping: { [key: number]: string } = {};\r\n private _destroy$: Subject = new Subject();\r\n\r\n\r\n async ngOnInit() {\r\n this.subscriptions = [];\r\n this.lrUpdateInProgress = false;\r\n this.scopeEntityTypeId = Core.EntityTypes.Company;\r\n const parentCompanyId = +this.upgradeNavigationServiceHandler.getQuerystringParam('companyId');\r\n\r\n this.forecastingBudgetingService.tlCompany = await this.companyService.getTopCompanyForEntity(this.scopeEntityTypeId, parentCompanyId);\r\n console.log('tlCompany=', this.forecastingBudgetingService.tlCompany);\r\n console.log('isTLCompany=', this.isTLCompany);\r\n this.scopeEntityId = this.forecastingBudgetingService.tlCompany.companyID;\r\n\r\n this.forecastingBudgetingService.initServiceModel(this.scopeEntityTypeId, this.scopeEntityId);\r\n this.priorYears = this.filters.yearEnd - this.filters.yearBegin;\r\n\r\n await this.populateBudgetNameDropdown();\r\n\r\n const availableFilters = await this.forecastingBudgetingService.getAvailableFilters(this.scopeEntityTypeId, this.scopeEntityId);\r\n availableFilters.companies = _.sortBy(availableFilters.companies, company => company.id == this.forecastingBudgetingService.tlCompany.companyID || company.name.toLowerCase());\r\n _.assign(this.availableFilters, availableFilters);\r\n\r\n this.parentCompany = _.find(this.availableFilters.companies, {id: parentCompanyId});\r\n\r\n const lrp = await this.companyService.checkOngoingAction(this.parentCompany.id);\r\n if (lrp) {\r\n this.longRunningProcessId = lrp.longRunningProcessId;\r\n this._showBusyIndicator(this._lrTypeMapping[lrp.processType], this.longRunningProcessId, this.accountService.userData.id == lrp.createdBy);\r\n }\r\n\r\n await this._setFiltersAndLoadData();\r\n\r\n this.isInitialized = true;\r\n this.subscriptions.push(this.forecastingBudgetingService.forecastingBudgetingGridData$.subscribe((isData: boolean) => {\r\n if(isData) {\r\n this._setRowData();\r\n }\r\n }));\r\n\r\n const instanceId = await lastValueFrom(this.instanceRepository.getEntityInstanceId('company', this.parentCompany.id));\r\n this.hasEditPermission = this.restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, instanceId) &&\r\n await this.restrictService.hasCompanyPermission(this.parentCompany.id, Core.AccessRightsEnum.Write);\r\n this.budgetsEnabled = await this.forecastingBudgetingService.getAreBudgetsEnabled(this.scopeEntityTypeId, this.scopeEntityId);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n // I wanted to use the unsubscribe mixin, but piping destroy$ to takeUntil didn't work\r\n this.subscriptions.forEach(s => s.unsubscribe());\r\n }\r\n\r\n get gridApi() {\r\n return this.forecastingBudgetingService.gridApi;\r\n }\r\n\r\n set gridApi(gridApi) {\r\n this.forecastingBudgetingService.gridApi = gridApi;\r\n }\r\n\r\n get filters() {\r\n return this.forecastingBudgetingService.filters;\r\n }\r\n\r\n set filters(filters) {\r\n this.forecastingBudgetingService.filters = filters;\r\n }\r\n\r\n get selectedBudget() {\r\n return this.forecastingBudgetingService.selectedBudget;\r\n }\r\n\r\n set selectedBudget(selectedBudget) {\r\n this.forecastingBudgetingService.selectedBudget = selectedBudget;\r\n }\r\n\r\n get forecastGridSearchModel() {\r\n return this.forecastingBudgetingService.forecastGridSearchModel;\r\n }\r\n\r\n set forecastGridSearchModel(forecastGridSearchModel) {\r\n this.forecastingBudgetingService.forecastGridSearchModel = forecastGridSearchModel;\r\n }\r\n\r\n get isTLCompany() {\r\n return( this.scopeEntityTypeId != Core.EntityTypes.Company ? false : this.forecastingBudgetingService.isTLCompany(this.scopeEntityId));\r\n }\r\n\r\n get missingSyncData() {\r\n return this.forecastingBudgetingService.missingSyncData;\r\n }\r\n\r\n get freezeButtonLabel() {\r\n return this.forecastingBudgetingService.freezeButtonLabel;\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this.gridApi = event.api;\r\n this.columnApi = event.columnApi;\r\n this.gridApi.setRowData([]);\r\n }\r\n\r\n toggleEditMode(isEdit: boolean) {\r\n this.forecastingBudgetingService.editMode = isEdit;\r\n this.refreshBulkUpdateState();\r\n }\r\n\r\n onSelectionChanged(event: AgGridEvent) {\r\n this.refreshBulkUpdateState();\r\n }\r\n\r\n refreshBulkUpdateState() {\r\n const isBulkUpdateVisible = this.forecastingBudgetingService.editMode && this.gridApi.getSelectedNodes().length > 0;\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n }\r\n\r\n toggleMaximize(isMaximized: boolean): void {\r\n this.isMaximized = isMaximized;\r\n }\r\n\r\n goToParentCompany() {\r\n this.upgradeNavigationServiceHandler.go('company', {companyId: this.parentCompany.id});\r\n }\r\n\r\n async modeChanged(): Promise {\r\n console.log(`New Mode: ${this.forecastingBudgetingService.selectedMode}`);\r\n this.forecastingBudgetingService.clearData();\r\n this.refreshBulkUpdateState();\r\n\r\n if ( this.forecastingBudgetingService.selectedMode === 'budget' ) {\r\n this.forecastGridSearchModel.mode = ForecastBudgetScreenModeEnum.TaxYearBudget;\r\n this.forecastGridSearchModel.showBudgetEntriesFor = ShowAssessmentsTaxesEnum.AssessmentsAndTaxes;\r\n this.priorYears = 1;\r\n if ( this.selectedBudget ) {\r\n this.filters.yearEnd = moment.utc(this.selectedBudget.fiscalPeriodBegin).year();\r\n }\r\n this.filters.yearBegin = this.filters.yearEnd - this.priorYears;\r\n\r\n // Switched to Budget mode.\r\n // Clear any old selection and populate Budget Name dropdown.\r\n\r\n await this.populateBudgetNameDropdown(this.selectedBudget ? this.selectedBudget.budgetName : undefined);\r\n } else {\r\n this.forecastGridSearchModel.mode = ForecastBudgetScreenModeEnum.Forecast;\r\n this.forecastGridSearchModel.showBudgetEntriesFor = ShowAssessmentsTaxesEnum.AssessmentsAndTaxes;\r\n }\r\n\r\n //await this.loadNewColumnData();\r\n this.showFilterApplyButton = true;\r\n // TODO Re-retrieve grid content and missing/sync counts for new mode.\r\n }\r\n\r\n async populateBudgetNameDropdown(selectName?: string) : Promise {\r\n if ( this.forecastingBudgetingService.selectedMode === 'budget' )\r\n {\r\n // Get availableBudgets for company from Get Available Company Budgets\r\n const availableBudgets = await this.forecastingBudgetingService.getAvailableCompanyBudgets(this.forecastingBudgetingService.tlCompany.companyID, false);\r\n this.availableBudgets = _.orderBy(availableBudgets, ['budgetDate', 'budgetName'], ['desc', 'asc']);\r\n\r\n if ( this.selectedBudget && selectName )\r\n {\r\n // Clear Budget selection if no longer present in dropdown.\r\n const stillPresent = _.some(this.availableBudgets, (entry) => {\r\n return entry.budgetName === selectName;\r\n });\r\n\r\n if ( !stillPresent )\r\n {\r\n this.selectedBudget = undefined;\r\n }\r\n else\r\n {\r\n // Even though the budget is already set, we need to set it from the available budgets\r\n // so that the dropdown will correctly set\r\n this.selectedBudget = _.find(this.availableBudgets, {companyBudgetId: this.selectedBudget.companyBudgetId});\r\n }\r\n }\r\n else if ( selectName )\r\n {\r\n // Select the Budget for the given date, if present.\r\n this.selectedBudget = _.find(this.availableBudgets, (entry) => {\r\n return entry.budgetName === selectName;\r\n });\r\n\r\n this.selectedBudgetChanged();\r\n }\r\n else if ( !selectName )\r\n {\r\n this.selectedBudget = undefined;\r\n }\r\n }\r\n }\r\n\r\n selectedBudgetChanged(): void {\r\n console.log(`Selected: ${this.selectedBudget.budgetName} - ${this.selectedBudget.companyBudgetId} - ${moment(this.selectedBudget.fiscalPeriodBegin).utc().format('MM/DD/YYYY')}..${moment(this.selectedBudget.fiscalPeriodEnd).utc().format('MM/DD/YYYY')}`);\r\n\r\n this.forecastGridSearchModel.companyBudgetId = this.selectedBudget.companyBudgetId;\r\n this.forecastGridSearchModel.budgetBasis = this.selectedBudget.budgetBasis;\r\n this.filters.yearEnd = moment.utc(this.selectedBudget.fiscalPeriodEnd).year();\r\n this.filters.yearBegin = this.filters.yearEnd - this.priorYears;\r\n if(this.selectedBudget.isFrozen) {\r\n this.forecastingBudgetingService.autoSyncBudgetToLatest = false;\r\n }\r\n\r\n this.taxYearsChanged();\r\n }\r\n\r\n selectedBudgetBasisChanged() {\r\n this.forecastGridSearchModel.budgetBasis = this.selectedBudget.budgetBasis;\r\n this.showBudgetApplyButton = true;\r\n }\r\n\r\n async saveCompanyBudget() {\r\n this.savingBudget = true;\r\n\r\n try {\r\n this.showBudgetApplyButton = false;\r\n await this.forecastingBudgetingService.saveCompanyBudget();\r\n this.toastr.info('Budget Basis Saved!');\r\n this.loadNewColumnData();\r\n } finally {\r\n this.savingBudget = false;\r\n }\r\n }\r\n\r\n addNewBudget(): void {\r\n const initialState = {\r\n tlCompany: this.forecastingBudgetingService.tlCompany\r\n };\r\n const modalRef = this.modalService.show(AddCompanyBudgetModalComponent, {initialState, class: 'modal-sd', ignoreBackdropClick: true});\r\n\r\n modalRef.content.onClose = this.newBudgetAdded.bind(this);\r\n }\r\n\r\n async newBudgetAdded(result?: Core.CompanyBudgetDTO) : Promise {\r\n if ( result )\r\n {\r\n this.selectedBudget = undefined;\r\n console.log(`Added: ${result.budgetName} - ${result.companyBudgetId} - ${moment(result.fiscalPeriodBegin).utc().format('MM/DD/YYYY')}..${moment(result.fiscalPeriodEnd).utc().format('MM/DD/YYYY')}`);\r\n\r\n // Refresh availableBudgets and select added date.\r\n // This indirectly will trigger loadNewColumnData() to refresh grid and counts.\r\n await this.populateBudgetNameDropdown( result.budgetName );\r\n }\r\n }\r\n\r\n companiesSelected(eventTarget: EventTarget): void {\r\n this.availableFilters.states = this.availableFilters.propertyTypes = this.availableFilters.activityStatuses = [];\r\n this.filters.companyIds = _.map((eventTarget as HTMLSelectElement).selectedOptions, (option: any) => Number(option.value));\r\n\r\n this._setFiltersAndLoadData();\r\n }\r\n\r\n statesSelected(eventTarget: EventTarget): void {\r\n this.filters.stateIds = _.map((eventTarget as HTMLSelectElement).selectedOptions, (option: any) => Number(option.value));\r\n\r\n //this.loadNewColumnData();\r\n this.filterChanged();\r\n }\r\n\r\n propertyTypesSelected(eventTarget: EventTarget) {\r\n this.filters.propertyTypeIds = _.map((eventTarget as HTMLSelectElement).selectedOptions, (option: any) => Number(option.value));\r\n\r\n //this.loadNewColumnData();\r\n this.filterChanged();\r\n }\r\n\r\n activityStatusesSelected(eventTarget: EventTarget) {\r\n this.filters.activityStatusIds = _.map((eventTarget as HTMLSelectElement).selectedOptions, (option: any) => Number(option.value));\r\n\r\n //this.loadNewColumnData();\r\n this.filterChanged();\r\n }\r\n\r\n async taxYearsChanged() {\r\n this.filters.yearBegin = this.filters.yearEnd - this.priorYears;\r\n\r\n //this.loadNewColumnData();\r\n this.filterChanged();\r\n }\r\n\r\n filterChanged() {\r\n this.showFilterApplyButton = true;\r\n }\r\n\r\n async deleteBudget(): Promise {\r\n const msgBoxResult = await this.messageBoxService.open({\r\n title: 'WARNING',\r\n message: 'Deleting the Budget will delete ALL corresponding Budget entries on Parcels, frozen or unfrozen. Are you sure you want to delete the ENTIRE Budget?',\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n\r\n if (msgBoxResult === MessageBoxResult.Yes) {\r\n await this.forecastingBudgetingService.deleteCompanyBudget(this.selectedBudget.companyBudgetId);\r\n\r\n this.forecastingBudgetingService.clearData();\r\n await this.populateBudgetNameDropdown();\r\n }\r\n }\r\n\r\n async applyFilters() {\r\n await this.loadNewColumnData();\r\n }\r\n\r\n async refresh() {\r\n this.gridApi.showLoadingOverlay();\r\n await this.forecastingBudgetingService.loadData();\r\n this.gridApi.hideOverlay();\r\n this.showFilterApplyButton = false;\r\n }\r\n\r\n async createMissingForecast(): Promise {\r\n this.lrUpdateInProgress = true;\r\n this._showBusyIndicator('Creating missing forecast tax years', null);\r\n\r\n try {\r\n const lrp = await this.forecastingBudgetingService.startCreateMissingForecast({\r\n taxYear: this.filters.yearEnd,\r\n topLevelCompanyId: this.forecastingBudgetingService.tlCompany.companyID,\r\n companyIds: this.filters.companyIds,\r\n propertyTypeIds: this.filters.propertyTypeIds,\r\n stateIds: this.filters.stateIds\r\n });\r\n this.longRunningProcessId = lrp.longRunningProcessId;\r\n await this._busyRef.setLongRunningProcessId(this.longRunningProcessId);\r\n } catch (err) {\r\n await this._hideBusyIndicator();\r\n this.lrUpdateInProgress = false;\r\n\r\n }\r\n }\r\n\r\n async createMissingBudgetTaxYear(): Promise {\r\n // Display a popup to confirm that the user wants to add a Budget to\r\n // any Pending parcels in the grid, if applicable.\r\n const proceed: boolean = await this.confirmActionOnPendingStatus();\r\n if ( !proceed )\r\n {\r\n console.log('Create Missing Budgets for Pending parcels NOT confirmed by user!');\r\n return;\r\n }\r\n\r\n this.lrUpdateInProgress = true;\r\n this._showBusyIndicator('Creating missing budget tax years', null);\r\n\r\n try {\r\n const lrp = await this.forecastingBudgetingService.startCreateMissingBudgetTaxYear({\r\n // TODO: Hook this up (honestly not sure what it is)\r\n cashPayEarlyAdjustment: 0,\r\n companyIds: this.filters.companyIds,\r\n propertyTypeIds: this.filters.propertyTypeIds,\r\n activityStatusIds: this.filters.activityStatusIds,\r\n stateIds: this.filters.stateIds,\r\n companyBudgetId: this.selectedBudget.companyBudgetId,\r\n topLevelCompanyId: this.forecastingBudgetingService.tlCompany.companyID,\r\n budgetBasis: this.selectedBudget.budgetBasis\r\n } as Core.BudgetMissingTaxYearAndAnnualBudgetRequest);\r\n this.longRunningProcessId = lrp.longRunningProcessId;\r\n await this._busyRef.setLongRunningProcessId(this.longRunningProcessId);\r\n } catch (err) {\r\n await this._hideBusyIndicator();\r\n this.lrUpdateInProgress = false;\r\n\r\n }\r\n }\r\n\r\n async syncBudgets(): Promise {\r\n this.lrUpdateInProgress = true;\r\n this._showBusyIndicator('Syncing parcel budgets', null);\r\n\r\n try {\r\n const lrp = await this.forecastingBudgetingService.startSyncBudgets({\r\n // TODO: Hook this up (honestly not sure what it is)\r\n cashPayEarlyAdjustment: 0,\r\n companyIds: this.filters.companyIds,\r\n propertyTypeIds: this.filters.propertyTypeIds,\r\n activityStatusIds: this.filters.activityStatusIds,\r\n stateIds: this.filters.stateIds,\r\n companyBudgetId: this.selectedBudget.companyBudgetId,\r\n topLevelCompanyId: this.forecastingBudgetingService.tlCompany.companyID,\r\n budgetBasis: this.selectedBudget.budgetBasis\r\n } as Core.BudgetMissingTaxYearAndAnnualBudgetRequest);\r\n this.longRunningProcessId = lrp.longRunningProcessId;\r\n await this._busyRef.setLongRunningProcessId(this.longRunningProcessId);\r\n } catch (err) {\r\n await this._hideBusyIndicator();\r\n this.lrUpdateInProgress = false;\r\n\r\n }\r\n }\r\n\r\n isFreezeUnfreezeAllowed() : boolean {\r\n return !this.lrUpdateInProgress &&\r\n this.forecastingBudgetingService.selectedMode === 'budget' &&\r\n !!this.selectedBudget;\r\n }\r\n\r\n async freezeUnfreezeBudget() {\r\n if ( !this.selectedBudget ) {\r\n return Promise.resolve();\r\n }\r\n\r\n if ( !this.selectedBudget.isFrozen )\r\n {\r\n const counts: BudgetTaxYearMissingSyncData = await this.forecastingBudgetingService.getMissingCountsBudgetForFreeze();\r\n console.log('MissingCountsForFreeze=', counts);\r\n\r\n let confirmTitle: string = 'Confirm Budget Freeze';\r\n let confirmMsg: string = 'This should only be done if all active Parcels have a completed Budget entry that is frozen or ready to be frozen. Are you sure you want to Freeze the ENTIRE portfolio Budget?';\r\n\r\n if ( counts.numMissingTaxYears > 0 || counts.numMissingBudgets > 0 )\r\n {\r\n confirmTitle = 'Confirm Incomplete Budget Freeze';\r\n confirmMsg = 'Are you sure you want to Freeze an incomplete Budget with ';\r\n if ( counts.numMissingTaxYears > 0 )\r\n {\r\n confirmMsg += ` ${counts.numMissingTaxYears} missing Tax `;\r\n if ( counts.numMissingTaxYears > 1 )\r\n confirmMsg += 'Years ';\r\n else\r\n confirmMsg += 'Year ';\r\n }\r\n if ( counts.numMissingBudgets > 0 )\r\n {\r\n if ( counts.numMissingTaxYears > 0 )\r\n confirmMsg += ' and ';\r\n confirmMsg += ` ${counts.numMissingBudgets} missing Budget `;\r\n if ( counts.numMissingBudgets > 1 )\r\n confirmMsg += 'entries';\r\n else\r\n confirmMsg += 'entry';\r\n }\r\n confirmMsg += '?';\r\n }\r\n\r\n // Confirm with the user to Freeze the entire budget.\r\n const answer: number = await this.messageBoxService.open({\r\n title: confirmTitle,\r\n message: confirmMsg,\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if ( answer !== MessageBoxResult.OK ) {\r\n // Canceled Freeze.\r\n console.log('Freeze Entire Budget confirmation canceled');\r\n return;\r\n }\r\n\r\n console.log('Freeze Entire Budget confirmed');\r\n }\r\n\r\n this.gridApi.showLoadingOverlay();\r\n\r\n await this.forecastingBudgetingService.freezeUnfreezeBudget();\r\n\r\n await this.forecastingBudgetingService.loadData();\r\n\r\n // Update isFrozen state of the Budget.\r\n this.selectedBudget.isFrozen = !this.selectedBudget.isFrozen;\r\n const curBudget = _.find(this.availableBudgets, (entry) => {\r\n return entry.budgetName === this.selectedBudget.budgetName;\r\n });\r\n if ( curBudget )\r\n {\r\n curBudget.isFrozen = this.selectedBudget.isFrozen;\r\n }\r\n if(this.selectedBudget.isFrozen) {\r\n this.forecastingBudgetingService.autoSyncBudgetToLatest = false;\r\n }\r\n\r\n this.gridApi.hideOverlay();\r\n }\r\n\r\n async loadNewColumnData(): Promise {\r\n if(this.forecastingBudgetingService.selectedMode == 'budget' && !this.selectedBudget) {\r\n return;\r\n }\r\n\r\n this.gridApi.showLoadingOverlay();\r\n\r\n await this.forecastingBudgetingService.loadData();\r\n this.gridApi.setColumnDefs(this.forecastingBudgetingService.getGridColumns());\r\n\r\n this.gridApi.hideOverlay();\r\n this.showFilterApplyButton = false;\r\n }\r\n\r\n async confirmActionOnPendingStatus(selections?: Core.ForecastGridEntry[]): Promise {\r\n let proceed: boolean = true;\r\n\r\n // Pending Status is selected in grid filter options, if:\r\n // Available Activity Statuses includes Pending\r\n // AND\r\n // (No Activity Statuses are selected (i.e. All apply)\r\n // OR\r\n // Pending Activity Status is explicitly selected)\r\n const isPendingStatusSelected: boolean = (\r\n _.some(this.availableFilters.activityStatuses, {id: Core.ActivityStatuses.ActivePending}) && // Available Activity Statuses includes Pending\r\n (this.filters.activityStatusIds.length === 0 || // No Activity Statuses selected, i.e. All\r\n this.filters.activityStatusIds.some(x => x === Core.ActivityStatuses.ActivePending)) // Pending Activity Status selected\r\n );\r\n const areSelectionsGiven: boolean = (selections !== undefined && selections !== null && selections.length > 0);\r\n\r\n let numPendingSelected: number = 0;\r\n if ( isPendingStatusSelected && areSelectionsGiven )\r\n {\r\n numPendingSelected = _.reduce(selections, (sum, entry): number => {\r\n if ( entry.activityStatus === 'Pending' ) {\r\n sum++;\r\n }\r\n return sum;\r\n }, 0);\r\n }\r\n console.log(`isPendingStatusSelected=${isPendingStatusSelected} areSelectionsGiven=${areSelectionsGiven} numPendingSelected=${numPendingSelected}`);\r\n\r\n // If Pending Status is selected AND\r\n // we were not given selections OR at least one selection with Pending status,\r\n // then we want to display a popup to confirm that the user wants to add\r\n // a Budget to Pending parcels.\r\n if ( isPendingStatusSelected && (!areSelectionsGiven || numPendingSelected > 0) )\r\n {\r\n const msgBoxResult = await this.messageBoxService.open({\r\n title: 'WARNING',\r\n message: 'You are about to possibly create a Budget for one or more Parcels with Activity Status of \"Pending\", which is usually not desirable. Are you sure you want to continue?',\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n\r\n if (msgBoxResult !== MessageBoxResult.Yes) {\r\n // User aborted request\r\n proceed = false;\r\n }\r\n }\r\n return proceed;\r\n }\r\n\r\n async bulkUpdate() {\r\n // Retrieve the selected Tax Authoriites.\r\n // This involves an API call that mirrors the grid population query, so that\r\n // the Tax Authorities can be retrieved for the All, and All but Given (exclusion)\r\n // selection use cases.\r\n const selections: Core.ForecastGridEntry[] = await this.gatherBulkUpdateSelections();\r\n if ( selections.length === 0 ) {\r\n return;\r\n }\r\n\r\n const initialState = {\r\n selectedCount: selections.length,\r\n yearBegin: this.filters.yearBegin,\r\n yearEnd: this.filters.yearEnd,\r\n selectedMode: this.forecastingBudgetingService.selectedMode,\r\n selectedView: this.forecastingBudgetingService.selectedView,\r\n isFrozen: this.forecastingBudgetingService.selectedMode === 'budget' && this.selectedBudget ? this.selectedBudget.isFrozen : false,\r\n selectedAltAsmtView: this.forecastingBudgetingService.forecastGridSearchModel.alternateAssessmentView\r\n };\r\n const modalRef = this.modalService.show(ForecastingBudgetingBulkUpdateModalComponent, {initialState, class: 'modal-lg', ignoreBackdropClick: true});\r\n\r\n modalRef.content.onClose = async (request?: ForecastBudgetEditRequest) => {\r\n await this.processBulkUpdateRequest(selections, request);\r\n };\r\n }\r\n\r\n async gatherBulkUpdateSelections(): Promise {\r\n\r\n this.bulkUpdateEntityType = (this.filters.siteRollup ? 'Site' : 'Parcel');\r\n\r\n const selections: Core.ForecastGridEntry[] = this.gridApi.getSelectedRows();\r\n console.log(`Forecast/Budget ${this.bulkUpdateEntityType} Selections (${selections.length}): `, _.map(selections, (entry) => entry.entityId));\r\n\r\n // If Selected count is less than threshold for \"an awful lot\", just proceed.\r\n if ( selections.length < this.LARGE_BULK_UPDATE_THRESHOLD ) {\r\n return selections;\r\n }\r\n\r\n // Confirm with the user to Bulk Update that many Tax Authorities.\r\n const answer: number = await this.messageBoxService.open({\r\n message: `Are you sure you want to Bulk Update ${selections.length} ${this.bulkUpdateEntityType} entries?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if ( answer === MessageBoxResult.OK ) {\r\n return selections;\r\n }\r\n\r\n // Canceled Bulk Update, return no selections.\r\n console.log('Bulk Update confirmation canceled');\r\n return [];\r\n }\r\n\r\n executeBulkUpdate(): void {\r\n // RECURSIVE function\r\n if ( !this.bulkUpdateInProgress || this.bulkUpdateCanceled ||\r\n this.isBulkUpdateDone() ) {\r\n // Bulk Update complete or canceled.\r\n if ( this.bulkUpdateProgress )\r\n {\r\n this.forecastingBudgetingService.postProcessEditResult(this.bulkUpdateProgress.request, this.bulkUpdateProgress);\r\n }\r\n return;\r\n }\r\n\r\n const curEntry = this.getCurrentBulkUpdateSelection();\r\n if ( this.bulkUpdateProgress.request.details.editAction == Core.ForecastBudgetEditActionEnum.DistribTotalFMV ||\r\n this.bulkUpdateProgress.request.details.editAction == Core.ForecastBudgetEditActionEnum.DistribAltFMV )\r\n {\r\n this.bulkUpdateProgress.request.details.valueFMV = this.getCurrentBulkUpdateDistributedFMV();\r\n }\r\n\r\n if ( this.bulkUpdateProgress.request.details.valueFMV < 0.0 )\r\n {\r\n console.log(`SKIPPED Bulk Update of ${this.getCurrentBulkUpdateIdentity()}: Not Applicable`);\r\n\r\n this.bulkUpdateProgress.currentIndex++;\r\n\r\n this.executeBulkUpdate();\r\n return;\r\n }\r\n\r\n this.forecastingBudgetingService.applyBulkUpdateToEntry(curEntry, this.bulkUpdateProgress.request)\r\n .then((result: Core.ForecastBudgetEditResult) => {\r\n console.log(`Bulk Updated ${this.getCurrentBulkUpdateIdentity()}: ${JSON.stringify(result)}`);\r\n\r\n this.bulkUpdateProgress.capture(result);\r\n\r\n this.bulkUpdateProgress.currentIndex++;\r\n\r\n this.executeBulkUpdate();\r\n })\r\n .catch((err:any) => {\r\n if ( this.bulkUpdateInProgress )\r\n {\r\n console.log(`Bulk Update FAILED for ${this.getCurrentBulkUpdateIdentity()}: ${JSON.stringify(err)}`);\r\n\r\n this.toastr.error(err.error.message, 'Bulk Update FAILED!');\r\n\r\n this.cancelBulkUpdate();\r\n }\r\n });\r\n }\r\n\r\n cancelBulkUpdate() {\r\n // Switch page to Bulk Updte Canceled display\r\n this.bulkUpdateCanceled = true;\r\n }\r\n\r\n endBulkUpdate() {\r\n // Switch page back to normal display\r\n this.bulkUpdateCanceled = false;\r\n this.bulkUpdateInProgress = false;\r\n this.bulkUpdateProgress.reset();\r\n\r\n // Refresh grid with applied updates.\r\n this.refresh();\r\n }\r\n\r\n isBulkUpdateDone() : boolean {\r\n return this.bulkUpdateProgress.currentIndex >= this.bulkUpdateProgress.selections.length;\r\n }\r\n\r\n getCurrentBulkUpdateSelection() : Core.ForecastGridEntry | null {\r\n let cur: Core.ForecastGridEntry = null;\r\n\r\n if ( this.bulkUpdateProgress.currentIndex < this.bulkUpdateProgress.selections.length )\r\n {\r\n cur = this.bulkUpdateProgress.selections[this.bulkUpdateProgress.currentIndex];\r\n }\r\n return cur;\r\n }\r\n\r\n getCurrentBulkUpdateDistributedFMV() : number {\r\n let cur: number = 0;\r\n\r\n if ( this.bulkUpdateProgress.currentIndex < this.bulkUpdateProgress.distributionFMVs.length )\r\n {\r\n cur = this.bulkUpdateProgress.distributionFMVs[this.bulkUpdateProgress.currentIndex];\r\n }\r\n return cur;\r\n }\r\n\r\n getCurrentBulkUpdateIdentity() : string {\r\n let identity: string = '';\r\n\r\n const cur = this.getCurrentBulkUpdateSelection();\r\n if ( cur )\r\n {\r\n identity = `[${this.bulkUpdateProgress.currentIndex + 1} of ${this.bulkUpdateProgress.selections.length}] Site: ${cur.siteName}`;\r\n if ( cur.entityTypeId === Core.EntityTypes.Parcel ) {\r\n identity += ` Parcel: ${cur.parcelAcctNum}`;\r\n }\r\n }\r\n return identity;\r\n }\r\n\r\n protected async processBulkUpdateRequest(selections: Core.ForecastGridEntry[], request?: ForecastBudgetEditRequest) : Promise {\r\n if ( request )\r\n {\r\n let proceed: boolean = true;\r\n if ( request.details.editAction == Core.ForecastBudgetEditActionEnum.CreateMissingBudget )\r\n {\r\n proceed = await this.confirmActionOnPendingStatus(selections);\r\n }\r\n if ( !proceed )\r\n {\r\n console.log('Created Missing Budgets for Pending parcels NOT confirmed by user!');\r\n return;\r\n }\r\n\r\n request.companyBudgetId = this.forecastingBudgetingService.selectedMode == 'budget' ? this.selectedBudget.companyBudgetId : 0;\r\n request.filters = _.cloneDeep(this.forecastingBudgetingService.filters);\r\n request.autoSyncBudgetToLatest = this.forecastingBudgetingService.autoSyncBudgetToLatest;\r\n request.forBulkUpdate = true;\r\n if ( this.selectedBudget ) {\r\n request.budgetBasis = this.selectedBudget.budgetBasis;\r\n }\r\n\r\n // Switch page to Bulk Update Progress display\r\n this.bulkUpdateInProgress = true;\r\n this.bulkUpdateCanceled = false;\r\n this.bulkUpdateProgress.reset();\r\n this.bulkUpdateProgress.selections = selections;\r\n this.bulkUpdateProgress.request = request;\r\n\r\n if ( request.details.editAction == Core.ForecastBudgetEditActionEnum.DistribTotalFMV ||\r\n request.details.editAction == Core.ForecastBudgetEditActionEnum.DistribAltFMV )\r\n {\r\n this.bulkUpdateProgress.overallDistributionFMV = request.details.valueFMV;\r\n\r\n const totalFMVSelected: number = _.reduce(selections, (sum, entry): number => {\r\n const assessment = _.find(entry.assessments, {annualYear: request.details.taxYear});\r\n if ( !assessment )\r\n {\r\n return sum;\r\n }\r\n let fmvValue: Decimal;\r\n if ( request.details.editAction == Core.ForecastBudgetEditActionEnum.DistribAltFMV )\r\n {\r\n fmvValue = !assessment.altFMV ? new Decimal(0) : new Decimal(assessment.altFMV);\r\n }\r\n else\r\n {\r\n fmvValue = !assessment.totalFMV ? new Decimal(0) : new Decimal(assessment.totalFMV);\r\n }\r\n console.log(`fmvValue=${fmvValue}`);\r\n return new Decimal(sum).plus(fmvValue).toNumber();\r\n }, 0);\r\n console.log('totalFMVSelected=', totalFMVSelected);\r\n\r\n this.bulkUpdateProgress.distributionFMVs = _.map(selections, (entry:Core.ForecastGridEntry) : number => {\r\n const assessment = _.find(entry.assessments, {annualYear: request.details.taxYear});\r\n if ( !assessment )\r\n {\r\n return 0;\r\n }\r\n let fmvValue: Decimal;\r\n if ( request.details.editAction == Core.ForecastBudgetEditActionEnum.DistribAltFMV )\r\n {\r\n fmvValue = !assessment.altFMV ? new Decimal(0) : new Decimal(assessment.altFMV);\r\n }\r\n else\r\n {\r\n fmvValue = !assessment.totalFMV ? new Decimal(0) : new Decimal(assessment.totalFMV);\r\n }\r\n let ratio: Decimal;\r\n if ( totalFMVSelected === 0 && selections.length > 1 )\r\n {\r\n // Total FMV is 0 and there is more than one parcel/site selection.\r\n // Ratio cannot be determined for any Parcel, so FMV\r\n // cannot be distributed to any of them.\r\n return -1;\r\n }\r\n else if ( totalFMVSelected === 0 && selections.length === 1 )\r\n {\r\n // Total FMV is 0 and there is only one parcel/site selection.\r\n // The lone site/parcel will receive entire distribution, so\r\n // Ratio needs to be 1.0 (100%).\r\n ratio = new Decimal(1.0);\r\n }\r\n else\r\n {\r\n // Compute ratio of this selection's FMV and total FMV of selections.\r\n ratio = fmvValue.dividedBy(totalFMVSelected);\r\n }\r\n console.log(`fmvValue=${fmvValue} ratio=${ratio}`);\r\n return new Decimal(this.bulkUpdateProgress.overallDistributionFMV).times(ratio).round().toNumber();\r\n });\r\n }\r\n console.log('distFMVs=', this.bulkUpdateProgress.distributionFMVs);\r\n\r\n console.log(`Forecast/Budget Bulk Updates to apply: ${JSON.stringify(this.bulkUpdateProgress.request)}`);\r\n //console.log(`${this.bulkUpdateEntityType} to Bulk Update: ${JSON.stringify(this.bulkUpdateProgress.selections)}`);\r\n\r\n // Execute Bulk Update\r\n this.executeBulkUpdate();\r\n }\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this.gridApi && this.isInitialized)) {\r\n return;\r\n }\r\n\r\n this.gridApi.setRowData(this.forecastingBudgetingService.getData());\r\n\r\n this.forecastingBudgetingService.updateTotals();\r\n }\r\n\r\n private async _setFiltersAndLoadData() {\r\n _.chain(this.availableFilters.companies)\r\n .filter(company => !this.filters.companyIds.length || _.includes(this.filters.companyIds, company.id))\r\n .forEach(company => {\r\n this.availableFilters.states = _.chain(this.availableFilters.states)\r\n .unionWith(company.states, _.isEqual)\r\n .sortBy('name')\r\n .value();\r\n this.availableFilters.propertyTypes = _.unionWith(this.availableFilters.propertyTypes, company.propertyTypes, _.isEqual);\r\n this.availableFilters.activityStatuses = _.unionWith(this.availableFilters.activityStatuses, company.activityStatuses, _.isEqual);\r\n })\r\n .value();\r\n\r\n this.filters.stateIds = _.intersectionBy(this.filters.stateIds, _.map(this.availableFilters.states, 'id'));\r\n this.filters.propertyTypeIds = _.intersectionBy(this.filters.propertyTypeIds, _.map(this.availableFilters.propertyTypes, 'id'));\r\n this.filters.activityStatusIds = _.intersectionBy(this.filters.activityStatusIds, _.map(this.availableFilters.activityStatuses, 'id'));\r\n\r\n //await this.loadNewColumnData();\r\n this.showFilterApplyButton = true;\r\n }\r\n\r\n private _showBusyIndicator(message: string, lrpId: number, hasAction: boolean = true): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n longRunningProcessId: lrpId,\r\n identifier: this.busyRefId,\r\n title: 'Processing company update',\r\n message,\r\n hasProgressBar: false,\r\n hasAction,\r\n actionMessage: 'Cancel',\r\n canDismiss: true\r\n });\r\n\r\n if (hasAction) {\r\n this._busyRef.onAction().pipe(takeUntil(this._destroy$)).subscribe(async () => {\r\n await lastValueFrom(this.longRunningProcessRepository.cancel(this.longRunningProcessId));\r\n });\r\n }\r\n\r\n this._busyRef.onDismiss().pipe(takeUntil(this._destroy$)).subscribe(async () => {\r\n await this._hideBusyIndicator();\r\n this.goToParentCompany();\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success) => {\r\n await this._hideBusyIndicator();\r\n this.lrUpdateInProgress = false;\r\n if (success) {\r\n await this.refresh();\r\n }\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._destroy$.next();\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { AddCompanyBudgetModalComponent } from './add.company.budget.modal.component';\r\nimport { ForecastBudgetYearCellEditorComponent } from './agGridForecastBudgetYearCellEditor.component';\r\nimport { ForecastBudgetYearCellRendererComponent } from './agGridForecastBudgetYearCellRender.component';\r\nimport { AgGridSwitchCellRendererComponent } from './agGridSwitchCellRenderer.component';\r\nimport { BudgetTaxYearCreateMissingComponent } from './budget.taxyear.create.missing.component';\r\nimport { BudgetTaxYearSyncBudgetsComponent } from './budget.taxyear.sync.budgets.component';\r\nimport { ForecastCreateMissingComponent } from './forecast.create.missing.component';\r\nimport { ForecastingBudgetingBulkUpdateModalComponent } from './forecasting.budgeting.bulk.update.modal.component';\r\nimport { ForecastingBudgetingPageComponent } from './forecasting.budgeting.page.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule\r\n ],\r\n declarations: [\r\n ForecastingBudgetingPageComponent,\r\n ForecastingBudgetingBulkUpdateModalComponent,\r\n ForecastCreateMissingComponent,\r\n BudgetTaxYearCreateMissingComponent,\r\n BudgetTaxYearSyncBudgetsComponent,\r\n AddCompanyBudgetModalComponent,\r\n ForecastBudgetYearCellRendererComponent,\r\n ForecastBudgetYearCellEditorComponent,\r\n AgGridSwitchCellRendererComponent\r\n ],\r\n exports: [\r\n ForecastingBudgetingPageComponent\r\n ]\r\n})\r\nexport class BudgetModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('forecastingBudgetingPage', ForecastingBudgetingPageComponent);\r\n }\r\n}\r\n","\r\nexport class BulkImportAssessmentsModel {\r\n assessorID: number;\r\n stateID: number;\r\n annualYear: number;\r\n comment: string;\r\n\tdata: string; // text; first line - headers\r\n}\r\n\r\nexport class BulkImportSitesModel {\r\n topCompanyID: number;\r\n comment: string;\r\n data: string; // text; first line - headers\r\n validateOnly: boolean;\r\n totalProcessedRows: number;\r\n}\r\n\r\nexport class BulkImportResultModel {\r\n numberOfProcessedRows: number;\r\n numberOfValidRows: number;\r\n validationResults: Array;\r\n criticalErrors: Array;\r\n}\r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\nimport { BulkImportAssessmentsModel, BulkImportSitesModel, BulkImportResultModel } from './bulk.import.model';\r\n\r\n@Injectable()\r\nexport class BulkImportService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n importAssessmentData(payload: BulkImportAssessmentsModel): Promise {\r\n return this.http.post('/api/AnnualAssessment/BulkImport', payload);\r\n }\r\n\r\n importSiteData(payload: BulkImportSitesModel): Promise {\r\n return this.http.post('/api/Site/BulkImport', payload);\r\n }\r\n\r\n importParcelData(payload: BulkImportSitesModel): Promise {\r\n return this.http.post('/api/Parcel/BulkImport', payload);\r\n }\r\n}\r\n","
\r\n
\r\n

Import Assessments

\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n\r\n \r\n\r\n \r\n
\r\n\r\n
\r\n

Reading File

\r\n

= fileLines.length\" class=\"text-start\">Done

\r\n \r\n

{{successfulImportCount}} / {{fileLines.length - 1}} Parcels Successfully Imported

\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n

Cancelling...

\r\n \r\n
\r\n
\r\n
\r\n","import { OnInit, Component } from '@angular/core';\r\nimport { StateService } from '../../Common/States/States.Service';\r\nimport { StateSummary } from '../../Common/States/state.model';\r\nimport { AssessorService } from '../../Assessor-Collector/Assessor/assessor-service';\r\nimport { Assessor } from '../../Assessor-Collector/assessor.model';\r\n\r\nimport * as _ from 'lodash';\r\nimport { BulkImportAssessmentsModel } from '../bulk.import.model';\r\nimport { BulkImportService } from '../bulk.import.service';\r\n\r\n@Component({\r\n selector: 'bulk-import-assessments',\r\n templateUrl: './bulk.import.assessments.component.html',\r\n styleUrls: ['./bulk.import.assessments.component.scss']\r\n})\r\nexport class BulkImportAssessmentsComponent implements OnInit {\r\n constructor(\r\n private stateService: StateService,\r\n private assessorService: AssessorService,\r\n private bulkImportService: BulkImportService,\r\n ) {\r\n }\r\n\r\n states: StateSummary[];\r\n assessors: Assessor[];\r\n years: number[];\r\n isImporting: boolean;\r\n initIndex: number;\r\n userCancelled: boolean;\r\n successfulImportCount: number;\r\n\r\n payload: BulkImportAssessmentsModel;\r\n fileLines: string[];\r\n\r\n ngOnInit() {\r\n this.stateService.getSummary()\r\n .then((states: StateSummary[]) => {\r\n this.states = states;\r\n });\r\n\r\n const currentYear: number = new Date().getFullYear();\r\n\r\n const years: number[] = _.range(currentYear - 5, currentYear + 10) as number[];\r\n this.years = years.reverse();\r\n\r\n this.initValues();\r\n }\r\n\r\n initValues(): void {\r\n this.payload = new BulkImportAssessmentsModel();\r\n this.payload.annualYear = new Date().getFullYear();\r\n this.payload.stateID = null;\r\n this.payload.assessorID = null;\r\n\r\n this.isImporting = false;\r\n this.userCancelled = false;\r\n this.initIndex = 1;\r\n this.fileLines = undefined;\r\n this.successfulImportCount = 0;\r\n }\r\n\r\n stateSelected(): void {\r\n this.assessorService.getByStateId(this.payload.stateID)\r\n .then((assessors: Assessor[]) => {\r\n this.assessors = _.orderBy(assessors, ['abbr'], ['asc']);\r\n\r\n this.payload.assessorID = null;\r\n });\r\n }\r\n\r\n fileChanged(e): void {\r\n const file: File = e.target.files[0];\r\n\r\n if (!file) {\r\n this.fileLines = undefined;\r\n return;\r\n }\r\n\r\n const fileReader: FileReader = new FileReader();\r\n\r\n fileReader.onload = () => {\r\n this.fileLines = (fileReader.result as string).split('\\n');\r\n };\r\n\r\n fileReader.readAsText(file);\r\n }\r\n\r\n startImporting(): void {\r\n if (this.userCancelled) {\r\n this.userCancelled = false;\r\n this.initIndex = 1;\r\n this.successfulImportCount = 0;\r\n this.fileLines = undefined;\r\n\r\n return;\r\n }\r\n\r\n if (this.initIndex >= this.fileLines.length) {\r\n return;\r\n }\r\n\r\n this.isImporting = true;\r\n this.payload.data = `${this.fileLines[0] }\\n`;\r\n\r\n for (let i = this.initIndex; i < (10 + this.initIndex) && i < this.fileLines.length; i++) {\r\n this.payload.data += `${this.fileLines[i] }\\n`;\r\n }\r\n\r\n this.bulkImportService.importAssessmentData(this.payload)\r\n .then((successfullyImported) => {\r\n this.successfulImportCount += successfullyImported;\r\n\r\n this.initIndex = this.fileLines.length;\r\n\r\n this.startImporting();\r\n })\r\n .catch(() => {\r\n this.cancelImport();\r\n\r\n this.startImporting();\r\n });\r\n }\r\n\r\n cancelImport(): void {\r\n this.isImporting = false;\r\n this.userCancelled = true;\r\n }\r\n}\r\n","export class DisplayStringArrayModel {\r\n stringArray: Array;\r\n}","
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n {{ item }}\r\n
\r\n
\r\n","import { Component, Input } from '@angular/core';\r\nimport {DisplayStringArrayModel} from './display.String.Array.model';\r\n\r\n@Component({\r\n selector: 'display-String-Array-component',\r\n templateUrl:\r\n './display.String.Array.component.html'\r\n})\r\nexport class DisplayStringArrayComponent {\r\n\r\n @Input() data: DisplayStringArrayModel;\r\n\r\n // constructor(\r\n // public data: DisplayStringArrayModel,\r\n // ) {\r\n // this.dataToDisplay = data;\r\n // }\r\n\r\n}","
\r\n
\r\n

\r\n Import\r\n Sites\r\n Parcels\r\n

\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n

Reading File

\r\n

= fileLines.length\" class=\"text-start\">Done

\r\n

Cancelled

\r\n
\r\n \r\n \r\n
\r\n

\r\n {{successfulImportCount}} / {{fileLines.length - 1}}\r\n Sites\r\n Parcels\r\n Successfully\r\n Validated\r\n Imported\r\n

\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n

Cancelling...

\r\n \r\n
\r\n
\r\n

0\">\r\n Problems encountered during\r\n validation:\r\n import:\r\n

\r\n \r\n
\r\n
\r\n
\r\n\r\n","import { OnInit, Component, ViewChild, ElementRef } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BulkImportSitesModel, BulkImportResultModel } from '../bulk.import.model';\r\nimport { BulkImportService } from '../bulk.import.service';\r\nimport { TypeaheadCompany } from '../../Entity/Company/Company.Picker.Component';\r\nimport { DisplayStringArrayModel } from '../Display-String-Array/display.String.Array.model';\r\n\r\nexport enum ImportType { Site = 'site', Parcel = 'parcel' }\r\n\r\n@Component({\r\n selector: 'bulk-import-sites',\r\n templateUrl: './bulk.import.sites.component.html',\r\n styleUrls: ['./bulk.import.sites.component.scss']\r\n})\r\nexport class BulkImportSitesComponent implements OnInit {\r\n constructor(\r\n private bulkImportService: BulkImportService,\r\n ) { }\r\n\r\n @ViewChild('fileInput', { static: true })\r\n\r\n isImporting: boolean;\r\n initIndex: number;\r\n userCancelling: boolean;\r\n userCancelled: boolean;\r\n successfulImportCount: number;\r\n payload: BulkImportSitesModel;\r\n warnings: DisplayStringArrayModel;\r\n fileLines: string[];\r\n // TODO: We should probably rename this component and folders since it's now importing sites or parcels\r\n importType: ImportType;\r\n fileInput: ElementRef;\r\n hasFile: boolean;\r\n outputFile: string = null;\r\n\r\n ngOnInit() {\r\n this.payload = new BulkImportSitesModel();\r\n this.payload.topCompanyID = null;\r\n this.hasFile = false;\r\n this.initValues();\r\n }\r\n\r\n initValues() {\r\n this.isImporting = false;\r\n this.userCancelled = false;\r\n this.userCancelling = false;\r\n this.initIndex = 1;\r\n this.successfulImportCount = 0;\r\n this.warnings = new DisplayStringArrayModel();\r\n this.warnings.stringArray = [];\r\n }\r\n\r\n clearFilePicker() {\r\n this.fileInput.nativeElement.value = '';\r\n this.fileLines = undefined;\r\n this.hasFile = false;\r\n }\r\n\r\n companySelected(selectedCompany: TypeaheadCompany) {\r\n if (selectedCompany.companyID)\r\n this.payload.topCompanyID = selectedCompany.companyID;\r\n else\r\n this.payload.topCompanyID = null;\r\n }\r\n\r\n fileChanged(e): void {\r\n const file: File = e.target.files[0];\r\n\r\n if (!file) {\r\n this.fileLines = undefined;\r\n this.hasFile = false;\r\n\r\n return;\r\n }\r\n this.hasFile = true;\r\n\r\n const fileReader: FileReader = new FileReader();\r\n\r\n fileReader.onload = () => {\r\n // get lines from file into array\r\n\r\n const fileText = fileReader.result;\r\n let lines: string[];\r\n if ((fileText as string).indexOf('\\r') >= 0) {\r\n lines = (fileText as string).split('\\r\\n');\r\n }\r\n else {\r\n lines = (fileText as string).split('\\n');\r\n }\r\n\r\n // Remove trailing blank lines\r\n let blankIndex = lines.length;\r\n while (lines[blankIndex - 1] === '') {\r\n blankIndex--;\r\n }\r\n lines = lines.slice(0, blankIndex);\r\n this.fileLines = lines;\r\n };\r\n\r\n fileReader.readAsText(file, 'CP1252');\r\n }\r\n\r\n startImporting(validateOnly): void {\r\n if (this.userCancelling) {\r\n this.userCancelling = false;\r\n this.userCancelled = true;\r\n return;\r\n }\r\n\r\n if (this.initIndex >= this.fileLines.length) {\r\n if(this.warnings.stringArray.length) {\r\n this._createOutputFile();\r\n }\r\n\r\n return;\r\n }\r\n\r\n this.isImporting = true;\r\n this.payload.validateOnly = validateOnly;\r\n // get first line (headers)\r\n this.payload.data = `${this.fileLines[0] }\\r\\n`;\r\n\r\n // add more lines to the chink\r\n for (let i = this.initIndex; i < (50 + this.initIndex) && i < this.fileLines.length; i++) {\r\n this.payload.data += `${this.fileLines[i] }\\r\\n`;\r\n }\r\n\r\n this.payload.totalProcessedRows = this.initIndex - 1;\r\n\r\n this.performImport(this.payload).then((bulkImportResult) => {\r\n // we are getting an object now, let's get number of lines etc\r\n this.warnings.stringArray = this.warnings.stringArray.concat(bulkImportResult.criticalErrors);\r\n this.warnings.stringArray = this.warnings.stringArray.concat(bulkImportResult.validationResults);\r\n\r\n this.successfulImportCount += bulkImportResult.numberOfValidRows;\r\n\r\n this.initIndex = this.fileLines.length;\r\n\r\n this.startImporting(validateOnly);\r\n }).catch(() => {\r\n this.warnings.stringArray = this.warnings.stringArray.concat('A serious error was encountered which has caused the import to abort while in progress');\r\n this.cancelImport();\r\n this.startImporting(validateOnly);\r\n });\r\n }\r\n\r\n performImport(payload: BulkImportSitesModel): Promise {\r\n switch (this.importType) {\r\n case ImportType.Parcel:\r\n return this.bulkImportService.importParcelData(payload);\r\n case ImportType.Site:\r\n return this.bulkImportService.importSiteData(payload);\r\n default:\r\n throw new Error(`Unrecognized import type: ${ this.importType}`);\r\n }\r\n }\r\n\r\n cancelImport(): void {\r\n this.userCancelling = true;\r\n }\r\n\r\n // https://stackoverflow.com/questions/21012580/is-it-possible-to-write-data-to-file-using-only-javascript\r\n private _createOutputFile() {\r\n const stringLines: string = _.reduce(this.warnings.stringArray, (finalString: string, line: string) => {\r\n finalString += `${line }\\r\\n`;\r\n\r\n return finalString;\r\n }, '');\r\n\r\n const blob = new Blob([stringLines], { type: 'text/plain' });\r\n\r\n if(this.outputFile !== null) {\r\n window.URL.revokeObjectURL(this.outputFile);\r\n }\r\n\r\n this.outputFile= window.URL.createObjectURL(blob);\r\n\r\n const link = document.createElement('a');\r\n link.setAttribute('download', 'import-warnings.txt');\r\n link.href = this.outputFile;\r\n document.body.appendChild(link);\r\n\r\n // wait for the link to be added to the document\r\n window.requestAnimationFrame(function () {\r\n const event = new MouseEvent('click');\r\n link.dispatchEvent(event);\r\n document.body.removeChild(link);\r\n });\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { CompanyModule } from '../Entity/Company/company.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { BulkImportAssessmentsComponent } from './Assessments/bulk.import.assessments.component';\r\nimport { BulkImportService } from './bulk.import.service';\r\nimport { DisplayStringArrayComponent } from './Display-String-Array/display.String.Array.component';\r\nimport { BulkImportSitesComponent } from './Sites/bulk.import.sites.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n CompanyModule\r\n ],\r\n declarations: [\r\n BulkImportAssessmentsComponent,\r\n BulkImportSitesComponent,\r\n DisplayStringArrayComponent\r\n ],\r\n providers: [\r\n BulkImportService\r\n ],\r\n exports: [\r\n BulkImportAssessmentsComponent,\r\n BulkImportSitesComponent\r\n ]\r\n})\r\nexport class BulkImportModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('bulkImportAssessments', BulkImportAssessmentsComponent);\r\n hybridAdapterUtility.downgradeNg2Component('bulkImportSites', BulkImportSitesComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { UIRouterUpgradeModule } from '@uirouter/angular-hybrid';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { AceModule } from '../UI-Lib/ACE/ace.module';\r\nimport { DiagnosticsComponent } from './diagnostics.component';\r\nimport { AttachmentDownloadDiagnosticComponent } from './Attachment-Download/attachmentDownloadDiagnostic.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n WeissmanSharedModule,\r\n AceModule,\r\n UIRouterUpgradeModule\r\n ],\r\n declarations: [\r\n DiagnosticsComponent,\r\n AttachmentDownloadDiagnosticComponent\r\n ],\r\n exports: [\r\n DiagnosticsComponent\r\n ]\r\n})\r\nexport class DiagnosticsModule {\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { AttachmentFormComponent } from './Form/attachmentForm.component';\r\nimport { FileViewerComponent } from './Viewer/file.viewer.component';\r\nimport { AttachmentService } from './attachment.service';\r\nimport { BillImageModalComponent } from './Bill-Image-Modal/billImageModal.component';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { AttachmentModalComponent } from './Modal/attachmentModal.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n WeissmanSharedModule,\r\n BusyIndicatorModule\r\n ],\r\n declarations: [\r\n AttachmentFormComponent,\r\n FileViewerComponent,\r\n BillImageModalComponent,\r\n AttachmentModalComponent\r\n ],\r\n exports: [\r\n AttachmentFormComponent,\r\n FileViewerComponent\r\n ],\r\n providers: [\r\n AttachmentService\r\n ]\r\n})\r\nexport class AttachmentModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('sdAttachmentForm', AttachmentFormComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('sdAttachmentService', AttachmentService);\r\n }\r\n}\r\n","import { Collector } from '../collector.model';\r\n\r\nexport abstract class CollectorService {\r\n abstract getCollectorsByState(stateId: number): Promise;\r\n abstract getCollectorsByAssessor(assessorId: number): Promise;\r\n}\r\n","import { HttpClient, HttpHeaders } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { BatchDocument } from './document.intake.component';\r\nimport { BaseRepository } from '../../Common/Data/base.repository';\r\n\r\nconst baseUrl = '/api/documentintake';\r\n\r\n@Injectable()\r\nexport class DocumentIntakeService extends BaseRepository {\r\n constructor(httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n sendBatchDocuments(options: BatchDocument, files: File[]): Promise {\r\n const formData = new FormData();\r\n\r\n files.forEach(file => formData.append('file', file));\r\n formData.append('intakeInfo', encodeURIComponent(JSON.stringify(options)));\r\n const params = {\r\n headers: new HttpHeaders({\r\n 'Content-Type': [undefined]\r\n })\r\n };\r\n\r\n return lastValueFrom(this.httpPost(`${baseUrl}/batch`, formData, params));\r\n }\r\n}\r\n","
\r\n
\r\n

Document Intake

\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Document Information

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Exclude the first\r\n pages\r\n
Pages Per Item\r\n \r\n
Assign to Ryan\r\n \r\n
Intake to Licensed Instance\r\n \r\n
Client Instance:\r\n \r\n
Ultimately Resp:\r\n \r\n \r\n \r\n
Assigned Entry:\r\n \r\n \r\n \r\n
Assigned QC:\r\n \r\n \r\n \r\n
Contact:\r\n \r\n \r\n \r\n
Document Type:\r\n \r\n
Perform OCR:\r\n \r\n
Earliest Due Date:\r\n \r\n
\r\n
\r\n
State:\r\n \r\n \r\n
Assessor:\r\n \r\n
Collector:\r\n \r\n
Company:\r\n \r\n
Tax Year:\r\n \r\n
Comment:\r\n \r\n
\r\n\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{file.name}}\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n
\r\n","import { ChangeDetectorRef, Component, ElementRef, OnInit, TemplateRef } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Assessor } from '../../Assessor-Collector/assessor.model';\r\nimport { Collector } from '../../Assessor-Collector/collector.model';\r\nimport { AssessorService } from '../../Assessor-Collector/Assessor/assessor-service';\r\nimport { CollectorService } from '../../Assessor-Collector/Collector/collector.service.upgrade';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { TypeaheadCompany } from '../../Entity/Company/Company.Picker.Component';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { DocumentIntakeService } from './document.intake.service';\r\nimport { TimerService } from '../../UI-Lib/Utilities';\r\nimport { DocumentIntakeLicensedClientDetailRepository } from '../Document-Intake-Licensed-Clients/documentIntakeLicensedClient.repository';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { RyanInstanceId } from '../../constants.new';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { InstanceRepository } from '../../Entity/Instance/instance.repository';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { AttachmentService } from 'src/app/Attachment/attachment.service';\r\nimport { TeamService } from 'src/app/Team/team.service';\r\nimport { ProductAnalyticsService } from 'src/app/Common/Amplitude/productAnalytics.service';\r\nimport { find } from 'lodash';\r\nimport * as moment from 'moment';\r\n\r\nexport interface BatchDocument {\r\n splitDocument: boolean;\r\n pagesPerItem: number;\r\n excludeFirstXPages: number;\r\n companyID: number;\r\n documentTypeID?: number;\r\n assignedQC?: Core.UserTeamModel;\r\n assignedEntry?: Core.UserTeamModel;\r\n ultimatelyResponsible?: Core.UserTeamModel;\r\n contact?: Core.UserTeamModel;\r\n earliestDueDate?: Date;\r\n entityName: string;\r\n stateID?: number;\r\n assessorID?: number;\r\n collectorID?: number;\r\n taxYear: number;\r\n commentBody: string;\r\n assignToRyan: boolean;\r\n clientInstanceId?: number;\r\n performOcr: boolean;\r\n}\r\n@Component({\r\n selector: 'document-intake',\r\n templateUrl: './document.intake.component.html',\r\n styleUrls: ['./document.intake.component.scss']\r\n})\r\nexport class DocumentIntakeComponent implements OnInit {\r\n constructor(\r\n private readonly _assessorService: AssessorService,\r\n private readonly _collectorService: CollectorService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _cdr: ChangeDetectorRef,\r\n private readonly _elem: ElementRef,\r\n private readonly _documentIntakeService: DocumentIntakeService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: BsModalService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _teamService: TeamService,\r\n private readonly _timer: TimerService,\r\n public readonly featureFlagsService: FeatureFlagsService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private readonly _documentIntakeLicensedClientRepository: DocumentIntakeLicensedClientDetailRepository,\r\n private readonly _attachmentService: AttachmentService,\r\n private readonly _restrictService: RestrictService) { }\r\n\r\n batchDocument: BatchDocument = {} as BatchDocument;\r\n assessorList: Assessor[] = [];\r\n collectorList: Collector[] = [];\r\n collectorsLoading: boolean = false;\r\n taxYearList: number[] = _.range(new Date().getFullYear() + 5, new Date().getFullYear() - 11);\r\n documentTypeList: Core.AttachmentTypeModel[] = [];\r\n pageCount = 0;\r\n pagesPerItemList: number[] = _.range(1, 11);\r\n invalidPageCount: boolean = false;\r\n multiFiles: File[] = [];\r\n singleFile: File;\r\n selectedMultiFile: File;\r\n uploading: boolean = false;\r\n saveAttempted: boolean = false;\r\n showForm: boolean = true;\r\n company: TypeaheadCompany;\r\n documentIntakeUsers: Core.UserTeamModel[] = [];\r\n documentIntakeSettings: Core.DocumentIntakeLicensedClientModel;\r\n enableIntakeToLicensedInstance: boolean;\r\n enableAssignToRyan: boolean;\r\n intakeToLicensedInstance: boolean;\r\n licensedClients: Core.DocumentIntakeLicensedClientModel[] = [];\r\n selectedInstance: Core.DocumentIntakeLicensedClientModel;\r\n selectedInstanceName: string;\r\n clientInstanceId: number;\r\n instanceHasIdpEnabled: boolean = false;\r\n\r\n private readonly MAX_FILE_NUM: number = 999;\r\n private readonly NAVIGATE_WARNING: string = 'An upload is in progress; are you sure you want to leave?';\r\n private _assignToRyan: boolean;\r\n private _defaultContact: Core.UserTeamModel;\r\n\r\n async ngOnInit() {\r\n this.showForm = false;\r\n let documentIntakeAndProcessingAssignToRyan: boolean = false;\r\n\r\n const requests: Promise[] = [\r\n this._teamService.getAllAssignableUsers(false, false, undefined, undefined, undefined, undefined, undefined, true),\r\n ];\r\n\r\n const selectedInstance = this._userInstanceService.getSelectedInstance();\r\n const selectedInstanceId = selectedInstance.instanceId;\r\n\r\n this.enableAssignToRyan = this.featureFlagsService.featureFlags.enableLicensedDocumentIntakeAndProcessing\r\n && selectedInstanceId != RyanInstanceId\r\n && selectedInstanceId != -1;\r\n this.enableIntakeToLicensedInstance = this.featureFlagsService.featureFlags.enableLicensedDocumentIntakeAndProcessing\r\n && selectedInstanceId === RyanInstanceId\r\n && this._restrictService.isInRole(Roles.LICENSEDDOCUMENTSERVICES);\r\n this.instanceHasIdpEnabled = selectedInstance.documentIntakeIdpEnabled;\r\n\r\n if (this.enableAssignToRyan) {\r\n const instanceInfo = await lastValueFrom(this._instanceRepository.get(selectedInstanceId));\r\n\r\n documentIntakeAndProcessingAssignToRyan = !!instanceInfo?.documentIntakeAndProcessingAssignToRyan;\r\n if (documentIntakeAndProcessingAssignToRyan) {\r\n requests.push(lastValueFrom(this._documentIntakeLicensedClientRepository.get(selectedInstanceId)));\r\n }\r\n } else if (this.enableIntakeToLicensedInstance) {\r\n requests.push(lastValueFrom(this._documentIntakeLicensedClientRepository.getListAcceptedForDI()));\r\n }\r\n\r\n const responses = await Promise.all(requests);\r\n\r\n this.documentIntakeUsers = responses[0];\r\n\r\n this.documentIntakeSettings = this.enableAssignToRyan && documentIntakeAndProcessingAssignToRyan\r\n ? responses[1]\r\n : {};\r\n this._assignToRyan = !!this.documentIntakeSettings.ryanUserGroupId;\r\n\r\n if (this.enableIntakeToLicensedInstance) {\r\n this.licensedClients = responses[1];\r\n this.licensedClients = this.licensedClients.filter(x => x.ryanUserGroupId);\r\n }\r\n\r\n await this.initializeForm();\r\n this.batchDocument.splitDocument = true;\r\n\r\n const documentTypeList = await this._attachmentService.getAttachmentTypes();\r\n this.documentTypeList = documentTypeList.sort((a, b) => a.attachmentTypeName.localeCompare(b.attachmentTypeName));\r\n }\r\n\r\n get shouldDisplayAssignToRyan() {\r\n return this.enableAssignToRyan && this.documentIntakeSettings?.ryanUserGroupId;\r\n }\r\n\r\n get shouldDisplayPerformOCR() {\r\n return this.featureFlagsService.featureFlags.enableIdp && this.instanceHasIdpEnabled\r\n && (this.batchDocument.documentTypeID === Core.AttachmentTypes.TaxBill\r\n || (this.featureFlagsService.featureFlags.enableIdpAssessment\r\n && this.batchDocument.documentTypeID === Core.AttachmentTypes.AssessmentNotice)\r\n );\r\n }\r\n\r\n async initializeForm(): Promise {\r\n this.showForm = false;\r\n\r\n _.assign(this.batchDocument, {\r\n pagesPerItem: 1,\r\n excludeFirstXPages: 0,\r\n companyID: 0,\r\n entityName: 'company',\r\n documentTypeID: undefined,\r\n assignedQC: undefined,\r\n assignedEntry: undefined,\r\n ultimatelyResponsible: undefined,\r\n contact: undefined,\r\n earliestDueDate: undefined,\r\n stateID: undefined,\r\n assessorID: undefined,\r\n collectorID: undefined,\r\n taxYear: undefined,\r\n commentBody: undefined,\r\n assignToRyan: this._assignToRyan\r\n });\r\n\r\n this._defaultContact = await this._teamService.getUserDefaultTeam();\r\n\r\n if (!this._assignToRyan) {\r\n this.batchDocument.contact = this._defaultContact;\r\n }\r\n this.company = undefined;\r\n\r\n this.showForm = true;\r\n }\r\n\r\n pageExclusionChanged(): void {\r\n this._productAnalyticsService.logEvent('exclude-first-page(s)');\r\n this.pageCount = 0;\r\n // If we haven't loaded a PDF yet, don't clear the pagesPerItemList\r\n // Works as long as document intake only has one iframe; if this assumption changes we'll need to alter this query\r\n if (this._elem.nativeElement.querySelector('iframe')) {\r\n this.pagesPerItemList = [];\r\n }\r\n this._startCheckPageCount();\r\n }\r\n\r\n resetExclusionInput(): void {\r\n if(!this.batchDocument.excludeFirstXPages && this.batchDocument.excludeFirstXPages != 0) {\r\n this.batchDocument.excludeFirstXPages = 0;\r\n }\r\n }\r\n\r\n ultimatelyResponsibleChosen(user: Core.UserTeamModel): void {\r\n if(user ) {\r\n this.batchDocument.assignedEntry = _.cloneDeep(user);\r\n }\r\n }\r\n\r\n async stateChanged(): Promise {\r\n if(this.batchDocument.stateID) {\r\n this._productAnalyticsService.logEvent('enter-state');\r\n\r\n await this.getCollectorList();\r\n this.batchDocument.assessorID = null;\r\n\r\n const assessorList = await this._assessorService.getByStateId(this.batchDocument.stateID);\r\n this.assessorList = _.sortBy(assessorList, 'name');\r\n }\r\n }\r\n\r\n async getCollectorList(): Promise {\r\n this.batchDocument.collectorID = undefined;\r\n let collectorList: Collector[];\r\n\r\n this.collectorsLoading = true;\r\n\r\n if(this.batchDocument.assessorID) {\r\n const results = await this._collectorService.getCollectorsByAssessor(this.batchDocument.assessorID);\r\n collectorList = _.map(results, 'collector');\r\n } else {\r\n collectorList = await this._collectorService.getCollectorsByState(this.batchDocument.stateID);\r\n }\r\n this.collectorList = _.sortBy(collectorList, 'abbr');\r\n\r\n this.collectorsLoading = false;\r\n }\r\n\r\n isUploadDisabled(): boolean {\r\n if (this.batchDocument.splitDocument) {\r\n return this.batchDocument.excludeFirstXPages >= this.pageCount || !this.singleFile;\r\n } else {\r\n return !this.multiFiles.length;\r\n }\r\n }\r\n\r\n filesPicked(files: File[]): void {\r\n if(!files.length) {\r\n this._toastr.error('Could not process file for upload');\r\n return;\r\n }\r\n\r\n if(this.batchDocument.splitDocument) {\r\n if(files[0].type != 'application/pdf') {\r\n this._toastr.error('Only PDF files are supported for Single Document (Split) uploads');\r\n return;\r\n }\r\n\r\n if(files.length > 1) {\r\n this._toastr.error('Only one document can be uploaded');\r\n return;\r\n }\r\n\r\n this.singleFile = files[0];\r\n this._startCheckPageCount();\r\n } else {\r\n this.multiFiles = [...files, ...this.multiFiles];\r\n\r\n if(this.multiFiles.length > this.MAX_FILE_NUM) {\r\n this.multiFiles = _.take(this.multiFiles, this.MAX_FILE_NUM);\r\n this._toastr.error('Please limit number of files to 999');\r\n }\r\n }\r\n\r\n this._cdr.detectChanges();\r\n }\r\n\r\n async selectInstance(selectedInstance: Core.DocumentIntakeLicensedClientModel): Promise {\r\n this.selectedInstance = selectedInstance;\r\n this.selectedInstanceName = selectedInstance.instanceName;\r\n this.batchDocument.clientInstanceId = this.selectedInstance.instanceId;\r\n this.batchDocument.ultimatelyResponsible = this.selectedInstance.ryanUltimatelyResp;\r\n this.batchDocument.assignedEntry = this.selectedInstance.ryanAssignedEntry;\r\n this.batchDocument.assignedQC = this.selectedInstance.ryanAssignedQC;\r\n this.clientInstanceId = this.selectedInstance.instanceId;\r\n this.documentIntakeUsers = await this._teamService.getAllAssignableUsers(false, false, undefined, undefined, this.selectedInstance.instanceId, undefined, undefined, true);\r\n }\r\n\r\n changed(): void {\r\n if(!_.trim(this.selectedInstanceName)) {\r\n this.selectedInstance = null;\r\n this.batchDocument.clientInstanceId = null;\r\n this.batchDocument.ultimatelyResponsible = null;\r\n this.batchDocument.assignedEntry = null;\r\n this.batchDocument.assignedQC = null;\r\n }\r\n }\r\n\r\n async onBlur(): Promise {\r\n if (!_.trim(this.selectedInstanceName) && this.selectedInstance) {\r\n this.selectedInstanceName = this.selectedInstance.instanceName;\r\n return;\r\n }\r\n\r\n if (_.trim(this.selectedInstanceName) && !this.selectedInstance) {\r\n const licensedClient = this.licensedClients.find(x => x.instanceName === this.selectedInstanceName);\r\n if (licensedClient) {\r\n await this.selectInstance(licensedClient);\r\n\r\n }\r\n }\r\n }\r\n\r\n intakeToLicensedInstanceChanged(e): void {\r\n this._productAnalyticsService.logEvent('intake-licensed-document');\r\n\r\n if (e.target.checked) {\r\n this.batchDocument.contact = null;\r\n\r\n if (!this.selectedInstance) {\r\n this.clientInstanceId = -1;\r\n }\r\n } else {\r\n this.batchDocument.contact = this._defaultContact;\r\n this.batchDocument.ultimatelyResponsible = null;\r\n this.batchDocument.assignedEntry = null;\r\n this.batchDocument.assignedQC = null;\r\n this.batchDocument.companyID = null;\r\n this.batchDocument.clientInstanceId = null;\r\n this.selectedInstance = null;\r\n this.selectedInstanceName = null;\r\n this.clientInstanceId = RyanInstanceId;\r\n this.company = null;\r\n }\r\n }\r\n\r\n removeSingleDocument(): void {\r\n this.singleFile = undefined;\r\n this.pagesPerItemList = _.range(1, 11);\r\n this.pageCount = 0;\r\n }\r\n\r\n viewMultiFile(file: File, multiFileViewer: TemplateRef): void {\r\n this.selectedMultiFile = file;\r\n this._modalService.show(multiFileViewer, Object.assign({}, { class: 'modal-lg' }));\r\n }\r\n\r\n removeMultiFile(index: number): void {\r\n this.multiFiles.splice(index, 1);\r\n }\r\n\r\n select(eventTarget: EventTarget): void {\r\n (eventTarget as HTMLInputElement).select();\r\n }\r\n\r\n async uploadClicked(): Promise {\r\n this._productAnalyticsService.logEvent('click-upload-documents');\r\n\r\n const isValid = this.batchDocument.documentTypeID\r\n && this.batchDocument.earliestDueDate\r\n && (\r\n (\r\n (this.batchDocument.contact && this.batchDocument.assignedEntry && this.batchDocument.ultimatelyResponsible)\r\n || this.batchDocument.assignToRyan\r\n )\r\n || (this.batchDocument.assignedEntry && this.batchDocument.ultimatelyResponsible && this.batchDocument.clientInstanceId)\r\n );\r\n\r\n if(!isValid) {\r\n this.saveAttempted = true;\r\n this._toastr.error('Please fill out the missing fields!');\r\n\r\n return;\r\n }\r\n\r\n if (this._assignToRyan || this.batchDocument.assignedQC && this.batchDocument.assignedQC.userID) {\r\n await this._createBatch();\r\n }\r\n else {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'No user has been assigned to QC. If you proceed to upload documents only Identify/Data Enter tasks will be created for these items (no Perform QC task will be created). Do you wish to proceed?',\r\n 'Upload with no QC User?'\r\n );\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._createBatch();\r\n }\r\n }\r\n\r\n companySelected(company: TypeaheadCompany): void {\r\n this._productAnalyticsService.logEvent('enter-company');\r\n\r\n this.company = company;\r\n this.batchDocument.companyID = company.companyID;\r\n }\r\n\r\n async assignToRyanChanged($event: any): Promise {\r\n this._assignToRyan = $event.target.checked;\r\n\r\n _.assign(this.batchDocument, {\r\n companyID: 0,\r\n assignedQC: undefined,\r\n assignedEntry: undefined,\r\n ultimatelyResponsible: undefined,\r\n contact: undefined,\r\n earliestDueDate: undefined,\r\n stateID: undefined,\r\n assessorID: undefined,\r\n collectorID: undefined,\r\n taxYear: undefined,\r\n commentBody: undefined,\r\n assignToRyan: this._assignToRyan\r\n });\r\n\r\n if (!this._assignToRyan) {\r\n this.batchDocument.contact = this._defaultContact;\r\n }\r\n\r\n this.company = undefined;\r\n\r\n this.clientInstanceId = this._assignToRyan\r\n ? RyanInstanceId\r\n : this._userInstanceService.getSelectedInstance().instanceId;\r\n }\r\n\r\n togglePerformOcr() {\r\n if(this.batchDocument.performOcr) {\r\n this._productAnalyticsService.logEvent('check-perform-ocr');\r\n }\r\n }\r\n\r\n selectDocumentCount() {\r\n this._productAnalyticsService.logEvent('select-document-count');\r\n }\r\n\r\n assignedQcChanged() {\r\n this._productAnalyticsService.logEvent('enter-assigned-qc');\r\n }\r\n\r\n documentTypeSelected() {\r\n const docType = find(this.documentTypeList, {attachmentTypeID: this.batchDocument.documentTypeID});\r\n\r\n if(docType) {\r\n this._productAnalyticsService.logEvent('select-document-type', { DocumentType: docType.attachmentTypeName});\r\n }\r\n }\r\n\r\n earliestDueDateChanged() {\r\n const numDays = moment(this.batchDocument.earliestDueDate).diff(new Date(), 'days');\r\n\r\n let DaysToEarliestDueDate;\r\n\r\n if(numDays < 5 ) {\r\n DaysToEarliestDueDate = '<5';\r\n } else if(numDays < 10) {\r\n DaysToEarliestDueDate = '<10';\r\n } else if(numDays < 20) {\r\n DaysToEarliestDueDate = '<20';\r\n } else if(numDays < 30) {\r\n DaysToEarliestDueDate = '<30';\r\n } else {\r\n DaysToEarliestDueDate = '30+';\r\n }\r\n\r\n this._productAnalyticsService.logEvent('enter-earliest-due-date', { DaysToEarliestDueDate });\r\n }\r\n\r\n assessorChanged() {\r\n this._productAnalyticsService.logEvent('select-assessor');\r\n this.getCollectorList();\r\n }\r\n\r\n collectorChanged() {\r\n this._productAnalyticsService.logEvent('select-collector');\r\n }\r\n\r\n taxYearChanged() {\r\n this._productAnalyticsService.logEvent('select-tax-year');\r\n }\r\n\r\n commentChanged() {\r\n this._productAnalyticsService.logEvent('enter-comment');\r\n }\r\n\r\n clearForm() {\r\n this._productAnalyticsService.logEvent('click-clear-form');\r\n this.initializeForm();\r\n }\r\n\r\n private _startCheckPageCount(): void {\r\n const pageCountTimer = this._timer.setInterval(() => {\r\n const iframe: HTMLIFrameElement = document.querySelector('iframe.preview-window');\r\n const pageCount = (iframe?.contentWindow as any)?.PDFViewerApplication?.pagesCount;\r\n if (pageCount > 0 && pageCountTimer !== undefined) {\r\n clearInterval(pageCountTimer);\r\n this._preparePageCount(pageCount);\r\n }\r\n }, 500);\r\n }\r\n\r\n private _preparePageCount(count: number): void {\r\n const pagesPerItem = this.batchDocument.pagesPerItem;\r\n let countTotal = count;\r\n\r\n if (this.batchDocument.excludeFirstXPages >= 0) {\r\n countTotal -= this.batchDocument.excludeFirstXPages;\r\n this.invalidPageCount = countTotal < 1;\r\n }\r\n\r\n if (countTotal > 0 && !this.invalidPageCount) {\r\n this.pagesPerItemList = this._getPagesPerItem(countTotal, countTotal);\r\n\r\n //This is to preserve the pagesPerItem selection if we can... if not set to null to trigger required error so users know to change it\r\n if (this.batchDocument.pagesPerItem) {\r\n if (!_.includes(this.pagesPerItemList, this.batchDocument.pagesPerItem)) {\r\n this.batchDocument.pagesPerItem = null;\r\n }\r\n }\r\n this.pageCount = count;\r\n\r\n if (pagesPerItem && (this.pageCount / pagesPerItem) > 999) {\r\n if (!_.includes(this.pagesPerItemList, pagesPerItem)) {\r\n this.batchDocument.pagesPerItem = this.pagesPerItemList[0];\r\n }\r\n }\r\n }\r\n }\r\n\r\n private async _createBatch(): Promise {\r\n const files = this.batchDocument.splitDocument ? [this.singleFile] : this.multiFiles;\r\n\r\n // If Tax Bill and Assessment Notice were not selected as the document type, ensure OCR is not performed\r\n if (this.batchDocument.performOcr\r\n && (this.batchDocument.documentTypeID !== Core.AttachmentTypes.TaxBill\r\n && this.batchDocument.documentTypeID !== Core.AttachmentTypes.AssessmentNotice)) {\r\n this.batchDocument.performOcr = false;\r\n }\r\n\r\n try {\r\n this.uploading = true;\r\n this._navigationService.enableNavWarning(this.NAVIGATE_WARNING);\r\n\r\n const response = await this._documentIntakeService.sendBatchDocuments(this.batchDocument, files);\r\n\r\n this._messageModalService.alertList([`Batch Number: ${response.batchNumber}`, `Items Processed: ${response.intakeItems.length}`], 'Document Intake Successful');\r\n\r\n this.singleFile = undefined;\r\n this.multiFiles = [];\r\n } finally {\r\n this.uploading = false;\r\n this._navigationService.disableNavWarning();\r\n }\r\n }\r\n\r\n private _getPagesPerItem(totalPages: number, pages: number): number[] {\r\n if(pages === 0) {\r\n return [];\r\n }\r\n\r\n if(totalPages % pages === 0) {\r\n return [totalPages / pages, ...this._getPagesPerItem(totalPages, pages - 1)];\r\n } else {\r\n return this._getPagesPerItem(totalPages, pages - 1);\r\n }\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n\r\n
\r\n
\r\n
\r\n Instance:\r\n
\r\n
\r\n {{clientDetail.instanceName}}\r\n
\r\n
\r\n
\r\n
\r\n Client Contact:\r\n
\r\n
\r\n {{clientContactName}}\r\n
\r\n
\r\n
\r\n
\r\n Special Instructions:\r\n
\r\n
\r\n {{clientDetail.clientSpecialInstructions}}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n Ryan Assignments\r\n
\r\n
\r\n
\r\n
\r\n User Group:\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n Ultimately Resp:\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n Assigned Entry:\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n Assigned QC:\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { DocumentIntakeLicensedClientDetailRepository } from '../documentIntakeLicensedClient.repository';\r\nimport * as _ from 'lodash';\r\nimport { TeamService } from 'src/app/Team/team.service';\r\n\r\nexport interface DocumentIntakeLicensedClientDetailComponentParams {\r\n client: Core.DocumentIntakeLicensedClientModel;\r\n}\r\n\r\n@Component({\r\n selector: 'document-intake-licensed-client-detail',\r\n templateUrl: './documentIntakeLicensedClientDetail.component.html',\r\n styleUrls: ['./documentIntakeLicensedClientDetail.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class DocumentIntakeLicensedClientDetailComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _documentIntakeLicensedClientRepository: DocumentIntakeLicensedClientDetailRepository,\r\n private readonly _teamService: TeamService) {\r\n }\r\n\r\n params: DocumentIntakeLicensedClientDetailComponentParams;\r\n result: Core.DocumentIntakeLicensedClientModel;\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n clientDetail: Core.DocumentIntakeLicensedClientModel;\r\n groups: Core.GroupModel[] = [];\r\n users: Core.UserTeamModel[] = [];\r\n saveAttempted: boolean = false;\r\n clientContactName: string;\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n async ngOnInit(): Promise {\r\n const busyLoading = 'load-Metadata';\r\n this.busyIndicatorMessageManager.add('Loading', busyLoading);\r\n\r\n try{\r\n const requests: Promise[] = [\r\n lastValueFrom(this._documentIntakeLicensedClientRepository.getDocumentGroupList())\r\n ];\r\n \r\n if (this.params.client.ryanUserGroupId) {\r\n requests.push(this._teamService.getAllForGroup(this.params.client.ryanUserGroupId));\r\n requests.push(lastValueFrom(this._documentIntakeLicensedClientRepository.get(this.params.client.instanceId)));\r\n }\r\n const responses = await Promise.all(requests);\r\n\r\n this.groups = responses[0];\r\n this.groups.splice(0, 0, {} as Core.GroupModel);\r\n\r\n this.users = responses[1];\r\n\r\n if (this.params.client.ryanUserGroupId) {\r\n this.clientDetail = responses[2];\r\n } else {\r\n this.clientDetail = _.cloneDeep(this.params.client);\r\n }\r\n\r\n this.clientContactName = `${this.clientDetail.clientContact.firstName} ${this.clientDetail.clientContact.lastName}`;\r\n }\r\n finally{\r\n this.busyIndicatorMessageManager.remove(busyLoading);\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.unsubscribe();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgId = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgId);\r\n\r\n try {\r\n this.result = await lastValueFrom(this._documentIntakeLicensedClientRepository.updateSettings(this.clientDetail));\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n ultimatelyResponsibleChosen(user: Core.UserTeamModel): void {\r\n if(user) {\r\n this.clientDetail.ryanUltimatelyResp = _.cloneDeep(user);\r\n }\r\n }\r\n\r\n assignedEntryChosen(user: Core.UserTeamModel): void {\r\n if(user) {\r\n this.clientDetail.ryanAssignedEntry = _.cloneDeep(user);\r\n }\r\n }\r\n\r\n assignedQCChosen(user: Core.UserTeamModel): void {\r\n if(user) {\r\n this.clientDetail.ryanAssignedQC = _.cloneDeep(user);\r\n }\r\n }\r\n\r\n async groupSelected(): Promise{\r\n await this.updateUsers();\r\n this.clientDetail.ryanAssignedEntry = null;\r\n this.clientDetail.ryanUltimatelyResp = null;\r\n this.clientDetail.ryanAssignedQC = null;\r\n }\r\n\r\n async updateUsers(): Promise{\r\n this.users = await this._teamService.getAllForGroup(this.clientDetail.ryanUserGroupId);\r\n }\r\n\r\n get canSave(): boolean {\r\n return !!this.clientDetail && !!this.clientDetail.ryanUserGroupId && !!this.clientDetail.ryanUltimatelyResp &&\r\n !!this.clientDetail.ryanAssignedEntry && !!this.clientDetail.ryanAssignedQC;\r\n }\r\n}\r\n"," 0\">\r\n
\r\n
\r\n

Licensed Client Documents

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
InstanceCompanyStatusAssignments
\r\n {{client.instanceName}}\r\n \r\n {{client.topLevelCompanyName}}\r\n \r\n {{getStatus(client)}}\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { DocumentIntakeLicensedClientDetailRepository } from '../documentIntakeLicensedClient.repository';\r\nimport {\r\n DocumentIntakeLicensedClientDetailComponent,\r\n DocumentIntakeLicensedClientDetailComponentParams\r\n} from '../Document-Intake-Licensed-Client-Detail/documentIntakeLicensedClientDetail.component';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\n\r\n@Component({\r\n selector: 'document-intake-licensed-client-list',\r\n templateUrl: './documentIntakeLicensedClientList.component.html',\r\n styleUrls: ['./documentIntakeLicensedClientList.component.scss']\r\n})\r\nexport class DocumentIntakeLicensedClientListComponent implements OnInit {\r\n\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _documentIntakeLicensedClientDetailRepository: DocumentIntakeLicensedClientDetailRepository,\r\n private readonly _modalService: WeissmanModalService,) {\r\n }\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n licensedClients: Core.DocumentIntakeLicensedClientModel[];\r\n\r\n async ngOnInit(): Promise {\r\n if(!this._restrictService.isInRole(Roles.LICENSEDDOCUMENTSERVICES)) {\r\n this._routerService.go('unauthorizedAccess', {});\r\n return Promise.resolve();\r\n }\r\n\r\n const busyLoading = 'loading';\r\n this.busyIndicatorMessageManager.add('Loading', busyLoading);\r\n\r\n try {\r\n this.licensedClients = await lastValueFrom(this._documentIntakeLicensedClientDetailRepository.getList());\r\n this.licensedClients.sort((a, b) => a.instanceName.localeCompare(b.instanceName));\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyLoading);\r\n }\r\n }\r\n\r\n getStatus(client: Core.DocumentIntakeLicensedClientModel) : string {\r\n let status = '';\r\n\r\n if (client.ryanUserGroupId) {\r\n status = 'Invite Accepted';\r\n } else if (client.cancellationDate) {\r\n status = 'Discontinued';\r\n } else {\r\n status = 'Invited';\r\n }\r\n\r\n return status;\r\n }\r\n\r\n async configure(client: Core.DocumentIntakeLicensedClientModel) : Promise {\r\n const params: DocumentIntakeLicensedClientDetailComponentParams = {\r\n client: client\r\n };\r\n const result = await this._modalService.showAsync(DocumentIntakeLicensedClientDetailComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const licensedClient = this.licensedClients.find(x => x.instanceId == result.instanceId);\r\n licensedClient.ryanUserGroupId = result.ryanUserGroupId;\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { AttachmentModule } from '../Attachment/attachment.module';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { CompanyModule } from '../Entity/Company/company.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { DocumentIntakeComponent } from './Document-Intake/document.intake.component';\r\nimport { DocumentIntakeService } from './Document-Intake/document.intake.service';\r\nimport { DocumentIntakeLicensedClientListComponent } from './Document-Intake-Licensed-Clients/Document-Intake-Licensed-Client-List/documentIntakeLicensedClientList.component';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { DocumentIntakeLicensedClientDetailRepository } from './Document-Intake-Licensed-Clients/documentIntakeLicensedClient.repository';\r\nimport { DocumentIntakeLicensedClientDetailComponent } from './Document-Intake-Licensed-Clients/Document-Intake-Licensed-Client-Detail/documentIntakeLicensedClientDetail.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n CompanyModule,\r\n AttachmentModule,\r\n BusyIndicatorModule\r\n ],\r\n declarations: [\r\n DocumentIntakeComponent,\r\n DocumentIntakeLicensedClientListComponent,\r\n DocumentIntakeLicensedClientDetailComponent],\r\n providers: [\r\n DocumentIntakeService,\r\n DocumentIntakeLicensedClientDetailRepository],\r\n exports: [DocumentIntakeComponent]\r\n})\r\nexport class DocumentsModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('documentIntake', DocumentIntakeComponent);\r\n hybridAdapterUtility.downgradeNg2Component('documentIntakeLicensedClientList', DocumentIntakeLicensedClientListComponent);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n {{details.title}}\r\n Status not detected\r\n {{details.message}}\r\n
\r\n
\r\n \r\n Download\r\n \r\n \r\n Cancel\r\n \r\n \r\n Navigate\r\n \r\n \r\n Click to dismiss\r\n \r\n \r\n Refresh \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n {{details.progress}}%\r\n \r\n \r\n \r\n \r\n
\r\n {{details.title}}\r\n {{details.message}}\r\n
\r\n
\r\n
\r\n
\r\n\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ProgressIndicator } from '../../Models/progressIndicator.model';\r\nimport { SnackSize } from '../snackBar.service';\r\nimport { TimerService } from '../../../UI-Lib/Utilities';\r\nimport { WebsocketListenerService } from '../../../Compliance/websocketListener.service';\r\nimport { LongRunningProcessRepository } from '../../../Compliance/Repositories';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'snack',\r\n templateUrl: './snack.component.html',\r\n styleUrls: ['../../busyIndicator.component.scss', './snack.component.scss']\r\n})\r\nexport class SnackComponent implements OnInit {\r\n constructor(private readonly _timerService: TimerService,\r\n private readonly _longRunningProcessRepository: LongRunningProcessRepository,\r\n private readonly _websocketListenerService: WebsocketListenerService\r\n ) { }\r\n\r\n @Input() details: ProgressIndicator;\r\n @Input() size: SnackSize;\r\n @Input() signalRDisconnected: boolean;\r\n\r\n snackSize = SnackSize;\r\n\r\n loadingWaitComplete: boolean;\r\n manualUpdateLoading: boolean;\r\n\r\n ngOnInit(): void {\r\n this._timerService.setTimeout(x => this.loadingWaitComplete = true, 3000);\r\n }\r\n\r\n get cancelDisabled(): boolean {\r\n return this.details.cancelling || (this.details.canDownload && !this.details.downloadWithCancel) ? !this.details.isComplete : false;\r\n }\r\n\r\n get showCancel(): boolean {\r\n return this.details.canCancel || (this.details.isComplete && this.details.canNavigate) || (this.details.isComplete && this.details.canDownload);\r\n }\r\n\r\n /**\r\n * If SignalR is disconnected the user can manually check for updates\r\n */\r\n async refreshFromLRPServer(): Promise {\r\n if (this.manualUpdateLoading) {\r\n return;\r\n }\r\n this.manualUpdateLoading = true;\r\n const lrp = await lastValueFrom(this._longRunningProcessRepository.get(this.details.longRunningProcessId));\r\n this._websocketListenerService.updateLRPManually(lrp);\r\n this.manualUpdateLoading = false;\r\n }\r\n\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ProgressIndicator } from '../Models/progressIndicator.model';\r\nimport { SnackBarService, SnackSize } from './snackBar.service';\r\nimport { WebsocketListenerService } from '../../Compliance/websocketListener.service';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { LongRunningProcessRepository } from '../../Compliance/Repositories';\r\n\r\n@Component({\r\n selector: 'snack-bar',\r\n templateUrl: './snackBar.component.html',\r\n styleUrls: ['./snackBar.component.scss']\r\n})\r\nexport class SnackBarComponent implements OnInit {\r\n constructor(private readonly _snackBarService: SnackBarService,\r\n private readonly _websocketListenerService: WebsocketListenerService,\r\n private readonly _longRunningProcessRepository: LongRunningProcessRepository\r\n ) { }\r\n\r\n size: SnackSize;\r\n snacks: ProgressIndicator[] = [];\r\n snackSize = SnackSize;\r\n\r\n signalRDisconnected: boolean;\r\n manualUpdateLoading: boolean;\r\n\r\n ngOnInit(): void {\r\n this.signalRDisconnected = this._websocketListenerService.signalRDisconnected;\r\n\r\n this._websocketListenerService.longRunningProcessDisconnected$.subscribe(x => {\r\n this.signalRDisconnected = true;\r\n });\r\n\r\n this._websocketListenerService.longRunningProcessReconnected$.subscribe(x => {\r\n this.signalRDisconnected = false;\r\n this.refreshFromLRPServer();\r\n });\r\n\r\n this._snackBarService.longRunningProcesses.subscribe((snacks) => {\r\n this.snacks = snacks;\r\n });\r\n\r\n this._snackBarService.displayState.subscribe((state) => {\r\n if (state === SnackSize.Large || state === SnackSize.Hidden) {\r\n this.size = state;\r\n }\r\n });\r\n\r\n this._snackBarService.start();\r\n }\r\n\r\n /**\r\n * Hide the snack bar into the navigation\r\n */\r\n hideSnackBar(): void {\r\n this._snackBarService.hideSnackBar();\r\n }\r\n\r\n /**\r\n * Tracker for ngFor\r\n * @param index\r\n * @param item\r\n */\r\n processIdTracker(index: number, item: ProgressIndicator): string {\r\n return item.identifier;\r\n }\r\n\r\n /**\r\n * If SignalR is disconnected the user can manually check for updates\r\n */\r\n async refreshFromLRPServer(): Promise {\r\n if (this.manualUpdateLoading) {\r\n return;\r\n }\r\n this.manualUpdateLoading = true;\r\n const searchModel: Compliance.LongRunningProcessSearchModel = {\r\n notAcknowledged: true,\r\n allUsers: false\r\n };\r\n const lrp$ = this._longRunningProcessRepository.getList(searchModel);\r\n const lrps = await lastValueFrom(lrp$);\r\n lrps.data.forEach(x => {\r\n this._websocketListenerService.updateLRPManually(x);\r\n });\r\n this.manualUpdateLoading = false;\r\n }\r\n\r\n}\r\n","import { OnInit, Component, HostListener } from '@angular/core';\r\nimport { ProgressIndicator } from '../../Models/progressIndicator.model';\r\nimport { SnackSize, SnackBarService } from '../snackBar.service';\r\n\r\n@Component({\r\n selector: 'snack-message',\r\n template: `\r\n
\r\n
\r\n \r\n \r\n {{processing}}\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n {{complete}}\r\n \r\n
\r\n
\r\n `,\r\n styleUrls: ['./snackMessage.component.scss']\r\n})\r\nexport class SnackMessageComponent implements OnInit {\r\n constructor(private readonly _snackBarService: SnackBarService) { }\r\n\r\n size: SnackSize;\r\n processes: ProgressIndicator[] = [];\r\n complete: number = 0;\r\n processing: number;\r\n\r\n @HostListener('mouseenter') onMouseEnter() {\r\n if (this.size === SnackSize.Hidden) {\r\n this._snackBarService.showMiniSnackBar();\r\n }\r\n }\r\n\r\n @HostListener('mouseleave') onMouseLeave() {\r\n if (this.size === SnackSize.Small) {\r\n this._snackBarService.hideMiniSnackBar();\r\n }\r\n }\r\n\r\n ngOnInit(): void {\r\n this._snackBarService.displayState.subscribe(size => this.size = size);\r\n this._snackBarService.longRunningProcesses.subscribe(processes => {\r\n this.processes = processes;\r\n this.complete = processes.reduce((acc: number, p: ProgressIndicator) => (p.isComplete) ? (acc += 1) : acc, 0);\r\n this.processing = processes.length - this.complete;\r\n });\r\n }\r\n\r\n open(): void {\r\n this._snackBarService.showSnackBar();\r\n }\r\n\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { SnackBarComponent } from './snackBar.component';\r\nimport { SnackComponent } from './Snack/snack.component';\r\nimport { SnackMessageComponent } from './SnackMessage/snackMessage.component';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { HelpModule } from '../../UI-Lib/Help-Tooltip/help.module';\r\nimport { SnackBarService } from './snackBar.service';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n HelpModule\r\n ],\r\n declarations: [\r\n SnackBarComponent,\r\n SnackComponent,\r\n SnackMessageComponent\r\n ],\r\n exports: [\r\n SnackBarComponent,\r\n SnackMessageComponent\r\n ]\r\n})\r\nexport class SnackBarModule {\r\n static setupModule(): void {\r\n hybridAdapterUtility.downgradeNg2Component('snackBar', SnackBarComponent);\r\n hybridAdapterUtility.downgradeNg2Component('snackMessage', SnackMessageComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('snackBarService', SnackBarService);\r\n }\r\n}\r\n","\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { AceUIIcon, IMenuAction, IPortalBrandingConfig } from '@ace/shared';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { Subject, tap } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { InstanceRights, RestrictService } from '../../Common/Permissions/restrict.service';\r\nimport { AppStates, AppStateService } from '../../Layout/appStateService';\r\nimport { AdvancedSearchPersistenceService } from '../../Search/Advanced/advancedSearchPersistence.service';\r\nimport { ActionViewPersistenceService } from '../../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { TimerService } from '../../UI-Lib/Utilities';\r\nimport { branding, TopNavRoles, TopNavService } from '../Top-Nav/topNav.service';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\n\r\ninterface AnalyticsEvent {\r\n key: string;\r\n params?: { [key: string]: any };\r\n}\r\n\r\ninterface Analytics {\r\n [key: string]: AnalyticsEvent;\r\n}\r\n\r\n@Component({\r\n selector: 'side-nav',\r\n templateUrl: './sideNav.component.html',\r\n styleUrls: ['./sideNav.component.scss']\r\n})\r\nexport class SideNavComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _router: UIRouter,\r\n private readonly _topNavService: TopNavService,\r\n private readonly _appStateService: AppStateService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _timerService: TimerService,\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _userInstanceService: UserInstanceService) {\r\n this._appStateService.appState$.pipe(\r\n tap(state => {\r\n if (state === AppStates.LoggedIn) {\r\n if (!this.roles) {\r\n this.roles = this._topNavService.roles();\r\n }\r\n this._setLoggedInMenu();\r\n } else {\r\n this._setLoggedOutMenu();\r\n }\r\n })\r\n ).subscribe();\r\n }\r\n\r\n closed = true;\r\n show: boolean;\r\n hiding: boolean;\r\n\r\n roles: TopNavRoles;\r\n branding: IPortalBrandingConfig = branding;\r\n navActions: IMenuAction[] = [];\r\n currentUrl: string = '';\r\n\r\n private _analytics: Analytics = {\r\n stateJurisdictionCommandCenter: { key: 'click-manage-admin-state-juris-CC' },\r\n taxRateCommandCenter: { key: 'click-manage-admin-tax-rate-CC' },\r\n paymentBatchCommandCenter: { key: 'click-manage-payment-batch-CC' }\r\n };\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this.branding.footerPortalHref = this._featureFlagsService.taxDotComBase;\r\n this._topNavService.sideNavOpen$.pipe(takeUntil(this._destroy$)).subscribe((isOpen: boolean) => {\r\n const url = window.location.href.substring(window.location.origin.length);\r\n this.currentUrl = url.substring(2);\r\n if (isOpen) {\r\n this.show = isOpen;\r\n this._timerService.setTimeout(() => {\r\n this.closed = !isOpen;\r\n }, 0);\r\n } else {\r\n this.closed = !isOpen;\r\n this.hiding = true;\r\n this._timerService.setTimeout(() => {\r\n this.show = isOpen;\r\n this.hiding = false;\r\n }, 300);\r\n }\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n close(): void {\r\n if (this.show) {\r\n this._topNavService.sideNavOpen = false;\r\n }\r\n }\r\n\r\n routeTo(target: string): void {\r\n this._router.stateService.transitionTo(target);\r\n }\r\n\r\n handleActionTriggered(action: CustomEvent) {\r\n if (action.detail === 'home') {\r\n this._topNavService.sideNavOpen = false;\r\n this._router.stateService.transitionTo(action.detail);\r\n return;\r\n }\r\n switch (action.detail.key) {\r\n case 'newSmart':\r\n this._advancedSearchPersistenceService.clearSearchData();\r\n this._productAnalyticsService.logEvent('click-explore-SMART');\r\n this.routeTo('search');\r\n break;\r\n case 'newAV':\r\n this._actionViewPersistenceService.clearSavedData();\r\n this._productAnalyticsService.logEvent('click-act-new');\r\n this.routeTo('actionview');\r\n break;\r\n default:\r\n const menuAction: IMenuAction = action.detail;\r\n if (menuAction.routerOutlet) {\r\n this.routeTo(menuAction.routerOutlet);\r\n }\r\n if (this._analytics[menuAction.key]) {\r\n const event = this._analytics[menuAction.key];\r\n this._productAnalyticsService.logEvent(event.key, event.params);\r\n }\r\n }\r\n this._topNavService.sideNavOpen = false;\r\n }\r\n\r\n private _setLoggedInMenu() {\r\n const nav: IMenuAction[] = [\r\n {\r\n isHeading: true,\r\n key: 'propertyPoint',\r\n content: 'PropertyPoint'\r\n },\r\n {\r\n key: 'smart',\r\n content: 'SMARTs',\r\n children: [\r\n { key: 'newSmart', content: 'New SMART', routerOutlet: 'search', routerLink: ['#', '/search/'] },\r\n {\r\n key: 'systemSmart',\r\n content: 'System SMARTs',\r\n routerOutlet: 'savedSmart.system',\r\n routerLink: ['#', '/saved', '/smart', '/system']\r\n },\r\n {\r\n key: 'savedSmart',\r\n content: 'My Saved SMARTs',\r\n routerOutlet: 'savedSmart.user',\r\n routerLink: ['#', '/saved', '/smart', '/user']\r\n }\r\n ]\r\n },\r\n {\r\n key: 'actionView',\r\n content: 'Action Views',\r\n children: [\r\n {\r\n key: 'newAV',\r\n content: 'New Action View',\r\n routerOutlet: 'actionview',\r\n routerLink: ['#', '/actionview/']\r\n },\r\n {\r\n key: 'systemAV',\r\n content: 'System Action Views',\r\n routerOutlet: 'savedActionView.system',\r\n routerLink: ['#', '/saved', '/action-view', '/system']\r\n },\r\n {\r\n key: 'savedAV',\r\n content: 'My Saved Action Views',\r\n routerOutlet: 'savedActionView.user',\r\n routerLink: ['#', '/saved', '/action-view', '/user']\r\n }\r\n ]\r\n },\r\n {\r\n key: 'report',\r\n content: 'Reports',\r\n children: [\r\n {\r\n key: 'systemReport',\r\n content: 'System Reports',\r\n routerOutlet: 'savedReport.system',\r\n routerLink: ['#', '/saved', '/report', '/system']\r\n },\r\n {\r\n key: 'userReport',\r\n content: 'My Saved Reports',\r\n routerOutlet: 'savedReport.user',\r\n routerLink: ['#', '/saved', '/report', '/user']\r\n }\r\n ]\r\n }\r\n ];\r\n\r\n // Add Command Centers\r\n const commandCenters = this._getCommandCenters();\r\n if (commandCenters) {\r\n nav.push(commandCenters);\r\n }\r\n\r\n // Add Intake Documents\r\n if (this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT)) {\r\n nav.push({\r\n key: 'intakeDocuments',\r\n content: 'Intake Documents',\r\n routerOutlet: 'documentintake',\r\n routerLink: ['#', '/documentintake']\r\n });\r\n }\r\n\r\n // Add States Map\r\n nav.push({\r\n key: 'stateJurisdiction',\r\n content: 'States & Jurisdictions',\r\n routerOutlet: 'states',\r\n routerLink: ['#', '/states']\r\n });\r\n\r\n // Add Manage and/or Diagnostic\r\n if (this.roles.hasAdminRole || this.roles.hasAddNewCompanyRole || this.roles.hasAddNewInstanceRole) {\r\n nav.push({ key: 'manage', content: 'Manage', routerOutlet: 'manage', routerLink: ['#', '/manage'] });\r\n }\r\n\r\n if (this.roles.hasAdminRole && (this.roles.hasAdminOperationsView || this.roles.hasAdminOperationsEdit)) {\r\n nav.push({\r\n key: 'diagnostic',\r\n content: 'Diagnostic',\r\n routerOutlet: 'diagnostic',\r\n routerLink: ['#', '/diagnostic']\r\n });\r\n }\r\n\r\n // Add Snapshot\r\n nav.push({\r\n isHeading: true,\r\n key: 'propertyTax',\r\n content: 'Property Tax'\r\n },\r\n {\r\n key: 'snapshot',\r\n content: 'Snapshot',\r\n url: `${this._featureFlagsService.taxDotComBase}/apps/PropertyTaxSnapshot/`,\r\n icon: AceUIIcon.WindowRestore\r\n });\r\n\r\n this.navActions = nav;\r\n }\r\n\r\n private _setLoggedOutMenu() {\r\n this.navActions = [];\r\n }\r\n\r\n private _getCommandCenters(): IMenuAction {\r\n const commandCenters: IMenuAction = {\r\n key: 'commandCenters',\r\n content: 'Command Centers',\r\n children: []\r\n };\r\n\r\n // all users can view the state & jurisdiction command center read only\r\n commandCenters.children.push({\r\n key: 'stateJurisdictionCommandCenter',\r\n content: 'State & Jurisdiction Command Center',\r\n routerOutlet: 'stateJurisdictionCommandCenter',\r\n routerLink: ['#', '/state-jurisdiction-command-center']\r\n });\r\n\r\n if (this._userInstanceService.isSingleInstanceSelected() && (this.roles.hasViewRyanPrivatePermissions || this.roles.hasEditRyanPrivatePermissions)) {\r\n commandCenters.children.push({\r\n key: 'appealRecommendationCommandCenter',\r\n content: 'Appeal Recommendation Command Center',\r\n routerOutlet: 'appealRecommendationCommandCenter',\r\n routerLink: ['#', '/appealRecommendationCommandCenter']\r\n });\r\n }\r\n\r\n if (this._featureFlagsService.featureFlags.enablePaymentBatch && (this.roles.hasViewRyanPrivatePermissions || this.roles.hasEditRyanPrivatePermissions)) {\r\n commandCenters.children.push({\r\n key: 'paymentBatchCommandCenter',\r\n content: 'Payment Batch Command Center',\r\n routerOutlet: 'paymentBatchCommandCenter',\r\n routerLink: ['#', '/payment-batch-command-center']\r\n });\r\n }\r\n\r\n if (this.roles.hasViewRyanPrivatePermissions || this.roles.hasEditRyanPrivatePermissions) {\r\n commandCenters.children.push({\r\n key: 'taxRateCommandCenter',\r\n content: 'Tax Rate Command Center',\r\n routerOutlet: 'taxRateCommandCenter',\r\n routerLink: ['#', '/tax-rate-command-center']\r\n });\r\n }\r\n\r\n return commandCenters.children.length ? commandCenters : null;\r\n }\r\n}\r\n","import {\r\n AceUIColorStyle,\r\n AceUINeutralColorStyle,\r\n AceUIState,\r\n IIconDisplay,\r\n AceUIExtendedColorStyle,\r\n isString,\r\n AceUIIcon,\r\n ButtonState,\r\n BannerState\r\n} from '@ace/shared';\r\nimport { getThemeVariable, RGB } from './themeHelper';\r\n\r\nexport interface IAceColorModel {\r\n key: string;\r\n fgWhite?: boolean;\r\n icon?: AceUIIcon;\r\n}\r\n\r\nexport interface IAceColorModelWithKey {\r\n colorType: AceColorType;\r\n key: string;\r\n fgWhite?: boolean;\r\n icon?: AceUIIcon;\r\n}\r\n\r\nexport type AceColorType = AceUIColorStyle | ButtonState | BannerState | string;\r\n\r\nexport const aceColorLookup = new Map([\r\n [AceUINeutralColorStyle.Neutral050, { key: 'neutral-050' }],\r\n [AceUINeutralColorStyle.Neutral100, { key: 'neutral-100' }],\r\n [AceUINeutralColorStyle.Neutral200, { key: 'neutral-200' }],\r\n [AceUINeutralColorStyle.Neutral300, { key: 'neutral-300' }],\r\n [AceUINeutralColorStyle.Neutral400, { key: 'neutral-400', fgWhite: true }],\r\n [AceUINeutralColorStyle.Neutral500, { key: 'neutral-500', fgWhite: true }],\r\n [AceUINeutralColorStyle.Neutral600, { key: 'neutral-600', fgWhite: true }],\r\n [AceUINeutralColorStyle.Neutral700, { key: 'neutral-700', fgWhite: true }],\r\n [AceUINeutralColorStyle.Neutral800, { key: 'neutral-800', fgWhite: true }],\r\n [AceUINeutralColorStyle.Neutral900, { key: 'neutral-900', fgWhite: true }],\r\n [AceUINeutralColorStyle.White, { key: 'neutral-white' }],\r\n [AceUINeutralColorStyle.Black, { key: 'neutral-black', fgWhite: true }],\r\n\r\n [AceUIState.Inactive, { key: 'neutral-300', icon: AceUIIcon.Exclamation }],\r\n [AceUIState.Primary, { key: 'action', fgWhite: true, icon: AceUIIcon.InfoCircle }],\r\n [AceUIState.Info, { key: 'info', fgWhite: true, icon: AceUIIcon.InfoCircle }],\r\n [AceUIState.Secondary, { key: 'info', fgWhite: true, icon: AceUIIcon.InfoCircle }],\r\n [AceUIState.Success, { key: 'success', fgWhite: true, icon: AceUIIcon.SuccessOutline }],\r\n [AceUIState.Error, { key: 'danger', fgWhite: true, icon: AceUIIcon.TimesCircle }],\r\n\r\n [AceUIExtendedColorStyle.HoverHighlight, { key: 'hover-highlight' }],\r\n [AceUIExtendedColorStyle.Highlight, { key: 'highlight' }],\r\n\r\n [ButtonState.Action, { key: 'action', fgWhite: true, icon: AceUIIcon.InfoCircle }],\r\n [ButtonState.Success, { key: 'success', fgWhite: true, icon: AceUIIcon.Check }],\r\n [ButtonState.Danger, { key: 'danger', fgWhite: true, icon: AceUIIcon.TimesCircle }],\r\n\r\n [BannerState.Info, { key: 'success', fgWhite: true, icon: AceUIIcon.InfoCircle }],\r\n [BannerState.Success, { key: 'success', fgWhite: true, icon: AceUIIcon.SuccessOutline }],\r\n [BannerState.Warning, { key: 'warning', fgWhite: true, icon: AceUIIcon.ExclamationTriangle }],\r\n [BannerState.Danger, { key: 'danger', fgWhite: true, icon: AceUIIcon.TimesCircle }]\r\n]);\r\n\r\nexport function getColorModel(colorType: AceColorType): IAceColorModelWithKey | undefined {\r\n const colorModel = aceColorLookup.get(colorType);\r\n if (colorModel) {\r\n return { ...colorModel, colorType };\r\n }\r\n return undefined;\r\n}\r\n\r\nexport function colorStyleToCssClass(prefix: string, colorStyle?: AceColorType, enableForegroud?: boolean): object | undefined {\r\n const model = aceColorLookup.get(colorStyle);\r\n if (model) {\r\n const result = {};\r\n result[`${prefix}${model.key}`] = true;\r\n if (enableForegroud) {\r\n if (model.fgWhite) {\r\n result['text-white'] = true;\r\n }\r\n }\r\n return result;\r\n }\r\n return undefined;\r\n}\r\n\r\nexport function stateToColorVar(state?: AceColorType): string | undefined {\r\n if (state) {\r\n const colorObj = colorStyleToCssClass('', state, false) || {};\r\n const colorStyle = Object.keys(colorObj);\r\n if (colorStyle.length > 0) {\r\n return `var(--ace-${colorStyle[0]})`;\r\n } else if (isString(state)) {\r\n return state;\r\n }\r\n }\r\n return undefined;\r\n}\r\n\r\nexport function stateToColor(state?: AceColorType): string | undefined {\r\n if (state) {\r\n const colorObj = colorStyleToCssClass('', state, false) || {};\r\n const colorStyle = Object.keys(colorObj);\r\n if (colorStyle.length > 0) {\r\n return getThemeVariable(colorStyle[0]);\r\n }\r\n }\r\n return undefined;\r\n}\r\n\r\nexport function forEachAceColor(callback: (colorStyle: IAceColorModel, colorType: AceColorType) => void) {\r\n [AceUINeutralColorStyle, AceUIExtendedColorStyle, AceUIState].forEach(colorEnum => {\r\n Object.keys(colorEnum)\r\n .filter(k => isNaN(Number(k)))\r\n .forEach((key: string) => {\r\n const colorType = colorEnum[key];\r\n if (colorType) {\r\n const colorStyle = aceColorLookup.get(colorEnum[key]);\r\n if (colorStyle) {\r\n callback(colorStyle, colorType);\r\n }\r\n }\r\n });\r\n });\r\n}\r\n\r\nexport function colorStyleToIcon(colorStyle?: AceColorType): IIconDisplay | undefined {\r\n const model = aceColorLookup.get(colorStyle);\r\n if (model?.icon) {\r\n return { icon: model.icon };\r\n }\r\n return undefined;\r\n}\r\n\r\nexport function rgbToHex(rgb) {\r\n rgb = rgb.match(/^rgb\\((\\d+),\\s*(\\d+),\\s*(\\d+)\\)$/);\r\n function hex(x) {\r\n return (`0${ parseInt(x, 10).toString(16)}`).slice(-2);\r\n }\r\n return `#${ hex(rgb[1]) }${hex(rgb[2]) }${hex(rgb[3])}`;\r\n}\r\n\r\n// https://css-tricks.com/converting-color-spaces-in-javascript/\r\nexport function hexToHsl(H) {\r\n // Convert hex to RGB first\r\n let { r, g, b } = hexToRGB(H);\r\n\r\n // Then to HSL\r\n r /= 255;\r\n g /= 255;\r\n b /= 255;\r\n const cmin = Math.min(r, g, b);\r\n const cmax = Math.max(r, g, b);\r\n const delta = cmax - cmin;\r\n let h = 0;\r\n let s = 0;\r\n let l = 0;\r\n\r\n if (delta === 0) h = 0;\r\n else if (cmax === r) h = ((g - b) / delta) % 6;\r\n else if (cmax === g) h = (b - r) / delta + 2;\r\n else h = (r - g) / delta + 4;\r\n\r\n h = Math.round(h * 60);\r\n\r\n if (h < 0) h += 360;\r\n\r\n l = (cmax + cmin) / 2;\r\n s = delta === 0 ? 0 : delta / (1 - Math.abs(2 * l - 1));\r\n s = +(s * 100).toFixed(1);\r\n l = +(l * 100).toFixed(1);\r\n\r\n return { h, s, l };\r\n}\r\n\r\n/** Convert hex to RGB */\r\nexport function hexToRGB(H) {\r\n let r: any = 0;\r\n let g: any = 0;\r\n let b: any = 0;\r\n if (H.length === 4) {\r\n r = `0x${ H[1] }${H[1]}`;\r\n g = `0x${ H[2] }${H[2]}`;\r\n b = `0x${ H[3] }${H[3]}`;\r\n } else if (H.length === 7) {\r\n r = `0x${ H[1] }${H[2]}`;\r\n g = `0x${ H[3] }${H[4]}`;\r\n b = `0x${ H[5] }${H[6]}`;\r\n }\r\n\r\n return { r, g, b };\r\n}\r\n\r\n/** This function will return an equivalent opaque RGB color for a given partially transparent RGB color against a given background.\r\n * Default is a white background.\r\n */\r\nexport function rgbOpaqueFromAlpha(color: RGB, alpha: number, backgroundColor: RGB = { r: 255, g: 255, b: 255 }): RGB {\r\n const r = Math.round(backgroundColor.r - alpha * (backgroundColor.r - color.r));\r\n const g = Math.round(backgroundColor.g - alpha * (backgroundColor.g - color.g));\r\n const b = Math.round(backgroundColor.b - alpha * (backgroundColor.b - color.b));\r\n\r\n return { r, g, b };\r\n}\r\n","
\r\n
\r\n \r\n
\r\n
\r\n

{{header}}

\r\n {{content}}\r\n \r\n
\r\n \r\n
\r\n","import { AceUIIcon, BannerState } from '@ace/shared';\r\nimport {\r\n AfterViewInit,\r\n Component,\r\n EventEmitter,\r\n HostBinding,\r\n Input,\r\n OnInit,\r\n Output,\r\n ViewChild,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { TimerService } from '../../Utilities';\r\nimport { aceColorLookup } from '../Utils/colorHelper';\r\n\r\ntype Constructor = new (...args: any[]) => T;\r\n\r\n@Component({\r\n selector: 'ws-ace-banner',\r\n templateUrl: './banner.component.html',\r\n styleUrls: ['./banner.component.scss']\r\n})\r\nexport class AceBannerComponent implements OnInit, AfterViewInit {\r\n constructor(private readonly _timerService: TimerService) {\r\n }\r\n\r\n @Input() enableDismiss: boolean;\r\n @Input() suppressDefaultIcon: boolean;\r\n @Input() content: string | Constructor;\r\n // because \"title\" is a reserved attribute\r\n @Input() header: string;\r\n /**\r\n * (optional) The icon to display on this element.\r\n */\r\n @Input() icon: AceUIIcon;\r\n\r\n @HostBinding('attr.state')\r\n @Input() state: BannerState;\r\n\r\n /** full width block banner */\r\n @HostBinding('attr.block')\r\n @Input() block: boolean;\r\n\r\n /** Event will be raised when banner is dismissed */\r\n @Output() dismissed?: EventEmitter = new EventEmitter();\r\n\r\n @ViewChild('contentComponent', {read: ViewContainerRef}) contentComponent: ViewContainerRef;\r\n\r\n displayIcon: AceUIIcon;\r\n closing: boolean;\r\n isNarrow: boolean;\r\n contentIsComponent: boolean;\r\n closed: boolean;\r\n\r\n ngOnInit() {\r\n const colorModel = aceColorLookup.get(this.state || BannerState.Info)!;\r\n this.displayIcon = this.icon || (!this.suppressDefaultIcon && colorModel.icon);\r\n this.isNarrow = !this.block;\r\n\r\n if (!(typeof this.content === 'string')) {\r\n this.contentIsComponent = true;\r\n }\r\n }\r\n\r\n ngAfterViewInit() {\r\n // Check if a component was passed in as the content\r\n if (!(typeof this.content === 'string')) {\r\n this.contentIsComponent = true;\r\n this.contentComponent.clear();\r\n this.contentComponent.createComponent(this.content);\r\n }\r\n }\r\n\r\n async handleClose(): Promise {\r\n if (this.closing || this.closed) {\r\n return;\r\n }\r\n this.closing = true;\r\n // Wait for the css transition to finish\r\n await this._timerService.whenDoneTransitioning(300);\r\n this.closed = true;\r\n this.dismissed.emit();\r\n }\r\n}\r\n","\r\n\r\n\r\n\r\n
\r\n \r\n
\r\n\r\n","import {\r\n AceUIIcon,\r\n IAuthMenuAction,\r\n IMenuAction,\r\n IPortalBrandingConfig,\r\n IPortalProfile,\r\n ISlotMenuAction\r\n} from '@ace/shared';\r\nimport { IAuthChildMenuAction } from '@ace/shared/src/portal/autoSyncService';\r\nimport { ComponentType } from '@angular/cdk/overlay';\r\nimport { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\nimport { UserService } from '../../Account/user.service';\r\nimport { ProgressIndicator, SnackBarService } from '../../Busy-Indicator';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { ContactModalOrigin } from '../../constants.new';\r\nimport { ContactModalService } from '../../Contact/contactModal.service';\r\nimport { AppStates, AppStateService } from '../../Layout/appStateService';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { BannerMessage, branding, TopNavService } from './topNav.service';\r\n\r\nconst defaultAccountName = 'Tax.com Account';\r\n\r\ninterface IPPMenuAction extends IAuthChildMenuAction {\r\n amplitudeProperty?: {\r\n event: string;\r\n properties?: any;\r\n };\r\n}\r\n\r\ninterface IPPAuthMenuAction extends IAuthMenuAction {\r\n children: IPPMenuAction[];\r\n}\r\n\r\n@Component({\r\n selector: 'top-nav',\r\n templateUrl: './topNav.component.html',\r\n styleUrls: ['./topNav.component.scss']\r\n})\r\nexport class TopNavComponent implements OnDestroy, OnInit {\r\n constructor(private readonly _router: UIRouter,\r\n private readonly _appStateService: AppStateService,\r\n private readonly _userService: UserService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _topNavService: TopNavService,\r\n private readonly _snackBarService: SnackBarService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _contactModalService: ContactModalService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {\r\n }\r\n\r\n currentAction: string | undefined;\r\n isLoggedIn: boolean;\r\n sideNavOpen: boolean;\r\n showBanner: boolean;\r\n bannerMessage: BannerMessage>;\r\n\r\n branding: IPortalBrandingConfig = branding;\r\n\r\n chromeActions: (IMenuAction | IAuthMenuAction | ISlotMenuAction)[] = [];\r\n\r\n private _helpMenuOption: IMenuAction = {\r\n key: 'profile-help',\r\n icon: AceUIIcon.Question,\r\n info: 'Help',\r\n content: null,\r\n children: [\r\n {\r\n isHeading: true,\r\n key: 'support-heading',\r\n content: 'Support'\r\n },\r\n { key: 'help', content: 'Help Center', routerOutlet: 'help' }\r\n // { key: 'contact', content: 'Contact Us', routerOutlet: 'contact' },\r\n // { key: 'support', content: 'Support', routerOutlet: 'feedback' }\r\n ]\r\n };\r\n\r\n private _searchMenuOption: IMenuAction = {\r\n key: 'quick-search',\r\n icon: AceUIIcon.Search,\r\n info: 'Search',\r\n content: null\r\n };\r\n\r\n private _snackMenuOption: IMenuAction = {\r\n key: 'snack-bar',\r\n icon: AceUIIcon.SuccessOutline,\r\n info: 'Long Running Processes',\r\n content: null\r\n };\r\n\r\n private _isAttachmentPopup: boolean;\r\n private _profileMenu: IPPAuthMenuAction | IMenuAction;\r\n private _destroy$: Subject = new Subject();\r\n private _destroyRouteListener: any;\r\n\r\n get showInstanceFilter(): boolean {\r\n return [this._userInstanceService.allInstancesItem].concat(this._userInstanceService.getUserInstanceMembership(false)).length > 2;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._isAttachmentPopup = window.location.href.indexOf('#/attachmentPopup') >= 0;\r\n\r\n this._appStateService.appState$.subscribe(async (state) => {\r\n if (state === AppStates.LoggedIn && !this._isAttachmentPopup) {\r\n this._setLoggedInMenu();\r\n switch (this._userService.getUser().onboardingStatus) {\r\n case Core.UserOnboardingStatusEnum.NoAction:\r\n await this._topNavService.showOnboardingModal();\r\n break;\r\n case Core.UserOnboardingStatusEnum.Completed:\r\n this._topNavService.showOnboardingBanner();\r\n break;\r\n }\r\n } else {\r\n this._setLoggedOutMenu();\r\n }\r\n });\r\n\r\n this._topNavService.sideNavOpen$.pipe(takeUntil(this._destroy$)).subscribe(isOpen => {\r\n this.sideNavOpen = isOpen;\r\n });\r\n\r\n this._topNavService.bannerMessage$.pipe(takeUntil(this._destroy$)).subscribe(message => {\r\n this.bannerMessage = message;\r\n this.showBanner = true;\r\n });\r\n\r\n this._snackBarService.longRunningProcesses.pipe(takeUntil(this._destroy$)).subscribe(processes => {\r\n this._processLRP(processes);\r\n });\r\n\r\n this._destroyRouteListener = this._router.transitionService.onSuccess({}, (transition) => {\r\n const transitions = transition.entering();\r\n transitions.forEach(x => {\r\n if (x.name === 'admin' || x.name === 'diagnostic') {\r\n this.currentAction = x.name;\r\n } else {\r\n this.currentAction = null;\r\n }\r\n });\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._destroyRouteListener();\r\n }\r\n\r\n handleActionTriggered(action: CustomEvent) {\r\n if (action.detail === 'home') {\r\n if (!this._isAttachmentPopup) {\r\n this._productAnalyticsService.logEvent('click-logo');\r\n this._router.stateService.transitionTo(action.detail);\r\n }\r\n } else {\r\n switch (action.detail.key) {\r\n case 'quick-search':\r\n this._productAnalyticsService.logEvent('initiate-quick-search', { initiateQuickSearch: 'header icon' });\r\n this._navigationService.openQuickSearch(false, 'navbar');\r\n break;\r\n case 'snack-bar':\r\n this._snackBarService.showSnackBar();\r\n break;\r\n case 'pp-account':\r\n const user = this._userService.getUser();\r\n const contactId = this._userInstanceService.isSingleInstanceSelected() ? this._userInstanceService.getInstanceContactId() : user.contactId;\r\n this._productAnalyticsService.logEvent('click-manage-view-profile');\r\n this._contactModalService.openContactDialog(contactId, ContactModalOrigin.ViewProfile);\r\n break;\r\n default:\r\n const menuAction: IPPMenuAction = action.detail;\r\n if (menuAction.amplitudeProperty) {\r\n this._productAnalyticsService.logEvent(menuAction.amplitudeProperty.event, menuAction.amplitudeProperty.properties);\r\n }\r\n if (menuAction.routerOutlet) {\r\n this.routeTo(menuAction.routerOutlet);\r\n }\r\n if (menuAction.url) {\r\n window.open(menuAction.url, '_blank').focus();\r\n }\r\n }\r\n }\r\n }\r\n\r\n toggleSideNav(): void {\r\n this._topNavService.sideNavOpen = true;\r\n }\r\n\r\n dismissBanner(): void {\r\n this.showBanner = false;\r\n this.bannerMessage.onDismiss();\r\n this.bannerMessage = null;\r\n }\r\n\r\n routeTo(commands: string): void {\r\n this._router.stateService.transitionTo(commands);\r\n }\r\n\r\n private _setLoggedOutMenu(): void {\r\n this.chromeActions = [];\r\n this.isLoggedIn = false;\r\n }\r\n\r\n private _setLoggedInMenu(): void {\r\n const user = this._userService.getUser();\r\n const profile: IPortalProfile = {\r\n firstName: user.firstName,\r\n lastName: user.lastName,\r\n email: user.email,\r\n sub: '',\r\n name: `${user.firstName} ${user.lastName}`\r\n };\r\n\r\n this._profileMenu = {\r\n key: 'auth',\r\n profile,\r\n info: profile.name,\r\n children: [\r\n {\r\n key: 'header',\r\n content: defaultAccountName,\r\n isHeading: true\r\n },\r\n {\r\n key: 'profile',\r\n content: 'My Account',\r\n profile\r\n },\r\n {\r\n key: 'pp-account',\r\n content: 'View Profile'\r\n },\r\n {\r\n key: 'manage-account',\r\n content: 'Manage Account',\r\n url: `${this._featureFlagsService.taxDotComBase}/user-management/myaccount/`,\r\n amplitudeProperty: {\r\n event: 'PP-click-tax.com-menu-option',\r\n properties: { menuOption: 'Manage Account' }\r\n }\r\n },\r\n // TODO implement this once permissions are determined\r\n // {\r\n // key: 'manage-organization',\r\n // content: 'Manage Organization',\r\n // url: `${this._featureFlagsService.taxDotComBase}/apps/`\r\n // },\r\n {\r\n key: 'hr1',\r\n content: 'hr1',\r\n isDivider: true\r\n },\r\n {\r\n key: 'logout',\r\n content: 'Log Out',\r\n routerOutlet: 'logout'\r\n }\r\n ]\r\n };\r\n\r\n this.chromeActions = [\r\n this._searchMenuOption,\r\n this._helpMenuOption,\r\n this._profileMenu\r\n ];\r\n this.isLoggedIn = true;\r\n }\r\n\r\n private _processLRP(processes: ProgressIndicator[]): void {\r\n if (processes.length) {\r\n const completeProcesses = processes.reduce((acc: number, p: ProgressIndicator) => (p.isComplete) ? (acc += 1) : acc, 0);\r\n const activeProcesses = processes.length - completeProcesses;\r\n\r\n if (activeProcesses) {\r\n this._snackMenuOption.info = `Long Running Processes (Active: ${activeProcesses}${completeProcesses ? `, Complete: ${completeProcesses}` : ''})`;\r\n this._snackMenuOption.icon = AceUIIcon.Spinner;\r\n } else {\r\n this._snackMenuOption.info = `Long Running Processes (Complete: ${completeProcesses})`;\r\n this._snackMenuOption.icon = AceUIIcon.SuccessOutline;\r\n }\r\n\r\n if (!this.chromeActions.includes(this._snackMenuOption)) {\r\n this.chromeActions.splice(2, 0, this._snackMenuOption);\r\n }\r\n this.chromeActions = [...this.chromeActions];\r\n } else {\r\n if (this.chromeActions.includes(this._snackMenuOption)) {\r\n this.chromeActions = this.chromeActions.filter(x => x.key !== 'snack-bar');\r\n }\r\n }\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../../../Common/weissman-shared.module';\r\nimport { ActionViewCategoryComponent } from './Category/actionViewCategory.component';\r\nimport { ReportCategoryComponent } from './Category/reportCategory.component';\r\nimport { SearchCategoryComponent } from './Category/searchCategory.component';\r\nimport { ActionViewDefaultDisplayComponent } from './Default-Display/actionViewDefaultDisplay.component';\r\nimport { SearchDefaultDisplayComponent } from './Default-Display/searchDefaultDisplay.component';\r\nimport { ActionViewRenameComponent } from './Rename/actionViewRename.component';\r\nimport { ReportRenameComponent } from './Rename/reportRename.component';\r\nimport { SearchRenameComponent } from './Rename/searchRename.component';\r\n\r\n@NgModule({\r\n imports: [WeissmanSharedModule],\r\n declarations: [\r\n ActionViewRenameComponent,\r\n ReportRenameComponent,\r\n SearchRenameComponent,\r\n ActionViewDefaultDisplayComponent,\r\n SearchDefaultDisplayComponent,\r\n ActionViewCategoryComponent,\r\n ReportCategoryComponent,\r\n SearchCategoryComponent\r\n ],\r\n exports: [\r\n ActionViewRenameComponent,\r\n ReportRenameComponent,\r\n SearchRenameComponent,\r\n ActionViewDefaultDisplayComponent,\r\n SearchDefaultDisplayComponent,\r\n ActionViewCategoryComponent,\r\n ReportCategoryComponent,\r\n SearchCategoryComponent\r\n ]\r\n})\r\nexport class NavigationModalsModule {\r\n}\r\n","import { CUSTOM_ELEMENTS_SCHEMA, NgModule } from '@angular/core';\r\nimport { UIRouterUpgradeModule } from '@uirouter/angular-hybrid';\r\nimport { SnackBarModule } from '../Busy-Indicator/SnackBar/snackBar.module';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { NubComponent } from './Nub/nub.component';\r\nimport { NubService } from './Nub/nub.service';\r\nimport { NavOnboardingComponent } from './Onboarding-Modal/navOnboarding.component';\r\nimport { OnboardingBannerComponent } from './Onboarding-Modal/onboardingBanner.component';\r\nimport { SavedActionViewComponent } from './Saved-AV/savedActionView.component';\r\nimport { SavedActionViewService } from './Saved-AV/savedActionView.service';\r\nimport { SavedReportComponent } from './Saved-Report/savedReport.component';\r\nimport { SideNavComponent } from './Side-Nav/sideNav.component';\r\nimport { TopNavComponent } from './Top-Nav/topNav.component';\r\nimport { NavigationModalsModule } from './User-Save/Modals/navigationModals.module';\r\nimport { SavedSmartComponent } from './Saved-Smart/savedSmart.component';\r\nimport { SavePageComponent } from './User-Save/Save-Page/savePage.component';\r\nimport { SaveTabContentComponent } from './User-Save/Save-Tab-Content/saveTabContent.component';\r\n\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { UserSaveService } from './User-Save/userSave.service';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n UIRouterUpgradeModule,\r\n NavigationModalsModule,\r\n SnackBarModule\r\n ],\r\n declarations: [\r\n TopNavComponent,\r\n SideNavComponent,\r\n SavePageComponent,\r\n SaveTabContentComponent,\r\n SavedSmartComponent,\r\n SavedActionViewComponent,\r\n SavedReportComponent,\r\n NubComponent,\r\n NavOnboardingComponent,\r\n OnboardingBannerComponent\r\n ],\r\n exports: [\r\n TopNavComponent,\r\n SideNavComponent,\r\n SavedSmartComponent,\r\n SavedActionViewComponent,\r\n SavedReportComponent,\r\n NubComponent,\r\n NavOnboardingComponent,\r\n OnboardingBannerComponent\r\n ],\r\n schemas: [\r\n CUSTOM_ELEMENTS_SCHEMA // Tells Angular we have custom tags in our template\r\n ]\r\n})\r\nexport class NavigationModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('topNav', TopNavComponent);\r\n hybridAdapterUtility.downgradeNg2Component('sideNav', SideNavComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('nubService', NubService);\r\n hybridAdapterUtility.downgradeNg2Provider('userSaveService', UserSaveService);\r\n hybridAdapterUtility.downgradeNg2Provider('SavedActionViewService', SavedActionViewService);\r\n }\r\n}\r\n","\r\n Requirements:\r\n
    \r\n
  • Cannot be the same as your User Name.
  • \r\n
  • Must be at least 8 characters long.
  • \r\n
  • Must contain at least one number, letter and special character.
  • \r\n
  • Cannot match your last 3 passwords.
  • \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
    \r\n
  • This entry is too short.
  • \r\n
  • An entry is required.
  • \r\n
  • Incorrect password entered.
  • \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n\r\n
\r\n
    \r\n
  • This entry is too short.
  • \r\n
  • An entry is required.
  • \r\n
  • Does not have at least one special character and one number.
  • \r\n
  • Password cannot be the same as your user name.
  • \r\n
  • Password has already been used.
  • \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
    \r\n
  • Does not match new password.
  • \r\n
  • An entry is required.
  • \r\n
\r\n
\r\n
\r\n
\r\n

\r\n Note: Once you change your password you will be logged out.\r\n

\r\n
\r\n","import { Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { AbstractControl, FormBuilder, FormControl, FormGroup, ValidatorFn, Validators } from '@angular/forms';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { UserService } from '../user.service';\r\n\r\nexport interface PasswordChangeData {\r\n current: string;\r\n 'new': string;\r\n confirm: string;\r\n}\r\n\r\n@Component({\r\n selector: 'new-password',\r\n templateUrl: './newPassword.component.html'\r\n})\r\nexport class NewPasswordComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _userService: UserService,\r\n private readonly _fb: FormBuilder) {\r\n }\r\n\r\n @Input() showCurrent: boolean;\r\n @Input() passwordIncorrect: boolean;\r\n @Input() alreadyUsed: string;\r\n @Input() passwords: PasswordChangeData;\r\n @Input() passwordsValid: boolean;\r\n\r\n @Output() passwordsChange: EventEmitter = new EventEmitter();\r\n @Output() passwordsValidChange: EventEmitter = new EventEmitter();\r\n\r\n form: FormGroup;\r\n passwordRegEx: RegExp;\r\n username = '';\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n doesNotMatchUsername = (): ValidatorFn => {\r\n return (control: AbstractControl): { [key: string]: boolean } | null => {\r\n return this.username && control.value === this.username ? { 'sdDoesNotMatch': true } : null;\r\n };\r\n };\r\n\r\n confirmMustMatchNew = (): ValidatorFn => {\r\n return (control: AbstractControl): { [key: string]: boolean } | null => {\r\n return control.value !== this.newPassword?.value ? { 'sdMustMatch': true } : null;\r\n };\r\n };\r\n\r\n isNotAlreadyUsed = (): ValidatorFn => {\r\n return (control: AbstractControl): { [key: string]: boolean } | null => {\r\n return this.alreadyUsed ? { 'alreadyUsed': true } : null;\r\n };\r\n };\r\n\r\n currentPasswordValid = (): ValidatorFn => {\r\n return (control: AbstractControl): { [key: string]: boolean } | null => {\r\n return this.passwordIncorrect ? { 'incorrect': true } : null;\r\n };\r\n };\r\n\r\n get current(): FormControl {\r\n return this.form?.get('current') as FormControl;\r\n }\r\n\r\n get newPassword(): FormControl {\r\n return this.form?.get('new') as FormControl;\r\n }\r\n\r\n get confirm(): FormControl {\r\n return this.form?.get('confirm') as FormControl;\r\n }\r\n\r\n ngOnInit(): void {\r\n this.passwordRegEx = /^(?=.*?[a-zA-Z])(?=.*?[0-9])(?=.*?[^\\w\\s]).{8,}$/;\r\n\r\n this.form = this._fb.group({\r\n current: ['', (this.showCurrent ? [\r\n Validators.required,\r\n Validators.minLength(8),\r\n Validators.pattern(this.passwordRegEx),\r\n this.currentPasswordValid()\r\n ] : [])],\r\n new: ['', [\r\n Validators.required,\r\n Validators.minLength(8),\r\n Validators.pattern(this.passwordRegEx),\r\n this.doesNotMatchUsername(),\r\n this.isNotAlreadyUsed()\r\n ]],\r\n confirm: ['', [\r\n Validators.required,\r\n this.confirmMustMatchNew()\r\n ]]\r\n });\r\n\r\n this.form.valueChanges.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n this.passwordsChange.emit(this.form.getRawValue());\r\n this.passwordsValidChange.emit(this.form.valid);\r\n });\r\n\r\n const user = this._userService.getUser();\r\n if (user) {\r\n this.username = user.username;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { UtilitiesService } from '../../UI-Lib/Utilities';\r\nimport { UserService } from '../user.service';\r\n\r\n\r\n@Component({\r\n selector: 'change-password',\r\n templateUrl: './changePassword.component.html'\r\n})\r\nexport class ChangePasswordComponent {\r\n constructor(private readonly _router: UIRouter,\r\n private readonly _userService: UserService,\r\n private readonly _utils: UtilitiesService) {\r\n }\r\n\r\n alreadyUsed: string = '';\r\n passwordIncorrect: boolean;\r\n passwordsValid: boolean;\r\n password = {\r\n current: '',\r\n 'new': '',\r\n confirm: ''\r\n };\r\n disableSave = false;\r\n\r\n async changePassword(): Promise {\r\n this.disableSave = true;\r\n this.passwordIncorrect = false;\r\n this.alreadyUsed = '';\r\n try {\r\n await this._userService.changePassword(this.password.current, this.password.new);\r\n this._router.stateService.go('logout');\r\n } catch(error) {\r\n console.log('changePassword - error', error);\r\n if (error.status === 400) {\r\n const message = error.data.modelState[''][0];\r\n switch (message) {\r\n case 'Could not validate user.':\r\n this.passwordIncorrect = true;\r\n this._utils.focusOnElement('[name=current]', 300);\r\n break;\r\n case 'Password must contain at least one numeral and one letter.':\r\n this._setNewValidation();\r\n console.log('changePassword - error', message);\r\n break;\r\n case 'Passwords cannot have been used within last 3 password changes.':\r\n this.alreadyUsed = this.password.new;\r\n this._setNewValidation();\r\n break;\r\n default:\r\n break;\r\n }\r\n }\r\n } finally {\r\n this.disableSave = false;\r\n }\r\n }\r\n\r\n goToHome(): void {\r\n this._router.stateService.go('home');\r\n }\r\n\r\n private _setNewValidation(): void {\r\n this._utils.focusOnElement('[name=new]', 100);\r\n this.password.confirm = '';\r\n }\r\n}\r\n","
\r\n
\r\n \r\n
\r\n

Login

\r\n
\r\n
{{ error }}
\r\n
{{ warning }}
\r\n
\r\n
\r\n \r\n \r\n \r\n Username is required\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n Password is required\r\n \r\n
\r\n\r\n
\r\n \r\n Forgot password?\r\n \r\n
\r\n\r\n
\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tLogin using SSO\r\n\t\t\t\t\t\t\r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n

Password recovery

\r\n\r\n
\r\n
{{ error }}
\r\n
{{ warning }}
\r\n\r\n
\r\n
\r\n

{{ passwordResetEmailHasBeenSentMessage }}

\r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n \r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n

Password reset

\r\n
\r\n
{{ error }}
\r\n
{{ warning }}
\r\n\r\n
\r\n \r\n
\r\n\r\n \r\n
\r\n\r\n \r\n \r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n

Login Using SSO

\r\n\r\n
\r\n
{{ error }}
\r\n
{{ warning }}
\r\n\r\n \r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n For example, if your email address is john.doe@company.com, company.com is the domain\r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Login Using SSO

\r\n
\r\n
\r\n
\r\n Login with your company's provider using the pop-up\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n

Login To PropertyPoint

\r\n\r\n
\r\n
{{ error }}
\r\n
{{ warning }}
\r\n\r\n \r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n

Login To PropertyPoint

\r\n\r\n
\r\n
{{ error }}
\r\n
{{ warning }}
\r\n\r\n \r\n\r\n
\r\n
\r\n \r\n \r\n Password is required\r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","
\r\n
\r\n
\r\n

Change Password

\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { AfterViewInit, Component, ElementRef, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormControl, Validators } from '@angular/forms';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { AceAuthOidcWrapperService } from '../../IAM/aceAuthOidcWrapper.service';\r\nimport { AppStateService } from '../../Layout/appStateService';\r\nimport { LoginFromSSOModel, NavigationService } from '../../Layout/navigation.service';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { TimerService, UtilitiesService } from '../../UI-Lib/Utilities';\r\nimport { AccountService, GrantTypes, ILoginData } from '../../User/account.service';\r\nimport { AuthStorageService } from '../../User/authStorage.service';\r\nimport { PasswordChangeData } from '../New-Password/newPassword.component';\r\nimport { UserService } from '../user.service';\r\n\r\nenum LoginPageModesEnum {\r\n 'login' = 1,\r\n 'getToken' = 2,\r\n 'useToken' = 3,\r\n 'selectSSODomain' = 4,\r\n 'awaitingSSO' = 5,\r\n 'homeRealmDiscovery' = 6,\r\n 'migratePassword' = 7\r\n}\r\n\r\n@Component({\r\n selector: 'login',\r\n templateUrl: './login.component.html'\r\n})\r\nexport class LoginComponent implements OnInit, AfterViewInit, OnDestroy {\r\n constructor(private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _accountService: AccountService,\r\n private readonly _appStateService: AppStateService,\r\n private readonly _authStorageService: AuthStorageService,\r\n private readonly _aceAuthOidcWrapperService: AceAuthOidcWrapperService,\r\n private readonly _userService: UserService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _elRef: ElementRef,\r\n private readonly _toastr: ToastrService,\r\n private readonly _timer: TimerService,\r\n private readonly _utils: UtilitiesService,\r\n private readonly _router: UIRouter) {\r\n }\r\n\r\n showLogin: boolean;\r\n\r\n userName: FormControl = new FormControl('', [Validators.required]);\r\n password: FormControl = new FormControl('', [Validators.required]);\r\n usernameOrEmail: FormControl = new FormControl('', [Validators.required]);\r\n loginDomain: FormControl = new FormControl('', [Validators.required]);\r\n\r\n currentMode: number;\r\n warning: string = '';\r\n error: string = '';\r\n alreadyUsed: string = '';\r\n passwordsValid: boolean;\r\n passwordObj: PasswordChangeData = {\r\n current: '',\r\n 'new': '',\r\n confirm: ''\r\n };\r\n loginPageModesEnum = LoginPageModesEnum;\r\n\r\n isIAMMigration: boolean;\r\n isSSOEnabled: boolean;\r\n rememberSSODomain: boolean;\r\n rememberSSOEmail: boolean;\r\n showSpinner: boolean;\r\n showGetNewTokenButton: boolean;\r\n\r\n passwordResetEmailHasBeenSentMessage: string;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n private readonly LAST_SSO_DOMAIN_KEY = 'lastSSODomain';\r\n private readonly SAVE_SSO_EMAIL_KEY = 'rememberSSOEmail';\r\n\r\n ngOnInit() {\r\n this.error = '';\r\n this.passwordResetEmailHasBeenSentMessage = undefined;\r\n this.showSpinner = false;\r\n this.showGetNewTokenButton = false;\r\n this.rememberSSODomain = localStorage['rememberSSODomain'] !== 'false';\r\n this.rememberSSOEmail = !!localStorage[this.SAVE_SSO_EMAIL_KEY];\r\n this.warning = this._accountService.initialMessage;\r\n\r\n let appState = null;\r\n this._appStateService.appState$.pipe(takeUntil(this._destroy$)).subscribe(newAppState => {\r\n appState = newAppState;\r\n });\r\n\r\n if (appState === this._appStateService.appStates.LoggedIn) {\r\n // Redirect to home (and don't leave the login route in router history)\r\n this._router.stateService.go('home', null, { location: 'replace' });\r\n return;\r\n } else {\r\n this._authStorageService.clearAuthData();\r\n }\r\n\r\n this._userService.isSSOIntegrationEnabled().then((isEnabled) => {\r\n this.isSSOEnabled = isEnabled;\r\n });\r\n\r\n this._navigationService.loginFromSSO$.pipe(takeUntil(this._destroy$))\r\n .subscribe(async (data: LoginFromSSOModel) => {\r\n this.currentMode = this.isIAMMigration ? LoginPageModesEnum.homeRealmDiscovery : LoginPageModesEnum.selectSSODomain;\r\n if (data.message) {\r\n this.error = data.message;\r\n } else {\r\n await this.loginWithSSO(data.grantType, data.request);\r\n }\r\n });\r\n\r\n if (this._router.globals.params.tokenHash) {\r\n this.currentMode = LoginPageModesEnum.useToken;\r\n } else if (this._accountService.homeRealmDiscoveryStarted) {\r\n this.currentMode = LoginPageModesEnum.homeRealmDiscovery;\r\n if (this.rememberSSOEmail) {\r\n this.userName.setValue(localStorage[this.SAVE_SSO_EMAIL_KEY]);\r\n }\r\n } else {\r\n this.currentMode = LoginPageModesEnum.login;\r\n\r\n if (localStorage[this.LAST_SSO_DOMAIN_KEY]) {\r\n this.loginDomain.setValue(localStorage[this.LAST_SSO_DOMAIN_KEY]);\r\n this.currentMode = LoginPageModesEnum.selectSSODomain;\r\n }\r\n }\r\n\r\n // When IAM is on, never use old login modes. It shouldn't be possible for this to happen anyway, but if one is missed this\r\n // is a fallback to ensure it redirects to HRD.\r\n if (this._featureFlagsService.featureFlags.enableIAMLogin\r\n && (this.currentMode === LoginPageModesEnum.selectSSODomain || this.currentMode === LoginPageModesEnum.login)) {\r\n this.currentMode = LoginPageModesEnum.homeRealmDiscovery;\r\n }\r\n\r\n this.showLogin = true;\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.setFocus();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async login(): Promise {\r\n this.showLogin = false;\r\n\r\n const errorHandler = response => {\r\n console.log('Error on login', response);\r\n this.showLogin = true;\r\n this.password.setValue('');\r\n if (response && response.error && response.error.error_description) {\r\n this.error = response.error.error_description;\r\n this.setFocus();\r\n } else {\r\n this.error = 'An unexpected error has occurred';\r\n this.setFocus();\r\n throw response;\r\n }\r\n };\r\n\r\n await this.checkForExistingRefreshToken();\r\n const loginData = { username: this.userName.value, password: this.password.value };\r\n\r\n if (this.isIAMMigration) {\r\n try {\r\n const migrateResult = await this._accountService.loginMigration(this.userName.value, GrantTypes.password, loginData);\r\n if (migrateResult.alreadyMigrated) {\r\n this.startAuthOidcLogin(this.userName.value);\r\n } else {\r\n window.location.href = migrateResult.inviteUrl;\r\n }\r\n } catch (err) {\r\n errorHandler(err);\r\n }\r\n\r\n return;\r\n }\r\n\r\n try {\r\n const didSucceed = await this._accountService.login(GrantTypes.password, loginData);\r\n this.showSpinner = false;\r\n\r\n if (!didSucceed) {\r\n return;\r\n }\r\n\r\n delete localStorage[this.LAST_SSO_DOMAIN_KEY];\r\n\r\n if (this.currentMode === LoginPageModesEnum.useToken) {\r\n this._router.stateService.go('home');\r\n } else {\r\n this._navigationService.postLogin();\r\n }\r\n\r\n } catch (err) {\r\n errorHandler(err);\r\n }\r\n }\r\n\r\n async checkForExistingRefreshToken(): Promise {\r\n if (this._accountService.checkForExistingRefreshToken()) {\r\n const result = await this._messageBoxService.open({\r\n message: 'You are already logged in on another tab or window. Continue with your existing session?',\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n if (result !== MessageBoxResult.No) {\r\n // Refresh the page and let default handling catch the refresh token\r\n (window.location as any).reload(true);\r\n }\r\n }\r\n }\r\n\r\n async loginWithSSO(grantType: GrantTypes, ssoRequest: string | ILoginData): Promise {\r\n this.showSpinner = true;\r\n\r\n const errorHandler = response => {\r\n this.showSpinner = false;\r\n if (response && response.error && response.error.error_description) {\r\n this.error = response.error.error_description;\r\n } else {\r\n this.error = 'An unexpected error has occurred';\r\n throw response;\r\n }\r\n };\r\n\r\n if (this.isIAMMigration) {\r\n try {\r\n const migrateResult = await this._accountService.loginMigration(this.userName.value, grantType, ssoRequest);\r\n if (migrateResult.alreadyMigrated) {\r\n this.startAuthOidcLogin(this.userName.value);\r\n } else {\r\n window.location.href = migrateResult.inviteUrl;\r\n }\r\n } catch (err) {\r\n errorHandler(err);\r\n }\r\n }\r\n\r\n try {\r\n await this._accountService.login(grantType, ssoRequest);\r\n if (this.rememberSSODomain) {\r\n localStorage[this.LAST_SSO_DOMAIN_KEY] = this.loginDomain.value;\r\n } else {\r\n delete localStorage[this.LAST_SSO_DOMAIN_KEY];\r\n }\r\n this._navigationService.postLogin();\r\n } catch (err) {\r\n errorHandler(err);\r\n }\r\n }\r\n\r\n async resetPassword(): Promise {\r\n this.showSpinner = true;\r\n this.showGetNewTokenButton = false;\r\n this.error = '';\r\n const result = await this._userService.resetPasswordUsingToken(this._router.globals.params.tokenHash, this.passwordObj.new);\r\n try {\r\n // console.log('resetPasswordUsingToken - api response:', result);\r\n // console.log('this.passwordObj:', this.passwordObj);\r\n if (result.error == '') {\r\n this.userName.setValue(result.userName);\r\n this.password.setValue(this.passwordObj.new);\r\n await this.login();\r\n } else {\r\n this.error = result.error;\r\n this._toastr.error(this.error);\r\n this.showSpinner = false;\r\n\r\n if (result.showResetPaswordFormAgain) {\r\n this.passwordObj.new = null;\r\n this.passwordObj.confirm = null;\r\n this.currentMode = LoginPageModesEnum.useToken;\r\n this.showGetNewTokenButton = false;\r\n } else\r\n this.showGetNewTokenButton = true;\r\n }\r\n } catch (error) {\r\n console.log('login page controller - error while resetting password:', error);\r\n this.error = error.data.error_description;\r\n this.setFocus();\r\n }\r\n }\r\n\r\n async sendPasswordResetToken(): Promise {\r\n this.showSpinner = true;\r\n this.passwordResetEmailHasBeenSentMessage = undefined;\r\n try {\r\n const result = await this._userService.sendPasswordResetToken(this.usernameOrEmail.value);\r\n console.log('sendPasswordResetToken api call result', result);\r\n this.showSpinner = false;\r\n\r\n if (result != '') {\r\n this.passwordResetEmailHasBeenSentMessage = result;\r\n this._toastr.error(result);\r\n } else\t// no errors\r\n this.passwordResetEmailHasBeenSentMessage = 'Check your inbox for a password reset email.';\r\n } catch (error) {\r\n console.log('sendPasswordResetToken - error:', error);\r\n }\r\n }\r\n\r\n async submitHomeRealmDiscovery(): Promise {\r\n this.isIAMMigration = true;\r\n this.showSpinner = true;\r\n\r\n if (this.rememberSSOEmail) {\r\n localStorage[this.SAVE_SSO_EMAIL_KEY] = this.userName.value;\r\n } else {\r\n delete localStorage[this.SAVE_SSO_EMAIL_KEY];\r\n }\r\n try {\r\n const initialData = await this._accountService.getIAMInitialLoginData(this.userName.value);\r\n this._accountService.handleInitialRoute();\r\n if (initialData.migrationSSOExceptionEndpoint) {\r\n await this.initializeSSOLogin(initialData.migrationSSOExceptionEndpoint);\r\n this.isIAMMigration = false;\r\n } else if (!initialData.needsMigration) {\r\n this.startAuthOidcLogin(this.userName.value);\r\n } else if (initialData.ssoDomain) {\r\n this.loginDomain.setValue(initialData.ssoDomain);\r\n await this.initializeSSOLogin();\r\n } else {\r\n this.showSpinner = false;\r\n this.currentMode = LoginPageModesEnum.migratePassword;\r\n }\r\n } catch (error) {\r\n this.showSpinner = false;\r\n console.error(error);\r\n this.error = 'An unexpected error has ocurred';\r\n }\r\n }\r\n\r\n startAuthOidcLogin(userName: string): void {\r\n this._aceAuthOidcWrapperService.authElement$.pipe(takeUntil(this._destroy$))\r\n .subscribe(el => {\r\n const redirectUrl = this._navigationService.getInitialUrl() || window.location.href;\r\n console.log('redirectUrl', redirectUrl);\r\n try {\r\n el.authenticate({\r\n redirectUrl: redirectUrl,\r\n email: userName,\r\n forceLogin: true\r\n });\r\n } catch (err) {\r\n this.showSpinner = false;\r\n throw err;\r\n }\r\n });\r\n }\r\n\r\n setFocus() {\r\n this._utils.focusOnElement('input[name=username]');\r\n }\r\n\r\n switchToSSOMode() {\r\n this.currentMode = LoginPageModesEnum.selectSSODomain;\r\n this.showSpinner = false;\r\n this.error = '';\r\n this._utils.focusOnElement('input[name=loginDomain]');\r\n }\r\n\r\n// If overrideEndpoint is set that's what will be redirected to, otherwise get the appropriate endpoint for this.loginDomain\r\n async initializeSSOLogin(overrideEndpoint?: System.Uri | string): Promise {\r\n await this.checkForExistingRefreshToken();\r\n this.showSpinner = true;\r\n this.error = '';\r\n\r\n let endpoint = overrideEndpoint;\r\n if (!overrideEndpoint) {\r\n endpoint = await this._userService.getSSOIntegrationEndpoint(this.loginDomain.value);\r\n }\r\n\r\n this.showSpinner = false;\r\n if (endpoint === null) {\r\n this.error = 'Domain not recognized';\r\n } else {\r\n endpoint = `${endpoint + ((endpoint as string).indexOf('?') >= 0 ? '&' : '?')}nocache=${+new Date()}`;\r\n const popupWindow = window.open(endpoint, 'ssowindow', 'toolbar=no,location=no,directories=no,status=no,menubar=no,resizable=yes,width=800,height=600');\r\n if (!popupWindow) {\r\n this.error = 'Error opening pop-up. Please ensure pop-ups are enabled for this site';\r\n } else {\r\n this.currentMode = LoginPageModesEnum.awaitingSSO;\r\n }\r\n }\r\n }\r\n\r\n cancelSelectSSODomain(): void {\r\n this.currentMode = this.isIAMMigration ? LoginPageModesEnum.homeRealmDiscovery : LoginPageModesEnum.login;\r\n this.error = '';\r\n this.showSpinner = false;\r\n this.setFocus();\r\n }\r\n\r\n setRememberSSODomain(): void {\r\n if (this.rememberSSODomain) {\r\n delete localStorage['rememberSSODomain'];\r\n } else {\r\n localStorage['rememberSSODomain'] = 'false';\r\n }\r\n }\r\n\r\n goToLogin(): void {\r\n this._router.stateService.go('login');\r\n }\r\n}\r\n","\r\n
    \r\n
  • \r\n \r\n
  • \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AppealFormItem } from '../appeal.application.model';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\n\r\nexport interface AppealApplicationSetTopModalParams {\r\n appealFormList: AppealFormItem[];\r\n}\r\n\r\n@Component({\r\n selector: 'appeal-application-set-page-modal',\r\n templateUrl: 'appealApplicationSetTopModal.component.html'\r\n})\r\nexport class AppealApplicationSetTopModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _modalRef: BsModalRef) { }\r\n\r\n params: AppealApplicationSetTopModalParams;\r\n result: number;\r\n topAppealFormRevisionId: number;\r\n\r\n private _originalTopAppealFormRevisionId: number;\r\n\r\n ngOnInit(): void {\r\n this.result = null;\r\n\r\n const topAppealCandidates = this.params.appealFormList.filter(a => a.isTopAppeal);\r\n this._originalTopAppealFormRevisionId = topAppealCandidates.length === 1 ?\r\n topAppealCandidates[0].appealFormRevisionId : null;\r\n this.topAppealFormRevisionId = this._originalTopAppealFormRevisionId;\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n save(): void {\r\n if (this.topAppealFormRevisionId !== this._originalTopAppealFormRevisionId) {\r\n this.result = this.topAppealFormRevisionId;\r\n }\r\n\r\n this._modalRef.hide();\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n Apply form overrides to:\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n

Document Preview Is Not Available

\r\n
\r\n\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n\r\n
0\">\r\n

Form Overrides ({{overrideHolder.overrides.length}})

\r\n
\r\n {{i + 1}} - {{ override.overrideValue }}\r\n
\r\n
\r\n
\r\n","import { Component, ElementRef, Input, OnDestroy, OnChanges, Output, EventEmitter, Renderer2, NgZone } from '@angular/core';\r\nimport { PDFViewerBase, FieldOverride } from '../../Common/PDFViewer/pdfViewerBase';\r\nimport { AppealApplicationService } from '../appeal.application.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { AppealFormItem, AppealFormOverrideModel } from '../appeal.application.model';\r\nimport { AppealApplicationSetTopModalComponent, AppealApplicationSetTopModalParams } from '../Set-Top-Modal/appealApplicationSetTopModal.component';\r\nimport { ScriptLoaderService } from 'src/app/UI-Lib/Utilities/scriptLoader.service';\r\nimport { Constants } from 'src/app/constants.new';\r\n\r\n\r\n@Component({\r\n selector: 'appeal-application-viewer',\r\n templateUrl: './appealApplicationViewer.component.html'\r\n})\r\nexport class AppealApplicationViewerComponent extends PDFViewerBase implements OnChanges, OnDestroy {\r\n constructor(\r\n private _elementRef: ElementRef,\r\n public appealApplicationService: AppealApplicationService,\r\n private _busyIndicatorService: BusyIndicatorService,\r\n _renderer: Renderer2,\r\n _zone: NgZone,\r\n _modalService: WeissmanModalService,\r\n _scriptLoaderService: ScriptLoaderService,\r\n _constants: Constants\r\n ) {\r\n super('#appeal-output', _modalService, _scriptLoaderService, _constants, _renderer, _zone);\r\n }\r\n\r\n @Input() selectedForm: AppealFormItem;\r\n @Input() appealFormList: AppealFormItem[];\r\n @Output() topAppealSelected: EventEmitter = new EventEmitter();\r\n\r\n showFieldLocation: boolean = false;\r\n // appealIds: number[];\r\n // appealId: number;\r\n //additionalAccountAppealIds: number[];\r\n isFormLoading: boolean = false;\r\n // multiAccountData: AppealFormReference[];\r\n overrideAccountIndexLookup: { [appealFormRevisionOverrideId: number]: number };\r\n\r\n\r\n async ngOnChanges(): Promise {\r\n this.isReadOnly = false;\r\n this.isAppealForm = true;\r\n // this.appealIds = this.appealFormList.map(af => af.appealId);\r\n\r\n if(this.selectedForm) {\r\n await this.loadForm();\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.disposePdfDocument();\r\n }\r\n\r\n onApplyEditsToAllChange(value: boolean): void {\r\n this.appealApplicationService.setApplyEditsToAll(value);\r\n }\r\n\r\n processAppealOverrideMultiAccountIndexes(overrides: AppealFormOverrideModel[]): AppealFormOverrideModel[] {\r\n this.overrideAccountIndexLookup = {};\r\n const multiAccountOverrides: string[] = [];\r\n const topAppealFormRevisionId = this.selectedForm.appealFormRevisionId;\r\n overrides.forEach(o => {\r\n let result = 0;\r\n if (o.appealFormRevisionId !== topAppealFormRevisionId) {\r\n result = this.selectedForm.additionalAccounts.map(a => a.appealFormRevisionId).indexOf(o.appealFormRevisionId) + 1;\r\n }\r\n this.overrideAccountIndexLookup[o.appealFormRevisionOverrideId] = result;\r\n multiAccountOverrides.push(o.fieldName);\r\n });\r\n // Note that we normally don't need a multi-account index lookup entry for fields on the top form (that's where overrides go by\r\n // default), however if multiple overrides exist for the same field and one of them is on the top form, it needs an entry here\r\n // to disambiguate it.\r\n if (multiAccountOverrides.length > 0) {\r\n overrides\r\n .filter(o =>\r\n o.appealFormRevisionId === topAppealFormRevisionId &&\r\n multiAccountOverrides.some(f => f === o.fieldName))\r\n .forEach(o => {\r\n this.overrideAccountIndexLookup[o.appealFormRevisionId] = 0;\r\n });\r\n }\r\n\r\n return overrides;\r\n }\r\n\r\n async selectTopAppeal(): Promise {\r\n const params: AppealApplicationSetTopModalParams = {\r\n appealFormList: [this.selectedForm].concat(this.selectedForm.additionalAccounts)\r\n };\r\n\r\n const result = await this._modalService.showAsync(AppealApplicationSetTopModalComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.topAppealSelected.emit(result);\r\n }\r\n\r\n async loadForm(): Promise {\r\n this.disposePdfDocument();\r\n\r\n if (!this.selectedForm) return;\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading preview' });\r\n this.isFormLoading = true;\r\n const appealFormReference = this.appealApplicationService.toAppealFormReference(this.selectedForm);\r\n try {\r\n const response = await Promise.all(this.selectedForm.additionalAccounts.length === 0 ? [\r\n this.appealApplicationService.getFormTemplate(appealFormReference),\r\n this.appealApplicationService.getFormDefaultValues(appealFormReference),\r\n this.appealApplicationService.getFormOverrides(appealFormReference).then(o => this.processAppealOverrideMultiAccountIndexes(o))\r\n ]: [\r\n this.appealApplicationService.getMultiAccountFormTemplate(appealFormReference),\r\n this.appealApplicationService.getMultiAccountFormDefaultValues(appealFormReference),\r\n this.appealApplicationService.getMultiAccountFormOverrides(appealFormReference).then(o => this.processAppealOverrideMultiAccountIndexes(o))\r\n ]\r\n );\r\n\r\n await this._loadPreviewForForm(response[0], response[1], response[2]);\r\n\r\n } finally {\r\n await busyRef.hide();\r\n this.isFormLoading = false;\r\n }\r\n }\r\n\r\n async onPdfFieldChange(event): Promise {\r\n if (event.target) {\r\n const id = event.target.parentElement.getAttribute('data-annotation-id');\r\n const fieldData = this._idFieldMap[id];\r\n\r\n //todo: is there an annotation or configuration to do this automatically?\r\n // workaround to set the checkbox value to checked/unchecked value\r\n if (event.target.type === 'checkbox') {\r\n event.target.value = event.target.checked ? 'On' : 'Off';\r\n }\r\n\r\n const newValue = event.target.value;\r\n\r\n const shouldApplyEditsToAll = this.appealApplicationService.shouldApplyEditsToAll;\r\n if (shouldApplyEditsToAll) {\r\n // Normally disable field during override, but in this case multiple fields may get simultaneously overridden;\r\n // show the loading\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving overrides...' });\r\n this.isFormLoading = true;\r\n try {\r\n await this._processSingleFieldChange(fieldData, newValue, true);\r\n if (this.getUIAccountIndex(fieldData.fieldName) !== null) {\r\n // We've applied the override to this specific field and to all other forms, but now\r\n // we need to also apply it to other accounts on this particular form (note this logic\r\n // is also present in _deleteOverride)\r\n const accountlessName = this.removeUIAccountIndex(fieldData.fieldName);\r\n // TODO: We should create an API endpoint that does this update in bulk and returns the\r\n // affected RowVersions so we don't have to individually call it for each override.\r\n for (let i = 0; i < this._accountlessNameIdMap[accountlessName].length; i++) {\r\n const relatedId = this._accountlessNameIdMap[accountlessName][i];\r\n if (relatedId !== id) {\r\n const relatedFieldData = this._idFieldMap[relatedId];\r\n await this._processSingleFieldChange(relatedFieldData, newValue, false);\r\n }\r\n }\r\n }\r\n }\r\n finally {\r\n this.isFormLoading = false;\r\n await busyRef.hide();\r\n }\r\n }\r\n else {\r\n await this._processSingleFieldChange(fieldData, newValue, false);\r\n }\r\n }\r\n }\r\n\r\n protected resolveAccountIndex(override: Compliance.FormOverrideModel): number {\r\n if (!override) { return null; }\r\n return this.overrideAccountIndexLookup[(override).appealFormRevisionOverrideId];\r\n }\r\n\r\n protected getElementRef(): ElementRef {\r\n return this._elementRef;\r\n }\r\n\r\n protected isShowingAnnotations(): boolean {\r\n return true;\r\n }\r\n\r\n protected async _deleteOverride(override: FieldOverride, rowVersion: number[]) {\r\n if (this.appealApplicationService.shouldApplyEditsToAll) {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Removing overrides...' });\r\n this.isFormLoading = true;\r\n try {\r\n await this._deleteSingleOverride(override, rowVersion, true);\r\n const accountIndex = this.getUIAccountIndex(override.fieldName);\r\n if (accountIndex !== null) {\r\n // Same deal as in saved override; apply to other accounts on this form one at a time, and\r\n // TODO: Make this not one at a time\r\n const accountlessName = this.removeUIAccountIndex(override.fieldName);\r\n const fieldOverrides = this.overrideHolder.overrides.filter(o =>\r\n this.getUIAccountIndex(o.fieldName) !== accountIndex &&\r\n this.removeUIAccountIndex(o.fieldName) === accountlessName);\r\n for (let i = 0; i < fieldOverrides.length; i++) {\r\n const fieldOverride = fieldOverrides[i];\r\n await this._deleteSingleOverride(fieldOverride, this.overrideHolder.getSaved(fieldOverride.fieldName).rowVersion, false);\r\n }\r\n }\r\n }\r\n finally {\r\n this.isFormLoading = false;\r\n await busyRef.hide();\r\n }\r\n }\r\n else {\r\n await this._deleteSingleOverride(override, rowVersion, false);\r\n }\r\n }\r\n\r\n private async _processSingleFieldChange(\r\n fieldData: { fieldName: string, fullName: string, elements: Element[] },\r\n newValue: string,\r\n shouldApplyEditsToAll: boolean\r\n ): Promise {\r\n /* Note: this comment is years after the fact, so hopefully I'm remembering this right.\r\n * Basically, a \"full field name\" is something like:\r\n *\r\n * topmostSubform[0].Page1[0].PP\\.TaxpayerAddress\\.State[0]\r\n *\r\n * Where PP\\.TaxpayerAddress\\.State is the \"short name\". The short name can be split into parts delimited by \\. (so in\r\n * the example above PP, TaxpayerAddress, and State). The first component of the short name is the \"namespace\", in this\r\n * case PP. Basically the PP namespace signifies this as a field PropertyPoint should attempt to process, everything\r\n * else is ignored. The second part is the name. All remaining parts are parameters.\r\n *\r\n * Originally, overrides were stored with the full name, but this became a problem after multi-account forms started being\r\n * used, since the first part of the field name depends on how the PDF is constructed, which then began to vary. The new\r\n * method stored the short name with the account parameter removed. For example, you may have something like\r\n * topmostSubform[0].Page1[0].PP\\.AccountNumber\\.Account-1[0]; that full name would then be converted to PP\\.AccountNumber\r\n * (the short name with the account number removed). So this \"old format override\" code is to deal with overrides that were\r\n * stored in the database before the change was made.\r\n *\r\n * An additional layer of complexity is in the account number parameters; PDFs have account number parameters starting from\r\n * 1 for every page in the PDF, but the UI needs account number indexes starting from 1 once at the start of the whole PDF,\r\n * so the \"uiaccountindex\" parameter tracks that. You can image a PDF like this:\r\n * Page 1\r\n * PP\\.OOV\\.Schedule-Land (UIAccountIndex-1)\r\n * Page 2\r\n * PP\\.OOV\\.Schedule-Land.Account-1 (UIAccountIndex-2)\r\n * PP\\.OOV\\.Schedule-Land.Account-2 (UIAccountIndex-3)\r\n * PP\\.OOV\\.Schedule-Land.Account-3 (UIAccountIndex-4)\r\n * PP\\.OOV\\.Schedule-Land.Account-4 (UIAccountIndex-5)\r\n * PP\\.OOV\\.Schedule-Land.Account-5 (UIAccountIndex-6)\r\n * Page 3\r\n * PP\\.OOV\\.Schedule-Land.Account-1 (UIAccountIndex-7)\r\n * PP\\.OOV\\.Schedule-Land.Account-2 (UIAccountIndex-8)\r\n * PP\\.OOV\\.Schedule-Land.Account-3 (UIAccountIndex-9)\r\n * PP\\.OOV\\.Schedule-Land.Account-4 (UIAccountIndex-10)\r\n * PP\\.OOV\\.Schedule-Land.Account-5 (UIAccountIndex-11)\r\n *\r\n * So if you see references to UIAccountIndex, that's what it's talking about. When we store overrides, the account number\r\n * should not be present (so that it will track with the correct account regardless of the context), but when the PDF is\r\n * loaded the account index -> AppealFormRevisionId association needs to be tracked.\r\n */\r\n const oldFormatOverride = this._oldFormatOverrides[fieldData.fieldName];\r\n if (oldFormatOverride) {\r\n await this._deleteOverride(oldFormatOverride.override, oldFormatOverride.rowVersion);\r\n }\r\n\r\n fieldData.elements.forEach(element => (element as any).value = newValue);\r\n\r\n const overrideUIElement: FieldOverride = {\r\n formElements: fieldData.elements,\r\n overrideValue: newValue,\r\n fieldName: fieldData.fieldName\r\n };\r\n\r\n let rowVersion: number[] = null;\r\n let appealFormItem = this.selectedForm;\r\n\r\n const savedOverride = this.overrideHolder.getSaved(fieldData.fieldName);\r\n let currentAccountIndex = 0;\r\n const perAccountField = this._multiAccountFieldMap[fieldData.fullName] !== undefined;\r\n if (perAccountField) {\r\n currentAccountIndex = this._multiAccountFieldMap[fieldData.fullName];\r\n // If currentAccountIndex is \"0\", it's an override on the main form; otherwise it's one of the items in the addtional account list\r\n if (currentAccountIndex > 0) {\r\n appealFormItem = appealFormItem.additionalAccounts[currentAccountIndex - 1];\r\n }\r\n }\r\n if (savedOverride !== undefined) {\r\n if (this.resolveAccountIndex(savedOverride) === currentAccountIndex) {\r\n rowVersion = savedOverride.rowVersion;\r\n }\r\n }\r\n\r\n // persist\r\n const appealFormReference = this.appealApplicationService.toAppealFormReference(appealFormItem);\r\n const override: Compliance.AppealFormOverrideRequestModel = {\r\n inEdit: appealFormReference,\r\n otherReferences: [],\r\n fieldName: fieldData.fieldName,\r\n value: newValue,\r\n rowVersion: rowVersion\r\n };\r\n\r\n if(shouldApplyEditsToAll) {\r\n const topFormReference = this.appealApplicationService.toAppealFormReference(this.selectedForm);\r\n // Add other appealIds as long as they're not for this form (either by appealId or additional account)\r\n override.otherReferences = this.appealFormList\r\n .filter(x => ! this.appealApplicationService.allAppealIds(topFormReference).includes(x.appealId))\r\n .map(a => this.appealApplicationService.toAppealFormReference(a));\r\n }\r\n\r\n\r\n (overrideUIElement.formElements as any[]).forEach(element => { element.disabled = true; });\r\n const cleanedOverride = Object.assign({}, override, {\r\n fieldName: this.removeUIAccountIndex(fieldData.fieldName),\r\n // During an override, do not include additional multi-account references\r\n inEdit: Object.assign({}, override.inEdit, {\r\n additionalAccounts: []\r\n })\r\n });\r\n const allResults = await this.appealApplicationService.createUpdateOverride(cleanedOverride);\r\n const result = allResults.find(r => r.appealFormRevisionId === cleanedOverride.inEdit.appealFormRevisionId);\r\n if (perAccountField) {\r\n result.fieldName = this.setUIAccountIndex(result.fieldName, currentAccountIndex);\r\n }\r\n\r\n (overrideUIElement.formElements as any[]).forEach(element => {\r\n element.disabled = false;\r\n element.classList.add(this.MODIFIED_FIELD_CSS_CLASS);\r\n });\r\n this._createOverrideUI(overrideUIElement);\r\n this._deleteInfoMarker(overrideUIElement);\r\n if(result) {\r\n this.overrideHolder.saveOverride(result, fieldData.fieldName);\r\n this.overrideAccountIndexLookup[result.appealFormRevisionOverrideId] = currentAccountIndex;\r\n }\r\n\r\n // Use selected Id instead of override Id here; what we're really interested in is the\r\n // top-page appealId, not the account-specific appealId\r\n this.appealApplicationService.setOverrideChange(this.selectedForm.appealFormRevisionId, true);\r\n }\r\n\r\n private async _deleteSingleOverride(override: FieldOverride, rowVersion: number[], shouldApplyEditsToAll: boolean): Promise {\r\n const oldFormatShortName = Object.keys(this._oldFormatOverrides).find(shortName => this._oldFormatOverrides[shortName].override === override);\r\n if (oldFormatShortName) {\r\n delete this._oldFormatOverrides[oldFormatShortName];\r\n }\r\n\r\n let appealFormItem = this.selectedForm;\r\n\r\n const currentAccountIndex = this.getUIAccountIndex(override.fieldName);\r\n const perAccountField = currentAccountIndex !== null;\r\n\r\n if (perAccountField && currentAccountIndex > 0) {\r\n appealFormItem = appealFormItem.additionalAccounts[currentAccountIndex - 1];\r\n }\r\n\r\n const appealFormReference = this.appealApplicationService.toAppealFormReference(appealFormItem);\r\n const overrideModel: Compliance.AppealFormOverrideRequestModel = {\r\n inEdit: appealFormReference,\r\n fieldName: override.fieldName,\r\n otherReferences: [],\r\n value: null,\r\n rowVersion: rowVersion\r\n };\r\n\r\n // if (perAccountField) {\r\n // overrideAppealId = this.multiAccountData[currentAccountIndex].appealId;\r\n // }\r\n // else {\r\n // currentAccountIndex = 0;\r\n // }\r\n\r\n if (shouldApplyEditsToAll) {\r\n const topFormReference = this.appealApplicationService.toAppealFormReference(this.selectedForm);\r\n // Add other appealIds as long as they're not for this form (either by appealId or additional account)\r\n overrideModel.otherReferences = this.appealFormList\r\n .filter(x => ! this.appealApplicationService.allAppealIds(topFormReference).includes(x.appealId))\r\n .map(a => this.appealApplicationService.toAppealFormReference(a));\r\n }\r\n else if (!perAccountField) {\r\n // The idea is to keep overrides \"synced\" between multi-account fields. So if we have a multi-account form and an\r\n // override is removed on a field that isn't a per-account field, also \"silently\" remove the unshown overrides\r\n // for other accounts on this form.\r\n overrideModel.otherReferences = [appealFormReference];\r\n }\r\n\r\n\r\n (override.formElements as any[]).forEach(formElement => { formElement.disabled = true; });\r\n await this.appealApplicationService.deleteOverride(Object.assign({}, overrideModel, {\r\n fieldName: this.removeUIAccountIndex(overrideModel.fieldName)\r\n }));\r\n\r\n (override.formElements as any[]).forEach(formElement => {\r\n formElement.disabled = false;\r\n formElement.classList.remove(this.MODIFIED_FIELD_CSS_CLASS);\r\n });\r\n this._deleteOverrideUI(override);\r\n\r\n if(!this.overrideHolder.overrides.length) {\r\n // Use this.appealId instead of overrideAppealId here; what we're really interested in is the\r\n // top-page appealId, not the account-specific appealId\r\n this.appealApplicationService.setOverrideChange(this.selectedForm.appealFormRevisionId, false);\r\n }\r\n }\r\n\r\n}\r\n","import { HelpContent } from '../UI-Lib/Help-Tooltip';\r\n\r\nexport const APPEAL_APPLICATION_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'appeal-application.download-form',\r\n tooltipText: 'Download Form'\r\n },\r\n {\r\n helpContentId: 'appeal-application.edit-form',\r\n tooltipText: 'Edit supplemental form associations.'\r\n },\r\n {\r\n helpContentId: 'appeal-application.edit-main-form',\r\n tooltipText: 'Edit main form associations.'\r\n },\r\n {\r\n helpContentId: 'appeal-application.edit-supplement-form',\r\n tooltipText: 'Edit supplemental form associations.'\r\n },\r\n {\r\n helpContentId: 'appeal-application.preview-form',\r\n tooltipText: 'Preview form'\r\n },\r\n {\r\n helpContentId: 'appeal-application.preview-form-has-override',\r\n tooltipText: 'Preview form (contains overrides).'\r\n },\r\n];\r\n","\r\n\r\n\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { DownloadFileService } from '../../../Common/Download/downloadFileService';\r\nimport { AppealApplicationService } from '../../appeal.application.service';\r\nimport { AppealFormItem } from '../../appeal.application.model';\r\nimport { has } from 'lodash';\r\n\r\nexport interface DownloadAppealFormModalParams {\r\n appealForms: AppealFormItem[],\r\n supplementalForms: { [id: number]: number[] }\r\n}\r\n\r\n@Component({\r\n selector: 'download-appeal-form-modal',\r\n templateUrl: './downloadAppealForm.component.html'\r\n})\r\nexport class DownloadAppealFormComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _toastr: ToastrService,\r\n private readonly _downloadFileService: DownloadFileService,\r\n private readonly _appealApplicationService: AppealApplicationService\r\n ) {}\r\n\r\n params: DownloadAppealFormModalParams;\r\n result: void;\r\n\r\n appealForms: AppealFormItem[] = [];\r\n selectedForm: AppealFormItem;\r\n isBusy: boolean;\r\n includeSupplementalForms: boolean;\r\n\r\n ngOnInit(): void {\r\n this.appealForms = this.params.appealForms || [];\r\n this.selectedForm = this.appealForms[0];\r\n }\r\n\r\n async downloadForm(): Promise {\r\n this.isBusy = true;\r\n\r\n let appealIds = [this.selectedForm.appealId, ...this.selectedForm.additionalAccounts.map(x => x.appealId)];\r\n\r\n if (this.includeSupplementalForms && has(this.params.supplementalForms, this.selectedForm.appealId)) {\r\n appealIds = [...appealIds, ...this.params.supplementalForms[this.selectedForm.appealId]];\r\n }\r\n\r\n try {\r\n const downloadRequest: Core.AppealsDownloadRequest = {\r\n batchAppealIds: appealIds,\r\n flatten: false,\r\n onlyTheseFormRevisions: [],\r\n zipOutput: false,\r\n skipOptimize: false\r\n };\r\n\r\n const response = await this._appealApplicationService.download(downloadRequest);\r\n await this._downloadFileService.downloadResponse(response);\r\n } catch (e) {\r\n this._toastr.error('An error occurred while downloading the form. Please try again later.');\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\n\r\n\r\n\r\n
\r\n
Apply changes to:
\r\n
\r\n \r\n
\r\n
\r\n There are no supplemental appeals available.\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n {{ item.name }}{{ getMessage(item) }}
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AppealApplicationService } from '../../appeal.application.service';\r\nimport { Subscription } from 'rxjs';\r\nimport { AppealFormItem } from '../../appeal.application.model';\r\n\r\nexport interface EditAppealAssociationsComponentParams {\r\n selectedAppeal: AppealFormItem;\r\n supplementalForms: Compliance.AppealSupplementalFormAssociation[];\r\n formRevisionId: number;\r\n parentAppeals: AppealFormItem[];\r\n}\r\n\r\nexport interface AvailableSupplementalFormEditModel extends Compliance.AppealSupplementalFormAssociation {\r\n isAssociatedInitial: boolean;\r\n hasChanges: boolean;\r\n totalAppeals: number;\r\n canAddToAppealTotal: number;\r\n canRemoveFromAppealTotal: number;\r\n isSelected: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'edit-appeal-supplement-associations',\r\n templateUrl: './editAppealSupplementAssociations.component.html'\r\n})\r\nexport class EditAppealSupplementAssociationsComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _appealApplicationService: AppealApplicationService\r\n ) {\r\n this.subscriptions = new Subscription();\r\n }\r\n\r\n params: EditAppealAssociationsComponentParams;\r\n result: boolean;\r\n\r\n isBusy: boolean;\r\n busyMessage: string;\r\n applyChangesScopeOptions: Compliance.NameValuePair[] = [];\r\n selectedApplyChangesScopeOption: Compliance.NameValuePair;\r\n formRevisionAssociations: AvailableSupplementalFormEditModel[] = [];\r\n hasChanges: boolean;\r\n\r\n private readonly subscriptions: Subscription;\r\n private readonly _APPLY_CHANGES_SCOPE_OPTION_ALL_SELECTED_APPEALS: Compliance.NameValuePair = {\r\n name: 'all-appeals',\r\n value: 'All appeals'\r\n };\r\n\r\n private _APPLY_CHANGES_SCOPE_OPTION_SELECTED_APPEAL: Compliance.NameValuePair = {\r\n name: 'selected-appeal',\r\n value: null\r\n };\r\n\r\n async ngOnInit(): Promise {\r\n this.applyChangesScopeOptions.push(this._APPLY_CHANGES_SCOPE_OPTION_ALL_SELECTED_APPEALS);\r\n\r\n if (this.params.selectedAppeal) {\r\n this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_APPEAL.value = this.params.selectedAppeal.parcelAcctNum;\r\n this.applyChangesScopeOptions.push(this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_APPEAL);\r\n }\r\n\r\n this.selectedApplyChangesScopeOption = this.applyChangesScopeOptions.indexOf(this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_APPEAL) === -1 ?\r\n this.applyChangesScopeOptions[this.applyChangesScopeOptions.indexOf(this._APPLY_CHANGES_SCOPE_OPTION_ALL_SELECTED_APPEALS)] :\r\n this.applyChangesScopeOptions[this.applyChangesScopeOptions.indexOf(this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_APPEAL)];\r\n\r\n this._refreshAppealFormRevisions();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n onSelectedApplyChangesScopeFilterChange(): void {\r\n this._refreshAppealFormRevisions();\r\n }\r\n\r\n onFormSelectedChange(form: AvailableSupplementalFormEditModel): void {\r\n form.isAssociated = !form.isAssociated;\r\n form.hasChanges = this.selectedApplyChangesScopeOption === this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_APPEAL\r\n ? form.isAssociatedInitial !== form.isAssociated\r\n : (form.isAssociated && form.canAddToAppealTotal !== 0) || !form.isAssociated;\r\n\r\n this.hasChanges = !!this.formRevisionAssociations.find(x => x.hasChanges);\r\n }\r\n\r\n async save(): Promise {\r\n this.busyMessage = 'Updating Form Associations';\r\n this.isBusy = true;\r\n\r\n try {\r\n const appealIds = this.selectedApplyChangesScopeOption === this._APPLY_CHANGES_SCOPE_OPTION_ALL_SELECTED_APPEALS\r\n ? this.params.parentAppeals.map(x => x.appealId)\r\n : [this.params.selectedAppeal.appealId];\r\n\r\n const updates: Compliance.AppealSupplementalFormsAssociationChangeRequest = {\r\n appealIds,\r\n changes: this.formRevisionAssociations.filter(x => x.hasChanges)\r\n .map(x => (\r\n {\r\n formRevisionId: x.supplementalFormRevisionId,\r\n parentFormRevisionId: x.parentFormRevisionId,\r\n associate: x.isAssociated\r\n }))\r\n };\r\n await this._appealApplicationService.changeSupplementalFormAssociations(updates);\r\n this.result = true;\r\n } finally {\r\n this.isBusy = false;\r\n this.cancel();\r\n }\r\n }\r\n\r\n getMessage(form: AvailableSupplementalFormEditModel): string {\r\n let message: string;\r\n\r\n if (this.selectedApplyChangesScopeOption === this._APPLY_CHANGES_SCOPE_OPTION_SELECTED_APPEAL) {\r\n if (form.isAssociated) {\r\n message = form.hasChanges\r\n ? `Adding to ${this.selectedApplyChangesScopeOption.value}`\r\n : `No changes. (added to ${this.selectedApplyChangesScopeOption.value})`;\r\n } else {\r\n message = form.hasChanges\r\n ? `Removing from ${this.selectedApplyChangesScopeOption.value}`\r\n : `No changes. (not added to ${this.selectedApplyChangesScopeOption.value})`;\r\n }\r\n } else {\r\n if (form.isAssociated) {\r\n message = form.hasChanges\r\n ? `Adding to ${form.canAddToAppealTotal} of ${form.totalAppeals} available appeals`\r\n : `No changes. (added to ${form.totalAppeals - form.canAddToAppealTotal} of ${form.totalAppeals} available appeals)`;\r\n } else {\r\n message = form.hasChanges\r\n ? `Removing from ${form.canRemoveFromAppealTotal} of ${form.totalAppeals} available appeals`\r\n : `No changes. (added to ${form.totalAppeals - form.canRemoveFromAppealTotal} of ${form.totalAppeals} available appeals)`;\r\n }\r\n }\r\n\r\n return message;\r\n }\r\n\r\n private async _refreshAppealFormRevisions(): Promise {\r\n this.busyMessage = 'Loading';\r\n this.isBusy = true;\r\n try {\r\n const allPossibleSupplementAssociations = this.params.supplementalForms;\r\n const possibleAssociationsForSelectedAppeal = allPossibleSupplementAssociations.filter(x => x.appealId === this.params.selectedAppeal.appealId);\r\n\r\n this.formRevisionAssociations = [];\r\n\r\n const totalAppeals = this.params.parentAppeals.length;\r\n\r\n possibleAssociationsForSelectedAppeal.forEach(possibleAssociation => {\r\n const canAddToAppealTotal = allPossibleSupplementAssociations.filter(x => possibleAssociation.supplementalFormRevisionId === x.supplementalFormRevisionId\r\n && !x.isAssociated).length;\r\n const canRemoveFromAppealTotal = allPossibleSupplementAssociations.filter(x => possibleAssociation.supplementalFormRevisionId === x.supplementalFormRevisionId\r\n && x.isAssociated).length;\r\n const supplemental = {\r\n ...possibleAssociation,\r\n isAssociatedInitial: possibleAssociation.isAssociated,\r\n hasChanges: false,\r\n totalAppeals,\r\n canAddToAppealTotal: canAddToAppealTotal,\r\n canRemoveFromAppealTotal: canRemoveFromAppealTotal\r\n } as AvailableSupplementalFormEditModel;\r\n\r\n this.formRevisionAssociations.push(supplemental);\r\n });\r\n\r\n\r\n this.hasChanges = !!this.formRevisionAssociations.find(x => x.hasChanges);\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { HelpContentComponent, HelpContentRendererValue } from '../../../UI-Lib/Help-Tooltip';\r\nimport { AppealFormItem } from '../../appeal.application.model';\r\n\r\n@Component({\r\n selector: 'additional-account-tooltip',\r\n template: `\r\n
\r\n
{{ appeal.siteName }} -\r\n {{ appeal.annualYear }}\r\n {{ appeal.propTypeAbbr }}\r\n {{ appeal.appealLevel }}
\r\n Accounts:\r\n
    \r\n
  • {{appeal.parcelAcctNum}}
  • \r\n
  • \r\n {{account.parcelAcctNum}}\r\n
  • \r\n
\r\n
\r\n `\r\n})\r\nexport class AdditionalAccountTooltipComponent implements HelpContentComponent>{\r\n params: HelpContentRendererValue;\r\n appeal: AppealFormItem;\r\n\r\n helpInit(): void {\r\n this.appeal = this.params.value;\r\n }\r\n}\r\n","\r\n\r\n\r\n\r\n
\r\n
Set appeal main form to:
\r\n
\r\n \r\n
\r\n
\r\n There are no main forms available.\r\n\r\n
\r\n","import {Component, OnInit} from '@angular/core';\r\nimport {IWeissmanModalComponent} from '../../../Compliance/WeissmanModalService';\r\nimport {BsModalRef} from 'ngx-bootstrap/modal';\r\nimport {AppealApplicationService} from '../../appeal.application.service';\r\nimport {Subscription} from 'rxjs';\r\nimport {AppealFormItem} from '../../appeal.application.model';\r\n\r\nexport interface EditAppealMainAssociationsComponentParams {\r\n selectedAppeal: AppealFormItem;\r\n mainForms: Compliance.AppealMainFormAssociation[];\r\n}\r\n\r\nexport interface AvailableMainFormEditModel extends Compliance.AppealMainFormAssociation {\r\n isAssociatedInitial: boolean;\r\n hasChanges: boolean;\r\n totalAppeals: number;\r\n}\r\n\r\n@Component({\r\n selector: 'edit-appeal-supplement-associations',\r\n templateUrl: './editAppealMainAssociations.component.html'\r\n})\r\nexport class EditAppealMainAssociationsComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _appealApplicationService: AppealApplicationService\r\n ) {\r\n this.subscriptions = new Subscription();\r\n }\r\n\r\n params: EditAppealMainAssociationsComponentParams;\r\n result: boolean;\r\n\r\n isBusy: boolean;\r\n busyMessage: string;\r\n selectedApplyChangesScopeOption: Compliance.NameValuePair;\r\n formRevisionAssociations: AvailableMainFormEditModel[] = [];\r\n hasChanges: boolean;\r\n\r\n newMainFormRevisionId: number;\r\n private readonly subscriptions: Subscription;\r\n\r\n async ngOnInit(): Promise {\r\n const appealMainFormAssociation = this.params.mainForms.filter(m => m.formRevisionId === this.params.selectedAppeal.formRevisionId)[0];\r\n this.newMainFormRevisionId = appealMainFormAssociation?.formRevisionId;\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save(): Promise {\r\n this.busyMessage = 'Updating Form Associations';\r\n this.isBusy = true;\r\n\r\n try {\r\n if (!this.newMainFormRevisionId) {\r\n this.result = false;\r\n return;\r\n }\r\n const updateRequest: Compliance.AppealMainFormAssociationChangeRequest = {\r\n appealId: this.params.selectedAppeal.appealId,\r\n formRevisionId: this.newMainFormRevisionId\r\n };\r\n await this._appealApplicationService.changeMainFormAssociations(updateRequest);\r\n this.result = true;\r\n } finally {\r\n this.isBusy = false;\r\n this.cancel();\r\n }\r\n }\r\n\r\n}\r\n","\r\n
\r\n {{appeal.hovered}}\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n Appeals\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Input, Output, EventEmitter, ViewChild, TemplateRef } from '@angular/core';\r\nimport { AppealFormItem } from '../appeal.application.model';\r\nimport { AppealApplicationService } from '../appeal.application.service';\r\nimport { Subscription } from 'rxjs';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { DownloadAppealFormComponent, DownloadAppealFormModalParams } from './Download-Appeal-Form/downloadAppealForm.component';\r\nimport { EditAppealSupplementAssociationsComponent, EditAppealAssociationsComponentParams } from './Edit-Appeal-Associations/editAppealSupplementAssociations.component';\r\nimport { HelpContentComponentConfig, HelpContentRendererValue } from '../../UI-Lib/Help-Tooltip';\r\nimport { AdditionalAccountTooltipComponent } from './Additional-Account-Tooltip/additionalAccountTooltip.component';\r\nimport * as _ from 'lodash';\r\nimport {FeatureFlagsService} from '../../Common/FeatureFlags/feature-flags-service';\r\nimport {\r\n EditAppealMainAssociationsComponent,\r\n EditAppealMainAssociationsComponentParams\r\n} from './Edit-Appeal-Associations/editAppealMainAssociations.component';\r\n\r\n@Component({\r\n selector: 'appeal-application-list',\r\n templateUrl: './appealApplicationList.component.html',\r\n styleUrls: [\r\n '../../Compliance/Return/Return-Parts/Preview/Form-List/returnPreviewFormList.component.scss',\r\n 'appealApplicationList.component.scss'\r\n ]\r\n})\r\nexport class AppealApplicationListComponent implements OnInit {\r\n constructor(private readonly _appealApplicationService: AppealApplicationService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _featureFlagService: FeatureFlagsService) {}\r\n\r\n @Input() appealIds: number[];\r\n @Input() defaultSelectedAppealId: number;\r\n @Output() formSelected: EventEmitter = new EventEmitter();\r\n @Output() appealFormListFetched: EventEmitter = new EventEmitter();\r\n\r\n @ViewChild('appealTemplate', { static: true }) appealTemplate: TemplateRef;\r\n @ViewChild('supplementalTemplate', { static: true }) supplementalTemplate: TemplateRef;\r\n\r\n canEdit: boolean = true;\r\n editMode: boolean;\r\n selectedAppealFormRevisionId: number;\r\n appealFormList: AppealFormItem[];\r\n subscription: Subscription;\r\n additionalAccountsTooltip: HelpContentComponentConfig> = {\r\n component: AdditionalAccountTooltipComponent,\r\n componentParams: {}\r\n };\r\n hoveredAppealFormRevisionId: number;\r\n\r\n private _availableSupplementalForms: Compliance.AppealSupplementalFormAssociation[];\r\n private _availableMainForms: Compliance.AppealMainFormAssociation[];\r\n\r\n async ngOnInit(): Promise {\r\n await this._appealApplicationService.correctApplicationFormRevisions(this.appealIds);\r\n this.subscription = this._appealApplicationService.overrideChange$.subscribe(\r\n overrideChange => {\r\n const changedItem: AppealFormItem = this.appealFormList.find(x => x.appealFormRevisionId === overrideChange.appealFormRevisionId);\r\n\r\n if (changedItem) {\r\n changedItem.hasOverrides = overrideChange.overridden;\r\n\r\n if (this._appealApplicationService.shouldApplyEditsToAll) {\r\n this.appealFormList = this.appealFormList.map(item => {\r\n item.hasOverrides = overrideChange.overridden;\r\n\r\n return item;\r\n });\r\n }\r\n }\r\n }\r\n );\r\n await this._getAppealList();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.subscription.unsubscribe();\r\n }\r\n\r\n formSelectedOnList(item: AppealFormItem): void {\r\n if (this.selectedAppealFormRevisionId !== item.appealFormRevisionId) {\r\n this.selectedAppealFormRevisionId = item.appealFormRevisionId;\r\n\r\n this.formSelected.emit(item);\r\n }\r\n }\r\n\r\n async downloadAppealDocument(parcelAcctNum: string): Promise {\r\n const appealForms = this.appealFormList.filter(x => x.parcelAcctNum === parcelAcctNum && !x.parentFormRevisionId);\r\n const supplementalForms = this.appealFormList.filter(x => !!x.parentFormRevisionId)\r\n .reduce((acc, x) => {\r\n if (!_.has(acc, x.parentFormRevisionId)) {\r\n acc[x.parentFormRevisionId] = [];\r\n }\r\n acc[x.parentFormRevisionId].push();\r\n return acc;\r\n }, {});\r\n\r\n const params: DownloadAppealFormModalParams = {\r\n appealForms,\r\n supplementalForms\r\n };\r\n\r\n await this._modalService.showAsync(DownloadAppealFormComponent, params, 'modal-md');\r\n }\r\n\r\n async editAppealSupplements(appeal: AppealFormItem): Promise {\r\n const params: EditAppealAssociationsComponentParams = {\r\n selectedAppeal: appeal,\r\n supplementalForms: this._availableSupplementalForms,\r\n formRevisionId: appeal.formRevisionId,\r\n parentAppeals: this.appealFormList.filter(x => !x.parentFormRevisionId && !x.additionalAccounts.length)\r\n };\r\n\r\n const result = await this._modalService.showAsync(EditAppealSupplementAssociationsComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._getAppealList();\r\n }\r\n\r\n async editAppealMainForms(appeal: AppealFormItem) : Promise\r\n {\r\n const params : EditAppealMainAssociationsComponentParams = {\r\n selectedAppeal: appeal,\r\n mainForms: this._availableNonMultiAccountMainFormsFor(appeal)\r\n };\r\n if (!this.canChangeMainForm(appeal))\r\n {\r\n return Promise.resolve();\r\n }\r\n const result = await this._modalService.showAsync(EditAppealMainAssociationsComponent, params, 'modal-md');\r\n\r\n if (!result){\r\n return Promise.resolve();\r\n }\r\n\r\n await this._getAppealList();\r\n }\r\n\r\n toggleHovered(appeal: AppealFormItem): void {\r\n this.hoveredAppealFormRevisionId = appeal && appeal.appealFormRevisionId;\r\n }\r\n\r\n canChangeSupplements(appeal: AppealFormItem): boolean {\r\n if (!appeal || appeal.isMultiAccount) {\r\n return false;\r\n }\r\n const supplements = (this._availableSupplementalForms ?? []).filter(x => x.appealId === appeal.appealId && x.parentFormRevisionId === appeal.formRevisionId);\r\n if (!supplements || supplements.length < 1) {\r\n return false;\r\n }\r\n return true;\r\n }\r\n\r\n canChangeMainForm(appeal: AppealFormItem): boolean {\r\n if (!appeal || appeal.isMultiAccount) {\r\n return false;\r\n }\r\n\r\n const mainForms = this._availableNonMultiAccountMainFormsFor(appeal);\r\n\r\n if (!mainForms || mainForms.length < 1) {\r\n return false;\r\n }\r\n\r\n const otherMainForms = mainForms.filter(x => !x.isAssociated);\r\n\r\n if (otherMainForms.length < 1) {\r\n return false;\r\n }\r\n return true;\r\n }\r\n\r\n private async _getAppealList(): Promise {\r\n const appealFormList = await this._appealApplicationService.getAppealList(this.appealIds);\r\n const getAllAppealForms = () => appealFormList.concat(_.flatMap(appealFormList, afl => afl.additionalAccounts));\r\n const appealsNeedingCaching = appealFormList.filter(a => a.useCache);\r\n if (appealsNeedingCaching.length > 0) {\r\n await this._appealApplicationService.cacheForms(appealsNeedingCaching.map(i => this._appealApplicationService.toAppealFormReference(i)));\r\n }\r\n\r\n this.appealFormListFetched.emit(getAllAppealForms());\r\n\r\n // Assign the templates\r\n appealFormList.forEach(x => {\r\n if (!x.parentFormRevisionId) {\r\n x.template = this.appealTemplate;\r\n } else {\r\n x.template = this.supplementalTemplate;\r\n }\r\n });\r\n console.log('assign list');\r\n this.appealFormList = appealFormList;\r\n\r\n // Set default form\r\n let defaultForm = this.appealFormList[0];\r\n if (this.defaultSelectedAppealId !== null) {\r\n defaultForm = this.appealFormList.find(a => a.appealId == this.defaultSelectedAppealId);\r\n if (!defaultForm) {\r\n defaultForm = this.appealFormList[0];\r\n }\r\n }\r\n this.formSelectedOnList(defaultForm);\r\n\r\n // Get supplemental forms\r\n await this._getAvailableSupplementalForms();\r\n await this._getAvailableMainForms();\r\n }\r\n\r\n private async _getAvailableSupplementalForms(): Promise {\r\n const appealIds = this.appealFormList.filter(x => !x.parentFormRevisionId).map(x => x.appealId);\r\n this._availableSupplementalForms = await this._appealApplicationService.getAvailableSupplementForms(appealIds);\r\n }\r\n\r\n private async _getAvailableMainForms(): Promise {\r\n const appealIds = this.appealFormList.filter(x => !x.parentFormRevisionId).map(x => x.appealId);\r\n this._availableMainForms = await this._appealApplicationService.getAvailableMainForms(appealIds);\r\n }\r\n\r\n private _availableNonMultiAccountMainFormsFor(appeal: AppealFormItem) {\r\n const mainForms = this._availableMainForms ?? [];\r\n return mainForms.filter(x => x.appealId === appeal.appealId && !x.isMultiAccount);\r\n }\r\n}\r\n","import { TemplateRef } from '@angular/core';\r\n\r\nexport interface AppealFormOverrideModel extends Compliance.VersionedModel {\r\n fieldName: string;\r\n appealFormRevisionOverrideId: number;\r\n appealFormRevisionId: number;\r\n value: string;\r\n}\r\n\r\nexport class AppealFormItem {\r\n appealId: number;\r\n appealLevel: string;\r\n appealFormRevisionId: number;\r\n annualYear: number;\r\n companyId: number;\r\n companyName: string;\r\n siteId: number;\r\n siteName: string;\r\n parcelId: number;\r\n parcelAcctNum: string;\r\n formRevisionId: number;\r\n formRevisionName: string;\r\n parentFormRevisionId: number;\r\n hasOverrides: boolean;\r\n isTopAppeal: boolean;\r\n //matchedFormRevisionId: number;\r\n additionalAccounts: AppealFormItem[];\r\n propTypeAbbr: string;\r\n useLRProcess: boolean;\r\n useCache: boolean;\r\n propertyTypeID: number;\r\n isMultiAccount: boolean;\r\n template: TemplateRef;\r\n}\r\n\r\nexport class AppealFormSettingLookup {\r\n [groupNumber: number]: {\r\n options: AppealFormSettingLookupOption[];\r\n exceptions: AppealFormException[];\r\n }\r\n}\r\n\r\nexport class AppealFormSettingLookupOption {\r\n appealFormSettingsLookupId: number;\r\n groupNumber: number;\r\n name: string;\r\n}\r\n\r\nexport class AppealFormSettings {\r\n constructor() {\r\n this.settings = new AppealFormDropdownSettings();\r\n }\r\n\r\n settings: AppealFormDropdownSettings;\r\n isMultiAccount: boolean;\r\n exceptions: AppealFormException[];\r\n}\r\n\r\nexport class AppealFormDropdownSettings {\r\n constructor() {\r\n this.ownerName = 4;\r\n this.ownerAddress = 21;\r\n this.agentContact = 30;\r\n this.agentAddress = 40;\r\n this.agentPhone = 50;\r\n this.signer = 60;\r\n this.signerType = 70;\r\n }\r\n\r\n ownerName: number;\r\n ownerAddress: number;\r\n agentContact: number;\r\n agentContactOtherValue: number;\r\n agentAddress: number;\r\n agentPhone: number;\r\n signer: number;\r\n signerOtherValue: number;\r\n signerType: number;\r\n applyDigitalSignature: number;\r\n multiAccount: any;\r\n}\r\n\r\nexport class AppealFormException {\r\n appealFormRevisionSettingsID: number;\r\n appealFormRevisionID: number;\r\n groupNumber: number;\r\n value: number;\r\n otherValue: string;\r\n efAction: string;\r\n}\r\n","
\r\n
\r\n
\r\n

Settings

\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n\t\t\t\t\t
\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t
\r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n Saving Settings...\r\n
\r\n\r\n
\r\n
\r\n","import { Component, OnInit, Input, EventEmitter, Output } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AppealApplicationService } from '../appeal.application.service';\r\nimport * as _ from 'lodash';\r\nimport { AppealFormSettings, AppealFormSettingLookup, AppealFormSettingLookupOption, AppealFormException } from '../appeal.application.model';\r\nimport { ExtendedContactModel } from '../../Compliance/Return/Models/extendedContactModel';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { InstanceRepository } from '../../Entity/Instance/instance.repository';\r\nimport { ContactsUpgradeService } from '../../Contact/contacts.service.upgrade';\r\n\r\n@Component({\r\n selector: 'appeal-application-settings',\r\n templateUrl: './appeal.application.settings.component.html'\r\n})\r\nexport class AppealApplicationSettingsComponent implements OnInit {\r\n constructor(\r\n private appealApplicationService: AppealApplicationService,\r\n private instanceRepository : InstanceRepository,\r\n private toastr: ToastrService,\r\n private contactService: ContactsUpgradeService\r\n ) {}\r\n\r\n @Input() appealFormRevisionIds: number[];\r\n @Input() appealId: number;\r\n @Output() settingsChanged: EventEmitter = new EventEmitter();\r\n @Output() multiAccountSettingChanged: EventEmitter = new EventEmitter();\r\n appealFormSettings: AppealFormSettings;\r\n appealFormSettingLookups: AppealFormSettingLookup;\r\n savingSettings: boolean = false;\r\n agentContactOtherId: number;\r\n signerOtherId: number;\r\n instanceId: number;\r\n groupNumberMap: { [appealFormSettingsLookupId: number]: { title: string, settingsProp: string } };\r\n search: any;\r\n oldAgentContact: number;\r\n oldSigner: number;\r\n\r\n\r\n ngOnInit() {\r\n this._getData();\r\n this.getInstanceIdForAppeal();\r\n this.groupNumberMap = this.appealApplicationService.getGroupNumberMap();\r\n }\r\n\r\n async saveSetting(groupNumber: number, isException: boolean, otherModel?: ExtendedContactModel): Promise {\r\n this.savingSettings = true;\r\n\r\n try {\r\n const lookup = this.appealFormSettingLookups[groupNumber];\r\n\r\n // console.log('this.appealFormSettings.settings[this.groupNumberMap[groupNumber].settingsProp]', this.appealFormSettings.settings[this.groupNumberMap[groupNumber].settingsProp]);\r\n\r\n const payload: any = {\r\n appealRevisionFormIds: isException ? _.map(lookup.exceptions, 'appealFormRevisionID') : this.appealFormRevisionIds,\r\n groupNumber: groupNumber,\r\n value: this.appealFormSettings.settings[this.groupNumberMap[groupNumber].settingsProp]\r\n };\r\n\r\n if(otherModel) {\r\n if(groupNumber === 3) {\r\n this.appealFormSettings.settings.agentContactOtherValue = otherModel.model.contactID;\r\n } else {\r\n this.appealFormSettings.settings.signerOtherValue = otherModel.model.contactID;\r\n }\r\n\r\n payload.otherValue = otherModel.model.contactID;\r\n }\r\n\r\n await this.appealApplicationService.saveSettings(payload);\r\n\r\n if (groupNumber === 9 && payload.value === 1) {\r\n // user wants to apply digital signature - check permissions etc\r\n //\r\n const checkIfSignatureMayBeAppliedResult = await this.appealApplicationService.checkIfSignatureMayBeApplied(payload);\r\n if (checkIfSignatureMayBeAppliedResult)\r\n {\r\n this.toastr.error(checkIfSignatureMayBeAppliedResult);\r\n this.appealFormSettings.settings[this.groupNumberMap[9].settingsProp] = 0;\r\n\r\n await this.appealApplicationService.saveSettings({\r\n appealRevisionFormIds: isException ? _.map(lookup.exceptions, 'appealFormRevisionID') : this.appealFormRevisionIds,\r\n groupNumber: 9,\r\n value: 0\r\n });\r\n }\r\n }\r\n\r\n if (groupNumber === 8) {\r\n this.multiAccountSettingChanged.emit(true);\r\n }\r\n else {\r\n this.settingsChanged.emit(true);\r\n }\r\n // Changing a setting will clear all exceptions as long as the API call succeeds\r\n lookup.exceptions = [];\r\n } finally {\r\n this.savingSettings = false;\r\n }\r\n }\r\n\r\n\r\n async setFlagApplyDigitalSignature(groupNumber: number, isException: boolean): Promise {\r\n if (this.appealFormSettings.settings[this.groupNumberMap[groupNumber].settingsProp] === 1) {\r\n this.appealFormSettings.settings[this.groupNumberMap[groupNumber].settingsProp] = 0;\r\n } else {\r\n this.appealFormSettings.settings[this.groupNumberMap[groupNumber].settingsProp] = 1;\r\n }\r\n await this.saveSetting(groupNumber, isException);\r\n }\r\n\r\n private async _getData() {\r\n await this._getDropdowns();\r\n this._getSavedSettings();\r\n }\r\n\r\n private async _getDropdowns() {\r\n const options: AppealFormSettingLookupOption[] = await this.appealApplicationService.getApplicationFormLookups();\r\n\r\n this.appealFormSettingLookups = _.chain(options)\r\n .groupBy('groupNumber')\r\n .mapValues((optionArr: AppealFormSettingLookupOption[]) => {\r\n return {\r\n options: optionArr,\r\n exceptions: []\r\n };\r\n })\r\n .value();\r\n }\r\n\r\n private async getInstanceIdForAppeal() {\r\n this.instanceId = await lastValueFrom(this.instanceRepository.getEntityInstanceId('appeal', this.appealId));\r\n this.search = {\r\n find: (filter) => {\r\n return this.contactService.search(this.instanceId, filter, 1, 100, true);\r\n }\r\n };\r\n }\r\n\r\n private async _getSavedSettings(): Promise {\r\n this.appealFormSettings = await this.appealApplicationService.getSettings(this.appealFormRevisionIds) || new AppealFormSettings();\r\n\r\n _.forEach(this.appealFormSettings.exceptions, (exception: AppealFormException) => this.appealFormSettingLookups[exception.groupNumber].exceptions.push(exception));\r\n\r\n this.agentContactOtherId = this.appealFormSettings.settings.agentContactOtherValue || null;\r\n this.signerOtherId = this.appealFormSettings.settings.signerOtherValue || null;\r\n\r\n //console.log('this.appealFormSettings', this.appealFormSettings);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n Appeal Application\r\n

\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ViewChild, ChangeDetectorRef } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { Subscription } from 'rxjs';\r\nimport { AppealApplicationService } from './appeal.application.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AppealApplicationViewerComponent } from './PDF-Viewer/appealApplicationViewer.component';\r\nimport { ActionViewPersistenceService } from '../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { AppealFormItem } from './appeal.application.model';\r\nimport { BusyIndicatorRef, BusyIndicatorService, SnackBarService } from '../Busy-Indicator';\r\nimport { DownloadFileService } from '../Common/Download/downloadFileService';\r\nimport { HelpService } from '../UI-Lib/Help-Tooltip';\r\nimport { APPEAL_APPLICATION_HELP } from './appealApplication.help';\r\n\r\n@Component({\r\n selector: 'appeal-application',\r\n templateUrl: './appealApplication.component.html'\r\n})\r\nexport class AppealApplicationComponent implements OnInit {\r\n constructor(private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _appealApplicationService: AppealApplicationService,\r\n private readonly _toastsManager: ToastrService,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService,\r\n private readonly _changeDetectorRef: ChangeDetectorRef,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _downloadFileService: DownloadFileService,\r\n private readonly _helpService: HelpService,\r\n private readonly _snackBarService: SnackBarService\r\n ) { }\r\n\r\n @ViewChild(AppealApplicationViewerComponent) appealApplicationViewer;\r\n appealIds: number[];\r\n defaultSelectedAppealId: number;\r\n appealFormList: AppealFormItem[];\r\n appealFormRevisionIds: number[];\r\n selectedForm: AppealFormItem;\r\n state: any;\r\n isDownloadingForms: boolean = false;\r\n haveSettingsChanged: boolean = false;\r\n hasMultiAccountSettingChanged: boolean = false;\r\n isCompleting: boolean = false;\r\n initBusyRef: BusyIndicatorRef;\r\n\r\n private _appealApplicationChangeSub: Subscription;\r\n private _longRunningProcessId: number;\r\n\r\n ngOnInit() {\r\n this._helpService.setContent(APPEAL_APPLICATION_HELP);\r\n\r\n this.state = this._upgradeNavigationServiceHandler.getCurrentState();\r\n this.defaultSelectedAppealId = null;\r\n this.initBusyRef = this._busyIndicatorService.show({ message: 'Initializing Viewer' });\r\n\r\n switch (this.state.name) {\r\n case 'appealApplicationBatch':\r\n const appealBatchId = this._upgradeNavigationServiceHandler.getQuerystringParam('appealBatchId');\r\n if (appealBatchId) {\r\n const serializedAppealIds: string = sessionStorage[`AppealApplicationBatch${ appealBatchId}`];\r\n if (serializedAppealIds) {\r\n this.appealIds = JSON.parse(serializedAppealIds);\r\n }\r\n else {\r\n // TODO: Handle this case somehow (we got an appeal batch ID string, but sessionStorage didn't have it)\r\n }\r\n }\r\n break;\r\n case 'appealApplication':\r\n this.appealIds = [parseInt(this._routerService.getQuerystringParam('appealId'))];\r\n break;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._appealApplicationChangeSub && this._appealApplicationChangeSub.unsubscribe();\r\n }\r\n\r\n onAppealFormListRetrieved(appealFormList: AppealFormItem[]) {\r\n this.initBusyRef.hide();\r\n this.appealFormList = appealFormList;\r\n this.appealFormRevisionIds = appealFormList.map(af => af.appealFormRevisionId);\r\n }\r\n\r\n async onViewerTabSelected(_event: any) {\r\n if (this.haveSettingsChanged) {\r\n await this.appealApplicationViewer.loadForm();\r\n this.haveSettingsChanged = false;\r\n }\r\n else if (this.hasMultiAccountSettingChanged) {\r\n // If we changed the multi-account settings, we want to reset the appeal list component.\r\n this.defaultSelectedAppealId = this.selectedForm.appealId;\r\n const originalAppealIds = this.appealIds;\r\n this.selectedForm = null;\r\n this.appealIds = null;\r\n this._changeDetectorRef.detectChanges();\r\n this.appealIds = originalAppealIds;\r\n this._changeDetectorRef.detectChanges();\r\n\r\n this.hasMultiAccountSettingChanged = false;\r\n }\r\n }\r\n\r\n async topAppealSelected(newTopAppealFormRevisionId: number) {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Setting Top Account' });\r\n let topAppealId: number;\r\n try {\r\n const additionalTopAccounts = this.selectedForm.additionalAccounts.filter(a => a.appealFormRevisionId === newTopAppealFormRevisionId);\r\n if (additionalTopAccounts.length > 0) {\r\n topAppealId = additionalTopAccounts[0].appealId;\r\n }\r\n else if (this.selectedForm.appealFormRevisionId === newTopAppealFormRevisionId) {\r\n topAppealId = this.selectedForm.appealId;\r\n }\r\n\r\n await this._appealApplicationService.setTopAppeal({\r\n otherAppealIds: [this.selectedForm]\r\n .concat(this.selectedForm.additionalAccounts)\r\n .map(a => a.appealId)\r\n .filter(a => a !== topAppealId),\r\n topAppealId: topAppealId\r\n });\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n // As with multi-account settings, reload the appeal list component if a new top page was selected\r\n this.defaultSelectedAppealId = topAppealId;\r\n const originalAppealIds = this.appealIds;\r\n this.selectedForm = null;\r\n this.appealIds = null;\r\n this._changeDetectorRef.detectChanges();\r\n this.appealIds = originalAppealIds;\r\n this._changeDetectorRef.detectChanges();\r\n }\r\n\r\n async generateOutput(): Promise {\r\n if (this.appealFormList.some(a => a.useLRProcess)) {\r\n this._longRunningProcessId = await this._appealApplicationService.generateOutputFile(this.appealIds);\r\n this._snackBarService.addById(this._longRunningProcessId, Compliance.LongRunningProcessTypeEnum.GetAppealApplications);\r\n } else {\r\n this.isDownloadingForms = true;\r\n\r\n try {\r\n const downloadRequest: Core.AppealsDownloadRequest = {\r\n batchAppealIds: this.appealIds,\r\n flatten: false,\r\n onlyTheseFormRevisions: [],\r\n zipOutput: false,\r\n skipOptimize: false\r\n };\r\n\r\n const response = await this._appealApplicationService.flattenAndDownload(downloadRequest);\r\n await this._downloadFileService.downloadResponse(response);\r\n } catch (e) {\r\n this._toastsManager.error('An error occurred while downloading the forms. Please try again later.');\r\n } finally {\r\n this.isDownloadingForms = false;\r\n }\r\n }\r\n }\r\n\r\n async downloadEditable(): Promise {\r\n this.isDownloadingForms = true;\r\n\r\n try {\r\n const downloadRequest: Core.AppealsDownloadRequest = {\r\n batchAppealIds: this.appealIds,\r\n flatten: false,\r\n onlyTheseFormRevisions: [],\r\n zipOutput: false,\r\n skipOptimize: false\r\n };\r\n\r\n const response = await this._appealApplicationService.download(downloadRequest);\r\n await this._downloadFileService.downloadResponse(response);\r\n } catch (e) {\r\n this._toastsManager.error('An error occurred while downloading the forms. Please try again later.');\r\n } finally {\r\n this.isDownloadingForms = false;\r\n }\r\n }\r\n\r\n async downloadFlat(): Promise {\r\n this.isDownloadingForms = true;\r\n\r\n try {\r\n const downloadRequest: Core.AppealsDownloadRequest = {\r\n batchAppealIds: this.appealIds,\r\n flatten: true,\r\n onlyTheseFormRevisions: [],\r\n zipOutput: false,\r\n skipOptimize: false\r\n };\r\n\r\n const response = await this._appealApplicationService.flattenAndDownload(downloadRequest)\r\n await this._downloadFileService.downloadResponse(response);\r\n } catch (e) {\r\n this._toastsManager.error('An error occurred while downloading the forms. Please try again later.');\r\n } finally {\r\n this.isDownloadingForms = false;\r\n }\r\n }\r\n\r\n async complete(): Promise {\r\n this.isCompleting = true;\r\n try {\r\n await this._appealApplicationService.completeAppealTasks(this.appealIds);\r\n } catch (e) {\r\n this.isCompleting = false;\r\n this._toastsManager.error(e.errorMessage);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n this._goBackToPreviousState();\r\n }\r\n\r\n close() {\r\n this._goBackToPreviousState();\r\n }\r\n\r\n private _goBackToPreviousState() {\r\n switch (this.state.name) {\r\n case 'appealApplicationBatch':\r\n this._upgradeNavigationServiceHandler.go('actionview', this._actionViewPersistenceService.routeParams);\r\n break;\r\n case 'appealApplication':\r\n this._upgradeNavigationServiceHandler.go('parcel', { companyId: this.selectedForm.companyId, siteId: this.selectedForm.siteId, parcelId: this.selectedForm.parcelId });\r\n break;\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForExpandCellRenderer extends ICellRendererParams {\r\n expand: (params: ICellRendererParamsForExpandCellRenderer) => void;\r\n collapse: (params: ICellRendererParamsForExpandCellRenderer) => void;\r\n showHiddenChildren: (params: ICellRendererParamsForExpandCellRenderer) => void;\r\n canExpand: (params: ICellRendererParamsForExpandCellRenderer) => boolean;\r\n canCollapse: (params: ICellRendererParamsForExpandCellRenderer) => boolean;\r\n canShowHiddenChildren: (params: ICellRendererParamsForExpandCellRenderer) => boolean;\r\n getName: (params: ICellRendererParamsForExpandCellRenderer) => string;\r\n getTooltip: (params: ICellRendererParamsForExpandCellRenderer) => string;\r\n}\r\n\r\n@Component({\r\n selector: 'expand-cell',\r\n template: `\r\n\r\n \r\n \r\n\r\n{{ params.getName(params) }}\r\n ( + )`\r\n})\r\nexport class ExpandCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForExpandCellRenderer;\r\n\r\n agInit(params: ICellRendererParamsForExpandCellRenderer): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { IHeaderAngularComp } from 'ag-grid-angular';\r\nimport { IHeaderParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForExpandCellHeaderParams extends IHeaderParams {\r\n expandAll: (params: ICellRendererParamsForExpandCellHeaderParams) => void;\r\n collapseAll: (params: ICellRendererParamsForExpandCellHeaderParams) => void;\r\n canExpandAll: (params: ICellRendererParamsForExpandCellHeaderParams) => boolean;\r\n canCollapseAll: (params: ICellRendererParamsForExpandCellHeaderParams) => boolean;\r\n headerText: string;\r\n}\r\n\r\n@Component({\r\n selector: 'expand-cell-header',\r\n template: `\r\n\r\n \r\n \r\n {{params.headerText}}`\r\n})\r\nexport class ExpandCellHeaderRendererComponent implements IHeaderAngularComp {\r\n params: ICellRendererParamsForExpandCellHeaderParams;\r\n\r\n agInit(params: ICellRendererParamsForExpandCellHeaderParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import Guid = System.Guid;\r\n\r\nexport class AppealRecommendationGridRowInfoTreeItemModel implements Core.AppealRecommendationGridRowInfoModel {\r\n constructor(model: Core.AppealRecommendationGridRowInfoModel) {\r\n this.accountHandler = model.accountHandler;\r\n this.accountHandlerUserId = model.accountHandlerUserId;\r\n this.annualAssessmentId = model.annualAssessmentId;\r\n this.appealDeadline = model.appealDeadline;\r\n this.appealLevel = model.appealLevel;\r\n this.appealRecommendationStatus = model.appealRecommendationStatus;\r\n this.appealRecommendationStatusId = model.appealRecommendationStatusId;\r\n this.assesseeName = model.assesseeName;\r\n this.assessorId = model.assessorId;\r\n this.assessorName = model.assessorName;\r\n this.canChangeAppealRecommendationStatus = model.canChangeAppealRecommendationStatus;\r\n this.canEdit = model.canEdit;\r\n this.class = model.class;\r\n this.companyId = model.companyId;\r\n this.companyName = model.companyName;\r\n this.createDate = model.createDate;\r\n this.currentAV = model.currentAV;\r\n this.currentFMV = model.currentFMV;\r\n this.currentImpsAV = model.currentImpsAV;\r\n this.currentImpsFMV = model.currentImpsFMV;\r\n this.currentPersAV = model.currentPersAV;\r\n this.currentPersFMV = model.currentPersFMV;\r\n this.currentAltAV = model.currentAltAV;\r\n this.currentAltFMV = model.currentAltFMV;\r\n this.currentLandAV = model.currentLandAV;\r\n this.currentLandFMV = model.currentLandFMV;\r\n this.determineIfAppealWarrantedTaskId = model.determineIfAppealWarrantedTaskId;\r\n this.emailSentDate = model.emailSentDate;\r\n this.entityId = model.entityId;\r\n this.entityName = model.entityName;\r\n this.fmvVariance = model.fmvVariance;\r\n this.instanceId = model.instanceId;\r\n this.isClientApproved = model.isClientApproved;\r\n this.isClientApprovalRequired = model.isClientApprovalRequired;\r\n this.isReady = model.isReady;\r\n this.originalAV = model.originalAV;\r\n this.originalFMV = model.originalFMV;\r\n this.originalImpsAV = model.originalImpsAV;\r\n this.originalImpsFMV = model.originalImpsFMV;\r\n this.originalPersAV = model.originalPersAV;\r\n this.originalPersFMV = model.originalPersFMV;\r\n this.originalAltAV = model.originalAltAV;\r\n this.originalAltFMV = model.originalAltFMV;\r\n this.originalLandAV = model.originalLandAV;\r\n this.originalLandFMV = model.originalLandFMV;\r\n this.parcelAccountNumber = model.parcelAccountNumber;\r\n this.priorYearAppealId = model.priorYearAppealId;\r\n this.priorYearAppeal = model.priorYearAppeal;\r\n this.parcelId = model.parcelId;\r\n this.priorYearAV = model.priorYearAV;\r\n this.priorYearFMV = model.priorYearFMV;\r\n this.priorYearImpsAV = model.priorYearImpsAV;\r\n this.priorYearImpsFMV = model.priorYearImpsFMV;\r\n this.priorYearPersAV = model.priorYearPersAV;\r\n this.priorYearPersFMV = model.priorYearPersFMV;\r\n this.priorYearAltAV = model.priorYearAltAV;\r\n this.priorYearAltFMV = model.priorYearAltFMV;\r\n this.priorYearLandAV = model.priorYearLandAV;\r\n this.priorYearLandFMV = model.priorYearLandFMV;\r\n this.propertyType = model.propertyType;\r\n this.responsibleUser = model.responsibleUser;\r\n this.revisionName = model.revisionName;\r\n this.savings = model.savings;\r\n this.siteId = model.siteId;\r\n this.siteName = model.siteName;\r\n this.state = model.state;\r\n this.stateId = model.stateId;\r\n this.targetValue = model.targetValue;\r\n this.taxYear = model.taxYear;\r\n this.team = model.team;\r\n this.topLevelCompanyId = model.topLevelCompanyId;\r\n this.topLevelCompanyName = model.topLevelCompanyName;\r\n this.totalDollarSqFt = model.totalDollarSqFt;\r\n this.totalDollarUnit = model.totalDollarUnit;\r\n this.totalLandDollarAcre = model.totalLandDollarAcre;\r\n this.totalLandDollarSqFt = model.totalLandDollarSqFt;\r\n this.totalPriorYearDollarSqFt = model.totalPriorYearDollarSqFt;\r\n this.totalPriorYearDollarUnit = model.totalPriorYearDollarUnit;\r\n this.totalPriorYearLandDollarAcre = model.totalPriorYearLandDollarAcre;\r\n this.totalPriorYearLandDollarSqFt = model.totalPriorYearLandDollarSqFt;\r\n this.hasComments = model.hasComments;\r\n this.hasAttachments = model.hasAttachments;\r\n }\r\n\r\n accountHandler: string;\r\n accountHandlerUserId: Guid;\r\n annualAssessmentId: number;\r\n appealDeadline: Date;\r\n appealLevel: string;\r\n appealRecommendationStatus: string;\r\n appealRecommendationStatusId: number;\r\n assesseeName: string;\r\n assessorId: number;\r\n assessorName: string;\r\n canChangeAppealRecommendationStatus: boolean;\r\n canEdit: boolean;\r\n class: string;\r\n companyId: number;\r\n companyName: string;\r\n createDate: Date;\r\n currentAV: number;\r\n currentFMV: number;\r\n currentImpsAV: number;\r\n currentImpsFMV: number;\r\n currentPersAV: number;\r\n currentPersFMV: number;\r\n currentAltAV: number;\r\n currentAltFMV: number;\r\n currentLandAV: number;\r\n currentLandFMV: number;\r\n determineIfAppealWarrantedTaskId: number;\r\n emailSentDate: Date;\r\n entityId: string;\r\n entityName: string;\r\n fmvVariance: number;\r\n instanceId: number;\r\n isClientApproved?: boolean;\r\n isClientApprovalRequired: boolean;\r\n isReady: boolean;\r\n originalAV: number;\r\n originalFMV: number;\r\n originalImpsFMV: number;\r\n originalImpsAV: number;\r\n originalPersFMV: number;\r\n originalPersAV: number;\r\n originalAltAV: number;\r\n originalAltFMV: number;\r\n originalLandAV: number;\r\n originalLandFMV: number;\r\n parcelAccountNumber: string;\r\n parcelId: number;\r\n priorYearAppeal: string;\r\n priorYearAppealId: number;\r\n priorYearAV: number;\r\n priorYearFMV: number;\r\n priorYearImpsAV: number;\r\n priorYearImpsFMV: number;\r\n priorYearPersAV: number;\r\n priorYearPersFMV: number;\r\n priorYearAltAV: number;\r\n priorYearAltFMV: number;\r\n priorYearLandAV: number;\r\n priorYearLandFMV: number;\r\n propertyType: string;\r\n responsibleUser: string;\r\n revisionName: string;\r\n savings: number;\r\n siteId: number;\r\n siteName: string;\r\n state: string;\r\n stateId: number;\r\n targetValue: number;\r\n taxYear: number;\r\n team: string;\r\n topLevelCompanyId: number;\r\n topLevelCompanyName: string;\r\n totalDollarSqFt: number;\r\n totalDollarUnit: number;\r\n totalLandDollarAcre: number;\r\n totalLandDollarSqFt: number;\r\n totalPriorYearDollarSqFt: number;\r\n totalPriorYearDollarUnit: number;\r\n totalPriorYearLandDollarAcre: number;\r\n totalPriorYearLandDollarSqFt: number;\r\n hasComments: boolean;\r\n hasAttachments: boolean;\r\n hasError: boolean;\r\n\r\n get level(): number {\r\n return this.parcelId ? 2 : 1;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\n\r\nexport interface AgGridTooltipCellRendererParams extends ICellRendererParams {\r\n getTooltipText: (params: AgGridTooltipCellRendererParams) => string;\r\n}\r\n\r\n@Component({\r\n selector: 'ag-grid-tooltip-cell-renderer',\r\n template: `\r\n
\r\n {{cellText}}\r\n x\r\n
\r\n `\r\n})\r\nexport class AgGridTooltipCellRendererComponent implements ICellRendererAngularComp {\r\n\r\n params: AgGridTooltipCellRendererParams;\r\n tooltipText: string;\r\n cellText: string;\r\n\r\n agInit(params: AgGridTooltipCellRendererParams): void {\r\n this.params = params;\r\n this.tooltipText = params.getTooltipText(params);\r\n this.cellText = params.valueFormatted || params.value;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { DecimalPipe } from '@angular/common';\r\nimport {\r\n AgGridColumns,\r\n AgGridCurrencyCellEditor,\r\n AgGridDatepickerCellEditor, AgGridDropdownCellEditor,\r\n AgGridFilterParams, AgGridNumberCellEditor, AgGridTextCellEditor\r\n} from './index';\r\nimport { AgGridTooltipCellRendererComponent } from './CellRenderers/agGridTooltipCellRenderer.component';\r\nimport { CellEditorValidationResult } from './CellEditors/validator.interface';\r\nimport { WeissmanDateFormat } from '../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport {\r\n AgGridYesNoFloatingFilterComponent\r\n} from './FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport { ColDef } from 'ag-grid-community';\r\n\r\nexport interface DescriptorColumnDefinitions {\r\n [key: number]: (\r\n descriptor: Core.DescriptorInfoModel,\r\n getDescriptorValue: (model: Compliance.AssessorCommandCenterModel, descriptor: Core.DescriptorInfoModel) => any,\r\n pickList?: Core.DescriptorPicklistModel[]) => ColDef;\r\n}\r\n\r\n\r\nexport function DESCRIPTOR_COLUMN_DEFINITIONS(decimalPipe: DecimalPipe): DescriptorColumnDefinitions {\r\n return {\r\n [Core.DescriptorFieldTypes.Currency]: (descriptor, getDescriptorValue) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n colId: `d.${descriptor.descriptorId}`,\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridCurrencyCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => { return null; },\r\n validator: (value: number): CellEditorValidationResult => {\r\n const validation = getDescriptor().validation;\r\n if (validation) {\r\n const isValid = validation\r\n && (validation.minValue ? value >= validation.minValue : true)\r\n && (validation.maxValue ? value <= validation.maxValue : true);\r\n let message = 'Value must be ';\r\n message += (validation.minValue) && `> ${validation.minValue - 1}`;\r\n message += (validation.minValue && validation.maxValue) && ' and ';\r\n message += (validation.maxValue) && `< ${validation.maxValue + 1}`;\r\n return {isValid, validationMessage: message};\r\n } else {\r\n return {isValid: true, validationMessage: ''};\r\n }\r\n }\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n valueFormatter: (params) =>\r\n {\r\n if ([null, undefined].indexOf(params.value) !== -1) {\r\n return '';\r\n }\r\n\r\n let result: string;\r\n switch (descriptor.format) {\r\n case '(#,###)':\r\n result = decimalPipe.transform(params.value, '1.0-0');\r\n break;\r\n case '(#,###.00)':\r\n result = decimalPipe.transform(params.value, '1.2-2');\r\n break;\r\n case '(#,###.000)':\r\n result = decimalPipe.transform(params.value, '1.3-3');\r\n break;\r\n case '(0000)':\r\n default:\r\n result = decimalPipe.transform(params.value, '1.2-2');\r\n break;\r\n }\r\n\r\n return `$${ result}`;\r\n },\r\n cellClass: () => '',\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Date]: (descriptor, getDescriptorValue) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n colId: `d.${descriptor.descriptorId}`,\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.dateColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridDatepickerCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => { return null; },\r\n validator: (value: Date): CellEditorValidationResult => {\r\n const year = value.getFullYear();\r\n const validation = getDescriptor().validation;\r\n\r\n if (validation) {\r\n const isValid = validation\r\n && (validation.minValue ? year >= validation.minValue : true)\r\n && (validation.maxValue ? year <= validation.maxValue : true);\r\n let message = 'Year must be ';\r\n message += (validation.minValue) && `> ${validation.minValue - 1}`;\r\n message += (validation.minValue && validation.maxValue) && ' and ';\r\n message += (validation.maxValue) && `< ${validation.maxValue + 1}`;\r\n return {isValid, validationMessage: message};\r\n } else {\r\n return {isValid: true, validationMessage: ''};\r\n }\r\n }\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => WeissmanDateFormat(params.value, true),\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => '',\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Number]: (descriptor, getDescriptorValue) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n colId: `d.${descriptor.descriptorId}`,\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridNumberCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => { return null; },\r\n validator: (value: number): CellEditorValidationResult => {\r\n const validation = getDescriptor().validation;\r\n\r\n if (validation) {\r\n const isValid = validation\r\n && (validation.minValue ? value >= validation.minValue : true)\r\n && (validation.maxValue ? value <= validation.maxValue : true);\r\n let message = 'Value must be ';\r\n message += (validation.minValue) && `> ${validation.minValue - 1}`;\r\n message += (validation.minValue && validation.maxValue) && ' and ';\r\n message += (validation.maxValue) && `< ${validation.maxValue + 1}`;\r\n return {isValid, validationMessage: message};\r\n } else {\r\n return {isValid: true, validationMessage: ''};\r\n }\r\n }\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n valueFormatter: (params) =>\r\n {\r\n if ([null, undefined].indexOf(params.value) !== -1) {\r\n return '';\r\n }\r\n\r\n let result: string;\r\n switch (descriptor.format) {\r\n case '(#,###)':\r\n result = decimalPipe.transform(params.value, '1.0-0');\r\n break;\r\n case '(#,###.00)':\r\n result = decimalPipe.transform(params.value, '1.2-2');\r\n break;\r\n case '(#,###.000)':\r\n result = decimalPipe.transform(params.value, '1.3-3');\r\n break;\r\n case '(0000)':\r\n default:\r\n result = params.value;\r\n break;\r\n }\r\n\r\n return result;\r\n },\r\n cellClass: () => '',\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Picklist]: (descriptor, getDescriptorValue, picklist) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n colId: `d.${descriptor.descriptorId}`,\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.selectionColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => {\r\n return picklist.reduce((acc, x) => {\r\n if (x.groupId === getDescriptor().picklistGroupId) {\r\n acc.push({ name: x.name, value: x.name });\r\n }\r\n return acc;\r\n }, []);\r\n },\r\n cellFocusLost: () => { return null; }\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => '',\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Text]: (descriptor, getDescriptorValue) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n colId: `d.${descriptor.descriptorId}`,\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridTextCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => { return null; },\r\n validator: (value: string): CellEditorValidationResult => {\r\n const validation = getDescriptor().validation;\r\n\r\n if (validation) {\r\n const isValid = validation\r\n && (validation.maxLength ? value.length <= validation.maxLength : true);\r\n const message = `Max characters: ${validation.maxLength}`;\r\n return {isValid, validationMessage: message};\r\n } else {\r\n return {isValid: true, validationMessage: ''};\r\n }\r\n },\r\n maxLength: descriptor.validation && descriptor.validation.maxLength\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => '',\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.YesNo]: (descriptor, getDescriptorValue) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n colId: `d.${descriptor.descriptorId}`,\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => [{ name: 'Yes', value: true }, {name: 'No', value: false}],\r\n cellFocusLost: () => { return null; }\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterWithBlankOptionsParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.yesNoFilterWithBlankOptionsParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n valueFormatter: (params) => {\r\n if ([null, undefined].indexOf(params.value) !== -1) {\r\n return '';\r\n }\r\n\r\n if (params.value || params.value === false) {\r\n return (params.value) ? 'Yes' : 'No';\r\n } else {\r\n return '';\r\n }\r\n },\r\n cellClass: () => '',\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n };\r\n }\r\n };\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { AppealRecommendationGridRowInfoTreeItemModel } from './appealRecommendationGridRowInfoTreeItemModel';\r\nimport { AttachmentModalData } from '../../Attachment/attachment.modal.model';\r\n\r\nexport type ICellRendererParamsForFAppealRecommendationCommandCenterGridAction = ICellRendererParams;\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n`\r\n})\r\nexport class AppealRecommendationCommandCenterGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForFAppealRecommendationCommandCenterGridAction;\r\n item: AppealRecommendationGridRowInfoTreeItemModel;\r\n commentModalData: CommentModalData;\r\n attachmentModalData: AttachmentModalData;\r\n\r\n agInit(params: ICellRendererParamsForFAppealRecommendationCommandCenterGridAction): void {\r\n this.params = params;\r\n this.item = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!this.item) {\r\n return;\r\n }\r\n\r\n this.commentModalData = {\r\n entityID: this.item.parcelId || this.item.siteId,\r\n entityTypeID: this.item.parcelId ? Core.EntityTypes.Parcel : Core.EntityTypes.Site,\r\n entityName: this.item.entityName,\r\n parcelAcctNum: this.item.parcelId ? this.item.parcelAccountNumber : null,\r\n canEdit: this.item.canEdit,\r\n description: this.item.parcelId ? `Parcel: ${this.item.parcelAccountNumber}` : `Site: ${this.item.siteName}`,\r\n parcelID: null,\r\n year: (this.item.taxYear || new Date().getFullYear()).toString(),\r\n commentTypeID: Core.CommentTypes.AppealRecommendation,\r\n disableCommentTypeSelection: !this.item.parcelId,\r\n disableYearSelection: true\r\n } as CommentModalData;\r\n\r\n this.attachmentModalData = {\r\n entityType: this.item.parcelId ? 'Parcel' : 'Site', //todo: make this a constant generated typescript value\r\n entityName: this.item.entityName,\r\n year: this.item.taxYear,\r\n disableYears: true,\r\n singleYear: true,\r\n entityData: {\r\n typeId: this.item.parcelId ? Core.EntityTypes.Parcel : Core.EntityTypes.Site,\r\n id: this.item.parcelId || this.item.siteId,\r\n name: this.item.entityName\r\n }\r\n } as AttachmentModalData;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const APPEAL_RECOMMENDATION_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'appeal-recommendation.checkbox.disabled',\r\n tooltipText: 'Please click edit pencil to modify default settings or edit comment(s).'\r\n },\r\n {\r\n helpContentId: 'appeal-recommendation.checkbox.selections-exceed-printable-area-width',\r\n tooltipText: 'Selections exceed printable area width.'\r\n },\r\n {\r\n helpContentId: 'appeal-recommendation-template-specification.copy',\r\n tooltipText: 'Save a copy of this template.'\r\n },\r\n {\r\n helpContentId: 'appeal-recommendation-template-specification.no-template',\r\n tooltipText: 'Select a template.'\r\n },\r\n {\r\n helpContentId: 'appeal-recommendation-template-specification.edit-default',\r\n tooltipText: 'The built-in default template cannot be saved.'\r\n },\r\n {\r\n helpContentId: 'appeal-recommendation-template-specification.delete-default',\r\n tooltipText: 'The built-in default template cannot be deleted.'\r\n }\r\n];\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Site:{{getValue(sentInfo, 'siteName', 20)}},Parcel:{{getValue(sentInfo, 'parcelAccountNumber', 20)}},By:{{getUserName(sentInfo, 15)}},Sent:{{sentInfo.sentDate | date: 'MM/dd/yyyy'}}
\r\n
\r\n All parcels sent by this user on date indicated.\r\n
\r\n","import { Component, ViewEncapsulation } from '@angular/core';\r\nimport { HelpContentComponent, HelpService } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport interface AppealRecommendationTemplateLastSentHelpComponentParams{\r\n sentInfo: Core.AppealRecommendationEmailSentInfo[];\r\n totalParcelsCount: number;\r\n}\r\n\r\n@Component({\r\n selector: 'last-sent-tooltip',\r\n templateUrl: './appealRecommendationTemplateLastSentHelp.component.html',\r\n styleUrls: ['./appealRecommendationTemplate.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class AppealRecommendationTemplateLastSentHelpComponent implements HelpContentComponent {\r\n constructor(private readonly _helpService: HelpService) { }\r\n\r\n params: AppealRecommendationTemplateLastSentHelpComponentParams;\r\n sentInfos: Core.AppealRecommendationEmailSentInfo[];\r\n isSameDateSamePerson: boolean;\r\n\r\n async helpInit(params: AppealRecommendationTemplateLastSentHelpComponentParams): Promise {\r\n if (params) {\r\n this.sentInfos = params.sentInfo;\r\n }\r\n\r\n const uniqueInfo = new Set(this.sentInfos.map(x => `${x.userId}${x.sentDate.getDate()}`));\r\n this.isSameDateSamePerson = uniqueInfo.size === 1 && this.sentInfos.length === this.params.totalParcelsCount;\r\n\r\n this._helpService.refresh();\r\n\r\n }\r\n\r\n getValue(sentInfo: Core.AppealRecommendationEmailSentInfo, fieldName: string, maxLength: number): string {\r\n return this._trimValue(sentInfo[fieldName], maxLength);\r\n }\r\n\r\n getUserName(sentInfo: Core.AppealRecommendationEmailSentInfo, maxLength: number): string {\r\n return this._trimValue(`${sentInfo.userLastName} ${sentInfo.userFirstName}`, maxLength);\r\n }\r\n\r\n private _trimValue(value: string, maxLength: number): string {\r\n let result = value;\r\n\r\n if (result.length >= maxLength) {\r\n result = `${result.substring(0, maxLength) }...`;\r\n }\r\n\r\n return result;\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const APPEAL_RECOMMENDATION_TEMPLATE_DETAILS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'appeal-recommendation-template-details.template-exists',\r\n tooltipText: 'Template name already exists'\r\n }\r\n];\r\n"," 0\">\r\n\r\n
\r\n

Appeal Email Template

\r\n \r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n {{ visibility?.description }}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport {\r\n AppealRecommendationEmailTemplateListItemModel,\r\n VisibilityModel\r\n} from '../appealRecommendationTemplate.component';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AppealRecommendationRepository } from '../../appealRecommendation.repository';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { APPEAL_RECOMMENDATION_TEMPLATE_DETAILS_HELP } from './appealRecommendationTemplateDetails.component.help';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport interface AppealRecommendationTemplateDetailsParams{\r\n emailSubjectTemplate: string,\r\n emailBodyTemplate: string,\r\n options: Core.AppealRecommendationTemplateOptionsModel,\r\n taskIds: number[],\r\n existingTemplates: AppealRecommendationEmailTemplateListItemModel[],\r\n selectedTemplate?: AppealRecommendationEmailTemplateListItemModel;\r\n}\r\n\r\n@Component({\r\n selector: 'appeal-recommendation-template-details',\r\n templateUrl: './appealRecommendationTemplateDetails.component.html',\r\n})\r\nexport class AppealRecommendationTemplateDetailsComponent implements OnInit, IWeissmanModalComponent{\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _appealRecommendationRepository: AppealRecommendationRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _helpService: HelpService) {\r\n }\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n visibilities: VisibilityModel[] = [\r\n {\r\n name: 'Private',\r\n description: 'Visible only to you',\r\n isDefault: false,\r\n isShared: false\r\n },\r\n {\r\n name: 'Shared',\r\n description: 'Visible to everyone',\r\n isDefault: false,\r\n isShared: true\r\n }\r\n ];\r\n\r\n params: AppealRecommendationTemplateDetailsParams;\r\n result: Core.AppealRecommendationEmailTemplateModel;\r\n\r\n name: string;\r\n description: string;\r\n visibility: VisibilityModel = this.visibilities[0];\r\n hasEditSystemSearch: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(APPEAL_RECOMMENDATION_TEMPLATE_DETAILS_HELP);\r\n\r\n this.hasEditSystemSearch = this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT);\r\n\r\n if (this.params.selectedTemplate) {\r\n this.name = this.params.selectedTemplate.name;\r\n this.description = this.params.selectedTemplate.description;\r\n this.visibility = this.visibilities.find(x => x.isShared === this.params.selectedTemplate.visibilityItem.isShared);\r\n }\r\n }\r\n\r\n canSave(): boolean {\r\n return !!this.name && !!this.visibility && !this._hasDuplicateName();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgId = 'saving template';\r\n this.busyIndicatorMessageManager.add('Saving Template', busyMsgId);\r\n\r\n try {\r\n const saveTemplateModel: Core.AppealRecommendationEmailTemplateUpdateModel = {\r\n appealRecommendationEmailTemplateId: this.params.selectedTemplate ? this.params.selectedTemplate.appealRecommendationEmailTemplateId : 0,\r\n name: this.name,\r\n description: this.description,\r\n isShared: this.visibility.isShared,\r\n emailSubjectTemplate: this.params.emailSubjectTemplate,\r\n emailBodyTemplate: this.params.emailBodyTemplate,\r\n showPriorYear: this.params.options.showPriorYear,\r\n showYearBuilt: this.params.options.showYearBuilt,\r\n showAcquisitionInfo: this.params.options.showAcquisitionInfo,\r\n showAppealDeadlines: this.params.options.showAppealDeadlines,\r\n showAssessments: this.params.options.showAssessments,\r\n showMetrics: this.params.options.showMetrics,\r\n showInitialValue: this.params.options.showInitialValue,\r\n showTargetValue: this.params.options.showTargetValue,\r\n showLatestValue: this.params.options.showLatestValue,\r\n showTaxDetails: this.params.options.showTaxDetails,\r\n showSavings: this.params.options.showSavings,\r\n embedInEmail: this.params.options.embedInEmail,\r\n includeSiteComment: this.params.options.includeSiteComment,\r\n attachChart: this.params.options.attachChart,\r\n taskIds: this.params.taskIds\r\n };\r\n\r\n this.result = await lastValueFrom(this._appealRecommendationRepository.saveTemplate(saveTemplateModel));\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n\r\n this._bsModalRef.hide();\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n get saveHelpId(): string {\r\n return this._hasDuplicateName() ? 'appeal-recommendation-template-details.template-exists' : 'app.save';\r\n }\r\n\r\n private _hasDuplicateName() {\r\n return !!this.params.existingTemplates.find(x => x.name.toLowerCase() === (this.name || '').toLowerCase() &&\r\n x.isShared === this.visibility.isShared && (!this.params.selectedTemplate || x.appealRecommendationEmailTemplateId !== this.params.selectedTemplate.appealRecommendationEmailTemplateId));\r\n }\r\n}\r\n"," 0\">\r\n\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n {{ attachment.attachmentName }}\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
To:
\r\n
{{ appealRecommendationInfo.to.name }}
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
 
\r\n
{{ appealRecommendationInfo.cc?.name }}
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
{{ appealRecommendationInfo.emailSubject }}\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Last sent by {{ lastSent }}\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n \r\n\r\n\r\n\r\n
\r\n
\r\n Description:\r\n
\r\n {{ selectedTemplate.description }}\r\n
\r\n
\r\n
\r\n Visibility:\r\n
\r\n {{ selectedTemplate.visibilityItem.name }}\r\n {{ selectedTemplate.visibilityItem.description }}\r\n
\r\n
\r\n
\r\n Updated By:\r\n
\r\n {{ selectedTemplate.changedByName }}\r\n
\r\n
\r\n
\r\n
\r\n","import {\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n OnInit,\r\n SecurityContext,\r\n ViewChild,\r\n ViewEncapsulation\r\n} from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { QuillModules } from 'ngx-quill';\r\nimport { ContentChange } from 'ngx-quill/lib/quill-editor.component';\r\nimport { BusyIndicatorMessageManager } from '../../Busy-Indicator';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { AppealRecommendationRepository } from '../appealRecommendation.repository';\r\nimport { lastValueFrom, Observable, of, Subscriber } from 'rxjs';\r\nimport { DomSanitizer, SafeHtml } from '@angular/platform-browser';\r\nimport { HelpContentComponentConfig, HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { APPEAL_RECOMMENDATION_HELP } from './appealRecommendationTemplate.component.help';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { mergeMap } from 'rxjs/operators';\r\nimport { DownloadFileService } from '../../Common/Download/downloadFileService';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { CommentsModalService } from '../../Comments/commentsModal.service';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { CommentTypeNames, EntityTypeIds } from '../../constants.new';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { TimerService } from '../../UI-Lib/Utilities';\r\nimport {\r\n AppealRecommendationTemplateLastSentHelpComponent,\r\n AppealRecommendationTemplateLastSentHelpComponentParams\r\n} from './appealRecommendationTemplateLastSentHelp.component';\r\nimport { AttachmentModalData } from '../../Attachment/attachment.modal.model';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { AttachmentModalComponent } from '../../Attachment/Modal/attachmentModal.component';\r\nimport { CommentDateTimeFormat } from '../../UI-Lib/Pipes';\r\nimport { UserSettingsService } from '../../Account/userSettings.service';\r\nimport {\r\n AppealRecommendationTemplateDetailsComponent,\r\n AppealRecommendationTemplateDetailsParams,\r\n} from './Appeal-Recommendation-Template-Details/appealRecommendationTemplateDetails.component';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport AttachmentTypes = Core.AttachmentTypes;\r\nimport AttachmentCategories = Core.AttachmentCategories;\r\n\r\ndeclare const $: any;\r\n\r\nenum PanelView {\r\n Options,\r\n Attachments\r\n}\r\n\r\nenum AnalyticsEvent {\r\n ClickShowAcquisitionInfo,\r\n ClickShowYearBuilt,\r\n ClickShowAppealDeadlines,\r\n ClickShowAssessments,\r\n ClickShowMetrics,\r\n ClickShowInitialValue,\r\n ClickShowTargetValue,\r\n ClickShowLatestValue,\r\n ClickShowTaxDetails,\r\n ClickShowSavings,\r\n ClickEmbedChart,\r\n ClickAttachChart\r\n}\r\n\r\nexport class TemplateFieldDTO {\r\n name: string;\r\n validInSubject: boolean;\r\n}\r\n\r\nexport interface VisibilityModel {\r\n name: string;\r\n isDefault: boolean;\r\n isShared: boolean;\r\n description: string;\r\n}\r\n\r\nexport interface AppealRecommendationEmailTemplateListItemModel extends Core.AppealRecommendationEmailTemplateModel {\r\n canEdit: boolean;\r\n visibilityItem: VisibilityModel;\r\n}\r\n\r\n@Component({\r\n templateUrl: './appealRecommendationTemplate.component.html',\r\n selector: 'appeal-recommendation-template',\r\n styleUrls: ['./appealRecommendationTemplate.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class AppealRecommendationTemplateComponent implements OnInit {\r\n\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _appealRecommendationRepository: AppealRecommendationRepository,\r\n private readonly _sanitizer: DomSanitizer,\r\n private readonly _helpService: HelpService,\r\n private readonly _downloadFileService: DownloadFileService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _commentsModalService: CommentsModalService,\r\n private readonly _toastsManager: ToastrService,\r\n private readonly _timer: TimerService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _commentDateTimePipe: CommentDateTimeFormat,\r\n private readonly _userSettingsService: UserSettingsService,\r\n private readonly _cdRef: ChangeDetectorRef,\r\n private readonly _featureFlagService: FeatureFlagsService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _messageModalService: MessageModalService,\r\n ) {\r\n }\r\n\r\n @ViewChild('optionsPanel1') set optionsPanel1(p: ElementRef) {\r\n this._optionsPanel1 = p;\r\n this._setConsistentPanelWidth();\r\n }\r\n @ViewChild('optionsPanel2') set optionsPanel2(p: ElementRef) {\r\n this._optionsPanel2 = p;\r\n this._setConsistentPanelWidth();\r\n }\r\n\r\n panelSize = null;\r\n taskIds: number[];\r\n instanceId: number;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n editorInstance: QuillModules;\r\n emailTemplateSubjectFields: TemplateFieldDTO[];\r\n emailTemplateBodyFields: TemplateFieldDTO[];\r\n analyticsEvent = AnalyticsEvent;\r\n editing: boolean = false;\r\n initialized: boolean = false;\r\n selectedView: PanelView = PanelView.Options;\r\n sites: Core.AppealRecommendationSiteInfoModel[];\r\n appealRecommendationInfo: Core.AppealRecommendationTemplateModel;\r\n emailBody: SafeHtml;\r\n toFilter: string = '';\r\n ccFilter: string ='';\r\n lastSent: string;\r\n attachments: Core.AppealRecommendationAttachmentModel[] = [];\r\n canIncludePDFAsAttachment: boolean = false;\r\n savedSettings: Core.AppealRecommendationTemplateOptionsModel = {\r\n includeSiteComment: true,\r\n showPriorYear: true,\r\n showYearBuilt: false,\r\n showAcquisitionInfo: true,\r\n showAppealDeadlines: true,\r\n showAssessments: Core.PsrShowAssessmentsEnum.FMV,\r\n showMetrics: Core.PsrShowMetrics.MostApplicableBasedOnSiteClass,\r\n showInitialValue: Core.PsrShowValueEnum.YesNoMetrics,\r\n showTargetValue: Core.PsrShowValueEnum.YesNoMetrics,\r\n showLatestValue: Core.PsrShowLatestValueEnum.YesInclMetricsAndYOYChange,\r\n showTaxDetails: Core.PsrShowTaxDetails.None,\r\n showSavings: Core.PsrShowSavings.No,\r\n embedInEmail: true,\r\n attachChart: Core.AppealRecommendationTemplateAttachChartOptionEnum.No\r\n };\r\n sentInfoTooltip: HelpContentComponentConfig = {\r\n component: AppealRecommendationTemplateLastSentHelpComponent,\r\n componentParams: {\r\n sentInfo: null,\r\n totalParcelsCount: -1\r\n }\r\n };\r\n showAssessmentOptions: Compliance.NameValuePair[] = [\r\n { name: 'FMV', value: Core.PsrShowAssessmentsEnum.FMV },\r\n { name: 'Alternate', value: Core.PsrShowAssessmentsEnum.Alternate },\r\n { name: 'FMV and Alternate', value: Core.PsrShowAssessmentsEnum.FMVAndAlternate }];\r\n showMetricOptions: Compliance.NameValuePair[] = [\r\n { name: 'None', value: Core.PsrShowMetrics.None },\r\n { name: 'Most applicable based on site class', value: Core.PsrShowMetrics.MostApplicableBasedOnSiteClass },\r\n { name: 'All present', value: Core.PsrShowMetrics.AllPresent },\r\n ];\r\n showInitialValueOptions: Compliance.NameValuePair[] = [\r\n { name: 'No', value: Core.PsrShowValueEnum.No },\r\n { name: 'Yes (Incl. Metrics)', value: Core.PsrShowValueEnum.YesInclMetrics },\r\n { name: 'Yes (No Metrics)', value: Core.PsrShowValueEnum.YesNoMetrics },\r\n ];\r\n showTargetValueOptions: Compliance.NameValuePair[] = [\r\n { name: 'No', value: Core.PsrShowValueEnum.No },\r\n { name: 'Yes (Incl. Metrics)', value: Core.PsrShowValueEnum.YesInclMetrics },\r\n { name: 'Yes (No Metrics)', value: Core.PsrShowValueEnum.YesNoMetrics },\r\n ];\r\n showLatestValueOptions: Compliance.NameValuePair[] = [\r\n { name: 'Yes (Incl. Metrics and YOY % Change)', value: Core.PsrShowLatestValueEnum.YesInclMetricsAndYOYChange },\r\n { name: 'Yes (Incl. Metrics)', value: Core.PsrShowLatestValueEnum.YesInclMetrics },\r\n { name: 'Yes (Incl. YOY % Change )', value: Core.PsrShowLatestValueEnum.YesInclYOYChange },\r\n { name: 'Yes (No Metrics or YOY % Change)', value: Core.PsrShowLatestValueEnum.YesNoMetricsOrYOYChange },\r\n ];\r\n showTaxDetailsOptions: Compliance.NameValuePair[] = [\r\n { name: 'None', value: Core.PsrShowTaxDetails.None },\r\n { name: 'Latest Taxes (Incl. Metrics)', value: Core.PsrShowTaxDetails.LatestTaxesInclMetrics },\r\n { name: 'Latest Taxes (No Metrics)', value: Core.PsrShowTaxDetails.LatestTaxesNoMetrics },\r\n { name: 'All Taxes (Incl. Metrics)', value: Core.PsrShowTaxDetails.AllTaxesInclMetrics },\r\n { name: 'All Taxes (No Metrics)', value: Core.PsrShowTaxDetails.AllTaxesNoMetrics },\r\n ];\r\n showSavingOptions: Compliance.NameValuePair[] = [\r\n { name: 'Received and Projected', value: Core.PsrShowSavings.ReceivedAndProjected },\r\n { name: 'Received Only', value: Core.PsrShowSavings.ReceivedOnly },\r\n { name: 'Projected Only', value: Core.PsrShowSavings.ProjectedOnly },\r\n { name: 'No', value: Core.PsrShowSavings.No },\r\n ];\r\n embedChartOptions: Compliance.NameValuePair[] = [\r\n { name: 'Yes', value: true },\r\n { name: 'No', value: false }\r\n ];\r\n attachChartOptions: any[] = [\r\n { name: 'No', value: Core.AppealRecommendationTemplateAttachChartOptionEnum.No, isDisabled: false, title: '' },\r\n { name: 'PDF', value: Core.AppealRecommendationTemplateAttachChartOptionEnum.PDF, isDisabled: false, title: '' },\r\n { name: 'Excel', value: Core.AppealRecommendationTemplateAttachChartOptionEnum.Excel, isDisabled: false, title: '' }\r\n ];\r\n selectedTemplate: AppealRecommendationEmailTemplateListItemModel;\r\n templates: AppealRecommendationEmailTemplateListItemModel[];\r\n enableAppealRecommendationEmailTemplate: boolean = false;\r\n\r\n to$: Observable = new Observable((observer: Subscriber) => observer.next(this.toFilter))\r\n .pipe(mergeMap((token) => this._filterRecipients(token)));\r\n\r\n cc$: Observable = new Observable((observer: Subscriber) => observer.next(this.ccFilter))\r\n .pipe(mergeMap((token) => this._filterRecipients(token)));\r\n\r\n protected readonly PanelView = PanelView;\r\n private _optionsPanel1: ElementRef;\r\n private _optionsPanel2: ElementRef;\r\n private _availableRecipients: Core.AppealRecipientModel[];\r\n private _appealRecommendationInfo: Core.AppealRecommendationTemplateModel;\r\n private _savedSettings: Core.AppealRecommendationTemplateOptionsModel;\r\n private _initialAppealRecommendationInfo: Core.AppealRecommendationTemplateModel;\r\n private _settingName: string = 'Selected-Options';\r\n private _savedUserSettings: any;\r\n private _attachments: Core.AppealRecommendationAttachmentModel[] = [];\r\n private _siteDivisorDescriptors: System.Collections.Generic.KeyValuePair[] = [];\r\n private _selectedTemplateId: number;\r\n private _hasEditSystemSearchPermission: boolean;\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(APPEAL_RECOMMENDATION_HELP);\r\n this.enableAppealRecommendationEmailTemplate = this._featureFlagService.featureFlags.enableAppealRecommendationEmailTemplate;\r\n this._hasEditSystemSearchPermission = this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT);\r\n\r\n try {\r\n if (this.enableAppealRecommendationEmailTemplate) {\r\n const templates = await lastValueFrom(this._appealRecommendationRepository.getTemplatesAsync(this.taskIds));\r\n\r\n this.templates = templates\r\n .map(x => this._convertToListItem(x));\r\n this._sortSavedTemplates();\r\n }\r\n\r\n await this._loadSettings();\r\n\r\n const model: Core.AppealRecommendationTemplateRefreshModel = {\r\n taskIds: this.taskIds,\r\n emailSubjectTemplate: null,\r\n emailBodyTemplate: null,\r\n showPriorYear: this.savedSettings.showPriorYear,\r\n embedInEmail: this.savedSettings.embedInEmail,\r\n includeSiteComment: this.savedSettings.includeSiteComment,\r\n recipientFirstName: '',\r\n showAssessments: this.savedSettings.showAssessments,\r\n showMetrics: this.savedSettings.showMetrics,\r\n showInitialValue: this.savedSettings.showInitialValue,\r\n showTargetValue: this.savedSettings.showTargetValue,\r\n showLatestValue: this.savedSettings.showLatestValue,\r\n showTaxDetails: this.savedSettings.showTaxDetails,\r\n showSavings: this.savedSettings.showSavings,\r\n showYearBuilt: this.savedSettings.showYearBuilt,\r\n showAcquisitionInfo: this.savedSettings.showAcquisitionInfo,\r\n showAppealDeadlines: this.savedSettings.showAppealDeadlines,\r\n attachChart: this.savedSettings.attachChart\r\n };\r\n\r\n if (this.enableAppealRecommendationEmailTemplate) {\r\n model.emailSubjectTemplate = this.selectedTemplate.emailSubjectTemplate;\r\n model.emailBodyTemplate = this.selectedTemplate.emailBodyTemplate;\r\n }\r\n\r\n const requests = await Promise.all([\r\n lastValueFrom(this._appealRecommendationRepository.getTemplate(model)),\r\n lastValueFrom(this._appealRecommendationRepository.getFields()),\r\n lastValueFrom(this._appealRecommendationRepository.getAvailableRecipients(this.taskIds))\r\n ]);\r\n\r\n this.appealRecommendationInfo = requests[0];\r\n this._initialAppealRecommendationInfo = {... this.appealRecommendationInfo};\r\n this._siteDivisorDescriptors = this.appealRecommendationInfo.siteDivisors;\r\n\r\n let fields = requests[1];\r\n\r\n if (this.appealRecommendationInfo.hasMultipleSites) {\r\n fields = fields.filter(x => x.name !== 'CompanyName' && x.name !== 'SiteName');\r\n }\r\n\r\n if (this.appealRecommendationInfo.hasMultipleAssessors) {\r\n fields = fields.filter(x => x.name !== 'Jurisdiction' && x.name !== 'AppealDeadline');\r\n }\r\n\r\n this.emailTemplateSubjectFields = fields.filter(x => x.validInSubject);\r\n this.emailTemplateBodyFields = fields;\r\n\r\n this._availableRecipients = requests[2];\r\n\r\n this.sites = this.appealRecommendationInfo.sites\r\n .sort((x, y) => x.siteName.localeCompare(y.siteName));\r\n\r\n this.emailBody = this._sanitizer.sanitize(SecurityContext.HTML, this.appealRecommendationInfo.emailBody);\r\n\r\n this.toFilter = this.appealRecommendationInfo.to.name;\r\n\r\n if (this.appealRecommendationInfo.sentInfo.length !== 0) {\r\n const lastSentInfo = this.appealRecommendationInfo.sentInfo\r\n .sort((a, b) => b.sentDate.getTime() - a.sentDate.getTime())\r\n .at(0);\r\n\r\n if (lastSentInfo) {\r\n this.lastSent = `${lastSentInfo.userLastName}, ${lastSentInfo.userFirstName} ${this._commentDateTimePipe.transform(lastSentInfo.sentDate)}`;\r\n }\r\n this.sentInfoTooltip.componentParams.sentInfo = this.appealRecommendationInfo.sentInfo;\r\n this.sentInfoTooltip.componentParams.totalParcelsCount = this.appealRecommendationInfo.parcelsCount;\r\n }\r\n\r\n this.settingChanged();\r\n } finally {\r\n this.initialized = true;\r\n }\r\n }\r\n\r\n async close(): Promise {\r\n if (!this.appealRecommendationInfo) {\r\n this._bsModalRef.hide();\r\n return;\r\n }\r\n let hasNotSavedChanges: boolean = JSON.stringify(this._initialAppealRecommendationInfo.emailSubjectTemplate) !== JSON.stringify(this.appealRecommendationInfo.emailSubjectTemplate) ||\r\n JSON.stringify(this._initialAppealRecommendationInfo.emailBodyTemplate) !== JSON.stringify(this.appealRecommendationInfo.emailBodyTemplate);\r\n\r\n if (!hasNotSavedChanges && this.enableAppealRecommendationEmailTemplate) {\r\n hasNotSavedChanges = this.savedSettings.showPriorYear !== this.selectedTemplate.showPriorYear ||\r\n this.savedSettings.showYearBuilt !== this.selectedTemplate.showYearBuilt ||\r\n this.savedSettings.showAcquisitionInfo !== this.selectedTemplate.showAcquisitionInfo ||\r\n this.savedSettings.showAppealDeadlines !== this.selectedTemplate.showAppealDeadlines ||\r\n this.savedSettings.showAssessments !== this.selectedTemplate.showAssessments ||\r\n this.savedSettings.showMetrics !== this.selectedTemplate.showMetrics ||\r\n this.savedSettings.showInitialValue !== this.selectedTemplate.showInitialValue ||\r\n this.savedSettings.showTargetValue !== this.selectedTemplate.showTargetValue ||\r\n this.savedSettings.showLatestValue !== this.selectedTemplate.showLatestValue ||\r\n this.savedSettings.showTaxDetails !== this.selectedTemplate.showTaxDetails ||\r\n this.savedSettings.showSavings !== this.selectedTemplate.showSavings ||\r\n this.savedSettings.attachChart !== this.selectedTemplate.attachChart ||\r\n this.savedSettings.embedInEmail !== this.selectedTemplate.embedInEmail;\r\n }\r\n\r\n if (hasNotSavedChanges) {\r\n if ((await this._messageBoxService.open({\r\n message: 'Changes have not been saved to a template and will be lost. Are you sure you would like to close before saving to a template, downloading or sending?',\r\n buttons: MessageBoxButtons.YesNo\r\n })) === MessageBoxResult.Yes) {\r\n this._bsModalRef.hide();\r\n }\r\n } else {\r\n this._bsModalRef.hide();\r\n }\r\n }\r\n\r\n async refresh(): Promise {\r\n const busyMsgId = 'refreshing';\r\n this.busyIndicatorMessageManager.add('Refreshing', busyMsgId);\r\n\r\n try {\r\n const model: Core.AppealRecommendationTemplateRefreshModel = {\r\n taskIds: this.taskIds,\r\n emailSubjectTemplate: this.appealRecommendationInfo.emailSubjectTemplate,\r\n emailBodyTemplate: this.appealRecommendationInfo.emailBodyTemplate,\r\n showPriorYear: this.savedSettings.showPriorYear,\r\n embedInEmail: this.savedSettings.embedInEmail,\r\n includeSiteComment: this.savedSettings.includeSiteComment,\r\n recipientFirstName: this.appealRecommendationInfo.to.name.split(' ')[0],\r\n showAssessments: this.savedSettings.showAssessments,\r\n showMetrics: this.savedSettings.showMetrics,\r\n showInitialValue: this.savedSettings.showInitialValue,\r\n showTargetValue: this.savedSettings.showTargetValue,\r\n showLatestValue: this.savedSettings.showLatestValue,\r\n showTaxDetails: this.savedSettings.showTaxDetails,\r\n showSavings: this.savedSettings.showSavings,\r\n showYearBuilt: this.savedSettings.showYearBuilt,\r\n showAcquisitionInfo: this.savedSettings.showAcquisitionInfo,\r\n showAppealDeadlines: this.savedSettings.showAppealDeadlines,\r\n attachChart: this.savedSettings.attachChart\r\n };\r\n\r\n const result = await lastValueFrom(this._appealRecommendationRepository.refresh(model));\r\n\r\n this.appealRecommendationInfo.emailSubject = result.emailSubject;\r\n this.appealRecommendationInfo.emailBody = result.emailBody;\r\n this.emailBody = this._sanitizer.sanitize(SecurityContext.HTML, this.appealRecommendationInfo.emailBody);\r\n this._siteDivisorDescriptors = result.siteDivisors;\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n edit() {\r\n this._appealRecommendationInfo = {... this.appealRecommendationInfo};\r\n this._savedSettings = {... this.savedSettings};\r\n this._attachments = this.attachments.slice(0);\r\n this.editing = true;\r\n this._productAnalyticsService.logEvent('edit-modal');\r\n\r\n if (this.enableAppealRecommendationEmailTemplate) {\r\n this._selectedTemplateId = this.selectedTemplate.appealRecommendationEmailTemplateId;\r\n }\r\n }\r\n\r\n changeTab(tab: PanelView): void {\r\n this.selectedView = tab;\r\n this._productAnalyticsService.logEvent('click-settings-panel-tab', { settingsTab: tab === PanelView.Options ? 'Options' : 'Attachments' });\r\n }\r\n\r\n addBindingCreated(quillInstance: QuillModules): void {\r\n this.editorInstance = quillInstance;\r\n }\r\n\r\n insertFieldInSubject(field: TemplateFieldDTO): void {\r\n const templateSubject = $('#template-subject');\r\n const cursorPosStart = templateSubject.prop('selectionStart');\r\n const cursorPosEnd = templateSubject.prop('selectionEnd');\r\n const v = templateSubject.val();\r\n const textBefore = v.substring(0, cursorPosStart);\r\n const textAfter = v.substring(cursorPosEnd, v.length);\r\n const fieldName = `{{ ${ field.name } }}`;\r\n\r\n templateSubject.val(textBefore + fieldName + textAfter);\r\n this.appealRecommendationInfo.emailSubjectTemplate = templateSubject.val();\r\n\r\n templateSubject.focus();\r\n\r\n // Analytics\r\n this._productAnalyticsService.logEvent('edit-subject-line', { subjectField: field.name });\r\n }\r\n\r\n insertFieldInBody(field: TemplateFieldDTO): void {\r\n const cursorPosition: number = this.editorInstance.getSelection(true).index;\r\n const fieldName: string = `{{ ${ field.name } }}`;\r\n\r\n this.editorInstance.insertText(cursorPosition, fieldName);\r\n this._timer.setTimeout(() => this.editorInstance.setSelection(cursorPosition + fieldName.length), 1);\r\n\r\n // Analytics\r\n this._productAnalyticsService.logEvent('insert-field-body', { bodyField: field.name });\r\n }\r\n\r\n // Inserting field does not trigger binding change event, so we need to manually update the model\r\n contentChange(change: ContentChange): void {\r\n this.appealRecommendationInfo.emailBodyTemplate = change.html;\r\n }\r\n\r\n bodyBlur(): void {\r\n if (this._initialAppealRecommendationInfo.emailBodyTemplate !== this.appealRecommendationInfo.emailBodyTemplate) {\r\n this._productAnalyticsService.logEvent('insert-text-body');\r\n }\r\n }\r\n\r\n async downloadEmail(): Promise {\r\n this._productAnalyticsService.logEvent('download-email');\r\n\r\n const busyMsgId = 'downloading';\r\n this.busyIndicatorMessageManager.add('Generating the .eml file', busyMsgId);\r\n\r\n try {\r\n const model: Core.AppealRecommendationEmailModel = {\r\n emailSubject: this.appealRecommendationInfo.emailSubject,\r\n emailBody: this.appealRecommendationInfo.emailBody,\r\n toId: this.appealRecommendationInfo.to.value,\r\n ccId: this.appealRecommendationInfo.cc ? this.appealRecommendationInfo.cc.value : null,\r\n taskIds: this.taskIds,\r\n options: this.savedSettings,\r\n attachments: this.attachments\r\n };\r\n\r\n const response = await lastValueFrom(this._appealRecommendationRepository.download(model));\r\n await this._downloadFileService.downloadResponse(response);\r\n\r\n this._initialAppealRecommendationInfo = this.appealRecommendationInfo;\r\n\r\n await this._saveSettings();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n async sendEmail(): Promise {\r\n this._productAnalyticsService.logEvent('send-email');\r\n\r\n let recipients = this.appealRecommendationInfo.to.name;\r\n\r\n if (this.appealRecommendationInfo.cc) {\r\n recipients += ` and ${this.appealRecommendationInfo.cc.name}`;\r\n }\r\n\r\n if ((await this._messageBoxService.open({\r\n message: `An appeal recommendation email will be sent to ${recipients}. Are you sure?`,\r\n buttons: MessageBoxButtons.YesNo\r\n })) === MessageBoxResult.Yes) {\r\n const busyMsgId = 'sending';\r\n this.busyIndicatorMessageManager.add('Sending email', busyMsgId);\r\n\r\n try {\r\n const model: Core.AppealRecommendationEmailModel = {\r\n emailSubject: this.appealRecommendationInfo.emailSubject,\r\n emailBody: this.appealRecommendationInfo.emailBody,\r\n toId: this.appealRecommendationInfo.to.value,\r\n ccId: this.appealRecommendationInfo.cc ? this.appealRecommendationInfo.cc.value : null,\r\n taskIds: this.taskIds,\r\n options: this.savedSettings,\r\n attachments: this.attachments\r\n };\r\n\r\n await this._appealRecommendationRepository.send(model);\r\n\r\n await this._saveSettings();\r\n\r\n this._bsModalRef.hide();\r\n this._toastsManager.success('Your email has been sent');\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n }\r\n\r\n getCheckboxHelpContentId(): string {\r\n return this.editing\r\n ? null\r\n : 'appeal-recommendation.checkbox.disabled';\r\n }\r\n\r\n onToBlur(): void {\r\n this._selectTo(this.toFilter);\r\n }\r\n\r\n onToSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const userInfo = match.item as Core.AppealRecipientModel;\r\n this.toFilter = userInfo.name;\r\n this.appealRecommendationInfo.to = {\r\n name: userInfo.name,\r\n value: userInfo.contactId\r\n };\r\n\r\n // Analytics\r\n this._productAnalyticsService.logEvent('edit-recipient-one', { recipientRoleOne: userInfo.role });\r\n }\r\n }\r\n\r\n onCCBlur(): void {\r\n this._selectCC(this.ccFilter);\r\n }\r\n\r\n onCCSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const userInfo = match.item as Core.AppealRecipientModel;\r\n this.ccFilter = userInfo.name;\r\n this.appealRecommendationInfo.cc = {\r\n name: userInfo.name,\r\n value: userInfo.contactId\r\n };\r\n\r\n // Analytics\r\n this._productAnalyticsService.logEvent('edit-recipient-two', { recipientRoleTwo: userInfo.role });\r\n }\r\n }\r\n\r\n async save(refreshTemplate: boolean = true): Promise {\r\n await this.refresh();\r\n this.editing = false;\r\n this._productAnalyticsService.logEvent('save-changes');\r\n }\r\n\r\n cancel(): void {\r\n this.appealRecommendationInfo = this._appealRecommendationInfo;\r\n this.savedSettings = this._savedSettings;\r\n\r\n if (this.enableAppealRecommendationEmailTemplate) {\r\n this.selectedTemplate = this.templates.find(x => x.appealRecommendationEmailTemplateId === this._selectedTemplateId);\r\n if (!this.selectedTemplate) {\r\n this.selectedTemplate = this.templates[0];\r\n }\r\n }\r\n\r\n this.toFilter = this.appealRecommendationInfo.to.name;\r\n this.ccFilter = null;\r\n this.editing = false;\r\n this.attachments = this._attachments;\r\n this._productAnalyticsService.logEvent('cancel-changes');\r\n }\r\n\r\n async commentSiteChanged(siteId: number): Promise {\r\n this._productAnalyticsService.logEvent('edit-site-comment');\r\n const modalData: CommentModalData = {\r\n canEdit: true,\r\n commentTypeID: CommentTypeNames['Appeal Recommendation'],\r\n entityTypeID: EntityTypeIds.SITE,\r\n entityID: siteId,\r\n description: `Site: ${this.sites.find(x => x.siteId === siteId).siteName}`,\r\n year: this.appealRecommendationInfo.taxYear.toString(),\r\n disableYearSelection: true,\r\n disableCommentTypeSelection: true\r\n };\r\n\r\n await this._commentsModalService.openCommentModal(modalData);\r\n }\r\n\r\n async attachmentSiteChanged(siteId: number): Promise {\r\n this._productAnalyticsService.logEvent('click-include-site-attachments');\r\n\r\n const siteName = this.sites.find(x => x.siteId === siteId).siteName;\r\n\r\n const existingAttachment = this.attachments.find(x => x.siteId === siteId);\r\n\r\n const modalData: AttachmentModalData = {\r\n entityType: 'Site',\r\n parentId: null,\r\n parentType: null,\r\n entityName: siteName,\r\n entityDescription: null,\r\n belowParcelEntity: null,\r\n entityData: {\r\n typeId: EntityTypeIds.SITE,\r\n id: siteId,\r\n name: siteName\r\n },\r\n year: this.appealRecommendationInfo.taxYear,\r\n disableYears: true,\r\n singleYear: true,\r\n readOnly: false,\r\n startOnPhotos: false,\r\n disableCategories: true,\r\n attachmentCategoryId: AttachmentCategories.AppealDocs,\r\n attachmentTypeId: AttachmentTypes.Recommendation,\r\n showEmailAttachmentButton: true,\r\n selectedAttachmentId: existingAttachment && existingAttachment.attachmentId\r\n };\r\n\r\n const result = await this._modalService.showAsync(AttachmentModalComponent, modalData, 'modal-xl modal-no-max-width');\r\n\r\n if (result.selectedAttachmentId !== (existingAttachment && existingAttachment.attachmentId)) {\r\n const attachmentName = `${siteName}_${result.selectedAttachmentFileName}`;\r\n\r\n if (existingAttachment) {\r\n existingAttachment.attachmentId = result.selectedAttachmentId;\r\n existingAttachment.attachmentName = attachmentName;\r\n } else {\r\n this.attachments.push({\r\n siteId: siteId,\r\n attachmentId: result.selectedAttachmentId,\r\n attachmentName: attachmentName\r\n });\r\n\r\n this.attachments.sort((x, y) => x.attachmentName.localeCompare(y.attachmentName));\r\n }\r\n }\r\n }\r\n\r\n get canSave(): boolean {\r\n return !!this.appealRecommendationInfo.to &&\r\n (this.appealRecommendationInfo.emailSubjectTemplate || '').trim().length !== 0;\r\n }\r\n\r\n emitAnalyticsEvent(eventName: string, eventProperties: any = null): void {\r\n this._productAnalyticsService.logEvent(eventName, eventProperties);\r\n }\r\n\r\n removeAttachment(attachment: Core.AppealRecommendationAttachmentModel) {\r\n const index = this.attachments.indexOf(attachment);\r\n this.attachments.splice(index, 1);\r\n this._productAnalyticsService.logEvent('click-remove-site-attachments');\r\n }\r\n\r\n getCanIncludeAsAttachmentHelpContentId(): string {\r\n return this.canIncludePDFAsAttachment\r\n ? this.getCheckboxHelpContentId()\r\n : 'appeal-recommendation.checkbox.selections-exceed-printable-area-width';\r\n }\r\n\r\n settingChanged(analyticsEvent?: AnalyticsEvent): void {\r\n this._checkIfExceedsPrintableArea();\r\n\r\n if (analyticsEvent !== undefined) {\r\n switch (analyticsEvent) {\r\n case AnalyticsEvent.ClickShowAcquisitionInfo:\r\n this._productAnalyticsService.logEvent('click-show-acquisition-info', { showAcquisitionInfo: this.savedSettings.showAcquisitionInfo });\r\n break;\r\n case AnalyticsEvent.ClickShowYearBuilt:\r\n this._productAnalyticsService.logEvent('click-show-year-built', { showYearBuilt: this.savedSettings.showYearBuilt });\r\n break;\r\n case AnalyticsEvent.ClickShowAppealDeadlines:\r\n this._productAnalyticsService.logEvent('click-show-appeal-deadlines', { showAppealDeadlines: this.savedSettings.showAppealDeadlines });\r\n break;\r\n case AnalyticsEvent.ClickShowAssessments:\r\n this._productAnalyticsService.logEvent('click-show-assessments', {\r\n assessmentOptions: this.showAssessmentOptions.find(x => x.value === this.savedSettings.showAssessments)?.name\r\n });\r\n break;\r\n case AnalyticsEvent.ClickShowMetrics:\r\n this._productAnalyticsService.logEvent('click-show-metrics', {\r\n metricsOptions: this.showMetricOptions.find(x => x.value === this.savedSettings.showMetrics)?.name\r\n });\r\n break;\r\n case AnalyticsEvent.ClickShowInitialValue:\r\n this._productAnalyticsService.logEvent('click-show-initial-value', {\r\n initialValueOptions: this.showInitialValueOptions.find(x => x.value === this.savedSettings.showInitialValue)?.name\r\n });\r\n break;\r\n case AnalyticsEvent.ClickShowTargetValue:\r\n this._productAnalyticsService.logEvent('click-show-target-value', {\r\n targetValueOptions: this.showTargetValueOptions.find(x => x.value === this.savedSettings.showTargetValue)?.name\r\n });\r\n break;\r\n case AnalyticsEvent.ClickShowLatestValue:\r\n this._productAnalyticsService.logEvent('click-show-latest-value', {\r\n latestValueOptions: this.showLatestValueOptions.find(x => x.value === this.savedSettings.showLatestValue)?.name\r\n });\r\n break;\r\n case AnalyticsEvent.ClickShowTaxDetails:\r\n this._productAnalyticsService.logEvent('click-show-tax-details', {\r\n taxDetailsOptions: this.showTaxDetailsOptions.find(x => x.value === this.savedSettings.showTaxDetails)?.name\r\n });\r\n break;\r\n case AnalyticsEvent.ClickShowSavings:\r\n this._productAnalyticsService.logEvent('click-show-savings', {\r\n savingsOptions: this.showSavingOptions.find(x => x.value === this.savedSettings.showSavings)?.name\r\n });\r\n break;\r\n case AnalyticsEvent.ClickEmbedChart:\r\n this._productAnalyticsService.logEvent('embed-in-email', {\r\n embedInEmail: this.savedSettings.embedInEmail\r\n });\r\n break;\r\n case AnalyticsEvent.ClickAttachChart:\r\n this._productAnalyticsService.logEvent('include-as-attachment', {\r\n includeInAttachment: this.savedSettings.attachChart.toString().toLowerCase()\r\n });\r\n break;\r\n }\r\n }\r\n }\r\n\r\n get editHelpContentId(): string {\r\n if (!this.selectedTemplate) {\r\n return 'appeal-recommendation-template-specification.no-template';\r\n }\r\n\r\n if (this.selectedTemplate.isDefault) {\r\n return 'appeal-recommendation-template-specification.edit-default';\r\n }\r\n\r\n if (this.selectedTemplate.isShared && !this._hasEditSystemSearchPermission) {\r\n return 'app.save-disabled';\r\n }\r\n\r\n return 'app.save';\r\n }\r\n\r\n get copyHelpContentId(): string {\r\n if (!this.selectedTemplate) {\r\n return 'appeal-recommendation-template-specification.no-template';\r\n }\r\n\r\n return 'appeal-recommendation-template-specification.copy';\r\n }\r\n\r\n get deleteHelpContentId(): string {\r\n if (!this.selectedTemplate) {\r\n return 'appeal-recommendation-template-specification.no-template';\r\n }\r\n\r\n if (this.selectedTemplate.isDefault) {\r\n return 'appeal-recommendation-template-specification.delete-default';\r\n }\r\n\r\n if (this.selectedTemplate.isShared && !this._hasEditSystemSearchPermission) {\r\n return 'app.delete-disabled';\r\n }\r\n\r\n return 'app.delete';\r\n }\r\n\r\n async editTemplate(copy: boolean): Promise {\r\n const params: AppealRecommendationTemplateDetailsParams = {\r\n emailSubjectTemplate: this.appealRecommendationInfo.emailSubjectTemplate,\r\n emailBodyTemplate: this.appealRecommendationInfo.emailBodyTemplate,\r\n options: this.savedSettings,\r\n taskIds: this.taskIds,\r\n existingTemplates: this.templates,\r\n selectedTemplate: copy ? null : this.selectedTemplate\r\n };\r\n\r\n const result: Core.AppealRecommendationEmailTemplateModel = await this._modalService.showAsync(AppealRecommendationTemplateDetailsComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (copy) {\r\n this._productAnalyticsService.logEvent('update-custom-template');\r\n const savedTemplate = this._convertToListItem(result);\r\n\r\n this.templates.push(savedTemplate);\r\n this.selectedTemplate = savedTemplate;\r\n } else {\r\n this._productAnalyticsService.logEvent('save-custom-template');\r\n const updatedTemplateIndex = this.templates.findIndex(x => x.appealRecommendationEmailTemplateId === result.appealRecommendationEmailTemplateId);\r\n const updatedTemplate = {...this.templates[updatedTemplateIndex], ...result};\r\n this.templates[updatedTemplateIndex] = updatedTemplate;\r\n this.selectedTemplate = updatedTemplate;\r\n }\r\n\r\n this._initialAppealRecommendationInfo.emailSubjectTemplate = this.selectedTemplate.emailSubjectTemplate;\r\n this._initialAppealRecommendationInfo.emailBodyTemplate = this.selectedTemplate.emailBodyTemplate;\r\n\r\n this._sortSavedTemplates();\r\n await this.save();\r\n }\r\n\r\n async deleteTemplate(): Promise {\r\n try {\r\n await this._messageModalService.confirm(\r\n `Template will be permanently deleted. Are you sure you wish to delete the template \"${this.selectedTemplate.name}\"?`,\r\n 'Confirm Delete'\r\n );\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyMsgId = 'deletingTemplate';\r\n this.busyIndicatorMessageManager.add('Deleting template', busyMsgId);\r\n\r\n const templateId = this.selectedTemplate.appealRecommendationEmailTemplateId;\r\n try {\r\n await lastValueFrom(this._appealRecommendationRepository.deleteTemplate(templateId));\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n\r\n this.selectedTemplate = this.templates[0];\r\n this._selectedTemplateId = this.selectedTemplate.appealRecommendationEmailTemplateId;\r\n await this.onTemplateChanged();\r\n const deletedTemplateIndex = this.templates.findIndex(x => x.appealRecommendationEmailTemplateId === templateId);\r\n this.templates.splice(deletedTemplateIndex, 1);\r\n this._productAnalyticsService.logEvent('delete-custom-template');\r\n this.editing = false;\r\n }\r\n\r\n async onTemplateChanged(userInitiated?: boolean): Promise {\r\n if (userInitiated) {\r\n this._productAnalyticsService.logEvent('select-email-template');\r\n }\r\n if (this.appealRecommendationInfo) {\r\n this.appealRecommendationInfo.emailSubjectTemplate = this.selectedTemplate.emailSubjectTemplate;\r\n this.appealRecommendationInfo.emailBodyTemplate = this.selectedTemplate.emailBodyTemplate;\r\n }\r\n\r\n this.savedSettings.includeSiteComment = this.selectedTemplate.includeSiteComment;\r\n this.savedSettings.showPriorYear = this.selectedTemplate.showPriorYear;\r\n this.savedSettings.showYearBuilt = this.selectedTemplate.showYearBuilt;\r\n this.savedSettings.showAcquisitionInfo = this.selectedTemplate.showAcquisitionInfo;\r\n this.savedSettings.showAppealDeadlines = this.selectedTemplate.showAppealDeadlines;\r\n this.savedSettings.showAssessments = this.selectedTemplate.showAssessments;\r\n this.savedSettings.showMetrics = this.selectedTemplate.showMetrics;\r\n this.savedSettings.showInitialValue = this.selectedTemplate.showInitialValue;\r\n this.savedSettings.showTargetValue = this.selectedTemplate.showTargetValue;\r\n this.savedSettings.showLatestValue = this.selectedTemplate.showLatestValue;\r\n this.savedSettings.showTaxDetails = this.selectedTemplate.showTaxDetails;\r\n this.savedSettings.showSavings = this.selectedTemplate.showSavings;\r\n this.savedSettings.embedInEmail = this.selectedTemplate.embedInEmail;\r\n this.savedSettings.attachChart = this.selectedTemplate.attachChart;\r\n\r\n if (this.initialized) {\r\n await this.refresh();\r\n\r\n this._initialAppealRecommendationInfo = {...this.appealRecommendationInfo};\r\n }\r\n\r\n this._checkIfExceedsPrintableArea();\r\n }\r\n\r\n get canEditDelete(): boolean {\r\n return !this.selectedTemplate.isDefault && (!this.selectedTemplate.isShared ||\r\n this.selectedTemplate.isShared && this._hasEditSystemSearchPermission);\r\n }\r\n\r\n private _canIncludePDFAsAttachment(): boolean {\r\n const number = this._calculateNumberOfGridColumns();\r\n return number <= 11;\r\n }\r\n\r\n private _selectTo(filter: string): void {\r\n const userInfos = this._availableRecipients.filter(a => a.name === filter);\r\n\r\n if (userInfos && userInfos.length == 1) {\r\n this.toFilter = filter;\r\n } else {\r\n this.toFilter = null;\r\n this.appealRecommendationInfo.to = null;\r\n }\r\n }\r\n\r\n private _selectCC(filter: string): void {\r\n const userInfos = this._availableRecipients.filter(a => a.name === filter);\r\n\r\n if (userInfos && userInfos.length == 1) {\r\n this.ccFilter = filter;\r\n } else {\r\n this.ccFilter = null;\r\n this.appealRecommendationInfo.cc = null;\r\n }\r\n }\r\n\r\n private _filterRecipients(filter: string): Observable {\r\n if (filter === null || filter === undefined) {\r\n filter = '';\r\n }\r\n\r\n return of(\r\n this._availableRecipients\r\n .filter(x => x.name.toLowerCase().indexOf(filter.toLowerCase()) !== -1)\r\n .sort((x, y) => x.name > y.name ? 1 : -1)\r\n );\r\n }\r\n\r\n private async _loadSettings() : Promise {\r\n const settingsGroup = this._userSettingsService.getSettingsByGroup(Core.UserSettingGroup.AppealRecommendationTemplate);\r\n this._savedUserSettings = settingsGroup.find(x => x.name === this._settingName);\r\n\r\n if (this._savedUserSettings && this._savedUserSettings.value) {\r\n const savedTemplateId = +this._savedUserSettings.value;\r\n\r\n if (this.enableAppealRecommendationEmailTemplate) {\r\n if (!isNaN(savedTemplateId)) {\r\n const savedTemplate = this.templates.find(x => x.appealRecommendationEmailTemplateId === savedTemplateId);\r\n\r\n this.selectedTemplate = savedTemplate || this.templates[0];\r\n } else {\r\n this.selectedTemplate = this.templates[0];\r\n }\r\n await this.onTemplateChanged();\r\n } else {\r\n this.savedSettings.showPriorYear = this._savedUserSettings.value.showPriorYear;\r\n this.savedSettings.showYearBuilt = this._savedUserSettings.value.showYearBuilt;\r\n this.savedSettings.showAcquisitionInfo = this._savedUserSettings.value.showAcquisitionInfo;\r\n this.savedSettings.showAppealDeadlines = this._savedUserSettings.value.showAppealDeadlines;\r\n this.savedSettings.showAssessments = this._savedUserSettings.value.showAssessments;\r\n this.savedSettings.showMetrics = this._savedUserSettings.value.showMetrics;\r\n this.savedSettings.showInitialValue = this._savedUserSettings.value.showInitialValue;\r\n this.savedSettings.showTargetValue = this._savedUserSettings.value.showTargetValue;\r\n this.savedSettings.showLatestValue = this._savedUserSettings.value.showLatestValue;\r\n this.savedSettings.showTaxDetails = this._savedUserSettings.value.showTaxDetails;\r\n this.savedSettings.showSavings = this._savedUserSettings.value.showSavings;\r\n this.savedSettings.embedInEmail = this._savedUserSettings.value.embedInEmail;\r\n this.savedSettings.attachChart = this._savedUserSettings.value.attachChart;\r\n }\r\n } else if (this.enableAppealRecommendationEmailTemplate) {\r\n this.selectedTemplate = this.templates[0];\r\n await this.onTemplateChanged();\r\n }\r\n\r\n this._checkIfExceedsPrintableArea();\r\n }\r\n\r\n private async _saveSettings() {\r\n if (!this._savedUserSettings) {\r\n this._savedUserSettings = {\r\n id: 0,\r\n name: this._settingName,\r\n groupId: Core.UserSettingGroup.AppealRecommendationTemplate,\r\n folderId: Core.UserSettingFolder.Default,\r\n value: {}\r\n };\r\n }\r\n\r\n this._savedUserSettings.value = this.enableAppealRecommendationEmailTemplate\r\n ? this.selectedTemplate.appealRecommendationEmailTemplateId\r\n : this.savedSettings;\r\n\r\n this._savedUserSettings = await this._userSettingsService.save(this._savedUserSettings);\r\n }\r\n\r\n private _setConsistentPanelWidth(): void {\r\n if (this._optionsPanel1?.nativeElement && this._optionsPanel2?.nativeElement) {\r\n const p1 = this._optionsPanel1.nativeElement.getBoundingClientRect();\r\n const p2 = this._optionsPanel2.nativeElement.getBoundingClientRect();\r\n this.panelSize = {\r\n width: `${p1.width > p2.width ? p1.width : p2.width}px`,\r\n height: `${p1.height > p2.height ? p1.height : p2.height}px`\r\n };\r\n this._cdRef.detectChanges();\r\n }\r\n }\r\n\r\n private _calculateNumberOfGridColumns(): number {\r\n let columnsCount: number = 1;\r\n\r\n if (this.savedSettings.showAssessments === Core.PsrShowAssessmentsEnum.FMV ||\r\n this.savedSettings.showAssessments === Core.PsrShowAssessmentsEnum.FMVAndAlternate) {\r\n if (this.savedSettings.showInitialValue !== Core.PsrShowValueEnum.No) {\r\n columnsCount++;\r\n }\r\n\r\n if (this.savedSettings.showInitialValue === Core.PsrShowValueEnum.YesInclMetrics) {\r\n if (this.savedSettings.showMetrics === Core.PsrShowMetrics.AllPresent) {\r\n columnsCount += 3;\r\n } else if (this.savedSettings.showMetrics === Core.PsrShowMetrics.MostApplicableBasedOnSiteClass &&\r\n this._siteDivisorDescriptors.some(x => x.value === 3 || x.value === 4 || x.value === 5)) {\r\n columnsCount++;\r\n }\r\n }\r\n\r\n if (this.savedSettings.showTargetValue !== Core.PsrShowValueEnum.No) {\r\n columnsCount++;\r\n }\r\n\r\n if (this.savedSettings.showTargetValue === Core.PsrShowValueEnum.YesInclMetrics) {\r\n columnsCount += this._getMetricsColumnsCount();\r\n }\r\n\r\n columnsCount++;\r\n\r\n if (this.savedSettings.showLatestValue === Core.PsrShowLatestValueEnum.YesInclMetricsAndYOYChange ||\r\n this.savedSettings.showLatestValue === Core.PsrShowLatestValueEnum.YesInclMetrics) {\r\n columnsCount += this._getMetricsColumnsCount();\r\n }\r\n\r\n if (this.savedSettings.showLatestValue === Core.PsrShowLatestValueEnum.YesInclMetricsAndYOYChange) {\r\n columnsCount++;\r\n }\r\n }\r\n\r\n if (this.savedSettings.showAssessments === Core.PsrShowAssessmentsEnum.Alternate ||\r\n this.savedSettings.showAssessments === Core.PsrShowAssessmentsEnum.FMVAndAlternate) {\r\n if (this.savedSettings.showInitialValue !== Core.PsrShowValueEnum.No) {\r\n columnsCount++;\r\n }\r\n\r\n if (this.savedSettings.showInitialValue === Core.PsrShowValueEnum.YesInclMetrics) {\r\n columnsCount += this._getMetricsColumnsCount();\r\n }\r\n\r\n columnsCount++;\r\n\r\n if (this.savedSettings.showLatestValue === Core.PsrShowLatestValueEnum.YesInclMetrics ||\r\n this.savedSettings.showLatestValue === Core.PsrShowLatestValueEnum.YesInclMetricsAndYOYChange) {\r\n columnsCount += this._getMetricsColumnsCount();\r\n }\r\n\r\n if (this.savedSettings.showLatestValue === Core.PsrShowLatestValueEnum.YesInclYOYChange ||\r\n this.savedSettings.showLatestValue === Core.PsrShowLatestValueEnum.YesInclMetricsAndYOYChange) {\r\n columnsCount++;\r\n }\r\n }\r\n\r\n if (this.savedSettings.showTaxDetails !== Core.PsrShowTaxDetails.None) {\r\n columnsCount++;\r\n\r\n if (this.savedSettings.showInitialValue !== Core.PsrShowValueEnum.No && (\r\n this.savedSettings.showTaxDetails === Core.PsrShowTaxDetails.AllTaxesInclMetrics ||\r\n this.savedSettings.showTaxDetails === Core.PsrShowTaxDetails.AllTaxesNoMetrics)) {\r\n columnsCount++;\r\n }\r\n\r\n if (this.savedSettings.showTargetValue !== Core.PsrShowValueEnum.No && (\r\n this.savedSettings.showTaxDetails === Core.PsrShowTaxDetails.AllTaxesInclMetrics ||\r\n this.savedSettings.showTaxDetails === Core.PsrShowTaxDetails.AllTaxesNoMetrics)) {\r\n columnsCount++;\r\n }\r\n\r\n columnsCount++;\r\n\r\n if (this.savedSettings.showTaxDetails === Core.PsrShowTaxDetails.LatestTaxesInclMetrics ||\r\n this.savedSettings.showTaxDetails === Core.PsrShowTaxDetails.AllTaxesNoMetrics) {\r\n columnsCount += this._getMetricsColumnsCount();\r\n }\r\n }\r\n\r\n columnsCount++;\r\n\r\n if (this.savedSettings.showSavings === Core.PsrShowSavings.ReceivedOnly ||\r\n this.savedSettings.showSavings === Core.PsrShowSavings.ReceivedAndProjected) {\r\n columnsCount++;\r\n }\r\n\r\n if (this.savedSettings.showSavings === Core.PsrShowSavings.ProjectedOnly ||\r\n this.savedSettings.showSavings === Core.PsrShowSavings.ReceivedAndProjected) {\r\n columnsCount++;\r\n }\r\n\r\n return columnsCount;\r\n }\r\n\r\n private _getMetricsColumnsCount() {\r\n let result = 0;\r\n\r\n if (this.savedSettings.showMetrics === Core.PsrShowMetrics.AllPresent) {\r\n result = 3;\r\n } else if (this.savedSettings.showMetrics === Core.PsrShowMetrics.MostApplicableBasedOnSiteClass &&\r\n this._siteDivisorDescriptors.some(x => x.value === 3 || x.value === 4 || x.value === 5)) {\r\n result++;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n private _sortSavedTemplates(): void {\r\n const defaultTemplates = this.templates.filter(x => x.isDefault);\r\n defaultTemplates.sort((x, y) => x.name.localeCompare(y.name));\r\n\r\n const customTemplates = this.templates.filter(x => !x.isDefault);\r\n customTemplates.sort((x, y) => x.name.localeCompare(y.name));\r\n\r\n this.templates = defaultTemplates.concat(customTemplates);\r\n }\r\n\r\n private _convertToListItem(x: Core.AppealRecommendationEmailTemplateModel): AppealRecommendationEmailTemplateListItemModel {\r\n const result = {\r\n ... x,\r\n ... {\r\n visibilityItem: {\r\n isShared: x.isShared,\r\n isDefault: x.isDefault,\r\n name: '',\r\n description: ''\r\n },\r\n canEdit: false\r\n }\r\n };\r\n\r\n if (result.isDefault) {\r\n result.visibilityItem.name = 'Default';\r\n result.visibilityItem.description = 'Visible to everyone';\r\n } else if (result.isShared) {\r\n result.visibilityItem.name = 'Shared';\r\n result.visibilityItem.description = 'Visible to everyone';\r\n } else {\r\n result.visibilityItem.name = 'Private';\r\n result.visibilityItem.description = 'Visible only to you';\r\n }\r\n\r\n return result;\r\n }\r\n\r\n private _checkIfExceedsPrintableArea() {\r\n this.canIncludePDFAsAttachment = this._canIncludePDFAsAttachment();\r\n if (!this.canIncludePDFAsAttachment &&\r\n this.savedSettings.attachChart === Core.AppealRecommendationTemplateAttachChartOptionEnum.PDF) {\r\n this.savedSettings.attachChart = Core.AppealRecommendationTemplateAttachChartOptionEnum.Excel;\r\n }\r\n\r\n this.attachChartOptions[1].isDisabled = !this.canIncludePDFAsAttachment;\r\n this.attachChartOptions[1].title = !this.canIncludePDFAsAttachment ? this._helpService.getById('appeal-recommendation.checkbox.selections-exceed-printable-area-width') : '';\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const APPEAL_RECOMMENDATION_COMMAND_CENTER_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'appeal-recommendation-command-center.state',\r\n tooltipText: 'At least one state must be selected in order to proceed.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'appeal-recommendation-command-center.assigned',\r\n tooltipText: 'Filtering to indicate appeal determination task assignments and status.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'appeal-recommendation-command-center.deadline',\r\n tooltipText: 'Appeal deadline may not exceed 30 days in the past or 120 days in the future.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.bulk-update-empty',\r\n tooltipText: 'Bulk update supports accepting recommendations, client approval, and displayed characteristics.',\r\n hasIcon: false\r\n }\r\n];\r\n","import { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, ValidatorFn } from '@angular/forms';\r\n\r\nexport interface BulkUpdateOption {\r\n name: string;\r\n descriptorId?: number;\r\n isRequired: boolean;\r\n template: any;\r\n picklist?: Compliance.NameValuePair[];\r\n action: number;\r\n formControlName: string;\r\n formControl: UntypedFormControl;\r\n validation?: Core.DescriptorValidationDTO;\r\n hiddenField?: any;\r\n removeOptionName?: string;\r\n}\r\n\r\nexport abstract class BulkUpdateDynamicBase {\r\n constructor(\r\n protected readonly _bsModalRef: BsModalRef,\r\n protected readonly _fb: UntypedFormBuilder\r\n ) {}\r\n\r\n params: T;\r\n result: U;\r\n\r\n bulkUpdateForm: UntypedFormGroup = this._fb.group({});\r\n\r\n header: string;\r\n updateOptions: BulkUpdateOption[] = [];\r\n\r\n isLoading: boolean;\r\n fieldsModified: boolean = false;\r\n verificationModified: boolean = false;\r\n\r\n protected _templateMap: Map;\r\n\r\n protected _validators: Map ValidatorFn> = new Map([\r\n [Core.DescriptorFieldTypes.Date, (validation) => (control) => {\r\n if (!control.value || this._isValidation(control.value) || !validation) { return null; }\r\n const year = control.value.getFullYear();\r\n const isValid = (validation.minValue ? year >= validation.minValue : true)\r\n && (validation.maxValue ? year <= validation.maxValue : true);\r\n let message = 'Year must be ';\r\n message += (validation.minValue) ? `> ${validation.minValue - 1}` : '';\r\n message += (validation.minValue && validation.maxValue) ? ' and ' : '';\r\n message += (validation.maxValue) ? `< ${validation.maxValue + 1}` : '';\r\n return (!isValid) ? { 'dateInvalid': message } : null;\r\n }],\r\n [Core.DescriptorFieldTypes.Number, (validation) => (control) => {\r\n if (!control.value || this._isValidation(control.value) || !validation) { return null; }\r\n const isValid = (validation.minValue ? control.value >= validation.minValue : true)\r\n && (validation.maxValue ? control.value <= validation.maxValue : true);\r\n let message = 'Value must be ';\r\n message += (validation.minValue) ? `> ${validation.minValue - 1}` : '';\r\n message += (validation.minValue && validation.maxValue) ? ' and ' : '';\r\n message += (validation.maxValue) ? `< ${validation.maxValue + 1}` : '';\r\n return (!isValid) ? { 'numberInvalid': message } : null;\r\n }],\r\n [Core.DescriptorFieldTypes.Picklist, (validation) => (control) => null],\r\n [Core.DescriptorFieldTypes.YesNo, (validation) => (control) => null],\r\n [Core.DescriptorFieldTypes.Text, (validation) => (control) => {\r\n if (!control.value || this._isValidation(control.value) || !validation) { return null; }\r\n const isValid = validation.maxLength ? control.value.length <= validation.maxLength : true;\r\n const message = `Max characters: ${validation.maxLength}`;\r\n return (!isValid) ? { 'textInvalid': message } : null;\r\n }],\r\n [Core.DescriptorFieldTypes.Currency, (validation) => (control) => null]\r\n ]);\r\n\r\n get isFormValid(): boolean {return (this.bulkUpdateForm.valid || this.bulkUpdateForm.disabled) && (this.verificationModified || this.fieldsModified); }\r\n\r\n async save(force: boolean = false): Promise {\r\n return null;\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n rowActionChanged(row: BulkUpdateOption): void {\r\n if (row.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.ChangeTo) {\r\n row.formControl.enable();\r\n this.fieldsModified = true;\r\n return;\r\n } else if (row.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.Remove) {\r\n row.formControl.setValue(null);\r\n this.fieldsModified = true;\r\n } else {\r\n this.fieldsModified = this._actionModified();\r\n }\r\n row.formControl.disable();\r\n }\r\n\r\n validationActionChanged(action: Compliance.NameValuePair, row: BulkUpdateOption): void {\r\n row.action = action.value;\r\n this.verificationModified = this._actionModified();\r\n }\r\n\r\n dateValueChange(date: Date, row: BulkUpdateOption): void {\r\n row.formControl.setValue(date);\r\n row.formControl.markAsDirty();\r\n }\r\n\r\n protected _actionModified(): boolean {\r\n return this.updateOptions.findIndex(o => !(o.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange)) !== -1;\r\n }\r\n\r\n protected _isValidation(value): boolean {\r\n return value === Compliance.AssessorCommandCenterBulkUpdateActionEnum.Verify ||\r\n value === Compliance.AssessorCommandCenterBulkUpdateActionEnum.QC;\r\n }\r\n}\r\n","
\r\n \r\n \r\n The currency value entered is invalid\r\n
\r\n","import { Component, EventEmitter, forwardRef, Input, Output } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\n\r\n/**\r\n * Currency Input\r\n *\r\n * Tied into ControlValueAccessor for integration with native Angular FormControls and ngModel\r\n *\r\n * Example usage:\r\n * \r\n *\r\n */\r\n@Component({\r\n selector: 'ws-currency-input',\r\n templateUrl: './currencyInput.component.html',\r\n styleUrls: ['./currencyInput.component.scss'],\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => CurrencyInputComponent),\r\n multi: true\r\n }\r\n ],\r\n})\r\nexport class CurrencyInputComponent implements ControlValueAccessor {\r\n\r\n @Input() override: boolean;\r\n @Input() hasAdjustments: boolean;\r\n @Input() valid: boolean = true;\r\n @Input() isCalculated: boolean;\r\n @Input() name: string = null;\r\n // Currency lib only supports up to 999 trillion before using exponents, or rounding decimals, 22 is that max with commas\r\n @Input() maxLength: number = 22;\r\n @Input() hasMargin: boolean = true;\r\n\r\n @Output() valueChange: EventEmitter = new EventEmitter();\r\n\r\n value: number;\r\n\r\n disabled: boolean;\r\n error: boolean;\r\n\r\n private onChange: (val: number) => void;\r\n private onTouched: () => void;\r\n\r\n writeValue(value: number) {\r\n this.value = value;\r\n }\r\n\r\n setDisabledState(disabled: boolean) {\r\n this.disabled = disabled;\r\n }\r\n\r\n next() {\r\n this.onChange(this.value);\r\n this.onTouched();\r\n this.valueChange.emit(this.value);\r\n }\r\n\r\n registerOnChange(fn: any) {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any) {\r\n this.onTouched = fn;\r\n }\r\n\r\n currencyChanged(value: number): void {\r\n this.value = value;\r\n this.next();\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { Subscription } from 'rxjs';\r\nimport AssessorCommandCenterBulkUpdateActionEnum = Compliance.AssessorCommandCenterBulkUpdateActionEnum;\r\n\r\n@Component({\r\n selector: 'ws-bulk-update-action',\r\n template: `\r\n \r\n \r\n `,\r\n styles: ['select {width:120px}']\r\n})\r\nexport class BulkUpdateActionComponent implements OnInit, OnDestroy {\r\n\r\n @Input() fieldAction: Compliance.AssessorCommandCenterBulkUpdateActionEnum;\r\n\r\n @Input() requiredField: boolean;\r\n @Input()\r\n set disabled(disabled: boolean) {\r\n if (disabled) {\r\n this.selectedAction.disable();\r\n } else {\r\n this.selectedAction.enable();\r\n }\r\n }\r\n\r\n @Input()\r\n set hideField(hiddenField : Compliance.AssessorCommandCenterBulkUpdateActionEnum) {\r\n if(hiddenField) {\r\n this.possibleActions.forEach( (item, index) => {\r\n if(item.value === hiddenField) {\r\n this.possibleActions.splice(index, 1);\r\n }\r\n });\r\n }\r\n }\r\n\r\n @Input() set removeOptionName(name: string) {\r\n if (name) {\r\n const removeOption = this.possibleActions.find(x => x.value === AssessorCommandCenterBulkUpdateActionEnum.Remove);\r\n removeOption.name = name;\r\n }\r\n }\r\n\r\n @Output() fieldActionChange = new EventEmitter();\r\n\r\n possibleActions: Compliance.NameValuePair[] = [\r\n { name: 'No Change', value: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange },\r\n { name: 'Change To', value: Compliance.AssessorCommandCenterBulkUpdateActionEnum.ChangeTo },\r\n { name: 'Remove', value: Compliance.AssessorCommandCenterBulkUpdateActionEnum.Remove }\r\n ];\r\n selectedAction: UntypedFormControl = new UntypedFormControl(Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange);\r\n private _formSub: Subscription;\r\n\r\n ngOnInit(): void {\r\n this._formSub = this.selectedAction.valueChanges\r\n .subscribe((action: Compliance.AssessorCommandCenterBulkUpdateActionEnum) => this.fieldActionChange.next(action));\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._formSub.unsubscribe();\r\n }\r\n\r\n fieldActionChanged(action): void {\r\n this.selectedAction = action;\r\n this.fieldActionChange.next(action);\r\n }\r\n\r\n isSelected(action: Compliance.AssessorCommandCenterBulkUpdateActionEnum): boolean {\r\n return action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange;\r\n }\r\n}\r\n","\r\n
\r\n \r\n \r\n {{row.formControl.errors?.textInvalid}}\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n \r\n {{row.formControl.errors?.numberInvalid}}\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n \r\n \r\n {{row.formControl.errors?.dateInvalid}}\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{row.name}}\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AppealRecommendationRepository } from '../../appealRecommendation.repository';\r\nimport { BulkUpdateDynamicBase, BulkUpdateOption } from '../../../UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component';\r\nimport { UntypedFormBuilder, UntypedFormControl } from '@angular/forms';\r\n\r\nexport interface AppealRecommendationCommandCenterBulkUpdateParams {\r\n selectedRowsInfo: Core.AppealRecommendationBulkUpdateRowInfoModel[],\r\n stateIds: number[],\r\n appealDeadlineStart: Date,\r\n appealDeadlineEnd: Date,\r\n assignedFilter: Core.AppealRecommendationCCAssignedFilterModel,\r\n descriptorInfo: Core.DescriptorInfoModel[],\r\n picklistInfo: Core.DescriptorPicklistModel[],\r\n appealRecommendationStatuses: Core.AppealRecommendationStatusModel[],\r\n canChangeAppealRecommendationStatus: boolean,\r\n canChangeIsClientApproved: boolean\r\n selectedSiteAnnualAssessmentIds: number[]\r\n}\r\n\r\n@Component({\r\n selector: 'appeal-recommendation-command-center-bulk-update',\r\n templateUrl: '../../../UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component.html',\r\n})\r\nexport class ARCCBulkUpdateComponent extends BulkUpdateDynamicBase implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _appealRecommendationRepository: AppealRecommendationRepository,\r\n _bsModalRef: BsModalRef,\r\n _fb: UntypedFormBuilder\r\n ) { super(_bsModalRef, _fb); }\r\n\r\n @ViewChild('text', { static: true }) textTemplate: ElementRef;\r\n @ViewChild('number', { static: true }) numberTemplate: ElementRef;\r\n @ViewChild('currency', { static: true }) currencyTemplate: ElementRef;\r\n @ViewChild('date', { static: true }) dateTemplate: ElementRef;\r\n @ViewChild('picklist', { static: true }) picklistTemplate: ElementRef;\r\n\r\n params: AppealRecommendationCommandCenterBulkUpdateParams;\r\n result: Core.AppealRecommendationBulkUpdateResultModel;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n isSaving: boolean = false;\r\n\r\n private _hasSelectedSites: boolean;\r\n private _hasSelectedParcels: boolean;\r\n\r\n ngOnInit(): void {\r\n this.header = `Bulk Update ${this.params.selectedRowsInfo.length} Records`;\r\n\r\n this._templateMap = new Map([\r\n [Core.DescriptorFieldTypes.Date, this.dateTemplate],\r\n [Core.DescriptorFieldTypes.Number, this.numberTemplate],\r\n [Core.DescriptorFieldTypes.Picklist, this.picklistTemplate],\r\n [Core.DescriptorFieldTypes.YesNo, this.picklistTemplate],\r\n [Core.DescriptorFieldTypes.Text, this.textTemplate],\r\n [Core.DescriptorFieldTypes.Currency, this.currencyTemplate],\r\n ]);\r\n\r\n this._hasSelectedSites = this.params.selectedRowsInfo.some(x => !x.parcelId);\r\n this._hasSelectedParcels = this.params.selectedRowsInfo.some(x => x.parcelId);\r\n\r\n if (this._hasSelectedSites) {\r\n if (this.params.canChangeAppealRecommendationStatus) {\r\n const appealRecommendationStatusControl = new UntypedFormControl(null);\r\n appealRecommendationStatusControl.disable();\r\n this.bulkUpdateForm.addControl('appealRecommendationStatusId', appealRecommendationStatusControl);\r\n\r\n this.updateOptions.push({\r\n name: 'Rec Status',\r\n isRequired: true,\r\n template: this._templateMap.get(Core.DescriptorFieldTypes.Picklist),\r\n picklist: this.params.appealRecommendationStatuses.map(x => {\r\n return {value: x.id, name: x.name} as Compliance.NameValuePair;\r\n }),\r\n action: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange,\r\n hiddenField: Compliance.AssessorCommandCenterBulkUpdateActionEnum.Remove,\r\n formControlName: 'appealRecommendationStatusId',\r\n formControl: appealRecommendationStatusControl\r\n } as BulkUpdateOption);\r\n }\r\n\r\n if (this.params.canChangeIsClientApproved) {\r\n const isClientApprovedControl = new UntypedFormControl(null);\r\n isClientApprovedControl.disable();\r\n this.bulkUpdateForm.addControl('isClientApproved', isClientApprovedControl);\r\n\r\n this.updateOptions.push({\r\n name: 'Client Approved',\r\n isRequired: true,\r\n template: this._templateMap.get(Core.DescriptorFieldTypes.YesNo),\r\n picklist: this._getPicklist(Core.DescriptorFieldTypes.YesNo),\r\n action: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange,\r\n hiddenField: Compliance.AssessorCommandCenterBulkUpdateActionEnum.Remove,\r\n formControlName: 'isClientApproved',\r\n formControl: isClientApprovedControl\r\n } as BulkUpdateOption);\r\n }\r\n }\r\n\r\n this.params.descriptorInfo.sort((x, y) => x.name.localeCompare(y.name));\r\n this.params.descriptorInfo.forEach(x => {\r\n if (x.siteUsage !== Core.DescriptorUsageEnum.Never && this._hasSelectedSites) {\r\n const controlName = `s.${x.descriptorId}`;\r\n const control = new UntypedFormControl(null, [this._validators.get(x.fieldType)(x.validation)]);\r\n control.disable();\r\n this.bulkUpdateForm.addControl(controlName, control);\r\n\r\n this.updateOptions.push({\r\n name: `Site ${x.name}`,\r\n descriptorId: x.descriptorId,\r\n isRequired: true,\r\n template: this._templateMap.get(x.fieldType),\r\n picklist: this._getPicklist(x.fieldType),\r\n action: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange,\r\n formControlName: controlName,\r\n formControl: control\r\n } as BulkUpdateOption);\r\n }\r\n\r\n if (x.parcelUsage !== Core.DescriptorUsageEnum.Never && this._hasSelectedParcels) {\r\n const controlName = `p.${x.descriptorId}`;\r\n const control = new UntypedFormControl(null, [this._validators.get(x.fieldType)(x.validation)]);\r\n control.disable();\r\n this.bulkUpdateForm.addControl(controlName, control);\r\n\r\n this.updateOptions.push({\r\n name: `Parcel ${x.name}`,\r\n descriptorId: x.descriptorId,\r\n isRequired: true,\r\n template: this._templateMap.get(x.fieldType),\r\n picklist: this._getPicklist(x.fieldType),\r\n action: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange,\r\n formControlName: controlName,\r\n formControl: control\r\n } as BulkUpdateOption);\r\n }\r\n });\r\n\r\n this.isLoading = false;\r\n }\r\n\r\n async save(force: boolean = false): Promise {\r\n this.isSaving = true;\r\n await this._bulkUpdate();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private async _bulkUpdate(): Promise {\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n\r\n const formValues = this.bulkUpdateForm.value;\r\n try {\r\n const appealRecommendationStatusOption = this.updateOptions.find(x => x.name === 'Rec Status');\r\n const isClientApprovedOption = this.updateOptions.find(x => x.name === 'Client Approved');\r\n\r\n const model: Core.AppealRecommendationBulkUpdateModel = {\r\n selectedRowsInfo: this.params.selectedRowsInfo,\r\n stateIds: this.params.stateIds,\r\n selectedSiteAnnualAssessmentIds: this.params.selectedSiteAnnualAssessmentIds,\r\n appealDeadlineStart: this.params.appealDeadlineStart,\r\n appealDeadlineEnd: this.params.appealDeadlineEnd,\r\n assignedFilter: this.params.assignedFilter,\r\n appealRecommendationStatusAction: this._hasSelectedSites && this.params.canChangeAppealRecommendationStatus && appealRecommendationStatusOption.action,\r\n appealRecommendationStatus: this._hasSelectedSites && this.params.canChangeAppealRecommendationStatus && appealRecommendationStatusOption.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.ChangeTo ? formValues['appealRecommendationStatusId'] : null,\r\n isClientApprovedAction: this._hasSelectedSites && this.params.canChangeIsClientApproved && isClientApprovedOption.action,\r\n isClientApproved: this._hasSelectedSites && this.params.canChangeIsClientApproved && isClientApprovedOption.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.ChangeTo ? formValues['isClientApproved'] : null,\r\n descriptors: this.updateOptions\r\n .filter(x => x.descriptorId && x.action !== Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange)\r\n .map(x => {\r\n return {\r\n descriptorId: x.descriptorId,\r\n action: x.action,\r\n isSiteLevel: x.formControlName.startsWith('s.'),\r\n value: x.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.Remove\r\n ? null :\r\n formValues[x.formControlName],\r\n } as Core.AppealRecommendationBulkUpdateDescriptorModel;\r\n })\r\n };\r\n\r\n this.result = await lastValueFrom(this._appealRecommendationRepository.bulkUpdate(model));\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.isSaving = false;\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n private _getPicklist(fieldType: Core.DescriptorFieldTypes) {\r\n if (fieldType === Core.DescriptorFieldTypes.Picklist) {\r\n return this.params.picklistInfo.map(x => ({ name: x.name, value: x.name }));\r\n }\r\n\r\n if (fieldType === Core.DescriptorFieldTypes.YesNo) {\r\n return [\r\n { name: 'Yes', value: true },\r\n { name: 'No', value: false }\r\n ];\r\n }\r\n }\r\n}\r\n","\r\n
\r\n
    \r\n
  • {{site.companyName}} - {{site.siteName}}
  • \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\n\r\nexport interface AppealRecommendationCommandCenterBulkUpdateResultConfirmationComponentParams {\r\n ignoredSites: Core.AppealRecommendationBulkUpdateSiteResultModel[]\r\n}\r\n\r\n@Component({\r\n selector: 'appeal-recommendation-command-center-bulk-update-result-confirmation',\r\n templateUrl: './aRCCBulkUpdateResultConfirmation.component.html'\r\n})\r\nexport class ARCCBulkUpdateResultConfirmationComponent implements OnInit, IWeissmanModalComponent{\r\n constructor(private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: AppealRecommendationCommandCenterBulkUpdateResultConfirmationComponentParams;\r\n result: void;\r\n sites: Core.AppealRecommendationBulkUpdateSiteResultModel[];\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n ngOnInit(): void {\r\n this.sites = this.params.ignoredSites.sort((x, y) => `${x.companyName + x.siteName}`.localeCompare(`${y.companyName + y.siteName}`));\r\n }\r\n}\r\n","\r\n \r\n

{{loadingMessage}}

\r\n
\r\n

Please confirm client approval has been received prior to processing.

\r\n

{{ validationMessage }}

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n Comment:\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { ProcessingService } from '../processing.service.upgrade';\r\n\r\nexport interface ProcessAppealWarrantedParams {\r\n taskIDs: number[];\r\n searchTimestamp: Date;\r\n runWithBuffer: boolean;\r\n updateAppealRecommendation: boolean;\r\n}\r\n\r\nexport interface ProcessAppealWarrantedForm {\r\n taskIDs: number[];\r\n appealLevelID: number;\r\n comment: string;\r\n searchTimestamp: Date;\r\n updateAppealRecommendation: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'process-appeal-warranted',\r\n templateUrl: './processAppealWarranted.component.html'\r\n})\r\nexport class ProcessAppealWarrantedComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _processingService: ProcessingService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _toastr: ToastrService) {\r\n }\r\n\r\n params: ProcessAppealWarrantedParams;\r\n result: Core.BulkOperationResult[];\r\n\r\n loading: boolean;\r\n loadingMessage: string;\r\n validationMessage: string;\r\n appealLevels: any[];\r\n isClientApprovalRequired: boolean;\r\n\r\n payload: ProcessAppealWarrantedForm;\r\n\r\n get cancelLabel(): string {\r\n return this.appealLevels ? 'Cancel' : 'Close';\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this.loading = true;\r\n\r\n this.payload = {\r\n taskIDs: this.params.taskIDs,\r\n appealLevelID: null,\r\n comment: null,\r\n searchTimestamp: this.params.searchTimestamp,\r\n updateAppealRecommendation: this.params.updateAppealRecommendation\r\n };\r\n\r\n try {\r\n const result = await this._processingService.getAppealLevels(this.params.taskIDs);\r\n this.validationMessage = result.validationMessage;\r\n this.appealLevels = result.appealLevels;\r\n this.isClientApprovalRequired = result.isClientApprovalRequired;\r\n\r\n if (result.warningMessage) {\r\n await this._messageBoxService.warning(result.warningMessage);\r\n }\r\n\r\n if (this.appealLevels.length) {\r\n this.payload.appealLevelID = this.appealLevels[0].appealLevelID;\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async process(): Promise {\r\n this.loading = true;\r\n\r\n if (this.params.runWithBuffer) {\r\n // This is \"experimental\" at the moment; I'm leaving in the ability to set a processingBufferOverride in\r\n // a console in case we run into any obscure problems here and for instance need to set it to 1 to clear\r\n // things out. Once this has been in place for a while we can probably get rid of the override thing.\r\n await this._runModalResultWithBuffer();\r\n } else {\r\n this.result = await this._processingService.processAppealWarranted(this.payload);\r\n this._bsModalRef.hide();\r\n }\r\n }\r\n\r\n private async _runModalResultWithBuffer(): Promise {\r\n const bufferSize = (window as any).processingBufferOverride || 20;\r\n\r\n const chunks = [];\r\n for (let i = 0; i < this.params.taskIDs.length; i += bufferSize) {\r\n chunks.push(this.params.taskIDs.slice(i, i + bufferSize));\r\n }\r\n\r\n let index = 1;\r\n this.result = [];\r\n\r\n const processChunk = async () => {\r\n if (chunks.length) {\r\n const chunk = chunks.shift();\r\n if (bufferSize === 1) {\r\n this.loadingMessage = `Processing Task ${ index } of ${ this.params.taskIDs.length }...`;\r\n } else {\r\n this.loadingMessage = `Processing Tasks ${ index } - ${ index + chunk.length - 1 } of ${ this.params.taskIDs.length }...`;\r\n }\r\n\r\n try {\r\n const payload = structuredClone(this.payload);\r\n payload.taskIDs = chunk;\r\n const tempResult = await this._processingService.processAppealWarranted(this.payload);\r\n this.result = [...this.result, ...tempResult];\r\n index += chunk.length;\r\n await processChunk();\r\n } catch (err) {\r\n this.loading = false;\r\n this.loadingMessage = null;\r\n this._toastr.error('An unexpected error has occurred');\r\n }\r\n } else {\r\n this.loading = false;\r\n this.loadingMessage = null;\r\n this._bsModalRef.hide();\r\n }\r\n };\r\n\r\n await processChunk();\r\n }\r\n}\r\n","\r\n \r\n
\r\n

Please confirm client approval has been received prior to processing.

\r\n
\r\n Set Assessment Description to:\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n Comment:\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { RevisionChangeTypes } from '../../constants.new';\r\nimport { ActionViewPersistenceService } from '../../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { ProcessingService } from '../processing.service.upgrade';\r\n\r\nexport interface ProcessNoAppealParams {\r\n taskIDs: number[];\r\n searchTimestamp: Date;\r\n updateAppealRecommendation: boolean;\r\n}\r\n\r\nexport interface ProcessNoAppealForm {\r\n taskIDs: number[];\r\n revisionChangeTypeID: number;\r\n newRevisionDescription: string;\r\n comment: string;\r\n searchTimestamp: Date;\r\n updateAppealRecommendation: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'process-no-appeal',\r\n templateUrl: './processNoAppeal.component.html'\r\n})\r\nexport class ProcessNoAppealComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService,\r\n private readonly _processingService: ProcessingService) {\r\n }\r\n\r\n @ViewChild('other') other: ElementRef;\r\n\r\n params: ProcessNoAppealParams;\r\n result: Core.BulkOperationResult[];\r\n\r\n loading: boolean;\r\n payload: ProcessNoAppealForm;\r\n revisionChangeTypes = RevisionChangeTypes;\r\n isClientApprovalRequired: boolean;\r\n\r\n async ngOnInit(): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n const result = await this._processingService.getAppealLevels(this.params.taskIDs);\r\n this.isClientApprovalRequired = result.isClientApprovalRequired;\r\n\r\n this.payload = {\r\n taskIDs: this.params.taskIDs,\r\n revisionChangeTypeID: this._actionViewPersistenceService.revisionChangeTypeID || 1,\r\n newRevisionDescription: '',\r\n comment: null,\r\n searchTimestamp: this.params.searchTimestamp,\r\n updateAppealRecommendation: this.params.updateAppealRecommendation\r\n };\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n focus(): void {\r\n if (this.other) {\r\n this.other.nativeElement.focus();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async process(): Promise {\r\n this.loading = true;\r\n this._actionViewPersistenceService.revisionChangeTypeID = this.payload.revisionChangeTypeID;\r\n\r\n try {\r\n this.result = await this._processingService.processNoAppealWarranted(this.payload);\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n}\r\n","\r\n
\r\n
\r\n

{{topLevelMessage}}

\r\n
    \r\n
  • {{message}}
  • \r\n
  • {{message}}
  • \r\n
\r\n
\r\n
0\">\r\n

{{warningMessage}}

\r\n
    \r\n
  • {{message}}
  • \r\n
\r\n
\r\n
0\">\r\n

{{errorMessage}}

\r\n
    \r\n
  • {{message}}
  • \r\n
\r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\n\r\nexport interface ErrorNotificationParams {\r\n errors: string[];\r\n warnings: string[];\r\n errorMessage: string;\r\n warningMessage: string;\r\n}\r\n\r\n@Component({\r\n selector: 'error-notification',\r\n templateUrl: './errorNotification.component.html'\r\n})\r\nexport class ErrorNotificationComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef) { }\r\n\r\n params: ErrorNotificationParams;\r\n result: void;\r\n\r\n errors: string[];\r\n warnings: string[];\r\n topLevelMessage: string;\r\n errorMessage: string;\r\n warningMessage: string;\r\n\r\n ngOnInit() {\r\n this.errors = this.params.errors;\r\n this.warnings = this.params.warnings;\r\n if (this.params.errorMessage && !this.params.warningMessage) {\r\n this.topLevelMessage = this.params.errorMessage;\r\n } else {\r\n this.errorMessage = this.params.errorMessage;\r\n this.warningMessage = this.params.warningMessage;\r\n }\r\n }\r\n\r\n close(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { WeissmanModalService } from '../Compliance/WeissmanModalService';\r\nimport { ErrorNotificationComponent, ErrorNotificationParams } from './Error-Notification/errorNotification.component';\r\n// import { TaskModalComponent, TaskModalParams } from './taskModal.component';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class TaskModalsService {\r\n constructor(private readonly _weissmanModalService: WeissmanModalService) {\r\n }\r\n\r\n // async launchTaskModal(taskGroupsBySequence: any, modalSize: string): Promise {\r\n // const params: TaskModalParams = {\r\n // tasks: taskGroupsBySequence\r\n // };\r\n //\r\n // //returns boolean for reload required\r\n // return await this._weissmanModalService.showAsync(TaskModalComponent, params, modalSize);\r\n // }\r\n\r\n showErrorNotificationModal(errors: string[], warnings: string[], errorMessage: string, warningMessage?: string): void {\r\n const params: ErrorNotificationParams = {\r\n errorMessage: errorMessage,\r\n errors: errors,\r\n warningMessage: warningMessage,\r\n warnings: warnings,\r\n };\r\n\r\n this._weissmanModalService.showAsync(ErrorNotificationComponent, params, 'modal-lg');\r\n }\r\n}\r\n","\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { CostCenterTeam } from '../../../Team/teamPicker.component';\r\nimport TeamModel = Core.TeamModel;\r\n\r\nexport interface AssignedDetailsModalParams {\r\n options: Compliance.NameValuePair[],\r\n selectedOptionName: string,\r\n defaultCustomOption: Compliance.NameValuePair;\r\n}\r\n\r\nexport enum AppealRecommendationCCAssignedFilterShowOptionEnum {\r\n MyTasks = Core.AppealRecommendationCCAssignedFilterShowOptionEnum.MyTasks,\r\n MyTeamTasks = Core.AppealRecommendationCCAssignedFilterShowOptionEnum.MyTeamTasks,\r\n SpecificIndividualTasks = Core.AppealRecommendationCCAssignedFilterShowOptionEnum.SpecificIndividualTasks,\r\n SpecificTeamTasks = Core.AppealRecommendationCCAssignedFilterShowOptionEnum.SpecificTeamTasks\r\n}\r\n\r\nexport enum AppealRecommendationCCAssignedFilterWhereOptionEnum {\r\n Assigned = Core.AppealRecommendationCCAssignedFilterWhereOptionEnum.Assigned,\r\n UltimatelyResponsible = Core.AppealRecommendationCCAssignedFilterWhereOptionEnum.UltimatelyResponsible,\r\n AssignedOrUltimatelyResponsible = Core.AppealRecommendationCCAssignedFilterWhereOptionEnum.AssignedOrUltimatelyResponsible,\r\n AccountHandler = Core.AppealRecommendationCCAssignedFilterWhereOptionEnum.AccountHandler\r\n}\r\n\r\nexport enum AppealRecommendationCCAssignedFilterThatOptionEnum {\r\n Ready = Core.AppealRecommendationCCAssignedFilterThatOptionEnum.Ready,\r\n NotReady = Core.AppealRecommendationCCAssignedFilterThatOptionEnum.NotReady,\r\n ReadyOrNotReady = Core.AppealRecommendationCCAssignedFilterThatOptionEnum.ReadyOrNotReady,\r\n Completed = Core.AppealRecommendationCCAssignedFilterThatOptionEnum.Completed\r\n}\r\n\r\n@Component({\r\n selector: 'appeal-recommendation-command-center-assigned-details-modal',\r\n templateUrl: './aRCCAssignedDetailsModal.component.html',\r\n styleUrls: ['./aRCCAssignedDetailsModal.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ARCCAssignedDetailsModalComponent implements OnInit, IWeissmanModalComponent>{\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef\r\n ){ }\r\n\r\n params: AssignedDetailsModalParams;\r\n result: Compliance.NameValuePair;\r\n appealRecommendationCCAssignedFilterShowOptionEnum = AppealRecommendationCCAssignedFilterShowOptionEnum;\r\n appealRecommendationCCAssignedFilterWhereOptionEnum = AppealRecommendationCCAssignedFilterWhereOptionEnum;\r\n appealRecommendationCCAssignedFilterThatOptionEnum = AppealRecommendationCCAssignedFilterThatOptionEnum;\r\n selectedOption: Compliance.NameValuePair;\r\n _originalCustomOption: Compliance.NameValuePair;\r\n specificTeams: CostCenterTeam[] = [];\r\n\r\n ngOnInit(): void {\r\n this.selectedOption = this.params.options.find(x => x.name === this.params.selectedOptionName);\r\n this._originalCustomOption = structuredClone(this.params.options[this.params.options.length - 1]);\r\n\r\n if (this.selectedOptionName === 'Custom' && this.selectedOption.value.specificUsers.length === 0) {\r\n this.addNewUser();\r\n }\r\n\r\n if (this.selectedOptionName === 'Custom' && this.selectedOption.value.specificTeams.length === 0) {\r\n this.addNewTeam();\r\n }\r\n\r\n if (this.selectedOption.name === 'Custom') {\r\n this._populateSpecificTeams(this.selectedOption.value.specificTeams);\r\n }\r\n }\r\n\r\n\r\n save() {\r\n if (this.selectedOption.name === 'Custom') {\r\n this.selectedOption.value.specificTeams = this.specificTeams.map(x => {\r\n return {teamID: x.teamID, name: x.name} as TeamModel;\r\n });\r\n }\r\n this.result = this.selectedOption;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel() {\r\n if (this.selectedOption.name === 'Custom') {\r\n Object.assign(this.selectedOption, this._originalCustomOption);\r\n }\r\n this._bsModalRef.hide();\r\n }\r\n\r\n removeUser(index: number) {\r\n this.selectedOption.value.specificUsers.splice(index, 1);\r\n }\r\n\r\n setUser(user: Core.UserTeamModel, index: number) {\r\n this.selectedOption.value.specificUsers[index] = user;\r\n }\r\n\r\n addNewUser() {\r\n this.selectedOption.value.specificUsers.push({} as Core.UserTeamModel);\r\n }\r\n\r\n selectionChanged(newValue: any, propertyName: string) {\r\n const modifiedSelectedOption = structuredClone(this.selectedOption);\r\n modifiedSelectedOption.value[propertyName] = newValue;\r\n\r\n const predefinedOption = this.params.options\r\n .find(x => x.value.show === modifiedSelectedOption.value.show &&\r\n x.value.where === modifiedSelectedOption.value.where &&\r\n x.value.that === modifiedSelectedOption.value.that);\r\n\r\n if (predefinedOption) {\r\n this.selectedOptionChanged(predefinedOption.name, false);\r\n } else {\r\n if (this.selectedOptionName !== 'Custom') {\r\n this.selectedOption = structuredClone(this.params.defaultCustomOption);\r\n }\r\n\r\n this.selectedOption.value[propertyName] = newValue;\r\n if (propertyName === 'show') {\r\n if (newValue === AppealRecommendationCCAssignedFilterShowOptionEnum.MyTasks ||\r\n newValue === AppealRecommendationCCAssignedFilterShowOptionEnum.MyTeamTasks) {\r\n this.selectedOption.value.specificUsers = [];\r\n this.selectedOption.value.specificTeams = [];\r\n this.specificTeams = [];\r\n } else if (newValue === AppealRecommendationCCAssignedFilterShowOptionEnum.SpecificIndividualTasks) {\r\n this.selectedOption.value.specificUsers = [{} as Core.UserTeamModel];\r\n this.selectedOption.value.specificTeams = [];\r\n this.specificTeams = [];\r\n } else if (newValue === AppealRecommendationCCAssignedFilterShowOptionEnum.SpecificTeamTasks) {\r\n this.selectedOption.value.specificUsers = [];\r\n this.specificTeams = [{} as CostCenterTeam];\r\n }\r\n }\r\n }\r\n }\r\n\r\n selectedOptionChanged(optionName: string, reloadCustom: boolean) {\r\n this.selectedOption = this.params.options\r\n .find(x => x.name === optionName);\r\n\r\n if (optionName === 'Custom' && reloadCustom) {\r\n Object.assign(this.selectedOption, this._originalCustomOption);\r\n }\r\n }\r\n\r\n addNewTeam() {\r\n this.specificTeams.push({} as CostCenterTeam);\r\n }\r\n\r\n removeTeam(index: number) {\r\n this.specificTeams.splice(index, 1);\r\n }\r\n teamChanged(team: CostCenterTeam, index: number) {\r\n this.specificTeams[index] = team;\r\n }\r\n\r\n get selectedOptionName(): string {\r\n return this.selectedOption && this.selectedOption.name;\r\n }\r\n\r\n get disableSubmit(): boolean {\r\n const selectedOptionValue = this.selectedOption.value;\r\n const specificIndividualTasks = selectedOptionValue.show === Core.AppealRecommendationCCAssignedFilterShowOptionEnum.SpecificIndividualTasks\r\n && selectedOptionValue.specificUsers.some(x => x && !x.userID);\r\n const specificTeamTasks = selectedOptionValue.show === Core.AppealRecommendationCCAssignedFilterShowOptionEnum.SpecificTeamTasks\r\n && this.specificTeams.some(x => x && !x.teamID);\r\n return specificIndividualTasks || specificTeamTasks;\r\n }\r\n\r\n private _populateSpecificTeams(teams: Core.TeamModel[]) {\r\n this.specificTeams = teams.map(x => {\r\n return {teamID: x.teamID, name: x.name} as CostCenterTeam;\r\n });\r\n\r\n if (this.specificTeams.length === 0) {\r\n this.addNewTeam();\r\n }\r\n }\r\n}\r\n","
\r\n \r\n \r\n \r\n
\r\n","import { Component, EventEmitter, OnInit, Output } from '@angular/core';\r\nimport AppealRecommendationCCAssignedFilterShowOptionEnum = Core.AppealRecommendationCCAssignedFilterShowOptionEnum;\r\nimport AppealRecommendationCCAssignedFilterWhereOptionEnum = Core.AppealRecommendationCCAssignedFilterWhereOptionEnum;\r\nimport AppealRecommendationCCAssignedFilterThatOptionEnum = Core.AppealRecommendationCCAssignedFilterThatOptionEnum;\r\nimport { UserSettingsService } from '../../../Account/userSettings.service';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport {\r\n ARCCAssignedDetailsModalComponent, AssignedDetailsModalParams\r\n} from '../ARCC-Assigned-Details-Modal/aRCCAssignedDetailsModal.component';\r\nimport { APPEAL_RECOMMENDATION_COMMAND_CENTER_HELP } from '../aRCC.component.help';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\n\r\n@Component({\r\n selector: 'appeal-recommendation-command-center-assigned',\r\n templateUrl: './aRCCAssigned.component.html'\r\n})\r\nexport class ARCCAssignedComponent implements OnInit {\r\n\r\n constructor(\r\n private readonly _userSettingsService: UserSettingsService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {\r\n }\r\n\r\n @Output() optionChange: EventEmitter = new EventEmitter();\r\n\r\n defaultCustomOption: Compliance.NameValuePair = {\r\n name: 'Custom', value: {\r\n show: AppealRecommendationCCAssignedFilterShowOptionEnum.MyTasks,\r\n where: AppealRecommendationCCAssignedFilterWhereOptionEnum.Assigned,\r\n that: AppealRecommendationCCAssignedFilterThatOptionEnum.Ready,\r\n specificUsers: [],\r\n specificTeams: []\r\n }\r\n };\r\n\r\n options: Compliance.NameValuePair[] = [\r\n {\r\n name: 'My Assigned Tasks: Ready or Not Ready', value: {\r\n show: AppealRecommendationCCAssignedFilterShowOptionEnum.MyTasks,\r\n where: AppealRecommendationCCAssignedFilterWhereOptionEnum.Assigned,\r\n that: AppealRecommendationCCAssignedFilterThatOptionEnum.ReadyOrNotReady,\r\n specificUsers: [],\r\n specificTeams: []\r\n }\r\n },\r\n {\r\n name: 'My Team\\'s Assigned Tasks: Ready or Not Ready', value: {\r\n show: AppealRecommendationCCAssignedFilterShowOptionEnum.MyTeamTasks,\r\n where: AppealRecommendationCCAssignedFilterWhereOptionEnum.Assigned,\r\n that: AppealRecommendationCCAssignedFilterThatOptionEnum.ReadyOrNotReady,\r\n specificUsers: [],\r\n specificTeams: []\r\n }\r\n },\r\n structuredClone(this.defaultCustomOption)\r\n ];\r\n\r\n selectedOptionName: string;\r\n\r\n private _savedSelectedOptionSetting: any;\r\n private readonly _settingName = 'Assigned-Selected-Option';\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(APPEAL_RECOMMENDATION_COMMAND_CENTER_HELP);\r\n\r\n const settings = this._userSettingsService.getSettingsByGroup(Core.UserSettingGroup.AppealRecommendationCommandCenter);\r\n this._savedSelectedOptionSetting = settings.find(x => x.name === this._settingName);\r\n\r\n let selectedOption: Compliance.NameValuePair;\r\n\r\n if (this._savedSelectedOptionSetting) {\r\n selectedOption = this.options.find(x => x.name === this._savedSelectedOptionSetting.value.name);\r\n\r\n if (selectedOption && selectedOption.name === 'Custom') {\r\n for (const prop in this._savedSelectedOptionSetting.value.value) {\r\n selectedOption.value[prop] = this._savedSelectedOptionSetting.value.value[prop];\r\n }\r\n }\r\n }\r\n\r\n if (!selectedOption) {\r\n selectedOption = this.options[0];\r\n }\r\n\r\n this.selectedOptionName = selectedOption.name;\r\n this.optionChange.emit(selectedOption.value);\r\n }\r\n\r\n async selectedOptionChanged() {\r\n const selectedOption = this.options\r\n .find(x => x.name === this.selectedOptionName);\r\n this._productAnalyticsService.logEvent('select-assignment-type', { arccAssigned: this._getNameFromEnum('show', selectedOption.value) });\r\n this.optionChange.emit(selectedOption.value);\r\n await this._saveSelectedOption(selectedOption);\r\n }\r\n\r\n async edit(): Promise {\r\n const params: AssignedDetailsModalParams = {\r\n options: this.options,\r\n selectedOptionName: this.selectedOptionName,\r\n defaultCustomOption: this.defaultCustomOption\r\n };\r\n\r\n const result = await this._modalService.showAsync(ARCCAssignedDetailsModalComponent, params, 'modal-xl');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._productAnalyticsService.logEvent('edit-assignment-options', {\r\n arccShow: this._getNameFromEnum('show', result.value),\r\n arccWhere: this._getNameFromEnum('where', result.value),\r\n arccThatAre: this._getNameFromEnum('that', result.value),\r\n });\r\n\r\n this.selectedOptionName = result.name;\r\n\r\n if (this.selectedOptionName === 'Custom') {\r\n this.options[this.options.length - 1] = result;\r\n }\r\n\r\n this.optionChange.emit(result.value);\r\n\r\n await this._saveSelectedOption(result);\r\n }\r\n\r\n private async _saveSelectedOption(selectedOption: Compliance.NameValuePair) {\r\n if (!this._savedSelectedOptionSetting) {\r\n this._savedSelectedOptionSetting = {\r\n id: 0,\r\n name: this._settingName,\r\n groupId: Core.UserSettingGroup.AppealRecommendationCommandCenter,\r\n folderId: Core.UserSettingFolder.Default\r\n };\r\n }\r\n\r\n this._savedSelectedOptionSetting.value = selectedOption;\r\n this._savedSelectedOptionSetting = await this._userSettingsService.save(this._savedSelectedOptionSetting);\r\n }\r\n\r\n private _getNameFromEnum(prop: string, value: any): string {\r\n let selection: string;\r\n switch (prop) {\r\n case 'show':\r\n switch (value.show) {\r\n case Core.AppealRecommendationCCAssignedFilterShowOptionEnum.MyTasks:\r\n selection = 'My Tasks';\r\n break;\r\n case Core.AppealRecommendationCCAssignedFilterShowOptionEnum.MyTeamTasks:\r\n selection = 'My Team Tasks';\r\n break;\r\n case Core.AppealRecommendationCCAssignedFilterShowOptionEnum.SpecificIndividualTasks:\r\n selection = 'Specific Individual';\r\n break;\r\n case Core.AppealRecommendationCCAssignedFilterShowOptionEnum.SpecificTeamTasks:\r\n selection = 'Specific Team';\r\n break;\r\n }\r\n break;\r\n case 'where':\r\n switch (value.where) {\r\n case Core.AppealRecommendationCCAssignedFilterWhereOptionEnum.Assigned:\r\n selection = 'Assigned';\r\n break;\r\n case Core.AppealRecommendationCCAssignedFilterWhereOptionEnum.UltimatelyResponsible:\r\n selection = 'Ultimately Responsible';\r\n break;\r\n case Core.AppealRecommendationCCAssignedFilterWhereOptionEnum.AssignedOrUltimatelyResponsible:\r\n selection = 'Assigned or Ultimately Responsible';\r\n break;\r\n case Core.AppealRecommendationCCAssignedFilterWhereOptionEnum.AccountHandler:\r\n selection = 'Account Handler';\r\n break;\r\n }\r\n break;\r\n case 'that':\r\n switch (value.that) {\r\n case Core.AppealRecommendationCCAssignedFilterThatOptionEnum.Ready:\r\n selection = 'Ready';\r\n break;\r\n case Core.AppealRecommendationCCAssignedFilterThatOptionEnum.NotReady:\r\n selection = 'Not Ready';\r\n break;\r\n case Core.AppealRecommendationCCAssignedFilterThatOptionEnum.ReadyOrNotReady:\r\n selection = 'Ready or Not Ready';\r\n break;\r\n case Core.AppealRecommendationCCAssignedFilterThatOptionEnum.Completed:\r\n selection = 'Completed';\r\n break;\r\n }\r\n break;\r\n }\r\n return selection;\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n Appeal Recommendation Command Center\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n","import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { ColDef, ColumnApi, FilterChangedEvent, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport {\r\n AgGridColumns,\r\n AgGridDropdownCellEditor,\r\n AgGridFilterParams,\r\n AgGridNumberCellEditor,\r\n AgGridOptionsBuilder\r\n} from '../../Compliance/AgGrid';\r\nimport { AppealRecommendationRepository } from '../appealRecommendation.repository';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { BehaviorSubject, lastValueFrom, Subject } from 'rxjs';\r\nimport {\r\n ExpandCellRendererComponent,\r\n ICellRendererParamsForExpandCellRenderer\r\n} from 'src/app/Common/AgGrid/agGridExpandCellRenderer.component';\r\nimport {\r\n ExpandCellHeaderRendererComponent,\r\n ICellRendererParamsForExpandCellHeaderParams\r\n} from '../../Common/AgGrid/agGridExpandCellHeaderRenderer.component';\r\nimport {\r\n AgGridMultiSelectCellRendererParams,\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../Compliance/AgGrid/MultiSelectTracker';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AppealRecommendationGridRowInfoTreeItemModel } from './appealRecommendationGridRowInfoTreeItemModel';\r\nimport { WeissmanDateFormatPipe } from '../../UI-Lib/Pipes';\r\nimport { DecimalPipe, PercentPipe } from '@angular/common';\r\nimport {\r\n AgGridYesNoFloatingFilterComponent\r\n} from '../../Compliance/AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport { ICellEditorParams } from 'ag-grid-community/dist/lib/interfaces/iCellEditor';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport {\r\n AgGridExportOptions,\r\n AgGridExportStartLRP,\r\n AgGridToolPanelButton\r\n} from '../../Compliance/AgGrid/ToolPanel/models';\r\nimport { DESCRIPTOR_COLUMN_DEFINITIONS } from '../../Compliance/AgGrid/agGridDescriptorColumnDefenition';\r\nimport { AppealRecommendationCommandCenterGridActionCellRendererComponent } from './agGridActionCellRenderer.component';\r\nimport { AgGridTooltipCellRendererComponent } from '../../Compliance/AgGrid/CellRenderers/agGridTooltipCellRenderer.component';\r\nimport {\r\n AppealRecommendationTemplateComponent\r\n} from '../Appeal-Recommendation-Template/appealRecommendationTemplate.component';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { StateService } from '../../Common/States/States.Service';\r\nimport { StateSummary } from '../../Common/States/state.model';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { APPEAL_RECOMMENDATION_COMMAND_CENTER_HELP } from './aRCC.component.help';\r\nimport {\r\n AppealRecommendationCommandCenterBulkUpdateParams,\r\n ARCCBulkUpdateComponent\r\n} from './ARCC-Bulk-Update/aRCCBulkUpdate.component';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport {\r\n AppealRecommendationCommandCenterBulkUpdateResultConfirmationComponentParams,\r\n ARCCBulkUpdateResultConfirmationComponent\r\n} from './ARCC-Bulk-Update/ARCC-Bulk-Update-Result-Confirmation/aRCCBulkUpdateResultConfirmation.component';\r\nimport {\r\n ProcessAppealWarrantedComponent,\r\n ProcessAppealWarrantedParams\r\n} from '../../Processing/Process-Appeal-Warranted-Modal/processAppealWarranted.component';\r\nimport {\r\n ProcessNoAppealComponent,\r\n ProcessNoAppealParams\r\n} from '../../Processing/Process-No-Appeal-Modal/processNoAppeal.component';\r\nimport { TaskModalsService } from '../../Task/taskModals.service';\r\nimport { BulkEditButtonOptions } from '../../Compliance/AgGrid/ToolPanel/agGridToolPanel.component';\r\nimport DescriptorUsageEnum = Core.DescriptorUsageEnum;\r\nimport DescriptorFieldTypes = Core.DescriptorFieldTypes;\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport Guid = System.Guid;\r\n\r\nimport * as moment from 'moment';\r\nimport { UserService } from '../../Account/user.service';\r\n\r\ninterface SelectionValidationResult {\r\n isValid: boolean;\r\n validationMessage: string;\r\n}\r\n\r\n@Component({\r\n selector: 'appeal-recommendation-command-center',\r\n templateUrl: './aRCC.component.html',\r\n styleUrls: ['./aRCC.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ARCCComponent implements OnInit, OnDestroy {\r\n\r\n constructor(\r\n private readonly _appealRecommendationRepository: AppealRecommendationRepository,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _percentPipe: PercentPipe,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _modalService: BsModalService,\r\n private readonly _weissmanModalService: WeissmanModalService,\r\n private readonly _stateService: StateService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private toastr: ToastrService,\r\n private readonly _helpService: HelpService,\r\n private readonly _taskModalService: TaskModalsService,\r\n private readonly _userService: UserService) {\r\n }\r\n\r\n isInitialized: boolean = false;\r\n refreshing: boolean = false;\r\n gridId: System.Guid = 'FDEA0E55-AFE5-40DE-BE50-D85B70ED24EF';\r\n gridTracker: AgGridMultiSelectTracker;\r\n states: StateSummary[] = [];\r\n selectedStates: number[] = [];\r\n appealDeadlineStart: Date;\r\n appealDeadlineEnd: Date;\r\n\r\n //It has to be out of the order as it is used in exportOptions.\r\n private _hasSelectedRows: boolean = false;\r\n private _assignedFilter: Core.AppealRecommendationCCAssignedFilterModel;\r\n private _bypassDateRangeValidation: boolean;\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum, customExportType: number): Promise => {\r\n this._productAnalyticsService.logEvent('click-ARCC-excel-export');\r\n const selectedRowsOrdered: string[]= this._mappingViewData\r\n .filter(x => this._selectedRowIds.indexOf(x.entityId) !== -1)\r\n .map(x => x.entityId);\r\n\r\n const exportModel: Core.AppealRecommendationCCExportModel = {\r\n stateIds: this.selectedStates,\r\n appealDeadlineStart: this.appealDeadlineStart,\r\n appealDeadlineEnd: this.appealDeadlineEnd,\r\n exportType: customExportType,\r\n columnsToReturn: columnsToReturn,\r\n selectedRows: selectedRowsOrdered,\r\n assignedFilter: this._assignedFilter\r\n };\r\n\r\n const lrp$ = this._appealRecommendationRepository.startExport(exportModel);\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportAppealRecommendationCommandCenter };\r\n },\r\n getDisabled: () => !this._hasSelectedRows,\r\n canCancel: true,\r\n showFileFormatSelection: true,\r\n availableFileFormats: [],\r\n customExportFileFormats: [\r\n {\r\n name: 'Sites Only',\r\n value: Core.AppealRecommendationCommandCenterExportTypeEnum.SitesOnly,\r\n isDisabled: () => this._sitesOnlyExportOptionDisabled(),\r\n disabledTooltip: 'Selection does not include sites.'\r\n },\r\n {\r\n name: 'Sites and Parcels',\r\n value: Core.AppealRecommendationCommandCenterExportTypeEnum.SitesAndParcels,\r\n isDisabled: () => this._parcelsOnlyExportOptionDisabled(),\r\n disabledTooltip: 'Selection does not include parcels.'\r\n }\r\n ]\r\n };\r\n\r\n additionalButtons = [{\r\n icon: 'fa-regular fa-envelope',\r\n getTooltipText: () => this._canOpenEmailPreview().validationMessage,\r\n disabled: () => !this._canOpenEmailPreview().isValid,\r\n onClickCallback: () => this._showAppealRecommendationEmailModal()\r\n },\r\n {\r\n icon: 'fa-clipboard-check',\r\n getTooltipText: () => this._canAcceptRecommendation().validationMessage,\r\n disabled: () => !this._canAcceptRecommendation().isValid,\r\n onClickCallback: () => this._acceptRecommendation()\r\n }\r\n ] as AgGridToolPanelButton[];\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as AppealRecommendationGridRowInfoTreeItemModel).entityId),\r\n 'no-filter-applies': (params) => params.data && this._siteRequiredFilterSet.has(params.data.entityId) && !params.data.parcelId,\r\n 'has-error': (params) => params.data && (params.data as AppealRecommendationGridRowInfoTreeItemModel).hasError\r\n },\r\n singleClickEdit: true,\r\n onFilterChanged: (event: FilterChangedEvent) => {\r\n const columnFilters = Object.keys(event.api.getFilterModel());\r\n const columnNames = columnFilters.map(x => event.api.getColumnDef(x).headerName);\r\n this._productAnalyticsService.logEvent('filter-ARCC-column', { arccFilteredColumn: columnNames});\r\n this.gridTracker.onGridFilterChanged();\r\n },\r\n getRowNodeId: (data) => data.entityId,\r\n })\r\n .withColumnResize()\r\n .withLoadingOverlay()\r\n .withContext(this)\r\n .withTextSelection()\r\n .withoutCellEditingStoppedOnGridLostFocus()\r\n .withColumnPinning()\r\n .withSort()\r\n .build();\r\n\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n private _gridApi: GridApi;\r\n private _gridColumnApi: ColumnApi;\r\n private _destroy$: Subject = new Subject();\r\n\r\n private _canExpandAllRows: boolean = true;\r\n\r\n private _expandedSites = new Set();\r\n private _collapsedSites = new Set();\r\n private _filteredOutParcelsMap: Map = new Map();\r\n private _siteRequiredFilterSet: Set = new Set();\r\n private _redrawGrid: boolean = false;\r\n\r\n private _sites: AppealRecommendationGridRowInfoTreeItemModel[] = [];\r\n private _parcels: AppealRecommendationGridRowInfoTreeItemModel[] = [];\r\n private _descriptorInfo: Core.DescriptorInfoModel[] = [];\r\n private _descriptorValues: Core.AppealRecommendationDescriptorValueModel[] = [];\r\n private _picklistInfo: Core.DescriptorPicklistModel[] = [];\r\n private _mappingViewData: AppealRecommendationGridRowInfoTreeItemModel[] = [];\r\n private _appealRecommendationStatuses: Core.AppealRecommendationStatusModel[];\r\n private _selectedRowIds: string[] = [];\r\n private _searchTimestamp: Date;\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(APPEAL_RECOMMENDATION_COMMAND_CENTER_HELP);\r\n\r\n this.appealDeadlineStart = new Date();\r\n this.appealDeadlineEnd = this._addDays(new Date(), 45);\r\n\r\n if (!this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW) && !this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT)) {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Loading'});\r\n\r\n try {\r\n const [descriptorMetadata, statuses, states] = await Promise.all([\r\n lastValueFrom(this._appealRecommendationRepository.getDescriptorMetadata()),\r\n lastValueFrom(this._appealRecommendationRepository.getAppealRecommendationStatuses()),\r\n this._stateService.getSummary()\r\n ]);\r\n\r\n this._descriptorInfo = descriptorMetadata.descriptors;\r\n this._picklistInfo = descriptorMetadata.pickList;\r\n this._appealRecommendationStatuses = statuses.sort((x, y) => x.id - y.id);\r\n this.states = states.filter(x => x.countryID === 1);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n const user = this._userService.getUser();\r\n this._bypassDateRangeValidation = user.id === 'e99b97e6-f6af-4cad-85d8-0025e8837125';\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n get isRefreshDisabled(): boolean {\r\n return !this.isInitialized || this.selectedStates.length === 0;\r\n }\r\n\r\n onAssignedFilterChange(value: Core.AppealRecommendationCCAssignedFilterModel) {\r\n this._assignedFilter = value;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n // get API objects and start setting up the AgGrid\r\n this._gridApi = event.api;\r\n this._gridColumnApi = event.columnApi;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this.gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe(async () => {\r\n const hasSelectedRows = this.gridTracker.hasSelectedRows();\r\n\r\n const isBulkUpdateVisible = BulkEditButtonOptions.Create({\r\n show: hasSelectedRows\r\n });\r\n\r\n if (isBulkUpdateVisible) {\r\n const selectedRows = await this.gridTracker.getSelectedRowIds();\r\n const selectedEntityIds = selectedRows.map(x => x.toString());\r\n\r\n const disableBulkUpdate = !this._getCanChangeAppealRecommendationStatus(selectedEntityIds) &&\r\n !this._getCanChangeIsClientApproved(selectedEntityIds) &&\r\n this._getVisibleDescriptorInfo().length === 0;\r\n\r\n if (disableBulkUpdate) {\r\n isBulkUpdateVisible.disable = true;\r\n isBulkUpdateVisible.toolTipId = 'ag-grid-tool-panel.bulk-update-empty';\r\n }\r\n }\r\n\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n this._hasSelectedRows = hasSelectedRows;\r\n const selectedRows = await this.gridTracker.getSelectedRowIds();\r\n\r\n this._selectedRowIds = selectedRows.map(x => x.toString());\r\n });\r\n\r\n this._setColumns();\r\n this._setRowData(true);\r\n }\r\n\r\n getDescriptorValue = (model: AppealRecommendationGridRowInfoTreeItemModel, descriptor: Core.DescriptorInfoModel): any => {\r\n if (model) {\r\n return this._getDescriptorValue(model.siteId, model.parcelId, descriptor.descriptorId, descriptor.fieldType);\r\n }\r\n };\r\n\r\n onAgGridFilterChanged(event: FilterChangedEvent) {\r\n const filters = event.api.getFilterModel();\r\n let numberExpanded = 0;\r\n const hadRequiredSites = this._siteRequiredFilterSet.size;\r\n\r\n this._siteRequiredFilterSet.clear();\r\n\r\n if (!Object.keys(filters).length) {\r\n this._setRowData();\r\n return;\r\n }\r\n\r\n this._collapsedSites.forEach((entityId: string) => {\r\n const site = this._sites.find(x => x.entityId === entityId);\r\n\r\n if (!site) {\r\n this._collapsedSites.delete(entityId);\r\n return;\r\n }\r\n\r\n const expandSites: string[] = [];\r\n\r\n for (const fieldName in filters) {\r\n const filter = filters[fieldName].filterValues[0];\r\n const filterMethod = filter.filterType.displayKey;\r\n const filterValue = filter.filterValue;\r\n\r\n switch (fieldName) {\r\n case 'entityName':\r\n case 'responsibleUser':\r\n case 'state':\r\n case 'assessorName':\r\n case 'class':\r\n case 'propertyType':\r\n case 'accountHandler':\r\n case 'companyName':\r\n case 'revisionName':\r\n case 'team':\r\n case 'topLevelCompanyName':\r\n case 'priorYearAppeal':\r\n case 'appealLevel':\r\n case 'assesseeName':\r\n if (this._filterString(fieldName, filterMethod, site[fieldName], filterValue, site)) {\r\n expandSites.push(site.entityId);\r\n }\r\n break;\r\n case 'appealDeadline':\r\n case 'createDate':\r\n case 'emailSentDate':\r\n if (this._filterDate(fieldName, filterMethod, this._datePipe.transform(site[fieldName], false, 'central'), filterValue, site)) {\r\n expandSites.push(site.entityId);\r\n }\r\n break;\r\n case 'taxYear':\r\n case 'originalFMV':\r\n case 'currentFMV':\r\n case 'priorYearFMV':\r\n case 'targetValue':\r\n case 'originalLandFMV':\r\n case 'originalImpsFMV':\r\n case 'originalPersFMV':\r\n case 'originalAltFMV':\r\n case 'currentLandFMV':\r\n case 'currentImpsFMV':\r\n case 'currentPersFMV':\r\n case 'currentAltFMV':\r\n case 'priorYearLandFMV':\r\n case 'priorYearImpsFMV':\r\n case 'priorYearPersFMV':\r\n case 'priorYearAltFMV':\r\n case 'originalAV':\r\n case 'originalLandAV':\r\n case 'originalImpsAV':\r\n case 'originalPersAV':\r\n case 'originalAltAV':\r\n case 'currentAV':\r\n case 'currentLandAV':\r\n case 'currentImpsAV':\r\n case 'currentPersAV':\r\n case 'currentAltAV':\r\n case 'priorYearAV':\r\n case 'priorYearLandAV':\r\n case 'priorYearImpsAV':\r\n case 'priorYearPersAV':\r\n case 'priorYearAltAV':\r\n case 'savings':\r\n case 'totalDollarSqFt':\r\n case 'totalDollarUnit':\r\n case 'totalLandDollarAcre':\r\n case 'totalLandDollarSqFt':\r\n case 'totalPriorYearDollarSqFt':\r\n case 'totalPriorYearDollarUnit':\r\n case 'totalPriorYearLandDollarAcre':\r\n case 'totalPriorYearLandDollarSqFt':\r\n if (this._filterNumber(fieldName, filterMethod, site[fieldName], filterValue, site)) {\r\n expandSites.push(site.entityId);\r\n }\r\n break;\r\n case 'isReady':\r\n if (this._filterBoolean(fieldName, filterMethod, site[fieldName].toString(), filterValue, site)) {\r\n expandSites.push(site.entityId);\r\n }\r\n break;\r\n case 'fmvVariance':\r\n if (this._filterPercent(fieldName, filterMethod, site[fieldName], filterValue, site)) {\r\n expandSites.push(site.entityId);\r\n }\r\n break;\r\n default:\r\n if (fieldName.startsWith('d.')){\r\n const descriptorId = +fieldName.substring(2);\r\n const descriptorInfo = this._descriptorInfo.find(x => x.descriptorId === descriptorId);\r\n const descriptorValue = this._descriptorValues.find(x =>\r\n x.siteId === site.siteId && x.parcelId === 0 && x.descriptorId === descriptorId);\r\n\r\n if (!descriptorValue) {\r\n break;\r\n }\r\n\r\n switch (descriptorInfo.fieldType) {\r\n case DescriptorFieldTypes.Text:\r\n case DescriptorFieldTypes.Picklist:\r\n if (this._filterString(fieldName, filterMethod, descriptorValue.value, filterValue, site)) {\r\n expandSites.push(site.entityId);\r\n }\r\n break;\r\n case DescriptorFieldTypes.Currency:\r\n case DescriptorFieldTypes.Number:\r\n if (this._filterNumber(fieldName, filterMethod, descriptorValue.value, +filterValue, site)) {\r\n expandSites.push(site.entityId);\r\n }\r\n break;\r\n case DescriptorFieldTypes.YesNo:\r\n if (this._filterBoolean(fieldName, filterMethod, descriptorValue.value, filterValue, site)) {\r\n expandSites.push(site.entityId);\r\n }\r\n break;\r\n case DescriptorFieldTypes.Date:\r\n if (this._filterDate(fieldName, filterMethod, descriptorValue.value, filterValue, site)) {\r\n expandSites.push(site.entityId);\r\n }\r\n break;\r\n }\r\n }\r\n break;\r\n }\r\n }\r\n\r\n expandSites.every(x => {\r\n this._collapsedSites.delete(x);\r\n this._expandedSites.add(x);\r\n numberExpanded++;\r\n });\r\n });\r\n\r\n if (numberExpanded > 0 || hadRequiredSites > 0 || this._redrawGrid) {\r\n this._setRowData();\r\n }\r\n }\r\n\r\n onAgGridSortChanged() {\r\n if (this._gridApi) {\r\n this._setRowData();\r\n }\r\n }\r\n\r\n reports() {\r\n alert('Coming soon');\r\n }\r\n\r\n emitStateAnalyticsEvent(states: string[]): void {\r\n this._productAnalyticsService.logEvent('select-state', { arccState: states });\r\n }\r\n\r\n emitDateAnalyticsEvent(date: Date, event: string): void {\r\n const today = moment(new Date());\r\n const selection = moment(date);\r\n const params = (event === 'enter-begin-date')\r\n ? { arccBeginDate: selection.diff(today, 'days') }\r\n : { arccEndDate: selection.diff(today, 'days') };\r\n this._productAnalyticsService.logEvent(event, params);\r\n }\r\n\r\n layoutChanged(): void {\r\n this._productAnalyticsService.logEvent('select-custom-layout');\r\n }\r\n\r\n async refresh(): Promise{\r\n await this._loadData();\r\n this._setRowData();\r\n }\r\n\r\n async bulkUpdate(): Promise {\r\n const selectedRows = await this.gridTracker.getSelectedRowIds();\r\n const selectedEntityIds = selectedRows.map(x => x.toString());\r\n const selectedSiteIds = selectedEntityIds\r\n .filter(x => x[0] === 'S')\r\n .map(x => +x.substring(1, x.length - 5));\r\n\r\n const params: AppealRecommendationCommandCenterBulkUpdateParams = {\r\n selectedRowsInfo: this._mappingViewData\r\n .filter(x => selectedEntityIds.includes(x.entityId))\r\n .map(x => {\r\n return {\r\n siteId: x.siteId,\r\n parcelId: x.parcelId,\r\n taxYear: x.taxYear,\r\n annualAssessmentId: x.annualAssessmentId\r\n } as Core.AppealRecommendationBulkUpdateRowInfoModel;\r\n }),\r\n canChangeAppealRecommendationStatus: this._getCanChangeAppealRecommendationStatus(selectedEntityIds),\r\n canChangeIsClientApproved: this._getCanChangeIsClientApproved(selectedEntityIds),\r\n stateIds: this.selectedStates,\r\n appealDeadlineStart: this.appealDeadlineStart,\r\n appealDeadlineEnd: this.appealDeadlineEnd,\r\n assignedFilter: this._assignedFilter,\r\n descriptorInfo: this._getVisibleDescriptorInfo(),\r\n picklistInfo: this._picklistInfo,\r\n appealRecommendationStatuses: this._appealRecommendationStatuses,\r\n selectedSiteAnnualAssessmentIds: this._parcels\r\n .filter(x => selectedSiteIds.includes(x.siteId))\r\n .map(x => x.annualAssessmentId)\r\n };\r\n\r\n const result = await this._weissmanModalService.showAsync(ARCCBulkUpdateComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (result.ignoredSites.length !== 0) {\r\n const resultsParams: AppealRecommendationCommandCenterBulkUpdateResultConfirmationComponentParams = {\r\n ignoredSites: result.ignoredSites\r\n };\r\n\r\n await this._weissmanModalService.showAsync(ARCCBulkUpdateResultConfirmationComponent, resultsParams, 'modal-sd');\r\n }\r\n\r\n this.gridTracker.clear();\r\n await this.refresh();\r\n }\r\n\r\n private async _loadData() {\r\n if (!this.appealDeadlineStart || !this.appealDeadlineEnd) {\r\n this.toastr.error('Appeal Deadline date is required');\r\n } else if (this.appealDeadlineEnd > this._addDays(new Date(), 120) && !this._bypassDateRangeValidation) {\r\n this.toastr.error('Appeal Deadline may not exceed 120 days in the future.');\r\n } else if (this.appealDeadlineStart < this._addDays(new Date(), - 30) && !this._bypassDateRangeValidation) {\r\n this.toastr.error('Appeal Deadline may not exceed 30 days in the past.');\r\n } else if (this.selectedStates.length !== 0) {\r\n const busyRef = this._busyIndicatorService.show({message: 'Loading'});\r\n\r\n const searchModel: Core.AppealRecommendationCCSearchModel = {\r\n stateIds: this.selectedStates,\r\n appealDeadlineStart: this.appealDeadlineStart,\r\n appealDeadlineEnd: this.appealDeadlineEnd,\r\n assignedFilter: this._assignedFilter\r\n };\r\n\r\n try {\r\n const data = await lastValueFrom(this._appealRecommendationRepository.getList(searchModel));\r\n\r\n this._sites = data.siteInfo.map(x => new AppealRecommendationGridRowInfoTreeItemModel(x));\r\n this._parcels = data.parcelInfo.map(x => new AppealRecommendationGridRowInfoTreeItemModel(x));\r\n this._descriptorValues = data.descriptorValues;\r\n this._searchTimestamp = data.searchTimeStamp;\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n }\r\n\r\n private _getVisibleDescriptorInfo() {\r\n const displayedDescriptorColumns = this.gridOptions.columnApi.getAllDisplayedColumns()\r\n .filter(x => x.getColId().startsWith('d.'))\r\n .map(x => +x.getColId().substring(2));\r\n\r\n return this._descriptorInfo\r\n .filter(x => displayedDescriptorColumns.indexOf(x.descriptorId) !== -1);\r\n }\r\n\r\n private _getCanChangeIsClientApproved(selectedEntityIds: string[]) {\r\n return this._mappingViewData\r\n .filter(x => selectedEntityIds.includes(x.entityId) && !x.parcelId).some(x => x.isClientApprovalRequired);\r\n }\r\n\r\n private _getCanChangeAppealRecommendationStatus(selectedEntityIds: string[]) {\r\n return this._mappingViewData\r\n .filter(x => selectedEntityIds.includes(x.entityId) && !x.parcelId)\r\n .some(x => x.appealRecommendationStatusId !== +Core.AppealRecommendationStatusEnum.Appeal &&\r\n x.appealRecommendationStatusId !== +Core.AppealRecommendationStatusEnum.NoAppeal);\r\n }\r\n\r\n private _setRowData(firstLoad: boolean = false): void {\r\n if (!this._gridApi || !this.isInitialized) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._populateMappingViewData());\r\n\r\n if (firstLoad) {\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n this._redrawGrid = false;\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n }\r\n\r\n private _populateMappingViewData() {\r\n this._mappingViewData = [];\r\n const sortModel = this._gridApi.getSortModel();\r\n\r\n if (!Object.keys(sortModel).length) {\r\n sortModel[0] = {\r\n colId: 'entityName',\r\n sort: 'asc'};\r\n }\r\n\r\n const colId = sortModel[0].colId;\r\n const sort = sortModel[0].sort;\r\n\r\n let sortFunction: (x: any, y: any, sort: string) => number;\r\n\r\n switch (colId) {\r\n case 'entityName':\r\n case 'responsibleUser':\r\n case 'state':\r\n case 'assessorName':\r\n case 'class':\r\n case 'propertyType':\r\n case 'accountHandler':\r\n case 'companyName':\r\n case 'revisionName':\r\n case 'team':\r\n case 'topLevelCompanyName':\r\n case 'appealRecommendationStatus':\r\n case 'priorYearAppeal':\r\n case 'appealLevel':\r\n case 'assesseeName':\r\n sortFunction = (x: string = '', y : string = '', s: string) => s === 'asc' ? (x || '').localeCompare(y) : (y || '').localeCompare(x);\r\n break;\r\n case 'appealDeadline':\r\n case 'createDate':\r\n case 'emailSentDate':\r\n sortFunction = (x: Date = new Date(0), y : Date = new Date(0), s: string) => s === 'asc' ? (x || new Date()).getTime() - (y || new Date()).getTime() : (y || new Date()).getTime() - (x || new Date()).getTime();\r\n break;\r\n case 'taxYear':\r\n case 'originalFMV':\r\n case 'currentFMV':\r\n case 'priorYearFMV':\r\n case 'targetValue':\r\n case 'originalLandFMV':\r\n case 'originalImpsFMV':\r\n case 'originalPersFMV':\r\n case 'originalAltFMV':\r\n case 'currentLandFMV':\r\n case 'currentImpsFMV':\r\n case 'currentPersFMV':\r\n case 'currentAltFMV':\r\n case 'priorYearLandFMV':\r\n case 'priorYearImpsFMV':\r\n case 'priorYearPersFMV':\r\n case 'priorYearAltFMV':\r\n case 'originalAV':\r\n case 'originalLandAV':\r\n case 'originalImpsAV':\r\n case 'originalPersAV':\r\n case 'originalAltAV':\r\n case 'currentAV':\r\n case 'currentLandAV':\r\n case 'currentImpsAV':\r\n case 'currentPersAV':\r\n case 'currentAltAV':\r\n case 'priorYearAV':\r\n case 'priorYearLandAV':\r\n case 'priorYearImpsAV':\r\n case 'priorYearPersAV':\r\n case 'priorYearAltAV':\r\n case 'savings':\r\n case 'totalDollarSqFt':\r\n case 'totalDollarUnit':\r\n case 'totalLandDollarAcre':\r\n case 'totalLandDollarSqFt':\r\n case 'totalPriorYearDollarSqFt':\r\n case 'totalPriorYearDollarUnit':\r\n case 'totalPriorYearLandDollarAcre':\r\n case 'totalPriorYearLandDollarSqFt':\r\n case 'fmvVariance':\r\n sortFunction = (x: number = 0, y : number = 0, s: string) => s === 'asc' ? x - y : y - x;\r\n break;\r\n case 'isReady':\r\n sortFunction = (x: string = '', y : string = '', s: string) => s === 'asc' ? (x || '').toString().localeCompare(y) : (y || '').toString().localeCompare(x);\r\n break;\r\n case 'isClientApproved':\r\n sortFunction = (x: boolean | string, y: boolean | string, s: string) => {\r\n const localX = typeof x === 'boolean' ? x : x === 'true';\r\n const localY = typeof y === 'boolean' ? y : y === 'true';\r\n const result = s === 'asc' ? Number(localX) - Number(localY) : Number(localY) - Number(localX);\r\n return result;\r\n };\r\n break;\r\n default:\r\n if (colId.startsWith('d.')){\r\n const descriptorId = +colId.substring(2);\r\n const descriptorInfo = this._descriptorInfo.find(x => x.descriptorId === descriptorId);\r\n\r\n switch (descriptorInfo.fieldType) {\r\n case DescriptorFieldTypes.Text:\r\n case DescriptorFieldTypes.Picklist:\r\n case DescriptorFieldTypes.YesNo:\r\n sortFunction = (x: string = '', y : string = '', s: string) => s === 'asc' ? (x || '').toString().localeCompare(y) : (y || '').toString().localeCompare(x);\r\n break;\r\n case DescriptorFieldTypes.Currency:\r\n case DescriptorFieldTypes.Number:\r\n sortFunction = (x: number = 0, y : number = 0, s: string) => s === 'asc' ? x - y : y - x;\r\n break;\r\n case DescriptorFieldTypes.Date:\r\n sortFunction = (x: Date = new Date(0), y : Date = new Date(0), s: string) => s === 'asc' ? x.getTime() - y.getTime() : y.getTime() - x.getTime();\r\n break;\r\n }\r\n }\r\n break;\r\n }\r\n\r\n this._sites\r\n .sort((x, y) =>\r\n {\r\n let xValue = x[sortModel[0].colId];\r\n let yValue = y[sortModel[0].colId];\r\n\r\n if (colId.startsWith('d.')) {\r\n const descriptorId = +colId.substring(2);\r\n xValue = this._getDescriptorValue(x.siteId, 0, descriptorId);\r\n yValue = this._getDescriptorValue(y.siteId, 0, descriptorId);\r\n }\r\n return sortFunction(xValue, yValue, sort);\r\n })\r\n .forEach(site => {\r\n this._mappingViewData.push(site);\r\n if (this._expandedSites.has(site.entityId)) {\r\n this._parcels\r\n .filter(parcel => parcel.siteId === site.siteId && parcel.taxYear === site.taxYear)\r\n .sort((x, y) => {\r\n const id = sortModel[0].colId === 'appealRecommendationStatus'\r\n ? 'entityName'\r\n : sortModel[0].colId;\r\n const sortDirection = sortModel[0].colId === 'appealRecommendationStatus'\r\n ? 'asc'\r\n : sort;\r\n\r\n let xValue = x[id];\r\n let yValue = y[id];\r\n\r\n if (id.startsWith('d.')) {\r\n const descriptorId = +id.substring(2);\r\n xValue = this._getDescriptorValue(x.siteId, x.parcelId, descriptorId);\r\n yValue = this._getDescriptorValue(y.siteId, y.parcelId, descriptorId);\r\n }\r\n return sortFunction(xValue, yValue, sortDirection);\r\n })\r\n .forEach((parcel) => {\r\n this._mappingViewData.push(parcel);\r\n });\r\n } else {\r\n this._collapsedSites.add(site.entityId);\r\n }\r\n });\r\n\r\n return this._mappingViewData;\r\n }\r\n\r\n private _expand(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!item) {\r\n return;\r\n }\r\n\r\n this._expandedSites.add(item.entityId);\r\n this._collapsedSites.delete(item.entityId);\r\n this._setRowData();\r\n }\r\n\r\n private _collapse(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!item) {\r\n return;\r\n }\r\n\r\n this._expandedSites.delete(item.entityId);\r\n this._collapsedSites.add(item.entityId);\r\n this._setRowData();\r\n }\r\n\r\n private _showHiddenParcels(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!item) {\r\n return;\r\n }\r\n\r\n // expand node if collapsed\r\n if (this._collapsedSites.has(item.entityId)) {\r\n this._expandedSites.add(item.entityId);\r\n this._collapsedSites.delete(item.entityId);\r\n }\r\n\r\n this._setRowData();\r\n }\r\n\r\n private _canExpand(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!item) {\r\n return false;\r\n }\r\n\r\n return !item.parcelId && this._collapsedSites.has(item.entityId);\r\n }\r\n\r\n private _canCollapse(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!item) {\r\n return false;\r\n }\r\n\r\n return !item.parcelId && this._expandedSites.has(item.entityId);\r\n }\r\n\r\n private _canShowHiddenParcels(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!item || this._collapsedSites.has(item.entityId)) {\r\n return false;\r\n }\r\n return this._filteredOutParcelsMap.has(item.siteId);\r\n }\r\n\r\n private _canExpandAll(): boolean {\r\n return this._canExpandAllRows;\r\n }\r\n\r\n private _canCollapseAll(params: ICellRendererParamsForExpandCellHeaderParams): boolean {\r\n return !this._canExpandAllRows;\r\n }\r\n\r\n private _expandAll(params: ICellRendererParamsForExpandCellHeaderParams): void {\r\n this._sites.forEach(site => {\r\n if (this._collapsedSites.has(site.entityId)) {\r\n this._expandedSites.add(site.entityId);\r\n this._collapsedSites.delete(site.entityId);\r\n }\r\n });\r\n\r\n this._setRowData();\r\n\r\n this._canExpandAllRows = false;\r\n }\r\n\r\n private _collapseAll(params: ICellRendererParamsForExpandCellHeaderParams): void {\r\n this._sites.forEach(site => {\r\n if (this._expandedSites.has(site.entityId)) {\r\n this._expandedSites.delete(site.entityId);\r\n this._collapsedSites.add(site.entityId);\r\n }\r\n });\r\n\r\n this._setRowData();\r\n\r\n this._canExpandAllRows = true;\r\n }\r\n\r\n private _filterString(fieldName: string, filter: string, gridValue: any, filterText: string, rowData?: AppealRecommendationGridRowInfoTreeItemModel): boolean {\r\n const filterPassed = this._filterCheckStringValue(filter, gridValue, filterText);\r\n let someParcelsPass: boolean = false;\r\n\r\n if (!rowData.parcelId) {\r\n someParcelsPass = this._parcels\r\n .filter(parcel => parcel.siteId == rowData.siteId && parcel.taxYear === rowData.taxYear)\r\n .some(parcel =>\r\n fieldName === 'appealRecommendationStatus' && filterPassed ||\r\n this._filterString(fieldName, filter, parcel[fieldName], filterText, parcel));\r\n\r\n if (rowData && !filterPassed && someParcelsPass) {\r\n this._siteRequiredFilterSet.add(rowData.entityId);\r\n } else if (rowData && this._siteRequiredFilterSet.has(rowData.entityId)) {\r\n this._siteRequiredFilterSet.delete(rowData.entityId);\r\n this._redrawGrid = true;\r\n }\r\n } else if (fieldName === 'appealRecommendationStatus') {\r\n const siteNode = this._gridApi.getRowNode(`S${rowData.siteId}`);\r\n }\r\n\r\n return filterPassed || someParcelsPass;\r\n }\r\n\r\n private _filterDate(fieldName: string, filter: string, gridValue: any, filterText: string, rowData?: AppealRecommendationGridRowInfoTreeItemModel): boolean {\r\n const filterPassed = this._filterCheckDateValue(filter, gridValue, filterText);\r\n let someParcelsPass: boolean = false;\r\n\r\n if (!rowData.parcelId) {\r\n someParcelsPass = this._parcels\r\n .filter(parcel => parcel.siteId == rowData.siteId && parcel.taxYear === rowData.taxYear)\r\n .some(parcel => this._filterDate(fieldName, filter, this._datePipe.transform(parcel[fieldName], false, 'central'), filterText, parcel));\r\n\r\n if (rowData && !filterPassed && someParcelsPass) {\r\n this._siteRequiredFilterSet.add(rowData.entityId);\r\n } else if (rowData && this._siteRequiredFilterSet.has(rowData.entityId)) {\r\n this._siteRequiredFilterSet.delete(rowData.entityId);\r\n this._redrawGrid = true;\r\n }\r\n }\r\n\r\n return filterPassed || someParcelsPass;\r\n }\r\n\r\n private _filterNumber(fieldName: string, filter: string, gridValue: any, filterText: number, rowData?: AppealRecommendationGridRowInfoTreeItemModel): boolean {\r\n const filterPassed = this._filterCheckNumberValue(filter, gridValue, filterText);\r\n let someParcelsPass: boolean = false;\r\n\r\n if (!rowData.parcelId) {\r\n someParcelsPass = this._parcels\r\n .filter(parcel => parcel.siteId == rowData.siteId && parcel.taxYear === rowData.taxYear)\r\n .some(parcel => {\r\n let result: boolean;\r\n\r\n if (fieldName.startsWith('d.')) {\r\n const descriptorValue = this._descriptorValues.find(x => x.parcelId == parcel.parcelId &&\r\n x.descriptorId == +fieldName.substring(2));\r\n\r\n result = descriptorValue && this._filterNumber(fieldName, filter, descriptorValue.value, filterText, parcel);\r\n } else {\r\n result = this._filterNumber(fieldName, filter, parcel[fieldName], filterText, parcel);\r\n }\r\n\r\n return result;\r\n });\r\n\r\n if (rowData && !filterPassed && someParcelsPass) {\r\n this._siteRequiredFilterSet.add(rowData.entityId);\r\n } else if (rowData && this._siteRequiredFilterSet.has(rowData.entityId)) {\r\n this._siteRequiredFilterSet.delete(rowData.entityId);\r\n this._redrawGrid = true;\r\n }\r\n }\r\n\r\n return filterPassed || someParcelsPass;\r\n }\r\n\r\n private _filterPercent(fieldName: string, filter: string, gridValue: any, filterText: number, rowData?: AppealRecommendationGridRowInfoTreeItemModel): boolean {\r\n const filterPassed = this._filterCheckPercentValue(filter, gridValue, +filterText);\r\n let someParcelsPass: boolean = false;\r\n\r\n if (!rowData.parcelId) {\r\n someParcelsPass = this._parcels\r\n .filter(parcel => parcel.siteId == rowData.siteId && parcel.taxYear === rowData.taxYear)\r\n .some(parcel => {\r\n let result: boolean;\r\n\r\n if (fieldName.startsWith('d.')) {\r\n const descriptorValue = this._descriptorValues.find(x => x.parcelId == parcel.parcelId &&\r\n x.descriptorId == +fieldName.substring(2));\r\n\r\n result = descriptorValue && this._filterPercent(fieldName, filter, descriptorValue.value, filterText, parcel);\r\n } else {\r\n result = this._filterPercent(fieldName, filter, parcel[fieldName], filterText, parcel);\r\n }\r\n\r\n return result;\r\n });\r\n\r\n if (rowData && !filterPassed && someParcelsPass) {\r\n this._siteRequiredFilterSet.add(rowData.entityId);\r\n } else if (rowData && this._siteRequiredFilterSet.has(rowData.entityId)) {\r\n this._siteRequiredFilterSet.delete(rowData.entityId);\r\n this._redrawGrid = true;\r\n }\r\n }\r\n\r\n return filterPassed || someParcelsPass;\r\n }\r\n\r\n private _filterBoolean(fieldName: string, filter: string, gridValue: any, filterText: number, rowData?: AppealRecommendationGridRowInfoTreeItemModel): boolean {\r\n //TODO: For some reason, this method called multiple times for the same parcel and the last call has \"\" as the gridValue.\r\n // So, we cannot use it and have to use the rowData property\r\n const filterPassed = this._filterCheckBooleanValue(filter, gridValue);\r\n let someParcelsPass: boolean = false;\r\n\r\n if (!rowData.parcelId) {\r\n someParcelsPass = this._parcels\r\n .filter(parcel => parcel.siteId == rowData.siteId && parcel.taxYear === rowData.taxYear)\r\n .some(parcel => {\r\n let result: boolean;\r\n\r\n if (fieldName.startsWith('d.')) {\r\n const descriptorValue = this._descriptorValues.find(x => x.parcelId == parcel.parcelId &&\r\n x.descriptorId == +fieldName.substring(2));\r\n\r\n result = descriptorValue && this._filterBoolean(fieldName, filter, descriptorValue.value, filterText, parcel);\r\n } else {\r\n result = this._filterBoolean(fieldName, filter, parcel[fieldName], filterText, parcel);\r\n }\r\n\r\n return result;\r\n });\r\n\r\n if (rowData && !filterPassed && someParcelsPass) {\r\n this._siteRequiredFilterSet.add(rowData.entityId);\r\n } else if (rowData && this._siteRequiredFilterSet.has(rowData.entityId)) {\r\n this._siteRequiredFilterSet.delete(rowData.entityId);\r\n this._redrawGrid = true;\r\n }\r\n }\r\n\r\n return filterPassed || someParcelsPass;\r\n }\r\n\r\n private _filterCheckStringValue(method: string, sourceString: string, matchString: string): boolean {\r\n const sourceCompare = (sourceString || '').toLowerCase();\r\n const matchCompare = (matchString || '').toLowerCase();\r\n\r\n switch (method) {\r\n case 'startsWith':\r\n return sourceCompare.startsWith(matchCompare);\r\n case 'equals':\r\n return sourceCompare === matchCompare;\r\n case 'notEqual':\r\n return sourceCompare !== matchCompare;\r\n case 'contains':\r\n return sourceCompare.includes(matchCompare);\r\n case 'notContains':\r\n return !sourceCompare.includes(matchCompare);\r\n case 'endsWith':\r\n return sourceCompare.endsWith(matchCompare);\r\n case AgGridFilterParams.blankFilterOptionDef.displayKey:\r\n return sourceString.length === 0;\r\n case AgGridFilterParams.notBlankFilterOptionDef.displayKey:\r\n return sourceString.length > 0;\r\n\r\n }\r\n\r\n return false;\r\n }\r\n\r\n private _filterCheckDateValue(method: string, source: string, match: string): boolean {\r\n const sourceDate = source ? Date.parse(source) : new Date(1, 1, 1);\r\n const matchDate = match ? Date.parse(match) : new Date(1, 1, 1);\r\n switch (method) {\r\n case 'equals':\r\n return sourceDate === matchDate;\r\n case 'notEqual':\r\n return sourceDate !== matchDate;\r\n case 'lessThan':\r\n return sourceDate < matchDate;\r\n case 'greaterThan':\r\n return sourceDate > matchDate;\r\n case 'blank':\r\n return !source;\r\n case 'notBlank':\r\n return !!source && source !== '' && source !== 'Invalid date';\r\n }\r\n\r\n return false;\r\n }\r\n\r\n private _filterCheckNumberValue(method: string, source: number, match: number): boolean {\r\n switch (method) {\r\n case 'equals':\r\n return +source === +match;\r\n case 'notEqual':\r\n return +source !== +match;\r\n case 'lessThan':\r\n return +source < +match;\r\n case 'greaterThan':\r\n return +source > +match;\r\n }\r\n\r\n return false;\r\n }\r\n\r\n private _filterCheckPercentValue(method: string, source: number, match: number): boolean {\r\n const fixedSource = (source * 100).toFixed(2);\r\n\r\n switch (method) {\r\n case 'equals':\r\n return +fixedSource === +match;\r\n case 'notEqual':\r\n return +fixedSource !== +match;\r\n case 'lessThan':\r\n return +fixedSource < +match;\r\n case 'greaterThan':\r\n return +fixedSource > +match;\r\n }\r\n\r\n return false;\r\n }\r\n\r\n private _filterCheckBooleanValue(method: string, source: string): boolean {\r\n switch (method) {\r\n case AgGridFilterParams.yesOptionDef.displayKey:\r\n return ['yes', 'true'].indexOf((source || '').toString()) !== -1;\r\n case AgGridFilterParams.noOptionDef.displayKey:\r\n return ['no', 'false'].indexOf((source || '').toString()) !== -1;\r\n case AgGridFilterParams.blankFilterOptionDef.displayKey:\r\n return true;\r\n }\r\n\r\n return false;\r\n }\r\n\r\n private _getGridRowIds(skip: number, take: number): Compliance.QueryResultModel {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return {\r\n data: rows.map((x) => {\r\n const row = x.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n return row && row.entityId;\r\n })\r\n } as Compliance.QueryResultModel;\r\n }\r\n\r\n private async _updateDescriptor(params: ICellEditorParams, updatedValue: any, descriptor: Core.DescriptorInfoModel): Promise {\r\n const data = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!data) {\r\n return Promise.resolve();\r\n }\r\n\r\n const initialValue = params.value;\r\n if (updatedValue === initialValue) {\r\n return Promise.resolve();\r\n }\r\n\r\n const updateModel: Core.AppealRecommendationCommandCenterUpdateDescriptorModel = {\r\n siteId: data.siteId,\r\n parcelId: data.parcelId,\r\n force: false,\r\n descriptorId: descriptor.descriptorId,\r\n descriptorValue: updatedValue,\r\n taxYear: data.taxYear,\r\n stateIds: this.selectedStates,\r\n assignedFilter: this._assignedFilter,\r\n appealDeadlineStart: this.appealDeadlineStart,\r\n appealDeadlineEnd: this.appealDeadlineEnd\r\n };\r\n\r\n let busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n\r\n let result: Core.AppealRecommendationCommandCenterUpdateDescriptorResultModel = null;\r\n\r\n try {\r\n result = await lastValueFrom(this._appealRecommendationRepository.updateDescriptor(updateModel));\r\n } catch (e) {\r\n // service returns a 422 and a message if the user confirmation needed to force update\r\n if (e && e.status !== 422) {\r\n return Promise.reject(e);\r\n }\r\n await busyRef.hide();\r\n\r\n try {\r\n await this._messageModalService.confirm(e.error.message, `Confirm ${descriptor.name} Exception`);\r\n } catch (cancel) {\r\n // revert the cell value\r\n params.node.setDataValue(params.column.getColId(), params.value);\r\n return await Promise.reject(e);\r\n }\r\n\r\n busyRef = this._busyIndicatorService.show({message: 'Loading'});\r\n\r\n updateModel.force = true;\r\n result = await lastValueFrom(this._appealRecommendationRepository.updateDescriptor(updateModel));\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n if (result) {\r\n if (result.updatedSiteInfo) {\r\n const nodes = [];\r\n\r\n const sites = this._sites\r\n .filter(x => x.siteId == result.updatedSiteInfo.siteId && x.taxYear === data.taxYear);\r\n\r\n sites.forEach(x => {\r\n x.totalDollarSqFt = result.updatedSiteInfo.totalDollarSqFt;\r\n x.totalDollarUnit = result.updatedSiteInfo.totalDollarUnit;\r\n x.totalLandDollarAcre = result.updatedSiteInfo.totalLandDollarAcre;\r\n x.totalLandDollarSqFt = result.updatedSiteInfo.totalLandDollarSqFt;\r\n x.totalPriorYearDollarSqFt = result.updatedSiteInfo.totalPriorYearDollarSqFt;\r\n x.totalPriorYearDollarUnit = result.updatedSiteInfo.totalPriorYearDollarUnit;\r\n x.totalPriorYearLandDollarAcre = result.updatedSiteInfo.totalPriorYearLandDollarAcre;\r\n x.totalPriorYearLandDollarSqFt = result.updatedSiteInfo.totalPriorYearLandDollarSqFt;\r\n nodes.push(this._gridApi.getRowNode(x.entityId));\r\n\r\n params.node.setData(x);\r\n });\r\n }\r\n\r\n const descriptorValue = this._descriptorValues\r\n .find(x =>\r\n x.siteId === data.siteId &&\r\n x.parcelId === data.parcelId &&\r\n x.descriptorId === descriptor.descriptorId);\r\n if (descriptorValue) {\r\n descriptorValue.value = updatedValue;\r\n } else {\r\n this._descriptorValues.push(result.newDescriptorInfo);\r\n }\r\n\r\n const nodes = this._mappingViewData\r\n .filter(x => x.siteId === data.siteId && x.parcelId === data.parcelId)\r\n .map(x => this._gridApi.getRowNode(x.entityId));\r\n\r\n this._gridApi.redrawRows({rowNodes: nodes});\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private async _updateTargetValue(params: ICellEditorParams, updatedValue: number): Promise {\r\n const data = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!data) {\r\n return Promise.resolve();\r\n }\r\n\r\n const initialValue = params.value;\r\n if (updatedValue === initialValue) {\r\n return Promise.resolve();\r\n }\r\n\r\n const updateModel: Core.AppealRecommendationCommandCenterUpdateTargetValueModel = {\r\n parcelId: data.parcelId,\r\n taxYear: data.taxYear,\r\n targetValue: updatedValue,\r\n force: false\r\n };\r\n\r\n if (data.currentFMV < updatedValue) {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'You have entered an amount greater than the assessment value. Is this correct?',\r\n 'Warning');\r\n updateModel.force = true;\r\n } catch (cancel) {\r\n // revert the cell value\r\n params.node.setDataValue(params.column.getColId(), params.value);\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n\r\n try {\r\n await lastValueFrom(this._appealRecommendationRepository.updateTargetValue(updateModel));\r\n\r\n const parcelInfo = this._parcels.find(x => x.parcelId === data.parcelId);\r\n parcelInfo.targetValue = updatedValue;\r\n params.node.setData(parcelInfo);\r\n\r\n const siteInfo = this._sites\r\n .find(x => x.siteId === parcelInfo.siteId && x.taxYear === data.taxYear);\r\n siteInfo.targetValue = siteInfo.targetValue + (updatedValue - initialValue);\r\n const siteNode = this._gridApi.getRowNode(siteInfo.entityId);\r\n siteNode.data = siteInfo;\r\n\r\n this._gridApi.redrawRows({rowNodes: [params.node, siteNode]});\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private async _updateAppealRecommendationStatus(params: ICellEditorParams, updatedValue: string): Promise {\r\n const data = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!data) {\r\n return Promise.resolve();\r\n }\r\n\r\n const initialValue = params.value;\r\n if (updatedValue === initialValue) {\r\n return Promise.resolve();\r\n }\r\n\r\n const status = this._appealRecommendationStatuses\r\n .find(x => x.name === updatedValue)\r\n .id;\r\n\r\n const annualAssessmentIds = this._parcels\r\n .filter(x => x.siteId === data.siteId && x.parcelId)\r\n .map(x => x.annualAssessmentId);\r\n\r\n const updateModel: Core.UpdateAppealRecommendationStatusModel = {\r\n siteId: data.siteId,\r\n taxYear: data.taxYear,\r\n stateIds: this.selectedStates,\r\n assignedFilter: this._assignedFilter,\r\n appealDeadlineStart: this.appealDeadlineStart,\r\n appealDeadlineEnd: this.appealDeadlineEnd,\r\n status: status,\r\n annualAssessmentIds: annualAssessmentIds\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n\r\n try {\r\n await lastValueFrom(this._appealRecommendationRepository.updateAppealRecommendationStatus(updateModel));\r\n\r\n const siteInfo = this._sites\r\n .find(x => x.siteId === data.siteId && !x.parcelId && x.taxYear === data.taxYear);\r\n siteInfo.appealRecommendationStatusId = status;\r\n } catch (e) {\r\n const siteInfo = this._sites\r\n .find(x => x.siteId === data.siteId && !x.parcelId && x.taxYear === data.taxYear);\r\n siteInfo.appealRecommendationStatus = initialValue;\r\n params.node.setData(siteInfo);\r\n throw e;\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private async _updateIsClientApproved(params: ICellEditorParams, updatedValue: boolean): Promise {\r\n const data = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!data) {\r\n return Promise.resolve();\r\n }\r\n\r\n const initialValue = params.value;\r\n if (updatedValue === initialValue) {\r\n return Promise.resolve();\r\n }\r\n\r\n const updateModel: Core.UpdateSiteAppealRecommendationIsClientApprovedModel = {\r\n siteId: data.siteId,\r\n taxYear: data.taxYear,\r\n stateIds: [],\r\n assignedFilter: this._assignedFilter,\r\n appealDeadlineStart: this.appealDeadlineStart,\r\n appealDeadlineEnd: this.appealDeadlineEnd,\r\n isClientApproved: updatedValue\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n\r\n try {\r\n await lastValueFrom(this._appealRecommendationRepository.updateSiteAppealRecommendationIsClientApproved(updateModel));\r\n const siteInfo = this._sites\r\n .find(x => x.siteId === data.siteId && !x.parcelId && x.taxYear === data.taxYear);\r\n siteInfo.isClientApproved = updatedValue;\r\n } catch (e) {\r\n const siteInfo = this._sites\r\n .find(x => x.siteId === data.siteId && !x.parcelId && x.taxYear === data.taxYear);\r\n siteInfo.isClientApproved = initialValue;\r\n params.node.setData(siteInfo);\r\n throw e;\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private _setColumns() {\r\n const columns: ColDef[] = [\r\n {\r\n lockPinned: true,\r\n suppressMenu: true,\r\n width: AgGridColumns.selectionColumnWidth,\r\n lockVisible: true,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n cellRendererFramework: ExpandCellRendererComponent,\r\n cellRendererParams: {\r\n expand: this._expand.bind(this),\r\n collapse: this._collapse.bind(this),\r\n canExpand: this._canExpand.bind(this),\r\n canCollapse: this._canCollapse.bind(this),\r\n canShowHiddenChildren: this._canShowHiddenParcels.bind(this),\r\n showHiddenChildren: this._showHiddenParcels.bind(this),\r\n getName: (params) => '',\r\n getTooltip: (params) => {\r\n return null;\r\n }\r\n } as ICellRendererParamsForExpandCellRenderer,\r\n headerComponentFramework: ExpandCellHeaderRendererComponent,\r\n headerComponentParams: {\r\n expandAll: this._expandAll.bind(this),\r\n collapseAll: this._collapseAll.bind(this),\r\n canExpandAll: this._canExpandAll.bind(this),\r\n canCollapseAll: this._canCollapseAll.bind(this),\r\n headerText: ''\r\n }\r\n },\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'entityId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n lockVisible: true,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n resizable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {tracker: this.gridTracker} as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {tracker: this.gridTracker} as AgGridMultiSelectCellRendererParams\r\n },\r\n {\r\n colId: 'entityName',\r\n headerName: 'Site / Parcel',\r\n field: 'entityName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!model) {\r\n return '';\r\n }\r\n\r\n let result: string;\r\n\r\n if (model.parcelId) {\r\n result = `#/parcel/${model.parcelId}`;\r\n } else {\r\n result = `#/site/${model.siteId}`;\r\n }\r\n\r\n return result;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'entityName'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'responsibleUser',\r\n headerName: 'Responsible User',\r\n field: 'responsibleUser',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'responsibleUser'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'isReady',\r\n headerName: 'Ready',\r\n field: 'isReady',\r\n valueFormatter: (params) => {\r\n const data = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!data) {\r\n return '';\r\n }\r\n\r\n return data.isReady ? 'Yes' : 'No';\r\n },\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: {\r\n filterOptions: [AgGridFilterParams.noFilterOptionDef, AgGridFilterParams.yesOptionDef, AgGridFilterParams.noOptionDef],\r\n textCustomComparator: this._filterBoolean.bind(this, 'isReady'),\r\n newRowsAction: 'keep',\r\n defaultOption: AgGridFilterParams.noFilterOptionDef.displayKey,\r\n suppressAndOrCondition: true,\r\n },\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.yesNoFilterWithBlankOptionsParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'appealRecommendationStatus',\r\n headerName: 'Rec Status',\r\n field: 'appealRecommendationStatus',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'appealRecommendationStatus'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n editable: (params) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n return model && model.canEdit && model.canChangeAppealRecommendationStatus;\r\n },\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: (params) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n return this._appealRecommendationStatuses\r\n .filter(x => !model || model.isReady ||\r\n (x.id !== Core.AppealRecommendationStatusEnum.Recommend &&\r\n x.id !== Core.AppealRecommendationStatusEnum.DoNotRecommend))\r\n .map(x => {\r\n return {name: x.name, value: x.name};\r\n });\r\n },\r\n cellFocusLost: (params, updatedValue) => this._updateAppealRecommendationStatus(params, updatedValue)\r\n },\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {\r\n getTooltipText: (params) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!model || !model.canEdit) {\r\n return '';\r\n }\r\n\r\n return !model.canChangeAppealRecommendationStatus\r\n ? 'All underlying assessment revisions have completed the Determine if Appeal Warranted task.'\r\n : '';\r\n }\r\n },\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'isClientApproved',\r\n headerName: 'Client Approved',\r\n field: 'isClientApproved',\r\n valueFormatter: (params) => {\r\n const data = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!data) {\r\n return '';\r\n }\r\n\r\n const result = data.parcelId || !data.isClientApprovalRequired\r\n ? ''\r\n : data.isClientApproved.toString() === 'true'\r\n ? 'Yes'\r\n : 'No';\r\n return result;\r\n },\r\n valueSetter: (params) => {\r\n const data = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!data) {\r\n return null;\r\n }\r\n\r\n data.isClientApproved = params.newValue === 'true' || params.newValue;\r\n return true;\r\n },\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: {\r\n filterOptions: [AgGridFilterParams.noFilterOptionDef, AgGridFilterParams.yesOptionDef, AgGridFilterParams.noOptionDef],\r\n textCustomComparator: this._filterBoolean.bind(this, 'isClientApproved'),\r\n newRowsAction: 'keep',\r\n defaultOption: AgGridFilterParams.noFilterOptionDef.displayKey,\r\n suppressAndOrCondition: true,\r\n },\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.yesNoFilterWithBlankOptionsParams,\r\n editable: (params) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n return model && model.canEdit && !model.parcelId && model.isClientApprovalRequired;\r\n },\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: (params) => {\r\n return [\r\n { name: 'No', value: false },\r\n { name: 'Yes', value: true }\r\n ];\r\n },\r\n cellFocusLost: (params, updatedValue) => this._updateIsClientApproved(params, updatedValue)\r\n },\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'emailSentDate',\r\n headerName: 'Email Sent',\r\n field: 'emailSentDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n valueGetter: params => {\r\n const data = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!data || !data.emailSentDate) {\r\n return '';\r\n }\r\n return this._datePipe.transform(data.emailSentDate, false);\r\n },\r\n filter: 'agDateColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan', 'blank', 'notBlank'],\r\n textCustomComparator: this._filterDate.bind(this, 'emailSentDate'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'state',\r\n headerName: 'State',\r\n field: 'state',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!model) {\r\n return '';\r\n }\r\n\r\n return `#/states/${model.stateId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'state'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'assessorName',\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!model || !model.assessorId) {\r\n return null;\r\n }\r\n\r\n return `#/states/${model.stateId}/assessors/${model.assessorId}`;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n return !model || !model.assessorId;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'assessorName'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'appealDeadline',\r\n headerName: 'Appeal Deadline',\r\n field: 'appealDeadline',\r\n width: AgGridColumns.dateColumnWidth,\r\n valueGetter: params => {\r\n const data = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n if (!data) {\r\n return '';\r\n }\r\n\r\n return this._datePipe.transform(data.appealDeadline, false);\r\n },\r\n filter: 'agDateColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterDate.bind(this, 'appealDeadline'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'taxYear',\r\n headerName: 'Tax Year',\r\n field: 'taxYear',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'taxYear'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'class',\r\n headerName: 'Class',\r\n field: 'class',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'class'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'propertyType',\r\n headerName: 'Prop Type',\r\n field: 'propertyType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'propertyType'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'originalFMV',\r\n headerName: 'Original FMV',\r\n field: 'originalFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'originalFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'currentFMV',\r\n headerName: 'Current FMV',\r\n field: 'currentFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'currentFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearFMV',\r\n headerName: 'PY FMV',\r\n field: 'priorYearFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'priorYearFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'targetValue',\r\n headerName: 'Target Value',\r\n field: 'targetValue',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'targetValue'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n editable: (params) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!model) {\r\n return false;\r\n }\r\n\r\n return model.canEdit && !!model.parcelId;\r\n },\r\n cellEditorFramework: AgGridNumberCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: (params, updatedValue) => this._updateTargetValue(params, updatedValue)\r\n },\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'fmvVariance',\r\n headerName: 'FMV YOY Var%',\r\n field: 'fmvVariance',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => this._percentPipe.transform(params.value ?? 0, '1.2-2'),\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterPercent.bind(this, 'fmvVariance'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'accountHandler',\r\n headerName: 'Account Handler',\r\n field: 'accountHandler',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'accountHandler'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'companyName',\r\n headerName: 'Company Name',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!model) {\r\n return null;\r\n }\r\n\r\n return `#/company/${model.companyId}`;\r\n },\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'companyName'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'originalLandFMV',\r\n headerName: 'Original Land FMV',\r\n field: 'originalLandFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'originalLandFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'originalImpsFMV',\r\n headerName: 'Original Imps FMV',\r\n field: 'originalImpsFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'originalImpsFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'originalPersFMV',\r\n headerName: 'Original Pers FMV',\r\n field: 'originalPersFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'originalPersFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'originalAltFMV',\r\n headerName: 'Original Alt FMV',\r\n field: 'originalAltFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'originalAltFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'currentLandFMV',\r\n headerName: 'Current Land FMV',\r\n field: 'currentLandFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'currentLandFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'currentImpsFMV',\r\n headerName: 'Current Imps FMV',\r\n field: 'currentImpsFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'currentImpsFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'currentPersFMV',\r\n headerName: 'Current Pers FMV',\r\n field: 'currentPersFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'currentPersFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'currentAltFMV',\r\n headerName: 'Current Alt FMV',\r\n field: 'currentAltFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'currentAltFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearLandFMV',\r\n headerName: 'PY Land FMV',\r\n field: 'priorYearLandFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'priorYearLandFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearImpsFMV',\r\n headerName: 'PY Imps FMV',\r\n field: 'priorYearImpsFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'priorYearImpsFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearPersFMV',\r\n headerName: 'PY Pers FMV',\r\n field: 'priorYearPersFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'priorYearPersFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearAltFMV',\r\n headerName: 'PY Alt FMV',\r\n field: 'priorYearAltFMV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'priorYearAltFMV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'originalAV',\r\n headerName: 'Original AV',\r\n field: 'originalAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'originalAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'originalLandFMV',\r\n headerName: 'Original Land AV',\r\n field: 'originalLandAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'originalLandAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'originalImpsFMV',\r\n headerName: 'Original Imps AV',\r\n field: 'originalImpsAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'originalImpsAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'originalPersAV',\r\n headerName: 'Original Pers AV',\r\n field: 'originalPersAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'originalPersAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'originalAltAV',\r\n headerName: 'Original Alt AV',\r\n field: 'originalAltAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'originalAltAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'currentAV',\r\n headerName: 'Current AV',\r\n field: 'currentAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'currentAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'currentLandAV',\r\n headerName: 'Current Land AV',\r\n field: 'currentLandAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'currentLandAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'currentImpsAV',\r\n headerName: 'Current Imps AV',\r\n field: 'currentImpsAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'currentImpsAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'currentPersAV',\r\n headerName: 'Current Pers AV',\r\n field: 'currentPersAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'currentPersAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'currentAltAV',\r\n headerName: 'Current Alt AV',\r\n field: 'currentAltAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'currentAltAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearAV',\r\n headerName: 'PY AV',\r\n field: 'priorYearAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'priorYearAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearLandAV',\r\n headerName: 'PY Land AV',\r\n field: 'priorYearLandAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'priorYearLandAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearImpsAV',\r\n headerName: 'PY Imps AV',\r\n field: 'priorYearImpsAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'priorYearImpsAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearPersAV',\r\n headerName: 'PY Pers AV',\r\n field: 'priorYearPersAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'priorYearPersAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearAltAV',\r\n headerName: 'PY Alt AV',\r\n field: 'priorYearAltAV',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'priorYearAltAV'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'revisionName',\r\n headerName: 'Revision Name',\r\n field: 'revisionName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'revisionName'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'appealLevel',\r\n headerName: 'Appeal Level',\r\n field: 'appealLevel',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'appealLevel'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'priorYearAppeal',\r\n headerName: 'PY Appeal',\r\n field: 'priorYearAppeal',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!model) {\r\n return '';\r\n }\r\n\r\n return `#/appeal/${model.priorYearAppealId}`;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n return !model || !model.priorYearAppealId;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'priorYearAppeal'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'savings',\r\n headerName: 'Savings',\r\n field: 'savings',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(Math.floor(params.value ?? 0), '1.0-0')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'savings'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'assesseeName',\r\n headerName: 'Parcel Assessee',\r\n field: 'assesseeName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'assesseeName'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'createDate',\r\n headerName: 'Create Date',\r\n field: 'createDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n filter: 'agDateColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterDate.bind(this, 'createDate'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'team',\r\n headerName: 'Team',\r\n field: 'team',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'team'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'topLevelCompanyName',\r\n headerName: 'Top Company Name',\r\n field: 'topLevelCompanyName',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!model) {\r\n return null;\r\n }\r\n\r\n return `#/company/${model.topLevelCompanyId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, 'topLevelCompanyName'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'totalDollarSqFt',\r\n headerName: 'Total $/SqFt',\r\n field: 'totalDollarSqFt',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(params.value, '1.2-2')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'totalDollarSqFt'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'totalLandDollarAcre',\r\n headerName: 'Land $/Acre',\r\n field: 'totalLandDollarAcre',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(params.value, '1.2-2')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'totalLandDollarAcre'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'totalPriorYearDollarSqFt',\r\n headerName: 'PY Total $/SqFt',\r\n field: 'totalPriorYearDollarSqFt',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(params.value, '1.2-2')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'totalPriorYearDollarSqFt'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'totalPriorYearLandDollarAcre',\r\n headerName: 'PY Land $/Acre',\r\n field: 'totalPriorYearLandDollarAcre',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(params.value, '1.2-2')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'totalPriorYearLandDollarAcre'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'totalDollarUnit',\r\n headerName: 'Total $/Unit',\r\n field: 'totalDollarUnit',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(params.value, '1.2-2')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'totalDollarUnit'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'totalLandDollarSqFt',\r\n headerName: 'Land $/SqFt',\r\n field: 'totalLandDollarSqFt',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(params.value, '1.2-2')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'totalLandDollarSqFt'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'totalPriorYearDollarUnit',\r\n headerName: 'PY Total $/Unit',\r\n field: 'totalPriorYearDollarUnit',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(params.value, '1.2-2')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'totalPriorYearDollarUnit'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n colId: 'totalPriorYearLandDollarSqFt',\r\n headerName: 'PY Land $/SqFt',\r\n field: 'totalPriorYearLandDollarSqFt',\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => `${this._decimalPipe.transform(params.value, '1.2-2')}`,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, 'totalPriorYearLandDollarSqFt'),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n comparator: (valueA, valueB, nodeA, nodeB, isDescending) => 0\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n suppressMenu: true,\r\n sortable: false,\r\n cellRendererFramework: AppealRecommendationCommandCenterGridActionCellRendererComponent\r\n }\r\n ];\r\n\r\n const descriptorColumns = DESCRIPTOR_COLUMN_DEFINITIONS(this._decimalPipe);\r\n this._descriptorInfo\r\n .sort((x, y) => x.name.localeCompare(y.name))\r\n .reduce((acc, descriptor) => {\r\n const column: ColDef = descriptorColumns[descriptor.fieldType](descriptor, this.getDescriptorValue.bind(this), this._picklistInfo);\r\n column.editable = (params) => {\r\n const model = params.data as AppealRecommendationGridRowInfoTreeItemModel;\r\n if (!model) {\r\n return false;\r\n }\r\n\r\n const canEditParcel = !!model.parcelId && descriptor.parcelUsage !== DescriptorUsageEnum.Never;\r\n const canEditSite = !model.parcelId && descriptor.siteUsage !== DescriptorUsageEnum.Never;\r\n\r\n return model.canEdit && (canEditParcel || canEditSite);\r\n };\r\n column.cellEditorParams.cellFocusLost = (params, updatedValue) => this._updateDescriptor(params, updatedValue, descriptor);\r\n column.cellRendererParams = {\r\n getTooltipText: (params) => '',\r\n };\r\n\r\n switch (descriptor.fieldType) {\r\n case DescriptorFieldTypes.Text:\r\n case DescriptorFieldTypes.Picklist:\r\n column.filterParams = {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterString.bind(this, column.field),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n };\r\n break;\r\n case DescriptorFieldTypes.Currency:\r\n case DescriptorFieldTypes.Number:\r\n column.filterParams = {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterNumber.bind(this, column.field),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n };\r\n break;\r\n case DescriptorFieldTypes.YesNo:\r\n column.filterParams = {\r\n filterOptions: [AgGridFilterParams.noFilterOptionDef, AgGridFilterParams.yesOptionDef, AgGridFilterParams.noOptionDef],\r\n textCustomComparator: this._filterBoolean.bind(this, column.field),\r\n newRowsAction: 'keep',\r\n defaultOption: AgGridFilterParams.noFilterOptionDef.displayKey,\r\n suppressAndOrCondition: true,\r\n };\r\n break;\r\n case DescriptorFieldTypes.Date:\r\n column.filterParams = {\r\n filterOptions: ['equals', 'notEqual', 'greaterThan', 'lessThan'],\r\n textCustomComparator: this._filterDate.bind(this, column.field),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n };\r\n break;\r\n }\r\n\r\n acc.push(column);\r\n\r\n return acc;\r\n },\r\n columns);\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'entityName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._gridColumnApi.setColumnPinned('actions', 'right');\r\n }\r\n\r\n private _getDescriptorValue(siteId: number, parcelId: number, descriptorId: number, fieldType: Core.DescriptorFieldTypes = null): any {\r\n const found = this._descriptorValues\r\n .find(x => x.descriptorId == descriptorId &&\r\n x.siteId === siteId && x.parcelId === parcelId);\r\n\r\n let result = found && found.value;\r\n if (fieldType === Core.DescriptorFieldTypes.YesNo) {\r\n result = result && result.toString() === 'true';\r\n }\r\n\r\n return result;\r\n }\r\n\r\n private _sitesOnlyExportOptionDisabled(): boolean {\r\n return this._selectedRowIds.every(x => x.substring(0, 1) !== 'S');\r\n }\r\n\r\n private _parcelsOnlyExportOptionDisabled(): boolean {\r\n return this._selectedRowIds.every(x => x.substring(0, 1) !== 'P');\r\n }\r\n\r\n private _canOpenEmailPreview(): SelectionValidationResult {\r\n const result: SelectionValidationResult= {\r\n isValid: this._hasSelectedRows,\r\n validationMessage: !this._hasSelectedRows ? 'No rows selected' : 'Send Appeal Recommendation Email.'\r\n };\r\n\r\n if (result.isValid) {\r\n if (this._assignedFilter.that === Core.AppealRecommendationCCAssignedFilterThatOptionEnum.Completed) {\r\n result.isValid = false;\r\n result.validationMessage = 'Determination task has been completed.';\r\n } else {\r\n const companyIds: number[] = [];\r\n const taxYears: number[] = [];\r\n const accountHandlers: Guid[] = [];\r\n\r\n this._mappingViewData\r\n .filter(x => this._selectedRowIds.indexOf(x.entityId) !== -1)\r\n .forEach(x => {\r\n companyIds.push(x.topLevelCompanyId);\r\n taxYears.push(x.taxYear);\r\n accountHandlers.push(x.accountHandlerUserId);\r\n });\r\n\r\n if (companyIds.filter(this._uniqueNumberFilter).length > 1 ||\r\n taxYears.filter(this._uniqueNumberFilter).length > 1) {\r\n result.isValid = false;\r\n result.validationMessage = 'Selection must be in the same top company and tax year.';\r\n } else if (accountHandlers.filter(this._uniqueGuidFilter).length > 1) {\r\n result.isValid = false;\r\n result.validationMessage = 'Selection has different account handlers.';\r\n }\r\n else {\r\n const taskIds = this._getSelectedTaskIds();\r\n\r\n if (taskIds.length === 0) {\r\n result.isValid = false;\r\n result.validationMessage = 'Selected rows are not yet ready.';\r\n }\r\n }\r\n }\r\n }\r\n\r\n return result;\r\n }\r\n\r\n private _canAcceptRecommendation(): SelectionValidationResult {\r\n const selectedSites = this._mappingViewData\r\n .filter(x => this._hasSelectedRows && !x.parcelId && this._selectedRowIds.includes(x.entityId));\r\n const hasSelectedSites = selectedSites.length !== 0;\r\n const result: SelectionValidationResult= {\r\n isValid: hasSelectedSites,\r\n validationMessage: !hasSelectedSites ? 'No Site rows selected' : 'Accept recommendations.'\r\n };\r\n\r\n if (result.isValid) {\r\n const selectedAppealRecommendationStatuses: number[] = selectedSites\r\n .map(x => x.appealRecommendationStatusId);\r\n if (selectedAppealRecommendationStatuses.some(x => x === Core.AppealRecommendationStatusEnum.AwaitingReview ||\r\n x === Core.AppealRecommendationStatusEnum.UnderReview)){\r\n result.isValid = false;\r\n result.validationMessage = 'Selection contains sites that are missing a recommendation.';\r\n } else if (selectedAppealRecommendationStatuses.some(x => x !== selectedAppealRecommendationStatuses[0])) {\r\n result.isValid = false;\r\n result.validationMessage = 'Selected sites must have the same recommendation status.';\r\n } else if (selectedAppealRecommendationStatuses.some(x => x === Core.AppealRecommendationStatusEnum.Appeal ||\r\n x === Core.AppealRecommendationStatusEnum.NoAppeal)) {\r\n result.isValid = false;\r\n result.validationMessage = 'Selection contains sites that have already been accepted.';\r\n }\r\n }\r\n\r\n return result;\r\n }\r\n\r\n private _getSelectedTaskIds() {\r\n const taskIds: number[] = this._parcels\r\n .filter(x => {\r\n const result = x.isReady && (this._selectedRowIds.indexOf(x.entityId) !== -1 ||\r\n this._selectedRowIds.indexOf(`S${x.siteId}_${x.taxYear}`) !== -1);\r\n\r\n return result;\r\n })\r\n .map(x => x.determineIfAppealWarrantedTaskId);\r\n\r\n return taskIds;\r\n }\r\n\r\n private _uniqueNumberFilter(value: number, index: number, self: number[]) {\r\n return self.indexOf(value) === index;\r\n }\r\n\r\n private _uniqueGuidFilter(value: Guid, index: number, self: Guid[]) {\r\n return self.indexOf(value) === index;\r\n }\r\n\r\n private async _showAppealRecommendationEmailModal(): Promise {\r\n this._productAnalyticsService.logEvent('click-ARCC-email');\r\n const initialState = {\r\n taskIds: this._getSelectedTaskIds(),\r\n instanceId: this._sites[0].instanceId\r\n };\r\n\r\n this._modalService.show(AppealRecommendationTemplateComponent, { initialState, ignoreBackdropClick: true, class: 'modal-no-max-width modal-xl'});\r\n }\r\n\r\n private async _acceptRecommendation(): Promise {\r\n this._productAnalyticsService.logEvent('click-accept-recommendation');\r\n const selectedSites = this._sites\r\n .filter(x => this._selectedRowIds.indexOf(x.entityId) !== -1);\r\n\r\n const selectedSiteIds = selectedSites\r\n .filter(x => !x.parcelId)\r\n .map(x => x.siteId);\r\n\r\n const selectedTaskIds = this._parcels\r\n .filter(x => selectedSiteIds.includes(x.siteId))\r\n .map(x => x.determineIfAppealWarrantedTaskId);\r\n\r\n let result: Core.BulkOperationResult[];\r\n\r\n if (selectedSites[0].appealRecommendationStatusId === Core.AppealRecommendationStatusEnum.Recommend) {\r\n const model: ProcessAppealWarrantedParams = {\r\n taskIDs: selectedTaskIds,\r\n searchTimestamp: this._searchTimestamp,\r\n runWithBuffer: true,\r\n updateAppealRecommendation: true\r\n };\r\n\r\n result = await this._weissmanModalService.showAsync(ProcessAppealWarrantedComponent, model, 'modal-lg');\r\n } else {\r\n const model: ProcessNoAppealParams = {\r\n taskIDs: selectedTaskIds,\r\n searchTimestamp: this._searchTimestamp,\r\n updateAppealRecommendation: true\r\n };\r\n\r\n result = await this._weissmanModalService.showAsync(ProcessNoAppealComponent, model, 'modal-lg');\r\n }\r\n\r\n if (result) {\r\n const processedTaskIds = result\r\n .filter(x => !x.errorMessage && !x.warningMessage)\r\n .map(x => x.taskID);\r\n processedTaskIds.forEach( x => {\r\n const parcel = this._parcels.find(y => y.determineIfAppealWarrantedTaskId === x);\r\n this._parcels.splice(this._parcels.indexOf(parcel), 1);\r\n\r\n const site = this._sites.find(y => y.siteId === parcel.siteId);\r\n if (site) {\r\n this._sites.splice(this._sites.indexOf(site), 1);\r\n let displayedRow: AppealRecommendationGridRowInfoTreeItemModel;\r\n\r\n while((displayedRow = this._mappingViewData.find(y => y.siteId === site.siteId))) {\r\n this._mappingViewData.splice(this._mappingViewData.indexOf(displayedRow), 1);\r\n }\r\n }\r\n });\r\n\r\n if (result.some(x => x.errorMessage || x.warningMessage)) {\r\n result.forEach(x =>\r\n {\r\n const parcel = this._parcels.find(y => y.determineIfAppealWarrantedTaskId === x.taskID);\r\n if (parcel) {\r\n parcel.hasError = true;\r\n }\r\n });\r\n\r\n this._redrawGrid = true;\r\n\r\n const allErrors = result\r\n .filter(x => x.errorMessage)\r\n .map(x => x.errorMessage);\r\n const uniqueErrors = Array.from(new Set(allErrors));\r\n\r\n const allWarnings = result\r\n .filter(x => x.warningMessage)\r\n .map(x => x.warningMessage);\r\n const uniqueWarnings = Array.from(new Set(allWarnings));\r\n\r\n const errorMessage = 'The following error(s) or warning(s) were encountered attempting to accept the recommendation; please attempt to correct these errors and try again';\r\n\r\n this._taskModalService.showErrorNotificationModal(uniqueErrors, uniqueWarnings, errorMessage);\r\n }\r\n\r\n this._setRowData();\r\n }\r\n }\r\n\r\n private _addDays(currentDate: Date, days: number): Date {\r\n const result = new Date(currentDate);\r\n result.setDate(result.getDate() + days);\r\n return result;\r\n }\r\n\r\n private _addSeconds(currentDate: Date, seconds: number): Date {\r\n const result = new Date(currentDate);\r\n result.setDate(result.getSeconds() + seconds);\r\n return result;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AssessorCollectorRepository } from '../Core-Repositories';\r\nimport { Assessor, AssessorActiveParcelCount } from './assessor.model';\r\nimport { AssessorMunicipality } from './List/addAssessorModal.component';\r\nimport { CollectorAssociation } from './Assessor/Assessor-Available-Collectors/assessor.available.collectors.component';\r\nimport { Collector } from './collector.model';\r\n\r\n@Injectable()\r\nexport class AssessorCollectorService {\r\n constructor(private readonly _assessorCollectorRepository: AssessorCollectorRepository) {}\r\n\r\n selectedCollectorLetter: string;\r\n\r\n private readonly COLLECTOR: string = 'collector';\r\n private readonly ASSESSOR: string = 'assessor';\r\n\r\n getNavigationInfo(entityType: string, entityId: number): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getNavigationInfo(entityType, entityId));\r\n }\r\n\r\n getCompanyCollectorsByParcel(parcelId: number): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getCompanyCollectorsByParcel(parcelId));\r\n }\r\n\r\n getAssessorExtract(): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getAssessorExtract());\r\n }\r\n\r\n getCollectorExtract(): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getCollectorExtract());\r\n }\r\n\r\n getUpdatedAssessor(entityId: number, extraParam?: string): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getUpdatedAssessorCollector(this.ASSESSOR, entityId, extraParam));\r\n }\r\n\r\n getUpdatedCollector(entityId: number, extraParam?: string): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getUpdatedAssessorCollector(this.COLLECTOR, entityId, extraParam));\r\n }\r\n\r\n saveAssessor(assessor: Assessor): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.saveAssessorCollector(this.ASSESSOR, assessor)) as Promise;\r\n }\r\n\r\n saveCollector(collector: any): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.saveAssessorCollector(this.COLLECTOR, collector));\r\n }\r\n\r\n getAssessorCollectorList(stateId: number, assessorId: number): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getAssessorCollectorList(stateId, assessorId));\r\n }\r\n\r\n getStateCollectorList(stateId:number): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getStateCollectorList(stateId));\r\n }\r\n\r\n getCompanyCollectorList(companyId: number): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getCompanyCollectorList(companyId));\r\n }\r\n\r\n getCollectorAssociations(assesorId: number): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getCollectorAssociations(assesorId));\r\n }\r\n\r\n saveAssociations(assessorId: number, associations: CollectorAssociation[]): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.saveAssociations(assessorId, associations));\r\n }\r\n\r\n getAssessorList(stateId: number): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getStateAssessorList(stateId));\r\n }\r\n\r\n getAssessorActiveParcelCounts(stateId: number): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getAssessorActiveParcelCounts(stateId));\r\n }\r\n\r\n getAssessorMunicipalities(): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getAssessorMunicipalities());\r\n }\r\n\r\n createAssessor(assessor: Assessor): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.createAssessor(assessor));\r\n }\r\n\r\n createCollector(collector: Collector): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.createCollector(collector));\r\n }\r\n\r\n getAssessor(assessorId: number): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.getAssessor(assessorId));\r\n }\r\n\r\n saveCollectorProtocols(collectorProtocols: Weissman.Model.Collectors.Collector): Promise {\r\n return lastValueFrom(this._assessorCollectorRepository.saveCollectorProtocols(collectorProtocols));\r\n }\r\n}\r\n","import { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AppealDeadlinePayload } from './Panel/deadlineListPanel.component';\r\n\r\n@Injectable()\r\nexport class DeadlineService {\r\n constructor(private readonly _http: HttpClient) {}\r\n\r\n private readonly _baseUrl = 'api/group';\r\n\r\n getAvailableStateYears(stateId: number): Promise<{years: number}[]> {\r\n return lastValueFrom(this._http.get(`api/State/${stateId}/AppealDeadline/Years`)) as Promise<{\r\n years: number\r\n }[]>;\r\n }\r\n\r\n getAvailableAssessorYears(assessorId: number): Promise<{years: number}[]> {\r\n return lastValueFrom(this._http.get(`api/Assessor/${assessorId}/AppealDeadline/Years`)) as Promise<{\r\n years: number\r\n }[]>;\r\n }\r\n\r\n getStateDeadlines(stateId: number): Promise {\r\n return lastValueFrom(this._http.get(`api/State/${stateId}/AppealDeadline`)) as Promise;\r\n }\r\n\r\n getAssessorDeadlines(assessorId: number): Promise {\r\n return lastValueFrom(this._http.get(`api/Assessor/${assessorId}/AppealDeadline`)) as Promise;\r\n }\r\n\r\n getAppealDeadlineTypes(): Promise {\r\n return lastValueFrom(this._http.get('/api/AppealDeadlineType/'));\r\n }\r\n\r\n saveForState(stateId: number, payload: any): Promise {\r\n return lastValueFrom(this._http.post(`/api/state/${stateId}/AppealDeadlines`, payload)) as Promise;\r\n }\r\n\r\n create(entityString: string, entityId: number, payload: AppealDeadlinePayload): Promise {\r\n return lastValueFrom(this._http.post(`/api/${entityString}/${entityId}/AppealDeadline`, payload)) as Promise;\r\n }\r\n\r\n update(entityString: string, entityId: number, payload: AppealDeadlinePayload): Promise {\r\n return lastValueFrom(this._http.put(`/api/${entityString}/${entityId}/AppealDeadline`, payload)) as Promise;\r\n }\r\n\r\n remove(entityString: string, entityId: number, appealDeadlineId: number, doUpdate: boolean): Promise {\r\n const params = new HttpParams().set('doUpdate', doUpdate.toString());\r\n\r\n return lastValueFrom(this._http.delete(`/api/${entityString}/${entityId}/AppealDeadline/${appealDeadlineId}`, { params: params })) as Promise;\r\n }\r\n\r\n getAssessorExceptions(deadline: Core.AppealDeadlineModel, stateId: number, taxYear: string | number): Promise {\r\n if (deadline.appealDeadlineTypeID === undefined) throw 'deadlineTypeId is required';\r\n if (deadline.propertyTypeID === undefined) throw 'propertyTypeId is required';\r\n if (taxYear === undefined) throw 'taxYear is required';\r\n if (stateId === undefined) throw 'stateId is required';\r\n if (deadline.deadlineMonthDay === undefined) throw 'stateDeadline is required';\r\n\r\n const params = new HttpParams()\r\n .set('stateID', stateId.toString())\r\n .set('taxyear', taxYear.toString())\r\n .set('proptypeid', deadline.propertyTypeID.toString())\r\n .set('deadlinetypeid', deadline.appealDeadlineTypeID.toString())\r\n .set('statedeadline', deadline.deadlineMonthDay.toString());\r\n\r\n return lastValueFrom(this._http.get(`/api/state/${stateId}/appealdeadline/exceptions`, { params: params }));\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { DeadlineService } from '../deadline.service';\r\nimport { AppealDeadlineModel } from '../Panel/deadlineListPanel.component';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface AssessorExceptionsParams {\r\n deadline: AppealDeadlineModel\r\n stateId: number;\r\n selectedYear: number | string;\r\n}\r\n\r\nexport interface AssessorException {\r\n abbr: string;\r\n assessorID: number;\r\n deadlineDate: string;\r\n deadlineMonthDay: string;\r\n deadlineType: string;\r\n deadlineDateDisplay: string;\r\n earliestPossible: boolean;\r\n municipalityName: string;\r\n name: string;\r\n propTypeName: string;\r\n}\r\n\r\n@Component({\r\n selector: 'assessor-exceptions-modal',\r\n template: `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Assessor AbbrDeadline
\r\n {{exception.abbr + ' ' + exception.municipalityName}}\r\n \r\n {{exception.deadlineDateDisplay | date:'M/d/yyyy':'utc' }} ^\r\n
\r\n
^Not available. Projected as earliest possible date.
\r\n
\r\n `,\r\n})\r\nexport class AssessorExceptionsModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _deadlineService: DeadlineService\r\n ) { }\r\n\r\n params: AssessorExceptionsParams;\r\n result: void;\r\n\r\n loading: boolean = false;\r\n exceptions: AssessorException[];\r\n propertyType: string;\r\n deadlineType: string;\r\n isEarliestPossibleDeadline: boolean = false;\r\n headerLabel: string;\r\n\r\n async ngOnInit() {\r\n this.loading = true;\r\n\r\n try {\r\n const exceptions = await this._deadlineService.getAssessorExceptions(this.params.deadline, this.params.stateId, this.params.selectedYear);\r\n\r\n this.exceptions = _.chain(exceptions)\r\n .reject(x => {\r\n return _.some(exceptions, y => {\r\n return (x != y) // we don't compare exception to itself\r\n && (x.assessorID === y.assessorID) // we have more than one expetion for the same assessor\r\n && (y.deadlineDate != null);\r\n });\r\n })\r\n .map(exception => {\r\n exception.deadlineDateDisplay = exception.deadlineDate\r\n ? new Date(exception.deadlineDate)\r\n : exception.deadlineMonthDay\r\n ? (`${exception.deadlineMonthDay }/${ this.params.selectedYear}`)\r\n : 'Unknown Date';\r\n\r\n return exception;\r\n })\r\n .sortBy('name')\r\n .value();\r\n\r\n\r\n if(this.exceptions.length) {\r\n this.propertyType = this.exceptions[0].propTypeName;\r\n this.deadlineType = this.exceptions[0].deadlineType;\r\n }\r\n\r\n this.isEarliestPossibleDeadline = _.some(this.exceptions, 'earliestPossible');\r\n this.headerLabel = `Assessor Exceptions: ${this.params.selectedYear} ${this.propertyType} ${this.deadlineType} deadlines`;\r\n\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n getAssessorSref(exception: AssessorException) {\r\n return {\r\n target: 'assessor',\r\n options: {\r\n stateId: this.params.stateId,\r\n id: exception.assessorID,\r\n year: this.params.selectedYear\r\n }\r\n };\r\n }\r\n\r\n close() {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\n
\r\n
\r\n

Deadlines

\r\n
\r\n
\r\n Tax Year:\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n

0\">{{deadlineType.deadlineType}} Deadlines (Assessor Overrides)

\r\n

{{deadlineType.deadlineType}}

\r\n
\r\n {{deadline.propertyTypeName}}\r\n \r\n \r\n {{getDeadlineDateStr(deadline)}}\r\n {{deadline.deadlineDate | date:'M/d/yyyy':'utc'}}\r\n ^\r\n \r\n \r\n (Exceptions)\r\n \r\n \r\n (per state setup)\r\n \r\n
{{deadline.propertyTypeName}}\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
0\" class=\"checkbox\">\r\n \r\n
\r\n
\r\n \r\n
From Date:
\r\n\r\n
\r\n ^Not available. Projected as earliest possible date.\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Input } from '@angular/core';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { DeadlineService } from '../deadline.service';\r\nimport * as _ from 'lodash';\r\nimport { PropertyTypeService } from '../../Common/Services/propertyType.service.upgrade';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { efAction } from '../../constants.new';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport * as moment from 'moment';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { AssessorExceptionsParams, AssessorExceptionsModalComponent } from '../Assessor-Exceptions/assessorExceptionsModal.component';\r\nimport { Assessor } from '../../Assessor-Collector/assessor.model';\r\n\r\ninterface AppealDeadlineType {\r\n appealDeadlineTypeID: number;\r\n deadlineType: string;\r\n sequence: number;\r\n}\r\n\r\nexport interface AppealDeadlineModel extends Core.AppealDeadlineModel {\r\n efAction?: efAction;\r\n fromDate?: Date;\r\n}\r\n\r\ninterface DeadlinesByDeadlineType {\r\n appealDeadlineTypeID: number;\r\n deadlineType: string;\r\n deadlines: AppealDeadlineModel[];\r\n}\r\n\r\ninterface LienDateTooltipInfo {\r\n showTooltip: boolean;\r\n tooltipDate?: string;\r\n}\r\n\r\nexport interface AppealDeadlinePayload {\r\n deadline: AppealDeadlineModel;\r\n doUpdate: boolean;\r\n fromDate: string;\r\n}\r\n\r\nexport interface UpdateDeadlineResponseConfirmation {\r\n skipped: number;\r\n total: number;\r\n}\r\n\r\ninterface UnassignedDeadlinePropType {\r\n display: string;\r\n deadlineType: AppealDeadlineType;\r\n propertyType: Weissman.Model.Assessments.PropertyType;\r\n}\r\n\r\n@Component({\r\n selector: 'deadline-list-panel',\r\n templateUrl: './deadlineListPanel.component.html',\r\n styleUrls: ['./deadlineListPanel.component.scss']\r\n})\r\nexport class DeadlineListPanelComponent implements OnInit {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _deadlineService: DeadlineService,\r\n private readonly _propertTypeService: PropertyTypeService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _toastrService: ToastrService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: WeissmanModalService,\r\n ) {}\r\n\r\n @Input() stateId: number;\r\n @Input() assessorId: number;\r\n @Input() assessor: Assessor;\r\n @Input() state: Weissman.Model.Misc.State;\r\n\r\n\r\n hasEditPermission: boolean = false;\r\n years: (number | string)[];\r\n selectedYear: number | string;\r\n deadlinesByDeadlineType: DeadlinesByDeadlineType[];\r\n editMode: boolean = false;\r\n serverAction: boolean = false;\r\n checkUseEarliestPossible: boolean = false;\r\n unassignedDeadlinePropTypes: UnassignedDeadlinePropType[];\r\n chosenDeadlineProptype: UnassignedDeadlinePropType;\r\n readonly YEAR_TYPES: {id: number, name: string}[] = [{ id: -1, name: 'Prior' }, { id: 0, name: 'Current' }, { id: 1, name: 'Next' }, { id: 2, name: 'Next Next' }];\r\n\r\n private _propertyTypes: Weissman.Model.Assessments.PropertyType[];\r\n private _availableDeadlineTypes: AppealDeadlineType[];\r\n private _flatDeadlines: AppealDeadlineModel[];\r\n private _orignalSelectedYear: number;\r\n private _originalDeadlines: AppealDeadlineModel[];\r\n private _doUpdate = false;\r\n private _impactedEntities: UpdateDeadlineResponseConfirmation;\r\n\r\n private get _entityString (): 'state' | 'assessor' {\r\n return this.isStatePage ? 'state' : 'assessor';\r\n }\r\n private get _undeletedFlatDeadlines(): AppealDeadlineModel[] {\r\n return _.reject(this._flatDeadlines, {efAction: 'delete'});\r\n }\r\n private get _entityId(): number {\r\n return this.isStatePage ? this.stateId : this.assessorId;\r\n }\r\n private get _isOnDefault(): boolean {\r\n return this.selectedYear === 'Default' || this.isStatePage;\r\n }\r\n get isStatePage(): boolean {\r\n return !this.assessorId;\r\n }\r\n\r\n async ngOnInit() {\r\n await this._loadData();\r\n\r\n this.hasEditPermission = this._restrictService.isInRole(Roles.STATEEDIT);\r\n\t\t// this.hasContactRoles = !this._restrictService.isNotInRoles([Roles.RYANPRIVATEITEMSVIEW, Roles.RYANPRIVATEITEMSEDIT]);\r\n }\r\n\r\n getDeadlineDateStr(deadline: AppealDeadlineModel) {\r\n return `${deadline.deadlineMonthDay}/${deadline.deadlineYearID + (this.selectedYear as number)}`;\r\n }\r\n\r\n setDirty(deadline: AppealDeadlineModel) {\r\n if (deadline.efAction !== 'add') {\r\n deadline.efAction = 'update';\r\n }\r\n }\r\n\r\n yearChanged() {\r\n if(!this.isStatePage) {\r\n this._getDeadlinesByYear();\r\n }\r\n }\r\n\r\n deadlineHasExceptions(deadline: AppealDeadlineModel) {\r\n return deadline.hasDefaultExceptions\r\n || (deadline.yearsWithNonDefaultExceptions && deadline.yearsWithNonDefaultExceptions.includes(this.selectedYear as number));\r\n }\r\n\r\n edit() {\r\n this._orignalSelectedYear = this.selectedYear as number;\r\n this._originalDeadlines = _.cloneDeep(this._flatDeadlines);\r\n\r\n this.editMode = true;\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you wish to leave?');\r\n\r\n this._getDeadlinesByYear();\r\n\r\n if(!this.isStatePage) {\r\n this._updateYears();\r\n }\r\n }\r\n\r\n cancel() {\r\n this._flatDeadlines = this._originalDeadlines;\r\n\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n\r\n this._getDeadlinesByYear();\r\n\r\n if(!this.isStatePage) {\r\n this._updateYears();\r\n }\r\n }\r\n\r\n delete(deadline: AppealDeadlineModel) {\r\n if (deadline.efAction === 'add') {\r\n _.remove(this._flatDeadlines, deadline);\r\n } else {\r\n deadline.efAction = 'delete';\r\n }\r\n }\r\n\r\n addDeadline(): void {\r\n const newDeadline: AppealDeadlineModel = {\r\n efAction: 'add',\r\n appealDeadlineID: 0,\r\n appealDeadlineTypeID: this.chosenDeadlineProptype.deadlineType.appealDeadlineTypeID,\r\n deadlineDate: null,\r\n deadlineMonthDay: this._isOnDefault ? '' : null,\r\n deadlineYearID: this._isOnDefault ? 0 : null,\r\n taxYear: this._isOnDefault ? null : Number(this.selectedYear),\r\n deadlineType: this.chosenDeadlineProptype.deadlineType.deadlineType,\r\n propertyTypeAbbr: this.chosenDeadlineProptype.propertyType.propTypeAbbr,\r\n propertyTypeID: this.chosenDeadlineProptype.propertyType.propertyTypeID,\r\n propertyTypeName: this.chosenDeadlineProptype.propertyType.propTypeName,\r\n earliestPossible: false,\r\n yearsWithNonDefaultExceptions: [],\r\n hasDefaultExceptions: false,\r\n entityID: this._entityId,\r\n entityTypeID: this.isStatePage ? Core.EntityTypes.State : Core.EntityTypes.Assessor\r\n };\r\n\r\n this._flatDeadlines.push(newDeadline);\r\n\r\n setTimeout(() => {\r\n this.chosenDeadlineProptype = undefined;\r\n });\r\n\r\n this._getDeadlinesByYear();\r\n }\r\n\r\n async openAssessorExceptions(deadline: AppealDeadlineModel): Promise {\r\n const params: AssessorExceptionsParams = {\r\n deadline,\r\n stateId: this.stateId,\r\n selectedYear: this.selectedYear\r\n };\r\n\r\n await this._modalService.showAsync(AssessorExceptionsModalComponent, params, 'modal-md');\r\n }\r\n\r\n async save () {\r\n const isMissingFromDate = _.some(this._undeletedFlatDeadlines, x => {\r\n return x.appealDeadlineTypeID > 0 && x.efAction && !x.fromDate;\r\n });\r\n\r\n if(isMissingFromDate) {\r\n this._toastrService.error('Missing From Date');\r\n return;\r\n }\r\n\r\n const invalidDateDeadline = _.find(this._undeletedFlatDeadlines, x => {\r\n if (x.deadlineMonthDay !== null) {\r\n return !moment(x.deadlineMonthDay, 'MM/DD').isValid();\r\n }\r\n\r\n return false;\r\n });\r\n\r\n if (invalidDateDeadline) {\r\n this._toastrService.error(`Invalid date entered: ${ invalidDateDeadline.deadlineMonthDay}`);\r\n return;\r\n }\r\n\r\n this.serverAction = true;\r\n try {\r\n const responses = await this._sendRequests();\r\n this.serverAction = false;\r\n\r\n if(!responses.length) {\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n\r\n return;\r\n }\r\n\r\n const message = `${this._impactedEntities.total} parcel deadline(s) will be affected. ${this._impactedEntities.skipped} will be skipped.`;\r\n\r\n try {\r\n await this._messageModalService.confirm(message);\r\n } catch (e3) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._doUpdate = true;\r\n this.serverAction = true;\r\n await this._sendRequests();\r\n await this._loadData();\r\n\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n\r\n if(!this.isStatePage) {\r\n this._updateYears();\r\n }\r\n } finally {\r\n this._doUpdate = false;\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n getHelpTooltip(appealDeadlineTypeID: number): string {\r\n const tooltipInfo = this._getTooltipInfo(appealDeadlineTypeID);\r\n\r\n return tooltipInfo.showTooltip\r\n ? `Personal Property Lien Date ${tooltipInfo.tooltipDate}`\r\n : null;\r\n }\r\n\r\n showTooltipIcon(appealDeadlineTypeID: number) {\r\n return this._getTooltipInfo(appealDeadlineTypeID).showTooltip;\r\n }\r\n\r\n private async _sendRequests(): Promise {\r\n const deadlinePromises = [];\r\n this._impactedEntities = {\r\n skipped: 0,\r\n total: 0\r\n };\r\n\r\n if (this.isStatePage){\r\n const payload = _.chain(this._undeletedFlatDeadlines)\r\n .filter('efAction')\r\n .map(this._getDeadlinePayload.bind(this))\r\n .value();\r\n\r\n if(payload.length) {\r\n const statePromise = this._deadlineService.saveForState(this.stateId, payload)\r\n .then(this.handleCRUDResult.bind(this));\r\n\r\n deadlinePromises.push(statePromise);\r\n }\r\n\r\n const deletedStateDeadlines = _.filter(this._flatDeadlines, {efAction: 'delete'});\r\n _.forEach(deletedStateDeadlines, deadline => {\r\n const promise = this._deadlineService.remove(this._entityString, this._entityId, deadline.appealDeadlineID, this._doUpdate)\r\n .then(this.handleCRUDResult.bind(this));\r\n\r\n deadlinePromises.push(promise);\r\n });\r\n }\r\n else {\r\n _.forEach(this._flatDeadlines, deadline => {\r\n const payload = this._getDeadlinePayload(deadline);\r\n let promise;\r\n\r\n switch (deadline.efAction) {\r\n case 'update':\r\n promise = this._deadlineService.update(this._entityString, this._entityId, payload)\r\n .then(this.handleCRUDResult.bind(this));\r\n break;\r\n case 'add':\r\n promise = this._deadlineService.create(this._entityString, this._entityId, payload)\r\n .then(this.handleCRUDResult.bind(this));\r\n break;\r\n case 'delete':\r\n promise = this._deadlineService.remove(this._entityString, this._entityId, deadline.appealDeadlineID, this._doUpdate)\r\n .then(this.handleCRUDResult.bind(this));\r\n break;\r\n }\r\n\r\n deadlinePromises.push(promise);\r\n });\r\n }\r\n\r\n return Promise.all(deadlinePromises);\r\n }\r\n\r\n private handleCRUDResult(result) {\r\n if(this._doUpdate) return;\r\n\r\n const { skipped, total } = result as UpdateDeadlineResponseConfirmation;\r\n this._impactedEntities.skipped += skipped;\r\n this._impactedEntities.total += total;\r\n }\r\n\r\n private _getDeadlinePayload(deadline: AppealDeadlineModel): AppealDeadlinePayload {\r\n return {\r\n deadline: _.omit(deadline, 'fromDate') as AppealDeadlineModel,\r\n doUpdate: this._doUpdate,\r\n fromDate: moment(deadline.fromDate).utc().format('MM/DD/YYYY')\r\n };\r\n }\r\n\r\n private async _loadData() {\r\n this.serverAction = true;\r\n\r\n try {\r\n const years = this.isStatePage\r\n ? await this._deadlineService.getAvailableStateYears(this.stateId)\r\n : await this._deadlineService.getAvailableAssessorYears(this.assessorId);\r\n\r\n const currentYear = new Date().getFullYear();\r\n\r\n this.years = _.chain(years)\r\n .map('years')\r\n .union(_.range(currentYear - 5, currentYear + 4))\r\n .uniq()\r\n .orderBy([], ['desc'])\r\n .value();\r\n\r\n this.selectedYear = currentYear;\r\n\r\n this._propertyTypes = await this._propertTypeService.get();\r\n this._availableDeadlineTypes = await this._deadlineService.getAppealDeadlineTypes();\r\n this._flatDeadlines = await this._deadlineService.getStateDeadlines(this.stateId) as AppealDeadlineModel[];\r\n\r\n if(this.isStatePage) {\r\n this._availableDeadlineTypes.push({appealDeadlineTypeID: -1, deadlineType: 'Fiscal Dates', sequence: 1000});\r\n } else {\r\n const assessorDeadlines = await this._deadlineService.getAssessorDeadlines(this.assessorId) as AppealDeadlineModel[];\r\n this._flatDeadlines = _.union(this._flatDeadlines, assessorDeadlines);\r\n }\r\n\r\n this.checkUseEarliestPossible = _.some(this._flatDeadlines, 'earliestPossible');\r\n\r\n this._getDeadlinesByYear();\r\n }\r\n finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n private _getDeadlinesByYear() {\r\n this.deadlinesByDeadlineType = _.chain(this._flatDeadlines)\r\n .groupBy(x => {\r\n return x.appealDeadlineTypeID < 0 ? -1 : x.appealDeadlineTypeID;\r\n })\r\n .map(x => this._getDeadlinesByType(x))\r\n .sortBy(deadlinesByDeadlineType => {\r\n const deadlineType = _.find(this._availableDeadlineTypes, {appealDeadlineTypeID: deadlinesByDeadlineType.appealDeadlineTypeID});\r\n return deadlineType ? deadlineType.sequence : 99;\r\n })\r\n .value();\r\n\r\n this.unassignedDeadlinePropTypes = _.reduce(this._availableDeadlineTypes, (unassigned, deadlineType) => {\r\n if(deadlineType.appealDeadlineTypeID < 0) {\r\n return unassigned;\r\n }\r\n\r\n const usedDeadlineType = _.find(this.deadlinesByDeadlineType, {appealDeadlineTypeID: deadlineType.appealDeadlineTypeID});\r\n const unassignedForDeadlineType = _.chain(this._propertyTypes)\r\n .reject(x => {\r\n return usedDeadlineType && _.some(usedDeadlineType.deadlines, {propertyTypeID: x.propertyTypeID});\r\n })\r\n .map(x => {\r\n return {\r\n display: `${deadlineType.deadlineType} (${x.propTypeAbbr})`,\r\n deadlineType: deadlineType,\r\n propertyType: x\r\n };\r\n })\r\n .value();\r\n\r\n return [...unassigned, ...unassignedForDeadlineType];\r\n }, []);\r\n }\r\n\r\n private _getDeadlinesByType(deadlinesByDeadlineType: Core.AppealDeadlineModel[]): DeadlinesByDeadlineType {\r\n const deadlines = _.chain(deadlinesByDeadlineType)\r\n .groupBy('propertyTypeID')\r\n .map((deadlineArr) => {\r\n if(this.isStatePage) {\r\n return deadlineArr;\r\n } else {\r\n if(this.editMode) {\r\n const assessorTaxYearDeadline = _.find(deadlineArr, {taxYear: this.selectedYear});\r\n const assessorDefaultDeadline = _.find(deadlineArr, {taxYear: null, entityID: this.assessorId});\r\n\r\n return assessorTaxYearDeadline || (this.selectedYear === 'Default' && assessorDefaultDeadline);\r\n\r\n } else {\r\n const assessorTaxYearDeadline = _.find(deadlineArr, {taxYear: this.selectedYear});\r\n const assessorDefaultDeadline = _.find(deadlineArr, {taxYear: null, entityID: this.assessorId});\r\n const stateDefaultDeadline = _.find(deadlineArr, {taxYear: null, entityID: this.stateId});\r\n const fiscalDatesDeadlines = _.filter(deadlineArr, {appealDeadlineID: 0});\r\n\r\n return assessorTaxYearDeadline || assessorDefaultDeadline || stateDefaultDeadline || fiscalDatesDeadlines;\r\n }\r\n }\r\n })\r\n .flatten()\r\n .compact()\r\n .sortBy(deadline => {\r\n const propertyType = _.find(this._propertyTypes, {propertyTypeID: deadline.propertyTypeID});\r\n return propertyType ? propertyType.sequence : 99;\r\n })\r\n .value();\r\n\r\n return {\r\n appealDeadlineTypeID: deadlinesByDeadlineType[0].appealDeadlineTypeID,\r\n deadlineType: deadlinesByDeadlineType[0].deadlineType,\r\n deadlines: deadlines as AppealDeadlineModel[]\r\n };\r\n }\r\n\r\n private _updateYears() {\r\n if(this.editMode) {\r\n this.years.unshift('Default');\r\n } else {\r\n if(this.selectedYear === 'Default') {\r\n this.selectedYear = this._orignalSelectedYear;\r\n }\r\n\r\n _.remove(this.years, x => x === 'Default');\r\n }\r\n }\r\n\r\n private _getTooltipInfo(appealDeadlineTypeID: number): LienDateTooltipInfo {\r\n const tooltipInfo: LienDateTooltipInfo = {\r\n showTooltip: false\r\n };\r\n\r\n if (appealDeadlineTypeID === -1) {\r\n if (this.isStatePage) {\r\n if (this.state.lienDateMonthDay !== this.state.ppLienDateMonthDay || this.state.lienDateYearID !== this.state.ppLienDateYearOffset) {\r\n tooltipInfo.showTooltip = true;\r\n tooltipInfo.tooltipDate = `${this.state.ppLienDateMonthDay }/${ +this.selectedYear + this.state.ppLienDateYearOffset}`;\r\n }\r\n } else {\r\n if (this.state.ppLienDateDisplayMonthDay !== this.assessor.ppLienDateDisplayMonthDay && this.assessor.ppLienDateDisplayMonthDay) {\r\n tooltipInfo.showTooltip = true;\r\n tooltipInfo.tooltipDate = `${this.assessor.ppLienDateDisplayMonthDay }/${ +this.selectedYear + this.assessor.ppLienDateYearOffset}`;\r\n } else if (this.state.lienDateMonthDay !== this.state.ppLienDateDisplayMonthDay && this.state.personalPropTaxable) {\r\n tooltipInfo.showTooltip = true;\r\n tooltipInfo.tooltipDate = `${this.state.ppLienDateDisplayMonthDay }/${ +this.selectedYear + this.state.ppLienDateYearOffset}`;\r\n }\r\n }\r\n }\r\n\r\n return tooltipInfo;\r\n }\r\n}\r\n","import { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class AssessmentClassService {\r\n constructor(private readonly _http: HttpClient) {}\r\n\r\n private readonly _baseUrl = 'api/assessmentclass';\r\n\r\n getList(stateId: number, assessorId: number): Promise< Weissman.Model.Assessments.AssessmentClass[]> {\r\n return lastValueFrom(this._http.get(`${this._baseUrl}/state/${stateId}/assessor/${assessorId}`)) as Promise;\r\n }\r\n\r\n getAssessmentComponents(): Promise {\r\n return lastValueFrom(this._http.get('/api/assessmentcomponent')) as Promise;\r\n }\r\n\r\n getExemptionChoicesForTaxAuthority(taxAuthorityId: number): Promise {\r\n return lastValueFrom(this._http.get(`/api/assessmentcomponent/taxAuthorityExemptionChoices/${taxAuthorityId}`)) as Promise;\r\n }\r\n\r\n getParcelsAffectedByRatio(assessmentClassRatioId: number) {\r\n const params = new HttpParams()\r\n .set('assessmentClassRatioID', assessmentClassRatioId.toString());\r\n\r\n return lastValueFrom(this._http.get('/api/assessmentclassratio', { params }));\r\n }\r\n\r\n create(assessmentClass: Weissman.Model.Assessments.AssessmentClass) {\r\n return lastValueFrom(this._http.post(this._baseUrl, assessmentClass));\r\n }\r\n\r\n update(assessmentClass: Weissman.Model.Assessments.AssessmentClass) {\r\n return lastValueFrom(this._http.put(this._baseUrl, assessmentClass));\r\n }\r\n\r\n deleteClass(assessmentClassId: number) {\r\n return lastValueFrom(this._http.delete(`${this._baseUrl}/${assessmentClassId}`));\r\n }\r\n}\r\n","// Combination of\r\n// https://stackoverflow.com/a/50736992/18059803\r\n// and\r\n// https://stackoverflow.com/a/43589069/18059803\r\n\r\n// This directive does two things:\r\n// Converts a decimal to a percentage for a display (but keeps the decimal for saving)\r\n// and\r\n// Allows the consuming component to specify the number of decimal places to display\r\n\r\n// Usage\r\n// \r\n\r\nimport { Directive, ElementRef, Input, forwardRef, HostListener } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\n\r\n@Directive({\r\n selector: '[toPercentage]',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => ToPercentDirective),\r\n multi: true\r\n }],\r\n host: {\r\n // \"[value]\": 'ngModel',\r\n '(blur)': 'onBlur()'\r\n }\r\n})\r\nexport class ToPercentDirective implements ControlValueAccessor {\r\n constructor(private el: ElementRef) {\r\n this.el.nativeElement.style.textAlign = 'right';\r\n }\r\n\r\n @Input() precision: number;\r\n\r\n private innerValue: string;\r\n private toNumber: number;\r\n private toPercent: number;\r\n private regex: RegExp = new RegExp(/^\\d*\\.?\\d{0,3}$/g);\r\n private specialKeys: Array = ['Backspace', 'Tab', 'End', 'Home', '-', 'ArrowLeft', 'ArrowRight', 'Del', 'Delete'];\r\n\r\n @HostListener('keydown', ['$event'])\r\n onKeyDown(event: KeyboardEvent) {\r\n // Allow Backspace, tab, end, and home keys\r\n if (!this.precision || this.specialKeys.indexOf(event.key) !== -1) {\r\n return;\r\n }\r\n const current: string = this.el.nativeElement.value;\r\n const position = this.el.nativeElement.selectionStart;\r\n const next: string = [current.slice(0, position), event.key == 'Decimal' ? '.' : event.key, current.slice(position)].join('');\r\n if (next && !String(next).match(new RegExp(`^\\\\d*\\\\.?\\\\d{0,${ this.precision }}$`, 'g'))) {\r\n event.preventDefault();\r\n }\r\n }\r\n\r\n public onChangeCallback: any = (_) => { console.log(_); };\r\n public onTouched: any = () => { /*Empty*/ };\r\n\r\n onBlur() {\r\n let input = this.el.nativeElement.value;\r\n if (!input) {\r\n input = 0;\r\n }\r\n this.toPercent = new Decimal(input).dividedBy(100).toNumber();\r\n if (new Decimal(input).toNumber() !== this.toNumber) {\r\n this.toNumber = new Decimal(input).toNumber();\r\n this.onChangeCallback(this.toPercent);\r\n }\r\n this.el.nativeElement.value = this.toNumber.toFixed(this.precision);\r\n }\r\n\r\n get value(): any {\r\n return this.innerValue;\r\n }\r\n\r\n //set accessor including call the onchange callback\r\n set value(v: any) {\r\n if (v !== this.innerValue) {\r\n this.innerValue = v;\r\n this.onChangeCallback(v);\r\n }\r\n }\r\n\r\n writeValue(val: string): void {\r\n // this.ngModel.ControlValueAccessor.writeValue(val);\r\n this.toNumber = new Decimal(val || 0).times(100).toNumber();\r\n if (this.toNumber !== 0) {\r\n this.el.nativeElement.value = this.toNumber.toFixed(this.precision);\r\n }\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n // console.log(fn);\r\n this.onChangeCallback = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n // console.log(fn);\r\n this.onTouched = fn;\r\n }\r\n}\r\n","\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Use this Assessment Class as Default for these Property Type(s)

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Parcel Prop TypeDefault
{{default.propertyType.propTypeAbbr}}\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Components Available by Property Class

\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Parcel Prop TypeComponentEnabled
{{comp.propertyType.propTypeAbbr}}{{comp.assessmentComponent.componentName}}\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Ratios

\r\n
\r\n
\r\n
\r\n \r\n

(doesn't vary by individual assessor)

\r\n
\r\n
\r\n
\r\n \r\n

(doesn't change annually)

\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Tax YearRatio (%)
{{ratio.taxYear}}\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport * as _ from 'lodash';\r\nimport { AssessmentClassUI } from '../List/assessmentClassListPanel.component';\r\nimport { AssessmentClassService } from '../assessmentClass.service';\r\nimport { PropertyTypeService } from '../../Common/Services/propertyType.service.upgrade';\r\nimport { filter, uniqBy, map, sortBy, reject, orderBy, difference } from 'lodash/fp';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\n\r\nexport interface AssessmentClassModalParams {\r\n assessmentClass: AssessmentClassUI;\r\n state: Weissman.Model.Misc.State;\r\n assessor: Core.AssessorModel;\r\n}\r\n\r\ninterface ACDefault {\r\n propertyType: Weissman.Model.Assessments.PropertyType;\r\n propertyTypeID: number;\r\n isDefault: boolean;\r\n}\r\n\r\ninterface PropTypeComponentCombo {\r\n name: string;\r\n assessmentComponent: Weissman.Model.Assessments.AssessmentComponent;\r\n propertyType: Weissman.Model.Assessments.PropertyType;\r\n sequence: number;\r\n}\r\n\r\ninterface EfActionEntity {\r\n efAction: string;\r\n}\r\n\r\n@Component({\r\n selector: 'assessment-class-modal',\r\n templateUrl: './assessmentClassModal.component.html',\r\n styles: [`\r\n .panel-flat-header, .table {\r\n margin-bottom: 0;\r\n }\r\n\r\n .panel-flat-body {\r\n min-height: initial;\r\n max-height: 300px\r\n }\r\n\r\n td, th {\r\n text-align: center;\r\n }\r\n\r\n .help-block {\r\n display: inline-block;\r\n }\r\n `]\r\n})\r\nexport class AssessmentClassModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _assessmentClassService: AssessmentClassService,\r\n private readonly _propertyTypeService: PropertyTypeService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _restrictService: RestrictService\r\n ) { }\r\n params: AssessmentClassModalParams;\r\n result: boolean;\r\n\r\n loading: boolean = false;\r\n headerLabel: string;\r\n ac: AssessmentClassUI;\r\n availableDefaults: ACDefault[] = [];\r\n availableCombos: PropTypeComponentCombo[] = [];\r\n hasEditPermission: boolean = false;\r\n chosenComponent: PropTypeComponentCombo;\r\n yearToAdd: number;\r\n\r\n private _availableComponents: Weissman.Model.Assessments.AssessmentComponent[];\r\n private _availablePropertyTypes: Weissman.Model.Assessments.PropertyType[];\r\n private _ratioYears: number[];\r\n private _currentYear: number;\r\n\r\n get readOnly(): boolean {\r\n return !(this.hasEditPermission && !this.params.assessor);\r\n }\r\n\r\n get readOnlyRatio(): boolean {\r\n return !(this.hasEditPermission && (!this.params.assessor || this.ac.ratioSetAtAssessor));\r\n }\r\n\r\n get undeletedComponents(): Weissman.Model.Assessments.AssessmentClassComponent[] {\r\n return _.reject(this.ac.assessmentClassComponents, {efAction: 'delete'});\r\n }\r\n\r\n get undeletedDefaults(): Weissman.Model.Assessments.AssessmentClassDefault[] {\r\n return _.reject(this.ac.assessmentClassDefaults, {efAction: 'delete'});\r\n }\r\n\r\n get undeletedRatios(): Weissman.Model.Assessments.AssessmentClassRatio[] {\r\n return _.flow([\r\n reject({efAction: 'delete'}),\r\n orderBy(['taxYear'], ['desc'])\r\n ])(this.ac.assessmentClassRatios);\r\n }\r\n\r\n get availableYears(): any {\r\n return _.flow([\r\n map('taxYear'),\r\n difference(this._ratioYears)\r\n ])(this.ac.assessmentClassRatios);\r\n }\r\n\r\n async ngOnInit() {\r\n this.ac = this.params.assessmentClass;\r\n this.headerLabel = `Assessment Class for ${this.params.state.fullName}`;\r\n this.hasEditPermission = this._restrictService.isInRole(Roles.STATEEDIT);\r\n this._currentYear = new Date().getFullYear();\r\n this._ratioYears = _.range(this._currentYear - 10, this._currentYear + 5).reverse();\r\n\r\n this.loading = true;\r\n try {\r\n this._availableComponents = await this._assessmentClassService.getAssessmentComponents();\r\n this._availablePropertyTypes = await this._propertyTypeService.get();\r\n this._initDefaults();\r\n this._getAvailableCombos();\r\n\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n updateEfAction(entity: EfActionEntity) {\r\n entity.efAction = entity.efAction || 'update';\r\n }\r\n\r\n removeEntity(entityArray: EfActionEntity[], entity: EfActionEntity): void {\r\n if (entity.efAction === 'add') {\r\n _.remove(entityArray, entity);\r\n } else {\r\n entity.efAction = 'delete';\r\n }\r\n }\r\n\r\n toggleDefault(availableDefault: ACDefault) {\r\n if(availableDefault.isDefault) {\r\n const acDefault = {\r\n propertyTypeID: availableDefault.propertyTypeID,\r\n efAction: 'add',\r\n assessmentClassID: this.ac.assessmentClassID\r\n } as Weissman.Model.Assessments.AssessmentClassDefault;\r\n\r\n this.ac.assessmentClassDefaults.push(acDefault);\r\n } else {\r\n this._deleteDefault(availableDefault.propertyTypeID);\r\n }\r\n }\r\n\r\n deleteComponent(component: Weissman.Model.Assessments.AssessmentClassComponent) {\r\n if(component.inUse) {\r\n this._toastr.error('Component is in use.', 'Error');\r\n } else {\r\n this.removeEntity(this.ac.assessmentClassComponents, component);\r\n this._getAvailableCombos();\r\n this._initDefaults();\r\n }\r\n }\r\n\r\n addComponent() {\r\n const component = {\r\n propertyTypeID: this.chosenComponent.propertyType.propertyTypeID,\r\n assessmentComponentID: this.chosenComponent.assessmentComponent.assessmentComponentID,\r\n propertyType: this.chosenComponent.propertyType,\r\n assessmentComponent: this.chosenComponent.assessmentComponent,\r\n enabled: true,\r\n inUse: false,\r\n efAction: 'add',\r\n assessmentClassID: this.ac.assessmentClassID || undefined\r\n } as Weissman.Model.Assessments.AssessmentClassComponent;\r\n\r\n this.ac.assessmentClassComponents.push(component);\r\n this._getAvailableCombos();\r\n this._initDefaults();\r\n\r\n setTimeout(() => this.chosenComponent = undefined);\r\n }\r\n\r\n onEnabledChange(component: Weissman.Model.Assessments.AssessmentClassComponent): void {\r\n this.updateEfAction(component);\r\n this._initDefaults();\r\n }\r\n\r\n onStateWideRatioChange() {\r\n this.ac.ratioSetAtAssessor = !this.ac.ratioSetAtAssessor;\r\n this.updateEfAction(this.ac);\r\n }\r\n\r\n onFixedRatioChange() {\r\n if(this.ac.fixedRatio) {\r\n const latest = _.maxBy(this.undeletedRatios, 'taxYear');\r\n\r\n const fixed = {\r\n assessorID: this.params.assessor ? this.params.assessor.assessorID : null,\r\n assessmentRatio: latest ? latest.assessmentRatio || 1 : 1,\r\n taxYear: null,\r\n efAction: 'add'\r\n } as Weissman.Model.Assessments.AssessmentClassRatio;\r\n\r\n if (this.ac.assessmentClassID) {\r\n fixed.assessmentClassID = this.ac.assessmentClassID;\r\n }\r\n\r\n this.ac.assessmentClassRatios = _.flow([\r\n reject({efAction: 'add'}),\r\n map(x => {\r\n x.efAction = 'delete';\r\n return x;\r\n })\r\n ])(this.ac.assessmentClassRatios);\r\n\r\n this.ac.assessmentClassRatios.push(fixed);\r\n\r\n } else {\r\n const firstRatio = this.undeletedRatios[0];\r\n firstRatio.taxYear = this._currentYear;\r\n this.updateEfAction(firstRatio);\r\n }\r\n }\r\n\r\n addRatio(): void {\r\n const ratio = {\r\n assessorID: this.params.assessor ? this.params.assessor.assessorID : null,\r\n assessmentRatio: 0,\r\n taxYear: this.yearToAdd,\r\n efAction: 'add'\r\n } as Weissman.Model.Assessments.AssessmentClassRatio;\r\n\r\n if (this.ac.assessmentClassID !== undefined) {\r\n ratio.assessmentClassID = this.ac.assessmentClassID;\r\n }\r\n this.ac.assessmentClassRatios.push(ratio);\r\n\r\n setTimeout(() => {\r\n this.yearToAdd = undefined;\r\n });\r\n }\r\n\r\n async save(){\r\n const acToSave = _.omit(this.ac, 'propTypes', 'fixedRatio');\r\n\r\n if(!this.undeletedRatios.length) {\r\n this._toastr.error('Please enter at least one ratio.');\r\n\r\n return;\r\n }\r\n\r\n this.loading = true;\r\n try {\r\n const parcelsAffectedPromises = _.flow([\r\n filter({efAction: 'update'}),\r\n map(x => this._assessmentClassService.getParcelsAffectedByRatio(x.assessmentClassRatioID))\r\n ])(acToSave.assessmentClassRatios);\r\n\r\n const parcelsAffectedArr = await Promise.all(parcelsAffectedPromises);\r\n const parcelsAffected = _.sum(parcelsAffectedArr);\r\n\r\n if(parcelsAffected > 0) {\r\n try {\r\n const message = `${parcelsAffected} parcels will be affected by changing this assessment class's ratio(s)`;\r\n await this._messageModalService.confirm(message, 'Save Assessment Class?');\r\n } catch(e) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n if(acToSave.assessmentClassID) {\r\n await this._assessmentClassService.update(acToSave as Weissman.Model.Assessments.AssessmentClass);\r\n } else {\r\n await this._assessmentClassService.create(acToSave as Weissman.Model.Assessments.AssessmentClass);\r\n }\r\n\r\n this.result = true;\r\n this.close();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n close() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _initDefaults(): void {\r\n const newAvailableDefaults = _.flow([\r\n filter('enabled'),\r\n uniqBy('propertyTypeID'),\r\n map((x: Weissman.Model.Assessments.AssessmentClassComponent) => {\r\n return {\r\n propertyType: x.propertyType,\r\n propertyTypeID: x.propertyType.propertyTypeID,\r\n isDefault: _.some(this.undeletedDefaults, {propertyTypeID: x.propertyTypeID})\r\n };\r\n }),\r\n sortBy(x => x.propertyType.sequence)\r\n ])(this.undeletedComponents) as ACDefault[];\r\n\r\n const diff = _.differenceBy(this.availableDefaults, newAvailableDefaults, 'propertyTypeID');\r\n\r\n if(diff.length) {\r\n this._deleteDefault(diff[0].propertyTypeID);\r\n }\r\n\r\n this.availableDefaults = newAvailableDefaults;\r\n }\r\n\r\n private _deleteDefault(propertyTypeId: number) {\r\n const acDefault = _.find(this.ac.assessmentClassDefaults, {propertyTypeID: propertyTypeId});\r\n\r\n if(acDefault) {\r\n this.removeEntity(this.ac.assessmentClassDefaults, acDefault);\r\n }\r\n }\r\n\r\n private _getAvailableCombos(): void {\r\n const availableCombos = [];\r\n\r\n _.forEach(this._availableComponents, x => {\r\n _.forEach(this._availablePropertyTypes, y => {\r\n const comboAlreadyAdded = _.some(this.undeletedComponents, {\r\n assessmentComponentID: x.assessmentComponentID,\r\n propertyTypeID: y.propertyTypeID\r\n });\r\n\r\n if(!comboAlreadyAdded) {\r\n availableCombos.push({\r\n name: `${y.propTypeAbbr} ${x.componentName}`,\r\n assessmentComponent: x,\r\n propertyType: y,\r\n sequence: y.sequence\r\n });\r\n }\r\n });\r\n });\r\n\r\n this.availableCombos = _.sortBy(availableCombos, ['sequence', 'name']);\r\n }\r\n}\r\n","\r\n
\r\n
\r\n

Assessment Classes

\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Assessment ClassificationParcel Prop TypesComponent(s)RatioNotes
{{ac.name}}\r\n
{{propType.abbr}}
\r\n
\r\n
{{propType.componentsString}}
\r\n
\r\n
Defined at Assessor
\r\n
\r\n
\r\n \r\n {{ratio.assessmentRatio | percent:'1.0-3'}}\r\n \r\n
\r\n
\r\n \r\n {{ratio.taxYear}}: {{ratio.assessmentRatio | percent:'1.0-3'}},\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\t\t\t\r\n\t\t
\r\n
\r\n
\r\n","import { Component, OnInit, Input } from '@angular/core';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport * as _ from 'lodash';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { AssessmentClassService } from '../assessmentClass.service';\r\nimport { map, sortBy, filter, groupBy, join } from 'lodash/fp';\r\nimport { AssessmentClassModalParams, AssessmentClassModalComponent } from '../View/assessmentClassModal.component';\r\n\r\nexport interface AssessmentClassUI extends Weissman.Model.Assessments.AssessmentClass{\r\n propTypes: {\r\n abbr: string;\r\n componentsString: string;\r\n } [];\r\n isVisible?: boolean;\r\n fixedRatio: boolean;\r\n isHovered?: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'assessment-class-list-panel',\r\n templateUrl: './assessmentClassListPanel.component.html'\r\n})\r\nexport class AssessmentClassListPanelComponent implements OnInit {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _assessmentClassService: AssessmentClassService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: WeissmanModalService\r\n ) {}\r\n\r\n @Input() state: Weissman.Model.Misc.State;\r\n @Input() assessor: Core.AssessorModel;\r\n\r\n assessmentClasses: AssessmentClassUI[];\r\n serverAction: boolean = false;\r\n showStateClasses: boolean = false;\r\n hasEditPermission: boolean = false;\r\n\r\n async ngOnInit(): Promise {\r\n this.hasEditPermission = this._restrictService.isInRole(Roles.STATEEDIT);\r\n\r\n await this._getAssessmentClasses();\r\n }\r\n\r\n onShowUnusedChanged(): void {\r\n this.assessmentClasses = _.map(this.assessmentClasses, this._setClassVisibility.bind(this));\r\n }\r\n\r\n async launchClassModal(assessmentClass?: AssessmentClassUI) {\r\n if(!assessmentClass) {\r\n const lastClass = _.maxBy(this.assessmentClasses, 'sequence');\r\n const sequence = lastClass ? lastClass.sequence + 1 : 0;\r\n assessmentClass = {\r\n stateID: this.state.stateID,\r\n name: '',\r\n description: '',\r\n ratioSetAtAssessor: true,\r\n sequence: sequence,\r\n fixedRatio: true,\r\n assessmentClassComponents: [],\r\n assessmentClassDefaults: [],\r\n assessmentClassRatios: [{\r\n assessmentRatio: 1,\r\n taxYear: null,\r\n assessorID: this.assessor ? this.assessor.assessorID : null,\r\n efAction: 'add'\r\n } as Weissman.Model.Assessments.AssessmentClassRatio],\r\n efAction: 'add'\r\n } as AssessmentClassUI;\r\n }\r\n const params: AssessmentClassModalParams = {\r\n assessmentClass: _.cloneDeep(assessmentClass),\r\n state: this.state,\r\n assessor: this.assessor\r\n };\r\n\r\n const reloadClasses = await this._modalService.showAsync(AssessmentClassModalComponent, params, 'modal-lg');\r\n\r\n if(reloadClasses) {\r\n await this._getAssessmentClasses();\r\n }\r\n }\r\n\r\n async deleteClass(assessmentClass: AssessmentClassUI) {\r\n try {\r\n await this._messageModalService.confirm(`Delete ${assessmentClass.name}?`);\r\n } catch(e) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.serverAction = true;\r\n try {\r\n await this._assessmentClassService.deleteClass(assessmentClass.assessmentClassID);\r\n await this._getAssessmentClasses();\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n private async _getAssessmentClasses(): Promise {\r\n this.serverAction = true;\r\n try {\r\n const assessorId = this.assessor ? this.assessor.assessorID : 0;\r\n const assessmentClasses = await this._assessmentClassService.getList(this.state.stateID, assessorId);\r\n this.assessmentClasses = _.flow([\r\n map(ac => {\r\n const propTypes = _.flow([\r\n filter('enabled'),\r\n groupBy('propertyTypeID'),\r\n map(components => {\r\n const componentsString = _.flow([\r\n map('assessmentComponent'),\r\n map('componentName'),\r\n join(', ')\r\n ])(components);\r\n\r\n return {\r\n abbr: components[0].propertyType.propTypeAbbr,\r\n componentsString\r\n };\r\n })\r\n ])(ac.assessmentClassComponents);\r\n\r\n if (this.assessor) {\r\n ac.assessmentClassRatios = _.filter(ac.assessmentClassRatios, ratio => {\r\n if (ac.ratioSetAtAssessor) {\r\n return ratio.assessorID === this.assessor.assessorID;\r\n }\r\n\r\n return true;\r\n });\r\n }\r\n\r\n ac.assessmentClassRatios = _.orderBy(ac.assessmentClassRatios, ['taxYear'], ['desc']);\r\n const fixedRatio = !_.every(ac.assessmentClassRatios, 'taxYear');\r\n\r\n return { ...ac, propTypes, fixedRatio };\r\n }),\r\n sortBy('sequence'),\r\n map(this._setClassVisibility.bind(this))\r\n ])(assessmentClasses);\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n private _setClassVisibility(ac: AssessmentClassUI) {\r\n if (this.assessor) {\r\n if (this.showStateClasses) {\r\n ac.isVisible = true;\r\n } else {\r\n ac.isVisible = !ac.ratioSetAtAssessor\r\n || (ac.ratioSetAtAssessor\r\n && _.some(ac.assessmentClassRatios, { assessorID: this.assessor.assessorID })\r\n );\r\n }\r\n } else {\r\n ac.isVisible = true;\r\n }\r\n\r\n return ac;\r\n }\r\n\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\nexport class JurisdictionSpecialist {\r\n assessorID: number;\r\n jurisdictionSpecialist: Weissman.Model.Workflow.JurisdictionSpecialist;\r\n propertyTypeID: number;\r\n propertyTypeXStateHasChildExceptions: boolean;\r\n siteClassExceptions: Weissman.Model.Workflow.JurisdictionSpecialist[];\r\n stateID: number;\r\n}\r\n\r\nexport interface StateAssessorException extends Weissman.Model.Workflow.JurisdictionSpecialist {\r\n assessor: Weissman.Model.Domain.SiteAssessorDTO;\r\n hasSiteClassExceptions: boolean;\r\n}\r\n\r\n@Injectable()\r\nexport class ProtocolService {\r\n constructor(private readonly _http: HttpClient) {}\r\n\r\n private readonly _baseUrl = 'api/jurisdictionSpecialist';\r\n\r\n getByState(stateId: number): Promise {\r\n return lastValueFrom(this._http.get(`${this._baseUrl}/state/${stateId}`)) as Promise;\r\n }\r\n\r\n getByAssessor(assessorId: number): Promise {\r\n return lastValueFrom(this._http.get(`${this._baseUrl}/assessor/${assessorId}`)) as Promise;\r\n }\r\n\r\n getExceptionsByStateXPropertyType(stateId: number, propertyTypeId: number): Promise {\r\n return lastValueFrom(this._http.get(`${this._baseUrl}/state/${stateId}/ExceptionsByPropertyType/${propertyTypeId}`)) as Promise;\r\n }\r\n\r\n saveStateSpecialists(specialists: Weissman.Model.Workflow.JurisdictionSpecialist[]): Promise {\r\n return lastValueFrom(this._http.put(`${this._baseUrl}`, specialists)) as Promise;\r\n }\r\n\r\n saveAssessorSpecialists(specialists: Weissman.Model.Workflow.JurisdictionSpecialist[], assessorId: number): Promise {\r\n const updatedModel = {\r\n jurisdictionSpecialists: specialists\r\n };\r\n return lastValueFrom(this._http.post(`${this._baseUrl}/assessorProtocols/${assessorId}`, updatedModel)) as Promise;\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport { IWeissmanModalComponent } from '../Compliance/WeissmanModalService';\r\nimport { ProtocolService, StateAssessorException } from './protocol.service';\r\n\r\nexport interface StateAssessorExceptionsParams {\r\n stateId: number;\r\n propertyTypeId: number;\r\n propertyTypeName: string;\r\n}\r\n\r\n@Component({\r\n selector: 'assessor-exceptions-modal',\r\n template: `\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Assessor AbbrAssignee
\r\n {{exception.assessor.abbr + ' ' + exception.assessor.municipalityName}}\r\n \r\n {{exception.user.firstName}} {{exception.user.lastName}} ({{exception.team.name}}) \r\n *\r\n
\r\n
\r\n\r\n
\r\n * Additional Site Class assignees exist (not shown)\r\n
\r\n
\r\n `,\r\n})\r\nexport class StateAssessorExceptionsModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _protocolService: ProtocolService\r\n ) { }\r\n\r\n params: StateAssessorExceptionsParams;\r\n result: void;\r\n\r\n loading: boolean = false;\r\n exceptions: StateAssessorException[];\r\n propertyType: string;\r\n deadlineType: string;\r\n isEarliestPossibleDeadline: boolean = false;\r\n headerLabel: string;\r\n\r\n showFootnote: boolean = false;\r\n\r\n async ngOnInit() {\r\n this.headerLabel = `Assessor Exceptions - ${this.params.propertyTypeName}`;\r\n this.loading = true;\r\n\r\n try {\r\n this.exceptions = await this._protocolService.getExceptionsByStateXPropertyType(this.params.stateId, this.params.propertyTypeId);\r\n this.showFootnote = _.some(this.exceptions, 'hasSiteClassExceptions');\r\n\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n getAssessorSref(exception: StateAssessorException) {\r\n return {\r\n target: 'assessor',\r\n options: {\r\n stateId: this.params.stateId,\r\n id: exception.assessorID,\r\n }\r\n };\r\n }\r\n\r\n close() {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\n
\r\n
\r\n \r\n

Jurisdiction Specialists

\r\n

State Protocols

\r\n
\r\n\t\t\t\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n {{row.propertyTypeName}}\r\n \r\n
\r\n {{getJSDisplay(row)}}\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
Exceptions (Specific Site Class Specialists):
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{exception.siteClassName}}\r\n {{getAssigneeDisplay(exception)}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, Input } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { RestrictService, Roles } from '../Common/Permissions/restrict.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { WeissmanModalService } from '../Compliance/WeissmanModalService';\r\nimport { JurisdictionSpecialist, ProtocolService } from './protocol.service';\r\nimport { PropertyTypeService } from '../Common/Services/propertyType.service.upgrade';\r\nimport { SiteClassService } from '../Entity/Site/siteClass.service';\r\nimport { map, sortBy } from 'lodash/fp';\r\nimport { StateAssessorExceptionsParams, StateAssessorExceptionsModalComponent } from './stateAssessorExceptionsModal.component';\r\nimport { NavigationService } from '../Layout/navigation.service';\r\nimport { EmptyGuid } from '../constants.new';\r\n\r\nclass JurisdictionSpecialistUI extends JurisdictionSpecialist {\r\n propertyTypeName: string;\r\n availableSiteClasses: SiteClassUI[];\r\n chosenSiteClass: SiteClassUI;\r\n isNoneAssigned: boolean;\r\n disablePicker: boolean;\r\n get undeletedExceptions() {\r\n return _.reject(this.siteClassExceptions, {efAction: 'delete'});\r\n }\r\n get showNoneAssigned() {\r\n return !this.undeletedExceptions.length;\r\n }\r\n}\r\n\r\ninterface SiteClassUI extends Weissman.Model.Domain.SiteClassSecondary {\r\n name: string;\r\n}\r\n\r\n@Component({\r\n selector: 'protocol-list-panel',\r\n templateUrl: './protocolListPanel.component.html',\r\n styles: [`\r\n .exceptions-table td {\r\n padding: 3px 8px;\r\n }\r\n `]\r\n})\r\nexport class ProtocolListPanelComponent {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _protocolService: ProtocolService,\r\n private readonly _toastrService: ToastrService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _propertyTypeService: PropertyTypeService,\r\n private readonly _siteClassService: SiteClassService,\r\n private readonly _navigationService: NavigationService\r\n ) {}\r\n\r\n @Input() state: Weissman.Model.Misc.State;\r\n @Input() assessor: Core.AssessorModel;\r\n\r\n hasEditPermission: boolean = this._restrictService.isInRole(Roles.STATEEDIT);\r\n showBody: boolean = false;\r\n editMode: boolean = false;\r\n serverAction: boolean = false;\r\n jurisdictionSpecialists: JurisdictionSpecialistUI[];\r\n exceptionToEdit: Weissman.Model.Workflow.JurisdictionSpecialist;\r\n\r\n private _availableSiteClasses: SiteClassUI[];\r\n private _originalJurisdictionSpecialists: JurisdictionSpecialistUI[];\r\n\r\n private get _entityIdString(): string {\r\n return this.assessor ? 'assessorID' : 'stateID';\r\n }\r\n\r\n async expandOrCollapse(): Promise {\r\n if(this.editMode) {\r\n return;\r\n }\r\n\r\n this.showBody = !this.showBody;\r\n\r\n if(this.showBody) {\r\n this.serverAction = true;\r\n try {\r\n await this._loadSpecialists();\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n }\r\n\r\n getJSDisplay(js: JurisdictionSpecialistUI): string {\r\n if(js.isNoneAssigned) {\r\n return 'None Assigned';\r\n } else {\r\n return this.getAssigneeDisplay(js.jurisdictionSpecialist);\r\n }\r\n }\r\n\r\n getAssigneeDisplay(entity: any): string {\r\n if (entity.user && entity.team) {\r\n return `${entity.user.lastName}, ${entity.user.firstName} (${entity.team.name})`;\r\n } else {\r\n return '';\r\n }\r\n }\r\n\r\n async goToEditMode(): Promise {\r\n if(!this._availableSiteClasses) {\r\n const availableSiteClasses = await this._siteClassService.getSecondaries();\r\n this._availableSiteClasses = _.flow([\r\n map(x => {\r\n const name = `${x.siteClassPrimary.siteClassPrimaryDesc} - ${x.siteClassDesc}`;\r\n return { name, ...x };\r\n }),\r\n sortBy('name')\r\n ])(availableSiteClasses);\r\n\r\n }\r\n\r\n this.jurisdictionSpecialists = _.map(this.jurisdictionSpecialists, js => {\r\n js.availableSiteClasses = this._getJSAvailableSiteClasses(js);\r\n return js;\r\n });\r\n\r\n this._originalJurisdictionSpecialists = _.cloneDeep(this.jurisdictionSpecialists);\r\n this.editMode = true;\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you wish to leave?');\r\n }\r\n\r\n cancel() {\r\n this.jurisdictionSpecialists = this._originalJurisdictionSpecialists;\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n editException(exception: Weissman.Model.Workflow.JurisdictionSpecialist): void {\r\n this.exceptionToEdit = _.cloneDeep(exception);\r\n }\r\n\r\n jsUserChanged(user: Core.UserTeamModel, jsUI: JurisdictionSpecialistUI): void {\r\n if(this._setNewUser(user, jsUI.jurisdictionSpecialist)) {\r\n if(jsUI[this._entityIdString] && jsUI.jurisdictionSpecialist.jurisdictionSpecialistID) {\r\n if (!jsUI.jurisdictionSpecialist.efAction) {\r\n jsUI.jurisdictionSpecialist.efAction = 'update';\r\n }\r\n if (this.assessor && jsUI.jurisdictionSpecialist.assessorID !== this.assessor.assessorID) {\r\n jsUI.jurisdictionSpecialist.efAction = 'add';\r\n jsUI.jurisdictionSpecialist.assessorID = this.assessor.assessorID;\r\n }\r\n } else {\r\n jsUI.jurisdictionSpecialist.efAction = 'add';\r\n jsUI.jurisdictionSpecialist.stateID = jsUI.stateID;\r\n jsUI.jurisdictionSpecialist.assessorID = jsUI.assessorID;\r\n jsUI.jurisdictionSpecialist.propertyTypeID = jsUI.propertyTypeID;\r\n }\r\n }\r\n }\r\n\r\n noneAssignedChanged(js: JurisdictionSpecialistUI): void {\r\n if(js.isNoneAssigned) {\r\n if(js.jurisdictionSpecialist.efAction === 'add') {\r\n js.jurisdictionSpecialist = this._getBlankJS();\r\n } else {\r\n js.jurisdictionSpecialist.efAction = 'delete';\r\n }\r\n } else {\r\n if(js.jurisdictionSpecialist[this._entityIdString]) {\r\n js.jurisdictionSpecialist.efAction = 'update';\r\n }\r\n }\r\n }\r\n\r\n exceptionUserChanged(user: Core.UserTeamModel, exception: Weissman.Model.Workflow.JurisdictionSpecialist) : void{\r\n if(this._setNewUser(user, exception)) {\r\n this.exceptionToEdit = undefined;\r\n }\r\n }\r\n\r\n deleteException(exception: Weissman.Model.Workflow.JurisdictionSpecialist, js: JurisdictionSpecialistUI): void {\r\n if(exception.efAction === 'add') {\r\n _.remove(js.siteClassExceptions, exception);\r\n } else {\r\n exception.efAction = 'delete';\r\n }\r\n\r\n js.availableSiteClasses = this._getJSAvailableSiteClasses(js);\r\n }\r\n\r\n isExceptionInEditMode(exception: Weissman.Model.Workflow.JurisdictionSpecialist): boolean {\r\n return this.exceptionToEdit && exception.jurisdictionSpecialistID === this.exceptionToEdit.jurisdictionSpecialistID;\r\n }\r\n\r\n cancelUserChange(exception: Weissman.Model.Workflow.JurisdictionSpecialist, js: JurisdictionSpecialistUI): void {\r\n if(exception.efAction === 'add') {\r\n _.remove(js.siteClassExceptions, exception);\r\n }\r\n\r\n this.exceptionToEdit = undefined;\r\n }\r\n\r\n addSiteClass(js: JurisdictionSpecialistUI): void {\r\n if(!js.siteClassExceptions) {\r\n js.siteClassExceptions = [];\r\n }\r\n\r\n js.siteClassExceptions.push({\r\n stateID: this.state.stateID,\r\n propertyTypeID: js.propertyTypeID,\r\n assessorID: js.assessorID,\r\n efAction: 'add',\r\n siteClassSecondaryID: js.chosenSiteClass.siteClassSecondaryID,\r\n siteClassName: js.chosenSiteClass.name\r\n } as Weissman.Model.Workflow.JurisdictionSpecialist);\r\n\r\n js.availableSiteClasses = this._getJSAvailableSiteClasses(js);\r\n\r\n this.editException(_.last(js.siteClassExceptions));\r\n\r\n setTimeout(() => {\r\n js.chosenSiteClass = undefined;\r\n });\r\n }\r\n\r\n async save() {\r\n const specialistsToSave = _.cloneDeep(this.jurisdictionSpecialists);\r\n\r\n let changedSpecialists = _.reduce(specialistsToSave, (changedJSs: Weissman.Model.Workflow.JurisdictionSpecialist[], js: JurisdictionSpecialistUI) => {\r\n if(js.jurisdictionSpecialist.efAction) {\r\n changedJSs.push(js.jurisdictionSpecialist);\r\n }\r\n\r\n const changedExceptions = _.filter(js.siteClassExceptions, 'efAction');\r\n\r\n return _.union(changedJSs, changedExceptions);\r\n }, []);\r\n\r\n changedSpecialists = _.map(changedSpecialists, x => {\r\n const mapped = _.omit(x, 'team', 'user', 'siteClassName', 'siteClassSecondary');\r\n // Saving this bit of code for when Assessor is refactored\r\n // if(this.assessor) {\r\n // mapped.assessorID = this.assessor.assessorID;\r\n // }\r\n\r\n return mapped as Weissman.Model.Workflow.JurisdictionSpecialist;\r\n });\r\n\r\n this.serverAction = true;\r\n try {\r\n this.assessor\r\n ? await this._protocolService.saveAssessorSpecialists(changedSpecialists, this.assessor.assessorID)\r\n : await this._protocolService.saveStateSpecialists(changedSpecialists);\r\n\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n\r\n await this._loadSpecialists();\r\n }\r\n finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n async showExceptionsModal(js: JurisdictionSpecialistUI): Promise {\r\n const params: StateAssessorExceptionsParams = {\r\n stateId: this.state.stateID,\r\n propertyTypeId: js.propertyTypeID,\r\n propertyTypeName: js.propertyTypeName\r\n };\r\n\r\n await this._modalService.showAsync(StateAssessorExceptionsModalComponent, params, 'modal-md');\r\n }\r\n\r\n private _getJSAvailableSiteClasses(js: JurisdictionSpecialistUI): SiteClassUI[] {\r\n return _.reject(this._availableSiteClasses, sc => {\r\n return _.some(js.undeletedExceptions, {siteClassSecondaryID: sc.siteClassSecondaryID});\r\n });\r\n }\r\n\r\n private _setNewUser(user: Core.UserTeamModel, js: Weissman.Model.Workflow.JurisdictionSpecialist): boolean {\r\n if(!user) {\r\n return false;\r\n }\r\n\r\n js.userID = user.userID;\r\n js.teamID = user.teamID;\r\n js.user = {\r\n firstName: user.firstName,\r\n lastName: user.lastName,\r\n userID: user.userID,\r\n efAction: null\r\n };\r\n js.team = {\r\n teamID: user.teamID,\r\n name: user.teamName,\r\n efAction: null\r\n } as Weissman.Model.Workflow.Team;\r\n js.efAction = js.efAction || 'update';\r\n\r\n return true;\r\n }\r\n\r\n private _getBlankJS(): Weissman.Model.Workflow.JurisdictionSpecialist {\r\n return {\r\n assessorID: null,\r\n efAction: null,\r\n isException: false,\r\n jurisdictionSpecialistID: 0,\r\n propertyTypeID: 0,\r\n siteClassName: null,\r\n siteClassSecondary: null,\r\n siteClassSecondaryID: null,\r\n stateID: 0,\r\n team: null,\r\n teamID: 0,\r\n user: null,\r\n userID: EmptyGuid\r\n } as unknown as Weissman.Model.Workflow.JurisdictionSpecialist;\r\n }\r\n\r\n private async _getAssessorSpecialists(propertyTypes: Weissman.Model.Assessments.PropertyType[]): Promise {\r\n const assessorSpecialists = await this._protocolService.getByAssessor(this.assessor.assessorID);\r\n\r\n _.forEach(propertyTypes, x => {\r\n if(!_.some(assessorSpecialists, {propertyTypeID: x.propertyTypeID})) {\r\n assessorSpecialists.push({\r\n assessorID: this.assessor.assessorID,\r\n propertyTypeID: x.propertyTypeID,\r\n stateID: this.state.stateID,\r\n propertyTypeXStateHasChildExceptions: false,\r\n siteClassExceptions: null,\r\n jurisdictionSpecialist: {\r\n assessorID: null,\r\n isException: false,\r\n propertyTypeID: x.propertyTypeID,\r\n stateID: this.state.stateID,\r\n teamID: null,\r\n team: {} as Weissman.Model.Workflow.Team,\r\n user: {} as Core.ContactShortDTO,\r\n userID: null\r\n } as Weissman.Model.Workflow.JurisdictionSpecialist\r\n });\r\n }\r\n });\r\n\r\n return assessorSpecialists;\r\n }\r\n\r\n private async _loadSpecialists(): Promise {\r\n const propertyTypes: Weissman.Model.Assessments.PropertyType[] = await this._propertyTypeService.get();\r\n\r\n const stateSpecialists = await this._protocolService.getByState(this.state.stateID);\r\n const jurisdictionSpecialists = this.assessor ? await this._getAssessorSpecialists(propertyTypes) : stateSpecialists;\r\n\r\n this.jurisdictionSpecialists = _(jurisdictionSpecialists)\r\n .map(js => {\r\n const newJS = new JurisdictionSpecialistUI();\r\n _.assign(newJS, js);\r\n\r\n newJS.propertyTypeName = _.find(propertyTypes, {propertyTypeID: js.propertyTypeID}).propTypeName;\r\n newJS.siteClassExceptions = _.sortBy(js.siteClassExceptions, 'siteClassName');\r\n newJS.isNoneAssigned = !js.jurisdictionSpecialist.team\r\n || !js.jurisdictionSpecialist.user\r\n || _.isEmpty(js.jurisdictionSpecialist.team)\r\n || _.isEmpty(js.jurisdictionSpecialist.user);\r\n\r\n if(this.assessor) {\r\n newJS.disablePicker = !_.some(stateSpecialists, stateSpecialist => {\r\n return stateSpecialist.propertyTypeID === js.propertyTypeID &&\r\n stateSpecialist.jurisdictionSpecialist.user !== null;\r\n });\r\n }\r\n\r\n return newJS;\r\n })\r\n .orderBy(x => x.propertyTypeID)\r\n .value();\r\n }\r\n}\r\n","import { Address } from '../../Common/Models/common.model';\r\nimport { efAction } from '../../constants.new';\r\n\r\nexport interface TaxRatesPanelPayload {\r\n taxRateAreas: TaxRateArea[];\r\n taxAuthorities: TaxAuthority[];\r\n}\r\n\r\nexport class TaxRateArea {\r\n constructor() {\r\n this.disabled = false;\r\n this.efAction = 'add';\r\n }\r\n\r\n taxRateAreaId: number;\r\n name: string;\r\n code: string;\r\n addressId: number;\r\n address: Address;\r\n disabled: boolean;\r\n mayBeDeleted: boolean;\r\n assessorId: number;\r\n collectorId: number;\r\n hasAttachments: boolean;\r\n hasComments: boolean;\r\n rowVersion: string;\r\n efAction: efAction;\r\n yearRateSummaryList: YearRateSummary[];\r\n details: TaxRateAreaDetail[];\r\n}\r\n\r\nexport interface YearRateSummary {\r\n year: number;\r\n rate: number;\r\n rateChange: number;\r\n isActual: boolean;\r\n}\r\n\r\nexport interface TaxRateAreaDetail {\r\n taxRateAreaTaxAuthorityDetailId: number;\r\n taxRateAreaId: number;\r\n taxAuthorityId: number;\r\n yearBegin: number;\r\n yearEnd: number;\r\n sequence: number;\r\n rowVersion: string;\r\n efAction: efAction;\r\n}\r\n\r\nexport class TaxAuthority {\r\n constructor() {\r\n this.obtainInAdvance = true;\r\n this.disabled = false;\r\n this.efAction = 'add';\r\n }\r\n\r\n address: Address;\r\n details: TaxAuthorityDetail[];\r\n taxRateAreaTaxAuthorityDetails: TaxRateAreaTaxAuthorityDetail[];\r\n taxAuthorityId: number;\r\n name: string;\r\n code: string;\r\n ptxId: string;\r\n addressId: string;\r\n taxAuthorityCategoryId: number;\r\n taxableAssessmentTypeId: number;\r\n obtainInAdvance: boolean;\r\n disabled: boolean;\r\n defaultAnnualRateIncrease: number;\r\n defaultAnnualRateIncreaseAsPct: string;\r\n certificationMonth: number;\r\n certificationDay: number;\r\n certificationType: any;\r\n certificationDate: Date;\r\n collectorId: number;\r\n hasAttachments: boolean;\r\n hasComments: boolean;\r\n taxAuthorityExemptionTypeId: number;\r\n allowExemptionsOnAlternateAV: boolean;\r\n allowedExemptionAssessmentComponentIds: number[];\r\n qcRequestTimeUtc: Date;\r\n qcRequestUserFullName: string;\r\n rowVersion: string;\r\n efAction: efAction;\r\n queueProcessingStatusId: Core.QueueUpdateStatusEnum;\r\n queueProcessingStatusName: string;\r\n}\r\n\r\nexport class TaxAuthorityDetail {\r\n constructor(taxAuthorityId: number) {\r\n this.efAction = 'add';\r\n this.taxAuthorityId = taxAuthorityId;\r\n this.rateChange = null;\r\n this.rate = null;\r\n }\r\n\r\n taxAuthorityDetailId: number;\r\n taxAuthorityId: number;\r\n taxYear: number;\r\n rate?: number;\r\n rateAsPct: string;\r\n rateAsMills: string;\r\n rateChange?: number;\r\n rateChangeAsPercent: string;\r\n // rateChangeAsMills: string;\r\n billsUtilizing: number;\r\n taxAuthorityStatusId: number;\r\n rowVersion: string;\r\n qcRequestTimeUtc: Date;\r\n qcRequestUserId: string;\r\n qcRequestUserFullName: string;\r\n efAction: efAction;\r\n}\r\n\r\nexport class TaxRateAreaTaxAuthorityDetail {\r\n constructor(taxRateAreaId: number, taxAuthorityId: number) {\r\n this.yearBegin = null;\r\n this.yearEnd = null;\r\n this.efAction = 'add';\r\n this.taxRateAreaId = taxRateAreaId;\r\n this.taxAuthorityId = taxAuthorityId;\r\n }\r\n\r\n taxRateAreaTaxAuthorityDetailId: number;\r\n taxRateAreaId: number;\r\n taxAuthorityId: number;\r\n yearBegin: number;\r\n yearEnd: number;\r\n sequence: number;\r\n rowVersion: string;\r\n efAction: efAction;\r\n taxRateAreaName: string;\r\n}\r\n\r\nexport class TaxRateAreaInclusions {\r\n constructor() {\r\n this.yearsIncluded = [];\r\n }\r\n\r\n taxRateAreaName: string;\r\n yearsIncluded: boolean[];\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\nimport { TaxAuthorityPayload, TaxRateAreaPayload, PanelProjectionsPayload } from './tax.rate.model';\r\n\r\n@Injectable(\r\n { providedIn: 'root'}\r\n)\r\nexport class TaxRateService {\r\n\r\n constructor(private sdHttp: SDHttpService) {}\r\n\r\n getTaxRateArea(taxRateAreaId: number): Promise {\r\n return this.sdHttp.get(`/api/TaxRateArea/Panel/${taxRateAreaId}`);\r\n }\r\n\r\n updateTaxRateArea(taxRateAreaPayload: TaxRateAreaPayload): Promise {\r\n return this.sdHttp.put('/api/TaxRateArea/Panel/', taxRateAreaPayload);\r\n }\r\n\r\n createTaxRateArea(taxRateArea: TaxRateAreaPayload): Promise {\r\n return this.sdHttp.post('/api/TaxRateArea/Panel/', taxRateArea);\r\n }\r\n\r\n deleteTaxRateArea(taxRateAreaId: number): Promise {\r\n return this.sdHttp.delete(`/api/TaxRateArea/Panel/${taxRateAreaId}`);\r\n }\r\n\r\n getTaxAuthority(taxAuthorityId: number): Promise {\r\n return this.sdHttp.get(`/api/TaxAuthority/${taxAuthorityId}`);\r\n }\r\n\r\n updateTaxAuthority(taxAuthorityPayload: TaxAuthorityPayload): Promise {\r\n return this.sdHttp.put('/api/TaxAuthority/', taxAuthorityPayload);\r\n }\r\n\r\n createTaxAuthority(TaxAuthority: TaxAuthorityPayload): Promise {\r\n return this.sdHttp.post('/api/TaxAuthority/', TaxAuthority);\r\n }\r\n\r\n deleteTaxAuthority(taxAuthorityId: number): Promise {\r\n return this.sdHttp.delete(`/api/TaxAuthority/${taxAuthorityId}`);\r\n }\r\n\r\n getPanelProjections(panelProjectionsPayload: PanelProjectionsPayload): Promise {\r\n return this.sdHttp.post('/api/TaxRateArea/PanelProjections', panelProjectionsPayload);\r\n }\r\n\r\n cloneTaxRateArea(taxRateAreaId: number): Promise {\r\n return this.sdHttp.post(`/api/TaxRateArea/Duplicate/${taxRateAreaId}`);\r\n }\r\n\r\n}\r\n","import { Component, OnInit, ViewChild, ElementRef, AfterViewInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { EntityType } from '../../constants.new';\r\nimport { TaxRateService } from '../../Tax-Rate/tax.rate.service';\r\nimport { TaxAuthority, TaxRateArea } from './tax.rates.panel.model';\r\nimport { TaxAuthorityPayload, TaxRateAreaPayload } from '../../Tax-Rate/tax.rate.model';\r\n\r\nexport interface AddTaxEntityModalParams {\r\n assessorId?: number;\r\n collectorId: number;\r\n entityTypeId: number;\r\n defaultAnnualRateIncrease?: number;\r\n}\r\n\r\n@Component({\r\n selector: 'add-tax-entity-modal',\r\n template: `\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n `\r\n})\r\nexport class AddTaxEntityModalComponent implements OnInit, AfterViewInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _taxRateService: TaxRateService) {\r\n }\r\n\r\n @ViewChild('name') name: ElementRef;\r\n\r\n params: AddTaxEntityModalParams;\r\n result: number;\r\n\r\n taxEntity: TaxRateArea | TaxAuthority;\r\n modalTitle: string;\r\n loading: boolean = false;\r\n\r\n ngOnInit(): void {\r\n if (this.params.entityTypeId == EntityType.TaxAuthority) {\r\n this.modalTitle = 'Add New Tax Authority';\r\n this.taxEntity = new TaxAuthority();\r\n this.taxEntity.defaultAnnualRateIncrease = this.params.defaultAnnualRateIncrease;\r\n } else {\r\n this.modalTitle = 'Add New Tax Rate Area';\r\n this.taxEntity = new TaxRateArea();\r\n this.taxEntity.assessorId = this.params.assessorId;\r\n }\r\n\r\n this.taxEntity.collectorId = this.params.collectorId;\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n setTimeout(() => {\r\n this.name.nativeElement.focus();\r\n });\r\n }\r\n\r\n closeModal(): void {\r\n console.log('closeModal');\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async add(): Promise {\r\n if (this.loading) {\r\n return;\r\n }\r\n\r\n let id: number;\r\n this.loading = true;\r\n\r\n try {\r\n if (this.params.entityTypeId == EntityType.TaxAuthority) {\r\n this.taxEntity = await this._taxRateService.createTaxAuthority(this.taxEntity as TaxAuthorityPayload);\r\n id = this.taxEntity.taxAuthorityId;\r\n } else {\r\n this.taxEntity = await this._taxRateService.createTaxRateArea(this.taxEntity as TaxRateAreaPayload);\r\n id = this.taxEntity.taxRateAreaId;\r\n }\r\n\r\n this.result = id;\r\n this.closeModal();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const TAX_AUTHORITY_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'tax-authority.certain-exemptions-disabled',\r\n tooltipText: 'Select \"Certain Exemptions\" to enable this feature.'\r\n },\r\n {\r\n helpContentId: 'tax-authority.honor-exemptions-on-alternate-av-disabled',\r\n tooltipText: 'Taxable Assessment must be set to \"Lower of Total AV and Alternate AV\" to enable this feature.'\r\n }\r\n];\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment';\r\n\r\n@Component({\r\n selector: 'add-tax-year-modal',\r\n template: `\r\n \r\n
\r\n \r\n
\r\n
\r\n `\r\n})\r\nexport class AddTaxYearModalComponent implements OnInit {\r\n constructor(public bsModalRef: BsModalRef) {}\r\n\r\n yearsAlreadyAdded: number[];\r\n onClose: (yearToAdd: number) => void;\r\n\r\n years: number[];\r\n yearToAdd: number;\r\n\r\n ngOnInit() {\r\n const currentYear: number = Number(moment().format('YYYY'));\r\n const years = _.range(currentYear - 10, currentYear + 5);\r\n\r\n this.years = _.chain(years)\r\n .without(...this.yearsAlreadyAdded)\r\n .reverse()\r\n .value();\r\n\r\n\r\n //console.log('this.yearToAdd', this.yearToAdd);\r\n\r\n if (this.yearsAlreadyAdded && _.max(this.yearsAlreadyAdded))\r\n this.yearToAdd = _.max(this.yearsAlreadyAdded) + 1;\r\n\r\n if (!this.yearToAdd)\r\n this.yearToAdd = currentYear;\r\n }\r\n\r\n add() {\r\n this.onClose(this.yearToAdd);\r\n this.bsModalRef.hide();\r\n\r\n }\r\n\r\n closeModal() {\r\n this.bsModalRef.hide();\r\n }\r\n}\r\n","\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n

Info

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Name:\r\n {{taxAuthority.name}}\r\n \r\n
Code:\r\n {{taxAuthority.code}}\r\n \r\n
PTX ID:\r\n {{taxAuthority.ptxId}}\r\n \r\n
Address:\r\n \r\n \r\n
Category:\r\n {{getCategory(taxAuthority.taxAuthorityCategoryId)}}\r\n \r\n
Taxable Assessment:\r\n {{getTaxableAssessmentLabel(taxAuthority.taxableAssessmentTypeId)}}\r\n \r\n
Exemptions Honored:\r\n
\r\n \r\n
\r\n
 \r\n
\r\n \r\n
\r\n
 \r\n
\r\n \r\n
\r\n
 \r\n
0\" class=\"ps-2\">\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
 \r\n
\r\n \r\n
\r\n
Typical Certification Date:\r\n {{taxAuthority.certificationMonth}}/{{taxAuthority.certificationDay}} {{getCertificationType()}}\r\n
\r\n \r\n /\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n

Rates

\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n {{taxAuthority.defaultAnnualRateIncreaseAsPct}}\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Tax Year *RateMillsYoY % ChangeStatusBills Utilizing
{{yearDetail.taxYear}}\r\n
\r\n {{yearDetail.rateAsPct}}\r\n {{yearDetail.rateAsMills}}\r\n
\r\n \r\n \r\n
\r\n
\r\n {{yearDetail.rateChangeAsPercent}}\r\n N/A\r\n
\r\n \r\n
\r\n {{getStatus(yearDetail.taxAuthorityStatusId)}}\r\n \r\n {{yearDetail.billsUtilizing}}\r\n \r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n

* When calculating bill tax amounts, taxes for years not listed with project using the default annual rate increase.

\r\n
\r\n
\r\n
\r\n
\r\n

Tax Rate Area Inclusion

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Tax Rate Area{{yearDetail.taxYear}}
{{traInclusion.taxRateAreaName}}\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Renderer2 } from '@angular/core';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { TaxRateService } from '../tax.rate.service';\r\nimport { Constants, TaxAuthorityStatuses } from '../../constants.new';\r\nimport { TaxRateAreaTaxAuthorityDetail, TaxAuthorityDetail, TaxRateAreaInclusions } from '../../Assessor-Collector/Tax-Rates/tax.rates.panel.model';\r\nimport { MessageBoxService, MessageBoxButtons, MessageBoxResult } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { TaxAuthorityPayload } from '../tax.rate.model';\r\nimport { AttachmentModalData } from '../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { Address } from '../../Common/Models/common.model';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { BsModalService, BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { TAX_AUTHORITY_HELP } from './taxAuthority.help';\r\nimport { AddTaxYearModalComponent } from './add.tax.year.modal.component';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { Decimal } from 'decimal.js';\r\nimport { TimerService } from '../../UI-Lib/Utilities';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { Subject, takeUntil } from 'rxjs';\r\nimport { AssessmentClassService } from '../../Assessment-Class/assessmentClass.service';\r\n\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment-timezone';\r\n\r\nexport interface Picklist {\r\n label: string;\r\n id: number;\r\n}\r\n\r\nexport interface CheckboxList {\r\n label: string;\r\n value: any;\r\n checked: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'tax-authority',\r\n templateUrl: './tax.authority.component.html'\r\n})\r\nexport class TaxAuthorityComponent implements OnInit {\r\n constructor(public taxRateService: TaxRateService,\r\n public constants: Constants,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _modalService: BsModalService,\r\n private readonly _restrictService: RestrictService,\r\n public bsModalRef: BsModalRef,\r\n private readonly featureFlagsService: FeatureFlagsService,\r\n private readonly assessmentClassService: AssessmentClassService,\r\n public readonly busyIndicatorService: BusyIndicatorService,\r\n private readonly _renderer: Renderer2,\r\n private readonly _timer: TimerService,\r\n private readonly _helpService: HelpService) {\r\n this.canEdit = _restrictService.isInRole(Roles.TAXRATESETUP);\r\n }\r\n _busyRef: BusyIndicatorRef;\r\n _destroy$: Subject = new Subject();\r\n busyRefId: string = this.busyIndicatorService.generateUniqueMessageIdentifier();\r\n enableTrueRateBasedSystem: boolean;\r\n availableExemptionComponents: Weissman.Model.Assessments.AssessmentComponent[];\r\n allowedExemptions: CheckboxList[];\r\n\r\n canEdit: boolean = false;\r\n currentYear: number = Number(moment().format('YYYY'));\r\n categories: Picklist[];\r\n taxableAssessments: Picklist[];\r\n statuses: Picklist[];\r\n certificationTypes: Picklist[];\r\n certificationMonths: number[];\r\n certificationDays: number[];\r\n displayAs: 'rate' | 'mills' = 'rate';\r\n taxAuthority: TaxAuthorityPayload;\r\n originalTaxAuthority: TaxAuthorityPayload;\r\n saving: boolean = false;\r\n tempVals: any = {};\r\n taxRateAreaInclusions: TaxRateAreaInclusions[] = [];\r\n editMode: boolean = false;\r\n\r\n launchInEditMode: boolean;\r\n taxAuthorityId: number;\r\n onClose: any;\r\n\r\n exemptions = {\r\n allExemptions: Core.TaxAuthorityExemptionTypeEnum.AllExemptions,\r\n certainExemptions: Core.TaxAuthorityExemptionTypeEnum.CertainExemptions,\r\n noExemptions: Core.TaxAuthorityExemptionTypeEnum.NoExemptions\r\n }\r\n\r\n taxableAssessmentTypes = {\r\n totalAV: Core.TaxableAssessmentTypeEnum.TotalAV,\r\n alternateAV: Core.TaxableAssessmentTypeEnum.AlternateAV,\r\n landOnly: Core.TaxableAssessmentTypeEnum.LandOnly,\r\n lowerOfTotalAvAndAlternateAv: Core.TaxableAssessmentTypeEnum.LowerOfTotalAvAndAlternateAv\r\n }\r\n\r\n async ngOnInit() {\r\n this._helpService.setContent(TAX_AUTHORITY_HELP);\r\n\r\n this._initPickLists();\r\n this.enableTrueRateBasedSystem = this.featureFlagsService.featureFlags.enableTrueRateBasedSystem;\r\n\r\n const taxAuthority = await this.taxRateService.getTaxAuthority(this.taxAuthorityId);\r\n this.taxAuthority = this._prepareData(taxAuthority);\r\n //this.taxAuthority = taxAuthority;\r\n\r\n this.availableExemptionComponents = await this.assessmentClassService.getExemptionChoicesForTaxAuthority(this.taxAuthority.taxAuthorityId);\r\n\r\n this.allowedExemptions = _.map(this.availableExemptionComponents, (exemption: Weissman.Model.Assessments.AssessmentComponent) => {\r\n return {\r\n value: exemption.assessmentComponentID,\r\n label: exemption.componentName,\r\n checked: (this.taxAuthority.allowedExemptionAssessmentComponentIds.indexOf(exemption.assessmentComponentID) >= 0)\r\n };\r\n });\r\n\r\n const uniqTRAs = this.getCompiledListOfTaxRateAreaTaxAuthorityDetails(this.taxAuthority.taxRateAreaTaxAuthorityDetails);\r\n this.taxRateAreaInclusions = _.map(uniqTRAs, (tratad: TaxRateAreaTaxAuthorityDetail) : TaxRateAreaInclusions => {\r\n return {\r\n taxRateAreaName: tratad.taxRateAreaName,\r\n yearsIncluded: _.map(this.taxAuthority.details, (tad: TaxAuthorityDetail) => {\r\n return this.shouldDisplayCheck(tratad, tad.taxYear);\r\n })\r\n };\r\n });\r\n\r\n if (this.launchInEditMode) {\r\n this.goToEditMode();\r\n }\r\n //console.log(this.taxAuthority)\r\n }\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.taxAuthority) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: 'TaxAuthority',\r\n entityName: this.taxAuthority.name,\r\n entityData: {\r\n typeId: Core.EntityTypes.TaxAuthority,\r\n id: this.taxAuthority.taxAuthorityId,\r\n name: this.taxAuthority.name\r\n },\r\n readOnly: !this.canEdit\r\n } as AttachmentModalData;\r\n }\r\n get commentsModel(): CommentModalData {\r\n if (!this.taxAuthority) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityID: this.taxAuthority.taxAuthorityId,\r\n entityTypeID: Core.EntityTypes.TaxAuthority,\r\n description: this.taxAuthority.name,\r\n canEdit: this.canEdit\r\n } as CommentModalData;\r\n }\r\n\r\n goToEditMode(): void {\r\n this.originalTaxAuthority = _.cloneDeep(this.taxAuthority);\r\n this.editMode = true;\r\n }\r\n\r\n cancel(): void {\r\n this.taxAuthority = this.originalTaxAuthority;\r\n this.editMode = false;\r\n }\r\n\r\n getCategory(taxAuthorityCategoryId: number): string {\r\n return taxAuthorityCategoryId ? this.constants.TaxAuthorityCategories[taxAuthorityCategoryId].displayName : '';\r\n }\r\n\r\n getTaxableAssessmentLabel(taxableAssessmentId: number): string {\r\n if(!taxableAssessmentId) {\r\n return;\r\n }\r\n return _.find(this.taxableAssessments, {id: taxableAssessmentId}).label;\r\n }\r\n\r\n getStatus(taxAuthorityStatusId: number): string {\r\n if(!taxAuthorityStatusId) {\r\n return;\r\n }\r\n\r\n return _.find(this.statuses, {id: taxAuthorityStatusId}).label;\r\n }\r\n\r\n getCertificationType(): string {\r\n return _.find(this.certificationTypes, {id: this.taxAuthority.certificationType}).label;\r\n }\r\n\r\n getYearEstimated(yearDetail: TaxAuthorityDetail): boolean {\r\n return yearDetail.taxAuthorityStatusId != TaxAuthorityStatuses.Actual;\r\n }\r\n\r\n getShadingFromStatus(yearDetail: TaxAuthorityDetail): string {\r\n switch(yearDetail.taxAuthorityStatusId) {\r\n case TaxAuthorityStatuses.Estimated:\r\n return 'not-actual-tax-year';\r\n case TaxAuthorityStatuses.Pending:\r\n return 'pending-tax-year';\r\n default:\r\n return '';\r\n }\r\n }\r\n\r\n shouldDisplayCheck(tratd: TaxRateAreaTaxAuthorityDetail, year: number): boolean {\r\n // get all records with this taxRateAreaId\r\n // if any of those records would include this year - return true\r\n\r\n const allTratad = _.filter(this.taxAuthority.taxRateAreaTaxAuthorityDetails, {taxRateAreaId: tratd.taxRateAreaId});\r\n\r\n return _.some(allTratad, (tratad: TaxRateAreaTaxAuthorityDetail) => {\r\n return (!tratad.yearBegin || tratad.yearBegin <= year)\r\n && (!tratad.yearEnd || tratad.yearEnd >= year);\r\n });\r\n }\r\n\r\n getCompiledListOfTaxRateAreaTaxAuthorityDetails(tartadList: TaxRateAreaTaxAuthorityDetail[]): TaxRateAreaTaxAuthorityDetail[] {\r\n return _.uniqBy(tartadList, 'taxRateAreaId');\r\n }\r\n\r\n removeYearDetail(yearDetail: TaxAuthorityDetail): void {\r\n if(yearDetail.efAction == 'add') {\r\n _.remove(this.taxAuthority.details, yearDetail);\r\n } else {\r\n yearDetail.efAction = 'delete';\r\n }\r\n }\r\n\r\n disableTaxAuthority(): void {\r\n\r\n // In order to disable the max year must have an entry of 0.\r\n // When user checks disabled, automatically add this year if not already present.\r\n\r\n this.taxAuthority.disabled = true;\r\n const maxYearDetail = _.maxBy(this.taxAuthority.details, 'taxYear');\r\n\r\n if(!maxYearDetail || maxYearDetail.rate != 0) {\r\n const taxAuthorityDetail = new TaxAuthorityDetail(this.taxAuthority.taxAuthorityId);\r\n\r\n taxAuthorityDetail.rate = 0;\r\n taxAuthorityDetail.rateAsMills = new Decimal(0).toFixed(6);\r\n this.syncRateFromMillsToPct(taxAuthorityDetail);\r\n\r\n // was there prev. year?\r\n if (this.taxAuthority.details.length > 0)\r\n taxAuthorityDetail.rateChangeAsPercent = new Decimal(-100).toFixed(2);\r\n else\r\n taxAuthorityDetail.rateChangeAsPercent = new Decimal(0).toFixed(2);\r\n\r\n this.syncRateChange(taxAuthorityDetail);\r\n\r\n taxAuthorityDetail.taxYear = maxYearDetail ? maxYearDetail.taxYear + 1 : this.currentYear;\r\n taxAuthorityDetail.taxAuthorityStatusId = TaxAuthorityStatuses.Estimated;\r\n\r\n this.taxAuthority.details.push(taxAuthorityDetail);\r\n this.taxAuthority.details = _.orderBy(this.taxAuthority.details, 'taxYear', 'desc');\r\n\r\n this._toastr.info(`Year ${taxAuthorityDetail.taxYear} added`);\r\n }\r\n }\r\n\r\n launchAddTaxYearModal(): void {\r\n const initialState = {\r\n yearsAlreadyAdded: _.chain(this.taxAuthority.details)\r\n .reject({efAction: 'delete'})\r\n .map('taxYear')\r\n .value()\r\n };\r\n\r\n const modalRef = this._modalService.show(AddTaxYearModalComponent, {initialState});\r\n\r\n modalRef.content.onClose = (year: number) => {\r\n\r\n //console.log('adding year', year);\r\n\r\n // do we have deleted entry for this given year?\r\n const deletedYear = _.find(this.taxAuthority.details, {taxYear: year});\r\n if(deletedYear) {\r\n deletedYear.efAction = null;\r\n\r\n this._calculateRate(deletedYear);\r\n } else {\r\n // create new entry for this given yeat\r\n const taxAuthorityDetail = new TaxAuthorityDetail(this.taxAuthority.taxAuthorityId);\r\n taxAuthorityDetail.taxYear = year;\r\n taxAuthorityDetail.taxAuthorityStatusId = TaxAuthorityStatuses.Estimated;\r\n this._calculateRate(taxAuthorityDetail);\r\n\r\n this.taxAuthority.details.push(taxAuthorityDetail);\r\n }\r\n\r\n this.taxAuthority.details = _.orderBy(this.taxAuthority.details, 'taxYear', 'desc');\r\n const detailIdx = _.findIndex(this.taxAuthority.details, {taxYear: year});\r\n\r\n this._timer.setTimeout(() => {\r\n const rateClass = this.displayAs == 'rate' ? '.rate' : '.mills';\r\n const element = this._renderer.selectRootElement(rateClass + detailIdx);\r\n element.focus();\r\n });\r\n };\r\n }\r\n\r\n captureVal(entity: any, field: string): void {\r\n\t\tthis.tempVals[field] = entity[field];\r\n\t}\r\n\r\n syncDefaultAnnualRateIncrease(): void {\r\n if(!this._isValidNumber(this.taxAuthority.defaultAnnualRateIncreaseAsPct)) {\r\n return;\r\n }\r\n\r\n this.taxAuthority.defaultAnnualRateIncrease = new Decimal(this.taxAuthority.defaultAnnualRateIncreaseAsPct).dividedBy(100).toNumber();\r\n }\r\n\r\n syncRateFromPctToMills(yearDetail: TaxAuthorityDetail): void {\r\n if(!this._isValidNumber(yearDetail.rateAsPct)) {\r\n yearDetail.rateAsMills = null;\r\n return;\r\n }\r\n\r\n yearDetail.rateAsMills = new Decimal(yearDetail.rateAsPct).times(10).toFixed(6);\r\n }\r\n\r\n syncRateFromMillsToPct(yearDetail: TaxAuthorityDetail): void {\r\n if(!this._isValidNumber(yearDetail.rateAsMills)) {\r\n yearDetail.rateAsPct = null;\r\n return;\r\n }\r\n\r\n yearDetail.rateAsPct = new Decimal(yearDetail.rateAsMills).dividedBy(10).toFixed(6);\r\n }\r\n\r\n syncRateChange(yearDetail: TaxAuthorityDetail): void {\r\n if(!this._isValidNumber(yearDetail.rateChangeAsPercent)) {\r\n yearDetail.rateChange = null;\r\n return;\r\n }\r\n\r\n yearDetail.rateChange = new Decimal(yearDetail.rateChangeAsPercent).dividedBy(100).toNumber();\r\n }\r\n\r\n defaultAnnualRateIncreaseAsPctBlur(): void {\r\n if(!this.taxAuthority.defaultAnnualRateIncreaseAsPct) {\r\n return;\r\n }\r\n\r\n this.taxAuthority.defaultAnnualRateIncreaseAsPct = new Decimal(this.taxAuthority.defaultAnnualRateIncreaseAsPct).toFixed(2);\r\n }\r\n\r\n rateAsMillsBlur(currentYearDetail: TaxAuthorityDetail): void {\r\n //console.log('rateAsMillsBlur', currentYearDetail);\r\n\r\n if(currentYearDetail.rateAsMills == this.tempVals.rateAsMills) {\r\n return;\r\n }\r\n\r\n if (!this._isValidNumber(currentYearDetail.rateAsMills)){\r\n currentYearDetail.rateAsMills = null;\r\n currentYearDetail.rateAsPct = null;\r\n currentYearDetail.rateChangeAsPercent = null;\r\n return;\r\n }\r\n\r\n // store\r\n currentYearDetail.rate = this._isInvalidNumber(currentYearDetail.rateAsMills) ? null : new Decimal(currentYearDetail.rateAsMills).dividedBy(1000).toNumber();\r\n // format\r\n currentYearDetail.rateAsMills = this._isInvalidNumber(currentYearDetail.rateAsMills) ? new Decimal(0).toFixed(6) : new Decimal(currentYearDetail.rateAsMills).toFixed(6);\r\n // sync\r\n currentYearDetail.rateAsPct = new Decimal(currentYearDetail.rate).times(100).toFixed(6);\r\n\r\n this._updateCurrentYearRateChange(currentYearDetail);\r\n }\r\n\r\n rateAsPctBlur(currentYearDetail: TaxAuthorityDetail): void {\r\n //console.log('rateAsPctBlur', currentYearDetail);\r\n\r\n if(currentYearDetail.rateAsPct == this.tempVals.rateAsPct) {\r\n return;\r\n }\r\n\r\n if (!this._isValidNumber(currentYearDetail.rateAsPct)){\r\n currentYearDetail.rateAsPct = null;\r\n currentYearDetail.rateAsMills = null;\r\n currentYearDetail.rateChangeAsPercent = null;\r\n return;\r\n }\r\n\r\n // store\r\n currentYearDetail.rate = this._isInvalidNumber(currentYearDetail.rateAsPct) ? null : new Decimal(currentYearDetail.rateAsPct).dividedBy(100).toNumber();\r\n // format\r\n currentYearDetail.rateAsPct = this._isInvalidNumber(currentYearDetail.rateAsPct) ? new Decimal(0).toFixed(6) : new Decimal(currentYearDetail.rateAsPct).toFixed(6);\r\n // sync\r\n currentYearDetail.rateAsMills = new Decimal(currentYearDetail.rate).times(1000).toFixed(6);\r\n\r\n this._updateCurrentYearRateChange(currentYearDetail);\r\n }\r\n\r\n rateChangeAsPercentBlur(currentYearDetail: TaxAuthorityDetail): void {\r\n //console.log('rateChangeAsPercentBlur', currentYearDetail);\r\n\r\n if(!this._isValidNumber(currentYearDetail.rateChangeAsPercent)) {\r\n currentYearDetail.rateChangeAsPercent = null;\r\n return;\r\n }\r\n\r\n if(currentYearDetail.rateChangeAsPercent == this.tempVals.rateChangeAsPercent) {\r\n return;\r\n }\r\n\r\n currentYearDetail.rateChangeAsPercent = new Decimal(currentYearDetail.rateChangeAsPercent).toFixed(2);\r\n\r\n this._updateCurrentYearRate(currentYearDetail);\r\n }\r\n\r\n async save() {\r\n if (_.some(this.taxAuthority.details, ['rate', null]) || _.some(this.taxAuthority.details, ['rateAsPct', null]) || _.some(this.taxAuthority.details, ['rateAsMills', null])) {\r\n this._toastr.error('Rate is required for each tax year');\r\n return;\r\n }\r\n\r\n if(this.taxAuthority.disabled && Number(this.taxAuthority.details[0].rate) !== 0) {\r\n this._toastr.error('Max Year must have rate of 0%');\r\n return;\r\n }\r\n\r\n if(_.some(this.taxAuthority.details, x => x.rate > 9999)) {\r\n this._toastr.error('Tax rate cannot exceed 999,999.');\r\n return;\r\n }\r\n\r\n if(!_.isEqual(_.omit(this.taxAuthority, 'details'), _.omit(this.originalTaxAuthority, 'details'))) {\r\n this.taxAuthority.efAction = 'update';\r\n }\r\n\r\n this.taxAuthority.details = _.map(this.taxAuthority.details, yearDetail => {\r\n yearDetail.rate = new Decimal(yearDetail.rateAsPct).dividedBy(100).toNumber();\r\n\r\n if(!yearDetail.efAction) {\r\n const originalYearDetail = _.find(this.originalTaxAuthority.details, {taxAuthorityDetailId: yearDetail.taxAuthorityDetailId});\r\n\r\n if(originalYearDetail && !_.isEqual(yearDetail, originalYearDetail)) {\r\n yearDetail.efAction = 'update';\r\n }\r\n }\r\n\r\n return yearDetail;\r\n });\r\n\r\n this.taxAuthority.allowedExemptionAssessmentComponentIds = [];\r\n\r\n if (this.taxAuthority.taxAuthorityExemptionTypeId === Core.TaxAuthorityExemptionTypeEnum.CertainExemptions) {\r\n _.forEach(this.allowedExemptions,\r\n exemption => {\r\n if (exemption.checked) {\r\n this.taxAuthority.allowedExemptionAssessmentComponentIds.push(Number(exemption.value));\r\n }\r\n });\r\n }\r\n\r\n if (this.taxAuthority.taxableAssessmentTypeId !== Core.TaxableAssessmentTypeEnum.LowerOfTotalAvAndAlternateAv) {\r\n this.taxAuthority.allowExemptionsOnAlternateAV = false;\r\n }\r\n\r\n this.saving = true;\r\n\r\n try {\r\n const savedAuthority = await this._saveOrUpdateTaxAuthority(this.taxAuthority);\r\n this.taxAuthority = this._prepareData(savedAuthority);\r\n this.editMode = false;\r\n this.onClose(savedAuthority);\r\n this.bsModalRef.hide();\r\n } finally {\r\n this.saving = false;\r\n }\r\n }\r\n\r\n async delete(): Promise {\r\n const result: number = await this._messageBoxService.open({\r\n message: `Are you sure you want to delete ${this.taxAuthority.name}?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (result === MessageBoxResult.OK) {\r\n if (this.featureFlagsService.featureFlags.enableTaxRateAreaTaxAuthorityBackgroundProcess){\r\n this._showBusyIndicator('Tax Authority', 'Deleting Tax Authority', null, false, true);\r\n try\r\n {\r\n const longRunningProcessId = await this.taxRateService.deleteTaxAuthority(this.taxAuthority.taxAuthorityId);\r\n await this._busyRef.setLongRunningProcessId(longRunningProcessId);\r\n }\r\n catch(e)\r\n {\r\n await this._hideBusyIndicator();\r\n return Promise.reject(e);\r\n }\r\n this.bsModalRef.hide();\r\n return Promise.resolve();\r\n\r\n }\r\n else {\r\n await this.taxRateService.deleteTaxAuthority(this.taxAuthority.taxAuthorityId);\r\n\r\n this.onClose();\r\n this.bsModalRef.hide();\r\n }\r\n }\r\n }\r\n\r\n getQcInfo(yearDetail: TaxAuthorityDetail): string {\r\n let result: string = null;\r\n if (yearDetail.taxAuthorityStatusId === TaxAuthorityStatuses.Pending) {\r\n if (yearDetail.qcRequestTimeUtc) {\r\n result = `QC requested at ${ moment(yearDetail.qcRequestTimeUtc).utc().format('M/D/Y')}`;\r\n if (yearDetail.qcRequestUserFullName) {\r\n result += ` by ${ yearDetail.qcRequestUserFullName}`;\r\n }\r\n }\r\n }\r\n\r\n return result;\r\n }\r\n\r\n async closeModal() {\r\n if(this.editMode && this._changesWereMade()) {\r\n const result: number = await this._messageBoxService.open({\r\n message: 'Are you sure you want to cancel and discard all changes?',\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (result === MessageBoxResult.OK) {\r\n this.onClose();\r\n this.bsModalRef.hide();\r\n }\r\n } else {\r\n this.onClose();\r\n this.bsModalRef.hide();\r\n }\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', lrpId: number, canDismiss = true, hasProgressBar = true): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this.busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: lrpId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: hasProgressBar,\r\n canDismiss\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success) => {\r\n await this._hideBusyIndicator();\r\n if (success) {\r\n this._refreshAndNotifyParent();\r\n }\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._destroy$.next();\r\n }\r\n\r\n private _refreshAndNotifyParent() {\r\n this.onClose();\r\n //this.gridDataChanged.emit();\r\n }\r\n\r\n private _initPickLists() {\r\n this.certificationTypes = this.constants.CertificationTypes;\r\n\r\n this.certificationMonths = _.range(1, 13);\r\n this.certificationDays = _.range(1, 32);\r\n\r\n this.categories = _.map(this.constants.TaxAuthorityCategories, (names: any, id: number) => {\r\n return {\r\n id: Number(id),\r\n label: names.displayName\r\n };\r\n });\r\n\r\n if (this.featureFlagsService.featureFlags.enableTrueRateBasedSystem)\r\n {\r\n this.taxableAssessments = _.map(this.constants.TaxableAssessmentTypesForTrueRate, (names: any, id: number) => {\r\n return {\r\n id: Number(id),\r\n label: `${names.displayName} ${names.extraDisplay}`\r\n };\r\n });\r\n }\r\n else\r\n {\r\n this.taxableAssessments = _.map(this.constants.TaxableAssessmentTypes, (names: any, id: number) => {\r\n return {\r\n id: Number(id),\r\n label: `${names.displayName} ${names.extraDisplay}`\r\n };\r\n });\r\n }\r\n\r\n this.statuses = this.constants.TaxAuthorityStatuses;\r\n }\r\n\r\n private _prepareData(taxAuthority: TaxAuthorityPayload): TaxAuthorityPayload {\r\n if(!taxAuthority) {\r\n return;\r\n }\r\n taxAuthority.address = taxAuthority.address || new Address();\r\n taxAuthority.defaultAnnualRateIncreaseAsPct = taxAuthority.defaultAnnualRateIncrease ? new Decimal(taxAuthority.defaultAnnualRateIncrease).times(100).toFixed(2) : undefined;\r\n if (!taxAuthority.defaultAnnualRateIncreaseAsPct)\r\n taxAuthority.defaultAnnualRateIncreaseAsPct = new Decimal(0).times(100).toFixed(2);\r\n\r\n taxAuthority.details = _.chain(taxAuthority.details)\r\n .map(yearDetail => {\r\n //yearDetail.rate = yearDetail.rate ? new Decimal(yearDetail.rate).toFixed(8) : yearDetail.rate;\r\n if (yearDetail.rate != null){\r\n yearDetail.rateAsPct = new Decimal(yearDetail.rate).times(100).toFixed(6);\r\n }\r\n else{\r\n yearDetail.rateAsPct = new Decimal(0).times(100).toFixed(6);\r\n }\r\n\r\n // we have pct -> sync pct to mills\r\n this.syncRateFromPctToMills(yearDetail);\r\n\r\n yearDetail.rateChangeAsPercent = yearDetail.rateChange ? new Decimal(yearDetail.rateChange).times(100).toFixed(2) : undefined;\r\n\r\n if (yearDetail.rateChange == 0)\r\n yearDetail.rateChangeAsPercent = new Decimal(0).toFixed(2);\r\n return yearDetail;\r\n })\r\n .orderBy('taxYear', 'desc')\r\n .value();\r\n\r\n return taxAuthority;\r\n }\r\n\r\n private _calculateRate(yearDetail: TaxAuthorityDetail): void {\r\n yearDetail.rateChangeAsPercent = this.taxAuthority.defaultAnnualRateIncreaseAsPct || new Decimal(0).toFixed(2);\r\n this.syncRateChange(yearDetail);\r\n\r\n this._updateCurrentYearRate(yearDetail);\r\n }\r\n\r\n private _isValidNumber(value: string | number): boolean {\r\n if (this._isInvalidNumber(value))\r\n return false;\r\n\r\n if (isNaN(Number(value)))\r\n return false;\r\n\r\n return true;\r\n }\r\n\r\n\r\n private _isInvalidNumber(value: string | number): boolean {\r\n return value === null || value === undefined || value === '' || value === '.';\r\n }\r\n\r\n private _updateCurrentYearRateChange(currentYearDetail: TaxAuthorityDetail): void {\r\n\r\n //console.log('_updateCurrentYearRateChange', currentYearDetail);\r\n const previousYearDetail = this._findPreviousYearDetail(currentYearDetail);\r\n if(previousYearDetail) {\r\n if (Number(previousYearDetail.rate) > 0)\r\n currentYearDetail.rateChangeAsPercent = new Decimal(currentYearDetail.rate).minus(previousYearDetail.rate).dividedBy(previousYearDetail.rate).times(100).toFixed(2);\r\n\r\n if (Number(currentYearDetail.rate) == 0 && Number(previousYearDetail.rate) == 0)\r\n currentYearDetail.rateChangeAsPercent = new Decimal(0).toFixed(2);\r\n\r\n if (Number(previousYearDetail.rate) == 0 && Number(currentYearDetail.rate) > 0)\r\n currentYearDetail.rateChangeAsPercent = null;\r\n\r\n this.syncRateChange(currentYearDetail);\r\n }\r\n\r\n this._updateNextYearRateChange(currentYearDetail);\r\n }\r\n\r\n private _updateCurrentYearRate(currentYearDetail: TaxAuthorityDetail): void {\r\n const previousYearDetail = this._findPreviousYearDetail(currentYearDetail);\r\n\r\n if(previousYearDetail) {\r\n if (previousYearDetail.rate != null){\r\n currentYearDetail.rate = this._computeRateFromPrevious(previousYearDetail, currentYearDetail);\r\n currentYearDetail.rateAsMills = new Decimal(currentYearDetail.rate).times(1000).toFixed(6);\r\n\r\n this.syncRateFromMillsToPct(currentYearDetail);\r\n\r\n this._updateNextYearRateChange(currentYearDetail);\r\n }\r\n return;\r\n }\r\n // there was no prev. year, do we have next year instead?\r\n // If so, we project the next year's Rate flat to current.\r\n //\r\n\r\n const nextYearDetail = this._findNextYearDetail(currentYearDetail);\r\n\r\n if(nextYearDetail) {\r\n if (nextYearDetail.rate != null){\r\n currentYearDetail.rate = nextYearDetail.rate;\r\n currentYearDetail.rateAsMills = new Decimal(currentYearDetail.rate).times(1000).toFixed(6);\r\n\r\n this.syncRateFromMillsToPct(currentYearDetail);\r\n\r\n currentYearDetail.rateChangeAsPercent = null;\r\n this.syncRateChange(currentYearDetail);\r\n\r\n this._updateNextYearRateChange(currentYearDetail);\r\n }\r\n\r\n }\r\n }\r\n\r\n private _computeRateFromPrevious(previousYearDetail: TaxAuthorityDetail, currentYearDetail: TaxAuthorityDetail) : number {\r\n if ( previousYearDetail.rate == null )\r\n {\r\n return new Decimal(0).toNumber();\r\n }\r\n\r\n // Compute the Rate compounded over gap years between Previous and Current\r\n // using Default Annual Rate Increase.\r\n let prevRate: Decimal = new Decimal(previousYearDetail.rate);\r\n for (let yr = previousYearDetail.taxYear + 1; yr < currentYearDetail.taxYear; yr++)\r\n {\r\n prevRate = prevRate.times(new Decimal(1).plus(this.taxAuthority.defaultAnnualRateIncrease));\r\n }\r\n\r\n // Compute final Rate for Current with Current's rate change\r\n return new Decimal(currentYearDetail.rateChange).plus(1).times(prevRate).toNumber();\r\n }\r\n\r\n private _updateNextYearRateChange(currentYearDetail: TaxAuthorityDetail): void {\r\n const nextYearDetail = this._findNextYearDetail(currentYearDetail);\r\n\r\n if (!nextYearDetail)\r\n return;\r\n\r\n if (Number(currentYearDetail.rate) == 0 && Number(nextYearDetail.rate) > 0){\r\n nextYearDetail.rateChangeAsPercent = null;\r\n return;\r\n }\r\n\r\n if (Number(currentYearDetail.rate) == 0 && Number(nextYearDetail.rate) == 0)\r\n nextYearDetail.rateChangeAsPercent = new Decimal(0).toFixed(2);\r\n\r\n if(Number(currentYearDetail.rate) > 0)\r\n nextYearDetail.rateChangeAsPercent = new Decimal(nextYearDetail.rate).minus(currentYearDetail.rate).dividedBy(currentYearDetail.rate).times(100).toFixed(2);\r\n\r\n this.syncRateChange(nextYearDetail);\r\n }\r\n\r\n private _findPreviousYearDetail(currentYearDetail: TaxAuthorityDetail): TaxAuthorityDetail {\r\n return _.find(this.taxAuthority.details, function(d) {\r\n return d.taxYear < currentYearDetail.taxYear;\r\n });\r\n }\r\n\r\n private _findNextYearDetail(currentYearDetail: TaxAuthorityDetail): TaxAuthorityDetail {\r\n return _.findLast(this.taxAuthority.details, function(d) {\r\n return d.taxYear > currentYearDetail.taxYear;\r\n });\r\n }\r\n\r\n private _saveOrUpdateTaxAuthority(taxAuthority: TaxAuthorityPayload): Promise {\r\n if(taxAuthority.taxAuthorityId) {\r\n return this.taxRateService.updateTaxAuthority(this.taxAuthority);\r\n } else {\r\n return this.taxRateService.createTaxAuthority(this.taxAuthority);\r\n }\r\n }\r\n\r\n private _changesWereMade(): boolean {\r\n if(!_.isEqual(_.omit(this.taxAuthority, 'details'), _.omit(this.originalTaxAuthority, 'details'))) {\r\n return true;\r\n }\r\n\r\n const isChangedDetail = _.some(this.taxAuthority.details, yearDetail => {\r\n if(!yearDetail.efAction) {\r\n const originalYearDetail = _.find(this.originalTaxAuthority.details, {taxAuthorityDetailId: yearDetail.taxAuthorityDetailId});\r\n\r\n return originalYearDetail && !_.isEqual(yearDetail, originalYearDetail);\r\n }\r\n\r\n return true;\r\n\r\n });\r\n\r\n return isChangedDetail;\r\n }\r\n\r\n}\r\n","import { Component, Input, Output, EventEmitter, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { WsSelectValueFormatter } from '../UI-Lib/Select/select.interface';\r\n\r\n@Component({\r\n selector: 'show-tax-year',\r\n template: `\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
plus
\r\n
\r\n \r\n \r\n
\r\n
\r\n `\r\n})\r\nexport class ShowTaxYearComponent implements OnInit {\r\n @Input() taxYearBegin: number = new Date().getFullYear();\r\n @Input() taxYearsPrior: number = 2;\r\n @Output() taxYearBeginChange: EventEmitter = new EventEmitter();\r\n @Output() taxYearsPriorChange: EventEmitter = new EventEmitter();\r\n @Output() showTaxYearChanged: EventEmitter = new EventEmitter();\r\n\r\n taxYearOptions: number[];\r\n priorOptions: Compliance.NameValuePair[];\r\n priorFormatter: WsSelectValueFormatter = (value) => `${value} Prior`;\r\n\r\n ngOnInit() {\r\n const currentYear = new Date().getFullYear();\r\n this.taxYearOptions = _.range(currentYear + 5, currentYear - 11);\r\n this.priorOptions = [1, 2, 3, 4].map(n => ({ name: `${n} Prior`, value: n }));\r\n }\r\n\r\n onTaxYearBeginChange() {\r\n this.taxYearBeginChange.emit(this.taxYearBegin);\r\n this.showTaxYearChanged.emit();\r\n\r\n }\r\n\r\n onTaxYearsPriorChange() {\r\n this.taxYearsPriorChange.emit(this.taxYearsPrior);\r\n this.showTaxYearChanged.emit();\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n
\r\n

Tax Rate Area

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n

Info

\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Name:\r\n {{ taxRateArea.name }}\r\n \r\n
Code:\r\n {{ taxRateArea.code }}\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
Address:\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n

Tax Authorities

\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
CodeTax Authority NameCategoryTax Year BeginTax Year End{{ year }}\r\n
{{ taxAuthority.code }}{{ taxAuthority.name }}{{ getCategory(taxAuthority.taxAuthorityCategoryId) }}\r\n {{ detail.yearBegin || 'Infinite' }}\r\n \r\n \r\n {{ detail.yearEnd || 'Infinite' }}\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n {{ getYearRate(taxAuthority, detail, year) }}\r\n
\r\n {{ getTotalRateForDisplay(collector.taxAuthorities, year) }}\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n

No Collectors Added

\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n","import {Component, OnInit} from '@angular/core';\r\nimport { TaxRateService } from '../tax.rate.service';\r\nimport { Constants, TaxAuthorityStatuses } from '../../constants.new';\r\nimport { TaxAuthoritiesOrderBy, TaxRateAreaPayload, TaxRateAreaCollector, PanelProjectionsPayload } from '../tax.rate.model';\r\nimport { Address } from '../../Common/Models/common.model';\r\nimport { TaxAuthority, TaxAuthorityDetail, TaxRateAreaTaxAuthorityDetail } from '../../Assessor-Collector/Tax-Rates/tax.rates.panel.model';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AttachmentModalData } from '../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { MessageBoxService, MessageBoxButtons, MessageBoxResult } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { TimerService } from '../../UI-Lib/Utilities';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { Subject, takeUntil } from 'rxjs';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment';\r\n\r\n@Component({\r\n selector: 'tax-rate-area',\r\n templateUrl: './tax.rate.area.component.html',\r\n styleUrls: ['./tax.rate.area.component.scss']\r\n})\r\nexport class TaxRateAreaComponent implements OnInit {\r\n constructor(private readonly _taxRateService: TaxRateService,\r\n private readonly _constants: Constants,\r\n private readonly _toastr: ToastrService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n public readonly busyIndicatorService: BusyIndicatorService,\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n public bsModalRef: BsModalRef,\r\n private readonly _timer: TimerService) {\r\n this.canEdit = _restrictService.isInRole(Roles.TAXRATESETUP);\r\n }\r\n\r\n canEdit: boolean = true;\r\n hideAddCollectorButton = false;\r\n\r\n showTaxYearOptions: number[];\r\n taxYearBeginEndOptions: number[];\r\n priorOptions: number[];\r\n orderBy: TaxAuthoritiesOrderBy = 'alpha';\r\n groupByCategory: boolean = false;\r\n taxYearBegin: number;\r\n taxYearsPrior: number;\r\n globalYearEnd: number;\r\n\r\n years: number[];\r\n\r\n taxRateArea: TaxRateAreaPayload;\r\n originalTaxRateArea: TaxRateAreaPayload;\r\n clonedTaxRateArea: TaxRateAreaPayload;\r\n\r\n saving: boolean = false;\r\n loadingProjections: boolean = false;\r\n cloning: boolean = false;\r\n\r\n // Data from Tax Rates Panel\r\n editMode: boolean;\r\n taxRateAreaId: number;\r\n onClose: any;\r\n busyRefId: string = this.busyIndicatorService.generateUniqueMessageIdentifier();\r\n\r\n private _busyRef: BusyIndicatorRef;\r\n private _destroy$: Subject = new Subject();\r\n\r\n async ngOnInit() {\r\n const currentYear = Number(moment().format('YYYY'));\r\n this.showTaxYearOptions = _.range(currentYear + 5, currentYear - 10);\r\n this.taxYearBeginEndOptions = _.range(currentYear + 5, currentYear - 10);\r\n this.priorOptions = [1, 2, 3, 4];\r\n this.taxYearBegin = currentYear;\r\n this.taxYearsPrior = 2;\r\n this.showTaxYearChanged();\r\n\r\n const taxRateArea = await this._taxRateService.getTaxRateArea(this.taxRateAreaId);\r\n this._initTaxRateArea(taxRateArea);\r\n }\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.taxRateArea) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: 'TaxRateArea',\r\n entityName: this.taxRateArea.name,\r\n entityData: {\r\n typeId: Core.EntityTypes.TaxRateArea,\r\n id: this.taxRateArea.taxRateAreaId,\r\n name: this.taxRateArea.name\r\n },\r\n readOnly: !this.canEdit\r\n } as AttachmentModalData;\r\n }\r\n get commentsModel(): CommentModalData {\r\n if (!this.taxRateArea) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityID: this.taxRateArea.taxRateAreaId,\r\n entityTypeID: Core.EntityTypes.TaxRateArea,\r\n description: this.taxRateArea.name,\r\n canEdit: this.canEdit\r\n } as CommentModalData;\r\n }\r\n\r\n goToEditMode() {\r\n this.originalTaxRateArea = _.cloneDeep(this.taxRateArea);\r\n this.editMode = true;\r\n }\r\n\r\n cancel() {\r\n if (this.originalTaxRateArea) {\r\n this.taxRateArea = _.cloneDeep(this.originalTaxRateArea);\r\n }\r\n this.editMode = false;\r\n }\r\n\r\n getCategory(taxAuthorityCategoryId: number): string {\r\n return taxAuthorityCategoryId ? this._constants.TaxAuthorityCategories[taxAuthorityCategoryId].displayName : '';\r\n }\r\n\r\n getYearRate(taxAuthority: TaxAuthority, tratdDetail: TaxRateAreaTaxAuthorityDetail, year: number): number | string {\r\n\r\n if (tratdDetail.yearBegin && year < tratdDetail.yearBegin )\r\n return null;\r\n\r\n if (tratdDetail.yearEnd && year > tratdDetail.yearEnd)\r\n return null;\r\n\r\n const yearDetail: TaxAuthorityDetail = _.find(taxAuthority.details, {taxYear: year});\r\n\r\n return yearDetail ? new Decimal(yearDetail.rate).times(100).toFixed(6) : null;\r\n }\r\n\r\n getTaxAuthotitiesSortedByName(taxAuthorities: TaxAuthority[]): TaxAuthority[] {\r\n return _.sortBy(taxAuthorities, 'name');\r\n }\r\n\r\n getTotalRateForDisplay(taxAuthorities: TaxAuthority[], year: number): string {\r\n const totalRate = this._getTotalRate(taxAuthorities, year);\r\n\r\n return this._isValidNumber(totalRate) ? new Decimal(totalRate).times(100).toFixed(6) : '';\r\n }\r\n\r\n getYearEstimated(taxAuthority: TaxAuthority, year: number): boolean {\r\n const yearDetail = _.find(taxAuthority.details, {taxYear: year});\r\n\r\n if (!yearDetail)\r\n return true;\r\n\r\n return !this._isDetailActual(yearDetail);\r\n }\r\n\r\n getTotalEstimated(taxAuthorities: TaxAuthority[], year: number): boolean {\r\n return _.some(taxAuthorities, taxAuthority => {\r\n return this._nonDeletedDetails(taxAuthority).length\r\n && _.some(taxAuthority.details, yearDetail =>\r\n yearDetail.taxYear === year && !this._isDetailActual(yearDetail)\r\n );\r\n });\r\n }\r\n\r\n sortData(): void {\r\n window['groupByCategory'] = this.groupByCategory;\r\n\r\n //console.log('sorting ', this.taxRateArea);\r\n this.taxRateArea.collectors = _.map(this.taxRateArea.collectors, (collector: TaxRateAreaCollector) => {\r\n\r\n //console.log('processing collector ', collector);\r\n collector.taxAuthorities.sort((a: TaxAuthority, b: TaxAuthority) => {\r\n if (window['groupByCategory']){\r\n // sorting by category first\r\n if (this.getCategory(a.taxAuthorityCategoryId) === this.getCategory(b.taxAuthorityCategoryId))\r\n return a.name >= b.name ? 1: -1;\r\n else\r\n return this.getCategory(a.taxAuthorityCategoryId) > this.getCategory(b.taxAuthorityCategoryId) ? 1: -1;\r\n } else {\r\n // ignoring category\r\n return a.name >= b.name ? 1: -1;\r\n }\r\n });\r\n\r\n //console.log('collector.taxAuthorities has been sorted ', collector);\r\n\r\n // now sort taxAuthority.taxRateAreaTaxAuthorityDetails\r\n\r\n collector.taxAuthorities = _.map(collector.taxAuthorities, (taxAuthority: TaxAuthority) => {\r\n\r\n //console.log('processing taxAuthority ', taxAuthority);\r\n\r\n taxAuthority.taxRateAreaTaxAuthorityDetails.sort( (a: TaxRateAreaTaxAuthorityDetail, b: TaxRateAreaTaxAuthorityDetail) => {\r\n const ae = a.yearEnd ? a.yearEnd: 9999;\r\n const be = b.yearEnd ? b.yearEnd: 9999;\r\n\r\n if (ae == be)\r\n return 0;\r\n\r\n return ae < be ? 1: -1;\r\n });\r\n\r\n //console.log('taxAuthority.taxRateAreaTaxAuthorityDetails has been sorted ', taxAuthority);\r\n return taxAuthority;\r\n });\r\n\r\n // collector.taxAuthorities = _.sortBy(collector.taxAuthorities, sortProperty)\r\n //console.log('we are done with collector ', collector);\r\n return collector;\r\n\r\n });\r\n }\r\n\r\n showTaxYearChanged(): void {\r\n this.years = _.range(this.taxYearBegin, this.taxYearBegin - this.taxYearsPrior - 1);\r\n }\r\n\r\n addTaxAuthority(taxAuthority: TaxAuthority) {\r\n taxAuthority.taxRateAreaTaxAuthorityDetails.push(new TaxRateAreaTaxAuthorityDetail(this.taxRateArea.taxRateAreaId, taxAuthority.taxAuthorityId));\r\n this.sortData();\r\n\r\n this._timer.setTimeout(() => {\r\n const table:any = document.getElementsByClassName('tra-table');\r\n table[0].scrollTop = table[0].scrollHeight;\r\n });\r\n }\r\n\r\n yearBeginChange(taxRateAreaTaxAuthorityDetail: TaxRateAreaTaxAuthorityDetail, taxAuthority: TaxAuthority) {\r\n if(taxRateAreaTaxAuthorityDetail.yearBegin > taxRateAreaTaxAuthorityDetail.yearEnd && taxRateAreaTaxAuthorityDetail.yearEnd !== null) {\r\n taxRateAreaTaxAuthorityDetail.yearEnd = taxRateAreaTaxAuthorityDetail.yearBegin;\r\n }\r\n\r\n this._taxYearChange(taxRateAreaTaxAuthorityDetail, taxAuthority);\r\n }\r\n\r\n yearEndChange(taxRateAreaTaxAuthorityDetail: TaxRateAreaTaxAuthorityDetail, taxAuthority: TaxAuthority) {\r\n if(taxRateAreaTaxAuthorityDetail.yearEnd < taxRateAreaTaxAuthorityDetail.yearBegin) {\r\n taxRateAreaTaxAuthorityDetail.yearBegin = taxRateAreaTaxAuthorityDetail.yearEnd;\r\n }\r\n\r\n this._taxYearChange(taxRateAreaTaxAuthorityDetail, taxAuthority);\r\n }\r\n\r\n removeTaxRateAreaTaxAuthorityDetail(taxAuthority: TaxAuthority, detail: TaxRateAreaTaxAuthorityDetail) {\r\n\r\n //console.log('removing detail', detail);\r\n\r\n if(detail.efAction == 'add') {\r\n taxAuthority.taxRateAreaTaxAuthorityDetails.splice(taxAuthority.taxRateAreaTaxAuthorityDetails.indexOf(detail), 1);\r\n } else {\r\n detail.efAction = 'delete';\r\n }\r\n }\r\n\r\n get shouldDisableAddCollector(): boolean {\r\n return _.every(this.taxRateArea.collectors, 'isTab');\r\n }\r\n\r\n get atLeastOneTab(): boolean {\r\n return _.some(this.taxRateArea.collectors, 'isTab');\r\n }\r\n\r\n addCollector(collector: TaxRateAreaCollector): void {\r\n collector.isTab = collector.active = true;\r\n }\r\n\r\n disableTaxRateArea(): void {\r\n this.taxRateArea.collectors = _.map(this.taxRateArea.collectors, collector => {\r\n collector.taxAuthorities = _.map(collector.taxAuthorities, taxAuthority => {\r\n taxAuthority.taxRateAreaTaxAuthorityDetails = _.map(taxAuthority.taxRateAreaTaxAuthorityDetails, detail => {\r\n detail.yearEnd = detail.yearEnd || this.globalYearEnd;\r\n return detail;\r\n });\r\n\r\n return taxAuthority;\r\n });\r\n\r\n return collector;\r\n });\r\n\r\n this.taxRateArea.disabled = true;\r\n this.globalYearEnd = null;\r\n }\r\n\r\n async save() {\r\n if(this.taxRateArea.disabled && this._atLeastOneInfiniteTaxYearEnd()) {\r\n this._toastr.error('A disabled Tax Rate Area cannot have an Infinite Tax Year End');\r\n return;\r\n }\r\n\r\n if(this._atLeastOneTaxYearRangeOverlap()) {\r\n this._toastr.error('Tax year ranges cannot overlap for a Tax Authority');\r\n return;\r\n }\r\n\r\n if(!_.isEqual(_.omit(this.taxRateArea, 'collectors', 'yearRateSummaryList', 'details'), _.omit(this.originalTaxRateArea, 'collectors', 'yearRateSummaryList', 'details'))) {\r\n this.taxRateArea.efAction = 'update';\r\n }\r\n\r\n this.saving = true;\r\n\r\n try {\r\n const savedArea = await this._saveOrUpdateTaxRateArea(this.taxRateArea);\r\n this.taxRateArea = this._prepareData(savedArea);\r\n\r\n this.editMode = false;\r\n\r\n this.onClose(savedArea);\r\n this.bsModalRef.hide();\r\n } finally {\r\n this.saving = false;\r\n }\r\n }\r\n\r\n async closeModal() {\r\n if(this.editMode && !_.isEqual(_.omit(this.taxRateArea, 'collectors', 'yearRateSummaryList', 'details'), _.omit(this.originalTaxRateArea, 'collectors', 'yearRateSummaryList', 'details'))) {\r\n const result: number = await this._messageBoxService.open({\r\n message: 'Are you sure you want to cancel and discard all changes?',\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (result === MessageBoxResult.OK) {\r\n if(this.clonedTaxRateArea) {\r\n this.onClose(this.clonedTaxRateArea);\r\n }\r\n\r\n this.bsModalRef.hide();\r\n }\r\n } else {\r\n if(this.clonedTaxRateArea) {\r\n this.onClose(this.clonedTaxRateArea);\r\n }\r\n\r\n this.bsModalRef.hide();\r\n }\r\n }\r\n\r\n async delete(): Promise {\r\n const result: number = await this._messageBoxService.open({\r\n message: `Are you sure you want to delete ${this.taxRateArea.name}?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (result === MessageBoxResult.OK) {\r\n if (this._featureFlagsService.featureFlags.enableTaxRateAreaTaxAuthorityBackgroundProcess){\r\n this._showBusyIndicator('Tax Rate Area', 'Deleting Tax Rate Area', null, false, true);\r\n try {\r\n const longRunningProcessId = await this._taxRateService.deleteTaxRateArea(this.taxRateArea.taxRateAreaId);\r\n await this._busyRef.setLongRunningProcessId(longRunningProcessId);\r\n }\r\n catch (e) {\r\n await this._hideBusyIndicator();\r\n return Promise.reject(e);\r\n }\r\n this.bsModalRef.hide();\r\n return Promise.resolve(); }\r\n else {\r\n await this._taxRateService.deleteTaxRateArea(this.taxRateArea.taxRateAreaId);\r\n this.onClose();\r\n this.bsModalRef.hide();\r\n }\r\n\r\n }\r\n\r\n }\r\n\r\n\r\n shouldUseDropup(taxAuthorities: TaxAuthority[]) {\r\n const taLength = _.reduce(taxAuthorities, (sum, taxAuthority) => {\r\n return sum + _.reduce(taxAuthority.taxRateAreaTaxAuthorityDetails, (sum2, detail) => {\r\n return detail.efAction === 'delete' ? sum2 : sum2 + 1;\r\n }, 0);\r\n }, 0);\r\n\r\n return taLength > 4 || (taLength > 2 && taxAuthorities.length > 4);\r\n }\r\n\r\n async clone() {\r\n this.cloning = true;\r\n\r\n this.clonedTaxRateArea = await this._taxRateService.cloneTaxRateArea(this.taxRateArea.taxRateAreaId);\r\n\r\n this._initTaxRateArea(_.cloneDeep(this.clonedTaxRateArea));\r\n this.goToEditMode();\r\n\r\n this.cloning = false;\r\n }\r\n\r\n private async _taxYearChange(taxRateAreaTaxAuthorityDetail: TaxRateAreaTaxAuthorityDetail, taxAuthority: TaxAuthority): Promise {\r\n this.loadingProjections = true;\r\n\r\n try {\r\n taxRateAreaTaxAuthorityDetail.efAction = taxRateAreaTaxAuthorityDetail.efAction || 'update';\r\n\r\n const panelProjectionsRequestPayload: PanelProjectionsPayload = {\r\n taxRateAreaId: taxRateAreaTaxAuthorityDetail.taxRateAreaId,\r\n collectorId: taxAuthority.collectorId,\r\n taxAuthorityId: taxAuthority.taxAuthorityId,\r\n taxAuthorityDefaultAnnualRateIncrease: taxAuthority.defaultAnnualRateIncrease,\r\n details: taxAuthority.details,\r\n taxRateAreaTaxAuthorityDetails: taxAuthority.taxRateAreaTaxAuthorityDetails,\r\n yearBegin: taxRateAreaTaxAuthorityDetail.yearBegin,\r\n yearEnd: taxRateAreaTaxAuthorityDetail.yearEnd\r\n };\r\n\r\n const panelProjectionsResponsePayload = await this._taxRateService.getPanelProjections(panelProjectionsRequestPayload);\r\n taxAuthority.details = panelProjectionsResponsePayload.details;\r\n } finally {\r\n this.loadingProjections = false;\r\n }\r\n\r\n }\r\n\r\n private _prepareData(taxRateArea: TaxRateAreaPayload): TaxRateAreaPayload {\r\n taxRateArea.address = taxRateArea.address || new Address();\r\n taxRateArea.collectors = _.chain(taxRateArea.collectors)\r\n .map(collector => {\r\n collector.isTab = _.some(collector.taxAuthorities, taxAuthority => taxAuthority.taxRateAreaTaxAuthorityDetails.length);\r\n\r\n return collector;\r\n })\r\n .sortBy('name')\r\n .value();\r\n\r\n if(taxRateArea.collectors.length) {\r\n if(taxRateArea.collectorId) {\r\n taxRateArea.collectors[0].isTab = true;\r\n taxRateArea.collectors[0].active = true;\r\n this.hideAddCollectorButton = true;\r\n } else {\r\n const firstActiveIdx: number = _.findIndex(taxRateArea.collectors, 'isTab');\r\n if(firstActiveIdx > -1) {\r\n taxRateArea.collectors[firstActiveIdx].active = true;\r\n }\r\n }\r\n\r\n }\r\n\r\n return taxRateArea;\r\n }\r\n\r\n private _saveOrUpdateTaxRateArea(taxRateArea: TaxRateAreaPayload): Promise {\r\n if(taxRateArea.taxRateAreaId) {\r\n return this._taxRateService.updateTaxRateArea(this.taxRateArea);\r\n } else {\r\n return this._taxRateService.createTaxRateArea(this.taxRateArea);\r\n }\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', lrpId: number, canDismiss = true, hasProgressBar = true): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this.busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: lrpId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: hasProgressBar,\r\n canDismiss\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success) => {\r\n await this._hideBusyIndicator();\r\n if (success) {\r\n this._refreshAndNotifyParent();\r\n }\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._destroy$.next();\r\n }\r\n\r\n private _refreshAndNotifyParent() {\r\n this.onClose();\r\n //this.gridDataChanged.emit();\r\n }\r\n\r\n private _isValidNumber(value: string | number): boolean {\r\n return !(value === null || value === undefined || value === '' || value === '.');\r\n }\r\n\r\n private _getTotalRate(taxAuthorities: TaxAuthority[], year: number): number {\r\n\r\n //console.log('procesing taxAuthorities', taxAuthorities);\r\n\r\n let result = 0;\r\n for(let k = 0; k < taxAuthorities.length; k++){\r\n\r\n const taxAuthority = taxAuthorities[k];\r\n for(let i = 0; i < taxAuthority.taxRateAreaTaxAuthorityDetails.length; i++){\r\n if (\r\n (!taxAuthority.taxRateAreaTaxAuthorityDetails[i].yearBegin || taxAuthority.taxRateAreaTaxAuthorityDetails[i].yearBegin <= year)\r\n &&\r\n (!taxAuthority.taxRateAreaTaxAuthorityDetails[i].yearEnd || taxAuthority.taxRateAreaTaxAuthorityDetails[i].yearEnd >= year)\r\n ){\r\n const yearDetail = _.find(taxAuthority.details, {taxYear: year});\r\n if (yearDetail)\r\n result += new Decimal(yearDetail.rate).toNumber();\r\n }\r\n }\r\n }\r\n return result;\r\n }\r\n\r\n private _initTaxRateArea(taxRateArea: TaxRateAreaPayload) {\r\n this.taxRateArea = this._prepareData(taxRateArea);\r\n\r\n if(!this.taxRateArea.collectors.length && this.taxRateArea.taxRateAreaId) {\r\n this._toastr.info('No tax authorities configured for Collector');\r\n }\r\n\r\n console.log('this.taxRateArea', _.cloneDeep(this.taxRateArea));\r\n\r\n this.sortData();\r\n }\r\n\r\n private _nonDeletedDetails(taxAuthority: TaxAuthority): TaxRateAreaTaxAuthorityDetail[] {\r\n return _.reject(taxAuthority.taxRateAreaTaxAuthorityDetails, detail => detail.efAction == 'delete');\r\n }\r\n\r\n private _isDetailActual(yearDetail: TaxAuthorityDetail): boolean {\r\n return yearDetail.taxAuthorityStatusId == TaxAuthorityStatuses.Actual;\r\n }\r\n\r\n private _atLeastOneInfiniteTaxYearEnd(): boolean {\r\n return _.chain(this.taxRateArea.collectors)\r\n .cloneDeep()\r\n .flatMap('taxAuthorities')\r\n .flatMap((taxAuthority: TaxAuthority) => this._nonDeletedDetails(taxAuthority))\r\n .some(['yearEnd', null])\r\n .value();\r\n }\r\n\r\n private _atLeastOneTaxYearRangeOverlap(): boolean {\r\n\r\n const numberOfProblematicEntries = _.chain(this.taxRateArea.collectors)\r\n .cloneDeep()\r\n //.filter({ isTab: true } )\r\n .flatMap('taxAuthorities')\r\n .map((taxAuthority: TaxAuthority) => this._nonDeletedDetails(taxAuthority))\r\n .map((detailArray: TaxRateAreaTaxAuthorityDetail[]) => {\r\n if (detailArray.length == 0) return 0;\r\n\r\n for(let i = 0; i < detailArray.length; i++){\r\n detailArray[i].yearBegin = detailArray[i].yearBegin || 1;\r\n detailArray[i].yearEnd = detailArray[i].yearEnd || 9999;\r\n }\r\n\r\n detailArray = _.sortBy(detailArray, o => o.yearBegin);\r\n\r\n for(let i = 0; i < detailArray.length; i++){\r\n if (i > 0 && (detailArray[i-1].yearBegin >= detailArray[i].yearBegin || detailArray[i-1].yearEnd >= detailArray[i].yearBegin))\r\n return 1;\r\n }\r\n return 0;\r\n })\r\n .sum()\r\n .value();\r\n\r\n //console.log('numberOfProblematicEntries', numberOfProblematicEntries);\r\n\r\n return (numberOfProblematicEntries != 0);\r\n }\r\n\r\n}\r\n","import * as _ from 'lodash';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { GridApi, GridReadyEvent, ColDef } from 'ag-grid-community';\r\nimport { YearRateSummary, TaxAuthorityDetail, TaxRateArea, TaxAuthority, TaxRateAreaDetail, TaxRateAreaTaxAuthorityDetail } from '../Assessor-Collector/Tax-Rates/tax.rates.panel.model';\r\nimport { RestrictService, Roles } from '../Common/Permissions/restrict.service';\r\nimport { AgGridColumns } from '../Compliance/AgGrid';\r\nimport { TaxRatesPanelTaxAuthoritiesCellRendererComponent, ICellRendererParamsForTaxRatesPanelTaxAuthorities } from '../Assessor-Collector/Tax-Rates/agGridTaxAuthoritiesCellRenderer.component';\r\nimport { TaxAuthorityStatuses } from '../constants.new';\r\nimport { TaxAuthorityComponent } from './Tax-Authority/tax.authority.component';\r\nimport { TaxRateAreaComponent } from './Tax-Rate-Area/tax.rate.area.component';\r\nimport { TaxRateGridService } from './tax.rate.grid.service';\r\nimport { TaxRateQcByCellRendererComponent, ICellRendererParamsForTaxRateQcBy } from './agGridQcByCellRenderer.component';\r\n\r\nexport type GridSource = 'authorities' | 'areas';\r\ntype YearObject = YearRateSummary | TaxAuthorityDetail;\r\n\r\nexport abstract class TaxRateGridComponent {\r\n protected constructor(\r\n private taxRateGridService: TaxRateGridService,\r\n protected _restrictService: RestrictService,\r\n private _modalService: BsModalService) {\r\n this.hasTaxRatePermission = _restrictService.isInRole(Roles.TAXRATESETUP);\r\n }\r\n\r\n hasTaxRatePermission: boolean = false;\r\n selectedGridSourceOption: GridSource = 'authorities';\r\n\r\n protected isInitialized: boolean = true;\r\n protected gridApi: GridApi;\r\n\r\n showTaxYearChanged() {\r\n this.gridApi.setColumnDefs(this.getGridColumns());\r\n this.gridApi.sizeColumnsToFit();\r\n }\r\n\r\n launchTaxAuthorityModal(taxAuthorityId: number, launchInEditMode: boolean): void {\r\n const initialState = { taxAuthorityId, launchInEditMode };\r\n const modalRef = this._modalService.show(TaxAuthorityComponent, {initialState, class: 'tax-rate-modal', ignoreBackdropClick: true});\r\n\r\n modalRef.content.onClose = (savedTaxAuthority: TaxAuthority) => {\r\n this.loadPanel(savedTaxAuthority);\r\n this.selectedGridSourceOption = 'authorities';\r\n\r\n };\r\n }\r\n\r\n launchTaxRateAreaModal(taxRateAreaId: number, editMode: boolean): void {\r\n const initialState = { taxRateAreaId, editMode };\r\n const modalRef = this._modalService.show(TaxRateAreaComponent, {initialState, class: 'tax-rate-modal', ignoreBackdropClick: true});\r\n\r\n modalRef.content.onClose = (savedTaxRateArea: TaxRateArea) => {\r\n this.loadPanel(savedTaxRateArea);\r\n this.selectedGridSourceOption = 'areas';\r\n };\r\n }\r\n\r\n protected getGridColumns(): ColDef[] {\r\n let cols: ColDef[] = this.getSharedColumns();\r\n\r\n if(this.selectedGridSourceOption == 'areas') {\r\n cols = [...cols, ...this.getAreaColumns()];\r\n } else {\r\n cols = [...cols, ...this.getAuthorityColumns()];\r\n }\r\n\r\n cols = _.chain(cols)\r\n .sortBy('sequence')\r\n .map(col => _.omit(col, 'sequence'))\r\n .value();\r\n\r\n const taxYears: number[] = _.range(this.taxRateGridService.taxYearBegin, this.taxRateGridService.taxYearBegin - this.taxRateGridService.taxYearsPrior - 1);\r\n\r\n cols = _.reduce(taxYears, (columns: ColDef[], taxYear: number, i: number) => {\r\n columns = [...columns, this._getRateColumn(taxYear)];\r\n\r\n if(i < taxYears.length - 1) {\r\n columns.push(this._getChangeColumn(taxYear));\r\n }\r\n\r\n return columns;\r\n }, cols);\r\n\r\n return cols;\r\n }\r\n\r\n protected abstract onAgGridReady(event: GridReadyEvent): void;\r\n protected abstract loadPanel(entity?: TaxRateArea | TaxAuthority): void;\r\n protected abstract getSharedColumns(): ColDef[];\r\n protected abstract getAuthorityColumns(): ColDef[];\r\n protected abstract getAreaColumns(): ColDef[];\r\n\r\n private _isValidNumber(value: string | number): boolean {\r\n if (value === null || value === undefined || value === '' || value === '.')\r\n return false;\r\n\r\n return true;\r\n }\r\n\r\n private _getRateColumn(year: number): ColDef {\r\n if(this.selectedGridSourceOption == 'areas') {\r\n return {\r\n headerName: `${year} Rate`,\r\n headerClass: 'text-align-right',\r\n field: 'rate',\r\n // filter: 'agNumberColumnFilter',\r\n // filterParams: AgGridFilterParams.numberFilterParams,\r\n // floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n sortable: false,\r\n width: AgGridColumns.numericColumnWidth,\r\n suppressToolPanel: true,\r\n cellRendererFramework: TaxRatesPanelTaxAuthoritiesCellRendererComponent,\r\n cellRendererParams: {\r\n rate: this._getTaxAreaRateByYear.bind(this),\r\n taxRateAuthorities: this._getAuthoritiesByTaxRateArea.bind(this),\r\n year: year\r\n } as ICellRendererParamsForTaxRatesPanelTaxAuthorities,\r\n cellClass: params => this._getCellClass(params, year)\r\n };\r\n } else {\r\n return {\r\n headerName: `${year} Rate`,\r\n headerClass: 'text-align-right',\r\n field: 'rate',\r\n // filter: 'agNumberColumnFilter',\r\n // filterParams: AgGridFilterParams.numberFilterParams,\r\n // floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n sortable: false,\r\n width: AgGridColumns.numericColumnWidth,\r\n suppressToolPanel: true,\r\n cellRendererFramework: TaxRateQcByCellRendererComponent,\r\n cellRendererParams: {\r\n rate: this._getTaxAuthorityRateByYear.bind(this),\r\n year: year\r\n } as ICellRendererParamsForTaxRateQcBy,\r\n cellClass: params => this._getCellClass(params, year)\r\n };\r\n }\r\n }\r\n\r\n private _getChangeColumn(year: number): ColDef {\r\n return {\r\n headerName: '% Change',\r\n headerClass: 'text-align-right',\r\n field: 'change',\r\n // filter: 'agNumberColumnFilter',\r\n // filterParams: AgGridFilterParams.numberFilterParams,\r\n // floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n sortable: false,\r\n width: AgGridColumns.numericColumnWidth,\r\n suppressToolPanel: true,\r\n valueGetter: (params) => {\r\n if(!params.data) {\r\n return;\r\n }\r\n const yearObj: YearObject = this._getYearObj(params, year);\r\n return yearObj && this._isValidNumber(yearObj.rateChange) ? (`${new Decimal(yearObj.rateChange).times(100).toFixed(2) }%`) : '';\r\n },\r\n cellClass: params => this._getCellClass(params, year)\r\n };\r\n }\r\n\r\n private _getTaxAuthorityRateByYear(params, year: number): string {\r\n if(!params.data) {\r\n return;\r\n }\r\n\r\n const yearObj: YearObject = this._getYearObj(params, year);\r\n return yearObj && this._isValidNumber(yearObj.rate) ? new Decimal(yearObj.rate).times(100).toFixed(6) : '';\r\n }\r\n\r\n\r\n private _getYearObj(params, year: number): YearObject {\r\n return this.selectedGridSourceOption == 'areas'\r\n ? _.find(params.data.yearRateSummaryList as YearRateSummary[], {year: year})\r\n : _.find(params.data.details as TaxAuthorityDetail[], {taxYear: year});\r\n }\r\n\r\n private _getCellClass(params, year: number): string {\r\n if(!params.data) {\r\n return;\r\n }\r\n\r\n const baseClass = 'text-align-right';\r\n const estimatedClass = 'tax-rate-estimated';\r\n const pendingClass = 'pending';\r\n\r\n if(this.selectedGridSourceOption == 'areas') {\r\n const yearObj: YearRateSummary = _.find(params.data.yearRateSummaryList as YearRateSummary[], {year: year});\r\n return yearObj && !yearObj.isActual ? `${baseClass} ${estimatedClass}` : baseClass;\r\n } else {\r\n const yearObj: TaxAuthorityDetail = _.find(params.data.details as TaxAuthorityDetail[], {taxYear: year});\r\n\r\n if(!yearObj) {\r\n return baseClass;\r\n }\r\n\r\n switch(yearObj.taxAuthorityStatusId) {\r\n case TaxAuthorityStatuses.Estimated:\r\n return `${baseClass} ${estimatedClass}`;\r\n case TaxAuthorityStatuses.Pending:\r\n return `${baseClass} ${pendingClass}`;\r\n default:\r\n return baseClass;\r\n }\r\n }\r\n }\r\n\r\n private _getTaxAreaRateByYear(taxRateArea: TaxRateArea, year: number): string {\r\n if(!taxRateArea) {\r\n return '';\r\n }\r\n\r\n const yearRateSummary: YearRateSummary = _.find(taxRateArea.yearRateSummaryList, {year: year});\r\n\r\n if (yearRateSummary && yearRateSummary.rate == 0)\r\n return new Decimal(0).toFixed(6);\r\n\r\n return yearRateSummary ? new Decimal(yearRateSummary.rate).times(100).toFixed(6) : null;\r\n }\r\n\r\n private _getAuthoritiesByTaxRateArea(taxRateArea: TaxRateArea, year: number): {name: string, rate: number | string}[] {\r\n if(!taxRateArea) {\r\n return [{name: '', rate: ''}];\r\n }\r\n const taxAuthorities: TaxAuthority[] = this.taxRateGridService.allTaxAuthorities;\r\n\r\n return _.chain(taxRateArea.details)\r\n .map((detail: TaxRateAreaDetail) => {\r\n const taxAuthority: TaxAuthority = _.find(taxAuthorities, {taxAuthorityId: detail.taxAuthorityId});\r\n\r\n if(taxAuthority) {\r\n const taDetail: TaxAuthorityDetail = _.find(taxAuthority.details, {taxYear: year});\r\n\r\n const includeThisTaxAuthorityForThisYear = _.some(taxAuthority.taxRateAreaTaxAuthorityDetails, (tratad: TaxRateAreaTaxAuthorityDetail) => {\r\n return (tratad.taxRateAreaId == taxRateArea.taxRateAreaId)\r\n && (!tratad.yearBegin || tratad.yearBegin <= year)\r\n && (!tratad.yearEnd || tratad.yearEnd >= year);\r\n });\r\n\r\n if(includeThisTaxAuthorityForThisYear && taDetail) {\r\n return {\r\n name: taxAuthority.name,\r\n rate: taDetail.rate\r\n };\r\n }\r\n }\r\n })\r\n .uniqBy('name')\r\n .value();\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable, BehaviorSubject } from 'rxjs';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport * as _ from 'lodash';\r\nimport { TaxRatesPanelPayload } from './tax.rates.panel.model';\r\nimport { TaxRateGridService } from '../../Tax-Rate/tax.rate.grid.service';\r\nimport { HttpClient } from '@angular/common/http';\r\n\r\n@Injectable()\r\nexport class TaxRatesPanelService extends TaxRateGridService {\r\n constructor(private sdHttp: SDHttpService, httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n private _taxRatesPanelDataSubject = new BehaviorSubject(false);\r\n\r\n get taxRatesPanelData$(): Observable {\r\n return this._taxRatesPanelDataSubject.asObservable();\r\n }\r\n\r\n async loadTaxRatesByCollector(collectorId: number): Promise {\r\n await this._loadTaxRatesByCollector(collectorId);\r\n\r\n this._taxRatesPanelDataSubject.next(true);\r\n }\r\n\r\n async loadTaxRatesByAssessor(assessorId: number): Promise {\r\n await this._loadTaxRatesByAssessor(assessorId);\r\n\r\n this._taxRatesPanelDataSubject.next(true);\r\n }\r\n\r\n private async _loadTaxRatesByCollector(collectorId: number): Promise {\r\n this.isInitialized = false;\r\n\r\n const taxRatesPanelPayload: TaxRatesPanelPayload = await this.sdHttp.get(`/api/taxrate/collector/${collectorId}`);\r\n\r\n this.taxRateAreas = _.sortBy(taxRatesPanelPayload.taxRateAreas, 'name');\r\n this.taxAuthorities = _.sortBy(taxRatesPanelPayload.taxAuthorities, 'name');\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n private async _loadTaxRatesByAssessor(assessorId: number): Promise {\r\n this.isInitialized = false;\r\n\r\n const taxRatesPanelPayload: TaxRatesPanelPayload = await this.sdHttp.get(`/api/taxrate/assessor/${assessorId}`);\r\n\r\n this.taxRateAreas = _.sortBy(taxRatesPanelPayload.taxRateAreas, 'name');\r\n this.taxAuthorities = _.sortBy(taxRatesPanelPayload.taxAuthorities, 'name');\r\n\r\n this.isInitialized = true;\r\n }\r\n}\r\n","
\r\n
\r\n \r\n

Tax Rates

\r\n

Tax Rate Areas

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { Constants, EntityType } from '../../constants.new';\r\nimport { TaxRatesPanelService } from './tax.rates.panel.service';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../Compliance/AgGrid';\r\nimport { Subscription } from 'rxjs';\r\nimport { ColDef, GridReadyEvent } from 'ag-grid-community';\r\nimport { TaxAuthority, TaxRateArea } from './tax.rates.panel.model';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { AddTaxEntityModalComponent, AddTaxEntityModalParams } from './add.tax.entity.modal.component';\r\nimport { RestrictService } from '../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { TaxRateGridComponent } from '../../Tax-Rate/tax.rate.grid.component';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\n@Component({\r\n selector: 'tax-rates-panel',\r\n templateUrl: './tax.rates.panel.component.html',\r\n styleUrls: ['./tax.rates.panel.component.scss']\r\n})\r\nexport class TaxRatesPanelComponent extends TaxRateGridComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _constants: Constants,\r\n public taxRatesPanelService: TaxRatesPanelService,\r\n private modalService: BsModalService,\r\n private readonly _weissmanModalService: WeissmanModalService,\r\n private restrictService: RestrictService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private featureFlagsService: FeatureFlagsService) {\r\n super(taxRatesPanelService, restrictService, modalService);\r\n }\r\n\r\n @Input() collectorId: number;\r\n @Input() assessorId: number;\r\n @Input() annualRateIncrease: number;\r\n @Output() maximizeToggled: EventEmitter = new EventEmitter();\r\n\r\n showBody: boolean = false;\r\n showDisabled: boolean = false;\r\n isMaximized: boolean = false;\r\n\r\n gridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'disabled': params => params.data && params.data.disabled\r\n },\r\n onRowClicked: (params) => {\r\n if (!params.data) {\r\n return;\r\n }\r\n\r\n if (this.selectedGridSourceOption == 'areas') {\r\n this.launchTaxRateAreaModal(params.data.taxRateAreaId, false);\r\n } else {\r\n this.launchTaxAuthorityModal(params.data.taxAuthorityId, false);\r\n }\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .withVerticalScrollBar()\r\n .build();\r\n\r\n private _taxRatesPanelDataSub: Subscription;\r\n private enableTrueRateBasedSystem: boolean;\r\n\r\n ngOnInit() {\r\n this._taxRatesPanelDataSub = this.taxRatesPanelService.taxRatesPanelData$.subscribe(() => {\r\n // initial load\r\n this._setRowData();\r\n });\r\n this.enableTrueRateBasedSystem = this.featureFlagsService.featureFlags.enableTrueRateBasedSystem;\r\n }\r\n\r\n ngOnDestroy() {\r\n this._taxRatesPanelDataSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this.gridApi = event.api;\r\n\r\n this.gridApi.setColumnDefs(this.getGridColumns());\r\n console.log('onready');\r\n this._setRowData();\r\n }\r\n\r\n selectedGridSourceChanged(): void {\r\n this.gridApi.setRowData([]);\r\n this.gridApi.setColumnDefs(this.getGridColumns());\r\n this._setRowData();\r\n }\r\n\r\n toggleMaximize(isMaximized: boolean) {\r\n this.isMaximized = isMaximized;\r\n this.maximizeToggled.emit(this.isMaximized);\r\n }\r\n\r\n expandOrCollapse(): void {\r\n this.showBody = !this.showBody;\r\n\r\n if(this.showBody) {\r\n this.loadPanel();\r\n }\r\n }\r\n\r\n showDisabledChanged(): void {\r\n this._setRowData();\r\n }\r\n\r\n async addTaxRateArea(): Promise {\r\n const modalParams: AddTaxEntityModalParams = {\r\n assessorId: this.assessorId,\r\n collectorId: this.collectorId,\r\n entityTypeId: EntityType.TaxRateArea\r\n };\r\n\r\n const taxRateAreaId = await this._weissmanModalService.showAsync(AddTaxEntityModalComponent, modalParams, 'modal-md');\r\n\r\n if (taxRateAreaId) {\r\n this.launchTaxRateAreaModal(taxRateAreaId, true);\r\n }\r\n }\r\n\r\n async addTaxAuthority(): Promise {\r\n const modalParams: AddTaxEntityModalParams = {\r\n collectorId: this.collectorId,\r\n entityTypeId: EntityType.TaxAuthority,\r\n defaultAnnualRateIncrease: this.annualRateIncrease\r\n };\r\n\r\n const taxAuthorityId = await this._weissmanModalService.showAsync(AddTaxEntityModalComponent, modalParams, 'modal-md');\r\n\r\n if(taxAuthorityId) {\r\n this.launchTaxAuthorityModal(taxAuthorityId, true);\r\n }\r\n }\r\n\r\n navigateToCommandCenter(): void {\r\n this._upgradeNavigationServiceHandler.go('taxRateCommandCenter', {});\r\n }\r\n\r\n protected loadPanel(): void {\r\n if(this.collectorId) {\r\n this.taxRatesPanelService.loadTaxRatesByCollector(this.collectorId);\r\n this.selectedGridSourceOption = 'authorities';\r\n } else if(this.assessorId) {\r\n this.taxRatesPanelService.loadTaxRatesByAssessor(this.assessorId);\r\n this.selectedGridSourceOption = 'areas';\r\n }\r\n }\r\n\r\n protected getSharedColumns(): ColDef[] {\r\n return [{\r\n headerName: 'Code',\r\n field: 'code',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth\r\n }];\r\n }\r\n\r\n protected getAuthorityColumns(): ColDef[] {\r\n return [{\r\n headerName: 'Authority Name',\r\n field: 'name',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth\r\n }, {\r\n headerName: 'Category',\r\n field: 'taxAuthorityCategoryId',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n valueGetter: (params) => {\r\n const taxAuthority: TaxAuthority = params.data;\r\n\r\n if(!taxAuthority || taxAuthority.taxAuthorityCategoryId == null) {\r\n return '';\r\n }\r\n return this._constants.TaxAuthorityCategories[taxAuthority.taxAuthorityCategoryId].displayName;\r\n }\r\n }, {\r\n headerName: 'Taxable Assessment',\r\n field: 'taxableAssessmentTypeId',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n valueGetter: (params) => {\r\n const taxAuthority: TaxAuthority = params.data;\r\n\r\n if(!taxAuthority || taxAuthority.taxableAssessmentTypeId == null) {\r\n return '';\r\n }\r\n return this.enableTrueRateBasedSystem\r\n ? this._constants.TaxableAssessmentTypesForTrueRate[taxAuthority.taxableAssessmentTypeId].displayName\r\n : this._constants.TaxableAssessmentTypes[taxAuthority.taxableAssessmentTypeId].displayName;\r\n }\r\n }];\r\n }\r\n\r\n protected getAreaColumns(): ColDef[] {\r\n return [{\r\n headerName: 'Rate Area Name',\r\n field: 'name',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth\r\n }];\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this.gridApi && this.taxRatesPanelService.isInitialized)) {\r\n return;\r\n }\r\n\r\n this.gridApi.setRowData(this._getRowData());\r\n this.gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getRowData(): TaxRateArea[] | TaxAuthority[] {\r\n if(this.selectedGridSourceOption == 'areas') {\r\n if(this.showDisabled) {\r\n return this.taxRatesPanelService.allTaxRateAreas;\r\n } else {\r\n return this.taxRatesPanelService.enabledTaxRateAreas;\r\n }\r\n } else {\r\n if(this.showDisabled) {\r\n return this.taxRatesPanelService.allTaxAuthorities;\r\n } else {\r\n return this.taxRatesPanelService.enabledTaxAuthorities;\r\n }\r\n }\r\n }\r\n}\r\n","\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { GridOptions, GridReadyEvent, ColDef, GridApi, RowNode, StartEditingCellParams } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams, AgGridTextCellEditor } from '../../../Compliance/AgGrid';\r\nimport { TaxingDistrictListGridActionCellRendererComponent, TaxingDistrictListGridActionCellRendererParams } from './agGridActionCellRenderer.component';\r\n\r\nexport interface TaxingDistrictListParams {\r\n assessorId: number;\r\n assessorName: string;\r\n taxingDistricts: Core.TaxingDistrictModel[];\r\n editMode: boolean;\r\n}\r\n\r\nexport interface TaxingDistrictListResult {\r\n taxingDistricts: Core.TaxingDistrictModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'taxing-district-list',\r\n templateUrl: './taxingDistrictList.component.html',\r\n styleUrls: ['./taxingDistrictList.component.scss']\r\n})\r\nexport class TaxingDistrictListComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef) { }\r\n\r\n params: TaxingDistrictListParams;\r\n result: TaxingDistrictListResult;\r\n isValid: boolean = true;\r\n\r\n gridId: System.Guid = '9FEF25C2-C398-4398-B5DF-74258762E46F';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n singleClickEdit: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withFloatingFilter()\r\n .withTextSelection()\r\n .withFirstDataRendered(x => {\r\n x.api.sizeColumnsToFit();\r\n })\r\n .withCellValueChanged(x => {\r\n this._validate();\r\n })\r\n .withoutCellEditingStoppedOnGridLostFocus()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n\r\n get editMode(): boolean {\r\n return this.params && this.params.editMode;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._setRowData();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Taxing District Name',\r\n field: 'name',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n editable: (x) => {\r\n return this.params.editMode;\r\n },\r\n cellEditorFramework: AgGridTextCellEditor,\r\n cellEditorParams: {\r\n maxLength: 250\r\n }\r\n },\r\n {\r\n headerName: 'Taxing District Code',\r\n field: 'code',\r\n width: AgGridColumns.textColumnMedWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n editable: (x) => {\r\n return this.params.editMode;\r\n },\r\n cellEditorFramework: AgGridTextCellEditor,\r\n cellEditorParams: {\r\n maxLength: 50\r\n }\r\n },\r\n {\r\n headerName: 'Township Name',\r\n field: 'townshipName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n editable: (x) => {\r\n return this.params.editMode;\r\n },\r\n cellEditorFramework: AgGridTextCellEditor,\r\n cellEditorParams: {\r\n maxLength: 250\r\n }\r\n },\r\n {\r\n headerName: 'Township Code',\r\n field: 'townshipCode',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n editable: (x) => {\r\n return this.params.editMode;\r\n },\r\n cellEditorFramework: AgGridTextCellEditor,\r\n cellEditorParams: {\r\n maxLength: 50\r\n }\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: TaxingDistrictListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canDelete: this._canDelete.bind(this),\r\n delete: this._delete.bind(this)\r\n } as TaxingDistrictListGridActionCellRendererParams,\r\n hide: !this.params.editMode\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'name',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n save(): void {\r\n const taxingDistricts: Core.TaxingDistrictModel[] = [];\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const taxingDistrict = node.data as Core.TaxingDistrictModel;\r\n if (taxingDistrict) {\r\n taxingDistricts.push(taxingDistrict);\r\n }\r\n });\r\n\r\n this.result = {\r\n taxingDistricts: taxingDistricts\r\n };\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n add(): void {\r\n const newTaxingDistrict: Core.TaxingDistrictModel = {\r\n assessorId: this.params.assessorId,\r\n name: '',\r\n code: '',\r\n townshipCode: '',\r\n townshipName: '',\r\n displayName: '',\r\n taxingDistrictId: 0\r\n };\r\n\r\n this._gridApi.updateRowData({ add: [newTaxingDistrict] });\r\n\r\n const params: StartEditingCellParams = {\r\n rowIndex: 0,\r\n colKey: 'name'\r\n };\r\n\r\n this._gridApi.startEditingCell(params);\r\n this._validate();\r\n }\r\n\r\n private _validate(): void {\r\n let isValid = true;\r\n\r\n const regexp = new RegExp('^[\\\\s\\\\S]*\\\\S[\\\\s\\\\S]*$');\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const taxingDistrict = node.data as Core.TaxingDistrictModel;\r\n\r\n if (!(regexp.test(taxingDistrict.name) &&\r\n regexp.test(taxingDistrict.code) &&\r\n regexp.test(taxingDistrict.townshipName) &&\r\n regexp.test(taxingDistrict.townshipCode))) {\r\n isValid = false;\r\n }\r\n });\r\n\r\n this.isValid = isValid;\r\n }\r\n\r\n private _canDelete(params: TaxingDistrictListGridActionCellRendererParams): boolean {\r\n const taxingDistrict = params.data as Core.TaxingDistrictModel;\r\n if (!taxingDistrict) {\r\n return false;\r\n }\r\n\r\n return this.params.editMode;\r\n }\r\n\r\n private _delete(params: TaxingDistrictListGridActionCellRendererParams): void {\r\n const taxingDistrict = params.data as Core.TaxingDistrictModel;\r\n if (!taxingDistrict) {\r\n return;\r\n }\r\n\r\n this._gridApi.updateRowData({ remove: [taxingDistrict] });\r\n this._validate();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.params.taxingDistricts)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this.params.taxingDistricts);\r\n this._validate();\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { TaxingDistrictListParams, TaxingDistrictListComponent } from './Taxing-District-List/taxingDistrictList.component';\r\nimport * as _ from 'lodash';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\n\r\n@Component({\r\n selector: 'taxing-district',\r\n templateUrl: './taxingDistrict.component.html'\r\n})\r\nexport class TaxingDistrictComponent {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService) { }\r\n\r\n @Input() assessor: Core.AssessorModel;\r\n @Input() editMode: boolean;\r\n\r\n async showTaxingDistricts(): Promise {\r\n const params: TaxingDistrictListParams = {\r\n assessorId: this.assessor.assessorID,\r\n assessorName: this.assessor.name,\r\n taxingDistricts: _.map(this.assessor.taxingDistrictModels, _.clone),\r\n editMode: this.editMode\r\n };\r\n\r\n const result = await this._modalService.showAsync(TaxingDistrictListComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.assessor.taxingDistrictModels = result.taxingDistricts;\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","
\r\n
\r\n

Details

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Abbr:\r\n
{{assessor.abbr}} {{assessor.municipalityName}}
\r\n
\r\n \r\n \r\n
\r\n
Full Name:\r\n
{{assessor.name}}
\r\n \r\n
Website:\r\n {{assessor.website}}\r\n \r\n
Default Parcel # Format:\r\n
{{assessor.defaultParcelNumberFormat}}
\r\n \r\n
PTX ID:\r\n
{{assessor.ptxId}}
\r\n \r\n
Default Address:\r\n \r\n \r\n
Addresses\r\n Addresses ({{ nonDeletedEntityAddresses.length }})\r\n
Taxing Districts:\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","\r\n","import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { AssessorCollectorService } from '../../assessor.collector.service';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { AddressDetailsModalLaunchService } from '../../../Common/Address/Address-View-Edit/address.details.modal.launch.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Assessor, Municipality } from '../../assessor.model';\r\nimport { AttachmentModalData } from '../../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../../Comments/comments.service';\r\nimport { EntityAddress } from '../../../Common/Address/Address-View-Edit/address.model';\r\nimport * as _ from 'lodash';\r\nimport { EntityTypeIds } from '../../../constants.new';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { Address } from '../../../Common/Models/common.model';\r\n\r\n@Component({\r\n selector: 'assessor-info',\r\n templateUrl: './assessor.info.component.html',\r\n styles: [`\r\n .assessor-info td {\r\n vertical-align: middle;\r\n }\r\n `]\r\n})\r\nexport class AssessorInfoComponent implements OnInit {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _addressDetailsModalLaunchService: AddressDetailsModalLaunchService,\r\n private readonly _toastr: ToastrService,\r\n ) { }\r\n\r\n @Input() assessor: Assessor;\r\n @Output() assessorSaved: EventEmitter = new EventEmitter();\r\n\r\n municipalities: Municipality[] = [];\r\n editMode: boolean = false;\r\n hasWritePermission: boolean = false;\r\n allowTaxingDistricts: boolean = false;\r\n\r\n private _originalAssessor: Assessor;\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.assessor) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: 'ASSESSOR',\r\n entityName: this.assessor.abbr,\r\n entityData: {\r\n typeId: Core.EntityTypes.Assessor,\r\n id: this.assessor.assessorID,\r\n name: this.assessor.abbr\r\n },\r\n readOnly: !this.hasWritePermission\r\n } as AttachmentModalData;\r\n }\r\n\r\n get commentsModel(): CommentModalData {\r\n if (!this.assessor) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityID: this.assessor.assessorID,\r\n entityTypeID: Core.EntityTypes.Assessor,\r\n description: `Assessor: ${this.assessor.abbr}`,\r\n canEdit: this.hasWritePermission\r\n } as CommentModalData;\r\n }\r\n\r\n get nonDeletedEntityAddresses(): EntityAddress[] {\r\n return _.reject(this.assessor.entityAddresses, { efAction: 'delete' });\r\n }\r\n\r\n get defaultAddress(): Address {\r\n const entityAddress = _.find(this.assessor.entityAddresses, 'isDefault');\r\n\r\n return entityAddress?.address as unknown as Address;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this.hasWritePermission = this._restrictService.isInRole(Roles.ASSESSOREDIT);\r\n this.allowTaxingDistricts = this.assessor.stateID === 16;\r\n }\r\n\r\n async save(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n this.assessor = await this._assessorCollectorService.saveAssessor(this.assessor);\r\n this.assessorSaved.emit(this.assessor);\r\n\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async edit(): Promise {\r\n if (!this.municipalities.length) {\r\n this.municipalities = await this._assessorCollectorService.getAssessorMunicipalities();\r\n }\r\n\r\n this._originalAssessor = _.cloneDeep(this.assessor);\r\n this.editMode = true;\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you wish to leave?');\r\n }\r\n\r\n cancel(): void {\r\n this.assessor = this._originalAssessor;\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n async launchAddressDetailsModal(): Promise {\r\n try {\r\n const result = await this._addressDetailsModalLaunchService.openAddressDetailsModal(\r\n this.assessor.assessorID,\r\n EntityTypeIds.ASSESSOR,\r\n _.cloneDeep(this.assessor.entityAddresses),\r\n this.editMode,\r\n false,\r\n true\r\n );\r\n\r\n if (this.editMode) {\r\n this.assessor.entityAddresses = result;\r\n }\r\n } catch (err) {\r\n this._toastr.error(err.error.message);\r\n }\r\n }\r\n\r\n updateMunicipality(): void {\r\n const m = _.find(this.municipalities, { municipalityID: this.assessor.municipalityID });\r\n\r\n if (m) {\r\n this.assessor.municipality = m;\r\n this.assessor.municipalityAbbr = m.abbr;\r\n this.assessor.municipalityName = m.name;\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n

Available Collectors

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n State:\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
DefaultCollectorState
\r\n \r\n \r\n \r\n {{ collector.collector.abbr }}\r\n \r\n {{ collector.collector.abbr }}\r\n {{ collector.stateAbbr }}\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Input } from '@angular/core';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { AssessorCollectorService } from '../../assessor.collector.service';\r\nimport { Assessor } from '../../assessor.model';\r\nimport * as _ from 'lodash';\r\nimport { StateSummary } from 'src/app/Common/States/state.model';\r\nimport { StateService } from 'src/app/Common/States/States.Service';\r\nimport { NavigationService } from 'src/app/Layout/navigation.service';\r\nimport { reject, sortBy } from 'lodash/fp';\r\n\r\nexport interface CollectorAssociation {\r\n assessor?: Assessor;\r\n assessorID: number;\r\n collector: Weissman.Model.Collectors.Collector;\r\n collectorID: number;\r\n efAction: string;\r\n hasCompanyCollectors?: boolean;\r\n isDefault: boolean;\r\n stateAbbr: string;\r\n}\r\n\r\n@Component({\r\n selector: 'assessor-available-collectors',\r\n templateUrl: './assessor.available.collectors.component.html'\r\n})\r\nexport class AssessorAvailableCollectorsComponent implements OnInit {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _stateService: StateService,\r\n private readonly _navigationService: NavigationService\r\n ) { }\r\n\r\n @Input() assessor: Assessor;\r\n @Input() state: Weissman.Model.Misc.State;\r\n\r\n collectorAssociations: CollectorAssociation[] = [];\r\n serverAction: boolean = false;\r\n loadingAvailableCollectors: boolean = false;\r\n filteredStateCollectors: Weissman.Model.Collectors.Collector[];\r\n newCollector: Weissman.Model.Collectors.Collector;\r\n editMode: boolean = false;\r\n hasWritePermission: boolean = false;\r\n\r\n private _states: StateSummary[];\r\n private _originalCollectorAssociations: CollectorAssociation[];\r\n private _stateCollectors: Weissman.Model.Collectors.Collector[];\r\n\r\n\r\n async ngOnInit(): Promise {\r\n this.hasWritePermission = this._restrictService.isInRole(Roles.ASSESSOREDIT);\r\n let collectorAssociations: CollectorAssociation[];\r\n\r\n this.serverAction = true;\r\n\r\n try {\r\n [this._states, collectorAssociations] = await Promise.all([\r\n this._stateService.getSummary(),\r\n this._assessorCollectorService.getCollectorAssociations(this.assessor.assessorID)\r\n ]);\r\n\r\n\r\n this.collectorAssociations = _.map(collectorAssociations, x => {\r\n const collectorState = _.find(this._states, { stateID: x.collector.stateID });\r\n x.stateAbbr = collectorState ? collectorState.abbr : '';\r\n\r\n return x;\r\n });\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n this.serverAction = true;\r\n\r\n try {\r\n await this._assessorCollectorService.saveAssociations(this.assessor.assessorID, this.collectorAssociations);\r\n\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n async edit(): Promise {\r\n this._originalCollectorAssociations = _.cloneDeep(this.collectorAssociations);\r\n this.editMode = true;\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you wish to leave?');\r\n\r\n this.loadAvailableCollectors(this.state.stateID);\r\n }\r\n\r\n cancel(): void {\r\n this.collectorAssociations = this._originalCollectorAssociations;\r\n this.editMode = false;\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n removeAssociation(collectorassociation: CollectorAssociation) {\r\n this.filteredStateCollectors.push(collectorassociation.collector);\r\n this.filteredStateCollectors = _.sortBy(this.filteredStateCollectors, 'abbr');\r\n\r\n _.remove(this.collectorAssociations, collectorassociation);\r\n }\r\n\r\n addAssociation(): void {\r\n const stateAbbr = _.find(this._states, { stateID: this.newCollector.stateID })?.abbr;\r\n\r\n const collectorAssociationToAdd: CollectorAssociation = {\r\n assessorID: this.assessor.assessorID,\r\n collectorID: this.newCollector.collectorID,\r\n isDefault: false,\r\n collector: this.newCollector,\r\n efAction: null,\r\n stateAbbr\r\n };\r\n\r\n this.collectorAssociations.push(collectorAssociationToAdd);\r\n\r\n _.remove(this.filteredStateCollectors, this.newCollector);\r\n\r\n setTimeout(() => {\r\n this.newCollector = undefined;\r\n });\r\n }\r\n\r\n async loadAvailableCollectors(stateId: number): Promise {\r\n this.loadingAvailableCollectors = true;\r\n\r\n try {\r\n this._stateCollectors = await this._assessorCollectorService.getAssessorCollectorList(stateId, this.assessor.assessorID);\r\n this.filteredStateCollectors = _.flow([\r\n reject(x => _.some(this.collectorAssociations, { collectorID: x.collectorID })),\r\n sortBy('abbr')\r\n ])(this._stateCollectors);\r\n\r\n } finally {\r\n this.loadingAvailableCollectors = false;\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n

{{assessor.abbr}}

\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { BreadCrumb } from '../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { StateService } from '../../Common/States/States.Service';\r\nimport { AssessorCollectorService } from '../assessor.collector.service';\r\nimport * as _ from 'lodash';\r\nimport { Assessor } from '../assessor.model';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { ContactPanelEntityData } from 'src/app/State/us.state.component';\r\n\r\n@Component({\r\n selector: 'assessor',\r\n templateUrl: './assessor.component.html'\r\n})\r\nexport class AssessorComponent implements OnInit {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _stateService: StateService,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _toastr: ToastrService\r\n ) { }\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n state: Weissman.Model.Misc.State;\r\n assessor: Assessor;\r\n assessorForInfo: Assessor;\r\n entity: ContactPanelEntityData;\r\n\r\n isTaxRatesMaximized: boolean = false;\r\n\r\n async ngOnInit(): Promise {\r\n await this._loadData();\r\n\r\n this.assessorForInfo = _.cloneDeep(this.assessor);\r\n\r\n this.entity = {\r\n id: this.assessor.assessorID,\r\n type: 'assessor',\r\n newAllowed: false,\r\n name: this.assessor.name\r\n };\r\n\r\n this.breadcrumbs = [\r\n {\r\n name: 'States',\r\n target: 'states',\r\n options: {}\r\n },\r\n {\r\n name: this.state.fullName,\r\n target: 'state',\r\n options: { stateId: this.state.stateID }\r\n },\r\n {\r\n name: 'Assessors',\r\n target: 'assessors',\r\n options: { stateId: this.state.stateID }\r\n }\r\n ];\r\n }\r\n\r\n assessorChanged(assessor): void {\r\n _.assign(this.assessor, assessor);\r\n }\r\n\r\n toggleTaxRatesMaximize(e: any): void {\r\n this.isTaxRatesMaximized = e as unknown as boolean;\r\n }\r\n\r\n private async _loadData(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n const stateIDErrMsg = 'State ID does not match assessor';\r\n try {\r\n const stateId = +this._upgradeNavigationServiceHandler.getQuerystringParam('stateId');\r\n const assessorId = +this._upgradeNavigationServiceHandler.getQuerystringParam('id');\r\n\r\n [this.state, this.assessor] = await Promise.all([\r\n this._stateService.getById(stateId),\r\n this._assessorCollectorService.getAssessor(assessorId)\r\n ]);\r\n\r\n if (this.assessor.stateID != stateId) {\r\n throw new Error(stateIDErrMsg);\r\n }\r\n }\r\n catch(e) {\r\n if(e.message === stateIDErrMsg) {\r\n this._toastr.error(e.message);\r\n }\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const COLLECTOR_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'collector.scenario-in-use',\r\n tooltipText: 'Scenario in Use'\r\n },\r\n {\r\n helpContentId: 'collector.payment-in-use',\r\n tooltipText: 'Payment Option in Use'\r\n },\r\n {\r\n helpContentId: 'collector.add-billing-scenario',\r\n tooltipText: 'Add Billing Scenario'\r\n },\r\n {\r\n helpContentId: 'collector.bill-number',\r\n tooltipText: 'Add up to 4 bills to this scenario',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'collector.default-payment-option',\r\n tooltipText: 'Set as default payment option'\r\n },\r\n {\r\n helpContentId: 'collector.ptx-discount',\r\n tooltipText: 'Set as PTX discount'\r\n },\r\n]\r\n","
\r\n
\r\n
\r\n

Collector Details

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
Abbr:
\r\n
\r\n
\r\n {{collector.abbr}} {{collector.municipalityName}}\r\n
\r\n
\r\n \r\n
\r\n
\r\n
Full Name:
\r\n
\r\n
\r\n {{collector.name}}\r\n
\r\n
\r\n \r\n
\r\n
\r\n
Website:
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
Annual Rate Increase:
\r\n
\r\n
\r\n {{collector.annualRateIncrease | percent: '1.0-3'}}\r\n
\r\n
\r\n \r\n
\r\n
\r\n
PTX ID:
\r\n
\r\n
\r\n {{collector.ptxId}}\r\n
\r\n
\r\n \r\n
\r\n
\r\n
Default Address:
\r\n
\r\n \r\n
\r\n
Addresses:
\r\n
\r\n \r\n Addresses ({{ addressesLength }})\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, Input } from '@angular/core';\r\nimport { AssessorCollectorService } from '../../assessor.collector.service';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AddressDetailsModalLaunchService } from '../../../Common/Address/Address-View-Edit/address.details.modal.launch.service';\r\nimport { AttachmentModalData } from '../../../Attachment/attachment.modal.model';\r\nimport { EntityTypeIds } from '../../../constants.new';\r\n\r\nimport * as _ from 'lodash';\r\nimport { Address } from '../../../Common/Models/common.model';\r\n\r\n@Component({\r\n selector: 'collector-details',\r\n templateUrl: './collectorDetails.component.html'\r\n})\r\nexport class CollectorDetailsComponent {\r\n constructor(\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _addressDetailsModalLaunchService: AddressDetailsModalLaunchService,\r\n private readonly _toastr: ToastrService\r\n ) {}\r\n\r\n @Input() entityId: number;\r\n @Input() companyId: number;\r\n @Input() isCompanyCollector: boolean;\r\n @Input() viewOnly: boolean;\r\n @Input()\r\n set collectorValue(collector: any) {\r\n this.collector = collector;\r\n this._initializeCollectorValues();\r\n }\r\n\r\n collector: any;\r\n editingCollector: any;\r\n entityTypeId: EntityTypeIds = EntityTypeIds.COLLECTOR;\r\n editMode: boolean;\r\n defaultAddress: Address;\r\n addressesLength: number;\r\n attachmentIcon: string;\r\n\r\n private readonly _WARNING_MESSAGE: string = 'Editing is in progress. Are you sure you want to leave?';\r\n private readonly _COLLECTOR_CAPS: string = 'Collector';\r\n private readonly _COLLECTOR: string = 'collector';\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.collector) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: this._COLLECTOR_CAPS,\r\n entityName: this.collector.abbr,\r\n entityData: {\r\n typeId: Core.EntityTypes.Collector,\r\n id: this.collector.collectorID,\r\n name: this.collector.abbr\r\n },\r\n readOnly: this.viewOnly\r\n } as AttachmentModalData;\r\n }\r\n\r\n edit(): void {\r\n this.editMode = true;\r\n this.editingCollector = _.cloneDeep(this.collector);\r\n this._navigationService.enableNavWarning(this._WARNING_MESSAGE);\r\n this._setEditAddress();\r\n }\r\n\r\n async save(): Promise {\r\n try {\r\n this.collector = await this._assessorCollectorService.saveCollector(this.editingCollector);\r\n } finally {\r\n this.cancel();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._navigationService.disableNavWarning();\r\n this.editMode = false;\r\n this.editingCollector = null;\r\n this._setEditAddress();\r\n }\r\n\r\n getCommentsModalData = (): any => {\r\n const entityId = this.collector.collectorID;\r\n const description = `${this._COLLECTOR_CAPS }: ${ this.collector.abbr}`;\r\n return {\r\n entityTypeID: this.entityTypeId,\r\n entityID: entityId,\r\n description: description,\r\n canEdit: !this.viewOnly\r\n };\r\n };\r\n\r\n async launchAddressDetailsModal(): Promise {\r\n const entityId = this.collector.collectorID;\r\n const entityAddresses = this.editMode ? this.editingCollector.entityAddresses : this.collector.entityAddresses;\r\n\r\n try {\r\n const result = await this._addressDetailsModalLaunchService.openAddressDetailsModal(\r\n entityId,\r\n this.entityTypeId,\r\n _.cloneDeep(entityAddresses),\r\n this.editMode,\r\n false,\r\n true\r\n );\r\n\r\n if(this.editMode) {\r\n this.editingCollector.entityAddresses = result;\r\n }\r\n } catch(err) {\r\n this._toastr.error(err.error.message);\r\n }\r\n }\r\n\r\n private _setEditAddress(): void {\r\n const entityAddresses = this.editMode ? this.editingCollector.entityAddresses : this.collector.entityAddresses;\r\n\r\n this.defaultAddress = entityAddresses.find(x => x.isDefault).address;\r\n this.addressesLength = _.reject(entityAddresses, {efAction: 'delete'}).length;\r\n }\r\n\r\n private _initializeCollectorValues(): void {\r\n if (this.collector) {\r\n this._setEditAddress();\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { BaseRepository } from '../Common/Data/base.repository';\r\nimport { Observable } from 'rxjs';\r\n\r\nexport interface ParcelCollectorBillScenarioInfo {\r\n collectorAbbr: string;\r\n collectorBillInfo: ParcelCollectorBillInfo[];\r\n collectorBillScenarioID: number;\r\n collectorBillScenarioName: string;\r\n collectorID: number;\r\n}\r\n\r\nexport interface ParcelCollectorBillInfo {\r\n collectorBillID: number;\r\n collectorBillName: string;\r\n collectorBillScenarioID: number;\r\n collectorPaymentOptionInfo: ParcelCollectorPaymentOptionInfo[];\r\n}\r\n\r\nexport interface ParcelCollectorPaymentOptionInfo {\r\n collectorPaymentOptionID: number;\r\n collectorPaymentOptionName: string;\r\n isDefault: boolean;\r\n}\r\n\r\n@Injectable()\r\nexport class BillingScenarioRepository extends BaseRepository {\r\n constructor(\r\n httpClient: HttpClient\r\n ) {\r\n super(httpClient);\r\n }\r\n\r\n private readonly SERVICE_URL = '/api/collectorbillscenario/';\r\n\r\n getById(id: number): Observable {\r\n return this.httpGet(`${this.SERVICE_URL}${id}`, {});\r\n }\r\n\r\n getByParcelId(id: number): Observable {\r\n return this.httpGet(`${this.SERVICE_URL}parcel/${id}`);\r\n }\r\n\r\n getInUse(id: number): Observable {\r\n return this.httpGet(`${this.SERVICE_URL}${id}/inuse`);\r\n }\r\n\r\n addScenario(scenario: any): Observable {\r\n return this.httpPost(`${this.SERVICE_URL}`, scenario);\r\n }\r\n\r\n updateScenario(scenario: any): Observable {\r\n return this.httpPut(`${this.SERVICE_URL}`, scenario);\r\n }\r\n\r\n deleteScenario(id: number): Observable {\r\n return this.httpDelete(`${this.SERVICE_URL}${id}`);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { BillingScenarioRepository, ParcelCollectorBillScenarioInfo } from '../../../Core-Repositories/billingScenario.repository';\r\n\r\n@Injectable()\r\nexport class BillingScenarioService {\r\n constructor(private readonly _billingScenarioRepository: BillingScenarioRepository) {}\r\n\r\n getById(id: number): Promise {\r\n return lastValueFrom(this._billingScenarioRepository.getById(id));\r\n }\r\n\r\n getByParcelId(id: number): Promise {\r\n return lastValueFrom(this._billingScenarioRepository.getByParcelId(id));\r\n }\r\n\r\n getInUse(id: number): Promise {\r\n return lastValueFrom(this._billingScenarioRepository.getInUse(id));\r\n }\r\n\r\n addScenario(scenario: any): Promise {\r\n return lastValueFrom(this._billingScenarioRepository.addScenario(scenario));\r\n }\r\n\r\n updateScenario(scenario: any): Promise {\r\n return lastValueFrom(this._billingScenarioRepository.updateScenario(scenario));\r\n }\r\n\r\n deleteScenario(id: number): Promise {\r\n return lastValueFrom(this._billingScenarioRepository.deleteScenario(id));\r\n }\r\n}\r\n","\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Default Scenario for Collector

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
0\" class=\"options-list-header\">\r\n Payment Options:\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n Default\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n Payment Name:\r\n Pmt Due Date:\r\n Tax Projection:\r\n Tax Period:\r\n Discount Pct:\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n to\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { RestrictService, Roles } from '../../../../Common/Permissions/restrict.service';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UntypedFormArray, UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { BillingScenarioService } from '../billingScenario.service';\r\nimport { UtilitiesService } from '../../../../UI-Lib/Utilities/Utilities.Service.upgrade';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { MessageModalService } from '../../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { Subject, Subscription } from 'rxjs';\r\nimport { CollectorBillScenario, CollectorPayment } from '../billingScenario.models';\r\nimport { distinctUntilChanged } from 'rxjs/operators';\r\n\r\nimport * as moment from 'moment';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface BillingScenarioModalParams {\r\n collector: any;\r\n inputScenario: any;\r\n}\r\n\r\nexport interface BillingScenarioResult {\r\n remove?: number;\r\n scenario?: CollectorBillScenario\r\n}\r\n\r\ninterface IdName {\r\n id: number;\r\n name: string;\r\n}\r\n\r\n@Component({\r\n selector: 'billing-scenario-modal',\r\n templateUrl: './billingScenarioModal.component.html',\r\n styleUrls: ['./billingScenarioModal.component.scss']\r\n})\r\nexport class BillingScenarioModalComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _billingScenarioService: BillingScenarioService,\r\n private readonly _utils: UtilitiesService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _messageModalService: MessageModalService\r\n ) {}\r\n\r\n params: BillingScenarioModalParams;\r\n result: BillingScenarioResult;\r\n\r\n scenarioForm: UntypedFormGroup;\r\n collector;\r\n scenario: CollectorBillScenario;\r\n viewOnly: boolean;\r\n loading: boolean;\r\n\r\n whens: IdName[] = [{\r\n id: -1,\r\n name: 'Prior'\r\n }, {\r\n id: 0,\r\n name: 'Current'\r\n }, {\r\n id: 1,\r\n name: 'Next'\r\n }, {\r\n id: 2,\r\n name: 'Next Next'\r\n }];\r\n\r\n projTypes: IdName[] = [{\r\n id: 1,\r\n name: 'Proj Rate'\r\n }, {\r\n id: 2,\r\n name: 'Prior Tax'\r\n }, {\r\n id: 3,\r\n name: 'Remain Tax'\r\n }];\r\n\r\n private _oldScenario;\r\n private _paymentSubs: Subscription[][] = [];\r\n private _destroy$: Subject = new Subject();\r\n\r\n get billNumber(): UntypedFormControl {\r\n return this.scenarioForm.get('billNumber') as UntypedFormControl;\r\n }\r\n\r\n get isDefault(): UntypedFormControl {\r\n return this.scenarioForm.get('isDefault') as UntypedFormControl;\r\n }\r\n\r\n get collectorBills(): UntypedFormArray {\r\n return this.scenarioForm.get('collectorBills') as UntypedFormArray;\r\n }\r\n\r\n toWhens = (fromWhen: number): IdName[] => {\r\n switch (fromWhen) {\r\n case 0:\r\n return this.whens.filter(x => x.id !== -1);\r\n case 1:\r\n return this.whens.filter(x => !(x.id === -1 || x.id === 0));\r\n case 2:\r\n return this.whens.filter(x => !(x.id === -1 || x.id === 0 || x.id === 1));\r\n default:\r\n return this.whens;\r\n }\r\n };\r\n\r\n async ngOnInit(): Promise {\r\n this.loading = true;\r\n\r\n this.collector = this.params.collector;\r\n this.scenario = _.cloneDeep(this.params.inputScenario);\r\n this._oldScenario = _.cloneDeep(this.params.inputScenario);\r\n this.viewOnly = this._restrictService.isNotInRoles([Roles.COLLECTOREDIT]) && !this.collector.isCompanyCollector;\r\n\r\n if (this.scenario === undefined) {\r\n this.scenarioForm = this._newScenario(this.collector.collectorID);\r\n this.loading = false;\r\n } else {\r\n try {\r\n const result = await this._billingScenarioService.getInUse(this.scenario.collectorBillScenarioID);\r\n this._prepareScenario(result);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n this.scenarioForm.controls['billNumber'].valueChanges.subscribe(() => this._addRemoveBills());\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n removeItem(list: UntypedFormArray, item, index: number) {\r\n const itemValues = item.getRawValue();\r\n if (itemValues.efAction === 'add') {\r\n list.removeAt(index);\r\n } else {\r\n item.patchValue({ efAction: 'delete' });\r\n }\r\n }\r\n\r\n addOption(bill: any): void {\r\n bill = bill as UntypedFormGroup;\r\n\r\n const billValues = bill.getRawValue();\r\n const pmtOption = this._newOption(billValues.collectorBillScenarioID, billValues.collectorBillID);\r\n // When adding the first Payment Option to a bill, set isDefault=true\r\n if (billValues.collectorPaymentOptions.length === 0) {\r\n pmtOption.patchValue({ isDefault: true });\r\n }\r\n (bill.get('collectorPaymentOptions') as UntypedFormArray).push(pmtOption);\r\n }\r\n\r\n addBill(): void {\r\n if (this.collectorBills.length === 4) {\r\n return;\r\n }\r\n\r\n this.scenarioForm.patchValue({ billNumber: Number(this.billNumber.value) + 1 });\r\n }\r\n\r\n removeBill(): void {\r\n if (this.collectorBills.length === 1) {\r\n return;\r\n }\r\n\r\n this.scenarioForm.patchValue({ billNumber: Number(this.billNumber.value) - 1 });\r\n }\r\n\r\n addPayment(option: UntypedFormGroup, optionIndex: number): void {\r\n const payments = option.get('collectorPayments') as UntypedFormArray;\r\n if (payments.length === 12) {\r\n return;\r\n }\r\n option.patchValue({ paymentNumber: payments.length + 1 });\r\n const payment = this._newPayment(option.get('collectorPaymentOptionID').value);\r\n this._watchPaymentChanges(payment, optionIndex, payments.length);\r\n payments.push(payment);\r\n\r\n if (payments.length > 1 && !this.collector.isCompanyCollector) {\r\n option.get('ptxDiscount').disable();\r\n option.get('ptxDiscount').setValue(false);\r\n }\r\n }\r\n\r\n removePayment(option: UntypedFormGroup, optionIndex: number): void {\r\n const payments = option.get('collectorPayments') as UntypedFormArray;\r\n if (payments.length === 0) {\r\n return;\r\n }\r\n const lastIndex = payments.length - 1;\r\n const payment = payments.at(lastIndex);\r\n option.patchValue({ paymentNumber: lastIndex });\r\n this._paymentSubs[optionIndex][lastIndex].unsubscribe();\r\n this._paymentSubs[optionIndex][lastIndex] = null;\r\n this.removeItem(payments, payment, lastIndex);\r\n\r\n if (payments.value.length === 1 && !!payments.value[0].discountPercent && !this.collector.isCompanyCollector) {\r\n option.get('ptxDiscount').enable();\r\n }\r\n }\r\n\r\n addRemovePayments(option: UntypedFormGroup, optionIndex: number): void {\r\n const optionValues = option.getRawValue();\r\n\r\n if (optionValues.paymentNumber < 1 || optionValues.paymentNumber > 12) {\r\n return;\r\n }\r\n\r\n const nonDeleted = this._utils.nonDeleted(optionValues.collectorPayments);\r\n const collectorPayments = option.get('collectorPayments') as UntypedFormArray;\r\n // Find the total change in number\r\n const diff = Math.abs(optionValues.paymentNumber - nonDeleted.length);\r\n let i;\r\n\r\n if (optionValues.paymentNumber > nonDeleted.length) {\r\n for (i = 0; i < diff; i++) {\r\n const payment = this._newPayment(optionValues.collectorPaymentOptionID);\r\n this._watchPaymentChanges(payment, optionIndex, collectorPayments.length);\r\n collectorPayments.push(payment);\r\n }\r\n } else {\r\n if (optionValues.collectorPayments.some(x => x.inUse) && optionValues.collectorPayments[optionValues.collectorPayments.length - 1].collectorPaymentID) {\r\n optionValues.patchValue({ paymentNumber: optionValues.paymentNumber++ });\r\n\r\n this._toastr.error('At least one payment is in use.', 'Cannot Remove!');\r\n return;\r\n }\r\n\r\n for (i = 0; i < diff; i++) {\r\n const removeIndex = collectorPayments.length - 1;\r\n this._paymentSubs[optionIndex][removeIndex].unsubscribe();\r\n this._paymentSubs[optionIndex][removeIndex] = null;\r\n collectorPayments.removeAt(removeIndex);\r\n }\r\n }\r\n }\r\n\r\n removeCollectorPaymentOption(bill: any, option: any, j: number) {\r\n this.removeItem(bill.get('collectorPaymentOptions'), option, j);\r\n }\r\n\r\n makeDefault(): void {\r\n this.collector.collectorBillScenarios = this._utils.nonDeleted(this.collector.collectorBillScenarios);\r\n this.collector.collectorBillScenarios.forEach((scenario) => {\r\n scenario.isDefault = false;\r\n });\r\n\r\n this.scenarioForm.patchValue({ isDefault: true });\r\n }\r\n\r\n async save(): Promise {\r\n const scenario = this.scenarioForm.getRawValue();\r\n\r\n if (!this.validateOnSave(scenario)) {\r\n return;\r\n }\r\n\r\n const scenarioToSave = this._prepare(scenario);\r\n\r\n if (!scenarioToSave) {\r\n return;\r\n }\r\n\r\n try {\r\n let result;\r\n if (scenario.efAction === 'add') {\r\n result = await this._billingScenarioService.addScenario(scenarioToSave);\r\n } else {\r\n result = await this._billingScenarioService.updateScenario(scenarioToSave);\r\n }\r\n\r\n this.result = { scenario: result };\r\n this._bsModalRef.hide();\r\n } catch (err) {\r\n const action = scenario.efAction === 'add' ? 'adding' : 'updating';\r\n this._toastr.error(`There was an error ${action} the billing scenario.`);\r\n }\r\n }\r\n\r\n async deleteScenarioModal(): Promise {\r\n const scenario = this.scenarioForm.getRawValue();\r\n try {\r\n await this._messageModalService.confirm(`Are you sure you want to delete ${scenario.name}?`);\r\n } catch (err) {\r\n return;\r\n }\r\n\r\n try {\r\n await this._billingScenarioService.deleteScenario(scenario.collectorBillScenarioID);\r\n\r\n this.result = { remove: scenario.collectorBillScenarioID };\r\n this._bsModalRef.hide();\r\n } catch (err) {\r\n this._toastr.error('There was an error attempting to delete this scenario.');\r\n }\r\n }\r\n\r\n undefaultOthers(bill, newDefault: UntypedFormGroup, i) {\r\n const list = bill.get('collectorPaymentOptions') as UntypedFormArray;\r\n list.controls.forEach(x => {\r\n if (x.value.efAction !== 'delete') {\r\n x.patchValue({ isDefault: false });\r\n }\r\n });\r\n\r\n newDefault.patchValue({ isDefault: true });\r\n }\r\n\r\n undiscountOthers(bill, newDiscount: UntypedFormGroup, event: any) {\r\n const ptxDiscount = event.target.checked;\r\n\r\n const list = bill.get('collectorPaymentOptions') as UntypedFormArray;\r\n list.controls.forEach(x => {\r\n if (x.value.efAction !== 'delete') {\r\n x.patchValue({ ptxDiscount: false });\r\n }\r\n });\r\n\r\n newDiscount.patchValue({ ptxDiscount });\r\n }\r\n\r\n discountPercentChanged(option: UntypedFormGroup, event: any) {\r\n if(this.collector.isCompanyCollector) {\r\n return;\r\n }\r\n\r\n const ptxDiscount = option.get('ptxDiscount');\r\n const payments = option.get('collectorPayments') as UntypedFormArray;\r\n\r\n if(event.target.value && payments.length === 1) {\r\n ptxDiscount.enable();\r\n } else {\r\n ptxDiscount.disable();\r\n ptxDiscount.setValue(false);\r\n }\r\n }\r\n\r\n validateOnSave(scenario) {\r\n // Verify that at least one Bill is configured for the Bill Scenario.\r\n if (this._utils.nonDeleted(scenario.collectorBills).length < 1) {\r\n this._toastr.error('At least one Bill must be configured for a Bill Scenario.', 'Cannot Save!');\r\n return false;\r\n }\r\n\r\n return this._utils.nonDeleted(scenario.collectorBills).every((bill) => {\r\n\r\n // Verify that at least one Payment Option is configured for each Bill.\r\n if (this._utils.nonDeleted(bill.collectorPaymentOptions).length < 1) {\r\n this._toastr.error('At least one Payment Option must be configured for each Bill.', 'Cannot Save!');\r\n return false;\r\n }\r\n\r\n return this._utils.nonDeleted(bill.collectorPaymentOptions).every((option) => {\r\n\r\n // Verify that at least one Payment is configured for each Payment Option.\r\n if (this._utils.nonDeleted(option.collectorPayments).length < 1) {\r\n this._toastr.error('At least one Payment must be configured for each Payment Option.', 'Cannot Save!');\r\n return false;\r\n }\r\n\r\n // Verify that required content is not missing for each Payment configured and\r\n // content is valid.\r\n return _.every(this._utils.nonDeleted(option.collectorPayments), (payment) => {\r\n\r\n let isValid = true;\r\n if (!payment.dueMonthDay) {\r\n this._toastr.error('Each Payment must have a Pmt Due Date configured, in M/D format.', 'Cannot Save!');\r\n isValid = false;\r\n } else if (!moment(payment.dueMonthDay, 'M/D', true).isValid()) {\r\n this._toastr.error('Invalid Pmt Date. Must be in M/D format.');\r\n isValid = false;\r\n }\r\n if (!payment.projectionPercentage || payment.projectionPercentage < 0 || payment.projectionPercentage > 100) {\r\n this._toastr.error('Each Payment must have a Tax Projection configured, from 0 to 100%.', 'Cannot Save!');\r\n isValid = false;\r\n }\r\n if (!payment.accrualBeginDate || !payment.accrualEndDate) {\r\n this._toastr.error('Each Payment must have a Accrual Period Begin and End configured, in M/D format.', 'Cannot Save!');\r\n isValid = false;\r\n }\r\n if (_.trim(payment.accrualBeginDate, '0') === '2/29' || _.trim(payment.accrualEndDate, '0') === '2/29') {\r\n this._toastr.error('Leap Days are not permitted as accrual dates.');\r\n isValid = false;\r\n }\r\n if (payment.projectionPercentage > 1.0) {\r\n this._toastr.error('Each Payment Tax Projection must be in the range from 0 to 100%.', 'Cannot Save!');\r\n isValid = false;\r\n }\r\n if (payment.discountPercent && payment.discountPercent > 1.0) {\r\n this._toastr.error('An entered Payment Discount Percent must be in the range from 0 to 100%.', 'Cannot Save!');\r\n isValid = false;\r\n }\r\n return isValid;\r\n })\r\n && this._validateNoOverlap(option.collectorPayments);\r\n })\r\n && this._validateAtLeastOnePaymentOptionIsDefault(bill);\r\n });\r\n }\r\n\r\n private _prepare(scenarioToPrepare): CollectorBillScenario {\r\n let scenario = _.omit(_.cloneDeep(scenarioToPrepare), ['billNumber', 'inUse']);\r\n\r\n //TODO there has to be a cleaner way to strip these values\r\n scenario.collectorBills = scenario.collectorBills.map((bill) => {\r\n if (scenario.efAction === 'add') {\r\n bill = _.omit(bill, 'collectorBillScenarioID');\r\n }\r\n if (bill.efAction === 'add') {\r\n bill = _.omit(bill, 'collectorBillID');\r\n }\r\n bill = _.omit(bill, 'inUse');\r\n bill.collectorPaymentOptions = bill.collectorPaymentOptions.map((option) => {\r\n option.collectorPayments = option.collectorPayments.map((payment) => {\r\n if (scenario.efAction === 'add') {\r\n payment = _.omit(payment, 'collectorPaymentOptionID');\r\n }\r\n if (payment.efAction === 'add') {\r\n payment = _.omit(payment, 'collectorPaymentID');\r\n }\r\n return _.omit(payment, ['monthDay', 'inUse']);\r\n });\r\n if (scenario.efAction === 'add') {\r\n option = _.omit(option, ['collectorBillScenarioID', 'collectorBillID']);\r\n }\r\n if (option.efAction === 'add') {\r\n if (!option.collectorPaymentOptionID) {\r\n option = _.omit(option, 'collectorPaymentOptionID');\r\n }\r\n if (!option.collectorBillID) {\r\n option = _.omit(option, 'collectorBillID');\r\n }\r\n }\r\n return _.omit(option, ['paymentNumber', 'earliestPaymentSortValue', 'inUse']);\r\n });\r\n return bill;\r\n });\r\n\r\n if (scenario.efAction === 'add') {\r\n scenario = _.omit(scenario, 'collectorBillScenarioID');\r\n return scenario as CollectorBillScenario;\r\n }\r\n\r\n if (!_.isEqual(this._oldScenario, scenario)) {\r\n scenario.efAction = 'update';\r\n }\r\n\r\n scenario.collectorBills = scenario.collectorBills.map((bill) => {\r\n if (bill.efAction !== null) {\r\n return bill;\r\n }\r\n\r\n const oldBill = this._oldScenario.collectorBills.find(x => x.collectorBillID === bill.collectorBillID);\r\n if (!_.isEqual(bill, oldBill)) {\r\n bill.efAction = 'update';\r\n }\r\n\r\n bill.collectorPaymentOptions = bill.collectorPaymentOptions.map((option) => {\r\n if (option.efAction !== null) {\r\n return option;\r\n }\r\n const oldOption = oldBill?.collectorPaymentOptions.find(x => x.collectorPaymentOptionID === option.collectorPaymentOptionID);\r\n if (!_.isEqual(option, oldOption)) {\r\n option.efAction = 'update';\r\n }\r\n\r\n option.collectorPayments = option.collectorPayments.map((payment) => {\r\n if (payment.efAction !== null) {\r\n return payment;\r\n }\r\n const oldPayment = oldOption?.collectorPayments.find(x => x.collectorPaymentID === payment.collectorPaymentID);\r\n if (!_.isEqual(payment, oldPayment)) {\r\n payment.efAction = 'update';\r\n }\r\n\r\n return payment;\r\n });\r\n\r\n return option;\r\n });\r\n\r\n return bill;\r\n });\r\n\r\n return scenario as CollectorBillScenario;\r\n }\r\n\r\n private _addRemoveBills(): void {\r\n const scenario = this.scenarioForm.getRawValue();\r\n let billNumber = Number(scenario.billNumber);\r\n\r\n if (billNumber < 1 || billNumber > 4) {\r\n return;\r\n }\r\n const nonDeleted = this._utils.nonDeleted(scenario.collectorBills);\r\n // Find the total change in number\r\n const diff = Math.abs(billNumber - nonDeleted.length);\r\n let i: number;\r\n\r\n if (billNumber >= nonDeleted.length) {\r\n for (i = 0; i < diff; i++) {\r\n (this.scenarioForm.get('collectorBills') as UntypedFormArray).push(this._newBill(scenario.collectorBillScenarioID, true));\r\n }\r\n } else {\r\n if (scenario.collectorBills.some(x => x.inUse) && scenario.collectorBills[scenario.collectorBills.length - 1].collectorBillID) {\r\n this.scenarioForm.patchValue({ billNumber: billNumber++ }, { emitEvent: false });\r\n\r\n this._toastr.error('At least one bill is in use.', 'Cannot Remove!');\r\n return;\r\n }\r\n\r\n for (i = 0; i < diff; i++) {\r\n const lastIndex = this.collectorBills.length - 1;\r\n const lastBill = this.collectorBills.at(lastIndex);\r\n this.removeItem(this.scenarioForm.get('collectorBills') as UntypedFormArray, lastBill, lastIndex);\r\n }\r\n }\r\n }\r\n\r\n private _newPayment(id?: number): UntypedFormGroup {\r\n return this._fb.group({\r\n collectorPaymentOptionID: [id || 0],\r\n collectorPaymentID: [null],\r\n name: [{ value: '', disabled: this.viewOnly }],\r\n dueMonthDay: [{ value: '', disabled: this.viewOnly }, [Validators.pattern('^([1-9]|0[1-9]|1[0-2])\\/([1-9]|0[1-9]|1[0-9]|2[0-9]|3[0-1])$')]],\r\n monthDay: [-1],\r\n efAction: ['add'],\r\n accrualBeginDate: [{ value: '', disabled: this.viewOnly }, [Validators.pattern('^([1-9]|0[1-9]|1[0-2])\\/([1-9]|0[1-9]|1[0-9]|2[0-9]|3[0-1])$')]],\r\n accrualBeginYearID: [{ value: -1, disabled: this.viewOnly }],\r\n accrualEndDate: [{ value: '', disabled: this.viewOnly }, [Validators.pattern('^([1-9]|0[1-9]|1[0-2])\\/([1-9]|0[1-9]|1[0-9]|2[0-9]|3[0-1])$')]],\r\n accrualEndYearID: [{ value: -1, disabled: this.viewOnly }],\r\n dueYearID: [{ value: -1, disabled: this.viewOnly }],\r\n projectionPercentage: [{ value: 0, disabled: this.viewOnly }],\r\n projectionType: [{ value: 1, disabled: this.viewOnly }],\r\n discountPercent: [{ value: 0, disabled: this.viewOnly }],\r\n });\r\n }\r\n\r\n private _newOption(scenarioId: number, id?: number, isDefault = false, startEmpty = false): UntypedFormGroup {\r\n return this._fb.group({\r\n collectorBillScenarioID: [scenarioId || null],\r\n collectorBillID: [id || null],\r\n collectorPaymentOptionID: [null],\r\n collectorBillName: [null],\r\n isDefault: [{ value: isDefault, disabled: this.viewOnly }],\r\n name: [{ value: '', disabled: this.viewOnly }],\r\n efAction: ['add'],\r\n inUse: [false],\r\n paymentNumber: [{ value: 1, disabled: this.viewOnly }],\r\n collectorPayments: this._fb.array(startEmpty ? [] : [this._newPayment()]),\r\n ptxDiscount: [{value: false, disabled: true}]\r\n });\r\n }\r\n\r\n private _newBill(id?: number, startEmpty = false): UntypedFormGroup {\r\n // For a new Bill, set isDefault=true for the initial empty Payment Option\r\n return this._fb.group({\r\n collectorBillScenarioID: [id || null],\r\n collectorBillID: [null],\r\n name: [{ value: '', disabled: this.viewOnly }],\r\n procureDays: [{ value: 1, disabled: this.viewOnly }],\r\n efAction: ['add'],\r\n inUse: [false],\r\n collectorPaymentOptions: this._fb.array(startEmpty ? [] : [this._newOption(id, null, true)])\r\n });\r\n }\r\n\r\n private _newScenario(id?: number, startEmpty = false): UntypedFormGroup {\r\n return this._fb.group({\r\n name: [{ value: '', disabled: this.viewOnly }],\r\n billNumber: [{ value: 1, disabled: this.viewOnly || this.scenario?.inUse }],\r\n isDefault: [false],\r\n collectorID: [id || null],\r\n efAction: ['add'],\r\n enabled: [{ value: true, disabled: this.viewOnly }],\r\n inUse: [false],\r\n collectorBillScenarioID: [null],\r\n collectorBills: this._fb.array(startEmpty ? [] : [this._newBill()])\r\n });\r\n }\r\n\r\n private _prepareScenario(inUseObj): void {\r\n this.scenarioForm = this._newScenario(inUseObj.collectorID, true);\r\n\r\n this.scenario.collectorBills.forEach((bill, i) => {\r\n const billControl = this._newBill(this.scenario.collectorBillScenarioID, true);\r\n const collectorPaymentOptions = billControl.get('collectorPaymentOptions') as UntypedFormArray;\r\n\r\n bill.collectorPaymentOptions\r\n .sort((a, b) => {\r\n // Kind of a hack to create a sort value for payment option dueYear ID then monthDay\r\n const ae = (a.collectorPayments[0].dueYearID * 100) + a.collectorPayments[0].monthDay;\r\n const be = (b.collectorPayments[0].dueYearID * 100) + b.collectorPayments[0].monthDay;\r\n if (a.isDefault > b.isDefault || ae < be || (a.name || '').localeCompare(b.name) === 1) {\r\n return 1;\r\n } else if (a.isDefault < b.isDefault || ae > be || (a.name || '').localeCompare(b.name) === -1) {\r\n return -1;\r\n } else {\r\n return 0;\r\n }\r\n })\r\n .forEach((option, j) => {\r\n const optionControl = this._newOption(option.collectorBillScenarioID, bill.collectorBillID, false, true);\r\n const collectorPayments = optionControl.get('collectorPayments') as UntypedFormArray;\r\n\r\n option.collectorPayments\r\n .sort((a, b) => {\r\n const at = a.dueMonthDay.split('/');\r\n const bt = b.dueMonthDay.split('/');\r\n return (a.dueYearID > b.dueYearID ? 1 : (a.dueYearID < b.dueYearID ? -1 : 0))\r\n || (+at.join('.') > +bt.join('.') ? 1 : (+at.join('.') > +bt.join('.') ? -1 : 0));\r\n })\r\n .forEach((payment, k) => {\r\n const paymentControl = this._newPayment(payment.collectorPaymentOptionID);\r\n\r\n const dt = payment.dueMonthDay.split('/');\r\n paymentControl.patchValue({\r\n ...payment,\r\n monthDay: parseFloat(`${dt[0] }.${ dt[1]}`),\r\n inUse: inUseObj.collectorPayments.find(x => x.collectorPaymentId === payment.collectorPaymentID)?.inUse\r\n });\r\n this._watchPaymentChanges(paymentControl, j, k);\r\n collectorPayments.push(paymentControl);\r\n });\r\n\r\n const inUse = inUseObj.collectorPaymentOptions.find(x => x.collectorPaymentOptionId === option.collectorPaymentOptionID)?.inUse;\r\n\r\n optionControl.patchValue({\r\n ...option,\r\n paymentNumber: option.collectorPayments.length,\r\n inUse\r\n });\r\n\r\n if (inUse) {\r\n optionControl.get('paymentNumber').disable();\r\n }\r\n\r\n if(!this.collector.isCompanyCollector) {\r\n if (this.viewOnly || option.collectorPayments.length > 1 || !option.collectorPayments[0].discountPercent) {\r\n optionControl.get('ptxDiscount').disable();\r\n } else {\r\n optionControl.get('ptxDiscount').enable();\r\n }\r\n }\r\n\r\n collectorPaymentOptions.push(optionControl);\r\n });\r\n\r\n billControl.patchValue({\r\n ...bill,\r\n inUse: inUseObj.collectorBills.find(x => x.collectorBillId === bill.collectorBillID)?.inUse\r\n });\r\n\r\n // All items must be pushed into the form array, Angular doesn't allow setValue or patchValue for FormArray types\r\n this.collectorBills.push(billControl);\r\n });\r\n\r\n this.scenarioForm.patchValue({\r\n ...this.scenario,\r\n billNumber: this.scenario.collectorBills.length,\r\n inUse: inUseObj.collectorBillScenario.inUse\r\n });\r\n }\r\n\r\n private _validateAtLeastOnePaymentOptionIsDefault(bill) {\r\n // See if any Payment Option of this Bill has Default checked.\r\n const nonDeletedOptions = this._utils.nonDeleted(bill.collectorPaymentOptions);\r\n let anyChecked = _.some(nonDeletedOptions, ['isDefault', true]);\r\n\r\n if (!anyChecked) {\r\n // None with Default checked.\r\n // If only one Payment Option, auto-set Default=true.\r\n // Otherwise, validation fails.\r\n if (nonDeletedOptions.length === 1) {\r\n _.head(nonDeletedOptions).isDefault = true;\r\n anyChecked = true;\r\n }\r\n }\r\n if (!anyChecked) {\r\n this._toastr.error('At least one Payment Option for a Bill must be checked as Default.', 'Cannot Save!');\r\n }\r\n\r\n return anyChecked;\r\n }\r\n\r\n private _validateNoOverlap(payments: CollectorPayment[]): boolean {\r\n const currentYear = new Date().getFullYear();\r\n\r\n const taxPeriods = _.map(payments, payment => {\r\n const beginStr = `${payment.accrualBeginDate}/${currentYear + payment.accrualBeginYearID}`;\r\n const endStr = `${payment.accrualEndDate}/${currentYear + payment.accrualEndYearID}`;\r\n return {\r\n begin: new Date(beginStr),\r\n end: new Date(endStr)\r\n };\r\n });\r\n\r\n // Check for overlap or if they are identical\r\n let valid = _.every(taxPeriods, (taxPeriod1, i) => {\r\n return _.every(taxPeriods, (taxPeriod2, j) => {\r\n if(i === j) {\r\n return true;\r\n }\r\n\r\n const areTaxPeriodsIdentical = (taxPeriod1.begin.getTime() === taxPeriod2.begin.getTime()\r\n && taxPeriod1.end.getTime() === taxPeriod2.end.getTime());\r\n const taxPeriodsNotOverlapping = (taxPeriod1.begin < taxPeriod2.begin || taxPeriod1.begin > taxPeriod2.end)\r\n && (taxPeriod1.end < taxPeriod2.begin || taxPeriod1.end > taxPeriod2.end);\r\n\r\n return areTaxPeriodsIdentical || taxPeriodsNotOverlapping;\r\n });\r\n });\r\n\r\n if(!valid) {\r\n this._toastr.error('At least two payments\\' tax periods are overlapping', 'Cannot Save!');\r\n return valid;\r\n }\r\n\r\n // Check that the beginning and end dates are contiguous for all tax periods\r\n if (taxPeriods.length > 1) {\r\n valid = taxPeriods.every((taxPeriod1, i) => {\r\n return !!taxPeriods.find((taxPeriod2, j) => {\r\n if(i === j) {\r\n return false;\r\n }\r\n\r\n // Allow identical tax periods\r\n if (taxPeriod1.begin.getTime() === taxPeriod2.begin.getTime()\r\n && taxPeriod1.end.getTime() === taxPeriod2.end.getTime()) {\r\n return true;\r\n }\r\n\r\n const period1BeginMinusOne = new Date(taxPeriod1.begin);\r\n period1BeginMinusOne.setDate(period1BeginMinusOne.getDate() - 1);\r\n const period1EndPlusOne = new Date(taxPeriod1.end);\r\n period1EndPlusOne.setDate(period1EndPlusOne.getDate() + 1);\r\n\r\n return period1BeginMinusOne.getTime() === taxPeriod2.end.getTime()\r\n || period1EndPlusOne.getTime() === taxPeriod2.begin.getTime();\r\n });\r\n });\r\n\r\n if(!valid) {\r\n this._toastr.error('At least two payments\\' tax periods are not contiguous', 'Cannot Save!');\r\n }\r\n }\r\n\r\n return valid;\r\n }\r\n\r\n private _watchPaymentChanges(payment: UntypedFormGroup, optionIndex: number, index: number): void {\r\n if(!Array.isArray(this._paymentSubs[optionIndex])) {\r\n this._paymentSubs[optionIndex] = [];\r\n }\r\n this._paymentSubs[optionIndex][index] = payment.get('accrualBeginYearID').valueChanges.pipe(distinctUntilChanged()).subscribe(x => {\r\n const endYear = payment.get('accrualEndYearID');\r\n if (x === 0 && endYear.value === -1) {\r\n endYear.patchValue(0);\r\n } else if (x === 1 && (endYear.value === -1 || endYear.value === 0)) {\r\n endYear.patchValue(1);\r\n } else if (x === 2) {\r\n endYear.patchValue(2);\r\n }\r\n });\r\n }\r\n}\r\n","
\r\n
\r\n

Billing Scenarios

\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n Tax Year:\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Displayed payment due dates use current due date values and may not be accurate to the values used historically\r\n
\r\n
\r\n \r\n
\r\n
\r\n

\r\n {{scenario.name}}\r\n Scenario\r\n

\r\n
\r\n

Default

\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
{{bill.name}}
\r\n
Payment Option(s):
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n or\r\n
\r\n
\r\n
\r\n
\r\n
1\" class=\"default-opt\">Default
\r\n {{(option.name !== null ? option.name : 'Payment option')}}:\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\" class=\"payment\" [ngClass]=\"{ 'even': paymentIndex % 2 }\">\r\n \r\n \r\n \r\n \r\n \r\n
\r\n {{(payment.name !== null ? payment.name : 'Payment')}}\r\n \r\n due\r\n \r\n {{payment.dueMonthDay}}/{{toWords(payment.dueYearID)}}\r\n \r\n Tax Period:\r\n \r\n {{payment.accrualBeginDate}}/{{toWords(payment.accrualBeginYearID)}}\r\n \r\n to\r\n \r\n {{payment.accrualEndDate}}/{{toWords(payment.accrualEndYearID)}}\r\n
\r\n Discount:\r\n {{(payment.discountPercent * 100)}}%
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { BillingScenarioModalComponent, BillingScenarioModalParams } from './New-Scenario/billingScenarioModal.component';\r\nimport { YearPickerMixin } from '../../../UI-Lib/Mixins';\r\n\r\n@Component({\r\n selector: 'billing-scenario',\r\n templateUrl: './billingScenario.component.html',\r\n styleUrls: ['./billingScenario.component.scss']\r\n})\r\nexport class BillingScenarioComponent extends YearPickerMixin() implements OnInit {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _weissmanModalService: WeissmanModalService\r\n ) {\r\n super();\r\n }\r\n\r\n @Input() collector;\r\n @Output() collectorUpdated: EventEmitter = new EventEmitter();\r\n\r\n selectedYear: number;\r\n viewOnly: boolean;\r\n showDisabled: boolean;\r\n showYearWarning: boolean;\r\n\r\n paymentOrder = (payment): number => {\r\n const dt = payment.dueMonthDay.split('/');\r\n const monthDay = parseInt(`${dt[0] }.${ dt[1]}`);\r\n return (payment.dueYearID * 100) + monthDay;\r\n };\r\n\r\n ngOnInit(): void {\r\n this.viewOnly = this._restrictService.isNotInRoles([Roles.COLLECTOREDIT]) && !this.collector.isCompanyCollector;\r\n this.selectedYear = new Date().getFullYear();\r\n }\r\n\r\n toWords(id: number): number {\r\n switch (id) {\r\n case -1:\r\n return this.selectedYear - 1;\r\n case 0:\r\n return this.selectedYear;\r\n case 1:\r\n return this.selectedYear + 1;\r\n case 2:\r\n return this.selectedYear + 2;\r\n }\r\n }\r\n\r\n async openScenario(scenario?: any): Promise {\r\n try {\r\n const params = {\r\n collector: this.collector,\r\n inputScenario: scenario\r\n } as BillingScenarioModalParams;\r\n\r\n const result = await this._weissmanModalService.showAsync(BillingScenarioModalComponent, params, 'modal-xl');\r\n\r\n if (result) {\r\n this.collectorUpdated.emit();\r\n }\r\n } catch(err) {\r\n return null;\r\n }\r\n }\r\n\r\n yearChanged(year: string): void {\r\n this.selectedYear = +year;\r\n this.showYearWarning = +year < new Date().getFullYear();\r\n }\r\n}\r\n","
\r\n
\r\n \r\n

Collector Protocols

\r\n\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n *Value cannot be lower than 0\r\n
\r\n
\r\n *Value cannot be greater than 1000\r\n
\r\n
\r\n Maximum {{collector.maxItemsPerCheck || 0}} payment item{{(collector.maxItemsPerCheck > 1 || collector.maxItemsPerCheck === 0 ? 's' : '')}} per check\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { AssessorCollectorService } from '../../assessor.collector.service';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\n\r\nimport * as _ from 'lodash';\r\nimport { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'collector-protocols',\r\n templateUrl: './collectorProtocols.component.html'\r\n})\r\nexport class CollectorProtocolsComponent implements OnInit {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _fb: UntypedFormBuilder\r\n ) {}\r\n\r\n @Input() collector: Weissman.Model.Collectors.Collector;\r\n @Input() canEdit: boolean;\r\n\r\n isEdit: boolean;\r\n showBody: boolean;\r\n isLoading: boolean;\r\n hasEditPermission: boolean;\r\n hasViewPermission: boolean;\r\n saving: boolean;\r\n\r\n protocolForm: UntypedFormGroup;\r\n\r\n private readonly WARNING_MESSAGE = 'Editing is in progress. Are you sure you want to leave?';\r\n\r\n get originalTaxBillRequired(): UntypedFormControl {\r\n return this.protocolForm.get('originalTaxBillRequired') as UntypedFormControl;\r\n }\r\n\r\n get receiveByDueDate(): UntypedFormControl {\r\n return this.protocolForm.get('receiveByDueDate') as UntypedFormControl;\r\n }\r\n\r\n get maxItemsPerCheck(): UntypedFormControl {\r\n return this.protocolForm.get('maxItemsPerCheck') as UntypedFormControl;\r\n }\r\n\r\n ngOnInit(): void {\r\n this.hasEditPermission = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT);\r\n this.hasViewPermission = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n }\r\n\r\n expandOrCollapse(): void {\r\n if(this.isEdit) {\r\n return;\r\n }\r\n\r\n this.showBody = !this.showBody;\r\n\r\n if (this.showBody && !this.protocolForm) {\r\n this.protocolForm = this._fb.group({\r\n originalTaxBillRequired: [{ value: this.collector?.originalTaxBillRequired, disabled: true }],\r\n receiveByDueDate: [{ value: this.collector?.receiveByDueDate, disabled: true }],\r\n maxItemsPerCheck: [this.collector?.maxItemsPerCheck || 0, [Validators.min(0), Validators.max(1000)]]\r\n });\r\n }\r\n\r\n this.isEdit = false;\r\n }\r\n\r\n editMode(): void {\r\n this.showBody = true;\r\n this.isEdit = true;\r\n this.originalTaxBillRequired.enable();\r\n this.receiveByDueDate.enable();\r\n this._navigationService.enableNavWarning(this.WARNING_MESSAGE);\r\n }\r\n\r\n cancelEdit(): void {\r\n this._navigationService.disableNavWarning();\r\n this.showBody = true;\r\n this.isEdit = false;\r\n this.originalTaxBillRequired.disable();\r\n this.receiveByDueDate.disable();\r\n\r\n this.protocolForm.reset(this.collector);\r\n }\r\n\r\n async savePanel(): Promise {\r\n this.saving = true;\r\n\r\n try {\r\n const formValues = this.protocolForm.getRawValue();\r\n formValues.maxItemsPerCheck = formValues.maxItemsPerCheck > 0 ? formValues.maxItemsPerCheck : null;\r\n const update = {\r\n ..._.cloneDeep(this.collector),\r\n ...formValues\r\n };\r\n\r\n await this._assessorCollectorService.saveCollectorProtocols(update);\r\n\r\n this.collector.originalTaxBillRequired = formValues.originalTaxBillRequired;\r\n this.collector.receiveByDueDate = formValues.receiveByDueDate;\r\n this.collector.maxItemsPerCheck = formValues.maxItemsPerCheck;\r\n } finally {\r\n this._navigationService.disableNavWarning();\r\n this.showBody = true;\r\n this.isEdit = false;\r\n this.originalTaxBillRequired.disable();\r\n this.receiveByDueDate.disable();\r\n this.saving = false;\r\n }\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BreadCrumb } from '../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { StateSummary } from '../../Common/States/state.model';\r\nimport { StateService } from '../../Common/States/States.Service';\r\nimport { AssessorCollectorService } from '../assessor.collector.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { RestrictData, RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { COLLECTOR_HELP } from './collector.help';\r\nimport { TaxRatesService } from '../Tax-Rates/tax.rates.service';\r\nimport { CompanyService } from '../../Entity/Company/company.service';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\n\r\n@Component({\r\n selector: 'collector',\r\n templateUrl: './collector.component.html'\r\n})\r\nexport class CollectorComponent implements OnInit {\r\n constructor(\r\n private readonly _route: UpgradeNavigationServiceHandler,\r\n private readonly _stateService: StateService,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _helpService: HelpService,\r\n private readonly _taxRatesService: TaxRatesService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _featureFlagsService: FeatureFlagsService\r\n\r\n ) {}\r\n\r\n entityId: number;\r\n companyId: number;\r\n viewOnly: boolean;\r\n isTaxRatesMaximized: boolean;\r\n isCompanyCollector: boolean;\r\n breadcrumbs: BreadCrumb[] = [];\r\n // if we find there are more states with tax districts, then we can move this flag to the backend\r\n // but for now, we have been asked to hard-code this to indiana assessors\r\n allowTaxingDistricts: boolean = false;\r\n collector: any;\r\n entityProperties: any;\r\n\r\n private readonly COLLECTOR = 'collector';\r\n private _states: StateSummary[];\r\n private _state: StateSummary;\r\n private _companyName: string;\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(COLLECTOR_HELP);\r\n this.companyId = +this._route.getQuerystringParam('companyID');\r\n this.isCompanyCollector = !!this.companyId;\r\n\r\n if (this.isCompanyCollector) {\r\n const restrictionData = {\r\n roles: null,\r\n instanceRights: [],\r\n explicitInstanceId: null,\r\n isCompany: true,\r\n entityId: this.companyId,\r\n flag: Core.AccessRightsEnum.Write\r\n } as RestrictData;\r\n\r\n const hasPermission = await this._restrictService.hasPermission(restrictionData);\r\n this.viewOnly = !hasPermission;\r\n this._companyName = await this._companyService.getCompanyName(this.companyId);\r\n } else {\r\n this.viewOnly = this._restrictService.isNotInRoles([Roles.COLLECTOREDIT]);\r\n }\r\n\r\n this.entityId = +this._route.getQuerystringParam(this.isCompanyCollector ? 'collectorID' : 'stateCollectorId');\r\n\r\n const [states, collector]: [StateSummary[], any] = await Promise.all([\r\n this._stateService.getSummary(),\r\n this._loadCollector()\r\n ]);\r\n\r\n // states response\r\n this._states = states;\r\n\r\n // assessor-collector response\r\n this.collector = collector;\r\n this._state = this._states.find((state) => {\r\n return state.stateID === this.collector.stateID;\r\n });\r\n this._setBreadcrumbs();\r\n\r\n this.entityProperties = {\r\n id: this.entityId,\r\n type: this.COLLECTOR,\r\n newAllowed: false,\r\n name: this.collector.name\r\n };\r\n }\r\n\r\n toggleTaxRatesMaximize(e: any): void {\r\n this.isTaxRatesMaximized = e as unknown as boolean;\r\n }\r\n\r\n async refreshCollector(): Promise {\r\n this.collector = await this._loadCollector();\r\n }\r\n\r\n private async _loadCollector(): Promise {\r\n const extraParam = this.isCompanyCollector ? `?companyId=${this.companyId}`: null;\r\n\r\n return await this._assessorCollectorService.getUpdatedCollector(this.entityId, extraParam);\r\n }\r\n\r\n private _setBreadcrumbs(): void {\r\n let target: string, options, crumb: BreadCrumb;\r\n if (this.isCompanyCollector) {\r\n target = this._assessorCollectorService.selectedCollectorLetter ? 'companyCollectors.letter' : 'companyCollectors';\r\n options = { companyID: this.companyId, letter: this._assessorCollectorService.selectedCollectorLetter };\r\n crumb = {\r\n name: this._companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n };\r\n } else {\r\n target = this._assessorCollectorService.selectedCollectorLetter ? 'collectors.letter' : 'collectors';\r\n options = { stateId: this._state.stateID, letter: this._assessorCollectorService.selectedCollectorLetter };\r\n crumb = {\r\n name: this._state.fullName,\r\n target: 'state',\r\n options: { stateId: this._state.stateID }\r\n };\r\n }\r\n this.breadcrumbs = [\r\n crumb,\r\n {\r\n name: 'Collectors',\r\n target,\r\n options\r\n },\r\n ];\r\n }\r\n\r\n\r\n}\r\n","import { Component, OnInit, ViewChild, ElementRef, AfterViewInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { Assessor } from '../assessor.model';\r\nimport { AssessorCollectorService } from '../assessor.collector.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { BehaviorSubject } from 'rxjs';\r\n\r\nexport interface AddAssessorParams {\r\n state: Weissman.Model.Misc.State\r\n}\r\n\r\nexport interface AssessorMunicipality {\r\n abbr: string;\r\n efAction: string;\r\n municipalityID: number;\r\n name: string;\r\n}\r\n\r\n@Component({\r\n selector: 'add-assessor-modal',\r\n template: `\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n `,\r\n})\r\nexport class AddAssessorModalComponent implements OnInit, AfterViewInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler\r\n ) { }\r\n\r\n @ViewChild('abbr') abbr: ElementRef;\r\n\r\n params: AddAssessorParams;\r\n result: void;\r\n serverAction: boolean = false;\r\n newAssessor: Assessor;\r\n municipalities: AssessorMunicipality[];\r\n\r\n private _$dataLoaded: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n async ngOnInit() {\r\n this.newAssessor = {\r\n stateID: this.params.state.stateID\r\n } as Assessor;\r\n\r\n this.serverAction = true;\r\n try {\r\n this.municipalities = await this._assessorCollectorService.getAssessorMunicipalities();\r\n this.newAssessor.municipalityID = this.municipalities[0]?.municipalityID;\r\n } finally {\r\n this.serverAction = false;\r\n\r\n if(this.municipalities) {\r\n this._$dataLoaded.next(true);\r\n }\r\n }\r\n }\r\n\r\n ngAfterViewInit() {\r\n this._$dataLoaded.subscribe(isLoaded => {\r\n if(isLoaded) {\r\n this.abbr.nativeElement.focus();\r\n }\r\n });\r\n }\r\n\r\n async save() {\r\n this.serverAction = true;\r\n\r\n try {\r\n const savedAssesor = await this._assessorCollectorService.createAssessor(this.newAssessor);\r\n this._bsModalRef.hide();\r\n this._upgradeNavigationServiceHandler.go('assessor', {stateId: this.params.state.stateID, id: savedAssesor.assessorID});\r\n\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n close() {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { Component, Input, OnInit, ViewChild, AfterViewInit, EventEmitter, Output } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { AnchorSREF } from '../UI-Lib/Directives/Anchor-Route/anchorRoute.directive';\r\nimport { TabsetComponent, TabDirective } from 'ngx-bootstrap/tabs/';\r\n\r\nexport interface ItemsByLetter {\r\n letter: string;\r\n items: {\r\n name: string;\r\n badge?: number;\r\n sref: AnchorSREF\r\n } []\r\n}\r\n\r\n@Component({\r\n selector: 'alphabetized-list',\r\n template: `\r\n \r\n \r\n \r\n \r\n \r\n `,\r\n styles: [`\r\n :host {\r\n display: flex;\r\n justify-content: center;\r\n }\r\n\r\n .list-group {\r\n max-width: 400px;\r\n margin: auto;\r\n margin-top: 20px;\r\n font-size: 150%;\r\n }\r\n\r\n .badge {\r\n font-size: 100%;\r\n }\r\n `]\r\n})\r\nexport class AlphabetizedListComponent implements OnInit, AfterViewInit {\r\n @Input() itemsByLetters: ItemsByLetter[];\r\n @Input() startingLetter: string;\r\n @Output() letterSelected: EventEmitter = new EventEmitter();\r\n @ViewChild('letterTabs', {static: false}) letterTabs: TabsetComponent;\r\n\r\n private readonly _alphabet = '#ABCDEFGHIJKLMNOPQRSTUVWXYZ';\r\n\r\n ngOnInit() {\r\n this.itemsByLetters = _.map(this._alphabet, letter => {\r\n let itemsByLetter = _.find(this.itemsByLetters, {letter});\r\n itemsByLetter = itemsByLetter || { letter, items: [] };\r\n\r\n itemsByLetter.items = _.sortBy(itemsByLetter.items, 'name');\r\n\r\n return itemsByLetter;\r\n });\r\n }\r\n\r\n ngAfterViewInit() {\r\n const tabIndex = this.startingLetter\r\n ? this._alphabet.indexOf(this.startingLetter)\r\n : _.findIndex(this.itemsByLetters, x => x.items.length);\r\n\r\n this.letterTabs.tabs[tabIndex].active = true;\r\n }\r\n\r\n onSelect(data: TabDirective) {\r\n this.letterSelected.emit(data.heading);\r\n }\r\n\r\n}\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BreadCrumb } from '../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { StateService } from '../../Common/States/States.Service';\r\nimport { AssessorCollectorService } from '../assessor.collector.service';\r\nimport { ItemsByLetter } from '../alphabetizedList.component';\r\nimport { Assessor } from '../assessor.model';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { AddAssessorModalComponent, AddAssessorParams } from './addAssessorModal.component';\r\nimport { RestrictService, Roles } from 'src/app/Common/Permissions/restrict.service';\r\n\r\n@Component({\r\n selector: 'assessor-list',\r\n template: `\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n

{{state.fullName}} Assessors

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n `\r\n})\r\nexport class AssessorListComponent implements OnInit {\r\n constructor(private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _stateService: StateService) { }\r\n\r\n state: Weissman.Model.Misc.State;\r\n breadcrumbs: BreadCrumb[] = [];\r\n assessorsByLetters: ItemsByLetter[];\r\n startingLetter: string;\r\n canAdd: boolean = false;\r\n\r\n async ngOnInit() {\r\n this.canAdd = this._restrictService.isInRole(Roles.ASSESSOREDIT);\r\n this.startingLetter = this._upgradeNavigationServiceHandler.getQuerystringParam('letter');\r\n await this._loadData();\r\n }\r\n\r\n onLetterSelected(letter: string): void {\r\n const params = {stateId: this.state.stateID, letter};\r\n this._upgradeNavigationServiceHandler.go('assessors.letter', params);\r\n }\r\n\r\n async launchAddModal(): Promise {\r\n const params: AddAssessorParams = {\r\n state: this.state\r\n };\r\n\r\n await this._modalService.showAsync(AddAssessorModalComponent, params, 'modal-md');\r\n }\r\n\r\n private async _loadData() {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n try {\r\n const stateId = +this._upgradeNavigationServiceHandler.getQuerystringParam('stateId');\r\n this.state = await this._stateService.getById(stateId);\r\n\r\n this.breadcrumbs = [\r\n {\r\n name: 'States',\r\n target: 'states',\r\n options: { }\r\n },\r\n {\r\n name: this.state.fullName,\r\n target: 'state',\r\n options: { stateId: this.state.stateID }\r\n }\r\n ];\r\n\r\n const [assessorList, assessorActiveParcelCounts] = await Promise.all([\r\n this._assessorCollectorService.getAssessorList(stateId),\r\n this._assessorCollectorService.getAssessorActiveParcelCounts(stateId)\r\n ]);\r\n\r\n this.assessorsByLetters = _.chain(assessorList)\r\n .groupBy(x => {\r\n const firstChar = x.abbr.charAt(0);\r\n return isNaN(+firstChar) ? firstChar.toUpperCase() : '#';\r\n })\r\n .map((assessors, letter) => {\r\n const items = _.map(assessors, (x: Assessor) => {\r\n return {\r\n name: `${x.abbr} ${x.municipalityName}`,\r\n badge: _.find(assessorActiveParcelCounts, {assessorID: x.assessorID})?.activeParcelCount,\r\n sref: {target: 'assessor', options: {stateId, id: x.assessorID}}\r\n };\r\n });\r\n\r\n return { letter, items };\r\n })\r\n .sortBy('letter')\r\n .value();\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n}\r\n\r\n","\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AssessorCollectorService } from '../../assessor.collector.service';\r\nimport { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Collector } from '../../collector.model';\r\n\r\nexport interface AddCollectorModalParams {\r\n state: Weissman.Model.Misc.State,\r\n isCompanyCollector: boolean;\r\n companyID: number;\r\n companyName: string;\r\n}\r\n\r\n@Component({\r\n selector: 'add-collector-modal',\r\n templateUrl: './addCollectorModal.component.html'\r\n})\r\nexport class AddCollectorModalComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _toastr: ToastrService\r\n ) {}\r\n\r\n params: AddCollectorModalParams;\r\n result: Collector;\r\n\r\n collectorForm: UntypedFormGroup;\r\n modalTitle: string;\r\n isCompanyCollector: boolean;\r\n\r\n get stateId(): UntypedFormControl {\r\n return this.collectorForm.get('stateID') as UntypedFormControl;\r\n }\r\n\r\n ngOnInit() {\r\n this.isCompanyCollector = this.params.isCompanyCollector || false;\r\n this.modalTitle = `Add ${this.isCompanyCollector ? this.params.companyName : this.params.state.fullName} Collector`;\r\n\r\n this.collectorForm = this._fb.group({\r\n abbr: ['', [Validators.required]],\r\n name: ['', [Validators.required]],\r\n companyID: [(this.isCompanyCollector ? this.params.companyID : null)],\r\n stateID: [(!this.isCompanyCollector ? this.params.state.stateID : null)],\r\n enabled: [true],\r\n isCompanyCollector: this.isCompanyCollector\r\n });\r\n }\r\n\r\n async add(): Promise {\r\n const collector = this.collectorForm.getRawValue();\r\n try {\r\n this.result = await this._assessorCollectorService.createCollector(collector);\r\n this._bsModalRef.hide();\r\n } catch(err) {\r\n this._toastr.error('There was an error creating this collector');\r\n }\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BreadCrumb } from '../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { StateService } from '../../Common/States/States.Service';\r\nimport { AssessorCollectorService } from '../assessor.collector.service';\r\nimport { ItemsByLetter } from '../alphabetizedList.component';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { AddCollectorModalComponent, AddCollectorModalParams } from '../Add/Collector/addCollectorModal.component';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { Collector } from '../collector.model';\r\nimport { CompanyService } from '../../Entity/Company/company.service';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'collector-list',\r\n template: `\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n

{{collectorName}} Collectors

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n `\r\n})\r\nexport class CollectorListComponent implements OnInit {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _stateService: StateService,\r\n private readonly _companyService: CompanyService\r\n ) { }\r\n\r\n collectorName: string;\r\n state: Weissman.Model.Misc.State;\r\n breadcrumbs: BreadCrumb[] = [];\r\n collectorsByLetters: ItemsByLetter[];\r\n companyId: number;\r\n stateId: number;\r\n isCompanyCollector: boolean;\r\n startingLetter: string;\r\n viewOnly: boolean;\r\n initialized: boolean;\r\n\r\n async ngOnInit(): Promise {\r\n\r\n this.startingLetter = this._upgradeNavigationServiceHandler.getQuerystringParam('letter');\r\n this.companyId = +this._upgradeNavigationServiceHandler.getQuerystringParam('companyID');\r\n\r\n if (this.companyId) {\r\n this.isCompanyCollector = !!this.companyId;\r\n } else {\r\n this.stateId = +this._upgradeNavigationServiceHandler.getQuerystringParam('stateId');\r\n }\r\n\r\n this.viewOnly = this._restrictService.isNotInRoles([Roles.COLLECTOREDIT]) && !this.isCompanyCollector;\r\n\r\n await this._loadData();\r\n }\r\n\r\n onLetterSelected(letter: string): void {\r\n this._assessorCollectorService.selectedCollectorLetter = letter;\r\n if (this.isCompanyCollector) {\r\n const params = { companyID: this.companyId, letter };\r\n this._upgradeNavigationServiceHandler.go('companyCollectors.letter', params);\r\n } else {\r\n const params = { stateId: this.state.stateID, letter };\r\n this._upgradeNavigationServiceHandler.go('collectors.letter', params);\r\n }\r\n }\r\n\r\n async launchAddModal(): Promise {\r\n const params: AddCollectorModalParams = {\r\n state: this.state,\r\n companyID: this.companyId,\r\n companyName: this.collectorName,\r\n isCompanyCollector: this.isCompanyCollector\r\n };\r\n\r\n const result = await this._modalService.showAsync(AddCollectorModalComponent, params, 'modal-md');\r\n\r\n if (result) {\r\n let target, options;\r\n if (this.isCompanyCollector) {\r\n target = 'companyCollector';\r\n options = { companyID: this.companyId, collectorID: result.collectorID };\r\n } else {\r\n target = 'collector';\r\n options = { stateId: this.stateId, stateCollectorId: result.collectorID };\r\n }\r\n this._upgradeNavigationServiceHandler.go(target, options);\r\n }\r\n }\r\n\r\n private async _loadData(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n try {\r\n let collectorList: Collector[];\r\n this.breadcrumbs = [\r\n {\r\n name: 'States',\r\n target: 'states',\r\n options: { }\r\n },\r\n ];\r\n\r\n if (this.isCompanyCollector) {\r\n const companyName = await this._companyService.getCompanyName(this.companyId);\r\n this.collectorName = companyName;\r\n\r\n this.breadcrumbs.push({\r\n name: companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n });\r\n\r\n collectorList = await this._assessorCollectorService.getCompanyCollectorList(this.companyId);\r\n } else {\r\n this.state = await this._stateService.getById(this.stateId);\r\n this.collectorName = this.state.fullName;\r\n\r\n this.breadcrumbs.push({\r\n name: this.state.fullName,\r\n target: 'state',\r\n options: { stateId: this.state.stateID }\r\n });\r\n\r\n collectorList = await this._assessorCollectorService.getStateCollectorList(this.stateId);\r\n }\r\n\r\n this.collectorsByLetters = _.chain(collectorList)\r\n .groupBy(x => {\r\n const firstChar = x.abbr.charAt(0);\r\n return isNaN(+firstChar) ? firstChar.toUpperCase() : '#';\r\n })\r\n .map((collectors, letter) => {\r\n const items = _.map(collectors, (x: Collector) => {\r\n let sref;\r\n if (this.isCompanyCollector) {\r\n sref = { target: 'companyCollector', options: { companyID: this.companyId, collectorID: x.collectorID }};\r\n } else {\r\n sref = { target: 'collector', options: { stateId: this.stateId, stateCollectorId: x.collectorID }};\r\n }\r\n return {\r\n name: x.abbr,\r\n sref\r\n };\r\n });\r\n\r\n return { letter, items };\r\n })\r\n .sortBy('letter')\r\n .value();\r\n\r\n } finally {\r\n this.initialized = true;\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n}\r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { AssessorCommandCenterRepository } from '../Repositories';\r\nimport { BehaviorSubject, lastValueFrom, Observable, Subject } from 'rxjs';\r\nimport { HttpResponse } from '@angular/common/http';\r\n\r\ndeclare var moment: any;\r\n\r\nexport enum GridSourceOptionEnum {\r\n Assessor\r\n};\r\n\r\nexport interface FilterTimeFrame {\r\n date: Date;\r\n direction: string;\r\n}\r\n\r\nexport interface FilterVerification {\r\n field: string;\r\n value: string;\r\n property: Compliance.AssessorCommandCenterModelPropertyEnum;\r\n}\r\n\r\nexport interface FilterModel {\r\n recentChanges: FilterTimeFrame;\r\n verification: FilterVerification;\r\n}\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class StateJurisdictionCommandCenterService {\r\n constructor(private readonly _assessorRepo: AssessorCommandCenterRepository) { }\r\n\r\n private readonly _GRID_SOURCE_OPTION_ASSESSOR: Compliance.NameValuePair = {\r\n name: 'Assessors',\r\n value: GridSourceOptionEnum.Assessor\r\n };\r\n private _gridSourceOptions: Compliance.NameValuePair[] = [\r\n this._GRID_SOURCE_OPTION_ASSESSOR\r\n ];\r\n\r\n private _highlightDates: Compliance.NameValuePair[] = [\r\n { name: 'More than 12 months ago', value: { date: this._getDate(12, 0), direction: 'gt' } },\r\n { name: 'More than 6 months ago', value: { date: this._getDate(6, 0), direction: 'gt' } },\r\n { name: 'More than 30 days ago', value: { date: this._getDate(0, 30), direction: 'gt' } },\r\n { name: 'More than 7 days ago', value: { date: this._getDate(0, 7), direction: 'gt' } },\r\n { name: 'Within the last 7 days', value: { date: this._getDate(0, 7), direction: 'lt' } },\r\n { name: 'Within the last 30 days', value: { date: this._getDate(0,30), direction: 'lt' } },\r\n { name: 'Within the last 6 months', value: { date: this._getDate(6, 0), direction: 'lt' } },\r\n { name: 'Within the last year', value: { date: this._getDate(12, 0), direction: 'lt' } }\r\n ];\r\n\r\n private _verificationOptions: Compliance.NameValuePair[] = [\r\n {\r\n name: 'Pending QC', value: {\r\n field: 'isPendingQC',\r\n value: 'true',\r\n property: Compliance.AssessorCommandCenterModelPropertyEnum.IsPendingQC\r\n }\r\n }\r\n ];\r\n\r\n private _currentFilterModel: FilterVerification;\r\n private _highlightChanges: FilterTimeFrame;\r\n private _states: Core.StateModel[];\r\n private _descriptorInfo: Core.DescriptorMetadataModel;\r\n\r\n private _selectedGridSourceOptionSubject: BehaviorSubject> = new BehaviorSubject(this._GRID_SOURCE_OPTION_ASSESSOR);\r\n private _currentSearchModelSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _currentFilterModelSubject: Subject = new Subject();\r\n private _highlightChangesSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _updatingValueSubject: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n selectedGridSourceOption$: Observable> = this._selectedGridSourceOptionSubject.asObservable();\r\n currentSearchModel$: Observable = this._currentSearchModelSubject.asObservable();\r\n currentFilterModel$: Observable = this._currentFilterModelSubject.asObservable();\r\n highlightChanges$: Observable = this._highlightChangesSubject.asObservable();\r\n updatingValue$: Observable = this._updatingValueSubject.asObservable();\r\n\r\n get editGroup(): string {\r\n return 'state-jurisdiction-edit-group';\r\n }\r\n\r\n get currentSearchModel(): Compliance.AssessorCommandCenterSearchModel {\r\n return this._currentSearchModelSubject.value;\r\n }\r\n\r\n get currentFilterModel(): FilterVerification {\r\n return this._currentFilterModel;\r\n }\r\n\r\n get highlightChangesModel(): FilterTimeFrame {\r\n return this._highlightChanges;\r\n }\r\n\r\n get highlightDates(): Compliance.NameValuePair[] {\r\n return this._highlightDates;\r\n }\r\n\r\n get verificationOptions(): Compliance.NameValuePair[] {\r\n return this._verificationOptions;\r\n }\r\n\r\n get gridSourceOptions(): Compliance.NameValuePair[] {\r\n return this._gridSourceOptions;\r\n }\r\n\r\n get canGetRows(): boolean {\r\n const model = this.currentSearchModel;\r\n return !!(model && (model.stateId >= 0 || model.stateId === null) && model.taxYear);\r\n }\r\n\r\n get states(): Core.StateModel[] {\r\n return this._states;\r\n }\r\n\r\n get descriptorInfo(): Core.DescriptorMetadataModel {\r\n return this._descriptorInfo;\r\n }\r\n\r\n async start(): Promise {\r\n this._descriptorInfo = await lastValueFrom(this._assessorRepo.getDescriptorInfo());\r\n this._states = await lastValueFrom(this._assessorRepo.getStates());\r\n }\r\n\r\n setSelectedGridSourceOption(gso: Compliance.NameValuePair): void {\r\n this._selectedGridSourceOptionSubject.next(gso);\r\n }\r\n\r\n async updateDeadline(updateModel: Compliance.AssessorCommandCenterDeadlineUpdateModel): Promise {\r\n return await lastValueFrom(this._assessorRepo.updateDeadline(updateModel));\r\n }\r\n\r\n async updateDescriptor(updateModel: Compliance.AssessorCommandCenterDescriptorUpdateModel): Promise {\r\n return await lastValueFrom(this._assessorRepo.updateDescriptor(updateModel));\r\n }\r\n\r\n async updateDefaultAddressType(updateModel: Compliance.AssessorCommandCenterDefaultAddressUpdateModel): Promise {\r\n return await lastValueFrom(this._assessorRepo.updateDefaultAddressType(updateModel));\r\n }\r\n\r\n async getAssessors(searchModel: Compliance.AssessorCommandCenterSearchModel): Promise> {\r\n return await lastValueFrom(this._assessorRepo.getList(searchModel));\r\n }\r\n\r\n async exportList(model: Compliance.AssessorCommandCenterExportModel): Promise {\r\n return await lastValueFrom(this._assessorRepo.exportList(model));\r\n }\r\n\r\n async getList(longRunningProcessId: number): Promise> {\r\n return await lastValueFrom(this._assessorRepo.getExport(longRunningProcessId));\r\n }\r\n\r\n async getRowIds(searchModel: any): Promise> {\r\n return await lastValueFrom(this._assessorRepo.getRowIds(searchModel));\r\n }\r\n\r\n async bulkUpdateList(updateModel: Compliance.AssessorCommandCenterBulkUpdateModel): Promise {\r\n return await lastValueFrom(this._assessorRepo.bulkUpdateList(updateModel));\r\n }\r\n\r\n formChanged(searchModel: Compliance.AssessorCommandCenterSearchModel): void {\r\n this._currentSearchModelSubject.next(searchModel);\r\n }\r\n\r\n filtersChanged(value: FilterVerification): void {\r\n this._currentFilterModel = value;\r\n this._currentFilterModelSubject.next(value);\r\n }\r\n\r\n highlightChanged(value: FilterTimeFrame): void {\r\n this._highlightChanges = value;\r\n this._highlightChangesSubject.next(value);\r\n }\r\n\r\n loading(loading: boolean): void {\r\n this._updatingValueSubject.next(loading);\r\n }\r\n\r\n private _getDate(months: number, days: number): Date {\r\n const d = new Date();\r\n d.setMonth(d.getMonth() - months);\r\n d.setDate(d.getDate() - days);\r\n return moment.tz({ y: d.getFullYear(), M: d.getMonth(), d: d.getDate(), h: 0, m: 0 }, 'UTC')\r\n .toDate();\r\n }\r\n}\r\n","\r\n\r\n

Reassign CSRs

\r\n
You have selected {{params.csrs.length}} responsibilites to change. Select the responsible person below
\r\n
\r\n\r\n \r\n
\r\n \r\n
\r\n\r\n\t\r\n
\r\n \r\n
\r\n\r\n \r\n\t
\r\n\t\t\r\n \r\n\t\t
1\" class=\"consultant-selector\">\r\n\t\t\t\r\n\t\t
\r\n\t
\r\n\r\n \r\n
\r\n \r\n
\r\n\r\n \r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { Constants, EntityType } from '../../../constants.new';\r\nimport { InstanceRepository } from '../../../Entity/Instance/instance.repository';\r\nimport { UserInstanceService } from '../../../User/userInstance.service';\r\nimport { ConsultingEngagementsRepository } from '../../../Consulting/consultingEngagements.repository';\r\nimport * as _ from 'lodash';\r\nimport { BulkUpdateCsrIdentifier, BulkUpdateParams } from '../csrCommandCenter.component';\r\nimport { BulkSaveExceptionResult, EntityResponsibilityAssignmentChange } from '../../Exceptions/client-service-exception.models';\r\nimport { ClientServicesExceptionService } from '../../Exceptions/client-services-exception.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\n@Component({\r\n selector: 'csr-bulk-update-modal',\r\n templateUrl: './csrBulkUpdate.component.html'\r\n})\r\nexport class CsrBulkUpdateComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private constants: Constants,\r\n private instanceRepository: InstanceRepository,\r\n private userInstanceService : UserInstanceService,\r\n private consultingEngagementsRepository: ConsultingEngagementsRepository,\r\n private clientServicesExceptionService: ClientServicesExceptionService,\r\n private toastr: ToastrService,\r\n ) { }\r\n\r\n result: boolean = false;\r\n workflowUserTypes: any[];\r\n WorkflowUserTypes = this.constants.WorkflowUserTypes;\r\n updateUser: Core.UserTeamModel;\r\n updateWorkflowType: number;\r\n\r\n enableSaveButton: boolean = false;\r\n selectedCount: number = 0;\r\n isLoading: boolean = true;\r\n instanceId: number;\r\n includeAll: boolean = false;\r\n showDatePicker: boolean = false;\r\n setDateFrom: Date;\r\n showPopover: boolean = false;\r\n isRyanInstance: boolean = false;\r\n\r\n isCurrentInstanceRyan: boolean = false;\r\n consultingEngagements: Core.ConsultingEngagementResponse[] = [];\r\n selectedConsultingEngagementId: number = null;\r\n consultantsInstanceId: number = null;\r\n isConsultantPerspective = false;\r\n\r\n params: BulkUpdateParams;\r\n\r\n isSaving: boolean = false;\r\n\r\n get isFormValid(): boolean {\r\n if (this.updateWorkflowType === undefined) {\r\n return false;\r\n }\r\n if (this.updateWorkflowType == this.WorkflowUserTypes['USER'].id && !this.updateUser) {\r\n return false;\r\n }\r\n if (this.showDatePicker && !this.setDateFrom) {\r\n return false;\r\n }\r\n return true;\r\n }\r\n\r\n\r\n ngOnInit(): void {\r\n this.workflowUserTypes = _.toArray(this.constants.WorkflowUserTypes);\r\n this.isRyanInstance = this.userInstanceService.isCurrentInstanceRyan();\r\n\r\n Promise.all([\r\n //consulting engagements for entity\r\n this.loadConsultingEngagements(),\r\n this.setEntityInstanceId()\r\n ]).then(() => {\r\n this.isLoading = false;\r\n this.isConsultantPerspective = this.userInstanceService.isCrossInstancePerspective(this.instanceId);\r\n });\r\n }\r\n\r\n isConsultingClient():boolean {\r\n return this.consultingEngagements.length && this.instanceId && !this.userInstanceService.isInstanceImplicit(this.instanceId);\r\n }\r\n\r\n //consultants are defined by implicit instance membership\r\n shouldUseConsultingEngagementInstanceId():boolean {\r\n return this.userInstanceService.isInstanceImplicit(this.instanceId);\r\n }\r\n\r\n setUser($event: any): void {\r\n this.determineShowDatepicker();\r\n this.updateUser = $event;\r\n }\r\n\r\n assignUserValue(): void {\r\n this.updateWorkflowType = this.WorkflowUserTypes['USER'].id;\r\n }\r\n\r\n cancel(): void {\r\n this.result = false;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save(): Promise {\r\n this.isSaving = true;\r\n\r\n const updatedResponsibilities: EntityResponsibilityAssignmentChange[] = new Array();\r\n\r\n const dateToSave = this.showDatePicker ? this.setDateFrom : null;\r\n\r\n const assignee = this.updateWorkflowType === this.WorkflowUserTypes['USER'].id ? this.updateUser : null;\r\n\r\n //if consultant selects account handler then need to set workflow user type to Consultant, otherwise leave it alone\r\n const workflowUserType = this.isConsultantPerspective && this.updateWorkflowType === this.WorkflowUserTypes['ACCOUNTHANDLER'].id ? this.WorkflowUserTypes['CONSULTANT'].id : this.updateWorkflowType;\r\n\r\n if (this.consultingEngagements.length === 1 && (workflowUserType === this.WorkflowUserTypes['CONSULTANT'].id || this.isConsultantPerspective)) {\r\n this.selectedConsultingEngagementId = this.consultingEngagements[0].consultingEngagementId;\r\n }\r\n\r\n _.forEach(this.params.csrs, (resp: BulkUpdateCsrIdentifier) => {\r\n const changeData = new EntityResponsibilityAssignmentChange(\r\n resp.entityId,\r\n resp.entityTypeId,\r\n resp.clientServiceId,\r\n resp.propertyTypeId,\r\n workflowUserType,\r\n dateToSave,\r\n assignee,\r\n this.selectedConsultingEngagementId);\r\n\r\n updatedResponsibilities.push(changeData);\r\n });\r\n\r\n this.isLoading = true;\r\n this.clientServicesExceptionService.saveClientServiceExceptions(updatedResponsibilities).then((response) => {\r\n const areNotAuthorized = (x: BulkSaveExceptionResult) => !x.isAuthorized;\r\n const haveErrors = (x: BulkSaveExceptionResult) => !!x.errorMessage;\r\n const result = response.results;\r\n\r\n this.isSaving = false;\r\n if (result.length && _.every(result, areNotAuthorized)) {\r\n this.toastr.error('You are not authorized to perform this operation');\r\n }\r\n else if (result.length && _.some(result, areNotAuthorized)) {\r\n this.toastr.error('Some exceptions could not be saved because you are not authorized to perform this operation');\r\n }\r\n\r\n if (result.length && _.every(result, haveErrors)) {\r\n this.toastr.error('There was an unexpected error processing your request');\r\n }\r\n else if (result.length && _.some(result, haveErrors)) {\r\n this.toastr.error('Some exceptions could not be saved because there was an error processing your request');\r\n }\r\n else if (response.longRunningProcessId) {\r\n this.params.longRunningProcessId = response.longRunningProcessId;\r\n this.toastr.success('You requested a large number of updates. They are being run in the background, and you\\'ll be notified when they are done');\r\n }\r\n else {\r\n this.toastr.success('Responsibilties assigned successfully');\r\n this.result = true;\r\n }\r\n this.isLoading = false;\r\n this.isSaving = false;\r\n this._bsModalRef.hide();\r\n }).catch(() => {\r\n this.isSaving = false;\r\n this.isLoading = false;\r\n });\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n\r\n determineShowDatepicker(): void {\r\n\r\n this.isSaving = false;\r\n\r\n //Because of the inifinite scroll nature of the grid, we can't determine whether or not it needs to be shown. So always show it if assigning to anything other than n/a\r\n this.showDatePicker = this.updateWorkflowType !== this.WorkflowUserTypes['NA'].id;\r\n\r\n }\r\n\r\n changeConsultingEngagement(eventTarget: EventTarget) {\r\n this.selectedConsultingEngagementId = Number((eventTarget as HTMLInputElement).value);\r\n }\r\n\r\n private async setEntityInstanceId() {\r\n //entity instance id\r\n await lastValueFrom(this.instanceRepository.getEntityInstanceId(EntityType[this.params.entityTypeId], this.params.entityId)).then(i => {\r\n this.instanceId = i;\r\n if (i === 1) {\r\n this.isRyanInstance = true;\r\n }\r\n });\r\n }\r\n\r\n private async loadConsultingEngagements() {\r\n this.consultingEngagements = await this.consultingEngagementsRepository.getAcceptedEngagements(EntityType.Company, this.params.topLevelCompanyId);\r\n }\r\n\r\n}\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { CsrCommandCenterService } from './csrCommandCenter.service';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../Compliance/AgGrid';\r\nimport { has } from 'lodash';\r\n\r\nexport interface CsrListDataSourceParams {\r\n exceptionsOnly: boolean;\r\n clientServiceIds: number[];\r\n entityFilters: Weissman.Model.Reports.EntityFilter[];\r\n sitePropCharFilters: Weissman.Model.NameValuePair[];\r\n parcelPropCharFilters: Weissman.Model.NameValuePair[];\r\n propertyTypeIds: number[];\r\n rootEntityId: number;\r\n rootEntityType: Core.EntityTypes;\r\n sourceEntityIDs: number[];\r\n sourceEntityIsTopLevelCompany: boolean;\r\n sourceEntityTypeID: number;\r\n excludeInactiveCompanies: boolean;\r\n}\r\n\r\nexport class CsrListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _csrCommandCenterService: CsrCommandCenterService,\r\n protected _dataSourceParamsFn: () => CsrListDataSourceParams,\r\n ) { super(_gridApi); }\r\n\r\n public descriptorIds: number[] = [];\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'clientServiceName', value: Core.ClientServiceResponsibilityCommandCenterPropertyEnum.ClientServiceName },\r\n { name: 'companyName', value: Core.ClientServiceResponsibilityCommandCenterPropertyEnum.CompanyName },\r\n { name: 'companyCode', value: Core.ClientServiceResponsibilityCommandCenterPropertyEnum.CompanyCode },\r\n { name: 'parcelAccountNumber', value: Core.ClientServiceResponsibilityCommandCenterPropertyEnum.ParcelAccountNumber },\r\n { name: 'propertyTypeName', value: Core.ClientServiceResponsibilityCommandCenterPropertyEnum.PropertyTypeName },\r\n { name: 'responsibility', value: Core.ClientServiceResponsibilityCommandCenterPropertyEnum.Responsibility },\r\n { name: 'siteName', value: Core.ClientServiceResponsibilityCommandCenterPropertyEnum.SiteName },\r\n { name: 'siteNumber', value: Core.ClientServiceResponsibilityCommandCenterPropertyEnum.SiteNumber },\r\n { name: 'state', value: Core.ClientServiceResponsibilityCommandCenterPropertyEnum.State },\r\n { name: 'topLevelCompanyName', value: Core.ClientServiceResponsibilityCommandCenterPropertyEnum.TopLevelCompanyName },\r\n ];\r\n\r\n private readonly _filterSortMap: Map = new Map([\r\n [Core.DescriptorFieldTypes.Number, Compliance.AssessorCommandCenterModelPropertyEnum.NumberDescriptor],\r\n [Core.DescriptorFieldTypes.Currency, Compliance.AssessorCommandCenterModelPropertyEnum.NumberDescriptor],\r\n [Core.DescriptorFieldTypes.Date, Compliance.AssessorCommandCenterModelPropertyEnum.DateDescriptor],\r\n [Core.DescriptorFieldTypes.YesNo, Compliance.AssessorCommandCenterModelPropertyEnum.BooleanDescriptor],\r\n [Core.DescriptorFieldTypes.Picklist, Compliance.AssessorCommandCenterModelPropertyEnum.StringDescriptor],\r\n [Core.DescriptorFieldTypes.Text, Compliance.AssessorCommandCenterModelPropertyEnum.StringDescriptor]\r\n ]);\r\n\r\n getSearchParamsWithoutPagination() : Core.ClientServiceResponsibilityCommandCenterSearchModel{\r\n this.refreshDataSourceParams();\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n rootEntityId: this._dataSourceParams.rootEntityId,\r\n rootEntityType: this._dataSourceParams.rootEntityType,\r\n clientServiceIds: this._dataSourceParams.clientServiceIds,\r\n propertyTypeIds: this._dataSourceParams.propertyTypeIds,\r\n exceptionsOnly: this._dataSourceParams.exceptionsOnly,\r\n entityFilters: this._dataSourceParams.entityFilters,\r\n sitePropCharFilters: this._dataSourceParams.sitePropCharFilters,\r\n parcelPropCharFilters: this._dataSourceParams.parcelPropCharFilters,\r\n sourceEntityIDs: this._dataSourceParams.sourceEntityIDs,\r\n sourceEntityIsTopLevelCompany: this._dataSourceParams.sourceEntityIsTopLevelCompany,\r\n sourceEntityTypeID: this._dataSourceParams.sourceEntityTypeID,\r\n descriptorIds: this.descriptorIds,\r\n includeInactive: !this._dataSourceParams.excludeInactiveCompanies,\r\n };\r\n }\r\n\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.ClientServiceResponsibilityCommandCenterSearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n rootEntityId: this._dataSourceParams.rootEntityId,\r\n rootEntityType: this._dataSourceParams.rootEntityType,\r\n clientServiceIds: this._dataSourceParams.clientServiceIds,\r\n propertyTypeIds: this._dataSourceParams.propertyTypeIds,\r\n exceptionsOnly: this._dataSourceParams.exceptionsOnly,\r\n entityFilters: this._dataSourceParams.entityFilters,\r\n sitePropCharFilters: this._dataSourceParams.sitePropCharFilters,\r\n parcelPropCharFilters: this._dataSourceParams.parcelPropCharFilters,\r\n sourceEntityIDs: this._dataSourceParams.sourceEntityIDs,\r\n sourceEntityIsTopLevelCompany: this._dataSourceParams.sourceEntityIsTopLevelCompany,\r\n sourceEntityTypeID: this._dataSourceParams.sourceEntityTypeID,\r\n descriptorIds: this.descriptorIds,\r\n includeInactive: !this._dataSourceParams.excludeInactiveCompanies,\r\n };\r\n\r\n return await this._csrCommandCenterService.searchRowIds(searchParams);\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected getSortColumns(propertyMap: Compliance.NameValuePair[]): Core.SortModel[] {\r\n const columns: Core.SortModel[] = [];\r\n\r\n const sortModel = this.gridApi.getSortModel();\r\n\r\n if (sortModel) {\r\n sortModel.forEach(x => {\r\n const property = this.getProperty(x.colId, propertyMap);\r\n if (property !== null) {\r\n columns.push({\r\n sortProperty: property,\r\n sortDirection: this.getSortDirection(x.sort)\r\n });\r\n }\r\n });\r\n }\r\n\r\n return columns;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const result = await this._csrCommandCenterService.search(searchParams);\r\n const dataSourceResult: AgGridDataSourceResult = {\r\n rows: result.data,\r\n totalRows: result.totalRows,\r\n lastModifiedTimestamp: result.lastModifiedTimestamp\r\n };\r\n\r\n return dataSourceResult;\r\n }\r\n\r\n protected getColumnFilters(propertyMap: Compliance.NameValuePair[]): Core.FilterModel[] {\r\n const columns: Core.FilterModel[] = [];\r\n const filterModel = this.gridApi.getFilterModel();\r\n\r\n if (filterModel) {\r\n for (const prop in filterModel) {\r\n if (has(filterModel, prop)) {\r\n const property = this.getProperty(prop, propertyMap);\r\n if (property !== null) {\r\n columns.push({\r\n filterProperty: property,\r\n filterConditionType: filterModel[prop] && filterModel[prop].filterConditionType,\r\n filterValues: filterModel[prop] && filterModel[prop].filterValues.map(x => {\r\n return {\r\n filterType: this.getFilterType(x.filterType.displayKey),\r\n filterValue: this.getFilterValue(x),\r\n filterToValue: this.getFilterType(x.filterType.displayKey) === Core.FilterTypeEnum.InRange ? x.filterToValue : null\r\n };\r\n })\r\n });\r\n } else {\r\n const descriptor = this._csrCommandCenterService.entityCharacteristics.descriptors.find(d => `d.${d.descriptorId}` === prop);\r\n if (descriptor) {\r\n columns.push({\r\n filterProperty: this._filterSortMap.get(descriptor.fieldType),\r\n filterConditionType: filterModel[prop] && filterModel[prop].filterConditionType,\r\n filterValues: filterModel[prop] && filterModel[prop].filterValues.map(x => {\r\n return {\r\n filterParameter: prop.split('.')[1],\r\n filterType: this.getFilterType(x.filterType.displayKey),\r\n filterValue: this.getFilterValue(x),\r\n filterToValue: this.getFilterType(x.filterType.displayKey) === Core.FilterTypeEnum.InRange ? x.filterToValue : null\r\n };\r\n })\r\n });\r\n }\r\n }\r\n }\r\n }\r\n }\r\n return columns;\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const CSR_COMMAND_CENTER_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'ag-grid-tool-panel.show-configure',\r\n tooltipText: 'Configure layout'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.hide-configure',\r\n tooltipText: 'Hide configure layout'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.show-filters',\r\n tooltipText: 'Show filters'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.hide-filters',\r\n tooltipText: 'Hide filters'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.export',\r\n tooltipText: 'Export data'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.export-tab-delimited',\r\n tooltipText: 'Export data to tab-delimited format which does not have formatting but exports faster'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.export-excel',\r\n tooltipText: 'Export data to Excel'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.size-to-fit',\r\n tooltipText: 'Size columns to fit the available space'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.size-to-content',\r\n tooltipText: 'Size columns to fit cell contents'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.bulk-update',\r\n tooltipText: 'Bulk assign selected rows'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.bulk-delete',\r\n tooltipText: 'Remove selected exceptions'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.clearFiltersHelpContentId',\r\n tooltipText: 'Clear filters'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.pinColumn',\r\n tooltipText: 'Pin column left'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.additional-actions',\r\n tooltipText: 'Additional actions are available'\r\n }\r\n];\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams, IAfterGuiAttachedParams } from 'ag-grid-community';\r\n\r\nexport interface ICsrUpdateStatusCellRendererParams extends ICellRendererParams{\r\n retryAction: (ICellRendererParams)=>Promise\r\n}\r\n\r\n@Component({\r\n selector: 'grid-csr-update-status-cell',\r\n template:\r\n `\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n `\r\n})\r\nexport class CsrUpdateStatusCellRendererComponent implements ICellRendererAngularComp {\r\n csrUpdateStatus: number;\r\n params: ICellRendererParams;\r\n retryAction: (ICellRendererParams)=>Promise;\r\n\r\n refresh(params: any): boolean {\r\n return false;\r\n }\r\n agInit(params: ICsrUpdateStatusCellRendererParams): void {\r\n this.csrUpdateStatus = params?.data?.csrUpdateStatus;\r\n this.params = params;\r\n this.retryAction = params.retryAction as (ICellRendererParams)=>Promise;\r\n }\r\n afterGuiAttached?(params?: IAfterGuiAttachedParams): void {\r\n return null;\r\n }\r\n async retryResponsiblityUpdate() {\r\n await this.retryAction(this.params);\r\n this.csrUpdateStatus = null;\r\n }\r\n}\r\n","import { HttpClient, HttpResponse} from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { EntityTypeIds } from '../../constants.new';\r\nimport { CsrCommandCenterRepository } from './csrCommandCenter.repository';\r\n\r\n@Injectable()\r\nexport class CsrCommandCenterService {\r\n constructor(private readonly _http: HttpClient, private readonly csrRepo : CsrCommandCenterRepository) {}\r\n\r\n entityCharacteristics: Core.ClientServiceResponsibilityCommandCenterDescriptorInfoModel = null;\r\n\r\n private readonly _baseUrl = 'api/clientserviceresponsibility/cc/';\r\n\r\n search(groupSearchModel: Core.ClientServiceResponsibilityCommandCenterSearchModel): Promise> {\r\n return lastValueFrom(this._http.post(`${this._baseUrl}search/`, groupSearchModel)) as Promise>;\r\n }\r\n\r\n searchRowIds(groupSearchModel: Core.ClientServiceResponsibilityCommandCenterSearchModel): Promise> {\r\n return lastValueFrom(this._http.post(`${this._baseUrl}search/rowids`, groupSearchModel)) as Promise>;\r\n }\r\n\r\n removeExceptions(model: Core.ClientServiceExceptionRemoveRequest): Promise {\r\n return lastValueFrom(this._http.put(`${this._baseUrl}exception/remove`, model)) as Promise;\r\n }\r\n\r\n async exportList(exportModel: Core.ClientServiceResponsibilityCommandCenterExportModel): Promise {\r\n return await lastValueFrom(this.csrRepo.exportList(exportModel));\r\n }\r\n\r\n async getExport(companyId:number, longRunningProcessId: number): Promise> {\r\n return await lastValueFrom(this.csrRepo.getExport(companyId, longRunningProcessId));\r\n }\r\n\r\n async getEntityDescriptors(entityId: number, entityTypeId: EntityTypeIds): Promise {\r\n if(entityTypeId === EntityTypeIds.COMPANY || entityTypeId === EntityTypeIds.SITE || entityTypeId === EntityTypeIds.PARCEL) {\r\n this.entityCharacteristics = await (lastValueFrom(this._http.get(`${this._baseUrl}descriptorInfo/${entityId}/${entityTypeId}`)) as Promise);\r\n return this.entityCharacteristics;\r\n }\r\n else {\r\n throw(entityTypeId);\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../../Common/Routing/sd-http.service';\r\nimport { EntityFilter, EntitySelection, GetEntitiesRequest, GetPropCharValuesRequest, SelectedEntity, GenericEntity, TopLevelCompany } from './report.manager.model';\r\nimport { EntityTypeIds } from '../../constants.new';\r\n\r\ndeclare const _: any;\r\n\r\n@Injectable()\r\nexport class ReportManagerSelectEntitiesService {\r\n\r\n constructor(private http: SDHttpService) {\r\n }\r\n\r\n getTopLevelCompanies(onlyFavorites: boolean, excludeInactive: boolean): Promise {\r\n const onlyFavoritesString: string = onlyFavorites ? 'favorite' : 'all';\r\n\r\n const params: object = {\r\n excludeInactive: excludeInactive\r\n };\r\n\r\n return this.http.get(`/api/company/topcompanies/${ onlyFavoritesString}`, {params: params});\r\n }\r\n\r\n getEntitiesFromParent(payload): Promise {\r\n return this.http.post('/api/reportmanager/entities', payload);\r\n }\r\n\r\n getUsersWithAccessToCertainCompanies(payload, includeInternalUsers: boolean): Promise {\r\n payload.includeInternalUsers = includeInternalUsers || false;\r\n return this.http.post('api/ReportManager/UsersWithAccessToCertainCompanies', payload);\r\n }\r\n\r\n getPropCharsFromParent(type:string, payload): Promise {\r\n return this.http.post(`/api/reportmanager/propchars/${type}`, payload);\r\n }\r\n\r\n getPropCharValues(type:string, payload: GetPropCharValuesRequest): Promise {\r\n return this.http.post(`/api/reportmanager/propchars/${type}/values`, payload);\r\n }\r\n\r\n getClientServices(payload: {sourceEntityIDs: number[], sourceEntityTypeID: number}): Promise {\r\n return this.http.post('/api/clientservice/cs/forentities', payload);\r\n }\r\n\r\n getPropertyTypes(payload: {sourceEntityIDs: number[], sourceEntityTypeID: number}): Promise {\r\n return this.http.post('/api/clientservice/propertytypes/forentities', payload);\r\n }\r\n\r\n getPayloadSourceEntityData(entitySelection: EntitySelection, i?: number, omitForCurrentEntity?: boolean): GetEntitiesRequest {\r\n if (i === undefined) {\r\n i = entitySelection.selectedEntities.length - 1;\r\n }\r\n const nonSourceEntityIDs: number[] = [EntityTypeIds.STATE, EntityTypeIds.ASSESSOR, EntityTypeIds.PROPERTYTYPE, EntityTypeIds.CLIENTSERVICE];\r\n const payload: GetEntitiesRequest = new GetEntitiesRequest();\r\n\r\n const lastSourceEntity: SelectedEntity = _.findLast(entitySelection.selectedEntities, (entity: SelectedEntity, index: number) => {\r\n return index <= i && entity.id != 999 && entity.id != 998 && entity.id != EntityTypeIds.USER && entity.id != EntityTypeIds.CONTACT && !_.includes(nonSourceEntityIDs, entity.id) && entity.selectedIDs.length;\r\n }) as SelectedEntity;\r\n\r\n if (lastSourceEntity) {\r\n payload.sourceEntityIDs = lastSourceEntity.selectedIDs as number[];\r\n payload.sourceEntityTypeID = lastSourceEntity.id;\r\n payload.sourceEntityIsTopLevelCompany = false;\r\n } else {\r\n payload.sourceEntityIDs = entitySelection.selectedTopLevelCompanyIDs,\r\n payload.sourceEntityTypeID = 1;\r\n payload.sourceEntityIsTopLevelCompany = true;\r\n }\r\n\r\n //site property chars filters\r\n const sitePropCharFilters = _.chain(entitySelection.selectedEntities)\r\n .filter((selectedEntity: SelectedEntity, index: number): boolean => {\r\n const isEntityIncluded = omitForCurrentEntity ? index < i : index <= i;\r\n\r\n return (selectedEntity.id === 999) && isEntityIncluded;\r\n })\r\n .map((entity: SelectedEntity) => {\r\n return _.map(entity.selectedPropCharVals, (propChar: string) => {\r\n return {\r\n name: entity.selectedDropdown,\r\n value: propChar\r\n };\r\n });\r\n })\r\n .flatten()\r\n .value() as any[];\r\n\r\n if (sitePropCharFilters.length) {\r\n payload.sitePropCharFilters = sitePropCharFilters;\r\n }\r\n\r\n //parcel property chars filters\r\n const parcelCharFilters = _.chain(entitySelection.selectedEntities)\r\n .filter((selectedEntity: SelectedEntity, index: number): boolean => {\r\n const isEntityIncluded = omitForCurrentEntity ? index < i : index <= i;\r\n\r\n return (selectedEntity.id === 998) && isEntityIncluded;\r\n })\r\n .map((entity: SelectedEntity) => {\r\n return _.map(entity.selectedPropCharVals, (propChar: string) => {\r\n return {\r\n name: entity.selectedDropdown,\r\n value: propChar\r\n };\r\n });\r\n })\r\n .flatten()\r\n .value() as any[];\r\n\r\n if (parcelCharFilters.length) {\r\n payload.parcelPropCharFilters = parcelCharFilters;\r\n }\r\n\r\n //userid filters\r\n const userIdFilters = _.chain(entitySelection.selectedEntities)\r\n .filter((selectedEntity: SelectedEntity, index: number): boolean => {\r\n const isEntityIncluded = omitForCurrentEntity ? index < i : index <= i;\r\n\r\n return selectedEntity.id === EntityTypeIds.USER && isEntityIncluded;\r\n })\r\n .map((entity: SelectedEntity) => entity.selectedIDs)\r\n .flatten()\r\n .value() as string[];\r\n\r\n if (userIdFilters.length) {\r\n payload.userIdFilters = userIdFilters;\r\n }\r\n\r\n //contact filters\r\n const contactIds = _.chain(entitySelection.selectedEntities)\r\n .filter((selectedEntity: SelectedEntity, index: number): boolean => {\r\n const isEntityIncluded = omitForCurrentEntity ? index < i : index <= i;\r\n\r\n return selectedEntity.id === EntityTypeIds.CONTACT && isEntityIncluded;\r\n })\r\n .map((entity: SelectedEntity) => entity.selectedIDs)\r\n .flatten()\r\n .value() as number[];\r\n\r\n if (contactIds.length) {\r\n payload.contactIds = contactIds;\r\n }\r\n\r\n //entity filters\r\n payload.entityFilters = _.chain(entitySelection.selectedEntities)\r\n .filter((entity: SelectedEntity, index: number) => {\r\n return _.includes(nonSourceEntityIDs, entity.id) && index <= i;\r\n })\r\n .map((entity: SelectedEntity) => {\r\n return {\r\n entityTypeID: entity.id,\r\n entityIDs: entity.selectedIDs\r\n };\r\n })\r\n .value() as EntityFilter[];\r\n\r\n payload.excludeInactive = entitySelection.excludeInactive;\r\n\r\n return payload;\r\n }\r\n\r\n getSelectedEntities(): SelectedEntity[] {\r\n const entities: SelectedEntity[] = [\r\n {\r\n name: 'Subsidiary Companies',\r\n buttonName: 'Subsidiaries',\r\n id: EntityTypeIds.COMPANY,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.COMPANY, EntityTypeIds.SITE, EntityTypeIds.STATE, 999, 998, EntityTypeIds.CONTACT],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'Sites',\r\n buttonName: 'Sites',\r\n id: EntityTypeIds.SITE,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.SITE, EntityTypeIds.CONTACT, EntityTypeIds.PARCEL, 998],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'States',\r\n buttonName: 'States',\r\n id: EntityTypeIds.STATE,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.SITE, EntityTypeIds.STATE, EntityTypeIds.CONTACT],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'Assessors',\r\n buttonName: 'Assessors',\r\n id: EntityTypeIds.ASSESSOR,\r\n prerequisites: [EntityTypeIds.STATE],\r\n blockers: [EntityTypeIds.ASSESSOR, EntityTypeIds.SITE, EntityTypeIds.CONTACT],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'Site Characteristic',\r\n buttonName: 'Site Characteristic',\r\n id: 999,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.PARCEL, EntityTypeIds.SITE, EntityTypeIds.CONTACT, 999, 998],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'Parcel Characteristic',\r\n buttonName: 'Parcel Characteristic',\r\n id: 998,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.CONTACT, 998],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'Appeal Responsibility',\r\n buttonName: 'Appeal Responsibility',\r\n id: EntityTypeIds.USER,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.USER, EntityTypeIds.CONTACT],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false,\r\n isAppealResponsibility: true\r\n },\r\n {\r\n name: 'Users',\r\n buttonName: 'Users',\r\n id: EntityTypeIds.CONTACT,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.CONTACT],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'Users',\r\n buttonName: 'Users',\r\n id: EntityTypeIds.USER,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.USER],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'Parcels',\r\n buttonName: 'Parcels',\r\n id: EntityTypeIds.PARCEL,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.PARCEL],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'Responsibilities',\r\n buttonName: 'Client Service',\r\n id: EntityTypeIds.CLIENTSERVICE,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.CLIENTSERVICE, EntityTypeIds.CONTACT],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'Property Type',\r\n buttonName: 'Property Type',\r\n id: EntityTypeIds.PROPERTYTYPE,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.PROPERTYTYPE, EntityTypeIds.CONTACT],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n },\r\n {\r\n name: 'Users',\r\n buttonName: 'Users',\r\n id: EntityTypeIds.SUPPORTUSER,\r\n prerequisites: [],\r\n blockers: [EntityTypeIds.SUPPORTUSER],\r\n list: [],\r\n selectedIDs: [],\r\n selectedPropCharVals: [],\r\n dropdownList: [],\r\n selectedDropdown: '',\r\n loading: false\r\n }\r\n ];\r\n\r\n return entities;\r\n }\r\n\r\n getSupportInstances(): Promise {\r\n return this.http.get('/api/supportInstance/list/');\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

{{headerText}}

\r\n
0\" *ngIf=\"hasInactiveEntities\">\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

Support Instances

\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

Top Level Companies

\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

{{selectedEntity.name}}

\r\n
\r\n \r\n Empty\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n Additional Selections\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n","import {Component, OnInit, Input, Output, EventEmitter} from '@angular/core';\r\nimport {\r\n GetPropCharValuesRequest, TopLevelCompany, SelectedEntity, GenericEntity,\r\n ReportDetail, EntitySelection, GetEntitiesRequest\r\n} from './report.manager.model';\r\nimport { ReportManagerSelectEntitiesService } from './select.entities.service';\r\nimport {InstanceRights, RestrictService} from '../../Common/Permissions/restrict.service';\r\nimport { ReportManagerService } from './report.manager.service';\r\nimport { ReportType } from './report-type';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { EntityTypeIds } from '../../constants.new';\r\nimport { WeissmanDateFormatPipe } from '../../UI-Lib/Pipes';\r\n\r\ndeclare const _: any;\r\n\r\n@Component({\r\n selector: 'report-manager-select-entities',\r\n templateUrl: './select.entities.component.html'\r\n})\r\nexport class ReportManagerSelectEntitiesComponent implements OnInit {\r\n constructor(private selectEntitiesService: ReportManagerSelectEntitiesService,\r\n private restrictService: RestrictService,\r\n private readonly _toastr: ToastrService,\r\n private reportManagerService: ReportManagerService,\r\n private readonly _datePipe: WeissmanDateFormatPipe) {\r\n this.reportFavoriteChange = new EventEmitter();\r\n this.entitySelectionChanged = new EventEmitter();\r\n this.excludeInactiveChanged = new EventEmitter();\r\n }\r\n\r\n @Input() entitySelection: EntitySelection;\r\n @Input() dataLoaded: boolean = true;\r\n @Input() report: ReportDetail;\r\n @Input() hideTopLevelCompanyPicker: boolean = false;\r\n @Input() showSupportInstancePicker: boolean = false;\r\n @Output() reportFavoriteChange: EventEmitter;\r\n @Output() entitySelectionChanged: EventEmitter;\r\n @Output() excludeInactiveChanged: EventEmitter;\r\n\r\n additionalSelections: SelectedEntity[];\r\n loadingTopLevelCompanies: boolean;\r\n hasInstancePrivatePermission: boolean;\r\n reportTypes = ReportType;\r\n topLevelCompanies: TopLevelCompany[];\r\n loadingSupportInstances: boolean;\r\n supportInstances: Core.SupportInstanceInfoModel[];\r\n headerText: string;\r\n hasInactiveEntities: boolean;\r\n showMoreSelections: boolean;\r\n\r\n async ngOnInit() : Promise {\r\n this.headerText = this.report.reportTypeId !== ReportType.SupportInstanceEscalationActivity\r\n ? 'Select Your Companies/Sites/Parcels'\r\n : 'Select Your Companies/Users';\r\n this.hasInactiveEntities = this.report.reportTypeId !== ReportType.SupportInstanceEscalationActivity;\r\n\r\n this.topLevelCompanies = [];\r\n this.supportInstances = [];\r\n this.hasInstancePrivatePermission = this.restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW)\r\n || this.restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT);\r\n\r\n if(!this.hasInstancePrivatePermission) {\r\n this.report.criteria.frequentlyUsed = false;\r\n }\r\n\r\n const initedEntities: SelectedEntity[] = this.selectEntitiesService.getSelectedEntities();\r\n this.entitySelection.selectedEntities = _.map(this.entitySelection.selectedEntities, (selectedEntity) => {\r\n const initedEntity = _.find(initedEntities, x => {\r\n if(selectedEntity.isAppealResponsibility && x.isAppealResponsibility) { // Appeal Responsibiliy and Users (not contacts) have the same ID\r\n return true;\r\n }\r\n\r\n return x.id === selectedEntity.id && !selectedEntity.isAppealResponsibility && !x.isAppealResponsibility;\r\n });\r\n\r\n return _.defaults(selectedEntity, initedEntity);\r\n });\r\n\r\n this.configureAdditionalSelections();\r\n\r\n if (!this.hideTopLevelCompanyPicker) {\r\n await this.getTopLevelCompanies();\r\n }\r\n\r\n if (this.showSupportInstancePicker) {\r\n await this.loadInstances();\r\n await this.maybeGetSubentities(-1);\r\n }\r\n }\r\n\r\n async getTopLevelCompanies(): Promise {\r\n this.loadingTopLevelCompanies = true;\r\n\r\n try {\r\n this.reportFavoriteChange.emit(this.report.criteria.frequentlyUsed);\r\n\r\n const topLevelCompanies = await this.selectEntitiesService.getTopLevelCompanies(this.report.criteria.frequentlyUsed, this.entitySelection.excludeInactive);\r\n this.topLevelCompanies = _.sortBy(topLevelCompanies, item => item.companyName.toLowerCase());\r\n } finally {\r\n this.loadingTopLevelCompanies = false;\r\n }\r\n\r\n const topLevelCompanyIDs: number[] = _.map(this.topLevelCompanies, 'companyID') as number[];\r\n this.entitySelection.selectedTopLevelCompanyIDs = _.intersection(this.entitySelection.selectedTopLevelCompanyIDs, topLevelCompanyIDs) as number[];\r\n this.reportManagerService.topLevelCompanies$.next({\r\n topLevelCompanyIds: this.entitySelection.selectedTopLevelCompanyIDs,\r\n initFromSavedReport: this.report.isOwnedByUser\r\n });\r\n\r\n if (this.topLevelCompanies.length === 0 || this.entitySelection.selectedTopLevelCompanyIDs.length === 0) {\r\n this.removeEmptyEntities(0);\r\n return Promise.resolve();\r\n }\r\n\r\n return this.maybeGetSubentities(-1);\r\n }\r\n\r\n async selectionButtonClicked(entityId: number): Promise {\r\n const targetEntity: SelectedEntity = _.find(this.additionalSelections, { id: entityId });\r\n\r\n targetEntity.loading = true;\r\n\r\n try {\r\n await this.getSelectionData(entityId, targetEntity);\r\n this.configureAdditionalSelections();\r\n } finally {\r\n targetEntity.loading = false;\r\n }\r\n }\r\n\r\n async propCharChanged(entity: SelectedEntity, i: number): Promise {\r\n const payload: GetPropCharValuesRequest = new GetPropCharValuesRequest();\r\n Object.assign(payload, this.selectEntitiesService.getPayloadSourceEntityData(this.entitySelection, i, true));\r\n payload.selectedPropCharName = entity.selectedDropdown;\r\n\r\n entity.loading = true;\r\n\r\n const type = entity.id === 999 ? 'site' : 'parcel';\r\n try {\r\n const propCharValues = await this.selectEntitiesService.getPropCharValues(type, payload);\r\n entity.list = propCharValues\r\n .map((val: any) => {\r\n let tempValue = val;\r\n\r\n if (tempValue instanceof Date && !isNaN(tempValue.getTime())) {\r\n tempValue = this._datePipe.transform(val, true);\r\n }\r\n return {\r\n id: null,\r\n name: tempValue\r\n };\r\n });\r\n entity.list.sort((x, y) => x.name.toLowerCase().localeCompare(y.name.toLowerCase()));\r\n\r\n this.removeEmptyEntities(i);\r\n } finally {\r\n entity.loading = false;\r\n }\r\n }\r\n\r\n selectAllTopLevelCompanies(): void {\r\n this.entitySelection.selectedTopLevelCompanyIDs = _.map(this.topLevelCompanies, 'companyID') as number[];\r\n\r\n this.maybeGetSubentities(-1);\r\n }\r\n\r\n apply(): void {\r\n this.entitySelectionChanged.emit(true);\r\n }\r\n\r\n unselectAllTopLevelCompanies(): void {\r\n this.entitySelection.selectedTopLevelCompanyIDs = [];\r\n\r\n this.maybeGetSubentities(-1);\r\n }\r\n\r\n selectAll(entity: SelectedEntity, i: number): void {\r\n if (entity.id == 999 || entity.id == 998) {\r\n entity.selectedPropCharVals = _.map(entity.list, 'name') as string[];\r\n } else {\r\n entity.selectedIDs = _.map(entity.list, 'id');\r\n }\r\n\r\n this.maybeGetSubentities(i);\r\n }\r\n\r\n unselectAll(entity: SelectedEntity, i: number): void {\r\n if (entity.id == 999 || entity.id == 998) {\r\n entity.selectedPropCharVals = [];\r\n } else {\r\n entity.selectedIDs = [];\r\n }\r\n\r\n this.maybeGetSubentities(i);\r\n }\r\n\r\n areAllSelected(entity: SelectedEntity): boolean {\r\n if (entity.id == 999 || entity.id == 998) {\r\n return entity.selectedPropCharVals.length == entity.list.length;\r\n } else {\r\n return entity.selectedIDs.length == entity.list.length;\r\n }\r\n }\r\n\r\n removeLast(): void {\r\n const last: SelectedEntity = _.last(this.entitySelection.selectedEntities);\r\n if(last && (last.id === 999 || last.id === 998)) {\r\n this.reportManagerService.setNewPropChars([]);\r\n }\r\n\r\n this.entitySelection.selectedEntities.pop();\r\n\r\n this.configureAdditionalSelections();\r\n }\r\n\r\n selectedTopLevelCompaniesChanged(e): void {\r\n if(e.target.selectedOptions.length > 1 && this._reportDisallowsMultipleTLCs()) {\r\n const multiSelect: any = document.getElementById('top-level');\r\n\r\n for (let i = 0; i < multiSelect.options.length; i++) {\r\n if (multiSelect.options[i].value !== this.entitySelection.selectedTopLevelCompanyIDs[0].toString()) {\r\n multiSelect.options[i].selected = false;\r\n }\r\n }\r\n\r\n this._toastr.error('Limit to only one Top Level Company for this report');\r\n\r\n return;\r\n }\r\n\r\n this.entitySelection.selectedTopLevelCompanyIDs = _.map(e.target.selectedOptions, option => Number(option.value)) as number[];\r\n\r\n this.reportManagerService.topLevelCompanies$.next({\r\n topLevelCompanyIds: this.entitySelection.selectedTopLevelCompanyIDs,\r\n initFromSavedReport: false\r\n });\r\n\r\n this.configureAdditionalSelections();\r\n this.maybeGetSubentities(-1);\r\n }\r\n\r\n selectedSubEntitiesChanged(eventTarget: EventTarget, entity: SelectedEntity, i: number): void {\r\n const selectedOptions = (eventTarget as HTMLSelectElement).selectedOptions;\r\n\r\n if (entity.id === 999 || entity.id == 998) {\r\n entity.selectedPropCharVals = _.map(selectedOptions, option => option.value) as string[];\r\n } else {\r\n entity.selectedIDs = _.map(selectedOptions, option => {\r\n return entity.id === EntityTypeIds.USER ? option.value : Number(option.value);\r\n });\r\n }\r\n\r\n this.maybeGetSubentities(i);\r\n }\r\n\r\n showAdditionalSelections(): boolean {\r\n return this.additionalSelections.length &&\r\n (!this.entitySelection.selectedEntities.length || _.last(this.entitySelection.selectedEntities).list.length);\r\n }\r\n\r\n noItemsSelected(): boolean {\r\n if (this.entitySelection.selectedEntities.length) {\r\n const lastEntity: SelectedEntity = _.last(this.entitySelection.selectedEntities);\r\n\r\n return lastEntity.selectedIDs.length == 0 && lastEntity.selectedPropCharVals.length == 0;\r\n } else {\r\n return this.entitySelection.selectedTopLevelCompanyIDs.length == 0 && !this.hideTopLevelCompanyPicker;\r\n }\r\n }\r\n\r\n isAppealResponsibilitySelected() {\r\n return this.entitySelection && _.some(this.entitySelection.selectedEntities, 'isAppealResponsibility');\r\n }\r\n\r\n selectedInstanceChanged(e): void {\r\n this.entitySelection.selectedSupportInstanceIds = _.map(e.target.selectedOptions, option => Number(option.value)) as number[];\r\n }\r\n\r\n async loadInstances(): Promise {\r\n this.loadingSupportInstances = true;\r\n\r\n try {\r\n this.reportFavoriteChange.emit(this.report.criteria.frequentlyUsed);\r\n\r\n const instances = await this.selectEntitiesService.getSupportInstances();\r\n this.supportInstances = _.sortBy(instances, item => item.instanceName.toLowerCase());\r\n } finally {\r\n this.loadingSupportInstances = false;\r\n }\r\n\r\n const instanceIds: number[] = _.map(this.supportInstances, 'instanceId') as number[];\r\n this.entitySelection.selectedSupportInstanceIds = _.intersection(this.entitySelection.selectedSupportInstanceIds, instanceIds) as number[];\r\n }\r\n\r\n selectAllSupportInstances(): void {\r\n this.entitySelection.selectedSupportInstanceIds = _.map(this.supportInstances, 'instanceId') as number[];\r\n }\r\n\r\n unselectAllSupportInstances(): void {\r\n this.entitySelection.selectedSupportInstanceIds = [];\r\n }\r\n\r\n //\r\n // Private Helper Functions\r\n //\r\n\r\n private async maybeGetSubentities(i: number): Promise {\r\n if (i === (this.entitySelection.selectedEntities.length - 1)) {\r\n return Promise.resolve();\r\n }\r\n\r\n return this.getNextEntities(i + 1);\r\n }\r\n\r\n private async getSelectionData(entityId: number, targetEntity: SelectedEntity): Promise {\r\n const i = this.entitySelection.selectedEntities.length - 1;\r\n const payload: GetEntitiesRequest = this.selectEntitiesService.getPayloadSourceEntityData(this.entitySelection, i);\r\n\r\n this.entitySelection.selectedEntities.push(targetEntity);\r\n\r\n if (entityId === 999 || entityId === 998) {\r\n const type = entityId === 999 ? 'site' : 'parcel';\r\n const parentPropChars = await this.selectEntitiesService.getPropCharsFromParent(type, payload);\r\n targetEntity.dropdownList = _.chain(parentPropChars)\r\n .map('name')\r\n .sortBy(parentPropChars, item => item.toLowerCase())\r\n .value() as string[];\r\n\r\n this.reportManagerService.setNewPropChars(parentPropChars);\r\n }\r\n else {\r\n payload.targetEntityTypeID = entityId;\r\n const parentEntities = await this.getEntitiesFromParent(payload);\r\n\r\n targetEntity.list = _.sortBy(parentEntities, item => item.name.toLowerCase()) as GenericEntity[];\r\n }\r\n }\r\n\r\n private async getEntitiesFromParent(payload: GetEntitiesRequest): Promise {\r\n if(payload.targetEntityTypeID === EntityTypeIds.USER && this.report.reportTypeId === this.reportTypes.UserAccess) {\r\n return await this.selectEntitiesService.getUsersWithAccessToCertainCompanies(payload, this.report.criteria.includeInternalUsers);\r\n }\r\n else if(payload.targetEntityTypeID === EntityTypeIds.CLIENTSERVICE) {\r\n return await this.selectEntitiesService.getClientServices(payload);\r\n }\r\n else if (payload.targetEntityTypeID === EntityTypeIds.PROPERTYTYPE) {\r\n return await this.selectEntitiesService.getPropertyTypes(payload);\r\n }\r\n else\r\n {\r\n return await this.selectEntitiesService.getEntitiesFromParent(payload);\r\n }\r\n }\r\n\r\n private removeEmptyEntities(i: number): void {\r\n this.entitySelection.selectedEntities = _.take(this.entitySelection.selectedEntities, i + 1) as SelectedEntity[];\r\n\r\n this.configureAdditionalSelections();\r\n }\r\n\r\n private configureAdditionalSelections(): void {\r\n const selectedEntities: SelectedEntity[] = this.selectEntitiesService.getSelectedEntities();\r\n\r\n this.additionalSelections = _.filter(selectedEntities, (entity: SelectedEntity): boolean => {\r\n const selectedEntitiesIDs: number[] = _.map(this.entitySelection.selectedEntities, 'id');\r\n\r\n // This is turning into something really messy....\r\n const preReqsSatisfied: boolean = _.intersection(selectedEntitiesIDs, entity.prerequisites).length === entity.prerequisites.length;\r\n const notBlocked: boolean = _.intersection(selectedEntitiesIDs, entity.blockers).length === 0;\r\n\r\n const maybeAppealResp = !entity.isAppealResponsibility || (this.entitySelection.selectedTopLevelCompanyIDs.length < 2 && (this.report.reportTypeId === this.reportTypes.Site));\r\n const maybeContacts = entity.id !== EntityTypeIds.CONTACT || (this.entitySelection.selectedTopLevelCompanyIDs.length < 2 && this.report.reportTypeId === this.reportTypes.UserActivity);\r\n const maybeUsers = entity.id !== EntityTypeIds.USER || entity.isAppealResponsibility || this.report.reportTypeId === this.reportTypes.UserAccess;\r\n const maybeSupportUsers = entity.id !== EntityTypeIds.SUPPORTUSER\r\n || this.report.reportTypeId === this.reportTypes.UserAccess\r\n || this.report.reportTypeId === this.reportTypes.UserActivity\r\n || this.report.reportTypeId === this.reportTypes.SupportInstanceEscalationActivity;\r\n\r\n const maybeSubsidiaries = entity.id != EntityTypeIds.COMPANY || _.intersection(selectedEntitiesIDs, [EntityTypeIds.USER]).length === 0 || this.report.reportTypeId === this.reportTypes.Site;\r\n\r\n const maybeUserActivityReport = this.report.reportTypeId != this.reportTypes.UserActivity || entity.id === EntityTypeIds.CONTACT || entity.id === EntityTypeIds.COMPANY;\r\n const maybeUserAccessReport = this.report.reportTypeId != this.reportTypes.UserAccess || entity.id === EntityTypeIds.USER || entity.id === EntityTypeIds.COMPANY;\r\n\r\n //condition is true if CsrCommandCenterReport OR not one of these 3 entity type (filters)\r\n const maybeCsrCommandCenterReport = this.report.reportTypeId === this.reportTypes.CsrCommandCenter || !(entity.id === EntityTypeIds.CLIENTSERVICE || entity.id === EntityTypeIds.PROPERTYTYPE || entity.id === 998);\r\n\r\n return preReqsSatisfied && notBlocked && maybeAppealResp && maybeContacts && maybeUserActivityReport && maybeUserAccessReport && maybeUsers && maybeSupportUsers && maybeSubsidiaries && maybeCsrCommandCenterReport;\r\n }) as SelectedEntity[];\r\n }\r\n\r\n private async getNextEntities(i: number): Promise {\r\n const entity: SelectedEntity = this.entitySelection.selectedEntities[i];\r\n const payload: any = this.selectEntitiesService.getPayloadSourceEntityData(this.entitySelection, i - 1);\r\n\r\n entity.loading = true;\r\n\r\n try {\r\n if (entity.id === 999 || entity.id === 998) {\r\n const type = entity.id === 999 ? 'site' : 'parcel';\r\n const parentPropChars = await this.selectEntitiesService.getPropCharsFromParent(type, payload);\r\n return this.processPropChars(entity, i, parentPropChars);\r\n } else {\r\n payload.targetEntityTypeID = entity.id;\r\n\r\n const parentEntities = await this.getEntitiesFromParent(payload);\r\n return this.processEntity(entity, i, parentEntities);\r\n }\r\n } finally {\r\n entity.loading = false;\r\n }\r\n }\r\n\r\n private async processPropChars(entity: SelectedEntity, i: number, propChars: GenericEntity[]): Promise {\r\n entity.dropdownList = _.map(propChars, 'name');\r\n\r\n if (!_.includes(entity.dropdownList, entity.selectedDropdown)) {\r\n entity.list = [];\r\n entity.selectedDropdown = '';\r\n this.removeEmptyEntities(i);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n await this.propCharChanged(entity, i);\r\n\r\n i++;\r\n if (i < this.entitySelection.selectedEntities.length) {\r\n return this.getNextEntities(i);\r\n }\r\n else {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n private processEntity(entity: SelectedEntity, i: number, entityList: GenericEntity[]): Promise {\r\n entity.selectedIDs = _.intersection(entity.selectedIDs, _.map(entityList, 'id'));\r\n entity.list = _.sortBy(entityList, item => item.name.toLowerCase()) as GenericEntity[];\r\n\r\n if (entity.list.length === 0 || entity.selectedIDs.length === 0) {\r\n this.removeEmptyEntities(i);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n i++;\r\n\r\n if (i < this.entitySelection.selectedEntities.length) {\r\n return this.getNextEntities(i);\r\n } else {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n private _reportDisallowsMultipleTLCs() {\r\n return this.report.reportTypeId == ReportType.Budget\r\n || this.report.reportTypeId == ReportType.BudgetVariance\r\n || this.report.reportTypeId == ReportType.Site;\r\n }\r\n}\r\n","\r\n
\r\n \r\n
\r\n
\r\n

\r\n Client Services Command Center\r\n

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n Exceptions only:\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n
\r\n Responsibilities\r\n \r\n
\r\n \r\n \r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport {\r\n ColDef,\r\n ColumnVisibleEvent,\r\n GridApi,\r\n GridOptions,\r\n GridReadyEvent,\r\n ICellRendererParams\r\n} from 'ag-grid-community';\r\nimport * as _ from 'lodash';\r\nimport { BreadCrumb } from '../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport {\r\n AgGridColumns,\r\n AgGridCurrencyCellEditor,\r\n AgGridDatepickerCellEditor,\r\n AgGridDropdownCellEditor,\r\n AgGridFilterParams,\r\n AgGridNumberCellEditor,\r\n AgGridOptionsBuilder,\r\n AgGridTextCellEditor\r\n} from '../../Compliance/AgGrid';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { GridSourceOptionEnum } from '../../Compliance/State-And-Jurisdiction/stateJurisdiction.service';\r\nimport { ProcessingService } from '../../Processing/processing.service.upgrade';\r\nimport { CsrCommandCenterService } from './csrCommandCenter.service';\r\nimport { CsrBulkUpdateComponent } from './Bulk-Update/csrBulkUpdate.component';\r\nimport { CsrListAgGridDataSource, CsrListDataSourceParams } from './agGridDataSource';\r\nimport {\r\n EntityFilter,\r\n EntitySelection,\r\n ReportDetail,\r\n ReportDetailCriteria,\r\n SelectedEntity\r\n} from '../../Reporting/Manager/report.manager.model';\r\nimport { ReportType } from '../../Reporting/Manager/report-type';\r\nimport { BehaviorSubject, Subject, Subscription, takeUntil } from 'rxjs';\r\nimport { ReportManagerSelectEntitiesService } from '../../Reporting/Manager/select.entities.service';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../Compliance/AgGrid/ToolPanel/models';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { EntityType } from '../../constants.new';\r\nimport { AgGridTooltipCellRendererComponent } from '../../Compliance/AgGrid/CellRenderers/agGridTooltipCellRenderer.component';\r\nimport { CellEditorValidationResult } from '../../Compliance/AgGrid/CellEditors/validator.interface';\r\nimport { WeissmanDateFormat } from '../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { CSR_COMMAND_CENTER_HELP } from './csrCommandCenter.component.help';\r\nimport { WebsocketListenerService } from 'src/app/Compliance/websocketListener.service';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from 'src/app/Busy-Indicator';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport { CsrUpdateStatusCellRendererComponent } from './agGridCsrUpdateStatusCellRenderer.component';\r\nimport { ClientServiceResponsibilityService } from '../clientServiceResponsibility.service';\r\n\r\nexport interface BulkUpdateCsrIdentifier {\r\n entityId: number,\r\n entityTypeId: number,\r\n clientServiceId: number,\r\n propertyTypeId: number,\r\n}\r\n\r\nexport interface BulkUpdateParams {\r\n csrs: BulkUpdateCsrIdentifier[];\r\n entityId: number;\r\n entityTypeId: number;\r\n topLevelCompanyId: number;\r\n longRunningProcessId?: number;\r\n}\r\n\r\n@Component({\r\n selector: 'csr-command-center',\r\n templateUrl: './csrCommandCenter.component.html',\r\n styles: [`\r\n :host {\r\n display: flex;\r\n flex-flow: column;\r\n height: 100%;\r\n width: 100%;\r\n }\r\n `]\r\n})\r\nexport class CsrCommandCenterComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _helpService: HelpService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _processingService: ProcessingService,\r\n private readonly _ccService : CsrCommandCenterService,\r\n private readonly _selectEntitiesService : ReportManagerSelectEntitiesService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _messageModalService : MessageModalService,\r\n private readonly _toastrService: ToastrService,\r\n private readonly _websocketListenerService: WebsocketListenerService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _csrService: ClientServiceResponsibilityService,\r\n ) {\r\n }\r\n\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n isRemoveExceptionsVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n selectedRows: number[] = [];\r\n gridId: System.Guid = '6FBDE227-1CFA-475E-B525-5992C1C368DB';\r\n breadcrumbs: BreadCrumb[] = [];\r\n isInitialized: boolean = false;\r\n isLoading: boolean = false;\r\n hasEditPermission: boolean = false;\r\n refreshing: boolean;\r\n showGrid: boolean = false;\r\n longRunningUpdateUnderway: boolean = false;\r\n isMaximized: boolean = false;\r\n isEmbededMode: boolean = false;\r\n exceptionsOnly: boolean = false;\r\n report: ReportDetail = new ReportDetail();\r\n entitySelection: EntitySelection = new EntitySelection();\r\n entityTree: any;\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true,\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected(params.data.id)\r\n },\r\n rowModelType: 'infinite'\r\n }).withInfiniteScroll(100)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withColumnPinning()\r\n .build();\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[]): Promise => {\r\n const searchModel = this._gridDataSource.getSearchParamsWithoutPagination();\r\n\r\n const exportModel: Core.ClientServiceResponsibilityCommandCenterExportModel = {\r\n columnsToReturn: columnsToReturn,\r\n searchModel: searchModel,\r\n companyId: this.entityTree.subsidiaryCompany.entityId\r\n };\r\n\r\n const longRunningProcessId = await this._ccService.exportList(exportModel);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportClientServiceResponsibilityCommandCenter };\r\n },\r\n disabled: false,\r\n canCancel: true\r\n };\r\n\r\n\r\n debouncedEntitySelectionChanged;\r\n\r\n private _gridApi: GridApi;\r\n private _gridMultiSelectSub: Subscription;\r\n private _destroy$: Subject = new Subject();\r\n private _busyRef: BusyIndicatorRef;\r\n private _gridDataSource: CsrListAgGridDataSource;\r\n\r\n private rootEntityId: number;\r\n private rootEntityTypeId: number;\r\n private entityCharacteristics: Core.ClientServiceResponsibilityCommandCenterDescriptorInfoModel;\r\n private selectedPropertyTypeIds: number[] = [];\r\n private selectedServicesIds: number[] = [];\r\n private entityFilters: EntityFilter[] = [];\r\n private excludeInactiveCompanies: boolean = false;\r\n private sourceEntityIds: number[] = [];\r\n private sourceEntityTypeId: number;\r\n private sourceEntityIsTopLevelCompany: boolean = false;\r\n private sitePropCharFilters: Compliance.NameValuePair[] = [];\r\n private parcelPropCharFilters: Compliance.NameValuePair[] = [];\r\n\r\n get refreshingGrid(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n\r\n this._helpService.setContent(CSR_COMMAND_CENTER_HELP);\r\n\r\n this.report.criteria = new ReportDetailCriteria();\r\n this.report.criteria.frequentlyUsed = false;\r\n this.report.criteria.reportType = ReportType.CsrCommandCenter;\r\n this.report.reportTypeId = 12;\r\n this.report.isOwnedByUser = true;\r\n this.report.criteria.includeInternalUsers = true;\r\n\r\n this.debouncedEntitySelectionChanged = _.debounce(this.onEntitySelectionChanged, 500);\r\n\r\n await this.loadEntity();\r\n await this.loadEntityCharacteristics();\r\n\r\n this.configureBreadcrumbs();\r\n\r\n this.gridOptions.onColumnVisible = (event: ColumnVisibleEvent) => {\r\n const columns = event.columnApi.getAllDisplayedColumns();\r\n\r\n const initialDescriptors = [...this._gridDataSource.descriptorIds];\r\n this._gridDataSource.descriptorIds = columns.filter(c => c.getColId().startsWith('d.')).map(c => +c.getColId().substring(2));\r\n if (!this._gridDataSource.descriptorIds.every(e => initialDescriptors.includes(e))) {\r\n this._gridDataSource.refresh();\r\n }\r\n return true;\r\n };\r\n\r\n const validProcessTypes = [Compliance.LongRunningProcessTypeEnum.UpdateCsrBulk, Compliance.LongRunningProcessTypeEnum.UpdateCsr];\r\n this._websocketListenerService.longRunningProcessStatusChange$.pipe(takeUntil(this._destroy$)).subscribe(\r\n async (x) => {\r\n if ((!validProcessTypes.includes(x.processType)) || x.entityId !== this.entitySelection.selectedTopLevelCompanyIDs[0]) {\r\n return;\r\n }\r\n if (x.isCanceled || x.isError || x.isCompleted) {\r\n this.longRunningUpdateUnderway = false;\r\n if (this._busyRef) {\r\n this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this.refresh();\r\n } else {\r\n this.longRunningUpdateUnderway = true;\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isRemoveExceptionsVisible$.next(false);\r\n }\r\n });\r\n\r\n this.isInitialized = true;\r\n return Promise.resolve();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridApi.showLoadingOverlay();\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._setGridColumns();\r\n\r\n this._gridApi.sizeColumnsToFit();\r\n if(this.showGrid)\r\n this._setDataSource();\r\n\r\n // notify the bulk update button (on the column tool panel) every time the grid selection changes\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(async () => {\r\n if (!this.longRunningUpdateUnderway) {\r\n this.isBulkUpdateVisible$.next(this.gridTracker.hasSelectedRows());\r\n this.isRemoveExceptionsVisible$.next(this.gridTracker.hasSelectedRows());\r\n }\r\n });\r\n }\r\n\r\n async bulkUpdate(): Promise {\r\n\r\n this.isLoading = true;\r\n let selectedRowIds ;\r\n try {\r\n selectedRowIds = await this.gridTracker.getSelectedRowIds();\r\n }\r\n finally {\r\n this.isLoading = false;\r\n }\r\n\r\n const csrs = selectedRowIds.map((sri:any) => this.parseCsrGridId(sri));\r\n\r\n const params:BulkUpdateParams = {csrs: csrs, entityId: this.rootEntityId, entityTypeId: this.rootEntityTypeId, topLevelCompanyId: this._gridApi.getRenderedNodes()[0].data.topLevelCompanyId };\r\n\r\n const result = await this._modalService.showAsync(CsrBulkUpdateComponent, params, 'modal-lg');\r\n\r\n if (params.longRunningProcessId) {\r\n this._busyRef = this._busyService.show({\r\n longRunningProcessId: params.longRunningProcessId,\r\n title: 'Updating Client Service Responsibility',\r\n canDismiss: true,\r\n message: '',\r\n captureFocus: true,\r\n restoreFocus: true,\r\n hasProgressBar: true,\r\n });\r\n\r\n this._busyRef.onDismiss().pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n this._busyRef.hide();\r\n this._destroy$.next();\r\n this._busyRef = null;\r\n });\r\n }\r\n\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.refresh();\r\n return Promise.resolve();\r\n }\r\n\r\n async removeExceptions(): Promise {\r\n\r\n this.isLoading = true;\r\n let selectedRowIds ;\r\n try {\r\n const searchModel = this._gridDataSource.getSearchParamsWithoutPagination();\r\n searchModel.exceptionsOnly = true;\r\n const exceptionRows = await this._ccService.searchRowIds(searchModel);\r\n const ids = await this.gridTracker.getSelectedRowIds();\r\n selectedRowIds = exceptionRows.data.filter(er => ids.includes(er));\r\n }\r\n finally {\r\n this.isLoading = false;\r\n }\r\n\r\n const possibleExceptions = [...new Set(selectedRowIds.map((sri) => this.parseCsrGridId(sri)).map(sri => sri.clientServiceResponsibilityId))] as number[];\r\n\r\n try {\r\n await this._messageModalService.confirm('Are you sure you want to remove client service responsibility exceptions from the selected items?', 'Remove Exceptions');\r\n\r\n this.isLoading = true;\r\n const params: Core.ClientServiceExceptionRemoveRequest = {responsibilitiesToRemove: possibleExceptions, topLevelCompanyId: this.rootEntityId };\r\n await this._ccService.removeExceptions(params);\r\n\r\n this._toastrService.success('Selected client service responsibility exception(s) removed');\r\n\r\n this.refresh();\r\n }\r\n catch(e){\r\n return Promise.resolve();\r\n }\r\n finally {\r\n this.isLoading = false;\r\n }\r\n\r\n }\r\n\r\n refresh() {\r\n this._refreshDataSource();\r\n }\r\n\r\n onEntitySelectionChanged(event) {\r\n const payload = this._selectEntitiesService.getPayloadSourceEntityData(this.entitySelection);\r\n this.entityFilters = payload.entityFilters;\r\n this.sourceEntityIds = payload.sourceEntityIDs;\r\n this.sourceEntityTypeId = payload.sourceEntityTypeID;\r\n this.sourceEntityIsTopLevelCompany = payload.sourceEntityIsTopLevelCompany || false;\r\n this.sitePropCharFilters = payload.sitePropCharFilters as Compliance.NameValuePair[];\r\n this.parcelPropCharFilters = payload.parcelPropCharFilters as Compliance.NameValuePair[];\r\n this.excludeInactiveCompanies = payload.excludeInactive;\r\n this._refreshDataSource();\r\n this.showGrid = true;\r\n }\r\n\r\n toggleMaximize(isMaximized: boolean): void {\r\n this.isMaximized = isMaximized;\r\n }\r\n\r\n private configureBreadcrumbs(): void {\r\n\r\n if(this.entityTree.topLevelCompany) {\r\n this.breadcrumbs.push({\r\n name: this.entityTree.topLevelCompany.text,\r\n target: 'company',\r\n options: { companyId: this.entityTree.topLevelCompany.entityId}\r\n });\r\n }\r\n\r\n this.breadcrumbs.push({\r\n name: this.entityTree.subsidiaryCompany.text,\r\n target: 'company',\r\n options: { companyId: this.entityTree.subsidiaryCompany.entityId }\r\n });\r\n\r\n if(this.entityTree.site) {\r\n this.breadcrumbs.push({\r\n name: this.entityTree.site.text,\r\n target: 'site',\r\n options: { companyId: this.entityTree.subsidiaryCompany.entityId, siteId: this.entityTree.site.entityId }\r\n });\r\n }\r\n\r\n if(this.entityTree.parcel) {\r\n this.breadcrumbs.push({\r\n name: this.entityTree.parcel.text,\r\n target: 'parcel',\r\n options: { companyId: this.entityTree.subsidiaryCompany.entityId, siteId: this.entityTree.site.entityId, parcelId: this.entityTree.parcel.entityId }\r\n });\r\n }\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return false;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isRemoveExceptionsVisible$.next(false);\r\n\r\n const dataSourceParams = (): CsrListDataSourceParams => {\r\n return {\r\n rootEntityId: this.entityTree.topLevelCompany ? this.entityTree.topLevelCompany.entityId : this.rootEntityId,\r\n rootEntityType: this.entityTree.topLevelCompany ? this.entityTree.topLevelCompany.entityTypeId : this.rootEntityTypeId,\r\n clientServiceIds: this.selectedServicesIds,\r\n propertyTypeIds: this.selectedPropertyTypeIds,\r\n exceptionsOnly: this.exceptionsOnly,\r\n entityFilters: this.entityFilters,\r\n sitePropCharFilters: this.sitePropCharFilters,\r\n parcelPropCharFilters: this.parcelPropCharFilters,\r\n sourceEntityIDs: this.sourceEntityIds,\r\n sourceEntityTypeID: this.sourceEntityTypeId,\r\n sourceEntityIsTopLevelCompany: this.sourceEntityIsTopLevelCompany,\r\n excludeInactiveCompanies: this.excludeInactiveCompanies,\r\n };\r\n };\r\n\r\n this._gridDataSource = new CsrListAgGridDataSource(\r\n this._gridApi,\r\n this._ccService,\r\n dataSourceParams\r\n );\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private _setGridColumns(): void {\r\n this._gridApi.setColumnDefs([]);\r\n\r\n //get standard columns\r\n const columns = this._getGridColumnsBySource(GridSourceOptionEnum.Assessor);\r\n\r\n const pickList = this.entityCharacteristics.pickList;\r\n\r\n //add dynamic columns based on the site/parcel chars\r\n this.entityCharacteristics.descriptors.reduce((acc, descriptor) => {\r\n const column: ColDef = BASE_DYNAMIC_DEFINITIONS[descriptor.fieldType](descriptor, pickList);\r\n column.cellRendererParams = {\r\n getTooltipText: (params) => {\r\n return '';\r\n }\r\n };\r\n acc.push(column);\r\n\r\n return acc;\r\n }, columns);\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setFilterModel(null);\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private parseCsrGridId(sri) {\r\n //This routine is pulling the different pieces of various ids that were crammed into a guid server-side. Because Microsoft is encoding the guids, parse it as \"variant 2\"\r\n //https://en.wikipedia.org/wiki/Universally_unique_identifier\r\n\r\n const hexRepresentation = sri.replaceAll('-', '');\r\n const firstNumStr = hexRepresentation.substr(0, 8);\r\n const firstNum = parseInt(firstNumStr, 16);\r\n const secondNumStr = `${ hexRepresentation.substr(12, 4) }${hexRepresentation.substr(8, 4)}`;\r\n const secondNum = parseInt(secondNumStr, 16);\r\n const thirdNumStr = `${ hexRepresentation.substr(22, 2) }${hexRepresentation.substr(20, 2) }${hexRepresentation.substr(18, 2) }${hexRepresentation.substr(16, 2)}`;\r\n const thirdNum = parseInt(thirdNumStr, 16);\r\n\r\n const fourthNumStr = hexRepresentation.substr(30, 2) +\r\n hexRepresentation.substr(28, 2) +\r\n hexRepresentation.substr(26, 2) +\r\n hexRepresentation.substr(24, 2);\r\n\r\n const fourthNum = parseInt(fourthNumStr, 16);\r\n\r\n\r\n const entityId = firstNum;\r\n const entityTypeId = secondNum;\r\n const clientServicePropertyTypeInt = thirdNum;\r\n const clientServiceResponsibilityId = fourthNum;\r\n\r\n const propertyTypeId = clientServicePropertyTypeInt >> 16;\r\n const clientServiceId = clientServicePropertyTypeInt % Math.pow(2, 16);\r\n\r\n return {\r\n entityId,\r\n entityTypeId,\r\n propertyTypeId,\r\n clientServiceId,\r\n clientServiceResponsibilityId,\r\n };\r\n }\r\n\r\n private async _refreshDataSource(): Promise {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n this.showGrid = true;\r\n this.gridTracker.clear(false);\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isRemoveExceptionsVisible$.next(false);\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _getGridColumnsBySource(gridSourceOption: GridSourceOptionEnum): ColDef[] {\r\n const columns: ColDef[] = [\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'id',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n } as ColDef,\r\n\r\n {\r\n headerName: 'Top Level Company',\r\n field: 'topLevelCompanyName',\r\n lockVisible: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const row = params.data as Core.ClientServiceResponsibilityCommandCenterModel;\r\n if (!row || !row.topLevelCompanyId) {\r\n return '';\r\n }\r\n return `#/company/${row.topLevelCompanyId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n\r\n },\r\n {\r\n headerName: 'Subsidiary',\r\n field: 'companyName',\r\n lockVisible: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const row = params.data as Core.ClientServiceResponsibilityCommandCenterModel;\r\n if (!row || !row.companyId) {\r\n return '';\r\n }\r\n return `#/company/${row.companyId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n headerName: 'Company Code',\r\n field: 'companyCode',\r\n lockVisible: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellClass: params => params.data && params.data.siteId === null ? 'barely-gray' : '',\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const row = params.data as Core.ClientServiceResponsibilityCommandCenterModel;\r\n if (!row || !row.siteId) {\r\n return '';\r\n }\r\n return `#/site/${row.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'siteNumber',\r\n lockVisible: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Parcel',\r\n field: 'parcelAccountNumber',\r\n lockVisible: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellClass: params => params.data && params.data.parcelId === null ? 'barely-gray' : '',\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const row = params.data as Core.ClientServiceResponsibilityCommandCenterModel;\r\n if (!row || !row.parcelId) {\r\n return '';\r\n }\r\n return `#/parcel/${row.parcelId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n lockVisible: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Client Service',\r\n field: 'clientServiceName',\r\n lockVisible: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'PropertyType',\r\n field: 'propertyTypeName',\r\n lockVisible: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Responsibility',\r\n field: 'responsibility',\r\n lockVisible: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const row = params.data as Core.ClientServiceResponsibilityCommandCenterModel;\r\n return row && row.isException ? 'overridden' : '';\r\n },\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n colId: 'grid-csr-update-status',\r\n headerName: '',\r\n field: 'csrUpdateStatus',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n pinned: 'right',\r\n lockVisible: true,\r\n sortable: false,\r\n cellRendererFramework: CsrUpdateStatusCellRendererComponent,\r\n cellRendererParams: {\r\n retryAction: this.retryResponsibilityUpdate.bind(this)\r\n },\r\n pinnedRowCellRenderer: () => {return '';}\r\n }\r\n ];\r\n\r\n return columns;\r\n }\r\n\r\n private async loadEntity() {\r\n this.rootEntityId = +this._upgradeNavigationServiceHandler.getQuerystringParam('entityId');\r\n this.rootEntityTypeId = +this._upgradeNavigationServiceHandler.getQuerystringParam('entityTypeId');\r\n this.entityTree = await this._processingService.getEntityTree(this.rootEntityTypeId, this.rootEntityId, false);\r\n this.entitySelection.selectedTopLevelCompanyIDs[0] = this.entityTree.topLevelCompany ? this.entityTree.topLevelCompany.entityId : this.entityTree.subsidiaryCompany.entityId;\r\n\r\n //top level company not set - must be top level company\r\n this.sourceEntityIsTopLevelCompany = this.entityTree.topLevelCompany === null && this.rootEntityTypeId === EntityType.Company;\r\n\r\n //determine entity filter that is set based on the type of entity passed in on route as long as not top company\r\n const selectedFilters:SelectedEntity[] = [];\r\n\r\n //show subsidiary filter with selection\r\n if(this.entityTree.subsidiaryCompany && this.entityTree.topLevelCompany !== null) {\r\n const selectedSubsidiaryFilter = this._selectEntitiesService.getSelectedEntities().filter(f => f.id === EntityType.Company)[0];\r\n selectedSubsidiaryFilter.selectedIDs = [this.entityTree.subsidiaryCompany.entityId];\r\n selectedFilters.push(selectedSubsidiaryFilter);\r\n }\r\n\r\n //show site filter with selection\r\n if(this.entityTree.site) {\r\n const selectedSiteFilter = this._selectEntitiesService.getSelectedEntities().filter(f => f.id === EntityType.Site)[0];\r\n selectedSiteFilter.selectedIDs = [this.entityTree.site.entityId];\r\n selectedFilters.push(selectedSiteFilter);\r\n }\r\n\r\n //show parcel filter with selection\r\n if(this.entityTree.parcel) {\r\n const selectedParcelFilter = this._selectEntitiesService.getSelectedEntities().filter(f => f.id === EntityType.Parcel)[0];\r\n selectedParcelFilter.selectedIDs = [this.entityTree.parcel.entityId];\r\n selectedFilters.push(selectedParcelFilter);\r\n }\r\n\r\n //filters that appear in faceted entity selector\r\n this.entitySelection.selectedEntities = selectedFilters;\r\n }\r\n\r\n private async loadEntityCharacteristics() {\r\n this.entityCharacteristics = await this._ccService.getEntityDescriptors(this.rootEntityId, this.rootEntityTypeId);\r\n }\r\n\r\n private async retryResponsibilityUpdate(params: ICellRendererParams): Promise {\r\n const respData = params.data as Core.ClientServiceResponsibilityCommandCenterModel;\r\n\r\n await this._csrService.retryWorkflowUpdateFromQueue({\r\n entityId: respData.parcelId ?? respData.siteId ?? respData.companyId ?? respData.topLevelCompanyId,\r\n entityTypeId: respData.parcelId ? 6 : respData.siteId ? 5 : 1,\r\n clientServiceId: respData.clientServiceId,\r\n propertyTypeId: respData.propertyTypeId\r\n });\r\n }\r\n}\r\n\r\nexport interface EntityDescriptorColumnDefinitions {\r\n [key: number]: (descriptor: Core.ClientServiceResponsibilityCommandCenterDescriptorModel, pickList?: Core.ClientServiceResponsibilityCommandCenterDescriptorPicklistModel[]) => ColDef;\r\n}\r\n\r\nexport const BASE_DYNAMIC_DEFINITIONS: EntityDescriptorColumnDefinitions = {\r\n [Core.DescriptorFieldTypes.Currency]: (descriptor) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n sortable: false,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridCurrencyCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => {\r\n return null;\r\n }\r\n },\r\n hide: true,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n valueFormatter: (params) => (+params.value) ? `$ ${(+params.value).toFixed(2)}` : '',\r\n cellClass: () => ''\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Date]: (descriptor) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n sortable: false,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.dateColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridDatepickerCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => {\r\n return null;\r\n },\r\n validator: (value: Date): CellEditorValidationResult => {\r\n const year = value.getFullYear();\r\n const validation = getDescriptor().validation;\r\n const isValid = validation\r\n && (validation.minValue ? year >= validation.minValue : true)\r\n && (validation.maxValue ? year <= validation.maxValue : true);\r\n let message = 'Year must be ';\r\n message += (validation.minValue) && `> ${validation.minValue - 1}`;\r\n message += (validation.minValue && validation.maxValue) && ' and ';\r\n message += (validation.maxValue) && `< ${validation.maxValue + 1}`;\r\n return { isValid, validationMessage: message };\r\n }\r\n },\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => WeissmanDateFormat(params.value, true),\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => ''\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Number]: (descriptor) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n sortable: false,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridNumberCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => {\r\n return null;\r\n },\r\n validator: (value: number): CellEditorValidationResult => {\r\n const validation = getDescriptor().validation;\r\n const isValid = validation\r\n && (validation.minValue ? value >= validation.minValue : true)\r\n && (validation.maxValue ? value <= validation.maxValue : true);\r\n let message = 'Value must be ';\r\n message += (validation.minValue) && `> ${validation.minValue - 1}`;\r\n message += (validation.minValue && validation.maxValue) && ' and ';\r\n message += (validation.maxValue) && `< ${ validation.maxValue + 1 }`;\r\n return { isValid, validationMessage: message};\r\n }\r\n },\r\n hide: true,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => ''\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Picklist]: (descriptor, picklist) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.selectionColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => {\r\n return picklist.reduce((acc, x) => {\r\n if (x.groupId === getDescriptor().picklistGroupId) {\r\n acc.push({ name: x.name, value: x.name });\r\n }\r\n return acc;\r\n }, []);\r\n },\r\n cellFocusLost: () => {\r\n return null;\r\n }\r\n },\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => ''\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Text]: (descriptor) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridTextCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => {\r\n return null;\r\n },\r\n validator: (value: string): CellEditorValidationResult => {\r\n const validation = getDescriptor().validation;\r\n const isValid = validation\r\n && (validation.maxLength ? value.length <= validation.maxLength : true);\r\n const message = `Max characters: ${validation.maxLength}`;\r\n return { isValid, validationMessage: message };\r\n },\r\n maxLength: descriptor.validation && descriptor.validation.maxLength\r\n },\r\n hide: true,\r\n sortable: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => ''\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.YesNo]: (descriptor) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => [{ name: 'Yes', value: true }, {name: 'No', value: false}],\r\n cellFocusLost: () => {\r\n return null;\r\n }\r\n },\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n valueFormatter: (params) => {\r\n if (params.value || params.value === false) {\r\n return (params.value) ? 'Yes' : 'No';\r\n } else {\r\n return '';\r\n }\r\n },\r\n cellClass: () => ''\r\n };\r\n }\r\n};\r\n\r\n\r\nconst getDescriptorValue =\r\n (model: any, descriptor: Core.ClientServiceResponsibilityCommandCenterDescriptorModel): any => {\r\n if (model && model.siteDescriptors && model.siteDescriptors.length) {\r\n const found = model.siteDescriptors.find(val => val.descriptorID === descriptor.descriptorId);\r\n return found && found.value;\r\n }\r\n if (model && model.parcelDescriptors && model.parcelDescriptors.length) {\r\n const found = model.parcelDescriptors.find(val => val.descriptorID === descriptor.descriptorId);\r\n return found && found.value;\r\n }\r\n };\r\n","export class AllocationDetailGridRowModel{\r\n constructor(private _allocationDetailModel: Compliance.AllocationDetailModel) {\r\n }\r\n\r\n get allocationDetailId(): number {\r\n return this._allocationDetailModel.allocationDetailId;\r\n }\r\n\r\n get assetNumber(): string {\r\n return this._allocationDetailModel.assetNumber;\r\n }\r\n\r\n set assetNumber(value: string) {\r\n this._allocationDetailModel.assetNumber = value;\r\n }\r\n\r\n get reportedCost(): number {\r\n return this._allocationDetailModel.reportedCost;\r\n }\r\n\r\n get returnValue(): number {\r\n return this._allocationDetailModel.returnValue;\r\n }\r\n\r\n get workPaperInitialAllocationAmount(): number {\r\n return this._allocationDetailModel.workPaperInitialAllocationAmount;\r\n }\r\n\r\n get initialAllocationAmount(): number{\r\n return this._allocationDetailModel.initialAllocationAmount ||\r\n this._allocationDetailModel.workPaperInitialAllocationAmount ||\r\n this._allocationDetailModel.returnValue;\r\n }\r\n\r\n set initialAllocationAmount(value: number) {\r\n if (this._allocationDetailModel.initialAllocationAmount !== value &&\r\n this._allocationDetailModel.workPaperInitialAllocationAmount !== value) {\r\n this._allocationDetailModel.initialAllocationAmount = value;\r\n }\r\n }\r\n\r\n get initialAllocationAmountOverridden(): boolean {\r\n return !!this._allocationDetailModel.initialAllocationAmount;\r\n }\r\n\r\n get initialAllocationAmountCalculated(): boolean {\r\n return !this._allocationDetailModel.initialAllocationAmount &&\r\n !this._allocationDetailModel.workPaperInitialAllocationAmount &&\r\n !!this._allocationDetailModel.returnValue;\r\n }\r\n\r\n get workPaperFinalAllocationAmount(): number {\r\n return this._allocationDetailModel.workPaperFinalAllocationAmount;\r\n }\r\n\r\n get finalAllocationAmount(): number{\r\n return this._allocationDetailModel.finalAllocationAmount ||\r\n this._allocationDetailModel.workPaperFinalAllocationAmount ||\r\n this._allocationDetailModel.initialAllocationAmount ||\r\n this._allocationDetailModel.workPaperInitialAllocationAmount;\r\n }\r\n set finalAllocationAmount(value: number) {\r\n if (this._allocationDetailModel.finalAllocationAmount !== value &&\r\n this._allocationDetailModel.workPaperFinalAllocationAmount !== value){\r\n this._allocationDetailModel.finalAllocationAmount = value;\r\n }\r\n }\r\n\r\n get finalAllocationAmountOverridden(): boolean {\r\n return !!this._allocationDetailModel.finalAllocationAmount;\r\n }\r\n\r\n set parcel(value: string) {\r\n this._allocationDetailModel.parcel = value;\r\n }\r\n get parcel(): string {\r\n return this._allocationDetailModel.parcel;\r\n }\r\n\r\n get calculatedParcel(): string {\r\n return this._allocationDetailModel.calculatedParcel;\r\n }\r\n\r\n get isWorkPaperParcelOverridden(): boolean {\r\n return this._allocationDetailModel.isWorkPaperParcelOverridden;\r\n }\r\n\r\n get statusId(): number{\r\n return this._allocationDetailModel.allocationDetailStatusId;\r\n }\r\n\r\n set statusId(value: number) {\r\n this._allocationDetailModel.allocationDetailStatusId = value;\r\n }\r\n\r\n get status(): string{\r\n return this._allocationDetailModel.allocationDetailStatus;\r\n }\r\n\r\n set status(value: string) {\r\n this._allocationDetailModel.allocationDetailStatus = value;\r\n }\r\n\r\n get isReconciled(): boolean {\r\n return this._allocationDetailModel.isReconciled;\r\n }\r\n\r\n set isReconciled(value: boolean) {\r\n this._allocationDetailModel.isReconciled = value;\r\n }\r\n\r\n get rowVersion(): number[] {\r\n return this._allocationDetailModel.rowVersion;\r\n }\r\n\r\n get assignedAllocationAssessmentIds(): number[]{\r\n return this._allocationDetailModel.assignedAllocationAssessmentIds;\r\n }\r\n\r\n get description(): string {\r\n return this._allocationDetailModel.description;\r\n }\r\n\r\n get companyCode(): string {\r\n return this._allocationDetailModel.companyCode;\r\n }\r\n\r\n get glAccount(): string {\r\n return this._allocationDetailModel.glAccount;\r\n }\r\n\r\n get glAccountNumber(): string {\r\n return this._allocationDetailModel.glAccountNumber;\r\n }\r\n\r\n get assetReturnStatus(): string {\r\n return this._allocationDetailModel.assetReturnStatus;\r\n }\r\n\r\n get splitAllocationPercentage(): number {\r\n return this._allocationDetailModel.splitAllocationPercentage;\r\n }\r\n\r\n get classificationName(): string {\r\n return this._allocationDetailModel.classificationName;\r\n }\r\n\r\n get parcelAddressComplete(): string {\r\n return this._allocationDetailModel.parcelAddressComplete;\r\n }\r\n\r\n get linkedParcelAccountNumber(): string {\r\n return this._allocationDetailModel.linkedParcelAccountNumber;\r\n }\r\n\r\n get parcelDescription(): string {\r\n return this._allocationDetailModel.parcelDescription;\r\n }\r\n\r\n get linkedParcelDescription(): string {\r\n return this._allocationDetailModel.linkedParcelDescription;\r\n }\r\n\r\n get assessorAbbr(): string {\r\n return this._allocationDetailModel.assessorAbbr;\r\n }\r\n\r\n get linkedParcelAssessorAbbr(): string {\r\n return this._allocationDetailModel.linkedParcelAssessorAbbr;\r\n }\r\n\r\n get priorAcqDate(): Date{\r\n return this._allocationDetailModel.priorAcqDate;\r\n }\r\n\r\n get acqDate(): Date {\r\n return this._allocationDetailModel.acqDate;\r\n }\r\n\r\n get priorCost(): number {\r\n return this._allocationDetailModel.priorCost;\r\n }\r\n\r\n get costChange(): number {\r\n return this._allocationDetailModel.costChange;\r\n }\r\n\r\n get netBookValue(): number {\r\n return this._allocationDetailModel.netBookValue;\r\n }\r\n\r\n get site(): string {\r\n return this._allocationDetailModel.site;\r\n }\r\n\r\n get siteProperty(): string {\r\n return this._allocationDetailModel.siteProperty;\r\n }\r\n\r\n get siteName(): string {\r\n return this._allocationDetailModel.siteName;\r\n }\r\n\r\n get priorScheduleName(): string {\r\n return this._allocationDetailModel.priorScheduleName;\r\n }\r\n\r\n get scheduleName(): string {\r\n return this._allocationDetailModel.scheduleName;\r\n }\r\n\r\n get priorDepreciationFactorTableName(): string {\r\n return this._allocationDetailModel.priorDepreciationFactorTableName;\r\n }\r\n\r\n get depreciationFactorTableName(): string {\r\n return this._allocationDetailModel.depreciationFactorTableName;\r\n }\r\n\r\n get factor(): number {\r\n return this._allocationDetailModel.factor;\r\n }\r\n\r\n get additionalDepreciation(): number {\r\n return this._allocationDetailModel.additionalDepreciation;\r\n }\r\n\r\n get estimatedFMV(): number {\r\n return this._allocationDetailModel.estimatedFMV;\r\n }\r\n\r\n get acqYear(): number {\r\n return this._allocationDetailModel.acqYear;\r\n }\r\n\r\n get age(): number {\r\n return this._allocationDetailModel.age;\r\n }\r\n\r\n get leaseLocationName(): string {\r\n return this._allocationDetailModel.leaseLocationName;\r\n }\r\n\r\n get leaseAddress(): string {\r\n return this._allocationDetailModel.leaseAddress;\r\n }\r\n\r\n get leaseCity(): string {\r\n return this._allocationDetailModel.leaseCity;\r\n }\r\n\r\n get leaseState(): string {\r\n return this._allocationDetailModel.leaseState;\r\n }\r\n\r\n get leaseZip(): string {\r\n return this._allocationDetailModel.leaseZip;\r\n }\r\n\r\n get leaseStartDate(): Date {\r\n return this._allocationDetailModel.leaseStartDate;\r\n }\r\n\r\n get leaseEndDate(): Date {\r\n return this._allocationDetailModel.leaseEndDate;\r\n }\r\n\r\n get leaseTermInMonths(): number {\r\n return this._allocationDetailModel.leaseTermInMonths;\r\n }\r\n\r\n get leaseMonthlyPayment(): number {\r\n return this._allocationDetailModel.leaseMonthlyPayment;\r\n }\r\n\r\n get leaseTypeId(): string {\r\n return this._allocationDetailModel.leaseTypeId;\r\n }\r\n\r\n get leaseAssetId(): string {\r\n return this._allocationDetailModel.leaseAssetId;\r\n }\r\n\r\n get leaseNumber(): string {\r\n return this._allocationDetailModel.leaseNumber;\r\n }\r\n\r\n get leaseBillingName(): string {\r\n return this._allocationDetailModel.leaseBillingName;\r\n }\r\n\r\n get leaseBillingAddress(): string {\r\n return this._allocationDetailModel.leaseBillingAddress;\r\n }\r\n\r\n get leaseBillingCity(): string {\r\n return this._allocationDetailModel.leaseBillingCity;\r\n }\r\n\r\n get leaseBillingState(): string {\r\n return this._allocationDetailModel.leaseBillingState;\r\n }\r\n\r\n get leaseBillingZip(): string {\r\n return this._allocationDetailModel.leaseBillingZip;\r\n }\r\n\r\n get leaseClientId(): string {\r\n return this._allocationDetailModel.leaseClientId;\r\n }\r\n\r\n get inventoryJan(): number {\r\n return this._allocationDetailModel.inventoryJan;\r\n }\r\n\r\n get inventoryFeb(): number {\r\n return this._allocationDetailModel.inventoryFeb;\r\n }\r\n\r\n get inventoryMar(): number {\r\n return this._allocationDetailModel.inventoryMar;\r\n }\r\n\r\n get inventoryApr(): number {\r\n return this._allocationDetailModel.inventoryApr;\r\n }\r\n\r\n get inventoryMay(): number {\r\n return this._allocationDetailModel.inventoryMay;\r\n }\r\n\r\n get inventoryJun(): number {\r\n return this._allocationDetailModel.inventoryJun;\r\n }\r\n\r\n get inventoryJul(): number {\r\n return this._allocationDetailModel.inventoryJul;\r\n }\r\n\r\n get inventoryAug(): number {\r\n return this._allocationDetailModel.inventoryAug;\r\n }\r\n\r\n get inventorySep(): number {\r\n return this._allocationDetailModel.inventorySep;\r\n }\r\n\r\n get inventoryOct(): number {\r\n return this._allocationDetailModel.inventoryOct;\r\n }\r\n\r\n get inventoryNov(): number {\r\n return this._allocationDetailModel.inventoryNov;\r\n }\r\n\r\n get inventoryDec(): number {\r\n return this._allocationDetailModel.inventoryDec;\r\n }\r\n\r\n get inventoryAvrCalculated(): number {\r\n return this._allocationDetailModel.inventoryAvrCalculated;\r\n }\r\n\r\n get inventoryAggregatedString(): string {\r\n return this._allocationDetailModel.inventoryAggregatedString;\r\n }\r\n\r\n get isReportable(): boolean {\r\n return this._allocationDetailModel.isReportable;\r\n }\r\n\r\n get isTaxable(): boolean {\r\n return this._allocationDetailModel.isTaxable;\r\n }\r\n\r\n get workPaperCost(): number {\r\n return this._allocationDetailModel.workPaperCost;\r\n }\r\n\r\n get workPaperAcqDate(): Date {\r\n return this._allocationDetailModel.workPaperAcqDate;\r\n }\r\n\r\n get canBeReconciled(): boolean {\r\n return !!this._allocationDetailModel.assetId || !!this._allocationDetailModel.returnAssetId;\r\n }\r\n\r\n get isMatched(): boolean {\r\n return !!this._allocationDetailModel.assetId || !!this._allocationDetailModel.returnAssetId;\r\n }\r\n\r\n get varianceDollar(): number {\r\n return this._allocationDetailModel.varianceDollar;\r\n }\r\n\r\n get variancePercentage(): number {\r\n return this._allocationDetailModel.variancePercentage;\r\n }\r\n\r\n get workPaperDescription(): string {\r\n return this._allocationDetailModel.workPaperDescription;\r\n }\r\n\r\n get workPaperAcqYear(): number {\r\n return this._allocationDetailModel.workPaperAcqYear;\r\n }\r\n\r\n get workPaperSchedule(): string {\r\n return this._allocationDetailModel.workPaperSchedule;\r\n }\r\n\r\n get workPaperFactor(): number {\r\n return this._allocationDetailModel.workPaperFactor;\r\n }\r\n\r\n get workPaperAddlDep(): number {\r\n return this._allocationDetailModel.workPaperAddlDep;\r\n }\r\n\r\n get workPaperAssessor(): string {\r\n return this._allocationDetailModel.workPaperAssessor;\r\n }\r\n\r\n get workPaperTaxingUnit(): string {\r\n return this._allocationDetailModel.workPaperTaxingUnit;\r\n }\r\n\r\n get workPaperPhysicalAddress(): string {\r\n return this._allocationDetailModel.workPaperPhysicalAddress;\r\n }\r\n\r\n get workPaperLesseeName(): string {\r\n return this._allocationDetailModel.workPaperLesseeName;\r\n }\r\n\r\n get workPaperNote(): string {\r\n return this._allocationDetailModel.workPaperNote;\r\n }\r\n\r\n get workPaperMisc1(): string {\r\n return this._allocationDetailModel.workPaperMisc1;\r\n }\r\n\r\n get workPaperMisc2(): string {\r\n return this._allocationDetailModel.workPaperMisc2;\r\n }\r\n\r\n get workPaperMisc3(): string {\r\n return this._allocationDetailModel.workPaperMisc3;\r\n }\r\n\r\n get workPaperMisc4(): string {\r\n return this._allocationDetailModel.workPaperMisc4;\r\n }\r\n\r\n get workPaperMisc5(): string {\r\n return this._allocationDetailModel.workPaperMisc5;\r\n }\r\n\r\n get reportingAssetId(): number {\r\n return this._allocationDetailModel.reportingAssetId;\r\n }\r\n\r\n get assetId(): number {\r\n return this._allocationDetailModel.assetId;\r\n }\r\n\r\n get returnAssetId(): number {\r\n return this._allocationDetailModel.returnAssetId;\r\n }\r\n\r\n get siteIsDifferent(): boolean {\r\n return this._allocationDetailModel.siteId !== this._allocationDetailModel.workPaperSiteId;\r\n }\r\n\r\n get parcelIsDifferent(): boolean {\r\n return this._allocationDetailModel.parcelId !== this._allocationDetailModel.workPaperParcelId &&\r\n this._allocationDetailModel.linkedParcelId !== this._allocationDetailModel.workPaperParcelId;\r\n }\r\n\r\n get calculatedAssetId(): number {\r\n return this._allocationDetailModel.calculatedAssetId;\r\n }\r\n\r\n get calculatedReportingAssetId(): number {\r\n return this._allocationDetailModel.calculatedReportingAssetId;\r\n }\r\n\r\n get parcelSiteId(): number {\r\n return this._allocationDetailModel.parcelSiteId;\r\n }\r\n\r\n get priorYearEffectiveTaxRate(): number {\r\n return this._allocationDetailModel.priorYearEffectiveTaxRate;\r\n }\r\n\r\n get priorYearFinalAllocationAmount(): number {\r\n return this._allocationDetailModel.priorYearFinalAllocationAmount;\r\n }\r\n\r\n get priorYearFactor(): number {\r\n return this._allocationDetailModel.priorYearFactor;\r\n }\r\n\r\n get taxVarianceDollar(): number {\r\n return this._allocationDetailModel.taxVarianceDollar;\r\n }\r\n}\r\n","import { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../AgGrid';\r\nimport { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { AllocationDetailRepository } from '../../Repositories/allocationDetail.repository';\r\nimport { AllocationDetailGridRowModel } from './AllocationDetailGridRowModel';\r\nimport { AllocationDetailsService } from './allocationDetails.service';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface AllocationDetailsListDataSourceParams {\r\n allocationId: number;\r\n hideNotReportedAssets: boolean;\r\n managementReviewOption: Compliance.AllocationDetailManagementReviewOptionEnum;\r\n}\r\n\r\nexport class AllocationDetailsListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(gridApi: GridApi,\r\n private readonly _allocationDetailRepository: AllocationDetailRepository,\r\n private readonly _allocationDetailService: AllocationDetailsService,\r\n protected _dataSourceParamsFn: () => AllocationDetailsListDataSourceParams,\r\n private readonly _totalsUpdateCallback: (totals: any, selectedTotals?: boolean, isLoading?: boolean) => void) {\r\n super(gridApi);\r\n }\r\n\r\n lastFetchedTotals: Compliance.AllocationDetailTotalsModel;\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'assetNumber', value: Compliance.AllocationDetailPropertyEnum.AssetNumber },\r\n { name: 'cost', value: Compliance.AllocationDetailPropertyEnum.Cost },\r\n { name: 'returnValue', value: Compliance.AllocationDetailPropertyEnum.ReturnValue },\r\n { name: 'initialAllocationAmount', value: Compliance.AllocationDetailPropertyEnum.InitialAllocationAmount },\r\n { name: 'finalAllocationAmount', value: Compliance.AllocationDetailPropertyEnum.FinalAllocationAmount },\r\n { name: 'calculatedParcel', value: Compliance.AllocationDetailPropertyEnum.CalculatedParcel },\r\n { name: 'statusId', value: Compliance.AllocationDetailPropertyEnum.AllocationDetailStatusId },\r\n { name: 'isReconciled', value: Compliance.AllocationDetailPropertyEnum.IsReconciled },\r\n { name: 'description', value: Compliance.AllocationDetailPropertyEnum.Description },\r\n { name: 'glAccount', value: Compliance.AllocationDetailPropertyEnum.GLAccount },\r\n { name: 'glAccountNumber', value: Compliance.AllocationDetailPropertyEnum.GLAccountNumber },\r\n { name: 'classificationName', value: Compliance.AllocationDetailPropertyEnum.ClassificationName },\r\n { name: 'parcel', value: Compliance.AllocationDetailPropertyEnum.Parcel },\r\n { name: 'parcelDescription', value: Compliance.AllocationDetailPropertyEnum.ParcelDescription },\r\n { name: 'assessorAbbr', value: Compliance.AllocationDetailPropertyEnum.AssessorAbbr },\r\n { name: 'acqDate', value: Compliance.AllocationDetailPropertyEnum.AcqDate },\r\n { name: 'age', value: Compliance.AllocationDetailPropertyEnum.Age },\r\n { name: 'priorAcqDate', value: Compliance.AllocationDetailPropertyEnum.PriorAcqDate },\r\n { name: 'priorCost', value: Compliance.AllocationDetailPropertyEnum.PriorCost },\r\n { name: 'scheduleName', value: Compliance.AllocationDetailPropertyEnum.Schedule },\r\n { name: 'site', value: Compliance.AllocationDetailPropertyEnum.Site },\r\n { name: 'siteName', value: Compliance.AllocationDetailPropertyEnum.SiteName },\r\n { name: 'siteProperty', value: Compliance.AllocationDetailPropertyEnum.SiteProperty },\r\n { name: 'parcelSiteProperty', value: Compliance.AllocationDetailPropertyEnum.ParcelSiteProperty },\r\n { name: 'parcelSiteName', value: Compliance.AllocationDetailPropertyEnum.ParcelSiteName },\r\n { name: 'priorScheduleName', value: Compliance.AllocationDetailPropertyEnum.PriorSchedule },\r\n { name: 'depreciationFactorTableName', value: Compliance.AllocationDetailPropertyEnum.DepreciationFactorTableName },\r\n { name: 'priorDepreciationFactorTableName', value: Compliance.AllocationDetailPropertyEnum.PriorDepreciationFactorTableName},\r\n { name: 'factor', value: Compliance.AllocationDetailPropertyEnum.Factor },\r\n { name: 'acqYear', value: Compliance.AllocationDetailPropertyEnum.AcqYear },\r\n { name: 'linkedParcelAccountNumber', value: Compliance.AllocationDetailPropertyEnum.LinkedParcelAccountNumber },\r\n { name: 'linkedParcelDescription', value: Compliance.AllocationDetailPropertyEnum.LinkedParcelDescription },\r\n { name: 'linkedParcelAssessorAbbr', value: Compliance.AllocationDetailPropertyEnum.LinkedParcelAssessorAbbr },\r\n { name: 'acqYear', value: Compliance.AllocationDetailPropertyEnum.AcqYear },\r\n { name: 'acqYear', value: Compliance.AllocationDetailPropertyEnum.AcqYear },\r\n { name: 't1', value: Compliance.AllocationDetailPropertyEnum.T1 },\r\n { name: 't2', value: Compliance.AllocationDetailPropertyEnum.T2 },\r\n { name: 't3', value: Compliance.AllocationDetailPropertyEnum.T3 },\r\n { name: 't4', value: Compliance.AllocationDetailPropertyEnum.T4 },\r\n { name: 't5', value: Compliance.AllocationDetailPropertyEnum.T5 },\r\n { name: 't6', value: Compliance.AllocationDetailPropertyEnum.T6 },\r\n { name: 't7', value: Compliance.AllocationDetailPropertyEnum.T7 },\r\n { name: 't8', value: Compliance.AllocationDetailPropertyEnum.T8 },\r\n { name: 't9', value: Compliance.AllocationDetailPropertyEnum.T9 },\r\n { name: 't10', value: Compliance.AllocationDetailPropertyEnum.T10 },\r\n { name: 't11', value: Compliance.AllocationDetailPropertyEnum.T11 },\r\n { name: 't12', value: Compliance.AllocationDetailPropertyEnum.T12 },\r\n { name: 't13', value: Compliance.AllocationDetailPropertyEnum.T13 },\r\n { name: 't14', value: Compliance.AllocationDetailPropertyEnum.T14 },\r\n { name: 't15', value: Compliance.AllocationDetailPropertyEnum.T15 },\r\n { name: 't16', value: Compliance.AllocationDetailPropertyEnum.T16 },\r\n { name: 't17', value: Compliance.AllocationDetailPropertyEnum.T17 },\r\n { name: 't18', value: Compliance.AllocationDetailPropertyEnum.T18 },\r\n { name: 't19', value: Compliance.AllocationDetailPropertyEnum.T19 },\r\n { name: 't20', value: Compliance.AllocationDetailPropertyEnum.T20 },\r\n { name: 't20', value: Compliance.AllocationDetailPropertyEnum.T20 },\r\n { name: 't21', value: Compliance.AllocationDetailPropertyEnum.T21 },\r\n { name: 't22', value: Compliance.AllocationDetailPropertyEnum.T22 },\r\n { name: 't23', value: Compliance.AllocationDetailPropertyEnum.T23 },\r\n { name: 't24', value: Compliance.AllocationDetailPropertyEnum.T24 },\r\n { name: 't25', value: Compliance.AllocationDetailPropertyEnum.T25 },\r\n { name: 't26', value: Compliance.AllocationDetailPropertyEnum.T26 },\r\n { name: 't27', value: Compliance.AllocationDetailPropertyEnum.T27 },\r\n { name: 't28', value: Compliance.AllocationDetailPropertyEnum.T28 },\r\n { name: 't29', value: Compliance.AllocationDetailPropertyEnum.T29 },\r\n { name: 't30', value: Compliance.AllocationDetailPropertyEnum.T30 },\r\n { name: 'n1', value: Compliance.AllocationDetailPropertyEnum.N1 },\r\n { name: 'n2', value: Compliance.AllocationDetailPropertyEnum.N2 },\r\n { name: 'n3', value: Compliance.AllocationDetailPropertyEnum.N3 },\r\n { name: 'n4', value: Compliance.AllocationDetailPropertyEnum.N4 },\r\n { name: 'n5', value: Compliance.AllocationDetailPropertyEnum.N5 },\r\n { name: 'n6', value: Compliance.AllocationDetailPropertyEnum.N6 },\r\n { name: 'n7', value: Compliance.AllocationDetailPropertyEnum.N7 },\r\n { name: 'n8', value: Compliance.AllocationDetailPropertyEnum.N8 },\r\n { name: 'n9', value: Compliance.AllocationDetailPropertyEnum.N9 },\r\n { name: 'n10', value: Compliance.AllocationDetailPropertyEnum.N10 },\r\n { name: 'd1', value: Compliance.AllocationDetailPropertyEnum.D1 },\r\n { name: 'd2', value: Compliance.AllocationDetailPropertyEnum.D2 },\r\n { name: 'd3', value: Compliance.AllocationDetailPropertyEnum.D3 },\r\n { name: 'd4', value: Compliance.AllocationDetailPropertyEnum.D4 },\r\n { name: 'd5', value: Compliance.AllocationDetailPropertyEnum.D5 },\r\n { name: 'd6', value: Compliance.AllocationDetailPropertyEnum.D6 },\r\n { name: 'd7', value: Compliance.AllocationDetailPropertyEnum.D7 },\r\n { name: 'd8', value: Compliance.AllocationDetailPropertyEnum.D8 },\r\n { name: 'd9', value: Compliance.AllocationDetailPropertyEnum.D9 },\r\n { name: 'd10', value: Compliance.AllocationDetailPropertyEnum.D10 },\r\n { name: 'inventoryJan', value: Compliance.AllocationDetailPropertyEnum.InventoryJan },\r\n { name: 'inventoryFeb', value: Compliance.AllocationDetailPropertyEnum.InventoryFeb },\r\n { name: 'inventoryMar', value: Compliance.AllocationDetailPropertyEnum.InventoryMar },\r\n { name: 'inventoryApr', value: Compliance.AllocationDetailPropertyEnum.InventoryApr },\r\n { name: 'inventoryMay', value: Compliance.AllocationDetailPropertyEnum.InventoryMay },\r\n { name: 'inventoryJun', value: Compliance.AllocationDetailPropertyEnum.InventoryJun },\r\n { name: 'inventoryJul', value: Compliance.AllocationDetailPropertyEnum.InventoryJul },\r\n { name: 'inventoryAug', value: Compliance.AllocationDetailPropertyEnum.InventoryAug },\r\n { name: 'inventorySep', value: Compliance.AllocationDetailPropertyEnum.InventorySep },\r\n { name: 'inventoryOct', value: Compliance.AllocationDetailPropertyEnum.InventoryOct },\r\n { name: 'inventoryNov', value: Compliance.AllocationDetailPropertyEnum.InventoryNov },\r\n { name: 'inventoryDec', value: Compliance.AllocationDetailPropertyEnum.InventoryDec },\r\n { name: 'inventoryAvr', value: Compliance.AllocationDetailPropertyEnum.InventoryAvr },\r\n { name: 'splitAllocationPercentage', value: Compliance.AllocationDetailPropertyEnum.SplitAllocationPercentage },\r\n { name: 'additionalDepreciation', value: Compliance.AllocationDetailPropertyEnum.AdditionalDepreciation },\r\n { name: 'estimatedFMV', value: Compliance.AllocationDetailPropertyEnum.EstimatedFMV },\r\n { name: 'isReportable', value: Compliance.AllocationDetailPropertyEnum.IsReportable },\r\n { name: 'isTaxable', value: Compliance.AllocationDetailPropertyEnum.IsTaxable },\r\n { name: 'parcelAddressComplete', value: Compliance.AllocationDetailPropertyEnum.ParcelAddressComplete },\r\n { name: 'companyCode', value: Compliance.AllocationDetailPropertyEnum.CompanyCode },\r\n { name: 'netBookValue', value: Compliance.AllocationDetailPropertyEnum.NetBookValue },\r\n { name: 'workPaperCost', value: Compliance.AllocationDetailPropertyEnum.WorkPaperCost },\r\n { name: 'workPaperAcqDate', value: Compliance.AllocationDetailPropertyEnum.WorkPaperAcqDate },\r\n { name: 'varianceDollar', value: Compliance.AllocationDetailPropertyEnum.VarianceDollar },\r\n { name: 'variancePercentage', value: Compliance.AllocationDetailPropertyEnum.VariancePercentage },\r\n { name: 'workPaperDescription', value: Compliance.AllocationDetailPropertyEnum.WorkPaperDescription },\r\n { name: 'workPaperAcqYear', value: Compliance.AllocationDetailPropertyEnum.WorkPaperAcqYear },\r\n { name: 'workPaperSchedule', value: Compliance.AllocationDetailPropertyEnum.WorkPaperSchedule },\r\n { name: 'workPaperFactor', value: Compliance.AllocationDetailPropertyEnum.WorkPaperFactor },\r\n { name: 'workPaperAddlDep', value: Compliance.AllocationDetailPropertyEnum.WorkPaperAddlDep },\r\n { name: 'workPaperAssessor', value: Compliance.AllocationDetailPropertyEnum.WorkPaperAssessor },\r\n { name: 'workPaperTaxingUnit', value: Compliance.AllocationDetailPropertyEnum.WorkPaperTaxingUnit },\r\n { name: 'workPaperPhysicalAddress', value: Compliance.AllocationDetailPropertyEnum.WorkPaperPhysicalAddress },\r\n { name: 'workPaperLesseeName', value: Compliance.AllocationDetailPropertyEnum.WorkPaperLesseeName },\r\n { name: 'workPaperNote', value: Compliance.AllocationDetailPropertyEnum.WorkPaperNote },\r\n { name: 'workPaperMisc1', value: Compliance.AllocationDetailPropertyEnum.WorkPaperMisc1 },\r\n { name: 'workPaperMisc2', value: Compliance.AllocationDetailPropertyEnum.WorkPaperMisc2 },\r\n { name: 'workPaperMisc3', value: Compliance.AllocationDetailPropertyEnum.WorkPaperMisc3 },\r\n { name: 'workPaperMisc4', value: Compliance.AllocationDetailPropertyEnum.WorkPaperMisc4 },\r\n { name: 'workPaperMisc5', value: Compliance.AllocationDetailPropertyEnum.WorkPaperMisc5 },\r\n { name: 'priorYearEffectiveTaxRate', value: Compliance.AllocationDetailPropertyEnum.PriorYearEffectiveTaxRate },\r\n { name: 'priorYearFinalAllocationAmount', value: Compliance.AllocationDetailPropertyEnum.PriorYearFinalAllocationAmount },\r\n { name: 'priorYearFactor', value: Compliance.AllocationDetailPropertyEnum.PriorYearFactor },\r\n { name: 'taxVarianceDollar', value: Compliance.AllocationDetailPropertyEnum.TaxVarianceDollar }\r\n ];\r\n\r\n private _lastFilterUsedInTotals: string;\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.pagination = { skip: startIndex, take: endIndex - startIndex + 1} as Core.PaginationModel;\r\n\r\n return await lastValueFrom(this._allocationDetailRepository.getRowIds(this._dataSourceParams.allocationId, searchParams));\r\n }\r\n\r\n async getSelectedRowTotals(selectedRowsModel: Compliance.SelectedRowsModel): Promise {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.selectedRows = selectedRowsModel;\r\n searchParams.includeTotals = true;\r\n searchParams.includeOnlyTotals = true;\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: 100\r\n };\r\n\r\n const result = await lastValueFrom(this._allocationDetailRepository.getList(this._dataSourceParams.allocationId, searchParams));\r\n\r\n return result.totals;\r\n }\r\n\r\n getSearchParamsWithoutPagination(): Compliance.AllocationDetailSearchModel {\r\n this.refreshDataSourceParams();\r\n\r\n const searchModel: Compliance.AllocationDetailSearchModel = {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n selectedRows: null,\r\n includeTotals: false,\r\n includeOnlyTotals: false,\r\n summaryFilter: this._allocationDetailService.allocationDetailsFilter && this._allocationDetailService.allocationDetailsFilter.model,\r\n hideNotReportedAssets: this._dataSourceParams.hideNotReportedAssets,\r\n managementReviewSelectedOption: this._dataSourceParams.managementReviewOption\r\n };\r\n\r\n return searchModel;\r\n }\r\n\r\n reloadDataAfterUpdate(field: string): boolean {\r\n let reload: boolean = true;\r\n const columnMap = _.find(this._propertyMap, i => i.name === field);\r\n\r\n if (columnMap){\r\n const isInUseInFilter = !!_.find(this.getColumnFilters(this._propertyMap), i => i.filterProperty === columnMap.value);\r\n const isInUseInSort = !!_.find(this.getSortColumns(this._propertyMap), i => i.sortProperty === columnMap.value);\r\n reload = isInUseInFilter || isInUseInSort;\r\n }\r\n\r\n return reload;\r\n }\r\n\r\n clearTotals(): void {\r\n this._lastFilterUsedInTotals = '';\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n this.gridApi.setPinnedBottomRowData([]);\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n const searchParamsString = JSON.stringify(searchParams);\r\n const fetchTotals: boolean = (!this.lastFetchedTotals) || (this._lastFilterUsedInTotals !== searchParamsString);\r\n\r\n this._lastFilterUsedInTotals = searchParamsString;\r\n\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const result = await lastValueFrom(this._allocationDetailRepository.getList(this._dataSourceParams.allocationId, searchParams));\r\n\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals);\r\n\r\n const dataSourceResult = {\r\n rows: _.map(result.data, i => new AllocationDetailGridRowModel(i)),\r\n totalRows: result.totalRows,\r\n lastModifiedTimestamp: result.lastModifiedTimestamp\r\n };\r\n\r\n if (fetchTotals) {\r\n this._getAllRowTotals(params);\r\n }\r\n\r\n return dataSourceResult;\r\n }\r\n\r\n private async _getAllRowTotals(params: IGetRowsParams): Promise {\r\n this._totalsUpdateCallback(this.lastFetchedTotals, false, true);\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n\r\n searchParams.includeTotals = true;\r\n searchParams.includeOnlyTotals = true;\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const result = await lastValueFrom(this._allocationDetailRepository.getList(this._dataSourceParams.allocationId, searchParams));\r\n\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals);\r\n\r\n return result.totals;\r\n }\r\n}\r\n","import { Injectable} from '@angular/core';\r\nimport { DragulaService } from 'ng2-dragula';\r\nimport { Observable, BehaviorSubject, Subject } from 'rxjs';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\n\r\nexport interface AllocationDetailDroppedEvent {\r\n element: Element;\r\n draggedAllocationDetailIds: number[];\r\n}\r\n\r\n@Injectable()\r\nexport class AllocationDetailDragAndDropService {\r\n constructor (private readonly _dragulaService: DragulaService) { }\r\n\r\n private _getAllocationDetailIdsFn: () => Promise;\r\n\r\n private _activeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _draggingSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _draggingOverSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _droppedSubject: Subject = new Subject();\r\n\r\n private _dropComplete: boolean = true;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n readonly BAG_NAME = 'ALLOCATION_DETAIL_DRAG_AND_DROP';\r\n readonly CONTAINER_TYPE_SOURCE = 'ALLOCATION_DETAIL_DRAG_AND_DROP_CONTAINER_TYPE_SOURCE';\r\n readonly CONTAINER_TYPE_TARGET = 'ALLOCATION_DETAIL_DRAG_AND_DROP_CONTAINER_TYPE_TARGET';\r\n\r\n active$: Observable = this._activeSubject.asObservable();\r\n\r\n /**\r\n * An observable that notifies the container being dragged.\r\n */\r\n dragging$: Observable = this._draggingSubject.asObservable();\r\n\r\n /**\r\n * An observable that notifies the container that the mouse is being dragged over.\r\n */\r\n draggingOver$: Observable = this._draggingOverSubject.asObservable();\r\n\r\n /**\r\n * An observable that notifies the container an items gets dropped in.\r\n */\r\n dropped$: Observable = this._droppedSubject.asObservable();\r\n\r\n /**\r\n * Initializes subscriptions to the dragula service and notifies about drag/drop events.\r\n * Because the drag targets are in a grid with an infinity scroll model, the service does not keep track of all available drag targets.\r\n * It takes in a function that returns a list of all selected IDs for the drag targets. This list is made available to the drop event.\r\n */\r\n start(fn: () => Promise): void {\r\n const isStarted = this._dragulaService.find(this.BAG_NAME);\r\n if (isStarted) {\r\n console.warn('Allocation Detail drag-and-drop service is already listening for events.');\r\n return;\r\n }\r\n\r\n this._getAllocationDetailIdsFn = fn;\r\n\r\n this._dragulaService.createGroup(this.BAG_NAME, this.getDragulaOptions());\r\n\r\n // TODO: Use the new events API (https://github.com/valor-software/ng2-dragula/blob/master/MIGRATION-v2.md)\r\n this._dragulaService.drag(this.BAG_NAME).pipe(takeUntil(this._destroy$))\r\n .subscribe(() => this._draggingSubject.next(true));\r\n\r\n this._dragulaService.dragend(this.BAG_NAME).pipe(takeUntil(this._destroy$), filter(() => this._dropComplete))\r\n .subscribe(() => this._draggingSubject.next(false));\r\n\r\n this._dragulaService.over(this.BAG_NAME).pipe(takeUntil(this._destroy$))\r\n .subscribe(value => this._draggingOverSubject.next(value.source));\r\n\r\n this._dragulaService.out(this.BAG_NAME).pipe(takeUntil(this._destroy$))\r\n .subscribe(() => this._draggingOverSubject.next(null));\r\n\r\n // we need to undo the drop event as we don't want the source element to actually move into the target container\r\n // there is currently no support from the library to do that\r\n // it is currently being handled via stylesheets by not displaying the dropped elements\r\n // TODO: cancel drop event or if a parameter gets exposed in the future to not \"actually\" drop the element use that\r\n this._dragulaService.drop(this.BAG_NAME).pipe(takeUntil(this._destroy$)).subscribe(value => {\r\n this._dropComplete = false;\r\n // fetch the allocation detail IDs in order to make them available to the drop event\r\n this._getAllocationDetailIdsFn().then((draggedAllocationDetailIds) => {\r\n const droppedEvent: AllocationDetailDroppedEvent = {\r\n element: value.target,\r\n draggedAllocationDetailIds: draggedAllocationDetailIds\r\n };\r\n this._droppedSubject.next(droppedEvent);\r\n this._dropComplete = true;\r\n this._draggingSubject.next(false);\r\n }, () => { return null; });\r\n });\r\n\r\n this._activeSubject.next(true);\r\n }\r\n\r\n /**\r\n * Disposes subscriptions to the dragula service.\r\n */\r\n stop(): void {\r\n this._activeSubject.next(false);\r\n\r\n this._destroy$.next();\r\n\r\n this._draggingSubject.next(false);\r\n this._draggingOverSubject.next(null);\r\n\r\n this._getAllocationDetailIdsFn = null;\r\n\r\n const isStarted = this._dragulaService.find(this.BAG_NAME);\r\n if (isStarted) {\r\n this._dragulaService.destroy(this.BAG_NAME);\r\n }\r\n }\r\n\r\n getDragulaOptions(): any {\r\n return {\r\n copy: true,\r\n copyItem: (item) => ({ ...item }),\r\n revertOnSpill: true,\r\n removeOnSpill: false,\r\n accepts: (el: Element, target: Element, source: Element, sibling: Element) => target.getAttribute('dragula-container-type') !== this.CONTAINER_TYPE_SOURCE,\r\n moves: (el: Element, target: Element, source: Element, sibling: Element) => target.getAttribute('dragula-container-type') === this.CONTAINER_TYPE_SOURCE\r\n };\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { AgGridMultiSelectTracker } from '../../../AgGrid/MultiSelectTracker';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AllocationDetailDragAndDropService } from './allocationDetailDragAndDrop.service';\r\n\r\nexport interface ICellRendererParamsForAllocationDetailDragAndDropSource extends ICellRendererParams {\r\n tracker: AgGridMultiSelectTracker\r\n}\r\n\r\n@Component({\r\n selector: 'allocation-detail-drag-and-drop-source',\r\n template: `\r\n \r\n \r\n \r\n `\r\n})\r\nexport class AllocationDetailDragAndDropSourceComponent implements ICellRendererAngularComp {\r\n constructor(\r\n private readonly _allocationDetailDragAndDropService: AllocationDetailDragAndDropService\r\n ) {\r\n this.dragulaContainerType = this._allocationDetailDragAndDropService.CONTAINER_TYPE_SOURCE;\r\n this.dragulaBagName = this._allocationDetailDragAndDropService.BAG_NAME;\r\n }\r\n\r\n isServiceActive: boolean;\r\n\r\n params: ICellRendererParamsForAllocationDetailDragAndDropSource;\r\n\r\n dragulaContainerType: string;\r\n dragulaBagName: string;\r\n\r\n private _tracker: AgGridMultiSelectTracker;\r\n private _rowId: number;\r\n private _destroy$: Subject = new Subject();\r\n\r\n\r\n agInit(params: ICellRendererParamsForAllocationDetailDragAndDropSource): void {\r\n this.params = params;\r\n this._tracker = params.tracker;\r\n this._rowId = params.value;\r\n\r\n this._allocationDetailDragAndDropService.active$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.isServiceActive = x);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n isRowSelected(): boolean {\r\n return this._tracker.isRowSelected(this._rowId);\r\n }\r\n}\r\n","import * as _ from 'lodash';\r\n\r\nexport class AssessmentSummaryInfo {\r\n constructor(\r\n private readonly _model: Compliance.AllocationAssessmentSummaryModel) {\r\n }\r\n\r\n private _isSelected: boolean;\r\n\r\n get model(): Compliance.AllocationAssessmentSummaryModel{\r\n return this._model;\r\n }\r\n\r\n get FMV(): number{\r\n return this._model.fmv;\r\n }\r\n\r\n get allocationAmount(): number {\r\n return this._model.allocationAmount;\r\n }\r\n\r\n get assetsCount(): number {\r\n return this._model.assetsCount;\r\n }\r\n\r\n get summaryType(): Compliance.AllocationAssessmentSummaryTypeEnum{\r\n return this._model.summaryType;\r\n }\r\n\r\n get allocationAnnualAssessmentId(): number{\r\n return this._model.allocationAnnualAssessmentId;\r\n }\r\n\r\n get annualAssessmentId(): number{\r\n return this._model.annualAssessmentId;\r\n }\r\n\r\n get parcelAccountNumber(): string{\r\n return this.model.parcelAccountNumber;\r\n }\r\n\r\n get title(): string{\r\n let title: string;\r\n const emptyValuePlaceholder: string = '---';\r\n\r\n if (this._model.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Total){\r\n title = 'Total';\r\n } else if (this._model.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Unassigned){\r\n title = 'Unassigned';\r\n } else if (this._model.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Phantom){\r\n title = this._model.description || emptyValuePlaceholder;\r\n } else {\r\n title = `${this._model.parcelAccountNumber || emptyValuePlaceholder} (${this._model.annualAssessmentRevisionDesc || emptyValuePlaceholder})`;\r\n }\r\n\r\n return title;\r\n }\r\n\r\n get taxAuthorityName(): string {\r\n return this._model.taxAuthorityName;\r\n }\r\n\r\n get variance(): number{\r\n return (this._model.fmv || 0) - (this._model.allocationAmount || 0);\r\n }\r\n\r\n get isLocked(): boolean{\r\n return !!this._model.lockDate;\r\n }\r\n\r\n set isLocked(value: boolean) {\r\n this._model.lockDate = value ? new Date() : null;\r\n }\r\n\r\n get components(): Compliance.AllocationAssessmentSummaryComponentModel[]{\r\n return _.sortBy(this._model.components, ['assessmentComponentTypeId']);\r\n }\r\n\r\n get canLock(): boolean {\r\n return this._model.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal &&\r\n !this.isComitted &&\r\n this.isActual &&\r\n this.variance === 0 &&\r\n !this.isTaxAuthority;\r\n }\r\n\r\n get canReleaseLock(): boolean {\r\n return this._model.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal && this.isLocked;\r\n }\r\n\r\n set isSelected(value: boolean) {\r\n this._isSelected = value;\r\n }\r\n\r\n get isSelected(): boolean {\r\n return this._isSelected;\r\n }\r\n\r\n get canSelect(): boolean {\r\n return this._model.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal ||\r\n this._model.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Phantom;\r\n }\r\n\r\n get assessorName(): string {\r\n return this._model.assessorName;\r\n }\r\n\r\n get canDelete(): boolean {\r\n return this.assetsCount === 0 && this.isTaxAuthority;\r\n }\r\n\r\n get isActual(): boolean {\r\n return this._model.isActual;\r\n }\r\n\r\n get companyId(): number {\r\n return this._model.companyId;\r\n }\r\n\r\n get siteId(): number {\r\n return this._model.siteId;\r\n }\r\n\r\n get annualYearId(): number {\r\n return this._model.annualYearId;\r\n }\r\n\r\n get parcelId(): number {\r\n return this._model.parcelId;\r\n }\r\n\r\n get description(): string {\r\n return this._model.description;\r\n }\r\n\r\n get parcelAccountNumber2(): string {\r\n return this._model.parcelAccountNumber2;\r\n }\r\n\r\n get parcelAddress1(): string {\r\n return this._model.parcelAddress1;\r\n }\r\n\r\n get parcelAddress2(): string {\r\n return this._model.parcelAddress2;\r\n }\r\n get parcelCity(): string {\r\n return this._model.parcelCity;\r\n }\r\n\r\n get parcelState(): string {\r\n return this._model.parcelState;\r\n }\r\n\r\n get parcelZip(): string {\r\n return this._model.parcelZip;\r\n }\r\n\r\n static isEqual(item1: AssessmentSummaryInfo, item2: AssessmentSummaryInfo): boolean {\r\n return !!item1 && !!item2 && (\r\n item1.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal &&\r\n item2.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal &&\r\n item1.allocationAnnualAssessmentId === item2.allocationAnnualAssessmentId ||\r\n item1.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Phantom &&\r\n item2.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Phantom &&\r\n item1.allocationAnnualAssessmentId === item2.allocationAnnualAssessmentId ||\r\n item1.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Unassigned &&\r\n item2.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Unassigned &&\r\n item1.summaryType === item2.summaryType ||\r\n item1.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Total &&\r\n item2.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Total &&\r\n item1.summaryType === item2.summaryType\r\n );\r\n }\r\n\r\n get hasActiveAppeal(): boolean {\r\n return this._model.hasActiveAppeal;\r\n }\r\n\r\n get isTaxAuthority(): boolean {\r\n return !!this._model.taxAuthorityId;\r\n }\r\n\r\n get taxAuthoritiesCount(): number {\r\n return this._model.taxAuthoritiesCount;\r\n }\r\n\r\n get sortByName(): string {\r\n return `${this.title }${`Z${ this.taxAuthorityName || ''}`}`;\r\n }\r\n\r\n get isMarkedAsReviewed(): boolean {\r\n return this._model.isMarkedAsReviewed;\r\n }\r\n\r\n get isComitted(): boolean {\r\n return this._model.isCommitted;\r\n }\r\n}\r\n"," 0\">\r\n\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../../Busy-Indicator';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../AgGrid';\r\nimport { AllocationRepository } from '../../../Repositories';\r\nimport { AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectTracker } from '../../../AgGrid/MultiSelectTracker';\r\nimport { lastValueFrom, Subscription } from 'rxjs';\r\n\r\nexport interface AddTaxAuthorityParams {\r\n allocationId: number,\r\n showWarning: boolean\r\n}\r\n\r\nexport interface AddTaxAuthorityResult {\r\n newSummaries: Compliance.AllocationAssessmentSummaryModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'add-tax-authority',\r\n templateUrl: './addTaxAuthority.component.html',\r\n styleUrls: ['./addTaxAuthority.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class AddTaxAuthorityComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(private readonly _modalRef: BsModalRef,\r\n private readonly _allocationRepository: AllocationRepository) {\r\n }\r\n\r\n params: AddTaxAuthorityParams;\r\n result: AddTaxAuthorityResult;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n gridTracker: AgGridMultiSelectTracker;\r\n showWarning: boolean;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged()\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withSort()\r\n .withTextSelection()\r\n .withFloatingFilter()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _taxAuthorities: Compliance.TaxAuthorityModel[];\r\n private _selectedRowsSub: Subscription;\r\n private _selectedRows: number[] = [];\r\n\r\n\r\n async ngOnInit(): Promise {\r\n const busyMsgId = 'loading';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsgId);\r\n this.showWarning = this.params.showWarning;\r\n\r\n try {\r\n this._taxAuthorities = await lastValueFrom(this._allocationRepository.getTaxAuthorities(this.params.allocationId));\r\n this._setRowData();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe((selected: Compliance.SelectedRowsModel) => {\r\n this._selectedRows = (selected.selectAllRows) ? this._taxAuthorities.map(f => f.taxAuthorityId) : selected.selectedRows;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'taxAuthorityId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n },\r\n {\r\n headerName: 'Collector',\r\n field: 'collector',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Name',\r\n field: 'name',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Code',\r\n field: 'code',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'collector',\r\n sort: 'asc'\r\n },\r\n {\r\n colId: 'name',\r\n sort: 'asc'\r\n },\r\n {\r\n colId: 'code',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.sizeColumnsToFit();\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgId = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgId);\r\n\r\n try {\r\n const newAssessmentSummaries = await lastValueFrom(this._allocationRepository.addTaxAuthorities(this.params.allocationId, this._selectedRows));\r\n\r\n this.result = {newSummaries: newAssessmentSummaries} as AddTaxAuthorityResult;\r\n\r\n this._modalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n const queryResultModel: Compliance.QueryResultModel = {\r\n lastModifiedTimestamp: new Date(),\r\n totalRows: rows.length,\r\n totalValidRows: rows.length,\r\n data: rows.map((x) => {\r\n const taxAuthority = x.data as Compliance.TaxAuthorityModel;\r\n return taxAuthority && taxAuthority.taxAuthorityId;\r\n })\r\n };\r\n\r\n return Promise.resolve(queryResultModel);\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._taxAuthorities)) {\r\n return;\r\n }\r\n\r\n this.gridTracker && this.gridTracker.clear();\r\n\r\n this._gridApi.setRowData(this._taxAuthorities);\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { IEntityPicker } from './entityPicker';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AgGridOptionsBuilder } from '../AgGrid';\r\nimport { GridApi, GridReadyEvent, ColDef, GridOptions } from 'ag-grid-community';\r\nimport { BusyIndicatorMessageManager } from '../../Busy-Indicator';\r\n\r\nexport interface EntityPickerComponentParams {\r\n entityPicker: IEntityPicker;\r\n titleOverride?: string;\r\n optionFlagText?: string;\r\n optionFlagValue?: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'entity-picker',\r\n templateUrl: './entityPicker.component.html'\r\n})\r\nexport class EntityPickerComponent implements OnInit {\r\n constructor(private readonly _bsModalRef: BsModalRef) { }\r\n\r\n @Input() params: EntityPickerComponentParams;\r\n title: string;\r\n\r\n private _gridApi: GridApi;\r\n\r\n entityPicker: IEntityPicker;\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && params.data.isSelected\r\n }\r\n })\r\n .withContext(this)\r\n .withInfiniteScroll()\r\n .withSingleRowSelect()\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withFloatingFilter()\r\n .withTextSelection()\r\n .build();\r\n\r\n get rowsSelected(): boolean {\r\n return (this.entityPicker && this.entityPicker.getSelectedIds().size > 0);\r\n }\r\n\r\n ngOnInit(): void {\r\n if (this.params) {\r\n this.entityPicker = this.params.entityPicker;\r\n this.title = this.params.titleOverride ? this.params.titleOverride : this.entityPicker.title;\r\n\r\n if (this.params.optionFlagValue != null) {\r\n this.entityPicker.optionFlag = this.params.optionFlagValue;\r\n }\r\n\r\n }\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = this.entityPicker.getColDefs();\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setDatasource(this.entityPicker.getDataSource(this._gridApi));\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n save(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n getResult(): any {\r\n return this.entityPicker.getResult();\r\n }\r\n}\r\n","import { ColDef, IDatasource, IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult, AgGridColumns } from '../AgGrid';\r\nimport { AgGridCheckboxCellRendererComponent, ICellRendererParamsForAgGridCheckbox } from '../AgGrid/CellRenderers/agGridCheckboxCellRender.component';\r\n\r\nexport interface IEntityPickerResult {\r\n result: T;\r\n}\r\n\r\nexport interface IEntityPicker {\r\n getModalClass(): string;\r\n getDataSource(gridApi: GridApi): IDatasource;\r\n getColDefs(): ColDef[];\r\n getSelectedIds(): Set;\r\n getResult(): IEntityPickerResult;\r\n optionFlagChange(): void;\r\n title: string;\r\n optionFlagText: string;\r\n optionFlag: boolean;\r\n}\r\n\r\nclass EntityPickerDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n gridApi: GridApi,\r\n private readonly _propertyMap: Compliance.NameValuePair[],\r\n private readonly _getRowsFunction: (params: IGetRowsParams, paginatedSearchModel: any) => Promise) {\r\n super(gridApi);\r\n }\r\n\r\n canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const paginatedSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n\r\n const result = await this._getRowsFunction(params, paginatedSearchModel);\r\n this.gridApi.sizeColumnsToFit();\r\n\r\n return result;\r\n }\r\n}\r\n\r\nexport abstract class EntityPicker implements IEntityPicker {\r\n protected constructor(protected searchModel: any) {\r\n }\r\n\r\n protected selectedIds: Set = new Set();\r\n protected abstract propertyMap: Compliance.NameValuePair[];\r\n protected dataSource: AgGridDataSourceBase;\r\n protected idRowDataField: string = 'id';\r\n protected singleSelectColDef: ColDef = {\r\n field: 'isSelected',\r\n headerName: '',\r\n width: AgGridColumns.selectionColumnWidth,\r\n minWidth: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n onValueChanged: this.onSelectEdited.bind(this),\r\n isVisible: this.isSelectVisible.bind(this),\r\n canEdit: this.isSelectEditable.bind(this),\r\n canEnterEditMode: this.isSelectEditable.bind(this),\r\n } as ICellRendererParamsForAgGridCheckbox\r\n };\r\n protected singleSelector = true;\r\n protected singleSelectedEntity: T;\r\n\r\n optionFlagText: string;\r\n optionFlag: boolean;\r\n title = 'Choose Entity';\r\n\r\n getModalClass() {\r\n return 'modal-sm';\r\n }\r\n\r\n getSelectedIds() {\r\n return this.selectedIds;\r\n }\r\n\r\n protected abstract getRowsInternal(params: IGetRowsParams, paginatedSearchModel: any): Promise;\r\n\r\n protected addSelectedFlag(dataEntry) {\r\n dataEntry.isSelected = false; // later - apply pre-selected from a parameter\r\n return dataEntry;\r\n }\r\n\r\n protected getIdFromRow(params): string {\r\n if (params.data) {\r\n return params.data[this.idRowDataField];\r\n }\r\n return null;\r\n }\r\n\r\n protected onSelectEdited(params, selected) {\r\n if (selected) {\r\n this.storeSelection(params);\r\n } else {\r\n this.removeSelection(params);\r\n }\r\n }\r\n\r\n protected storeSelection(params) {\r\n const id = this.getIdFromRow(params);\r\n if (this.singleSelector) {\r\n // clear other selections\r\n if (this.dataSource) {\r\n this.dataSource.getShownRows().forEach((node) => {\r\n const nodeId = this.getIdFromRow({ data: node });\r\n node.isSelected = id === nodeId;\r\n });\r\n }\r\n this.singleSelectedEntity = params.data as T;\r\n }\r\n this.selectedIds.add(id);\r\n this.dataSource.gridApi.redrawRows();\r\n }\r\n\r\n protected removeSelection(params) {\r\n const id = this.getIdFromRow(params.data);\r\n this.selectedIds.delete(id);\r\n if (this.singleSelector) {\r\n this.singleSelectedEntity = null;\r\n }\r\n this.dataSource.gridApi.redrawRows();\r\n }\r\n\r\n protected isSelectVisible() {\r\n return true;\r\n }\r\n\r\n protected isSelectEditable() {\r\n return true;\r\n }\r\n\r\n getResult(): IEntityPickerResult {\r\n return {\r\n result: this.singleSelectedEntity,\r\n optionFlag: this.optionFlag\r\n } as IEntityPickerResult;\r\n }\r\n\r\n getDataSource(gridApi: GridApi): IDatasource {\r\n if (!this.dataSource) {\r\n this.dataSource = new EntityPickerDataSource(gridApi, this.propertyMap, this.getRowsInternal.bind(this));\r\n }\r\n return this.dataSource;\r\n }\r\n\r\n abstract optionFlagChange();\r\n abstract getColDefs();\r\n}\r\n","import { ColDef, IGetRowsParams } from 'ag-grid-community';\r\nimport { AgGridFilterParams } from '../AgGrid/agGridFilterParams';\r\nimport { AgGridColumns } from '../AgGrid/agGridColumns';\r\nimport { EntityPicker } from './entityPicker';\r\nimport { AgGridDataSourceResult } from '../AgGrid';\r\n\r\nexport class ParcelPicker extends EntityPicker {\r\n constructor(\r\n private reportingParcelSearchModel: Compliance.ReportingParcelSearchModel,\r\n private _siteIds: number[],\r\n private _masterSiteIds: number[],\r\n private _selectedReportingParcelSiteId: number,\r\n private _getParcels: (searchParams: any) => Promise>,\r\n optionFlagText: string) {\r\n super(reportingParcelSearchModel);\r\n this.title = 'Parcels';\r\n this.idRowDataField = 'parcelId';\r\n this.siteIds = _siteIds;\r\n this.masterSiteIds = _masterSiteIds;\r\n this.optionFlag = true;\r\n this.optionFlagText = optionFlagText;\r\n }\r\n\r\n protected readonly propertyMap = [\r\n { name: 'companyName', value: Compliance.ReportingParcelPropertyEnum.CompanyName },\r\n { name: 'parcelAcctNumWithStatus', value: Compliance.ReportingParcelPropertyEnum.ParcelAcctNumWithStatus },\r\n { name: 'siteName', value: Compliance.ReportingParcelPropertyEnum.SiteName },\r\n { name: 'state', value: Compliance.ReportingParcelPropertyEnum.State }\r\n ];\r\n\r\n searchModel: Compliance.ReportingParcelSearchModel;\r\n siteIds: number[];\r\n masterSiteIds: number[];\r\n\r\n getColDefs(): ColDef[] {\r\n return [\r\n this.singleSelectColDef,\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Parcel Number',\r\n field: 'parcelAcctNumWithStatus',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n }\r\n ]\r\n }\r\n\r\n optionFlagChange(): void {\r\n this.dataSource.refresh();\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams, paginatedSearchModel: any): Promise {\r\n if(this.optionFlag && this.siteIds) {\r\n this.reportingParcelSearchModel.includeSiteIds = this.siteIds.concat(this.masterSiteIds.filter(x => x != null));\r\n } else {\r\n this.reportingParcelSearchModel.includeSiteIds = [];\r\n }\r\n\r\n var result = await this._getParcels(Object.assign(paginatedSearchModel, this.reportingParcelSearchModel));\r\n\r\n return {\r\n rows: result.data.map(this.addSelectedFlag),\r\n totalRows: result.data.length\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n public getModalClass() {\r\n return 'modal-lg';\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { WeissmanModalService } from '../WeissmanModalService';\r\nimport { BsModalService, BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { EntityPicker, IEntityPickerResult } from './entityPicker';\r\nimport { EntityPickerComponent } from './entityPicker.component';\r\nimport { ParcelPicker } from './parcelPicker';\r\n\r\nexport interface IEntityPickerService {\r\n showParcelPicker: (searchModel: Compliance.ReportingParcelSearchModel, siteIds: number[], masterSiteIds: number[],\r\n selectedReportingParcelSiteId: number,\r\n getParcels: (searchParams: any) => Promise>,\r\n optionFlagText: string)\r\n => Promise>;\r\n}\r\n\r\n@Injectable()\r\nexport class EntityPickerService implements IEntityPickerService {\r\n constructor(\r\n private readonly _weissmanModalService: WeissmanModalService,\r\n private readonly _modalService: BsModalService,\r\n ) { }\r\n\r\n async showParcelPicker(searchModel: Compliance.ReportingParcelSearchModel, siteIds: number[], masterSiteIds: number[] = [],\r\n selectedReportingParcelSiteId: number = null,\r\n getParcels: (searchParams: any) => Promise>,\r\n optionFlagText: string)\r\n : Promise> {\r\n const picker = new ParcelPicker(searchModel, siteIds, masterSiteIds, selectedReportingParcelSiteId, getParcels, optionFlagText);\r\n const result = await this._showEntityPicker(picker);\r\n return result;\r\n }\r\n\r\n private async _showEntityPicker(picker: EntityPicker): Promise> {\r\n const showModalFn = (): BsModalRef => {\r\n return this._modalService.show(EntityPickerComponent, {\r\n class: picker.getModalClass(),\r\n initialState: {\r\n params: {\r\n entityPicker: picker\r\n }\r\n }\r\n });\r\n }\r\n\r\n let result: IEntityPickerResult;\r\n try {\r\n await this._weissmanModalService.show(showModalFn.bind(this)).whenClosed.then(bsModalRef => {\r\n const componentResult = (bsModalRef.content as EntityPickerComponent).getResult();\r\n result = componentResult as IEntityPickerResult;\r\n }, () => {});\r\n } catch (e) {\r\n return null;\r\n }\r\n\r\n return result;\r\n }\r\n}\r\n","\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'allocation-detail-bulk-update-action',\r\n templateUrl: './allocationDetailBulkUpdateAction.component.html',\r\n styles: ['select {width:120px}']\r\n})\r\nexport class AllocationDetailBulkUpdateActionComponent implements OnInit{\r\n constructor(\r\n ){\r\n this.possibleActions = [\r\n { name: 'No Change', value: Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange },\r\n { name: 'Change To', value: Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo },\r\n { name: 'Set to Blank', value: Compliance.AllocationDetailBulkUpdateFieldActionEnum.SetToBlank },\r\n { name: 'Remove Override', value: Compliance.AllocationDetailBulkUpdateFieldActionEnum.RemoveOverride },\r\n { name: 'Copy Return/Reported Value', value: Compliance.AllocationDetailBulkUpdateFieldActionEnum.CopyReturnValue },\r\n { name: 'Distribute Variance', value: Compliance.AllocationDetailBulkUpdateFieldActionEnum.DistributeVariance }\r\n ];\r\n }\r\n\r\n @Input()\r\n set fieldAction(fieldAction: Compliance.AllocationDetailBulkUpdateFieldActionEnum) {\r\n this.fieldActionChanged(fieldAction);\r\n }\r\n\r\n @Output() fieldActionChange = new EventEmitter();\r\n @Input() requiredField: boolean = false;\r\n @Input() fieldHasOverrides: boolean = false;\r\n @Input() verifyField: boolean = false;\r\n @Input() disabled: boolean;\r\n @Input() isInitialAllocationAmount: boolean;\r\n @Input() isFinalAllocationAmount: boolean;\r\n\r\n action: Compliance.AllocationDetailBulkUpdateFieldActionEnum;\r\n possibleActions: Compliance.NameValuePair[];\r\n selectedAction: Compliance.AllocationDetailBulkUpdateFieldActionEnum = Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange;\r\n\r\n ngOnInit(): void {\r\n if (this.requiredField){\r\n this.possibleActions = this.possibleActions.filter(i => i.value !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.SetToBlank);\r\n }\r\n\r\n if (!this.fieldHasOverrides){\r\n this.possibleActions = this.possibleActions.filter(i => i.value !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.RemoveOverride);\r\n }\r\n\r\n if (this.isInitialAllocationAmount) {\r\n this.possibleActions = this.possibleActions.filter(i => i.value !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.DistributeVariance);\r\n } else if (!this.isFinalAllocationAmount) {\r\n this.possibleActions = this.possibleActions.filter(i => i.value !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.CopyReturnValue &&\r\n i.value !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.DistributeVariance);\r\n }\r\n }\r\n\r\n fieldActionChanged(action: Compliance.AllocationDetailBulkUpdateFieldActionEnum): void {\r\n if (action || action === Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange) {\r\n this.selectedAction = action;\r\n this.fieldActionChange.next(action);\r\n } else {\r\n this.selectedAction = Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n }\r\n\r\n isSelected(action: Compliance.AllocationDetailBulkUpdateFieldActionEnum): boolean{\r\n return action === Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n}\r\n"," 0\">\r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Initial Allocation Amount\r\n \r\n \r\n \r\n \r\n \r\n
Final Allocation Amount\r\n \r\n \r\n \r\n \r\n \r\n
Parcel\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
Status\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
Reconciled\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, KeyValueDiffers, OnInit, Renderer2, ViewChild } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../../../UI-Lib/Pipes';\r\nimport { MessageModalService } from '../../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { EntityPickerService } from '../../../Entity-Picker/entityPicker.service';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { AllocationDetailRepository } from '../../../Repositories/allocationDetail.repository';\r\nimport { AssessmentSummaryInfo } from '../assessmentSummaryInfo';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface AllocationDetailBulkUpdateParams {\r\n allocationId: number;\r\n selection: Compliance.SelectedRowsModel;\r\n selectedCount: number;\r\n allocationDetailListLastModifiedTimestamp: Date;\r\n statuses: Compliance.AllocationDetailStatusModel[];\r\n assessmentsSummary: AssessmentSummaryInfo[];\r\n removeExistingAllocations: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'allocation-detail-bulk-update',\r\n templateUrl: './allocationDetailBulkUpdate.component.html',\r\n})\r\nexport class AllocationDetailBulkUpdateComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _allocationDetailRepository: AllocationDetailRepository,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe,\r\n private readonly _entityPickerService: EntityPickerService,\r\n private readonly _differs: KeyValueDiffers,\r\n private readonly _renderer: Renderer2,\r\n private readonly _decimalPipe: DecimalPipe\r\n ) { }\r\n\r\n @ViewChild('bulkUpdateFieldContainer', { static: true }) bulkUpdateFormElement;\r\n\r\n params: AllocationDetailBulkUpdateParams;\r\n result: boolean;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n bulkUpdateModel: Compliance.AllocationDetailBulkUpdateModel;\r\n\r\n busyRefId: string = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n\r\n private _assessmentsSummary: AssessmentSummaryInfo[] = null;\r\n private _assessmentSummaryInfo: AssessmentSummaryInfo = null;\r\n\r\n\r\n get selectedCount(): string {\r\n return this._decimalPipe.transform(this.params.selectedCount);\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n const busyLoading = 'load-Metadata';\r\n this.busyIndicatorMessageManager.add('Loading', busyLoading);\r\n\r\n try {\r\n this._assessmentsSummary = _\r\n .cloneDeep(this.params.assessmentsSummary)\r\n .filter(x => !x.isComitted);\r\n _.orderBy(this._assessmentsSummary, x => `${x.title }${`Z${ x.taxAuthorityName || ''}`}`);\r\n\r\n this._assessmentsSummary.splice(0, 0,\r\n new AssessmentSummaryInfo({summaryType: Compliance.AllocationAssessmentSummaryTypeEnum.Unassigned} as Compliance.AllocationAssessmentSummaryModel));\r\n\r\n this.bulkUpdateModel = {\r\n allocationId: this.params.allocationId,\r\n selectedRows: this.params.selection.selectedRows,\r\n selectAllRows: this.params.selection.selectAllRows,\r\n lastModifiedTimestamp: this.params.allocationDetailListLastModifiedTimestamp,\r\n isReconciledAction: Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange,\r\n allocationAction: Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange,\r\n statusAction: Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange,\r\n initialAllocationAmountAction: Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange,\r\n finalAllocationAmountAction: Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange\r\n } as Compliance.AllocationDetailBulkUpdateModel;\r\n }\r\n finally{\r\n this.busyIndicatorMessageManager.remove(busyLoading);\r\n }\r\n }\r\n\r\n get isValid(): boolean {\r\n const initialAllocationAmountSelectionValid =\r\n this.bulkUpdateModel.initialAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo &&\r\n !!this.bulkUpdateModel.initialAllocationAmount ||\r\n this.bulkUpdateModel.initialAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.RemoveOverride ||\r\n this.bulkUpdateModel.initialAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.SetToBlank ||\r\n this.bulkUpdateModel.initialAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange ||\r\n this.bulkUpdateModel.initialAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.CopyReturnValue;\r\n\r\n const finalAllocationAmountSelectionValid =\r\n this.bulkUpdateModel.finalAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo &&\r\n !!this.bulkUpdateModel.finalAllocationAmount ||\r\n this.bulkUpdateModel.finalAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.RemoveOverride ||\r\n this.bulkUpdateModel.finalAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.SetToBlank ||\r\n this.bulkUpdateModel.finalAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange ||\r\n this.bulkUpdateModel.finalAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.CopyReturnValue ||\r\n this.bulkUpdateModel.finalAllocationAmountAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.DistributeVariance;\r\n\r\n const allocationSelectionValid =\r\n this.bulkUpdateModel.allocationAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo &&\r\n !!this._assessmentsSummary ||\r\n this.bulkUpdateModel.allocationAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.RemoveOverride ||\r\n this.bulkUpdateModel.allocationAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.SetToBlank ||\r\n this.bulkUpdateModel.allocationAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange;\r\n\r\n const statusSelectionValid =\r\n this.bulkUpdateModel.statusAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo &&\r\n !!this.bulkUpdateModel.status ||\r\n this.bulkUpdateModel.statusAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.SetToBlank ||\r\n this.bulkUpdateModel.statusAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange;\r\n\r\n const isReconciledSelectionValid =\r\n this.bulkUpdateModel.isReconciledAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo &&\r\n this.bulkUpdateModel.isReconciled !== null ||\r\n this.bulkUpdateModel.isReconciledAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.SetToBlank ||\r\n this.bulkUpdateModel.isReconciledAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange;\r\n\r\n const atLeastOneItemChanged = this.bulkUpdateModel.initialAllocationAmountAction !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange ||\r\n this.bulkUpdateModel.finalAllocationAmountAction !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange ||\r\n this.bulkUpdateModel.allocationAction !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange ||\r\n this.bulkUpdateModel.statusAction !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange ||\r\n this.bulkUpdateModel.isReconciledAction !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.NoChange;\r\n\r\n return initialAllocationAmountSelectionValid && finalAllocationAmountSelectionValid && allocationSelectionValid &&\r\n statusSelectionValid && isReconciledSelectionValid && atLeastOneItemChanged;\r\n }\r\n\r\n get assessmentsSummary(): AssessmentSummaryInfo[]{\r\n return this._assessmentsSummary;\r\n }\r\n\r\n get assessmentSummary(): AssessmentSummaryInfo{\r\n return this._assessmentSummaryInfo;\r\n }\r\n\r\n set assessmentSummary(value: AssessmentSummaryInfo) {\r\n if (value.allocationAnnualAssessmentId) {\r\n this._assessmentSummaryInfo = value;\r\n this.bulkUpdateModel.allocation = {\r\n lastModifiedTimestamp: this.params.allocationDetailListLastModifiedTimestamp,\r\n selectedRows: this.params.selection.selectedRows,\r\n selectAllRows: this.params.selection.selectAllRows,\r\n allocationAnnualAssessmentIds: [this._assessmentSummaryInfo.allocationAnnualAssessmentId]\r\n } as Compliance.AllocationDetailAllocateModel;\r\n } else {\r\n this._assessmentSummaryInfo = null;\r\n this.bulkUpdateModel.allocation = null;\r\n }\r\n }\r\n\r\n async save(force: boolean = false): Promise {\r\n if (!force && this.bulkUpdateModel.allocationAction === Compliance.AllocationDetailBulkUpdateFieldActionEnum.RemoveOverride) {\r\n this.bulkUpdateModel.allocation = {\r\n allocationAnnualAssessmentIds: null,\r\n lastModifiedTimestamp: this.params.allocationDetailListLastModifiedTimestamp,\r\n selectedRows: this.params.selection.selectedRows,\r\n selectAllRows: this.params.selection.selectAllRows\r\n };\r\n }\r\n\r\n const busyLoading = 'updating';\r\n this.busyIndicatorMessageManager.add('Updating Assets', busyLoading);\r\n\r\n let confirmMessage: string = '';\r\n\r\n try {\r\n this.bulkUpdateModel.force = force;\r\n\r\n await lastValueFrom(this._allocationDetailRepository.bulkUpdate(this.params.allocationId, this.bulkUpdateModel));\r\n\r\n this.result = true;\r\n this._bsModalRef.hide();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n confirmMessage = e2.error.message;\r\n } finally{\r\n this.busyIndicatorMessageManager.remove(busyLoading);\r\n }\r\n\r\n if (confirmMessage) {\r\n try {\r\n await this._messageModalService.confirm(confirmMessage, 'Confirm Update');\r\n } catch (e3) {\r\n return Promise.resolve();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyLoading);\r\n }\r\n\r\n // force\r\n await this.save(true);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n isDisabled(action: Compliance.AllocationDetailBulkUpdateFieldActionEnum){\r\n return action !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo &&\r\n action !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.DistributeVariance;\r\n }\r\n\r\n initialAllocationAmountActionChanged(action: Compliance.AllocationDetailBulkUpdateFieldActionEnum) {\r\n if (action !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo){\r\n this.bulkUpdateModel.initialAllocationAmount = null;\r\n }\r\n }\r\n\r\n finalAllocationAmountActionChanged(action: Compliance.AllocationDetailBulkUpdateFieldActionEnum) {\r\n if (action !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo){\r\n this.bulkUpdateModel.finalAllocationAmount = null;\r\n }\r\n }\r\n\r\n parcelActionChanged(action: Compliance.AllocationDetailBulkUpdateFieldActionEnum) {\r\n if (action !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo){\r\n this.bulkUpdateModel.allocation = null;\r\n }\r\n }\r\n\r\n statusActionChanged(action: Compliance.AllocationDetailBulkUpdateFieldActionEnum) {\r\n if (action !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo){\r\n this.bulkUpdateModel.status = null;\r\n }\r\n }\r\n\r\n isReconciledActionChanged(action: Compliance.AllocationDetailBulkUpdateFieldActionEnum) {\r\n if (action !== Compliance.AllocationDetailBulkUpdateFieldActionEnum.ChangeTo){\r\n this.bulkUpdateModel.isReconciled = null;\r\n }\r\n }\r\n\r\n getParcelOptionText(option: AssessmentSummaryInfo): string{\r\n return option.isTaxAuthority ? `\\xA0\\xA0${option.taxAuthorityName}` : option.title;\r\n }\r\n}\r\n"," 0\">\r\n\r\n
\r\n
\r\n
\r\n
Site:
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
Assessor:
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
Collectors:
\r\n
\r\n \r\n \r\n
The same collector cannot be selected more than once.
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AllocationRepository } from '../../../Repositories';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { BusyIndicatorMessageManager } from '../../../../Busy-Indicator';\r\nimport { AbstractControl, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\r\n\r\nexport interface CreateNewMergedParcelsParams{\r\n allocationId: number,\r\n allocationDetailSelectRowsModel?: Compliance.SelectedRowsModel,\r\n selectedAssessmentSummaryIds?: number[]\r\n}\r\n\r\nexport interface CreateNewMergedParcelsResult {\r\n assessmentsSummary: Compliance.AllocationAssessmentSummaryModel[]\r\n}\r\n\r\nexport class CollectorOption {\r\n id: number;\r\n name: string;\r\n isDefault: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'create-new-merged-parcels',\r\n templateUrl: './create-new-merged-parcels.component.html'\r\n})\r\nexport class CreateNewMergedParcelsComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _modalRef: BsModalRef,\r\n private readonly _allocationRepository: AllocationRepository) {\r\n }\r\n\r\n params: CreateNewMergedParcelsParams;\r\n result: CreateNewMergedParcelsResult;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n form: UntypedFormGroup;\r\n\r\n collectorErrorMessage: string;\r\n\r\n private _allocationAnnualAssessmentIds: number[];\r\n private _sites: Compliance.AllocationGetCreateNewMergedParcelsMetadataResultSite[] = [];\r\n private _assessors: Compliance.AllocationGetCreateNewMergedParcelsMetadataResultAssessor[] = [];\r\n private _collectors: Compliance.AllocationGetCreateNewMergedParcelsMetadataResultCollector[] = [];\r\n private _filteredCollectors: CollectorOption[] = [];\r\n\r\n async ngOnInit(): Promise {\r\n const busyMsgId = 'loading';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsgId);\r\n\r\n this.form = new UntypedFormGroup({\r\n site: new UntypedFormControl(null, [Validators.required]),\r\n assessor: new UntypedFormControl(null, [Validators.required]),\r\n collector: new UntypedFormControl(null, [Validators.required, this.validateCollectorSelection])\r\n });\r\n\r\n try {\r\n let selectedRowsModel: Compliance.SelectedRowsModel;\r\n\r\n if (this.params.allocationDetailSelectRowsModel)\r\n {\r\n selectedRowsModel = {\r\n selectedRows: this.params.allocationDetailSelectRowsModel.selectedRows,\r\n selectAllRows: this.params.allocationDetailSelectRowsModel.selectAllRows\r\n };\r\n }\r\n\r\n const metadata = await lastValueFrom(this._allocationRepository.getCreateNewMergedParcelsMetadata(this.params.allocationId, selectedRowsModel));\r\n this._sites = metadata.sites;\r\n this._assessors = metadata.assessors;\r\n this._collectors = metadata.collectors;\r\n this._allocationAnnualAssessmentIds = this.params.allocationDetailSelectRowsModel\r\n ? metadata.allocationAnnualAssessmentIds\r\n : this.params.selectedAssessmentSummaryIds;\r\n\r\n if (this._sites.length === 1){\r\n this.form.controls['site'].setValue(this._sites[0].siteId);\r\n this.form.controls['site'].disable({emitEvent: false});\r\n } else {\r\n this._sites.sort((i, j) =>\r\n i.siteName < j.siteName ? -1 : i.siteName > j.siteName ? 1 : 0);\r\n }\r\n\r\n if (this._assessors.length === 1){\r\n this.form.controls['assessor'].setValue(this._assessors[0].assessorId);\r\n this.form.controls['assessor'].disable({emitEvent: false});\r\n } else {\r\n this._assessors.sort((i, j) =>\r\n i.assessorName < j.assessorName ? -1 : i.assessorName > j.assessorName ? 1 : 0);\r\n }\r\n\r\n this._filterCollectors();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n get sites(): Compliance.AllocationGetCreateNewMergedParcelsMetadataResultSite[] {\r\n return this._sites;\r\n }\r\n\r\n get assessors(): Compliance.AllocationGetCreateNewMergedParcelsMetadataResultAssessor[]{\r\n return this._assessors;\r\n }\r\n\r\n get collectors(): CollectorOption[] {\r\n return this._filteredCollectors;\r\n }\r\n\r\n onSiteChanged(): void {\r\n if (this._sites.length >= 1){\r\n this.form.controls['assessor'].setValue(null);\r\n }\r\n }\r\n\r\n onAssessorChange(): void {\r\n this._filterCollectors();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgId = 'saving';\r\n this.busyIndicatorMessageManager.add('Creating parcels', busyMsgId);\r\n\r\n try{\r\n const model: Compliance.AllocationCreateMergedParcelsModel = {\r\n siteId: this.form.controls['site'].value,\r\n assessorId: this.form.controls['assessor'].value,\r\n collectorBillScenarioIds: this.form.controls['collector'].value,\r\n allocationAnnualAssessmentIds: this._allocationAnnualAssessmentIds\r\n };\r\n\r\n const result = await lastValueFrom(this._allocationRepository.createNewMergedParcels(this.params.allocationId, model));\r\n\r\n this.result = {\r\n assessmentsSummary: result\r\n };\r\n\r\n this._modalRef.hide();\r\n }\r\n finally{\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n get isFormValid(): boolean {\r\n return this.form.valid;\r\n }\r\n\r\n validateCollectorSelection = (control: AbstractControl): {[key: string]: any} | null => {\r\n if (control.value && (control.value as []).length !== 0) {\r\n const selectedBillScenarioIds = control.value as number[];\r\n const selectedCollectorBillScenarios = this._collectors.filter(i => i.assessorId === +this.form.get('assessor').value &&\r\n selectedBillScenarioIds.indexOf(i.collectorBillScenarioId) !== -1);\r\n const collectors = selectedCollectorBillScenarios.reduce((i, j) => {\r\n i[j.collectorId] = [...i[j.collectorId] || [], j];\r\n return i;\r\n }, []);\r\n\r\n if (collectors.filter(i => i.length > 1).length !== 0){\r\n return { 'collectorHasDuplicatesSelected': true };\r\n }\r\n }\r\n\r\n return null;\r\n };\r\n\r\n private _filterCollectors(): void {\r\n this._filteredCollectors = this._collectors\r\n .filter(i => i.siteId === +this.form.controls['site'].value &&\r\n i.assessorId === +this.form.controls['assessor'].value)\r\n .map(i => { return {\r\n id: i.collectorBillScenarioId,\r\n name: i.collectorBillScenarioName ? `${i.collectorName} - ${i.collectorBillScenarioName}` : `${i.collectorName}`,\r\n isDefault: i.isDefault} as CollectorOption;\r\n })\r\n .sort((i, j) => i.name < j.name ? -1 : i.name > j.name ? 1 : 0);\r\n\r\n if (this._filteredCollectors.length === 0){\r\n this.form.controls['collector'].disable({emitEvent: false});\r\n } else {\r\n this.form.controls['collector'].enable({emitEvent: false});\r\n\r\n const defaultCollectors = this._filteredCollectors.filter(i => i.isDefault).map(i => i.id);\r\n this.form.controls['collector'].setValue(defaultCollectors);\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForAllocationDetailListGridAction extends ICellRendererParams {\r\n canView: (params: ICellRendererParamsForAllocationDetailListGridAction) => boolean;\r\n viewDetails: (params: ICellRendererParamsForAllocationDetailListGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n ``\r\n})\r\n\r\nexport class AllocationDetailListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n\r\n allocationDetail: Compliance.AllocationDetailModel;\r\n canView: boolean = false;\r\n\r\n private _params: ICellRendererParamsForAllocationDetailListGridAction;\r\n\r\n agInit(params: ICellRendererParamsForAllocationDetailListGridAction): void {\r\n this._params = params;\r\n this.allocationDetail = params.data as Compliance.AllocationDetailModel;\r\n this.canView = params.canView(params);\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this._params.viewDetails(this._params);\r\n }\r\n}\r\n","import { Component, ElementRef, ViewChild, OnDestroy } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AllocationDetailDragAndDropService } from './allocationDetailDragAndDrop.service';\r\nimport { AssessmentSummaryInfo } from '../assessmentSummaryInfo';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\n\r\nexport interface DragAndDropCellRendererParams extends ICellRendererParams {\r\n allocationDetailsDropped: (allocationDetailIds: number[], summary: AssessmentSummaryInfo) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'drag-and-drop-cell-renderer',\r\n template: `\r\n
\r\n
\r\n
{{ summary.isTaxAuthority ? summary.taxAuthorityName : summary.title }}
\r\n
\r\n
\r\n `,\r\n host: { class: 'ws-stretch' }\r\n})\r\nexport class AllocationDetailDragAndDropCellRendererComponent implements ICellRendererAngularComp, OnDestroy {\r\n constructor(\r\n private _allocationDetailDragAndDropService: AllocationDetailDragAndDropService\r\n ) {}\r\n\r\n @ViewChild('dragulaEl') dragulaElRef: ElementRef;\r\n\r\n params: DragAndDropCellRendererParams;\r\n summary: AssessmentSummaryInfo;\r\n\r\n isServiceActive: boolean;\r\n isTotalRow: boolean;\r\n\r\n dragulaContainerType: string;\r\n dragulaBagName: string;\r\n\r\n dragging: boolean = false;\r\n draggingOver: boolean = false;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n agInit(params: DragAndDropCellRendererParams): void {\r\n this.dragulaContainerType = this._allocationDetailDragAndDropService.CONTAINER_TYPE_TARGET;\r\n this.dragulaBagName = this._allocationDetailDragAndDropService.BAG_NAME;\r\n\r\n this.params = params;\r\n this.summary = params.data as AssessmentSummaryInfo;\r\n this.isTotalRow = this.summary.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Total;\r\n\r\n this._allocationDetailDragAndDropService.dragging$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.dragging = x);\r\n\r\n this._allocationDetailDragAndDropService.draggingOver$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.draggingOver = this.dragulaElRef && (this.dragulaElRef.nativeElement === x));\r\n\r\n this._allocationDetailDragAndDropService.dropped$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => {\r\n if (!this.dragulaElRef) { return; }\r\n const droppedOnMe = this.dragulaElRef.nativeElement === x.element;\r\n if (droppedOnMe) {\r\n this.params.allocationDetailsDropped(x.draggedAllocationDetailIds, this.summary);\r\n }\r\n });\r\n\r\n this._allocationDetailDragAndDropService.active$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.isServiceActive = x);\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n}\r\n","import { HelpContentComponent, HelpContentRendererValue } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { Component } from '@angular/core';\r\nimport { AssessmentSummaryInfo } from '../assessmentSummaryInfo';\r\nimport { Decimal } from 'decimal.js';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface AllocationAssessmentSummaryComponentParams extends HelpContentRendererValue {\r\n summary: AssessmentSummaryInfo,\r\n components: Compliance.AllocationAssessmentSummaryComponentModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'allocation-assessment-summary-components',\r\n template: `\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Parcel #2:{{params.summary.parcelAccountNumber2}}
Desc:{{params.summary.description}}
Situs:{{situsLine1}}
{{situsLine2}}
{{situsLine3}}
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n Component\r\n \r\n AV\r\n \r\n Ratio (%)\r\n \r\n FMV\r\n
{{component.name}}{{component.av | number:\"1.0-0\"}}{{component.ratio * 100 | number:\"1.3-3\"}}%{{component.fmv | number:\"1.0-0\"}}
Total{{getTotal('av') | number:'1.0-0'}} {{getTotal('fmv') | number:'1.0-0'}}
\r\n
\r\n
\r\n
\r\n`\r\n})\r\n\r\nexport class AllocationAssessmentSummaryComponentComponent implements HelpContentComponent{\r\n params: AllocationAssessmentSummaryComponentParams;\r\n\r\n helpInit(params: AllocationAssessmentSummaryComponentParams): void {\r\n return null;\r\n }\r\n\r\n getTotal (column): number {\r\n return _.reduce(this.params.components, (sum, component) => new Decimal(sum).plus(Number(component[column])).toNumber(), 0);\r\n }\r\n\r\n get situsLinesNumber(): number {\r\n let result = 0;\r\n\r\n if (this.params.summary.parcelAddress1) {\r\n result += 1;\r\n }\r\n\r\n if (this.params.summary.parcelAddress2) {\r\n result += 1;\r\n }\r\n\r\n if (this.params.summary.parcelCity || this.params.summary.parcelZip) {\r\n result += 1;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n get situsLine3(): string {\r\n let result = '';\r\n\r\n if (this.params.summary.parcelCity){\r\n result = this.params.summary.parcelCity;\r\n }\r\n\r\n if (this.params.summary.parcelZip){\r\n result += `${result ? ', ' : ''}${this.params.summary.parcelState} ${this.params.summary.parcelZip}`;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n get situsLine1(): string {\r\n return this.params.summary.parcelAddress1 || this.params.summary.parcelAddress2 || this.situsLine3;\r\n }\r\n\r\n get situsLine2(): string {\r\n return this.params.summary.parcelAddress2 || this.situsLine3;\r\n }\r\n}\r\n","import { AssessmentSummaryInfo } from './assessmentSummaryInfo';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class AllocationDetailsService {\r\n allocationDetailsFilter: AssessmentSummaryInfo = null;\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { AssessmentSummaryInfo } from './assessmentSummaryInfo';\r\nimport { HelpContentComponentConfig } from '../../../UI-Lib/Help-Tooltip';\r\nimport { AllocationAssessmentSummaryComponentComponent, AllocationAssessmentSummaryComponentParams } from './Allocation-Assessment-Summary/allocationAssessmentSummaryComponent.component';\r\nimport { AllocationDetailsService } from './allocationDetails.service';\r\n\r\nexport interface ICellRendererParamsForAssessmentSummaryCellRenderer extends ICellRendererParams {\r\n deleteAssessmentClicked: (summary: AssessmentSummaryInfo) => void;\r\n lockReleaseLockedAssessmentClicked: (summary: AssessmentSummaryInfo, lock: boolean) => void;\r\n filterClicked: (summary: AssessmentSummaryInfo) => void;\r\n clearFilterClicked: () => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
`\r\n})\r\nexport class AgGridAssessmentSummaryActionCellRendererComponent implements ICellRendererAngularComp {\r\n constructor(private readonly _allocationDetailService: AllocationDetailsService) { }\r\n\r\n summary: AssessmentSummaryInfo;\r\n isNormalType: boolean;\r\n customRenderer: HelpContentComponentConfig;\r\n\r\n private _params: ICellRendererParamsForAssessmentSummaryCellRenderer;\r\n\r\n get lockCheckboxTitle(): string {\r\n let result: string = '';\r\n\r\n if (this.summary.isComitted) {\r\n result = 'Committed Allocation';\r\n } else if (this.summary.isLocked) {\r\n result = 'Un-Lock the Allocation';\r\n } else {\r\n result = 'Lock the Allocation';\r\n }\r\n\r\n return result;\r\n }\r\n\r\n get filterActive(): boolean {\r\n return this._allocationDetailService.allocationDetailsFilter &&\r\n this._allocationDetailService.allocationDetailsFilter.summaryType === this.summary.summaryType &&\r\n this._allocationDetailService.allocationDetailsFilter.allocationAnnualAssessmentId === this.summary.allocationAnnualAssessmentId;\r\n }\r\n\r\n agInit(params: ICellRendererParamsForAssessmentSummaryCellRenderer): void {\r\n this._params = params;\r\n this.summary = params.data as AssessmentSummaryInfo;\r\n\r\n this.customRenderer = {\r\n component: AllocationAssessmentSummaryComponentComponent,\r\n componentParams: {\r\n summary: this.summary,\r\n components: this.summary.components,\r\n },\r\n canHover: true\r\n };\r\n\r\n this.isNormalType = this.summary.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n deleteAssessmentClicked(event): void {\r\n if (!this.summary.canDelete) {\r\n return;\r\n }\r\n\r\n this._params.deleteAssessmentClicked(this.summary);\r\n event.stopPropagation();\r\n }\r\n\r\n lockReleaseLockedAssessmentClicked(event, lock: boolean): void{\r\n if (this.summary.isComitted || !this.summary.canLock && !this.summary.canReleaseLock) {\r\n return;\r\n }\r\n\r\n this.summary.isLocked = lock;\r\n this._params.lockReleaseLockedAssessmentClicked(this.summary, lock);\r\n event.stopPropagation();\r\n }\r\n\r\n filterOnSummary(): void {\r\n if (!this.filterActive) {\r\n this._params.filterClicked(this.summary);\r\n } else {\r\n this._params.clearFilterClicked();\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { AssessmentSummaryInfo } from './assessmentSummaryInfo';\r\nimport { AllocationDetailsService } from './allocationDetails.service';\r\n\r\nexport interface ICellRendererParamsForAssessmentSummaryHeaderRenderer extends ICellRendererParams {\r\n showLockedAssessmentsChange: (show: boolean) => void;\r\n clearFilter: () => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell-header',\r\n template: `\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n `\r\n})\r\nexport class AgGridAssessmentSummaryActionHeaderRendererComponent implements ICellRendererAngularComp {\r\n constructor(private readonly _allocationDetailService: AllocationDetailsService) { }\r\n\r\n summary: AssessmentSummaryInfo;\r\n showLockedAssessments: boolean = true;\r\n\r\n private _params: ICellRendererParamsForAssessmentSummaryHeaderRenderer;\r\n\r\n get filterActive(): boolean {\r\n return !!this._allocationDetailService.allocationDetailsFilter;\r\n }\r\n\r\n agInit(params: ICellRendererParamsForAssessmentSummaryHeaderRenderer): void {\r\n this._params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n lockAssessmentClicked(): void {\r\n this.showLockedAssessments = !this.showLockedAssessments;\r\n this._params.showLockedAssessmentsChange(this.showLockedAssessments);\r\n }\r\n\r\n clearFilter(): void {\r\n if (this.filterActive) {\r\n this._params.clearFilter();\r\n }\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const ALLOCATIONS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'allocations.new-assessment',\r\n tooltipText: 'Add Tax Authorities'\r\n },\r\n {\r\n helpContentId: 'allocations.assessment-size-available',\r\n tooltipText: 'Size columns to fit the available space'\r\n },\r\n {\r\n helpContentId: 'allocations.assessment-size-cell-content',\r\n tooltipText: 'Size columns to fit cell contents'\r\n },\r\n {\r\n helpContentId: 'allocations.assessment-filter-toggle',\r\n tooltipText: 'Show assessment grid filters'\r\n },\r\n];\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../AgGrid';\r\nimport { AllocationRepository } from '../../../Repositories';\r\n\r\nexport interface RetrieveAssetsDataSourceParams {\r\n allocationId: number;\r\n}\r\n\r\nexport class RetrieveAssetsAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private _gridApi: GridApi,\r\n private _allocationRepository: AllocationRepository,\r\n protected _dataSourceParamsFn: () => RetrieveAssetsDataSourceParams\r\n ) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'assetNumber', value: Compliance.AllocationCompanyAssetPropertyEnum.AssetNumber },\r\n { name: 'siteName', value: Compliance.AllocationCompanyAssetPropertyEnum.SiteName },\r\n { name: 'siteNumber', value: Compliance.AllocationCompanyAssetPropertyEnum.SiteNumber },\r\n { name: 'parcel', value: Compliance.AllocationCompanyAssetPropertyEnum.Parcel },\r\n { name: 'description', value: Compliance.AllocationCompanyAssetPropertyEnum.Description },\r\n { name: 'classification', value: Compliance.AllocationCompanyAssetPropertyEnum.Classification },\r\n { name: 'acqDate', value: Compliance.AllocationCompanyAssetPropertyEnum.AcqDate },\r\n { name: 'reportableCost', value: Compliance.AllocationCompanyAssetPropertyEnum.ReportableCost },\r\n { name: 'assessor', value: Compliance.AllocationCompanyAssetPropertyEnum.Assessor },\r\n { name: 'state', value: Compliance.AllocationCompanyAssetPropertyEnum.State },\r\n { name: 'allocated', value: Compliance.AllocationCompanyAssetPropertyEnum.Allocated },\r\n { name: 'lastReturn', value: Compliance.AllocationCompanyAssetPropertyEnum.LastReturn }\r\n ];\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.SearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n\r\n return await lastValueFrom(this._allocationRepository.getCompanyAssetIds(this._dataSourceParams.allocationId, searchParams));\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return !!this._dataSourceParams.allocationId;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.SearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n\r\n const result = await lastValueFrom(this._allocationRepository.getCompanyAssets(this._dataSourceParams.allocationId, searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n\r\n destroy?(): void { return null; }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const RETRIEVE_ASSETS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'retrieve-assets.title',\r\n tooltipText: 'List of assets that are available to add to this allocation. Assets must be in the same top-level company, and have a lien date corresponding to this allocation\\'s assessment revision tax year.',\r\n hasIcon: true\r\n }\r\n];\r\n"," 0\">\r\n\r\n \r\n \r\n\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../../Busy-Indicator';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../../AgGrid/MultiSelectTracker';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../AgGrid';\r\nimport { RetrieveAssetsAgGridDataSource, RetrieveAssetsDataSourceParams } from './agGridDataSource';\r\nimport { AllocationRepository } from '../../../Repositories';\r\nimport { RETRIEVE_ASSETS_HELP } from './retrieveAssets.component.help';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { lastValueFrom, Subscription } from 'rxjs';\r\nimport { WeissmanDateFormatPipe } from '../../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { DecimalPipe } from '@angular/common';\r\n\r\nexport interface RetrieveAssetsParams {\r\n allocationId: number\r\n}\r\n\r\n@Component({\r\n selector: 'retrieve-assets-component',\r\n templateUrl: './retrieveAssets.component.html'\r\n})\r\nexport class RetrieveAssetsComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(private readonly _modalRef: BsModalRef,\r\n private readonly _allocationRepository: AllocationRepository,\r\n private readonly _helpService: HelpService,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private _decimalPipe: DecimalPipe) {\r\n }\r\n\r\n params: RetrieveAssetsParams;\r\n result: boolean;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n gridTracker: AgGridMultiSelectTracker;\r\n disableSave: boolean = false;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.FilingModel).filingId)\r\n }\r\n })\r\n .withContext(this)\r\n .withInfiniteScroll()\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: RetrieveAssetsAgGridDataSource;\r\n private _selectedRowsSubscription: Subscription;\r\n\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(RETRIEVE_ASSETS_HELP);\r\n }\r\n\r\n async ngOnDestroy(): Promise {\r\n this._selectedRowsSubscription && this._selectedRowsSubscription.unsubscribe();\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._selectedRowsSubscription = this.gridTracker.selectedRows$.subscribe(x =>\r\n this.disableSave = !x.selectAllRows && x.selectedRows.length === 0);\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: '',\r\n field: 'assetId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n field: 'assetNumber',\r\n headerName: 'Asset Number',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n field: 'siteName',\r\n headerName: 'Site Name',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n field: 'siteNumber',\r\n headerName: 'Site Number',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n field: 'parcel',\r\n headerName: 'Parcel',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n field: 'description',\r\n headerName: 'Description',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n field: 'classification',\r\n headerName: 'Classification',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n field: 'acqDate',\r\n headerName: 'Aqc. Date',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n },\r\n {\r\n field: 'reportableCost',\r\n headerName: 'Reportable Cost',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2')\r\n },\r\n {\r\n field: 'assessor',\r\n headerName: 'Assessor',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n field: 'state',\r\n headerName: 'State',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n field: 'allocated',\r\n headerName: 'Allocated',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n field: 'lastReturn',\r\n headerName: 'Last Return',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: `${Compliance.AllocationCompanyAssetPropertyEnum.AssetNumber}`,\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgId = 'saving';\r\n this.busyIndicatorMessageManager.add('Adding Assets', busyMsgId);\r\n\r\n try {\r\n const model = this.gridTracker.getSelectedRowsModel();\r\n await lastValueFrom(this._allocationRepository.addCompanyAssets(this.params.allocationId, model));\r\n\r\n this.result = true;\r\n\r\n this._modalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n private _setDataSource(): void {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear();\r\n\r\n const dataSourceParams = (): RetrieveAssetsDataSourceParams => {\r\n return {\r\n allocationId: this.params.allocationId\r\n };\r\n };\r\n\r\n this._gridDataSource = new RetrieveAssetsAgGridDataSource(this._gridApi, this._allocationRepository, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridOptionsBuilder } from '../../../AgGrid';\r\nimport { UpgradeNavigationServiceHandler } from '../../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\n\r\nexport interface AssetsInAnotherAllocationsParams {\r\n assets: Compliance.AllocationAssessmentsWithAssetsInAnotherAllocationsModel[]\r\n}\r\n\r\n@Component({\r\n selector: 'assets-in-another-allocations',\r\n templateUrl: './assetsInAnotherAllocations.component.html'\r\n})\r\nexport class AssetsInAnotherAllocationsComponent implements IWeissmanModalComponent {\r\n constructor(private readonly _modalRef: BsModalRef,\r\n private readonly _routerService: UpgradeNavigationServiceHandler) {\r\n }\r\n\r\n params: AssetsInAnotherAllocationsParams;\r\n result: void;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'currentParcel',\r\n headerName: 'Assessment',\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n field: 'assetNumber',\r\n headerName: 'Asset Number',\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n field: 'additionalSite',\r\n headerName: 'Add\\'l Site Allocation',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => '',\r\n newWindow: true,\r\n isHelpDisabled: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Compliance.AllocationAssessmentsWithAssetsInAnotherAllocationsModel;\r\n if (model) {\r\n return this._routerService.getHrefFromState('site', {\r\n companyId: model.additionalCompanyId,\r\n siteId: model.additionalSiteId\r\n });\r\n }\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n field: 'additionalParcel',\r\n headerName: 'Add\\'l Assessment',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => '',\r\n newWindow: true,\r\n isHelpDisabled: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Compliance.AllocationAssessmentsWithAssetsInAnotherAllocationsModel;\r\n if (model) {\r\n return this._routerService.getHrefFromState('parcel', {\r\n companyId: model.additionalCompanyId,\r\n siteId: model.additionalSiteId,\r\n parcelId: model.additionalParcelId,\r\n annualYearID: model.additionalAnnualYearId,\r\n annualAssessmentID: model.additionalAnnualAssessmentId\r\n });\r\n }\r\n }\r\n } as AgGridLinkCellRendererParams\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setRowData(this.params.assets);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n async ok(): Promise {\r\n this._modalRef.hide();\r\n }\r\n}\r\n"," 0\">\r\n\r\n \r\n \r\n\r\n","\r\n \r\n \r\n\r\n","import { Component, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { Subscription } from 'rxjs';\r\nimport { BusyIndicatorMessageManager } from '../../../../Busy-Indicator';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../../AgGrid/MultiSelectTracker';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../AgGrid';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { AssessmentSummaryInfo } from '../assessmentSummaryInfo';\r\n\r\nexport interface SelectTaxAuthoritiesParams{\r\n allocationId: number,\r\n selectedAllocationDetailIds: number[],\r\n lastModifiedTimestamp: Date,\r\n taxAuthorities: AssessmentSummaryInfo[]\r\n}\r\n\r\nexport interface SelectTaxAuthoritiesResult {\r\n selectedAssessmentSummaries: number[]\r\n}\r\n\r\n@Component({\r\n selector: 'select-tax-authority',\r\n templateUrl: './selectTaxAuthority.component.html'\r\n})\r\nexport class SelectTaxAuthorityComponent implements IWeissmanModalComponent, OnDestroy {\r\n constructor(private readonly _modalRef: BsModalRef) {\r\n }\r\n\r\n params: SelectTaxAuthoritiesParams;\r\n result: SelectTaxAuthoritiesResult;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged()\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withSort()\r\n .withTextSelection()\r\n .withFloatingFilter()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n private _selectedRows: number[] = [];\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe((selected: Compliance.SelectedRowsModel) => {\r\n this._selectedRows = (selected.selectAllRows) ? this.params.taxAuthorities.map(f => f.allocationAnnualAssessmentId) : selected.selectedRows;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'allocationAnnualAssessmentId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n },\r\n {\r\n headerName: 'Tax Authority',\r\n field: 'taxAuthorityName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'taxAuthorityName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.sizeColumnsToFit();\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n this.result = {selectedAssessmentSummaries: this._selectedRows};\r\n this._modalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n const queryResultModel: Compliance.QueryResultModel = {\r\n lastModifiedTimestamp: new Date(),\r\n totalRows: rows.length,\r\n totalValidRows: rows.length,\r\n data: rows.map((x) => {\r\n const taxAuthority = x.data as AssessmentSummaryInfo;\r\n return taxAuthority && taxAuthority.allocationAnnualAssessmentId;\r\n })\r\n };\r\n\r\n return Promise.resolve(queryResultModel);\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.params.taxAuthorities)) {\r\n return;\r\n }\r\n\r\n this.gridTracker && this.gridTracker.clear();\r\n\r\n this._gridApi.setRowData(this.params.taxAuthorities);\r\n }\r\n}\r\n","import { Directive, ElementRef, EventEmitter, Input, NgZone, Output, Renderer2 } from '@angular/core';\r\nimport { fromEvent, Subject } from 'rxjs';\r\nimport { filter, map, switchMap, takeUntil } from 'rxjs/operators';\r\n\r\ninterface Vector2 {\r\n x: number;\r\n y: number;\r\n}\r\n\r\n@Directive({\r\n selector: '[ws-resizable]'\r\n})\r\nexport class ResizableDirective {\r\n constructor(\r\n private readonly _renderer: Renderer2,\r\n private readonly _elementRef: ElementRef,\r\n private readonly _zone: NgZone\r\n ) { }\r\n\r\n @Input() rDragAxis: string;\r\n @Input() rDragPosition: string;\r\n @Input() rMinWidth: number;\r\n @Input() rMinHeight: number;\r\n @Input() rMaxWidth: number;\r\n @Input() rMaxHeight: number;\r\n @Input() rFlex: boolean;\r\n @Input() rDisabled: boolean;\r\n @Input() rWidth: number;\r\n @Input() rHeight: number;\r\n\r\n @Output() rChanged: EventEmitter = new EventEmitter();\r\n\r\n private _container: HTMLElement;\r\n private _handle: HTMLElement;\r\n private _styleProperty: string;\r\n private _dragInProgress: boolean;\r\n private _startWidth: number;\r\n private _startHeight: number;\r\n private _delta: Vector2 = { x: 0, y: 0 };\r\n\r\n private destroy$ = new Subject();\r\n\r\n ngAfterViewInit(): void {\r\n this._container = this._elementRef.nativeElement;\r\n this._renderer.addClass(this._container, 'resizable');\r\n\r\n if (this.rFlex) {\r\n this._styleProperty = 'flexBasis' in document.documentElement.style ? 'flexBasis' :\r\n 'webkitFlexBasis' in document.documentElement.style ? 'webkitFlexBasis' :\r\n 'msFlexPreferredSize' in document.documentElement.style ? 'msFlexPreferredSize' : 'flexBasis';\r\n } else {\r\n this._styleProperty = this.rDragAxis === 'x' ? 'width' : 'height';\r\n }\r\n\r\n // Set base width if provided\r\n if (typeof this.rWidth === 'number' && this.rDragAxis === 'x') {\r\n this._renderer.setStyle(this._container, this._styleProperty, `${this.rWidth}px`);\r\n }\r\n\r\n // Set base height if provided\r\n if (typeof this.rHeight === 'number' && this.rDragAxis === 'y') {\r\n this._renderer.setStyle(this._container, this._styleProperty, `${this.rHeight}px`);\r\n }\r\n\r\n // Create the drag handle\r\n this._handle = this._renderer.createElement('div');\r\n\r\n // add class for styling purposes\r\n this._renderer.addClass(this._handle, `rg-${this.rDragPosition}`);\r\n this._renderer.addClass(this._handle, 'ws-cursor-grab');\r\n this._renderer.setProperty(this._handle, 'innerHTML', '');\r\n this._renderer.appendChild(this._container, this._handle);\r\n\r\n this._setStartValues();\r\n this._setupEvents();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.unsubscribe();\r\n }\r\n\r\n private _setupEvents(): void {\r\n this._zone.runOutsideAngular(() => {\r\n const mousedown$ = fromEvent(this._handle, 'mousedown');\r\n const mousemove$ = fromEvent(document, 'mousemove');\r\n const mouseup$ = fromEvent(document, 'mouseup');\r\n\r\n mousedown$\r\n .pipe(takeUntil(this.destroy$), filter(() => !this.rDisabled), switchMap((event: MouseEvent) => {\r\n event.preventDefault();\r\n this._setStartValues();\r\n const startX = event.clientX;\r\n const startY = event.clientY;\r\n\r\n return mousemove$\r\n .pipe(map((e: MouseEvent) => {\r\n e.preventDefault();\r\n this._dragInProgress = true;\r\n this._delta = {\r\n x: e.clientX - startX,\r\n y: e.clientY - startY\r\n };\r\n }))\r\n .pipe(takeUntil(mouseup$));\r\n }))\r\n .subscribe(() => {\r\n if (this._delta.x === 0 && this._delta.y === 0) {\r\n return;\r\n }\r\n\r\n this._translate();\r\n });\r\n\r\n mouseup$.pipe(takeUntil(this.destroy$)).subscribe((event: MouseEvent) => {\r\n // We don't want this event handler to steal mouse up events from\r\n // other controls if we don't have a drag in progress.\r\n // A \"select multiple\" within the draggable div was not getting\r\n // events consistently without this short-circuit.\r\n if (!this._dragInProgress) { return; }\r\n\r\n event.preventDefault();\r\n this._delta = { x: 0, y: 0 };\r\n this._setStartValues();\r\n this._dragInProgress = false;\r\n });\r\n });\r\n }\r\n\r\n private _translate(): void {\r\n requestAnimationFrame(() => {\r\n if (this.rDragAxis === 'x') {\r\n let width = this._startWidth + (this._delta.x * 2);\r\n if (this.rMinWidth && width < this.rMinWidth) {\r\n width = this.rMinWidth;\r\n } else if (this.rMaxWidth && width > this.rMaxWidth) {\r\n width = this.rMaxWidth;\r\n }\r\n this._renderer.setStyle(this._container, this._styleProperty, `${width}px`);\r\n this.rChanged.emit([width, this._startHeight]);\r\n } else {\r\n let height = this._startHeight + (this._delta.y * 2);\r\n if (this.rMinHeight && height < this.rMinHeight) {\r\n height = this.rMinHeight;\r\n } else if (this.rMaxHeight && height > this.rMaxHeight) {\r\n height = this.rMaxHeight;\r\n }\r\n this._renderer.setStyle(this._container, this._styleProperty, `${height}px`);\r\n this.rChanged.emit([this._startWidth, height]);\r\n }\r\n });\r\n }\r\n\r\n private _setStartValues(): void {\r\n if (this.rFlex && this._container.style[this._styleProperty]) {\r\n const value = parseInt(this._container.style[this._styleProperty]);\r\n this._startWidth = value;\r\n this._startHeight = value;\r\n } else {\r\n const baseValues = this._container.getBoundingClientRect();\r\n this._startWidth = baseValues.width;\r\n this._startHeight = baseValues.height;\r\n }\r\n }\r\n\r\n}\r\n"," 0\" [message]=\"busyMessageManager.message\">\r\n\r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { EntityImportRepository } from '../../Repositories';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, ColumnApi } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder } from '../../AgGrid';\r\nimport * as _ from 'lodash';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\nexport interface ExcelPreviewComponentParams {\r\n importFileId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'excel-preview',\r\n templateUrl: './excelPreview.component.html',\r\n styleUrls: ['./excelPreview.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ExcelPreviewComponent implements OnInit, IWeissmanModalComponent{\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _entityImportRepository: EntityImportRepository) {\r\n }\r\n\r\n params: ExcelPreviewComponentParams;\r\n result: Compliance.ImportFileModel;\r\n\r\n selectedWorksheetName: string;\r\n headerRowIndex?: number = 1;\r\n previewInfo: Compliance.ExcelImportPreviewModel = null;\r\n busyMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n gridId: System.Guid = '11713691-1C0B-4EB5-A136-92EF182117A9';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withContext(this)\r\n .withColumnResize()\r\n .withLoadingOverlay()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _gridColumnApi: ColumnApi;\r\n\r\n async ngOnInit(): Promise {\r\n this.busyMessageManager.add('Loading', 'loading');\r\n try{\r\n this.previewInfo = await lastValueFrom(this._entityImportRepository.getExcelPreviewAsync(this.params.importFileId));\r\n\r\n if (this.previewInfo.worksheetsInfo && this.previewInfo.worksheetsInfo.length > 0){\r\n this.selectedWorksheetName = this.previewInfo.worksheetsInfo[0].worksheetName;\r\n }\r\n\r\n this._setRowData();\r\n }\r\n finally{\r\n this.busyMessageManager.remove('loading');\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save(): Promise {\r\n this.busyMessageManager.add('Saving', 'saving');\r\n\r\n try {\r\n const model: Compliance.ImportFileExcelOptionsModel = {\r\n headerRowIndex: this.headerRowIndex,\r\n worksheetName: this.selectedWorksheetName\r\n };\r\n\r\n this.result = await lastValueFrom(this._entityImportRepository.updateExcelOptions(this.params.importFileId, model));\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyMessageManager.remove('saving');\r\n }\r\n }\r\n\r\n selectedWorksheetChanged(): void {\r\n this._setRowData();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridColumnApi = event.columnApi;\r\n\r\n this._setRowData();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!this._gridApi || !this.previewInfo) {\r\n return;\r\n }\r\n\r\n const worksheetInfo = _.find(this.previewInfo.worksheetsInfo, i => i.worksheetName === this.selectedWorksheetName);\r\n const columns: ColDef[] = [\r\n {\r\n headerName: '',\r\n field: 'rowIndex',\r\n width: 100,\r\n minWidth: 50}\r\n ];\r\n\r\n for (let i = 0; i < worksheetInfo.columnsCount; i++){\r\n columns.push({\r\n headerName: this._toColumnName(i + 1),\r\n field: `f${i}`,\r\n width: 100,\r\n minWidth: 50\r\n });\r\n }\r\n\r\n let rowIndex: number = 1;\r\n const data = _.map(worksheetInfo.rows, rawData => {\r\n const row = {\r\n ['rowIndex']: rowIndex++\r\n };\r\n for (let i = 0; i < worksheetInfo.columnsCount; i++){\r\n row[`f${i}`] = rawData[i];\r\n }\r\n return row;\r\n });\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n\r\n const allColumnIds = [];\r\n this._gridColumnApi.getAllColumns().forEach(function(column) {\r\n allColumnIds.push(column.getColId());\r\n });\r\n\r\n this._gridApi.setRowData(data);\r\n this._gridColumnApi.autoSizeColumns(allColumnIds);\r\n }\r\n\r\n private _toColumnName(num: number): string {\r\n let ret = '';\r\n for (let a = 1, b = 26; (num -= a) >= 0; a = b, b *= 26) {\r\n ret = String.fromCharCode((num % b) / a + 65) + ret;\r\n }\r\n return ret.toLocaleUpperCase();\r\n }\r\n}\r\n","import { Component, Input, Output, EventEmitter, OnDestroy } from '@angular/core';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { UpgradeNavigationServiceHandler } from '../Routing/upgrade-navigation-handler.service';\r\nimport { EntityImportUploadComponent, EntityImportUploadParams } from '../../Compliance/Entity-Import/Upload/upload.component';\r\nimport { ExcelPreviewComponent, ExcelPreviewComponentParams } from '../../Compliance/Entity-Import/Excel-Preview/excelPreview.component';\r\nimport { IBusyIndicatorConfig, BusyIndicatorService, BusyIndicatorRef } from '../../Busy-Indicator';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { EntityImportRepository } from '../../Compliance/Repositories';\r\n\r\n@Component({\r\n selector: 'begin-new-import',\r\n template: `\r\n \r\n`\r\n})\r\nexport class BeginNewImportComponent implements OnDestroy {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _entityImportRepository: EntityImportRepository\r\n ) { }\r\n\r\n @Input() label: string = 'New Data Import';\r\n @Input() canCloseProgressModal: boolean = true;\r\n @Input() companyId: number;\r\n @Input() buttonSize: string;\r\n @Input() isDisabled: boolean = false;\r\n @Input() allocationId?: number;\r\n\r\n @Output() refresh: EventEmitter = new EventEmitter();\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.unsubscribe();\r\n }\r\n\r\n async newImport(): Promise {\r\n const params: EntityImportUploadParams = {\r\n companyId: this.companyId,\r\n allocationId: this.allocationId\r\n };\r\n\r\n const importFile = await this._modalService.showAsync(EntityImportUploadComponent, params, 'modal-md');\r\n\r\n if (!importFile) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.refresh.emit();\r\n\r\n await this.resumeImport(importFile);\r\n }\r\n\r\n async resumeImport(importFile: Compliance.ImportFileModel): Promise {\r\n if (importFile.processStatus === Compliance.ImportFileProcessStatusEnum.ShowPreview) {\r\n const params: ExcelPreviewComponentParams = {\r\n importFileId: importFile.importFileId\r\n };\r\n\r\n const previewResult = await this._modalService.showAsync(ExcelPreviewComponent, params, 'modal-xl');\r\n if (!previewResult) {\r\n return Promise.resolve(null);\r\n }\r\n\r\n importFile = previewResult;\r\n }\r\n\r\n if (importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Uploaded) {\r\n const busyRef = await this.showImportFileIsProcessingMessage(importFile);\r\n\r\n let startResult: Compliance.ImportFileModel;\r\n try {\r\n startResult = await lastValueFrom(this._entityImportRepository.startProcess(importFile.importFileId));\r\n if (!startResult) {\r\n return Promise.resolve(null);\r\n }\r\n\r\n await busyRef.setLongRunningProcessId(startResult.longRunningProcessId);\r\n }\r\n catch (e) {\r\n busyRef.hide();\r\n throw e;\r\n }\r\n\r\n importFile = startResult;\r\n }\r\n\r\n return importFile;\r\n }\r\n\r\n async showImportFileIsProcessingMessage(importFile: Compliance.ImportFileModel): Promise {\r\n const busyRefId = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n\r\n const busyConfig: IBusyIndicatorConfig = {\r\n identifier: busyRefId,\r\n longRunningProcessId: importFile.longRunningProcessId,\r\n title: 'Processing Import',\r\n message: 'Import Uploading',\r\n hasProgressBar: false,\r\n canDismiss: !this.allocationId\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show(busyConfig);\r\n\r\n busyRef.onProgressBarComplete().pipe(takeUntil(this.destroy$)).subscribe((succeeded: boolean) => {\r\n busyRef.hide();\r\n if (succeeded) {\r\n this._dismissImportFileIsProcessingMessage(importFile);\r\n } else {\r\n this.refresh.emit();\r\n }\r\n this.destroy$.next();\r\n });\r\n\r\n busyRef.onDismiss().pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n busyRef.hide();\r\n this.destroy$.next();\r\n });\r\n\r\n return busyRef;\r\n }\r\n\r\n private _dismissImportFileIsProcessingMessage(importFile: Compliance.ImportFileModel): void {\r\n if (!importFile) {\r\n return;\r\n }\r\n\r\n if (this.allocationId) {\r\n this._routerService.go('processAllocationImport', { allocationId: this.allocationId, importId: importFile.importFileId });\r\n } else if (importFile.companyId) {\r\n this._routerService.go('processCompanyImport', { companyId: importFile.companyId, importId: importFile.importFileId });\r\n } else {\r\n this._routerService.go('processSystemImport', { importId: importFile.importFileId });\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n Lien Date:\r\n
{{ allocation.lienDate.toISOString() | slice: 0 : 10 | date : 'MM/dd/yyyy' }}
\r\n
\r\n
\r\n Assessor{{assessors.length > 1 ? 's' : ''}}:\r\n
\r\n \r\n {{ assessor.name }}\r\n \r\n \r\n
\r\n
\r\n
\r\n Site:\r\n
{{ allocation.siteName }}
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n Mark Allocation Reviewed\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n Assessments\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
Actions:
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n Assets\r\n \r\n
\r\n
\r\n
Management Review:
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n\r\n","import { Component, OnDestroy, OnInit, ViewChild, ViewEncapsulation } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { AllocationRepository, CompanyAssetDescriptorRepository } from '../../Repositories';\r\nimport { BeginNewImportComponent } from '../../../Common/import/beginNewImport.component';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport {\r\n AgGridMultiSelectCellRendererParams,\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectHeaderRendererParams,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../AgGrid/MultiSelectTracker';\r\nimport {\r\n CellValueChangedEvent,\r\n ColDef,\r\n GridApi,\r\n GridOptions,\r\n GridReadyEvent,\r\n ICellRendererParams\r\n} from 'ag-grid-community';\r\nimport {\r\n AgGridColumns,\r\n AgGridDropdownCellEditor,\r\n AgGridFilterParams,\r\n AgGridNumberCellEditor,\r\n AgGridOptionsBuilder,\r\n AgGridTextCellEditor\r\n} from '../../AgGrid';\r\nimport { AgGridExportOptions, AgGridExportStartLRP, AgGridToolPanelAction } from '../../AgGrid/ToolPanel/models';\r\nimport { BehaviorSubject, lastValueFrom, Subject, Subscription } from 'rxjs';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport {\r\n AgGridCheckboxCellRendererComponent,\r\n ICellRendererParamsForAgGridCheckbox\r\n} from '../../AgGrid/CellRenderers/agGridCheckboxCellRender.component';\r\nimport { AllocationDetailsListAgGridDataSource, AllocationDetailsListDataSourceParams } from './agGridDataSource';\r\nimport { AllocationDetailRepository } from '../../Repositories/allocationDetail.repository';\r\nimport { AllocationDetailGridRowModel } from './AllocationDetailGridRowModel';\r\nimport { IMutexServiceHandler, WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport {\r\n AllocationDetailDragAndDropSourceComponent,\r\n ICellRendererParamsForAllocationDetailDragAndDropSource\r\n} from './Drag-And-Drop/allocationDetailDragAndDropSource.component';\r\nimport { AllocationDetailDragAndDropService } from './Drag-And-Drop/allocationDetailDragAndDrop.service';\r\nimport { AllocationDetailsService } from './allocationDetails.service';\r\nimport { AssessmentSummaryInfo } from './assessmentSummaryInfo';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { AddTaxAuthorityComponent, AddTaxAuthorityParams } from './Add-Tax-Authority/addTaxAuthority.component';\r\nimport {\r\n AllocationDetailBulkUpdateComponent,\r\n AllocationDetailBulkUpdateParams\r\n} from './Allocation-Detail-Bulk-Update/allocationDetailBulkUpdate.component';\r\nimport { IsColumnFuncParams } from 'ag-grid-community/dist/lib/entities/colDef';\r\nimport {\r\n ReturnAssetChangeIconCellRendererComponent\r\n} from '../../Return/Return-Parts/Assets/Asset-List/agGridChangeIconCellRenderer.component';\r\nimport { WeissmanDateFormatPipe } from '../../../UI-Lib/Pipes';\r\nimport { ReturnService } from '../../Return/return.service';\r\nimport { AttachmentModalData } from '../../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../../Comments/comments.service';\r\nimport { InstanceRights, RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport {\r\n CreateNewMergedParcelsComponent,\r\n CreateNewMergedParcelsParams\r\n} from './Create-New-Merged-Parcels/create-new-merged-parcels.component';\r\nimport { AssetDetailsComponent, AssetDetailsParams } from '../../Asset/Asset-Details/assetDetails.component';\r\nimport {\r\n AllocationDetailListGridActionCellRendererComponent,\r\n ICellRendererParamsForAllocationDetailListGridAction\r\n} from './agGridActionCellRenderer.component';\r\nimport {\r\n AllocationDetailDragAndDropCellRendererComponent,\r\n DragAndDropCellRendererParams\r\n} from './Drag-And-Drop/allocationDetailDragAndDropCellRenderer.component';\r\nimport {\r\n AgGridAssessmentSummaryActionCellRendererComponent,\r\n ICellRendererParamsForAssessmentSummaryCellRenderer\r\n} from './agGridAssessmentSummaryActionCellRenderer.component';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport {\r\n AgGridAssessmentSummaryActionHeaderRendererComponent,\r\n ICellRendererParamsForAssessmentSummaryHeaderRenderer\r\n} from './agGridAssessmentSummaryActionHeaderRenderer.component';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { ALLOCATIONS_HELP } from './allocationDetails.help';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\nimport { filter, sortBy } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\nimport { AllocationService } from '../allocation.service';\r\nimport { RetrieveAssetsComponent, RetrieveAssetsParams } from './Retrieve-Assets/retrieveAssets.component';\r\nimport { SiteService } from '../../../Entity/Site/Site.Service.upgrade';\r\nimport {\r\n AssetsInAnotherAllocationsComponent,\r\n AssetsInAnotherAllocationsParams\r\n} from './Assets-In-Another-Allocations/assetsInAnotherAllocations.component';\r\nimport {\r\n SelectTaxAuthoritiesParams,\r\n SelectTaxAuthorityComponent\r\n} from './Select-Tax-Authority/selectTaxAuthority.component';\r\nimport {\r\n MessageModalButtons,\r\n MessageModalDisplayMode,\r\n MessageModalOptions,\r\n MessageModalResult,\r\n MessageModalService\r\n} from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport AllocationAssessmentSummaryTypeEnum = Compliance.AllocationAssessmentSummaryTypeEnum;\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\n\r\nenum AssessmentActions {\r\n LockAllocation,\r\n ReleaseLockedAllocation,\r\n DistributeVariance,\r\n CreateNewMergedParcels\r\n}\r\n\r\n@Component({\r\n selector: 'allocation-details',\r\n templateUrl: './allocationDetails.component.html',\r\n styleUrls: ['./allocationDetails.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class AllocationDetailsComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _allocationRepository: AllocationRepository,\r\n private readonly _allocationDetailRepository: AllocationDetailRepository,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _allocationDetailDragAndDropService: AllocationDetailDragAndDropService,\r\n private readonly _allocationDetailService: AllocationDetailsService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _returnService: ReturnService,\r\n private readonly _companyAssetDescriptorRepository: CompanyAssetDescriptorRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _helpService: HelpService,\r\n private readonly _allocationService: AllocationService,\r\n private readonly _siteService: SiteService,\r\n private readonly _messageModalService: MessageModalService) {\r\n }\r\n\r\n @ViewChild('newImport') newImport: BeginNewImportComponent;\r\n allocation: Compliance.AllocationModel;\r\n\r\n allocationId: number;\r\n companyId: number;\r\n isInitialized: boolean = false;\r\n breadcrumbs: BreadCrumb[] = [];\r\n assessmentGridTracker: AgGridMultiSelectTracker;\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridId: System.Guid = '111F9E56-B96B-4BAB-AB6F-856B067062B8';\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n assetGridTotalsRow: any;\r\n assetGridSelectedTotalsRow: any;\r\n selectedTotalsLoading: boolean = true;\r\n totalsLoading: any;\r\n editing: boolean = false;\r\n hideLockedAssessments: boolean = false;\r\n assessmentsSummaryFilter: string;\r\n hideNotReportedAssets: boolean = false;\r\n hasSelectedRows: boolean = false;\r\n canEditCompany: boolean = false;\r\n selectedAction: any;\r\n canViewRyanPrivateItems: boolean = false;\r\n assessors: BreadCrumb[];\r\n managementReviewSelectedOption: Compliance.AllocationDetailManagementReviewOptionEnum;\r\n assessmentActions: any[] = [\r\n {\r\n label: 'Lock Allocation',\r\n value: AssessmentActions.LockAllocation,\r\n disabled: true\r\n },\r\n {\r\n label: 'Release Locked Allocation',\r\n value: AssessmentActions.ReleaseLockedAllocation,\r\n disabled: true\r\n },\r\n {\r\n label: 'Distribute Variance',\r\n value: AssessmentActions.DistributeVariance,\r\n disabled: true\r\n },\r\n {\r\n label: 'Create new parcels and assessment for unallocated',\r\n value: AssessmentActions.CreateNewMergedParcels,\r\n disabled: true\r\n }\r\n ];\r\n\r\n managementReviewOptions: any[] = [\r\n {\r\n label: '',\r\n value: null,\r\n },\r\n {\r\n label: 'Final Assessed Allocated Value > Cost',\r\n value: Compliance.AllocationDetailManagementReviewOptionEnum.FinalAssessedAllocatedValueGreaterThanCost\r\n },\r\n {\r\n label: 'Final Assessed Allocated Value > Prior Yr Final Assessed Allocated Value',\r\n value: Compliance.AllocationDetailManagementReviewOptionEnum.FinalAssessedAllocatedValueGreaterThanPriorYrFinalAssessedAllocatedValue\r\n },\r\n {\r\n label: 'Prior Yr Factor = Current Yr Factor',\r\n value: Compliance.AllocationDetailManagementReviewOptionEnum.PriorYrFactorEqualsCurrentYrFactor\r\n },\r\n {\r\n label: 'Return Value <> Final Assessed Allocated Value',\r\n value: Compliance.AllocationDetailManagementReviewOptionEnum.ReturnValueNotEqualsFinalAssessedAllocatedValue\r\n }\r\n ];\r\n\r\n assessmentGridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'phantom-summary': (params) => params.data && params.data.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Phantom,\r\n 'estimated-summary': (params) => params.data && params.data.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal && !params.data.isActual && !params.data.hasActiveAppeal,\r\n 'has-active-appeal': (params) => params.data && params.data.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal && params.data.hasActiveAppeal,\r\n 'dragging': (params) => this._dragging\r\n },\r\n rowHeight: 39\r\n }).withContext(this)\r\n .withColumnResize()\r\n .build();\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as AllocationDetailGridRowModel).allocationDetailId),\r\n 'totals-row': (params) => params.data && params.data.totalsRow,\r\n 'selected-totals-row': (params) => params.data && params.data.selectedTotalsRow,\r\n 'not-matched': (params) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && !allocationDetail.isMatched;\r\n }\r\n },\r\n singleClickEdit: true\r\n })\r\n .withCellEditingStarted(() => {\r\n this.startEditMode();\r\n })\r\n .withCellEditingStopped(() => {\r\n this.endEditMode();\r\n })\r\n .withoutCellEditingStoppedOnGridLostFocus()\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const searchParams = this._gridDataSource.getSearchParamsWithoutPagination();\r\n searchParams.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n if (!searchParams.selectedRows.selectAllRows && searchParams.selectedRows.selectedRows.length === 0) {\r\n searchParams.selectedRows.selectAllRows = true;\r\n }\r\n const exportModel: Compliance.AllocationDetailExportModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn,\r\n fileFormat\r\n };\r\n\r\n const lrp$ = this._allocationDetailRepository.startExport(this.allocationId, exportModel);\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportAllocationDetails };\r\n },\r\n canCancel: true,\r\n showFileFormatSelection: true\r\n };\r\n\r\n gridActions: AgGridToolPanelAction[] = [\r\n {\r\n name: 'Match to existing non-allocated assets',\r\n helpContentId: '',\r\n disabled: () => !this._allocationDetailSelectionInfo.hasNotMatchedAssets,\r\n onClickCallback: this.matchToExistingNonAllocatedAssets.bind(this)\r\n },\r\n {\r\n name: 'Create assets not matched from work papers',\r\n helpContentId: '',\r\n disabled: () => !this._allocationDetailSelectionInfo.hasNotMatchedAssets,\r\n onClickCallback: this.createAssetsNotMatchedFromWorkPapers.bind(this)\r\n },\r\n {\r\n name: 'Create new parcels and assessments for unallocated',\r\n helpContentId: '',\r\n disabled: () => !this._allocationDetailSelectionInfo.hasNewParcels,\r\n onClickCallback: this.createNewParcelsFromDetails.bind(this)\r\n }\r\n ];\r\n\r\n private _assessmentGridApi: GridApi;\r\n private _gridApi: GridApi;\r\n private _gridDataSource: AllocationDetailsListAgGridDataSource;\r\n private _gridMultiSelectSub: Subscription;\r\n private _editGroup: string = 'allocation-details-edit-group';\r\n private _statuses: Compliance.AllocationDetailStatusModel[];\r\n private _totalAssessmentsSummary: AssessmentSummaryInfo;\r\n private _unassignedAssessmentsSummary: AssessmentSummaryInfo;\r\n private _assessmentsSummary: AssessmentSummaryInfo[];\r\n private _dragging: boolean;\r\n private _companyAssetDescriptorMappings: Compliance.CompanyAssetDescriptorMappingModel[];\r\n private _allocationDetailSelectionInfo: Compliance.AllocationDetailSelectionInfo = {\r\n hasNotMatchedAssets: false,\r\n hasNewParcels: false\r\n };\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(ALLOCATIONS_HELP);\r\n\r\n this.allocationId = parseInt(this._routerService.getQuerystringParam('allocationId'));\r\n this.canViewRyanPrivateItems = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading Allocation Details' });\r\n\r\n try {\r\n await lastValueFrom(this._allocationRepository.prepareData(this.allocationId));\r\n\r\n this.allocation = await lastValueFrom(this._allocationRepository.get(this.allocationId));\r\n this.companyId = this.allocation.companyId;\r\n\r\n const responses = await Promise.all([\r\n lastValueFrom(this._allocationDetailRepository.getStatuses(this.allocationId)),\r\n lastValueFrom(this._allocationRepository.getAssessmentsSummary(this.allocationId, {} as Compliance.AllocationAssessmentSummarySearchModel)),\r\n lastValueFrom(this._companyAssetDescriptorRepository.getByCompanyId(this.allocation.companyId)),\r\n this._restrictService.hasCompanyPermission(this.companyId, Core.AccessRightsEnum.Write),\r\n this._companyService.load(this.companyId, false, false)\r\n ]);\r\n\r\n this._statuses = responses[0] as Compliance.AllocationDetailStatusModel[];\r\n _.orderBy(this._statuses, i => i.displayOrder);\r\n\r\n this._statuses.splice(0, 0, {} as Compliance.AllocationDetailStatusModel);\r\n\r\n this._setAssessmentsSummary(this._convertToAssessmentSummaryInfo(responses[1] as Compliance.AllocationAssessmentSummaryModel[]));\r\n\r\n this._companyAssetDescriptorMappings = responses[2] as Compliance.CompanyAssetDescriptorMappingModel[];\r\n\r\n this.canEditCompany = responses[3];\r\n\r\n const company = responses[4];\r\n if (!(company.ppReturnPreparationAllowed && this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, company.instanceID))) {\r\n this.navigateToUnauthorized();\r\n }\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n const navigationProperties = await this._siteService.getNavigationInfo(this.allocation.siteId);\r\n const companyName = await this._companyService.getCompanyName(navigationProperties.companyID);\r\n this.breadcrumbs = [\r\n {\r\n name: companyName,\r\n target: 'company',\r\n options: { companyId: navigationProperties.companyID }\r\n },\r\n {\r\n name: this.allocation.siteName,\r\n target: 'site',\r\n options: { companyId: navigationProperties.companyID, siteId: navigationProperties.siteID }\r\n }\r\n ];\r\n\r\n this.assessors = this.allocation.assessors\r\n .sort((x, y) => x.assessorName.localeCompare(y.assessorName))\r\n .map(x => { return {\r\n name: x.assessorName,\r\n target: 'assessor',\r\n options: {stateId: x.stateId, id: x.assessorId}\r\n } as BreadCrumb;});\r\n\r\n this._allocationDetailDragAndDropService.start(this._getDraggedAllocationDetailIds.bind(this));\r\n this._allocationDetailDragAndDropService.dragging$.pipe(takeUntil(this._destroy$)).subscribe(x => {\r\n if (x) {\r\n this._setAssessmentDraggingColumns();\r\n } else {\r\n this._setAssessmentGridColumns();\r\n }\r\n });\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._allocationDetailDragAndDropService.stop();\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n this._allocationService.navigationParcelId = null;\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n get uploadNewImport(): boolean {\r\n return !this.allocation || !this.allocation.lastImportFile || this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.Completed;\r\n }\r\n\r\n async navigateToLastImport(): Promise {\r\n if (this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.Processing ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.Transferring ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.Reverting ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.Validating) {\r\n await this.newImport.showImportFileIsProcessingMessage(this.allocation.lastImportFile);\r\n } else if (this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.Uploaded ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.ShowPreview) {\r\n const resumeResult = await this.newImport.resumeImport(this.allocation.lastImportFile);\r\n if (resumeResult) {\r\n this._routerService.go('processAllocationImport', {\r\n allocationId: this.allocationId,\r\n importId: this.allocation.lastImportFileId\r\n });\r\n }\r\n } else if (this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.ProcessingError ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.ProcessingCompleted ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.Transferred ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.TransferError ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.TransferCompleted ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.RevertingError ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.Completed ||\r\n this.allocation.lastImportFile.processStatus === Compliance.ImportFileProcessStatusEnum.Validated) {\r\n this._routerService.go('processAllocationImport', {\r\n allocationId: this.allocationId,\r\n importId: this.allocation.lastImportFileId\r\n });\r\n }\r\n }\r\n\r\n onAssessmentAgGridReady(event: GridReadyEvent): void {\r\n this._assessmentGridApi = event.api;\r\n\r\n this.assessmentGridTracker = new AgGridMultiSelectTracker(this.assessmentGridOptions, this._getAssessmentGridRowIds.bind(this));\r\n\r\n this._setAssessmentGridColumns();\r\n this._setAssessmentsSummary([...this._assessmentsSummary, this._totalAssessmentsSummary, this._unassignedAssessmentsSummary]);\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._setGridColumns();\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'assetNumber',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n\r\n // notify the bulk update button (on the column tool panel) every time the grid selection changes\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(async () => {\r\n const isBulkUpdateVisible = this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n this.hasSelectedRows = isBulkUpdateVisible;\r\n\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n const model: Compliance.SelectedRowsModel = {\r\n selectAllRows: selectedRowsModel.selectAllRows,\r\n selectedRows: selectedRowsModel.selectedRows\r\n };\r\n\r\n lastValueFrom(this._allocationDetailRepository.getSelectedRowsInfo(this.allocationId, model)).then(x => this._allocationDetailSelectionInfo = x);\r\n await this._reloadTotals();\r\n });\r\n }\r\n\r\n startEditMode(): void {\r\n this.editing = true;\r\n this._mutexService.acquire(this, this._editGroup);\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you wish to leave?');\r\n }\r\n\r\n endEditMode(): void {\r\n this.editing = false;\r\n this._gridApi.stopEditing();\r\n this._mutexService.release(this, this._editGroup);\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n handleTotalsUpdate = (totals: Compliance.AllocationDetailTotalsModel, selectedTotals: boolean = false, isLoading: boolean = false) => {\r\n const totalsRow: any = {\r\n reportedCost: totals.totalReportedCost,\r\n returnValue: totals.totalReturnValue,\r\n initialAllocationAmount: totals.totalInitialAllocationValue,\r\n finalAllocationAmount: totals.totalFinalAllocationValue,\r\n estimatedFMV: totals.totalEstimatedFMV,\r\n inventoryApr: totals.totalInventoryApr,\r\n inventoryAug: totals.totalInventoryAug,\r\n inventoryAvr: totals.totalInventoryAvr,\r\n inventoryAvrCalculated: totals.totalInventoryAvrCalculated,\r\n inventoryDec: totals.totalInventoryDec,\r\n inventoryFeb: totals.totalInventoryFeb,\r\n inventoryJan: totals.totalInventoryJan,\r\n inventoryJul: totals.totalInventoryJul,\r\n inventoryJun: totals.totalInventoryJun,\r\n inventoryMar: totals.totalInventoryMar,\r\n inventoryMay: totals.totalInventoryMay,\r\n inventoryNov: totals.totalInventoryNov,\r\n inventoryOct: totals.totalInventoryOct,\r\n inventorySep: totals.totalInventorySep,\r\n leaseMonthlyPayment: totals.totalLeaseMonthlyPayment,\r\n n1: totals.totalN1,\r\n n10: totals.totalN10,\r\n n2: totals.totalN2,\r\n n3: totals.totalN3,\r\n n4: totals.totalN4,\r\n n5: totals.totalN5,\r\n n6: totals.totalN6,\r\n n7: totals.totalN7,\r\n n8: totals.totalN8,\r\n n9: totals.totalN9,\r\n netBookValue: totals.totalNetBookValue,\r\n workPaperCost: totals.totalWorkPaperCost,\r\n varianceDollar: totals.totalVarianceDollar,\r\n priorYearFinalAllocationAmount: totals.totalPriorYearFinalAllocationAmount,\r\n taxVarianceDollar: totals.totalTaxVarianceDollar\r\n };\r\n\r\n if (isLoading) {\r\n this.totalsLoading = this._gridDataSource.getLoadingMessage(msg => {\r\n totalsRow.assetNumber = msg;\r\n this._gridApi.setPinnedBottomRowData([totalsRow]);\r\n });\r\n return;\r\n } else if (!isLoading && this.totalsLoading >= 0) {\r\n clearInterval(this.totalsLoading);\r\n this.totalsLoading = null;\r\n }\r\n\r\n if (selectedTotals) {\r\n totalsRow.selectedTotalsRow = true;\r\n totalsRow.assetNumber = 'SELECTED';\r\n this.assetGridSelectedTotalsRow = totalsRow;\r\n } else {\r\n totalsRow.totalsRow = true;\r\n totalsRow.assetNumber = 'TOTAL';\r\n this.assetGridTotalsRow = totalsRow;\r\n }\r\n const totalRows = [this.assetGridTotalsRow];\r\n if (this.gridTracker.hasAnythingSelected()) {\r\n totalRows.push(this.assetGridSelectedTotalsRow);\r\n }\r\n setTimeout(() => this._gridApi.setPinnedBottomRowData(totalRows), 100);\r\n };\r\n\r\n refresh(): void {\r\n this.refreshAssetsList();\r\n this._refreshAssessmentsSummary();\r\n }\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n get hasLockedAssessments(): boolean {\r\n return !!_.find(this._assessmentsSummary, i => i.isLocked && i.isSelected && !i.isComitted);\r\n }\r\n\r\n get hasLockedNotReviewedAssessments(): boolean {\r\n return !!_.find(this._assessmentsSummary, i => i.isLocked && !i.isMarkedAsReviewed && i.isSelected);\r\n }\r\n\r\n async onAllocationDetailsDropped(allocationDetailIds: number[], summary: AssessmentSummaryInfo): Promise {\r\n let allocationAnnualAssessmentIds: number[];\r\n\r\n if (!summary.isTaxAuthority && summary.taxAuthoritiesCount != 0) {\r\n const parcelTaxAuthorities = this._assessmentsSummary\r\n .filter(x => x.annualAssessmentId === summary.annualAssessmentId && x.isTaxAuthority);\r\n\r\n const params: SelectTaxAuthoritiesParams = {\r\n allocationId: this.allocationId,\r\n selectedAllocationDetailIds: allocationDetailIds,\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp,\r\n taxAuthorities: parcelTaxAuthorities\r\n };\r\n\r\n const result = await this._modalService.showAsync(SelectTaxAuthorityComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n allocationAnnualAssessmentIds = result.selectedAssessmentSummaries;\r\n } else if (summary.allocationAnnualAssessmentId) {\r\n allocationAnnualAssessmentIds = [summary.allocationAnnualAssessmentId];\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Allocating Assets' });\r\n\r\n try {\r\n const model: Compliance.AllocationDetailAllocateModel = {\r\n allocationAnnualAssessmentIds: allocationAnnualAssessmentIds,\r\n selectAllRows: false,\r\n selectedRows: allocationDetailIds,\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp\r\n };\r\n\r\n await lastValueFrom(this._allocationDetailRepository.allocate(this.allocationId, model));\r\n\r\n const assessmentsSummary = await lastValueFrom(this._allocationRepository.getAssessmentsSummary(this.allocationId,\r\n { hideLockedAssessment: this.hideLockedAssessments } as Compliance.AllocationAssessmentSummarySearchModel));\r\n this._setAssessmentsSummary(this._convertToAssessmentSummaryInfo(assessmentsSummary));\r\n this.refreshAssetsList();\r\n } finally {\r\n this.gridTracker.clear();\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n onAllocationSummaryFilterClick(value: AssessmentSummaryInfo): void {\r\n this._allocationDetailService.allocationDetailsFilter = value;\r\n\r\n this.refreshAssetsList();\r\n }\r\n\r\n clearAssessmentFilter(): void {\r\n this._allocationDetailService.allocationDetailsFilter = null;\r\n this._assessmentGridApi.deselectAll();\r\n\r\n this.refreshAssetsList();\r\n }\r\n\r\n async addTaxAuthority(): Promise {\r\n const params: AddTaxAuthorityParams = {\r\n allocationId: this.allocationId,\r\n showWarning: this._assessmentsSummary.some(x =>\r\n x.summaryType === AllocationAssessmentSummaryTypeEnum.Normal && x.annualAssessmentId &&\r\n !x.isTaxAuthority && !x.isLocked && x.assetsCount && x.taxAuthoritiesCount === 0)\r\n };\r\n\r\n const result = await this._modalService.showAsync(AddTaxAuthorityComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n result.newSummaries.forEach(x => this._assessmentsSummary.push(new AssessmentSummaryInfo(x)));\r\n this._setAssessmentsSummary([...this._assessmentsSummary, this._totalAssessmentsSummary, this._unassignedAssessmentsSummary]);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async onLockReleaseLockedAssessmentClick(assessmentSummaryInfo: AssessmentSummaryInfo, lock: boolean): Promise {\r\n const model = {\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp\r\n } as Compliance.SelectAllocationAssessmentModel;\r\n\r\n if (this.isUnchecked()) {\r\n model.selectedRows = [assessmentSummaryInfo.allocationAnnualAssessmentId];\r\n } else {\r\n model.selectedRows = _(this._assessmentsSummary)\r\n .filter(i => i.isSelected && (lock && i.canLock || !lock && i.canReleaseLock))\r\n .map(i => i.allocationAnnualAssessmentId)\r\n .value();\r\n if (!_.find(model.selectedRows, i => i === assessmentSummaryInfo.allocationAnnualAssessmentId)) {\r\n model.selectedRows.push(assessmentSummaryInfo.allocationAnnualAssessmentId);\r\n }\r\n }\r\n if (lock) {\r\n await this._lockAssessments(model);\r\n } else{\r\n await this._releaseLockedAssessments(model);\r\n }\r\n }\r\n\r\n async bulkUpdate(): Promise {\r\n const searchModel = this._gridDataSource.getSearchParamsWithoutPagination();\r\n\r\n const params: AllocationDetailBulkUpdateParams = {\r\n allocationId: this.allocationId,\r\n selection: this.gridTracker.getSelectedRowsModel(),\r\n selectedCount: this.gridTracker.getSelectedRowsCount(),\r\n allocationDetailListLastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp,\r\n statuses: this._statuses,\r\n assessmentsSummary: this._assessmentsSummary,\r\n removeExistingAllocations: true\r\n };\r\n\r\n if (params.selection.selectAllRows && searchModel.summaryFilter) {\r\n const selectedRowIds = await this.gridTracker.getSelectedRowIds();\r\n params.selection.selectAllRows = false;\r\n params.selection.selectedRows = selectedRowIds;\r\n }\r\n\r\n const result = await this._modalService.showAsync(AllocationDetailBulkUpdateComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const assessmentsSummary = await lastValueFrom(this._allocationRepository.getAssessmentsSummary(this.allocationId,\r\n { hideLockedAssessment: this.hideLockedAssessments } as Compliance.AllocationAssessmentSummarySearchModel));\r\n this._setAssessmentsSummary(this._convertToAssessmentSummaryInfo(assessmentsSummary));\r\n\r\n this.gridTracker.clear();\r\n await this.refreshAssetsList();\r\n await this._reloadTotals();\r\n }\r\n\r\n isChecked(): boolean {\r\n const totalAssessmentsCount = this._assessmentsSummary.length;\r\n const checkedCount = _.filter(this._assessmentsSummary, i => i.isSelected).length;\r\n\r\n return totalAssessmentsCount !== 0 && totalAssessmentsCount === checkedCount;\r\n }\r\n\r\n isUnchecked(): boolean {\r\n const totalAssessmentsCount = this._assessmentsSummary.length;\r\n const unCheckedCount = _.filter(this._assessmentsSummary, i => !i.isSelected).length;\r\n\r\n return totalAssessmentsCount === unCheckedCount;\r\n }\r\n\r\n isIndeterminate(): boolean {\r\n const totalAssessmentsCount = this._assessmentsSummary.length;\r\n const checkedCount = _.filter(this._assessmentsSummary, i => i.isSelected).length;\r\n\r\n return totalAssessmentsCount !== checkedCount && !!checkedCount;\r\n }\r\n\r\n async onDeletTaxAuthorityClick(assessmentSummaryInfo: AssessmentSummaryInfo): Promise {\r\n const model = {} as Compliance.DeleteTaxAuthorityModel;\r\n\r\n if (this.isUnchecked()) {\r\n model.selectedRows = [assessmentSummaryInfo.allocationAnnualAssessmentId];\r\n } else if (this.isIndeterminate()) {\r\n model.selectedRows = _(this._assessmentsSummary)\r\n .filter(i => i.isSelected && i.canDelete)\r\n .map(i => i.allocationAnnualAssessmentId)\r\n .value();\r\n if (!_.find(model.selectedRows, i => i === assessmentSummaryInfo.allocationAnnualAssessmentId)) {\r\n model.selectedRows.push(assessmentSummaryInfo.allocationAnnualAssessmentId);\r\n }\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting Tax Authorities' });\r\n\r\n try {\r\n const affectedAssessmentSummaries = await lastValueFrom(this._allocationRepository.deleteTaxAuthority(this.allocationId, model));\r\n\r\n this._assessmentsSummary = this._assessmentsSummary.filter(x => _.find(model.selectedRows, j => j !== x.allocationAnnualAssessmentId));\r\n affectedAssessmentSummaries.forEach(x => {\r\n const index = this._assessmentsSummary.findIndex(y => y.allocationAnnualAssessmentId === x.allocationAnnualAssessmentId);\r\n if (index >= 0) {\r\n this._assessmentsSummary[index] = new AssessmentSummaryInfo(x);\r\n }\r\n });\r\n this._setAssessmentsSummary([...this._assessmentsSummary, this._totalAssessmentsSummary, this._unassignedAssessmentsSummary]);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n sizeToFit(): void {\r\n this.assessmentGridOptions.api.sizeColumnsToFit();\r\n }\r\n\r\n sizeToContent(): void {\r\n this.assessmentGridOptions.columnApi.autoSizeAllColumns();\r\n }\r\n\r\n toggleAssessmentGridFilters(): void {\r\n this.assessmentGridOptions.floatingFilter = !this.assessmentGridOptions.floatingFilter;\r\n this.assessmentGridOptions.api.refreshHeader();\r\n\r\n // clear filter when hiding\r\n if (!this.assessmentGridOptions.floatingFilter) {\r\n this.assessmentGridOptions.api.setFilterModel(null);\r\n this.assessmentGridOptions.api.onFilterChanged();\r\n }\r\n }\r\n\r\n async filterAssessmentsSummary(filterSummary: string): Promise {\r\n if (filterSummary !== this.assessmentsSummaryFilter) {\r\n this.assessmentsSummaryFilter = filterSummary;\r\n await this._refreshAssessmentsSummary();\r\n }\r\n }\r\n\r\n get isFiltered(): boolean {\r\n return !!this.assessmentsSummaryFilter && this.assessmentsSummaryFilter !== '';\r\n }\r\n\r\n get hasReadyToLockAllocations(): boolean {\r\n return !!_.find(this._assessmentsSummary, i =>\r\n i.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal &&\r\n !i.isTaxAuthority &&\r\n !i.isLocked &&\r\n i.isActual &&\r\n i.FMV &&\r\n i.allocationAmount &&\r\n i.variance === 0 &&\r\n i.isSelected);\r\n }\r\n\r\n get canDistributeVariance(): boolean {\r\n return !!_.find(this._assessmentsSummary, i =>\r\n i.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal &&\r\n !i.isTaxAuthority &&\r\n !i.isLocked &&\r\n i.FMV &&\r\n i.variance !== 0 &&\r\n i.isSelected);\r\n }\r\n\r\n async lockAllocation(): Promise {\r\n const model = {\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp\r\n } as Compliance.SelectAllocationAssessmentModel;\r\n\r\n model.selectedRows = _(this._assessmentsSummary)\r\n .filter(i => i.variance === 0 && !i.isLocked && (this.isChecked() || i.isSelected))\r\n .map(i => i.allocationAnnualAssessmentId)\r\n .value();\r\n\r\n await this._lockAssessments(model);\r\n }\r\n\r\n async releaseLockedAllocation(): Promise {\r\n const model = {\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp\r\n } as Compliance.SelectAllocationAssessmentModel;\r\n\r\n model.selectedRows = _(this._assessmentsSummary)\r\n .filter(i => i.isLocked && (this.isChecked() || i.isSelected))\r\n .map(i => i.allocationAnnualAssessmentId)\r\n .value();\r\n\r\n await this._releaseLockedAssessments(model);\r\n }\r\n\r\n async distributeVariance(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Distributing Variance' });\r\n\r\n const selectedRows = this.isChecked()\r\n ? []\r\n : _(this._assessmentsSummary)\r\n .filter(i => i.variance !== 0 && !i.isLocked && this.isChecked() ? !i.isSelected : i.isSelected)\r\n .map(i => i.allocationAnnualAssessmentId)\r\n .value();\r\n\r\n const model = {\r\n selectAllRows: this.isChecked(),\r\n selectedRows: selectedRows,\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp\r\n } as Compliance.AllocationDistributeAssessmentVarianceModel;\r\n\r\n try {\r\n const result = await lastValueFrom(this._allocationRepository.distributeAssessmentVariance(this.allocationId, model));\r\n\r\n _.forEach(result.assessmentsSummary, u => {\r\n const existingSummaryIndex = _.findIndex(this._assessmentsSummary,\r\n e => e.allocationAnnualAssessmentId === u.allocationAnnualAssessmentId);\r\n this._assessmentsSummary[existingSummaryIndex] = new AssessmentSummaryInfo(u);\r\n });\r\n\r\n _(this._assessmentsSummary)\r\n .filter(i => i.isSelected)\r\n .forEach(i => (i.isSelected = false) || true);\r\n this.refreshAssetsList();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async onHideNotReportedAssetsChange(): Promise {\r\n this.refreshAssetsList();\r\n }\r\n\r\n async createAssetsNotMatchedFromWorkPapers(): Promise {\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n const model: Compliance.AllocationDetailCreateAssetsNotMatchedFromWorkPapersModel = {\r\n selectedRows: selectedRowsModel.selectedRows,\r\n selectAllRows: selectedRowsModel.selectAllRows,\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Creating Assets' });\r\n try {\r\n await lastValueFrom(this._allocationDetailRepository.createAssetsNotMatchedFromWorkPapers(this.allocationId, model));\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n this.refreshAssetsList();\r\n }\r\n\r\n async matchToExistingNonAllocatedAssets(): Promise {\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n const model: Compliance.AllocationDetailCreateAssetsNotMatchedFromWorkPapersModel = {\r\n selectedRows: selectedRowsModel.selectedRows,\r\n selectAllRows: selectedRowsModel.selectAllRows,\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Matching to existing non-allocated Assets' });\r\n try {\r\n await lastValueFrom(this._allocationDetailRepository.matchToExistingNonAllocatedAssets(this.allocationId, model));\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n this.refreshAssetsList();\r\n }\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.allocation) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: 'Allocation',\r\n entityName: this.allocation.description,\r\n entityData: {\r\n typeId: Core.EntityTypes.Allocation,\r\n id: this.allocation.allocationId,\r\n name: this.allocation.description\r\n },\r\n singleYear: true,\r\n year: this.allocation.taxYear,\r\n disableYears: true,\r\n readOnly: !this.canEditCompany\r\n } as AttachmentModalData;\r\n }\r\n\r\n get commentsModel(): CommentModalData {\r\n if (!this.allocation) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityID: this.allocation.allocationId,\r\n entityTypeID: Core.EntityTypes.Allocation,\r\n description: this.allocation.description,\r\n year: this.allocation.taxYear.toString(),\r\n canEdit: this.canEditCompany,\r\n parcelAcctNum: undefined,\r\n parcelID: undefined\r\n } as CommentModalData;\r\n }\r\n\r\n get allocationDescription(): string {\r\n let result = this.allocation.description;\r\n\r\n if (result.length > 50) {\r\n result = `${result.substring(0, 47) }...`;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n get allAssessmentActionsDisabled(): boolean {\r\n return this.assessmentActions.every(x => x.disabled);\r\n }\r\n\r\n async onActionSelected(action): Promise {\r\n switch (action.value as AssessmentActions) {\r\n case AssessmentActions.LockAllocation:\r\n await this.lockAllocation();\r\n break;\r\n case AssessmentActions.ReleaseLockedAllocation:\r\n await this.releaseLockedAllocation();\r\n break;\r\n case AssessmentActions.DistributeVariance:\r\n await this.distributeVariance();\r\n break;\r\n case AssessmentActions.CreateNewMergedParcels:\r\n await this.createNewParcelsFromAssessmentSummary();\r\n break;\r\n default:\r\n throw Error(`Unknown action: [${action.value}]`);\r\n }\r\n\r\n this.selectedAction = null;\r\n }\r\n\r\n async createNewParcelsFromDetails(): Promise {\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n const params: CreateNewMergedParcelsParams = {\r\n allocationId: this.allocationId,\r\n allocationDetailSelectRowsModel: {\r\n selectedRows: selectedRowsModel.selectedRows,\r\n selectAllRows: selectedRowsModel.selectAllRows\r\n }\r\n };\r\n\r\n await this.createNewParcels(params);\r\n }\r\n\r\n async createNewParcelsFromAssessmentSummary(): Promise {\r\n const selectedAllocationAssessmentSummaryIds = this._assessmentsSummary\r\n .filter(i => i.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Phantom && i.isSelected)\r\n .map(i => i.allocationAnnualAssessmentId);\r\n const params: CreateNewMergedParcelsParams = {\r\n allocationId: this.allocationId,\r\n selectedAssessmentSummaryIds: selectedAllocationAssessmentSummaryIds\r\n };\r\n\r\n await this.createNewParcels(params);\r\n }\r\n\r\n async createNewParcels(params: CreateNewMergedParcelsParams): Promise {\r\n const result = await this._modalService.showAsync(CreateNewMergedParcelsComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n _.forEach(result.assessmentsSummary, u => {\r\n const existingSummaryIndex = _.findIndex(this._assessmentsSummary,\r\n e => e.allocationAnnualAssessmentId === u.allocationAnnualAssessmentId);\r\n this._assessmentsSummary[existingSummaryIndex] = new AssessmentSummaryInfo(u);\r\n });\r\n\r\n this.refreshAssetsList();\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n get canCreateMergedParcels(): boolean {\r\n return !!_.find(this._assessmentsSummary,\r\n i => i.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Phantom && i.isSelected);\r\n }\r\n\r\n async retrieveAssets(): Promise {\r\n const params: RetrieveAssetsParams = {\r\n allocationId: this.allocationId\r\n };\r\n\r\n const result = await this._modalService.showAsync(RetrieveAssetsComponent, params, 'modal-xl');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.refresh();\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async markAllocationReviewed(): Promise {\r\n const model = {\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp\r\n } as Compliance.SelectAllocationAssessmentModel;\r\n\r\n model.selectedRows = _(this._assessmentsSummary)\r\n .filter(i => i.isLocked && (this.isChecked() || i.isSelected))\r\n .map(i => i.allocationAnnualAssessmentId)\r\n .value();\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Marking Allocation Reviewed' });\r\n\r\n let result: Compliance.AllocationAssessmentUpdateResultModel;\r\n\r\n try {\r\n result = await lastValueFrom(this._allocationRepository.markAllocationReviewed(this.allocationId, model));\r\n\r\n _.forEach(result.assessmentsSummary, u => {\r\n const existingSummaryIndex = _.findIndex(this._assessmentsSummary,\r\n e => e.allocationAnnualAssessmentId === u.allocationAnnualAssessmentId);\r\n this._assessmentsSummary[existingSummaryIndex] = new AssessmentSummaryInfo(u);\r\n });\r\n\r\n this.assessmentGridTracker.clear();\r\n this._setAssessmentsSummary([...this._assessmentsSummary, this._totalAssessmentsSummary, this._unassignedAssessmentsSummary]);\r\n } finally {\r\n if (!result) {\r\n _.forEach(model.selectedRows, x => {\r\n const assessmentSummary = _.find(this._assessmentsSummary,\r\n e => e.allocationAnnualAssessmentId === x);\r\n assessmentSummary.isLocked = false;\r\n });\r\n }\r\n\r\n busyRef.hide();\r\n }\r\n\r\n if (result && result.assessmentsSummary.length) {\r\n try {\r\n const options: MessageModalOptions = {\r\n displayMode: MessageModalDisplayMode.SingleMessage,\r\n buttons: MessageModalButtons.OK,\r\n focusButton: MessageModalResult.OK,\r\n message: 'Selected Locked Allocations Reviewed',\r\n title: 'Mark Allocation Reviewed'\r\n };\r\n\r\n await this._messageModalService.open(options);\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n }\r\n }\r\n\r\n private _setAssessmentGridColumns(): void {\r\n if (!this._assessmentGridApi) { return; }\r\n this._dragging = false;\r\n const columns: ColDef[] = [\r\n {\r\n headerName: '',\r\n field: 'allocationAnnualAssessmentId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.assessmentGridTracker,\r\n updateAllRowValues: (params, checked) => {\r\n this._assessmentsSummary.forEach(x => x.isSelected = checked);\r\n this._updateAssessmentActions();\r\n }\r\n } as AgGridMultiSelectHeaderRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.assessmentGridTracker,\r\n updateRowValue: (params, checked) => {\r\n const assessment = params.data as AssessmentSummaryInfo;\r\n assessment.isSelected = checked;\r\n this._updateAssessmentActions();\r\n },\r\n isCellRendererHiddenFn: (rowId, data) => {\r\n const summary = data as AssessmentSummaryInfo;\r\n return summary && summary.isTaxAuthority;\r\n }\r\n } as AgGridMultiSelectCellRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n },\r\n {\r\n headerName: 'Assessment',\r\n field: 'title',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n lockVisible: true,\r\n lockPosition: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n suppressMovable: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => '',\r\n newWindow: true,\r\n isHelpDisabled: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const summary = params.data as AssessmentSummaryInfo;\r\n if (summary && !summary.isTaxAuthority) {\r\n return this._routerService.getHrefFromState('parcel', {\r\n companyId: summary.companyId,\r\n siteId: summary.siteId,\r\n parcelId: summary.parcelId,\r\n annualYearID: summary.annualYearId,\r\n annualAssessmentID: summary.annualAssessmentId\r\n });\r\n }\r\n\r\n return null;\r\n },\r\n getText: (params: AgGridLinkCellRendererParams) => {\r\n const summary = params.data as AssessmentSummaryInfo;\r\n return summary.isTaxAuthority ? summary.taxAuthorityName : summary.title;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const summary = params.data as AssessmentSummaryInfo;\r\n return !(summary && summary.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal\r\n && !summary.isTaxAuthority);\r\n },\r\n getStyle: (params: AgGridLinkCellRendererParams) => {\r\n const assessmentSummary = params.data as AssessmentSummaryInfo;\r\n return assessmentSummary && assessmentSummary.taxAuthorityName\r\n ? {'width': '100%', 'text-align': 'right'}\r\n : null;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n valueFormatter: (x) => {\r\n const assessmentSummary = x.data as AssessmentSummaryInfo;\r\n return assessmentSummary.taxAuthorityName || assessmentSummary.title;\r\n }\r\n },\r\n {\r\n headerName: 'FMV',\r\n field: 'FMV',\r\n cellClass: 'ag-numeric-cell',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (x) => {\r\n const assessmentSummary = x.data as AssessmentSummaryInfo;\r\n return !assessmentSummary.taxAuthorityName ? this._decimalPipe.transform(x.value, '1.2-2') : '';\r\n },\r\n },\r\n {\r\n headerName: 'Alloc',\r\n field: 'allocationAmount',\r\n cellClass: 'ag-numeric-cell',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n },\r\n {\r\n headerName: 'Count',\r\n field: 'assetsCount',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Var',\r\n field: 'variance',\r\n cellClass: 'ag-numeric-cell',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (x) => {\r\n const assessmentSummary = x.data as AssessmentSummaryInfo;\r\n return !assessmentSummary.taxAuthorityName ? this._decimalPipe.transform(x.value, '1.2-2') : '';\r\n },\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(3),\r\n minWidth: AgGridColumns.getActionColumnWidth(3),\r\n maxWidth: AgGridColumns.getActionColumnWidth(3),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n pinned: 'right',\r\n headerComponentFramework: AgGridAssessmentSummaryActionHeaderRendererComponent,\r\n headerComponentParams: {\r\n showLockedAssessmentsChange: (show: boolean) => {\r\n this.hideLockedAssessments = !show;\r\n this._refreshAssessmentsSummary();\r\n },\r\n clearFilter: this.clearAssessmentFilter.bind(this)\r\n } as ICellRendererParamsForAssessmentSummaryHeaderRenderer,\r\n cellRendererFramework: AgGridAssessmentSummaryActionCellRendererComponent,\r\n cellRendererParams: {\r\n deleteAssessmentClicked: this.onDeletTaxAuthorityClick.bind(this),\r\n lockReleaseLockedAssessmentClicked: this.onLockReleaseLockedAssessmentClick.bind(this),\r\n filterClicked: this.onAllocationSummaryFilterClick.bind(this),\r\n clearFilterClicked: this.clearAssessmentFilter.bind(this)\r\n } as ICellRendererParamsForAssessmentSummaryCellRenderer\r\n }\r\n ];\r\n this._assessmentGridApi.setColumnDefs(columns);\r\n this._assessmentGridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _setAssessmentDraggingColumns(): void {\r\n this._dragging = true;\r\n const dropZoneColumn = {\r\n headerName: 'Assessment',\r\n field: 'allocationAnnualAssessmentId',\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n cellRendererFramework: AllocationDetailDragAndDropCellRendererComponent,\r\n cellRendererParams: {\r\n allocationDetailsDropped: this.onAllocationDetailsDropped.bind(this)\r\n } as DragAndDropCellRendererParams,\r\n };\r\n this._assessmentGridApi.setColumnDefs([dropZoneColumn]);\r\n this._assessmentGridApi.sizeColumnsToFit();\r\n this._assessmentGridApi.redrawRows();\r\n }\r\n\r\n private _setGridColumns(): void {\r\n const columns: ColDef[] = [\r\n {\r\n headerName: '',\r\n field: 'allocationDetailId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n cellRendererFramework: AllocationDetailDragAndDropSourceComponent,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as ICellRendererParamsForAllocationDetailDragAndDropSource\r\n },\r\n {\r\n headerName: '',\r\n field: 'allocationDetailId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n },\r\n {\r\n headerName: 'Asset Number',\r\n field: 'assetNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n lockVisible: true,\r\n lockPosition: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n suppressMovable: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n toolPanelClass: 'Asset',\r\n editable: (params) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return this._isRowEditable(params) &&\r\n (allocationDetail && !allocationDetail.returnAssetId && !allocationDetail.assetId);\r\n },\r\n cellClass: (params: ICellRendererParams) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.assetNumber && !params.data.selectedTotalsRow &&\r\n !params.data.totalsRow &&\r\n (!allocationDetail.returnAssetId && !allocationDetail.assetId ||\r\n !!allocationDetail.parcelSiteId && allocationDetail.parcelSiteId !== this.allocation.siteId)\r\n ? ' ws-override'\r\n : '';\r\n },\r\n cellEditorFramework: AgGridTextCellEditor,\r\n cellEditorParams: {\r\n canReset: true,\r\n hasOverride: (params) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.assetNumber &&\r\n !allocationDetail.returnAssetId && !allocationDetail.assetId;\r\n }\r\n },\r\n onCellValueChanged: this._onValueChanged.bind(this)\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Description (WP)',\r\n field: 'workPaperDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Company Code',\r\n field: 'companyCode',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'G/L Account',\r\n field: 'glAccount',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'G/L Account Number',\r\n field: 'glAccountNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Change Status',\r\n field: 'assetReturnStatus',\r\n cellRendererFramework: ReturnAssetChangeIconCellRendererComponent,\r\n width: 120,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n sortable: false,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Split Allocation %',\r\n field: 'splitAllocationPercentage',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._decimalPipe.transform(params.value, '1.2-2') : null,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Classification',\r\n field: 'classificationName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Parcel Address (Complete)',\r\n field: 'parcelAddressComplete',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Linked/Sub Parcel',\r\n field: 'linkedParcelAccountNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: false,\r\n toolPanelClass: 'Asset',\r\n cellClass: (params: ICellRendererParams) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.parcelIsDifferent ? ' ws-override' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Parcel',\r\n field: 'parcel',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n toolPanelClass: 'Asset',\r\n cellClass: (params: ICellRendererParams) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.parcelIsDifferent ? ' ws-override' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Parcel Desc.',\r\n field: 'parcelDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset',\r\n cellClass: (params: ICellRendererParams) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.parcelIsDifferent ? ' ws-override' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Linked/Sub Parcel Desc.',\r\n field: 'linkedParcelDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorAbbr',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n }, {\r\n headerName: 'Assessor (WP)',\r\n field: 'workPaperAssessor',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Linked/Sub Assessor',\r\n field: 'linkedParcelAssessorAbbr',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Prior Acq. Date',\r\n field: 'priorAcqDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n toolPanelClass: 'Asset'\r\n } as ColDef,\r\n {\r\n headerName: 'Acq. Date',\r\n field: 'acqDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Acq. Date (WP)',\r\n field: 'workPaperAcqDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Acq. Year (WP)',\r\n field: 'workPaperAcqYear',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Prior Cost',\r\n field: 'priorCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n } as ColDef,\r\n {\r\n headerName: 'Cost (Reported)',\r\n field: 'reportedCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Cost (WP)',\r\n field: 'workPaperCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Cost Change',\r\n field: 'costChange',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n } as ColDef,\r\n {\r\n headerName: 'Return Value',\r\n field: 'returnValue',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return !allocationDetail\r\n ? null\r\n : allocationDetail.returnValue || allocationDetail.returnValue === 0\r\n ? this._decimalPipe.transform(allocationDetail.returnValue, '1.2-2')\r\n : 'N/A';\r\n },\r\n cellClass: 'ag-numeric-cell',\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Init Alloc Value',\r\n field: 'initialAllocationAmount',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n let additionalClass = '';\r\n if (allocationDetail) {\r\n if (allocationDetail.initialAllocationAmountOverridden) {\r\n additionalClass = ' ws-override';\r\n } else if (allocationDetail.initialAllocationAmountCalculated) {\r\n additionalClass = ' ws-calculated';\r\n }\r\n }\r\n return `ag-numeric-cell${additionalClass}`;\r\n },\r\n editable: (params) => this._isRowEditable(params),\r\n cellEditorFramework: AgGridNumberCellEditor,\r\n cellEditorParams: {\r\n canReset: true,\r\n hasOverride: (params) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.initialAllocationAmountOverridden;\r\n }\r\n },\r\n toolPanelClass: 'Work Papers',\r\n onCellValueChanged: this._onValueChanged.bind(this),\r\n } as ColDef,\r\n {\r\n headerName: 'Final Alloc Value',\r\n field: 'finalAllocationAmount',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return `ag-numeric-cell${ allocationDetail && allocationDetail.finalAllocationAmountOverridden ? ' ws-override' : ''}`;\r\n },\r\n editable: (params) => this._isRowEditable(params),\r\n cellEditorFramework: AgGridNumberCellEditor,\r\n cellEditorParams: {\r\n canReset: true,\r\n hasOverride: (params) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.finalAllocationAmountOverridden;\r\n }\r\n },\r\n toolPanelClass: 'Work Papers',\r\n onCellValueChanged: this._onValueChanged.bind(this),\r\n },\r\n {\r\n headerName: 'Val Variance ($)',\r\n field: 'varianceDollar',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Val Variance (%)',\r\n field: 'variancePercentage',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => (params.value || params.value === 0)\r\n ? this._decimalPipe.transform(params.value * 100, '1.2-2') : '',\r\n cellClass: 'ag-numeric-cell',\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'PY Avg ETR (%)',\r\n field: 'priorYearEffectiveTaxRate',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-6'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Tax Variance ($)',\r\n field: 'taxVarianceDollar',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'PY Value',\r\n field: 'priorYearFinalAllocationAmount',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Prior Yr Factor',\r\n field: 'priorYearFactor',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => (x && x.value) ? `${this._decimalPipe.transform(x.value * 100, '1.2-5')}%` : '',\r\n cellClass: 'ag-numeric-cell',\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Net Book Value',\r\n field: 'netBookValue',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => x.value || x.value === 0 ? this._decimalPipe.transform(x.value, '1.2-2') : null,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'site',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset',\r\n cellClass: (params: ICellRendererParams) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.siteIsDifferent ? ' ws-override' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'siteProperty',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset',\r\n cellClass: (params: ICellRendererParams) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.siteIsDifferent ? ' ws-override' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Site Name',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset',\r\n cellClass: (params: ICellRendererParams) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.siteIsDifferent ? ' ws-override' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Prior Schedule',\r\n field: 'priorScheduleName',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n toolPanelClass: 'Asset'\r\n } as ColDef,\r\n {\r\n headerName: 'Schedule',\r\n field: 'scheduleName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Schedule (WP)',\r\n field: 'workPaperSchedule',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Prior Factor Table',\r\n field: 'priorDepreciationFactorTableName',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.priorDepreciationFactorTableName) ? `${rowData.priorDepreciationFactorTableName} (${rowData.priorDepreciationFactorTableLife} year life)` : '';\r\n },\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Factor Table',\r\n field: 'depreciationFactorTableName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return (rowData && rowData.depreciationFactorTableName)\r\n ? `${rowData.depreciationFactorTableName} (${rowData.depreciationFactorTableLife} year life)` : '';\r\n },\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Factor',\r\n field: 'factor',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => (x && x.value) ? `${this._decimalPipe.transform(x.value * 100, '1.2-5')}%` : '',\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Factor (WP)',\r\n field: 'workPaperFactor',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => (x && x.value) ? `${this._decimalPipe.transform(x.value * 100, '1.2-5')}%` : '',\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n colId: 'calculatedParcel',\r\n headerName: 'Parcel (WP)',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail && allocationDetail.isWorkPaperParcelOverridden ? ' ws-override' : '';\r\n },\r\n editable: (params) => this._isRowEditable(params),\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => {\r\n const items = _(this._assessmentsSummary)\r\n .orderBy(x => x.sortByName)\r\n .filter(i => {\r\n return !i.isTaxAuthority && !i.isLocked ||\r\n i.isTaxAuthority && !this._assessmentsSummary.find(x => x.annualAssessmentId === i.annualAssessmentId && !x.isTaxAuthority).isLocked;})\r\n .map(i => {\r\n return {\r\n name: !i.isTaxAuthority ? i.title : `\\xA0\\xA0${i.taxAuthorityName}`,\r\n value: i.allocationAnnualAssessmentId\r\n };\r\n })\r\n .value();\r\n\r\n items.splice(0, 0, { name: '', value: 0 });\r\n\r\n return items;\r\n },\r\n cellFocusLost: (params, updatedValue) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n let summaryModel = {} as AssessmentSummaryInfo;\r\n\r\n if (!updatedValue) {\r\n summaryModel = new AssessmentSummaryInfo({\r\n summaryType: Compliance.AllocationAssessmentSummaryTypeEnum.Unassigned,\r\n parcelAccountNumber: null\r\n } as Compliance.AllocationAssessmentSummaryModel);\r\n } else {\r\n const existingAllocationSummary = _.find(this._assessmentsSummary,\r\n i => i.allocationAnnualAssessmentId === +updatedValue);\r\n if (existingAllocationSummary) {\r\n summaryModel = existingAllocationSummary;\r\n }\r\n }\r\n\r\n this.onAllocationDetailsDropped([allocationDetail.allocationDetailId], summaryModel);\r\n }\r\n },\r\n valueFormatter: (params) => {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return allocationDetail ? allocationDetail.calculatedParcel : null;\r\n },\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Status',\r\n field: 'statusId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n editable: (params) => this._isRowEditable(params),\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => _.map(this._statuses, i => {\r\n return {\r\n name: i.name,\r\n value: i.allocationDetailStatusId\r\n };\r\n }),\r\n },\r\n valueFormatter: (params) => {\r\n const gridRow = params.data as AllocationDetailGridRowModel;\r\n const status = gridRow ? this._statuses.find(i => i.allocationDetailStatusId === +gridRow.statusId) : null;\r\n return status ? status.name : '';\r\n },\r\n onCellValueChanged: this._onValueChanged.bind(this),\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Reconciled',\r\n field: 'isReconciled',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n isVisible: (params) => params.data && !params.data.selectedTotalsRow && !params.data.totalsRow,\r\n canEdit: (params) => this._canChangeReconciliationStatus(params),\r\n canEnterEditMode: () => true,\r\n onValueChanged: this._onValueChanged.bind(this)\r\n } as ICellRendererParamsForAgGridCheckbox,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Add\\'l Dep.',\r\n field: 'additionalDepreciation',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => (x && x.value) ? `${this._decimalPipe.transform(x.value * 100, '1.2-5')}%` : '',\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Add\\'l Dep. (WP)',\r\n field: 'workPaperAddlDep',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => (x && x.value) ? `${this._decimalPipe.transform(x.value * 100, '1.2-5')}%` : '',\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Est. FMV',\r\n field: 'estimatedFMV',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ReturnAssetModel;\r\n return !rowData\r\n ? null\r\n : x.value || x.value === 0 || rowData.estimatedFMVOverridden\r\n ? this._decimalPipe.transform(x.value, '1.2-2')\r\n : 'N/A';\r\n },\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Acq. Year',\r\n field: 'acqYear',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Age',\r\n field: 'age',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Location Name',\r\n field: 'leaseLocationName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Location Address',\r\n field: 'leaseAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Location City',\r\n field: 'leaseCity',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Location State',\r\n field: 'leaseState',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Location Zip',\r\n field: 'leaseZip',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Lease Start Date',\r\n field: 'leaseStartDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Lease End Date',\r\n field: 'leaseEndDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._datePipe.transform(x.value, true),\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Lease Term In Months',\r\n field: 'leaseTermInMonths',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Lease Monthly Payment',\r\n field: 'leaseMonthlyPayment',\r\n filter: 'agNumberColumnFilter',\r\n hide: true,\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Lease Type',\r\n field: 'leaseTypeId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Lease Asset ID',\r\n field: 'leaseAssetId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Lease Number',\r\n field: 'leaseNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Billing Name',\r\n field: 'leaseBillingName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Billing Address',\r\n field: 'leaseBillingAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Billing City',\r\n field: 'leaseBillingCity',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Billing State',\r\n field: 'leaseBillingState',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Billing Zip',\r\n field: 'leaseBillingZip',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Customer Id',\r\n field: 'leaseClientId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Leasing'\r\n },\r\n {\r\n headerName: 'Jan Balance',\r\n field: 'inventoryJan',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Feb Balance',\r\n field: 'inventoryFeb',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Mar Balance',\r\n field: 'inventoryMar',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Apr Balance',\r\n field: 'inventoryApr',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'May Balance',\r\n field: 'inventoryMay',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Jun Balance',\r\n field: 'inventoryJun',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Jul Balance',\r\n field: 'inventoryJul',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Aug Balance',\r\n field: 'inventoryAug',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Sep Balance',\r\n field: 'inventorySep',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Oct Balance',\r\n field: 'inventoryOct',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Nov Balance',\r\n field: 'inventoryNov',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Dec Balance',\r\n field: 'inventoryDec',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Avg Balance',\r\n field: 'inventoryAvrCalculated',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._decimalPipe.transform(x.value, '1.2-2'),\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Aggregated Balance',\r\n field: 'inventoryAggregatedString',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n sortable: false,\r\n cellClass: 'ag-numeric-cell',\r\n hide: true,\r\n toolPanelClass: 'Inventory'\r\n },\r\n {\r\n headerName: 'Reportable',\r\n field: 'isReportable',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n cellClass: 'ag-text-cell',\r\n valueFormatter: x => x.value ? 'Yes' : 'No',\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Taxable',\r\n field: 'isTaxable',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n cellClass: 'ag-text-cell',\r\n valueFormatter: x => x.value ? 'Yes' : 'No',\r\n hide: true,\r\n toolPanelClass: 'Asset'\r\n },\r\n {\r\n headerName: 'Taxing Unit (WP)',\r\n field: 'workPaperTaxingUnit',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Physical Address (WP)',\r\n field: 'workPaperPhysicalAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Lessee Name (WP)',\r\n field: 'workPaperLesseeName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Note (WP)',\r\n field: 'workPaperNote',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Misc',\r\n field: 'workPaperMisc',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Misc1 (WP)',\r\n field: 'workPaperMisc1',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Misc2 (WP)',\r\n field: 'workPaperMisc2',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Misc3 (WP)',\r\n field: 'workPaperMisc3',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Misc4 (WP)',\r\n field: 'workPaperMisc4',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n },\r\n {\r\n headerName: 'Misc5 (WP)',\r\n field: 'workPaperMisc5',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n toolPanelClass: 'Work Papers'\r\n }\r\n ];\r\n\r\n const descriptorColumns = this._returnService.getCompanyAssetDescriptorMappingsAsColDefs(this._companyAssetDescriptorMappings);\r\n\r\n const actionColumn: ColDef = {\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n pinned: 'right',\r\n cellRendererFramework: AllocationDetailListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canView: this._canViewAssetDetails.bind(this),\r\n viewDetails: this._viewAssetDetails.bind(this)\r\n } as ICellRendererParamsForAllocationDetailListGridAction,\r\n pinnedRowCellRenderer: () => {return '';}\r\n };\r\n\r\n this._gridApi.setColumnDefs([...columns, ...descriptorColumns, actionColumn]);\r\n }\r\n\r\n private _canViewAssetDetails(params: ICellRendererParamsForAllocationDetailListGridAction): boolean {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n return !!allocationDetail && !!allocationDetail.calculatedAssetId;\r\n }\r\n\r\n private async _viewAssetDetails(params: ICellRendererParamsForAllocationDetailListGridAction): Promise {\r\n const allocationDetail = params.data as AllocationDetailGridRowModel;\r\n if (!allocationDetail) {\r\n return Promise.resolve();\r\n }\r\n\r\n const inputParams: AssetDetailsParams = {\r\n reportingAssetId: allocationDetail.calculatedReportingAssetId,\r\n assetId: allocationDetail.calculatedAssetId,\r\n lienDate: this.allocation.lienDate,\r\n canEdit: this._returnService.canEditCompany && false,\r\n createNewAsset: false,\r\n topLevelCompanyId: this.companyId,\r\n assetDescriptors: null,\r\n newAssetCompanyId: null,\r\n canViewRyanPrivateItems: this._returnService.canViewRyanPrivateItems,\r\n fromLockedReturn: false,\r\n fromLockedAllocation: true\r\n };\r\n\r\n await this._modalService.showAsync(AssetDetailsComponent, inputParams, 'modal-xl');\r\n }\r\n\r\n private _isRowEditable(params: IsColumnFuncParams): boolean {\r\n const allocationDetailGridModel = params.data as AllocationDetailGridRowModel;\r\n\r\n return !params.data.selectedTotalsRow && !params.data.totalsRow && allocationDetailGridModel && !allocationDetailGridModel.isReconciled;\r\n }\r\n\r\n private _canChangeReconciliationStatus(params: ICellRendererParamsForAgGridCheckbox): boolean {\r\n const allocationDetailGridModel = params.data as AllocationDetailGridRowModel;\r\n\r\n let result = !params.data.selectedTotalsRow && !params.data.totalsRow && !!allocationDetailGridModel;\r\n\r\n if (result) {\r\n if (allocationDetailGridModel.isReconciled) {\r\n _.forEach(this._assessmentsSummary,\r\n i => {\r\n const lockedAssessmentSummary = _.find(\r\n allocationDetailGridModel.assignedAllocationAssessmentIds,\r\n j =>\r\n i.allocationAnnualAssessmentId === j && i.isLocked);\r\n\r\n if (lockedAssessmentSummary) {\r\n result = false;\r\n return true;\r\n }\r\n });\r\n } else {\r\n result = allocationDetailGridModel.canBeReconciled;\r\n }\r\n }\r\n\r\n return result;\r\n }\r\n\r\n private async _onValueChanged(params: CellValueChangedEvent): Promise {\r\n if (params.newValue === params.oldValue) {\r\n return;\r\n }\r\n\r\n const newValue = params.newValue;\r\n const allocationDetailGridModel = params.data as AllocationDetailGridRowModel;\r\n let reloadTotals: boolean;\r\n const updateModel = {\r\n rowVersion: allocationDetailGridModel.rowVersion\r\n } as Compliance.AllocationDetailUpdateModel;\r\n\r\n switch (params.colDef.field) {\r\n case 'initialAllocationAmount':\r\n updateModel.initialAllocationAmount = newValue;\r\n updateModel.updatedField = Compliance.AllocationDetailPropertyEnum.InitialAllocationAmount;\r\n reloadTotals = true;\r\n break;\r\n case 'finalAllocationAmount':\r\n updateModel.finalAllocationAmount = newValue;\r\n updateModel.updatedField = Compliance.AllocationDetailPropertyEnum.FinalAllocationAmount;\r\n reloadTotals = true;\r\n break;\r\n case 'statusId':\r\n updateModel.statusId = +newValue;\r\n updateModel.updatedField = Compliance.AllocationDetailPropertyEnum.AllocationDetailStatusId;\r\n reloadTotals = false;\r\n break;\r\n case 'isReconciled':\r\n updateModel.isReconciled = newValue;\r\n updateModel.updatedField = Compliance.AllocationDetailPropertyEnum.IsReconciled;\r\n reloadTotals = false;\r\n break;\r\n case 'assetNumber':\r\n updateModel.assetNumber = newValue;\r\n updateModel.updatedField = Compliance.AllocationDetailPropertyEnum.AssetNumber;\r\n break;\r\n }\r\n\r\n const reloadData = this._gridDataSource.reloadDataAfterUpdate(params.colDef.field);\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating Value' });\r\n try {\r\n const updateResult = await lastValueFrom(this._allocationDetailRepository.update(this.allocationId, allocationDetailGridModel.allocationDetailId, updateModel));\r\n\r\n if (!reloadData) {\r\n const updatedGridRow = new AllocationDetailGridRowModel(updateResult.updatedAllocationDetailModel);\r\n params.node.setData(updatedGridRow);\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n\r\n if (updateResult.affectedAssessmentSummaries.length !== 0) {\r\n const updatedTotalSummary = _.find(updateResult.affectedAssessmentSummaries, i =>\r\n i.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Total);\r\n\r\n if (updatedTotalSummary) {\r\n this._totalAssessmentsSummary = new AssessmentSummaryInfo(updatedTotalSummary);\r\n }\r\n\r\n const updatedUnassignedSummary = _.find(updateResult.affectedAssessmentSummaries, i =>\r\n i.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Unassigned);\r\n\r\n if (updatedTotalSummary) {\r\n this._unassignedAssessmentsSummary = new AssessmentSummaryInfo(updatedUnassignedSummary);\r\n }\r\n\r\n _(updateResult.affectedAssessmentSummaries)\r\n .filter(i => i.summaryType !== Compliance.AllocationAssessmentSummaryTypeEnum.Unassigned &&\r\n i.summaryType !== Compliance.AllocationAssessmentSummaryTypeEnum.Total)\r\n .each(i => {\r\n const updatedSummary = new AssessmentSummaryInfo(i);\r\n const existingSummaryIndex = this._assessmentsSummary.findIndex(j => AssessmentSummaryInfo.isEqual(j, updatedSummary));\r\n this._assessmentsSummary[existingSummaryIndex] = updatedSummary;\r\n });\r\n\r\n this._setAssessmentsSummary([ ...this._assessmentsSummary, this._totalAssessmentsSummary, this._unassignedAssessmentsSummary ]);\r\n }\r\n }\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n if (reloadData) {\r\n this.refreshAssetsList();\r\n } else if (reloadTotals) {\r\n await this._reloadTotals();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n this.hasSelectedRows = false;\r\n this._allocationDetailSelectionInfo = {\r\n hasNotMatchedAssets: false,\r\n hasNewParcels: false\r\n };\r\n\r\n const dataSourceParams = (): AllocationDetailsListDataSourceParams => {\r\n return {\r\n allocationId: this.allocationId,\r\n hideNotReportedAssets: this.hideNotReportedAssets,\r\n managementReviewOption: this.managementReviewSelectedOption\r\n };\r\n };\r\n\r\n this._gridDataSource = new AllocationDetailsListAgGridDataSource(\r\n this._gridApi,\r\n this._allocationDetailRepository,\r\n this._allocationDetailService,\r\n dataSourceParams,\r\n this.handleTotalsUpdate\r\n );\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private async _getAssessmentGridRowIds(skip: number, take: number): Promise> {\r\n const model: any = this._assessmentGridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return {\r\n data: rows.map((x) => {\r\n const assessment = x.data as AssessmentSummaryInfo;\r\n return assessment && assessment.allocationAnnualAssessmentId;\r\n })\r\n } as Compliance.QueryResultModel;\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private async _reloadTotals(): Promise {\r\n if (!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.selectedTotalsLoading = true;\r\n\r\n try {\r\n const totals:[Compliance.AllocationDetailTotalsModel, Compliance.AllocationDetailTotalsModel] =\r\n await Promise.all([this._gridDataSource.getSelectedRowTotals(this.gridTracker.getSelectedRowsModel()),\r\n this._gridDataSource.getSelectedRowTotals(null)]);\r\n // const result = await this._gridDataSource.getSelectedRowTotals(this.gridTracker.getSelectedRowsModel());\r\n this.selectedTotalsLoading = false;\r\n this.handleTotalsUpdate(totals[0], true);\r\n this.handleTotalsUpdate(totals[1], false);\r\n } finally {\r\n this.selectedTotalsLoading = false;\r\n }\r\n }\r\n\r\n refreshAssetsList() {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this._gridDataSource.clearTotals();\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private async _getDraggedAllocationDetailIds(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Working on it' });\r\n try {\r\n return await this.gridTracker.getSelectedRowIds();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _convertToAssessmentSummaryInfo(assessmentsSummary: Compliance.AllocationAssessmentSummaryModel[]): AssessmentSummaryInfo[] {\r\n return _.map(assessmentsSummary, i => new AssessmentSummaryInfo(i));\r\n }\r\n\r\n private _setAssessmentsSummary(assessmentsSummary: AssessmentSummaryInfo[]) {\r\n this._assessmentsSummary = _.flow([\r\n filter(i => i.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Normal ||\r\n i.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Phantom),\r\n sortBy(x => x.sortByName)\r\n ])(assessmentsSummary);\r\n\r\n this._totalAssessmentsSummary = _.find(assessmentsSummary, i => i.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Total);\r\n this._unassignedAssessmentsSummary = _.find(assessmentsSummary, i => i.summaryType === Compliance.AllocationAssessmentSummaryTypeEnum.Unassigned);\r\n\r\n this.filterAssessmentsSummary(this.assessmentsSummaryFilter);\r\n\r\n if (this._assessmentGridApi) {\r\n this._assessmentGridApi.setRowData(this._assessmentsSummary);\r\n this._assessmentGridApi.setPinnedBottomRowData([this._totalAssessmentsSummary, this._unassignedAssessmentsSummary]);\r\n }\r\n }\r\n\r\n private async _lockAssessments(model: Compliance.SelectAllocationAssessmentModel): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Locking Assessment' });\r\n\r\n let result: Compliance.LockAllocationAssessmentResultModel;\r\n\r\n try {\r\n result = await lastValueFrom(this._allocationRepository.lockAllocationAssessment(this.allocationId, model));\r\n\r\n _.forEach(result.assessmentsSummary, u => {\r\n const existingSummaryIndex = _.findIndex(this._assessmentsSummary,\r\n e => e.allocationAnnualAssessmentId === u.allocationAnnualAssessmentId);\r\n this._assessmentsSummary[existingSummaryIndex] = new AssessmentSummaryInfo(u);\r\n });\r\n\r\n this.assessmentGridTracker.clear();\r\n this._setAssessmentsSummary([...this._assessmentsSummary, this._totalAssessmentsSummary, this._unassignedAssessmentsSummary]);\r\n\r\n if (result.reloadAllocationDetails) {\r\n this.refreshAssetsList();\r\n }\r\n } finally {\r\n if (!result) {\r\n _.forEach(model.selectedRows, x => {\r\n const assessmentSummary = _.find(this._assessmentsSummary,\r\n e => e.allocationAnnualAssessmentId === x);\r\n assessmentSummary.isLocked = false;\r\n });\r\n }\r\n\r\n busyRef.hide();\r\n }\r\n\r\n if (result && result.assetsInAnotherAllocations && result.assetsInAnotherAllocations.length) {\r\n const params: AssetsInAnotherAllocationsParams = {\r\n assets: result.assetsInAnotherAllocations\r\n };\r\n\r\n await this._modalService.showAsync(AssetsInAnotherAllocationsComponent, params, 'modal-xl');\r\n }\r\n }\r\n\r\n private async _releaseLockedAssessments(model: Compliance.SelectAllocationAssessmentModel): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Un-Locking Assessment' });\r\n\r\n try {\r\n const result = await lastValueFrom(this._allocationRepository.releaseLockedAllocationAssessment(this.allocationId, model));\r\n\r\n _.forEach(result.assessmentsSummary, u => {\r\n const existingSummaryIndex = _.findIndex(this._assessmentsSummary,\r\n e => e.allocationAnnualAssessmentId === u.allocationAnnualAssessmentId);\r\n this._assessmentsSummary[existingSummaryIndex] = new AssessmentSummaryInfo(u);\r\n });\r\n\r\n this.assessmentGridTracker.clear();\r\n this._setAssessmentsSummary([...this._assessmentsSummary, this._totalAssessmentsSummary, this._unassignedAssessmentsSummary]);\r\n\r\n if (result.reloadAllocationDetails) {\r\n this.refreshAssetsList();\r\n }\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _updateAssessmentActions(): void {\r\n // Lock Allocation\r\n this.assessmentActions[0].disabled = !this.hasReadyToLockAllocations;\r\n // Release Locked Allocation\r\n this.assessmentActions[1].disabled = !this.hasLockedAssessments;\r\n // Distribute Variance\r\n this.assessmentActions[2].disabled = !this.canDistributeVariance;\r\n // Create new parcels and assessment for unallocated\r\n this.assessmentActions[3].disabled = !this.canCreateMergedParcels;\r\n // Copy list to trigger change detection\r\n this.assessmentActions = [...this.assessmentActions];\r\n }\r\n\r\n private async _refreshAssessmentsSummary() {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Filtering...' });\r\n try {\r\n const model = {\r\n hideLockedAssessment: this.hideLockedAssessments,\r\n filter: this.assessmentsSummaryFilter\r\n } as Compliance.AllocationAssessmentSummarySearchModel;\r\n const assessmentsSummary = await lastValueFrom(this._allocationRepository.getAssessmentsSummary(this.allocationId, model));\r\n this._setAssessmentsSummary(this._convertToAssessmentSummaryInfo(assessmentsSummary));\r\n this.refreshAssetsList();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AssetRepository } from '../../Repositories';\r\nimport { AssetSummary } from '../Models/assetSummary';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../AgGrid';\r\nimport { AssetLienDate } from '../Asset-Lien-Date/assetLienDate.component';\r\nimport { AssetLimitOption } from './Asset-Limit/assetLimit.component';\r\n\r\nexport interface AssetListDataSourceParams {\r\n companyId: number;\r\n lienDate: AssetLienDate;\r\n importId: number;\r\n limitOption: AssetLimitOption;\r\n advancedFilters: Compliance.AdvancedAssetFilters;\r\n fetchSourceAssets: boolean;\r\n parcelId?: number;\r\n siteId?: number;\r\n}\r\n\r\nexport class AssetListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _assetRepository: AssetRepository,\r\n protected _dataSourceParamsFn: () => AssetListDataSourceParams,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe,\r\n private readonly _totalsUpdateCallback: (totals: Compliance.AssetSearchTotalsModel, selectedTotals?: boolean, isLoading?: boolean) => void,\r\n private readonly _autoUpdateTotalsCallback: () => boolean\r\n ) { super(_gridApi); }\r\n\r\n hasLatestTotals: boolean;\r\n lastFetchedTotals: Compliance.AssetSearchTotalsModel;\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n // Originally, these were like this:\r\n //{ name: `${Compliance.AssetPropertyEnum.ReportingAssetNumber.toString()}`, value: Compliance.AssetPropertyEnum.ReportingAssetNumber },\r\n // However, TypeScript has had a really annoying bug for years where this sometimes breaks during transpilation.\r\n // Eventually, we'll upgrade to a version of TypeScript where this bug is fixed (supposedly 3.3+), but until then\r\n // just use string interpolation. https://github.com/angular/angular-cli/issues/13842\r\n { name: `${Compliance.AssetPropertyEnum.ReportingAssetNumber}`, value: Compliance.AssetPropertyEnum.ReportingAssetNumber },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingAcqDate}`, value: Compliance.AssetPropertyEnum.ReportingAcqDate },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingCost}`, value: Compliance.AssetPropertyEnum.ReportingCost },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingDescription}`, value: Compliance.AssetPropertyEnum.ReportingDescription },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingDisposedDate}`, value: Compliance.AssetPropertyEnum.ReportingDisposedDate },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingGLAccountNameOrNumber}`, value: Compliance.AssetPropertyEnum.ReportingGLAccountNameOrNumber },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingGLAccountNumber}`, value: Compliance.AssetPropertyEnum.ReportingGLAccountNumber },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingSiteNameOrNumber}`, value: Compliance.AssetPropertyEnum.ReportingSiteNameOrNumber },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingSiteName}`, value: Compliance.AssetPropertyEnum.ReportingSiteName },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingSiteNumber}`, value: Compliance.AssetPropertyEnum.ReportingSiteNumber },\r\n { name: `${Compliance.AssetPropertyEnum.AssetClassificationName}`, value: Compliance.AssetPropertyEnum.AssetClassificationName },\r\n { name: `${Compliance.AssetPropertyEnum.SourceAssetNumber}`, value: Compliance.AssetPropertyEnum.SourceAssetNumber },\r\n { name: `${Compliance.AssetPropertyEnum.SourceAcqDate}`, value: Compliance.AssetPropertyEnum.SourceAcqDate },\r\n { name: `${Compliance.AssetPropertyEnum.SourceCost}`, value: Compliance.AssetPropertyEnum.SourceCost },\r\n { name: `${Compliance.AssetPropertyEnum.SourceDescription}`, value: Compliance.AssetPropertyEnum.SourceDescription },\r\n { name: `${Compliance.AssetPropertyEnum.SourceDisposedDate}`, value: Compliance.AssetPropertyEnum.SourceDisposedDate },\r\n { name: `${Compliance.AssetPropertyEnum.SourceGLAccountNameOrNumber}`, value: Compliance.AssetPropertyEnum.SourceGLAccountNameOrNumber },\r\n { name: `${Compliance.AssetPropertyEnum.SourceGLAccountNumber}`, value: Compliance.AssetPropertyEnum.SourceGLAccountNumber },\r\n { name: `${Compliance.AssetPropertyEnum.SourceSiteNameOrNumber}`, value: Compliance.AssetPropertyEnum.SourceSiteNameOrNumber },\r\n { name: `${Compliance.AssetPropertyEnum.SourceSiteName}`, value: Compliance.AssetPropertyEnum.SourceSiteName },\r\n { name: `${Compliance.AssetPropertyEnum.SourceSiteNumber}`, value: Compliance.AssetPropertyEnum.SourceSiteNumber },\r\n { name: `${Compliance.AssetPropertyEnum.EffectiveDate}`, value: Compliance.AssetPropertyEnum.EffectiveDate },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingParcel}`, value: Compliance.AssetPropertyEnum.ReportingParcel },\r\n { name: `${Compliance.AssetPropertyEnum.CompanyCode}`, value: Compliance.AssetPropertyEnum.CompanyCode },\r\n { name: `${Compliance.AssetPropertyEnum.CompanyName}`, value: Compliance.AssetPropertyEnum.CompanyName },\r\n { name: `${Compliance.AssetPropertyEnum.AssessorName}`, value: Compliance.AssetPropertyEnum.AssessorName },\r\n { name: `${Compliance.AssetPropertyEnum.SourceState}`, value: Compliance.AssetPropertyEnum.SourceState},\r\n { name: `${Compliance.AssetPropertyEnum.State}`, value: Compliance.AssetPropertyEnum.State },\r\n { name: `${Compliance.AssetPropertyEnum.SourceAdjustedCost}`, value: Compliance.AssetPropertyEnum.SourceAdjustedCost },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingAreSplitAllocationsValid}`, value: Compliance.AssetPropertyEnum.ReportingAreSplitAllocationsValid },\r\n { name: 'assetVerificationReason', value: Compliance.AssetPropertyEnum.AssetVerificationReason },\r\n { name: 'reportingIsPerpetual', value: Compliance.AssetPropertyEnum.ReportingIsPerpetual },\r\n { name: 'isUserCreated', value: Compliance.AssetPropertyEnum.IsUserCreated },\r\n { name: 'reportedT1', value: Compliance.AssetPropertyEnum.ReportingT1 },\r\n { name: 'reportedT2', value: Compliance.AssetPropertyEnum.ReportingT2 },\r\n { name: 'reportedT3', value: Compliance.AssetPropertyEnum.ReportingT3 },\r\n { name: 'reportedT4', value: Compliance.AssetPropertyEnum.ReportingT4 },\r\n { name: 'reportedT5', value: Compliance.AssetPropertyEnum.ReportingT5 },\r\n { name: 'reportedT6', value: Compliance.AssetPropertyEnum.ReportingT6 },\r\n { name: 'reportedT7', value: Compliance.AssetPropertyEnum.ReportingT7 },\r\n { name: 'reportedT8', value: Compliance.AssetPropertyEnum.ReportingT8 },\r\n { name: 'reportedT9', value: Compliance.AssetPropertyEnum.ReportingT9 },\r\n { name: 'reportedT10', value: Compliance.AssetPropertyEnum.ReportingT10 },\r\n { name: 'reportedT11', value: Compliance.AssetPropertyEnum.ReportingT11 },\r\n { name: 'reportedT12', value: Compliance.AssetPropertyEnum.ReportingT12 },\r\n { name: 'reportedT13', value: Compliance.AssetPropertyEnum.ReportingT13 },\r\n { name: 'reportedT14', value: Compliance.AssetPropertyEnum.ReportingT14 },\r\n { name: 'reportedT15', value: Compliance.AssetPropertyEnum.ReportingT15 },\r\n { name: 'reportedT16', value: Compliance.AssetPropertyEnum.ReportingT16 },\r\n { name: 'reportedT17', value: Compliance.AssetPropertyEnum.ReportingT17 },\r\n { name: 'reportedT18', value: Compliance.AssetPropertyEnum.ReportingT18 },\r\n { name: 'reportedT19', value: Compliance.AssetPropertyEnum.ReportingT19 },\r\n { name: 'reportedT20', value: Compliance.AssetPropertyEnum.ReportingT20 },\r\n { name: 'reportedT20', value: Compliance.AssetPropertyEnum.ReportingT20 },\r\n { name: 'reportedT21', value: Compliance.AssetPropertyEnum.ReportingT21 },\r\n { name: 'reportedT22', value: Compliance.AssetPropertyEnum.ReportingT22 },\r\n { name: 'reportedT23', value: Compliance.AssetPropertyEnum.ReportingT23 },\r\n { name: 'reportedT24', value: Compliance.AssetPropertyEnum.ReportingT24 },\r\n { name: 'reportedT25', value: Compliance.AssetPropertyEnum.ReportingT25 },\r\n { name: 'reportedT26', value: Compliance.AssetPropertyEnum.ReportingT26 },\r\n { name: 'reportedT27', value: Compliance.AssetPropertyEnum.ReportingT27 },\r\n { name: 'reportedT28', value: Compliance.AssetPropertyEnum.ReportingT28 },\r\n { name: 'reportedT29', value: Compliance.AssetPropertyEnum.ReportingT29 },\r\n { name: 'reportedT30', value: Compliance.AssetPropertyEnum.ReportingT30 },\r\n { name: 'reportedN1', value: Compliance.AssetPropertyEnum.ReportingN1 },\r\n { name: 'reportedN2', value: Compliance.AssetPropertyEnum.ReportingN2 },\r\n { name: 'reportedN3', value: Compliance.AssetPropertyEnum.ReportingN3 },\r\n { name: 'reportedN4', value: Compliance.AssetPropertyEnum.ReportingN4 },\r\n { name: 'reportedN5', value: Compliance.AssetPropertyEnum.ReportingN5 },\r\n { name: 'reportedN6', value: Compliance.AssetPropertyEnum.ReportingN6 },\r\n { name: 'reportedN7', value: Compliance.AssetPropertyEnum.ReportingN7 },\r\n { name: 'reportedN8', value: Compliance.AssetPropertyEnum.ReportingN8 },\r\n { name: 'reportedN9', value: Compliance.AssetPropertyEnum.ReportingN9 },\r\n { name: 'reportedN10', value: Compliance.AssetPropertyEnum.ReportingN10 },\r\n { name: 'reportedD1', value: Compliance.AssetPropertyEnum.ReportingD1 },\r\n { name: 'reportedD2', value: Compliance.AssetPropertyEnum.ReportingD2 },\r\n { name: 'reportedD3', value: Compliance.AssetPropertyEnum.ReportingD3 },\r\n { name: 'reportedD4', value: Compliance.AssetPropertyEnum.ReportingD4 },\r\n { name: 'reportedD5', value: Compliance.AssetPropertyEnum.ReportingD5 },\r\n { name: 'reportedD6', value: Compliance.AssetPropertyEnum.ReportingD6 },\r\n { name: 'reportedD7', value: Compliance.AssetPropertyEnum.ReportingD7 },\r\n { name: 'reportedD8', value: Compliance.AssetPropertyEnum.ReportingD8 },\r\n { name: 'reportedD9', value: Compliance.AssetPropertyEnum.ReportingD9 },\r\n { name: 'reportedD10', value: Compliance.AssetPropertyEnum.ReportingD10 },\r\n { name: 'sourceT1', value: Compliance.AssetPropertyEnum.SourceT1 },\r\n { name: 'sourceT2', value: Compliance.AssetPropertyEnum.SourceT2 },\r\n { name: 'sourceT3', value: Compliance.AssetPropertyEnum.SourceT3 },\r\n { name: 'sourceT4', value: Compliance.AssetPropertyEnum.SourceT4 },\r\n { name: 'sourceT5', value: Compliance.AssetPropertyEnum.SourceT5 },\r\n { name: 'sourceT6', value: Compliance.AssetPropertyEnum.SourceT6 },\r\n { name: 'sourceT7', value: Compliance.AssetPropertyEnum.SourceT7 },\r\n { name: 'sourceT8', value: Compliance.AssetPropertyEnum.SourceT8 },\r\n { name: 'sourceT9', value: Compliance.AssetPropertyEnum.SourceT9 },\r\n { name: 'sourceT10', value: Compliance.AssetPropertyEnum.SourceT10 },\r\n { name: 'sourceT11', value: Compliance.AssetPropertyEnum.SourceT11 },\r\n { name: 'sourceT12', value: Compliance.AssetPropertyEnum.SourceT12 },\r\n { name: 'sourceT13', value: Compliance.AssetPropertyEnum.SourceT13 },\r\n { name: 'sourceT14', value: Compliance.AssetPropertyEnum.SourceT14 },\r\n { name: 'sourceT15', value: Compliance.AssetPropertyEnum.SourceT15 },\r\n { name: 'sourceT16', value: Compliance.AssetPropertyEnum.SourceT16 },\r\n { name: 'sourceT17', value: Compliance.AssetPropertyEnum.SourceT17 },\r\n { name: 'sourceT18', value: Compliance.AssetPropertyEnum.SourceT18 },\r\n { name: 'sourceT19', value: Compliance.AssetPropertyEnum.SourceT19 },\r\n { name: 'sourceT20', value: Compliance.AssetPropertyEnum.SourceT20 },\r\n { name: 'sourceT20', value: Compliance.AssetPropertyEnum.SourceT20 },\r\n { name: 'sourceT21', value: Compliance.AssetPropertyEnum.SourceT21 },\r\n { name: 'sourceT22', value: Compliance.AssetPropertyEnum.SourceT22 },\r\n { name: 'sourceT23', value: Compliance.AssetPropertyEnum.SourceT23 },\r\n { name: 'sourceT24', value: Compliance.AssetPropertyEnum.SourceT24 },\r\n { name: 'sourceT25', value: Compliance.AssetPropertyEnum.SourceT25 },\r\n { name: 'sourceT26', value: Compliance.AssetPropertyEnum.SourceT26 },\r\n { name: 'sourceT27', value: Compliance.AssetPropertyEnum.SourceT27 },\r\n { name: 'sourceT28', value: Compliance.AssetPropertyEnum.SourceT28 },\r\n { name: 'sourceT29', value: Compliance.AssetPropertyEnum.SourceT29 },\r\n { name: 'sourceT30', value: Compliance.AssetPropertyEnum.SourceT30 },\r\n { name: 'sourceN1', value: Compliance.AssetPropertyEnum.SourceN1 },\r\n { name: 'sourceN2', value: Compliance.AssetPropertyEnum.SourceN2 },\r\n { name: 'sourceN3', value: Compliance.AssetPropertyEnum.SourceN3 },\r\n { name: 'sourceN4', value: Compliance.AssetPropertyEnum.SourceN4 },\r\n { name: 'sourceN5', value: Compliance.AssetPropertyEnum.SourceN5 },\r\n { name: 'sourceN6', value: Compliance.AssetPropertyEnum.SourceN6 },\r\n { name: 'sourceN7', value: Compliance.AssetPropertyEnum.SourceN7 },\r\n { name: 'sourceN8', value: Compliance.AssetPropertyEnum.SourceN8 },\r\n { name: 'sourceN9', value: Compliance.AssetPropertyEnum.SourceN9 },\r\n { name: 'sourceN10', value: Compliance.AssetPropertyEnum.SourceN10 },\r\n { name: 'sourceD1', value: Compliance.AssetPropertyEnum.SourceD1 },\r\n { name: 'sourceD2', value: Compliance.AssetPropertyEnum.SourceD2 },\r\n { name: 'sourceD3', value: Compliance.AssetPropertyEnum.SourceD3 },\r\n { name: 'sourceD4', value: Compliance.AssetPropertyEnum.SourceD4 },\r\n { name: 'sourceD5', value: Compliance.AssetPropertyEnum.SourceD5 },\r\n { name: 'sourceD5', value: Compliance.AssetPropertyEnum.SourceD5 },\r\n { name: 'sourceD6', value: Compliance.AssetPropertyEnum.SourceD6 },\r\n { name: 'sourceD7', value: Compliance.AssetPropertyEnum.SourceD7 },\r\n { name: 'sourceD8', value: Compliance.AssetPropertyEnum.SourceD8 },\r\n { name: 'sourceD9', value: Compliance.AssetPropertyEnum.SourceD9 },\r\n { name: 'sourceD10', value: Compliance.AssetPropertyEnum.SourceD10 },\r\n { name: 'reportedCostAdjustmentAmount1', value: Compliance.AssetPropertyEnum.ReportingCostAdjustmentAmount1 },\r\n { name: 'reportedCostAdjustmentAmount2', value: Compliance.AssetPropertyEnum.ReportingCostAdjustmentAmount2 },\r\n { name: 'reportedCostAdjustmentAmount3', value: Compliance.AssetPropertyEnum.ReportingCostAdjustmentAmount3 },\r\n { name: 'reportedCostAdjustmentAmount4', value: Compliance.AssetPropertyEnum.ReportingCostAdjustmentAmount4 },\r\n { name: 'sourceLeaseLocationName', value: Compliance.AssetPropertyEnum.SourceLeaseLocationName },\r\n { name: 'sourceLeaseAddress', value: Compliance.AssetPropertyEnum.SourceLeaseAddress },\r\n { name: 'sourceLeaseCity', value: Compliance.AssetPropertyEnum.SourceLeaseCity },\r\n { name: 'sourceLeaseState', value: Compliance.AssetPropertyEnum.SourceLeaseState },\r\n { name: 'sourceLeaseZip', value: Compliance.AssetPropertyEnum.SourceLeaseZip },\r\n { name: 'sourceLeaseTermInMonths', value: Compliance.AssetPropertyEnum.SourceLeaseTermInMonths },\r\n { name: 'sourceLeaseMonthlyPayment', value: Compliance.AssetPropertyEnum.SourceLeaseMonthlyPayment },\r\n { name: 'sourceLeaseTypeId', value: Compliance.AssetPropertyEnum.SourceLeaseTypeId },\r\n { name: 'sourceLeaseAssetId', value: Compliance.AssetPropertyEnum.SourceLeaseAssetId },\r\n { name: 'sourceLeaseNumber', value: Compliance.AssetPropertyEnum.SourceLeaseNumber },\r\n { name: 'sourceLeaseBillingName', value: Compliance.AssetPropertyEnum.SourceLeaseBillingName },\r\n { name: 'sourceLeaseBillingAddress', value: Compliance.AssetPropertyEnum.SourceLeaseBillingAddress },\r\n { name: 'sourceLeaseBillingCity', value: Compliance.AssetPropertyEnum.SourceLeaseBillingCity },\r\n { name: 'sourceLeaseBillingState', value: Compliance.AssetPropertyEnum.SourceLeaseBillingState },\r\n { name: 'sourceLeaseBillingZip', value: Compliance.AssetPropertyEnum.SourceLeaseBillingZip },\r\n { name: 'sourceLeaseStartDate', value: Compliance.AssetPropertyEnum.SourceLeaseStartDate },\r\n { name: 'sourceLeaseEndDate', value: Compliance.AssetPropertyEnum.SourceLeaseEndDate },\r\n { name: 'sourceLeaseClientId', value: Compliance.AssetPropertyEnum.SourceLeaseClientId },\r\n { name: 'reportedLeaseLocationName', value: Compliance.AssetPropertyEnum.ReportingLeaseLocationName },\r\n { name: 'reportedLeaseAddress', value: Compliance.AssetPropertyEnum.ReportingLeaseAddress },\r\n { name: 'reportedLeaseCity', value: Compliance.AssetPropertyEnum.ReportingLeaseCity },\r\n { name: 'reportedLeaseState', value: Compliance.AssetPropertyEnum.ReportingLeaseState },\r\n { name: 'reportedLeaseZip', value: Compliance.AssetPropertyEnum.ReportingLeaseZip },\r\n { name: 'reportedLeaseTermInMonths', value: Compliance.AssetPropertyEnum.ReportingLeaseTermInMonths },\r\n { name: 'reportedLeaseMonthlyPayment', value: Compliance.AssetPropertyEnum.ReportingLeaseMonthlyPayment },\r\n { name: 'reportedLeaseTypeId', value: Compliance.AssetPropertyEnum.ReportingLeaseTypeId },\r\n { name: 'reportedLeaseAssetId', value: Compliance.AssetPropertyEnum.ReportingLeaseAssetId },\r\n { name: 'reportedLeaseNumber', value: Compliance.AssetPropertyEnum.ReportingLeaseNumber },\r\n { name: 'reportedLeaseBillingName', value: Compliance.AssetPropertyEnum.ReportingLeaseBillingName },\r\n { name: 'reportedLeaseBillingAddress', value: Compliance.AssetPropertyEnum.ReportingLeaseBillingAddress },\r\n { name: 'reportedLeaseBillingCity', value: Compliance.AssetPropertyEnum.ReportingLeaseBillingCity },\r\n { name: 'reportedLeaseBillingState', value: Compliance.AssetPropertyEnum.ReportingLeaseBillingState },\r\n { name: 'reportedLeaseBillingZip', value: Compliance.AssetPropertyEnum.ReportingLeaseBillingZip },\r\n { name: 'reportedLeaseStartDate', value: Compliance.AssetPropertyEnum.ReportingLeaseStartDate },\r\n { name: 'reportedLeaseEndDate', value: Compliance.AssetPropertyEnum.ReportingLeaseEndDate },\r\n { name: 'reportedLeaseClientId', value: Compliance.AssetPropertyEnum.ReportingLeaseClientId },\r\n { name: 'assetOwnershipType', value: Compliance.AssetPropertyEnum.AssetOwnershipType },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingSplitAllocationPercentage}`, value: Compliance.AssetPropertyEnum.ReportingSplitAllocationPercentage },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingOldAssetNumber}`, value: Compliance.AssetPropertyEnum.ReportingOldAssetNumber },\r\n { name: `${Compliance.AssetPropertyEnum.SourceOldAssetNumber}`, value: Compliance.AssetPropertyEnum.SourceOldAssetNumber },\r\n { name: 'sourceInventoryJan', value: Compliance.AssetPropertyEnum.SourceInventoryJan },\r\n { name: 'sourceInventoryFeb', value: Compliance.AssetPropertyEnum.SourceInventoryFeb },\r\n { name: 'sourceInventoryMar', value: Compliance.AssetPropertyEnum.SourceInventoryMar },\r\n { name: 'sourceInventoryApr', value: Compliance.AssetPropertyEnum.SourceInventoryApr },\r\n { name: 'sourceInventoryMay', value: Compliance.AssetPropertyEnum.SourceInventoryMay },\r\n { name: 'sourceInventoryJun', value: Compliance.AssetPropertyEnum.SourceInventoryJun },\r\n { name: 'sourceInventoryJul', value: Compliance.AssetPropertyEnum.SourceInventoryJul },\r\n { name: 'sourceInventoryAug', value: Compliance.AssetPropertyEnum.SourceInventoryAug },\r\n { name: 'sourceInventorySep', value: Compliance.AssetPropertyEnum.SourceInventorySep },\r\n { name: 'sourceInventoryOct', value: Compliance.AssetPropertyEnum.SourceInventoryOct },\r\n { name: 'sourceInventoryNov', value: Compliance.AssetPropertyEnum.SourceInventoryNov },\r\n { name: 'sourceInventoryDec', value: Compliance.AssetPropertyEnum.SourceInventoryDec },\r\n { name: 'sourceInventoryAvr', value: Compliance.AssetPropertyEnum.SourceInventoryAvr },\r\n { name: 'reportedInventoryJan', value: Compliance.AssetPropertyEnum.ReportingInventoryJan },\r\n { name: 'reportedInventoryFeb', value: Compliance.AssetPropertyEnum.ReportingInventoryFeb },\r\n { name: 'reportedInventoryMar', value: Compliance.AssetPropertyEnum.ReportingInventoryMar },\r\n { name: 'reportedInventoryApr', value: Compliance.AssetPropertyEnum.ReportingInventoryApr },\r\n { name: 'reportedInventoryMay', value: Compliance.AssetPropertyEnum.ReportingInventoryMay },\r\n { name: 'reportedInventoryJun', value: Compliance.AssetPropertyEnum.ReportingInventoryJun },\r\n { name: 'reportedInventoryJul', value: Compliance.AssetPropertyEnum.ReportingInventoryJul },\r\n { name: 'reportedInventoryAug', value: Compliance.AssetPropertyEnum.ReportingInventoryAug },\r\n { name: 'reportedInventorySep', value: Compliance.AssetPropertyEnum.ReportingInventorySep },\r\n { name: 'reportedInventoryOct', value: Compliance.AssetPropertyEnum.ReportingInventoryOct },\r\n { name: 'reportedInventoryNov', value: Compliance.AssetPropertyEnum.ReportingInventoryNov },\r\n { name: 'reportedInventoryDec', value: Compliance.AssetPropertyEnum.ReportingInventoryDec },\r\n { name: 'reportedInventoryAvr', value: Compliance.AssetPropertyEnum.ReportingInventoryAvr },\r\n { name: 'sourceNetBookValue', value: Compliance.AssetPropertyEnum.SourceNetBookValue },\r\n { name: 'reportedNetBookValue', value: Compliance.AssetPropertyEnum.ReportingNetBookValue },\r\n { name: `${Compliance.AssetPropertyEnum.AlternativeAcqDateDescriptorName}`, value: Compliance.AssetPropertyEnum.AlternativeAcqDateDescriptorName },\r\n { name: `${Compliance.AssetPropertyEnum.AlternativeCostDescriptorName}`, value: Compliance.AssetPropertyEnum.AlternativeCostDescriptorName },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingIsAnchored}`, value: Compliance.AssetPropertyEnum.ReportingIsAnchored },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingDoNotPotentiallyDispose}`, value: Compliance.AssetPropertyEnum.ReportingDoNotPotentiallyDispose },\r\n { name: `${Compliance.AssetPropertyEnum.ReportingIsLocked}`, value: Compliance.AssetPropertyEnum.ReportingIsLocked },\r\n { name: `${Compliance.AssetPropertyEnum.LastReturnDescription}`, value: Compliance.AssetPropertyEnum.LastReturnDescription },\r\n { name: `${Compliance.AssetPropertyEnum.LastReturnId}`, value: Compliance.AssetPropertyEnum.LastReturnId },\r\n { name: `${Compliance.AssetPropertyEnum.SourceSiteAddress}`, value: Compliance.AssetPropertyEnum.SourceSiteAddress },\r\n { name: `${Compliance.AssetPropertyEnum.SiteAddress}`, value: Compliance.AssetPropertyEnum.SiteAddress },\r\n { name: `${Compliance.AssetPropertyEnum.SourcePriorCost}`, value: Compliance.AssetPropertyEnum.SourcePriorCost },\r\n { name: `${Compliance.AssetPropertyEnum.PriorCost}`, value: Compliance.AssetPropertyEnum.PriorCost },\r\n { name: `${Compliance.AssetPropertyEnum.SourceCostChange}`, value: Compliance.AssetPropertyEnum.SourceCostChange },\r\n { name: `${Compliance.AssetPropertyEnum.CostChange}`, value: Compliance.AssetPropertyEnum.CostChange },\r\n { name: `${Compliance.AssetPropertyEnum.ParcelSystemId}`, value: Compliance.AssetPropertyEnum.ParcelSystemId },\r\n { name: `${Compliance.AssetPropertyEnum.AssessorId}`, value: Compliance.AssetPropertyEnum.AssessorId }\r\n ];\r\n\r\n private _lastFilterUsedInTotals: string;\r\n\r\n public async getSelectedRowTotals(selectedRowsModel: Compliance.SelectedRowsModel): Promise {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.selectedRowProperty = this._dataSourceParams.fetchSourceAssets ? Compliance.AssetPropertyEnum.SourceAssetNumber : Compliance.AssetPropertyEnum.ReportingAssetNumber;\r\n searchParams.selectedRows = selectedRowsModel;\r\n searchParams.includeTotals = true;\r\n searchParams.includeOnlyTotals = true;\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: 100\r\n };\r\n\r\n const result = this._dataSourceParams.fetchSourceAssets ?\r\n await lastValueFrom(this._assetRepository.getSourceAssetList(this._dataSourceParams.companyId, searchParams)) :\r\n await lastValueFrom(this._assetRepository.getReportingAssetList(this._dataSourceParams.companyId, searchParams));\r\n\r\n return result.totals;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const lienDate = this._dataSourceParams.lienDate;\r\n const limitOption = this._dataSourceParams.limitOption;\r\n const searchParams: Compliance.AssetSearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n advancedAssetFilters: this._dataSourceParams.advancedFilters,\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n includeTotals: false,\r\n includeOnlyTotals: false,\r\n selectedRows: null,\r\n importId: this._dataSourceParams.importId,\r\n lienDate: lienDate && lienDate.date,\r\n useStateLienDate: lienDate && lienDate.useStateLienDate,\r\n lienDateType: lienDate && lienDate.lienDateType,\r\n overrideFilterColumns: limitOption && limitOption.overrideFilterColumns,\r\n noReportingParcel: limitOption && limitOption.noReportingParcel,\r\n invalidCostAllocations: limitOption && limitOption.invalidCostAllocations,\r\n parcelId: this._dataSourceParams.parcelId,\r\n siteId: this._dataSourceParams.siteId\r\n };\r\n\r\n return await lastValueFrom(this._assetRepository.getReportingAssetRowIds(this._dataSourceParams.companyId, searchParams));\r\n }\r\n\r\n async getAllRowTotals(params: IGetRowsParams, force?: boolean): Promise {\r\n if (!force && !this._autoUpdateTotalsCallback()) {return;}\r\n\r\n this._totalsUpdateCallback(this.lastFetchedTotals, false, true);\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n\r\n searchParams.includeTotals = true;\r\n searchParams.includeOnlyTotals = true;\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const result = this._dataSourceParams.fetchSourceAssets ?\r\n await lastValueFrom(this._assetRepository.getSourceAssetList(this._dataSourceParams.companyId, searchParams)) :\r\n await lastValueFrom(this._assetRepository.getReportingAssetList(this._dataSourceParams.companyId, searchParams));\r\n\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals);\r\n this.hasLatestTotals = true;\r\n\r\n return result.totals;\r\n }\r\n\r\n clearTotals(): void {\r\n this._lastFilterUsedInTotals = '';\r\n }\r\n\r\n clearFilters(): void {\r\n this.gridApi.appliedFilter = null;\r\n this.gridApi.setFilterModel(null);\r\n }\r\n\r\n clearSort(): void {\r\n this.gridApi.setSortModel(null);\r\n }\r\n\r\n getSearchParamsWithoutPagination() : Compliance.AssetSearchModel{\r\n this.refreshDataSourceParams();\r\n const lienDate = this._dataSourceParams.lienDate;\r\n const limitOption = this._dataSourceParams.limitOption;\r\n return {\r\n advancedAssetFilters: this._dataSourceParams.advancedFilters,\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n includeTotals: false,\r\n includeOnlyTotals: false,\r\n selectedRows: null,\r\n importId: this._dataSourceParams.importId,\r\n lienDate: lienDate && lienDate.date,\r\n useStateLienDate: lienDate && lienDate.useStateLienDate,\r\n lienDateType: lienDate && lienDate.lienDateType,\r\n overrideFilterColumns: limitOption && limitOption.overrideFilterColumns,\r\n noReportingParcel: limitOption && limitOption.noReportingParcel,\r\n invalidCostAllocations: limitOption && limitOption.invalidCostAllocations,\r\n parcelId: this._dataSourceParams.parcelId,\r\n siteId: this._dataSourceParams.siteId\r\n };\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n const canGetRows = !!((((this._dataSourceParams.lienDate && this._dataSourceParams.lienDate.date) && this._dataSourceParams.limitOption) || this._dataSourceParams.importId) && this._dataSourceParams.companyId);\r\n if (!canGetRows) {\r\n this.clearTotals();\r\n this._totalsUpdateCallback(null);\r\n }\r\n return canGetRows;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n this._gridApi.setPinnedBottomRowData([]);\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n const searchParamsString = JSON.stringify(searchParams);\r\n const fetchTotals: boolean = (!this.lastFetchedTotals) || (this._lastFilterUsedInTotals !== searchParamsString);\r\n\r\n this._lastFilterUsedInTotals = searchParamsString;\r\n\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const result = this._dataSourceParams.fetchSourceAssets ?\r\n await lastValueFrom(this._assetRepository.getSourceAssetList(this._dataSourceParams.companyId, searchParams)) :\r\n await lastValueFrom(this._assetRepository.getReportingAssetList(this._dataSourceParams.companyId, searchParams));\r\n\r\n\r\n this.hasLatestTotals = false;\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(null);\r\n\r\n const dataSourceResult: AgGridDataSourceResult = {\r\n rows: result.data.map((x, idx) => new AssetSummary(x, this._keyValueDisplayPipe, idx)),\r\n totalRows: result.totalRows,\r\n lastModifiedTimestamp: result.lastModifiedTimestamp\r\n };\r\n\r\n if (fetchTotals && this._autoUpdateTotalsCallback()) {\r\n this.getAllRowTotals(params);\r\n }\r\n\r\n return dataSourceResult;\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const ASSET_LIST_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'asset-list.lien-date',\r\n tooltipText: 'The lien date is used to determine which assets to display in the list and which source values to display for each asset. By default, any assets disposed prior to the selected lien date are not displayed in the list.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-list.asset-changes-filter',\r\n tooltipText: 'Filtering to identify assets with specific statuses and status changes.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-list.further-limit-to',\r\n tooltipText: 'Additional filtering to identify assets with specific field overrides and other miscellaneous options.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-list.new-asset',\r\n tooltipText: 'New asset'\r\n },\r\n {\r\n helpContentId: 'asset-list.reporting-values-view',\r\n tooltipText: 'Displays the reporting and source values for assets based on the selected lien date.'\r\n },\r\n {\r\n helpContentId: 'asset-list.imported-values-view',\r\n tooltipText: 'Displays the source values based on the lien date or the import file.'\r\n },\r\n {\r\n helpContentId: 'asset-list.view-last-return',\r\n tooltipText: 'View Filing'\r\n },\r\n {\r\n helpContentId: 'asset-list.apply-filters',\r\n tooltipText: 'Apply filters and load asset list'\r\n }\r\n];\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { CommentModalData } from '../../../Comments/comments.service';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { ASSET_LIST_HELP } from './assetList.component.help';\r\n\r\nexport interface ICellRendererParamsForAssetListGridAction extends ICellRendererParams {\r\n viewDetails: (params: ICellRendererParamsForAssetListGridAction) => void;\r\n canViewRyanPrivateItems: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class AssetListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n constructor(\r\n private readonly _helpService: HelpService\r\n ) { }\r\n\r\n assetModel: Compliance.AssetModel;\r\n commentModalData: CommentModalData;\r\n hasComments: boolean;\r\n\r\n private _params: ICellRendererParamsForAssetListGridAction;\r\n\r\n agInit(params: ICellRendererParamsForAssetListGridAction): void {\r\n this._helpService.setContent(ASSET_LIST_HELP);\r\n this._params = params;\r\n this.assetModel = params.data && params.data.getModel() as Compliance.AssetModel;\r\n if (!this.assetModel) {\r\n return;\r\n }\r\n\r\n this.hasComments = this.assetModel.hasNonRyanInternalComments || (this.assetModel.hasRyanInternalComments && params.canViewRyanPrivateItems);\r\n\r\n this.commentModalData = {\r\n entityID: this.assetModel.assetId,\r\n entityTypeID: Core.EntityTypes.Asset,\r\n parcelAcctNum: null,\r\n canEdit: true,\r\n description: null,\r\n parcelID: null,\r\n year: null\r\n };\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this._params.viewDetails(this._params);\r\n }\r\n}\r\n","import { WeissmanKeyValueDisplayPipe } from '../../../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe';\r\nimport { ExtendedModelBase } from '../../../Models/extendedModelBase';\r\n\r\nexport class ExtendedGLAccountModel extends ExtendedModelBase {\r\n constructor(model: Compliance.GLAccountModel, keyValueDisplayPipe: WeissmanKeyValueDisplayPipe) {\r\n super(model);\r\n this._keyValueDisplayPipe = keyValueDisplayPipe;\r\n }\r\n\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe;\r\n\r\n get displayName(): string {\r\n return this._keyValueDisplayPipe.transform(this.model, this.model.accountNumber, this.model.accountName);\r\n }\r\n}\r\n","import { WeissmanKeyValueDisplayPipe } from '../../../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe';\r\nimport { ExtendedModelBase } from '../../../Models/extendedModelBase';\r\n\r\nexport class ExtendedSiteModel extends ExtendedModelBase {\r\n constructor(model: Core.SiteModel, keyValueDisplayPipe: WeissmanKeyValueDisplayPipe) {\r\n super(model);\r\n this._keyValueDisplayPipe = keyValueDisplayPipe;\r\n }\r\n\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe;\r\n\r\n get displayName(): string {\r\n return this._keyValueDisplayPipe.transform(this.model, this.model.property, this.model.name);\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const ASSET_BULK_UPDATE_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'asset-bulk-update.isPerpetual',\r\n tooltipText: 'This field cannot be updated because the selected records do not have asset classifications which allow perpetual assets.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-bulk-update.isPerpetual-none',\r\n tooltipText: '',\r\n hasIcon: false\r\n },\r\n {\r\n helpContentId: 'asset-bulk-update.createNewSplitDisabled',\r\n tooltipText: 'New asset splits cannot be created because the selected records contain split assets.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'asset-bulk-update.updateSplitDisabled',\r\n tooltipText: 'Asset splits cannot be updated because the selected records contain assets without two-way splits.',\r\n hasIcon: true\r\n }\r\n];\r\n","import { Component } from '@angular/core';\r\nimport { HelpContentRendererValue, HelpContentComponent, HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { FlattenedCostAdjustmentSource} from '../Asset-Details/Asset-Info/assetInfo.component';\r\n\r\nexport type CostAdjustmentHelpComponentParams = HelpContentRendererValue;\r\n\r\n@Component({\r\n selector: 'cost-adjustment-tooltip',\r\n template: `\r\n Cost of asset is used for purposes of calculations. The source value may be altered by adjustments, applied for this state in the following order:\r\n
    \r\n
  • {{ costAdjustment.typeName }} (% values use {{ costAdjustment.applyToSource ? 'original cost' : 'running total' }})
  • \r\n
\r\n `\r\n})\r\nexport class CostAdjustmentHelpComponent implements HelpContentComponent {\r\n constructor(private readonly _helpService: HelpService) { }\r\n\r\n params: CostAdjustmentHelpComponentParams;\r\n adjustments: FlattenedCostAdjustmentSource[];\r\n\r\n async helpInit(params: CostAdjustmentHelpComponentParams): Promise {\r\n if (params) {\r\n this.adjustments = params.value;\r\n }\r\n this._helpService.refresh();\r\n\r\n }\r\n}\r\n","import { Directive, ElementRef, HostListener, Input } from '@angular/core';\r\n\r\n@Directive({\r\n selector: '[decimalNumber]'\r\n})\r\nexport class DecimalNumberDirective {\r\n constructor(private el: ElementRef) {\r\n }\r\n\r\n // Allow key codes for special events. Reflect :\r\n // Backspace, tab, end, home\r\n @Input() decimalPrecision: number = 2;\r\n\r\n private specialKeys: Array = ['Backspace', 'Tab', 'End', 'Home', 'ArrowLeft', 'ArrowRight', 'Del', 'Delete'];\r\n\r\n\r\n @HostListener('keydown', ['$event'])\r\n onKeyDown(event: KeyboardEvent) {\r\n const regex = new RegExp(`^\\\\d*\\\\.?\\\\d{0,${ this.decimalPrecision }}$`);\r\n\r\n // Allow Backspace, tab, end, and home keys\r\n if (this.specialKeys.indexOf(event.key) !== -1) {\r\n return;\r\n }\r\n const current: string = this.el.nativeElement.value;\r\n const position = this.el.nativeElement.selectionStart;\r\n const next: string = [current.slice(0, position), event.key == 'Decimal' ? '.' : event.key, current.slice(position)].join('');\r\n if (next && !String(next).match(regex)) {\r\n event.preventDefault();\r\n }\r\n }\r\n}","\r\n\r\n {{model.parcelAcctNum}}\r\n\r\n\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n","import {of as observableOf, Observable } from 'rxjs';\r\nimport { Component, OnInit, OnChanges, Input, Output, EventEmitter, SimpleChanges, SimpleChange } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { EntityPickerService } from '../../Entity-Picker/entityPicker.service';\r\nimport { mergeMap } from 'rxjs/operators';\r\n\r\ninterface ParcelSelectorComponentChanges extends SimpleChanges {\r\n parcelId: SimpleChange;\r\n siteIds: SimpleChange;\r\n}\r\n\r\n@Component({\r\n selector: 'parcel-selector',\r\n templateUrl: './parcelSelector.component.html',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: ParcelSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class ParcelSelectorComponent implements OnInit, OnChanges, ControlValueAccessor {\r\n constructor(\r\n private readonly _entityPickerService: EntityPickerService\r\n ) { }\r\n\r\n // reactive forms functions\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n @Input() companyId;\r\n @Input() reportingParcelId;\r\n @Input() excludeParcelIds: number[];\r\n @Input() siteIds: number[];\r\n @Input() masterSiteIds: number[];\r\n @Input() isOverridden: boolean = false;\r\n @Input() isDisabled: boolean = false;\r\n @Input() loadParcelsOnInit: boolean = true;\r\n @Input() getParcels: (searchParams: any) => Promise>;\r\n @Input() optionFlagText: string;\r\n @Output() reportingParcelIdChange = new EventEmitter();\r\n\r\n reportingParcelFilter: string = '';\r\n allReportingParcels: any[] = [];\r\n reportingParcels: any[] = [];\r\n selectedReportingParcelAcctNum: string = '';\r\n selectedReportingParcelSiteId: number;\r\n showOnlyParcelsUnderSite: boolean;\r\n\r\n // this component will be considered initialized when the reporting parcels have been loaded\r\n // in the meanwhile, any select reporting parcel attempts will be skipped\r\n isInitialized: boolean = false;\r\n\r\n reportingParcels$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.reportingParcelFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterReportingParcels(token)));\r\n\r\n ngOnInit() {\r\n if (this.loadParcelsOnInit) {\r\n this.loadParcels();\r\n }\r\n }\r\n\r\n ngOnChanges(changes: ParcelSelectorComponentChanges): void {\r\n if (changes.reportingParcelId || changes.siteIds) {\r\n this._selectReportingParcel(this.reportingParcelId);\r\n }\r\n }\r\n\r\n async loadParcels() {\r\n const searchParams = {\r\n companyId: this.companyId,\r\n excludeParcelIds: this._filterInvalidExcludeParcelIds(this.excludeParcelIds)\r\n } as Compliance.ReportingParcelSearchModel;\r\n\r\n const reportingParcels = await this.getParcels(searchParams);\r\n\r\n this.allReportingParcels = reportingParcels.data;\r\n this.reportingParcels = this.allReportingParcels;\r\n\r\n this.isInitialized = true;\r\n this._selectReportingParcel(this.reportingParcelId);\r\n }\r\n\r\n writeValue(reportingParcelId: number): void {\r\n this._selectReportingParcel(reportingParcelId);\r\n }\r\n\r\n nge(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState?(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n onReportingParcelBlur(): void {\r\n this._selectReportingParcel(this.reportingParcelId);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onReportingParcelSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const parcel = match.item as Compliance.ReportingParcelModel;\r\n this._selectReportingParcel(parcel.parcelId);\r\n this.reportingParcelIdChange.emit(parcel.parcelId);\r\n }\r\n }\r\n\r\n _filterInvalidExcludeParcelIds(excludeIds: number[]): number[] {\r\n return excludeIds ? excludeIds.filter((entry: number) => entry !== undefined && entry !== null) : [];\r\n }\r\n\r\n async openPickerModal() {\r\n const searchModel: Compliance.ReportingParcelSearchModel = {\r\n companyId: this.companyId,\r\n excludeParcelIds: this._filterInvalidExcludeParcelIds(this.excludeParcelIds),\r\n includeSiteIds: []\r\n };\r\n\r\n const entityPickerResult = await this._entityPickerService.showParcelPicker(searchModel, this.siteIds, this.masterSiteIds,\r\n this.selectedReportingParcelSiteId, this.getParcels, this.optionFlagText);\r\n\r\n if(entityPickerResult && entityPickerResult.result) {\r\n this._selectReportingParcel(entityPickerResult.result.parcelId);\r\n this.reportingParcelIdChange.emit(entityPickerResult.result.parcelId);\r\n }\r\n }\r\n\r\n private _filterReportingParcels(filter: string): Observable {\r\n if (filter === null || filter === undefined) filter = '';\r\n return observableOf(\r\n (this.reportingParcels || []).filter(i => i.parcelAcctNum.toLowerCase().includes(filter.toLowerCase()))\r\n );\r\n }\r\n\r\n private _selectReportingParcel(parcelId: number): void {\r\n if (!this.isInitialized) return;\r\n\r\n const parcel = this.allReportingParcels.find(rp => rp.parcelId === parcelId);\r\n\r\n if (parcel) {\r\n this.reportingParcels = (this.siteIds || this.masterSiteIds) ? this.allReportingParcels.filter(x => (this.siteIds && this.siteIds.includes(x.siteId)) || (this.masterSiteIds && this.masterSiteIds.includes(x.siteId)) || x.parcelId === parcelId) : this.allReportingParcels;\r\n this.reportingParcelId = parcel.parcelId;\r\n this.selectedReportingParcelSiteId = parcel.siteId;\r\n this.reportingParcelFilter = parcel.parcelAcctNum;\r\n this.selectedReportingParcelAcctNum = parcel.parcelAcctNum;\r\n this._onChangeFn && this._onChangeFn(this.reportingParcelId);\r\n } else if (parcelId == null) {\r\n this.reportingParcelFilter = null;\r\n this.reportingParcels = this.siteIds ? this.allReportingParcels.filter(x => this.siteIds.includes(x.siteId)) : this.allReportingParcels;\r\n } else {\r\n this.reportingParcelFilter = this.selectedReportingParcelAcctNum;\r\n this.reportingParcels = this.siteIds ? this.allReportingParcels.filter(x => this.siteIds.includes(x.siteId)) : this.allReportingParcels;\r\n }\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\n\r\nenum ReportingAssetBulkUpdateFieldActionEnum {\r\n NoChange = 0,\r\n SetToBlank = 1,\r\n ChangeTo = 2\r\n}\r\n\r\n@Component({\r\n selector: 'asset-bulk-update-action',\r\n templateUrl: './assetBulkUpdateAction.component.html',\r\n styles: ['select {width:120px}']\r\n})\r\nexport class AssetBulkUpdateActionComponent implements OnInit{\r\n constructor(\r\n ){\r\n this.possibleActions = [\r\n { name: 'No Change', value: Compliance.ReportingAssetBulkUpdateFieldActionEnum.NoChange },\r\n { name: 'Change To', value: Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo },\r\n { name: 'Set to Blank', value: Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank },\r\n { name: 'Remove Override', value: Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride },\r\n { name: 'Verify', value: Compliance.ReportingAssetBulkUpdateFieldActionEnum.Verify }\r\n ];\r\n }\r\n\r\n @Input()\r\n set fieldAction(fieldAction: Compliance.ReportingAssetBulkUpdateFieldActionEnum) {\r\n this.fieldActionChanged(fieldAction);\r\n }\r\n\r\n @Output() fieldActionChange = new EventEmitter();\r\n @Input() requiredField: boolean;\r\n @Input() fieldHasOverrides: boolean = false;\r\n @Input() verifyField: boolean = false;\r\n @Input() disabled: boolean;\r\n\r\n action: Compliance.ReportingAssetBulkUpdateFieldActionEnum;\r\n possibleActions: Compliance.NameValuePair[];\r\n selectedAction: Compliance.ReportingAssetBulkUpdateFieldActionEnum = Compliance.ReportingAssetBulkUpdateFieldActionEnum.NoChange;\r\n\r\n ngOnInit(): void {\r\n if (this.verifyField){\r\n this.possibleActions = this.possibleActions.filter(i => i.value === Compliance.ReportingAssetBulkUpdateFieldActionEnum.NoChange ||\r\n i.value === Compliance.ReportingAssetBulkUpdateFieldActionEnum.Verify);\r\n } else {\r\n this.possibleActions = this.possibleActions.filter(i => i.value !== Compliance.ReportingAssetBulkUpdateFieldActionEnum.Verify);\r\n }\r\n\r\n if (this.requiredField){\r\n this.possibleActions = this.possibleActions.filter(i => i.value !== Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank);\r\n }\r\n\r\n if (!this.fieldHasOverrides){\r\n this.possibleActions = this.possibleActions.filter(i => i.value !== Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride);\r\n }\r\n }\r\n\r\n public fieldActionChanged(action: Compliance.ReportingAssetBulkUpdateFieldActionEnum): void {\r\n if (action || action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.NoChange) {\r\n this.selectedAction = action;\r\n this.fieldActionChange.next(action);\r\n } else {\r\n this.selectedAction = Compliance.ReportingAssetBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n }\r\n\r\n isSelected(action: Compliance.ReportingAssetBulkUpdateFieldActionEnum): boolean{\r\n return action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n}\r\n","\r\n","
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n","import { Component, Input, Output, EventEmitter, SimpleChanges, SimpleChange } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { AssetDescriptorFieldTypes } from '../Models/enums';\r\nimport * as _ from 'lodash';\r\n\r\ninterface AssetDescriptorEditComponentChanges extends SimpleChanges {\r\n descriptor: SimpleChange,\r\n isDisabled: SimpleChange\r\n}\r\n\r\n@Component({\r\n selector: 'asset-descriptor-edit',\r\n templateUrl: './assetDescriptorEdit.component.html',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: AssetDescriptorEditComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class AssetDescriptorEditComponent implements ControlValueAccessor {\r\n constructor() {\r\n this.dateChange = new EventEmitter();\r\n }\r\n\r\n @Input() descriptor: Compliance.CompanyAssetDescriptorMappingModel;\r\n @Input() isDisabled: boolean = false;\r\n @Input() isOverridden: boolean = false;\r\n @Output() dateChange: EventEmitter;\r\n\r\n pickList: string[];\r\n textValue: string;\r\n numberValue: number;\r\n dateValue: Date;\r\n booleanValue: boolean;\r\n\r\n fieldTypes = AssetDescriptorFieldTypes;\r\n\r\n private _onChangeFn: (val: any) => void;\r\n private _onTouchedFn: () => void;\r\n\r\n ngOnChanges(changes: AssetDescriptorEditComponentChanges): void {\r\n if (changes && changes.descriptor) {\r\n this._setModel();\r\n }\r\n }\r\n\r\n descriptorTypesEq(a: Core.DescriptorFieldTypes, b: AssetDescriptorFieldTypes): boolean {\r\n return (a as number) === (b as number);\r\n }\r\n\r\n registerOnChange(fn: (val: any) => void): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: () => void): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n writeValue(val: any): void {\r\n switch (this.descriptor.descriptor.fieldType) {\r\n case Core.DescriptorFieldTypes.Text:\r\n this.textValue = val;\r\n break;\r\n case Core.DescriptorFieldTypes.Number:\r\n this.numberValue = val;\r\n break;\r\n case Core.DescriptorFieldTypes.Date:\r\n if (!val) {\r\n this.dateValue = null;\r\n } else {\r\n this.dateValue = new Date(val);\r\n }\r\n break;\r\n case Core.DescriptorFieldTypes.YesNo:\r\n this.booleanValue = !!val;\r\n break;\r\n case Core.DescriptorFieldTypes.Currency:\r\n this.numberValue = val;\r\n break;\r\n case Core.DescriptorFieldTypes.Picklist:\r\n this.textValue = val;\r\n break;\r\n }\r\n }\r\n\r\n notifyTextChange(): void {\r\n this._onChangeFn && this._onChangeFn(this.textValue);\r\n }\r\n\r\n notifyNumberChange(): void {\r\n this._onChangeFn && this._onChangeFn(this.numberValue);\r\n }\r\n\r\n notifyDateChange(): void {\r\n this._onChangeFn && this._onChangeFn(this.dateValue);\r\n this.dateChange.emit(this.dateValue);\r\n }\r\n\r\n notifyBooleanChange(): void {\r\n const v = this.booleanValue ? 1 : 0;\r\n this._onChangeFn && this._onChangeFn(v);\r\n }\r\n\r\n getMaxLength(): number {\r\n let maxLength = 1000;\r\n if(this.descriptor && this.descriptor.descriptor && this.descriptor.descriptor.validation && this.descriptor.descriptor.validation.maxLength) {\r\n maxLength = this.descriptor.descriptor.validation.maxLength;\r\n }\r\n return maxLength;\r\n }\r\n\r\n private _setModel(): void {\r\n this.pickList = _.map(_.filter(this.descriptor && this.descriptor.pickList, y => !y.disabled), x => x.name);\r\n }\r\n}\r\n","\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Manual Asset Verification\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
Ownership Type\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
Lease Type\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
Classification\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
{{descriptor.descriptor.name}}\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
Alternative Acquisition Date Field\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
Acquisition Date\r\n \r\n \r\n \r\n \r\n \r\n
Disposed Date\r\n \r\n \r\n \r\n \r\n \r\n
Do Not Potentially Dispose\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
Description\r\n \r\n \r\n \r\n \r\n
{{descriptor.descriptor.name}}\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
Alternative Cost Field\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
Cost\r\n \r\n \r\n \r\n \r\n \r\n
Net Book Value\r\n \r\n \r\n \r\n \r\n \r\n
GL Account\r\n \r\n \r\n \r\n \r\n
Site\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
Is Anchored\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
Parcel\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n Is Perpetual\r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
Is Locked\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
Remove overrides\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
{{descriptor.descriptor.name}}\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n

0\">Cost Adjustments By State

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n {{stateCostAdjustment.state}}\r\n
{{costAdjustment.costAdjustment}}\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
$
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
%
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Create New Asset Split
Split Cost Percentage\r\n
\r\n
\r\n
%
\r\n \r\n
\r\n
\r\n
Split Asset Classification\r\n
\r\n \r\n
\r\n
Split Description Append Text\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Update Existing Asset Split
Split Cost Percentage\r\n
\r\n
\r\n
%
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

{{validationMessage}}

\r\n
\r\n
\r\n
\r\n
\r\n","import {\r\n AfterViewInit,\r\n Component,\r\n DoCheck, ElementRef,\r\n KeyValueDiffer,\r\n KeyValueDiffers,\r\n OnDestroy,\r\n OnInit,\r\n Renderer2,\r\n ViewChild\r\n} from '@angular/core';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { from as observableFrom, lastValueFrom, Observable, of as observableOf, Subject } from 'rxjs';\r\nimport { map, mergeMap, takeUntil } from 'rxjs/operators';\r\nimport {\r\n AssetRepository,\r\n CompanyAssetDescriptorRepository,\r\n CostAdjustmentRepository,\r\n GLAccountRepository,\r\n ReportingParcelRepository\r\n} from '../../../Repositories';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ExtendedGLAccountModel } from '../../Asset-Details/Asset-Info/extendedGLAccountModel';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport { MessageModalService } from '../../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { ExtendedSiteModel } from '../../Asset-Details/Asset-Info/extendedSiteModel';\r\nimport { AssetLienDate } from '../../Asset-Lien-Date/assetLienDate.component';\r\nimport { SiteRepository } from '../../../../Core-Repositories';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { AssetBulkUpdateActionComponent } from './assetBulkUpdateAction.component';\r\nimport { HelpContentComponentConfig, HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { ASSET_BULK_UPDATE_HELP } from './assetBulkUpdate.component.help';\r\nimport {\r\n CostAdjustmentHelpComponent,\r\n CostAdjustmentHelpComponentParams\r\n} from '../../Asset-Details/costAdjustmentHelp.component';\r\nimport { FlattenedCostAdjustmentSource } from '../../Asset-Details/Asset-Info/assetInfo.component';\r\nimport { TimerService } from '../../../../UI-Lib/Utilities';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nexport class BulkUpdateStateCostAdjustment {\r\n stateId: number;\r\n state: string;\r\n costAdjustments: BulkUpdateCostAdjustment[];\r\n customHelpRenderer: HelpContentComponentConfig;\r\n extendedCostAdjustmentTypes: FlattenedCostAdjustmentSource[];\r\n}\r\n\r\nexport class BulkUpdateCostAdjustment {\r\n costAdjustmentTypeId: number;\r\n costAdjustment: string;\r\n sequence: number;\r\n}\r\n\r\nexport interface AssetBulkUpdateParams {\r\n companyId: number;\r\n lienDate: AssetLienDate;\r\n reportingAssetIds: number[];\r\n selection: Compliance.SelectedRowsModel;\r\n selectedCount: number;\r\n assetListLastModifiedTimestamp: Date;\r\n hotkeyFocus: string;\r\n siteId?: number;\r\n parcelId?: number;\r\n}\r\n\r\nenum AssetBulkUpdateTabEnum{\r\n AssetFields,\r\n Splits\r\n}\r\n\r\n@Component({\r\n selector: 'asset-bulk-update-modal',\r\n templateUrl: './assetBulkUpdate.component.html',\r\n styleUrls: ['./assetBulkUpdate.component.scss'],\r\n})\r\nexport class AssetBulkUpdateComponent implements OnInit, AfterViewInit, OnDestroy, DoCheck, IWeissmanModalComponent> {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _assetRepository: AssetRepository,\r\n private readonly _glAccountRepository: GLAccountRepository,\r\n private readonly _costAdjustmentRepository: CostAdjustmentRepository,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe,\r\n private readonly _siteService: SiteRepository,\r\n private readonly _helpService: HelpService,\r\n private readonly _companyAssetDescriptorRepository: CompanyAssetDescriptorRepository,\r\n private readonly _differs: KeyValueDiffers,\r\n private readonly _renderer: Renderer2,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _timerService: TimerService,\r\n private readonly _reportingParcelRepository: ReportingParcelRepository,\r\n private readonly _toastrService: ToastrService\r\n ) { }\r\n\r\n @ViewChild('bulkUpdateFieldContainer', { static: true }) bulkUpdateFormElement: ElementRef;\r\n @ViewChild('leaseTypeActionField') leaseTypeActionField: AssetBulkUpdateActionComponent;\r\n\r\n params: AssetBulkUpdateParams;\r\n result: Compliance.QueryResultWithTotalsModel;\r\n\r\n reportingAssetBulkUpdateModel: Compliance.ReportingAssetBulkUpdateModel = { } as Compliance.ReportingAssetBulkUpdateModel;\r\n glAccountFilter: string = '';\r\n glAccountLastMatch: string = null;\r\n assetClassificationId: number;\r\n assetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[];\r\n costAssetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[];\r\n acqDateAssetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[];\r\n bulkUpdateMetadata: Compliance.ReportingAssetBulkUpdateSelectionMetadataModel;\r\n costAdjustmentTypes: Compliance.CostAdjustmentTypeModel[];\r\n stateCostAdjustments: BulkUpdateStateCostAdjustment[] = new Array();\r\n siteIds: number[];\r\n isFormValid: boolean = false;\r\n isAssetFieldTabValid: boolean = false;\r\n isSplitTabValid: boolean = false;\r\n isLoading: boolean = false;\r\n isSaving: boolean = false;\r\n isBulkMetadataLoaded: boolean = false;\r\n\r\n validationMessage: string = '';\r\n displayPerpetualTooltip: boolean = false;\r\n perpetualAllowedAssetsCount: number;\r\n siteFilter: string = '';\r\n siteIsLoading: boolean = false;\r\n siteFieldEdited: boolean = false;\r\n\r\n isCreateNewSplitAllowed: boolean = false;\r\n isUpdateSplitAllowed: boolean = false;\r\n\r\n activeTab: AssetBulkUpdateTabEnum = AssetBulkUpdateTabEnum.AssetFields;\r\n\r\n assetBulkUpdateTabEnum = AssetBulkUpdateTabEnum;\r\n\r\n assetVerificationReasons: string[];\r\n\r\n perpetualHelpContentId: string = 'asset-bulk-update.isPerpetual-none';\r\n\r\n leaseTypes: Compliance.LeaseTypeModel[];\r\n ownershipTypes: Compliance.AssetOwnershipTypeModel[];\r\n\r\n glAccounts$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.glAccountFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterGlAccounts(token)));\r\n\r\n sites$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.siteFilter); }) as Observable)\r\n .pipe(mergeMap((token: string) => this._filterSites(token)));\r\n\r\n busyRefId: string = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n\r\n private _glAccounts: ExtendedGLAccountModel[];\r\n private _glAccountNoResult: boolean = false;\r\n private _bulkUpdateModelDiffer: KeyValueDiffer;\r\n private _siteNoResult: boolean = false;\r\n\r\n private readonly OWNERSHIP_TYPE_OWNED = 0;\r\n\r\n private _busyRef: BusyIndicatorRef;\r\n private _closed: boolean;\r\n private _destroy$: Subject = new Subject();\r\n\r\n\r\n\r\n get selectedCount(): string {\r\n return this._decimalPipe.transform(this.params.selectedCount);\r\n }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(ASSET_BULK_UPDATE_HELP);\r\n this._loadMetadata();\r\n\r\n this.initializeBulkUpdateModel();\r\n\r\n this._bulkUpdateModelDiffer = this._differs.find(this.reportingAssetBulkUpdateModel).create();\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this._focusOnFormElement(this.params.hotkeyFocus, true);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n ngDoCheck(): void {\r\n const assetChanges = this._bulkUpdateModelDiffer && this._bulkUpdateModelDiffer.diff(this.reportingAssetBulkUpdateModel);\r\n\r\n if (assetChanges) {\r\n this.validateForm();\r\n }\r\n }\r\n\r\n onGlAccountSelected(match: TypeaheadMatch): void {\r\n this.reportingAssetBulkUpdateModel.glAccountId = (match.item as ExtendedGLAccountModel).model.glAccountId;\r\n this.glAccountFilter = match.value;\r\n this.glAccountLastMatch = match.value;\r\n }\r\n\r\n onGlAccountBlur(): void {\r\n if (this.glAccountFilter.trim() === '' || this._glAccountNoResult) {\r\n this.glAccountFilter = '';\r\n this.reportingAssetBulkUpdateModel.glAccountId = null;\r\n } else if (this.glAccountLastMatch && this.glAccountLastMatch !== this.glAccountFilter.trim()) {\r\n this.glAccountFilter = this.glAccountLastMatch;\r\n }\r\n }\r\n\r\n onGlAccountNoResults(event: boolean): void {\r\n this._glAccountNoResult = event;\r\n\r\n if (event) {\r\n this.glAccountLastMatch = null;\r\n this.reportingAssetBulkUpdateModel.glAccountId = null;\r\n }\r\n }\r\n\r\n onSiteNoResults(event: boolean): void {\r\n this._siteNoResult = event;\r\n }\r\n\r\n validateForm(): void {\r\n this.validationMessage = '';\r\n this.isFormValid = false;\r\n this.isSplitTabValid = false;\r\n\r\n const areSplitFieldsValid =\r\n (this.reportingAssetBulkUpdateModel.isBulkCreateSplitOperation\r\n && this.reportingAssetBulkUpdateModel.splitCreateCostAllocationPercentage >= 0\r\n && this.reportingAssetBulkUpdateModel.splitCreateCostAllocationPercentage <= 100)\r\n ||\r\n (this.reportingAssetBulkUpdateModel.isBulkUpdateSplitOperation\r\n && this.reportingAssetBulkUpdateModel.splitUpdateCostAllocationPercentage >= 0\r\n && this.reportingAssetBulkUpdateModel.splitUpdateCostAllocationPercentage <= 100);\r\n\r\n const areBaseFieldsValid =\r\n (this.reportingAssetBulkUpdateModel.assetVerificationReason != null\r\n && this.reportingAssetBulkUpdateModel.assetVerificationDate != null\r\n && this.reportingAssetBulkUpdateModel.assetVerificationAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.Verify)\r\n ||\r\n (this.reportingAssetBulkUpdateModel.ownershipTypeId != null\r\n && this.reportingAssetBulkUpdateModel.ownershipTypeAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo)\r\n ||\r\n (this.reportingAssetBulkUpdateModel.leaseTypeId\r\n && this.reportingAssetBulkUpdateModel.leaseTypeAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo)\r\n ||\r\n (this.reportingAssetBulkUpdateModel.acqDate\r\n && this.reportingAssetBulkUpdateModel.acqDateAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.acqDateAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.classificationId\r\n && this.reportingAssetBulkUpdateModel.classificationIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.classificationIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.classificationIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.cost && this.reportingAssetBulkUpdateModel.costAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.costAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (typeof this.reportingAssetBulkUpdateModel.isPerpetual !=='undefined' && this.reportingAssetBulkUpdateModel.isPerpetual !== null && this.reportingAssetBulkUpdateModel.isPerpetualAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo)\r\n || (this.reportingAssetBulkUpdateModel.description\r\n && this.reportingAssetBulkUpdateModel.description !== ''\r\n && this.reportingAssetBulkUpdateModel.descriptionAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.descriptionAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.descriptionAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.disposedDate\r\n && this.reportingAssetBulkUpdateModel.disposedDateAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.disposedDateAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.glAccountId\r\n && this.reportingAssetBulkUpdateModel.glAccountIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.glAccountIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.siteId\r\n && this.reportingAssetBulkUpdateModel.siteIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.siteIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.reportingParcelId\r\n && this.reportingAssetBulkUpdateModel.reportingParcelIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.reportingParcelIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t1\r\n && this.reportingAssetBulkUpdateModel.t1Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t1Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t1Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t2\r\n && this.reportingAssetBulkUpdateModel.t2Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t2Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t2Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t3\r\n && this.reportingAssetBulkUpdateModel.t3Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t3Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t3Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t4\r\n && this.reportingAssetBulkUpdateModel.t4Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t4Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t4Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t5\r\n && this.reportingAssetBulkUpdateModel.t5Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t5Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t5Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t6\r\n && this.reportingAssetBulkUpdateModel.t6Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t6Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t6Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t7\r\n && this.reportingAssetBulkUpdateModel.t7Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t7Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t7Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t8\r\n && this.reportingAssetBulkUpdateModel.t8Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t8Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t8Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t9\r\n && this.reportingAssetBulkUpdateModel.t9Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t9Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t9Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t10\r\n && this.reportingAssetBulkUpdateModel.t10Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t10Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t10Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t11\r\n && this.reportingAssetBulkUpdateModel.t11Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t11Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t11Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t12\r\n && this.reportingAssetBulkUpdateModel.t12Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t12Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t12Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t13\r\n && this.reportingAssetBulkUpdateModel.t13Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t13Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t13Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t14\r\n && this.reportingAssetBulkUpdateModel.t14Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t14Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t14Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t15\r\n && this.reportingAssetBulkUpdateModel.t15Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t15Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t15Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t16\r\n && this.reportingAssetBulkUpdateModel.t16Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t16Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t16Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t17\r\n && this.reportingAssetBulkUpdateModel.t17Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t17Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t17Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t18\r\n && this.reportingAssetBulkUpdateModel.t18Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t18Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t18Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t19\r\n && this.reportingAssetBulkUpdateModel.t19Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t19Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t19Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t20\r\n && this.reportingAssetBulkUpdateModel.t20Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t20Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t20Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t21\r\n && this.reportingAssetBulkUpdateModel.t21Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t21Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t21Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t22\r\n && this.reportingAssetBulkUpdateModel.t22Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t22Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t22Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t23\r\n && this.reportingAssetBulkUpdateModel.t23Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t23Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t23Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t24\r\n && this.reportingAssetBulkUpdateModel.t24Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t24Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t24Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t25\r\n && this.reportingAssetBulkUpdateModel.t25Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t25Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t25Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t26\r\n && this.reportingAssetBulkUpdateModel.t26Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t26Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t26Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t27\r\n && this.reportingAssetBulkUpdateModel.t27Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t27Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t27Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t28\r\n && this.reportingAssetBulkUpdateModel.t28Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t28Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t28Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t29\r\n && this.reportingAssetBulkUpdateModel.t29Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t29Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t29Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.t30\r\n && this.reportingAssetBulkUpdateModel.t30Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.t30Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank\r\n || this.reportingAssetBulkUpdateModel.t30Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.n1\r\n && this.reportingAssetBulkUpdateModel.n1Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.n1Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.n2\r\n && this.reportingAssetBulkUpdateModel.n2Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.n2Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.n3\r\n && this.reportingAssetBulkUpdateModel.n3Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.n3Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.n4\r\n && this.reportingAssetBulkUpdateModel.n4Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.n4Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.n5\r\n && this.reportingAssetBulkUpdateModel.n5Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.n5Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.n6\r\n && this.reportingAssetBulkUpdateModel.n6Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.n6Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.n7\r\n && this.reportingAssetBulkUpdateModel.n7Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.n7Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.n8\r\n && this.reportingAssetBulkUpdateModel.n8Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.n8Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.n9\r\n && this.reportingAssetBulkUpdateModel.n9Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.n9Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.n10\r\n && this.reportingAssetBulkUpdateModel.n10Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.n10Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.d1\r\n && this.reportingAssetBulkUpdateModel.d1Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.d1Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.d2\r\n && this.reportingAssetBulkUpdateModel.d2Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.d2Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.d3\r\n && this.reportingAssetBulkUpdateModel.d3Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.d3Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.d4\r\n && this.reportingAssetBulkUpdateModel.d4Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.d4Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.d5\r\n && this.reportingAssetBulkUpdateModel.d5Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.d5Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.d6\r\n && this.reportingAssetBulkUpdateModel.d6Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.d6Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.d7\r\n && this.reportingAssetBulkUpdateModel.d7Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.d7Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.d8\r\n && this.reportingAssetBulkUpdateModel.d8Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.d8Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.d9\r\n && this.reportingAssetBulkUpdateModel.d9Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.d9Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.d10\r\n && this.reportingAssetBulkUpdateModel.d10Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.d10Action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || (this.reportingAssetBulkUpdateModel.netBookValue\r\n && this.reportingAssetBulkUpdateModel.netBookValueAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || this.reportingAssetBulkUpdateModel.netBookValueAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.RemoveOverride)\r\n || ((this.reportingAssetBulkUpdateModel.isAnchored || this.reportingAssetBulkUpdateModel.isAnchored === false)\r\n && this.reportingAssetBulkUpdateModel.isAnchoredAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo)\r\n || ((this.reportingAssetBulkUpdateModel.doNotPotentiallyDispose || this.reportingAssetBulkUpdateModel.doNotPotentiallyDispose === false)\r\n && this.reportingAssetBulkUpdateModel.doNotPotentiallyDisposeAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo)\r\n || ((this.reportingAssetBulkUpdateModel.isLocked || this.reportingAssetBulkUpdateModel.isLocked === false)\r\n && this.reportingAssetBulkUpdateModel.isLockedAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo);\r\n\r\n const isAlternativeAcqDateFieldRequired = this.reportingAssetBulkUpdateModel.alternativeAcqDateDescriptorIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo;\r\n const isAlternativeCostFieldRequired = this.reportingAssetBulkUpdateModel.alternativeCostDescriptorIdAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo;\r\n\r\n if (isAlternativeAcqDateFieldRequired || isAlternativeCostFieldRequired) {\r\n const isAlternativeAcqDateFieldValid = !isAlternativeAcqDateFieldRequired || (isAlternativeAcqDateFieldRequired && this.reportingAssetBulkUpdateModel.alternativeAcqDateDescriptorId === null || this.reportingAssetBulkUpdateModel.alternativeAcqDateDescriptorId >= 0);\r\n const isAlternativeCostFieldValid = !isAlternativeCostFieldRequired || (isAlternativeCostFieldRequired && this.reportingAssetBulkUpdateModel.alternativeCostDescriptorId === null || this.reportingAssetBulkUpdateModel.alternativeCostDescriptorId >= 0);\r\n\r\n const alternativeAcqDateAssetDescriptor = this.acqDateAssetDescriptors.find(x => x.companyAssetDescriptorMappingId == this.reportingAssetBulkUpdateModel.alternativeAcqDateDescriptorId);\r\n const alternativeCostAssetDescriptor = this.costAssetDescriptors.find(x => x.companyAssetDescriptorMappingId == this.reportingAssetBulkUpdateModel.alternativeCostDescriptorId);\r\n\r\n if (alternativeAcqDateAssetDescriptor && this.reportingAssetBulkUpdateModel[`${alternativeAcqDateAssetDescriptor.columnName.toLowerCase()}Action`] === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank) {\r\n this.validationMessage = `${alternativeAcqDateAssetDescriptor.descriptor.name} cannot be set to blank because it is used for the Alternative Acquisition Date field.`;\r\n this.isFormValid = false;\r\n return;\r\n }\r\n\r\n if (alternativeCostAssetDescriptor && this.reportingAssetBulkUpdateModel[`${alternativeCostAssetDescriptor.columnName.toLowerCase()}Action`] === Compliance.ReportingAssetBulkUpdateFieldActionEnum.SetToBlank) {\r\n this.validationMessage = `${alternativeCostAssetDescriptor.descriptor.name} cannot be set to blank because it is used for the Alternative Cost field.`;\r\n this.isFormValid = false;\r\n return;\r\n }\r\n\r\n this.isFormValid = isAlternativeAcqDateFieldValid && isAlternativeCostFieldValid;\r\n return;\r\n }\r\n\r\n if (this.reportingAssetBulkUpdateModel.costAdjustmentUpdates) {\r\n for (let i = 0; i < this.reportingAssetBulkUpdateModel.costAdjustmentUpdates.length; i++) {\r\n const costAdjustmentUpdate = this.reportingAssetBulkUpdateModel.costAdjustmentUpdates[i];\r\n\r\n if (costAdjustmentUpdate.fieldAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo && (costAdjustmentUpdate.adjustmentAmount !== 0 || costAdjustmentUpdate.adjustmentPercentage !== 0)) {\r\n this.isFormValid = true;\r\n this.isAssetFieldTabValid = true;\r\n return;\r\n }\r\n }\r\n }\r\n\r\n if (this.reportingAssetBulkUpdateModel.isBulkCreateSplitOperation\r\n && (this.reportingAssetBulkUpdateModel.splitCreateCostAllocationPercentage < 0 || this.reportingAssetBulkUpdateModel.splitCreateCostAllocationPercentage > 100 || this.reportingAssetBulkUpdateModel.splitCreateCostAllocationPercentage === null))\r\n {\r\n this.validationMessage = 'Split Cost Percentage must me between 0% and 100%.';\r\n this.isFormValid = false;\r\n this.isSplitTabValid = false;\r\n return;\r\n }\r\n\r\n if (this.reportingAssetBulkUpdateModel.isBulkUpdateSplitOperation\r\n && (this.reportingAssetBulkUpdateModel.splitUpdateCostAllocationPercentage < 0 || this.reportingAssetBulkUpdateModel.splitUpdateCostAllocationPercentage > 100 || this.reportingAssetBulkUpdateModel.splitUpdateCostAllocationPercentage === null))\r\n {\r\n this.validationMessage = 'Split Cost Percentage must me between 0% and 100%.';\r\n this.isFormValid = false;\r\n this.isSplitTabValid = false;\r\n return;\r\n }\r\n\r\n this.isFormValid = areBaseFieldsValid || areSplitFieldsValid;\r\n this.isAssetFieldTabValid = areBaseFieldsValid;\r\n this.isSplitTabValid = areSplitFieldsValid;\r\n }\r\n\r\n async save(): Promise {\r\n this.isSaving = true;\r\n await this._bulkUpdate();\r\n }\r\n\r\n cancel(): void {\r\n this._closed = true;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n changeActiveTab(activeTab: AssetBulkUpdateTabEnum): void {\r\n if ((activeTab !== AssetBulkUpdateTabEnum.AssetFields && this.isAssetFieldTabValid) || (activeTab !== AssetBulkUpdateTabEnum.Splits && this.isSplitTabValid)) {\r\n if(!confirm('Switching tabs will clear all fields. Do you want to continue?')) {\r\n return;\r\n }\r\n\r\n this.validationMessage = null;\r\n this.initializeBulkUpdateModel();\r\n }\r\n\r\n this.activeTab = activeTab;\r\n this.reportingAssetBulkUpdateModel.isBulkCreateSplitOperation = activeTab === AssetBulkUpdateTabEnum.Splits && this.bulkUpdateMetadata && this.bulkUpdateMetadata.isCreateSplitEnabled;\r\n this.reportingAssetBulkUpdateModel.isBulkUpdateSplitOperation = activeTab === AssetBulkUpdateTabEnum.Splits && this.bulkUpdateMetadata && this.bulkUpdateMetadata.isUpdateSplitEnabled;\r\n this.validateForm();\r\n }\r\n\r\n getParcels = async (searchParams: any): Promise> => {\r\n return await lastValueFrom(this._reportingParcelRepository.getReportingParcelsByAsset(searchParams));\r\n };\r\n\r\n get unlockAssets() : boolean {\r\n return this.reportingAssetBulkUpdateModel &&\r\n this.reportingAssetBulkUpdateModel.isLockedAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo &&\r\n this.reportingAssetBulkUpdateModel.isLocked === false;\r\n }\r\n\r\n async overrideAllFields(): Promise {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you want to override all fields?', 'Confirm Update');\r\n } catch (e3) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._bulkUpdate(false, true);\r\n }\r\n\r\n isLockedChanged($event) {\r\n this.reportingAssetBulkUpdateModel.isLockedRemoveOverridesAction = Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo;\r\n this.reportingAssetBulkUpdateModel.isLockedRemoveOverrides = false;\r\n }\r\n\r\n ownershipTypeChanged(ownershipTypeId?: number): void {\r\n if (ownershipTypeId === this.OWNERSHIP_TYPE_OWNED) {\r\n this.leaseTypeActionField.fieldActionChanged(Compliance.ReportingAssetBulkUpdateFieldActionEnum.NoChange);\r\n }\r\n }\r\n\r\n isDisabled(action: Compliance.ReportingAssetBulkUpdateFieldActionEnum){\r\n return action !== Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo && action !== Compliance.ReportingAssetBulkUpdateFieldActionEnum.Verify;\r\n }\r\n\r\n isLeaseTypeFieldDisabled() {\r\n return this.reportingAssetBulkUpdateModel.ownershipTypeAction !== Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo\r\n || (this.reportingAssetBulkUpdateModel.ownershipTypeId == null || this.reportingAssetBulkUpdateModel.ownershipTypeId === this.OWNERSHIP_TYPE_OWNED);\r\n }\r\n\r\n isCostInputDisabled(stateId: number, typeId: number, isPercent: boolean): boolean {\r\n const otherElemSelector = isPercent ? '.costAdjustmentAmount' : '.costAdjustmentPercent';\r\n const otherElem = this.bulkUpdateFormElement.nativeElement.querySelector(otherElemSelector + stateId + typeId);\r\n\r\n const existingCostAdjustmentUpdate = this.reportingAssetBulkUpdateModel.costAdjustmentUpdates && this.reportingAssetBulkUpdateModel.costAdjustmentUpdates.find(x => x.stateId === stateId && x.costAdjustmentTypeId === typeId);\r\n\r\n if (!existingCostAdjustmentUpdate) {\r\n return true;\r\n }\r\n\r\n if (existingCostAdjustmentUpdate.fieldAction !== Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo) {\r\n return true;\r\n }\r\n\r\n return (otherElem && otherElem.value && otherElem.value !== '0' && otherElem.value !== '');\r\n }\r\n\r\n updateCostAdjustmentAmount(stateId: number, typeId: number, event): void {\r\n const idx = this.reportingAssetBulkUpdateModel.costAdjustmentUpdates.findIndex(x => x.stateId === stateId && x.costAdjustmentTypeId === typeId);\r\n\r\n if (idx >= 0) {\r\n this.reportingAssetBulkUpdateModel.costAdjustmentUpdates[idx].adjustmentPercentage = null;\r\n this.reportingAssetBulkUpdateModel.costAdjustmentUpdates[idx].adjustmentAmount = parseFloat(event.target.value);\r\n this.validateForm();\r\n }\r\n }\r\n\r\n updateCostAdjustmentPercent(stateId: number, typeId: number, event): void {\r\n const idx = this.reportingAssetBulkUpdateModel.costAdjustmentUpdates.findIndex(x => x.stateId === stateId && x.costAdjustmentTypeId === typeId);\r\n\r\n if (idx >= 0) {\r\n this.reportingAssetBulkUpdateModel.costAdjustmentUpdates[idx].adjustmentAmount = null;\r\n this.reportingAssetBulkUpdateModel.costAdjustmentUpdates[idx].adjustmentPercentage = parseFloat(event.target.value) / 100;\r\n this.validateForm();\r\n }\r\n }\r\n\r\n onCostAdjustmentActionChange(action: Compliance.ReportingAssetBulkUpdateFieldActionEnum, stateId: number, costAdjustmentTypeId: number): void {\r\n const existingCostAdjustmentUpdate = this.reportingAssetBulkUpdateModel.costAdjustmentUpdates.find(x => x.stateId === stateId && x.costAdjustmentTypeId === costAdjustmentTypeId);\r\n\r\n if (!existingCostAdjustmentUpdate) {\r\n const newCostAdjustmentUpdate: Compliance.ReportingAssetBulkUpdateCostAdjustmentModel = {\r\n stateId: stateId,\r\n costAdjustmentTypeId: costAdjustmentTypeId,\r\n fieldAction: action\r\n };\r\n\r\n this.reportingAssetBulkUpdateModel.costAdjustmentUpdates.push(newCostAdjustmentUpdate);\r\n } else {\r\n existingCostAdjustmentUpdate.fieldAction = action;\r\n }\r\n }\r\n\r\n onSiteBlur(): void {\r\n if (this.siteFilter.trim() === '' || this._siteNoResult) {\r\n this.siteFilter = '';\r\n this.reportingAssetBulkUpdateModel.siteId = null;\r\n }\r\n\r\n this.siteFieldEdited = true;\r\n }\r\n\r\n onSiteLoadingChange(isLoading: boolean): void {\r\n this.siteIsLoading = isLoading;\r\n }\r\n\r\n onSiteSelected(match: TypeaheadMatch): void {\r\n this.reportingAssetBulkUpdateModel.siteId = (match.item as ExtendedSiteModel).model.siteID;\r\n this.siteFilter = match.value;\r\n }\r\n\r\n onVerificationDateChanged(verificationDate: AssetLienDate) {\r\n this.reportingAssetBulkUpdateModel.assetVerificationDate = verificationDate.date;\r\n }\r\n\r\n private initializeBulkUpdateModel() {\r\n this.reportingAssetBulkUpdateModel = { } as Compliance.ReportingAssetBulkUpdateModel;\r\n\r\n this.reportingAssetBulkUpdateModel.selectedRows = this.params.selection;\r\n this.reportingAssetBulkUpdateModel.lastModifiedTimestamp = this.params.assetListLastModifiedTimestamp;\r\n this.reportingAssetBulkUpdateModel.lienDate = this.params.lienDate.date;\r\n this.reportingAssetBulkUpdateModel.useStateLienDate = this.params.lienDate.useStateLienDate;\r\n this.reportingAssetBulkUpdateModel.lienDateType = this.params.lienDate.lienDateType;\r\n this.reportingAssetBulkUpdateModel.costAdjustmentUpdates = [];\r\n this.reportingAssetBulkUpdateModel.assetVerificationDate = this.params.lienDate.date;\r\n this.reportingAssetBulkUpdateModel.filterBySiteId = this.params.siteId;\r\n this.reportingAssetBulkUpdateModel.filterByParcelId = this.params.parcelId;\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._destroy$.next();\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', lrpId: number,\r\n canDismiss = true, hasProgressBar = true, warningMessage: string = null): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: lrpId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: hasProgressBar,\r\n canDismiss\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success) => {\r\n if (success) {\r\n let newRowData;\r\n try {\r\n newRowData = await lastValueFrom(this._assetRepository.getMultiple(this.params.lienDate.date, this.params.reportingAssetIds, true));\r\n\r\n if (warningMessage) {\r\n this._toastrService.warning(warningMessage);\r\n }\r\n } finally {\r\n await this._hideBusyIndicator();\r\n this.result = newRowData;\r\n this.isSaving = false;\r\n this._bsModalRef.hide();\r\n }\r\n } else {\r\n await this._hideBusyIndicator();\r\n this.isSaving = false;\r\n }\r\n });\r\n }\r\n\r\n private async _loadMetadata(): Promise {\r\n this.isLoading = true;\r\n\r\n try {\r\n // Make all requests in parallel\r\n const [ ownershipTypes, leaseTypes, assetVerificationReasons, glAccountResponse,\r\n assetDescriptorsResponse, bulkUpdateMetadata, costAdjustmentTypes ]:\r\n [ Compliance.AssetOwnershipTypeModel[], Compliance.LeaseTypeModel[], string[], Compliance.QueryResultModel,\r\n Compliance.CompanyAssetDescriptorMappingModel[], Compliance.ReportingAssetBulkUpdateSelectionMetadataModel, Compliance.CostAdjustmentTypeModel[] ] = await Promise.all([\r\n !this.ownershipTypes ? lastValueFrom(this._assetRepository.getOwnershipTypes()) : Promise.resolve(undefined),\r\n !this.leaseTypes ? lastValueFrom(this._assetRepository.getLeaseTypes()) : Promise.resolve(undefined),\r\n !this.assetVerificationReasons ? lastValueFrom(this._assetRepository.getVerificationReasons()) : Promise.resolve(undefined),\r\n lastValueFrom(this._glAccountRepository.getList(this.params.companyId, {} as Core.SearchModel)),\r\n lastValueFrom(this._companyAssetDescriptorRepository.getByCompanyId(this.params.companyId)),\r\n this._getBulkUpdateMetaData(),\r\n lastValueFrom(this._costAdjustmentRepository.getTypes())\r\n ]);\r\n\r\n //Asset Ownership Types\r\n if (!this.ownershipTypes) {\r\n this.ownershipTypes = ownershipTypes;\r\n }\r\n\r\n if (!this.leaseTypes) {\r\n this.leaseTypes = leaseTypes;\r\n }\r\n\r\n if (!this.assetVerificationReasons) {\r\n this.assetVerificationReasons = assetVerificationReasons;\r\n }\r\n\r\n // GL Accounts\r\n this._glAccounts = glAccountResponse.data\r\n .filter(x => x.accountType === Compliance.GLAccountTypeEnum.Asset)\r\n .map(i => new ExtendedGLAccountModel(i, this._keyValueDisplayPipe));\r\n\r\n // Asset Descriptors\r\n this.assetDescriptors = assetDescriptorsResponse.filter(x => x.descriptor.category !== Core.DescriptorCategoryEnum.AssetCost && x.descriptor.category !== Core.DescriptorCategoryEnum.AssetAquisitionDate);\r\n this.costAssetDescriptors = assetDescriptorsResponse.filter(x => x.descriptor.category == Core.DescriptorCategoryEnum.AssetCost);\r\n this.acqDateAssetDescriptors = assetDescriptorsResponse.filter(x => x.descriptor.category == Core.DescriptorCategoryEnum.AssetAquisitionDate);\r\n\r\n // Bulk Update Metadata\r\n this.costAdjustmentTypes = costAdjustmentTypes;\r\n\r\n this.bulkUpdateMetadata.states.forEach(state => {\r\n const filteredTypes = this.costAdjustmentTypes.filter(x => x.states.find(y => y.stateId == state.stateID));\r\n\r\n const bulkUpdateStateCostAdjustment = {\r\n state: state.fullName,\r\n stateId: state.stateID,\r\n costAdjustments: filteredTypes.map(cat => ({\r\n costAdjustmentTypeId: cat.costAdjustmentTypeId,\r\n costAdjustment: cat.typeName,\r\n sequence: _.find(cat.states, x => x.stateId === state.stateID).sequence\r\n } as BulkUpdateCostAdjustment)).sort((a, b) => a.sequence - b.sequence),\r\n customHelpRenderer: {\r\n component: CostAdjustmentHelpComponent,\r\n canHover: true,\r\n hasIcon: true\r\n } as HelpContentComponentConfig\r\n } as BulkUpdateStateCostAdjustment;\r\n\r\n\r\n const flattenedTypes: FlattenedCostAdjustmentSource[] = filteredTypes.map(type => {\r\n const typeState = _.find(type.states, x => x.stateId === bulkUpdateStateCostAdjustment.stateId);\r\n return {\r\n typeName: type.typeName,\r\n costAdjustmentTypeId: type.costAdjustmentTypeId,\r\n applyToSource: typeState.applyToSource,\r\n sequence: typeState.sequence,\r\n states: []\r\n };\r\n });\r\n\r\n const sequencedCostAdjustments = flattenedTypes.sort((a, b) => a.sequence - b.sequence);\r\n bulkUpdateStateCostAdjustment.extendedCostAdjustmentTypes = sequencedCostAdjustments;\r\n bulkUpdateStateCostAdjustment.customHelpRenderer.componentParams = { value: sequencedCostAdjustments };\r\n\r\n this.stateCostAdjustments.push(bulkUpdateStateCostAdjustment);\r\n });\r\n\r\n this.isCreateNewSplitAllowed = this.bulkUpdateMetadata.isCreateSplitEnabled;\r\n this.isUpdateSplitAllowed = this.bulkUpdateMetadata.isUpdateSplitEnabled;\r\n\r\n this.perpetualAllowedAssetsCount = this.bulkUpdateMetadata.perpetualAllowedAssetsCount;\r\n this.siteIds = this.bulkUpdateMetadata.siteIds;\r\n this.displayPerpetualTooltip = this.perpetualAllowedAssetsCount < this.params.selectedCount;\r\n\r\n if(!this.displayPerpetualTooltip) {\r\n this.perpetualHelpContentId = 'asset-bulk-update.isPerpetual-none';\r\n }\r\n else if (this.perpetualAllowedAssetsCount > 0) {\r\n const helpContent = _.find(ASSET_BULK_UPDATE_HELP, x => x.helpContentId == 'asset-bulk-update.isPerpetual');\r\n helpContent.tooltipText = `Only ${this.perpetualAllowedAssetsCount} of the ${this.params.selectedCount} selected assets have classifications which allow perpetual assets. This field will only be updated for those assets.`;\r\n\r\n this.perpetualHelpContentId = 'asset-bulk-update.isPerpetual';\r\n\r\n } else {\r\n const helpContent = _.find(ASSET_BULK_UPDATE_HELP, x => x.helpContentId == 'asset-bulk-update.isPerpetual');\r\n helpContent.tooltipText = 'This field cannot be updated because the selected records do not have asset classifications which allow perpetual assets.';\r\n\r\n this.perpetualHelpContentId = 'asset-bulk-update.isPerpetual';\r\n }\r\n } finally {\r\n this.isLoading = false;\r\n this._focusOnFormElement(this.params.hotkeyFocus);\r\n }\r\n }\r\n\r\n private _getBulkUpdateMetaData(): Promise {\r\n const params: Compliance.ReportingAssetBulkUpdateMetadataModel = {\r\n lienDate: this.params.lienDate.date,\r\n lienDateType: this.params.lienDate.lienDateType,\r\n useStateLienDate: this.params.lienDate.useStateLienDate,\r\n selectedRows: this.params.selection,\r\n filterBySiteId: this.params.siteId,\r\n filterByParcelId: this.params.parcelId\r\n };\r\n\r\n return lastValueFrom(this._assetRepository.getBulkUpdateMetadata(this.params.companyId, params))\r\n .then(bulkUpdateMetadata => {\r\n this.bulkUpdateMetadata = bulkUpdateMetadata;\r\n this.isBulkMetadataLoaded = true;\r\n return bulkUpdateMetadata;\r\n });\r\n }\r\n\r\n private _filterGlAccounts(filter: string): Observable {\r\n return observableOf(\r\n (this._glAccounts || []).filter(i => i.displayName.toLowerCase().includes(filter.toLowerCase()))\r\n );\r\n }\r\n\r\n private _filterSites(filter: string): Observable {\r\n const searchModel: Core.SiteSearchModel = {\r\n excludeFromInactiveCompany: true,\r\n pagination: {\r\n skip: 0,\r\n take: 100\r\n },\r\n columnFilters: [\r\n {\r\n filterProperty: Core.SitePropertyEnum.SiteNameOrNumber,\r\n filterValues: [\r\n {\r\n filterType: Core.FilterTypeEnum.Contains,\r\n filterValue: filter\r\n }\r\n ]\r\n }\r\n ]\r\n };\r\n\r\n return observableFrom(lastValueFrom(this._siteService.searchSites(this.params.companyId, searchModel))).pipe(\r\n map((sites) => sites.map(site => new ExtendedSiteModel(site, this._keyValueDisplayPipe))));\r\n }\r\n\r\n private _focusOnFormElement(focus: string, firstInit?: boolean): void {\r\n if (!focus || this._closed) { return; }\r\n let target;\r\n switch (focus) {\r\n case 'r':\r\n this.reportingAssetBulkUpdateModel.classificationIdAction = Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo;\r\n target = '#selectAssetClass';\r\n break;\r\n }\r\n const element = target && this._renderer.selectRootElement(target);\r\n if (element) {\r\n this._timerService.setTimeout(() => {\r\n if (document.activeElement !== element && firstInit) {\r\n element.disabled = false;\r\n element.focus();\r\n element.scrollIntoView({ behavior: 'smooth', block: 'center' });\r\n } else if (document.activeElement === element) {\r\n element.scrollIntoView({behavior: 'auto', block: 'center'});\r\n }\r\n }, 0);\r\n }\r\n }\r\n\r\n private async _bulkUpdate(force: boolean = false, overrideAllFields: boolean = false): Promise {\r\n\r\n let warning: string = null;\r\n\r\n if (this.bulkUpdateMetadata.hasLockedAssets &&\r\n (this.reportingAssetBulkUpdateModel.isLockedAction !== Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo ||\r\n !this.reportingAssetBulkUpdateModel.isLocked)) {\r\n warning = 'Your selection contains locked assets. These assets were not updated.';\r\n }\r\n\r\n this._showBusyIndicator('Bulk update', 'Updating assets', null, false, false, warning);\r\n\r\n let confirmMessage: string = '';\r\n\r\n try {\r\n this.reportingAssetBulkUpdateModel.force = force;\r\n this.reportingAssetBulkUpdateModel.overrideAllFields = overrideAllFields;\r\n\r\n if (this.reportingAssetBulkUpdateModel.isLockedAction !== Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo ||\r\n this.reportingAssetBulkUpdateModel.isLockedAction === Compliance.ReportingAssetBulkUpdateFieldActionEnum.ChangeTo &&\r\n this.reportingAssetBulkUpdateModel.isLocked) {\r\n this.reportingAssetBulkUpdateModel.isLockedRemoveOverridesAction = undefined;\r\n this.reportingAssetBulkUpdateModel.isLockedRemoveOverrides = undefined;\r\n }\r\n\r\n const longRunningProcessId = await lastValueFrom(this._assetRepository\r\n .startBulkUpdate(this.params.companyId, this.reportingAssetBulkUpdateModel));\r\n\r\n await this._busyRef.setLongRunningProcessId(longRunningProcessId);\r\n } catch (e2) {\r\n await this._hideBusyIndicator();\r\n\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n confirmMessage = e2.error.message;\r\n }\r\n\r\n if (confirmMessage) {\r\n try {\r\n await this._messageModalService.confirm(confirmMessage, 'Confirm Update');\r\n } catch (e3) {\r\n return Promise.resolve();\r\n }\r\n\r\n // force\r\n await this._bulkUpdate(true, overrideAllFields);\r\n }\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\n\r\nexport interface StateIcon {\r\n selector: Compliance.AssetChangeStatusEnum;\r\n iconClass: string;\r\n active: boolean;\r\n tooltipTitle: string;\r\n}\r\n\r\n@Component({\r\n selector: 'asset-change-icon',\r\n styleUrls: ['./assetChangeIcon.component.scss'],\r\n template: `\r\n
\r\n
    \r\n
  • \r\n \r\n
  • \r\n
\r\n
\r\n `\r\n})\r\nexport class AssetChangeIconComponent {\r\n @Input()\r\n set icons(icons: StateIcon[]) {\r\n this.activeIcons = icons.filter(i => i.active);\r\n }\r\n\r\n activeIcons: StateIcon[] = [];\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { StateIcon } from './Asset-Change-Icon/assetChangeIcon.component';\r\nimport { AssetSummary } from '../Models/assetSummary';\r\n\r\n@Component({\r\n selector: 'asset-change-icon-cell',\r\n template: '-'\r\n})\r\nexport class AssetChangeIconCellRendererComponent implements ICellRendererAngularComp {\r\n changeStatus: Compliance.AssetChangeStatusEnum[];\r\n params: ICellRendererParams;\r\n isTotalsRow: boolean = false;\r\n\r\n icons: StateIcon[] = [\r\n {\r\n selector: null,\r\n iconClass: 'fa-circle-thin',\r\n active: false,\r\n tooltipTitle: 'Not changed'\r\n },\r\n {\r\n selector: Compliance.AssetChangeStatusEnum.NewAddition,\r\n iconClass: 'fa-plus',\r\n active: false,\r\n tooltipTitle: 'Added'\r\n },\r\n {\r\n selector: Compliance.AssetChangeStatusEnum.Disposed,\r\n iconClass: 'fa-trash',\r\n active: false,\r\n tooltipTitle: 'Disposed'\r\n },\r\n {\r\n selector: Compliance.AssetChangeStatusEnum.PotentiallyDisposed,\r\n iconClass: 'fa-trash-o',\r\n active: false,\r\n tooltipTitle: 'Potentially disposed'\r\n },\r\n {\r\n selector: Compliance.AssetChangeStatusEnum.Changed,\r\n iconClass: 'fa-pencil',\r\n active: false,\r\n tooltipTitle: 'Changed'\r\n }\r\n ];\r\n\r\n agInit(params: ICellRendererParams): void {\r\n const summary = params.data as AssetSummary;\r\n this.params = params;\r\n\r\n this.changeStatus = (summary && summary['changeStatus']) ? summary.changeStatus : null;\r\n\r\n if (this.changeStatus && this.changeStatus.length) {\r\n this.icons.forEach(i => i.active = this.changeStatus.includes(i.selector));\r\n } else if(!summary) {\r\n this.isTotalsRow = true;\r\n } else {\r\n this.icons[0].active = true;\r\n }\r\n this.isTotalsRow = summary && (summary['totalsRow'] || summary['selectedTotalsRow']);\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Injectable, OnDestroy } from '@angular/core';\r\nimport { EventManager } from '@angular/platform-browser';\r\nimport { Observable, Subject } from 'rxjs';\r\n\r\nexport interface HotkeyParams {\r\n element?: any;\r\n keys?: string;\r\n}\r\n\r\nexport interface Hotkey {\r\n element: any;\r\n keys: string;\r\n listen: Observable;\r\n destroy: () => void;\r\n}\r\n\r\n/**\r\n * HotKeys Service\r\n *\r\n * Intended to be an instance service provided on a component level to\r\n * Kills event listeners on component destruction\r\n * This means you do not need to worry about unsubscribing from key events created in this service\r\n */\r\n@Injectable()\r\nexport class HotkeyService implements OnDestroy {\r\n constructor(private readonly _eventManager: EventManager) { }\r\n\r\n private _lib: Hotkey[] = [];\r\n private _default: HotkeyParams = {\r\n element: document\r\n };\r\n\r\n ngOnDestroy(): void {\r\n this._lib.forEach(hotkey => hotkey.destroy());\r\n }\r\n\r\n add(options: HotkeyParams): Observable {\r\n const merged = { ...this._default, ...options };\r\n const event = `keydown.${merged.keys}`;\r\n\r\n const subject = new Subject();\r\n\r\n const handler = (e: KeyboardEvent) => {\r\n e.preventDefault();\r\n subject.next(e);\r\n };\r\n\r\n const dispose = this._eventManager.addEventListener(\r\n merged.element, event, handler\r\n );\r\n\r\n const hotkey = {\r\n element: merged.element,\r\n keys: merged.keys,\r\n listen: subject.asObservable(),\r\n destroy: () => {\r\n subject.complete();\r\n dispose();\r\n }\r\n };\r\n\r\n this._lib.push(hotkey);\r\n\r\n return hotkey.listen;\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\nexport interface DeleteConfirmationComponentParams {\r\n item: string;\r\n message?: string;\r\n url?: string;\r\n}\r\n\r\n@Component({\r\n selector: 'delete-confirmation-component',\r\n template: `\r\n \r\n \r\n

{{message}}

\r\n
\r\n `\r\n})\r\nexport class DeleteConfirmationComponent implements OnInit {\r\n constructor(\r\n private readonly _http: HttpClient,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _toastr: ToastrService\r\n ) { }\r\n\r\n params: DeleteConfirmationComponentParams;\r\n result: boolean;\r\n\r\n item: string;\r\n message: string;\r\n url: string;\r\n deleting: boolean;\r\n\r\n ngOnInit(): void {\r\n this.item = this.params.item;\r\n this.message = this.params.message;\r\n this.url = this.params.url;\r\n }\r\n\r\n async delete(): Promise {\r\n if (this.url) {\r\n this.deleting = true;\r\n try {\r\n await lastValueFrom(this._http.delete(this.url));\r\n this.result = true;\r\n } catch (err) {\r\n const errorMessage = err && err.error && err.error.message ? err.error.message : '';\r\n this._toastr.error(errorMessage, 'Error!');\r\n }\r\n } else {\r\n this.result = true;\r\n }\r\n this.cancel();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { AgGridPersistenceService } from '../agGridPersistence.service';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\nexport interface AgGridTextWithTotalsUpdateCellRendererParams extends ICellRendererParams {\r\n getTooltipText: (params: AgGridTextWithTotalsUpdateCellRendererParams) => string;\r\n totalsNeedRefresh: () => boolean;\r\n onUpdateTotalsClicked: () => void;\r\n}\r\n\r\n@Component({\r\n selector: 'ag-grid-text-with-selected-row-cell-renderer',\r\n template: `\r\n
\r\n {{cellText}}\r\n
\r\n
\r\n \r\n Calculate Totals\r\n
\r\n `,\r\n styles: [\r\n '#autoUpdate { margin: 0 3px }',\r\n 'label { font-weight: normal }'\r\n ]\r\n})\r\nexport class AgGridTextWithTotalsUpdateCellRendererComponent implements ICellRendererAngularComp {\r\n constructor(private _agGridPersistenceService: AgGridPersistenceService) {}\r\n\r\n params: AgGridTextWithTotalsUpdateCellRendererParams;\r\n tooltipText: string;\r\n cellText: string;\r\n isTotalsRow: boolean;\r\n autoUpdateChecked: boolean;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n get totalsNeedRefresh(): boolean {\r\n return !this.autoUpdateChecked && this.params.totalsNeedRefresh();\r\n }\r\n\r\n agInit(params: AgGridTextWithTotalsUpdateCellRendererParams): void {\r\n this.params = params;\r\n this.tooltipText = params.getTooltipText(params);\r\n this.cellText = params.valueFormatted || params.value;\r\n this.isTotalsRow = this.cellText === 'TOTAL';\r\n\r\n this._agGridPersistenceService.totalsRowAutomaticUpdate$(this.params.context.gridId)\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(autoUpdate => {\r\n this.autoUpdateChecked = autoUpdate;\r\n });\r\n }\r\n\r\n onAutomaticUpdatesClicked(checked: boolean): void {\r\n this._agGridPersistenceService.toggleTotalsRowAutomaticUpdate(this.params.context.gridId, checked);\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AssetImportProgressService } from './assetImportProgress.service';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\n\r\nexport interface AssetImportProgressParams {\r\n assetImportProgressService: AssetImportProgressService\r\n}\r\n\r\n@Component({\r\n selector: 'asset-import-progress',\r\n templateUrl: './assetImportProgress.component.html',\r\n styleUrls: ['./assetImportProgress.component.scss']\r\n})\r\nexport class AssetImportProgressComponent implements OnInit, OnDestroy, IWeissmanModalComponent{\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: AssetImportProgressParams;\r\n result: void;\r\n\r\n activeImportSelectedRowsCount: number;\r\n activeImportProcessedRowsCount: number;\r\n activeImportTimeRemaining: string;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this.params.assetImportProgressService.importStarted$.pipe(takeUntil(this._destroy$))\r\n .subscribe(async x => {\r\n if (!x){\r\n return;\r\n }\r\n\r\n this.activeImportSelectedRowsCount = x.selectedRowsCount || this.activeImportSelectedRowsCount;\r\n });\r\n\r\n this.params.assetImportProgressService.importFinished$.pipe(takeUntil(this._destroy$))\r\n .subscribe(() => this.close());\r\n\r\n this.params.assetImportProgressService.processedRows$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.activeImportProcessedRowsCount = x);\r\n\r\n this.params.assetImportProgressService.timeRemaining$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.activeImportTimeRemaining = x);\r\n\r\n this.params.assetImportProgressService.selectedRowsCountLoaded$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.activeImportSelectedRowsCount = this.activeImportSelectedRowsCount || x);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n close(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n get progressPercentage(): number {\r\n return Math.round(this.activeImportProcessedRowsCount / this.activeImportSelectedRowsCount * 100);\r\n }\r\n}\r\n","\r\n
\r\n
The system is still importing assets.
\r\n
Progress
\r\n
\r\n
\r\n
\r\n
\r\n {{progressPercentage}}% Done\r\n Time Remaining: {{activeImportTimeRemaining}}\r\n
\r\n
\r\n\r\n","import { BehaviorSubject, lastValueFrom, Observable, Subject, Subscription } from 'rxjs';\r\nimport { WebsocketListenerService } from '../../../websocketListener.service';\r\nimport Timeout = NodeJS.Timeout;\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport { Injectable, OnDestroy } from '@angular/core';\r\nimport { EntityImportRepository } from '../../../Repositories';\r\n\r\nexport interface ActiveImportInfo {\r\n longRunningProcessId: number;\r\n selectedRowsCount: number;\r\n}\r\n\r\n@Injectable()\r\nexport class AssetImportProgressService implements OnDestroy{\r\n\r\n constructor(\r\n private readonly _websocketListenerService: WebsocketListenerService,\r\n private readonly _entityImportRepository: EntityImportRepository\r\n ) {\r\n console.log('AssetImportProgressService created');\r\n }\r\n private _companyId: number;\r\n private _assetImportInProgressMetadata: Compliance.AssetImportInProgressMetadataModel;\r\n private _progressIntervalId: Timeout;\r\n private _timeRemainingIntervalId: Timeout;\r\n private _importStartedSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _importFinishedSubject: Subject = new Subject();\r\n private _selectedRowsCountLoadedSubject: BehaviorSubject = new BehaviorSubject(0);\r\n private _processedRowsSubject: BehaviorSubject = new BehaviorSubject(0);\r\n private _timeRemainingSubject: BehaviorSubject = new BehaviorSubject('');\r\n private _reconnectedSub: Subscription;\r\n private _statusChangedSub: Subscription;\r\n private _progressChangedSub: Subscription;\r\n private _selectedRowsCount: number = 0;\r\n private _processedRowsCount: number = 0;\r\n private _loadingAssetImportInProgressMetadata: boolean = false;\r\n\r\n get importStarted$(): Observable {\r\n return this._importStartedSubject.asObservable();\r\n }\r\n\r\n get importFinished$(): Observable {\r\n return this._importFinishedSubject.asObservable();\r\n }\r\n\r\n get processedRows$(): Observable {\r\n return this._processedRowsSubject.asObservable();\r\n }\r\n\r\n get timeRemaining$(): Observable {\r\n return this._timeRemainingSubject.asObservable();\r\n }\r\n\r\n get selectedRowsCountLoaded$(): Observable {\r\n return this._selectedRowsCountLoadedSubject.asObservable();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n console.log('AssetImportProgressService destroyed');\r\n this._reconnectedSub && this._reconnectedSub.unsubscribe();\r\n this._statusChangedSub && this._statusChangedSub.unsubscribe();\r\n this._progressChangedSub && this._progressChangedSub.unsubscribe();\r\n }\r\n\r\n async initialize(companyId: number): Promise {\r\n this._companyId = companyId;\r\n\r\n await this._loadAssetImportInProgress();\r\n\r\n this._reconnectedSub = this._websocketListenerService.longRunningProcessReconnected$\r\n .subscribe(async () => await this._loadAssetImportInProgress());\r\n\r\n this._statusChangedSub = this._websocketListenerService.longRunningProcessStatusChange$\r\n .subscribe(async (x) => {\r\n if (x.processType === LongRunningProcessTypeEnum.ImportFile && x.operationName === 'Transfer') {\r\n console.log('LRP (OnStatusChanged)', x);\r\n\r\n if (this._assetImportInProgressMetadata && this._assetImportInProgressMetadata.longRunningProcessId === x.longRunningProcessId) {\r\n if (x.isCompleted || x.isCanceled || x.isError) {\r\n this._importFinishedSubject.next(this._assetImportInProgressMetadata.longRunningProcessId);\r\n\r\n this._processedRowsSubject.next(0);\r\n this._timeRemainingSubject.next('');\r\n this._selectedRowsCountLoadedSubject.next(0);\r\n this._importStartedSubject.next(null);\r\n\r\n this._assetImportInProgressMetadata = null;\r\n this._processedRowsCount = 0;\r\n this._selectedRowsCount = 0;\r\n\r\n if (this._progressIntervalId) {\r\n clearInterval(this._progressIntervalId);\r\n this._progressIntervalId = null;\r\n }\r\n\r\n if (this._timeRemainingIntervalId) {\r\n clearInterval(this._timeRemainingIntervalId);\r\n this._timeRemainingIntervalId = null;\r\n }\r\n\r\n console.log('Removing LRP', x.longRunningProcessId);\r\n }\r\n } else {\r\n if (x.isCompleted || x.isCanceled || x.isError || this._loadingAssetImportInProgressMetadata) {\r\n return;\r\n }\r\n\r\n this._loadingAssetImportInProgressMetadata = true;\r\n try {\r\n const assetImportInProgressMetadata = await lastValueFrom(this._entityImportRepository.getAssetImportInProgressMetadataByLongRunningProcessId(x.longRunningProcessId));\r\n\r\n if (assetImportInProgressMetadata && assetImportInProgressMetadata.companyId === this._companyId && !this._assetImportInProgressMetadata) {\r\n this._assetImportInProgressMetadata = assetImportInProgressMetadata;\r\n this._initializeAssetImportProgress();\r\n\r\n console.log('Adding LRP (OnStatusChanged)', this._assetImportInProgressMetadata.longRunningProcessId);\r\n }\r\n } finally {\r\n this._loadingAssetImportInProgressMetadata = false;\r\n }\r\n }\r\n }\r\n });\r\n\r\n this._progressChangedSub = this._websocketListenerService.longRunningProcessProgressChange$\r\n .subscribe(async (progress) => {\r\n if (progress.processType === LongRunningProcessTypeEnum.ImportFile && progress.operationName === 'Transfer') {\r\n if (!this._assetImportInProgressMetadata || this._assetImportInProgressMetadata.longRunningProcessId !== progress.longRunningProcessId) {\r\n\r\n if (!this._loadingAssetImportInProgressMetadata) {\r\n this._loadingAssetImportInProgressMetadata = true;\r\n\r\n try {\r\n const assetImportInProgressMetadata = await lastValueFrom(this._entityImportRepository.getAssetImportInProgressMetadataByLongRunningProcessId(progress.longRunningProcessId));\r\n\r\n if (assetImportInProgressMetadata && assetImportInProgressMetadata.companyId === this._companyId && !this._assetImportInProgressMetadata) {\r\n this._assetImportInProgressMetadata = assetImportInProgressMetadata;\r\n this._initializeAssetImportProgress();\r\n\r\n console.log('Adding LRP (OnProgressChanged)', this._assetImportInProgressMetadata.longRunningProcessId);\r\n }\r\n } finally {\r\n this._loadingAssetImportInProgressMetadata = false;\r\n }\r\n }\r\n } else if (this._assetImportInProgressMetadata.longRunningProcessId === progress.longRunningProcessId &&\r\n !this._selectedRowsCount) {\r\n this._selectedRowsCount = progress.total;\r\n\r\n this._selectedRowsCountLoadedSubject.next(this._selectedRowsCount);\r\n console.log('Setting initial value for importRowsSelected', this._selectedRowsCount);\r\n }\r\n }\r\n });\r\n }\r\n\r\n private async _loadAssetImportInProgress(): Promise {\r\n if (this._loadingAssetImportInProgressMetadata) {\r\n return;\r\n }\r\n\r\n this._loadingAssetImportInProgressMetadata = true;\r\n\r\n try {\r\n this._assetImportInProgressMetadata = await lastValueFrom(this._entityImportRepository.getAssetImportInProgressMetadataByCompanyId(this._companyId));\r\n\r\n console.log('this._assetImportInProgressMetadata', this._assetImportInProgressMetadata);\r\n\r\n if (this._assetImportInProgressMetadata) {\r\n this._initializeAssetImportProgress();\r\n\r\n console.log('Adding LRP (LoadAssetImportInProgress)', this._assetImportInProgressMetadata.longRunningProcessId);\r\n }\r\n } finally {\r\n this._loadingAssetImportInProgressMetadata = false;\r\n }\r\n }\r\n\r\n private _initializeAssetImportProgress() {\r\n this._processedRowsCount = this._assetImportInProgressMetadata.transferredRowsCount;\r\n this._selectedRowsCount = this._assetImportInProgressMetadata.selectedRowsCount;\r\n\r\n const activeImportInfo: ActiveImportInfo = {\r\n longRunningProcessId: this._assetImportInProgressMetadata.longRunningProcessId,\r\n selectedRowsCount: this._selectedRowsCount\r\n };\r\n this._importStartedSubject.next(activeImportInfo);\r\n\r\n this._progressIntervalId = setInterval(() => {\r\n if (this._assetImportInProgressMetadata && this._processedRowsCount < this._selectedRowsCount) {\r\n this._processedRowsCount++;\r\n this._processedRowsSubject.next(this._processedRowsCount);\r\n }\r\n }, this._assetImportInProgressMetadata.millisecondsPerRow);\r\n\r\n this._timeRemainingIntervalId = setInterval(() => {\r\n let result = '';\r\n\r\n if (this._assetImportInProgressMetadata) {\r\n const rowsToProcess = this._selectedRowsCount - this._processedRowsCount;\r\n const timeToProcess = rowsToProcess * this._assetImportInProgressMetadata.millisecondsPerRow;\r\n\r\n let seconds = Math.round(timeToProcess / 1000);\r\n const hours = Math.floor(seconds / 3600);\r\n seconds = seconds % 3600;\r\n const minutes = Math.floor(seconds / 60);\r\n seconds = seconds % 60;\r\n\r\n result = `${minutes.toString().padStart(2, '0')}:${seconds.toString().padStart(2, '0')}`;\r\n\r\n if (hours) {\r\n result = `${hours.toString().padStart(2, '0')}:${result}`;\r\n }\r\n }\r\n\r\n this._timeRemainingSubject.next(result);\r\n }, 1000);\r\n }\r\n}\r\n","import { Component, Input, OnChanges, OnDestroy, OnInit, SimpleChanges } from '@angular/core';\r\nimport { Subscription } from 'rxjs';\r\nimport { AgGridPersistenceService } from '../../../agGridPersistence.service';\r\n\r\n@Component({\r\n selector: 'ag-grid-current-layout-applied',\r\n template: '
Layout: {{layoutName}}
'\r\n})\r\nexport class AgGridCurrentLayoutAppliedComponent implements OnInit, OnDestroy, OnChanges {\r\n constructor(private readonly _agGridPersistenceService: AgGridPersistenceService) {}\r\n\r\n @Input() gridId: System.Guid | string;\r\n\r\n layoutName: string;\r\n\r\n private _sub: Subscription;\r\n\r\n ngOnInit(): void {\r\n this._sub = this._agGridPersistenceService.currentGridLayoutApplied$(this.gridId as string)\r\n .subscribe(layoutName => this.layoutName = layoutName);\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges) {\r\n if (changes.gridId && !changes.gridId.firstChange) {\r\n this._sub.unsubscribe();\r\n this._sub = this._agGridPersistenceService.currentGridLayoutApplied$(this.gridId as string)\r\n .subscribe(layoutName => this.layoutName = layoutName);\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._sub.unsubscribe();\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const ASSET_ADVANCED_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'asset-advanced.header',\r\n tooltipText: 'Advanced'\r\n }\r\n];\r\n","\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { UntypedFormControl, UntypedFormGroup, ValidatorFn, ValidationErrors } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AssetPropertyInfo } from '../../Models/assetPropertyMap';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { ASSET_ADVANCED_HELP } from '../Asset-Advanced/assetAdvanced.component.help';\r\nimport { AssetRepository } from '../../../Repositories';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nexport enum AdvancedFormElements {\r\n AllAssets = 'allAssetsAtLienDate',\r\n AnyChanged = 'anyField',\r\n AnyImpactful = 'includeAnyReturnImpactfulFieldChange',\r\n Changed = 'includeChanged',\r\n Disposed = 'disposed',\r\n DisposedLien = 'includeDisposedSinceLastLienDate',\r\n DisposedPeriod = 'includeDisposed',\r\n FieldChanged = 'fieldChangedColumns',\r\n NewAddition = 'includeNewAddition',\r\n NotChanged = 'includeNotChanged',\r\n PotentiallyDisposed = 'includePotentiallyDisposed',\r\n SpecificField = 'specificField',\r\n Transferred = 'includeTransferred'\r\n}\r\n\r\nexport interface DynamicFormControls {\r\n [key: string]: UntypedFormControl;\r\n}\r\n\r\nexport interface CheckboxSubSelect {\r\n formControlName: AdvancedFormElements;\r\n formControl: UntypedFormControl;\r\n isOutputControl: boolean;\r\n options: AssetPropertyInfo[];\r\n}\r\n\r\nexport interface FilterCheckbox {\r\n name: string;\r\n formControl: UntypedFormControl,\r\n formControlName: AdvancedFormElements;\r\n isOutputControl: boolean;\r\n children?: FilterCheckbox[];\r\n additionalSelect?: CheckboxSubSelect;\r\n}\r\n\r\nexport interface AssetAdvancedDetailsParams {\r\n selectOptions: Compliance.NameValuePair[];\r\n selectControl: UntypedFormControl;\r\n fieldSelectOptions: AssetPropertyInfo[];\r\n}\r\n\r\n@Component({\r\n selector: 'asset-advanced-filter',\r\n templateUrl: './assetAdvancedDetails.component.html'\r\n})\r\nexport class AssetAdvancedDetailsComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _assetRepository: AssetRepository,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _helpService: HelpService\r\n ) { }\r\n\r\n fieldSelect: CheckboxSubSelect = {\r\n formControlName: AdvancedFormElements.FieldChanged,\r\n formControl: new UntypedFormControl({ value: [], disabled: true }),\r\n isOutputControl: true,\r\n options: []\r\n };\r\n\r\n assetFilters: FilterCheckbox[] = [\r\n {\r\n name: 'All assets at lien date',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.AllAssets,\r\n isOutputControl: true,\r\n children: [\r\n {\r\n name: 'Changed',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.Changed,\r\n isOutputControl: true,\r\n children: [\r\n {\r\n name: 'Any return-impactful field change (excluding transfers)',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.AnyImpactful,\r\n isOutputControl: true\r\n },\r\n {\r\n name: 'Field change',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.SpecificField,\r\n additionalSelect: this.fieldSelect,\r\n isOutputControl: false\r\n },\r\n {\r\n name: 'Transferred (site change)',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.Transferred,\r\n isOutputControl: true\r\n }\r\n ]\r\n },\r\n {\r\n name: 'New Addition',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.NewAddition,\r\n isOutputControl: true\r\n },\r\n {\r\n name: 'Not Changed',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.NotChanged,\r\n isOutputControl: true\r\n },\r\n {\r\n name: 'Potentially disposed',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.PotentiallyDisposed,\r\n isOutputControl: true\r\n }\r\n ]\r\n },\r\n {\r\n name: 'Disposed assets',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.Disposed,\r\n isOutputControl: false,\r\n children: [\r\n {\r\n name: 'Disposed. Period.',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.DisposedPeriod,\r\n isOutputControl: true\r\n },\r\n {\r\n name: 'Disposed since comparison date',\r\n formControl: new UntypedFormControl(false),\r\n formControlName: AdvancedFormElements.DisposedLien,\r\n isOutputControl: true\r\n }\r\n ]\r\n }\r\n ];\r\n\r\n params: AssetAdvancedDetailsParams;\r\n result: Compliance.AdvancedAssetFilters;\r\n\r\n selectOptions: Compliance.NameValuePair[];\r\n selectedOption: UntypedFormControl;\r\n advancedFilterForm: UntypedFormGroup;\r\n helperFormGroup: UntypedFormGroup;\r\n disableSubmit: boolean = false;\r\n\r\n lienDate: Date;\r\n comparisonLienDate: Date;\r\n comparisonLienDateTypeOption: UntypedFormControl;\r\n comparisonLienDateDisabled: boolean = true;\r\n\r\n\r\n comparisonLienDateTypeOptions: Compliance.NameValuePair[] = [\r\n {\r\n name: 'Lien Date One Year Ago', value: Compliance.ComparisonLienDateTypeEnum.OneYearAgo\r\n },\r\n {\r\n name: 'Nearest prior lien date', value: Compliance.ComparisonLienDateTypeEnum.NearestPriorLienDate\r\n },\r\n {\r\n name: 'Custom', value: Compliance.ComparisonLienDateTypeEnum.Custom\r\n }\r\n ];\r\n\r\n private _destroy$: Subject = new Subject();\r\n private _dropdownOnOpen: Compliance.NameValuePair;\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(ASSET_ADVANCED_HELP);\r\n // set select options\r\n this.selectOptions = this.params.selectOptions;\r\n this.selectedOption = this.params.selectControl;\r\n this._dropdownOnOpen = this.selectedOption.value;\r\n this.fieldSelect.options = this.params.fieldSelectOptions;\r\n\r\n this.lienDate = this._assetRepository.getLienDateUserSetting();\r\n\r\n let comparisonLienDateType: Compliance.ComparisonLienDateTypeEnum;\r\n\r\n comparisonLienDateType = this._assetRepository.getComparisonDateTypeUserSetting();\r\n\r\n this.comparisonLienDate = this._assetRepository.getComparisonDateUserSetting();\r\n\r\n if (!comparisonLienDateType) {\r\n comparisonLienDateType = Compliance.ComparisonLienDateTypeEnum.OneYearAgo;\r\n }\r\n\r\n this.comparisonLienDateTypeOption = new UntypedFormControl(_.find(this.comparisonLienDateTypeOptions, { value: comparisonLienDateType }));\r\n\r\n if (comparisonLienDateType === Compliance.ComparisonLienDateTypeEnum.Custom) {\r\n this.comparisonLienDateDisabled = false;\r\n }\r\n\r\n // build form\r\n this._buildForm();\r\n this.applyFromDropdown();\r\n this._registerFormListeners();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n /**\r\n * Save the form values\r\n */\r\n save(): void {\r\n this.result = this._createOutputModel();\r\n\r\n if (_.isEqual(this.result, this._dropdownOnOpen.value)) {\r\n this.result = null;\r\n this.cancel();\r\n return;\r\n }\r\n\r\n this._assetRepository.updateComparisonDateUserSetting(this.result.comparisonLienDate);\r\n this._assetRepository.updateComparisonDateTypeUserSetting(this.result.comparisonLienDateType);\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n /**\r\n * Cancel and reset to initial state\r\n */\r\n cancel(): void {\r\n this.selectedOption.setValue(this._dropdownOnOpen);\r\n this.applyFromDropdown();\r\n this._bsModalRef.hide();\r\n }\r\n\r\n /**\r\n * Apply from the initial set value or from quick list select\r\n */\r\n applyFromDropdown(): void {\r\n const formValue = this.selectedOption.value;\r\n const filter = { ...formValue.value };\r\n filter.fieldChangedColumns = (!filter.fieldChangedColumns) ? [] : filter.fieldChangedColumns;\r\n this.advancedFilterForm.patchValue(filter);\r\n this.helperFormGroup.get(AdvancedFormElements.SpecificField)\r\n .setValue(!!(filter.fieldChangedColumns && filter.fieldChangedColumns.length));\r\n this._checkChildChanges(this.assetFilters);\r\n }\r\n\r\n async comparisonLienDateTypeOptionChanged(): Promise {\r\n const filter: Compliance.NameValuePair = this.comparisonLienDateTypeOption.value;\r\n\r\n if (filter.value === Compliance.ComparisonLienDateTypeEnum.Custom) {\r\n this.comparisonLienDateDisabled = false;\r\n } else {\r\n this.comparisonLienDate = null;\r\n this.comparisonLienDateDisabled = true;\r\n }\r\n\r\n this._validateComparisonDate();\r\n }\r\n\r\n onComparisonLienDateChanged(value: Date): void {\r\n this._validateComparisonDate();\r\n }\r\n\r\n /**\r\n * Update the form on selected changes\r\n * @param selected\r\n */\r\n updateForm(selected: FilterCheckbox): void {\r\n this._updateFormChildren(selected);\r\n this._checkQuickListMatch();\r\n }\r\n\r\n /**\r\n * Update the selected form element and it's children\r\n * @param selected\r\n * @param value\r\n */\r\n private _updateFormChildren(selected: FilterCheckbox, value?: boolean): void {\r\n if (selected.children) {\r\n if (value === null || value === undefined) {\r\n value = selected.formControl.value;\r\n }\r\n selected.children.forEach(\r\n child => {\r\n child.formControl.setValue(value);\r\n\r\n if (child.additionalSelect) {\r\n //handle the field change select if it's a child\r\n const select = child.additionalSelect;\r\n select.formControl.setValue((value) ? select.options.map(o => o.property) : []);\r\n }\r\n\r\n this._updateFormChildren(child, value);\r\n });\r\n } else {\r\n this._checkChildChanges(this.assetFilters);\r\n }\r\n }\r\n\r\n /**\r\n * Check to see if a change to a child checkbox effects the parent\r\n * @param filters\r\n */\r\n private _checkChildChanges(filters: FilterCheckbox[]): boolean {\r\n let filterActiveCount: number = 0;\r\n let filterIndeterminateCount: number = 0;\r\n _.forEach(filters,\r\n (filter: FilterCheckbox) => {\r\n if (filter.children) {\r\n filter.formControl.setValue(this._checkChildChanges(filter.children));\r\n }\r\n const value: boolean = filter.formControl.value;\r\n if (value) {\r\n filterActiveCount++;\r\n } else if (value === null) {\r\n filterIndeterminateCount++;\r\n }\r\n });\r\n if (filterActiveCount === filters.length) {\r\n return true;\r\n } else if (filterActiveCount === 0 && !filterIndeterminateCount) {\r\n return false;\r\n } else {\r\n return null;\r\n }\r\n }\r\n\r\n /**\r\n * Check if the options selected match a value from the quick list, otherwise set custom\r\n */\r\n private _checkQuickListMatch(): void {\r\n const allFilters = { ...this.advancedFilterForm.value, ...this.helperFormGroup.value };\r\n const filtersApplied: number = _.reduce(Object.keys(allFilters),\r\n (acc: number, key: string) => ((allFilters[key] === true) ? (acc += 1) : acc), 0);\r\n if (!filtersApplied) {\r\n this.selectedOption.setValue(this._dropdownOnOpen);\r\n return;\r\n }\r\n const outputModel: Compliance.AdvancedAssetFilters = this._createOutputModel();\r\n const option: Compliance.NameValuePair = _.find(this.selectOptions,\r\n (x) => _.isEqual(outputModel, x.value));\r\n this.selectedOption.setValue((option) ? option : this.selectOptions[this.selectOptions.length - 1]);\r\n }\r\n\r\n /**\r\n * Flatten the form controls for form groups\r\n * @param filterList\r\n * @param accumulator\r\n * @param isOutputControl\r\n */\r\n private _createFormControls(filterList: FilterCheckbox[], accumulator: DynamicFormControls, isOutputControl: boolean): DynamicFormControls {\r\n const result: DynamicFormControls = _.reduce(filterList, (acc, filter) => {\r\n if (filter.isOutputControl === isOutputControl) {\r\n acc[filter.formControlName] = filter.formControl;\r\n }\r\n if (filter.additionalSelect && filter.additionalSelect.isOutputControl === isOutputControl) {\r\n acc[filter.additionalSelect.formControlName] = filter.additionalSelect.formControl;\r\n }\r\n if (filter.children) {\r\n this._createFormControls(filter.children, acc, isOutputControl);\r\n }\r\n return acc;\r\n }, accumulator);\r\n return result;\r\n }\r\n\r\n /**\r\n * Format the output\r\n */\r\n private _createOutputModel(): Compliance.AdvancedAssetFilters {\r\n const formResults = this.advancedFilterForm.getRawValue() as Compliance.AdvancedAssetFilters;\r\n const fieldSelect = this.advancedFilterForm.get(AdvancedFormElements.FieldChanged);\r\n formResults[AdvancedFormElements.Changed] = !!formResults[AdvancedFormElements.Changed];\r\n formResults[AdvancedFormElements.FieldChanged] =\r\n (fieldSelect.disabled || (fieldSelect.enabled && (!fieldSelect.value || (fieldSelect.value && !fieldSelect.value.length))))\r\n ? null\r\n : this.advancedFilterForm.get(AdvancedFormElements.FieldChanged).value;\r\n\r\n const comparisonLienDateTypeFilter: Compliance.NameValuePair = this.comparisonLienDateTypeOption.value;\r\n formResults.comparisonLienDateType = comparisonLienDateTypeFilter.value;\r\n formResults.comparisonLienDate = this.comparisonLienDate;\r\n formResults.allAssetsAtLienDate = !!formResults.allAssetsAtLienDate;\r\n return formResults;\r\n }\r\n\r\n /**\r\n * Build the form groups\r\n */\r\n private _buildForm(): void {\r\n const helperFormControls: DynamicFormControls = this._createFormControls(this.assetFilters, {}, false);\r\n this.helperFormGroup = new UntypedFormGroup(helperFormControls);\r\n const advancedFormControls: DynamicFormControls = this._createFormControls(this.assetFilters, {}, true);\r\n this.advancedFilterForm = new UntypedFormGroup(advancedFormControls, { validators: this._validateForm() });\r\n this.helperFormGroup.get(AdvancedFormElements.SpecificField).valueChanges.pipe(takeUntil(this._destroy$)).subscribe(\r\n (checked: boolean) => {\r\n if (checked) {\r\n this.fieldSelect.formControl.enable();\r\n } else {\r\n this.fieldSelect.formControl.disable();\r\n this.fieldSelect.formControl.updateValueAndValidity();\r\n }\r\n });\r\n }\r\n\r\n /**\r\n * Listen to child dropdown for changes\r\n */\r\n private _registerFormListeners(): void {\r\n this.fieldSelect.formControl.valueChanges.pipe(takeUntil(this._destroy$)).subscribe(\r\n () => this._checkQuickListMatch());\r\n }\r\n\r\n /**\r\n * Validate that all form fields aren't filled out\r\n * */\r\n private _validateForm(): ValidatorFn {\r\n return (control: UntypedFormGroup): ValidationErrors | null => {\r\n const form = control.value;\r\n const active = Object.keys(form)\r\n .reduce((acc: number, key: string) => (form[key] === true || (Array.isArray(form[key]) && form[key].length)) ? (acc += 1) : acc, 0);\r\n const fieldSelectChecked = this.helperFormGroup.get(AdvancedFormElements.SpecificField).value;\r\n const fieldSelected = !fieldSelectChecked || (form[AdvancedFormElements.FieldChanged] && form[AdvancedFormElements.FieldChanged].length);\r\n this.disableSubmit = !(fieldSelected && active);\r\n this._helpService.updateContent([{\r\n helpContentId: 'asset-advanced.accept',\r\n tooltipText: (this.disableSubmit) ? 'Field change is checked but no fields were selected' : 'OK'\r\n }]);\r\n return (fieldSelected && active) ? null : { 'no-selection': true };\r\n };\r\n }\r\n\r\n private _validateComparisonDate() {\r\n const comparisonLienDateTypeFilter: Compliance.NameValuePair = this.comparisonLienDateTypeOption.value;\r\n const comparisonLienDateType = comparisonLienDateTypeFilter.value;\r\n\r\n if (comparisonLienDateType === Compliance.ComparisonLienDateTypeEnum.Custom && (!this.comparisonLienDate || (this.comparisonLienDate > this.lienDate))) {\r\n this.disableSubmit = true;\r\n this._helpService.updateContent([{\r\n helpContentId: 'asset-advanced.accept',\r\n tooltipText: 'Comparison date must be earlier than lien date'\r\n }]);\r\n } else {\r\n this.disableSubmit = false;\r\n this._helpService.updateContent([{ helpContentId: 'asset-advanced.accept', tooltipText: 'OK' }]);\r\n }\r\n }\r\n\r\n}\r\n","export interface AssetPropertyInfo {\r\n key: string;\r\n displayName: string;\r\n property: Compliance.AssetPropertyEnum;\r\n isDescriptor: boolean;\r\n isFurtherLimitTo?: boolean;\r\n isChangeFilter?: boolean;\r\n isSelected?: boolean;\r\n}\r\n\r\nexport class AssetPropertyMap {\r\n static properties: AssetPropertyInfo[] = [\r\n { key: 'reportingAcqDate', isDescriptor: false, displayName: 'Acquisition Date', property: Compliance.AssetPropertyEnum.ReportingAcqDate, isFurtherLimitTo: true },\r\n { key: 'reportingAssetNumber', isDescriptor: false, displayName: 'Asset Number', property: Compliance.AssetPropertyEnum.ReportingAssetNumber, isFurtherLimitTo: true },\r\n { key: 'assetClassificationName', isDescriptor: false, displayName: 'Classification', property: Compliance.AssetPropertyEnum.AssetClassificationName, isFurtherLimitTo: true },\r\n { key: 'reportingCost', isDescriptor: false, displayName: 'Cost', property: Compliance.AssetPropertyEnum.ReportingCost, isFurtherLimitTo: true },\r\n { key: 'reportingDescription', isDescriptor: false, displayName: 'Description', property: Compliance.AssetPropertyEnum.ReportingDescription, isFurtherLimitTo: true },\r\n { key: 'reportingDisposedDate', isDescriptor: false, displayName: 'Disposed Date', property: Compliance.AssetPropertyEnum.ReportingDisposedDate, isFurtherLimitTo: true },\r\n { key: 'reportingGLAccountName', isDescriptor: false, displayName: 'G/L Account', property: Compliance.AssetPropertyEnum.ReportingGLAccountNameOrNumber, isFurtherLimitTo: true },\r\n { key: 'reportingGLAccountNumber', isDescriptor: false, displayName: 'G/L Account Number', property: Compliance.AssetPropertyEnum.ReportingGLAccountNumber, isFurtherLimitTo: false, isChangeFilter: false },\r\n { key: 'reportingSiteNameOrNumber', isDescriptor: false, displayName: 'Site', property: Compliance.AssetPropertyEnum.ReportingSiteNameOrNumber, isFurtherLimitTo: true },\r\n { key: 'reportingSiteName', isDescriptor: false, displayName: 'Site Name', property: Compliance.AssetPropertyEnum.ReportingSiteName, isFurtherLimitTo: false, isChangeFilter: false },\r\n { key: 'reportingSiteNumber', isDescriptor: false, displayName: 'Site Number', property: Compliance.AssetPropertyEnum.ReportingSiteNumber, isFurtherLimitTo: false, isChangeFilter: false },\r\n { key: 'reportingParcel', isDescriptor: false, displayName: 'Parcel', property: Compliance.AssetPropertyEnum.ReportingParcel, isFurtherLimitTo: true },\r\n { key: 'reportingT1', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT1, isFurtherLimitTo: true },\r\n { key: 'reportingT2', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT2, isFurtherLimitTo: true },\r\n { key: 'reportingT3', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT3, isFurtherLimitTo: true },\r\n { key: 'reportingT4', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT4, isFurtherLimitTo: true },\r\n { key: 'reportingT5', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT5, isFurtherLimitTo: true },\r\n { key: 'reportingT6', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT6, isFurtherLimitTo: true },\r\n { key: 'reportingT7', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT7, isFurtherLimitTo: true },\r\n { key: 'reportingT8', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT8, isFurtherLimitTo: true },\r\n { key: 'reportingT9', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT9, isFurtherLimitTo: true },\r\n { key: 'reportingT10', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT10, isFurtherLimitTo: true },\r\n { key: 'reportingT11', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT11, isFurtherLimitTo: true },\r\n { key: 'reportingT12', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT12, isFurtherLimitTo: true },\r\n { key: 'reportingT13', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT13, isFurtherLimitTo: true },\r\n { key: 'reportingT14', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT14, isFurtherLimitTo: true },\r\n { key: 'reportingT15', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT15, isFurtherLimitTo: true },\r\n { key: 'reportingT16', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT16, isFurtherLimitTo: true },\r\n { key: 'reportingT17', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT17, isFurtherLimitTo: true },\r\n { key: 'reportingT18', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT18, isFurtherLimitTo: true },\r\n { key: 'reportingT19', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT19, isFurtherLimitTo: true },\r\n { key: 'reportingT20', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT20, isFurtherLimitTo: true },\r\n { key: 'reportingT21', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT21, isFurtherLimitTo: true },\r\n { key: 'reportingT22', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT22, isFurtherLimitTo: true },\r\n { key: 'reportingT23', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT23, isFurtherLimitTo: true },\r\n { key: 'reportingT24', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT24, isFurtherLimitTo: true },\r\n { key: 'reportingT25', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT25, isFurtherLimitTo: true },\r\n { key: 'reportingT26', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT26, isFurtherLimitTo: true },\r\n { key: 'reportingT27', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT27, isFurtherLimitTo: true },\r\n { key: 'reportingT28', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT28, isFurtherLimitTo: true },\r\n { key: 'reportingT29', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT29, isFurtherLimitTo: true },\r\n { key: 'reportingT30', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingT30, isFurtherLimitTo: true },\r\n { key: 'reportingN1', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingN1, isFurtherLimitTo: true },\r\n { key: 'reportingN2', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingN2, isFurtherLimitTo: true },\r\n { key: 'reportingN3', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingN3, isFurtherLimitTo: true },\r\n { key: 'reportingN4', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingN4, isFurtherLimitTo: true },\r\n { key: 'reportingN5', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingN5, isFurtherLimitTo: true },\r\n { key: 'reportingN6', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingN6, isFurtherLimitTo: true },\r\n { key: 'reportingN7', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingN7, isFurtherLimitTo: true },\r\n { key: 'reportingN8', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingN8, isFurtherLimitTo: true },\r\n { key: 'reportingN9', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingN9, isFurtherLimitTo: true },\r\n { key: 'reportingN10', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingN10, isFurtherLimitTo: true },\r\n { key: 'reportingD1', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingD1, isFurtherLimitTo: true },\r\n { key: 'reportingD2', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingD2, isFurtherLimitTo: true },\r\n { key: 'reportingD3', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingD3, isFurtherLimitTo: true },\r\n { key: 'reportingD4', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingD4, isFurtherLimitTo: true },\r\n { key: 'reportingD5', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingD5, isFurtherLimitTo: true },\r\n { key: 'reportingD6', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingD6, isFurtherLimitTo: true },\r\n { key: 'reportingD7', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingD7, isFurtherLimitTo: true },\r\n { key: 'reportingD8', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingD8, isFurtherLimitTo: true },\r\n { key: 'reportingD9', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingD9, isFurtherLimitTo: true },\r\n { key: 'reportingD10', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.ReportingD10, isFurtherLimitTo: true },\r\n\r\n { key: 'effectiveDate', isDescriptor: false, displayName: 'EffectiveDate', property: Compliance.AssetPropertyEnum.EffectiveDate, isChangeFilter: false },\r\n { key: 'companyCode', isDescriptor: false, displayName: 'Company Code', property: Compliance.AssetPropertyEnum.CompanyCode, isChangeFilter: false },\r\n { key: 'CompanyName', isDescriptor: false, displayName: 'Company Name', property: Compliance.AssetPropertyEnum.CompanyName, isChangeFilter: false },\r\n { key: 'assetOwnershipType', isDescriptor: false, displayName: 'Asset Ownership Type', property: Compliance.AssetPropertyEnum.AssetOwnershipType, isChangeFilter: false },\r\n { key: 'assetVerificationReason', isDescriptor: false, displayName: 'Asset Verification Reason', property: Compliance.AssetPropertyEnum.AssetVerificationReason, isChangeFilter: false },\r\n { key: 'sourceAssetNumber', isDescriptor: false, displayName: 'Asset Number', property: Compliance.AssetPropertyEnum.SourceAssetNumber, isChangeFilter: true },\r\n { key: 'sourceAcqDate', isDescriptor: false, displayName: 'Acq Date', property: Compliance.AssetPropertyEnum.SourceAcqDate, isChangeFilter: true },\r\n { key: 'sourceDescription', isDescriptor: false, displayName: 'Description', property: Compliance.AssetPropertyEnum.SourceDescription, isChangeFilter: true },\r\n { key: 'sourceCost', isDescriptor: false, displayName: 'Cost', property: Compliance.AssetPropertyEnum.SourceCost, isChangeFilter: true },\r\n { key: 'sourceAdjustedCost', isDescriptor: false, displayName: 'Adjusted Cost', property: Compliance.AssetPropertyEnum.SourceAdjustedCost, isChangeFilter: false },\r\n { key: 'sourceSiteNameOrNumber', isDescriptor: false, displayName: 'Site', property: Compliance.AssetPropertyEnum.SourceSiteNameOrNumber, isChangeFilter: true },\r\n { key: 'sourceSiteName', isDescriptor: false, displayName: 'Site Name', property: Compliance.AssetPropertyEnum.SourceSiteName, isChangeFilter: false },\r\n { key: 'sourceSiteNumber', isDescriptor: false, displayName: 'Site Number', property: Compliance.AssetPropertyEnum.SourceSiteNumber, isChangeFilter: false },\r\n { key: 'sourceGLAccountName', isDescriptor: false, displayName: 'G/L Account', property: Compliance.AssetPropertyEnum.SourceGLAccountNameOrNumber, isChangeFilter: true },\r\n { key: 'sourceGLAccountNumber', isDescriptor: false, displayName: 'G/L Account Number', property: Compliance.AssetPropertyEnum.SourceGLAccountNumber, isChangeFilter: false },\r\n { key: 'sourceDisposedDate', isDescriptor: false, displayName: 'Disposed Date', property: Compliance.AssetPropertyEnum.SourceDisposedDate, isChangeFilter: true },\r\n { key: 'sourceT1', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT1, isChangeFilter: true },\r\n { key: 'sourceT2', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT2, isChangeFilter: true },\r\n { key: 'sourceT3', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT3, isChangeFilter: true },\r\n { key: 'sourceT4', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT4, isChangeFilter: true },\r\n { key: 'sourceT5', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT5, isChangeFilter: true },\r\n { key: 'sourceT6', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT6, isChangeFilter: true },\r\n { key: 'sourceT7', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT7, isChangeFilter: true },\r\n { key: 'sourceT8', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT8, isChangeFilter: true },\r\n { key: 'sourceT9', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT9, isChangeFilter: true },\r\n { key: 'sourceT10', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT10, isChangeFilter: true },\r\n { key: 'sourceT11', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT11, isChangeFilter: true },\r\n { key: 'sourceT12', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT12, isChangeFilter: true },\r\n { key: 'sourceT13', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT13, isChangeFilter: true },\r\n { key: 'sourceT14', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT14, isChangeFilter: true },\r\n { key: 'sourceT15', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT15, isChangeFilter: true },\r\n { key: 'sourceT16', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT16, isChangeFilter: true },\r\n { key: 'sourceT17', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT17, isChangeFilter: true },\r\n { key: 'sourceT18', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT18, isChangeFilter: true },\r\n { key: 'sourceT19', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT19, isChangeFilter: true },\r\n { key: 'sourceT20', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT20, isChangeFilter: true },\r\n { key: 'sourceT21', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT21, isChangeFilter: true },\r\n { key: 'sourceT22', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT22, isChangeFilter: true },\r\n { key: 'sourceT23', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT23, isChangeFilter: true },\r\n { key: 'sourceT24', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT24, isChangeFilter: true },\r\n { key: 'sourceT25', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT25, isChangeFilter: true },\r\n { key: 'sourceT26', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT26, isChangeFilter: true },\r\n { key: 'sourceT27', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT27, isChangeFilter: true },\r\n { key: 'sourceT28', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT28, isChangeFilter: true },\r\n { key: 'sourceT29', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT29, isChangeFilter: true },\r\n { key: 'sourceT30', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceT30, isChangeFilter: true },\r\n { key: 'sourceN1', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceN1, isChangeFilter: true },\r\n { key: 'sourceN2', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceN2, isChangeFilter: true },\r\n { key: 'sourceN3', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceN3, isChangeFilter: true },\r\n { key: 'sourceN4', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceN4, isChangeFilter: true },\r\n { key: 'sourceN5', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceN5, isChangeFilter: true },\r\n { key: 'sourceN6', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceN6, isChangeFilter: true },\r\n { key: 'sourceN7', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceN7, isChangeFilter: true },\r\n { key: 'sourceN8', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceN8, isChangeFilter: true },\r\n { key: 'sourceN9', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceN9, isChangeFilter: true },\r\n { key: 'sourceN10', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceN10, isChangeFilter: true },\r\n { key: 'sourceD1', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceD1, isChangeFilter: true },\r\n { key: 'sourceD2', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceD2, isChangeFilter: true },\r\n { key: 'sourceD3', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceD3, isChangeFilter: true },\r\n { key: 'sourceD4', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceD4, isChangeFilter: true },\r\n { key: 'sourceD5', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceD5, isChangeFilter: true },\r\n { key: 'sourceD6', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceD6, isChangeFilter: true },\r\n { key: 'sourceD7', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceD7, isChangeFilter: true },\r\n { key: 'sourceD8', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceD8, isChangeFilter: true },\r\n { key: 'sourceD9', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceD9, isChangeFilter: true },\r\n { key: 'sourceD10', isDescriptor: true, displayName: '', property: Compliance.AssetPropertyEnum.SourceD10, isChangeFilter: true },\r\n { key: 'isUserCreated', isDescriptor: false, displayName: 'User Created', property: Compliance.AssetPropertyEnum.IsUserCreated, isChangeFilter: false },\r\n { key: 'state', isDescriptor: false, displayName: 'State', property: Compliance.AssetPropertyEnum.State, isChangeFilter: false },\r\n { key: 'assessorName', isDescriptor: false, displayName: 'Assessor Name', property: Compliance.AssetPropertyEnum.AssessorName, isChangeFilter: false },\r\n { key: 'sourceState', isDescriptor: false, displayName: 'S. State', property: Compliance.AssetPropertyEnum.SourceState, isChangeFilter: false },\r\n { key: 'alternativeAcqDateDescriptorName', isDescriptor: false, displayName: 'Alternate Acq Date Source', property: Compliance.AssetPropertyEnum.AlternativeAcqDateDescriptorName, isChangeFilter: false },\r\n { key: 'alternativeCostDescriptorName', isDescriptor: false, displayName: 'Alternate Cost Source', property: Compliance.AssetPropertyEnum.AlternativeCostDescriptorName, isChangeFilter: false },\r\n ];\r\n}\r\n","\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n","import { Component, Input, Output, EventEmitter } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { WeissmanModalService } from '../../../WeissmanModalService';\r\nimport { AssetAdvancedDetailsComponent, AssetAdvancedDetailsParams } from '../Asset-Advanced-Details/assetAdvancedDetails.component';\r\nimport { AssetPropertyMap } from '../../Models/assetPropertyMap';\r\nimport { AssetPropertyInfo } from '../../Models/assetPropertyMap';\r\nimport * as _ from 'lodash';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { ASSET_ADVANCED_HELP } from './assetAdvanced.component.help';\r\nimport { UserSettingsService } from '../../../../Account/userSettings.service';\r\n\r\n@Component({\r\n selector: 'asset-advanced',\r\n templateUrl: './assetAdvanced.component.html'\r\n})\r\nexport class AssetAdvancedComponent {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService,\r\n private readonly _userSettingsService: UserSettingsService\r\n ) { }\r\n\r\n @Input()\r\n set assetDescriptors(assetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[]) {\r\n if (assetDescriptors) {\r\n this._setAssetDescriptors(assetDescriptors);\r\n }\r\n }\r\n\r\n @Output() optionChange: EventEmitter = new EventEmitter();\r\n\r\n isInitialized: boolean;\r\n\r\n selectOptions: Compliance.NameValuePair[] = [\r\n {\r\n name: 'All assets at lien date and disposed', value: {\r\n allAssetsAtLienDate: true,\r\n fieldChangedColumns: null,\r\n includeAnyReturnImpactfulFieldChange: true,\r\n includeDisposed: true,\r\n includeDisposedSinceLastLienDate: false,\r\n includeNewAddition: true,\r\n includePotentiallyDisposed: true,\r\n includeChanged: true,\r\n includeNotChanged: true,\r\n includeTransferred: true,\r\n comparisonLienDate: null,\r\n comparisonLienDateType: Compliance.ComparisonLienDateTypeEnum.OneYearAgo\r\n }\r\n },\r\n {\r\n name: 'All assets at lien date', value: {\r\n allAssetsAtLienDate: true,\r\n fieldChangedColumns: null,\r\n includeAnyReturnImpactfulFieldChange: true,\r\n includeDisposed: false,\r\n includeDisposedSinceLastLienDate: false,\r\n includeNewAddition: true,\r\n includePotentiallyDisposed: true,\r\n includeChanged: true,\r\n includeNotChanged: true,\r\n includeTransferred: true,\r\n comparisonLienDate: null,\r\n comparisonLienDateType: Compliance.ComparisonLienDateTypeEnum.OneYearAgo\r\n }\r\n },\r\n {\r\n name: 'New additions and transfers', value: {\r\n allAssetsAtLienDate: false,\r\n fieldChangedColumns: null,\r\n includeAnyReturnImpactfulFieldChange: false,\r\n includeDisposed: false,\r\n includeDisposedSinceLastLienDate: false,\r\n includeNewAddition: true,\r\n includePotentiallyDisposed: false,\r\n includeChanged: false,\r\n includeNotChanged: false,\r\n includeTransferred: true,\r\n comparisonLienDate: null,\r\n comparisonLienDateType: Compliance.ComparisonLienDateTypeEnum.OneYearAgo\r\n }\r\n },\r\n {\r\n name: 'Potentially disposed', value: {\r\n allAssetsAtLienDate: false,\r\n fieldChangedColumns: null,\r\n includeAnyReturnImpactfulFieldChange: false,\r\n includeDisposed: false,\r\n includeDisposedSinceLastLienDate: false,\r\n includeNewAddition: false,\r\n includePotentiallyDisposed: true,\r\n includeChanged: false,\r\n includeNotChanged: false,\r\n includeTransferred: false,\r\n comparisonLienDate: null,\r\n comparisonLienDateType: Compliance.ComparisonLienDateTypeEnum.OneYearAgo\r\n }\r\n },\r\n {\r\n name: 'Disposed', value: {\r\n allAssetsAtLienDate: false,\r\n fieldChangedColumns: null,\r\n includeAnyReturnImpactfulFieldChange: false,\r\n includeDisposed: true,\r\n includeDisposedSinceLastLienDate: true,\r\n includeNewAddition: false,\r\n includePotentiallyDisposed: false,\r\n includeChanged: false,\r\n includeNotChanged: false,\r\n includeTransferred: false,\r\n comparisonLienDate: null,\r\n comparisonLienDateType: Compliance.ComparisonLienDateTypeEnum.OneYearAgo\r\n }\r\n },\r\n {\r\n name: 'Custom', value: {\r\n allAssetsAtLienDate: false,\r\n fieldChangedColumns: null,\r\n includeAnyReturnImpactfulFieldChange: true,\r\n includeDisposed: false,\r\n includeDisposedSinceLastLienDate: false,\r\n includeNewAddition: true,\r\n includePotentiallyDisposed: true,\r\n includeChanged: true,\r\n includeNotChanged: true,\r\n includeTransferred: true,\r\n comparisonLienDate: null,\r\n comparisonLienDateType: Compliance.ComparisonLienDateTypeEnum.OneYearAgo\r\n }\r\n }\r\n ];\r\n selectedOption: UntypedFormControl;\r\n\r\n private readonly _settingName = 'Show-Selected-Option';\r\n private _fieldSelectOptions: AssetPropertyInfo[];\r\n private _savedSelectedOptionSetting: any;\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(ASSET_ADVANCED_HELP);\r\n\r\n this.selectOptions.forEach(x => {\r\n if (x.value.allAssetsAtLienDate && !x.value.fieldChangedColumns) {\r\n x.value.fieldChangedColumns = _.map(this._fieldSelectOptions, y => y.property);\r\n }\r\n });\r\n\r\n const settings = this._userSettingsService.getSettingsByGroup(Core.UserSettingGroup.CompanyAssetsList);\r\n this._savedSelectedOptionSetting = settings.find(x => x.name === this._settingName);\r\n\r\n let selectedOption: Compliance.NameValuePair;\r\n\r\n if (this._savedSelectedOptionSetting) {\r\n selectedOption = this.selectOptions.find(x => x.name === this._savedSelectedOptionSetting.value.name);\r\n\r\n if (selectedOption && selectedOption.name === 'Custom') {\r\n for (const prop in this._savedSelectedOptionSetting.value.value) {\r\n selectedOption.value[prop] = this._savedSelectedOptionSetting.value.value[prop];\r\n }\r\n\r\n this._fieldSelectOptions.forEach(x => x['isSelected'] = !!_.find(selectedOption.value.fieldChangedColumns, y => x.property === y));\r\n selectedOption.value.fieldChangedColumns = _.map(this._fieldSelectOptions.filter(x => x.isSelected), x => x.property);\r\n }\r\n }\r\n\r\n if (!selectedOption) {\r\n selectedOption = this.selectOptions[0];\r\n }\r\n\r\n this.selectedOption = new UntypedFormControl(selectedOption);\r\n this.optionChange.emit(this.selectedOption.value.value);\r\n }\r\n\r\n /**\r\n * Select Option change\r\n */\r\n async selectedOptionChanged(): Promise {\r\n const filter: Compliance.NameValuePair = this.selectedOption.value;\r\n this.optionChange.emit(filter.value);\r\n await this._saveSelectedOption();\r\n }\r\n\r\n /**\r\n * Handle advanced filter modal\r\n */\r\n async edit(): Promise {\r\n const params: AssetAdvancedDetailsParams = {\r\n selectOptions: this.selectOptions,\r\n selectControl: this.selectedOption,\r\n fieldSelectOptions: this._fieldSelectOptions\r\n };\r\n\r\n const result = await this._modalService.showAsync(AssetAdvancedDetailsComponent, params, 'modal-md');\r\n\r\n // trigger change detection on dropdown value\r\n this.selectedOption.setValue(this.selectedOption.value);\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (this.selectedOption.value === this.selectOptions[this.selectOptions.length - 1]) {\r\n this.selectOptions[this.selectOptions.length - 1].value = result;\r\n }\r\n\r\n this.optionChange.emit(result);\r\n\r\n await this._saveSelectedOption();\r\n }\r\n\r\n /**\r\n * Assign asset descriptors and override properties\r\n * @param assetDescriptors\r\n */\r\n private _setAssetDescriptors(assetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[]): void {\r\n const overrideProperties = _.map(_.filter(AssetPropertyMap.properties, x => x.isChangeFilter && !x.isDescriptor), x => x);\r\n\r\n _.forEach(assetDescriptors, x => {\r\n const descriptorKey = `source${x.columnName}`;\r\n const descriptorPropertyInfo = _.find(AssetPropertyMap.properties, (p: AssetPropertyInfo) => p.isChangeFilter && p.isDescriptor && p.key === descriptorKey);\r\n\r\n if (descriptorPropertyInfo) {\r\n overrideProperties.push(_.extend(descriptorPropertyInfo, { isSelected: false, displayName: x.descriptor.name }));\r\n }\r\n else {\r\n console.warn(`Property info not found for asset descriptor ${descriptorKey}`);\r\n }\r\n });\r\n\r\n this._fieldSelectOptions = overrideProperties.sort((a, b) => (a.displayName > b.displayName) ? 1 : ((b.displayName > a.displayName) ? -1 : 0));\r\n }\r\n\r\n private async _saveSelectedOption() {\r\n if (!this._savedSelectedOptionSetting) {\r\n this._savedSelectedOptionSetting = {\r\n id: 0,\r\n name: this._settingName,\r\n groupId: Core.UserSettingGroup.CompanyAssetsList,\r\n folderId: Core.UserSettingFolder.Default\r\n };\r\n }\r\n\r\n this._savedSelectedOptionSetting.value = this.selectedOption.value;\r\n this._savedSelectedOptionSetting = await this._userSettingsService.save(this._savedSelectedOptionSetting);\r\n }\r\n}\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const ASSET_LIMIT_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'asset-limit.header',\r\n tooltipText: '',\r\n hasIcon: false\r\n }\r\n];\r\n","\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { UntypedFormControl, UntypedFormGroup } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AssetLimitOption } from '../Asset-Limit/assetLimit.component';\r\nimport { AssetPropertyInfo } from '../../Models/assetPropertyMap';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport * as _ from 'lodash';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { ASSET_LIMIT_HELP } from '../Asset-Limit/assetLimit.component.help';\r\n\r\nexport interface AssetLimitDetailsParams {\r\n limitOptions: Compliance.NameValuePair[];\r\n selectedOption: UntypedFormControl;\r\n assetDescriptors: AssetPropertyInfo[];\r\n}\r\n\r\nexport interface AssetOverrideProperty extends AssetPropertyInfo {\r\n isSelected: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'asset-limit-details',\r\n templateUrl: './assetLimitDetails.component.html'\r\n})\r\nexport class AssetLimitDetailsComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _helpService: HelpService\r\n ) { }\r\n\r\n selectedOption: UntypedFormControl;\r\n invalidCostAllocations: UntypedFormControl = new UntypedFormControl(false);\r\n noReportingParcel: UntypedFormControl = new UntypedFormControl(false);\r\n selectedOverrides: UntypedFormControl = new UntypedFormControl([]);\r\n furtherLimitForm: UntypedFormGroup;\r\n\r\n params: AssetLimitDetailsParams;\r\n result: AssetLimitOption;\r\n\r\n limitOptions: Compliance.NameValuePair[];\r\n overrideProperties: AssetPropertyInfo[];\r\n\r\n private _dropdownOnOpen: Compliance.NameValuePair;\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(ASSET_LIMIT_HELP);\r\n this.limitOptions = this.params.limitOptions;\r\n this.selectedOption = this.params.selectedOption;\r\n this.overrideProperties = this.params.assetDescriptors;\r\n this._dropdownOnOpen = this.selectedOption.value;\r\n\r\n this._buildForm();\r\n this.applyFromDropdown();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n\r\n /**\r\n * Save the form values\r\n */\r\n save(): void {\r\n this.result = this.furtherLimitForm.value;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n /**\r\n * Cancel and reset to initial state\r\n */\r\n cancel(): void {\r\n this.selectedOption.setValue(this._dropdownOnOpen);\r\n this.applyFromDropdown();\r\n this._bsModalRef.hide();\r\n }\r\n\r\n /**\r\n * Apply from the initial set value or from quick list select\r\n */\r\n applyFromDropdown(): void {\r\n const formValue = this.selectedOption.value;\r\n const filter = { ...formValue.value };\r\n this.furtherLimitForm.setValue(filter);\r\n }\r\n\r\n private _buildForm() {\r\n this.furtherLimitForm = new UntypedFormGroup({\r\n overrideFilterColumns: this.selectedOverrides,\r\n invalidCostAllocations: this.invalidCostAllocations,\r\n noReportingParcel: this.noReportingParcel\r\n });\r\n this.furtherLimitForm.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(() => this._formChanged());\r\n }\r\n\r\n private _formChanged(): void {\r\n const option: Compliance.NameValuePair = _.find(this.limitOptions,\r\n (x, i) => {\r\n this.furtherLimitForm.value.overrideFilterColumns.sort();\r\n x.value.overrideFilterColumns.sort();\r\n // By default, \"Custom\" is the same as \"Nothing selected\", so if they picked custom don't auto-set it to nothing selected\r\n if (i === 0 && this.selectedOption.value === this.limitOptions[this.limitOptions.length - 1]) {\r\n return false;\r\n }\r\n return _.isEqual(this.furtherLimitForm.value, x.value);\r\n });\r\n this.selectedOption.setValue((option) ? option : this.limitOptions[this.limitOptions.length - 1]);\r\n }\r\n}\r\n","
\r\n \r\n \r\n
\r\n","import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { WeissmanModalService } from '../../../WeissmanModalService';\r\nimport { AssetLimitDetailsComponent, AssetLimitDetailsParams, AssetOverrideProperty } from '../Asset-Limit-Details/assetLimitDetails.component';\r\nimport { AssetPropertyMap, AssetPropertyInfo } from '../../Models/assetPropertyMap';\r\nimport * as _ from 'lodash';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { ASSET_LIMIT_HELP } from './assetLimit.component.help';\r\n\r\nexport interface AssetLimitOption {\r\n overrideFilterColumns: Compliance.AssetPropertyEnum[];\r\n invalidCostAllocations: boolean;\r\n noReportingParcel: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'asset-limit',\r\n templateUrl: './assetLimit.component.html'\r\n})\r\nexport class AssetLimitComponent implements OnInit {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService\r\n ) { }\r\n\r\n @Input()\r\n set assetDescriptors(assetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[]) {\r\n if (assetDescriptors) {\r\n this._setAssetDescriptors(assetDescriptors);\r\n }\r\n }\r\n\r\n @Output() optionChange: EventEmitter = new EventEmitter();\r\n\r\n limitOptions: Compliance.NameValuePair[] = [\r\n { name: 'Nothing selected', value: { overrideFilterColumns: [], invalidCostAllocations: false, noReportingParcel: false } },\r\n { name: 'Any field is overridden', value: { overrideFilterColumns: [], invalidCostAllocations: false, noReportingParcel: false } },\r\n { name: 'Has an issue', value: { overrideFilterColumns: [], invalidCostAllocations: true, noReportingParcel: false } },\r\n { name: 'No default asset parcel', value: { overrideFilterColumns: [], invalidCostAllocations: false, noReportingParcel: true } },\r\n { name: 'Custom', value: { overrideFilterColumns: [], invalidCostAllocations: false, noReportingParcel: false } },\r\n ];\r\n overrideOptions: AssetPropertyInfo[];\r\n selectedOption: UntypedFormControl;\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(ASSET_LIMIT_HELP);\r\n this.selectedOption = new UntypedFormControl(this.limitOptions[0]);\r\n this.optionChange.emit(this.limitOptions[0].value);\r\n }\r\n\r\n /**\r\n * Select Option change\r\n */\r\n selectedOptionChanged(): void {\r\n const filter = this.selectedOption.value;\r\n this.optionChange.emit(filter.value);\r\n }\r\n\r\n /**\r\n * Handle advanced filter modal\r\n */\r\n async edit(): Promise {\r\n const params: AssetLimitDetailsParams = {\r\n limitOptions: this.limitOptions,\r\n selectedOption: this.selectedOption,\r\n assetDescriptors: this.overrideOptions\r\n };\r\n\r\n const result = await this._modalService.showAsync(AssetLimitDetailsComponent, params, 'modal-md');\r\n\r\n // trigger change detection on dropdown value\r\n this.selectedOption.setValue(this.selectedOption.value);\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (this.selectedOption.value === this.limitOptions[this.limitOptions.length - 1]) {\r\n this.limitOptions[this.limitOptions.length - 1].value = result;\r\n }\r\n\r\n this.optionChange.emit(this.selectedOption.value.value);\r\n }\r\n\r\n private _setAssetDescriptors(assetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[]): void {\r\n\r\n // get non-descriptor overridable properties\r\n const overrideOptions: AssetPropertyInfo[] = _.map(_.filter(AssetPropertyMap.properties, x => x.isFurtherLimitTo && !x.isDescriptor), x => x);\r\n\r\n _.forEach(assetDescriptors, x => {\r\n const descriptorKey = `reporting${x.columnName}`;\r\n const descriptorPropertyInfo = _.find(AssetPropertyMap.properties, (p: AssetPropertyInfo) => p.isFurtherLimitTo && p.isDescriptor && p.key === descriptorKey);\r\n\r\n if (descriptorPropertyInfo) {\r\n overrideOptions.push(_.extend(descriptorPropertyInfo, { isSelected: false, displayName: x.descriptor.name } as AssetOverrideProperty));\r\n }\r\n else {\r\n console.warn(`Property info not found for asset descriptor ${descriptorKey}`);\r\n }\r\n });\r\n\r\n this.overrideOptions = _.sortBy(overrideOptions, x => x.displayName);\r\n this.limitOptions[1].value.overrideFilterColumns = overrideOptions.map(o => o.property);\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Assets\r\n \r\n {{ isLienDatePrior ? ' Assets present on or carried forward to ' + (lienDate.date | weissmanDateFormat) : ''}}\r\n {{ isLienDateExact ? ' Assets present or confirmed present on ' + (lienDate.date | weissmanDateFormat) : ''}}\r\n {{ lienDate && lienDate.useStateLienDate ? 'only states utilizing ' + (lienDate.date | weissmanMonthDayDateFormat) + ' lien date' : ''}}\r\n \r\n \r\n

\r\n
\r\n
\r\n
View:
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
Asset import in progress
\r\n
\r\n
Importing: {{activeImportProcessedRowsCount}} of {{this.activeImportSelectedRowsCount}}
\r\n
Time left: {{activeImportTimeRemaining}}
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n","import { Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, ICellRendererParams, RowNode } from 'ag-grid-community';\r\nimport { AssetListAgGridDataSource, AssetListDataSourceParams } from './agGridDataSource';\r\nimport {\r\n AssetRepository,\r\n CompanyAssetDescriptorRepository,\r\n CostAdjustmentRepository,\r\n EntityImportRepository\r\n} from '../../Repositories';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { WeissmanDateFormatPipe, WeissmanKeyValueDisplayPipe } from '../../../UI-Lib/Pipes';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { AssetSummary } from '../Models/assetSummary';\r\nimport {\r\n AssetListGridActionCellRendererComponent,\r\n ICellRendererParamsForAssetListGridAction\r\n} from './agGridActionCellRenderer.component';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../AgGrid/MultiSelectTracker';\r\nimport { AssetDetailsComponent, AssetDetailsParams } from '../Asset-Details/assetDetails.component';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../AgGrid';\r\nimport { BehaviorSubject, lastValueFrom, Observable, Subject, Subscription } from 'rxjs';\r\nimport { InstanceRights, RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { AssetLienDate } from '../Asset-Lien-Date/assetLienDate.component';\r\nimport { AssetLimitOption } from './Asset-Limit/assetLimit.component';\r\nimport { AssetBulkUpdateComponent, AssetBulkUpdateParams } from './Asset-Bulk-Update/assetBulkUpdate.component';\r\nimport { AssetChangeIconCellRendererComponent } from './agGridChangeIconCellRenderer.component';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../AgGrid/ToolPanel/models';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { ASSET_LIST_HELP } from './assetList.component.help';\r\nimport { HotkeyService } from '../../../UI-Lib/HotKeys/hotKeys.service';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxOptions,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport {\r\n DeleteConfirmationComponent,\r\n DeleteConfirmationComponentParams\r\n} from '../../../Common/Delete-Confirmation/deleteConfirmation.component';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { ParcelService } from '../../../Entity/Parcel/parcel.service.upgrade';\r\nimport { SiteRepository } from '../../../Core-Repositories';\r\nimport { AgGridYesNoFloatingFilterComponent } from '../../AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport {\r\n AgGridTextWithTotalsUpdateCellRendererComponent,\r\n AgGridTextWithTotalsUpdateCellRendererParams\r\n} from '../../AgGrid/CellRenderers/agGridTextWithTotalsUpdateCellRenderer.component';\r\nimport { AgGridPersistenceService } from '../../AgGrid/agGridPersistence.service';\r\nimport { TimerService } from '../../../UI-Lib/Utilities';\r\n\r\nimport * as _ from 'lodash';\r\nimport {\r\n AssetImportProgressComponent,\r\n AssetImportProgressParams\r\n} from './Asset-Import-Progress/assetImportProgress.component';\r\nimport { AssetImportProgressService } from './Asset-Import-Progress/assetImportProgress.service';\r\n\r\nenum GridSourceOptionEnum {\r\n Imported,\r\n Reporting\r\n}\r\n\r\n@Component({\r\n selector: 'asset-list',\r\n templateUrl: './assetList.component.html',\r\n styleUrls: ['./assetList.component.scss'],\r\n providers: [HotkeyService]\r\n})\r\nexport class AssetListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _assetRepository: AssetRepository,\r\n private readonly _entityImportRepository: EntityImportRepository,\r\n private readonly _companyService: CompanyService,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _companyAssetDescriptorRepository: CompanyAssetDescriptorRepository,\r\n private readonly _costAdjustmentRepository: CostAdjustmentRepository,\r\n private readonly _helpService: HelpService,\r\n private readonly _hotkeyService: HotkeyService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _siteService: SiteRepository,\r\n private readonly _parcelService: ParcelService,\r\n private readonly _agGridPersistenceService: AgGridPersistenceService,\r\n private readonly _assetImportProgressService: AssetImportProgressService,\r\n private readonly _timer: TimerService\r\n ) { }\r\n\r\n @Input() companyIdFilter: number;\r\n @Input() siteIdFilter: number;\r\n @Input() parcelIdFilter: number;\r\n @Input() isEmbeddedMode: boolean = false;\r\n @Input() loading: boolean;\r\n @Output() loadingChange: EventEmitter = new EventEmitter();\r\n\r\n private readonly _GRID_SOURCE_OPTION_IMPORTED_VALUES: Compliance.NameValuePair = {\r\n name: 'Source Values',\r\n value: GridSourceOptionEnum.Imported\r\n };\r\n\r\n private readonly _GRID_SOURCE_OPTION_REPORTING_VALUES: Compliance.NameValuePair = {\r\n name: 'Reporting Values',\r\n value: GridSourceOptionEnum.Reporting\r\n };\r\n\r\n private readonly _IMPORTED_VALUES_FILTER_OPTION_LIEN: Compliance.NameValuePair = {\r\n name: 'Lien Date',\r\n value: 'imported-values-filter-lien'\r\n };\r\n\r\n private readonly _IMPORTED_VALUES_FILTER_OPTION_IMPORT: Compliance.NameValuePair = {\r\n name: 'Source File',\r\n value: 'imported-values-filter-import-file'\r\n };\r\n\r\n private readonly _IMPORTED_VALUES_GRID_ID: System.Guid = '454CB87C-DE80-4334-9CE0-49A828063D7E';\r\n private readonly _REPORTING_VALUES_GRID_ID: System.Guid = '5EF912A2-28AA-4143-A625-2CACDAD86F10';\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n assetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[];\r\n lienDate: AssetLienDate;\r\n assetGridTotalsRow: any;\r\n assetGridSelectedTotalsRow: any;\r\n selectedTotalsLoading: boolean = true;\r\n agGridReady: boolean;\r\n companyId: number;\r\n newCompanyId: number;\r\n companyName: string;\r\n canEdit: boolean = false;\r\n canViewRyanPrivateItems: boolean = false;\r\n hasComplianceFeaturesOverview: boolean = false;\r\n isInitialized: boolean = false;\r\n importFiles: Compliance.ImportFileInfoModel[] = null;\r\n gridId: System.Guid = this._REPORTING_VALUES_GRID_ID;\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n isBulkDeleteVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n limitOption: AssetLimitOption;\r\n advancedFilters: Compliance.AdvancedAssetFilters;\r\n totalsLoading: any;\r\n busyRefId: string = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n filterHref: string;\r\n siteName: string;\r\n parcelName: string;\r\n\r\n activeImportLongRunningProcessId: number;\r\n activeImportSelectedRowsCount: number;\r\n activeImportProcessedRowsCount: number;\r\n activeImportTimeRemaining: string;\r\n\r\n gridSourceOptions: Compliance.NameValuePair[] = [\r\n this._GRID_SOURCE_OPTION_IMPORTED_VALUES,\r\n this._GRID_SOURCE_OPTION_REPORTING_VALUES\r\n ];\r\n\r\n importGridFilterOptions: Compliance.NameValuePair[] = [\r\n this._IMPORTED_VALUES_FILTER_OPTION_LIEN,\r\n this._IMPORTED_VALUES_FILTER_OPTION_IMPORT\r\n ];\r\n\r\n selectedGridSourceOption = this._GRID_SOURCE_OPTION_REPORTING_VALUES;\r\n selectedImportGridFilterOption = this._IMPORTED_VALUES_FILTER_OPTION_LIEN;\r\n selectedImportFileId: number;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as AssetSummary).reportedAssetId),\r\n 'totals-row': (params) => params.data && params.data.totalsRow,\r\n 'selected-totals-row': (params) => params.data && params.data.selectedTotalsRow\r\n }\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const searchParams = this._gridDataSource.getSearchParamsWithoutPagination();\r\n\r\n if (this.selectedGridSourceOption === this._GRID_SOURCE_OPTION_REPORTING_VALUES){\r\n searchParams.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n if (!searchParams.selectedRows.selectAllRows && searchParams.selectedRows.selectedRows.length === 0){\r\n searchParams.selectedRows.selectAllRows = true;\r\n }\r\n }\r\n const exportModel: Compliance.AssetExportModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn,\r\n fileFormat,\r\n layoutName: this._layoutName,\r\n viewName: this.selectedGridSourceOption.name\r\n };\r\n\r\n let lrp$: Observable;\r\n\r\n switch (this.selectedGridSourceOption.value) {\r\n case GridSourceOptionEnum.Imported:\r\n lrp$ = this._assetRepository.startSourceAssetExport(this.companyId, exportModel);\r\n break;\r\n case GridSourceOptionEnum.Reporting:\r\n lrp$ = this._assetRepository.startReportingAssetExport(this.companyId, exportModel);\r\n break;\r\n }\r\n\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n const longRunningProcessTypeId = this.selectedGridSourceOption === this._GRID_SOURCE_OPTION_IMPORTED_VALUES\r\n ? Compliance.LongRunningProcessTypeEnum.ExportSourceAssets : Compliance.LongRunningProcessTypeEnum.ExportReportingAssets;\r\n\r\n return { longRunningProcessId, longRunningProcessTypeId };\r\n },\r\n canCancel: true,\r\n showFileFormatSelection: true,\r\n getDisabled: () => !this._gridDataSource || this._gridDataSource.isRefreshing\r\n };\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: AssetListAgGridDataSource;\r\n private _gridMultiSelectSub: Subscription;\r\n private _costAdjustmentTypes: Compliance.CostAdjustmentTypeModel[];\r\n private _autoUpdateTotals: boolean;\r\n private _busyRef: BusyIndicatorRef;\r\n private _destroy$: Subject = new Subject();\r\n private _layoutDestroy$: Subject = new Subject();\r\n private _assetImportInProgressModalOpened: boolean = false;\r\n private _layoutName: string;\r\n private _calculateTotalsClicked: boolean;\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n get importFilterOptionVisible(): boolean {\r\n return this.selectedGridSourceOption === this._GRID_SOURCE_OPTION_IMPORTED_VALUES && !this.isEmbeddedMode;\r\n }\r\n\r\n get lienDateVisible(): boolean {\r\n return this.selectedGridSourceOption === this._GRID_SOURCE_OPTION_REPORTING_VALUES ||\r\n this.selectedImportGridFilterOption === this._IMPORTED_VALUES_FILTER_OPTION_LIEN;\r\n }\r\n\r\n get furtherLimitVisible(): boolean {\r\n return this.selectedGridSourceOption === this._GRID_SOURCE_OPTION_REPORTING_VALUES && !this.isEmbeddedMode;\r\n }\r\n\r\n get importFileListVisible(): boolean {\r\n return (this.selectedGridSourceOption === this._GRID_SOURCE_OPTION_IMPORTED_VALUES &&\r\n this.selectedImportGridFilterOption === this._IMPORTED_VALUES_FILTER_OPTION_IMPORT) && !this.isEmbeddedMode;\r\n }\r\n\r\n get isLienDatePrior(): boolean {\r\n return this.lienDate?.lienDateType === Compliance.AssetLienDateTypeEnum.Prior;\r\n }\r\n\r\n get isLienDateExact(): boolean {\r\n return this.lienDate?.lienDateType === Compliance.AssetLienDateTypeEnum.Exact;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(ASSET_LIST_HELP);\r\n this._hotkeyService.add({ keys: 'alt.r' }).subscribe(() => this.gridTracker.getSelectedRowsCount() && this.bulkUpdate('r'));\r\n\r\n this._agGridPersistenceService.totalsRowAutomaticUpdate$(this.gridId as string)\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(autoUpdate => this._autoUpdateTotals = autoUpdate);\r\n this._agGridPersistenceService.currentGridLayoutApplied$(this.gridId as string)\r\n .pipe(takeUntil(this._layoutDestroy$))\r\n .subscribe(layoutName => this._layoutName = layoutName);\r\n\r\n if(this.companyIdFilter) {\r\n this.companyId = this.companyIdFilter;\r\n } else {\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n }\r\n\r\n if(!this.isEmbeddedMode && typeof this.siteIdFilter === 'undefined') {\r\n this.siteIdFilter = parseInt(this._routerService.getQuerystringParam('siteId'));\r\n }\r\n\r\n if(!this.isEmbeddedMode && typeof this.parcelIdFilter === 'undefined') {\r\n this.parcelIdFilter = parseInt(this._routerService.getQuerystringParam('parcelId'));\r\n }\r\n\r\n this.newCompanyId = this.companyId;\r\n\r\n let busyRef: BusyIndicatorRef;\r\n\r\n if(this.isEmbeddedMode) {\r\n this.loading = true;\r\n this.loadingChange.emit(true);\r\n\r\n if(typeof this.siteIdFilter !== 'undefined') {\r\n this.filterHref = this._routerService.getHrefFromState('assetListSiteFilter', { companyId: this.companyId, siteId: this.siteIdFilter });\r\n }\r\n else if(typeof this.parcelIdFilter !== 'undefined') {\r\n this.filterHref = this._routerService.getHrefFromState('assetListParcelFilter', { companyId: this.companyId, parcelId: this.parcelIdFilter });\r\n }\r\n }\r\n else {\r\n busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n }\r\n\r\n try {\r\n this.canEdit = await this._restrictService.hasCompanyPermission(this.companyId, Core.AccessRightsEnum.Write);\r\n this.canViewRyanPrivateItems = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n\r\n let sitePromise: Promise;\r\n\r\n if(!this.isEmbeddedMode && this.siteIdFilter) {\r\n sitePromise = lastValueFrom(this._siteService.getSiteName(this.siteIdFilter)).then(result => {\r\n this.siteName = result;\r\n });\r\n }\r\n\r\n let parcelPromise: Promise;\r\n\r\n if(!this.isEmbeddedMode && this.parcelIdFilter) {\r\n parcelPromise = this._parcelService.getView(this.parcelIdFilter, false).then(result => {\r\n this.parcelName = result.parcel.acctNum;\r\n });\r\n }\r\n\r\n let companyInfo: Core.CompanyModel;\r\n\r\n const companyPromise = this._companyService.getInfoForCompliance(this.companyId);\r\n companyPromise.then((company) => {\r\n this.companyName = company.companyName;\r\n companyInfo = company;\r\n });\r\n\r\n const assetDescriptorsPromise = lastValueFrom(this._companyAssetDescriptorRepository.getByCompanyId(this.companyId)).then(result => {\r\n this.assetDescriptors = result;\r\n });\r\n\r\n const costAdjustmentTypesPromise = lastValueFrom(this._costAdjustmentRepository.getTypes()).then(result => {\r\n this._costAdjustmentTypes = result;\r\n });\r\n\r\n await Promise.all([\r\n companyPromise,\r\n assetDescriptorsPromise,\r\n costAdjustmentTypesPromise,\r\n sitePromise,\r\n parcelPromise\r\n ]);\r\n\r\n this.breadcrumbs.push({\r\n name: this.companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n });\r\n\r\n if(this.siteName) {\r\n this.breadcrumbs.push({\r\n name: this.siteName,\r\n target: 'siteRedirect',\r\n options: { entityID: this.siteIdFilter }\r\n });\r\n }\r\n\r\n if(this.parcelName) {\r\n this.breadcrumbs.push({\r\n name: this.parcelName,\r\n target: 'parcelRedirect',\r\n options: { entityID: this.parcelIdFilter }\r\n });\r\n }\r\n\r\n if (!companyInfo.ppReturnPreparationAllowed && this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, companyInfo.instanceID)) {\r\n this._routerService.go('unauthorizedAccess', {});\r\n return Promise.resolve();\r\n }\r\n\r\n if (!this._restrictService.hasInstanceRight(InstanceRights.COMPANYDATAIMPORTSVIEW, companyInfo.instanceID)) {\r\n this.gridSourceOptions.splice(0, 1);\r\n }\r\n\r\n this.isInitialized = true;\r\n } finally {\r\n if(this.isEmbeddedMode) {\r\n this.loading = false;\r\n this.loadingChange.emit(false);\r\n }\r\n else {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n this._assetImportProgressService.importStarted$.pipe(takeUntil(this._destroy$))\r\n .subscribe(async x => {\r\n if (!x) {\r\n return;\r\n }\r\n\r\n console.log(`AssetList (OnImportStarted) ${this.activeImportLongRunningProcessId} === ${x.longRunningProcessId} selectedRowsCount=${x.selectedRowsCount}`);\r\n if (this.activeImportLongRunningProcessId === x.longRunningProcessId && this.activeImportSelectedRowsCount) {\r\n return;\r\n }\r\n\r\n this.activeImportLongRunningProcessId = x.longRunningProcessId;\r\n this.activeImportSelectedRowsCount = x.selectedRowsCount;\r\n\r\n await this.openAssetImportInProgressModal();\r\n });\r\n\r\n this._assetImportProgressService.importFinished$.pipe(takeUntil(this._destroy$))\r\n .subscribe(() => {\r\n this.activeImportLongRunningProcessId = null;\r\n this.activeImportSelectedRowsCount = 0;});\r\n\r\n this._assetImportProgressService.processedRows$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.activeImportProcessedRowsCount = x);\r\n\r\n this._assetImportProgressService.timeRemaining$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.activeImportTimeRemaining = x);\r\n\r\n this._assetImportProgressService.selectedRowsCountLoaded$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.activeImportSelectedRowsCount = x);\r\n\r\n await this._assetImportProgressService.initialize(this.companyId);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._assetImportProgressService.ngOnDestroy();\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._layoutDestroy$.next();\r\n this._layoutDestroy$.complete();\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n this._gridApi.showLoadingOverlay();\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this.gridTracker.setExternalFilterApplied(true);\r\n\r\n if (!this.agGridReady) {\r\n this._setGridColumns();\r\n }\r\n\r\n this.agGridReady = true;\r\n this._gridApi.hideOverlay();\r\n\r\n // notify the bulk update button (on the column tool panel) every time the grid selection changes\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(async () => {\r\n const isBulkUpdateVisible = this.canEdit && this.lienDate && this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n this.isBulkDeleteVisible$.next(isBulkUpdateVisible);\r\n if (this._calculateTotalsClicked) {\r\n await this._reloadTotals();\r\n }\r\n });\r\n\r\n this.gridTracker.isSelectingRange$.pipe(takeUntil(this._destroy$)).subscribe(loading => {\r\n if (!loading) {\r\n const isBulkUpdateVisible = this.canEdit && this.lienDate && this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n this.isBulkDeleteVisible$.next(isBulkUpdateVisible);\r\n } else {\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isBulkDeleteVisible$.next(false);\r\n }\r\n });\r\n }\r\n\r\n onLienDateChanged(lienDate: AssetLienDate): void {\r\n this.lienDate = lienDate;\r\n }\r\n\r\n onAdvancedOptionChanged(advancedFilters: Compliance.AdvancedAssetFilters): void {\r\n this.advancedFilters = advancedFilters;\r\n }\r\n\r\n onLimitOptionChanged(limitOption: AssetLimitOption): void {\r\n this.limitOption = limitOption;\r\n }\r\n\r\n onImportGridFilterChanged(importGridFilterOption: Compliance.NameValuePair): void {\r\n this.selectedImportGridFilterOption = importGridFilterOption;\r\n }\r\n\r\n onSelectedImportFileChanged(importFileId: number): void {\r\n this.selectedImportFileId = importFileId;\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n async bulkUpdate(hotkeyFocus?: string): Promise {\r\n const reportingAssetIds: number[] = [];\r\n this._gridApi.forEachNode(x => {\r\n if (x.data) {\r\n reportingAssetIds.push(x.data.reportingAssetId);\r\n }\r\n });\r\n\r\n const params: AssetBulkUpdateParams = {\r\n companyId: this.companyId,\r\n lienDate: this.lienDate && this.lienDate,\r\n reportingAssetIds: reportingAssetIds,\r\n selection: this.gridTracker.getSelectedRowsModel(),\r\n selectedCount: this.gridTracker.getSelectedRowsCount(),\r\n assetListLastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp,\r\n hotkeyFocus: hotkeyFocus,\r\n siteId: this.siteIdFilter,\r\n parcelId: this.parcelIdFilter\r\n };\r\n\r\n const result = await this._modalService.showAsync(AssetBulkUpdateComponent, params, 'modal-lg');\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._refreshRows(result);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async refresh(): Promise {\r\n if (this.selectedGridSourceOption.value === GridSourceOptionEnum.Imported) {\r\n await this._refreshImportFiles();\r\n }\r\n\r\n await this._refreshDataSource();\r\n }\r\n\r\n async addAsset(): Promise {\r\n const params: AssetDetailsParams = {\r\n reportingAssetId: null,\r\n assetId: null,\r\n lienDate: this.lienDate && this.lienDate.date,\r\n canEdit: this.canEdit,\r\n createNewAsset: true,\r\n topLevelCompanyId: this.companyId,\r\n newAssetCompanyId: this.newCompanyId || this.companyId,\r\n assetDescriptors: this.assetDescriptors,\r\n canViewRyanPrivateItems: this.canViewRyanPrivateItems\r\n };\r\n\r\n const result = await this._modalService.showAsync(AssetDetailsComponent, params, 'modal-xl');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (result.hasChanges) {\r\n this.newCompanyId = result.newAssetCompanyId;\r\n this._refreshDataSource();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async setSelectedGridSourceOption(value: Compliance.NameValuePair): Promise {\r\n if (this.selectedGridSourceOption === value) {\r\n return;\r\n }\r\n\r\n if (this._gridDataSource) {\r\n this._gridDataSource.clearTotals();\r\n this._gridDataSource = null;\r\n this._gridApi.setDatasource([] as any);\r\n }\r\n\r\n this.selectedGridSourceOption = value;\r\n this.gridId = this._getGridIdBySource(this.selectedGridSourceOption.value);\r\n this._setGridColumns();\r\n\r\n this._layoutDestroy$.next();\r\n this._agGridPersistenceService.currentGridLayoutApplied$(this.gridId as string)\r\n .pipe(takeUntil(this._layoutDestroy$))\r\n .subscribe(layoutName => this._layoutName = layoutName);\r\n\r\n if ((this.selectedGridSourceOption.value === GridSourceOptionEnum.Imported) && !this.importFiles) {\r\n await this._refreshImportFiles();\r\n }\r\n }\r\n\r\n getListViewHelpContentId(viewName: string): string {\r\n switch(viewName) {\r\n case 'Reporting Values':\r\n return 'asset-list.reporting-values-view';\r\n case 'Imported Values':\r\n return 'asset-list.imported-values-view';\r\n default:\r\n return '';\r\n }\r\n }\r\n\r\n async bulkDelete(): Promise {\r\n const confirmOptions = {\r\n message: 'Are you sure you want to delete selected assets?',\r\n buttons: MessageBoxButtons.OKCancel\r\n } as MessageBoxOptions;\r\n\r\n const result = await this._messageBoxService.open(confirmOptions);\r\n\r\n if (result === MessageBoxResult.OK) {\r\n\r\n const params: DeleteConfirmationComponentParams = {\r\n item: 'Assets',\r\n message: 'Are you sure you want to delete selected assets? If you choose to proceed, all information related to assets will be removed and cannot be recovered.'\r\n };\r\n\r\n const deleteResult = await this._modalService.showAsync(DeleteConfirmationComponent, params, 'modal-md');\r\n\r\n if (deleteResult) {\r\n this._showBusyIndicator('Bulk Delete', 'Deleting assets', null, false, false);\r\n\r\n const model: Compliance.AssetBulkDeleteModel = {\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp,\r\n selectAllRows: this.gridTracker.getSelectedRowsModel().selectAllRows,\r\n selectedRows: this.gridTracker.getSelectedRowsModel().selectedRows,\r\n lienDate: this.lienDate.date,\r\n filterBySiteId: this.siteIdFilter,\r\n filterByParcelId: this.parcelIdFilter\r\n };\r\n\r\n try {\r\n const longRunningProcessId = await lastValueFrom(this._assetRepository.startBulkDelete(this.companyId, model));\r\n await this._busyRef.setLongRunningProcessId(longRunningProcessId);\r\n }\r\n catch (e) {\r\n await this._hideBusyIndicator();\r\n return Promise.reject(e);\r\n }\r\n }\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async openAssetImportInProgressModal(): Promise {\r\n if (!this._assetImportInProgressModalOpened) {\r\n this._assetImportInProgressModalOpened = true;\r\n\r\n const params: AssetImportProgressParams = {\r\n assetImportProgressService: this._assetImportProgressService\r\n };\r\n\r\n try {\r\n await this._modalService.showAsync(AssetImportProgressComponent, params, 'modal-md');\r\n } finally {\r\n this._assetImportInProgressModalOpened = false;\r\n }\r\n }\r\n }\r\n\r\n private async _refreshImportFiles(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n const importContentTypes = [Compliance.ImportContentTypeIdEnum.Assets, Compliance.ImportContentTypeIdEnum.AssetUpdatesOnly];\r\n const result = await lastValueFrom(this._entityImportRepository.getByCompanyTransferred(this.companyId, importContentTypes));\r\n this.importFiles = result.data;\r\n this.importFiles.sort((x, y) => y.importFileId - x.importFileId)\r\n\r\n let importFile = _.find(this.importFiles, x => x.importFileId === this.selectedImportFileId);\r\n\r\n if (!importFile) {\r\n importFile = _.first(this.importFiles);\r\n }\r\n\r\n this.selectedImportFileId = importFile && importFile.importFileId;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private async _viewAssetDetails(params: ICellRendererParamsForAssetListGridAction): Promise {\r\n const assetSummary = params.data as AssetSummary;\r\n\r\n const inputParams: AssetDetailsParams = {\r\n reportingAssetId: assetSummary.reportingAssetId,\r\n assetId: assetSummary.assetId,\r\n lienDate: this.lienDate.date,\r\n canEdit: this.canEdit,\r\n createNewAsset: false,\r\n topLevelCompanyId: this.companyId,\r\n assetDescriptors: this.assetDescriptors,\r\n newAssetCompanyId: assetSummary.companyId,\r\n canViewRyanPrivateItems: this.canViewRyanPrivateItems\r\n };\r\n\r\n const result = await this._modalService.showAsync(AssetDetailsComponent, inputParams, 'modal-xl');\r\n\r\n if (!(result && result.hasChanges)) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (result.savedModels && result.savedModels.length > 0) {\r\n const allNodesOnPage: RowNode[] = [];\r\n this._gridApi.forEachNode(x => {\r\n const gridRow = x.data as AssetSummary;\r\n if (gridRow.reportedAssetId) {\r\n const row = result.savedModels.find(y => y.reportingAsset.reportingAssetId == gridRow.reportedAssetId);\r\n if (row) {\r\n gridRow.updateModel(row);\r\n }\r\n allNodesOnPage.push(x);\r\n }\r\n });\r\n this._gridApi.redrawRows({rowNodes: allNodesOnPage});\r\n\r\n if (this._autoUpdateTotals) {\r\n this._handleTotalsUpdate(result.totalsModel);\r\n this._gridDataSource.hasLatestTotals = true;\r\n } else {\r\n this._handleTotalsUpdate(null);\r\n this._gridDataSource.hasLatestTotals = false;\r\n }\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private async _refreshRows(rowData: Compliance.QueryResultWithTotalsModel): Promise {\r\n this.gridTracker.clear(false);\r\n\r\n this._handleTotalsUpdate(null);\r\n this._gridDataSource.hasLatestTotals = false;\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isBulkDeleteVisible$.next(false);\r\n\r\n this._gridDataSource.clearTotals();\r\n\r\n const rowNodes: RowNode[] = [];\r\n this._gridApi.forEachNode(x => {\r\n const gridRow = x.data as AssetSummary;\r\n if (gridRow.reportedAssetId) {\r\n const row = rowData.data.find(y => y.reportingAsset.reportingAssetId === gridRow.reportedAssetId);\r\n if (row) {\r\n gridRow.updateModel(row);\r\n rowNodes.push(x);\r\n }\r\n }\r\n });\r\n\r\n this._gridApi.redrawRows({ rowNodes: rowNodes });\r\n\r\n this._handleTotalsUpdate(rowData.totals);\r\n this._gridDataSource.hasLatestTotals = true;\r\n\r\n this._gridDataSource.lastModifiedTimestamp = rowData.lastModifiedTimestamp;\r\n }\r\n\r\n private async _refreshDataSource(): Promise {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isBulkDeleteVisible$.next(false);\r\n\r\n this._gridDataSource.clearTotals();\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return false;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isBulkDeleteVisible$.next(false);\r\n\r\n const dataSourceParams = (): AssetListDataSourceParams => {\r\n return {\r\n companyId: this.companyId,\r\n lienDate: this.lienDateVisible ? this.lienDate : { date: null, useStateLienDate: false, lienDateType: Compliance.AssetLienDateTypeEnum.Prior } as AssetLienDate,\r\n importId: this.importFileListVisible ? this.selectedImportFileId : null,\r\n limitOption: this.furtherLimitVisible ? this.limitOption : { invalidCostAllocations: false, noReportingParcel: false, overrideFilterColumns: [] } as AssetLimitOption,\r\n advancedFilters: this.advancedFilters && !this.isEmbeddedMode ? this.advancedFilters : null,\r\n fetchSourceAssets: this.selectedGridSourceOption === this._GRID_SOURCE_OPTION_IMPORTED_VALUES, // fetch source vs reporting assets\r\n parcelId: this.parcelIdFilter,\r\n siteId: this.siteIdFilter\r\n };\r\n };\r\n\r\n this._gridDataSource = new AssetListAgGridDataSource(\r\n this._gridApi,\r\n this._assetRepository,\r\n dataSourceParams,\r\n this._keyValueDisplayPipe,\r\n this._handleTotalsUpdate,\r\n () => this._autoUpdateTotals\r\n );\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n\r\n return true;\r\n }\r\n\r\n private _setGridColumns(): void {\r\n this._gridApi.setColumnDefs([]);\r\n const columns = this._getGridColumnsBySource(this.selectedGridSourceOption.value);\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setFilterModel(null);\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: this.selectedGridSourceOption.value === GridSourceOptionEnum.Imported\r\n ? `${Compliance.AssetPropertyEnum.SourceAssetNumber}`\r\n : `${Compliance.AssetPropertyEnum.ReportingAssetNumber}`,\r\n sort: 'asc'\r\n }\r\n ];\r\n this._gridApi.setSortModel(defaultSortModel);\r\n }\r\n\r\n private _getGridColumnsBySource(gridSourceOption: GridSourceOptionEnum): ColDef[] {\r\n const columns: ColDef[] = [];\r\n\r\n const effectiveDateColDef: ColDef = {\r\n colId: `${Compliance.AssetPropertyEnum.EffectiveDate}`,\r\n headerName: 'Effective Date',\r\n toolPanelClass: 'Asset',\r\n field: 'effectiveDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._datePipe.transform(params.value, true) : ''\r\n };\r\n\r\n const actionsColDef: ColDef = {\r\n colId: 'grid-column-actions',\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n pinned: 'right',\r\n lockVisible: true,\r\n sortable: false,\r\n cellRendererFramework: AssetListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this._viewAssetDetails.bind(this),\r\n canViewRyanPrivateItems: this.canViewRyanPrivateItems\r\n } as ICellRendererParamsForAssetListGridAction,\r\n pinnedRowCellRenderer: () => {return '';}\r\n };\r\n\r\n // get asset columns for specified source\r\n switch (gridSourceOption) {\r\n case GridSourceOptionEnum.Imported:\r\n columns.push(\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceAssetNumber}`,\r\n headerName: 'S. Asset Number',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceAssetNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridTextWithTotalsUpdateCellRendererComponent,\r\n cellRendererParams: {\r\n getTooltipText: (params: AgGridTextWithTotalsUpdateCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n\r\n return `${asset.sourceAssetNumber}`;\r\n },\r\n totalsNeedRefresh: () => !this._gridDataSource.hasLatestTotals,\r\n onUpdateTotalsClicked: () => {\r\n this._calculateTotalsClicked = true;\r\n this._gridDataSource.getAllRowTotals(this._gridApi.getCacheBlockState(), true);\r\n }\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.CompanyCode}`,\r\n headerName: 'Company Code',\r\n toolPanelClass: 'Asset',\r\n field: 'companyCode',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.CompanyName}`,\r\n headerName: 'Company Name',\r\n toolPanelClass: 'Asset',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Asset Ownership Type',\r\n toolPanelClass: 'Asset',\r\n field: 'assetOwnershipType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceDescription}`,\r\n headerName: 'S. Description',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceSiteNameOrNumber}`,\r\n headerName: 'S. Site',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceSiteDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!(asset && asset.sourceSite)) {\r\n return '';\r\n }\r\n return `#/site/${asset.sourceSite.siteID}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceSiteName}`,\r\n headerName: 'S. Site Name',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceSiteName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!(asset && asset.sourceSite)) {\r\n return '';\r\n }\r\n return `#/site/${asset.sourceSite.siteID}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceSiteNumber}`,\r\n headerName: 'S. Site Number',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceSiteNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!(asset && asset.sourceSite)) {\r\n return '';\r\n }\r\n return `#/site/${asset.sourceSite.siteID}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceSiteAddress}`,\r\n headerName: 'S. Site Address',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceSiteAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceState}`,\r\n headerName: 'S. State',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceState',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceGLAccountNameOrNumber}`,\r\n headerName: 'S. G/L Account',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceGlAccountDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceGLAccountNumber}`,\r\n headerName: 'S. G/L Account Number',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceGlAccountNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourcePriorCost}`,\r\n headerName: 'S. Prior Cost',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourcePriorCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceCost}`,\r\n headerName: 'S. Cost',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell'\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceCostChange}`,\r\n headerName: 'S. Cost Change',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceCostChange',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceNetBookValue}`,\r\n headerName: 'S. Net Book Value',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceNetBookValue',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceAdjustedCost}`,\r\n headerName: 'S. Adj. Cost',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceAdjustedCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell'\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceAcqDate}`,\r\n headerName: 'S. Acquisition Date',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceAcqDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true)\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceDisposedDate}`,\r\n headerName: 'S. Disposed Date',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceDisposedDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true)\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Location Name',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseLocationName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Location Address',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease City',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseCity',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease State',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseState',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Zip',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseZip',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Term (Months)',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseTermInMonths',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell'\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Monthly Payment',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseMonthlyPayment',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell'\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Type',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseTypeId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Asset',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseAssetId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Number',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Billing Name',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseBillingName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Billing Address',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseBillingAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Billing City',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseBillingCity',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Billing State',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseBillingState',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Billing Zip',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseBillingZip',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Start Date',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseStartDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true)\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease End Date',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseEndDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true)\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Customer ID',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseClientId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'S. Jan Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryJan',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Feb Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryFeb',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Mar Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryMar',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Apr Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryApr',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. May Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryMay',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Jun Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryJun',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Jul Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryJul',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Aug Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryAug',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Sep Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventorySep',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Oct Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryOct',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Nov Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryNov',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Dec Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryDec',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Avg Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryAvr',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Aggregated Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryAggregatedString',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n sortable: false,\r\n cellClass: 'ag-text-cell',\r\n hide: true\r\n } as ColDef,\r\n effectiveDateColDef,\r\n actionsColDef\r\n );\r\n break;\r\n case GridSourceOptionEnum.Reporting:\r\n columns.push(\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'reportedAssetId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingAssetNumber}`,\r\n headerName: 'Asset Number',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedAssetNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n lockVisible: true,\r\n lockPosition: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n suppressMovable: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridTextWithTotalsUpdateCellRendererComponent,\r\n cellRendererParams: {\r\n getTooltipText: (params: AgGridTextWithTotalsUpdateCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n\r\n return `${asset.reportedAssetNumber}${asset.reportingIsPerpetual ? ' (Perpetual)' : ''}`;\r\n },\r\n totalsNeedRefresh: () => !this._gridDataSource?.hasLatestTotals,\r\n onUpdateTotalsClicked: () => {\r\n this._calculateTotalsClicked = true;\r\n this._gridDataSource?.getAllRowTotals(this._gridApi.getCacheBlockState(), true);\r\n }\r\n },\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedAssetNumberHasOverride ? 'ws-override' : '';\r\n },\r\n valueFormatter: (params) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n\r\n return `${asset.reportedAssetNumber}${asset.reportingIsPerpetual ? ' (P)' : ''}`;\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceAssetNumber}`,\r\n headerName: 'S. Asset Number',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceAssetNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingOldAssetNumber}`,\r\n headerName: 'Old Asset Number',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedOldAssetNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedOldAssetNumberHasOverride ? 'ws-override' : '';\r\n },\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceOldAssetNumber}`,\r\n headerName: 'S. Old Asset Number',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceOldAssetNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceDescription}`,\r\n headerName: 'S. Description',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingDescription}`,\r\n headerName: 'Description',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedDescription',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedDescriptionHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'Change Status',\r\n toolPanelClass: 'Asset',\r\n field: 'changeStatus',\r\n cellRendererFramework: AssetChangeIconCellRendererComponent,\r\n width: 120,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n sortable: false,\r\n cellRendererParams: {}\r\n },\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.CompanyCode}`,\r\n headerName: 'Company Code',\r\n toolPanelClass: 'Asset',\r\n field: 'companyCode',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset\r\n && asset.getModel().sourceAsset\r\n && asset.getModel().sourceAsset.sourceCompanyCode !== asset.getModel().companyCode ? 'ws-calculated' : '';\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.CompanyName}`,\r\n headerName: 'Company Name',\r\n toolPanelClass: 'Asset',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset\r\n && asset.getModel().sourceAsset\r\n && asset.getModel().sourceAsset.sourceCompanyName !== asset.getModel().companyName ? 'ws-calculated' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'Asset Ownership Type',\r\n toolPanelClass: 'Asset',\r\n field: 'assetOwnershipType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Asset Verification Reason',\r\n toolPanelClass: 'Asset',\r\n field: 'assetVerificationReason',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceState}`,\r\n headerName: 'S. State',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceState',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.State}`,\r\n headerName: 'State',\r\n toolPanelClass: 'Asset',\r\n field: 'state',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.AssessorName}`,\r\n headerName: 'Assessor',\r\n toolPanelClass: 'Asset',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.AssessorId}`,\r\n headerName: 'Assessor ID',\r\n toolPanelClass: 'Asset',\r\n field: 'assessorId',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n return `#/assessor/${asset.assessorId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceSiteNameOrNumber}`,\r\n headerName: 'S. Site',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceSiteDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!(asset && asset.sourceSite)) {\r\n return '';\r\n }\r\n return `#/site/${asset.sourceSite.siteID}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingSiteNameOrNumber}`,\r\n headerName: 'Site',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedSiteDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedSiteHasOverride ? 'ws-override' : '';\r\n },\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n return `#/site/${asset.reportedSiteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceSiteName}`,\r\n headerName: 'S. Site Name',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceSiteName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!(asset && asset.sourceSite)) {\r\n return '';\r\n }\r\n return `#/site/${asset.sourceSite.siteID}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingSiteName}`,\r\n headerName: 'Site Name',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedSiteName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedSiteHasOverride ? 'ws-override' : '';\r\n },\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n return `#/site/${asset.reportedSiteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceSiteNumber}`,\r\n headerName: 'S. Site Number',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceSiteNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!(asset && asset.sourceSite)) {\r\n return '';\r\n }\r\n return `#/site/${asset.sourceSite.siteID}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingSiteNumber}`,\r\n headerName: 'Site Number',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedSiteNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedSiteHasOverride ? 'ws-override' : '';\r\n },\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n return `#/site/${asset.reportedSiteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SiteAddress}`,\r\n headerName: 'Site Address',\r\n toolPanelClass: 'Asset',\r\n field: 'siteAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedSiteAddressHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceSiteAddress}`,\r\n headerName: 'S. Site Address',\r\n toolPanelClass: 'Asset',\r\n field: 'sourceSiteAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingIsAnchored}`,\r\n headerName: 'Is Anchored',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedIsAnchored',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return '';\r\n }\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingParcel}`,\r\n headerName: 'Parcel',\r\n toolPanelClass: 'Asset',\r\n field: 'parcelDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedParcelHasOverride ? 'ws-override' : '';\r\n },\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n return `#/parcel/${asset.reportedParcelId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ParcelSystemId}`,\r\n headerName: 'Parcel System ID',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedParcelId',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n return `#/parcel/${asset.reportedParcelId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingIsLocked}`,\r\n headerName: 'Is Locked',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedIsLocked',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return '';\r\n }\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceGLAccountNameOrNumber}`,\r\n headerName: 'S. G/L Account',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceGlAccountDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingGLAccountNameOrNumber}`,\r\n headerName: 'G/L Account',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedGlAccountDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedGlAccountHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceGLAccountNumber}`,\r\n headerName: 'S. G/L Account Number',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceGlAccountNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingGLAccountNumber}`,\r\n headerName: 'G/L Account Number',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedGlAccountNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedGlAccountHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.AssetClassificationName}`,\r\n headerName: 'Classification',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedAssetClassificationDisplay',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.assetClassificationHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceCost}`,\r\n headerName: 'S. Cost',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceAdjustedCost}`,\r\n headerName: 'S. Adj. Cost',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceAdjustedCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourcePriorCost}`,\r\n headerName: 'S. Prior Cost',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourcePriorCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.PriorCost}`,\r\n headerName: 'Prior Cost',\r\n toolPanelClass: 'Asset',\r\n field: 'priorCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n if (asset && asset.priorCostHasOverride) {\r\n return 'ag-numeric-cell ws-override';\r\n } else {\r\n return 'ag-numeric-cell';\r\n }\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingCost}`,\r\n headerName: 'Cost (reportable)',\r\n toolPanelClass: 'Asset',\r\n field: 'cost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n if (asset && asset.alternativeCostDescriptorId) {\r\n return 'ag-numeric-cell ws-calculated';\r\n } else if (asset && asset.hasCostAdjustment && asset.hasCostAdjustment() && !asset.reportedCostHasOverride) {\r\n return 'ag-numeric-cell ws-calculated';\r\n } else if (asset && asset.reportedCostHasOverride) {\r\n return 'ag-numeric-cell ws-override';\r\n } else {\r\n return 'ag-numeric-cell';\r\n }\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceCostChange}`,\r\n headerName: 'S. Cost Change',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceCostChange',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.PriorCost}`,\r\n headerName: 'Cost Change',\r\n toolPanelClass: 'Asset',\r\n field: 'costChange',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n if (asset && asset.costChangeHasOverride) {\r\n return 'ag-numeric-cell ws-override';\r\n } else {\r\n return 'ag-numeric-cell';\r\n }\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.AlternativeCostDescriptorName}`,\r\n headerName: 'Alternate Cost Source',\r\n toolPanelClass: 'Asset',\r\n field: 'alternativeCostDescriptorName',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingAreSplitAllocationsValid}`,\r\n headerName: 'Cost Alloc. Valid',\r\n toolPanelClass: 'Asset',\r\n field: 'areSplitAllocationsValid',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return '';\r\n }\r\n },\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.areSplitAllocationsValid === false ? 'cell-validation-error' : '';\r\n }\r\n },\r\n {\r\n headerName: 'S. Net Book Value',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceNetBookValue',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => params.value || params.value === 0 ? this._decimalPipe.transform(params.value, '1.2-2') : null,\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Net Book Value',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedNetBookValue',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => params.value || params.value === 0 ? this._decimalPipe.transform(params.value, '1.2-2') : null,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedNetBookValueHasOverride ? 'ag-numeric-cell ws-override' : 'ag-numeric-cell';\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingSplitAllocationPercentage}`,\r\n headerName: 'Split Allocation %',\r\n toolPanelClass: 'Asset',\r\n field: 'splitAllocationPercentage',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceAcqDate}`,\r\n headerName: 'S. Acquisition Date',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceAcqDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true),\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingAcqDate}`,\r\n headerName: 'Acquisition Date',\r\n toolPanelClass: 'Asset',\r\n field: 'acqDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedAcqDateHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.AlternativeAcqDateDescriptorName}`,\r\n headerName: 'Alternate Acquisition Date Source',\r\n toolPanelClass: 'Asset',\r\n field: 'alternativeAcqDateDescriptorName',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.SourceDisposedDate}`,\r\n headerName: 'S. Disposed Date',\r\n toolPanelClass: 'Source Values',\r\n field: 'sourceDisposedDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true),\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingDisposedDate}`,\r\n headerName: 'Disposed Date',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedDisposedDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._datePipe.transform(params.value, true) : '',\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedDisposedDateHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Compliance.AssetPropertyEnum.ReportingDoNotPotentiallyDispose}`,\r\n headerName: 'Do Not Potentially Dispose',\r\n toolPanelClass: 'Asset',\r\n field: 'reportedDoNotPotentiallyDispose',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return '';\r\n }\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'Perpetual',\r\n toolPanelClass: 'Asset',\r\n field: 'reportingIsPerpetual',\r\n width: AgGridColumns.textColumnMedWidth,\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n\r\n return asset.reportingIsPerpetual ? 'Yes' : 'No';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Location Name',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseLocationName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Location Name',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseLocationName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseLocationNameHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Location Address',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Location Address',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseAddress',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseAddressHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease City',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseCity',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease City',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseCity',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseCityHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease State',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseState',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease State',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseState',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseStateHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Zip',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseZip',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Zip',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseZip',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseZipHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Term (Months)',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseTermInMonths',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell'\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Term (Months)',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseTermInMonths',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseTermInMonthsHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Monthly Payment',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseMonthlyPayment',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell'\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Monthly Payment',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseMonthlyPayment',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseMonthlyPaymentHasOverride ? 'ag-numeric-cell ws-override' : 'ag-numeric-cell';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Type',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseTypeId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Type',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseTypeId',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseTypeIdHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Asset',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseAssetId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Asset',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseAssetId',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseAssetIdHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Number',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Number',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseNumber',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseNumberHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Billing Name',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseBillingName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Billing Name',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseBillingName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseBillingNameHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Billing Address',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseBillingAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Billing Address',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseBillingAddress',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseBillingAddressHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Billing City',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseBillingCity',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Billing City',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseBillingCity',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseBillingCityHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Billing State',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseBillingState',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Billing State',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseBillingState',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseBillingStateHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Billing Zip',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseBillingZip',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Billing Zip',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseBillingZip',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseBillingZipHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Start Date',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseStartDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true)\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Start Date',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseStartDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._datePipe.transform(params.value, true) : '',\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseStartDateHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease End Date',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseEndDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true)\r\n } as ColDef,\r\n {\r\n headerName: 'Lease End Date',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseEndDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._datePipe.transform(params.value, true) : '',\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseEndDateHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Lease Customer ID',\r\n toolPanelClass: 'Source Leasing',\r\n field: 'sourceLeaseClientId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n headerName: 'Lease Customer ID',\r\n toolPanelClass: 'Leasing',\r\n field: 'reportedLeaseClientId',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedLeaseClientIdHasOverride ? 'ws-override' : '';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'User Created',\r\n toolPanelClass: 'Asset',\r\n field: 'isUserCreated',\r\n width: AgGridColumns.textColumnMedWidth,\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n\r\n return asset.isUserCreated ? 'Yes' : 'No';\r\n }\r\n } as ColDef,\r\n {\r\n headerName: 'S. Jan Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryJan',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Jan Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryJan',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryJanHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Feb Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryFeb',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Feb Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryFeb',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryFebHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Mar Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryMar',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Mar Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryMar',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryMarHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Apr Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryApr',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Apr Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryApr',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryAprHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. May Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryMay',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'May Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryMay',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryMayHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Jun Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryJun',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Jun Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryJun',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryJunHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Jul Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryJul',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Jul Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryJul',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryJulHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Aug Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryAug',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Aug Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryAug',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryAugHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Sep Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventorySep',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Sep Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventorySep',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventorySepHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Oct Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryOct',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Oct Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryOct',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryOctHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Nov Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryNov',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Nov Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryNov',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryNovHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Dec Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryDec',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Dec Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryDec',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.reportedInventoryDecHasOverride\r\n ? 'ag-numeric-cell ws-override'\r\n : 'ag-numeric-cell';\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Avg Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryAvr',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Avg Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryAvrCalculated',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n let cellClass: string = 'ag-numeric-cell';\r\n\r\n if (asset) {\r\n if (asset.reportedInventoryAvrIsCalculated){\r\n cellClass += ' ws-calculated';\r\n } else if (asset.reportedInventoryAvrHasOverride){\r\n cellClass += ' ws-override';\r\n }\r\n }\r\n\r\n return cellClass;\r\n },\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'S. Aggregated Balance',\r\n toolPanelClass: 'Source Inventory',\r\n field: 'sourceInventoryAggregatedString',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n sortable: false,\r\n cellClass: 'ag-text-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n headerName: 'Aggregated Balance',\r\n toolPanelClass: 'Inventory',\r\n field: 'reportedInventoryAggregatedString',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n sortable: false,\r\n cellClass: 'ag-text-cell',\r\n hide: true\r\n } as ColDef,\r\n effectiveDateColDef,\r\n actionsColDef\r\n );\r\n break;\r\n default:\r\n throw new Error('An unknown source was specified for retrieving asset values.');\r\n }\r\n\r\n // get descriptor columns (user defined) and config by source\r\n this.assetDescriptors.forEach(x => {\r\n let columnWidth: number;\r\n let filterName: string;\r\n let filterParams: any;\r\n let floatingFilterComponentParams: any;\r\n let valueFormatter: any;\r\n let floatingFilterComponentFramework: any;\r\n\r\n switch (x.descriptor.fieldType) {\r\n case Core.DescriptorFieldTypes.Date:\r\n columnWidth = AgGridColumns.dateColumnWidth;\r\n filterName = 'agDateColumnFilter';\r\n filterParams = AgGridFilterParams.dateFilterParamsWithBlankOptionsParams;\r\n floatingFilterComponentParams = AgGridFilterParams.dateFloatingFilterParams;\r\n valueFormatter = (y) => {\r\n if (!y.value) {\r\n return '';\r\n }\r\n\r\n const d = new Date(y.value);\r\n return this._datePipe.transform(d, true);\r\n };\r\n break;\r\n case Core.DescriptorFieldTypes.Currency:\r\n case Core.DescriptorFieldTypes.Number:\r\n columnWidth = AgGridColumns.numericColumnWidth;\r\n filterName = 'agNumberColumnFilter';\r\n filterParams = AgGridFilterParams.numberFilterWithBlankOptionsParams;\r\n floatingFilterComponentParams = AgGridFilterParams.numberFloatingFilterParams;\r\n valueFormatter = (params) => {\r\n if (x.descriptor.format) {\r\n switch (x.descriptor.format) {\r\n case '(0000)':\r\n return params.value;\r\n case '(#,###)':\r\n case '(#,###,####)':\r\n return this._decimalPipe.transform(params.value, '1.0-0');\r\n case '(#,###,####.00)':\r\n return this._decimalPipe.transform(params.value, '1.2-2');\r\n case '(#,###,####.000)':\r\n return this._decimalPipe.transform(params.value, '1.3-3');\r\n default:\r\n // fallback to old code if format property does not exist\r\n return this._decimalPipe.transform(params.value, '1.2-2');\r\n }\r\n } else {\r\n // fallback to old code if format property does not exist\r\n return this._decimalPipe.transform(params.value, '1.2-2');}\r\n };\r\n break;\r\n case Core.DescriptorFieldTypes.Text:\r\n case Core.DescriptorFieldTypes.Picklist:\r\n columnWidth = AgGridColumns.textColumnMedWidth;\r\n filterName = 'agTextColumnFilter';\r\n filterParams = AgGridFilterParams.textFilterWithBlankOptionsParams;\r\n floatingFilterComponentParams = AgGridFilterParams.textFloatingFilterParams;\r\n break;\r\n case Core.DescriptorFieldTypes.YesNo:\r\n columnWidth = AgGridColumns.textColumnMedWidth;\r\n filterName = 'agYesNoColumnFilter';\r\n filterParams = AgGridFilterParams.yesNoFilterWithBlankOptionsParams;\r\n floatingFilterComponentFramework = AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams = AgGridFilterParams.textFloatingFilterParams;\r\n valueFormatter = (y) => {\r\n let result = '';\r\n\r\n if (y.value === 0){\r\n result = 'No';\r\n } else if (y.value === 1){\r\n result = 'Yes';\r\n }\r\n\r\n return result;\r\n };\r\n break;\r\n }\r\n\r\n let colDef: ColDef;\r\n\r\n switch (gridSourceOption) {\r\n case GridSourceOptionEnum.Imported:\r\n colDef = this._getColDef(`S. ${x.descriptor.name}`, x.descriptor.assetUsage !== Core.DescriptorUsageEnum.Frequent,\r\n columnWidth, filterName, filterParams, floatingFilterComponentParams, floatingFilterComponentFramework, valueFormatter,\r\n `source${x.columnName}`, `source${x.columnName}`, 'Source Values');\r\n columns.push(colDef);\r\n break;\r\n case GridSourceOptionEnum.Reporting:\r\n colDef = this._getColDef(`S. ${x.descriptor.name}`, x.descriptor.assetUsage !== Core.DescriptorUsageEnum.Frequent,\r\n columnWidth, filterName, filterParams, floatingFilterComponentParams, floatingFilterComponentFramework, valueFormatter,\r\n `source${x.columnName}`, `source${x.columnName}`, 'Source Values');\r\n columns.push(colDef);\r\n\r\n colDef = this._getColDef(x.descriptor.name, x.descriptor.assetUsage !== Core.DescriptorUsageEnum.Frequent,\r\n columnWidth, filterName, filterParams, floatingFilterComponentParams, floatingFilterComponentFramework, valueFormatter,\r\n `reported${x.columnName}`, `reported${x.columnName}`, 'Asset');\r\n colDef.cellClass = (params: ICellRendererParams): string => {\r\n const asset = params.data as AssetSummary;\r\n return asset && asset.slotColumnHasOverride && asset.slotColumnHasOverride(x.columnName) ? 'ws-override' : '';\r\n };\r\n columns.push(colDef);\r\n break;\r\n default:\r\n throw new Error('An unknown source was specified for retrieving asset values.');\r\n }\r\n });\r\n\r\n this._costAdjustmentTypes.forEach(x => {\r\n const colDef = {\r\n colId: `reportedCostAdjustmentAmount${x.costAdjustmentTypeId}`,\r\n headerName: `${x.typeName } Cost Adj. Amt.`,\r\n toolPanelClass: 'Asset',\r\n field: `reportedCostAdjustmentAmount${x.costAdjustmentTypeId}`,\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n suppressSizeToFit: false,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value || 0, '1.2-2'),\r\n cellClass: 'ag-numeric-cell'\r\n } as ColDef;\r\n columns.push(colDef);\r\n });\r\n\r\n const lastReturnColDef = {\r\n colId: `${Compliance.AssetPropertyEnum.LastReturnDescription}`,\r\n headerName: 'Last Return',\r\n toolPanelClass: 'Asset',\r\n field: 'lastReturnDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'asset-list.view-last-return',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const asset = params.data as AssetSummary;\r\n if (!asset) {\r\n return '';\r\n }\r\n return `#/returnBatch/${asset.lastReturnId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n };\r\n columns.push(lastReturnColDef);\r\n\r\n return columns;\r\n }\r\n\r\n private _getColDef(headerName: string, hide: boolean, columnWidth: number, filterName: string,\r\n filterParams: any, floatingFilterComponentParams: any,\r\n floatingFilterComponentFramework: any, valueFormatter: any,\r\n colId: string, field: string, group: string) : ColDef {\r\n const col = {\r\n colId: colId,\r\n field: field,\r\n headerName: headerName,\r\n toolPanelClass: group,\r\n width: columnWidth,\r\n filter: filterName,\r\n filterParams: filterParams,\r\n floatingFilterComponentParams: floatingFilterComponentParams,\r\n valueFormatter: valueFormatter,\r\n suppressSizeToFit: false,\r\n hide: hide\r\n } as ColDef;\r\n\r\n if (floatingFilterComponentFramework) {\r\n col['floatingFilterComponentFramework'] = floatingFilterComponentFramework;\r\n }\r\n\r\n return col;\r\n }\r\n\r\n private _getGridIdBySource(gridSourceOption: GridSourceOptionEnum): System.Guid {\r\n switch (gridSourceOption) {\r\n case GridSourceOptionEnum.Imported:\r\n return this._IMPORTED_VALUES_GRID_ID;\r\n case GridSourceOptionEnum.Reporting:\r\n return this._REPORTING_VALUES_GRID_ID;\r\n default:\r\n throw new Error('An unknown source was specified for retrieving asset values.');\r\n }\r\n }\r\n\r\n private _handleTotalsUpdate = (totals: Compliance.AssetSearchTotalsModel, selectedTotals: boolean = false, isLoading: boolean = false) => {\r\n const model = {\r\n //cost: totals.totalCost,\r\n //sourceCost: totals.totalSourceCost,\r\n };\r\n const assetModelRow: any = {\r\n model: model,\r\n getModel: () => { return model; },\r\n displayPipe: this._keyValueDisplayPipe,\r\n index: 0,\r\n cost: totals && totals.totalCost,\r\n sourceCost: totals && totals.totalSourceCost,\r\n sourceAdjustedCost: totals && totals.totalSourceAdjustedCost,\r\n sourceN1: totals && totals.totalSourceN1,\r\n sourceN2: totals && totals.totalSourceN2,\r\n sourceN3: totals && totals.totalSourceN3,\r\n sourceN4: totals && totals.totalSourceN4,\r\n sourceN5: totals && totals.totalSourceN5,\r\n sourceN6: totals && totals.totalSourceN6,\r\n sourceN7: totals && totals.totalSourceN7,\r\n sourceN8: totals && totals.totalSourceN8,\r\n sourceN9: totals && totals.totalSourceN9,\r\n sourceN10: totals && totals.totalSourceN10,\r\n reportedN1: totals && totals.totalN1,\r\n reportedN2: totals && totals.totalN2,\r\n reportedN3: totals && totals.totalN3,\r\n reportedN4: totals && totals.totalN4,\r\n reportedN5: totals && totals.totalN5,\r\n reportedN6: totals && totals.totalN6,\r\n reportedN7: totals && totals.totalN7,\r\n reportedN8: totals && totals.totalN8,\r\n reportedN9: totals && totals.totalN9,\r\n reportedN10: totals && totals.totalN10,\r\n reportedAssetNumber: this.selectedGridSourceOption.value === GridSourceOptionEnum.Reporting ? 'TOTAL' : '',\r\n sourceAssetNumber: this.selectedGridSourceOption.value === GridSourceOptionEnum.Imported ? 'TOTAL' : '',\r\n reportedCostAdjustmentAmount1: totals && totals.totalCostAdjustmentAmount1,\r\n reportedCostAdjustmentAmount2: totals && totals.totalCostAdjustmentAmount2,\r\n reportedCostAdjustmentAmount3: totals && totals.totalCostAdjustmentAmount3,\r\n reportedCostAdjustmentAmount4: totals && totals.totalCostAdjustmentAmount4,\r\n reportedInventoryJan: totals && totals.totalInventoryJan,\r\n reportedInventoryFeb: totals && totals.totalInventoryFeb,\r\n reportedInventoryMar: totals && totals.totalInventoryMar,\r\n reportedInventoryApr: totals && totals.totalInventoryApr,\r\n reportedInventoryMay: totals && totals.totalInventoryMay,\r\n reportedInventoryJun: totals && totals.totalInventoryJun,\r\n reportedInventoryJul: totals && totals.totalInventoryJul,\r\n reportedInventoryAug: totals && totals.totalInventoryAug,\r\n reportedInventorySep: totals && totals.totalInventorySep,\r\n reportedInventoryOct: totals && totals.totalInventoryOct,\r\n reportedInventoryNov: totals && totals.totalInventoryNov,\r\n reportedInventoryDec: totals && totals.totalInventoryDec,\r\n reportedInventoryAvrCalculated: totals && totals.totalInventoryAvrCalculated,\r\n sourceInventoryJan: totals && totals.totalSourceInventoryJan,\r\n sourceInventoryFeb: totals && totals.totalSourceInventoryFeb,\r\n sourceInventoryMar: totals && totals.totalSourceInventoryMar,\r\n sourceInventoryApr: totals && totals.totalSourceInventoryApr,\r\n sourceInventoryMay: totals && totals.totalSourceInventoryMay,\r\n sourceInventoryJun: totals && totals.totalSourceInventoryJun,\r\n sourceInventoryJul: totals && totals.totalSourceInventoryJul,\r\n sourceInventoryAug: totals && totals.totalSourceInventoryAug,\r\n sourceInventorySep: totals && totals.totalSourceInventorySep,\r\n sourceInventoryOct: totals && totals.totalSourceInventoryOct,\r\n sourceInventoryNov: totals && totals.totalSourceInventoryNov,\r\n sourceInventoryDec: totals && totals.totalSourceInventoryDec,\r\n sourceInventoryAvr: totals && totals.totalSourceInventoryAvr,\r\n reportedNetBookValue: totals && totals.totalNetBookValue,\r\n sourceNetBookValue: totals && totals.totalSourceNetBookValue\r\n };\r\n\r\n if (selectedTotals) {\r\n assetModelRow.selectedTotalsRow = true;\r\n assetModelRow.reportedAssetNumber = this.selectedGridSourceOption.value === GridSourceOptionEnum.Reporting ? 'SELECTED' : '';\r\n assetModelRow.sourceAssetNumber = this.selectedGridSourceOption.value === GridSourceOptionEnum.Imported ? 'SELECTED' : '';\r\n this.assetGridSelectedTotalsRow = assetModelRow;\r\n } else {\r\n assetModelRow.totalsRow = true;\r\n this.assetGridTotalsRow = assetModelRow;\r\n }\r\n\r\n if (isLoading) {\r\n this.totalsLoading = this._gridDataSource.getLoadingMessage(msg => {\r\n assetModelRow.reportedAssetNumber = msg;\r\n assetModelRow.sourceAssetNumber = msg;\r\n this._gridApi.setPinnedBottomRowData([assetModelRow]);\r\n });\r\n return;\r\n } else if (!isLoading && this.totalsLoading >= 0) {\r\n clearInterval(this.totalsLoading);\r\n this.totalsLoading = null;\r\n }\r\n\r\n const totalRows = [this.assetGridTotalsRow];\r\n if (this.gridTracker.hasAnythingSelected()) {\r\n totalRows.push(this.assetGridSelectedTotalsRow);\r\n }\r\n this._timer.setTimeout(() => this._gridApi.setPinnedBottomRowData(totalRows), 100);\r\n };\r\n\r\n private async _reloadTotals(): Promise {\r\n if (!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.selectedTotalsLoading = true;\r\n\r\n try {\r\n const result = await this._gridDataSource.getSelectedRowTotals(this.gridTracker.getSelectedRowsModel());\r\n this.selectedTotalsLoading = false;\r\n this._handleTotalsUpdate(result, true);\r\n }\r\n finally {\r\n this.selectedTotalsLoading = false;\r\n }\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', lrpId: number, canDismiss = true, hasProgressBar = true): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: lrpId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: hasProgressBar,\r\n canDismiss\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success) => {\r\n await this._hideBusyIndicator();\r\n if (success) {\r\n this.refresh();\r\n }\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._destroy$.next();\r\n }\r\n}\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../AgGrid';\r\nimport { ElectronicFilingRepository } from '../Repositories';\r\n\r\nexport interface ElectronicFilingDataSourceParams {\r\n companyId: number;\r\n stateId: number;\r\n electronicFilingTypeId: number,\r\n taxYear: number;\r\n}\r\n\r\nexport class ElectronicFilingAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _electronicFilingRepository: ElectronicFilingRepository,\r\n protected _dataSourceParamsFn: () => ElectronicFilingDataSourceParams) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'assessorAbbr', value: Compliance.ElectronicFilingPropertyEnum.AssessorAbbr },\r\n { name: 'parcelAccountNumber', value: Compliance.ElectronicFilingPropertyEnum.ParcelAccountNumber },\r\n { name: 'filingBatchNumber', value: Compliance.ElectronicFilingPropertyEnum.FilingBatchNumber },\r\n { name: 'returnDueDate', value: Compliance.ElectronicFilingPropertyEnum.ReturnDueDate },\r\n { name: 'status', value: Compliance.ElectronicFilingPropertyEnum.Status },\r\n { name: 'siteName', value: Compliance.ElectronicFilingPropertyEnum.SiteName },\r\n { name: 'ppeFilingAvailability', value: Compliance.ElectronicFilingPropertyEnum.PPEFilingAvailability },\r\n { name: 'cost', value: Compliance.ElectronicFilingPropertyEnum.Cost },\r\n { name: 'reportedCost', value: Compliance.ElectronicFilingPropertyEnum.ReportedCost },\r\n { name: 'reportedValue', value: Compliance.ElectronicFilingPropertyEnum.ReportedValue },\r\n { name: 'taxLiability', value: Compliance.ElectronicFilingPropertyEnum.TaxLiability },\r\n { name: 'estimatedFMV', value: Compliance.ElectronicFilingPropertyEnum.EstimatedFMV },\r\n { name: 'filingBatchName', value: Compliance.ElectronicFilingPropertyEnum.FilingBatchName },\r\n { name: 'assessorCity', value: Compliance.ElectronicFilingPropertyEnum.AssessorCity },\r\n { name: 'companyName', value: Compliance.ElectronicFilingPropertyEnum.CompanyName },\r\n { name: 'downloadedDate', value: Compliance.ElectronicFilingPropertyEnum.DownloadedDate },\r\n { name: 'isAmended', value: Compliance.ElectronicFilingPropertyEnum.IsAmended },\r\n { name: 'isConsolidatedReturn', value: Compliance.ElectronicFilingPropertyEnum.IsConsolidatedReturn },\r\n { name: 'notReportedAssetCount', value: Compliance.ElectronicFilingPropertyEnum.NotReportedAssetCount },\r\n { name: 'ppeFilingRemarks', value: Compliance.ElectronicFilingPropertyEnum.PPEFilingRemarks },\r\n { name: 'ppeFilingUrl', value: Compliance.ElectronicFilingPropertyEnum.PPEFilingUrl },\r\n { name: 'priorReturnName', value: Compliance.ElectronicFilingPropertyEnum.PriorReturnName },\r\n { name: 'reportedAssetCount', value: Compliance.ElectronicFilingPropertyEnum.ReportedAssetCount },\r\n { name: 'siteNumber', value: Compliance.ElectronicFilingPropertyEnum.SiteNumber },\r\n ];\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Compliance.ElectronicFilingSearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n stateId: this._dataSourceParams.stateId,\r\n electronicFilingTypeId: this._dataSourceParams.electronicFilingTypeId,\r\n taxYear: this._dataSourceParams.taxYear,\r\n selectedRows: {selectAllRows: true} as Compliance.SelectedRowsModel\r\n };\r\n\r\n return await lastValueFrom(this._electronicFilingRepository.getRowIds(this._dataSourceParams.companyId, searchParams));\r\n }\r\n\r\n getSearchModel(startIndex?: number, endIndex?: number): Compliance.ElectronicFilingSearchModel {\r\n return {\r\n pagination: {\r\n skip: (startIndex) ? startIndex : 0,\r\n take: (endIndex) ? endIndex - startIndex + 1 : 0\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n stateId: this._dataSourceParams.stateId,\r\n taxYear: this._dataSourceParams.taxYear,\r\n electronicFilingTypeId: this._dataSourceParams.electronicFilingTypeId,\r\n selectedRows: {selectAllRows: true} as Compliance.SelectedRowsModel\r\n };\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return (!!(this._dataSourceParams.stateId && this._dataSourceParams.electronicFilingTypeId && this._dataSourceParams.companyId));\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Compliance.ElectronicFilingSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n stateId: this._dataSourceParams.stateId,\r\n electronicFilingTypeId: this._dataSourceParams.electronicFilingTypeId,\r\n taxYear: this._dataSourceParams.taxYear,\r\n selectedRows: {selectAllRows: true} as Compliance.SelectedRowsModel\r\n };\r\n\r\n const result = await lastValueFrom(this._electronicFilingRepository.getList(this._dataSourceParams.companyId, searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const ELECTRONIC_FILING_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'electronic-filing.options',\r\n tooltipText: 'Please indicate if you would like to download a separate electronic file per assessor or if you would like all selected assessors included in one electronic file.',\r\n hasIcon: true\r\n }\r\n];\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Electronic Filings\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n
\r\n Output Options\r\n \r\n \r\n Files created in accordance with state and assessor specifications and regulations.\r\n
\r\n
\r\n \r\n Submit a test file with the CA SDR / e-SDR: here\r\n File an electronic return at CA SDR / e-SDR: here\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n\r\n","import { DecimalPipe } from '@angular/common';\r\nimport { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormBuilder, FormControl, FormGroup } from '@angular/forms';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { take, takeUntil } from 'rxjs/operators';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { BreadCrumb } from '../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { YearPickerMixin } from '../../UI-Lib/Mixins';\r\nimport { WeissmanDateFormat } from '../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../AgGrid';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AgGridYesNoFloatingFilterComponent } from '../AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport {\r\n AgGridMultiSelectCellRendererParams,\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectTracker\r\n} from '../AgGrid/MultiSelectTracker';\r\nimport {\r\n ICellRendererParamsForFilingBatchListGridAction\r\n} from '../Filing-Batch/Filing-Batch-List/agGridActionCellRenderer.component';\r\nimport { ElectronicFilingRepository } from '../Repositories';\r\nimport { ElectronicFilingAgGridDataSource, ElectronicFilingDataSourceParams } from './agGridDataSource';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../AgGrid/ToolPanel/models';\r\nimport { BusyIndicatorService, SnackBarService } from '../../Busy-Indicator';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { ELECTRONIC_FILING_HELP } from './electronicFiling.component.help';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\n\r\ninterface ViewControlFormModel {\r\n electronicFilingType: FormControl;\r\n taxYear: FormControl;\r\n}\r\n\r\ninterface DownloadControlFormModel {\r\n bundleAssessors: FormControl;\r\n}\r\n\r\n@Component({\r\n selector: 'electronic-filing',\r\n templateUrl: './electronicFiling.component.html',\r\n styleUrls: ['./electronicFiling.component.scss']\r\n})\r\nexport class ElectronicFilingComponent extends YearPickerMixin() implements OnInit, OnDestroy {\r\n constructor(private readonly _electronicFilingRepository: ElectronicFilingRepository,\r\n private readonly _fb: FormBuilder,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _taskService: TaskService,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _snackBarService: SnackBarService,\r\n private readonly _helpService: HelpService,\r\n private readonly _featureFlagsService: FeatureFlagsService) {\r\n super();\r\n }\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n isInitialized: boolean = false;\r\n hasRowsSelected: boolean = false;\r\n companyId: number;\r\n companyName: string;\r\n viewControlForm: FormGroup;\r\n downloadControlForm: FormGroup;\r\n sdrTestUrl: string;\r\n sdrUrl: string;\r\n electronicFilingTypes: Compliance.ElectronicFilingTypeModel[];\r\n placeholderElectronicFilingType: Compliance.ElectronicFilingTypeModel = {\r\n name: '',\r\n electronicFilingTypeId: null,\r\n stateAbbr: null,\r\n displayName: 'Nothing selected',\r\n stateId: null\r\n };\r\n isCASdr: boolean = false;\r\n\r\n gridId: System.Guid = 'a070ef4b-6057-410f-8a54-7cbc8a59fdca';\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => {\r\n const data = params.data as Compliance.ElectronicFilingModel;\r\n if (!data) {\r\n return false;\r\n }\r\n const isDisabled = !data.ppeFilingAvailability || data.ppeFilingAvailability === this.NOT_AVAILABLE || (!(this._featureFlagsService.featureFlags.allowElectronicFilingUnapprovedDownload || (data.hasApprovalTask && data.isApproved) || (!data.hasApprovalTask && data.isReviewed)));\r\n return !isDisabled && this.gridTracker.isRowSelected(data.returnId);\r\n }\r\n }\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const searchParams = this._gridDataSource.getSearchModel();\r\n searchParams.pagination = null;\r\n\r\n searchParams.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n if (!searchParams.selectedRows.selectAllRows && searchParams.selectedRows.selectedRows.length === 0) {\r\n searchParams.selectedRows.selectAllRows = true;\r\n }\r\n\r\n const exportModel: Compliance.ElectronicFilingExportModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn\r\n };\r\n\r\n const lrp$ = this._electronicFilingRepository.startExport(this.companyId, exportModel);\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n return { longRunningProcessId, longRunningProcessTypeId: Compliance.LongRunningProcessTypeEnum.ExportElectronicFiling };\r\n },\r\n canCancel: true,\r\n showFileFormatSelection: false,\r\n getDisabled: () => !this._gridDataSource || this._gridDataSource.isRefreshing\r\n };\r\n\r\n private readonly NOT_AVAILABLE: string = 'Not Available';\r\n private _gridApi: GridApi;\r\n private _gridDataSource: ElectronicFilingAgGridDataSource;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get canRefresh(): boolean {\r\n const { electronicFilingType, taxYear } = this.viewControlForm.getRawValue();\r\n return !this._gridDataSource?.isRefreshing && !!electronicFilingType && !!taxYear;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(ELECTRONIC_FILING_HELP);\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n const info = await lastValueFrom(this._electronicFilingRepository.getElectronicFilingInfo(this.companyId));\r\n\r\n this.companyName = info.companyName;\r\n this.electronicFilingTypes = info.electronicFilingTypes;\r\n this.electronicFilingTypes.unshift(this.placeholderElectronicFilingType);\r\n\r\n this.sdrTestUrl = info.caSdrTestUrl;\r\n this.sdrUrl = info.caSdrUrl;\r\n\r\n this.breadcrumbs = [{\r\n name: this.companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n }];\r\n\r\n this.viewControlForm = this._fb.group({\r\n electronicFilingType: this._fb.control(this.placeholderElectronicFilingType),\r\n taxYear: this._fb.control(new Date().getFullYear())\r\n });\r\n\r\n this.downloadControlForm = this._fb.group({\r\n bundleAssessors: this._fb.control(false)\r\n });\r\n\r\n this.viewControlForm.valueChanges.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n const { electronicFilingType, taxYear } = this.viewControlForm.getRawValue();\r\n if (electronicFilingType && taxYear) {\r\n this._refreshDataSource();\r\n }\r\n });\r\n\r\n this.isInitialized = true;\r\n\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n refresh(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n onElectronicFilingTypeChanged(electronicFilingType: Compliance.ElectronicFilingTypeModel): void {\r\n this.isCASdr = electronicFilingType && electronicFilingType.electronicFilingTypeId === Compliance.ElectronicFilingTypeEnum.Ca571LSdr;\r\n }\r\n\r\n async downloadElectronicFilings(): Promise {\r\n this.disableDownload = true;\r\n const busyRef = this._busyIndicatorService.show({ message: 'Working on it...', delay: 0 });\r\n\r\n try {\r\n const { electronicFilingType, taxYear } = this.viewControlForm.getRawValue();\r\n\r\n const { bundleAssessors } = this.downloadControlForm.getRawValue();\r\n\r\n const searchParams = this._gridDataSource.getSearchModel();\r\n searchParams.pagination = null;\r\n searchParams.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n\r\n // not that this is assuming there is only one electronic filing type per state\r\n // in future we may want to pass in the electronic filing type id as well to limit the list by state and type\r\n const outputModel: Compliance.ElectronicFilingOutputModel = {\r\n topLevelCompanyId: this.companyId,\r\n taxYear: taxYear,\r\n bundleByAssessor: bundleAssessors,\r\n electronicFilingTypeId: electronicFilingType.electronicFilingTypeId,\r\n searchModel: searchParams\r\n };\r\n\r\n const lrpId = await lastValueFrom(this._electronicFilingRepository.generateElectronicFilingOutput(outputModel));\r\n this._snackBarService.addById(lrpId, Compliance.LongRunningProcessTypeEnum.GenerateElectronicFilingOutput);\r\n this.disableDownload = false;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this.gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n this.hasRowsSelected = this.gridTracker.hasSelectedRows() && !this.gridTracker.isAllRowsDisabled();\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'returnId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n maxWidth: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n editable: false,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker,\r\n isCellRendererDisabledFn: (rowId: number, data: Compliance.ElectronicFilingModel) => {\r\n return this.gridTracker.isAllRowsDisabled();\r\n }\r\n } as AgGridMultiSelectCellRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker,\r\n tooltipText: (params) => {\r\n const data = params.data as Compliance.ElectronicFilingModel;\r\n let message: string = '';\r\n if(!data) {\r\n return message;\r\n }\r\n if (!data.ppeFilingAvailability) {\r\n message = 'This assessor does not accept electronic filings (availability not set)';\r\n }\r\n if (data.ppeFilingAvailability === this.NOT_AVAILABLE) {\r\n message = 'This assessor does not accept electronic filings';\r\n }\r\n if (data.hasApprovalTask && !data.isApproved) {\r\n if (message) {\r\n message += ' ';\r\n }\r\n message += `${message ? ' and this' : 'This'} return has not been approved`;\r\n }\r\n if (!data.hasApprovalTask && !data.isReviewed) {\r\n if (message) {\r\n message += ' ';\r\n }\r\n message += `${message ? ' and this' : 'This'} return has not been reviewed`;\r\n }\r\n return message ? `${message}.` : 'Toggle selection';\r\n },\r\n isCellRendererDisabledFn: (rowId: number, data: Compliance.ElectronicFilingModel) => {\r\n return !data.ppeFilingAvailability || data.ppeFilingAvailability === this.NOT_AVAILABLE || (!(this._featureFlagsService.featureFlags.allowElectronicFilingUnapprovedDownload || (data.hasApprovalTask && data.isApproved) || (!data.hasApprovalTask && data.isReviewed)));\r\n }\r\n } as AgGridMultiSelectCellRendererParams\r\n },\r\n {\r\n headerName: 'Parcel Acct Num',\r\n field: 'parcelAccountNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n editable: false,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/parcel/${model.parcelId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorAbbr',\r\n width: AgGridColumns.textColumnWidth,\r\n editable: false,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/assessor/${model.assessorId}?year=${this.viewControlForm.value.taxYear}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Batch Number',\r\n field: 'filingBatchNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n editable: false,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-filing-batch',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/returnBatch/${model.filingBatchId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Return Due Date',\r\n field: 'returnDueDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n if (!(model && model.returnDueDate)) {\r\n return '';\r\n }\r\n return WeissmanDateFormat(model.returnDueDate, true, 'stored');\r\n }\r\n },\r\n {\r\n headerName: 'Status',\r\n field: 'status',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n sortable: false,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-task-series',\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n return null;\r\n },\r\n onClick: this._viewTasks.bind(this)\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Site Name',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnWidth,\r\n editable: false,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/site/${model.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'PP E-Filing Availability',\r\n field: 'ppeFilingAvailability',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Cost',\r\n field: 'cost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ElectronicFilingModel;\r\n return !rowData\r\n ? null\r\n : x.value || x.value === 0 || rowData.cost\r\n ? this._decimalPipe.transform(x.value, '1.2-2')\r\n : 'N/A';\r\n },\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Rep. Cost',\r\n field: 'reportedCost',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ElectronicFilingModel;\r\n return !rowData\r\n ? null\r\n : x.value || x.value === 0 || rowData.reportedCost\r\n ? this._decimalPipe.transform(x.value, '1.2-2')\r\n : 'N/A';\r\n },\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Dep. Value',\r\n field: 'reportedValue',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ElectronicFilingModel;\r\n return !rowData\r\n ? null\r\n : x.value || x.value === 0 || rowData.reportedValue\r\n ? this._decimalPipe.transform(x.value, '1.2-2')\r\n : 'N/A';\r\n },\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Est. Tax',\r\n field: 'taxLiability',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ElectronicFilingModel;\r\n return !rowData\r\n ? null\r\n : x.value || x.value === 0 || rowData.taxLiability\r\n ? this._decimalPipe.transform(x.value, '1.2-2')\r\n : 'N/A';\r\n },\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Est. FMV',\r\n field: 'estimatedFMV',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ElectronicFilingModel;\r\n return !rowData\r\n ? null\r\n : x.value || x.value === 0 || rowData.estimatedFMV\r\n ? this._decimalPipe.transform(x.value, '1.2-2')\r\n : 'N/A';\r\n },\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Batch Name',\r\n field: 'filingBatchName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'City',\r\n field: 'assessorCity',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n editable: false,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/company/${model.companyId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Downloaded Date',\r\n field: 'downloadedDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n if (!(model && model.downloadedDate)) {\r\n return '';\r\n }\r\n return WeissmanDateFormat(model.downloadedDate, true, 'stored');\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Is Amended',\r\n field: 'isAmended',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: params => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n return model?.isAmended ? 'Yes' : 'No';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Is Consolidated',\r\n field: 'isConsolidatedReturn',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: params => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n return model?.isConsolidatedReturn ? 'Yes' : 'No';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Not Rep. Asset Count',\r\n field: 'notReportedAssetCount',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ElectronicFilingModel;\r\n if (!rowData) {\r\n return '0';\r\n }\r\n return x.value || rowData.notReportedAssetCount ? rowData.notReportedAssetCount.toString() : '0';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'PP E-Filing Remarks',\r\n field: 'ppeFilingRemarks',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'PP E-Filing URL',\r\n field: 'ppeFilingUrl',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Prior Return',\r\n field: 'priorReturnName',\r\n width: AgGridColumns.textColumnWidth,\r\n editable: false,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-return',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/returnBatch/${model.priorReturnId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Rep. Asset Count',\r\n field: 'reportedAssetCount',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => {\r\n const rowData = x.data as Compliance.ElectronicFilingModel;\r\n if (!rowData) {\r\n return '0';\r\n }\r\n return x.value || rowData.reportedAssetCount ? rowData.reportedAssetCount.toString() : '0';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'siteNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n editable: false,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Compliance.ElectronicFilingModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/site/${model.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'parcelAccountNumber',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n private async _viewTasks(params: ICellRendererParamsForFilingBatchListGridAction): Promise {\r\n const efiling = params.data as Compliance.ElectronicFilingModel;\r\n if (!efiling) {\r\n return;\r\n }\r\n\r\n const entityId = efiling.filingBatchId;\r\n\r\n const entityType = Core.EntityTypes.FilingBatch;\r\n\r\n await this._taskService.launchTaskModal(entityId, entityType, true);\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this.gridTracker.clear();\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return false;\r\n }\r\n\r\n this.gridTracker.clear();\r\n\r\n const dataSourceParams = (): ElectronicFilingDataSourceParams => {\r\n const { electronicFilingType, taxYear } = this.viewControlForm.getRawValue();\r\n return {\r\n companyId: this.companyId,\r\n stateId: electronicFilingType && electronicFilingType.stateId,\r\n electronicFilingTypeId: electronicFilingType && electronicFilingType.electronicFilingTypeId,\r\n taxYear: taxYear\r\n };\r\n };\r\n\r\n this._gridDataSource = new ElectronicFilingAgGridDataSource(\r\n this._gridApi,\r\n this._electronicFilingRepository,\r\n dataSourceParams);\r\n\r\n this._gridDataSource.onFirstDataRendered$.pipe(take(1)).subscribe(() => {\r\n this._gridApi.sizeColumnsToFit();\r\n });\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private _getGridRowIds(skip: number, toTake: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, toTake);\r\n }\r\n}\r\n","import { lastValueFrom } from 'rxjs';\r\nimport { EntityImportRepository } from '../../Repositories';\r\nimport { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../AgGrid';\r\n\r\nexport interface EntityImportListDataSourceParams {\r\n isCompanyImport: boolean;\r\n includeCompleted: boolean;\r\n companyId: number;\r\n}\r\n\r\nexport class EntityImportListGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private _gridApi: GridApi,\r\n private _entityImportRepository: EntityImportRepository,\r\n protected _dataSourceParamsFn: () => EntityImportListDataSourceParams\r\n ) { super(_gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'displayName', value: Compliance.ImportFilePropertyEnum.DisplayName },\r\n { name: 'fileName', value: Compliance.ImportFilePropertyEnum.FileName },\r\n { name: 'createDate', value: Compliance.ImportFilePropertyEnum.CreateDate },\r\n { name: 'importContentType.name', value: Compliance.ImportFilePropertyEnum.ImportContentTypeName },\r\n { name: 'transferredRows', value: Compliance.ImportFilePropertyEnum.TransferredRows },\r\n { name: 'ownerName', value: Compliance.ImportFilePropertyEnum.OwnerName }\r\n ];\r\n\r\n protected canGetRows(): boolean {\r\n return !this._dataSourceParams.isCompanyImport || !!this._dataSourceParams.companyId;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Compliance.ImportSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n includeCompleted: this._dataSourceParams.includeCompleted\r\n };\r\n\r\n let result: Compliance.QueryResultModel;\r\n\r\n if (this._dataSourceParams.isCompanyImport){\r\n result = await lastValueFrom(this._entityImportRepository.getByCompany(this._dataSourceParams.companyId, searchParams));\r\n } else{\r\n result = await lastValueFrom(this._entityImportRepository.getSystem(searchParams));\r\n }\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows,\r\n lastModifiedTimestamp: result.lastModifiedTimestamp\r\n };\r\n }\r\n}\r\n","import { Component, Input, Output, EventEmitter } from '@angular/core';\r\nimport { StepProgressIndicatorStep } from '../../../Common/Step-Progress-Indicator/stepProgressIndicator.component';\r\nimport { DecimalPipe } from '@angular/common';\r\n\r\n@Component({\r\n selector: 'entity-import-progress',\r\n template: ''\r\n})\r\nexport class EntityImportProgressComponent {\r\n constructor(\r\n private readonly _decimalPipe: DecimalPipe) { }\r\n\r\n @Input() importFile: Compliance.ImportFileModel;\r\n @Input() showStepName: boolean = true;\r\n @Input() clickable: boolean = true;\r\n @Output() click: EventEmitter = new EventEmitter();\r\n\r\n steps: StepProgressIndicatorStep[] = [\r\n {\r\n name: 'UPLOAD',\r\n title: this._getUploadTitle.bind(this),\r\n isError: this._uploadIsError.bind(this),\r\n isCurrent: this._uploadIsCurrent.bind(this),\r\n isWorking: this._uploadIsWorking.bind(this),\r\n isComplete: this._uploadIsComplete.bind(this),\r\n click: this._onClick.bind(this)\r\n },\r\n {\r\n name: 'MAP',\r\n title: this._getMapTitle.bind(this),\r\n isError: this._mapIsError.bind(this),\r\n isCurrent: this._mapIsCurrent.bind(this),\r\n isWorking: this._mapIsWorking.bind(this),\r\n isComplete: this._mapIsComplete.bind(this),\r\n click: this._onClick.bind(this)\r\n },\r\n {\r\n name: 'XFER',\r\n title: this._getTransferTitle.bind(this),\r\n isError: this._transferIsError.bind(this),\r\n isCurrent: this._transferIsCurrent.bind(this),\r\n isWorking: this._transferIsWorking.bind(this),\r\n isComplete: this._transferIsComplete.bind(this),\r\n click: this._onClick.bind(this)\r\n }\r\n ];\r\n\r\n private _getUploadTitle(): string {\r\n if (!this.importFile) {\r\n return 'Upload';\r\n }\r\n\r\n if (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.ProcessingError) {\r\n return `${(this.importFile.error ? this.importFile.error : 'An error has occurred.')} Delete the import and try again.`;\r\n }\r\n if (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Uploaded) {\r\n return 'Upload complete. Please click to resume the import.';\r\n }\r\n if (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Processing) {\r\n return 'The import is being processed by the server.';\r\n }\r\n if (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.ShowPreview) {\r\n return 'Upload complete. Please click to provide some additional information.';\r\n }\r\n if (this.importFile.processStatus >= Compliance.ImportFileProcessStatusEnum.ProcessingCompleted) {\r\n return 'Upload complete.';\r\n }\r\n\r\n return 'Upload';\r\n }\r\n\r\n private _uploadIsError(): boolean {\r\n return this.importFile && this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.ProcessingError;\r\n }\r\n\r\n private _uploadIsCurrent(): boolean {\r\n return this.importFile && this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Uploaded;\r\n }\r\n\r\n private _uploadIsWorking(): boolean {\r\n return this.importFile && (this.importFile && this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Processing);\r\n }\r\n\r\n private _uploadIsComplete(): boolean {\r\n return this.importFile &&\r\n this.importFile.processStatus >= Compliance.ImportFileProcessStatusEnum.ProcessingCompleted &&\r\n this.importFile.processStatus !== Compliance.ImportFileProcessStatusEnum.ShowPreview;\r\n }\r\n\r\n private _getMapTitle(): string {\r\n if (this.importFile && this.importFile.requiredFieldsAssigned) {\r\n return 'All required fields have been mapped.';\r\n }\r\n return 'Map required fields';\r\n }\r\n\r\n private _mapIsError(): boolean {\r\n return false;\r\n }\r\n\r\n private _mapIsCurrent(): boolean {\r\n return (this.importFile && this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.ProcessingCompleted && !this.importFile.requiredFieldsAssigned);\r\n }\r\n\r\n private _mapIsWorking(): boolean {\r\n return false;\r\n }\r\n\r\n private _mapIsComplete(): boolean {\r\n return this.importFile && (this.importFile.requiredFieldsAssigned || this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Completed);\r\n }\r\n\r\n private _getTransferTitle(): string {\r\n if (!this.importFile) {\r\n return 'Transfer data.';\r\n }\r\n\r\n if (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Transferring) {\r\n let message = 'Transferring data: ';\r\n if (this.importFile.lastTransferInfo){\r\n const current = this.importFile.lastTransferInfo.insertedCount +\r\n this.importFile.lastTransferInfo.updatedCount +\r\n this.importFile.lastTransferInfo.unchangedCount;\r\n\r\n if (current !== 0)\r\n {\r\n message += `transferred ${this._decimalPipe.transform(current || 0, '1.0-0')} of ${this._decimalPipe.transform(this.importFile.lastTransferInfo.selectedCount || 0, '1.0-0')} rows`;\r\n } else{\r\n message += 'preparing for transfer';\r\n }\r\n } else{\r\n message += 'preparing for transfer';\r\n }\r\n\r\n message += '.';\r\n return message;\r\n }\r\n\r\n if (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.TransferCompleted) {\r\n return 'Transfer completed.';\r\n }\r\n\r\n if (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.TransferError ||\r\n this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.RevertingError) {\r\n return `${(this.importFile.error ? this.importFile.error : 'An error has occurred.')}`;\r\n }\r\n\r\n if (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Reverting) {\r\n return 'Reverting transferred data.';\r\n }\r\n\r\n if (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Validating) {\r\n return 'Validating.';\r\n }\r\n\r\n return 'Transfer data.';\r\n }\r\n\r\n private _transferIsError(): boolean {\r\n return this.importFile && (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.TransferError ||\r\n this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.RevertingError);\r\n }\r\n\r\n private _transferIsCurrent(): boolean {\r\n return this.importFile && (this.importFile.requiredFieldsAssigned &&\r\n this.importFile.processStatus !== Compliance.ImportFileProcessStatusEnum.TransferCompleted &&\r\n (this.importFile.processStatus !== Compliance.ImportFileProcessStatusEnum.RevertingError || this.importFile.totalRows != this.importFile.transferredRows));\r\n }\r\n\r\n private _transferIsWorking(): boolean {\r\n return this.importFile && (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Transferring ||\r\n this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Reverting ||\r\n this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Validating);\r\n }\r\n\r\n private _transferIsComplete(): boolean {\r\n return this.importFile && (this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Completed ||\r\n this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.TransferCompleted ||\r\n this.importFile.processStatus === Compliance.ImportFileProcessStatusEnum.RevertingError && this.importFile.totalRows === this.importFile.transferredRows);\r\n }\r\n\r\n private _onClick(): void {\r\n if (!this.importFile) {\r\n return;\r\n }\r\n\r\n this.click.emit(this.importFile);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForProgressCell extends ICellRendererParams {\r\n resume: (params: ICellRendererParamsForProgressCell) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-list-grid-progress',\r\n template: ''\r\n})\r\nexport class EntityImportListGridProgressCellRendererComponent implements ICellRendererAngularComp {\r\n importFile: Compliance.ImportFileModel;\r\n params: ICellRendererParamsForProgressCell;\r\n\r\n agInit(params: ICellRendererParamsForProgressCell): void {\r\n this.importFile = params.data as Compliance.ImportFileModel;\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForImportListGridAction extends ICellRendererParams {\r\n resume: (params: ICellRendererParamsForImportListGridAction) => void;\r\n delete: (params: ICellRendererParamsForImportListGridAction) => void;\r\n canDelete: (params: ICellRendererParamsForImportListGridAction) => boolean;\r\n revert: (params: ICellRendererParamsForImportListGridAction) => void;\r\n canRevert: (params: ICellRendererParamsForImportListGridAction) => boolean;\r\n complete: (params: ICellRendererParamsForImportListGridAction) => void;\r\n canComplete: (params: ICellRendererParamsForImportListGridAction) => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n `\r\n})\r\nexport class EntityImportListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForImportListGridAction;\r\n importFile: Compliance.ImportFileModel;\r\n\r\n get deleteHelpContentId(): string {\r\n return this.params.canDelete(this.params) ?\r\n 'app.delete' :\r\n 'import-list.delete-disabled';\r\n }\r\n\r\n get revertHelpContentId(): string {\r\n return this.params.canRevert(this.params) ?\r\n 'import-list.revert' :\r\n 'import-list.revert-disabled';\r\n }\r\n\r\n get markCompletedHelpContentId(): string {\r\n return this.params.canComplete(this.params) ?\r\n 'import-list.mark-completed' :\r\n 'import-list.mark-completed-disabled';\r\n }\r\n\r\n agInit(params: ICellRendererParamsForImportListGridAction): void {\r\n this.params = params;\r\n this.importFile = params.data as Compliance.ImportFileModel;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const IMPORT_LIST_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'import-list.completed',\r\n tooltipText: 'Include data imports where all rows have been transferred or the data import has been marked completed.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'import-list.new-data-import',\r\n tooltipText: 'New data import'\r\n },\r\n {\r\n helpContentId: 'import-list.data-import-specifications',\r\n tooltipText: 'View and edit data import specifications.'\r\n },\r\n {\r\n helpContentId: 'import-list.data-import-specifications-company',\r\n tooltipText: 'View and edit data import specifications used in this company.'\r\n },\r\n {\r\n helpContentId: 'import-list.resume',\r\n tooltipText: 'Resume data import'\r\n },\r\n {\r\n helpContentId: 'import-list.revert',\r\n tooltipText: 'Revert database changes made by data import.'\r\n },\r\n {\r\n helpContentId: 'import-list.revert-disabled',\r\n tooltipText: 'Data import cannot be reverted.'\r\n },\r\n {\r\n helpContentId: 'import-list.mark-completed',\r\n tooltipText: 'Mark data import as completed.'\r\n },\r\n {\r\n helpContentId: 'import-list.mark-completed-disabled',\r\n tooltipText: 'Data import cannot be marked as completed if already completed or no rows have been transferred.'\r\n },\r\n {\r\n helpContentId: 'import-list.delete-disabled',\r\n tooltipText: 'Data import cannot be deleted if it is being processed or any rows have been transferred.'\r\n }\r\n];\r\n","\r\n
\r\n Are you sure you want to start the transfer process?
\r\n The following are the summary of actions:
\r\n Insert: {{params.evaluatedInsertCount | number}} rows
\r\n Update: {{params.evaluatedUpdateCount | number}} rows
\r\n Delete: {{params.evaluatedDeleteCount | number}} rows
\r\n Unchanged: {{params.evaluatedNoChangeCount | number}} rows (recording assets appeared on import)
\r\n
\r\n Effective date: {{params.effectiveDate|date:'M/d/yyyy'}}
\r\n Asset Ownership type: {{params.assetOwnershipType}}
\r\n Amount Value type: {{params.accrualAdjustmentAmountValueType}}\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\n\r\nexport interface TransferConfirmParams {\r\n evaluatedInsertCount?: number,\r\n evaluatedUpdateCount?: number,\r\n evaluatedDeleteCount?: number,\r\n evaluatedNoChangeCount?: number,\r\n effectiveDate?: Date;\r\n assetOwnershipType?: string;\r\n accrualAdjustmentAmountValueType?: string;\r\n importContentType: Compliance.ImportContentTypeIdEnum;\r\n}\r\n\r\n@Component({\r\n selector: 'transfer-confirm',\r\n templateUrl: './transferConfirm.component.html'\r\n})\r\nexport class TransferConfirmComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef){\r\n }\r\n\r\n params: TransferConfirmParams;\r\n result: boolean;\r\n\r\n ngOnInit(): void {\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n ok(): void {\r\n this.result = true;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n get isAssetsImport(): boolean {\r\n return this.params.importContentType === Compliance.ImportContentTypeIdEnum.Assets;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { ImportSpecificationRepository } from '../../../Repositories';\r\n\r\n@Injectable()\r\nexport class DynamicFieldBehaviorService {\r\n private _showDynamicFieldConfiguration: boolean = false;\r\n private _selectedDynamicFieldBehaviorOption: Compliance.ImportDynamicFieldOptionModel;\r\n private _selectedDynamicFieldBehaviorOptions: System.Collections.Generic.KeyValuePair[] = [];\r\n private _dynamicFieldBehaviorOptions: Compliance.ImportDynamicFieldOptionModel[] = [];\r\n private _fields: Compliance.ImportFieldModel[] = [];\r\n private _fieldMappings: Compliance.ImportFileSpecificationImportFieldModel[] = [];\r\n\r\n constructor(\r\n private readonly _entityImportSpecificationRepository: ImportSpecificationRepository)\r\n {}\r\n\r\n async initialize(importContentType: Compliance.ImportContentTypeModel,\r\n importDynamicFieldBehavior: Compliance.ImportDynamicFieldOptionEnum,\r\n setAllFields: Compliance.ImportDynamicFieldOptionEnum, dynamicFieldsBehavior: System.Collections.Generic.KeyValuePair[],\r\n fields: Compliance.ImportFieldModel[], fieldMappings: Compliance.ImportFileSpecificationImportFieldModel[]): Promise {\r\n this._fields = fields;\r\n this._fieldMappings = fieldMappings;\r\n this._showDynamicFieldConfiguration = importContentType.supportsDynamicFieldBehaviorConfiguration;\r\n\r\n if (this._showDynamicFieldConfiguration) {\r\n this._dynamicFieldBehaviorOptions = await lastValueFrom(this._entityImportSpecificationRepository.getDynamicFieldBehaviorOptions())\r\n this._dynamicFieldBehaviorOptions.sort((x, y) => x.displayOrder - y.displayOrder);\r\n\r\n this._selectedDynamicFieldBehaviorOption = this._dynamicFieldBehaviorOptions.find(x => x.optionId === (importDynamicFieldBehavior || Compliance.ImportDynamicFieldOptionEnum.Ignore));\r\n\r\n this._selectedDynamicFieldBehaviorOptions = dynamicFieldsBehavior;\r\n this._selectedDynamicFieldBehaviorOptions.unshift({key: 0, value: setAllFields || Compliance.ImportDynamicFieldOptionEnum.Ignore});\r\n }\r\n }\r\n\r\n getFileDynamicFieldBehaviorOptions(): Compliance.ImportDynamicFieldOptionModel[] {\r\n return this._dynamicFieldBehaviorOptions;\r\n }\r\n\r\n get showDynamicFieldConfiguration(): boolean {\r\n return this._showDynamicFieldConfiguration;\r\n }\r\n\r\n getSelectedDynamicFieldBehaviorOption(): Compliance.ImportDynamicFieldOptionModel {\r\n return this._selectedDynamicFieldBehaviorOption;\r\n }\r\n\r\n getSelectedDynamicFieldBehaviorOptions(): System.Collections.Generic.KeyValuePair[] {\r\n return this._selectedDynamicFieldBehaviorOptions || [];\r\n }\r\n\r\n async setSelectedDynamicFieldBehaviorOption(importId: number, optionId: Compliance.ImportDynamicFieldOptionEnum): Promise {\r\n await lastValueFrom(this._entityImportSpecificationRepository.updateImportPropertyCharacteristicBehavior(importId, optionId));\r\n\r\n this._selectedDynamicFieldBehaviorOption = this._dynamicFieldBehaviorOptions.find(x => x.optionId === optionId);\r\n if (optionId !== Compliance.ImportDynamicFieldOptionEnum.Specify) {\r\n this._selectedDynamicFieldBehaviorOptions = [];\r\n }\r\n }\r\n\r\n getFieldMappings(): Compliance.ImportFileSpecificationImportFieldModel[] {\r\n return this._fieldMappings;\r\n }\r\n\r\n getFields(): Compliance.ImportFieldModel[] {\r\n return this._fields;\r\n }\r\n\r\n async updateImportFieldPropertyCharacteristicBehavior(model: Compliance.ImportFieldPropertyCharacteristicBehaviorUpdateModel): Promise {\r\n this._selectedDynamicFieldBehaviorOptions = await lastValueFrom(this._entityImportSpecificationRepository.updateImportFieldPropertyCharacteristicBehavior(model));\r\n }\r\n}\r\n","import { distinctUntilChanged } from 'rxjs/operators';\r\nimport { Injectable, EventEmitter } from '@angular/core';\r\nimport { Observable, BehaviorSubject, Subject, Subscription, lastValueFrom } from 'rxjs';\r\nimport { EntityImportRepository, ImportSpecificationRepository } from '../../Repositories';\r\nimport * as _ from 'lodash';\r\nimport { WebsocketListenerService } from '../../websocketListener.service';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { TransferConfirmComponent, TransferConfirmParams } from './Transfer-Confirm/transferConfirm.component';\r\nimport { AssetRepository } from '../../Repositories';\r\nimport { EntityImportService } from '../entityImport.service';\r\nimport { DynamicFieldBehaviorService } from './Dynamic-Field-Behavior/dynamicFieldBehavior.service';\r\n\r\nexport class ISelectedRowsEvent {\r\n selectedRowsModel: Compliance.ImportBulkOperationModel;\r\n selectedRowsCount: number;\r\n}\r\n\r\n@Injectable()\r\nexport class EntityImportProcessService {\r\n constructor(\r\n private readonly _entityImportRepository: EntityImportRepository,\r\n private readonly _websocketListenerService: WebsocketListenerService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _assetRepository: AssetRepository,\r\n private readonly _entityImportService: EntityImportService,\r\n private readonly _entityImportSpecificationRepository: ImportSpecificationRepository,\r\n private readonly _dynamicFieldBehaviorService: DynamicFieldBehaviorService) {\r\n }\r\n\r\n private _validationSummaryBehaviorSubject: BehaviorSubject = new BehaviorSubject([]);\r\n private _validatedEventEmitter: EventEmitter> = new EventEmitter>();\r\n private _evaluatingEventEmitter: EventEmitter> = new EventEmitter>();\r\n private _transferredEventEmitter: EventEmitter = new EventEmitter();\r\n private _cellUpdatedEventEmitter: EventEmitter = new EventEmitter();\r\n private _selectedRowsEventEmitter: EventEmitter = new EventEmitter();\r\n private _errorFilterChangedBehaviorSubject: BehaviorSubject = new BehaviorSubject([]);\r\n private _importStatusSubject: Subject = new Subject();\r\n private _importProgressStatusSubject: Subject = new Subject();\r\n private _importFile: Compliance.ImportFileModel;\r\n private _importProcessStatusError: string;\r\n private _importStatusChangeSub: Subscription;\r\n private _importProgressChangeSub: Subscription;\r\n private _lastEvaluationResult: Compliance.ImportEvaluateResultModel;\r\n private _showValidRowsOnlyEventEmitter: EventEmitter = new EventEmitter();\r\n private _longRunningProcessId: number;\r\n private _assetEffectiveDate?: Date = null;\r\n private _assetOwnershipTypeId?: number = null;\r\n private _assetOwnershipTypeName: string = null;\r\n private _selectedRowsInfo: Compliance.ImportSelectedRowsInfoModel = null;\r\n private _forceValidateSubject: Subject = new Subject();\r\n private _sitesUpdatesOnlyMatchBy: string;\r\n private _accrualAdjustmentAmountValueType: string = null;\r\n private _taxPaymentsMatchOverall: string = null;\r\n private _isTaxPaymentsImportMatchByPaymentSystemId: boolean = false;\r\n private _taxPaymentsMatchParcel: string = null;\r\n private _taxPaymentsMatchCollector: string = null;\r\n private _incomeStatementsEndingDate: Date = null;\r\n private _rentRollEndingDate: Date = null;\r\n private _glAccountsIntendedUse: string = null;\r\n private _clearErrorsWarningsSelectionEventEmitter: EventEmitter = new EventEmitter();\r\n\r\n transferCompletedEventEmitter: EventEmitter> = new EventEmitter>();\r\n get longRunningProcessId(): number { return this._longRunningProcessId; }\r\n set longRunningProcessId(id: number) { this._longRunningProcessId = id; }\r\n get importProcessStatusError(): string {\r\n return this._importProcessStatusError;\r\n }\r\n\r\n get importStatus$(): Observable { return this._importStatusSubject.asObservable(); }\r\n\r\n async initialize(importFile: Compliance.ImportFileModel):Promise {\r\n this._importFile = importFile;\r\n\r\n this._assetEffectiveDate = null;\r\n this._assetOwnershipTypeId = null;\r\n this._assetOwnershipTypeName = null;\r\n this._accrualAdjustmentAmountValueType = null;\r\n this._taxPaymentsMatchOverall = null;\r\n this._isTaxPaymentsImportMatchByPaymentSystemId = false;\r\n this._taxPaymentsMatchParcel = null;\r\n this._taxPaymentsMatchCollector = null;\r\n let assetEffectiveDate: string = null;\r\n\r\n switch (this._importFile.importContentTypeId) {\r\n case Compliance.ImportContentTypeIdEnum.Assets:\r\n assetEffectiveDate = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.AssetEffectiveDate).value;\r\n this._assetOwnershipTypeId = +this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.AssetAssetOwnershipType).value;\r\n break;\r\n case Compliance.ImportContentTypeIdEnum.AssetUpdatesOnly:\r\n assetEffectiveDate = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.AssetUpdatesOnlyEffectiveDate).value;\r\n this._assetOwnershipTypeId = +this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.AssetUpdatesOnlyAssetOwnershipType).value;\r\n break;\r\n case Compliance.ImportContentTypeIdEnum.SitesUpdatesOnly:\r\n this._sitesUpdatesOnlyMatchBy = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.SiteUpdatesOnlyMatchBy).value;\r\n this._sitesUpdatesOnlyMatchBy = this._sitesUpdatesOnlyMatchBy[0].toUpperCase() + this._sitesUpdatesOnlyMatchBy.slice(1);\r\n break;\r\n case Compliance.ImportContentTypeIdEnum.AccrualExpenseAdjustments:\r\n this._accrualAdjustmentAmountValueType = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.AmountValueType).value;\r\n break;\r\n case Compliance.ImportContentTypeIdEnum.TaxPayments:\r\n const matchOverall = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.TaxPaymentsMatchOverall).value;\r\n this._taxPaymentsMatchOverall = this._entityImportService.taxPaymentsMatchOverallOptions.find(x => x.value === matchOverall).name;\r\n this._isTaxPaymentsImportMatchByPaymentSystemId = matchOverall === 'payment_system_id';\r\n\r\n if (!this._isTaxPaymentsImportMatchByPaymentSystemId) {\r\n const matchParcel = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.TaxPaymentsMatchParcel).value;\r\n this._taxPaymentsMatchParcel = this._entityImportService.taxPaymentsMatchParcelOptions.find(x => x.value === matchParcel).name;\r\n\r\n const matchCollector = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.TaxPaymentsMatchCollector).value;\r\n this._taxPaymentsMatchCollector = this._entityImportService.taxPaymentsMatchCollectorOptions.find(x => x.value === matchCollector).name;\r\n }\r\n break;\r\n case Compliance.ImportContentTypeIdEnum.AssetsCreateSplits:\r\n assetEffectiveDate = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.AssetsCreateSplitsEffectiveDate).value;\r\n break;\r\n case Compliance.ImportContentTypeIdEnum.AssetsUpdateClassification:\r\n assetEffectiveDate = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.AssetsUpdateClassificationEffectiveDate).value;\r\n break;\r\n case Compliance.ImportContentTypeIdEnum.AssetsUpdateAssetNumber:\r\n assetEffectiveDate = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.AssetsUpdateAssetNumberEffectiveDate).value;\r\n break;\r\n case Compliance.ImportContentTypeIdEnum.IncomeStatements:\r\n this._incomeStatementsEndingDate = new Date(this._importFile.fileFields.find(x => +x.importFieldId === Compliance.ImportFieldIdEnum.IncomeStatementEndingDate).value);\r\n break;\r\n case Compliance.ImportContentTypeIdEnum.RentRoll:\r\n this._rentRollEndingDate = new Date(this._importFile.fileFields.find(x => +x.importFieldId === Compliance.ImportFieldIdEnum.RentRollEndDate).value);\r\n break;\r\n case Compliance.ImportContentTypeIdEnum.GLAccount:\r\n const intendedUse = this._importFile.fileFields.find(i => +i.importFieldId === Compliance.ImportFieldIdEnum.GLAccountIntendedUse).value;\r\n this._glAccountsIntendedUse = this._entityImportService.glAccountIntendedUseOptions.find(x => x.value === intendedUse).name;\r\n break;\r\n }\r\n\r\n if (assetEffectiveDate) {\r\n this._assetEffectiveDate = new Date(assetEffectiveDate);\r\n }\r\n\r\n if (this._assetOwnershipTypeId || this._assetOwnershipTypeId === 0) {\r\n const assetOwnershipTypes = await lastValueFrom(this._assetRepository.getOwnershipTypes());\r\n const assetOwnershipType = assetOwnershipTypes.find(i => i.assetOwnershipTypeId === this._assetOwnershipTypeId);\r\n\r\n if (assetOwnershipType) {\r\n this._assetOwnershipTypeName = assetOwnershipType.description;\r\n }\r\n }\r\n\r\n this._importStatusChangeSub = this._websocketListenerService.longRunningProcessStatusChange$.subscribe(x => this._wsHandleStatusChange(x));\r\n this._importProgressChangeSub = this._websocketListenerService.longRunningProcessProgressChange$.subscribe(x => this._wsHandleProgressChange(x));\r\n\r\n await this._dynamicFieldBehaviorService.initialize(this._importFile.importContentType, this._importFile.dynamicFieldBehavior,\r\n this._importFile.setAllDynamicFieldBehavior, this._importFile.dynamicFieldsBehavior, this._importFile.importContentType.importFields,\r\n this._importFile.assignedFields);\r\n }\r\n\r\n destroy() : void{\r\n this._importStatusChangeSub && this._importStatusChangeSub.unsubscribe();\r\n this._importProgressChangeSub && this._importProgressChangeSub.unsubscribe();\r\n }\r\n\r\n async validate(importFileId: number, model?: Compliance.ImportValidateModel): Promise {\r\n const result = await lastValueFrom(this._entityImportRepository.validate(importFileId, model));\r\n this._longRunningProcessId = result.longRunningProcessId;\r\n this._importFile.processStatus = Compliance.ImportFileProcessStatusEnum.Validating;\r\n }\r\n\r\n getValidationSummary(importFileId: number): Promise {\r\n const promise = lastValueFrom(this._entityImportRepository.getValidationSummary(importFileId))\r\n .then((data) => {\r\n this._importFile.processStatus = Compliance.ImportFileProcessStatusEnum.Validated;\r\n this.notifyValidationSummaryChanged(data);\r\n this.notifyErrorFilterChanged([]);\r\n });\r\n\r\n this.notifyValidated(promise);\r\n\r\n return promise;\r\n }\r\n\r\n evaluate(importFileId: number, selectedRowsModel: Compliance.SelectedRowsModel): Promise {\r\n const promise = lastValueFrom(this._entityImportRepository.evaluate(importFileId, selectedRowsModel));\r\n this.notifyEvaluating(promise);\r\n\r\n promise.then(result => {\r\n this._lastEvaluationResult = result;\r\n if (this._selectedRowsInfo){\r\n this._selectedRowsInfo.evaluatedInsertCount = result.insertCount;\r\n this._selectedRowsInfo.evaluatedUpdateCount = result.updateCount;\r\n this._selectedRowsInfo.evaluatedDeleteCount = result.deleteCount;\r\n this._selectedRowsInfo.evaluatedNoChangeCount = result.noChangeCount;\r\n }\r\n });\r\n\r\n return promise;\r\n }\r\n\r\n async transfer(): Promise {\r\n const params: TransferConfirmParams = {\r\n evaluatedInsertCount: this._selectedRowsInfo.evaluatedInsertCount,\r\n evaluatedUpdateCount: this._selectedRowsInfo.evaluatedUpdateCount,\r\n evaluatedDeleteCount: this._selectedRowsInfo.evaluatedDeleteCount,\r\n evaluatedNoChangeCount: this._selectedRowsInfo.evaluatedNoChangeCount,\r\n effectiveDate: this._assetEffectiveDate,\r\n assetOwnershipType: this._assetOwnershipTypeName,\r\n accrualAdjustmentAmountValueType: this._accrualAdjustmentAmountValueType,\r\n importContentType: this._importFile.importContentTypeId\r\n };\r\n\r\n return await this._modalService.showAsync(TransferConfirmComponent, params, 'modal-md');\r\n }\r\n\r\n startTransfer(importFileId: number, selectedRowsModel: Compliance.SelectedRowsModel): Promise {\r\n return lastValueFrom(this._entityImportRepository.transfer(importFileId, selectedRowsModel));\r\n }\r\n\r\n updateCell(importId: number, rowIndex: number, importFileSpecificationImportFieldId: number, value: string): Promise {\r\n const promise = lastValueFrom(this._entityImportRepository.updateImportFieldValue(importId, rowIndex, importFileSpecificationImportFieldId, value));\r\n promise.then(x => this.notifyCellUpdated(x));\r\n return promise;\r\n }\r\n\r\n get notValidatedUpdates$(): Observable {\r\n return this._cellUpdatedEventEmitter.asObservable();\r\n }\r\n\r\n notifyCellUpdated(value: number) {\r\n this._cellUpdatedEventEmitter.emit(value);\r\n }\r\n\r\n get validationSummaryChanged$(): Observable {\r\n return this._validationSummaryBehaviorSubject\r\n .asObservable().pipe(\r\n distinctUntilChanged((\r\n x: Compliance.ImportFileValidationErrorModel[],\r\n y: Compliance.ImportFileValidationErrorModel[]) => _.isEqual(x, y)));\r\n }\r\n\r\n notifyValidationSummaryChanged(validationErrors: Compliance.ImportFileValidationErrorModel[]): void {\r\n this._validationSummaryBehaviorSubject.next(validationErrors);\r\n }\r\n\r\n get validated$(): Observable> {\r\n return this._validatedEventEmitter.asObservable();\r\n }\r\n\r\n notifyValidated(promise: Promise) {\r\n this._validatedEventEmitter.next(promise);\r\n }\r\n\r\n get evaluating$(): Observable> {\r\n return this._evaluatingEventEmitter.asObservable();\r\n }\r\n\r\n notifyEvaluating(promise: Promise) {\r\n this._evaluatingEventEmitter.emit(promise);\r\n }\r\n\r\n get selectedRowsChanged$(): Observable {\r\n return this._selectedRowsEventEmitter.asObservable();\r\n }\r\n\r\n notifySelectedRowsChanged(selectedRowsModel: Compliance.ImportBulkOperationModel, selectedRowsCount: number) {\r\n this._selectedRowsEventEmitter.emit({ selectedRowsModel: selectedRowsModel, selectedRowsCount: selectedRowsCount });\r\n }\r\n\r\n get errorFilterChanged$(): Observable {\r\n return this._errorFilterChangedBehaviorSubject\r\n .asObservable().pipe(\r\n distinctUntilChanged((\r\n x: Compliance.ImportFileValidationErrorModel[],\r\n y: Compliance.ImportFileValidationErrorModel[]) => _.isEqual(x, y)));\r\n }\r\n\r\n notifyErrorFilterChanged(errors: Compliance.ImportFileValidationErrorModel[]) {\r\n this._errorFilterChangedBehaviorSubject.next(errors);\r\n }\r\n\r\n getValidationResults(importFileId: number): Promise{\r\n return lastValueFrom(this._entityImportRepository.getValidationSummary(importFileId));\r\n }\r\n\r\n async deleteStagingRows(importFileId: number, selectedRowsModel: Compliance.ImportBulkOperationModel): Promise{\r\n this._importFile = await lastValueFrom(this._entityImportRepository.deleteStagingRows(importFileId, selectedRowsModel));\r\n\r\n if (this._importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Completed ||\r\n this._importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Transferred) {\r\n this._importFile.processStatus = Compliance.ImportFileProcessStatusEnum.ProcessingCompleted;\r\n }\r\n\r\n this._importStatusSubject.next(this._importFile);\r\n return this._importFile;\r\n }\r\n\r\n get showValidRowsOnlyChanged$(): Observable {\r\n return this._showValidRowsOnlyEventEmitter.asObservable();\r\n }\r\n\r\n notifyShowValidRowsOnlyChanged(showValidRowsOnly: boolean) {\r\n this._showValidRowsOnlyEventEmitter.emit(showValidRowsOnly);\r\n }\r\n\r\n get assetEffectiveDate(): Date {\r\n return this._assetEffectiveDate;\r\n }\r\n\r\n get assetOwnershipTypeId(): number {\r\n return this._assetOwnershipTypeId;\r\n }\r\n\r\n get assetOwnershipTypeName(): string {\r\n return this._assetOwnershipTypeName;\r\n }\r\n\r\n get accrualAdjustmentAmountValueType(): string {\r\n return this._accrualAdjustmentAmountValueType;\r\n }\r\n\r\n async getSelectedRowsInfo(importFileId: number, selectedRowsModel: Compliance.ImportBulkOperationModel): Promise {\r\n this._selectedRowsInfo = await lastValueFrom(this._entityImportRepository.getSelectedRowsInfo(importFileId, selectedRowsModel));\r\n return this._selectedRowsInfo;\r\n }\r\n\r\n canDelete(importFile: Compliance.ImportFileModel): boolean {\r\n return (importFile.processStatus === Compliance.ImportFileProcessStatusEnum.ShowPreview ||\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.ProcessingCompleted ||\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.ProcessingError ||\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Validated ||\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.TransferError && importFile.transferredRows === 0);\r\n }\r\n\r\n get forceValidate$(): Observable {\r\n return this._forceValidateSubject.asObservable();\r\n }\r\n\r\n forceValidate() {\r\n this._forceValidateSubject.next();\r\n }\r\n\r\n get importContentTypeId(): number {\r\n return this._importFile.importContentTypeId;\r\n }\r\n\r\n get sitesUpdatesOnlyMatchBy(): string {\r\n return this._sitesUpdatesOnlyMatchBy;\r\n }\r\n\r\n get taxPaymentsMatchOverall(): string {\r\n return this._taxPaymentsMatchOverall;\r\n }\r\n\r\n get isTaxPaymentsImportMatchByPaymentSystemId(): boolean {\r\n return this._isTaxPaymentsImportMatchByPaymentSystemId;\r\n }\r\n\r\n get taxPaymentsMatchParcel(): string {\r\n return this._taxPaymentsMatchParcel;\r\n }\r\n\r\n get taxPaymentsMatchCollector(): string {\r\n return this._taxPaymentsMatchCollector;\r\n }\r\n\r\n get incomeStatementsEndingDate(): Date {\r\n return this._incomeStatementsEndingDate;\r\n }\r\n\r\n get rentRollEndingDate(): Date {\r\n return this._rentRollEndingDate;\r\n }\r\n\r\n get glAccountsIntendedUse(): string {\r\n return this._glAccountsIntendedUse;\r\n }\r\n\r\n get clearErrorsWarningsSelectionChanged$(): Observable {\r\n return this._clearErrorsWarningsSelectionEventEmitter.asObservable();\r\n }\r\n\r\n notifyClearErrorsWarningsSelection() {\r\n this._clearErrorsWarningsSelectionEventEmitter.emit();\r\n }\r\n\r\n private async _wsHandleStatusChange(statusChange: Compliance.LongRunningProcessStatusChangeModel): Promise {\r\n if (!(this._importFile && this._importFile.importFileId === statusChange.entityId && statusChange.isCompleted)) {\r\n return;\r\n }\r\n\r\n // reload\r\n this._importFile = await lastValueFrom(this._entityImportRepository.getImport(this._importFile.importFileId));\r\n\r\n if (this._importFile.longRunningProcessId === statusChange.longRunningProcessId) {\r\n //hack\r\n if (statusChange.operationName === 'Validate' && this._importFile.processStatus !== Compliance.ImportFileProcessStatusEnum.Validated) {\r\n this._importFile.processStatus = Compliance.ImportFileProcessStatusEnum.Validating;\r\n } else if (statusChange.operationName === 'Transfer') {\r\n this._importFile.processStatus = Compliance.ImportFileProcessStatusEnum.TransferCompleted;\r\n } else if (statusChange.operationName === 'Bulk Update') {\r\n this._importFile.processStatus = Compliance.ImportFileProcessStatusEnum.BulkUpdated;\r\n }\r\n\r\n this._importProcessStatusError = statusChange.errorMessage;\r\n this._importStatusSubject.next(this._importFile);\r\n }\r\n }\r\n\r\n private async _wsHandleProgressChange(progressChange: Compliance.LongRunningProcessProgressChangeModel): Promise {\r\n if (this._importFile && this._importFile.importFileId === progressChange.entityId) {\r\n this._importProgressStatusSubject.next(progressChange);\r\n }\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Data Imports\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit, ViewChild } from '@angular/core';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { EntityImportRepository, LongRunningProcessRepository } from '../../Repositories';\r\nimport { WebsocketListenerService } from '../../websocketListener.service';\r\nimport { InstanceRights, RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { EntityImportListDataSourceParams, EntityImportListGridDataSource } from './agGridDataSource';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, RowNode } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../AgGrid';\r\nimport {\r\n EntityImportListGridProgressCellRendererComponent,\r\n ICellRendererParamsForProgressCell\r\n} from './agGridProgressCellRenderer.component';\r\nimport {\r\n EntityImportListGridActionCellRendererComponent,\r\n ICellRendererParamsForImportListGridAction\r\n} from './agGridActionCellRenderer.component';\r\nimport { WeissmanDateTimeFormatPipe } from '../../../UI-Lib/Pipes';\r\nimport { BeginNewImportComponent } from '../../../Common/import/beginNewImport.component';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { IMPORT_LIST_HELP } from './importList.component.help';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { EntityImportProcessService } from '../Import-Process/importProcess.service';\r\nimport { InstanceRepository } from '../../../Entity/Instance/instance.repository';\r\n\r\n@Component({\r\n selector: 'entity-import-list',\r\n templateUrl: './importList.component.html',\r\n styleUrls: ['./importList.component.scss']\r\n})\r\nexport class EntityImportListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _companyService: CompanyService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _entityImportRepository: EntityImportRepository,\r\n private readonly _websocketListenerService: WebsocketListenerService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _datetimePipe: WeissmanDateTimeFormatPipe,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _helpService: HelpService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _importService: EntityImportProcessService,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private readonly _longRunningProcessRepository: LongRunningProcessRepository) { }\r\n\r\n @ViewChild('newImport') newImport: BeginNewImportComponent;\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n isCompanyImport: boolean = false;\r\n isInitialized: boolean = false;\r\n canEdit: boolean = false;\r\n companyId?: number = null;\r\n companyName: string;\r\n gridId: System.Guid = 'F056E620-C711-47E0-A059-BD70FBC078AE';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n includeCompleted: boolean = false;\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: EntityImportListGridDataSource;\r\n private _hasComplianceFeaturePermission: boolean;\r\n private _destroy$: Subject = new Subject();\r\n\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n get dataImportSpecificationsHelpContentId(): string {\r\n return this.companyId ?\r\n 'import-list.data-import-specifications-company' :\r\n 'import-list.data-import-specifications';\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this.isCompanyImport = !!this._routerService.getQuerystringParam('companyId');\r\n\r\n this._helpService.setContent(IMPORT_LIST_HELP);\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n if (this.isCompanyImport) {\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n this.canEdit = await this._restrictService.hasCompanyPermission(this.companyId, Core.AccessRightsEnum.Write);\r\n const instanceId = await lastValueFrom(this._instanceRepository.getEntityInstanceId('company', this.companyId));\r\n\r\n this._hasComplianceFeaturePermission = this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, instanceId);\r\n\r\n if(!this._restrictService.hasInstanceRight(InstanceRights.COMPANYDATAIMPORTSVIEW, instanceId)) {\r\n this.navigateToUnauthorized();\r\n }\r\n\r\n const company = await this._companyService.load(this.companyId, false, false);\r\n\r\n if (company.companyID !== company.topLevelCompanyId) {\r\n this._toastr.error('Data imports are not allowed on subsidiary companies.');\r\n this.navigateToCompany();\r\n return;\r\n }\r\n\r\n this.companyName = company.companyName;\r\n\r\n this.breadcrumbs.push({\r\n name: company.companyName,\r\n target: 'company',\r\n options: { companyId: company.companyID }\r\n });\r\n } else {\r\n if(!this._restrictService.isInRole(Roles.ALLOWDATAIMPORTS) && !this._restrictService.isInRole(Roles.TAXRATESETUP) &&\r\n !this._restrictService.hasInstanceRight(InstanceRights.INSTANCEDATAIMPORTS)) {\r\n this.navigateToUnauthorized();\r\n }\r\n\r\n this.canEdit = true;\r\n this.isInitialized = true;\r\n }\r\n this.isInitialized = true;\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n this._websocketListenerService.longRunningProcessStatusChange$.pipe(takeUntil(this._destroy$)).subscribe(\r\n async (x) => {\r\n if (x.processType !== Compliance.LongRunningProcessTypeEnum.ImportFile) {\r\n return;\r\n }\r\n\r\n if(!x.isCompleted) {\r\n return;\r\n }\r\n\r\n if (!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const rowNode: RowNode = this._gridDataSource.getShownNodes().find(r => {\r\n const importFile = r.data as Compliance.ImportFileModel;\r\n return importFile && importFile.importFileId === x.entityId;\r\n });\r\n\r\n if(!rowNode) {\r\n return;\r\n }\r\n\r\n await this._updateRowModel(x.entityId);\r\n });\r\n\r\n this._websocketListenerService.longRunningProcessProgressChange$.pipe(takeUntil(this._destroy$)).subscribe(\r\n async (x) => {\r\n if (x.processType !== Compliance.LongRunningProcessTypeEnum.ImportFile) {\r\n return;\r\n }\r\n\r\n if(!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const rowNode: RowNode = this._gridDataSource.getShownNodes().find(r => {\r\n const importFile = r.data as Compliance.ImportFileModel;\r\n return importFile && importFile.importFileId === x.entityId;\r\n });\r\n\r\n if(!rowNode) {\r\n return;\r\n }\r\n\r\n await this._gridDataSource.updateRow(y => {\r\n const rowModel = y.data as Compliance.ImportFileModel;\r\n return rowModel && rowModel.importFileId === x.entityId;\r\n },\r\n async y => {\r\n const rowModel = y.data as Compliance.ImportFileModel;\r\n\r\n if (rowModel.processStatus === Compliance.ImportFileProcessStatusEnum.Transferring) {\r\n rowModel.transferredRows = x.current;\r\n }\r\n\r\n if(rowModel.processStatus === Compliance.ImportFileProcessStatusEnum.Processing || rowModel.processStatus === Compliance.ImportFileProcessStatusEnum.ProcessingCompleted) {\r\n rowModel.totalRows = x.total;\r\n }\r\n\r\n return Promise.resolve(rowModel);\r\n });\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Name',\r\n field: 'displayName',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Progress',\r\n field: 'displayStatus',\r\n width: 175,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n sortable: false,\r\n cellRendererFramework: EntityImportListGridProgressCellRendererComponent,\r\n cellRendererParams: {\r\n resume: this._onProgressResume.bind(this)\r\n } as ICellRendererParamsForProgressCell\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'importContentType.name',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n },\r\n {\r\n headerName: 'Filename',\r\n field: 'fileName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n },\r\n {\r\n headerName: 'Created',\r\n field: 'createDate',\r\n valueFormatter: (params) => {\r\n return this._datetimePipe.transform(params.value, true, 'central');\r\n },\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n },\r\n {\r\n headerName: 'Owner',\r\n field: 'ownerName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Transferred / Total',\r\n field: 'transferredRows',\r\n type: 'numericColumn',\r\n valueFormatter: (params) => {\r\n return params.data\r\n ? `${this._decimalPipe.transform(params.data.transferredRows, '1.0-0')} / ${this._decimalPipe\r\n .transform(params.data.totalRows, '1.0-0')}`\r\n : '';\r\n },\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(4),\r\n minWidth: AgGridColumns.getActionColumnWidth(4),\r\n maxWidth: AgGridColumns.getActionColumnWidth(4),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'right',\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: EntityImportListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n resume: this._onResume.bind(this),\r\n delete: this._onDelete.bind(this),\r\n canDelete: this._canDelete.bind(this),\r\n revert: this._onRevert.bind(this),\r\n canRevert: this._canRevert.bind(this),\r\n complete: this._onComplete.bind(this),\r\n canComplete: this._canComplete.bind(this)\r\n } as ICellRendererParamsForImportListGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'createDate',\r\n sort: 'desc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n refresh(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n navigateToCompany(): void {\r\n this._routerService.go('company', { 'companyId': this.companyId });\r\n }\r\n\r\n async onIncludeCompletedChange(): Promise {\r\n this._refreshDataSource();\r\n }\r\n\r\n navigateToImportSpecifications(): void {\r\n if (this.companyId) {\r\n this._routerService.go('companyImportSpecificationList', { 'companyId': this.companyId });\r\n } else {\r\n this._routerService.go('importSpecificationList', {});\r\n }\r\n }\r\n\r\n private _canDelete(params: ICellRendererParamsForImportListGridAction): boolean {\r\n const importFile = params.data as Compliance.ImportFileModel;\r\n if (!importFile) {\r\n return false;\r\n }\r\n\r\n return this._importService.canDelete(importFile);\r\n }\r\n\r\n private _onDelete(params: ICellRendererParamsForImportListGridAction) {\r\n const importFile = params.data as Compliance.ImportFileModel;\r\n if (!importFile) {\r\n return;\r\n }\r\n\r\n this._deleteImport(importFile.importFileId);\r\n }\r\n\r\n private async _deleteImport(importFileId: number): Promise {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to delete the data import?',\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n try {\r\n await lastValueFrom(this._entityImportRepository.deleteImport(importFileId));\r\n this._refreshDataSource();\r\n return Promise.resolve(true);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n private _onProgressResume(params: ICellRendererParamsForProgressCell) {\r\n this._resumeImport(params.data as Compliance.ImportFileModel);\r\n }\r\n\r\n private _onResume(params: ICellRendererParamsForImportListGridAction) {\r\n this._resumeImport(params.data as Compliance.ImportFileModel);\r\n }\r\n\r\n private async _resumeImport(importFile: Compliance.ImportFileModel): Promise {\r\n if (!importFile) {\r\n return;\r\n }\r\n\r\n let message = '';\r\n\r\n if (importFile.processStatus === Compliance.ImportFileProcessStatusEnum.ProcessingError) {\r\n message = importFile.error || 'An error occurred while processing the file. Delete it and try again.';\r\n }\r\n\r\n if (importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Reverting) {\r\n message = 'The transferred data is currently being reverted . You\\'ll be able to resume working on the data import when it\\'s done.';\r\n }\r\n\r\n if (importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Processing ||\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Transferring) {\r\n this._showImportProgress(importFile);\r\n return;\r\n }\r\n\r\n if (importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Uploaded ||\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.ShowPreview) {\r\n const resumeResult = await this.newImport.resumeImport(importFile);\r\n if (resumeResult) {\r\n this._gridDataSource.updateRow(\r\n x => {\r\n const rowData = x.data as Compliance.ImportFileModel;\r\n return rowData && rowData.importFileId === resumeResult.importFileId;\r\n },\r\n () => Promise.resolve(resumeResult),\r\n false);\r\n }\r\n return;\r\n }\r\n\r\n if (message) {\r\n this._messageModalService.alert(message);\r\n } else {\r\n if (importFile.companyId) {\r\n this._routerService.go('processCompanyImport', { companyId: importFile.companyId, importId: importFile.importFileId });\r\n } else {\r\n this._routerService.go('processSystemImport', { importId: importFile.importFileId });\r\n }\r\n }\r\n }\r\n\r\n private _refreshDataSource() {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n const dataSourceParams = (): EntityImportListDataSourceParams => {\r\n return {\r\n isCompanyImport: this.isCompanyImport,\r\n includeCompleted: this.includeCompleted,\r\n companyId: this.companyId\r\n };\r\n };\r\n\r\n this._gridDataSource = new EntityImportListGridDataSource(this._gridApi, this._entityImportRepository, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private _onRevert(params: ICellRendererParamsForImportListGridAction) {\r\n const importFile = params.data as Compliance.ImportFileModel;\r\n if (!importFile) {\r\n return;\r\n }\r\n\r\n this._revertImport(importFile.importFileId);\r\n }\r\n\r\n private async _revertImport(importFileId: number): Promise {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to revert the data import? Any parcel override updates were set during the import will not be removed.',\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const messageId = 'reverting';\r\n const message = 'Reverting Data Import';\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: message, identifier: messageId });\r\n try {\r\n await lastValueFrom(this._entityImportRepository.revertImport(importFileId));\r\n } catch (e) {\r\n if (e && e.status === 423) {\r\n try {\r\n busyRef.hide();\r\n await this._messageModalService.confirm(\r\n `${e.error.message } Are you sure you wish to take ownership?`,\r\n 'Confirm Take Ownership');\r\n } catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n busyRef.updateMessage('Taking ownership of the Data Import', messageId);\r\n\r\n try{\r\n await lastValueFrom(this._entityImportRepository.takeOwnership(importFileId));\r\n }\r\n finally{\r\n busyRef.updateMessage(message, messageId);\r\n\r\n try {\r\n await lastValueFrom(this._entityImportRepository.revertImport(importFileId));\r\n } catch (error) {\r\n // The ownership updated but the revert failed. Refresh the table row to reflect the new owner\r\n await this._updateRowModel(importFileId);\r\n throw error;\r\n }\r\n\r\n return Promise.resolve(true);\r\n }\r\n } else {\r\n throw e;\r\n }\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n\r\n return Promise.resolve(true);\r\n }\r\n\r\n private async _updateRowModel(importFileId: number): Promise {\r\n await this._gridDataSource.updateRow(\r\n y => {\r\n const rowModel = y.data as Compliance.ImportFileModel;\r\n return rowModel && rowModel.importFileId === importFileId;\r\n },\r\n async (y) => {\r\n const importFile = await lastValueFrom(this._entityImportRepository.getImport(importFileId, true));\r\n const rowModel = y.data as Compliance.ImportFileModel;\r\n importFile.createDate = rowModel.createDate; // todo: grid is sorted by create date by default, date comparison always returns false\r\n return importFile;\r\n });\r\n }\r\n\r\n private _canRevert(params: ICellRendererParamsForImportListGridAction): boolean {\r\n const importFile = params.data as Compliance.ImportFileModel;\r\n if (!importFile) {\r\n return false;\r\n }\r\n\r\n return this._hasComplianceFeaturePermission && importFile.canBeReverted && (\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Completed ||\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Transferred ||\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.TransferCompleted ||\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.RevertingError ||\r\n importFile.processStatus === Compliance.ImportFileProcessStatusEnum.TransferError && importFile.transferredRows !== 0);\r\n }\r\n\r\n private async _showImportProgress(importFile: Compliance.ImportFileModel): Promise {\r\n await this.newImport.showImportFileIsProcessingMessage(importFile);\r\n }\r\n\r\n private _onComplete(params: ICellRendererParamsForImportListGridAction) {\r\n const importFile = params.data as Compliance.ImportFileModel;\r\n if (!importFile || importFile.processStatus === Compliance.ImportFileProcessStatusEnum.Completed) {\r\n return;\r\n }\r\n\r\n this._completeImport(importFile.importFileId);\r\n }\r\n\r\n private async _completeImport(importFileId: number): Promise {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to mark the data import as completed?',\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Completing Data Import' });\r\n try {\r\n await lastValueFrom(this._entityImportRepository.markAsCompleted(importFileId));\r\n this._refreshDataSource();\r\n return Promise.resolve(true);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _canComplete(params: ICellRendererParamsForImportListGridAction): boolean {\r\n const importFile = params.data as Compliance.ImportFileModel;\r\n if (!importFile) {\r\n return false;\r\n }\r\n\r\n return this._hasComplianceFeaturePermission && importFile.processStatus !== Compliance.ImportFileProcessStatusEnum.Completed && importFile.transferredRows !== 0;\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n
\r\n

Save the import specification by choosing one of the options below.

\r\n

You made changes after applying the import specification. How would you like to proceed?

\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n Note: Null property characteristics will default to Ignore\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { ImportSpecificationRepository } from '../../../../Repositories';\r\nimport { BusyIndicatorMessageManager } from '../../../../../Busy-Indicator';\r\nimport { RestrictService, Roles } from '../../../../../Common/Permissions/restrict.service';\r\nimport { IWeissmanModalComponent } from '../../../../WeissmanModalService';\r\nimport { DynamicFieldBehaviorService } from '../../Dynamic-Field-Behavior/dynamicFieldBehavior.service';\r\n\r\nexport interface ImportSpecificationMappingParams {\r\n importFileId: number;\r\n companyId?: number;\r\n importFileSpecificationId: number;\r\n importFileSpecificationName: string;\r\n allowNoSave: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-specification-mapping',\r\n templateUrl: './importSpecificationMapping.component.html'\r\n})\r\nexport class EntityImportSpecificationMappingComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _modalRef: BsModalRef,\r\n private readonly _entityImportSpecificationRepository: ImportSpecificationRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _dynamicFieldBehaviorService: DynamicFieldBehaviorService) {\r\n }\r\n\r\n params: ImportSpecificationMappingParams;\r\n result: Compliance.ImportFileSpecificationModel;\r\n\r\n specificationName: string;\r\n viewType: string = '';\r\n saveType: string;\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n supportsDynamicFieldConfiguration: boolean;\r\n\r\n get canSaveSharedSpecs(): boolean {\r\n return this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT);\r\n }\r\n\r\n ngOnInit(): void {\r\n this.saveType = this.params.importFileSpecificationId ? 'update' : 'insert';\r\n this.supportsDynamicFieldConfiguration = this._dynamicFieldBehaviorService.showDynamicFieldConfiguration;\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n async saveSpecification() : Promise {\r\n if (!this.viewType && this.saveType === 'insert') {\r\n return;\r\n }\r\n\r\n let existingFileSpecificationId: number = null;\r\n let companyId: number = null;\r\n let isShared: boolean = false;\r\n let specificationName: string;\r\n\r\n switch (this.saveType) {\r\n case 'update':\r\n existingFileSpecificationId = this.params.importFileSpecificationId;\r\n specificationName = this.params.importFileSpecificationName;\r\n break;\r\n case 'nosave':\r\n this.cancel();\r\n return;\r\n default: //insert\r\n specificationName = this.specificationName;\r\n break;\r\n }\r\n\r\n const fromImportFileId = this.params.importFileId;\r\n\r\n switch (this.viewType) {\r\n case 'shared':\r\n isShared = true;\r\n break;\r\n case 'company':\r\n companyId = this.params.companyId;\r\n break;\r\n default:\r\n break; //If private, defaults should suffice\r\n }\r\n\r\n const spec: Compliance.ImportFileSpecificationImportUpdateModel = {\r\n displayName: specificationName,\r\n companyId: companyId,\r\n importFileSpecificationId: existingFileSpecificationId,\r\n importFileId: fromImportFileId,\r\n isShared: isShared\r\n };\r\n\r\n this.busyIndicatorMessageManager.add('Saving', 'saving');\r\n\r\n try {\r\n this.result = await lastValueFrom(this._entityImportSpecificationRepository.createOrUpdateFromImport(spec));\r\n\r\n this._modalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove('saving');\r\n }\r\n }\r\n}\r\n","import {HelpContent} from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const IMPORT_PROCESS_HELP:HelpContent[] = [\r\n {\r\n helpContentId: 'import-process.next-step-validate',\r\n tooltipText: 'Validate imported data.'\r\n },\r\n {\r\n helpContentId: 'import-process.next-step-validate.disabled',\r\n tooltipText: 'Not available until all required fields have been mapped.'\r\n },\r\n {\r\n helpContentId: 'import-process.next-step-evaluate',\r\n tooltipText: 'Evaluates if each selected row will be created, updated or unchanged when transferred to the database.'\r\n },\r\n {\r\n helpContentId: 'import-process.next-step-evaluate.disabled.no-selection',\r\n tooltipText: 'Select rows to evaluate for transfer.'\r\n },\r\n {\r\n helpContentId: 'import-process.next-step-evaluate.disabled.no-nochanges',\r\n tooltipText: 'Selection does not have any insert/update rows.'\r\n },\r\n {\r\n helpContentId: 'import-process.next-step-evaluate.disabled.invalid-selection',\r\n tooltipText: 'Select valid rows to evaluate for transfer.'\r\n },\r\n {\r\n helpContentId: 'import-process.next-step-transfer',\r\n tooltipText: 'Transfer evaluated rows to the database.'\r\n },\r\n {\r\n helpContentId: 'import-process.close',\r\n tooltipText: 'Close data import.'\r\n },\r\n {\r\n helpContentId: 'import-process.back.edit',\r\n tooltipText: 'Go back to field mapping.'\r\n },\r\n {\r\n helpContentId: 'import-process.back',\r\n tooltipText: 'Close data import.'\r\n },\r\n {\r\n helpContentId: 'import-process.mark-completed',\r\n tooltipText: 'Mark data import as completed.'\r\n },\r\n {\r\n helpContentId: 'import-process.mark-completed-disabled',\r\n tooltipText: 'Data import cannot be marked as completed if already completed or no rows have been transferred.'\r\n },\r\n {\r\n helpContentId: 'import-process.revalidate',\r\n tooltipText: 'Revalidate selected rows or the whole file if no rows selected.'\r\n },\r\n {\r\n helpContentId: 'import-process.delete',\r\n tooltipText: 'Delete data import.'\r\n },\r\n {\r\n helpContentId: 'import-process.delete-disabled',\r\n tooltipText: 'Data import cannot be deleted if already completed or at least one row has been transferred.'\r\n },\r\n {\r\n helpContentId: 'import-process.has-not-validated-updates',\r\n tooltipText: 'Pending updates detected. Import must be revalidated.'\r\n }\r\n];\r\n","import { Injectable, EventEmitter } from '@angular/core';\r\nimport { lastValueFrom, Observable } from 'rxjs';\r\nimport { EntityImportRepository } from '../../../Repositories';\r\nimport { ImportSpecificationRepository } from '../../../Repositories';\r\nimport { DynamicFieldBehaviorService } from '../Dynamic-Field-Behavior/dynamicFieldBehavior.service';\r\n\r\nexport interface ImportFileSpecificationInfo {\r\n importFileSpecificationId: number;\r\n displayName: string;\r\n companyId: number;\r\n}\r\n\r\n@Injectable()\r\nexport class EntityImportColumnMappingStepService {\r\n constructor(\r\n private readonly _entityImportRepository: EntityImportRepository,\r\n private readonly _entityImportSpecificationRepository: ImportSpecificationRepository,\r\n private readonly _dynamicFieldBehaviorService: DynamicFieldBehaviorService) { }\r\n\r\n private _headers: Compliance.ImportFileHeaderModel[] = [];\r\n private _fields: Compliance.ImportFieldModel[] = [];\r\n private _fieldMappings: Compliance.ImportFileSpecificationImportFieldModel[] = [];\r\n private _fileSpecificationId: number;\r\n private _fileSpecificationName: string;\r\n private _companyId: number;\r\n private _fieldAssigned: EventEmitter = new EventEmitter();\r\n private _fieldUnassigned: EventEmitter = new EventEmitter();\r\n\r\n async initialize(importId: number): Promise {\r\n const fileModel = await lastValueFrom(this._entityImportRepository.getImport(importId));\r\n const contentTypeModel = await lastValueFrom(this._entityImportRepository.getContentType(fileModel.importContentTypeId, fileModel.importFileId));\r\n\r\n this._headers = fileModel.importFileHeaders;\r\n this._fields = contentTypeModel.importFields;\r\n this._fieldMappings = fileModel.assignedFields;\r\n this._fileSpecificationId = fileModel.importFileSpecificationId;\r\n this._fileSpecificationName = fileModel.importFileSpecificationName;\r\n this._companyId = fileModel.companyId;\r\n\r\n await this._dynamicFieldBehaviorService.initialize(contentTypeModel, fileModel.dynamicFieldBehavior, fileModel.setAllDynamicFieldBehavior,\r\n fileModel.dynamicFieldsBehavior, this._fields, this._fieldMappings);\r\n }\r\n\r\n canAssignField(targetId: number): boolean {\r\n return this._fieldMappings.findIndex(m => (m.value === targetId.toString())) === -1;\r\n }\r\n\r\n getFileHeaders(): Compliance.ImportFileHeaderModel[] {\r\n return this._headers;\r\n }\r\n\r\n getFields(): Compliance.ImportFieldModel[] {\r\n return this._fields;\r\n }\r\n\r\n getFieldMappings(): Compliance.ImportFileSpecificationImportFieldModel[] {\r\n return this._fieldMappings;\r\n }\r\n\r\n getFileSpecificationInfo(): ImportFileSpecificationInfo {\r\n const specificationInfo: ImportFileSpecificationInfo = {\r\n importFileSpecificationId: this._fileSpecificationId,\r\n displayName: this._fileSpecificationName,\r\n companyId: this._companyId,\r\n };\r\n\r\n return specificationInfo;\r\n }\r\n\r\n async assignFieldToColumn(importId: number, fieldId: string, headerIndex: number, clarificationValues: Compliance.NameValuePair[]): Promise {\r\n const response = await lastValueFrom(this._entityImportSpecificationRepository.assignField(importId, fieldId, headerIndex, clarificationValues));\r\n this._fieldMappings.push(response);\r\n this._fieldAssigned.emit(response);\r\n return response;\r\n }\r\n\r\n async assignStaticField(importId: number, fieldId: string, value: string, clarificationValues: Compliance.NameValuePair[]): Promise {\r\n const response = await lastValueFrom(this._entityImportSpecificationRepository.assignStaticField(importId, fieldId, value, clarificationValues));\r\n this._fieldMappings.push(response);\r\n this._fieldAssigned.emit(response);\r\n return response;\r\n }\r\n\r\n async unAssignField(specificationFieldId: number): Promise {\r\n await lastValueFrom(this._entityImportSpecificationRepository.unAssignField(specificationFieldId));\r\n const fieldMapping = this._fieldMappings.find(i => i.importFileSpecificationFieldId === specificationFieldId);\r\n this._fieldMappings.splice(this._fieldMappings.indexOf(fieldMapping), 1);\r\n this._fieldUnassigned.emit(fieldMapping);\r\n }\r\n\r\n get fieldAssigned$(): Observable {\r\n return this._fieldAssigned.asObservable();\r\n }\r\n\r\n get fieldUnassigned$(): Observable {\r\n return this._fieldUnassigned.asObservable();\r\n }\r\n}\r\n","import { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport function AgGridPinnedRowCellRenderer(params: ICellRendererParams) {\r\n const colMetadata: Compliance.EntityImportMappingColDefMetadata = params.colDef['ws'];\r\n return `
${ (colMetadata && colMetadata.isStatic) ? 'Static Column' : (params.value || '-') }
`;\r\n}\r\n","import * as _ from 'lodash';\r\nimport { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { EntityImportRepository } from '../../../Repositories';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../AgGrid';\r\n\r\nexport class EntityImportEditorAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private _gridApi: GridApi,\r\n private _entityImportRepository: EntityImportRepository,\r\n private _importId: number\r\n ) { super(_gridApi); }\r\n\r\n protected canGetRows(): boolean {\r\n return !!this._importId;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const skip = params.startRow;\r\n const take = params.endRow - params.startRow;\r\n const searchModel: Compliance.ImportGridSearchModel = {\r\n pagination: {skip: skip, take: take} as Core.PaginationModel,\r\n validationErrors: [],\r\n columnFilters: [],\r\n showTransferredRows: false,\r\n showValidRowsOnly: false,\r\n estimatedActionFilter: null,\r\n sortColumns: [],\r\n includeTotals: false,\r\n includeOnlyTotals: false\r\n }\r\n\r\n const result = await lastValueFrom(this._entityImportRepository.getImportRows(this._importId, searchModel));\r\n\r\n const rows = _.sortBy(result.data, ['rowIndex']);\r\n\r\n // for each row we are given a collection of fields with their index and their value\r\n // for the grid, we will flatten all those fields into one object where\r\n // the key will be the field index, the value will be the current value\r\n const gridRows: Compliance.ImportGridRow[] = rows.map((i: Compliance.ImportGridRow) => {\r\n const gridRow: Compliance.ImportGridRow = {} as Compliance.ImportGridRow;\r\n\r\n // if the current values are null then load them from the original values\r\n i.fields.forEach((f) => { gridRow[f.fieldIndex] = f.currentValue === null ? f.originalValue : f.currentValue; });\r\n\r\n // set the rowIndex property for each row\r\n gridRow.rowIndex = i.rowIndex;\r\n return gridRow;\r\n });\r\n\r\n return {\r\n rows: gridRows,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n}\r\n","import { Component, OnDestroy } from '@angular/core';\r\nimport { IHeaderAngularComp } from 'ag-grid-angular';\r\nimport { IHeaderParams, IAfterGuiAttachedParams } from 'ag-grid-community';\r\nimport { EntityImportColumnMappingStepService } from './columnMappingStep.service';\r\nimport { Subscription } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'ag-grid-mapping-header-row-cell-renderer',\r\n template: `\r\n
\r\n {{ headerName }}\r\n \r\n
\r\n `\r\n})\r\nexport class AgGridMappingHeaderRowCellRendererComponent implements IHeaderAngularComp, OnDestroy {\r\n constructor(private _columnMappingStepService: EntityImportColumnMappingStepService) { }\r\n\r\n private _params: IHeaderParams;\r\n\r\n private _fieldAssignedSub: Subscription;\r\n\r\n private _enableMappingMaintenance: boolean;\r\n\r\n // the import file header that this column is associated with\r\n private _headerId: number;\r\n\r\n // the specification link for that field mapping\r\n private _specificationFieldId: number;\r\n\r\n private _refresh(): void {\r\n // collect information\r\n let isHeaderMappedToRequiredField: boolean = false;\r\n let isStaticColumn = false;\r\n let isUnknown: boolean = false;\r\n let fieldName: string = '';\r\n\r\n const isHeaderMapped = this._specificationFieldId > 0;\r\n\r\n if (isHeaderMapped) {\r\n const fieldMapping = this._columnMappingStepService.getFieldMappings().find((i) => i.importFileSpecificationFieldId === this._specificationFieldId);\r\n const field = this._columnMappingStepService.getFields().find((i) => i.importFieldId === fieldMapping.importFieldId);\r\n\r\n if (field) {\r\n isHeaderMappedToRequiredField = field.isMappingRequired;\r\n isStaticColumn = fieldMapping.isStatic;\r\n fieldName = field.displayName;\r\n } else {\r\n fieldName = 'Unknown field';\r\n isUnknown = true;\r\n }\r\n }\r\n\r\n // set properties\r\n this.mappingMaintenanceAllowed = this._enableMappingMaintenance && (isHeaderMapped || isStaticColumn);\r\n\r\n if (!this._headerId) {\r\n this.headerName = this._params.displayName;\r\n }\r\n else if (isHeaderMapped || isStaticColumn) {\r\n this.headerName = fieldName;\r\n } else {\r\n this.headerName = 'Unmapped';\r\n }\r\n\r\n this.headerClass['mapping-required'] = !isUnknown && (isHeaderMapped || isStaticColumn) && isHeaderMappedToRequiredField;\r\n this.headerClass['mapping-optional'] = !isUnknown && (isHeaderMapped || isStaticColumn) && !isHeaderMappedToRequiredField;\r\n this.headerClass['unmapped'] = !isUnknown && !(isHeaderMapped || isStaticColumn);\r\n this.headerClass['mapping-unknown'] = isUnknown;\r\n }\r\n\r\n mappingMaintenanceAllowed: boolean = false;\r\n\r\n headerName: string;\r\n\r\n headerClass = {\r\n 'mapping-required': false,\r\n 'mapping-optional': false,\r\n 'unmapped': false,\r\n 'mapping-unknown': false\r\n };\r\n\r\n agInit(params: IHeaderParams): void {\r\n this._params = params;\r\n\r\n let colDefMetadata: Compliance.EntityImportMappingColDefMetadata = params.column.getColDef()['ws'];\r\n this._enableMappingMaintenance = colDefMetadata.enableMappingMaintenance;\r\n this._headerId = colDefMetadata.fileHeaderId;\r\n\r\n // when trying to figure out if a field is mapped it can be one of the following:\r\n // 1. a header ID is available and we can determine the mapping via that\r\n // 2. a field is not mapped to a header in the file but is \"mapped\" as a \"static\" field\r\n let fieldMapping = colDefMetadata.isStatic ?\r\n this._columnMappingStepService.getFieldMappings().find(i => i.isStatic && i.importFieldId === colDefMetadata.staticFieldId) :\r\n this._columnMappingStepService.getFieldMappings().find(i => i.value === colDefMetadata.fileHeaderId.toString());\r\n\r\n this._specificationFieldId = fieldMapping && fieldMapping.importFileSpecificationFieldId;\r\n\r\n this._refresh();\r\n\r\n this._fieldAssignedSub = this._columnMappingStepService.fieldAssigned$.subscribe(fieldMapping => {\r\n if (!fieldMapping.isStatic && fieldMapping.value) {\r\n let header = this._columnMappingStepService.getFileHeaders().find(i => i.importFileHeaderId.toString() === fieldMapping.value);\r\n if (header.importFileHeaderId === this._headerId) {\r\n this._specificationFieldId = fieldMapping.importFileSpecificationFieldId;\r\n this._refresh();\r\n }\r\n }\r\n });\r\n }\r\n\r\n afterGuiAttached?(params?: IAfterGuiAttachedParams): void {\r\n throw new Error('Method not implemented.');\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._fieldAssignedSub.unsubscribe();\r\n }\r\n\r\n async unAssignField(): Promise {\r\n await this._columnMappingStepService.unAssignField(this._specificationFieldId);\r\n this._specificationFieldId = null;\r\n this._refresh();\r\n }\r\n}\r\n","\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { UntypedFormControl } from \"@angular/forms\";\r\nimport { takeUntil } from \"rxjs/operators\";\r\nimport { Subject } from \"rxjs\";\r\n\r\nexport interface EntityImportStaticFieldsParams {\r\n availableImportFields: Compliance.ImportFieldModel[];\r\n}\r\n\r\nexport interface EntityImportStaticMappingInfo {\r\n staticColumn: Compliance.StaticImportFieldModel;\r\n clarificationFieldValues?: Compliance.NameValuePair[];\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-static-fields',\r\n templateUrl: './staticFields.component.html'\r\n})\r\nexport class EntityImportStaticFieldsComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(private _modalRef: BsModalRef) { }\r\n\r\n params: EntityImportStaticFieldsParams;\r\n result: EntityImportStaticMappingInfo;\r\n staticValue: string;\r\n clarificationColumn: Compliance.ImportFieldModel;\r\n clarificationFieldControl: UntypedFormControl = new UntypedFormControl();\r\n\r\n private _staticColumn: Compliance.ImportFieldModel = null;\r\n private _clarificationFieldValue: string;\r\n private destroy$: Subject = new Subject();\r\n private _availableImportFields: Compliance.ImportFieldModel[];\r\n\r\n ngOnInit(): void {\r\n this.clarificationFieldControl.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(x => {\r\n this._clarificationFieldValue = x;\r\n });\r\n\r\n this._availableImportFields = this.params.availableImportFields.filter(x => x.importFieldId !== Compliance.ImportFieldIdEnum.TaxPaymentsPaymentDueDate.toString());\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n get staticColumn(): Compliance.ImportFieldModel{\r\n return this._staticColumn;\r\n }\r\n\r\n set staticColumn(value: Compliance.ImportFieldModel) {\r\n this._staticColumn = value;\r\n\r\n if (this._staticColumn.clarificationFields && this._staticColumn.clarificationFields.length){\r\n this.clarificationColumn = this._staticColumn.clarificationFields[0];\r\n } else{\r\n this.clarificationColumn = null;\r\n }\r\n\r\n this._clarificationFieldValue = null;\r\n }\r\n\r\n cancel() {\r\n this._modalRef.hide();\r\n }\r\n\r\n save() {\r\n const staticColumn = this.staticColumn as Compliance.StaticImportFieldModel;\r\n if (!staticColumn) {\r\n return;\r\n }\r\n\r\n staticColumn.value = this.staticValue;\r\n this.result = {\r\n staticColumn: staticColumn,\r\n clarificationFieldValues: null\r\n } as EntityImportStaticMappingInfo;\r\n\r\n if (this._clarificationFieldValue){\r\n this.result.clarificationFieldValues = [];\r\n this.result.clarificationFieldValues.push({\r\n name: this.clarificationColumn.importFieldId,\r\n value: this._clarificationFieldValue} as Compliance.NameValuePair);\r\n }\r\n\r\n this._modalRef.hide();\r\n }\r\n\r\n get isSaveDisabled(): boolean {\r\n return !(this.staticColumn && this.staticValue && (!this.clarificationColumn || this._clarificationFieldValue));\r\n }\r\n\r\n get availableImportFields(): Compliance.ImportFieldModel[] {\r\n return this._availableImportFields;\r\n }\r\n}\r\n","import {HelpContent} from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const COLUMN_MAPPING_STEP_HELP:HelpContent[] = [\r\n {\r\n helpContentId: 'column-mapping-step.save-import-specification',\r\n tooltipText: 'Save these mappings so that it is easier the next time you import this type of file.'\r\n },\r\n {\r\n helpContentId: 'column-mapping-step.add-static-column',\r\n tooltipText: 'Static columns are values that are applied to all the rows of the import. You can set them up here.'\r\n },\r\n];\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../../WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\nexport interface ImportMappingModalParams {\r\n header: string;\r\n message: string;\r\n options: Compliance.NameValuePair[];\r\n}\r\n\r\n@Component({\r\n selector: 'import-mapping-modal',\r\n templateUrl: './importMappingModal.component.html'\r\n})\r\nexport class ImportMappingModalComponent implements OnInit, OnDestroy, IWeissmanModalComponent[]> {\r\n constructor(private readonly _bsModalRef: BsModalRef) {}\r\n\r\n params: Compliance.ImportFieldModel;\r\n result: Compliance.NameValuePair[];\r\n\r\n clarificationField: Compliance.ImportFieldModel;\r\n options: string[];\r\n selectedOption: UntypedFormControl = new UntypedFormControl();\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this.clarificationField = this.params.clarificationFields[0];\r\n this.options = this.clarificationField.possibleOptions;\r\n this.selectedOption.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(x => {\r\n this.result = [];\r\n this.result.push({name: this.clarificationField.importFieldId, value: x} as Compliance.NameValuePair);\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n onAccept(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n onCancel(): void {\r\n this.result = null;\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\n
\r\n {{params.clarificationFields[0].displayName}}\r\n \r\n \r\n
\r\n
\r\n","import { Injectable, EventEmitter } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\n\r\nexport interface IAgGridOverlayService {\r\n notifyColumnAdd: (params: AgGridOverlayColumn) => void;\r\n notifyColumnRemove: (params: number) => void;\r\n notifyColumnResize: (params: AgGridOverlayColumnsResizedEvent) => void;\r\n notifyGridHorizontalScroll: (params: number) => void;\r\n columnAdd$: Observable;\r\n columnRemove$: Observable;\r\n columnResize$: Observable;\r\n gridHorizontalScroll$: Observable;\r\n}\r\n\r\nexport interface AgGridOverlayColumnsResizedEvent {\r\n columns: AgGridOverlayColumn[]\r\n}\r\n\r\nexport interface AgGridOverlayColumn {\r\n columnId: number;\r\n left: number;\r\n width: number;\r\n}\r\n\r\n@Injectable()\r\nexport class AgGridOverlayService implements IAgGridOverlayService {\r\n\r\n private _columnAddEmitter = new EventEmitter();\r\n\r\n private _columnRemoveEmitter = new EventEmitter();\r\n\r\n private _columnResizeEmitter = new EventEmitter();\r\n\r\n private _gridHorizontalScrollEmitter = new EventEmitter();\r\n\r\n notifyColumnAdd(params: AgGridOverlayColumn): void {\r\n this._columnAddEmitter.emit(params);\r\n }\r\n\r\n notifyColumnRemove(params: number): void {\r\n this._columnRemoveEmitter.emit(params);\r\n }\r\n\r\n notifyColumnResize(params: AgGridOverlayColumnsResizedEvent): void {\r\n this._columnResizeEmitter.emit(params);\r\n }\r\n\r\n notifyGridHorizontalScroll(params: number): void {\r\n this._gridHorizontalScrollEmitter.emit(params);\r\n }\r\n\r\n get columnAdd$(): Observable {\r\n return this._columnAddEmitter.asObservable();\r\n }\r\n\r\n get columnRemove$(): Observable {\r\n return this._columnRemoveEmitter.asObservable();\r\n }\r\n\r\n get columnResize$(): Observable {\r\n return this._columnResizeEmitter.asObservable();\r\n }\r\n\r\n get gridHorizontalScroll$(): Observable {\r\n return this._gridHorizontalScrollEmitter.asObservable();\r\n }\r\n}\r\n","export interface IAgGridOverlayContainer {\r\n columnId: number;\r\n bottom: number;\r\n left: number;\r\n width: number;\r\n horizontalScrollOffset: number;\r\n hasMouseOver: boolean;\r\n}\r\n\r\n/**\r\n * A class for managing the overlay container that is positioned on top of the AgGrid.\r\n */\r\nexport class AgGridOverlayContainer implements IAgGridOverlayContainer {\r\n constructor(private _columnId: number) { }\r\n\r\n private readonly _overlayContainerPadding: number = 0;\r\n\r\n private _left: number = 0;\r\n private _width: number = 0;\r\n\r\n /**\r\n * The AgGrid column ID that this container is associated with.\r\n */\r\n get columnId(): number {\r\n return this._columnId;\r\n }\r\n\r\n /**\r\n * The container bottom offset.\r\n * Used to adjust the container bottom in case the AgGrid has a horizontal scrollbar.\r\n */\r\n get bottom(): number {\r\n return 0;\r\n }\r\n\r\n /**\r\n * The container left offset.\r\n */\r\n get left(): number {\r\n return this._left + this._overlayContainerPadding - this.horizontalScrollOffset;\r\n }\r\n\r\n set left(value) {\r\n this._left = value;\r\n }\r\n\r\n /**\r\n * The container width.\r\n */\r\n get width(): number {\r\n return this._width - (this._overlayContainerPadding * 2);\r\n }\r\n\r\n set width(value) {\r\n this._width = value;\r\n }\r\n\r\n /**\r\n * The horizontal scroll offset of the AgGrid.\r\n * Used to correctly set the left offset of the container.\r\n */\r\n horizontalScrollOffset: number = 0;\r\n\r\n /**\r\n * Indicates if the drag-and-drop cursor is over the container.\r\n */\r\n hasMouseOver: boolean = false;\r\n}\r\n","
\r\n \r\n
\r\n \r\n
Drop Here
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy, Input, Output, EventEmitter } from '@angular/core';\r\nimport { DragulaService } from 'ng2-dragula';\r\nimport { AgGridOverlayService } from './agGridOverlay.service';\r\nimport { AgGridOverlayContainer } from './agGridOverlayContainer';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\n\r\nexport interface AgGridOverlayDropEvent {\r\n sourceId: string;\r\n targetId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'ag-grid-overlay',\r\n templateUrl: './agGridOverlay.component.html'\r\n})\r\nexport class AgGridOverlayComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private _dragulaService: DragulaService,\r\n private _agGridOverlayService: AgGridOverlayService\r\n ) { }\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n // keep track of the grid horizontal scroll offset changes in order to correctly position new overlay containers when they're added\r\n private _horizontalScrollOffset: number = 0;\r\n\r\n private _getDragulaTargetId(name: string, el: Element) {\r\n if (name !== this.bagName) return null;\r\n\r\n // only care about drops related to the overlay containers that this component manages\r\n const dropEl = el;\r\n if (!dropEl || dropEl.getAttribute('overlay-bag-name') !== this.bagName) return null;\r\n const columnId = parseInt(dropEl.getAttribute('column-id'));\r\n\r\n return columnId;\r\n }\r\n\r\n private _getDragulaSourceId(name: string, el: Element) {\r\n if (name !== this.bagName) return null;\r\n\r\n // get the source element and retrieve a unique identifier for it\r\n const sourceEl = el;\r\n const sourceId = sourceEl.getAttribute(this.sourceElIdAttribute);\r\n\r\n return sourceId;\r\n }\r\n\r\n /**\r\n * Controls the visibility of the overlay.\r\n */\r\n @Input() isVisible: boolean;\r\n\r\n /**\r\n * The bag name to use for the drag-and-drop containers.\r\n */\r\n @Input() bagName: string;\r\n\r\n /**\r\n * An attribute on the element being dropped that identifies it.\r\n */\r\n @Input('sourceElementIdAttribute') sourceElIdAttribute: string;\r\n\r\n /**\r\n * Event queue for when a source element is successfully dropped in an overlay container\r\n */\r\n @Output() drop: EventEmitter = new EventEmitter();\r\n\r\n /**\r\n * A collection of overlays to superimpose on top of the Ag Grid.\r\n */\r\n overlayContainers: AgGridOverlayContainer[] = [];\r\n\r\n // dummy property required by dragula\r\n selectedOverlayItems: any[] = [];\r\n\r\n ngOnInit(): void {\r\n this._dragulaService.drop(this.bagName).pipe(takeUntil(this.destroy$)).subscribe(value => {\r\n const columnId = this._getDragulaTargetId(value.name, value.target);\r\n const sourceId = this._getDragulaSourceId(value.name, value.el);\r\n if (sourceId && columnId) {\r\n this.drop.emit({\r\n sourceId: sourceId,\r\n targetId: columnId\r\n });\r\n }\r\n });\r\n\r\n this._dragulaService.over(this.bagName).pipe(takeUntil(this.destroy$)).subscribe(value => {\r\n const columnId = this._getDragulaTargetId(value.name, value.container);\r\n const container = this.overlayContainers.find(i => i.columnId === columnId);\r\n if (container) {\r\n container.hasMouseOver = true;\r\n }\r\n });\r\n\r\n this._dragulaService.out(this.bagName).pipe(takeUntil(this.destroy$)).subscribe(value => {\r\n const columnId = this._getDragulaTargetId(value.name, value.container);\r\n const container = this.overlayContainers.find(i => i.columnId === columnId);\r\n if (container) {\r\n container.hasMouseOver = false;\r\n }\r\n });\r\n\r\n this._agGridOverlayService.columnAdd$.pipe(takeUntil(this.destroy$)).subscribe(value => {\r\n let container = this.overlayContainers.find(i => i.columnId === value.columnId);\r\n if (container) {\r\n return;\r\n }\r\n container = new AgGridOverlayContainer(value.columnId);\r\n container.left = value.left;\r\n container.width = value.width;\r\n container.horizontalScrollOffset = this._horizontalScrollOffset;\r\n this.overlayContainers.push(container);\r\n });\r\n\r\n this._agGridOverlayService.columnRemove$.pipe(takeUntil(this.destroy$)).subscribe(value => {\r\n const container = this.overlayContainers.find(i => i.columnId === value);\r\n if (!container) {\r\n return;\r\n }\r\n this.overlayContainers.splice(this.overlayContainers.indexOf(container), 1);\r\n });\r\n\r\n this._agGridOverlayService.columnResize$.pipe(takeUntil(this.destroy$)).subscribe(value => {\r\n value.columns.forEach(i => {\r\n const container = this.overlayContainers.find(c => c.columnId === i.columnId);\r\n if (container) {\r\n container.left = i.left;\r\n container.width = i.width;\r\n }\r\n });\r\n });\r\n\r\n this._agGridOverlayService.gridHorizontalScroll$.pipe(takeUntil(this.destroy$)).subscribe(value => {\r\n this._horizontalScrollOffset = value;\r\n this.overlayContainers.forEach(i => i.horizontalScrollOffset = value);\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n}\r\n","
Indicate how null records should affect imported values.
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
{{option.name}}:{{option.description}}
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { HelpContentComponent, HelpService } from '../../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport interface DynamicFieldBehaviorHelpComponentParams {\r\n options: Compliance.ImportDynamicFieldOptionModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'dynamic-field-behavior-help',\r\n templateUrl: './dynamicFieldBehaviorHelp.component.html',\r\n})\r\nexport class DynamicFieldBehaviorHelpComponent implements HelpContentComponent {\r\n constructor(private readonly _helpService: HelpService) { }\r\n\r\n params: DynamicFieldBehaviorHelpComponentParams;\r\n options: Compliance.ImportDynamicFieldOptionModel[];\r\n\r\n helpInit(params: DynamicFieldBehaviorHelpComponentParams): void {\r\n if (params) {\r\n this.options = params.options;\r\n }\r\n\r\n this._helpService.refresh();\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Set All:\r\n \r\n
{{field.name}}:\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../../WeissmanModalService';\r\nimport { BusyIndicatorMessageManager } from '../../../../../Busy-Indicator';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { EntityImportColumnMappingStepService } from '../../Column-Mapping-Step/columnMappingStep.service';\r\nimport { EntityImportProcessService } from '../../importProcess.service';\r\nimport { DynamicFieldBehaviorService } from '../dynamicFieldBehavior.service';\r\n\r\nexport interface DynamicFieldBehaviorConfigurationFieldInfo {\r\n importFieldId: number;\r\n name: string;\r\n}\r\n\r\nexport interface DynamicFieldBehaviorConfigurationParams {\r\n importId: number;\r\n options: Compliance.ImportDynamicFieldOptionModel[];\r\n dynamicFields: DynamicFieldBehaviorConfigurationFieldInfo[],\r\n selectedOptions: System.Collections.Generic.KeyValuePair[];\r\n}\r\n\r\n@Component({\r\n selector: 'dynamic-field-behavior-configuration',\r\n templateUrl: './dynamicFieldBehaviorConfiguration.component.html',\r\n styles: [`\r\n ws-select {\r\n display: block;\r\n width: 100px;\r\n }`]\r\n})\r\nexport class DynamicFieldBehaviorConfigurationComponent implements OnInit, IWeissmanModalComponent{\r\n params: DynamicFieldBehaviorConfigurationParams;\r\n result: void;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n availableOptions: Compliance.ImportDynamicFieldOptionModel[];\r\n fields: DynamicFieldBehaviorConfigurationFieldInfo[];\r\n selectedOptions: System.Collections.Generic.KeyValuePair[] = [];\r\n\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _dynamicFieldBehaviorService: DynamicFieldBehaviorService\r\n ) {}\r\n\r\n ngOnInit(): void {\r\n this.availableOptions = this.params.options.filter(x => !x.isFileOnlyOption);\r\n this.fields = this.params.dynamicFields;\r\n this.fields.sort((x, y) => x.name.localeCompare(y.name));\r\n this.selectedOptions = [... this.params.selectedOptions] || [];\r\n\r\n if (this.selectedOptions.length === 0) {\r\n this.selectedOptions.push({key: 0, value: Compliance.ImportDynamicFieldOptionEnum.Ignore});\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n getValue(importFieldId: number) {\r\n const selectedValue = this.selectedOptions.find(x => x.key === importFieldId);\r\n const setAllValue = this.selectedOptions.find(x => x.key === 0);\r\n\r\n return selectedValue\r\n ? selectedValue.value || Compliance.ImportDynamicFieldOptionEnum.Ignore\r\n : setAllValue\r\n ? setAllValue.value\r\n : Compliance.ImportDynamicFieldOptionEnum.Ignore;\r\n }\r\n\r\n setValue(importFieldId: number, option: Compliance.ImportDynamicFieldOptionEnum) {\r\n if (importFieldId === 0) {\r\n this.selectedOptions = [];\r\n }\r\n\r\n let selectedValue = this.selectedOptions.find(x => x.key === importFieldId);\r\n\r\n if (!selectedValue) {\r\n selectedValue = {key: importFieldId, value: option};\r\n this.selectedOptions.push(selectedValue);\r\n } else {\r\n selectedValue.value = option;\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsg = 'saving';\r\n\r\n this.busyIndicatorMessageManager.add('Saving', busyMsg);\r\n\r\n try {\r\n const updateModel: Compliance.ImportFieldPropertyCharacteristicBehaviorUpdateModel = {\r\n importId: this.params.importId,\r\n fieldOptions: this.selectedOptions\r\n };\r\n\r\n await this._dynamicFieldBehaviorService.updateImportFieldPropertyCharacteristicBehavior(updateModel);\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n }\r\n}\r\n","
\r\n \r\n \r\n \r\n \r\n \r\n
{{field.name}}:{{field.selectedOption}}
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { HelpContentComponent } from '../../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport interface DynamicFieldBehaviorHelpFieldInfo {\r\n name: string;\r\n selectedOption: string;\r\n}\r\n\r\nexport interface DynamicFieldSelectedBehaviorHelpComponentParams{\r\n fields: DynamicFieldBehaviorHelpFieldInfo[];\r\n}\r\n\r\n@Component({\r\n selector: 'dynamic-field-selected-behavior-help',\r\n templateUrl: './dynamicFieldSelectedBehaviorHelp.component.html'\r\n})\r\nexport class DynamicFieldSelectedBehaviorHelpComponent implements OnInit, HelpContentComponent {\r\n params: DynamicFieldSelectedBehaviorHelpComponentParams;\r\n fields: DynamicFieldBehaviorHelpFieldInfo[];\r\n\r\n helpInit(params: DynamicFieldSelectedBehaviorHelpComponentParams): void {\r\n }\r\n\r\n ngOnInit() {\r\n this.fields = this.params.fields;\r\n this.fields.sort((a, b) => a.name.localeCompare(b.name));\r\n }\r\n}\r\n","
\r\n \r\n Property Characteristics Behavior:\r\n
\r\n
\r\n {{selectedPropertyCharacteristicOptionName}}\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { HelpContentComponentConfig } from '../../../../UI-Lib/Help-Tooltip';\r\nimport {\r\n DynamicFieldBehaviorHelpComponent,\r\n DynamicFieldBehaviorHelpComponentParams\r\n} from './Dynamic-Field-Behavior-Help/dynamicFieldBehaviorHelp.component';\r\nimport {\r\n DynamicFieldBehaviorConfigurationComponent,\r\n DynamicFieldBehaviorConfigurationParams,\r\n DynamicFieldBehaviorConfigurationFieldInfo\r\n} from './Dynamic-Field-Behavior-Configuration/dynamicFieldBehaviorConfiguration.component';\r\nimport { WeissmanModalService } from '../../../WeissmanModalService';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport {\r\n DynamicFieldBehaviorHelpFieldInfo,\r\n DynamicFieldSelectedBehaviorHelpComponent, DynamicFieldSelectedBehaviorHelpComponentParams\r\n} from './Dynamic-Field-Selected-Behavior-Help/dynamicFieldSelectedBehaviorHelp.component';\r\nimport { DynamicFieldBehaviorService } from './dynamicFieldBehavior.service';\r\n\r\n@Component({\r\n selector: 'dynamic-field-behavior',\r\n templateUrl: './dynamicFieldBehavior.component.html',\r\n})\r\nexport class DynamicFieldBehaviorComponent implements OnInit {\r\n constructor(\r\n private readonly _dynamicFieldBehaviorService: DynamicFieldBehaviorService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService) {\r\n }\r\n\r\n @Input() importFileId: number;\r\n @Input() isReadOnly: boolean;\r\n selectedPropertyCharacteristicOptionName: string;\r\n\r\n availableDynamicFieldBehaviorOptions: Compliance.ImportDynamicFieldOptionModel[] = [];\r\n\r\n dynamicFieldBehaviorTooltip: HelpContentComponentConfig;\r\n dynamicFieldSelectedBehaviorTooltip: HelpContentComponentConfig;\r\n showFieldOptionsTooltip: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this.availableDynamicFieldBehaviorOptions = this._dynamicFieldBehaviorService.getFileDynamicFieldBehaviorOptions();\r\n\r\n if (!this.isReadOnly) {\r\n this.dynamicFieldBehaviorTooltip = {\r\n component: DynamicFieldBehaviorHelpComponent,\r\n componentParams: {\r\n options: this.availableDynamicFieldBehaviorOptions,\r\n }\r\n };\r\n }\r\n\r\n if (this.selectedImportDynamicFieldBehavior.optionId === Compliance.ImportDynamicFieldOptionEnum.Specify) {\r\n this.selectedPropertyCharacteristicOptionName = 'Per Characteristic';\r\n this.showFieldOptionsTooltip = true;\r\n\r\n const fieldsSettings = this._dynamicFieldBehaviorService.getSelectedDynamicFieldBehaviorOptions();\r\n const setAllOption = fieldsSettings.find(x => x.key == 0);\r\n const dynamicFields = this._getDynamicFields();\r\n\r\n this.dynamicFieldSelectedBehaviorTooltip = {\r\n component: DynamicFieldSelectedBehaviorHelpComponent,\r\n componentParams: {\r\n fields: dynamicFields.map(x => {\r\n const fieldSelectedOption = fieldsSettings.find(y => y.key === x.importFieldId);\r\n\r\n let selectedOption = Compliance.ImportDynamicFieldOptionEnum.Ignore;\r\n\r\n if (fieldSelectedOption) {\r\n selectedOption = fieldSelectedOption.value;\r\n } else if (setAllOption) {\r\n selectedOption = setAllOption.value;\r\n }\r\n\r\n return {\r\n name: x.name,\r\n selectedOption: this.availableDynamicFieldBehaviorOptions.find(y => y.optionId === selectedOption).name,\r\n } as DynamicFieldBehaviorHelpFieldInfo;\r\n })\r\n }\r\n }\r\n } else {\r\n this.selectedPropertyCharacteristicOptionName = this.selectedImportDynamicFieldBehavior.name;\r\n }\r\n }\r\n\r\n get selectedImportDynamicFieldBehavior(): Compliance.ImportDynamicFieldOptionModel{\r\n return this._dynamicFieldBehaviorService.getSelectedDynamicFieldBehaviorOption();\r\n }\r\n\r\n get canEditDynamicFieldConfiguration(): boolean {\r\n return this.selectedImportDynamicFieldBehavior && this.selectedImportDynamicFieldBehavior.optionId === Compliance.ImportDynamicFieldOptionEnum.Specify;\r\n }\r\n\r\n async editDynamicFieldBehavior(): Promise {\r\n const params: DynamicFieldBehaviorConfigurationParams = {\r\n importId: this.importFileId,\r\n options: this.availableDynamicFieldBehaviorOptions,\r\n selectedOptions: this._dynamicFieldBehaviorService.getSelectedDynamicFieldBehaviorOptions(),\r\n dynamicFields: this._getDynamicFields()\r\n };\r\n\r\n await this._modalService.showAsync(DynamicFieldBehaviorConfigurationComponent, params, 'modal-dd');\r\n }\r\n\r\n async setDynamicFieldBehavior(optionId: Compliance.ImportDynamicFieldOptionEnum): Promise {\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving Property Characteristic Behavior Selection'});\r\n\r\n try {\r\n await this._dynamicFieldBehaviorService.setSelectedDynamicFieldBehaviorOption(\r\n this.importFileId,\r\n optionId);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n private _getDynamicFields() {\r\n const mappedFields = this._dynamicFieldBehaviorService.getFieldMappings();\r\n const allFields = this._dynamicFieldBehaviorService.getFields();\r\n\r\n return mappedFields\r\n .filter(x => x.importFieldId.includes('-'))\r\n .map(x => {\r\n const field = allFields.find(y => y.importFieldId == x.importFieldId);\r\n return {\r\n importFieldId: x.importFileSpecificationFieldId,\r\n name: field.displayName\r\n } as DynamicFieldBehaviorConfigurationFieldInfo;\r\n });\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Import Data\r\n \r\n

\r\n
\r\n \r\n
\r\n
View:
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
To map a field to a column, drag and drop it to the table below.
\r\n
\r\n\r\n\r\n
\r\n
\r\n
Required Fields:
\r\n
\r\n
{{ field.displayName }}
\r\n None\r\n
\r\n
\r\n
\r\n
Optional Fields:
\r\n
\r\n
{{ field.displayName }}
\r\n None\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n \r\n\r\n \r\n \r\n
\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { DragulaService } from 'ng2-dragula';\r\nimport {\r\n BodyScrollEvent,\r\n ColDef,\r\n Column,\r\n ColumnApi,\r\n ColumnResizedEvent,\r\n GridApi,\r\n GridOptions,\r\n GridReadyEvent,\r\n IDatasource\r\n} from 'ag-grid-community';\r\nimport { AgGridOverlayColumn, AgGridOverlayService } from './Drag-And-Drop-Overlay/agGridOverlay.service';\r\nimport { Subscription } from 'rxjs';\r\nimport { AgGridPinnedRowCellRenderer } from './agGridPinnedRowCellRenderer';\r\nimport { EntityImportEditorAgGridDataSource } from './agGridDataSource';\r\nimport * as _ from 'lodash';\r\nimport { EntityImportRepository } from '../../../Repositories';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport { AgGridOverlayDropEvent } from './Drag-And-Drop-Overlay/agGridOverlay.component';\r\nimport { AgGridMappingHeaderRowCellRendererComponent } from './agGridHeaderRowCellRenderer.component';\r\nimport { EntityImportColumnMappingStepService } from './columnMappingStep.service';\r\nimport {\r\n EntityImportStaticFieldsComponent,\r\n EntityImportStaticFieldsParams,\r\n EntityImportStaticMappingInfo\r\n} from '../../Static-Fields/staticFields.component';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AgGridColumns, AgGridOptionsBuilder } from '../../../AgGrid';\r\nimport { WeissmanModalService } from '../../../WeissmanModalService';\r\nimport {\r\n EntityImportSpecificationMappingComponent,\r\n ImportSpecificationMappingParams\r\n} from './Import-Specification-Mapping/importSpecificationMapping.component';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { COLUMN_MAPPING_STEP_HELP } from './columnMappingStep.component.help';\r\nimport { ImportMappingModalComponent } from './Import-Mapping-Modal/importMappingModal.component';\r\nimport { DynamicFieldBehaviorService } from '../Dynamic-Field-Behavior/dynamicFieldBehavior.service';\r\n\r\n@Component({\r\n selector: 'entity-import-column-mapping-step',\r\n templateUrl: './columnMappingStep.component.html',\r\n styleUrls: ['./columnMappingStep.component.scss']\r\n})\r\nexport class EntityImportColumnMappingStepComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _dragulaService: DragulaService,\r\n private readonly _agGridOverlayService: AgGridOverlayService,\r\n private readonly _entityImportRepository: EntityImportRepository,\r\n private readonly _columnMappingStepService: EntityImportColumnMappingStepService,\r\n private readonly _toastsManager: ToastrService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService,\r\n private readonly _dynamicFieldBehaviorService: DynamicFieldBehaviorService\r\n ) { }\r\n\r\n private _gridApi: GridApi;\r\n private _gridColumnApi: ColumnApi;\r\n private _gridDataSource: IDatasource;\r\n private _modelHiddenSub: Subscription;\r\n private _dragSub: Subscription;\r\n private _dragEndSub: Subscription;\r\n private _fieldAssignedSub: Subscription;\r\n private _fieldUnassignedSub: Subscription;\r\n\r\n private async _loadImportFileInformation(): Promise {\r\n this.canGridInitialize = false;\r\n\r\n // load necessary information to figure out the state of the field/column mapping\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading Data Import' });\r\n\r\n try {\r\n await this._columnMappingStepService.initialize(this.importId);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n // now that we have loaded the necessary information determine which fields have been mapped and which ones have not\r\n for (let i = 0, l = this._columnMappingStepService.getFields().length; i < l; i++) {\r\n const field = this._columnMappingStepService.getFields()[i];\r\n\r\n // if this field is mapped, skip it\r\n const fieldMappingIndex = this._columnMappingStepService.getFieldMappings().findIndex((mappedField) => mappedField.importFieldId === field.importFieldId);\r\n if (fieldMappingIndex !== -1) continue;\r\n\r\n // if the field is not mapped, figure out if it is a required field or not and put it in the right collection\r\n if (field.isMappingRequired) {\r\n this.availableImportFieldsRequired.push(field);\r\n } else {\r\n this.availableImportFieldsOptional.push(field);\r\n }\r\n }\r\n\r\n this.showDynamicFieldConfiguration = this._dynamicFieldBehaviorService.showDynamicFieldConfiguration;\r\n this.canGridInitialize = true;\r\n }\r\n\r\n private _getGridColumnsAssociatedWithImportFileColumns(): Column[] {\r\n return this._gridColumnApi\r\n .getAllColumns()\r\n .filter((i) => {\r\n const metadata: Compliance.EntityImportMappingColDefMetadata = i.getColDef()['ws'];\r\n return metadata && !metadata.isStatic;\r\n });\r\n }\r\n\r\n private _getGridColumnsAssociatedWithMappedImportFileColumns(): Column[] {\r\n return this._getGridColumnsAssociatedWithImportFileColumns()\r\n .filter((i) => {\r\n // check if the column is currently mapped\r\n const headerId = (i.getColDef()['ws'] as Compliance.EntityImportMappingColDefMetadata).fileHeaderId;\r\n return this._columnMappingStepService.getFieldMappings().findIndex(i => !i.isStatic && i.value === headerId.toString()) !== -1;\r\n });\r\n }\r\n\r\n private _getGridColumnsAssociatedWithUnmappedImportFileColumns(): Column[] {\r\n return this._getGridColumnsAssociatedWithImportFileColumns()\r\n .filter((i) => {\r\n // check if the column is currently unmapped\r\n const headerId: number = (i.getColDef()['ws'] as Compliance.EntityImportMappingColDefMetadata).fileHeaderId;\r\n return this._columnMappingStepService.getFieldMappings().findIndex(i => !i.isStatic && i.value === headerId.toString()) === -1;\r\n });\r\n }\r\n\r\n private _getGridColumnsAssociatedWithStaticImportFileColumns(): Column[] {\r\n return this._gridColumnApi\r\n .getAllColumns()\r\n .filter((i) => {\r\n const metadata: Compliance.EntityImportMappingColDefMetadata = i.getColDef()['ws'];\r\n return metadata && metadata.isStatic;\r\n });\r\n }\r\n\r\n private _getDragAndDropOverlaysFromGridColumns(): AgGridOverlayColumn[] {\r\n return this._getGridColumnsAssociatedWithUnmappedImportFileColumns()\r\n .map((i) => {\r\n return {\r\n columnId: (i.getColDef()['ws'] as Compliance.EntityImportMappingColDefMetadata).fileHeaderId,\r\n left: i.getLeft(),\r\n width: i.getActualWidth()\r\n };\r\n });\r\n }\r\n\r\n private _applyGridColumnFilter(): void {\r\n const mappedColumns = this._getGridColumnsAssociatedWithMappedImportFileColumns();\r\n const unmappedColumns = this._getGridColumnsAssociatedWithUnmappedImportFileColumns();\r\n const staticColumns = this._getGridColumnsAssociatedWithStaticImportFileColumns();\r\n\r\n const allColumns = ([] as Column[]).concat(mappedColumns).concat(unmappedColumns).concat(staticColumns);\r\n\r\n switch (this.selectedGridColumnFilter) {\r\n case this.gridColumnFilters.allColumns:\r\n allColumns.forEach(i => {\r\n this._showGridColumn(i);\r\n if (mappedColumns.indexOf(i) !== -1) {\r\n this._removeGridOverlay(i);\r\n }\r\n });\r\n break;\r\n\r\n case this.gridColumnFilters.mappedColumns:\r\n allColumns.forEach(i => {\r\n if (mappedColumns.indexOf(i) === -1) {\r\n this._hideGridColumn(i);\r\n } else this._showGridColumn(i);\r\n });\r\n break;\r\n\r\n case this.gridColumnFilters.unmappedColumns:\r\n allColumns.forEach(i => {\r\n if (unmappedColumns.indexOf(i) === -1) {\r\n this._hideGridColumn(i);\r\n } else this._showGridColumn(i);\r\n });\r\n break;\r\n\r\n case this.gridColumnFilters.staticColumns:\r\n allColumns.forEach(i => {\r\n if (staticColumns.indexOf(i) === -1) {\r\n this._hideGridColumn(i);\r\n } else this._showGridColumn(i);\r\n });\r\n break;\r\n\r\n default:\r\n console.warn('Cannot filter grid columns. An unknown filter is specified.');\r\n break;\r\n }\r\n\r\n // notify overlay of new column sizes\r\n setTimeout(() => {\r\n this._agGridOverlayService.notifyColumnResize({ columns: this._getDragAndDropOverlaysFromGridColumns() });\r\n }, 500);\r\n }\r\n\r\n private _showGridColumn(col: Column): void {\r\n const colDef = col.getColDef();\r\n const colDefMetadata: Compliance.EntityImportMappingColDefMetadata = colDef['ws'];\r\n this._gridColumnApi.setColumnVisible(col, true);\r\n if (colDefMetadata.fileHeaderId) {\r\n if (this._columnMappingStepService.canAssignField(colDefMetadata.fileHeaderId)) {\r\n this._agGridOverlayService.notifyColumnAdd({\r\n columnId: colDefMetadata.fileHeaderId,\r\n left: col.getLeft(),\r\n width: col.getActualWidth()\r\n });\r\n }\r\n }\r\n }\r\n\r\n private _hideGridColumn(col: Column): void {\r\n const colDef = col.getColDef();\r\n const colDefMetadata: Compliance.EntityImportMappingColDefMetadata = colDef['ws'];\r\n this._gridColumnApi.setColumnVisible(col, false);\r\n this._agGridOverlayService.notifyColumnRemove(colDefMetadata.fileHeaderId);\r\n }\r\n\r\n private _removeGridOverlay(col: Column): void {\r\n const colDef = col.getColDef();\r\n const colDefMetadata: Compliance.EntityImportMappingColDefMetadata = colDef['ws'];\r\n this._agGridOverlayService.notifyColumnRemove(colDefMetadata.fileHeaderId);\r\n }\r\n\r\n private async _showStaticFieldsModal(availableImportFields: Compliance.ImportFieldModel[]): Promise {\r\n const params: EntityImportStaticFieldsParams = {\r\n availableImportFields: availableImportFields\r\n };\r\n\r\n return await this._modalService.showAsync(EntityImportStaticFieldsComponent, params, 'modal-md');\r\n }\r\n\r\n private _addStaticColumnToGrid(fieldMapping: Compliance.ImportFileSpecificationImportFieldModel): void {\r\n const field = this._columnMappingStepService.getFields().find(i => i.importFieldId === fieldMapping.importFieldId);\r\n const colDef = this._prepareStaticColumnDefinition(field, fieldMapping);\r\n const colDefList = this._gridColumnApi.getAllColumns().map(x => x.getColDef());\r\n this._gridApi.setColumnDefs(colDefList.concat(colDef));\r\n }\r\n\r\n private _removeStaticColumnFromGrid(col: Column): void {\r\n const colDef = col.getColDef();\r\n const colDefList = this._gridColumnApi\r\n .getAllColumns()\r\n .filter(i => i.getColDef() !== colDef) // remove grid column\r\n .map(i => i.getColDef());\r\n this._gridApi.setColumnDefs(colDefList);\r\n }\r\n\r\n private _prepareStaticColumnDefinition(field: Compliance.ImportFieldModel, fieldMapping: Compliance.ImportFileSpecificationImportFieldModel): ColDef {\r\n return {\r\n headerName: field.displayName,\r\n editable: false,\r\n suppressMovable: true,\r\n pinnedRowCellRenderer: AgGridPinnedRowCellRenderer,\r\n headerComponentFramework: AgGridMappingHeaderRowCellRendererComponent,\r\n valueGetter: () => fieldMapping.value,\r\n cellClass: 'static-column-cell',\r\n // custom metadata\r\n ws: {\r\n enableMappingMaintenance: true,\r\n isStatic: true,\r\n staticFieldId: fieldMapping.importFieldId,\r\n staticFieldMappingId: fieldMapping.importFileSpecificationFieldId\r\n } as Compliance.EntityImportMappingColDefMetadata\r\n } as ColDef;\r\n }\r\n\r\n private async _dropMappingCharacteristicModal(mappedField: Compliance.ImportFieldModel): Promise[]> {\r\n const result = await this._modalService.showAsync(ImportMappingModalComponent, mappedField, 'modal-md');\r\n\r\n if (!result) {\r\n const field = this._columnMappingStepService.getFields().find(i => i.importFieldId === mappedField.importFieldId);\r\n if (field.isMappingRequired) {\r\n this.availableImportFieldsRequired.push(field);\r\n } else {\r\n this.availableImportFieldsOptional.push(field);\r\n }\r\n return;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n @Input() importId: number;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n floatingFilter: false,\r\n enableFilter: false,\r\n enableServerSideFilter: false,\r\n })\r\n .withColumnResize()\r\n .withInfiniteScroll()\r\n .withLoadingOverlay()\r\n .withTextSelection()\r\n .build();\r\n\r\n gridColumnFilters = {\r\n allColumns: 'All Columns',\r\n mappedColumns: 'Mapped Columns',\r\n unmappedColumns: 'Columns Not Mapped',\r\n staticColumns: 'Static Columns'\r\n };\r\n\r\n selectedGridColumnFilter = this.gridColumnFilters.allColumns;\r\n\r\n // we cannot correctly initialize the grid until all the necessary import file information has loaded\r\n canGridInitialize: boolean = false;\r\n\r\n // a (dragula) bag name identifier for all the containers involved in the available field drag-and-drop\r\n readonly availableImportFieldsDragAndDropBagName: string = 'available-import-fields-bag';\r\n\r\n // an attribute put on all source containers to identify them\r\n // used to block the user from drag and dropping between source containers\r\n readonly availableImportFieldsDragAndDropSourceContainerIdentifier: string = 'available-import-fields-source-container';\r\n\r\n // a variable to control the visibility of the drag-and-drop containers that overlay the grid\r\n availableImportFieldsOverlayVisible: boolean = false;\r\n availableImportFieldsRequired: Compliance.ImportFieldModel[] = [];\r\n availableImportFieldsOptional: Compliance.ImportFieldModel[] = [];\r\n showDynamicFieldConfiguration: boolean = false;\r\n\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(COLUMN_MAPPING_STEP_HELP);\r\n // make sure available fields cannot be dragged within the same container\r\n const bag = this._dragulaService.find(this.availableImportFieldsDragAndDropBagName);\r\n if (!bag) {\r\n this._dragulaService.createGroup(this.availableImportFieldsDragAndDropBagName, {\r\n revertOnSpill: true,\r\n removeOnSpill: false,\r\n accepts: (el: Element, target: Element) => {\r\n return target && target.getAttribute('container-id') !== this.availableImportFieldsDragAndDropSourceContainerIdentifier;\r\n }\r\n });\r\n }\r\n\r\n this._dragSub = this._dragulaService.drag(this.availableImportFieldsDragAndDropBagName).subscribe(value => {\r\n if (value.name !== this.availableImportFieldsDragAndDropBagName) return;\r\n this.availableImportFieldsOverlayVisible = true;\r\n });\r\n\r\n this._dragEndSub = this._dragulaService.dragend(this.availableImportFieldsDragAndDropBagName).subscribe(value => {\r\n if (value.name !== this.availableImportFieldsDragAndDropBagName) return;\r\n this.availableImportFieldsOverlayVisible = false;\r\n });\r\n\r\n this._fieldAssignedSub = this._columnMappingStepService.fieldAssigned$.subscribe(fieldMapping => {\r\n // remove field from the available fields collection\r\n const field = this._columnMappingStepService.getFields().find(i => i.importFieldId === fieldMapping.importFieldId);\r\n if (field.isMappingRequired) {\r\n const index = this.availableImportFieldsRequired.indexOf(field);\r\n if (index !== -1) {\r\n this.availableImportFieldsRequired.splice(index, 1);\r\n }\r\n } else {\r\n const index = this.availableImportFieldsOptional.indexOf(field);\r\n if (index !== -1) {\r\n this.availableImportFieldsOptional.splice(index, 1);\r\n }\r\n }\r\n\r\n // apply grid column filters to grid columns and sync up grid overlays\r\n this._applyGridColumnFilter();\r\n });\r\n\r\n this._fieldUnassignedSub = this._columnMappingStepService.fieldUnassigned$.subscribe(fieldMapping => {\r\n // if the field mapping was for a static field, remove that field from the grid columns\r\n if (fieldMapping.isStatic) {\r\n const staticColumn = this._getGridColumnsAssociatedWithStaticImportFileColumns().filter(i => {\r\n return (i.getColDef()['ws'] as Compliance.EntityImportMappingColDefMetadata).staticFieldId === fieldMapping.importFieldId;\r\n })[0];\r\n this._removeStaticColumnFromGrid(staticColumn);\r\n }\r\n\r\n // find the field associated with that mapping and add it to the right collection\r\n const field = this._columnMappingStepService.getFields().find(i => i.importFieldId === fieldMapping.importFieldId);\r\n if (field) {\r\n if (field.isMappingRequired) {\r\n this.availableImportFieldsRequired.push(field);\r\n } else {\r\n this.availableImportFieldsOptional.push(field);\r\n }\r\n }\r\n\r\n // apply grid column filters to grid columns and sync up grid overlays\r\n this._applyGridColumnFilter();\r\n });\r\n\r\n await this._loadImportFileInformation();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._dragSub.unsubscribe();\r\n this._dragEndSub.unsubscribe();\r\n this._fieldAssignedSub.unsubscribe();\r\n this._fieldUnassignedSub.unsubscribe();\r\n this._modelHiddenSub && this._modelHiddenSub.unsubscribe();\r\n }\r\n\r\n /**\r\n * Called after the import model has loaded.\r\n * @param event Event parameters.\r\n */\r\n onAgGridReady(event: GridReadyEvent): void {\r\n // get API objects and start setting up the AgGrid\r\n this._gridApi = event.api;\r\n this._gridColumnApi = event.columnApi;\r\n\r\n // setup AgGrid column for row #\r\n const rowIdColumnDef: ColDef = {\r\n headerName: 'Row',\r\n field: 'rowIndex',\r\n width: AgGridColumns.rowNumberColumnWidth,\r\n type: 'numericColumn',\r\n editable: false,\r\n suppressMovable: true,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n pinnedRowCellRenderer: AgGridPinnedRowCellRenderer,\r\n // custom metadata\r\n ws: null\r\n } as ColDef;\r\n\r\n // setup AgGrid column for import file columns\r\n // fields for each row are matched to the right columns via their index in the file; i.e.\r\n // columns: [ { headerName: 'FIRSTNAME', field: 1 }, { headerName: 'LASTNAME', field: 3 }]\r\n // row 1: { 1: 'Adam', 3: 'Smith' }\r\n // row 2: { 1: 'John', 3: 'Doe' }\r\n const columnDefList: ColDef[] = _\r\n .chain(this._columnMappingStepService.getFileHeaders())\r\n .sortBy(['index'])\r\n .map((i) => {\r\n return {\r\n headerName: null,\r\n field: i.index.toString(),\r\n editable: false,\r\n suppressMovable: true,\r\n pinnedRowCellRenderer: AgGridPinnedRowCellRenderer,\r\n headerComponentFramework: AgGridMappingHeaderRowCellRendererComponent,\r\n // custom metadata\r\n ws: {\r\n enableMappingMaintenance: true,\r\n isStatic: false,\r\n fileHeaderId: i.importFileHeaderId\r\n } as Compliance.EntityImportMappingColDefMetadata,\r\n } as ColDef;\r\n })\r\n .value();\r\n\r\n // setup AgGrid column for static columns\r\n const staticColumnDefList: ColDef[] = _\r\n .chain(this._columnMappingStepService.getFieldMappings())\r\n .filter(i => i.isStatic)\r\n .map(i => {\r\n const field = this._columnMappingStepService.getFields().find(f => f.importFieldId === i.importFieldId);\r\n return this._prepareStaticColumnDefinition(field, i);\r\n })\r\n .value();\r\n\r\n // pin file headers as top row\r\n const headersRow: any = {};\r\n this._columnMappingStepService.getFileHeaders().forEach((i) => { headersRow[i.index] = i.name; });\r\n this._gridApi.setPinnedTopRowData([headersRow]);\r\n\r\n // set AgGrid columns\r\n this._gridApi.setColumnDefs(([] as ColDef[]).concat(rowIdColumnDef).concat(columnDefList).concat(staticColumnDefList));\r\n\r\n // setup AgGrid data source for infinite scrolling\r\n this._gridDataSource = new EntityImportEditorAgGridDataSource(this._gridApi, this._entityImportRepository, this.importId);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n\r\n // make the overlay component aware of the grid columns\r\n const columns = this._getDragAndDropOverlaysFromGridColumns();\r\n columns.forEach(i => this._agGridOverlayService.notifyColumnAdd(i));\r\n\r\n //make the overlay component aware of the grid column sizes\r\n this._agGridOverlayService.notifyColumnResize({ columns: this._getDragAndDropOverlaysFromGridColumns() });\r\n }\r\n\r\n /**\r\n * Called when the AgGrid columns are being resized.\r\n * @param event Event parameters.\r\n */\r\n onAgGridColumnResized(event: ColumnResizedEvent): void {\r\n if (event.finished) {\r\n this._agGridOverlayService.notifyColumnResize({ columns: this._getDragAndDropOverlaysFromGridColumns() });\r\n }\r\n }\r\n\r\n /**\r\n * Called when the AgGrid body is being scrolled.\r\n * @param event Event parameters.\r\n */\r\n onAgGridBodyScroll(event: BodyScrollEvent): void {\r\n if (event.direction === 'horizontal') {\r\n this._agGridOverlayService.notifyGridHorizontalScroll(event.left);\r\n }\r\n }\r\n\r\n /**\r\n * Called when the user drops a field on top of one of the AgGrid columns.\r\n * @param params Event parameters.\r\n */\r\n async onAvailableImportFieldMapped(params: AgGridOverlayDropEvent): Promise {\r\n if (!this._columnMappingStepService.canAssignField(params.targetId)) {\r\n return;\r\n }\r\n\r\n const allFields = this._columnMappingStepService.getFields();\r\n const field = allFields.find(f => f.importFieldId === params.sourceId);\r\n let clarificationValues: Compliance.NameValuePair[];\r\n\r\n if (field && field.clarificationFields && field.clarificationFields.length !== 0){\r\n clarificationValues = await this._dropMappingCharacteristicModal(field);\r\n if (!clarificationValues) {\r\n return;\r\n }\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Mapping Field'});\r\n try {\r\n await this._columnMappingStepService.assignFieldToColumn(this.importId, params.sourceId, params.targetId, clarificationValues);\r\n // apply grid column filters to grid columns and sync up grid overlays\r\n this._applyGridColumnFilter();\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n async addStaticColumn(): Promise {\r\n const availableFields = ([] as Compliance.ImportFieldModel[]).concat(this.availableImportFieldsRequired).concat(this.availableImportFieldsOptional);\r\n\r\n let staticFieldMapping: EntityImportStaticMappingInfo;\r\n\r\n try {\r\n staticFieldMapping = await this._showStaticFieldsModal(availableFields);\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (staticFieldMapping) {\r\n const busyRef = this._busyIndicatorService.show({message: 'Adding Static Field'});\r\n\r\n try {\r\n const response = await this._columnMappingStepService.assignStaticField(\r\n this.importId,\r\n staticFieldMapping.staticColumn.importFieldId, staticFieldMapping.staticColumn.value,\r\n staticFieldMapping.clarificationFieldValues);\r\n this._addStaticColumnToGrid(response);\r\n return Promise.resolve();\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n }\r\n\r\n /**\r\n * Sets the selected grid filter and sets the visibility of the grid columns based on that filter.\r\n * @param filter Selected grid filter to apply.\r\n */\r\n filterGridColumns(filter: string): void {\r\n this.selectedGridColumnFilter = filter;\r\n this._applyGridColumnFilter();\r\n }\r\n\r\n async saveImportSpecification(): Promise {\r\n const importSpecInfo = this._columnMappingStepService.getFileSpecificationInfo();\r\n\r\n const params: ImportSpecificationMappingParams = {\r\n importFileId: this.importId,\r\n companyId: importSpecInfo.companyId,\r\n importFileSpecificationId: importSpecInfo.importFileSpecificationId,\r\n importFileSpecificationName: importSpecInfo.displayName,\r\n allowNoSave: false\r\n };\r\n\r\n const result = await this._modalService.showAsync(EntityImportSpecificationMappingComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (result) {\r\n this._toastsManager.success('Specification saved');\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","import {GridApi, IGetRowsParams} from 'ag-grid-community';\r\nimport {EntityImportRepository} from '../../../../Repositories';\r\nimport {AgGridDataSourceBase, AgGridDataSourceResult} from '../../../../AgGrid';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\nexport interface EntityImportEditorDataSourceParams {\r\n importFileModel: Compliance.ImportFileModel;\r\n validationSummaryFilters: Compliance.ImportFileValidationErrorModel[];\r\n showTransferredRows: boolean;\r\n showValidRowsOnly: boolean;\r\n sortingColumns: Compliance.NameValuePair[];\r\n}\r\n\r\nexport class EntityImportEditorAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private _gridApi: GridApi,\r\n private _entityImportRepository: EntityImportRepository,\r\n protected _dataSourceParamsFn: () => EntityImportEditorDataSourceParams,\r\n private _rowsLoaded:(totalRows: number) => void,\r\n private _setTotalValidCount:(totalValidCount: number) => void,\r\n private _totalsUpdateCallback: (totals: Compliance.ImportGridTotalRow, selectedTotals: boolean) => void,\r\n private _notProcessedUpdatesCallback: (updates: Compliance.ImportGridNotValidatedUpdateModel[], totalNotValidatedUpdates: number) => void\r\n ) {\r\n super(_gridApi);\r\n this.refreshDataSourceParams();\r\n }\r\n\r\n private _lastFilterUsedInTotals: string;\r\n lastFetchedTotals: Compliance.ImportGridTotalRow;\r\n\r\n gridParams: IGetRowsParams;\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n this.gridParams = params;\r\n\r\n const fields = this._dataSourceParams.importFileModel.importContentType.importFields\r\n .filter(f => this._dataSourceParams.importFileModel.assignedFields.map(af => af.importFieldId).includes(f.importFieldId));\r\n\r\n const columnFilters = this.columnFilters(params);\r\n const searchModel = this.getSearchModelWithoutPagination(columnFilters, params);\r\n\r\n searchModel.pagination = {skip: params.startRow, take: params.endRow - params.startRow} as Core.PaginationModel;\r\n\r\n const searchParamsString = JSON.stringify(searchModel);\r\n const fetchTotals: boolean = this._dataSourceParams.importFileModel.importContentType.supportsTotals &&\r\n (!this.lastFetchedTotals || this._lastFilterUsedInTotals != searchParamsString);\r\n\r\n this._lastFilterUsedInTotals = searchParamsString;\r\n\r\n searchModel.includeTotals = fetchTotals;\r\n\r\n const result = await lastValueFrom(this._entityImportRepository.getImportRows(this._dataSourceParams.importFileModel.importFileId, searchModel));\r\n\r\n this._notProcessedUpdatesCallback(result.notValidatedUpdates, result.totalNotValidatedUpdates);\r\n\r\n const rows = result.data;\r\n const gridRows = rows.map((i) => {\r\n const flatRowObj = {\r\n validationStatus: {},\r\n originalValues: {},\r\n hasError: false,\r\n rowIndex: i.rowIndex\r\n } as Compliance.ImportGridRowGridModel;\r\n\r\n this._setupFields(fields, flatRowObj, i);\r\n\r\n i.validationErrors.forEach(ve => {\r\n const assignedField = this._dataSourceParams.importFileModel.assignedFields.find(af => af.importFileSpecificationFieldId === ve.importFileSpecificationFieldId);\r\n\r\n if (!ve.isWarning) {\r\n flatRowObj.hasError = true;\r\n }\r\n\r\n if (assignedField) {\r\n const field = fields.find(f => f.importFieldId === assignedField.importFieldId);\r\n flatRowObj.validationStatus[field.displayName] = ve.isWarning\r\n ? (flatRowObj.validationStatus[field.displayName] || 'cell-validation-warning')\r\n : 'cell-validation-error';\r\n }\r\n });\r\n flatRowObj.actualAction = i.actualAction;\r\n flatRowObj.estimatedAction = i.estimatedAction;\r\n flatRowObj.rowIndex = i.rowIndex;\r\n return flatRowObj;\r\n });\r\n\r\n if (rows.length) {\r\n params.context = {}\r\n }\r\n\r\n if (!columnFilters.length) {\r\n this._setTotalValidCount(result.totalValidRows);\r\n }\r\n this._rowsLoaded(result.totalRows);\r\n\r\n if (fetchTotals) {\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals, false);\r\n }\r\n\r\n this._notProcessedUpdatesCallback(result.notValidatedUpdates, result.totalNotValidatedUpdates);\r\n\r\n return {\r\n rows: gridRows,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n private getSearchModelWithoutPagination(columnFilters: Core.FilterModel[], params: IGetRowsParams) {\r\n return {\r\n validationErrors: this._dataSourceParams.validationSummaryFilters,\r\n columnFilters: columnFilters,\r\n showTransferredRows: this._dataSourceParams.showTransferredRows,\r\n showValidRowsOnly: this._dataSourceParams.showValidRowsOnly,\r\n estimatedActionFilter: this.estimatedActionFilter(params),\r\n sortColumns: this.getSortColumns(this._dataSourceParams.sortingColumns),\r\n includeTotals: false,\r\n includeOnlyTotals: false\r\n } as Compliance.ImportGridSearchModel;\r\n }\r\n\r\n async forceRefreshOfTotalValidRows(showTransferredRows: boolean, showValidRowsOnly: boolean) {\r\n const searchModel: Compliance.ImportGridSearchModel = {\r\n pagination: {skip: 0, take: 1} as Core.PaginationModel,\r\n validationErrors: [],\r\n columnFilters: [],\r\n showTransferredRows: showTransferredRows,\r\n showValidRowsOnly: showValidRowsOnly,\r\n estimatedActionFilter: null,\r\n sortColumns: [],\r\n includeTotals: false,\r\n includeOnlyTotals: false\r\n }\r\n const result = await lastValueFrom(this._entityImportRepository.getImportRows(this._dataSourceParams.importFileModel.importFileId, searchModel));\r\n\r\n this._setTotalValidCount(result.totalValidRows);\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const columnFilters = this.columnFilters({filterModel: this._gridApi.getFilterModel()} as IGetRowsParams);\r\n const estimatedActionFilter = this.estimatedActionFilter({filterModel: this._gridApi.getFilterModel()} as IGetRowsParams);\r\n const searchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n } as Core.PaginationModel,\r\n validationErrors: this._dataSourceParams.validationSummaryFilters,\r\n columnFilters: columnFilters,\r\n showTransferredRows: this._dataSourceParams.showTransferredRows,\r\n estimatedActionFilter: estimatedActionFilter,\r\n sortColumns: this.getSortColumns(this._dataSourceParams.sortingColumns),\r\n includeTotals: false,\r\n includeOnlyTotals: false\r\n } as Compliance.ImportGridSearchModel;\r\n\r\n return await lastValueFrom(this._entityImportRepository.getImportSelectedRowIds(this._dataSourceParams.importFileModel.importFileId, searchModel));\r\n }\r\n\r\n columnFilters(params: IGetRowsParams): Core.FilterModel[] {\r\n const filters: Core.FilterModel[] = [];\r\n if (params && params.filterModel) {\r\n for (const prop in params.filterModel) {\r\n // ignore any custom filter that have nothing to do with the import file columns\r\n if (params.filterModel.hasOwnProperty(prop) && ['estimatedAction'].indexOf(prop) === -1) {\r\n\r\n // looking for the ID of the header of the import file that was imported\r\n // if the column has been mapped the name will match the field name otherwise it will be the header name\r\n const contentTypeField = this._dataSourceParams.importFileModel.importContentType.importFields.find(i => i.displayName === prop);\r\n\r\n const assignedField = contentTypeField && this._dataSourceParams.importFileModel.assignedFields.find(i => i.importFieldId === contentTypeField.importFieldId);\r\n\r\n const header = (contentTypeField && assignedField) ?\r\n this._dataSourceParams.importFileModel.importFileHeaders.find(i => i.importFileHeaderId.toString() === assignedField.value) :\r\n this._dataSourceParams.importFileModel.importFileHeaders.find(i => i.index.toString() === prop);\r\n\r\n filters.push({\r\n filterProperty: header.index.toString(),\r\n filterConditionType: params.filterModel[prop] && params.filterModel[prop].filterConditionType,\r\n filterValues: params.filterModel[prop] && params.filterModel[prop].filterValues.map(x => {\r\n return {\r\n filterType: this.getFilterType(x.filterType.displayKey),\r\n filterValue: this.getFilterValue(x),\r\n filterToValue: this.getFilterType(x.filterType.displayKey) === Core.FilterTypeEnum.InRange ? x.filterToValue : null\r\n }\r\n })\r\n });\r\n }\r\n }\r\n }\r\n return filters;\r\n }\r\n\r\n estimatedActionFilter(params: IGetRowsParams): string {\r\n if (params && params.filterModel && params.filterModel['estimatedAction']) {\r\n return params.filterModel['estimatedAction'].filterValues[0].filterValue;\r\n }\r\n return null;\r\n }\r\n\r\n async getSelectedRowTotals(selectedRowsModel: Compliance.SelectedRowsModel): Promise {\r\n const searchModel = this.getSearchModelWithoutPagination(this.columnFilters({filterModel: this._gridApi.getFilterModel()} as IGetRowsParams), this.gridParams);\r\n searchModel.selectAllRows = selectedRowsModel.selectAllRows;\r\n searchModel.selectedRows = selectedRowsModel.selectedRows;\r\n searchModel.includeTotals = true;\r\n searchModel.includeOnlyTotals = true;\r\n\r\n const result = await lastValueFrom(this._entityImportRepository.getImportRows(this._dataSourceParams.importFileModel.importFileId, searchModel));\r\n return result.totals;\r\n }\r\n\r\n refresh(): void {\r\n this._lastFilterUsedInTotals = null;\r\n\r\n super.refresh();\r\n }\r\n\r\n private _setupFields(fields, rowObj, gridRow) {\r\n gridRow.fields.forEach(gr => {\r\n const importFieldHeader = this._dataSourceParams.importFileModel.importFileHeaders.find(ifh => gr.fieldIndex === ifh.index);\r\n const assignedField = this._dataSourceParams.importFileModel.assignedFields.find(af => af.value === `${importFieldHeader.importFileHeaderId}` && !af.isStatic);\r\n const field = assignedField && fields.find(f => f.importFieldId === assignedField.importFieldId);\r\n const key = field ? field.displayName : importFieldHeader.index;\r\n rowObj[key] = gr.currentValue === null ? gr.originalValue : gr.currentValue;\r\n rowObj.originalValues[key] = gr.originalValue;\r\n });\r\n\r\n this._dataSourceParams.importFileModel.assignedFields.forEach(af => {\r\n const field = fields.find(f => f.importFieldId === af.importFieldId);\r\n if (af.isStatic) {\r\n rowObj[field.displayName] = af.value;\r\n }\r\n });\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { IHeaderAngularComp } from 'ag-grid-angular';\r\nimport { IHeaderParams } from 'ag-grid-community';\r\n\r\n@Component({\r\n selector: 'entity-import-editor-estimated-action-header',\r\n template: `\r\n \r\n `\r\n})\r\nexport class EntityImportEditorEstimatedActionHeaderRendererComponent implements IHeaderAngularComp {\r\n private _params: IHeaderParams;\r\n\r\n agInit(params: IHeaderParams): void {\r\n this._params = params;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { IFloatingFilterComp } from 'ag-grid-angular';\r\nimport { IFloatingFilterParams } from 'ag-grid-community';\r\nimport { AgGridTextFilterComponent } from '../../../../AgGrid/Filters/Text/agGridTextFilter.component';\r\n\r\n@Component({\r\n selector: 'entity-import-editor-estimated-action-filter',\r\n template: ``,\r\n styles: [`\r\n option {\r\n font-weight: 900\r\n }\r\n\r\n `]\r\n})\r\nexport class EntityImportEditorEstimatedActionFilterRendererComponent implements IFloatingFilterComp {\r\n private _params: IFloatingFilterParams;\r\n\r\n selectedEstimatedAction: string = '';\r\n\r\n agInit(params: IFloatingFilterParams): void {\r\n this._params = params;\r\n }\r\n\r\n destroy?(): void;\r\n\r\n onParentModelChanged(parentModel: any): void {\r\n if (!parentModel || !parentModel.filterValues.length) {\r\n this.selectedEstimatedAction = '';\r\n return;\r\n }\r\n this.selectedEstimatedAction = parentModel.filterValues[0].filterValue;\r\n }\r\n\r\n selectedEstimatedActionChange(): void {\r\n this._params.parentFilterInstance(x => {\r\n const filterInstance = x as unknown as AgGridTextFilterComponent;\r\n filterInstance.onFloatingFilterChanged('equals', this.selectedEstimatedAction, true);\r\n });\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { UtilitiesService } from 'src/app/UI-Lib/Utilities/Utilities.Service.upgrade';\r\n\r\n@Component({\r\n selector: 'entity-import-editor-estimated-action',\r\n template: ``,\r\n styles: ['.deleted {color: var(--ace-danger-ghosted)}']\r\n})\r\nexport class EntityImportEditorEstimatedActionCellRendererComponent implements ICellRendererAngularComp {\r\n gridRow: Compliance.ImportGridRowGridModel;\r\n\r\n agInit(params: ICellRendererParams): void {\r\n this.gridRow = params.data as Compliance.ImportGridRowGridModel;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n isNotEvaluated(): boolean {\r\n return (!this.gridRow || !(this.gridRow.actualAction || this.gridRow.estimatedAction));\r\n }\r\n\r\n isUpdate(): boolean {\r\n return (this.gridRow && (this.gridRow.actualAction === 'update' || this.gridRow.estimatedAction === 'update'));\r\n }\r\n\r\n isInsert(): boolean {\r\n return (this.gridRow && (this.gridRow.actualAction === 'insert' || this.gridRow.estimatedAction === 'insert'));\r\n }\r\n\r\n isNoChange(): boolean {\r\n return (this.gridRow && (this.gridRow.actualAction === 'no change' || this.gridRow.estimatedAction === 'no change'));\r\n }\r\n\r\n isEntityDeleted(): boolean {\r\n return this.gridRow && this.gridRow.actualAction && this.gridRow.actualAction.endsWith('_Deleted');\r\n }\r\n\r\n isDelete(): boolean {\r\n return (this.gridRow && (this.gridRow.actualAction === 'delete' || this.gridRow.estimatedAction === 'delete'));\r\n }\r\n\r\n getTitle() {\r\n let title: string = '';\r\n\r\n if (this.isNotEvaluated()) {\r\n title = 'Not evaluated';\r\n } else if (this.isUpdate()) {\r\n title = 'Update';\r\n } else if (this.isInsert()) {\r\n title = 'Insert';\r\n } else if (this.isNoChange()) {\r\n title = 'No change';\r\n } else if (this.isDelete()) {\r\n title = 'Delete';\r\n }\r\n\r\n if (title != '' && this.isEntityDeleted()){\r\n title += ' (Has been deleted by user)';\r\n }\r\n\r\n return title;\r\n }\r\n\r\n get showControl(): boolean{\r\n return this.gridRow && UtilitiesService.isNumeric(this.gridRow.rowIndex);\r\n }\r\n}\r\n","import {ICellEditorAngularComp} from \"ag-grid-angular\";\r\nimport {ICellEditorParams} from \"ag-grid-community\";\r\nimport {Component, ViewChild} from \"@angular/core\";\r\nimport {AssetClassSelectorComponent} from \"../../../../../Asset/Asset-Class-Selector/assetClassSelector.component\";\r\n\r\nexport interface EntityImportEditorAssetClassSelectorCellEditorParams extends ICellEditorParams {\r\n getAssetClassifications(): Compliance.AssetClassificationModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-editor-asset-class-selector',\r\n template: ``\r\n})\r\nexport class EntityImportEditorAssetClassSelectorCellEditorComponent implements ICellEditorAngularComp {\r\n focusIn(): void {\r\n }\r\n\r\n focusOut(): void {\r\n }\r\n\r\n getValue(): any {\r\n return this.assetClassificationName;\r\n }\r\n\r\n isCancelAfterEnd(): boolean {\r\n if (this.assetClassSelector.assetClassificationName && !this.assetClassSelector.assetClassificationFilter){\r\n this._params.node.setDataValue(this._params.column.getColId(), '');\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n isCancelBeforeStart(): boolean {\r\n return false;\r\n }\r\n\r\n isPopup(): boolean {\r\n return false;\r\n }\r\n\r\n assetClassificationName: string;\r\n assetClassifications: Compliance.AssetClassificationModel[];\r\n\r\n @ViewChild(\"assetClassSelector\") assetClassSelector: AssetClassSelectorComponent;\r\n\r\n private _params: EntityImportEditorAssetClassSelectorCellEditorParams;\r\n\r\n async agInit(params: EntityImportEditorAssetClassSelectorCellEditorParams): Promise {\r\n this._params = params;\r\n this.assetClassificationName = params.value;\r\n this.assetClassifications = await params.getAssetClassifications();\r\n }\r\n\r\n onAssetClassificationChanged(assetClass: Compliance.AssetClassificationModel) {\r\n this.assetClassificationName = assetClass ? assetClass.name : null;\r\n this._params.node.setDataValue(this._params.column.getColId(), assetClass ? assetClass.name : null);\r\n }\r\n}\r\n","\r\n
\r\n
    \r\n
  • \r\n
    \r\n 0 ? '' : 'empty-tree-node'\" *ngIf=\"!isExpanded(topLevel); else collapse\" (click)=\"expandCategory(topLevel)\">\r\n \r\n 0 ? '' : 'empty-tree-node'\" (click)=\"collapseCategory(topLevel)\">\r\n \r\n {{ topLevel.name }}\r\n
    \r\n
      \r\n
    • \r\n
      \r\n 0 ? '' : 'empty-tree-node'\" *ngIf=\"!isExpanded(secondLevel); else collapseSecondLevel\" (click)=\"expandCategory(secondLevel)\">\r\n \r\n 0 ? '' : 'empty-tree-node'\" (click)=\"collapseCategory(secondLevel)\">\r\n \r\n {{ secondLevel.name }}\r\n
      \r\n
        \r\n
      • \r\n
        \r\n {{ thirdLevel.name }}\r\n
        \r\n
      • \r\n
      \r\n
    • \r\n
    \r\n
  • \r\n
\r\n
\r\n
\r\n","import { Component, ViewChild, ElementRef, OnInit } from '@angular/core';\r\nimport { animate, trigger, transition, style } from '@angular/animations';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { IncomeStatementCategoryRepository } from '../../../Compliance/Repositories/incomeStatementCategory.repository';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\n\r\nexport interface IncomeStatementCategoryPickerParams {\r\n incomeStatementCategoryId: number;\r\n incomeStatementCategories: Core.IncomeStatementCategoryModel[];\r\n glAccountTypeId: Compliance.GLAccountTypeEnum;\r\n}\r\n\r\n@Component({\r\n selector: 'income-statement-category-picker-modal',\r\n templateUrl: './incomeStatementCategoryPicker.component.html',\r\n animations: [\r\n trigger('pickerEnter', [\r\n transition(':enter', [\r\n style({ opacity: 0, transform: 'translateX(-2%)' }),\r\n animate(125, style({ opacity: 1, transform: 'translateX(0)' }))\r\n ]),\r\n transition(':leave', [\r\n animate(100, style({ opacity: 0, transform: 'translateX(-2%)' }))\r\n ])\r\n ])\r\n ]\r\n})\r\nexport class IncomeStatementCategoryPickerComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private _modalRef: BsModalRef,\r\n private _incomeStatementCategoryRepository: IncomeStatementCategoryRepository,\r\n private _elem: ElementRef\r\n ) { }\r\n\r\n @ViewChild('.active-category-picker') selectedIncomeStatementCategory: ElementRef;\r\n\r\n params: IncomeStatementCategoryPickerParams;\r\n result: Core.IncomeStatementCategoryModel;\r\n incomeStatementCategories: Core.IncomeStatementCategoryModel[];\r\n\r\n private _expandedIncomeStatementCategories: Set = new Set();\r\n\r\n async ngOnInit(): Promise {\r\n const result = this.params.incomeStatementCategories\r\n || await lastValueFrom(this._incomeStatementCategoryRepository.getIncomeStatementCategories());\r\n\r\n this.incomeStatementCategories = result.filter(x => this._matchesAccountType(x));\r\n if (this.params.incomeStatementCategoryId) {\r\n this.incomeStatementCategories.forEach(topLevel => {\r\n if (topLevel.childIncomeStatementCategories) {\r\n topLevel.childIncomeStatementCategories.forEach(secondLevel => {\r\n if (secondLevel.incomeStatementCategoryId === this.params.incomeStatementCategoryId) {\r\n this._expandedIncomeStatementCategories.add(topLevel.incomeStatementCategoryId);\r\n } else if (secondLevel.childIncomeStatementCategories &&\r\n secondLevel.childIncomeStatementCategories.find(ac => ac.incomeStatementCategoryId === this.params.incomeStatementCategoryId)) {\r\n this._expandedIncomeStatementCategories.add(topLevel.incomeStatementCategoryId);\r\n this._expandedIncomeStatementCategories.add(secondLevel.incomeStatementCategoryId);\r\n }\r\n });\r\n }\r\n });\r\n }\r\n\r\n setTimeout(() => {\r\n const elem = this._elem.nativeElement.querySelector('.active-category-link');\r\n if (elem) {\r\n elem.scrollIntoView({ behavior: 'smooth' });\r\n }\r\n }, 0);\r\n }\r\n\r\n selectIncomeStatementCategory(incomeStatementCategory: Core.IncomeStatementCategoryModel): void {\r\n this.result = incomeStatementCategory;\r\n this._modalRef.hide();\r\n }\r\n\r\n isSelected(incomeStatementCategory: Core.IncomeStatementCategoryModel): boolean {\r\n return incomeStatementCategory.incomeStatementCategoryId === this.params.incomeStatementCategoryId;\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n isExpanded(category: Core.IncomeStatementCategoryModel): boolean {\r\n return this._expandedIncomeStatementCategories.has(category.incomeStatementCategoryId);\r\n }\r\n\r\n expandCategory(category: Core.IncomeStatementCategoryModel): void {\r\n this._expandedIncomeStatementCategories.add(category.incomeStatementCategoryId);\r\n }\r\n\r\n collapseCategory(category: Core.IncomeStatementCategoryModel): void {\r\n this._expandedIncomeStatementCategories.delete(category.incomeStatementCategoryId);\r\n }\r\n\r\n private _matchesAccountType(category: Core.IncomeStatementCategoryModel): boolean {\r\n switch(this.params.glAccountTypeId) {\r\n case Compliance.GLAccountTypeEnum.Expense:\r\n return category.incomeStatementCategoryTypeId == Core.IncomeStatementCategoryTypeEnum.Expense;\r\n case Compliance.GLAccountTypeEnum.Revenue:\r\n return category.incomeStatementCategoryTypeId == Core.IncomeStatementCategoryTypeEnum.Income;\r\n case Compliance.GLAccountTypeEnum.Reporting:\r\n return category.incomeStatementCategoryTypeId == Core.IncomeStatementCategoryTypeEnum.Reporting;\r\n default:\r\n return true;\r\n }\r\n }\r\n}\r\n","\r\n\r\n {{model.extraPath}}{{model.name}}\r\n\r\n\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n","import { of as observableOf, Observable, Subscription } from 'rxjs';\r\nimport { first, mergeMap } from 'rxjs/operators';\r\nimport { Component, OnDestroy, OnInit, OnChanges, Input, Output, EventEmitter, SimpleChanges, SimpleChange } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { IncomeStatementCategoryPickerComponent, IncomeStatementCategoryPickerParams } from './incomeStatementCategoryPicker.component';\r\nimport { IncomeStatementCategoryRepository } from '../../../Compliance/Repositories';\r\n\r\ninterface IncomeStatementCategoryComponentChanges extends SimpleChanges {\r\n incomeStatementCategoryId: SimpleChange;\r\n incomeStatementCategoryName: SimpleChange;\r\n}\r\n\r\n@Component({\r\n selector: 'income-statement-category-selector',\r\n templateUrl: './incomeStatementCategorySelector.component.html',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: IncomeStatementCategorySelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class IncomeStatementCategorySelectorComponent implements OnInit, OnDestroy, OnChanges, ControlValueAccessor {\r\n constructor(\r\n private readonly _incomeStatementCategoryRepository: IncomeStatementCategoryRepository,\r\n private readonly _modalService: WeissmanModalService\r\n ) { }\r\n\r\n @Input() incomeStatementCategoryId: number;\r\n @Input() incomeStatementCategoryName: string;\r\n @Input() isDisabled: boolean = false;\r\n @Input() isRequiredField: boolean = true;\r\n @Input() isOverridden: boolean = false;\r\n @Input() incomeStatementCategories: Core.IncomeStatementCategoryModel[] = null;\r\n @Input() glAccountTypeId: Compliance.GLAccountTypeEnum;\r\n\r\n @Output() incomeStatementCategoryIdChange = new EventEmitter();\r\n @Output() incomeStatementCategoryChange = new EventEmitter();\r\n\r\n incomeStatementCategoryFilter: string = '';\r\n\r\n // this component will be considered initialized when the categories have been loaded\r\n // in the meanwhile, any selection attempts will be skipped\r\n isInitialized: boolean = false;\r\n\r\n incomeStatementCategories$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.incomeStatementCategoryFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterIncomeStatementCategories(token)));\r\n\r\n private _incomeStatementCategorySubscription: Subscription;\r\n private _onChangeFn: any;\r\n private _onTouchedFn: any;\r\n\r\n\r\n private _incomeStatementCategories: Core.IncomeStatementCategoryModel[] = [];\r\n\r\n ngOnInit(): void {\r\n if (this.incomeStatementCategories){\r\n this._populateIncomeStatementCategories(this.incomeStatementCategories);\r\n } else {\r\n this._incomeStatementCategorySubscription = this._incomeStatementCategoryRepository\r\n .getIncomeStatementCategories().pipe(\r\n first())\r\n .subscribe(data => {\r\n const incomeStatementCategories: any = data;\r\n this._populateIncomeStatementCategories(incomeStatementCategories);\r\n });\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._incomeStatementCategorySubscription && this._incomeStatementCategorySubscription.unsubscribe();\r\n }\r\n\r\n ngOnChanges(changes: IncomeStatementCategoryComponentChanges): void {\r\n if (changes.incomeStatementCategoryId) {\r\n this._selectIncomeStatementCategory(this.incomeStatementCategoryId);\r\n }\r\n\r\n if (changes.incomeStatementCategoryName) {\r\n this._selectIncomeStatementCategory(this.incomeStatementCategoryId, this.incomeStatementCategoryName, true);\r\n }\r\n }\r\n\r\n clear(): void {\r\n this.writeValue(null);\r\n }\r\n\r\n writeValue(incomeStatementCategoryId: number): void {\r\n this._selectIncomeStatementCategory(incomeStatementCategoryId);\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState?(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n onIncomeStatementCategoryBlur(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n this.onIncomeStatementCategorySelected(match);\r\n return;\r\n }\r\n\r\n if (!this.isRequiredField && this.incomeStatementCategoryFilter === '') {\r\n this.incomeStatementCategoryId = null;\r\n this.incomeStatementCategoryName = null;\r\n this.incomeStatementCategoryChange.emit(null);\r\n }\r\n\r\n this._selectIncomeStatementCategory(this.incomeStatementCategoryId);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onIncomeStatementCategorySelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const incomeStatementCategory = match.item as Core.IncomeStatementCategoryModel;\r\n this._selectIncomeStatementCategory(incomeStatementCategory.incomeStatementCategoryId);\r\n this.incomeStatementCategoryIdChange.emit(incomeStatementCategory.incomeStatementCategoryId);\r\n this.incomeStatementCategoryChange.emit(incomeStatementCategory);\r\n }\r\n }\r\n\r\n async openPickerModal(): Promise {\r\n const params: IncomeStatementCategoryPickerParams = {\r\n incomeStatementCategoryId: this.incomeStatementCategoryId,\r\n incomeStatementCategories: this.incomeStatementCategories,\r\n glAccountTypeId: this.glAccountTypeId\r\n };\r\n\r\n const result = await this._modalService.showAsync(IncomeStatementCategoryPickerComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._selectIncomeStatementCategory(result.incomeStatementCategoryId);\r\n this.incomeStatementCategoryIdChange.emit(this.incomeStatementCategoryId);\r\n this.incomeStatementCategoryChange.emit(result);\r\n }\r\n\r\n private _filterIncomeStatementCategories(filter: string): Observable {\r\n if (filter === null || filter === undefined) filter = '';\r\n\r\n return observableOf(\r\n (this._incomeStatementCategories || []).filter(i => i.name.toLowerCase().includes(filter.toLowerCase()) && this._matchesAccountType(i))\r\n );\r\n }\r\n\r\n private _selectIncomeStatementCategory(incomeStatementCategoryId: number, incomeStatementCategoryName?: string, forceFindByName: boolean = false): void {\r\n // keep track of the value that the classification is being set to\r\n this.incomeStatementCategoryId = incomeStatementCategoryId;\r\n\r\n // if not initialized then return\r\n // when initialized the asset class ID that is being tracked (above) will be selected\r\n if (!this.isInitialized) {\r\n return;\r\n }\r\n\r\n const incomeStatementCategory = this._incomeStatementCategories.find(osc => {\r\n if (forceFindByName) {\r\n return osc.name === incomeStatementCategoryName;\r\n } else {\r\n return osc.incomeStatementCategoryId === incomeStatementCategoryId || osc.name === incomeStatementCategoryName;\r\n }\r\n });\r\n\r\n if (incomeStatementCategory) {\r\n this.incomeStatementCategoryId = incomeStatementCategory.incomeStatementCategoryId;\r\n this.incomeStatementCategoryFilter = incomeStatementCategory.name;\r\n } else {\r\n this.incomeStatementCategoryId = null;\r\n this.incomeStatementCategoryFilter = null;\r\n }\r\n\r\n this._onChangeFn && this._onChangeFn(this.incomeStatementCategoryId);\r\n }\r\n\r\n private _populateIncomeStatementCategories(incomeStatementCategories: any){\r\n if (incomeStatementCategories) {\r\n incomeStatementCategories.forEach(outerItem => {\r\n this._incomeStatementCategories.push(outerItem);\r\n if (outerItem.childIncomeStatementCategories) {\r\n outerItem.childIncomeStatementCategories.forEach(secondLevelItem => {\r\n secondLevelItem.extraPath = `${outerItem.name } > `;\r\n this._incomeStatementCategories.push(secondLevelItem);\r\n if (secondLevelItem.childIncomeStatementCategories) {\r\n secondLevelItem.childIncomeStatementCategories.forEach(thirdLevelItem => {\r\n thirdLevelItem.extraPath = `${secondLevelItem.extraPath + secondLevelItem.name } > `;\r\n this._incomeStatementCategories.push(thirdLevelItem);\r\n });\r\n }\r\n });\r\n }\r\n });\r\n }\r\n\r\n this.isInitialized = true;\r\n this._selectIncomeStatementCategory(this.incomeStatementCategoryId, this.incomeStatementCategoryName);\r\n }\r\n\r\n private _matchesAccountType(category: Core.IncomeStatementCategoryModel): boolean {\r\n switch(this.glAccountTypeId) {\r\n case Compliance.GLAccountTypeEnum.Expense:\r\n return category.incomeStatementCategoryTypeId == Core.IncomeStatementCategoryTypeEnum.Expense;\r\n case Compliance.GLAccountTypeEnum.Revenue:\r\n return category.incomeStatementCategoryTypeId == Core.IncomeStatementCategoryTypeEnum.Income;\r\n case Compliance.GLAccountTypeEnum.Reporting:\r\n return category.incomeStatementCategoryTypeId == Core.IncomeStatementCategoryTypeEnum.Reporting;\r\n default:\r\n return true;\r\n }\r\n }\r\n}\r\n","\r\n","import { Component, EventEmitter, Input, OnInit, Output } from \"@angular/core\";\r\n\r\n@Component({\r\n selector: 'import-bulk-update-action',\r\n templateUrl: './importBulkUpdateAction.component.html',\r\n styles: ['select {width:120px}']\r\n})\r\nexport class ImportBulkUpdateActionComponent implements OnInit{\r\n constructor(\r\n ){\r\n this._possibleActions = [\r\n { name: 'No Change', value: Compliance.ImportBulkUpdateFieldActionEnum.NoChange },\r\n { name: 'Change To', value: Compliance.ImportBulkUpdateFieldActionEnum.ChangeTo },\r\n { name: 'Remove User Value', value: Compliance.ImportBulkUpdateFieldActionEnum.RemoveUserValue }\r\n ];\r\n }\r\n\r\n @Input() fieldAction: Compliance.ImportBulkUpdateFieldActionEnum;\r\n @Output() fieldActionChange = new EventEmitter();\r\n @Input() requiredField: boolean;\r\n @Input() disabled: boolean;\r\n @Input() changeToAllowed: boolean = true;\r\n\r\n private _possibleActions: Compliance.NameValuePair[];\r\n selectedAction: Compliance.ImportBulkUpdateFieldActionEnum = Compliance.ImportBulkUpdateFieldActionEnum.NoChange;\r\n\r\n ngOnInit(): void {\r\n }\r\n\r\n fieldActionChanged(action: Compliance.ImportBulkUpdateFieldActionEnum) : void{\r\n this.selectedAction = action;\r\n this.fieldActionChange.next(action);\r\n }\r\n\r\n isSelected(action: Compliance.ImportBulkUpdateFieldActionEnum): boolean{\r\n return action === Compliance.ImportBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n\r\n get possibleActions(): Compliance.NameValuePair[]{\r\n return this._possibleActions.filter(i => this.changeToAllowed || i.name != 'Change To');\r\n }\r\n}\r\n","\r\nimport {of as observableOf, Observable} from 'rxjs';\r\nimport {\r\n Component,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n SimpleChange,\r\n SimpleChanges\r\n} from \"@angular/core\";\r\nimport {ControlValueAccessor, NG_VALUE_ACCESSOR} from \"@angular/forms\";\r\nimport {TypeaheadMatch} from \"ngx-bootstrap/typeahead\";\r\nimport * as _ from \"lodash\";\r\nimport { mergeMap } from 'rxjs/operators';\r\n\r\ninterface AssessorSelectorComponentChanges extends SimpleChanges {\r\n assessorValue: SimpleChange\r\n}\r\n\r\n@Component({\r\n templateUrl: './assessorSelector.component.html',\r\n selector: 'assessor-selector',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: AssessorSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class AssessorSelectorComponent implements ControlValueAccessor {\r\n\r\n // reactive forms functions\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n @Input() assessors: Compliance.ImportAssessorModel[] = [];\r\n @Input() isRequiredField: boolean = true;\r\n @Input() isDisabled: boolean = false;\r\n @Input() isOverridden: boolean = false;\r\n\r\n @Output() assessorChanged = new EventEmitter();\r\n\r\n value: string;\r\n assessorFilter: string = '';\r\n\r\n assessors$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.assessorFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterAssessors(token)));\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n writeValue(assessorValue: string): void {\r\n this.value = assessorValue;\r\n this.assessorFilter = assessorValue;\r\n }\r\n\r\n onAssessorBlur(): void {\r\n if (!this.isRequiredField && this.assessorFilter === '') {\r\n this.assessorChanged.emit(null);\r\n }\r\n\r\n this._selectAssessor(this.value);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onAssessorSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const assessor = match.item as Compliance.ImportAssessorModel;\r\n this.assessorFilter = assessor.name;\r\n this.assessorChanged.emit(assessor.name);\r\n }\r\n }\r\n\r\n private _filterAssessors(filter: string): Observable {\r\n if (filter === null || filter === undefined) {\r\n filter = '';\r\n }\r\n\r\n return observableOf(\r\n _.filter(this.assessors, i => this._isMatch(i, filter))\r\n );\r\n }\r\n\r\n private _selectAssessor(assessorValue: string): void {\r\n const assessors = this.assessors && this.assessors.filter(a => this._isMatch(a, assessorValue));\r\n\r\n if (assessors && assessors.length == 1) {\r\n this.assessorFilter = assessorValue;\r\n } else {\r\n this.assessorFilter = null;\r\n }\r\n }\r\n\r\n private _isMatch(assessor: Compliance.ImportAssessorModel, selectedValue: string): boolean {\r\n const value = (selectedValue || '').toLocaleLowerCase();\r\n const localAssessor = {\r\n assessorId: assessor.assessorId,\r\n name: assessor.name.toLocaleLowerCase(),\r\n primaryMatch: assessor.primaryMatch.toLocaleLowerCase(),\r\n additionalMatches: assessor.additionalMatches.map(i => i.toLocaleLowerCase())\r\n } as Compliance.ImportAssessorModel;\r\n\r\n let result = value === '';\r\n\r\n if (!result){\r\n result = localAssessor.name.indexOf(value) >= 0;\r\n }\r\n\r\n if (!result) {\r\n result = value === localAssessor.primaryMatch ||\r\n value.startsWith(localAssessor.primaryMatch + ' ') ||\r\n value.endsWith(' ' + localAssessor.primaryMatch) ||\r\n value.indexOf(' ' + localAssessor.primaryMatch + ' ') !== -1;\r\n }\r\n\r\n if (!result){\r\n _.forEach(localAssessor.additionalMatches, additionalMatch => {\r\n result = value.indexOf(localAssessor.primaryMatch) !== -1 && value.indexOf(additionalMatch) !== -1;\r\n\r\n return !result;\r\n });\r\n }\r\n\r\n if (!result) {\r\n result = localAssessor.assessorId === +value;\r\n }\r\n\r\n if (!result){\r\n _.forEach(localAssessor.additionalMatches, additionalMatch => {\r\n result = value === (localAssessor.primaryMatch + ' ' + additionalMatch).toLocaleLowerCase();\r\n\r\n return !result;\r\n });\r\n }\r\n\r\n return result;\r\n }\r\n}\r\n","
\r\n \r\n
\r\n","
\r\n \r\n
\r\n","import {\r\n Component,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n SimpleChange,\r\n SimpleChanges\r\n} from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\n\r\n@Component({\r\n templateUrl: './assessmentClassSelector.component.html',\r\n selector: 'assessment-class-selector',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: AssessmentClassSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class AssessmentClassSelectorComponent implements ControlValueAccessor {\r\n\r\n // reactive forms functions\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n @Input() values: string[] = [];\r\n @Input() isOverridden: boolean = false;\r\n @Input() isDisabled: boolean = false;\r\n\r\n @Output() changed = new EventEmitter();\r\n\r\n value: string;\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n writeValue(assessmentClass: string): void {\r\n this.value = assessmentClass;\r\n }\r\n\r\n select(value: string): void {\r\n this.value = value;\r\n this.changed.emit(value);\r\n }\r\n}\r\n","\r\nimport {of as observableOf, Observable } from 'rxjs';\r\nimport {\r\n Component,\r\n EventEmitter,\r\n Input,\r\n Output\r\n} from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport * as _ from 'lodash';\r\nimport { mergeMap } from 'rxjs/operators';\r\nimport {WeissmanKeyValueDisplayPipe} from \"../../../../../../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe\";\r\nimport {ExtendedGLAccountModel} from \"../../../../../../Asset/Asset-Details/Asset-Info/extendedGLAccountModel\";\r\n\r\n@Component({\r\n templateUrl: './glAccountSelector.component.html',\r\n selector: 'glaccount-selector',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: GLAccountSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class GLAccountSelectorComponent implements ControlValueAccessor {\r\n constructor(private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe){\r\n\r\n }\r\n // reactive forms functions\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n private _glAccounts: ExtendedGLAccountModel[] = [];\r\n\r\n @Input() set values(values: Compliance.GLAccountModel[]) {\r\n this._glAccounts = (values || []).map(x => new ExtendedGLAccountModel(x, this._keyValueDisplayPipe))\r\n }\r\n @Input() isOverridden: boolean = false;\r\n @Input() isDisabled: boolean = false;\r\n\r\n @Output() changed = new EventEmitter();\r\n\r\n value: string = '';\r\n filter: string = '';\r\n\r\n values$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.filter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filter(token)));\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n writeValue(glAccount: string): void {\r\n this._select(glAccount);\r\n }\r\n\r\n onBlur(): void {\r\n this._select(this.filter === '' ? '' : this.value);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const glAccount = match.item as ExtendedGLAccountModel;\r\n this._select(glAccount.model.accountNumber);\r\n this.changed.emit(glAccount.model.accountNumber);\r\n }\r\n }\r\n\r\n private _filter(filter: string): Observable {\r\n if (filter === null || filter === undefined) {\r\n filter = '';\r\n }\r\n\r\n return observableOf(\r\n (this._glAccounts || []).filter(x => filter === '' ||\r\n x.displayName.toLowerCase().includes(filter.toLowerCase()))\r\n );\r\n }\r\n\r\n private _select(value: string): void {\r\n this.value = value;\r\n\r\n const glAccount = _.find(this._glAccounts, (x) => x.model.accountNumber === value);\r\n\r\n if (glAccount) {\r\n this.filter = value;\r\n } else {\r\n this.filter = null;\r\n }\r\n }\r\n}\r\n","
\r\n \r\n
\r\n","import {of as observableOf, Observable} from 'rxjs';\r\nimport {\r\n Component,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n SimpleChange,\r\n SimpleChanges\r\n} from \"@angular/core\";\r\nimport {ControlValueAccessor, NG_VALUE_ACCESSOR} from \"@angular/forms\";\r\nimport {TypeaheadMatch} from \"ngx-bootstrap/typeahead\";\r\nimport { mergeMap } from 'rxjs/operators';\r\n\r\ninterface AssessorSelectorComponentChanges extends SimpleChanges {\r\n assessorValue: SimpleChange\r\n}\r\n\r\n@Component({\r\n templateUrl: './taxingDistrictSelector.component.html',\r\n selector: 'taxing-district-selector',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: TaxingDistrictSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class TaxingDistrictSelectorComponent implements ControlValueAccessor {\r\n\r\n // reactive forms functions\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n @Input() values: Core.TaxingDistrictModel[] = [];\r\n @Input() isDisabled: boolean = false;\r\n @Input() isOverridden: boolean = false;\r\n\r\n @Output() changed = new EventEmitter();\r\n\r\n value: string;\r\n filter: string = '';\r\n\r\n typeaheadValues: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.filter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filter(token)));\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n writeValue(value: string): void {\r\n this.value = value;\r\n this.filter = value;\r\n }\r\n\r\n onBlur(): void {\r\n if (this.filter === '') {\r\n this.changed.emit(null);\r\n }\r\n\r\n this._select(this.value);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const taxingDistrict = match.item as Core.TaxingDistrictModel;\r\n\r\n const allMatches = this.values.filter(i => this._isMatch(i, taxingDistrict.code));\r\n let code = taxingDistrict.code;\r\n\r\n if (allMatches.length > 1) {\r\n code = `${taxingDistrict.code}|${taxingDistrict.townshipCode}`;\r\n }\r\n\r\n this._select(code);\r\n this.changed.emit(code);\r\n }\r\n }\r\n\r\n private _filter(filter: string): Observable {\r\n if (filter === null || filter === undefined) {\r\n filter = '';\r\n }\r\n\r\n const filtered = (this.values || []).filter(i => this._isMatch(i, filter));\r\n\r\n return observableOf(\r\n filtered.sort((a, b) => a.displayName.localeCompare(b.displayName))\r\n );\r\n }\r\n\r\n private _select(value: string): void {\r\n const taxingDistricts = this.values && this.values.filter(a => this._isMatch(a, value));\r\n\r\n if (taxingDistricts && taxingDistricts.length === 1) {\r\n this.filter = value;\r\n } else {\r\n this.filter = null;\r\n }\r\n }\r\n\r\n private _isMatch(taxingDistrict: Core.TaxingDistrictModel, selectedValue: string): boolean {\r\n const value = (selectedValue || '').toLocaleLowerCase();\r\n const localTaxingDistrict = {\r\n taxingDistrictId: taxingDistrict.taxingDistrictId,\r\n code: taxingDistrict.code.toLocaleLowerCase(),\r\n name: taxingDistrict.name.toLocaleLowerCase(),\r\n townshipCode: taxingDistrict.townshipCode.toLocaleLowerCase(),\r\n townshipName: taxingDistrict.townshipName.toLocaleLowerCase(),\r\n } as Core.TaxingDistrictModel;\r\n\r\n let result = value === '';\r\n\r\n if (!result) {\r\n const items = value.split('|');\r\n result = (localTaxingDistrict.name.indexOf(items[0]) >= 0 || localTaxingDistrict.code.indexOf(items[0]) >= 0) &&\r\n (items.length === 1 || localTaxingDistrict.townshipName.indexOf(items[1]) >= 0 || localTaxingDistrict.townshipCode.indexOf(items[1]) >= 0);\r\n }\r\n\r\n return result;\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{mappedField.name}}\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n

{{validationMessage}}

\r\n
\r\n
\r\n
\r\n
\r\n","
\r\n \r\n
\r\n","import { Component, OnDestroy } from '@angular/core';\r\nimport {BsModalRef} from \"ngx-bootstrap/modal\";\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../../../../../Busy-Indicator';\r\nimport {BusyIndicatorMessageManager} from '../../../../../../Busy-Indicator';\r\nimport {EntityImportRepository} from '../../../../../Repositories';\r\nimport {EntityImportProcessService} from \"../../../importProcess.service\";\r\nimport * as _ from 'lodash';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n templateUrl: './importBulkUpdate.component.html',\r\n selector: 'import-bulk-update'\r\n})\r\nexport class ImportBulkUpdateComponent implements OnDestroy{\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _entityImportRepository: EntityImportRepository,\r\n private readonly _entityImportProcessService: EntityImportProcessService){\r\n }\r\n\r\n private _isGlAccountTypeDirty: boolean = false;\r\n private _isIncomeStatementCategoryDirty: boolean = false;\r\n private _busyRef: BusyIndicatorRef;\r\n private _bulkUpdateModel: Compliance.ImportBulkUpdateFieldModel[] = [];\r\n private _destroy$: Subject = new Subject();\r\n\r\n importId: number;\r\n importFileId: number;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n mappedFields: FieldInfo[] = [];\r\n selectionModel: Compliance.ImportBulkOperationModel;\r\n saveCompleteCallback: (selectionModel: Compliance.ImportBulkOperationModel) => void;\r\n validationMessage: string;\r\n selectedCount: number;\r\n busyRefId: string = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n\r\n isSaving: boolean = false;\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async save(): Promise {\r\n this.isSaving = true;\r\n\r\n try {\r\n const updateModel = {\r\n updateFields: this._bulkUpdateModel,\r\n } as Compliance.ImportBulkUpdateModel;\r\n\r\n _.extend(updateModel, this.selectionModel);\r\n\r\n this._showBusyIndicator('Bulk update', 'Updating', null);\r\n\r\n const longRunningProcessId = await lastValueFrom(this._entityImportRepository.bulkUpdateFieldsAsync(this.importFileId, updateModel));\r\n await this._busyRef.setLongRunningProcessId(longRunningProcessId);\r\n } catch (e2) {\r\n await this._hideBusyIndicator();\r\n return Promise.reject(e2);\r\n }\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n isDisabled(importFileSpecificationFieldId: number): boolean {\r\n const fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === importFileSpecificationFieldId);\r\n return !fieldAction || fieldAction.action !== Compliance.ImportBulkUpdateFieldActionEnum.ChangeTo;\r\n }\r\n\r\n onActionChanged(mappedField: FieldInfo, action: Compliance.ImportBulkUpdateFieldActionEnum): void {\r\n let fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === mappedField.importFileSpecificationFieldId);\r\n\r\n if (!fieldAction){\r\n fieldAction = {\r\n importFileSpecificationImportFieldId: mappedField.importFileSpecificationFieldId,\r\n } as Compliance.ImportBulkUpdateFieldModel;\r\n this._bulkUpdateModel.push(fieldAction);\r\n }\r\n\r\n fieldAction.action = action;\r\n\r\n fieldAction.value = (action === Compliance.ImportBulkUpdateFieldActionEnum.ChangeTo) ? '' : null;\r\n\r\n if(mappedField.uiCellRenderer === 'IncomeStatementCategorySelector') {\r\n this._isIncomeStatementCategoryDirty = fieldAction.action !== Compliance.ImportBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n\r\n if(mappedField.uiCellRenderer === 'GLAccountTypeSelector') {\r\n this._isGlAccountTypeDirty = fieldAction.action !== Compliance.ImportBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n }\r\n\r\n onValueChanged(importFileSpecificationFieldId: number, value: string): void {\r\n let fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === importFileSpecificationFieldId);\r\n\r\n if (!fieldAction){\r\n fieldAction = {} as Compliance.ImportBulkUpdateFieldModel;\r\n }\r\n\r\n fieldAction.value = value;\r\n }\r\n\r\n onAssetClassificationChanged(importFileSpecificationFieldId: number, assetClass: Compliance.AssetClassificationModel) {\r\n const value = assetClass ? assetClass.name : null;\r\n\r\n let fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === importFileSpecificationFieldId);\r\n\r\n if (!fieldAction){\r\n fieldAction = {} as Compliance.ImportBulkUpdateFieldModel;\r\n }\r\n\r\n fieldAction.value = value;\r\n }\r\n\r\n onIncomeStatementCategoryChanged(importFileSpecificationFieldId: number, incomeStatementCategory: Core.IncomeStatementCategoryModel) {\r\n const value = incomeStatementCategory ? incomeStatementCategory.name : null;\r\n\r\n let fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === importFileSpecificationFieldId);\r\n\r\n if (!fieldAction){\r\n fieldAction = {} as Compliance.ImportBulkUpdateFieldModel;\r\n }\r\n\r\n fieldAction.value = value;\r\n }\r\n\r\n getValue(importFileSpecificationFieldId: number): string {\r\n const fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === importFileSpecificationFieldId);\r\n\r\n return fieldAction && fieldAction.value;\r\n }\r\n\r\n get isFormValid(): boolean{\r\n let isValid: boolean;\r\n\r\n isValid = !!this._bulkUpdateModel.find(i => i.action === Compliance.ImportBulkUpdateFieldActionEnum.ChangeTo && (i.value === '' || !!i.value))\r\n || !!this._bulkUpdateModel.find(i => i.action === Compliance.ImportBulkUpdateFieldActionEnum.RemoveUserValue);\r\n\r\n return isValid;\r\n }\r\n\r\n onAssessorChanged(importFileSpecificationFieldId: number, assessorValue?: string) {\r\n let fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === importFileSpecificationFieldId);\r\n\r\n if (!fieldAction){\r\n fieldAction = {} as Compliance.ImportBulkUpdateFieldModel;\r\n }\r\n\r\n fieldAction.value = assessorValue;\r\n }\r\n\r\n onAssessmentClassChanged(importFileSpecificationFieldId: number, assessmentClassValue?: string) {\r\n let fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === importFileSpecificationFieldId);\r\n\r\n if (!fieldAction){\r\n fieldAction = {} as Compliance.ImportBulkUpdateFieldModel;\r\n }\r\n\r\n fieldAction.value = assessmentClassValue;\r\n }\r\n\r\n onGLAccountChanged(importFileSpecificationFieldId: number, glAccount: string) {\r\n const value = glAccount ? glAccount : null;\r\n\r\n let fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === importFileSpecificationFieldId);\r\n\r\n if (!fieldAction){\r\n fieldAction = {} as Compliance.ImportBulkUpdateFieldModel;\r\n }\r\n\r\n fieldAction.value = value;\r\n }\r\n\r\n onTaxingDistrictChanged(importFileSpecificationFieldId: number, value?: string) {\r\n let fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === importFileSpecificationFieldId);\r\n\r\n if (!fieldAction){\r\n fieldAction = {} as Compliance.ImportBulkUpdateFieldModel;\r\n }\r\n\r\n fieldAction.value = value;\r\n }\r\n\r\n onGlAccountTypeChanged(importFileSpecificationFieldId: number, eventTarget: EventTarget) {\r\n const glAccountType = (eventTarget as HTMLSelectElement).value;\r\n\r\n let fieldAction = this._bulkUpdateModel.find(i => i.importFileSpecificationImportFieldId === importFileSpecificationFieldId);\r\n\r\n if (!fieldAction){\r\n fieldAction = {} as Compliance.ImportBulkUpdateFieldModel;\r\n }\r\n\r\n fieldAction.value = glAccountType;\r\n }\r\n\r\n isChangeToAllowed(mappedField: FieldInfo): boolean {\r\n const areAdditionalParamsValid = !mappedField.additionalParams || mappedField.additionalParams.length !== 0;\r\n\r\n switch(mappedField.uiCellRenderer) {\r\n case 'IncomeStatementCategorySelector':\r\n return areAdditionalParamsValid && !this._isGlAccountTypeDirty;\r\n case 'GLAccountTypeSelector':\r\n return areAdditionalParamsValid && !this._isIncomeStatementCategoryDirty;\r\n default:\r\n return areAdditionalParamsValid;\r\n }\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', lrpId: number): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: lrpId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: false,\r\n canDismiss: false\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success) => {\r\n if (success) {\r\n try {\r\n if (this.saveCompleteCallback) {\r\n this.saveCompleteCallback(this.selectionModel);\r\n }\r\n } finally {\r\n await this._hideBusyIndicator();\r\n this.isSaving = false;\r\n this._bsModalRef.hide();\r\n }\r\n } else {\r\n await this._hideBusyIndicator();\r\n this.isSaving = false;\r\n }\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._destroy$.next();\r\n }\r\n}\r\n\r\nexport class FieldInfo{\r\n name: string;\r\n isMappingRequired: boolean;\r\n importFileSpecificationFieldId: number;\r\n uiCellRenderer: string;\r\n additionalParams: any;\r\n}\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { of as observableOf, Observable } from 'rxjs';\r\nimport { mergeMap } from 'rxjs/operators';\r\nimport * as _ from 'lodash';\r\n\r\nexport type Predicate = (...args: any) => boolean;\r\nexport type HigherOrderFn = (...args: any) => T;\r\n\r\n@Component({\r\n selector: 'typeahead-selector',\r\n templateUrl: './typeaheadSelector.component.html',\r\n styleUrls: ['./typeaheadSelector.component.scss'],\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: TypeaheadSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class TypeaheadSelectorComponent implements ControlValueAccessor {\r\n\r\n @Input() set values(values: any[]) {\r\n this._allValues = values || [];\r\n this._select(this.value);\r\n }\r\n @Input() labelProperty: string = 'label';\r\n @Input() valueProperty: string = 'value';\r\n @Input() sortProperty: string;\r\n @Input() placeholder: string = '';\r\n @Input() isOverridden: boolean = false;\r\n @Input() canReset: boolean = false;\r\n @Input() isRequiredField: boolean = true;\r\n @Input() originalValue: string;\r\n @Input() filterFn: HigherOrderFn;\r\n @Input() findFn: HigherOrderFn;\r\n\r\n @Output() changed = new EventEmitter();\r\n\r\n disabled: boolean;\r\n value: string = '';\r\n filter: string = '';\r\n\r\n private _allValues: any[] = [];\r\n\r\n // reactive forms functions\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n get showReset(): boolean {\r\n return this.canReset && !this.disabled && (this.originalValue && this.filter !== this.originalValue) || this.isOverridden;\r\n }\r\n\r\n values$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.filter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filter(token)));\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState(disabled: boolean): void {\r\n this.disabled = disabled;\r\n }\r\n\r\n writeValue(value: string): void {\r\n this._select(value);\r\n }\r\n\r\n onBlur(): void {\r\n this._select(this.filter);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const selected = match.item;\r\n const value = _.get(selected, this.valueProperty);\r\n this._select(value);\r\n this.changed.emit(value);\r\n }\r\n }\r\n\r\n resetToOriginalValue(): void {\r\n this.value = null;\r\n this.filter = this.originalValue;\r\n this.changed.emit(null);\r\n }\r\n\r\n private _filter(filter: string): Observable {\r\n if (filter === null || filter === undefined) {\r\n filter = '';\r\n }\r\n const filterFn = this.filterFn(filter);\r\n const result = (this._allValues || []).filter(filterFn);\r\n if (this.sortProperty) {\r\n result.sort((a, b) => `${a[this.sortProperty]}`.localeCompare(`${b[this.sortProperty]}`));\r\n }\r\n return observableOf(result);\r\n }\r\n\r\n private _select(value: string): void {\r\n this.value = value;\r\n\r\n let item;\r\n if (this.findFn) {\r\n const findFn = this.findFn(value);\r\n item = this._allValues.find(findFn);\r\n } else {\r\n item = this._allValues.find((x) => _.get(x, this.valueProperty) === value);\r\n }\r\n\r\n if (item) {\r\n this.filter = value;\r\n } else if (value === '') {\r\n this.filter = null;\r\n } else {\r\n this.filter = value;\r\n }\r\n }\r\n}\r\n","
\r\n \r\n \r\n \r\n \r\n
\r\n","import { ICellEditorAngularComp } from \"ag-grid-angular\";\r\nimport { ICellEditorParams } from \"ag-grid-community\";\r\nimport { Component, ViewChild } from \"@angular/core\";\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { HigherOrderFn, Predicate, TypeaheadSelectorComponent } from '../Selectors/Typeahead-Selector/typeaheadSelector.component';\r\n\r\nexport interface EntityImportEditorAssessorSelectorCellEditorParams extends ICellEditorParams {\r\n getAssessors(rowIndex: number): Compliance.ImportAssessorModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-editor-assessor-selector',\r\n template: ``\r\n})\r\nexport class EntityImportEditorAssessorSelectorCellEditorComponent implements ICellEditorAngularComp {\r\n @ViewChild(\"typeaheadSelector\", { static: true }) typeaheadSelector: TypeaheadSelectorComponent;\r\n\r\n gridRow: Compliance.ImportGridRowGridModel;\r\n assessorValue: UntypedFormControl = new UntypedFormControl({ value: null, disabled: true });\r\n assessors: Compliance.ImportAssessorModel[];\r\n originalValue: string;\r\n typeaheadFilter: HigherOrderFn = (filter: string) => (x: Compliance.ImportAssessorModel) => this._isMatch(x, filter);\r\n\r\n private _params: EntityImportEditorAssessorSelectorCellEditorParams;\r\n\r\n focusIn(): void {\r\n }\r\n\r\n focusOut(): void {\r\n }\r\n\r\n getValue(): any {\r\n return this.assessorValue.value;\r\n }\r\n\r\n isCancelAfterEnd(): boolean {\r\n if (this.typeaheadSelector.value && !this.typeaheadSelector.filter) {\r\n this._params.node.setDataValue(this._params.column.getColId(), '');\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n isCancelBeforeStart(): boolean {\r\n return false;\r\n }\r\n\r\n isPopup(): boolean {\r\n return false;\r\n }\r\n\r\n async agInit(params: EntityImportEditorAssessorSelectorCellEditorParams): Promise {\r\n this.gridRow = params.data as Compliance.ImportGridRowGridModel;\r\n\r\n this._params = params;\r\n\r\n if (this._params.data && this._params.data.originalValues) {\r\n this.originalValue = this._params.data.originalValues[this._params.colDef.field];\r\n }\r\n\r\n this.assessorValue.setValue(params.value);\r\n\r\n this.assessors = await params.getAssessors(this.gridRow.rowIndex);\r\n\r\n if (this.assessors && this.assessors.length) {\r\n this.assessorValue.enable();\r\n }\r\n }\r\n\r\n onAssessorChanged(assessorValue?: string): void {\r\n if (this.assessorValue.value !== assessorValue) {\r\n this.assessorValue.setValue(assessorValue);\r\n this._params.node.setDataValue(this._params.column.getColId(), assessorValue);\r\n }\r\n }\r\n\r\n private _isMatch(assessor: Compliance.ImportAssessorModel, selectedValue: string): boolean {\r\n const value = (selectedValue || '').toLocaleLowerCase();\r\n const localAssessor = {\r\n assessorId: assessor.assessorId,\r\n name: assessor.name.toLocaleLowerCase(),\r\n primaryMatch: assessor.primaryMatch.toLocaleLowerCase(),\r\n additionalMatches: assessor.additionalMatches.map(i => i.toLocaleLowerCase())\r\n } as Compliance.ImportAssessorModel;\r\n\r\n let result = value === '';\r\n\r\n if (!result) {\r\n result = localAssessor.name.indexOf(value) >= 0;\r\n }\r\n\r\n if (!result) {\r\n result = value === localAssessor.primaryMatch ||\r\n value.startsWith(localAssessor.primaryMatch + ' ') ||\r\n value.endsWith(' ' + localAssessor.primaryMatch) ||\r\n value.indexOf(' ' + localAssessor.primaryMatch + ' ') !== -1;\r\n }\r\n\r\n if (!result) {\r\n localAssessor.additionalMatches.forEach(additionalMatch => {\r\n result = value.indexOf(localAssessor.primaryMatch) !== -1 && value.indexOf(additionalMatch) !== -1;\r\n\r\n return !result;\r\n });\r\n }\r\n\r\n if (!result) {\r\n result = localAssessor.assessorId === +value;\r\n }\r\n\r\n if (!result) {\r\n localAssessor.additionalMatches.forEach(additionalMatch => {\r\n result = value === (localAssessor.primaryMatch + ' ' + additionalMatch).toLocaleLowerCase();\r\n\r\n return !result;\r\n });\r\n }\r\n\r\n return result;\r\n }\r\n}\r\n","import { ICellEditorAngularComp } from 'ag-grid-angular';\r\nimport { ICellEditorParams } from 'ag-grid-community';\r\nimport { Component, ViewChild } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { TypeaheadSelectorComponent, HigherOrderFn, Predicate } from '../Selectors/Typeahead-Selector/typeaheadSelector.component';\r\n\r\nexport interface EntityImportEditorAttachmentTypeSelectorCellEditorParams extends ICellEditorParams {\r\n getAttachmentTypes(row: Compliance.ImportGridRowGridModel): Compliance.AttachmentTypeViewModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-editor-attachment-type-selector',\r\n template: `\r\n `\r\n})\r\nexport class EntityImportEditorAttachmentTypeSelectorCellEditorComponent implements ICellEditorAngularComp {\r\n @ViewChild(\"typeaheadSelector\", { static: true }) typeaheadSelector: TypeaheadSelectorComponent;\r\n\r\n gridRow: Compliance.ImportGridRowGridModel;\r\n attachmentType: UntypedFormControl = new UntypedFormControl({ value: null, disabled: true });\r\n values: Compliance.AttachmentTypeViewModel[];\r\n originalValue: string;\r\n typeaheadFilter: HigherOrderFn = (filter: string) => (x: Compliance.AttachmentTypeViewModel) =>\r\n x.attachmentType.toLowerCase().includes(filter.toLowerCase());\r\n\r\n private _params: EntityImportEditorAttachmentTypeSelectorCellEditorParams;\r\n\r\n focusIn(): void {\r\n }\r\n\r\n focusOut(): void {\r\n }\r\n\r\n getValue(): any {\r\n return this.attachmentType.value;\r\n }\r\n\r\n isCancelAfterEnd(): boolean {\r\n if (this.typeaheadSelector.value && !this.typeaheadSelector.filter) {\r\n this._params.node.setDataValue(this._params.column.getColId(), '');\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n isCancelBeforeStart(): boolean {\r\n return false;\r\n }\r\n\r\n isPopup(): boolean {\r\n return false;\r\n }\r\n\r\n async agInit(params: EntityImportEditorAttachmentTypeSelectorCellEditorParams): Promise {\r\n this.gridRow = params.data as Compliance.ImportGridRowGridModel;\r\n\r\n this._params = params;\r\n\r\n if (this._params.data && this._params.data.originalValues) {\r\n this.originalValue = this._params.data.originalValues[this._params.colDef.field];\r\n }\r\n\r\n this.attachmentType.setValue(params.value);\r\n\r\n this.values = await params.getAttachmentTypes(this.gridRow);\r\n\r\n if (this.values && this.values.length) {\r\n this.attachmentType.enable();\r\n }\r\n }\r\n\r\n onChanged(value?: string) {\r\n if (this.attachmentType.value !== value) {\r\n this.attachmentType.setValue(value);\r\n this._params.node.setDataValue(this._params.column.getColId(), value);\r\n }\r\n }\r\n}\r\n","
\r\n \r\n
\r\n","import {\r\n Component,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n SimpleChange,\r\n SimpleChanges\r\n} from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\n\r\n@Component({\r\n templateUrl: './leaseTypeSelector.component.html',\r\n selector: 'lease-type-selector',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: LeaseTypeSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class LeaseTypeSelectorComponent implements ControlValueAccessor {\r\n\r\n // reactive forms functions\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n @Input() values: Compliance.LeaseTypeModel[] = [];\r\n @Input() isOverridden: boolean = false;\r\n\r\n @Output() changed = new EventEmitter();\r\n\r\n value: string;\r\n disabled: boolean;\r\n filter: string = '';\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState(isDisabled: boolean): void {\r\n this.disabled = isDisabled;\r\n }\r\n\r\n writeValue(leaseType: string): void {\r\n this.value = leaseType;\r\n }\r\n\r\n select(value: string): void {\r\n this.value = value;\r\n this.changed.emit(value);\r\n }\r\n}\r\n","import { ICellEditorAngularComp } from 'ag-grid-angular';\r\nimport { ICellEditorParams } from 'ag-grid-community';\r\nimport { Component, ViewChild } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { LeaseTypeSelectorComponent } from \"../Selectors/Lease-Type-Selector/leaseTypeSelector.component\";\r\n\r\nexport interface EntityImportEditorLeaseTypeSelectorCellEditorParams extends ICellEditorParams {\r\n getLeaseTypes(row: Compliance.ImportGridRowGridModel): Compliance.LeaseTypeModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-editor-lease-type-selector',\r\n template: `\r\n `\r\n})\r\nexport class EntityImportEditorLeaseTypeSelectorCellEditorComponent implements ICellEditorAngularComp{\r\n gridRow: Compliance.ImportGridRowGridModel;\r\n\r\n focusIn(): void {\r\n }\r\n\r\n focusOut(): void {\r\n }\r\n\r\n getValue(): any {\r\n return this.leaseType.value;\r\n }\r\n\r\n isCancelAfterEnd(): boolean {\r\n if (this.leaseTypeSelector.value === ''){\r\n this._params.node.setDataValue(this._params.column.getColId(), null);\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n isCancelBeforeStart(): boolean {\r\n return false;\r\n }\r\n\r\n isPopup(): boolean {\r\n return false;\r\n }\r\n\r\n leaseType: UntypedFormControl = new UntypedFormControl();\r\n values: Compliance.LeaseTypeModel[];\r\n\r\n @ViewChild(\"leaseTypeSelector\", { static: true }) leaseTypeSelector: LeaseTypeSelectorComponent;\r\n\r\n private _params: EntityImportEditorLeaseTypeSelectorCellEditorParams;\r\n\r\n async agInit(params: EntityImportEditorLeaseTypeSelectorCellEditorParams): Promise {\r\n this.gridRow = params.data as Compliance.ImportGridRowGridModel;\r\n\r\n this._params = params;\r\n this.leaseType.setValue(params.value);\r\n this.values = await params.getLeaseTypes(this.gridRow);\r\n }\r\n\r\n onChanged(value: string) {\r\n if (!value) {\r\n this.leaseType.setValue(value);\r\n return;\r\n }\r\n if (this.leaseType.value !== value) {\r\n this.leaseType.setValue(value);\r\n this._params.node.setDataValue(this._params.column.getColId(), value);\r\n }\r\n }\r\n}\r\n","import { ICellEditorAngularComp } from 'ag-grid-angular';\r\nimport { ICellEditorParams } from 'ag-grid-community';\r\nimport { Component, ViewChild } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { AssessmentClassSelectorComponent } from \"../Selectors/AssessmentClass-Selector/assessmentClassSelector.component\";\r\n\r\nexport interface EntityImportEditorAssessmentClassSelectorCellEditorParams extends ICellEditorParams {\r\n getAssessmentClasses(rowIndex: number): string[];\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-editor-assessment-class-selector',\r\n template: `\r\n `\r\n})\r\nexport class EntityImportEditorAssessmentClassSelectorCellEditorComponent implements ICellEditorAngularComp{\r\n gridRow: Compliance.ImportGridRowGridModel;\r\n\r\n focusIn(): void {\r\n }\r\n\r\n focusOut(): void {\r\n }\r\n\r\n getValue(): any {\r\n return this.assessmentClass.value;\r\n }\r\n\r\n isCancelAfterEnd(): boolean {\r\n if (this.assessmentClassSelector.value === ''){\r\n this._params.node.setDataValue(this._params.column.getColId(), null);\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n isCancelBeforeStart(): boolean {\r\n return false;\r\n }\r\n\r\n isPopup(): boolean {\r\n return false;\r\n }\r\n\r\n assessmentClass: UntypedFormControl = new UntypedFormControl();\r\n values: string[];\r\n\r\n @ViewChild(\"assessmentClassSelector\", { static: true }) assessmentClassSelector: AssessmentClassSelectorComponent;\r\n\r\n private _params: EntityImportEditorAssessmentClassSelectorCellEditorParams;\r\n\r\n async agInit(params: EntityImportEditorAssessmentClassSelectorCellEditorParams): Promise {\r\n this.gridRow = params.data as Compliance.ImportGridRowGridModel;\r\n\r\n this._params = params;\r\n this.assessmentClass.setValue(params.value);\r\n this.values = await params.getAssessmentClasses(this.gridRow.rowIndex);\r\n }\r\n\r\n onChanged(value: string) {\r\n if (this.assessmentClass.value !== value) {\r\n this.assessmentClass.setValue(value);\r\n this._params.node.setDataValue(this._params.column.getColId(), value);\r\n }\r\n }\r\n}\r\n","import { ICellEditorAngularComp } from 'ag-grid-angular';\r\nimport { ICellEditorParams } from 'ag-grid-community';\r\nimport { Component, ViewChild } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { ExtendedGLAccountModel } from '../../../../../Asset/Asset-Details/Asset-Info/extendedGLAccountModel';\r\nimport { HigherOrderFn, Predicate, TypeaheadSelectorComponent } from '../Selectors/Typeahead-Selector/typeaheadSelector.component';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../../../../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe';\r\n\r\nexport interface EntityImportEditorGLAccountSelectorCellEditorParams extends ICellEditorParams {\r\n getGLAccounts(rowIndex: number): Compliance.GLAccountModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-editor-glaccount-selector',\r\n template: `\r\n `\r\n})\r\nexport class EntityImportEditorGLAccountSelectorCellEditorComponent implements ICellEditorAngularComp {\r\n constructor(private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe) { }\r\n\r\n @ViewChild(\"typeaheadSelector\", { static: true }) typeaheadSelector: TypeaheadSelectorComponent;\r\n\r\n gridRow: Compliance.ImportGridRowGridModel;\r\n glAccount: UntypedFormControl = new UntypedFormControl({ value: null, disabled: true });\r\n values: ExtendedGLAccountModel[];\r\n originalValue: string;\r\n typeaheadFilter: HigherOrderFn = (filter: string) => (x: ExtendedGLAccountModel) => filter === '' ||\r\n x.displayName.toLowerCase().includes(filter.toLowerCase());\r\n\r\n private _params: EntityImportEditorGLAccountSelectorCellEditorParams;\r\n\r\n focusIn(): void {\r\n }\r\n\r\n focusOut(): void {\r\n }\r\n\r\n getValue(): any {\r\n return this.glAccount.value;\r\n }\r\n\r\n isCancelAfterEnd(): boolean {\r\n if (this.typeaheadSelector.value && !this.typeaheadSelector.filter) {\r\n this._params.node.setDataValue(this._params.column.getColId(), '');\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n isCancelBeforeStart(): boolean {\r\n return false;\r\n }\r\n\r\n isPopup(): boolean {\r\n return false;\r\n }\r\n\r\n async agInit(params: EntityImportEditorGLAccountSelectorCellEditorParams): Promise {\r\n this.gridRow = params.data as Compliance.ImportGridRowGridModel;\r\n\r\n this._params = params;\r\n\r\n if (this._params.data && this._params.data.originalValues) {\r\n this.originalValue = this._params.data.originalValues[this._params.colDef.field];\r\n }\r\n\r\n this.glAccount.setValue(params.value);\r\n\r\n const glAccounts = await params.getGLAccounts(this.gridRow.rowIndex);\r\n this.values = glAccounts.map(x => new ExtendedGLAccountModel(x, this._keyValueDisplayPipe));\r\n\r\n if (this.values && this.values.length) {\r\n this.glAccount.enable();\r\n }\r\n }\r\n\r\n onChanged(value?: string) {\r\n if (this.glAccount.value !== value) {\r\n this.glAccount.setValue(value);\r\n this._params.node.setDataValue(this._params.column.getColId(), value);\r\n }\r\n }\r\n}\r\n","import { ICellEditorAngularComp } from \"ag-grid-angular\";\r\nimport { ICellEditorParams } from \"ag-grid-community\";\r\nimport { Component, ViewChild } from \"@angular/core\";\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { TypeaheadSelectorComponent, HigherOrderFn, Predicate } from '../Selectors/Typeahead-Selector/typeaheadSelector.component';\r\n\r\nexport interface EntityImportEditorTaxingDistrictSelectorCellEditorParams extends ICellEditorParams {\r\n getTaxingDistricts(rowIndex: number): Core.TaxingDistrictModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-editor-taxing-district-selector',\r\n template: ``\r\n})\r\nexport class EntityImportEditorTaxingSelectorCellEditorComponent implements ICellEditorAngularComp {\r\n @ViewChild(\"typeaheadSelector\", { static: true }) typeaheadSelector: TypeaheadSelectorComponent;\r\n\r\n gridRow: Compliance.ImportGridRowGridModel;\r\n taxingDistrictValue: UntypedFormControl = new UntypedFormControl({ value: null, disabled: true });\r\n taxingDistricts: Core.TaxingDistrictModel[];\r\n originalValue: string;\r\n typeaheadFilter: HigherOrderFn = (filter: string) => (x: Core.TaxingDistrictModel) => this._isMatch(x, filter);\r\n\r\n private _params: EntityImportEditorTaxingDistrictSelectorCellEditorParams;\r\n\r\n focusIn(): void {\r\n }\r\n\r\n focusOut(): void {\r\n }\r\n\r\n getValue(): any {\r\n return this._formatCode(this.taxingDistrictValue.value);\r\n }\r\n\r\n isCancelAfterEnd(): boolean {\r\n if (this.typeaheadSelector.value && !this.typeaheadSelector.filter) {\r\n this._params.node.setDataValue(this._params.column.getColId(), '');\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n isCancelBeforeStart(): boolean {\r\n return false;\r\n }\r\n\r\n isPopup(): boolean {\r\n return false;\r\n }\r\n\r\n async agInit(params: EntityImportEditorTaxingDistrictSelectorCellEditorParams): Promise {\r\n this.gridRow = params.data as Compliance.ImportGridRowGridModel;\r\n\r\n this._params = params;\r\n\r\n if (this._params.data && this._params.data.originalValues) {\r\n this.originalValue = this._params.data.originalValues[this._params.colDef.field];\r\n }\r\n\r\n this.taxingDistrictValue.setValue(params.value);\r\n\r\n this.taxingDistricts = await params.getTaxingDistricts(this.gridRow.rowIndex);\r\n\r\n if (this.taxingDistricts && this.taxingDistricts.length) {\r\n this.taxingDistrictValue.enable();\r\n }\r\n }\r\n\r\n onTaxingDistrictChanged(value?: string): void {\r\n if (this.taxingDistrictValue.value !== value) {\r\n const formatted = this._formatCode(value);\r\n this.taxingDistrictValue.setValue(formatted);\r\n this._params.node.setDataValue(this._params.column.getColId(), formatted);\r\n }\r\n }\r\n\r\n private _formatCode(value: string): string {\r\n if (value === null) {\r\n return null;\r\n }\r\n\r\n let code = '';\r\n\r\n const taxingDistrict = this.taxingDistricts.find(i => this._isMatch(i, value));\r\n\r\n if (taxingDistrict) {\r\n const allMatches = this.taxingDistricts.filter(i => this._isMatch(i, taxingDistrict.code));\r\n code = taxingDistrict.code;\r\n\r\n if (allMatches.length > 1) {\r\n code = `${taxingDistrict.code}|${taxingDistrict.townshipCode}`;\r\n }\r\n } else {\r\n code = this._params.value;\r\n }\r\n\r\n return code;\r\n }\r\n\r\n private _isMatch(taxingDistrict: Core.TaxingDistrictModel, selectedValue: string): boolean {\r\n const value = (selectedValue || '').toLocaleLowerCase();\r\n const localTaxingDistrict = {\r\n taxingDistrictId: taxingDistrict.taxingDistrictId,\r\n code: taxingDistrict.code.toLocaleLowerCase(),\r\n name: taxingDistrict.name.toLocaleLowerCase(),\r\n townshipCode: taxingDistrict.townshipCode.toLocaleLowerCase(),\r\n townshipName: taxingDistrict.townshipName.toLocaleLowerCase(),\r\n } as Core.TaxingDistrictModel;\r\n\r\n let result = value === '';\r\n\r\n if (!result) {\r\n const items = value.split('|');\r\n result = (localTaxingDistrict.name.indexOf(items[0]) >= 0 || localTaxingDistrict.code.indexOf(items[0]) >= 0) &&\r\n (items.length === 1 || localTaxingDistrict.townshipName.indexOf(items[1]) >= 0 || localTaxingDistrict.townshipCode.indexOf(items[1]) >= 0);\r\n }\r\n\r\n return result;\r\n }\r\n}\r\n","import {\r\n Component,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n SimpleChange,\r\n SimpleChanges\r\n} from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\n\r\n@Component({\r\n templateUrl: './oneTimeVRecurringSelector.component.html',\r\n selector: 'onetime-v-recurring-selector',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: OneTimeVRecurringSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class OneTimeVRecurringSelectorComponent implements ControlValueAccessor {\r\n\r\n // reactive forms functions\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n @Input() isOverridden: boolean = false;\r\n\r\n @Output() changed = new EventEmitter();\r\n\r\n value: string;\r\n disabled: boolean;\r\n filter: string = '';\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState(isDisabled: boolean): void {\r\n this.disabled = isDisabled;\r\n }\r\n\r\n writeValue(value: string): void {\r\n this.value = value;\r\n }\r\n\r\n select(value: string): void {\r\n this.value = value;\r\n this.changed.emit(value);\r\n }\r\n}\r\n","
\r\n \r\n
\r\n","import { ICellEditorAngularComp } from 'ag-grid-angular';\r\nimport { ICellEditorParams } from 'ag-grid-community';\r\nimport { Component, ViewChild } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { LeaseTypeSelectorComponent } from \"../Selectors/Lease-Type-Selector/leaseTypeSelector.component\";\r\n\r\n@Component({\r\n selector: 'entity-import-editor-onetime-v-recurring-selector',\r\n template: `\r\n `\r\n})\r\nexport class EntityImportEditorOneTimeVRecurringSelectorRendererCellEditorComponent implements ICellEditorAngularComp{\r\n gridRow: Compliance.ImportGridRowGridModel;\r\n\r\n focusIn(): void {\r\n }\r\n\r\n focusOut(): void {\r\n }\r\n\r\n getValue(): any {\r\n return this.selector.value;\r\n }\r\n\r\n isCancelAfterEnd(): boolean {\r\n if (this.selectorComponent.value === ''){\r\n this._params.node.setDataValue(this._params.column.getColId(), null);\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n isCancelBeforeStart(): boolean {\r\n return false;\r\n }\r\n\r\n isPopup(): boolean {\r\n return false;\r\n }\r\n\r\n selector: UntypedFormControl = new UntypedFormControl();\r\n values: Compliance.LeaseTypeModel[];\r\n\r\n @ViewChild(\"selectorComponent\", { static: true }) selectorComponent: LeaseTypeSelectorComponent;\r\n\r\n private _params: ICellEditorParams;\r\n\r\n async agInit(params: ICellEditorParams): Promise {\r\n this.gridRow = params.data as Compliance.ImportGridRowGridModel;\r\n\r\n this._params = params;\r\n this.selector.setValue(params.value);\r\n }\r\n\r\n onChanged(value: string) {\r\n if (!value) {\r\n this.selector.setValue(value);\r\n return;\r\n }\r\n if (this.selector.value !== value) {\r\n this.selector.setValue(value);\r\n this._params.node.setDataValue(this._params.column.getColId(), value);\r\n }\r\n }\r\n}\r\n","import {ICellEditorAngularComp} from \"ag-grid-angular\";\r\nimport {ICellEditorParams} from \"ag-grid-community\";\r\nimport {Component, ViewChild} from \"@angular/core\";\r\nimport { IncomeStatementCategorySelectorComponent } from '../../../../../../Valuation/Income-Statement/Income-Statement-Category-Selector/incomeStatementCategorySelector.component';\r\n\r\nexport interface EntityImportEditorIncomeStatementCategorySelectorCellEditorParams extends ICellEditorParams {\r\n getGlAccountTypeId(params: EntityImportEditorIncomeStatementCategorySelectorCellEditorParams): Promise;\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-editor-income-statement-category-selector',\r\n template: `\r\n \r\n \r\n `\r\n})\r\nexport class EntityImportEditorIncomeStatementCategorySelectorCellEditorComponent implements ICellEditorAngularComp {\r\n focusIn(): void {\r\n }\r\n\r\n focusOut(): void {\r\n }\r\n\r\n getValue(): any {\r\n return this.incomeStatementCategoryName;\r\n }\r\n\r\n isCancelAfterEnd(): boolean {\r\n if (this.incomeStatementCategorySelector.incomeStatementCategoryName && !this.incomeStatementCategorySelector.incomeStatementCategoryFilter){\r\n this._params.node.setDataValue(this._params.column.getColId(), '');\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n isCancelBeforeStart(): boolean {\r\n return false;\r\n }\r\n\r\n isPopup(): boolean {\r\n return false;\r\n }\r\n\r\n incomeStatementCategoryName: string;\r\n glAccountTypeId: number;\r\n\r\n @ViewChild(\"incomeStatementCategorySelector\") incomeStatementCategorySelector: IncomeStatementCategorySelectorComponent;\r\n\r\n private _params: EntityImportEditorIncomeStatementCategorySelectorCellEditorParams;\r\n\r\n async agInit(params: EntityImportEditorIncomeStatementCategorySelectorCellEditorParams): Promise {\r\n this._params = params;\r\n this.incomeStatementCategoryName = params.value;\r\n this.glAccountTypeId = await params.getGlAccountTypeId(params);\r\n }\r\n\r\n onIncomeStatementCategoryChanged(incomeStatementCategory: Core.IncomeStatementCategoryModel) {\r\n this.incomeStatementCategoryName = incomeStatementCategory ? incomeStatementCategory.name : null;\r\n this._params.node.setDataValue(this._params.column.getColId(), incomeStatementCategory ? incomeStatementCategory.name : null);\r\n }\r\n}\r\n","import { ICellEditorAngularComp } from 'ag-grid-angular';\r\nimport { ICellEditorParams } from 'ag-grid-community';\r\nimport { Component, ViewChild } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { TypeaheadSelectorComponent, HigherOrderFn, Predicate } from '../Selectors/Typeahead-Selector/typeaheadSelector.component';\r\n\r\nexport interface EntityImportEditorGLAccountTypeSelectorCellEditorParams extends ICellEditorParams {\r\n getGLAccountTypes(row: Compliance.ImportGridRowGridModel): Compliance.GLAccountTypeModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-editor-gl-account-type-selector',\r\n template: `\r\n `\r\n})\r\nexport class EntityImportEditorGLAccountTypeSelectorCellEditorComponent implements ICellEditorAngularComp {\r\n @ViewChild(\"typeaheadSelector\", { static: true }) typeaheadSelector: TypeaheadSelectorComponent;\r\n\r\n gridRow: Compliance.ImportGridRowGridModel;\r\n glAccountType: UntypedFormControl = new UntypedFormControl({ value: null, disabled: true });\r\n values: Compliance.GLAccountTypeModel[];\r\n originalValue: string;\r\n typeaheadFilter: HigherOrderFn = (filter: string) => (x: Compliance.GLAccountTypeModel) =>\r\n x.name.toLowerCase().includes(filter.toLowerCase());\r\n\r\n private _params: EntityImportEditorGLAccountTypeSelectorCellEditorParams;\r\n\r\n focusIn(): void {\r\n }\r\n\r\n focusOut(): void {\r\n }\r\n\r\n getValue(): any {\r\n return this.glAccountType.value;\r\n }\r\n\r\n isCancelAfterEnd(): boolean {\r\n if (this.typeaheadSelector.value && !this.typeaheadSelector.filter) {\r\n this._params.node.setDataValue(this._params.column.getColId(), '');\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n isCancelBeforeStart(): boolean {\r\n return false;\r\n }\r\n\r\n isPopup(): boolean {\r\n return false;\r\n }\r\n\r\n async agInit(params: EntityImportEditorGLAccountTypeSelectorCellEditorParams): Promise {\r\n this.gridRow = params.data as Compliance.ImportGridRowGridModel;\r\n\r\n this._params = params;\r\n\r\n if (this._params.data && this._params.data.originalValues) {\r\n this.originalValue = this._params.data.originalValues[this._params.colDef.field];\r\n }\r\n\r\n this.glAccountType.setValue(params.value);\r\n\r\n this.values = await params.getGLAccountTypes(this.gridRow);\r\n\r\n if (this.values && this.values.length) {\r\n this.glAccountType.enable();\r\n }\r\n }\r\n\r\n onChanged(value?: string) {\r\n if (this.glAccountType.value !== value) {\r\n this.glAccountType.setValue(value);\r\n this._params.node.setDataValue(this._params.column.getColId(), value);\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom, Observable, Subject, Subscription } from 'rxjs';\r\nimport { LongRunningProcessRepository } from '../Repositories';\r\nimport { WebsocketListenerService } from '../websocketListener.service';\r\n\r\n@Injectable()\r\nexport class LongRunningProcessService {\r\n constructor(\r\n private readonly _longRunningProcessRepository: LongRunningProcessRepository,\r\n private readonly _websocketListenerService: WebsocketListenerService) {\r\n }\r\n\r\n private _longRunningProcessQuiescedStatusChangeSub: Subscription;\r\n private _longRunningProcessStatusChangeSub: Subscription;\r\n\r\n private _startSubject: Subject = new Subject();\r\n private _refreshSubject: Subject = new Subject();\r\n private _longRunningProcessQuiescedStatusSubject = new Subject();\r\n private _longRunningProcessStatusSubject = new Subject();\r\n\r\n private _autoRefresh: boolean = false;\r\n private _quiescedStatus: Compliance.LongRunningProcessQuiescedStatusModel;\r\n private _queueTypes: Compliance.LongRunningProcessQueueTypeModel[];\r\n private _controlMessageTypes: Compliance.LongRunningProcessControlMessageTypeModel[];\r\n private _serviceHosts: string[];\r\n\r\n get quiescedStatus(): Compliance.LongRunningProcessQuiescedStatusModel { return this._quiescedStatus; }\r\n get queueTypes(): Compliance.LongRunningProcessQueueTypeModel[] { return this._queueTypes; }\r\n get controlMessageTypes(): Compliance.LongRunningProcessControlMessageTypeModel[] { return this._controlMessageTypes; }\r\n get serviceHosts(): string[] { return this._serviceHosts; }\r\n get autoRefresh(): boolean { return this._autoRefresh; }\r\n\r\n get start$(): Observable { return this._startSubject.asObservable(); }\r\n get refresh$(): Observable { return this._refreshSubject.asObservable(); }\r\n get longRunningProcessStatusChange$(): Observable { return this._longRunningProcessStatusSubject.asObservable(); }\r\n get longRunningProcessQuiescedStatusChange$(): Observable { return this._longRunningProcessQuiescedStatusSubject.asObservable(); }\r\n\r\n async start(): Promise {\r\n await this._loadQuiescedStatus();\r\n await this._loadQueueTypes();\r\n await this._loadControlMessageTypes();\r\n await this._loadServiceHosts();\r\n\r\n this._longRunningProcessStatusChangeSub = this._websocketListenerService.longRunningProcessStatusChange$.subscribe(\r\n (x) => {\r\n this._longRunningProcessStatusSubject.next(x);\r\n });\r\n\r\n this._longRunningProcessQuiescedStatusChangeSub = this._websocketListenerService.longRunningProcessQuiescedStatusChange$.subscribe(\r\n async (x) => {\r\n this._longRunningProcessQuiescedStatusSubject.next(x);\r\n\r\n await this._loadQuiescedStatus();\r\n });\r\n\r\n this._startSubject.next();\r\n }\r\n\r\n stop(): void {\r\n this._longRunningProcessQuiescedStatusChangeSub && this._longRunningProcessQuiescedStatusChangeSub.unsubscribe();\r\n this._longRunningProcessStatusChangeSub && this._longRunningProcessStatusChangeSub.unsubscribe();\r\n\r\n this._quiescedStatus = null;\r\n this._queueTypes = null;\r\n }\r\n\r\n async refresh(): Promise {\r\n await this._loadQuiescedStatus();\r\n this._refreshSubject.next();\r\n }\r\n\r\n async updateQuiescedStatus(model: Compliance.LongRunningProcessQuiescedStatusModel): Promise {\r\n this._quiescedStatus = await lastValueFrom(this._longRunningProcessRepository.updateQuiescedStatus(model));\r\n }\r\n\r\n setAutoRefresh(autoRefresh: boolean): void {\r\n this._autoRefresh = autoRefresh;\r\n if (autoRefresh) {\r\n this._refreshSubject.next();\r\n }\r\n }\r\n\r\n async test(parameters: Compliance.SyntheticLongRunningProcessParameters): Promise {\r\n await lastValueFrom(this._longRunningProcessRepository.startSyntheticLongRunningProcess(parameters));\r\n this._refreshSubject.next();\r\n }\r\n\r\n async controlMessage(parameters: Compliance.ControlMessageLongRunningProcessParameters): Promise {\r\n await lastValueFrom(this._longRunningProcessRepository.sendControlMessage(parameters));\r\n this._refreshSubject.next();\r\n }\r\n\r\n async get(longRunningProcessId: number): Promise {\r\n return await lastValueFrom(this._longRunningProcessRepository.get(longRunningProcessId));\r\n }\r\n\r\n private async _loadQuiescedStatus(): Promise {\r\n this._quiescedStatus = await lastValueFrom(this._longRunningProcessRepository.getQuiescedStatus());\r\n }\r\n\r\n private async _loadQueueTypes(): Promise {\r\n this._queueTypes = await lastValueFrom(this._longRunningProcessRepository.getQueueTypes());\r\n }\r\n\r\n private async _loadControlMessageTypes(): Promise {\r\n this._controlMessageTypes = await lastValueFrom(this._longRunningProcessRepository.getControlMessageTypes());\r\n }\r\n\r\n private async _loadServiceHosts(): Promise {\r\n this._serviceHosts = await lastValueFrom(this._longRunningProcessRepository.getServiceHosts());\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Import Data\r\n \r\n

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
View:
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
Review data and make any necessary changes below. Rows in gray represent data that has been successfully transferred.
\r\n
\r\n\r\n\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport {\r\n CellValueChangedEvent,\r\n ColDef,\r\n Column,\r\n ColumnApi,\r\n GridApi,\r\n GridOptions,\r\n GridReadyEvent,\r\n IGetRowsParams\r\n} from 'ag-grid-community';\r\nimport { BehaviorSubject, lastValueFrom, Subject, Subscription } from 'rxjs';\r\nimport { EntityImportEditorAgGridDataSource, EntityImportEditorDataSourceParams } from './agGridDataSource';\r\nimport { EntityImportProcessService } from '../../importProcess.service';\r\nimport { AssetClassificationRepository, AssetRepository, EntityImportRepository } from '../../../../Repositories';\r\nimport {\r\n EntityImportEditorEstimatedActionHeaderRendererComponent\r\n} from './agGridEstimatedActionHeaderRenderer.component';\r\nimport {\r\n EntityImportEditorEstimatedActionFilterRendererComponent\r\n} from './agGridEstimatedActionFilterRenderer.component';\r\nimport { EntityImportEditorEstimatedActionCellRendererComponent } from './agGridEstimatedActionCellRenderer.component';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../../../../Busy-Indicator';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder, AgGridTextCellEditor } from '../../../../AgGrid';\r\nimport {\r\n AgGridMultiSelectCellRendererParams,\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../../../AgGrid/MultiSelectTracker';\r\nimport {\r\n EntityImportEditorAssetClassSelectorCellEditorComponent,\r\n EntityImportEditorAssetClassSelectorCellEditorParams\r\n} from './SelectorRenderers/agGridAssetClassSelectorRenderer.component';\r\nimport { BsModalRef, BsModalService } from 'ngx-bootstrap/modal';\r\nimport { FieldInfo, ImportBulkUpdateComponent } from './Import-Bulk-Update/importBulkUpdate.component';\r\nimport { WeissmanModalService } from '../../../../WeissmanModalService';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxOptions,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport {\r\n EntityImportEditorAssessorSelectorCellEditorComponent,\r\n EntityImportEditorAssessorSelectorCellEditorParams\r\n} from './SelectorRenderers/agGridAssessorSelectorRenderer.component';\r\nimport {\r\n EntityImportEditorAttachmentTypeSelectorCellEditorComponent,\r\n EntityImportEditorAttachmentTypeSelectorCellEditorParams\r\n} from './SelectorRenderers/agGridAttachmentTypeSelectorRenderer.component';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport {\r\n EntityImportEditorLeaseTypeSelectorCellEditorComponent,\r\n EntityImportEditorLeaseTypeSelectorCellEditorParams\r\n} from './SelectorRenderers/agGridLeaseTypeSelectorRenderer.component';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../../../AgGrid/ToolPanel/models';\r\nimport {\r\n EntityImportEditorAssessmentClassSelectorCellEditorComponent,\r\n EntityImportEditorAssessmentClassSelectorCellEditorParams\r\n} from \"./SelectorRenderers/agGridAssessmentClassSelectorRenderer.component\";\r\nimport {\r\n EntityImportEditorGLAccountSelectorCellEditorComponent,\r\n EntityImportEditorGLAccountSelectorCellEditorParams\r\n} from \"./SelectorRenderers/agGridGLAccountSelectorRenderer.component\";\r\nimport { DecimalPipe } from \"@angular/common\";\r\nimport {\r\n EntityImportEditorTaxingDistrictSelectorCellEditorParams,\r\n EntityImportEditorTaxingSelectorCellEditorComponent\r\n} from \"./SelectorRenderers/agGridTaxingDistrictSelectorRenderer.component\";\r\nimport {\r\n EntityImportEditorOneTimeVRecurringSelectorRendererCellEditorComponent\r\n} from './SelectorRenderers/agGridOneTimeVRecurringSelectorRenderer.component';\r\nimport {\r\n EntityImportEditorIncomeStatementCategorySelectorCellEditorComponent,\r\n EntityImportEditorIncomeStatementCategorySelectorCellEditorParams\r\n} from './SelectorRenderers/agGridIncomeStatementCategorySelectorRenderer.component';\r\nimport {\r\n EntityImportEditorGLAccountTypeSelectorCellEditorComponent,\r\n EntityImportEditorGLAccountTypeSelectorCellEditorParams\r\n} from './SelectorRenderers/agGridGLAccountTypeSelectorRenderer.component';\r\nimport { UtilitiesService } from 'src/app/UI-Lib/Utilities/Utilities.Service.upgrade';\r\nimport { LongRunningProcessService } from '../../../../Long-Running-Process/longRunningProcess.service';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport { EntityImportColumnMappingStepService } from '../../Column-Mapping-Step/columnMappingStep.service';\r\n\r\nconst KEY_ENTER = 13;\r\n\r\nexport interface ImportGridRow extends ColDef {\r\n ws: Compliance.EntityImportEditingColDefMetadata\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-editor',\r\n templateUrl: './editor.component.html'\r\n})\r\nexport class EntityImportEditorComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _entityImportRepository: EntityImportRepository,\r\n private readonly _entityImportProcessService: EntityImportProcessService,\r\n private readonly _assetClassificationRepository: AssetClassificationRepository,\r\n private readonly _bsModalService: BsModalService,\r\n private readonly _wsModalService: WeissmanModalService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _assetRepository: AssetRepository,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _longRunningProcessService: LongRunningProcessService,\r\n private readonly _columnMappingStepService: EntityImportColumnMappingStepService\r\n ) {}\r\n\r\n private _gridApi: GridApi;\r\n private _gridColumnApi: ColumnApi;\r\n private _gridDataSource: EntityImportEditorAgGridDataSource;\r\n private _validationErrors: Compliance.ImportFileValidationErrorModel[];\r\n private _errorFilterSub: Subscription;\r\n private _evaluatingSub: Subscription;\r\n private _validationSummarySub: Subscription;\r\n private _transferredSub: Subscription;\r\n private _importFileModel: Compliance.ImportFileModel;\r\n private _gridMultiSelectSub: Subscription;\r\n private _assetClassifications: Compliance.AssetClassificationModel[];\r\n private _assessors: Compliance.ImportAssessorModel[];\r\n private _sortingColumns: Compliance.NameValuePair[] = [{name: 'rowIndex_1', value: '-1'} as Compliance.NameValuePair];\r\n private _selectionSupportBulkOperation: boolean = false;\r\n private _selectionSupportDeleteOperation: boolean = false;\r\n private _defaultSortModel = [\r\n {\r\n colId: 'rowIndex_1',\r\n sort: 'asc'\r\n }\r\n ];\r\n private _leaseTypes: Compliance.LeaseTypeModel[];\r\n private _isImportCompleted: boolean = false;\r\n private _showTotals: boolean = false;\r\n private _fieldNames: string[] = [];\r\n private _busyRef: BusyIndicatorRef;\r\n private _destroy$: Subject = new Subject();\r\n private _destroyIndicator$: Subject = new Subject();\r\n private _taxingDistricts: Core.TaxingDistrictModel[];\r\n private _glAccountTypes: Compliance.GLAccountTypeModel[];\r\n private _selectedRowIndex: number = -1;\r\n private _selectedRow: Compliance.ImportGridRowGridModel;\r\n private _updateCellParams: CellValueChangedEvent;\r\n private _notValidatedUpdates: Compliance.ImportGridNotValidatedUpdateModel[] = [];\r\n\r\n @Input() set importFileModel(importFile: Compliance.ImportFileModel) {\r\n this._importFileModel = importFile;\r\n this.totalRows = importFile.totalRows;\r\n this._isImportCompleted = this._importFileModel.processStatus === Compliance.ImportFileProcessStatusEnum.Completed;\r\n this._showTotals = this._importFileModel.importContentType.supportsTotals;\r\n }\r\n @Input() showTransferredRows: boolean = false;\r\n @Input() busyRefId: string;\r\n @Input() selectedRowsInfo$: BehaviorSubject;\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n totalRows: number = 0;\r\n filteredRows: number = 0;\r\n totalValidCount: number = 0;\r\n hasError: boolean;\r\n gridId: System.Guid = 'F1D496E2-BB3B-4984-995D-0BA54F9C88CA';\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n isBulkDeleteVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n importGridTotalsRow: any;\r\n importGridSelectedTotalsRow: any;\r\n selectedTotalsTimestamp: number;\r\n selectedTotalsLoading: boolean = true;\r\n showValidRowsOnly: boolean;\r\n showDynamicFieldConfiguration: boolean;\r\n\r\n get importFileModel(): Compliance.ImportFileModel {\r\n return this._importFileModel;\r\n }\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'row-transferred': params => !!(params.data && (params.data as Compliance.ImportGridRowGridModel).actualAction),\r\n 'ag-row-selected': params => {\r\n const rowModel = params.data as Compliance.ImportGridRowGridModel;\r\n return rowModel &&\r\n this.gridTracker.isRowSelected(rowModel.rowIndex) &&\r\n !this._isRowSelectionDisabled(rowModel.rowIndex, rowModel) &&\r\n !this._isRowSelectionHidden(rowModel.rowIndex, rowModel);\r\n }\r\n },\r\n suppressFieldDotNotation: true,\r\n suppressCellSelection: true\r\n })\r\n .withContext(this)\r\n .withInfiniteScroll()\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .withoutCellEditingStoppedOnGridLostFocus()\r\n .build();\r\n\r\n gridColumnFilters = {\r\n allColumns: 'All Columns',\r\n mappedColumns: 'Mapped Columns',\r\n };\r\n\r\n selectedGridColumnFilter = this.gridColumnFilters.mappedColumns;\r\n\r\n async ngOnInit(): Promise {\r\n this._evaluatingSub = this._entityImportProcessService.evaluating$.subscribe((promise: Promise) => {\r\n promise.then(() => {\r\n this._refreshDataSource(false);\r\n });\r\n });\r\n\r\n this._validationSummarySub = this._entityImportProcessService.validationSummaryChanged$.subscribe((validationErrors: Compliance.ImportFileValidationErrorModel[]) => {\r\n this.hasError = _.some(validationErrors, (x) => { return !x.isWarning; });\r\n\r\n if (this.gridTracker && (this.gridTracker.getSelectedRowsModel().selectAllRows || this.gridTracker.getSelectedRowsModel().selectedRows)){\r\n this._refreshDataSource(false);\r\n }\r\n });\r\n\r\n this._transferredSub = this._entityImportProcessService.transferCompletedEventEmitter.subscribe(() => {\r\n this._refreshDataSource();\r\n });\r\n\r\n this.showTransferredRows = this.importFileModel.totalRows === this.importFileModel.transferredRows ||\r\n this._isImportCompleted;\r\n\r\n this.selectedRowsInfo$.pipe(takeUntil(this._destroy$)).subscribe(data => {\r\n const hasDataForBulkOperation = !this._isImportCompleted && data && (!!data.invalidRowsCount || !!data.validRowsCount);\r\n\r\n this._selectionSupportDeleteOperation = hasDataForBulkOperation;\r\n\r\n if (hasDataForBulkOperation) {\r\n const bulkUpdateFields = this._getBulkUpdateFields();\r\n this._selectionSupportBulkOperation = bulkUpdateFields.length !== 0;\r\n }\r\n\r\n this.isBulkDeleteVisible$.next(this._selectionSupportDeleteOperation);\r\n this.isBulkUpdateVisible$.next(this._selectionSupportBulkOperation);\r\n });\r\n\r\n this._entityImportProcessService.notValidatedUpdates$.pipe(takeUntil(this._destroy$)).subscribe(x => {\r\n if (x === 0) {\r\n this._notValidatedUpdates = [];\r\n this._gridApi.redrawRows();\r\n }\r\n });\r\n\r\n this.showDynamicFieldConfiguration = this.importFileModel.importContentType.supportsDynamicFieldBehaviorConfiguration;\r\n }\r\n\r\n /**\r\n * Modified version of gridTracker's method, easier to externalize change in behavior. In our case we have\r\n * to be aware of the total valid rows as well as the selection. We don't actually need to worry about there\r\n * being invalid rows selected, because they can never be selected, they are just impliedly selected via a\r\n * select all activity when no filter is set. In our version, instead of using the grid tracker's version of\r\n * the total rows count, we use our own external count updated when results are fetched with no column filter\r\n */\r\n getSelectedRowsCount():number {\r\n if (!this.gridTracker) {\r\n return 0;\r\n }\r\n if (this.gridTracker.getSelectedRowsModel().selectAllRows) {\r\n return this.totalValidCount - this.gridTracker.getSelectedRowsModel().selectedRows.length;\r\n }\r\n return this.gridTracker.getSelectedRowsModel().selectedRows.length;\r\n\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._destroyIndicator$.next();\r\n this._destroyIndicator$.complete();\r\n this._errorFilterSub && this._errorFilterSub.unsubscribe();\r\n this._evaluatingSub.unsubscribe();\r\n this._validationSummarySub.unsubscribe();\r\n this._transferredSub.unsubscribe();\r\n this._gridMultiSelectSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n // get API objects and start setting up the AgGrid\r\n this._gridApi = event.api;\r\n this._gridColumnApi = event.columnApi;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n // setup AgGrid column for row selection\r\n const selectRowColumnDef: ImportGridRow = {\r\n headerName: '',\r\n field: 'rowIndex',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressMovable: true,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker,\r\n isCellRendererDisabledFn: this._isRowSelectionDisabled.bind(this),\r\n isCellRendererHiddenFn: this._isRowSelectionHidden.bind(this)\r\n } as AgGridMultiSelectCellRendererParams\r\n } as ImportGridRow;\r\n\r\n // setup AgGrid column for row action estimation\r\n const estimatedActionColumnDef: ImportGridRow = {\r\n field: 'estimatedAction',\r\n suppressMovable: true,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n filter: 'agTextColumnFilter',\r\n cellRendererFramework: EntityImportEditorEstimatedActionCellRendererComponent,\r\n headerComponentFramework: EntityImportEditorEstimatedActionHeaderRendererComponent,\r\n floatingFilterComponentFramework: EntityImportEditorEstimatedActionFilterRendererComponent,\r\n floatingFilterComponentParams: {\r\n filterValue: null,\r\n suppressFilterButton: true\r\n },\r\n width: AgGridColumns.rowNumberColumnWidth\r\n } as ImportGridRow;\r\n\r\n // setup AgGrid column for row #\r\n const rowIdColumnDef: ImportGridRow = {\r\n headerName: 'Row',\r\n field: 'rowIndex',\r\n width: AgGridColumns.rowNumberColumnWithSortingWidth,\r\n type: 'numericColumn',\r\n editable: false,\r\n suppressMovable: true,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n // custom data\r\n ws: null\r\n } as ImportGridRow;\r\n\r\n // setup AgGrid columns for import file columns\r\n const fileColumnDefList: ImportGridRow[] = _\r\n .chain(this._importFileModel.importFileHeaders)\r\n .map(ifh => {\r\n const assignedField = this._importFileModel.assignedFields.find(af => af.value === `${ifh.importFileHeaderId}` && !af.isStatic);\r\n const field = assignedField && this._importFileModel.importContentType.importFields.find(f => f.importFieldId === assignedField.importFieldId);\r\n const headerName = field ? field.displayName : ifh.name;\r\n const key = field ? field.displayName : ifh.index.toString();\r\n this._fieldNames.push(key);\r\n const colDef = {\r\n headerName: headerName,\r\n field: key,\r\n suppressMovable: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n // if it's not one of the mapped columns (not mapped to a field) than do not allow editing\r\n editable: (params) => {\r\n const gridRow = params.data as Compliance.ImportGridRowGridModel;\r\n return field && gridRow && !gridRow.actualAction && UtilitiesService.isNumeric(gridRow.rowIndex);\r\n },\r\n cellEditorFramework: AgGridTextCellEditor,\r\n cellEditorParams: {\r\n canReset: true,\r\n hasOverride: (params) => params.data && params.data.originalValues && (params.data.originalValues[params.colDef.field] !== params.data[params.colDef.field] || params.data.originalValues[params.colDef.field] != params.data[params.colDef.field])\r\n },\r\n singleClickEdit: true,\r\n // initialize as hidden, will be applying column filters after column definitions are set and that will take care of setting the visibility\r\n hide: true,\r\n cellClass: (params) => {\r\n let result = (params.data && params.data.validationStatus && params.data.validationStatus[params.colDef.field]) || '';\r\n if (params.data) {\r\n const ws = (params.colDef as ImportGridRow).ws;\r\n\r\n if (ws && ws.columnIndex &&\r\n this._notValidatedUpdates.some(x => x.columnIndex == ws.columnIndex &&\r\n x.rowIndex == params.data.rowIndex)) {\r\n result = 'ws-calculated';\r\n } else if (params.data.originalValues && params.data.originalValues[params.colDef.field] !== params.data[params.colDef.field]) {\r\n result += ' ws-override';\r\n }\r\n }\r\n return result;\r\n },\r\n onCellValueChanged: this.onAgCellValueChanged.bind(this),\r\n // custom metadata\r\n ws: {\r\n isStatic: false,\r\n fieldMappingId: (assignedField && assignedField.importFileSpecificationFieldId) || null,\r\n isMappedToRequiredFields: (field && field.isMappingRequired) || false,\r\n columnIndex: ifh.index\r\n } as Compliance.EntityImportEditingColDefMetadata\r\n } as ImportGridRow;\r\n\r\n if (field) {\r\n switch (field.uiCellRenderer) {\r\n case 'AssetClassSelector':\r\n colDef.cellEditorFramework = EntityImportEditorAssetClassSelectorCellEditorComponent;\r\n colDef.cellEditorParams = {getAssetClassifications: this._getAssetClassifications.bind(this)} as EntityImportEditorAssetClassSelectorCellEditorParams;\r\n colDef.suppressKeyboardEvent = (params) => {\r\n const keyCode = params.event.keyCode;\r\n return params.editing && (keyCode === KEY_ENTER);\r\n };\r\n break;\r\n case 'AssessorSelector':\r\n colDef.cellEditorFramework = EntityImportEditorAssessorSelectorCellEditorComponent;\r\n colDef.cellEditorParams = { getAssessors: this._getAssessors.bind(this) } as EntityImportEditorAssessorSelectorCellEditorParams;\r\n colDef.suppressKeyboardEvent = (params) => {\r\n const keyCode = params.event.keyCode;\r\n return params.editing && (keyCode === KEY_ENTER);\r\n };\r\n break;\r\n case 'AttachmentTypeSelector':\r\n colDef.cellEditorFramework = EntityImportEditorAttachmentTypeSelectorCellEditorComponent;\r\n colDef.cellEditorParams = {getAttachmentTypes: this._getAttachmentTypes.bind(this)} as EntityImportEditorAttachmentTypeSelectorCellEditorParams;\r\n colDef.suppressKeyboardEvent = (params) => {\r\n const keyCode = params.event.keyCode;\r\n return params.editing && (keyCode === KEY_ENTER);\r\n };\r\n break;\r\n case 'LeaseTypeSelector':\r\n colDef.cellEditorFramework = EntityImportEditorLeaseTypeSelectorCellEditorComponent;\r\n colDef.cellEditorParams = {getLeaseTypes: this._getLeaseTypes.bind(this)} as EntityImportEditorLeaseTypeSelectorCellEditorParams;\r\n colDef.suppressKeyboardEvent = (params) => {\r\n const keyCode = params.event.keyCode;\r\n return params.editing && (keyCode === KEY_ENTER);\r\n };\r\n break;\r\n case 'AssessmentClassSelector':\r\n colDef.cellEditorFramework = EntityImportEditorAssessmentClassSelectorCellEditorComponent;\r\n colDef.cellEditorParams = {getAssessmentClasses: this._getAssessmentClasses.bind(this)} as EntityImportEditorAssessmentClassSelectorCellEditorParams;\r\n colDef.suppressKeyboardEvent = (params) => {\r\n const keyCode = params.event.keyCode;\r\n return params.editing && (keyCode === KEY_ENTER);\r\n };\r\n break;\r\n case 'GLAccountSelector':\r\n colDef.cellEditorFramework = EntityImportEditorGLAccountSelectorCellEditorComponent;\r\n colDef.cellEditorParams = {getGLAccounts: this._getGLAccounts.bind(this)} as EntityImportEditorGLAccountSelectorCellEditorParams;\r\n colDef.suppressKeyboardEvent = (params) => {\r\n const keyCode = params.event.keyCode;\r\n return params.editing && (keyCode === KEY_ENTER);\r\n };\r\n break;\r\n case 'TaxingDistrictSelector':\r\n colDef.cellEditorFramework = EntityImportEditorTaxingSelectorCellEditorComponent;\r\n colDef.cellEditorParams = { getTaxingDistricts: this._getTaxingDistricts.bind(this) } as EntityImportEditorTaxingDistrictSelectorCellEditorParams;\r\n colDef.suppressKeyboardEvent = (params) => {\r\n const keyCode = params.event.keyCode;\r\n return params.editing && (keyCode === KEY_ENTER);\r\n };\r\n break;\r\n case 'OneTimeVRecurringSelector':\r\n colDef.cellEditorFramework = EntityImportEditorOneTimeVRecurringSelectorRendererCellEditorComponent;\r\n colDef.cellEditorParams = null;\r\n colDef.suppressKeyboardEvent = (params) => {\r\n const keyCode = params.event.keyCode;\r\n return params.editing && (keyCode === KEY_ENTER);\r\n };\r\n break;\r\n case 'GLAccountTypeSelector':\r\n colDef.cellEditorFramework = EntityImportEditorGLAccountTypeSelectorCellEditorComponent;\r\n colDef.cellEditorParams = { getGLAccountTypes: this._getGLAccountTypes.bind(this)} as EntityImportEditorGLAccountTypeSelectorCellEditorParams;\r\n colDef.suppressKeyboardEvent = (params) => {\r\n const keyCode = params.event.keyCode;\r\n return params.editing && (keyCode === KEY_ENTER);\r\n };\r\n break;\r\n case 'IncomeStatementCategorySelector':\r\n colDef.cellEditorFramework = EntityImportEditorIncomeStatementCategorySelectorCellEditorComponent;\r\n colDef.cellEditorParams = { getGlAccountTypeId: this._getGlAccountTypeId.bind(this)} as EntityImportEditorIncomeStatementCategorySelectorCellEditorParams;\r\n colDef.suppressKeyboardEvent = (params) => {\r\n const keyCode = params.event.keyCode;\r\n return params.editing && (keyCode === KEY_ENTER);\r\n };\r\n break;\r\n }\r\n }\r\n\r\n const header = (field && assignedField) ?\r\n this._importFileModel.importFileHeaders.find(i => i.importFileHeaderId.toString() === assignedField.value) :\r\n this._importFileModel.importFileHeaders.find(i => i.index.toString() === key);\r\n\r\n this._sortingColumns.push({name: key, value: header.index.toString()} as Compliance.NameValuePair);\r\n\r\n return colDef;\r\n })\r\n .value();\r\n\r\n // setup AgGrid columns for static columns\r\n const staticColumnDef: ImportGridRow[] = _\r\n .chain(this._importFileModel.importContentType.importFields)\r\n .filter(f => this._importFileModel.assignedFields.filter(af => af.isStatic).map(af => af.importFieldId).includes(f.importFieldId))\r\n .map(i => {\r\n const assignedField = this._importFileModel.assignedFields.find(af => af.importFieldId === i.importFieldId);\r\n const field = assignedField && this._importFileModel.importContentType.importFields.find(f => f.importFieldId === assignedField.importFieldId);\r\n this._fieldNames.push(i.displayName);\r\n return {\r\n headerName: i.displayName,\r\n field: i.displayName,\r\n suppressMovable: true,\r\n editable: false,\r\n sortable: false,\r\n cellClass: (params) => {\r\n return 'static-cell ' + ((params.data && params.data.validationStatus && params.data.validationStatus[params.colDef.field])||'');\r\n },\r\n // custom metadata\r\n ws: {\r\n isStatic: true,\r\n fieldMappingId: assignedField.importFileSpecificationFieldId,\r\n isMappedToRequiredFields: (field && field.isMappingRequired) || false\r\n } as Compliance.EntityImportEditingColDefMetadata\r\n } as ImportGridRow;\r\n })\r\n .value();\r\n\r\n // set AgGrid columns\r\n this._gridApi.setColumnDefs([\r\n selectRowColumnDef,\r\n estimatedActionColumnDef,\r\n rowIdColumnDef,\r\n ...fileColumnDefList,\r\n ...staticColumnDef\r\n ]);\r\n\r\n // apply column filters (hiding/showing columns)\r\n this._applyGridColumnFilter();\r\n\r\n this._setDataSource();\r\n\r\n this._gridApi.setSortModel(this._defaultSortModel);\r\n\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(async () => {\r\n const data: Compliance.ImportBulkOperationModel = {\r\n validationErrors: this._validationErrors || [],\r\n columnFilters: this._gridDataSource && this._gridDataSource.columnFilters({filterModel: this._gridApi.getFilterModel()} as IGetRowsParams) || [],\r\n estimatedActionFilter: this._gridDataSource && this._gridDataSource.estimatedActionFilter(this._gridDataSource.gridParams),\r\n selectAllRows: this.gridTracker.getSelectedRowsModel().selectAllRows,\r\n selectedRows: this.gridTracker.getSelectedRowsModel().selectedRows\r\n };\r\n\r\n this._entityImportProcessService.notifySelectedRowsChanged(data, this.getSelectedRowsCount());\r\n\r\n if (this._showTotals) {\r\n await this._reloadTotals();\r\n }\r\n });\r\n\r\n this._errorFilterSub = this._entityImportProcessService.errorFilterChanged$.subscribe((errors) => {\r\n // if they're the same empty array then do nothing (preventing double loading)\r\n if (this._validationErrors && this._validationErrors.length === 0 && (errors || []).length === 0) return;\r\n // setup AgGrid data source for infinite scrolling, will be reset every time the validation changes\r\n this._validationErrors = errors || [];\r\n\r\n if (_.filter(this._validationErrors, item => !item.isWarning).length !== 0){\r\n this.showValidRowsOnly = false;\r\n }\r\n\r\n this._refreshDataSource();\r\n });\r\n }\r\n\r\n async onAgCellValueChanged(params: CellValueChangedEvent): Promise {\r\n let newValue = params.newValue;\r\n const oldValue = params.oldValue;\r\n\r\n if (newValue === oldValue) {\r\n return;\r\n }\r\n\r\n this._showBusyIndicator('Update', 'Updating Value', null);\r\n\r\n try {\r\n await this._updateCell(newValue, params);\r\n\r\n const ws = (params.colDef as ImportGridRow).ws;\r\n if (!this._notValidatedUpdates.some(x => x.rowIndex == this._selectedRowIndex &&\r\n x.columnIndex == ws.columnIndex))\r\n {\r\n this._notValidatedUpdates.push({\r\n rowIndex: this._selectedRowIndex,\r\n columnIndex: ws.columnIndex});\r\n\r\n params.api.refreshCells({\r\n columns: [params.column.getColId()],\r\n rowNodes: [params.node],\r\n force: true\r\n });\r\n }\r\n\r\n if (!newValue) {\r\n const colId = params.column.getColId();\r\n params.node.setDataValue(colId, params.node.data.originalValues[colId]);\r\n }\r\n } finally {\r\n await this._hideBusyIndicator();\r\n }\r\n }\r\n\r\n filterGridColumns(filter: string): void {\r\n this.selectedGridColumnFilter = filter;\r\n this._applyGridColumnFilter();\r\n }\r\n\r\n showTransferredRowsChange(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n showValidRowsOnlyChange(): void {\r\n this.gridTracker.clear();\r\n this._entityImportProcessService.notifyShowValidRowsOnlyChanged(this.showValidRowsOnly);\r\n\r\n if (!this.showValidRowsOnly || !this._validationErrors || this._validationErrors.length === 0){\r\n this._refreshDataSource();\r\n }\r\n }\r\n\r\n async bulkUpdate(): Promise {\r\n const bulkUpdateFields = this._getBulkUpdateFields();\r\n\r\n const fields = await Promise.all(bulkUpdateFields.map(async (fieldInfo) => {\r\n switch (fieldInfo.uiCellRenderer) {\r\n case 'AssetClassSelector':\r\n fieldInfo.additionalParams = this._assetClassifications;\r\n break;\r\n case 'AssessorSelector':\r\n fieldInfo.additionalParams = await this._getAssessors(null);\r\n break;\r\n case 'AssessmentClassSelector':\r\n fieldInfo.additionalParams = await this._getAssessmentClasses(null);\r\n break;\r\n case 'GLAccountSelector':\r\n fieldInfo.additionalParams = await this._getGLAccounts(null);\r\n break;\r\n case 'TaxingDistrictSelector':\r\n fieldInfo.additionalParams = await this._getTaxingDistricts(null);\r\n break;\r\n case 'GLAccountTypeSelector':\r\n const glAccountTypes = await this._getGLAccountTypes();\r\n fieldInfo.additionalParams = [{\r\n glAccountTypeId: null,\r\n name: '',\r\n validForAccrual: false\r\n }, ...glAccountTypes];\r\n break;\r\n }\r\n\r\n return fieldInfo;\r\n }));\r\n\r\n const showModalFn = (): BsModalRef => {\r\n const selectionModel: Compliance.ImportBulkOperationModel = {\r\n validationErrors: this._validationErrors || [],\r\n columnFilters: this._gridDataSource.columnFilters({filterModel: this._gridApi.getFilterModel()} as IGetRowsParams) || [],\r\n estimatedActionFilter: this._gridDataSource.estimatedActionFilter(this._gridDataSource.gridParams),\r\n selectAllRows: this.gridTracker.getSelectedRowsModel().selectAllRows,\r\n selectedRows: this.gridTracker.getSelectedRowsModel().selectedRows\r\n };\r\n\r\n return this._bsModalService.show(ImportBulkUpdateComponent, {\r\n ignoreBackdropClick: true,\r\n initialState: {\r\n importFileId: this.importFileModel.importFileId,\r\n mappedFields: fields,\r\n selectionModel: selectionModel,\r\n saveCompleteCallback: this._bulkUpdateSaveCompleteCallback.bind(this),\r\n selectedCount: this.gridTracker.getSelectedRowsCount()\r\n }\r\n });\r\n };\r\n\r\n this._wsModalService.show(showModalFn.bind(this));\r\n }\r\n\r\n async bulkDelete(): Promise {\r\n const selectedRowsCount = this.gridTracker.getSelectedRowsCount();\r\n\r\n const confirmOptions = {\r\n message: `Are you sure you want to delete row${selectedRowsCount > 1 ? 's' : ''}?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n } as MessageBoxOptions;\r\n\r\n const result = await this._messageBoxService.open(confirmOptions);\r\n\r\n if (result === MessageBoxResult.OK) {\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: null,\r\n title: '',\r\n message: 'Deleting Rows',\r\n hasProgressBar: false\r\n });\r\n\r\n const selectionModel: Compliance.ImportBulkOperationModel = {\r\n validationErrors: this._validationErrors || [],\r\n columnFilters: this._gridDataSource.columnFilters({filterModel: this._gridApi.getFilterModel()} as IGetRowsParams) || [],\r\n estimatedActionFilter: this._gridDataSource.estimatedActionFilter(this._gridDataSource.gridParams),\r\n selectAllRows: this.gridTracker.getSelectedRowsModel().selectAllRows,\r\n selectedRows: this.gridTracker.getSelectedRowsModel().selectedRows\r\n };\r\n\r\n try {\r\n this.importFileModel = await this._entityImportProcessService.deleteStagingRows(this.importFileModel.importFileId, selectionModel);\r\n if (!this.importFileModel.transferredRows){\r\n this._refreshDataSource();\r\n this._entityImportProcessService.notifyClearErrorsWarningsSelection();\r\n }\r\n this.gridTracker.clear(false);\r\n }\r\n finally{\r\n await this._hideBusyIndicator();\r\n }\r\n\r\n this._entityImportProcessService.forceValidate();\r\n }\r\n }\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[]): Promise => {\r\n const selectionModel: Compliance.ImportGridSearchModel = {\r\n validationErrors: this._validationErrors || [],\r\n columnFilters: this._gridDataSource.columnFilters({filterModel: this._gridApi.getFilterModel()} as IGetRowsParams) || [],\r\n estimatedActionFilter: this._gridDataSource.estimatedActionFilter(this._gridDataSource.gridParams),\r\n selectAllRows: this.gridTracker.getSelectedRowsModel().selectAllRows,\r\n selectedRows: this.gridTracker.getSelectedRowsModel().selectedRows,\r\n showTransferredRows: this.showTransferredRows,\r\n showValidRowsOnly: this.showValidRowsOnly,\r\n includeOnlyTotals: false,\r\n includeTotals: false\r\n };\r\n\r\n const exportModel = {\r\n searchModel: selectionModel,\r\n columnsToReturn: columnsToReturn,\r\n } as Compliance.ImportExportStagingRowsModel;\r\n const lrp$ = this._entityImportRepository.exportStagingRows(this.importFileModel.importFileId, exportModel);\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportImportStagingRows };\r\n },\r\n canCancel: true\r\n };\r\n\r\n private async _updateCell(newValue: string, params: CellValueChangedEvent): Promise {\r\n this._selectedRow = params.data as Compliance.ImportGridRowGridModel;\r\n this._selectedRowIndex = this._selectedRow.rowIndex;\r\n this._updateCellParams = params;\r\n const importFileSpecificationFieldId = (params.colDef['ws'] as Compliance.EntityImportEditingColDefMetadata).fieldMappingId;\r\n await this._entityImportProcessService.updateCell(this._importFileModel.importFileId, this._selectedRow.rowIndex, importFileSpecificationFieldId, newValue);\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', lrpId: number): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: lrpId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: false,\r\n canDismiss: false\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success) => {\r\n if (success) {\r\n try {\r\n const longRunningProcessResult = await this._longRunningProcessService.get(this._entityImportProcessService.longRunningProcessId)\r\n const result: Compliance.ImportUpdateFieldProcessResultModel = JSON.parse(longRunningProcessResult.result);\r\n\r\n if (this._selectedRow.rowIndex !== result.selectedRowIndex) {\r\n return;\r\n }\r\n\r\n const props = this._getPageInvolvedProperties();\r\n\r\n if (result.moreThanOneRowsAffected || props.find(prop => prop === this._updateCellParams.column.getColId())) {\r\n this._refreshDataSource(false);\r\n }\r\n\r\n this._selectedRow[\"estimatedAction\"] = null;\r\n const newRowData = { ...this._selectedRow };\r\n newRowData.validationStatus = {};\r\n\r\n newRowData.hasError = false;\r\n result.rowValidationSummary.forEach(rvs => {\r\n newRowData.hasError = newRowData.hasError || !rvs.isWarning && rvs.errorSource === 'Validation';\r\n newRowData.validationStatus[rvs.fieldName] = rvs.isWarning ? 'cell-validation-warning' : 'cell-validation-error';\r\n });\r\n\r\n this._entityImportProcessService.notifyValidationSummaryChanged(result.importValidationSummary);\r\n\r\n // if the row has an error, ensure it isn't selected\r\n if (newRowData.hasError && this.gridTracker.isRowSelected(newRowData.rowIndex)) {\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n const index = selectedRowsModel.selectedRows.indexOf(newRowData.rowIndex);\r\n if (index !== -1) {\r\n selectedRowsModel.selectedRows.splice(index, 1);\r\n }\r\n this.gridTracker.setSelectedRowsModel(selectedRowsModel);\r\n }\r\n\r\n if (result.moreThanOneRowsAffected) {\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n if (selectedRowsModel.selectedRows && selectedRowsModel.selectedRows.length != 0 || selectedRowsModel.selectAllRows){\r\n await this._reloadTotals();\r\n }\r\n }\r\n\r\n if (newRowData) {\r\n const hasNullValues = Object.keys(newRowData.originalValues).find(x => newRowData[x] === null);\r\n if (hasNullValues) {\r\n this._refreshDataSource(false);\r\n } else {\r\n this._updateCellParams.node.setData(newRowData);\r\n this._gridApi.redrawRows({ rowNodes: [this._updateCellParams.node] });\r\n }\r\n\r\n if (this.importFileModel.importContentType.supportsTotals) {\r\n await this._gridDataSource.forceRefreshOfTotalValidRows(this.showTransferredRows, this.showValidRowsOnly);\r\n }\r\n } else {\r\n const colId = this._updateCellParams.column.getColId();\r\n this._updateCellParams.node.setDataValue(colId, this._updateCellParams);\r\n }\r\n } finally {\r\n await this._hideBusyIndicator();\r\n this._selectedRowIndex = -1;\r\n }\r\n } else {\r\n await this._hideBusyIndicator();\r\n }\r\n });\r\n }\r\n\r\n private _getPageInvolvedProperties(): string[] {\r\n const props = this._gridApi.getSortModel().map(sortColumn => sortColumn.colId);\r\n const keys = Object.keys(this._gridApi.getFilterModel());\r\n return props.concat(keys);\r\n }\r\n\r\n private _getGridColumnsAssociatedWithImportFileColumns(): Column[] {\r\n return this._gridColumnApi\r\n .getAllColumns()\r\n .filter((i) => {\r\n const metadata: Compliance.EntityImportEditingColDefMetadata = i.getColDef()['ws'];\r\n return metadata && !metadata.isStatic;\r\n });\r\n }\r\n\r\n private _getGridColumnsAssociatedWithMappedImportFileColumns(): Column[] {\r\n return this._getGridColumnsAssociatedWithImportFileColumns()\r\n .filter((i) => {\r\n const fieldMappingId: number = (i.getColDef()['ws'] as Compliance.EntityImportEditingColDefMetadata).fieldMappingId;\r\n return (fieldMappingId && fieldMappingId > 0) || false;\r\n });\r\n }\r\n\r\n private _getGridColumnsAssociatedWithUnmappedImportFileColumns(): Column[] {\r\n return this._getGridColumnsAssociatedWithImportFileColumns()\r\n .filter((i) => {\r\n const fieldMappingId: number = (i.getColDef()['ws'] as Compliance.EntityImportEditingColDefMetadata).fieldMappingId;\r\n const isMappedColumn = (fieldMappingId && fieldMappingId > 0) || false;\r\n return !isMappedColumn;\r\n });\r\n }\r\n\r\n private _getGridColumnsAssociatedWithStaticImportFileColumns(): Column[] {\r\n return this._gridColumnApi\r\n .getAllColumns()\r\n .filter((i) => {\r\n const metadata: Compliance.EntityImportEditingColDefMetadata = i.getColDef()['ws'];\r\n return metadata && metadata.isStatic;\r\n });\r\n }\r\n\r\n private _applyGridColumnFilter(): void {\r\n const mappedColumns = this._getGridColumnsAssociatedWithMappedImportFileColumns();\r\n const unmappedColumns = this._getGridColumnsAssociatedWithUnmappedImportFileColumns();\r\n const staticColumns = this._getGridColumnsAssociatedWithStaticImportFileColumns();\r\n\r\n const allColumns = ([] as Column[]).concat(mappedColumns).concat(unmappedColumns).concat(staticColumns);\r\n\r\n switch (this.selectedGridColumnFilter) {\r\n case this.gridColumnFilters.allColumns:\r\n allColumns.forEach(i => {\r\n this._gridColumnApi.setColumnVisible(i, true);\r\n const colDef = i.getColDef();\r\n const colDefMetadata: Compliance.EntityImportEditingColDefMetadata = colDef['ws'];\r\n colDef.headerClass = colDefMetadata.fieldMappingId ? `header-cell ${colDefMetadata.isMappedToRequiredFields ? 'mapping-required' : 'mapping-optional'}` : '';\r\n });\r\n this._gridApi.refreshHeader();\r\n break;\r\n\r\n case this.gridColumnFilters.mappedColumns:\r\n let visibleColumnsCount = 0;\r\n allColumns.forEach(i => {\r\n // the \"mapped columns\" UI filter should include both mapped columns from the file and columns \"mapped\" as static columns\r\n if (mappedColumns.indexOf(i) === -1 && staticColumns.indexOf(i) === -1) {\r\n this._gridColumnApi.setColumnVisible(i, false);\r\n } else {\r\n this._gridColumnApi.setColumnVisible(i, true);\r\n visibleColumnsCount++;\r\n }\r\n\r\n const colDef = i.getColDef();\r\n colDef.headerClass = '';\r\n });\r\n this._gridApi.refreshHeader();\r\n if (visibleColumnsCount <= 8){\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n break;\r\n\r\n default:\r\n console.warn('Cannot filter grid columns. An unknown filter is specified.');\r\n break;\r\n }\r\n }\r\n\r\n private _refreshDataSource(clearSelection: boolean = true): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n if (clearSelection) {\r\n this.gridTracker.clear();\r\n }\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const dataSourceParams = (): EntityImportEditorDataSourceParams => {\r\n return {\r\n importFileModel: this._importFileModel,\r\n validationSummaryFilters: this._validationErrors,\r\n showTransferredRows: this.showTransferredRows,\r\n showValidRowsOnly: this.showValidRowsOnly,\r\n sortingColumns: this._sortingColumns\r\n }\r\n }\r\n\r\n this._gridDataSource = new EntityImportEditorAgGridDataSource(\r\n this._gridApi,\r\n this._entityImportRepository,\r\n dataSourceParams,\r\n (count) => this._setFilteredRowCount(count),\r\n (count) => this._setTotalValidCount(count),\r\n this._handleTotalsUpdate,\r\n (updates: Compliance.ImportGridNotValidatedUpdateModel[], totalNotValidatedUpdates: number) => {\r\n this._notValidatedUpdates = updates;\r\n this._entityImportProcessService.notifyCellUpdated(totalNotValidatedUpdates);\r\n }\r\n );\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private _setFilteredRowCount(filteredRowCount) {\r\n this.filteredRows = filteredRowCount;\r\n this.totalRows = filteredRowCount;\r\n }\r\n\r\n private _setTotalValidCount(totalValidCount) {\r\n this.totalValidCount = totalValidCount;\r\n }\r\n\r\n private _isRowSelectionDisabled(rowIndex: number, data: Compliance.ImportGridRowGridModel): boolean {\r\n return false;\r\n }\r\n\r\n private _isRowSelectionHidden(rowIndex: number, data: Compliance.ImportGridRowGridModel): boolean {\r\n if (!this._isImportCompleted && UtilitiesService.isNumeric(rowIndex) && data) {\r\n return !!data.actualAction; // hide checkbox selection for transferred rows\r\n }\r\n\r\n return !UtilitiesService.isNumeric(rowIndex);\r\n }\r\n\r\n private async _bulkUpdateSaveCompleteCallback(selectionModel: Compliance.ImportBulkOperationModel): Promise {\r\n this._refreshDataSource(false);\r\n this._entityImportProcessService.notifySelectedRowsChanged(selectionModel, this.getSelectedRowsCount());\r\n\r\n if (this._showTotals) {\r\n await this._reloadTotals();\r\n }\r\n }\r\n\r\n private async _getAssessors(rowIndex?: number): Promise {\r\n this._assessors = await lastValueFrom(this._entityImportRepository.getAssessors(this.importFileModel.importFileId,\r\n this._getSelectionModel(rowIndex))) as Compliance.ImportAssessorModel[];\r\n return this._assessors;\r\n }\r\n\r\n private async _getAttachmentTypes(row: Compliance.ImportGridRowGridModel): Promise {\r\n let entityTypeId: Core.EntityTypes;\r\n\r\n if (this.importFileModel.importContentTypeId === Compliance.ImportContentTypeIdEnum.Attachment){\r\n const siteNumberAssignedField = this.importFileModel.assignedFields.find(i => i.importFieldId === `${Compliance.ImportFieldIdEnum.AttachmentSiteNumber}`);\r\n const siteField = siteNumberAssignedField && this._importFileModel.importContentType.importFields.find(f => f.importFieldId === siteNumberAssignedField.importFieldId);\r\n const parcelAssignedField = this.importFileModel.assignedFields.find(i => i.importFieldId === `${Compliance.ImportFieldIdEnum.AttachmentParcelAcctNum}`);\r\n const parcelField = parcelAssignedField && this._importFileModel.importContentType.importFields.find(f => f.importFieldId === parcelAssignedField.importFieldId);\r\n\r\n if (parcelField && (row[parcelField.displayName] || row.originalValues[parcelField.displayName])){\r\n entityTypeId = Core.EntityTypes.Parcel;\r\n } else if (siteField && (row[siteField.displayName] || row.originalValues[siteField.displayName])){\r\n entityTypeId = Core.EntityTypes.Site;\r\n } else{\r\n entityTypeId = Core.EntityTypes.Company;\r\n }\r\n } else{\r\n throw new Error(`Can't get entityTypeId for ContentType ${this.importFileModel.importContentTypeId} in _getAttachmentTypes method`);\r\n }\r\n\r\n return await lastValueFrom(this._entityImportRepository.getAvailableAttachmentTypes(entityTypeId));\r\n }\r\n\r\n private async _getLeaseTypes(): Promise {\r\n if (!this._leaseTypes){\r\n this._leaseTypes = await lastValueFrom(this._assetRepository.getLeaseTypes());\r\n\r\n this._leaseTypes.splice(0, 0, {leaseTypeId: ''} as Compliance.LeaseTypeModel);\r\n }\r\n\r\n return this._leaseTypes;\r\n }\r\n\r\n private _handleTotalsUpdate = (totals: Compliance.ImportGridTotalRow, selectedTotals:boolean = false) => {\r\n if (!this._showTotals || !totals || !totals.fields){\r\n return;\r\n }\r\n\r\n const totalsRow: any = {\r\n validationStatus: {},\r\n originalValues: {},\r\n hasError: false,\r\n rowIndex: 'TOTAL',\r\n actualAction: null,\r\n estimatedAction: null\r\n };\r\n\r\n _.each(this._fieldNames, fieldName => {\r\n const field = _.find(totals.fields, field => field.fieldName === fieldName);\r\n if (field){\r\n totalsRow[field.fieldName] = this._decimalPipe.transform(field.value, '1.2-2');\r\n totalsRow.originalValues[field.fieldName] = this._decimalPipe.transform(field.value, '1.2-2');\r\n } else{\r\n totalsRow[fieldName] = '-';\r\n totalsRow.originalValues[fieldName] = '-';\r\n }\r\n });\r\n\r\n if (selectedTotals){\r\n totalsRow.selectedTotalsRow = true;\r\n totalsRow.rowIndex = 'Selected';\r\n this.importGridSelectedTotalsRow = totalsRow;\r\n } else{\r\n totalsRow.totalsRow = true;\r\n this.importGridTotalsRow = totalsRow;\r\n }\r\n const totalRows = [this.importGridTotalsRow];\r\n if (this.gridTracker.hasAnythingSelected()) {\r\n totalRows.push(this.importGridSelectedTotalsRow);\r\n }\r\n setTimeout(() => this._gridApi.setPinnedBottomRowData(totalRows), 100);\r\n }\r\n\r\n private async _reloadTotals(): Promise {\r\n if (!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const timestamp = Date.now();\r\n this.selectedTotalsTimestamp = timestamp;\r\n\r\n this.selectedTotalsLoading = true;\r\n try {\r\n const result = await this._gridDataSource.getSelectedRowTotals(this.gridTracker.getSelectedRowsModel());\r\n if (this.selectedTotalsTimestamp === timestamp) {\r\n this.selectedTotalsLoading = false;\r\n this._handleTotalsUpdate(result, true);\r\n }\r\n }\r\n finally {\r\n this.selectedTotalsLoading = false;\r\n }\r\n }\r\n\r\n private async _getAssessmentClasses(rowIndex: number): Promise {\r\n let assessmentClasses = await lastValueFrom(this._entityImportRepository.getAssessmentClasses(this.importFileModel.importFileId,\r\n this._getSelectionModel(rowIndex)));\r\n\r\n assessmentClasses.splice(0, 0, null);\r\n\r\n return assessmentClasses;\r\n }\r\n\r\n private async _getGLAccounts(rowIndex: number): Promise {\r\n return await lastValueFrom(this._entityImportRepository.getGLAccounts(this.importFileModel.importFileId,\r\n this._getSelectionModel(rowIndex)));\r\n }\r\n\r\n private _getSelectionModel(rowIndex: number) {\r\n const selectionModel: Compliance.ImportBulkOperationModel = {\r\n validationErrors: this._validationErrors || [],\r\n columnFilters: this._gridDataSource.columnFilters({filterModel: this._gridApi.getFilterModel()} as IGetRowsParams) || [],\r\n estimatedActionFilter: this._gridDataSource.estimatedActionFilter(this._gridDataSource.gridParams),\r\n selectAllRows: false,\r\n selectedRows: []\r\n };\r\n\r\n if (rowIndex) {\r\n selectionModel.selectAllRows = false;\r\n selectionModel.selectedRows = [rowIndex];\r\n } else {\r\n selectionModel.selectAllRows = this.gridTracker.getSelectedRowsModel().selectAllRows;\r\n selectionModel.selectedRows = this.gridTracker.getSelectedRowsModel().selectedRows;\r\n }\r\n return selectionModel;\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._entityImportProcessService.longRunningProcessId = null;\r\n this._destroyIndicator$.next();\r\n }\r\n\r\n private async _getTaxingDistricts(rowIndex?: number): Promise {\r\n this._taxingDistricts = await lastValueFrom(this._entityImportRepository.getTaxingDistricts(this.importFileModel.importFileId,\r\n this._getSelectionModel(rowIndex))) as Core.TaxingDistrictModel[];\r\n return this._taxingDistricts;\r\n }\r\n\r\n private async _getAssetClassifications(): Promise {\r\n if (!this._assetClassifications) {\r\n const assetClassifications = await lastValueFrom(this._assetClassificationRepository.getAssetClassifications());\r\n const removeOverrideOption: Compliance.AssetClassificationModel = {\r\n allowPerpetual: false,\r\n assetClassificationId: -1,\r\n childClassifications: [],\r\n isInventory: false,\r\n name: 'Remove Override',\r\n parentAssetClassificationId: null\r\n };\r\n\r\n this._assetClassifications = [removeOverrideOption].concat(assetClassifications);\r\n }\r\n\r\n return this._assetClassifications;\r\n }\r\n\r\n private async _getGLAccountTypes(): Promise {\r\n if(!this._glAccountTypes) {\r\n const searchModel: Core.GLAccountTypeSearchModel = {\r\n forIncomeStatement: true\r\n }\r\n this._glAccountTypes = await lastValueFrom(this._entityImportRepository.getGLAccountTypes(searchModel));\r\n }\r\n\r\n return this._glAccountTypes;\r\n }\r\n\r\n private async _getGlAccountTypeId(params: EntityImportEditorIncomeStatementCategorySelectorCellEditorParams): Promise {\r\n if(params.data && params.data['G/L Account Type']) {\r\n const glAccountTypeName = params.data['G/L Account Type'];\r\n const glAccountTypes = await this._getGLAccountTypes();\r\n const glAccountType = _.find(glAccountTypes, {name: glAccountTypeName});\r\n\r\n return glAccountType ? glAccountType.glAccountTypeId : null;\r\n }\r\n\r\n return null;\r\n }\r\n\r\n private _getBulkUpdateFields() {\r\n const bulkUpdateFields = this._importFileModel.importContentType.importFields\r\n .filter(f => f.bulkUpdateAllowed && this._importFileModel.assignedFields.some(af => !af.isStatic && af.importFieldId === f.importFieldId))\r\n .map((i) => {\r\n const assignedField = this._importFileModel.assignedFields.find(af => af.importFieldId === i.importFieldId);\r\n const field = assignedField && this._importFileModel.importContentType.importFields.find(f => f.importFieldId === assignedField.importFieldId);\r\n\r\n const fieldInfo = {\r\n name: field.displayName,\r\n isMappingRequired: field.isMappingRequired,\r\n importFileSpecificationFieldId: assignedField.importFileSpecificationFieldId,\r\n uiCellRenderer: field.uiCellRenderer\r\n } as FieldInfo;\r\n\r\n return fieldInfo;\r\n });\r\n return bulkUpdateFields;\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Errors and Warnings\r\n \r\n

\r\n
\r\n
\r\n 0\"> {{notValidatedUpdatesCount}} Update(s)\r\n No Update(s)\r\n
\r\n
\r\n 0\"> {{errorCount()}} Error(s)\r\n No Error(s)\r\n
\r\n
\r\n 0\"> {{warningCount()}} Warning(s)\r\n No Warning(s)\r\n
\r\n
\r\n
\r\n
Click on an error or warning below to show associated data. To continue, all errors must be resolved.
\r\n
\r\n\r\n\r\n","import {Component, OnInit, OnDestroy, Input, ViewEncapsulation} from '@angular/core';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { GridApi, GridReadyEvent, ColDef, ICellRendererParams, GridOptions } from 'ag-grid-community';\r\nimport { EntityImportProcessService } from '../../importProcess.service';\r\nimport * as _ from 'lodash';\r\nimport { Subscription } from 'rxjs';\r\nimport { AgGridOptionsBuilder, AgGridColumns } from '../../../../AgGrid';\r\nimport { EntityImportColumnMappingStepService } from '../../Column-Mapping-Step/columnMappingStep.service';\r\n\r\n@Component({\r\n selector: 'entity-import-validation-summary',\r\n templateUrl: './validationSummary.component.html',\r\n styleUrls: ['./validationSummary.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class EntityImportValidationSummaryComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _entityImportProcessService: EntityImportProcessService,\r\n private readonly _decimalPipe: DecimalPipe) {\r\n }\r\n\r\n @Input() importFileModel: Compliance.ImportFileModel;\r\n\r\n private _validationSummarySub: Subscription;\r\n private _gridApi: GridApi;\r\n private _validationErrors: Compliance.ImportFileValidationErrorModel[];\r\n private _selectedIds: string[] = [];\r\n private _transferCompletedSub: Subscription;\r\n private _showValidRowsOnlyChangedSub: Subscription;\r\n private _clearErrorsWarningsSelectionSub: Subscription;\r\n private _notValidatedUpdatesSub: Subscription;\r\n notValidatedUpdatesCount: number = 0;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n getRowNodeId: this._getRowId\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleRowSelect()\r\n .withTextSelection()\r\n .build();\r\n\r\n ngOnInit() {\r\n this._validationSummarySub = this._entityImportProcessService.validationSummaryChanged$.subscribe(\r\n (validationErrors: Compliance.ImportFileValidationErrorModel[]) => {\r\n this._loadValidationErrors(validationErrors);\r\n });\r\n\r\n this._transferCompletedSub = this._entityImportProcessService.transferCompletedEventEmitter.subscribe(() => {\r\n this._entityImportProcessService.getValidationResults(this.importFileModel.importFileId).then(validationErrors => this._loadValidationErrors(validationErrors));\r\n });\r\n\r\n this._showValidRowsOnlyChangedSub =\r\n this._entityImportProcessService.showValidRowsOnlyChanged$.subscribe(\r\n (showValidRowsOnly) => this._showValidRowsOnlyChanged(showValidRowsOnly));\r\n\r\n this._clearErrorsWarningsSelectionSub = this._entityImportProcessService.clearErrorsWarningsSelectionChanged$.subscribe(() => this._clearSelection());\r\n\r\n this._notValidatedUpdatesSub = this._entityImportProcessService.notValidatedUpdates$.subscribe((x) => {\r\n this.notValidatedUpdatesCount = x;\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._validationSummarySub.unsubscribe();\r\n this._transferCompletedSub.unsubscribe();\r\n this._showValidRowsOnlyChangedSub.unsubscribe();\r\n this._clearErrorsWarningsSelectionSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerCheckboxSelection: true,\r\n checkboxSelection: true,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n width: AgGridColumns.selectionColumnWidth\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'isWarning',\r\n cellRenderer: (params: ICellRendererParams): string => {\r\n if (params.data.isWarning) {\r\n return 'Warning';\r\n } else {\r\n return 'Error';\r\n }\r\n },\r\n cellClass: (params: ICellRendererParams): string => {\r\n const validationError = params.data as Compliance.ImportFileValidationErrorModel;\r\n if (!validationError) {\r\n return '';\r\n }\r\n\r\n return validationError.isWarning ? 'cell-validation-warning' : 'cell-validation-error';\r\n },\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Column',\r\n field: 'fieldName',\r\n width: AgGridColumns.textColumnWidth,\r\n suppressSizeToFit: true,\r\n valueGetter: (params: ICellRendererParams): string => {\r\n const validationError = params.data as Compliance.ImportFileValidationErrorModel;\r\n if (!validationError) {\r\n return '';\r\n }\r\n\r\n let result = validationError.fieldName;\r\n\r\n if (!result) {\r\n result = validationError.errorSource === 'Transfer'\r\n ? 'N/A - Transfer Error'\r\n : 'N/A - Column name is not available';\r\n }\r\n\r\n return result;\r\n }\r\n },\r\n {\r\n headerName: 'Rows Affected',\r\n type: 'numericColumn',\r\n valueFormatter: (params) => {\r\n return this._decimalPipe.transform(params.value, '1.0-0');\r\n },\r\n field: 'count',\r\n width: AgGridColumns.numericColumnWidth,\r\n suppressSizeToFit: true\r\n },\r\n {\r\n headerName: 'Issue',\r\n field: 'issue'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setRowData(this._validationErrors);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n onAgGridSelectionChanged(): void {\r\n const selectedData = this._gridApi.getSelectedNodes().map(node => node.data as Compliance.ImportFileValidationErrorModel);\r\n const ids = selectedData.map(data => this._getRowId(data)).sort();\r\n\r\n // if the same error is in the list but only the count is changing, return\r\n if (_.isEqual(ids, this._selectedIds)) {\r\n return;\r\n }\r\n\r\n this._selectedIds = ids;\r\n this._entityImportProcessService.notifyErrorFilterChanged(selectedData || []);\r\n }\r\n\r\n rowsSelected(): boolean {\r\n return this._gridApi && this._gridApi.getSelectedNodes().length === 0;\r\n }\r\n\r\n errorCount(): number {\r\n return _.filter(this._validationErrors,\r\n (x) => {\r\n return !x.isWarning;\r\n }).length;\r\n }\r\n\r\n warningCount(): number {\r\n return _.filter(this._validationErrors,\r\n (x) => {\r\n return x.isWarning;\r\n }).length;\r\n }\r\n\r\n private _getRowId(data: Compliance.ImportFileValidationErrorModel): string {\r\n return data.fieldName + data.issue + data.isWarning;\r\n }\r\n\r\n private _loadValidationErrors(validationErrors: Compliance.ImportFileValidationErrorModel[]): void{\r\n this._validationErrors = _.orderBy(validationErrors, ['isWarning'], ['asc']);\r\n\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n // get the ids of the selected rows\r\n const selectedIds = this._gridApi.getSelectedNodes().map(node => {\r\n const data = node.data as Compliance.ImportFileValidationErrorModel;\r\n return this._getRowId(data);\r\n });\r\n\r\n this._gridApi.setRowData(this._validationErrors);\r\n\r\n // re-select rows\r\n _.each(selectedIds, (id) => {\r\n const node = this._gridApi.getRowNode(id);\r\n if (node) {\r\n node.setSelected(true);\r\n }\r\n });\r\n\r\n const selectedData = this._gridApi.getSelectedNodes().map(node => node.data as Compliance.ImportFileValidationErrorModel);\r\n this._entityImportProcessService.notifyErrorFilterChanged(selectedData || []);\r\n }\r\n\r\n private _showValidRowsOnlyChanged(showValidRowsOnly: boolean) {\r\n if (showValidRowsOnly){\r\n _.each(this._gridApi.getSelectedNodes(), node => {\r\n const data = node.data as Compliance.ImportFileValidationErrorModel;\r\n if (!data.isWarning){\r\n node.setSelected(false);\r\n }\r\n })\r\n\r\n this.onAgGridSelectionChanged();\r\n }\r\n }\r\n\r\n private _clearSelection() {\r\n this._gridApi.deselectAll();\r\n }\r\n}\r\n","\r\n\r\n\r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { BehaviorSubject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'entity-import-editing-step',\r\n templateUrl: './editingStep.component.html'\r\n})\r\nexport class EntityImportEditingStepComponent {\r\n @Input() importFileModel: Compliance.ImportFileModel;\r\n @Input() selectedRowsInfo$: BehaviorSubject;\r\n @Input() busyRefId: string;\r\n}\r\n","
\r\n \r\n
\r\n
\r\n \r\n
\r\n
Asset Effective date:
\r\n {{assetEffectiveDate | date : 'M/d/yyyy'}}\r\n
Asset Ownership type:
\r\n {{assetOwnershipTypeName}}\r\n
\r\n
\r\n
Adjustment Amount Value type:
\r\n {{accrualAdjustmentAmountValueType}}\r\n
\r\n
\r\n
Match existing sites by:
\r\n {{sitesUpdatesOnlyMatchBy}}\r\n
\r\n
\r\n
Match overall by:
\r\n {{taxPaymentsMatchOverall}}\r\n \r\n
Match parcel using:
\r\n {{taxPaymentsMatchParcel}}\r\n
Match collector using:
\r\n {{taxPaymentsMatchCollector}}\r\n
\r\n
\r\n
\r\n
Income Statements Ending date:
\r\n {{incomeStatementsEndingDate | date : 'M/d/yyyy'}}\r\n
\r\n
\r\n
Rent Roll Ending date:
\r\n {{rentRollEndingDate | date : 'M/d/yyyy'}}\r\n
\r\n
\r\n
Intended use:
\r\n {{glAccountsIntendedUse}}\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n
\r\n\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { AllocationRepository, EntityImportRepository } from '../../Repositories';\r\nimport { EntityImportProcessService, ISelectedRowsEvent } from './importProcess.service';\r\nimport { Subscription, BehaviorSubject, Subject, lastValueFrom } from 'rxjs';\r\nimport { EntityImportColumnMappingStepService } from './Column-Mapping-Step/columnMappingStep.service';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport * as _ from 'lodash';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { EntityImportSpecificationMappingComponent, ImportSpecificationMappingParams } from './Column-Mapping-Step/Import-Specification-Mapping/importSpecificationMapping.component';\r\nimport {HelpService} from '../../../UI-Lib/Help-Tooltip';\r\nimport {IMPORT_PROCESS_HELP} from './importProcess.component.help';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { InstanceRights, RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { EntityImportService } from '../entityImport.service';\r\n\r\nenum ImportStep {\r\n Indeterminate = 0,\r\n ColumnMapping = 1,\r\n Editing = 2\r\n}\r\n\r\nenum ImportInitiatorEnum {\r\n SystemList,\r\n CompanyList,\r\n Allocation\r\n}\r\n\r\n@Component({\r\n selector: 'entity-import-process',\r\n templateUrl: './importProcess.component.html',\r\n styleUrls: ['./importProcess.component.scss']\r\n})\r\nexport class EntityImportProcessComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _entityImportRepository: EntityImportRepository,\r\n private readonly _entityImportProcessService: EntityImportProcessService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _columnMappingStepService: EntityImportColumnMappingStepService,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _toastsManager: ToastrService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService,\r\n private readonly _allocationRepository: AllocationRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _entityImportService: EntityImportService) { }\r\n\r\n private readonly _unknownImportStep = 'An unknown import step was specified.';\r\n\r\n private _selectedRowsSub: Subscription;\r\n private _fieldAssignedSub: Subscription;\r\n private _fieldUnassignedSub: Subscription;\r\n private _notValidatedUpdatesSub: Subscription;\r\n private _validatedSub: Subscription;\r\n private _evaluatingSub: Subscription;\r\n private _selectedRowsModel: Compliance.SelectedRowsModel;\r\n private _selectedRowsCount: number = 0;\r\n private _isEvaluated: boolean = false;\r\n private _isValidated: boolean = false;\r\n private _isModelDirty: boolean = false;\r\n private _importStatusSub: Subscription;\r\n private _importProgressSub: Subscription;\r\n private _busyRef: BusyIndicatorRef;\r\n private _selectedRowsInfo: Compliance.ImportSelectedRowsInfoModel;\r\n private _previousEvaluationAllSelected: boolean;\r\n private _destroy$: Subject = new Subject();\r\n private _importInitiator: ImportInitiatorEnum;\r\n private _forceValidateSub: Subscription;\r\n\r\n selectedRowsInfo$: BehaviorSubject;\r\n\r\n busyRefId: string = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n breadcrumbs: BreadCrumb[] = [];\r\n isInitialized: boolean = false;\r\n importId: number;\r\n companyId: number;\r\n importSteps = ImportStep;\r\n importStep: ImportStep = ImportStep.Indeterminate;\r\n importFileModel: Compliance.ImportFileModel;\r\n allocationId?: number;\r\n notValidatedUpdatesCount: number = 0;\r\n\r\n get nextText(): string {\r\n if (this.importStep === ImportStep.ColumnMapping) {\r\n return 'Next Step: Validate';\r\n }\r\n if (this.importStep === ImportStep.Editing && !this._isEvaluated) {\r\n return 'Next Step: Evaluate';\r\n }\r\n if (this.importStep === ImportStep.Editing && this._isEvaluated) {\r\n return 'Next Step: Transfer';\r\n }\r\n return 'Next';\r\n }\r\n\r\n get isGoBackVisible(): boolean {\r\n switch (this.importStep) {\r\n case ImportStep.Indeterminate:\r\n case ImportStep.ColumnMapping:\r\n return false;\r\n case ImportStep.Editing:\r\n return this.importFileModel.transferredRows === 0;\r\n default:\r\n console.warn(this._unknownImportStep);\r\n return true;\r\n }\r\n }\r\n\r\n get isGoBackEnabled(): boolean {\r\n switch (this.importStep) {\r\n case ImportStep.Indeterminate:\r\n case ImportStep.ColumnMapping:\r\n return false;\r\n case ImportStep.Editing:\r\n return true;\r\n default:\r\n console.warn(this._unknownImportStep);\r\n return true;\r\n }\r\n }\r\n\r\n get isGoNextVisible(): boolean {\r\n switch (this.importStep) {\r\n case ImportStep.Indeterminate:\r\n return false;\r\n case ImportStep.ColumnMapping:\r\n case ImportStep.Editing:\r\n return this.importFileModel &&\r\n this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.Completed &&\r\n this.importFileModel.totalRows !== this.importFileModel.transferredRows;\r\n default:\r\n console.warn(this._unknownImportStep);\r\n return true;\r\n }\r\n }\r\n\r\n get importFileDescription(): string {\r\n return this.importFileModel ? `${this.importFileModel.displayName } (${ _.get(this.importFileModel, 'importContentType.name') })` : '';\r\n }\r\n\r\n get isGoNextEnabled(): boolean {\r\n let isEnabled: boolean;\r\n\r\n switch (this.importStep) {\r\n case ImportStep.Indeterminate:\r\n return false;\r\n case ImportStep.ColumnMapping:\r\n isEnabled = this.importFileModel.requiredFieldsAssigned;\r\n\r\n if (isEnabled) {\r\n const unknownMappedFields = this.importFileModel.assignedFields\r\n .filter(x => !this.importFileModel.importContentType.importFields.find(y => y.importFieldId == x.importFieldId));\r\n isEnabled = !unknownMappedFields.length;\r\n }\r\n return isEnabled;\r\n case ImportStep.Editing:\r\n isEnabled = this._selectedRowsModel && this._selectedRowsCount > 0 && this._selectedRowsInfo &&\r\n this._selectedRowsInfo.validRowsCount !== 0 && !this.notValidatedUpdatesCount;\r\n\r\n if (isEnabled && this._isEvaluated){\r\n isEnabled = this.importFileModel.importContentTypeId === Compliance.ImportContentTypeIdEnum.Assets ||\r\n (!!this._selectedRowsInfo.evaluatedInsertCount || !!this._selectedRowsInfo.evaluatedUpdateCount ||\r\n !!this._selectedRowsInfo.evaluatedDeleteCount);\r\n }\r\n\r\n return isEnabled;\r\n default:\r\n console.warn(this._unknownImportStep);\r\n return true;\r\n }\r\n }\r\n\r\n get isCloseEnabled(): boolean {\r\n return this.importStep !== ImportStep.Indeterminate;\r\n }\r\n\r\n get nextHelpContentId(): string {\r\n switch (this.importStep) {\r\n case ImportStep.Indeterminate:\r\n return '';\r\n case ImportStep.ColumnMapping:\r\n if (this.importFileModel.requiredFieldsAssigned) {\r\n return 'import-process.next-step-validate';\r\n }\r\n return 'import-process.next-step-validate.disabled';\r\n case ImportStep.Editing:\r\n let helpId = '';\r\n\r\n if (this.importFileModel && !this._isEvaluated) {\r\n if (this.notValidatedUpdatesCount) {\r\n helpId = 'import-process.has-not-validated-updates';\r\n } else if (this._selectedRowsModel && this._selectedRowsCount === 0 ) {\r\n helpId = 'import-process.next-step-evaluate.disabled.no-selection';\r\n } else if (this._selectedRowsModel && this._selectedRowsInfo && this._selectedRowsInfo.validRowsCount === 0) {\r\n helpId = 'import-process.next-step-evaluate.disabled.invalid-selection';\r\n } else {\r\n helpId = 'import-process.next-step-evaluate';\r\n }\r\n } else if (this.importFileModel && this._isEvaluated){\r\n if (this.importFileModel.importContentTypeId === Compliance.ImportContentTypeIdEnum.Assets ||\r\n (this._selectedRowsInfo && (!!this._selectedRowsInfo.evaluatedInsertCount || !!this._selectedRowsInfo.evaluatedUpdateCount))){\r\n helpId = 'import-process.next-step-transfer';\r\n } else{\r\n helpId = 'import-process.next-step-evaluate.disabled.no-nochanges';\r\n }\r\n } else {\r\n helpId = 'import-process.next-step-transfer';\r\n }\r\n\r\n return helpId;\r\n }\r\n }\r\n\r\n get backHelpContentId(): string {\r\n if (this.importStep == ImportStep.Editing) {\r\n return 'import-process.back.edit';\r\n }\r\n\r\n return 'import-process.back';\r\n }\r\n\r\n get isMarkAsCompletedVisible(): boolean {\r\n switch (this.importStep) {\r\n case ImportStep.Indeterminate:\r\n case ImportStep.ColumnMapping:\r\n return false;\r\n case ImportStep.Editing:\r\n return this.importFileModel &&\r\n this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.Completed &&\r\n this.importFileModel.totalRows !== this.importFileModel.transferredRows;\r\n default:\r\n console.warn(this._unknownImportStep);\r\n return true;\r\n }\r\n }\r\n\r\n get isValidateVisible(): boolean {\r\n switch (this.importStep) {\r\n case ImportStep.Indeterminate:\r\n case ImportStep.ColumnMapping:\r\n return false;\r\n case ImportStep.Editing:\r\n return this.importFileModel &&\r\n this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.Completed;\r\n default:\r\n console.warn(this._unknownImportStep);\r\n return true;\r\n }\r\n }\r\n\r\n get isMarkAsCompletedEnabled(): boolean {\r\n switch (this.importStep) {\r\n case ImportStep.Indeterminate:\r\n case ImportStep.ColumnMapping:\r\n return false;\r\n case ImportStep.Editing:\r\n return this.importFileModel &&\r\n this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.Completed &&\r\n this.importFileModel.transferredRows !== 0 &&\r\n !this.notValidatedUpdatesCount;\r\n default:\r\n console.warn(this._unknownImportStep);\r\n return true;\r\n }\r\n }\r\n\r\n get markCompletedHelpContentId(): string {\r\n let result = '';\r\n\r\n if (this.notValidatedUpdatesCount) {\r\n result = 'import-process.has-not-validated-updates';\r\n } else if (!this.isMarkAsCompletedEnabled) {\r\n result = 'import-process.mark-completed-disabled';\r\n } else {\r\n result = 'import-process.mark-completed';\r\n }\r\n\r\n return result;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n let companyName: string;\r\n let allocationName: string;\r\n\r\n this._helpService.setContent(IMPORT_PROCESS_HELP);\r\n\r\n if (this._routerService.getQuerystringParam('allocationId')){\r\n this._importInitiator = ImportInitiatorEnum.Allocation;\r\n } else if (this._routerService.getQuerystringParam('companyId')){\r\n this._importInitiator = ImportInitiatorEnum.CompanyList;\r\n } else {\r\n this._importInitiator = ImportInitiatorEnum.SystemList;\r\n }\r\n\r\n let busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n this.selectedRowsInfo$ = new BehaviorSubject(null);\r\n try {\r\n try {\r\n this.importId = parseInt(this._routerService.getQuerystringParam('importId'));\r\n let instanceId: number;\r\n\r\n if (this._importInitiator === ImportInitiatorEnum.CompanyList) {\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n\r\n const company = await this._companyService.load(this.companyId, false, false);\r\n\r\n if (company.companyID !== company.topLevelCompanyId) {\r\n this._toastsManager.error('Data imports are not allowed on subsidiary companies.');\r\n this.navigateToCompany();\r\n return;\r\n }\r\n\r\n companyName = company.companyName;\r\n instanceId = company.instanceID;\r\n } else if (this._importInitiator === ImportInitiatorEnum.Allocation) {\r\n this.allocationId = parseInt(this._routerService.getQuerystringParam('allocationId'));\r\n const allocation = await lastValueFrom(this._allocationRepository.get(this.allocationId));\r\n\r\n if (!this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, allocation.instanceId)) {\r\n this.navigateToUnauthorized();\r\n return Promise.resolve();\r\n }\r\n\r\n allocationName = allocation.description;\r\n instanceId = allocation.instanceId;\r\n }\r\n\r\n if (this._importInitiator === ImportInitiatorEnum.CompanyList ||\r\n this._importInitiator === ImportInitiatorEnum.Allocation)\r\n {\r\n if (!this._restrictService.hasInstanceRight(InstanceRights.COMPANYDATAIMPORTSVIEW, instanceId)) {\r\n this.navigateToUnauthorized();\r\n return Promise.resolve();\r\n }\r\n } else {\r\n if (!this._restrictService.hasInstanceRight(InstanceRights.INSTANCEDATAIMPORTS, instanceId) &&\r\n !this._restrictService.isInRole(Roles.ALLOWDATAIMPORTS) &&\r\n !this._restrictService.isInRole(Roles.TAXRATESETUP)){\r\n this.navigateToUnauthorized();\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n await this._getImport(this.importId);\r\n } catch (e) {\r\n if (e && e.status === 423) {\r\n try {\r\n await busyRef.hide();\r\n await this._messageModalService.confirm(\r\n `${e.error.message } Are you sure you wish to take ownership?`,\r\n 'Confirm Take Ownership');\r\n } catch (e) {\r\n this.navigateToImportsList();\r\n return;\r\n }\r\n\r\n busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n await lastValueFrom(this._entityImportRepository.takeOwnership(this.importId));\r\n await this._getImport(this.importId);\r\n } else {\r\n throw e;\r\n }\r\n }\r\n\r\n await this._entityImportProcessService.initialize(this.importFileModel);\r\n\r\n this._fieldAssignedSub = this._columnMappingStepService.fieldAssigned$.subscribe(() => this._setModelDirty());\r\n\r\n this._fieldUnassignedSub = this._columnMappingStepService.fieldUnassigned$.subscribe(() => this._setModelDirty());\r\n\r\n this._selectedRowsSub = this._entityImportProcessService.selectedRowsChanged$.subscribe(\r\n async (selectedRowsEvent: ISelectedRowsEvent) => {\r\n this._selectedRowsModel = {\r\n selectedRows: selectedRowsEvent.selectedRowsModel.selectedRows,\r\n selectAllRows: selectedRowsEvent.selectedRowsModel.selectAllRows\r\n };\r\n\r\n this._selectedRowsCount = selectedRowsEvent.selectedRowsCount;\r\n\r\n this._isEvaluated = this._previousEvaluationAllSelected;\r\n\r\n if (this._selectedRowsModel.selectAllRows || this._selectedRowsModel.selectedRows.length !== 0) {\r\n const busyIndicatorRef = this._busyIndicatorService.show({ message: 'Validating selection' });\r\n try{\r\n this._selectedRowsInfo = await this._entityImportProcessService.getSelectedRowsInfo(this.importId, selectedRowsEvent.selectedRowsModel);\r\n }\r\n finally{\r\n busyIndicatorRef.hide();\r\n }\r\n } else {\r\n this._selectedRowsInfo = null;\r\n }\r\n\r\n this.selectedRowsInfo$.next(this._selectedRowsInfo);\r\n });\r\n\r\n this._notValidatedUpdatesSub = this._entityImportProcessService.notValidatedUpdates$.subscribe((x) => {\r\n this.notValidatedUpdatesCount = x;\r\n\r\n if (x)\r\n {\r\n this._isEvaluated = false;\r\n this._previousEvaluationAllSelected = false;\r\n }\r\n });\r\n\r\n this._validatedSub = this._entityImportProcessService.validated$.subscribe(\r\n async (promise: Promise) => {\r\n this._isValidated = false;\r\n const busyIndicatorRef = this._busyIndicatorService.show({ message: 'Loading Validation Summary' });\r\n\r\n try {\r\n await promise;\r\n this._isValidated = true;\r\n if (this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.Completed){\r\n this.importFileModel.processStatus = Compliance.ImportFileProcessStatusEnum.Validated;\r\n }\r\n } finally {\r\n await busyIndicatorRef.hide();\r\n }\r\n });\r\n\r\n this._evaluatingSub = this._entityImportProcessService.evaluating$.subscribe(\r\n async (promise: Promise) => {\r\n this._previousEvaluationAllSelected = false;\r\n this._isEvaluated = false;\r\n const busyIndicatorRef = this._busyIndicatorService.show({ message: 'Evaluating selected rows' });\r\n\r\n try {\r\n await promise;\r\n this._isEvaluated = true;\r\n if (this._selectedRowsModel.selectAllRows) {\r\n this._previousEvaluationAllSelected = true;\r\n }\r\n } finally {\r\n busyIndicatorRef.hide();\r\n }\r\n });\r\n\r\n // determine import step to go to based on the state of the import file\r\n // go to editing step if (1) required fields are mapped (2) transferred at least one row\r\n this.importStep = (this.importFileModel.requiredFieldsAssigned && this.importFileModel.transferredRows > 0 ||\r\n this.importFileModel.processStatus === Compliance.ImportFileProcessStatusEnum.Completed)\r\n ? ImportStep.Editing\r\n : ImportStep.ColumnMapping;\r\n\r\n // re-validate in case some of the lookup data is different.\r\n if (this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.Completed\r\n && this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.Transferring\r\n && this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.Validating\r\n && this.importFileModel.transferredRows !== this.importFileModel.totalRows\r\n && this.importStep === ImportStep.Editing) {\r\n if (!busyRef.isDisposed){\r\n await busyRef.hide();\r\n }\r\n await this._startValidation('Validating', false);\r\n }\r\n\r\n if (this._importInitiator === ImportInitiatorEnum.CompanyList) {\r\n this.breadcrumbs.push({\r\n name: companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n });\r\n this.breadcrumbs.push({\r\n name: 'Data Imports',\r\n target: 'companyImports',\r\n options: { companyId: this.companyId }\r\n });\r\n } else if (this._importInitiator === ImportInitiatorEnum.Allocation) {\r\n this.breadcrumbs.push({\r\n name: allocationName,\r\n target: 'allocationDetails',\r\n options: { allocationId: this.allocationId }\r\n });\r\n } else {\r\n this.breadcrumbs.push({\r\n name: 'Data Imports',\r\n target: 'systemImports',\r\n options: {}\r\n });\r\n }\r\n\r\n this._forceValidateSub = this._entityImportProcessService.forceValidate$.subscribe(async() => await this.revalidate());\r\n\r\n this.isInitialized = true;\r\n }\r\n finally {\r\n if (!busyRef.isDisposed) {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n this._importStatusSub = this._entityImportProcessService.importStatus$.subscribe(x => this._handleStatusChange(x));\r\n\r\n if (this.importStep === ImportStep.Editing) {\r\n // get initial status and block UI if a long running process is active\r\n // this needs to run after the global busy indicator in the try/catch has been disposed\r\n\r\n setTimeout(() => this._handleStatusChange(this.importFileModel, true), 500);\r\n }\r\n }\r\n\r\n async ngOnDestroy(): Promise {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n this._fieldAssignedSub && this._fieldAssignedSub.unsubscribe();\r\n this._fieldUnassignedSub && this._fieldUnassignedSub.unsubscribe();\r\n this._notValidatedUpdatesSub && this._notValidatedUpdatesSub.unsubscribe();\r\n this._validatedSub && this._validatedSub.unsubscribe();\r\n this._evaluatingSub && this._evaluatingSub.unsubscribe();\r\n this._entityImportProcessService && this._entityImportProcessService.destroy();\r\n this._importStatusSub && this._importStatusSub.unsubscribe();\r\n this._importProgressSub && this._importProgressSub.unsubscribe();\r\n this._forceValidateSub && this._forceValidateSub.unsubscribe();\r\n await this._hideBusyIndicator();\r\n }\r\n\r\n goBack() {\r\n this.importStep--;\r\n if (this.importStep === ImportStep.ColumnMapping) {\r\n this._isValidated = false;\r\n this._isEvaluated = false;\r\n this._previousEvaluationAllSelected = false;\r\n }\r\n }\r\n\r\n async goNext(): Promise {\r\n if (this.importStep === ImportStep.ColumnMapping) {\r\n if (this._isModelDirty && this.importFileModel.importFileSpecificationId\r\n && (!this.importFileModel.importFileSpecificationIsPrivate || this.importFileModel.importFileSpecificationUserId === this.importFileModel.userId)) {\r\n\r\n await this.saveImportSpecification();\r\n }\r\n\r\n if (this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.Completed &&\r\n this.importFileModel.transferredRows !== this.importFileModel.totalRows) {\r\n await this._startValidation('Validating', true);\r\n } else {\r\n this.importStep++;\r\n }\r\n } else {\r\n await this._goNext();\r\n }\r\n }\r\n\r\n onCloseClick(): void {\r\n this.navigateToImportsList();\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n navigateToImportsList(): void {\r\n if (this._importInitiator === ImportInitiatorEnum.CompanyList){\r\n this._routerService.go('companyImports', { 'companyId': this.companyId });\r\n } else if (this._importInitiator === ImportInitiatorEnum.Allocation) {\r\n this._routerService.go('allocationDetails', { 'allocationId': this.allocationId });\r\n } else{\r\n this._routerService.go('systemImports', {});\r\n }\r\n }\r\n\r\n async saveImportSpecification(): Promise {\r\n const params: ImportSpecificationMappingParams = {\r\n importFileId: this.importFileModel.importFileId,\r\n companyId: this.importFileModel.companyId,\r\n importFileSpecificationId: this.importFileModel.importFileSpecificationId,\r\n importFileSpecificationName: this.importFileModel.importFileSpecificationName,\r\n allowNoSave: true\r\n };\r\n\r\n const result = await this._modalService.showAsync(EntityImportSpecificationMappingComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._toastsManager.success('Specification saved');\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async markAsCompleted(): Promise{\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to mark the data import as completed?',\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Completing Data Import' });\r\n try {\r\n this.importFileModel = await lastValueFrom(this._entityImportRepository.markAsCompleted(this.importFileModel.importFileId));\r\n this.navigateToImportsList();\r\n return Promise.resolve();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n get isRevalidateVisible(): boolean {\r\n switch (this.importStep) {\r\n case ImportStep.Indeterminate:\r\n case ImportStep.ColumnMapping:\r\n return false;\r\n case ImportStep.Editing:\r\n return this.importFileModel &&\r\n this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.Completed &&\r\n this.importFileModel.totalRows !== this.importFileModel.transferredRows;\r\n default:\r\n console.warn(`this._unknownImportStep: ${this.importStep}`);\r\n return true;\r\n }\r\n }\r\n\r\n async revalidate(): Promise {\r\n const model: Compliance.ImportValidateModel = {\r\n validateNotValidatedUpdatesOnly: !!this.notValidatedUpdatesCount\r\n };\r\n await this._startValidation('Revalidating', false, model);\r\n }\r\n\r\n get assetEffectiveDate(): Date {\r\n return this._entityImportProcessService.assetEffectiveDate;\r\n }\r\n\r\n get assetOwnershipTypeName(): string {\r\n return this._entityImportProcessService.assetOwnershipTypeName;\r\n }\r\n\r\n get accrualAdjustmentAmountValueType(): string {\r\n return this._entityImportProcessService.accrualAdjustmentAmountValueType;\r\n }\r\n\r\n navigateToCompany(): void {\r\n this._routerService.go('company', { 'companyId': this.companyId });\r\n }\r\n\r\n get isDeleteVisible(): boolean {\r\n switch (this.importStep) {\r\n case ImportStep.Indeterminate:\r\n return false;\r\n case ImportStep.ColumnMapping:\r\n return true;\r\n case ImportStep.Editing:\r\n return this.importFileModel &&\r\n this._entityImportProcessService.canDelete(this.importFileModel) &&\r\n !this.importFileModel.transferredRows;\r\n default:\r\n console.warn(this._unknownImportStep);\r\n return true;\r\n }\r\n }\r\n\r\n get isDeleteEnabled(): boolean {\r\n return this._entityImportProcessService.canDelete(this.importFileModel);\r\n }\r\n\r\n get deleteHelpContentId(): string {\r\n if (!this.isDeleteEnabled) {\r\n return 'import-process.delete-disabled';\r\n }\r\n\r\n return 'import-process.delete';\r\n }\r\n\r\n get isSiteUpdatesOnlyImport(): boolean {\r\n return this._entityImportProcessService.importContentTypeId === Compliance.ImportContentTypeIdEnum.SitesUpdatesOnly;\r\n }\r\n\r\n get sitesUpdatesOnlyMatchBy(): string {\r\n return this._entityImportProcessService.sitesUpdatesOnlyMatchBy;\r\n }\r\n\r\n get isTaxPaymentsImport(): boolean {\r\n return this._entityImportProcessService.importContentTypeId === Compliance.ImportContentTypeIdEnum.TaxPayments;\r\n }\r\n\r\n get taxPaymentsMatchOverall(): string {\r\n return this._entityImportProcessService.taxPaymentsMatchOverall;\r\n }\r\n\r\n get isTaxPaymentsImportMatchByPaymentSystemId(): boolean {\r\n return this._entityImportProcessService.isTaxPaymentsImportMatchByPaymentSystemId;\r\n }\r\n\r\n get taxPaymentsMatchParcel(): string {\r\n return this._entityImportProcessService.taxPaymentsMatchParcel;\r\n }\r\n\r\n get taxPaymentsMatchCollector(): string {\r\n return this._entityImportProcessService.taxPaymentsMatchCollector;\r\n }\r\n\r\n get incomeStatementsEndingDate(): Date {\r\n return this._entityImportProcessService.incomeStatementsEndingDate;\r\n }\r\n\r\n get rentRollEndingDate(): Date {\r\n return this._entityImportProcessService.rentRollEndingDate;\r\n }\r\n\r\n get glAccountsIntendedUse(): string {\r\n return this._entityImportProcessService.glAccountsIntendedUse;\r\n }\r\n\r\n async delete(): Promise {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to delete the data import?',\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n try {\r\n await lastValueFrom(this._entityImportRepository.deleteImport(this.importId));\r\n this.navigateToImportsList();\r\n return Promise.resolve(true);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private async _getImport(id: number): Promise {\r\n this.importFileModel = await lastValueFrom(this._entityImportRepository.getImport(id));\r\n }\r\n\r\n private async _setModelDirty(): Promise {\r\n this._isModelDirty = true;\r\n await this._getImport(this.importId);\r\n }\r\n\r\n private async _goNext(): Promise {\r\n // evaluate\r\n if (this._isValidated && !this._isEvaluated) {\r\n await this._entityImportProcessService.evaluate(this.importId, this._selectedRowsModel);\r\n this._messageModalService.alert('The selected rows have been evaluated and are now ready to transfer. Review the estimated database transfer action for each selected row before proceeding.');\r\n return;\r\n }\r\n\r\n // transfer\r\n if (this._isValidated && this._isEvaluated) {\r\n const confirm = await this._entityImportProcessService.transfer();\r\n\r\n if (confirm) {\r\n this._showBusyIndicator('', 'Transferring selected rows', null, !this.allocationId);\r\n try {\r\n const transfer = await this._entityImportProcessService.startTransfer(this.importId, this._selectedRowsModel);\r\n this._busyRef.setLongRunningProcessId(transfer.longRunningProcessId);\r\n } catch (errResp) {\r\n this._toastsManager.error(errResp.error.message);\r\n this._hideBusyIndicator();\r\n }\r\n }\r\n }\r\n }\r\n\r\n private async _handleStatusChange(importFile: Compliance.ImportFileModel, isFirstLoad: boolean = false): Promise {\r\n this.importFileModel = importFile;\r\n\r\n let message: string;\r\n const status = importFile.processStatus;\r\n const lrpId = importFile.longRunningProcessId;\r\n\r\n switch (status) {\r\n case Compliance.ImportFileProcessStatusEnum.None:\r\n case Compliance.ImportFileProcessStatusEnum.ProcessingCompleted:\r\n case Compliance.ImportFileProcessStatusEnum.BulkUpdated:\r\n return;\r\n case Compliance.ImportFileProcessStatusEnum.Validating:\r\n if (!importFile.error) {\r\n this._showBusyIndicator('', 'Validating', lrpId, false, false);\r\n }\r\n return;\r\n case Compliance.ImportFileProcessStatusEnum.Validated:\r\n if (isFirstLoad && this.importStep === ImportStep.Indeterminate) {\r\n this.importStep = ImportStep.Editing;\r\n }\r\n return;\r\n case Compliance.ImportFileProcessStatusEnum.Processing:\r\n case Compliance.ImportFileProcessStatusEnum.Transferring:\r\n message = 'Transferring selected rows';\r\n this._showBusyIndicator('', message, lrpId);\r\n return;\r\n case Compliance.ImportFileProcessStatusEnum.TransferError:\r\n message = `Transfer failed. ${this.importFileModel.lastTransferInfo.errorMessage}`;\r\n break;\r\n case Compliance.ImportFileProcessStatusEnum.RevertingError:\r\n message = `Revert failed. ${this.importFileModel.lastTransferInfo.errorMessage}`;\r\n break;\r\n case Compliance.ImportFileProcessStatusEnum.Transferred:\r\n case Compliance.ImportFileProcessStatusEnum.TransferCompleted:\r\n case Compliance.ImportFileProcessStatusEnum.Completed:\r\n if (this.importFileModel.lastTransferInfo){\r\n const rowsCount: number = this.importFileModel.lastTransferInfo.insertedCount +\r\n this.importFileModel.lastTransferInfo.updatedCount +\r\n this.importFileModel.lastTransferInfo.deletedCount +\r\n this.importFileModel.lastTransferInfo.unchangedCount;\r\n const errorsCount = this.importFileModel.lastTransferInfo.errorsCount;\r\n\r\n message = `${this._decimalPipe.transform(rowsCount || 0, '1.0-0')} row(s) were transferred.`;\r\n\r\n if (this.importFileModel.importContentTypeId === Compliance.ImportContentTypeIdEnum.Assets &&\r\n this.importFileModel.lastTransferInfo.unchangedCount !== 0){\r\n message += ' (included unchanged assets just recorded as appearing on import)';\r\n }\r\n\r\n if (errorsCount){\r\n message += ` Transfer failed for ${this._decimalPipe.transform(errorsCount, '1.0-0')} row(s). Transfer error(s) are reflected in the Errors and Warnings panel.`;\r\n }\r\n }\r\n\r\n this._entityImportProcessService.transferCompletedEventEmitter.emit(Promise.resolve());\r\n break;\r\n default:\r\n console.log('Unknown return status.', status);\r\n throw new Error('Unknown return status.');\r\n }\r\n\r\n if (isFirstLoad) {\r\n return;\r\n }\r\n\r\n let resultTitle = 'Success';\r\n if (this.importFileModel && this._entityImportProcessService.importProcessStatusError) {\r\n resultTitle = 'Error';\r\n message = this._entityImportProcessService.importProcessStatusError;\r\n }\r\n\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n }\r\n\r\n try {\r\n await this._messageModalService.alert(message, resultTitle);\r\n this._busyRef = null;\r\n\r\n if (this.importFileModel.totalRows === this.importFileModel.transferredRows){\r\n await this.navigateToImportsList();\r\n }\r\n } catch (e) {\r\n\r\n }\r\n }\r\n\r\n private async _startValidation(message: string, goToNextStep: boolean, validationModel?: Compliance.ImportValidateModel): Promise {\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: null,\r\n title: 'Processing',\r\n message: message,\r\n hasProgressBar: true,\r\n canDismiss: false\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success: boolean) => {\r\n await this._hideBusyIndicator();\r\n if (!success) {\r\n return;\r\n }\r\n\r\n this._isEvaluated = false;\r\n this.notValidatedUpdatesCount = 0;\r\n this._entityImportProcessService.notifyCellUpdated(0);\r\n\r\n if (this._selectedRowsModel && (this._selectedRowsModel.selectAllRows || this._selectedRowsModel.selectedRows && this._selectedRowsModel.selectedRows.length !== 0)) {\r\n const selectedRowsModel = {\r\n estimatedActionFilter: null,\r\n validationErrors: [],\r\n selectAllRows: this._selectedRowsModel.selectAllRows,\r\n selectedRows: this._selectedRowsModel.selectedRows\r\n } as Compliance.ImportBulkOperationModel;\r\n this._selectedRowsInfo = await this._entityImportProcessService.getSelectedRowsInfo(this.importId, selectedRowsModel);\r\n\r\n this.selectedRowsInfo$.next(this._selectedRowsInfo);\r\n }\r\n\r\n if (goToNextStep && this.importFileModel.processStatus !== Compliance.ImportFileProcessStatusEnum.ProcessingError) {\r\n this.importStep++;\r\n }\r\n\r\n await this._entityImportProcessService.getValidationSummary(this.importId);\r\n });\r\n\r\n try {\r\n await this._entityImportProcessService.validate(this.importId, validationModel);\r\n await this._busyRef.setLongRunningProcessId(this._entityImportProcessService.longRunningProcessId);\r\n } catch (errResp) {\r\n this._toastsManager.error(errResp.error.message);\r\n await this._hideBusyIndicator();\r\n }\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', lrpId: number, canDismiss = true, hasProgressBar = true): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: lrpId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: hasProgressBar,\r\n canDismiss\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async () => {\r\n await this._hideBusyIndicator();\r\n });\r\n\r\n this._busyRef.onDismiss().pipe(takeUntil(this._destroy$)).subscribe(async () => {\r\n await this._hideBusyIndicator();\r\n this._routerService.go('companyImports', {\r\n 'companyId': this.importFileModel.companyId\r\n });\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef && !this._busyRef.isDisposed) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._entityImportProcessService.longRunningProcessId = null;\r\n this._destroy$.next();\r\n }\r\n}\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../AgGrid';\r\nimport { ImportSpecificationRepository } from '../../Repositories';\r\n\r\nexport interface ImportSpecificationListDataSourceParams {\r\n excludeReadOnly: boolean;\r\n includeDisabled: boolean;\r\n companyId: number;\r\n}\r\n\r\nexport class ImportSpecificationListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _importSpecificationRepository: ImportSpecificationRepository,\r\n protected _dataSourceParamsFn: () => ImportSpecificationListDataSourceParams\r\n ) { super(_gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'displayName', value: Compliance.ImportFileSpecificationPropertyEnum.DisplayName },\r\n { name: 'companyName', value: Compliance.ImportFileSpecificationPropertyEnum.CompanyName },\r\n { name: 'visibility', value: Compliance.ImportFileSpecificationPropertyEnum.Visibility },\r\n { name: 'importContentTypeName', value: Compliance.ImportFileSpecificationPropertyEnum.ImportContentTypeName },\r\n { name: 'ownerName', value: Compliance.ImportFileSpecificationPropertyEnum.OwnerName },\r\n { name: 'hasHeaders', value: Compliance.ImportFileSpecificationPropertyEnum.HasHeaders },\r\n { name: 'delimiterName', value: Compliance.ImportFileSpecificationPropertyEnum.DelimiterName },\r\n { name: 'isDisabled', value: Compliance.ImportFileSpecificationPropertyEnum.IsDisabled },\r\n { name: 'fileType', value: Compliance.ImportFileSpecificationPropertyEnum.FileType }\r\n ];\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Compliance.ImportFileSpecificationSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n excludeReadOnly: this._dataSourceParams.excludeReadOnly,\r\n includeDisabled: this._dataSourceParams.includeDisabled,\r\n companyId: this._dataSourceParams.companyId\r\n };\r\n\r\n let result = await lastValueFrom(this._importSpecificationRepository.getList(searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n}\r\n\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForImportSpecificationListGridAction extends ICellRendererParams {\r\n viewDetails: (params: ICellRendererParamsForImportSpecificationListGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n`\r\n})\r\nexport class ImportSpecificationListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForImportSpecificationListGridAction;\r\n importSpecification: Compliance.ImportFileSpecificationModel;\r\n\r\n agInit(params: ICellRendererParamsForImportSpecificationListGridAction): void {\r\n this.params = params;\r\n this.importSpecification = params.data as Compliance.ImportFileSpecificationModel;\r\n\r\n if (!this.importSpecification) {\r\n\r\n }\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this.params.viewDetails(this.params);\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n

{{ specification.importContentTypeName }}

\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n \r\n
\r\n
Please provide a name.
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n

{{ specification.fileType }}

\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n Please select a company\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import {Component, OnInit, ViewEncapsulation, OnDestroy} from '@angular/core';\r\nimport { UntypedFormGroup, UntypedFormControl, Validators } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { takeUntil, mergeMap } from 'rxjs/operators';\r\nimport { lastValueFrom, Observable, Subject } from 'rxjs';\r\nimport { CompanyRepository, ImportSpecificationRepository } from '../../../Repositories';\r\nimport { RestrictService, Roles } from '../../../../Common/Permissions/restrict.service';\r\nimport { AccountService } from '../../../../User/account.service';\r\nimport { BusyIndicatorMessageManager } from '../../../../Busy-Indicator';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder } from '../../../AgGrid';\r\nimport * as _ from \"lodash\";\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\n\r\nexport interface EntityImportSpecificationEditParams {\r\n specificationId: number;\r\n}\r\n\r\ninterface EditFormResultValues {\r\n displayName: string;\r\n visibility: string;\r\n companyId: number;\r\n isDisabled: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'import-specification-edit',\r\n templateUrl: './importSpecificationEdit.component.html',\r\n styleUrls: ['./importSpecificationEdit.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class EntityImportSpecificationEditComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _companyRepository: CompanyRepository,\r\n private readonly _accountService: AccountService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _entityImportSpecificationRepository: ImportSpecificationRepository) {}\r\n\r\n private readonly visibilityPrivate: string = 'Private';\r\n private readonly visibilityCompany: string = 'Company';\r\n private readonly visibilityShared: string = 'Shared';\r\n private _gridApi: GridApi;\r\n private destroy$: Subject = new Subject();\r\n\r\n params: EntityImportSpecificationEditParams;\r\n result: Compliance.ImportFileSpecificationModel;\r\n\r\n specification: Compliance.ImportFileSpecificationModel;\r\n visibilityOptions: string[] = [];\r\n editForm: UntypedFormGroup;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n companyFilter: string = '';\r\n companiesLoading: boolean = false;\r\n selectedCompanyId: number;\r\n companiesDataSource$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.companyFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterCompanies(token)));\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withContext(this)\r\n .withColumnResize()\r\n .withLoadingOverlay()\r\n .build();\r\n canEdit: boolean = false;\r\n isInitialized: boolean = false;\r\n\r\n async ngOnInit(): Promise {\r\n\r\n const busyMsg = 'loading';\r\n\r\n this.busyIndicatorMessageManager.add('Loading', busyMsg);\r\n try {\r\n this.specification = await lastValueFrom(this._entityImportSpecificationRepository.get(this.params.specificationId))\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n\r\n this.selectedCompanyId = this.specification.companyId;\r\n this.companyFilter = this.specification.companyName;\r\n\r\n if (this.specification.userId === this._accountService.userData.id) {\r\n this.visibilityOptions.push(this.visibilityPrivate);\r\n }\r\n\r\n this.visibilityOptions.push(this.visibilityCompany);\r\n\r\n if (this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT)) {\r\n this.visibilityOptions.push(this.visibilityShared);\r\n }\r\n\r\n this.canEdit = this.specification.userId === this._accountService.userData.id;\r\n\r\n this.editForm = new UntypedFormGroup({\r\n displayName: new UntypedFormControl({value: this.specification.displayName, disabled: !this.canEdit},[Validators.required]),\r\n visibility: new UntypedFormControl({value: this.specification.visibility, disabled: !this.canEdit}),\r\n companyName: new UntypedFormControl({\r\n value: this.specification.companyName,\r\n disabled: !this.canEdit || (this.specification.visibility !== this.visibilityCompany)\r\n }, [Validators.required]),\r\n isDisabled: new UntypedFormControl({value: this.specification.isDisabled, disabled: !this.canEdit})\r\n });\r\n\r\n this.editForm.get('visibility').valueChanges.pipe(takeUntil(this.destroy$)).subscribe(v => {\r\n if (v === this.visibilityCompany) {\r\n this.editForm.get('companyName').enable();\r\n } else {\r\n this.editForm.get('companyName').disable();\r\n }\r\n });\r\n\r\n this._setRowData();\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsg = 'saving';\r\n\r\n this.busyIndicatorMessageManager.add('Saving', busyMsg);\r\n\r\n try {\r\n const formValues = this.editForm.value as EditFormResultValues;\r\n\r\n const updateModel: Compliance.ImportFileSpecificationUpdateModel = {\r\n companyId: formValues.visibility === this.visibilityCompany ? this.selectedCompanyId : null,\r\n displayName: formValues.displayName,\r\n importFileSpecificationId: this.specification.importFileSpecificationId,\r\n isDisabled: formValues.isDisabled,\r\n isSystem: formValues.visibility === this.visibilityShared\r\n };\r\n\r\n this.result = await lastValueFrom(this._entityImportSpecificationRepository.update(updateModel));\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n onCompanySelected(typeAheadMatch: TypeaheadMatch): void {\r\n const company = typeAheadMatch.item as Core.CompanyDTO;\r\n this.editForm.get('companyName').setValue(company.companyName);\r\n this.selectedCompanyId = company.companyID;\r\n }\r\n\r\n onCompanyBlur(): void {\r\n if (!this.companyFilter || this.companyFilter.trim() === '') {\r\n this.editForm.get('companyName').setValue(null);\r\n this.selectedCompanyId = null;\r\n }\r\n }\r\n\r\n onCompanyLoadingChange(isLoading: boolean): void {\r\n this.companiesLoading = isLoading;\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent) {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Import Field Name',\r\n field: `importFieldName`,\r\n width: 100,\r\n minWidth: 50\r\n },\r\n {\r\n headerName: 'Column Index',\r\n field: `columnIndex`,\r\n width: 70,\r\n minWidth: 50\r\n },\r\n {\r\n headerName: 'Static Value',\r\n field: `staticValue`,\r\n width: 100,\r\n minWidth: 50,\r\n valueFormatter: params => {\r\n const data = params.data as Compliance.ImportFileSpecificationFieldModel;\r\n return data.isStatic ? params.value : ''\r\n }\r\n },\r\n {\r\n headerName: 'Import Field Data Type',\r\n field: `importFieldDataType`,\r\n width: 100,\r\n minWidth: 50,\r\n valueFormatter: params =>{\r\n const data = params.data as Compliance.ImportFileSpecificationFieldModel;\r\n let result: string;\r\n\r\n const fieldDataType = data.importFieldDataType;\r\n switch (fieldDataType) {\r\n case Compliance.ImportFieldDataTypeEnum.YesNo.toString():\r\n case Compliance.ImportFieldDataTypeEnum.YesNoToTrueFalse.toString():\r\n result = 'Yes/No';\r\n break;\r\n case Compliance.ImportFieldDataTypeEnum.YesNoBlank.toString():\r\n case Compliance.ImportFieldDataTypeEnum.YesNoBlankDefaultNo.toString():\r\n result = 'Yes/No/Blank';\r\n break;\r\n default:\r\n result = data.importFieldDataType;\r\n break;\r\n }\r\n\r\n return result;\r\n }\r\n },\r\n {\r\n headerName: 'Min Value/Length',\r\n field: `min`,\r\n width: 100,\r\n minWidth: 50,\r\n valueFormatter: params => {\r\n const data = params.data as Compliance.ImportFileSpecificationFieldModel;\r\n let result = '';\r\n\r\n if (data.min) {\r\n const fieldDataType = data.importFieldDataType;\r\n\r\n switch (fieldDataType) {\r\n case Compliance.ImportFieldDataTypeEnum.Currency.toString():\r\n result = data.min.toLocaleString('en-US', {style: 'currency', currency: 'USD'});\r\n break;\r\n case Compliance.ImportFieldDataTypeEnum.Integer.toString():\r\n case Compliance.ImportFieldDataTypeEnum.Text.toString():\r\n result = data.min.toFixed().toLocaleString();\r\n break;\r\n default:\r\n result = data.min.toLocaleString();\r\n break;\r\n }\r\n }\r\n\r\n return result;\r\n }\r\n },\r\n {\r\n headerName: 'Max Value/Length',\r\n field: `max`,\r\n width: 100,\r\n minWidth: 50,\r\n valueFormatter: params => {\r\n const data = params.data as Compliance.ImportFileSpecificationFieldModel;\r\n let result = '';\r\n\r\n if (data.max) {\r\n const fieldDataType = data.importFieldDataType;\r\n\r\n switch (fieldDataType) {\r\n case Compliance.ImportFieldDataTypeEnum.Currency.toString():\r\n result = data.max.toLocaleString('en-US', {style: 'currency', currency: 'USD'});\r\n break;\r\n case Compliance.ImportFieldDataTypeEnum.Integer.toString():\r\n case Compliance.ImportFieldDataTypeEnum.Text.toString():\r\n result = data.max.toFixed().toLocaleString();\r\n break;\r\n default:\r\n result = data.max.toLocaleString();\r\n break;\r\n }\r\n }\r\n\r\n return result;\r\n }\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n\r\n this._setRowData();\r\n }\r\n\r\n private _filterCompanies(searchValue: string): Observable {\r\n return this._companyRepository.searchCompanies(searchValue);\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.specification)) {\r\n return;\r\n }\r\n\r\n let gridData: Compliance.ImportFileSpecificationFieldModel[] = [];\r\n\r\n let lastColumnIndex: number = 1;\r\n _.forEach(this.specification.fields.sort(field => field.columnIndex), field => {\r\n for (lastColumnIndex; lastColumnIndex < field.columnIndex; lastColumnIndex++){\r\n gridData.push({columnIndex: lastColumnIndex} as Compliance.ImportFileSpecificationFieldModel);\r\n }\r\n gridData.push(field);\r\n lastColumnIndex++;\r\n })\r\n\r\n this._gridApi.setRowData(gridData);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const IMPORT_SPECIFICATION_LIST_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'import-specification-list.include-disabled',\r\n tooltipText: 'Include disabled specifications.',\r\n hasIcon: true\r\n }\r\n];\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Data Import Specifications\r\n \r\n

\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation, OnDestroy } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { ImportSpecificationListAgGridDataSource, ImportSpecificationListDataSourceParams } from './agGridDataSource';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridFilterParams, AgGridColumns } from '../../AgGrid';\r\nimport { AgGridOptionsBuilder } from '../../AgGrid';\r\nimport { ImportSpecificationRepository } from '../../Repositories';\r\nimport { ICellRendererParamsForImportSpecificationListGridAction, ImportSpecificationListGridActionCellRendererComponent } from './agGridActionCellRenderer.component';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { EntityImportSpecificationEditComponent, EntityImportSpecificationEditParams } from './Import-Specification-Edit/importSpecificationEdit.component';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { Subject } from 'rxjs';\r\nimport { IMPORT_SPECIFICATION_LIST_HELP } from './importSpecificationList.component.help';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\n\r\n@Component({\r\n templateUrl: './importSpecificationList.component.html',\r\n styleUrls: ['./importSpecificationList.component.scss'],\r\n selector: 'import-specification-list',\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ImportSpecificationListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _importSpecificationRepository: ImportSpecificationRepository,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _helpService: HelpService) {}\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: ImportSpecificationListAgGridDataSource;\r\n private _companyId?: number;\r\n private _destroy$: Subject = new Subject();\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n gridId: System.Guid = '6AA74EEF-A678-461B-B55C-CD59A9619487';\r\n companyName: string;\r\n includeDisabled: UntypedFormControl = new UntypedFormControl(false);\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'row-disabled': params => params.data && (params.data as Compliance.ImportFileSpecificationModel).isDisabled\r\n }})\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(IMPORT_SPECIFICATION_LIST_HELP);\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n if (!!this._routerService.getQuerystringParam('companyId')) {\r\n this._companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n const company = await this._companyService.load(this._companyId, false, false);\r\n\r\n this.companyName = company.companyName;\r\n\r\n this.breadcrumbs.push({\r\n name: this.companyName,\r\n target: 'company',\r\n options: { companyId: this._companyId }\r\n });\r\n }\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n this.includeDisabled.valueChanges.pipe(takeUntil(this._destroy$)).subscribe(() => this._setDataSource());\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Name',\r\n field: 'displayName',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'importContentTypeName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Visibility',\r\n field: 'visibility',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: !!this._companyId\r\n },\r\n {\r\n headerName: 'Owner',\r\n field: 'ownerName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Header Row',\r\n field: 'hasHeaders',\r\n width: AgGridColumns.textColumnExtraSmallWidth,\r\n lockPinned: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const spec = params.data as Compliance.ImportFileSpecificationModel;\r\n if (!spec) {\r\n return '';\r\n }\r\n return spec.headerRowIndex !== 0 ? 'Yes' : 'No';\r\n }\r\n },\r\n {\r\n headerName: 'File Type',\r\n field: 'fileType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }, {\r\n headerName: 'Delimiter',\r\n field: 'delimiterName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Disabled',\r\n field: 'isDisabled',\r\n width: AgGridColumns.textColumnExtraSmallWidth,\r\n lockPinned: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const spec = params.data as Compliance.ImportFileSpecificationModel;\r\n if (!spec) {\r\n return '';\r\n }\r\n return spec.isDisabled ? 'Yes' : 'No';\r\n }\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: ImportSpecificationListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this._onViewDetails.bind(this)\r\n } as ICellRendererParamsForImportSpecificationListGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'displayName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n\r\n this._setDataSource();\r\n }\r\n\r\n async refresh(): Promise {\r\n this._refreshDataSource();\r\n }\r\n\r\n navigateToCompany(): void {\r\n this._routerService.go('company', { 'companyId': this._companyId });\r\n }\r\n\r\n async onIncludeDisabledChanged(): Promise {\r\n this._refreshDataSource();\r\n }\r\n\r\n private async _onViewDetails(params: ICellRendererParamsForImportSpecificationListGridAction): Promise {\r\n const importSpec = params.data as Compliance.ImportFileSpecificationModel;\r\n if (!importSpec) {\r\n return Promise.resolve();\r\n }\r\n\r\n const specParams: EntityImportSpecificationEditParams = {\r\n specificationId: importSpec.importFileSpecificationId\r\n };\r\n\r\n const result = await this._modalService.showAsync(EntityImportSpecificationEditComponent, specParams, 'modal-xl');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._gridDataSource.updateRow(y => {\r\n const rowModel = y.data as Compliance.ImportFileSpecificationModel;\r\n return rowModel && rowModel.importFileSpecificationId === result.importFileSpecificationId;\r\n },\r\n () => {\r\n return Promise.resolve(result);\r\n });\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const dataSourceParams = (): ImportSpecificationListDataSourceParams => {\r\n return {\r\n excludeReadOnly: true,\r\n includeDisabled: this.includeDisabled.value,\r\n companyId: this._companyId\r\n }\r\n }\r\n\r\n this._gridDataSource = new ImportSpecificationListAgGridDataSource(this._gridApi, this._importSpecificationRepository, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { AttachmentModalData } from '../../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../../Comments/comments.service';\r\n\r\nexport interface ICellRendererParamsForFactorTableListGridAction extends ICellRendererParams {\r\n canEdit: () => boolean;\r\n viewDetails: (params: ICellRendererParamsForFactorTableListGridAction) => void;\r\n delete: (params: ICellRendererParamsForFactorTableListGridAction) => void;\r\n copy: (params: ICellRendererParamsForFactorTableListGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class FactorTableListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n private _params: ICellRendererParamsForFactorTableListGridAction;\r\n factorTableGridItem: Compliance.FactorTableListItemModel;\r\n attachmentModalData: AttachmentModalData;\r\n commentModalData: CommentModalData;\r\n canEdit: boolean = false;\r\n\r\n agInit(params: ICellRendererParamsForFactorTableListGridAction): void {\r\n this._params = params;\r\n this.canEdit = params.canEdit();\r\n this.factorTableGridItem = params.data as Compliance.FactorTableListItemModel;\r\n if (!this.factorTableGridItem) {\r\n return;\r\n }\r\n this.attachmentModalData = {\r\n entityType: 'FactorTable', //todo: make this a constant generated typescript value\r\n entityName: this.factorTableGridItem.name,\r\n year: this.factorTableGridItem.taxYear,\r\n disableYears: false,\r\n singleYear: false,\r\n entityData: {\r\n typeId: Core.EntityTypes.FactorTable,\r\n id: this.factorTableGridItem.factorTableId,\r\n name: this.factorTableGridItem.name\r\n },\r\n readOnly: !this.canEdit\r\n } as AttachmentModalData;\r\n\r\n this.commentModalData = {\r\n entityID: this.factorTableGridItem.factorTableId,\r\n entityTypeID: Core.EntityTypes.FactorTable,\r\n parcelAcctNum: null,\r\n canEdit: this.canEdit,\r\n description: null,\r\n parcelID: null,\r\n year: this.factorTableGridItem.taxYear ? this.factorTableGridItem.taxYear.toString() : null\r\n } as CommentModalData;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this._params.viewDetails(this._params);\r\n }\r\n\r\n onDeleteClicked(): void {\r\n this._params.delete(this._params);\r\n }\r\n\r\n onCopyClicked() {\r\n this._params.copy(this._params);\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, ICellRendererParams } from \"ag-grid-community\";\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from \"../../AgGrid/MultiSelectTracker\";\r\nimport { lastValueFrom, Subscription } from \"rxjs\";\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from \"../../AgGrid\";\r\nimport { WeissmanDateTimeFormatPipe } from \"../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe\";\r\nimport { FactorTableRepository } from \"../../Repositories\";\r\nimport {\r\n FactorTableListGridActionCellRendererComponent,\r\n ICellRendererParamsForFactorTableListGridAction\r\n} from \"../Factor-Table-List/agGridActionCellRenderer.component\";\r\n\r\n@Component({\r\n selector: 'form-library-export',\r\n templateUrl: './factorTableExportAttachments.component.html',\r\n styleUrls: ['./factorTableExportAttachments.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class FactorTableExportAttachmentsComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _factorTableRepository: FactorTableRepository,\r\n private readonly _dateTimePipe: WeissmanDateTimeFormatPipe) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n private _factorTables: Compliance.FactorTableListItemModel[];\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data &&\r\n this.gridTracker.isRowSelected((params.data as Compliance.FactorTableListItemModel).factorTableId)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n params: void;\r\n result: number[];\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n rowsSelected: boolean = false;\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n const busyMsg = \"Loading\";\r\n\r\n this.busyIndicatorMessageManager.add('Loading', busyMsg);\r\n try {\r\n const searchModel: Compliance.FactorTableSearchModel = {\r\n includeRetiredTables: false,\r\n hasAttachments: true\r\n };\r\n this._factorTables = await lastValueFrom(this._factorTableRepository.getList(searchModel));\r\n }\r\n finally{\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n this._setRowData();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.rowsSelected = x.selectAllRows || x.selectedRows.length > 0;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'factorTableId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n width: AgGridColumns.stateAbbreviationColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: (params) => {\r\n const factorTableGridItem = params.data as Compliance.FactorTableListItemModel;\r\n if (!factorTableGridItem) {\r\n return '';\r\n }\r\n return factorTableGridItem.assessorName ? factorTableGridItem.assessorName : factorTableGridItem.state;\r\n },\r\n cellClass: (params: ICellRendererParams): string => {\r\n const factorTableGridItem = params.data as Compliance.FactorTableListItemModel;\r\n if (!factorTableGridItem) {\r\n return '';\r\n }\r\n return factorTableGridItem.assessorName ? '' : 'assessor-state';\r\n }\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'typeName',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Table Name',\r\n field: 'name',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Changed By',\r\n field: 'changedByUserName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Changed Date',\r\n field: 'changeDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._dateTimePipe.transform(x.value, true)\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'state',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n async export(): Promise {\r\n this.result = await this.gridTracker.getSelectedRowIds();\r\n\r\n this._bsModalRef.hide();\r\n return Promise.resolve();\r\n }\r\n\r\n private _setRowData() {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._factorTables);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map((x) => {\r\n const formRevision = x.data as Compliance.FactorTableListItemModel;\r\n return formRevision && formRevision.factorTableId;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n Factor Tables\r\n \r\n

\r\n
\r\n
\r\n
View:
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport {\r\n ColDef,\r\n CsvExportParams,\r\n GridApi,\r\n GridOptions,\r\n GridReadyEvent,\r\n ICellRendererParams,\r\n ProcessCellForExportParams\r\n} from 'ag-grid-community';\r\nimport { BusyIndicatorService, SnackBarService } from '../../../Busy-Indicator';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { CompanyRepository, FactorTableRepository } from '../../Repositories';\r\nimport {\r\n FactorTableListGridActionCellRendererComponent,\r\n ICellRendererParamsForFactorTableListGridAction\r\n} from './agGridActionCellRenderer.component';\r\nimport { InstanceRights, RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../AgGrid';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { map, mergeMap } from 'rxjs/operators';\r\nimport {\r\n FactorTableDetailsComponent,\r\n FactorTableDetailsParams,\r\n GridSourceOptionEnum\r\n} from '../Factor-Table-Details/factorTableDetails.component';\r\nimport { from, lastValueFrom, Observable, Subject } from 'rxjs';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { WsSelectValueFormatter } from '../../../UI-Lib/Select/select.interface';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { AgGridExportOptions } from '../../AgGrid/ToolPanel/models';\r\nimport {\r\n FactorTableExportAttachmentsComponent\r\n} from '../Factor-Table-Export-Attachments/factorTableExportAttachments.component';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'factor-table-list',\r\n templateUrl: './factorTableList.component.html',\r\n styleUrls: ['./factorTableList.component.scss']\r\n})\r\nexport class FactorTableListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _factorTableRepository: FactorTableRepository,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _companyRepository: CompanyRepository,\r\n private readonly _snackBarService: SnackBarService\r\n ) {}\r\n\r\n private readonly _GRID_SOURCE_OPTION_SYSTEM: Compliance.NameValuePair = {\r\n name: 'System',\r\n value: GridSourceOptionEnum.System\r\n };\r\n\r\n private readonly _GRID_SOURCE_OPTION_COMPANY: Compliance.NameValuePair = {\r\n name: 'Company Specific',\r\n value: GridSourceOptionEnum.Company\r\n };\r\n\r\n private _gridApi: GridApi;\r\n private _currentYear = new Date().getFullYear();\r\n private _factorTables: Compliance.FactorTableListItemModel[];\r\n private _destroy$: Subject = new Subject();\r\n private _factorTableExportAttachmentsLongRunningProcessId: number;\r\n\r\n GridSourceOptionEnum = GridSourceOptionEnum;\r\n gridId: System.Guid = '7D885CAC-59F4-4CAE-AE56-B89D8DE60508';\r\n isInitialized: boolean = false;\r\n states: Compliance.FactorTableStateModel[];\r\n selectedState: UntypedFormControl = new UntypedFormControl(null);\r\n taxYears: number[] = [];\r\n selectedTaxYear: UntypedFormControl = new UntypedFormControl(null);\r\n tableTypes: Compliance.NameValuePair[];\r\n selectedTableType: Compliance.NameValuePair;\r\n hasCompanyWritePermission: boolean = false;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .withColumnPinning()\r\n .build();\r\n\r\n companyFilter: string = '';\r\n companiesLoading: boolean = false;\r\n selectedCompanyId: number;\r\n selectedCompany: UntypedFormControl = new UntypedFormControl(null);\r\n refreshing: boolean;\r\n includeRetiredTables: boolean = false;\r\n\r\n companiesDataSource$: Observable = Observable\r\n .create((observer: any) => { observer.next(this.companyFilter); })\r\n .pipe(mergeMap((token: string) => this._filterCompanies(token)))\r\n .pipe(map((result: Compliance.QueryResultModel) => result.data));\r\n\r\n selectedGridSourceOption = this._GRID_SOURCE_OPTION_SYSTEM;\r\n gridSourceOptions: Compliance.NameValuePair[] = [\r\n this._GRID_SOURCE_OPTION_SYSTEM,\r\n this._GRID_SOURCE_OPTION_COMPANY\r\n ];\r\n\r\n exportOptions: AgGridExportOptions = {\r\n canCancel: false,\r\n disabled: false,\r\n clientSideExport: () => {\r\n return {\r\n fileName: 'FactorTableExport.csv',\r\n processCellCallback: (params: ProcessCellForExportParams) => {\r\n const field = params.column.getColDef().field;\r\n const factorTableGridItem = params.node.data as Compliance.FactorTableListItemModel;\r\n switch (field) {\r\n case 'assessorName':\r\n if (!factorTableGridItem) {\r\n return '';\r\n }\r\n return factorTableGridItem.assessorName ? factorTableGridItem.assessorName : factorTableGridItem.state;\r\n default:\r\n return params.value;\r\n }\r\n }\r\n } as CsvExportParams;\r\n }\r\n };\r\n\r\n formatStates: WsSelectValueFormatter = (state: Compliance.FactorTableStateModel) => `${state.stateName} (${state.stateAbbr})`;\r\n\r\n get canEdit(): boolean {\r\n if (!this.selectedState.value) {\r\n return false;\r\n }\r\n\r\n switch (this.selectedGridSourceOption.value) {\r\n case GridSourceOptionEnum.Company:\r\n return (\r\n this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW) ||\r\n this._restrictService.isInRole(Roles.COMPLIANCESETUPSVIEW) ||\r\n this._restrictService.isInRole(Roles.COMPLIANCESETUPSEDIT)) &&\r\n this.hasCompanyWritePermission;\r\n case GridSourceOptionEnum.System:\r\n return this._restrictService.isInRole(Roles.COMPLIANCESETUPSEDIT);\r\n }\r\n }\r\n\r\n get canExportAttachments(): boolean {\r\n switch (this.selectedGridSourceOption.value) {\r\n case GridSourceOptionEnum.Company:\r\n return (\r\n this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW) ||\r\n this._restrictService.isInRole(Roles.COMPLIANCESETUPSVIEW) ||\r\n this._restrictService.isInRole(Roles.COMPLIANCESETUPSEDIT)) &&\r\n this.hasCompanyWritePermission;\r\n case GridSourceOptionEnum.System:\r\n return this._restrictService.isInRole(Roles.COMPLIANCESETUPSEDIT);\r\n }\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this.tableTypes = [\r\n { name: 'Depreciation', value: Compliance.FactorTableTypeEnum.Depreciation },\r\n { name: 'Index', value: Compliance.FactorTableTypeEnum.Index }\r\n ];\r\n\r\n this.selectedTableType = this.tableTypes[0];\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Name',\r\n field: 'name',\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: (params) => {\r\n const factorTableGridItem = params.data as Compliance.FactorTableListItemModel;\r\n if (!factorTableGridItem) {\r\n return '';\r\n }\r\n return factorTableGridItem.assessorName ? factorTableGridItem.assessorName : factorTableGridItem.state;\r\n },\r\n cellClass: (params: ICellRendererParams): string => {\r\n const factorTableGridItem = params.data as Compliance.FactorTableListItemModel;\r\n if (!factorTableGridItem) {\r\n return '';\r\n }\r\n return factorTableGridItem.assessorName ? '' : 'assessor-state';\r\n }\r\n },\r\n {\r\n headerName: 'Life',\r\n field: 'life',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Retired Tax Year',\r\n field: 'retiredTaxYear',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Latest Available Factors',\r\n field: 'taxYearValues',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const factorTableGridItem = params.data as Compliance.FactorTableListItemModel;\r\n if (!factorTableGridItem) {\r\n return '';\r\n }\r\n return factorTableGridItem.taxYear && factorTableGridItem.taxYear < this.selectedTaxYear.value ? 'factors-prior-year' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Latest Floor Values',\r\n field: 'floorValues',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(5),\r\n minWidth: AgGridColumns.getActionColumnWidth(5),\r\n maxWidth: AgGridColumns.getActionColumnWidth(5),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: FactorTableListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this.viewDetails.bind(this),\r\n delete: this.delete.bind(this),\r\n copy: this.copy.bind(this),\r\n canEdit: () => this.canEdit\r\n } as ICellRendererParamsForFactorTableListGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'assessorName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._gridApi.sizeColumnsToFit();\r\n await this._refresh();\r\n }\r\n\r\n stateTracker(index: number, factorTableStateModel: Compliance.FactorTableStateModel): number {\r\n return factorTableStateModel.stateId;\r\n }\r\n\r\n async setSelectedGridSourceOption(gridSourceOption: Compliance.NameValuePair): Promise {\r\n if (this.selectedCompany.value) {\r\n this.companyFilter = '';\r\n this.selectedCompany.setValue(null);\r\n this.selectedCompanyId = null;\r\n this.hasCompanyWritePermission = false;\r\n }\r\n\r\n this.selectedGridSourceOption = gridSourceOption;\r\n\r\n await this._refresh();\r\n }\r\n\r\n async onSelectedTableTypeChange(): Promise {\r\n await this._refresh();\r\n }\r\n\r\n async onCompanySelected(typeAheadMatch: TypeaheadMatch): Promise {\r\n const company = typeAheadMatch.item as Core.CompanyInfoModel;\r\n this.selectedCompany.setValue(company);\r\n\r\n this.selectedCompanyId = company.companyId;\r\n this.hasCompanyWritePermission = company.writeAllowed;\r\n\r\n await this._refresh();\r\n }\r\n\r\n async onCompanyBlur(): Promise {\r\n if (!this.companyFilter || this.companyFilter.trim() === '') {\r\n this.selectedCompany.setValue(null);\r\n\r\n this.selectedCompanyId = null;\r\n this.hasCompanyWritePermission = false;\r\n\r\n await this._refresh();\r\n }\r\n }\r\n\r\n onCompanyLoadingChange(isLoading: boolean): void {\r\n this.companiesLoading = isLoading;\r\n }\r\n\r\n async onSelectedStateChanged(): Promise {\r\n await this._refresh();\r\n }\r\n\r\n async onSelectedTaxYearChanged(): Promise {\r\n await this._refresh();\r\n }\r\n\r\n async addNew(): Promise {\r\n await this._showModal();\r\n }\r\n\r\n async refresh(): Promise {\r\n await this._refresh();\r\n }\r\n\r\n async viewDetails(params: ICellRendererParamsForFactorTableListGridAction): Promise {\r\n await this._showModal(params.data as Compliance.FactorTableListItemModel);\r\n }\r\n\r\n async delete(params: ICellRendererParamsForFactorTableListGridAction, force: boolean = false): Promise {\r\n if (!force) {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to delete the factor table?',\r\n 'Confirm Delete');\r\n } catch (e1) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting Factor Table' });\r\n let confirmMessage: string = '';\r\n const factorTableGridItem = params.data as Compliance.FactorTableListItemModel;\r\n\r\n try {\r\n await lastValueFrom(this._factorTableRepository.delete(factorTableGridItem.factorTableId, force));\r\n await this._refresh();\r\n return Promise.resolve();\r\n }\r\n catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n confirmMessage = e2.error.message;\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n confirmMessage,\r\n 'Confirm Delete');\r\n }\r\n catch(e3) {\r\n return Promise.resolve();\r\n }\r\n\r\n // force\r\n await this.delete(params, true);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async onIncludeRetiredTablesChanged(): Promise{\r\n await this._refresh(false);\r\n }\r\n\r\n async copy(params: ICellRendererParamsForFactorTableListGridAction): Promise {\r\n await this._showModal(params.data as Compliance.FactorTableListItemModel, true);\r\n }\r\n\r\n private async _refresh(reloadStates: boolean = true): Promise {\r\n this.refreshing = true;\r\n if (reloadStates){\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n try {\r\n this.states = await lastValueFrom(this._factorTableRepository.getStates());\r\n\r\n if (this.selectedState.value) {\r\n this.selectedState.setValue(_.find(this.states,\r\n (x) => { return x.stateId === this.selectedState.value.stateId; }));\r\n }\r\n\r\n this._setTaxYears();\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n this._factorTables = [];\r\n\r\n try {\r\n if (this.selectedState.value &&\r\n this.selectedState.value.stateId &&\r\n this.selectedTableType.value !== null &&\r\n this.selectedTaxYear.value &&\r\n (this.selectedGridSourceOption.value === GridSourceOptionEnum.System || this.selectedCompany.value)) {\r\n\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n\r\n const searchParams: Compliance.FactorTableSearchModel = {\r\n stateId: this.selectedState.value.stateId,\r\n tableType: this.selectedTableType.value,\r\n taxYear: this.selectedTaxYear.value,\r\n companyId: this.selectedCompany.value && this.selectedCompany.value.companyId,\r\n includeRetiredTables: this.includeRetiredTables\r\n };\r\n\r\n this._factorTables = await lastValueFrom(this._factorTableRepository.getList(searchParams));\r\n }\r\n } finally {\r\n this._gridApi && this._gridApi.hideOverlay();\r\n }\r\n\r\n this._setRowData();\r\n this.refreshing = false;\r\n }\r\n\r\n private _setTaxYears(): void {\r\n\r\n // set the list of tax years for the selected state by adding a tax year\r\n // for each year between the earliest factor table record and the current year\r\n\r\n this.taxYears = [];\r\n let minTaxYear = this._currentYear;\r\n let maxTaxYear: number = null;\r\n\r\n if (this.selectedState.value) {\r\n const selectedState = this.selectedState.value as Compliance.FactorTableStateModel;\r\n switch (this.selectedTableType.value) {\r\n case Compliance.FactorTableTypeEnum.Index:\r\n if (selectedState.indexTableMinTaxYear) {\r\n minTaxYear = selectedState.indexTableMinTaxYear;\r\n maxTaxYear = selectedState.indexTableMaxTaxYear;\r\n }\r\n break;\r\n case Compliance.FactorTableTypeEnum.Depreciation:\r\n if (selectedState.depreciationTableMinTaxYear) {\r\n minTaxYear = selectedState.depreciationTableMinTaxYear;\r\n maxTaxYear = selectedState.depreciationTableMaxTaxYear;\r\n }\r\n break;\r\n }\r\n }\r\n\r\n if (!maxTaxYear) {\r\n maxTaxYear = this._currentYear;\r\n }\r\n\r\n for (let year = maxTaxYear; year >= minTaxYear; year--) {\r\n this.taxYears.push(year);\r\n }\r\n\r\n // persist the selected tax year or set to current year if the selected tax year is not in the list\r\n if (!this.selectedTaxYear || !_.find(this.taxYears, (x) => { return x === this.selectedTaxYear.value; })) {\r\n this.selectedTaxYear.setValue(maxTaxYear);\r\n }\r\n }\r\n\r\n private _setRowData() {\r\n if (!(this._gridApi && this._factorTables)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._factorTables);\r\n }\r\n\r\n private _filterCompanies(searchValue: string): Observable> {\r\n const searchModel: Core.CompanyInfoSearchModel = {\r\n columnFilters: [{\r\n filterProperty: Core.CompanyInfoPropertyEnum.CompanyName,\r\n filterValues: [\r\n {\r\n filterType: Core.FilterTypeEnum.Contains,\r\n filterValue: searchValue\r\n }]\r\n }],\r\n topLevelOnly: true,\r\n preparePPReturnsOnly: true\r\n };\r\n\r\n return from(lastValueFrom(this._companyRepository.searchCompanyInfo(searchModel)));\r\n }\r\n\r\n private async _showModal(factorTableDetailModel?: Compliance.FactorTableListItemModel, isCopyFrom: boolean = false): Promise {\r\n const params: FactorTableDetailsParams = {\r\n factorTableId: factorTableDetailModel && factorTableDetailModel.factorTableId,\r\n editMode: this.canEdit,\r\n newFactorTableParams: {\r\n source: this.selectedGridSourceOption.value,\r\n stateId: this.selectedState.value && this.selectedState.value.stateId,\r\n company: this.selectedCompany.value,\r\n isCopyFrom: isCopyFrom\r\n }\r\n };\r\n\r\n const result = await this._modalService.showAsync(FactorTableDetailsComponent, params, 'modal-xl');\r\n\r\n if (!(result && result.hasChanges)) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._refresh(); // refresh all because tax years might have changed\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async exportAttachments(): Promise {\r\n const result = await this._modalService.showAsync(FactorTableExportAttachmentsComponent, null, 'modal-xl');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._factorTableExportAttachmentsLongRunningProcessId = await lastValueFrom(this._factorTableRepository.exportAttachments(result));\r\n this._snackBarService.addById(this._factorTableExportAttachmentsLongRunningProcessId, Compliance.LongRunningProcessTypeEnum.FactorTableExportAttachments);\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","export enum FormTypeEnum {\r\n Appeal = Compliance.FormTypeEnum.Appeal as number,\r\n // Breaks if you call it \"Compliance\" because that's also the namespace name\r\n ComplianceType = Compliance.FormTypeEnum.Compliance as number\r\n}","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const FORM_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'form.is-form-consolidated',\r\n tooltipText: 'Consolidated Form'\r\n },\r\n {\r\n helpContentId: 'form.all-assessors-certified',\r\n tooltipText: 'All assessors are certified.'\r\n },\r\n {\r\n helpContentId: 'form.not-all-assessors-certified',\r\n tooltipText: 'Not all assessors are certified.'\r\n },\r\n {\r\n helpContentId: 'form.electronic-filing-type-state',\r\n tooltipText: 'PropertyPoint does not currently support electronic filings for this state.'\r\n },\r\n {\r\n helpContentId: 'form.electronic-filing-is-supported',\r\n tooltipText: 'Electronic filing of this form is supported.'\r\n },\r\n {\r\n helpContentId: 'form.electronic-filing-type-locked-batch',\r\n tooltipText: 'Electronic Filing Type cannot be modified because this form revision is in use in one or more locked batches.'\r\n },\r\n];\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { FormRepository } from '../../Repositories/form.repository';\r\nimport { StateService } from '../../../Common/States/States.Service';\r\nimport { StateSummary } from '../../../Common/States/state.model';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Constants } from '../../../constants.new';\r\nimport { FormTypeEnum } from '../Models/enums';\r\nimport { AppealLevel } from '../../../Annual-Details/Appeals/appeal.model';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { YearPickerMixin } from '../../../UI-Lib/Mixins';\r\nimport * as _ from 'lodash';\r\nimport { ElectronicFilingRepository } from '../../Repositories'\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { FORM_HELP } from '../form.help';\r\n\r\nexport enum FormType {\r\n Form = 0,\r\n FormRevision = 1,\r\n SupplementalForm = 2\r\n}\r\n\r\nexport enum FormMode {\r\n Create = 0,\r\n Edit = 1\r\n}\r\n\r\nexport interface FormDetailsParams {\r\n type: FormType;\r\n mode: FormMode;\r\n stateId: number;\r\n formId?: number;\r\n formTypeId: Compliance.FormTypeEnum;\r\n formName?: string;\r\n formDescription?: string;\r\n revisionId?: number;\r\n revisionName?: string;\r\n revisionDescription?: string;\r\n supplementalFormName?: string;\r\n supplementalFormDescription?: string;\r\n taxYear?: number;\r\n canEdit: boolean;\r\n appealLevelId?: number;\r\n appealLevels?: AppealLevel[];\r\n allFormRevisions?: Compliance.FormRevisionModel[];\r\n priorFormRevisionId?: number;\r\n revisionStampLocationId: number;\r\n stampLocations: Compliance.FormRevisionStampLocationModel[];\r\n supportsNBVReporting?: boolean;\r\n supportsEstFMVReporting?: boolean;\r\n electronicFilingTypeId?: Compliance.ElectronicFilingTypeEnum;\r\n isFormRevisionInLockedBatch: boolean;\r\n}\r\n\r\nexport interface FormDetailsResult {\r\n newFormRevision: Compliance.FormRevisionModel;\r\n}\r\n\r\n@Component({\r\n selector: 'form-details',\r\n templateUrl: './formDetails.component.html'\r\n})\r\nexport class FormDetailsComponent extends YearPickerMixin() implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _toastsManager: ToastrService,\r\n private readonly _stateService: StateService,\r\n private readonly _formRepository: FormRepository,\r\n private readonly _electronicFilingRepository: ElectronicFilingRepository,\r\n private readonly _helpService: HelpService,\r\n private readonly _constants: Constants) {\r\n super();\r\n }\r\n\r\n params: FormDetailsParams;\r\n result: FormDetailsResult;\r\n\r\n FormTypeEnum = FormTypeEnum;\r\n selectedStateId: number;\r\n formTypes = this._constants.FormTypes;\r\n formType = FormType;\r\n formMode = FormMode;\r\n states: StateSummary[];\r\n electronicFilingTypes: Compliance.ElectronicFilingTypeModel[];\r\n doesStateHaveElectronicFilingType: boolean;\r\n formTitle: string;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n initialFormRevisionNameIfEdit: string;\r\n priorFormRevisions: Compliance.FormRevisionModel[];\r\n\r\n get modalTitle(): string {\r\n const modeText = (this.params.mode === FormMode.Create) ? 'New ' : '';\r\n return `${modeText}${this.formTitle}`;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(FORM_HELP);\r\n\r\n const busyMsgLoad = 'load';\r\n this.busyIndicatorMessageManager.add(`Loading`, busyMsgLoad);\r\n\r\n // Convert to boolean in case of null\r\n this.params.supportsNBVReporting = !!this.params.supportsNBVReporting;\r\n this.params.supportsEstFMVReporting = !!this.params.supportsEstFMVReporting;\r\n\r\n try {\r\n if (this.params.stateId) {\r\n this.selectedStateId = this.params.stateId;\r\n }\r\n switch (this.params.type) {\r\n case FormType.Form:\r\n this.formTitle = 'Form';\r\n break;\r\n case FormType.FormRevision:\r\n this.formTitle = 'Revision';\r\n break;\r\n case FormType.SupplementalForm:\r\n this.formTitle = 'Supplemental Form';\r\n break;\r\n }\r\n\r\n if (this.params.mode === FormMode.Edit && this.params.type === FormType.FormRevision) {\r\n this.initialFormRevisionNameIfEdit = this.params.revisionName;\r\n }\r\n\r\n if (this.params.mode === FormMode.Edit && this.params.type === FormType.SupplementalForm) {\r\n this.initialFormRevisionNameIfEdit = this.params.supplementalFormName;\r\n }\r\n\r\n this.priorFormRevisions = _.filter(this.params.allFormRevisions, x => x.formRevisionId !== this.params.revisionId);\r\n\r\n this.states = await this._stateService.getSummary();\r\n\r\n this.electronicFilingTypes = await lastValueFrom(this._electronicFilingRepository.getElectronicFilingTypes(this.params.stateId));\r\n this.doesStateHaveElectronicFilingType = !!this.electronicFilingTypes?.length;\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgLoad);\r\n }\r\n }\r\n\r\n formTypesEqual(a: Compliance.FormTypeEnum, b: FormTypeEnum): boolean {\r\n return (a as number) === (b as number);\r\n }\r\n\r\n getElectronicFilingTypeHelpContentId(){\r\n if(!this.doesStateHaveElectronicFilingType){\r\n return 'form.electronic-filing-type-state';\r\n }\r\n\r\n if(this.params.isFormRevisionInLockedBatch){\r\n return 'form.electronic-filing-type-locked-batch';\r\n }\r\n\r\n return '';\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgSave = 'save';\r\n this.busyIndicatorMessageManager.add(`Saving ${this.formTitle}`, busyMsgSave);\r\n\r\n try {\r\n //todo: move validation to reactive forms\r\n switch (this.params.mode) {\r\n case FormMode.Create:\r\n switch (this.params.type) {\r\n case FormType.Form:\r\n if (!this.params.formName) {\r\n this._toastsManager.error('Form Name is required.');\r\n return;\r\n }\r\n\r\n if (!this.params.formTypeId) {\r\n this._toastsManager.error('Form Type is required.');\r\n return;\r\n }\r\n\r\n if (!this.params.taxYear) {\r\n this._toastsManager.error('Tax Year is required.');\r\n return;\r\n }\r\n\r\n if (!this.params.revisionName) {\r\n this._toastsManager.error('Revision Name is required.');\r\n return;\r\n }\r\n\r\n if (!this.params.revisionStampLocationId) {\r\n this._toastsManager.error('Stamp Location is required.');\r\n return;\r\n }\r\n\r\n if (this.params.formTypeId === Compliance.FormTypeEnum.Appeal && !this.params.appealLevelId) {\r\n this._toastsManager.error('Appeal Level is required.');\r\n return;\r\n }\r\n\r\n const formCreateModel: Compliance.FormCreateModel = {\r\n stateId: this.params.stateId,\r\n taxYear: this.params.taxYear,\r\n appealLevelId: this.params.appealLevelId,\r\n name: this.params.formName,\r\n description: this.params.formDescription,\r\n formTypeId: this.params.formTypeId,\r\n revisionName: this.params.revisionName,\r\n revisionDescription: this.params.revisionDescription,\r\n revisionPriorFormRevisionId: this.params.priorFormRevisionId,\r\n revisionStampLocationId: this.params.revisionStampLocationId,\r\n supportsNBVReporting: this.params.supportsNBVReporting,\r\n supportsEstFMVReporting: this.params.supportsEstFMVReporting,\r\n electronicFilingTypeId: this.params.electronicFilingTypeId\r\n };\r\n\r\n const form = await lastValueFrom(this._formRepository.createForm(formCreateModel));\r\n\r\n this.result = {\r\n newFormRevision: form.formRevisions[0]\r\n };\r\n\r\n this._bsModalRef.hide();\r\n break;\r\n case FormType.FormRevision:\r\n if (!this.params.revisionName) {\r\n this._toastsManager.error('Revision Name is required.');\r\n return;\r\n }\r\n\r\n if (!this.params.taxYear) {\r\n this._toastsManager.error('Tax Year is required.');\r\n return;\r\n }\r\n\r\n if (!this.params.revisionStampLocationId) {\r\n this._toastsManager.error('Stamp Location is required.');\r\n return;\r\n }\r\n\r\n if (this.params.formTypeId === Compliance.FormTypeEnum.Appeal && !this.params.appealLevelId) {\r\n this._toastsManager.error('Appeal Level is required.');\r\n return;\r\n }\r\n\r\n const revisionCreateModel: Compliance.FormRevisionCreateModel = {\r\n formId: this.params.formId,\r\n name: this.params.revisionName,\r\n description: this.params.revisionDescription,\r\n taxYear: this.params.taxYear,\r\n appealLevelId: this.params.appealLevelId,\r\n priorFormRevisionId: this.params.priorFormRevisionId,\r\n formRevisionStampLocationId: this.params.revisionStampLocationId,\r\n supportsNBVReporting: this.params.supportsNBVReporting,\r\n supportsEstFMVReporting: this.params.supportsEstFMVReporting,\r\n electronicFilingTypeId: this.params.electronicFilingTypeId\r\n };\r\n\r\n const revision = await lastValueFrom(this._formRepository.createRevisionSupplementalForm(revisionCreateModel));\r\n\r\n this.result = {\r\n newFormRevision: revision\r\n };\r\n\r\n this._bsModalRef.hide();\r\n break;\r\n case FormType.SupplementalForm:\r\n if (!this.params.supplementalFormName) {\r\n this._toastsManager.error('Form Name is required.');\r\n return;\r\n }\r\n\r\n if (!this.params.taxYear) {\r\n this._toastsManager.error('Tax Year is required.');\r\n return;\r\n }\r\n\r\n if (!this.params.revisionStampLocationId) {\r\n this._toastsManager.error('Stamp Location is required.');\r\n return;\r\n }\r\n\r\n const supplementalCreateModel: Compliance.FormRevisionCreateModel = {\r\n formId: this.params.formId,\r\n parentRevisionId: this.params.revisionId,\r\n name: this.params.supplementalFormName,\r\n description: this.params.supplementalFormDescription,\r\n taxYear: this.params.taxYear,\r\n priorFormRevisionId: this.params.priorFormRevisionId,\r\n appealLevelId: this.params.appealLevelId,\r\n formRevisionStampLocationId: this.params.revisionStampLocationId,\r\n supportsNBVReporting: this.params.supportsNBVReporting,\r\n supportsEstFMVReporting: this.params.supportsEstFMVReporting,\r\n electronicFilingTypeId: this.params.electronicFilingTypeId\r\n };\r\n\r\n const supplement = await lastValueFrom(this._formRepository.createRevisionSupplementalForm(supplementalCreateModel));\r\n\r\n this.result = {\r\n newFormRevision: supplement\r\n };\r\n\r\n this._bsModalRef.hide();\r\n break;\r\n }\r\n break;\r\n case FormMode.Edit:\r\n switch (this.params.type) {\r\n case FormType.Form:\r\n if (!this.params.formName) {\r\n this._toastsManager.error('Form Name is required.');\r\n return;\r\n }\r\n\r\n const formUpdateModel: Compliance.FormUpdateModel = {\r\n name: this.params.formName,\r\n description: this.params.formDescription\r\n };\r\n\r\n await lastValueFrom(this._formRepository.updateForm(this.params.formId, formUpdateModel));\r\n\r\n this.result = {\r\n newFormRevision: null\r\n };\r\n\r\n this._bsModalRef.hide();\r\n break;\r\n case FormType.FormRevision:\r\n if (!this.params.revisionName) {\r\n this._toastsManager.error('Revision Name is required.');\r\n return;\r\n }\r\n\r\n if (!this.params.revisionStampLocationId) {\r\n this._toastsManager.error('Stamp Location is required.');\r\n return;\r\n }\r\n\r\n const revisionUpdateModel: Compliance.FormRevisionUpdateModel = {\r\n name: this.params.revisionName,\r\n description: this.params.revisionDescription,\r\n priorFormRevisionId: this.params.priorFormRevisionId,\r\n formRevisionStampLocationId: this.params.revisionStampLocationId,\r\n supportsNBVReporting: this.params.supportsNBVReporting,\r\n supportsEstFMVReporting: this.params.supportsEstFMVReporting,\r\n electronicFilingTypeId: this.params.electronicFilingTypeId\r\n };\r\n\r\n await lastValueFrom(this._formRepository.updateFormRevision(this.params.revisionId, revisionUpdateModel, true));\r\n\r\n this.result = {\r\n newFormRevision: null\r\n };\r\n\r\n this._bsModalRef.hide();\r\n\r\n break;\r\n case FormType.SupplementalForm:\r\n if (!this.params.supplementalFormName) {\r\n this._toastsManager.error('Form Name is required.');\r\n return;\r\n }\r\n\r\n if (!this.params.revisionStampLocationId) {\r\n this._toastsManager.error('Stamp Location is required.');\r\n return;\r\n }\r\n\r\n const supplementalUpdateModel: Compliance.FormRevisionUpdateModel = {\r\n name: this.params.supplementalFormName,\r\n description: this.params.supplementalFormDescription,\r\n priorFormRevisionId: this.params.priorFormRevisionId,\r\n formRevisionStampLocationId: this.params.revisionStampLocationId,\r\n supportsNBVReporting: this.params.supportsNBVReporting,\r\n supportsEstFMVReporting: this.params.supportsEstFMVReporting,\r\n electronicFilingTypeId: this.params.electronicFilingTypeId\r\n };\r\n\r\n await lastValueFrom(this._formRepository.updateFormRevision(this.params.revisionId, supplementalUpdateModel, true));\r\n\r\n this.result = {\r\n newFormRevision: null\r\n };\r\n\r\n this._bsModalRef.hide();\r\n break;\r\n }\r\n break;\r\n }\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgSave);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n"," 0\" [message]=\"busyMessageManager.message\">\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { FormSetupRepository } from '../../Repositories';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'form-setup-upload',\r\n templateUrl: './formSetupUpload.component.html'\r\n})\r\nexport class FormSetupUploadComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formSetupRepository: FormSetupRepository\r\n ) { }\r\n\r\n params: void;\r\n result: number;\r\n\r\n busyMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n file: File;\r\n replaceTargetFormRevision: boolean;\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n filePicked(files: File[]): void {\r\n this.file = files[0];\r\n }\r\n\r\n async upload(): Promise {\r\n this.busyMessageManager.add('Uploading', 'uploading');\r\n\r\n try {\r\n const fileMetadata = {\r\n fileName: this.file.name,\r\n replaceTargetFormRevision: this.replaceTargetFormRevision\r\n } as Compliance.FormSetupUploadModel;\r\n\r\n this.result = await lastValueFrom(this._formSetupRepository.import(this.file, fileMetadata));\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyMessageManager.remove('uploading');\r\n }\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { FormSetupRepository } from '../../Repositories';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../AgGrid/MultiSelectTracker';\r\nimport { lastValueFrom, Subscription } from 'rxjs';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../AgGrid';\r\nimport { WeissmanDateTimeFormatPipe } from '../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\n\r\n@Component({\r\n selector: 'form-setup-download',\r\n templateUrl: './formSetupDownload.component.html',\r\n styleUrls: ['./formSetupDownload.component.scss']\r\n})\r\nexport class FormSetupDownloadComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formSetupRepository: FormSetupRepository,\r\n private readonly _dateTimePipe: WeissmanDateTimeFormatPipe) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n private _formRevisions: Compliance.FormSetupDownloadFormRevisionModel[];\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.FormSetupDownloadFormRevisionModel).formRevisionId)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n params: void;\r\n result: number[];\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n rowsSelected: boolean = false;\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n const busyMsg = 'Loading';\r\n\r\n this.busyIndicatorMessageManager.add('Loading', busyMsg);\r\n try {\r\n this._formRevisions = await lastValueFrom(this._formSetupRepository.getFormRevisions());\r\n }\r\n finally{\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n this._setRowData();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.rowsSelected = x.selectAllRows || x.selectedRows.length > 0;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'formRevisionId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'stateAbbr',\r\n width: AgGridColumns.stateAbbreviationColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Form',\r\n field: 'formName',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Form Revision',\r\n field: 'formRevisionName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Is Supplemental',\r\n field: 'isSupplementalForm',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Changed By',\r\n field: 'changedBy',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Changed Date',\r\n field: 'changeDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: x => this._dateTimePipe.transform(x.value, true),\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'stateAbbr',\r\n sort: 'asc'\r\n },\r\n {\r\n colId: 'formName',\r\n sort: 'asc'\r\n },\r\n {\r\n colId: 'formRevisionName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n async export(): Promise {\r\n this.result = await this.gridTracker.getSelectedRowIds();\r\n\r\n this._bsModalRef.hide();\r\n return Promise.resolve();\r\n }\r\n\r\n private _setRowData() {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._formRevisions);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map((x) => {\r\n const formRevision = x.data as Compliance.FormSetupDownloadFormRevisionModel;\r\n return formRevision && formRevision.formRevisionId;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { FormRepository } from '../../Repositories';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\n@Component({\r\n selector: 'export-form-list',\r\n templateUrl: './exportFormList.component.html'\r\n }\r\n)\r\nexport class ExportFormListComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formRepository: FormRepository) {\r\n }\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n isInitialized: boolean = false;\r\n fileTypes: Compliance.NameValuePair[] = [\r\n { name: 'All', value: 0 },\r\n { name: 'Appeals', value: Compliance.FormTypeEnum.Appeal },\r\n { name: 'Compliance', value: Compliance.FormTypeEnum.Compliance }\r\n ];\r\n statuses: Compliance.NameValuePair[] = [\r\n { name: 'All', value: Compliance.ExportFormStatusEnum.All },\r\n { name: 'Certified', value: Compliance.ExportFormStatusEnum.Certified },\r\n { name: 'Not-Certified', value: Compliance.ExportFormStatusEnum.NotCertified }\r\n ];\r\n taxYears: number[] = [];\r\n status: Compliance.ExportFormStatusEnum = Compliance.ExportFormStatusEnum.All;\r\n taxYear: number;\r\n params: void;\r\n result: number;\r\n fileType: Compliance.FormTypeEnum = 0;\r\n\r\n ngOnInit(): void {\r\n this.taxYear = new Date().getFullYear();\r\n\r\n for (let i = 2; i >= -2; i--) {\r\n this.taxYears.push(this.taxYear + i);\r\n }\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n async export(): Promise {\r\n const message = \"Exporting Form List\";\r\n this.busyIndicatorMessageManager.add(message, message);\r\n\r\n try{\r\n const model: Compliance.ExportFormListModel = {\r\n taxYear: this.taxYear,\r\n status: this.status,\r\n formType: this.fileType\r\n };\r\n\r\n this.result = await lastValueFrom(this._formRepository.exportFormList(model));\r\n\r\n this._bsModalRef.hide();\r\n return Promise.resolve();\r\n }\r\n finally {\r\n this.busyIndicatorMessageManager.remove(message);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../AgGrid/MultiSelectTracker';\r\nimport { lastValueFrom, Subscription } from 'rxjs';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../AgGrid';\r\nimport { WeissmanDateTimeFormatPipe } from '../../../UI-Lib/Pipes';\r\nimport { FormLibraryRepository } from '../../Repositories/formLibraryRepository';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../AgGrid/ToolPanel/models';\r\nimport { GridHelper } from '../../AgGrid/GridHelper';\r\n\r\n@Component({\r\n selector: 'form-library-export',\r\n templateUrl: './formLibraryExport.component.html',\r\n styleUrls: ['./formLibraryExport.component.scss']\r\n})\r\nexport class FormLibraryExportComponent implements IWeissmanModalComponent, OnInit, OnDestroy {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formLibraryRepository: FormLibraryRepository,\r\n private readonly _dateTimePipe: WeissmanDateTimeFormatPipe) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n private _formRevisions: Compliance.FormRevisionForLibraryModel[];\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'formRevisionId', value: Compliance.FormRevisionForLibraryPropertyEnum.FormRevisionId },\r\n { name: 'formTypeName', value: Compliance.FormRevisionForLibraryPropertyEnum.FormTypeName },\r\n { name: 'stateAbbr', value: Compliance.FormRevisionForLibraryPropertyEnum.StateAbbr },\r\n { name: 'taxYearsRange', value: Compliance.FormRevisionForLibraryPropertyEnum.TaxYearsRange },\r\n { name: 'formName', value: Compliance.FormRevisionForLibraryPropertyEnum.FormName },\r\n { name: 'formRevisionName', value: Compliance.FormRevisionForLibraryPropertyEnum.FormRevisionName },\r\n { name: 'isSupplementalForm', value: Compliance.FormRevisionForLibraryPropertyEnum.IsSupplementalForm },\r\n { name: 'changedBy', value: Compliance.FormRevisionForLibraryPropertyEnum.ChangedBy },\r\n { name: 'changeDate', value: Compliance.FormRevisionForLibraryPropertyEnum.ChangeDate }\r\n ];\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridId: System.Guid = '8EE28900-B379-4A8E-A9F4-B753C8A75BAA';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.FormSetupDownloadFormRevisionModel).formRevisionId)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const selectedRowIds = await this.gridTracker.getSelectedRowIds();\r\n const sortModel = this._gridApi.getSortModel();\r\n\r\n const model: Compliance.FormLibraryExportModel = {\r\n formRevisionIds: selectedRowIds,\r\n columnsToReturn: columnsToReturn.map(x => {\r\n return {name: x.value, value: GridHelper.getProperty(x.name, this._propertyMap)};\r\n }),\r\n exportFileType: fileFormat,\r\n sortColumns: GridHelper.getSortModel(sortModel, this._propertyMap)\r\n };\r\n\r\n const longRunningProcessId = await lastValueFrom(this._formLibraryRepository.export(model));\r\n\r\n const longRunningProcessTypeId = Compliance.LongRunningProcessTypeEnum.FormLibraryExport;\r\n\r\n this.cancel();\r\n\r\n return { longRunningProcessId, longRunningProcessTypeId };\r\n },\r\n canCancel: true,\r\n showFileFormatSelection: true,\r\n availableFileFormats: [Compliance.ExportFileFormatEnum.Excel, Compliance.ExportFileFormatEnum.PDF],\r\n getDisabled: () => !this.rowsSelected\r\n };\r\n\r\n params: void;\r\n result: number[];\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n rowsSelected: boolean = false;\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n const busyMsg = 'Loading';\r\n\r\n this.busyIndicatorMessageManager.add('Loading', busyMsg);\r\n try {\r\n this._formRevisions = await lastValueFrom(this._formLibraryRepository.getFormRevisions());\r\n }\r\n finally{\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy() {\r\n this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.rowsSelected = x.selectAllRows || x.selectedRows.length > 0;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'formRevisionId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Form Type',\r\n field: 'formTypeName',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'stateAbbr',\r\n width: AgGridColumns.stateAbbreviationColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Tax Years',\r\n field: 'taxYearsRange',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n filterValueGetter: (params) => {\r\n console.log('params', params);\r\n const formRevision = params.data as Compliance.FormRevisionForLibraryModel;\r\n return formRevision != null ? formRevision.allTaxYears : null;\r\n }\r\n },\r\n {\r\n headerName: 'Form Name',\r\n field: 'formName',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Revision Name',\r\n field: 'formRevisionName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Is Supplemental',\r\n field: 'isSupplementalForm',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Changed By',\r\n field: 'changedBy',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Changed Date',\r\n field: 'changeDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: x => this._dateTimePipe.transform(x.value, true),\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'stateAbbr',\r\n sort: 'asc'\r\n },\r\n {\r\n colId: 'taxYearsRange',\r\n sort: 'asc'\r\n },\r\n {\r\n colId: 'formName',\r\n sort: 'asc'\r\n },\r\n {\r\n colId: 'formRevisionName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n async export(): Promise {\r\n this.result = await this.gridTracker.getSelectedRowIds();\r\n\r\n this._bsModalRef.hide();\r\n return Promise.resolve();\r\n }\r\n\r\n private _setRowData() {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._formRevisions);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map((x) => {\r\n const formRevision = x.data as Compliance.FormRevisionForLibraryModel;\r\n return formRevision && formRevision.formRevisionId;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, lastValueFrom, Observable, Subject } from 'rxjs';\r\nimport { AssetClassificationRepository, FormRepository } from '../Repositories';\r\nimport * as _ from 'lodash';\r\nimport { HttpResponse } from '@angular/common/http';\r\nimport { IExpandableComponentContainer } from '../../UI-Lib/Expandable-Component/expandableComponentContainer.model';\r\nimport { IExpandableComponent } from '../../UI-Lib/Expandable-Component/expandableComponent.model';\r\nimport { AppealService } from '../../Annual-Details/Appeals/appeal.service';\r\nimport { AppealLevel } from '../../Annual-Details/Appeals/appeal.model';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\n\r\n@Injectable()\r\nexport class FormService implements IExpandableComponentContainer {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _formRepository: FormRepository,\r\n private readonly _assetClassificationRepository: AssetClassificationRepository,\r\n private readonly _appealService: AppealService,\r\n private readonly _messageBoxService: MessageBoxService) {\r\n }\r\n\r\n // subjects\r\n private _formRevisionSubject = new BehaviorSubject(null);\r\n private _assessorSubject = new Subject();\r\n private _assessorsSubject = new Subject();\r\n private _assetClassificationMappingsSubject = new Subject();\r\n private _formRevisionYearsSubject = new Subject();\r\n private _formRevisionYearSubject = new Subject();\r\n private _schedulesSubject = new Subject();\r\n private _factorTablesSubject = new Subject();\r\n private _reportsSubject = new Subject();\r\n private _isInDevelopmentSubject = new Subject();\r\n private _isPrimarySubject = new Subject();\r\n private _anyAssessorMappingsCertifiedSubject = new Subject();\r\n\r\n // state\r\n private _canEdit: boolean = false;\r\n private _canView: boolean = false;\r\n private _defaultAssessor: Compliance.FormRevisionAssessorModel = null;\r\n private _factorTableAssessor: Compliance.FormRevisionAssessorModel = null;\r\n private _assessor: Compliance.FormRevisionAssessorModel = null;\r\n private _assessors: Compliance.FormRevisionAssessorModel[] = [];\r\n private _assetClassifications: Compliance.AssetClassificationModel[] = [];\r\n private _assetClassificationMappings: Compliance.FormClassificationMappingModel[] = [];\r\n private _formRevision: Compliance.FormRevisionModel = null;\r\n private _formRevisionYears: Compliance.FormRevisionYearModel[] = [];\r\n private _formRevisionYear: Compliance.FormRevisionYearModel;\r\n private _maxFormRevisionYear: Compliance.FormRevisionYearModel;\r\n private _minFormRevisionYear: Compliance.FormRevisionYearModel;\r\n private _schedules: Compliance.FormRevisionScheduleModel[] = [];\r\n private _factorTables: Compliance.FormFactorTableModel[] = [];\r\n private _allFactorTables: Compliance.FactorTableListItemModel[] = null;\r\n private _reports: Compliance.FormRevisionReportModel[] = [];\r\n private _allReports: Core.SavedSearchModel[] = null;\r\n private _lastFormRevision: Compliance.FormRevisionModel = null;\r\n private _isInitialized = false;\r\n private _expandedComponent: IExpandableComponent = null;\r\n private _validAppealPanels: string[] = ['form-assessor-list', 'form-template', 'dummy'];\r\n private _appealLevels: AppealLevel[] = [];\r\n private _anyAssessorMappingsCertified = false;\r\n private _templateValidationResult: Compliance.ReturnFormTemplateValidationResultModel = null;\r\n private _warnDefaultAssessorEdit: boolean = false;\r\n\r\n reset() {\r\n this._isInitialized = false;\r\n this._canEdit = false;\r\n this._canView = false;\r\n this._defaultAssessor = null;\r\n this._factorTableAssessor = null;\r\n this._assessors = [];\r\n this._assessor = null;\r\n this._assetClassifications = [];\r\n this._assetClassificationMappings = [];\r\n this._formRevision = null;\r\n this._formRevisionYears = [];\r\n this._formRevisionYear = null;\r\n this._maxFormRevisionYear = null;\r\n this._minFormRevisionYear = null;\r\n this._schedules = [];\r\n this._allFactorTables = [];\r\n this._factorTables = [];\r\n this._reports = [];\r\n this._allReports = [];\r\n this._appealLevels = [];\r\n this._expandedComponent = null;\r\n this._anyAssessorMappingsCertified = false;\r\n this._templateValidationResult = null;\r\n }\r\n\r\n // properties\r\n get editGroup(): string {\r\n return 'form-edit-group';\r\n }\r\n\r\n get isInitialized(): boolean {\r\n return this._isInitialized;\r\n }\r\n\r\n get canEdit(): boolean {\r\n return this._canEdit;\r\n }\r\n\r\n get canView(): boolean {\r\n return this._canView;\r\n }\r\n\r\n get defaultAssessor(): Compliance.FormRevisionAssessorModel {\r\n return this._defaultAssessor;\r\n }\r\n\r\n get defaultAssessorId(): number {\r\n return this._defaultAssessor && this._defaultAssessor.formRevisionYearAssessorId;\r\n }\r\n\r\n get factorTableAssessor(): Compliance.FormRevisionAssessorModel {\r\n return this._factorTableAssessor;\r\n }\r\n\r\n get factorTableAssessorId(): number {\r\n return this.factorTableAssessor && this._factorTableAssessor.formRevisionYearAssessorId;\r\n }\r\n\r\n get factorTablesAssessorName() {\r\n if (!this._assessor) {\r\n return '';\r\n }\r\n\r\n if (!this._assessor.assessorId) {\r\n return this._defaultAssessor && this._defaultAssessor.assessorName;\r\n }\r\n\r\n return this._assessor.isUsingDefaultTables\r\n ? this._defaultAssessor && this._defaultAssessor.assessorName\r\n : this._assessor.assessorName;\r\n }\r\n\r\n get classificationMappingsAssessorName() {\r\n if (!this._assessor) {\r\n return '';\r\n }\r\n\r\n if (!this._assessor.assessorId) {\r\n return this._defaultAssessor && this._defaultAssessor.assessorName;\r\n }\r\n\r\n return this._assessor.isUsingDefaultMappings\r\n ? this._defaultAssessor && this._defaultAssessor.assessorName\r\n : this._assessor.assessorName;\r\n }\r\n\r\n get assessor(): Compliance.FormRevisionAssessorModel {\r\n return this._assessor;\r\n }\r\n\r\n get assessorName(): string {\r\n return this._assessor && this._assessor.assessorName;\r\n }\r\n\r\n get assessorId(): number {\r\n return this._assessor && this._assessor.formRevisionYearAssessorId;\r\n }\r\n\r\n get assessors(): Compliance.FormRevisionAssessorModel[] {\r\n return this._assessors;\r\n }\r\n\r\n get assetClassifications(): Compliance.AssetClassificationModel[] {\r\n return this._assetClassifications;\r\n }\r\n\r\n get assetClassificationMappings(): Compliance.FormClassificationMappingModel[] {\r\n return this._assetClassificationMappings;\r\n }\r\n\r\n get formRevision(): Compliance.FormRevisionModel {\r\n return this._formRevision;\r\n }\r\n\r\n get formRevisionId(): number {\r\n return this._formRevision && this._formRevision.formRevisionId;\r\n }\r\n\r\n get formRevisionStateId(): number {\r\n return this._formRevision && this._formRevision.stateId;\r\n }\r\n\r\n get lastFormRevision(): Compliance.FormRevisionModel {\r\n return this._lastFormRevision;\r\n }\r\n\r\n get isPrimary(): boolean {\r\n return this._formRevisionYear && this._formRevisionYear.isPrimary;\r\n }\r\n\r\n get isInDevelopment(): boolean {\r\n return this._formRevisionYear && this._formRevisionYear.isInDevelopment;\r\n }\r\n\r\n get formRevisionYears(): Compliance.FormRevisionYearModel[] {\r\n return this._formRevisionYears;\r\n }\r\n\r\n get formRevisionYear(): Compliance.FormRevisionYearModel {\r\n return this._formRevisionYear;\r\n }\r\n\r\n get taxYear(): number {\r\n return this._formRevisionYear && this._formRevisionYear.taxYear;\r\n }\r\n\r\n get maxFormRevisionYear(): Compliance.FormRevisionYearModel {\r\n return this._maxFormRevisionYear;\r\n }\r\n\r\n get minFormRevisionYear(): Compliance.FormRevisionYearModel {\r\n return this._minFormRevisionYear;\r\n }\r\n\r\n get isMaxFormRevisionYear(): boolean {\r\n return this._formRevisionYear && this._formRevisionYear === this._maxFormRevisionYear;\r\n }\r\n\r\n get isMinFormRevisionYear(): boolean {\r\n return this._formRevisionYear && this._formRevisionYear === this._minFormRevisionYear;\r\n }\r\n\r\n get schedules(): Compliance.FormRevisionScheduleModel[] {\r\n return this._schedules;\r\n }\r\n\r\n get factorTables(): Compliance.FormFactorTableModel[] {\r\n return this._factorTables;\r\n }\r\n\r\n get assessorsAvailableForAssignment(): Compliance.FormRevisionAssessorModel[] {\r\n return this._assessors.filter(x => !x.formRevisionYearAssessorId);\r\n }\r\n\r\n get assessorsAssigned(): Compliance.FormRevisionAssessorModel[] {\r\n return this._assessors.filter(x => x.formRevisionYearAssessorId);\r\n }\r\n\r\n get reports(): Compliance.FormRevisionReportModel[] {\r\n return this._reports;\r\n }\r\n\r\n get allReports(): Core.SavedSearchModel[] {\r\n return this._allReports;\r\n }\r\n\r\n get allFactorTables(): Compliance.FactorTableListItemModel[] {\r\n return this._allFactorTables;\r\n }\r\n\r\n get isFormTypeAppeal(): boolean {\r\n return this._formRevision && this._formRevision.formTypeId === Compliance.FormTypeEnum.Appeal;\r\n }\r\n\r\n get isFormTypeCompliance(): boolean {\r\n return this._formRevision && this._formRevision.formTypeId === Compliance.FormTypeEnum.Compliance;\r\n }\r\n\r\n get appealLevelId(): number {\r\n return this._formRevision && this._formRevision.appealLevelId;\r\n }\r\n\r\n get appealLevels(): AppealLevel[] {\r\n return this._appealLevels;\r\n }\r\n\r\n get anyAssessorMappingsCertified(): boolean {\r\n return this._anyAssessorMappingsCertified;\r\n }\r\n\r\n get templateValidationResult(): Compliance.ReturnFormTemplateValidationResultModel {\r\n return this._templateValidationResult;\r\n }\r\n\r\n get isPlaceholderTemplate(): boolean {\r\n return this._formRevision && this._formRevision.isPlaceholderTemplate;\r\n }\r\n\r\n get hasTemplateValidationErrors(): boolean {\r\n return !!(this._templateValidationResult && this._templateValidationResult.errors && this._templateValidationResult.errors.length);\r\n }\r\n\r\n get hasTemplateValidationWarnings(): boolean {\r\n return !!(this._templateValidationResult && this._templateValidationResult.warnings && this._templateValidationResult.warnings.length);\r\n }\r\n\r\n // observables\r\n get assessors$(): Observable {\r\n return this._assessorsSubject.asObservable();\r\n }\r\n\r\n get assessor$(): Observable {\r\n return this._assessorSubject.asObservable();\r\n }\r\n\r\n get formRevision$(): Observable {\r\n return this._formRevisionSubject.asObservable();\r\n }\r\n\r\n get formRevisionYears$(): Observable {\r\n return this._formRevisionYearsSubject.asObservable();\r\n }\r\n\r\n get formRevisionYear$(): Observable {\r\n return this._formRevisionYearSubject.asObservable();\r\n }\r\n\r\n get assetClassificationMappings$(): Observable {\r\n return this._assetClassificationMappingsSubject.asObservable();\r\n }\r\n\r\n get schedules$(): Observable {\r\n return this._schedulesSubject.asObservable();\r\n }\r\n\r\n get factorTables$(): Observable {\r\n return this._factorTablesSubject.asObservable();\r\n }\r\n\r\n get reports$(): Observable {\r\n return this._reportsSubject.asObservable();\r\n }\r\n\r\n get isInDevelopment$(): Observable {\r\n return this._isInDevelopmentSubject.asObservable();\r\n }\r\n\r\n get isPrimary$(): Observable {\r\n return this._isPrimarySubject.asObservable();\r\n }\r\n\r\n get anyAssessorMappingsCertified$(): Observable {\r\n return this._anyAssessorMappingsCertifiedSubject.asObservable();\r\n }\r\n\r\n // events raised by components\r\n setExpandedComponent(component: IExpandableComponent): void {\r\n this._expandedComponent = component;\r\n }\r\n\r\n isComponentExpanded(component: IExpandableComponent): boolean {\r\n return this._expandedComponent === component;\r\n }\r\n\r\n isExpanded(componentName: string): boolean {\r\n return this._expandedComponent && (this._expandedComponent.getName() === componentName);\r\n }\r\n\r\n isOtherComponentExpanded(componentName: string): boolean {\r\n return this._expandedComponent && (this._expandedComponent.getName() !== componentName);\r\n }\r\n\r\n isValidForAppeal(componentName: string): boolean {\r\n return this._formRevision && (!this.isFormTypeAppeal || _.includes(this._validAppealPanels, componentName));\r\n }\r\n\r\n async setAssessors(assessors: Compliance.FormRevisionAssessorModel[]): Promise {\r\n await this._setAssessors(assessors);\r\n this._assessorsSubject.next(this._assessors);\r\n }\r\n\r\n async setAssessor(assessor: Compliance.FormRevisionAssessorModel) {\r\n await this._setAssessor(assessor);\r\n this._assessorSubject.next(this._assessor);\r\n }\r\n\r\n async checkEditDefaultAssessor(): Promise {\r\n if (this._warnDefaultAssessorEdit) {\r\n const result = await this._messageBoxService.open({\r\n title: 'Edit default assessor',\r\n message: 'Are you sure you wish to edit the default assessor?',\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n this._warnDefaultAssessorEdit = false;\r\n return result === MessageBoxResult.Yes;\r\n }\r\n return true;\r\n }\r\n\r\n async loadFormRevision(formRevisionId: number, taxYear?: number): Promise {\r\n await this._loadFormRevision(formRevisionId, taxYear);\r\n this._formRevisionSubject.next(this._formRevision);\r\n }\r\n\r\n async setFormRevisionYear(formRevisionYear: Compliance.FormRevisionYearModel) {\r\n await this._setFormRevisionYear(formRevisionYear);\r\n this._formRevisionYearSubject.next(this._formRevisionYear);\r\n }\r\n\r\n async setFormRevisionAppealLevel(appealLevelId: number): Promise {\r\n await lastValueFrom(this._formRepository.updateAppealLevel(this._formRevision.formRevisionId, appealLevelId));\r\n this._formRevision.appealLevelId = appealLevelId;\r\n }\r\n\r\n async loadAssetClassificationMappings(): Promise {\r\n await this._loadAssetClassificationMappings();\r\n this._assetClassificationMappingsSubject.next();\r\n }\r\n\r\n async exportFormClassificationMappings(): Promise {\r\n const result = await lastValueFrom(this._formRepository.exportFormClassificationMappings(this.assessor.formRevisionYearAssessorId));\r\n return result;\r\n }\r\n\r\n async setSchedules(schedules: Compliance.FormRevisionScheduleModel[]): Promise {\r\n await this._setSchedules(schedules);\r\n this._schedulesSubject.next(this._schedules);\r\n }\r\n\r\n async loadSchedules(): Promise {\r\n await this._loadSchedules();\r\n this._schedulesSubject.next(this._schedules);\r\n }\r\n\r\n async updateSchedules(schedules: Compliance.FormRevisionScheduleModel[], force: boolean): Promise {\r\n const result = await lastValueFrom(this._formRepository.updateSchedules(this._formRevision.formRevisionId, this._formRevisionYear.taxYear, schedules, force));\r\n\r\n if (result.formClassificationMappingsUpdated) {\r\n await this.loadAssetClassificationMappings();\r\n }\r\n\r\n await this.validateTemplate();\r\n\r\n await this.setSchedules(result.schedules);\r\n }\r\n\r\n async setFactorTables(factorTables: Compliance.FormFactorTableModel[]): Promise {\r\n await this._setFactorTables(factorTables);\r\n this._factorTablesSubject.next(this._factorTables);\r\n }\r\n\r\n async setReports(reports: Compliance.FormRevisionReportModel[]): Promise {\r\n await this._setReports(reports);\r\n this._reportsSubject.next(this._reports);\r\n }\r\n\r\n async associateAssessors(associationModel: Compliance.FormRevisionAssessorAssociationModel): Promise {\r\n await this._associateAssessors(associationModel);\r\n this._assessorsSubject.next(this._assessors);\r\n }\r\n\r\n async disassociateAssessor(formRevisionYearAssessorIds: number[], force: boolean): Promise {\r\n await this._disassociateAssessors(formRevisionYearAssessorIds, force);\r\n this._assessorsSubject.next(this._assessors);\r\n }\r\n\r\n async assessorChangeIsCertified(formRevisionYearAssessorId: number, isCertified: boolean): Promise {\r\n await this._assessorChangeIsCertified(formRevisionYearAssessorId, isCertified);\r\n this._assessorsSubject.next(this._assessors);\r\n }\r\n\r\n async getAssessorAddresses(formRevisionYearAssessorId: number): Promise {\r\n return await lastValueFrom(this._formRepository.getAssessorAddresses(formRevisionYearAssessorId));\r\n }\r\n\r\n async updateAssessorAddress(formRevisionYearAssessorId: number, addressId: number): Promise {\r\n await this._updateAssessorAddress(formRevisionYearAssessorId, addressId);\r\n this._assessorsSubject.next(this._assessors);\r\n }\r\n\r\n async assessorChangeUseDefaultTables(formRevisionYearAssessorId, useDefaultTables: boolean): Promise {\r\n await this._assessorChangeUseDefaultTables(formRevisionYearAssessorId, useDefaultTables);\r\n this._assessorsSubject.next(this._assessors);\r\n this._schedulesSubject.next(this._schedules);\r\n }\r\n\r\n async assessorChangeUseDefaultMappings(formRevisionYearAssessorId: number, useDefaultMappings: boolean): Promise {\r\n await this._assessorChangeUseDefaultMappings(formRevisionYearAssessorId, useDefaultMappings);\r\n this._assessorsSubject.next(this._assessors);\r\n }\r\n\r\n async assessorChangeUsePropertyType(formRevisionYearAssessorId: number, usePropertyType: boolean, field: string): Promise {\r\n await this._assessorChangeUsePropertyType(formRevisionYearAssessorId, usePropertyType, field);\r\n this._assessorsSubject.next(this._assessors);\r\n }\r\n\r\n async updateFactorTables(formRevisionYearAssessorId: number, factorTableIds: number[], force: boolean): Promise {\r\n const updateModel: Compliance.FormRevisionFactorTableUpdateModel = {\r\n force: force,\r\n factorTableIds: factorTableIds\r\n };\r\n await lastValueFrom(this._formRepository.updateFactorTableList(formRevisionYearAssessorId, updateModel));\r\n if (force) {\r\n const factorTables = await lastValueFrom(this._formRepository.getFactors(formRevisionYearAssessorId));\r\n this._setFactorTables(factorTables);\r\n this._factorTablesSubject.next(this._factorTables);\r\n\r\n }\r\n }\r\n\r\n async updateIsPrimary(isPrimary: boolean, force:boolean = false): Promise {\r\n const result = await lastValueFrom(this._formRepository.updateIsPrimary(this._formRevisionYear.formRevisionYearId, isPrimary, force));\r\n this._formRevisionYear.isPrimary = result.isPrimary;\r\n this._isPrimarySubject.next(result.isPrimary);\r\n }\r\n\r\n async updateIsInDevelopment(isInDevelopment: boolean): Promise {\r\n const result = await lastValueFrom(this._formRepository.updateIsInDevelopment(this._formRevisionYear.formRevisionYearId, isInDevelopment));\r\n this._formRevisionYear.isInDevelopment = result.isInDevelopment;\r\n this._isInDevelopmentSubject.next(result.isInDevelopment);\r\n }\r\n\r\n async validateTemplate(): Promise {\r\n await this._validateTemplate();\r\n }\r\n\r\n async downloadTemplate(): Promise {\r\n const response = await lastValueFrom(this._formRepository.getTemplate(this._formRevision.formRevisionId));\r\n this._saveFileAsPdf(response.body, this._getFilenameFromResponseContentDisposition(response));\r\n }\r\n\r\n async updateTemplate(file: File, fileMetadata: Compliance.ReturnFormTemplateModel): Promise {\r\n const result = await lastValueFrom(this._formRepository.updateTemplate(file, fileMetadata));\r\n\r\n // if there are any errors, the template was not updated\r\n if (result.errors && result.errors.length) {\r\n return result;\r\n }\r\n\r\n this._formRevision.isPlaceholderTemplate = false;\r\n this._formRevision.templateChangeDate = result.templateChangeDate;\r\n this._formRevision.templateChangedBy = result.templateChangedBy;\r\n this._templateValidationResult = result;\r\n\r\n return result;\r\n }\r\n\r\n async deleteTemplate(): Promise {\r\n const result = await lastValueFrom(this._formRepository.deleteTemplate(this._formRevision.formRevisionId));\r\n\r\n this._formRevision.isPlaceholderTemplate = true;\r\n this._formRevision.hasTemplate = false;\r\n this._formRevision.templateChangedBy = result.templateChangedBy;\r\n this._formRevision.templateChangeDate = result.templateChangeDate;\r\n this._templateValidationResult = null;\r\n }\r\n\r\n async previewTemplateEditMetadata(data: Compliance.FormRevisionTemplateEditModel): Promise {\r\n return await lastValueFrom(this._formRepository.previewTemplateEditMetadata(this._formRevision.formRevisionId, data));\r\n }\r\n\r\n async previewTemplateEdit(data: Compliance.FormRevisionTemplateEditModel): Promise {\r\n const response = await lastValueFrom(this._formRepository.previewTemplateEdit(this._formRevision.formRevisionId, data));\r\n this._saveFileAsPdf(response.body, this._getFilenameFromResponseContentDisposition(response));\r\n }\r\n\r\n async getTemplateMetadata(): Promise {\r\n return await lastValueFrom(this._formRepository.getTemplateMetadata(this._formRevision.formRevisionId));\r\n }\r\n\r\n async applyTemplateEdit(data: Compliance.FormRevisionTemplateEditModel): Promise {\r\n const result = await lastValueFrom(this._formRepository.applyTemplateEdit(this._formRevision.formRevisionId, data));\r\n\r\n this._templateValidationResult = result;\r\n this._formRevision.templateChangeDate = result.templateChangeDate;\r\n this._formRevision.templateChangedBy = result.templateChangedBy;\r\n }\r\n\r\n async getTemplatePageCount(): Promise {\r\n return await lastValueFrom(this._formRepository.getTemplatePageCount(this._formRevision.formRevisionId));\r\n }\r\n\r\n async createTaxYear(taxYear: number): Promise {\r\n const result = await lastValueFrom(this._formRepository.createNextTaxYear(this._formRevision.formRevisionId, taxYear));\r\n await this._loadFormRevision(this._formRevision.formRevisionId);\r\n await this._setFormRevisionYear(_.find(this._formRevision.formRevisionYears, x => x.formRevisionYearId === result.formRevisionYearId));\r\n this._formRevisionSubject.next(this._formRevision);\r\n }\r\n\r\n async getByAvailableToCopyTo(): Promise {\r\n return await lastValueFrom(this._formRepository.getByAvailableToCopyTo(this._formRevisionYear.formRevisionYearId));\r\n }\r\n\r\n async copyTo(targetFormRevisionId: number): Promise {\r\n return await lastValueFrom(this._formRepository.copyTo(this._formRevisionYear.formRevisionYearId, targetFormRevisionId));\r\n }\r\n\r\n async deleteTaxYear(): Promise {\r\n let yearIndex = _.findIndex(this._formRevisionYears, x => x === this._formRevisionYear);\r\n if (yearIndex > 0) {\r\n yearIndex = yearIndex - 1;\r\n }\r\n\r\n await lastValueFrom(this._formRepository.deleteTaxYear(this._formRevisionYear.formRevisionYearId));\r\n await this._loadFormRevision(this._formRevision.formRevisionId);\r\n await this._setFormRevisionYear(this._formRevisionYears[yearIndex]);\r\n this._formRevisionSubject.next(this._formRevision);\r\n }\r\n\r\n loadRoles(): void {\r\n this._loadRoles();\r\n }\r\n\r\n // helper methods\r\n getFactorTableTypeName(factorTableType: Compliance.FactorTableTypeEnum): string {\r\n switch (factorTableType) {\r\n case Compliance.FactorTableTypeEnum.Depreciation:\r\n return 'Depreciation';\r\n case Compliance.FactorTableTypeEnum.Index:\r\n return 'Index';\r\n default:\r\n return '';\r\n }\r\n }\r\n\r\n getReportType(formRevisionReport: Compliance.FormRevisionReportModel): string {\r\n if (!formRevisionReport) {\r\n return '';\r\n }\r\n\r\n return formRevisionReport.isSystem ? 'System' : 'Custom';\r\n }\r\n\r\n getReportName(formRevisionReport: Compliance.FormRevisionReportModel): string {\r\n if (!formRevisionReport) {\r\n return '';\r\n }\r\n\r\n return `${formRevisionReport.name}${(formRevisionReport.variantName ? ` - ${formRevisionReport.variantName}` : '')}`;\r\n }\r\n\r\n getSavedSearchReportType(savedSearch: Core.SavedSearchModel): string {\r\n if (!savedSearch) {\r\n return '';\r\n }\r\n\r\n return savedSearch.isSystemSearch ? 'System' : 'Custom';\r\n }\r\n\r\n getSavedSearchReportName(savedSearch: Core.SavedSearchModel): string {\r\n if (!savedSearch) {\r\n return '';\r\n }\r\n\r\n return `${savedSearch.searchName}${(savedSearch.variantName ? ` - ${savedSearch.variantName}`: '')}`;\r\n }\r\n\r\n updateFormRevisionInfo(info: Compliance.ReturnFormTemplateValidationResultModel): void {\r\n if (this._formRevision) {\r\n this._formRevision.isFormConsolidated = info.isFormConsolidated;\r\n this._formRevision.templateChangeDate = info.templateChangeDate;\r\n this._formRevision.templateChangedBy = info.templateChangedBy;\r\n this._formRevision.hasTemplate = info.hasTemplate;\r\n this._formRevision.templateSafeFileName = info.templateSafeFileName;\r\n this._formRevision.isPlaceholderTemplate = info.isPlaceholderTemplate;\r\n }\r\n }\r\n\r\n // private\r\n private async _loadFormRevision(formRevisionId: number, taxYear?: number): Promise {\r\n this._isInitialized = false;\r\n\r\n // load the form revision\r\n this._formRevision = await lastValueFrom(this._formRepository.getRevision(formRevisionId));\r\n\r\n // remember the form revision\r\n this._lastFormRevision = this._formRevision;\r\n\r\n // load appeal levels\r\n if (this.isFormTypeAppeal) {\r\n await this._loadAppealLevels();\r\n }\r\n\r\n // load asset classifications\r\n await this._loadAssetClassifications();\r\n\r\n // load all reports\r\n await this._loadAllReports();\r\n\r\n // set form revision reports\r\n await this._setReports(this._formRevision.formRevisionReports);\r\n\r\n // set schedules\r\n await this._setSchedules(this._formRevision.formRevisionSchedules);\r\n\r\n // set form revision years\r\n await this._setFormRevisionYears(this._formRevision.formRevisionYears, taxYear);\r\n\r\n // validate the template\r\n await this._validateTemplate();\r\n\r\n this._isInitialized = true;\r\n }\r\n\r\n private _loadRoles(): void {\r\n this._canEdit = this._restrictService.isInRole(Roles.COMPLIANCESETUPSEDIT);\r\n this._canView = this._restrictService.isInRole(Roles.COMPLIANCESETUPSVIEW);\r\n }\r\n\r\n private async _loadAppealLevels(): Promise {\r\n this._appealLevels = await this._appealService.getStateAppealLevels(this.formRevision.stateId);\r\n }\r\n\r\n private async _loadAssetClassifications(): Promise {\r\n this._assetClassifications = await lastValueFrom(this._assetClassificationRepository.getAssetClassifications());\r\n }\r\n\r\n private async _loadAssetClassificationMappings(): Promise {\r\n let mappings: Compliance.FormClassificationMappingModel[] = [];\r\n if (this._assessor) {\r\n mappings = await lastValueFrom(this._formRepository.getFormClassificationMappings(this._assessor.formRevisionYearAssessorId));\r\n }\r\n\r\n this._assetClassificationMappings = mappings;\r\n }\r\n\r\n private async _setAssessors(assessors: Compliance.FormRevisionAssessorModel[]): Promise {\r\n this._assessors = assessors;\r\n\r\n // maintain the selected assessor when the list is updated\r\n let selectedAssessor: Compliance.FormRevisionAssessorModel = null;\r\n if (this._assessor) {\r\n selectedAssessor = _.find(this._assessors, item => item.formRevisionYearAssessorId === this._assessor.formRevisionYearAssessorId);\r\n }\r\n\r\n // set the default assessor\r\n this._defaultAssessor = _.find(this._assessors,\r\n (x) => {\r\n return x.assessorId === null;\r\n });\r\n\r\n // if not found in the new list, set to default assessor\r\n if (!selectedAssessor) {\r\n selectedAssessor = this._defaultAssessor;\r\n }\r\n\r\n // set flag if any assessor has been certified\r\n this._anyAssessorMappingsCertified = _.find(this._assessors, item => item.isMappingCertified) ? true : false;\r\n this._anyAssessorMappingsCertifiedSubject.next(this._anyAssessorMappingsCertified);\r\n\r\n // set the assessor\r\n await this._setAssessor(selectedAssessor);\r\n }\r\n\r\n private async _setAssessor(assessor: Compliance.FormRevisionAssessorModel): Promise {\r\n this._assessor = assessor;\r\n this._warnDefaultAssessorEdit = this._assessor && !this._assessor.assessorId;\r\n\r\n // set the factor table assessor\r\n this._factorTableAssessor = this._assessor && !this._assessor.isUsingDefaultTables\r\n ? this._assessor\r\n : this._defaultAssessor;\r\n\r\n // load the assessor factor tables\r\n let factorTables: Compliance.FormFactorTableModel[] = [];\r\n if (this._assessor) {\r\n factorTables = await lastValueFrom(this._formRepository.getFactors(this._assessor.formRevisionYearAssessorId));\r\n }\r\n await this._setFactorTables(factorTables);\r\n\r\n // load asset classification mappings\r\n await this._loadAssetClassificationMappings();\r\n }\r\n\r\n private async _setFormRevisionYears(formRevisionYears: Compliance.FormRevisionYearModel[], taxYear?: number): Promise {\r\n this._formRevisionYears = _.orderBy(formRevisionYears, [x => x.taxYear], ['desc']);\r\n\r\n this._maxFormRevisionYear = _.maxBy(this._formRevisionYears, (x) => x.taxYear);\r\n this._minFormRevisionYear = _.minBy(this._formRevisionYears, (x) => x.taxYear);\r\n\r\n let formRevisionYear: Compliance.FormRevisionYearModel = null;\r\n const selectedYear = taxYear\r\n ? this._formRevisionYears.find(x => x.taxYear === taxYear)\r\n : this._formRevisionYear;\r\n\r\n // persist the selected year between form selection\r\n if (selectedYear) {\r\n formRevisionYear = this._formRevisionYears.find((x) => { return x.formRevisionYearId === selectedYear.formRevisionYearId; });\r\n }\r\n\r\n // if no year selected, attempt to select the max\r\n if (!formRevisionYear) {\r\n formRevisionYear = this._maxFormRevisionYear;\r\n }\r\n\r\n await this._setFormRevisionYear(formRevisionYear);\r\n }\r\n\r\n private async _setFormRevisionYear(formRevisionYear: Compliance.FormRevisionYearModel): Promise {\r\n this._formRevisionYear = formRevisionYear;\r\n\r\n // load the assessors\r\n const assessors = await lastValueFrom(this._formRepository.getAssessors(this._formRevision.formRevisionId, this._formRevisionYear.taxYear));\r\n\r\n // load all factor tables\r\n await this._loadAllFactorTables();\r\n\r\n await this._setAssessors(assessors);\r\n }\r\n\r\n private async _setSchedules(schedules: Compliance.FormRevisionScheduleModel[]): Promise {\r\n this._schedules = schedules;\r\n await Promise.resolve();\r\n }\r\n\r\n private async _loadAllFactorTables(): Promise {\r\n const searchModel: Compliance.FactorTableSearchModel = {\r\n stateId: this._formRevision.stateId,\r\n taxYear: this._formRevisionYear.taxYear,\r\n tableType: null,\r\n companyId: null,\r\n includeRetiredTables: false\r\n };\r\n\r\n this._allFactorTables = await lastValueFrom(this._formRepository.getFactorTableList(searchModel));\r\n }\r\n\r\n private async _loadAllReports(): Promise {\r\n this._allReports = await lastValueFrom(this._formRepository.getReports());\r\n }\r\n\r\n private async _loadSchedules(): Promise {\r\n let schedules: Compliance.FormRevisionScheduleModel[] = [];\r\n if (this._formRevision) {\r\n schedules = await lastValueFrom(this._formRepository.getSchedulesForRevision(this._formRevision.formRevisionId));\r\n }\r\n\r\n await this._setSchedules(schedules);\r\n }\r\n\r\n private async _setFactorTables(factorTables: Compliance.FormFactorTableModel[]): Promise {\r\n this._factorTables = factorTables;\r\n await Promise.resolve();\r\n }\r\n\r\n private async _setReports(reports: Compliance.FormRevisionReportModel[]): Promise {\r\n this._reports = reports;\r\n await Promise.resolve();\r\n }\r\n\r\n private async _associateAssessors(associationModel: Compliance.FormRevisionAssessorAssociationModel): Promise {\r\n const updatedAssessors = await lastValueFrom(this._formRepository.associateAssessors(this._formRevision.formRevisionId, associationModel));\r\n\r\n // update assessors\r\n _.forEach(updatedAssessors, updatedAssessor => {\r\n const existingAssessor = _.find(this._assessors, x => x.assessorId === updatedAssessor.assessorId);\r\n\r\n if (existingAssessor) {\r\n const assessorIndex = this._assessors.indexOf(existingAssessor);\r\n updatedAssessor.assessorName = existingAssessor.assessorName;\r\n this._assessors[assessorIndex] = updatedAssessor;\r\n }\r\n else {\r\n this._assessors.push(updatedAssessor);\r\n }\r\n });\r\n\r\n await this._setAssessors(this._assessors);\r\n }\r\n\r\n private async _disassociateAssessors(formRevisionYearAssessorIds: number[], force: boolean): Promise {\r\n // remove the association\r\n await lastValueFrom(this._formRepository.disassociateAssessors(this._formRevision.formRevisionId, formRevisionYearAssessorIds, force));\r\n\r\n // if the selected assessor is deleted, set selected to default\r\n if (formRevisionYearAssessorIds.find(id => this._assessor.formRevisionYearAssessorId === id)) {\r\n this._assessor = this._defaultAssessor;\r\n }\r\n\r\n // null the IDs\r\n formRevisionYearAssessorIds.forEach(id => {\r\n const existingAssessor = _.find(this._assessors, x => x.formRevisionYearAssessorId === id);\r\n if(existingAssessor) {\r\n existingAssessor.formRevisionYearAssessorId = null;\r\n }\r\n });\r\n\r\n await this._setAssessors(this._assessors);\r\n }\r\n\r\n private async _assessorChangeIsCertified(formRevisionYearAssessorId: number, isCertified: boolean): Promise {\r\n const updatedAssessor = await lastValueFrom(this._formRepository.assessorChangeIsCertified(formRevisionYearAssessorId, isCertified));\r\n\r\n let assessors = this._assessors;\r\n\r\n // when the default assessor mapping is updated, any assessor using default mappings will also get certification updated\r\n if (!updatedAssessor.assessorId) {\r\n assessors = await lastValueFrom(this._formRepository.getAssessors(this._formRevision.formRevisionId, this._formRevisionYear.taxYear));\r\n }\r\n\r\n const existingAssessor = _.find(assessors, x => x.formRevisionYearAssessorId === formRevisionYearAssessorId);\r\n\r\n if (existingAssessor) {\r\n _.extend(existingAssessor, updatedAssessor);\r\n }\r\n\r\n await this._setAssessors(assessors);\r\n }\r\n\r\n private async _updateAssessorAddress(formRevisionYearAssessorId: number, addressId: number): Promise {\r\n const updatedAssessor = await lastValueFrom(this._formRepository.updateAssessorAddress(formRevisionYearAssessorId, addressId));\r\n\r\n const existingAssessor = _.find(this._assessors, x => x.formRevisionYearAssessorId === formRevisionYearAssessorId);\r\n\r\n if (existingAssessor) {\r\n _.extend(existingAssessor, updatedAssessor);\r\n }\r\n\r\n await this._setAssessors(this._assessors);\r\n }\r\n\r\n private async _assessorChangeUseDefaultTables(formRevisionYearAssessorId: number, useDefaultTables: boolean): Promise {\r\n const updatedAssessor = await lastValueFrom(this._formRepository.assessorChangeUseDefaultTables(formRevisionYearAssessorId, useDefaultTables));\r\n\r\n const existingAssessor = _.find(this._assessors, x => x.formRevisionYearAssessorId === formRevisionYearAssessorId);\r\n\r\n if (existingAssessor) {\r\n _.extend(existingAssessor, updatedAssessor);\r\n }\r\n\r\n await this._setAssessors(this._assessors);\r\n await this._loadSchedules();\r\n }\r\n\r\n private async _assessorChangeUseDefaultMappings(formRevisionYearAssessorId: number, useDefaultMappings: boolean): Promise {\r\n const updatedAssessor = await lastValueFrom(this._formRepository.assessorChangeUseDefaultMappings(formRevisionYearAssessorId, useDefaultMappings));\r\n\r\n const existingAssessor = _.find(this._assessors, x => x.formRevisionYearAssessorId === formRevisionYearAssessorId);\r\n\r\n if (existingAssessor) {\r\n _.extend(existingAssessor, updatedAssessor);\r\n }\r\n\r\n await this._setAssessors(this._assessors);\r\n }\r\n\r\n private async _assessorChangeUsePropertyType(formRevisionYearAssessorId: number, usePropertyType: boolean, field: string): Promise {\r\n const updatedAssessor = await lastValueFrom(this._formRepository.assessorChangeUsePropertyType(formRevisionYearAssessorId, usePropertyType, field));\r\n\r\n const existingAssessor = _.find(this._assessors, x => x.formRevisionYearAssessorId === formRevisionYearAssessorId);\r\n\r\n if (existingAssessor) {\r\n _.extend(existingAssessor, updatedAssessor);\r\n }\r\n\r\n await this._setAssessors(this._assessors);\r\n }\r\n\r\n private async _validateTemplate(): Promise {\r\n this._templateValidationResult = null;\r\n\r\n if (!this._formRevision) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._templateValidationResult = await lastValueFrom(this._formRepository.validateTemplate(this._formRevision.formRevisionId));\r\n }\r\n\r\n private _getFilenameFromResponseContentDisposition(response: HttpResponse): string {\r\n const contentDisposition = response.headers.get('content-disposition') || '';\r\n const matches = /filename=\"?([^;\"]+)\"?/ig.exec(contentDisposition);\r\n return (matches[1] || 'untitled').trim();\r\n }\r\n\r\n private _saveFileAsPdf(data: Blob, filename: string): void {\r\n const blob = new Blob([data], { type: 'application/pdf' });\r\n const link = document.createElement('a');\r\n link.href = window.URL.createObjectURL(blob);\r\n link.download = filename;\r\n link.click();\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

Forms

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
    \r\n
  • \r\n
    \r\n \r\n \r\n \r\n \r\n {{ form.name }}\r\n {{ form.description }}\r\n \r\n \r\n \r\n \r\n \r\n
    \r\n
      \r\n
    • \r\n
      \r\n \r\n \r\n 0 ? '' : 'empty-tree-node'\" (click)=\"collapseFormRevision(revision)\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ revision.name }}\r\n \r\n {{ revision.description }}\r\n {{ revision.yearInfo }}\r\n (Prior: {{ revision.priorFormRevisionName }})\r\n \r\n \r\n \r\n \r\n \r\n \r\n
      \r\n
        \r\n
      • \r\n
        \r\n \r\n \r\n \r\n {{ supplemental.name }}\r\n \r\n {{ supplemental.description }}\r\n {{ supplemental.yearInfo }}\r\n (Prior: {{ supplemental.priorFormRevisionName }})\r\n \r\n \r\n \r\n \r\n \r\n
        \r\n
      • \r\n
      \r\n
    • \r\n
    \r\n
  • \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
No Forms to Show
\r\n
\r\n
\r\n","import { Component, OnInit, EventEmitter, OnDestroy } from '@angular/core';\r\nimport { StateService } from '../../../Common/States/States.Service';\r\nimport { StateSummary } from '../../../Common/States/state.model';\r\nimport { FormRepository } from '../../Repositories';\r\nimport { FormService } from '../form.service';\r\nimport { lastValueFrom, Subscription } from 'rxjs';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { FormDetailsComponent, FormMode, FormType, FormDetailsParams } from '../Form-Details/formDetails.component';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { BusyIndicatorService, SnackBarService } from '../../../Busy-Indicator';\r\nimport { Constants } from '../../../constants.new';\r\nimport { FormTypeEnum } from '../Models/enums';\r\nimport { AppealLevel } from '../../../Annual-Details/Appeals/appeal.model';\r\nimport { AppealService } from '../../../Annual-Details/Appeals/appeal.service';\r\nimport { BusyIndicatorRef } from '../../../Busy-Indicator';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { FormSetupUploadComponent } from '../Form-Setup-Upload/formSetupUpload.component';\r\nimport { FormSetupRepository } from '../../Repositories';\r\nimport { FormSetupDownloadComponent } from '../Form-Setup-Download/formSetupDownload.component';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { FORM_HELP } from '../form.help';\r\nimport { ExportFormListComponent } from '../Export-Form-List/exportFormList.component';\r\nimport { FormLibraryExportComponent } from '../Form-Library-Export/formLibraryExport.component';\r\nimport { FormLibraryRepository } from '../../Repositories/formLibraryRepository';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'form-list',\r\n templateUrl: './formList.component.html',\r\n styleUrls: ['./formList.component.scss']\r\n})\r\nexport class FormListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _appealService: AppealService,\r\n private readonly _stateService: StateService,\r\n private readonly _formRepository: FormRepository,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _formService: FormService,\r\n private readonly _constants: Constants,\r\n private readonly _formSetupRepository: FormSetupRepository,\r\n private readonly _toastr: ToastrService,\r\n private readonly _helpService: HelpService,\r\n private readonly _formLibraryRepository: FormLibraryRepository,\r\n private readonly _snackBarService: SnackBarService) { }\r\n\r\n private _expandedFormIds: Set = new Set([]);\r\n private _collapsedRevisionIds: Set = new Set([]);\r\n private _appealLevels: AppealLevel[];\r\n private _formsSetupFileLongRunningProcessId: number;\r\n private _longRunningProcessProgressSub: Subscription;\r\n private _longRunningProcessStatusSub: Subscription;\r\n private _exportFormListLongRunningProcessId: number;\r\n private _formLibraryExportLongRunningProcessId: number;\r\n\r\n private _busyRef: BusyIndicatorRef;\r\n private _busyRefId = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n\r\n formList: Compliance.FormModel[] = [];\r\n FormTypeEnum = FormTypeEnum;\r\n formTypes = this._constants.FormTypes;\r\n states: StateSummary[];\r\n selectedState: StateSummary = null;\r\n selectedFormType: Compliance.NameValuePair = null;\r\n selectFormRevisionEmitter: EventEmitter = new EventEmitter();\r\n canEdit: boolean = false;\r\n canView: boolean = false;\r\n canExport: boolean = false;\r\n stateFormatter = (state: StateSummary) => (state.abbr) ? `${state.fullName} (${state.abbr})` : state.fullName;\r\n refreshing: boolean;\r\n stampLocations: Compliance.FormRevisionStampLocationModel[];\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(FORM_HELP);\r\n\r\n this.canEdit = this._restrictService.isInRole(Roles.COMPLIANCESETUPSEDIT);\r\n this.canView = this._restrictService.isInRole(Roles.COMPLIANCESETUPSVIEW);\r\n this.canExport = this._restrictService.isInRole(Roles.COMPLIANCESETUPSVIEW) && this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n\r\n await this.refresh();\r\n\r\n await this._setLastFormRevision();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._longRunningProcessProgressSub && this._longRunningProcessProgressSub.unsubscribe();\r\n this._longRunningProcessStatusSub && this._longRunningProcessStatusSub.unsubscribe();\r\n\r\n this._busyRef = null;\r\n }\r\n\r\n async refresh(): Promise {\r\n this.refreshing = true;\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n const summaryData = await this._stateService.getSummary();\r\n this.states = summaryData.filter(item => item.countryID === 1);\r\n this.stampLocations = await lastValueFrom(this._formRepository.getStampLocations());\r\n this.criteriaChanged();\r\n }\r\n finally {\r\n busyRef.hide();\r\n this.refreshing = false;\r\n }\r\n }\r\n\r\n isExpanded(form: Compliance.FormModel) {\r\n return this._expandedFormIds.has(form.formId);\r\n }\r\n\r\n isRevisionCollapsed(revision: Compliance.FormRevisionModel) {\r\n return this._collapsedRevisionIds.has(revision.formRevisionId);\r\n }\r\n\r\n expandFormRevision(revision: Compliance.FormRevisionModel) {\r\n this._collapsedRevisionIds.delete(revision.formRevisionId);\r\n }\r\n\r\n collapseFormRevision(revision: Compliance.FormRevisionModel) {\r\n if (revision.supplementalForms.length > 0) {\r\n this._collapsedRevisionIds.add(revision.formRevisionId);\r\n }\r\n }\r\n\r\n expandForm(form: Compliance.FormModel) {\r\n this._expandedFormIds.add(form.formId);\r\n }\r\n\r\n collapseForm(form: Compliance.FormModel) {\r\n this._expandedFormIds.delete(form.formId);\r\n }\r\n\r\n async criteriaChanged(): Promise {\r\n if (!this.selectedState || !this.selectedFormType) {\r\n this.formList = [];\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n const result = await lastValueFrom>(this._formRepository.getForms(this.selectedState.stateID, this.selectedFormType.value as number, null, null));\r\n this._appealLevels = await this._appealService.getStateAppealLevels(this.selectedState.stateID);\r\n this.formList = (result && result.data) || [];\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n createNewForm(): Promise {\r\n return new Promise(() => {\r\n const params: FormDetailsParams = {\r\n type: FormType.Form,\r\n mode: FormMode.Create,\r\n stateId: this.selectedState ? this.selectedState.stateID : null,\r\n formTypeId: this.selectedFormType ? this.selectedFormType.value : null,\r\n taxYear: new Date().getFullYear(),\r\n formName: '',\r\n formDescription: null,\r\n revisionId: null,\r\n revisionName: null,\r\n revisionDescription: null,\r\n supplementalFormName: null,\r\n supplementalFormDescription: null,\r\n canEdit: this.canEdit,\r\n appealLevelId: null,\r\n appealLevels: this._appealLevels,\r\n priorFormRevisionId: null,\r\n revisionStampLocationId: Compliance.FormRevisionStampLocationEnum.Top,\r\n stampLocations: this.stampLocations,\r\n supportsNBVReporting: false,\r\n supportsEstFMVReporting: false,\r\n electronicFilingTypeId: null,\r\n isFormRevisionInLockedBatch: false\r\n };\r\n\r\n this.showFormDetailsWithParams(params);\r\n });\r\n }\r\n\r\n async deleteForm(form: Compliance.FormModel, force: boolean = false): Promise {\r\n if (!force) {\r\n try {\r\n await this._messageModalService.confirm(\r\n `Are you sure you wish to delete \"${form.name}\"?`,\r\n 'Confirm Delete');\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n let confirmMessage = '';\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting Form' });\r\n\r\n try {\r\n await lastValueFrom(this._formRepository.deleteForm(form.formId, force));\r\n this.criteriaChanged();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n confirmMessage = e2.error.message;\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n if (confirmMessage) {\r\n try {\r\n await this._messageModalService.confirm(\r\n confirmMessage,\r\n 'Confirm Delete');\r\n }\r\n catch (e3) {\r\n return Promise.resolve();\r\n }\r\n\r\n // force\r\n await this.deleteForm(form, true);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async deleteRevision(revision: Compliance.FormRevisionModel, typeText = 'revision', force: boolean = false): Promise {\r\n if (!force) {\r\n try {\r\n await this._messageModalService.confirm(\r\n `Are you sure you wish to delete ${typeText} \"${revision.name}\"?`,\r\n 'Confirm Delete');\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n let confirmMessage = '';\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting Form Revision' });\r\n\r\n try {\r\n await lastValueFrom(this._formRepository.deleteRevision(revision.formRevisionId, force));\r\n this.criteriaChanged();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n confirmMessage = e2.error.message;\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n if (confirmMessage) {\r\n try {\r\n await this._messageModalService.confirm(\r\n confirmMessage,\r\n 'Confirm Delete');\r\n }\r\n catch (e3) {\r\n return Promise.resolve();\r\n }\r\n\r\n // force\r\n await this.deleteRevision(revision, typeText, true);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n deleteSupplement(supplement: Compliance.FormRevisionModel): void {\r\n this.deleteRevision(supplement, 'revision supplement');\r\n }\r\n\r\n createRevision(form: Compliance.FormModel): Promise {\r\n return new Promise(() => {\r\n const params: FormDetailsParams = {\r\n type: FormType.FormRevision,\r\n mode: FormMode.Create,\r\n formId: form.formId,\r\n formName: form.name,\r\n formDescription: form.description,\r\n stateId: form.stateId,\r\n formTypeId: form.formTypeId,\r\n canEdit: this.canEdit,\r\n appealLevels: this._appealLevels,\r\n allFormRevisions: form.formRevisions || [],\r\n priorFormRevisionId: _.last(_.sortBy(_.map(form.formRevisions, x => x.formRevisionId))),\r\n revisionStampLocationId: Compliance.FormRevisionStampLocationEnum.Top,\r\n stampLocations: this.stampLocations,\r\n electronicFilingTypeId: null,\r\n isFormRevisionInLockedBatch: false\r\n };\r\n\r\n this.showFormDetailsWithParams(params);\r\n });\r\n }\r\n\r\n configureAssociations(revision: Compliance.FormRevisionModel): void {\r\n this._routerService.go('formPage', { formRevisionId: revision.formRevisionId });\r\n }\r\n\r\n createSupplement(form: Compliance.FormModel, parentRevision: Compliance.FormRevisionModel): void {\r\n let allFormRevisions: Compliance.FormRevisionModel[] = [];\r\n if (parentRevision.priorFormRevisionId) {\r\n const priorFormRevision = _.find(form.formRevisions, x => x.formRevisionId === parentRevision.priorFormRevisionId);\r\n if (priorFormRevision) {\r\n allFormRevisions = priorFormRevision.supplementalForms || [];\r\n }\r\n }\r\n\r\n const params: FormDetailsParams = {\r\n type: FormType.SupplementalForm,\r\n mode: FormMode.Create,\r\n formId: form.formId,\r\n formName: form.name,\r\n formDescription: form.description,\r\n stateId: form.stateId,\r\n formTypeId: form.formTypeId,\r\n revisionId: parentRevision.formRevisionId,\r\n revisionName: parentRevision.name,\r\n revisionDescription: parentRevision.description,\r\n canEdit: this.canEdit,\r\n appealLevels: this._appealLevels,\r\n allFormRevisions: allFormRevisions,\r\n priorFormRevisionId: _.last(_.sortBy(_.map(allFormRevisions, x => x.formRevisionId))),\r\n revisionStampLocationId: Compliance.FormRevisionStampLocationEnum.Top,\r\n stampLocations: this.stampLocations,\r\n electronicFilingTypeId: null,\r\n isFormRevisionInLockedBatch: false\r\n };\r\n\r\n this.showFormDetailsWithParams(params);\r\n }\r\n\r\n editForm(form: Compliance.FormModel): Promise {\r\n return new Promise(() => {\r\n const params: FormDetailsParams = {\r\n type: FormType.Form,\r\n mode: FormMode.Edit,\r\n formId: form.formId,\r\n formName: form.name,\r\n formDescription: form.description,\r\n stateId: form.stateId,\r\n formTypeId: form.formTypeId,\r\n canEdit: this.canEdit,\r\n revisionStampLocationId: Compliance.FormRevisionStampLocationEnum.Top,\r\n stampLocations: this.stampLocations,\r\n isFormRevisionInLockedBatch: false\r\n };\r\n this.showFormDetailsWithParams(params);\r\n });\r\n }\r\n\r\n editRevision(form: Compliance.FormModel, revision: Compliance.FormRevisionModel): Promise {\r\n return new Promise(() => {\r\n const params: FormDetailsParams = {\r\n type: FormType.FormRevision,\r\n mode: FormMode.Edit,\r\n revisionId: revision.formRevisionId,\r\n revisionName: revision.name,\r\n revisionDescription: revision.description,\r\n formName: form.name,\r\n formDescription: form.description,\r\n stateId: form.stateId,\r\n formTypeId: form.formTypeId,\r\n canEdit: this.canEdit,\r\n allFormRevisions: form.formRevisions || [],\r\n priorFormRevisionId: revision.priorFormRevisionId,\r\n revisionStampLocationId: revision.formRevisionStampLocationId,\r\n stampLocations: this.stampLocations,\r\n supportsNBVReporting: revision.supportsNBVReporting,\r\n supportsEstFMVReporting: revision.supportsEstFMVReporting,\r\n electronicFilingTypeId: revision.electronicFilingTypeId,\r\n isFormRevisionInLockedBatch: revision.isFormRevisionInLockedBatch\r\n };\r\n this.showFormDetailsWithParams(params);\r\n });\r\n }\r\n\r\n editSupplement(form: Compliance.FormModel, parentRevision: Compliance.FormRevisionModel, supplement: Compliance.FormRevisionModel): Promise {\r\n let allFormRevisions: Compliance.FormRevisionModel[] = [];\r\n if (parentRevision.priorFormRevisionId) {\r\n const priorFormRevision = _.find(form.formRevisions, x => x.formRevisionId === parentRevision.priorFormRevisionId);\r\n if (priorFormRevision) {\r\n allFormRevisions = priorFormRevision.supplementalForms || [];\r\n }\r\n }\r\n\r\n return new Promise(() => {\r\n // revisionId has to be the supplement id - a little confusing\r\n const params: FormDetailsParams = {\r\n type: FormType.SupplementalForm,\r\n mode: FormMode.Edit,\r\n revisionId: supplement.formRevisionId,\r\n revisionName: parentRevision.name,\r\n revisionDescription: parentRevision.description,\r\n formName: form.name,\r\n formDescription: form.description,\r\n stateId: form.stateId,\r\n formTypeId: form.formTypeId,\r\n supplementalFormName: supplement.name,\r\n supplementalFormDescription: supplement.description,\r\n canEdit: this.canEdit,\r\n allFormRevisions: allFormRevisions,\r\n priorFormRevisionId: supplement.priorFormRevisionId,\r\n revisionStampLocationId: supplement.formRevisionStampLocationId,\r\n stampLocations: this.stampLocations,\r\n electronicFilingTypeId: supplement.electronicFilingTypeId,\r\n isFormRevisionInLockedBatch: supplement.isFormRevisionInLockedBatch\r\n };\r\n this.showFormDetailsWithParams(params);\r\n });\r\n }\r\n\r\n async showFormDetailsWithParams(params: FormDetailsParams): Promise {\r\n const result = await this._modalService.showAsync(FormDetailsComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (result.newFormRevision) {\r\n this.configureAssociations(result.newFormRevision);\r\n return Promise.resolve();\r\n }\r\n\r\n await this.criteriaChanged();\r\n return Promise.resolve();\r\n }\r\n\r\n async exportFormsSetup(): Promise {\r\n const result = await this._modalService.showAsync(FormSetupDownloadComponent, null, 'modal-xl');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._formsSetupFileLongRunningProcessId = await lastValueFrom(this._formSetupRepository.export(result));\r\n this._snackBarService.addById(this._formsSetupFileLongRunningProcessId, Compliance.LongRunningProcessTypeEnum.FormSetupExport);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async importFormsSetup(): Promise {\r\n const result = await this._modalService.showAsync(FormSetupUploadComponent, null, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._formsSetupFileLongRunningProcessId = result;\r\n this._showBusyIndicator('', 'Importing Forms Setup', 'Forms Setup imported successfully');\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async exportFormList(): Promise {\r\n const result = await this._modalService.showAsync(ExportFormListComponent, null, 'modal-md');\r\n\r\n if (!result) {\r\n return;\r\n }\r\n\r\n this._exportFormListLongRunningProcessId = result;\r\n this._snackBarService.addById(this._exportFormListLongRunningProcessId, Compliance.LongRunningProcessTypeEnum.ExportFormList);\r\n }\r\n\r\n async exportFormsLibrary(): Promise {\r\n const result = await this._modalService.showAsync(FormLibraryExportComponent, null, 'modal-xl');\r\n }\r\n\r\n private async _setLastFormRevision(): Promise {\r\n this.selectedFormType = _.find(this.formTypes, x => x.value === Compliance.FormTypeEnum.Compliance);\r\n\r\n if (!this._formService.lastFormRevision) {\r\n return Promise.resolve();\r\n }\r\n\r\n const state = this.states.find(x => x.stateID === this._formService.lastFormRevision.stateId);\r\n if (!state) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.selectedState = state;\r\n\r\n if (!this._formService.lastFormRevision.formTypeId) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.selectedFormType = _.find(this.formTypes, x => x.value as number === this._formService.lastFormRevision.formTypeId);\r\n\r\n await this.criteriaChanged();\r\n\r\n const form = this.formList.find(x => x.formId === this._formService.lastFormRevision.formId);\r\n if (!form) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.expandForm(form);\r\n\r\n // if it's a form revision supplement, then expand the revision it is associated with\r\n if (!this._formService.lastFormRevision.parentFormRevisionId) {\r\n return Promise.resolve();\r\n }\r\n\r\n const formRevision = form.formRevisions.find(x => x.formRevisionId === this._formService.lastFormRevision.parentFormRevisionId);\r\n if (formRevision) {\r\n this.expandFormRevision(formRevision);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', successMessage: string = null): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this._busyRefId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this._busyRefId,\r\n longRunningProcessId: this._formsSetupFileLongRunningProcessId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n canDismiss: true\r\n });\r\n\r\n this._busyRef.onDismiss().subscribe(() => this._hideBusyIndicator());\r\n\r\n this._busyRef.onProgressBarComplete().subscribe(success => {\r\n if (success && successMessage){\r\n this._toastr.success(successMessage);\r\n this.criteriaChanged();\r\n }\r\n this._hideBusyIndicator();\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { Subscription , BehaviorSubject } from 'rxjs';\r\n\r\nexport interface FormScheduleListGridCheckboxCellRendererParams extends ICellRendererParams {\r\n editMode$: BehaviorSubject;\r\n canEdit: (params: FormScheduleListGridCheckboxCellRendererParams) => boolean;\r\n isVisible: (params: FormScheduleListGridCheckboxCellRendererParams) => boolean;\r\n onValueChanged: (params: FormScheduleListGridCheckboxCellRendererParams, value: boolean) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'form-schedule-list-grid-checkbox',\r\n template: `\r\n \r\n `\r\n})\r\nexport class FormScheduleListGridCheckboxCellRendererComponent implements ICellRendererAngularComp {\r\n private _editModeSub: Subscription;\r\n\r\n params: FormScheduleListGridCheckboxCellRendererParams;\r\n editMode: boolean = false;\r\n\r\n agInit(params: FormScheduleListGridCheckboxCellRendererParams): void {\r\n this.params = params;\r\n this._editModeSub = this.params.editMode$.subscribe(x => this.editMode = x);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub.unsubscribe();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onModelChanged(eventTarget: EventTarget): void {\r\n const value = (eventTarget as HTMLInputElement).checked;\r\n this.params.onValueChanged(this.params, value);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { Subscription } from 'rxjs';\r\n\r\nexport interface ICellRendererParamsForFormScheduleListGridAction extends ICellRendererParams {\r\n canDelete(params: ICellRendererParamsForFormScheduleListGridAction): boolean;\r\n canUndoDelete(params: ICellRendererParamsForFormScheduleListGridAction): boolean;\r\n delete: (params: ICellRendererParamsForFormScheduleListGridAction) => void;\r\n undoDelete: (params: ICellRendererParamsForFormScheduleListGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n \r\n \r\n `\r\n})\r\nexport class FormScheduleListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n private _editModeSub: Subscription;\r\n\r\n params: ICellRendererParamsForFormScheduleListGridAction;\r\n\r\n agInit(params: ICellRendererParamsForFormScheduleListGridAction): void {\r\n this.params = params;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component, ViewChild, ElementRef } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { Subscription, BehaviorSubject } from 'rxjs';\r\nimport { FormRevisionScheduleRowModel } from './formScheduleList.component';\r\n\r\nexport interface FormScheduleListGridFactorTableDropdownCellRendererComponentParams extends ICellRendererParams {\r\n editMode$: BehaviorSubject;\r\n canEdit: (params: FormScheduleListGridFactorTableDropdownCellRendererComponentParams) => boolean;\r\n onValueChanged: (params: FormScheduleListGridFactorTableDropdownCellRendererComponentParams, value: Compliance.FormFactorTableModel) => void;\r\n factorTables$: BehaviorSubject;\r\n}\r\n\r\n@Component({\r\n selector: 'form-schedule-list-grid-factor-table-dropdown',\r\n template: `\r\n
\r\n
\r\n \r\n {{ schedule.defaultFactorTable.factorTableName }} ({{ schedule.defaultFactorTable.life }} yr life)\r\n \r\n
\r\n
\r\n \r\n
\r\n
`,\r\n styleUrls: ['./../agGridCellStyles.scss']\r\n})\r\nexport class FormScheduleListGridFactorTableDropdownCellRendererComponent implements ICellRendererAngularComp {\r\n private _editModeSub: Subscription;\r\n private _factorTablesSub: Subscription;\r\n\r\n params: FormScheduleListGridFactorTableDropdownCellRendererComponentParams;\r\n schedule: FormRevisionScheduleRowModel;\r\n editMode: boolean = false;\r\n isHovering: boolean = false;\r\n factorTables: Compliance.FormFactorTableModel[];\r\n\r\n @ViewChild('outerDiv', { read: ElementRef, static: true }) outerDiv: ElementRef;\r\n\r\n agInit(params: FormScheduleListGridFactorTableDropdownCellRendererComponentParams): void {\r\n this.params = params;\r\n this.schedule = params.data as FormRevisionScheduleRowModel;\r\n\r\n this._editModeSub = this.params.editMode$.subscribe(x => this.editMode = x);\r\n this._factorTablesSub = this.params.factorTables$.subscribe(x => {\r\n this.factorTables = x;\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub.unsubscribe();\r\n this._factorTablesSub.unsubscribe();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onModelChange(value: Compliance.FormFactorTableModel) {\r\n this.params.onValueChanged(this.params, value);\r\n }\r\n\r\n mouseover($event) {\r\n this.isHovering = this.editMode && this.params.canEdit(this.params);\r\n }\r\n\r\n mouseout($event) {\r\n if (this.isHovering && $event.relatedTarget) {\r\n // protect against clicks on inner children\r\n let parent = $event.relatedTarget.parentElement;\r\n while (parent) {\r\n if (parent === this.outerDiv.nativeElement) {\r\n return;\r\n }\r\n parent = parent.parentElement;\r\n }\r\n this.isHovering = false;\r\n }\r\n }\r\n}\r\n","import { Component, ViewChild, ElementRef } from '@angular/core';\r\nimport { ICellEditorAngularComp } from 'ag-grid-angular';\r\nimport { ICellEditorParams } from 'ag-grid-community';\r\nimport { Subscription , BehaviorSubject } from 'rxjs';\r\n\r\nexport interface FormScheduleListGridInputCellRendererParams extends ICellEditorParams {\r\n editMode$: BehaviorSubject;\r\n canEdit: (params: FormScheduleListGridInputCellRendererParams) => boolean;\r\n onValueChanged: (params: FormScheduleListGridInputCellRendererParams, value: string) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'form-schedule-list-grid-input',\r\n template: `\r\n
{{ params.value }}
\r\n
\r\n \r\n
\r\n`\r\n})\r\nexport class FormScheduleListGridInputCellRendererComponent implements ICellEditorAngularComp {\r\n private _editModeSub: Subscription;\r\n\r\n params: FormScheduleListGridInputCellRendererParams;\r\n editMode: boolean = false;\r\n value: string;\r\n\r\n @ViewChild('inputBox') inputBox: ElementRef;\r\n\r\n agInit(params: FormScheduleListGridInputCellRendererParams): void {\r\n this.params = params;\r\n this._editModeSub = this.params.editMode$.subscribe(x => this.editMode = x);\r\n this.value = params.data[params.colDef.field];\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub && this._editModeSub.unsubscribe();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n afterGuiAttached(): void {\r\n if (this.inputBox) {\r\n this.inputBox.nativeElement.focus();\r\n }\r\n }\r\n\r\n getValue(): string {\r\n return this.value;\r\n }\r\n}\r\n","import { Component, ViewChild, ElementRef } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { Subscription, BehaviorSubject } from 'rxjs';\r\nimport { FormRevisionScheduleRowModel } from './formScheduleList.component';\r\n\r\nexport interface FormScheduleListGridReportDropdownCellRendererParams extends ICellRendererParams {\r\n editMode$: BehaviorSubject;\r\n canEdit: (params: FormScheduleListGridReportDropdownCellRendererParams) => boolean;\r\n onValueChanged: (params: FormScheduleListGridReportDropdownCellRendererParams, value: Core.SavedSearchModel) => void;\r\n reports$: BehaviorSubject;\r\n}\r\n\r\n@Component({\r\n selector: 'form-schedule-list-grid-report-dropdown',\r\n template: `\r\n
\r\n
\r\n \r\n {{ schedule.savedSearch.searchName }}{{ schedule.savedSearch.variantName ? ' - ' + schedule.savedSearch.variantName : '' }}\r\n \r\n
\r\n
\r\n \r\n
\r\n
`,\r\n styleUrls: ['./../agGridCellStyles.scss']\r\n})\r\nexport class FormScheduleListGridReportDropdownCellRendererComponent implements ICellRendererAngularComp {\r\n private _editModeSub: Subscription;\r\n private _reportsSub: Subscription;\r\n\r\n params: FormScheduleListGridReportDropdownCellRendererParams;\r\n schedule: FormRevisionScheduleRowModel;\r\n editMode: boolean = false;\r\n isHovering: boolean = false;\r\n reports: Core.SavedSearchModel[];\r\n\r\n @ViewChild('outerDiv', { read: ElementRef, static: true }) outerDiv: ElementRef;\r\n\r\n agInit(params: FormScheduleListGridReportDropdownCellRendererParams): void {\r\n this.params = params;\r\n this.schedule = params.data as FormRevisionScheduleRowModel;\r\n this._editModeSub = this.params.editMode$.subscribe(x => this.editMode = x);\r\n this._reportsSub = this.params.reports$.subscribe(x => {\r\n this.reports = x;\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub && this._editModeSub.unsubscribe();\r\n this._reportsSub && this._reportsSub.unsubscribe();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onModelChange(value: Core.SavedSearchModel) {\r\n this.params.onValueChanged(this.params, value);\r\n }\r\n\r\n mouseover($event) {\r\n this.isHovering = this.editMode && this.params.canEdit(this.params);\r\n }\r\n\r\n mouseout($event) {\r\n if (this.isHovering && $event.relatedTarget) {\r\n // protect against clicks on inner children\r\n let parent = $event.relatedTarget.parentElement;\r\n while (parent) {\r\n if (parent === this.outerDiv.nativeElement) {\r\n return;\r\n }\r\n parent = parent.parentElement;\r\n }\r\n this.isHovering = false;\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Schedules [All Tax Years - All Assessors - {{taxYear}} {{ factorTablesAssessorName }} Tables]\r\n \r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { Subscription, BehaviorSubject } from 'rxjs';\r\nimport * as _ from 'lodash';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { FormService } from '../form.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator/busyIndicator.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, RowNode, CsvExportParams, ProcessCellForExportParams, ICellRendererParams, StartEditingCellParams } from 'ag-grid-community';\r\nimport { AgGridFilterParams, AgGridColumns } from '../../AgGrid';\r\nimport { FormScheduleListGridCheckboxCellRendererComponent, FormScheduleListGridCheckboxCellRendererParams } from './agGridCheckboxCellRender.component';\r\nimport { AgGridOptionsBuilder } from '../../AgGrid/agGridOptionsBuilder';\r\nimport { FormScheduleListGridActionCellRendererComponent, ICellRendererParamsForFormScheduleListGridAction } from './agGridActionCellRenderer.component';\r\nimport { FormScheduleListGridFactorTableDropdownCellRendererComponent, FormScheduleListGridFactorTableDropdownCellRendererComponentParams } from './agGridFactorTableDropdownCellRenderer.component';\r\nimport { FormScheduleListGridInputCellRendererComponent, FormScheduleListGridInputCellRendererParams } from './agGridInputCellRender.component';\r\nimport { WeissmanMutexService, IMutexServiceHandler } from '../../WeissmanMutexService';\r\nimport { BaseExpandableAgGridComponent } from '../../../UI-Lib/Expandable-Component/baseExpandableAgGridComponent';\r\nimport { FormScheduleListGridReportDropdownCellRendererComponent, FormScheduleListGridReportDropdownCellRendererParams } from './agGridReportDropdownCellRenderer.component';\r\n\r\nexport interface FormRevisionScheduleRowModel extends Compliance.FormRevisionScheduleModel {\r\n defaultFactorTable: Compliance.FormFactorTableModel;\r\n savedSearch: Core.SavedSearchModel;\r\n isFactorTableLocked: boolean;\r\n scheduleFactorTables: Compliance.FormRevisionScheduleFactorTableModel[];\r\n changed: boolean;\r\n deleted: boolean;\r\n added: boolean;\r\n originalValue: Compliance.FormRevisionScheduleModel;\r\n}\r\n\r\n@Component({\r\n selector: 'form-schedule-list',\r\n templateUrl: './formScheduleList.component.html',\r\n styleUrls: ['formScheduleList.component.scss']\r\n})\r\nexport class FormScheduleListComponent extends BaseExpandableAgGridComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _toastsManager: ToastrService) {\r\n super(_formService, 'form-schedule-list');\r\n }\r\n\r\n private _formRevisionSub: Subscription;\r\n private _formRevisionYearSub: Subscription;\r\n private _schedulesSub: Subscription;\r\n private _assessorSub: Subscription;\r\n private _assessorsSub: Subscription;\r\n private _reportsSub: Subscription;\r\n private _reportsSubject: BehaviorSubject = new BehaviorSubject([]);\r\n private _factorTablesSub: Subscription;\r\n private _factorTablesSubject: BehaviorSubject = new BehaviorSubject([]);\r\n private _gridApi: GridApi;\r\n private _editModeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _editModeSub: Subscription;\r\n\r\n get assessor(): Compliance.FormRevisionAssessorModel {\r\n return this._formService.assessor;\r\n }\r\n\r\n get factorTablesAssessorName(): string {\r\n return this._formService.factorTablesAssessorName;\r\n }\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._formService.assessor &&\r\n this._mutexService.canAcquire(this._formService.editGroup) &&\r\n ((!this._formService.assessor.isMappingCertified) &&\r\n ((!this._formService.assessor.isUsingDefaultTables) || (!this._formService.assessor.assessorId)));\r\n }\r\n\r\n get taxYear(): number {\r\n return this._formService.taxYear;\r\n }\r\n\r\n editMode: boolean = false;\r\n factorTables: Compliance.FormFactorTableModel[] = null;\r\n reports: Core.SavedSearchModel[] = null;\r\n gridId: System.Guid = '1508C9A3-CB71-4C28-98A7-ACE9E3BD1BBD';\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'grid-row-readonly': params => params.data && params.data.isSystem,\r\n 'grid-row-deleted': params => params.data && params.data.deleted\r\n },\r\n singleClickEdit: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .withFirstDataRendered(x => {\r\n x.api.sizeColumnsToFit();\r\n })\r\n .withoutCellEditingStoppedOnGridLostFocus()\r\n .build();\r\n\r\n ngOnInit(): void {\r\n this._editModeSub = this._editModeSubject.asObservable().subscribe(x => {\r\n this.editMode = x;\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n });\r\n\r\n this._formRevisionSub = this._formService.formRevision$.subscribe(() => {\r\n // initial load\r\n this._setRowData();\r\n });\r\n\r\n this._assessorSub = this._formService.assessor$.subscribe(() => {\r\n // assessor changed\r\n this._setRowData();\r\n });\r\n\r\n this._assessorsSub = this._formService.assessors$.subscribe(() => {\r\n // assessors changed (add/remove/change defaults)\r\n this._setRowData();\r\n });\r\n\r\n this._formRevisionYearSub = this._formService.formRevisionYear$.subscribe(() => {\r\n // year changed\r\n this._setRowData();\r\n });\r\n\r\n this._schedulesSub = this._formService.schedules$.subscribe(() => {\r\n // schedules changed\r\n this._setRowData();\r\n });\r\n\r\n this._factorTablesSub = this._formService.factorTables$.subscribe(() => {\r\n // factor tables changed\r\n this._setRowData();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub && this._editModeSub.unsubscribe();\r\n this._formRevisionSub && this._formRevisionSub.unsubscribe();\r\n this._schedulesSub && this._schedulesSub.unsubscribe();\r\n this._assessorSub && this._assessorSub.unsubscribe();\r\n this._assessorsSub && this._assessorsSub.unsubscribe();\r\n this._factorTablesSub && this._factorTablesSub.unsubscribe();\r\n this._reportsSub && this._reportsSub.unsubscribe();\r\n this._formRevisionYearSub && this._formRevisionYearSub.unsubscribe();\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n super.setGridApi(event.api);\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Name',\r\n field: 'name',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n editable: () => this._canEditSchedule.bind(this),\r\n cellEditorFramework: FormScheduleListGridInputCellRendererComponent,\r\n cellEditorParams: {\r\n canEdit: this._canEditSchedule.bind(this),\r\n editMode$: this._editModeSubject.asObservable(),\r\n onValueChanged: (params: FormScheduleListGridInputCellRendererParams, value: string) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return;\r\n }\r\n\r\n schedule.name = value;\r\n schedule.changed = true;\r\n }\r\n } as FormScheduleListGridInputCellRendererParams\r\n },\r\n {\r\n headerName: 'Abbr',\r\n field: 'abbr',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n editable: () => this._canEditSchedule.bind(this),\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellEditorFramework: FormScheduleListGridInputCellRendererComponent,\r\n cellEditorParams: {\r\n canEdit: this._canEditSchedule.bind(this),\r\n editMode$: this._editModeSubject.asObservable(),\r\n onValueChanged: (params: FormScheduleListGridInputCellRendererParams, value: string) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return;\r\n }\r\n\r\n schedule.abbr = value;\r\n schedule.changed = true;\r\n }\r\n } as FormScheduleListGridInputCellRendererParams\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n editable: () => this._canEditSchedule.bind(this),\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellEditorFramework: FormScheduleListGridInputCellRendererComponent,\r\n cellEditorParams: {\r\n canEdit: this._canEditSchedule.bind(this),\r\n editMode$: this._editModeSubject.asObservable(),\r\n onValueChanged: (params: FormScheduleListGridInputCellRendererParams, value: string) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return;\r\n }\r\n\r\n schedule.description = value;\r\n schedule.changed = true;\r\n }\r\n } as FormScheduleListGridInputCellRendererParams\r\n\r\n },\r\n {\r\n headerName: 'Taxable',\r\n field: 'isTaxable',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: FormScheduleListGridCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n onValueChanged: (params: FormScheduleListGridCheckboxCellRendererParams, value: boolean) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return;\r\n }\r\n\r\n schedule.isTaxable = value;\r\n schedule.changed = true;\r\n\r\n if (!schedule.isTaxable && schedule.isDepreciable) {\r\n schedule.isDepreciable = false;\r\n\r\n // remove any schedule factor tables\r\n schedule.scheduleFactorTables = [];\r\n schedule.defaultFactorTable = null;\r\n schedule.isFactorTableLocked = false;\r\n\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n }\r\n },\r\n isVisible: (params: FormScheduleListGridCheckboxCellRendererParams) => true,\r\n canEdit: this._canEditSchedule.bind(this),\r\n editMode$: this._editModeSubject.asObservable()\r\n } as FormScheduleListGridCheckboxCellRendererParams,\r\n },\r\n {\r\n headerName: 'Depreciable',\r\n field: 'isDepreciable',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: FormScheduleListGridCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n onValueChanged: (params: FormScheduleListGridCheckboxCellRendererParams, value: boolean) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return;\r\n }\r\n\r\n schedule.isDepreciable = value;\r\n schedule.changed = true;\r\n\r\n if ((!schedule.isDepreciable) && schedule.defaultFactorTable) {\r\n // if changing to non-depreciable, remove schedule factor tables\r\n schedule.scheduleFactorTables = [];\r\n this._setDefaultFactorTable(schedule);\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n }\r\n },\r\n isVisible: (params: FormScheduleListGridCheckboxCellRendererParams) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return false;\r\n }\r\n return schedule.isTaxable;\r\n },\r\n canEdit: this._canEditSchedule.bind(this),\r\n editMode$: this._editModeSubject.asObservable()\r\n } as FormScheduleListGridCheckboxCellRendererParams,\r\n },\r\n {\r\n headerName: 'Dep. Table',\r\n field: 'defaultFactorTable',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const schedule = params.node.data as FormRevisionScheduleRowModel;\r\n if (!(schedule && schedule.defaultFactorTable)) {\r\n return '';\r\n }\r\n\r\n return `${schedule.defaultFactorTable.factorTableName} (${schedule.defaultFactorTable.life} yr life)`;\r\n },\r\n cellRendererFramework: FormScheduleListGridFactorTableDropdownCellRendererComponent,\r\n cellRendererParams: {\r\n onValueChanged: (params: FormScheduleListGridFactorTableDropdownCellRendererComponentParams, value: Compliance.FormFactorTableModel) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return;\r\n }\r\n\r\n schedule.defaultFactorTable = value;\r\n schedule.changed = true;\r\n\r\n this._defaultFactorTableChanged(schedule);\r\n },\r\n canEdit: (params: FormScheduleListGridFactorTableDropdownCellRendererComponentParams) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return false;\r\n }\r\n if (schedule.isFactorTableLocked) {\r\n return false;\r\n }\r\n\r\n return this._canEditSchedule(params) && schedule.isDepreciable;\r\n },\r\n editMode$: this._editModeSubject.asObservable(),\r\n factorTables$: this._factorTablesSubject.asObservable()\r\n } as FormScheduleListGridFactorTableDropdownCellRendererComponentParams,\r\n },\r\n {\r\n headerName: 'Table Locked',\r\n field: 'isFactorTableLocked',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: FormScheduleListGridCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n onValueChanged: (params: FormScheduleListGridCheckboxCellRendererParams, value: boolean) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return;\r\n }\r\n\r\n schedule.isFactorTableLocked = value;\r\n schedule.changed = true;\r\n this._defaultFactorTableChanged(schedule);\r\n },\r\n isVisible: this._isLockVisible.bind(this),\r\n canEdit: this._canEditSchedule.bind(this),\r\n editMode$: this._editModeSubject.asObservable()\r\n } as FormScheduleListGridCheckboxCellRendererParams,\r\n },\r\n {\r\n headerName: 'Overflow Report',\r\n field: 'savedSearch',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n filterValueGetter: params => {\r\n const schedule = params.node.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return '';\r\n }\r\n\r\n return this._formService.getSavedSearchReportName(schedule.savedSearch);\r\n },\r\n cellRendererFramework: FormScheduleListGridReportDropdownCellRendererComponent,\r\n cellRendererParams: {\r\n onValueChanged: (params: FormScheduleListGridReportDropdownCellRendererParams, value: Core.SavedSearchModel) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return;\r\n }\r\n\r\n schedule.savedSearch = value;\r\n schedule.savedSearchId = value && value.savedSearchID;\r\n\r\n schedule.changed = true;\r\n },\r\n canEdit: (params: FormScheduleListGridReportDropdownCellRendererParams) => {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return false;\r\n }\r\n\r\n return this._canEditSchedule(params);\r\n },\r\n editMode$: this._editModeSubject.asObservable(),\r\n reports$: this._reportsSubject.asObservable()\r\n } as FormScheduleListGridReportDropdownCellRendererParams\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: FormScheduleListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canDelete: (params: ICellRendererParamsForFormScheduleListGridAction) => {\r\n const schedule = params.node.data as FormRevisionScheduleRowModel;\r\n return this.canEdit && this.editMode && schedule && !schedule.isSystem && !schedule.deleted;\r\n },\r\n canUndoDelete: (params: ICellRendererParamsForFormScheduleListGridAction) => {\r\n const schedule = params.node.data as FormRevisionScheduleRowModel;\r\n return this.canEdit && this.editMode && schedule && !schedule.isSystem && schedule.deleted;\r\n },\r\n delete: this.delete.bind(this),\r\n undoDelete: this.undoDelete.bind(this),\r\n } as ICellRendererParamsForFormScheduleListGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'name',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n async save(force?: boolean): Promise {\r\n if (!this.hasChanges()) {\r\n return Promise.resolve();\r\n }\r\n\r\n const schedules: Compliance.FormRevisionScheduleModel[] = [];\r\n\r\n let scheduleChangedToNonDepreciable = false;\r\n const abbrInvalid: string[] = [];\r\n const regexp = new RegExp('^[a-zA-Z0-9_]+$');\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const scheduleRow = node.data as FormRevisionScheduleRowModel;\r\n\r\n if (!scheduleRow.deleted) {\r\n // changed to non-depreciable?\r\n if (scheduleRow.originalValue && scheduleRow.originalValue.isDepreciable && !scheduleRow.isDepreciable) {\r\n scheduleChangedToNonDepreciable = true;\r\n }\r\n\r\n // abbr validation\r\n if (!regexp.test(scheduleRow.abbr)) {\r\n abbrInvalid.push(scheduleRow.abbr);\r\n }\r\n\r\n // map schedule entry\r\n const schedule = {\r\n formRevisionScheduleId: scheduleRow.formRevisionScheduleId,\r\n formRevisionId: scheduleRow.formRevisionId,\r\n name: scheduleRow.name,\r\n description: scheduleRow.description,\r\n isTaxable: scheduleRow.isTaxable,\r\n isReportable: scheduleRow.isReportable,\r\n isDepreciable: scheduleRow.isDepreciable,\r\n isSystem: false,\r\n abbr: scheduleRow.abbr,\r\n savedSearchId: scheduleRow.savedSearchId,\r\n scheduleFactorTables: _.cloneDeep(scheduleRow.scheduleFactorTables)\r\n } as Compliance.FormRevisionScheduleModel;\r\n\r\n schedules.push(schedule);\r\n }\r\n });\r\n\r\n if (abbrInvalid.length > 0) {\r\n this._toastsManager.error(`Abbreviation must be alphanumeric or underscore: '${_.join(abbrInvalid, ',')}'.`);\r\n return Promise.resolve();\r\n }\r\n\r\n const abbrDupes = _.map(_.filter(_.groupBy(_.map(schedules, x => x.abbr.toLowerCase())), x => x.length > 1), x => x[0]);\r\n if (abbrDupes.length > 0) {\r\n this._toastsManager.error(`Abbreviation must be unique: '${_.join(abbrDupes, ',')}'.`);\r\n return Promise.resolve();\r\n }\r\n\r\n if (scheduleChangedToNonDepreciable) {\r\n try {\r\n await this._messageModalService.prompt('Changing a schedule to non-depreciable will result in depreciation and index tables being removed from all asset classifications mapped to that schedule. Are you sure you want to continue?');\r\n }\r\n catch (ex) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving Schedules' });\r\n let confirmMessage: string = '';\r\n\r\n try {\r\n await this._formService.updateSchedules(schedules, force);\r\n\r\n this._editModeSubject.next(false);\r\n this._mutexService.release(this, this._formService.editGroup);\r\n\r\n return Promise.resolve();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n confirmMessage = e2.error.message;\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n confirmMessage,\r\n 'Confirm'\r\n );\r\n }\r\n catch (e3) {\r\n return Promise.resolve();\r\n }\r\n\r\n // force\r\n await this.save(true);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n const update: RowNode[] = [];\r\n const remove: FormRevisionScheduleRowModel[] = [];\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n\r\n const schedule = node.data as FormRevisionScheduleRowModel;\r\n\r\n if (schedule && !schedule.added) {\r\n update.push(node);\r\n\r\n schedule.abbr = schedule.originalValue.abbr;\r\n schedule.isDepreciable = schedule.originalValue.isDepreciable;\r\n schedule.formRevisionId = schedule.originalValue.formRevisionId;\r\n schedule.formRevisionScheduleId = schedule.originalValue.formRevisionScheduleId;\r\n schedule.description = schedule.originalValue.description;\r\n schedule.isReportable = schedule.originalValue.isReportable;\r\n schedule.isTaxable = schedule.originalValue.isTaxable;\r\n schedule.name = schedule.originalValue.name;\r\n schedule.savedSearchId = schedule.originalValue.savedSearchId;\r\n schedule.scheduleFactorTables = _.cloneDeep(schedule.originalValue.scheduleFactorTables);\r\n schedule.changed = false;\r\n schedule.deleted = false;\r\n\r\n this._setDefaultFactorTable(schedule);\r\n this._setSavedSearch(schedule);\r\n\r\n } else { // if added, remove it\r\n remove.push(schedule);\r\n }\r\n });\r\n\r\n this._gridApi.updateRowData({ remove: remove });\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this._editModeSubject.next(false);\r\n }\r\n\r\n async edit(): Promise {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n const res = await this._formService.checkEditDefaultAssessor();\r\n if (res) {\r\n this._mutexService.acquire(this, this._formService.editGroup);\r\n this._editModeSubject.next(true);\r\n }\r\n }\r\n\r\n add(): void {\r\n const newSchedule: FormRevisionScheduleRowModel = {\r\n description: '',\r\n name: '',\r\n isTaxable: true,\r\n isReportable: true,\r\n formRevisionId: this._formService.formRevisionId,\r\n formRevisionScheduleId: 0,\r\n isDepreciable: true,\r\n isSystem: false,\r\n abbr: '',\r\n defaultFactorTable: null,\r\n savedSearchId: null,\r\n savedSearch: null,\r\n isFactorTableLocked: false,\r\n scheduleFactorTables: [],\r\n changed: false,\r\n deleted: false,\r\n added: true,\r\n originalValue: null\r\n };\r\n\r\n this._gridApi.updateRowData({ add: [newSchedule] });\r\n\r\n const params: StartEditingCellParams = {\r\n rowIndex: 0,\r\n colKey: 'name'\r\n };\r\n\r\n this._gridApi.startEditingCell(params);\r\n }\r\n\r\n async delete(params: ICellRendererParamsForFormScheduleListGridAction): Promise {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return Promise.resolve();\r\n }\r\n\r\n if (!schedule.added) {\r\n schedule.deleted = true;\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n } else {\r\n this._gridApi.updateRowData({ remove: [schedule] });\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n undoDelete(params: ICellRendererParamsForFormScheduleListGridAction): void {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return;\r\n }\r\n\r\n schedule.deleted = false;\r\n\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n }\r\n\r\n hasChanges(): boolean {\r\n let hasChanges: boolean = false;\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const schedule = node.data as FormRevisionScheduleRowModel;\r\n if (schedule && (schedule.changed || schedule.deleted || schedule.added)) {\r\n hasChanges = true;\r\n }\r\n });\r\n\r\n return hasChanges;\r\n }\r\n\r\n export(): void {\r\n const params = {\r\n fileName: 'Schedules.csv',\r\n processCellCallback: (params: ProcessCellForExportParams) => {\r\n const field = params.column.getColDef().field;\r\n const schedule = params.node.data as FormRevisionScheduleRowModel;\r\n switch (field) {\r\n case 'defaultFactorTable':\r\n if (!(schedule && schedule.defaultFactorTable)) {\r\n return '';\r\n }\r\n return `${schedule.defaultFactorTable.factorTableName} (${schedule.defaultFactorTable.life} yr life)`;\r\n case 'savedSearch':\r\n if (!(schedule && schedule.savedSearch)) {\r\n return '';\r\n }\r\n return this._formService.getSavedSearchReportName(schedule.savedSearch);\r\n case 'isTaxable':\r\n return schedule.isTaxable ? 'Yes' : 'No';\r\n case 'isDepreciable':\r\n return schedule.isDepreciable ? 'Yes' : 'No';\r\n case 'isFactorTableLocked':\r\n return schedule.isFactorTableLocked ? 'Yes' : 'No';\r\n default:\r\n return params.value;\r\n }\r\n }\r\n } as CsvExportParams;\r\n this._gridApi.exportDataAsCsv(params);\r\n }\r\n\r\n private _setFactorTables(): void {\r\n this.factorTables = _.filter(this._formService.factorTables, (t) => t.tableType === Compliance.FactorTableTypeEnum.Depreciation);\r\n this._factorTablesSubject.next(this.factorTables);\r\n }\r\n\r\n private _setReports(): void {\r\n this.reports = _.filter(this._formService.allReports, (x) => x.searchName === 'Return Asset Detail');\r\n this._reportsSubject.next(this.reports);\r\n }\r\n\r\n private _canEditSchedule(params: ICellRendererParams): boolean {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return false;\r\n }\r\n\r\n return this.canEdit && !schedule.isSystem && !schedule.deleted;\r\n }\r\n\r\n private _isLockVisible(params: FormScheduleListGridCheckboxCellRendererParams): boolean {\r\n const schedule = params.data as FormRevisionScheduleRowModel;\r\n if (!schedule) {\r\n return false;\r\n }\r\n\r\n return schedule.defaultFactorTable !== null;\r\n }\r\n\r\n private _defaultFactorTableChanged(scheduleRow: FormRevisionScheduleRowModel): void {\r\n // if a default factor table is set, add or update schedule factor table record\r\n if (scheduleRow.defaultFactorTable) {\r\n\r\n // is there a default factor table record already?\r\n let scheduleFactorTable = _.find(scheduleRow.scheduleFactorTables,\r\n (x) => {\r\n return x.formRevisionYearAssessorId === this._formService.factorTableAssessorId;\r\n });\r\n\r\n // update record\r\n if (scheduleFactorTable) {\r\n scheduleFactorTable.formFactorTableId = scheduleRow.defaultFactorTable.formFactorTableId;\r\n scheduleFactorTable.isLocked = scheduleRow.isFactorTableLocked;\r\n } else {\r\n // add record\r\n scheduleFactorTable = {\r\n formRevisionScheduleFactorTableId: 0,\r\n formFactorTableId: scheduleRow.defaultFactorTable.formFactorTableId,\r\n formRevisionScheduleId: scheduleRow.formRevisionScheduleId,\r\n formRevisionYearAssessorId: this._formService.factorTableAssessorId,\r\n isLocked: scheduleRow.isFactorTableLocked\r\n } as Compliance.FormRevisionScheduleFactorTableModel;\r\n scheduleRow.scheduleFactorTables.push(scheduleFactorTable);\r\n }\r\n } else { // no default factor table, remove record\r\n _.remove(scheduleRow.scheduleFactorTables,\r\n (x) => {\r\n return x.formRevisionYearAssessorId === this._formService.factorTableAssessorId;\r\n });\r\n }\r\n }\r\n\r\n private _setSavedSearch(schedule: FormRevisionScheduleRowModel): void {\r\n if (!schedule.savedSearchId) {\r\n return;\r\n }\r\n\r\n schedule.savedSearch = _.find(this._formService.allReports, x => x.savedSearchID === schedule.savedSearchId);\r\n if (schedule.savedSearch === null) {\r\n console.warn(`Could not find saved search ID ${schedule.savedSearchId}`);\r\n }\r\n }\r\n\r\n private _setDefaultFactorTable(schedule: FormRevisionScheduleRowModel): void {\r\n let isLocked: boolean = false;\r\n let defaultFactorTable: Compliance.FormFactorTableModel = null;\r\n\r\n const scheduleFactorTable = _.find(schedule.scheduleFactorTables,\r\n (x) => {\r\n return x.formRevisionYearAssessorId === this._formService.factorTableAssessorId;\r\n });\r\n\r\n if (scheduleFactorTable) {\r\n isLocked = scheduleFactorTable.isLocked;\r\n defaultFactorTable = _.find(this.factorTables,\r\n (x) => {\r\n return x.formFactorTableId === scheduleFactorTable.formFactorTableId;\r\n });\r\n }\r\n\r\n schedule.isFactorTableLocked = isLocked;\r\n schedule.defaultFactorTable = defaultFactorTable;\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._formService.isInitialized)) {\r\n return;\r\n }\r\n\r\n this._setFactorTables();\r\n this._setReports();\r\n\r\n const formSchedules = _.map(_.filter(this._formService.schedules, (x) => !x.isSystem),\r\n (schedule) => {\r\n const rowModel: FormRevisionScheduleRowModel = {\r\n abbr: schedule.abbr,\r\n isDepreciable: schedule.isDepreciable,\r\n formRevisionId: schedule.formRevisionId,\r\n formRevisionScheduleId: schedule.formRevisionScheduleId,\r\n description: schedule.description,\r\n isReportable: schedule.isReportable,\r\n isTaxable: schedule.isTaxable,\r\n isSystem: false,\r\n name: schedule.name,\r\n defaultFactorTable: null,\r\n isFactorTableLocked: false,\r\n savedSearchId: schedule.savedSearchId,\r\n savedSearch: null,\r\n scheduleFactorTables: _.cloneDeep(schedule.scheduleFactorTables),\r\n changed: false,\r\n deleted: false,\r\n added: false,\r\n originalValue: schedule,\r\n };\r\n\r\n this._setDefaultFactorTable(rowModel);\r\n this._setSavedSearch(rowModel);\r\n\r\n return rowModel;\r\n });\r\n\r\n this._gridApi.setRowData(formSchedules);\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'form-year-list',\r\n templateUrl: './formYearList.component.html',\r\n styleUrls: ['formYearList.component.scss']\r\n})\r\nexport class FormYearListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _formService: FormService\r\n ) {}\r\n\r\n get years(): Compliance.FormRevisionYearModel[] {\r\n return this._formService.formRevisionYears;\r\n }\r\n\r\n selectedYear: UntypedFormControl = new UntypedFormControl();\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this.selectedYear.disable();\r\n\r\n this._formService.formRevision$.pipe(takeUntil(this.destroy$))\r\n .subscribe(() => {\r\n // initial load\r\n this.selectedYear.setValue(this._formService.formRevisionYear);\r\n });\r\n\r\n this._formService.formRevisionYear$.pipe(takeUntil(this.destroy$))\r\n .subscribe(() => {\r\n // year changed\r\n this.selectedYear.setValue(this._formService.formRevisionYear);\r\n });\r\n\r\n this._mutexService.lockChanged$.pipe(takeUntil(this.destroy$))\r\n .subscribe((val) => (!val.hasOwnProperty(this._formService.editGroup))\r\n ? this.selectedYear.enable()\r\n : this.selectedYear.disable());\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n async selectedYearChanged(year: Compliance.FormRevisionYearModel): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: `Loading ${ year && year.taxYear}` });\r\n try {\r\n await this._formService.setFormRevisionYear(year);\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n return Promise.resolve();\r\n }\r\n}\r\n","\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n Tax year {{ taxYear }} will be created and the following will be copied to it:\r\n
    \r\n
  • Assessors
  • \r\n
  • Schedule factor tables
  • \r\n
  • Factor tables
  • \r\n
  • Asset class mappings
  • \r\n
\r\n
\r\n
\r\n Tax year {{ taxYear }} will be created and assessors will be copied to it.\r\n
\r\n
\r\n
\r\n
\r\n
\r\n Are you sure you wish to continue?\r\n
\r\n
\r\n
\r\n
\r\n","
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { FormService } from '../form.service';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\n@Component({\r\n selector: 'form-year-new-modal',\r\n templateUrl: './formYearNewModal.component.html',\r\n styleUrls: ['./formYearNewModal.component.scss']\r\n})\r\nexport class FormYearNewModalComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formService: FormService) {\r\n }\r\n\r\n params: void;\r\n result: number;\r\n\r\n taxYear: number;\r\n\r\n get minTaxYear(): number {\r\n return this._formService.minFormRevisionYear.taxYear;\r\n }\r\n\r\n get maxTaxYear(): number {\r\n return this._formService.maxFormRevisionYear.taxYear;\r\n }\r\n\r\n get priorTaxYear(): number {\r\n return this.minTaxYear - 1;\r\n }\r\n\r\n get nextTaxYear(): number {\r\n return this.maxTaxYear + 1;\r\n }\r\n\r\n get isTaxYearIndeterminate(): boolean {\r\n return this.minTaxYear === this.maxTaxYear;\r\n }\r\n\r\n get isFormTypeAppeal(): boolean {\r\n return this._formService.isFormTypeAppeal;\r\n }\r\n\r\n get isFormTypeCompliance(): boolean {\r\n return this._formService.isFormTypeCompliance;\r\n }\r\n\r\n ngOnInit(): void {\r\n if (!this._formService.taxYear) {\r\n this._bsModalRef.hide();\r\n return;\r\n }\r\n\r\n // if the tax year can't be determined, default to next\r\n if(this.isTaxYearIndeterminate) {\r\n this.taxYear = this.nextTaxYear;\r\n }\r\n\r\n // if the current year is the minimum, create prior tax year\r\n if (this._formService.taxYear === this.minTaxYear) {\r\n this.taxYear = this.priorTaxYear;\r\n }\r\n\r\n // if the current year is the maximum, create next tax year\r\n if (this._formService.taxYear === this.maxTaxYear) {\r\n this.taxYear = this.nextTaxYear;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n }\r\n\r\n async save(): Promise {\r\n this.result = this.taxYear;\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { FormYearNewModalComponent } from '../Form-Year-New-Modal/formYearNewModal.component';\r\n\r\n@Component({\r\n selector: 'form-year-new',\r\n templateUrl: './formYearNew.component.html'\r\n})\r\nexport class FormYearNewComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _formService: FormService,\r\n private readonly _modalService: WeissmanModalService) { }\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._formService.editGroup);\r\n }\r\n\r\n get canCreateTaxYear(): boolean {\r\n return this._formService.isMaxFormRevisionYear || this._formService.isMinFormRevisionYear;\r\n }\r\n \r\n ngOnInit(): void { }\r\n\r\n ngOnDestroy(): void { }\r\n \r\n async createTaxYear(): Promise {\r\n const result = await this._modalService.showAsync(FormYearNewModalComponent, null, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: `Creating tax year ${result}` });\r\n\r\n try {\r\n await this._formService.createTaxYear(result);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n Forms certified for one or more assessors and forms that are included in a return batch may not be targeted.\r\n
\r\n
\r\n There are no available form revisions to copy to.\r\n
\r\n
\r\n
\r\n
\r\n","\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { List } from 'lodash';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\n@Component({\r\n selector: 'form-year-copy-list',\r\n templateUrl: './formYearCopyList.component.html'\r\n})\r\nexport class FormYearCopyListComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formService: FormService) {\r\n }\r\n\r\n params: void;\r\n result: number;\r\n\r\n formRevisionYears: Compliance.FormRevisionYearCopyModel[];\r\n selectedFormRevisionYear: Compliance.FormRevisionYearCopyModel;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n selectedFormRevisionName: string;\r\n selectedFormRevisionTaxYear: number;\r\n \r\n get taxYear(): number {\r\n return this._formService.taxYear;\r\n }\r\n\r\n get allAvailableTaxYearsForFormRevision(): number[] {\r\n if (this.selectedFormRevisionName){\r\n return [...new Set(this.formRevisionYears.filter( x => x.formRevisionName === this.selectedFormRevisionName).map(x => x.formRevisionTaxYear))];\r\n }\r\n \r\n return null;\r\n }\r\n\r\n get allAvailableFormRevisionNames(): string[] {\r\n if (this.formRevisionYears != null){\r\n return [...new Set(this.formRevisionYears.map(x => x.formRevisionName))];\r\n }\r\n \r\n return null;\r\n }\r\n\r\n get isSaveEnabled(): boolean {\r\n return this.selectedFormRevisionName != null && \r\n this.selectedFormRevisionName.length > 0 &&\r\n this.selectedFormRevisionTaxYear != null &&\r\n this.selectedFormRevisionTaxYear !== 0;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n const busyMsgLoading = 'loading';\r\n\r\n this.busyIndicatorMessageManager.add('Loading', busyMsgLoading);\r\n\r\n try {\r\n this.formRevisionYears = await this._formService.getByAvailableToCopyTo();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgLoading);\r\n }\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n save(): void {\r\n if (this.selectedFormRevisionName && this.selectedFormRevisionTaxYear){\r\n this.selectedFormRevisionYear = this.formRevisionYears.filter(x => x.formRevisionName === this.selectedFormRevisionName && x.formRevisionTaxYear === this.selectedFormRevisionTaxYear)[0];\r\n }\r\n\r\n this.result = this.selectedFormRevisionYear && this.selectedFormRevisionYear.formRevisionYearId;\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { FormYearCopyListComponent } from '../Form-Year-Copy-List/formYearCopyList.component';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\n@Component({\r\n selector: 'form-year-copy',\r\n templateUrl: './formYearCopy.component.html'\r\n})\r\nexport class FormYearCopyComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _formService: FormService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _toastsManager: ToastrService\r\n ) { }\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._formService.editGroup);\r\n }\r\n\r\n ngOnInit(): void { }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n async copyTaxYear(): Promise {\r\n const result = await this._modalService.showAsync(FormYearCopyListComponent, null, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n try {\r\n await this._messageModalService.prompt('Any existing mappings on the target form revision year will be overwritten with the following mappings from this form revision year: Assessors, Schedules, Factor Tables, Asset Class Mappings, Reports. Are you sure you wish to copy the tax year?', 'Confirm');\r\n } catch (e) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Copying tax year' });\r\n\r\n try {\r\n await this._formService.copyTo(result);\r\n\r\n this._toastsManager.success('Tax year successfully copied.');\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\n\r\n@Component({\r\n selector: 'form-year-delete',\r\n templateUrl: './formYearDelete.component.html'\r\n})\r\nexport class FormYearDeleteComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _formService: FormService,\r\n private readonly _messageModalService: MessageModalService\r\n ) { }\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._formService.editGroup);\r\n }\r\n\r\n get canDeleteTaxYear(): boolean {\r\n return this._formService.isMaxFormRevisionYear || this._formService.isMinFormRevisionYear;\r\n }\r\n\r\n get taxYear(): number {\r\n return this._formService.taxYear;\r\n }\r\n\r\n ngOnInit(): void { }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n async deleteTaxYear(): Promise {\r\n try {\r\n await this._messageModalService.prompt(`Are you sure you wish to delete tax year ${this.taxYear}?`, 'Confirm');\r\n } catch (e) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: `Deleting tax year ${this.taxYear}` });\r\n\r\n try {\r\n await this._formService.deleteTaxYear();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForFormAssessorsPanelGridAction extends ICellRendererParams {\r\n canEdit: (params: ICellRendererParamsForFormAssessorsPanelGridAction) => boolean;\r\n canEnterEditMode: () => boolean;\r\n canRemove: (params: ICellRendererParamsForFormAssessorsPanelGridAction) => boolean;\r\n remove: (params: ICellRendererParamsForFormAssessorsPanelGridAction) => void;\r\n edit: (params: ICellRendererParamsForFormAssessorsPanelGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n \r\n `\r\n})\r\nexport class FormAssessorsPanelGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForFormAssessorsPanelGridAction;\r\n\r\n agInit(params: ICellRendererParamsForFormAssessorsPanelGridAction): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onRemoveClicked(): void {\r\n this.params.remove(this.params);\r\n }\r\n}\r\n","\r\n"," 0\">\r\n\r\n\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { GridApi, GridReadyEvent, ColDef, GridOptions } from 'ag-grid-community';\r\nimport * as _ from 'lodash';\r\nimport { AgGridMultiSelectTracker } from '../../AgGrid/MultiSelectTracker/agGridMultiSelectTracker';\r\nimport { Subscription } from 'rxjs';\r\nimport { AgGridColumns } from '../../AgGrid/agGridColumns';\r\nimport { AgGridMultiSelectedHeaderRendererComponent } from '../../AgGrid/MultiSelectTracker/agGridMultiSelectHeaderRenderer.component';\r\nimport { AgGridMultiSelectedCellRendererComponent } from '../../AgGrid/MultiSelectTracker/agGridMultiSelectCellRenderer.component';\r\nimport { AgGridMultiSelectRendererParams } from '../../AgGrid/MultiSelectTracker/agGridMultiSelectTracker';\r\nimport { AgGridFilterParams } from '../../AgGrid/agGridFilterParams';\r\nimport { AgGridOptionsBuilder } from '../../AgGrid/agGridOptionsBuilder';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\nexport interface FormAssessorAddParams {\r\n formRevisionId: number;\r\n taxYear: number;\r\n}\r\n\r\ninterface FormRevisionAssessorSelectableModel extends Compliance.FormRevisionAssessorModel {\r\n isSelected: boolean;\r\n}\r\n\r\n@Component({\r\n templateUrl: './FormAssessorAdd.component.html',\r\n selector: 'form-assessor-add',\r\n styleUrls: ['./formAssessorAdd.component.scss']\r\n})\r\nexport class FormAssessorAddComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as FormRevisionAssessorSelectableModel).assessorId)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n params: FormAssessorAddParams;\r\n result: boolean;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n allAssessors: FormRevisionAssessorSelectableModel[];\r\n filteredAssessors: FormRevisionAssessorSelectableModel[];\r\n rowsSelected: boolean = false;\r\n\r\n async ngOnInit(): Promise {\r\n const assessors = this._formService.assessorsAvailableForAssignment;\r\n this.allAssessors = _.map(assessors.filter(item => !item.formRevisionYearAssessorId), (item) => {\r\n return { ...item, isSelected: false } as FormRevisionAssessorSelectableModel;\r\n }\r\n ) || [];\r\n\r\n this.filteredAssessors = this.allAssessors;\r\n\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.rowsSelected = x.selectAllRows || x.selectedRows.length > 0;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'assessorId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRendererComponent,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRendererComponent,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Name',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsg = 'saving';\r\n\r\n this.busyIndicatorMessageManager.add('Saving', busyMsg);\r\n\r\n try {\r\n const assessorIds = await this.gridTracker.getSelectedRowIds();\r\n\r\n await this._formService.associateAssessors(\r\n {\r\n taxYear: this.params.taxYear,\r\n assessorIds: assessorIds\r\n } as Compliance.FormRevisionAssessorAssociationModel);\r\n\r\n this.result = true;\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this.filteredAssessors);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map((x) => {\r\n const assessor = x.data as FormRevisionAssessorSelectableModel;\r\n return assessor && assessor.assessorId;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { HelpContentComponent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport interface AssessorAddressTooltipComponentParams {\r\n address: Core.AddressModel;\r\n}\r\n\r\n@Component({\r\n selector: 'assessor-address-tooltip',\r\n template: `\r\n No Address Selected\r\n \r\n `\r\n})\r\nexport class AssessorAddressTooltipComponent implements HelpContentComponent{\r\n params: AssessorAddressTooltipComponentParams;\r\n\r\n helpInit(params: AssessorAddressTooltipComponentParams): void {\r\n this.params = params;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { HelpContentComponentConfig } from '../../../UI-Lib/Help-Tooltip';\r\nimport {\r\n AssessorAddressTooltipComponent,\r\n AssessorAddressTooltipComponentParams\r\n} from './Assessor-Address-Tooltip/assessorAddressTooltip.component';\r\n\r\nexport interface FormAssessorListAddressCellRendererComponentParams extends ICellRendererParams {\r\n edit: (params: FormAssessorListAddressCellRendererComponentParams) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'assessor-address',\r\n template: `\r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class FormAssessorListAddressCellRendererComponent implements ICellRendererAngularComp {\r\n params: FormAssessorListAddressCellRendererComponentParams;\r\n assessor: Compliance.FormRevisionAssessorModel;\r\n\r\n contentComponent: HelpContentComponentConfig = {\r\n component: AssessorAddressTooltipComponent,\r\n componentParams: {\r\n address: null\r\n },\r\n canHover: false\r\n };\r\n\r\n agInit(params: FormAssessorListAddressCellRendererComponentParams): void {\r\n this.params = params;\r\n this.assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n this.contentComponent.componentParams.address = this.assessor.address;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GridApi, GridReadyEvent, ColDef, GridOptions, RowNode } from 'ag-grid-community';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { FormService } from '../form.service';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../AgGrid';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { AgGridCheckboxCellRendererComponent, ICellRendererParamsForAgGridCheckbox } from '../../AgGrid/CellRenderers/agGridCheckboxCellRender.component';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\nexport interface FormAssessorAddressPickerParams {\r\n formRevisionYearAssessorId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'form-assessor-address-picker',\r\n templateUrl: './formAssessorAddressPicker.component.html',\r\n styleUrls: ['./formAssessorAddressPicker.component.scss']\r\n})\r\nexport class FormAssessorAddressPickerComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _addressId: number;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && params.data.isSelected\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n params: FormAssessorAddressPickerParams;\r\n result: boolean;\r\n\r\n assessorAddresses: Compliance.FormRevisionYearAssessorAddressModel[];\r\n fryaAddress: Compliance.FormRevisionYearAssessorAddressModel = null;\r\n selectedAssessorAddress: Compliance.FormRevisionYearAssessorAddressModel = null;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n get addressChanged(): boolean {\r\n return this.selectedAssessorAddress && this.selectedAssessorAddress.addressID !== this._addressId;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n const addresses = await this._formService.getAssessorAddresses(this.params.formRevisionYearAssessorId);\r\n\r\n this.assessorAddresses = _.filter(addresses, x => !x.isFormRevisionYearAssessor);\r\n this.fryaAddress = _.find(addresses, x => x.isFormRevisionYearAssessor);\r\n this.selectedAssessorAddress = _.find(addresses, x => x.isSelected);\r\n\r\n this._addressId = this.selectedAssessorAddress && this.selectedAssessorAddress.addressID;\r\n this._setRowData();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: '',\r\n field: 'isSelected',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n suppressAutoSize: true,\r\n resizable: false,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n onValueChanged: this._onSelectEdited.bind(this),\r\n isVisible: (params) => {\r\n const assessorAddress = params.data as Compliance.FormRevisionYearAssessorAddressModel;\r\n return assessorAddress && !assessorAddress.isFormRevisionYearAssessor;\r\n },\r\n canEdit: (params) => {\r\n const assessorAddress = params.data as Compliance.FormRevisionYearAssessorAddressModel;\r\n return assessorAddress && !assessorAddress.isFormRevisionYearAssessor;\r\n },\r\n canEnterEditMode: () => true\r\n } as ICellRendererParamsForAgGridCheckbox\r\n },\r\n {\r\n headerName: 'Address',\r\n field: 'address',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n suppressMovable: true,\r\n valueFormatter: (params) => {\r\n const assessorAddress = params.data as Compliance.FormRevisionYearAssessorAddressModel;\r\n if (!assessorAddress) {\r\n return '';\r\n }\r\n\r\n let combined = '';\r\n if (assessorAddress.address1) {\r\n combined += assessorAddress.address1;\r\n }\r\n\r\n if (assessorAddress.address2) {\r\n combined += ` ${assessorAddress.address2}`;\r\n }\r\n\r\n return combined;\r\n },\r\n filterValueGetter: (params) => {\r\n const assessorAddress = params.data as Compliance.FormRevisionYearAssessorAddressModel;\r\n if (!assessorAddress) {\r\n return '';\r\n }\r\n\r\n let combined = '';\r\n if (assessorAddress.address1) {\r\n combined += assessorAddress.address1;\r\n }\r\n\r\n if (assessorAddress.address2) {\r\n combined += ` ${assessorAddress.address2}`;\r\n }\r\n\r\n return combined;\r\n }\r\n },\r\n {\r\n headerName: 'City',\r\n field: 'city',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n suppressMovable: true,\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n suppressMovable: true,\r\n valueFormatter: (params) => {\r\n const assessorAddress = params.data as Compliance.FormRevisionYearAssessorAddressModel;\r\n if (!(assessorAddress && assessorAddress.state)) {\r\n return '';\r\n }\r\n return assessorAddress.state.abbr;\r\n },\r\n filterValueGetter: (params) => {\r\n const assessorAddress = params.data as Compliance.FormRevisionYearAssessorAddressModel;\r\n if (!(assessorAddress && assessorAddress.state)) {\r\n return '';\r\n }\r\n return assessorAddress.state.abbr;\r\n }\r\n },\r\n {\r\n headerName: 'Zip',\r\n field: 'zip',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n suppressMovable: true,\r\n },\r\n {\r\n headerName: 'Correspondence',\r\n field: 'correspondenceType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n suppressMovable: true,\r\n },\r\n {\r\n headerName: 'Remark',\r\n field: 'remark',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n suppressMovable: true,\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n if (!this.selectedAssessorAddress) {\r\n return;\r\n }\r\n \r\n const busyMsg = 'saving';\r\n\r\n this.busyIndicatorMessageManager.add('Saving', busyMsg);\r\n\r\n try {\r\n if (this.addressChanged) {\r\n await this._formService.updateAssessorAddress(\r\n this.params.formRevisionYearAssessorId,\r\n this.selectedAssessorAddress.addressID);\r\n\r\n this.result = true;\r\n }\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.assessorAddresses)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this.assessorAddresses);\r\n this._gridApi.setPinnedTopRowData([ this.fryaAddress ]);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _onSelectEdited(params: ICellRendererParamsForAgGridCheckbox, newValue: boolean): void {\r\n const assessorAddress = params.data as Compliance.FormRevisionYearAssessorAddressModel;\r\n if (!assessorAddress) {\r\n return;\r\n }\r\n\r\n const update: RowNode[] = [];\r\n\r\n // on select, ensure all other rows are de-selected\r\n if (newValue) {\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const address = node.data as Compliance.FormRevisionYearAssessorAddressModel;\r\n\r\n if (address && address !== assessorAddress && address.isSelected) {\r\n address.isSelected = false;\r\n update.push(node);\r\n }\r\n });\r\n }\r\n\r\n assessorAddress.isSelected = newValue;\r\n update.push(params.node);\r\n\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this.selectedAssessorAddress = newValue ? assessorAddress : null;\r\n }\r\n}\r\n","
\r\n All assessors are certified.\r\n \r\n The following assessors are not certified:\r\n
\r\n
    \r\n
  • {{assessor.assessorName}}
  • \r\n
\r\n
\r\n
\r\n
\r\n\r\n","import { Component } from \"@angular/core\";\r\nimport { HelpContentComponent } from \"../../../../UI-Lib/Help-Tooltip\";\r\nimport FormRevisionAssessorModel = Compliance.FormRevisionAssessorModel;\r\n\r\nexport interface AssessorCertifiedTooltipParams {\r\n areAllAssessorsCertified: boolean;\r\n nonCertifiedAssessors: FormRevisionAssessorModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'assessor-certified-tooltip',\r\n templateUrl: 'assessorCertifiedTooltip.component.html',\r\n styleUrls: ['assessorCertifiedTooltip.component.scss']\r\n})\r\nexport class AssessorCertifiedTooltipComponent implements HelpContentComponent {\r\n params: AssessorCertifiedTooltipParams;\r\n\r\n helpInit(params: AssessorCertifiedTooltipParams): void {\r\n\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Assessors [All Assessors - {{taxYear}}]\r\n \r\n

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { ColDef, GridApi, GridReadyEvent, RowNode } from 'ag-grid-community';\r\nimport { FormAssessorsPanelGridActionCellRendererComponent, ICellRendererParamsForFormAssessorsPanelGridAction } from './agGridActionCellRenderer.component';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { AgGridCheckboxCellRendererComponent, ICellRendererParamsForAgGridCheckbox } from '../../AgGrid/CellRenderers/agGridCheckboxCellRender.component';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { BehaviorSubject, Subject, Subscription } from 'rxjs';\r\nimport { FormAssessorAddParams, FormAssessorAddComponent } from '../Form-Assessor-Add/formAssessorAdd.component';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from '../../AgGrid';\r\nimport { IMutexServiceHandler, WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { BaseExpandableAgGridComponent } from '../../../UI-Lib/Expandable-Component/baseExpandableAgGridComponent';\r\nimport * as _ from 'lodash';\r\nimport { FormAssessorListAddressCellRendererComponentParams, FormAssessorListAddressCellRendererComponent } from './agGridAddressCellRenderer.component';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from '../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { FormAssessorAddressPickerComponent, FormAssessorAddressPickerParams } from '../Form-Assessor-Address-Picker/formAssessorAddressPicker.component';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer, AgGridMultiSelectCellRendererParams, AgGridMultiSelectTracker, AgGridMultiSelectHeaderRendererParams } from '../../AgGrid/MultiSelectTracker';\r\nimport { takeUntil } from \"rxjs/internal/operators/takeUntil\";\r\nimport { HelpContentComponentConfig } from \"../../../UI-Lib/Help-Tooltip\";\r\nimport {\r\n AssessorCertifiedTooltipComponent,\r\n AssessorCertifiedTooltipParams\r\n} from \"./Assessor-Certified-Tooltip/assessorCertifiedTooltip.component\";\r\n\r\n@Component({\r\n selector: 'form-assessor-list',\r\n templateUrl: './formAssessorList.component.html',\r\n styleUrls: ['./formAssessorList.component.scss']\r\n})\r\nexport class FormAssessorListComponent extends BaseExpandableAgGridComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _modalService: WeissmanModalService) {\r\n super(_formService, 'form-assessor-list');\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _gridTracker: AgGridMultiSelectTracker;\r\n private _editModeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _destroy$: Subject = new Subject();\r\n\r\n get assessors(): Compliance.FormRevisionAssessorModel[] {\r\n return this._formService.assessors;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._formService.editGroup);\r\n }\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n get taxYear(): number {\r\n return this._formService.taxYear;\r\n }\r\n\r\n get hasSelectedRows(): boolean {\r\n return this._gridTracker && (this._gridTracker.hasSelectedRows() && !!this.selectedRows.length);\r\n }\r\n\r\n get selectedRows(): number[] {\r\n const rowModel = this._gridTracker && this._gridTracker.getSelectedRowsModel();\r\n const selected: number[] = [];\r\n this._gridApi.forEachNodeAfterFilterAndSort(node => {\r\n const data = node.data as Compliance.FormRevisionAssessorModel;\r\n if (!(data === this._formService.defaultAssessor || data.isMappingCertified)\r\n && (!rowModel.selectAllRows || !rowModel.selectedRows.find(d => d === data.formRevisionYearAssessorId))) {\r\n selected.push(data.formRevisionYearAssessorId);\r\n }\r\n });\r\n return selected;\r\n }\r\n\r\n areAllCertified: boolean;\r\n editMode: boolean;\r\n gridId: System.Guid = 'AFF812F3-C66D-46CE-9E50-7D6696219C06';\r\n\r\n gridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => {\r\n const data = params.data as Compliance.FormRevisionAssessorModel;\r\n return data && this._gridTracker.isRowSelected(data.formRevisionYearAssessorId) && !(data === this._formService.defaultAssessor || data.isMappingCertified);\r\n }\r\n },\r\n onFilterChanged: () => this._gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this._gridTracker.onGridSortChanged()\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .withRowId(x => {\r\n const assessor = x as Compliance.FormRevisionAssessorModel;\r\n return assessor && assessor.assessorId.toString();\r\n })\r\n .withFirstDataRendered(x => {\r\n x.api.sizeColumnsToFit();\r\n })\r\n .build();\r\n\r\n certifiedTooltip: HelpContentComponentConfig = {\r\n component: AssessorCertifiedTooltipComponent,\r\n canHover: true\r\n };\r\n\r\n ngOnInit(): void {\r\n this._editModeSubject.asObservable().subscribe(x => {\r\n this.editMode = x;\r\n if (this.gridOptions && this.gridOptions.columnApi) {\r\n this.gridOptions.columnApi.setColumnsVisible(['formRevisionYearAssessorId', 'actions'], this.editMode);\r\n this.gridOptions.api.sizeColumnsToFit();\r\n this._gridApi.redrawRows();\r\n }\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n });\r\n\r\n this._formService.formRevision$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n // initial load\r\n this._setRowData();\r\n });\r\n\r\n this._formService.formRevisionYear$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n // year changed\r\n this._setRowData();\r\n });\r\n\r\n this._formService.assessors$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n // assessors changed\r\n this._setRowData();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'formRevisionYearAssessorId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n hide: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this._gridTracker,\r\n isCellRendererDisabledFn: (rowId: number, data: Compliance.FormRevisionAssessorModel) => {\r\n let result = true;\r\n this._gridApi.forEachNodeAfterFilterAndSort(node => {\r\n const data = node.data as Compliance.FormRevisionAssessorModel;\r\n if (!(data === this._formService.defaultAssessor || data.isMappingCertified)) {\r\n result = false;\r\n }\r\n });\r\n return result;\r\n }\r\n } as AgGridMultiSelectHeaderRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this._gridTracker,\r\n isCellRendererDisabledFn: (rowId: number, data: Compliance.FormRevisionAssessorModel) => data === this._formService.defaultAssessor || data.isMappingCertified\r\n } as AgGridMultiSelectCellRendererParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n lockVisible: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n if (!(assessor && assessor.assessorId)) {\r\n return '';\r\n }\r\n return `#/assessor/${assessor.assessorId}`;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n return !(assessor && assessor.assessorId);\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Def. Tables',\r\n field: 'isUsingDefaultTables',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n hide: this._formService.isFormTypeAppeal,\r\n cellRendererParams: {\r\n isVisible: this._isVisibleAssessor.bind(this),\r\n canEdit: this._canEditDefaults.bind(this),\r\n canEnterEditMode: () => this.editMode || this.canEnterEditMode,\r\n onValueChanged: this._onValueChanged.bind(this)\r\n } as ICellRendererParamsForAgGridCheckbox\r\n },\r\n {\r\n headerName: 'Def. Mappings',\r\n field: 'isUsingDefaultMappings',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n hide: this._formService.isFormTypeAppeal,\r\n cellRendererParams: {\r\n isVisible: this._isVisibleAssessor.bind(this),\r\n canEdit: this._canEditDefaults.bind(this),\r\n canEnterEditMode: () => this.editMode || this.canEnterEditMode,\r\n onValueChanged: this._onValueChanged.bind(this)\r\n } as ICellRendererParamsForAgGridCheckbox\r\n },\r\n {\r\n headerName: 'Address',\r\n field: 'isValid',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n minWidth: AgGridColumns.textColumnSmallWidth,\r\n cellRendererFramework: FormAssessorListAddressCellRendererComponent,\r\n cellRendererParams: {\r\n edit: this._editAddress.bind(this),\r\n } as FormAssessorListAddressCellRendererComponentParams\r\n },\r\n {\r\n headerName: 'Certified',\r\n field: 'isMappingCertified',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n isVisible: (params: ICellRendererParamsForAgGridCheckbox) => true,\r\n canEdit: this._canCertifyAssessor.bind(this),\r\n canEnterEditMode: () => this.editMode || this.canEnterEditMode,\r\n onValueChanged: this._onValueChanged.bind(this)\r\n } as ICellRendererParamsForAgGridCheckbox\r\n },\r\n {\r\n headerName: 'RE',\r\n field: 'useForRE',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n hide: !this._formService.isFormTypeAppeal,\r\n cellRendererParams: {\r\n isVisible: this._isVisibleAssessor.bind(this),\r\n canEdit: this._canEditAssessor.bind(this),\r\n canEnterEditMode: () => this.editMode || this.canEnterEditMode,\r\n onValueChanged: this._onValueChanged.bind(this)\r\n } as ICellRendererParamsForAgGridCheckbox\r\n },\r\n {\r\n headerName: 'PP',\r\n field: 'useForPP',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n hide: !this._formService.isFormTypeAppeal,\r\n cellRendererParams: {\r\n isVisible: this._isVisibleAssessor.bind(this),\r\n canEdit: this._canEditAssessor.bind(this),\r\n canEnterEditMode: () => this.editMode || this.canEnterEditMode,\r\n onValueChanged: this._onValueChanged.bind(this)\r\n } as ICellRendererParamsForAgGridCheckbox\r\n },\r\n {\r\n headerName: 'CA',\r\n field: 'useForCA',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n hide: !this._formService.isFormTypeAppeal,\r\n cellRendererParams: {\r\n isVisible: this._isVisibleAssessor.bind(this),\r\n canEdit: this._canEditAssessor.bind(this),\r\n canEnterEditMode: () => this.editMode || this.canEnterEditMode,\r\n onValueChanged: this._onValueChanged.bind(this)\r\n } as ICellRendererParamsForAgGridCheckbox\r\n },\r\n {\r\n headerName: 'MN',\r\n field: 'useForMN',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n hide: !this._formService.isFormTypeAppeal,\r\n cellRendererParams: {\r\n isVisible: this._isVisibleAssessor.bind(this),\r\n canEdit: this._canEditAssessor.bind(this),\r\n canEnterEditMode: () => this.editMode || this.canEnterEditMode,\r\n onValueChanged: this._onValueChanged.bind(this)\r\n } as ICellRendererParamsForAgGridCheckbox\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n hide: true,\r\n cellRendererFramework: FormAssessorsPanelGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canEdit: this._canViewAssessor.bind(this),\r\n canEnterEditMode: () => this.editMode || this.canEnterEditMode,\r\n canRemove: this._canRemoveAssessor.bind(this),\r\n remove: this._onRemove.bind(this)\r\n } as ICellRendererParamsForFormAssessorsPanelGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'assessorName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n edit(): void {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n\r\n this._mutexService.acquire(this, this._formService.editGroup);\r\n this._editModeSubject.next(true);\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n this._gridTracker.clear();\r\n this._editModeSubject.next(false);\r\n }\r\n\r\n async addNewAssessor(): Promise {\r\n const params: FormAssessorAddParams = {\r\n formRevisionId: this._formService.formRevisionId,\r\n taxYear: this._formService.taxYear\r\n };\r\n\r\n await this._modalService.showAsync(FormAssessorAddComponent, params, 'modal-md');\r\n }\r\n\r\n async bulkRemove(): Promise {\r\n const rowModel = this._gridTracker.getSelectedRowsModel();\r\n const selected = (rowModel.selectAllRows) ? this.selectedRows : rowModel.selectedRows;\r\n if (!selected.length) {\r\n return Promise.resolve();\r\n }\r\n\r\n let busyRef = this._busyIndicatorService.show({ message: 'Removing Assessors' });\r\n\r\n try {\r\n await this._formService.disassociateAssessor(selected, false);\r\n } catch (e) {\r\n if (e && e.status !== 422) {\r\n return Promise.reject(e);\r\n }\r\n busyRef.hide();\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n e.error.message,\r\n 'Confirm Remove');\r\n } catch (e2) {\r\n return Promise.resolve();\r\n }\r\n\r\n busyRef = this._busyIndicatorService.show({ message: 'Removing Assessors' });\r\n await this._formService.disassociateAssessor(selected, true);\r\n\r\n this._gridTracker.clear();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._formService.isInitialized)) {\r\n return;\r\n }\r\n\r\n const assessors = _.filter(this._formService.assessorsAssigned, x => x !== this._formService.defaultAssessor);\r\n\r\n const update: RowNode[] = [];\r\n const remove: Compliance.FormRevisionAssessorModel[] = [];\r\n const add: Compliance.FormRevisionAssessorModel[] = [];\r\n\r\n _.forEach(assessors,\r\n x => {\r\n const row = this._gridApi.getRowNode(x.assessorId.toString());\r\n if (row) {\r\n const assessor = row.data as Compliance.FormRevisionAssessorModel;\r\n if (assessor) {\r\n _.extend(assessor, x);\r\n update.push(row);\r\n }\r\n } else {\r\n add.push(x);\r\n }\r\n });\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const assessor = node.data as Compliance.FormRevisionAssessorModel;\r\n if (assessor) {\r\n if (!_.find(assessors, x => x.assessorId === assessor.assessorId)) {\r\n remove.push(assessor);\r\n }\r\n }\r\n });\r\n\r\n this._gridApi.setPinnedTopRowData([this._formService.defaultAssessor]);\r\n this._gridApi.updateRowData({ remove: remove, add: add });\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this._areAllAssessorsCertified();\r\n }\r\n\r\n private async _editAddress(params: FormAssessorListAddressCellRendererComponentParams): Promise {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n\r\n if (!(this.editMode && assessor && !assessor.isMappingCertified)) {\r\n return;\r\n }\r\n\r\n const addressParams: FormAssessorAddressPickerParams = {\r\n formRevisionYearAssessorId: assessor.formRevisionYearAssessorId\r\n };\r\n\r\n await this._modalService.showAsync(FormAssessorAddressPickerComponent, addressParams, 'modal-lg');\r\n }\r\n\r\n private _canViewAssessor(params: ICellRendererParamsForFormAssessorsPanelGridAction): boolean {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n if (!assessor) {\r\n return false;\r\n }\r\n\r\n // for compliance forms do not allow editing when the assessor is using defaults\r\n if (!this._formService.isFormTypeAppeal && assessor.assessorId && assessor.isUsingDefaultMappings && assessor.isUsingDefaultTables) {\r\n return false;\r\n }\r\n\r\n return true;\r\n }\r\n\r\n private _canEditAssessor(params: ICellRendererParamsForFormAssessorsPanelGridAction): boolean {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n if (!assessor) {\r\n return false;\r\n }\r\n\r\n // for compliance forms do not allow editing when the assessor is using defaults\r\n if (!this._formService.isFormTypeAppeal && assessor.assessorId && assessor.isUsingDefaultMappings && assessor.isUsingDefaultTables) {\r\n return false;\r\n }\r\n\r\n return this.editMode && this.canEdit && !assessor.isMappingCertified;\r\n }\r\n\r\n private _canRemoveAssessor(params: ICellRendererParamsForFormAssessorsPanelGridAction): boolean {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n if (!assessor) {\r\n return false;\r\n }\r\n\r\n return this.editMode && this.canEdit && assessor.assessorId !== null && !assessor.isMappingCertified;\r\n }\r\n\r\n private _canEditDefaults(params: ICellRendererParamsForFormAssessorsPanelGridAction): boolean {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n if (!assessor) {\r\n return false;\r\n }\r\n\r\n return this.editMode && this.canEdit && assessor.assessorId !== null;\r\n }\r\n\r\n private _canCertifyAssessor(params: ICellRendererParamsForFormAssessorsPanelGridAction): boolean {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n if (!assessor) {\r\n return false;\r\n }\r\n\r\n // for compliance forms do not allow editing when the assessor is using defaults\r\n if (!this._formService.isFormTypeAppeal && assessor.assessorId && assessor.isUsingDefaultMappings && assessor.isUsingDefaultTables) {\r\n return false;\r\n }\r\n\r\n return this.editMode && this.canEdit;\r\n }\r\n\r\n private _isVisibleAssessor(params: ICellRendererParamsForFormAssessorsPanelGridAction): boolean {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n if (!assessor) {\r\n return false;\r\n }\r\n\r\n return assessor.assessorId !== null;\r\n }\r\n\r\n private async _onRemove(params: ICellRendererParamsForFormAssessorsPanelGridAction): Promise {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n if (!assessor) {\r\n return Promise.resolve();\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n `Are you sure you wish to remove '${assessor.assessorName}'?`,\r\n 'Confirm Remove');\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Removing Assessor' });\r\n\r\n try {\r\n await this._formService.disassociateAssessor([assessor.formRevisionYearAssessorId], true);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n this._areAllAssessorsCertified();\r\n }\r\n\r\n private async _onValueChanged(params: ICellRendererParamsForAgGridCheckbox, newValue: any): Promise {\r\n const assessor = params.data as Compliance.FormRevisionAssessorModel;\r\n\r\n if (newValue) {\r\n if (params.colDef.field === 'isUsingDefaultTables') {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to use default factor tables? This will revert factor tables to default.',\r\n 'Confirm Action');\r\n } catch (e1) {\r\n params.value = !newValue;\r\n assessor.isUsingDefaultTables = !newValue;\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Setting factor tables to default' });\r\n\r\n try {\r\n await this._formService.assessorChangeUseDefaultTables(assessor.formRevisionYearAssessorId, newValue);\r\n } catch (e2) {\r\n params.value = !newValue;\r\n assessor.isUsingDefaultTables = !newValue;\r\n await Promise.reject(e2);\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n } else if (params.colDef.field === 'isUsingDefaultMappings') {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to use default mappings? This will revert factor tables and asset class mappings to default values.',\r\n 'Confirm Action');\r\n } catch (e3) {\r\n params.value = !newValue;\r\n assessor.isUsingDefaultMappings = !newValue;\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Setting factor tables and asset class mappings to default' });\r\n\r\n try {\r\n await this._formService.assessorChangeUseDefaultMappings(assessor.formRevisionYearAssessorId, newValue);\r\n } catch (e4) {\r\n params.value = !newValue;\r\n assessor.isUsingDefaultMappings = !newValue;\r\n await Promise.reject(e4);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n } else if (_.startsWith(params.colDef.field, 'useFor')) {\r\n const busyRef = this._busyIndicatorService.show({ message: `Setting Property Type ${params.colDef.headerName} for ${assessor.assessorName}` });\r\n\r\n try {\r\n await this._formService.assessorChangeUsePropertyType(assessor.formRevisionYearAssessorId, newValue, params.colDef.field);\r\n } catch (e5) {\r\n params.value = !newValue;\r\n assessor[params.colDef.field] = !newValue;\r\n await Promise.reject(e5);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n } else if (params.colDef.field === 'isMappingCertified') {\r\n if (!assessor.assessorId) {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to update the certification for all assessors using default mappings?',\r\n 'Confirm Action');\r\n } catch (e6) {\r\n params.value = !newValue;;\r\n assessor.isMappingCertified = !newValue;\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Setting assessor certification' });\r\n\r\n try {\r\n await this._formService.assessorChangeIsCertified(assessor.formRevisionYearAssessorId, newValue);\r\n } catch (e7) {\r\n params.value = !newValue;\r\n assessor.isMappingCertified = !newValue;\r\n await Promise.reject(e7);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n } else {\r\n if (params.colDef.field === 'isUsingDefaultTables') {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Copying factor table default settings.' });\r\n\r\n try {\r\n await this._formService.assessorChangeUseDefaultTables(assessor.formRevisionYearAssessorId, newValue);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n } else if (params.colDef.field === 'isUsingDefaultMappings') {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Copying factor table and asset class mapping default settings.' });\r\n\r\n try {\r\n await this._formService.assessorChangeUseDefaultMappings(assessor.formRevisionYearAssessorId, newValue);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n } else if (_.startsWith(params.colDef.field, 'useFor')) {\r\n const busyRef = this._busyIndicatorService.show({ message: `Unsetting Property Type ${params.colDef.headerName} for ${assessor.assessorName}` });\r\n\r\n try {\r\n await this._formService.assessorChangeUsePropertyType(assessor.formRevisionYearAssessorId, newValue, params.colDef.field);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n } else if (params.colDef.field === 'isMappingCertified') {\r\n if (!assessor.assessorId) {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to update the certification for all assessors using default mappings?',\r\n 'Confirm Action');\r\n } catch (e6) {\r\n params.value = !newValue;;\r\n assessor.isMappingCertified = !newValue;\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Setting assessor certification' });\r\n\r\n try {\r\n await this._formService.assessorChangeIsCertified(assessor.formRevisionYearAssessorId, newValue);\r\n } catch (e9) {\r\n params.value = !newValue;\r\n assessor.isMappingCertified = !newValue;\r\n await Promise.reject(e9);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n }\r\n\r\n this._areAllAssessorsCertified();\r\n }\r\n\r\n private _areAllAssessorsCertified(): void {\r\n this.areAllCertified = this._formService.assessorsAssigned.every(x => x.isMappingCertified);\r\n let nonCertifiedAssessors = [];\r\n if (!this.areAllCertified) {\r\n nonCertifiedAssessors = this._formService.assessorsAssigned.filter(x => {\r\n return x !== this._formService.defaultAssessor && !x.isMappingCertified;\r\n });\r\n }\r\n\r\n this.certifiedTooltip.componentParams = {\r\n areAllAssessorsCertified: this.areAllCertified,\r\n nonCertifiedAssessors\r\n }\r\n }\r\n\r\n private _getGridRowIds(skip, take): Compliance.QueryResultModel {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return {\r\n data: rows.map((x) => {\r\n const assessor = x.data as Compliance.FormRevisionAssessorModel;\r\n return assessor && assessor.formRevisionYearAssessorId;\r\n })\r\n } as Compliance.QueryResultModel;\r\n }\r\n}\r\n","\r\n\r\n","import { Component } from '@angular/core';\r\nimport { FormService } from '../form.service';\r\nimport { CommentModalData } from '../../../Comments/comments.service';\r\n\r\n@Component({\r\n selector: 'form-comments',\r\n templateUrl: './FormComments.component.html'\r\n})\r\nexport class FormCommentsComponent {\r\n constructor(\r\n private readonly _formService: FormService\r\n ){ }\r\n\r\n get formRevision(): Compliance.FormRevisionModel {\r\n return this._formService.formRevision;\r\n }\r\n\r\n getCommentModalData() {\r\n return {\r\n entityID: this.formRevision.formRevisionId,\r\n entityTypeID: Core.EntityTypes.FormRevision,\r\n description: this._formService.formRevision && this._formService.formRevision.name,\r\n year: this._formService.taxYear ? this._formService.taxYear.toString() : null,\r\n canEdit: this._formService.canEdit\r\n } as CommentModalData;\r\n }\r\n}\r\n","\r\n\r\n","import { Component } from '@angular/core';\r\nimport { FormService } from '../form.service';\r\nimport { AttachmentModalData } from '../../../Attachment/attachment.modal.model';\r\n\r\n@Component({\r\n selector: 'form-attachments',\r\n templateUrl: './FormAttachments.component.html'\r\n})\r\nexport class FormAttachmentsComponent {\r\n constructor(\r\n private readonly _formService: FormService\r\n ) { }\r\n\r\n get formRevision(): Compliance.FormRevisionModel {\r\n return this._formService.formRevision;\r\n }\r\n\r\n getAttachmentModalData() {\r\n return {\r\n entityType: 'FormRevision',\r\n entityName: this._formService.formRevision && this._formService.formRevision.name,\r\n entityData: {\r\n typeId: Core.EntityTypes.FormRevision,\r\n id: this._formService.formRevision && this._formService.formRevision.formRevisionId,\r\n name: this._formService.formRevision && this._formService.formRevision.name\r\n },\r\n readOnly: !this._formService.canEdit,\r\n singleYear: true,\r\n year: this._formService.taxYear,\r\n disableYears: true\r\n } as AttachmentModalData;\r\n }\r\n}\r\n"," 0\">\r\n\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport { FormService } from '../form.service';\r\nimport { Subscription } from 'rxjs';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams } from '../../AgGrid';\r\nimport { GridApi, GridReadyEvent, ColDef, GridOptions } from 'ag-grid-community';\r\nimport { AgGridMultiSelectTracker, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer, AgGridMultiSelectRendererParams } from '../../AgGrid/MultiSelectTracker';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\n@Component({\r\n selector: 'form-factor-table-add',\r\n templateUrl: './formFactorTableAdd.component.html',\r\n styleUrls: ['formFactorTableAdd.component.scss']\r\n})\r\nexport class FormFactorTableAddComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n private _availableFactorTables: Compliance.FactorTableListItemModelSelectable[] = null;\r\n\r\n params: void;\r\n result: Compliance.FactorTableListItemModel[];\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.FactorTableListItemModelSelectable).factorTableId)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n rowsSelected: boolean = false;\r\n\r\n ngOnInit(): void {\r\n const result = _.filter(this._formService.allFactorTables, (aft) => !_.some(this._formService.factorTables, (fft) => { return aft.factorTableId === fft.factorTableId; }));\r\n this._availableFactorTables = _.map(result, (fft) => { return { ...fft, isSelected: false } as Compliance.FactorTableListItemModelSelectable; });\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n if (this._selectedRowsSub) {\r\n this._selectedRowsSub.unsubscribe();\r\n }\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.rowsSelected = x.selectAllRows || x.selectedRows.length > 0;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'factorTableId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const factorTable = params.data as Compliance.FactorTableListItemModel;\r\n if (!factorTable) {\r\n return '';\r\n }\r\n return factorTable.assessorName ? factorTable.assessorName : factorTable.state;\r\n },\r\n filterValueGetter: params => {\r\n const factorTable = params.data as Compliance.FactorTableListItemModel;\r\n if (!factorTable) {\r\n return '';\r\n }\r\n return factorTable.assessorName ? factorTable.assessorName : factorTable.state;\r\n },\r\n cellClass: params => {\r\n const factorTable = params.data as Compliance.FactorTableListItemModel;\r\n if (!factorTable) {\r\n return '';\r\n }\r\n return factorTable.assessorName ? '' : 'assessor-state';\r\n }\r\n },\r\n {\r\n headerName: 'Name',\r\n field: 'name',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Life',\r\n type: 'numericColumn',\r\n field: 'life',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'tableType',\r\n filterValueGetter: x => {\r\n return (x.data) ? this._formService.getFactorTableTypeName(x.data.tableType) : '';\r\n },\r\n valueFormatter: x => {\r\n return (x.data) ? this._formService.getFactorTableTypeName(x.data.tableType) : '';\r\n },\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save(): Promise {\r\n const selectedRows = await this.gridTracker.getSelectedRowIds();\r\n const nodes = [];\r\n this._gridApi.forEachNode(x => {\r\n const ft = x.data as Compliance.FactorTableListItemModel;\r\n if (selectedRows.includes(ft.factorTableId)) {\r\n nodes.push(ft);\r\n }\r\n });\r\n this.result = nodes;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._formService.isInitialized)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._availableFactorTables);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map(x => {\r\n const factorTable = x.data as Compliance.FactorTableListItemModel;\r\n return factorTable && factorTable.factorTableId;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface FormFactorTableListGridActionCellRendererParams extends ICellRendererParams {\r\n viewDetails: (params: FormFactorTableListGridActionCellRendererParams) => void;\r\n canEdit: (params: FormFactorTableListGridActionCellRendererParams) => boolean;\r\n canEnterEditMode: (params: FormFactorTableListGridActionCellRendererParams) => boolean;\r\n canRemove: (params: FormFactorTableListGridActionCellRendererParams) => boolean;\r\n remove: (params: FormFactorTableListGridActionCellRendererParams) => void;\r\n canUndoRemove: (params: FormFactorTableListGridActionCellRendererParams) => boolean;\r\n undoRemove: (params: FormFactorTableListGridActionCellRendererParams) => void;\r\n\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n \r\n \r\n \r\n `\r\n})\r\nexport class FormFactorTableListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: FormFactorTableListGridActionCellRendererParams;\r\n\r\n agInit(params: FormFactorTableListGridActionCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Factor Tables [{{factorTablesAssessorName}} - {{taxYear}}]\r\n \r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { FormService } from '../form.service';\r\nimport { FormFactorTableAddComponent } from '../Form-Factor-Table-Add/formFactorTableAdd.component';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { ColDef, GridApi, GridReadyEvent, RowNode } from 'ag-grid-community';\r\nimport { AgGridFilterParams, AgGridColumns } from '../../AgGrid';\r\nimport { AgGridOptionsBuilder } from '../../AgGrid';\r\nimport { FormFactorTableListGridActionCellRendererComponent, FormFactorTableListGridActionCellRendererParams } from './agGridActionCellRenderer.component';\r\nimport { IMutexServiceHandler, WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { BaseExpandableAgGridComponent } from '../../../UI-Lib/Expandable-Component/baseExpandableAgGridComponent';\r\nimport { BehaviorSubject, Subject } from 'rxjs';\r\nimport { FactorTableDetailsComponent, FactorTableDetailsParams } from '../../Factor-Table/Factor-Table-Details/factorTableDetails.component';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { AgGridMultiSelectCellRendererParams, AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectHeaderRendererParams, AgGridMultiSelectTracker } from '../../AgGrid/MultiSelectTracker';\r\nimport { takeUntil } from 'rxjs/internal/operators/takeUntil';\r\nimport * as _ from 'lodash';\r\nimport { FormRevisionReportRowModel } from '../Form-Report-List/formReportList.component';\r\n\r\nexport interface FormFactorTableRowModel extends Compliance.FormFactorTableModel {\r\n deleted: boolean;\r\n added: boolean;\r\n originalValue: Compliance.FormRevisionReportModel;\r\n displayName: string;\r\n}\r\n\r\n@Component({\r\n selector: 'form-factor-table-list',\r\n templateUrl: './formFactorTableList.component.html',\r\n styleUrls: ['./formFactorTableList.component.scss']\r\n})\r\nexport class FormFactorTableListComponent extends BaseExpandableAgGridComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService) {\r\n super(_formService, 'form-factor-table-list');\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _gridTracker: AgGridMultiSelectTracker;\r\n private _editModeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _destroy$: Subject = new Subject();\r\n\r\n get assessor(): Compliance.FormRevisionAssessorModel {\r\n return this._formService.assessor;\r\n }\r\n\r\n get factorTablesAssessorName(): string {\r\n return this._formService.factorTablesAssessorName;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._formService.assessor &&\r\n this._mutexService.canAcquire(this._formService.editGroup) &&\r\n (!this._formService.assessor.isMappingCertified &&\r\n (!this._formService.assessor.isUsingDefaultTables ||\r\n (this._formService.assessor && !this._formService.assessor.assessorId)));\r\n }\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n get taxYear(): number {\r\n return this._formService.taxYear;\r\n }\r\n\r\n get hasSelectedRows(): boolean {\r\n return this._gridTracker && this._gridTracker.hasSelectedRows();\r\n }\r\n\r\n get hasChanges(): boolean {\r\n let hasChanges: boolean = false;\r\n\r\n if (this._gridApi) {\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const report = node.data as FormRevisionReportRowModel;\r\n if (report && (report.deleted || report.added)) {\r\n hasChanges = true;\r\n }\r\n });\r\n }\r\n\r\n return hasChanges;\r\n }\r\n\r\n editMode: boolean = false;\r\n canRemove: boolean = false;\r\n canUndoRemove: boolean = false;\r\n hasRemovedSelected: boolean = false;\r\n gridId: System.Guid = '5DAD3F51-DA76-4A6B-B937-2CD709963E11';\r\n\r\n gridOptions = new AgGridOptionsBuilder(\r\n {\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => {\r\n const data = params.data as Compliance.FormFactorTableModel;\r\n return data && this._gridTracker.isRowSelected(data.formFactorTableId);\r\n },\r\n 'grid-row-deleted': params => params.data && params.data.deleted\r\n },\r\n onFilterChanged: () => this._gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this._gridTracker.onGridSortChanged()\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .withTextSelection()\r\n .withFirstDataRendered(x => {\r\n x.api.sizeColumnsToFit();\r\n })\r\n .build();\r\n\r\n ngOnInit(): void {\r\n this._editModeSubject.asObservable().subscribe(x => {\r\n this.editMode = x;\r\n if (this.gridOptions && this.gridOptions.columnApi) {\r\n this.gridOptions.columnApi.setColumnVisible('formFactorTableId', this.editMode);\r\n this.gridOptions.api.sizeColumnsToFit();\r\n }\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n });\r\n\r\n this._formService.formRevision$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n // initial load\r\n this._setRowData();\r\n });\r\n\r\n this._formService.formRevisionYear$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n // year changed\r\n this._setRowData();\r\n });\r\n\r\n this._formService.assessor$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n // assessor selected\r\n this._setRowData();\r\n });\r\n\r\n this._formService.assessors$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n // assessors changed (add/remove/change defaults)\r\n this._setRowData();\r\n });\r\n\r\n this._formService.factorTables$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n // factor tables changed\r\n this._setRowData();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n super.setGridApi(event.api);\r\n this._gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe(x => {\r\n const rows = this._getRowNodesFromSelectModel(x);\r\n this.hasRemovedSelected = !!rows.find(x => x.data.deleted);\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'formFactorTableId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n hide: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this._gridTracker,\r\n isCellRendererDisabledFn: (rowId: number, data: Compliance.FormFactorTableModel) => !this._canEditFactorTable()\r\n } as AgGridMultiSelectHeaderRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this._gridTracker,\r\n isCellRendererDisabledFn: (rowId: number, data: Compliance.FormFactorTableModel) => !this._canEditFactorTable()\r\n } as AgGridMultiSelectCellRendererParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessor',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n suppressMenu: true,\r\n valueFormatter: (params) => {\r\n const formFactorTable = params.data as Compliance.FormFactorTableModel;\r\n if (!formFactorTable) {\r\n return '';\r\n }\r\n return formFactorTable.assessor ? formFactorTable.assessor : formFactorTable.state;\r\n },\r\n filterValueGetter: params => {\r\n const formFactorTable = params.data as Compliance.FormFactorTableModel;\r\n if (!formFactorTable) {\r\n return '';\r\n }\r\n return formFactorTable.assessor ? formFactorTable.assessor : formFactorTable.state;\r\n },\r\n cellClass: params => {\r\n const formFactorTable = params.data as Compliance.FormFactorTableModel;\r\n if (!formFactorTable) {\r\n return '';\r\n }\r\n return formFactorTable.assessor ? '' : 'assessor-state';\r\n }\r\n },\r\n {\r\n headerName: 'Name',\r\n field: 'factorTableName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth\r\n },\r\n {\r\n headerName: 'Life',\r\n field: 'life',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n lockPinned: true,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n suppressMenu: true\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'TableType',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const formFactorTable = params.data as Compliance.FormFactorTableModel;\r\n if (!formFactorTable) {\r\n return '';\r\n }\r\n return this._formService.getFactorTableTypeName(formFactorTable.tableType);\r\n },\r\n filterValueGetter: params => {\r\n const formFactorTable = params.data as Compliance.FormFactorTableModel;\r\n if (!formFactorTable) {\r\n return '';\r\n }\r\n\r\n return this._formService.getFactorTableTypeName(formFactorTable.tableType);\r\n }\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n suppressMenu: true,\r\n sortable: false,\r\n cellRendererFramework: FormFactorTableListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this.viewDetails.bind(this),\r\n canEdit: this._canEditFactorTable.bind(this),\r\n canEnterEditMode: (params: FormFactorTableListGridActionCellRendererParams) => this.canEnterEditMode,\r\n canRemove: this._canRemove.bind(this),\r\n remove: this._remove.bind(this),\r\n canUndoRemove: this._canUndoRemove.bind(this),\r\n undoRemove: this._undoRemove.bind(this)\r\n } as FormFactorTableListGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'assessor',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n async edit(): Promise {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n const res = await this._formService.checkEditDefaultAssessor();\r\n if (res) {\r\n this._mutexService.acquire(this, this._formService.editGroup);\r\n this._editModeSubject.next(true);\r\n }\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n const update: RowNode[] = [];\r\n const remove: FormRevisionReportRowModel[] = [];\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const report = node.data as FormRevisionReportRowModel;\r\n\r\n if (report && !report.added) {\r\n update.push(node);\r\n\r\n _.extend(report, report.originalValue, { changed: false, deleted: false });\r\n\r\n } else { // if added, remove it\r\n remove.push(report);\r\n }\r\n });\r\n\r\n this._gridApi.updateRowData({ remove: remove });\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this._editModeSubject.next(false);\r\n }\r\n\r\n async add(): Promise {\r\n const result = await this._modalService.showAsync(FormFactorTableAddComponent, null, 'modal-xl');\r\n\r\n if (!result) {\r\n return;\r\n }\r\n\r\n const newReports = result.map((x) => {\r\n return {\r\n ...x,\r\n ...{\r\n formFactorTableId: x.factorTableId,\r\n assessor: x.assessorName,\r\n factorTableName: x.name,\r\n isFrequentlyUsed: true,\r\n isIncluded: false,\r\n added: true,\r\n deleted: false,\r\n originalValue: null\r\n }\r\n };\r\n });\r\n\r\n this._gridApi.updateRowData({ add: newReports });\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async save(force: boolean): Promise {\r\n // Clear grid selections\r\n const rowModel = this._gridTracker.getSelectedRowsModel();\r\n const selected = this._getRowNodesFromSelectModel(rowModel);\r\n this._gridTracker.clear();\r\n this._gridApi.redrawRows({ rowNodes: selected });\r\n\r\n let associations = 0;\r\n let disassociations = 0;\r\n const update = [];\r\n\r\n this._gridApi.forEachNode(x => {\r\n const ft = x.data as FormFactorTableRowModel;\r\n associations += ft.added ? 1 : 0;\r\n disassociations += ft.deleted ? 1 : 0;\r\n if (!ft.deleted) {\r\n update.push(ft.factorTableId);\r\n }\r\n });\r\n\r\n if (!disassociations) {\r\n force = true;\r\n }\r\n\r\n if (!force) {\r\n try {\r\n await this._messageModalService.confirm(\r\n `Are you sure you wish to ${associations ? `add ${ associations } factor table${ associations > 1 ? 's' : ''}` : ''} ${associations && disassociations ? 'and' : ''} ${disassociations ? `remove ${ disassociations } factor table${ disassociations > 1 ? 's' : ''}` : ''}?`,\r\n 'Confirm Save'\r\n );\r\n } catch (e1) {\r\n return;\r\n }\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating Factor Tables' });\r\n let confirmMessage: string = '';\r\n try {\r\n await this._formService.updateFactorTables(this._formService.assessorId, update, force);\r\n if (force) {\r\n this._editModeSubject.next(false);\r\n this._mutexService.release(this, this._formService.editGroup);\r\n this._setRowData();\r\n return;\r\n }\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n confirmMessage = e2.error.message;\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n\r\n if (confirmMessage) {\r\n try {\r\n await this._messageModalService.confirm(\r\n confirmMessage,\r\n 'Confirm Update'\r\n );\r\n }\r\n catch (e3) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n // force\r\n await this.save(true);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n bulkRemove(): void {\r\n const rowModel = this._gridTracker.getSelectedRowsModel();\r\n const selected = this._getRowNodesFromSelectModel(rowModel);\r\n\r\n if (!selected.length) {\r\n return;\r\n }\r\n\r\n selected.forEach(x => {\r\n const ft = x.data as FormFactorTableRowModel;\r\n if (ft.added) {\r\n this._gridApi.updateRowData({ remove: [ft] });\r\n } else {\r\n ft.deleted = true;\r\n }\r\n });\r\n\r\n this._gridTracker.clear();\r\n this._gridApi.redrawRows({ rowNodes: selected });\r\n }\r\n\r\n bulkUndoRemove(): void {\r\n const rowModel = this._gridTracker.getSelectedRowsModel();\r\n const selected = this._getRowNodesFromSelectModel(rowModel);\r\n\r\n if (!selected.length) {\r\n return;\r\n }\r\n\r\n selected.forEach(x => {\r\n const ft = x.data as FormFactorTableRowModel;\r\n ft.deleted = false;\r\n });\r\n\r\n this._gridTracker.clear();\r\n this._gridApi.redrawRows({ rowNodes: selected });\r\n }\r\n\r\n async viewDetails(params: FormFactorTableListGridActionCellRendererParams): Promise {\r\n const formFactorTable = params.data as Compliance.FormFactorTableModel;\r\n if (!formFactorTable) {\r\n return Promise.resolve();\r\n }\r\n\r\n const tableParams: FactorTableDetailsParams = {\r\n editMode: false,\r\n factorTableId: formFactorTable.factorTableId\r\n };\r\n\r\n await this._modalService.showAsync(FactorTableDetailsComponent, tableParams, 'modal-lg');\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private _canEditFactorTable(params?: FormFactorTableListGridActionCellRendererParams): boolean {\r\n // do not allow editing when the assessor is using defaults\r\n if (this._formService.assessor && this._formService.assessor.assessorId && this._formService.assessor.isUsingDefaultTables) {\r\n return false;\r\n }\r\n\r\n return this.canEdit;\r\n }\r\n\r\n private _setRowData() {\r\n if (!(this._gridApi && this._formService.isInitialized)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._formService.factorTables);\r\n }\r\n\r\n private _getGridRowIds(skip, take): Compliance.QueryResultModel {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return {\r\n data: rows.map((x) => {\r\n const factorTable = x.data as Compliance.FormFactorTableModel;\r\n return factorTable && factorTable.formFactorTableId;\r\n })\r\n } as Compliance.QueryResultModel;\r\n }\r\n\r\n private _remove(params: FormFactorTableListGridActionCellRendererParams): void {\r\n const ft = params.data as FormFactorTableRowModel;\r\n if (!ft) {\r\n return;\r\n }\r\n\r\n if (!ft.added) {\r\n ft.deleted = true;\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n } else {\r\n this._gridApi.updateRowData({ remove: [ft] });\r\n }\r\n }\r\n\r\n private _undoRemove(params: FormFactorTableListGridActionCellRendererParams): void {\r\n const ft = params.data as FormFactorTableRowModel;\r\n if (!ft) {\r\n return;\r\n }\r\n\r\n ft.deleted = false;\r\n\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n }\r\n\r\n private _canRemove(params: FormFactorTableListGridActionCellRendererParams): boolean {\r\n const ft = params.data as FormFactorTableRowModel;\r\n if (!ft) {\r\n return false;\r\n }\r\n\r\n return this.editMode && !ft.deleted;\r\n }\r\n\r\n private _canUndoRemove(params: FormFactorTableListGridActionCellRendererParams): boolean {\r\n const ft = params.data as FormFactorTableRowModel;\r\n if (!ft) {\r\n return false;\r\n }\r\n\r\n return this.editMode && ft.deleted;\r\n }\r\n\r\n private _getRowNodesFromSelectModel(selectModel: Compliance.SelectedRowsModel): RowNode[] {\r\n const nodes = [];\r\n this._gridApi.forEachNode(x => {\r\n const ft = x.data as FormFactorTableRowModel;\r\n if ((!selectModel.selectAllRows && selectModel.selectedRows.find(y => ft.formFactorTableId === y))\r\n || (selectModel.selectAllRows && !selectModel.selectedRows.find(y => ft.formFactorTableId === y))) {\r\n nodes.push(x);\r\n }\r\n });\r\n return nodes;\r\n }\r\n}\r\n","import { Component, ViewChild, ElementRef } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular/main';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { Subscription, BehaviorSubject } from 'rxjs';\r\n\r\nexport interface ICellRendererParamsForDropdowns extends ICellRendererParams {\r\n editMode$: BehaviorSubject;\r\n canEdit: (params: ICellRendererParamsForDropdowns) => boolean;\r\n isDisabled: (params: ICellRendererParamsForDropdowns) => boolean;\r\n dropdownItems: any[];\r\n name: string;\r\n valueField: string;\r\n allowNull: boolean;\r\n originalValue: any;\r\n displayGetter: (dropdownItem: any) => string;\r\n change: (params: ICellRendererParamsForDropdowns) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'form-asset-class-mapping-cell-renderer',\r\n template: `
\r\n
{{ getDisplayValue() }}**
\r\n
\r\n \r\n
\r\n
`,\r\n styleUrls: ['./../agGridCellStyles.scss', './agGridDropdownCellRenderer.component.scss']\r\n})\r\nexport class DropdownCellRenderer implements ICellRendererAngularComp {\r\n private _editModeSub: Subscription;\r\n\r\n params: ICellRendererParamsForDropdowns;\r\n editMode: boolean = false;\r\n isHovering: boolean;\r\n @ViewChild('outerDiv', { read: ElementRef, static: true }) outerDiv: ElementRef;\r\n\r\n agInit(params: ICellRendererParamsForDropdowns): void {\r\n this.params = params;\r\n this._editModeSub = this.params.editMode$.subscribe(x => this.editMode = x);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub.unsubscribe();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onModelChange(value: any) {\r\n this.params.originalValue = this.params.data[this.params.colDef.field];\r\n this.params.data[this.params.colDef.field] = value;\r\n this.params.change(this.params);\r\n }\r\n\r\n overridesParentValue(): boolean {\r\n if (!this.params.data) { return false; }\r\n switch (this.params.colDef.field) {\r\n case 'formRevisionScheduleId': {\r\n return this.params.data.isScheduleOverridden;\r\n }\r\n case 'depreciationFactorTableId': {\r\n return this.params.data.isDepreciationOverridden;\r\n }\r\n case 'indexFactorTableId': {\r\n return this.params.data.isFactorOverridden;\r\n }\r\n default: return false;\r\n }\r\n }\r\n\r\n hasChildOverride(): boolean {\r\n if (!this.params.data) { return false; }\r\n switch (this.params.colDef.field) {\r\n case 'formRevisionScheduleId': {\r\n return this.params.data.childOverridesSchedule;\r\n }\r\n case 'depreciationFactorTableId': {\r\n return this.params.data.childOverridesDepreciation;\r\n }\r\n case 'indexFactorTableId': {\r\n return this.params.data.childOverridesFactor;\r\n }\r\n default: return false;\r\n }\r\n }\r\n\r\n mouseover($event) {\r\n this.isHovering = this.editMode && this.params.canEdit(this.params);\r\n }\r\n\r\n mouseout($event) {\r\n if (this.editMode && this.params.canEdit(this.params) && $event.relatedTarget) {\r\n // protect against clicks on inner children\r\n let parent = $event.relatedTarget.parentElement;\r\n while (parent) {\r\n if (parent === this.outerDiv.nativeElement) {\r\n return;\r\n }\r\n parent = parent.parentElement;\r\n }\r\n this.isHovering = false;\r\n }\r\n }\r\n\r\n getDisplayValue(): string {\r\n if (!this.params.data) {\r\n return null;\r\n }\r\n const dropdownItem = this.params.dropdownItems.find(x => x[this.params.valueField] === this.params.data[this.params.colDef.field]);\r\n return (dropdownItem && this.params.displayGetter(dropdownItem)) || null;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface FormAssetClassMappingListGridActionCellRendererParams extends ICellRendererParams {\r\n viewDepreciationTable: (params: FormAssetClassMappingListGridActionCellRendererParams) => void;\r\n canViewDepreciationTable: (params: FormAssetClassMappingListGridActionCellRendererParams) => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n \r\n `\r\n})\r\nexport class FormAssetClassMappingListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: FormAssetClassMappingListGridActionCellRendererParams;\r\n\r\n agInit(params: FormAssetClassMappingListGridActionCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Asset Class Mappings [{{classificationMappingsAssessorName}} Mappings - {{ factorTablesAssessorName }} Tables - {{taxYear}}]\r\n \r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { ColDef, ColumnApi, GridApi, GridOptions, GridReadyEvent, FilterChangedEvent, IFilterOptionDef, RowNode } from 'ag-grid-community';\r\nimport { BusyIndicatorService, SnackBarService } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { FormRepository } from '../../Repositories';\r\nimport { DropdownCellRenderer, ICellRendererParamsForDropdowns } from './agGridDropdownCellRenderer.component';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams } from '../../AgGrid';\r\nimport { WeissmanMutexService, IMutexServiceHandler } from '../../WeissmanMutexService';\r\nimport { BaseExpandableAgGridComponent } from '../../../UI-Lib/Expandable-Component/baseExpandableAgGridComponent';\r\nimport { FormAssetClassMappingListGridActionCellRendererComponent, FormAssetClassMappingListGridActionCellRendererParams } from './agGridActionCellRenderer.component';\r\nimport { Subscription, BehaviorSubject, lastValueFrom } from 'rxjs';\r\nimport { FactorTableDetailsComponent, FactorTableDetailsParams } from '../../Factor-Table/Factor-Table-Details/factorTableDetails.component';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { AgGridCheckboxCellRendererComponent, ICellRendererParamsForAgGridCheckbox } from '../../AgGrid/CellRenderers/agGridCheckboxCellRender.component';\r\nimport * as _ from 'lodash';\r\nimport {\r\n ExpandCellRendererComponent,\r\n ICellRendererParamsForExpandCellRenderer\r\n} from '../../../Common/AgGrid/agGridExpandCellRenderer.component';\r\nimport {\r\n ExpandCellHeaderRendererComponent,\r\n ICellRendererParamsForExpandCellHeaderParams\r\n} from '../../../Common/AgGrid/agGridExpandCellHeaderRenderer.component';\r\n\r\nexport class FormClassificationMappingTreeItemModel implements Compliance.FormClassificationMappingModel {\r\n formClassificationMappingId: number;\r\n assetClassificationId: number;\r\n depreciationFactorTableId?: number;\r\n isDepreciationFactorTableLocked: boolean;\r\n ownedFormRevisionScheduleId?: number;\r\n leasedToFormRevisionScheduleId?: number;\r\n leasedFromFormRevisionScheduleId?: number;\r\n indexFactorTableId?: number;\r\n level: number;\r\n isScheduleOverridden?: boolean;\r\n isDepreciationOverridden?: boolean;\r\n isIndexOverridden?: boolean;\r\n childOverridesSchedule?: boolean;\r\n childOverridesDepreciation?: boolean;\r\n childOverridesIndex?: boolean;\r\n assetClassName: string;\r\n assetClassAllowPerpetual: boolean;\r\n parentTreeItem?: FormClassificationMappingTreeItemModel;\r\n isFormRevisionScheduleReportable: boolean;\r\n isExempt: boolean;\r\n}\r\n\r\ninterface ScheduleFactorTableModel {\r\n factorTableId: number;\r\n isLocked: boolean;\r\n isReportable: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'form-asset-class-mapping',\r\n templateUrl: './formAssetClassMapping.component.html',\r\n styleUrls: ['./formAssetClassMapping.component.scss']\r\n})\r\nexport class FormAssetClassMappingComponent extends BaseExpandableAgGridComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n // The asset class mapping is a grid for associating schedules and factor tables to classifications. It uses a grid structure, but has nodes which can be\r\n // expanded and collapsed and which will automatically expand during search to show matching children. A later change also happened to allow the user to\r\n // select a node where children should be filtered out, and exclude the children from the current filter, to allow a more interactive navigation.\r\n // The grid itself is fed _mappingViewData, a getter which creates a view from _flattenedData.\r\n // The complications around filtering are handled in two main ways - first, there is an onAgGridFilterChanged event which uses the various filter options\r\n // to determine if nodes should be expanded to find the inner children. Second the filter itself has to, for schedule and factor table, use the wider data\r\n // around those by feeding in the assetClassName as the filter value, then doing a lookup with that in the filterMappingLookup method to look inside _flattened data.\r\n\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _formRepository: FormRepository,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _snackBarService: SnackBarService\r\n ) {\r\n super(_formService, 'form-asset-class-mapping');\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _gridColumnApi: ColumnApi;\r\n private _formRevisionSub: Subscription;\r\n private _formRevisionYearSub: Subscription;\r\n private _schedulesSub: Subscription;\r\n private _factorTableSub: Subscription;\r\n private _assessorSub: Subscription;\r\n private _assessorsSub: Subscription;\r\n private _editModeSubject = new BehaviorSubject(false);\r\n private _editModeSub: Subscription;\r\n private _classificationMappingsUpdatedSub: Subscription;\r\n private _assetClassificationsNameMap: { [s: string]: Compliance.AssetClassificationModel } = {};\r\n private _flattenedData: FormClassificationMappingTreeItemModel[] = [];\r\n private _flattenedAssetClassificationsFullList: Compliance.AssetClassificationModel[] = [];\r\n private _childrenAssetIdsToShowDespiteFilter: number[] = [];\r\n private _expandedClassifications = new Set();\r\n private _collapsedClassifications = new Set();\r\n private _indexFactorTables: Compliance.FormFactorTableModel[] = [];\r\n private _depreciationFactorTables: Compliance.FormFactorTableModel[] = [];\r\n private _originalMappingViewData: FormClassificationMappingTreeItemModel[];\r\n private _canExpandAllRows: boolean = true;\r\n private _filteredOutChildrenMap: Map = new Map();\r\n private _parentRequiredFilterSet: Set = new Set();\r\n\r\n editMode: boolean = false;\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n formRevisionSchedules: Compliance.FormRevisionScheduleModel[] = [];\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._formService.assessor &&\r\n this._mutexService.canAcquire(this._formService.editGroup) &&\r\n ((!this._formService.assessor.isMappingCertified) &&\r\n ((!this._formService.assessor.isUsingDefaultMappings) ||\r\n (this._formService.assessor && !this._formService.assessor.assessorId)));\r\n }\r\n\r\n get factorTablesAssessorName(): string {\r\n return this._formService.factorTablesAssessorName;\r\n }\r\n\r\n get classificationMappingsAssessorName(): string {\r\n return this._formService.classificationMappingsAssessorName;\r\n }\r\n\r\n get assessor(): Compliance.FormRevisionAssessorModel {\r\n return this._formService.assessor;\r\n }\r\n\r\n get taxYear(): number {\r\n return this._formService.taxYear;\r\n }\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'no-filter-applies': (params) => params.data && this._parentRequiredFilterSet.has(params.data.assetClassificationId)\r\n}\r\n })\r\n .withColumnResize()\r\n .withLoadingOverlay()\r\n .withContext(this)\r\n .withTextSelection()\r\n .build();\r\n\r\n async ngOnInit(): Promise {\r\n this._editModeSub = this._editModeSubject.asObservable().subscribe(x => {\r\n this.editMode = x;\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n });\r\n\r\n this._formRevisionSub = this._formService.formRevision$.subscribe(() => {\r\n this._setAssetClassifications();\r\n\r\n // initial load\r\n this._setRowData();\r\n });\r\n\r\n this._assessorSub = this._formService.assessor$.subscribe(() => {\r\n // assessor changed\r\n this._setRowData();\r\n });\r\n\r\n this._assessorsSub = this._formService.assessors$.subscribe(() => {\r\n // assessors changed (add/remove/change defaults)\r\n this._setRowData();\r\n });\r\n\r\n this._formRevisionYearSub = this._formService.formRevisionYear$.subscribe(() => {\r\n // year changed\r\n this._setRowData();\r\n });\r\n\r\n this._schedulesSub = this._formService.schedules$.subscribe(() => {\r\n // schedules changed\r\n this._setRowData();\r\n });\r\n\r\n this._factorTableSub = this._formService.factorTables$.subscribe(() => {\r\n // factor tables changed\r\n this._setRowData();\r\n });\r\n\r\n this._classificationMappingsUpdatedSub = this._formService.assetClassificationMappings$.subscribe(() => {\r\n // mappings updated\r\n this._setRowData();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._formRevisionSub.unsubscribe();\r\n this._editModeSub.unsubscribe();\r\n this._schedulesSub.unsubscribe();\r\n this._factorTableSub.unsubscribe();\r\n this._assessorSub.unsubscribe();\r\n this._assessorsSub.unsubscribe();\r\n this._classificationMappingsUpdatedSub.unsubscribe();\r\n this._formRevisionYearSub.unsubscribe();\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n // get API objects and start setting up the AgGrid\r\n this._gridApi = event.api;\r\n this._gridColumnApi = event.columnApi;\r\n super.setGridApi(event.api);\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Asset Class',\r\n field: 'assetClassName',\r\n lockPinned: true,\r\n filter: 'agTextColumnFilter',\r\n filterValueGetter: x => (x.data ? `${x.data['assetClassName']}@${x.data['assetClassificationId']}` : ''),\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith'],\r\n textCustomComparator: this._filterName.bind(this),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n suppressMenu: true,\r\n cellClass: (params) => {\r\n if (params.data && params.data.level) {\r\n return `tree-level-${params.data.level}`;\r\n }\r\n return '';\r\n },\r\n cellRendererFramework: ExpandCellRendererComponent,\r\n cellRendererParams: {\r\n expand: this._expand.bind(this),\r\n collapse: this._collapse.bind(this),\r\n canExpand: this._canExpand.bind(this),\r\n canCollapse: this._canCollapse.bind(this),\r\n canShowHiddenChildren: this._canShowHiddenChildren.bind(this),\r\n showHiddenChildren: this._showHiddenChildren.bind(this),\r\n getName: this._getName.bind(this),\r\n getTooltip: this._getTooltip.bind(this)\r\n } as ICellRendererParamsForExpandCellRenderer,\r\n headerComponentFramework: ExpandCellHeaderRendererComponent,\r\n headerComponentParams: {\r\n expandAll: this._expandAll.bind(this),\r\n collapseAll: this._collapseAll.bind(this),\r\n canExpandAll: this._canExpandAll.bind(this),\r\n canCollapseAll: this._canCollapseAll.bind(this),\r\n headerText: 'Asset Class'\r\n }\r\n },\r\n {\r\n headerName: 'Owned Schedule',\r\n field: 'ownedFormRevisionScheduleId',\r\n filter: 'agTextColumnFilter',\r\n filterValueGetter: x => (x.data ? `${x.data['assetClassName']}@${x.data['assetClassificationId']}` : ''),\r\n filterParams: {\r\n filterOptions: [\r\n 'startsWith',\r\n 'equals',\r\n 'notEqual',\r\n 'contains',\r\n 'notContains',\r\n 'endsWith',\r\n AgGridFilterParams.blankFilterOptionDef,\r\n AgGridFilterParams.notBlankFilterOptionDef],\r\n textCustomComparator: this._filterMappingLookup.bind(this, 'ownedFormRevisionScheduleId', 'formRevisionScheduleId', this.formRevisionSchedules, x => `${x.name} (${x.abbr})`),\r\n newRowsAction: 'keep',\r\n suppressAndOrCondition: true,\r\n defaultOption: 'contains'\r\n },\r\n cellRendererFramework: DropdownCellRenderer,\r\n cellRendererParams: {\r\n canEdit: (x) => this.canEdit,\r\n editMode$: this._editModeSubject.asObservable(),\r\n isDisabled: (x) => false,\r\n dropdownItems: this.formRevisionSchedules,\r\n name: 'schedule',\r\n valueField: 'formRevisionScheduleId',\r\n allowNull: true,\r\n change: this.scheduleChanged.bind(this),\r\n displayGetter: (item: Compliance.FormRevisionScheduleModel) => `${item.name} (${item.abbr})`\r\n }\r\n },\r\n {\r\n headerName: 'Dep. Table',\r\n field: 'depreciationFactorTableId',\r\n filter: 'agTextColumnFilter',\r\n filterValueGetter: x => (x.data ? `${x.data['assetClassName']}@${x.data['assetClassificationId']}` : ''),\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith', AgGridFilterParams.blankFilterOptionDef, AgGridFilterParams.notBlankFilterOptionDef],\r\n textCustomComparator: this._filterMappingLookup.bind(this, 'depreciationFactorTableId', 'factorTableId', this._depreciationFactorTables, this.factorAssessorTableRenderer),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n cellRendererFramework: DropdownCellRenderer,\r\n cellRendererParams: {\r\n canEdit: (x) => {\r\n const row = x.data as FormClassificationMappingTreeItemModel;\r\n return this.canEdit &&\r\n row &&\r\n (row.isFormRevisionScheduleReportable && !row.isDepreciationFactorTableLocked);\r\n },\r\n isDisabled: (x) => false,\r\n editMode$: this._editModeSubject.asObservable(),\r\n dropdownItems: this._depreciationFactorTables,\r\n name: 'depreciationFactorTable',\r\n valueField: 'factorTableId',\r\n allowNull: true,\r\n change: this.depreciationTableChanged.bind(this),\r\n displayGetter: this.factorAssessorTableRenderer\r\n }\r\n },\r\n {\r\n headerName: 'Leased To Schedule',\r\n field: 'leasedToFormRevisionScheduleId',\r\n filter: 'agTextColumnFilter',\r\n filterValueGetter: x => (x.data ? `${x.data['assetClassName']}@${x.data['assetClassificationId']}` : ''),\r\n filterParams: {\r\n filterOptions: [\r\n 'startsWith',\r\n 'equals',\r\n 'notEqual',\r\n 'contains',\r\n 'notContains',\r\n 'endsWith',\r\n AgGridFilterParams.blankFilterOptionDef,\r\n AgGridFilterParams.notBlankFilterOptionDef],\r\n textCustomComparator: this._filterMappingLookup.bind(this, 'leasedToFormRevisionScheduleId', 'formRevisionScheduleId', this.formRevisionSchedules, x => `${x.name} (${x.abbr})`),\r\n newRowsAction: 'keep',\r\n suppressAndOrCondition: true,\r\n defaultOption: 'contains'\r\n },\r\n cellRendererFramework: DropdownCellRenderer,\r\n cellRendererParams: {\r\n canEdit: (x) => this.canEdit,\r\n editMode$: this._editModeSubject.asObservable(),\r\n isDisabled: (x) => false,\r\n dropdownItems: this.formRevisionSchedules,\r\n name: 'schedule',\r\n valueField: 'formRevisionScheduleId',\r\n allowNull: true,\r\n change: this.leasedToScheduleChanged.bind(this),\r\n displayGetter: (item: Compliance.FormRevisionScheduleModel) => `${item.name} (${item.abbr})`\r\n }\r\n },\r\n {\r\n headerName: 'Leased From Schedule',\r\n field: 'leasedFromFormRevisionScheduleId',\r\n filter: 'agTextColumnFilter',\r\n filterValueGetter: x => (x.data ? `${x.data['assetClassName']}@${x.data['assetClassificationId']}` : ''),\r\n filterParams: {\r\n filterOptions: [\r\n 'startsWith',\r\n 'equals',\r\n 'notEqual',\r\n 'contains',\r\n 'notContains',\r\n 'endsWith',\r\n AgGridFilterParams.blankFilterOptionDef,\r\n AgGridFilterParams.notBlankFilterOptionDef],\r\n textCustomComparator: this._filterMappingLookup.bind(this, 'leasedFromFormRevisionScheduleId', 'formRevisionScheduleId', this.formRevisionSchedules, x => `${x.name} (${x.abbr})`),\r\n newRowsAction: 'keep',\r\n suppressAndOrCondition: true,\r\n defaultOption: 'contains'\r\n },\r\n cellRendererFramework: DropdownCellRenderer,\r\n cellRendererParams: {\r\n canEdit: (x) => this.canEdit,\r\n editMode$: this._editModeSubject.asObservable(),\r\n isDisabled: (x) => false,\r\n dropdownItems: this.formRevisionSchedules,\r\n name: 'schedule',\r\n valueField: 'formRevisionScheduleId',\r\n allowNull: true,\r\n change: this.leasedFromScheduleChanged.bind(this),\r\n displayGetter: (item: Compliance.FormRevisionScheduleModel) => `${item.name} (${item.abbr})`\r\n }\r\n },\r\n {\r\n headerName: 'Index Table',\r\n field: 'indexFactorTableId',\r\n filter: 'agTextColumnFilter',\r\n filterValueGetter: x => (x.data ? `${x.data['assetClassName']}@${x.data['assetClassificationId']}` : ''),\r\n filterParams: {\r\n filterOptions: ['startsWith', 'equals', 'notEqual', 'contains', 'notContains', 'endsWith', AgGridFilterParams.blankFilterOptionDef, AgGridFilterParams.notBlankFilterOptionDef],\r\n textCustomComparator: this._filterMappingLookup.bind(this, 'indexFactorTableId', 'factorTableId', this._indexFactorTables, this.factorAssessorTableRenderer),\r\n newRowsAction: 'keep',\r\n defaultOption: 'contains',\r\n suppressAndOrCondition: true\r\n },\r\n cellRendererFramework: DropdownCellRenderer,\r\n cellRendererParams: {\r\n canEdit: (x) => {\r\n const row = x.data as FormClassificationMappingTreeItemModel;\r\n return this.canEdit &&\r\n row &&\r\n (row.isFormRevisionScheduleReportable);\r\n },\r\n isDisabled: (x) => false,\r\n editMode$: this._editModeSubject.asObservable(),\r\n dropdownItems: this._indexFactorTables,\r\n name: 'indexFactorTables',\r\n valueField: 'factorTableId',\r\n allowNull: true,\r\n change: this.factorTableChanged.bind(this),\r\n displayGetter: this.factorAssessorTableRenderer\r\n }\r\n },\r\n {\r\n headerName: 'Exempt',\r\n field: 'isExempt',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: AgGridCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n valueGetter: (params: ICellRendererParamsForAgGridCheckbox) => {\r\n const assetClass = params.data as FormClassificationMappingTreeItemModel;\r\n if (!assetClass) {\r\n return;\r\n }\r\n return assetClass.isExempt;\r\n },\r\n onValueChanged: this.exemptChanged.bind(this),\r\n isVisible: (params: ICellRendererParamsForAgGridCheckbox) => true,\r\n canEdit: (params: ICellRendererParamsForAgGridCheckbox) => {\r\n const assetClass = params.data as FormClassificationMappingTreeItemModel;\r\n if (!assetClass) {\r\n return;\r\n }\r\n\r\n return !!assetClass.ownedFormRevisionScheduleId;\r\n },\r\n canEnterEditMode: (params: ICellRendererParamsForAgGridCheckbox) => this._editModeSubject.getValue()\r\n } as ICellRendererParamsForAgGridCheckbox\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n suppressMenu: true,\r\n sortable: false,\r\n cellRendererFramework: FormAssetClassMappingListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canViewDepreciationTable: this._canViewDepreciationTable.bind(this),\r\n viewDepreciationTable: this._viewDepreciationTable.bind(this),\r\n } as FormAssetClassMappingListGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridColumnApi.setColumnPinned('actions', 'right');\r\n this._setRowData();\r\n }\r\n\r\n async wsMutexRelease(groupId: string): Promise {\r\n await Promise.resolve();\r\n }\r\n\r\n factorAssessorTableRenderer(item: Compliance.FormFactorTableModel) {\r\n return `${item.factorTableName} (${item.life} yr life)`;\r\n }\r\n\r\n onAgGridFilterChanged(event: FilterChangedEvent) {\r\n const filters = event.api.getFilterModel();\r\n let numberExpanded = 0;\r\n\r\n this._collapsedClassifications.forEach((assetClassificationId: number) => {\r\n const matchingRow = this._flattenedData.find((dataRow: FormClassificationMappingTreeItemModel) => {\r\n return dataRow.assetClassificationId === assetClassificationId;\r\n });\r\n let filteredOut:boolean = false;\r\n if (filters.assetClassName) {\r\n const filter = filters.assetClassName.filterValues[0];\r\n const filterType = filter.filterType.displayKey;\r\n const assetClassNameString = filter.filterValue;\r\n if (!this._filterName(filterType, `${matchingRow.assetClassName}@${matchingRow.assetClassificationId}`, assetClassNameString)) {\r\n filteredOut = true;\r\n }\r\n }\r\n\r\n if (filters.formRevisionScheduleId) {\r\n const filter = filters.formRevisionScheduleId.filterValues[0];\r\n if (filter.filterType.displayKey === AgGridFilterParams.blankFilterOptionDef.displayKey || filter.filterType.displayKey === AgGridFilterParams.notBlankFilterOptionDef.displayKey) {\r\n // This seems to be taken care of by the nature of those filters, which explicitly account for children\r\n } else {\r\n const scheduleFilterType = filter.filterType.displayKey;\r\n const scheduleFilterValue = filter.filterValue;\r\n if (!this._filterMappingLookup('formRevisionScheduleId', 'formRevisionScheduleId', this.formRevisionSchedules, x => `${x.name} (${x.abbr})`, scheduleFilterType, `${matchingRow['assetClassName']}@${matchingRow['assetClassificationId']}`, scheduleFilterValue) ) {\r\n filteredOut = true;\r\n }\r\n }\r\n }\r\n\r\n if (filters.depreciationFactorTableId) {\r\n const filter = filters.depreciationFactorTableId.filterValues[0];\r\n const scheduleFilterType = filter.filterType.displayKey;\r\n const scheduleFilterValue = filter.filterValue;\r\n if (!this._filterMappingLookup('depreciationFactorTableId', 'factorTableId', this._depreciationFactorTables, this.factorAssessorTableRenderer, scheduleFilterType, `${matchingRow['assetClassName']}@${matchingRow['assetClassificationId']}`, scheduleFilterValue) ) {\r\n filteredOut = true;\r\n }\r\n }\r\n\r\n if (!filteredOut) {\r\n this._collapsedClassifications.delete(assetClassificationId);\r\n this._expandedClassifications.add(assetClassificationId);\r\n numberExpanded++;\r\n }\r\n });\r\n if (numberExpanded > 0) {\r\n this._setRowData(false);\r\n }\r\n\r\n this._childrenAssetIdsToShowDespiteFilter = [];\r\n this.mapNodesWithFilteredOutChildren();\r\n // redraw to apply css classes, does not happen automatically on filter change\r\n this._setRowData(false);\r\n }\r\n\r\n // does this classification have children but which are missing from the filtered row data\r\n mapNodesWithFilteredOutChildren(): void {\r\n const filteredOutChildrenMap: Map = new Map();\r\n const idsInGrid: number[] = [];\r\n this._gridApi.forEachNodeAfterFilter((rowNode) => {\r\n if (rowNode && rowNode.data) {\r\n const ac = rowNode.data as FormClassificationMappingTreeItemModel;\r\n idsInGrid.push(ac.assetClassificationId);\r\n }\r\n });\r\n\r\n this._gridApi.forEachNodeAfterFilter((rowNode) => {\r\n if (rowNode && rowNode.data) {\r\n const treeModel = rowNode.data as FormClassificationMappingTreeItemModel;\r\n const assetClassification: Compliance.AssetClassificationModel =\r\n this._flattenedAssetClassificationsFullList.find(ac => ac.assetClassificationId ===\r\n treeModel.assetClassificationId);\r\n if (assetClassification &&\r\n assetClassification.childClassifications &&\r\n assetClassification.childClassifications.length > 0) {\r\n const filteredOutChildren =\r\n assetClassification.childClassifications.filter(\r\n child => idsInGrid.indexOf(child.assetClassificationId) === -1);\r\n if (filteredOutChildren.length > 0) {\r\n filteredOutChildrenMap.set(assetClassification.assetClassificationId, filteredOutChildren);\r\n }\r\n }\r\n }\r\n });\r\n\r\n this._filteredOutChildrenMap = filteredOutChildrenMap;\r\n }\r\n\r\n getRootDataNode(node: FormClassificationMappingTreeItemModel): FormClassificationMappingTreeItemModel {\r\n if (node.parentTreeItem) {\r\n return this.getRootDataNode(node.parentTreeItem);\r\n } else {\r\n return node;\r\n }\r\n }\r\n\r\n getAssetClassificationById(assetClassificationId: number): Compliance.AssetClassificationModel {\r\n return this._formService.assetClassifications.find(ac => ac.assetClassificationId === assetClassificationId);\r\n }\r\n\r\n exemptChanged(params: ICellRendererParamsForAgGridCheckbox, value: boolean): void {\r\n const assetClass = params.data as FormClassificationMappingTreeItemModel;\r\n if (!assetClass) { return; }\r\n\r\n this._setExempt(assetClass, value);\r\n }\r\n\r\n scheduleChanged(params: ICellRendererParamsForDropdowns) {\r\n const row = params.data as FormClassificationMappingTreeItemModel;\r\n const originalValue = params.originalValue as number;\r\n this._setFormRevisionScheduleId(row.assetClassificationId, originalValue, row.ownedFormRevisionScheduleId);\r\n this._setExempt(row, row.isExempt && !!row.ownedFormRevisionScheduleId);\r\n this._setDepreciationTables(row);\r\n this._populateOverrides(this.getAssetClassificationById(this.getRootDataNode(params.data).assetClassificationId));\r\n }\r\n\r\n leasedToScheduleChanged(params: ICellRendererParamsForDropdowns) {\r\n const row = params.data as FormClassificationMappingTreeItemModel;\r\n const originalValue = params.originalValue as number;\r\n this._setLeasedToFormRevisionScheduleId(row.assetClassificationId, originalValue, row.leasedToFormRevisionScheduleId);\r\n this._populateOverrides(this.getAssetClassificationById(this.getRootDataNode(params.data).assetClassificationId));\r\n }\r\n\r\n leasedFromScheduleChanged(params: ICellRendererParamsForDropdowns) {\r\n const row = params.data as FormClassificationMappingTreeItemModel;\r\n const originalValue = params.originalValue as number;\r\n this._setLeasedFromFormRevisionScheduleId(row.assetClassificationId, originalValue, row.leasedFromFormRevisionScheduleId);\r\n this._populateOverrides(this.getAssetClassificationById(this.getRootDataNode(params.data).assetClassificationId));\r\n }\r\n\r\n private _setFormRevisionScheduleId(parentAssetClassificationId: number, oldFormRevisionScheduleId, newFormRevisionScheduleId: number): void {\r\n // get children where the old value is the same\r\n const children = this._flattenedData.filter(x => x.parentTreeItem && x.parentTreeItem.assetClassificationId === parentAssetClassificationId && (!x.ownedFormRevisionScheduleId || (x.ownedFormRevisionScheduleId === oldFormRevisionScheduleId)));\r\n children.forEach(x => {\r\n x.ownedFormRevisionScheduleId = newFormRevisionScheduleId;\r\n this._setFormRevisionScheduleId(x.assetClassificationId, oldFormRevisionScheduleId, newFormRevisionScheduleId);\r\n });\r\n }\r\n\r\n private _setLeasedToFormRevisionScheduleId(parentAssetClassificationId: number, oldFormRevisionScheduleId, newFormRevisionScheduleId: number): void {\r\n // get children where the old value is the same\r\n const children = this._flattenedData.filter(x => x.parentTreeItem && x.parentTreeItem.assetClassificationId === parentAssetClassificationId && (!x.leasedToFormRevisionScheduleId || (x.leasedToFormRevisionScheduleId === oldFormRevisionScheduleId)));\r\n children.forEach(x => {\r\n x.leasedToFormRevisionScheduleId = newFormRevisionScheduleId;\r\n this._setLeasedToFormRevisionScheduleId(x.assetClassificationId, oldFormRevisionScheduleId, newFormRevisionScheduleId);\r\n });\r\n }\r\n\r\n private _setLeasedFromFormRevisionScheduleId(parentAssetClassificationId: number, oldFormRevisionScheduleId, newFormRevisionScheduleId: number): void {\r\n // get children where the old value is the same\r\n const children = this._flattenedData.filter(x => x.parentTreeItem && x.parentTreeItem.assetClassificationId === parentAssetClassificationId && (!x.leasedFromFormRevisionScheduleId || (x.leasedFromFormRevisionScheduleId === oldFormRevisionScheduleId)));\r\n children.forEach(x => {\r\n x.leasedFromFormRevisionScheduleId = newFormRevisionScheduleId;\r\n this._setLeasedFromFormRevisionScheduleId(x.assetClassificationId, oldFormRevisionScheduleId, newFormRevisionScheduleId);\r\n });\r\n }\r\n\r\n depreciationTableChanged(params: ICellRendererParamsForDropdowns) {\r\n const row = params.data as FormClassificationMappingTreeItemModel;\r\n const originalValue = params.originalValue as number;\r\n this._setDepreciationTableId(row.assetClassificationId, originalValue, row.depreciationFactorTableId);\r\n this._populateOverrides(this.getAssetClassificationById(this.getRootDataNode(params.data).assetClassificationId));\r\n }\r\n\r\n factorTableChanged(params: ICellRendererParamsForDropdowns) {\r\n const row = params.data as FormClassificationMappingTreeItemModel;\r\n const originalValue = params.originalValue as number;\r\n this._setIndexFactorTableId(row.assetClassificationId, originalValue, row.indexFactorTableId);\r\n this._populateOverrides(this.getAssetClassificationById(this.getRootDataNode(params.data).assetClassificationId));\r\n }\r\n\r\n async export(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Exporting' });\r\n\r\n try {\r\n const lrpId = await this._formService.exportFormClassificationMappings();\r\n this._snackBarService.addById(lrpId, Compliance.LongRunningProcessTypeEnum.FormClassificationMappingExport);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._flattenedData = _.cloneDeep(this._originalMappingViewData);\r\n this._setRowData();\r\n this._editModeSubject.next(false);\r\n }\r\n\r\n async edit(): Promise {\r\n const res = await this._formService.checkEditDefaultAssessor();\r\n if (res) {\r\n this._originalMappingViewData = _.cloneDeep(this._flattenedData);\r\n this._mutexService.acquire(this, this._formService.editGroup);\r\n this._editModeSubject.next(true);\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n if (!this.okToSave()) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n const mappings = this._flattenedData.map((mvd: FormClassificationMappingTreeItemModel) => {\r\n const mappingModel: Compliance.FormClassificationMappingModel = {\r\n formClassificationMappingId: mvd.formClassificationMappingId,\r\n assetClassificationId: mvd.assetClassificationId,\r\n depreciationFactorTableId: mvd.depreciationFactorTableId,\r\n indexFactorTableId: mvd.indexFactorTableId,\r\n ownedFormRevisionScheduleId: mvd.ownedFormRevisionScheduleId,\r\n leasedFromFormRevisionScheduleId: mvd.leasedFromFormRevisionScheduleId,\r\n leasedToFormRevisionScheduleId: mvd.leasedToFormRevisionScheduleId,\r\n transferId: null,\r\n isExempt: mvd.isExempt\r\n };\r\n\r\n return mappingModel;\r\n }).filter((c) => c.ownedFormRevisionScheduleId\r\n || c.leasedToFormRevisionScheduleId\r\n || c.leasedFromFormRevisionScheduleId\r\n || c.indexFactorTableId\r\n || c.depreciationFactorTableId\r\n || c.isExempt);\r\n\r\n await lastValueFrom(this._formRepository.saveClassificationMappings(this._formService.assessor.formRevisionYearAssessorId, mappings));\r\n\r\n await this._formService.loadAssetClassificationMappings();\r\n\r\n this._editModeSubject.next(false);\r\n\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n okToSave() {\r\n return this._flattenedData.every(\r\n (c: FormClassificationMappingTreeItemModel) => {\r\n return (\r\n !!(c.ownedFormRevisionScheduleId && (c.depreciationFactorTableId || !c.indexFactorTableId)) ||\r\n (!c.ownedFormRevisionScheduleId && !c.indexFactorTableId && !c.depreciationFactorTableId && !c.leasedFromFormRevisionScheduleId && !c.leasedToFormRevisionScheduleId));\r\n });\r\n }\r\n\r\n private _setExempt(assetClass: FormClassificationMappingTreeItemModel, isExempt: boolean): void {\r\n assetClass.isExempt = isExempt;\r\n\r\n const children = this._flattenedData.filter(x => x.parentTreeItem && x.parentTreeItem.assetClassificationId === assetClass.assetClassificationId);\r\n children.forEach(x => {\r\n x.isExempt = isExempt;\r\n this._setExempt(x, isExempt);\r\n });\r\n }\r\n\r\n private _canViewDepreciationTable(params: FormAssetClassMappingListGridActionCellRendererParams): boolean {\r\n const mapping = params.data as FormClassificationMappingTreeItemModel;\r\n return mapping && mapping.depreciationFactorTableId ? true : false;\r\n }\r\n\r\n private async _viewDepreciationTable(params: FormAssetClassMappingListGridActionCellRendererParams): Promise {\r\n const mapping = params.data as FormClassificationMappingTreeItemModel;\r\n if (!(mapping && mapping.depreciationFactorTableId)) {\r\n return Promise.resolve();\r\n }\r\n\r\n const tableParams: FactorTableDetailsParams = {\r\n editMode: false,\r\n factorTableId: mapping.depreciationFactorTableId\r\n };\r\n\r\n await this._modalService.showAsync(FactorTableDetailsComponent, tableParams, 'modal-lg');\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private _setDepreciationTableId(parentAssetClassificationId: number, oldDepreciationTableId, newDepreciationTableId: number): void {\r\n // get children where the old value is the same\r\n const children = this._flattenedData.filter(x => x.parentTreeItem && x.parentTreeItem.assetClassificationId === parentAssetClassificationId && x.depreciationFactorTableId === oldDepreciationTableId);\r\n children.forEach(x => {\r\n x.depreciationFactorTableId = newDepreciationTableId;\r\n this._setDepreciationTableId(x.assetClassificationId, oldDepreciationTableId, newDepreciationTableId);\r\n });\r\n }\r\n\r\n private _setIndexFactorTableId(parentAssetClassificationId: number, oldIndexTableId, newIndexTableId: number): void {\r\n // get children where the old value is the same\r\n const children = this._flattenedData.filter(x => x.parentTreeItem && x.parentTreeItem.assetClassificationId === parentAssetClassificationId && x.indexFactorTableId === oldIndexTableId);\r\n children.forEach(x => {\r\n x.indexFactorTableId = newIndexTableId;\r\n this._setIndexFactorTableId(x.assetClassificationId, oldIndexTableId, newIndexTableId);\r\n });\r\n }\r\n\r\n private _setDepreciationTables(row: FormClassificationMappingTreeItemModel) {\r\n const scheduleFactorTable = this._getScheduleFactorTable(row);\r\n this._setDepreciationTable(row, scheduleFactorTable.factorTableId, scheduleFactorTable.isLocked, scheduleFactorTable.isReportable);\r\n }\r\n\r\n private _setDepreciationTable(row: FormClassificationMappingTreeItemModel, defaultFactorTableId: number, isLocked: boolean, isReportable: boolean) {\r\n // set factor table when the schedule is locked or has a default factor table\r\n row.isDepreciationFactorTableLocked = isLocked;\r\n // WR-5132 Removing the locked condition. Leaving code here in-case this causes regressions. Remove post Epic 75\r\n //if (row.isDepreciationFactorTableLocked || !row.depreciationFactorTableId) {\r\n row.depreciationFactorTableId = defaultFactorTableId;\r\n //}\r\n\r\n // remove factor table when the schedule is not reportable\r\n row.isFormRevisionScheduleReportable = isReportable;\r\n if (!row.isFormRevisionScheduleReportable) {\r\n row.depreciationFactorTableId = null;\r\n row.indexFactorTableId = null;\r\n }\r\n\r\n // get children using the schedule that have no factor table or get all children using the schedule if factor table is locked to the schedule\r\n const children = this._flattenedData.filter(x => x.parentTreeItem && x.parentTreeItem.assetClassificationId === row.assetClassificationId && x.ownedFormRevisionScheduleId === row.ownedFormRevisionScheduleId && (isLocked || !x.depreciationFactorTableId));\r\n children.forEach(x => {\r\n this._setDepreciationTable(x, defaultFactorTableId, isLocked, isReportable);\r\n });\r\n }\r\n\r\n private _setAssetClassifications(): void {\r\n this._assetClassificationsNameMap = {};\r\n this._flattenedAssetClassificationsFullList = [];\r\n this._formService.assetClassifications.forEach((ac) => {\r\n this._mapClassification(ac);\r\n });\r\n }\r\n\r\n private _setSchedules(): void {\r\n const sorted = this._formService.schedules.sort((x, y) => x.name.localeCompare(y.name));\r\n this.formRevisionSchedules.length = 0;\r\n this.formRevisionSchedules.push.apply(this.formRevisionSchedules, sorted);\r\n }\r\n\r\n private _setFactorTables(): void {\r\n this._indexFactorTables.length = 0; //Using this method to update so that the column definition still references the same array.\r\n this._indexFactorTables.push.apply(this._indexFactorTables, this._formService.factorTables.filter((t) => t.tableType === Compliance.FactorTableTypeEnum.Index));\r\n\r\n this._depreciationFactorTables.length = 0;\r\n this._depreciationFactorTables.push.apply(this._depreciationFactorTables, this._formService.factorTables.filter((t) => t.tableType === Compliance.FactorTableTypeEnum.Depreciation));\r\n }\r\n\r\n private async _setAssessorMappings(): Promise {\r\n const flattenedData: FormClassificationMappingTreeItemModel[] = [];\r\n\r\n this._formService.assetClassifications\r\n .forEach(item => {\r\n this._generateAndPushTreeItem(flattenedData, item, 1, null, this._formService.assetClassificationMappings);\r\n });\r\n\r\n this._flattenedData = flattenedData;\r\n\r\n this._formService.assetClassifications.forEach(ac => {\r\n this._populateOverrides(ac);\r\n });\r\n }\r\n\r\n // resetAssessorMappings resets the underlying data - expand/collapse/filter must call with false\r\n private _setRowData(resetAssessorMappings: boolean = true): void {\r\n if (!(this._gridApi && this._formService.isInitialized)) {\r\n return;\r\n }\r\n\r\n this._setSchedules();\r\n this._setFactorTables();\r\n\r\n if (resetAssessorMappings) {\r\n this._setAssessorMappings();\r\n }\r\n\r\n this._gridApi.setRowData(this._mappingViewData);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _filterName(filter: string, gridValue: any, filterText: string, rowData?: Compliance.AssetClassificationModel): boolean {\r\n const currentAssetClassification = this._assetClassificationsNameMap[gridValue.toLowerCase()];\r\n if (currentAssetClassification && this._childrenAssetIdsToShowDespiteFilter.includes(currentAssetClassification.assetClassificationId)) {\r\n return true; // shortcut show via user control\r\n }\r\n\r\n if (currentAssetClassification.name === 'Computer Equipment') {\r\n debugger;\r\n }\r\n\r\n const filterPassed = this._filterCheckValue(filter, currentAssetClassification.name, filterText);\r\n const someChildrenPass = currentAssetClassification.childClassifications.some((ac: Compliance.AssetClassificationModel) => this._filterName(filter, `${ac.name}@${ac.assetClassificationId}`, filterText));\r\n\r\n if (rowData && !filterPassed && someChildrenPass) {\r\n this._parentRequiredFilterSet.add(rowData.assetClassificationId);\r\n } else if (rowData && this._parentRequiredFilterSet.has(rowData.assetClassificationId)) {\r\n this._parentRequiredFilterSet.delete(rowData.assetClassificationId);\r\n }\r\n\r\n return filterPassed || someChildrenPass;\r\n }\r\n\r\n // this function is designed to match the 3 filter values of the ag-grid custom text filter, with extra\r\n // parameters bound at the start. lookupNameFieldRenderer is a function called to inspect the provided lookup table\r\n private _filterMappingLookup(mappingFieldName: string, lookupFieldName: string, lookupTable: any[], lookupNameFieldRenderer: Function, filter: string, gridValue: any, filterText: string, rowData?: Compliance.AssetClassificationModel): boolean {\r\n if (!gridValue) { return !filter; }\r\n const currentAssetClassification = this._assetClassificationsNameMap[gridValue.toLowerCase()];\r\n if (currentAssetClassification && this._childrenAssetIdsToShowDespiteFilter.includes(currentAssetClassification.assetClassificationId)) {\r\n return true; // shortcut show via user control\r\n }\r\n\r\n const mappingForClassification = this._flattenedData.find(mapping => mapping.assetClassificationId === currentAssetClassification.assetClassificationId);\r\n\r\n let lookupName = '';\r\n if (mappingForClassification && mappingForClassification[mappingFieldName]) {\r\n const lookup = lookupTable.find(row => row[lookupFieldName] === mappingForClassification[mappingFieldName]);\r\n if (lookup) {\r\n lookupName = lookupNameFieldRenderer.call(this, lookup);\r\n }\r\n }\r\n\r\n const filterPassed = this._filterCheckValue(filter, lookupName, filterText);\r\n const someChildrenPass = currentAssetClassification.childClassifications.some((ac: Compliance.AssetClassificationModel) => this._filterMappingLookup(mappingFieldName, lookupFieldName, lookupTable, lookupNameFieldRenderer, filter, `${ac.name}@${ac.assetClassificationId}`, filterText, ac));\r\n\r\n if (rowData && !filterPassed && someChildrenPass) {\r\n this._parentRequiredFilterSet.add(rowData.assetClassificationId);\r\n } else if (rowData && this._parentRequiredFilterSet.has(rowData.assetClassificationId)) {\r\n this._parentRequiredFilterSet.delete(rowData.assetClassificationId);\r\n }\r\n\r\n return filterPassed || someChildrenPass;\r\n }\r\n\r\n private _filterCheckValue(method: string, sourceString: string, matchString: string): boolean {\r\n const sourceCompare = (sourceString || '').toLowerCase();\r\n const matchCompare = (matchString || '').toLowerCase();\r\n\r\n switch (method) {\r\n case 'startsWith':\r\n return sourceCompare.startsWith(matchCompare);\r\n case 'equals':\r\n return sourceCompare === matchCompare;\r\n case 'notEqual':\r\n return sourceCompare !== matchCompare;\r\n case 'contains':\r\n return sourceCompare.includes(matchCompare);\r\n case 'notContains':\r\n return !sourceCompare.includes(matchCompare);\r\n case 'endsWith':\r\n return sourceCompare.endsWith(matchCompare);\r\n case AgGridFilterParams.blankFilterOptionDef.displayKey:\r\n return sourceString.length === 0;\r\n case AgGridFilterParams.notBlankFilterOptionDef.displayKey:\r\n return sourceString.length > 0;\r\n\r\n }\r\n return false;\r\n }\r\n\r\n private get _mappingViewData() {\r\n const mappingViewData: FormClassificationMappingTreeItemModel[] = [];\r\n\r\n this._formService.assetClassifications.forEach((topLevel: Compliance.AssetClassificationModel) => {\r\n const dataNode: FormClassificationMappingTreeItemModel = this._flattenedData.find(row => row.assetClassificationId === topLevel.assetClassificationId);\r\n mappingViewData.push(dataNode);\r\n if (this._expandedClassifications.has(topLevel.assetClassificationId) && topLevel.childClassifications && topLevel.childClassifications.length > 0) {\r\n topLevel.childClassifications.forEach((secondLevel: Compliance.AssetClassificationModel) => {\r\n mappingViewData.push(this._flattenedData.find(row => row.assetClassificationId === secondLevel.assetClassificationId));\r\n if (this._expandedClassifications.has(secondLevel.assetClassificationId) && secondLevel.childClassifications && secondLevel.childClassifications.length > 0) {\r\n secondLevel.childClassifications.forEach((thirdLevel: Compliance.AssetClassificationModel) => {\r\n mappingViewData.push(this._flattenedData.find(row => row.assetClassificationId ===\r\n thirdLevel.assetClassificationId));\r\n });\r\n }\r\n });\r\n }\r\n });\r\n\r\n return mappingViewData;\r\n }\r\n\r\n private _mapClassification(classifications: Compliance.AssetClassificationModel) {\r\n this._flattenedAssetClassificationsFullList.push(classifications);\r\n const name = `${classifications.name && classifications.name.toLowerCase()}@${classifications.assetClassificationId}`;\r\n this._assetClassificationsNameMap[name] = classifications;\r\n if (classifications.childClassifications && classifications.childClassifications.length > 0) {\r\n this._collapsedClassifications.add(classifications.assetClassificationId);\r\n }\r\n classifications.childClassifications.forEach(ac => {\r\n this._mapClassification(ac);\r\n });\r\n }\r\n\r\n private _generateAndPushTreeItem(\r\n flattenedData: FormClassificationMappingTreeItemModel[],\r\n classificationItem: Compliance.AssetClassificationModel,\r\n level: number,\r\n parentTreeItem: FormClassificationMappingTreeItemModel,\r\n assessorMappings: Compliance.FormClassificationMappingModel[]): void {\r\n\r\n const result = {\r\n assetClassificationId: classificationItem.assetClassificationId,\r\n assetClassName: classificationItem.name,\r\n assetClassAllowPerpetual: classificationItem.allowPerpetual,\r\n level: level,\r\n parentTreeItem: parentTreeItem,\r\n ownedFormRevisionScheduleId: null,\r\n depreciationFactorTableId: null,\r\n isDepreciationFactorTableLocked: false,\r\n indexFactorTableId: null,\r\n formClassificationMappingId: 0,\r\n isFormRevisionScheduleReportable: true,\r\n isExempt: false\r\n } as FormClassificationMappingTreeItemModel;\r\n\r\n const mapping = assessorMappings.find((item => item.assetClassificationId === result.assetClassificationId));\r\n\r\n if (mapping) {\r\n result.formClassificationMappingId = mapping.formClassificationMappingId;\r\n result.ownedFormRevisionScheduleId = mapping.ownedFormRevisionScheduleId;\r\n result.leasedToFormRevisionScheduleId = mapping.leasedToFormRevisionScheduleId;\r\n result.leasedFromFormRevisionScheduleId = mapping.leasedFromFormRevisionScheduleId;\r\n result.depreciationFactorTableId = mapping.depreciationFactorTableId;\r\n result.indexFactorTableId = mapping.indexFactorTableId;\r\n result.isExempt = mapping.isExempt;\r\n\r\n const scheduleFactorTable = this._getScheduleFactorTable(result);\r\n result.isDepreciationFactorTableLocked = scheduleFactorTable && scheduleFactorTable.isLocked;\r\n result.isFormRevisionScheduleReportable = scheduleFactorTable && scheduleFactorTable.isReportable;\r\n }\r\n\r\n flattenedData.push(result);\r\n\r\n if (classificationItem.childClassifications) {\r\n classificationItem.childClassifications\r\n .forEach(item => this._generateAndPushTreeItem(flattenedData, item, level + 1, result, assessorMappings));\r\n }\r\n }\r\n\r\n private _getScheduleFactorTable(row: FormClassificationMappingTreeItemModel): ScheduleFactorTableModel {\r\n const result: ScheduleFactorTableModel = {\r\n factorTableId: null,\r\n isLocked: false,\r\n isReportable: true\r\n };\r\n\r\n if (row.ownedFormRevisionScheduleId) {\r\n // get the schedule\r\n const schedule = this.formRevisionSchedules.find(x => {\r\n return x.formRevisionScheduleId === row.ownedFormRevisionScheduleId;\r\n });\r\n\r\n if (!schedule) {\r\n return null;\r\n }\r\n\r\n result.isReportable = schedule.isReportable;\r\n\r\n // get schedule factor table for the assessor\r\n const scheduleFactorTable = schedule.scheduleFactorTables.find(x => {\r\n return x.formRevisionYearAssessorId === this._formService.factorTableAssessorId;\r\n });\r\n\r\n // get the depreciation factor table\r\n if (scheduleFactorTable) {\r\n result.isLocked = scheduleFactorTable.isLocked;\r\n const depreciationTable = this._depreciationFactorTables.find(x => {\r\n return x.formFactorTableId === scheduleFactorTable.formFactorTableId;\r\n });\r\n if (depreciationTable) {\r\n result.factorTableId = depreciationTable.factorTableId;\r\n }\r\n }\r\n }\r\n\r\n return result;\r\n }\r\n\r\n private _populateOverrides(parentAssetClassificationNode: Compliance.AssetClassificationModel) {\r\n const parentDataRow = this._flattenedData.find((dataRow: FormClassificationMappingTreeItemModel) => {\r\n return dataRow.assetClassificationId === parentAssetClassificationNode.assetClassificationId;\r\n });\r\n if (parentAssetClassificationNode.childClassifications) {\r\n parentDataRow.childOverridesSchedule = false;\r\n parentDataRow.childOverridesDepreciation = false;\r\n parentDataRow.childOverridesIndex = false; // set false before checking children\r\n parentAssetClassificationNode.childClassifications.forEach((childClassification: Compliance.AssetClassificationModel) => {\r\n const childDataRow = this._flattenedData.find((dataRow: FormClassificationMappingTreeItemModel) => {\r\n return dataRow.assetClassificationId === childClassification.assetClassificationId;\r\n });\r\n childDataRow.isScheduleOverridden = this._isPropertyOverridden(parentDataRow.ownedFormRevisionScheduleId, childDataRow.ownedFormRevisionScheduleId);\r\n childDataRow.isDepreciationOverridden = this._isPropertyOverridden(parentDataRow.depreciationFactorTableId, childDataRow.depreciationFactorTableId);\r\n childDataRow.isIndexOverridden = this._isPropertyOverridden(parentDataRow.indexFactorTableId, childDataRow.indexFactorTableId);\r\n\r\n this._populateOverrides(childClassification);\r\n if (childDataRow.isScheduleOverridden) {\r\n parentDataRow.childOverridesSchedule = true;\r\n }\r\n if (childDataRow.isDepreciationOverridden) {\r\n parentDataRow.childOverridesDepreciation = true;\r\n }\r\n if (childDataRow.isIndexOverridden) {\r\n parentDataRow.childOverridesIndex = true;\r\n }\r\n });\r\n }\r\n }\r\n\r\n private _isPropertyOverridden(parentValue, itemValue): boolean {\r\n let result: boolean = false;\r\n\r\n if (parentValue && !itemValue) {\r\n result = true;\r\n } else if (!parentValue && itemValue) {\r\n result = true;\r\n } else if (parentValue !== itemValue) {\r\n result = true;\r\n }\r\n\r\n return result;\r\n }\r\n\r\n private _expand(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as FormClassificationMappingTreeItemModel;\r\n if (!item) {\r\n return;\r\n }\r\n\r\n if (this._filteredOutChildrenMap.has(item.assetClassificationId)) {\r\n this._showHiddenChildren(params);\r\n } else {\r\n this._expandedClassifications.add(item.assetClassificationId);\r\n this._collapsedClassifications.delete(item.assetClassificationId);\r\n this._setRowData(false);\r\n }\r\n }\r\n\r\n private _collapse(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as FormClassificationMappingTreeItemModel;\r\n if (!item) {\r\n return;\r\n }\r\n\r\n this._expandedClassifications.delete(item.assetClassificationId);\r\n this._collapsedClassifications.add(item.assetClassificationId);\r\n this._setRowData(false);\r\n }\r\n\r\n private _showHiddenChildren(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as FormClassificationMappingTreeItemModel;\r\n if (!item) {\r\n return;\r\n }\r\n\r\n const childrenToShowDespiteFilter = this._filteredOutChildrenMap.get(item.assetClassificationId);\r\n this._childrenAssetIdsToShowDespiteFilter = this._childrenAssetIdsToShowDespiteFilter.concat(childrenToShowDespiteFilter.map(ac => ac.assetClassificationId ));\r\n this._filteredOutChildrenMap.delete(item.assetClassificationId); // no longer hidden\r\n\r\n // expand node if collapsed\r\n if (this._collapsedClassifications.has(item.assetClassificationId)) {\r\n this._expandedClassifications.add(item.assetClassificationId);\r\n this._collapsedClassifications.delete(item.assetClassificationId);\r\n }\r\n\r\n this._setRowData(false);\r\n }\r\n\r\n private _canExpand(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as FormClassificationMappingTreeItemModel;\r\n if (!item) {\r\n return false;\r\n }\r\n\r\n return this._collapsedClassifications.has(item.assetClassificationId);\r\n }\r\n\r\n private _canCollapse(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as FormClassificationMappingTreeItemModel;\r\n if (!item) {\r\n return false;\r\n }\r\n\r\n return this._expandedClassifications.has(item.assetClassificationId);\r\n }\r\n\r\n private _canShowHiddenChildren(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as FormClassificationMappingTreeItemModel;\r\n if (!item || this._collapsedClassifications.has(item.assetClassificationId)) {\r\n return false;\r\n }\r\n return this._filteredOutChildrenMap.has(item.assetClassificationId);\r\n }\r\n\r\n private _getName(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as FormClassificationMappingTreeItemModel;\r\n if (!item) {\r\n return '';\r\n }\r\n\r\n return item.assetClassName;\r\n }\r\n\r\n private _getTooltip(params: ICellRendererParamsForExpandCellRenderer) {\r\n const item = params.data as FormClassificationMappingTreeItemModel;\r\n if (!item) {\r\n return '';\r\n }\r\n\r\n return `${item.assetClassName}${item.assetClassAllowPerpetual ? ' (Allowed to be perpetual)' : ''}`;\r\n }\r\n\r\n private _canExpandAll(params: ICellRendererParamsForExpandCellHeaderParams): boolean {\r\n return this._canExpandAllRows;\r\n }\r\n\r\n private _canCollapseAll(params: ICellRendererParamsForExpandCellHeaderParams): boolean {\r\n return !this._canExpandAllRows;\r\n }\r\n\r\n private _expandAll(params: ICellRendererParamsForExpandCellHeaderParams): void {\r\n this._flattenedData.forEach(x => {\r\n if (x.parentTreeItem && this._collapsedClassifications.has(x.parentTreeItem.assetClassificationId)) {\r\n this._expandedClassifications.add(x.parentTreeItem.assetClassificationId);\r\n this._collapsedClassifications.delete(x.parentTreeItem.assetClassificationId);\r\n }\r\n });\r\n\r\n this._setRowData(false);\r\n\r\n this._canExpandAllRows = false;\r\n }\r\n\r\n private _collapseAll(params: ICellRendererParamsForExpandCellHeaderParams): void {\r\n this._flattenedData.forEach(x => {\r\n if (x.parentTreeItem && this._expandedClassifications.has(x.parentTreeItem.assetClassificationId)) {\r\n this._expandedClassifications.delete(x.parentTreeItem.assetClassificationId);\r\n this._collapsedClassifications.add(x.parentTreeItem.assetClassificationId);\r\n }\r\n });\r\n\r\n this._setRowData(false);\r\n\r\n this._canExpandAllRows = true;\r\n }\r\n\r\n private _blankFilterScheduleTest = (filterValue: any, cellValue: any) => {\r\n const currentAssetClassification = this._assetClassificationsNameMap[cellValue.toLowerCase()];\r\n if (currentAssetClassification && this._childrenAssetIdsToShowDespiteFilter.includes(currentAssetClassification.assetClassificationId)) {\r\n return true; // short cut show via user control\r\n }\r\n const mappingForClassification = this._mappingViewData.find(mapping => mapping.assetClassificationId === currentAssetClassification.assetClassificationId);\r\n if (!(mappingForClassification && (mappingForClassification.ownedFormRevisionScheduleId))\r\n || currentAssetClassification.childClassifications.some((ac: Compliance.AssetClassificationModel) => this._blankFilterScheduleTest(filterValue, `${ac.name}@${ac.assetClassificationId}`))) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n };\r\n\r\n\r\n private _notBlankFilterScheduleTest = (filterValue: any, cellValue: any) => {\r\n const currentAssetClassification = this._assetClassificationsNameMap[cellValue.toLowerCase()];\r\n if (currentAssetClassification && this._childrenAssetIdsToShowDespiteFilter.includes(currentAssetClassification.assetClassificationId)) {\r\n return true; // short cut show via user control\r\n }\r\n const mappingForClassification = this._mappingViewData.find(mapping => mapping.assetClassificationId === currentAssetClassification.assetClassificationId);\r\n if ((mappingForClassification && (mappingForClassification.ownedFormRevisionScheduleId))\r\n || currentAssetClassification.childClassifications.some((ac: Compliance.AssetClassificationModel) => this._notBlankFilterScheduleTest(filterValue, `${ac.name}@${ac.assetClassificationId}`))) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n };\r\n}\r\n","\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { FormRepository } from '../../Repositories/form.repository';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef} from 'ngx-bootstrap/modal';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, CsvExportParams } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder } from '../../AgGrid/agGridOptionsBuilder';\r\nimport { AgGridFilterParams, AgGridColumns } from '../../AgGrid';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\ninterface FormFieldListModel extends Compliance.ReturnFormFieldInfoModel {\r\n parameterList: string;\r\n ruleList: string;\r\n}\r\n\r\n@Component({\r\n selector: 'form-field-list',\r\n templateUrl: './formFieldList.component.html',\r\n styleUrls: ['./formFieldList.component.scss']\r\n})\r\nexport class FormFieldListComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _formRepository: FormRepository,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _restrictService: RestrictService) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _fields: FormFieldListModel[];\r\n\r\n params: void;\r\n result: void;\r\n canExport: boolean = false;\r\n isBusy: boolean = false;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .build();\r\n\r\n async ngOnInit(): Promise {\r\n this.canExport = this._restrictService.isInRole(Roles.COMPLIANCESETUPSVIEW) && this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n this.isBusy = true;\r\n\r\n try {\r\n const result = await lastValueFrom(this._formRepository.getDataSourceFieldInfo());\r\n this._fields = _.map(result,\r\n item => {\r\n const field = item as FormFieldListModel;\r\n if (field.parameters) {\r\n field.parameterList = _.join(field.parameters, ', ');\r\n }\r\n if (field.rules) {\r\n field.ruleList = _.join(field.rules, ' > ');\r\n }\r\n return field;\r\n });\r\n this._setRowData();\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Name',\r\n field: 'name',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n tooltipField: 'name'\r\n },\r\n {\r\n headerName: 'Full Name',\r\n field: 'fullName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n tooltipField: 'fullName'\r\n },\r\n {\r\n headerName: 'Category',\r\n field: 'category',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n tooltipField: 'dataSourceName'\r\n },\r\n {\r\n headerName: 'Max Length',\r\n field: 'maxLength',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Parameters',\r\n field: 'parameterList',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n tooltipField: 'parameterList'\r\n },\r\n {\r\n headerName: 'Rules',\r\n field: 'ruleList',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n tooltipField: 'ruleList'\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n tooltipField: 'description'\r\n },\r\n {\r\n headerName: 'Sample Data',\r\n field: 'sampleData',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n tooltipField: 'sampleData'\r\n },\r\n {\r\n headerName: 'Transferable',\r\n field: 'isTransferable',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n tooltipField: 'isTransferable'\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'name',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n\r\n this._setRowData();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n export(): void {\r\n const params = {\r\n fileName: 'FormFields.csv'\r\n } as CsvExportParams;\r\n this._gridApi.exportDataAsCsv(params);\r\n }\r\n\r\n private _setRowData() {\r\n if (!(this._gridApi && this._fields)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._fields);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { FormFieldListComponent } from '../Form-Field-List/formFieldList.component';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\n\r\n@Component({\r\n selector: 'form-fields',\r\n templateUrl: './formFields.component.html'\r\n})\r\nexport class FormFieldsComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService) { }\r\n\r\n ngOnInit(): void { }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n async show(): Promise {\r\n await this._modalService.showAsync(FormFieldListComponent, null, 'modal-xl');\r\n }\r\n}\r\n"," 0\" [message]=\"busyMessageManager.message\">\r\n\r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport * as _ from 'lodash';\r\nimport { AgGridOptionsBuilder, AgGridColumns } from '../../AgGrid';\r\nimport { GridOptions, GridReadyEvent, ColDef, GridApi } from 'ag-grid-community';\r\nimport { AgGridMultiSelectTracker, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectedCellRenderer } from '../../AgGrid/MultiSelectTracker';\r\nimport { Subscription } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'form-template-edit',\r\n templateUrl: './formTemplateEdit.component.html',\r\n styleUrls: ['./formTemplateEdit.component.scss']\r\n})\r\nexport class FormTemplateEditComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formService: FormService) { }\r\n\r\n private _currentGridApi: GridApi;\r\n private _previewGridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n selectedRows: number[] = [];\r\n\r\n params: void;\r\n result: boolean;\r\n busyMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n file: File;\r\n rotateBy: number;\r\n moveX: number;\r\n moveY: number;\r\n\r\n currentMetadata: Compliance.FormRevisionTemplateMetadataModel;\r\n previewMetadata: Compliance.FormRevisionTemplateMetadataModel;\r\n\r\n currentGridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.FormRevisionTemplatePageMetadataModel).pageNumber)\r\n }\r\n })\r\n .withContext(this)\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .withFirstDataRendered(x => {\r\n x.api.sizeColumnsToFit();\r\n })\r\n .build();\r\n\r\n previewGridOptions: GridOptions = new AgGridOptionsBuilder({})\r\n .withContext(this)\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .withFirstDataRendered(x => {\r\n x.api.sizeColumnsToFit();\r\n })\r\n .build();\r\n\r\n async ngOnInit(): Promise {\r\n this.busyMessageManager.add('Loading', 'loading');\r\n\r\n try {\r\n this.currentMetadata = await this._formService.getTemplateMetadata();\r\n\r\n this._setCurrentRowData();\r\n this._setPreviewRowData();\r\n } finally {\r\n this.busyMessageManager.remove('loading');\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onCurrentAgGridReady(event: GridReadyEvent): void {\r\n this._currentGridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.currentGridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(async () => {\r\n this.selectedRows = await this.gridTracker.getSelectedRowIds();\r\n this.onOptionChanged();\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'pageNumber',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Page #',\r\n field: 'pageNumber',\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Page Rotation',\r\n field: 'pageRotation',\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Field Rotation',\r\n field: 'fieldRotation',\r\n width: AgGridColumns.textColumnWidth\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'pageNumber',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._currentGridApi.setColumnDefs(columns);\r\n this._currentGridApi.setSortModel(defaultSortModel);\r\n this._setCurrentRowData();\r\n }\r\n\r\n onPreviewAgGridReady(event: GridReadyEvent): void {\r\n this._previewGridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Page #',\r\n field: 'pageNumber',\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Page Rotation',\r\n field: 'pageRotation',\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Field Rotation',\r\n field: 'fieldRotation',\r\n width: AgGridColumns.textColumnWidth\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'pageNumber',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._previewGridApi.setColumnDefs(columns);\r\n this._previewGridApi.setSortModel(defaultSortModel);\r\n this._setPreviewRowData();\r\n }\r\n\r\n onOptionChanged(): void {\r\n this.previewMetadata = null;\r\n this._setPreviewRowData();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async preview(): Promise {\r\n this.busyMessageManager.add('Previewing', 'previewing');\r\n\r\n try {\r\n const data = {\r\n pagesIn: this.selectedRows,\r\n rotateBy: this.rotateBy,\r\n moveX: this.moveX,\r\n moveY: this.moveY\r\n };\r\n\r\n this.previewMetadata = await this._formService.previewTemplateEditMetadata(data);\r\n await this._formService.previewTemplateEdit(data);\r\n\r\n this._setPreviewRowData();\r\n } finally {\r\n this.busyMessageManager.remove('previewing');\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n this.busyMessageManager.add('Saving Template', 'saving');\r\n try {\r\n const data: Compliance.FormRevisionTemplateEditModel = {\r\n pagesIn: this.selectedRows,\r\n rotateBy: this.rotateBy,\r\n moveX: this.moveX,\r\n moveY: this.moveY\r\n };\r\n\r\n await this._formService.applyTemplateEdit(data);\r\n\r\n this.result = true;\r\n\r\n this._bsModalRef.hide();\r\n\r\n } finally {\r\n this.busyMessageManager.remove('saving');\r\n }\r\n }\r\n\r\n private _setCurrentRowData(): void {\r\n if (!(this._currentGridApi && this.currentMetadata)) {\r\n return;\r\n }\r\n\r\n this._currentGridApi.setRowData(this.currentMetadata.pages);\r\n }\r\n\r\n private _setPreviewRowData(): void {\r\n if (!(this._previewGridApi)) {\r\n return;\r\n }\r\n\r\n this._previewGridApi.setRowData(this.previewMetadata ? this.previewMetadata.pages : []);\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._currentGridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n const queryResultModel: Compliance.QueryResultModel = {\r\n lastModifiedTimestamp: new Date(),\r\n totalRows: rows.length,\r\n totalValidRows: rows.length,\r\n data: rows.map((x) => {\r\n const page = x.data as Compliance.FormRevisionTemplatePageMetadataModel;\r\n return page && page.pageNumber;\r\n })\r\n };\r\n\r\n return Promise.resolve(queryResultModel);\r\n }\r\n}\r\n","\r\n

{{ params.message }}

\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { GridApi, GridReadyEvent, ColDef, GridOptions, CsvExportParams, ICellRendererParams } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams } from '../../AgGrid';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface FormTemplateValidationParams {\r\n validationResult: Compliance.ReturnFormTemplateValidationResultModel;\r\n message?: string;\r\n}\r\n\r\ninterface FormTemplateValidationRow {\r\n message: string;\r\n validationType: string;\r\n}\r\n\r\n@Component({\r\n selector: 'form-template-validation',\r\n templateUrl: './formTemplateValidation.component.html',\r\n styleUrls: ['./formTemplateValidation.component.scss']\r\n})\r\nexport class FormTemplateValidationComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _validationRows: FormTemplateValidationRow[];\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({})\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .withFirstDataRendered(x => {\r\n x.columnApi.autoSizeAllColumns();\r\n })\r\n .build();\r\n\r\n params: FormTemplateValidationParams;\r\n result: void;\r\n\r\n ngOnInit(): void {\r\n this._validationRows = _.union(_.map(this.params.validationResult.errors, (x) => {\r\n return {\r\n message: x,\r\n validationType: 'Error'\r\n };\r\n }), _.map(this.params.validationResult.warnings, (x) => {\r\n return {\r\n message: x,\r\n validationType: 'Warning'\r\n };\r\n }));\r\n\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Type',\r\n field: 'validationType',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const validation = params.data as FormTemplateValidationRow;\r\n if (validation.validationType === 'Error') {\r\n return 'cell-validation-error';\r\n }\r\n\r\n if (validation.validationType === 'Warning') {\r\n return 'cell-validation-warning';\r\n }\r\n\r\n return '';\r\n }\r\n },\r\n {\r\n headerName: 'Message',\r\n field: 'message',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'validationType',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n export(): void {\r\n const params = {\r\n fileName: 'FormTemplateValidation.csv'\r\n } as CsvExportParams;\r\n this._gridApi.exportDataAsCsv(params);\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._validationRows)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._validationRows);\r\n }\r\n}\r\n"," 0\" [message]=\"busyMessageManager.message\">\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { IWeissmanModalComponent, WeissmanModalService } from '../../WeissmanModalService';\r\nimport { FormTemplateValidationParams, FormTemplateValidationComponent } from '../Form-Template-Validation/formTemplateValidation.component';\r\n\r\n@Component({\r\n selector: 'form-template-upload',\r\n templateUrl: './formTemplateUpload.component.html'\r\n})\r\nexport class FormTemplateUploadComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formService: FormService,\r\n private readonly _modalService: WeissmanModalService\r\n ) { }\r\n\r\n params: void;\r\n result: Compliance.ReturnFormTemplateValidationResultModel;\r\n\r\n busyMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n file: File;\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n filePicked(files: File[]): void {\r\n this.file = files[0];\r\n }\r\n\r\n async upload(): Promise {\r\n this.busyMessageManager.add('Uploading', 'uploading');\r\n\r\n let result: Compliance.ReturnFormTemplateValidationResultModel = null;\r\n\r\n try {\r\n const fileMetadata: Compliance.ReturnFormTemplateModel = {\r\n formRevisionId: this._formService.formRevisionId,\r\n fileName: this.file.name\r\n };\r\n \r\n result = await this._formService.updateTemplate(this.file, fileMetadata);\r\n } finally {\r\n this.busyMessageManager.remove('uploading');\r\n }\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const hasErrors = result.errors && result.errors.length;\r\n const hasWarnings = result.warnings && result.warnings.length;\r\n\r\n if (hasErrors || hasWarnings) {\r\n const params: FormTemplateValidationParams = {\r\n validationResult: result,\r\n message: hasErrors ?\r\n 'The template was not uploaded because it contains errors.' :\r\n 'The template was successfully uploaded. Please review template errors and/or warnings.'\r\n };\r\n\r\n await this._modalService.showAsync(FormTemplateValidationComponent, params, 'modal-lg');\r\n \r\n if (hasErrors) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n this.result = result;\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","
\r\n
\r\n

Form Template [All Tax Years - All Assessors]

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n The form doesn't have a template\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n {{ formRevision.templateSafeFileName }}\r\n \r\n (Placeholder)\r\n (Last changed by {{formRevision.templateChangedBy}} on {{formRevision.templateChangeDate | date: 'MM/dd/yyyy h:mm a'}})\r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component } from '@angular/core';\r\nimport { FormService} from '../form.service';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator/busyIndicator.service';\r\nimport { BaseExpandableComponent } from '../../../UI-Lib/Expandable-Component/baseExpandableComponent';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { FormTemplateEditComponent } from '../Form-Template-Edit/formTemplateEdit.component';\r\nimport { FormTemplateUploadComponent } from '../Form-Template-Upload/formTemplateUpload.component';\r\nimport { FormTemplateValidationParams, FormTemplateValidationComponent } from '../Form-Template-Validation/formTemplateValidation.component';\r\n\r\n@Component({\r\n selector: 'form-template',\r\n templateUrl: './formTemplate.component.html',\r\n styleUrls: ['./formTemplate.component.scss']\r\n})\r\nexport class FormTemplateComponent extends BaseExpandableComponent {\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _modalService: WeissmanModalService) {\r\n super(_formService, 'form-template');\r\n }\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._formService.editGroup);\r\n }\r\n\r\n get formRevision(): Compliance.FormRevisionModel {\r\n return this._formService.formRevision;\r\n }\r\n\r\n get hasErrors(): boolean {\r\n return this._formService.hasTemplateValidationErrors;\r\n }\r\n\r\n async upload(): Promise {\r\n if (!this._formService.isPlaceholderTemplate) {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to overwrite the form template?',\r\n 'Confirm Overwrite'\r\n );\r\n } catch (e) {\r\n return;\r\n }\r\n }\r\n\r\n const result = await this._modalService.showAsync(FormTemplateUploadComponent, null, 'modal-md');\r\n\r\n if (result) {\r\n this._formService.updateFormRevisionInfo(result);\r\n }\r\n }\r\n\r\n async edit(): Promise {\r\n await this._modalService.showAsync(FormTemplateEditComponent, null, 'modal-md');\r\n }\r\n\r\n async download(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Downloading' });\r\n try {\r\n await this._formService.downloadTemplate();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async delete(): Promise {\r\n if (this._formService.isPlaceholderTemplate) {\r\n return Promise.resolve();\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm('Are you sure you wish to delete the form template?', 'Confirm Delete');\r\n }\r\n catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n try {\r\n await this._formService.deleteTemplate();\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async showValidations(): Promise {\r\n const params: FormTemplateValidationParams = {\r\n validationResult: this._formService.templateValidationResult\r\n };\r\n\r\n await this._modalService.showAsync(FormTemplateValidationComponent, params, 'modal-lg');\r\n }\r\n\r\n async validate(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Validating' });\r\n\r\n try {\r\n await this._formService.validateTemplate();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n if (this._formService.hasTemplateValidationErrors || this._formService.hasTemplateValidationWarnings) {\r\n const params: FormTemplateValidationParams = {\r\n validationResult: this._formService.templateValidationResult\r\n };\r\n\r\n await this._modalService.showAsync(FormTemplateValidationComponent, params, 'modal-lg');\r\n } else {\r\n try {\r\n await this._messageModalService.alert(\r\n 'The form template does not have any errors or warnings.',\r\n 'Form Template Validation'\r\n );\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForFormReportListGridAction extends ICellRendererParams {\r\n edit: (params: ICellRendererParamsForFormReportListGridAction) => void;\r\n getEditTitle: (params: ICellRendererParamsForFormReportListGridAction) => string;\r\n canEdit: (params: ICellRendererParamsForFormReportListGridAction) => boolean;\r\n canEnterEditMode: (params: ICellRendererParamsForFormReportListGridAction) => boolean;\r\n canRemove: (params: ICellRendererParamsForFormReportListGridAction) => boolean;\r\n remove: (params: ICellRendererParamsForFormReportListGridAction) => void;\r\n canUndoRemove: (params: ICellRendererParamsForFormReportListGridAction) => boolean;\r\n undoRemove: (params: ICellRendererParamsForFormReportListGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class FormReportListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForFormReportListGridAction;\r\n\r\n agInit(params: ICellRendererParamsForFormReportListGridAction): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { Subscription , BehaviorSubject } from 'rxjs';\r\n\r\nexport interface ICellRendererParamsForFormReportListCheckbox extends ICellRendererParams {\r\n editMode$: BehaviorSubject;\r\n canEdit: (params: ICellRendererParamsForFormReportListCheckbox) => boolean;\r\n onValueChanged: (params: ICellRendererParamsForFormReportListCheckbox) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'form-report-list-checkbox',\r\n template: `\r\n \r\n `\r\n})\r\nexport class FormReportListCheckboxCellRendererComponent implements ICellRendererAngularComp {\r\n private _editModeSub: Subscription;\r\n\r\n params: ICellRendererParamsForFormReportListCheckbox;\r\n editMode: boolean = false;\r\n\r\n agInit(params: ICellRendererParamsForFormReportListCheckbox): void {\r\n this.params = params;\r\n this._editModeSub = this.params.editMode$.subscribe(x => this.editMode = x);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub.unsubscribe();\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onModelChanged(eventTarget: EventTarget): void {\r\n const value = (eventTarget as HTMLInputElement).checked;\r\n this.params.value = value\r\n this.params.data[this.params.colDef.field] = value;\r\n this.params.onValueChanged(this.params);\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport { FormService } from '../form.service';\r\nimport { Subscription } from 'rxjs';\r\nimport { AgGridOptionsBuilder } from '../../AgGrid/agGridOptionsBuilder';\r\nimport { AgGridColumns } from '../../AgGrid/agGridColumns';\r\nimport { GridApi, GridReadyEvent, ColDef, GridOptions } from 'ag-grid-community';\r\nimport { AgGridMultiSelectTracker, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer, AgGridMultiSelectRendererParams } from '../../AgGrid/MultiSelectTracker';\r\nimport { AgGridFilterParams } from '../../AgGrid/agGridFilterParams';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\n@Component({\r\n selector: 'form-report-add',\r\n templateUrl: './formReportAdd.component.html',\r\n styleUrls: ['./formReportAdd.component.scss']\r\n})\r\nexport class FormReportAddComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n private _availableReports: Compliance.SavedSearchModelSelectable[] = null;\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.SavedSearchModelSelectable).savedSearchID)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n params: Compliance.FormRevisionReportModel[];\r\n result: Compliance.FormRevisionReportModel[];\r\n\r\n rowsSelected: boolean = false;\r\n\r\n ngOnInit(): void {\r\n const reports = _.filter(this._formService.allReports, (ar) => !_.some(this.params, (fr) => { return ar.savedSearchID === fr.savedSearchId; }));\r\n this._availableReports = _.map(reports, (r) => { return { ...r, isSelected: false } as Compliance.SavedSearchModelSelectable; });\r\n\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.rowsSelected = x.selectAllRows || x.selectedRows.length > 0;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'savedSearchID',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Name',\r\n field: 'searchName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const savedSearch = params.data as Core.SavedSearchModel;\r\n return this._formService.getSavedSearchReportName(savedSearch);\r\n },\r\n filterValueGetter: params => {\r\n const savedSearch = params.data as Core.SavedSearchModel;\r\n return this._formService.getSavedSearchReportName(savedSearch);\r\n }\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'isSystem',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const savedSearch = params.data as Core.SavedSearchModel;\r\n return this._formService.getSavedSearchReportType(savedSearch);\r\n },\r\n filterValueGetter: params => {\r\n const savedSearch = params.data as Core.SavedSearchModel;\r\n return this._formService.getSavedSearchReportType(savedSearch);\r\n }\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save(): Promise {\r\n const rowIds = await this.gridTracker.getSelectedRowIds();\r\n this.result = _.map(_.filter(this._formService.allReports, (x) => _.some(rowIds, (y) => x.savedSearchID === y)), (x) => {\r\n return {\r\n formRevisionReportId: 0,\r\n formRevisionId: this._formService.formRevisionId,\r\n isFrequentlyUsed: true,\r\n isIncluded: false,\r\n savedSearchId: x.savedSearchID,\r\n savedSearchCategoryId: x.savedSearchCategoryID,\r\n sequence: x.sequence,\r\n name: x.searchName,\r\n variantName: x.variantName,\r\n isSystem: x.isSystemSearch,\r\n transferId: null\r\n } as Compliance.FormRevisionReportModel;\r\n });\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._formService.isInitialized)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._availableReports);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map((x) => {\r\n const savedSearch = x.data as Core.SavedSearchModel;\r\n return savedSearch && savedSearch.savedSearchID;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Reports [All Tax Years - All Assessors]\r\n \r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormService } from '../form.service';\r\nimport { Subscription, BehaviorSubject, lastValueFrom } from 'rxjs';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { ColDef, GridApi, GridReadyEvent, RowNode } from 'ag-grid-community';\r\nimport { AgGridFilterParams, AgGridColumns } from '../../AgGrid';\r\nimport { AgGridOptionsBuilder } from '../../AgGrid';\r\nimport { FormReportListGridActionCellRendererComponent, ICellRendererParamsForFormReportListGridAction } from './agGridActionCellRenderer.component';\r\nimport { WeissmanMutexService, IMutexServiceHandler } from '../../WeissmanMutexService';\r\nimport { FormReportListCheckboxCellRendererComponent } from './agGridCheckboxCellRender.component';\r\nimport { ICellRendererParamsForFormReportListCheckbox } from './agGridCheckboxCellRender.component';\r\nimport { FormReportAddComponent } from '../Form-Report-Add/formReportAdd.component';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { FormRepository } from '../../Repositories';\r\nimport { BaseExpandableAgGridComponent } from '../../../UI-Lib/Expandable-Component/baseExpandableAgGridComponent';\r\nimport { ReportManagerModalService } from '../../../Reporting/Manager/reportManagerModal.service';\r\nimport { ReportManagerModalInputParameters } from '../../../Reporting/Manager/reportManagerModal.component';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nexport interface FormRevisionReportRowModel extends Compliance.FormRevisionReportModel {\r\n deleted: boolean;\r\n added: boolean;\r\n changed: boolean;\r\n originalValue: Compliance.FormRevisionReportModel;\r\n displayName: string;\r\n}\r\n\r\n@Component({\r\n selector: 'form-report-list',\r\n templateUrl: './formReportList.component.html',\r\n styleUrls: ['./formReportList.component.scss']\r\n})\r\nexport class FormReportListComponent extends BaseExpandableAgGridComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _formService: FormService,\r\n private readonly _formRepository: FormRepository,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _reportManagerModalService: ReportManagerModalService\r\n ) {\r\n super(_formService, 'form-report-list');\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _formRevisionSub: Subscription;\r\n private _reportsSub: Subscription;\r\n private _editModeSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _editModeSub: Subscription;\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._formService.editGroup);\r\n }\r\n\r\n get hasChanges(): boolean {\r\n let hasChanges: boolean = false;\r\n\r\n if (this._gridApi) {\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const report = node.data as FormRevisionReportRowModel;\r\n if (report && (report.deleted || report.added || report.changed)) {\r\n hasChanges = true;\r\n }\r\n });\r\n }\r\n\r\n return hasChanges;\r\n }\r\n\r\n editMode: boolean = false;\r\n\r\n gridId: System.Guid = '4CEF3CDA-E95B-4382-8371-D601D7E959F6';\r\n\r\n gridOptions = new AgGridOptionsBuilder(\r\n {\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'grid-row-deleted': params => params.data && params.data.deleted\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .withRowId(x => {\r\n const report = x as FormRevisionReportRowModel;\r\n return report && report.formRevisionReportId.toString();\r\n })\r\n .withFirstDataRendered(x => {\r\n x.api.sizeColumnsToFit();\r\n })\r\n .build();\r\n\r\n ngOnInit(): void {\r\n this._editModeSub = this._editModeSubject.asObservable().subscribe(x => {\r\n this.editMode = x;\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n });\r\n\r\n this._formRevisionSub = this._formService.formRevision$.subscribe(() => {\r\n // initial load\r\n this._setRowData();\r\n });\r\n\r\n this._reportsSub = this._formService.reports$.subscribe(() => {\r\n // reports changed\r\n this._setRowData();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._editModeSub && this._editModeSub.unsubscribe();\r\n this._formRevisionSub && this._formRevisionSub.unsubscribe();\r\n this._reportsSub && this._reportsSub.unsubscribe();\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n super.setGridApi(event.api);\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Name',\r\n field: 'displayName',\r\n width: AgGridColumns.textColumnWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'isSystem',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const formRevisionReport = params.data as Compliance.FormRevisionReportModel;\r\n return this._formService.getReportType(formRevisionReport);\r\n },\r\n filterValueGetter: params => {\r\n const formRevisionReport = params.data as Compliance.FormRevisionReportModel;\r\n return this._formService.getReportType(formRevisionReport);\r\n }\r\n },\r\n {\r\n headerName: 'Included',\r\n field: 'isIncluded',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: FormReportListCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n canEdit: this._canEditSettings.bind(this),\r\n editMode$: this._editModeSubject.asObservable(),\r\n onValueChanged: this._onValueChanged.bind(this)\r\n } as ICellRendererParamsForFormReportListCheckbox\r\n },\r\n {\r\n headerName: 'Freq. Used',\r\n field: 'isFrequentlyUsed',\r\n width: AgGridColumns.textColumnMedWidth,\r\n minWidth: AgGridColumns.checkboxColumnMinWidth,\r\n cellRendererFramework: FormReportListCheckboxCellRendererComponent,\r\n cellRendererParams: {\r\n canEdit: this._canEditSettings.bind(this),\r\n editMode$: this._editModeSubject.asObservable(),\r\n onValueChanged: this._onValueChanged.bind(this)\r\n } as ICellRendererParamsForFormReportListCheckbox\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: FormReportListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canEdit: this._canEdit.bind(this),\r\n canEnterEditMode: this._canEnterEditMode.bind(this),\r\n edit: this._edit.bind(this),\r\n getEditTitle: this._getEditTitle.bind(this),\r\n canRemove: this._canRemove.bind(this),\r\n remove: this._remove.bind(this),\r\n canUndoRemove: this._canUndoRemove.bind(this),\r\n undoRemove: this._undoRemove.bind(this),\r\n } as ICellRendererParamsForFormReportListGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'displayName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n async edit(): Promise {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n const res = await this._formService.checkEditDefaultAssessor();\r\n if (res) {\r\n this._mutexService.acquire(this, this._formService.editGroup);\r\n this._editModeSubject.next(true);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n const update: RowNode[] = [];\r\n const remove: FormRevisionReportRowModel[] = [];\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const report = node.data as FormRevisionReportRowModel;\r\n\r\n if (report && !report.added) {\r\n update.push(node);\r\n\r\n _.extend(report, report.originalValue, { changed: false, deleted: false });\r\n\r\n } else { // if added, remove it\r\n remove.push(report);\r\n }\r\n });\r\n\r\n this._gridApi.updateRowData({ remove: remove });\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this._editModeSubject.next(false);\r\n }\r\n\r\n async add(): Promise {\r\n const reports: Compliance.FormRevisionReportModel[] = [];\r\n this._gridApi.forEachNode(x => reports.push(x.data));\r\n\r\n const result = await this._modalService.showAsync(FormReportAddComponent, reports, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const newReports = _.map(result,\r\n (x) => {\r\n return _.extend(\r\n {} as FormRevisionReportRowModel,\r\n x,\r\n {\r\n formRevisionId: this._formService.formRevisionId,\r\n isFrequentlyUsed: true,\r\n isIncluded: false,\r\n added: true,\r\n deleted: false,\r\n changed: false,\r\n originalValue: null,\r\n displayName: this._formService.getReportName(x)\r\n });\r\n });\r\n\r\n this._gridApi.updateRowData({ add: newReports });\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async save(): Promise {\r\n if (!this.hasChanges) {\r\n return Promise.resolve();\r\n }\r\n\r\n const reports: Compliance.FormRevisionReportModel[] = [];\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const reportRow = node.data as FormRevisionReportRowModel;\r\n\r\n if (!reportRow.deleted) {\r\n const report = _.extend({} as Compliance.FormRevisionReportModel, reportRow);\r\n reports.push(report);\r\n }\r\n });\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving Reports' });\r\n\r\n try {\r\n const result = await lastValueFrom(this._formRepository.updateReports(this._formService.formRevisionId, reports));\r\n this._formService.setReports(result);\r\n this._editModeSubject.next(false);\r\n this._mutexService.release(this, this._formService.editGroup);\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n private _getEditTitle(params: ICellRendererParamsForFormReportListGridAction): string {\r\n const formRevisionReportRow = params.data as FormRevisionReportRowModel;\r\n if (!formRevisionReportRow) {\r\n return '';\r\n }\r\n\r\n if (formRevisionReportRow.savedSearchCategoryId !== Core.SavedSearchCategoryEnum.ComplianceReportSetup &&\r\n formRevisionReportRow.savedSearchCategoryId !== Core.SavedSearchCategoryEnum.ComplianceCustomReport) {\r\n return 'Cannot customize this type of report';\r\n }\r\n\r\n if (formRevisionReportRow.added) {\r\n return 'Cannot customize until you save changes';\r\n }\r\n\r\n if (formRevisionReportRow.deleted) {\r\n return 'Cannot customize a deleted report';\r\n }\r\n\r\n return '';\r\n }\r\n\r\n private _canEdit(params: ICellRendererParamsForFormReportListGridAction): boolean {\r\n const formRevisionReportRow = params.data as FormRevisionReportRowModel;\r\n if (!formRevisionReportRow) {\r\n return false;\r\n }\r\n return this.canEdit && this.editMode;\r\n }\r\n\r\n private _canEnterEditMode(params: ICellRendererParamsForFormReportListGridAction): boolean {\r\n const formRevisionReportRow = params.data as FormRevisionReportRowModel;\r\n if (!formRevisionReportRow) {\r\n return false;\r\n }\r\n\r\n return (!(formRevisionReportRow.added || formRevisionReportRow.deleted)) &&\r\n (formRevisionReportRow.savedSearchCategoryId === Core.SavedSearchCategoryEnum.ComplianceReportSetup ||\r\n formRevisionReportRow.savedSearchCategoryId === Core.SavedSearchCategoryEnum.ComplianceCustomReport);\r\n }\r\n\r\n private async _edit(params: ICellRendererParamsForFormReportListGridAction): Promise {\r\n const formRevisionReportRow = params.data as FormRevisionReportRowModel;\r\n if (!formRevisionReportRow) {\r\n return;\r\n }\r\n\r\n const modalParams: ReportManagerModalInputParameters = {\r\n reportId: formRevisionReportRow.savedSearchId,\r\n reportType: formRevisionReportRow.isSystem ? 0 : 1,\r\n formRevisionId: formRevisionReportRow.formRevisionId,\r\n formRevisions: [],\r\n schedules: this._formService.formRevision.formRevisionSchedules\r\n };\r\n\r\n try {\r\n const formRevisionReport = await this._reportManagerModalService.showForFormRevision(modalParams);\r\n\r\n if (!formRevisionReport) {\r\n return;\r\n }\r\n\r\n _.extend(\r\n formRevisionReportRow,\r\n formRevisionReport,\r\n { changed: true, deleted: false, added: false, originalValue: formRevisionReport,\r\n displayName: this._formService.getReportName(formRevisionReport) });\r\n\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n } catch (e) {\r\n\r\n }\r\n }\r\n\r\n private _canEditSettings(params: ICellRendererParamsForFormReportListCheckbox): boolean {\r\n const report = params.data as FormRevisionReportRowModel;\r\n if (!report) {\r\n return false;\r\n }\r\n return this.canEdit && !report.deleted;\r\n }\r\n\r\n private _canUndoRemove(params: ICellRendererParamsForFormReportListGridAction): boolean {\r\n const formRevisionReportRow = params.data as FormRevisionReportRowModel;\r\n if (!formRevisionReportRow) {\r\n return false;\r\n }\r\n\r\n return this.editMode && formRevisionReportRow.deleted;\r\n }\r\n\r\n private _canRemove(params: ICellRendererParamsForFormReportListGridAction): boolean {\r\n const formRevisionReportRow = params.data as FormRevisionReportRowModel;\r\n if (!formRevisionReportRow) {\r\n return false;\r\n }\r\n\r\n return this.editMode && !formRevisionReportRow.deleted;\r\n }\r\n\r\n private _remove(params: ICellRendererParamsForFormReportListGridAction): void {\r\n const report = params.data as FormRevisionReportRowModel;\r\n if (!report) {\r\n return;\r\n }\r\n\r\n if (!report.added) {\r\n report.deleted = true;\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n } else {\r\n this._gridApi.updateRowData({ remove: [report] });\r\n }\r\n }\r\n\r\n private _undoRemove(params: ICellRendererParamsForFormReportListGridAction): void {\r\n const report = params.data as FormRevisionReportRowModel;\r\n if (!report) {\r\n return;\r\n }\r\n\r\n report.deleted = false;\r\n\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n }\r\n\r\n private _onValueChanged(params: ICellRendererParamsForFormReportListCheckbox): void {\r\n const report = params.data as FormRevisionReportRowModel;\r\n if (!report) {\r\n return;\r\n }\r\n\r\n report.changed = true;\r\n }\r\n\r\n private _setRowData() {\r\n if (!(this._gridApi && this._formService.isInitialized)) {\r\n return;\r\n }\r\n\r\n const reports = _.map(this._formService.reports,\r\n (x) => {\r\n return _.extend(\r\n {} as FormRevisionReportRowModel,\r\n x,\r\n {\r\n changed: false,\r\n deleted: false,\r\n added: false,\r\n originalValue: x,\r\n displayName: this._formService.getReportName(x)\r\n });\r\n });\r\n\r\n this._gridApi.setRowData(reports);\r\n }\r\n}\r\n","
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { FormService } from '../form.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { Constants } from '../../../constants.new';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\nimport * as _ from 'lodash';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\n\r\n@Component({\r\n selector: 'form-switches',\r\n templateUrl: './formSwitches.component.html'\r\n})\r\nexport class FormSwitchesComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _toastsManager: ToastrService,\r\n private readonly _constants: Constants,\r\n private _messageModalService: MessageModalService) { }\r\n\r\n isPrimary: UntypedFormControl = new UntypedFormControl(false);\r\n isInDevelopment: UntypedFormControl = new UntypedFormControl(false);\r\n\r\n initializedPrimary: boolean;\r\n initializedDevelopment: boolean;\r\n\r\n formTypes = this._constants.FormTypes;\r\n selectedFormType: Compliance.NameValuePair = null;\r\n selectedFormIsSupplementalAppeal: boolean;\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._formService.editGroup);\r\n }\r\n\r\n ngOnInit(): void {\r\n this._updateIsPrimary();\r\n\r\n this._mutexService.lockChanged$.pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n // initial load\r\n this._updateIsPrimary();\r\n this._updateIsInDevelopment();\r\n });\r\n\r\n this._formService.formRevision$.pipe(takeUntil(this.destroy$)).subscribe((formRevision) => {\r\n // initial load\r\n this._updateIsPrimary();\r\n this._updateIsInDevelopment();\r\n if (formRevision) {\r\n this.selectedFormType = _.find(this.formTypes, x => x.value as number === formRevision.formTypeId);\r\n this.selectedFormIsSupplementalAppeal = this.selectedFormType.value === Compliance.FormTypeEnum.Appeal && !!formRevision.parentFormRevisionId;\r\n }\r\n });\r\n\r\n this._formService.formRevisionYear$.pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n // year changed\r\n this._updateIsPrimary();\r\n this._updateIsInDevelopment();\r\n });\r\n\r\n this._formService.isPrimary$.pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n // primary changed\r\n this._updateIsPrimary();\r\n });\r\n\r\n this._formService.isInDevelopment$.pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n // in development changed\r\n this._updateIsInDevelopment();\r\n });\r\n\r\n this._formService.anyAssessorMappingsCertified$.pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n // assessor certifications changed\r\n this._updateIsInDevelopment();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n async onIsPrimaryChange(isPrimary: boolean): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n await this._formService.updateIsPrimary(isPrimary);\r\n this._toastsManager.success(`Form set as ${isPrimary ? '' : 'not '}primary for ${this._formService.taxYear}`);\r\n }\r\n catch(e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n\r\n if (e2.error.message) {\r\n try {\r\n busyRef.hide();\r\n await this._messageModalService.confirm(\r\n e2.error.message,\r\n 'Confirm Update');\r\n await this._formService.updateIsPrimary(isPrimary, true);\r\n } catch (e3) {\r\n this.isPrimary.setValue(!isPrimary);\r\n return Promise.resolve();\r\n }\r\n }\r\n }\r\n finally {\r\n this._updateIsPrimary();\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async onIsInDevelopmentChange(isInDevelopment: boolean): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n await this._formService.updateIsInDevelopment(isInDevelopment);\r\n this._toastsManager.success(`Form set as ${isInDevelopment ? '' : 'not '}in development for ${this._formService.taxYear}`);\r\n }\r\n finally {\r\n this._updateIsInDevelopment();\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _updateIsPrimary(): void {\r\n const isPrimary = this._formService.isPrimary;\r\n if (isPrimary !== null && isPrimary !== undefined) {\r\n this.isPrimary.setValue(isPrimary);\r\n this.initializedPrimary = true;\r\n }\r\n this._setCanEdit();\r\n }\r\n\r\n private _updateIsInDevelopment(): void {\r\n const isInDevelopment = this._formService.isInDevelopment;\r\n if (isInDevelopment !== null && isInDevelopment !== undefined) {\r\n this.isInDevelopment.setValue(isInDevelopment);\r\n this.initializedDevelopment = true;\r\n }\r\n this._setCanEdit();\r\n }\r\n\r\n private _setCanEdit(): void {\r\n if (!this.canEnterEditMode || !this.canEdit) {\r\n this.isPrimary.disable();\r\n this.isInDevelopment.disable();\r\n } else {\r\n this.isPrimary.enable();\r\n this.isInDevelopment.enable();\r\n }\r\n }\r\n\r\n}\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { FormService } from '../form.service';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { AppealLevel } from '../../../Annual-Details/Appeals/appeal.model';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'form-appeal-level-list',\r\n templateUrl: './formAppealLevelList.component.html',\r\n styleUrls: ['./formAppealLevelList.component.scss']\r\n})\r\nexport class FormAppealLevelListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _formService: FormService,\r\n private readonly _toastsManager: ToastrService\r\n ) { }\r\n\r\n get canEnterEditMode(): boolean {\r\n return this._mutexService.canAcquire(this._formService.editGroup);\r\n }\r\n\r\n appealLevels: AppealLevel[] = [];\r\n\r\n appealLevelId: UntypedFormControl = new UntypedFormControl({ disabled: !this.canEnterEditMode });\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._formService.formRevision$.pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n // initial load\r\n this.appealLevels = [...this._formService.appealLevels];\r\n if (this.appealLevels.length) {\r\n this.appealLevelId.setValue(this._formService.appealLevelId);\r\n }\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n async onSelectedAppealLevelChange(appealLevel: AppealLevel): Promise {\r\n if (!appealLevel) {\r\n return;\r\n }\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n try {\r\n await this._formService.setFormRevisionAppealLevel(appealLevel.appealLevelID);\r\n this._toastsManager.success('Appeal level successfully set');\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { FormService } from '../form.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'form-assessor-select',\r\n templateUrl: './formAssessorSelect.component.html',\r\n styleUrls: ['./formAssessorSelect.component.scss']\r\n})\r\nexport class FormAssessorSelectComponent implements OnInit, OnDestroy {\r\n\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _busyIndicatorService: BusyIndicatorService\r\n ) {}\r\n\r\n assessors: Compliance.FormRevisionAssessorModel[];\r\n selectedAssessor: UntypedFormControl = new UntypedFormControl();\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit() {\r\n this.selectedAssessor.disable();\r\n\r\n this._formService.formRevision$.pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n // initial load\r\n this.selectedAssessor.setValue(this._formService.assessor);\r\n this._setAssessors();\r\n });\r\n\r\n this._formService.formRevisionYear$.pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n // year changed\r\n this.selectedAssessor.setValue(this._formService.assessor);\r\n this._setAssessors();\r\n });\r\n\r\n this._formService.assessors$.pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n // assessors changed\r\n this.selectedAssessor.setValue(this._formService.assessor);\r\n this._setAssessors();\r\n });\r\n\r\n this._formService.assessor$.pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n // assessors changed\r\n this.selectedAssessor.setValue(this._formService.assessor);\r\n this._setAssessors();\r\n });\r\n\r\n this._mutexService.lockChanged$.pipe(takeUntil(this.destroy$))\r\n .subscribe((val) => (!val.hasOwnProperty(this._formService.editGroup))\r\n ? this.selectedAssessor.enable()\r\n : this.selectedAssessor.disable());\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n \r\n async selectedAssessorChanged(assessor: Compliance.FormRevisionAssessorModel): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: `Loading ${assessor && assessor.assessorName}` });\r\n try {\r\n await this._formService.setAssessor(assessor);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private _setAssessors(): void {\r\n this.assessors = this._formService.assessorsAssigned;\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { FormRepository } from '../../Repositories/form.repository';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef} from 'ngx-bootstrap/modal';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, CsvExportParams } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder } from '../../AgGrid/agGridOptionsBuilder';\r\nimport { AgGridFilterParams, AgGridColumns } from '../../AgGrid';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { FormService } from '../form.service';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from '../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\n\r\n@Component({\r\n selector: 'form-filing-batch-list',\r\n templateUrl: './formFilingBatchList.component.html',\r\n styleUrls: ['./formFilingBatchList.component.scss']\r\n})\r\nexport class FormFilingBatchListComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _formRepository: FormRepository,\r\n private readonly _formService: FormService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _filingBatches: Compliance.FilingBatchInfoModel[];\r\n\r\n params: void;\r\n result: void;\r\n\r\n isBusy: boolean = false;\r\n\r\n get headerLabel(): string {\r\n return `In-Use Filing Batches for ${this._formService.assessorName}`;\r\n }\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .build();\r\n\r\n async ngOnInit(): Promise {\r\n this.isBusy = true;\r\n\r\n try {\r\n this._filingBatches = await lastValueFrom(this._formRepository.getFilingBatches(this._formService.assessorId));\r\n this._setRowData();\r\n }\r\n finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Batch #',\r\n field: 'displayId',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-filing-batch',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingBatch = params.data as Compliance.FormRevisionFilingBatchInfoModel;\r\n if (!(filingBatch && filingBatch.filingBatchId)) {\r\n return '';\r\n }\r\n return `#/returnBatch/${filingBatch.filingBatchId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n headerName: 'Progress Status',\r\n field: 'statusCode',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n ,\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n lockVisible: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingBatch = params.data as Compliance.FormRevisionFilingBatchInfoModel;\r\n if (!(filingBatch && filingBatch.assessorId)) {\r\n return '';\r\n }\r\n return `#/assessor/${filingBatch.assessorId}`;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => {\r\n const filingBatch = params.data as Compliance.FormRevisionFilingBatchInfoModel;\r\n return !(filingBatch && filingBatch.assessorId);\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'displayId',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n export(): void {\r\n const params = {\r\n fileName: 'FormFilingBatches.csv'\r\n } as CsvExportParams;\r\n this._gridApi.exportDataAsCsv(params);\r\n }\r\n\r\n private _setRowData() {\r\n if (!(this._gridApi && this._filingBatches)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._filingBatches);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n}\r\n","\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { FormFilingBatchListComponent } from '../Form-Filing-Batch-List/formFilingBatchList.component';\r\nimport { FormService } from '../form.service';\r\n\r\n@Component({\r\n selector: 'form-filing-batches',\r\n templateUrl: './formFilingBatches.component.html'\r\n})\r\nexport class FormFilingBatchesComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _formService: FormService) { }\r\n\r\n get helpContent(): string {\r\n return `In-Use Filing Batches for ${this._formService.assessorName}`\r\n }\r\n\r\n ngOnInit(): void { }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n async show(): Promise {\r\n await this._modalService.showAsync(FormFilingBatchListComponent, null, 'modal-xl');\r\n }\r\n}\r\n","
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { FormService } from '../form.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { Subscription } from 'rxjs';\r\nimport * as _ from 'lodash';\r\nimport { WeissmanMutexService } from '../../WeissmanMutexService';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { FORM_HELP } from '../form.help';\r\n\r\n@Component({\r\n selector: 'form-page',\r\n templateUrl: './formPage.component.html',\r\n styleUrls: ['./formPage.component.scss']\r\n})\r\nexport class FormPageComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _formService: FormService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _helpService: HelpService) { }\r\n\r\n private _lockChangedSub: Subscription;\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n\r\n get formRevision(): Compliance.FormRevisionModel {\r\n return this._formService.formRevision;\r\n }\r\n\r\n get isFormTypeAppeal(): boolean {\r\n return this._formService.isFormTypeAppeal;\r\n }\r\n\r\n get canEdit(): boolean {\r\n return this._formService.canEdit;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(FORM_HELP);\r\n\r\n this._formService.reset();\r\n this._formService.loadRoles();\r\n\r\n if (!(this._formService.canEdit || this._formService.canView)) {\r\n this._routerService.go('unauthorizedAccess', {});\r\n return Promise.resolve();\r\n }\r\n\r\n const formRevisionId = parseInt(this._routerService.getQuerystringParam('formRevisionId'));\r\n const taxYear = parseInt(this._routerService.getQuerystringParam('taxYear'));\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading Form' });\r\n\r\n try {\r\n await this._formService.loadFormRevision(formRevisionId, taxYear);\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n this._lockChangedSub = this._mutexService.lockChanged$.subscribe((x) => {\r\n const isLocked = x && x[this._formService.editGroup];\r\n if (isLocked) {\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you wish to leave?');\r\n }\r\n else {\r\n this._navigationService.disableNavWarning();\r\n }\r\n });\r\n\r\n this.breadcrumbs = [\r\n {\r\n name: 'Forms',\r\n target: 'formList',\r\n options: {}\r\n },\r\n {\r\n name: this.formRevision.state,\r\n target: 'formList',\r\n options: {}\r\n }\r\n ];\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._lockChangedSub && this._lockChangedSub.unsubscribe();\r\n }\r\n\r\n isHidden(componentName: string): boolean {\r\n return this._formService.isOtherComponentExpanded(componentName) || !this._formService.isValidForAppeal(componentName);\r\n }\r\n\r\n areHidden(componentNames: string[]): boolean {\r\n return _.find(componentNames,\r\n (componentName) => {\r\n return !this.isHidden(componentName);\r\n }) ? false : true;\r\n }\r\n}\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { GLAccountRepository } from '../../Repositories';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../AgGrid';\r\n\r\nexport class GLAccountListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private _gridApi: GridApi,\r\n private _glAccountRepository: GLAccountRepository,\r\n private _companyId: number\r\n ) { super(_gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'accountName', value: Compliance.GLAccountPropertyEnum.AccountName },\r\n { name: 'accountNumber', value: Compliance.GLAccountPropertyEnum.AccountNumber },\r\n { name: 'description', value: Compliance.GLAccountPropertyEnum.Description },\r\n { name: 'assetClassification', value: Compliance.GLAccountPropertyEnum.AssetClassification },\r\n { name: 'accountTypeName', value: Compliance.GLAccountPropertyEnum.AccountType },\r\n { name: 'foundInAssets', value: Compliance.GLAccountPropertyEnum.FoundInAssets },\r\n { name: 'incomeStatementCategoryName', value: Compliance.GLAccountPropertyEnum.IncomeStatementCategoryName },\r\n { name: 'foundInAccruals', value: Compliance.GLAccountPropertyEnum.FoundInAccruals },\r\n { name: 'foundInIncomeStatements', value: Compliance.GLAccountPropertyEnum.FoundInIncomeStatements },\r\n { name: 'createDate', value: Compliance.GLAccountPropertyEnum.CreateDate },\r\n { name: 'validatedBy', value: Compliance.GLAccountPropertyEnum.ValidatedBy },\r\n { name: 'validatedDate', value: Compliance.GLAccountPropertyEnum.ValidatedDate }\r\n ];\r\n\r\n protected canGetRows(): boolean {\r\n return !!this._companyId;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.SearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n\r\n const result = await lastValueFrom(this._glAccountRepository.getList(this._companyId, searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows,\r\n lastModifiedTimestamp: result.lastModifiedTimestamp\r\n };\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.SearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n\r\n return await lastValueFrom(this._glAccountRepository.getRowIds(this._companyId, searchParams));\r\n }\r\n\r\n getSearchModelWithoutPagination(): Core.SearchModel {\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { GLAccountRepository } from '../Repositories';\r\nimport { HttpResponse } from '@angular/common/http';\r\nimport { CompanyService } from '../../Entity/Company/company.service';\r\nimport { RestrictService } from '../../Common/Permissions/restrict.service';\r\n\r\n@Injectable()\r\nexport class GLAccountService {\r\n private _accrualsFeatureEnabled: boolean = false;\r\n\r\n constructor(\r\n private readonly _glAccountRepository: GLAccountRepository,\r\n private readonly _companyService: CompanyService,\r\n private readonly _restrictService: RestrictService)\r\n {\r\n this._accrualsFeatureEnabled = null;\r\n }\r\n\r\n private _company: Core.CompanyModel;\r\n private _tlCompany: Core.CompanyRecordDTO;\r\n private _canReadCompany: boolean = false;\r\n private _canWriteCompany: boolean = false;\r\n private _startResults: Compliance.GLAccountStartResultModel;\r\n\r\n get company(): Core.CompanyModel {\r\n return this._company;\r\n }\r\n\r\n get companyId(): number {\r\n return this._company && this._company.companyID;\r\n }\r\n\r\n get tlCompany(): Core.CompanyRecordDTO {\r\n return this._tlCompany;\r\n }\r\n\r\n get tlCompanyId(): number {\r\n return this._tlCompany && this._tlCompany.companyID;\r\n }\r\n\r\n get isTopLevelCompany(): boolean {\r\n return this._company && this._company.companyID === this._company.topLevelCompanyId;\r\n }\r\n\r\n get isSubsidiaryCompany(): boolean {\r\n return this._company && this._company.companyID !== this._company.topLevelCompanyId;\r\n }\r\n\r\n get companyName(): string {\r\n return this._company && this._company.companyName;\r\n }\r\n\r\n get canReadCompany(): boolean {\r\n return this._canReadCompany;\r\n }\r\n\r\n get canWriteCompany(): boolean {\r\n return this._canWriteCompany;\r\n }\r\n\r\n get startResults(): Compliance.GLAccountStartResultModel {\r\n return this._startResults;\r\n }\r\n\r\n get accrualsFeatureEnabled(): boolean {\r\n return this._accrualsFeatureEnabled;\r\n }\r\n\r\n async start(companyId: number): Promise {\r\n this._accrualsFeatureEnabled = await this._companyService.checkAccrualsEnabled();\r\n\r\n this._company = await this._companyService.load(companyId, false, false);\r\n this._tlCompany = await this._companyService.getTopCompanyForEntity(Core.EntityTypes.Company, this._company.topLevelCompanyId);\r\n\r\n const read = await this._restrictService.hasCompanyPermission(this._company.topLevelCompanyId, Core.AccessRightsEnum.Read);\r\n this._canReadCompany = read && !!this._company;\r\n\r\n if (this._canReadCompany) {\r\n const write = await this._restrictService.hasCompanyPermission(this._company.topLevelCompanyId, Core.AccessRightsEnum.Write);\r\n this._canWriteCompany = write &&\r\n ((this._company.companyID === this._company.topLevelCompanyId) ||\r\n (this._company.companyID !== this._company.topLevelCompanyId) && (!this._company.useTopLevelCompanyCOA));\r\n }\r\n\r\n // Retrieve data for G/L Account popup selections.\r\n this._startResults = await lastValueFrom(this._glAccountRepository.start(this._company.topLevelCompanyId));\r\n }\r\n\r\n stop(): void {\r\n this._company = null;\r\n this._canReadCompany = false;\r\n this._canWriteCompany = false;\r\n this._startResults = null;\r\n }\r\n\r\n async startExport(companyId: number, exportModel: Compliance.GLAccountExportModel): Promise {\r\n return await lastValueFrom(this._glAccountRepository.startExport(companyId, exportModel));\r\n }\r\n\r\n async getExport(companyId: number, longRunningProcessId: number): Promise> {\r\n return await lastValueFrom(this._glAccountRepository.getExport(companyId, longRunningProcessId));\r\n }\r\n\r\n async get(glAccountId: number): Promise {\r\n return await lastValueFrom(this._glAccountRepository.get(glAccountId));\r\n }\r\n\r\n async create(glAccount: Compliance.GLAccountModel): Promise {\r\n return await lastValueFrom(this._glAccountRepository.create(glAccount));\r\n }\r\n\r\n async update(glAccount: Compliance.GLAccountModel): Promise {\r\n return await lastValueFrom(this._glAccountRepository.update(glAccount));\r\n }\r\n\r\n async updateBulk(companyId: number, bulkUpdateModel: Compliance.GLAccountBulkUpdateModel): Promise {\r\n await lastValueFrom(this._glAccountRepository.bulkUpdate(companyId, bulkUpdateModel));\r\n }\r\n\r\n async updateBulkIncomeStatementTypes(companyId: number, bulkUpdateModel: Compliance.GLAccountBulkUpdateIncomeStatementTypesModel): Promise {\r\n await lastValueFrom(this._glAccountRepository.bulkUpdateIncomeStatementTypes(companyId, bulkUpdateModel));\r\n }\r\n\r\n async delete(glAccountId: number): Promise {\r\n return await lastValueFrom(this._glAccountRepository.delete(glAccountId));\r\n }\r\n\r\n async selectionSummary(companyId: number, searchModel: Core.SearchModel, selectedRowsModel: Compliance.SelectedRowsModel) {\r\n return await lastValueFrom(this._glAccountRepository.selectionSummary(companyId, searchModel, selectedRowsModel));\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n\r\n
\r\n
\r\n
\r\n
\r\n \r\n
{{ form.controls.accountNumber.value }}
\r\n \r\n
\r\n
G/L Account Number is required.
\r\n
G/L Account Number max length is 100 characters.
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
{{ form.controls.accountName.value }}
\r\n \r\n
\r\n
G/L Account Name is required.
\r\n
G/L Account Name max length is 100 characters.
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
{{ form.controls.description.value }}
\r\n \r\n
\r\n
G/L Account Description max length is 500 characters.
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
{{ currAccountType?.name }}
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
{{ form.controls.selectedAccountAccrualType.value?.name }}
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n

Accrual Scope

\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
{{ form.controls.assetClassificationName.value }}
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
{{ form.controls.incomeStatementCategoryName.value }}
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormArray, FormControl } from '@angular/forms';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { GLAccountService } from '../glAccount.service';\r\n\r\nexport enum DisplayMode {\r\n Add = 0,\r\n Edit = 1,\r\n View = 2\r\n}\r\n\r\nexport interface GLAccountDetailsParams {\r\n glAccountId: number;\r\n displayMode: DisplayMode;\r\n companyId: number;\r\n foundInAssets: boolean;\r\n foundInIncomeStatements: boolean;\r\n foundInAccruals: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'gl-account-details',\r\n templateUrl: './glAccountDetails.component.html'\r\n})\r\nexport class GLAccountDetailsComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formBuilder: UntypedFormBuilder,\r\n private readonly _glAccountService: GLAccountService\r\n ) {}\r\n\r\n params: GLAccountDetailsParams;\r\n result: Compliance.GLAccountModel;\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n DisplayMode = DisplayMode;\r\n\r\n // reactive form helper methods for accessing part of that form\r\n form: UntypedFormGroup;\r\n glAccount: Compliance.GLAccountModel = null;\r\n currAccountType: Compliance.GLAccountTypeModel = { glAccountTypeId: 0, name: '', validForAccrual: false };\r\n currAccountAccrualTypes: Compliance.GLAccountAccrualTypeModel[] = [];\r\n accrualsFeatureEnabled: boolean = false;\r\n\r\n PropertyTaxPayableType: Compliance.GLAccountAccrualTypeEnum = Compliance.GLAccountAccrualTypeEnum.PropertyTaxPayable;\r\n\r\n accountTypes: Compliance.GLAccountTypeModel[];\r\n\r\n get f() { return this.form; }\r\n\r\n get fPropTypes() { return (this.form.get('forPropertyTypes') as UntypedFormArray); }\r\n\r\n get fPmtTypes() { return (this.form.get('forPaymentTypes') as UntypedFormArray); }\r\n\r\n get accountAccrualTypes(): Compliance.GLAccountAccrualTypeModel[] {\r\n return this._glAccountService.startResults.glAccountAccrualTypes;\r\n }\r\n\r\n get propertyTypes(): Core.PropertyTypeModel[] {\r\n return this._glAccountService.startResults.propertyTypes;\r\n }\r\n\r\n get paymentTypes(): Core.PaymentTypeModel[] {\r\n return this._glAccountService.startResults.paymentTypes;\r\n }\r\n\r\n get accrualScopeCompanies(): Core.NameIdPair[] {\r\n return this._glAccountService.startResults.companies;\r\n }\r\n\r\n get isTopLevelCompany(): boolean {\r\n return this._glAccountService.isTopLevelCompany;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n // Create the form before any async operation so that it exists before Angular references it.\r\n this.form = this._formBuilder.group({\r\n accountNumber: [null, [Validators.required, Validators.maxLength(100)]],\r\n accountName: [null, [Validators.required, Validators.maxLength(100)]],\r\n description: [null, [Validators.maxLength(500)]],\r\n assetClassificationId: [null, []],\r\n assetClassificationName: [null, []],\r\n selectedAccountType: [null, [Validators.required]],\r\n applicableToAccruals: [{value: false, disabled: this.params.displayMode === 2}, []],\r\n payableIncludesPrepaid: [{value: false}, []],\r\n selectedAccountAccrualType: [null, []],\r\n forAllCompanies: [{value: true, disabled: this.params.displayMode === 2}, []],\r\n forPropertyTypes: this._formBuilder.array(this.propertyTypes.map(t => ({ value: false, disabled: this.params.displayMode === 2}))),\r\n forPaymentTypes: this._formBuilder.array(this.paymentTypes.map(t => ({ value: false, disabled: this.params.displayMode === 2}))),\r\n forCompanies: [[], []],\r\n incomeStatementCategoryName: [null, []],\r\n incomeStatementCategoryId: [null, []],\r\n isValidated: [null, []],\r\n });\r\n\r\n this.accrualsFeatureEnabled = this._glAccountService.accrualsFeatureEnabled &&\r\n this._glAccountService.tlCompany.accrualsEnabled;\r\n\r\n if (this.params.foundInAccruals) {\r\n this.form.get('applicableToAccruals').disable();\r\n this.form.get('payableIncludesPrepaid').disable();\r\n this.form.get('forPropertyTypes').disable();\r\n this.form.get('forPaymentTypes').disable();\r\n this.form.get('forAllCompanies').disable();\r\n this.form.get('forCompanies').disable();\r\n }\r\n\r\n await this._loadGLAccount();\r\n this.accountTypes = this.setupAllowedAccountTypes();\r\n // setup form\r\n this._updateFormFromModel();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save(): Promise {\r\n this._updateModelFromForm();\r\n\r\n const busyMsgId = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgId);\r\n\r\n try {\r\n\r\n const promise = this.params.displayMode === DisplayMode.Add ?\r\n this._glAccountService.create(this.glAccount) :\r\n this._glAccountService.update(this.glAccount);\r\n\r\n this.glAccount = await promise;\r\n\r\n // reset form\r\n this._updateFormFromModel();\r\n this.form.markAsPristine();\r\n this.form.markAsUntouched();\r\n\r\n this.result = this.glAccount;\r\n\r\n // close modal window\r\n this._bsModalRef.hide();\r\n }\r\n finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n onAssetClassificationChanged(assetClass: Compliance.AssetClassificationModel): void {\r\n this.form.patchValue({ assetClassificationName: assetClass && assetClass.name });\r\n }\r\n\r\n onIncomeStatementCategoryChanged(incomeStatementCategory: Core.IncomeStatementCategoryModel): void {\r\n this.form.patchValue({ incomeStatementCategoryName: incomeStatementCategory && incomeStatementCategory.name });\r\n }\r\n\r\n async accountTypeChanged(event: any): Promise {\r\n this.currAccountType = this.form.controls.selectedAccountType.value;\r\n if ( !this.currAccountType.validForAccrual && this.form.controls.applicableToAccruals.value )\r\n {\r\n this.form.patchValue({ applicableToAccruals: false });\r\n this.initializeScopeSelections();\r\n }\r\n this.repopulateAccountAccrualTypes();\r\n this.form.patchValue({ incomeStatementCategoryName: '' });\r\n this.form.patchValue({ incomeStatementCategoryId: null });\r\n }\r\n\r\n setupAllowedAccountTypes(): Compliance.GLAccountTypeModel[] {\r\n if (this.currAccountType && this.params?.foundInAssets) {\r\n return this._glAccountService.startResults.glAccountTypes\r\n .filter(x => this.currAccountType.glAccountTypeId === x.glAccountTypeId);\r\n }\r\n if (this.params?.foundInIncomeStatements) {\r\n return this._glAccountService.startResults.glAccountTypes\r\n .filter(x => x.glAccountTypeId === Compliance.GLAccountTypeEnum.Revenue\r\n || x.glAccountTypeId === Compliance.GLAccountTypeEnum.Expense\r\n || x.glAccountTypeId === Compliance.GLAccountTypeEnum.Reporting);\r\n }\r\n return this._glAccountService.startResults.glAccountTypes;\r\n }\r\n\r\n switchApplicableToAccruals(event: any): void {\r\n this.repopulateAccountAccrualTypes();\r\n this.initializeScopeSelections();\r\n\r\n if(!this.form.controls.applicableToAccruals.value) {\r\n this.form.patchValue({ payableIncludesPrepaid: false });\r\n }\r\n }\r\n\r\n accountAccrualTypeChanged(): void {\r\n if (this.form.controls.selectedAccountAccrualType.value.glAccountAccrualTypeId !== this.PropertyTaxPayableType) {\r\n this.form.patchValue({ payableIncludesPrepaid: false });\r\n }\r\n }\r\n\r\n get showAssetClassification(): boolean {\r\n return this.currAccountType && this.currAccountType.glAccountTypeId === Compliance.GLAccountTypeEnum.Asset;\r\n }\r\n\r\n get showIncomeStatementCategory(): boolean {\r\n const allowedAccountTypes = [\r\n Compliance.GLAccountTypeEnum.Expense,\r\n Compliance.GLAccountTypeEnum.Revenue,\r\n Compliance.GLAccountTypeEnum.Reporting];\r\n return this.currAccountType\r\n && allowedAccountTypes.indexOf(this.currAccountType.glAccountTypeId) > -1;\r\n }\r\n\r\n private initializeScopeSelections(): void {\r\n // Switching to Applicable/Non-applicable to Accruals.\r\n // Select all Property Types and Payment Types.\r\n const arrPropTypeSel = this.propertyTypes.map(t => !!(this.accrualsFeatureEnabled && this.form.controls.applicableToAccruals.value));\r\n const arrPmtTypeSel = this.paymentTypes.map(t => !!(this.accrualsFeatureEnabled && this.form.controls.applicableToAccruals.value));\r\n\r\n // Always initialze to For All Companies.\r\n this.form.patchValue({\r\n forPropertyTypes: arrPropTypeSel,\r\n forPaymentTypes: arrPmtTypeSel,\r\n forAllCompanies: true,\r\n forCompanies: []\r\n });\r\n }\r\n\r\n private repopulateAccountAccrualTypes(): void {\r\n const repopulate = (this.accrualsFeatureEnabled && this.form.controls.applicableToAccruals.value);\r\n\r\n this.currAccountAccrualTypes = repopulate ? this.accountAccrualTypes.filter(x => x.glAccountTypeId === this.currAccountType.glAccountTypeId) : [];\r\n this.form.patchValue({ selectedAccountAccrualType: repopulate ? this.currAccountAccrualTypes[0] : null });\r\n }\r\n\r\n private async _loadGLAccount(): Promise {\r\n if (this.params.displayMode === DisplayMode.Add) {\r\n // Default to adding a new non-Accrual Asset G/L Account.\r\n this.currAccountType = this._glAccountService.startResults.glAccountTypes.find(at => at.glAccountTypeId === Compliance.GLAccountTypeEnum.Asset);\r\n this.currAccountAccrualTypes = [];\r\n\r\n this.glAccount = {\r\n glAccountId: 0,\r\n companyId: this.params.companyId,\r\n accountNumber: null,\r\n accountName: null,\r\n assetClassificationId: null,\r\n assetClassification: null,\r\n description: null,\r\n accountType: this.currAccountType.glAccountTypeId,\r\n accountTypeName: this.currAccountType.name,\r\n applicableToAccruals: false,\r\n payableIncludesPrepaid: false,\r\n accountAccrualType: null,\r\n forAllCompanies: true,\r\n forPropertyTypes: [],\r\n forPaymentTypes: [],\r\n forCompanies: [],\r\n incomeStatementCategoryName: null,\r\n incomeStatementCategoryId: null\r\n } as Compliance.GLAccountModel;\r\n\r\n return;\r\n }\r\n\r\n const busyMsgId = 'loading';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsgId);\r\n\r\n try {\r\n this.glAccount = await this._glAccountService.get(this.params.glAccountId);\r\n }\r\n finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n\r\n this.currAccountType = this._glAccountService.startResults.glAccountTypes.find(at => at.glAccountTypeId == this.glAccount.accountType);\r\n }\r\n\r\n private _updateFormFromModel(): void {\r\n let arrPropTypeSel = this.propertyTypes.map(t => {\r\n return this.accrualsFeatureEnabled &&\r\n (this.glAccount.forPropertyTypes.length > 0) &&\r\n this.glAccount.forPropertyTypes.some(x => x.propertyTypeId === t.propertyTypeId);\r\n });\r\n let arrPmtTypeSel = this.paymentTypes.map(t => {\r\n return this.accrualsFeatureEnabled &&\r\n (this.glAccount.forPaymentTypes.length > 0) &&\r\n this.glAccount.forPaymentTypes.some(x => x.paymentTypeId === t.paymentTypeId);\r\n });\r\n\r\n let arrCompanySel: number[] = [];\r\n if ( this.accrualsFeatureEnabled )\r\n {\r\n if ( !this.isTopLevelCompany )\r\n {\r\n // G/L Account is for a Subsidiary Company.\r\n // We don't provide Companies selection, and we default\r\n // to Specific companies with just the Subsidiary selected.\r\n if ( this.glAccount.forAllCompanies )\r\n this.glAccount.forAllCompanies = false;\r\n if ( this.glAccount.forCompanies.length != 1 )\r\n {\r\n this.glAccount.forCompanies = [{\r\n glAccountId: this.glAccount.glAccountId,\r\n companyId: this._glAccountService.companyId\r\n }];\r\n }\r\n arrCompanySel.push(this._glAccountService.companyId);\r\n }\r\n else\r\n {\r\n // Select the stored companies that are valid for selection.\r\n arrCompanySel = this.accrualScopeCompanies\r\n .filter((c) => this.glAccount.forCompanies.some(x => x.companyId === c.id))\r\n .map((fc) => fc.id);\r\n }\r\n }\r\n else\r\n {\r\n // Accruals Feature not enabled\r\n this.glAccount.applicableToAccruals = false;\r\n this.glAccount.forAllCompanies = true;\r\n }\r\n this.form.patchValue({\r\n accountNumber: this.glAccount.accountNumber,\r\n accountName: this.glAccount.accountName,\r\n description: this.glAccount.description,\r\n assetClassificationId: this.glAccount.assetClassificationId,\r\n assetClassificationName: this.glAccount.assetClassification,\r\n selectedAccountType: this.currAccountType,\r\n applicableToAccruals: this.glAccount.applicableToAccruals,\r\n payableIncludesPrepaid: this.glAccount.payableIncludesPrepaid,\r\n selectedAccountAccrualType: null,\r\n forAllCompanies: this.glAccount.forAllCompanies,\r\n forPropertyTypes: arrPropTypeSel,\r\n forPaymentTypes: arrPmtTypeSel,\r\n forCompanies: arrCompanySel,\r\n incomeStatementCategoryName: this.glAccount.incomeStatementCategoryName,\r\n incomeStatementCategoryId: this.glAccount.incomeStatementCategoryId,\r\n isValidated: this.glAccount.isValidated\r\n });\r\n\r\n this.repopulateAccountAccrualTypes();\r\n this.form.patchValue({ selectedAccountAccrualType: this.glAccount.accountAccrualType\r\n ? this.currAccountAccrualTypes.find(x => x.glAccountAccrualTypeId === this.glAccount.accountAccrualType)\r\n : null });\r\n }\r\n\r\n private _updateModelFromForm(): void {\r\n this.glAccount.glAccountId = !!this.params.glAccountId ? this.params.glAccountId : 0;\r\n this.glAccount.accountNumber = this.form.get('accountNumber').value;\r\n this.glAccount.accountName = this.form.get('accountName').value;\r\n this.glAccount.description = this.form.get('description').value;\r\n this.glAccount.accountType = this.form.get('selectedAccountType').value.glAccountTypeId;\r\n this.glAccount.applicableToAccruals = this.form.get('applicableToAccruals').value;\r\n this.glAccount.payableIncludesPrepaid = this.form.get('payableIncludesPrepaid').value;\r\n this.glAccount.accountAccrualType = this.form.get('selectedAccountAccrualType').value ? this.form.get('selectedAccountAccrualType').value.glAccountAccrualTypeId : null;\r\n this.glAccount.forAllCompanies = this.form.get('forAllCompanies').value;\r\n this.glAccount.forPropertyTypes = [];\r\n this.glAccount.forPaymentTypes = [];\r\n this.glAccount.forCompanies = [];\r\n this.glAccount.isValidated = this.form.get('isValidated').value;\r\n\r\n if (this.currAccountType.glAccountTypeId === Compliance.GLAccountTypeEnum.Asset){\r\n this.glAccount.assetClassificationId = this.form.get('assetClassificationId').value;\r\n this.glAccount.assetClassification = this.form.get('assetClassificationName').value;\r\n }\r\n\r\n if (this.currAccountType.glAccountTypeId === Compliance.GLAccountTypeEnum.Expense ||\r\n this.currAccountType.glAccountTypeId === Compliance.GLAccountTypeEnum.Revenue ||\r\n this.currAccountType.glAccountTypeId === Compliance.GLAccountTypeEnum.Reporting) {\r\n this.glAccount.incomeStatementCategoryId = this.form.get('incomeStatementCategoryId').value;\r\n this.glAccount.incomeStatementCategoryName = this.form.get('incomeStatementCategoryName').value;\r\n }\r\n\r\n if ( this.accrualsFeatureEnabled && this.glAccount.applicableToAccruals )\r\n {\r\n this.fPropTypes.controls.forEach((ft, ndx) => {\r\n if ( ft.value )\r\n {\r\n this.glAccount.forPropertyTypes.push({\r\n glAccountId: this.glAccount.glAccountId,\r\n propertyTypeId: this.propertyTypes[ndx].propertyTypeId\r\n });\r\n }\r\n });\r\n\r\n this.fPmtTypes.controls.forEach((ft, ndx) => {\r\n if ( ft.value )\r\n {\r\n this.glAccount.forPaymentTypes.push({\r\n glAccountId: this.glAccount.glAccountId,\r\n paymentTypeId: this.paymentTypes[ndx].paymentTypeId\r\n });\r\n }\r\n });\r\n\r\n if ( !this.glAccount.forAllCompanies && this.form.get('forCompanies').value.length > 0 )\r\n {\r\n this.form.get('forCompanies').value.forEach((cid) => {\r\n this.glAccount.forCompanies.push({\r\n glAccountId: this.glAccount.glAccountId,\r\n companyId: cid\r\n });\r\n });\r\n }\r\n }\r\n }\r\n}\r\n","\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'gl-account-bulk-update-action',\r\n templateUrl: './glAccountBulkUpdateAction.component.html',\r\n styles: ['select {width:120px}']\r\n})\r\nexport class GLAccountBulkUpdateActionComponent implements OnInit{\r\n constructor(\r\n ){\r\n // this.possibleActions = [\r\n // { name: 'No Change', value: Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange },\r\n // { name: 'Change To', value: Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo },\r\n // { name: 'Set to Blank', value: Compliance.GLAccountBulkUpdateFieldActionEnum.SetToBlank }\r\n // ];\r\n }\r\n\r\n @Input() fieldAction: Compliance.GLAccountBulkUpdateFieldActionEnum;\r\n @Input() requiredField: boolean;\r\n @Input() disabled: boolean;\r\n @Input() possibleActions: Compliance.NameValuePair[] = [];\r\n\r\n @Output() fieldActionChange = new EventEmitter();\r\n\r\n selectedAction: Compliance.GLAccountBulkUpdateFieldActionEnum = null;\r\n\r\n ngOnInit(): void {\r\n if (this.requiredField){\r\n this.possibleActions = this.possibleActions.filter(i => i.value !== Compliance.GLAccountBulkUpdateFieldActionEnum.SetToBlank);\r\n }\r\n this.selectedAction = this.fieldAction;\r\n }\r\n\r\n fieldActionChanged(action: Compliance.GLAccountBulkUpdateFieldActionEnum) : void{\r\n this.selectedAction = action;\r\n this.fieldActionChange.next(action);\r\n }\r\n\r\n isSelected(action: Compliance.ReportingAssetBulkUpdateFieldActionEnum): boolean{\r\n return action === Compliance.ReportingAssetBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Description\r\n \r\n\r\n \r\n \r\n \r\n
Asset Classification\r\n \r\n \r\n
\r\n \r\n\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n","import {Component, OnInit} from '@angular/core';\r\nimport {BusyIndicatorMessageManager} from '../../../../Busy-Indicator/busyIndicatorMessageManager'\r\nimport {BusyIndicatorService} from '../../../../Busy-Indicator';\r\nimport {MessageModalService} from '../../../../UI-Lib/Message-Box/messageModal.service';\r\nimport {BsModalRef} from 'ngx-bootstrap/modal';\r\nimport {IWeissmanModalComponent} from '../../../WeissmanModalService';\r\nimport {GLAccountService} from '../../glAccount.service';\r\nimport {GLAccountBulkUpdateChangedFields} from \"./glAccountBulkUpdateExports\";\r\nimport GLAccountBulkUpdateFieldActionEnum = Compliance.GLAccountBulkUpdateFieldActionEnum;\r\n\r\nexport interface GLAccountBulkUpdateParams {\r\n companyId: number;\r\n selection: Compliance.SelectedRowsModel;\r\n selectedCount: number;\r\n glAccountListLastModifiedTimestamp: Date;\r\n};\r\n\r\n@Component({\r\n selector: 'gl-account-bulk-update-modal',\r\n templateUrl: './glAccountBulkUpdate.component.html',\r\n})\r\nexport class GLAccountBulkUpdateComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private _busyIndicatorService: BusyIndicatorService,\r\n private _bsModalRef: BsModalRef,\r\n private _messageModalService: MessageModalService,\r\n private _glAccountService: GLAccountService\r\n ) { }\r\n\r\n params: GLAccountBulkUpdateParams;\r\n result: GLAccountBulkUpdateChangedFields;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n glAccountBulkUpdateModel: Compliance.GLAccountBulkUpdateModel = { } as Compliance.GLAccountBulkUpdateModel;\r\n assetClassificationId: number;\r\n\r\n possibleActions = [\r\n { name: 'No Change', value: Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange },\r\n { name: 'Change To', value: Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo },\r\n { name: 'Set to Blank', value: Compliance.GLAccountBulkUpdateFieldActionEnum.SetToBlank },\r\n ];\r\n\r\n fieldActionInitValue = Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange;\r\n\r\n private _newClassificationName: string;\r\n\r\n newClassification(value: Compliance.AssetClassificationModel) {\r\n this._newClassificationName = value && value.name;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this.glAccountBulkUpdateModel.selectedRows = this.params.selection;\r\n this.glAccountBulkUpdateModel.lastModifiedTimestamp = this.params.glAccountListLastModifiedTimestamp;\r\n this.glAccountBulkUpdateModel.descriptionAction = GLAccountBulkUpdateFieldActionEnum.NoChange;\r\n this.glAccountBulkUpdateModel.classificationIdAction = GLAccountBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n\r\n isFormValid(): boolean {\r\n return (this.glAccountBulkUpdateModel.classificationId\r\n && this.glAccountBulkUpdateModel.classificationIdAction === Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo\r\n || this.glAccountBulkUpdateModel.classificationIdAction === Compliance.GLAccountBulkUpdateFieldActionEnum.SetToBlank)\r\n || (this.glAccountBulkUpdateModel.description\r\n && this.glAccountBulkUpdateModel.description !== ''\r\n && this.glAccountBulkUpdateModel.descriptionAction === Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo\r\n || this.glAccountBulkUpdateModel.descriptionAction === Compliance.GLAccountBulkUpdateFieldActionEnum.SetToBlank);\r\n }\r\n\r\n async save(force: boolean = false): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating' });\r\n let confirmMessage: string = '';\r\n\r\n try {\r\n this.glAccountBulkUpdateModel.force = force;\r\n\r\n await this._glAccountService.updateBulk(this.params.companyId, this.glAccountBulkUpdateModel);\r\n\r\n this.result = {\r\n selectedRows: this.glAccountBulkUpdateModel.selectedRows\r\n } as GLAccountBulkUpdateChangedFields;\r\n\r\n if (this.glAccountBulkUpdateModel.classificationIdAction === Compliance.GLAccountBulkUpdateFieldActionEnum.SetToBlank){\r\n this.result.assetClassification = \"\";\r\n this.result.assetClassificationId = null;\r\n } else if (this.glAccountBulkUpdateModel.classificationIdAction === Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo){\r\n this.result.assetClassification = this._newClassificationName;\r\n this.result.assetClassificationId = this.glAccountBulkUpdateModel.classificationId;\r\n }\r\n\r\n if (this.glAccountBulkUpdateModel.descriptionAction === Compliance.GLAccountBulkUpdateFieldActionEnum.SetToBlank){\r\n this.result.description = null;\r\n } else if (this.glAccountBulkUpdateModel.descriptionAction === Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo){\r\n this.result.description = this.glAccountBulkUpdateModel.description;\r\n }\r\n\r\n this._bsModalRef.hide();\r\n return Promise.resolve();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n confirmMessage = e2.error.message;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n confirmMessage,\r\n 'Confirm Update');\r\n } catch (e3) {\r\n return Promise.resolve();\r\n }\r\n\r\n // force\r\n await this.save(true);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n isDisabled(action: Compliance.GLAccountBulkUpdateFieldActionEnum){\r\n return action !== Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo;\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const GL_ACCOUNT_LIST_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'gl-account-list.new-gl-account',\r\n tooltipText: 'New G/L Account'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.bulk-delete-found-in-accruals',\r\n tooltipText: 'Cannot bulk edit GL accounts found in accruals.'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.bulk-delete-found-in-income-statements',\r\n tooltipText: 'Cannot bulk edit GL accounts found in income statements. Account has been validated.'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.bulk-delete-applicable-to-accruals',\r\n tooltipText: 'Cannot bulk edit GL accounts applicable to accruals.'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.bulk-delete-nothing-selected',\r\n tooltipText: 'Must select more than record to bulk edit.'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.bulk-delete-mixed-types',\r\n tooltipText: 'Cannot mix I/S GL accounts with other types of GL accounts for bulk edit.'\r\n },\r\n {\r\n helpContentId: 'ag-grid-tool-panel.bulk-delete-mixed-types-income-statements',\r\n tooltipText: 'Cannot mix I/S GL accounts types for bulk edit.'\r\n }\r\n];\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Account Type\r\n \r\n \r\n \r\n \r\n
Income Statement Category\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n GL accounts found in an income statement will not be updated\r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnDestroy, OnInit, ViewChild, ViewEncapsulation } from '@angular/core';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport { MessageModalService } from '../../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { GLAccountService } from '../../glAccount.service';\r\nimport { AbstractControl, UntypedFormControl, UntypedFormGroup } from '@angular/forms';\r\nimport { Subscription } from 'rxjs';\r\nimport { GLAccountBulkUpdateIncomeStatementTypesChangedFields } from './glAccountBulkUpdateExports';\r\nimport {\r\n IncomeStatementCategorySelectorComponent\r\n} from '../../../../Valuation/Income-Statement/Income-Statement-Category-Selector/incomeStatementCategorySelector.component';\r\n\r\nexport interface GLAccountBulkUpdateIncomeStatementTypesParams {\r\n companyId: number;\r\n selectedCount: number;\r\n glAccountListLastModifiedTimestamp: Date;\r\n selection: Compliance.SelectedRowsModel;\r\n selectionSummary: Compliance.GLAccountBulkSelectionSummaryResponse;\r\n}\r\n\r\ninterface GLAccountIncomeStatementTypesBulkFormValues {\r\n accountType: Compliance.GLAccountTypeModel,\r\n accountTypeAction: Compliance.GLAccountBulkUpdateFieldActionEnum,\r\n incomeStatementCategory: Core.IncomeStatementCategoryModel,\r\n incomeStatementCategoryAction: Compliance.GLAccountBulkUpdateFieldActionEnum,\r\n isValidated: boolean\r\n}\r\n\r\n@Component({\r\n selector: 'gl-account-bulk-update-income-statement-types-modal',\r\n templateUrl: './glAccountBulkUpdateIncomeStatementTypes.component.html',\r\n styleUrls: ['./glAccountBulkUpdateIncomeStatementTypes.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class GLAccountBulkUpdateIncomeStatementTypesComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n\r\n constructor(\r\n private _busyIndicatorService: BusyIndicatorService,\r\n private _bsModalRef: BsModalRef,\r\n private _messageModalService: MessageModalService,\r\n private _glAccountService: GLAccountService\r\n ) {\r\n this.bulkUpdateForm = new UntypedFormGroup({\r\n accountType: new UntypedFormControl({ value: {}, disabled: true }),\r\n accountTypeAction: new UntypedFormControl(Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange),\r\n incomeStatementCategory: new UntypedFormControl(null),\r\n incomeStatementCategoryAction: new UntypedFormControl(Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange),\r\n isValidated: new UntypedFormControl(false)\r\n });\r\n }\r\n\r\n @ViewChild('incomeStatementCategorySelector') incomeStatementCategorySelector: IncomeStatementCategorySelectorComponent;\r\n\r\n params: GLAccountBulkUpdateIncomeStatementTypesParams;\r\n result: GLAccountBulkUpdateIncomeStatementTypesChangedFields;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n bulkUpdateModel: Compliance.GLAccountBulkUpdateIncomeStatementTypesModel = {\r\n accountTypeId: null,\r\n accountTypeIdAction: Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange,\r\n incomeStatementCategoryId: null,\r\n incomeStatementCategoryIdAction: Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange\r\n } as Compliance.GLAccountBulkUpdateIncomeStatementTypesModel;\r\n\r\n accountTypes: Compliance.GLAccountTypeModel[] = this.setupAllowedAccountTypes();\r\n bulkUpdateForm: UntypedFormGroup;\r\n\r\n get showIncomeStatementCategoryChoices(): boolean { return !this.incomeStatementCategoryControl.disabled;}\r\n\r\n get incomeStatementCategoryActionControl(): AbstractControl {\r\n return this.bulkUpdateForm.get('incomeStatementCategoryAction');\r\n }\r\n\r\n accountTypePossibleActions: Compliance.NameValuePair[] = [\r\n { name: 'No Change', value: Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange },\r\n { name: 'Change To', value: Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo }\r\n ];\r\n\r\n categoryPossibleActions: Compliance.NameValuePair[] = [\r\n { name: 'No Change', value: Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange },\r\n { name: 'Set to Blank', value: Compliance.GLAccountBulkUpdateFieldActionEnum.SetToBlank },\r\n { name: 'Change To', value: Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo }\r\n ];\r\n\r\n accountTypeActionInitValue = Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange;\r\n categoryActionInitValue = Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange;\r\n\r\n private internalSubs = new Subscription();\r\n private originalAccountTypeId: Compliance.GLAccountTypeEnum;\r\n\r\n async ngOnInit(): Promise {\r\n if (this.params.selectionSummary.asset > 0) throw 'We don\\'t update assets here';\r\n if (this.params.selectionSummary.equity > 0) throw 'We don\\'t update equity here';\r\n if (this.params.selectionSummary.liability > 0) throw 'We don\\'t update liability here';\r\n\r\n this.bulkUpdateModel.selectedRows = this.params.selection;\r\n this.bulkUpdateModel.lastModifiedTimestamp = this.params.glAccountListLastModifiedTimestamp;\r\n\r\n this.internalSubs.add(\r\n this.bulkUpdateForm.valueChanges\r\n .subscribe(() => {\r\n const formValues = this.bulkUpdateForm.getRawValue() as GLAccountIncomeStatementTypesBulkFormValues;\r\n if (!!formValues) {\r\n this.bulkUpdateModel.accountTypeId = !!formValues.accountType ? formValues.accountType.glAccountTypeId : null;\r\n this.bulkUpdateModel.accountTypeIdAction = formValues.accountTypeAction;\r\n this.bulkUpdateModel.incomeStatementCategoryId = !!formValues.incomeStatementCategory ? formValues.incomeStatementCategory.incomeStatementCategoryId : null;\r\n this.bulkUpdateModel.incomeStatementCategoryIdAction = formValues.incomeStatementCategoryAction;\r\n this.bulkUpdateModel.validate = formValues.isValidated\r\n }\r\n })\r\n );\r\n\r\n if (this.params.selectionSummary.validated.length !== 0) {\r\n this.bulkUpdateForm.get('isValidated').disable();\r\n this.bulkUpdateForm.get('isValidated').setValue(true);\r\n }\r\n }\r\n\r\n private get accountTypeControl(): AbstractControl {\r\n return this.bulkUpdateForm.get('accountType');\r\n }\r\n\r\n private get incomeStatementCategoryControl(): AbstractControl {\r\n return this.bulkUpdateForm.get('incomeStatementCategory');\r\n }\r\n\r\n ngOnDestroy(): void {\r\n if (!!this.internalSubs) {\r\n this.internalSubs.unsubscribe();\r\n }\r\n }\r\n\r\n setupAllowedAccountTypes(): Compliance.GLAccountTypeModel[] {\r\n const realTypes = this._glAccountService.startResults.glAccountTypes\r\n .filter(x =>\r\n x.glAccountTypeId === Compliance.GLAccountTypeEnum.Reporting ||\r\n x.glAccountTypeId === Compliance.GLAccountTypeEnum.Expense ||\r\n x.glAccountTypeId === Compliance.GLAccountTypeEnum.Revenue);\r\n return [{\r\n name: '',\r\n glAccountTypeId: null\r\n } as Compliance.GLAccountTypeModel, ...realTypes];\r\n }\r\n\r\n onIncomeStatementCategoryChanged(incomeStatementCategory: Core.IncomeStatementCategoryModel): void {\r\n this.bulkUpdateForm.patchValue({ incomeStatementCategory: incomeStatementCategory });\r\n }\r\n\r\n accountTypeActionChanged(event: Compliance.GLAccountBulkUpdateFieldActionEnum): void {\r\n if (event === Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo) {\r\n this.accountTypeControl.enable();\r\n } else {\r\n this.accountTypeControl.disable();\r\n }\r\n this.bulkUpdateForm.patchValue({ accountTypeAction: event });\r\n }\r\n\r\n incomeStatementCategoryActionChanged(event: Compliance.GLAccountBulkUpdateFieldActionEnum): void {\r\n this.bulkUpdateForm.patchValue({ incomeStatementCategoryAction: event });\r\n }\r\n\r\n isFormValid(): boolean {\r\n const accountTypeIsChanging = this.bulkUpdateModel.accountTypeId !== this.originalAccountTypeId;\r\n const accountTypeNoChangeIsValid = this.bulkUpdateModel.accountTypeIdAction === Compliance.GLAccountBulkUpdateFieldActionEnum.NoChange && !accountTypeIsChanging;\r\n const accountTypeChangeIsValid = this.bulkUpdateModel.accountTypeIdAction === Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo && accountTypeIsChanging;\r\n\r\n const categoryIsSet = !!this.bulkUpdateModel.incomeStatementCategoryId;\r\n const categorySetToBlankIsValid = this.bulkUpdateModel.incomeStatementCategoryIdAction === Compliance.GLAccountBulkUpdateFieldActionEnum.SetToBlank && !categoryIsSet;\r\n const categoryChangeToIsValid = this.bulkUpdateModel.incomeStatementCategoryIdAction === Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo && categoryIsSet;\r\n\r\n const accountTypeFieldValuesAreValid = accountTypeChangeIsValid || accountTypeNoChangeIsValid;\r\n const categoryFieldValuesAreValid = categoryChangeToIsValid || categorySetToBlankIsValid;\r\n\r\n return accountTypeFieldValuesAreValid && categoryFieldValuesAreValid || this.bulkUpdateModel.validate;\r\n }\r\n\r\n async save(force: boolean = false): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating' });\r\n let confirmMessage: string = '';\r\n\r\n try {\r\n this.bulkUpdateModel.force = force;\r\n\r\n await this._glAccountService.updateBulkIncomeStatementTypes(this.params.companyId, this.bulkUpdateModel);\r\n\r\n this.result = {\r\n selectedRows: this.bulkUpdateModel.selectedRows\r\n } as GLAccountBulkUpdateIncomeStatementTypesChangedFields;\r\n\r\n this.result.accountTypeId = this.bulkUpdateModel.accountTypeId;\r\n this.result.incomeStatementCategoryId = this.bulkUpdateModel.incomeStatementCategoryId;\r\n\r\n this._bsModalRef.hide();\r\n return Promise.resolve();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n confirmMessage = e2.error.message;\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n confirmMessage,\r\n 'Confirm Update');\r\n } catch (e3) {\r\n return Promise.resolve();\r\n }\r\n\r\n // force\r\n await this.save(true);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n isDisabled(action: Compliance.GLAccountBulkUpdateFieldActionEnum): boolean {\r\n return action !== Compliance.GLAccountBulkUpdateFieldActionEnum.ChangeTo;\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Chart of Accounts\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { GLAccountListAgGridDataSource } from './agGridDataSource';\r\nimport {\r\n DisplayMode,\r\n GLAccountDetailsComponent,\r\n GLAccountDetailsParams\r\n} from '../GL-Account-Details/glAccountDetails.component';\r\nimport { GLAccountRepository } from '../../Repositories';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../AgGrid';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../AgGrid/MultiSelectTracker';\r\nimport { BehaviorSubject, from, of, Subscription } from 'rxjs';\r\nimport {\r\n GLAccountBulkUpdateComponent,\r\n GLAccountBulkUpdateParams\r\n} from './GL-Account-Bulk-Update/glAccountBulkUpdate.component';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../AgGrid/ToolPanel/models';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { GLAccountService } from '../glAccount.service';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { GL_ACCOUNT_LIST_HELP } from './glAccountList.component.help';\r\nimport { catchError, switchMap, tap } from 'rxjs/operators';\r\nimport { BulkEditButtonOptions } from '../../AgGrid/ToolPanel/agGridToolPanel.component';\r\nimport {\r\n GLAccountBulkUpdateIncomeStatementTypesComponent,\r\n GLAccountBulkUpdateIncomeStatementTypesParams\r\n} from './GL-Account-Bulk-Update/glAccountBulkUpdateIncomeStatementTypes.component';\r\nimport {\r\n AgGridActionCellRendererComponent,\r\n AgGridActionCellRendererParams\r\n} from '../../AgGrid/CellRenderers/agGridActionCellRenderer.component';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport { WeissmanDateFormat } from '../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\n\r\n\r\n@Component({\r\n selector: 'gl-account-list',\r\n templateUrl: './glAccountList.component.html',\r\n styleUrls: ['./glAccountList.component.scss']\r\n})\r\nexport class GLAccountListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _glAccountRepository: GLAccountRepository,\r\n private readonly _glAccountService: GLAccountService,\r\n private readonly _helpService: HelpService\r\n ) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: GLAccountListAgGridDataSource;\r\n private _gridMultiSelectSub: Subscription;\r\n private selectionSummary: Compliance.GLAccountBulkSelectionSummaryResponse;\r\n\r\n companyId: number;\r\n breadcrumbs: BreadCrumb[] = [];\r\n isInitialized: boolean = false;\r\n canEdit: boolean = false;\r\n gridId: System.Guid = 'EB1D7E96-03FD-42C8-B5FB-0273E7BAC586';\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.GLAccountModel).glAccountId)\r\n }\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[]): Promise => {\r\n const searchParams = this._gridDataSource.getSearchModelWithoutPagination();\r\n\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: this._gridDataSource.totalRows\r\n };\r\n\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n if (!selectedRowsModel.selectAllRows && selectedRowsModel.selectedRows.length === 0) {\r\n selectedRowsModel.selectAllRows = true;\r\n }\r\n\r\n const exportModel: Compliance.GLAccountExportModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn,\r\n selectedRows: selectedRowsModel\r\n };\r\n\r\n const longRunningProcessId = await this._glAccountService.startExport(this.companyId, exportModel);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportGLAccounts };\r\n },\r\n canCancel: true\r\n };\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(GL_ACCOUNT_LIST_HELP);\r\n\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Loading'});\r\n\r\n try {\r\n await this._glAccountService.start(this.companyId);\r\n\r\n if (!this._glAccountService.canReadCompany) {\r\n this._routerService.go('unauthorizedAccess', {});\r\n return Promise.resolve();\r\n }\r\n\r\n this.canEdit = this._glAccountService.canWriteCompany;\r\n\r\n this.breadcrumbs.push({\r\n name: this._glAccountService.companyName,\r\n target: 'company',\r\n options: {companyId: this._glAccountService.companyId}\r\n });\r\n\r\n this.isInitialized = true;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n ngOnDestroy() {\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n this._glAccountService.stop();\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n // notify the bulk update button (on the column tool panel) every time the grid selection changes\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$\r\n .pipe(\r\n // does this need to be debounced?\r\n tap(() => this.isBulkUpdateVisible$.next(BulkEditButtonOptions.Create({\r\n showLoading: true,\r\n show: true\r\n }))),\r\n switchMap((rows) => this.getSelectionSummary()\r\n .pipe(catchError(() => {\r\n return of(null);\r\n }))\r\n ),\r\n tap((selectionSummary: Compliance.GLAccountBulkSelectionSummaryResponse) => this.selectionSummary = selectionSummary)\r\n )\r\n .subscribe(\r\n (selectionSummary) => {\r\n const isBulkUpdateVisible = this.canBulkUpdate(selectionSummary);\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'glAccountId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n lockVisible: true,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n resizable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {tracker: this.gridTracker} as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {tracker: this.gridTracker} as AgGridMultiSelectRendererParams,\r\n },\r\n {\r\n headerName: 'G/L Account Number',\r\n field: 'accountNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'G/L Account Name',\r\n field: 'accountName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'I/S Category',\r\n field: 'incomeStatementCategoryName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Asset Class',\r\n field: 'assetClassification',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Account Type',\r\n field: 'accountTypeName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Found in Assets',\r\n field: 'foundInAssets',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n hide: true,\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n } else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return null;\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Found in Accruals',\r\n field: 'foundInAccruals',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n hide: true,\r\n suppressColumnsToolPanel: false,\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n } else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return null;\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Found in I/S',\r\n field: 'foundInIncomeStatements',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n suppressColumnsToolPanel: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n } else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return null;\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Created Date',\r\n field: 'createDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n suppressColumnsToolPanel: false,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => WeissmanDateFormat(params.value, false)\r\n },\r\n {\r\n headerName: 'Validated By',\r\n field: 'validatedBy',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n suppressColumnsToolPanel: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Validated Date',\r\n field: 'validatedDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n suppressColumnsToolPanel: false,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => WeissmanDateFormat(params.value, true)\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: AgGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n buttonConfigs: [\r\n {\r\n iconClass: 'fa-pencil',\r\n onClick: this._edit.bind(this),\r\n isShown: () => true,\r\n helpContentId: 'app.edit'\r\n },\r\n {\r\n iconClass: 'fa-trash',\r\n onClick: this._delete.bind(this),\r\n isShown: this._canDelete.bind(this),\r\n buttonClass: 'btn-primary btn-danger',\r\n helpContentId: 'app.delete'\r\n }\r\n ]\r\n } as AgGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'accountNumber',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n private canBulkUpdate(selectionSummary: Compliance.GLAccountBulkSelectionSummaryResponse) {\r\n if (!this.canEdit) {\r\n return false;\r\n }\r\n\r\n if (!selectionSummary) {\r\n return false;\r\n }\r\n\r\n if (selectionSummary.foundInAccruals > 0) {\r\n return BulkEditButtonOptions.Create({\r\n showLoading: false,\r\n show: true,\r\n disable: true,\r\n toolTipId: 'ag-grid-tool-panel.bulk-delete-found-in-accruals'\r\n });\r\n }\r\n\r\n if (selectionSummary.applicableToAccruals > 0) {\r\n return BulkEditButtonOptions.Create({\r\n showLoading: false,\r\n show: true,\r\n disable: true,\r\n toolTipId: 'ag-grid-tool-panel.bulk-delete-applicable-to-accruals'\r\n });\r\n }\r\n\r\n if (this._isAllSelectedAccountsFoundInISAndValidated(selectionSummary)) {\r\n return BulkEditButtonOptions.Create({\r\n showLoading: false,\r\n show: true,\r\n disable: true,\r\n toolTipId: 'ag-grid-tool-panel.bulk-delete-found-in-income-statements'\r\n });\r\n }\r\n\r\n if (selectionSummary.total < 1) {\r\n return BulkEditButtonOptions.Create({\r\n showLoading: false,\r\n show: true,\r\n disable: true,\r\n toolTipId: 'ag-grid-tool-panel.bulk-delete-nothing-selected'\r\n });\r\n }\r\n\r\n const incomeStatementTypes = selectionSummary.revenue + selectionSummary.reporting + selectionSummary.expense > 0;\r\n const otherTypes = selectionSummary.asset + selectionSummary.equity + selectionSummary.liability > 0;\r\n if (incomeStatementTypes && otherTypes) {\r\n return BulkEditButtonOptions.Create({\r\n showLoading: false,\r\n show: true,\r\n disable: true,\r\n toolTipId: 'ag-grid-tool-panel.bulk-delete-mixed-types'\r\n });\r\n }\r\n\r\n return true;\r\n }\r\n\r\n private showIncomeStatementTypesBulkUpdate() : boolean\r\n {\r\n if (!this.selectionSummary) return false;\r\n if (this.selectionSummary.foundInAccruals > 0) return false;\r\n if (this.selectionSummary.applicableToAccruals > 0) return false;\r\n if (this.selectionSummary.total < 1) return false;\r\n const incomeStatementTypes = this.selectionSummary.revenue + this.selectionSummary.reporting + this.selectionSummary.expense > 0;\r\n if (!incomeStatementTypes) return false;\r\n const otherTypes = this.selectionSummary.asset + this.selectionSummary.equity + this.selectionSummary.liability > 0;\r\n if (incomeStatementTypes && otherTypes) return false;\r\n return true;\r\n }\r\n\r\n private showBulkUpdate() : boolean\r\n {\r\n if (!this.selectionSummary) return false;\r\n if (this.selectionSummary.foundInAccruals > 0) return false;\r\n if (this.selectionSummary.applicableToAccruals > 0) return false;\r\n if (this.selectionSummary.foundInIncomeStatements.length > 0) return false;\r\n if (this.selectionSummary.total < 1) return false;\r\n const incomeStatementTypes = this.selectionSummary.revenue + this.selectionSummary.reporting + this.selectionSummary.expense > 0;\r\n if (incomeStatementTypes) return false;\r\n const otherTypes = this.selectionSummary.asset + this.selectionSummary.equity + this.selectionSummary.liability > 0;\r\n if (incomeStatementTypes && otherTypes) return false;\r\n return true;\r\n }\r\n\r\n private getSelectionSummary() {\r\n if (!this.gridTracker.hasSelectedRows()) {\r\n return of(null as Compliance.GLAccountBulkSelectionSummaryResponse);\r\n }\r\n const searchModel = this._gridDataSource.getSearchModelWithoutPagination();\r\n\r\n searchModel.pagination = {\r\n skip: 0,\r\n take: this._gridDataSource.totalRows\r\n };\r\n\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n if (!selectedRowsModel.selectAllRows && selectedRowsModel.selectedRows.length === 0) {\r\n selectedRowsModel.selectAllRows = true;\r\n }\r\n return from(this._glAccountService.selectionSummary(this.companyId, searchModel, selectedRowsModel));\r\n }\r\n\r\n async bulkUpdate(): Promise {\r\n if (this.showBulkUpdate()) {\r\n const params: GLAccountBulkUpdateParams = {\r\n companyId: this.companyId,\r\n selection: this.gridTracker.getSelectedRowsModel(),\r\n selectedCount: this.gridTracker.getSelectedRowsCount(),\r\n glAccountListLastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp\r\n };\r\n const result = await this._modalService.showAsync(GLAccountBulkUpdateComponent, params, 'modal-lg');\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n }\r\n if (this.showIncomeStatementTypesBulkUpdate()) {\r\n const params: GLAccountBulkUpdateIncomeStatementTypesParams = {\r\n companyId: this.companyId,\r\n selection: this.gridTracker.getSelectedRowsModel(),\r\n selectedCount: this.gridTracker.getSelectedRowsCount(),\r\n glAccountListLastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp,\r\n selectionSummary: this.selectionSummary\r\n };\r\n const result = await this._modalService.showAsync(GLAccountBulkUpdateIncomeStatementTypesComponent, params, 'modal-lg');\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n this._refreshDataSource();\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async add(): Promise {\r\n const params: GLAccountDetailsParams = {\r\n glAccountId: null,\r\n displayMode: DisplayMode.Add,\r\n companyId: this.companyId,\r\n foundInAssets: false,\r\n foundInIncomeStatements: false,\r\n foundInAccruals: false\r\n };\r\n\r\n const result = await this._modalService.showAsync(GLAccountDetailsComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._refreshDataSource();\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n refresh(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n private async _edit(cellParams: AgGridActionCellRendererParams): Promise {\r\n const data = cellParams.data as Compliance.GLAccountModel;\r\n\r\n if (data.foundInIncomeStatements) {\r\n try {\r\n await this._messageModalService.confirm('Any changes made will flow through to all income statements that contain this account. Would you like to continue?');\r\n } catch(err) {\r\n return;\r\n }\r\n }\r\n\r\n const params: GLAccountDetailsParams = {\r\n glAccountId: data.glAccountId,\r\n displayMode: this.canEdit ? DisplayMode.Edit : DisplayMode.View,\r\n companyId: this.companyId,\r\n foundInAssets: data.foundInAssets,\r\n foundInIncomeStatements: data.foundInIncomeStatements,\r\n foundInAccruals: data.foundInAccruals\r\n };\r\n\r\n const result = await this._modalService.showAsync(GLAccountDetailsComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._gridDataSource.updateRow(y => {\r\n const rowModel = y.data as Compliance.GLAccountModel;\r\n return rowModel && rowModel.glAccountId === result.glAccountId;\r\n },\r\n () => {\r\n return Promise.resolve(result);\r\n });\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private async _delete(params: AgGridActionCellRendererParams): Promise {\r\n const glAccount = params.data as Compliance.GLAccountModel;\r\n if (!glAccount) {\r\n return Promise.resolve();\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to delete the G/L Account?',\r\n 'Confirm Delete');\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Deleting G/L Account'});\r\n\r\n try {\r\n await this._glAccountService.delete(glAccount.glAccountId);\r\n this._refreshDataSource();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private _canDelete(params: AgGridActionCellRendererParams): boolean {\r\n if (!(params && this.canEdit)) {\r\n return false;\r\n }\r\n const glAccount = params.data as Compliance.GLAccountModel;\r\n if (!glAccount) {\r\n return false;\r\n }\r\n return !(glAccount.foundInAssets || glAccount.foundInAccruals || glAccount.foundInIncomeStatements);\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this.gridTracker.clear();\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear();\r\n\r\n this._gridDataSource = new GLAccountListAgGridDataSource(\r\n this._gridApi,\r\n this._glAccountRepository,\r\n this.companyId);\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private _isAllSelectedAccountsFoundInISAndValidated(selectionSummary: Compliance.GLAccountBulkSelectionSummaryResponse): boolean{\r\n return selectionSummary.foundInIncomeStatements.length !== 0 &&\r\n selectionSummary.foundInIncomeStatements.length === selectionSummary.validated.length &&\r\n selectionSummary.foundInIncomeStatements.every(x => selectionSummary.validated.indexOf(x) !== -1);\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const LONG_RUNNING_PROCESS_PAGE_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'long-running-process-page.auto-refresh',\r\n tooltipText: 'When checked, the list will automatically refresh when any long-running process status changes.'\r\n }\r\n];\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../AgGrid';\r\nimport { LongRunningProcessRepository } from '../../Repositories';\r\n\r\nexport class LongRunningProcessListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n readonly gridApi: GridApi,\r\n private readonly _longRunningProcessRepository: LongRunningProcessRepository\r\n ) { super(gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'longRunningProcessId', value: Compliance.LongRunningProcessPropertyEnum.LongRunningProcessId },\r\n { name: 'entityId', value: Compliance.LongRunningProcessPropertyEnum.EntityId },\r\n { name: 'hostName', value: Compliance.LongRunningProcessPropertyEnum.HostName },\r\n { name: 'operationName', value: Compliance.LongRunningProcessPropertyEnum.OperationName },\r\n { name: 'operationDisplayName', value: Compliance.LongRunningProcessPropertyEnum.OperationDisplayName },\r\n { name: 'longRunningProcessQueueTypeName', value: Compliance.LongRunningProcessPropertyEnum.LongRunningProcessQueueTypeName },\r\n { name: 'longRunningProcessTypeName', value: Compliance.LongRunningProcessPropertyEnum.LongRunningProcessTypeName },\r\n { name: 'createDate', value: Compliance.LongRunningProcessPropertyEnum.CreateDate },\r\n { name: 'changeDate', value: Compliance.LongRunningProcessPropertyEnum.ChangeDate },\r\n { name: 'start', value: Compliance.LongRunningProcessPropertyEnum.Start },\r\n { name: 'end', value: Compliance.LongRunningProcessPropertyEnum.End },\r\n { name: 'totalMs', value: Compliance.LongRunningProcessPropertyEnum.TotalMs },\r\n { name: 'queueMs', value: Compliance.LongRunningProcessPropertyEnum.QueueMs },\r\n { name: 'msPerRow', value: Compliance.LongRunningProcessPropertyEnum.MsPerRow },\r\n { name: 'error', value: Compliance.LongRunningProcessPropertyEnum.Error },\r\n { name: 'errorGuid', value: Compliance.LongRunningProcessPropertyEnum.ErrorGuid },\r\n { name: 'totalRows', value: Compliance.LongRunningProcessPropertyEnum.TotalRows },\r\n { name: 'statusCode', value: Compliance.LongRunningProcessPropertyEnum.StatusCode },\r\n { name: 'isCanceled', value: Compliance.LongRunningProcessPropertyEnum.IsCanceled },\r\n { name: 'isPaused', value: Compliance.LongRunningProcessPropertyEnum.IsPaused },\r\n { name: 'isAcknowledged', value: Compliance.LongRunningProcessPropertyEnum.IsAcknowledged },\r\n { name: 'createdByName', value: Compliance.LongRunningProcessPropertyEnum.CreatedByName },\r\n { name: 'instanceName', value: Compliance.LongRunningProcessPropertyEnum.InstanceName }\r\n ];\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Compliance.LongRunningProcessSearchModel = {\r\n notAcknowledged: false,\r\n allUsers: true,\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n\r\n const result = await lastValueFrom(this._longRunningProcessRepository.getList(searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Compliance.LongRunningProcessSearchModel = {\r\n notAcknowledged: false,\r\n allUsers: true,\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n\r\n return await lastValueFrom(this._longRunningProcessRepository.getList(searchParams));\r\n }\r\n\r\n getSearchParamsWithoutPagination() : Compliance.LongRunningProcessSearchModel{\r\n this.refreshDataSourceParams();\r\n return {\r\n notAcknowledged: false,\r\n allUsers: true,\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const LONG_RUNNING_PROCESS_LIST_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'long-running-process-list.update-error',\r\n tooltipText: 'Update to error status. Use when a long-running process has terminated abnormally and the status was not updated to error.'\r\n }\r\n];\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface LongRunningProcessListGridActionCellRendererParams extends ICellRendererParams {\r\n updateError: (params: LongRunningProcessListGridActionCellRendererParams) => void;\r\n canUpdateError: (params: LongRunningProcessListGridActionCellRendererParams) => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n ``\r\n})\r\nexport class LongRunningProcessListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: LongRunningProcessListGridActionCellRendererParams;\r\n\r\n agInit(params: LongRunningProcessListGridActionCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n {{ errorLog.json }}\r\n
\r\n
\r\n
\r\n \r\n
\r\n {{ errorLog.exception }}\r\n
\r\n
\r\n
\r\n
\r\n No data.\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { ErrorLogRepository } from '../errorLog.repository';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\nexport interface ErrorLogDetailsParams {\r\n errorLogId: number;\r\n errorLogGuid: string;\r\n}\r\n\r\n@Component({\r\n selector: 'error-log-details',\r\n templateUrl: './errorLogDetails.component.html',\r\n styleUrls: ['./errorLogDetails.component.scss']\r\n})\r\nexport class ErrorLogDetailsComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _errorLogRepository: ErrorLogRepository) { }\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n params: ErrorLogDetailsParams;\r\n result: void;\r\n\r\n errorLog: Core.ErrorLogModel;\r\n\r\n async ngOnInit(): Promise {\r\n\r\n const busyMsgId = 'loading';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsgId);\r\n\r\n try {\r\n if (this.params.errorLogId) {\r\n this.errorLog = await lastValueFrom(this._errorLogRepository.get(this.params.errorLogId));\r\n }\r\n else {\r\n this.errorLog = await lastValueFrom(this._errorLogRepository.getViaGuid(this.params.errorLogGuid));\r\n }\r\n }\r\n finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import {Component} from \"@angular/core\";\r\nimport {ICellRendererAngularComp} from \"ag-grid-angular\";\r\nimport {ICellRendererParams} from \"ag-grid-community\";\r\n\r\nexport interface LongRunningProcessListGridErrorGuidCellRendererParams extends ICellRendererParams {\r\n showErrorDetails: (errorGuid: string) => void;\r\n}\r\n@Component({\r\n selector: 'grid-error-guid-cell',\r\n template:\r\n `{{error}}\r\n {{error}}`\r\n})\r\nexport class LongRunningProcessListGridErrorGuidCellRendererComponent implements ICellRendererAngularComp {\r\n params: LongRunningProcessListGridErrorGuidCellRendererParams;\r\n showLink: boolean;\r\n error: string;\r\n errorGuid: string;\r\n agInit(params: LongRunningProcessListGridErrorGuidCellRendererParams): void {\r\n this.params = params;\r\n this.error = params?.data?.error;\r\n this.errorGuid = params?.data?.errorGuid;\r\n this.showLink = !! this.errorGuid\r\n }\r\n\r\n refresh(params: ICellRendererParams): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy, Input } from '@angular/core';\r\nimport { ColDef, GridApi, GridReadyEvent, GridOptions } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from '../../AgGrid';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../AgGrid/ToolPanel/models';\r\nimport { LongRunningProcessListAgGridDataSource } from './agGridDataSource';\r\nimport { LongRunningProcessRepository } from '../../Repositories';\r\nimport { WeissmanDateTimeFormatPipe } from '../../../UI-Lib/Pipes';\r\nimport { AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker } from '../../AgGrid/MultiSelectTracker';\r\nimport { Subscription, lastValueFrom, Observable, ReplaySubject } from 'rxjs';\r\nimport { LongRunningProcessService } from '../longRunningProcess.service';\r\nimport { WeissmanTimeSpanPipe } from '../../../UI-Lib/Pipes';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { LONG_RUNNING_PROCESS_LIST_HELP } from './longRunningProcessList.component.help';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport {\r\n LongRunningProcessListGridActionCellRendererComponent,\r\n LongRunningProcessListGridActionCellRendererParams\r\n} from './agGridActionCellRenderer.component';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport {\r\n ErrorLogDetailsComponent,\r\n ErrorLogDetailsParams\r\n} from '../../../Diagnostics/Error-Log/Error-Log-Details/errorLogDetails.component';\r\nimport {WeissmanModalService} from '../../WeissmanModalService';\r\nimport {\r\n LongRunningProcessListGridErrorGuidCellRendererComponent, LongRunningProcessListGridErrorGuidCellRendererParams\r\n} from './long-running-process-list-grid-error-guid-cell-renderer.component';\r\n\r\n@Component({\r\n selector: 'long-running-process-list',\r\n templateUrl: './longRunningProcessList.component.html',\r\n styleUrls: ['./longRunningProcessList.component.scss']\r\n})\r\nexport class LongRunningProcessListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _longRunningProcessRepository: LongRunningProcessRepository,\r\n private readonly _dateTimePipe: WeissmanDateTimeFormatPipe,\r\n private readonly _timeSpanPipe: WeissmanTimeSpanPipe,\r\n private readonly _longRunningProcessService: LongRunningProcessService,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _helpService: HelpService,\r\n private readonly _modalService: WeissmanModalService) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: LongRunningProcessListAgGridDataSource;\r\n private _refreshSub: Subscription;\r\n private _statusChangeSub: Subscription;\r\n private _gridInitialized: ReplaySubject;\r\n\r\n @Input() canEdit: boolean;\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridId: System.Guid = '3BF7E5D1-40E4-4E40-93BB-3F3652E90F10';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.LongRunningProcessModel).longRunningProcessId)\r\n }\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[]): Promise => {\r\n const searchParams = this._gridDataSource.getSearchParamsWithoutPagination();\r\n searchParams.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n if (!searchParams.selectedRows.selectAllRows && searchParams.selectedRows.selectedRows.length === 0){\r\n searchParams.selectedRows.selectAllRows = true;\r\n }\r\n const exportModel: Compliance.LongRunningProcessExportModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn\r\n };\r\n const lrp$: Observable = this._longRunningProcessRepository.startLrpListExport(exportModel);\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n const longRunningProcessTypeId = Compliance.LongRunningProcessTypeEnum.ExportLRPList;\r\n return { longRunningProcessId, longRunningProcessTypeId };\r\n },\r\n canCancel: true,\r\n showFileFormatSelection: false\r\n };\r\n\r\n ngOnInit(): void {\r\n this._gridInitialized = new ReplaySubject();\r\n this._helpService.setContent(LONG_RUNNING_PROCESS_LIST_HELP);\r\n\r\n this._statusChangeSub = this._longRunningProcessService.longRunningProcessStatusChange$.subscribe(async (x) => {\r\n if (this._longRunningProcessService.autoRefresh) {\r\n this._refreshDataSource();\r\n } else {\r\n this._gridInitialized.subscribe(async () => {\r\n await this._gridDataSource.updateRow(\r\n y => {\r\n const rowModel = y.data as Compliance.LongRunningProcessModel;\r\n return rowModel && rowModel.longRunningProcessId === x.longRunningProcessId;\r\n },\r\n async () => {\r\n return await this._longRunningProcessService.get(x.longRunningProcessId);\r\n }, true);\r\n });\r\n }\r\n });\r\n\r\n this._refreshSub = this._longRunningProcessService.refresh$.subscribe(() => {\r\n this._refreshDataSource();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._refreshSub && this._refreshSub.unsubscribe();\r\n this._statusChangeSub && this._statusChangeSub.unsubscribe();\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n const columns: ColDef[] = [\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'longRunningProcessId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n },\r\n {\r\n headerName: 'ID',\r\n field: 'longRunningProcessId',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n lockVisible: true,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Status',\r\n field: 'statusCode',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Created By',\r\n field: 'createdByName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Instance',\r\n field: 'instanceName',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Entity ID',\r\n field: 'entityId',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Host Name',\r\n field: 'hostName',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Queue Type',\r\n field: 'longRunningProcessQueueTypeName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Process Type',\r\n field: 'longRunningProcessTypeName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Operation',\r\n field: 'operationDisplayName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Parameters',\r\n field: 'parameters',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Result',\r\n field: 'result',\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Created',\r\n field: 'createDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._dateTimePipe.transform(params.value, true, 'central') : '',\r\n hide: true\r\n },\r\n {\r\n headerName: 'Changed',\r\n field: 'changeDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._dateTimePipe.transform(params.value, true, 'central') : ''\r\n },\r\n {\r\n headerName: 'Start',\r\n field: 'start',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._dateTimePipe.transform(params.value, true, 'central') : ''\r\n },\r\n {\r\n headerName: 'End',\r\n field: 'end',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._dateTimePipe.transform(params.value, true, 'central') : ''\r\n },\r\n {\r\n headerName: 'Queue',\r\n field: 'queueMs',\r\n width: AgGridColumns.numericColumnWidth,\r\n type: 'numericColumn',\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._timeSpanPipe.transform(params.value, 2, 's') : '',\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Process',\r\n field: 'totalMs',\r\n width: AgGridColumns.numericColumnWidth,\r\n type: 'numericColumn',\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._timeSpanPipe.transform(params.value, 2, 's') : '',\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Time/Row',\r\n field: 'msPerRow',\r\n width: AgGridColumns.numericColumnWidth,\r\n type: 'numericColumn',\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => params.value || params.value === 0 ? this._timeSpanPipe.transform(params.value, 2, 's') : '',\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: '# Rows',\r\n field: 'totalRows',\r\n width: AgGridColumns.numericColumnWidth,\r\n type: 'numericColumn',\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._decimalPipe.transform(params.value, '1.0-0') : '',\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Error',\r\n field: 'error',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: 'text-danger',\r\n cellRendererFramework: LongRunningProcessListGridErrorGuidCellRendererComponent,\r\n cellRendererParams: {\r\n showErrorDetails: this._showErrorDetails.bind(this)\r\n } as LongRunningProcessListGridErrorGuidCellRendererParams\r\n },\r\n {\r\n headerName: 'Canceled',\r\n field: 'isCanceled',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return null;\r\n }\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Paused',\r\n field: 'isPaused',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return null;\r\n }\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Acknowledged',\r\n field: 'isAcknowledged',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return null;\r\n }\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: LongRunningProcessListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canUpdateError: this._canUpdateError.bind(this),\r\n updateError: this._updateError.bind(this)\r\n } as LongRunningProcessListGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'longRunningProcessId',\r\n sort: 'desc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n this._gridInitialized.next();\r\n }\r\n\r\n private _canUpdateError(params: LongRunningProcessListGridActionCellRendererParams): boolean{\r\n const longRunningProcess = params.data as Compliance.LongRunningProcessModel;\r\n if (!longRunningProcess) {\r\n return false;\r\n }\r\n\r\n return (this.canEdit && !longRunningProcess.isCompleted);\r\n }\r\n\r\n\r\n private async _updateError(params: LongRunningProcessListGridActionCellRendererParams): Promise {\r\n const longRunningProcess = params.data as Compliance.LongRunningProcessModel;\r\n if (!longRunningProcess) {\r\n return;\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm('Are you sure you wish to update the long-running process to error status? If the process is still running, it will not be terminated.', 'Confirm');\r\n }\r\n catch (e) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyService.show({ message: 'Updating' });\r\n\r\n try {\r\n const errorModel: Compliance.LongRunningProcessErrorModel = {\r\n longRunningProcessId: longRunningProcess.longRunningProcessId,\r\n errorMessage: 'An unexpected error has occurred.'\r\n };\r\n\r\n const result = await lastValueFrom(this._longRunningProcessRepository.updateError(errorModel));\r\n Object.assign(longRunningProcess, result);\r\n\r\n this._gridApi.redrawRows({ rowNodes: [params.node] });\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this._gridDataSource = new LongRunningProcessListAgGridDataSource(this._gridApi, this._longRunningProcessRepository);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private async _showErrorDetails(errorGuid: string): Promise {\r\n if (!errorGuid) {\r\n return;\r\n }\r\n\r\n const detailParams: ErrorLogDetailsParams = {\r\n errorLogId: null,\r\n errorLogGuid: errorGuid\r\n };\r\n\r\n await this._modalService.showAsync(ErrorLogDetailsComponent, detailParams, 'modal-lg');\r\n }\r\n\r\n}\r\n","\r\n\r\n\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const LONG_RUNNING_PROCESS_QUIESCE_MODAL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'long-running-process-quiesce-modal.message',\r\n tooltipText: 'Error message displayed to users when attempting to start a long-running process.',\r\n hasIcon: true\r\n }\r\n];\r\n","\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
Message max length is 100 characters.
\r\n
Message is required.
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { LONG_RUNNING_PROCESS_QUIESCE_MODAL_HELP } from './longRunningProcessQuiesceModal.component.help';\r\n\r\n@Component({\r\n templateUrl: './longRunningProcessQuiesceModal.component.html',\r\n selector: 'long-running-process-quiesce-modal'\r\n})\r\nexport class LongRunningProcessQuiesceModalComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formBuilder: UntypedFormBuilder,\r\n private readonly _helpService: HelpService) {\r\n }\r\n\r\n params: void;\r\n result: string;\r\n\r\n form: UntypedFormGroup;\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(LONG_RUNNING_PROCESS_QUIESCE_MODAL_HELP);\r\n\r\n this.form = this._formBuilder.group({\r\n message: [null, [Validators.maxLength(100), Validators.required]]\r\n });\r\n\r\n this.form.setValue({\r\n message: 'The processing service is not available. Please try again later.'\r\n });\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n async pause(): Promise {\r\n this.result = this.form.get('message').value;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const LONG_RUNNING_PROCESS_QUIESCE_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'long-running-process-quiesce.pause',\r\n tooltipText: 'Pauses the long-running process service to allow existing processes to finish while preventing new ones from starting. Note that this DOES NOT pause the actual services running on the server.'\r\n },\r\n {\r\n helpContentId: 'long-running-process-quiesce.resume',\r\n tooltipText: 'Resumes the long-running process service.'\r\n }\r\n];\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const LONG_RUNNING_PROCESS_SYNTHETIC_MODAL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'long-running-process-synthetic-modal.queue-type',\r\n tooltipText: 'The queue type to use which controls how many processes can run concurrently.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'long-running-process-synthetic-modal.number-processes',\r\n tooltipText: 'The number of long-running synthetic processes to start.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'long-running-process-synthetic-modal.duration',\r\n tooltipText: 'The number of milliseconds the long-running process will wait before completing (progress will be reported every second if applicable).',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'long-running-process-synthetic-modal.wait',\r\n tooltipText: 'The number of milliseconds to wait between executing each long-running process.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'long-running-process-synthetic-modal.exception',\r\n tooltipText: 'When checked, the long-running process will throw an exception to simulate something going wrong.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'long-running-process-synthetic-modal.publish-progress',\r\n tooltipText: 'When checked, the process will publish progress change messages to the real-time messaging service to simulate work being completed.',\r\n hasIcon: true\r\n }\r\n];\r\n","\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
Queue Type is required.
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
# Processes must be at least 1.
\r\n
# Processes is required.
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
# Duration must be at least 0.
\r\n
Duration is required.
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
# Wait must be at least 0.
\r\n
Wait is required.
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { LONG_RUNNING_PROCESS_SYNTHETIC_MODAL_HELP } from './longRunningProcessSyntheticModal.component.help';\r\nimport { LongRunningProcessService } from '../longRunningProcess.service';\r\n\r\n@Component({\r\n templateUrl: './longRunningProcessSyntheticModal.component.html',\r\n selector: 'long-running-process-synthetic-modal'\r\n})\r\nexport class LongRunningProcessSyntheticModalComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formBuilder: UntypedFormBuilder,\r\n private readonly _helpService: HelpService,\r\n private readonly _longRunningProcessService: LongRunningProcessService) {\r\n }\r\n\r\n params: void;\r\n result: Compliance.SyntheticLongRunningProcessParameters;\r\n form: UntypedFormGroup;\r\n\r\n get queueTypes(): Compliance.LongRunningProcessQueueTypeModel[] {\r\n return this._longRunningProcessService.queueTypes\r\n .filter(t => t.longRunningProcessQueueType !== Compliance.LongRunningProcessQueueTypeEnum.Control);\r\n }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(LONG_RUNNING_PROCESS_SYNTHETIC_MODAL_HELP);\r\n\r\n this.form = this._formBuilder.group({\r\n queueType: [null, [Validators.required,]],\r\n processes: [null, [Validators.required, Validators.min(1)]],\r\n duration: [null, [Validators.required, Validators.min(0)]],\r\n wait: [null, [Validators.required, Validators.min(0)]],\r\n throwException: [null, []],\r\n publishProgressChangeMessage: [null, []]\r\n });\r\n\r\n this.form.setValue({\r\n queueType: Compliance.LongRunningProcessQueueTypeEnum.Normal,\r\n processes: 1,\r\n duration: 0,\r\n wait: 0,\r\n throwException: false,\r\n publishProgressChangeMessage: false\r\n });\r\n }\r\n\r\n setInstantsDefault(): void {\r\n this.form.setValue({\r\n queueType: Compliance.LongRunningProcessQueueTypeEnum.Normal,\r\n processes: 1,\r\n duration: 0,\r\n wait: 0,\r\n throwException: false,\r\n publishProgressChangeMessage: false\r\n });\r\n }\r\n\r\n setWithDurationDefault(): void {\r\n this.form.setValue({\r\n queueType: Compliance.LongRunningProcessQueueTypeEnum.Normal,\r\n processes: 1,\r\n duration: 3000,\r\n wait: 0,\r\n throwException: false,\r\n publishProgressChangeMessage: true\r\n });\r\n }\r\n\r\n setMultipleDefault(): void {\r\n this.form.setValue({\r\n queueType: Compliance.LongRunningProcessQueueTypeEnum.Normal,\r\n processes: 4,\r\n duration: 2000,\r\n wait: 0,\r\n throwException: false,\r\n publishProgressChangeMessage: true\r\n });\r\n }\r\n\r\n setOverTimeDefault(): void {\r\n this.form.setValue({\r\n queueType: Compliance.LongRunningProcessQueueTypeEnum.Normal,\r\n processes: 4,\r\n duration: 2000,\r\n wait: 500,\r\n throwException: false,\r\n publishProgressChangeMessage: true\r\n });\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n async test(): Promise {\r\n this.result = {\r\n longRunningProcessQueueType: this.form.get(\"queueType\").value as Compliance.LongRunningProcessQueueTypeEnum,\r\n numberOfProcesses: this.form.get('processes').value as number,\r\n duration: this.form.get('duration').value as number,\r\n throwException: this.form.get('throwException').value as boolean,\r\n publishProgressChangeMessage: this.form.get('publishProgressChangeMessage').value as boolean,\r\n cancel: false,\r\n wait: this.form.get('wait').value as number\r\n };\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const LONG_RUNNING_PROCESS_SYNTHETIC_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'long-running-process-synthetic.test',\r\n tooltipText: 'Test the service by simulating long-running processes.'\r\n }\r\n];\r\n","\r\n","import { Component, OnInit, OnDestroy, Input } from '@angular/core';\r\nimport { LongRunningProcessService } from '../longRunningProcess.service';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator/busyIndicator.service';\r\nimport { LongRunningProcessSyntheticModalComponent } from '../Long-Running-Process-Synthetic-Modal/longRunningProcessSyntheticModal.component';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { LONG_RUNNING_PROCESS_SYNTHETIC_HELP } from './longRunningProcessSynthetic.component.help';\r\n\r\n@Component({\r\n selector: 'long-running-process-synthetic',\r\n templateUrl: './longRunningProcessSynthetic.component.html'\r\n})\r\nexport class LongRunningProcessSyntheticComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _longRunningProcessService: LongRunningProcessService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _helpService: HelpService) { }\r\n\r\n @Input() canEdit: boolean;\r\n\r\n get quiescedStatus(): Compliance.LongRunningProcessQuiescedStatusModel {\r\n return this._longRunningProcessService.quiescedStatus;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(LONG_RUNNING_PROCESS_SYNTHETIC_HELP);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n }\r\n\r\n async test(): Promise {\r\n const result = await this._modalService.showAsync(LongRunningProcessSyntheticModalComponent, null, 'modal-md');\r\n\r\n if (!result) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyService.show({ message: 'Testing service' });\r\n\r\n try {\r\n await this._longRunningProcessService.test(result);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const LONG_RUNNING_PROCESS_CONTROL_MODAL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'long-running-process-control-modal.message',\r\n tooltipText: 'Message to send to the long-running process host',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'long-running-process-control-modal.serviceHost',\r\n tooltipText: 'Long-running process host to send the message to',\r\n hasIcon: true\r\n }\r\n];\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { LONG_RUNNING_PROCESS_CONTROL_MODAL_HELP } from './longRunningProcessControlModal.component.help';\r\nimport { LongRunningProcessService } from '../longRunningProcess.service';\r\n\r\n@Component({\r\n templateUrl: './longRunningProcessControlModal.component.html',\r\n selector: 'long-running-process-control-modal'\r\n})\r\nexport class LongRunningProcessControlModalComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formBuilder: UntypedFormBuilder,\r\n private readonly _helpService: HelpService,\r\n private readonly _longRunningProcessService: LongRunningProcessService) {\r\n }\r\n\r\n params: void;\r\n result: { controlMessage: Compliance.LongRunningProcessControlMessageTypeEnum, serviceHost: string };\r\n form: UntypedFormGroup;\r\n\r\n get serviceHosts(): string[] {\r\n return this._longRunningProcessService.serviceHosts;\r\n }\r\n\r\n get controlMessageTypes(): Compliance.LongRunningProcessControlMessageTypeModel[] {\r\n return this._longRunningProcessService.controlMessageTypes;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(LONG_RUNNING_PROCESS_CONTROL_MODAL_HELP);\r\n\r\n this.form = this._formBuilder.group({\r\n controlMessage: [null, [Validators.required,]],\r\n serviceHost: [null, [Validators.required,]],\r\n });\r\n\r\n this.form.setValue({\r\n controlMessage: Compliance.LongRunningProcessControlMessageTypeEnum.GetStatus,\r\n serviceHost: this.serviceHosts[0]\r\n });\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n getControlMessage() {\r\n this.result = {\r\n controlMessage: this.form.get('controlMessage').value as Compliance.LongRunningProcessControlMessageTypeEnum,\r\n serviceHost: this.form.get('serviceHost').value as string\r\n };\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const LONG_RUNNING_PROCESS_CONTROL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'long-running-process-control.message',\r\n tooltipText: 'Send a control message to a service host'\r\n }\r\n];\r\n","\r\n","import { Component, OnInit, OnDestroy, Input } from '@angular/core';\r\nimport { LongRunningProcessService } from '../longRunningProcess.service';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator/busyIndicator.service';\r\nimport { LongRunningProcessControlModalComponent } from '../Long-Running-Process-Control-Modal/longRunningProcessControlModal.component';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { LONG_RUNNING_PROCESS_CONTROL_HELP } from './longRunningProcessControl.component.help';\r\n\r\n@Component({\r\n selector: 'long-running-process-control',\r\n templateUrl: './longRunningProcessControl.component.html'\r\n})\r\nexport class LongRunningProcessControlComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _longRunningProcessService: LongRunningProcessService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _helpService: HelpService) { }\r\n\r\n @Input() canEdit: boolean;\r\n\r\n get serviceHosts(): string[] {\r\n return this._longRunningProcessService.serviceHosts;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(LONG_RUNNING_PROCESS_CONTROL_HELP);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n }\r\n\r\n async sendMessage(): Promise {\r\n const result = await this._modalService.showAsync(LongRunningProcessControlModalComponent, null, 'modal-md');\r\n\r\n if (!result) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyService.show({ message: 'Sending control message' });\r\n\r\n try {\r\n await this._longRunningProcessService.controlMessage(result);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","
\r\n\r\n
\r\n \r\n
\r\n \r\n {{quiescedStatus.isQuiesced ? \"Paused\" : \"Running\"}}\r\n
\r\n
\r\n\r\n
\r\n \r\n {{quiescedStatus.message}}\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n\r\n
\r\n","import { Component, OnInit, OnDestroy, Input } from '@angular/core';\r\nimport { LongRunningProcessService } from '../longRunningProcess.service';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { LongRunningProcessQuiesceModalComponent } from '../Long-Running-Process-Quiesce-Modal/longRunningProcessQuiesceModal.component';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { LONG_RUNNING_PROCESS_QUIESCE_HELP } from './longRunningProcessQuiesce.component.help';\r\n\r\n@Component({\r\n selector: 'long-running-process-quiesce',\r\n templateUrl: './longRunningProcessQuiesce.component.html',\r\n styleUrls: ['./longRunningProcessQuiesce.component.scss']\r\n})\r\nexport class LongRunningProcessQuiesceComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _longRunningProcessService: LongRunningProcessService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _helpService: HelpService) { }\r\n\r\n @Input() canEdit: boolean;\r\n\r\n get quiescedStatus(): Compliance.LongRunningProcessQuiescedStatusModel {\r\n return this._longRunningProcessService.quiescedStatus;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(LONG_RUNNING_PROCESS_QUIESCE_HELP);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n }\r\n\r\n async pause(): Promise {\r\n const result = await this._modalService.showAsync(LongRunningProcessQuiesceModalComponent, null, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyService.show({ message: 'Pausing service' });\r\n\r\n try {\r\n const model: Compliance.LongRunningProcessQuiescedStatusModel = {\r\n isQuiesced: true,\r\n message: result\r\n };\r\n\r\n await this._longRunningProcessService.updateQuiescedStatus(model);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async resume(): Promise {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you wish to resume the long-running process service?', 'Confirm');\r\n }\r\n catch (e) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyService.show({ message: 'Resuming service' });\r\n\r\n try {\r\n const model: Compliance.LongRunningProcessQuiescedStatusModel = {\r\n isQuiesced: false,\r\n message: null\r\n };\r\n\r\n await this._longRunningProcessService.updateQuiescedStatus(model);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

Long-Running Processes

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { LongRunningProcessService } from '../longRunningProcess.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { LONG_RUNNING_PROCESS_PAGE_HELP } from './longRunningProcessPage.component.help';\r\n\r\n@Component({\r\n selector: 'long-running-process-page',\r\n templateUrl: './longRunningProcessPage.component.html',\r\n styleUrls: ['./longRunningProcessPage.component.scss']\r\n})\r\nexport class LongRunningProcessPageComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _longRunningProcessService: LongRunningProcessService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _helpService: HelpService) { }\r\n\r\n isInitialized: boolean = false;\r\n autoRefresh: boolean = false;\r\n canEdit: boolean = false;\r\n refreshing: boolean = false;\r\n\r\n get quiescedStatus(): Compliance.LongRunningProcessQuiescedStatusModel {\r\n return this._longRunningProcessService.quiescedStatus;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(LONG_RUNNING_PROCESS_PAGE_HELP);\r\n\r\n if (!(this._restrictService.isInRole(Roles.ADMINOPERATIONSVIEW) ||\r\n this._restrictService.isInRole(Roles.ADMINOPERATIONSEDIT))) {\r\n this.navigateToUnauthorized();\r\n return;\r\n }\r\n\r\n this.canEdit = this._restrictService.isInRole(Roles.ADMINOPERATIONSEDIT);\r\n\r\n const busyRef = this._busyService.show({ message: 'Loading' });\r\n\r\n try {\r\n await this._longRunningProcessService.start();\r\n\r\n this.autoRefresh = this._longRunningProcessService.autoRefresh;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._longRunningProcessService.stop();\r\n }\r\n\r\n async refresh(): Promise {\r\n this.refreshing = true;\r\n const busyRef = this._busyService.show({ message: 'Loading' });\r\n\r\n try {\r\n await this._longRunningProcessService.refresh();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n this.refreshing = false;\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n onAutoRefreshChange(): void {\r\n this.autoRefresh = !this.autoRefresh;\r\n this._longRunningProcessService.setAutoRefresh(this.autoRefresh);\r\n }\r\n}\r\n","import { StateJurisdictionCommandCenterComponent } from './stateJurisdiction.component';\r\nimport { ColDef, ICellRendererParams, IFilterComp } from 'ag-grid-community';\r\nimport { AgGridFilterParams, AgGridColumns, AgGridDropdownCellEditor, AgGridDatepickerCellEditor, AgGridCurrencyCellEditor, AgGridNumberCellEditor, AgGridTextCellEditor } from '../AgGrid';\r\nimport { WeissmanDateFormat } from '../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer, AgGridMultiSelectRendererParams } from '../AgGrid/MultiSelectTracker';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from '../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { CellEditorValidationResult } from '../AgGrid/CellEditors/validator.interface';\r\nimport { AgGridTooltipCellRendererComponent, AgGridTooltipCellRendererParams } from '../AgGrid/CellRenderers/agGridTooltipCellRenderer.component';\r\nimport { AgGridYesNoFloatingFilterComponent } from '../AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\n\r\nexport interface DeadlineInfo {\r\n propertyType: Core.PropertyTypes;\r\n deadlineType: Core.AppealDeadlineTypes;\r\n name: string;\r\n}\r\n\r\nexport interface DescriptorColumnDefinitions {\r\n [key: number]: (descriptor: Core.DescriptorInfoModel, pickList?: Core.DescriptorPicklistModel[]) => ColDef;\r\n}\r\n\r\nconst getTooltipText = (params: AgGridTooltipCellRendererParams, id: number): string => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (model && model.verifications && model.verifications.length) {\r\n const found = model.verifications.find(val => val.elementId === id);\r\n return found && found.verifiedByName;\r\n }\r\n};\r\n\r\nexport const STATE_JURISDICTION_LIST_COLUMNS = (classRef: StateJurisdictionCommandCenterComponent): ColDef[] => [\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'assessorId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n editable: false,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: classRef.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: classRef.gridTracker } as AgGridMultiSelectRendererParams,\r\n } as ColDef,\r\n {\r\n headerName: 'Assessor Abbr',\r\n field: 'assessorAbbr',\r\n width: AgGridColumns.textColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n editable: false,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/assessor/${model.assessorId}?year=${model.taxYear}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Assessor Name',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Assessor PTX ID',\r\n field: 'assessorPtxId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'stateAbbr',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Full State Name',\r\n field: 'stateName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Assessor Website',\r\n field: 'assessorWebsite',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'view-assessor-website',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const row = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!row || !row.assessorWebsite) {\r\n return '';\r\n }\r\n if (!row.assessorWebsite.toLowerCase().startsWith('http')) {\r\n return `http://${ row.assessorWebsite}`;\r\n }\r\n return row.assessorWebsite;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n headerName: 'Assessor Email',\r\n field: 'assessorEmail',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.send-email-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const row = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!row || !row.assessorEmail) {\r\n return '';\r\n }\r\n return `mailto:${row.assessorEmail}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n headerName: 'Default Collectors',\r\n field: 'defaultCollectors',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Available Collectors',\r\n field: 'availableCollectors',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'PP Due Date',\r\n field: 'compliancePPDeadline',\r\n width: AgGridColumns.dateColumnWidth,\r\n editable: () => classRef.canEdit,\r\n cellEditorFramework: AgGridDatepickerCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: classRef.updateDeadline.bind(classRef),\r\n canReset: true,\r\n hasOverride: (x) => {\r\n const model = x.data as Compliance.AssessorCommandCenterModel;\r\n return !!(model && model.compliancePPAssessorDeadlineIsForTaxYear);\r\n },\r\n args: {\r\n deadlineType: Core.AppealDeadlineTypes.Compliance,\r\n propertyType: Core.PropertyTypes.Personal,\r\n name: 'PP Due Date'\r\n }\r\n },\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!(model && model.compliancePPDeadline)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.compliancePPDeadline, true, 'stored');\r\n },\r\n cellClass: x => {\r\n const model = x.data as Compliance.AssessorCommandCenterModel;\r\n return (model && model.compliancePPAssessorDeadlineIsForTaxYear) ? 'ws-override' : null;\r\n }\r\n },\r\n {\r\n headerName: 'PP Appeal Date',\r\n field: 'appealPPDeadline',\r\n width: AgGridColumns.dateColumnWidth,\r\n editable: () => classRef.canEdit,\r\n cellEditorFramework: AgGridDatepickerCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: classRef.updateDeadline.bind(classRef),\r\n canReset: true,\r\n hasOverride: (x) => {\r\n const model = x.data as Compliance.AssessorCommandCenterModel;\r\n return !!(model && model.appealPPAssessorDeadlineIsForTaxYear);\r\n },\r\n args: {\r\n deadlineType: Core.AppealDeadlineTypes.Appeal,\r\n propertyType: Core.PropertyTypes.Personal,\r\n name: 'PP Appeal Date'\r\n }\r\n },\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!(model && model.appealPPDeadline)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.appealPPDeadline, true, 'stored');\r\n },\r\n cellClass: x => {\r\n const model = x.data as Compliance.AssessorCommandCenterModel;\r\n return (model && model.appealPPAssessorDeadlineIsForTaxYear) ? 'ws-override' : null;\r\n }\r\n },\r\n {\r\n headerName: 'RE Appeal Date',\r\n field: 'appealREDeadline',\r\n width: AgGridColumns.dateColumnWidth,\r\n editable: () => classRef.canEdit,\r\n cellEditorFramework: AgGridDatepickerCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: classRef.updateDeadline.bind(classRef),\r\n canReset: true,\r\n hasOverride: (x) => {\r\n const model = x.data as Compliance.AssessorCommandCenterModel;\r\n return !!(model && model.appealREAssessorDeadlineIsForTaxYear);\r\n },\r\n args: {\r\n deadlineType: Core.AppealDeadlineTypes.Appeal,\r\n propertyType: Core.PropertyTypes.RealEstate,\r\n name: 'RE Appeal Date'\r\n }\r\n },\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!(model && model.appealREDeadline)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.appealREDeadline, true, 'stored');\r\n },\r\n cellClass: x => {\r\n const model = x.data as Compliance.AssessorCommandCenterModel;\r\n return (model && model.appealREAssessorDeadlineIsForTaxYear) ? 'ws-override' : null;\r\n }\r\n },\r\n {\r\n headerName: 'CA Appeal Date',\r\n field: 'appealCADeadline',\r\n width: AgGridColumns.dateColumnWidth,\r\n editable: () => classRef.canEdit,\r\n cellEditorFramework: AgGridDatepickerCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: classRef.updateDeadline.bind(classRef),\r\n canReset: true,\r\n hasOverride: (x) => {\r\n const model = x.data as Compliance.AssessorCommandCenterModel;\r\n return !!(model && model.appealCAAssessorDeadlineIsForTaxYear);\r\n },\r\n args: {\r\n deadlineType: Core.AppealDeadlineTypes.Appeal,\r\n propertyType: Core.PropertyTypes.CentrallyAssessed,\r\n name: 'CA Appeal Date'\r\n }\r\n },\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!(model && model.appealCADeadline)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.appealCADeadline, true, 'stored');\r\n },\r\n cellClass: x => {\r\n const model = x.data as Compliance.AssessorCommandCenterModel;\r\n return (model && model.appealCAAssessorDeadlineIsForTaxYear) ? 'ws-override' : null;\r\n }\r\n },\r\n {\r\n headerName: 'MN Appeal Date',\r\n field: 'appealMNDeadline',\r\n width: AgGridColumns.dateColumnWidth,\r\n editable: () => classRef.canEdit,\r\n cellEditorFramework: AgGridDatepickerCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: classRef.updateDeadline.bind(classRef),\r\n canReset: true,\r\n hasOverride: (x) => {\r\n const model = x.data as Compliance.AssessorCommandCenterModel;\r\n return !!(model && model.appealMNAssessorDeadlineIsForTaxYear);\r\n },\r\n args: {\r\n deadlineType: Core.AppealDeadlineTypes.Appeal,\r\n propertyType: Core.PropertyTypes.Mineral,\r\n name: 'MN Appeal Date'\r\n }\r\n },\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!(model && model.appealMNDeadline)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.appealMNDeadline, true, 'stored');\r\n },\r\n cellClass: x => {\r\n const model = x.data as Compliance.AssessorCommandCenterModel;\r\n return (model && model.appealMNAssessorDeadlineIsForTaxYear) ? 'ws-override' : null;\r\n }\r\n },\r\n {\r\n headerName: 'PP Return Forms',\r\n field: 'ppReturnForms',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n return (model && model.ppReturnFormsPrimaryCount > 1) ? 'cell-validation-warning' : '';\r\n }\r\n },\r\n {\r\n headerName: 'Appeal Forms',\r\n field: 'appealForms',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Default Address',\r\n field: 'defaultAddress',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Default Address Type',\r\n field: 'defaultAddressCorrespondenceTypeName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n editable: () => classRef.canEdit,\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => [\r\n { name: 'Appeal Filing', value: 'Appeal Filing' },\r\n { name: 'General', value: 'General' },\r\n { name: 'PP Return', value: 'PP Return' }\r\n ],\r\n cellFocusLost: classRef.updateDefaultAddressType.bind(classRef)\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'General Address',\r\n field: 'generalAddress',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {\r\n getTooltipText: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return; }\r\n const text: string[] = [];\r\n const verification = model.verifications.find(v => v.elementId === model.generalAddressVerificationElementId);\r\n\r\n if (verification && !verification.qcDate && verification.verifiedDate) {\r\n text.push('Pending QC');\r\n } else if (model.generalAddress && !verification) {\r\n text.push('Verification required');\r\n }\r\n if (model.generalAddressCount > 1) {\r\n text.push(`${(text.length) ? 'd' : 'D' }uplicate General Address exists`);\r\n }\r\n\r\n return text.join(' and ');\r\n }\r\n },\r\n cellClass: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return; }\r\n return classRef.getAddressCellStyle(model.verifications, model.generalAddressVerificationElementId, model.generalAddress, model.generalAddressChangeDate, model.generalAddressCount);\r\n }\r\n },\r\n {\r\n headerName: 'V. General Address',\r\n field: 'generalAddressVerification',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {\r\n getTooltipText: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return; }\r\n return getTooltipText(params, model.generalAddressVerificationElementId);\r\n }\r\n },\r\n valueFormatter: (params) => WeissmanDateFormat(params.value, true),\r\n valueGetter: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (model && model.verifications && model.verifications.length) {\r\n const found = model.verifications.find(val => val.elementId === model.generalAddressVerificationElementId);\r\n return found && found.verifiedDate;\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'PP Return Address',\r\n field: 'ppReturnAddress',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {\r\n getTooltipText: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return; }\r\n const text: string[] = [];\r\n const verification = model.verifications.find(v => v.elementId === model.ppReturnAddressVerificationElementId);\r\n\r\n if (verification && !verification.qcDate && verification.verifiedDate) {\r\n text.push('Pending QC');\r\n } else if (model.ppReturnAddress && !verification) {\r\n text.push('Verification required');\r\n }\r\n if (model.ppReturnAddressCount > 1) {\r\n text.push(`${(text.length) ? 'd' : 'D' }uplicate PP Return Address exists`);\r\n }\r\n\r\n return text.join(' and ');\r\n }\r\n },\r\n cellClass: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return; }\r\n return classRef.getAddressCellStyle(model.verifications, model.ppReturnAddressVerificationElementId, model.ppReturnAddress, model.ppReturnAddressChangeDate, model.ppReturnAddressCount);\r\n }\r\n },\r\n {\r\n headerName: 'V. PP Return Address',\r\n field: 'ppReturnAddressVerification',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {\r\n getTooltipText: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return; }\r\n return getTooltipText(params, model.ppReturnAddressVerificationElementId);\r\n }\r\n },\r\n valueFormatter: (params) => WeissmanDateFormat(params.value, true),\r\n valueGetter: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (model && model.verifications && model.verifications.length) {\r\n const found = model.verifications.find(val => val.elementId === model.ppReturnAddressVerificationElementId);\r\n return found && found.verifiedDate;\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Appeal Filing Address',\r\n field: 'appealFilingAddress',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {\r\n getTooltipText: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return; }\r\n const text: string[] = [];\r\n const verification = model.verifications.find(v => v.elementId === model.appealFilingAddressVerificationElementId);\r\n\r\n if (verification && !verification.qcDate && verification.verifiedDate) {\r\n text.push('Pending QC');\r\n } else if (model.appealFilingAddress && !verification) {\r\n text.push('Verification required');\r\n }\r\n if (model.appealFilingAddressCount > 1) {\r\n text.push(`${(text.length) ? 'd' : 'D' }uplicate Appeal Filing Address exists`);\r\n }\r\n\r\n return text.join(' and ');\r\n }\r\n },\r\n cellClass: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return; }\r\n return classRef.getAddressCellStyle(model.verifications, model.appealFilingAddressVerificationElementId, model.appealFilingAddress, model.appealFilingAddressChangeDate, model.appealFilingAddressCount);\r\n }\r\n },\r\n {\r\n headerName: 'V. Appeal Filing Address',\r\n field: 'appealFilingAddressVerification',\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {\r\n getTooltipText: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return; }\r\n return getTooltipText(params, model.appealFilingAddressVerificationElementId);\r\n }\r\n },\r\n valueFormatter: (params) => WeissmanDateFormat(params.value, true),\r\n valueGetter: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (model && model.verifications && model.verifications.length) {\r\n const found = model.verifications.find(val => val.elementId === model.appealFilingAddressVerificationElementId);\r\n return found && found.verifiedDate;\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Pending QC',\r\n field: 'isPendingQC',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value === true) {\r\n return 'Yes';\r\n }\r\n else if (params.value === false) {\r\n return 'No';\r\n } else {\r\n return null;\r\n }\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Verified Date',\r\n field: 'minVerifiedDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!(model && model.minVerifiedDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.minVerifiedDate, true);\r\n },\r\n hide: true\r\n }\r\n];\r\n\r\nconst getDescriptorValue =\r\n (model: Compliance.AssessorCommandCenterModel, descriptor: Core.DescriptorInfoModel): any => {\r\n if (model && model.descriptorValues && model.descriptorValues.length) {\r\n const found = model.descriptorValues.find(val => val.descriptorId === descriptor.descriptorId);\r\n return found && found.value;\r\n }\r\n };\r\n\r\nexport const BASE_DYNAMIC_DEFINITIONS: DescriptorColumnDefinitions = {\r\n [Core.DescriptorFieldTypes.Currency]: (descriptor) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridCurrencyCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => { }\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n valueFormatter: (params) => (+params.value) ? `$ ${(+params.value).toFixed(2)}` : '',\r\n cellClass: () => ''\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Date]: (descriptor) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.dateColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridDatepickerCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => { },\r\n validator: (value: Date): CellEditorValidationResult => {\r\n const year = value.getFullYear();\r\n const validation = getDescriptor().validation;\r\n const isValid = validation\r\n && (validation.minValue ? year >= validation.minValue : true)\r\n && (validation.maxValue ? year <= validation.maxValue : true);\r\n let message = 'Year must be ';\r\n message += (validation.minValue) && `> ${validation.minValue - 1}`;\r\n message += (validation.minValue && validation.maxValue) && ' and ';\r\n message += (validation.maxValue) && `< ${validation.maxValue + 1}`;\r\n return { isValid, validationMessage: message };\r\n }\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => WeissmanDateFormat(params.value, true),\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => ''\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Number]: (descriptor) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.numericColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridNumberCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => { },\r\n validator: (value: number): CellEditorValidationResult => {\r\n const validation = getDescriptor().validation;\r\n const isValid = validation\r\n && (validation.minValue ? value >= validation.minValue : true)\r\n && (validation.maxValue ? value <= validation.maxValue : true);\r\n let message = 'Value must be ';\r\n message += (validation.minValue) && `> ${validation.minValue - 1}`;\r\n message += (validation.minValue && validation.maxValue) && ' and ';\r\n message += (validation.maxValue) && `< ${ validation.maxValue + 1 }`;\r\n return { isValid, validationMessage: message};\r\n }\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => ''\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Picklist]: (descriptor, picklist) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.selectionColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => {\r\n return picklist.reduce((acc, x) => {\r\n if (x.groupId === getDescriptor().picklistGroupId) {\r\n acc.push({ name: x.name, value: x.name });\r\n }\r\n return acc;\r\n }, []);\r\n },\r\n cellFocusLost: () => { }\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => ''\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.Text]: (descriptor) => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridTextCellEditor,\r\n cellEditorParams: {\r\n cellFocusLost: () => { },\r\n validator: (value: string): CellEditorValidationResult => {\r\n const validation = getDescriptor().validation;\r\n const isValid = validation\r\n && (validation.maxLength ? value.length <= validation.maxLength : true);\r\n const message = `Max characters: ${validation.maxLength}`;\r\n return { isValid, validationMessage: message };\r\n },\r\n maxLength: descriptor.validation && descriptor.validation.maxLength\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n cellClass: () => ''\r\n };\r\n },\r\n [Core.DescriptorFieldTypes.YesNo]: (descriptor) => {\r\n const getDescriptor = () => descriptor;// create closure for later access\r\n let headerParams = {};\r\n // #268558 - PP Original Form Required needs tooltip\r\n if (descriptor.name === 'PP Original Form Required') {\r\n headerParams = {\r\n headerTooltipText: () => {\r\n return 'state-jurisdiction-command-center.pp-original-form-required';\r\n }\r\n };\r\n }\r\n return {\r\n headerName: descriptor.name,\r\n field: `d.${descriptor.descriptorId}`,\r\n width: AgGridColumns.checkboxColumnMinWidth,\r\n headerComponentParams: headerParams,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {},\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => [{ name: 'Yes', value: true }, {name: 'No', value: false}],\r\n cellFocusLost: () => { }\r\n },\r\n hide: !(descriptor.assessorUsage === Core.DescriptorUsageEnum.Frequent),\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterWithBlankOptionsParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.yesNoFilterWithBlankOptionsParams,\r\n valueGetter: (params) => getDescriptorValue(params.data, getDescriptor()),\r\n valueFormatter: (params) => {\r\n if (params.value || params.value === false) {\r\n return (params.value) ? 'Yes' : 'No';\r\n } else {\r\n return '';\r\n }\r\n },\r\n cellClass: () => ''\r\n };\r\n }\r\n};\r\n\r\nexport const BASE_VERIFICATION_COLUMN = (descriptor: Core.DescriptorInfoModel): ColDef => {\r\n const getDescriptor = () => descriptor; // create closure for later access\r\n return {\r\n headerName: `V. ${descriptor.name}`,\r\n field: `v.${descriptor.descriptorId}`,\r\n width: AgGridColumns.dateColumnWidth,\r\n hide: true,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n cellRendererFramework: AgGridTooltipCellRendererComponent,\r\n cellRendererParams: {\r\n getTooltipText: (params) => getTooltipText(params, getDescriptor().descriptorId)\r\n },\r\n valueFormatter: (params) => WeissmanDateFormat(params.value, true),\r\n valueGetter: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n const desc = getDescriptor();\r\n if (model && model.verifications && model.verifications.length) {\r\n const found = model.verifications.find(val => val.elementId === desc.descriptorId);\r\n return found && found.verifiedDate;\r\n }\r\n }\r\n };\r\n};\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../AgGrid';\r\nimport { StateJurisdictionCommandCenterService } from './stateJurisdiction.service';\r\n\r\nexport class StateJurisdictionCommandCenterAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _stateJurisdictionService: StateJurisdictionCommandCenterService) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'assessorName', value: Compliance.AssessorCommandCenterModelPropertyEnum.AssessorName },\r\n { name: 'assessorAbbr', value: Compliance.AssessorCommandCenterModelPropertyEnum.AssessorAbbr },\r\n { name: 'stateAbbr', value: Compliance.AssessorCommandCenterModelPropertyEnum.StateAbbr },\r\n { name: 'ppReturnForms', value: Compliance.AssessorCommandCenterModelPropertyEnum.PPReturnForms },\r\n { name: 'ppReturnAddress', value: Compliance.AssessorCommandCenterModelPropertyEnum.PPReturnAddress },\r\n { name: 'ppReturnAddressVerification', value: Compliance.AssessorCommandCenterModelPropertyEnum.PPReturnAddressVerification },\r\n { name: 'appealFilingAddress', value: Compliance.AssessorCommandCenterModelPropertyEnum.AppealFilingAddress },\r\n { name: 'appealFilingAddressVerification', value: Compliance.AssessorCommandCenterModelPropertyEnum.AppealFilingAddressVerification },\r\n { name: 'generalAddress', value: Compliance.AssessorCommandCenterModelPropertyEnum.GeneralAddress },\r\n { name: 'generalAddressVerification', value: Compliance.AssessorCommandCenterModelPropertyEnum.GeneralAddressVerification },\r\n { name: 'compliancePPDeadline', value: Compliance.AssessorCommandCenterModelPropertyEnum.CompliancePPDeadline },\r\n { name: 'appealPPDeadline', value: Compliance.AssessorCommandCenterModelPropertyEnum.AppealPPDeadline },\r\n { name: 'appealREDeadline', value: Compliance.AssessorCommandCenterModelPropertyEnum.AppealREDeadline },\r\n { name: 'appealCADeadline', value: Compliance.AssessorCommandCenterModelPropertyEnum.AppealCADeadline },\r\n { name: 'appealMNDeadline', value: Compliance.AssessorCommandCenterModelPropertyEnum.AppealMNDeadline },\r\n { name: 'isPendingQC', value: Compliance.AssessorCommandCenterModelPropertyEnum.IsPendingQC },\r\n { name: 'minVerifiedDate', value: Compliance.AssessorCommandCenterModelPropertyEnum.MinVerifiedDate },\r\n { name: 'appealForms', value: Compliance.AssessorCommandCenterModelPropertyEnum.AppealForms },\r\n { name: 'availableCollectors', value: Compliance.AssessorCommandCenterModelPropertyEnum.AvailableCollectors },\r\n { name: 'defaultCollectors', value: Compliance.AssessorCommandCenterModelPropertyEnum.DefaultCollectors },\r\n { name: 'defaultAddressCorrespondenceTypeName', value: Compliance.AssessorCommandCenterModelPropertyEnum.DefaultAddressCorrespondenceTypeName },\r\n { name: 'defaultAddress', value: Compliance.AssessorCommandCenterModelPropertyEnum.DefaultAddress },\r\n { name: 'assessorWebsite', value: Compliance.AssessorCommandCenterModelPropertyEnum.AssessorWebsite },\r\n { name: 'assessorEmail', value: Compliance.AssessorCommandCenterModelPropertyEnum.AssessorEmail },\r\n { name: 'stateName', value: Compliance.AssessorCommandCenterModelPropertyEnum.StateName },\r\n ];\r\n private readonly _filterSortMap: Map = new Map([\r\n [Core.DescriptorFieldTypes.Number, Compliance.AssessorCommandCenterModelPropertyEnum.NumberDescriptor],\r\n [Core.DescriptorFieldTypes.Currency, Compliance.AssessorCommandCenterModelPropertyEnum.NumberDescriptor],\r\n [Core.DescriptorFieldTypes.Date, Compliance.AssessorCommandCenterModelPropertyEnum.DateDescriptor],\r\n [Core.DescriptorFieldTypes.YesNo, Compliance.AssessorCommandCenterModelPropertyEnum.BooleanDescriptor],\r\n [Core.DescriptorFieldTypes.Picklist, Compliance.AssessorCommandCenterModelPropertyEnum.StringDescriptor],\r\n [Core.DescriptorFieldTypes.Text, Compliance.AssessorCommandCenterModelPropertyEnum.StringDescriptor]\r\n ]);\r\n\r\n protected canGetRows(): boolean {\r\n return this._stateJurisdictionService.canGetRows;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const model = this._stateJurisdictionService.currentSearchModel;\r\n\r\n const searchParams: Compliance.AssessorCommandCenterSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n stateId: model && model.stateId,\r\n taxYear: model && model.taxYear\r\n };\r\n\r\n const result = await this._stateJurisdictionService.getAssessors(searchParams);\r\n if (!result) {\r\n return null;\r\n }\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n protected getSortColumns(propertyMap: Compliance.NameValuePair[]) {\r\n const columns: Core.SortModel[] = [];\r\n\r\n const sortModel = this.gridApi.getSortModel();\r\n\r\n if (sortModel) {\r\n sortModel.forEach(x => {\r\n const property = this.getProperty(x.colId, propertyMap);\r\n if (property !== null) {\r\n columns.push({\r\n sortProperty: property,\r\n sortDirection: this.getSortDirection(x.sort)\r\n });\r\n } else {\r\n const descriptor = this._stateJurisdictionService.descriptorInfo.descriptors.find(d => `d.${d.descriptorId}` === x.colId);\r\n if (descriptor) {\r\n columns.push({\r\n sortProperty: this._filterSortMap.get(descriptor.fieldType),\r\n sortDirection: this.getSortDirection(x.sort),\r\n sortParameter: x.colId.split('.')[1]\r\n });\r\n }\r\n\r\n const verification = this._stateJurisdictionService.descriptorInfo.descriptors.find(d => `v.${d.descriptorId}` === x.colId);\r\n if (verification) {\r\n columns.push({\r\n sortProperty: Compliance.AssessorCommandCenterModelPropertyEnum.DescriptorVerification,\r\n sortDirection: this.getSortDirection(x.sort),\r\n sortParameter: x.colId.split('.')[1]\r\n });\r\n }\r\n }\r\n });\r\n }\r\n\r\n return columns;\r\n }\r\n\r\n getSearchParamsWithoutPagination() : Compliance.AssessorCommandCenterSearchModel{\r\n const model = this._stateJurisdictionService.currentSearchModel;\r\n\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n stateId: model && model.stateId,\r\n taxYear: model && model.taxYear\r\n };\r\n }\r\n\r\n protected getColumnFilters(propertyMap: Compliance.NameValuePair[]) {\r\n const columns: Core.FilterModel[] = [];\r\n const filterModel = this.gridApi.getFilterModel();\r\n\r\n if (filterModel) {\r\n for (let prop in filterModel) {\r\n if (filterModel.hasOwnProperty(prop)) {\r\n const property = this.getProperty(prop, propertyMap);\r\n if (property !== null) {\r\n columns.push({\r\n filterProperty: property,\r\n filterConditionType: filterModel[prop] && filterModel[prop].filterConditionType,\r\n filterValues: filterModel[prop] && filterModel[prop].filterValues.map(x => {\r\n return {\r\n filterType: this.getFilterType(x.filterType.displayKey),\r\n filterValue: this.getFilterValue(x),\r\n filterToValue: this.getFilterType(x.filterType.displayKey) === Core.FilterTypeEnum.InRange ? x.filterToValue : null\r\n }\r\n })\r\n });\r\n } else {\r\n const descriptor = this._stateJurisdictionService.descriptorInfo.descriptors.find(d => `d.${d.descriptorId}` === prop);\r\n if (descriptor) {\r\n columns.push({\r\n filterProperty: this._filterSortMap.get(descriptor.fieldType),\r\n filterConditionType: filterModel[prop] && filterModel[prop].filterConditionType,\r\n filterValues: filterModel[prop] && filterModel[prop].filterValues.map(x => {\r\n return {\r\n filterParameter: prop.split('.')[1],\r\n filterType: this.getFilterType(x.filterType.displayKey),\r\n filterValue: this.getFilterValue(x),\r\n filterToValue: this.getFilterType(x.filterType.displayKey) === Core.FilterTypeEnum.InRange ? x.filterToValue : null\r\n }\r\n })\r\n });\r\n }\r\n\r\n const verification = this._stateJurisdictionService.descriptorInfo.descriptors.find(d => `v.${d.descriptorId}` === prop);\r\n if (verification) {\r\n columns.push({\r\n filterProperty: Compliance.AssessorCommandCenterModelPropertyEnum.DescriptorVerification,\r\n filterConditionType: filterModel[prop] && filterModel[prop].filterConditionType,\r\n filterValues: filterModel[prop] && filterModel[prop].filterValues.map(x => {\r\n return {\r\n filterParameter: prop.split('.')[1],\r\n filterType: this.getFilterType(x.filterType.displayKey),\r\n filterValue: this.getFilterValue(x),\r\n filterToValue: this.getFilterType(x.filterType.displayKey) === Core.FilterTypeEnum.InRange ? x.filterToValue : null\r\n }\r\n })\r\n });\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n // handle verification dropdown\r\n const verification = this._stateJurisdictionService.currentFilterModel;\r\n if (verification) {\r\n if (!columns.find(x => x.filterValues.find(y => y.filterParameter === verification.field) ? true: false)) {\r\n columns.push({\r\n filterProperty: verification.property,\r\n filterConditionType: Core.FilterConditionTypeEnum.None,\r\n filterValues: [\r\n {\r\n filterParameter: verification.field,\r\n filterType: Core.FilterTypeEnum.Equals,\r\n filterValue: verification.value,\r\n filterToValue: null\r\n }\r\n ]\r\n });\r\n }\r\n }\r\n\r\n return columns;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const model = this._stateJurisdictionService.currentSearchModel;\r\n\r\n const searchParams: Compliance.AssessorCommandCenterSearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n stateId: model && model.stateId,\r\n taxYear: model && model.taxYear\r\n };\r\n\r\n return await this._stateJurisdictionService.getRowIds(searchParams);\r\n }\r\n}\r\n","\r\n
\r\n \r\n \r\n {{row.formControl.errors?.textInvalid}}\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n \r\n {{row.formControl.errors?.numberInvalid}}\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n $\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n \r\n \r\n {{row.formControl.errors?.dateInvalid}}\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{row.name}}\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{row.name}}\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ViewChild, ElementRef } from '@angular/core';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UntypedFormGroup, UntypedFormControl, UntypedFormBuilder } from '@angular/forms';\r\nimport { StateJurisdictionCommandCenterService } from '../stateJurisdiction.service';\r\nimport { BulkUpdateDynamicBase, BulkUpdateOption } from '../../../UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component';\r\nimport { IWeissmanModalComponent } from '../../WeissmanModalService';\r\n\r\nexport interface StateJurisdictionBulkUpdateParams {\r\n selection: Compliance.SelectedRowsModel;\r\n selectedCount: number;\r\n descriptorInfo: Core.DescriptorMetadataModel;\r\n}\r\n\r\n@Component({\r\n selector: 'state-jurisdiction-bulk-update',\r\n templateUrl: './stateJurisdictionBulkUpdate.component.html'\r\n})\r\nexport class StateJurisdictionBulkUpdateComponent extends BulkUpdateDynamicBase implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _stateJurisdictionService: StateJurisdictionCommandCenterService,\r\n _bsModalRef: BsModalRef,\r\n _fb: UntypedFormBuilder\r\n ) { super(_bsModalRef, _fb) }\r\n\r\n @ViewChild('text', { static: true }) textTemplate: ElementRef;\r\n @ViewChild('number', { static: true }) numberTemplate: ElementRef;\r\n @ViewChild('currency', { static: true }) currencyTemplate: ElementRef;\r\n @ViewChild('date', { static: true }) dateTemplate: ElementRef;\r\n @ViewChild('picklist', { static: true }) picklistTemplate: ElementRef;\r\n\r\n bulkUpdateForm: UntypedFormGroup = this._fb.group({\r\n defaultAddressCorrespondenceTypeName: [{ value: null, disabled: true }],\r\n ppReturnAddress: [{ value: null, disabled: true }],\r\n appealFilingAddress: [{ value: null, disabled: true }],\r\n generalAddress: [{ value: null, disabled: true }]\r\n });\r\n\r\n verificationOptions: Compliance.NameValuePair[] = [\r\n { name: 'No Change', value: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange },\r\n { name: 'Verify', value: Compliance.AssessorCommandCenterBulkUpdateActionEnum.Verify },\r\n { name: 'QC', value: Compliance.AssessorCommandCenterBulkUpdateActionEnum.QC }\r\n ];\r\n\r\n defaultAddressType: BulkUpdateOption;\r\n ppAddress: BulkUpdateOption;\r\n appealFilingAddress: BulkUpdateOption;\r\n generalAddress: BulkUpdateOption;\r\n\r\n areSplitControlsVisible: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this.header = `Bulk Update ${this.params.selectedCount} Records`;\r\n\r\n this._templateMap = new Map([\r\n [Core.DescriptorFieldTypes.Date, this.dateTemplate],\r\n [Core.DescriptorFieldTypes.Number, this.numberTemplate],\r\n [Core.DescriptorFieldTypes.Picklist, this.picklistTemplate],\r\n [Core.DescriptorFieldTypes.YesNo, this.picklistTemplate],\r\n [Core.DescriptorFieldTypes.Text, this.textTemplate],\r\n [Core.DescriptorFieldTypes.Currency, this.currencyTemplate]\r\n ]);\r\n\r\n this.defaultAddressType = {\r\n name: 'Default Address Type',\r\n isRequired: true,\r\n template: this._templateMap.get(Core.DescriptorFieldTypes.Picklist),\r\n picklist: [\r\n { name: 'Appeal Filing', value: Core.CorrespondenceTypes.AppealFiling },\r\n { name: 'General', value: Core.CorrespondenceTypes.General },\r\n { name: 'PP Return', value: Core.CorrespondenceTypes.PPReturn }\r\n ],\r\n action: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange,\r\n formControlName: 'defaultAddressCorrespondenceTypeName',\r\n formControl: this.bulkUpdateForm.get('defaultAddressCorrespondenceTypeName') as UntypedFormControl\r\n };\r\n\r\n this.ppAddress = {\r\n name: 'PP Return Address',\r\n isRequired: true,\r\n template: this._templateMap.get(Core.DescriptorFieldTypes.Picklist),\r\n picklist: [\r\n { name: 'Use General Address', value: Core.CorrespondenceTypes.General},\r\n { name: 'Use Appeal Filing Address', value: Core.CorrespondenceTypes.AppealFiling}\r\n ],\r\n action: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange,\r\n formControlName: 'ppReturnAddress',\r\n formControl: this.bulkUpdateForm.get('ppReturnAddress') as UntypedFormControl\r\n };\r\n\r\n this.appealFilingAddress = {\r\n name: 'Appeal Filing Address',\r\n isRequired: true,\r\n template: this._templateMap.get(Core.DescriptorFieldTypes.Picklist),\r\n picklist: [\r\n { name: 'Use General Address', value: Core.CorrespondenceTypes.General },\r\n { name: 'Use PP Return Address', value: Core.CorrespondenceTypes.PPReturn }\r\n ],\r\n action: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange,\r\n formControlName: 'appealFilingAddress',\r\n formControl: this.bulkUpdateForm.get('appealFilingAddress') as UntypedFormControl\r\n };\r\n\r\n this.generalAddress = {\r\n name: 'General Address',\r\n isRequired: true,\r\n template: this._templateMap.get(Core.DescriptorFieldTypes.Picklist),\r\n picklist: [\r\n { name: 'Use Appeal Filing Address', value: Core.CorrespondenceTypes.AppealFiling },\r\n { name: 'Use PP Return Address', value: Core.CorrespondenceTypes.PPReturn }\r\n ],\r\n action: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange,\r\n formControlName: 'generalAddress',\r\n formControl: this.bulkUpdateForm.get('generalAddress') as UntypedFormControl\r\n };\r\n\r\n this.updateOptions = [this.defaultAddressType, this.generalAddress, this.appealFilingAddress, this.ppAddress];\r\n\r\n this.params.descriptorInfo.descriptors.forEach(descriptor => {\r\n const control = new UntypedFormControl(null, [this._validators.get(descriptor.fieldType)(descriptor.validation)]);\r\n control.disable();\r\n this.bulkUpdateForm.addControl(`${descriptor.descriptorId}`, control);\r\n\r\n const option = {\r\n name: descriptor.name,\r\n descriptorId: descriptor.descriptorId,\r\n isRequired: true,\r\n template: this._templateMap.get(descriptor.fieldType),\r\n picklist: this._getPicklist(descriptor),\r\n action: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange,\r\n formControlName: `${descriptor.descriptorId}`,\r\n formControl: control,\r\n validation: descriptor.validation\r\n };\r\n this.updateOptions.push(option);\r\n });\r\n }\r\n\r\n async save(force: boolean = false): Promise {\r\n let confirmMessage: string = '';\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating' });\r\n\r\n try {\r\n const formValues = this.bulkUpdateForm.value;\r\n const changedDescriptors: Compliance.AssessorCommandCenterDescriptorValueBulkUpdateModel[] = this\r\n .updateOptions\r\n .filter(o => o.descriptorId &&\r\n !(o.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange))\r\n .map(o => ({\r\n action: o.action,\r\n descriptorId: o.descriptorId,\r\n value: (o.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.Remove\r\n || o.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.QC\r\n || o.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.Verify)\r\n ? null\r\n : formValues[o.descriptorId]\r\n }));\r\n\r\n const changedAddresses: Compliance.AssessorCommandCenterAddressBulkUpdateModel[] = [\r\n {\r\n action: this.ppAddress.action,\r\n changeToCorrespondenceType: (formValues.ppReturnAddress) ? formValues.ppReturnAddress : null,\r\n correspondenceType: Core.CorrespondenceTypes.PPReturn\r\n },\r\n {\r\n action: this.appealFilingAddress.action,\r\n changeToCorrespondenceType: (formValues.appealFilingAddress) ? formValues.appealFilingAddress : null,\r\n correspondenceType: Core.CorrespondenceTypes.AppealFiling\r\n },\r\n {\r\n action: this.generalAddress.action,\r\n changeToCorrespondenceType: (formValues.generalAddress) ? formValues.generalAddress : null,\r\n correspondenceType: Core.CorrespondenceTypes.General\r\n }\r\n ];\r\n\r\n const updateModel: Compliance.AssessorCommandCenterBulkUpdateModel = {\r\n descriptorValues: changedDescriptors,\r\n addresses: changedAddresses,\r\n defaultAddress: {\r\n action: this.defaultAddressType.action,\r\n correspondenceType: formValues.defaultAddressCorrespondenceTypeName\r\n },\r\n force: force,\r\n searchModel: this._stateJurisdictionService.currentSearchModel,\r\n selectedRows: this.params.selection\r\n };\r\n\r\n this.result = await this._stateJurisdictionService.bulkUpdateList(updateModel);\r\n\r\n this._bsModalRef.hide();\r\n return Promise.resolve();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n confirmMessage = e2.error.message;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(confirmMessage, 'Confirm Update');\r\n } catch (e3) {\r\n return Promise.resolve();\r\n }\r\n\r\n // force\r\n await this.save(true);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n showSplitControls(showControls: boolean): void {\r\n if ((showControls && this.fieldsModified) || (!showControls && this.verificationModified)) {\r\n if (!confirm(\"Switching tabs will clear all fields. Do you want to continue?\")) {\r\n return;\r\n }\r\n }\r\n\r\n this._setTabFormState(showControls);\r\n this.areSplitControlsVisible = showControls;\r\n this.fieldsModified = false;\r\n this.verificationModified = false;\r\n }\r\n\r\n private _setTabFormState(state: boolean): void {\r\n this.updateOptions.forEach(o => {\r\n o.action = Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange;\r\n if (state) {\r\n o.formControl.setValue(Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange);\r\n o.formControl.enable();\r\n } else {\r\n o.formControl.setValue(null);\r\n o.formControl.disable();\r\n }\r\n });\r\n }\r\n\r\n private _getPicklist(descriptor: Core.DescriptorInfoModel): Compliance.NameValuePair[] {\r\n if (descriptor.fieldType === Core.DescriptorFieldTypes.Picklist) {\r\n return this.params.descriptorInfo.pickList\r\n .filter(p => p.groupId === descriptor.picklistGroupId)\r\n .map(p => ({ name: p.name, value: p.name }));\r\n }\r\n if (descriptor.fieldType === Core.DescriptorFieldTypes.YesNo) {\r\n return [\r\n { name: 'Yes', value: true },\r\n { name: 'No', value: false }\r\n ];\r\n }\r\n return null;\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const STATE_JURISDICTION_COMMAND_CENTER_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'state-jurisdiction-command-center.filter-disabled',\r\n tooltipText: 'Not available until a valid filter is selected'\r\n },\r\n {\r\n helpContentId: 'state-jurisdiction-command-center.highlight',\r\n tooltipText: 'Highlights change-tracked cells which have been recently modified.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'state-jurisdiction-command-center.filter-verification',\r\n tooltipText: 'Filters based on verification status.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'state-jurisdiction-command-center.pp-original-form-required',\r\n tooltipText: 'Original jurisdiction paper form should be submitted with any software generated return.'\r\n }\r\n];\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { UntypedFormGroup, UntypedFormBuilder } from '@angular/forms';\r\nimport { StateJurisdictionCommandCenterService, FilterTimeFrame, FilterVerification } from '../stateJurisdiction.service';\r\nimport { YearPickerMixin } from '../../../UI-Lib/Mixins';\r\nimport { takeUntil, distinctUntilChanged } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'command-view-controls',\r\n templateUrl: './viewControls.component.html',\r\n styleUrls: ['./viewControls.component.scss']\r\n})\r\nexport class CommandViewControlsComponent extends YearPickerMixin() implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _stateJurisdictionService: StateJurisdictionCommandCenterService\r\n ) {\r\n super();\r\n }\r\n\r\n states: Core.StateModel[] = [];\r\n stateFormatter = (state) => (state.abbr) ? `${state.fullName} (${state.abbr})` : state.fullName;\r\n viewControlForm: UntypedFormGroup;\r\n filterForm: UntypedFormGroup;\r\n deselectValue;\r\n\r\n highlightDates: Compliance.NameValuePair[] = this._stateJurisdictionService.highlightDates;\r\n verificationOptions: Compliance.NameValuePair[] = this._stateJurisdictionService.verificationOptions;\r\n\r\n private _all: Core.StateModel = {\r\n abbr: null,\r\n countryId: 0,\r\n fullName: 'All',\r\n lienDateMonthDay: '',\r\n lienDateYearID: 0,\r\n stateID: null\r\n };\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n const searchModel = this._stateJurisdictionService.currentSearchModel;\r\n\r\n this.viewControlForm = this._fb.group({\r\n state: [],\r\n taxYear: [(searchModel) ? searchModel.taxYear : new Date().getFullYear()]\r\n });\r\n\r\n const filterModel = this._stateJurisdictionService.currentFilterModel;\r\n const highlightModel = this._stateJurisdictionService.highlightChangesModel;\r\n\r\n this.filterForm = this._fb.group({\r\n recentChanges: [(highlightModel) ? highlightModel : null],\r\n verification: [(filterModel) ? filterModel : null]\r\n });\r\n\r\n this.viewControlForm.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(() => this._outputFormChanges());\r\n\r\n this.filterForm.get('recentChanges').valueChanges\r\n .pipe(takeUntil(this.destroy$))\r\n .pipe(distinctUntilChanged())\r\n .subscribe((val) => this._outputHighlightChanges(val));\r\n\r\n this.filterForm.get('verification').valueChanges\r\n .pipe(takeUntil(this.destroy$))\r\n .pipe(distinctUntilChanged())\r\n .subscribe((val) => this._outputFilterChanges(val));\r\n\r\n this.states = [this._all, ...this._stateJurisdictionService.states];\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.viewControlForm.patchValue({state: undefined});\r\n this._outputFormChanges();\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n private _outputFormChanges(): void {\r\n const { state, taxYear } = this.viewControlForm.value;\r\n\r\n let searchModel: Compliance.AssessorCommandCenterSearchModel = {\r\n stateId: (state) ? state.stateID : undefined,\r\n taxYear: taxYear\r\n }\r\n\r\n this._stateJurisdictionService.formChanged(searchModel);\r\n }\r\n\r\n private _outputHighlightChanges(value: FilterTimeFrame): void {\r\n this._stateJurisdictionService.highlightChanged(value);\r\n }\r\n\r\n private _outputFilterChanges(value: FilterVerification): void {\r\n this._stateJurisdictionService.filtersChanged(value);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n State and Jurisdiction Command Center\r\n \r\n

\r\n
\r\n
\r\n
View:
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n \r\n\r\n \r\n \r\n
\r\n","
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, HostBinding, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport {\r\n FilterTimeFrame,\r\n GridSourceOptionEnum,\r\n StateJurisdictionCommandCenterService\r\n} from './stateJurisdiction.service';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { BehaviorSubject, Subject } from 'rxjs';\r\nimport { AgGridOptionsBuilder } from '../AgGrid';\r\nimport { ColDef, ColumnApi, GridApi, GridReadyEvent } from 'ag-grid-community';\r\nimport {\r\n BASE_DYNAMIC_DEFINITIONS,\r\n BASE_VERIFICATION_COLUMN,\r\n DeadlineInfo,\r\n STATE_JURISDICTION_LIST_COLUMNS\r\n} from './stateJurisdiction.columns';\r\nimport { AgGridMultiSelectTracker } from '../AgGrid/MultiSelectTracker';\r\nimport { IMutexServiceHandler, WeissmanMutexService } from '../WeissmanMutexService';\r\nimport { StateJurisdictionCommandCenterAgGridDataSource } from './agGridDataSource';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../AgGrid/ToolPanel/models';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { WeissmanDateFormat } from '../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { DatepickerCellEditorParams } from '../AgGrid/CellEditors/agGridDatePickerCellEditor.component';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport {\r\n StateJurisdictionBulkUpdateComponent,\r\n StateJurisdictionBulkUpdateParams\r\n} from './Bulk-Update/stateJurisdictionBulkUpdate.component';\r\nimport { WeissmanModalService } from '../WeissmanModalService';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { STATE_JURISDICTION_COMMAND_CENTER_HELP } from './stateJurisdiction.component.help';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { DropdownCellEditorParams } from '../AgGrid/CellEditors/agGridDropdownCellEditor.component';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\n\r\n@Component({\r\n selector: 'state-jurisdiction-command-center',\r\n templateUrl: './stateJurisdiction.component.html',\r\n styleUrls: ['./stateJurisdiction.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class StateJurisdictionCommandCenterComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _stateJurisdictionService: StateJurisdictionCommandCenterService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _helpService: HelpService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _toastr: ToastrService) { }\r\n\r\n @HostBinding('class.state-jurisdiction-command-center') hostClass = true;\r\n\r\n selectedGridSourceOption: Compliance.NameValuePair;\r\n gridSourceOptions: Compliance.NameValuePair[];\r\n\r\n canGetRows: boolean = false;\r\n canEdit: boolean = false;\r\n editing: boolean = false;\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n isInitialized: boolean = false;\r\n gridId: System.Guid = 'c0899ab1-6634-4a4c-b9cc-f148cb781959';\r\n gridTracker: AgGridMultiSelectTracker;\r\n columnApi: ColumnApi;\r\n gridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'clickable': (params) => false,\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Compliance.AssessorCommandCenterModel).assessorId)\r\n },\r\n singleClickEdit: true\r\n })\r\n .withCellEditingStarted(x => {\r\n this.startEditMode();\r\n })\r\n .withCellEditingStopped(x => {\r\n this.endEditMode();\r\n })\r\n .withoutCellEditingStoppedOnGridLostFocus()\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[]): Promise => {\r\n const searchModel = this._gridDataSource.getSearchParamsWithoutPagination();\r\n searchModel.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n\r\n if (!searchModel.selectedRows.selectAllRows && searchModel.selectedRows.selectedRows.length === 0) {\r\n searchModel.selectedRows.selectAllRows = true;\r\n }\r\n\r\n const exportModel: Compliance.AssessorCommandCenterExportModel = {\r\n columnsToReturn: columnsToReturn,\r\n searchModel: searchModel\r\n };\r\n const longRunningProcessId = await this._stateJurisdictionService.exportList(exportModel);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportAssessorCommandCenterAssessors };\r\n },\r\n disabled: true,\r\n canCancel: true\r\n };\r\n\r\n verificationStatus: Compliance.AssessorCommandCenterModelPropertyEnum;\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: StateJurisdictionCommandCenterAgGridDataSource;\r\n private _highlightDate: FilterTimeFrame;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get inEditMode(): boolean {\r\n return !this._mutexService.canAcquire(this._stateJurisdictionService.editGroup);\r\n }\r\n\r\n get refreshHelpContentId(): string {\r\n if (!this.canGetRows) {\r\n return 'state-jurisdiction-command-center.filter-disabled';\r\n }\r\n\r\n return 'app.refresh';\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(STATE_JURISDICTION_COMMAND_CENTER_HELP);\r\n\r\n const busyRef = this._busyService.show({ message: 'Loading' });\r\n\r\n try {\r\n await this._stateJurisdictionService.start();\r\n\r\n this.gridSourceOptions = this._stateJurisdictionService.gridSourceOptions;\r\n\r\n this.canEdit = this._restrictService.isInRole(Roles.ASSESSOREDIT);\r\n\r\n this._stateJurisdictionService.selectedGridSourceOption$.pipe(takeUntil(this._destroy$))\r\n .subscribe(option => this.selectedGridSourceOption = option);\r\n\r\n this._stateJurisdictionService.currentSearchModel$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n this.canGetRows = this._stateJurisdictionService.canGetRows;\r\n this.exportOptions.disabled = !this.canGetRows;\r\n this._refreshDataSource();\r\n });\r\n\r\n this._stateJurisdictionService.currentFilterModel$\r\n .pipe(takeUntil(this._destroy$)).subscribe((model) => {\r\n this.verificationStatus = model && model.property;\r\n this._refreshDataSource();\r\n });\r\n\r\n this._stateJurisdictionService.highlightChanges$.pipe(takeUntil(this._destroy$)).subscribe(model => {\r\n this._highlightDate = model;\r\n if (this._gridApi) {\r\n this._gridApi.redrawRows();\r\n }\r\n });\r\n\r\n this._stateJurisdictionService.updatingValue$.pipe(takeUntil(this._destroy$)).subscribe(updating => {\r\n if (this._gridApi) {\r\n if (updating) {\r\n this._gridApi.showLoadingOverlay();\r\n } else {\r\n this._gridApi.hideOverlay();\r\n }\r\n }\r\n });\r\n\r\n this.isInitialized = true;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this.gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n const isBulkUpdateVisible = this.canEdit && this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n });\r\n\r\n this._setColumnDefinitions();\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'assessorAbbr',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n setSelectedGridSourceOption(gso: Compliance.NameValuePair): void {\r\n this._stateJurisdictionService.setSelectedGridSourceOption(gso);\r\n }\r\n\r\n startEditMode(): void {\r\n this.editing = true;\r\n this._mutexService.acquire(this, this._stateJurisdictionService.editGroup);\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you wish to leave?');\r\n }\r\n\r\n endEditMode(): void {\r\n this.editing = false;\r\n this._gridApi.stopEditing();\r\n this._mutexService.release(this, this._stateJurisdictionService.editGroup);\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n refresh(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n async bulkUpdate(): Promise {\r\n const params: StateJurisdictionBulkUpdateParams = {\r\n selection: this.gridTracker.getSelectedRowsModel(),\r\n selectedCount: this.gridTracker.getSelectedRowsCount(),\r\n descriptorInfo: this._stateJurisdictionService.descriptorInfo\r\n };\r\n\r\n const result = await this._modalService.showAsync(StateJurisdictionBulkUpdateComponent, params, 'modal-lg');\r\n if (!result) {\r\n return;\r\n }\r\n\r\n if (result.warnings && result.warnings.length) {\r\n await this._messageModalService.alertList(result.warnings, 'Bulk update notice');\r\n }\r\n\r\n this._refreshDataSource();\r\n }\r\n\r\n async updateDefaultAddressType(params: DropdownCellEditorParams, updatedValue: string): Promise {\r\n const rowData = params.data as Compliance.AssessorCommandCenterModel;\r\n\r\n let correspondenceType: number;\r\n switch (updatedValue) {\r\n case 'Appeal Filing':\r\n correspondenceType = Core.CorrespondenceTypes.AppealFiling;\r\n break;\r\n case 'General':\r\n correspondenceType = Core.CorrespondenceTypes.General;\r\n break;\r\n case 'PP Return':\r\n correspondenceType = Core.CorrespondenceTypes.PPReturn;\r\n }\r\n\r\n const updateParams: Compliance.AssessorCommandCenterDefaultAddressUpdateModel = {\r\n assessorId: rowData.assessorId,\r\n correspondenceType,\r\n searchModel: this._gridDataSource.getSearchParamsWithoutPagination()\r\n };\r\n\r\n try {\r\n await this._stateJurisdictionService.updateDefaultAddressType(updateParams);\r\n } catch (err) {\r\n this._toastr.error(err.error.message);\r\n } finally {\r\n this._refreshDataSource();\r\n }\r\n }\r\n\r\n async updateDeadline(params: DatepickerCellEditorParams, updatedDate: string): Promise {\r\n const rowModel = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!rowModel) {\r\n return Promise.resolve();\r\n }\r\n\r\n const deadlineInfo = params.args as DeadlineInfo;\r\n if (!deadlineInfo) {\r\n return Promise.resolve();\r\n }\r\n\r\n const initialDate = params.value && WeissmanDateFormat(params.value, true);\r\n if (updatedDate === initialDate) {\r\n return Promise.resolve();\r\n }\r\n\r\n const updateModel: Compliance.AssessorCommandCenterDeadlineUpdateModel = {\r\n assessorId: rowModel.assessorId,\r\n deadlineDate: (updatedDate) ? new Date(updatedDate) : null,\r\n force: false,\r\n searchModel: this._stateJurisdictionService.currentSearchModel,\r\n propertyType: deadlineInfo.propertyType,\r\n deadlineType: deadlineInfo.deadlineType\r\n };\r\n\r\n this._stateJurisdictionService.loading(true);\r\n\r\n let result: Compliance.AssessorCommandCenterModel = null;\r\n\r\n try {\r\n result = await this._stateJurisdictionService.updateDeadline(updateModel);\r\n } catch (e) {\r\n // service returns a 422 and a message if the user confirmation needed to force update\r\n if (e && e.status !== 422) {\r\n return Promise.reject(e);\r\n }\r\n this._stateJurisdictionService.loading(false);\r\n const deadlineInfo = params.args as DeadlineInfo;\r\n\r\n try {\r\n await this._messageModalService.confirm(e.error.message, `Confirm ${deadlineInfo ? deadlineInfo.name : 'Date'} Exception`);\r\n } catch (cancel) {\r\n // revert the cell value\r\n params.node.setDataValue(params.column.getColId(), params.value);\r\n return Promise.resolve();\r\n }\r\n\r\n this._stateJurisdictionService.loading(true);\r\n\r\n updateModel.force = true;\r\n result = await this._stateJurisdictionService.updateDeadline(updateModel);\r\n } finally {\r\n this._stateJurisdictionService.loading(false);\r\n }\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._gridDataSource.updateRow(y => {\r\n const rowModel = y.data as Compliance.AssessorCommandCenterModel;\r\n return rowModel && rowModel.assessorId === result.assessorId;\r\n },\r\n () => {\r\n return Promise.resolve(result);\r\n });\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n onIncludeCompletedChange(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n private async _setColumnDefinitions(): Promise {\r\n const columns = STATE_JURISDICTION_LIST_COLUMNS(this);\r\n\r\n const pickList = this._stateJurisdictionService.descriptorInfo.pickList;\r\n\r\n this._stateJurisdictionService.descriptorInfo.descriptors.reduce((acc, descriptor) => {\r\n const column: ColDef = BASE_DYNAMIC_DEFINITIONS[descriptor.fieldType](descriptor, pickList);\r\n column.editable = () => this.canEdit;\r\n column.cellEditorParams.cellFocusLost = (params, updatedValue) => this._updateDescriptor(params, updatedValue, descriptor);\r\n column.cellClass = (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return ''; }\r\n return this._getCellStyle(model, descriptor);\r\n };\r\n column.cellRendererParams = {\r\n getTooltipText: (params) => {\r\n const model = params.data as Compliance.AssessorCommandCenterModel;\r\n if (!model) { return ''; }\r\n return this._getCellWarning(model, descriptor);\r\n }\r\n };\r\n acc.push(column);\r\n\r\n const verifiedColumn: ColDef = BASE_VERIFICATION_COLUMN(descriptor);\r\n acc.push(verifiedColumn);\r\n\r\n return acc;\r\n }, columns);\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n }\r\n\r\n getAddressCellStyle(verifications: Compliance.AssessorCommandCenterVerificationElementModel[], elementId: number, address: string, changeDate: Date, addressCount: number): string {\r\n let style = '';\r\n const verification = verifications.find(v => v.elementId === elementId);\r\n\r\n // verification style\r\n if (verification && verification.verifiedDate && verification.qcDate) {\r\n style += 'cell-qc';\r\n } else if (verification && verification.verifiedDate) {\r\n if (this.verificationStatus === Compliance.AssessorCommandCenterModelPropertyEnum.IsPendingQC) {\r\n style += 'cell-pending-qc';\r\n }\r\n } else if (address && addressCount > 1) {\r\n style += 'cell-validation-warning';\r\n }\r\n\r\n // highlight styles\r\n let isRecent = false;\r\n if (this._highlightDate && changeDate) {\r\n const highlightDate = this._highlightDate.date.getTime();\r\n const changed = changeDate.getTime();\r\n isRecent = (this._highlightDate.direction === 'gt')\r\n ? (changed < highlightDate)\r\n : (changed > highlightDate);\r\n }\r\n style += (isRecent) ? ' cell-highlight-recent-changes' : '';\r\n\r\n return style;\r\n }\r\n\r\n private _getCellStyle(model: Compliance.AssessorCommandCenterModel, descriptor: Core.DescriptorInfoModel): string {\r\n let style = '';\r\n const verification = model.verifications.find(v => v.elementId === descriptor.descriptorId);\r\n let changeDate: Date = null;\r\n\r\n // verification styles\r\n if (model && model.descriptorValues && model.descriptorValues.length) {\r\n const found = model.descriptorValues.find(val => val.descriptorId === descriptor.descriptorId);\r\n const descriptorValue = found && found.value;\r\n changeDate = found && found.changeDate;\r\n if (!(descriptorValue === null || descriptorValue === undefined)) {\r\n if (verification && verification.verifiedDate && verification.qcDate) {\r\n style += 'cell-qc';\r\n } else if (verification && verification.verifiedDate) {\r\n if (this.verificationStatus === Compliance.AssessorCommandCenterModelPropertyEnum.IsPendingQC) {\r\n style += 'cell-pending-qc';\r\n }\r\n } else if (verification) {\r\n style += 'cell-validation-warning';\r\n }\r\n }\r\n }\r\n\r\n // highlight styles\r\n let isRecent = false;\r\n if (this._highlightDate && changeDate) {\r\n const highlightDate = this._highlightDate.date.getTime();\r\n const changed = changeDate.getTime();\r\n isRecent = (this._highlightDate.direction === 'gt')\r\n ? (changed < highlightDate)\r\n : (changed > highlightDate);\r\n }\r\n style += (isRecent) ? ' cell-highlight-recent-changes' : '';\r\n\r\n return style;\r\n }\r\n\r\n private _getCellWarning(model: Compliance.AssessorCommandCenterModel, descriptor: Core.DescriptorInfoModel): string {\r\n const verification = model.verifications.find(v => v.elementId === descriptor.descriptorId);\r\n\r\n // verification messages\r\n if (model && model.descriptorValues && model.descriptorValues.length) {\r\n const found = model.descriptorValues.find(val => val.descriptorId === descriptor.descriptorId);\r\n const descriptorValue = found && found.value;\r\n if (!(descriptorValue === null || descriptorValue === undefined)) {\r\n if (verification && verification.verifiedDate) {\r\n return (verification.qcDate) ? null : 'Pending QC';\r\n } else if (verification) {\r\n return 'Verification Required';\r\n }\r\n }\r\n }\r\n\r\n return null;\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this.gridTracker.clear();\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear();\r\n\r\n this._gridDataSource = new StateJurisdictionCommandCenterAgGridDataSource(\r\n this._gridApi,\r\n this._stateJurisdictionService);\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private async _updateDescriptor(params: DatepickerCellEditorParams, updatedValue: any, descriptor: Core.DescriptorInfoModel): Promise {\r\n const rowModel = params.data as Compliance.AssessorCommandCenterModel;\r\n\r\n if (!rowModel) {\r\n return Promise.resolve();\r\n }\r\n\r\n const initialValue = params.value;\r\n if (updatedValue === initialValue) {\r\n return Promise.resolve();\r\n }\r\n\r\n const updateModel: Compliance.AssessorCommandCenterDescriptorUpdateModel = {\r\n assessorId: rowModel.assessorId,\r\n force: false,\r\n searchModel: this._stateJurisdictionService.currentSearchModel,\r\n descriptorId: descriptor.descriptorId,\r\n value: updatedValue\r\n };\r\n\r\n this._stateJurisdictionService.loading(true);\r\n\r\n let result: Compliance.AssessorCommandCenterModel = null;\r\n\r\n try {\r\n result = await this._stateJurisdictionService.updateDescriptor(updateModel);\r\n } catch (e) {\r\n // service returns a 422 and a message if the user confirmation needed to force update\r\n if (e && e.status !== 422) {\r\n return Promise.reject(e);\r\n }\r\n this._stateJurisdictionService.loading(false);\r\n\r\n try {\r\n await this._messageModalService.confirm(e.error.message, `Confirm ${descriptor.name} Exception`);\r\n } catch (cancel) {\r\n // revert the cell value\r\n params.node.setDataValue(params.column.getColId(), params.value);\r\n return await Promise.reject(e);\r\n }\r\n\r\n this._stateJurisdictionService.loading(true);\r\n\r\n updateModel.force = true;\r\n result = await this._stateJurisdictionService.updateDescriptor(updateModel);\r\n } finally {\r\n this._stateJurisdictionService.loading(false);\r\n }\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n await this._gridDataSource.updateRow(\r\n y => {\r\n const rowModel = y.data as Compliance.AssessorCommandCenterModel;\r\n return rowModel && rowModel.assessorId === result.assessorId;\r\n },\r\n () => {\r\n return Promise.resolve(result);\r\n });\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","import { Component, ViewChild, ElementRef } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { BehaviorSubject } from 'rxjs';\r\n\r\nexport interface ICellRendererParamsForDropdowns extends ICellRendererParams {\r\n editMode$: BehaviorSubject;\r\n canEdit: (params: ICellRendererParamsForDropdowns) => boolean;\r\n isDisabled: (params: ICellRendererParamsForDropdowns) => boolean;\r\n dropdownItems: any[];\r\n name: string;\r\n valueField: string;\r\n allowNull: boolean;\r\n originalValue: any;\r\n displayGetter: (dropdownItem: any) => string;\r\n change: (params: ICellRendererParamsForDropdowns) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'supplemental-information-cell-renderer',\r\n template: `
\r\n
{{ getDisplayValue() }}
\r\n
\r\n \r\n
\r\n
`\r\n})\r\nexport class DropdownCellRenderer implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForDropdowns;\r\n editMode: boolean = false;\r\n isHovering: boolean;\r\n @ViewChild('outerDiv', { read: ElementRef, static: true }) outerDiv: ElementRef;\r\n\r\n agInit(params: ICellRendererParamsForDropdowns): void {\r\n this.params = params;\r\n this.editMode = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onModelChange(value: any) {\r\n this.params.originalValue = this.params.data[this.params.colDef.field];\r\n this.params.data[this.params.colDef.field] = value;\r\n this.params.change(this.params);\r\n }\r\n\r\n mouseover($event) {\r\n this.isHovering = this.editMode && this.params.canEdit(this.params);\r\n }\r\n\r\n mouseout($event) {\r\n if (this.editMode && this.params.canEdit(this.params) && $event.relatedTarget) {\r\n // protect against clicks on inner children\r\n let parent = $event.relatedTarget.parentElement;\r\n while (parent) {\r\n if (parent === this.outerDiv.nativeElement) {\r\n return;\r\n }\r\n parent = parent.parentElement;\r\n }\r\n this.isHovering = false;\r\n }\r\n }\r\n\r\n getDisplayValue(): string {\r\n if (!this.params.data) {\r\n return null;\r\n }\r\n const dropdownItem = this.params.dropdownItems.find(x => x[this.params.valueField] === this.params.data[this.params.colDef.field]);\r\n return (dropdownItem && this.params.displayGetter(dropdownItem)) || null;\r\n }\r\n\r\n isInherited(): boolean {\r\n if (!this.params.data) {\r\n return false;\r\n }\r\n if (this.params.originalValue && (this.params.originalValue !== this.params.data[this.params.colDef.field])) {\r\n return false;\r\n } \r\n if (this.params.data[this.params.colDef.field + 'Source']) {\r\n const sourceType = this.params.data[this.params.colDef.field + 'Source'];\r\n if (sourceType === Compliance.SupplementalInformationValueSource.ParentCompanyDefault || \r\n (sourceType !== Compliance.SupplementalInformationValueSource.CompanyStateSpecific && \r\n this.params.data['state'] !== 'Default')) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n }\r\n\r\n isOverride(): boolean {\r\n if (this.params.data && !this.params.data.stateId) {\r\n return false;\r\n }\r\n if (this.params.originalValue && (this.params.originalValue !== this.params.data[this.params.colDef.field])) {\r\n return true;\r\n } else {\r\n return (!this.isInherited());\r\n }\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Supplemental Information\r\n \r\n

\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Available Fields

\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { InstanceRights, RestrictService } from '../../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { ColDef, GridApi, GridReadyEvent, GridOptions, CellValueChangedEvent, ITooltipParams } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridTextCellEditor } from '../../AgGrid';\r\nimport { StateService } from '../../../Common/States/States.Service';\r\nimport { SupplementalInformationRepository } from '../../Repositories';\r\nimport { AgGridFilterParams } from '../../AgGrid';\r\nimport { DropdownCellRenderer, ICellRendererParamsForDropdowns } from './agGridDropdownCellRenderer.component';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { TextCellEditorParams } from '../../AgGrid/CellEditors/agGridTextCellEditor.component';\r\n\r\n@Component({\r\n selector: 'supplemental-information-sheet',\r\n templateUrl: './supplementalInformationSheet.component.html',\r\n styleUrls: ['./supplementalInformationSheet.component.scss']\r\n})\r\nexport class SupplementalInformationSheetComponent implements OnInit {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _supplementalInformationRepository: SupplementalInformationRepository,\r\n private readonly _stateService: StateService,\r\n private readonly _navigationService: NavigationService\r\n ) { }\r\n\r\n private _companyId: number;\r\n private _gridApi: GridApi;\r\n private _supplementaryInformationOptions: Compliance.SupplementalInformationLookupModel[];\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n stateFilterType: string = 'ALL';\r\n isInitialized: boolean = false;\r\n canEdit: boolean = false;\r\n editMode: boolean = false;\r\n isDirty: boolean = false;\r\n refreshing: boolean;\r\n company: Weissman.Model.Domain.Company;\r\n selectedCompanyId: number;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onCellValueChanged: this._onAgCellValueChanged.bind(this),\r\n singleClickEdit: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withoutCellEditingStoppedOnGridLostFocus()\r\n .build();\r\n\r\n fieldMap = [\r\n {'fieldName': 'fein', 'labelName': 'FEIN', 'isSelected': true, 'optionType': null, mask: '00-0000000'},\r\n {'fieldName': 'stin', 'labelName': 'STIN', 'isSelected': true, 'optionType': null},\r\n {'fieldName': 'naics', 'labelName': 'NAICS', 'isSelected': true, 'optionType': null},\r\n {'fieldName': 'salesTaxNumber', 'labelName': 'Sales Tax Number', 'isSelected': false, 'optionType': null},\r\n {'fieldName': 'inventoryCostMethodId', 'labelName': 'Inventory Cost Method', 'isSelected': false, 'optionType': Compliance.SupplementalInformationLookupTypeEnum.InventoryCostMethod},\r\n {'fieldName': 'inventoryAccountingMethodId', 'labelName': 'Inventory Accounting Method', 'isSelected': false, 'optionType': Compliance.SupplementalInformationLookupTypeEnum.InventoryAccountingMethod},\r\n {'fieldName': 'organizationTypeId', 'labelName': 'Organization Type', 'isSelected': true, 'optionType': Compliance.SupplementalInformationLookupTypeEnum.Organization}\r\n ];\r\n\r\n async ngOnInit(): Promise {\r\n this._companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n this.company = await this._companyService.load(this._companyId, false, false);\r\n\r\n if (!(this.company.ppReturnPreparationAllowed && this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, this.company.instanceID))) {\r\n this._routerService.go('unauthorizedAccess', {});\r\n return Promise.resolve();\r\n }\r\n\r\n this.breadcrumbs.push({\r\n name: this.company.companyName,\r\n target: 'company',\r\n options: { companyId: this.company.companyID }\r\n });\r\n\r\n const result = await Promise.all([\r\n this._restrictService.hasCompanyPermission(this._companyId, Core.AccessRightsEnum.Write),\r\n lastValueFrom(this._supplementalInformationRepository.getOptions())\r\n ]);\r\n\r\n this._supplementaryInformationOptions = result[1];\r\n\r\n this.canEdit = result[0];\r\n\r\n this.isInitialized = true;\r\n this.selectedCompanyId = this._companyId;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this._setColumns();\r\n this._setRowData();\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n supplementalDataChanged(params: ICellRendererParamsForDropdowns): void {\r\n params.data.isDirty = true;\r\n this.isDirty = true;\r\n }\r\n\r\n async stateFilterTypeChanged(): Promise {\r\n this._setRowData();\r\n }\r\n\r\n async selectedCompanyIdChanged(): Promise {\r\n await this._setRowData();\r\n }\r\n\r\n fieldMapChanged(): void {\r\n this._setColumns();\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n edit(): void {\r\n this.editMode = true;\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n }\r\n\r\n async refresh(): Promise {\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n const rowsToSave = [];\r\n const topRow = this._gridApi.getFloatingTopRow(0);\r\n if (topRow && topRow.data.isDirty) {\r\n rowsToSave.push(topRow.data);\r\n }\r\n this._gridApi.getModel().forEachNode(r => {\r\n if (r.data.isDirty) {\r\n rowsToSave.push(r.data);\r\n }\r\n });\r\n\r\n await lastValueFrom(this._supplementalInformationRepository.update(this.selectedCompanyId, rowsToSave));\r\n\r\n await this._setRowData();\r\n this._navigationService.disableNavWarning();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async cancel(): Promise {\r\n this.editMode = false;\r\n await this._setRowData();\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n private _onAgCellValueChanged(event: CellValueChangedEvent) {\r\n this.isDirty = true;\r\n event.data.isDirty = true;\r\n if (event.newValue === '') {\r\n event.newValue = null;\r\n }\r\n }\r\n\r\n private _setColumns() {\r\n const editableColumns: ColDef[] = this.fieldMap.filter((fm) => fm.isSelected).map((fm) => {\r\n const columnDef: ColDef = {\r\n headerName: fm.labelName,\r\n field: fm.fieldName,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n tooltipValueGetter: (params: ITooltipParams) => {\r\n let tip = '';\r\n if (params.data && params.colDef) {\r\n const sourceType = params.data[`${params.colDef.field }Source`];\r\n if (sourceType === Compliance.SupplementalInformationValueSource.CompanyDefault) {\r\n tip = 'Saved value found from this company\\'s default setting';\r\n } else if (sourceType === Compliance.SupplementalInformationValueSource.ParentCompanyDefault) {\r\n tip = 'Saved value found from parent company\\'s default setting';\r\n } else if (sourceType === Compliance.SupplementalInformationValueSource.CompanyStateSpecific) {\r\n tip = 'Saved value found from this company\\'s state-specific setting';\r\n } else if (sourceType === Compliance.SupplementalInformationValueSource.ParentCompanyStateSpecific) {\r\n tip = 'Saved value found from parent company\\'s state-specific setting';\r\n } else {\r\n tip = 'No value currently saved for this.';\r\n }\r\n }\r\n return tip;\r\n }\r\n };\r\n if (fm.optionType) {\r\n columnDef.cellRendererFramework = DropdownCellRenderer;\r\n columnDef.cellRendererParams = {\r\n canEdit: (x) => this.editMode,\r\n isDisabled: (x) => false,\r\n dropdownItems: this._supplementaryInformationOptions.filter(x => x.supplementalInformationLookupType === fm.optionType),\r\n name: 'schedule',\r\n valueField: 'supplementalInformationLookupId',\r\n allowNull: true,\r\n change: this.supplementalDataChanged.bind(this),\r\n displayGetter: (item: Compliance.FormRevisionScheduleModel) => `${item.name}`\r\n } as ICellRendererParamsForDropdowns;\r\n } else {\r\n columnDef.cellClass = (params) => {\r\n if (params.data && !params.data.stateId) {\r\n return '';\r\n }\r\n if (params.data.originalValues[params.colDef.field] !== params.data[params.colDef.field]) {\r\n return 'value-override';\r\n } else if (params.data && params.data[`${fm.fieldName }Source`]) {\r\n const sourceType = params.data[`${fm.fieldName }Source`];\r\n //copied from dropdown renderer\r\n if (sourceType === Compliance.SupplementalInformationValueSource.ParentCompanyDefault ||\r\n (sourceType !== Compliance.SupplementalInformationValueSource.CompanyStateSpecific &&\r\n params.data['state'] !== 'Default')) {\r\n return 'value-inherited';\r\n } else {\r\n return 'value-override';\r\n }\r\n }\r\n return '';\r\n };\r\n columnDef.cellEditorFramework = AgGridTextCellEditor;\r\n columnDef.cellEditorParams = {\r\n showOverrideDuringEdit: true,\r\n hasOverride: (params: TextCellEditorParams, currentValue: string) => {\r\n if (params.data && !params.data.stateId) {\r\n return false;\r\n }\r\n return (params.data.originalValues[params.colDef.field] !== params.data[params.colDef.field] || params.data.originalValues[params.colDef.field] !== currentValue);\r\n }\r\n };\r\n if (fm.mask) {\r\n columnDef.cellEditorParams = {\r\n ...columnDef.cellEditorParams,\r\n ...{ inputMask: () => fm.mask }\r\n };\r\n }\r\n columnDef.editable = () => this.editMode;\r\n }\r\n return columnDef;\r\n });\r\n const columns : ColDef[]= [\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n width: 50,\r\n },\r\n ...editableColumns\r\n ];\r\n this._gridApi.setColumnDefs(columns);\r\n }\r\n\r\n private async _getData(): Promise {\r\n this.refreshing = true;\r\n this.editMode = false;\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n try {\r\n const supplementalList = await lastValueFrom(this._supplementalInformationRepository.getList(this.selectedCompanyId));\r\n\r\n let result = [];\r\n const defaultRow = supplementalList.find(s => s.stateId === null);\r\n if (this.stateFilterType === 'ALL') {\r\n result = (await this._stateService.getSummary()).map(state => {\r\n const stateRow = supplementalList.find(s => s.stateId === state.stateID);\r\n if (stateRow) {\r\n return stateRow;\r\n }\r\n\r\n return { ...defaultRow, stateId: state.stateID, state: state.abbr};\r\n });\r\n\r\n } else if (this.stateFilterType === 'OVERRIDES') {\r\n result = supplementalList.filter(s => s.stateId !== null);\r\n } else if (this.stateFilterType === 'SITES') {\r\n const activeStates = await this._companyService.getStatesWithSites(this._companyId, true, false);\r\n result = (await this._stateService.getSummary()).filter(state => activeStates.includes(state.abbr)).map(state => {\r\n const stateRow=supplementalList.find(s => s.stateId === state.stateID);\r\n if (stateRow) {\r\n return stateRow;\r\n }\r\n\r\n return { ...defaultRow, stateId: state.stateID, state: state.abbr};\r\n });\r\n }\r\n\r\n // Store original values for override comparison\r\n result = result.map(x => ({...x, ...{ originalValues: {...x} }}));\r\n\r\n let defRowToShow: any;\r\n if (defaultRow) {\r\n defRowToShow = defaultRow;\r\n } else {\r\n defRowToShow = {\r\n stateId: null,\r\n state: 'Default'\r\n };\r\n }\r\n this._gridApi.setRowData(result);\r\n this._gridApi.setPinnedTopRowData([ defRowToShow ]);\r\n } finally {\r\n busyRef.hide();\r\n this.refreshing = false;\r\n }\r\n }\r\n\r\n private async _setRowData(): Promise {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n await this._getData();\r\n this.isDirty = false;\r\n }\r\n}\r\n","
\r\n \r\n
\r\n \r\n
{{params.engagement.name}}
\r\n
\r\n
\r\n \r\n\t\t\t\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
0\">\r\n
\r\n
Existing CSRs Assigned
\r\n
\r\n \r\n
\r\n \r\n {{getPropTypeAbbr(csr)}}\r\n {{csr.name}}\r\n
\r\n
\r\n
\r\n
\r\n Changing the Account Handler will reassign the above CSRs from {{params.engagement.accountHandler.firstName}} {{params.engagement.accountHandler.lastName}} ({{params.engagement.accountHandler.teamName}}) to your new selection\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { UntypedFormGroup, Validators, UntypedFormBuilder } from '@angular/forms';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Subject } from 'rxjs';\r\nimport { BusyIndicatorService } from '../Busy-Indicator';\r\nimport { BulkSaveExceptionResult } from '../Client-Services/Exceptions/client-service-exception.models';\r\nimport { IWeissmanModalComponent } from '../Compliance/WeissmanModalService';\r\nimport { Constants } from '../constants.new';\r\nimport { ConsultingEngagementModalParams } from './consultingEngagements.component';\r\nimport { ConsultingEngagementsRepository } from './consultingEngagements.repository';\r\n\r\n@Component({\r\n selector: 'consulting-engagement-modal',\r\n templateUrl: './consultingEngagementModal.component.html'\r\n})\r\n\r\nexport class ConsultingEngagementModalComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _engagementsRepository: ConsultingEngagementsRepository,\r\n private readonly constants: Constants,\r\n private _toastrService: ToastrService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n engagementForm: UntypedFormGroup;\r\n params: ConsultingEngagementModalParams;\r\n result: any;\r\n assignedUserTeam: Core.UserTeamModel = {} as Core.UserTeamModel;\r\n csrs: Core.ConsultingEngagementCSR[] = [];\r\n accountHandlerChanged: boolean = false;\r\n isLoading: boolean = false;\r\n instanceId: number;\r\n assignedGroups: Core.GroupModel[] = [];\r\n availableGroups: Core.GroupModel[] = [];\r\n selectedGroupId: number;\r\n addingNewGroup: boolean = false;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n async ngOnInit(): Promise {\r\n this.isLoading = true;\r\n this.engagementForm = this._fb.group({\r\n accountHandler: [null, Validators.required]\r\n });\r\n\r\n const userGroups = await this._engagementsRepository.getUserGroups();\r\n\r\n //if existing engagement - check for csr's already assigned\r\n if(this.params.engagement.accepted) {\r\n this.assignedUserTeam = this.transformAccountHandler(this.params.engagement.accountHandler);\r\n\r\n const engagementInfo = await this._engagementsRepository.getEngagementInfo(this.params.engagement.consultingEngagementId);\r\n\r\n this.csrs = engagementInfo.consultingEngagementCSRs;\r\n\r\n this.assignedGroups = this._sortUserGroups(engagementInfo.userGroups);\r\n this.availableGroups = this._sortUserGroups(userGroups.filter(x => !engagementInfo.userGroups.find(y => y.groupID === x.groupID)));\r\n } else {\r\n this.availableGroups = this._sortUserGroups(userGroups);\r\n }\r\n\r\n this.isLoading = false;\r\n }\r\n\r\n //TODO: some properties on the AccountHandlerResponse class don't match the UserTeamMember class - might want to return one directly\r\n transformAccountHandler (accountHandler: Core.AccountHandlerResponse): Core.UserTeamModel {\r\n return {\r\n firstName: accountHandler.firstName,\r\n lastName: accountHandler.lastName,\r\n userID: accountHandler.userId as string,\r\n teamID: accountHandler.teamId,\r\n teamName: accountHandler.teamName\r\n } as unknown as Core.UserTeamModel;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n getPropTypeAbbr(responsibility): string {\r\n const propertyType : any = _.find(Object.values(this.constants.PropertyTypes), { id: responsibility.propertyTypeId });\r\n return propertyType.propTypeAbbr;\r\n }\r\n\r\n setNewUser(newUser: Core.UserTeamModel) {\r\n this.assignedUserTeam = newUser;\r\n\r\n this.accountHandlerChanged = this.params.engagement.accountHandler && this.assignedUserTeam && (this.assignedUserTeam.teamID !== this.params.engagement.accountHandler.teamId || this.assignedUserTeam.userID !== this.params.engagement.accountHandler.userId);\r\n }\r\n\r\n getSaveLabel():string {\r\n if(this.params.engagement.accepted === false) {\r\n return 'Accept';\r\n }\r\n else {\r\n return 'Save';\r\n }\r\n\r\n }\r\n\r\n async saveEngagement(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating consulting engagement' });\r\n\r\n const engagementRequest : Core.ConsultingEngagementDetails = {\r\n accountHandlerTeamId: this.assignedUserTeam.teamID,\r\n accountHandlerUserId: this.assignedUserTeam.userID,\r\n consultingEngagementId: this.params.engagement.consultingEngagementId,\r\n userGroupIds: this.assignedGroups.map(x => x.groupID)\r\n };\r\n\r\n try {\r\n //new engagement\r\n if(this.params.engagement.accepted === false) {\r\n this.result = await this._engagementsRepository.accept(engagementRequest);\r\n this._toastrService.success(`Consulting engagement request from ${this.params.engagement.name} accepted successfully.`);\r\n }\r\n //existing engagement\r\n else {\r\n this.result = await this._engagementsRepository.update(engagementRequest);\r\n const hasErrors = this.handleUpdateErrors(this.result.results);\r\n\r\n if(!hasErrors)\r\n {\r\n if (this.result.longRunningProcessId)\r\n {\r\n this._toastrService.success('This change has requested a large number of updates to tasks. They are being run in the background, and you\\'ll be notified when they are done.');\r\n }\r\n else\r\n {\r\n this._toastrService.success(`Consulting engagement with ${this.params.engagement.name} updated successfully.`);\r\n }\r\n }\r\n }\r\n } finally {\r\n busyRef.hide();\r\n }\r\n this.cancel();\r\n }\r\n\r\n handleUpdateErrors(updateInfo: Core.BulkExceptionSetResult[]) : boolean {\r\n let anyErrors = false;\r\n\r\n if(!!updateInfo && updateInfo.length > 0)\r\n {\r\n const isNotAuthorized = (x: BulkSaveExceptionResult) => !x.isAuthorized;\r\n const hasErrors = (x: BulkSaveExceptionResult) => !!x.errorMessage;\r\n\r\n if (_.every(updateInfo, isNotAuthorized)) {\r\n this._toastrService.error('You are not authorized to perform this operation');\r\n anyErrors = true;\r\n }\r\n else if (_.some(updateInfo, isNotAuthorized)) {\r\n this._toastrService.error('Some exceptions could not be saved because you are not authorized to perform this operation');\r\n anyErrors = true;\r\n }\r\n\r\n if (_.every(updateInfo, hasErrors)) {\r\n this._toastrService.error('There was an unexpected error processing your request');\r\n anyErrors = true;\r\n }\r\n else if (_.some(updateInfo, hasErrors)) {\r\n this._toastrService.error('Some exceptions could not be saved because there was an error processing your request');\r\n anyErrors = true;\r\n }\r\n }\r\n\r\n return anyErrors;\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n deleteUserGroup(group: Core.GroupModel) {\r\n const index = this.assignedGroups.indexOf(group);\r\n this.assignedGroups.splice(index, 1);\r\n this.availableGroups.push(group);\r\n\r\n this._sortUserGroups(this.assignedGroups);\r\n this._sortUserGroups(this.availableGroups);\r\n }\r\n\r\n selectUserGroupToAdd() {\r\n this.addingNewGroup = true;\r\n }\r\n\r\n addUserGroup() {\r\n const group = this.availableGroups.find(x => x.groupID === +this.selectedGroupId);\r\n\r\n this.assignedGroups.push(group);\r\n const groupIndex = this.availableGroups.indexOf(group);\r\n this.availableGroups.splice(groupIndex, 1);\r\n\r\n this._sortUserGroups(this.assignedGroups);\r\n this._sortUserGroups(this.availableGroups);\r\n\r\n this.selectedGroupId = null;\r\n }\r\n\r\n cancelAddUserGroup() {\r\n this.selectedGroupId = null;\r\n this.addingNewGroup = false;\r\n }\r\n\r\n private _sortUserGroups(userGroups: Core.GroupModel[]) : Core.GroupModel[] {\r\n return userGroups.sort((x, y) => x.name.localeCompare(y.name));\r\n }\r\n}\r\n","
\r\n
\r\n

Consulting Engagements

\r\n
\r\n \r\n
\r\n
\r\n There are currently no consulting engagements\r\n
\r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
CompanyActions
\r\n {{engagement.name}}\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Subject } from 'rxjs';\r\nimport { MessageModalService } from '../UI-Lib/Message-Box/messageModal.service';\r\nimport { WeissmanModalService } from '../Compliance/WeissmanModalService';\r\nimport { ConsultingEngagementModalComponent } from './consultingEngagementModal.component';\r\nimport { ConsultingEngagementsRepository } from './consultingEngagements.repository';\r\n\r\nexport interface ConsultingEngagementModalParams {\r\n engagement: Core.ConsultingEngagementResponse\r\n}\r\n\r\n@Component({\r\n selector: 'consulting-engagements',\r\n templateUrl: './consultingEngagements.component.html',\r\n styleUrls: ['./consultingEngagements.component.scss']\r\n})\r\n\r\nexport class ConsultingEngagementsComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _consultingEngagementsRepository: ConsultingEngagementsRepository,\r\n private readonly _modalService : WeissmanModalService,\r\n private readonly _messageModalService : MessageModalService,\r\n private _toastrService: ToastrService) {\r\n }\r\n\r\n params: ConsultingEngagementModalParams;\r\n result: any;\r\n isLoading: boolean = true;\r\n\r\n engagements: Core.ConsultingEngagementResponse[] = [];\r\n changesMade: boolean = false;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n async ngOnInit(): Promise {\r\n this.isLoading = true;\r\n this.engagements = await this._consultingEngagementsRepository.getList();\r\n\r\n this.engagements.sort((x, y) => x.name.localeCompare(y.name));\r\n\r\n this.isLoading = false;\r\n }\r\n\r\n async openEngagementModal(engagement) {\r\n const params: ConsultingEngagementModalParams = {engagement: engagement};\r\n await this._modalService.showAsync(ConsultingEngagementModalComponent, params, 'modal-md');\r\n this.engagements = await this._consultingEngagementsRepository.getList();\r\n }\r\n\r\n async rejectInvitation(engagement): Promise {\r\n\r\n try {\r\n await this._messageModalService.confirm(`Are you sure you want to reject the consulting engagement invitation from ${engagement.name}?`);\r\n }\r\n catch (e) {\r\n return Promise.resolve();\r\n }\r\n this.isLoading = true;\r\n\r\n await this._consultingEngagementsRepository.delete(engagement.consultingEngagementId);\r\n this._toastrService.success(`Consulting engagement invitation from ${engagement.name} rejected.`);\r\n this.engagements = await this._consultingEngagementsRepository.getList();\r\n\r\n this.isLoading = false;\r\n }\r\n\r\n async cancelEngagement(engagement): Promise {\r\n\r\n try {\r\n await this._messageModalService.confirm(`Are you sure you want to cancel the consulting engagement with ${engagement.name}?`);\r\n }\r\n catch (e) {\r\n return Promise.resolve();\r\n }\r\n this.isLoading = true;\r\n\r\n try {\r\n await this._consultingEngagementsRepository.delete(engagement.consultingEngagementId);\r\n this._toastrService.success(`Consulting engagement with ${engagement.name} cancelled.`);\r\n this.engagements = await this._consultingEngagementsRepository.getList();\r\n } finally {\r\n this.isLoading = false;\r\n }\r\n }\r\n\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n // async acceptInvitation(contactId: number): Promise {\r\n // const busyRef = this._busyIndicatorService.show({ message: 'Accepting Invitation' });\r\n // try {\r\n // var success = await this._instanceRepository.acceptInvite(contactId);\r\n // if(success)\r\n // this._toastrService.success(`Invitation accepted.`);\r\n // this.statuses = await this._instanceRepository.getCurrentUsersContactInviteStatuses();\r\n // this.changesMade = true;\r\n // } finally {\r\n // busyRef.hide();\r\n // }\r\n // }\r\n}\r\n","import { GridsterItem } from 'angular-gridster2';\r\nimport { EventEmitter } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\n\r\nexport class Dashboard {\r\n constructor() {\r\n this.userWidgets = [];\r\n }\r\n\r\n firstName: string;\r\n userWidgets: UserWidget[];\r\n availableWidgets: Widget[];\r\n}\r\n\r\nexport class UserWidget implements GridsterItem {\r\n userWidgetId: number;\r\n widget: Widget;\r\n x: number;\r\n y: number;\r\n rows: number;\r\n cols: number;\r\n minItemCols: number;\r\n minItemRows: number;\r\n useLightIcon: boolean;\r\n}\r\n\r\nexport class Widget {\r\n widgetId: number;\r\n name: string;\r\n title: string;\r\n refreshPolicy: number;\r\n isMultiInstance: boolean;\r\n canRefresh: boolean;\r\n hasSettings: boolean;\r\n height: number;\r\n width: number;\r\n}\r\n\r\nexport interface DataWidgetI {\r\n data$?: Observable;\r\n newParams?: EventEmitter;\r\n}\r\n\r\nexport class WidgetCache {\r\n data: any;\r\n params: any;\r\n}\r\n\r\nexport enum WidgetIds {\r\n AppealSavings = 1,\r\n QuickSearchButton = 2,\r\n StatesButton = 3,\r\n Calendar = 4,\r\n Shortcut = 5,\r\n PortfolioAnalysis = 6,\r\n PortfolioAnalysisSummary = 7,\r\n MyTasks = 8\r\n}\r\n\r\nexport enum RefreshPolicies {\r\n NoData = 1,\r\n NoCache = 2,\r\n InMemoryUI = 3\r\n}\r\n\r\nexport interface CalendarWidgetFieldIds {\r\n categories: CalendarWidgetFieldIdCategory[];\r\n}\r\n\r\nexport interface CalendarWidgetFieldIdCategory {\r\n type: number;\r\n columnIds: number[];\r\n availableDepths?: number[];\r\n columnsToKeep?: number[];\r\n}\r\n\r\n\r\n","export class CalendarMonth {\r\n constructor() {\r\n this.weeks = [];\r\n }\r\n\r\n weeks: CalendarWeek[];\r\n name: string;\r\n year: number;\r\n}\r\n\r\nexport class CalendarWeek {\r\n constructor() {\r\n this.days = [];\r\n\r\n for(let i=0; i< 7; i++) {\r\n this.days.push(new CalendarDay());\r\n }\r\n }\r\n\r\n days: CalendarDay[];\r\n weekNumber: number;\r\n}\r\n\r\nexport class CalendarDay {\r\n monthDay: number;\r\n eventTypeBlocks: EventTypeBlock[];\r\n weekdayAbbr: string;\r\n icons: string[];\r\n}\r\n\r\nexport class EventTypeBlock {\r\n dashboardCalendarEventType: number;\r\n events: DateEvent[];\r\n totalCount: number;\r\n}\r\n\r\nexport enum DashboardCalendarEventTypes {\r\n AppealDeadline = 1,\r\n AppealFormalHearing = 2,\r\n AppealInformalHearing = 3,\r\n AppealSubmitEvidence = 4,\r\n PaymentDueDate = 5,\r\n PPReturnComplianceDeadline = 6,\r\n MiscFilingComplianceDeadline = 7,\r\n FreeportComplianceDeadline = 8,\r\n AbatementComplianceDeadline = 9,\r\n PollutionControlComplianceDeadline = 10,\r\n AppealConfirmHearing = 11\r\n}\r\n\r\nexport class DateEvent {\r\n date: Date;\r\n stateAbbr: string;\r\n dashboardCalendarEventType: number;\r\n count: number;\r\n}\r\n\r\nexport class LegendBlock {\r\n title: string;\r\n count: number;\r\n dashboardCalendarEventType: number;\r\n eventTypeBlocks: EventTypeBlock[];\r\n}","import { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { GridsterItem } from 'angular-gridster2';\r\nimport * as _ from 'lodash';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { tap } from 'rxjs/operators';\r\nimport { UserSettingsService } from '../Account/userSettings.service';\r\nimport { FeatureFlagsService } from '../Common/FeatureFlags/feature-flags-service';\r\nimport { CalendarWidgetFieldIds, Dashboard, RefreshPolicies, UserWidget, WidgetCache } from './dashboard.model';\r\nimport { DashboardCalendarEventTypes } from './Widgets/Calendar-Widget/calendar.widget.model';\r\n\r\ninterface WidgetDataLookup {\r\n [userWidgetId: number]: WidgetCache;\r\n}\r\n@Injectable()\r\nexport class DashboardDataService {\r\n constructor(private readonly http: HttpClient,\r\n private readonly _userSettingsService: UserSettingsService,\r\n private readonly _featureFlagsService: FeatureFlagsService\r\n ){}\r\n\r\n RefreshPolicies = RefreshPolicies;\r\n\r\n readonly eventTypeTitleMap = new Map([\r\n [DashboardCalendarEventTypes.AbatementComplianceDeadline, 'Compliance Filing'], // used to be Abatement filing, but now it represents all compliance filings\r\n [DashboardCalendarEventTypes.FreeportComplianceDeadline, 'FreePort Filing'],\r\n [DashboardCalendarEventTypes.MiscFilingComplianceDeadline, 'Misc Filing'],\r\n [DashboardCalendarEventTypes.PPReturnComplianceDeadline, 'PP Return Filing'],\r\n [DashboardCalendarEventTypes.PollutionControlComplianceDeadline, 'Pollution Control Filing'],\r\n [DashboardCalendarEventTypes.AppealFormalHearing, 'Formal Hearing'],\r\n [DashboardCalendarEventTypes.AppealInformalHearing, 'Informal Hearing'],\r\n [DashboardCalendarEventTypes.AppealSubmitEvidence, 'Submit Evidence Date'],\r\n [DashboardCalendarEventTypes.AppealDeadline, 'Appeal Deadline'],\r\n [DashboardCalendarEventTypes.PaymentDueDate, 'Payment Due Date'],\r\n [DashboardCalendarEventTypes.AppealConfirmHearing, 'Confirm Hearing']\r\n ]);\r\n\r\n userWidgetResize$: Subject = new Subject();\r\n resizeGrid$: Subject = new Subject();\r\n showDashboardToggled$: Subject = new Subject();\r\n\r\n private widgetDataLookup: WidgetDataLookup = {};\r\n private widgetUrl: string = '/api/dashboard/userwidgets/';\r\n private readonly _showDashboardSettingName: string = 'Landing-Page';\r\n private readonly _showDashboardSettingGroupId: number = 24;\r\n\r\n\r\n getDashboard(): Promise {\r\n return lastValueFrom(this.http.get('/api/dashboard').pipe(\r\n tap(data => console.log(data))));\r\n }\r\n\r\n resetDashboard(): Promise {\r\n return lastValueFrom(this.http.put('/api/dashboard/reset', null));\r\n }\r\n\r\n addToDashboard(widgetId: number, firstPossiblePosition: GridsterItem): Promise {\r\n return lastValueFrom(this.http.post(this.widgetUrl, {\r\n widgetId: widgetId,\r\n y: firstPossiblePosition.y,\r\n x: firstPossiblePosition.x,\r\n rows: firstPossiblePosition.rows,\r\n cols: firstPossiblePosition.cols\r\n }));\r\n }\r\n\r\n removeFromDashboard(widgetId: number): Promise {\r\n return lastValueFrom(this.http.delete(this.widgetUrl + widgetId));\r\n }\r\n\r\n updateUserWidget(userWidget: UserWidget) {\r\n return lastValueFrom(this.http.put(this.widgetUrl + userWidget.userWidgetId,\r\n _.pick(userWidget, ['x', 'y', 'rows', 'cols']),\r\n { responseType: 'text' }));\r\n }\r\n\r\n async getWidgetData(userWidget: UserWidget, params?: object): Promise {\r\n if(!params && this.widgetDataLookup[userWidget.userWidgetId]) {\r\n return Promise.resolve(this.widgetDataLookup[userWidget.userWidgetId]);\r\n }\r\n\r\n let httpParams: HttpParams = new HttpParams();\r\n\r\n if(params) {\r\n Object.keys(params).forEach(function (key) {\r\n httpParams = httpParams.set(key, params[key]);\r\n });\r\n }\r\n\r\n const data = await lastValueFrom(this.http.get(this.widgetUrl + userWidget.userWidgetId, { params: httpParams }));\r\n const widgetCache = {\r\n data: data,\r\n params: params\r\n };\r\n\r\n if(userWidget.widget.refreshPolicy === RefreshPolicies.InMemoryUI && (!params || _.isEmpty(params))) {\r\n this.widgetDataLookup[userWidget.userWidgetId] = widgetCache;\r\n }\r\n\r\n return widgetCache;\r\n // let dataSub$ = this.http.get(this.widgetUrl + userWidget.userWidgetId, {params: httpParams}).pipe(\r\n // map(data => {\r\n // return {\r\n // data: data,\r\n // params: params\r\n // }\r\n // }))\r\n\r\n // dataSub$.subscribe((widgetCache: WidgetCache) => {\r\n // if(userWidget.widget.refreshPolicy === RefreshPolicies.InMemoryUI) {\r\n // this.widgetDataLookup[userWidget.userWidgetId] = widgetCache;\r\n // }\r\n // });\r\n\r\n // return dataSub$;\r\n }\r\n\r\n getWidgetSettings(userWidgetId: number): Promise {\r\n return lastValueFrom(this.http.get(`${this.widgetUrl + userWidgetId }/settings`));\r\n }\r\n\r\n saveWidgetSettings(userWidgetId: number, widgetSettings: object): Promise {\r\n return lastValueFrom(this.http.put(`${this.widgetUrl + userWidgetId }/settings`,\r\n _.omit(widgetSettings, 'version'),\r\n { responseType: 'text' }));\r\n }\r\n\r\n getShowDashBoardUserSetting(): boolean {\r\n const settings = this._userSettingsService.getSettingsByGroup(this._showDashboardSettingGroupId);\r\n const setting = _.find(settings, (x: any) => x.name === this._showDashboardSettingName);\r\n return setting ? setting.value : false;\r\n }\r\n\r\n async updateShowDashboardUserSetting(showDashboard: boolean): Promise {\r\n const settings = this._userSettingsService.getSettingsByGroup(this._showDashboardSettingGroupId);\r\n const setting = settings.find(x => x.name === this._showDashboardSettingName);\r\n const userSetting: any = {\r\n id: setting ? setting.id : 0,\r\n name: this._showDashboardSettingName,\r\n value: showDashboard,\r\n groupId: this._showDashboardSettingGroupId,\r\n folderId: Core.UserSettingFolder.Default\r\n };\r\n await this._userSettingsService.save(userSetting);\r\n\r\n this.showDashboardToggled$.next(showDashboard);\r\n }\r\n\r\n async getSmartAvFields(): Promise {\r\n return lastValueFrom(this.http.get(`${this.widgetUrl}SmartAvFields`)) as Promise;\r\n }\r\n\r\n async saveSmartAvFields(calendarWidgetFields: CalendarWidgetFieldIds): Promise {\r\n return lastValueFrom(this.http.put(`${this.widgetUrl}SmartAvFields`, calendarWidgetFields));\r\n }\r\n\r\n async getSmartAvFieldsDefault(): Promise {\r\n return lastValueFrom(this.http.get(`${this.widgetUrl}SmartAvFields/default`)) as Promise;\r\n }\r\n}\r\n","import { OnDestroy } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\n\r\nexport type Constructor = new (...args: any[]) => T;\r\ninterface UnsubscribeMixin { destroy$: Subject; }\r\n\r\n/**\r\n * Mixin for auto unsubscribing from Component subscriptions\r\n *\r\n * Example Usage:\r\n *\r\n * export class MyComponent extends UnsubscribeMixin() implements OnInit {\r\n * constructor(private readonly myService: MyService) {super()}\r\n *\r\n * ngOnInit():void {\r\n * this.myService.mySubscription$.pipe(takeUntil(this.destroy$)).subscribe(x => console.log(x));\r\n * }\r\n * }\r\n *\r\n * The mixin provides a subject that can be used in the takeUntil pipe that will be called when the component is destroyed\r\n *\r\n * If you need to do additional functionality in OnDestroy within your component, place the following line at the top of ngOnDestroy\r\n *\r\n * ngOnDestroy(): void {\r\n * super['ngOnDestroy'] && super['ngOnDestroy']();\r\n * // Your code\r\n * }\r\n *\r\n * @param base\r\n */\r\nexport const UnsubscribeMixin = (base: T = class { } as T): Constructor => {\r\n return class extends base implements OnDestroy {\r\n public readonly destroy$: Subject = new Subject();\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n };\r\n};\r\n","import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';\r\nimport { DataWidgetI, WidgetCache } from '../dashboard.model';\r\nimport { lastValueFrom, Observable } from 'rxjs';\r\nimport { HttpParams, HttpClient } from '@angular/common/http';\r\nimport { AdvancedSearchPersistenceService } from '../../Search/Advanced/advancedSearchPersistence.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { SmartSearchService } from '../../Search/Advanced/smartSearch.service';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\n\r\n\r\n@Component({\r\n selector: 'appeal-savings-widget',\r\n template: `\r\n \r\n
\r\n \r\n
\r\n
Appeal Savings YTD:
\r\n \r\n
\r\n \r\n
\r\n `\r\n})\r\nexport class AppealSavingsWidgetComponent implements OnInit, DataWidgetI {\r\n constructor(\r\n private readonly _http: HttpClient,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _advancedSearchService: SmartSearchService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) { }\r\n\r\n @Input() data$: Observable;\r\n @Output() newParams: EventEmitter = new EventEmitter();\r\n\r\n loading: boolean;\r\n data: any;\r\n\r\n ngOnInit() {\r\n this.data$.subscribe((widgetCache: WidgetCache) => {\r\n this.data = widgetCache.data;\r\n });\r\n }\r\n\r\n async goToSmart(year?: string) {\r\n let httpParams: HttpParams = new HttpParams();\r\n const currentYear: number = new Date().getFullYear();\r\n\r\n httpParams = year ? httpParams.set('year', year) : httpParams.set('year', currentYear.toString());\r\n\r\n this.loading = true;\r\n\r\n try {\r\n this._advancedSearchPersistenceService.clearSearchData();\r\n\r\n const data = await lastValueFrom(this._http.get('/api/search/Widget/Appealsavings', {params: httpParams}));\r\n this._advancedSearchPersistenceService.search = await this._advancedSearchService.returnSearch(data);\r\n this._advancedSearchPersistenceService.fromWidget = true;\r\n\r\n this._productAnalyticsService.logEvent('click-appeal-savings-widget', {\r\n 'appealSavingsWidget': year ? `y-${currentYear - (+year)}` : 'ytd'\r\n });\r\n\r\n this._upgradeNavigationServiceHandler.go('search', {});\r\n } finally {\r\n this.loading = false;\r\n }\r\n\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\n\r\n@Component({\r\n selector: 'quick-search-button-widget',\r\n template: `\r\n
\r\n

Quick Search

\r\n
\r\n
\r\n
Navigate to a Company, Site, or Parcel. Access Quick Search by clicking the magnifying glass icon in the upper right-hand corner, or press alt-q.
\r\n
\r\n
\r\n `,\r\n styleUrls: ['dashboard-widget.scss']\r\n})\r\nexport class QuickSearchButtonWidgetComponent {\r\n constructor(\r\n private readonly _navigationService: NavigationService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) { }\r\n\r\n openQuickSearch(resetFilter: boolean): void {\r\n this._productAnalyticsService.logEvent('initiate-quick-search', { initiateQuickSearch: 'dashboard' });\r\n this._productAnalyticsService.logEvent('click-quick-search-widget');\r\n this._navigationService.openQuickSearch(resetFilter, 'dashboard');\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { StateService } from '../../Common/States/States.Service';\r\n\r\n@Component({\r\n selector: 'states-button-widget',\r\n template: `\r\n
\r\n

States

\r\n
\r\n
\r\n
Here, you will find a list of states to which you can navigate. From there, access assessment classes, collectors, and assessors.
\r\n
\r\n
\r\n `,\r\n styleUrls: ['dashboard-widget.scss']\r\n})\r\nexport class StatesButtonWidgetComponent {\r\n constructor(\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _stateService: StateService\r\n ) { }\r\n\r\n goToStatePage(): void {\r\n this._stateService.navigatedFrom = 'dashboard';\r\n this._upgradeNavigationServiceHandler.go('states', {});\r\n }\r\n}\r\n","
\r\n
\r\n
d
\r\n
{{month.name}} ({{month.year}})
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
SMTWTFS
\r\n
\r\n {{day.monthDay}}\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n
\r\n
{{clickedDay.weekdayAbbr}}
\r\n
{{clickedDay.monthDay}}
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';\r\nimport { DataWidgetI, WidgetCache } from '../../dashboard.model';\r\nimport * as _ from 'lodash';\r\nimport { DashboardCalendarEventTypes, CalendarMonth, DateEvent, CalendarWeek, EventTypeBlock, CalendarDay, LegendBlock } from './calendar.widget.model';\r\nimport { lastValueFrom, Observable } from 'rxjs';\r\nimport { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { AdvancedSearchPersistenceService } from '../../../Search/Advanced/advancedSearchPersistence.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { SmartSearchService } from '../../../Search/Advanced/smartSearch.service';\r\nimport { TimerService } from '../../../UI-Lib/Utilities';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\n\r\nimport * as moment from 'moment';\r\n\r\n@Component({\r\n selector: 'calendar-widget',\r\n templateUrl: './calendar.widget.component.html',\r\n styleUrls: ['./calendar.widget.component.scss']\r\n})\r\nexport class CalendarWidgetComponent implements OnInit, DataWidgetI {\r\n constructor(\r\n private readonly _http: HttpClient,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _advancedSearchService: SmartSearchService,\r\n private readonly _timer: TimerService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n @Input() data$: Observable;\r\n @Output() newParams: EventEmitter = new EventEmitter();\r\n\r\n DashboardCalendarEventTypes = DashboardCalendarEventTypes;\r\n\r\n objectKeys = Object.keys;\r\n\r\n month: CalendarMonth;\r\n now: moment.Moment = moment();\r\n calendarDate: any = moment();\r\n clickedDay: CalendarDay;\r\n legendBlocks: LegendBlock [];\r\n loading: boolean = false;\r\n\r\n private readonly _EVENT_TYPE_TO_TEXT: Record = {\r\n [DashboardCalendarEventTypes.AbatementComplianceDeadline]: 'Abatement Compliance Deadline',\r\n [DashboardCalendarEventTypes.FreeportComplianceDeadline]: 'Freeport Compliance Deadline',\r\n [DashboardCalendarEventTypes.MiscFilingComplianceDeadline]: 'Misc Filing Compliance Deadline',\r\n [DashboardCalendarEventTypes.PPReturnComplianceDeadline]: 'PP Return Compliance Deadline',\r\n [DashboardCalendarEventTypes.PollutionControlComplianceDeadline]: 'Pollution Control Compliance Deadline',\r\n [DashboardCalendarEventTypes.AppealFormalHearing]: 'Appeal Formal Hearing',\r\n [DashboardCalendarEventTypes.AppealInformalHearing]: 'Appeal Informal Hearing',\r\n [DashboardCalendarEventTypes.AppealSubmitEvidence]: 'Appeal Submit Evidence',\r\n [DashboardCalendarEventTypes.AppealConfirmHearing]: 'Appeal Confirm Hearing',\r\n [DashboardCalendarEventTypes.AppealDeadline]: 'Appeal Deadline',\r\n [DashboardCalendarEventTypes.PaymentDueDate]: 'Payment Due Date'\r\n };\r\n\r\n ngOnInit() {\r\n this.data$.subscribe((widgetCache: WidgetCache) => {\r\n if(widgetCache.params && !_.isEmpty(widgetCache.params)) {\r\n this.calendarDate = moment([widgetCache.params.year, Number(widgetCache.params.month) - 1]);\r\n }\r\n const eventTypesByDay = this._groupEventTypesByDay(widgetCache.data);\r\n this.month = this._generateMonth(eventTypesByDay);\r\n this.legendBlocks = this._getLegendFromData(widgetCache.data);\r\n });\r\n }\r\n\r\n nextMonth(): void {\r\n this.calendarDate = this.calendarDate.add(1, 'month');\r\n\r\n this._monthChanged();\r\n }\r\n\r\n previousMonth(): void {\r\n this.calendarDate = this.calendarDate.subtract(1, 'month');\r\n\r\n this._monthChanged();\r\n }\r\n\r\n getIconClass(dashboardCalendarEventType: number): string {\r\n const className: string = 'small-icon-badge fa ';\r\n\r\n switch(dashboardCalendarEventType) {\r\n case DashboardCalendarEventTypes.AbatementComplianceDeadline:\r\n case DashboardCalendarEventTypes.FreeportComplianceDeadline:\r\n case DashboardCalendarEventTypes.MiscFilingComplianceDeadline:\r\n case DashboardCalendarEventTypes.PPReturnComplianceDeadline:\r\n case DashboardCalendarEventTypes.PollutionControlComplianceDeadline:\r\n return `${className }fa-file-text-o blue-badge`;\r\n\r\n case DashboardCalendarEventTypes.AppealFormalHearing:\r\n case DashboardCalendarEventTypes.AppealInformalHearing:\r\n case DashboardCalendarEventTypes.AppealSubmitEvidence:\r\n case DashboardCalendarEventTypes.AppealConfirmHearing:\r\n return `${className }fa-gavel gold-badge`;\r\n\r\n case DashboardCalendarEventTypes.AppealDeadline:\r\n return `${className }fa-clipboard red-badge`;\r\n\r\n case DashboardCalendarEventTypes.PaymentDueDate:\r\n return `${className }fa-dollar dollar-icon-fix green-badge`;\r\n }\r\n }\r\n\r\n getBackgroundColor(dashboardCalendarEventType: number): string {\r\n const className: string = 'event-type-block ';\r\n\r\n switch(dashboardCalendarEventType) {\r\n case DashboardCalendarEventTypes.AbatementComplianceDeadline:\r\n case DashboardCalendarEventTypes.FreeportComplianceDeadline:\r\n case DashboardCalendarEventTypes.MiscFilingComplianceDeadline:\r\n case DashboardCalendarEventTypes.PPReturnComplianceDeadline:\r\n case DashboardCalendarEventTypes.PollutionControlComplianceDeadline:\r\n return `${className }blue-badge`;\r\n\r\n case DashboardCalendarEventTypes.AppealFormalHearing:\r\n case DashboardCalendarEventTypes.AppealInformalHearing:\r\n case DashboardCalendarEventTypes.AppealSubmitEvidence:\r\n case DashboardCalendarEventTypes.AppealConfirmHearing:\r\n return `${className }gold-badge`;\r\n\r\n case DashboardCalendarEventTypes.AppealDeadline:\r\n return `${className }red-badge`;\r\n\r\n case DashboardCalendarEventTypes.PaymentDueDate:\r\n return `${className }green-badge`;\r\n }\r\n }\r\n\r\n async goToSmartFromPopover(eventTypeBlock: EventTypeBlock, stateAbbr?: string): Promise {\r\n let httpParams: HttpParams = new HttpParams();\r\n let url: string, analyticsEvent: string;\r\n\r\n httpParams = httpParams.set('eventTypeId', eventTypeBlock.dashboardCalendarEventType.toString());\r\n\r\n if(stateAbbr) {\r\n httpParams = httpParams.set('stateAbbr', stateAbbr);\r\n }\r\n\r\n if(this.clickedDay.monthDay) {\r\n let dateString: string = moment(eventTypeBlock.events[0].date).utc().toISOString();\r\n dateString = dateString.split('T')[0];\r\n httpParams = httpParams.set('date', encodeURI(dateString));\r\n\r\n analyticsEvent = 'click-task-icon-smart';\r\n\r\n url = '/api/search/Widget/Calendar';\r\n } else {\r\n httpParams = httpParams.set('month', this.calendarDate.format('M'));\r\n httpParams = httpParams.set('year', this.calendarDate.format('YYYY'));\r\n\r\n analyticsEvent = 'click-task-list-smart';\r\n\r\n url = '/api/search/Widget/Calendar/Legend';\r\n }\r\n\r\n this.loading = true;\r\n\r\n try {\r\n if(!this._advancedSearchService.checkIfAllFieldsPresent()) {\r\n await this._advancedSearchService.getAllFields(true);\r\n }\r\n const data = await lastValueFrom(this._http.get(url, {params: httpParams}));\r\n this._productAnalyticsService.logEvent(analyticsEvent);\r\n this._goToSmart(data);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n legendClicked(legendBlock: LegendBlock): void {\r\n this.loading = true;\r\n\r\n this._timer.setTimeout(() => {\r\n // TODO: This type really is wrong, but it didn't used to throw an error. My best guess is that\r\n // this broke on TypeScript 2.4.2->2.9.2 or @types/lodash 4.14.64->4.14.103\r\n //this.clickedDay = _.pick(legendBlock, 'dashboardCalendarEventType', 'eventTypeBlocks');\r\n this.clickedDay = (_ as any).pick(legendBlock, 'dashboardCalendarEventType', 'eventTypeBlocks');\r\n this._productAnalyticsService.logEvent('click-calendar-month-task', {\r\n calendarTaskIcon: this.clickedDay.eventTypeBlocks.map(x => this._EVENT_TYPE_TO_TEXT[x.dashboardCalendarEventType])\r\n });\r\n this.loading = false;\r\n });\r\n }\r\n\r\n isDayToday(day: CalendarDay): boolean {\r\n return this.month.name === this.now.format('MMMM') && day.monthDay === this.now.date() && this.month.year === this.now.year();\r\n }\r\n\r\n getEventTypeTitle(dashboardCalendarEventType, dayView?: boolean): string {\r\n switch(dashboardCalendarEventType) {\r\n case DashboardCalendarEventTypes.AbatementComplianceDeadline:\r\n if(dayView) {\r\n return 'Abatement Filing';\r\n }\r\n case DashboardCalendarEventTypes.FreeportComplianceDeadline:\r\n if(dayView) {\r\n return 'FreePort Filing';\r\n }\r\n case DashboardCalendarEventTypes.MiscFilingComplianceDeadline:\r\n if(dayView) {\r\n return 'Misc Filing';\r\n }\r\n case DashboardCalendarEventTypes.PPReturnComplianceDeadline:\r\n if(dayView) {\r\n return 'PP Return Filing';\r\n }\r\n case DashboardCalendarEventTypes.PollutionControlComplianceDeadline:\r\n return dayView ? 'Polution Control Filing' : 'Compliance Filing';\r\n case DashboardCalendarEventTypes.AppealFormalHearing:\r\n if(dayView) {\r\n return 'Formal Hearing';\r\n }\r\n case DashboardCalendarEventTypes.AppealInformalHearing:\r\n if(dayView) {\r\n return 'Informal Hearing';\r\n }\r\n case DashboardCalendarEventTypes.AppealSubmitEvidence:\r\n return dayView ? 'Submit Evidence Date' : 'Appeal Hearing';\r\n case DashboardCalendarEventTypes.AppealDeadline:\r\n return 'Appeal Deadline';\r\n case DashboardCalendarEventTypes.PaymentDueDate:\r\n return 'Payment Due Date';\r\n case DashboardCalendarEventTypes.AppealConfirmHearing:\r\n return 'Confirm Hearing';\r\n }\r\n }\r\n\r\n getPopoverPlacement(weekIdx: number, dayIdx: number): any {\r\n switch(dayIdx) {\r\n case 0:\r\n return 'right';\r\n case 6:\r\n return 'left';\r\n default:\r\n return weekIdx === 0 ? 'bottom' : 'top';\r\n }\r\n }\r\n\r\n dayClicked(day: CalendarDay): void {\r\n this._timer.setTimeout(() => {\r\n if(this.clickedDay) {\r\n return;\r\n }\r\n\r\n this.clickedDay = day;\r\n this._productAnalyticsService.logEvent('click-calendar-date-task', {\r\n calendarDateIcon: this.clickedDay.eventTypeBlocks.map(x => this._EVENT_TYPE_TO_TEXT[x.dashboardCalendarEventType])\r\n });\r\n });\r\n }\r\n\r\n private _getEventTypeSequence(dashboardCalendarEventType: number): number {\r\n switch(dashboardCalendarEventType) {\r\n case DashboardCalendarEventTypes.AbatementComplianceDeadline:\r\n case DashboardCalendarEventTypes.FreeportComplianceDeadline:\r\n case DashboardCalendarEventTypes.MiscFilingComplianceDeadline:\r\n case DashboardCalendarEventTypes.PPReturnComplianceDeadline:\r\n case DashboardCalendarEventTypes.PollutionControlComplianceDeadline:\r\n return 1;\r\n\r\n case DashboardCalendarEventTypes.AppealFormalHearing:\r\n case DashboardCalendarEventTypes.AppealInformalHearing:\r\n case DashboardCalendarEventTypes.AppealSubmitEvidence:\r\n case DashboardCalendarEventTypes.AppealConfirmHearing:\r\n return 2;\r\n\r\n case DashboardCalendarEventTypes.AppealDeadline:\r\n return 3;\r\n\r\n case DashboardCalendarEventTypes.PaymentDueDate:\r\n return 4;\r\n }\r\n }\r\n\r\n private _generateMonth(eventDays?: any): CalendarMonth {\r\n //Get weekday index of the first day of the current month\r\n //So if the 1st falls on a thursday, firstDayOfTheWeekIdx = 4\r\n const firstDayOfTheWeekIdx: number = this.calendarDate.subtract(this.calendarDate.date() - 1, 'days').day();\r\n\r\n const month = new CalendarMonth();\r\n let week: CalendarWeek = new CalendarWeek();\r\n\r\n for(let j = 0; j < this.calendarDate.daysInMonth(); j++) {\r\n //Incrementing the dayOfTheWeekIdx of each day of the month (0 - 6 repeating)\r\n const dayOfTheWeekIdx: number = (firstDayOfTheWeekIdx + j) % 7;\r\n\r\n //If we're back on Sunday, add that week to the calendar,\r\n //then start working with a new one\r\n //(checking j != 0 ensures we aren't adding a blank week if the month starts on a sunday)\r\n if(dayOfTheWeekIdx == 0 && j != 0) {\r\n month.weeks.push(week);\r\n week = new CalendarWeek();\r\n }\r\n\r\n week.days[dayOfTheWeekIdx].monthDay = j + 1;\r\n week.days[dayOfTheWeekIdx].weekdayAbbr = moment().day(dayOfTheWeekIdx).format('ddd');\r\n\r\n if(eventDays) {\r\n week.days[dayOfTheWeekIdx].eventTypeBlocks = eventDays[j + 1];\r\n week.days[dayOfTheWeekIdx].icons = _.chain(eventDays[j + 1])\r\n .groupBy((eventTypeBlock: EventTypeBlock) => {\r\n return this.getEventTypeTitle(eventTypeBlock.dashboardCalendarEventType);\r\n })\r\n .toArray()\r\n .sortBy([(eventTypeBlocks: EventTypeBlock[]) => {\r\n return this._getEventTypeSequence(eventTypeBlocks[0].dashboardCalendarEventType);\r\n }])\r\n .map((eventTypeBlocks: EventTypeBlock[]) => {\r\n return this.getIconClass(eventTypeBlocks[0].dashboardCalendarEventType);\r\n })\r\n .value();\r\n }\r\n }\r\n\r\n //We ran out of month days, so push the final week onto the month\r\n month.weeks.push(week);\r\n\r\n month.name = this.calendarDate.format('MMMM');\r\n month.year = this.calendarDate.year();\r\n\r\n return month;\r\n }\r\n\r\n private _goToSmart(data): void {\r\n this._advancedSearchService.returnSearch(data)\r\n .then((result) => {\r\n this._advancedSearchPersistenceService.search = result;\r\n this._advancedSearchPersistenceService.fromWidget = true;\r\n\r\n this._upgradeNavigationServiceHandler.go('search', {});\r\n });\r\n }\r\n\r\n private _getLegendFromData(data: {events: DateEvent[]}): LegendBlock [] {\r\n const legendBlocks = _.chain(data.events)\r\n .groupBy((event: DateEvent) => {\r\n return this.getEventTypeTitle(event.dashboardCalendarEventType);\r\n })\r\n .map((events: DateEvent[], key: string) => {\r\n const count = _.reduce(events, (sum, event: DateEvent) => {\r\n return sum + event.count;\r\n }, 0);\r\n\r\n return {\r\n title: key,\r\n count: count,\r\n dashboardCalendarEventType: events[0].dashboardCalendarEventType,\r\n eventTypeBlocks: this._createEventTypeBlocks(events)\r\n };\r\n })\r\n .sortBy([(legendBlock: LegendBlock) => {\r\n return this._getEventTypeSequence(legendBlock.dashboardCalendarEventType);\r\n }])\r\n .value();\r\n\r\n return legendBlocks;\r\n }\r\n\r\n private _monthChanged() {\r\n const params = {month: this.calendarDate.format('M'), year: this.calendarDate.format('YYYY')};\r\n this.newParams.emit(params);\r\n }\r\n\r\n private _groupEventTypesByDay(data: {events: DateEvent[]}) {\r\n const eventDays = _.chain(data.events)\r\n .groupBy((event: DateEvent) => {\r\n return moment(event.date).utc().date();\r\n })\r\n .mapValues((events: DateEvent[]) => this._createEventTypeBlocks(events))\r\n .value();\r\n\r\n return eventDays;\r\n }\r\n\r\n private _createEventTypeBlocks(events: DateEvent[]): EventTypeBlock[] {\r\n return _.chain(events)\r\n .groupBy('dashboardCalendarEventType')\r\n .map((events: DateEvent[], key: number) => {\r\n return {\r\n dashboardCalendarEventType: Number(key),\r\n events: this._aggregateStates(events),\r\n totalCount: _.reduce(events, (sum, event: DateEvent) => {\r\n return sum + event.count;\r\n }, 0)\r\n };\r\n })\r\n .sortBy([(eventTypeBlock: EventTypeBlock) => {\r\n return this._getEventTypeSequence(eventTypeBlock.dashboardCalendarEventType);\r\n }])\r\n .value();\r\n }\r\n\r\n //Need to get rid of duplicate states for legend\r\n private _aggregateStates(events: DateEvent[]): DateEvent[] {\r\n return _.chain(events)\r\n .groupBy('stateAbbr')\r\n .map((dateEvents: DateEvent[]) => {\r\n return _.reduce(dateEvents, (summedEvent: DateEvent, event: DateEvent) => {\r\n summedEvent.count += event.count;\r\n\r\n return summedEvent;\r\n }, {\r\n count: 0,\r\n dashboardCalendarEventType: dateEvents[0].dashboardCalendarEventType,\r\n stateAbbr: dateEvents[0].stateAbbr,\r\n date: dateEvents[0].date\r\n } as DateEvent);\r\n })\r\n .sortBy('stateAbbr')\r\n .value();\r\n }\r\n}\r\n","import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';\r\nimport { DataWidgetI, WidgetCache } from '../../dashboard.model';\r\nimport { Observable } from 'rxjs';\r\nimport { Shortcut } from './shortcut.widget.model';\r\nimport * as _ from 'lodash';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { ActionViewPersistenceService } from '../../../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { AdvancedSearchPersistenceService } from '../../../Search/Advanced/advancedSearchPersistence.service';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\n\r\n@Component({\r\n selector: 'shortcut-widget',\r\n template: `\r\n

\r\n Shortcuts\r\n {{title}}\r\n

\r\n
\r\n
\r\n
\r\n
\r\n

{{group.category}}

\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n `\r\n})\r\nexport class ShortcutWidgetComponent implements OnInit, DataWidgetI {\r\n constructor(\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) { }\r\n\r\n @Input() data$: Observable;\r\n @Output() newParams: EventEmitter = new EventEmitter();\r\n\r\n groupByType: boolean = false;\r\n shortcuts: Shortcut[];\r\n groupedShortcuts: {category: string, shortcuts: Shortcut[]}[];\r\n title: string;\r\n\r\n ngOnInit() {\r\n this.data$.subscribe((widgetCache: WidgetCache) => {\r\n this.groupByType = widgetCache.data.groupByType;\r\n this.title = widgetCache.data.title;\r\n\r\n if(this.groupByType) {\r\n this.groupedShortcuts = _.chain(widgetCache.data.shortcuts)\r\n .groupBy('searchType')\r\n .map((shortcuts: Shortcut[], searchType: string) => {\r\n return {\r\n category: this._getCategory(Number(searchType)),\r\n shortcuts: _.sortBy(shortcuts, [(item: Shortcut) => item.searchName.toUpperCase()])\r\n };\r\n })\r\n .value();\r\n } else {\r\n this.shortcuts = _.sortBy(widgetCache.data.shortcuts, [(item: Shortcut) => item.searchName.toUpperCase()]);\r\n }\r\n });\r\n }\r\n\r\n _getCategory(searchType: number): string {\r\n switch(searchType) {\r\n case 0:\r\n return 'SMART Searches';\r\n case 1:\r\n return 'Action Views';\r\n case 2:\r\n return 'Reports';\r\n }\r\n }\r\n\r\n goToShortcut(shortcut: Shortcut): void {\r\n let route: string,\r\n params: object,\r\n analyticsProperty: string;\r\n\r\n if(shortcut.searchType === 0) {\r\n route = 'search';\r\n params = {\r\n searchId: shortcut.savedSearchId,\r\n searchType: shortcut.isSystemSearch ? 0 : 1\r\n };\r\n analyticsProperty = 'smart';\r\n\r\n this._advancedSearchPersistenceService.clearSearchData();\r\n } else if(shortcut.searchType === 1) {\r\n route = 'actionview';\r\n params = {\r\n actionViewId: shortcut.savedSearchId,\r\n actionViewType: shortcut.isSystemSearch ? 0 : 1,\r\n displayType: shortcut.defaultDisplay\r\n };\r\n analyticsProperty = 'actionView';\r\n\r\n this._actionViewPersistenceService.clearSavedData();\r\n } else if(shortcut.searchType === 2) {\r\n route = 'reportmanager';\r\n params = {\r\n reportId: shortcut.savedSearchId,\r\n reportType: shortcut.isSystemSearch ? 0 : 1\r\n };\r\n analyticsProperty = 'reports';\r\n }\r\n\r\n this._productAnalyticsService.logEvent('click-shortcut-widget', {\r\n [analyticsProperty]: (shortcut.variantName) ? `${shortcut.searchName} - ${shortcut.variantName}` : shortcut.searchName\r\n });\r\n\r\n this._upgradeNavigationServiceHandler.go(route, params);\r\n }\r\n}\r\n","\r\n
\r\n

Shortcut Settings

\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
    \r\n
  • \r\n
    {{item.name}}
    \r\n
    \r\n
  • \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { DashboardDataService } from '../../dashboard.data.service';\r\nimport { ReportManagerService } from '../../../Reporting/Manager/report.manager.service';\r\nimport { ActionViewService } from '../../../Task/ActionView/action-view-service.upgrade';\r\nimport { ShortcutWidgetSettings } from './shortcut.widget.model';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { SavedSearchCategoryEnum } from '../../../constants.new';\r\nimport { SmartSearchService } from '../../../Search/Advanced/smartSearch.service';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'shortcut-widget-settings',\r\n templateUrl: './shortcut.widget.settings.component.html'\r\n})\r\nexport class ShortcutWidgetSettingsComponent implements OnInit {\r\n constructor(public bsModalRef: BsModalRef,\r\n private actionViewService: ActionViewService,\r\n private advancedSearchService: SmartSearchService,\r\n private reportManagerService: ReportManagerService,\r\n private dashboardDataService: DashboardDataService,\r\n private restrictService: RestrictService) { }\r\n\r\n userWidgetId: number;\r\n loading: boolean;\r\n settings: ShortcutWidgetSettings;\r\n actionViews: any[] = [];\r\n smarts: any[] = [];\r\n reports: any[] = [];\r\n selectedActionViews: any[] =[];\r\n selectedSmarts: any[] =[];\r\n selectedReports: any[] =[];\r\n addedShortcuts: any[] = [];\r\n onClose: any;\r\n canViewReports: boolean;\r\n\r\n async ngOnInit() {\r\n this.canViewReports = this.restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW) || this.restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT);\r\n this.loading = true;\r\n\r\n try {\r\n const result = await Promise.all([\r\n this.actionViewService.getCategories(),\r\n this.advancedSearchService.getSearchCategories(),\r\n this.reportManagerService.getReportCategories()\r\n ]);\r\n\r\n this._compileShortcutLists(result);\r\n\r\n this.settings = await this.dashboardDataService.getWidgetSettings(this.userWidgetId) as ShortcutWidgetSettings;\r\n\r\n this.addedShortcuts = _.chain(this.settings.savedSearchIds)\r\n .map((id: number) => {\r\n const av = _.find(this.actionViews, {actionViewID: id});\r\n const smart = _.find(this.smarts, {searchId: id});\r\n const report = _.find(this.reports, {reportID: id});\r\n\r\n return av || smart || report;\r\n })\r\n .filter(item => item)\r\n .sortBy([(item) => item.name.toUpperCase()])\r\n .value();\r\n\r\n this._removeAddedShortcutsFromLists();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n addShortcuts(): void {\r\n this.addedShortcuts = _.chain(this.addedShortcuts)\r\n .union(this.selectedActionViews)\r\n .union(this.selectedSmarts)\r\n .union(this.selectedReports)\r\n .sortBy([(item) => item.name.toUpperCase()])\r\n .value();\r\n\r\n this._removeAddedShortcutsFromLists();\r\n\r\n this.selectedActionViews = this.selectedReports = this.selectedSmarts = [];\r\n }\r\n\r\n removeShortcut(item): void {\r\n _.remove(this.addedShortcuts, item);\r\n\r\n if(item.searchId) {\r\n this.smarts.push(item);\r\n this.smarts = _.chain(this.smarts)\r\n .sortBy(['isSystemSearch', (x) => x.name.toUpperCase()])\r\n .reverse()\r\n .value();\r\n } else if(item.reportID) {\r\n this.reports.push(item);\r\n this.reports = _.sortBy(this.reports, [(x) => x.categoryId !== 100, (x) => x.name.toUpperCase()]);\r\n } else if(item.actionViewID) {\r\n this.actionViews.push(item);\r\n this.actionViews = _.chain(this.actionViews)\r\n .sortBy(['isSystemSearch', (x) => x.name.toUpperCase()])\r\n .reverse()\r\n .value();\r\n }\r\n }\r\n\r\n saveAndClose(): void {\r\n this.settings.savedSearchIds = _.map(this.addedShortcuts, item => {\r\n return item.searchId || item.reportID || item.actionViewID;\r\n });\r\n\r\n this.dashboardDataService.saveWidgetSettings(this.userWidgetId, this.settings)\r\n .then(() => {\r\n this.onClose(true);\r\n this.bsModalRef.hide();\r\n });\r\n }\r\n\r\n private _compileShortcutLists(result): void {\r\n this.actionViews = _.chain(result[0])\r\n .map('actionViewList')\r\n .flatten()\r\n .compact()\r\n .map((item: any) => {\r\n item.name = item.actionViewName;\r\n return item;\r\n })\r\n .sortBy(['isSystemSearch', (item) => item.name.toUpperCase()])\r\n .reverse()\r\n .value();\r\n\r\n this.smarts = _.chain(result[1])\r\n .map('searchList')\r\n .flatten()\r\n .compact()\r\n .map((item: any) => {\r\n item.name = item.searchName;\r\n return item;\r\n })\r\n .sortBy(['isSystemSearch', (item) => item.name.toUpperCase()])\r\n .reverse()\r\n .value();\r\n\r\n this.reports = _.chain(result[2])\r\n .map('reportList')\r\n .flatten()\r\n .compact()\r\n .filter((item: any) => !([\r\n SavedSearchCategoryEnum.ComplianceReport,\r\n SavedSearchCategoryEnum.ComplianceReturnReport,\r\n SavedSearchCategoryEnum.CompliancePackageReport,\r\n SavedSearchCategoryEnum.ComplianceCustomReport\r\n ].indexOf(item.categoryId) >= 0))\r\n .map((item: any) => {\r\n item.name = item.reportName;\r\n item.name+= item.variantName ? ` - ${ item.variantName}` : '';\r\n return item;\r\n })\r\n .sortBy([(item) => item.categoryId !== 100, (item) => item.name.toUpperCase()])\r\n .value();\r\n }\r\n\r\n private _removeAddedShortcutsFromLists(): void {\r\n _.forEach(this.addedShortcuts, item => {\r\n if(item.actionViewID) {\r\n _.remove(this.actionViews, item);\r\n }\r\n\r\n if(item.reportID) {\r\n _.remove(this.reports, item);\r\n }\r\n\r\n if(item.searchId) {\r\n _.remove(this.smarts, item);\r\n }\r\n });\r\n }\r\n}\r\n","export class PortfolioAnalysisWidgetModel {\r\n totalCompanies: number;\r\n totalSites: number;\r\n totalParcels: number;\r\n taxYears: number[]; // List of ALL available tax years across applicable Parcels\r\n annualData: PortfolioAnalysisAnnualData[]; // List of retrieved data for requested years\r\n}\r\n\r\nexport class PortfolioAnalysisAnnualData {\r\n year: number;\r\n totalFMV: number; // decimal(19,6)\r\n totalFMVPerSqFt: number; // decimal(19,6)\r\n totalFMVPerUnit: number; // decimal(19,6)\r\n fmvByPropertyType: PortfolioAnalysisFMVByPropType[];\r\n fmvForLandTypeComponents: PortfolioAnalysisFMVLand;\r\n totalTax: number; // decimal(19,6)\r\n totalRefund: number; // decimal(19,6)\r\n\r\n totalSitesForYear: number;\r\n totalSitesActualAssessments: number;\r\n totalSitesActualTaxes: number;\r\n totalSitesProjectedAssessment: number;\r\n totalSitesProjectedTaxes: number;\r\n totalSitesUnderAppeal: number;\r\n}\r\n\r\nexport class PortfolioAnalysisFMVByPropType {\r\n name: string;\r\n fmv: number; // decimal(19,6)\r\n fmvPerSqFt: number; // decimal(19,6)\r\n fmvPerUnit: number; // decimal(19,6)\r\n}\r\n\r\nexport class PortfolioAnalysisFMVLand {\r\n fmv: number; // decimal(19,6)\r\n landFMVPerSqFt: number; // decimal(19,6)\r\n landFMVPerAcre: number; // decimal(19,6)\r\n}","\r\n
\r\n \r\n \r\n
\r\n
\r\n
No Data
\r\n
\r\n\r\n\t\r\n\t\t\r\n\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\r\n\t\t\t\t\r\n\t\t\t\r\n\t\t\r\n\t\t\r\n\t\t\t\r\n\t\t\t\t\r\n\r\n\t\t\t\t\r\n\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\r\n\t\t\t\t\r\n\t\t\t\r\n\t\t\r\n\t
Tax Year\r\n\t\t\t\t\t{{seriesItem.name}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getColumnTitle(TotalValueNames.TOTALFMV)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getColumnTitle(TotalValueNames.FMVPERSQFT)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getColumnTitle(TotalValueNames.FMVPERUNIT)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getColumnTitle(TotalValueNames.LANDFMV)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getColumnTitle(TotalValueNames.LANDFMVPERSQFT)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getColumnTitle(TotalValueNames.LANDFMVPERACRE)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getColumnTitle(TotalValueNames.TOTALTAX)}}\r\n\t\t\t\t
{{xAxisCategory}}\r\n\t\t\t\t\t{{getCellValue(seriesItem, xAxisCategory)| currency:'USD':'':'1.0-0'}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getTotalValueForYear(xAxisCategory, TotalValueNames.TOTALFMV) | currency:'USD':'':getPrecision(TotalValueNames.TOTALFMV)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getTotalValueForYear(xAxisCategory, TotalValueNames.FMVPERSQFT) | currency:'USD':'symbol':getPrecision(TotalValueNames.FMVPERSQFT)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getTotalValueForYear(xAxisCategory, TotalValueNames.FMVPERUNIT) | currency:'USD':'symbol':getPrecision(TotalValueNames.FMVPERUNIT)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getTotalValueForYear(xAxisCategory, TotalValueNames.LANDFMV) | currency:'USD':'':getPrecision(TotalValueNames.LANDFMV)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getTotalValueForYear(xAxisCategory, TotalValueNames.LANDFMVPERSQFT) | currency:'USD':'symbol':getPrecision(TotalValueNames.LANDFMVPERSQFT)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getTotalValueForYear(xAxisCategory, TotalValueNames.LANDFMVPERACRE) | currency:'USD':'symbol':getPrecision(TotalValueNames.LANDFMVPERACRE)}}\r\n\t\t\t\t\r\n\t\t\t\t\t{{getTotalValueForYear(xAxisCategory, TotalValueNames.TOTALTAX) | currency:'USD':'symbol':getPrecision(TotalValueNames.TOTALTAX)}}\r\n\t\t\t\t
\r\n\r\n\t
\r\n\t\t
\r\n\t\t\t= data.taxYears.length)\" (click)=\"showAllYearsClicked.emit()\">Show All Years\r\n\t\t
\r\n\t
\r\n
\r\n","import { Component, Input, ViewChild, ElementRef, EventEmitter, Output, OnInit } from '@angular/core';\r\nimport { PortfolioAnalysisWidgetModel } from './portfolio.analysis.widget.model';\r\nimport { ActivityService } from '../../../Common/Activity/activity.service';\r\nimport { Observable } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { UnsubscribeMixin } from '../../../UI-Lib/Mixins/unsubscribe.mixin';\r\nimport { DashboardDataService } from '../../dashboard.data.service';\r\nimport { TimerService } from '../../../UI-Lib/Utilities';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport Exporting from 'highcharts/modules/exporting';\r\n\r\nimport * as _ from 'lodash';\r\ndeclare const Highcharts: any;\r\nExporting(Highcharts);\r\n\r\n@Component({\r\n selector: 'portfolio-analysis-chart-table',\r\n templateUrl: './portfolio.analysis.chart.table.component.html'\r\n})\r\nexport class PortfolioAnalysisChartTableComponent extends UnsubscribeMixin() implements OnInit {\r\n constructor(\r\n private readonly _activityService: ActivityService,\r\n private readonly _dashboardDataService: DashboardDataService,\r\n private readonly _timer: TimerService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {\r\n super();\r\n }\r\n\r\n @ViewChild('chart', { static: true }) chart: ElementRef;\r\n @Input() data: PortfolioAnalysisWidgetModel;\r\n @Input() resize$: Observable;\r\n @Output() showAllYearsClicked: EventEmitter = new EventEmitter();\r\n @Output() graphSelected: EventEmitter = new EventEmitter();\r\n\r\n highChart: any;\r\n config: any;\r\n activityMode: 'graph' | 'table' = 'graph';\r\n // The values of this object are attribute names in the totalValues array objects\r\n // populated in this.config by ActivityService.\r\n TotalValueNames: any = {\r\n TOTALFMV: 'totalFMV',\r\n FMVPERSQFT: 'fmvPerSqFt',\r\n FMVPERUNIT: 'fmvPerUnit',\r\n LANDFMV: 'landFMV',\r\n LANDFMVPERSQFT: 'landFMVPerSqFt',\r\n LANDFMVPERACRE: 'landFMVPerAcre',\r\n TOTALTAX: 'totalTax',\r\n };\r\n // The keys of this object align with the values of the object above.\r\n TotalValueAttributes: any = {\r\n 'totalFMV': { title: 'Total FMV', precision: '1.0-0' },\r\n 'fmvPerSqFt': { title: '$/SqFt', precision: '1.2-2' },\r\n 'fmvPerUnit': { title: '$/Unit', precision: '1.2-2' },\r\n 'landFMV': { title: 'Land FMV', precision: '1.0-0' },\r\n 'landFMVPerSqFt': { title: 'Land $/SqFt', precision: '1.2-2' },\r\n 'landFMVPerAcre': { title: 'Land $/Acre', precision: '1.2-2' },\r\n 'totalTax': { title: 'Total Tax', precision: '1.2-2' },\r\n };\r\n\r\n ngOnInit() {\r\n if (this.resize$) {\r\n this.resize$.pipe(takeUntil(this.destroy$)).subscribe(r => {\r\n this._timer.setTimeout(() => {\r\n if (this.highChart) {\r\n this.highChart.setSize();\r\n }\r\n }, 0);\r\n });\r\n }\r\n }\r\n\r\n updateChartType(chartType: string, data: PortfolioAnalysisWidgetModel): void {\r\n const afterPrintCb = () => this._dashboardDataService.resizeGrid$.next(); // WK-9467 Need to resize the grid after chart is printed due to weirdness\r\n this.config = this._activityService.createGraphConfigForDashboard(data, chartType, afterPrintCb);\r\n\r\n this.highChart = Highcharts.chart(this.chart.nativeElement, this.config);\r\n }\r\n\r\n reverseIt(categories: any[]) {\r\n return _.reverse(_.cloneDeep(categories));\r\n }\r\n\r\n getCellValue(seriesItem, year:number): string {\r\n const xAxisCategoryIndex = this.config.xAxis.categories.indexOf(year);\r\n return seriesItem.data[xAxisCategoryIndex].y;\r\n }\r\n\r\n getTotalValueForYear(year: number, totalValueName: string): number {\r\n let result = 0;\r\n const yearIndex: number = this.config.totalValues.findIndex(entry => entry.year === year);\r\n const yearTotals = yearIndex >= 0 && yearIndex < this.config.totalValues.length ? this.config.totalValues[yearIndex] : null;\r\n if ( yearTotals && totalValueName && yearTotals[totalValueName] > 0 )\r\n {\r\n result = yearTotals[totalValueName];\r\n }\r\n return result;\r\n }\r\n\r\n showColumn(totalValueName: string, arrayOfAllowedModes: string[]): boolean {\r\n if (arrayOfAllowedModes.indexOf(this.config.chartType) < 0)\r\n return false;\r\n\r\n if (totalValueName === '')\r\n return true;\r\n\r\n // do we have any value?\r\n return _.some(this.config.totalValues, entry => entry[totalValueName] > 0);\r\n }\r\n\r\n getColumnTitle(totalValueName: string): string {\r\n return this.TotalValueAttributes[totalValueName] ? this.TotalValueAttributes[totalValueName].title : 'error!';\r\n }\r\n\r\n getPrecision(totalValueName: string): string {\r\n return this.TotalValueAttributes[totalValueName] ? this.TotalValueAttributes[totalValueName].precision : '1.0-0';\r\n }\r\n\r\n sortByPropType(series): any {\r\n return _.orderBy(series, 'propertyTypeSequence');\r\n }\r\n\r\n chartTypeSelected(type: string): void {\r\n if (type === 'graph') {\r\n this.graphSelected.emit();\r\n }\r\n this._productAnalyticsService.logEvent('click-portfolio-widget', {\r\n format: type\r\n });\r\n }\r\n\r\n reflowChart() {\r\n return null;\r\n }\r\n}\r\n","
\r\n\t
\r\n\t\t
\r\n\t\t\t
\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t
\r\n\t\t\t
\r\n\t\t\t\t
\r\n\t\t\t\t\t
\r\n\t\t\t\t\t\tTotal FMV: {{ (currentYear.totalFMV || 0) | currency:'USD':'':'1.0-0' }}\r\n\t\t\t\t\t
\r\n\t\t\t\t\t
0\" (click)=\"lineItemClicked('totalFMVPerSqFt')\">\r\n\t\t\t\t\t\tTotal $/SqFt: {{ currentYear.totalFMVPerSqFt | currency }}\r\n\t\t\t\t\t
\r\n\t\t\t\t\t
0\" (click)=\"lineItemClicked('totalFMVPerUnit')\">\r\n\t\t\t\t\t\tTotal $/Unit: {{ currentYear.totalFMVPerUnit | currency }} \r\n\t\t\t\t\t
\r\n\t\t\t\t\t
0\" (click)=\"lineItemClicked('landFMVPerSqFt')\">\r\n\t\t\t\t\t\tLand $/SqFt: {{ currentYear.fmvForLandTypeComponents.landFMVPerSqFt | currency }}\r\n\t\t\t\t\t
\r\n\t\t\t\t\t
0\" (click)=\"lineItemClicked('landFMVPerAcre')\">\r\n\t\t\t\t\t\tLand $/Acre: {{ currentYear.fmvForLandTypeComponents.landFMVPerAcre | currency }}\r\n\t\t\t\t\t
\r\n\t\t\t\t
\r\n\r\n\t\t\t\t
\r\n\t\t\t\t\tTotal Tax: {{ (currentYear.totalTax || 0) | currency }}\r\n\t\t\t\t
\r\n\t\t\t
\r\n\t\t\t
\r\n\t\t\t\t
Sites Under Appeal: {{currentYear.totalSitesUnderAppeal || 0}}/{{currentYear.totalSitesForYear || 0}}
\r\n\t\t\t\t
Sites with Actual Assessments: {{currentYear.totalSitesActualAssessments || 0}}/{{currentYear.totalSitesForYear || 0}}
\r\n\t\t\t\t
Sites with Actual Taxes: {{currentYear.totalSitesActualTaxes || 0}}/{{currentYear.totalSitesForYear || 0}}
\r\n\t\t\t
\r\n\t\t
\r\n\t
\r\n\t
\r\n\t\t\r\n\t
\r\n
\r\n","import { Component, Input, Output, EventEmitter, AfterViewInit, ViewChild } from '@angular/core';\r\nimport { DataWidgetI, WidgetCache, WidgetIds, UserWidget } from '../../dashboard.model';\r\nimport { Observable, Subject } from 'rxjs';\r\nimport { PortfolioAnalysisWidgetModel, PortfolioAnalysisAnnualData } from './portfolio.analysis.widget.model';\r\nimport * as _ from 'lodash';\r\nimport { PortfolioAnalysisChartTableComponent } from './portfolio.analysis.chart.table.component';\r\nimport { DashboardDataService } from '../../dashboard.data.service';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\n\r\n@Component({\r\n selector: 'portfolio-analysis-widget',\r\n templateUrl: './portfolio.analysis.widget.component.html',\r\n styleUrls: ['./portfolio.analysis.widget.component.scss']\r\n})\r\nexport class PortfolioAnalysisWidgetComponent implements DataWidgetI, AfterViewInit {\r\n constructor(\r\n private readonly _dashboardDataService: DashboardDataService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) { }\r\n\r\n @ViewChild(PortfolioAnalysisChartTableComponent)\r\n chartTableComponent: PortfolioAnalysisChartTableComponent;\r\n\r\n @Input() data$: Observable;\r\n @Input() userWidget: UserWidget;\r\n @Output() newParams: EventEmitter = new EventEmitter();\r\n\r\n resize$: Subject;\r\n availableYears: number[];\r\n selectedYear: number;\r\n\r\n data: PortfolioAnalysisWidgetModel;\r\n chartType: string;\r\n\r\n currentYear: PortfolioAnalysisAnnualData;\r\n acres: string;\r\n impsSqFt: string;\r\n units: string;\r\n\r\n WidgetIds = WidgetIds;\r\n\r\n get isChartWidget(): boolean {\r\n return this.userWidget.widget.widgetId === WidgetIds.PortfolioAnalysis;\r\n }\r\n\r\n ngOnInit(): void {\r\n // Initialize selected year to current year upon first display.\r\n this.selectedYear = new Date().getFullYear();\r\n\r\n this.resize$ = new Subject();\r\n // WK-8048 - The chart doesn't get automatically updated when we resize the widget for some reason;\r\n // \"kick\" the widget when resized in design mode to make it work correctly\r\n this._dashboardDataService.userWidgetResize$.subscribe(() => this.resize$.next());\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.data$.subscribe((widgetCache: WidgetCache) => {\r\n this.data = widgetCache.data;\r\n this.availableYears = _.reverse(this.data.taxYears);\r\n\r\n this.currentYear = _.findLast(this.data.annualData, x => x.year <= this.selectedYear);\r\n if ( !this.currentYear )\r\n {\r\n // Didn't find selected year or an earlier year.\r\n // Look for a later year than selected.\r\n this.currentYear = _.find(this.data.annualData, x => x.year > this.selectedYear);\r\n if ( !this.currentYear )\r\n {\r\n // Didn't find any years.\r\n // Create currentYear with default data for selected year.\r\n this.currentYear = new PortfolioAnalysisAnnualData();\r\n this.currentYear.year = this.selectedYear;\r\n }\r\n }\r\n if ( this.currentYear.year != this.selectedYear )\r\n {\r\n // Didn't find selected year, but found an earlier/later year.\r\n this.selectedYear = this.currentYear.year;\r\n }\r\n\r\n this.currentYear.totalFMV = Math.round(this.currentYear.totalFMV);\r\n\r\n /*\r\n this.acres = _.find(this.data.propertyCharacteristics, {label: 'Land Acreage' });\r\n this.impsSqFt = _.find(this.data.propertyCharacteristics, {label: 'Imps. SqFt' });\r\n this.units = _.find(this.data.propertyCharacteristics, {label: 'Units' });\r\n */\r\n\r\n this.lineItemClicked('totalFMV', false);\r\n });\r\n }\r\n\r\n getDataByYear(year: number): void {\r\n const event = this.isChartWidget ? 'click-portfolio-widget' : 'click-portfolio-summary-widget';\r\n this._productAnalyticsService.logEvent(event, { taxYear: year });\r\n this.newParams.emit({year: year});\r\n }\r\n\r\n lineItemClicked(chartType: string, fromClick: boolean = true): void {\r\n if(!this.isChartWidget || chartType === this.chartType) {\r\n return;\r\n }\r\n\r\n this.chartType = chartType;\r\n this.chartTableComponent.updateChartType(this.chartType, this.data);\r\n\r\n if(fromClick) {\r\n let analyticsProperty: string, analyticsValue: string;\r\n switch (chartType) {\r\n case 'totalFMV':\r\n analyticsProperty = 'totalFMV';\r\n analyticsValue = `$${this.currentYear.totalFMV}`;\r\n break;\r\n case 'totalFMVPerSqFt':\r\n analyticsProperty = 'total$Sqft';\r\n analyticsValue = `$${this.currentYear.totalFMVPerSqFt}`;\r\n break;\r\n case 'totalFMVPerUnit':\r\n analyticsProperty = 'total$Unit';\r\n analyticsValue = `$${this.currentYear.totalFMVPerUnit}`;\r\n break;\r\n case 'landFMVPerSqFt':\r\n analyticsProperty = 'land$Sqft';\r\n analyticsValue = `$${this.currentYear.fmvForLandTypeComponents.landFMVPerSqFt}`;\r\n break;\r\n case 'landFMVPerAcre':\r\n analyticsProperty = 'land$Acre';\r\n analyticsValue = `$${this.currentYear.fmvForLandTypeComponents.landFMVPerAcre}`;\r\n break;\r\n case 'totalTaxesUngrouped':\r\n analyticsProperty = 'totalTax';\r\n analyticsValue = `$${this.currentYear.totalTax || 0}`;\r\n }\r\n this._productAnalyticsService.logEvent('click-portfolio-widget', {\r\n [analyticsProperty]: analyticsValue\r\n });\r\n }\r\n }\r\n}\r\n","
\r\n

\r\n My Team's Tasks Due Within 45 Days\r\n

\r\n

\r\n No current tasks\r\n

\r\n

\r\n Your data is taking some time to load. To access your Action Views, click here.\r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{headerItem.label}}
{{ taskSeriesTypeItem.taskSeriesTypeName }}\r\n \r\n 0\" >{{taskCountItem.ready}} 0\">({{taskCountItem.notReady}})\r\n \r\n
\r\n
\r\n
","import { Component, OnInit, EventEmitter, Input, Output, OnDestroy } from '@angular/core';\r\nimport { DataWidgetI } from '../../dashboard.model';\r\nimport { Observable, Subscription } from 'rxjs';\r\nimport * as _ from 'lodash';\r\nimport { ActionViewService } from '../../../Task/ActionView/action-view-service.upgrade';\r\nimport { ActionViewPersistenceService } from '../../../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { TaskSeriesTypeItem } from './my.tasks.widget.model';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\n\r\n@Component({\r\n selector: 'my-tasks-widget',\r\n templateUrl: './my.tasks.widget.component.html',\r\n styleUrls: ['./my.tasks.widget.component.scss']\r\n})\r\nexport class MyTasksWidgetComponent implements OnInit, DataWidgetI, OnDestroy {\r\n constructor(\r\n private readonly _actionViewService: ActionViewService,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService,\r\n private readonly _upgradeNavigationService: UpgradeNavigationServiceHandler,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) { }\r\n\r\n @Input() data$?: Observable;\r\n @Output() newParams?: EventEmitter = new EventEmitter();\r\n\r\n dataSubscription: Subscription;\r\n taskSeriesTypeList: TaskSeriesTypeItem[];\r\n originalRequest: any;\r\n actionViewTimeout: boolean = false;\r\n\r\n ngOnInit() {\r\n this.taskSeriesTypeList = null;\r\n this.dataSubscription = this.data$.subscribe(event => {\r\n const data = _.cloneDeep(event.data);\r\n\r\n this._actionViewService.processSearchResultPlusRequest(data);\r\n this.originalRequest = data.originalRequest;\r\n\r\n if (data.isCancelled) {\r\n this.actionViewTimeout = true;\r\n return;\r\n }\r\n\r\n this.taskSeriesTypeList = _.map(data.group1ResultList, (task: TaskSeriesTypeItem) => {\r\n task.data = _.map(task.data, (item: any) => {\r\n item.colClass = this._actionViewService.getUrgencyColumnStyleClass(item.sequence);\r\n return item;\r\n });\r\n return task;\r\n });\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this.dataSubscription.unsubscribe();\r\n }\r\n\r\n drilldownCell(cell: any, ready: string, task: any): void {\r\n this._actionViewPersistenceService.clearSavedData();\r\n //step 1: set drilldown persistenceservice variable\r\n this._actionViewPersistenceService.externalDrilldown = true;\r\n this._actionViewPersistenceService.masterFilter = _.cloneDeep(this.originalRequest);\r\n this._actionViewPersistenceService.drilldownFilter = _.cloneDeep(this.originalRequest);\r\n this._actionViewPersistenceService.externalDrilldownData = {\r\n ready: ready,\r\n item: cell,\r\n task: task\r\n };\r\n\r\n this._productAnalyticsService.logEvent('click-task-widget', {\r\n [cell.label.toLowerCase()]: task.taskSeriesTypeName\r\n });\r\n this._upgradeNavigationService.go('actionview', {});\r\n }\r\n\r\n goToActionView(): void {\r\n this._actionViewPersistenceService.clearSavedData();\r\n this._actionViewPersistenceService.masterFilter = this.originalRequest;\r\n this._upgradeNavigationService.go('actionview', {});\r\n }\r\n}\r\n","export enum MyTasksView {\r\n myTasks = 1,\r\n myTeamsTasks = 2\r\n}\r\n\r\nexport class MyTasksWidgetSettings {\r\n myTasksView: MyTasksView;\r\n}\r\n\r\nexport class TaskSeriesTypeItem {\r\n data: TaskCountItem[];\r\n firstGroup: string;\r\n secondGroup: string;\r\n taskSeriesTypeID: number;\r\n taskSeriesName: string;\r\n taskTypeID: number;\r\n taskSeriesTypeName: string;\r\n}\r\n\r\nexport class TaskCountItem {\r\n colClass: string;\r\n label: string;\r\n notReady: number;\r\n ready: number;\r\n sequence: number;\r\n value: number;\r\n}","
\r\n

My Tasks Settings

\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { DashboardDataService } from '../../dashboard.data.service';\r\nimport { MyTasksWidgetSettings, MyTasksView } from './my.tasks.widget.model';\r\n\r\n@Component({\r\n selector: 'my-tasks-widget-settings',\r\n templateUrl: './my.tasks.widget.settings.component.html'\r\n})\r\nexport class MyTasksWidgetSettingsComponent implements OnInit {\r\n constructor(\r\n public bsModalRef: BsModalRef,\r\n private dashboardDataService: DashboardDataService\r\n ) { }\r\n\r\n loading: boolean;\r\n userWidgetId: number;\r\n settings: MyTasksWidgetSettings;\r\n selectedMyTasksView: MyTasksView;\r\n myTasksViews: { viewId: MyTasksView, name: string }[];\r\n onClose: (shouldReload: boolean) => void;\r\n\r\n\r\n async ngOnInit() {\r\n this.myTasksViews = [{\r\n viewId: MyTasksView.myTasks,\r\n name: 'My Tasks'\r\n }, {\r\n viewId: MyTasksView.myTeamsTasks,\r\n name: 'My Team\\'s Tasks'\r\n }];\r\n\r\n this.loading = true;\r\n\r\n try {\r\n this.settings = (await this.dashboardDataService.getWidgetSettings(this.userWidgetId)) as MyTasksWidgetSettings;\r\n this.selectedMyTasksView = this.settings.myTasksView;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async saveAndClose() {\r\n this.loading = true;\r\n\r\n try {\r\n this.settings.myTasksView = this.selectedMyTasksView;\r\n await this.dashboardDataService.saveWidgetSettings(this.userWidgetId, this.settings);\r\n this.onClose(true);\r\n this.bsModalRef.hide();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n}\r\n\r\n","\r\n
\r\n

Output Columns

\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n

{{category.categoryName}}

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { DashboardDataService } from '../../dashboard.data.service';\r\nimport { CalendarWidgetFieldIdCategory, CalendarWidgetFieldIds } from '../../dashboard.model';\r\nimport { DashboardCalendarEventTypes } from './calendar.widget.model';\r\nimport { OutputColumn } from '../../../Search/Advanced/Column-Picker/column.model';\r\nimport { ColumnCategory, DraggableOutputColumn } from '../../../Common/AV-AS/category.column.picker.component';\r\nimport { SmartSearchService } from '../../../Search/Advanced/smartSearch.service';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'calendar-widget-settings',\r\n templateUrl: './calendar.widget.settings.component.html'\r\n})\r\nexport class CalendarWidgetSettingsComponent implements OnInit {\r\n constructor(\r\n public bsModalRef: BsModalRef,\r\n private dashboardDataService: DashboardDataService,\r\n private asService: SmartSearchService\r\n ) { }\r\n\r\n loading: boolean;\r\n calendarWidgetIds: CalendarWidgetFieldIds;\r\n calendarWidgetIdsDefaults: CalendarWidgetFieldIds;\r\n calendarWidgetFields: ColumnCategory[];\r\n onClose: (shouldReload: boolean) => void;\r\n private allOutputColumns: OutputColumn[];\r\n\r\n\r\n async ngOnInit() {\r\n this.loading = true;\r\n\r\n try {\r\n this.calendarWidgetIds = await this.dashboardDataService.getSmartAvFields();\r\n this.calendarWidgetIdsDefaults = await this.dashboardDataService.getSmartAvFieldsDefault();\r\n\r\n this.allOutputColumns = (await this.asService.getColumns(true, 'smart')).all;\r\n\r\n this.calendarWidgetFields = _.chain(this.calendarWidgetIds.categories)\r\n .reject(category => this._isDummyComplianceCategory(category.type))\r\n .map((category, idx) => {\r\n const defaultCategory = this.calendarWidgetIdsDefaults.categories[idx];\r\n\r\n return {\r\n categoryName: this.dashboardDataService.eventTypeTitleMap.get(category.type),\r\n columns: this._mapColIds(category),\r\n defaultColumns: this._mapColIds(defaultCategory)\r\n };\r\n })\r\n .value();\r\n } finally {\r\n this.loading = false;\r\n }\r\n\r\n }\r\n\r\n async saveAndClose(): Promise {\r\n const masterComplianceCategoryIdx = _.findIndex(this.calendarWidgetIds.categories, {type: DashboardCalendarEventTypes.AbatementComplianceDeadline});\r\n const masterComplianceCategory = this.calendarWidgetFields[masterComplianceCategoryIdx];\r\n\r\n const calendarWidgetFieldsIds: CalendarWidgetFieldIds = {\r\n categories: _.map(this.calendarWidgetIds.categories, (category, idx) => {\r\n const columnsToMap = this._isDummyComplianceCategory(category.type)\r\n ? masterComplianceCategory.columns\r\n : this.calendarWidgetFields[idx].columns;\r\n\r\n category.columnIds = _.map(columnsToMap, 'columnId');\r\n return category;\r\n })\r\n };\r\n\r\n this.loading = true;\r\n\r\n try {\r\n await this.dashboardDataService.saveSmartAvFields(calendarWidgetFieldsIds);\r\n\r\n this.onClose(false);\r\n this.bsModalRef.hide();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n private _mapColIds(category: CalendarWidgetFieldIdCategory): DraggableOutputColumn[] {\r\n return _.map(category.columnIds, colId => {\r\n const column = _.find(this.allOutputColumns, { columnId: colId });\r\n if(!column) {\r\n console.warn('Column cannot be found from ID!');\r\n return;\r\n }\r\n\r\n return { ...column, isRemovable: !_.includes(category.columnsToKeep, column.columnId) };\r\n });\r\n }\r\n\r\n private _isDummyComplianceCategory(categoryType: DashboardCalendarEventTypes): boolean {\r\n switch (categoryType) {\r\n case DashboardCalendarEventTypes.FreeportComplianceDeadline:\r\n case DashboardCalendarEventTypes.MiscFilingComplianceDeadline:\r\n case DashboardCalendarEventTypes.PPReturnComplianceDeadline:\r\n case DashboardCalendarEventTypes.PollutionControlComplianceDeadline:\r\n return true;\r\n default:\r\n return false;\r\n }\r\n }\r\n}\r\n\r\n","import { Injectable, Type } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { AppealSavingsWidgetComponent } from './Widgets/appeal.savings.widget.component';\r\nimport { QuickSearchButtonWidgetComponent } from './Widgets/quick.search.button.widget.component';\r\nimport { StatesButtonWidgetComponent } from './Widgets/states.button.widget.component';\r\nimport { CalendarWidgetComponent } from './Widgets/Calendar-Widget/calendar.widget.component';\r\nimport { ShortcutWidgetComponent } from './Widgets/Shortcuts-Widget/shortcut.widget.component';\r\nimport { ShortcutWidgetSettingsComponent } from './Widgets/Shortcuts-Widget/shortcut.widget.settings.component';\r\nimport { PortfolioAnalysisWidgetComponent } from './Widgets/Portfolio-Analysis-Widget/portfolio.analysis.widget.component';\r\nimport { WidgetIds } from './dashboard.model';\r\nimport { MyTasksWidgetComponent } from './Widgets/My-Tasks-Widget/my.tasks.widget.component';\r\nimport { MyTasksWidgetSettingsComponent } from './Widgets/My-Tasks-Widget/my.tasks.widget.settings.component';\r\nimport { CalendarWidgetSettingsComponent } from './Widgets/Calendar-Widget/calendar.widget.settings.component';\r\n\r\nexport class WidgetRegistry {\r\n widgetId: number;\r\n widget: Type;\r\n settings: Type;\r\n smallerSettingsModal?: boolean;\r\n}\r\n\r\n@Injectable()\r\nexport class WidgetComponentRegistryService {\r\n private widgetComponents: WidgetRegistry[] = [{\r\n widgetId: WidgetIds.AppealSavings,\r\n widget: AppealSavingsWidgetComponent,\r\n settings: null\r\n }, {\r\n widgetId: WidgetIds.QuickSearchButton,\r\n widget: QuickSearchButtonWidgetComponent,\r\n settings: null\r\n }, {\r\n widgetId: WidgetIds.StatesButton,\r\n widget: StatesButtonWidgetComponent,\r\n settings: null\r\n }, {\r\n widgetId: WidgetIds.Calendar,\r\n widget: CalendarWidgetComponent,\r\n settings: CalendarWidgetSettingsComponent,\r\n smallerSettingsModal: true\r\n }, {\r\n widgetId: WidgetIds.Shortcut,\r\n widget: ShortcutWidgetComponent,\r\n settings: ShortcutWidgetSettingsComponent\r\n }, {\r\n widgetId: WidgetIds.PortfolioAnalysis,\r\n widget: PortfolioAnalysisWidgetComponent,\r\n settings: null\r\n }, {\r\n widgetId: WidgetIds.PortfolioAnalysisSummary,\r\n widget: PortfolioAnalysisWidgetComponent,\r\n settings: null\r\n }, {\r\n widgetId: WidgetIds.MyTasks,\r\n widget: MyTasksWidgetComponent,\r\n settings: MyTasksWidgetSettingsComponent\r\n }];\r\n\r\n getWidgetComponentById(widgetId: number): Type {\r\n return _.find(this.widgetComponents, {widgetId: widgetId}).widget;\r\n }\r\n\r\n getRegisteredWidgetById(widgetId: number): WidgetRegistry {\r\n return _.find(this.widgetComponents, { widgetId: widgetId });\r\n }\r\n}\r\n","import { Component, OnInit, Input, Output, EventEmitter, ViewContainerRef, ViewChild, ComponentFactoryResolver } from '@angular/core';\r\nimport { DashboardDataService } from '../dashboard.data.service';\r\nimport { UserWidget, RefreshPolicies } from '../dashboard.model';\r\nimport { MessageBoxService, MessageBoxButtons, MessageBoxResult } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { Subject, Observable } from 'rxjs';\r\nimport { BsModalService, ModalOptions } from 'ngx-bootstrap/modal';\r\nimport { WidgetComponentRegistryService } from '../widget.component.registry.service';\r\nimport { UnsubscribeMixin } from '../../UI-Lib/Mixins/unsubscribe.mixin';\r\nimport { takeUntil } from 'rxjs/operators';\r\n@Component({\r\n selector: 'user-widget',\r\n template: `\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n `,\r\n styleUrls: ['dashboard-widget.scss']\r\n})\r\nexport class UserWidgetComponent extends UnsubscribeMixin() implements OnInit {\r\n constructor(\r\n private messageBoxService: MessageBoxService,\r\n private dashboardDataService: DashboardDataService,\r\n private widgetComponentRegistryService: WidgetComponentRegistryService,\r\n private resolver: ComponentFactoryResolver,\r\n private modalService: BsModalService\r\n ) {\r\n super();\r\n }\r\n\r\n @Input() userWidget: UserWidget;\r\n @Input() designMode: boolean;\r\n @Output() widgetRemove: EventEmitter = new EventEmitter();\r\n\r\n @ViewChild('widgetContainer', { read: ViewContainerRef, static: true }) entry: ViewContainerRef;\r\n\r\n RefreshPolicies = RefreshPolicies;\r\n hovered: boolean = false;\r\n loading: boolean = false;\r\n widgetDataSource: Subject = new Subject();\r\n widgetParams: object = {};\r\n\r\n ngOnInit() {\r\n this.entry.clear();\r\n const factory = this.resolver.resolveComponentFactory<{\r\n data$: Observable,\r\n newParams: EventEmitter,\r\n userWidget: UserWidget\r\n }>(this.widgetComponentRegistryService.getWidgetComponentById(this.userWidget.widget.widgetId));\r\n const componentRef = this.entry.createComponent(factory);\r\n\r\n if(this.userWidget.widget.refreshPolicy !== RefreshPolicies.NoData) {\r\n componentRef.instance.data$ = this.widgetDataSource.asObservable();\r\n\r\n\r\n componentRef.instance.newParams.pipe(takeUntil(this.destroy$)).subscribe((widgetParams: object) => {\r\n this.getWidgetData(widgetParams);\r\n });\r\n\r\n componentRef.instance.userWidget = this.userWidget;\r\n this.getWidgetData();\r\n }\r\n }\r\n\r\n async getWidgetData(params?: object) {\r\n this.loading = true;\r\n\r\n try {\r\n const widgetCache = await this.dashboardDataService.getWidgetData(this.userWidget, params);\r\n\r\n this.widgetParams = widgetCache.params || {};\r\n this.widgetDataSource.next(widgetCache);\r\n } finally {\r\n this.loading = false;\r\n }\r\n\r\n }\r\n\r\n async confirmRemove(): Promise {\r\n const result = await this.messageBoxService.open({\r\n message: 'Are you sure you want to remove this widget?',\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if (result === MessageBoxResult.OK) {\r\n this.widgetRemove.emit(this.userWidget.userWidgetId);\r\n }\r\n }\r\n\r\n goToSettings(): void {\r\n const registeredWidget = this.widgetComponentRegistryService.getRegisteredWidgetById(this.userWidget.widget.widgetId);\r\n if(!registeredWidget) {\r\n console.warn('could not find registered widget!');\r\n return;\r\n }\r\n\r\n const params: ModalOptions = {\r\n initialState: { userWidgetId: this.userWidget.userWidgetId }\r\n };\r\n\r\n if(!registeredWidget.smallerSettingsModal) {\r\n params.class = 'modal-lg';\r\n }\r\n\r\n const settingsModalRef = this.modalService.show(registeredWidget.settings, params);\r\n settingsModalRef.content.onClose = (shouldReload: boolean) => {\r\n if(shouldReload) {\r\n this.getWidgetData(this.widgetParams);\r\n }\r\n };\r\n }\r\n\r\n}\r\n","import { Component, OnDestroy, OnInit, ViewChild } from '@angular/core';\r\nimport { ProductAnalyticsService } from '../Common/Amplitude/productAnalytics.service';\r\nimport { DashboardDataService } from './dashboard.data.service';\r\nimport { Dashboard, Widget, UserWidget } from './dashboard.model';\r\nimport { GridsterConfig, GridsterItem } from 'angular-gridster2';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { MessageBoxService, MessageBoxButtons, MessageBoxResult } from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { Subscription } from 'rxjs';\r\nimport { FeatureFlagsService } from '../Common/FeatureFlags/feature-flags-service';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'dashboard',\r\n template: `\r\n
\r\n
\r\n
\r\n

Welcome {{dashboard.firstName}}!

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n `,\r\n styleUrls: ['./dashboard.component.scss']\r\n})\r\nexport class DashboardComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _dashboardDataService: DashboardDataService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n @ViewChild('addWidgetDropdown') addWidgetDropdown;\r\n dashboard: Dashboard = new Dashboard();\r\n options: GridsterConfig;\r\n designMode: boolean = false;\r\n loading: boolean = false;\r\n isShowDashboard: boolean = false;\r\n IAMactive: boolean = false;\r\n resizeGridSub: Subscription;\r\n\r\n async ngOnInit(): Promise {\r\n this.options = {\r\n draggable: {},\r\n resizable: {},\r\n\r\n margin: 5,\r\n displayGrid: this.designMode ? 'always' : 'none',\r\n enableEmptyCellClick: this.designMode,\r\n\r\n maxCols: 4,\r\n minCols: 4,\r\n minRows: 3,\r\n maxRows: 3,\r\n // pushItems: true,\r\n scrollToNewItems: true,\r\n emptyCellClickCallback: () => {\r\n // this.addWidgetDropdown.show()\r\n },\r\n itemResizeCallback: (item: UserWidget) => {\r\n this._dashboardDataService.userWidgetResize$.next(item.userWidgetId);\r\n },\r\n itemChangeCallback: async (userWidget: UserWidget) => {\r\n this.loading = true;\r\n\r\n try {\r\n await this._dashboardDataService.updateUserWidget(userWidget);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n };\r\n\r\n this.loading = true;\r\n\r\n try {\r\n this.setDashboard(await this._dashboardDataService.getDashboard());\r\n } finally {\r\n this.loading = false;\r\n }\r\n\r\n this.isShowDashboard = this._dashboardDataService.getShowDashBoardUserSetting();\r\n this.resizeGridSub = this._dashboardDataService.resizeGrid$.subscribe(() => this.options.api.resize());\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.resizeGridSub.unsubscribe();\r\n }\r\n\r\n async addWidget(widget: Widget): Promise {\r\n const possibleGridItem: GridsterItem = { rows: widget.height, cols: widget.width, x: 0, y: 0 };\r\n\r\n if(!this.options.api.getNextPossiblePosition(possibleGridItem)) {\r\n this._toastr.error('Not enough room to fit widget!');\r\n\r\n return;\r\n }\r\n\r\n const firstPossiblePosition: GridsterItem = this.options.api.getFirstPossiblePosition(possibleGridItem);\r\n\r\n this.loading = true;\r\n\r\n try {\r\n const dashboard: Dashboard = await this._dashboardDataService.addToDashboard(widget.widgetId, firstPossiblePosition);\r\n\r\n this.dashboard.availableWidgets = dashboard.availableWidgets;\r\n const newUserWidgetIdArr: number[] = _.chain(dashboard.userWidgets)\r\n .map('userWidgetId')\r\n .difference(_.map(this.dashboard.userWidgets, 'userWidgetId'))\r\n .value();\r\n\r\n const newUserWidget: UserWidget = _.find(dashboard.userWidgets, {userWidgetId: newUserWidgetIdArr[0]});\r\n newUserWidget.minItemCols = newUserWidget.widget.width;\r\n newUserWidget.minItemRows = newUserWidget.widget.height;\r\n\r\n this.dashboard.userWidgets.push(newUserWidget);\r\n } finally {\r\n this.loading = false;\r\n }\r\n\r\n }\r\n\r\n async removeWidget(userWidgetId: any): Promise {\r\n userWidgetId = userWidgetId as number;\r\n\r\n this.loading = true;\r\n\r\n try {\r\n const dashboard: Dashboard = await this._dashboardDataService.removeFromDashboard(userWidgetId);\r\n\r\n this.dashboard.availableWidgets = dashboard.availableWidgets;\r\n\r\n const removedIdx: number = _.findIndex(this.dashboard.userWidgets, {userWidgetId: userWidgetId});\r\n this.dashboard.userWidgets.splice(removedIdx, 1);\r\n } finally {\r\n this.loading = false;\r\n }\r\n\r\n }\r\n\r\n toggleDesignMode(): void {\r\n if(!this.designMode && !this.dashboard.userWidgets.length) {\r\n this._upgradeNavigationServiceHandler.transitionTo(this._upgradeNavigationServiceHandler.getCurrentState(),\r\n {}, {\r\n reload: true\r\n });\r\n }\r\n this.options.draggable.enabled = this.designMode;\r\n this.options.resizable.enabled = this.designMode;\r\n this.options.displayGrid = this.designMode ? 'always' : 'none';\r\n this.options.enableEmptyCellClick = this.designMode;\r\n\r\n this._productAnalyticsService.logEvent('click-design-mode', {\r\n 'designMode': this.designMode ? 'on' : 'off'\r\n });\r\n\r\n this.options.api.optionsChanged();\r\n }\r\n\r\n async resetToDefault(): Promise {\r\n if ((await this._messageBoxService.open({\r\n buttons: MessageBoxButtons.YesNo,\r\n message: 'This will delete all of your dashboard settings; are you sure?',\r\n title: 'Confirm resetting dashboard to defaults'\r\n })) === MessageBoxResult.Yes) {\r\n this.loading = true;\r\n\r\n try {\r\n this.setDashboard(await this._dashboardDataService.resetDashboard());\r\n this.designMode = false;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n\r\n async toggleShowDashboard(): Promise {\r\n await this._dashboardDataService.updateShowDashboardUserSetting(this.isShowDashboard);\r\n }\r\n\r\n private setDashboard(dashboard: Dashboard): void {\r\n dashboard.userWidgets = _.map(dashboard.userWidgets, (userWidget: UserWidget) => {\r\n userWidget.rows = userWidget.rows || 1;\r\n userWidget.cols = userWidget.cols || 1;\r\n\r\n userWidget.minItemCols = userWidget.widget.width;\r\n userWidget.minItemRows = userWidget.widget.height;\r\n\r\n if (userWidget.widget.widgetId === 4) {\r\n userWidget.useLightIcon = true;\r\n }\r\n\r\n return userWidget;\r\n });\r\n\r\n this.dashboard = dashboard;\r\n }\r\n\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface DatabaseProcessListGridActionCellRendererParams extends ICellRendererParams {\r\n killProcess: (params: DatabaseProcessListGridActionCellRendererParams) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n ``\r\n})\r\nexport class DatabaseProcessListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: DatabaseProcessListGridActionCellRendererParams;\r\n\r\n agInit(params: DatabaseProcessListGridActionCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const DATABASE_PROCESS_LIST_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'database-process-list.kill-process',\r\n tooltipText: 'Kill the process.'\r\n }\r\n];\r\n","import { Injectable } from '@angular/core';\r\nimport { BaseRepository } from '../../Common/Data/base.repository';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class DatabaseRepository extends BaseRepository{\r\n constructor(httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n private _baseUrl: string = '/api/database/';\r\n\r\n getRunningProcesses(): Observable {\r\n return this.httpGet(`${this._baseUrl}getRunningProcesses`);\r\n }\r\n\r\n killProcesses(sessionIds: number[]): Observable {\r\n return this.httpPost(`${this._baseUrl}killProcesses`, sessionIds);\r\n }\r\n\r\n clearCache(): Observable {\r\n return this.httpPost(`${this._baseUrl}clearCache`, {});\r\n }\r\n\r\n clearCacheEntries(planHandles: string[]): Observable {\r\n return this.httpPost(`${this._baseUrl}clearCacheEntries`, planHandles);\r\n }\r\n\r\n searchCachePlan(searchString: string): Observable {\r\n return this.httpGet(`${this._baseUrl}plans/${encodeURIComponent(searchString)}`);\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Object NameCache Object TypeObject TypeHandle
{{ entry.objectName }}{{ entry.cacheObjectType }}{{ entry.objectType }}{{ (entry.planHandle.length > 10) ? (entry.planHandle | slice:0:10) + '...' : (entry.planHandle) }}\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { DatabaseRepository } from '../database.repository';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { MessageBoxButtons, MessageBoxOptions, MessageBoxResult, MessageBoxService } from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\n\r\n@Component({\r\n selector: 'database-clear-cache-entry',\r\n templateUrl: './databaseClearCacheEntry.component.html',\r\n styleUrls: ['./databaseClearCacheEntry.component.scss']\r\n})\r\nexport class DatabaseClearCacheEntryComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(\r\n private _bsModalRef : BsModalRef,\r\n private _databaseRepository: DatabaseRepository,\r\n private _messageBoxService: MessageBoxService\r\n ) {\r\n }\r\n params: void;\r\n result: void;\r\n objectName: string;\r\n planEntries: Core.PlanCacheModel[];\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n ngOnInit(): void {\r\n this.planEntries = [];\r\n }\r\n\r\n close(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async searchObject(): Promise {\r\n const busyMessage = 'Loading';\r\n\r\n this.busyIndicatorMessageManager.add('Loading', busyMessage);\r\n\r\n try {\r\n this.planEntries = await lastValueFrom(this._databaseRepository.searchCachePlan(this.objectName));\r\n }\r\n finally {\r\n this.busyIndicatorMessageManager.remove(busyMessage);\r\n }\r\n }\r\n\r\n async clearPlanEntry(entry: Core.PlanCacheModel) {\r\n const confirmOptions = {\r\n message: 'Are you sure you wish to clear this cache entry?',\r\n buttons: MessageBoxButtons.YesNo\r\n } as MessageBoxOptions;\r\n\r\n const result = await this._messageBoxService.open(confirmOptions);\r\n\r\n if (result === MessageBoxResult.Yes) {\r\n const busyMessage = 'Clearing cache';\r\n\r\n this.busyIndicatorMessageManager.add('Clearing cache', busyMessage);\r\n\r\n try {\r\n await lastValueFrom(this._databaseRepository.clearCacheEntries([entry.planHandle]));\r\n this.planEntries = await lastValueFrom(this._databaseRepository.searchCachePlan(this.objectName));\r\n }\r\n finally {\r\n this.busyIndicatorMessageManager.remove(busyMessage);\r\n }\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Database Processes\r\n \r\n

\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n","import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { DatabaseRepository } from '../database.repository';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../Compliance/AgGrid';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { BehaviorSubject, lastValueFrom, Subscription } from 'rxjs';\r\nimport {\r\n DatabaseProcessListGridActionCellRendererComponent,\r\n DatabaseProcessListGridActionCellRendererParams\r\n} from './agGridActionCellRenderer.component';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxOptions,\r\n MessageBoxResult, MessageBoxService\r\n} from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { DATABASE_PROCESS_LIST_HELP } from './processList.component.help';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { DatabaseClearCacheEntryComponent } from '../Database-Clear-Cache-Entry/databaseClearCacheEntry.component';\r\n\r\n@Component({\r\n selector: 'database-process-list',\r\n templateUrl: './processList.component.html',\r\n styleUrls: ['./processList.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ProcessListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _databaseRepository: DatabaseRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _helpService: HelpService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _weissmanModalService: WeissmanModalService\r\n ) {\r\n }\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridId: System.Guid = 'F3B74B92-6EEC-43F0-962D-D15BED9BFEAB';\r\n isInitialized: boolean = false;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Core.DatabaseProcessModel).sessionId)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withSort()\r\n .withTextSelection()\r\n .build();\r\n agGridReady: boolean;\r\n loadingData: boolean;\r\n isBulkDeleteVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n private _gridApi: GridApi;\r\n private _sourceData: Core.DatabaseProcessModel[];\r\n private _selectedRowsSub: Subscription;\r\n private _isSelectingRangeSub: Subscription;\r\n private _selectedRows: number[] = [];\r\n\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(DATABASE_PROCESS_LIST_HELP);\r\n\r\n if (!(this._restrictService.isInRole(Roles.ALLOWMANAGESYSTEM))) {\r\n this._navigateToUnauthorized();\r\n return;\r\n }\r\n\r\n await this._loadData();\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n this._isSelectingRangeSub && this._isSelectingRangeSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe((selected: Compliance.SelectedRowsModel) => {\r\n this._selectedRows = (selected.selectAllRows) ? this._sourceData.map(x => x.sessionId) : selected.selectedRows;\r\n this.isBulkDeleteVisible$.next(this._selectedRows.length !== 0);\r\n });\r\n\r\n this._isSelectingRangeSub = this.gridTracker.isSelectingRange$.subscribe(loading => {\r\n if (!loading) {\r\n this.isBulkDeleteVisible$.next(this.gridTracker.hasSelectedRows());\r\n } else {\r\n this.isBulkDeleteVisible$.next(false);\r\n }\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'sessionId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n },\r\n {\r\n headerName: 'Row Number',\r\n field: 'rowNumber',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Blocking Row Number',\r\n field: 'blockingRowNumber',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Session ID',\r\n field: 'sessionId',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Status',\r\n field: 'status',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Blocking Session ID',\r\n field: 'blockingSessionId',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Elapsed Time (ms)',\r\n field: 'totalElapsedTime',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Query Text',\r\n field: 'queryText',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Wait Type',\r\n field: 'waitType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Wait Resource',\r\n field: 'waitResource',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'CPU Time',\r\n field: 'cpuTime',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Row Count',\r\n field: 'rowCount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Logical Reads',\r\n field: 'logicalReads',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Reads',\r\n field: 'reads',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Writes',\r\n field: 'writes',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'User ID',\r\n field: 'userId',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Host Name',\r\n field: 'hostName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Program Name',\r\n field: 'programName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Database',\r\n field: 'database',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Schema',\r\n field: 'schema',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Procedure',\r\n field: 'procedure',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Command',\r\n field: 'command',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Wait Time',\r\n field: 'waitTime',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Last Wait Type',\r\n field: 'lastWaitType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Isolation',\r\n field: 'transactionIsolationLevel',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: DatabaseProcessListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n killProcess: this._killProcess.bind(this)\r\n } as DatabaseProcessListGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'rowNumber',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.sizeColumnsToFit();\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n async refresh(): Promise {\r\n await this._loadData();\r\n }\r\n\r\n async bulkKill(): Promise {\r\n await this._killProcesses(this._selectedRows);\r\n }\r\n\r\n async clearCacheEntry(): Promise {\r\n await this._weissmanModalService.showAsync(DatabaseClearCacheEntryComponent, null, 'modal-lg');\r\n }\r\n\r\n async clearCache(): Promise {\r\n const confirmOptions = {\r\n message: 'Are you sure you wish to clear cache?',\r\n buttons: MessageBoxButtons.OKCancel\r\n } as MessageBoxOptions;\r\n\r\n const result = await this._messageBoxService.open(confirmOptions);\r\n\r\n if (result === MessageBoxResult.OK) {\r\n const busyRef = this._busyService.show({message: 'Clearing cache'});\r\n\r\n try {\r\n await lastValueFrom(this._databaseRepository.clearCache());\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n }\r\n\r\n private async _loadData(): Promise {\r\n const busyRef = this._busyService.show({ message: 'Loading' });\r\n\r\n try {\r\n this._sourceData = await lastValueFrom(this._databaseRepository.getRunningProcesses());\r\n this._setRowData();\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n private _setRowData(): void {\r\n if (!(this._gridApi)) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkDeleteVisible$.next(false);\r\n\r\n this._gridApi.setRowData(this._sourceData);\r\n }\r\n\r\n private _navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n private async _killProcess(params: DatabaseProcessListGridActionCellRendererParams): Promise {\r\n const process = params.data as Core.DatabaseProcessModel;\r\n\r\n await this._killProcesses([process.sessionId]);\r\n }\r\n\r\n private async _killProcesses(sessionIds: number[]): Promise {\r\n let confirmationMessage = 'Are you sure you wish to kill ';\r\n\r\n if (sessionIds.length === 1) {\r\n confirmationMessage += `process ${sessionIds[0]}`;\r\n } else {\r\n confirmationMessage += `processes ${sessionIds.join(', ')}`;\r\n }\r\n\r\n const confirmOptions = {\r\n message: `${confirmationMessage}?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n } as MessageBoxOptions;\r\n\r\n const result = await this._messageBoxService.open(confirmOptions);\r\n\r\n if (result === MessageBoxResult.OK) {\r\n const progressMessage = `Killing the process${sessionIds.length !== 1 ? 'es' : ''}`;\r\n const busyRef = this._busyService.show({message: progressMessage});\r\n\r\n let success: boolean = false;\r\n\r\n try {\r\n await lastValueFrom(this._databaseRepository.killProcesses(sessionIds));\r\n success = true;\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n if (success) {\r\n await this._loadData();\r\n }\r\n }\r\n }\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n const queryResultModel: Compliance.QueryResultModel = {\r\n lastModifiedTimestamp: new Date(),\r\n totalRows: rows.length,\r\n totalValidRows: rows.length,\r\n data: rows.map((x) => {\r\n const process = x.data as Core.DatabaseProcessModel;\r\n return process && process.sessionId;\r\n })\r\n };\r\n\r\n return Promise.resolve(queryResultModel);\r\n }\r\n}\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormControl } from '@angular/forms';\r\nimport { Ng2StateDeclaration, UIRouter } from '@uirouter/angular';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { FeatureFlagsService } from '../Common/FeatureFlags/feature-flags-service';\r\nimport { RestrictService, Roles } from '../Common/Permissions/restrict.service';\r\n\r\ninterface DiagnosticsOption {\r\n name: string;\r\n route: string;\r\n isShown: () => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'diagnostics',\r\n templateUrl: './diagnostics.component.html',\r\n styleUrls: ['./diagnostics.component.scss']\r\n})\r\nexport class DiagnosticsComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _featureFlagService: FeatureFlagsService,\r\n private readonly _router: UIRouter,\r\n private readonly _restrictService: RestrictService\r\n ) {\r\n }\r\n\r\n diagnosticControl: FormControl = new FormControl();\r\n diagnosticOptions: DiagnosticsOption[] = [];\r\n\r\n private _hasAdminRole: boolean;\r\n private _hasAdminOperationsView: boolean;\r\n private _hasAdminOperationsEdit: boolean;\r\n private _hasAllowManageSystem: boolean;\r\n\r\n private _allDiagnosticOptions: DiagnosticsOption[] = [\r\n {\r\n name: 'About',\r\n route: 'diagnostic.about',\r\n isShown: () => this._hasAdminOperationsView || this._hasAdminOperationsEdit\r\n },\r\n {\r\n name: 'Database',\r\n route: 'diagnostic.database',\r\n isShown: () => this._hasAllowManageSystem\r\n },\r\n {\r\n name: 'Error Log',\r\n route: 'diagnostic.errorLog',\r\n isShown: () => this._hasAdminOperationsView || this._hasAdminOperationsEdit\r\n },\r\n {\r\n name: 'Long-Running Processes',\r\n route: 'diagnostic.longRunningProcess',\r\n isShown: () => this._hasAdminOperationsView || this._hasAdminOperationsEdit\r\n },\r\n {\r\n name: 'Smart, AV, Report Queries',\r\n route: 'diagnostic.queryInfo',\r\n isShown: () => this._hasAdminOperationsView || this._hasAdminOperationsEdit\r\n },\r\n {\r\n name: 'Attachment Download Tool',\r\n route: 'diagnostic.attachmentDownload',\r\n isShown: () => this._hasAdminOperationsView || this._hasAdminOperationsEdit\r\n }\r\n ];\r\n\r\n private _destroy$: Subject = new Subject();\r\n private _destroyTransitionHook: any;\r\n\r\n ngOnInit(): void {\r\n this._hasAdminOperationsEdit = this._restrictService.isInRole(Roles.ADMINOPERATIONSEDIT);\r\n this._hasAdminOperationsView = this._restrictService.isInRole(Roles.ADMINOPERATIONSVIEW);\r\n this._hasAllowManageSystem = this._restrictService.isInRole(Roles.ALLOWMANAGESYSTEM);\r\n\r\n this._hasAdminRole = this._hasAdminOperationsView;\r\n\r\n if (!this._hasAdminRole) {\r\n this._router.stateService.go('home', {});\r\n }\r\n\r\n this.diagnosticOptions = this._allDiagnosticOptions.filter(x => x.isShown());\r\n\r\n this._setDiagnosticControlValue(this._router.globals.current);\r\n\r\n this._destroyTransitionHook = this._router.transitionService.onSuccess({}, (transition) => {\r\n this._setDiagnosticControlValue(this._router.globals.current);\r\n });\r\n\r\n this.diagnosticControl.valueChanges.pipe(takeUntil(this._destroy$)).subscribe((value) => {\r\n this._router.stateService.transitionTo(value, {});\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._destroyTransitionHook();\r\n }\r\n\r\n private _setDiagnosticControlValue(routerState: Ng2StateDeclaration): void {\r\n if (routerState.name === 'diagnostic') {\r\n return;\r\n }\r\n const option = this.diagnosticOptions.find(x => x.route === routerState.name);\r\n if (option) {\r\n this.diagnosticControl.setValue(option.route);\r\n } else {\r\n console.warn('No route found for', routerState.name);\r\n this._router.stateService.go('home', {});\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n

Diagnostic

\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../Compliance/AgGrid';\r\nimport { ErrorLogRepository } from '../errorLog.repository';\r\n\r\nexport class ErrorLogListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n readonly gridApi: GridApi,\r\n private readonly _errorLogRepository: ErrorLogRepository\r\n ) { super(gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'id', value: Core.ErrorLogInfoPropertyEnum.Id },\r\n { name: 'guid', value: Core.ErrorLogInfoPropertyEnum.Guid },\r\n { name: 'date', value: Core.ErrorLogInfoPropertyEnum.Date },\r\n { name: 'userId', value: Core.ErrorLogInfoPropertyEnum.UserId },\r\n { name: 'contactName', value: Core.ErrorLogInfoPropertyEnum.ContactName },\r\n { name: 'message', value: Core.ErrorLogInfoPropertyEnum.Message },\r\n { name: 'machineName', value: Core.ErrorLogInfoPropertyEnum.MachineName },\r\n { name: 'httpMethod', value: Core.ErrorLogInfoPropertyEnum.HttpMethod },\r\n { name: 'route', value: Core.ErrorLogInfoPropertyEnum.Route }\r\n ];\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.ErrorLogInfoSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n\r\n const result = await lastValueFrom(this._errorLogRepository.getList(searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ErrorLogListGridActionCellRendererParams extends ICellRendererParams {\r\n viewDetails: (params: ErrorLogListGridActionCellRendererParams) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n ``\r\n})\r\nexport class ErrorLogListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ErrorLogListGridActionCellRendererParams;\r\n errorLog: Core.ErrorLogModel;\r\n\r\n agInit(params: ErrorLogListGridActionCellRendererParams): void {\r\n this.params = params;\r\n this.errorLog = params.data as Core.ErrorLogModel;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable, Subject } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class ErrorLogService {\r\n private _refreshSubject: Subject = new Subject();\r\n\r\n get refresh$(): Observable { return this._refreshSubject.asObservable(); }\r\n\r\n async refresh(): Promise {\r\n this._refreshSubject.next();\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Error Log\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { ColDef, GridApi, GridReadyEvent, GridOptions } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from '../../../Compliance/AgGrid';\r\nimport { ErrorLogListAgGridDataSource } from './agGridDataSource';\r\nimport { WeissmanDateTimeFormatPipe } from '../../../UI-Lib/Pipes';\r\nimport { Subscription } from 'rxjs';\r\nimport { ErrorLogService } from '../errorLog.service';\r\nimport { ErrorLogRepository } from '../errorLog.repository';\r\nimport { ErrorLogListGridActionCellRendererComponent, ErrorLogListGridActionCellRendererParams } from './agGridActionCellRenderer.component';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { ErrorLogDetailsComponent, ErrorLogDetailsParams } from '../Error-Log-Details/errorLogDetails.component';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\n\r\n@Component({\r\n selector: 'error-log-list',\r\n templateUrl: './errorLogList.component.html',\r\n styleUrls: ['./errorLogList.component.scss']\r\n})\r\nexport class ErrorLogListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _dateTimePipe: WeissmanDateTimeFormatPipe,\r\n private readonly _errorLogRepository: ErrorLogRepository,\r\n private readonly _errorLogService: ErrorLogService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler) {\r\n }\r\n\r\n gridId: System.Guid = '0735BCF2-E246-4F49-8CDB-AAFF1C9C46A0';\r\n isInitialized: boolean = false;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n agGridReady: boolean;\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: ErrorLogListAgGridDataSource;\r\n private _refreshSub: Subscription;\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n ngOnInit(): void {\r\n if (!(this._restrictService.isInRole(Roles.ADMINOPERATIONSVIEW) || this._restrictService.isInRole(Roles.ADMINOPERATIONSEDIT))) {\r\n this.navigateToUnauthorized();\r\n return;\r\n }\r\n\r\n this._refreshSub = this._errorLogService.refresh$.subscribe(() => {\r\n this._refreshDataSource();\r\n });\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._refreshSub && this._refreshSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'GUID',\r\n field: 'guid',\r\n width: AgGridColumns.textColumnWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'ID',\r\n field: 'id',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n },\r\n {\r\n headerName: 'User',\r\n field: 'contactName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Host Name',\r\n field: 'machineName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Message',\r\n field: 'message',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Route',\r\n field: 'route',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'HTTP Method',\r\n field: 'httpMethod',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Date',\r\n field: 'date',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._dateTimePipe.transform(params.value, true) : ''\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: ErrorLogListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this._viewDetails.bind(this)\r\n } as ErrorLogListGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'date',\r\n sort: 'desc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n this.agGridReady = true;\r\n }\r\n\r\n async refresh(): Promise {\r\n const busyRef = this._busyService.show({ message: 'Loading' });\r\n\r\n try {\r\n await this._errorLogService.refresh();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n private async _viewDetails(params: ErrorLogListGridActionCellRendererParams): Promise {\r\n const errorLog = params.data as Core.ErrorLogModel;\r\n if (!errorLog) {\r\n return;\r\n }\r\n\r\n const detailParams: ErrorLogDetailsParams = {\r\n errorLogId: errorLog.id,\r\n errorLogGuid: null\r\n };\r\n\r\n await this._modalService.showAsync(ErrorLogDetailsComponent, detailParams, 'modal-xl');\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this._gridDataSource = new ErrorLogListAgGridDataSource(this._gridApi, this._errorLogRepository);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n}\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../Compliance/AgGrid';\r\nimport { QueryInfoRepository } from '../queryInfo.repository';\r\n\r\nexport class QueryInfoListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n readonly gridApi: GridApi,\r\n private readonly _queryInfoRepository: QueryInfoRepository\r\n ) { super(gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'id', value: Core.QueryInfoPropertyEnum.QueryInfoID },\r\n { name: 'queryTypeName', value: Core.QueryInfoPropertyEnum.QueryTypeName },\r\n { name: 'createDate', value: Core.QueryInfoPropertyEnum.CreateDate },\r\n { name: 'queryName', value: Core.QueryInfoPropertyEnum.QueryName },\r\n { name: 'contactName', value: Core.QueryInfoPropertyEnum.ContactName },\r\n { name: 'totalElapsedTimeMs', value: Core.QueryInfoPropertyEnum.TotalElapsedTimeMs },\r\n { name: 'queryText', value: Core.QueryInfoPropertyEnum.QueryText },\r\n { name: 'count', value: Core.QueryInfoPropertyEnum.Count },\r\n { name: 'savedSearchID', value: Core.QueryInfoPropertyEnum.SavedSearchID }\r\n ];\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.QueryInfoSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n\r\n const result = await lastValueFrom(this._queryInfoRepository.getList(searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface QueryInfoListGridActionCellRendererParams extends ICellRendererParams {\r\n viewDetails: (params: QueryInfoListGridActionCellRendererParams) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n ``\r\n})\r\nexport class QueryInfoListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: QueryInfoListGridActionCellRendererParams;\r\n queryInfo: Core.QueryInfoModel;\r\n\r\n agInit(params: QueryInfoListGridActionCellRendererParams): void {\r\n this.params = params;\r\n this.queryInfo = params.data as Core.QueryInfoModel;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { QueryInfoRepository } from '../queryInfo.repository';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\n\r\nexport interface QueryInfoDetailsParams {\r\n queryInfoId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'query-info-details',\r\n templateUrl: './queryInfoDetails.component.html',\r\n styleUrls: ['./queryInfoDetails.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class QueryInfoDetailsComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _queryInfoRepository: QueryInfoRepository) { }\r\n\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n params: QueryInfoDetailsParams;\r\n result: void;\r\n\r\n queryInfo: Core.QueryInfoModel;\r\n\r\n async ngOnInit(): Promise {\r\n\r\n const busyMsgId = 'loading';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsgId);\r\n\r\n try {\r\n this.queryInfo = await lastValueFrom(this._queryInfoRepository.get(this.params.queryInfoId));\r\n }\r\n finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable, Subject } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class QueryInfoService {\r\n private _refreshSubject: Subject = new Subject();\r\n\r\n get refresh$(): Observable { return this._refreshSubject.asObservable(); }\r\n\r\n async refresh(): Promise {\r\n this._refreshSubject.next();\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n Query Info\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { ColDef, GridApi, GridReadyEvent, GridOptions } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from '../../../Compliance/AgGrid';\r\nimport { QueryInfoListAgGridDataSource } from './agGridDataSource';\r\nimport { WeissmanDateTimeFormatPipe } from '../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { Subscription } from 'rxjs';\r\nimport { QueryInfoService } from '../queryInfo.service';\r\nimport { QueryInfoRepository } from '../queryInfo.repository';\r\nimport { QueryInfoListGridActionCellRendererComponent, QueryInfoListGridActionCellRendererParams } from './agGridActionCellRenderer.component';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { QueryInfoDetailsComponent, QueryInfoDetailsParams } from '../Query-Info-Details/queryInfoDetails.component';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\n\r\n@Component({\r\n selector: 'query-info-list',\r\n templateUrl: './queryInfoList.component.html',\r\n styleUrls: ['./queryInfoList.component.scss']\r\n})\r\nexport class QueryInfoListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _dateTimePipe: WeissmanDateTimeFormatPipe,\r\n private readonly _queryInfoRepository: QueryInfoRepository,\r\n private readonly _queryInfoService: QueryInfoService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler) {\r\n }\r\n\r\n gridId: System.Guid = 'FE5B3FA9-B369-4EDF-9A30-530FB50B768F';\r\n isInitialized: boolean = false;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: QueryInfoListAgGridDataSource;\r\n private _refreshSub: Subscription;\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n ngOnInit(): void {\r\n if (!(this._restrictService.isInRole(Roles.ADMINOPERATIONSVIEW) || this._restrictService.isInRole(Roles.ADMINOPERATIONSEDIT))) {\r\n this.navigateToUnauthorized();\r\n return;\r\n }\r\n\r\n this._refreshSub = this._queryInfoService.refresh$.subscribe(() => {\r\n this._refreshDataSource();\r\n });\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._refreshSub && this._refreshSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'QueryTypeName',\r\n field: 'queryTypeName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'ID',\r\n field: 'id',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n },\r\n {\r\n headerName: 'User',\r\n field: 'contactName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Query Name',\r\n field: 'queryName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'TotalElapsedTimeMs',\r\n field: 'totalElapsedTimeMs',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Count',\r\n field: 'count',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'SavedSearchID',\r\n field: 'savedSearchID',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Error',\r\n field: 'error',\r\n //width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Date',\r\n field: 'createDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._dateTimePipe.transform(params.value, true) : ''\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: QueryInfoListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this._viewDetails.bind(this)\r\n } as QueryInfoListGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'date',\r\n sort: 'desc'\r\n }\r\n ];\r\n\r\n this._gridApi.paginationSetPageSize(50);\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n async refresh(): Promise {\r\n const busyRef = this._busyService.show({ message: 'Loading' });\r\n\r\n try {\r\n await this._queryInfoService.refresh();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n private async _viewDetails(params: QueryInfoListGridActionCellRendererParams): Promise {\r\n const queryInfo = params.data as Core.QueryInfoModel;\r\n if (!queryInfo) {\r\n return;\r\n }\r\n\r\n const detailParams: QueryInfoDetailsParams = {\r\n queryInfoId: queryInfo.id\r\n };\r\n\r\n await this._modalService.showAsync(QueryInfoDetailsComponent, detailParams, 'modal-lg');\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this._gridDataSource = new QueryInfoListAgGridDataSource(this._gridApi, this._queryInfoRepository);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

Instance Settings

\r\n
\r\n \r\n
\r\n
\r\n \r\n Processing...\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n {{instanceModel.instanceName}}\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n {{instanceModel.customerCompanyName}}\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n

Document Intake & Processing Services

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n Processing...\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n {{selectedUserName}}\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n {{instanceModel.documentIntakeAndProcessingClientSpecialInstructions}}\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { UserInstanceService } from '../../../User/userInstance.service';\r\nimport { TypeaheadCompany } from '../../Company/Company.Picker.Component';\r\nimport { InstanceRepository } from '../instance.repository';\r\nimport { AccountService } from '../../../User/account.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { TeamService } from 'src/app/Team/team.service';\r\n\r\n@Component({\r\n selector: 'instance-info-panel',\r\n templateUrl: './instanceInfoPanel.component.html',\r\n styleUrls: ['./instanceInfoPanel.component.scss'],\r\n}) export class InstanceInfoPanelComponent implements OnInit {\r\n\r\n constructor(\r\n private readonly _instanceRepo: InstanceRepository,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _accountService: AccountService,\r\n private readonly _navigationService: NavigationService,\r\n private toastr: ToastrService,\r\n private readonly _teamService: TeamService,\r\n private readonly _messageBoxService: MessageBoxService\r\n ) {\r\n\r\n }\r\n\r\n isEditSettings = false;\r\n isEditDocumentIntakeAndProcessing: boolean = false;\r\n showSpinnerSettings = false;\r\n showSpinnerDocumentIntakeAndProcessing: boolean = false;\r\n instanceId: number;\r\n instanceModel: Core.InstanceDTO = {} as Core.InstanceDTO;\r\n initialInstanceModel: Core.InstanceDTO;\r\n companyModel: TypeaheadCompany = null;\r\n users: Core.UserTeamModel[] = [];\r\n selectedUser: Core.UserTeamModel;\r\n placeholder: string = 'Search User...';\r\n showDocumentIntakeAndProcessingPanel: boolean = false;\r\n\r\n async ngOnInit() {\r\n this.instanceId = this._userInstanceService.getSelectedInstance().instanceId;\r\n await this.loadData();\r\n }\r\n\r\n async loadData() {\r\n this.showSpinnerSettings = true;\r\n this.showSpinnerDocumentIntakeAndProcessing = true;\r\n\r\n try {\r\n const responses = await Promise.all([\r\n lastValueFrom(this._instanceRepo.get(this.instanceId)),\r\n this._teamService.getAllAssignableUsers(false, false, undefined, undefined, undefined)\r\n ]);\r\n\r\n this.instanceModel = responses[0];\r\n this.users = responses[1];\r\n\r\n if(!this.instanceModel) {\r\n return;\r\n }\r\n\r\n this.showDocumentIntakeAndProcessingPanel = this.instanceModel.instanceId != this._userInstanceService.SystemInstanceId &&\r\n this.instanceModel.instanceId != this._userInstanceService.RyanInstanceId;\r\n\r\n this.companyModel = {\r\n companyID: this.instanceModel.customerCompanyId,\r\n companyName: this.instanceModel.customerCompanyName,\r\n isFavorite: false,\r\n instanceIdFilter: null\r\n };\r\n\r\n if (this.showDocumentIntakeAndProcessingPanel && this.instanceModel.documentIntakeAndProcessingAssignToRyan) {\r\n this.selectedUser = this.users.find(x => x.userID == this.instanceModel.documentIntakeAndProcessingClientUserId);\r\n }\r\n }\r\n finally {\r\n this.showSpinnerSettings = false;\r\n this.showSpinnerDocumentIntakeAndProcessing = false;\r\n }\r\n }\r\n\r\n setEditSettings() {\r\n this.isEditSettings = true;\r\n this._setEdit();\r\n }\r\n\r\n setEditDocumentIntakeAndProcessing() {\r\n this.isEditDocumentIntakeAndProcessing = true;\r\n this._setEdit();\r\n }\r\n\r\n async saveSettings() {\r\n this.showSpinnerSettings = true;\r\n\r\n const hasError = await this._save(true);\r\n\r\n if (!hasError) {\r\n this.isEditSettings = false;\r\n\r\n //name changed - reload window\r\n if(this.initialInstanceModel.instanceName !== this.instanceModel.instanceName) {\r\n window.location.reload();\r\n }\r\n }\r\n }\r\n\r\n cancelSettings() {\r\n this.isEditSettings = false;\r\n this._cancel();\r\n }\r\n\r\n async saveDocumentIntakeAndProcessing() {\r\n this.showSpinnerDocumentIntakeAndProcessing = true;\r\n\r\n const hasError = await this._save(false);\r\n\r\n if (!hasError) {\r\n this.isEditDocumentIntakeAndProcessing = false;\r\n }\r\n }\r\n\r\n get canSaveDocumentIntakeAndProcessingSettings(): boolean {\r\n return this.instanceModel.documentIntakeAndProcessingAssignToRyan && !!this.instanceModel.documentIntakeAndProcessingClientUserId ||\r\n !this.instanceModel.documentIntakeAndProcessingAssignToRyan && !this.instanceModel.documentIntakeAndProcessingClientUserId && !this.instanceModel.documentIntakeAndProcessingClientSpecialInstructions;\r\n }\r\n\r\n cancelDocumentIntakeAndProcessing() {\r\n this.isEditDocumentIntakeAndProcessing = false;\r\n this._cancel();\r\n }\r\n\r\n companySelected(company:TypeaheadCompany) {\r\n this.instanceModel.customerCompanyId = company.companyID;\r\n this.instanceModel.customerCompanyName = company.companyName;\r\n }\r\n\r\n userChosen(user: Core.UserTeamModel): void {\r\n this.instanceModel.documentIntakeAndProcessingClientUserId = user ? user.userID : null;\r\n this.instanceModel.documentIntakeAndProcessingClientTeamId = user ? user.teamID : null;\r\n }\r\n\r\n get selectedUserName(): string {\r\n return this.selectedUser ? `${this.selectedUser.firstName} ${this.selectedUser.lastName}` : null;\r\n }\r\n\r\n async assignToRyanChanged($event: any): Promise {\r\n if (!$event.target.checked && this.initialInstanceModel.documentIntakeAndProcessingAssignToRyan) {\r\n const answer = await this._messageBoxService.open(\r\n {\r\n message: `Are you sure? By unchecking this selection you are indicating that you wish to discontinue Ryan's document intake and processing services. Ryan will no longer perform these services on behalf of ${this.instanceModel.customerCompanyName}.`,\r\n buttons: MessageBoxButtons.YesNo});\r\n if (answer === MessageBoxResult.Yes) {\r\n this.instanceModel.documentIntakeAndProcessingAssignToRyan = false;\r\n this.instanceModel.documentIntakeAndProcessingClientUserId = null;\r\n this.instanceModel.documentIntakeAndProcessingClientTeamId = null;\r\n this.instanceModel.documentIntakeAndProcessingClientSpecialInstructions = null;\r\n this.selectedUser = null;\r\n } else {\r\n $event.target.checked = true;\r\n }\r\n } else {\r\n this.instanceModel.documentIntakeAndProcessingAssignToRyan = $event.target.checked;\r\n }\r\n }\r\n\r\n private async _save(resetRoles: boolean): Promise {\r\n let success: boolean = false;\r\n\r\n try {\r\n await lastValueFrom(this._instanceRepo.update(this.instanceModel));\r\n\r\n if (resetRoles) {\r\n await this._accountService.resetRoles();\r\n }\r\n\r\n await this.loadData();\r\n\r\n this._navigationService.disableNavWarning();\r\n\r\n success = true;\r\n }\r\n finally {\r\n this.showSpinnerSettings = false;\r\n this.showSpinnerDocumentIntakeAndProcessing = false;\r\n }\r\n\r\n return !success;\r\n }\r\n\r\n private _setEdit() {\r\n this.initialInstanceModel = {...this.instanceModel};\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n }\r\n\r\n private _cancel() {\r\n this.instanceModel = this.initialInstanceModel;\r\n this._navigationService.disableNavWarning();\r\n\r\n if (this.instanceModel.documentIntakeAndProcessingAssignToRyan) {\r\n this.selectedUser = this.users.find(x => x.userID == this.instanceModel.documentIntakeAndProcessingClientUserId);\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n

My Instances

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
 InstanceCompanyStatusActions
\r\n \r\n {{instanceInviteStatus.instanceName}}\r\n \r\n {{instanceInviteStatus.companyName}}\r\n \r\n {{getStatus(instanceInviteStatus)}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
You will need to logout for your changes to take effect in the application
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Subject } from 'rxjs';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { InstanceRepository } from './instance.repository';\r\n\r\n@Component({\r\n selector: 'manage-invitations',\r\n templateUrl: './manageInvitations.component.html',\r\n styleUrls: ['./manageInvitations.component.scss']\r\n})\r\nexport class ManageInvitationsComponent implements OnInit {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private _toastrService: ToastrService,\r\n private upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler) {\r\n }\r\n\r\n params: any;\r\n result: any;\r\n statuses: Core.ContactStatusDTO[] = [];\r\n changesMade: boolean = false;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n async ngOnInit(): Promise {\r\n this.statuses = (await this._instanceRepository.getCurrentUsersContactInviteStatuses()).filter(s => s.contactId !== null);\r\n\r\n //only has one instance (must have arrived via direct link or url) : send user home\r\n if(this.statuses.length === 1) {\r\n this.upgradeNavigationServiceHandler.go('home', {});\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n getHomeIndicator(status: Core.ContactStatusDTO):string {\r\n return status.isHomeInstance ? ' ' : '';\r\n }\r\n\r\n getStatus(status: Core.ContactStatusDTO):string {\r\n if(status.active === false) {\r\n return 'Inactive';\r\n }\r\n else if(status.invite === false) {\r\n return 'Invite Pending';\r\n }\r\n else {\r\n if(status.hidden === false) {\r\n return 'Invite Accepted';\r\n }\r\n else {\r\n return 'Hidden';\r\n }\r\n }\r\n }\r\n\r\n async acceptInvitation(contactId: number): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Accepting Invitation' });\r\n try {\r\n const success = await this._instanceRepository.acceptInvite(contactId);\r\n if(success)\r\n this._toastrService.success('Invitation accepted.');\r\n this.statuses = await this._instanceRepository.getCurrentUsersContactInviteStatuses();\r\n this.changesMade = true;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async rejectInvitation(contactId: number): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Rejecting Invitation' });\r\n try {\r\n const success = await this._instanceRepository.rejectInvite(contactId);\r\n if(success)\r\n this._toastrService.success('Invitation was rejected.');\r\n this.statuses = await this._instanceRepository.getCurrentUsersContactInviteStatuses();\r\n this.changesMade = true;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async toggleVisibility(contactId: number): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Toggling Visibility' });\r\n try {\r\n const success = await this._instanceRepository.toggleInstance(contactId);\r\n if(success)\r\n this._toastrService.success('Instance visibility toggled.');\r\n this.statuses = await this._instanceRepository.getCurrentUsersContactInviteStatuses();\r\n this.changesMade = true;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","import { HelpContent } from \"../UI-Lib/Help-Tooltip\";\r\n\r\n \r\nexport const MOVE_COPY_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'move.copy-csrmode',\r\n tooltipText: \"This controls how already created tasks on the source entity will be treated during the requested operation. \"\r\n + \" CSR themselves will not be modified at the source or destination. The following applies to open tasks only. \"\r\n + \" Always Preserve Existing means no changes will be made (default) \"\r\n + \"Preserve Overridden Only means tasks with overridden assignments will remain unchanged, but all others will be updated to the destination's CSR config. \"\r\n + \" Assume Destination means that all tasks will be updated to match the destination's current CSR configuration. \"\r\n + \" Future tasks will follow the CSR configuration of the entity at the time of creation.\",\r\n hasIcon: true\r\n },\r\n];\r\n ","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\nimport { MoveCopyPayload } from './move.copy.entity.component';\r\n\r\n@Injectable()\r\nexport class MoveCopyEntityService {\r\n constructor(private http: SDHttpService) { }\r\n\r\n copyMoveEntity(payload: MoveCopyPayload): Promise {\r\n return this.http.post('/api/copymoveentity', payload);\r\n }\r\n\r\n getSiteYears(siteId: number): Promise {\r\n return this.http.get(`/api/parcel/years/${ siteId}`);\r\n }\r\n}\r\n","
\r\n \r\n
\r\n

\r\n Move \r\n Copy \r\n Sites\r\n \r\n Parcels\r\n \r\n

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n Beginning Year:\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n

Items to\r\n Move\r\n Copy\r\n

\r\n
\r\n
\r\n
\r\n \r\n {{companyName}}\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n {{siteName}}\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n There are errors that need to be corrected before this can be can be movedcopied. Check the Client Services panel.\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

Destination

\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

Confirm

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n

\r\n The following\r\n Site(s)\r\n \r\n Parcel(s)\r\n \r\n

\r\n
    \r\n
  • {{getEntityName(id)}}
  • \r\n
\r\n
\r\n Will be Moved\r\n Copied\r\n
\r\n \r\n \r\n
\r\n
\r\n

\r\n To this Company\r\n Site\r\n

\r\n
    \r\n
  • {{targetCompany.companyName}}
  • \r\n
  • {{getTargetSiteName(moveCopyPayload.destEntityID)}}
  • \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n

MovingCopying

\r\n

= sourceIds.length\" class=\"text-start\">Done

\r\n \r\n

{{getEntityName(sourceIds[sourceIdIdx])}}

\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n

Cancelling...

\r\n \r\n
\r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { ActivityService } from '../Common/Activity/activity.service';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { StateService } from '../Common/States/States.Service';\r\nimport { StateSummary } from '../Common/States/state.model';\r\nimport { SiteSummary } from './Site/Site.Model';\r\nimport { CompanyService } from './Company/company.service';\r\nimport { ParcelService } from './Parcel/parcel.service.upgrade';\r\nimport { TypeaheadCompany } from './Company/Company.Picker.Component';\r\nimport { MoveCopyEntityService } from './move.copy.entity.service';\r\nimport { ParcelSummary } from './Parcel/parcel.models';\r\nimport { SiteRepository } from '../Core-Repositories';\r\nimport { InstanceRepository } from './Instance/instance.repository';\r\nimport { UserInstanceService } from '../User/userInstance.service';\r\nimport { RestrictService, Roles } from '../Common/Permissions/restrict.service';\r\nimport { FeatureFlagsService } from '../Common/FeatureFlags/feature-flags-service';\r\nimport { TimerService } from '../UI-Lib/Utilities';\r\nimport { MessageModalService } from '../UI-Lib/Message-Box/messageModal.service';\r\nimport { ClientServiceResponsibilityService } from '../Client-Services/clientServiceResponsibility.service';\r\n\r\nimport * as _ from 'lodash';\r\nimport { HelpService } from '../UI-Lib/Help-Tooltip';\r\nimport { MOVE_COPY_HELP } from './move.copy.entity.component.help';\r\n\r\nexport enum Entity {\r\n COMPANY = 1, SITE = 5, PARCEL = 6\r\n}\r\n\r\nexport enum CopyMoveCSRModeEnum {\r\n AlwaysPreserveExisting = 1,\r\n PreserveOverriddenOnly = 2,\r\n AssumeDestination = 3\r\n}\r\n\r\nexport class MoveCopyPayload {\r\n constructor(entityTypeID: number, actionId: number, firstYear: number) {\r\n this.action = actionId;\r\n this.firstYear = firstYear;\r\n this.destEntityID = null;\r\n this.sourceEntityTypeID = entityTypeID;\r\n this.sourceIDs = [];\r\n this.includeAttachments = false;\r\n this.includeAppeals = false;\r\n this.includeComments = false;\r\n this.csrMode = CopyMoveCSRModeEnum.AlwaysPreserveExisting;\r\n\r\n }\r\n\r\n action: number;\r\n firstYear: number;\r\n destEntityID: number;\r\n sourceEntityTypeID: number;\r\n sourceIDs: number[];\r\n includeAttachments: boolean;\r\n csrMode: CopyMoveCSRModeEnum;\r\n interInstanceCopy: boolean;\r\n includeComments: boolean;\r\n includeAppeals: boolean;\r\n ignorePendingReturnError: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'move-copy-entity',\r\n templateUrl: './move.copy.entity.component.html'\r\n})\r\nexport class MoveCopyEntityComponent implements OnInit {\r\n constructor(private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _stateService: StateService,\r\n private readonly _siteService: SiteRepository,\r\n private readonly _companyService: CompanyService,\r\n private readonly _parcelService: ParcelService,\r\n private readonly _moveCopyEntityService: MoveCopyEntityService,\r\n private readonly _instanceRepository: InstanceRepository,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _featureFlagService: FeatureFlagsService,\r\n private readonly _timer: TimerService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _csrService: ClientServiceResponsibilityService,\r\n private readonly _activityService: ActivityService,\r\n private readonly _helpService: HelpService\r\n ) {\r\n }\r\n\r\n @Input() isCopy: boolean;\r\n\r\n entities = Entity;\r\n launchingEntity: number;\r\n states: StateSummary[];\r\n sites: SiteSummary[];\r\n parcels: ParcelSummary[];\r\n allParcels: ParcelSummary[];\r\n\r\n companyId: string;\r\n siteId: string;\r\n parcelId: string;\r\n\r\n companyName: string;\r\n siteName: string;\r\n targetCompany: TypeaheadCompany;\r\n moveCopyPayload: MoveCopyPayload;\r\n\r\n selectedStateId: number;\r\n stateSites: SiteSummary[];\r\n\r\n loading: boolean = false;\r\n awaitingConfirm: boolean = false;\r\n isInactive: boolean = false;\r\n excludeInactive: boolean = true;\r\n showSiteNumber: boolean = false;\r\n loadingSites: boolean = false;\r\n\r\n years: number[];\r\n sourceIds: number[];\r\n sourceIdIdx: number;\r\n isExecuting: boolean = false;\r\n userCancelled: boolean = false;\r\n hasCsrErrors: boolean = false;\r\n\r\n CopyMoveCSRModeEnum = CopyMoveCSRModeEnum;\r\n\r\n hasInstanceAdminPermission: boolean = false;\r\n instances: Array = [];\r\n targetInstanceId: number;\r\n\r\n async ngOnInit() {\r\n this.companyId = this._upgradeNavigationServiceHandler.getQuerystringParam('companyID');\r\n this.siteId = this._upgradeNavigationServiceHandler.getQuerystringParam('siteID');\r\n this.parcelId = this._upgradeNavigationServiceHandler.getQuerystringParam('parcelID');\r\n this.isInactive = (this._upgradeNavigationServiceHandler.getQuerystringParam('isInactive') === 'true');\r\n this.sourceIdIdx = 0;\r\n this.sourceIds = [];\r\n this._helpService.setContent(MOVE_COPY_HELP) \r\n\r\n if (this.isInactive) {\r\n this.excludeInactive = false;\r\n }\r\n\r\n if (this.parcelId && this._areValidIds([this.parcelId, this.siteId, this.companyId])) {\r\n this.launchingEntity = this.entities.PARCEL;\r\n } else if (this.siteId && this._areValidIds([this.siteId, this.companyId])) {\r\n this.launchingEntity = this.entities.SITE;\r\n } else if (this._areValidIds([this.companyId])) {\r\n this.launchingEntity = this.entities.COMPANY;\r\n } else {\r\n this._goToHome();\r\n return;\r\n }\r\n this.loading = true;\r\n\r\n try {\r\n this.companyName = await this._companyService.getCompanyName(Number(this.companyId));\r\n this.hasCsrErrors = await this._csrService.doesEntityHaveErrantResponsibilities({ entityTypeId: this.launchingEntity, entityId: +(this.parcelId || this.siteId || this.companyId) });\r\n\r\n //get instance id for the company - search must be scoped to the single instance\r\n this.targetInstanceId = await lastValueFrom(this._instanceRepository.getEntityInstanceId('company', parseInt(this.companyId)));\r\n\r\n this.hasInstanceAdminPermission = this._restrictService.isInRole(Roles.ALLOWCOPYMOVEINSTANCE);\r\n if (this.hasInstanceAdminPermission) {\r\n this.instances = [this._userInstanceService.allInstancesItem].concat(this._userInstanceService.getUserInstanceMembership());\r\n this.targetInstanceId = this._userInstanceService.getSelectedInstance().instanceId;\r\n }\r\n\r\n await this._setupEntity();\r\n } finally {\r\n this.loading = false;\r\n }\r\n\r\n await this._getBeginningYears();\r\n }\r\n\r\n async _getBeginningYears(): Promise {\r\n const result = await this._getYears();\r\n\r\n if (!result || !result.length) {\r\n return;\r\n }\r\n\r\n this.years = result;\r\n\r\n if (!this.moveCopyPayload.firstYear || !_.includes(this.years, this.moveCopyPayload.firstYear)) {\r\n this.moveCopyPayload.firstYear = this.years[0];\r\n }\r\n }\r\n\r\n async getSitesByCompanyId(companyId: number): Promise {\r\n //need to determine if user has selected an instance from the copy site/parcel instance selector or not\r\n //if so then we use a different URI\r\n let sites;\r\n\r\n if (this.targetInstanceId !== this._userInstanceService.getSelectedInstance().instanceId) {\r\n sites = await lastValueFrom(this._siteService.getSiteListByCompanyIdOtherInstance(Number(companyId), this.excludeInactive));\r\n } else {\r\n sites = await lastValueFrom(this._siteService.getSiteListByCompanyId(Number(companyId), this.excludeInactive));\r\n }\r\n\r\n this.sites = _.sortBy(sites, 'siteName');\r\n\r\n const states = await this._stateService.getSummary();\r\n this.states = this._getFilteredStates(states);\r\n }\r\n\r\n stateSelected(isTarget?: boolean): void {\r\n this.stateSites = this._getFilteredSites(isTarget);\r\n\r\n if (this.stateSites.length) {\r\n if (isTarget) {\r\n this.moveCopyPayload.destEntityID = this.stateSites[0].siteID;\r\n } else {\r\n this.sourceIds = [this.stateSites[0].siteID];\r\n }\r\n }\r\n }\r\n\r\n selectedEntitiesChanged(eventTarget: EventTarget): void {\r\n const options = (eventTarget as HTMLSelectElement).selectedOptions;\r\n this.sourceIds = _.map(options, option => Number(option.value));\r\n }\r\n\r\n async movingSitesSelected(): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n this.moveCopyPayload = new MoveCopyPayload(this.entities.SITE, this.isCopy ? 2 : 1, this.moveCopyPayload ? this.moveCopyPayload.firstYear : null);\r\n\r\n if (this.targetCompany) {\r\n this.moveCopyPayload.destEntityID = this.targetCompany.companyID;\r\n }\r\n\r\n await this.getSitesByCompanyId(+this.companyId);\r\n this.selectedStateId = _.find(this.sites, { siteID: Number(this.siteId) }).stateID;\r\n this.stateSelected();\r\n this.sourceIds = [Number(this.siteId)];\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async movingParcelsSelected(): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n this.moveCopyPayload = new MoveCopyPayload(this.entities.PARCEL, this.isCopy ? 2 : 1, this.moveCopyPayload ? this.moveCopyPayload.firstYear : null);\r\n\r\n this.siteName = await lastValueFrom(this._siteService.getSiteName(Number(this.siteId)));\r\n\r\n const parcels = await this._parcelService.getParcelListBySiteId(Number(this.siteId), this.excludeInactive);\r\n this.allParcels = _.cloneDeep(parcels);\r\n this.parcels = _.sortBy(parcels, 'parcelName');\r\n\r\n if (this.parcels.length) {\r\n if (this.launchingEntity === this.entities.PARCEL) {\r\n this.parcels = _.filter(this.parcels, { parcelID: Number(this.parcelId) });\r\n this.sourceIds = [Number(this.parcelId)];\r\n } else {\r\n this.sourceIds = [this.parcels[0].parcelID];\r\n }\r\n }\r\n\r\n if (this.targetCompany) {\r\n await this.getSitesByCompanyId(this.targetCompany.companyID);\r\n this.selectedStateId = 0;\r\n this.stateSelected(true);\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async targetCompanySelected(e: TypeaheadCompany): Promise {\r\n if (!e || _.isEmpty(e)) {\r\n return;\r\n }\r\n\r\n this.targetCompany = e;\r\n\r\n if (this.moveCopyPayload.sourceEntityTypeID === this.entities.SITE) {\r\n this.moveCopyPayload.destEntityID = this.targetCompany.companyID;\r\n } else {\r\n this.loadingSites = true;\r\n\r\n try {\r\n await this.getSitesByCompanyId(this.targetCompany.companyID);\r\n this.selectedStateId = 0;\r\n this.stateSelected(true);\r\n } finally {\r\n this.loadingSites = false;\r\n }\r\n }\r\n }\r\n\r\n getEntityName(id: number): string {\r\n if (!id) {\r\n return '';\r\n }\r\n\r\n if (this.moveCopyPayload.sourceEntityTypeID === this.entities.SITE) {\r\n return this.getSiteNameWithNumber(_.find(this.stateSites, { siteID: id }));\r\n } else {\r\n const foundParcel = _.find(this.parcels, { parcelID: id }) as ParcelSummary;\r\n return foundParcel.parcelName;\r\n }\r\n }\r\n\r\n getTargetSiteName(id: number): string {\r\n return _.find(this.stateSites, { siteID: Number(id) }).siteName;\r\n }\r\n\r\n async executeMoveCopy(): Promise {\r\n await this._executeMoveCopy(false);\r\n }\r\n\r\n cancelExecute() {\r\n this.isExecuting = false;\r\n this.userCancelled = true;\r\n }\r\n\r\n moveCopyCompleted(): void {\r\n this.isExecuting = false;\r\n\r\n if (this.isCopy) {\r\n return;\r\n }\r\n\r\n if (this.moveCopyPayload.sourceEntityTypeID === this.entities.SITE) {\r\n if (this.launchingEntity === this.entities.SITE) {\r\n this._timer.setTimeout(() => {\r\n this._upgradeNavigationServiceHandler.transitionTo('company', { companyId: this.companyId });\r\n }, 1000);\r\n\r\n return;\r\n }\r\n\r\n this.sites = _.reject(this.sites, (site: SiteSummary) => _.includes(this.sourceIds, site.siteID));\r\n\r\n if (this.sites.length) {\r\n this.states = this._getFilteredStates(this.states);\r\n\r\n if (!_.includes(_.map(this.states, 'stateID'), this.selectedStateId)) {\r\n this.selectedStateId = 0;\r\n }\r\n\r\n this.stateSelected();\r\n } else {\r\n this._upgradeNavigationServiceHandler.transitionTo('company', { companyId: this.companyId });\r\n }\r\n\r\n } else {\r\n // Remove To and From sites from session storage so that activity panel loads fresh data\r\n this._activityService.clearParcelFilterCacheForSite(+this.siteId);\r\n this._activityService.clearParcelFilterCacheForSite(this.moveCopyPayload.destEntityID);\r\n\r\n this.parcels = _.reject(this.parcels, parcel => _.includes(this.sourceIds, parcel.parcelID));\r\n\r\n if (!this.parcels.length) {\r\n\r\n this._upgradeNavigationServiceHandler.transitionTo('site', { companyId: this.companyId, siteId: this.siteId });\r\n }\r\n }\r\n\r\n this.sourceIds = [];\r\n }\r\n\r\n backToEntity(): void {\r\n switch (this.launchingEntity) {\r\n case this.entities.COMPANY:\r\n this._upgradeNavigationServiceHandler.transitionTo('company', { companyId: this.companyId });\r\n break;\r\n\r\n case this.entities.SITE:\r\n this._upgradeNavigationServiceHandler.transitionTo('site', { companyId: this.companyId, siteId: this.siteId });\r\n break;\r\n\r\n case this.entities.PARCEL:\r\n this._upgradeNavigationServiceHandler.transitionTo('parcel', { companyId: this.companyId, siteId: this.siteId, parcelId: this.parcelId });\r\n break;\r\n }\r\n }\r\n\r\n selectAll(entity: string): void {\r\n this.sourceIds = entity === 'sites' ? _.map(this.stateSites, 'siteID') : _.map(this.parcels, 'parcelID');\r\n }\r\n\r\n async siteInactiveStatusChanged(): Promise {\r\n await this._setupEntity();\r\n }\r\n\r\n showSiteNumberStatusChanged(): void {\r\n this.stateSites.sort((s1, s2) => this.getSiteNameWithNumber(s1) < this.getSiteNameWithNumber(s2) ? -1 : 1);\r\n }\r\n\r\n async parcelInactiveStatusChanged(): Promise {\r\n await this.movingParcelsSelected();\r\n }\r\n\r\n private _getFilteredStates(states: StateSummary[]): StateSummary[] {\r\n const siteStateIds = _.chain(this.sites)\r\n .map('stateID')\r\n .uniq()\r\n .value();\r\n\r\n return _.filter(states, (state: StateSummary) => _.includes(siteStateIds, state.stateID));\r\n }\r\n\r\n private _getFilteredSites(isTarget?: boolean): SiteSummary[] {\r\n if (Number(this.selectedStateId)) {\r\n if (this.launchingEntity === this.entities.SITE && !isTarget) {\r\n const launchingSite = _.find(this.sites, { siteID: Number(this.siteId) });\r\n\r\n return [launchingSite];\r\n } else {\r\n return _.chain(this.sites)\r\n .cloneDeep()\r\n .filter({ stateID: Number(this.selectedStateId) })\r\n .value();\r\n }\r\n\r\n } else {\r\n return _.cloneDeep(this.sites);\r\n }\r\n }\r\n\r\n private _getYears(): Promise {\r\n if (this.launchingEntity === this.entities.COMPANY) {\r\n const currentYear = new Date().getFullYear();\r\n\r\n return Promise.resolve(_.range(currentYear - 15, currentYear + 5));\r\n } else if (this.moveCopyPayload.sourceEntityTypeID === this.entities.SITE) {\r\n return this._moveCopyEntityService.getSiteYears(Number(this.siteId));\r\n } else {\r\n return this._parcelService.getParcelYears(Number(this.parcelId));\r\n }\r\n }\r\n\r\n private _areValidIds(args: string[]): boolean {\r\n return _.every(args, (arg: string) => !_.isNaN(Number(arg)));\r\n }\r\n\r\n private _goToHome(): void {\r\n console.warn('Invalid Id');\r\n\r\n this._upgradeNavigationServiceHandler.transitionTo('home', {});\r\n }\r\n\r\n private async _setupCompany(): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n this.moveCopyPayload = new MoveCopyPayload(this.entities.SITE, this.isCopy ? 2 : 1, this.moveCopyPayload ? this.moveCopyPayload.firstYear : null);\r\n await this.getSitesByCompanyId(+this.companyId);\r\n this.selectedStateId = 0;\r\n this.stateSelected();\r\n\r\n await this._getBeginningYears();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n private async _setupEntity(): Promise {\r\n switch (this.launchingEntity) {\r\n case this.entities.COMPANY:\r\n await this._setupCompany();\r\n break;\r\n case this.entities.SITE:\r\n await this.movingSitesSelected();\r\n break;\r\n case this.entities.PARCEL:\r\n await this.movingParcelsSelected();\r\n break;\r\n }\r\n }\r\n\r\n private getSiteNameWithNumber(site: { siteNumber: string, siteName: string }): string {\r\n if (this.showSiteNumber) {\r\n return site.siteNumber ? `${site.siteNumber} - ${site.siteName}` : site.siteName;\r\n } else {\r\n return site.siteName;\r\n }\r\n }\r\n\r\n private async _executeMoveCopy(force: boolean): Promise {\r\n if (this.userCancelled) {\r\n this.userCancelled = false;\r\n return;\r\n }\r\n\r\n if (this.sourceIdIdx >= this.sourceIds.length) {\r\n return;\r\n }\r\n\r\n this.awaitingConfirm = false;\r\n this.isExecuting = true;\r\n\r\n for (let i = 0; i < this.sourceIds.length; i++) {\r\n this.moveCopyPayload.sourceIDs[i] = this.sourceIds[i];\r\n this.sourceIdIdx++;\r\n }\r\n\r\n this.moveCopyPayload.interInstanceCopy = this.targetInstanceId !== this._userInstanceService.getSelectedInstance().instanceId;\r\n this.moveCopyPayload.ignorePendingReturnError = force;\r\n\r\n try {\r\n await this._moveCopyEntityService.copyMoveEntity(this.moveCopyPayload);\r\n await this.executeMoveCopy();\r\n } catch (error) {\r\n if (error.status === 422) {\r\n try {\r\n await this._messageModalService.confirm(error.data.message, 'Warning');\r\n } catch {\r\n this.isExecuting = false;\r\n\r\n return Promise.resolve();\r\n }\r\n this.sourceIdIdx = 0;\r\n await this._executeMoveCopy(true);\r\n } else {\r\n this.cancelExecute();\r\n await this._executeMoveCopy(false);\r\n }\r\n } finally {\r\n\r\n this.sourceIdIdx = 0;\r\n this.moveCopyCompleted();\r\n }\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { UserSettingsService } from '../Account/userSettings.service';\r\nimport { ProductAnalyticsService } from '../Common/Amplitude/productAnalytics.service';\r\nimport { NavigationService } from '../Layout/navigation.service';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { InstanceRights, RestrictService } from '../Common/Permissions/restrict.service';\r\nimport { AccountService } from '../User/account.service';\r\n\r\n@Component({\r\n selector: 'landing',\r\n templateUrl: './landing.component.html',\r\n styleUrls: ['./landing.component.scss']\r\n})\r\nexport class LandingComponent implements OnInit {\r\n constructor(\r\n private userSettingsService: UserSettingsService,\r\n private accountService: AccountService,\r\n private navigationService: NavigationService,\r\n private upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private restrictService: RestrictService,\r\n private _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n userInfo: { isTeamMemberAndAssignable: boolean, firstName: string };\r\n defaultView: LandingViewTypes = LandingViewTypes.MyTasks;\r\n showActionView: boolean = false;\r\n existingDefaultViewSetting: Array;\r\n hasInstancePrivatePermission: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this.hasInstancePrivatePermission = this.restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT) || this.restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW);\r\n\r\n this.existingDefaultViewSetting = this.userSettingsService.getSettingsByGroup(16);\r\n if(this.existingDefaultViewSetting.length) {\r\n this.defaultView = +this.existingDefaultViewSetting[0].value;\r\n }\r\n\r\n this.userInfo = {\r\n isTeamMemberAndAssignable: this.accountService.userData.isTeamMemberAndAssignable,\r\n firstName: this.accountService.userData.firstName\r\n };\r\n\r\n this.defaultViewChange();\r\n }\r\n\r\n defaultViewChange(): void {\r\n // Convert to number\r\n this.defaultView = +this.defaultView;\r\n if(!this.hasInstancePrivatePermission && !this.userInfo.isTeamMemberAndAssignable) {\r\n this.defaultView = LandingViewTypes.None;\r\n }\r\n\r\n switch(this.defaultView) {\r\n case LandingViewTypes.None:\r\n this.showActionView = false;\r\n break;\r\n case LandingViewTypes.MyTasks:\r\n this.showActionView = true;\r\n break;\r\n case LandingViewTypes.MyTeamsTasks:\r\n if(this.hasInstancePrivatePermission) {\r\n this.showActionView = true;\r\n } else {\r\n this.defaultView = LandingViewTypes.None;\r\n this.showActionView = false;\r\n }\r\n break;\r\n }\r\n\r\n //Save new or existing default view setting\r\n let settingUpdated = true;\r\n if(!this.existingDefaultViewSetting.length) {\r\n this.existingDefaultViewSetting.push({\r\n id: 0,\r\n name: 'Dashboard-Default-View',\r\n value: this.defaultView,\r\n groupId: 16,\r\n groupName: 'Dashboard-Default-View',\r\n folderId: 20,\r\n folderName: 'Dashboard-Default-View',\r\n });\r\n } else {\r\n if (_.isEqual(this.existingDefaultViewSetting[0].value, this.defaultView)) {\r\n settingUpdated = false;\r\n }\r\n else {\r\n this.existingDefaultViewSetting[0].value = this.defaultView;\r\n }\r\n }\r\n\r\n if (settingUpdated) {\r\n this.userSettingsService.save(this.existingDefaultViewSetting[0]).then(savedSetting => {\r\n this.existingDefaultViewSetting[0] = savedSetting;\r\n });\r\n }\r\n }\r\n\r\n openQuickSearch(resetFilter: boolean): void {\r\n this._productAnalyticsService.logEvent('initiate-quick-search', { initiateQuickSearch: 'home page' });\r\n this.navigationService.openQuickSearch(resetFilter, 'home');\r\n }\r\n\r\n goToStatePage(): void {\r\n this.upgradeNavigationServiceHandler.go('states', {});\r\n }\r\n\r\n goToDashboard(): void {\r\n this.upgradeNavigationServiceHandler.go('myDashboard', {});\r\n }\r\n}\r\n\r\nexport enum LandingViewTypes {\r\n None = 0,\r\n MyTasks = 1,\r\n MyTeamsTasks = 2\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { lastValueFrom } from 'rxjs';\r\n// TODO: Migrate to @angular/google-maps\r\n// import { MapTypeStyle } from '@agm/core';\r\n\r\n@Injectable()\r\nexport class SiteMapService {\r\n\r\n constructor(private http: HttpClient) {\r\n }\r\n\r\n // TODO: Migrate to @angular/google-maps\r\n //https://mapstyle.withgoogle.com/\r\n mapStyles: google.maps.MapTypeStyle[] = [\r\n {\r\n 'featureType': 'administrative.land_parcel',\r\n 'elementType': 'labels',\r\n 'stylers': [\r\n {\r\n 'visibility': 'off'\r\n }\r\n ]\r\n },\r\n {\r\n 'featureType': 'poi',\r\n 'elementType': 'labels.text',\r\n 'stylers': [\r\n {\r\n 'visibility': 'off'\r\n }\r\n ]\r\n },\r\n {\r\n 'featureType': 'poi.business',\r\n 'stylers': [\r\n {\r\n 'visibility': 'off'\r\n }\r\n ]\r\n },\r\n {\r\n 'featureType': 'road',\r\n 'elementType': 'labels.icon',\r\n 'stylers': [\r\n {\r\n 'visibility': 'off'\r\n }\r\n ]\r\n },\r\n {\r\n 'featureType': 'road.local',\r\n 'elementType': 'labels',\r\n 'stylers': [\r\n {\r\n 'visibility': 'off'\r\n }\r\n ]\r\n },\r\n {\r\n 'featureType': 'transit',\r\n 'stylers': [\r\n {\r\n 'visibility': 'off'\r\n }\r\n ]\r\n }\r\n ];\r\n\r\n getSitesToMap(sitesToMapRequest: Core.SitesToMapRequest): Promise {\r\n return lastValueFrom(this.http.post('/api/GeoMapping/FetchSites', sitesToMapRequest));\r\n }\r\n\r\n getSiteMarkerInfo(siteIds: number[]): Promise {\r\n return lastValueFrom(this.http.post('/api/geomapping/site/markers', { siteIds }));\r\n }\r\n}\r\n","import { Component, Input, OnChanges } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { Address } from '../Common/Models/common.model';\r\n\r\n@Component({\r\n selector: 'site-map-info-window',\r\n template: `\r\n
\r\n \r\n
\r\n
\r\n \r\n
{{selectedMarkerInfo.companyName}}
\r\n

{{selectedMarkerInfo.siteName}}

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
{{type}}
\r\n
{{selectedMarkerInfo.siteClassPrimaryDesc}}
\r\n
\r\n
\r\n
\r\n lat: {{selectedMarkerInfo.address.latitude}}
\r\n lng: {{selectedMarkerInfo.address.longitude}}\r\n
\r\n SqFt: {{selectedMarkerInfo.totalSqFt | number:'1.0-0'}}
\r\n Units: {{selectedMarkerInfo.totalUnits | number:'1.0-0'}}\r\n
\r\n
\r\n `,\r\n styleUrls: ['./site.map.component.scss']\r\n})\r\nexport class SiteMapInfoWindowComponent implements OnChanges {\r\n constructor(private _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler){}\r\n\r\n @Input() siteMarkerInfoArr: Core.SiteMarkerInfo[];\r\n selectedMarkerInfo: Core.SiteMarkerInfo;\r\n\r\n get address() {\r\n return this.selectedMarkerInfo.address as unknown as Address;\r\n }\r\n\r\n ngOnChanges() {\r\n if(this.siteMarkerInfoArr.length) {\r\n this.selectedMarkerInfo = this.siteMarkerInfoArr[0];\r\n }\r\n }\r\n\r\n getAbbrevs(propertyTypeAbbrevs: string): string[] {\r\n return _.words(propertyTypeAbbrevs);\r\n }\r\n\r\n navigateToSite(): void {\r\n const url = this._upgradeNavigationServiceHandler.getHrefFromState('siteRedirect', {entityID: this.selectedMarkerInfo.siteId});\r\n\r\n window.open(url, '_blank');\r\n }\r\n\r\n}\r\n","
\r\n
\r\n
    \r\n
  1. \r\n {{originalSite.company.companyName}}\r\n
  2. \r\n
  3. \r\n {{originalSite.name}}\r\n
  4. \r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Site Map

\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ViewChild } from '@angular/core';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { PropertyTypeService } from '../Common/Services/propertyType.service.upgrade';\r\nimport { Site } from './Site/Site.Model';\r\nimport { Constants } from '../constants.new';\r\nimport * as _ from 'lodash';\r\nimport { SiteClassService } from './Site/siteClass.service';\r\nimport { SiteMapService } from './site.map.service';\r\nimport { BusyIndicatorService } from '../Busy-Indicator';\r\nimport { Subject } from 'rxjs';\r\nimport { debounceTime } from 'rxjs/operators';\r\nimport { SiteService } from './Site/Site.Service.upgrade';\r\nimport { TimerService } from '../UI-Lib/Utilities/timer.service';\r\nimport { GoogleMap, MapInfoWindow, MapMarker } from '@angular/google-maps';\r\n\r\nexport interface MappableSite extends Core.MappableSite {\r\n markerOptions: google.maps.MarkerOptions;\r\n center: google.maps.LatLngLiteral;\r\n}\r\n\r\n@Component({\r\n selector: 'site-map',\r\n templateUrl: './site.map.component.html',\r\n styleUrls: ['./site.map.component.scss']\r\n})\r\nexport class SiteMapComponent implements OnInit {\r\n constructor(private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _propertyTypeService: PropertyTypeService,\r\n private readonly _siteService: SiteService,\r\n private readonly _Constants: Constants,\r\n private readonly _siteClassService: SiteClassService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n public readonly siteMapService: SiteMapService,\r\n private readonly _timer: TimerService\r\n ){}\r\n\r\n @ViewChild(MapInfoWindow, { static: false }) infoWindow: MapInfoWindow;\r\n @ViewChild(GoogleMap, { static: false }) map: GoogleMap;\r\n\r\n originalSite: Site;\r\n isOriginalSiteIncluded: boolean;\r\n windowHover: object = {};\r\n mapOptions: google.maps.MapOptions;\r\n markerOptions: google.maps.MarkerOptions;\r\n infoWindowOptions: google.maps.InfoWindowOptions;\r\n originalCenter: google.maps.LatLngLiteral;\r\n hoveredSiteId: number;\r\n\r\n propertyTypes = [];\r\n siteClasses = [];\r\n\r\n startingZoom: number = 16;\r\n zoom: number = this.startingZoom;\r\n\r\n viewportBounds: Core.GeoMapBounds;\r\n paddedBounds: Core.GeoMapBounds;\r\n\r\n filters: Core.SiteMappingFilters = {\r\n propertyTypeIds: [],\r\n siteClassPrimaryIds: [],\r\n companyIds: []\r\n };\r\n\r\n getNewSites$: Subject = new Subject();\r\n sitesToDisplay: MappableSite[] = [];\r\n siteMarkerInfoArr: Core.SiteMarkerInfo[] = [];\r\n\r\n debouncedGetSiteInfo;\r\n\r\n ngOnInit(): void {\r\n this.mapOptions = { styles: this.siteMapService.mapStyles };\r\n this.markerOptions = { animation: google.maps.Animation.DROP };\r\n this.infoWindowOptions = { maxWidth: 300 };\r\n\r\n this._getSite();\r\n this._getFilters();\r\n\r\n this.debouncedGetSiteInfo = _.debounce(this.getSiteInfo, 250);\r\n\r\n this.getNewSites$.pipe( debounceTime(500) )\r\n .subscribe(() => this._getNewSites() );\r\n }\r\n\r\n private async _getSite(): Promise {\r\n const siteId = +this._upgradeNavigationServiceHandler.getQuerystringParam('siteId');\r\n const companyId = +this._upgradeNavigationServiceHandler.getQuerystringParam('companyId');\r\n\r\n this.originalSite = await this._siteService.load(siteId, companyId);\r\n this.originalCenter = {\r\n lat: this.originalSite?.address.latitude,\r\n lng: this.originalSite?.address.longitude\r\n };\r\n }\r\n\r\n private _getFilters(): void {\r\n this._propertyTypeService.get().then(propertyTypes => this.propertyTypes = propertyTypes);\r\n this._siteClassService.getPrimaries().then(siteClasses => this.siteClasses = _.sortBy(siteClasses, 'siteClassPrimaryDesc'));\r\n }\r\n\r\n private async _getNewSites(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading sites', delay: 0 });\r\n\r\n try {\r\n this.paddedBounds = this._getPaddedBounds();\r\n const filteredSites = (await this.siteMapService.getSitesToMap({ bounds: this.paddedBounds, filters: this.filters })).sites;\r\n\r\n this.isOriginalSiteIncluded = _.some(filteredSites, {siteId: this.originalSite.siteID});\r\n\r\n const filteredSitesNotOnMap = _.differenceBy(filteredSites, this.sitesToDisplay, 'siteId');\r\n const sitesToAdd = _.chain(filteredSitesNotOnMap)\r\n .reject({siteId: this.originalSite.siteID})\r\n .map((site: MappableSite) => {\r\n let iconName: string = 'symbol_iter';\r\n\r\n if(site.siteClassPrimaryID !== undefined) {\r\n iconName = site.stackId ? 'condominium' : this._Constants.SiteClassIcons[site.siteClassPrimaryID];\r\n }\r\n\r\n site.markerOptions = { icon: `/images/google-maps-icons/${iconName}.png` };\r\n\r\n site.center = {\r\n lat: site.latitude,\r\n lng: site.longitude\r\n };\r\n\r\n return site;\r\n })\r\n .value();\r\n\r\n this.sitesToDisplay.push(...sitesToAdd);\r\n\r\n const sitesToRemove = _.differenceBy(this.sitesToDisplay, filteredSites, 'siteId');\r\n _.pullAllBy(this.sitesToDisplay, sitesToRemove, 'siteId');\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n }\r\n\r\n private _getPaddedBounds(): Core.GeoMapBounds {\r\n const startingOffset = 0.01;\r\n const totalOffset = startingOffset * Math.pow(2, this.startingZoom - this.zoom);\r\n\r\n return {\r\n northwestCorner: {\r\n latitude: this.viewportBounds.northwestCorner.latitude + totalOffset,\r\n longitude: this.viewportBounds.northwestCorner.longitude - totalOffset\r\n },\r\n southeastCorner: {\r\n latitude: this.viewportBounds.southeastCorner.latitude - totalOffset,\r\n longitude: this.viewportBounds.southeastCorner.longitude + totalOffset\r\n }\r\n };\r\n }\r\n\r\n propertyTypesSelected(eventTarget: EventTarget): void {\r\n const selectedOptions = (eventTarget as HTMLSelectElement).selectedOptions;\r\n this.filters.propertyTypeIds = _.map(selectedOptions, (option: any) => Number(option.value));\r\n }\r\n\r\n siteClassesSelected(eventTarget: EventTarget): void {\r\n const selectedOptions = (eventTarget as HTMLSelectElement).selectedOptions;\r\n this.filters.siteClassPrimaryIds = _.map(selectedOptions, (option: any) => Number(option.value));\r\n }\r\n\r\n boundsChanged(): void {\r\n const bounds = this.map.getBounds();\r\n const northeastCorner = bounds.getNorthEast();\r\n const southwestCorner = bounds.getSouthWest();\r\n\r\n this.viewportBounds = {\r\n northwestCorner: {\r\n latitude: northeastCorner.lat(),\r\n longitude: southwestCorner.lng()\r\n },\r\n southeastCorner: {\r\n latitude: southwestCorner.lat(),\r\n longitude: northeastCorner.lng()\r\n }\r\n };\r\n }\r\n\r\n zoomChanged(): void {\r\n this.zoom = this.map.getZoom();\r\n }\r\n\r\n mapIdle(): void {\r\n // need to figure out if we've moved beyond the bounds of the buffered viewport\r\n if(!this.paddedBounds // initial call\r\n || this.viewportBounds.northwestCorner.latitude > this.paddedBounds.northwestCorner.latitude\r\n || this.viewportBounds.northwestCorner.longitude < this.paddedBounds.northwestCorner.longitude\r\n || this.viewportBounds.southeastCorner.latitude < this.paddedBounds.southeastCorner.latitude\r\n || this.viewportBounds.southeastCorner.longitude > this.paddedBounds.southeastCorner.longitude) {\r\n this.getNewSites$.next();\r\n }\r\n }\r\n\r\n navigateToCompany(): void {\r\n this._upgradeNavigationServiceHandler.go('company', {companyId: this.originalSite.companyID});\r\n }\r\n\r\n navigateToOriginalSite(): void {\r\n this._upgradeNavigationServiceHandler.go('siteRedirect', {entityID: this.originalSite.siteID});\r\n }\r\n\r\n async getSiteInfo(siteId: number, mapMarker: MapMarker, stackId?: number) {\r\n this.infoWindow.open(mapMarker);\r\n\r\n this.siteMarkerInfoArr = [];\r\n this.hoveredSiteId = siteId;\r\n\r\n let siteIds = [siteId];\r\n\r\n if(stackId) {\r\n siteIds = _.chain(this.sitesToDisplay)\r\n .filter({stackId: stackId})\r\n .map('siteId')\r\n .value();\r\n }\r\n\r\n const siteMarkerInfoGetResult = (await this.siteMapService.getSiteMarkerInfo(siteIds));\r\n this.siteMarkerInfoArr = _.sortBy(siteMarkerInfoGetResult.sites, 'siteName');\r\n }\r\n\r\n mouseOutOfPin(siteId: number): void {\r\n this._timer.setTimeout(() => {\r\n if(this.windowHover[siteId]) {\r\n return;\r\n }\r\n\r\n this.infoWindow.close();\r\n this.debouncedGetSiteInfo.cancel();\r\n }, 150);\r\n }\r\n\r\n limitToParentCompany(e): void {\r\n this.filters.companyIds = e.target.checked ? [this.originalSite.companyID] : [];\r\n }\r\n\r\n mouseEnterWindow(): void {\r\n this.windowHover[this.hoveredSiteId] = true;\r\n }\r\n\r\n mouseleaveWindow() {\r\n this.windowHover[this.hoveredSiteId] = false;\r\n this.infoWindow.close();\r\n this.debouncedGetSiteInfo.cancel();\r\n }\r\n}\r\n","
\r\n
\r\n

Help

\r\n\r\n
\r\n \r\n
\r\n

Help Desk

\r\n
    \r\n
  • Click here to open the\r\n PropertyPoint Help Desk where you can find a growing knowledge base with detailed training articles and additional\r\n Support.
  • \r\n
  • Click here to submit a PropertyPoint User Setup/User Change request
  • \r\n
  • Click here to access an Appeal Application Request Form
  • \r\n
  • Click here to access a Compliance Form Request Form
  • \r\n
  • Click here to access a form to share an Assessment Release Date
  • \r\n
  • Click here to access a form to share a Tax Bill Release Date
  • \r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n

Acknowledgements

\r\n \r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n

Reach out to your Ryan contact or Account Handler if you need assistance with client support or navigation issues.

\r\n

For system issues, click here to open the PropertyPoint Help Desk

\r\n

For the best browsing experience we recommend using Google Chrome.

\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n","import {Component, OnInit} from '@angular/core';\r\nimport {RestrictService} from '../../Common/Permissions/restrict.service';\r\nimport {Constants} from '../../constants.new';\r\n\r\n@Component({\r\n selector: 'help-component',\r\n templateUrl: './_help.html'\r\n})\r\nexport class HelpComponent implements OnInit {\r\n constructor(private restrictService: RestrictService,\r\n private constants: Constants) {}\r\n\r\n hasViewPermission: boolean = false;\r\n editingInProgress: boolean;\r\n\r\n ngOnInit(): void {\r\n this.hasViewPermission = this.restrictService.isInRole(this.constants.Roles['RYANPRIVATEITEMSVIEW']) ||\r\n this.restrictService.isInRole(this.constants.Roles['RYANPRIVATEITEMSEDIT']);\r\n }\r\n\r\n}\r\n","
\r\n
\r\n

Welcome, {{userInfo.firstName}}

\r\n
\r\n
\r\n \r\n
\r\n\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n

Quick Search

\r\n

Navigate to a Company, Site, or Parcel. Access Quick Search by clicking the magnifying glass icon in the upper right-hand corner, or press alt-q.

\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n

States

\r\n

Here, you will find a list of states to which you can navigate. From there, access assessment classes, collectors, and assessors.

\r\n
\r\n
\r\n
\r\n\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import {Component} from '@angular/core';\r\nimport { DashboardDataService } from '../Dashboard/dashboard.data.service';\r\n\r\n@Component({\r\n selector: 'landing-selector',\r\n template: `\r\n \r\n \r\n `,\r\n styleUrls: ['./landing.selector.component.scss']\r\n})\r\nexport class LandingSelectorComponent {\r\n constructor(private dashboardDataService: DashboardDataService) {\r\n this.showDashboard = dashboardDataService.getShowDashBoardUserSetting();\r\n }\r\n\r\n showDashboard: boolean;\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n","import { ButtonState, ButtonStyle } from '@ace/shared';\r\nimport {\r\n Component,\r\n EventEmitter,\r\n forwardRef, HostBinding,\r\n Input,\r\n OnDestroy,\r\n OnInit,\r\n Output,\r\n ViewEncapsulation\r\n} from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { IButtonInput } from '../Button/button.component';\r\n\r\nexport interface IButtonGroupInput {\r\n /** Child buttons to display */\r\n buttons: IButtonInput[];\r\n\r\n singleSelect?: {\r\n activeStyle: ButtonStyle;\r\n inactiveStyle: ButtonStyle;\r\n activeState: ButtonState;\r\n inactiveState: ButtonState;\r\n };\r\n}\r\n\r\n@Component({\r\n selector: 'ws-ace-button-group',\r\n templateUrl: './buttonGroup.component.html',\r\n styleUrls: ['./buttonGroup.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => AceButtonGroupComponent),\r\n multi: true\r\n }\r\n ]\r\n})\r\nexport class AceButtonGroupComponent implements ControlValueAccessor, OnInit, OnDestroy {\r\n constructor(private readonly _router: UIRouter) {\r\n }\r\n @Input() input!: IButtonGroupInput;\r\n @Input() selectedButton: IButtonInput;\r\n\r\n @HostBinding('attr.singleSelect') get singleSelect() {\r\n return !!this.input.singleSelect || null;\r\n }\r\n\r\n @Output() selectedButtonChange: EventEmitter = new EventEmitter();\r\n @Output() buttonClicked: EventEmitter = new EventEmitter();\r\n\r\n buttons: IButtonInput[];\r\n\r\n // Angular Form methods\r\n\r\n onChange: (val: IButtonInput) => void;\r\n onTouched: () => void;\r\n\r\n private _destroyTransitionHook: any;\r\n\r\n writeValue(value: IButtonInput): void {\r\n this.selectedButton = value;\r\n }\r\n\r\n setDisabledState(disabled: boolean): void {\r\n this.buttons.forEach((button) => {\r\n button.isDisabled = disabled;\r\n });\r\n }\r\n\r\n next(): void {\r\n this.selectedButtonChange.emit(this.selectedButton);\r\n if (this.onChange) {\r\n this.onChange(this.selectedButton);\r\n }\r\n if (this.onTouched) {\r\n this.onTouched();\r\n }\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouched = fn;\r\n }\r\n\r\n ngOnInit() {\r\n this.buttons = this.input.buttons;\r\n if (this.input.singleSelect) {\r\n this._destroyTransitionHook = this._router.transitionService.onSuccess({}, () => {\r\n this._validateRouterChange();\r\n });\r\n this._validateRouterChange();\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n if (this._destroyTransitionHook) {\r\n this._destroyTransitionHook();\r\n }\r\n }\r\n\r\n onButtonClicked(button: IButtonInput): void {\r\n if (this.input.singleSelect) {\r\n this.selectedButton = button;\r\n this._updateButtonStyles();\r\n this.next();\r\n }\r\n\r\n this.buttonClicked.emit(button);\r\n }\r\n\r\n private _validateRouterChange(): void {\r\n const route = this._router.globals.current;\r\n this.selectedButton = this.buttons.find((b) => b.routerOutlet === route.name);\r\n this._updateButtonStyles();\r\n }\r\n\r\n private _updateButtonStyles(): void {\r\n this.buttons.forEach((b) => {\r\n if (b === this.selectedButton) {\r\n b.style = this.input.singleSelect.activeStyle;\r\n b.state = this.input.singleSelect.activeState;\r\n } else {\r\n b.style = this.input.singleSelect.inactiveStyle;\r\n b.state = this.input.singleSelect.inactiveState;\r\n }\r\n });\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n

{{ pageTitle }}

\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { IButtonGroupInput } from '../../../UI-Lib/ACE/Button-Group/buttonGroup.component';\r\nimport { SearchCategoryType, UserSaveService } from '../userSave.service';\r\n\r\n@Component({\r\n selector: 'save-page',\r\n templateUrl: './savePage.component.html',\r\n styleUrls: ['./savePage.component.scss']\r\n})\r\nexport class SavePageComponent implements OnInit {\r\n constructor(private readonly _userSaveService: UserSaveService,\r\n private readonly _router: UIRouter) {\r\n }\r\n\r\n @Input() pageTitle: string;\r\n @Input() newButtonLabel: string;\r\n @Input() tabSetConfig: IButtonGroupInput;\r\n\r\n @Output() newButtonClicked: EventEmitter = new EventEmitter();\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._userSaveService.selectedUserSavePage$.pipe(takeUntil(this._destroy$))\r\n .subscribe((userSavePage) => {\r\n if (!userSavePage) {\r\n return;\r\n }\r\n\r\n if (!userSavePage.currentSelectedFilter) {\r\n userSavePage.currentSelectedFilter = SearchCategoryType.System;\r\n const current = this._router.globals.current;\r\n this._router.stateService.transitionTo(`${current.name}.${userSavePage.currentSelectedFilter}`);\r\n }\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n}\r\n","import { ButtonSize, ButtonState, ButtonStyle } from '@ace/shared';\r\nimport { Component } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { ActionViewPersistenceService } from '../../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { IButtonGroupInput } from '../../UI-Lib/ACE/Button-Group/buttonGroup.component';\r\nimport { SearchCategoryType } from '../User-Save/userSave.service';\r\n\r\n@Component({\r\n selector: 'saved-action-view',\r\n templateUrl: './savedActionView.component.html',\r\n styleUrls: ['./savedActionView.component.scss']\r\n})\r\nexport class SavedActionViewComponent {\r\n constructor(private readonly _router: UIRouter,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService) {\r\n }\r\n\r\n tabSetConfig: IButtonGroupInput = {\r\n buttons: [\r\n {\r\n id: SearchCategoryType.System,\r\n content: 'SYSTEM ACTION VIEWS',\r\n routerOutlet: 'savedActionView.system',\r\n size: ButtonSize.Small\r\n },\r\n {\r\n id: SearchCategoryType.User,\r\n content: 'MY SAVED ACTION VIEWS',\r\n routerOutlet: 'savedActionView.user',\r\n size: ButtonSize.Small\r\n },\r\n {\r\n id: SearchCategoryType.Favorite,\r\n content: 'FAVORITES',\r\n routerOutlet: 'savedActionView.favorite',\r\n size: ButtonSize.Small\r\n }\r\n ],\r\n singleSelect: {\r\n activeStyle: ButtonStyle.Primary,\r\n inactiveStyle: null,\r\n activeState: ButtonState.Info,\r\n inactiveState: ButtonState.Info\r\n }\r\n };\r\n\r\n newActionView(): void {\r\n this._actionViewPersistenceService.clearSavedData();\r\n this._productAnalyticsService.logEvent('click-act-new');\r\n this._router.stateService.transitionTo('actionview');\r\n }\r\n}\r\n","\r\n\r\n","import { ButtonSize, ButtonState, ButtonStyle } from '@ace/shared';\r\nimport { Component } from '@angular/core';\r\nimport { IButtonGroupInput } from '../../UI-Lib/ACE/Button-Group/buttonGroup.component';\r\nimport { SearchCategoryType } from '../User-Save/userSave.service';\r\n\r\n@Component({\r\n selector: 'saved-report',\r\n templateUrl: './savedReport.component.html',\r\n styleUrls: ['./savedReport.component.scss']\r\n})\r\nexport class SavedReportComponent {\r\n\r\n tabSetConfig: IButtonGroupInput = {\r\n buttons: [\r\n {\r\n id: SearchCategoryType.System,\r\n content: 'SYSTEM REPORTS',\r\n routerOutlet: 'savedReport.system',\r\n size: ButtonSize.Small\r\n },\r\n {\r\n id: SearchCategoryType.User,\r\n content: 'MY SAVED REPORTS',\r\n routerOutlet: 'savedReport.user',\r\n size: ButtonSize.Small\r\n }\r\n ],\r\n singleSelect: {\r\n activeStyle: ButtonStyle.Primary,\r\n inactiveStyle: null,\r\n activeState: ButtonState.Info,\r\n inactiveState: ButtonState.Info\r\n }\r\n };\r\n}\r\n","
\r\n
\r\n
\r\n {{ userPageConfig?.tabTitle }} ({{ categoryTotal }})\r\n
\r\n
\r\n
\r\n
\r\n {{ category.categoryName }} ({{ category.savedItemList.length }})\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n {{ col.name }}\r\n
\r\n
\r\n {{ row[col.key] }}\r\n {{ row[col.key] | weissmanDateFormat}}\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n","\r\n\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { SmartSearchService } from '../../../Search/Advanced/smartSearch.service';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { SearchCategoryType, UserSaveService } from '../userSave.service';\r\nimport {\r\n ContextMenuItem,\r\n SaveCategory,\r\n SaveListItem,\r\n SaveTabColumn,\r\n SaveTabColumnType,\r\n UserSavePage\r\n} from '../userSavePage.model';\r\n\r\ninterface CategoryContextMenuItem {\r\n name: string;\r\n onClick: (category: SaveCategory) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'save-tab-content',\r\n templateUrl: './saveTabContent.component.html',\r\n styleUrls: ['./saveTabContent.component.scss']\r\n})\r\nexport class SaveTabContentComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _userSaveService: UserSaveService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _messageModalService: MessageModalService) {\r\n }\r\n\r\n @Input() userPageConfig: UserSavePage;\r\n\r\n tabTitle: string;\r\n columns: SaveTabColumn[] = [];\r\n columnType = SaveTabColumnType;\r\n\r\n selectedFilter: SearchCategoryType;\r\n searchCategoryTypes = SearchCategoryType;\r\n selectedCategory: SaveCategory;\r\n categories: SaveCategory[] = [];\r\n loadingRowMenu: boolean;\r\n categoryMenuOptions: CategoryContextMenuItem[] = [\r\n { name: 'Delete', onClick: this._deleteCategory.bind(this) }\r\n ];\r\n rowMenuOptions: ContextMenuItem[] = [];\r\n hoveredRow: SaveListItem;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n get categoryTotal(): number {\r\n return this.categories?.reduce((acc, curr) => acc + curr.savedItemList.length, 0);\r\n }\r\n\r\n ngOnInit(): void {\r\n this.selectedFilter = this.userPageConfig.currentSelectedFilter;\r\n this.categories = this.userPageConfig.categories;\r\n this.columns = this.userPageConfig.columns;\r\n\r\n if (!this.selectedCategory) {\r\n this._checkSelectedCategory();\r\n }\r\n\r\n this._userSaveService.selectedUserSavePage$.pipe(takeUntil(this._destroy$)).subscribe((page) => {\r\n if (!this.userPageConfig) {\r\n this.userPageConfig = page;\r\n }\r\n\r\n if (page) {\r\n this.selectedFilter = page.currentSelectedFilter;\r\n this.categories = page.categories;\r\n this._checkSelectedCategory();\r\n }\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n selectCategory(category: SaveCategory): void {\r\n this.selectedCategory = category;\r\n // Save to service for returning to page\r\n this.userPageConfig.currentSelectedCategory = category;\r\n }\r\n\r\n selectRow(row: SaveListItem): void {\r\n if (row.amplitudeEvent) {\r\n this._productAnalyticsService.logEvent(row.amplitudeEvent.event, row.amplitudeEvent.properties);\r\n }\r\n this.userPageConfig.navigateTo(row, this.selectedCategory.categoryType);\r\n }\r\n\r\n async toggleFavorite(row: SaveListItem): Promise {\r\n row.isFavorite = !row.isFavorite;\r\n this.userPageConfig.refreshLocalList();\r\n this.categories = this.userPageConfig.categories;\r\n this._checkSelectedCategory();\r\n await this.userPageConfig.toggleFavorite(row);\r\n await this._userSaveService.refreshCurrentList();\r\n }\r\n\r\n hasMenuOptions(category: SaveCategory, index: number, row: SaveListItem): boolean {\r\n return this.userPageConfig.contextMenu(category, index)\r\n .filter(x => !x.isDisabled(row)).length > 0;\r\n }\r\n\r\n getMenuOptions(isOpen: boolean, category: SaveCategory, index: number): void {\r\n if (isOpen) {\r\n this.loadingRowMenu = true;\r\n this.rowMenuOptions = this.userPageConfig.contextMenu(category, index);\r\n this.loadingRowMenu = false;\r\n }\r\n }\r\n\r\n private _checkSelectedCategory(): void {\r\n if (this.userPageConfig.currentSelectedCategory) {\r\n const categoryId = this.userPageConfig.currentSelectedCategory.categoryId;\r\n const category = this.categories.find((c) => c.categoryId === categoryId);\r\n if (category) {\r\n this.selectCategory(category);\r\n } else {\r\n this.selectCategory(this.categories[0]);\r\n }\r\n } else {\r\n this.selectCategory(this.categories[0]);\r\n }\r\n }\r\n\r\n private async _deleteCategory(category: SaveCategory): Promise {\r\n try {\r\n await this._messageModalService.confirm(`Are you sure you want to delete ${ category.categoryName }?`);\r\n } catch (e) {\r\n return;\r\n }\r\n\r\n if (category.savedItemList.length > 0) {\r\n await this._messageModalService.alert(`The search category ${ category.categoryName } is currently not empty. Please make sure the category is empty and try again.`);\r\n return;\r\n }\r\n\r\n await this._smartSearchService.deleteSearchCategory(category);\r\n await this._userSaveService.refreshCurrentList();\r\n }\r\n}\r\n","import { ButtonSize, ButtonState, ButtonStyle } from '@ace/shared';\r\nimport { Component } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { AdvancedSearchPersistenceService } from '../../Search/Advanced/advancedSearchPersistence.service';\r\nimport { IButtonGroupInput } from '../../UI-Lib/ACE/Button-Group/buttonGroup.component';\r\nimport { SearchCategoryType } from '../User-Save/userSave.service';\r\n\r\n@Component({\r\n selector: 'saved-smart',\r\n templateUrl: './savedSmart.component.html',\r\n styleUrls: ['./savedSmart.component.scss']\r\n})\r\nexport class SavedSmartComponent {\r\n constructor(private readonly _router: UIRouter,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService) {\r\n }\r\n\r\n tabSetConfig: IButtonGroupInput = {\r\n buttons: [\r\n {\r\n id: SearchCategoryType.System,\r\n content: 'SYSTEM SMARTS',\r\n routerOutlet: 'savedSmart.system',\r\n size: ButtonSize.Small\r\n },\r\n {\r\n id: SearchCategoryType.User,\r\n content: 'MY SAVED SMARTS',\r\n routerOutlet: 'savedSmart.user',\r\n size: ButtonSize.Small\r\n },\r\n {\r\n id: SearchCategoryType.Favorite,\r\n content: 'FAVORITES',\r\n routerOutlet: 'savedSmart.favorite',\r\n size: ButtonSize.Small\r\n }\r\n ],\r\n singleSelect: {\r\n activeStyle: ButtonStyle.Primary,\r\n inactiveStyle: ButtonStyle.Secondary,\r\n activeState: ButtonState.Info,\r\n inactiveState: ButtonState.Info\r\n }\r\n };\r\n\r\n newSmart(): void {\r\n this._advancedSearchPersistenceService.clearSearchData();\r\n this._productAnalyticsService.logEvent('click-explore-SMART');\r\n this._router.stateService.transitionTo('search');\r\n }\r\n}\r\n","\r\n\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from 'src/app/Compliance/AgGrid';\r\nimport { PaymentBatchService } from '../paymentBatch.service';\r\n\r\nexport interface PaymentBatchListDataSourceParams {\r\n canGetRows: boolean;\r\n gridFilters: Core.PaymentBatchGridFilterSelectionsModel\r\n}\r\n\r\nexport class PaymentBatchCommandCenterAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n protected _dataSourceParamsFn: () => PaymentBatchListDataSourceParams,\r\n private readonly _paymentBatchService: PaymentBatchService) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'batchNo', value: Core.PaymentBatchPropertyEnum.BatchNo },\r\n { name: 'description', value: Core.PaymentBatchPropertyEnum.Description },\r\n { name: 'createDate', value: Core.PaymentBatchPropertyEnum.CreateDate },\r\n { name: 'earliestDueDate', value: Core.PaymentBatchPropertyEnum.EarliestDueDate },\r\n { name: 'fundingDueDate', value: Core.PaymentBatchPropertyEnum.FundingDueDate },\r\n { name: 'completedDate', value: Core.PaymentBatchPropertyEnum.CompletedDate },\r\n { name: 'batchStatus', value: Core.PaymentBatchPropertyEnum.BatchStatus },\r\n { name: 'paymentCount', value: Core.PaymentBatchPropertyEnum.PaymentCount },\r\n { name: 'paymentAmount', value: Core.PaymentBatchPropertyEnum.PaymentAmount },\r\n { name: 'fundedAmount', value: Core.PaymentBatchPropertyEnum.FundedAmount },\r\n { name: 'topLevelCompanyName', value: Core.PaymentBatchPropertyEnum.TopLevelCompanyName },\r\n { name: 'company', value: Core.PaymentBatchPropertyEnum.Company },\r\n { name: 'batchTypeName', value: Core.PaymentBatchPropertyEnum.BatchTypeName },\r\n { name: 'workflowName', value: Core.PaymentBatchPropertyEnum.WorkflowName },\r\n ];\r\n\r\n getSearchParamsWithoutPagination() : Core.PaymentBatchSearchModel{\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n gridFilters: this._dataSourceParams.gridFilters\r\n };\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return !!this._dataSourceParams.canGetRows;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.PaymentBatchSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n gridFilters: this._dataSourceParams.gridFilters\r\n };\r\n\r\n const result = await this._paymentBatchService.getPaymentBatches(searchParams);\r\n if (!result) {\r\n return null;\r\n }\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const PAYMENT_BATCH_COMMAND_CENTER_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'payment-batch-command-center.filter-disabled',\r\n tooltipText: 'Not available until a valid filter is selected'\r\n },\r\n {\r\n helpContentId: 'payment-batch-command-center.company',\r\n tooltipText: 'Filter grid by top level company.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'payment-batch-detail.status',\r\n tooltipText: 'How many payments at a status.',\r\n hasIcon: true\r\n }\r\n];\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { AttachmentModalData } from 'src/app/Attachment/attachment.modal.model';\r\nimport { CommentModalData } from 'src/app/Comments/comments.service';\r\n\r\nexport interface ICellRendererParamsForPaymentBatchListGridAction extends ICellRendererParams {\r\n canEdit: boolean;\r\n viewDetails: (params: ICellRendererParamsForPaymentBatchListGridAction) => void;\r\n delete: (params: ICellRendererParamsForPaymentBatchListGridAction) => void;\r\n canDelete: (params: ICellRendererParamsForPaymentBatchListGridAction) => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n`\r\n})\r\nexport class PaymentBatchListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForPaymentBatchListGridAction;\r\n paymentBatch: Core.PaymentBatchModel;\r\n attachmentModalData: AttachmentModalData;\r\n commentModalData: CommentModalData;\r\n\r\n agInit(params: ICellRendererParamsForPaymentBatchListGridAction): void {\r\n this.params = params;\r\n this.paymentBatch = params.data as Core.PaymentBatchModel;\r\n\r\n if (!this.paymentBatch) {\r\n return;\r\n }\r\n this.attachmentModalData = {\r\n entityType: 'PaymentBatch', //todo: make this a constant generated typescript value\r\n entityName: this.paymentBatch.description,\r\n disableYears: false,\r\n singleYear: false,\r\n entityData: {\r\n typeId: Core.EntityTypes.PaymentBatch,\r\n id: this.paymentBatch.paymentBatchId,\r\n name: this.paymentBatch.description\r\n },\r\n readOnly: !this.params.canEdit\r\n } as AttachmentModalData;\r\n\r\n this.commentModalData = {\r\n entityID: this.paymentBatch.paymentBatchId,\r\n entityTypeID: Core.EntityTypes.PaymentBatch,\r\n entityName: this.paymentBatch.description,\r\n parcelAcctNum: null,\r\n canEdit: this.params.canEdit,\r\n description: null,\r\n parcelID: null,\r\n } as CommentModalData;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this.params.viewDetails(this.params);\r\n }\r\n\r\n onDeleteClicked(): void {\r\n this.params.delete(this.params);\r\n }\r\n}\r\n","import { PaymentBatchCommandCenterComponent } from './paymentBatch.component';\r\nimport { ColDef } from 'ag-grid-community';\r\nimport { WeissmanDateFormat } from '../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { AgGridColumns, AgGridFilterParams } from '../../Compliance/AgGrid';\r\nimport { ICellRendererParamsForPaymentBatchListGridAction, PaymentBatchListGridActionCellRendererComponent } from './agGridActionCellRenderer.component';\r\n\r\n// const getTooltipText = (params: AgGridTooltipCellRendererParams, id: number): string => {\r\n// const model = params.data as Compliance.AssessorCommandCenterModel;\r\n// if (model && model.verifications && model.verifications.length) {\r\n// const found = model.verifications.find(val => val.elementId === id);\r\n// return found && found.verifiedByName;\r\n// }\r\n// };\r\n\r\nexport const PAYMENT_BATCH_LIST_COLUMNS = (classRef: PaymentBatchCommandCenterComponent): ColDef[] => [\r\n // {\r\n // colId: 'grid-column-multiselect',\r\n // headerName: '',\r\n // field: 'assessorId',\r\n // width: AgGridColumns.selectionColumnWidth,\r\n // suppressSizeToFit: true,\r\n // suppressAutoSize: true,\r\n // suppressColumnsToolPanel: true,\r\n // editable: false,\r\n // pinned: 'left',\r\n // lockPinned: true,\r\n // lockVisible: true,\r\n // lockPosition: true,\r\n // suppressMovable: true,\r\n // headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n // headerComponentParams: { tracker: classRef.gridTracker } as AgGridMultiSelectRendererParams,\r\n // cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n // cellRendererParams: { tracker: classRef.gridTracker } as AgGridMultiSelectRendererParams,\r\n // } as ColDef,\r\n {\r\n headerName: 'Batch No',\r\n field: 'batchNo',\r\n width: AgGridColumns.textColumnWidth,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Batch Status',\r\n field: 'batchStatus',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Payment Count',\r\n field: 'paymentCount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFilterWithBlankOptionsParams\r\n },\r\n {\r\n headerName: 'Top Level Company',\r\n field: 'topLevelCompanyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'company',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnLargeWidth\r\n },\r\n {\r\n headerName: 'Batch Type',\r\n field: 'batchTypeName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Workflow',\r\n field: 'workflowName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Earliest Due Date',\r\n field: 'earliestDueDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Core.PaymentBatchModel;\r\n if (!(model && model.earliestDueDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.earliestDueDate, true, 'stored');\r\n }\r\n },\r\n {\r\n headerName: 'Funding Due Date',\r\n field: 'fundingDueDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Core.PaymentBatchModel;\r\n if (!(model && model.fundingDueDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.fundingDueDate, true, 'stored');\r\n }\r\n },\r\n {\r\n headerName: 'Amount',\r\n field: 'paymentAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => classRef.formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Funded Amount',\r\n field: 'fundedAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => classRef.formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Create Date',\r\n field: 'createDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Core.PaymentBatchModel;\r\n if (!(model && model.createDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.createDate, true, 'stored');\r\n }\r\n },\r\n {\r\n headerName: 'Completed Date',\r\n field: 'completedDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Core.PaymentBatchModel;\r\n if (!(model && model.completedDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.completedDate, true, 'stored');\r\n }\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(4),\r\n minWidth: AgGridColumns.getActionColumnWidth(4),\r\n maxWidth: AgGridColumns.getActionColumnWidth(4),\r\n lockPinned: true,\r\n suppressColumnsToolPanel: true,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n sortable: false,\r\n cellRendererFramework: PaymentBatchListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: classRef.onViewDetails.bind(classRef),\r\n delete: classRef.delete.bind(classRef),\r\n canDelete: classRef.canDelete.bind(classRef),\r\n canEdit: classRef.canEdit\r\n } as ICellRendererParamsForPaymentBatchListGridAction\r\n }\r\n];\r\n","\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n Please select an output type for the 'Tax Bill - Transmit' delivery details of the selected company to create a new payment batch\r\n
\r\n
\r\n
\r\n","import { Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { TypeaheadCompany } from '../../Entity/Company/Company.Picker.Component';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { GetEntitiesRequest } from 'src/app/Reporting/Manager/report.manager.model';\r\nimport { ReportManagerSelectEntitiesService } from 'src/app/Reporting/Manager/select.entities.service';\r\nimport { PaymentBatchService } from '../paymentBatch.service';\r\nimport { PaymentBatchCompany } from '../paymentBatch.model';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\n\r\ninterface DDOption {\r\n id: number;\r\n name: string;\r\n}\r\n\r\n@Component({\r\n selector: 'create-payment-batch-modal-component',\r\n templateUrl: './createPaymentBatchModal.component.html'\r\n})\r\nexport class CreatePaymentBatchModalComponent implements OnInit {\r\n constructor(\r\n private upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private selectEntitiesService: ReportManagerSelectEntitiesService,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _toastr: ToastrService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private _paymentBatchService: PaymentBatchService,\r\n ) { }\r\n\r\n @ViewChild('descriptionText') descriptionText: ElementRef;\r\n\r\n result: void;\r\n topCompanyID: number;\r\n companyID: number;\r\n serverAction: boolean = false;\r\n newPaymentBatchForm: UntypedFormGroup;\r\n companyName: string;\r\n companiesLoading: boolean;\r\n dataSource: Observable;\r\n payload: GetEntitiesRequest;\r\n batchTypeOptions: Core.PaymentBatchCreationBatchTypeModel[];\r\n selectedBatchTypeId: Core.PaymentBatchTypeEnum;\r\n paymentBatch: Core.PaymentBatchModel;\r\n onClose: () => void;\r\n\r\n\r\n async ngOnInit() {\r\n this.payload = new GetEntitiesRequest();\r\n this.payload.excludeInactive = true;\r\n this.payload.sourceEntityIsTopLevelCompany = true;\r\n this.payload.sourceEntityTypeID = 1;\r\n this.payload.targetEntityTypeID = 1;\r\n this.payload.sourceEntityIDs = [this.topCompanyID];\r\n\r\n this.newPaymentBatchForm = this._fb.group({\r\n companyName: [{value: '', disabled: true}, Validators.required],\r\n descriptionText: [{value: '', disabled: false}, Validators.required],\r\n batchType: [{value: '', disabled: false}, Validators.required]\r\n });\r\n this.dataSource = Observable.create((observer: any) => {\r\n this.selectEntitiesService.getEntitiesFromParent(this.payload)\r\n .then((data) => {\r\n observer.next(data);\r\n });\r\n });\r\n }\r\n\r\n topCompanySelected(selectedCompany: TypeaheadCompany) {\r\n if(_.isEmpty(selectedCompany)) return;\r\n\r\n if (selectedCompany.companyID) {\r\n this.topCompanyID = selectedCompany.companyID;\r\n this.newPaymentBatchForm.get('companyName').enable();\r\n this.newPaymentBatchForm.patchValue({\r\n companyName: selectedCompany.companyName\r\n });\r\n this.payload.sourceEntityIDs = [this.topCompanyID];\r\n this.companyID = selectedCompany.companyID;\r\n }\r\n else {\r\n this.topCompanyID = null;\r\n this.newPaymentBatchForm.patchValue({\r\n companyName: ''\r\n });\r\n this.newPaymentBatchForm.get('companyName').disable();\r\n }\r\n\r\n this.getAllowedBatchTypes(this.companyID);\r\n }\r\n\r\n typeaheadOnSelect(e: TypeaheadMatch) {\r\n this.companyID = e.item.id;\r\n this.getAllowedBatchTypes(this.companyID);\r\n }\r\n\r\n async getAllowedBatchTypes(companyID: number): Promise{\r\n const allowedBatchTypes = await this._paymentBatchService.getAllowedBatchTypes(companyID);\r\n if (!allowedBatchTypes?.batchTypes.length) {\r\n console.log(`No Batch Types allowed for Company ${companyID}`);\r\n this.batchTypeOptions = [];\r\n this.selectedBatchTypeId = null;\r\n this.newPaymentBatchForm.get('batchType').disable();\r\n return;\r\n } else {\r\n this.newPaymentBatchForm.get('batchType').enable();\r\n }\r\n\r\n this.batchTypeOptions = _.cloneDeep(allowedBatchTypes.batchTypes);\r\n this.selectedBatchTypeId = this.batchTypeOptions.length == 1 ? this.batchTypeOptions[0].id : null;\r\n }\r\n\r\n async save(): Promise {\r\n const isDescriptionNonAscii = !(/^[ -~\\t\\n\\r]+$/.test(this.newPaymentBatchForm.controls.descriptionText.value));\r\n if (isDescriptionNonAscii) {\r\n this._toastr.error('Description contains invalid character(s)');\r\n return;\r\n }\r\n const paymentBatchCreation: Core.PaymentBatchCreateRequestModel = {\r\n companyId: this.companyID,\r\n description: this.newPaymentBatchForm.get('descriptionText').value,\r\n batchType: this.newPaymentBatchForm.get('batchType').value as Core.PaymentBatchTypeEnum\r\n };\r\n\r\n this.serverAction = true;\r\n\r\n try {\r\n\r\n this.paymentBatch = await this._paymentBatchService.savePaymentBatch(paymentBatchCreation);\r\n this._bsModalRef.hide();\r\n this._toastr.success('Payment Batch saved successfully');\r\n } catch (e) {\r\n if (e.error) {\r\n this._toastr.error(e.error.message);\r\n }\r\n } finally {\r\n this.serverAction = false;\r\n if ( this.paymentBatch ) {\r\n this.upgradeNavigationServiceHandler.transitionTo('paymentBatchDetails', {paymentBatchId: this.paymentBatch.paymentBatchId});\r\n }\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n to\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n Apply\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\nimport { BusyIndicatorService } from 'src/app/Busy-Indicator';\r\nimport * as moment from 'moment';\r\nimport { chain, find, reject, some } from 'lodash';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\nexport interface PaymentBatchFilterCriteria {\r\n companyIds: number[]\r\n}\r\n\r\n@Component({\r\n selector: 'payment-batch-filters',\r\n templateUrl: 'paymentBatchFilters.component.html',\r\n styleUrls: ['paymentBatchFilters.component.scss']\r\n})\r\n\r\nexport class PaymentBatchFiltersComponent implements OnInit {\r\n constructor(\r\n private readonly _paymentBatchService: PaymentBatchService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _toastr: ToastrService\r\n ) { }\r\n\r\n @Input() gridLoading: boolean;\r\n @Output() applyFilters: EventEmitter = new EventEmitter();\r\n\r\n filters: Core.PaymentBatchGridFiltersAvailableModel;\r\n selections: Core.PaymentBatchGridFilterSelectionsModel;\r\n availableSubCompanies: Core.NameIdPair[] = [];\r\n workflows: Core.NameIdPair[] = [{id: undefined, name: undefined}];\r\n batchStatuses: Core.NameIdPair[] = [{id: undefined, name: undefined}];\r\n disableAppyButton: boolean = false;\r\n\r\n private _dateTypeMap: { [key in Core.PaymentBatchGridFilterDateTypeEnum]: string } = {\r\n [Core.PaymentBatchGridFilterDateTypeEnum.None]: 'None',\r\n [Core.PaymentBatchGridFilterDateTypeEnum.BatchCreatedDate]: 'Batch Created Date',\r\n [Core.PaymentBatchGridFilterDateTypeEnum.FundingDueDate]: 'Funding Due Date',\r\n [Core.PaymentBatchGridFilterDateTypeEnum.EarliestDueDate]: 'Earliest Due Date',\r\n [Core.PaymentBatchGridFilterDateTypeEnum.BatchCompletedDate]: 'Batch Completed Date'\r\n };\r\n\r\n async ngOnInit() {\r\n this._initSelections();\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Loading'});\r\n try {\r\n const filters = await this._paymentBatchService.getAvailablePaymentBatchGridFilters();\r\n filters.batchTypes.unshift({id: undefined, name: undefined});\r\n filters.workflowTypes.map(x => {\r\n x.workflows.unshift({id: undefined, name: undefined});\r\n return x;\r\n });\r\n filters.batchStatuses.map(x => {\r\n x.statuses.unshift({id: undefined, name: undefined});\r\n return x;\r\n });\r\n filters.dateTypes.map(x => {\r\n x.name = this._dateTypeMap[x.id];\r\n return x;\r\n });\r\n\r\n this.filters = filters;\r\n\r\n if(sessionStorage['pbGoBack']) {\r\n const selectionsString = sessionStorage['pbccFilters'];\r\n if(selectionsString) {\r\n this.selections = JSON.parse(selectionsString);\r\n this.apply();\r\n }\r\n\r\n sessionStorage.removeItem('pbGoBack');\r\n } else if(sessionStorage['fromTlCompany']) {\r\n const selectionsString = sessionStorage['pbccFilters'];\r\n\r\n if(selectionsString) {\r\n const { tlCompanyIds } = JSON.parse(selectionsString) as Core.PaymentBatchGridFilterSelectionsModel;\r\n\r\n if(some(this.filters.tlCompanies, { id: tlCompanyIds[0] })) {\r\n this.selections.tlCompanyIds = tlCompanyIds;\r\n this.apply();\r\n } else {\r\n this._toastr.info(`There are no payment batches for ${sessionStorage['fromTlCompany']}`);\r\n sessionStorage.removeItem('pbccFilters');\r\n }\r\n }\r\n\r\n sessionStorage.removeItem('fromTlCompany');\r\n }\r\n\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n get dateTypeFilters(): Core.NameIdPair[] {\r\n if(!this.filters) {\r\n return [];\r\n }\r\n\r\n return this.selections.showCompleted\r\n ? this.filters.dateTypes\r\n : reject(this.filters.dateTypes, {\r\n id: Core.PaymentBatchGridFilterDateTypeEnum.BatchCompletedDate\r\n });\r\n }\r\n\r\n get isDisabledBasedOnBatchType(): boolean {\r\n return !this.selections.batchTypeId || this.selections.batchTypeId === Core.PaymentBatchTypeEnum.Transmittal;\r\n }\r\n\r\n async getSubsidiaries() {\r\n this.makeItDirty();\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Loading subsidiaries...'});\r\n\r\n try {\r\n const { subCompanies } = await this._paymentBatchService.getAvailablePaymentBatchGridSubsidiaries({\r\n tlCompanyIds: this.selections.tlCompanyIds\r\n });\r\n\r\n this.selections.subCompanyIds = [];\r\n this.availableSubCompanies = subCompanies;\r\n\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n dateTypeChanged() {\r\n if(this.selections.dateFilter.dateType ) {\r\n if(this.selections.dateFilter.fromDate === undefined && this.selections.dateFilter.toDate === undefined) {\r\n this.selections.dateFilter.fromDate = moment().tz('America/Chicago').subtract(2, 'months').startOf('month').toDate();\r\n this.selections.dateFilter.toDate = moment().tz('America/Chicago').add(3, 'months').endOf('month').toDate();\r\n }\r\n } else {\r\n this.selections.dateFilter.fromDate = undefined;\r\n this.selections.dateFilter.toDate = undefined;\r\n }\r\n\r\n this.makeItDirty();\r\n }\r\n\r\n batchTypeSelected() {\r\n this.selections.workflowTypeId = undefined;\r\n this.selections.batchStatusName = undefined;\r\n\r\n const workflowType = find(this.filters?.workflowTypes, {\r\n batchTypeId: this.selections.batchTypeId\r\n });\r\n this.workflows = workflowType?.workflows || [];\r\n this.batchStatuses = this._populateBatchStatuses();\r\n\r\n this.makeItDirty();\r\n }\r\n\r\n workflowSelected() {\r\n this.selections.batchStatusName = undefined;\r\n this.batchStatuses = this._populateBatchStatuses();\r\n\r\n this.makeItDirty();\r\n }\r\n\r\n showCompletedToggle() {\r\n this.makeItDirty();\r\n\r\n if(!this.selections.showCompleted) {\r\n if(this.selections.dateFilter.dateType === Core.PaymentBatchGridFilterDateTypeEnum.BatchCompletedDate) {\r\n this.selections.dateFilter.dateType = Core.PaymentBatchGridFilterDateTypeEnum.None;\r\n }\r\n } else {\r\n this.selections.batchStatusName = undefined;\r\n }\r\n }\r\n\r\n clear() {\r\n this.makeItDirty();\r\n this._initSelections();\r\n }\r\n\r\n makeItDirty() {\r\n this.disableAppyButton = false;\r\n }\r\n\r\n apply() {\r\n sessionStorage['pbccFilters'] = JSON.stringify(this.selections);\r\n this.applyFilters.emit(this.selections);\r\n this.disableAppyButton = true;\r\n }\r\n\r\n private _initSelections() {\r\n this.selections = {\r\n dateFilter: {\r\n dateType: Core.PaymentBatchGridFilterDateTypeEnum.None\r\n },\r\n showCompleted: false,\r\n subCompanyIds: [],\r\n tlCompanyIds: []\r\n };\r\n }\r\n\r\n private _populateBatchStatuses(): Core.NameIdPair[] {\r\n if(this.selections.batchTypeId) {\r\n if(this.selections.workflowTypeId) {\r\n const batchStatusItem = find(this.filters?.batchStatuses, {\r\n batchTypeId: this.selections.batchTypeId,\r\n workflowTypeId: this.selections.workflowTypeId\r\n });\r\n\r\n return batchStatusItem?.statuses ?? [];\r\n } else {\r\n return chain(this.filters?.batchStatuses)\r\n .filter({batchTypeId: this.selections.batchTypeId})\r\n .flatMap('statuses')\r\n .uniqBy('id')\r\n .value();\r\n }\r\n } else {\r\n return [];\r\n }\r\n }\r\n}","
\r\n
\r\n
\r\n

\r\n Payment Batch Command Center\r\n \r\n

\r\n
\r\n
\r\n \r\n Create Payment Batch\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n \r\n \r\n\r\n \r\n \r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { Observable, Subject, lastValueFrom } from 'rxjs';\r\nimport { ColumnApi, GridApi, GridReadyEvent } from 'ag-grid-community';\r\nimport { PaymentBatchCommandCenterAgGridDataSource, PaymentBatchListDataSourceParams } from './agGridDataSource';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { PAYMENT_BATCH_COMMAND_CENTER_HELP } from './paymentBatch.component.help';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { AgGridOptionsBuilder } from '../../Compliance/AgGrid';\r\nimport { CurrencyPipe, DecimalPipe } from '@angular/common';\r\nimport { PAYMENT_BATCH_LIST_COLUMNS } from './paymentBatch.columns';\r\nimport { ICellRendererParamsForPaymentBatchListGridAction } from './agGridActionCellRenderer.component';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { PaymentBatchRepository } from '../../Core-Repositories/paymentBatch.repository';\r\nimport { CreatePaymentBatchModalComponent } from '../Create-Payment-Batch-Modal/createPaymentBatchModal.component';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { PaymentBatchService } from '../paymentBatch.service';\r\nimport { TypeaheadCompany } from 'src/app/Entity/Company/Company.Picker.Component';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from 'src/app/Compliance/AgGrid/ToolPanel/models';\r\n\r\n\r\n@Component({\r\n selector: 'payment-batch-command-center',\r\n templateUrl: './paymentBatch.component.html',\r\n styleUrls: ['./paymentBatch.component.scss']\r\n})\r\nexport class PaymentBatchCommandCenterComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _paymentBatchService: PaymentBatchService,\r\n private readonly _paymentBatchRepository: PaymentBatchRepository,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _modalService: BsModalService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _helpService: HelpService,\r\n private readonly _busyService: BusyIndicatorService,\r\n public readonly _decimalPipe: DecimalPipe,\r\n public readonly _currencyPipe: CurrencyPipe) { }\r\n canEdit: boolean = true;\r\n isInitialized: boolean = false;\r\n gridFilters: Core.PaymentBatchGridFilterSelectionsModel;\r\n readonly gridId: System.Guid = 'D4997CE4-F879-4C32-A893-5EC6856D6365';\r\n columnApi: ColumnApi;\r\n gridOptions = new AgGridOptionsBuilder()\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n gridDataSource: PaymentBatchCommandCenterAgGridDataSource;\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (\r\n columnsToReturn: Compliance.NameValuePair[],\r\n fileFormat: Compliance.ExportFileFormatEnum\r\n ): Promise => {\r\n const searchModel = this.gridDataSource.getSearchParamsWithoutPagination();\r\n\r\n const lrp$ = this._paymentBatchRepository.startPaymentBatchExport({\r\n searchModel,\r\n columnsToReturn,\r\n fileFormat\r\n });\r\n\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n const longRunningProcessTypeId = Compliance.LongRunningProcessTypeEnum.PaymentBatchExportList;\r\n\r\n return { longRunningProcessId, longRunningProcessTypeId };\r\n },\r\n canCancel: true,\r\n getDisabled: () => !this.gridDataSource || this.gridDataSource.totalRows === 0 || this.gridDataSource.isRefreshing\r\n };\r\n overlayNoRowsString: string = 'Please select filter criteria to see results';\r\n\r\n private _gridApi: GridApi;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get refreshHelpContentId(): string {\r\n if (!this.canGetRows) {\r\n return 'payment-batch-command-center.filter-disabled';\r\n }\r\n\r\n return 'app.refresh';\r\n }\r\n\r\n get canGetRows(): boolean {\r\n return !!this.gridFilters;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(PAYMENT_BATCH_COMMAND_CENTER_HELP);\r\n this.isInitialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this._setColumnDefinitions();\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'assessorAbbr', // change\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n refresh(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n launch(){\r\n const modalRef = this._modalService.show(CreatePaymentBatchModalComponent);\r\n }\r\n\r\n onViewDetails(params: ICellRendererParamsForPaymentBatchListGridAction) {\r\n const paymentBatch = params.data as Core.PaymentBatchModel;\r\n this._navigateToPaymentBatchDetails(paymentBatch);\r\n }\r\n\r\n async delete(params: ICellRendererParamsForPaymentBatchListGridAction): Promise {\r\n const paymentBatch = params.data as Core.PaymentBatchModel;\r\n if (!paymentBatch) {\r\n return;\r\n }\r\n\r\n const deleted = await this._deletePaymentBatch(paymentBatch);\r\n if (deleted) {\r\n this._refreshDataSource();\r\n }\r\n }\r\n\r\n canDelete(params: ICellRendererParamsForPaymentBatchListGridAction): boolean {\r\n const paymentBatch = params.data as Core.PaymentBatchModel;\r\n if (!paymentBatch) {\r\n return false;\r\n }\r\n\r\n // return this.canEdit && !paymentBatch.batchStatus;\r\n return paymentBatch.editDeleteAllowed;\r\n }\r\n\r\n formatCurrency(value: number): string {\r\n if(value == null) {\r\n return '';\r\n }\r\n\r\n const formattedVal = this._currencyPipe.transform(Math.abs(value), 'USD', 'symbol-narrow');\r\n return value < 0 ? `(${formattedVal})` : formattedVal;\r\n }\r\n\r\n applyFilters(gridFilters: Core.PaymentBatchGridFilterSelectionsModel) {\r\n this.gridFilters = gridFilters;\r\n this._refreshDataSource();\r\n this.overlayNoRowsString = undefined;\r\n }\r\n\r\n private async _setColumnDefinitions(): Promise {\r\n const columns = PAYMENT_BATCH_LIST_COLUMNS(this);\r\n this._gridApi.setColumnDefs(columns);\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this.gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this.gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this.gridDataSource) {\r\n return;\r\n }\r\n\r\n const dataSourceParams = (): PaymentBatchListDataSourceParams => {\r\n return {\r\n gridFilters: this.gridFilters,\r\n canGetRows: this.canGetRows\r\n };\r\n };\r\n\r\n this.gridDataSource = new PaymentBatchCommandCenterAgGridDataSource(\r\n this._gridApi,\r\n dataSourceParams,\r\n this._paymentBatchService);\r\n\r\n this._gridApi.setDatasource(this.gridDataSource);\r\n\r\n return true;\r\n }\r\n\r\n private _navigateToPaymentBatchDetails(paymentBatch: Core.PaymentBatchModel): void {\r\n if (!paymentBatch) {\r\n return;\r\n }\r\n // this._productAnalyticsService.logEvent('access-payment-batch', {\r\n // returnAccessPath: 'view return payment'\r\n // });\r\n this._routerService.go('paymentBatchDetails',\r\n {\r\n 'paymentBatchId': paymentBatch.paymentBatchId\r\n });\r\n }\r\n\r\n private async _deletePaymentBatch(paymentBatch: Core.PaymentBatchModel): Promise {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you wish to delete the payment batch?', 'Confirm Delete');\r\n }\r\n catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const busyRef = this._busyService.show({ message: 'Deleting' });\r\n\r\n try {\r\n await lastValueFrom(this._paymentBatchRepository.deletePaymentBatch(paymentBatch.paymentBatchId));\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve(true);\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n No options available\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { BusyIndicatorMessageManager } from 'src/app/Busy-Indicator';\r\nimport { TaskProcessingActions } from 'src/app/Compliance/Return/Models/enums';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\n\r\nexport interface PaymentBatchTaskExceptionModalParams {\r\n workflowStatus: Core.PaymentBatchDetailsWorkflowStatusModel;\r\n paymentBatchId: number;\r\n}\r\n\r\ninterface PBTaskExceptionOption {\r\n taskId: number;\r\n action: TaskProcessingActions;\r\n title: string;\r\n taskName: string;\r\n assignedUserId: System.Guid;\r\n assignedTeamId: number;\r\n // includeCompanyRepresentative: boolean;\r\n isAuthorized?: boolean;\r\n message: string;\r\n}\r\n\r\n@Component({\r\n selector: 'payment-batch-task-exception-modal',\r\n templateUrl: 'paymentBatchTaskExceptionModal.component.html'\r\n})\r\n\r\n\r\nexport class PaymentBatchTaskExceptionModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _paymentBatchService: PaymentBatchService) { }\r\n\r\n params: PaymentBatchTaskExceptionModalParams;\r\n result: Core.PaymentBatchTaskUpdateResultModel;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n comment: string;\r\n options: PBTaskExceptionOption[] = [];\r\n selectedOption: PBTaskExceptionOption;\r\n isReassignedAuthorized: boolean = true;\r\n reassignOptionName: string;\r\n isRescindAuthorized: boolean = true;\r\n TaskProcessingActions = TaskProcessingActions;\r\n\r\n ngOnInit() {\r\n this.options = [];\r\n if(this.params.workflowStatus.canReassignTask && this.params.workflowStatus.taskStatusName)\r\n {\r\n this.options.push({\r\n action: TaskProcessingActions.ReassignTask,\r\n taskId: this.params.workflowStatus.taskID,\r\n title: `Reassign ${this.params.workflowStatus.taskStatusName}`,\r\n message: 'Reassigning',\r\n taskName: this.params.workflowStatus.taskStatusName,\r\n assignedTeamId: null,\r\n assignedUserId: '',\r\n isAuthorized: !!this.params.workflowStatus.taskStatusName\r\n });\r\n }\r\n\r\n if(this.params.workflowStatus.canRescindTask && this.params.workflowStatus.taskRescindName) {\r\n this.options.push({\r\n action: TaskProcessingActions.RescindTask,\r\n taskId: this.params.workflowStatus.taskID,\r\n title: `Rescind ${this.params.workflowStatus.taskRescindName}`,\r\n message: 'Rescinding',\r\n taskName: 'placeholder',\r\n assignedTeamId: null,\r\n assignedUserId: '',\r\n isAuthorized: true\r\n });\r\n }\r\n }\r\n\r\n selectedOptionChanged(e) {\r\n console.log(e);\r\n }\r\n\r\n userChanged(newUser: Core.UserTeamModel, option: PBTaskExceptionOption) {\r\n option.assignedTeamId = newUser.teamID;\r\n option.assignedUserId = newUser.userID;\r\n }\r\n\r\n async save() {\r\n const busyMsg = 'saving';\r\n this.busyIndicatorMessageManager.add(this.selectedOption.message, busyMsg);\r\n\r\n try {\r\n this.result = await this._actOnTask();\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private async _actOnTask(): Promise {\r\n const updateModel = {\r\n taskId: this.params.workflowStatus.taskID,\r\n comment: this.comment\r\n };\r\n\r\n switch (this.selectedOption.action) {\r\n case TaskProcessingActions.RescindTask:\r\n return this._paymentBatchService.rescindTask(this.params.paymentBatchId, updateModel);\r\n case TaskProcessingActions.ReassignTask:\r\n return this._paymentBatchService.reassignTask(this.params.paymentBatchId, {\r\n ...updateModel,\r\n assignedTeamId: this.selectedOption.assignedTeamId,\r\n assignedUserId: this.selectedOption.assignedUserId\r\n });\r\n }\r\n }\r\n}","
\r\n \r\n
\r\n
\r\n

\r\n Payment Batch Details\r\n

\r\n
\r\n \r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n
\r\n","import { Component, OnInit, ViewChild } from '@angular/core';\r\nimport { BreadCrumb } from '../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { PAYMENT_BATCH_COMMAND_CENTER_HELP } from '../Command-Center/paymentBatch.component.help';\r\nimport { PaymentBatchService } from '../paymentBatch.service';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { AttachmentModalData } from '../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { PaymentBatchPaymentsGridComponent } from './Payments-Grid/paymentBatchPaymentsGrid.component';\r\nimport { EntityTypeIds } from '../../constants.new';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { PaymentBatchTaskExceptionModalComponent } from './Task-Exception-Modal/paymentBatchTaskExceptionModal.component';\r\nimport { TabsetComponent } from 'ngx-bootstrap/tabs';\r\nimport * as _ from 'lodash';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { uniqBy } from 'lodash';\r\nimport { PaymentBatchPackagesComponent } from './Packages-Table/paymentBatchPackages.component';\r\n\r\nenum TabIdxs {\r\n Payments = 0,\r\n Packages = 1,\r\n Output = 2\r\n}\r\n\r\nexport interface RefreshComponents {\r\n payments: boolean;\r\n packages: boolean;\r\n status: boolean;\r\n}\r\n\r\n\r\n@Component({\r\n selector: 'payment-batch-details',\r\n templateUrl: './paymentBatchDetails.component.html',\r\n styleUrls: ['./paymentBatchDetails.component.scss']\r\n // encapsulation: ViewEncapsulation.None\r\n})\r\nexport class PaymentBatchDetailsComponent implements OnInit {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _helpService: HelpService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _taskService: TaskService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _featureFlagService: FeatureFlagsService,\r\n private readonly _paymentBatchService: PaymentBatchService){}\r\n\r\n\r\n @ViewChild('paymentBatchDetailsGrid') paymentBatchDetailsGrid: PaymentBatchPaymentsGridComponent;\r\n @ViewChild('paymentBatchPackages') paymentBatchPackages: PaymentBatchPackagesComponent;\r\n @ViewChild('paymentDetailsTabs', { static: false }) paymentDetailsTabs?: TabsetComponent;\r\n\r\n isInitialized: boolean = true;\r\n pageTitle: string = 'Batch';\r\n breadcrumbs: BreadCrumb[] = [];\r\n attachmentModalData: AttachmentModalData;\r\n commentModalData: CommentModalData;\r\n hasComments: boolean = false;\r\n hasAttachments: boolean = false;\r\n paymentBatch: Core.PaymentBatchModel;\r\n editingFundedAmount: boolean = false;\r\n savingFundedAmount: boolean = false;\r\n workflowStatus: Core.PaymentBatchDetailsWorkflowStatusModel;\r\n tabIndex: number;\r\n rowCount: number;\r\n settingsEditing: boolean = false;\r\n\r\n private _originalFundedAmount: number;\r\n private _errors: string[] = [];\r\n\r\n async ngOnInit(): Promise {\r\n this.breadcrumbs = [\r\n {\r\n name: 'Payment Batch Command Center',\r\n target: 'paymentBatchCommandCenter',\r\n options: { }\r\n }\r\n ];\r\n if (this._upgradeNavigationServiceHandler.getQuerystringParam('tabIndex'))\r\n this.tabIndex = JSON.parse(this._upgradeNavigationServiceHandler.getQuerystringParam('tabIndex'));\r\n\r\n this._helpService.setContent(PAYMENT_BATCH_COMMAND_CENTER_HELP);\r\n await this._loadPaymentBatch();\r\n await this._loadPaymentBatchDetailsWorkflowStatus();\r\n\r\n if (this.tabIndex)\r\n this.paymentDetailsTabs.tabs[this.tabIndex].active = true;\r\n }\r\n\r\n get isTransmittal(): boolean {\r\n return this.paymentBatch?.batchType === Core.PaymentBatchTypeEnum.Transmittal;\r\n }\r\n\r\n get isBillPay(): boolean {\r\n return this.paymentBatch?.batchType === Core.PaymentBatchTypeEnum.BillPay;\r\n }\r\n\r\n launchTaskModal(event: any): void {\r\n event.stopPropagation();\r\n this._taskService.launchTaskModal(this.paymentBatch.paymentBatchId, EntityTypeIds.PAYMENT_BATCH, true);\r\n }\r\n\r\n goBack(): void {\r\n sessionStorage['pbGoBack'] = true;\r\n this._routerService.go('paymentBatchCommandCenter', null);\r\n }\r\n\r\n refreshPage({payments, packages, status}: RefreshComponents, bypassTabSwitch?: boolean): void {\r\n\r\n // Tab switching\r\n if (packages) {\r\n if(this.paymentDetailsTabs.tabs[TabIdxs.Packages].active) {\r\n this.paymentBatchPackages.loadData();\r\n } else {\r\n !bypassTabSwitch && (this.paymentDetailsTabs.tabs[TabIdxs.Packages].active = true);\r\n }\r\n } else if (payments) {\r\n !bypassTabSwitch && (this.paymentDetailsTabs.tabs[TabIdxs.Payments].active = true);\r\n }\r\n\r\n // Loading data\r\n this._loadPaymentBatch();\r\n\r\n if (payments) {\r\n this.paymentBatchDetailsGrid.refresh();\r\n }\r\n if (status) {\r\n this._loadPaymentBatchDetailsWorkflowStatus();\r\n }\r\n }\r\n\r\n async advanceTask() {\r\n try {\r\n const message = `Are you sure you wish to ${this.workflowStatus?.taskAdvanceName}`;\r\n await this._messageModalService.confirm(message, 'Confirm Completion' );\r\n }\r\n catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n if (this.workflowStatus.advanceCreatesPackages && this.paymentBatch.hasZeroAmountPayments) {\r\n try {\r\n const operation: string = this.isTransmittal ? 'Transmittal' : 'Feed generation';\r\n const message = `The batch has 1 or more payments with a $0 amount which will be excluded from the ${operation}. Are you sure wish to proceed?`;\r\n await this._messageModalService.confirm(message, 'Confirm Proceeding' );\r\n }\r\n catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Advancing task...' });\r\n try {\r\n const updateModel = { taskId: this.workflowStatus.taskID };\r\n const {\r\n succeeded,\r\n refreshStatus: status,\r\n refreshPayments: payments,\r\n refreshPackages: packages,\r\n errorMessage,\r\n paymentErrors,\r\n packageIds\r\n } = await this._paymentBatchService.advanceTask(this.paymentBatch.paymentBatchId, updateModel);\r\n\r\n if (succeeded) {\r\n this.refreshPage({status, payments, packages});\r\n\r\n // If this is a Transmittal advance, we know that draft Payment Packages have been\r\n // created, so we want to navigate to the Bill Payment Packages page to finalize.\r\n if (packageIds && packageIds.length) {\r\n const newKey = (new Date()).getTime();\r\n sessionStorage[`PaymentPackageDrafts${ newKey}`] = JSON.stringify(packageIds);\r\n const params = { draftID: newKey, paymentBatchId: this.paymentBatch.paymentBatchId, taskId: this.workflowStatus.taskID} as any;\r\n if(this.workflowStatus.taskAdvanceName === 'Prepare Preliminary AP Feed') {\r\n params.isPrelimApFeed = true;\r\n }\r\n this._routerService.go('paymentPackagesDraft', params);\r\n }\r\n } else {\r\n // Handle PaymentErrors\r\n if (errorMessage) {\r\n this._toastr.error(errorMessage);\r\n return;\r\n }\r\n\r\n if(paymentErrors) {\r\n this.paymentBatchDetailsGrid.addPaymentErrors(paymentErrors);\r\n const uniqueErrorPayments = uniqBy(paymentErrors, 'entityID');\r\n this._toastr.error('Hover over payment error icon for more details.', `${uniqueErrorPayments.length} payments have errors.`);\r\n }\r\n\r\n\r\n }\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async launchExceptionModal() {\r\n const params = {\r\n workflowStatus: this.workflowStatus,\r\n paymentBatchId: this.paymentBatch.paymentBatchId\r\n };\r\n\r\n const result = await this._modalService.showAsync(PaymentBatchTaskExceptionModalComponent, params, 'modal-md');\r\n\r\n if (!result) return;\r\n\r\n if (result.succeeded) {\r\n const {refreshStatus: status, refreshPayments: payments, refreshPackages: packages} = result;\r\n this.refreshPage({status, payments, packages});\r\n } else {\r\n // TODO handle result.PaymentErrors\r\n this._toastr.error(result.errorMessage);\r\n }\r\n }\r\n\r\n async recallBatch() {\r\n try {\r\n const message = `Are you sure you want to recall the batch #${this.paymentBatch.batchNo}`;\r\n await this._messageModalService.confirm(message, 'Confirm Recall');\r\n }\r\n catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Recalling' });\r\n\r\n try {\r\n const updateModel = {taskId: this.workflowStatus.taskID};\r\n const {\r\n refreshStatus: status,\r\n refreshPayments: payments,\r\n refreshPackages: packages\r\n } = await this._paymentBatchService.rescindTask(this.paymentBatch.paymentBatchId, updateModel);\r\n\r\n this.refreshPage({status, payments, packages});\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve(true);\r\n }\r\n\r\n private async _loadPaymentBatch(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n const paymentBatchId = +this._upgradeNavigationServiceHandler.getQuerystringParam('paymentBatchId');\r\n this.paymentBatch = await this._paymentBatchService.getPaymentBatchDetailById(paymentBatchId);\r\n this.attachmentModalData = {\r\n entityType: 'Payment',\r\n entityName: this.paymentBatch.description,\r\n disableYears: false,\r\n singleYear: false,\r\n entityData: {\r\n typeId: Core.EntityTypes.PaymentBatch,\r\n id: this.paymentBatch.paymentBatchId,\r\n name: this.paymentBatch.description\r\n },\r\n readOnly: false,\r\n } as AttachmentModalData;\r\n\r\n this.commentModalData = {\r\n entityID: this.paymentBatch.paymentBatchId,\r\n entityTypeID: Core.EntityTypes.PaymentBatch,\r\n entityName: this.paymentBatch.description,\r\n canEdit: true,\r\n description: null\r\n } as CommentModalData;\r\n this.hasAttachments = this.paymentBatch.hasAttachments;\r\n this.hasComments = this.paymentBatch.hasComments;\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private async _loadPaymentBatchDetailsWorkflowStatus(): Promise{\r\n this.workflowStatus = await this._paymentBatchService.getPaymentBatchDetailsWorkflowStatus(this.paymentBatch.paymentBatchId);\r\n }\r\n}\r\n","\r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n {{report.displayName}} - \r\n \r\n \r\n The maximum length for the name is 50 characters\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { SearchPageType, UserSaveService } from '../../Navigation/User-Save/userSave.service';\r\nimport { ReportManagerService } from '../Manager/report.manager.service';\r\nimport { ReportDetail, ReportCategory } from '../Manager/report.manager.model';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { ReportManagerModalInputParameters } from '../Manager/reportManagerModal.component';\r\nimport { FormRepository } from '../../Compliance/Repositories';\r\nimport { ReturnRepository } from '../../Compliance/Repositories';\r\nimport { TimerService } from '../../UI-Lib/Utilities';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nexport interface SaveReportModalParameters {\r\n report: ReportDetail;\r\n modalParameters: ReportManagerModalInputParameters;\r\n}\r\n\r\nexport interface SaveReportModalResult {\r\n report: ReportDetail;\r\n isSystemReport: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'save-report-modal',\r\n templateUrl: './save-report.component.html'\r\n})\r\nexport class SaveReportModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _reportManagerService: ReportManagerService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _formRepository: FormRepository,\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _userSaveService: UserSaveService,\r\n private readonly _timer: TimerService,\r\n private readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: SaveReportModalParameters;\r\n result: SaveReportModalResult;\r\n\r\n model: ReportDetail;\r\n modalParameters?: ReportManagerModalInputParameters;\r\n report: ReportDetail;\r\n isSystemReport: boolean;\r\n loading: boolean;\r\n userReportCategories: Core.SavedReportCategoryManagementDTO[];\r\n systemReportCategories: Core.SavedReportCategoryManagementDTO[];\r\n defaultUserCategory: Core.SavedReportCategoryManagementDTO;\r\n defaultSystemCategory: Core.SavedReportCategoryManagementDTO;\r\n isComplianceReport: boolean = false;\r\n newCategoryName: string;\r\n hasEditPermission: boolean;\r\n\r\n async ngOnInit(): Promise {\r\n this.model = this.params.report;\r\n this.modalParameters = this.params.modalParameters;\r\n this.hasEditPermission = this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT);\r\n\r\n // Whenever the Save As dialog is shown, make a copy of the model;\r\n // that way changes to things like the report name are not live updated\r\n // in the parent page, and changes are discarded on cancel\r\n this.report = Object.assign({}, this.model);\r\n this.isComplianceReport = this._isComplianceReport();\r\n // Default the name to null (could default to existing value, but that default doesn't necessarily make sense)\r\n this.report.variantName = null;\r\n this.isSystemReport = false;\r\n this.loading = true;\r\n\r\n try {\r\n const allCategories = await this._reportManagerService.getReportCategories();\r\n const categories = _.filter(allCategories, (category: ReportCategory): boolean => {\r\n return ![Core.SavedSearchCategoryEnum.ComplianceReportSetup,\r\n Core.SavedSearchCategoryEnum.ComplianceReturnReport,\r\n Core.SavedSearchCategoryEnum.CompliancePackageReport,\r\n Core.SavedSearchCategoryEnum.ComplianceCustomReport].includes(category.categoryId);\r\n });\r\n\r\n this.systemReportCategories = _.filter(categories, (category: Core.SavedReportCategoryManagementDTO): boolean => {\r\n return category.categoryType === 0;\r\n });\r\n this.userReportCategories = _.filter(categories, (category: Core.SavedReportCategoryManagementDTO): boolean => {\r\n return category.categoryType === 1;\r\n });\r\n\r\n this.defaultUserCategory = _.find(this.userReportCategories, { categoryId: null }) as Core.SavedReportCategoryManagementDTO;\r\n if (!this.defaultUserCategory) {\r\n // We didn't find the \"uncategorized\" category; just make one up\r\n this.defaultUserCategory = {\r\n categoryId: null,\r\n categoryName: 'No Category',\r\n categoryType: 1,\r\n reportList: null\r\n };\r\n this.userReportCategories.unshift(this.defaultUserCategory);\r\n }\r\n this.defaultSystemCategory = _.head(this.systemReportCategories) as Core.SavedReportCategoryManagementDTO;\r\n\r\n // If the user is saving a system report, we initially assume what they really want\r\n // is to save as a user report; make the user select system if that's what they want\r\n if (_.some(this.systemReportCategories, { categoryId: this.report.categoryID })) {\r\n this.report.categoryID = null;\r\n this.report.categoryName = this.defaultUserCategory.categoryName;\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n reportTypeClicked(): void {\r\n // Use setTimeout so that the model has a chance to propogate before we respond to the click event\r\n this._timer.setTimeout(() => {\r\n const defaultCategory: Core.SavedReportCategoryManagementDTO = this.isSystemReport ? this.defaultSystemCategory : this.defaultUserCategory;\r\n this.report.categoryID = defaultCategory.categoryId;\r\n this.report.categoryName = defaultCategory.categoryName;\r\n }, 1);\r\n }\r\n\r\n async save(): Promise {\r\n if (this.report.categoryID == -1) {\r\n this.loading = true;\r\n\r\n try {\r\n const category = await this._reportManagerService.createCategory(this.newCategoryName, this.isSystemReport);\r\n this.report.categoryID = category.categoryId;\r\n this.report.categoryName = category.categoryName;\r\n this.createReport();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n else {\r\n this.createReport();\r\n }\r\n }\r\n\r\n private async createReport(): Promise {\r\n this._userSaveService.setDirty(SearchPageType.Report);\r\n if (!this._isComplianceReport()) {\r\n await this._saveReport();\r\n } else if (this.modalParameters && this.modalParameters.filingBatchId) {\r\n this.loading = true;\r\n\r\n try {\r\n const reportCopy = {...this.report};\r\n reportCopy.reportID = 0;\r\n const newReport = await lastValueFrom(this._returnRepository.saveCustomReport(this.modalParameters.filingBatchId, this.report.reportID, reportCopy));\r\n this._saveCompleted(newReport as any);\r\n } finally {\r\n this.loading = false;\r\n }\r\n } else if (this.modalParameters && this.modalParameters.formRevisionId) {\r\n this.loading = true;\r\n\r\n try {\r\n const reportCopy = {...this.report};\r\n reportCopy.reportID = 0;\r\n const newReport = await lastValueFrom(this._formRepository.saveCustomReport(this.modalParameters.formRevisionId, this.report.reportID, reportCopy));\r\n this._saveCompleted(newReport as any);\r\n } finally {\r\n this.loading = false;\r\n }\r\n } else {\r\n // regular endpoint works for non-formrev / filing batch compliance reports, but must be system not custom\r\n return this._saveReport(true);\r\n }\r\n }\r\n\r\n private async _saveReport(forceSystem: boolean = false): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n const newReport = await this._reportManagerService.createReport(this.report, forceSystem ? true : this.isSystemReport);\r\n this._saveCompleted(newReport);\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n private _saveCompleted(newReport: any): void{\r\n this.report.reportID = newReport.reportID;\r\n // Copy the properties back to the model the parent passed us so things\r\n // like the name are live-updated\r\n Object.assign(this.model, this.report);\r\n this.result = newReport;\r\n this._bsModalRef.hide();\r\n }\r\n private _isComplianceReport(): boolean {\r\n return [Core.SavedSearchCategoryEnum.ComplianceReportSetup,\r\n Core.SavedSearchCategoryEnum.ComplianceReturnReport,\r\n Core.SavedSearchCategoryEnum.CompliancePackageReport,\r\n Core.SavedSearchCategoryEnum.ComplianceCustomReport].includes(this.report.categoryID);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BaseRepository } from '../Common/Data/base.repository';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { GetEntitiesRequest, SummaryReportCriteria, ExtraReportDetailCriteria, BudgetVarianceFormatOutputCriteria } from './Manager/report.manager.model';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\nexport class PsrRequest extends GetEntitiesRequest {\r\n reportTitle: string;\r\n startYearValue: number;\r\n endYearValue: number;\r\n propertyTypes: number[];\r\n includeEstAssessment: boolean;\r\n includeOnlySitesUnderAppeal: boolean;\r\n outputFormat: number;\r\n psrReportType: number;\r\n includeDisclaimer: boolean;\r\n}\r\n\r\nexport class MaarRequest extends GetEntitiesRequest {\r\n reportTitle: string;\r\n YearValue: number;\r\n propertyTypes: number[];\r\n includeAllCompanies: boolean;\r\n}\r\n\r\nexport class BudgetRequest extends GetEntitiesRequest {\r\n reportTitle: string;\r\n budgetYear: number;\r\n budgetYearString: string; // calculated for jsreport\r\n //includePPPropertyType: boolean;\r\n propertyTypes: number[];\r\n minimumDetailYearsShown: number;\r\n outputFormat: number;\r\n currCompanyBudgetID: number;\r\n priorCompanyBudgetID: number;\r\n budgetBasis: Core.CompanyBudgetBasisEnum;\r\n detailReportOptions: ExtraReportDetailCriteria;\r\n summaryReportOptions: SummaryReportCriteria;\r\n includeDisclaimer: boolean;\r\n}\r\n\r\nexport class BudgetVarianceReportingRequest extends GetEntitiesRequest {\r\n constructor()\r\n {\r\n super();\r\n this.formatOutput = new BudgetVarianceFormatOutputCriteria();\r\n this.includeDisclaimer = true;\r\n }\r\n\r\n reportTitle: string;\r\n formatOutput: BudgetVarianceFormatOutputCriteria;\r\n includeDisclaimer: boolean;\r\n}\r\n\r\nexport class ProgressStatusRequest extends GetEntitiesRequest {\r\n reportTitle: string;\r\n startYearValue: number;\r\n endYearValue: number;\r\n siteStatus: number;\r\n propertyTypes: number[];\r\n}\r\n\r\nexport class SiteRequest extends GetEntitiesRequest {\r\n reportTitle: string;\r\n orderBy: number[];\r\n startYearValue: number;\r\n endYearValue: number;\r\n numberOfYearsToInclude: number;\r\n propertyTypes: number[];\r\n detailReportOptions: ExtraReportDetailCriteria;\r\n includeDisclaimer: boolean;\r\n}\r\n\r\nexport class UserActivityRequest extends GetEntitiesRequest {\r\n reportTitle: string;\r\n loginDateBegin: Date;\r\n loginDateEnd: Date;\r\n onlyActiveUsers: boolean;\r\n includeUsersWithoutLogin: boolean;\r\n outputFormat: number;\r\n includeInternalUsers: boolean;\r\n\r\n showUserName: boolean;\r\n showContactTitle: boolean;\r\n showLoginDates: boolean;\r\n showLoginDayCount: boolean;\r\n showLastPasswordChange: boolean;\r\n\r\n userAccessReportLimitByLoginDate: Core.UserAccessReportLimitByLoginDateEnum;\r\n}\r\n\r\nexport class UserAccessRequest extends GetEntitiesRequest {\r\n reportTitle: string;\r\n loginDateBegin: Date;\r\n loginDateEnd: Date;\r\n onlyActiveUsers: boolean;\r\n includeUsersWithoutLogin: boolean;\r\n outputFormat: number;\r\n includeInternalUsers: boolean;\r\n\r\n showUserName: boolean;\r\n showContactTitle: boolean;\r\n showLoginDates: boolean;\r\n showLoginDayCount: boolean;\r\n showLastPasswordChange: boolean;\r\n\r\n selectedUserId: System.Guid;\r\n userAccessReportStartWith: Core.UserAccessReportStartWithEnum;\r\n userAccessReportLimitByLoginDate: Core.UserAccessReportLimitByLoginDateEnum;\r\n}\r\n\r\nexport class UserCSRRequest extends GetEntitiesRequest {\r\n reportTitle: string;\r\n selectedUserId: System.Guid;\r\n}\r\n\r\nexport class AppealListReportRequest extends GetEntitiesRequest {\r\n taskIds: number[];\r\n}\r\n\r\nexport class SupportInstanceEscalationActivityReportRequest extends GetEntitiesRequest {\r\n instanceIds: number[];\r\n contactIds: number[];\r\n escalationDateBegin: Date;\r\n escalationDateEnd: Date;\r\n outputFormat: number;\r\n anyEscalationDates: boolean;\r\n escalationGroupBy: Core.SupportInstanceEscalationActivityReportGroupByEnum;\r\n}\r\n\r\n\r\n@Injectable()\r\nexport class ReportingService extends BaseRepository {\r\n constructor(httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n private SERVICE_URL: string = '/api/Reporting/';\r\n\r\n async runPsrReport(psrRequest: PsrRequest, shouldZip: boolean): Promise {\r\n return lastValueFrom(this.httpPost(`${this.SERVICE_URL }psr${ shouldZip ? '/zip' : ''}`, psrRequest)) as Promise;\r\n }\r\n\r\n async runBudgetReport(budgetRequest: BudgetRequest): Promise {\r\n return lastValueFrom(this.httpPost(`${this.SERVICE_URL }budget`, budgetRequest)) as Promise;\r\n }\r\n\r\n async runBudgetVarianceReport(budgetVarianceRequest: BudgetVarianceReportingRequest): Promise {\r\n return lastValueFrom(this.httpPost(`${this.SERVICE_URL }budgetvariance`, budgetVarianceRequest)) as Promise;\r\n }\r\n\r\n\tasync runMaarReport(maarRequest: MaarRequest): Promise {\r\n return lastValueFrom(this.httpPost(`${this.SERVICE_URL }maar`, maarRequest)) as Promise;\r\n }\r\n\r\n\tasync runProgressStatusExtract(pseRequest: ProgressStatusRequest): Promise {\r\n return lastValueFrom(this.httpPost(`${this.SERVICE_URL }pse`, pseRequest)) as Promise;\r\n }\r\n\r\n async runSiteReport(siteRequest: SiteRequest): Promise {\r\n return lastValueFrom(this.httpPost(`${this.SERVICE_URL }site`, siteRequest)) as Promise;\r\n }\r\n\r\n async runUserActivityReport(userActivityRequest: UserActivityRequest): Promise {\r\n return lastValueFrom(this.httpPost(`${this.SERVICE_URL }usr`, userActivityRequest)) as Promise;\r\n }\r\n\r\n async runUserAccessReport(userAccessRequest: UserAccessRequest): Promise {\r\n return lastValueFrom(this.httpPost(`${this.SERVICE_URL }usrAccess`, userAccessRequest)) as Promise;\r\n }\r\n\r\n async runUserCSRExtract(userCSRRequest: UserCSRRequest): Promise {\r\n return lastValueFrom(this.httpPost(`${this.SERVICE_URL }usrCsr`, userCSRRequest)) as Promise;\r\n }\r\n\r\n async runAppealListReport(request: AppealListReportRequest): Promise {\r\n return lastValueFrom(this.httpPost(`${this.SERVICE_URL }appealList`, request)) as Promise;\r\n }\r\n\r\n async runSupportInstanceEscalationActivityReport(request: SupportInstanceEscalationActivityReportRequest): Promise {\r\n return await lastValueFrom(this.httpPost(`${this.SERVICE_URL }siear`, request));\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const REPORT_MANAGER_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'report-manager.groupings',\r\n tooltipText: 'Group the data by it\\'s properties',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'report-manager.save-as',\r\n tooltipText: 'Save As'\r\n },\r\n {\r\n helpContentId: 'report-manager.all-instances-selected',\r\n tooltipText: 'Please select a single instance to save search'\r\n }\r\n];\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport { Constants } from '../../../constants.new';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'further-limit-panel-psr',\r\n template: `\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n `\r\n})\r\nexport class FurtherLimitPanelPsrComponent implements OnInit {\r\n constructor(private constants: Constants) { }\r\n\r\n @Input() report: ReportDetail;\r\n @Input() availableYears: number[];\r\n @Input() hasRyanPrivatePermission: boolean;\r\n propertyTypes: any[];\r\n\r\n ngOnInit() {\r\n if (!this.report.criteria.taxYearBegin) {\r\n const newYearValue = new Date().getFullYear() - 3;\r\n this.report.criteria.taxYearBegin = newYearValue;\r\n }\r\n\r\n this.propertyTypes = _.map(this.constants.PropertyTypeNames, (name: string, id: number) => {\r\n return {\r\n name: name,\r\n propertyTypeId: Number(id)\r\n };\r\n });\r\n\r\n this.report.criteria.propertyTypeIDs = this.report.criteria.propertyTypeIDs || [1, 2, 3, 4];\r\n\r\n this.report.criteria.includeEstimatedAssessments = this.report.criteria.includeEstimatedAssessments || false;\r\n this.report.criteria.includeOnlySitesUnderAppeal = this.report.criteria.includeOnlySitesUnderAppeal || false;\r\n\r\n if ([null, undefined].indexOf(this.report.criteria.includeDisclaimer) !== -1) {\r\n this.report.criteria.includeDisclaimer = true;\r\n }\r\n }\r\n\r\n yearChangedValidation(): void {\r\n if (this.report.criteria.taxYearBegin > this.report.criteria.taxYearEnd) {\r\n this.report.criteria.taxYearEnd = null;\r\n }\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport { Constants } from '../../../constants.new';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { ReportManagerService } from '../report.manager.service';\r\nimport * as moment from 'moment';\r\n\r\n@Component({\r\n selector: 'further-limit-panel-budget',\r\n template: `\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n `\r\n})\r\nexport class FurtherLimitPanelBudgetComponent implements OnInit {\r\n constructor(private constants: Constants, private companyService: CompanyService, private reportManagerService: ReportManagerService) { }\r\n\r\n @Input() report: ReportDetail;\r\n @Input() availableYears: number[];\r\n @Input() hasRyanPrivatePermission: boolean;\r\n numYears: number[];\r\n propertyTypes: any[];\r\n\r\n fiscalYearStart: string = '1/1';\r\n fiscalYearEnd: string = '12/31';\r\n\r\n yearsToDisplay: any[];\r\n\r\n ngOnInit() {\r\n let yearsToDisplay = [];\r\n\r\n let count = 0;\r\n this.availableYears.forEach(function(year) {\r\n yearsToDisplay[count] = new Array();\r\n yearsToDisplay[count][0] = year;\r\n yearsToDisplay[count][1] = year;\r\n count++;\r\n });\r\n\r\n this.reportManagerService.topLevelCompanies$.subscribe(async topLevelCompaniesObj => {\r\n yearsToDisplay = [];\r\n if(topLevelCompaniesObj.topLevelCompanyIds.length == 1) {\r\n const fiscalYearStart = await this.companyService.getCompanyFiscalYearStart(topLevelCompaniesObj.topLevelCompanyIds[0]);\r\n\r\n if(fiscalYearStart) {\r\n this.fiscalYearStart = fiscalYearStart;\r\n const fiscalYearStartDate = new Date(`${fiscalYearStart}/${new Date().getFullYear()}`);\r\n this.fiscalYearEnd = `${moment(fiscalYearStartDate).subtract(1, 'days').month() + 1}/${moment(fiscalYearStartDate).subtract(1, 'days').date()}`;\r\n\r\n count = 0;\r\n this.availableYears.forEach(function(year) {\r\n yearsToDisplay[count] = new Array();\r\n\r\n // if the month is not January, fiscalYearEnd will be in the following year\r\n if (moment(fiscalYearStartDate).month() != 0){\r\n yearsToDisplay[count][0] = year;\r\n yearsToDisplay[count][1] = year + 1;\r\n } else {\r\n yearsToDisplay[count][0] = year;\r\n yearsToDisplay[count][1] = year;\r\n }\r\n count++;\r\n });\r\n this.yearsToDisplay = yearsToDisplay;\r\n this.yearSelected();\r\n }\r\n }\r\n });\r\n\r\n this.propertyTypes = _.map(this.constants.PropertyTypeNames, (name: string, id: number) => {\r\n return {\r\n name: name,\r\n propertyTypeId: Number(id)\r\n };\r\n });\r\n\r\n this.report.criteria.propertyTypeIDs = this.report.criteria.propertyTypeIDs || [1, 2, 3, 4];\r\n if ([null, undefined].indexOf(this.report.criteria.includeDisclaimer) !== -1) {\r\n this.report.criteria.includeDisclaimer = true;\r\n }\r\n\r\n this.numYears = [2, 3, 4, 5, 6];\r\n this.yearsToDisplay = yearsToDisplay;\r\n\r\n const defaultValues: object = {\r\n minimumDetailYearsShown: 2,\r\n includePPPropertyType: true,\r\n budgetYear: new Date().getFullYear() + 1\r\n };\r\n\r\n _.defaults(this.report.criteria, defaultValues);\r\n\r\n this.yearSelected();\r\n }\r\n\r\n yearSelected() {\r\n const fiscalYearStartDate = new Date(`${this.fiscalYearStart}/${new Date().getFullYear()}`);\r\n let endBudgetYear = this.report.criteria.budgetYear;\r\n if (moment(fiscalYearStartDate).month() != 0){\r\n endBudgetYear = endBudgetYear + 1;\r\n }\r\n this.report.criteria.budgetYearString = `${this.fiscalYearStart}/${this.report.criteria.budgetYear} - ${this.fiscalYearEnd}/${endBudgetYear}`;\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ReportDetail, SiteStatus } from '../report.manager.model';\r\nimport * as _ from 'lodash';\r\nimport { Constants } from '../../../constants.new';\r\nimport { ReportManagerService } from '../report.manager.service';\r\n\r\n@Component({\r\n selector: 'further-limit-panel-maar',\r\n template: `\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n `\r\n})\r\nexport class FurtherLimitPanelMaarComponent implements OnInit {\r\n constructor(private constants: Constants, private reportManagerService: ReportManagerService) { }\r\n\r\n @Input() report: ReportDetail;\r\n @Input() availableYears: number[];\r\n propertyTypes: any[];\r\n siteStatuses: SiteStatus[];\r\n\r\n ngOnInit() {\r\n\r\n this.propertyTypes = _.map(this.constants.PropertyTypeNames, (name: string, id: string) => {\r\n return {\r\n name: name,\r\n propertyTypeId: Number(id)\r\n };\r\n });\r\n\r\n this.report.criteria.propertyTypeIDs = this.report.criteria.propertyTypeIDs || [1, 2, 3, 4];\r\n\r\n\t\t// todo - get all options, this is just for mvp\r\n this.siteStatuses = this.reportManagerService.getSiteStatusOptionsExceptInactive();\r\n\r\n this.report.criteria.siteStatus = this.report.criteria.siteStatus || this.siteStatuses[0].id;\r\n this.report.criteria.taxYear = this.report.criteria.taxYear || new Date().getFullYear() + 1;\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ReportDetail, SiteStatus } from '../report.manager.model';\r\nimport * as _ from 'lodash';\r\nimport { Constants } from '../../../constants.new';\r\nimport { ReportManagerService } from '../report.manager.service';\r\n\r\n@Component({\r\n selector: 'further-limit-panel-progress-status',\r\n template: `\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n `\r\n})\r\nexport class FurtherLimitPanelProgressStatusComponent implements OnInit {\r\n constructor(private constants: Constants, private reportManagerService: ReportManagerService) { }\r\n\r\n @Input() report: ReportDetail;\r\n @Input() availableYears: number[];\r\n propertyTypes: any[];\r\n siteStatuses: SiteStatus[];\r\n\r\n ngOnInit() {\r\n\r\n this.propertyTypes = _.map(this.constants.PropertyTypeNames, (name: string, id: number) => {\r\n return {\r\n name: name,\r\n propertyTypeId: Number(id)\r\n };\r\n });\r\n\r\n this.siteStatuses = this.reportManagerService.getSiteStatusOptions();\r\n\r\n this.report.criteria.siteStatus = this.report.criteria.siteStatus || this.siteStatuses[0].id;\r\n if (!this.report.criteria.taxYearBegin) {\r\n const newYearValue = new Date().getFullYear() - 3;\r\n this.report.criteria.taxYearBegin = newYearValue;\r\n }\r\n this.report.criteria.propertyTypeIDs = this.report.criteria.propertyTypeIDs || [1, 2, 3, 4];\r\n }\r\n\r\n yearChangedValidation(): void {\r\n if (this.report.criteria.taxYearBegin > this.report.criteria.taxYearEnd) {\r\n this.report.criteria.taxYearEnd = null;\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Order ByGroup By
{{field.name}}
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit, OnDestroy } from '@angular/core';\r\nimport { ReportDetail, FormatOutputOptionsPsr, PsrReportCriteria, OrderAndTotalByOption, GenericEntity } from '../report.manager.model';\r\nimport * as _ from 'lodash';\r\nimport { ReportManagerService } from '../report.manager.service';\r\nimport { Subscription } from 'rxjs';\r\nimport { ReportType } from '../report-type';\r\n\r\n@Component({\r\n selector: 'format-output-panel-psr',\r\n templateUrl: './format.output.panel.psr.component.html'\r\n})\r\nexport class FormatOutputPanelPsrComponent implements OnInit, OnDestroy {\r\n constructor(private reportManagerService: ReportManagerService) {\r\n this.subscription = reportManagerService.currentPropChars$.subscribe(\r\n propChars => {\r\n this.filterPropChars(propChars);\r\n }\r\n );\r\n }\r\n\r\n @Input() report: ReportDetail;\r\n orderAndTotalBySelected: OrderAndTotalByOption;\r\n orderAndTotalBySelection: OrderAndTotalByOption[] = [];\r\n orderAndTotalByOptions: OrderAndTotalByOption[];\r\n orderAndTotalByOptionsOriginal: OrderAndTotalByOption[];\r\n subscription: Subscription;\r\n reportTypes = ReportType;\r\n\r\n outputFormatOptions: string[];\r\n paperSizeOptions: string[];\r\n showAssessmentsOptions: string[];\r\n showMetricsOptions: string[];\r\n showValueOptions: string[];\r\n showTaxDetailsOptions: string[];\r\n showLatestValueOptions: string[];\r\n showSavingsOptions: string[];\r\n showSiteAppealCommentsOptions: string[];\r\n\r\n ngOnInit() {\r\n this._setDefaultsBudget();\r\n }\r\n\r\n orderAndTotalByChanged(): void {\r\n this.report.criteria.psrFormatOutputOptions.orderGroupBy = _.cloneDeep(this.orderAndTotalBySelection);\r\n this.orderAndTotalByOptions = _.map(this.orderAndTotalByOptions, (option: OrderAndTotalByOption) => {\r\n option.groupByThisItem = false;\r\n return option;\r\n });\r\n\r\n if(this.orderAndTotalBySelected.id) {\r\n this.report.criteria.psrFormatOutputOptions.orderGroupBy.push(this.orderAndTotalBySelected);\r\n }\r\n }\r\n\r\n addNewOrderAndTotalBy(): void {\r\n this.orderAndTotalBySelection.push(this.orderAndTotalBySelected);\r\n\r\n this.orderAndTotalByOptions = _.reject(this.orderAndTotalByOptions, {id: this.orderAndTotalBySelected.id});\r\n this.orderAndTotalBySelected = this.orderAndTotalByOptions[0];\r\n }\r\n\r\n removeOrderAndTotalBy(field: OrderAndTotalByOption): void {\r\n _.remove(this.orderAndTotalBySelection, field);\r\n this.report.criteria.psrFormatOutputOptions.orderGroupBy = _.reject(this.report.criteria.psrFormatOutputOptions.orderGroupBy, {id: field.id});\r\n\r\n field.groupByThisItem = false;\r\n this.orderAndTotalByOptions.push(field);\r\n this.orderAndTotalByOptions = _.sortBy(this.orderAndTotalByOptions, ['primarySortOrder', 'name']);\r\n }\r\n\r\n groupByChanged(field: OrderAndTotalByOption): void {\r\n const i = _.findIndex(this.report.criteria.psrFormatOutputOptions.orderGroupBy, {id: field.id});\r\n\r\n if(i >= 0) {\r\n this.report.criteria.psrFormatOutputOptions.orderGroupBy[i].groupByThisItem = field.groupByThisItem;\r\n }\r\n }\r\n\r\n filterPropChars(entityPropChars: GenericEntity[]) {\r\n if(entityPropChars.length) {\r\n this.orderAndTotalByOptions = _.filter(this.orderAndTotalByOptions, (option) => {\r\n return _.includes(_.map(entityPropChars, 'id'), option.id) || option.id < 0 || !option.id;\r\n });\r\n } else {\r\n this.orderAndTotalByOptions = _.chain(this.orderAndTotalByOptionsOriginal)\r\n .cloneDeep()\r\n .reject(option => {\r\n return _.some(this.report.criteria.psrFormatOutputOptions.orderGroupBy, {id: option.id});\r\n })\r\n .value();\r\n }\r\n }\r\n\r\n ngOnDestroy() {\r\n // prevent memory leak when component destroyed\r\n this.subscription.unsubscribe();\r\n }\r\n\r\n private _setDefaultsBudget(): void {\r\n\r\n this.reportManagerService.getTotalAndGroupByOptions()\r\n .then((result: OrderAndTotalByOption[]) => {\r\n const formatOutputOptions: FormatOutputOptionsPsr = new FormatOutputOptionsPsr();\r\n formatOutputOptions.orderAndTotalByOptions = _.sortBy(result, ['primarySortOrder', 'name']);\r\n formatOutputOptions.orderAndTotalByOptions.unshift({\r\n id: null,\r\n name: '',\r\n primarySortOrder: -1000\r\n });\r\n _.assign(this, formatOutputOptions);\r\n\r\n this.orderAndTotalByOptionsOriginal = _.cloneDeep(this.orderAndTotalByOptions);\r\n\r\n this._populateOrderBy();\r\n });\r\n\r\n this.report.criteria.outputFormat = this.report.criteria.outputFormat || 0;\r\n this.report.criteria.psrFormatOutputOptions = this.report.criteria.psrFormatOutputOptions || new PsrReportCriteria(this.report.reportTypeId);\r\n }\r\n\r\n private _populateOrderBy() {\r\n if(this.report.criteria.psrFormatOutputOptions.orderGroupBy.length) {\r\n this.orderAndTotalBySelection = _.cloneDeep(_.initial(this.report.criteria.psrFormatOutputOptions.orderGroupBy));\r\n const lastOrderById: OrderAndTotalByOption = _.last(this.report.criteria.psrFormatOutputOptions.orderGroupBy);\r\n this.orderAndTotalBySelected = _.find(this.orderAndTotalByOptions, {id: lastOrderById.id});\r\n this.orderAndTotalBySelected.groupByThisItem = lastOrderById.groupByThisItem;\r\n } else {\r\n this.orderAndTotalBySelected = this.orderAndTotalByOptions[0];\r\n }\r\n }\r\n}","import { Component, Input, OnInit, EventEmitter, Output, OnDestroy } from '@angular/core';\r\nimport { OrderAndTotalByOption, GenericEntity } from '../../report.manager.model';\r\nimport { ReportManagerService } from '../../report.manager.service';\r\nimport { Subscription } from 'rxjs';\r\n\r\nimport { cloneDeep, reject } from 'lodash/fp';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'report-order-by',\r\n template: `\r\n
\r\n \r\n \r\n \r\n
\r\n `\r\n})\r\nexport class ReportOrderByComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _reportManagerService: ReportManagerService) {}\r\n\r\n @Input() isTotal?: boolean = true;\r\n @Input() orderBy: number[] = [];\r\n\r\n @Output() orderByChange = new EventEmitter();\r\n\r\n orderAndTotalBySelection: OrderAndTotalByOption[] = [];\r\n orderAndTotalByOptions: OrderAndTotalByOption[] = [];\r\n orderAndTotalByOptionsOriginal: OrderAndTotalByOption[];\r\n\r\n subscription: Subscription;\r\n\r\n async ngOnInit(): Promise {\r\n this.subscription = this._reportManagerService.currentPropChars$.subscribe(propChars => {\r\n this.filterPropChars(propChars);\r\n });\r\n\r\n const orderByOptions = await this._reportManagerService.getOrderAndTotalByOptions();\r\n\r\n this.orderAndTotalByOptions = _.sortBy(orderByOptions, ['primarySortOrder', 'name']);\r\n\r\n this.orderAndTotalByOptionsOriginal = _.cloneDeep(this.orderAndTotalByOptions);\r\n\r\n if (this.orderBy.length) {\r\n this.orderAndTotalBySelection = this.orderBy.map(x => this.orderAndTotalByOptions.find(y => x === y.id));\r\n }\r\n }\r\n ngOnDestroy(): void {\r\n this.subscription.unsubscribe();\r\n }\r\n\r\n orderAndTotalByChanged(): void {\r\n this.orderBy = this.orderAndTotalBySelection.map(x => x.id);\r\n this.orderByChange.emit(this.orderBy);\r\n }\r\n\r\n filterPropChars(entityPropChars: GenericEntity[]): void {\r\n if(entityPropChars.length) {\r\n this.orderAndTotalByOptions = this.orderAndTotalByOptions.filter(option => {\r\n return entityPropChars.map(x => x.id).includes(option.id) || option.id < 0 || !option.id;\r\n });\r\n } else {\r\n this.orderAndTotalByOptions = _.flow([\r\n cloneDeep,\r\n reject(option => _.some(this.orderBy, {id: option.id}))\r\n ])(this.orderAndTotalByOptionsOriginal);\r\n }\r\n }\r\n}\r\n","import { Component, Input, OnInit, Output, EventEmitter } from '@angular/core';\r\nimport { ExtraReportDetailCriteria } from '../report.manager.model';\r\nimport { AssessmentTaxesOptions, AssessmentTaxesCriteria } from '../../../Common/Assessment-Taxes-Details/assessment-taxes-details.models';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'report-detail-options',\r\n template: `\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n `\r\n})\r\nexport class ReportDetailOptionsComponent implements OnInit {\r\n @Input() isBudgetReport?: boolean;\r\n\r\n @Output()\r\n detailReportOptionsChange = new EventEmitter();\r\n valueDetailsOptions: string[];\r\n includeAssessedValueInfoOptions: string[];\r\n includeTargetValueOptions: string[];\r\n includeValuationMetricsOptions: string[];\r\n breakOutTaxPaymentDetailsOptions: string[];\r\n showPercentChangeOptions: string[];\r\n\r\n @Input()\r\n get detailReportOptions() {\r\n return this._detailReportOptions;\r\n }\r\n\r\n set detailReportOptions(val) {\r\n this._detailReportOptions = val;\r\n this.detailReportOptionsChange.emit(this._detailReportOptions);\r\n }\r\n\r\n private _detailReportOptions: ExtraReportDetailCriteria;\r\n\r\n ngOnInit() {\r\n _.assign(this, new AssessmentTaxesOptions());\r\n\r\n this.detailReportOptions = this.detailReportOptions || new AssessmentTaxesCriteria();\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n

Summary Report Options

\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Detail Report Options

\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ReportDetail, SummaryReportCriteria, FormatOutputOptionsBudget } from '../report.manager.model';\r\nimport { ForecastingBudgetingService } from '../../../Budget/forecasting.budgeting.service';\r\nimport { ReportManagerService } from '../report.manager.service';\r\nimport * as moment from 'moment';\r\nimport { CompanyBudgetBasisEnum } from '../../../Budget/forecasting.budgeting.model';\r\nimport { EntityTypeIds } from '../../../constants.new';\r\n\r\n@Component({\r\n selector: 'format-output-panel-budget',\r\n templateUrl: './format.output.panel.budget.component.html'\r\n})\r\nexport class FormatOutputPanelBudgetComponent implements OnInit {\r\n constructor(\r\n private forecastingBudgetingService: ForecastingBudgetingService,\r\n private reportManagerService: ReportManagerService,\r\n ) {}\r\n\r\n @Input() report: ReportDetail;\r\n outputFormatOptions: string[];\r\n summaryCashBasisPeriodOptions: string[];\r\n showPercentChangeOptions: string[];\r\n detailLevelOptions: string[];\r\n\r\n CompanyBudgetBasisEnum = CompanyBudgetBasisEnum;\r\n\r\n budgetYear: number;\r\n availableBudgets: Core.AvailableCompanyBudget[];\r\n availableBasisBudgets: Core.AvailableCompanyBudget[];\r\n\r\n\r\n async ngOnInit() {\r\n this.reportManagerService.topLevelCompanies$.subscribe(async topLevelCompaniesObj => {\r\n if(topLevelCompaniesObj.topLevelCompanyIds.length == 1) {\r\n this.report.criteria.budgetBasis = await this.forecastingBudgetingService.getCompanyBudgetBasis(EntityTypeIds.COMPANY, topLevelCompaniesObj.topLevelCompanyIds[0]);\r\n this.availableBudgets = await this.forecastingBudgetingService.getAvailableCompanyBudgets(topLevelCompaniesObj.topLevelCompanyIds[0]);\r\n this.budgetBasisChanged(topLevelCompaniesObj.initFromSavedReport);\r\n }\r\n });\r\n\r\n this._setDefaultsBudget();\r\n }\r\n\r\n get budgetYearSources(): Core.AvailableCompanyBudget[] {\r\n return _.filter(this.availableBasisBudgets, budget => moment.utc(budget.fiscalPeriodBegin).year() == this.report.criteria.budgetYear);\r\n }\r\n\r\n get priorYearSources(): Core.AvailableCompanyBudget[] {\r\n return _.filter(this.availableBasisBudgets, budget => moment.utc(budget.fiscalPeriodBegin).year() == this.report.criteria.budgetYear -1);\r\n }\r\n\r\n budgetBasisChanged(initFromSavedReport?: boolean) {\r\n this.availableBasisBudgets = _.filter(this.availableBudgets, budget => {\r\n switch(budget.budgetBasis) {\r\n case Core.CompanyBudgetBasisEnum.AccrualAndCash:\r\n return true;\r\n case Core.CompanyBudgetBasisEnum.Accrual:\r\n return this.report.criteria.budgetBasis == Core.CompanyBudgetBasisEnum.Accrual;\r\n case Core.CompanyBudgetBasisEnum.Cash:\r\n return this.report.criteria.budgetBasis == Core.CompanyBudgetBasisEnum.Cash;\r\n }\r\n });\r\n\r\n if(initFromSavedReport) {\r\n return;\r\n }\r\n\r\n if(this.budgetYearSources.length) {\r\n if(!_.some(this.budgetYearSources, {companyBudgetId: this.report.criteria.currCompanyBudgetID})) {\r\n this.report.criteria.currCompanyBudgetID = this.budgetYearSources[0].companyBudgetId;\r\n }\r\n } else {\r\n this.report.criteria.currCompanyBudgetID = 0;\r\n }\r\n\r\n if(!this.priorYearSources.length || !_.some(this.priorYearSources, {companyBudgetId: this.report.criteria.priorCompanyBudgetID})) {\r\n this.report.criteria.priorCompanyBudgetID = 0;\r\n }\r\n }\r\n\r\n private _setDefaultsBudget(): void {\r\n _.assign(this, new FormatOutputOptionsBudget());\r\n this.report.criteria.outputFormat = this.report.criteria.outputFormat || 0;\r\n\r\n this.report.criteria.summaryReportOptions = this.report.criteria.summaryReportOptions || new SummaryReportCriteria();\r\n this.report.criteria.currCompanyBudgetID = this.report.criteria.currCompanyBudgetID || 0;\r\n this.report.criteria.priorCompanyBudgetID = this.report.criteria.priorCompanyBudgetID || 0;\r\n }\r\n\r\n\r\n}","import { Component, Input, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport { Constants } from '../../../constants.new';\r\n\r\n@Component({\r\n selector: 'further-limit-panel-site',\r\n template: `\r\n
\r\n
\r\n \r\n Latest assessed tax year plus \r\n\r\n \r\n\r\n prior tax years\r\n
\r\n
\r\n \r\n Tax years \r\n \r\n to \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n `\r\n})\r\nexport class FurtherLimitPanelSiteComponent implements OnInit {\r\n constructor(private constants: Constants) { }\r\n\r\n @Input() report: ReportDetail;\r\n @Input() availableYears: number[];\r\n @Input() hasRyanPrivatePermission: boolean;\r\n taxYearBeginUI: number;\r\n propertyTypes: any[];\r\n\r\n numYearsArr = [\r\n { n: 0, s: '0' },\r\n { n: 1, s: '1' },\r\n { n: 2, s: '2' },\r\n { n: 3, s: '3' },\r\n { n: -1, s: 'All' },\r\n ];\r\n\r\n\r\n ngOnInit() {\r\n const currentYear: number = new Date().getFullYear();\r\n this.report.criteria.yearChoice = this.report.criteria.yearChoice || 'latest';\r\n this.report.criteria.numberOfYearsToInclude = this.report.criteria.numberOfYearsToInclude === undefined ? 2 : this.report.criteria.numberOfYearsToInclude;\r\n this.report.criteria.taxYearBegin = this.report.criteria.taxYearBegin === undefined ? 0 : this.report.criteria.taxYearBegin;\r\n this.taxYearBeginUI = this.report.criteria.taxYearBegin || currentYear - 2;\r\n this.report.criteria.taxYearEnd = this.report.criteria.taxYearEnd || currentYear;\r\n\r\n this.propertyTypes = _.map(this.constants.PropertyTypeNames, (name: string, id: number) => {\r\n return {\r\n name: name,\r\n propertyTypeId: Number(id)\r\n };\r\n });\r\n\r\n this.report.criteria.propertyTypeIDs = this.report.criteria.propertyTypeIDs || [1, 2, 3, 4];\r\n if ([null, undefined].indexOf(this.report.criteria.includeDisclaimer) !== -1) {\r\n this.report.criteria.includeDisclaimer = true;\r\n }\r\n }\r\n\r\n yearChoiceChanged(): void {\r\n if(this.report.criteria.yearChoice === 'latest') {\r\n this.report.criteria.taxYearBegin = 0;\r\n } else {\r\n this.report.criteria.taxYearBegin = this.taxYearBeginUI;\r\n }\r\n }\r\n\r\n yearChangedValidation(): void {\r\n this.report.criteria.taxYearBegin = this.taxYearBeginUI;\r\n\r\n if (this.report.criteria.taxYearBegin > this.report.criteria.taxYearEnd) {\r\n this.report.criteria.taxYearEnd = null;\r\n }\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ReportDetail, SiteReportCriteria } from '../report.manager.model';\r\n\r\n@Component({\r\n selector: 'format-output-panel-site',\r\n template: `\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n `\r\n})\r\nexport class FormatOutputPanelSiteComponent implements OnInit {\r\n @Input() report: ReportDetail;\r\n\r\n ngOnInit() {\r\n this.report.criteria.orderBy = this.report.criteria.orderBy || [];\r\n this.report.criteria.siteFormatOutputOptions = this.report.criteria.siteFormatOutputOptions || new SiteReportCriteria();\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport { ReportManagerModalInputParameters } from '../reportManagerModal.component';\r\n@Component({\r\n selector: 'further-limit-panel-schedules-summary',\r\n templateUrl: './further.limit.panel.schedules.summary.component.html'\r\n})\r\nexport class FurtherLimitPanelSchedulesSummaryComponent implements OnInit{\r\n\r\n @Input() report: ReportDetail;\r\n @Input() modalParameters?: ReportManagerModalInputParameters;\r\n\r\n formRevisions: Compliance.ReturnFormRevisionModel[] = [];\r\n private _schedules: Compliance.FormRevisionScheduleModel[];\r\n\r\n async ngOnInit(): Promise {\r\n this._schedules = [\r\n {\r\n formRevisionScheduleId: -2,\r\n name: 'Reportable, Taxable'\r\n },\r\n {\r\n formRevisionScheduleId: -4,\r\n name: 'Reportable, Not Taxable'\r\n },\r\n {\r\n formRevisionScheduleId: -3,\r\n name: 'Reportable Taxable and Not Taxable'\r\n },\r\n {\r\n formRevisionScheduleId: -1,\r\n name: 'Non-Reportable'\r\n }\r\n ] as Compliance.FormRevisionScheduleModel[];\r\n\r\n if (this.modalParameters){\r\n if (this.modalParameters.formRevisions){\r\n this.formRevisions = this.modalParameters.formRevisions;\r\n }\r\n\r\n if (this.modalParameters.schedules){\r\n this.modalParameters.schedules.forEach(item => this._schedules.push(item));\r\n }\r\n\r\n if (!this.report.criteria.formRevisionId && this.formRevisions.length === 1){\r\n this.report.criteria.formRevisionId = this.formRevisions[0].formRevisionId;\r\n }\r\n }\r\n\r\n if (this.report.criteria.scheduleId){\r\n const selectedSchedule = this._schedules.find(i => i.formRevisionScheduleId === this.report.criteria.scheduleId);\r\n this.report.criteria.scheduleName = selectedSchedule ? selectedSchedule.name : null;\r\n }\r\n }\r\n\r\n get isSystemControlled(): boolean {\r\n return this.report.isSystemReport;\r\n }\r\n\r\n get schedules(): Compliance.FormRevisionScheduleModel[]{\r\n return this._schedules;\r\n }\r\n\r\n get scheduleId(): number {\r\n return this.report.criteria.scheduleId;\r\n }\r\n\r\n set scheduleId(value: number) {\r\n this.report.criteria.scheduleId = value;\r\n const selectedSchedule = this._schedules.find(i => i.formRevisionScheduleId === value);\r\n this.report.criteria.scheduleName = selectedSchedule ? selectedSchedule.name : null;\r\n }\r\n\r\n get scheduleSelectorDisabled(): boolean {\r\n return this.modalParameters && this.modalParameters.filingBatchId && !this.report.criteria.formRevisionId;\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Report Format:\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Optional Columns:\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit, OnDestroy } from '@angular/core';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport { UntypedFormControl, UntypedFormBuilder, UntypedFormGroup } from '@angular/forms';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\n\r\ninterface FormConfig {\r\n label: string;\r\n formControlName: string;\r\n}\r\n\r\n@Component({\r\n selector: 'format-output-panel-schedules-summary',\r\n templateUrl: './format.output.panel.schedules.summary.component.html',\r\n styleUrls: ['./format.output.panel.scss']\r\n})\r\nexport class FormatOutputPanelSchedulesSummaryComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _fb: UntypedFormBuilder) {}\r\n\r\n @Input() report: ReportDetail;\r\n @Input()\r\n set scheduleName(scheduleName: string) {\r\n this.report.criteria.title = this._getTitle(scheduleName);\r\n this.reportOutputForm.patchValue({ title: this.report.criteria.title });\r\n }\r\n\r\n initialized: boolean;\r\n formatOptions: FormConfig[] = [\r\n {\r\n label: 'Show Taxpayer Name',\r\n formControlName: 'showTaxpayerName'\r\n },\r\n {\r\n label: 'Suppress zero cost',\r\n formControlName: 'suppressZeroCost'\r\n },\r\n {\r\n label: 'Show Grand Total',\r\n formControlName: 'showGrandTotal'\r\n },\r\n {\r\n label: 'Split out Factors',\r\n formControlName: 'splitOutFactors'\r\n }\r\n ];\r\n optionalCols: FormConfig[] = [\r\n {\r\n label: 'Cost',\r\n formControlName: 'includeCost'\r\n },\r\n {\r\n label: 'Prior Cost / Adds / Deletes',\r\n formControlName: 'includePriorCostAddsDeletes'\r\n },\r\n {\r\n label: 'Factor and Depreciated Value',\r\n formControlName: 'includeFactorAndDepreciatedValue'\r\n },\r\n {\r\n label: 'Estimated FMV',\r\n formControlName: 'includeEstimatedFMV'\r\n }\r\n ];\r\n reportOutputForm: UntypedFormGroup = this._fb.group({\r\n title: this._fb.control('')\r\n });\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n const createControl = (x: FormConfig) => this.reportOutputForm.addControl(x.formControlName,\r\n new UntypedFormControl(this.report.criteria[x.formControlName]));\r\n\r\n this.formatOptions.forEach(createControl);\r\n this.optionalCols.forEach(createControl);\r\n\r\n this.reportOutputForm.patchValue({title: this.report.criteria.title});\r\n\r\n this.reportOutputForm.valueChanges\r\n .pipe(takeUntil(this.destroy$))\r\n .subscribe(() => this._updateReport());\r\n\r\n this.reportOutputForm.get('splitOutFactors').valueChanges\r\n .pipe(takeUntil(this.destroy$))\r\n .subscribe(value => {\r\n if (!value) {\r\n this.report.criteria.includeFactorAndDepreciatedValue = false;\r\n }\r\n });\r\n\r\n this.initialized = true;\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n private _getTitle(scheduleName?: string): string{\r\n if (this.report.criteria && this.report.criteria.title) {\r\n return this.report.criteria.title;\r\n } else if (!scheduleName || scheduleName === 'All Reportable'){\r\n return 'Schedule Summary';\r\n } else if (scheduleName === 'All Non-Reportable') {\r\n return 'Schedule Summary (Non-Reportable)';\r\n } else {\r\n return scheduleName;\r\n }\r\n }\r\n\r\n private _updateReport(): void {\r\n this.report.criteria = { ...this.report.criteria, ...this.reportOutputForm.value };\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport { ReportManagerModalInputParameters } from '../reportManagerModal.component';\r\nimport { ReturnAssetFilter } from '../../../Compliance/Return/Return-Parts/Assets/Asset-Status-Selector/returnAssetStatusSelector.component';\r\n\r\n@Component({\r\n selector: 'further-limit-panel-asset-detail',\r\n templateUrl: './further.limit.panel.asset.detail.component.html'\r\n})\r\nexport class FurtherLimitPanelAssetDetailComponent implements OnInit{\r\n\r\n @Input() report: ReportDetail;\r\n @Input() modalParameters?: ReportManagerModalInputParameters;\r\n\r\n formRevisions: Compliance.ReturnFormRevisionModel[] = [];\r\n private _scheduleFilters: Compliance.FormRevisionScheduleModel[] = [\r\n {\r\n formRevisionScheduleId: Compliance.ReportScheduleFilterTypeEnum.AllReportableTaxable,\r\n name: 'All Reportable, Taxable'\r\n },\r\n {\r\n formRevisionScheduleId: Compliance.ReportScheduleFilterTypeEnum.AllReportableNotTaxable,\r\n name: 'All Reportable, Not Taxable'\r\n },\r\n {\r\n formRevisionScheduleId: Compliance.ReportScheduleFilterTypeEnum.AllReportableTaxableNotTaxable,\r\n name: 'All Reportable, Taxable and Not Taxable'\r\n },\r\n {\r\n formRevisionScheduleId: Compliance.ReportScheduleFilterTypeEnum.AllNotReportableSchedules,\r\n name: 'All Not Reportable Schedules'\r\n },\r\n {\r\n formRevisionScheduleId: Compliance.ReportScheduleFilterTypeEnum.OnlyReportableNotTaxableSchedule,\r\n name: 'Only Reportable/Not Taxable Schedule'\r\n }\r\n ] as Compliance.FormRevisionScheduleModel[];\r\n private _schedules: Compliance.FormRevisionScheduleModel[] = [];\r\n\r\n async ngOnInit(): Promise {\r\n if (this.modalParameters) {\r\n if (this.modalParameters.formRevisions) {\r\n this.formRevisions = this.modalParameters.formRevisions;\r\n }\r\n\r\n if (this.modalParameters.schedules) {\r\n this.modalParameters.schedules.forEach(item => this._schedules.push(item));\r\n }\r\n }\r\n\r\n if (this.report.criteria.scheduleId) {\r\n const selectedSchedule = this._schedules.find(i => i.formRevisionScheduleId === this.report.criteria.scheduleId);\r\n this.report.criteria.scheduleName = selectedSchedule ? selectedSchedule.name : null;\r\n }\r\n\r\n if (!this.report.criteria.formRevisionId) {\r\n this.report.criteria.formRevisionId = null;\r\n }\r\n }\r\n\r\n get isSystemControlled(): boolean {\r\n return this.report.isSystemReport;\r\n }\r\n\r\n get schedules(): Compliance.FormRevisionScheduleModel[] {\r\n return this.report.criteria.formRevisionId\r\n ? this._schedules.filter(x => (this.report.criteria.formRevisionId && x.formRevisionId === this.report.criteria.formRevisionId))\r\n : this._scheduleFilters;\r\n }\r\n\r\n get priorReturnStatuses(): Compliance.ReturnAssetPriorReturnStatusEnum[]{\r\n return this.report.criteria.priorReturnStatuses;\r\n }\r\n\r\n set priorReturnStatuses(model: Compliance.ReturnAssetPriorReturnStatusEnum[]) {\r\n this.report.criteria.priorReturnStatuses = model;\r\n }\r\n\r\n get scheduleId(): number {\r\n return this.report.criteria.formRevisionId ? this.report.criteria.scheduleId : this.report.criteria.scheduleFilterType;\r\n }\r\n\r\n assignScheduleId(value: number) {\r\n let selectedSchedule: Compliance.FormRevisionScheduleModel;\r\n if (this.report.criteria.formRevisionId) {\r\n this.report.criteria.scheduleId = value;\r\n this.report.criteria.scheduleFilterType = Compliance.ReportScheduleFilterTypeEnum.Unrestricted;\r\n selectedSchedule = this._schedules.find(i => i.formRevisionScheduleId === value);\r\n } else {\r\n this.report.criteria.scheduleFilterType = value;\r\n this.report.criteria.scheduleId = null;\r\n selectedSchedule = this._scheduleFilters.find(i => i.formRevisionScheduleId === value);\r\n }\r\n this.report.criteria.scheduleName = selectedSchedule ? selectedSchedule.name : null;\r\n }\r\n\r\n onSelectedAssetStatusFilterChange(filter: ReturnAssetFilter): void{\r\n this.report.criteria.priorReturnStatusName = filter.name;\r\n this.report.criteria.priorReturnStatuses = filter.statuses;\r\n }\r\n\r\n onFormRevisionChange(revisionId: any): void {\r\n this.report.criteria.formRevisionId = revisionId;\r\n this.assignScheduleId(this.report.criteria.formRevisionId ? this.schedules[0].formRevisionScheduleId : this._scheduleFilters[0].formRevisionId);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Report Layout:\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Report Format:\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Optional Columns:\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n Lease fields:\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit, Output, EventEmitter, OnDestroy } from '@angular/core';\r\nimport { UntypedFormControl, UntypedFormGroup, UntypedFormBuilder } from '@angular/forms';\r\nimport { ReportDetail, ReturnAssetDetailIncludeAssetDescriptorModel } from '../report.manager.model';\r\nimport { ReportManagerModalInputParameters } from '../reportManagerModal.component';\r\nimport { ReturnRepository } from '../../../Compliance/Repositories';\r\nimport { CompanyAssetDescriptorRepository } from '../../../Compliance/Repositories';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\n\r\ninterface FormConfig {\r\n label: string;\r\n formControlName: string;\r\n}\r\n\r\ninterface LeaseFormConfig extends FormConfig {\r\n leaseType: Compliance.AssetOwnershipTypeEnum;\r\n}\r\n\r\n@Component({\r\n selector: 'format-output-panel-asset-detail',\r\n templateUrl: './format.output.panel.asset.detail.component.html',\r\n styleUrls: ['./format.output.panel.scss']\r\n})\r\nexport class FormatOutputPanelAssetDetailComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _companyAssetDescriptorRepository: CompanyAssetDescriptorRepository,\r\n private readonly _fb: UntypedFormBuilder\r\n ) {\r\n }\r\n\r\n @Input() report: ReportDetail;\r\n @Input() modalParameters?: ReportManagerModalInputParameters;\r\n\r\n @Input()\r\n set scheduleName(scheduleName: string) {\r\n this._previousScheduleName = this._scheduleName;\r\n this._scheduleName = scheduleName;\r\n this._setTitle();\r\n }\r\n\r\n @Input()\r\n set priorReturnStatusName(priorReturnStatusName: string) {\r\n this._priorReturnStatusName = priorReturnStatusName;\r\n this._setTitle();\r\n }\r\n\r\n @Output() reportChange: EventEmitter = new EventEmitter();\r\n\r\n selectedAssetGroups: UntypedFormControl = new UntypedFormControl();\r\n assetGroups: Compliance.NameValuePair[] = [\r\n { name: 'Acquisition Year', value: ['groupByAcqYear'] },\r\n { name: 'Asset Classification', value: ['groupByAssetClass'] },\r\n { name: 'Factor Table', value: ['splitOutFactors'] },\r\n { name: 'Linked/Sub Parcel Acct Num', value: ['groupByLinkedSubParcelAcctNum'] },\r\n { name: 'Linked/Sub Parcel Assessor', value: ['groupByLinkedSubAssessorAbbr']},\r\n { name: 'Linked/Sub Parcel Desc', value: ['groupByLinkedSubParcelDescription'] },\r\n { name: 'Schedule', value: ['groupBySchedule'] },\r\n { name: 'Schedule + Factor Table', value: ['groupBySchedule', 'splitOutFactors'] },\r\n { name: 'Site Address', value: ['groupBySiteAddress'] },\r\n { name: 'Site Name', value: ['groupBySiteName'] },\r\n { name: 'Site Number', value: ['groupBySiteNumber'] },\r\n { name: 'Cost Change', value: ['groupByCostChange'] }\r\n ];\r\n\r\n additionalDescriptors: ReturnAssetDetailIncludeAssetDescriptorModel[] = [];\r\n assetDescriptors: Core.DescriptorModel[] = [];\r\n\r\n assetOwnershipType: UntypedFormControl = new UntypedFormControl();\r\n ownershipTypes: {label: string, value: string}[] = [\r\n { label: 'Owned', value: `${+Compliance.AssetOwnershipTypeEnum.Owned}` },\r\n { label: 'Leased to Other', value: `${+Compliance.AssetOwnershipTypeEnum.LeasedToOther}` },\r\n { label: 'Leased from Other', value: `${+Compliance.AssetOwnershipTypeEnum.LeasedFromOther}` }\r\n ];\r\n\r\n layoutGroup: UntypedFormGroup;\r\n reportFormatGroup: UntypedFormGroup;\r\n leaseFromGroup: UntypedFormGroup;\r\n leaseToGroup: UntypedFormGroup;\r\n optionalGroup: UntypedFormGroup = this._fb.group({\r\n includeAssetClass: [false],\r\n includeAcqYear: [false],\r\n includeDisposedDate: [false],\r\n includeGLAccount: [false],\r\n includeScheduleName: [false],\r\n includeFactorTableName: [false],\r\n includeFactorAndDepreciatedValue: [false],\r\n //includeRatioAndAssessedValue: [false], // WR-4487\r\n includeAdditionalDepreciation: [false],\r\n includeEstimatedFMV: [false],\r\n includeCost: [false],\r\n includeCostChange: [false],\r\n includeAssetDescriptors: [[]]\r\n });\r\n\r\n reportFormatting: FormConfig[] = [\r\n {\r\n label: 'Show Taxpayer Name',\r\n formControlName: 'showTaxpayerName'\r\n },\r\n {\r\n label: 'Show Transfer Details',\r\n formControlName: 'showTransferDetails'\r\n },\r\n {\r\n label: 'Show Change Details',\r\n formControlName: 'showChangeDetails'\r\n },\r\n {\r\n label: 'Show Grand Total',\r\n formControlName: 'showGrandTotal'\r\n }\r\n ];\r\n optionalCols: FormConfig[] = [\r\n {\r\n label: 'Cost',\r\n formControlName: 'includeCost'\r\n },\r\n {\r\n label: 'Cost Change',\r\n formControlName: 'includeCostChange'\r\n },\r\n {\r\n label: 'Asset Class',\r\n formControlName: 'includeAssetClass'\r\n },\r\n {\r\n label: 'Acq. Year',\r\n formControlName: 'includeAcqYear'\r\n },\r\n {\r\n label: 'Disposed Date',\r\n formControlName: 'includeDisposedDate'\r\n },\r\n {\r\n label: 'G/L Account',\r\n formControlName: 'includeGLAccount'\r\n },\r\n {\r\n label: 'Schedule Name',\r\n formControlName: 'includeScheduleName'\r\n },\r\n {\r\n label: 'Factor Table Name',\r\n formControlName: 'includeFactorTableName'\r\n },\r\n {\r\n label: 'Factor and Depreciated Value',\r\n formControlName: 'includeFactorAndDepreciatedValue'\r\n },\r\n {\r\n label: 'Additional Depreciation',\r\n formControlName: 'includeAdditionalDepreciation'\r\n },\r\n {\r\n label: 'Estimated FMV',\r\n formControlName: 'includeEstimatedFMV'\r\n }\r\n ];\r\n leaseToCols: FormConfig[] = [\r\n {\r\n label: 'Lease Customer ID',\r\n formControlName: 'includeLeaseClientId'\r\n },\r\n {\r\n label: 'Location Name',\r\n formControlName: 'includeLeaseLocationName'\r\n },\r\n {\r\n label: 'Location Address',\r\n formControlName: 'includeLeaseLocationAddress'\r\n }\r\n ];\r\n leaseFromCols: FormConfig[] = [\r\n {\r\n label: 'Lease Start Date',\r\n formControlName: 'includeLeaseStartDate'\r\n },\r\n {\r\n label: 'Lease End Date',\r\n formControlName: 'includeLeaseEndDate'\r\n },\r\n {\r\n label: 'Lease Term In Months',\r\n formControlName: 'includeLeaseTerm'\r\n },\r\n {\r\n label: 'Lease Monthly Payment',\r\n formControlName: 'includeLeaseMonthlyPayments'\r\n },\r\n {\r\n label: 'Lease Type',\r\n formControlName: 'includeLeaseType'\r\n },\r\n {\r\n label: 'Lease Asset ID',\r\n formControlName: 'includeLeaseAssestId'\r\n },\r\n {\r\n label: 'Lease Number',\r\n formControlName: 'includeLeaseNumber'\r\n },\r\n {\r\n label: 'Billing Info',\r\n formControlName: 'includeLeaseBillingInfo'\r\n },\r\n {\r\n label: 'Linked/Sub Parcel Acct Number',\r\n formControlName: 'includeLinkedSubParcelAcctNumber'\r\n },\r\n {\r\n label: 'Linked/Sub Parcel Description',\r\n formControlName: 'includeLinkedSubParcelDescription'\r\n },\r\n {\r\n label: 'Linked/Sub Assessor Abbr',\r\n formControlName: 'includeLinkedSubAssessorAbbr'\r\n }\r\n ];\r\n\r\n get hasMoreAvailableDescriptors(): boolean {\r\n return this.additionalDescriptors.length > 0;\r\n }\r\n\r\n private _previousScheduleName?: string;\r\n private _scheduleName?: string;\r\n private _priorReturnStatusName?: string;\r\n private destroy$: Subject = new Subject();\r\n\r\n async ngOnInit(): Promise {\r\n // Setup form groups\r\n this.layoutGroup = this._createLayoutGroup();\r\n this.reportFormatGroup = this._createFormatGroup();\r\n this.leaseFromGroup = this._createLeaseFormGroup();\r\n this.leaseToGroup = this._createLeaseFormGroup();\r\n\r\n this.leaseToCols = [...this.leaseToCols, ...this.leaseFromCols];\r\n\r\n this.assetOwnershipType.setValue((!this.report.criteria.assetType) ? '0' : this.report.criteria.assetType);\r\n\r\n await this._setAssetDescriptors();\r\n this._initializeAdditionalColumns();\r\n\r\n if (this.assetOwnershipType.value === `${+Compliance.AssetOwnershipTypeEnum.LeasedToOther}`) {\r\n this.leaseToGroup.patchValue(this._getLeaseValues());\r\n } else if (this.assetOwnershipType.value === `${+Compliance.AssetOwnershipTypeEnum.LeasedFromOther}`) {\r\n this.leaseFromGroup.patchValue(this._getLeaseValues());\r\n }\r\n this.optionalGroup.patchValue(this._getOptionalValues());\r\n\r\n this._initializeSelectedGroups();\r\n this.selectedAssetGroups.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(() => this._applyGroupingChanges());\r\n\r\n // Listen to group changes\r\n this.assetOwnershipType.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(() => this._outputReport());\r\n this.leaseFromGroup.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(() => this._outputReport());\r\n this.leaseToGroup.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(() => this._outputReport());\r\n this.optionalGroup.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(() => this._outputReport());\r\n this.layoutGroup.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(() => this._outputReport());\r\n this.reportFormatGroup.valueChanges.pipe(takeUntil(this.destroy$)).subscribe(() => this._outputReport());\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.complete();\r\n }\r\n\r\n private _getOptionalValues() {\r\n const { criteria } = this.report;\r\n return {\r\n includeAssetClass: !!criteria.includeAssetClass,\r\n includeAcqYear: !!criteria.includeAcqYear,\r\n includeDisposedDate: !!criteria.includeDisposedDate,\r\n includeGLAccount: !!criteria.includeGLAccount,\r\n includeScheduleName: !!criteria.includeScheduleName,\r\n includeFactorTableName: !!criteria.includeFactorTableName,\r\n includeFactorAndDepreciatedValue: !!criteria.includeFactorAndDepreciatedValue,\r\n //includeRatioAndAssessedValue: !!criteria.includeRatioAndAssessedValue, //WR-4487\r\n includeAdditionalDepreciation: !!criteria.includeAdditionalDepreciation,\r\n includeEstimatedFMV: !!criteria.includeEstimatedFMV,\r\n includeCost: !!criteria.includeCost,\r\n includeCostChange: !!criteria.includeCostChange\r\n };\r\n }\r\n\r\n private _getLeaseValues() {\r\n const { criteria } = this.report;\r\n return {\r\n includeLeaseClientId: !!criteria.includeLeaseClientId,\r\n includeLeaseLocationName: !!criteria.includeLeaseLocationName,\r\n includeLeaseLocationAddress: !!criteria.includeLeaseLocationAddress,\r\n includeLeaseStartDate: !!criteria.includeLeaseStartDate,\r\n includeLeaseEndDate: !!criteria.includeLeaseEndDate,\r\n includeLeaseTerm: !!criteria.includeLeaseTerm,\r\n includeLeaseMonthlyPayments: !!criteria.includeLeaseMonthlyPayments,\r\n includeLeaseType: !!criteria.includeLeaseType,\r\n includeLeaseAssestId: !!criteria.includeLeaseAssestId,\r\n includeLeaseNumber: !!criteria.includeLeaseNumber,\r\n includeLeaseBillingInfo: !!criteria.includeLeaseBillingInfo,\r\n includeLinkedSubParcelAcctNumber: !!criteria.includeLinkedSubParcelAcctNumber,\r\n includeLinkedSubParcelDescription: !!criteria.includeLinkedSubParcelDescription,\r\n includeLinkedSubAssessorAbbr: !!criteria.includeLinkedSubAssessorAbbr\r\n };\r\n }\r\n\r\n private _setTitle(){\r\n const previousExpectedName = FormatOutputPanelAssetDetailComponent._getTitle(this._previousScheduleName, this._priorReturnStatusName);\r\n const newExpectedName = FormatOutputPanelAssetDetailComponent._getTitle(this._scheduleName, this.priorReturnStatusName);\r\n\r\n if (!this.report.criteria.title || this.report.criteria.title === previousExpectedName){\r\n this.report.criteria.title = newExpectedName;\r\n }\r\n }\r\n\r\n private static _getTitle(scheduleName?: string, priorReturnStatusName?: string): string{\r\n let result: string;\r\n\r\n if (!scheduleName || scheduleName === 'All Reportable'){\r\n result = 'Detailed Asset List';\r\n } else if (scheduleName === 'All Non-Reportable') {\r\n result = 'Detailed Asset List (Non-Reportable)';\r\n } else{\r\n result = scheduleName;\r\n }\r\n\r\n if (priorReturnStatusName && priorReturnStatusName !== 'All assets at lien date'){\r\n result += ` - ${priorReturnStatusName}`;\r\n }\r\n return result;\r\n }\r\n\r\n private async _setAssetDescriptors(): Promise {\r\n this.report.criteria.includeAssetDescriptors = this.report.criteria.includeAssetDescriptors || [];\r\n\r\n if (this.modalParameters && this.modalParameters.filingBatchId) {\r\n this.assetDescriptors = await lastValueFrom(this._returnRepository.getAssetCharacteristics(this.modalParameters.filingBatchId));\r\n } else {\r\n this.assetDescriptors = await lastValueFrom(this._companyAssetDescriptorRepository.getAssetCharacteristics());\r\n }\r\n\r\n this.additionalDescriptors = this.assetDescriptors.map(a => {\r\n return {\r\n descriptorId: a.descriptorID,\r\n name: a.name,\r\n include: true\r\n };\r\n });\r\n }\r\n\r\n private _initializeAdditionalColumns(): void {\r\n const includeAssetDescriptors = this.report.criteria.includeAssetDescriptors.map(item => {\r\n const assetDescriptor = this.assetDescriptors.find(i => i.descriptorID === item.descriptorId);\r\n const model: ReturnAssetDetailIncludeAssetDescriptorModel = {\r\n descriptorId: item.descriptorId,\r\n name: assetDescriptor ? assetDescriptor.name : 'Unknown Descriptor',\r\n include: item.include\r\n };\r\n return model;\r\n }).sort((a, b) => a.name.localeCompare(b.name));\r\n\r\n this.optionalGroup.patchValue({ includeAssetDescriptors });\r\n }\r\n\r\n private _initializeSelectedGroups(): void {\r\n if (!this.report.criteria.groupBy) { return; }\r\n let skipNext = false;\r\n // convert to values that match select list value format\r\n const groupBy = this.report.criteria.groupBy.reduce((acc, g, i, src) => {\r\n if (skipNext) {\r\n skipNext = false;\r\n return acc;\r\n }\r\n if (g === 'groupBySchedule' && src[i + 1] === 'splitOutFactors') {\r\n // handle the only current option that sets two values\r\n acc.push([g, src[i + 1]]);\r\n skipNext = true;\r\n } else {\r\n acc.push([g]);\r\n }\r\n return acc;\r\n }, []);\r\n // get matching values to assign\r\n const groups = groupBy.reduce((acc, group) => {\r\n const assetGroup = this.assetGroups.find(g => g.value.toString() === group.toString());\r\n if (assetGroup) {\r\n acc.push(assetGroup.value);\r\n }\r\n return acc;\r\n }, []);\r\n this.selectedAssetGroups.setValue(groups);\r\n this._applyGroupingChanges();\r\n }\r\n\r\n private _applyGroupingChanges(): void {\r\n const selectedGroups = this.selectedAssetGroups.value as string[][];\r\n const unique = selectedGroups.reduce((acc, val) => {\r\n val.forEach(v => acc.add(v));\r\n return acc;\r\n }, new Set());\r\n this.reportFormatGroup.patchValue({groupBy: Array.from(unique)});\r\n this._outputReport();\r\n }\r\n\r\n private _createLeaseFormGroup(): UntypedFormGroup {\r\n return this._fb.group({\r\n includeLeaseClientId: [false],\r\n includeLeaseLocationName: [false],\r\n includeLeaseLocationAddress: [false],\r\n includeLeaseStartDate: [false],\r\n includeLeaseEndDate: [false],\r\n includeLeaseTerm: [false],\r\n includeLeaseMonthlyPayments: [false],\r\n includeLeaseType: [false],\r\n includeLeaseAssestId: [false],\r\n includeLeaseNumber: [false],\r\n includeLeaseBillingInfo: [false],\r\n includeLinkedSubParcelAcctNumber: [false],\r\n includeLinkedSubParcelDescription: [false],\r\n includeLinkedSubAssessorAbbr: [false]\r\n });\r\n }\r\n\r\n private _createLayoutGroup(): UntypedFormGroup {\r\n const { criteria } = this.report;\r\n const group = this._fb.group({\r\n outputFormat: [criteria.outputFormat],\r\n legalSize: [!!criteria.legalSize],\r\n showLandscape: [!!criteria.showLandscape],\r\n watermark: [criteria.watermark]\r\n });\r\n\r\n group.get('outputFormat').valueChanges.pipe(takeUntil(this.destroy$))\r\n .subscribe(() => group.get('watermark').setValue(''));\r\n\r\n return group;\r\n }\r\n\r\n private _createFormatGroup(): UntypedFormGroup {\r\n const { criteria } = this.report;\r\n return this._fb.group({\r\n showTaxpayerName: [!!criteria.showTaxpayerName],\r\n showTransferDetails: [!!criteria.showTransferDetails],\r\n showChangeDetails: [!!criteria.showChangeDetails],\r\n showGrandTotal: [!!criteria.showGrandTotal],\r\n groupBy: []\r\n });\r\n }\r\n\r\n /**\r\n * Combine all the form values into the report output\r\n */\r\n private _outputReport(): void {\r\n let leaseOutput = {};\r\n if (this.assetOwnershipType.value === `${+Compliance.AssetOwnershipTypeEnum.LeasedToOther}`) {\r\n leaseOutput = this.leaseToGroup.value;\r\n } else if (this.assetOwnershipType.value === `${+Compliance.AssetOwnershipTypeEnum.LeasedFromOther}`) {\r\n leaseOutput = this.leaseFromGroup.value;\r\n }\r\n const newCriteria = {\r\n ...this.report.criteria,\r\n ...this.layoutGroup.value,\r\n ...this.reportFormatGroup.value,\r\n ...this.optionalGroup.value,\r\n ...leaseOutput,\r\n assetType: this.assetOwnershipType.value\r\n };\r\n newCriteria.includeAssetDescriptors = this.optionalGroup.value.includeAssetDescriptors.filter(d => d.include);\r\n\r\n const combined: ReportDetail = { ...this.report, ...{ criteria: newCriteria } };\r\n this.reportChange.emit(combined);\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport * as _ from 'lodash';\r\n\r\ndeclare const moment: any;\r\n\r\nenum UserAccessReportLimitByLoginDateEnum {\r\n Period = Core.UserAccessReportLimitByLoginDateEnum.Period as number,\r\n DateRange = Core.UserAccessReportLimitByLoginDateEnum.DateRange as number,\r\n AnyValidDate = Core.UserAccessReportLimitByLoginDateEnum.AnyValidDate as number\r\n}\r\n\r\n@Component({\r\n selector: 'further-limit-panel-user-activity',\r\n template: `\r\n
\r\n
\r\n
\r\n \r\n Login Period \r\n\r\n \r\n
\r\n
\r\n \r\n Login Date Range \r\n \r\n \r\n to\r\n \r\n \r\n
\r\n
\r\n \r\n Any Valid Login Date\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n `\r\n})\r\nexport class FurtherLimitPanelUserActivityComponent implements OnInit {\r\n @Input() report: ReportDetail;\r\n taxYearBeginUI: number;\r\n propertyTypes: any[];\r\n loginDateBeginUI: Date;\r\n loginDateEndUI: Date;\r\n periodOptions: {val: number, label: string}[] = [{\r\n val: 90,\r\n label: '90 Days'\r\n }, {\r\n val: 60,\r\n label: '60 Days'\r\n }, {\r\n val: 30,\r\n label: '30 Days'\r\n }];\r\n\r\n UserAccessReportLimitByLoginDateEnum = UserAccessReportLimitByLoginDateEnum;\r\n\r\n ngOnInit() {\r\n if(_.isUndefined(this.report.criteria.limitByLoginDate)) {\r\n this.report.criteria.limitByLoginDate = Core.UserAccessReportLimitByLoginDateEnum.Period;\r\n }\r\n this.report.criteria.loginDatePeriod = this.report.criteria.loginDatePeriod || 90;\r\n this.loginDateBeginUI = this.report.criteria.loginDateBegin;\r\n this.loginDateEndUI = this.report.criteria.loginDateEnd;\r\n this.loginDateChoiceChanged();\r\n\r\n this.report.criteria.onlyActiveUsers = this.report.criteria.onlyActiveUsers || false;\r\n this.report.criteria.includeUsersWithoutLogin = this.report.criteria.includeUsersWithoutLogin || false;\r\n this.report.criteria.includeInternalUsers = this.report.criteria.includeInternalUsers || false;\r\n }\r\n\r\n loginDateChoiceChanged(): void {\r\n switch(this.report.criteria.limitByLoginDate) {\r\n case Core.UserAccessReportLimitByLoginDateEnum.Period:\r\n this.report.criteria.loginDateBegin = moment().tz('America/Chicago').subtract(this.report.criteria.loginDatePeriod, 'days').toDate();\r\n this.report.criteria.loginDateEnd = moment().tz('America/Chicago').toDate();\r\n break;\r\n case Core.UserAccessReportLimitByLoginDateEnum.DateRange:\r\n this.report.criteria.loginDateBegin = this.loginDateBeginUI;\r\n this.report.criteria.loginDateEnd = this.loginDateEndUI;\r\n break;\r\n }\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport * as _ from 'lodash';\r\n\r\ndeclare const moment: any;\r\n\r\nenum SupportInstanceEscalationActivityReportLimitByEscalationDateEnum {\r\n Period = Core.SupportInstanceEscalationActivityReportLimitByEscalationDateEnum.Period as number,\r\n DateRange = Core.SupportInstanceEscalationActivityReportLimitByEscalationDateEnum.DateRange as number,\r\n AnyValidDate = Core.SupportInstanceEscalationActivityReportLimitByEscalationDateEnum.AnyValidDate as number\r\n}\r\n\r\n@Component({\r\n selector: 'further-limit-panel-support-instance-escalation-activity',\r\n template: `\r\n
\r\n
\r\n \r\n Escalation Period \r\n\r\n \r\n
\r\n
\r\n \r\n Escalation Date Range \r\n \r\n \r\n to\r\n \r\n \r\n
\r\n
\r\n \r\n Any Escalation Date\r\n
\r\n
\r\n `\r\n})\r\nexport class FurtherLimitPanelSupportInstanceEscalationActivityComponent implements OnInit{\r\n @Input() report: ReportDetail;\r\n\r\n SupportInstanceEscalationActivityReportLimitByEscalationDateEnum = SupportInstanceEscalationActivityReportLimitByEscalationDateEnum;\r\n escalationDateBeginUI: Date;\r\n escalationDateEndUI: Date;\r\n periodOptions: {val: number, label: string}[] = [{\r\n val: 90,\r\n label: '90 Days'\r\n }, {\r\n val: 60,\r\n label: '60 Days'\r\n }, {\r\n val: 30,\r\n label: '30 Days'\r\n }];\r\n\r\n ngOnInit() {\r\n if(_.isUndefined(this.report.criteria.limitByEscalationDate)) {\r\n this.report.criteria.limitByEscalationDate = Core.SupportInstanceEscalationActivityReportLimitByEscalationDateEnum.Period;\r\n }\r\n this.report.criteria.escalationDatePeriod = this.report.criteria.escalationDatePeriod || 90;\r\n this.escalationDateBeginUI = this.report.criteria.escalationDateBegin;\r\n this.escalationDateEndUI = this.report.criteria.escalationDateEnd;\r\n this.escalationDateChoiceChanged();\r\n }\r\n\r\n escalationDateChoiceChanged(): void {\r\n switch(this.report.criteria.limitByEscalationDate) {\r\n case Core.SupportInstanceEscalationActivityReportLimitByEscalationDateEnum.Period:\r\n this.report.criteria.escalationDateBegin = moment().tz('America/Chicago').subtract(this.report.criteria.escalationDatePeriod, 'days').toDate();\r\n this.report.criteria.escalationDateEnd = moment().tz('America/Chicago').toDate();\r\n this.report.criteria.anyEscalationDates = false;\r\n break;\r\n case Core.SupportInstanceEscalationActivityReportLimitByEscalationDateEnum.DateRange:\r\n this.report.criteria.escalationDateBegin = this.escalationDateBeginUI;\r\n this.report.criteria.escalationDateEnd = this.escalationDateEndUI;\r\n this.report.criteria.anyEscalationDates = false;\r\n break;\r\n default:\r\n this.report.criteria.escalationDateBegin = null;\r\n this.report.criteria.escalationDateEnd = null;\r\n this.report.criteria.anyEscalationDates = true;\r\n break;\r\n }\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport { ReportType } from '../report-type';\r\nimport KeyValuePair = System.Collections.Generic.KeyValuePair;\r\n\r\nenum SupportInstanceEscalationActivityReportGroupByEnum {\r\n SupportInstance = Core.SupportInstanceEscalationActivityReportGroupByEnum.SupportInstance as number,\r\n User = Core.SupportInstanceEscalationActivityReportGroupByEnum.User as number\r\n}\r\n@Component({\r\n selector: 'format-output-panel-support-instance-escalation-activity',\r\n template: `\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n `,\r\n styleUrls: ['./format.output.panel.scss']\r\n})\r\nexport class FormatOutputPanelSupportInstanceEscalationActivityComponent implements OnInit{\r\n @Input() report: ReportDetail;\r\n outputFormatOptions: KeyValuePair[];\r\n reportTypes = ReportType;\r\n\r\n SupportInstanceEscalationActivityReportGroupByEnum = SupportInstanceEscalationActivityReportGroupByEnum;\r\n\r\n ngOnInit() {\r\n this.outputFormatOptions = [\r\n {\r\n key: Core.SupportInstanceEscalationActivityReportOutputFormatEnum.PDF,\r\n value: 'PDF'\r\n },\r\n {\r\n key: Core.SupportInstanceEscalationActivityReportOutputFormatEnum.Excel,\r\n value: 'Excel'\r\n }];\r\n this.report.criteria.outputFormat = this.report.criteria.outputFormat || Core.SupportInstanceEscalationActivityReportOutputFormatEnum.PDF;\r\n this.report.criteria.escalationGroupBy = Core.SupportInstanceEscalationActivityReportGroupByEnum.SupportInstance;\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { SearchPageType, UserSaveService } from '../../Navigation/User-Save/userSave.service';\r\nimport {\r\n BudgetVarianceBudgetSource,\r\n EntitySelection,\r\n GetEntitiesRequest,\r\n ReportDetail,\r\n SelectedEntity\r\n} from './report.manager.model';\r\nimport { ReportManagerService } from './report.manager.service';\r\nimport { ReportManagerSelectEntitiesService } from './select.entities.service';\r\nimport { ReportManagerModalInputParameters } from './reportManagerModal.component';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { SaveReportModalComponent } from '../Modals/save-report.component';\r\nimport { InstanceRights, RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport {\r\n BudgetRequest,\r\n BudgetVarianceReportingRequest,\r\n MaarRequest,\r\n ProgressStatusRequest,\r\n PsrRequest,\r\n ReportingService,\r\n SiteRequest, SupportInstanceEscalationActivityReportRequest,\r\n UserAccessRequest,\r\n UserActivityRequest,\r\n UserCSRRequest\r\n} from '../reporting.service';\r\nimport { MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { ReportType } from './report-type';\r\nimport { FormRepository, ReturnRepository } from '../../Compliance/Repositories';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { REPORT_MANAGER_HELP } from './report.manager.component.help';\r\nimport { ContactsUpgradeService } from '../../Contact/contacts.service.upgrade';\r\nimport { ExtendedContactModelCore } from '../../Common/User-Pickers/user.picker.component';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\n\r\nimport SearchType = Core.SearchType;\r\nimport { SnackBarService } from '../../Busy-Indicator';\r\nimport { EntityTypeIds } from '../../constants.new';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { UserInstanceService } from 'src/app/User/userInstance.service';\r\n\r\ndeclare const _: any;\r\n\r\nenum StartWithEnum {\r\n Company = Core.UserAccessReportStartWithEnum.Company as number,\r\n SingleUser = Core.UserAccessReportStartWithEnum.SingleUser as number\r\n}\r\n\r\n@Component({\r\n selector: 'report-manager',\r\n templateUrl: './report.manager.component.html'\r\n})\r\nexport class ReportManagerComponent implements OnInit {\r\n constructor(\r\n private readonly _reportManagerService: ReportManagerService,\r\n private readonly _selectEntitiesService: ReportManagerSelectEntitiesService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _reportingService: ReportingService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _formRepository: FormRepository,\r\n private readonly _returnRepository: ReturnRepository,\r\n private readonly _helpService: HelpService,\r\n private readonly _contactsService: ContactsUpgradeService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _snackBarService: SnackBarService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _weissmanModalService: WeissmanModalService,\r\n private readonly _userSaveService: UserSaveService\r\n ) {\r\n this.saveModalClosed = new EventEmitter();\r\n }\r\n\r\n @Input() modalParameters?: ReportManagerModalInputParameters;\r\n @Output() saveModalClosed: EventEmitter;\r\n\r\n report: ReportDetail;\r\n loading: boolean;\r\n initializingReport: boolean;\r\n isSystemReport: boolean;\r\n hasSystemReportPermission: boolean;\r\n hasRyanPrivatePermission: boolean;\r\n saveVisible: boolean;\r\n saveAsVisible: boolean;\r\n reportTypes = ReportType;\r\n availableYears: number[];\r\n isInModal: boolean = false;\r\n userSearch: any;\r\n isSingleInstanceSelected: boolean = false;\r\n StartWithEnum = StartWithEnum;\r\n\r\n get showEntitiesSelector(): boolean {\r\n return this.report.reportTypeId !== this.reportTypes.ReturnScheduleSummary &&\r\n this.report.reportTypeId !== this.reportTypes.ReturnAssetDetail &&\r\n this.report.reportTypeId !== this.reportTypes.UserCSR &&\r\n this.report.criteria.startWith === Core.UserAccessReportStartWithEnum.Company;\r\n }\r\n\r\n get requestButtonIsDisabled(): boolean {\r\n if(this.initializingReport) {\r\n return true;\r\n }\r\n\r\n if(this.report.criteria.startWith === Core.UserAccessReportStartWithEnum.SingleUser || this.report.reportTypeId === this.reportTypes.UserCSR) {\r\n return !this.report.criteria.selectedContact;\r\n } else if (this.report.reportTypeId === this.reportTypes.SupportInstanceEscalationActivity) {\r\n return !(!!this.report.criteria.escalationDateBegin && !!this.report.criteria.escalationDateEnd || this.report.criteria.anyEscalationDates);\r\n } else {\r\n return !this.companiesSelected;\r\n }\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(REPORT_MANAGER_HELP);\r\n\r\n this.hasSystemReportPermission = this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT);\r\n this.hasRyanPrivatePermission = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT);\r\n this.isSingleInstanceSelected = this._userInstanceService.isSingleInstanceSelected();\r\n\r\n // parameters passed via route or via input\r\n let reportID: number;\r\n if (this.modalParameters) {\r\n reportID = this.modalParameters.reportId;\r\n this.isSystemReport = this.modalParameters.reportType === 0;\r\n this.isInModal = true;\r\n } else {\r\n reportID = Number(this._upgradeNavigationServiceHandler.getQuerystringParam('reportId'));\r\n this.isSystemReport = Number(this._upgradeNavigationServiceHandler.getQuerystringParam('reportType')) === 0;\r\n }\r\n await this.refresh(reportID);\r\n\r\n this.availableYears = this._reportManagerService.getAvailableYears();\r\n\r\n this.userSearch = {\r\n find: (filter) => {\r\n return this._contactsService.search(null, filter, 1, 100, this.report.reportTypeId !== this.reportTypes.UserCSR);\r\n }\r\n };\r\n }\r\n\r\n async refresh(reportID?: number): Promise {\r\n if (reportID === undefined) {\r\n reportID = this.report.reportID;\r\n }\r\n\r\n this.loading = true;\r\n\r\n try {\r\n this.saveVisible = false;\r\n this.saveAsVisible = true;\r\n this.report = null;\r\n if (this.modalParameters && this.modalParameters.filingBatchId) {\r\n this.report = await this._returnRepository.getFilingBatchReport(this.modalParameters.filingBatchId, reportID, SearchType.Report);\r\n } else {\r\n this.report = await this._reportManagerService.getReport(reportID);\r\n }\r\n\r\n if (this.hasRestrictedAccess(this.report)) {\r\n this._upgradeNavigationServiceHandler.go('unauthorizedAccess', {});\r\n\r\n return;\r\n }\r\n\r\n this.report.criteria.entitySelection = this.report.criteria.entitySelection || new EntitySelection();\r\n if(_.isUndefined(this.report.criteria.startWith)) {\r\n this.report.criteria.startWith = Core.UserAccessReportStartWithEnum.Company;\r\n }\r\n this.updateSaveVisible();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n\r\n async saveReport(): Promise {\r\n if (!this._isComplianceReport()) {\r\n this._saveSystemReport();\r\n } else if (this._isComplianceReport() && this.modalParameters && this.modalParameters.filingBatchId) {\r\n const updatedReport = await lastValueFrom(this._returnRepository.saveCustomReport(this.modalParameters.filingBatchId, this.report.reportID, this.report));\r\n this.handleSaveModalClose(updatedReport);\r\n } else if (this._isComplianceReport() && this.modalParameters && this.modalParameters.formRevisionId) {\r\n const updatedReport = await lastValueFrom(this._formRepository.saveCustomReport(this.modalParameters.formRevisionId, this.report.reportID, this.report));\r\n this.handleSaveModalClose(updatedReport);\r\n } else {\r\n // regular endpoint works for non-formrev / filing batch compliance reports\r\n this._saveSystemReport();\r\n }\r\n }\r\n\r\n async saveReportAs(): Promise {\r\n const params = {\r\n report: this.report,\r\n isSystemReport: this.isSystemReport,\r\n modalParameters: this.modalParameters\r\n };\r\n const result = await this._weissmanModalService.showAsync(SaveReportModalComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return;\r\n }\r\n\r\n this.handleSaveModalClose(result);\r\n\r\n if (!this._isComplianceReport()) {\r\n this._upgradeNavigationServiceHandler.transitionTo(this._upgradeNavigationServiceHandler.getCurrentState(), {\r\n reportId: this.report.reportID,\r\n reportType: result.isSystemReport ? 0 : 1\r\n }, {\r\n reload: true\r\n });\r\n }\r\n this._userSaveService.updateList(SearchPageType.Report);\r\n\r\n if (!this.modalParameters) {\r\n this._toastr.success('Report saved');\r\n }\r\n }\r\n\r\n handleSaveModalClose(report: any) {\r\n this._userSaveService.updateList(SearchPageType.Report);\r\n this.saveModalClosed.emit(report);\r\n }\r\n\r\n async requestReport() {\r\n this.initializingReport = true;\r\n\r\n try {\r\n let lrpId: number;\r\n let lrpTypeId: number;\r\n switch (this.report.reportTypeId) {\r\n case this.reportTypes.ProjectStatus:\r\n lrpId = await this.requestPsrReport();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.PsrReport;\r\n break;\r\n case this.reportTypes.AppealRecommendation:\r\n lrpId = await this.requestPsrReport();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.AppealListReport;\r\n break;\r\n case this.reportTypes.Maar:\r\n lrpId = await this.requestMaarReport();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.MaarReport;\r\n break;\r\n case this.reportTypes.Budget:\r\n lrpId = await this.requestBudgetReport();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.BudgetReport;\r\n break;\r\n case this.reportTypes.BudgetVariance:\r\n lrpId = await this.requestBudgetVarianceReport();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.BudgetVarianceReport;\r\n break;\r\n case this.reportTypes.ProgressStatus:\r\n lrpId = await this.requestProgressStatusReport();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.PseReport;\r\n break;\r\n case this.reportTypes.Site:\r\n lrpId = await this.requestSiteReport();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.SiteReport;\r\n break;\r\n case this.reportTypes.UserActivity:\r\n lrpId = await this.requestUserActivity();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.UserActivityReport;\r\n break;\r\n case this.reportTypes.UserAccess:\r\n lrpId = await this.requestUserAccess();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.UserAccessReport;\r\n break;\r\n case this.reportTypes.UserCSR:\r\n lrpId = await this.requestUserCSR();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.UserCsrReport;\r\n break;\r\n case this.reportTypes.SupportInstanceEscalationActivity:\r\n lrpId = await this.requestSupportInstanceEscalationActivityReport();\r\n lrpTypeId = Compliance.LongRunningProcessTypeEnum.UserCsrReport;\r\n break;\r\n }\r\n if (lrpId) {\r\n this._snackBarService.addById(lrpId, lrpTypeId);\r\n }\r\n } finally {\r\n this.initializingReport = false;\r\n }\r\n }\r\n\r\n showRevokeReportButton(): boolean {\r\n return this.report.isOwnedByUser && this.report.isShared;\r\n }\r\n\r\n revokeReportShare(): void {\r\n this._messageBoxService.confirm('Sharing with other users will be revoked. Click OK to confirm.', 'Reports')\r\n .then(() => {\r\n this._reportManagerService.revokeShare(this.report).then((result: any) => {\r\n this.report.isShared = result.isShared;\r\n this._toastr.success('Share was revoked');\r\n });\r\n });\r\n }\r\n\r\n updateFavoriteStatus(isFavorite: boolean): void {\r\n this.report.criteria.frequentlyUsed = isFavorite;\r\n }\r\n\r\n showRequestReportButton(): boolean {\r\n return this.report.reportTypeId !== this.reportTypes.ReturnScheduleSummary &&\r\n this.report.reportTypeId !== this.reportTypes.ReturnAssetDetail;\r\n }\r\n\r\n setSelectedContact(contact: ExtendedContactModelCore) {\r\n this.report.criteria.selectedContact = contact.model;\r\n }\r\n\r\n private hasRestrictedAccess(report: ReportDetail): boolean {\r\n if (report.categoryID === Core.SavedSearchCategoryEnum.ComplianceReportSetup || report.categoryID === Core.SavedSearchCategoryEnum.ComplianceCustomReport) {\r\n return !this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW);\r\n }\r\n\r\n if (report.reportTypeId === this.reportTypes.UserActivity) {\r\n return !this._restrictService.isInRole(Roles.USERREPORTSALLOW);\r\n }\r\n\r\n if (report.reportTypeId == this.reportTypes.Maar) {\r\n return !this.hasRyanPrivatePermission;\r\n }\r\n\r\n if (report.reportTypeId === this.reportTypes.SupportInstanceEscalationActivity) {\r\n return !this._restrictService.isInRole(Roles.ALLOWSUPPORTESCALATIONREPORT);\r\n }\r\n\r\n return false;\r\n }\r\n\r\n private updateSaveVisible(): void {\r\n if (this.isInModal) {\r\n // for our compliance reports, in the modal we never save system, only create custom ones based\r\n // on them. Save as on custom would take an extra workflow\r\n this.saveVisible = !this.isSystemReport;\r\n this.saveAsVisible = this.isSystemReport;\r\n } else {\r\n const specialCompliancePermission: boolean = this.hasSystemReportPermission && this._isComplianceReport();\r\n this.saveVisible = (specialCompliancePermission && !this.isSystemReport) || (this.report.variantName && this.report.isOwnedByUser && (!this.isSystemReport || this.hasSystemReportPermission));\r\n }\r\n }\r\n\r\n private _saveSystemReport(): void {\r\n this._reportManagerService.saveReport(this.report, this.isSystemReport).then((result: any) => {\r\n this.report.rowVersion = result.rowVersion;\r\n this._userSaveService.updateList(SearchPageType.Report);\r\n\r\n if (!this.modalParameters) {\r\n this._toastr.success('Report saved');\r\n }\r\n });\r\n }\r\n\r\n private _isComplianceReport(): boolean {\r\n return [Core.SavedSearchCategoryEnum.ComplianceReportSetup,\r\n Core.SavedSearchCategoryEnum.ComplianceReturnReport,\r\n Core.SavedSearchCategoryEnum.CompliancePackageReport,\r\n Core.SavedSearchCategoryEnum.ComplianceCustomReport].includes(this.report.categoryID);\r\n }\r\n\r\n private async requestBudgetReport(): Promise {\r\n if (this.report.criteria.entitySelection.selectedTopLevelCompanyIDs.length > 1) {\r\n this._toastr.error('Select only one Top Level Company for this report');\r\n\r\n return null;\r\n }\r\n\r\n const reportRequest = new BudgetRequest();\r\n const basePayload: GetEntitiesRequest = this._selectEntitiesService.getPayloadSourceEntityData(this.report.criteria.entitySelection);\r\n\r\n Object.assign(reportRequest, basePayload);\r\n reportRequest.reportTitle = this.report.variantName || this.report.displayName;\r\n reportRequest.budgetYear = this.report.criteria.budgetYear;\r\n reportRequest.budgetYearString = this.report.criteria.budgetYearString;\r\n reportRequest.outputFormat = this.report.criteria.outputFormat;\r\n //reportRequest.includePPPropertyType = this.report.criteria.includePPPropertyType;\r\n reportRequest.propertyTypes = this.report.criteria.propertyTypeIDs;\r\n reportRequest.minimumDetailYearsShown = this.report.criteria.minimumDetailYearsShown;\r\n reportRequest.currCompanyBudgetID = this.report.criteria.currCompanyBudgetID;\r\n reportRequest.priorCompanyBudgetID = this.report.criteria.priorCompanyBudgetID;\r\n reportRequest.budgetBasis = this.report.criteria.budgetBasis;\r\n reportRequest.includeDisclaimer = this.report.criteria.includeDisclaimer;\r\n reportRequest.detailReportOptions = this.report.criteria.detailReportOptions;\r\n reportRequest.summaryReportOptions = this.report.criteria.summaryReportOptions;\r\n\r\n return await this._reportingService.runBudgetReport(reportRequest);\r\n }\r\n\r\n private async requestBudgetVarianceReport(): Promise {\r\n if (this.report.criteria.entitySelection.selectedTopLevelCompanyIDs.length > 1) {\r\n this._toastr.error('Select only one Top Level Company for this report');\r\n\r\n return null;\r\n }\r\n if (this.report.criteria.bvrFormatOutput.budgetSources[0].budgetId < 0 ||\r\n this.report.criteria.bvrFormatOutput.budgetSources[1].budgetId < 0) {\r\n this._toastr.error('A selection must be made for the 1st and 2nd Source Budgets');\r\n return null;\r\n }\r\n if (this.report.criteria.bvrFormatOutput.budgetSources[3].budgetId > 0 &&\r\n this.report.criteria.bvrFormatOutput.budgetSources[2].budgetId < 0) {\r\n this._toastr.error('A 3rd Source Budget must be selected if a 4th is selected');\r\n return null;\r\n }\r\n if (this.report.criteria.bvrFormatOutput.budgetSources[1].budgetPeriod.periodBegin > this.report.criteria.bvrFormatOutput.budgetSources[0].budgetPeriod.periodBegin ||\r\n (this.report.criteria.bvrFormatOutput.budgetSources[2].budgetId > 0 &&\r\n this.report.criteria.bvrFormatOutput.budgetSources[2].budgetPeriod.periodBegin > this.report.criteria.bvrFormatOutput.budgetSources[1].budgetPeriod.periodBegin) ||\r\n (this.report.criteria.bvrFormatOutput.budgetSources[3].budgetId > 0 &&\r\n this.report.criteria.bvrFormatOutput.budgetSources[3].budgetPeriod.periodBegin > this.report.criteria.bvrFormatOutput.budgetSources[2].budgetPeriod.periodBegin)) {\r\n this._toastr.error('Each Source Budget must be in the same Budget Period as, or an earlier Budget Period than, the prior Source Budget (1st >= 2nd >= 3rd >= 4th)');\r\n return null;\r\n }\r\n\r\n const reportRequest = new BudgetVarianceReportingRequest();\r\n const basePayload: GetEntitiesRequest = this._selectEntitiesService.getPayloadSourceEntityData(this.report.criteria.entitySelection);\r\n\r\n Object.assign(reportRequest, basePayload);\r\n reportRequest.reportTitle = this.report.variantName || this.report.displayName;\r\n reportRequest.includeDisclaimer = this.report.criteria.includeDisclaimer;\r\n reportRequest.formatOutput = _.cloneDeep(this.report.criteria.bvrFormatOutput);\r\n // Only copy the selected Budget Sources to the request.\r\n reportRequest.formatOutput.budgetSources = _.filter(this.report.criteria.bvrFormatOutput.budgetSources, (budget: BudgetVarianceBudgetSource) => {\r\n return budget.budgetId >= 0;\r\n });\r\n console.log('Requesting Budget Variance Report', reportRequest);\r\n\r\n return await this._reportingService.runBudgetVarianceReport(reportRequest);\r\n }\r\n\r\n private requestPsrReport(): Promise {\r\n if (this.report.criteria.psrFormatOutputOptions.showParcelsAddedSinceCheckbox && !this.report.criteria.psrFormatOutputOptions.showParcelsAddedSince) {\r\n this._toastr.error('Please select a date for Show Parcels Added Since');\r\n\r\n return null;\r\n }\r\n const reportRequest = new PsrRequest();\r\n const basePayload: GetEntitiesRequest = this._selectEntitiesService.getPayloadSourceEntityData(this.report.criteria.entitySelection);\r\n Object.assign(reportRequest, basePayload);\r\n reportRequest.reportTitle = this.report.variantName || this.report.displayName;\r\n reportRequest.startYearValue = this.report.criteria.taxYearBegin;\r\n reportRequest.endYearValue = this.report.criteria.taxYearEnd;\r\n reportRequest.includeEstAssessment = this.report.criteria.includeEstimatedAssessments;\r\n reportRequest.includeOnlySitesUnderAppeal = this.report.criteria.includeOnlySitesUnderAppeal;\r\n reportRequest.propertyTypes = this.report.criteria.propertyTypeIDs;\r\n reportRequest.outputFormat = this.report.criteria.outputFormat;\r\n reportRequest.includeDisclaimer = this.report.criteria.includeDisclaimer;\r\n reportRequest.psrReportType = this.report.reportTypeId === this.reportTypes.ProjectStatus ? 0 : 1;\r\n _.assign(reportRequest, this.report.criteria.psrFormatOutputOptions);\r\n\r\n return this._reportingService.runPsrReport(reportRequest, this.report.criteria.entitySelection.selectedTopLevelCompanyIDs.length > 1);\r\n }\r\n\r\n private requestMaarReport(): Promise {\r\n const reportRequest = new MaarRequest();\r\n const basePayload: GetEntitiesRequest = this._selectEntitiesService.getPayloadSourceEntityData(this.report.criteria.entitySelection);\r\n Object.assign(reportRequest, basePayload);\r\n reportRequest.reportTitle = 'MAAR Extract';\r\n reportRequest.YearValue = this.report.criteria.taxYear;\r\n // Might need to uncomment to fix a future bug?\r\n reportRequest.propertyTypes = this.report.criteria.propertyTypeIDs;\r\n // reportRequest.statusID = this.report.criteria.statusID;\r\n reportRequest.includeAllCompanies = this.report.criteria.includeAllCompanies;\r\n if(reportRequest.includeAllCompanies) {\r\n reportRequest.sourceEntityIDs = [];\r\n }\r\n\r\n return this._reportingService.runMaarReport(reportRequest);\r\n }\r\n\r\n private requestProgressStatusReport(): Promise {\r\n const reportRequest = new ProgressStatusRequest();\r\n const basePayload: GetEntitiesRequest = this._selectEntitiesService.getPayloadSourceEntityData(this.report.criteria.entitySelection);\r\n Object.assign(reportRequest, basePayload);\r\n reportRequest.reportTitle = 'Project Status Extract';\r\n reportRequest.startYearValue = this.report.criteria.taxYearBegin;\r\n reportRequest.endYearValue = this.report.criteria.taxYearEnd;\r\n reportRequest.siteStatus = this.report.criteria.siteStatus;\r\n reportRequest.propertyTypes = this.report.criteria.propertyTypeIDs;\r\n\r\n return this._reportingService.runProgressStatusExtract(reportRequest);\r\n }\r\n\r\n private requestSiteReport(): Promise {\r\n if (this.report.criteria.entitySelection.selectedTopLevelCompanyIDs.length > 1) {\r\n this._toastr.error('Select only one Top Level Company for this report');\r\n\r\n return null;\r\n }\r\n\r\n const reportRequest = new SiteRequest();\r\n const basePayload: GetEntitiesRequest = this._selectEntitiesService.getPayloadSourceEntityData(this.report.criteria.entitySelection);\r\n\r\n Object.assign(reportRequest, basePayload);\r\n\r\n reportRequest.reportTitle = this.report.variantName || this.report.displayName;\r\n reportRequest.orderBy = this.report.criteria.orderBy;\r\n reportRequest.startYearValue = this.report.criteria.taxYearBegin;\r\n reportRequest.endYearValue = this.report.criteria.taxYearEnd;\r\n reportRequest.numberOfYearsToInclude = Number(this.report.criteria.numberOfYearsToInclude);\r\n reportRequest.propertyTypes = this.report.criteria.propertyTypeIDs;\r\n reportRequest.includeDisclaimer = this.report.criteria.includeDisclaimer;\r\n reportRequest.detailReportOptions = _.merge(this.report.criteria.detailReportOptions, this.report.criteria.siteFormatOutputOptions);\r\n\r\n return this._reportingService.runSiteReport(reportRequest);\r\n }\r\n\r\n private requestUserActivity(): Promise {\r\n const reportRequest = new UserActivityRequest();\r\n const basePayload: GetEntitiesRequest = this._selectEntitiesService.getPayloadSourceEntityData(this.report.criteria.entitySelection);\r\n Object.assign(reportRequest, basePayload);\r\n reportRequest.reportTitle = 'User Activity';\r\n reportRequest.outputFormat = this.report.criteria.outputFormat;\r\n reportRequest.loginDateBegin = this.report.criteria.loginDateBegin;\r\n reportRequest.loginDateEnd = this.report.criteria.loginDateEnd;\r\n reportRequest.onlyActiveUsers = this.report.criteria.onlyActiveUsers;\r\n reportRequest.includeUsersWithoutLogin = this.report.criteria.includeUsersWithoutLogin;\r\n reportRequest.includeInternalUsers = this.report.criteria.includeInternalUsers;\r\n\r\n _.assign(reportRequest, this.report.criteria.userActivityFormatOutputOptions);\r\n\r\n return this._reportingService.runUserActivityReport(reportRequest);\t\t// this.report.variantName\r\n }\r\n\r\n private requestUserAccess(): Promise {\r\n const reportRequest = new UserAccessRequest();\r\n\r\n if(this.report.criteria.startWith === Core.UserAccessReportStartWithEnum.SingleUser) {\r\n reportRequest.selectedUserId = this.report.criteria.selectedContact.userID;\r\n } else {\r\n const basePayload: GetEntitiesRequest = this._selectEntitiesService.getPayloadSourceEntityData(this.report.criteria.entitySelection);\r\n Object.assign(reportRequest, basePayload);\r\n }\r\n\r\n reportRequest.reportTitle = 'User Access';\r\n reportRequest.outputFormat = this.report.criteria.outputFormat;\r\n reportRequest.loginDateBegin = this.report.criteria.loginDateBegin;\r\n reportRequest.loginDateEnd = this.report.criteria.loginDateEnd;\r\n reportRequest.onlyActiveUsers = this.report.criteria.onlyActiveUsers;\r\n reportRequest.includeUsersWithoutLogin = this.report.criteria.includeUsersWithoutLogin;\r\n reportRequest.includeInternalUsers = this.report.criteria.includeInternalUsers;\r\n reportRequest.userAccessReportStartWith = this.report.criteria.startWith;\r\n reportRequest.userAccessReportLimitByLoginDate = this.report.criteria.limitByLoginDate;\r\n\r\n _.assign(reportRequest, this.report.criteria.userActivityFormatOutputOptions);\r\n\r\n return this._reportingService.runUserAccessReport(reportRequest);\t\t// this.report.variantName\r\n }\r\n\r\n private requestUserCSR(): Promise {\r\n const reportRequest = new UserCSRRequest();\r\n\r\n reportRequest.selectedUserId = this.report.criteria.selectedContact.userID;\r\n reportRequest.reportTitle = 'User CSR Extract';\r\n\r\n return this._reportingService.runUserCSRExtract(reportRequest);\t\t// this.report.variantName\r\n }\r\n\r\n private get companiesSelected(): boolean {\r\n return this.report.criteria.entitySelection.selectedTopLevelCompanyIDs.length || this.report.criteria.includeAllCompanies;\r\n }\r\n\r\n private requestSupportInstanceEscalationActivityReport(): Promise {\r\n const reportRequest = new SupportInstanceEscalationActivityReportRequest();\r\n reportRequest.outputFormat = this.report.criteria.outputFormat;\r\n reportRequest.escalationDateBegin = this.report.criteria.escalationDateBegin;\r\n reportRequest.escalationDateEnd = this.report.criteria.escalationDateEnd;\r\n reportRequest.anyEscalationDates = this.report.criteria.anyEscalationDates;\r\n reportRequest.escalationGroupBy = this.report.criteria.escalationGroupBy;\r\n reportRequest.instanceIds = this.report.criteria.entitySelection.selectedSupportInstanceIds;\r\n\r\n reportRequest.contactIds = _.chain(this.report.criteria.entitySelection.selectedEntities)\r\n .filter((selectedEntity: SelectedEntity): boolean => {\r\n return selectedEntity.id === EntityTypeIds.SUPPORTUSER;\r\n })\r\n .map((entity: SelectedEntity) => entity.selectedIDs)\r\n .flatten()\r\n .value() as number[];\r\n\r\n this._productAnalyticsService.logEvent('Run Report', {\r\n reportName: 'Support Instance Escalation Activity',\r\n isSystemReport: this.isSystemReport,\r\n totalEntityFilterLevelsApplied: this.report.criteria.entitySelection.selectedEntities.length + 1\r\n });\r\n\r\n return this._reportingService.runSupportInstanceEscalationActivityReport(reportRequest);\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ReportDetail, UserActivityReportCriteria } from '../report.manager.model';\r\nimport * as _ from 'lodash';\r\nimport { ReportType } from '../report-type';\r\n\r\n@Component({\r\n selector: 'format-output-panel-user-activity',\r\n template: `\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n `\r\n})\r\nexport class FormatOutputPanelUserActivityComponent implements OnInit {\r\n @Input() report: ReportDetail;\r\n outputFormatOptions: string[];\r\n reportTypes = ReportType;\r\n\r\n ngOnInit() {\r\n this.outputFormatOptions = [ 'Summary Report (PDF)', 'Summary Report (Excel)', 'Details Report (PDF)', 'Details Report (Excel)'];\r\n this.report.criteria.outputFormat = this.report.criteria.outputFormat || 0;\r\n this.report.criteria.userActivityFormatOutputOptions = this.report.criteria.userActivityFormatOutputOptions || new UserActivityReportCriteria();\r\n }\r\n}\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport { ReportManagerService } from '../report.manager.service';\r\nimport { Subscription } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'further-limit-panel-budget-variance',\r\n template: `\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n `\r\n})\r\nexport class FurtherLimitPanelBudgetVarianceComponent implements OnInit {\r\n constructor(private reportManagerService: ReportManagerService)\r\n {\r\n }\r\n\r\n @Input() report: ReportDetail;\r\n @Input() hasRyanPrivatePermission: boolean;\r\n\r\n private _topLevelCompanyChangedSub: Subscription;\r\n\r\n ngOnInit() {\r\n if ([null, undefined].indexOf(this.report.criteria.includeDisclaimer) !== -1) {\r\n this.report.criteria.includeDisclaimer = true;\r\n }\r\n this.report.criteria.budgetPeriods = this.report.criteria.budgetPeriods || [];\r\n\r\n this._topLevelCompanyChangedSub = this.reportManagerService.topLevelCompanies$.subscribe(async topLevelCompaniesObj => {\r\n if (topLevelCompaniesObj.topLevelCompanyIds.length == 1) {\r\n // Top Level Company changed. Refresh the Budget Periods.\r\n // This will clear Budget Period selections and cascade to Format Output component.\r\n await this.reportManagerService.refreshBudgetPeriods(this.report, topLevelCompaniesObj.topLevelCompanyIds[0]);\r\n }\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this._topLevelCompanyChangedSub.unsubscribe();\r\n }\r\n\r\n get availablePeriods() {\r\n return this.reportManagerService.availableBudgetPeriods;\r\n }\r\n\r\n budgetPeriodSelectionChanged() {\r\n this.reportManagerService.refreshSelectableBudgetSources(this.report.criteria.budgetPeriods);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n

Summary Report Options

\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ReportDetail } from '../report.manager.model';\r\nimport { ReportManagerService } from '../report.manager.service';\r\nimport { BudgetVarianceBudgetSource, BudgetVarianceFormatOutputCriteria } from '../report.manager.model';\r\nimport { Subscription } from 'rxjs';\r\nimport { CompanyBudgetBasisEnum } from '../../../Budget/forecasting.budgeting.model';\r\n\r\n@Component({\r\n selector: 'format-output-panel-budget-variance',\r\n templateUrl: './format.output.panel.budget.variance.component.html'\r\n})\r\nexport class FormatOutputPanelBudgetVarianceComponent implements OnInit {\r\n constructor(private reportManagerService: ReportManagerService) {}\r\n\r\n @Input() report: ReportDetail;\r\n\r\n CompanyBudgetBasisEnum = CompanyBudgetBasisEnum;\r\n outputFormatOptions: string[] = [ 'Summary Report (PDF)', 'Summary Report (Excel)'];\r\n detailLevelOptions: string[] = ['Site', 'Parcel', 'None'];\r\n varianceDetailOptions: string[] = ['Amount', 'Percent', 'Amount and Percent'];\r\n\r\n firstBudgetSources: BudgetVarianceBudgetSource[] = [];\r\n secondBudgetSources: BudgetVarianceBudgetSource[] = [];\r\n thirdBudgetSources: BudgetVarianceBudgetSource[] = [];\r\n fourthBudgetSources: BudgetVarianceBudgetSource[] = [];\r\n\r\n private _selectedBudgetsChangedSub: Subscription;\r\n private _loading: boolean = false;\r\n\r\n private NoSelectionBudgetSource: BudgetVarianceBudgetSource = {\r\n budgetId: -1,\r\n budgetName: 'Make a selection',\r\n budgetBasis: Core.CompanyBudgetBasisEnum.AccrualAndCash,\r\n budgetPeriod: {\r\n periodBegin: null,\r\n periodEnd: null\r\n }\r\n };\r\n private filteredBudgetSources: BudgetVarianceBudgetSource[] = [];\r\n private noForecastBudgetSources: BudgetVarianceBudgetSource[] = [];\r\n\r\n\r\n\r\n ngOnInit() {\r\n // I am using a loading flag here to prevent loaded Source selections from being wiped\r\n // out by refreshBudgetSources() because the observable is firing on subscribe before\r\n // exiting this method and beforee the selectable Budget Sources have been populated.\r\n this._loading = true;\r\n this._setDefaultsBudget();\r\n\r\n this._selectedBudgetsChangedSub = this.reportManagerService.selectableBudgetsChanged$.subscribe(() => {\r\n this.refreshBudgetSources();\r\n });\r\n this._loading = false;\r\n }\r\n\r\n ngOnDestroy() {\r\n this._selectedBudgetsChangedSub.unsubscribe();\r\n }\r\n\r\n async refreshBudgetSources() : Promise {\r\n this.filteredBudgetSources = _.filter(this.reportManagerService.selectableBudgetSources, budget => {\r\n // Filter to only budgets configured with a matching Budget Basis.\r\n switch(budget.budgetBasis) {\r\n case Core.CompanyBudgetBasisEnum.AccrualAndCash:\r\n return true;\r\n case Core.CompanyBudgetBasisEnum.Accrual:\r\n return this.report.criteria.bvrFormatOutput.budgetBasis == Core.CompanyBudgetBasisEnum.Accrual;\r\n case Core.CompanyBudgetBasisEnum.Cash:\r\n return this.report.criteria.bvrFormatOutput.budgetBasis == Core.CompanyBudgetBasisEnum.Cash;\r\n }\r\n });\r\n this.noForecastBudgetSources = _.filter(this.filteredBudgetSources, (budget) => budget.budgetId > 0);\r\n\r\n // Populate the SourceBudgets arrays with appropriate selections.\r\n this.sourceBudgetChanged();\r\n }\r\n\r\n\r\n sourceBudgetChanged()\r\n {\r\n // Populate the SourceBudgets arrays with appropriate selections.\r\n let srcIndex = 0;\r\n this.firstBudgetSources = _.concat([_.cloneDeep(this.NoSelectionBudgetSource)], _.filter(this.filteredBudgetSources, (budget) => {\r\n return _.every(this.report.criteria.bvrFormatOutput.budgetSources, (sel, index) => {\r\n // Include our own selection, and any budget not selected for any other source.\r\n return index === 0 || budget.budgetId != sel.budgetId;\r\n });\r\n }));\r\n this.confirmSelection(0, this.firstBudgetSources);\r\n\r\n srcIndex++;\r\n this.secondBudgetSources = _.concat([_.cloneDeep(this.NoSelectionBudgetSource)], _.filter(this.noForecastBudgetSources, (budget) => {\r\n return _.every(this.report.criteria.bvrFormatOutput.budgetSources, (sel, index) => {\r\n // Include our own selection, and any budget not selected for any other source.\r\n return index === 1 || budget.budgetId != sel.budgetId;\r\n });\r\n }));\r\n this.confirmSelection(1, this.secondBudgetSources);\r\n\r\n srcIndex++;\r\n this.thirdBudgetSources =_.concat([_.cloneDeep(this.NoSelectionBudgetSource)], _.filter(this.noForecastBudgetSources, (budget) => {\r\n return _.every(this.report.criteria.bvrFormatOutput.budgetSources, (sel, index) => {\r\n // Include our own selection, and any budget not selected for any other source.\r\n return index === 2 || budget.budgetId != sel.budgetId;\r\n });\r\n }));\r\n this.confirmSelection(2, this.thirdBudgetSources);\r\n\r\n srcIndex++;\r\n this.fourthBudgetSources =_.concat([_.cloneDeep(this.NoSelectionBudgetSource)], _.filter(this.noForecastBudgetSources, (budget) => {\r\n return _.every(this.report.criteria.bvrFormatOutput.budgetSources, (sel, index) => {\r\n // Include our own selection, and any budget not selected for any other source.\r\n return index === 3 || budget.budgetId != sel.budgetId;\r\n });\r\n }));\r\n this.confirmSelection(3, this.fourthBudgetSources);\r\n }\r\n\r\n private _setDefaultsBudget(): void {\r\n this.report.criteria.bvrFormatOutput = this.report.criteria.bvrFormatOutput || new BudgetVarianceFormatOutputCriteria();\r\n if ( this.report.criteria.bvrFormatOutput.budgetSources )\r\n {\r\n // Prepopulate the budgetSources with NoSelection objects.\r\n for ( let i=this.report.criteria.bvrFormatOutput.budgetSources.length; i < 4; i++ )\r\n {\r\n this.report.criteria.bvrFormatOutput.budgetSources.push(_.cloneDeep(this.NoSelectionBudgetSource));\r\n }\r\n }\r\n }\r\n\r\n private confirmSelection(srcIndex: number, budgetSources: BudgetVarianceBudgetSource[])\r\n {\r\n if ( this._loading )\r\n return;\r\n\r\n const selectionAvailable = _.find(budgetSources, ['budgetId', this.report.criteria.bvrFormatOutput.budgetSources[srcIndex].budgetId]);\r\n if ( selectionAvailable )\r\n {\r\n // Save selection.\r\n this.report.criteria.bvrFormatOutput.budgetSources[srcIndex] = selectionAvailable;\r\n }\r\n else\r\n {\r\n // Clear selection.\r\n this.report.criteria.bvrFormatOutput.budgetSources[srcIndex] = _.find(budgetSources, ['budgetId', -1]);\r\n }\r\n }\r\n}","
\r\n

{{ report.displayName }}\r\n - {{ report.variantName }}\r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

Further Limit the Contents of your Report

\r\n

Limit the Report Content

\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

Format the Report Output

\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n Request Report\r\n
\r\n","
\r\n \r\n
\r\n
\r\n
\r\n

Roles

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Role Description\r\n {{entityType}}\r\n
{{ role.roleDesc || '' }}\r\n \r\n
\r\n
\r\n
\r\n","import { ElementRef, QueryList, ViewChildren } from '@angular/core';\r\nimport { Component, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ContactRoleService } from './contact.role.service';\r\n@Component({\r\n selector: 'roles-list',\r\n templateUrl: './roles.list.component.html',\r\n styleUrls: ['./roles.list.component.scss']\r\n})\r\nexport class RolesListComponent implements OnInit {\r\n constructor(private readonly _roleService: ContactRoleService) { }\r\n\r\n @ViewChildren('formRow') rows: QueryList;\r\n readonly entityTypes: string[] = ['company', 'site', 'parcel', 'state', 'assessor', 'collector'];\r\n dataLoading: boolean = false;\r\n roles: Weissman.Model.Contacts.ContactRole[];\r\n\r\n async ngOnInit() {\r\n this.dataLoading = true;\r\n const roles = await this._roleService.get();\r\n this.roles = _.orderBy(roles, ['new', 'roleDesc'], ['desc', 'asc']);\r\n this.dataLoading = false;\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const SMART_SEARCH_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'smartSearch.export',\r\n tooltipText: 'Export the search in Excel format'\r\n },\r\n {\r\n helpContentId: 'smartSearch.results',\r\n tooltipText: 'SMART search results'\r\n },\r\n {\r\n helpContentId: 'smartSearch.save-header',\r\n tooltipText: 'Save Search'\r\n },\r\n {\r\n helpContentId: 'smartSearch.new-category',\r\n tooltipText: 'Finish or cancel adding a new category to save'\r\n },\r\n {\r\n helpContentId: 'smartSearch.show-criteria',\r\n tooltipText: 'Show filter criteria'\r\n },\r\n {\r\n helpContentId: 'smartSearch.clear-criteria',\r\n tooltipText: 'Reset'\r\n },\r\n {\r\n helpContentId: 'smartSearch.stop-sharing',\r\n tooltipText: 'Stop sharing'\r\n },\r\n {\r\n helpContentId: 'smartSearch.all-instances-selected',\r\n tooltipText: 'Please select a single instance to save search'\r\n }\r\n];\r\n","import { Injectable } from '@angular/core';\r\nimport { SearchFilters } from '../../../Search/Advanced/advancedSearchPersistence.service';\r\n\r\n// import methods from fp library to utilize flow transducer\r\nimport map from 'lodash/fp/map';\r\nimport reject from 'lodash/fp/reject';\r\nimport * as _ from 'lodash';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class ColumnFilterService {\r\n\r\n prepareFilters(filters: SearchFilters[]) {\r\n return _.flow([\r\n map(x => ({ ...x, ...{ columnId: x.columnId || x.id || x.advancedSearchFieldID }})),\r\n reject(x => x.columnId === 9002 || x.columnId === 1430),\r\n map(x => {\r\n const filter = { columnId: x.columnId, or: x.or };\r\n filter.or = _.flow([\r\n reject(or => or.operator.name !== 'blank' && or.operator.name !== 'notBlank' && or.operator.name !== 'isNA' && (!_.isDate(or.value) && (!or.value || !or.value.trim()))),\r\n map(or => ({ ...or, ...{ operator: or.operator.name }}))\r\n ])(filter.or);\r\n\r\n return filter;\r\n }),\r\n reject(x => !x.or.length)\r\n ])(filters);\r\n }\r\n}\r\n","\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n The maximum length for the name is 50 characters\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { AdvancedSearchCategoryTypes, DefaultDisplayTypes } from '../../../constants.new';\r\nimport { SearchPageType, UserSaveService } from '../../../Navigation/User-Save/userSave.service';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport {\r\n AdvancedSearchCriteria,\r\n AdvancedSearchPersistenceService,\r\n SavedSearchModel\r\n} from '../advancedSearchPersistence.service';\r\nimport { SmartSearchService } from '../smartSearch.service';\r\n\r\nexport interface SaveSearchModalParams {\r\n searchCriteria: AdvancedSearchCriteria;\r\n searchType: number;\r\n hasEditPermission: boolean;\r\n}\r\n\r\nexport interface SaveSearchModalResult {\r\n search: SavedSearchModel;\r\n type: number;\r\n}\r\n\r\n@Component({\r\n selector: 'save-search-modal',\r\n templateUrl: './saveSearchModal.component.html',\r\n styleUrls: ['./saveSearchModal.component.scss']\r\n})\r\nexport class SaveSearchModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _userSaveService: UserSaveService\r\n ) {}\r\n\r\n @ViewChild('searchNameRef', { static: true }) searchNameRef: ElementRef;\r\n @ViewChild('newCategoryNameRef', { static: true }) newCategoryNameRef: ElementRef;\r\n\r\n params: SaveSearchModalParams;\r\n result: SaveSearchModalResult;\r\n\r\n isBusy: boolean;\r\n categoriesLoading: boolean = true;\r\n saveHelpContentId: string = 'app.save';\r\n\r\n searchFormGroup: UntypedFormGroup;\r\n hasEditPermission: boolean;\r\n defaultDisplayTypes = DefaultDisplayTypes;\r\n\r\n categoryTypes = AdvancedSearchCategoryTypes;\r\n categoryEntered: boolean = true;\r\n enteringCategory: boolean = false;\r\n addingNewCategory: boolean = false;\r\n newCategoryName: UntypedFormControl = new UntypedFormControl('');\r\n\r\n private _searchCategories: any[];\r\n private _noCategory = { categoryName: 'No Category', categoryId: null, categoryType: 1 };\r\n\r\n get searchCategoryOptions(): any[] {\r\n const form = this.searchFormGroup.value;\r\n return this._searchCategories ? this._searchCategories.filter(x => x.categoryType === form.type || !x.categoryId && form.type === AdvancedSearchCategoryTypes.CUSTOM) : [];\r\n }\r\n\r\n get searchName(): UntypedFormControl {\r\n return this.searchFormGroup.get('searchName') as UntypedFormControl;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this.hasEditPermission = this.params.hasEditPermission;\r\n\r\n this.searchFormGroup = this._fb.group({\r\n type: [this.params.searchType || AdvancedSearchCategoryTypes.CUSTOM],\r\n defaultDisplay: [this.params.searchCriteria.defaultDisplay || DefaultDisplayTypes.CRITERIA],\r\n categoryId: [this.params.searchCriteria.categoryId || null],\r\n searchName: [this.params.searchCriteria.searchName || null, { validators: [Validators.required, Validators.maxLength(50) ] }],\r\n }, {\r\n validator: (formGroup: UntypedFormGroup) => {\r\n this.saveHelpContentId = (this.addingNewCategory) ? 'smartSearch.new-category' : 'app.save';\r\n return !this.addingNewCategory && formGroup.get('categoryId').valid && formGroup.get('searchName').valid;\r\n }\r\n });\r\n\r\n const searchCategories = await this._smartSearchService.getSearchCategories();\r\n this._searchCategories = _.sortBy(searchCategories, 'categoryName');\r\n if (!this._searchCategories.find(x => x.categoryName === 'No Category')) {\r\n this._searchCategories.unshift(this._noCategory);\r\n }\r\n this.setCustomCategory();\r\n this.categoriesLoading = false;\r\n\r\n this.searchNameRef.nativeElement.focus();\r\n }\r\n\r\n toggled(): void {\r\n this.addingNewCategory = !this.addingNewCategory;\r\n if (this.addingNewCategory) {\r\n this.saveHelpContentId = 'smartSearch.new-category';\r\n this.searchFormGroup.disable();\r\n this.newCategoryNameRef.nativeElement.focus();\r\n } else {\r\n this.saveHelpContentId = 'app.save';\r\n this.searchFormGroup.enable();\r\n this.newCategoryName.setValue(null);\r\n }\r\n }\r\n\r\n setCustomCategory(): void {\r\n this.searchFormGroup.patchValue({ categoryId: null });\r\n }\r\n\r\n findSystemCategory(): void {\r\n if (!this.searchFormGroup.value.categoryId && (this._searchCategories && this._searchCategories.length)) {\r\n this.searchFormGroup.patchValue({ categoryId: this._searchCategories.find(x => x.categoryType === AdvancedSearchCategoryTypes.SYSTEM).categoryId });\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n createNewCategory(): void {\r\n if (!this.newCategoryName.value) {\r\n return;\r\n }\r\n\r\n this._searchCategories.push({\r\n categoryName: this.newCategoryName.value,\r\n categoryType: this.searchFormGroup.value.type,\r\n categoryId: 'new'\r\n });\r\n this._searchCategories = _.sortBy(this._searchCategories, 'categoryName');\r\n\r\n this.searchFormGroup.patchValue({ categoryId: 'new' });\r\n this.addingNewCategory = false;\r\n this.searchFormGroup.enable();\r\n\r\n this.searchNameRef.nativeElement.focus();\r\n }\r\n\r\n async saveSearch(): Promise {\r\n this.isBusy = true;\r\n const form = this.searchFormGroup.value;\r\n if (form.categoryId === 'new') {\r\n const category = this._searchCategories.find(x => x.categoryId === 'new');\r\n\r\n try {\r\n const categoryToSubmit = { ...category };\r\n delete categoryToSubmit.categoryId;\r\n\r\n const result = await this._smartSearchService.createSearchCategory(categoryToSubmit);\r\n this.searchFormGroup.patchValue({ categoryId: result.categoryId });\r\n try {\r\n const updated = await this._createOrUpdate();\r\n this._productAnalyticsService.logEvent('click-SMART-save-search', {\r\n smartSavedSearchType: updated.isSystemSearch ? 'System' : 'User',\r\n smartSavedSearchDisplay: updated.defaultDisplay === DefaultDisplayTypes.CRITERIA ? 'Filter' : 'Detailed',\r\n smartSavedSearchCategory: updated.categoryName ? updated.categoryName : 'No Category'\r\n });\r\n this._broadcastAndClose(updated);\r\n } catch (e1) {\r\n this._errorToast(e1, 'Search name/category already exists');\r\n }\r\n } catch (e2) {\r\n this._errorToast(e2, 'Category already exists.');\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n } else {\r\n try {\r\n const updated = await this._createOrUpdate();\r\n this._productAnalyticsService.logEvent('click-SMART-save-search', {\r\n smartSavedSearchType: updated.isSystemSearch ? 'System' : 'User',\r\n smartSavedSearchDisplay: updated.defaultDisplay === DefaultDisplayTypes.CRITERIA ? 'Filter' : 'Detailed',\r\n smartSavedSearchCategory: updated.categoryName ? updated.categoryName : 'No Category'\r\n });\r\n this._broadcastAndClose(updated);\r\n } catch (e1) {\r\n this._errorToast(e1, 'Search name/category already exists');\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n }\r\n\r\n private _broadcastAndClose(savedSearch: any): void {\r\n this._advancedSearchPersistenceService.reloadingSearch = true;\r\n const form = this.searchFormGroup.value;\r\n this.result = {\r\n search: savedSearch,\r\n type: form.type\r\n };\r\n this._userSaveService.setDirty(SearchPageType.Smart);\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _errorToast(error: any, msg: string): void {\r\n if (error.status === 409) {\r\n this._toastr.error('Error!', msg);\r\n } else {\r\n this._toastr.error('Error!', 'Server Error');\r\n }\r\n }\r\n\r\n private async _createOrUpdate(): Promise {\r\n const form = this.searchFormGroup.value;\r\n const search = { searchCriteria: { ...this.params.searchCriteria }, ...form } as SavedSearchModel;\r\n delete search.type;\r\n // TODO searchId doesn't exist on this model. Determine if there is a reason this code was here in the old JS code.\r\n // it looks as though it was used to update the values if the same save name was used, although both the old JS code\r\n // and the new code display an error toast in that case. Maybe this condition can be deleted\r\n if (search.searchId) {\r\n if (form.type === AdvancedSearchCategoryTypes.CUSTOM) {\r\n return await this._smartSearchService.saveCustomSearch(search);\r\n } else {\r\n try {\r\n await this._messageModalService.confirm('Confirm Overwriting System Search', 'Confirm Overwrite');\r\n } catch {\r\n return Promise.reject();\r\n }\r\n return await this._smartSearchService.saveSystemSearch(search);\r\n }\r\n } else {\r\n if (form.type === AdvancedSearchCategoryTypes.CUSTOM) {\r\n return await this._smartSearchService.createCustomSearch(search);\r\n } else {\r\n return await this._smartSearchService.createSystemSearch(search);\r\n }\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

Filter

\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n

\r\n Add Search Filters...\r\n

\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { ProductAnalyticsService } from '../../../../Common/Amplitude/productAnalytics.service';\r\nimport { RestrictService, Roles } from '../../../../Common/Permissions/restrict.service';\r\nimport { SmartSearchService } from '../../smartSearch.service';\r\nimport { SearchOperatorsService } from '../../../searchOperators.service';\r\nimport { AdvancedSearchCriteria, AdvancedSearchPersistenceService, AdvancedSearchRouteParams } from '../../advancedSearchPersistence.service';\r\nimport { AdvancedSearchRepository } from '../../../../Core-Repositories';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'advanced-filter-list',\r\n templateUrl: './filterList.component.html',\r\n styleUrls: ['../../../../../styles/utilities/helpers.scss', './filterList.component.scss']\r\n})\r\nexport class FilterListComponent implements OnInit {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _searchOperators: SearchOperatorsService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _advancedSearchRepository: AdvancedSearchRepository,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n @Input() routeParams: AdvancedSearchRouteParams;\r\n\r\n @Input()\r\n set searchCriteria(searchCriteria: AdvancedSearchCriteria) {\r\n this._searchCriteria = { ...searchCriteria };\r\n\r\n this.outputColumns = this._searchCriteria.outputColumns;\r\n this.searchFilters = this._searchCriteria.filters;\r\n this.excludeInactive = this._searchCriteria.excludeInactive;\r\n this.showOrs = this._searchCriteria.showOrs;\r\n this.frequentlyUsed = this._searchCriteria.frequentlyUsed;\r\n }\r\n\r\n @Output() filtersChanged: EventEmitter = new EventEmitter();\r\n\r\n outputColumns: any[] = [];\r\n searchFilters: any[] = [];\r\n excludeInactive: boolean;\r\n showOrs: boolean;\r\n frequentlyUsed: boolean;\r\n\r\n loadSaveSettings: boolean;\r\n hasRyanPrivatePermission: boolean;\r\n\r\n private _searchCriteria: AdvancedSearchCriteria;\r\n\r\n get areNoOrs(): boolean {\r\n return this.searchFilters\r\n .map(x => x.or)\r\n .every(orArr => orArr.length < 2);\r\n }\r\n\r\n ngOnInit(): void {\r\n this.hasRyanPrivatePermission = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT) ||\r\n this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n\r\n // Dima: this call is to ensure that the user has permissions to execute the smart search.\r\n // See issue [WK-3479 In SMART, 'No permission to view this page' warning isn't displayed in the 1st go] for additional details\r\n if (this.routeParams.searchId !== 0) {\r\n this._advancedSearchRepository.getOneSearch(Number(this.routeParams.searchId), Number(this.routeParams.searchType));\r\n }\r\n }\r\n\r\n addFilters(columns: any): void {\r\n columns.forEach(column => {\r\n const filter = { ...column };\r\n\r\n filter.operators = this._searchOperators.getOperatorArray(filter.operators);\r\n\r\n //Temporary workaround. If the Company or Company Name fields are used, we should default to Equals instead\r\n //This is different than every other column. It's so we can use the company picker\r\n if (column.columnId === 101 || column.columnId === 109) {\r\n filter.or = [this._searchOperators.getCompanyOr(filter.operators)];\r\n } else {\r\n filter.or = filter.operators.length ? [this._searchOperators.getOr(filter.operators)] : [];\r\n }\r\n\r\n this.searchFilters.push(filter);\r\n\r\n const notAlreadyAdded = !this.outputColumns.some(x => x.columnId === column.columnId);\r\n\r\n if (notAlreadyAdded) {\r\n this.outputColumns.push({ ...column });\r\n }\r\n });\r\n\r\n this.disableColumns();\r\n this.updateCriteria();\r\n }\r\n\r\n disableColumns(): void {\r\n this._smartSearchService.disableColumns(_.union(this.searchFilters, this.outputColumns));\r\n }\r\n\r\n updateColumnFilters(filters: any[]): void {\r\n this.searchFilters = filters;\r\n this.updateCriteria();\r\n }\r\n\r\n toggleOrs(): void {\r\n this.updateCriteria();\r\n this._productAnalyticsService.logEvent('click-or-toggle', { smartOrToggle: this.showOrs ? 'on' : 'off' });\r\n }\r\n\r\n updateCriteria(): void {\r\n this._searchCriteria.outputColumns = this.outputColumns;\r\n this._searchCriteria.filters = this.searchFilters;\r\n this._searchCriteria.excludeInactive = this.excludeInactive;\r\n this._searchCriteria.showOrs = this.showOrs;\r\n this._searchCriteria.frequentlyUsed = this.frequentlyUsed;\r\n\r\n this._advancedSearchPersistenceService.setSearchCriteria(this._searchCriteria);\r\n this.filtersChanged.emit();\r\n }\r\n\r\n async persistSetting(analyticsEvent?: string): Promise {\r\n this.updateCriteria();\r\n this.loadSaveSettings = true;\r\n await this._smartSearchService.persistSetting(this);\r\n this.loadSaveSettings = false;\r\n if (analyticsEvent) {\r\n this._productAnalyticsService.logEvent(analyticsEvent);\r\n }\r\n }\r\n}\r\n","import { Directive, ElementRef, EventEmitter, HostListener, Input, OnDestroy, OnInit, Output, Renderer2 } from '@angular/core';\r\nimport { DragAndDropListService } from './dragAndDropList.service';\r\nimport { Observable, Subscription } from 'rxjs';\r\nimport { TimerService } from '../../Utilities/timer.service';\r\n\r\n@Directive({\r\n selector: '[ws-dnd-draggable]'\r\n})\r\nexport class DragAndDropDraggableDirective implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _elementRef: ElementRef,\r\n private readonly _renderer: Renderer2,\r\n private readonly _dndState: DragAndDropListService,\r\n private readonly _timer: TimerService\r\n ) {}\r\n\r\n @Input() dndDraggable;\r\n @Input() dndEffectAllowed;\r\n @Input() dndType;\r\n @Input() dndDisableIf: Observable;\r\n\r\n @Output() dndDragstart: EventEmitter = new EventEmitter();\r\n @Output() dndMoved: EventEmitter = new EventEmitter();\r\n @Output() dndCopied: EventEmitter = new EventEmitter();\r\n @Output() dndLinked: EventEmitter = new EventEmitter();\r\n @Output() dndCanceled: EventEmitter = new EventEmitter();\r\n @Output() dndDragend: EventEmitter = new EventEmitter();\r\n @Output() dndSelected: EventEmitter = new EventEmitter();\r\n @Output() dndCallback: EventEmitter = new EventEmitter();\r\n\r\n private _disableIfSub: Subscription;\r\n\r\n @HostListener('dragstart', ['$event'])\r\n dragStart(event) {\r\n event = event.originalEvent || event;\r\n\r\n // Check whether the element is draggable, since dragstart might be triggered on a child.\r\n if (this._elementRef.nativeElement['draggable'] == 'false') return true;\r\n\r\n // Initialize global state.\r\n this._dndState.isDragging = true;\r\n this._dndState.itemType = this.dndType && this.dndType.toLowerCase();\r\n\r\n // Set the allowed drop effects. See below for special IE handling.\r\n this._dndState.dropEffect = 'none';\r\n this._dndState.effectAllowed = this.dndEffectAllowed || this._dndState.ALL_EFFECTS[0];\r\n event.dataTransfer.effectAllowed = this._dndState.effectAllowed;\r\n\r\n // Internet Explorer and Microsoft Edge don't support custom mime types\r\n const item = this.dndDraggable;\r\n const mimeType = this._dndState.MIME_TYPE + (this._dndState.itemType ? (`-${ this._dndState.itemType}`) : '');\r\n try {\r\n event.dataTransfer.setData(mimeType, JSON.stringify(item));\r\n } catch (e) {\r\n // Setting a custom MIME type did not work, we are probably in IE or Edge.\r\n const data = JSON.stringify({ item: item, type: this._dndState.itemType });\r\n try {\r\n event.dataTransfer.setData(this._dndState.EDGE_MIME_TYPE, data);\r\n } catch (error) {\r\n // We are in Internet Explorer and can only use the Text MIME type. Also note that IE\r\n // does not allow changing the cursor in the dragover event, therefore we have to choose\r\n // the one we want to display now by setting effectAllowed.\r\n let effectsAllowed;\r\n if (this._dndState.effectAllowed == 'all') {\r\n effectsAllowed = this._dndState.ALL_EFFECTS;\r\n } else {\r\n effectsAllowed = this._dndState.ALL_EFFECTS.filter((effect) => {\r\n return this._dndState.effectAllowed.toLowerCase().indexOf(effect) != -1;\r\n });\r\n }\r\n event.dataTransfer.effectAllowed = effectsAllowed[0];\r\n event.dataTransfer.setData(this._dndState.MSIE_MIME_TYPE, data);\r\n }\r\n }\r\n\r\n // Add CSS classes. See documentation above.\r\n this._renderer.addClass(this._elementRef.nativeElement, 'dndDragging');\r\n this._timer.setTimeout(() => { this._renderer.addClass(this._elementRef.nativeElement, 'dndDraggingSource'); }, 0);\r\n this._renderer.removeClass(this._elementRef.nativeElement, 'ws-cursor-grab');\r\n this._renderer.addClass(this._elementRef.nativeElement, 'ws-cursor-grabbing');\r\n\r\n // Try setting a proper drag image if triggered on a dnd-handle (won't work in IE).\r\n if (event._dndHandle && event.dataTransfer.setDragImage) {\r\n event.dataTransfer.setDragImage(this._elementRef.nativeElement, 0, 0);\r\n }\r\n\r\n // Invoke dragstart callback and prepare extra callback for dropzone.\r\n this.dndDragstart.emit(event);\r\n if (this.dndCallback) {\r\n this._dndState.callback = (params) => { this.dndCallback.emit(params || {}); };\r\n }\r\n\r\n event.stopPropagation();\r\n }\r\n\r\n /**\r\n * The dragend event is triggered when the element was dropped or when the drag\r\n * operation was aborted (e.g. hit escape button). Depending on the executed action\r\n * we will invoke the callbacks specified with the dnd-moved or dnd-copied attribute.\r\n */\r\n @HostListener('dragend', ['$event'])\r\n dragEnd(event) {\r\n event = event.originalEvent || event;\r\n\r\n // Invoke callbacks. Usually we would use event.dataTransfer.dropEffect to determine\r\n // the used effect, but Chrome has not implemented that field correctly. On Windows\r\n // it always sets it to 'none', while Chrome on Linux sometimes sets it to something\r\n // else when it's supposed to send 'none' (drag operation aborted).\r\n const dropEffect = this._dndState.dropEffect;\r\n const cb = {copy: 'dndCopied', link: 'dndLinked', move: 'dndMoved', none: 'dndCanceled'};\r\n this[cb[dropEffect]].emit(event);\r\n this.dndDragend.emit({event: event, dropEffect: dropEffect});\r\n\r\n // Clean up\r\n this._dndState.isDragging = false;\r\n this._dndState.callback = undefined;\r\n this._renderer.removeClass(this._elementRef.nativeElement, 'dndDragging');\r\n this._renderer.removeClass(this._elementRef.nativeElement, 'dndDraggingSource');\r\n this._renderer.removeClass(this._elementRef.nativeElement, 'ws-cursor-grabbing');\r\n this._renderer.addClass(this._elementRef.nativeElement, 'ws-cursor-grab');\r\n event.stopPropagation();\r\n\r\n // In IE9 it is possible that the timeout from dragstart triggers after the dragend handler.\r\n this._timer.setTimeout(() => { this._renderer.removeClass(this._elementRef.nativeElement, 'dndDraggingSource'); }, 0);\r\n }\r\n\r\n /**\r\n * When the element is clicked we invoke the callback function\r\n * specified with the dnd-selected attribute.\r\n */\r\n @HostListener('click', ['$event'])\r\n click(event) {\r\n if (!this.dndSelected) return;\r\n\r\n event = event.originalEvent || event;\r\n\r\n this.dndSelected.emit(event);\r\n\r\n // Prevent triggering dndSelected in parent elements.\r\n event.stopPropagation();\r\n }\r\n\r\n ngOnInit(): void {\r\n this._setDraggableAttr();\r\n\r\n if (this.dndDisableIf) {\r\n this._disableIfSub = this.dndDisableIf.subscribe(disabled => {\r\n this._renderer.setAttribute(this._elementRef.nativeElement, 'draggable', `${disabled}`);\r\n });\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n if (this._disableIfSub) {\r\n this._disableIfSub.unsubscribe();\r\n }\r\n }\r\n\r\n private _setDraggableAttr(): void {\r\n this._renderer.setAttribute(this._elementRef.nativeElement, 'draggable', 'true');\r\n this._renderer.addClass(this._elementRef.nativeElement, 'ws-cursor-grab');\r\n }\r\n}\r\n\r\n@Directive({\r\n selector: '[ws-dnd-list]'\r\n})\r\nexport class DragAndDropListDirective implements OnInit {\r\n constructor(\r\n private readonly _elementRef: ElementRef,\r\n private readonly _renderer: Renderer2,\r\n private readonly _dndState: DragAndDropListService\r\n ) {}\r\n\r\n @Input() dndList: any[];\r\n @Input() dndAllowedTypes: string[];\r\n @Input() dndEffectAllowed: string;\r\n @Input() dndDisableIf: Observable;\r\n @Input() dndHorizontalList: boolean;\r\n @Input() dndExternalSources;\r\n @Input() dndListItemIdGetter: (value: any) => string;\r\n\r\n // Callbacks\r\n @Input() dndListChange: EventEmitter = new EventEmitter();\r\n @Input() dndDragover: any;\r\n @Input() dndDrop: any;\r\n @Input() dndInserted: any;\r\n\r\n private _placeholder;\r\n private _listSettings;\r\n private _placeholderNode;\r\n private _listNode;\r\n private _hoverCount: number = 0;\r\n\r\n /**\r\n * The dragenter event is fired when a dragged element or text selection enters a valid drop\r\n * target. According to the spec, we either need to have a dropzone attribute or listen on\r\n * dragenter events and call preventDefault(). It should be noted though that no browser seems\r\n * to enforce this behaviour.\r\n */\r\n @HostListener('dragenter', ['$event'])\r\n dragenter(event) {\r\n event = event.originalEvent || event;\r\n this._hoverCount++;\r\n\r\n // Calculate list properties, so that we don't have to repeat this on every dragover event.\r\n const types = this.dndAllowedTypes;\r\n this._listSettings = {\r\n allowedTypes: Array.isArray(types) && types.join('|').toLowerCase().split('|'),\r\n disabled: this.dndDisableIf,\r\n externalSources: this.dndExternalSources,\r\n horizontal: this.dndHorizontalList\r\n };\r\n\r\n const mimeType = this._getMimeType(event.dataTransfer.types);\r\n if (!mimeType || !this._isDropAllowed(this._getItemType(mimeType))) return true;\r\n event.preventDefault();\r\n }\r\n\r\n /**\r\n * The dragover event is triggered \"every few hundred milliseconds\" while an element\r\n * is being dragged over our list, or over an child element.\r\n */\r\n @HostListener('dragover', ['$event'])\r\n dragover(event) {\r\n event = event.originalEvent || event;\r\n\r\n // Check whether the drop is allowed and determine mime type.\r\n const mimeType = this._getMimeType(event.dataTransfer.types);\r\n const itemType = this._getItemType(mimeType);\r\n if (!mimeType || !this._isDropAllowed(itemType)) return true;\r\n\r\n // Make sure the placeholder is shown, which is especially important if the list is empty.\r\n if (this._placeholderNode.parentNode != this._listNode) {\r\n this._elementRef.nativeElement.append(this._placeholder);\r\n }\r\n\r\n if (event.target != this._listNode) {\r\n // Try to find the node direct directly below the list node.\r\n let listItemNode = event.target;\r\n while (listItemNode.parentNode != this._listNode && listItemNode.parentNode) {\r\n listItemNode = listItemNode.parentNode;\r\n }\r\n\r\n if (listItemNode.parentNode == this._listNode && listItemNode != this._placeholderNode) {\r\n // If the mouse pointer is in the upper half of the list item element,\r\n // we position the placeholder before the list item, otherwise after it.\r\n const rect = listItemNode.getBoundingClientRect();\r\n let isFirstHalf;\r\n if (this._listSettings.horizontal) {\r\n isFirstHalf = event.clientX < rect.left + rect.width / 2;\r\n } else {\r\n isFirstHalf = event.clientY < rect.top + rect.height / 2;\r\n }\r\n this._listNode.insertBefore(this._placeholderNode,\r\n isFirstHalf ? listItemNode : listItemNode.nextSibling);\r\n }\r\n }\r\n\r\n // In IE we set a fake effectAllowed in dragstart to get the correct cursor, we therefore\r\n // ignore the effectAllowed passed in dataTransfer. We must also not access dataTransfer for\r\n // drops from external sources, as that throws an exception.\r\n const ignoreDataTransfer = mimeType == this._dndState.MSIE_MIME_TYPE;\r\n const dropEffect = this._getDropEffect(event, ignoreDataTransfer);\r\n if (dropEffect == 'none') return this._stopDragover();\r\n\r\n // At this point we invoke the callback, which still can disallow the drop.\r\n // We can't do this earlier because we want to pass the index of the placeholder.\r\n if (this.dndDragover && !this._invokeCallback(this.dndDragover, event, dropEffect, itemType)) {\r\n return this._stopDragover();\r\n }\r\n\r\n // Set dropEffect to modify the cursor shown by the browser, unless we're in IE, where this\r\n // is not supported. This must be done after preventDefault in Firefox.\r\n event.preventDefault();\r\n if (!ignoreDataTransfer) {\r\n event.dataTransfer.dropEffect = dropEffect;\r\n }\r\n\r\n this._renderer.addClass(this._elementRef.nativeElement, 'dndDragover');\r\n event.stopPropagation();\r\n return false;\r\n }\r\n\r\n /**\r\n * When the element is dropped, we use the position of the placeholder element as the\r\n * position where we insert the transferred data. This assumes that the list has exactly\r\n * one child element per array element.\r\n */\r\n @HostListener('drop', ['$event'])\r\n drop(event) {\r\n event = event.originalEvent || event;\r\n\r\n // Check whether the drop is allowed and determine mime type.\r\n const mimeType = this._getMimeType(event.dataTransfer.types);\r\n let itemType = this._getItemType(mimeType);\r\n if (!mimeType || !this._isDropAllowed(itemType)) return true;\r\n\r\n // The default behavior in Firefox is to interpret the dropped element as URL and\r\n // forward to it. We want to prevent that even if our drop is aborted.\r\n event.preventDefault();\r\n\r\n // Unserialize the data that was serialized in dragstart.\r\n let data;\r\n const index = this._getPlaceholderIndex();\r\n try {\r\n const droppedItem = JSON.parse(event.dataTransfer.getData(mimeType));\r\n data = this.dndList.find((x, i) => this.dndListItemIdGetter(x) === this.dndListItemIdGetter(droppedItem));\r\n if (!data) {\r\n this._stopDragover();\r\n }\r\n } catch(e) {\r\n return this._stopDragover();\r\n }\r\n\r\n // Drops with invalid types from external sources might not have been filtered out yet.\r\n if (mimeType == this._dndState.MSIE_MIME_TYPE || mimeType == this._dndState.EDGE_MIME_TYPE) {\r\n itemType = data.type || undefined;\r\n data = data.item;\r\n if (!this._isDropAllowed(itemType)) return this._stopDragover();\r\n }\r\n\r\n // Special handling for internal IE drops, see dragover handler.\r\n const ignoreDataTransfer = mimeType == this._dndState.MSIE_MIME_TYPE;\r\n const dropEffect = this._getDropEffect(event, ignoreDataTransfer);\r\n if (dropEffect == 'none') return this._stopDragover();\r\n\r\n // Invoke the callback, which can transform the transferredObject and even abort the drop.\r\n if (this.dndDrop) {\r\n data = this._invokeCallback(this.dndDrop, event, dropEffect, itemType, index, data);\r\n if (!data) return this._stopDragover();\r\n }\r\n\r\n // The drop is definitely going to happen now, store the dropEffect.\r\n this._dndState.dropEffect = dropEffect;\r\n if (!ignoreDataTransfer) {\r\n event.dataTransfer.dropEffect = dropEffect;\r\n }\r\n\r\n // Insert the object into the array, unless dnd-drop took care of that (returned true).\r\n if (data !== true) {\r\n switch (dropEffect) {\r\n case 'move':\r\n this.dndList.splice(index, 0, data);\r\n const startIndex = this.dndList.findIndex((x, i) => i !== index && this.dndListItemIdGetter(x) === this.dndListItemIdGetter(data));\r\n this.dndList.splice(startIndex, 1);\r\n break;\r\n case 'copy':\r\n this.dndList.splice(index, 0, data);\r\n break;\r\n case 'link':\r\n\r\n }\r\n }\r\n this.dndList = [...this.dndList]; // Since we mutated we need to copy the array to trigger change detection\r\n this.dndListChange.emit(this.dndList);\r\n this._invokeCallback(this.dndInserted, event, dropEffect, itemType, index, data);\r\n\r\n // Clean up\r\n this._stopDragover();\r\n event.stopPropagation();\r\n return false;\r\n }\r\n\r\n /**\r\n * We have to remove the placeholder when the element is no longer dragged over our list. The\r\n * problem is that the dragleave event is not only fired when the element leaves our list,\r\n * but also when it leaves a child element. Therefore, we determine whether the mouse cursor\r\n * is still pointing to an element inside the list or not.\r\n */\r\n @HostListener('dragleave', ['$event'])\r\n dragleave(event) {\r\n event = event.originalEvent || event;\r\n this._hoverCount--;\r\n\r\n const newTarget = document.elementFromPoint(event.clientX, event.clientY);\r\n if (this._listNode && this._listNode.contains(newTarget) && !event._dndPhShown) {\r\n // Signalize to potential parent lists that a placeholder is already shown.\r\n event._dndPhShown = true;\r\n }\r\n\r\n if (this._hoverCount === 0) {\r\n this._stopDragover();\r\n }\r\n }\r\n\r\n ngOnInit(): void {\r\n this._placeholder = this._getPlaceholderElement();\r\n this._placeholder.remove();\r\n\r\n this._placeholderNode = this._placeholder;\r\n this._listNode = this._elementRef.nativeElement;\r\n this._listSettings = {};\r\n }\r\n\r\n /**\r\n * Given the types array from the DataTransfer object, returns the first valid mime type.\r\n * A type is valid if it starts with MIME_TYPE, or it equals MSIE_MIME_TYPE or EDGE_MIME_TYPE.\r\n */\r\n private _getMimeType(types) {\r\n if (!types) return this._dndState.MSIE_MIME_TYPE; // IE 9 workaround.\r\n for (let i = 0; i < types.length; i++) {\r\n if (types[i] == this._dndState.MSIE_MIME_TYPE || types[i] == this._dndState.EDGE_MIME_TYPE ||\r\n types[i].substr(0, this._dndState.MIME_TYPE.length) == this._dndState.MIME_TYPE) {\r\n return types[i];\r\n }\r\n }\r\n return null;\r\n }\r\n\r\n /**\r\n * Determines the type of the item from the dndState, or from the mime type for items from\r\n * external sources. Returns undefined if no item type was set and null if the item type could\r\n * not be determined.\r\n */\r\n private _getItemType(mimeType) {\r\n if (this._dndState.isDragging) return this._dndState.itemType || undefined;\r\n if (mimeType == this._dndState.MSIE_MIME_TYPE || mimeType == this._dndState.EDGE_MIME_TYPE) return null;\r\n return (mimeType && mimeType.substr(this._dndState.MIME_TYPE.length + 1)) || undefined;\r\n }\r\n\r\n /**\r\n * Checks various conditions that must be fulfilled for a drop to be allowed, including the\r\n * dnd-allowed-types attribute. If the item Type is unknown (null), the drop will be allowed.\r\n */\r\n private _isDropAllowed(itemType) {\r\n if (this._listSettings.disabled) return false;\r\n if (!this._listSettings.externalSources && !this._dndState.isDragging) return false;\r\n if (!this._listSettings.allowedTypes || itemType === null) return true;\r\n return itemType && this._listSettings.allowedTypes.indexOf(itemType) != -1;\r\n }\r\n\r\n /**\r\n * Determines which drop effect to use for the given event. In Internet Explorer we have to\r\n * ignore the effectAllowed field on dataTransfer, since we set a fake value in dragstart.\r\n * In those cases we rely on dndState to filter effects.\r\n */\r\n private _getDropEffect(event, ignoreDataTransfer) {\r\n let effects = this._dndState.ALL_EFFECTS;\r\n if (!ignoreDataTransfer) {\r\n effects = this._filterEffects(effects, event.dataTransfer.effectAllowed);\r\n }\r\n if (this._dndState.isDragging) {\r\n effects = this._filterEffects(effects, this._dndState.effectAllowed);\r\n }\r\n if (this.dndEffectAllowed) {\r\n effects = this._filterEffects(effects, this.dndEffectAllowed);\r\n }\r\n // MacOS automatically filters dataTransfer.effectAllowed depending on the modifier keys,\r\n // therefore the following modifier keys will only affect other operating systems.\r\n if (!effects.length) {\r\n return 'none';\r\n } else if (event.ctrlKey && effects.indexOf('copy') != -1) {\r\n return 'copy';\r\n } else if (event.altKey && effects.indexOf('link') != -1) {\r\n return 'link';\r\n } else {\r\n return effects[0];\r\n }\r\n }\r\n\r\n /**\r\n * Small helper function that cleans up if we aborted a drop.\r\n */\r\n private _stopDragover() {\r\n this._hoverCount = 0;\r\n this._placeholder.remove();\r\n this._renderer.removeClass(this._elementRef.nativeElement, 'dndDragover');\r\n return true;\r\n }\r\n\r\n /**\r\n * Invokes a callback with some interesting parameters and returns the callbacks return value.\r\n */\r\n private _invokeCallback(expression, event, dropEffect, itemType, index?, item?) {\r\n if (!expression) { return; }\r\n return expression({\r\n callback: this._dndState.callback,\r\n dropEffect: dropEffect,\r\n event: event,\r\n external: !this._dndState.isDragging,\r\n index: index !== undefined ? index : this._getPlaceholderIndex(),\r\n item: item || undefined,\r\n type: itemType\r\n });\r\n }\r\n\r\n /**\r\n * We use the position of the placeholder node to determine at which position of the array the\r\n * object needs to be inserted\r\n */\r\n private _getPlaceholderIndex(): number {\r\n let children = this._listNode.children;\r\n if(Object.prototype.isPrototypeOf.call(HTMLCollection.prototype, children)) {\r\n children = Array.from(children);\r\n }\r\n return children.indexOf(this._placeholderNode);\r\n }\r\n\r\n /**\r\n * Tries to find a child element that has the dndPlaceholder class set. If none was found, a\r\n * new li element is created.\r\n */\r\n private _getPlaceholderElement() {\r\n let placeholder;\r\n if (this._elementRef.nativeElement.children && this._elementRef.nativeElement.children.length) {\r\n this._elementRef.nativeElement.children.forEach(childNode => {\r\n const child = childNode;\r\n if (child.hasClass('dndPlaceholder')) {\r\n placeholder = child;\r\n }\r\n });\r\n }\r\n if (!placeholder) {\r\n const li = this._renderer.createElement('li');\r\n this._renderer.addClass(li, 'dndPlaceholder');\r\n placeholder = li;\r\n }\r\n return placeholder;\r\n }\r\n\r\n /**\r\n * Filters an array of drop effects using a HTML5 effectAllowed string.\r\n */\r\n private _filterEffects(effects, effectAllowed) {\r\n if (effectAllowed == 'all') return effects;\r\n return effects.filter(effect => {\r\n return effectAllowed.toLowerCase().indexOf(effect) != -1;\r\n });\r\n }\r\n}\r\n\r\n/**\r\n * Use the dnd-nodrag attribute inside of dnd-draggable elements to prevent them from starting\r\n * drag operations. This is especially useful if you want to use input elements inside of\r\n * dnd-draggable elements or create specific handle elements. Note: This directive does not work\r\n * in Internet Explorer 9.\r\n */\r\n@Directive({\r\n selector: '[ws-dnd-no-drag]'\r\n})\r\nexport class DragAndDropNoDragDirective implements OnInit {\r\n constructor(\r\n private readonly _elementRef: ElementRef,\r\n private readonly _renderer: Renderer2\r\n ) {}\r\n\r\n /**\r\n * Since the element is draggable, the browser's default operation is to drag it on dragstart.\r\n * We will prevent that and also stop the event from bubbling up.\r\n */\r\n @HostListener('dragstart', ['$event'])\r\n dragstart(event) {\r\n event = event.originalEvent || event;\r\n\r\n if (!event._dndHandle) {\r\n // If a child element already reacted to dragstart and set a dataTransfer object, we will\r\n // allow that. For example, this is the case for user selections inside of input elements.\r\n if (!(event.dataTransfer.types && event.dataTransfer.types.length)) {\r\n event.preventDefault();\r\n }\r\n event.stopPropagation();\r\n }\r\n }\r\n\r\n /**\r\n * Stop propagation of dragend events, otherwise dnd-moved might be triggered and the element\r\n * would be removed.\r\n */\r\n @HostListener('dragend', ['$event'])\r\n dragend(event) {\r\n event = event.originalEvent || event;\r\n if (!event._dndHandle) {\r\n event.stopPropagation();\r\n }\r\n }\r\n\r\n ngOnInit(): void {\r\n this._setDraggableAttr();\r\n }\r\n\r\n private _setDraggableAttr(): void {\r\n this._renderer.setAttribute(this._elementRef.nativeElement, 'draggable', 'true');\r\n }\r\n}\r\n\r\n/**\r\n * Use the dnd-handle directive within a dnd-nodrag element in order to allow dragging with that\r\n * element after all. Therefore, by combining dnd-nodrag and dnd-handle you can allow\r\n * dnd-draggable elements to only be dragged via specific \"handle\" elements. Note that Internet\r\n * Explorer will show the handle element as drag image instead of the dnd-draggable element. You\r\n * can work around this by styling the handle element differently when it is being dragged. Use\r\n * the CSS selector .dndDragging:not(.dndDraggingSource) [dnd-handle] for that.\r\n */\r\n@Directive({\r\n selector: '[ws-dnd-no-drag]'\r\n})\r\nexport class DragAndDropHandleDirective implements OnInit {\r\n constructor(\r\n private readonly _elementRef: ElementRef,\r\n private readonly _renderer: Renderer2\r\n ) {}\r\n\r\n @HostListener('dragstart', ['$event'])\r\n dragstart(event) {\r\n event = event.originalEvent || event;\r\n event._dndHandle = true;\r\n }\r\n\r\n @HostListener('dragend', ['$event'])\r\n dragend(event) {\r\n event = event.originalEvent || event;\r\n event._dndHandle = true;\r\n }\r\n\r\n ngOnInit(): void {\r\n this._setDraggableAttr();\r\n }\r\n\r\n private _setDraggableAttr(): void {\r\n this._renderer.setAttribute(this._elementRef.nativeElement, 'draggable', 'true');\r\n }\r\n}\r\n\r\n\r\n","
\r\n
\r\n
\r\n

Output

\r\n
\r\n
\r\n

\r\n Add Output Columns...\r\n

\r\n
\r\n
    \r\n
  • \r\n {{column.categoryName}} - {{column.displayName}}\r\n \r\n
  • \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { ProductAnalyticsService } from '../../../../Common/Amplitude/productAnalytics.service';\r\nimport { SmartSearchService } from '../../smartSearch.service';\r\nimport { RestrictService, Roles } from '../../../../Common/Permissions/restrict.service';\r\nimport { AdvancedSearchCriteria, AdvancedSearchPersistenceService, SearchFilters, SearchOutputColumns } from '../../advancedSearchPersistence.service';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'advanced-output-list',\r\n templateUrl: './outputList.component.html',\r\n styleUrls: ['./outputList.component.scss']\r\n})\r\nexport class OutputListComponent implements OnInit {\r\n constructor(\r\n private readonly _restrictService: RestrictService,\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n @Input() invalidColumns;\r\n @Input()\r\n set searchCriteria(searchCriteria: AdvancedSearchCriteria) {\r\n this._searchCriteria = { ...searchCriteria };\r\n\r\n this.outputColumns = this._searchCriteria.outputColumns;\r\n this.outputFormat = this._searchCriteria.outputFormat;\r\n this.searchFilters = this._searchCriteria.filters;\r\n this.groupByBatches = this._searchCriteria.groupByBatches;\r\n }\r\n\r\n @Output() outputChanged: EventEmitter = new EventEmitter();\r\n\r\n outputColumns: SearchOutputColumns[];\r\n outputFormat: number;\r\n searchFilters: SearchFilters[];\r\n groupByBatches: boolean;\r\n hasRyanPrivatePermission: boolean;\r\n loadSaveSettings: boolean;\r\n\r\n private _searchCriteria: AdvancedSearchCriteria;\r\n\r\n ngOnInit(): void {\r\n this.hasRyanPrivatePermission = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT) ||\r\n this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n }\r\n\r\n getColumnUniqueId = (value) => `${value.categoryId}${value.columnId}`;\r\n\r\n addOutputs(columns: any[]): void {\r\n this.outputColumns = _.union(this.outputColumns, columns);\r\n\r\n this._smartSearchService.disableColumns(_.union(this.outputColumns, this.searchFilters));\r\n this.updateCriteria();\r\n }\r\n\r\n removeOutput(column: any): void {\r\n _.remove(this.outputColumns, column);\r\n\r\n this._smartSearchService.disableColumns(_.union(this.outputColumns, this.searchFilters));\r\n this.invalidColumns = this._smartSearchService.getInvalidColumns(_.cloneDeep(this.outputColumns));\r\n this.updateCriteria();\r\n }\r\n\r\n columnMoved(): void {\r\n this.outputColumns = this.outputColumns.map(column => {\r\n column.showClose = false;\r\n return column;\r\n });\r\n this.updateCriteria();\r\n }\r\n\r\n updateCriteria(): void {\r\n this._searchCriteria.outputColumns = this.outputColumns;\r\n this._searchCriteria.outputFormat = this.outputFormat;\r\n this._searchCriteria.filters = this.searchFilters;\r\n this._searchCriteria.groupByBatches = this.groupByBatches;\r\n\r\n this._advancedSearchPersistenceService.setSearchCriteria(this._searchCriteria);\r\n this.outputChanged.emit();\r\n }\r\n\r\n async persistSetting(analyticsEvent?: string): Promise {\r\n this.updateCriteria();\r\n this.loadSaveSettings = true;\r\n await this._smartSearchService.persistSetting(this);\r\n this.loadSaveSettings = false;\r\n if (analyticsEvent) {\r\n this._productAnalyticsService.logEvent(analyticsEvent);\r\n }\r\n }\r\n\r\n areBatchFields(): boolean {\r\n const batchFieldsPresent = this.outputColumns.some(column => {\r\n // These IDs are company, Filing, and Batch respectively\r\n return [10, 140, 160].includes(column.depthValue);\r\n });\r\n\r\n if(!batchFieldsPresent) {\r\n this.groupByBatches = false;\r\n }\r\n\r\n return batchFieldsPresent;\r\n }\r\n}\r\n","\r\n
\r\n
\r\n

\r\n Search\r\n Mining\r\n And\r\n Reporting\r\n Tool\r\n

\r\n

{{ search.searchName }}

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n The following output columns are now invalid; please remove the disputing output columns to proceed\r\n
    \r\n
  • \r\n {{column.colName}} because of: {{offendingColumn}}\r\n
  • \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n","import { Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { Subject } from 'rxjs';\r\nimport { SearchPageType, UserSaveService } from '../../../Navigation/User-Save/userSave.service';\r\nimport { MessageBoxService } from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AdvancedSearchPersistenceService, AdvancedSearchResults, AdvancedSearchRouteParams, SavedSearchModel, SearchOr } from '../advancedSearchPersistence.service';\r\nimport { SmartSearchService } from '../smartSearch.service';\r\nimport { UtilitiesService } from '../../../UI-Lib/Utilities';\r\nimport { SaveSearchModalComponent, SaveSearchModalParams } from '../Save-Search-Modal/saveSearchModal.component';\r\nimport { AdvancedSearchCategoryTypes, DefaultDisplayTypes } from '../../../constants.new';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { takeUntil } from 'rxjs/internal/operators/takeUntil';\r\nimport { TimerService } from '../../../UI-Lib/Utilities';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\n\r\nimport * as _ from 'lodash';\r\nimport { UserInstanceService } from 'src/app/User/userInstance.service';\r\n\r\n@Component({\r\n selector: 'advanced-search',\r\n templateUrl: './advancedSearch.component.html',\r\n styleUrls: ['./advancedSearch.component.scss']\r\n})\r\nexport class AdvancedSearchComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _utils: UtilitiesService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _navigationService: UpgradeNavigationServiceHandler,\r\n private readonly _timer: TimerService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _userSaveService: UserSaveService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n @Input() search: SavedSearchModel;\r\n @Input() hasEditPermission: boolean;\r\n @Input() routeParams: AdvancedSearchRouteParams;\r\n\r\n @Output() executeSearch: EventEmitter = new EventEmitter();\r\n @Output() updateSearch: EventEmitter = new EventEmitter();\r\n @Output() updateSearchResults: EventEmitter = new EventEmitter();\r\n\r\n showPageTitle: boolean;\r\n searchResults;\r\n isSystemSearch: boolean;\r\n isSavedSearch: boolean;\r\n isShown: boolean;\r\n isSaveEnabled: boolean = false;\r\n isSingleInstanceSelected: boolean = false;\r\n\r\n invalidColumns = [];\r\n\r\n private _updateAdvancedSearchMenu: Subject = new Subject();\r\n private _destroy$: Subject = new Subject();\r\n\r\n get hideRevokeShareButton(): boolean {\r\n return this.search && (!this.search.isOwnedByUser || !this.search.isShared);\r\n }\r\n\r\n get hideSaveButton(): boolean {\r\n //Hide the button if:\r\n //It's a system search and the user does not have edit permissions\r\n //It's from a widget that can never be edited\r\n //or if it's a custom search but it's not saved or not owned by the user\r\n\r\n return (this.isSystemSearch && !this.hasEditPermission)\r\n || (this.search && this.search.searchId < 1000)\r\n || (!this.isSystemSearch && (!this.isSavedSearch || !this.search.isOwnedByUser));\r\n }\r\n\r\n ngOnInit(): void {\r\n this.isSingleInstanceSelected = this._userInstanceService.isSingleInstanceSelected();\r\n this._advancedSearchPersistenceService.showCriteria$.pipe(takeUntil(this._destroy$)).subscribe(x => this.isShown = x);\r\n\r\n this._populateSearch().then(() => {\r\n this._smartSearchService.disableColumns(_.union(this.search.searchCriteria.filters, this.search.searchCriteria.outputColumns));\r\n\r\n this._utils.convertDateStringsToDates(this.search.searchCriteria.filters);\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async favoriteSearchToggle(status): Promise {\r\n this.search.isFavorite = status;\r\n await this._smartSearchService.toggleSearchFavorite(this.search, status);\r\n this._updateAdvancedSearchMenu.next();\r\n }\r\n\r\n async revokeSearchShare(): Promise {\r\n await this._messageBoxService.confirm('Sharing with other users will be revoked. Click OK to confirm.', 'Search');\r\n const result = await this._smartSearchService.revokeShare(this.search);\r\n this.search.isShared = result.savedSearchDTO.isShared;\r\n this._toastr.success('Share was revoked!');\r\n }\r\n\r\n reloadSearch(): void {\r\n this._productAnalyticsService.logEvent('click-SMART-refresh');\r\n this.executeSearch.emit();\r\n }\r\n\r\n showCriteria(): void {\r\n this._productAnalyticsService.logEvent('refine-smart-search-criteria');\r\n this._advancedSearchPersistenceService.showCriteria(true);\r\n }\r\n\r\n clearCriteria(): void {\r\n if (!this.showPageTitle) {\r\n this._advancedSearchPersistenceService.resetSearchCriteria();\r\n } else {\r\n this._initSearch(false);\r\n }\r\n this._smartSearchService.disableColumns([ ...this.search.searchCriteria.filters, ...this.search.searchCriteria.outputColumns ]);\r\n this._productAnalyticsService.logEvent('click-reset');\r\n }\r\n\r\n userChangedSettings(): void {\r\n this.isSaveEnabled = true;\r\n }\r\n\r\n async saveSearch(): Promise {\r\n const search = { ...this.search };\r\n if (this.isSystemSearch) {\r\n if (confirm('Confirm Overwriting System Search')) {\r\n const result = await this._smartSearchService.saveSystemSearch(search);\r\n this.search.rowVersion = result.rowVersion;\r\n this._toastr.success('System Search Saved!');\r\n\r\n this._userSaveService.updateList(SearchPageType.Smart);\r\n }\r\n } else {\r\n const result = await this._smartSearchService.saveCustomSearch(search);\r\n this.search.rowVersion = result.rowVersion;\r\n this._toastr.success('User Search Saved!');\r\n\r\n this._userSaveService.updateList(SearchPageType.Smart);\r\n }\r\n this._productAnalyticsService.logEvent('click-SMART-save-search', {\r\n smartSavedSearchType: search.isSystemSearch ? 'System' : 'User',\r\n smartSavedSearchDisplay: search.defaultDisplay === DefaultDisplayTypes.CRITERIA ? 'Filter' : 'Detailed',\r\n smartSavedSearchCategory: search.categoryName ? search.categoryName : 'No Category'\r\n });\r\n this._advancedSearchPersistenceService.loadedSearchCriteriaCache = _.cloneDeep(this.search.searchCriteria);\r\n this.isSaveEnabled = false;\r\n }\r\n\r\n async saveSearchAs(): Promise {\r\n const searchCriteria = _.cloneDeep(this.search.searchCriteria);\r\n searchCriteria.searchName = this.search.searchName;\r\n searchCriteria.defaultDisplay = this.search.defaultDisplay;\r\n\r\n const params: SaveSearchModalParams = {\r\n searchCriteria: searchCriteria,\r\n searchType: this.search.type,\r\n hasEditPermission: this.hasEditPermission\r\n };\r\n const result = await this._modalService.showAsync(SaveSearchModalComponent, params, 'modal-md');\r\n\r\n if (!result) { return; }\r\n\r\n this.search.rowVersion = result.search.rowVersion;\r\n this._userSaveService.updateList(SearchPageType.Smart);\r\n this._advancedSearchPersistenceService.clearSearchData();\r\n this._navigationService.go('search', { searchId: result.search.searchId, searchType: result.type });\r\n }\r\n\r\n private async _populateSearch(): Promise {\r\n // This condition is for when users click the nub to return to a search\r\n // OR\r\n // When drilling down from the calendar widget\r\n if (this._advancedSearchPersistenceService.search) {\r\n this.showPageTitle = this._advancedSearchPersistenceService.showPageTitle;\r\n this.isSavedSearch = !!(this._advancedSearchPersistenceService.routeParams && this._advancedSearchPersistenceService.routeParams.searchId);\r\n this.isSystemSearch = this._advancedSearchPersistenceService.routeParams && parseInt(this._advancedSearchPersistenceService.routeParams.searchType) === AdvancedSearchCategoryTypes.SYSTEM;\r\n\r\n this.search = this._advancedSearchPersistenceService.search;\r\n this.searchResults = this._advancedSearchPersistenceService.results;\r\n\r\n if (!this._advancedSearchPersistenceService.fromWidget) {\r\n this._timer.setTimeout(() => {\r\n //TODO\r\n // this.gridOptions.api.setSortModel(this._advancedSearchPersistenceService.sort);\r\n });\r\n }\r\n\r\n this.updateSearch.emit(this.search);\r\n this.updateSearchResults.emit(this.searchResults);\r\n this._advancedSearchPersistenceService.showCriteria(false);\r\n\r\n if (this._advancedSearchPersistenceService.fromWidget) {\r\n this.executeSearch.emit();\r\n }\r\n } else if (this.routeParams.searchId && this.routeParams.searchType) {\r\n this.showPageTitle = false;\r\n this.isSavedSearch = true;\r\n this.isSystemSearch = (parseInt(this.routeParams.searchType) === AdvancedSearchCategoryTypes.SYSTEM);\r\n\r\n await this._loadSearch(+this.routeParams.searchId, +this.routeParams.searchType);\r\n if (this.search.defaultDisplay && !this._advancedSearchPersistenceService.reloadingSearch) {\r\n this.executeSearch.emit();\r\n } else {\r\n this._advancedSearchPersistenceService.reloadingSearch = false;\r\n }\r\n } else {\r\n this._initSearch();\r\n this.showPageTitle = true;\r\n }\r\n }\r\n\r\n private async _loadSearch(searchId, searchType): Promise {\r\n const result = await this._smartSearchService.getOneSearch(searchId, searchType);\r\n if (result.searchId) {\r\n if (result.searchCriteria) {\r\n this.invalidColumns = this._smartSearchService.getInvalidColumns(_.cloneDeep(result.searchCriteria.outputColumns));\r\n }\r\n result.type = searchType;\r\n this.search = result;\r\n this._advancedSearchPersistenceService.search = this.search;\r\n this._advancedSearchPersistenceService.loadedSearchCriteriaCache = _.cloneDeep(this.search.searchCriteria);\r\n\r\n if(this.routeParams.filters) {\r\n this._populateFilters();\r\n }\r\n\r\n this.updateSearch.emit(this.search);\r\n } else {\r\n this._toastr.error('Error retrieving search');\r\n this._initSearch();\r\n }\r\n }\r\n\r\n private _initSearch(transitionToNewSearch: boolean = true): void {\r\n if (transitionToNewSearch) {\r\n this._navigationService.transitionTo('search', { searchId: '', searchType: '' });\r\n }\r\n\r\n this.search = {\r\n ...this.search,\r\n searchCriteria: {\r\n searchName: null,\r\n outputColumns: [],\r\n filters: [],\r\n excludeInactive: true,\r\n groupByBatches: false,\r\n outputFormat: 0,\r\n showOrs: false,\r\n frequentlyUsed: false // WK-7166 is reversing WK-4681\r\n }\r\n };\r\n\r\n this.search.searchCriteria = { ...this.search.searchCriteria, ...this._smartSearchService.getSavedSettings() };\r\n\r\n this._advancedSearchPersistenceService.search = this.search;\r\n this._advancedSearchPersistenceService.setSearchCriteria(this.search.searchCriteria);\r\n this._smartSearchService.resetCategoryState();\r\n this.updateSearch.emit(this.search);\r\n }\r\n\r\n private _populateFilters() {\r\n this.search.searchCriteria.showOrs = true;\r\n const filterValues = JSON.parse(this.routeParams.filters);\r\n\r\n _.forEach(filterValues, filterValue => {\r\n const filterToUpdate = _.find(this.search.searchCriteria.filters, filter => {\r\n if (filter.columnId === filterValue.id) {\r\n if(filterValue.operatorName) {\r\n return filterValue.operatorName === filter.or[0].operator.name;\r\n } else {\r\n return true;\r\n }\r\n } else {\r\n return false;\r\n }\r\n });\r\n\r\n if(filterToUpdate) {\r\n filterToUpdate.or = _.map(filterValue.values, x => {\r\n return {\r\n ...filterToUpdate.or[0],\r\n value: x\r\n } as SearchOr;\r\n });\r\n }\r\n });\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AdvancedSearchRepository } from '../../../Core-Repositories';\r\n\r\n@Injectable()\r\nexport class AdvancedSearchListService {\r\n constructor(\r\n private readonly _advancedSearchRepository: AdvancedSearchRepository\r\n ) {}\r\n\r\n getBulkUpdateDescriptors(fieldCollection: number[]): Promise {\r\n const updateModel: Core.SmartBulkUpdateModel = {\r\n advancedSearchFieldIds: fieldCollection,\r\n descriptorValues: []\r\n };\r\n return lastValueFrom(this._advancedSearchRepository.getBulkUpdateDescriptors(updateModel));\r\n }\r\n\r\n async bulkUpdateList(updateModel: Core.SmartBulkUpdateModel): Promise {\r\n return lastValueFrom(this._advancedSearchRepository.bulkUpdateList(updateModel));\r\n }\r\n}\r\n","import { Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { UntypedFormBuilder, UntypedFormControl } from '@angular/forms';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { BulkUpdateDynamicBase } from '../../../../UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component';\r\nimport { AdvancedSearchListService } from '../advancedSearchList.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\nexport interface AdvancedSearchBulkUpdateFieldInfo {\r\n fieldId: number;\r\n field: Core.AdvancedSearchField;\r\n depth: Core.AdvancedSearchField;\r\n descriptorPickList: Core.DescriptorPickListModel[];\r\n descriptor: Core.DescriptorDTO;\r\n}\r\n\r\nexport interface FieldCollection {\r\n fields: { field: Core.AdvancedSearchField, depth: Core.AdvancedSearchField }[];\r\n fieldIds: number[];\r\n}\r\n\r\nexport interface AdvancedSearchBulkUpdateParams {\r\n searchFields: Core.AdvancedSearchField[];\r\n selection: any[];\r\n selectedCount: number;\r\n fieldCollection: FieldCollection;\r\n fieldInfo: AdvancedSearchBulkUpdateFieldInfo[];\r\n}\r\n\r\n@Component({\r\n selector: 'advanced-search-bulk-update',\r\n templateUrl: '../../../../UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component.html'\r\n})\r\nexport class AdvancedSearchBulkUpdateComponent extends BulkUpdateDynamicBase implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _advancedSearchListService: AdvancedSearchListService,\r\n private readonly _toastr: ToastrService,\r\n _bsModalRef: BsModalRef,\r\n _fb: UntypedFormBuilder,\r\n ) { super(_bsModalRef, _fb); }\r\n\r\n @ViewChild('text', { static: true }) textTemplate: ElementRef;\r\n @ViewChild('number', { static: true }) numberTemplate: ElementRef;\r\n @ViewChild('currency', { static: true }) currencyTemplate: ElementRef;\r\n @ViewChild('date', { static: true }) dateTemplate: ElementRef;\r\n @ViewChild('picklist', { static: true }) picklistTemplate: ElementRef;\r\n\r\n ngOnInit(): void {\r\n this.header = `Bulk Update ${this.params.selectedCount} Records`;\r\n\r\n this._templateMap = new Map([\r\n [Core.DescriptorFieldTypes.Date, this.dateTemplate],\r\n [Core.DescriptorFieldTypes.Number, this.numberTemplate],\r\n [Core.DescriptorFieldTypes.Picklist, this.picklistTemplate],\r\n [Core.DescriptorFieldTypes.YesNo, this.picklistTemplate],\r\n [Core.DescriptorFieldTypes.Text, this.textTemplate],\r\n [Core.DescriptorFieldTypes.Currency, this.currencyTemplate],\r\n ]);\r\n\r\n this.getUpdatableFields();\r\n }\r\n\r\n async save(force: boolean = false): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating' });\r\n\r\n const formValues = this.bulkUpdateForm.value;\r\n const changedDescriptors: Core.SmartDescriptorValueBulkUpdateModel[] = this.updateOptions\r\n .filter(x => x.descriptorId &&\r\n !(x.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange))\r\n .reduce((acc, x) => {\r\n const fieldInfo = this.params.fieldInfo.find(y => y.fieldId === +x.formControlName);\r\n const entityIds = this.params.selection.reduce((accArr, y) => {\r\n const id = y[`n${fieldInfo.depth.advancedSearchFieldID}`];\r\n if (accArr.indexOf(id) === -1) {\r\n accArr.push(id);\r\n }\r\n return accArr;\r\n }, []);\r\n\r\n acc.push({\r\n action: x.action,\r\n advancedSearchFieldId: fieldInfo.field.advancedSearchFieldID,\r\n descriptorId: x.descriptorId,\r\n entityIds,\r\n value: (x.action === Compliance.AssessorCommandCenterBulkUpdateActionEnum.Remove)\r\n ? null\r\n : formValues[x.formControlName]\r\n });\r\n return acc;\r\n }, [] as Core.SmartDescriptorValueBulkUpdateModel[]);\r\n\r\n const updateModel: Core.SmartBulkUpdateModel = {\r\n advancedSearchFieldIds: this.params.fieldInfo.map(x => x.descriptor.descriptorID),\r\n descriptorValues: changedDescriptors\r\n };\r\n\r\n try {\r\n await this._advancedSearchListService.bulkUpdateList(updateModel);\r\n\r\n this.result = this.params.selection.map(x => {\r\n const row = { ...x };\r\n changedDescriptors.forEach(y => {\r\n row[`f${y.advancedSearchFieldId}`] = y.value;\r\n });\r\n return row;\r\n });\r\n\r\n this._bsModalRef.hide();\r\n\r\n } catch (err) {\r\n console.error(err.message);\r\n return Promise.reject();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private async getUpdatableFields(): Promise {\r\n this.isLoading = true;\r\n const ptxFields = ['TopLevelCompanyAssessmentTaxFeed', 'TopLevelCompanyTaxBillTaxFeed',\r\n 'ParcelAssessmentTaxFeed', 'ParcelTaxBillTaxFeed' ];\r\n // Retrieve the descriptors from the back end and populate a model with all the data aggregated into one place\r\n let descriptors: Core.SmartBulkUpdateMetadataModel;\r\n try {\r\n descriptors = await this._advancedSearchListService.getBulkUpdateDescriptors(this.params.fieldCollection.fieldIds);\r\n const dummyDescriptor: Core.DescriptorDTO = {\r\n descriptorID: -1,\r\n fieldTypeID: Core.DescriptorFieldTypes.YesNo,\r\n assessorUsageID: 0,\r\n collectorUsageID: 0,\r\n assetUsageID: 0,\r\n categoryID: 0,\r\n enabled: false,\r\n isSystemControlled: false,\r\n name: '',\r\n notes: '',\r\n parcelUsageID: 0,\r\n sequenceNumber: 0,\r\n siteUsageID: 0,\r\n validation: undefined,\r\n arccUsageId: 0,\r\n companyUsageId: 0,\r\n changeDate: undefined,\r\n changedBy: undefined,\r\n efAction: ''\r\n };\r\n this.params.fieldCollection.fields.forEach((x, i) => {\r\n if(ptxFields.includes(x.field.internalName)) {\r\n this.params.fieldInfo.push({\r\n fieldId: this.params.fieldCollection.fieldIds[i],\r\n field: x.field,\r\n depth: x.depth,\r\n descriptor: dummyDescriptor,\r\n descriptorPickList: null\r\n });\r\n } else {\r\n // Some descriptors are shared between parcel and site\r\n const descriptor = descriptors.descriptors.find(y => y.descriptorID === x.field.descriptorID);\r\n const descriptorPickList = descriptors.descriptorPickLists.filter(y => y.groupID === descriptor.pickListGroupID);\r\n this.params.fieldInfo.push({\r\n fieldId: this.params.fieldCollection.fieldIds[i],\r\n field: x.field,\r\n depth: x.depth,\r\n descriptor,\r\n descriptorPickList\r\n });\r\n }});\r\n } catch (err) {\r\n console.error(err.message);\r\n this._toastr.error('There was an issue requesting the data required for bulk update');\r\n this.cancel();\r\n return;\r\n }\r\n\r\n this.params.fieldInfo.forEach(x => {\r\n const control = new UntypedFormControl(null, [this._validators.get(x.descriptor.fieldTypeID)(x.descriptor.validation)]);\r\n control.disable();\r\n this.bulkUpdateForm.addControl(`${x.fieldId}`, control);\r\n\r\n const option = {\r\n name: x.field.resultsColumnName,\r\n descriptorId: x.descriptor.descriptorID,\r\n isRequired: true,\r\n template: this._templateMap.get(x.descriptor.fieldTypeID),\r\n picklist: this._getPicklist(x),\r\n action: Compliance.AssessorCommandCenterBulkUpdateActionEnum.NoChange,\r\n formControlName: `${x.fieldId}`,\r\n formControl: control,\r\n validation: x.descriptor.validation,\r\n hiddenField: x.descriptor.descriptorID === -1 ? Compliance.AssessorCommandCenterBulkUpdateActionEnum.Remove: null\r\n };\r\n this.updateOptions.push(option);\r\n });\r\n\r\n this.isLoading = false;\r\n }\r\n\r\n private _getPicklist(fieldInfo: AdvancedSearchBulkUpdateFieldInfo): Compliance.NameValuePair[] {\r\n if (fieldInfo.descriptor.fieldTypeID === Core.DescriptorFieldTypes.Picklist) {\r\n return fieldInfo.descriptorPickList.map(p => ({ name: p.name, value: p.name }));\r\n }\r\n if (fieldInfo.descriptor.fieldTypeID === Core.DescriptorFieldTypes.YesNo) {\r\n return [\r\n { name: 'Yes', value: true },\r\n { name: 'No', value: false }\r\n ];\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { AgGridColumns, AgGridFilterParams } from '../../../Compliance/AgGrid';\r\nimport { CellClickedEvent, ColDef, RowNode, ValueGetterParams } from 'ag-grid-community';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from '../../../Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport {\r\n AgGridYesNoFloatingFilterComponent\r\n} from '../../../Compliance/AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport { SiteService } from '../../../Entity/Site/Site.Service.upgrade';\r\nimport { ParcelService } from '../../../Entity/Parcel/parcel.service.upgrade';\r\nimport { AssessorCollectorService } from '../../../Assessor-Collector/assessor.collector.service';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { NubService } from '../../../Navigation/Nub/nub.service';\r\nimport { AdvancedSearchPersistenceService } from '../advancedSearchPersistence.service';\r\nimport { SmartSearchService } from '../smartSearch.service';\r\nimport { ValueFormatterParams } from 'ag-grid-community/dist/lib/entities/colDef';\r\nimport { CommentsService } from '../../../Comments/comments.service';\r\nimport { WeissmanDateFormat } from '../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { EntityTypeIds } from '../../../constants.new';\r\nimport { DocumentServiceUpgrade } from '../../../Documents/document.service.upgrade';\r\nimport { PopUpService } from '../../../Common/Popup/popup.service';\r\nimport { CommentsModalService } from '../../../Comments/commentsModal.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport * as moment from 'moment-timezone';\r\nimport AdvancedSearchField = Core.AdvancedSearchField;\r\nimport { AttachmentService } from 'src/app/Attachment/attachment.service';\r\n\r\n@Injectable()\r\nexport class AdvancedSearchColumnBuilder {\r\n constructor(\r\n private readonly _siteService: SiteService,\r\n private readonly _parcelService: ParcelService,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _commentsService: CommentsService,\r\n private readonly _commentsModalService: CommentsModalService,\r\n private readonly _documentService: DocumentServiceUpgrade,\r\n private readonly _attachmentService: AttachmentService,\r\n private readonly _popUpService: PopUpService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _nubService: NubService\r\n ) {}\r\n\r\n getColumnDefinition(columnId: string, field: Core.AdvancedSearchField, source: string = 'smart'): ColDef {\r\n // Setup common column properties used by all column types\r\n // Depending on the column the cell renderer could get replaced\r\n let baseDefinition: any = {\r\n colId: columnId,\r\n headerName: field.resultsColumnName,\r\n field: columnId,\r\n hide: !(field.visible)\r\n };\r\n\r\n // If it is a navigation field, provide the correct renderer and nav link\r\n if (field.navigation) {\r\n const navigationRoute = this._getNavigationRoute(field.navigation, columnId);\r\n baseDefinition.cellRendererFramework = AgGridLinkCellRendererComponent;\r\n baseDefinition.cellRendererParams = {\r\n newWindow: false,\r\n isHelpDisabled: true,\r\n isDisabled: (params) => !navigationRoute,\r\n getLinkAsync: async (params: AgGridLinkCellRendererParams) => {\r\n const entry = params.data;\r\n if (!entry) {\r\n return '';\r\n }\r\n return await navigationRoute(entry);\r\n },\r\n onClick: (params: AgGridLinkCellRendererParams) => {\r\n this._setPersistentState(params.node, source);\r\n }\r\n } as AgGridLinkCellRendererParams;\r\n }\r\n\r\n // If formatting is provided by the back end, apply it\r\n const suppliedFormatting = {};\r\n if (field.advancedSearchDataType && field.advancedSearchDataType.formatting) {\r\n const dataTypeCustomFormatting = JSON.parse(field.advancedSearchDataType.formatting);\r\n Object.keys(dataTypeCustomFormatting).forEach((key: string) => {\r\n suppliedFormatting[key] = dataTypeCustomFormatting[key];\r\n });\r\n }\r\n\r\n // Get and apply the type based column settings\r\n baseDefinition = { ...baseDefinition, ...this._getTypeColumnProperties(field), ...suppliedFormatting };\r\n\r\n // Check to see if a field specific click event is needed\r\n const clickHandler = this._fieldSpecificClickEvents(field);\r\n if (clickHandler) {\r\n baseDefinition.onCellClicked = (params: CellClickedEvent) => {\r\n const rowData = params.data;\r\n clickHandler(rowData);\r\n };\r\n }\r\n\r\n // Set renderer if comment type\r\n switch (field.advancedSearchFieldID) {\r\n case 9007:\t\t// Document Intake Number of Comments\r\n case 1916:\t\t// Invoice Number of Comments\r\n case 1444:\t\t// Payment Number of Comments\r\n case 1044:\t\t// Revision Number of Comments\r\n case 1052:\t\t// Assessment DRTT Number of Comments\r\n case 1456:\t\t// Tax Bill DRTT Number of Comments\r\n baseDefinition = { ...baseDefinition, ...this._getCommentCell() };\r\n break;\r\n }\r\n\r\n // Ensure there is only one cell renderer applied since some fields will be both a navigation property and have\r\n // its own cell renderer, the regular cell renderer takes precedence, dropping the navigation renderer\r\n if (baseDefinition.cellRendererFramework && baseDefinition.cellRenderer) {\r\n delete baseDefinition.cellRendererFramework;\r\n delete baseDefinition.cellRendererParams;\r\n }\r\n\r\n return baseDefinition;\r\n }\r\n\r\n private _getNavigationRoute(navigationFieldName: string, columnId: string): (rowData) => Promise<{ stateName: string, params: any }> {\r\n switch (navigationFieldName) {\r\n case 'CompanyID':\r\n case 'Company_ParentCompanyID':\r\n return async (rowData) => {\r\n return {\r\n stateName: 'company',\r\n params: {\r\n companyId: this._getNavigationalFieldValueByName(rowData, navigationFieldName)\r\n }\r\n };\r\n };\r\n\r\n case 'SiteID':\r\n case 'Master SiteID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n\r\n if(!fieldValue) {\r\n this._toastr.warning('Site output column must be included for navigation.');\r\n return null;\r\n }\r\n\r\n return this._siteService.getNavigationInfo(fieldValue).then(result => {\r\n return {\r\n stateName: 'site',\r\n params: {\r\n siteId: fieldValue,\r\n companyId: result.companyID\r\n }\r\n };\r\n });\r\n };\r\n\r\n case 'ParcelID':\r\n case 'Master ParcelID':\r\n case 'PP Reporting ParcelID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n\r\n if(!fieldValue) {\r\n this._toastr.warning('Parcel output column must be included for navigation.');\r\n return null;\r\n }\r\n\r\n return await this._parcelService.getNavigationInfo(fieldValue).then(result => {\r\n return {\r\n stateName: 'parcel',\r\n params: {\r\n parcelId: fieldValue,\r\n siteId: result.siteID,\r\n companyId: result.companyID\r\n }\r\n };\r\n });\r\n };\r\n\r\n case 'AssessorID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n return this._assessorCollectorService.getNavigationInfo('assessor', fieldValue).then(result => {\r\n return {\r\n stateName: 'assessor',\r\n params: {\r\n id: this._getNavigationalFieldValueByName(rowData, navigationFieldName),\r\n stateId: result.stateID\r\n }\r\n };\r\n });\r\n };\r\n\r\n\r\n case 'CollectorID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n return this._assessorCollectorService.getNavigationInfo('collector', fieldValue).then(result => {\r\n return {\r\n stateName: 'collector',\r\n params: {\r\n stateCollectorId: this._getNavigationalFieldValueByName(rowData, navigationFieldName),\r\n stateId: result.stateID\r\n }\r\n };\r\n });\r\n };\r\n\r\n case 'CompanyContactID':\r\n case 'SiteContactID':\r\n case 'ParcelContactID':\r\n return async (rowData) => {\r\n return {\r\n stateName: 'contact',\r\n params: {\r\n contactId: this._getNavigationalFieldValueByName(rowData, navigationFieldName)\r\n }\r\n };\r\n };\r\n\r\n case 'StateID':\r\n return async (rowData) => {\r\n return {\r\n stateName: 'state',\r\n params: {\r\n // todo: get state id from central storage/ cached data?\r\n stateId: this._getNavigationalFieldValueByName(rowData, navigationFieldName)\r\n }\r\n };\r\n };\r\n\r\n case 'AnnualYearID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n return this._navigationService.getNavigationInfo('AnnualYear', fieldValue).then(result => {\r\n return {\r\n stateName: 'parcel',\r\n params: {\r\n annualYearID: fieldValue,\r\n siteId: result.siteID,\r\n companyId: result.companyID,\r\n parcelId: result.parcelID\r\n }\r\n };\r\n });\r\n };\r\n\r\n case 'AnnualAssessmentID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n return this._navigationService.getNavigationInfo('AnnualAssessment', fieldValue).then(result => {\r\n return {\r\n stateName: 'parcel',\r\n params: {\r\n annualAssessmentID: fieldValue,\r\n siteId: result.siteID,\r\n companyId: result.companyID,\r\n annualYearID: result.annualYearID,\r\n parcelId: result.parcelID\r\n }\r\n };\r\n });\r\n };\r\n\r\n case 'AppealID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n return this._navigationService.getNavigationInfo('Appeal', fieldValue).then(result => {\r\n return {\r\n stateName: 'parcel',\r\n params: {\r\n appealID: fieldValue,\r\n annualAssessmentID: result.annualAssessmentID,\r\n siteId: result.siteID,\r\n companyId: result.companyID,\r\n annualYearID: result.annualYearID,\r\n parcelId: result.parcelID\r\n }\r\n };\r\n });\r\n };\r\n\r\n case 'FilingID':\r\n return async (rowData) => {\r\n let fieldName = 'Filing';\r\n let fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n\r\n if (!fieldValue) {\r\n fieldValue = this._getNavigationalFieldValueByName(rowData, 'FilingBatchID');\r\n fieldName = 'FilingBatch';\r\n }\r\n\r\n return this._navigationService.getNavigationInfo(fieldName, fieldValue).then(result => {\r\n if (fieldName === 'Filing') {\r\n return {\r\n stateName: 'parcel',\r\n params: {\r\n filingId: fieldValue,\r\n siteId: result.siteID,\r\n companyId: result.companyID,\r\n annualYearID: result.annualYearID,\r\n parcelId: result.parcelID\r\n }\r\n };\r\n } else {\r\n return {\r\n stateName: 'filingBatchDetails',\r\n params: {\r\n companyId: result.companyID,\r\n filingBatchId: fieldValue\r\n }\r\n };\r\n }\r\n });\r\n };\r\n\r\n case 'FilingBatchID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n return this._navigationService.getNavigationInfo('FilingBatch', fieldValue).then(result => {\r\n return {\r\n stateName: 'filingBatchDetails',\r\n params: {\r\n companyId: result.companyID,\r\n filingBatchId: fieldValue\r\n }\r\n };\r\n });\r\n };\r\n\r\n case 'RefundID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n return this._navigationService.getNavigationInfo('Refund', fieldValue).then(result => {\r\n return {\r\n stateName: 'parcel',\r\n params: {\r\n refundID: fieldValue,\r\n siteId: result.siteID,\r\n companyId: result.companyID,\r\n annualYearID: result.annualYearID,\r\n parcelId: result.parcelID\r\n }\r\n };\r\n });\r\n };\r\n\r\n case 'BillClusterID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n return this._navigationService.getNavigationInfo('BillCluster', fieldValue).then(result => {\r\n return {\r\n stateName: 'parcel',\r\n params: {\r\n billClusterID: fieldValue,\r\n siteId: result.siteID,\r\n companyId: result.companyID,\r\n annualYearID: result.annualYearID,\r\n parcelId: result.parcelID\r\n }\r\n };\r\n });\r\n };\r\n\r\n case 'PaymentID':\r\n return async (rowData) => {\r\n return {\r\n stateName: 'paymentRedirect',\r\n params: {\r\n entityID: this._getNavigationalFieldValueByName(rowData, navigationFieldName)\r\n }\r\n };\r\n };\r\n\r\n case 'InvoiceID':\r\n return async (rowData) => {\r\n const fieldValue = this._getNavigationalFieldValueByName(rowData, navigationFieldName);\r\n return this._navigationService.getNavigationInfo('Invoice', fieldValue).then(result => {\r\n if (result.siteID) {\r\n return {\r\n stateName: 'siteInvoice',\r\n params: {\r\n invoiceID: fieldValue,\r\n siteID: result.siteID,\r\n companyID: result.companyID\r\n }\r\n };\r\n } else {\r\n return {\r\n stateName: 'companyInvoice',\r\n params: {\r\n invoiceID: fieldValue,\r\n companyID: result.companyID\r\n }\r\n };\r\n }\r\n });\r\n };\r\n\r\n default:\r\n console.log('advanced search - unimplemented navigation - ', navigationFieldName);\r\n return null;\r\n }\r\n }\r\n\r\n private _getTypeColumnProperties(field: Core.AdvancedSearchField): ColDef {\r\n const minimumFractionDigits = field.advancedSearchDataType.precision || 0;\r\n switch (field.advancedSearchDataTypeID) {\r\n case Core.AdvancedSearchDataTypeEnum.money:\r\n case Core.AdvancedSearchDataTypeEnum.Currency_0:\r\n case Core.AdvancedSearchDataTypeEnum.Currency_2:\r\n return {\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params: ValueFormatterParams) => {\r\n const valueToFormat = params.value;\r\n\r\n if (!valueToFormat) { return ''; }\r\n\r\n const formatter = new Intl.NumberFormat('en-US', {\r\n style: 'currency',\r\n currency: 'USD',\r\n minimumFractionDigits: minimumFractionDigits,\r\n maximumFractionDigits: minimumFractionDigits\r\n });\r\n\r\n return formatter.format(valueToFormat);\r\n }\r\n };\r\n case Core.AdvancedSearchDataTypeEnum.Date:\r\n case Core.AdvancedSearchDataTypeEnum.DateTime:\r\n case Core.AdvancedSearchDataTypeEnum.datetime2:\r\n case Core.AdvancedSearchDataTypeEnum.UTCDate:\r\n case Core.AdvancedSearchDataTypeEnum.UTCDateTime:\r\n case Core.AdvancedSearchDataTypeEnum.DateText:\r\n let dateFormatter;\r\n\r\n // For all other date types, the time coming from the server has already been\r\n // converted and is ready for display; we use UTC for transmission between the\r\n // server and client so that JavaScript doesn't convert the time to a local time.\r\n // So we use .utc() to retrieve the raw unprocessed date/time the server had\r\n // before transmission (see Utilities.Service.js convertDateStringsToDates\r\n // function and related functions for more info)\r\n if (field.advancedSearchDataType.name.indexOf('Date') >= 0) {\r\n dateFormatter = (inputDateTime) => {\r\n return moment(inputDateTime).utc().format('M/DD/YYYY');\r\n };\r\n }\r\n\r\n if (field.advancedSearchDataType.name.indexOf('DateTime') >= 0) {\r\n dateFormatter = (inputDateTime) => {\r\n return moment(inputDateTime).utc().format('M/DD/YYYY h:mm A');\r\n };\r\n }\r\n\r\n // For UTCDateTime and UTCDate type fields, the time coming from the server is\r\n // really a moment in time specified in UTC, and we need to convert it to Central\r\n // time before displaying\r\n if (field.advancedSearchDataType.name.indexOf('UTCDate') >= 0) {\r\n dateFormatter = (inputDateTime) => {\r\n return moment(inputDateTime).tz('America/Chicago').format('M/DD/YYYY');\r\n };\r\n }\r\n\r\n if (field.advancedSearchDataType.name.indexOf('UTCDateTime') >= 0) {\r\n dateFormatter = (inputDateTime) => {\r\n return moment(inputDateTime).tz('America/Chicago').format('M/DD/YYYY h:mm A');\r\n };\r\n }\r\n\r\n return {\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueGetter: (params: ValueGetterParams) => {\r\n const valueToFormat = params.data[params.colDef.field];\r\n\r\n if (!valueToFormat) { return ''; }\r\n\r\n if (valueToFormat === 'N/A') {\r\n return valueToFormat;\r\n }\r\n\r\n return dateFormatter ? dateFormatter(valueToFormat) : WeissmanDateFormat(valueToFormat);\r\n },\r\n comparator: (valueA, valueB) => {\r\n let result = 0;\r\n if (valueA == valueB) {\r\n return 0;\r\n }\r\n\r\n if (valueA == null && valueB == null) {\r\n return 0;\r\n }\r\n\r\n const cA = this._constructDateIfAbsent(valueA);\r\n const cB = this._constructDateIfAbsent(valueB);\r\n\r\n if (cA > cB) {\r\n result = 1;\r\n }\r\n\r\n if (cA < cB) {\r\n result = -1;\r\n }\r\n\r\n if (cA == cB) {\r\n result = 0;\r\n }\r\n\r\n return result;\r\n }\r\n };\r\n case Core.AdvancedSearchDataTypeEnum.Percent_0:\r\n case Core.AdvancedSearchDataTypeEnum.Percent_1:\r\n case Core.AdvancedSearchDataTypeEnum.Percent_2:\r\n case Core.AdvancedSearchDataTypeEnum.Percent_3:\r\n case Core.AdvancedSearchDataTypeEnum.Percent_4:\r\n case Core.AdvancedSearchDataTypeEnum.Percent_5:\r\n case Core.AdvancedSearchDataTypeEnum.Percent_6:\r\n return {\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params: ValueFormatterParams) => {\r\n const valueToFormat = params.value;\r\n\r\n if (!valueToFormat) { return ''; }\r\n\r\n const formatter = new Intl.NumberFormat('en-US', {\r\n style: 'percent',\r\n minimumFractionDigits: minimumFractionDigits,\r\n maximumFractionDigits: minimumFractionDigits\r\n });\r\n\r\n return formatter.format(valueToFormat);\r\n }\r\n };\r\n case Core.AdvancedSearchDataTypeEnum.Number_0:\r\n case Core.AdvancedSearchDataTypeEnum.Number_0_NoGrouping:\r\n case Core.AdvancedSearchDataTypeEnum.Number_1:\r\n case Core.AdvancedSearchDataTypeEnum.Number_2:\r\n case Core.AdvancedSearchDataTypeEnum.Number_3:\r\n case Core.AdvancedSearchDataTypeEnum.bit:\r\n case Core.AdvancedSearchDataTypeEnum.smallint:\r\n case Core.AdvancedSearchDataTypeEnum.intType:\r\n case Core.AdvancedSearchDataTypeEnum.decimalType:\r\n case Core.AdvancedSearchDataTypeEnum.Year:\r\n return {\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params: ValueFormatterParams) => {\r\n const valueToFormat = params.value;\r\n\r\n if (field.customFormatting.gridShowValueAsZeroIfZero && valueToFormat == 0) { return '0'; }\r\n if (field.customFormatting.gridShowValueAsZeroIfNull && valueToFormat == null) { return '0'; }\r\n\r\n if (!valueToFormat) { return ''; }\r\n\r\n const formatter = new Intl.NumberFormat('en-US', {\r\n style: 'decimal',\r\n minimumFractionDigits: minimumFractionDigits,\r\n maximumFractionDigits: minimumFractionDigits,\r\n useGrouping: (field.advancedSearchDataType.name.indexOf('NoGrouping') < 0)\r\n });\r\n\r\n return formatter ? formatter.format(valueToFormat) : valueToFormat;\r\n }\r\n };\r\n case Core.AdvancedSearchDataTypeEnum.picklist:\r\n return {\r\n width: AgGridColumns.selectionColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n };\r\n case Core.AdvancedSearchDataTypeEnum.Text_Align_Left:\r\n case Core.AdvancedSearchDataTypeEnum.Text_Align_Right:\r\n case Core.AdvancedSearchDataTypeEnum.Text_Align_Center:\r\n case Core.AdvancedSearchDataTypeEnum.varchar:\r\n let textAlign = 'left';\r\n if (field.advancedSearchDataTypeID === Core.AdvancedSearchDataTypeEnum.Text_Align_Right) {\r\n textAlign = 'right';\r\n } else if (field.advancedSearchDataTypeID === Core.AdvancedSearchDataTypeEnum.Text_Align_Center) {\r\n textAlign = 'center';\r\n }\r\n return {\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellStyle: {\r\n textAlign: textAlign\r\n }\r\n };\r\n case Core.AdvancedSearchDataTypeEnum.YesNo:\r\n case Core.AdvancedSearchDataTypeEnum.YesNoNullable:\r\n case Core.AdvancedSearchDataTypeEnum.YesNoEmpty:\r\n return {\r\n width: AgGridColumns.checkboxColumnMinWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterWithBlankOptionsParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n if (params.value || params.value === false) {\r\n return (params.value && !(params.value === 'no' || params.value === 'No')) ? 'Yes' : 'No';\r\n } else {\r\n return '';\r\n }\r\n }\r\n };\r\n case Core.AdvancedSearchDataTypeEnum.AttachmentIconOpenPreview:\r\n return {\r\n width: AgGridColumns.checkboxColumnMinWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.booleanFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n cellRenderer: (params) => {\r\n if (params.value) {\r\n if (params.colDef.pdfLoading && params.colDef.pdfLoading === params.value) {\r\n return `
\r\n \r\n
`;\r\n } else {\r\n return '';\r\n }\r\n }\r\n return '';\r\n },\r\n onCellClicked: async (params: CellClickedEvent) => {\r\n // Anything using square bracket notation to access or assign a value is not supported by the\r\n // Typing assigned to it, although it was part of the old JS code so I'm leaving it in place\r\n\r\n const rowData = params.data;\r\n\r\n params.colDef['pdfLoading'] = params.value;\r\n params.api.redrawRows();\r\n\r\n const attachmentId = rowData[`f${ field.advancedSearchFieldID.toString()}`];\r\n\r\n const response = await this._documentService.getDocumentBody(attachmentId);\r\n const fileName = this._attachmentService.getFileNameFromHttpResponse(response, true);\r\n const fileExtension = fileName.split('.')[1].substring(0, 3);\r\n const attachmentBlob = new Blob([response.data], { type: fileExtension });\r\n const fileInfo = this._attachmentService.getMimeTypeByFileExtension(fileExtension);\r\n\r\n if (fileInfo['previewSupported']) {\r\n const popUpData = {\r\n attachmentInfo: {\r\n attachmentID: attachmentId,\r\n fileName: fileName,\r\n fileExtension: fileExtension\r\n }\r\n };\r\n\r\n let attchmentGroupName = this._popUpService.StaticAliases.Attachment;\r\n\r\n // ctrl-click - open a new window\r\n if (params.event['ctrlKey']) {\r\n attchmentGroupName = attchmentGroupName + new Date().getTime();\r\n }\r\n\r\n const globalAttachmentsPopUpRef = this._popUpService.getByAliasGroup(attchmentGroupName)[0];\r\n if (globalAttachmentsPopUpRef && globalAttachmentsPopUpRef.isOpen()) {\r\n globalAttachmentsPopUpRef.publish(this._popUpService.Topics.Attachment.AttachmentChanged, popUpData);\r\n } else {\r\n const popUpRef = await this._popUpService.openAttachmentPreview(attchmentGroupName, globalAttachmentsPopUpRef);\r\n popUpRef.publish(this._popUpService.Topics.Attachment.AttachmentChanged, popUpData);\r\n }\r\n } else {\r\n await this._documentService.saveFile(attachmentBlob, fileName);\r\n }\r\n\r\n params.colDef['pdfLoading'] = undefined;\r\n params.api.redrawRows();\r\n }\r\n };\r\n default:\r\n return {};\r\n }\r\n }\r\n\r\n private _getCommentCell(): ColDef {\r\n return {\r\n cellRenderer: (params) => {\r\n if (params.value != 0) {\r\n return '';\r\n }\r\n return '';\r\n },\r\n cellClass: 'text-align-center',\r\n headerName: '',\r\n width: 40,\r\n minWidth: 40,\r\n maxWidth: 40,\r\n hide: false\r\n };\r\n }\r\n\r\n private _getNavigationalFieldValueByName(rowData, fieldName) {\r\n const navigationField = this._smartSearchService.getFieldByDisplayName(fieldName);\r\n // get value for navigational field\r\n return rowData[`n${ navigationField.advancedSearchFieldID}`];\r\n }\r\n\r\n private _setPersistentState(rowNode: RowNode, source: string): void {\r\n this._advancedSearchPersistenceService.scrollLocationIndex = rowNode ? rowNode.rowIndex : 0;\r\n switch (source) {\r\n case 'smart':\r\n this._nubService.showAdvancedSearchNub();\r\n break;\r\n case 'av':\r\n this._nubService.showActionViewNub();\r\n break;\r\n }\r\n }\r\n\r\n private _constructDateIfAbsent(data: any): Date {\r\n switch (data) {\r\n case null:\r\n return new Date('01-01-2200');\r\n case 'N/A':\r\n return new Date('01-01-2300');\r\n default:\r\n return new Date(data);\r\n }\r\n }\r\n\r\n private _fieldSpecificClickEvents(field: AdvancedSearchField) {\r\n switch (field.advancedSearchFieldID) {\r\n // Document Intake Number of Comments\r\n case 9007:\r\n return (rowData) => {\r\n this._commentsService.getEntityDataForTasks([rowData.n10908]).then((data) => {\r\n this._commentsModalService.openCommentModal(data[0]);\r\n });\r\n };\r\n // Assessment DRTT Number of Comments\r\n case 1052:\r\n return (rowData) => {\r\n console.log('opening DRTT comment modal ');\r\n // this field can be displayed in either AV or SMART\r\n // if the invoiceID is available use that, otherwise see if the taskID is available (taskID would not be available in SMART)\r\n if (rowData.n1000) {\t\t// SMART, we have assesmentID\r\n this._commentsService.getEntityData(rowData.n1000, EntityTypeIds.ASSESSMENT).then((data) => {\r\n console.log('opening comment modal using entity, data:', data);\r\n data.commentTypeID = 4;\r\n this._commentsModalService.openCommentModal(data);\r\n });\r\n } else {\r\n this._commentsService.getEntityDataForTasks([rowData.n10908]).then((data) => {\t\t// n10908 == SubjectTaskID\r\n console.log('opening comment modal using task, data:', data);\r\n data[0].commentTypeID = 4;\r\n this._commentsModalService.openCommentModal(data[0]);\r\n });\r\n }\r\n };\r\n\r\n // Bill DRTT Number of Comments\r\n case 1456:\r\n return (rowData) => {\r\n console.log('opening Bill DRTT comment modal ');\r\n // this field can be displayed in either AV or SMART\r\n // if the invoiceID is available use that, otherwise see if the taskID is available (taskID would not be available in SMART)\r\n if (rowData.n1498) {\t\t// SMART, we have bill ID\r\n this._commentsService.getEntityData(rowData.n1498, EntityTypeIds.TAX_BILL).then((data) => {\r\n console.log('opening comment modal using entity, data:', data);\r\n data.commentTypeID = 4;\r\n this._commentsModalService.openCommentModal(data);\r\n });\r\n } else {\r\n this._commentsService.getEntityDataForTasks([rowData.n10908]).then((data) => {\t\t// n10908 == SubjectTaskID\r\n console.log('opening comment modal using task, data:', data);\r\n data[0].commentTypeID = 4;\r\n this._commentsModalService.openCommentModal(data[0]);\r\n });\r\n }\r\n };\r\n\r\n // Invoice Number of Comments\r\n case 1916:\r\n return (rowData) => {\r\n // this field can be displayed in either AV or SMART\r\n // if the invoiceID is available use that, otherwise see if the taskID is available (taskID would not be available in SMART)\r\n if (rowData.n1900) {\r\n this._commentsService.getEntityData(rowData.n1900, EntityTypeIds.INVOICE).then((data) => {\r\n this._commentsModalService.openCommentModal(data);\r\n });\r\n } else {\r\n this._commentsService.getEntityDataForTasks([rowData.n10908]).then((data) => {\r\n this._commentsModalService.openCommentModal(data[0]);\r\n });\r\n }\r\n };\r\n\r\n case 1444:\t\t// TAX_BILL Number of Comments\r\n return (rowData) => {\r\n // this field can be displayed in either AV or SMART\r\n // if the BILLID is available use that, otherwise see if the taskID is available (taskID would not be available in SMART)\r\n if (rowData.n1498) {\r\n this._commentsService.getEntityData(rowData.n1498, EntityTypeIds.TAX_BILL).then((data) => {\r\n this._commentsModalService.openCommentModal(data);\r\n });\r\n } else {\t\t// use task\r\n this._commentsService.getEntityDataForTasks([rowData.n10908]).then((data) => {\r\n this._commentsModalService.openCommentModal(data[0]);\r\n });\r\n }\r\n };\r\n\r\n case 1044:\t\t// Revision Number of Comments\r\n return (rowData) => {\r\n // this field can be displayed in either AV or SMART\r\n // if the RevisionID is available use that, otherwise see if the taskID is available (taskID would not be available in SMART)\r\n if (rowData.n1000) {\r\n this._commentsService.getEntityData(rowData.n1000, EntityTypeIds.ASSESSMENT).then((data) => {\r\n this._commentsModalService.openCommentModal(data);\r\n });\r\n } else {\t\t// use task\r\n this._commentsService.getEntityDataForTasks([rowData.n10908]).then((data) => {\r\n this._commentsModalService.openCommentModal(data[0]);\r\n });\r\n }\r\n };\r\n }\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { BehaviorSubject, Subject } from 'rxjs';\r\nimport { ColDef, ColumnApi, GridApi, GridReadyEvent, RowDataChangedEvent, RowNode } from 'ag-grid-community';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { AgGridColumns, AgGridOptionsBuilder } from '../../../Compliance/AgGrid';\r\nimport { AgGridExportOptions } from '../../../Compliance/AgGrid/ToolPanel/models';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { SmartSearchService } from '../smartSearch.service';\r\nimport { AdvancedSearchColumnBuilder } from './advancedSearchColumnBuilder.service';\r\nimport { AdvancedSearchPersistenceService, AdvancedSearchResults } from '../advancedSearchPersistence.service';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectTracker } from '../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AdvancedSearchBulkUpdateComponent, AdvancedSearchBulkUpdateFieldInfo, AdvancedSearchBulkUpdateParams, FieldCollection } from './Bulk-Update/advancedSearchBulkUpdate.component';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\nimport * as moment from 'moment';\r\n\r\n@Component({\r\n selector: 'advanced-search-list',\r\n templateUrl: './advancedSearchList.component.html',\r\n styleUrls: ['./advancedSearchList.component.scss']\r\n})\r\nexport class AdvancedSearchListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _columnBuilder: AdvancedSearchColumnBuilder,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n @Input()\r\n set searchResults(searchResults: AdvancedSearchResults) {\r\n if (searchResults && searchResults.dataTable) {\r\n this._tableData = searchResults.dataTable;\r\n this._buildTable(this._tableData);\r\n } else {\r\n this._clearTable();\r\n }\r\n }\r\n\r\n @Output() exportToExcel: EventEmitter = new EventEmitter();\r\n\r\n haveAllSearchFields: boolean;\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n columnApi: ColumnApi;\r\n gridId: System.Guid = '59C76BFE-ADE9-450A-88FE-F4F1B61C4443';\r\n gridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => {\r\n this.gridTracker.onGridSortChanged();\r\n this.emitAnalyticsEvent('click-column-sort');\r\n },\r\n getRowNodeId: (x) => x.rowId,\r\n rowClassRules: {\r\n 'clickable': (params) => false,\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected(params.data.rowId)\r\n },\r\n suppressScrollOnNewData: true,\r\n onRowDataChanged: (event: RowDataChangedEvent) => {\r\n if (this._advancedSearchPersistenceService.scrollLocationIndex) {\r\n this._gridApi.ensureIndexVisible(this._advancedSearchPersistenceService.scrollLocationIndex, 'top');\r\n this._advancedSearchPersistenceService.scrollLocationIndex = null;\r\n }\r\n }\r\n })\r\n .withSort()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withLoadingOverlay()\r\n .build();\r\n\r\n exportOptions: AgGridExportOptions = {\r\n onExportClick: (): void => {\r\n this.emitAnalyticsEvent('click-SMART-excel-export');\r\n this.exportToExcel.emit();\r\n },\r\n disabled: false,\r\n canCancel: true\r\n };\r\n\r\n private _gridApi: GridApi;\r\n private _tableData: any[];\r\n private _destroy$: Subject = new Subject();\r\n\r\n async ngOnInit(): Promise {\r\n // we need to do this in order to preload search fields; once they are cached by service this call will return cached version\r\n await this._smartSearchService.getAllFields(true);\r\n this.haveAllSearchFields = true;\r\n\r\n this._advancedSearchPersistenceService.isSearching$.pipe(takeUntil(this._destroy$)).subscribe(searching => {\r\n if (!this._gridApi) { return; }\r\n if (searching) {\r\n this._gridApi.showLoadingOverlay();\r\n } else {\r\n this._gridApi.hideOverlay();\r\n }\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.columnApi = event.columnApi;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this.gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe(() => {\r\n const isBulkUpdateVisible = this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n });\r\n\r\n if (this._tableData) {\r\n this._buildTable(this._tableData);\r\n }\r\n }\r\n\r\n async bulkUpdate(): Promise {\r\n const fieldInfo: AdvancedSearchBulkUpdateFieldInfo[] = [];\r\n\r\n // Retrieve the selected row data\r\n const rowIds = await this.gridTracker.getSelectedRowIds();\r\n const rowData = rowIds.map(x => {\r\n const rowNode = this._gridApi.getRowNode(`${x}`);\r\n return rowNode && rowNode.data;\r\n }).filter(x => !!x);\r\n\r\n // Get the search fields that match the ids provided by the data\r\n const rowDataIds = Object.keys(rowData[0]);\r\n const searchFields = rowDataIds.reduce((acc, x) => {\r\n const fieldId = +x.slice(1);\r\n if (isNaN(fieldId)) { return acc; }\r\n\r\n const field = this._smartSearchService.getFieldById(fieldId);\r\n if (!field) { return acc; }\r\n\r\n acc.push(field);\r\n\r\n return acc;\r\n }, []);\r\n\r\n // Collect the descriptor ids from columns if all required values are available\r\n const columns = this.columnApi.getAllColumns();\r\n const ptxCompanyFields = ['TopLevelCompanyAssessmentTaxFeed', 'TopLevelCompanyTaxBillTaxFeed' ];\r\n const ptxParcelFields = ['ParcelAssessmentTaxFeed', 'ParcelTaxBillTaxFeed' ];\r\n const fieldCollection = columns.reduce((acc, x) => {\r\n const columnId = x.getColId().slice(1);\r\n const field = this._smartSearchService.getFieldById(+columnId);\r\n if (field && field.descriptorID) {\r\n // Check to make sure the entity field required for update is provided\r\n const depthFieldId = field.advancedSearchCategory.parentCategoryID * 100;\r\n const depth = this._smartSearchService.getFieldById(depthFieldId);\r\n if(depth) {\r\n if (rowDataIds.find(y => y === `n${depthFieldId}`)) {\r\n acc.fields.push({ field, depth });\r\n acc.fieldIds.push(+columnId);\r\n }\r\n }\r\n // Bulk Update via SMART is done only for characteristics.\r\n // These are the only 4 fields where non characteristic fields are being bulk updated.\r\n // So these fields do not have a descriptor id.\r\n } else if (field && (ptxCompanyFields.includes(field.internalName) || ptxParcelFields.includes(field.internalName))) {\r\n let depthFieldId:number;\r\n if(ptxCompanyFields.includes(field.internalName)) {\r\n depthFieldId = this._smartSearchService.getFieldByDisplayName('Company_ParentCompanyID').advancedSearchFieldID;\r\n } else {\r\n depthFieldId = this._smartSearchService.getFieldByDisplayName('ParcelID').advancedSearchFieldID;\r\n }\r\n const depth = this._smartSearchService.getFieldById(depthFieldId);\r\n if(depth) {\r\n if (rowDataIds.find(y => y === `n${depthFieldId}`)) {\r\n acc.fields.push({ field, depth });\r\n acc.fieldIds.push(+columnId);\r\n }\r\n }\r\n }\r\n return acc;\r\n }, {\r\n fields: [],\r\n fieldIds: []\r\n } as FieldCollection);\r\n\r\n // If not enough info at this point, bail out\r\n if (!fieldCollection.fieldIds.length) {\r\n this._toastr.warning('Site or parcel output columns must be included for bulk update.');\r\n this._gridApi.hideOverlay();\r\n this.gridTracker.clear();\r\n this._gridApi.redrawRows();\r\n return;\r\n }\r\n\r\n // Open the modal with all of the data just retrieved\r\n const params: AdvancedSearchBulkUpdateParams = {\r\n searchFields,\r\n selection: rowData,\r\n selectedCount: this.gridTracker.getSelectedRowsCount(),\r\n fieldCollection,\r\n fieldInfo\r\n };\r\n\r\n const result = await this._modalService.showAsync(AdvancedSearchBulkUpdateComponent, params, 'modal-lg');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._productAnalyticsService.logEvent('click-SMART-bulk-update', { smartBulkUpdatedRecords: result.length });\r\n\r\n // Update the rows selected with the result\r\n this._gridApi.updateRowData({ update: result });\r\n this.gridTracker.clear();\r\n this._gridApi.redrawRows();\r\n }\r\n\r\n emitAnalyticsEvent(event: string): void {\r\n this._productAnalyticsService.logEvent(event);\r\n }\r\n\r\n private _buildTable(tableData: any[]): void {\r\n if (!this._gridApi) { return; }\r\n\r\n // Important - For whatever reason, ag-grid will maintain the previous search column order if not reset\r\n this._gridApi.setColumnDefs([]);\r\n\r\n const search = this._advancedSearchPersistenceService.search;\r\n const columnIds = (tableData && tableData.length) ? Object.keys(tableData[0]) : [];\r\n\r\n // Reorder columnIds to match outputColumn order\r\n if (search && search.searchCriteria && search.searchCriteria.outputColumns) {\r\n const outputIds = search.searchCriteria.outputColumns.map(x => x.columnId);\r\n columnIds.sort((a, b) => {\r\n return outputIds.indexOf(+a.slice(1)) - outputIds.indexOf(+b.slice(1));\r\n });\r\n }\r\n\r\n const multiselectColDef = {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'rowId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n maxWidth: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n editable: false,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams\r\n } as ColDef;\r\n\r\n const columnProperties = columnIds.reduce((acc, x) => {\r\n const fieldId = +x.slice(1);\r\n if (isNaN(fieldId)) { return acc; }\r\n\r\n const field = this._smartSearchService.getFieldById(fieldId);\r\n if (!field) { return acc; }\r\n\r\n const baseColumn = this._columnBuilder.getColumnDefinition(x, field);\r\n\r\n acc.push(baseColumn);\r\n return acc;\r\n }, []);\r\n\r\n const columns = [\r\n multiselectColDef,\r\n ...columnProperties\r\n ];\r\n\r\n const tableDataWithRowIds = tableData.map((x, i) => ({ ...x, rowId: `_${i}` }));\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setRowData(tableDataWithRowIds);\r\n }\r\n\r\n private _clearTable(): void {\r\n if (!this._gridApi) { return; }\r\n\r\n this.gridTracker.clear();\r\n this._gridApi.setRowData([]);\r\n }\r\n\r\n private _exportToCsv(): void {\r\n const params = {\r\n fileName: `SMARTool - ${ moment().format()}`\r\n };\r\n\r\n this.gridOptions.api.exportDataAsCsv(params);\r\n }\r\n\r\n private async _exportToExcel(): Promise {\r\n this.exportToExcel.emit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows: RowNode[] = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map((x) => {\r\n return x.data.rowId;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n
\r\n \r\n
\r\n

\r\n Results\r\n \r\n

\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","
\r\n \r\n \r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n","import { Component, EventEmitter, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { AmplitudeEvent, ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { AdvancedSearchPersistenceService, AdvancedSearchResults, AdvancedSearchRouteParams, SavedSearchModel } from './advancedSearchPersistence.service';\r\nimport { BusyIndicatorService, SnackBarService } from '../../Busy-Indicator';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { SmartSearchService } from './smartSearch.service';\r\nimport { takeUntil } from 'rxjs/internal/operators/takeUntil';\r\nimport { Subject } from 'rxjs';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { ColumnFilterService } from '../../Common/AV-AS/Column-Filters/columnFilter.service';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { SMART_SEARCH_HELP } from './smartSearch.help';\r\n\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'smart-search',\r\n templateUrl: './smartSearch.component.html',\r\n styleUrls: ['./smartSearch.component.scss']\r\n})\r\nexport class SmartSearchComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _navigationService: UpgradeNavigationServiceHandler,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _columnFilterService: ColumnFilterService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _helpService: HelpService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _snackBarService: SnackBarService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService\r\n ) {}\r\n\r\n @Output() columnsExpandedValueHasBeenChanged: EventEmitter = new EventEmitter();\r\n\r\n routeParams: AdvancedSearchRouteParams;\r\n searchId: string;\r\n searchType: any;\r\n search: SavedSearchModel;\r\n searchResults: AdvancedSearchResults;\r\n\r\n hideCriteria: boolean;\r\n isSavedSearch: boolean;\r\n isSystemSearch: boolean;\r\n showPageTitle: boolean;\r\n columnsExpanded: boolean;\r\n excelDownloading: boolean;\r\n hasEditPermission: boolean;\r\n hasRyanPrivatePermission: boolean;\r\n haveAllSearchFields: boolean;\r\n invalidColumns = [];\r\n\r\n private readonly _REFINE_SEARCH_EVENT: AmplitudeEvent = { event: 'refine-smart-search-criteria', properties: { smartRefineCriteria: 'blue button' } };\r\n private _destroy$: Subject = new Subject();\r\n\r\n get noOutputColumns(): boolean {\r\n return this.search && (!this.search.searchCriteria || !this.search.searchCriteria.outputColumns || !this.search.searchCriteria.outputColumns.length);\r\n }\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(SMART_SEARCH_HELP);\r\n\r\n this.hasEditPermission = this._restrictService.isInRole(Roles.SYSTEMSEARCHESEDIT);\r\n this.hasRyanPrivatePermission = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSEDIT) ||\r\n this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n\r\n this.activate();\r\n\r\n this._advancedSearchPersistenceService.updateAdvancedSearch$.pipe(takeUntil(this._destroy$))\r\n .subscribe((data) => {\r\n if (this.searchId === data.searchId.toString()) {\r\n this.activate();\r\n }\r\n });\r\n\r\n this._advancedSearchPersistenceService.deleteAdvancedSearch$.pipe(takeUntil(this._destroy$))\r\n .subscribe((data) => {\r\n if (this.searchId === data.searchId.toString()) {\r\n this._advancedSearchPersistenceService.clearSearchData();\r\n this._navigationService.transitionTo('search', {}, { reload: true });\r\n }\r\n });\r\n\r\n this._advancedSearchPersistenceService.advancedSearch$.pipe(takeUntil(this._destroy$))\r\n .subscribe(search => this.search = search);\r\n\r\n this._advancedSearchPersistenceService.showCriteria$.pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.hideCriteria = !x);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._smartSearchService.cancelSearch();\r\n }\r\n\r\n activate(): void {\r\n this.invalidColumns = [];\r\n\r\n this.searchId = this._navigationService.getQuerystringParam('searchId');\r\n this.searchType = this._navigationService.getQuerystringParam('searchType');\r\n const filters = this._navigationService.getQuerystringParam('filters');\r\n\r\n this.routeParams = {\r\n searchId: +this.searchId,\r\n searchType: this.searchType,\r\n filters\r\n };\r\n\r\n if (this._advancedSearchPersistenceService.columnsExpanded != null) {\r\n this.columnsExpanded = this._advancedSearchPersistenceService.columnsExpanded;\r\n } else {\r\n this.columnsExpanded = false;\r\n this._advancedSearchPersistenceService.columnsExpanded = false;\r\n }\r\n }\r\n\r\n showCriteria(): void {\r\n this._productAnalyticsService.logSequenceEvent(this._REFINE_SEARCH_EVENT.event, 'click-smart-criteria-button');\r\n this._smartSearchService.cancelSearch();\r\n this._advancedSearchPersistenceService.showCriteria(true);\r\n this.excelDownloading = false;\r\n this.columnsExpanded = this._advancedSearchPersistenceService.columnsExpanded;\r\n this.updateSearchResults(null);\r\n }\r\n\r\n updateSearch(search: SavedSearchModel): void {\r\n this.search = search;\r\n }\r\n\r\n updateSearchResults(searchResults: AdvancedSearchResults): void {\r\n this.searchResults = searchResults;\r\n }\r\n\r\n cancelSearch(): void {\r\n this._smartSearchService.cancelSearch();\r\n }\r\n\r\n async executeSearch(): Promise {\r\n this._advancedSearchPersistenceService.setIsSearching(true);\r\n let uniqueID;\r\n\r\n const payloadCriteria = { ...this.search.searchCriteria };\r\n\r\n //WK-5012 - some situations have a blank frequentlyUsed, which is ignored by API, so account for that\r\n if(payloadCriteria.frequentlyUsed === undefined) {\r\n payloadCriteria.frequentlyUsed = false;\r\n }\r\n\r\n payloadCriteria.searchName = this.search.searchName;\r\n\r\n if (!payloadCriteria.searchName || payloadCriteria.searchName.trim() == '') {\r\n payloadCriteria.searchName = 'SMART Results';\r\n }\r\n\r\n else {\r\n payloadCriteria.searchName = payloadCriteria.searchName.replace(/[^a-z0-9_ \\-]/gi, '');\r\n }\r\n\r\n // just in case if there was nothing except special characters\r\n if (!payloadCriteria.searchName || payloadCriteria.searchName.trim() == '') {\r\n payloadCriteria.searchName = 'SMART Results';\r\n }\r\n\r\n //If excel output is selected, don't hide criteria or null results, just stay where we are\r\n if (this.search.searchCriteria.outputFormat !== 1) {\r\n this._advancedSearchPersistenceService.showCriteria(false);\r\n }\r\n\r\n payloadCriteria.outputColumns = _.chain(payloadCriteria.outputColumns)\r\n .map('columnId')\r\n .union(this._advancedSearchPersistenceService.hiddenColumns)\r\n .value();\r\n\r\n this._advancedSearchPersistenceService.hiddenColumns = [];\r\n\r\n payloadCriteria.filters = this._columnFilterService.prepareFilters(payloadCriteria.filters);\r\n\r\n payloadCriteria.outputInt = payloadCriteria.outputFormat;\r\n payloadCriteria.savedSearchID = this.searchId || null;\r\n\r\n // return search result for grid search or long running process for excel\r\n try {\r\n switch (payloadCriteria.outputInt) {\r\n case 0:\r\n const gridResult = await this._smartSearchService.executeSearch(payloadCriteria);\r\n this.searchResults = gridResult;\r\n this.searchResults.payloadCriteria = payloadCriteria;\r\n if (this.searchResults.dataTable && (this.searchResults.dataTable as unknown as any[]).length >= 50000) {\r\n this._toastr.warning('SMART Search', '50,000 records are shown; if you want to see all results please use the \"Excel\" output options.', { timeOut: 6000 });\r\n }\r\n\r\n //FOR TESTING\r\n this._advancedSearchPersistenceService.results = this.searchResults;\r\n this._advancedSearchPersistenceService.search = this.search;\r\n this._advancedSearchPersistenceService.routeParams = this.routeParams;\r\n this._advancedSearchPersistenceService.searchType = this.searchType;\r\n this._advancedSearchPersistenceService.showPageTitle = !this.searchType;\r\n this._advancedSearchPersistenceService.fromWidget = false;\r\n\r\n break;\r\n case 1:\r\n // saving xsls\r\n const busyRef = this._busyIndicatorService.show({\r\n message: 'Exporting search results'\r\n });\r\n\r\n this.excelDownloading = false;\r\n\r\n try {\r\n const lrpId = await this._smartSearchService.export(payloadCriteria);\r\n this._snackBarService.addById(lrpId, Compliance.LongRunningProcessTypeEnum.SmartSearchExport);\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n break;\r\n case 2:\r\n // saving csv\r\n const result = await this._smartSearchService.executeSearch(payloadCriteria);\r\n this.searchResults = null;\r\n this._advancedSearchPersistenceService.showCriteria(true);\r\n break;\r\n }\r\n } catch(err) {\r\n console.log(['Advanced search - Failure', err.message]);\r\n // error handler\r\n if (err.status === 0) {\r\n // $http timeout\r\n console.log('Advanced search - Failure - $http timeout');\r\n } else {\r\n // response error status from server\r\n console.log('Advanced search - Failure - response error status from server ');\r\n //warningService.warning(\"Smart Search\", \"The search has been cancelled\", 6000);\r\n this.searchResults = { payloadCriteria: payloadCriteria } as AdvancedSearchResults;\r\n\r\n this._advancedSearchPersistenceService.showCriteria(true);\r\n }\r\n return Promise.reject();\r\n } finally {\r\n this._advancedSearchPersistenceService.setIsSearching(false);\r\n }\r\n }\r\n\r\n getGridData(): void {\r\n this._productAnalyticsService.initiateSequenceEvent(this._REFINE_SEARCH_EVENT, ['click-smart-search-button', 'click-smart-criteria-button']);\r\n this._productAnalyticsService.logEvent('click-SMART-search-output', { smartOutput: 'web' });\r\n this.search.searchCriteria.outputFormat = 0;\r\n this.executeSearch();\r\n }\r\n\r\n async exportToExcel(): Promise {\r\n this._productAnalyticsService.logEvent('click-SMART-search-output', { smartOutput: 'excel' });\r\n this.search.searchCriteria.outputFormat = 1;\r\n this.excelDownloading = true;\r\n await this.executeSearch();\r\n this.excelDownloading = false;\r\n }\r\n}\r\n","\r\n {{model.fullName}}\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n Assessor List Extract\r\n \r\n \r\n
\r\n
\r\n Collector List Extract\r\n \r\n \r\n
\r\n
\r\n","import { Component, AfterViewInit, HostListener, ViewChild, ElementRef, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { StateService } from '../Common/States/States.Service';\r\nimport { AssessorCollectorService } from '../Assessor-Collector/assessor.collector.service';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { StateSummary } from '../Common/States/state.model';\r\nimport { UserService } from '../Account/user.service';\r\nimport { ProductAnalyticsService } from '../Common/Amplitude/productAnalytics.service';\r\nimport { TimerService } from '../UI-Lib/Utilities';\r\n\r\ndeclare const saveAs: any;\r\ndeclare const Datamap: any;\r\n\r\nexport interface StateTypeahead extends StateSummary {\r\n typeaheadVal: string;\r\n}\r\n\r\n@Component({\r\n selector: 'united-states',\r\n templateUrl: './states.component.html',\r\n styleUrls: ['./states.component.scss']\r\n})\r\nexport class UnitedStatesComponent implements OnInit, AfterViewInit {\r\n constructor(\r\n private readonly _stateService: StateService,\r\n private readonly _assessorCollectorService: AssessorCollectorService,\r\n private readonly _upgradeNavigationService: UpgradeNavigationServiceHandler,\r\n private readonly _userService: UserService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _timerService: TimerService\r\n ) {\r\n }\r\n\r\n @ViewChild('stateContainer', { static: true }) stateContainer: ElementRef;\r\n @ViewChild('unitedStates', { static: true }) unitedStates: ElementRef;\r\n\r\n states: StateTypeahead[];\r\n loadingCollectorList: boolean = false;\r\n loadingAssessorList: boolean = false;\r\n disableCollectorList: boolean = false;\r\n disableAssessorList: boolean = false;\r\n selected: string;\r\n\r\n private _map: any;\r\n private _mapHeight: any;\r\n private _navigatedFrom: string;\r\n private readonly _NAVIGATED_DASHBOARD: string = 'dashboard';\r\n\r\n @HostListener('window:resize', ['$event']) onResize(event) {\r\n this._resizeMap();\r\n }\r\n\r\n ngOnInit(): void {\r\n if (this._userService.getUser().isDemoUser){\r\n this.disableCollectorList = true;\r\n this.disableAssessorList = true;\r\n }\r\n\r\n this._navigatedFrom = this._stateService.navigatedFrom;\r\n this._stateService.navigatedFrom = null;\r\n\r\n this._getStates();\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this._timerService.setTimeout(() => {\r\n this._resizeMap();\r\n }, 100);\r\n }\r\n\r\n async downloadAssessorExtract(): Promise {\r\n this.loadingAssessorList = true;\r\n\r\n try {\r\n const result: Blob = await this._assessorCollectorService.getAssessorExtract();\r\n this._downloadFile(result, 'Assessor');\r\n if (this._navigatedFrom === this._NAVIGATED_DASHBOARD) {\r\n this._productAnalyticsService.logEvent('click-state-widget', { state: 'Assessor Extract' });\r\n }\r\n } finally {\r\n this.loadingAssessorList = false;\r\n }\r\n }\r\n\r\n async downloadCollectorExtract(): Promise {\r\n this.loadingCollectorList = true;\r\n\r\n try {\r\n const result: Blob = await this._assessorCollectorService.getCollectorExtract();\r\n this._downloadFile(result, 'Collector');\r\n if (this._navigatedFrom === this._NAVIGATED_DASHBOARD) {\r\n this._productAnalyticsService.logEvent('click-state-widget', { state: 'Collector Extract' });\r\n }\r\n } finally {\r\n this.loadingCollectorList = false;\r\n }\r\n }\r\n\r\n onStateSelect(e: any): void {\r\n this._upgradeNavigationService.go('state', { stateId: e.item.stateID });\r\n }\r\n\r\n private async _getStates(): Promise {\r\n const states = await this._stateService.getSummary();\r\n this.states = _.map(states, (state: StateTypeahead) => {\r\n // Hack since ngx-bootstrap doesn't currently support multiple typeaheadOptionFields\r\n state.typeaheadVal = `${state.fullName} ${state.abbr}`;\r\n return state;\r\n });\r\n }\r\n\r\n private _downloadFile(result: Blob, entity: string): void {\r\n const blob = new Blob([result], { type: 'text/csv' });\r\n\r\n saveAs(blob, `${entity } List Extract.csv`);\r\n }\r\n\r\n private _resizeMap(): void {\r\n const map = this.unitedStates.nativeElement;\r\n\r\n if (map) {\r\n map.innerHTML = '';\r\n this._mapHeight = this.unitedStates.nativeElement.clientHeight;\r\n this._updateMap();\r\n }\r\n }\r\n\r\n private _updateMap(): void {\r\n let width = window.innerWidth - 32; // 16px padding on each side\r\n let height = width * 0.55;\r\n if (height > this._mapHeight) {\r\n // set width and height to 11:6 aspect ratio\r\n width = this._mapHeight * 1.83;\r\n height = this._mapHeight;\r\n }\r\n\r\n this._map = new Datamap({\r\n scope: 'usa',\r\n element: this.unitedStates.nativeElement,\r\n geographyConfig: {\r\n popupOnHover: false,\r\n highlightFillColor: 'var(--ace-action)',\r\n highlightBorderColor: 'var(--ace-neutral-white)',\r\n highlightBorderWidth: 1\r\n },\r\n fills: {\r\n defaultFill: 'var(--ace-neutral-300)'\r\n },\r\n labelSize: 14,\r\n width,\r\n height,\r\n responsive: false,\r\n done: (datamap) => {\r\n datamap.svg.selectAll('.datamaps-subunit')\r\n .on('click', (geography) => {\r\n const state: StateTypeahead = _.find(this.states, {\r\n abbr: geography.id\r\n });\r\n\r\n if(state) {\r\n if (this._navigatedFrom === this._NAVIGATED_DASHBOARD) {\r\n this._productAnalyticsService.logEvent('click-state-widget', { state: state.abbr });\r\n }\r\n this._upgradeNavigationService.go('state', { stateId: state.stateID });\r\n } else {\r\n console.warn('State not found!');\r\n }\r\n });\r\n }\r\n });\r\n\r\n this._map.labels({ labelColor: '#3E4050', fontSize: 14 });\r\n }\r\n\r\n\r\n}\r\n","import { Component, OnInit, Input } from '@angular/core';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { AttachmentModalData } from '../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\n\r\n@Component({\r\n selector: 'state-details',\r\n templateUrl: './state.details.component.html',\r\n})\r\nexport class StateDetailsComponent implements OnInit {\r\n constructor(\r\n private readonly _restrictService: RestrictService\r\n ) { }\r\n\r\n @Input() state: Weissman.Model.Misc.State;\r\n\r\n hasWritePermission: boolean = false;\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.state) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: 'STATE',\r\n entityName: this.state.fullName,\r\n entityData: {\r\n typeId: Core.EntityTypes.State,\r\n id: this.state.stateID,\r\n name: this.state.fullName\r\n },\r\n readOnly: !this.hasWritePermission\r\n } as AttachmentModalData;\r\n }\r\n\r\n get commentsModel(): CommentModalData {\r\n if (!this.state) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityID: this.state.stateID,\r\n entityTypeID: Core.EntityTypes.State,\r\n description: `State: ${this.state.fullName}`,\r\n canEdit: this.hasWritePermission\r\n } as CommentModalData;\r\n }\r\n\r\n async ngOnInit() {\r\n this.hasWritePermission = this._restrictService.isInRole(Roles.STATEEDIT);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n

{{state.fullName}}

\r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\t\t
\r\n\t\t\t\r\n\t\t
\r\n\t
\r\n
\r\n\t\t
\r\n\t\t\t\r\n\t\t
\r\n\t
\r\n
\r\n\t\t
\r\n\t\t\t\r\n\t\t
\r\n\t
\r\n
\r\n\r\n","
\r\n
\r\n

Details

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Name:{{state.fullName}}
Abbr:{{state.abbr}}
Country:{{ state.country.name }}
Website:{{state.website}}
Personal Property Taxable:
Benchmark PP Tax Rate:{{state.benchmarkPPTaxRate | percent: '1.2'}}
Supplemental Tax Bills:
Land Comp FMV Fixed on Change:
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { StateService } from '../Common/States/States.Service';\r\nimport { BreadCrumb } from '../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { BusyIndicatorService } from '../Busy-Indicator';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\n\r\nexport interface ContactPanelEntityData {\r\n id: number;\r\n type: string;\r\n newAllowed: boolean;\r\n name: string;\r\n}\r\n\r\n@Component({\r\n selector: 'us-state',\r\n templateUrl: './us.state.component.html',\r\n})\r\nexport class USStateComponent implements OnInit {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _stateService: StateService\r\n ) {}\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n state: Weissman.Model.Misc.State;\r\n hasContactRoles: boolean = false;\r\n entity: ContactPanelEntityData;\r\n\r\n async ngOnInit() {\r\n this.breadcrumbs = [\r\n {\r\n name: 'States',\r\n target: 'states',\r\n options: { }\r\n }\r\n ];\r\n\r\n this._loadState();\r\n }\r\n\r\n private async _loadState() {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n const stateId = +this._upgradeNavigationServiceHandler.getQuerystringParam('stateId');\r\n this.state = await this._stateService.getById(stateId);\r\n\r\n // For angularjs contact panel\r\n this.entity = {\r\n id: this.state.stateID,\r\n type: 'state',\r\n newAllowed: false,\r\n name: this.state.fullName\r\n };\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BaseRepository } from '../../Common/Data/base.repository';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class SupportInstanceRepository extends BaseRepository{\r\n constructor(\r\n httpClient: HttpClient\r\n ) {\r\n super(httpClient);\r\n }\r\n\r\n private _pathPrefix = 'api/supportInstance';\r\n\r\n getList(): Observable {\r\n return this.httpGet(`${this._pathPrefix}/list`);\r\n }\r\n\r\n requestAccess(request: Core.SupportInstanceRequestModel): Observable {\r\n return this.httpPost(`${this._pathPrefix}/requestAccess`, request);\r\n }\r\n\r\n terminateAccess(instanceId: number): Observable {\r\n return this.httpPost(`${this._pathPrefix}/terminateAccess`, instanceId);\r\n }\r\n\r\n deactivateInstancePending(request: Core.SupportInstanceRequestModel): Observable {\r\n return this.httpPost(`${this._pathPrefix}/deactivateInstancePending`, request);\r\n }\r\n\r\n deactivateInstanceConfirm(request: Core.SupportInstanceRequestModel): Observable {\r\n return this.httpPost(`${this._pathPrefix}/deactivateInstanceConfirm`, request);\r\n }\r\n\r\n deactivateInstanceRevert(request: Core.SupportInstanceRequestModel): Observable {\r\n return this.httpPost(`${this._pathPrefix}/deactivateInstanceRevert`, request);\r\n }\r\n\r\n deactivationInfo(instanceId: number){\r\n return this.httpGet(`${this._pathPrefix}/deactivationInfo/${instanceId}`)\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n\r\n
\r\n
\r\n
\r\n {{userName}}\r\n
\r\n
\r\n REASON FOR REQUEST\r\n
\r\n
\r\n \r\n
\r\n
\r\n
Please enter the reason for which access is being requested. This is required to proceed.
\r\n
{{reasonLength}} / 500
\r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { SupportInstanceRepository } from '../../Compliance/Repositories/supportInstance.repository';\r\nimport { BusyIndicatorMessageManager } from '../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { UserService } from '../../Account/user.service';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\nexport interface SupportInstanceRequestAccessComponentParams {\r\n instanceId: number;\r\n}\r\n@Component({\r\n selector: 'support-instance-request-access',\r\n templateUrl: './supportInstanceRequestAccess.component.html',\r\n styleUrls: ['./supportInstanceRequestAccess.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class SupportInstanceRequestAccessComponent implements OnInit, OnDestroy, IWeissmanModalComponent{\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formBuilder: UntypedFormBuilder,\r\n private readonly _supportInstanceRepository: SupportInstanceRepository,\r\n private readonly _userService: UserService,\r\n private readonly _toastr: ToastrService\r\n ) {}\r\n\r\n params: SupportInstanceRequestAccessComponentParams;\r\n result: Core.SupportInstanceInfoModel;\r\n userName: string;\r\n reasonLength: number = 0;\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n form: UntypedFormGroup;\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this.form = this._formBuilder.group({\r\n reason: [null, [Validators.required, Validators.maxLength(500)]],\r\n });\r\n\r\n this.form.controls['reason'].valueChanges\r\n .pipe(takeUntil(this.destroy$))\r\n .subscribe(x => this.reasonLength = (x || '').length);\r\n\r\n const user = this._userService.getUser();\r\n this.userName = `${user.firstName} ${user.lastName}`;\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next();\r\n this.destroy$.unsubscribe();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgId = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgId);\r\n\r\n const request: Core.SupportInstanceRequestModel = {\r\n instanceId: this.params.instanceId,\r\n reason: this.form.get('reason').value\r\n };\r\n\r\n try {\r\n this.result = await lastValueFrom(this._supportInstanceRepository.requestAccess(request));\r\n this._bsModalRef.hide();\r\n\r\n this._toastr.success(`You now have access to ${this.result.instanceName} instance. You will need to logout and log back in to see it`);\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n onReasonChange(reason: string) {\r\n this.reasonLength = (reason || '').length;\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n\r\n
\r\n
\r\n
\r\n Please indicate why this instance is being deactivated.\r\n
\r\n
\r\n \r\n
\r\n
\r\n
Instance status will be changed to 'Pending Inactive' until confirmed.
\r\n
{{reasonLength}} / {{maxReasonLength}}
\r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { SupportInstanceRepository } from '../../Compliance/Repositories/supportInstance.repository';\r\nimport { BusyIndicatorMessageManager } from '../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { UserService } from '../../Account/user.service';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\nexport interface SupportInstanceDeactivateInstancePendingComponentParams {\r\n instanceId: number;\r\n}\r\n@Component({\r\n selector: 'support-instance-deactivate-instance-pending',\r\n templateUrl: './supportInstanceDeactivateInstancePending.component.html',\r\n styleUrls: ['./supportInstanceDeactivateInstancePending.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class SupportInstanceDeactivateInstancePendingComponent implements OnInit, OnDestroy, IWeissmanModalComponent{\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formBuilder: UntypedFormBuilder,\r\n private readonly _supportInstanceRepository: SupportInstanceRepository,\r\n private readonly _userService: UserService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _toastr: ToastrService\r\n ) {}\r\n\r\n params: SupportInstanceDeactivateInstancePendingComponentParams;\r\n result: Core.SupportInstanceInfoModel;\r\n reasonLength: number = 0;\r\n maxReasonLength: number = 1000;\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n form: UntypedFormGroup;\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this.form = this._formBuilder.group({\r\n reason: [null, [Validators.required, Validators.maxLength(this.maxReasonLength)]],\r\n });\r\n\r\n this.form.controls['reason'].valueChanges\r\n .pipe(takeUntil(this.destroy$))\r\n .subscribe(x => this.reasonLength = (x || '').length);\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next();\r\n this.destroy$.unsubscribe();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgId = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgId);\r\n\r\n const request: Core.SupportInstanceRequestModel = {\r\n instanceId: this.params.instanceId,\r\n reason: this.form.get('reason').value\r\n }\r\n\r\n try {\r\n this.result = await lastValueFrom(this._supportInstanceRepository.deactivateInstancePending(request));\r\n this._bsModalRef.hide();\r\n\r\n this._toastr.success(`The status of ${this.result.instanceName} instance was successfully changed to \"Pending Inactive\".`)\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n onReasonChange(reason: string) {\r\n this.reasonLength = (reason || '').length;\r\n }\r\n}\r\n"," 0\">\r\n\r\n\r\n\r\n
\r\n
\r\n
\r\n Please indicate why this instance is being deactivated.\r\n
\r\n
\r\n \r\n
\r\n
\r\n
Deactivation Initiated By: {{params.pendingUserName}} on {{params.pendingDateTime}}
\r\n
{{reasonLength}} / {{maxReasonLength}}
\r\n
\r\n
\r\n
\r\n
Instance will be deactivated.
\r\n
CSRs assigned to a consultant will be reassigned to the Client Account Handler, and all contacts will be removed.
\r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { SupportInstanceRepository } from '../../Compliance/Repositories/supportInstance.repository';\r\nimport { BusyIndicatorMessageManager } from '../../Busy-Indicator';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\n\r\nexport interface SupportInstanceDeactivateInstanceConfirmComponentParams {\r\n instanceId: number;\r\n pendingReason: string;\r\n pendingUserName: string;\r\n pendingDateTime: string;\r\n}\r\n@Component({\r\n selector: 'support-instance-deactivate-instance-confirm',\r\n templateUrl: './supportInstanceDeactivateInstanceConfirm.component.html',\r\n styleUrls: ['./supportInstanceDeactivateInstanceConfirm.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class SupportInstanceDeactivateInstanceConfirmComponent implements OnInit, OnDestroy, IWeissmanModalComponent{\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _formBuilder: UntypedFormBuilder,\r\n private readonly _supportInstanceRepository: SupportInstanceRepository,\r\n private readonly _toastr: ToastrService,\r\n private readonly _messageModalService: MessageModalService,\r\n ) {}\r\n\r\n params: SupportInstanceDeactivateInstanceConfirmComponentParams;\r\n result: Core.SupportInstanceInfoModel;\r\n reasonLength: number = 0;\r\n maxReasonLength: number = 1000;\r\n busyIndicatorMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n form: UntypedFormGroup;\r\n\r\n private destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this.form = this._formBuilder.group({\r\n reason: [null, [Validators.required, Validators.maxLength(this.maxReasonLength)]],\r\n });\r\n\r\n this.form.controls['reason'].valueChanges\r\n .pipe(takeUntil(this.destroy$))\r\n .subscribe(x => this.reasonLength = (x || '').length);\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next();\r\n this.destroy$.unsubscribe();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsgIdSaving = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgIdSaving);\r\n\r\n const request: Core.SupportInstanceRequestModel = {\r\n instanceId: this.params.instanceId,\r\n reason: this.form.get('reason').value,\r\n checkForOpenAppeals: true\r\n }\r\n\r\n try{\r\n this.result = await this.confirmDeactivateInstance(request);\r\n\r\n if (this.result.hasOpenAppeals == false) {\r\n this._toastr.success(`The ${this.result.instanceName} instance was successfully deactivated.`);\r\n this.busyIndicatorMessageManager.remove(busyMsgIdSaving);\r\n } else {\r\n var message = `\r\n This instance has open appeals. Are you sure you would like to continue?\r\n \r\n Open Appeals:\r\n ${this.result.openAppealNames.join('\\n')}`;\r\n \r\n try {\r\n await this._messageModalService.confirm(message, 'Warning');\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.busyIndicatorMessageManager.remove(busyMsgIdSaving);\r\n\r\n const busyMsgIdOpenAppeals = 'deactivate with open appeals';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgIdOpenAppeals);\r\n\r\n try{\r\n const requestTwo : Core.SupportInstanceRequestModel = {\r\n instanceId: this.params.instanceId,\r\n reason: this.form.get('reason').value,\r\n checkForOpenAppeals: false\r\n }\r\n\r\n this.result = await this.confirmDeactivateInstance(requestTwo);\r\n this._toastr.success(`The ${this.result.instanceName} instance was successfully deactivated.`)\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgIdOpenAppeals);\r\n }\r\n }\r\n } finally {\r\n this._bsModalRef.hide();\r\n }\r\n }\r\n\r\n private async confirmDeactivateInstance(request: Core.SupportInstanceRequestModel): Promise {\r\n return await lastValueFrom(this._supportInstanceRepository.deactivateInstanceConfirm(request));\r\n }\r\n\r\n async revert(): Promise {\r\n const busyMsgId = 'reverting';\r\n this.busyIndicatorMessageManager.add('Reverting', busyMsgId);\r\n\r\n const request: Core.SupportInstanceRequestModel = {\r\n instanceId: this.params.instanceId,\r\n reason: this.form.get('reason').value,\r\n }\r\n\r\n try {\r\n this.result = await lastValueFrom(this._supportInstanceRepository.deactivateInstanceRevert(request));\r\n this._bsModalRef.hide();\r\n\r\n this._toastr.success(`The ${this.result.instanceName} instance was successfully reactivated.`)\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n }\r\n\r\n onReasonChange(reason: string) {\r\n this.reasonLength = (reason || '').length;\r\n }\r\n}\r\n\r\n"," 0\">\r\n
\r\n
\r\n
\r\n

\r\n Support Instances\r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
InstanceCompanyStatusActions
\r\n {{ instance.instanceName }}\r\n \r\n {{ instance.topLevelCompanyName }}\r\n \r\n
\r\n \r\n \r\n

Deactivated by {{ instance.deactivationConfirmUserName }}\r\n on {{ instance.deactivationConfirmDate.toLocaleString() }}

\r\n

{{ instance.deactivationReason }}

\r\n
\r\n {{ getStatus(instance) }}\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { SupportInstanceRepository } from '../../Compliance/Repositories/supportInstance.repository';\r\nimport { BusyIndicatorMessageManager } from '../../Busy-Indicator';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { WeissmanDateTimeFormatPipe } from '../../UI-Lib/Pipes';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport {\r\n SupportInstanceRequestAccessComponent,\r\n SupportInstanceRequestAccessComponentParams\r\n} from '../Support-Instance-Request-Access/supportInstanceRequestAccess.component';\r\nimport {\r\n SupportInstanceDeactivateInstancePendingComponent,\r\n SupportInstanceDeactivateInstancePendingComponentParams\r\n} from '../Support-Instance-Deactivate-Instance-Pending/supportInstanceDeactivateInstancePending.component';\r\nimport {\r\n SupportInstanceDeactivateInstanceConfirmComponent,\r\n SupportInstanceDeactivateInstanceConfirmComponentParams\r\n} from '../Support-Instance-Deactivate-Instance-Confirm/supportInstanceDeactivateInstanceConfirm.component';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\ninterface SupportInstanceInfo extends Core.SupportInstanceInfoModel {\r\n isAccessTerminating: boolean;\r\n statusPopoverOpened: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'support-instance-list',\r\n templateUrl: './supportInstanceList.component.html',\r\n styleUrls: ['./supportInstanceList.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class SupportInstanceListComponent implements OnInit{\r\n \r\n constructor(\r\n private _supportInstanceRepository: SupportInstanceRepository,\r\n private _datePipe: WeissmanDateTimeFormatPipe,\r\n private _restrictService: RestrictService,\r\n private _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _toastr: ToastrService\r\n ){}\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n instances: SupportInstanceInfo[];\r\n userHasDeactivateInstancePermissions: boolean;\r\n excludeInactive: boolean;\r\n\r\n async ngOnInit(): Promise {\r\n if(!this._restrictService.isInRole(Roles.SUPPORT)) {\r\n this._routerService.go('unauthorizedAccess', {});\r\n return Promise.resolve();\r\n }\r\n\r\n this.excludeInactive = true;\r\n this.userHasDeactivateInstancePermissions = this._restrictService.isInRole(Roles.DEACTIVATEINSTANCE);\r\n\r\n await this.getSupportInstances();\r\n }\r\n\r\n refresh(){\r\n this.getSupportInstances();\r\n }\r\n\r\n async getSupportInstances(){\r\n const busyLoading = 'loading';\r\n this.busyIndicatorMessageManager.add('Loading', busyLoading);\r\n\r\n try {\r\n var result = await lastValueFrom(this._supportInstanceRepository.getList());\r\n\r\n if(this.excludeInactive){\r\n result = result.filter(x=>x.instanceActivationStatus != Core.InstanceActivationStatusEnum.ConfirmedInactive)\r\n }\r\n\r\n result.sort((a, b) => a.instanceName.localeCompare(b.instanceName));\r\n this.instances = result.map(x => x as SupportInstanceInfo);\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyLoading);\r\n }\r\n }\r\n\r\n getStatus(instance: Core.SupportInstanceInfoModel): string {\r\n if (instance.instanceActivationStatus == Core.InstanceActivationStatusEnum.PendingInactive){\r\n return 'Pending Inactive';\r\n }\r\n else if (instance.instanceActivationStatus == Core.InstanceActivationStatusEnum.ConfirmedInactive){\r\n return 'Inactive';\r\n }\r\n else{\r\n //instance activation status is active or no status sent to frontend\r\n return instance.accessGrantedDate ? `Initiated ${this._datePipe.transform(instance.accessGrantedDate, false, 'central')}` : 'Ready for Request';\r\n }\r\n }\r\n\r\n showDeactivateInstanceButton(instance: SupportInstanceInfo): boolean {\r\n return this.userHasDeactivateInstancePermissions && instance.instanceActivationStatus != Core.InstanceActivationStatusEnum.ConfirmedInactive;\r\n }\r\n\r\n showAccessInstanceButton(instance: SupportInstanceInfo): boolean {\r\n return !instance.accessGrantedDate && instance.instanceActivationStatus != Core.InstanceActivationStatusEnum.ConfirmedInactive;\r\n }\r\n\r\n async terminateAccess(instance: SupportInstanceInfo): Promise {\r\n const busyMsgId = 'terminating';\r\n this.busyIndicatorMessageManager.add('Terminating', busyMsgId);\r\n\r\n try {\r\n await lastValueFrom(this._supportInstanceRepository.terminateAccess(instance.instanceId));\r\n\r\n instance.isAccessTerminating = true;\r\n\r\n this._toastr.success(`You have initiated termination of your access to ${instance.instanceName}. Please log out and log back in to complete the process.`);\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgId);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async requestAccess(instance: SupportInstanceInfo): Promise {\r\n const params: SupportInstanceRequestAccessComponentParams = {\r\n instanceId: instance.instanceId\r\n };\r\n const result = await this._modalService.showAsync(SupportInstanceRequestAccessComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const instanceInfo = this.instances.find(x => x.instanceId == result.instanceId);\r\n instanceInfo.accessGrantedDate = result.accessGrantedDate;\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async deactivateInstance(instance: SupportInstanceInfo): Promise {\r\n if(instance.instanceActivationStatus == Core.InstanceActivationStatusEnum.PendingInactive){\r\n //step 2: user #2 confirms deactivation of instance\r\n const params: SupportInstanceDeactivateInstanceConfirmComponentParams = {\r\n instanceId: instance.instanceId,\r\n pendingReason: instance.deactivationReason,\r\n pendingUserName: instance.deactivationPendingUserName,\r\n pendingDateTime: instance.deactivationPendingDate.toLocaleDateString()\r\n }\r\n\r\n const result = await this._modalService.showAsync(SupportInstanceDeactivateInstanceConfirmComponent, params, 'modal-md');\r\n return Promise.resolve();\r\n }\r\n else{\r\n //step 1: user #1 begins deactivation process for instance\r\n const params: SupportInstanceDeactivateInstancePendingComponentParams = {\r\n instanceId: instance.instanceId\r\n }\r\n\r\n const result = await this._modalService.showAsync(SupportInstanceDeactivateInstancePendingComponent, params, 'modal-md');\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n updateStatusPopoverOpened(instance: SupportInstanceInfo, isMouseHovering: boolean) {\r\n instance.statusPopoverOpened = isMouseHovering && instance.instanceActivationStatus == Core.InstanceActivationStatusEnum.ConfirmedInactive;\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\n\r\nexport interface ActionViewOutputCustomParams {\r\n fromActionView: boolean;\r\n taskType: any;\r\n systemColumns: Core.AdvancedSearchField[];\r\n userColumns: any[];\r\n}\r\n\r\n@Component({\r\n selector: 'action-view-output-custom',\r\n template: `\r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class ActionViewOutputCustomComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _modalRef: BsModalRef) { }\r\n\r\n params: ActionViewOutputCustomParams;\r\n result: any[] = [];\r\n\r\n taskTypeName: string;\r\n category: any;\r\n\r\n ngOnInit() {\r\n this.taskTypeName = this.params.taskType.name == 'All' ? 'All Task Types' : this.params.taskType.name;\r\n\r\n const filterColumns = this.params.userColumns.length ? this.params.userColumns : this.params.systemColumns;\r\n this.category = {\r\n columns: _.chain(filterColumns)\r\n .map(x => {\r\n x.isRemovable = true;\r\n return x;\r\n })\r\n .sortBy('sequence')\r\n .value(),\r\n defaultColumns: this.params.systemColumns\r\n };\r\n }\r\n\r\n cancel(): void {\r\n this.result = undefined;\r\n this._modalRef.hide();\r\n }\r\n\r\n save(): void {\r\n if(this.category.columns.length) {\r\n const idProperty = this.category.columns[0].columnId ? 'columnId' : 'advancedSearchFieldID';\r\n const useSystem = _.xorBy(this.category.columns, this.category.defaultColumns, idProperty).length === 0;\r\n\r\n if(!useSystem || this.params.fromActionView) {\r\n this.result = _.map(this.category.columns, (col: any, i) => {\r\n col.sequence = i;\r\n return col;\r\n });\r\n }\r\n }\r\n\r\n this._modalRef.hide();\r\n }\r\n\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n Action View Output Defaults\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GridApi, GridOptions, GridReadyEvent, ColDef } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from '../../../Compliance/AgGrid';\r\nimport { ActionViewOutputDefaultsGridActionCellRendererComponent, ICellRendererParamsForActionViewOutputDefaultsGridAction } from './agGridActionCellRenderer.component';\r\nimport { ActionViewService } from '../action-view-service.upgrade';\r\nimport { ActionViewOutputCustomParams, ActionViewOutputCustomComponent } from '../Action-View-Output-Custom/actionViewOutputCustom.component';\r\nimport * as _ from 'lodash';\r\nimport { UserSettingsService } from '../../../Account/userSettings.service';\r\nimport { SmartSearchService } from '../../../Search/Advanced/smartSearch.service';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\n\r\n@Component({\r\n selector: 'action-view-output-defaults',\r\n templateUrl: './actionViewOutputDefaults.component.html',\r\n styleUrls: ['./actionViewOutputDefaults.component.scss']\r\n})\r\nexport class ActionViewOutputDefaultsComponent implements OnInit {\r\n constructor(\r\n private readonly _actionViewService: ActionViewService,\r\n private readonly _userSettingService: UserSettingsService,\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService) { }\r\n\r\n gridId: System.Guid = '7D885CAC-55F4-4CAE-AE56-B8948DE60508'; // need new guid\r\n isInitialized: boolean = false;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .build();\r\n\r\n refreshing: boolean;\r\n\r\n hasEditPermission: boolean = true;\r\n\r\n private _gridApi: GridApi;\r\n private _taskTypes: any[];\r\n private _taskTypeColumns: any[];\r\n\r\n async ngOnInit(): Promise {\r\n this.isInitialized = true;\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Task Type',\r\n field: 'name',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n sortable: false,\r\n width: AgGridColumns.textColumnWidth,\r\n cellStyle: params => {\r\n const taskType = params.data;\r\n\r\n return taskType.taskTypeID ? {marginLeft: '15px'} : {fontWeight: 'bold'};\r\n }\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: ActionViewOutputDefaultsGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n hasEditPermission: () => this.hasEditPermission,\r\n viewDetails: this._viewDetails.bind(this),\r\n } as ICellRendererParamsForActionViewOutputDefaultsGridAction\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.sizeColumnsToFit();\r\n this._refresh();\r\n }\r\n\r\n private async _viewDetails(params: ICellRendererParamsForActionViewOutputDefaultsGridAction): Promise {\r\n const selectedTaskType = params.data as any;\r\n\r\n const userSetting = this._userSettingService.getSettingsByGroup(12)[0] || {\r\n groupId: 12,\r\n name: 'Task View Output Defaults',\r\n value: '[]',\r\n id: 0\r\n };\r\n const customTaskTypes = typeof userSetting.value === 'string' ? JSON.parse(userSetting.value) : userSetting.value;\r\n const customTaskType = _.find(customTaskTypes, x => {\r\n return x.taskSeriesTypeID === selectedTaskType.taskSeriesTypeID && x.taskTypeID === selectedTaskType.taskTypeID;\r\n });\r\n\r\n const modalParams: ActionViewOutputCustomParams = {\r\n fromActionView: false,\r\n taskType: selectedTaskType,\r\n systemColumns: _.map(selectedTaskType.columnIds, x => {\r\n const column = _.find(this._taskTypeColumns, { columnId: x });\r\n\r\n return _.cloneDeep(column);\r\n }),\r\n userColumns: await this._getUserColumns(customTaskType)\r\n };\r\n\r\n const columns = await this._modalService.showAsync(ActionViewOutputCustomComponent, modalParams, '');\r\n\r\n if(!columns) {\r\n return;\r\n }\r\n\r\n if (columns.length) {\r\n const columnsToSave = _.map(columns, (filter, i) => {\r\n return {\r\n columnId: filter.columnId,\r\n sequence: i\r\n };\r\n });\r\n\r\n if (customTaskType) {\r\n const i = _.findIndex(customTaskTypes, (taskType: any) => {\r\n return taskType.taskSeriesTypeID === customTaskType.taskSeriesTypeID && taskType.taskTypeID === customTaskType.taskTypeID;\r\n });\r\n\r\n customTaskTypes[i].columns = columnsToSave;\r\n\r\n } else {\r\n customTaskTypes.push({\r\n taskSeriesTypeID: selectedTaskType.taskSeriesTypeID,\r\n taskTypeID: selectedTaskType.taskTypeID,\r\n columns: columnsToSave\r\n });\r\n }\r\n\r\n userSetting.value = JSON.stringify(customTaskTypes);\r\n this._saveUserSetting(userSetting);\r\n } else if (customTaskType) {\r\n _.remove(customTaskTypes, customTaskType);\r\n\r\n userSetting.value = customTaskTypes;\r\n this._saveUserSetting(userSetting);\r\n }\r\n\r\n }\r\n\r\n private async _getUserColumns(customTaskType): Promise {\r\n let userColumns = [];\r\n\r\n if (customTaskType) {\r\n const allFields = await this._smartSearchService.getAllFields(false);\r\n\r\n userColumns = _.map(_.cloneDeep(customTaskType.columns), (column: any) => {\r\n const fullColumn = _.cloneDeep(_.find(allFields, { advancedSearchFieldID: column.columnId }));\r\n _.assign(column, _.omit(fullColumn, 'sequence'));\r\n\r\n return column;\r\n });\r\n }\r\n\r\n return userColumns;\r\n }\r\n\r\n private async _saveUserSetting(userSetting): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating user setting' });\r\n\r\n try {\r\n await this._userSettingService.save(userSetting);\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n async refresh(): Promise {\r\n await this._refresh();\r\n }\r\n\r\n private async _refresh(): Promise {\r\n this.refreshing = true;\r\n\r\n this._taskTypes = [];\r\n\r\n try {\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n\r\n const result = await this._actionViewService.getTaskTypes();\r\n this._taskTypes = this._actionViewService.sortTaskTypes(result.taskTypes);\r\n this._taskTypeColumns = result.columns;\r\n\r\n } finally {\r\n this._gridApi && this._gridApi.hideOverlay();\r\n }\r\n\r\n this._setRowData();\r\n this.refreshing = false;\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._taskTypes)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._taskTypes);\r\n }\r\n}\r\n","import { TaxRateArea, TaxAuthority, TaxAuthorityDetail, TaxRateAreaTaxAuthorityDetail } from '../Assessor-Collector/Tax-Rates/tax.rates.panel.model';\r\nimport { CommonBulkUpdateFieldActionEnum } from '../constants.new';\r\nimport { ColDef } from 'ag-grid-community';\r\n\r\nexport type TaxAuthoritiesOrderBy = 'alpha' | 'manual';\r\n\r\nexport class TaxRateAreaPayload extends TaxRateArea {\r\n collectors: TaxRateAreaCollector[];\r\n}\r\n\r\nexport class TaxRateAreaCollector {\r\n name: string;\r\n collectorID: number;\r\n active: boolean;\r\n isTab: boolean;\r\n taxAuthorities: TaxAuthority[];\r\n}\r\n\r\nexport class TaxAuthorityPayload extends TaxAuthority {\r\n taxRateAreaInclusion: TaxRateAreaYears[];\r\n}\r\n\r\nexport class TaxRateAreaYears {\r\n taxRateAreaName: string;\r\n years: Map;\r\n}\r\n\r\nexport interface PanelProjectionsPayload {\r\n taxRateAreaId: number;\r\n collectorId: number;\r\n taxAuthorityId: number;\r\n taxAuthorityDefaultAnnualRateIncrease: number;\r\n details: TaxAuthorityDetail[];\r\n taxRateAreaTaxAuthorityDetails: TaxRateAreaTaxAuthorityDetail[];\r\n yearBegin: number;\r\n yearEnd: number;\r\n}\r\n\r\nexport class TaxAuthorityBulkUpdateContent {\r\n taxAuthorityCategoryId?: number;\r\n taxableAssessmentTypeId: number = 1;\r\n certificationMonth?: number;\r\n certificationDay?: number;\r\n certificationType?: number;\r\n obtainInAdvance: boolean = true;\r\n defaultAnnualIncrease: number = 0.0; // fraction. 0.02 for 2%\r\n taxYear: number = 0;\r\n yoyPercent: number = 0.0; // fraction. 0.02 for 2%\r\n}\r\n\r\nexport class TaxAuthorityBulkUpdateRequest extends TaxAuthorityBulkUpdateContent {\r\n categoryAction: CommonBulkUpdateFieldActionEnum = CommonBulkUpdateFieldActionEnum.NoChange;\r\n taxableAssessmentTypeAction: CommonBulkUpdateFieldActionEnum = CommonBulkUpdateFieldActionEnum.NoChange;\r\n certificationDateAction: CommonBulkUpdateFieldActionEnum = CommonBulkUpdateFieldActionEnum.NoChange;\r\n obtainInAdvanceAction: CommonBulkUpdateFieldActionEnum = CommonBulkUpdateFieldActionEnum.NoChange;\r\n defaultAnnualIncreaseAction: CommonBulkUpdateFieldActionEnum = CommonBulkUpdateFieldActionEnum.NoChange;\r\n yoyAction: CommonBulkUpdateFieldActionEnum = CommonBulkUpdateFieldActionEnum.NoChange;\r\n}\r\n\r\nexport enum TaxAuthoritySelectionType {\r\n Given = 1,\r\n All = 2,\r\n AllButGiven = 3\r\n}\r\n\r\n\r\n\r\nexport interface TaxAuthoritySelectionOptions {\r\n searchParams: CommandCenterSearchModel;\r\n selectionType: TaxAuthoritySelectionType;\r\n selectedTaxAuthorityIds: number[];\r\n}\r\n\r\nexport class TaxAuthorityToUpdate {\r\n taxAuthorityId: number;\r\n name: string;\r\n code: string;\r\n queueProcessingStatus: Core.QueueUpdateStatusEnum;\r\n}\r\n\r\nexport class TaxAuthorityUpdateResults {\r\n billClusterCount: number = 0;\r\n billCount: number = 0;\r\n paymentCount: number = 0;\r\n taxAuthorityCount: number = 0;\r\n}\r\n\r\nexport class TaxAuthorityBulkUpdateProgress extends TaxAuthorityUpdateResults {\r\n request: TaxAuthorityBulkUpdateRequest;\r\n\r\n currentIndex: number = 0;\r\n selections: TaxAuthorityToUpdate[] = [];\r\n\r\n reset() : void {\r\n this.currentIndex = 0;\r\n this.selections = [];\r\n this.billClusterCount = 0;\r\n this.billCount = 0;\r\n this.paymentCount = 0;\r\n this.taxAuthorityCount = 0;\r\n }\r\n}\r\n\r\nexport interface CommandCenterSearchModel extends Core.SearchModel {\r\n entityType: number;\r\n stateId: number;\r\n assessorId: number;\r\n collectorId: number;\r\n onlyPendingQC: boolean;\r\n}\r\n\r\nexport enum CommandCenterPropertyEnum {\r\n // both TaxRateArea and TaxAuthority\r\n Name = 1,\r\n Code = 2,\r\n Disabled = 3,\r\n Address = 4,\r\n HasComments = 5,\r\n HasAttachment = 6,\r\n MayBeDeleted = 7,\r\n AssessorName = 8,\r\n CollectorName = 9,\r\n QueueProcessingStatusName = 31,\r\n\r\n // TaxAuthority\r\n PtxId = 21,\r\n TaxAuthorityCategory = 22,\r\n TaxableAssessmentType = 23,\r\n ObtainInAdvance = 24,\r\n DefaultAnnualRateIncrease = 25,\r\n CertificationDate = 26,\r\n QcRequestTimeUtc = 29,\r\n QcRequestUserFullName = 30,\r\n TaxAuthorityId = 32\r\n}\r\n\r\nexport interface QcStateCount {\r\n item1: number //stateId\r\n item2: string //state name\r\n item3: number //QC Count\r\n}\r\n\r\nexport interface TaxRateDatatExportModel {\r\n columnsToReturn: Compliance.NameValuePair[];\r\n searchModel: Core.SearchModel;\r\n}\r\n","\r\n","import {Component, EventEmitter, Input, OnInit, Output} from '@angular/core';\r\nimport {CommonBulkUpdateFieldActionEnum} from '../../../constants.new';\r\n\r\n@Component({\r\n selector: 'tax-authority-bulk-update-action',\r\n templateUrl: './tax.authority.bulk.update.action.component.html',\r\n styles: ['select {width:120px}']\r\n})\r\nexport class TaxAuthorityBulkUpdateActionComponent implements OnInit {\r\n constructor() {\r\n this.possibleActions = [\r\n { name: 'No Change', value: CommonBulkUpdateFieldActionEnum.NoChange },\r\n { name: 'Change To', value: CommonBulkUpdateFieldActionEnum.ChangeTo },\r\n { name: 'Set to Blank', value: CommonBulkUpdateFieldActionEnum.SetToBlank }\r\n ];\r\n }\r\n\r\n @Input() fieldAction: CommonBulkUpdateFieldActionEnum;\r\n @Output() fieldActionChange = new EventEmitter();\r\n @Input() requiredField: boolean;\r\n @Input() disabled: boolean;\r\n\r\n possibleActions: Compliance.NameValuePair[];\r\n selectedAction: CommonBulkUpdateFieldActionEnum = CommonBulkUpdateFieldActionEnum.NoChange;\r\n\r\n ngOnInit(): void {\r\n if (this.requiredField) {\r\n this.possibleActions = this.possibleActions.filter(i => i.value !== CommonBulkUpdateFieldActionEnum.SetToBlank);\r\n }\r\n }\r\n\r\n fieldActionChanged(action: CommonBulkUpdateFieldActionEnum) : void {\r\n this.selectedAction = action;\r\n this.fieldActionChange.next(action);\r\n }\r\n\r\n isSelected(action: CommonBulkUpdateFieldActionEnum): boolean {\r\n return action === CommonBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n}","\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n \r\n /\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\n\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment';\r\nimport { Constants, CommonBulkUpdateFieldActionEnum } from '../../../constants.new';\r\nimport { TaxAuthorityToUpdate, TaxAuthorityBulkUpdateRequest } from '../../tax.rate.model';\r\nimport { Picklist } from '../../Tax-Authority/tax.authority.component';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\n@Component({\r\n selector: 'tax-authority-bulk-update-modal',\r\n templateUrl: './tax.authority.bulk.update.component.html',\r\n})\r\nexport class TaxAuthorityBulkUpdateComponent implements OnInit {\r\n constructor(\r\n private bsModalRef: BsModalRef,\r\n public constants: Constants,\r\n private toastr: ToastrService,\r\n private featureFlagsService: FeatureFlagsService\r\n ) { }\r\n\r\n onClose: (request?: TaxAuthorityBulkUpdateRequest) => void;\r\n selectedCount: number;\r\n selections: TaxAuthorityToUpdate[];\r\n\r\n headerLabel: string;\r\n taBulkUpdateRequest: TaxAuthorityBulkUpdateRequest;\r\n categories: Picklist[];\r\n taxableAssessments: Picklist[];\r\n certificationMonths: number[];\r\n certificationDays: number[];\r\n certificationTypes: Picklist[];\r\n selectableTaxYears: number[];\r\n defaultAnnualIncreaseDisplay: string;\r\n yoyPercentDisplay: string;\r\n enableTrueRateBasedSystem: boolean;\r\n\r\n ngOnInit() {\r\n this.taBulkUpdateRequest = new TaxAuthorityBulkUpdateRequest();\r\n this.enableTrueRateBasedSystem = this.featureFlagsService.featureFlags.enableTrueRateBasedSystem;\r\n\r\n this.headerLabel = `Bulk Update ${this.selectedCount} Tax Authorities`;\r\n\r\n this.certificationMonths = _.range(1, 13);\r\n this.certificationDays = _.range(1, 32);\r\n\r\n this.categories = _.map(this.constants.TaxAuthorityCategories, (names: any, id: number) => {\r\n return {\r\n label: names.displayName,\r\n id: Number(id)\r\n };\r\n });\r\n\r\n if (this.featureFlagsService.featureFlags.enableTrueRateBasedSystem) {\r\n this.taxableAssessments = _.map(this.constants.TaxableAssessmentTypesForTrueRate, (names: any, id: number) => {\r\n return {\r\n id: Number(id),\r\n label: `${names.displayName} ${names.extraDisplay}`\r\n };\r\n });\r\n }\r\n else {\r\n this.taxableAssessments = _.map(this.constants.TaxableAssessmentTypes, (names: any, id: number) => {\r\n return {\r\n id: Number(id),\r\n label: `${names.displayName} ${names.extraDisplay}`\r\n };\r\n });\r\n }\r\n\r\n this.certificationTypes = [{\r\n label: 'Prior Prior',\r\n id: -2\r\n }, {\r\n label: 'Prior',\r\n id: -1\r\n }, {\r\n label: 'Current',\r\n id: 0\r\n }, {\r\n label: 'Next',\r\n id: 1\r\n }, {\r\n label: 'Next Next',\r\n id: 2\r\n }];\r\n\r\n const currentYear: number = Number(moment().format('YYYY'));\r\n const years = _.range(currentYear - 10, currentYear + 6);\r\n this.selectableTaxYears = _.chain(years)\r\n .reverse()\r\n .value();\r\n this.taBulkUpdateRequest.taxYear = currentYear;\r\n\r\n this.defaultAnnualIncreaseDisplay = new Decimal(this.taBulkUpdateRequest.defaultAnnualIncrease).times(100).toFixed(4);\r\n this.yoyPercentDisplay = new Decimal(this.taBulkUpdateRequest.yoyPercent).times(100).toFixed(4);\r\n }\r\n\r\n isSaveable(): boolean {\r\n return (this.taBulkUpdateRequest.categoryAction !== CommonBulkUpdateFieldActionEnum.NoChange)\r\n || (this.taBulkUpdateRequest.taxableAssessmentTypeAction !== CommonBulkUpdateFieldActionEnum.NoChange)\r\n || (this.taBulkUpdateRequest.certificationDateAction !== CommonBulkUpdateFieldActionEnum.NoChange)\r\n || (this.taBulkUpdateRequest.obtainInAdvanceAction !== CommonBulkUpdateFieldActionEnum.NoChange)\r\n || (this.taBulkUpdateRequest.defaultAnnualIncreaseAction !== CommonBulkUpdateFieldActionEnum.NoChange)\r\n || (this.taBulkUpdateRequest.yoyAction !== CommonBulkUpdateFieldActionEnum.NoChange);\r\n }\r\n\r\n defaultAnnualIncreaseBlur(currentValue: string): void {\r\n if ( !this._isValidPercentage(this.defaultAnnualIncreaseDisplay) )\r\n {\r\n this.defaultAnnualIncreaseDisplay = '0.0';\r\n }\r\n this.defaultAnnualIncreaseDisplay = new Decimal(this.defaultAnnualIncreaseDisplay).toFixed(4);\r\n }\r\n\r\n yoyPercentBlur(currentValue: string): void {\r\n if ( !this._isValidPercentage(this.yoyPercentDisplay) )\r\n {\r\n this.yoyPercentDisplay = '0.0';\r\n }\r\n this.yoyPercentDisplay = new Decimal(this.yoyPercentDisplay).toFixed(4);\r\n }\r\n\r\n\r\n save() {\r\n // Validate Category selected if ChangeTo.\r\n if ( this.taBulkUpdateRequest.categoryAction === CommonBulkUpdateFieldActionEnum.ChangeTo &&\r\n !_.some(this.categories, ['id', this.taBulkUpdateRequest.taxAuthorityCategoryId]) )\r\n {\r\n this.toastr.error('A Category must be selected for \\'Change To\\' Action.', 'Cannot Save!');\r\n return;\r\n }\r\n // Validate all components of Certification Date selected if ChangeTo.\r\n if ( this.taBulkUpdateRequest.certificationDateAction === CommonBulkUpdateFieldActionEnum.ChangeTo &&\r\n (!this.taBulkUpdateRequest.certificationMonth ||\r\n !this.taBulkUpdateRequest.certificationDay ||\r\n !_.some(this.certificationTypes, ['id', this.taBulkUpdateRequest.certificationType])) )\r\n {\r\n this.toastr.error('All parts of Certification Date must be selected for \\'Change To\\' Action.', 'Cannot Save!');\r\n return;\r\n }\r\n\r\n // Convert string percent values to numeric percent values.\r\n if ( this.taBulkUpdateRequest.defaultAnnualIncreaseAction === CommonBulkUpdateFieldActionEnum.ChangeTo )\r\n {\r\n this.taBulkUpdateRequest.defaultAnnualIncrease = new Decimal(this.defaultAnnualIncreaseDisplay).dividedBy(100).toNumber();\r\n }\r\n if ( this.taBulkUpdateRequest.yoyAction === CommonBulkUpdateFieldActionEnum.ChangeTo )\r\n {\r\n this.taBulkUpdateRequest.yoyPercent = new Decimal(this.yoyPercentDisplay).dividedBy(100).toNumber();\r\n }\r\n\r\n this.bsModalRef.hide();\r\n\r\n this.onClose(this.taBulkUpdateRequest);\r\n }\r\n\r\n cancel() {\r\n this.bsModalRef.hide();\r\n\r\n this.onClose();\r\n }\r\n\r\n isDisabled(action: CommonBulkUpdateFieldActionEnum){\r\n return action !== CommonBulkUpdateFieldActionEnum.ChangeTo;\r\n }\r\n\r\n private _isValidPercentage(value: string | number): boolean {\r\n if (this._isInvalidNumber(value))\r\n return false;\r\n\r\n if (isNaN(Number(value)))\r\n return false;\r\n\r\n return true;\r\n }\r\n\r\n\r\n private _isInvalidNumber(value: string | number): boolean {\r\n return value === null || value === undefined || value === '' || value === '.';\r\n }\r\n\r\n}\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { TaxRateCommandCenterService } from './tax.rate.command.center.service';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../Compliance/AgGrid';\r\nimport { CommandCenterPropertyEnum, CommandCenterSearchModel } from '../tax.rate.model';\r\nimport { EntityType } from '../../constants.new';\r\n\r\nexport interface TaxRateDataSourceParams {\r\n entityType: number;\r\n stateId: number;\r\n assessorId: number;\r\n collectorId: number;\r\n onlyPendingQC: boolean;\r\n taxYearBegin: number;\r\n taxYearEnd: number;\r\n}\r\n\r\nexport class TaxRateCommandCenterAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private _gridApi: GridApi,\r\n private _taxRateCommandCenterService: TaxRateCommandCenterService,\r\n protected _dataSourceParamsFn: () => TaxRateDataSourceParams\r\n ) { super(_gridApi); }\r\n\r\n // All of the xxxx_1 names are from switching to Tax Rate Areas. Ag Grid considers these\r\n // to be separate fields, even though they're named the same. Probably a good thing, but\r\n // this is kind of hacky\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'name', value: CommandCenterPropertyEnum.Name },\r\n { name: 'name_1', value: CommandCenterPropertyEnum.Name },\r\n { name: 'code', value: CommandCenterPropertyEnum.Code },\r\n { name: 'code_1', value: CommandCenterPropertyEnum.Code },\r\n { name: 'disabled', value: CommandCenterPropertyEnum.Disabled },\r\n { name: 'disabled_1', value: CommandCenterPropertyEnum.Disabled },\r\n { name: 'address', value: CommandCenterPropertyEnum.Address },\r\n { name: 'address_1', value: CommandCenterPropertyEnum.Address },\r\n { name: 'assessorName', value: CommandCenterPropertyEnum.AssessorName },\r\n { name: 'assessorName_1', value: CommandCenterPropertyEnum.AssessorName },\r\n { name: 'collectorName', value: CommandCenterPropertyEnum.CollectorName },\r\n { name: 'collectorName_1', value: CommandCenterPropertyEnum.CollectorName },\r\n { name: 'hasComments', value: CommandCenterPropertyEnum.HasComments },\r\n { name: 'hasAttachments', value: CommandCenterPropertyEnum.HasAttachment },\r\n { name: 'ptxId', value: CommandCenterPropertyEnum.PtxId },\r\n { name: 'categoryName', value: CommandCenterPropertyEnum.TaxAuthorityCategory },\r\n { name: 'taxableAssessmentType', value: CommandCenterPropertyEnum.TaxableAssessmentType },\r\n { name: 'obtainInAdvance', value: CommandCenterPropertyEnum.ObtainInAdvance },\r\n { name: 'defaultAnnualRateIncrease', value: CommandCenterPropertyEnum.DefaultAnnualRateIncrease },\r\n { name: 'certificationDate', value: CommandCenterPropertyEnum.CertificationDate },\r\n { name: 'qcRequestTimeUtc', value: CommandCenterPropertyEnum.QcRequestTimeUtc },\r\n { name: 'qcRequestUserFullName', value: CommandCenterPropertyEnum.QcRequestUserFullName },\r\n { name: 'queueProcessingStatusName', value: CommandCenterPropertyEnum.QueueProcessingStatusName },\r\n { name: 'taxAuthorityId', value: CommandCenterPropertyEnum.TaxAuthorityId }\r\n ];\r\n\r\n getSearchModelWithoutPagination(){\r\n const searchParams: any = {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n entityType: this._dataSourceParams.entityType,\r\n stateId: this._dataSourceParams.stateId || null,\r\n assessorId: this._dataSourceParams.assessorId || null,\r\n collectorId: this._dataSourceParams.collectorId || null,\r\n yearBegin: this._dataSourceParams.taxYearBegin,\r\n yearEnd: this._dataSourceParams.taxYearEnd,\r\n onlyPendingQC: this._dataSourceParams.onlyPendingQC,\r\n };\r\n return searchParams;\r\n }\r\n\r\n getSearchModelForBulkUpdate(){\r\n const searchParams: CommandCenterSearchModel = {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n entityType: EntityType.TaxAuthority,\r\n stateId: this._dataSourceParams.stateId || null,\r\n assessorId: this._dataSourceParams.assessorId || null,\r\n collectorId: this._dataSourceParams.collectorId || null,\r\n // yearBegin: 0,\r\n // yearEnd: 0,\r\n onlyPendingQC: this._dataSourceParams.onlyPendingQC,\r\n };\r\n return searchParams;\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return this._dataSourceParams.stateId !== undefined;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: CommandCenterSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n entityType: this._dataSourceParams.entityType,\r\n stateId: this._dataSourceParams.stateId || null,\r\n assessorId: this._dataSourceParams.assessorId || null,\r\n collectorId: this._dataSourceParams.collectorId || null,\r\n // yearBegin: 0,\r\n // yearEnd: 0,\r\n onlyPendingQC: this._dataSourceParams.onlyPendingQC,\r\n // includeTotals: false,\r\n // includeOnlyTotals: false,\r\n // selectedRows: {\r\n // selectAllRows: false,\r\n // selectedRows: []\r\n // },\r\n // selectedRowProperty: null,\r\n // overrideFilterColumns: [],\r\n // advancedAssetFilters: null,\r\n // range: {\r\n // startId: 0,\r\n // endId: null\r\n // }\r\n\r\n };\r\n\r\n const result = await this._taxRateCommandCenterService.getList(searchParams);\r\n const data = this._dataSourceParams.entityType == EntityType.TaxAuthority ? result.taxAuthorities : result.taxRateAreas;\r\n\r\n if(this._dataSourceParams.entityType == EntityType.TaxRateArea) {\r\n this._taxRateCommandCenterService.allTaxAuthorities = result.taxAuthorities;\r\n }\r\n\r\n const dataSourceResult: AgGridDataSourceResult = {\r\n rows: data,\r\n totalRows: result.totalRows,\r\n lastModifiedTimestamp: new Date()\r\n };\r\n\r\n return dataSourceResult;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, ValueFormatterParams } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridDropdownCellEditor, AgGridFilterParams, AgGridOptionsBuilder } from '../../../Compliance/AgGrid';\r\nimport { DropdownCellEditorParams } from '../../../Compliance/AgGrid/CellEditors/agGridDropdownCellEditor.component';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { CompanySitePermissionsAgGridDataSource, CompanySitePermissionsDataSourceParams } from './companySitePermissionsAgGridDataSource';\r\nimport { PermissionService } from '../../permission.service';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport * as _ from 'lodash';\r\nexport interface CompanySitePermissionsParams {\r\n companyId: number;\r\n userId?: System.Guid;\r\n groupId?: number;\r\n editMode: boolean;\r\n saveRequest: Core.PermissionSaveRequest;\r\n}\r\n\r\nenum RightsDisplay {\r\n View = 'View',\r\n Edit = 'Edit',\r\n Hide = 'Hide'\r\n}\r\n\r\n@Component({\r\n selector: 'company-site-permissions',\r\n templateUrl: './companySitePermissions.component.html'\r\n})\r\nexport class CompanySitePermissionsComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _permissionService: PermissionService,\r\n private readonly _modalRef: BsModalRef,\r\n private _busyIndicatorService: BusyIndicatorService\r\n ) { }\r\n\r\n params: CompanySitePermissionsParams;\r\n result: Core.PermissionSaveRequest;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n singleClickEdit: true\r\n })\r\n .withContext(this)\r\n .withInfiniteScroll()\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n // .withFloatingFilter() Hiding for now until Access Level filtering works on the API\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: CompanySitePermissionsAgGridDataSource;\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'State',\r\n field: 'siteStateAbbr',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.stateAbbreviationColumnWidth\r\n },\r\n {\r\n headerName: 'Property #',\r\n field: 'siteProperty',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Name',\r\n field: 'entityName',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Access Level',\r\n field: 'rightsDropdown',\r\n sortable: false,\r\n headerTooltip: 'Sort is not available for this column.',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n editable: () => this.params.editMode,\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => [\r\n { name: RightsDisplay.View, value: RightsDisplay.View },\r\n { name: RightsDisplay.Edit, value: RightsDisplay.Edit },\r\n { name: RightsDisplay.Hide, value: RightsDisplay.Hide }\r\n ],\r\n cellChanged: (params: DropdownCellEditorParams, newValue: string) => {\r\n const permission = params.data as Core.PermissionModel;\r\n permission.readAllowed = newValue !== RightsDisplay.Hide;\r\n permission.writeAllowed = newValue === RightsDisplay.Edit;\r\n\r\n const alreadyUpdatedIdx = _.findIndex(this.params.saveRequest.updates, { entityID: permission.entityID });\r\n const alreadyDeletedIdx = _.findIndex(this.params.saveRequest.adds, { entityID: permission.entityID });\r\n const alreadyAddedIdx = _.findIndex(this.params.saveRequest.deletes, { entityID: permission.entityID });\r\n\r\n if(alreadyUpdatedIdx >= 0) {\r\n if(newValue === RightsDisplay.Hide) {\r\n _.pullAt(this.params.saveRequest.updates, alreadyUpdatedIdx);\r\n this.params.saveRequest.deletes.push(permission);\r\n } else {\r\n this.params.saveRequest.updates[alreadyUpdatedIdx] = permission;\r\n }\r\n } else if (alreadyDeletedIdx >= 0) {\r\n if(newValue !== RightsDisplay.Hide) {\r\n _.pullAt(this.params.saveRequest.deletes, alreadyDeletedIdx);\r\n this.params.saveRequest.updates.push(permission);\r\n }\r\n } else if (alreadyAddedIdx >= 0) {\r\n if(newValue === RightsDisplay.Hide) {\r\n _.pullAt(this.params.saveRequest.adds, alreadyAddedIdx);\r\n } else {\r\n this.params.saveRequest.adds[alreadyAddedIdx] = permission;\r\n }\r\n } else {\r\n // permission has not been edited yet\r\n\r\n if(permission.permissionID) {\r\n if(newValue === RightsDisplay.Hide) {\r\n this.params.saveRequest.deletes.push(permission);\r\n } else {\r\n this.params.saveRequest.updates.push(permission);\r\n }\r\n } else {\r\n this.params.saveRequest.adds.push(permission);\r\n }\r\n }\r\n\r\n }\r\n },\r\n valueGetter: this._getDropownPermission.bind(this)\r\n },\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'siteStateAbbr',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.sizeColumnsToFit();\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n save(): void {\r\n this.result = this.params.saveRequest;\r\n this._modalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._modalRef.hide();\r\n }\r\n\r\n private _getDropownPermission(params: ValueFormatterParams): string {\r\n const dbPermission = params.data as Core.PermissionModel;\r\n\r\n if(!dbPermission) {\r\n return '';\r\n }\r\n\r\n const inMemoryPermissions = _.flatten([this.params.saveRequest.adds, this.params.saveRequest.updates, this.params.saveRequest.deletes]);\r\n const p = _.find(inMemoryPermissions, { entityID: dbPermission.entityID }) || dbPermission;\r\n\r\n if (p.writeAllowed) {\r\n return RightsDisplay.Edit;\r\n } else if (p.readAllowed) {\r\n return RightsDisplay.View;\r\n } else {\r\n return RightsDisplay.Hide;\r\n }\r\n }\r\n\r\n private _setDataSource(): void {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const dataSourceParams = (): CompanySitePermissionsDataSourceParams => {\r\n return {\r\n companyId: this.params.companyId,\r\n groupId: this.params.groupId,\r\n userId: this.params.userId\r\n };\r\n };\r\n\r\n this._gridDataSource = new CompanySitePermissionsAgGridDataSource(this._gridApi, this._permissionService, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n }\r\n}\r\n","export enum CompanyPermissionOptions {\r\n ViewAllSites = 'View All Sites',\r\n ViewEditSomeSites = 'View/Edit Some Sites',\r\n EditAllSites = 'Edit All Sites'\r\n}","
\r\n
\r\n
\r\n

\r\n Tax Rate Command Center\r\n \r\n

\r\n
\r\n
\r\n
View:
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n

System-wide Tax Authority Rates Pending QC

\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
StateTax Authorities
{{state.item2}}\r\n {{state.item3}}\r\n
Total\r\n {{qcCountTotal}}\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n

Import Tax Rate Information

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Bulk Updating Tax Authorities

\r\n

Done

\r\n \r\n

{{getCurrentTABulkUpdateIdentity()}}

\r\n
\r\n
\r\n

Canceled

\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n {{bulkUpdateProgress.billClusterCount}}
\r\n \r\n {{bulkUpdateProgress.billCount}}
\r\n \r\n {{bulkUpdateProgress.paymentCount}}
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { BehaviorSubject, interval as observableInterval, Subscription } from 'rxjs';\r\nimport { startWith, switchMap } from 'rxjs/operators';\r\nimport { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { RestrictService, Roles } from '../../Common/Permissions/restrict.service';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { ColumnApi, GridReadyEvent, RowNode } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../Compliance/AgGrid';\r\nimport { TaxRateCommandCenterService } from './tax.rate.command.center.service';\r\nimport { TaxAuthority, TaxRateArea } from '../../Assessor-Collector/Tax-Rates/tax.rates.panel.model';\r\nimport { CommonBulkUpdateFieldActionEnum, Constants, EntityType } from '../../constants.new';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { GridSource, TaxRateGridComponent } from '../tax.rate.grid.component';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { TaxAuthorityBulkUpdateComponent } from './Tax-Authority-Bulk-Update/tax.authority.bulk.update.component';\r\nimport {\r\n QcStateCount,\r\n TaxAuthorityBulkUpdateProgress,\r\n TaxAuthorityBulkUpdateRequest,\r\n TaxAuthoritySelectionOptions,\r\n TaxAuthoritySelectionType,\r\n TaxAuthorityToUpdate,\r\n TaxAuthorityUpdateResults,\r\n TaxRateDatatExportModel\r\n} from '../tax.rate.model';\r\nimport { TaxRateCommandCenterAgGridDataSource, TaxRateDataSourceParams } from './agGridDataSource';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport {\r\n ICellRendererParamsForTaxRateCommandCenterComments,\r\n TaxRateCommandCenterCommentsCellRendererComponent\r\n} from './agGridCommentsCellRenderer.component';\r\nimport {\r\n ICellRendererParamsForTaxRateCommandCenterAttachments,\r\n TaxRateCommandCenterAttachmentsCellRendererComponent\r\n} from './agGridAttachmentsCellRenderer.component';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../Compliance/AgGrid/ToolPanel/models';\r\nimport { WeissmanDateFormatPipe } from '../../UI-Lib/Pipes';\r\nimport { OrderedColDef } from '../../Common/AgGrid/ag.grid.model';\r\nimport * as _ from 'lodash';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport { AssetSummary } from '../../Compliance/Asset/Models/assetSummary';\r\nimport { FeatureFlagsService } from 'src/app/Common/FeatureFlags/feature-flags-service';\r\n\r\ninterface SelectedRowInfo {\r\n entityId: number;\r\n queueProcessingStatus: Core.QueueUpdateStatusEnum;\r\n}\r\n\r\n@Component({\r\n selector: 'tax-rate-command-center',\r\n templateUrl: './tax.rate.command.center.component.html',\r\n styleUrls: ['./tax.rate.command.center.component.scss']\r\n})\r\nexport class TaxRateCommandCenterComponent extends TaxRateGridComponent implements OnInit, OnDestroy {\r\n constructor(\r\n public taxRateCommandCenterService: TaxRateCommandCenterService,\r\n private modalService: BsModalService,\r\n private constants: Constants,\r\n private messageBoxService: MessageBoxService,\r\n private toastr: ToastrService,\r\n private _datePipe: WeissmanDateFormatPipe,\r\n private restrictService: RestrictService,\r\n private featureFlagsService: FeatureFlagsService) {\r\n super(taxRateCommandCenterService, restrictService, modalService);\r\n this.hasDataImportPermission = restrictService.isInRole(Roles.ALLOWDATAIMPORTS);\r\n }\r\n\r\n isMaximized: boolean = false;\r\n hasDataImportPermission: boolean = false;\r\n\r\n stateAssessors: Compliance.NameValuePair[] = [];\r\n stateCollectors: Compliance.NameValuePair[] = [];\r\n assessorCollectors: Compliance.NameValuePair[] = [];\r\n assessorsCollectorsLoading: boolean = false;\r\n\r\n selectedStateId: number;\r\n selectedAssessorId: number;\r\n selectedCollectorId: number;\r\n onlyPendingQC: boolean;\r\n\r\n gridId: System.Guid;\r\n gridTracker: AgGridMultiSelectTracker;\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n pendingQcStateCounts: QcStateCount[] = [];\r\n qcCountTotal: number;\r\n qcCountsUpdating: boolean = false;\r\n\r\n bulkUpdateInProgress: boolean = false;\r\n bulkUpdateCanceled: boolean = false;\r\n bulkUpdateProgress: TaxAuthorityBulkUpdateProgress = new TaxAuthorityBulkUpdateProgress();\r\n showBulkUpdateRecalcSummary: boolean = false;\r\n\r\n LARGE_BULK_UPDATE_THRESHOLD: number = 100;\r\n\r\n selectedNode: RowNode;\r\n columnApi: ColumnApi;\r\n\r\n gridOptions = new AgGridOptionsBuilder(\r\n {\r\n suppressScrollOnNewData: true,\r\n onRowClicked: (params) => {\r\n if(!params.data || this.qcCountsUpdating) {\r\n return;\r\n }\r\n\r\n this.selectedNode = params.node;\r\n\r\n if(this.selectedGridSourceOption == 'areas') {\r\n this.launchTaxRateAreaModal(params.data.taxRateAreaId, false);\r\n } else {\r\n this.launchTaxAuthorityModal(params.data.taxAuthorityId, false);\r\n }\r\n },\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n onColumnVisible: () => {\r\n this.columnApi.autoSizeAllColumns();\r\n }\r\n\r\n // rowClassRules: {\r\n // 'ag-row-selected': (params) => {\r\n // if(!params.data) {\r\n // return false;\r\n // }\r\n\r\n // const entityId = this.selectedGridSourceOption == 'areas' ? params.data.taxRateAreaId : params.data.taxAuthorityId;\r\n // return this.gridTracker.isRowSelected(entityId)\r\n // }\r\n // }\r\n })\r\n .withColumnPinning()\r\n .withDefault(this).withSort().build();\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[]): Promise => {\r\n const searchParams = this._gridDataSource.getSearchModelWithoutPagination();\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: this._gridDataSource.totalRows\r\n };\r\n const exportModel = { searchModel: searchParams, columnsToReturn: columnsToReturn } as TaxRateDatatExportModel;\r\n const longRunningProcessId = await this.taxRateCommandCenterService.exportTaxRateData(exportModel);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportTaxRates };\r\n },\r\n canCancel: true\r\n };\r\n enableTrueRateBasedSystem: boolean;\r\n\r\n private readonly _TAX_AUTHORITIES_GRID_ID: System.Guid = 'E73E3CB3-2AD9-43F5-9DA1-645272848A80';\r\n private readonly _TAX_RATE_AREAS_GRID_ID: System.Guid = '065A0AD6-98E4-41B7-84CE-2857CBA47777';\r\n private _gridMultiSelectSub: Subscription;\r\n private _gridDataSource: TaxRateCommandCenterAgGridDataSource;\r\n private _qcCountSub: Subscription;\r\n private _selectedEntitiesInfo: SelectedRowInfo[] = [];\r\n private _agGridReady: boolean;\r\n\r\n async ngOnInit() {\r\n this.gridId = this._TAX_AUTHORITIES_GRID_ID;\r\n this.enableTrueRateBasedSystem = this.featureFlagsService.featureFlags.enableTrueRateBasedSystem;\r\n this._qcCountSub = observableInterval(60000).pipe(\r\n startWith(0),\r\n switchMap(() => {\r\n this.qcCountsUpdating = true;\r\n return this.taxRateCommandCenterService.getPendingQcCounts();\r\n }))\r\n .subscribe(data => {\r\n this.qcCountsUpdating = false;\r\n this.pendingQcStateCounts = data;\r\n\r\n this._getQcCountTotal();\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n this._qcCountSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent) {\r\n this.gridApi = event.api;\r\n this.columnApi = event.columnApi;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(async () => {\r\n const isBulkUpdateVisible = this.selectedGridSourceOption == 'authorities' && this.gridTracker.getSelectedRowsCount() > 1;\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n\r\n const selectedRowsModel = this.gridTracker.getSelectedRowsModel();\r\n if (selectedRowsModel.selectAllRows) {\r\n await this._getGridRowIds(0, 0);\r\n } else {\r\n this._selectedEntitiesInfo = this._gridDataSource.getShownRows()\r\n .filter(x => selectedRowsModel.selectedRows.indexOf(x.taxAuthorityId) !== -1)\r\n .map(x => {\r\n return {\r\n entityId: x.taxAuthorityId,\r\n queueProcessingStatus: x.queueProcessingStatus\r\n } as SelectedRowInfo;\r\n });\r\n }\r\n });\r\n\r\n if (!this._agGridReady) {\r\n this.gridApi.setColumnDefs(this.getGridColumns());\r\n }\r\n this._agGridReady = true;\r\n\r\n this._setDataSource();\r\n }\r\n\r\n toggleMaximize(isMaximized: boolean): void {\r\n this.isMaximized = isMaximized;\r\n }\r\n\r\n gridSourceSelected(gridSource: GridSource): void {\r\n if (this.selectedGridSourceOption === gridSource) {\r\n return;\r\n }\r\n this._changeGridSource(gridSource);\r\n this._refreshDataSource();\r\n }\r\n\r\n filterGridByStateAndQc(stateId:number) {\r\n this.selectedStateId = stateId;\r\n this.onlyPendingQC = true;\r\n\r\n if(this.selectedGridSourceOption == 'areas') {\r\n this._changeGridSource('authorities');\r\n }\r\n\r\n this.stateSelected();\r\n }\r\n\r\n async refreshQcCounts() {\r\n this.qcCountsUpdating = true;\r\n this.gridApi.showLoadingOverlay();\r\n\r\n this.pendingQcStateCounts = await this.taxRateCommandCenterService.getPendingQcCounts();\r\n this._getQcCountTotal();\r\n\r\n this.gridApi.hideOverlay();\r\n this.qcCountsUpdating = false;\r\n }\r\n\r\n async stateSelected(): Promise {\r\n if(!this.selectedStateId) {\r\n this.stateAssessors = this.stateCollectors = [];\r\n } else {\r\n this.assessorsCollectorsLoading = true;\r\n\r\n Promise.all(\r\n [\r\n this.taxRateCommandCenterService.getAssessors(this.selectedStateId),\r\n this.taxRateCommandCenterService.getCollectors(this.selectedStateId)\r\n ]\r\n ).then(([assessors, collectors]) => {\r\n this.stateAssessors = assessors\r\n .sort(this._abbrSort)\r\n .map((a) => ({ name: `${a.abbr} ${(a.municipalityName) ? a.municipalityName : ''}`, value: a.assessorID }));\r\n\r\n this.stateCollectors = collectors\r\n .sort(this._abbrSort)\r\n .map((a) => ({ name: `${a.abbr}`, value: a.collectorID }));\r\n\r\n this.assessorsCollectorsLoading = false;\r\n });\r\n }\r\n\r\n this.selectedAssessorId = null;\r\n this.selectedCollectorId = null;\r\n\r\n this._refreshDataSource();\r\n }\r\n\r\n async assessorSelected(): Promise {\r\n this.selectedCollectorId = null;\r\n this._refreshDataSource();\r\n\r\n if(!this.selectedAssessorId) {\r\n this.assessorCollectors = [];\r\n\r\n return;\r\n }\r\n this.assessorsCollectorsLoading = true;\r\n\r\n const collectorAssociations = await this.taxRateCommandCenterService.getCollectors(this.selectedStateId, this.selectedAssessorId);\r\n\r\n this.assessorCollectors = collectorAssociations\r\n .sort(this._abbrSort)\r\n .map((a) => ({ name: `${a.abbr}`, value: a.collectorID }));\r\n\r\n this.assessorsCollectorsLoading = false;\r\n }\r\n\r\n collectorSelected() {\r\n this._refreshDataSource();\r\n }\r\n\r\n showTaxYearChangedCC() {\r\n this.showTaxYearChanged();\r\n this._refreshDataSource();\r\n }\r\n\r\n onlyPendingQCChanged() {\r\n this._refreshDataSource();\r\n }\r\n\r\n async bulkUpdate() {\r\n // Retrieve the selected Tax Authoriites.\r\n // This involves an API call that mirrors the grid population query, so that\r\n // the Tax Authorities can be retrieved for the All, and All but Given (exclusion)\r\n // selection use cases.\r\n const selections: TaxAuthorityToUpdate[] = await this.gatherBulkUpdateSelections();\r\n if ( selections.length === 0 ) {\r\n return;\r\n }\r\n\r\n const initialState = {\r\n selectedCount: selections.length\r\n };\r\n const modalRef = this.modalService.show(TaxAuthorityBulkUpdateComponent, {initialState, class: 'modal-lg', ignoreBackdropClick: true});\r\n\r\n modalRef.content.onClose = (request?: TaxAuthorityBulkUpdateRequest) => {\r\n this.processBulkUpdateRequest(selections, request);\r\n };\r\n }\r\n\r\n async gatherBulkUpdateSelections(): Promise {\r\n // Retrieve list of selected Tax Authority identities to be Bulk Updated.\r\n const rowsSelectionModel: any = this.gridTracker.getSelectedRowsModel();\r\n const selectionOptions: TaxAuthoritySelectionOptions = {\r\n searchParams: this._gridDataSource.getSearchModelForBulkUpdate(),\r\n selectionType: rowsSelectionModel.selectAllRows\r\n ? (rowsSelectionModel.selectedRows.length > 0\r\n ? TaxAuthoritySelectionType.AllButGiven\r\n : TaxAuthoritySelectionType.All)\r\n : TaxAuthoritySelectionType.Given,\r\n selectedTaxAuthorityIds: rowsSelectionModel.selectedRows\r\n };\r\n console.log(`Gathering Tax Authority Selections (${selectionOptions.selectedTaxAuthorityIds.length}): ${JSON.stringify(selectionOptions)}`);\r\n\r\n const selections: TaxAuthorityToUpdate[] = await this.taxRateCommandCenterService.getTaxAuthoritySelectionsForBulkUpdate(selectionOptions);\r\n console.log(`Tax Authority Selections (${selections.length}): ${JSON.stringify(selections)}`);\r\n\r\n // If Selected count is less than threshold for \"an awful lot\", just proceed.\r\n if ( selections.length < this.LARGE_BULK_UPDATE_THRESHOLD ) {\r\n return selections;\r\n }\r\n\r\n // Confirm with the user to Builk Update that many Tax Authorities.\r\n const answer: number = await this.messageBoxService.open({\r\n message: `Are you sure you want to Bulk Update ${selections.length} Tax Authorities?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n\r\n if ( answer === MessageBoxResult.OK ) {\r\n return selections;\r\n }\r\n\r\n // Canceled Bulk Update, return no selections.\r\n console.log('Bulk Update confirmation canceled');\r\n return [];\r\n }\r\n\r\n refresh() {\r\n this._refreshDataSource();\r\n\r\n this._refreshAssessorCollectors();\r\n }\r\n\r\n executeBulkUpdate(): void {\r\n // RECURSIVE function\r\n if ( !this.bulkUpdateInProgress || this.bulkUpdateCanceled ||\r\n this.isBulkUpdateDone() ) {\r\n // Bulk Update complete or canceled.\r\n return;\r\n }\r\n\r\n const cur = this.getCurrentTABulkUpdateSelection();\r\n this.taxRateCommandCenterService.applyBulkUpdateToTaxAuthority(cur.taxAuthorityId, this.bulkUpdateProgress.request)\r\n .then((results: TaxAuthorityUpdateResults) => {\r\n console.log(`Bulk Updated Tax Authority ${this.getCurrentTABulkUpdateIdentity()}: ${JSON.stringify(results)}`);\r\n\r\n this.bulkUpdateProgress.billClusterCount += results.billClusterCount;\r\n this.bulkUpdateProgress.billCount += results.billCount;\r\n this.bulkUpdateProgress.paymentCount += results.paymentCount;\r\n\r\n this.bulkUpdateProgress.currentIndex++;\r\n\r\n this.executeBulkUpdate();\r\n })\r\n .catch((err:any) => {\r\n if ( this.bulkUpdateInProgress )\r\n {\r\n console.log(`Bulk Update FAILED for Tax Authority ${this.getCurrentTABulkUpdateIdentity()}: ${JSON.stringify(err)}`);\r\n\r\n this.toastr.error(err.message, 'Bulk Update FAILED!');\r\n\r\n this.cancelBulkUpdate();\r\n }\r\n });\r\n }\r\n\r\n cancelBulkUpdate() {\r\n // Switch page to Bulk Updte Canceled display\r\n this.bulkUpdateCanceled = true;\r\n }\r\n\r\n endBulkUpdate() {\r\n // Switch page back to normal Command Center display\r\n this.bulkUpdateCanceled = false;\r\n this.bulkUpdateInProgress = false;\r\n this.bulkUpdateProgress.reset();\r\n\r\n // Refresh grid with applied updates.\r\n this.refresh();\r\n }\r\n\r\n isBulkUpdateDone() : boolean {\r\n return this.bulkUpdateProgress.currentIndex >= this.bulkUpdateProgress.selections.length;\r\n }\r\n\r\n getCurrentTABulkUpdateSelection() : TaxAuthorityToUpdate | null {\r\n let cur: TaxAuthorityToUpdate = null;\r\n\r\n if ( this.bulkUpdateProgress.currentIndex < this.bulkUpdateProgress.selections.length )\r\n {\r\n cur = this.bulkUpdateProgress.selections[this.bulkUpdateProgress.currentIndex];\r\n }\r\n return cur;\r\n }\r\n\r\n getCurrentTABulkUpdateIdentity() : string {\r\n let identity: string = '';\r\n\r\n const cur = this.getCurrentTABulkUpdateSelection();\r\n if ( cur )\r\n {\r\n identity = `[${this.bulkUpdateProgress.currentIndex + 1} of ${this.bulkUpdateProgress.selections.length}] ${cur.name} (${cur.code})`;\r\n }\r\n return identity;\r\n }\r\n\r\n get isRetryDisabled(): boolean {\r\n const isDisabled = this._selectedEntitiesInfo.length === 0 ||\r\n this._selectedEntitiesInfo.some(x => x.queueProcessingStatus !== Core.QueueUpdateStatusEnum.Error);\r\n return isDisabled;\r\n }\r\n\r\n get isRetryVisible(): boolean {\r\n return this.selectedGridSourceOption !== 'areas';\r\n }\r\n\r\n async retry(): Promise {\r\n const taxAuthorityIds = this._selectedEntitiesInfo.map(x => x.entityId);\r\n await this.taxRateCommandCenterService.retryProcessingTaxAuthorities(taxAuthorityIds);\r\n\r\n const retriedNodes: RowNode[] = [];\r\n this.gridApi.forEachNode(x => {\r\n const gridRow = x.data as TaxAuthority;\r\n if (gridRow.taxAuthorityId && taxAuthorityIds.indexOf(gridRow.taxAuthorityId) !== -1) {\r\n gridRow.queueProcessingStatusId = Core.QueueUpdateStatusEnum.Queued;\r\n gridRow.queueProcessingStatusName = 'Requested, Pending';\r\n retriedNodes.push(x);\r\n }\r\n });\r\n\r\n this.gridApi.redrawRows({rowNodes: retriedNodes});\r\n\r\n this.gridTracker.clear();\r\n this._selectedEntitiesInfo = [];\r\n }\r\n\r\n protected processBulkUpdateRequest(selections: TaxAuthorityToUpdate[], request?: TaxAuthorityBulkUpdateRequest) : void {\r\n if ( request )\r\n {\r\n // Only show bill recalc summary if a field that affects it is changed.\r\n this.showBulkUpdateRecalcSummary = (request.taxableAssessmentTypeAction == CommonBulkUpdateFieldActionEnum.ChangeTo ||\r\n request.defaultAnnualIncreaseAction == CommonBulkUpdateFieldActionEnum.ChangeTo ||\r\n request.yoyAction == CommonBulkUpdateFieldActionEnum.ChangeTo);\r\n\r\n // Switch page to Bulk Update Progress display\r\n this.bulkUpdateInProgress = true;\r\n this.bulkUpdateCanceled = false;\r\n this.bulkUpdateProgress.reset();\r\n this.bulkUpdateProgress.selections = selections;\r\n this.bulkUpdateProgress.request = request;\r\n\r\n console.log(`Tax Authority Bulk Updates to apply: ${JSON.stringify(this.bulkUpdateProgress.request)}`);\r\n console.log(`Tax Authorities to Bulk Update: ${JSON.stringify(this.bulkUpdateProgress.selections)}`);\r\n\r\n // Execute Bulk Update\r\n this.executeBulkUpdate();\r\n }\r\n }\r\n\r\n protected loadPanel(entity: TaxRateArea | TaxAuthority): void {\r\n if(entity) {\r\n // this.selectedNode.setData(entity);\r\n this.refresh();\r\n }\r\n }\r\n\r\n protected getSharedColumns(): OrderedColDef[] {\r\n return [{\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: this.selectedGridSourceOption == 'areas' ? 'taxRateAreaId' : 'taxAuthorityId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n lockVisible: true,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n resizable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n sequence: 0\r\n }, {\r\n headerName: 'Code',\r\n field: 'code',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n sequence: 2\r\n }, {\r\n headerName: 'Address',\r\n field: 'address',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const entity = params.data as TaxAuthority | TaxRateArea;\r\n if(!entity || !entity.address) {\r\n return '';\r\n }\r\n\r\n const address = entity.address;\r\n let addressString: string = '';\r\n\r\n addressString += address.address1 ? `${address.address1},` : '';\r\n addressString += address.address2 ? ` ${address.address2},` : '';\r\n addressString += address.city ? ` ${address.city},` : '';\r\n addressString += address.abbr ? ` ${address.abbr}` : '';\r\n addressString += address.zip ? ` ${address.zip}` : '';\r\n\r\n return addressString;\r\n },\r\n sequence: 3\r\n }, {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n sequence: 8.1\r\n }, {\r\n headerName: 'Collector',\r\n field: 'collectorName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n sequence: 8.2\r\n }, {\r\n headerName: '',\r\n field: 'hasAttachments',\r\n filter: true,\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n width: AgGridColumns.textColumnSmallWidth,\r\n cellRendererFramework: TaxRateCommandCenterAttachmentsCellRendererComponent,\r\n cellRendererParams: {\r\n gridSofurce: this.selectedGridSourceOption,\r\n canEdit: true\r\n } as ICellRendererParamsForTaxRateCommandCenterAttachments,\r\n sequence: 9\r\n }, {\r\n headerName: '',\r\n field: 'hasComments',\r\n filter: true,\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n width: AgGridColumns.textColumnSmallWidth,\r\n cellRendererFramework: TaxRateCommandCenterCommentsCellRendererComponent,\r\n cellRendererParams: {\r\n gridSofurce: this.selectedGridSourceOption,\r\n canEdit: true\r\n } as ICellRendererParamsForTaxRateCommandCenterComments,\r\n sequence: 10\r\n }];\r\n }\r\n\r\n protected getAuthorityColumns(): OrderedColDef[] {\r\n return [{\r\n headerName: 'Authority Name',\r\n field: 'name',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n sequence: 1\r\n }, {\r\n headerName: 'PTX ID',\r\n field: 'ptxId',\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n sequence: 2.1\r\n }, {\r\n headerName: 'Category',\r\n field: 'categoryName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n valueGetter: (params) => {\r\n const taxAuthority: TaxAuthority = params.data;\r\n\r\n if(!taxAuthority || taxAuthority.taxAuthorityCategoryId == null) {\r\n return '';\r\n }\r\n return this.constants.TaxAuthorityCategories[taxAuthority.taxAuthorityCategoryId].displayName;\r\n },\r\n sequence: 4\r\n }, {\r\n headerName: 'Taxable Assessment',\r\n field: 'taxableAssessmentType',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n valueGetter: (params) => {\r\n const taxAuthority: TaxAuthority = params.data;\r\n\r\n if(!taxAuthority || taxAuthority.taxableAssessmentTypeId == null) {\r\n return '';\r\n }\r\n return this.enableTrueRateBasedSystem\r\n ? this.constants.TaxableAssessmentTypesForTrueRate[taxAuthority.taxableAssessmentTypeId].displayName\r\n : this.constants.TaxableAssessmentTypes[taxAuthority.taxableAssessmentTypeId].displayName;\r\n },\r\n sequence: 5\r\n }, {\r\n headerName: 'Obtain in Advance',\r\n // headerClass: 'ws-text-align-center',\r\n field: 'obtainInAdvance',\r\n filter: true,\r\n filterParams: AgGridFilterParams.booleanFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.booleanFloatingFilterParams,\r\n width: AgGridColumns.textColumnSmallWidth,\r\n cellRenderer: (params) => {\r\n const entity = params.data as TaxAuthority;\r\n\r\n if(!entity) {\r\n return '';\r\n }\r\n\r\n if(entity.obtainInAdvance) {\r\n return '';\r\n } else {\r\n return '';\r\n }\r\n },\r\n sequence: 7\r\n // cellClass: 'ws-text-align-center'\r\n }, {\r\n headerName: 'Default Annual Rate Increase',\r\n headerClass: 'text-align-right',\r\n field: 'defaultAnnualRateIncrease',\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => {\r\n if(!params.data) {\r\n return;\r\n }\r\n\r\n return new Decimal(params.data.defaultAnnualRateIncrease).times(100).toFixed(2);\r\n },\r\n cellClass: 'text-align-right',\r\n sequence: 8\r\n }, {\r\n headerName: 'QC By',\r\n field: 'qcRequestUserFullName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n sequence: 5.1\r\n }, {\r\n headerName: 'QC Request Date',\r\n field: 'qcRequestTimeUtc',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._datePipe.transform(params.value, true) : '',\r\n sequence: 5.2\r\n }, {\r\n headerName: 'Certification Date',\r\n field: 'certificationDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const taxAuthority: TaxAuthority = params.data;\r\n if (!taxAuthority) {\r\n return '';\r\n }\r\n return this._datePipe.transform(taxAuthority.certificationDate, true);\r\n },\r\n sequence: 6\r\n }, {\r\n headerName: 'Status Update',\r\n field: 'queueProcessingStatusName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n hide: true,\r\n sequence: 8.3\r\n }, {\r\n headerName: 'System ID',\r\n field: 'taxAuthorityId',\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n width: AgGridColumns.numericColumnWidth,\r\n cellClass: 'text-align-right',\r\n hide: true,\r\n sequence: 1.1\r\n }];\r\n }\r\n\r\n protected getAreaColumns(): OrderedColDef[] {\r\n return [{\r\n headerName: 'Rate Area Name',\r\n field: 'name',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth,\r\n sequence: 1\r\n }];\r\n }\r\n\r\n private _changeGridSource(gridSource: GridSource): void {\r\n this.selectedGridSourceOption = gridSource;\r\n this.gridId = gridSource == 'authorities'\r\n ? this._TAX_AUTHORITIES_GRID_ID\r\n : this._TAX_RATE_AREAS_GRID_ID;\r\n\r\n this.gridTracker.clear();\r\n\r\n this.gridApi.setColumnDefs([]);\r\n this.gridApi.setColumnDefs(this.getGridColumns());\r\n }\r\n\r\n private _getQcCountTotal(): void {\r\n this.qcCountTotal = this.pendingQcStateCounts.reduce((total, state) => {\r\n return total + state.item3;\r\n }, 0);\r\n }\r\n\r\n private async _refreshAssessorCollectors() {\r\n if(!this.selectedStateId) {\r\n return;\r\n }\r\n\r\n this.assessorsCollectorsLoading = true;\r\n const promises: Promise[] = [this.taxRateCommandCenterService.getAssessors(this.selectedStateId)];\r\n\r\n if(this.selectedAssessorId) {\r\n promises.push(this.taxRateCommandCenterService.getCollectors(this.selectedStateId, this.selectedAssessorId));\r\n } else {\r\n promises.push(this.taxRateCommandCenterService.getCollectors(this.selectedStateId));\r\n }\r\n\r\n const [assessors, collectors] = await Promise.all(promises);\r\n this.stateAssessors = assessors\r\n .sort(this._abbrSort)\r\n .map((a) => ({ name: `${a.abbr} ${(a.municipalityName) ? a.municipalityName : ''}`, value: a.assessorID }));\r\n\r\n if(this.selectedAssessorId) {\r\n if(!this.stateAssessors.some(x => x.value === this.selectedAssessorId)) {\r\n this.selectedAssessorId = null;\r\n }\r\n\r\n this.assessorCollectors = _.orderBy(collectors, 'abbr');\r\n\r\n if(this.selectedCollectorId && !this.assessorCollectors.some((x) => x.value === this.selectedCollectorId)) {\r\n this.selectedCollectorId = null;\r\n }\r\n } else {\r\n this.stateCollectors = collectors\r\n .sort(this._abbrSort)\r\n .map((a) => ({ name: `${a.abbr}`, value: a.collectorID }));\r\n\r\n if(this.selectedCollectorId && !this.stateCollectors.some(x => x.value === this.selectedCollectorId)) {\r\n this.selectedCollectorId = null;\r\n }\r\n }\r\n\r\n this.assessorsCollectorsLoading = false;\r\n }\r\n\r\n private _refreshDataSource() {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this.gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const dataSourceParams = (): TaxRateDataSourceParams => {\r\n return {\r\n entityType: this.selectedGridSourceOption == 'areas' ? EntityType.TaxRateArea : EntityType.TaxAuthority,\r\n stateId: this.selectedStateId,\r\n assessorId: this.selectedAssessorId,\r\n collectorId: this.selectedCollectorId,\r\n onlyPendingQC: this.onlyPendingQC,\r\n taxYearBegin: this.taxRateCommandCenterService.taxYearBegin - this.taxRateCommandCenterService.taxYearsPrior,\r\n taxYearEnd: this.taxRateCommandCenterService.taxYearBegin\r\n };\r\n };\r\n\r\n this._gridDataSource = new TaxRateCommandCenterAgGridDataSource(\r\n this.gridApi,\r\n this.taxRateCommandCenterService,\r\n dataSourceParams\r\n );\r\n\r\n this.gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n // Retrieve list of currently selected Tax Authority Ids (primarily used for Select All).\r\n const rowsSelectionModel: any = this.gridTracker.getSelectedRowsModel();\r\n const selectionOptions: TaxAuthoritySelectionOptions = {\r\n searchParams: this._gridDataSource.getSearchModelForBulkUpdate(),\r\n selectionType: this.gridTracker.isSelectAllChecked()\r\n ? (rowsSelectionModel.selectedRows.length > 0\r\n ? TaxAuthoritySelectionType.AllButGiven\r\n : TaxAuthoritySelectionType.All)\r\n : TaxAuthoritySelectionType.Given,\r\n selectedTaxAuthorityIds: rowsSelectionModel.selectedRows\r\n };\r\n\r\n const selectionInfo = await this.taxRateCommandCenterService.getTaxAuthoritySelectionsForBulkUpdate(selectionOptions);\r\n\r\n this._selectedEntitiesInfo = selectionInfo.map(x => {\r\n return {\r\n entityId: x.taxAuthorityId,\r\n queueProcessingStatus: x.queueProcessingStatus\r\n } as SelectedRowInfo;\r\n })\r\n return Promise.resolve({\r\n data: this._selectedEntitiesInfo.map(entry => entry.entityId),\r\n totalRows: this._selectedEntitiesInfo.length,\r\n lastModifiedTimestamp: new Date(),\r\n totalValidRows: 0\r\n });\r\n }\r\n\r\n private _abbrSort = (a, b) => (a.abbr > b.abbr) ? 1 : -1;\r\n\r\n /*\r\n private async peekGrid() {\r\n const selection: any = this.gridTracker.getSelectedRowsModel();\r\n console.log(`selectAllRows=${selection.selectAllRows}, selectedRows.length=${selection.selectedRows.length}`);\r\n if ( selection.selectedRows.length > 0 ) console.log(`selectedRows=${JSON.stringify(selection.selectedRows)}`);\r\n const selIds: number[] = await this.gridTracker.getSelectedRowIds();\r\n console.log(`SelectedRowIds.length=${selIds.length}`);\r\n if ( selIds.length > 0 ) console.log(`SelectedRowIds=${JSON.stringify(selIds)}`);\r\n console.log(`hasFilteredRows=${this.gridTracker.hasFilteredRows()} hasSelectedAllFilteredRows=${this.gridTracker.hasSelectedAllFilteredRows()}`);\r\n console.log(`hasSelectedRows=${this.gridTracker.hasSelectedRows()}`);\r\n console.log(`hasAnythingSelected=${this.gridTracker.hasAnythingSelected()} SelectedRowsCount=${this.gridTracker.getSelectedRowsCount()}`);\r\n console.log(`TotalRowsCount=${this.gridTracker.getTotalRowsCount()}`);\r\n const selectedRows: any = this.gridApi.getSelectedRows();\r\n if ( selectedRows ) console.log(`SelectedRows=${JSON.stringify(selectedRows)}`);\r\n const selectedNodes: any = this.gridApi.getSelectedNodes();\r\n if ( selectedNodes ) console.log(`SelectedNodes=${JSON.stringify(selectedNodes)}`);\r\n selection.selectedRows.forEach((rowId) => {\r\n const rowNode = this.gridApi.getRowNode(rowId);\r\n if ( rowNode ) console.log(`rowNode[${rowId}].data=${JSON.stringify(rowNode.data)}`);\r\n });\r\n //this.gridApi.forEachNode((rowNode: RowNode, index: number) => {\r\n // console.log(`rowNode[${index}].id=${rowNode.id}`);\r\n // console.log(`rowNode[${index}].data=${JSON.stringify(rowNode.data)}`);\r\n //});\r\n this.gridApi.forEachNode((rowNode: RowNode, index: number) => {\r\n if ( selection.selectedRows.some((selId: number) => selId === rowNode.data.taxAuthorityId) ) {\r\n console.log(`rowNode[${index}].id=${rowNode.id}`);\r\n console.log(`rowNode[${index}].isSelected=${rowNode.isSelected()}`);\r\n console.log(`rowNode[${index}].data.taxAuthorityId=${rowNode.data.taxAuthorityId}`);\r\n console.log(`rowNode[${index}].data.name=${rowNode.data.name}`);\r\n console.log(`rowNode[${index}].data.code=${rowNode.data.code}`);\r\n }\r\n });\r\n const model: any = this.gridApi.getModel();\r\n return;\r\n }\r\n */\r\n}\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../Compliance/AgGrid';\r\nimport { PermissionService } from '../../permission.service';\r\n\r\nexport interface CompanySitePermissionsDataSourceParams {\r\n companyId: number;\r\n groupId?: number;\r\n userId?: System.Guid;\r\n}\r\n\r\nexport class CompanySitePermissionsAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private _gridApi: GridApi,\r\n private _permissionService: PermissionService,\r\n protected _dataSourceParamsFn: () => CompanySitePermissionsDataSourceParams\r\n ) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'siteStateAbbr', value: Compliance.PermissionModelPropertyEnum.SiteStateAbbr },\r\n { name: 'siteProperty', value: Compliance.PermissionModelPropertyEnum.SiteProperty },\r\n { name: 'entityName', value: Compliance.PermissionModelPropertyEnum.EntityName },\r\n { name: 'rightsDropdown', value: Compliance.PermissionModelPropertyEnum.Rights }\r\n ];\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.PermissionSearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n groupId: this._dataSourceParams.groupId,\r\n userId: this._dataSourceParams.userId,\r\n excludeInactive: false\r\n };\r\n\r\n return await this._permissionService.getCompanySiteRowIds(this._dataSourceParams.companyId, searchParams);\r\n }\r\n\r\n destroy?(): void { return null; }\r\n\r\n protected canGetRows(): boolean {\r\n return !!this._dataSourceParams.groupId || !!this._dataSourceParams.userId;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.PermissionSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n groupId: this._dataSourceParams.groupId,\r\n userId: this._dataSourceParams.userId,\r\n excludeInactive: false\r\n };\r\n\r\n const result = await this._permissionService.getAvailableSitePermissions(this._dataSourceParams.companyId, searchParams);\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class PermissionService {\r\n constructor(private readonly _http: HttpClient) { }\r\n\r\n getGroupInstanceRights(groupId: number): Promise {\r\n return lastValueFrom(this._http.get(`api/instanceright/group/${groupId}`)) as Promise;\r\n }\r\n\r\n getAvailableGroupInstanceRights(groupId: number): Promise {\r\n return lastValueFrom(this._http.get(`api/instanceright/group/${groupId}/available`)) as Promise;\r\n }\r\n\r\n updateGroupInstanceRights(groupId: number, instanceRightsIds: number[]): Promise {\r\n return lastValueFrom(this._http.put(`api/instanceright/group/${groupId}`, instanceRightsIds)) as Promise;\r\n }\r\n\r\n getGroupApplicationRights(groupId: number): Promise {\r\n return lastValueFrom(this._http.get(`api/user/role/group/${groupId}`)) as Promise;\r\n }\r\n\r\n getAvailableGroupApplicationRights(groupId: number): Promise {\r\n return lastValueFrom(this._http.get(`api/user/role/group/${groupId}/available`)) as Promise;\r\n }\r\n\r\n updateGroupApplicationRights(groupId: number, roleIds: System.Guid[]): Promise {\r\n return lastValueFrom(this._http.put(`api/user/role/group/${groupId}`, roleIds)) as Promise;\r\n }\r\n\r\n getUserOrGroupEntityPermissions(instanceId: number, searchModel: Core.PermissionSearchModel): Promise> {\r\n return lastValueFrom(this._http.post(`api/permission/instance/${instanceId}`, searchModel)) as Promise>;\r\n }\r\n\r\n getCompanyRowIds(instanceId: number, searchModel: Core.PermissionSearchModel): Promise> {\r\n return lastValueFrom(this._http.post(`api/permission/instance/${instanceId}/rowids`, searchModel)) as Promise>;\r\n }\r\n\r\n getAvailableSitePermissions(companyId: number, searchModel: Core.PermissionSearchModel): Promise> {\r\n return lastValueFrom(this._http.post(`api/permission/company/${companyId}/sitesavailable`, searchModel)) as Promise>;\r\n }\r\n\r\n getCompanySiteRowIds(companyId: number, searchModel: Core.PermissionSearchModel): Promise> {\r\n return lastValueFrom(this._http.post(`api/permission/company/${companyId}/rowids`, searchModel)) as Promise>;\r\n }\r\n\r\n getAvailableCompanyPermissionsForGroup(instanceId: number, searchModel: Core.PermissionSearchModel) {\r\n return lastValueFrom(this._http.post(`api/permission/instance/${instanceId}/available`, searchModel)) as Promise>;\r\n }\r\n\r\n getAvailableCompanyPermissionsRowIds(instanceId: number, searchModel: Core.PermissionSearchModel) {\r\n return lastValueFrom(this._http.post(`api/permission/instance/${instanceId}/available/rowids`, searchModel)) as Promise>;\r\n }\r\n\r\n updateEntityPermissions(permissionSaveRequest: Core.PermissionSaveRequest): Promise> {\r\n return lastValueFrom(this._http.put('api/permission', permissionSaveRequest)) as Promise>;\r\n }\r\n}\r\n"," 0\">\r\n\r\n \r\n \r\n \r\n\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { PermissionService } from './../../permission.service';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../Compliance/AgGrid';\r\n\r\nexport interface CompanyListDataSourceParams {\r\n instanceId: number;\r\n groupId?: number;\r\n userId?: System.Guid;\r\n excludeCompanyIds: number[];\r\n excludeInactive: boolean;\r\n}\r\n\r\nexport class CompanyListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _permissionService: PermissionService,\r\n protected _dataSourceParamsFn: () => CompanyListDataSourceParams\r\n ) { super(_gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'entityName', value: Compliance.PermissionModelPropertyEnum.EntityName },\r\n { name: 'topLevelCompany', value: Compliance.PermissionModelPropertyEnum.TopLevelCompany }\r\n ];\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.PermissionSearchModel = this.getSearchModel(startIndex, endIndex);\r\n\r\n return await this._permissionService.getAvailableCompanyPermissionsRowIds(this._dataSourceParams.instanceId, searchParams);\r\n }\r\n\r\n getSearchModel(startIndex?: number, endIndex?: number): Core.PermissionSearchModel {\r\n return {\r\n pagination: {\r\n skip: (startIndex) ? startIndex : 0,\r\n take: (endIndex) ? endIndex - startIndex + 1 : 0\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n groupId: this._dataSourceParams.groupId,\r\n userId: this._dataSourceParams.userId,\r\n excludeCompanyIds: this._dataSourceParams.excludeCompanyIds,\r\n excludeInactive: this._dataSourceParams.excludeInactive\r\n };\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return (this._dataSourceParams.instanceId !== null);\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.PermissionSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n groupId: this._dataSourceParams.groupId,\r\n userId: this._dataSourceParams.userId,\r\n excludeCompanyIds: this._dataSourceParams.excludeCompanyIds,\r\n excludeInactive: this._dataSourceParams.excludeInactive\r\n };\r\n\r\n const result = await this._permissionService.getAvailableCompanyPermissionsForGroup(this._dataSourceParams.instanceId, searchParams);\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n}\r\n"," 0\">\r\n\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n","import { Component } from '@angular/core';\r\nimport { GridOptions, GridReadyEvent, GridApi, ColDef } from 'ag-grid-community';\r\nimport { AgGridMultiSelectTracker, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer, AgGridMultiSelectRendererParams } from './../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridColumns, AgGridOptionsBuilder } from '../../../Compliance/AgGrid';\r\nimport { CompanyListAgGridDataSource, CompanyListDataSourceParams} from './agGridDataSource';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AgGridFilterParams } from '../../../Compliance/AgGrid';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { PermissionService } from '../../permission.service';\r\nimport { CompanyPermissionOptions } from '../Panel/CompanyPermissionOptions';\r\nimport * as _ from 'lodash';\r\n\r\nexport interface CompanyPermissionAddParams {\r\n instanceId: number;\r\n groupId?: number;\r\n userId?: System.Guid;\r\n excludeCompanyIds: number[];\r\n}\r\nexport interface CompanyPermissionAddResult {\r\n totalRows: number;\r\n selectedRows: Core.PermissionModel[];\r\n permission: CompanyPermissionOptions;\r\n}\r\n\r\n@Component({\r\n selector: 'company-permission-add',\r\n templateUrl: './companyPermissionAdd.component.html',\r\n styleUrls: ['./companyPermissionAdd.component.scss']\r\n})\r\nexport class CompanyPermissionAddComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _permissionService: PermissionService,\r\n private readonly _modalRef: BsModalRef,\r\n private _busyIndicatorService: BusyIndicatorService\r\n ) { }\r\n\r\n public permissionTypes = Object.values(CompanyPermissionOptions);\r\n selectedPermissionType: CompanyPermissionOptions = CompanyPermissionOptions.ViewAllSites;\r\n excludeInactive: boolean = false;\r\n\r\n params: CompanyPermissionAddParams;\r\n result: CompanyPermissionAddResult;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected(params.data.entityID)\r\n }\r\n })\r\n .withContext(this)\r\n .withInfiniteScroll()\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: CompanyListAgGridDataSource;\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: '',\r\n field: 'entityID',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'entityName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParamsStartsWith,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Top Level Company',\r\n field: 'topLevelCompany',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParamsStartsWith,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'entityName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n async save(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Adding' });\r\n\r\n try {\r\n const selectedRows: Core.PermissionModel[] = [];\r\n const selected = await this.gridTracker.getSelectedRowIds();\r\n\r\n this._gridApi.forEachNode(x => {\r\n if(_.includes(selected, x.data.entityID)) {\r\n selectedRows.push(x.data);\r\n }\r\n });\r\n\r\n this.result = {\r\n selectedRows: await selectedRows,\r\n permission: this.selectedPermissionType,\r\n totalRows: this.gridTracker.getTotalRowsCount()\r\n } as CompanyPermissionAddResult;\r\n\r\n this._modalRef.hide();\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this.gridTracker.setSelectedRowsModel({\r\n selectAllRows: false,\r\n selectedRows: []\r\n });\r\n\r\n this._modalRef.hide();\r\n }\r\n\r\n onExcludeInactive() {\r\n this._refreshDataSource();\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear();\r\n\r\n const dataSourceParams = (): CompanyListDataSourceParams => {\r\n return {\r\n groupId: this.params.groupId,\r\n userId: this.params.userId,\r\n instanceId: this.params.instanceId,\r\n excludeCompanyIds: this.params.excludeCompanyIds,\r\n excludeInactive: this.excludeInactive\r\n };\r\n };\r\n\r\n this._gridDataSource = new CompanyListAgGridDataSource(this._gridApi, this._permissionService, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private _refreshDataSource() {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n}\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../Compliance/AgGrid';\r\nimport { PermissionService } from '../../permission.service';\r\n\r\nexport interface CompanyPermissionDataSourceParams {\r\n instanceId: number;\r\n groupId?: number;\r\n userId?: number;\r\n}\r\n\r\nexport class CompanyPermissionAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _permissionService: PermissionService,\r\n protected _dataSourceParamsFn: () => CompanyPermissionDataSourceParams\r\n ) { super(_gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'entityName', value: Compliance.PermissionModelPropertyEnum.EntityName },\r\n { name: 'topLevelCompany', value: Compliance.PermissionModelPropertyEnum.TopLevelCompany }\r\n ];\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.PermissionSearchModel = this.getSearchModel(startIndex, endIndex);\r\n\r\n return await this._permissionService.getCompanyRowIds(this._dataSourceParams.instanceId, searchParams);\r\n }\r\n\r\n getSearchModel(startIndex?: number, endIndex?: number): Core.PermissionSearchModel {\r\n return {\r\n pagination: {\r\n skip: (startIndex) ? startIndex : 0,\r\n take: (endIndex) ? endIndex - startIndex + 1 : 0\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n groupId: this._dataSourceParams.groupId,\r\n excludeInactive: false\r\n };\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return (this._dataSourceParams.instanceId !== null);\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.PermissionSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n groupId: this._dataSourceParams.groupId,\r\n userId: this._dataSourceParams.userId,\r\n excludeInactive: false\r\n };\r\n\r\n const result = await this._permissionService.getUserOrGroupEntityPermissions(this._dataSourceParams.instanceId, searchParams);\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const USER_GROUP_DETAIL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'user-group-detail.new-company-permission',\r\n tooltipText: 'Add a new company permission'\r\n },\r\n {\r\n helpContentId: 'user-group-detail.edit-site-permissions',\r\n tooltipText: 'Edit company site permissions'\r\n },\r\n {\r\n helpContentId: 'user-group-detail.view-site-permissions',\r\n tooltipText: 'View company site permissions'\r\n }\r\n];\r\n","import { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { BusyIndicatorService } from '../Busy-Indicator';\r\nimport { MessageModalService } from '../UI-Lib/Message-Box/messageModal.service';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class UserGroupsService {\r\n constructor(private readonly _http: HttpClient,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _messageModalService: MessageModalService) {}\r\n\r\n private readonly _baseUrl = 'api/group';\r\n private _panelEditSub: Subject = new Subject();\r\n\r\n panelEditChange$ = this._panelEditSub.asObservable();\r\n\r\n setPanelEdit(isEdit: boolean): void {\r\n this._panelEditSub.next(isEdit);\r\n }\r\n\r\n getList(instanceId: number, groupSearchModel: Core.GroupSearchModel): Promise {\r\n return lastValueFrom(this._http.post(`${this._baseUrl}/instance/${instanceId}`, groupSearchModel)) as Promise;\r\n }\r\n\r\n getGroup(groupId: number): Promise {\r\n return lastValueFrom(this._http.get(`${this._baseUrl}/${groupId}`)) as Promise;\r\n }\r\n\r\n create(userGroup: Core.GroupModel): Promise {\r\n return lastValueFrom(this._http.post(`${this._baseUrl}`, userGroup)) as Promise;\r\n }\r\n\r\n update(userGroup: Core.GroupModel): Promise {\r\n return lastValueFrom(this._http.put(`${this._baseUrl}/${userGroup.groupID}`, userGroup)) as Promise;\r\n }\r\n\r\n delete(groupId: number, force: boolean): Promise {\r\n const params = new HttpParams().set('force', force.toString());\r\n\r\n return lastValueFrom(this._http.delete(`${this._baseUrl}/${groupId}`, { params: params })) as Promise;\r\n }\r\n\r\n async deleteWithConfirm(userGroup: Core.GroupModel): Promise {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you wish to delete the user group?', 'Confirm Delete');\r\n }\r\n catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n let busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n\r\n try {\r\n await this.delete(userGroup.groupID, false);\r\n }\r\n catch (e2) {\r\n // service returns a 422 and a message if user confirmation needed to force delete\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n busyRef.hide();\r\n\r\n try {\r\n await this._messageModalService.confirm(e2.error.message, 'Confirm Delete');\r\n }\r\n catch (e3) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n\r\n await this.delete(userGroup.groupID, true);\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve(true);\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Company Permissions\r\n \r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { OnInit, Input, Component, EventEmitter, Output } from '@angular/core';\r\nimport { GridApi, GridOptions, GridReadyEvent, ColDef, ValueGetterParams } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams, AgGridDropdownCellEditor } from '../../../Compliance/AgGrid';\r\nimport { DropdownCellEditorParams } from '../../../Compliance/AgGrid/CellEditors/agGridDropdownCellEditor.component';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { UserInstanceService } from '../../../User/userInstance.service';\r\nimport { PermissionService } from '../../permission.service';\r\nimport { CompanySitePermissionsComponent, CompanySitePermissionsParams } from '../Site/companySitePermissions.component';\r\nimport { CompanyPermissionAddComponent, CompanyPermissionAddParams } from '../Add/companyPermissionAdd.component';\r\nimport { CompanyPermissionAgGridDataSource, CompanyPermissionDataSourceParams } from './agGridDataSource';\r\nimport { CompanyPermissionOptions } from './CompanyPermissionOptions';\r\nimport { CompanyPermissionsGridActionCellRendererComponent, ICellRendererParamsForCompanyPermissionsGridAction } from './agGridActionCellRenderer.component';\r\nimport * as _ from 'lodash';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { USER_GROUP_DETAIL_HELP } from '../../../User-Group/User-Group-Detail/userGroupDetail.component.help';\r\nimport { UserGroupsService } from '../../../User-Group/userGroup.service';\r\nimport { UserGroupPanel } from 'src/app/User-Group/User-Group-Detail/userGroupDetail.component';\r\n\r\n@Component({\r\n templateUrl: './companyPermissionPanel.component.html',\r\n selector: 'company-permission-panel',\r\n styles: [`\r\n :host {\r\n display: flex;\r\n flex-flow: column;\r\n height: 100%;\r\n width: 100%;\r\n }\r\n `]\r\n})\r\nexport class CompanyPermissionPanelComponent implements OnInit {\r\n constructor(\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _permissionService: PermissionService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService,\r\n private readonly _userGroupsService: UserGroupsService,\r\n private readonly _navigationService: NavigationService) { }\r\n\r\n @Input() userGroup: Core.GroupModel;\r\n @Input() canEdit: boolean;\r\n @Output() expandClicked: EventEmitter = new EventEmitter();\r\n\r\n editMode: boolean = false;\r\n isExpanded: boolean = false;\r\n gridIsDirty: boolean = false;\r\n\r\n saveRequest: Core.PermissionSaveRequest = {\r\n adds: [],\r\n deletes: [],\r\n updates: []\r\n };\r\n addedCompanies: Core.PermissionModel[] = [];\r\n\r\n currentInstance: Core.InstanceViewModel;\r\n agGridReady: boolean;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n rowClassRules: {\r\n 'grid-row-deleted': params => params.data && _.some(this.saveRequest.deletes, {permissionID: params.data.permissionID})\r\n },\r\n singleClickEdit: true,\r\n suppressHorizontalScroll: true\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: CompanyPermissionAgGridDataSource;\r\n\r\n\r\n ngOnInit(): void {\r\n this.currentInstance = this._userInstanceService.getSelectedInstance();\r\n this._helpService.setContent(USER_GROUP_DETAIL_HELP);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Company',\r\n field: 'entityName',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParamsStartsWith,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth\r\n },\r\n {\r\n headerName: 'Top Level Company',\r\n field: 'topLevelCompany',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParamsStartsWith,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth\r\n },\r\n {\r\n headerName: 'Access Level',\r\n field: 'rightsDropdown',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n editable: (params) => {\r\n const permissionRow = params.data as Core.PermissionModel;\r\n if (!permissionRow) {\r\n return false;\r\n }\r\n\r\n return this.canEdit && this.editMode && !_.some(this.saveRequest.deletes, { permissionID: permissionRow.permissionID });\r\n },\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => [\r\n { name: CompanyPermissionOptions.ViewAllSites, value: CompanyPermissionOptions.ViewAllSites },\r\n { name: CompanyPermissionOptions.ViewEditSomeSites, value: CompanyPermissionOptions.ViewEditSomeSites },\r\n { name: CompanyPermissionOptions.EditAllSites, value: CompanyPermissionOptions.EditAllSites }\r\n ],\r\n cellChanged: (params: DropdownCellEditorParams, newValue: string) => {\r\n const permission = params.data as Core.PermissionModel;\r\n this._setPermissionFlags(permission, newValue);\r\n\r\n const alreadyUpdatedIdx = _.findIndex(this.saveRequest.updates, {permissionID: permission.permissionID});\r\n\r\n if(alreadyUpdatedIdx >= 0) {\r\n this.saveRequest.updates[alreadyUpdatedIdx] = permission;\r\n } else {\r\n this.saveRequest.updates.push(permission);\r\n }\r\n\r\n this.gridIsDirty = true;\r\n }\r\n },\r\n valueGetter: this._getDropownPermission.bind(this)\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: CompanyPermissionsGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n editMode: params => this.canEdit && this.editMode,\r\n canLaunchSitesModal: (params: ICellRendererParamsForCompanyPermissionsGridAction) => {\r\n const permissionOption = this._getDropownPermission(params);\r\n return permissionOption === CompanyPermissionOptions.ViewEditSomeSites;\r\n },\r\n launchSitesModal: async (params: ICellRendererParamsForCompanyPermissionsGridAction) => {\r\n const permission = params.data as Core.PermissionModel;\r\n\r\n const modalParams: CompanySitePermissionsParams = {\r\n companyId: permission.entityID,\r\n groupId: permission.groupID,\r\n editMode: this.editMode,\r\n saveRequest: _.cloneDeep(this.saveRequest)\r\n };\r\n\r\n const result = await this._modalService.showAsync(CompanySitePermissionsComponent, modalParams, 'modal-lg');\r\n\r\n if(result) {\r\n this.saveRequest = result;\r\n this.gridIsDirty = true;\r\n }\r\n },\r\n canRemove: params => {\r\n const permissionRow = params.data as Core.PermissionModel;\r\n if (!permissionRow) {\r\n return false;\r\n }\r\n return this.canEdit && this.editMode && !_.some(this.saveRequest.deletes, {permissionID: permissionRow.permissionID});\r\n },\r\n remove: (params: ICellRendererParamsForCompanyPermissionsGridAction) => {\r\n const permissionRow = params.data as Core.PermissionModel;\r\n\r\n if(params.node.rowPinned) {\r\n this.addedCompanies = _.reject(this.addedCompanies, {entityID: permissionRow.entityID});\r\n } else {\r\n this.saveRequest.deletes.push(permissionRow);\r\n this._gridApi.redrawRows();\r\n }\r\n\r\n this.gridIsDirty = true;\r\n },\r\n canUndoRemove: params => {\r\n const permissionRow = params.data as Core.PermissionModel;\r\n if (!permissionRow) {\r\n return false;\r\n }\r\n\r\n return this.editMode && _.some(this.saveRequest.deletes, {permissionID: permissionRow.permissionID});\r\n },\r\n undoRemove: (params: ICellRendererParamsForCompanyPermissionsGridAction) => {\r\n const permissionRow = params.data as Core.PermissionModel;\r\n this.saveRequest.deletes = _.reject(this.saveRequest.deletes, {permissionID: permissionRow.permissionID});\r\n\r\n this._gridApi.redrawRows();\r\n },\r\n } as ICellRendererParamsForCompanyPermissionsGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'entityName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.sizeColumnsToFit();\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n async addNewCompanyPermission() {\r\n // Add new permission modal\r\n const dataSourceParams: CompanyPermissionAddParams = {\r\n instanceId: this.currentInstance.instanceId,\r\n groupId: this.userGroup.groupID,\r\n excludeCompanyIds: _.map(this.addedCompanies, 'entityID')\r\n };\r\n\r\n const result = await this._modalService.showAsync(CompanyPermissionAddComponent, dataSourceParams, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n result.selectedRows = _.map(result.selectedRows, x => {\r\n this._setPermissionFlags(x, result.permission);\r\n return x;\r\n });\r\n\r\n this.addedCompanies = [...this.addedCompanies, ...result.selectedRows];\r\n\r\n this.gridIsDirty = true;\r\n }\r\n\r\n edit() {\r\n this.editMode = true;\r\n this._userGroupsService.setPanelEdit(this.editMode);\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n }\r\n\r\n cancel() {\r\n this._resetPanel();\r\n }\r\n\r\n refresh(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n expandCollapse(expand: boolean) {\r\n this.expandClicked.emit('companyPermission');\r\n setTimeout(() => {\r\n this._gridApi.sizeColumnsToFit();\r\n });\r\n this.isExpanded = expand;\r\n }\r\n\r\n async save() {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating Company Permissions' });\r\n\r\n try {\r\n this.saveRequest.adds = [...this.saveRequest.adds, ...this.addedCompanies];\r\n await this._permissionService.updateEntityPermissions(this.saveRequest);\r\n\r\n this._resetPanel();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n private _getDropownPermission(params: ValueGetterParams): string {\r\n const dbPermission = params.data as Core.PermissionModel;\r\n\r\n if (!dbPermission) {\r\n return '';\r\n }\r\n\r\n const p = _.find(this.saveRequest.updates, {permissionID: dbPermission.permissionID}) || dbPermission;\r\n\r\n if (p.writeAllowed) {\r\n if (p.includeAllChildRecords) {\r\n return CompanyPermissionOptions.EditAllSites;\r\n } else {\r\n return CompanyPermissionOptions.ViewEditSomeSites;\r\n }\r\n }\r\n\r\n if (p.readAllowed) {\r\n if (p.includeAllChildRecords) {\r\n return CompanyPermissionOptions.ViewAllSites;\r\n } else {\r\n return CompanyPermissionOptions.ViewEditSomeSites;\r\n }\r\n }\r\n }\r\n\r\n private _setPermissionFlags(permission: Core.PermissionModel, rightsString: string): void {\r\n permission.readAllowed = true;\r\n permission.writeAllowed = rightsString === CompanyPermissionOptions.EditAllSites;\r\n permission.includeAllChildRecords = rightsString === CompanyPermissionOptions.ViewAllSites || rightsString === CompanyPermissionOptions.EditAllSites;\r\n }\r\n\r\n private _resetPanel() {\r\n this.editMode = false;\r\n this.saveRequest.updates = [];\r\n this.saveRequest.deletes = [];\r\n this.saveRequest.adds = [];\r\n this.addedCompanies = [];\r\n this._userGroupsService.setPanelEdit(this.editMode);\r\n this.gridIsDirty = false;\r\n this._navigationService.disableNavWarning();\r\n\r\n this.refresh();\r\n }\r\n\r\n private _refreshDataSource() {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const dataSourceParams = (): CompanyPermissionDataSourceParams => {\r\n return {\r\n instanceId: this.currentInstance.instanceId,\r\n groupId: this.userGroup.groupID\r\n };\r\n };\r\n\r\n this._gridDataSource = new CompanyPermissionAgGridDataSource(this._gridApi, this._permissionService, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Additional {{userInstanceService.getSelectedInstance().name}} Permissions\r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { PermissionService } from '../permission.service';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community/dist/lib/main';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../Compliance/AgGrid';\r\nimport { ICellRendererParamsForInstanceRightGridAction, InstanceRightGridActionCellRendererComponent } from './agGridActionCellRenderer.component';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { UserGroupsService } from '../../User-Group/userGroup.service';\r\nimport { RestrictService } from '../../Common/Permissions/restrict.service';\r\nimport * as _ from 'lodash';\r\nimport { UserGroupPanel } from 'src/app/User-Group/User-Group-Detail/userGroupDetail.component';\r\n\r\nexport interface PermissionWithOptions {\r\n right: Core.InstanceRightModel;\r\n rightOptions: Core.InstanceRightModel[];\r\n isDeleted: boolean;\r\n}\r\n\r\n@Component({\r\n templateUrl: './instancePermissionPanel.component.html',\r\n selector: 'instance-permission-panel'\r\n})\r\nexport class InstancePermissionPanelComponent implements OnInit {\r\n constructor(\r\n private readonly _permissionService: PermissionService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _userGroupsService: UserGroupsService,\r\n public readonly userInstanceService: UserInstanceService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _restrictService: RestrictService\r\n ) { }\r\n\r\n @Input() userGroup: Core.GroupModel;\r\n @Input() canEdit: boolean;\r\n @Input() userSetup: boolean;\r\n @Output() expandClicked: EventEmitter = new EventEmitter();\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressHorizontalScroll: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n canEnterEditMode: boolean = true;\r\n editMode: boolean = false;\r\n instanceId: number;\r\n isExpanded: boolean = false;\r\n gridIsDirty: boolean = false;\r\n\r\n allPermissions: PermissionWithOptions[];\r\n assignedPermissions: PermissionWithOptions[];\r\n availablePermissions: PermissionWithOptions[];\r\n\r\n private _originalAllPermissions: PermissionWithOptions[];\r\n\r\n private _gridApi: GridApi;\r\n\r\n private _gridDataSource: any;\r\n\r\n async ngOnInit(): Promise {\r\n this.instanceId = this.userInstanceService.getSelectedInstance().instanceId;\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Permission',\r\n field: 'right.screenType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Access Level',\r\n field: 'right.rights',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: InstanceRightGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canEdit: () => {\r\n return this.editMode && this.canEdit;\r\n },\r\n permissionChanged: () => {\r\n this.gridIsDirty = true;\r\n }\r\n } as ICellRendererParamsForInstanceRightGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'right.screenType',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._gridApi.sizeColumnsToFit();\r\n this.setDataSource();\r\n }\r\n\r\n setDataSource(): void {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n try {\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n this.loadPermissions().then(() => {\r\n this._gridApi.setRowData(this.allPermissions);\r\n this._gridApi && this._gridApi.hideOverlay();\r\n });\r\n\r\n } finally {\r\n this._gridApi && this._gridApi.hideOverlay();\r\n }\r\n\r\n }\r\n\r\n private async loadPermissions(): Promise {\r\n const assignedPermissions = await this._permissionService.getGroupInstanceRights(this.userGroup.groupID);\r\n await this._initPermissions(assignedPermissions);\r\n }\r\n\r\n private async _initPermissions(assignedPermissions: Core.InstanceRightModel[]): Promise {\r\n const availablePermissions = await this._permissionService.getAvailableGroupInstanceRights(this.userGroup.groupID);\r\n\r\n this.assignedPermissions = _.map(assignedPermissions, permission => {\r\n const otherOptions = _.filter(availablePermissions, x => x.screenTypeID === permission.screenTypeID);\r\n const noneOption: Core.InstanceRightModel = { instanceRightID: -1, rightsID: -1, name: permission.name, rights: 'None', screenType: permission.screenType, screenTypeID: -1 };\r\n\r\n return {\r\n right: permission,\r\n rightOptions: _.sortBy([...otherOptions, permission, noneOption], 'rightsID'),\r\n isDeleted: false\r\n };\r\n });\r\n\r\n this.availablePermissions = _.chain(availablePermissions)\r\n .reject(x => _.some(assignedPermissions, { screenTypeID: x.screenTypeID }))\r\n .groupBy('screenTypeID')\r\n .toArray()\r\n .map(rightOptions => {\r\n const noneOption: Core.InstanceRightModel = {\r\n instanceRightID: -1,\r\n rightsID: -1,\r\n name: rightOptions[0].name,\r\n rights: 'None',\r\n screenType: rightOptions[0].screenType,\r\n screenTypeID: -1\r\n };\r\n return {\r\n right: noneOption,\r\n rightOptions: _.sortBy([ ...rightOptions, noneOption ], 'rightsID'),\r\n isDeleted: false\r\n };\r\n })\r\n .value();\r\n\r\n this.allPermissions = _.sortBy(this.assignedPermissions.concat(this.availablePermissions), 'right.screenType');\r\n\r\n this._gridApi.setRowData(this.allPermissions);\r\n }\r\n\r\n edit(): void {\r\n this._originalAllPermissions = _.cloneDeep(this.allPermissions);\r\n this.editMode = true;\r\n this._userGroupsService.setPanelEdit(this.editMode);\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n }\r\n\r\n cancel(): void {\r\n this.allPermissions = this._originalAllPermissions;\r\n this.setDataSource();\r\n this._exitEditMode();\r\n }\r\n\r\n async save(): Promise {\r\n const instanceRightsIds = this.allPermissions\r\n .filter(a => a.right.rightsID > -1)\r\n .map(x => x.right.instanceRightID);\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating Instance Rights' });\r\n try {\r\n const assignedPermissions = await this._permissionService.updateGroupInstanceRights(this.userGroup.groupID, instanceRightsIds);\r\n await this._initPermissions(assignedPermissions);\r\n\r\n this._exitEditMode();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n expandCollapse(expand: boolean): void {\r\n this.expandClicked.emit('instancePermission');\r\n setTimeout(() => {\r\n this._gridApi.sizeColumnsToFit();\r\n });\r\n this.isExpanded = expand;\r\n }\r\n\r\n private _exitEditMode(): void {\r\n this.editMode = false;\r\n this._userGroupsService.setPanelEdit(this.editMode);\r\n this._navigationService.disableNavWarning();\r\n this.gridIsDirty = false;\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Additional Application Permissions\r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { PermissionService } from '../permission.service';\r\nimport * as _ from 'lodash';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridFilterParams, AgGridOptionsBuilder } from '../../Compliance/AgGrid';\r\nimport { ApplicationPermissionGridActionCellRendererComponent, ICellRendererParamsForApplicationPermissionGridAction } from './agGridActionCellRenderer.component';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { UserGroupsService } from '../../User-Group/userGroup.service';\r\nimport { UserGroupPanel } from 'src/app/User-Group/User-Group-Detail/userGroupDetail.component';\r\n\r\nexport interface PermissionWithOptions {\r\n right: Core.RoleModel;\r\n rightOptions: Core.RoleModel[];\r\n isDeleted: boolean;\r\n}\r\n\r\n@Component({\r\n templateUrl: './applicationPermissionPanel.component.html',\r\n selector: 'application-permission-panel'\r\n})\r\nexport class ApplicationPermissionPanelComponent {\r\n constructor(\r\n private readonly _permissionService: PermissionService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _userGroupsService: UserGroupsService,\r\n public readonly userInstanceService: UserInstanceService\r\n ) { }\r\n\r\n @Input() userGroup: Core.GroupModel;\r\n @Input() canEdit: boolean;\r\n @Input() userSetup: boolean;\r\n @Output() expandClicked: EventEmitter = new EventEmitter();\r\n\r\n canEnterEditMode: boolean = true;\r\n editMode: boolean = false;\r\n isExpanded: boolean = false;\r\n gridIsDirty: boolean = false;\r\n\r\n allPermissions: PermissionWithOptions[];\r\n assignedPermissions: PermissionWithOptions[];\r\n availablePermissions: PermissionWithOptions[];\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressHorizontalScroll: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n private _originalAllPermissions: PermissionWithOptions[];\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: any;\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Permission',\r\n field: 'right.screenType',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Access Level',\r\n field: 'right.rights',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: ApplicationPermissionGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canEdit: () => {\r\n return this.editMode && this.canEdit;\r\n },\r\n permissionChanged: () => {\r\n this.gridIsDirty = true;\r\n }\r\n } as ICellRendererParamsForApplicationPermissionGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'right.screenType',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._gridApi.sizeColumnsToFit();\r\n this.setDataSource();\r\n }\r\n\r\n setDataSource(): void {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n try {\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n\r\n this.loadPermissions().then(r => {\r\n this._gridApi.setRowData(this.allPermissions);\r\n this._gridApi && this._gridApi.hideOverlay();\r\n });\r\n }\r\n finally {\r\n this._gridApi && this._gridApi.hideOverlay();\r\n }\r\n\r\n }\r\n\r\n private async loadPermissions() {\r\n const assignedPermissions = await this._permissionService.getGroupApplicationRights(this.userGroup.groupID);\r\n await this._initPermissions(assignedPermissions);\r\n }\r\n\r\n private async _initPermissions(assignedPermissions: Core.RoleModel[]) {\r\n\r\n const availablePermissions = await this._permissionService.getAvailableGroupApplicationRights(this.userGroup.groupID);\r\n\r\n this.assignedPermissions = _.map(assignedPermissions, permission => {\r\n const otherOptions = _.filter(availablePermissions, x => x.screenTypeID === permission.screenTypeID);\r\n const noneOption: Core.RoleModel = { roleID: -1, rightsID: -1, name: permission.name, rights: 'None', screenType: permission.screenType, screenTypeID: -1, sequence: -1 };\r\n return {\r\n right: permission,\r\n rightOptions: _.sortBy([...otherOptions, permission, noneOption], 'rightsID'),\r\n isDeleted: false\r\n };\r\n });\r\n\r\n this.availablePermissions = _.chain(availablePermissions)\r\n .reject(x => _.some(assignedPermissions, { screenTypeID: x.screenTypeID }))\r\n .groupBy('screenTypeID')\r\n .toArray()\r\n .map(rightOptions => {\r\n const viewRight = _.find(rightOptions, { rightsID: Core.RightEnum.View }) || rightOptions[0];\r\n const noneOption: Core.RoleModel = { roleID: -1, rightsID: -1, name: rightOptions[0].name, rights: 'None', screenType: rightOptions[0].screenType, screenTypeID: -1, sequence: -1 };\r\n\r\n return {\r\n right: noneOption,\r\n rightOptions: _.sortBy([...rightOptions, noneOption], 'rightsID'),\r\n isDeleted: false\r\n };\r\n })\r\n .value();\r\n\r\n this.allPermissions = _.sortBy(this.assignedPermissions.concat(this.availablePermissions), 'right.screenType');\r\n\r\n }\r\n\r\n canBeEdited(permission: PermissionWithOptions) {\r\n return true;\r\n }\r\n\r\n addPermission(permission: PermissionWithOptions) {\r\n this.assignedPermissions.push(permission);\r\n _.remove(this.availablePermissions, permission);\r\n }\r\n\r\n edit() {\r\n this._originalAllPermissions = _.cloneDeep(this.allPermissions);\r\n this.editMode = true;\r\n this._userGroupsService.setPanelEdit(this.editMode);\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n }\r\n\r\n cancel() {\r\n this.allPermissions = this._originalAllPermissions;\r\n this.setDataSource();\r\n this._exitEditMode();\r\n }\r\n\r\n async save() {\r\n const roleIds = this.allPermissions\r\n .filter(a => a.right.rightsID > -1)\r\n .map(x => x.right.roleID);\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating Application Rights' });\r\n try {\r\n const assignedPermissions = await this._permissionService.updateGroupApplicationRights(this.userGroup.groupID, roleIds);\r\n await this._initPermissions(assignedPermissions);\r\n\r\n this._exitEditMode();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n expandCollapse(expand: boolean) {\r\n this.expandClicked.emit('applicationPermission');\r\n setTimeout(() => {\r\n this._gridApi.sizeColumnsToFit();\r\n });\r\n this.isExpanded = expand;\r\n }\r\n\r\n private _exitEditMode(): void {\r\n this.editMode = false;\r\n this._userGroupsService.setPanelEdit(this.editMode);\r\n this._navigationService.disableNavWarning();\r\n this.gridIsDirty = false;\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n

User Group

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnInit, ViewChild } from '@angular/core';\r\nimport { BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { BreadCrumb } from '../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { InstanceRights, RestrictService } from '../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { AccountService } from '../../User/account.service';\r\nimport { UserGroupsService } from '../userGroup.service';\r\nimport { CompanyPermissionPanelComponent } from '../../Permission/Company/Panel/companyPermissionPanel.component';\r\nimport { InstancePermissionPanelComponent } from '../../Permission/Instance/instancePermissionPanel.component';\r\nimport { ApplicationPermissionPanelComponent } from '../../Permission/Application/applicationPermissionPanel.component';\r\n\r\nexport type UserGroupPanel = 'userGroupInfo' | 'applicationPermission' | 'companyPermission' | 'instancePermission';\r\n\r\n@Component({\r\n selector: 'user-group-detail',\r\n templateUrl: './userGroupDetail.component.html',\r\n styles: [`\r\n :host {\r\n display: flex;\r\n flex-flow: column;\r\n height: 100%;\r\n width: 100%;\r\n }\r\n `]\r\n})\r\nexport class UserGroupDetailComponent implements OnInit {\r\n constructor(\r\n private readonly _userGroupsService: UserGroupsService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _accountService: AccountService\r\n ) {}\r\n\r\n @ViewChild(CompanyPermissionPanelComponent) companyPermissionPanel: CompanyPermissionPanelComponent;\r\n @ViewChild(InstancePermissionPanelComponent) instancePermissionPanel: InstancePermissionPanelComponent;\r\n @ViewChild(ApplicationPermissionPanelComponent) applicationPermissionPanel: ApplicationPermissionPanelComponent;\r\n\r\n userGroup: Core.GroupModel;\r\n canEdit: boolean = false;\r\n breadcrumbs: BreadCrumb[] = [];\r\n expandedPanel: UserGroupPanel;\r\n isPanelEdit: boolean;\r\n isLicensedUser: boolean = false;\r\n\r\n async ngOnInit() {\r\n this.breadcrumbs = [\r\n {\r\n name: 'User Groups',\r\n target: 'userGroupList',\r\n options: { }\r\n }\r\n ];\r\n\r\n this.isLicensedUser = this._accountService.userData.isLicensedUser;\r\n\r\n this.canEdit = this._restrictService.hasInstanceRight(InstanceRights.MANAGEUSERSETUP);\r\n this._loadUserGroup();\r\n\r\n this._userGroupsService.panelEditChange$.subscribe(x => this.isPanelEdit = x);\r\n }\r\n\r\n refresh() {\r\n this._loadUserGroup();\r\n this.companyPermissionPanel.refresh();\r\n this.instancePermissionPanel.setDataSource();\r\n this.applicationPermissionPanel.setDataSource();\r\n }\r\n\r\n expandClicked(panel: UserGroupPanel) {\r\n this.expandedPanel = this.expandedPanel == panel ? undefined : panel;\r\n }\r\n\r\n private async _loadUserGroup() {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n const userGroupId = +this._upgradeNavigationServiceHandler.getQuerystringParam('userGroupId');\r\n this.userGroup = await this._userGroupsService.getGroup(userGroupId);\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}\r\n","import { AfterViewInit, Component, ElementRef, ViewChild } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\n\r\n\r\n@Component({\r\n selector: 'add-user-group-modal',\r\n template: `\r\n \r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n `,\r\n})\r\nexport class AddUserGroupModalComponent implements AfterViewInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef\r\n ) { }\r\n\r\n @ViewChild('nameInput', { static: true }) nameInput: ElementRef;\r\n\r\n name: string;\r\n description: string;\r\n\r\n params: void;\r\n result: Core.GroupModel;\r\n\r\n ngAfterViewInit() {\r\n setTimeout(() => {\r\n this.nameInput.nativeElement.focus();\r\n });\r\n }\r\n\r\n save() {\r\n this.result = {\r\n name: this.name,\r\n description: this.description\r\n } as Core.GroupModel;\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n User Groups\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GridApi, GridOptions, GridReadyEvent, ColDef } from 'ag-grid-community';\r\nimport { RestrictService, InstanceRights } from '../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from '../../Compliance/AgGrid';\r\nimport { UserInstanceService } from '../../User/userInstance.service';\r\nimport { UserGroupsService } from '../userGroup.service';\r\nimport { UserGroupsGridActionCellRendererComponent, ICellRendererParamsForUserGroupsGridAction } from './agGridActionCellRendererComponent';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { AddUserGroupModalComponent } from './addUserGroupModal.component';\r\nimport {\r\n AgGridYesNoFloatingFilterComponent\r\n} from '../../Compliance/AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\n\r\n@Component({\r\n selector: 'user-group-list',\r\n templateUrl: './userGroupList.component.html',\r\n styleUrls: ['./userGroupList.component.scss']\r\n})\r\nexport class UserGroupListComponent implements OnInit {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _userGroupsService: UserGroupsService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _featureFlagService: FeatureFlagsService) { }\r\n\r\n gridId: System.Guid = '7D885CAC-59F4-4CAE-AE56-B8948DE60508'; // need new guid\r\n isInitialized: boolean = false;\r\n hasEditPermission: boolean = false;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n refreshing: boolean;\r\n instanceId: number;\r\n\r\n private _gridApi: GridApi;\r\n private _userGroups: Core.GroupModel[];\r\n\r\n async ngOnInit(): Promise {\r\n this.hasEditPermission = this._restrictService.hasInstanceRight(InstanceRights.MANAGEUSERSETUP);\r\n this.instanceId = this._userInstanceService.getSelectedInstance().instanceId;\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Name',\r\n field: 'name',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnLargeWidth\r\n },\r\n {\r\n headerName: '# Members',\r\n field: 'userCount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Consultant Group',\r\n field: 'isConsultantGroup',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: params => {\r\n const userGroup = params.data as Core.GroupModel;\r\n\r\n return userGroup.isConsultantGroup ? 'Yes' : 'No';\r\n }\r\n },\r\n {\r\n headerName: 'Support Group',\r\n field: 'isSupportGroup',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: params => {\r\n const userGroup = params.data as Core.GroupModel;\r\n\r\n return userGroup.isSupportGroup ? 'Yes' : 'No';\r\n }\r\n }\r\n ];\r\n\r\n if (this._featureFlagService.featureFlags.enableLicensedDocumentIntakeAndProcessing &&\r\n this._userInstanceService.RyanInstanceId === this._userInstanceService.getSelectedInstance().instanceId) {\r\n columns.push({\r\n headerName: 'Documents Group',\r\n field: 'isDocumentGroup',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: params => {\r\n const userGroup = params.data as Core.GroupModel;\r\n\r\n return userGroup.isDocumentsGroup ? 'Yes' : 'No';\r\n }\r\n }\r\n );\r\n }\r\n\r\n columns.push({\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: UserGroupsGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n hasEditPermission: () => this.hasEditPermission,\r\n viewDetails: this._viewDetails.bind(this),\r\n delete: this._delete.bind(this)\r\n } as ICellRendererParamsForUserGroupsGridAction\r\n }\r\n );\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'name',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._gridApi.sizeColumnsToFit();\r\n\r\n await this._refresh();\r\n }\r\n\r\n async refresh(): Promise {\r\n await this._refresh();\r\n }\r\n\r\n async addNew(): Promise {\r\n const result = await this._modalService.showAsync(AddUserGroupModalComponent, null, '');\r\n\r\n if(!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n result.instanceID = this.instanceId;\r\n\r\n try {\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n\r\n const newUserGroup = await this._userGroupsService.create(result);\r\n this._upgradeNavigationServiceHandler.go('userGroupDetail', { userGroupId: newUserGroup.groupID });\r\n } finally {\r\n this._gridApi && this._gridApi.hideOverlay();\r\n }\r\n }\r\n\r\n private async _viewDetails(params: ICellRendererParamsForUserGroupsGridAction): Promise {\r\n const userGroup = params.data as Core.GroupModel;\r\n\r\n this._upgradeNavigationServiceHandler.go('userGroupDetail', { userGroupId: userGroup.groupID });\r\n }\r\n\r\n private async _delete(params: ICellRendererParamsForUserGroupsGridAction): Promise {\r\n const userGroup = params.data as Core.GroupModel;\r\n if (!userGroup) {\r\n return;\r\n }\r\n\r\n const deleted = await this._userGroupsService.deleteWithConfirm(userGroup);\r\n if (deleted) {\r\n await this._refresh();\r\n }\r\n\r\n }\r\n\r\n private async _refresh(): Promise {\r\n this.refreshing = true;\r\n\r\n this._userGroups = [];\r\n\r\n try {\r\n this._gridApi && this._gridApi.showLoadingOverlay();\r\n\r\n const groupSearchModel: Core.GroupSearchModel = {};\r\n\r\n this._userGroups = await this._userGroupsService.getList(this.instanceId, groupSearchModel);\r\n\r\n } finally {\r\n this._gridApi && this._gridApi.hideOverlay();\r\n }\r\n\r\n this._setRowData();\r\n this.refreshing = false;\r\n }\r\n\r\n private _setRowData() {\r\n if (!(this._gridApi && this._userGroups)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._userGroups);\r\n }\r\n}\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../Compliance/AgGrid';\r\nimport { IncomeStatementRepository } from '../incomeStatement.repository';\r\n\r\nexport interface IncomeStatementDataSourceParams {\r\n companyId: number;\r\n endDate?: Date;\r\n siteId?: number;\r\n}\r\n\r\nexport class IncomeStatementAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _incomeStatementRepository: IncomeStatementRepository,\r\n protected _dataSourceParamsFn: () => IncomeStatementDataSourceParams,\r\n private readonly _totalsUpdateCallback: (totals: Core.IncomeStatementLineSearchTotalsModel, selectedTotals?: boolean, isLoading?: boolean) => void\r\n ) { super(_gridApi); }\r\n\r\n lastFetchedTotals: Core.IncomeStatementLineSearchTotalsModel;\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n {name: `${Core.IncomeStatementLinePropertyEnum.CompanyName}`, value: Core.IncomeStatementLinePropertyEnum.CompanyName },\r\n\t\t{name: `${Core.IncomeStatementLinePropertyEnum.TopLevelCompanyName}`, value: Core.IncomeStatementLinePropertyEnum.TopLevelCompanyName },\r\n\t\t{name: `${Core.IncomeStatementLinePropertyEnum.SiteName}`, value: Core.IncomeStatementLinePropertyEnum.SiteName },\r\n\t\t{name: `${Core.IncomeStatementLinePropertyEnum.SiteNumber}`, value: Core.IncomeStatementLinePropertyEnum.SiteNumber },\r\n\t\t{name: `${Core.IncomeStatementLinePropertyEnum.GLAccountNumber}`, value: Core.IncomeStatementLinePropertyEnum.GLAccountNumber },\r\n\t\t{name: `${Core.IncomeStatementLinePropertyEnum.GLAccountName}`, value: Core.IncomeStatementLinePropertyEnum.GLAccountName },\r\n\t\t{name: `${Core.IncomeStatementLinePropertyEnum.GLAccountDescription}`, value: Core.IncomeStatementLinePropertyEnum.GLAccountDescription },\r\n\t\t{name: `${Core.IncomeStatementLinePropertyEnum.GLAccountIncomeStatementCategoryName}`, value: Core.IncomeStatementLinePropertyEnum.GLAccountIncomeStatementCategoryName },\r\n\t\t{name: `${Core.IncomeStatementLinePropertyEnum.GLAccountIncomeStatementCategoryTypeName}`, value: Core.IncomeStatementLinePropertyEnum.GLAccountIncomeStatementCategoryTypeName },\r\n\t\t{name: `${Core.IncomeStatementLinePropertyEnum.CalculatedBalance}`, value: Core.IncomeStatementLinePropertyEnum.CalculatedBalance },\r\n {name: `${Core.IncomeStatementLinePropertyEnum.AccountHierarchyDescription}`, value: Core.IncomeStatementLinePropertyEnum.AccountHierarchyDescription },\r\n {name: `${Core.IncomeStatementLinePropertyEnum.CreateDate}`, value: Core.IncomeStatementLinePropertyEnum.CreateDate },\r\n {name: `${Core.IncomeStatementLinePropertyEnum.IsValidated}`, value: Core.IncomeStatementLinePropertyEnum.IsValidated },\r\n {name: `${Core.IncomeStatementLinePropertyEnum.ValidatedDate}`, value: Core.IncomeStatementLinePropertyEnum.ValidatedDate },\r\n {name: `${Core.IncomeStatementLinePropertyEnum.ValidatedBy}`, value: Core.IncomeStatementLinePropertyEnum.ValidatedBy }\r\n\r\n ];\r\n private _lastFilterUsedInTotals: string;\r\n\r\n clearTotals(): void {\r\n this._lastFilterUsedInTotals = '';\r\n }\r\n\r\n getSearchParamsWithoutPagination() : Core.IncomeStatementLineSearchModel{\r\n this.refreshDataSourceParams();\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n selectedRows: null,\r\n endDate: this._dataSourceParams.endDate,\r\n siteId: this._dataSourceParams.siteId\r\n };\r\n }\r\n\r\n public async getSelectedRowTotals(selectedRowsModel: Compliance.SelectedRowsModel): Promise {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.selectedRows = selectedRowsModel;\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: 100\r\n };\r\n\r\n const { totals } = await lastValueFrom(this._incomeStatementRepository.getIncomeStatementList(this._dataSourceParams.companyId, searchParams));\r\n\r\n return totals;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.IncomeStatementLineSearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n selectedRows: null,\r\n siteId: this._dataSourceParams.siteId,\r\n endDate: this._dataSourceParams.endDate\r\n };\r\n\r\n return await lastValueFrom(this._incomeStatementRepository.getIncomeStatementRowIds(this._dataSourceParams.companyId, searchParams));\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n const canGetRows = !!this._dataSourceParams.companyId;\r\n if (!canGetRows) {\r\n this.clearTotals();\r\n this._totalsUpdateCallback(null);\r\n }\r\n return canGetRows;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n this._gridApi.setPinnedBottomRowData([]);\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n const searchParamsString = JSON.stringify(searchParams);\r\n const fetchTotals: boolean = (!this.lastFetchedTotals) || (this._lastFilterUsedInTotals !== searchParamsString);\r\n\r\n this._lastFilterUsedInTotals = searchParamsString;\r\n\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const {\r\n totals,\r\n data: rows,\r\n totalRows,\r\n lastModifiedTimestamp\r\n } = await lastValueFrom(this._incomeStatementRepository.getIncomeStatementList(this._dataSourceParams.companyId, searchParams));\r\n\r\n this.lastFetchedTotals = totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals);\r\n\r\n const dataSourceResult: AgGridDataSourceResult = { rows, totalRows, lastModifiedTimestamp };\r\n\r\n if (fetchTotals) {\r\n await this._getAllRowTotals(params);\r\n }\r\n\r\n return dataSourceResult;\r\n }\r\n\r\n private async _getAllRowTotals(params: IGetRowsParams): Promise {\r\n this._totalsUpdateCallback(this.lastFetchedTotals, false, true);\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const result = await lastValueFrom(this._incomeStatementRepository.getIncomeStatementList(this._dataSourceParams.companyId, searchParams));\r\n\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals);\r\n\r\n return result.totals;\r\n }\r\n}\r\n","import { Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { BulkUpdateDynamicBase, BulkUpdateOption } from '../../../UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UntypedFormBuilder, UntypedFormControl } from '@angular/forms';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { IncomeStatementRepository } from '../incomeStatement.repository';\r\n\r\nexport interface IncomeStatementBulkUpdateParams {\r\n companyId: number;\r\n siteId?: number;\r\n selection: Compliance.SelectedRowsModel;\r\n selectedCount: number;\r\n endDate?: Date;\r\n}\r\n\r\n@Component({\r\n selector: 'income-statement-bulk-update',\r\n templateUrl: '../../../UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component.html',\r\n})\r\nexport class IncomeStatementBulkUpdateComponent extends BulkUpdateDynamicBase implements OnInit, IWeissmanModalComponent{\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _incomeStatementRepository: IncomeStatementRepository,\r\n _bsModalRef: BsModalRef,\r\n _fb: UntypedFormBuilder\r\n ) {\r\n super(_bsModalRef, _fb);\r\n }\r\n\r\n @ViewChild('number', { static: true }) numberTemplate: ElementRef;\r\n @ViewChild('picklist', { static: true }) picklistTemplate: ElementRef;\r\n\r\n params: IncomeStatementBulkUpdateParams;\r\n result: boolean = false;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n isSaving: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this.header = `Bulk Update ${this.params.selectedCount} Records`;\r\n\r\n this._templateMap = new Map([\r\n [Core.DescriptorFieldTypes.Number, this.numberTemplate],\r\n [Core.DescriptorFieldTypes.Picklist, this.picklistTemplate]\r\n ]);\r\n\r\n const isValidatedControl = new UntypedFormControl(null);\r\n isValidatedControl.disable();\r\n this.bulkUpdateForm.addControl('isValidated', isValidatedControl);\r\n\r\n this.updateOptions.push({\r\n name: 'Validate',\r\n isRequired: true,\r\n template: this._templateMap.get(Core.DescriptorFieldTypes.Picklist),\r\n picklist: [\r\n {value: true, name: 'Validated'} as Compliance.NameValuePair,\r\n {value: false, name: 'Not Validated'} as Compliance.NameValuePair\r\n ],\r\n action: Core.IncomeStatementLineBulkUpdateActionEnum.NoChange,\r\n hiddenField: Core.IncomeStatementLineBulkUpdateActionEnum.RemoveOverride,\r\n formControlName: 'isValidated',\r\n formControl: isValidatedControl\r\n } as BulkUpdateOption);\r\n\r\n const balanceControl = new UntypedFormControl(null);\r\n balanceControl.disable();\r\n this.bulkUpdateForm.addControl('balance', balanceControl);\r\n\r\n this.updateOptions.push({\r\n name: 'Balance',\r\n isRequired: true,\r\n template: this._templateMap.get(Core.DescriptorFieldTypes.Number),\r\n action: Core.IncomeStatementLineBulkUpdateActionEnum.NoChange,\r\n formControlName: 'balance',\r\n formControl: balanceControl,\r\n removeOptionName: 'Remove Override',\r\n validation: {\r\n maxLength: 16\r\n }\r\n } as BulkUpdateOption);\r\n }\r\n\r\n async save(): Promise {\r\n this.isSaving = true;\r\n await this._bulkUpdate();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private async _bulkUpdate(): Promise {\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n\r\n console.log(this.updateOptions);\r\n const formValues = this.bulkUpdateForm.value;\r\n try {\r\n const model: Core.IncomeStatementLineBulkUpdateModel = {\r\n selectedRows: this.params.selection,\r\n siteId: this.params.siteId,\r\n endDate: this.params.endDate,\r\n isValidatedAction: this.updateOptions[0].action,\r\n isValidated: formValues['isValidated'],\r\n balanceAction: this.updateOptions[1].action,\r\n balance: formValues['balance']\r\n };\r\n\r\n this.result = await lastValueFrom(this._incomeStatementRepository.bulkUpdate(this.params.companyId, model));\r\n\r\n this.result = true;\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.isSaving = false;\r\n await busyRef.hide();\r\n }\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Income Statements \r\n

\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n INCOME:${{currentTotals?.income | number:'1.0-0'}}\r\n
\r\n
\r\n OPERATING EXPENSE:${{currentTotals?.operatingExpense | number:'1.0-0'}}\r\n
\r\n
\r\n OPERATING EXPENSE RATIO:{{currentTotals?.operatingExpenseRatio | percent:'1.2-2'}}\r\n
\r\n
\r\n NOI:${{currentTotals?.noi | number:'1.0-0'}}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n OPEX LESS TAX:${{currentTotals?.opexLessTax | number:'1.0-0'}}\r\n
\r\n
\r\n OPEX RATIO LESS TAX:{{currentTotals?.opexRatioLessTax | percent:'1.2-2'}}\r\n
\r\n
\r\n NOI LESS TAX:${{currentTotals?.noiLessTax | number:'1.0-0'}}\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { HotkeyService } from '../../../UI-Lib/HotKeys/hotKeys.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../../UI-Lib/Pipes';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxOptions,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { SiteRepository } from '../../../Core-Repositories';\r\nimport { ParcelService } from '../../../Entity/Parcel/parcel.service.upgrade';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { IncomeStatementAgGridDataSource, IncomeStatementDataSourceParams } from './agGridDataSource';\r\nimport { BehaviorSubject, lastValueFrom, Subject, Subscription } from 'rxjs';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport {\r\n AgGridColumns,\r\n AgGridDropdownCellEditor,\r\n AgGridFilterParams, AgGridNumberCellEditor,\r\n AgGridOptionsBuilder\r\n} from '../../../Compliance/AgGrid';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../../Compliance/AgGrid/ToolPanel/models';\r\nimport * as _ from 'lodash';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../../Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { IncomeStatementRepository } from '../incomeStatement.repository';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport {\r\n DeleteConfirmationComponent,\r\n DeleteConfirmationComponentParams\r\n} from '../../../Common/Delete-Confirmation/deleteConfirmation.component';\r\nimport {\r\n AgGridActionCellRendererComponent,\r\n AgGridActionCellRendererParams\r\n} from '../../../Compliance/AgGrid/CellRenderers/agGridActionCellRenderer.component';\r\nimport { GLAccountService } from '../../../Compliance/GL-Account/glAccount.service';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport { WeissmanDateFormatPipe } from '../../../UI-Lib/Pipes';\r\nimport {\r\n AgGridYesNoFloatingFilterComponent\r\n} from '../../../Compliance/AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport { ICellEditorParams } from 'ag-grid-community/dist/lib/interfaces/iCellEditor';\r\nimport { BulkEditButtonOptions } from '../../../Compliance/AgGrid/ToolPanel/agGridToolPanel.component';\r\nimport {\r\n AppealRecommendationCommandCenterBulkUpdateParams,\r\n ARCCBulkUpdateComponent\r\n} from '../../../Appeal-Recommendation/ARCC/ARCC-Bulk-Update/aRCCBulkUpdate.component';\r\nimport {\r\n AppealRecommendationCommandCenterBulkUpdateResultConfirmationComponentParams,\r\n ARCCBulkUpdateResultConfirmationComponent\r\n} from '../../../Appeal-Recommendation/ARCC/ARCC-Bulk-Update/ARCC-Bulk-Update-Result-Confirmation/aRCCBulkUpdateResultConfirmation.component';\r\nimport {\r\n IncomeStatementBulkUpdateComponent, IncomeStatementBulkUpdateParams\r\n} from '../Income-Statement-Bulk-Update/incomeStatementBulkUpdate.component';\r\nimport { CellEditorValidationResult } from '../../../Compliance/AgGrid/CellEditors/validator.interface';\r\n\r\n@Component({\r\n selector: 'income-statement-list',\r\n templateUrl: './incomeStatementList.component.html',\r\n styleUrls: ['./incomeStatementList.component.scss'],\r\n providers: [HotkeyService]\r\n})\r\nexport class IncomeStatementListComponent implements OnInit{\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _incomeStatementRepository: IncomeStatementRepository,\r\n private readonly _companyService: CompanyService,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _siteService: SiteRepository,\r\n private readonly _parcelService: ParcelService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _glAccountService: GLAccountService,\r\n private readonly _datePipe: WeissmanDateFormatPipe\r\n ) { }\r\n\r\n @Input() companyIdFilter: number;\r\n @Input() siteIdFilter: number;\r\n @Input() parcelIdFilter: number;\r\n @Input() isEmbededMode: boolean = false;\r\n @Input() onLoading: boolean;\r\n @Output() onLoadingChange: EventEmitter = new EventEmitter();\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n selectedTotalsLoading: boolean = true;\r\n companyId: number;\r\n newCompanyId: number;\r\n companyName: string;\r\n canEdit: boolean = false;\r\n canViewRyanPrivateItems: boolean = false;\r\n isInitialized: boolean = false;\r\n gridId: System.Guid = 'D705A9AA-2ACE-4831-82FE-09A712A451B7';\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n isBulkDeleteVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n busyRefId: string = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n filterHref: string;\r\n siteName: string;\r\n parcelName: string;\r\n selectedEndDate: Date;\r\n endDates: Date[];\r\n currentTotals: Core.IncomeStatementLineSearchTotalsModel;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Core.IncomeStatementLineModel).incomeStatementLineId),\r\n 'totals-row': (params) => params.data && params.data.totalsRow,\r\n 'selected-totals-row': (params) => params.data && params.data.selectedTotalsRow\r\n }\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const searchParams = this._gridDataSource.getSearchParamsWithoutPagination();\r\n\r\n searchParams.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n if (!searchParams.selectedRows.selectAllRows && searchParams.selectedRows.selectedRows.length === 0){\r\n searchParams.selectedRows.selectAllRows = true;\r\n }\r\n const exportModel: Compliance.IncomeStatementLineExportModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn,\r\n selectedRows: searchParams.selectedRows\r\n };\r\n\r\n const lrp$ = this._incomeStatementRepository.startIncomeStatementLineExport(this.companyId, exportModel);\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.IncomeStatementLine };\r\n },\r\n canCancel: true,\r\n showFileFormatSelection: false\r\n };\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: IncomeStatementAgGridDataSource;\r\n private _gridMultiSelectSub: Subscription;\r\n private _busyRef: BusyIndicatorRef;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n if (this.companyIdFilter) {\r\n this.companyId = this.companyIdFilter;\r\n } else {\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n }\r\n\r\n if (!this.isEmbededMode && typeof this.siteIdFilter === 'undefined') {\r\n this.siteIdFilter = parseInt(this._routerService.getQuerystringParam('siteId'));\r\n }\r\n\r\n if (!this.isEmbededMode && typeof this.parcelIdFilter === 'undefined') {\r\n this.parcelIdFilter = parseInt(this._routerService.getQuerystringParam('parcelId'));\r\n }\r\n\r\n this.newCompanyId = this.companyId;\r\n\r\n let busyRef: BusyIndicatorRef;\r\n\r\n if (this.isEmbededMode) {\r\n this.onLoading = true;\r\n this.onLoadingChange.emit(true);\r\n\r\n if(typeof this.siteIdFilter !== 'undefined') {\r\n this.filterHref = this._routerService.getHrefFromState('siteIncomeStatement', { companyId: this.companyId, siteId: this.siteIdFilter });\r\n }\r\n else if(typeof this.parcelIdFilter !== 'undefined') {\r\n this.filterHref = this._routerService.getHrefFromState('incomeStatementParcelFilter', { companyId: this.companyId, parcelId: this.parcelIdFilter });\r\n }\r\n } else {\r\n busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n }\r\n\r\n try {\r\n this.canEdit = await this._restrictService.hasCompanyPermission(this.companyId, Core.AccessRightsEnum.Write);\r\n this.canViewRyanPrivateItems = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n\r\n let sitePromise: Promise;\r\n\r\n if(!this.isEmbededMode && this.siteIdFilter) {\r\n sitePromise = lastValueFrom(this._siteService.getSiteName(this.siteIdFilter)).then(result => {\r\n this.siteName = result;\r\n });\r\n }\r\n\r\n let parcelPromise: Promise;\r\n let parcelSiteId: number;\r\n\r\n if(!this.isEmbededMode && this.parcelIdFilter) {\r\n parcelPromise = this._parcelService.getView(this.parcelIdFilter, false).then(result => {\r\n this.parcelName = result.parcel.acctNum;\r\n parcelSiteId = result.siteId;\r\n });\r\n }\r\n\r\n let companyInfo: Core.CompanyModel;\r\n\r\n const companyPromise = this._companyService.load(this.companyId, true, false);\r\n companyPromise.then((company) => {\r\n this.companyName = company.companyName;\r\n companyInfo = company;\r\n });\r\n\r\n await Promise.all([\r\n companyPromise,\r\n sitePromise,\r\n parcelPromise\r\n ]);\r\n\r\n this.breadcrumbs.push({\r\n name: this.companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n });\r\n\r\n if (this.siteName) {\r\n this.breadcrumbs.push({\r\n name: this.siteName,\r\n target: 'site',\r\n options: { companyId: this.companyId, siteId: this.siteIdFilter }\r\n });\r\n }\r\n\r\n if (this.parcelName) {\r\n this.breadcrumbs.push({\r\n name: this.parcelName,\r\n target: 'parcel',\r\n options: { companyId: this.companyId, siteId: parcelSiteId, parcelId: this.parcelIdFilter }\r\n });\r\n }\r\n\r\n await this._initEndDates();\r\n\r\n this.isInitialized = true;\r\n } finally {\r\n if(this.isEmbededMode) {\r\n this.onLoading = false;\r\n this.onLoadingChange.emit(false);\r\n }\r\n else {\r\n busyRef.hide();\r\n }\r\n }\r\n this._glAccountService.start(this.companyId);\r\n return Promise.resolve();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n this._gridApi.showLoadingOverlay();\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._setGridColumns();\r\n\r\n // notify the bulk update button (on the column tool panel) every time the grid selection changes\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(async () => {\r\n const isBulkUpdateVisible = this.canEdit && this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n this.isBulkDeleteVisible$.next(isBulkUpdateVisible);\r\n });\r\n\r\n this._setDataSource();\r\n }\r\n\r\n onEndDateChange(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n async refresh(): Promise {\r\n await this._initEndDates();\r\n await this._refreshDataSource();\r\n }\r\n\r\n async bulkDelete(): Promise {\r\n const confirmOptions = {\r\n message: 'Are you sure you want to delete selected line items?',\r\n buttons: MessageBoxButtons.OKCancel\r\n } as MessageBoxOptions;\r\n\r\n const result = await this._messageBoxService.open(confirmOptions);\r\n\r\n if (result === MessageBoxResult.OK) {\r\n\r\n const params: DeleteConfirmationComponentParams = {\r\n item: 'Income Statement Line Items',\r\n message: 'Are you sure you want to delete selected line items? If you choose to proceed, all information related to line items will be removed and cannot be recovered.'\r\n };\r\n\r\n const result = await this._modalService.showAsync(DeleteConfirmationComponent, params, 'modal-md');\r\n\r\n if (result) {\r\n this._showBusyIndicator('Bulk Delete', 'Deleting line items', null, false, false);\r\n\r\n const model: Compliance.IncomeStatementLineBulkDeleteModel = {\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp,\r\n selectAllRows: this.gridTracker.getSelectedRowsModel().selectAllRows,\r\n selectedRows: this.gridTracker.getSelectedRowsModel().selectedRows,\r\n siteId: this.siteIdFilter,\r\n endDate: this.selectedEndDate\r\n };\r\n\r\n try {\r\n const longRunningProcessId = await lastValueFrom(this._incomeStatementRepository.startBulkDelete(this.companyId, model));\r\n await this._busyRef.setLongRunningProcessId(longRunningProcessId);\r\n }\r\n catch (e) {\r\n await this._hideBusyIndicator();\r\n return Promise.reject(e);\r\n }\r\n }\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n handleTotalsUpdate = (totals: Core.IncomeStatementLineSearchTotalsModel, selectedTotals: boolean = false) => {\r\n if (!selectedTotals) {\r\n this.currentTotals = totals;\r\n }\r\n };\r\n\r\n async bulkUpdate(): Promise {\r\n const params: IncomeStatementBulkUpdateParams = {\r\n companyId: this.companyId,\r\n siteId: this.siteIdFilter,\r\n selection: this.gridTracker.getSelectedRowsModel(),\r\n selectedCount: this.gridTracker.getSelectedRowsCount(),\r\n endDate: this.selectedEndDate\r\n };\r\n\r\n const result = await this._modalService.showAsync(IncomeStatementBulkUpdateComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.gridTracker.clear();\r\n await this.refresh();\r\n const totals = await this._gridDataSource.getSelectedRowTotals({selectedRows: [], selectAllRows: true});\r\n this.handleTotalsUpdate(totals);\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private async _refreshDataSource(): Promise {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isBulkDeleteVisible$.next(false);\r\n\r\n this._gridDataSource.clearTotals();\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return false;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isBulkDeleteVisible$.next(false);\r\n\r\n const dataSourceParams = (): IncomeStatementDataSourceParams => {\r\n return {\r\n companyId: this.companyId,\r\n siteId: this.siteIdFilter,\r\n endDate: this.selectedEndDate\r\n };\r\n };\r\n\r\n this._gridDataSource = new IncomeStatementAgGridDataSource(\r\n this._gridApi,\r\n this._incomeStatementRepository,\r\n dataSourceParams,\r\n this.handleTotalsUpdate\r\n );\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private _setGridColumns(): void {\r\n this._gridApi.setColumnDefs([]);\r\n const columns = this._getGridColumnsBySource();\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setFilterModel(null);\r\n }\r\n\r\n private _getGridColumnsBySource(): ColDef[] {\r\n const columns: ColDef[] = [];\r\n\r\n const actionsColDef: ColDef = {\r\n colId: 'grid-column-actions',\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n pinned: 'right',\r\n lockVisible: true,\r\n sortable: false,\r\n cellRendererFramework: AgGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n buttonConfigs: [\r\n {\r\n iconClass: 'fa-trash',\r\n onClick: this._deleteItem.bind(this),\r\n isShown: this._canDelete.bind(this),\r\n buttonClass: 'btn-primary btn-danger',\r\n helpContentId: 'app.delete'\r\n }\r\n ]\r\n } as AgGridActionCellRendererParams\r\n };\r\n\r\n columns.push(\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'incomeStatementLineId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.GLAccountName}`,\r\n headerName: 'G/L Account',\r\n // toolPanelClass: 'Source Values',\r\n field: 'glAccountName',\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.CompanyName}`,\r\n headerName: 'Company',\r\n // toolPanelClass: 'Source Values',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.TopLevelCompanyName}`,\r\n headerName: 'Top Level Company',\r\n // toolPanelClass: 'Source Values',\r\n field: 'topLevelCompanyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.SiteName}`,\r\n headerName: 'Site',\r\n // toolPanelClass: 'Source Values',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const lineItem = params.data as Core.IncomeStatementLineModel;\r\n // if (! lineItem && lineItem.sourceSite)) {\r\n if (! lineItem ) {\r\n return '';\r\n }\r\n return `#/site/${lineItem.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.SiteNumber}`,\r\n headerName: 'Site Number',\r\n field: 'siteNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const lineItem = params.data as Core.IncomeStatementLineModel;\r\n // if (! lineItem && lineItem.sourceSite)) {\r\n if (! lineItem ) {\r\n return '';\r\n }\r\n return `#/site/${lineItem.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.IsValidated}`,\r\n headerName: 'Validated',\r\n field: 'isValidated',\r\n type: 'textColumn',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const data = params.data as Core.IncomeStatementLineModel;\r\n return data && data.incomeStatementLineId\r\n ? data.isValidated === true ? 'Yes' : 'No'\r\n : '-';\r\n },\r\n editable: params => {\r\n const data = params.data as Core.IncomeStatementLineModel;\r\n return !!data.incomeStatementLineId;\r\n },\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => {\r\n return [\r\n {name: 'Yes', value: true},\r\n {name: 'No', value: false}\r\n ];\r\n },\r\n cellFocusLost: (params, updatedValue) => this._updateIsValidated(params, updatedValue)\r\n },\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.GLAccountNumber}`,\r\n headerName: 'G/L Account Number',\r\n // toolPanelClass: 'Source Values',\r\n field: 'glAccountNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.GLAccountDescription}`,\r\n headerName: 'G/L Account Description',\r\n // toolPanelClass: 'Source Values',\r\n field: 'glAccountDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.GLAccountIncomeStatementCategoryName}`,\r\n headerName: 'Category',\r\n // toolPanelClass: 'Asset',\r\n field: 'glAccountIncomeStatementCategoryName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.GLAccountIncomeStatementCategoryTypeName}`,\r\n headerName: 'Account Type',\r\n // toolPanelClass: 'Asset',\r\n field: 'glAccountIncomeStatementCategoryTypeName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.CalculatedBalance}`,\r\n headerName: 'Balance',\r\n // toolPanelClass: 'Source Values',\r\n field: 'calculatedBalance',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n cellClassRules: {\r\n 'overridden': params => {\r\n const data = params.data as Core.IncomeStatementLineModel;\r\n return data && data.incomeStatementLineId && data.calculatedBalance != null && data.calculatedBalance !== data.importedBalance;\r\n },\r\n 'inline-editor-disabled': params => {\r\n const data = params.data as Core.IncomeStatementLineModel;\r\n return data && data.incomeStatementLineId && data.isValidated;\r\n }\r\n },\r\n editable: params => {\r\n const data = params.data as Core.IncomeStatementLineModel;\r\n return data && data.incomeStatementLineId && !data.isValidated;\r\n },\r\n cellEditorFramework: AgGridNumberCellEditor,\r\n cellEditorParams: {\r\n allowNull: true,\r\n cellFocusLost: (params, updatedValue) => this._updateBalance(params, updatedValue),\r\n validator: (value: number): CellEditorValidationResult => {\r\n return value > 9999999999999992\r\n ? {isValid: false, validationMessage: 'Value is too big'}\r\n : {isValid: true, validationMessage: ''};\r\n }\r\n },\r\n tooltipValueGetter: params => {\r\n const data = params.data as Core.IncomeStatementLineModel;\r\n return data && data.incomeStatementLineId && data.isValidated\r\n ? 'May not edit a validated line item.'\r\n : '';\r\n }\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.AccountHierarchyDescription}`,\r\n headerName: 'Account Hierarchy Description',\r\n // toolPanelClass: 'Source Values',\r\n field: 'accountHierarchyDescription',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.CreateDate}`,\r\n headerName: 'Import Date',\r\n field: 'createDate',\r\n type: 'dateColumn',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true),\r\n cellClass: 'ag-date-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.ValidatedBy}`,\r\n headerName: 'Validated By',\r\n field: 'validatedBy',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.IncomeStatementLinePropertyEnum.ValidatedDate}`,\r\n headerName: 'Validated Date',\r\n field: 'validatedDate',\r\n type: 'dateColumn',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true),\r\n cellClass: 'ag-date-cell',\r\n hide: true\r\n } as ColDef,\r\n actionsColDef\r\n );\r\n\r\n return columns;\r\n }\r\n\r\n private async _deleteItem(params: AgGridActionCellRendererParams): Promise {\r\n const item = params.data as Core.IncomeStatementLineModel;\r\n\r\n if(!item) {\r\n return;\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n `Are you sure you wish to delete ${item.glAccountName}?`,\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n try {\r\n await lastValueFrom(this._incomeStatementRepository.deleteItem(item.incomeStatementLineId));\r\n await this._initEndDates();\r\n this.refresh();\r\n return Promise.resolve(true);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n }\r\n\r\n private _canDelete(params: AgGridActionCellRendererParams): boolean {\r\n return this.canEdit;\r\n }\r\n\r\n private async _reloadTotals(): Promise {\r\n if (!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.selectedTotalsLoading = true;\r\n\r\n try {\r\n const result = await this._gridDataSource.getSelectedRowTotals(this.gridTracker.getSelectedRowsModel());\r\n this.selectedTotalsLoading = false;\r\n this.handleTotalsUpdate(result, true);\r\n }\r\n finally {\r\n this.selectedTotalsLoading = false;\r\n }\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', lrpId: number, canDismiss = true, hasProgressBar = true): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: lrpId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: hasProgressBar,\r\n canDismiss\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success) => {\r\n await this._hideBusyIndicator();\r\n if (success) {\r\n await this._initEndDates();\r\n await this.refresh();\r\n }\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._destroy$.next();\r\n }\r\n\r\n private async _initEndDates() {\r\n this.endDates = await lastValueFrom(this._incomeStatementRepository.getIncomeStatementEndDates(this.companyId, this.siteIdFilter));\r\n\r\n if(!_.includes(this.endDates, this.selectedEndDate)) {\r\n this.selectedEndDate = _.maxBy(this.endDates, x => new Date(x));\r\n }\r\n }\r\n\r\n private async _updateIsValidated(params: ICellEditorParams, updatedValue: boolean): Promise {\r\n const data = params.data as Core.IncomeStatementLineModel;\r\n\r\n if (!data) {\r\n return Promise.resolve();\r\n }\r\n\r\n const initialValue = params.value;\r\n if (updatedValue === initialValue) {\r\n return Promise.resolve();\r\n }\r\n\r\n const updateModel: Core.IncomeStatementLineItemIsValidatedUpdateModel = {\r\n incomeStatementLineId: data.incomeStatementLineId,\r\n isValidated: updatedValue,\r\n rowVersion: data.rowVersion\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n\r\n try {\r\n const result = await lastValueFrom(this._incomeStatementRepository.updateIsValidated(updateModel));\r\n data.isValidated = result.isValidated;\r\n data.validatedBy = result.validatedBy;\r\n data.validatedDate = result.validatedDate;\r\n data.rowVersion = result.rowVersion;\r\n } catch (e) {\r\n data.isValidated = initialValue;\r\n throw e;\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n params.node.setData(data);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private async _updateBalance(params: ICellEditorParams, updatedValue?: number): Promise {\r\n const data = params.data as Core.IncomeStatementLineModel;\r\n\r\n if (!data) {\r\n return Promise.resolve();\r\n }\r\n\r\n const initialValue = params.value;\r\n if (updatedValue === initialValue) {\r\n return Promise.resolve();\r\n }\r\n\r\n const updateModel: Core.IncomeStatementLineBalanceUpdateModel = {\r\n incomeStatementLineId: data.incomeStatementLineId,\r\n balance: updatedValue,\r\n rowVersion: data.rowVersion\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n\r\n try {\r\n data.rowVersion = await lastValueFrom(this._incomeStatementRepository.updateBalance(updateModel));\r\n data.calculatedBalance = updatedValue || data.importedBalance;\r\n } catch (e) {\r\n data.calculatedBalance = initialValue;\r\n throw e;\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n params.node.setData(data);\r\n\r\n const totals = await this._gridDataSource.getSelectedRowTotals({selectedRows: [], selectAllRows: true});\r\n this.handleTotalsUpdate(totals);\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from '../../../Compliance/AgGrid';\r\nimport { RentRollRepository } from '../rentRoll.repository';\r\n\r\nexport interface RentRollDataSourceParams {\r\n companyId: number;\r\n endDate?: Date;\r\n siteId?: number;\r\n}\r\n\r\nexport class RentRollAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _rentRollRepository: RentRollRepository,\r\n protected _dataSourceParamsFn: () => RentRollDataSourceParams,\r\n private readonly _totalsUpdateCallback: (totals: Core.RentRollLineItemSearchTotalModel, selectedTotals?: boolean, isLoading?: boolean) => void\r\n ) { super(_gridApi); }\r\n\r\n lastFetchedTotals: Core.RentRollLineItemSearchTotalModel;\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n {name: `${Core.RentRollLineItemPropertyEnum.CompanyName}`, value: Core.RentRollLineItemPropertyEnum.CompanyName },\r\n\t\t{name: `${Core.RentRollLineItemPropertyEnum.TopLevelCompanyName}`, value: Core.RentRollLineItemPropertyEnum.TopLevelCompanyName },\r\n\t\t{name: `${Core.RentRollLineItemPropertyEnum.SiteName}`, value: Core.RentRollLineItemPropertyEnum.SiteName },\r\n\t\t{name: `${Core.RentRollLineItemPropertyEnum.SiteNumber}`, value: Core.RentRollLineItemPropertyEnum.SiteNumber },\r\n\t\t{name: `${Core.RentRollLineItemPropertyEnum.Bed}`, value: Core.RentRollLineItemPropertyEnum.Bed },\r\n\t\t{name: `${Core.RentRollLineItemPropertyEnum.Unit}`, value: Core.RentRollLineItemPropertyEnum.Unit },\r\n\t\t{name: `${Core.RentRollLineItemPropertyEnum.UnitType}`, value: Core.RentRollLineItemPropertyEnum.UnitType },\r\n\t\t{name: `${Core.RentRollLineItemPropertyEnum.Bath}`, value: Core.RentRollLineItemPropertyEnum.Bath },\r\n {name: `${Core.RentRollLineItemPropertyEnum.SqFt}`, value: Core.RentRollLineItemPropertyEnum.SqFt },\r\n {name: `${Core.RentRollLineItemPropertyEnum.Tenant}`, value: Core.RentRollLineItemPropertyEnum.Tenant },\r\n {name: `${Core.RentRollLineItemPropertyEnum.RentRollLineItemStatusName}`, value: Core.RentRollLineItemPropertyEnum.RentRollLineItemStatusName },\r\n {name: `${Core.RentRollLineItemPropertyEnum.LeaseBegin}`, value: Core.RentRollLineItemPropertyEnum.LeaseBegin },\r\n {name: `${Core.RentRollLineItemPropertyEnum.LeaseEnd}`, value: Core.RentRollLineItemPropertyEnum.LeaseEnd },\r\n {name: `${Core.RentRollLineItemPropertyEnum.MoveIn}`, value: Core.RentRollLineItemPropertyEnum.MoveIn },\r\n {name: `${Core.RentRollLineItemPropertyEnum.MoveOut}`, value: Core.RentRollLineItemPropertyEnum.MoveOut },\r\n {name: `${Core.RentRollLineItemPropertyEnum.BaseRate}`, value: Core.RentRollLineItemPropertyEnum.BaseRate },\r\n {name: `${Core.RentRollLineItemPropertyEnum.PctOfBuilding}`, value: Core.RentRollLineItemPropertyEnum.PctOfBuilding },\r\n {name: `${Core.RentRollLineItemPropertyEnum.AnnualRent}`, value: Core.RentRollLineItemPropertyEnum.AnnualRent },\r\n {name: `${Core.RentRollLineItemPropertyEnum.AnnualMarketRent}`, value: Core.RentRollLineItemPropertyEnum.AnnualMarketRent },\r\n {name: `${Core.RentRollLineItemPropertyEnum.AnnualOther}`, value: Core.RentRollLineItemPropertyEnum.AnnualOther },\r\n {name: `${Core.RentRollLineItemPropertyEnum.AnnualCAM}`, value: Core.RentRollLineItemPropertyEnum.AnnualCAM },\r\n {name: `${Core.RentRollLineItemPropertyEnum.MonthlyRent}`, value: Core.RentRollLineItemPropertyEnum.MonthlyRent },\r\n {name: `${Core.RentRollLineItemPropertyEnum.MonthlyMarketRent}`, value: Core.RentRollLineItemPropertyEnum.MonthlyMarketRent },\r\n {name: `${Core.RentRollLineItemPropertyEnum.MonthlyOther}`, value: Core.RentRollLineItemPropertyEnum.MonthlyOther },\r\n {name: `${Core.RentRollLineItemPropertyEnum.MonthlyCAM}`, value: Core.RentRollLineItemPropertyEnum.MonthlyCAM },\r\n {name: `${Core.RentRollLineItemPropertyEnum.BuildingId}`, value: Core.RentRollLineItemPropertyEnum.BuildingId },\r\n {name: `${Core.RentRollLineItemPropertyEnum.CreateDate}`, value: Core.RentRollLineItemPropertyEnum.CreateDate },\r\n {name: `${Core.RentRollLineItemPropertyEnum.IsValidated}`, value: Core.RentRollLineItemPropertyEnum.IsValidated },\r\n {name: `${Core.RentRollLineItemPropertyEnum.ValidatedDate}`, value: Core.RentRollLineItemPropertyEnum.ValidatedDate },\r\n {name: `${Core.RentRollLineItemPropertyEnum.ValidatedBy}`, value: Core.RentRollLineItemPropertyEnum.ValidatedBy }\r\n ];\r\n\r\n private _lastFilterUsedInTotals: string;\r\n\r\n clearTotals(): void {\r\n this._lastFilterUsedInTotals = '';\r\n }\r\n\r\n getSearchParamsWithoutPagination() : Core.RentRollLineItemSearchModel{\r\n this.refreshDataSourceParams();\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n selectedRows: null,\r\n endDate: this._dataSourceParams.endDate,\r\n siteId: this._dataSourceParams.siteId\r\n };\r\n }\r\n\r\n public async getSelectedRowTotals(selectedRowsModel: Compliance.SelectedRowsModel): Promise {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.selectedRows = selectedRowsModel;\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: 100\r\n };\r\n\r\n const result = await lastValueFrom(this._rentRollRepository.getRentRollList(this._dataSourceParams.companyId, searchParams));\r\n\r\n return result.totals;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.RentRollLineItemSearchModel = {\r\n pagination: {\r\n skip: startIndex,\r\n take: endIndex - startIndex + 1\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n selectedRows: null,\r\n siteId: this._dataSourceParams.siteId,\r\n endDate: this._dataSourceParams.endDate\r\n };\r\n\r\n return await lastValueFrom(this._rentRollRepository.getRentRollRowIds(this._dataSourceParams.companyId, searchParams));\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n const canGetRows = !!this._dataSourceParams.companyId;\r\n if (!canGetRows) {\r\n this.clearTotals();\r\n this._totalsUpdateCallback(null);\r\n }\r\n return canGetRows;\r\n }\r\n\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n this._gridApi.setPinnedBottomRowData([]);\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n const searchParamsString = JSON.stringify(searchParams);\r\n const fetchTotals: boolean = (!this.lastFetchedTotals) || (this._lastFilterUsedInTotals !== searchParamsString);\r\n\r\n this._lastFilterUsedInTotals = searchParamsString;\r\n\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const result = await lastValueFrom(this._rentRollRepository.getRentRollList(this._dataSourceParams.companyId, searchParams));\r\n\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals);\r\n\r\n const dataSourceResult: AgGridDataSourceResult = {\r\n rows: result.data,\r\n totalRows: result.totalRows,\r\n lastModifiedTimestamp: result.lastModifiedTimestamp\r\n };\r\n\r\n if (fetchTotals) {\r\n this._getAllRowTotals(params);\r\n }\r\n\r\n return dataSourceResult;\r\n }\r\n\r\n private async _getAllRowTotals(params: IGetRowsParams): Promise {\r\n this._totalsUpdateCallback(this.lastFetchedTotals, false, true);\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n\r\n searchParams.pagination = {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n };\r\n\r\n const result = await lastValueFrom(this._rentRollRepository.getRentRollList(this._dataSourceParams.companyId, searchParams));\r\n\r\n this.lastFetchedTotals = result.totals;\r\n this._totalsUpdateCallback(this.lastFetchedTotals);\r\n\r\n return result.totals;\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForRentRollGridAction extends ICellRendererParams {\r\n canDelete: (params: ICellRendererParamsForRentRollGridAction) => boolean;\r\n delete: (params: ICellRendererParamsForRentRollGridAction) => void;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n ``\r\n})\r\nexport class RentRollGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForRentRollGridAction;\r\n canDelete: boolean;\r\n\r\n agInit(params: ICellRendererParamsForRentRollGridAction): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onDeleteClicked(): void {\r\n this.params.delete(this.params);\r\n }\r\n}\r\n","import { Component, ElementRef, OnInit, ViewChild } from '@angular/core';\r\nimport { BulkUpdateDynamicBase, BulkUpdateOption } from '../../../UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BusyIndicatorMessageManager, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { UntypedFormBuilder, UntypedFormControl } from '@angular/forms';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { RentRollRepository } from '../rentRoll.repository';\r\n\r\nexport interface RentRollBulkUpdateParams {\r\n companyId: number;\r\n siteId?: number;\r\n selection: Compliance.SelectedRowsModel;\r\n selectedCount: number;\r\n endDate?: Date;\r\n}\r\n\r\n@Component({\r\n selector: 'rent-roll-bulk-update',\r\n templateUrl: '../../../UI-Lib/Bulk-Update/bulkUpdateDynamicBase.component.html',\r\n})\r\nexport class RentRollBulkUpdateComponent extends BulkUpdateDynamicBase implements OnInit, IWeissmanModalComponent{\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _rentRollRepository: RentRollRepository,\r\n _bsModalRef: BsModalRef,\r\n _fb: UntypedFormBuilder\r\n ) {\r\n super(_bsModalRef, _fb);\r\n }\r\n\r\n @ViewChild('picklist', { static: true }) picklistTemplate: ElementRef;\r\n\r\n params: RentRollBulkUpdateParams;\r\n result: boolean = false;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n isSaving: boolean = false;\r\n\r\n ngOnInit(): void {\r\n this.header = `Bulk Update ${this.params.selectedCount} Records`;\r\n\r\n this._templateMap = new Map([\r\n [Core.DescriptorFieldTypes.Picklist, this.picklistTemplate]\r\n ]);\r\n\r\n const isValidatedControl = new UntypedFormControl(null);\r\n isValidatedControl.disable();\r\n this.bulkUpdateForm.addControl('isValidated', isValidatedControl);\r\n\r\n this.updateOptions.push({\r\n name: 'Validate',\r\n isRequired: true,\r\n template: this._templateMap.get(Core.DescriptorFieldTypes.Picklist),\r\n picklist: [\r\n {value: true, name: 'Validated'} as Compliance.NameValuePair,\r\n {value: false, name: 'Not Validated'} as Compliance.NameValuePair\r\n ],\r\n action: Core.RentRollLineItemBulkUpdateActionEnum.NoChange,\r\n hiddenField: Core.RentRollLineItemBulkUpdateActionEnum.RemoveOverride,\r\n formControlName: 'isValidated',\r\n formControl: isValidatedControl\r\n } as BulkUpdateOption);\r\n }\r\n\r\n async save(): Promise {\r\n this.isSaving = true;\r\n await this._bulkUpdate();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private async _bulkUpdate(): Promise {\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n\r\n const formValues = this.bulkUpdateForm.value;\r\n try {\r\n const model: Core.RentRollLineItemBulkUpdateModel = {\r\n selectedRows: this.params.selection,\r\n siteId: this.params.siteId,\r\n endDate: this.params.endDate,\r\n isValidatedAction: this.updateOptions[0].action,\r\n isValidated: formValues['isValidated']\r\n };\r\n\r\n this.result = await lastValueFrom(this._rentRollRepository.bulkUpdate(this.params.companyId, model));\r\n\r\n this.result = true;\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.isSaving = false;\r\n await busyRef.hide();\r\n }\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Rent Rolls \r\n

\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n OCCUPANCY SF:{{rentRollGridTotalsRow?.occupancySqFt | number:'1.0-0'}}\r\n
\r\n
\r\n VACANCY SF:{{rentRollGridTotalsRow?.vacancySqFt | number:'1.0-0'}}\r\n
\r\n
\r\n TOTAL SF:{{rentRollGridTotalsRow?.totalSqFt | number:'1.0-0'}}\r\n
\r\n
\r\n OCCUPIED UNITS:{{rentRollGridTotalsRow?.occupiedUnits | number:'1.0-0'}}\r\n
\r\n
\r\n VACANT UNITS:{{rentRollGridTotalsRow?.vacantUnits | number:'1.0-0'}}\r\n
\r\n
\r\n TOTAL UNITS:{{rentRollGridTotalsRow?.totalUnits | number:'1.0-0'}}\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { HotkeyService } from '../../../UI-Lib/HotKeys/hotKeys.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { WeissmanDateFormatPipe } from '../../../UI-Lib/Pipes';\r\nimport { DecimalPipe, PercentPipe } from '@angular/common';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../../UI-Lib/Pipes';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { RestrictService, Roles } from '../../../Common/Permissions/restrict.service';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxOptions,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { SiteRepository } from '../../../Core-Repositories';\r\nimport { ParcelService } from '../../../Entity/Parcel/parcel.service.upgrade';\r\nimport {\r\n CellClassParams,\r\n ColDef,\r\n GridApi,\r\n GridOptions,\r\n GridReadyEvent,\r\n ICellEditorParams,\r\n ValueFormatterParams\r\n} from 'ag-grid-community';\r\nimport { RentRollAgGridDataSource, RentRollDataSourceParams } from './agGridDataSource';\r\nimport { BehaviorSubject, lastValueFrom, Subject, Subscription } from 'rxjs';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport {\r\n AgGridColumns,\r\n AgGridDropdownCellEditor,\r\n AgGridFilterParams,\r\n AgGridOptionsBuilder\r\n} from '../../../Compliance/AgGrid';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../../Compliance/AgGrid/ToolPanel/models';\r\nimport * as _ from 'lodash';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../../Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { RentRollRepository } from '../rentRoll.repository';\r\nimport {\r\n ICellRendererParamsForRentRollGridAction,\r\n RentRollGridActionCellRendererComponent\r\n} from './agGridActionCellRendererComponent';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport {\r\n DeleteConfirmationComponent,\r\n DeleteConfirmationComponentParams\r\n} from '../../../Common/Delete-Confirmation/deleteConfirmation.component';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport {\r\n AgGridYesNoFloatingFilterComponent\r\n} from '../../../Compliance/AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport {\r\n RentRollBulkUpdateComponent,\r\n RentRollBulkUpdateParams\r\n} from '../Rent-Roll-Bulk-Update/rentRollBulkUpdate.component';\r\n\r\n@Component({\r\n selector: 'rent-roll-list',\r\n templateUrl: './rentRollList.component.html',\r\n styleUrls: ['./rentRollList.component.scss'],\r\n providers: [HotkeyService]\r\n})\r\nexport class RentRollListComponent implements OnInit {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _rentRollRepository: RentRollRepository,\r\n private readonly _companyService: CompanyService,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _percentPipe: PercentPipe,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _helpService: HelpService,\r\n private readonly _hotkeyService: HotkeyService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _siteService: SiteRepository,\r\n private readonly _parcelService: ParcelService,\r\n private readonly _messageModalService: MessageModalService\r\n ) { }\r\n\r\n @Input() companyIdFilter: number;\r\n @Input() siteIdFilter: number;\r\n @Input() parcelIdFilter: number;\r\n @Input() isEmbededMode: boolean = false;\r\n @Input() onLoading: boolean;\r\n @Output() onLoadingChange: EventEmitter = new EventEmitter();\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n rentRollGridTotalsRow: any;\r\n rentRollGridSelectedTotalsRow: any;\r\n selectedTotalsLoading: boolean = true;\r\n companyId: number;\r\n newCompanyId: number;\r\n companyName: string;\r\n canEdit: boolean = false;\r\n canViewRyanPrivateItems: boolean = false;\r\n isInitialized: boolean = false;\r\n gridId: System.Guid = '8BD07243-8F4D-403E-BC70-54401905DF14';\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n isBulkDeleteVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n totalsLoading: any;\r\n busyRefId: string = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n filterHref: string;\r\n siteName: string;\r\n parcelName: string;\r\n siteId: number;\r\n selectedEndDate: Date;\r\n endDates: Date[];\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Core.RentRollLineItemModel).rentRollLineItemId),\r\n 'totals-row': (params) => params.data && params.data.totalsRow,\r\n 'selected-totals-row': (params) => params.data && params.data.selectedTotalsRow\r\n }\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const searchParams = this._gridDataSource.getSearchParamsWithoutPagination();\r\n\r\n searchParams.selectedRows = this.gridTracker.getSelectedRowsModel();\r\n if (!searchParams.selectedRows.selectAllRows && searchParams.selectedRows.selectedRows.length === 0){\r\n searchParams.selectedRows.selectAllRows = true;\r\n }\r\n const exportModel: Compliance.RentRollLineItemExportModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn,\r\n selectedRows: searchParams.selectedRows\r\n };\r\n\r\n const lrp$ = this._rentRollRepository.startRentRollExport(this.companyId, exportModel);\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.RentRollLineItem };\r\n },\r\n canCancel: true\r\n };\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: RentRollAgGridDataSource;\r\n private _gridMultiSelectSub: Subscription;\r\n private _busyRef: BusyIndicatorRef;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get refreshing(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n // this._helpService.setContent(ASSET_LIST_HELP);\r\n // this._hotkeyService.add({ keys: 'alt.r' }).subscribe(() => this.gridTracker.getSelectedRowsCount() && this.bulkUpdate('r'));\r\n\r\n if(this.companyIdFilter) {\r\n this.companyId = this.companyIdFilter;\r\n } else {\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n }\r\n\r\n if(!this.isEmbededMode && typeof this.siteIdFilter === 'undefined') {\r\n this.siteIdFilter = parseInt(this._routerService.getQuerystringParam('siteId'));\r\n }\r\n\r\n if(!this.isEmbededMode && typeof this.parcelIdFilter === 'undefined') {\r\n this.parcelIdFilter = parseInt(this._routerService.getQuerystringParam('parcelId'));\r\n }\r\n\r\n this.newCompanyId = this.companyId;\r\n\r\n let busyRef: BusyIndicatorRef;\r\n\r\n if(this.isEmbededMode) {\r\n this.onLoading = true;\r\n this.onLoadingChange.emit(true);\r\n\r\n if(typeof this.siteIdFilter !== 'undefined') {\r\n this.filterHref = this._routerService.getHrefFromState('siteRentRoll', { companyId: this.companyId, siteId: this.siteIdFilter });\r\n }\r\n else if(typeof this.parcelIdFilter !== 'undefined') {\r\n this.filterHref = this._routerService.getHrefFromState('rentRollParcelFilter', { companyId: this.companyId, parcelId: this.parcelIdFilter });\r\n }\r\n }\r\n else {\r\n busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n }\r\n\r\n try {\r\n this.canEdit = await this._restrictService.hasCompanyPermission(this.companyId, Core.AccessRightsEnum.Write);\r\n this.canViewRyanPrivateItems = this._restrictService.isInRole(Roles.RYANPRIVATEITEMSVIEW);\r\n\r\n let sitePromise: Promise;\r\n\r\n if(!this.isEmbededMode && this.siteIdFilter) {\r\n sitePromise = lastValueFrom(this._siteService.getSiteName(this.siteIdFilter)).then(result => {\r\n this.siteName = result;\r\n });\r\n }\r\n\r\n let parcelPromise: Promise;\r\n\r\n if(!this.isEmbededMode && this.parcelIdFilter) {\r\n parcelPromise = this._parcelService.getView(this.parcelIdFilter, false).then(result => {\r\n this.parcelName = result.parcel.acctNum;\r\n this.siteId = result.siteId;\r\n });\r\n }\r\n\r\n let companyInfo: Core.CompanyModel;\r\n\r\n const companyPromise = this._companyService.load(this.companyId, true, false);\r\n companyPromise.then((company) => {\r\n this.companyName = company.companyName;\r\n companyInfo = company;\r\n });\r\n\r\n await Promise.all([\r\n companyPromise,\r\n sitePromise,\r\n parcelPromise\r\n ]);\r\n\r\n this.breadcrumbs.push({\r\n name: this.companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n });\r\n\r\n if(this.siteName) {\r\n this.breadcrumbs.push({\r\n name: this.siteName,\r\n target: 'site',\r\n options: { companyId: this.companyId, siteId: this.siteIdFilter }\r\n });\r\n }\r\n\r\n if(this.parcelName) {\r\n this.breadcrumbs.push({\r\n name: this.parcelName,\r\n target: 'parcel',\r\n options: { companyId: this.companyId, siteId: this.siteId, parcelId: this.parcelIdFilter }\r\n });\r\n }\r\n\r\n this.endDates = await lastValueFrom(this._rentRollRepository.getRentRollEndDates(this.companyId, this.siteIdFilter));\r\n this.selectedEndDate = _.maxBy(this.endDates, x => new Date(x));\r\n\r\n this.isInitialized = true;\r\n } finally {\r\n if(this.isEmbededMode) {\r\n this.onLoading = false;\r\n this.onLoadingChange.emit(false);\r\n }\r\n else {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n this._gridApi.showLoadingOverlay();\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._setGridColumns();\r\n\r\n // notify the bulk update button (on the column tool panel) every time the grid selection changes\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(async () => {\r\n const isBulkUpdateVisible = this.canEdit && this.gridTracker.hasSelectedRows();\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n this.isBulkDeleteVisible$.next(isBulkUpdateVisible);\r\n await this._reloadTotals();\r\n });\r\n\r\n // if(!this.isEmbededMode && this.parcelIdFilter) {\r\n // const parcelFilterModel = {\r\n // [Core.RentRollLineItemPropertyEnum.ParcelName]: {\r\n // \"filterType\": \"text\",\r\n // \"filterConditionType\": 0,\r\n // \"filterValues\": [\r\n // {\r\n // \"filterValue\": this.parcelName,\r\n // \"filterType\": {\r\n // \"displayKey\": \"equals\",\r\n // \"displayName\": \"Equals\",\r\n // \"hideFilterInput\": false\r\n // }\r\n // }\r\n // ]\r\n // }\r\n // };\r\n\r\n // this.gridOptions.floatingFilter = true;\r\n // this._gridApi.setFilterModel(parcelFilterModel);\r\n // }\r\n this._setDataSource();\r\n }\r\n\r\n onEndDateChange(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n async refresh(): Promise {\r\n await this._refreshDataSource();\r\n }\r\n\r\n async bulkDelete(): Promise {\r\n const confirmOptions = {\r\n message: 'Are you sure you want to delete selected line items?',\r\n buttons: MessageBoxButtons.OKCancel\r\n } as MessageBoxOptions;\r\n\r\n const result = await this._messageBoxService.open(confirmOptions);\r\n\r\n if (result === MessageBoxResult.OK) {\r\n\r\n const params: DeleteConfirmationComponentParams = {\r\n item: 'Rent Roll Line Items',\r\n message: 'Are you sure you want to delete selected line items? If you choose to proceed, all information related to line items will be removed and cannot be recovered.'\r\n };\r\n\r\n const response = await this._modalService.showAsync(DeleteConfirmationComponent, params, 'modal-md');\r\n\r\n if (response) {\r\n this._showBusyIndicator('Bulk Delete', 'Deleting line items', null, false, false);\r\n\r\n const model: Compliance.RentRollLineItemBulkDeleteModel = {\r\n lastModifiedTimestamp: this._gridDataSource.lastModifiedTimestamp,\r\n selectAllRows: this.gridTracker.getSelectedRowsModel().selectAllRows,\r\n selectedRows: this.gridTracker.getSelectedRowsModel().selectedRows,\r\n siteId: this.siteIdFilter,\r\n endDate: this.selectedEndDate\r\n };\r\n\r\n try {\r\n const longRunningProcessId = await lastValueFrom(this._rentRollRepository.startBulkDelete(this.companyId, model));\r\n await this._busyRef.setLongRunningProcessId(longRunningProcessId);\r\n }\r\n catch (e) {\r\n await this._hideBusyIndicator();\r\n return Promise.reject(e);\r\n }\r\n }\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n handleTotalsUpdate = (totals: Core.RentRollLineItemSearchTotalModel, selectedTotals: boolean = false, isLoading: boolean = false) => {\r\n const model = {\r\n //cost: totals.totalCost,\r\n //sourceCost: totals.totalSourceCost,\r\n };\r\n const rentRollRow: any = {\r\n model: model,\r\n getModel: () => { return model; },\r\n displayPipe: this._keyValueDisplayPipe,\r\n index: 0,\r\n sqFt: totals && totals.sqFt,\r\n annualMarketRent: totals && totals.annualMarketRent,\r\n annualMarketRentCalculated: totals && totals.annualMarketRent,\r\n monthlyMarketRent: totals && totals.monthlyMarketRent,\r\n monthlyMarketRentCalculated: totals && totals.monthlyMarketRent,\r\n annualRent: totals && totals.annualRent,\r\n annualRentCalculated: totals && totals.annualRent,\r\n monthlyRent: totals && totals.monthlyRent,\r\n monthlyRentCalculated: totals && totals.monthlyRent,\r\n annualOther: totals && totals.annualOther,\r\n annualOtherCalculated: totals && totals.annualOther,\r\n monthlyOther: totals && totals.monthlyOther,\r\n monthlyOtherCalculated: totals && totals.monthlyOther,\r\n annualCAM: totals && totals.annualCAM,\r\n annualCAMCalculated: totals && totals.annualCAM,\r\n monthlyCAM: totals && totals.monthlyCAM,\r\n monthlyCAMCalculated: totals && totals.monthlyCAM,\r\n occupancySqFt: totals && totals.occupancySqFt,\r\n vacancySqFt: totals && totals.vacancySqFt,\r\n totalSqFt: totals && totals.totalSqFt,\r\n occupiedUnits: totals && totals.occupiedUnits,\r\n vacantUnits: totals && totals.vacantUnits,\r\n totalUnits: totals && totals.totalUnits,\r\n // balance: totals && totals.totalBalance,\r\n unit: 'TOTAL'\r\n };\r\n\r\n if (isLoading) {\r\n this.totalsLoading = this._gridDataSource.getLoadingMessage(msg => {\r\n rentRollRow.unit = msg;\r\n this._gridApi.setPinnedBottomRowData([rentRollRow]);\r\n });\r\n return;\r\n } else if (!isLoading && this.totalsLoading >= 0) {\r\n clearInterval(this.totalsLoading);\r\n this.totalsLoading = null;\r\n }\r\n\r\n if (selectedTotals) {\r\n rentRollRow.selectedTotalsRow = true;\r\n rentRollRow.unit ='SELECTED';\r\n this.rentRollGridSelectedTotalsRow = rentRollRow;\r\n } else {\r\n rentRollRow.totalsRow = true;\r\n this.rentRollGridTotalsRow = rentRollRow;\r\n }\r\n const totalRows = [this.rentRollGridTotalsRow];\r\n if (this.gridTracker.hasAnythingSelected()) {\r\n totalRows.push(this.rentRollGridSelectedTotalsRow);\r\n }\r\n setTimeout(() => this._gridApi.setPinnedBottomRowData(totalRows), 100);\r\n };\r\n\r\n async bulkUpdate(): Promise {\r\n const params: RentRollBulkUpdateParams = {\r\n companyId: this.companyId,\r\n siteId: this.siteIdFilter,\r\n selection: this.gridTracker.getSelectedRowsModel(),\r\n selectedCount: this.gridTracker.getSelectedRowsCount(),\r\n endDate: this.selectedEndDate\r\n };\r\n\r\n const result = await this._modalService.showAsync(RentRollBulkUpdateComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.gridTracker.clear();\r\n await this.refresh();\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private async _refreshDataSource(): Promise {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isBulkDeleteVisible$.next(false);\r\n\r\n this._gridDataSource.clearTotals();\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return false;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkUpdateVisible$.next(false);\r\n this.isBulkDeleteVisible$.next(false);\r\n\r\n const dataSourceParams = (): RentRollDataSourceParams => {\r\n return {\r\n companyId: this.companyId,\r\n siteId: this.siteIdFilter,\r\n endDate: this.selectedEndDate\r\n };\r\n };\r\n\r\n this._gridDataSource = new RentRollAgGridDataSource(\r\n this._gridApi,\r\n this._rentRollRepository,\r\n dataSourceParams,\r\n this.handleTotalsUpdate\r\n );\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private _setGridColumns(): void {\r\n this._gridApi.setColumnDefs([]);\r\n const columns = this._getGridColumnsBySource();\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setFilterModel(null);\r\n }\r\n\r\n private _getGridColumnsBySource(): ColDef[] {\r\n const columns: ColDef[] = [];\r\n\r\n const actionsColDef: ColDef = {\r\n colId: 'grid-column-actions',\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n pinned: 'right',\r\n lockVisible: true,\r\n sortable: false,\r\n cellRendererFramework: RentRollGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canDelete: (params) => true,\r\n delete: this._deleteItem.bind(this)\r\n } as ICellRendererParamsForRentRollGridAction,\r\n pinnedRowCellRenderer: () => {return '';}\r\n };\r\n\r\n columns.push(\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'rentRollLineItemId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.Unit}`,\r\n headerName: 'Unit',\r\n field: 'unit',\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.CompanyName}`,\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.TopLevelCompanyName}`,\r\n headerName: 'Top Level Company',\r\n field: 'topLevelCompanyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.SiteNumber}`,\r\n headerName: 'Site Number',\r\n field: 'siteNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const lineItem = params.data as Core.RentRollLineItemModel;\r\n // if (! lineItem && lineItem.sourceSite)) {\r\n if (! lineItem ) {\r\n return '';\r\n }\r\n return `#/site/${lineItem.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.IsValidated}`,\r\n headerName: 'Validated',\r\n field: 'isValidated',\r\n type: 'textColumn',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const data = params.data as Core.RentRollLineItemModel;\r\n if (!data || !data.rentRollLineItemId) {\r\n return '-';\r\n }\r\n\r\n return params.value === true ? 'Yes' : 'No'\r\n },\r\n editable: true,\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: (params) => {\r\n return [\r\n {name: 'Yes', value: true},\r\n {name: 'No', value: false}\r\n ]\r\n },\r\n cellFocusLost: (params, updatedValue) => this._updateIsValidated(params, updatedValue)\r\n },\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.SiteName}`,\r\n headerName: 'Site',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const lineItem = params.data as Core.RentRollLineItemModel;\r\n // if (! lineItem && lineItem.sourceSite)) {\r\n if (! lineItem ) {\r\n return '';\r\n }\r\n return `#/site/${lineItem.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.UnitType}`,\r\n headerName: 'Type',\r\n field: 'unitType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.Bed}`,\r\n headerName: 'Bed',\r\n field: 'bed',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell',\r\n hide: true,\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.Bath}`,\r\n headerName: 'Bath',\r\n field: 'bath',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell',\r\n hide: true,\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.SqFt}`,\r\n headerName: 'SqFt',\r\n field: 'sqFt',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterAndEqualToParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell'\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.Tenant}`,\r\n headerName: 'Tenant',\r\n field: 'tenant',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.RentRollLineItemStatusName}`,\r\n headerName: 'Status',\r\n field: 'rentRollLineItemStatusName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.AnnualMarketRent}`,\r\n headerName: 'Annual Market Rent',\r\n field: 'annualMarketRent',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: this._getCalcOrUncalcValue.bind(this),\r\n cellClass: this._getCellClass.bind(this)\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.MonthlyMarketRent}`,\r\n headerName: 'Monthly Market Rent',\r\n field: 'monthlyMarketRent',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: this._getCalcOrUncalcValue.bind(this),\r\n cellClass: this._getCellClass.bind(this)\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.AnnualRent}`,\r\n headerName: 'Annual Rent',\r\n field: 'annualRent',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: this._getCalcOrUncalcValue.bind(this),\r\n cellClass: this._getCellClass.bind(this)\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.MonthlyRent}`,\r\n headerName: 'Monthly Rent',\r\n field: 'monthlyRent',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: this._getCalcOrUncalcValue.bind(this),\r\n cellClass: this._getCellClass.bind(this)\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.LeaseBegin}`,\r\n headerName: 'Lease Begin',\r\n field: 'leaseBegin',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._datePipe.transform(params.value, true) : ''\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.LeaseEnd}`,\r\n headerName: 'Lease End',\r\n field: 'leaseEnd',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._datePipe.transform(params.value, true) : ''\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.MoveIn}`,\r\n headerName: 'Move In',\r\n field: 'moveIn',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._datePipe.transform(params.value, true) : '',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.MoveOut}`,\r\n headerName: 'Move Out',\r\n field: 'moveOut',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => params.value ? this._datePipe.transform(params.value, true) : '',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.BaseRate}`,\r\n headerName: 'Base Rate',\r\n field: 'baseRate',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.PctOfBuilding}`,\r\n headerName: 'Pct of Building',\r\n field: 'pctOfBuilding',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._percentPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.AnnualOther}`,\r\n headerName: 'Annual Other',\r\n field: 'annualOther',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: this._getCalcOrUncalcValue.bind(this),\r\n cellClass: this._getCellClass.bind(this),\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.AnnualCAM}`,\r\n headerName: 'Annual CAM',\r\n field: 'annualCAM',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: this._getCalcOrUncalcValue.bind(this),\r\n cellClass: this._getCellClass.bind(this),\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.MonthlyOther}`,\r\n headerName: 'Monthly Other',\r\n field: 'monthlyOther',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: this._getCalcOrUncalcValue.bind(this),\r\n cellClass: this._getCellClass.bind(this),\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.MonthlyCAM}`,\r\n headerName: 'Monthly CAM',\r\n field: 'monthlyCAM',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndEqualToAndBlankFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: this._getCalcOrUncalcValue.bind(this),\r\n cellClass: this._getCellClass.bind(this),\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.BuildingId}`,\r\n headerName: 'Building Id',\r\n field: 'buildingId',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.CreateDate}`,\r\n headerName: 'Import Date',\r\n field: 'createDate',\r\n type: 'dateColumn',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true),\r\n cellClass: 'ag-date-cell',\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.ValidatedBy}`,\r\n headerName: 'Validated By',\r\n field: 'validatedBy',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n } as ColDef,\r\n {\r\n colId: `${Core.RentRollLineItemPropertyEnum.ValidatedDate}`,\r\n headerName: 'Validated Date',\r\n field: 'validatedDate',\r\n type: 'dateColumn',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true),\r\n cellClass: 'ag-date-cell',\r\n hide: true\r\n } as ColDef,\r\n actionsColDef\r\n );\r\n\r\n return columns;\r\n }\r\n\r\n private async _deleteItem(params: ICellRendererParamsForRentRollGridAction) {\r\n const item = params.data as Core.RentRollLineItemModel;\r\n\r\n if(!item) {\r\n return;\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n `Are you sure you wish to delete Unit ${item.unit}?`,\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n try {\r\n await lastValueFrom(this._rentRollRepository.deleteItem(item.rentRollLineItemId));\r\n this._refreshDataSource();\r\n return Promise.resolve(true);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n }\r\n\r\n private _getCellClass(params: CellClassParams): string {\r\n const rentRollItem = params.data as Core.RentRollLineItemModel;\r\n if(!rentRollItem) {\r\n return '';\r\n }\r\n\r\n const actualValue = rentRollItem[params.colDef.field];\r\n const calcValue = rentRollItem[`${params.colDef.field }Calculated`];\r\n\r\n return calcValue !== actualValue ? 'ag-numeric-cell ws-calculated' : 'ag-numeric-cell';\r\n }\r\n\r\n private _getCalcOrUncalcValue(params: ValueFormatterParams): string {\r\n const rentRollItem = params.data as Core.RentRollLineItemModel;\r\n if(!rentRollItem) {\r\n return '';\r\n }\r\n\r\n const actualValue = rentRollItem[params.colDef.field];\r\n const calcValue = rentRollItem[`${params.colDef.field }Calculated`];\r\n const displayValue = actualValue || calcValue || 0;\r\n\r\n return this._decimalPipe.transform(displayValue, '1.2-2');\r\n }\r\n\r\n private async _reloadTotals(): Promise {\r\n if (!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n this.selectedTotalsLoading = true;\r\n\r\n try {\r\n const result = await this._gridDataSource.getSelectedRowTotals(this.gridTracker.getSelectedRowsModel());\r\n this.selectedTotalsLoading = false;\r\n this.handleTotalsUpdate(result, true);\r\n }\r\n finally {\r\n this.selectedTotalsLoading = false;\r\n }\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', lrpId: number, canDismiss = true, hasProgressBar = true): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this._busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: lrpId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: hasProgressBar,\r\n canDismiss\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success) => {\r\n await this._hideBusyIndicator();\r\n if (success) {\r\n await this._initEndDates();\r\n this.refresh();\r\n }\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._destroy$.next();\r\n }\r\n\r\n private async _initEndDates() {\r\n this.endDates = await lastValueFrom(this._rentRollRepository.getRentRollEndDates(this.companyId, this.siteIdFilter));\r\n\r\n if(!_.includes(this.endDates, this.selectedEndDate)) {\r\n this.selectedEndDate = _.maxBy(this.endDates, x => new Date(x));\r\n }\r\n }\r\n\r\n private async _updateIsValidated(params: ICellEditorParams, updatedValue: boolean): Promise {\r\n const data = params.data as Core.RentRollLineItemModel;\r\n\r\n if (!data) {\r\n return Promise.resolve();\r\n }\r\n\r\n const initialValue = params.value;\r\n if (updatedValue === initialValue) {\r\n return Promise.resolve();\r\n }\r\n\r\n const updateModel: Core.RentRollLineItemIsValidatedUpdateModel = {\r\n rentRollLineItemId: data.rentRollLineItemId,\r\n isValidated: updatedValue,\r\n rowVersion: data.rowVersion\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n\r\n try {\r\n const result = await lastValueFrom(this._rentRollRepository.updateIsValidated(updateModel));\r\n data.isValidated = result.isValidated;\r\n data.validatedBy = result.validatedBy;\r\n data.validatedDate = result.validatedDate;\r\n data.rowVersion = result.rowVersion;\r\n } catch (e) {\r\n data.isValidated = initialValue;\r\n throw e;\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n params.node.setData(data);\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ValuationTemplateRepository } from '../../Core-Repositories/valuationTemplate.repository';\r\nimport { IExpandableComponent } from '../../UI-Lib/Expandable-Component/expandableComponent.model';\r\nimport { BehaviorSubject, lastValueFrom, Observable } from 'rxjs';\r\nimport { IExpandableComponentContainer } from '../../UI-Lib/Expandable-Component/expandableComponentContainer.model';\r\nimport { DownloadFileService } from '../../Common/Download/downloadFileService';\r\n\r\n@Injectable()\r\nexport class ValuationTemplateService implements IExpandableComponentContainer {\r\n constructor(private readonly _valuationTemplateRepository: ValuationTemplateRepository,\r\n private readonly _downloadService: DownloadFileService) {}\r\n\r\n private _expandedComponent: IExpandableComponent;\r\n\r\n private _activeTemplateSubject: BehaviorSubject = new BehaviorSubject(null);\r\n private _activeTemplate$: Observable = this._activeTemplateSubject.asObservable();\r\n\r\n set template(template: Core.ValuationTemplateModel) {\r\n this._activeTemplateSubject.next(template ? { ...template } : null);\r\n }\r\n\r\n get template$(): Observable {\r\n return this._activeTemplate$;\r\n }\r\n\r\n get editGroup(): string {\r\n return 'valuation-template-group';\r\n }\r\n\r\n // events raised by components\r\n setExpandedComponent(component: IExpandableComponent): void {\r\n this._expandedComponent = component;\r\n }\r\n\r\n isComponentExpanded(component: IExpandableComponent): boolean {\r\n return this._expandedComponent === component;\r\n }\r\n\r\n isExpanded(componentName: string): boolean {\r\n return this._expandedComponent && (this._expandedComponent.getName() === componentName);\r\n }\r\n\r\n isOtherComponentExpanded(componentName: string): boolean {\r\n return this._expandedComponent && (this._expandedComponent.getName() !== componentName);\r\n }\r\n\r\n async getTemplateList(): Promise {\r\n return await lastValueFrom(this._valuationTemplateRepository.getTemplateList());\r\n }\r\n\r\n async addOrUpdateTemplate(template: Core.ValuationTemplateModel): Promise {\r\n return await lastValueFrom(this._valuationTemplateRepository.addOrUpdateTemplate(template));\r\n }\r\n\r\n async updateIsInDevelopment(templateId: number, isInDevelopment: boolean): Promise {\r\n const result = await lastValueFrom(this._valuationTemplateRepository.updateIsInDevelopment(templateId, isInDevelopment));\r\n this._activeTemplateSubject.next(result);\r\n return result;\r\n }\r\n\r\n async getTemplateNamesWithDuplicateSettings(templateId: number): Promise {\r\n return await lastValueFrom(this._valuationTemplateRepository.getTemplateNamesWithDuplicateSettings(templateId));\r\n }\r\n\r\n async updateTemplateStates(templateId: number, states: Core.ValuationTemplateStateModel[]): Promise {\r\n const result = await lastValueFrom(this._valuationTemplateRepository.updateTemplateStates(templateId, states));\r\n this._activeTemplateSubject.next(result);\r\n return result;\r\n }\r\n\r\n async updateTemplateAssessors(templateId: number, assessors: Core.ValuationTemplateAssessorModel[]): Promise {\r\n const result = await lastValueFrom(this._valuationTemplateRepository.updateTemplateAssessors(templateId, assessors));\r\n this._activeTemplateSubject.next(result);\r\n return result;\r\n }\r\n\r\n async getSiteClassOptions(){\r\n const result = await lastValueFrom(this._valuationTemplateRepository.getSiteClassOptions());\r\n return result;\r\n }\r\n\r\n async updateTemplateSiteClasses(templateId: number, siteClasses: Core.ValuationTemplateSiteClassPrimaryModel[]): Promise {\r\n const result = await lastValueFrom(this._valuationTemplateRepository.updateTemplateSiteClasses(templateId, siteClasses));\r\n this._activeTemplateSubject.next(result);\r\n return result;\r\n }\r\n\r\n async updateTemplateFile(templateId: number, file: File): Promise {\r\n const result = await lastValueFrom(this._valuationTemplateRepository.updateTemplateFile(templateId, file));\r\n this._activeTemplateSubject.next(result);\r\n return result;\r\n }\r\n\r\n async deleteTemplateFile(templateId: number): Promise {\r\n const result = await lastValueFrom(this._valuationTemplateRepository.deleteTemplateFile(templateId));\r\n this._activeTemplateSubject.next(result);\r\n return result;\r\n }\r\n\r\n async downloadTemplateFile(templateId: number): Promise {\r\n const response = await lastValueFrom(this._valuationTemplateRepository.downloadTemplateFile(templateId));\r\n await this._downloadService.downloadResponse(response);\r\n }\r\n\r\n getTemplateById(templateId: number): Promise {\r\n return lastValueFrom(this._valuationTemplateRepository.getTemplateById(templateId));\r\n }\r\n\r\n deleteTemplate(templateId: number): Promise {\r\n return lastValueFrom(this._valuationTemplateRepository.deleteTemplate(templateId));\r\n }\r\n\r\n}\r\n","\r\n \r\n
\r\n {{errorMessage}}\r\n
\r\n
\r\n
\r\n \r\n \r\n

\r\n Template name is required\r\n

\r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ValuationTemplateService } from '../valuationTemplate.service';\r\nimport { UserInstanceService } from '../../../User/userInstance.service';\r\n\r\nexport interface AddEditValuationTemplateModalParams {\r\n template?: Core.ValuationTemplateModel;\r\n}\r\n\r\n@Component({\r\n selector: 'add-edit-valuation-template',\r\n templateUrl: './addEditValuationTemplate.component.html'\r\n})\r\nexport class AddEditValuationTemplateComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _valuationTemplateService: ValuationTemplateService,\r\n private readonly _userInstanceService: UserInstanceService\r\n ) {}\r\n\r\n params: AddEditValuationTemplateModalParams;\r\n result: Core.ValuationTemplateModel;\r\n\r\n isBusy: boolean;\r\n templateForm: UntypedFormGroup;\r\n errorMessage: string;\r\n\r\n ngOnInit(): void {\r\n this.templateForm = this._fb.group({\r\n name: ['', Validators.required],\r\n description: ['']\r\n });\r\n\r\n if (this.params.template) {\r\n this.templateForm.patchValue({\r\n name: this.params.template.name,\r\n description: this.params.template.description\r\n });\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n this.isBusy = true;\r\n\r\n try {\r\n const {name, description} = this.templateForm.getRawValue();\r\n\r\n let model: any = {};\r\n if (this.params.template) {\r\n model = { ...this.params.template };\r\n }\r\n\r\n model.name = name;\r\n model.description = description || null;\r\n model.instanceId = this._userInstanceService.getSelectedInstance().instanceId;\r\n\r\n this.result = await this._valuationTemplateService.addOrUpdateTemplate(model);\r\n\r\n if (this.params.template) {\r\n this._valuationTemplateService.template = this.result;\r\n }\r\n\r\n this.cancel();\r\n } catch(err) {\r\n this.errorMessage = err.error.message;\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const VALUATION_TEMPLATE_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'valuation-template.new-template',\r\n tooltipText: 'Create a new valuation template.'\r\n },\r\n {\r\n helpContentId: 'valuation-template.edit-template',\r\n tooltipText: 'Edit the template name and description.'\r\n }\r\n];\r\n","import { Component, OnDestroy } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../../../Compliance/WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../../../Compliance/AgGrid';\r\nimport { AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectTracker } from '../../../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { Subscription } from 'rxjs';\r\nimport { StateService } from '../../../../../Common/States/States.Service';\r\nimport { StateSummary } from '../../../../../Common/States/state.model';\r\nimport { ValuationTemplateService } from '../../../valuationTemplate.service';\r\n\r\nexport interface AddStateModalParams {\r\n valuationTemplateId: number;\r\n statesSelected: number[];\r\n}\r\n\r\n@Component({\r\n selector: 'add-state-modal',\r\n templateUrl: './addState.component.html'\r\n})\r\nexport class AddStateComponent implements OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _stateService: StateService,\r\n private readonly _valuationTemplateService: ValuationTemplateService\r\n ) {}\r\n\r\n params: AddStateModalParams;\r\n result: Core.ValuationTemplateModel;\r\n\r\n loading: boolean = true;\r\n hasChanges: boolean;\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as StateSummary).stateID)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n private _allStates: StateSummary[];\r\n private _selectableStates: StateSummary[];\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n\r\n async ngOnInit(): Promise {\r\n const states = await this._stateService.getSummary();\r\n this._allStates = states.filter(x => x.countryID === 1);\r\n this._selectableStates = this._allStates.filter(x => !this.params.statesSelected.includes(x.stateID));\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.hasChanges = (x.selectAllRows && x.selectedRows.length !== this._selectableStates.length)\r\n || (!x.selectAllRows && !!x.selectedRows.length);\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'stateID',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'fullName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n this.loading = true;\r\n try {\r\n const rowModel = await this.gridTracker.getSelectedRowsModel();\r\n const states = this._allStates\r\n .reduce((acc, x) => {\r\n const row = rowModel.selectedRows.find(y => x.stateID === y);\r\n if ((!rowModel.selectAllRows && row) || (rowModel.selectAllRows && !row) || this.params.statesSelected.includes(x.stateID)) {\r\n acc.push({\r\n stateId: x.stateID,\r\n valuationTemplateId: this.params.valuationTemplateId\r\n });\r\n }\r\n return acc;\r\n }, [] as Core.ValuationTemplateStateModel[]);\r\n\r\n this.result = await this._valuationTemplateService.updateTemplateStates(this.params.valuationTemplateId, states);\r\n } finally {\r\n this.cancel();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!this._gridApi || !this._selectableStates) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._selectableStates);\r\n this._gridApi.sizeColumnsToFit();\r\n this.loading = false;\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map(x => {\r\n const state = x.data as StateSummary;\r\n return state && state.stateID;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n\r\n}\r\n","
\r\n
\r\n

\r\n States\r\n \r\n \r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n

National

\r\n
\r\n
\r\n
\r\n\r\n","\r\n\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { ColDef, GridApi, GridReadyEvent } from 'ag-grid-community';\r\nimport { BaseExpandableAgGridComponent } from '../../../../UI-Lib/Expandable-Component/baseExpandableAgGridComponent';\r\nimport { ValuationTemplateService } from '../../valuationTemplate.service';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../../Compliance/AgGrid';\r\nimport { IMutexServiceHandler, WeissmanMutexService } from '../../../../Compliance/WeissmanMutexService';\r\nimport { WeissmanModalService } from '../../../../Compliance/WeissmanModalService';\r\nimport { AddStateComponent, AddStateModalParams } from './Add-State/addState.component';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from '../../../../Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AgGridMultiSelectCellRendererParams, AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectHeaderRendererParams, AgGridMultiSelectTracker } from '../../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridActionCellRendererComponent, AgGridActionCellRendererParams } from '../../../../Compliance/AgGrid/CellRenderers/agGridActionCellRenderer.component';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\n\r\n@Component({\r\n selector: 'valuation-states-list',\r\n templateUrl: './valuationStatesList.component.html'\r\n})\r\nexport class ValuationStatesListComponent extends BaseExpandableAgGridComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _valuationTemplateService: ValuationTemplateService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _busyIndicatorService: BusyIndicatorService\r\n ) {\r\n super(_valuationTemplateService, 'valuation-states-list');\r\n }\r\n\r\n gridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => {\r\n const data = params.data as Core.ValuationTemplateStateModel;\r\n return data && this._gridTracker.isRowSelected(data.stateId);\r\n }\r\n },\r\n onFilterChanged: () => this._gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this._gridTracker.onGridSortChanged()\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n template: Core.ValuationTemplateModel;\r\n canEdit: boolean = true;\r\n canEnterEditMode: boolean;\r\n editMode: boolean;\r\n hasSelectedRows: boolean;\r\n\r\n private _gridTracker: AgGridMultiSelectTracker;\r\n private _gridApi: GridApi;\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._valuationTemplateService.template$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => {\r\n if (x) {\r\n this.template = x;\r\n this.canEnterEditMode = x.isInDevelopment;\r\n this._setGridData();\r\n\r\n if(!x.isInDevelopment && this.editMode){\r\n this.cancel();\r\n }\r\n }\r\n });\r\n\r\n this._mutexService.lockChanged$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.canEnterEditMode = !x[this._valuationTemplateService.editGroup] && this.template.isInDevelopment);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._mutexService.release(this, this._valuationTemplateService.editGroup);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._gridTracker.selectedRows$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.hasSelectedRows = x.selectAllRows || !!(!x.selectAllRows && x.selectedRows.length));\r\n\r\n super.setGridApi(event.api);\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'stateId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n hide: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this._gridTracker\r\n } as AgGridMultiSelectHeaderRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this._gridTracker\r\n } as AgGridMultiSelectCellRendererParams\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'stateFullName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => '',\r\n newWindow: true,\r\n isHelpDisabled: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const entry = params.data as Core.ValuationTemplateStateModel;\r\n if (!entry) {\r\n return '';\r\n }\r\n return `#/states/${entry.stateId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n hide: true,\r\n cellRendererFramework: AgGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n buttonConfigs: [\r\n {\r\n iconClass: 'fa-trash',\r\n onClick: this._onRemove.bind(this),\r\n isShown: () => true,\r\n buttonClass: 'btn-primary btn-danger',\r\n helpContentId: 'app.delete'\r\n }\r\n ]\r\n } as AgGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'stateFullName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setGridData();\r\n }\r\n\r\n async addNewState(): Promise {\r\n const params = {\r\n valuationTemplateId: this.template.valuationTemplateId,\r\n statesSelected: this.template.states.map(x => x.stateId)\r\n } as AddStateModalParams;\r\n\r\n await this._modalService.showAsync(AddStateComponent, params, 'modal-md');\r\n }\r\n\r\n edit(): void {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n\r\n this._toggleGridEdit(true);\r\n }\r\n\r\n cancel(): void {\r\n this._toggleGridEdit(false);\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n async bulkRemove(): Promise {\r\n const rowModel = this._gridTracker.getSelectedRowsModel();\r\n if (!this.hasSelectedRows) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Removing States' });\r\n\r\n try {\r\n const states = this.template.states.filter(x => {\r\n if (rowModel.selectAllRows) {\r\n return rowModel.selectedRows.find(y => y === x.stateId);\r\n } else {\r\n return !rowModel.selectedRows.find(y => y === x.stateId);\r\n }\r\n });\r\n await this._valuationTemplateService.updateTemplateStates(this.template.valuationTemplateId, states);\r\n } finally {\r\n this._gridTracker.clear();\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _setGridData(): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n this._gridApi.setRowData(this.template.states);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _toggleGridEdit(editing: boolean): void {\r\n this.editMode = editing;\r\n if (this.gridOptions && this.gridOptions.columnApi) {\r\n this.gridOptions.columnApi.setColumnsVisible(['stateId', 'actions'], this.editMode);\r\n this.gridOptions.api.sizeColumnsToFit();\r\n }\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._valuationTemplateService.editGroup);\r\n this._gridTracker.clear();\r\n } else {\r\n this._mutexService.acquire(this, this._valuationTemplateService.editGroup);\r\n }\r\n this._gridApi.redrawRows();\r\n }\r\n\r\n private async _onRemove(params: AgGridActionCellRendererParams): Promise {\r\n const state = params.data as Core.ValuationTemplateStateModel;\r\n if (!state) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Removing State' });\r\n\r\n try {\r\n const states = this.template.states.filter(x => x.stateId !== state.stateId);\r\n await this._valuationTemplateService.updateTemplateStates(this.template.valuationTemplateId, states);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _getGridRowIds(skip, take): Compliance.QueryResultModel {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return {\r\n data: rows.map((x) => {\r\n const assessor = x.data as Core.ValuationTemplateStateModel;\r\n return assessor && assessor.stateId;\r\n })\r\n } as Compliance.QueryResultModel;\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { GridApi, GridReadyEvent, ColDef, GridOptions } from 'ag-grid-community';\r\nimport { Subscription } from 'rxjs';\r\nimport { ValuationTemplateService } from '../../../valuationTemplate.service';\r\nimport { AssessorService } from '../../../../../Assessor-Collector/Assessor/assessor-service';\r\nimport { IWeissmanModalComponent } from '../../../../../Compliance/WeissmanModalService';\r\nimport { AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectTracker } from '../../../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../../../Compliance/AgGrid';\r\nimport { Assessor } from '../../../../../Assessor-Collector/assessor.model';\r\nimport { ValueFormatterParams } from 'ag-grid-community/dist/lib/entities/colDef';\r\n\r\nexport interface ValuationsAddAssessorModalParams {\r\n stateId: number;\r\n assessorsSelected: number[];\r\n valuationTemplateId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'valuation-assessor-add',\r\n templateUrl: './addAssessor.component.html'\r\n})\r\nexport class AddAssessorComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _valuationTemplateService: ValuationTemplateService,\r\n private readonly _assessorService: AssessorService,\r\n private readonly _bsModalRef: BsModalRef\r\n ) {}\r\n\r\n params: ValuationsAddAssessorModalParams;\r\n result: Core.ValuationTemplateModel;\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Assessor).assessorID)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n\r\n loading: boolean = true;\r\n hasChanges: boolean;\r\n\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n private _allAssessors: Assessor[];\r\n private _selectableAssessors: Assessor[];\r\n\r\n async ngOnInit(): Promise {\r\n const assessors = await this._assessorService.getByStateId(this.params.stateId);\r\n this._allAssessors = assessors.sort((a, b) => {\r\n return `${a.abbr} ${a.municipalityAbbr}`.localeCompare(`${b.abbr} ${b.municipalityAbbr}`);\r\n });\r\n this._selectableAssessors = this._allAssessors.filter(x => !this.params.assessorsSelected.includes(x.assessorID));\r\n\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.hasChanges = (x.selectAllRows && x.selectedRows.length !== this._selectableAssessors.length)\r\n || (!x.selectAllRows && !!x.selectedRows.length);\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'assessorID',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Name',\r\n field: 'abbr',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params: ValueFormatterParams) => {\r\n const data = params.data as Assessor;\r\n return `${data.abbr} ${data.municipalityAbbr}`;\r\n }\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n this.loading = true;\r\n\r\n try {\r\n const rowModel = await this.gridTracker.getSelectedRowsModel();\r\n const assessors = this._allAssessors\r\n .reduce((acc, x) => {\r\n const row = rowModel.selectedRows.find(y => x.assessorID === y);\r\n if ((!rowModel.selectAllRows && row) || (rowModel.selectAllRows && !row) || this.params.assessorsSelected.includes(x.assessorID)) {\r\n acc.push({\r\n assessorId: x.assessorID,\r\n valuationTemplateId: this.params.valuationTemplateId\r\n });\r\n }\r\n return acc;\r\n }, [] as Core.ValuationTemplateAssessorModel[]);\r\n\r\n const result = await this._valuationTemplateService.updateTemplateAssessors(this.params.valuationTemplateId, assessors);\r\n\r\n if (result) {\r\n this.result = result;\r\n }\r\n } finally {\r\n this.cancel();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!this._gridApi || !this._selectableAssessors) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._selectableAssessors);\r\n this._gridApi.sizeColumnsToFit();\r\n this.loading = false;\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map((x) => {\r\n const assessor = x.data as Assessor;\r\n return assessor && assessor.assessorID;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Assessors\r\n \r\n \r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n

Using All Assessors

\r\n
\r\n
\r\n
\r\n\r\n","\r\n\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { ColDef, GridApi, GridReadyEvent } from 'ag-grid-community';\r\nimport { BaseExpandableAgGridComponent } from '../../../../UI-Lib/Expandable-Component/baseExpandableAgGridComponent';\r\nimport { ValuationTemplateService } from '../../valuationTemplate.service';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../../Compliance/AgGrid';\r\nimport { WeissmanMutexService } from '../../../../Compliance/WeissmanMutexService';\r\nimport { WeissmanModalService } from '../../../../Compliance/WeissmanModalService';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\nimport { AddAssessorComponent, ValuationsAddAssessorModalParams } from './Add-Assessor/addAssessor.component';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from '../../../../Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AgGridMultiSelectCellRendererParams, AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectHeaderRendererParams, AgGridMultiSelectTracker } from '../../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridActionCellRendererComponent, AgGridActionCellRendererParams } from '../../../../Compliance/AgGrid/CellRenderers/agGridActionCellRenderer.component';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\n\r\n@Component({\r\n selector: 'valuation-assessors-list',\r\n templateUrl: './valuationAssessorsList.component.html'\r\n})\r\nexport class ValuationAssessorsListComponent extends BaseExpandableAgGridComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _valuationTemplateService: ValuationTemplateService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _busyIndicatorService: BusyIndicatorService\r\n ) {\r\n super(_valuationTemplateService, 'valuation-assessors-list');\r\n }\r\n\r\n gridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => {\r\n const data = params.data as Core.ValuationTemplateAssessorModel;\r\n return data && this._gridTracker.isRowSelected(data.assessorId);\r\n }\r\n },\r\n onFilterChanged: () => this._gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this._gridTracker.onGridSortChanged()\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n template: Core.ValuationTemplateModel;\r\n canEdit: boolean;\r\n canEnterEditMode: boolean;\r\n editMode: boolean;\r\n hasSelectedRows: boolean;\r\n\r\n private _gridTracker: AgGridMultiSelectTracker;\r\n private _gridApi: GridApi;\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._valuationTemplateService.template$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => {\r\n if (x) {\r\n this.template = x;\r\n this.canEdit = x.states.length === 1;\r\n this.canEnterEditMode = x.isInDevelopment;\r\n this._setGridData();\r\n\r\n if(!x.isInDevelopment && this.editMode){\r\n this.cancel();\r\n }\r\n }\r\n });\r\n\r\n this._mutexService.lockChanged$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.canEnterEditMode = !x[this._valuationTemplateService.editGroup] && this.template.isInDevelopment);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._mutexService.release(this, this._valuationTemplateService.editGroup);\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._gridTracker.selectedRows$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.hasSelectedRows = x.selectAllRows || !!(!x.selectAllRows && x.selectedRows.length));\r\n\r\n super.setGridApi(event.api);\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'assessorId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n hide: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this._gridTracker\r\n } as AgGridMultiSelectHeaderRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this._gridTracker\r\n } as AgGridMultiSelectCellRendererParams\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => '',\r\n newWindow: true,\r\n isHelpDisabled: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const entry = params.data as Core.ValuationTemplateAssessorModel;\r\n if (!entry) {\r\n return '';\r\n }\r\n return `#/states/${this.template.states[0].stateId}/assessors/${entry.assessorId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n hide: true,\r\n cellRendererFramework: AgGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n buttonConfigs: [\r\n {\r\n iconClass: 'fa-trash',\r\n onClick: this._onRemove.bind(this),\r\n isShown: () => true,\r\n buttonClass: 'btn-primary btn-danger',\r\n helpContentId: 'app.delete'\r\n }\r\n ]\r\n } as AgGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'assessorName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setGridData();\r\n }\r\n\r\n async addNewAssessor(): Promise {\r\n const params = {\r\n valuationTemplateId: this.template.valuationTemplateId,\r\n stateId: this.template.states[0].stateId,\r\n assessorsSelected: this.template.assessors.map(x => x.assessorId)\r\n } as ValuationsAddAssessorModalParams;\r\n\r\n await this._modalService.showAsync(AddAssessorComponent, params, 'modal-md');\r\n\r\n this._gridApi.redrawRows();\r\n }\r\n\r\n edit(): void {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n\r\n this._toggleGridEdit(true);\r\n }\r\n\r\n cancel(): void {\r\n this._toggleGridEdit(false);\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n async bulkRemove(): Promise {\r\n const rowModel = this._gridTracker.getSelectedRowsModel();\r\n if (!this.hasSelectedRows) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Removing Assessors' });\r\n\r\n try {\r\n const assessors = this.template.assessors.filter(x => {\r\n if (rowModel.selectAllRows) {\r\n return rowModel.selectedRows.find(y => y === x.assessorId);\r\n } else {\r\n return !rowModel.selectedRows.find(y => y === x.assessorId);\r\n }\r\n });\r\n await this._valuationTemplateService.updateTemplateAssessors(this.template.valuationTemplateId, assessors);\r\n } finally {\r\n this._gridTracker.clear();\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _setGridData(): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n this._gridApi.setRowData(this.template.assessors);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _toggleGridEdit(editing: boolean): void {\r\n this.editMode = editing;\r\n if (this.gridOptions && this.gridOptions.columnApi) {\r\n this.gridOptions.columnApi.setColumnsVisible(['assessorId', 'actions'], this.editMode);\r\n this.gridOptions.api.sizeColumnsToFit();\r\n }\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._valuationTemplateService.editGroup);\r\n this._gridTracker.clear();\r\n } else {\r\n this._mutexService.acquire(this, this._valuationTemplateService.editGroup);\r\n }\r\n this._gridApi.redrawRows();\r\n }\r\n\r\n private async _onRemove(params: AgGridActionCellRendererParams): Promise {\r\n const assessor = params.data as Core.ValuationTemplateAssessorModel;\r\n if (!assessor) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Removing Assessor' });\r\n\r\n try {\r\n const assessors = this.template.assessors.filter(x => x.assessorId !== assessor.assessorId);\r\n await this._valuationTemplateService.updateTemplateAssessors(this.template.valuationTemplateId, assessors);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _getGridRowIds(skip, take): Compliance.QueryResultModel {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return {\r\n data: rows.map((x) => {\r\n const assessor = x.data as Core.ValuationTemplateAssessorModel;\r\n return assessor && assessor.assessorId;\r\n })\r\n } as Compliance.QueryResultModel;\r\n }\r\n}\r\n","import { Component, OnDestroy } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../../../Compliance/WeissmanModalService';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../../../Compliance/AgGrid';\r\nimport { AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectTracker } from '../../../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { Subscription } from 'rxjs';\r\nimport { StateSummary } from '../../../../../Common/States/state.model';\r\nimport { ValuationTemplateService } from '../../../valuationTemplate.service';\r\nimport { SiteClassPrimary } from '../../../../../Core-Repositories/siteClass.repository';\r\n\r\nexport interface AddSiteClassModalParams {\r\n valuationTemplateId: number;\r\n siteClassesSelected: number[];\r\n}\r\n\r\n@Component({\r\n selector: 'add-site-class-modal',\r\n templateUrl: './addSiteClass.component.html'\r\n})\r\nexport class AddSiteClassComponent implements OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _valuationTemplateService: ValuationTemplateService\r\n ) {}\r\n\r\n params: AddSiteClassModalParams;\r\n result: Core.ValuationTemplateModel;\r\n\r\n loading: boolean = true;\r\n hasChanges: boolean;\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Weissman.Model.Domain.SiteClassPrimary).siteClassPrimaryID)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n private _allowedSiteClasses: SiteClassPrimary[];\r\n private _selectableSiteClasses: SiteClassPrimary[];\r\n private _gridApi: GridApi;\r\n private _selectedRowsSub: Subscription;\r\n\r\n async ngOnInit(): Promise {\r\n this._allowedSiteClasses = await this._valuationTemplateService.getSiteClassOptions();\r\n this._selectableSiteClasses = this._allowedSiteClasses.filter(x => !this.params.siteClassesSelected.includes(x.siteClassPrimaryID));\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._selectedRowsSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.hasChanges = (x.selectAllRows && x.selectedRows.length !== this._selectableSiteClasses.length)\r\n || (!x.selectAllRows && !!x.selectedRows.length);\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'siteClassPrimaryID',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'siteClassPrimaryDesc',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n this.loading = true;\r\n try {\r\n const rowModel = this.gridTracker.getSelectedRowsModel();\r\n const siteClasses = this._allowedSiteClasses\r\n .reduce((acc, x) => {\r\n const row = rowModel.selectedRows.find(y => x.siteClassPrimaryID === y);\r\n if ((!rowModel.selectAllRows && row) || (rowModel.selectAllRows && !row) || this.params.siteClassesSelected.includes(x.siteClassPrimaryID)) {\r\n acc.push({\r\n siteClassPrimaryId: x.siteClassPrimaryID,\r\n valuationTemplateId: this.params.valuationTemplateId\r\n });\r\n }\r\n return acc;\r\n }, [] as Core.ValuationTemplateSiteClassPrimaryModel[]);\r\n\r\n this.result = await this._valuationTemplateService.updateTemplateSiteClasses(this.params.valuationTemplateId, siteClasses);\r\n } finally {\r\n this.cancel();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!this._gridApi || !this._selectableSiteClasses) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._selectableSiteClasses);\r\n this._gridApi.sizeColumnsToFit();\r\n this.loading = false;\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map(x => {\r\n const state = x.data as StateSummary;\r\n return state && state.stateID;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n\r\n}\r\n","
\r\n
\r\n

\r\n Primary Site Class\r\n \r\n

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n

Please select a primary site class.

\r\n
\r\n
\r\n
\r\n\r\n","\r\n\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { ColDef, GridApi, GridReadyEvent } from 'ag-grid-community';\r\nimport { BaseExpandableAgGridComponent } from '../../../../UI-Lib/Expandable-Component/baseExpandableAgGridComponent';\r\nimport { ValuationTemplateService } from '../../valuationTemplate.service';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../../Compliance/AgGrid';\r\nimport { WeissmanMutexService } from '../../../../Compliance/WeissmanMutexService';\r\nimport { WeissmanModalService } from '../../../../Compliance/WeissmanModalService';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\nimport { AddSiteClassComponent, AddSiteClassModalParams } from './Add-Site-Class/addSiteClass.component';\r\nimport { AgGridActionCellRendererComponent, AgGridActionCellRendererParams } from '../../../../Compliance/AgGrid/CellRenderers/agGridActionCellRenderer.component';\r\nimport { AgGridMultiSelectCellRendererParams, AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectHeaderRendererParams, AgGridMultiSelectTracker } from '../../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\n\r\n@Component({\r\n selector: 'valuation-site-class-list',\r\n templateUrl: './valuationSiteClassList.component.html',\r\n styleUrls: ['./valuationSiteClassList.component.scss']\r\n})\r\nexport class ValuationSiteClassListComponent extends BaseExpandableAgGridComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _valuationTemplateService: ValuationTemplateService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n ) {\r\n super(_valuationTemplateService, 'valuation-site-class-list');\r\n }\r\n\r\n gridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => {\r\n const data = params.data as Core.ValuationTemplateSiteClassPrimaryModel;\r\n return data && this._gridTracker.isRowSelected(data.siteClassPrimaryId);\r\n }\r\n },\r\n onFilterChanged: () => this._gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this._gridTracker.onGridSortChanged()\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n template: Core.ValuationTemplateModel;\r\n canEdit: boolean = true;\r\n canEnterEditMode: boolean;\r\n editMode: boolean;\r\n hasSelectedRows: boolean;\r\n allRowsSelected: boolean;\r\n\r\n private _gridTracker: AgGridMultiSelectTracker;\r\n private _gridApi: GridApi;\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._valuationTemplateService.template$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => {\r\n if (x) {\r\n this.template = x;\r\n this.canEnterEditMode = x.isInDevelopment;\r\n this._setGridData();\r\n\r\n if(!x.isInDevelopment && this.editMode){\r\n this.cancel();\r\n }\r\n }\r\n });\r\n\r\n this._mutexService.lockChanged$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.canEnterEditMode = !x[this._valuationTemplateService.editGroup] && this.template.isInDevelopment);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this._gridTracker.selectedRows$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => {\r\n this.hasSelectedRows = x.selectAllRows || !!(!x.selectAllRows && x.selectedRows.length);\r\n this.allRowsSelected = (x.selectAllRows && !x.selectedRows.length)\r\n || (!x.selectAllRows && x.selectedRows.length === this.template.siteClassPrimaries.length);\r\n });\r\n\r\n super.setGridApi(event.api);\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'siteClassPrimaryId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n hide: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this._gridTracker\r\n } as AgGridMultiSelectHeaderRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this._gridTracker\r\n } as AgGridMultiSelectCellRendererParams\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'siteClassPrimaryDesc',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n hide: true,\r\n cellRendererFramework: AgGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n buttonConfigs: [\r\n {\r\n iconClass: 'fa-trash',\r\n onClick: this._onRemove.bind(this),\r\n isShown: () => this.template.siteClassPrimaries.length > 1,\r\n buttonClass: 'btn-primary btn-danger',\r\n helpContentId: 'app.delete'\r\n }\r\n ]\r\n } as AgGridActionCellRendererParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'siteClassPrimaryDesc',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setGridData();\r\n }\r\n\r\n async addNewSiteClass(): Promise {\r\n const params = {\r\n valuationTemplateId: this.template.valuationTemplateId,\r\n siteClassesSelected: this.template.siteClassPrimaries.map(x => x.siteClassPrimaryId)\r\n } as AddSiteClassModalParams;\r\n\r\n await this._modalService.showAsync(AddSiteClassComponent, params, 'modal-md');\r\n }\r\n\r\n edit(): void {\r\n if (!this.canEdit) {\r\n return;\r\n }\r\n\r\n this._toggleGridEdit(true);\r\n }\r\n\r\n cancel(): void {\r\n this._toggleGridEdit(false);\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n async bulkRemove(): Promise {\r\n const rowModel = this._gridTracker.getSelectedRowsModel();\r\n if (!this.hasSelectedRows) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Removing Site Classes' });\r\n\r\n try {\r\n const siteClasses = this.template.siteClassPrimaries.filter(x => {\r\n if (rowModel.selectAllRows) {\r\n return rowModel.selectedRows.find(y => y === x.siteClassPrimaryId);\r\n } else {\r\n return !rowModel.selectedRows.find(y => y === x.siteClassPrimaryId);\r\n }\r\n });\r\n\r\n await this._valuationTemplateService.updateTemplateSiteClasses(this.template.valuationTemplateId, siteClasses);\r\n } finally {\r\n this._gridTracker.clear();\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _setGridData(): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n this._gridApi.setRowData(this.template.siteClassPrimaries);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _toggleGridEdit(editing: boolean): void {\r\n this.editMode = editing;\r\n if (this.gridOptions && this.gridOptions.columnApi) {\r\n this.gridOptions.columnApi.setColumnsVisible(['siteClassPrimaryId', 'actions'], this.editMode);\r\n this.gridOptions.api.sizeColumnsToFit();\r\n }\r\n if (!this.editMode) {\r\n this._mutexService.release(this, this._valuationTemplateService.editGroup);\r\n this._gridTracker.clear();\r\n } else {\r\n this._mutexService.acquire(this, this._valuationTemplateService.editGroup);\r\n }\r\n this._gridApi.redrawRows();\r\n }\r\n\r\n private async _onRemove(params: AgGridActionCellRendererParams): Promise {\r\n const siteClass = params.data as Core.ValuationTemplateSiteClassPrimaryModel;\r\n if (!siteClass) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Removing Site Class' });\r\n\r\n try {\r\n const siteClasses = this.template.siteClassPrimaries.filter(x => x.siteClassPrimaryId !== siteClass.siteClassPrimaryId);\r\n await this._valuationTemplateService.updateTemplateSiteClasses(this.template.valuationTemplateId, siteClasses);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n private _getGridRowIds(skip, take): Compliance.QueryResultModel {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return {\r\n data: rows.map((x) => {\r\n const assessor = x.data as Core.ValuationTemplateSiteClassPrimaryModel;\r\n return assessor && assessor.siteClassPrimaryId;\r\n })\r\n } as Compliance.QueryResultModel;\r\n }\r\n}\r\n"," 0\" [message]=\"busyMessageManager.message\">\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../../../../Compliance/WeissmanModalService';\r\nimport { ValuationTemplateService } from '../../../valuationTemplate.service';\r\nimport { BusyIndicatorMessageManager } from '../../../../../Busy-Indicator';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\nexport interface ValuationTemplateUploadModalParams {\r\n valuationTemplateId: number;\r\n siteClassPrimaries: Core.ValuationTemplateSiteClassPrimaryModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'template-upload',\r\n templateUrl: './upload.component.html'\r\n})\r\nexport class UploadComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _valuationTemplateService: ValuationTemplateService,\r\n private readonly _toastr: ToastrService\r\n ) { }\r\n\r\n params: ValuationTemplateUploadModalParams;\r\n result: Core.ValuationTemplateModel;\r\n\r\n busyMessageManager: BusyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n file: File;\r\n\r\n\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n filePicked(files: File[]): void {\r\n this.file = files[0];\r\n }\r\n\r\n async upload(): Promise {\r\n this.busyMessageManager.add('Uploading', 'uploading');\r\n\r\n try {\r\n this.result = await this._valuationTemplateService.updateTemplateFile(this.params.valuationTemplateId, this.file);\r\n\r\n this.cancel();\r\n } catch(err) {\r\n this._toastr.error(err.error.message);\r\n } finally {\r\n this.busyMessageManager.remove('uploading');\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n

Valuation Template

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n

The valuation doesn't have a template

\r\n

Please select a primary site class to enable template upload

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n {{ fileName }}\r\n (Last changed by {{fileChangedBy}} on {{fileChangeDate | date: 'MM/dd/yyyy h:mm a'}})\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { BaseExpandableComponent } from '../../../../UI-Lib/Expandable-Component/baseExpandableComponent';\r\nimport { MessageModalService } from '../../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport { WeissmanMutexService } from '../../../../Compliance/WeissmanMutexService';\r\nimport { WeissmanModalService } from '../../../../Compliance/WeissmanModalService';\r\nimport { ValuationTemplateService } from '../../valuationTemplate.service';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { Subject } from 'rxjs';\r\nimport { UploadComponent, ValuationTemplateUploadModalParams } from './Template-Upload/upload.component';\r\n\r\n\r\n@Component({\r\n selector: 'valuation-template-upload',\r\n templateUrl: './valuationTemplateUpload.component.html'\r\n})\r\nexport class ValuationTemplateUploadComponent extends BaseExpandableComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _valuationTemplateService: ValuationTemplateService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _modalService: WeissmanModalService) {\r\n super(_valuationTemplateService, 'valuation-template-upload');\r\n }\r\n\r\n canEdit: boolean;\r\n canEnterEditMode: boolean;\r\n template: Core.ValuationTemplateModel;\r\n fileName: string;\r\n fileChangedBy: string;\r\n fileChangeDate: Date;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._valuationTemplateService.template$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => {\r\n this.template = x;\r\n this.fileName = x.fileName;\r\n this.canEdit = !!this.template.siteClassPrimaries.length;\r\n this.fileChangedBy = x.fileChangedByUserName;\r\n this.fileChangeDate = x.fileChangeDate;\r\n this.canEnterEditMode = x.isInDevelopment;\r\n });\r\n\r\n this._mutexService.lockChanged$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.canEnterEditMode = !x[this._valuationTemplateService.editGroup] && this.template.isInDevelopment);\r\n }\r\n\r\n ngOnDestroy() {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async upload(): Promise {\r\n if (this.template.hasFile) {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to overwrite the valuation template?',\r\n 'Confirm Overwrite'\r\n );\r\n } catch (e) {\r\n return;\r\n }\r\n }\r\n\r\n const params = {\r\n valuationTemplateId: this.template.valuationTemplateId,\r\n siteClassPrimaries: this.template.siteClassPrimaries\r\n } as ValuationTemplateUploadModalParams;\r\n\r\n await this._modalService.showAsync(UploadComponent, params, 'modal-md');\r\n }\r\n\r\n async download(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Downloading' });\r\n try {\r\n await this._valuationTemplateService.downloadTemplateFile(this.template.valuationTemplateId);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async delete(): Promise {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you wish to delete the valuation template?', 'Confirm Delete');\r\n }\r\n catch (e) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n try {\r\n await this._valuationTemplateService.deleteTemplateFile(this.template.valuationTemplateId);\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n \r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n
\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { ValuationTemplateService } from '../valuationTemplate.service';\r\nimport { AddEditValuationTemplateComponent } from '../Add-Edit-Tempalate/addEditValuationTemplate.component';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { VALUATION_TEMPLATE_HELP } from '../valuationTemplate.help';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\n@Component({\r\n selector: 'valuation-template-detail',\r\n templateUrl: './valuationTemplateDetail.component.html',\r\n styleUrls: ['./valuationTemplateDetail.component.scss']\r\n})\r\nexport class ValuationTemplateDetailComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _valuationTemplateService: ValuationTemplateService,\r\n private readonly _helpService: HelpService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _toastsManager: ToastrService,\r\n private readonly _busyIndicatorService: BusyIndicatorService\r\n ) {}\r\n\r\n breadcrumbs: BreadCrumb[] = [\r\n {\r\n name: 'Templates',\r\n target: 'valuationTemplates',\r\n options: {}\r\n }\r\n ];\r\n template: Core.ValuationTemplateModel;\r\n\r\n private _templateId: number;\r\n private _destroy$: Subject = new Subject();\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(VALUATION_TEMPLATE_HELP);\r\n this._templateId = +this._routerService.getQuerystringParam('templateId');\r\n\r\n this._valuationTemplateService.template$\r\n .pipe(takeUntil(this._destroy$))\r\n .subscribe(x => this.template = x);\r\n\r\n this.refresh();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._valuationTemplateService.template = null;\r\n this._valuationTemplateService.setExpandedComponent(null);\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async refresh(): Promise {\r\n this._valuationTemplateService.template = await this._valuationTemplateService.getTemplateById(this._templateId);\r\n }\r\n\r\n async editTemplateName(): Promise {\r\n const params = {\r\n template: this.template\r\n };\r\n\r\n const result = await this._modalService.showAsync(AddEditValuationTemplateComponent, params, 'modal-md');\r\n\r\n if (result) {\r\n this.template = result;\r\n }\r\n }\r\n\r\n async onIsInDevelopmentChange(isInDevelopmentInput: boolean): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Saving' });\r\n\r\n try {\r\n const result = await this._valuationTemplateService.updateIsInDevelopment(this.template.valuationTemplateId, isInDevelopmentInput);\r\n\r\n if (result)\r\n {\r\n this.template = result;\r\n if(result.isInDevelopment == isInDevelopmentInput)\r\n {\r\n this._toastsManager.success(`Template set as ${this.template.isInDevelopment ? '' : 'not '}in development`);\r\n }\r\n else\r\n {\r\n let duplicates = await this._valuationTemplateService.getTemplateNamesWithDuplicateSettings(this.template.valuationTemplateId);\r\n if(duplicates)\r\n {\r\n duplicates = duplicates.map(x => x =`\"${x}\"`);\r\n this._toastsManager.error(`Template already exists for this configuration in ${duplicates.join(', ')}.`);\r\n }\r\n else\r\n {\r\n this._toastsManager.error('Unable to update development settings for template.');\r\n }\r\n }\r\n }\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n isHidden(componentName: string): boolean {\r\n return this._valuationTemplateService.isOtherComponentExpanded(componentName);\r\n }\r\n\r\n areHidden(componentNames: string[]): boolean {\r\n return componentNames.every(x => this.isHidden(x));\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../Compliance/AgGrid';\r\nimport { GridApi, GridReadyEvent } from 'ag-grid-community';\r\nimport { AgGridActionCellRendererComponent, AgGridActionCellRendererParams } from '../../Compliance/AgGrid/CellRenderers/agGridActionCellRenderer.component';\r\nimport { ValuationTemplateService } from './valuationTemplate.service';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { AddEditValuationTemplateComponent } from './Add-Edit-Tempalate/addEditValuationTemplate.component';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { HelpService } from '../../UI-Lib/Help-Tooltip';\r\nimport { VALUATION_TEMPLATE_HELP } from './valuationTemplate.help';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\n\r\n@Component({\r\n selector: 'valuation-templates',\r\n templateUrl: './valuationTemplates.component.html',\r\n styleUrls: ['./valuationTemplates.component.scss']\r\n})\r\nexport class ValuationTemplatesComponent implements OnInit {\r\n constructor(\r\n private readonly _valuationTemplateService: ValuationTemplateService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler\r\n ) {}\r\n\r\n gridId: string = 'e34cb223-dd10-4ee8-890b-2caa2b83ef75';\r\n gridOptions = new AgGridOptionsBuilder()\r\n .withColumnPinning()\r\n .withSort()\r\n .withMultipleColumnSort()\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withContext(this)\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _gridValues: Core.ValuationTemplateModel[] = [];\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(VALUATION_TEMPLATE_HELP);\r\n this.refreshGridData();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns = [\r\n {\r\n headerName: 'Template Name',\r\n field: 'name',\r\n width: AgGridColumns.textColumnWidth,\r\n editable: false,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Template Description',\r\n field: 'description',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'States',\r\n field: 'states',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: params => {\r\n const template = params.data as Core.ValuationTemplateModel;\r\n if (template.states.length) {\r\n return template.states.map(x => x.stateAbbr).join(', ');\r\n } else {\r\n return 'National';\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Assessors',\r\n field: 'assessors',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: params => {\r\n const template = params.data as Core.ValuationTemplateModel;\r\n if (template.states.length === 1) {\r\n return params.data.assessors.map(x => x.assessorName).join(', ');\r\n } else {\r\n return 'Using All Assessors';\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Site Classes',\r\n field: 'siteClassPrimary',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsAndCommaParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueGetter: params => {\r\n return params.data.siteClassPrimaries.map(x => x.siteClassPrimaryDesc).join(', ');\r\n }\r\n },\r\n {\r\n colId: 'grid-column-actions',\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n pinned: 'right',\r\n lockVisible: true,\r\n sortable: false,\r\n cellRendererFramework: AgGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n buttonConfigs: [\r\n {\r\n iconClass: 'fa-pencil',\r\n isShown: () => true,\r\n onClick: this.editTemplate.bind(this)\r\n },\r\n {\r\n iconClass: 'fa-trash',\r\n buttonClass: 'btn-primary btn-danger',\r\n isShown: () => true,\r\n onClick: this.deleteTemplate.bind(this)\r\n }\r\n ]\r\n } as AgGridActionCellRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setDataSource();\r\n }\r\n\r\n async createNewTemplate(): Promise {\r\n const result = await this._modalService.showAsync(AddEditValuationTemplateComponent, {}, 'modal-md');\r\n\r\n if (!result) {\r\n return;\r\n }\r\n this._routerService.go('valuationTemplateDetail', { templateId: result.valuationTemplateId });\r\n }\r\n\r\n editTemplate(gridRow: AgGridActionCellRendererParams): void {\r\n const rowData = gridRow.data as Core.ValuationTemplateModel;\r\n this._routerService.go('valuationTemplateDetail', { templateId: rowData.valuationTemplateId });\r\n }\r\n\r\n async deleteTemplate(gridRow: AgGridActionCellRendererParams): Promise {\r\n const rowData = gridRow.data as Core.ValuationTemplateModel;\r\n\r\n try {\r\n await this._messageModalService.confirm('Are you sure you want to delete this valuation template?');\r\n } catch(err) {\r\n return;\r\n }\r\n\r\n try {\r\n await this._valuationTemplateService.deleteTemplate(rowData.valuationTemplateId);\r\n } finally {\r\n await this.refreshGridData();\r\n }\r\n }\r\n\r\n async refreshGridData(): Promise {\r\n if (this._gridApi) {\r\n this._gridApi.showLoadingOverlay();\r\n }\r\n try {\r\n this._gridValues = await this._valuationTemplateService.getTemplateList();\r\n } finally {\r\n this._setDataSource();\r\n }\r\n }\r\n\r\n private _setDataSource(): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n this._gridApi.setRowData(this._gridValues);\r\n this._gridApi.hideOverlay();\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n Valuation Templates\r\n \r\n

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n","import { AgGridDataSourceBase, AgGridDataSourceResult } from '../../Compliance/AgGrid';\r\nimport { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { ResponsibleEntityRepository } from '../responsbileEntity.repository';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\nexport interface ResponsibleEntityDataSourceParams {\r\n companyId: number;\r\n siteId?: number;\r\n parcelId: number;\r\n}\r\n\r\nexport class ResponsibleEntityAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _responsibleEntityRepository: ResponsibleEntityRepository,\r\n protected _dataSourceParamsFn: () => ResponsibleEntityDataSourceParams) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'name', value: Core.ResponsibleEntityPropertyEnum.Name },\r\n { name: 'responsibleEntityType', value: Core.ResponsibleEntityPropertyEnum.Type },\r\n { name: 'number', value: Core.ResponsibleEntityPropertyEnum.Number },\r\n { name: 'address1', value: Core.ResponsibleEntityPropertyEnum.Address1 },\r\n { name: 'address2', value: Core.ResponsibleEntityPropertyEnum.Address2 },\r\n { name: 'city', value: Core.ResponsibleEntityPropertyEnum.City },\r\n { name: 'state', value: Core.ResponsibleEntityPropertyEnum.State },\r\n { name: 'zip', value: Core.ResponsibleEntityPropertyEnum.Zip },\r\n { name: 'contact', value: Core.ResponsibleEntityPropertyEnum.Contact },\r\n { name: 'phone', value: Core.ResponsibleEntityPropertyEnum.Phone },\r\n { name: 'email', value: Core.ResponsibleEntityPropertyEnum.Email },\r\n { name: 'companyCode', value: Core.ResponsibleEntityPropertyEnum.CompanyCode },\r\n { name: 'companyName', value: Core.ResponsibleEntityPropertyEnum.CompanyName },\r\n { name: 'allocationDebitAccount', value: Core.ResponsibleEntityPropertyEnum.AllocationDebitAccount },\r\n { name: 'allocationCreditAccount', value: Core.ResponsibleEntityPropertyEnum.AllocationCreditAccount },\r\n { name: 'allocationReceivableAccount', value: Core.ResponsibleEntityPropertyEnum.AllocationReceivableAccount },\r\n { name: 'allocationsExport', value: Core.ResponsibleEntityPropertyEnum.AllocationsExport },\r\n { name: 'accrualsExport', value: Core.ResponsibleEntityPropertyEnum.AccrualsExport },\r\n { name: 'parcelAccountNumber', value: Core.ResponsibleEntityPropertyEnum.ParcelAccountNumber },\r\n { name: 'percentage', value: Core.ResponsibleEntityPropertyEnum.Percentage },\r\n { name: 'startDate', value: Core.ResponsibleEntityPropertyEnum.StartDate },\r\n { name: 'endDate', value: Core.ResponsibleEntityPropertyEnum.EndDate },\r\n ];\r\n\r\n async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.ResponsibleEntitySearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n siteId: this._dataSourceParams.siteId,\r\n parcelId: this._dataSourceParams.parcelId\r\n };\r\n\r\n const result = await lastValueFrom(this._responsibleEntityRepository.getList(this._dataSourceParams.companyId, searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.pagination = { skip: startIndex, take: endIndex - startIndex + 1} as Core.PaginationModel;\r\n\r\n return await lastValueFrom(this._responsibleEntityRepository.getRowIds(this._dataSourceParams.companyId, searchParams));\r\n }\r\n\r\n getSearchParamsWithoutPagination(): Core.ResponsibleEntitySearchModel {\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n } as Core.ResponsibleEntitySearchModel;\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return !!this._dataSourceParams.companyId;\r\n }\r\n}\r\n","import { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { Component } from '@angular/core';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\n\r\nexport interface ResponsibleEntityListGridActionCellRendererComponent extends ICellRendererParams{\r\n viewDetails: (params: ResponsibleEntityListGridActionCellRendererComponent) => void;\r\n canEdit: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class ResponsibleEntityListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n entity: Core.ResponsibleEntityModel;\r\n commentModalData: CommentModalData;\r\n\r\n private _params: ResponsibleEntityListGridActionCellRendererComponent;\r\n\r\n agInit(params: ResponsibleEntityListGridActionCellRendererComponent): void {\r\n this._params = params;\r\n this.entity = params.data as Core.ResponsibleEntityModel;\r\n\r\n if (!this.entity) {\r\n return;\r\n }\r\n\r\n this.commentModalData = {\r\n entityID: this.entity.responsibleEntityId,\r\n entityTypeID: Core.EntityTypes.ResponsibleEntity,\r\n entityName: this.entity.name,\r\n parcelAcctNum: null,\r\n canEdit: this._params.canEdit,\r\n description: null,\r\n parcelID: null,\r\n } as CommentModalData;\r\n }\r\n\r\n refresh(params: any): boolean {\r\n return false;\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this._params.viewDetails(this._params);\r\n }\r\n}\r\n","\r\n 0\">\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n Entity Name:\r\n
\r\n
\r\n {{entity.name}}\r\n \r\n
\r\n
\r\n Contact:\r\n
\r\n
\r\n {{entity.contact}}\r\n \r\n
\r\n
\r\n
\r\n
\r\n Entity Number:\r\n
\r\n
\r\n {{entity.number}}\r\n \r\n
\r\n
\r\n Phone:\r\n
\r\n
\r\n {{entity.phone}}\r\n \r\n
\r\n
\r\n
\r\n
\r\n Entity Type:\r\n
\r\n
\r\n {{entity.responsibleEntityType}}\r\n \r\n \r\n
\r\n
\r\n Email:\r\n
\r\n
\r\n {{entity.email}}\r\n \r\n
\r\n
\r\n
\r\n
\r\n Address:\r\n
\r\n
\r\n {{entity.address1}}\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n {{entity.address2}}\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n {{entity.city}}\r\n {{entity.state}}\r\n {{entity.zip}}\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
Alloc Debit Account:
\r\n
\r\n {{entity.allocationDebitAccount}}\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
Alloc Credit Account:
\r\n
\r\n {{entity.allocationCreditAccount}}\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
Alloc Receivable Account:
\r\n
\r\n {{entity.allocationReceivableAccount}}\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { AbstractControl, UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ResponsibleEntityRepository } from '../responsbileEntity.repository';\r\nimport { BusyIndicatorMessageManager } from '../../Busy-Indicator';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { CommentModalData } from '../../Comments/comments.service';\r\n\r\nexport interface ResponsibleEntityDetailsParams {\r\n companyId: number,\r\n data?: Core.ResponsibleEntityModel,\r\n canEdit: boolean\r\n}\r\n\r\n@Component({\r\n selector: 'responsible-entity-details',\r\n templateUrl: './responsibleEntityDetails.component.html',\r\n styleUrls: ['./responsibleEntityDetails.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ResponsibleEntityDetailsComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _responsibleEntityRepository: ResponsibleEntityRepository)\r\n {}\r\n\r\n params: ResponsibleEntityDetailsParams;\r\n result: Core.ResponsibleEntityModel;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n entityForm: UntypedFormGroup;\r\n entity: Core.ResponsibleEntityModel;\r\n entityTypes: Core.ResponsibleEntityTypeModel[];\r\n loading: boolean = false;\r\n canEdit: boolean = false;\r\n editing: boolean = false;\r\n commentModalData: CommentModalData;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n async ngOnInit(): Promise {\r\n this.entity = this.params.data;\r\n this.canEdit = this.params.canEdit || !this.params.data;\r\n this.editing = !this.params.data;\r\n\r\n const busyMsgLoading = 'loading';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsgLoading);\r\n this.loading = true;\r\n\r\n try {\r\n this.entityTypes = await lastValueFrom(this._responsibleEntityRepository.getTypes());\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgLoading);\r\n }\r\n\r\n this.entityForm = this._fb.group({\r\n name: [null, [Validators.required]],\r\n number: [null, [Validators.required]],\r\n responsibleEntityTypeId: [this.entityTypes[0].id, [Validators.required]],\r\n address1: [null],\r\n address2: [null],\r\n city: [null],\r\n stateId: [null],\r\n zip: [null],\r\n allocationDebitAccount: [null],\r\n allocationCreditAccount: [null],\r\n allocationReceivableAccount: [null],\r\n contact: [null],\r\n phone: [null],\r\n email: [null],\r\n allocationsExport: [{value: false, disabled: !this.editing}],\r\n accrualsExport: [{ value: false, disabled: !this.editing}]\r\n });\r\n\r\n if (this.entity) {\r\n this.entityForm.patchValue({\r\n name: this.entity.name,\r\n number: this.entity.number,\r\n responsibleEntityTypeId: this.entity.responsibleEntityTypeId,\r\n address1: this.entity.address1,\r\n address2: this.entity.address2,\r\n city: this.entity.city,\r\n stateId: this.entity.stateId,\r\n zip: this.entity.zip,\r\n allocationDebitAccount: this.entity.allocationDebitAccount,\r\n allocationCreditAccount: this.entity.allocationCreditAccount,\r\n allocationReceivableAccount: this.entity.allocationReceivableAccount,\r\n contact: this.entity.contact,\r\n phone: this.entity.phone,\r\n email: this.entity.email,\r\n allocationsExport: this.entity.allocationsExport,\r\n accrualsExport: this.entity.accrualsExport\r\n });\r\n\r\n this._setAllocationOptionalValidators(this.entity.allocationsExport);\r\n\r\n this.commentModalData = {\r\n entityID: this.entity.responsibleEntityId,\r\n entityTypeID: Core.EntityTypes.ResponsibleEntity,\r\n entityName: this.entity.name,\r\n parcelAcctNum: null,\r\n canEdit: this.canEdit,\r\n description: null,\r\n parcelID: null,\r\n } as CommentModalData;\r\n }\r\n\r\n this.allocationsExport.valueChanges.pipe(takeUntil(this._destroy$)).subscribe(allocationsExport => {\r\n this._setAllocationOptionalValidators(allocationsExport);\r\n });\r\n\r\n this.loading = false;\r\n }\r\n\r\n get accrualsExport(): AbstractControl {\r\n return this.entityForm.get('accrualsExport');\r\n }\r\n\r\n get allocationsExport(): AbstractControl {\r\n return this.entityForm.get('allocationsExport');\r\n }\r\n\r\n get allocationDebitAccount(): AbstractControl {\r\n return this.entityForm.get('allocationDebitAccount');\r\n }\r\n\r\n get allocationCreditAccount(): AbstractControl {\r\n return this.entityForm.get('allocationCreditAccount');\r\n }\r\n\r\n get allocationReceivableAccount(): AbstractControl {\r\n return this.entityForm.get('allocationReceivableAccount');\r\n }\r\n\r\n async save(): Promise {\r\n if (!this.editing) {\r\n this.cancel();\r\n return;\r\n }\r\n\r\n const busyMsgLoading = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsgLoading);\r\n\r\n try {\r\n if (this.entity) {\r\n const model: Core.ResponsibleEntityUpdateModel = this.entityForm.getRawValue();\r\n model.companyId = this.entity.companyId;\r\n model.responsibleEntityId = this.entity.responsibleEntityId;\r\n\r\n this.result = await lastValueFrom(this._responsibleEntityRepository.update(this.params.companyId, model));\r\n this.result.parcelAccountNumber = this.entity.parcelAccountNumber;\r\n this.result.percentage = this.entity.percentage;\r\n this.result.startDate = this.entity.startDate;\r\n this.result.endDate = this.entity.endDate;\r\n } else {\r\n const model: Core.ResponsibleEntityCreateModel = this.entityForm.getRawValue();\r\n model.companyId = this.params.companyId;\r\n\r\n this.result = await lastValueFrom(this._responsibleEntityRepository.create(this.params.companyId, model));\r\n }\r\n\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsgLoading);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n edit(): void {\r\n this.editing = true;\r\n\r\n this.allocationsExport.enable();\r\n this.accrualsExport.enable();\r\n }\r\n\r\n private _setAllocationOptionalValidators(allocationsExport: boolean): void {\r\n const validator = allocationsExport ? [Validators.required] : [];\r\n this.allocationDebitAccount.setValidators(validator);\r\n this.allocationDebitAccount.updateValueAndValidity();\r\n this.allocationCreditAccount.setValidators(validator);\r\n this.allocationCreditAccount.updateValueAndValidity();\r\n this.allocationReceivableAccount.setValidators(validator);\r\n this.allocationReceivableAccount.updateValueAndValidity();\r\n }\r\n}\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Responsible Entities\r\n \r\n

\r\n
\r\n
\r\n New Responsible Entity\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n","import { Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { CompanyService } from '../../Entity/Company/company.service';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../Busy-Indicator';\r\nimport { RestrictService } from '../../Common/Permissions/restrict.service';\r\nimport { ResponsibleEntityRepository } from '../responsbileEntity.repository';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { BreadCrumb } from '../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, RowNode } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../Compliance/AgGrid';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../Compliance/AgGrid/ToolPanel/models';\r\nimport { BehaviorSubject, lastValueFrom, Subscription } from 'rxjs';\r\nimport { ResponsibleEntityAgGridDataSource, ResponsibleEntityDataSourceParams } from './agGridDataSource';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport {\r\n AgGridYesNoFloatingFilterComponent\r\n} from '../../Compliance/AgGrid/FloatingFilters/agGridYesNoFloatingFilter.component';\r\nimport { ResponsibleEntityListGridActionCellRendererComponent } from './agGridActionCellRenderer.component';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport {\r\n ResponsibleEntityDetailsComponent,\r\n ResponsibleEntityDetailsParams\r\n} from '../Responsible-Entity-Details/responsibleEntityDetails.component';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\nimport AccessRightsEnum = Core.AccessRightsEnum;\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { WeissmanDateFormatPipe } from '../../UI-Lib/Pipes';\r\n\r\n@Component({\r\n selector: 'responsible-entity-list',\r\n templateUrl: './responsibleEntityList.component.html',\r\n styleUrls: ['./responsibleEntityList.component.scss']\r\n})\r\nexport class ResponsibleEntityListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _companyService: CompanyService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _responsibleEntityRepository: ResponsibleEntityRepository,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _datePipe: WeissmanDateFormatPipe\r\n ) {\r\n }\r\n\r\n @Input() companyId: number;\r\n @Input() siteId?: number;\r\n @Input() parcelId?: number;\r\n @Output() loading: EventEmitter = new EventEmitter();\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n canEdit: boolean = false;\r\n isInitialized: boolean = false;\r\n gridTracker: AgGridMultiSelectTracker;\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n hasSelectedRows: boolean = false;\r\n refreshing: boolean = false;\r\n isEmbeddedMode: boolean;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected((params.data as Core.ResponsibleEntityModel).responsibleEntityId)\r\n }\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const searchParams = this._gridDataSource.getSearchParamsWithoutPagination();\r\n\r\n const exportModel: Core.ResponsibleEntityExportModel = {\r\n columnFilters: searchParams.columnFilters,\r\n sortColumns: searchParams.sortColumns,\r\n selectedRows: this.gridTracker.getSelectedRowsModel(),\r\n fileFormat: fileFormat,\r\n columnsToReturn: columnsToReturn,\r\n siteId: this.siteId,\r\n parcelId: this.parcelId\r\n };\r\n\r\n const lrp$ = this._responsibleEntityRepository.startExport(this.companyId, exportModel);\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportResponsibleEntities };\r\n },\r\n canCancel: true,\r\n showFileFormatSelection: true\r\n };\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: ResponsibleEntityAgGridDataSource;\r\n private _gridMultiSelectSub: Subscription;\r\n private _canEdit: boolean = false;\r\n private _companyGridId: System.Guid = 'B41B12F0-56CD-49D7-8167-71CFE38838BF';\r\n private _siteGridId: System.Guid = '45F8F7B8-BB45-413E-BBA9-6AB2E3675312';\r\n private _parcelGridId: System.Guid = '4CF6D3AB-89A2-4B75-988C-7E1D16C2810B';\r\n\r\n async ngOnInit(): Promise {\r\n this.isEmbeddedMode = !!this.siteId || !!this.parcelId;\r\n\r\n if (!this.companyId) {\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n }\r\n\r\n const [canView, canEdit] = await Promise.all([\r\n this._restrictService.hasCompanyPermission(this.companyId, AccessRightsEnum.Read),\r\n this._restrictService.hasCompanyPermission(this.companyId, AccessRightsEnum.Write)\r\n ]);\r\n\r\n this._canEdit = canEdit;\r\n\r\n if (!canView) {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n let busyRef: BusyIndicatorRef;\r\n\r\n if (!this.isEmbeddedMode) {\r\n busyRef = this._busyIndicatorService.show({message: 'Loading'});\r\n }\r\n\r\n try {\r\n this.canEdit = await this._restrictService.hasCompanyPermission(this.companyId, Core.AccessRightsEnum.Write);\r\n\r\n const company: Core.CompanyModel = await this._companyService.getInfoForCompliance(this.companyId);\r\n\r\n this.breadcrumbs.push({\r\n name: company.companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n });\r\n\r\n this.isInitialized = true;\r\n } finally {\r\n if (!this.isEmbeddedMode) {\r\n await busyRef.hide();\r\n } else {\r\n this.loading.emit(false);\r\n }\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n this._gridApi.showLoadingOverlay();\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n const columns: ColDef[] = this._getColumns();\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'dueDate',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n\r\n this._setDataSource();\r\n\r\n this._gridApi.sizeColumnsToFit();\r\n\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(() => {\r\n const isBulkUpdateVisible = this.gridTracker.hasSelectedRows();\r\n // this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n this.hasSelectedRows = isBulkUpdateVisible;\r\n });\r\n\r\n }\r\n\r\n refresh() {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n async addResponsibleEntity(): Promise {\r\n const modalParams: ResponsibleEntityDetailsParams = {\r\n companyId: this.companyId,\r\n canEdit: true\r\n };\r\n\r\n const result = await this._modalService.showAsync(ResponsibleEntityDetailsComponent, modalParams, 'modal-xl');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.refresh();\r\n return Promise.resolve();\r\n }\r\n\r\n get gridId(): System.Guid {\r\n return this.siteId\r\n ? this._siteGridId\r\n : this.parcelId\r\n ? this._parcelGridId\r\n : this._companyGridId;\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const dataSourceParams = (): ResponsibleEntityDataSourceParams => {\r\n return {\r\n companyId: this.companyId,\r\n siteId: this.siteId,\r\n parcelId: this.parcelId\r\n };\r\n };\r\n\r\n this._gridDataSource = new ResponsibleEntityAgGridDataSource(this._gridApi, this._responsibleEntityRepository, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private _getColumns() {\r\n const columns = [\r\n {\r\n headerName: '',\r\n field: 'responsibleEntityId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockPosition: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {tracker: this.gridTracker} as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {tracker: this.gridTracker} as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {\r\n return '';\r\n }\r\n },\r\n {\r\n headerName: 'Entity Name',\r\n field: 'name',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParamsStartsWith,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n pinned: true\r\n },\r\n {\r\n headerName: 'Entity Type',\r\n field: 'responsibleEntityType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParamsStartsWith,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Entity Number',\r\n field: 'number',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterParamsWithEqualTo,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Address One',\r\n field: 'address1',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Address Two',\r\n field: 'address2',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'City',\r\n field: 'city',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Zip',\r\n field: 'zip',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Contact',\r\n field: 'contact',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Phone',\r\n field: 'phone',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Email',\r\n field: 'email',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Company Code',\r\n field: 'companyCode',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const responsibleEntity = params.data as Core.ResponsibleEntityModel;\r\n if (!responsibleEntity) {\r\n return '';\r\n }\r\n return `#/company/${responsibleEntity.companyId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Company Name',\r\n field: 'companyName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const responsibleEntity = params.data as Core.ResponsibleEntityModel;\r\n if (!responsibleEntity) {\r\n return '';\r\n }\r\n return `#/company/${responsibleEntity.companyId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n }];\r\n\r\n let embeddedColumns: ColDef[] = [];\r\n\r\n if (this.isEmbeddedMode) {\r\n if (!this.parcelId) {\r\n embeddedColumns = [\r\n {\r\n headerName: 'Parcel Account Number',\r\n field: 'parcelAccountNumber',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n }\r\n\r\n embeddedColumns.push(\r\n {\r\n headerName: 'Percentage',\r\n field: 'percentage',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeFilterAndEqualToParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => this._decimalPipe.transform(params.value, '1.2-2'),\r\n cellClass: 'ag-numeric-cell'\r\n },\r\n {\r\n headerName: 'Start Date',\r\n field: 'startDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true),\r\n hide: true\r\n },\r\n {\r\n headerName: 'End Date',\r\n field: 'endDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => this._datePipe.transform(params.value, true),\r\n hide: true\r\n });\r\n }\r\n\r\n const additionalColumns = [\r\n {\r\n headerName: 'Alloc Debit Account',\r\n field: 'allocationDebitAccount',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Alloc Credit Account',\r\n field: 'allocationCreditAccount',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Alloc Receivable Account',\r\n field: 'allocationReceivableAccount',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Allocations Export',\r\n field: 'allocationsExport',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const responsibleEntity = params.data as Core.ResponsibleEntityModel;\r\n return responsibleEntity\r\n ? responsibleEntity.allocationsExport ? 'Yes' : 'No'\r\n : '';\r\n },\r\n hide: true\r\n },\r\n {\r\n headerName: 'Accruals Export',\r\n field: 'accrualsExport',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agYesNoColumnFilter',\r\n filterParams: AgGridFilterParams.yesNoFilterParams,\r\n floatingFilterComponentFramework: AgGridYesNoFloatingFilterComponent,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const responsibleEntity = params.data as Core.ResponsibleEntityModel;\r\n return responsibleEntity\r\n ? responsibleEntity.accrualsExport ? 'Yes' : 'No'\r\n : '';\r\n },\r\n hide: true\r\n },\r\n {\r\n colId: 'grid-column-actions',\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n pinned: 'right',\r\n lockVisible: true,\r\n sortable: false,\r\n cellRendererFramework: ResponsibleEntityListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this._viewDetails.bind(this),\r\n canEdit: this._canEdit\r\n } as ResponsibleEntityListGridActionCellRendererComponent,\r\n pinnedRowCellRenderer: () => {return '';}\r\n }\r\n ];\r\n\r\n return [...columns, ...embeddedColumns, ...additionalColumns];\r\n }\r\n\r\n private async _viewDetails(params: ResponsibleEntityListGridActionCellRendererComponent): Promise {\r\n const modalParams: ResponsibleEntityDetailsParams = {\r\n companyId: this.companyId,\r\n data: params.data as Core.ResponsibleEntityModel,\r\n canEdit: this.canEdit\r\n };\r\n\r\n const result = await this._modalService.showAsync(ResponsibleEntityDetailsComponent, modalParams, 'modal-xl');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const allNodesOnPage: RowNode[] = [];\r\n this._gridApi.forEachNode(x => {\r\n const gridRow = x.data as Core.ResponsibleEntityModel;\r\n if (gridRow.responsibleEntityId === result.responsibleEntityId) {\r\n x.data = result;\r\n allNodesOnPage.push(x);\r\n }\r\n });\r\n this._gridApi.redrawRows({rowNodes: allNodesOnPage});\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { NavigationService } from '../Layout/navigation.service';\r\nimport { AccountService, GrantTypes } from '../User/account.service';\r\nimport { AuthStorageService } from '../User/authStorage.service';\r\n\r\nconst ssoSessionKey = 'ssoResponse';\r\n\r\n@Component({\r\n selector: 'ssoLogin',\r\n template: `\r\n
\r\n
\r\n \r\n
\r\n

{{errorMessage}}

\r\n
`\r\n})\r\nexport class SSOLoginComponent implements OnInit {\r\n constructor(\r\n private accountService: AccountService,\r\n private navigationService: NavigationService,\r\n private authStorageService: AuthStorageService\r\n ) { }\r\n\r\n loading: boolean;\r\n errorMessage: string;\r\n\r\n async ngOnInit() {\r\n const ssoResponse = sessionStorage[ssoSessionKey];\r\n if (ssoResponse) {\r\n this.loading = true;\r\n let keepLoading = false;\r\n try {\r\n await this.accountService.login(GrantTypes.saml20, ssoResponse, true, true);\r\n if (this.authStorageService.isMigrationLogin) {\r\n keepLoading = true;\r\n return;\r\n }\r\n }\r\n catch (err) {\r\n console.error(err);\r\n if (err && err.error && err.error.error_description) {\r\n this.errorMessage = err.error.error_description;\r\n }\r\n else {\r\n this.errorMessage = 'Error logging in';\r\n }\r\n return;\r\n }\r\n finally {\r\n if (!keepLoading) {\r\n this.loading = false;\r\n }\r\n delete sessionStorage[ssoSessionKey];\r\n }\r\n this.navigationService.postLogin();\r\n }\r\n else {\r\n this.errorMessage = 'Error logging in: no information from SSO provider found.';\r\n }\r\n }\r\n}\r\n","\r\n\r\n
\r\n\t
\r\n

ATTACHMENT DOWNLOAD TOOL

\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n DownloadingDownloaded\r\n {{ currentByte / 1048576 | number : '1.0-0' }}\r\n of\r\n {{ byteCount / 1048576 | number : '1.0-0'}}\r\n MB\r\n \r\n
\r\n

Attachment Info

\r\n
{{attachmentInfo}}
\r\n
\r\n
\r\n
\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Component } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { Attachment } from 'src/app/Attachment/attachment.model';\r\nimport { AttachmentService } from 'src/app/Attachment/attachment.service';\r\nimport { BusyIndicatorService } from 'src/app/Busy-Indicator';\r\n\r\n@Component({\r\n selector: 'attachment-download-diagnostic',\r\n templateUrl: './attachmentDownloadDiagnostic.component.html',\r\n styleUrls: ['./attachmentDownloadDiagnostic.component.scss']\r\n})\r\nexport class AttachmentDownloadDiagnosticComponent {\r\n attachmentId: string;\r\n attachmentInfo: string;\r\n currentByte: number;\r\n byteCount: number;\r\n downloading: boolean;\r\n abortController: AbortController;\r\n\r\n constructor(\r\n private readonly _toastr: ToastrService,\r\n private readonly _busyService: BusyIndicatorService,\r\n private readonly _attachmentService: AttachmentService,\r\n private readonly _http: HttpClient\r\n ) {\r\n }\r\n\r\n async getInfo() {\r\n if (!this.validate()) {\r\n return;\r\n }\r\n\r\n const busyRef = this._busyService.show({message: 'Getting Info'});\r\n\r\n try {\r\n await this.loadInfo();\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n async bufferedDownload() {\r\n if (!this.validate()) {\r\n return;\r\n }\r\n const busyRef = this._busyService.show({message: 'Processing download'});\r\n\r\n try {\r\n await this._attachmentService.downloadAttachmentFileBuffered(await this.loadInfo());\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n async streamedDownload() {\r\n if (!this.validate()) {\r\n return;\r\n }\r\n const busyRef = this._busyService.show({message: 'Processing download'});\r\n\r\n try {\r\n await this._attachmentService.downloadAttachmentFileStreamed(await this.loadInfo());\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n async simulateDownload() {\r\n if (!this.validate()) {\r\n return;\r\n }\r\n const busyRef = this._busyService.show({message: 'Processing download'});\r\n this.abortController = new AbortController();\r\n let fetchResponse: Response;\r\n\r\n try {\r\n const info = await this.loadInfo();\r\n const oneTimeCode = await lastValueFrom(this._http.get(`/api/attachment/${info.attachmentID}/OneTimeCode`));\r\n fetchResponse = await fetch(`/api/attachment/Download/${encodeURIComponent(oneTimeCode)}`, { signal: this.abortController.signal });\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n\r\n this.downloading = true;\r\n this.byteCount = +fetchResponse.headers.get('content-length');\r\n this.currentByte = 0;\r\n const reader = fetchResponse.body.getReader();\r\n let done = false;\r\n let value;\r\n\r\n while (!done) {\r\n ({ done, value } = await reader.read());\r\n\r\n if (!done) {\r\n this.currentByte += value.length;\r\n // Honestly it's usually pretty annoying to flood the log with these, so put a hidden flag here a dev an set if needed.\r\n if (window['showDownloadChunkLengths']) {\r\n console.log(`Read chunk (${value.length} bytes)`);\r\n }\r\n }\r\n }\r\n\r\n this.downloading = false;\r\n }\r\n\r\n cancel() {\r\n this.abortController.abort();\r\n this.downloading = false;\r\n }\r\n\r\n private async loadInfo(): Promise {\r\n this.byteCount = null;\r\n this.attachmentInfo = null;\r\n const result = await this._attachmentService.getInfo(this.attachmentId);\r\n this.attachmentInfo = JSON.stringify(result, null, 4);\r\n return result;\r\n }\r\n\r\n private validate(): boolean {\r\n if (!this.attachmentId || /^\\s*$/.test(this.attachmentId)) {\r\n this._toastr.warning('You must supply an Attachment Id.');\r\n return false;\r\n }\r\n\r\n if (!/^\\s*[0-9a-fA-F]{8}(-[0-9a-fA-F]{4}){3}-[0-9a-fA-F]{12}\\s*/.test(this.attachmentId)) {\r\n this._toastr.warning('Attachment Id must be a GUID.');\r\n return false;\r\n }\r\n\r\n return true;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { Ng2StateDeclaration, UIRouter, UIRouterModule } from '@uirouter/angular';\r\nimport { ChangePasswordComponent } from './Account/Change-Password/changePassword.component';\r\nimport { ExternalAPIKeyComponent } from './Account/ExternalAPI/external-api-key.component';\r\nimport { LoginComponent } from './Account/Login/login.component';\r\nimport { AccrualsPageComponent } from './Accruals/accruals.page.component';\r\nimport { AboutComponent } from './Admin/About/about.component';\r\nimport { AdminComponent } from './Admin/admin.component';\r\nimport { TestDXPPageComponent } from './Admin/DXP/testDXPPage.component';\r\nimport { LoginManagerComponent } from './Admin/LoginManager/loginManager.component';\r\nimport { APIKeyDetailComponent } from './Admin/ManageAPIKeys/api-key-detail.component';\r\nimport { ManageAPIKeysComponent } from './Admin/ManageAPIKeys/manage-api-keys.component';\r\nimport { AgentsPageComponent } from './Agents/agents.page.component';\r\nimport { AppealApplicationComponent } from './Appeal-Application/appealApplication.component';\r\nimport {\r\n ARCCComponent\r\n} from './Appeal-Recommendation/ARCC/aRCC.component';\r\nimport { AssessorComponent } from './Assessor-Collector/Assessor/assessor.component';\r\nimport { CollectorComponent } from './Assessor-Collector/Collector/collector.component';\r\nimport { AssessorListComponent } from './Assessor-Collector/List/assessorList.component';\r\nimport { CollectorListComponent } from './Assessor-Collector/List/collectorList.component';\r\nimport { ForecastingBudgetingPageComponent } from './Budget/forecasting.budgeting.page.component';\r\nimport { BulkImportAssessmentsComponent } from './Bulk-Import/Assessments/bulk.import.assessments.component';\r\nimport { BulkImportSitesComponent, ImportType } from './Bulk-Import/Sites/bulk.import.sites.component';\r\nimport { CsrCommandCenterComponent } from './Client-Services/Command-Center/csrCommandCenter.component';\r\nimport { InstanceRights, Roles } from './Common/Permissions/restrict.service';\r\nimport { AllocationDetailsComponent } from './Compliance/Allocation/Allocation-Details/allocationDetails.component';\r\nimport { AssetListComponent } from './Compliance/Asset/Asset-List/assetList.component';\r\nimport { ElectronicFilingComponent } from './Compliance/Electronic-Filing/electronicFiling.component';\r\nimport { EntityImportListComponent } from './Compliance/Entity-Import/Import-List/importList.component';\r\nimport { EntityImportProcessComponent } from './Compliance/Entity-Import/Import-Process/importProcess.component';\r\nimport {\r\n ImportSpecificationListComponent\r\n} from './Compliance/Entity-Import/Import-Specification-List/importSpecificationList.component';\r\nimport { FactorTableListComponent } from './Compliance/Factor-Table/Factor-Table-List/factorTableList.component';\r\nimport {\r\n FilingBatchDetailsComponent\r\n} from './Compliance/Filing-Batch/Filing-Batch-Details/filingBatchDetails.component';\r\nimport { FilingBatchListComponent } from './Compliance/Filing-Batch/Filing-Batch-List/filingBatchList.component';\r\nimport { FormListComponent } from './Compliance/Form/Form-List/formList.component';\r\nimport { FormPageComponent } from './Compliance/Form/Form-Page/formPage.component';\r\nimport { GLAccountListComponent } from './Compliance/GL-Account/GL-Account-List/glAccountList.component';\r\nimport {\r\n LongRunningProcessPageComponent\r\n} from './Compliance/Long-Running-Process/Long-Running-Process-Page/longRunningProcessPage.component';\r\nimport { ReturnPageComponent } from './Compliance/Return/returnPage.component';\r\nimport {\r\n StateJurisdictionCommandCenterComponent\r\n} from './Compliance/State-And-Jurisdiction/stateJurisdiction.component';\r\nimport {\r\n SupplementalInformationSheetComponent\r\n} from './Compliance/Supplemental-Information/Supplemental-Information-Sheet/supplementalInformationSheet.component';\r\nimport { ConsultingEngagementsComponent } from './Consulting/consultingEngagements.component';\r\nimport { ContactListPageComponent } from './Contact/Page/contactListPage.component';\r\nimport { DashboardComponent } from './Dashboard/dashboard.component';\r\nimport { ProcessListComponent } from './Diagnostics/Database/Process-List/processList.component';\r\nimport { DiagnosticsComponent } from './Diagnostics/diagnostics.component';\r\nimport { ErrorLogListComponent } from './Diagnostics/Error-Log/Error-Log-List/errorLogList.component';\r\nimport { QueryInfoListComponent } from './Diagnostics/Query-Info/Query-Info-List/queryInfoList.component';\r\nimport {\r\n DocumentIntakeLicensedClientListComponent\r\n} from './Documents/Document-Intake-Licensed-Clients/Document-Intake-Licensed-Client-List/documentIntakeLicensedClientList.component';\r\nimport { DocumentIntakeComponent } from './Documents/Document-Intake/document.intake.component';\r\nimport { CompanyPageComponent } from './Entity/Company/companyPage.component';\r\nimport { VendorCodeMappingComponent } from './Entity/Company/Vendor-Codes/vendorCodeMapping.component';\r\nimport { InstanceInfoPanelComponent } from './Entity/Instance/Info/instanceInfoPanel.component';\r\nimport { ManageInvitationsComponent } from './Entity/Instance/manageInvitations.component';\r\nimport { MoveCopyEntityComponent } from './Entity/move.copy.entity.component';\r\nimport { SiteMapComponent } from './Entity/site.map.component';\r\nimport { HelpComponent } from './Landing/Help/help.component';\r\nimport { LandingComponent } from './Landing/landing.component';\r\nimport { LandingSelectorComponent } from './Landing/landing.selector.component';\r\nimport { SavedActionViewComponent } from './Navigation/Saved-AV/savedActionView.component';\r\nimport { SavedReportComponent } from './Navigation/Saved-Report/savedReport.component';\r\nimport { TopNavService } from './Navigation/Top-Nav/topNav.service';\r\nimport { SaveTabContentComponent } from './Navigation/User-Save/Save-Tab-Content/saveTabContent.component';\r\nimport { SavedSmartComponent } from './Navigation/Saved-Smart/savedSmart.component';\r\nimport { SearchCategoryType, SearchPageType, UserSaveService } from './Navigation/User-Save/userSave.service';\r\nimport { PaymentBatchCommandCenterComponent } from './Payment-Batch/Command-Center/paymentBatch.component';\r\nimport { PaymentBatchDetailsComponent } from './Payment-Batch/Payment-Batch-Details/paymentBatchDetails.component';\r\nimport { ProcessInvoiceComponent } from './Processing/Invoice/invoice.component';\r\nimport {\r\n PaymentPackageAttachmentSummaryComponent\r\n} from './Processing/Transmittal/payment-package-attachment-summary.component';\r\nimport { PaymentPackagesComponent } from './Processing/Transmittal/payment-packages.component';\r\nimport { PropertyCharacteristicsComponent } from './Property-Characteristics/property.characteristics.component';\r\nimport { ReportManagerComponent } from './Reporting/Manager/report.manager.component';\r\nimport { RolesListComponent } from './Role/roles.list.component';\r\nimport { SmartSearchComponent } from './Search/Advanced/smartSearch.component';\r\nimport { UnitedStatesComponent } from './State/states.component';\r\nimport { USStateComponent } from './State/us.state.component';\r\nimport { SupportInstanceListComponent } from './Support-Instances/Support-Instance-List/supportInstanceList.component';\r\nimport {\r\n ActionViewOutputDefaultsComponent\r\n} from './Task/ActionView/Action-View-Output-Defaults/actionViewOutputDefaults.component';\r\nimport { TaxRateCommandCenterComponent } from './Tax-Rate/Command-Center/tax.rate.command.center.component';\r\nimport { TaxAuthorityComponent } from './Tax-Rate/Tax-Authority/tax.authority.component';\r\nimport { TaxRateAreaComponent } from './Tax-Rate/Tax-Rate-Area/tax.rate.area.component';\r\nimport { TeamsPageComponent } from './Team/teams.page.component';\r\nimport { UserGroupDetailComponent } from './User-Group/User-Group-Detail/userGroupDetail.component';\r\nimport { UserGroupListComponent } from './User-Group/User-Group-List/userGroupList.component';\r\nimport {\r\n IncomeStatementListComponent\r\n} from './Valuation/Income-Statement/Income-Statement-List/incomeStatementList.component';\r\nimport { RentRollListComponent } from './Valuation/Rent-Roll/Rent-Roll-List/rentRollList.component';\r\nimport {\r\n ValuationTemplateDetailComponent\r\n} from './Valuation/Templates/Template-Detail/valuationTemplateDetail.component';\r\nimport { ValuationTemplatesComponent } from './Valuation/Templates/valuationTemplates.component';\r\nimport {\r\n ResponsibleEntityListComponent\r\n} from './Responsible-Entity/Responsible-Entity-List/responsibleEntityList.component';\r\nimport { SSOLoginComponent } from './Landing/ssoLogin.component';\r\nimport { AttachmentDownloadDiagnosticComponent } from './Diagnostics/Attachment-Download/attachmentDownloadDiagnostic.component';\r\n\r\nexport function config(uiRouter: UIRouter) {\r\n // Uncomment to enable the router visualizer for debugging\r\n // window['visualizer'] && window['visualizer'].dispose();\r\n // window['visualizer'] = uiRouter.plugin(Visualizer);\r\n uiRouter.urlService.rules.initial({ state: 'home' });\r\n uiRouter.urlService.rules.otherwise({ state: 'home' });\r\n}\r\n\r\nexport const STATES: Ng2StateDeclaration[] = [\r\n {\r\n name: 'login',\r\n url: '/login?logout',\r\n component: LoginComponent\r\n },\r\n {\r\n name: 'changePassword',\r\n url: '/change-password',\r\n component: ChangePasswordComponent\r\n },\r\n {\r\n name: 'resetPasswordUsingTokenFromEmail',\r\n url: '/login/resetPassword/:tokenHash',\r\n component: LoginComponent\r\n },\r\n {\r\n name: 'home',\r\n url: '/home',\r\n component: LandingSelectorComponent\r\n },\r\n {\r\n name: 'dashboard',\r\n url: '/dashboard',\r\n redirectTo: 'home'\r\n },\r\n {\r\n name: 'landing',\r\n url: '/landing',\r\n component: LandingComponent\r\n },\r\n {\r\n name: 'ssoLogin',\r\n url: '/ssoLogin',\r\n component: SSOLoginComponent\r\n },\r\n // {\r\n // name: 'unauthorizedAccess',\r\n // component: '

You do not have permission to view this page. If you have any questions, please contact the site administrator.

',\r\n // },\r\n // {\r\n // name: 'logout'\r\n // // todo - figure out why onEnter throws AngularJS injection error\r\n // // onEnter: (trans: Transition) => {\r\n // // const accountService = trans.injector().get(AccountService);\r\n // // return accountService.logout().then(() => {\r\n // // return false;\r\n // // });\r\n // // }\r\n // },\r\n {\r\n name: 'manageAPIKeys',\r\n url: '/ManageAPIKeys',\r\n component: ManageAPIKeysComponent\r\n },\r\n {\r\n name: 'apiKeyDetail',\r\n url: '/ManageAPIKeys/:integrationHmacId',\r\n component: APIKeyDetailComponent\r\n },\r\n {\r\n name: 'externalAPIKey',\r\n url: '/externalAPIKey/{requestCode:string}',\r\n component: ExternalAPIKeyComponent\r\n },\r\n {\r\n name: 'search',\r\n url: '/search/:searchId?searchType?filters',\r\n params: {\r\n searchId: null\r\n },\r\n component: SmartSearchComponent\r\n },\r\n {\r\n name: 'savedSmart',\r\n url: '/saved/smart',\r\n component: SavedSmartComponent,\r\n redirectTo: 'savedSmart.system'\r\n },\r\n {\r\n name: 'savedSmart.system',\r\n url: '/system',\r\n component: SaveTabContentComponent,\r\n resolve: [\r\n {\r\n token: 'userPageConfig', deps: [UserSaveService], resolveFn: async (service: UserSaveService) => {\r\n const page = service.getSavePage(SearchPageType.Smart);\r\n if (page[SearchCategoryType.System].length === 0) {\r\n await service.updateList(SearchPageType.Smart);\r\n } else {\r\n service.updateList(SearchPageType.Smart);\r\n }\r\n page.currentSelectedFilter = SearchCategoryType.System;\r\n return page;\r\n }\r\n }\r\n ]\r\n },\r\n {\r\n name: 'savedSmart.user',\r\n url: '/user',\r\n component: SaveTabContentComponent,\r\n resolve: [\r\n {\r\n token: 'userPageConfig', deps: [UserSaveService], resolveFn: async (service: UserSaveService) => {\r\n const page = service.getSavePage(SearchPageType.Smart);\r\n if (page[SearchCategoryType.User].length === 0) {\r\n await service.updateList(SearchPageType.Smart);\r\n } else {\r\n service.updateList(SearchPageType.Smart);\r\n }\r\n page.currentSelectedFilter = SearchCategoryType.User;\r\n return page;\r\n }\r\n }\r\n ]\r\n },\r\n {\r\n name: 'savedSmart.favorite',\r\n url: '/favorite',\r\n component: SaveTabContentComponent,\r\n resolve: [\r\n {\r\n token: 'userPageConfig', deps: [UserSaveService], resolveFn: async (service: UserSaveService) => {\r\n const page = service.getSavePage(SearchPageType.Smart);\r\n if (page[SearchCategoryType.Favorite].length === 0) {\r\n await service.updateList(SearchPageType.Smart);\r\n } else {\r\n service.updateList(SearchPageType.Smart);\r\n }\r\n page.currentSelectedFilter = SearchCategoryType.Favorite;\r\n return page;\r\n }\r\n }\r\n ]\r\n },\r\n // {\r\n // name: 'actionview',\r\n // url: '/actionview/:actionViewId?actionViewType&displayType',\r\n // params: { actionViewId: null },\r\n // controller: ActionViewController,\r\n // onExit: ['actionViewService', function (actionViewService) {\r\n // actionViewService.cancelAvSearch();\r\n // }]\r\n // },\r\n {\r\n name: 'savedActionView',\r\n url: '/saved/action-view',\r\n component: SavedActionViewComponent,\r\n redirectTo: 'savedActionView.system'\r\n },\r\n {\r\n name: 'savedActionView.system',\r\n url: '/system',\r\n component: SaveTabContentComponent,\r\n resolve: [\r\n {\r\n token: 'userPageConfig', deps: [UserSaveService], resolveFn: async (service: UserSaveService) => {\r\n const page = service.getSavePage(SearchPageType.AV);\r\n if (page[SearchCategoryType.System].length === 0) {\r\n await service.updateList(SearchPageType.AV);\r\n } else {\r\n service.updateList(SearchPageType.AV);\r\n }\r\n page.currentSelectedFilter = SearchCategoryType.System;\r\n return page;\r\n }\r\n }\r\n ]\r\n },\r\n {\r\n name: 'savedActionView.user',\r\n url: '/user',\r\n component: SaveTabContentComponent,\r\n resolve: [\r\n {\r\n token: 'userPageConfig', deps: [UserSaveService], resolveFn: async (service: UserSaveService) => {\r\n const page = service.getSavePage(SearchPageType.AV);\r\n if (page[SearchCategoryType.User].length === 0) {\r\n await service.updateList(SearchPageType.AV);\r\n } else {\r\n service.updateList(SearchPageType.AV);\r\n }\r\n page.currentSelectedFilter = SearchCategoryType.User;\r\n return page;\r\n }\r\n }\r\n ]\r\n },\r\n {\r\n name: 'savedActionView.favorite',\r\n url: '/favorite',\r\n component: SaveTabContentComponent,\r\n resolve: [\r\n {\r\n token: 'userPageConfig', deps: [UserSaveService], resolveFn: async (service: UserSaveService) => {\r\n const page = service.getSavePage(SearchPageType.AV);\r\n if (page[SearchCategoryType.Favorite].length === 0) {\r\n await service.updateList(SearchPageType.AV);\r\n } else {\r\n service.updateList(SearchPageType.AV);\r\n }\r\n page.currentSelectedFilter = SearchCategoryType.Favorite;\r\n return page;\r\n }\r\n }\r\n ]\r\n },\r\n {\r\n name: 'savedReport',\r\n url: '/saved/report',\r\n component: SavedReportComponent,\r\n redirectTo: 'savedReport.system'\r\n },\r\n {\r\n name: 'savedReport.system',\r\n url: '/system',\r\n component: SaveTabContentComponent,\r\n resolve: [\r\n {\r\n token: 'userPageConfig', deps: [UserSaveService], resolveFn: async (service: UserSaveService) => {\r\n const page = service.getSavePage(SearchPageType.Report);\r\n if (page[SearchCategoryType.System].length === 0) {\r\n await service.updateList(SearchPageType.Report);\r\n } else {\r\n service.updateList(SearchPageType.Report);\r\n }\r\n page.currentSelectedFilter = SearchCategoryType.System;\r\n return page;\r\n }\r\n }\r\n ]\r\n },\r\n {\r\n name: 'savedReport.user',\r\n url: '/user',\r\n component: SaveTabContentComponent,\r\n resolve: [\r\n {\r\n token: 'userPageConfig', deps: [UserSaveService], resolveFn: async (service: UserSaveService) => {\r\n const page = service.getSavePage(SearchPageType.Report);\r\n if (page[SearchCategoryType.User].length === 0) {\r\n await service.updateList(SearchPageType.Report);\r\n } else {\r\n service.updateList(SearchPageType.Report);\r\n }\r\n page.currentSelectedFilter = SearchCategoryType.User;\r\n return page;\r\n }\r\n }\r\n ]\r\n },\r\n {\r\n name: 'manage',\r\n url: '/manage',\r\n component: AdminComponent,\r\n redirectTo: (trans) => {\r\n const topNavService = trans.injector().get(TopNavService) as TopNavService;\r\n if (topNavService.roles().hasContactRoles) {\r\n return 'manage.contacts';\r\n }\r\n }\r\n },\r\n {\r\n name: 'manage.contacts',\r\n url: '/contacts',\r\n component: ContactListPageComponent,\r\n data: {\r\n instanceRights: [InstanceRights.CONTACTVIEW, InstanceRights.CONTACTEDIT]\r\n }\r\n },\r\n {\r\n name: 'contacts',\r\n url: '/contacts',\r\n component: ContactListPageComponent,\r\n data: {\r\n instanceRights: [InstanceRights.CONTACTVIEW, InstanceRights.CONTACTEDIT]\r\n }\r\n },\r\n // {\r\n // name: 'contact',\r\n // url: '/contacts/:contactId',\r\n // params: {\r\n // contactId: null\r\n // },\r\n // data: {\r\n // instanceRights: [InstanceRights.CONTACTVIEW, InstanceRights.CONTACTEDIT]\r\n // },\r\n // // todo\r\n // onEnter: (trans: Transition, state: StateDeclaration) => {\r\n // console.log('state', state);\r\n // // return true;\r\n // // if (state.params.contactId) {\r\n // // const contactModalService = trans.injector().get(ContactModalService);\r\n // // console.log(contactModalService);\r\n // // contactModalService.openContactDialog(state.params.contactId, ContactModalOrigin.ContactsList);\r\n // // }\r\n // }\r\n // },\r\n {\r\n name: 'manage.agents',\r\n url: '/agents',\r\n component: AgentsPageComponent\r\n },\r\n {\r\n name: 'agents',\r\n url: '/agents',\r\n component: AgentsPageComponent\r\n },\r\n {\r\n name: 'manage.propertyCharacteristics',\r\n url: '/property-characteristics',\r\n component: PropertyCharacteristicsComponent,\r\n data: {\r\n roles: [Roles.PROPCHARVIEW, Roles.PROPCHAREDIT]\r\n }\r\n },\r\n {\r\n name: 'propertyCharacteristics',\r\n url: '/property-characteristics',\r\n component: PropertyCharacteristicsComponent,\r\n data: {\r\n roles: [Roles.PROPCHARVIEW, Roles.PROPCHAREDIT]\r\n }\r\n },\r\n {\r\n name: 'manage.roles',\r\n url: '/roles',\r\n component: RolesListComponent,\r\n data: {\r\n roles: [Roles.CONTACTROLEVIEW]\r\n }\r\n },\r\n {\r\n name: 'roles',\r\n url: '/roles',\r\n component: RolesListComponent,\r\n data: {\r\n roles: [Roles.CONTACTROLEVIEW]\r\n }\r\n },\r\n {\r\n name: 'manage.userGroups',\r\n url: '/user-group',\r\n component: UserGroupListComponent,\r\n data: {\r\n instanceRights: [\r\n InstanceRights.MANAGEUSERSETUP\r\n ]\r\n }\r\n },\r\n {\r\n name: 'userGroupList',\r\n url: '/userGroup',\r\n component: UserGroupListComponent,\r\n data: {\r\n instanceRights: [InstanceRights.MANAGEUSERSETUP]\r\n }\r\n },\r\n {\r\n name: 'userGroupDetail',\r\n url: '/userGroup/:userGroupId',\r\n component: UserGroupDetailComponent,\r\n data: {\r\n instanceRights: [InstanceRights.MANAGEUSERSETUP]\r\n }\r\n },\r\n {\r\n name: 'manage.manageApiKeys',\r\n url: '/manage-API-keys',\r\n component: ManageAPIKeysComponent\r\n },\r\n {\r\n name: 'manage.manageInstanceSettings',\r\n url: '/instance',\r\n component: InstanceInfoPanelComponent,\r\n data: {\r\n instanceRights: [\r\n InstanceRights.MANAGECONSULTINGENGAGEMENT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'instanceInfo',\r\n url: '/instance',\r\n data: {\r\n instanceRights: [\r\n InstanceRights.MANAGECONSULTINGENGAGEMENT\r\n ]\r\n },\r\n component: InstanceInfoPanelComponent\r\n },\r\n {\r\n name: 'manage.teams',\r\n url: '/teams',\r\n component: TeamsPageComponent\r\n },\r\n {\r\n name: 'teams',\r\n url: '/teams',\r\n component: TeamsPageComponent\r\n },\r\n {\r\n name: 'manage.importAssessments',\r\n url: '/import/assessments',\r\n component: BulkImportAssessmentsComponent\r\n },\r\n {\r\n name: 'importAssessments',\r\n url: '/Assessment/Bulk-Import',\r\n component: BulkImportAssessmentsComponent\r\n },\r\n {\r\n name: 'manage.importSites',\r\n url: '/import/sites',\r\n component: BulkImportSitesComponent,\r\n resolve: [\r\n { token: 'type', resolveFn: () => ImportType.Site }\r\n ]\r\n },\r\n {\r\n name: 'importSites',\r\n url: '/Site/Bulk-Import',\r\n component: BulkImportSitesComponent,\r\n resolve: [\r\n { token: 'type', resolveFn: () => ImportType.Site }\r\n ]\r\n },\r\n {\r\n name: 'manage.importParcels',\r\n url: '/import/parcels',\r\n component: BulkImportSitesComponent,\r\n resolve: [\r\n { token: 'type', resolveFn: () => ImportType.Parcel }\r\n ]\r\n },\r\n {\r\n name: 'importParcels',\r\n url: '/Parcel/Bulk-Import',\r\n component: BulkImportSitesComponent,\r\n resolve: [\r\n { token: 'type', resolveFn: () => ImportType.Parcel }\r\n ]\r\n },\r\n {\r\n name: 'manage.factorTables',\r\n url: '/factor-tables',\r\n component: FactorTableListComponent,\r\n data: {\r\n roles: [\r\n Roles.COMPLIANCESETUPSVIEW,\r\n Roles.COMPLIANCESETUPSEDIT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'factorTableList',\r\n url: '/factortable',\r\n component: FactorTableListComponent,\r\n data: {\r\n roles: [\r\n Roles.COMPLIANCESETUPSVIEW,\r\n Roles.COMPLIANCESETUPSEDIT\r\n ]\r\n\r\n }\r\n },\r\n {\r\n name: 'manage.forms',\r\n url: '/forms',\r\n component: FormListComponent,\r\n data: {\r\n roles: [\r\n Roles.COMPLIANCESETUPSVIEW,\r\n Roles.COMPLIANCESETUPSEDIT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'formList',\r\n url: '/form',\r\n component: FormListComponent,\r\n data: {\r\n roles: [\r\n Roles.COMPLIANCESETUPSVIEW,\r\n Roles.COMPLIANCESETUPSEDIT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'manage.valuationTemplates',\r\n url: '/valuation-templates',\r\n component: ValuationTemplatesComponent,\r\n data: {\r\n instanceRights: [\r\n InstanceRights.VALUATIONTEMPLATEEDIT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'valuationTemplates',\r\n url: '/valuationTemplate',\r\n data: {\r\n instanceRights: [\r\n InstanceRights.VALUATIONTEMPLATEEDIT\r\n ]\r\n },\r\n component: ValuationTemplatesComponent\r\n },\r\n {\r\n name: 'manage.paymentBatchCommandCenter',\r\n url: '/payment-batch-command-center',\r\n component: PaymentBatchCommandCenterComponent,\r\n data: {\r\n roles: [Roles.RYANPRIVATEITEMSVIEW, Roles.RYANPRIVATEITEMSEDIT]\r\n }\r\n },\r\n {\r\n name: 'manage.appealRecommendationCommandCenter',\r\n url: '/appeal-recommendation-command-center',\r\n component: ARCCComponent\r\n },\r\n {\r\n name: 'appealRecommendationCommandCenter',\r\n url: '/appealRecommendationCommandCenter',\r\n data: {},\r\n component: ARCCComponent\r\n },\r\n {\r\n name: 'manage.taxRateCommandCenter',\r\n url: '/tax-rate-command-center',\r\n component: TaxRateCommandCenterComponent,\r\n data: {\r\n roles: [Roles.RYANPRIVATEITEMSVIEW, Roles.RYANPRIVATEITEMSEDIT]\r\n }\r\n },\r\n {\r\n name: 'taxRateCommandCenter',\r\n url: '/tax-rate-command-center',\r\n data: {\r\n roles: [Roles.RYANPRIVATEITEMSVIEW, Roles.RYANPRIVATEITEMSEDIT]\r\n },\r\n component: TaxRateCommandCenterComponent\r\n },\r\n {\r\n name: 'manage.stateJurisdictionCommandCenter',\r\n url: '/state-jurisdiction-command-center',\r\n component: StateJurisdictionCommandCenterComponent\r\n },\r\n {\r\n name: 'stateJurisdictionCommandCenter',\r\n url: '/state-jurisdiction-command-center',\r\n component: StateJurisdictionCommandCenterComponent\r\n },\r\n {\r\n name: 'manage.dataImports',\r\n url: '/import',\r\n component: EntityImportListComponent\r\n },\r\n {\r\n name: 'systemImports',\r\n url: '/import',\r\n component: EntityImportListComponent\r\n },\r\n {\r\n name: 'companyImports',\r\n url: '/import/company/:companyId',\r\n component: EntityImportListComponent\r\n },\r\n {\r\n name: 'manage.manageInstances',\r\n url: '/manage-instances',\r\n component: ManageInvitationsComponent\r\n },\r\n {\r\n name: 'invites',\r\n url: '/invites',\r\n component: ManageInvitationsComponent\r\n },\r\n {\r\n name: 'manage.manageSupportInstances',\r\n url: '/manage-support-instances',\r\n component: SupportInstanceListComponent\r\n },\r\n {\r\n name: 'supportInstanceList',\r\n url: '/supportInstanceList',\r\n component: SupportInstanceListComponent\r\n },\r\n {\r\n name: 'manage.manageConsultingEngagements',\r\n url: '/manage-consulting-engagements',\r\n component: ConsultingEngagementsComponent,\r\n data: {\r\n instanceRights: [\r\n InstanceRights.MANAGECONSULTINGENGAGEMENT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'consulting',\r\n url: '/consulting',\r\n data: {\r\n instanceRights: [\r\n InstanceRights.MANAGECONSULTINGENGAGEMENT\r\n ]\r\n },\r\n component: ConsultingEngagementsComponent\r\n },\r\n {\r\n name: 'manage.manageLicensedClientDocuments',\r\n url: '/manage-licensed-client-documents',\r\n component: DocumentIntakeLicensedClientListComponent\r\n },\r\n {\r\n name: 'documentIntakeLicensedClientList',\r\n url: '/documentIntakeLicensedClientList',\r\n component: DocumentIntakeLicensedClientListComponent\r\n },\r\n {\r\n name: 'manage.actionViewOutputFields',\r\n url: '/action-view-output-fields',\r\n component: ActionViewOutputDefaultsComponent\r\n },\r\n {\r\n name: 'taskviewoutputdefaults',\r\n url: '/action-view-output-fields',\r\n component: ActionViewOutputDefaultsComponent\r\n },\r\n {\r\n name: 'diagnostic',\r\n url: '/diagnostic',\r\n component: DiagnosticsComponent\r\n },\r\n {\r\n name: 'diagnostic.about',\r\n url: '/about',\r\n component: AboutComponent\r\n },\r\n {\r\n name: 'about',\r\n url: '/about',\r\n component: AboutComponent\r\n },\r\n {\r\n name: 'diagnostic.longRunningProcess',\r\n url: '/long-running-process',\r\n component: LongRunningProcessPageComponent\r\n },\r\n {\r\n name: 'longRunningProcess',\r\n url: '/long-running-process',\r\n component: LongRunningProcessPageComponent,\r\n data: {\r\n roles: [\r\n Roles.ADMINOPERATIONSVIEW,\r\n Roles.ADMINOPERATIONSEDIT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'diagnostic.errorLog',\r\n url: '/error-log',\r\n component: ErrorLogListComponent\r\n },\r\n {\r\n name: 'errorLog',\r\n url: '/error-log',\r\n component: ErrorLogListComponent,\r\n data: {\r\n roles: [\r\n Roles.ADMINOPERATIONSVIEW,\r\n Roles.ADMINOPERATIONSEDIT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'diagnostic.queryInfo',\r\n url: '/query-info',\r\n component: QueryInfoListComponent,\r\n data: {\r\n roles: [\r\n Roles.ADMINOPERATIONSVIEW,\r\n Roles.ADMINOPERATIONSEDIT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'diagnostic.attachmentDownload',\r\n url: '/attachment-download',\r\n component: AttachmentDownloadDiagnosticComponent,\r\n data: {\r\n roles: [\r\n Roles.ADMINOPERATIONSVIEW,\r\n Roles.ADMINOPERATIONSEDIT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'queryInfo',\r\n url: '/queryInfo',\r\n component: QueryInfoListComponent,\r\n data: {\r\n roles: [\r\n Roles.ADMINOPERATIONSVIEW,\r\n Roles.ADMINOPERATIONSEDIT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'diagnostic.database',\r\n url: '/database',\r\n component: ProcessListComponent\r\n },\r\n {\r\n name: 'database',\r\n url: '/database',\r\n component: ProcessListComponent\r\n },\r\n {\r\n name: 'company',\r\n url: '/company/:companyId',\r\n component: CompanyPageComponent\r\n },\r\n // {\r\n // name: 'company.site',\r\n // url: '/site/:siteId',\r\n // component: SitePageComponent,\r\n // resolve: []\r\n // },\r\n // {\r\n // name: 'company.site.parcel',\r\n // url: '/parcel/:parcelId',\r\n // component: ParcelPageComponent,\r\n // resolve: []\r\n // },\r\n // {\r\n // name: 'siteRedirect',\r\n // url: '/site/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.SITE\r\n // }\r\n // },\r\n // {\r\n // name: 'parcelRedirect',\r\n // url: '/parcel/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.PARCEL\r\n // }\r\n // },\r\n // {\r\n // name: 'assessmentRedirect',\r\n // url: '/assessment/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.ASSESSMENT\r\n // }\r\n // },\r\n // {\r\n // name: 'appealRedirect',\r\n // url: '/appeal/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.APPEAL\r\n // }\r\n // },\r\n // {\r\n // name: 'billClusterRedirect',\r\n // url: '/billcluster/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.BILL_CLUSTER\r\n // }\r\n // },\r\n // {\r\n // name: 'billRedirect',\r\n // url: '/bill/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.TAX_BILL\r\n // }\r\n // },\r\n // {\r\n // name: 'filingRedirect',\r\n // url: '/filing/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.FILING\r\n // }\r\n // },\r\n // {\r\n // name: 'paymentRedirect',\r\n // url: '/payment/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.PAYMENT\r\n // }\r\n // },\r\n // {\r\n // name: 'refundRedirect',\r\n // url: '/refund/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.REFUND\r\n // }\r\n // },\r\n // {\r\n // name: 'collectorRedirect',\r\n // url: '/collector/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.COLLECTOR\r\n // }\r\n // },\r\n // {\r\n // name: 'assessorRedirect',\r\n // url: '/assessor/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.ASSESSOR\r\n // }\r\n // },\r\n // {\r\n // name: 'invoiceRedirect',\r\n // url: '/invoice/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.INVOICE\r\n // }\r\n // },\r\n // {\r\n // name: 'filingBatchRedirect',\r\n // url: '/filingbatch/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.FilingBatch\r\n // }\r\n // },\r\n // {\r\n // name: 'filingBatchRedirect2',\r\n // url: '/filingBatch/:entityID',\r\n // component: RedirectComponent,\r\n // resolve: {\r\n // entityTypeID: () => EntityTypeIDs.FilingBatch\r\n // }\r\n // },\r\n {\r\n name: 'states',\r\n url: '/states',\r\n component: UnitedStatesComponent\r\n },\r\n {\r\n name: 'state',\r\n url: '/states/:stateId',\r\n component: USStateComponent\r\n },\r\n {\r\n name: 'assessors',\r\n url: '/states/:stateId/assessors',\r\n component: AssessorListComponent\r\n },\r\n {\r\n name: 'assessors.letter',\r\n url: '?:letter',\r\n component: AssessorListComponent\r\n },\r\n {\r\n name: 'assessor',\r\n url: '/states/:stateId/assessors/:id?:year',\r\n component: AssessorComponent\r\n },\r\n {\r\n name: 'collectors',\r\n url: '/states/:stateId/collectors',\r\n component: CollectorListComponent\r\n },\r\n {\r\n name: 'collectors.letter',\r\n url: '?:letter',\r\n component: CollectorListComponent\r\n },\r\n {\r\n name: 'companyCollectors',\r\n url: '/company/:companyID/collectors',\r\n component: CollectorListComponent\r\n },\r\n {\r\n name: 'companyCollectors.letter',\r\n url: '?:letter',\r\n component: CollectorListComponent\r\n },\r\n {\r\n name: 'companyCollector',\r\n url: '/company/:companyID/collector/:collectorID',\r\n component: CollectorComponent\r\n },\r\n {\r\n name: 'collector',\r\n url: '/states/:stateId/collectors/:stateCollectorId',\r\n component: CollectorComponent\r\n },\r\n {\r\n name: 'documentintake',\r\n url: '/documentintake',\r\n component: DocumentIntakeComponent,\r\n data: {\r\n instanceRights: [InstanceRights.PRIVATEITEMSEDIT]\r\n }\r\n },\r\n // {\r\n // name: 'documentProcessing',\r\n // url: '/processing/document?taskID?parcelID?intakeItemID',\r\n // component: DocumentProcessingComponent,\r\n // params: {\r\n // selectedRows: [],\r\n // searchTimestamp: null\r\n // }\r\n // },\r\n // {\r\n // name: 'attachmentPopup',\r\n // url: '/attachmentPopup',\r\n // component: AttachmentPopupComponent\r\n // },\r\n {\r\n name: 'reportmanager',\r\n url: '/reportmanager/:reportId?reportType',\r\n component: ReportManagerComponent\r\n },\r\n {\r\n name: 'paymentPackagesDraft',\r\n url: '/processing/paymentPackages/:draftID?paymentBatchId?taskId?isPrelimApFeed',\r\n component: PaymentPackagesComponent\r\n },\r\n {\r\n name: 'paymentPackageAttachmentSummary',\r\n url: '/processing/paymentPackages/attachmentSummary/:paymentPackageID',\r\n component: PaymentPackageAttachmentSummaryComponent\r\n },\r\n {\r\n name: 'paymentPackagesForCompany',\r\n url: '/processing/paymentPackages/company/:companyID',\r\n component: PaymentPackagesComponent\r\n },\r\n {\r\n name: 'paymentPackagesForPayment',\r\n url: '/processing/paymentPackages/payment/:paymentID',\r\n component: PaymentPackagesComponent\r\n },\r\n {\r\n name: 'paymentPackageDetail',\r\n url: '/processing/paymentPackages/company/:companyID/package/:paymentPackageID?paymentBatchId',\r\n component: PaymentPackagesComponent\r\n },\r\n {\r\n name: 'paymentPackageBatchDetail',\r\n url: '/processing/paymentPackages/company/:companyID/package/:paymentPackageID/paymentBatch/:paymentBatchId',\r\n component: PaymentPackagesComponent\r\n },\r\n {\r\n name: 'processInvoice',\r\n url: '/processing/invoice/:draftId',\r\n component: ProcessInvoiceComponent\r\n },\r\n {\r\n name: 'siteInvoice',\r\n url: '/company/:companyID/site/:siteID/invoice/:invoiceID',\r\n component: ProcessInvoiceComponent\r\n },\r\n {\r\n name: 'companyInvoice',\r\n url: '/company/:companyID/invoice/:invoiceID',\r\n component: ProcessInvoiceComponent\r\n },\r\n {\r\n name: 'companyVendorCodes',\r\n url: '/company/:companyId/vendor-codes',\r\n component: VendorCodeMappingComponent\r\n },\r\n {\r\n name: 'moveCompany',\r\n url: '/company/:companyID/move?isInactive',\r\n component: MoveCopyEntityComponent\r\n },\r\n {\r\n name: 'moveSite',\r\n url: '/company/:companyID/site/:siteID/move?isInactive',\r\n component: MoveCopyEntityComponent\r\n },\r\n {\r\n name: 'moveParcel',\r\n url: '/company/:companyID/site/:siteID/parcel/:parcelID/move?isInactive',\r\n component: MoveCopyEntityComponent\r\n },\r\n {\r\n name: 'copyCompany',\r\n url: '/company/:companyID/copy?isInactive',\r\n component: MoveCopyEntityComponent,\r\n resolve: [\r\n { token: 'isCopy', resolveFn: () => true }\r\n ]\r\n },\r\n {\r\n name: 'copySite',\r\n url: '/company/:companyID/site/:siteID/copy?isInactive',\r\n component: MoveCopyEntityComponent,\r\n resolve: [\r\n { token: 'isCopy', resolveFn: () => true }\r\n ]\r\n },\r\n {\r\n name: 'copyParcel',\r\n url: '/company/:companyID/site/:siteID/parcel/:parcelID/copy?isInactive',\r\n component: MoveCopyEntityComponent,\r\n resolve: [\r\n { token: 'isCopy', resolveFn: () => true }\r\n ]\r\n },\r\n {\r\n name: 'help',\r\n url: '/help',\r\n component: HelpComponent\r\n },\r\n {\r\n name: 'myDashboard',\r\n url: '/my-dashboard',\r\n component: DashboardComponent\r\n },\r\n {\r\n name: 'appealApplication',\r\n url: '/appeal/:appealId/appealApplication',\r\n component: AppealApplicationComponent\r\n },\r\n {\r\n name: 'appealApplicationBatch',\r\n url: '/appealApplicationBatch/:appealBatchId',\r\n component: AppealApplicationComponent\r\n },\r\n {\r\n name: 'processCompanyImport',\r\n url: '/import/company/:companyId/:importId',\r\n component: EntityImportProcessComponent\r\n },\r\n {\r\n name: 'processSystemImport',\r\n url: '/import/:importId',\r\n component: EntityImportProcessComponent\r\n },\r\n {\r\n name: 'assetList',\r\n url: '/asset/company/:companyId',\r\n component: AssetListComponent\r\n },\r\n {\r\n name: 'assetListSiteFilter',\r\n url: '/asset/company/:companyId/site/:siteId',\r\n component: AssetListComponent\r\n },\r\n {\r\n name: 'assetListParcelFilter',\r\n url: '/asset/company/:companyId/parcel/:parcelId',\r\n component: AssetListComponent\r\n },\r\n {\r\n name: 'formPage',\r\n url: '/form/:formRevisionId?taxYear',\r\n component: FormPageComponent,\r\n data: {\r\n roles: [\r\n Roles.COMPLIANCESETUPSVIEW,\r\n Roles.COMPLIANCESETUPSEDIT\r\n ]\r\n }\r\n },\r\n {\r\n name: 'glAccountList',\r\n url: '/glaccount/company/:companyId',\r\n component: GLAccountListComponent\r\n },\r\n {\r\n name: 'filingBatchList',\r\n url: '/filingbatch/company/:companyId',\r\n component: FilingBatchListComponent\r\n },\r\n {\r\n name: 'filingBatchDetails',\r\n url: '/filingbatch/company/:companyId/batch/:filingBatchId?',\r\n component: FilingBatchDetailsComponent\r\n },\r\n {\r\n name: 'returnFilingBatchPage',\r\n url: '/returnBatch/:filingBatchId',\r\n component: ReturnPageComponent\r\n },\r\n {\r\n name: 'supplementalInformationSheet',\r\n url: '/supplemental/company/:companyId',\r\n component: SupplementalInformationSheetComponent\r\n },\r\n {\r\n name: 'testdxp',\r\n url: '/testdxp',\r\n component: TestDXPPageComponent,\r\n data: {\r\n roles: [Roles.ADMINOPERATIONSEDIT]\r\n }\r\n },\r\n {\r\n name: 'taxRateArea',\r\n url: '/tax-rate-area/:taxRateAreaId?editMode',\r\n component: TaxRateAreaComponent,\r\n data: {\r\n roles: [Roles.ADMINOPERATIONSEDIT]\r\n }\r\n },\r\n {\r\n name: 'taxAuthority',\r\n url: '/tax-authority/:taxAuthorityId?editMode',\r\n component: TaxAuthorityComponent,\r\n data: {\r\n roles: [Roles.ADMINOPERATIONSEDIT]\r\n }\r\n },\r\n {\r\n name: 'importSpecificationList',\r\n url: '/importSpecifications',\r\n component: ImportSpecificationListComponent,\r\n data: {\r\n instanceRights: [\r\n InstanceRights.COMPANYDATAIMPORTSVIEW\r\n ]\r\n }\r\n },\r\n {\r\n name: 'companyImportSpecificationList',\r\n url: '/importSpecifications/company/:companyId',\r\n component: ImportSpecificationListComponent,\r\n data: {\r\n instanceRights: [\r\n InstanceRights.COMPANYDATAIMPORTSVIEW\r\n ]\r\n }\r\n },\r\n {\r\n name: 'paymentBatchCommandCenter',\r\n url: '/payment-batch-command-center',\r\n data: {\r\n roles: [Roles.RYANPRIVATEITEMSVIEW, Roles.RYANPRIVATEITEMSEDIT]\r\n },\r\n component: PaymentBatchCommandCenterComponent\r\n\r\n },\r\n {\r\n name: 'paymentBatchDetails',\r\n url: '/payment-batch-command-center/batch/:paymentBatchId',\r\n data: {\r\n roles: [Roles.RYANPRIVATEITEMSVIEW, Roles.RYANPRIVATEITEMSEDIT]\r\n },\r\n component: PaymentBatchDetailsComponent\r\n\r\n },\r\n {\r\n name: 'paymentBatchDetailsWithTabIndex',\r\n url: '/payment-batch-command-center/batch/:paymentBatchId/:tabIndex',\r\n data: {\r\n roles: [Roles.RYANPRIVATEITEMSVIEW, Roles.RYANPRIVATEITEMSEDIT]\r\n },\r\n component: PaymentBatchDetailsComponent\r\n\r\n },\r\n {\r\n name: 'forecastingBudgeting',\r\n url: '/company/:companyId/forecasting-budgeting',\r\n data: {\r\n instanceRights: [\r\n InstanceRights.PRIVATEITEMSEDIT,\r\n InstanceRights.PRIVATEITEMSVIEW\r\n ]\r\n },\r\n component: ForecastingBudgetingPageComponent\r\n },\r\n {\r\n name: 'accruals',\r\n url: '/company/:companyId/accruals',\r\n data: {\r\n instanceRights: [\r\n InstanceRights.PRIVATEITEMSEDIT,\r\n InstanceRights.PRIVATEITEMSVIEW\r\n ]\r\n },\r\n component: AccrualsPageComponent\r\n },\r\n {\r\n name: 'siteMap',\r\n url: '/site-map?siteId?companyId',\r\n component: SiteMapComponent\r\n },\r\n {\r\n name: 'allocationDetails',\r\n url: '/allocationDetails/:allocationId',\r\n component: AllocationDetailsComponent\r\n },\r\n {\r\n name: 'processAllocationImport',\r\n url: '/import/allocation/:allocationId/:importId',\r\n component: EntityImportProcessComponent\r\n },\r\n {\r\n name: 'companyIncomeStatement',\r\n url: '/incomeStatement/company/:companyId',\r\n component: IncomeStatementListComponent\r\n },\r\n {\r\n name: 'siteIncomeStatement',\r\n url: '/incomeStatement/company/:companyId/site/:siteId',\r\n component: IncomeStatementListComponent\r\n },\r\n {\r\n name: 'csrCommandCenter',\r\n url: '/csrcommandcenter/entity/:entityId/type/:entityTypeId',\r\n component: CsrCommandCenterComponent\r\n },\r\n {\r\n name: 'companyRentRoll',\r\n url: '/rentRoll/company/:companyId',\r\n component: RentRollListComponent\r\n },\r\n {\r\n name: 'siteRentRoll',\r\n url: '/rentRoll/company/:companyId/site/:siteId',\r\n component: RentRollListComponent\r\n },\r\n {\r\n name: 'valuationTemplateDetail',\r\n url: '/valuationTemplate/:templateId',\r\n data: {\r\n instanceRights: [\r\n InstanceRights.VALUATIONTEMPLATEEDIT\r\n ]\r\n },\r\n component: ValuationTemplateDetailComponent\r\n },\r\n {\r\n name: 'electronicFiling',\r\n url: '/company/:companyId/efile',\r\n component: ElectronicFilingComponent\r\n },\r\n {\r\n name: 'loginManager',\r\n url: '/loginManager/:userId',\r\n component: LoginManagerComponent\r\n },\r\n {\r\n name: 'responsibleEntityList',\r\n url: '/responsibleEntity/company/:companyId',\r\n component: ResponsibleEntityListComponent\r\n }\r\n];\r\n\r\n@NgModule({\r\n imports: [\r\n UIRouterModule.forChild({ states: STATES, config: config })\r\n ]\r\n})\r\nexport class Ng2RoutesModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../Routing/sd-http.service';\r\n\r\n\r\n@Injectable(\r\n { providedIn: 'root' }\r\n)\r\nexport class CoreLongRunningProcessService {\r\n constructor(private sdHttp: SDHttpService) {}\r\n\r\n cancel(longRunningProcessId: number): Promise {\r\n return this.sdHttp.put(`/api/longrunningprocess/${longRunningProcessId}/cancel`);\r\n }\r\n\r\n pause(longRunningProcessId: number): Promise {\r\n return this.sdHttp.put(`/api/longrunningprocess/${longRunningProcessId}/pause`);\r\n }\r\n\r\n resume(longRunningProcessId: number): Promise {\r\n return this.sdHttp.put(`/api/longrunningprocess/${longRunningProcessId}/resume`);\r\n }\r\n}\r\n","import { Inject } from '@angular/core';\r\nimport { UserSettingsService } from '../Account/userSettings.service';\r\n\r\nexport interface SearchCategory {\r\n name: string;\r\n children: SearchCategory[];\r\n}\r\n\r\n@Inject({ providedIn: 'root' })\r\nexport class SearchCategoriesService {\r\n constructor(private readonly _userSettingsService: UserSettingsService) {}\r\n\r\n get(): SearchCategory {\r\n const settings = this._userSettingsService.getAdvancedCriteriaSettings();\r\n\r\n const groupedSettings = settings.reduce((grouped, setting) => {\r\n if (!grouped[setting.folderName]) {\r\n grouped[setting.folderName] = [];\r\n }\r\n\r\n grouped[setting.folderName].push(setting);\r\n\r\n return grouped;\r\n }, {});\r\n\r\n const searchesChildren = Object.keys(groupedSettings).reduce((children, folder: string) => {\r\n const folderArr = folder.split('/');\r\n\r\n children = this._buildChildren(folderArr, children, groupedSettings[folder]);\r\n\r\n return children;\r\n }, []);\r\n\r\n return {\r\n name: 'tree-top',\r\n children: searchesChildren\r\n };\r\n }\r\n\r\n isLeaf(node: SearchCategory): boolean {\r\n return !node.children.length;\r\n }\r\n\r\n private _buildChildren(folderArr: string[], children: SearchCategory[], payload: SearchCategory[]): SearchCategory[] {\r\n if (folderArr.length === 0) {\r\n return [...children, ...payload];\r\n }\r\n\r\n const folder = folderArr[0];\r\n\r\n let folderIndex = children.findIndex(x => x.name === folder);\r\n\r\n if (folderIndex < 0) {\r\n folderIndex = children.push({\r\n name: folder,\r\n children: []\r\n }) - 1;\r\n }\r\n\r\n children[folderIndex].children = this._buildChildren(folderArr.slice(1), children[folderIndex].children, payload);\r\n\r\n return children;\r\n }\r\n}\r\n","import { Testability, NgZone } from '@angular/core';\r\nimport { AppealService } from '../Annual-Details/Appeals/appeal.service';\r\nimport { AnnualBudgetService } from '../Annual-Details/Budget/budget.details.service';\r\nimport { TaxRatesService } from '../Assessor-Collector/Tax-Rates/tax.rates.service';\r\nimport { CommentsService } from '../Comments/comments.service';\r\nimport { CommentsModalService } from '../Comments/commentsModal.service';\r\nimport {\r\n AddressDetailsModalLaunchService\r\n} from '../Common/Address/Address-View-Edit/address.details.modal.launch.service';\r\nimport { ColumnFilterService } from '../Common/AV-AS/Column-Filters/columnFilter.service';\r\nimport { CoreLongRunningProcessService } from '../Common/Long-Running-Process/core.long.running.process.service';\r\nimport { PopUpService } from '../Common/Popup/popup.service';\r\nimport { PubSubService } from '../Common/Popup/pubsub.service';\r\nimport { CacheManagerService } from '../Common/Routing/cache-manager.service';\r\nimport { WebsocketListenerService } from '../Compliance/websocketListener.service';\r\nimport { ContactsUpgradeService } from '../Contact/contacts.service.upgrade';\r\nimport { AppStateService } from '../Layout/appStateService';\r\nimport { NavigationService } from '../Layout/navigation.service';\r\nimport { ContactRoleService } from '../Role/contact.role.service';\r\nimport { QuickFiltersService } from '../Search/Quick/Criteria/quickFilters.service';\r\nimport { SearchService } from '../Search/search.service';\r\nimport { SearchCategoriesService } from '../Search/searchCategories.service';\r\nimport { SearchFiltersService } from '../Search/searchFilters.service';\r\nimport { SearchOperatorsService } from '../Search/searchOperators.service';\r\nimport { HybridAdapterUtility } from './hybrid-adapter.utility';\r\nimport { AnnualDetailsNavigationEventService } from '../Annual-Details/annual-details-event.service';\r\nimport { ReportManagerService } from '../Reporting/Manager/report.manager.service';\r\nimport { ReportingService } from '../Reporting/reporting.service';\r\nimport { TransmittalService } from '../Processing/Transmittal/transmittal.service';\r\nimport { LaunchEmailTemplateModalService } from '../Common/Custom-Email-Template/launch.email.template.modal.service';\r\nimport { ClientServicesExceptionModalService } from '../Client-Services/Exceptions/client-service-exception-modal.service';\r\nimport { ChangeHistoryModalLaunchService } from '../Common/Change-History/change-history-modal-launch.service';\r\nimport { CreateInvoiceModalLaunchService } from '../Common/Invoice/create-invoice-modal-launch.service';\r\nimport { ClientServiceResponsibilityService } from '../Client-Services/clientServiceResponsibility.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AccountService } from '../User/account.service';\r\nimport { AuthStorageService } from '../User/authStorage.service';\r\nimport { UserInstanceService } from '../User/userInstance.service';\r\nimport { FeatureFlagsService } from '../Common/FeatureFlags/feature-flags-service';\r\nimport { InstancePermissionService } from '../Permission/Instance/Instance.Permission.Service';\r\nimport { InstanceRepository } from '../Entity/Instance/instance.repository';\r\nimport { ConsultingEngagementsRepository } from '../Consulting/consultingEngagements.repository';\r\nimport { LoadPdfIframeService } from '../Common/PDFViewer/LoadPdfIframeService';\r\nimport { AdvancedSearchPersistenceService } from '../Search/Advanced/advancedSearchPersistence.service';\r\nimport { StateService } from '../Common/States/States.Service';\r\nimport { CurrentEntityService } from '../Common/Entity/CurrentEntityService';\r\nimport { UserService } from '../Account/user.service';\r\nimport { EntityPermissionService } from '../Common/Permissions/entityPermission.service';\r\nimport { RestrictService } from '../Common/Permissions/restrict.service';\r\nimport { UserSettingsService } from '../Account/userSettings.service';\r\nimport { ProductAnalyticsService } from '../Common/Amplitude/productAnalytics.service';\r\nimport { SiteClassService } from '../Entity/Site/siteClass.service';\r\nimport { Constants } from '../constants.new';\r\nimport { AceAuthOidcWrapperService } from '../IAM/aceAuthOidcWrapper.service';\r\n\r\nexport class NG1UpgradeProviders {\r\n constructor (private hybridAdapterUtility: HybridAdapterUtility) { }\r\n\r\n setupProviders(): void {\r\n this.hybridAdapterUtility.downgradeNg2Provider('annualDetailsNavigationEventService', AnnualDetailsNavigationEventService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('ReportManagerService', ReportManagerService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('reportingService', ReportingService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('TransmittalService', TransmittalService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('testability', Testability);\r\n this.hybridAdapterUtility.downgradeNg2Provider('ngZone', NgZone);\r\n this.hybridAdapterUtility.downgradeNg2Provider('launchEmailTemplateModalService', LaunchEmailTemplateModalService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('clientServicesExceptionModalService', ClientServicesExceptionModalService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('changeHistoryModalLaunchService', ChangeHistoryModalLaunchService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('createInvoiceModalLaunchService', CreateInvoiceModalLaunchService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('csrService', ClientServiceResponsibilityService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('toastr', ToastrService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('accountService', AccountService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('authStorageService', AuthStorageService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('userInstanceService', UserInstanceService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('featureFlagsService', FeatureFlagsService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('instancePermissionService', InstancePermissionService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('instanceRepository', InstanceRepository);\r\n this.hybridAdapterUtility.downgradeNg2Provider('consultingEngagementsRepository', ConsultingEngagementsRepository);\r\n this.hybridAdapterUtility.downgradeNg2Provider('loadPdfIframeService', LoadPdfIframeService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('advancedSearchPersistenceService', AdvancedSearchPersistenceService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('StatesService', StateService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('sd.Current.Entity.Service', CurrentEntityService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('sd.Account.User.Service', UserService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('EntityPermissionService', EntityPermissionService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('SD.Restrict.Service', RestrictService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('sd.Account.User.Settings.Service', UserSettingsService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('productAnalyticsService', ProductAnalyticsService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('sd.Site.Class.Service', SiteClassService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('websocketListenerService', WebsocketListenerService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('constants', Constants);\r\n this.hybridAdapterUtility.downgradeNg2Provider('taxRatesService', TaxRatesService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('popUpService', PopUpService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('pubSubService', PubSubService); // RXJS should be used instead of this\r\n this.hybridAdapterUtility.downgradeNg2Provider('annualBudgetService', AnnualBudgetService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('appealService', AppealService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('appStateService', AppStateService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('cacheManagerService', CacheManagerService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('addressDetailsModalLaunchService', AddressDetailsModalLaunchService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('coreLongRunningProcessService', CoreLongRunningProcessService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('roleService', ContactRoleService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('columnFilterService', ColumnFilterService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('featureFlagsService', FeatureFlagsService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('CommentsService', CommentsService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('CommentsModalService', CommentsModalService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('sd.Contacts.Service', ContactsUpgradeService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('aceAuthOidcWrapperService', AceAuthOidcWrapperService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('searchService', SearchService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('searchCategories', SearchCategoriesService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('searchFilters', SearchFiltersService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('searchOperators', SearchOperatorsService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('sd.Quick.Filters.Service', QuickFiltersService);\r\n this.hybridAdapterUtility.downgradeNg2Provider('sd.Navigation.Service', NavigationService);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { SDHttpService } from '../../../Common/Routing/sd-http.service';\r\nimport {ParcelActivitySummary} from './parcel-activity.model';\r\n\r\ndeclare const _: any;\r\n\r\nconst parcelActivityEndpoint: string = '/api/DeliverableTasks/Parcel/';\r\nconst siteActivityEndpoint: string = '/api/DeliverableTasks/Site/';\r\n\r\n@Injectable()\r\nexport class ParcelActivityService {\r\n constructor(private http: SDHttpService) {\r\n }\r\n\r\n getParcelActivity(parcelId: number): Promise {\r\n return this.http.get(parcelActivityEndpoint + parcelId).then((results: ParcelActivitySummary[]) => {\r\n for (let i = 0; i < results.length; i++) {\r\n results[i].deliverableDueDateHasTime = results[i].deliverableDueDate &&\r\n !(results[i].deliverableDueDate.getUTCHours() === 0 &&\r\n results[i].deliverableDueDate.getUTCMinutes() === 0 &&\r\n results[i].deliverableDueDate.getUTCSeconds() === 0 &&\r\n results[i].deliverableDueDate.getUTCMilliseconds() === 0);\r\n }\r\n return results;\r\n });\r\n }\r\n\r\n getParcelActivityForSite(siteId: number): Promise {\r\n return this.http.get(siteActivityEndpoint + siteId);\r\n }\r\n}\r\n","
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n \r\n {{activity.deliverableDueDate | weissmanDateFormat: true }}\r\n \r\n Pending\r\n \r\n
{{ activity.parcelAcctNum }}
\r\n
{{ activity.activityName }}
\r\n
{{ activity.entityText }}
\r\n
\r\n \r\n
\r\n Assigned:\r\n \r\n {{ activity.deliverableTaskAssignedUser.firstName }} {{activity.deliverableTaskAssignedUser.lastName}}\r\n \r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { ParcelActivitySummary } from './parcel-activity.model';\r\nimport { ParcelActivityService } from './parcel-activity.service';\r\nimport { TaskService } from '../../../Task/task.service.upgrade';\r\nimport { AnnualDetailsNavigationEventService, AppealNavigationInput, AssessmentNavigationInput, TaxNavigationInput, FilingNavigationInput } from '../../../Annual-Details/annual-details-event.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { Subscription } from 'rxjs';\r\nimport { ClientServiceResponsibilityService } from '../../../Client-Services/clientServiceResponsibility.service';\r\n\r\n@Component({\r\n selector: 'parcel-activity',\r\n templateUrl: './parcel-activity-summary.component.html'\r\n})\r\nexport class ParcelActivitySummaryComponent implements OnInit {\r\n constructor(\r\n private readonly _activityService: ParcelActivityService,\r\n private readonly _taskService: TaskService,\r\n private readonly _navigationEvent: AnnualDetailsNavigationEventService,\r\n private readonly _upgradeNavigationService: UpgradeNavigationServiceHandler,\r\n private readonly _clientServiceResponsibilityService: ClientServiceResponsibilityService) {\r\n }\r\n\r\n @Input() parcelId: number;\r\n @Input() siteId: number;\r\n @Input() showComplianceInfo: boolean = false;\r\n\r\n activitySummaryItems: ParcelActivitySummary[];\r\n isParcelLevel: boolean = true;\r\n dataLoading: boolean = true;\r\n refreshSubscription: Subscription;\r\n\r\n private _clientServicesChangeSubscription: Subscription;\r\n\r\n async ngOnInit(): Promise {\r\n if (this.siteId) {\r\n this.isParcelLevel = false;\r\n }\r\n\r\n await this.getActivityData();\r\n\r\n this._clientServicesChangeSubscription = this._clientServiceResponsibilityService.clientServicesChange$\r\n .subscribe(async () => {\r\n await this.getActivityData();\r\n });\r\n\r\n this.refreshSubscription = this._navigationEvent.refreshEvent$\r\n .subscribe(async () => {\r\n await this.getActivityData();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.refreshSubscription.unsubscribe();\r\n this._clientServicesChangeSubscription.unsubscribe();\r\n }\r\n\r\n canNavigate(activity: ParcelActivitySummary): boolean {\r\n if (activity && activity.entityTypeID === Core.EntityTypes.FilingBatch && !this.showComplianceInfo) {\r\n return false;\r\n }\r\n\r\n return true;\r\n }\r\n\r\n async getActivityData(): Promise {\r\n this.dataLoading = true;\r\n\r\n try {\r\n this.activitySummaryItems = this.isParcelLevel\r\n ? await this._activityService.getParcelActivity(this.parcelId)\r\n : await this._activityService.getParcelActivityForSite(this.siteId);\r\n } finally {\r\n this.dataLoading = false;\r\n }\r\n }\r\n\r\n launchTaskModal(event: any, entityId: number, entityTypeId: number): void {\r\n event.stopPropagation();\r\n this._taskService.launchTaskModal(entityId, entityTypeId, true);\r\n }\r\n\r\n navigateToEntity(activity: ParcelActivitySummary): void {\r\n if (!this.canNavigate(activity)) {\r\n return;\r\n }\r\n\r\n if (this.isParcelLevel) {\r\n switch (activity.entityTypeID) {\r\n case Core.EntityTypes.AnnualAssessment:\r\n this._navigationEvent.goToAssessment(new AssessmentNavigationInput(activity.annualYearID, activity.entityID));\r\n break;\r\n case Core.EntityTypes.Appeal:\r\n this._navigationEvent.goToAppeal(new AppealNavigationInput(activity.annualYearID, activity.parentEntityID, activity.entityID));\r\n break;\r\n case Core.EntityTypes.Payment:\r\n // For tax payments, entityID is the PaymentID and parentEntityID is the BillClusterID\r\n this._navigationEvent.goToTax(new TaxNavigationInput(activity.annualYearID, activity.parentEntityID));\r\n break;\r\n case Core.EntityTypes.Refund:\r\n this._navigationEvent.goToRefund(new TaxNavigationInput(activity.annualYearID, activity.entityID));\r\n break;\r\n case Core.EntityTypes.Filing:\r\n this._navigationEvent.goToFiling(new FilingNavigationInput(activity.annualYearID, activity.entityID));\r\n break;\r\n case Core.EntityTypes.FilingBatch:\r\n this._upgradeNavigationService.goToFilingBatch(activity.entityID);\r\n break;\r\n }\r\n } else {\r\n const siteId: number = parseInt(this._upgradeNavigationService.getQuerystringParam('siteId'));\r\n const companyId: number = parseInt(this._upgradeNavigationService.getQuerystringParam('companyId'));\r\n\r\n switch (activity.entityTypeID) {\r\n case Core.EntityTypes.AnnualAssessment:\r\n this._upgradeNavigationService.goToAnnualDetailsAssessment(companyId, siteId, activity.parcelID, activity.annualYearID, activity.entityID);\r\n break;\r\n case Core.EntityTypes.Appeal:\r\n this._upgradeNavigationService.goToAnnualDetailsAppeal(companyId, siteId, activity.parcelID, activity.annualYearID, activity.parentEntityID, activity.entityID);\r\n break;\r\n case Core.EntityTypes.Payment:\r\n // For tax payments, entityID is the PaymentID and parentEntityID is the BillClusterID\r\n this._upgradeNavigationService.goToAnnualDetailsTax(companyId, siteId, activity.parcelID, activity.annualYearID, activity.parentEntityID);\r\n break;\r\n case Core.EntityTypes.Refund:\r\n this._upgradeNavigationService.goToAnnualDetailsRefund(companyId, siteId, activity.parcelID, activity.annualYearID, activity.entityID);\r\n break;\r\n case Core.EntityTypes.Filing:\r\n this._upgradeNavigationService.goToAnnualDetailsFiling(companyId, siteId, activity.parcelID, activity.annualYearID, activity.entityID);\r\n break;\r\n case Core.EntityTypes.FilingBatch:\r\n this._upgradeNavigationService.goToFilingBatch(activity.entityID);\r\n break;\r\n case Core.EntityTypes.Invoice:\r\n this._upgradeNavigationService.go('siteInvoice', { companyID: companyId, siteID: siteId, invoiceID: activity.parentEntityID }, true);\r\n break;\r\n }\r\n }\r\n }\r\n\r\n getTaskIcon(taskSeriesTypeId: number): string {\r\n switch (taskSeriesTypeId) {\r\n case Core.TaskSeriesTypes.PPReturn:\r\n return 'fa fa-file-text-o';\r\n case Core.TaskSeriesTypes.AsmtAppealReview:\r\n return 'fa fa-clipboard';\r\n case Core.TaskSeriesTypes.AppealPursuit:\r\n return 'fa fa-gavel';\r\n case Core.TaskSeriesTypes.Refund:\r\n return 'fa fa-money';\r\n case Core.TaskSeriesTypes.TaxPayment:\r\n return 'fa fa-dollar dollar-icon-fix';\r\n case Core.TaskSeriesTypes.DocumentIntake:\r\n return 'fa fa-file-o';\r\n case Core.TaskSeriesTypes.MiscFiling:\r\n case Core.TaskSeriesTypes.FreeportFiling:\r\n case Core.TaskSeriesTypes.AbatementFiling:\r\n case Core.TaskSeriesTypes.PollutionControlFiling:\r\n return 'fa fa-file-text-o';\r\n case Core.TaskSeriesTypes.ClientInvoice:\r\n return 'fa fa-money';\r\n default:\r\n return 'fa fa-info info-icon-fix';\r\n }\r\n }\r\n\r\n getTaskIconColor(taskSeriesTypeId: number): string {\r\n const className = 'icon-badge';\r\n switch (taskSeriesTypeId) {\r\n case Core.TaskSeriesTypes.PPReturn:\r\n return `${className } blue-badge`;\r\n case Core.TaskSeriesTypes.AsmtAppealReview:\r\n return `${className } red-badge`;\r\n case Core.TaskSeriesTypes.AppealPursuit:\r\n return `${className } gold-badge`;\r\n case Core.TaskSeriesTypes.Refund:\r\n return `${className } green-badge`;\r\n case Core.TaskSeriesTypes.TaxPayment:\r\n return `${className } green-badge`;\r\n case Core.TaskSeriesTypes.DocumentIntake:\r\n return `${className } gold-badge`;\r\n default:\r\n return `${className } blue-badge`;\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n

Sites reported by this parcel:

\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy, Input, Output, EventEmitter } from '@angular/core';\r\nimport { ColDef, GridApi, GridReadyEvent, GridOptions, RowNode } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder } from '../../AgGrid/agGridOptionsBuilder';\r\nimport { AgGridFilterParams } from '../../AgGrid/agGridFilterParams';\r\nimport { AgGridColumns } from '../../AgGrid/agGridColumns';\r\nimport { ReportingParcelRepository } from '../../Repositories/reportingParcel.repository';\r\nimport { AgGridLinkCellRendererComponent } from '../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AgGridLinkCellRendererParams } from '../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport * as _ from 'lodash';\r\nimport { IComponentRef } from '../../Return/Models/iComponentRef';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\nexport interface ReportingParcelSiteRowModel extends Compliance.ReportingParcelSiteModel {\r\n added: boolean;\r\n deleted: boolean;\r\n changed: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'reporting-parcel-site-list',\r\n templateUrl: './reportingParcelSiteList.component.html'\r\n})\r\nexport class ReportingParcelSiteListComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _reportingParcelRepository: ReportingParcelRepository) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _sites: ReportingParcelSiteRowModel[] = [];\r\n private _originalSites: Compliance.ReportingParcelSiteModel[] = [];\r\n private _originalParentSite: Compliance.ReportingParcelSiteModel;\r\n\r\n @Input() siteId: number;\r\n @Input() parcelId: number;\r\n\r\n @Output() changed: EventEmitter = new EventEmitter();\r\n @Output() onInitialized: EventEmitter = new EventEmitter();\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'grid-row-deleted': params => params.data && params.data.deleted\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .build();\r\n\r\n allowEdit: boolean = true;\r\n editMode: boolean = false;\r\n addedSiteIds: number[] = [];\r\n\r\n get deletedSiteIds(): number[] {\r\n return _.map(_.filter(this._sites, x => x.deleted), x => x.siteId);\r\n }\r\n\r\n parentSite: ReportingParcelSiteRowModel;\r\n\r\n get showSiteList(): boolean {\r\n var parentSiteInList = _.find(this._sites, (x: Compliance.ReportingParcelSiteModel) => x.siteId === this.parentSite.siteId);\r\n var minLength = parentSiteInList ? 1 : 0;\r\n \r\n return this._sites.length > minLength;\r\n }\r\n\r\n get hasReportingParcel(): boolean {\r\n return this.parentSite && this.parentSite.reportingParcelId ? true : false;\r\n }\r\n\r\n get isReportingParcelForParentSite(): boolean {\r\n return this.parentSite && (!this.parentSite.deleted) && this.parentSite.reportingParcelId === this.parcelId;\r\n }\r\n set isReportingParcelForParentSite(isReportingParcel: boolean) {\r\n if (!this.parentSite) {\r\n return;\r\n }\r\n\r\n if (isReportingParcel) {\r\n this.parentSite.reportingParcelId = this.parcelId;\r\n this.parentSite.changed = true;\r\n } else {\r\n this.parentSite.deleted = true;\r\n }\r\n\r\n this.changed.emit(this.hasChanges);\r\n }\r\n\r\n get isPartOfAMasterSite(): boolean {\r\n return this.parentSite.isSiteLinked;\r\n }\r\n\r\n get isAnotherParcelReportingForParentSite(): boolean {\r\n return this.parentSite && this.parentSite.reportingParcelId && this.parentSite.reportingParcelId !== this.parcelId;\r\n }\r\n\r\n get hasChanges(): boolean {\r\n if (this.parentSite && (this.parentSite.changed || this.parentSite.deleted)) {\r\n return true;\r\n }\r\n\r\n if (this.addedSiteIds.length) {\r\n return true;\r\n }\r\n\r\n let hasChanges: boolean = false;\r\n\r\n if (this._gridApi) {\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const site = node.data as ReportingParcelSiteRowModel;\r\n if (site && (site.added || site.deleted || site.changed)) {\r\n hasChanges = true;\r\n }\r\n });\r\n }\r\n\r\n return hasChanges;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n await this._load();\r\n\r\n const ref: IComponentRef = {\r\n save: this.save.bind(this),\r\n cancel: this.cancel.bind(this),\r\n edit: this.edit.bind(this),\r\n getSaveModel: this.getSaveModel.bind(this),\r\n load: this._load.bind(this),\r\n isDisabled: () => false\r\n };\r\n\r\n this.onInitialized.emit(ref);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Site Name',\r\n field: 'name',\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const site = params.data as Compliance.ReportingParcelSiteModel;\r\n if (!site) {\r\n return '';\r\n }\r\n return `#/site/${site.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n valueFormatter: (params) => {\r\n const site = params.data as Compliance.ReportingParcelSiteModel;\r\n if (!site) {\r\n return '';\r\n }\r\n\r\n return `${site.name}${(site.siteId === this.siteId) ? ' (this site)' : ''}`;\r\n },\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'property',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'siteName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setRowData();\r\n }\r\n\r\n async refresh(): Promise {\r\n await this._load();\r\n }\r\n\r\n async save(): Promise {\r\n const updates = this.getSaveModel();\r\n\r\n await lastValueFrom(this._reportingParcelRepository.updateSites(this.parcelId, updates));\r\n\r\n await this._loadSites();\r\n\r\n this.addedSiteIds = [];\r\n\r\n this.editMode = false;\r\n }\r\n\r\n private getSaveModel(): Compliance.ReportingParcelSiteUpdateModel[]{\r\n const updates: Compliance.ReportingParcelSiteUpdateModel[] = [];\r\n\r\n // add parent site\r\n if (this.parentSite.changed || this.parentSite.deleted) {\r\n updates.push(this._getSiteUpdateModel(this.parentSite));\r\n }\r\n\r\n // add added sites\r\n _.forEach(this.addedSiteIds,\r\n x => {\r\n updates.push({\r\n siteId: x,\r\n reportingParcelId: this.parcelId\r\n } as Compliance.ReportingParcelSiteUpdateModel);\r\n });\r\n\r\n if (this._gridApi) {\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const site = node.data as ReportingParcelSiteRowModel;\r\n if (site && (site.added || site.deleted || site.changed)) {\r\n updates.push(this._getSiteUpdateModel(site));\r\n }\r\n });\r\n }\r\n return updates;\r\n }\r\n\r\n edit(): void {\r\n this.editMode = true;\r\n }\r\n\r\n cancel(): void {\r\n this._setSites(this._originalSites);\r\n this._setParentSite(this._originalParentSite);\r\n this.addedSiteIds = [];\r\n this.editMode = false;\r\n }\r\n\r\n private async _load(): Promise {\r\n await this._loadSites();\r\n }\r\n\r\n private async _loadSites(): Promise {\r\n // get information about the parcel's parent site\r\n const parcelSite: Compliance.ReportingParcelSiteModel = await lastValueFrom(this._reportingParcelRepository.getSiteByParcel(this.parcelId));\r\n this._setParentSite(parcelSite);\r\n\r\n // get the sites that are using this parcel as a reporting parcel\r\n const searchParams = {\r\n parcelId: this.parcelId\r\n } as Compliance.ReportingParcelSiteSearchModel;\r\n\r\n const sites = (await lastValueFrom>(this._reportingParcelRepository.getSitesByReportingParcel(searchParams))).data;\r\n\r\n this._setSites(sites);\r\n }\r\n\r\n private _setParentSite(site: Compliance.ReportingParcelSiteModel): void {\r\n this._originalParentSite = site;\r\n\r\n this.parentSite = this._getSiteRowModel(this._originalParentSite);\r\n }\r\n\r\n private _setSites(sites: Compliance.ReportingParcelSiteModel[]): void {\r\n this._originalSites = sites;\r\n\r\n this._sites = _.map(sites, (x: Compliance.ReportingParcelSiteModel) => this._getSiteRowModel(x));\r\n\r\n this._setRowData();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._sites);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getSiteRowModel(siteModel: Compliance.ReportingParcelSiteModel): ReportingParcelSiteRowModel {\r\n return {\r\n\r\n added: false,\r\n deleted: false,\r\n changed: false,\r\n ...siteModel\r\n } as ReportingParcelSiteRowModel;\r\n }\r\n\r\n private _getSiteUpdateModel(siteRowModel: ReportingParcelSiteRowModel): Compliance.ReportingParcelSiteUpdateModel {\r\n return {\r\n reportingParcelId: siteRowModel.deleted ? null : siteRowModel.reportingParcelId,\r\n siteId: siteRowModel.siteId\r\n } as Compliance.ReportingParcelSiteUpdateModel;\r\n }\r\n}\r\n","
\r\n
\r\n \r\n

Return Settings

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n

Return Settings

\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n
\r\n

Reporting Parcel Sites

\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { IComponentRef } from '../../Return/Models/iComponentRef';\r\nimport { ComplianceInfoRepository } from '../../Repositories/complianceInfo.repository';\r\nimport { ReturnSettingsEntityTypeEnum } from '../../Return/Models/enums';\r\n\r\n@Component({\r\n selector: 'compliance-info-panel',\r\n templateUrl: './complianceInfoPanel.component.html'\r\n})\r\nexport class ComplianceInfoPanelComponent {\r\n constructor(private readonly _complianceInfoRepository: ComplianceInfoRepository) {\r\n }\r\n\r\n private _returnSettingsComponent: IComponentRef;\r\n private _reportingParcelSitesComponent: IComponentRef;\r\n\r\n @Input() siteId: number;\r\n @Input() parcelId: number;\r\n @Input() allowEdit: boolean;\r\n\r\n ReturnSettingsEntityTypeEnum: typeof ReturnSettingsEntityTypeEnum = ReturnSettingsEntityTypeEnum;\r\n hasChanges: boolean;\r\n\r\n isShowInfo: boolean = false;\r\n editMode: boolean = false;\r\n loading: boolean = true;\r\n\r\n expandOrCollapse(): void {\r\n if(this.editMode) {\r\n return;\r\n }\r\n\r\n this.isShowInfo = !this.isShowInfo;\r\n\r\n if(this.isShowInfo) {\r\n this.showInfo();\r\n }\r\n }\r\n\r\n showInfo(): void {\r\n this.loading = true;\r\n }\r\n\r\n async save(): Promise {\r\n try{\r\n this.loading = true;\r\n\r\n const saveModel: Compliance.ComplianceInfoGeneralReturnSettingsReportingSitesSaveModel = {\r\n returnSettings: this._returnSettingsComponent.getSaveModel(),\r\n sites: this._reportingParcelSitesComponent.getSaveModel()\r\n } as Compliance.ComplianceInfoGeneralReturnSettingsReportingSitesSaveModel;\r\n\r\n await lastValueFrom(this._complianceInfoRepository.saveByParcel(this.parcelId, saveModel));\r\n\r\n this._returnSettingsComponent.cancel();\r\n this._reportingParcelSitesComponent.cancel();\r\n\r\n const promises: Promise[] = [\r\n this._returnSettingsComponent.load(),\r\n this._reportingParcelSitesComponent.load()\r\n ];\r\n await Promise.all(promises);\r\n\r\n this.editMode = false;\r\n this.hasChanges = false;\r\n\r\n } finally{\r\n this.loading = false;\r\n }\r\n }\r\n\r\n setEditMode(): void {\r\n this.editMode = true;\r\n this._returnSettingsComponent.edit();\r\n this._reportingParcelSitesComponent.edit();\r\n }\r\n\r\n cancelEdit(): void {\r\n this._returnSettingsComponent.cancel();\r\n this._reportingParcelSitesComponent.cancel();\r\n this.editMode = false;\r\n }\r\n\r\n onReturnSettingsInitialized($ref: IComponentRef) {\r\n this._returnSettingsComponent = $ref;\r\n console.log(this._returnSettingsComponent)\r\n this.loading = !(this._returnSettingsComponent && this._reportingParcelSitesComponent);\r\n }\r\n\r\n onReturnSettingsChanged(value: boolean){\r\n this.hasChanges = value;\r\n }\r\n\r\n onReportingParcelSitesInitialized($ref: IComponentRef) {\r\n this._reportingParcelSitesComponent = $ref;\r\n console.log(this._reportingParcelSitesComponent)\r\n this.loading = !(this._returnSettingsComponent && this._reportingParcelSitesComponent);\r\n }\r\n\r\n onReportingParcelSitesChanged(value: boolean){\r\n this.hasChanges = value;\r\n }\r\n}\r\n","
\r\n
\r\n \r\n
\r\n
\r\n
\r\n

Tax Rate First Encounter

\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n

\r\n You are entering the actual {{taxAuthority.taxYear}} tax rate for tax authority\r\n {{taxAuthorityDisplayName}}.\r\n Please double check the accuracy of the entry before clicking Save. The rate's status will be changed from\r\n Estimated to Pending QC, the bill for this parcel will be attached as evidence, and all auto-calculated tax\r\n bills system-wide utilizing this rate will be re-estimated.\r\n

\r\n

\r\n WARNING: There are pending changes on this bill made since this document was associated, and the bill will\r\n be affected by entering a tax rate for this tax authority. If you continue, all pending changes will be\r\n reverted automatically once you click Save. Please ensure this is OK before continuing.\r\n

\r\n
\r\n
\r\n
\r\n\r\n","import { Component, OnInit, Output, EventEmitter, Input, ElementRef, ViewChild } from '@angular/core';\r\nimport { TaxAuthorityRateDetails, ParcelTaxRateService, FirstEncounterSaveResult } from './parcelTaxRateService';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { MessageBoxService, MessageBoxResult, MessageBoxButtons } from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { TimerService } from '../../../UI-Lib/Utilities/timer.service';\r\n\r\n@Component({\r\n templateUrl: './firstEncounter.component.html',\r\n selector: 'first-encounter'\r\n})\r\nexport class FirstEncounterComponent implements OnInit {\r\n constructor(\r\n private readonly _parcelTaxRateSevice: ParcelTaxRateService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _msgBox: MessageBoxService,\r\n private readonly _timer: TimerService\r\n ) { }\r\n\r\n @Output() hidden = new EventEmitter();\r\n @Output() saved = new EventEmitter();\r\n @Input() billId: number;\r\n @Input() taxAuthority: TaxAuthorityRateDetails;\r\n @Input() intakeAttachmentId: string;\r\n @Input() hasProcessingChanges: boolean;\r\n @ViewChild('rateInput') rateInputRef: ElementRef;\r\n model: Core.FirstEncounterDTO;\r\n taxAuthorityDisplayName: string;\r\n displayRate: number;\r\n twoYearsAgoDisplayRate: number;\r\n lastYearDisplayRate: number;\r\n rateIncrease: number;\r\n lastYearDisplayRateIncrease: number;\r\n loading: boolean;\r\n displayAs: 'rate' | 'mills' = 'rate';\r\n\r\n async ngOnInit() {\r\n this.loading = true;\r\n try {\r\n this.model = await this._parcelTaxRateSevice.getFirstEncounterData(this.taxAuthority.taxAuthorityId, this.taxAuthority.taxYear);\r\n this.rateIncrease = this.model.rateIncrease ? (this.model.rateIncrease * 100) : null;\r\n this.lastYearDisplayRateIncrease = this.model.lastYearRateIncrease ? (this.model.lastYearRateIncrease * 100) : null;\r\n this.onModelChange();\r\n }\r\n finally {\r\n this.loading = false;\r\n this._timer.setTimeout(() => {\r\n this.rateInputRef.nativeElement.focus();\r\n });\r\n }\r\n }\r\n\r\n hide() {\r\n this.hidden.emit();\r\n }\r\n\r\n onModelChange() {\r\n this.taxAuthorityDisplayName = this.model.taxAuthorityName || '';\r\n if (this.model.taxAuthorityCode) {\r\n this.taxAuthorityDisplayName += ` ${ this.model.taxAuthorityCode}`;\r\n }\r\n\r\n const factor = this.displayAs === 'mills' ? 1000 : 100;\r\n this.twoYearsAgoDisplayRate = this.model.twoYearsAgoRate * factor;\r\n this.lastYearDisplayRate = this.model.lastYearRate * factor;\r\n this.displayRate = this.model.rate === null ? null : (this.model.rate * factor);\r\n }\r\n\r\n onRateChange($event: string) {\r\n if (isNaN(parseFloat($event))) {\r\n this.model.rate = null;\r\n this.rateIncrease = null;\r\n }\r\n else {\r\n const factor = this.displayAs === 'mills' ? 1000 : 100;\r\n this.model.rate = (+$event) / factor;\r\n this.rateIncrease = this.model.lastYearRate ? (((this.model.rate - this.model.lastYearRate) / this.model.lastYearRate) * 100) : null;\r\n }\r\n }\r\n\r\n async save() {\r\n // Check for falseyness, but allow 0 (probably null is all this will ever be, but if it's false or undefined or something don't continue)\r\n if (!this.model.rate && this.model.rate !== 0) {\r\n this._toastr.warning(`Please select a valid rate for ${ this.taxAuthority.taxYear}`);\r\n return;\r\n }\r\n\r\n if (await this._msgBox.open({\r\n buttons: MessageBoxButtons.YesNo,\r\n message: 'Are you sure you want to set this bill as the first encountered rate for this tax authority?',\r\n title: 'Confirm First Encounter'\r\n }) === MessageBoxResult.Yes) {\r\n this.loading = true;\r\n try {\r\n const result = await this._parcelTaxRateSevice.saveFirstEncounterData(\r\n this.taxAuthority.taxAuthorityId,\r\n this.taxAuthority.taxYear, {\r\n rate: this.model.rate,\r\n attachmentId: this.intakeAttachmentId,\r\n trackBillId: this.billId\r\n }\r\n );\r\n\r\n this._toastr.success('Tax rate saved');\r\n this.saved.emit(result);\r\n }\r\n finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { ComplianceInfoPanelComponent } from './Compliance-Info-Panel/complianceInfoPanel.component';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { ReportingParcelSiteListComponent } from './Reporting-Parcel-Site-List/reportingParcelSiteList.component';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { ReturnModule } from '../Return/return.module';\r\nimport { ParcelSelectorComponent } from './Reporting-Parcel-Selector/parcelSelector.component';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { ModalModule } from 'ngx-bootstrap/modal';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { TaxRateSetupModalLaunchService } from '../../Entity/Parcel/TaxRateSetup/taxRateSetupModalLaunchService';\r\nimport { ParcelCollectorTaxRateSetupModalComponent } from '../../Entity/Parcel/TaxRateSetup/parcelCollectorTaxRateSetupModal.component';\r\nimport { BillClusterTaxRateSetupModalComponent } from '../../Entity/Parcel/TaxRateSetup/billClusterTaxRateSetupModal.component';\r\nimport { FirstEncounterComponent } from '../../Entity/Parcel/TaxRateSetup/firstEncounter.component';\r\nimport { ParcelTaxRateService } from '../../Entity/Parcel/TaxRateSetup/parcelTaxRateService';\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n CommonModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent\r\n ]),\r\n ReturnModule,\r\n BsDropdownModule,\r\n ModalModule,\r\n TypeaheadModule,\r\n TooltipModule\r\n ],\r\n declarations: [\r\n ComplianceInfoPanelComponent,\r\n ReportingParcelSiteListComponent,\r\n ParcelSelectorComponent,\r\n ParcelCollectorTaxRateSetupModalComponent,\r\n BillClusterTaxRateSetupModalComponent,\r\n FirstEncounterComponent\r\n ],\r\n providers: [\r\n TaxRateSetupModalLaunchService,\r\n ParcelTaxRateService\r\n ],\r\n exports: [\r\n ComplianceInfoPanelComponent,\r\n ReportingParcelSiteListComponent,\r\n ParcelSelectorComponent\r\n ]\r\n})\r\nexport class ComplianceParcelModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('complianceInfoPanel', ComplianceInfoPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Component('reportingParcelSiteList', ReportingParcelSiteListComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('taxRateSetupModalLaunchService', TaxRateSetupModalLaunchService);\r\n hybridAdapterUtility.downgradeNg2Provider('parcelTaxRateService', ParcelTaxRateService);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForLinkedParcelsListGridAction extends ICellRendererParams {\r\n canRemove: (params: ICellRendererParamsForLinkedParcelsListGridAction) => boolean;\r\n remove: (params: ICellRendererParamsForLinkedParcelsListGridAction) => void;\r\n toggleMaster: (params: ICellRendererParamsForLinkedParcelsListGridAction) => void;\r\n getMasterTitle: (params: ICellRendererParamsForLinkedParcelsListGridAction) => string;\r\n canToggleMaster: (params: ICellRendererParamsForLinkedParcelsListGridAction) => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n \r\n \r\n `\r\n})\r\nexport class LinkedParcelsListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForLinkedParcelsListGridAction;\r\n\r\n agInit(params: ICellRendererParamsForLinkedParcelsListGridAction): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport { AgGridMultiSelectTracker, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectedCellRenderer } from '../../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { Subscription } from 'rxjs';\r\nimport { GridApi, GridReadyEvent, ColDef, GridOptions } from 'ag-grid-community';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../../../Compliance/AgGrid';\r\nimport { ParcelTypeCellRendererComponent, ParcelTypeCellRendererComponentParams } from '../../Parcel-Type-Cell-Renderer/parcelTypeCellRenderer.component';\r\n\r\nexport interface LinkedParcelAddParams {\r\n parcels: Core.LinkedParcelDTO[];\r\n allParcels: Core.LinkedParcelDTO[];\r\n parcelId: number;\r\n}\r\n\r\ninterface LinkedParcelModelSelectable extends Core.LinkedParcelDTO {\r\n isSelected: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'linked-parcels-add',\r\n templateUrl: './linkedParcelsAdd.component.html',\r\n styleUrls: ['./linkedParcelsAdd.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class LinkedParcelsAddComponent implements OnInit, OnDestroy {\r\n constructor(\r\n public readonly _bsModalRef: BsModalRef) {\r\n }\r\n\r\n params: LinkedParcelAddParams;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this._gridTracker.isRowSelected((params.data as Core.LinkedParcelDTO).parcelId)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n rowsSelected: boolean = false;\r\n result: Core.LinkedParcelDTO[] = [];\r\n\r\n private _gridApi: GridApi;\r\n private _gridTracker: AgGridMultiSelectTracker;\r\n private _selectedRowsSub: Subscription;\r\n private _availableParcels: Core.LinkedParcelDTO[];\r\n\r\n ngOnInit(): void {\r\n // remove any parcels in available already selected\r\n const result = _.filter(this.params.allParcels, (as: Core.LinkedParcelDTO) => !_.some(this.params.parcels, (s: Core.LinkedParcelDTO) => { return as.parcelId === s.parcelId; }));\r\n\r\n this._availableParcels = _.map(result, (s) => { return { ...s, isSelected: false } as LinkedParcelModelSelectable; });\r\n\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this._selectedRowsSub = this._gridTracker.selectedRows$.subscribe(x => {\r\n this.rowsSelected = x.selectAllRows || x.selectedRows.length > 0;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'parcelId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this._gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this._gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'propertyTypeAbbr',\r\n width: AgGridColumns.textColumnExtraSmallWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: ParcelTypeCellRendererComponent,\r\n cellRendererParams: {\r\n getParcelType: this._getParcelType.bind(this),\r\n isLinkedParcel: this._isLinkedParcel.bind(this),\r\n isMasterParcel: this._isMasterParcel.bind(this)\r\n } as ParcelTypeCellRendererComponentParams\r\n },\r\n {\r\n headerName: 'Parcel',\r\n field: 'acctNum',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n const rowIds = await this._gridTracker.getSelectedRowIds();\r\n this.result = this.params.allParcels.filter((x) => rowIds.some((y) => x.parcelId === y));\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _getParcelType(params: ParcelTypeCellRendererComponentParams): string {\r\n const parcel = params.data as Core.LinkedParcelDTO;\r\n if (!parcel) {\r\n return null;\r\n }\r\n\r\n return parcel.propertyTypeAbbr;\r\n }\r\n\r\n private _isLinkedParcel(params: ParcelTypeCellRendererComponentParams): boolean {\r\n const parcel = params.data as Core.LinkedParcelDTO;\r\n if (!parcel) {\r\n return false;\r\n }\r\n return parcel.linked;\r\n }\r\n\r\n private _isMasterParcel(params: ParcelTypeCellRendererComponentParams): boolean {\r\n const parcel = params.data as Core.LinkedParcelDTO;\r\n if (!parcel) {\r\n return false;\r\n }\r\n return parcel.masterParcel;\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._availableParcels)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._availableParcels);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map((x) => {\r\n const parcel = x.data as LinkedParcelModelSelectable;\r\n return parcel && parcel.parcelId;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface LinkedParcelsListGridNameCellRendererParams extends ICellRendererParams {\r\n getName: (params: LinkedParcelsListGridNameCellRendererParams) => string;\r\n getLink: (params: LinkedParcelsListGridNameCellRendererParams) => string;\r\n isMaster: (params: LinkedParcelsListGridNameCellRendererParams) => boolean;\r\n canNavigate: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'linked-parcels-list-grid-name-cell',\r\n template: `\r\n \r\n \r\n \r\n \r\n {{ params.getName(params) }}\r\n \r\n \r\n {{ params.getName(params) }}\r\n \r\n `\r\n})\r\nexport class LinkedParcelsListGridNameCellRendererComponent implements ICellRendererAngularComp {\r\n params: LinkedParcelsListGridNameCellRendererParams;\r\n\r\n agInit(params: LinkedParcelsListGridNameCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","
\r\n

Parcel Links

\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { BaseRepository } from '../../../Common/Data/base.repository';\r\nimport { Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class LinkedParcelRepository extends BaseRepository {\r\n constructor(httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n getList(parcelId: number, includeUnlinked: boolean = false): Observable {\r\n return this.httpGet(`/api/parcelLinkage/parcel/${parcelId}?includeUnlinked=${includeUnlinked}`);\r\n }\r\n\r\n getLinkageTypes(): Observable {\r\n return this.httpGet('/api/parcelLinkage/types');\r\n }\r\n\r\n createOrUpdate(model: Core.LinkedParcelInputDTO): Observable {\r\n return this.httpPost('/api/parcelLinkage/parcels', model);\r\n }\r\n}\r\n"," 0\">\r\n\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
{{ selectedLinkageType?.type }}
\r\n
\r\n
\r\n
{{ selectedLinkageType?.description }}
\r\n
\r\n
\r\n \r\n \r\n
\r\n
Master parcel is required.
\r\n
Linkage is required.
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy, ElementRef, ViewChild, ViewEncapsulation } from '@angular/core';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent, ColumnApi } from 'ag-grid-community';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { LinkedParcelsListGridActionCellRendererComponent, ICellRendererParamsForLinkedParcelsListGridAction } from './agGridActionCellRenderer.component';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams } from '../../../../Compliance/AgGrid';\r\nimport { WeissmanModalService, IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { LinkedParcelAddParams, LinkedParcelsAddComponent } from '../Linked-Parcels-Add/linkedParcelsAdd.component';\r\nimport { ParcelTypeCellRendererComponent, ParcelTypeCellRendererComponentParams } from '../../Parcel-Type-Cell-Renderer/parcelTypeCellRenderer.component';\r\nimport { BusyIndicatorMessageManager } from '../../../../Busy-Indicator';\r\nimport { LinkedParcelRepository } from '../linkedParcel.repository';\r\nimport { LinkedParcelsListGridNameCellRendererComponent, LinkedParcelsListGridNameCellRendererParams } from './agGridNameCellRenderer.component';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectTracker, AgGridMultiSelectCellRendererParams } from '../../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { UpgradeNavigationServiceHandler } from '../../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { BehaviorSubject, lastValueFrom, Subscription } from 'rxjs';\r\nimport { TimerService } from '../../../../UI-Lib/Utilities/timer.service';\r\n\r\ninterface LinkedParcelRowModel extends Core.LinkedParcelDTO {\r\n masterParcelId?: number;\r\n}\r\n\r\ninterface LinkedParcelRowModelSelectable extends Core.LinkedParcelDTO {\r\n isSelected: boolean;\r\n}\r\n\r\nexport interface LinkedParcelsListParams {\r\n parcelId: number;\r\n parcelAcctNum: string;\r\n editMode: boolean;\r\n masterParcelAcctNum: string;\r\n masterParcelId: number;\r\n linkageTypes: Core.LinkageTypeModel[];\r\n linkedParcelCount: number;\r\n}\r\n\r\n@Component({\r\n selector: 'linked-parcels-list',\r\n templateUrl: './linkedParcelsList.component.html',\r\n styleUrls: ['./linkedParcelsList.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class LinkedParcelsListComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _bsModalService: BsModalService,\r\n private readonly _wsModalService: WeissmanModalService,\r\n private readonly _linkedParcelRepository: LinkedParcelRepository,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _timer: TimerService) { }\r\n\r\n @ViewChild('focus') focusElement: ElementRef;\r\n\r\n params: LinkedParcelsListParams;\r\n result: Core.LinkedParcelInfoDTO;\r\n\r\n parcels: LinkedParcelRowModel[];\r\n masterParcel: LinkedParcelRowModel;\r\n selectedLinkageType: Core.LinkageTypeModel;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n isBulkDeleteAvailable: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n companyId: number;\r\n agGridReady: boolean;\r\n gridId: System.Guid = '6C6E2165-6879-4A3E-B977-50EB5EA014D6';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this._gridTracker.isRowSelected((params.data as LinkedParcelRowModel).parcelId),\r\n 'grid-row-master': params => {\r\n const parcel = params.data as LinkedParcelRowModel;\r\n return parcel && parcel.masterParcel;\r\n }\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _gridColumnApi: ColumnApi;\r\n private _allParcels: Core.LinkedParcelDTO[];\r\n private _gridTracker: AgGridMultiSelectTracker;\r\n private _selectedRowsSub: Subscription;\r\n\r\n\r\n get editMode(): boolean {\r\n return this.params && this.params.editMode;\r\n }\r\n\r\n get masterParcelAcctNum(): string {\r\n return (this.masterParcel && this.masterParcel.acctNum) || this.params.parcelAcctNum;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n const busyMsg = 'loading';\r\n\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n\r\n this.busyIndicatorMessageManager.add('Loading', busyMsg);\r\n\r\n try {\r\n const linkedParcels = await lastValueFrom(this._linkedParcelRepository.getList(this.params.parcelId, false));\r\n\r\n this.parcels = linkedParcels\r\n .filter(x => x.parcelId === this.params.parcelId || x.linked)\r\n .map((x) => ({...x} as LinkedParcelRowModel));\r\n\r\n this.masterParcel = this.parcels.find(x => x.masterParcel);\r\n\r\n this.selectedLinkageType = this.params.linkageTypes.find(x => x.linkageTypeId == (this.masterParcel && this.masterParcel.linkageTypeId)) || this.params.linkageTypes.length && this.params.linkageTypes[0];\r\n\r\n this.parcels.forEach((x) => {\r\n x.masterParcelId = this.masterParcel && this.masterParcel.parcelId;\r\n });\r\n\r\n this._setRowData();\r\n }\r\n finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n }\r\n\r\n ngOnDestroy() {\r\n this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridColumnApi = event.columnApi;\r\n this._gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n if (this._selectedRowsSub) {\r\n this._selectedRowsSub.unsubscribe();\r\n }\r\n this._selectedRowsSub = this._gridTracker.selectedRows$.subscribe(x => {\r\n this.isBulkDeleteAvailable.next(x.selectAllRows || x.selectedRows.length > 0);\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'parcelId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this._gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this._gridTracker,\r\n isCellRendererDisabledFn: (rowId: number, data: LinkedParcelRowModel) => data.masterParcel\r\n } as AgGridMultiSelectCellRendererParams,\r\n hide: !this.editMode\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'propertyTypeAbbr',\r\n width: AgGridColumns.textColumnExtraSmallWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: ParcelTypeCellRendererComponent,\r\n cellRendererParams: {\r\n getParcelType: this._getParcelType.bind(this),\r\n isLinkedParcel: this._isLinkedParcel.bind(this),\r\n isMasterParcel: this._isMasterParcel.bind(this)\r\n } as ParcelTypeCellRendererComponentParams\r\n },\r\n {\r\n headerName: 'Parcel',\r\n field: 'acctNum',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: LinkedParcelsListGridNameCellRendererComponent,\r\n cellRendererParams: {\r\n getName: (params) => {\r\n const parcel = params.data as LinkedParcelRowModel;\r\n return parcel && parcel.acctNum;\r\n },\r\n getLink: (params) => {\r\n const parcel = params.data as LinkedParcelRowModel;\r\n if (!parcel) {\r\n return null;\r\n }\r\n return `#/parcel/${parcel.parcelId}`;\r\n },\r\n isMaster: (params) => {\r\n const parcel = params.data as LinkedParcelRowModel;\r\n return parcel && parcel.masterParcel;\r\n },\r\n canNavigate: !this.editMode\r\n } as LinkedParcelsListGridNameCellRendererParams\r\n },\r\n {\r\n headerName: 'Master',\r\n field: 'isMaster',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as LinkedParcelRowModel;\r\n return parcel && parcel.masterParcel ? 'Master' : 'Subordinate';\r\n },\r\n filterValueGetter: params => {\r\n const parcel = params.data as LinkedParcelRowModel;\r\n return parcel && parcel.masterParcel ? 'Master' : 'Subordinate';\r\n }\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(1),\r\n minWidth: AgGridColumns.getActionColumnWidth(1),\r\n maxWidth: AgGridColumns.getActionColumnWidth(1),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n suppressMenu: true,\r\n sortable: false,\r\n cellRendererFramework: LinkedParcelsListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canRemove: this._canRemove.bind(this),\r\n remove: this._remove.bind(this),\r\n toggleMaster: this._toggleMaster.bind(this),\r\n getMasterTitle: this._getMasterTitle.bind(this),\r\n canToggleMaster: (params) => {\r\n return false; //disable toggle master until the API supports it\r\n }\r\n } as ICellRendererParamsForLinkedParcelsListGridAction,\r\n hide: !this.editMode\r\n }];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridColumnApi.setColumnPinned('actions', 'right');\r\n this.agGridReady = true;\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n const busyMsg = 'saving';\r\n\r\n this.busyIndicatorMessageManager.add('Saving', busyMsg);\r\n\r\n const parcelLinks = this.parcels\r\n .filter(x => x.parcelId !== this.params.parcelId)\r\n .map((x) => {\r\n const parcelLink: Core.ParcelLinkDTO = {\r\n linked: true,\r\n parcelId: x.parcelId\r\n };\r\n return parcelLink;\r\n });\r\n\r\n try {\r\n const model: Core.LinkedParcelInputDTO = {\r\n callingParcelId: this.params.parcelId,\r\n linkageTypeId: this.selectedLinkageType && this.selectedLinkageType.linkageTypeId,\r\n masterParcelId: this.masterParcel && this.masterParcel.parcelId,\r\n parcelLinks: parcelLinks\r\n };\r\n\r\n this.result = await lastValueFrom(this._linkedParcelRepository.createOrUpdate(model));\r\n }\r\n finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async add(): Promise {\r\n if (!this._allParcels) {\r\n const busyMsg = 'loading';\r\n\r\n this.busyIndicatorMessageManager.add('Loading', busyMsg);\r\n\r\n try {\r\n this._allParcels = await lastValueFrom(this._linkedParcelRepository.getList(this.params.parcelId, true));\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n }\r\n\r\n let addResult: Core.LinkedParcelDTO[] = [];\r\n try {\r\n const params: LinkedParcelAddParams = {\r\n parcels: this.parcels,\r\n parcelId: this.params.parcelId,\r\n allParcels: this._allParcels\r\n };\r\n\r\n const bsModalRef = await this._wsModalService.show(() => {\r\n return this._bsModalService.show(LinkedParcelsAddComponent,\r\n {\r\n class: 'modal-lg',\r\n initialState: {\r\n params: params\r\n },\r\n ignoreBackdropClick: true\r\n });\r\n }).whenClosed;\r\n\r\n addResult = (bsModalRef.content as LinkedParcelsAddComponent).result;\r\n } catch (e) {\r\n return Promise.resolve();\r\n } finally {\r\n // restore focus to this modal\r\n this._timer.setTimeout(() => {\r\n this.focusElement.nativeElement.focus();\r\n }, 100);\r\n }\r\n\r\n const newParcels = addResult.map(\r\n (x) => {\r\n return {\r\n ...x,\r\n ...{\r\n isMaster: this.masterParcel && x.parcelId === this.masterParcel.parcelId,\r\n linked: true\r\n }\r\n } as LinkedParcelRowModel;\r\n });\r\n\r\n newParcels.forEach(x => this.parcels.push(x));\r\n\r\n this._setRowData();\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n removeAll(): void {\r\n this.parcels.forEach((x) => {\r\n x.linked = false;\r\n x.linkageTypeId = null;\r\n x.masterParcelId = null;\r\n });\r\n\r\n this.parcels = [this.masterParcel];\r\n\r\n this._setRowData();\r\n }\r\n\r\n async bulkDelete(): Promise {\r\n const selectedRowIds = await this._gridTracker.getSelectedRowIds();\r\n const selected = this.parcels.filter(x => selectedRowIds.includes(x.parcelId));\r\n selected.forEach(x => {\r\n x.linked = false;\r\n x.linkageTypeId = null;\r\n x.masterParcelId = null;\r\n });\r\n\r\n this._gridTracker.clear();\r\n this.parcels = this.parcels.filter(x => !selectedRowIds.includes(x.parcelId));\r\n\r\n this._setRowData();\r\n }\r\n\r\n private _getParcelType(params: ParcelTypeCellRendererComponentParams): string {\r\n const parcel = params.data as Core.LinkedParcelDTO;\r\n if (!parcel) {\r\n return null;\r\n }\r\n\r\n return parcel.propertyTypeAbbr;\r\n }\r\n\r\n private _isLinkedParcel(params: ParcelTypeCellRendererComponentParams): boolean {\r\n const parcel = params.data as Core.LinkedParcelDTO;\r\n if (!parcel) {\r\n return false;\r\n }\r\n return parcel.linked;\r\n }\r\n\r\n private _isMasterParcel(params: ParcelTypeCellRendererComponentParams): boolean {\r\n const parcel = params.data as Core.LinkedParcelDTO;\r\n if (!parcel) {\r\n return false;\r\n }\r\n return parcel.masterParcel;\r\n }\r\n\r\n private _getMasterTitle(params: ICellRendererParamsForLinkedParcelsListGridAction): string {\r\n const parcel = params.data as LinkedParcelRowModel;\r\n if (!parcel) {\r\n return '';\r\n }\r\n\r\n return parcel.masterParcel ? 'Remove Master' : 'Make Master';\r\n }\r\n\r\n private _toggleMaster(params: ICellRendererParamsForLinkedParcelsListGridAction): void {\r\n const newMasterParcel = params.data as LinkedParcelRowModel;\r\n if (!newMasterParcel) {\r\n return;\r\n }\r\n\r\n newMasterParcel.masterParcel = !newMasterParcel.masterParcel;\r\n this.masterParcel = newMasterParcel.masterParcel ? newMasterParcel : null;\r\n\r\n this.parcels.forEach(\r\n (parcel) => {\r\n parcel.masterParcelId = newMasterParcel.masterParcel ? newMasterParcel.parcelId : null;\r\n parcel.masterParcel = newMasterParcel.masterParcel ? parcel.parcelId === newMasterParcel.parcelId : false;\r\n });\r\n\r\n this._setRowData();\r\n }\r\n\r\n private _canRemove(params: ICellRendererParamsForLinkedParcelsListGridAction): boolean {\r\n const parcel = params.data as LinkedParcelRowModel;\r\n if (!parcel) {\r\n return false;\r\n }\r\n\r\n return parcel.parcelId !== this.params.parcelId;\r\n }\r\n\r\n private _remove(params: ICellRendererParamsForLinkedParcelsListGridAction): void {\r\n const parcel = params.data as LinkedParcelRowModel;\r\n if (!parcel) {\r\n return;\r\n }\r\n\r\n parcel.masterParcelId = null;\r\n parcel.masterParcel = false;\r\n parcel.linked = false;\r\n\r\n if (this.masterParcel) {\r\n if (parcel.parcelId === this.masterParcel.parcelId) {\r\n this.masterParcel = null;\r\n }\r\n }\r\n\r\n _.remove(this.parcels, x => x.parcelId === parcel.parcelId);\r\n\r\n this._setRowData();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.parcels && this.agGridReady)) {\r\n return;\r\n }\r\n\r\n const masterParcels = this.parcels.filter(x => x.masterParcel);\r\n const subordinateParcels = this.parcels.filter(x => !x.masterParcel);\r\n\r\n this._gridApi.setPinnedTopRowData(masterParcels);\r\n this._gridApi.setRowData(subordinateParcels);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Compliance.QueryResultModel {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return {\r\n data: rows.map((x) => {\r\n const parcel = x.data as LinkedParcelRowModelSelectable;\r\n return parcel && parcel.parcelId;\r\n })\r\n } as Compliance.QueryResultModel;\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const LINKED_PARCELS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'linked-parcels.master-parcel',\r\n tooltipText: 'Master parcel'\r\n }\r\n];\r\n","
\r\n Master Parcel:\r\n \r\n
\r\n
\r\n Linked To:\r\n \r\n
\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { LinkedParcelsListParams, LinkedParcelsListComponent } from './Linked-Parcels-List/linkedParcelsList.component';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { LinkedParcelRepository } from './linkedParcel.repository';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { LINKED_PARCELS_HELP } from './linkedParcels.component.help';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\n\r\n@Component({\r\n selector: 'linked-parcels',\r\n templateUrl: './linkedParcels.component.html'\r\n})\r\nexport class LinkedParcelsComponent implements OnInit {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _linkedParcelRepository: LinkedParcelRepository,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _helpService: HelpService) { }\r\n\r\n @Input() parcelId: number;\r\n @Input() parcelAcctNum: string;\r\n @Input() linkedParcelCount: number;\r\n @Input() masterParcelId: number;\r\n @Input() masterParcelAcctNum: string;\r\n @Input() isDisabled: boolean;\r\n\r\n private _linkageTypes: Core.LinkageTypeModel[];\r\n\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(LINKED_PARCELS_HELP);\r\n }\r\n\r\n async showParcels(): Promise {\r\n if (!this._linkageTypes) {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n this._linkageTypes = await lastValueFrom(this._linkedParcelRepository.getLinkageTypes());\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n const params: LinkedParcelsListParams = {\r\n parcelId: this.parcelId,\r\n parcelAcctNum: this.parcelAcctNum,\r\n masterParcelId: this.masterParcelId,\r\n masterParcelAcctNum: this.masterParcelAcctNum,\r\n linkageTypes: this._linkageTypes,\r\n linkedParcelCount: this.linkedParcelCount,\r\n editMode: false,\r\n };\r\n\r\n await this._modalService.showAsync(LinkedParcelsListComponent, params, 'modal-lg');\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n navigateToParcel(parcelId: number): void {\r\n this._routerService.go('parcelRedirect', { 'entityID': parcelId });\r\n }\r\n}\r\n","import { Component, Input, EventEmitter, Output } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { WeissmanModalService } from '../../../../Compliance/WeissmanModalService';\r\nimport { LinkedParcelsListParams, LinkedParcelsListComponent } from '../Linked-Parcels-List/linkedParcelsList.component';\r\nimport { LinkedParcelRepository } from '../linkedParcel.repository';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\n\r\n@Component({\r\n selector: 'linked-parcels-edit',\r\n templateUrl: './linkedParcelsEdit.component.html'\r\n})\r\nexport class LinkedParcelsEditComponent {\r\n constructor(\r\n private readonly _bsModalService: BsModalService,\r\n private readonly _wsModalService: WeissmanModalService,\r\n private readonly _linkedParcelRepository: LinkedParcelRepository,\r\n private readonly _busyIndicatorService: BusyIndicatorService) {\r\n }\r\n\r\n @Input() parcelId: number;\r\n @Input() parcelAcctNum: string;\r\n @Input() linkedParcelCount: number;\r\n @Input() masterParcelId: number;\r\n @Input() masterParcelAcctNum: string;\r\n @Input() isDisabled: boolean;\r\n\r\n @Output() linkedParcelsChanged: EventEmitter = new EventEmitter();\r\n\r\n private _linkageTypes: Core.LinkageTypeModel[];\r\n\r\n\r\n async edit(): Promise {\r\n if (!this._linkageTypes) {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading Linkages' });\r\n\r\n try {\r\n this._linkageTypes = await lastValueFrom(this._linkedParcelRepository.getLinkageTypes());\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n try {\r\n const params: LinkedParcelsListParams = {\r\n parcelId: this.parcelId,\r\n parcelAcctNum: this.parcelAcctNum,\r\n masterParcelId: this.masterParcelId,\r\n masterParcelAcctNum: this.masterParcelAcctNum,\r\n linkageTypes: this._linkageTypes,\r\n linkedParcelCount: this.linkedParcelCount,\r\n editMode: true\r\n };\r\n\r\n const bsModalParcelsRef = await this._wsModalService.show(() => {\r\n return this._bsModalService.show(LinkedParcelsListComponent,\r\n {\r\n class: 'modal-lg',\r\n initialState: {\r\n params: params\r\n },\r\n ignoreBackdropClick: true\r\n });\r\n }).whenClosed;\r\n\r\n const result = (bsModalParcelsRef.content as LinkedParcelsListComponent).result;\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.linkedParcelsChanged.next(result);\r\n\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ParcelReportsSitesListGridNameCellRendererParams extends ICellRendererParams {\r\n getName: (params: ParcelReportsSitesListGridNameCellRendererParams) => string;\r\n navigate: (params: ParcelReportsSitesListGridNameCellRendererParams) => void;\r\n canNavigate: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'parcel-reports-sites-list-grid-name-cell',\r\n template: `\r\n{{ params.getName(params) }}\r\n\r\n `\r\n})\r\nexport class ParcelReportsSitesListGridNameCellRendererComponent implements ICellRendererAngularComp {\r\n params: ParcelReportsSitesListGridNameCellRendererParams;\r\n\r\n agInit(params: ParcelReportsSitesListGridNameCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","\r\n","import { Component, OnInit, ViewEncapsulation } from '@angular/core';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams } from '../../../../Compliance/AgGrid';\r\nimport { ParcelReportsSitesListGridNameCellRendererParams, ParcelReportsSitesListGridNameCellRendererComponent } from './agGridNameCellRenderer.component';\r\nimport { UpgradeNavigationServiceHandler } from '../../../../Common/Routing/upgrade-navigation-handler.service';\r\n\r\nexport interface ParcelReportsSitesListParams {\r\n sites: Core.SiteNamePropertyDTO[];\r\n siteId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'parcel-reports-sites-list',\r\n templateUrl: './parcelReportsSitesList.component.html',\r\n styleUrls: ['./parcelReportsSitesList.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ParcelReportsSitesListComponent implements OnInit {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _routerService: UpgradeNavigationServiceHandler) { }\r\n\r\n params: ParcelReportsSitesListParams;\r\n reportingSites: Core.SiteNamePropertyDTO[] = [];\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({})\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n\r\n\r\n async ngOnInit(): Promise {\r\n this.reportingSites = _.map(this.params.sites,\r\n (x) => {\r\n return _.extend(\r\n {},\r\n x,\r\n {\r\n property: `${x.property ? x.property : '[No Site Number]'}${x.siteID === this.params.siteId ? ' (this parcel\\'s parent site)': ''}`\r\n });\r\n });\r\n\r\n this._setRowData();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Site Name',\r\n field: 'name',\r\n width: AgGridColumns.textColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: ParcelReportsSitesListGridNameCellRendererComponent,\r\n cellRendererParams: {\r\n getName: (params) => {\r\n const site = params.data as Core.SiteNamePropertyDTO;\r\n return site && site.name;\r\n },\r\n navigate: (params) => {\r\n const site = params.data as Core.SiteNamePropertyDTO;\r\n if (!site) {\r\n return;\r\n }\r\n this._navigateToSite(site.siteID);\r\n this._bsModalRef.hide();\r\n },\r\n canNavigate: true\r\n } as ParcelReportsSitesListGridNameCellRendererParams\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'property',\r\n width: AgGridColumns.textColumnWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _navigateToSite(siteId: number): void {\r\n this._routerService.go('siteRedirect', { 'entityID': siteId });\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.reportingSites)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this.reportingSites);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n}\r\n","
\r\n Reports Sites:\r\n
\r\n
{{ siteNumbers }}
\r\n \r\n
\r\n
\r\n","\r\n
\r\n

Reports Sites

\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, Input } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { ParcelReportsSitesListParams, ParcelReportsSitesListComponent } from './Reports-Sites-List/parcelReportsSitesList.component';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'parcel-reports-sites',\r\n templateUrl: './parcelReportsSites.component.html'\r\n})\r\nexport class ParcelReportsSitesComponent {\r\n constructor(\r\n private readonly _bsModalService: BsModalService,\r\n private readonly _wsModalService: WeissmanModalService) { }\r\n\r\n @Input() sites: Core.SiteNamePropertyDTO[];\r\n @Input() siteId: number;\r\n\r\n get siteNames(): string {\r\n return _.join(_.map(this.sites, x => x.name), ', ');\r\n }\r\n\r\n get siteNumbers(): string {\r\n return _.join(_.map(this.sites, x => `${x.property ? x.property : '[No Site Number]'}${x.siteID === this.siteId ? ' (this parcel\\'s parent site)' : ''}`), ', ');\r\n }\r\n\r\n async showSites(): Promise {\r\n try {\r\n const params: ParcelReportsSitesListParams = {\r\n sites: this.sites,\r\n siteId: this.siteId\r\n };\r\n\r\n await this._wsModalService.show(() => {\r\n return this._bsModalService.show(ParcelReportsSitesListComponent,\r\n {\r\n class: 'modal-md',\r\n initialState: {\r\n params: params\r\n },\r\n ignoreBackdropClick: true\r\n });\r\n }).whenClosed;\r\n\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ParcelIconComponent } from './parcelIcon.component';\r\nimport { WeissmanSharedModule } from '../../../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../../../Hybrid/hybrid-adapter.utility';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n WeissmanSharedModule\r\n ],\r\n declarations: [\r\n ParcelIconComponent\r\n ],\r\n exports: [\r\n ParcelIconComponent\r\n ]\r\n})\r\nexport class ParcelIconModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('parcelIcon', ParcelIconComponent);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Acct. PeriodCollectorDescriptionAccrualWrite Journal\r\n
{{account.accrualAccountTypeName}}
\r\n
{{account.accountNumber}}
\r\n
\r\n {{getAcctPeriodName(row.accountingPeriodId)}}\r\n \r\n \r\n {{getCollectorName(row.collectorId)}}\r\n \r\n \r\n {{row.description}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n Yes\r\n No\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, Output, EventEmitter, OnInit } from '@angular/core';\r\nimport { BalanceAdjustmentsService } from './balanceAdjustments.service';\r\nimport { NavigationService } from '../../Layout/navigation.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport * as _ from 'lodash';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\n\r\ninterface AccrualBalanceAdjustmentModelUI extends Core.AccrualBalanceAdjustmentModel {\r\n isEdit: boolean;\r\n isHovered: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'accruals-adjustments-list',\r\n templateUrl: './accrualsAdjustmentsList.component.html',\r\n styles: [`\r\n select.form-control {\r\n display: inline-block;\r\n width: auto;\r\n }\r\n td {\r\n vertical-align: middle !important;\r\n height: 42px;\r\n }\r\n :host {\r\n display: flex;\r\n flex-flow: column;\r\n height: 100%;\r\n max-height: 100%;\r\n width: 100%;\r\n }\r\n `]\r\n})\r\nexport class AccrualsAdjustmentsListComponent implements OnInit {\r\n constructor(\r\n private readonly _navigationService: NavigationService,\r\n private readonly _balanceAdjustmentsService: BalanceAdjustmentsService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _messageModalService: MessageModalService\r\n ) { }\r\n\r\n @Input() parcelId: number;\r\n @Input() editMode: boolean;\r\n @Input() hasEditPermission: boolean;\r\n @Output() editModeChange: EventEmitter = new EventEmitter();\r\n\r\n adjustments: AccrualBalanceAdjustmentModelUI[];\r\n selectionData: Core.AccrualBalanceAdjustmentSelectionDataModel;\r\n serverAction: boolean = false;\r\n\r\n private _originalAdjustment: AccrualBalanceAdjustmentModelUI;\r\n\r\n async ngOnInit(): Promise {\r\n this.serverAction = true;\r\n\r\n try {\r\n this.selectionData = await this._balanceAdjustmentsService.getSelectionData(this.parcelId);\r\n this.adjustments = (await this._balanceAdjustmentsService.getAdjustments(this.parcelId)).adjustments as AccrualBalanceAdjustmentModelUI[];\r\n }\r\n finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n getAcctPeriodName(accountingPeriodId: number): string {\r\n const acctPeriod = _.find(this.selectionData.accountingPeriods, { accountingPeriodId });\r\n\r\n return acctPeriod ? acctPeriod.name : '';\r\n }\r\n\r\n getCollectorName(collectorId: number): string {\r\n const collector = _.find(this.selectionData.collectors, { collectorId });\r\n\r\n return collector ? collector.name : '';\r\n }\r\n\r\n getImpactAmount(impacts: Core.AccrualBalanceAdjustmentJournalImpactModel[], glAccountId: number): number {\r\n const impact = _.find(impacts, { glAccountId });\r\n\r\n return impact ? impact.amount : null;\r\n }\r\n\r\n setImpactAmount(impacts: Core.AccrualBalanceAdjustmentJournalImpactModel[], glAccountId: number, amount: number): void {\r\n const impactIdx = _.findIndex(impacts, { glAccountId });\r\n\r\n if(impactIdx >= 0) {\r\n impacts[impactIdx].amount = amount;\r\n } else {\r\n impacts.push({ glAccountId, amount } as Core.AccrualBalanceAdjustmentJournalImpactModel);\r\n }\r\n }\r\n\r\n writeJournalChanged(adjustment: AccrualBalanceAdjustmentModelUI): void {\r\n if(!adjustment.writeJournal) {\r\n adjustment.journalImpacts = [];\r\n }\r\n }\r\n\r\n edit(adjustment: AccrualBalanceAdjustmentModelUI) {\r\n this._originalAdjustment = _.cloneDeep(adjustment);\r\n adjustment.isEdit = true;\r\n\r\n this._setEditMode(true);\r\n }\r\n\r\n cancel(adjustment: AccrualBalanceAdjustmentModelUI) {\r\n if(adjustment.accrualBalanceAdjustmentId) {\r\n adjustment.isEdit = false;\r\n _.assign(adjustment, this._originalAdjustment);\r\n } else {\r\n _.remove(this.adjustments, adjustment);\r\n }\r\n\r\n this._setEditMode(false);\r\n }\r\n\r\n async delete(adjustment: AccrualBalanceAdjustmentModelUI): Promise {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you wish to delete this adjustment?', 'Confirm Delete');\r\n }\r\n catch {\r\n return Promise.resolve();\r\n }\r\n\r\n this.serverAction = true;\r\n try {\r\n await this._balanceAdjustmentsService.deleteAdjustment(this.parcelId, adjustment.accrualBalanceAdjustmentId);\r\n _.remove(this.adjustments, adjustment);\r\n }\r\n finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n async save(adjustment: AccrualBalanceAdjustmentModelUI) {\r\n if(this._invalidData(adjustment)) {\r\n return;\r\n }\r\n\r\n this.serverAction = true;\r\n try {\r\n adjustment.journalImpacts = _.reject(adjustment.journalImpacts, {amount: null});\r\n const savedAdjustment = await this._balanceAdjustmentsService.updateAdjustment(this.parcelId, adjustment);\r\n _.assign(adjustment, savedAdjustment);\r\n\r\n adjustment.isEdit = false;\r\n this._setEditMode(false);\r\n }\r\n finally {\r\n this.serverAction = false;\r\n }\r\n\r\n }\r\n\r\n addRow(): void {\r\n const firstOpenAccountingPeriod = _.find(this.selectionData.accountingPeriods, {isClosed: false});\r\n\r\n if(!firstOpenAccountingPeriod) {\r\n this._toastr.error('Cannot Add. No open account periods available.');\r\n return;\r\n }\r\n\r\n const newRow = {\r\n parcelId: this.parcelId,\r\n accountingPeriodId: firstOpenAccountingPeriod.accountingPeriodId,\r\n collectorId: this.selectionData.collectors[0].collectorId,\r\n description: '',\r\n writeJournal: false,\r\n journalImpacts: [],\r\n isPeriodClosed: false,\r\n rowVersion: [],\r\n isEdit: true\r\n } as AccrualBalanceAdjustmentModelUI;\r\n\r\n this.adjustments.push(newRow);\r\n this._setEditMode(true);\r\n }\r\n\r\n private _setEditMode(editMode: boolean): void {\r\n this.editMode = editMode;\r\n this.editModeChange.emit(this.editMode);\r\n\r\n if(this.editMode) {\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n } else {\r\n this._navigationService.disableNavWarning();\r\n }\r\n }\r\n\r\n private _isAccrualInvalid(adjustment: AccrualBalanceAdjustmentModelUI): boolean {\r\n const noValue = adjustment.accrualAmount === null || adjustment.accrualAmount === undefined;\r\n const noJournalImpacts = !(adjustment && adjustment.writeJournal && !!adjustment.journalImpacts.length);\r\n\r\n return noValue && noJournalImpacts;\r\n }\r\n\r\n private _rowDoesNotBalance(adjustment: AccrualBalanceAdjustmentModelUI): boolean {\r\n if(!adjustment.writeJournal) {\r\n return false;\r\n }\r\n\r\n const impactsSum = _.chain(adjustment.journalImpacts)\r\n .map('amount')\r\n .compact()\r\n .sum()\r\n .value();\r\n\r\n return (adjustment.accrualAmount || 0) + impactsSum !== 0;\r\n }\r\n\r\n private _invalidData(adjustment: AccrualBalanceAdjustmentModelUI): boolean {\r\n if(!adjustment.description) {\r\n this._toastr.error('Description is Required');\r\n return true;\r\n }\r\n\r\n if(this._isAccrualInvalid(adjustment)) {\r\n this._toastr.error('Accrual Amount is required if no GL Account amounts are entered');\r\n return true;\r\n }\r\n\r\n if(this._rowDoesNotBalance(adjustment)) {\r\n this._toastr.error('Row Amounts do not balance');\r\n return true;\r\n }\r\n\r\n return false;\r\n }\r\n}\r\n","\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Acct. PeriodAdjustmentsAccrual Balance
{{row.accountingPeriodName}}
\r\n","import { Component, Input } from '@angular/core';\r\nimport { BalanceAdjustmentsService } from './balanceAdjustments.service';\r\n\r\n@Component({\r\n selector: 'accruals-balances-list',\r\n templateUrl: './accrualsBalancesList.component.html'\r\n})\r\nexport class AccrualsBalancesListComponent {\r\n constructor(\r\n private readonly _balanceAdjustmentsService: BalanceAdjustmentsService\r\n ) { }\r\n\r\n @Input() parcelId: number;\r\n\r\n balances: Core.ParcelAccrualBalanceModel [];\r\n loading: boolean = false;\r\n\r\n async ngOnInit(): Promise {\r\n this.loading = true;\r\n try {\r\n this.balances = (await this._balanceAdjustmentsService.getBalances(this.parcelId)).balances;\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n \r\n

Accruals

\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, Input, ChangeDetectionStrategy } from '@angular/core';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\n\r\n\r\n@Component({\r\n selector: 'accruals-panel',\r\n templateUrl: './accrualsPanel.component.html'\r\n})\r\nexport class AccrualsPanelComponent {\r\n constructor(public featureFlagService: FeatureFlagsService) {}\r\n\r\n @Input() parcelId: number;\r\n @Input() hasEditPermission: boolean;\r\n\r\n showBody: boolean = false;\r\n showBalance: boolean = false;\r\n adjustmentsEditMode: boolean = false;\r\n\r\n expandOrCollapse(): void {\r\n this.showBody = !this.showBody;\r\n }\r\n}\r\n","\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n \r\n
\r\n

No Collectors found for this parcel.

\r\n
\r\n\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n {{collectorBill.collectorBillName}} Pmt Option:\r\n \r\n Only single option available\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ChangeDetectorRef } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport * as _ from 'lodash';\r\nimport { reject, map, sortBy } from 'lodash/fp';\r\nimport { AssessorCollectorService } from 'src/app/Assessor-Collector/assessor.collector.service';\r\nimport { BillingScenarioService } from 'src/app/Assessor-Collector/Collector/Billing-Scenario/billingScenario.service';\r\n\r\nclass ParcelCollector {\r\n constructor(parcelCollector) {\r\n _.assign(this, parcelCollector);\r\n this.collectorBillInfo = _.map(this.collectorBillInfo, x => new CollectorBillInfo(x));\r\n }\r\n\r\n collectorAbbr: string;\r\n collectorBillInfo: CollectorBillInfo[];\r\n collectorBillScenarioID: number;\r\n collectorBillScenarioName: string;\r\n collectorID: number;\r\n name?: string;\r\n\r\n get title() {\r\n if(this.name) {\r\n return this.name;\r\n } else {\r\n let str = this.collectorAbbr;\r\n\r\n if(this.collectorBillScenarioName) {\r\n str += ` - ${this.collectorBillScenarioName}`;\r\n }\r\n return str;\r\n }\r\n }\r\n}\r\n\r\nclass CollectorBillInfo {\r\n constructor(collectorBillInfo) {\r\n _.assign(this, collectorBillInfo);\r\n }\r\n\r\n collectorBillID: number;\r\n collectorBillName: string;\r\n collectorBillScenarioID: number;\r\n collectorPaymentOptionInfo: CollectorPaymentOptionInfo[];\r\n\r\n get displayPaymentOptions() {\r\n return _.filter(this.collectorPaymentOptionInfo, 'collectorPaymentOptionName');\r\n }\r\n}\r\n\r\ninterface CollectorPaymentOptionInfo {\r\n collectorPaymentOptionID: number;\r\n collectorPaymentOptionName: string;\r\n isDefault: boolean;\r\n}\r\nexport interface AddParcelCollectorModalParams {\r\n collectorList: ParcelCollector[];\r\n addedCollectorIds: number[];\r\n hasCompanyCollectors: boolean;\r\n parcelId: number;\r\n}\r\n\r\nexport interface AddParcelCollectorModalResult {\r\n selectedCollector: ParcelCollector;\r\n applyTo: string;\r\n year?: number;\r\n parcelCollectorPaymentOptions: CollectorPaymentOptionInfo[];\r\n}\r\n\r\n@Component({\r\n selector: 'add-parcel-collector-modal',\r\n templateUrl: 'addParcelCollectorModal.component.html',\r\n styleUrls: ['addParcelCollectorModal.component.scss']\r\n})\r\nexport class AddParcelCollectorModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _changeDetRef: ChangeDetectorRef,\r\n private readonly _billingScenarioService: BillingScenarioService,\r\n private readonly _assessorCollectorService: AssessorCollectorService) { }\r\n\r\n params: AddParcelCollectorModalParams;\r\n result: AddParcelCollectorModalResult;\r\n\r\n serverAction: boolean = false;\r\n isStateCollector: boolean = true;\r\n stateCollectors: ParcelCollector[];\r\n companyCollectors: ParcelCollector[];\r\n selectedCollector: ParcelCollector;\r\n selectedPaymentOptions: CollectorPaymentOptionInfo[] = [];\r\n applyTo: 'all'|'year' = 'all';\r\n taxYears: number[] = _.range(2000, 2050);\r\n taxYear: number = new Date().getFullYear();\r\n\r\n\r\n ngOnInit(): void {\r\n this.stateCollectors = this._prepareCollectorList(this.params.collectorList);\r\n this.selectedCollector = this.stateCollectors[0];\r\n }\r\n\r\n get collectors(): ParcelCollector[] {\r\n return this.isStateCollector ? this.stateCollectors : this.companyCollectors;\r\n }\r\n\r\n governmentalCollectorsSelected(): void {\r\n this.selectedCollector = this.stateCollectors[0];\r\n this.collectorChanged();\r\n this._changeDetRef.detectChanges();\r\n }\r\n\r\n async companyCollectorsSelected(): Promise {\r\n if(!this.companyCollectors) {\r\n this.serverAction = true;\r\n\r\n try {\r\n const companyCollectors = await this._assessorCollectorService.getCompanyCollectorsByParcel(this.params.parcelId);\r\n this.companyCollectors = this._prepareCollectorList(companyCollectors);\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n this.selectedCollector = this.companyCollectors[0];\r\n this.collectorChanged();\r\n }\r\n\r\n // This is a hack until the parcel info panel is upgraded\r\n // For some reason this modal will not detect the change automatically\r\n // My theory is that it's launched from angularjs, whereas a modal that's launched\r\n // from modern angular doesn't have this issue.\r\n applyToChange(e): void {\r\n this.applyTo = e.target.value;\r\n this._changeDetRef.detectChanges();\r\n }\r\n\r\n async collectorChanged(): Promise {\r\n if(!this.selectedCollector?.collectorBillScenarioID) {\r\n return;\r\n }\r\n\r\n this.serverAction = true;\r\n try {\r\n const billScenario: Weissman.Model.Collectors.CollectorBillScenario = await this._billingScenarioService.getById(this.selectedCollector.collectorBillScenarioID);\r\n\r\n this.selectedCollector.collectorBillInfo = _.flow([\r\n map((bill: Weissman.Model.Collectors.CollectorBill) => {\r\n const collectorPaymentOptionInfo = _.map(bill.collectorPaymentOptions, option => {\r\n return {\r\n collectorPaymentOptionID: option.collectorPaymentOptionID,\r\n collectorPaymentOptionName: option.name,\r\n isDefault: option.isDefault\r\n };\r\n });\r\n\r\n return new CollectorBillInfo({\r\n collectorBillID: bill.collectorBillID,\r\n collectorBillName: bill.name,\r\n collectorBillScenarioID: bill.collectorBillScenarioID,\r\n collectorPaymentOptionInfo\r\n });\r\n }),\r\n sortBy('collectorBillName')\r\n ])(billScenario.collectorBills || []);\r\n\r\n this.selectedPaymentOptions = _.fill(Array(this.selectedCollector.collectorBillInfo.length), undefined);\r\n _.forEach(this.selectedPaymentOptions, (item, index) => {\r\n const defaultPaymentOption = _.find(this.selectedCollector.collectorBillInfo[index].collectorPaymentOptionInfo, {isDefault: true});\r\n if(defaultPaymentOption) {\r\n this.selectedPaymentOptions[index] = defaultPaymentOption;\r\n }\r\n });\r\n\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n add(): void {\r\n this.result = {\r\n selectedCollector: this.selectedCollector,\r\n applyTo: this.applyTo,\r\n parcelCollectorPaymentOptions: this.selectedPaymentOptions\r\n };\r\n\r\n if(this.applyTo === 'year') {\r\n this.result.year = this.taxYear;\r\n }\r\n\r\n if(this.result.parcelCollectorPaymentOptions.length < this.selectedCollector.collectorBillInfo.length) {\r\n _.forEach(this.selectedCollector.collectorBillInfo, collectorBill => {\r\n if(collectorBill.collectorPaymentOptionInfo.length > 0) {\r\n const selectedPaymentOptionIDs = _.map(this.result.parcelCollectorPaymentOptions, 'collectorPaymentOptionID');\r\n const collectorPaymentOptionIDs = _.map(collectorBill.collectorPaymentOptionInfo, 'collectorPaymentOptionID');\r\n if(!_.intersection(selectedPaymentOptionIDs, collectorPaymentOptionIDs).length) {\r\n this.result.parcelCollectorPaymentOptions.push(collectorBill.collectorPaymentOptionInfo[0]);\r\n }\r\n }\r\n });\r\n }\r\n\r\n this.close();\r\n }\r\n\r\n close(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _prepareCollectorList(collectors): ParcelCollector[] {\r\n return _.flow([\r\n reject(x => _.includes(this.params.addedCollectorIds, x.collectorID)),\r\n map(x => new ParcelCollector(x)),\r\n sortBy(x => x.title.toLowerCase())\r\n ])(collectors);\r\n }\r\n}","import { Injectable } from '@angular/core';\r\nimport { WeissmanModalService } from 'src/app/Compliance/WeissmanModalService';\r\nimport { AddParcelCollectorModalComponent, AddParcelCollectorModalParams, AddParcelCollectorModalResult } from './addParcelCollectorModal.component';\r\n\r\n@Injectable()\r\nexport class TempParcelCollectorModalService {\r\n constructor(private _modalService: WeissmanModalService) { }\r\n\r\n async launchModal(modalParams: AddParcelCollectorModalParams): Promise {\r\n return this._modalService.showAsync(AddParcelCollectorModalComponent, modalParams, 'modal-md');\r\n }\r\n\r\n}","import { Component } from '@angular/core';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AssessorSummary } from '../Site/Site.Model';\r\nimport { HelpContentRendererValue, HelpContentComponent, HelpService } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport interface AssessorDetailsComponentParams extends HelpContentRendererValue {\r\n siteId?: number;\r\n parcelId?: number;\r\n stateId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'assessor-details',\r\n template: `\r\n

Jurisdiction Specialist 1\">s

\r\n \r\n
\r\n
{{specialist.firstName}} {{specialist.lastName}} {{propertyTypes[type-1]}}
\r\n
{{specialist.teamName}}
\r\n
{{specialist.address.phone}}
\r\n \r\n
\r\n
\r\n None Assigned\r\n
\r\n `\r\n})\r\nexport class AssessorDetailsComponent implements HelpContentComponent {\r\n constructor(private readonly _http: HttpClient, private readonly _helpService: HelpService) { }\r\n\r\n jurisdictionSpecialists: any[] = [];\r\n propertyTypes = ['RE', 'PP', 'MN', 'CA'];\r\n loading: boolean = true;\r\n\r\n params: AssessorDetailsComponentParams;\r\n\r\n async helpInit(params: AssessorDetailsComponentParams): Promise {\r\n let url = '/api/';\r\n url += params.siteId ? (`site/${ params.siteId}`) : (`parcel/${ params.parcelId}`);\r\n url += `/assessor/${ params.value.assessorID }/jurisdictionspecialist`;\r\n\r\n try {\r\n this.jurisdictionSpecialists = await lastValueFrom(this._http.get(url));\r\n } catch (err) {\r\n console.log('Loading Jurisdiction Specialist Failed: ', err);\r\n } finally {\r\n this.loading = false;\r\n this._helpService.refresh();\r\n }\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\n\r\nexport interface LegalDescriptionModalParams {\r\n isEditMode: boolean;\r\n parcel: Weissman.Model.Domain.Parcel\r\n}\r\n\r\n@Component({\r\n selector: 'legal-description-modal',\r\n template: `\r\n \r\n \r\n \r\n `\r\n})\r\n\r\nexport class LegalDescriptionModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef) { }\r\n\r\n params: LegalDescriptionModalParams;\r\n result: void;\r\n\r\n headerLabel: string;\r\n descToEdit: string;\r\n\r\n ngOnInit() {\r\n this.headerLabel = `Legal description for parcel: ${this.params.parcel.acctNum}`;\r\n this.descToEdit = _.cloneDeep(this.params.parcel.legalDescription);\r\n }\r\n\r\n save() {\r\n this.params.parcel.legalDescription = this.descToEdit;\r\n this.close();\r\n }\r\n\r\n close() {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const PARCEL_INFO_PANEL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'parcel-info-panel.attachments',\r\n tooltipText: 'Attachments'\r\n },\r\n {\r\n helpContentId: 'parcel-info-panel.comments',\r\n tooltipText: 'Comments'\r\n },\r\n {\r\n helpContentId: 'parcel-info-panel.images',\r\n tooltipText: 'Images'\r\n },\r\n {\r\n helpContentId: 'parcel-info-panel.optimus',\r\n tooltipText: 'Research Parcel in Optimus™'\r\n }\r\n]\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { AnnualDetailsNavigationEventService } from 'src/app/Annual-Details/annual-details-event.service';\r\nimport { TaxRatesService } from 'src/app/Assessor-Collector/Tax-Rates/tax.rates.service';\r\nimport { ParcelService } from '../../parcel.service.upgrade';\r\nimport { ParcelCollectorTaxRateSetupModalResult } from '../../TaxRateSetup/parcelCollectorTaxRateSetupModal.component';\r\nimport { TaxAuthorityRate } from '../../TaxRateSetup/parcelTaxRateService';\r\nimport { TaxRateSetupModalLaunchService } from '../../TaxRateSetup/taxRateSetupModalLaunchService';\r\n\r\nexport interface ParcelCollectorTaxAuthorities {\r\n parcelCollector: Weissman.Model.Domain.ParcelCollector;\r\n taxAuthorities: TaxAuthorityRate[];\r\n}\r\n\r\n@Component({\r\n selector: 'collector-tax-rate-area',\r\n template: `\r\n \r\n \r\n \r\n TRA: {{trs.taxRateAreaName}}\r\n ({{trs.taxRateAreaCode}})\r\n \r\n \r\n Rate composed of {{trs.taxAuthorityCount}} tax {{trs.taxAuthorityCount === 1 ? 'authority' : 'authorities'}}\r\n \r\n \r\n Setup tax rates\r\n \r\n `,\r\n styles: [`\r\n .disabled {\r\n color: var(--ace-neutral-300);\r\n cursor: default;\r\n text-decoration: none;\r\n }\r\n `]\r\n})\r\n\r\nexport class CollectorTaxRateAreaComponent {\r\n constructor(private readonly _parcelService: ParcelService,\r\n private readonly _annualDetailsNavigationEventService: AnnualDetailsNavigationEventService,\r\n private readonly _taxRatesService: TaxRatesService,\r\n private readonly _taxRateSetupModalLaunchService: TaxRateSetupModalLaunchService) { }\r\n\r\n @Input() trs: Weissman.Model.Domain.ParcelTaxRateSetupDTO;\r\n @Input() parcelCollector: Weissman.Model.Domain.ParcelCollector;\r\n @Input() parcel: Weissman.Model.Domain.Parcel;\r\n @Input() years: number[];\r\n @Input() editMode: boolean;\r\n\r\n taxAuthorities: TaxAuthorityRate[];\r\n\r\n get hasTaxRateSetup(): boolean {\r\n return !!(this.trs?.taxRateAreaName || this.trs?.taxAuthorityCount > 0);\r\n }\r\n\r\n get shouldDisplay(): boolean {\r\n if(this.editMode) {\r\n // hack for when user adds new collector (hasAvailableTaxSetup is initialized on the collector)\r\n return this.trs ? this.trs.hasAvailableTaxSetup : (this.parcelCollector as any).hasAvailableTaxSetup;\r\n } else {\r\n return this.hasTaxRateSetup;\r\n }\r\n }\r\n\r\n get isAddedCollector(): boolean {\r\n return this.parcelCollector.efAction === 'add';\r\n }\r\n\r\n async launchParcelCollectorTaxRateModal(): Promise {\r\n if(this.isAddedCollector) {\r\n return;\r\n }\r\n\r\n const currentCalendarYear = (new Date()).getFullYear();\r\n const sortedYears = this.years ? [] : null;\r\n\r\n if (this.years?.length > 0) {\r\n for (let i = _.max(this.years) + 4; i >= _.min(this.years) - 5; i--) {\r\n sortedYears.push(i);\r\n }\r\n }\r\n else if (this.years?.length === 0) {\r\n for (let i = currentCalendarYear + 4; i >= currentCalendarYear - 5; i--) {\r\n sortedYears.push(i);\r\n }\r\n }\r\n\r\n const parcelYear = await this._parcelService.getParcelLatestAssessmentYear(this.parcelCollector.parcelID);\r\n const currentYear = parcelYear.year && parcelYear.year > 0 ? parcelYear.year : currentCalendarYear;\r\n\r\n let title = this.parcelCollector.collectorAbbr;\r\n if (this.parcelCollector.collectorBillingScenarioName) {\r\n title = `${title} - ${this.parcelCollector.collectorBillingScenarioName}`;\r\n }\r\n\r\n this._taxRateSetupModalLaunchService.openParcelCollectorTaxRateSetupModal(\r\n this.parcel.parcelID,\r\n this.parcelCollector as any,\r\n title,\r\n sortedYears,\r\n currentYear,\r\n !this.editMode,\r\n this.taxAuthorities\r\n ).subscribe({\r\n next: modalResult => {\r\n // Reflect changes from the modal result in the parcel collector. I've noticed that sometimes the this.parcelCollector\r\n // reference passed in as an argument isn't necessarily the same as the one on this.parcel, so change both.\r\n const affectedParcelCollectors = [this.parcelCollector].concat(\r\n _.filter(this.parcel.parcelCollectors, { parcelCollectorID: this.parcelCollector.parcelCollectorID })\r\n );\r\n\r\n _.forEach(affectedParcelCollectors, pc => this._applyTaxRateSetupModalResult(pc, modalResult));\r\n\r\n this.trs = this.trs || {} as Weissman.Model.Domain.ParcelTaxRateSetupDTO;\r\n\r\n this.trs.hasAvailableTaxSetup = !!(modalResult.taxRateAreaName || modalResult.taxAuthorityCount > 0);\r\n this.trs.taxAuthorityCount = modalResult.taxAuthorityCount;\r\n this.trs.taxRateAreaName = modalResult.taxRateAreaName;\r\n this.trs.taxRateAreaCode = modalResult.taxRateAreaCode;\r\n this.taxAuthorities = modalResult.taxAuthorities;\r\n\r\n if (this.parcelCollector.parcelCollectorID) {\r\n // Refresh the annual grid (tax bill amounts may have changed)\r\n this._annualDetailsNavigationEventService.goToGrid();\r\n }\r\n else {\r\n const parcelCollectorTAs = _.map(affectedParcelCollectors, parcelCollector => {\r\n const taxAuthorities = _.map(modalResult.taxAuthorities, ta => {\r\n ta.efAction = 'add';\r\n return ta;\r\n });\r\n\r\n return {taxAuthorities, parcelCollector};\r\n });\r\n\r\n\r\n this._parcelService.setParcelCollectorTaxAuthorities(parcelCollectorTAs);\r\n }\r\n }\r\n });\r\n }\r\n\r\n private _applyTaxRateSetupModalResult(pc: any, modalResult: ParcelCollectorTaxRateSetupModalResult): void {\r\n pc.rowVersion = modalResult.rowVersion;\r\n pc.taxRateAreaId = modalResult.taxRateAreaId;\r\n pc.taxRateAreaName = modalResult.taxRateAreaName;\r\n pc.taxRateAreaCode = modalResult.taxRateAreaCode;\r\n pc.taxAuthorityCount = modalResult.taxAuthorityCount;\r\n pc.hasTaxRateSetup = !!(modalResult.taxRateAreaName || modalResult.taxAuthorityCount > 0);\r\n }\r\n}\r\n","\r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n

{{parcel.acctNum}}

\r\n
\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{acctNum.accountNumberType.accountNumberDesc}}:{{acctNum.acctNumber}}
Assessee:{{parcel.assesseeName}}
Desc:{{parcel.description}}
Address:\r\n \r\n
Assessor:\r\n \r\n {{parcelAssessor?.abbr}} {{parcelAssessor?.municipalityName}}\r\n \r\n
Taxing District{{parcel.taxingDistrictModel?.displayName}}
Assessment Class(es):\r\n \r\n {{ac.assessmentClass.name}},\r\n \r\n
Collector(s):\r\n
\r\n \r\n {{collector.collectorAbbr}} - {{collector.collectorBillingScenarioName}}\r\n \r\n
\r\n Collector Acct Num: {{collector.collectorAcctNum}}\r\n
\r\n
\r\n \r\n {{ option.collectorPaymentOption.collectorBillName }} Pmt Option: {{option.collectorPaymentOption.name}}\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
Legal Desc:\r\n {{parcel.legalDescription?.substring(0, 50)}}\r\n 50\" (click)=\"showLegalDescriptionDialog()\"\r\n style=\"padding-left: 10px; cursor: pointer;\">more...\r\n
Parent Excluded From Accruals
Exclude From Accruals:\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { Assessor } from 'src/app/Assessor-Collector/assessor.model';\r\nimport { AttachmentModalData } from 'src/app/Attachment/attachment.modal.model';\r\nimport { CommentModalData } from 'src/app/Comments/comments.service';\r\nimport { Address } from 'src/app/Common/Models/common.model';\r\nimport { WeissmanModalService } from 'src/app/Compliance/WeissmanModalService';\r\nimport { AnchorSREF } from 'src/app/UI-Lib/Directives/Anchor-Route/anchorRoute.directive';\r\nimport { HelpContentComponentConfig, HelpService } from 'src/app/UI-Lib/Help-Tooltip';\r\nimport {\r\n AssessorDetailsComponent,\r\n AssessorDetailsComponentParams\r\n} from '../../Assessor-Details/assessorDetails.component';\r\nimport { ParcelService } from '../parcel.service.upgrade';\r\nimport { LegalDescriptionModalComponent, LegalDescriptionModalParams } from './legalDescriptionModal.component';\r\nimport { PARCEL_INFO_PANEL_HELP } from './parcelInfoPanel.component.help';\r\nimport { EntityType } from 'src/app/constants.new';\r\n\r\n\r\n@Component({\r\n selector: 'parcel-info-panel-view',\r\n templateUrl: 'parcelInfoPanelView.component.html',\r\n styleUrls: ['parcelInfoPanelView.component.scss']\r\n})\r\nexport class ParcelInfoPanelViewComponent implements OnInit {\r\n constructor(private readonly _parcelService: ParcelService,\r\n private readonly _helpService: HelpService,\r\n private readonly _modalService: WeissmanModalService) {\r\n }\r\n\r\n @Input() parcelViewDto: Core.ParcelViewDTO;\r\n @Input() stateAllowConsolidating: boolean;\r\n @Input() parcelAssessor: Assessor;\r\n @Input() hasEditPermission: boolean;\r\n @Input() years: number[];\r\n @Input() assessorDetailsRenderer: HelpContentComponentConfig;\r\n @Output() serverActionChange: EventEmitter = new EventEmitter();\r\n\r\n altAcctNums: Weissman.Model.Domain.AccountNumber[];\r\n optimusLinkInfo: { url: string };\r\n analyticsCategory: string = 'parcel';\r\n\r\n get parcel(): Weissman.Model.Domain.Parcel {\r\n return this.parcelViewDto.parcel;\r\n }\r\n\r\n get acctNumHasDoubleSpace(): boolean {\r\n return _.includes(this.parcel.acctNum, ' ');\r\n }\r\n\r\n get address(): Address {\r\n return this.parcel.address as unknown as Address;\r\n }\r\n\r\n get showTaxingDistrict(): boolean {\r\n return this.parcel.propertyTypeID === Core.PropertyTypes.Personal && this.parcelAssessor?.stateID === 16; // Indiana\r\n }\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.parcel) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityType: 'Parcel',\r\n entityName: this.parcel.acctNum,\r\n parentId: this.parcelViewDto.siteId,\r\n parentTypeId: EntityType.Site\r\n } as AttachmentModalData;\r\n }\r\n\r\n get commentsModel(): CommentModalData {\r\n if (!this.parcel) {\r\n return null;\r\n }\r\n\r\n return {\r\n entityID: this.parcel.parcelID,\r\n entityTypeID: Core.EntityTypes.Parcel,\r\n description: `Parcel: ${this.parcel.acctNum}`,\r\n canEdit: this.hasEditPermission\r\n } as CommentModalData;\r\n }\r\n\r\n async ngOnInit() {\r\n this.altAcctNums = _.filter(this.parcel.altAccountNumbers, x => {\r\n if (x === undefined || !x.accountNumberType) {\r\n return false;\r\n }\r\n const desc = x.accountNumberType.accountNumberDesc;\r\n return !(desc[0] === '!' && desc[desc.length - 1] === '!');\r\n });\r\n\r\n this._helpService.setContent(PARCEL_INFO_PANEL_HELP);\r\n\r\n this.serverActionChange.emit(true);\r\n try {\r\n this.optimusLinkInfo = await this._parcelService.getOptimusLinkInfo(this.parcel.parcelID);\r\n } finally {\r\n this.serverActionChange.emit(false);\r\n }\r\n }\r\n\r\n getCollectorSref(collector: Weissman.Model.Domain.ParcelCollector): AnchorSREF {\r\n if (collector.isCompanyCollector) {\r\n return {\r\n target: 'companyCollector',\r\n options: { companyID: this.parcelViewDto.topLevelCompanyId, collectorID: collector.collectorID }\r\n };\r\n } else {\r\n return {\r\n target: 'collector',\r\n options: { stateId: collector.collectorStateID, stateCollectorId: collector.collectorID }\r\n };\r\n }\r\n }\r\n\r\n getTRS(collector: Weissman.Model.Domain.ParcelCollector): Weissman.Model.Domain.ParcelTaxRateSetupDTO {\r\n return _.find(this.parcelViewDto.taxRateSetup, { parcelCollectorId: collector.parcelCollectorID });\r\n }\r\n\r\n async showLegalDescriptionDialog(): Promise {\r\n const modalParams: LegalDescriptionModalParams = {\r\n isEditMode: false,\r\n parcel: this.parcel\r\n };\r\n\r\n await this._modalService.showAsync(LegalDescriptionModalComponent, modalParams, 'ace-modal-dialog modal-lg');\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BaseRepository } from '../Data/base.repository';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { lastValueFrom } from 'rxjs';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ActivityStatusService extends BaseRepository {\r\n constructor(httpClient: HttpClient) {\r\n super(httpClient);\r\n }\r\n\r\n get(): Promise {\r\n return lastValueFrom(this.httpGet('/api/activitystatus/'));\r\n }\r\n\r\n}\r\n\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Parcel Acct Num:\r\n \r\n \r\n \r\n
{{acctNum.accountNumberType.accountNumberDesc}}:\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
Assessee:\r\n \r\n
Desc:\r\n \r\n
Address:\r\n \r\n \r\n
Property Type:\r\n \r\n
Assessor:\r\n \r\n
Taxing District:\r\n \r\n No Taxing Districts for this Assessor\r\n
Assessment Class(es):\r\n \r\n \r\n
Collector(s):\r\n
\r\n
\r\n {{collector.collectorAbbr}}- {{collector.collectorBillingScenarioName}}\r\n \r\n
\r\n
\r\n
Acct Num:
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n {{ option.collectorPaymentOption.collectorBillName }} Pmt Option:\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n
Legal Desc:{{parcel.legalDescription?.substring(0, 50) || 'None'}}\r\n \r\n
Parent Excluded From Accruals
Exclude From Accruals:\r\n \r\n
Status:\r\n \r\n
Sold Date:\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n\r\n\r\n
parcel.inactivatedDateTime\">\r\n
\r\n Activated by {{parcel.activatedBy}}
\r\n Date: {{parcel.activatedDateTime | date:'M/d/YYYY'}}\r\n
\r\n
\r\n Inactivated by {{parcel.inactivatedBy}}
\r\n Date: {{parcel.inactivatedDateTime | date:'M/d/YYYY'}}\r\n
\r\n
\r\n
\r\n
\r\n Inactivated by {{parcel.inactivatedBy}}
\r\n Date: {{parcel.inactivatedDateTime | date:'M/d/YYYY'}}\r\n
\r\n
\r\n Activated by {{parcel.activatedBy}}
\r\n Date: {{parcel.activatedDateTime | date:'M/d/YYYY'}}\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { Assessor } from 'src/app/Assessor-Collector/assessor.model';\r\nimport { BillingScenarioService } from 'src/app/Assessor-Collector/Collector/Billing-Scenario/billingScenario.service';\r\nimport { Address } from 'src/app/Common/Models/common.model';\r\nimport { InstanceRights, RestrictService } from 'src/app/Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\nimport { PropertyTypeService } from 'src/app/Common/Services/propertyType.service.upgrade';\r\nimport { WeissmanModalService } from 'src/app/Compliance/WeissmanModalService';\r\nimport { ParcelCollectorBillInfo, ParcelCollectorBillScenarioInfo, ParcelCollectorPaymentOptionInfo } from 'src/app/Core-Repositories/billingScenario.repository';\r\nimport { HelpContentComponentConfig } from 'src/app/UI-Lib/Help-Tooltip';\r\nimport { MessageBoxButtons, MessageBoxService } from 'src/app/UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { AssessorDetailsComponent, AssessorDetailsComponentParams } from '../../Assessor-Details/assessorDetails.component';\r\nimport { ParcelService } from '../parcel.service.upgrade';\r\nimport { ParcelTaxRateService } from '../TaxRateSetup/parcelTaxRateService';\r\nimport { AddParcelCollectorModalComponent, AddParcelCollectorModalParams } from './addParcelCollectorModal.component';\r\nimport { LegalDescriptionModalParams, LegalDescriptionModalComponent } from './legalDescriptionModal.component';\r\nimport { ActivityStatusService } from 'src/app/Common/Activity/activityStatus.service';\r\n\r\ninterface AvailablePaymentOptionsMap {\r\n [collectorBillScenarioID: number]: {\r\n collectorBillInfo: {\r\n [collectorBillID: number]: ParcelCollectorBillInfo;\r\n }\r\n }\r\n}\r\n\r\n@Component({\r\n selector: 'parcel-info-panel-edit',\r\n templateUrl: 'parcelInfoPanelEdit.component.html',\r\n styleUrls: ['parcelInfoPanelEdit.component.scss']\r\n})\r\n\r\nexport class ParcelInfoPanelEditComponent implements OnInit {\r\n constructor(private readonly _parcelService: ParcelService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _activityStatusService: ActivityStatusService,\r\n private readonly _parcelTaxRateService: ParcelTaxRateService,\r\n private readonly _billingScenarioService: BillingScenarioService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _propertyTypeService: PropertyTypeService) { }\r\n\r\n @Input() parcel: Weissman.Model.Domain.Parcel;\r\n @Input() stateAllowConsolidating: boolean;\r\n @Input() instanceId: number;\r\n @Input() assessorDetailsRenderer: HelpContentComponentConfig;\r\n @Input() assessors: Assessor[];\r\n @Input() ppReturnPreparationAllowed: boolean;\r\n @Input() years: number[];\r\n @Input() taxRateSetup: Weissman.Model.Domain.ParcelTaxRateSetupDTO[];\r\n @Input() reloadAnnualGrid: boolean;\r\n @Output() serverActionChange: EventEmitter = new EventEmitter();\r\n\r\n acctNumTypes: Weissman.Model.Domain.AccountNumberType[];\r\n acctNumToAdd: Weissman.Model.Domain.AccountNumber;\r\n propertyTypes: Weissman.Model.Assessments.PropertyType[];\r\n hasMoveCopyPermission: boolean = false;\r\n parcelAssessor: Assessor;\r\n assessmentClasses: Weissman.Model.Assessments.AssessmentClass[];\r\n availablePaymentOptionsMap: AvailablePaymentOptionsMap = {};\r\n activityStatuses: {\r\n activityStatusId: number;\r\n status: string;\r\n } [];\r\n\r\n async ngOnInit() {\r\n this.parcelAssessor = _.find(this.assessors, {assessorID: this.parcel.assessorID});\r\n this.hasMoveCopyPermission = this._restrictService.hasInstanceRight(InstanceRights.ALLOWMOVECOPY, this.instanceId);\r\n\r\n const promises = [\r\n this._parcelService.getAcctNumberTypes(),\r\n this._propertyTypeService.get(),\r\n this._activityStatusService.get(),\r\n this._billingScenarioService.getByParcelId(this.parcel.parcelID),\r\n this._parcelService.getParcelAssessmentClasses(this.parcel.parcelID)\r\n ];\r\n\r\n const [\r\n acctNumTypes,\r\n propertyTypes,\r\n activityStatuses,\r\n collectorBillingScenarioList,\r\n assessmentClasses\r\n ] = await Promise.all(promises);\r\n\r\n this.acctNumTypes = _.sortBy(acctNumTypes, 'sequence');\r\n this.propertyTypes = propertyTypes;\r\n this.activityStatuses = _.sortBy(activityStatuses, 'status');\r\n this.availablePaymentOptionsMap = this._mapCollectorBillingScenarioList(collectorBillingScenarioList);\r\n this.assessmentClasses = assessmentClasses;\r\n // Typescript hack. I'm not sure why we are mapping these, but they have to be the same type of assessment class\r\n this.parcel.parcelAssessmentClasses = this._mapParcelAssessmentClasses() as unknown as Weissman.Model.Domain.ParcelAssessmentClass[];\r\n }\r\n\r\n get showTaxingDistrict(): boolean {\r\n return this.parcel.propertyTypeID === Core.PropertyTypes.Personal && this.parcelAssessor?.stateID === 16; // Indiana\r\n }\r\n\r\n get nonDeletedParcelCollectors(): Weissman.Model.Domain.ParcelCollector[] {\r\n return _.reject(this.parcel.parcelCollectors, {efAction: 'delete'});\r\n }\r\n\r\n get address(): Address {\r\n return this.parcel.address as unknown as Address;\r\n }\r\n\r\n shouldDisplayAcctNum(acctNum: Weissman.Model.Domain.AccountNumber): boolean {\r\n if (acctNum === undefined || !acctNum.accountNumberType) {\r\n return false;\r\n }\r\n const desc = acctNum.accountNumberType.accountNumberDesc;\r\n return !(desc[0] === '!' && desc[desc.length - 1] === '!');\r\n }\r\n\r\n deleteAcctNum(acctNum: Weissman.Model.Domain.AccountNumber): void {\r\n _.remove(this.parcel.altAccountNumbers, acctNum);\r\n }\r\n\r\n altAcctNumAlreadyAdded(acctNumType: Weissman.Model.Domain.AccountNumberType): boolean {\r\n return _.some(this.parcel.altAccountNumbers, {\r\n accountNumberTypeID: acctNumType.accountNumberTypeID\r\n });\r\n }\r\n\r\n enterAltAcctNumToAdd(): void {\r\n const acctNumType = _.chain(this.acctNumTypes)\r\n .reject(type => {\r\n return this.altAcctNumAlreadyAdded(type);\r\n })\r\n .minBy('sequence')\r\n .value();\r\n\r\n this.acctNumToAdd = {\r\n accountNumberTypeID: acctNumType.accountNumberTypeID,\r\n acctNumber: ''\r\n } as Weissman.Model.Domain.AccountNumber;\r\n }\r\n\r\n\r\n cancelAddAcctNum(): void {\r\n this.acctNumToAdd = null;\r\n }\r\n\r\n addAltAcctNum(): void {\r\n this.acctNumToAdd.accountNumberType = _.find(this.acctNumTypes, {\r\n accountNumberTypeID: this.acctNumToAdd.accountNumberTypeID\r\n });\r\n\r\n this.parcel.altAccountNumbers.push(this.acctNumToAdd);\r\n\r\n this.cancelAddAcctNum();\r\n }\r\n\r\n onPropertyTypeChange(): void {\r\n const message = 'The following may be impacted: parcel\\'s assessment class(es), assessment components, budget assessment components, tax bill projections, task responsibilities, appeal deadlines, and filing deadlines.';\r\n this._showWarningIfAnnualData(message);\r\n }\r\n\r\n onAssessorChanged(): void {\r\n this.parcelAssessor = _.find(this.assessors, {assessorID: this.parcel.assessorID});\r\n this.parcel.taxingDistrictId = null;\r\n this.reloadAnnualGrid = true;\r\n\r\n const message = 'The following may be impacted: parcel’s collectors, assessments, tax bills, tax rate area for parcel collector, compliance filings, tasks assigned to juris spec, and budgets. Refunds and appeals will appear under the new assessor and/or collector. New parcel collector(s) will need to be added.';\r\n this._showWarningIfAnnualData(message);\r\n }\r\n\r\n async showLegalDescriptionDialog(): Promise {\r\n const modalParams: LegalDescriptionModalParams = {\r\n isEditMode: true,\r\n parcel: this.parcel\r\n };\r\n\r\n this._modalService.showAsync(LegalDescriptionModalComponent, modalParams, 'ace-modal-dialog modal-lg');\r\n }\r\n\r\n getCollectorPaymentOptionInfo (collector: Weissman.Model.Domain.ParcelCollector,\r\n option: Weissman.Model.Domain.ParcelCollectorPaymentOption): ParcelCollectorPaymentOptionInfo[] {\r\n return this.availablePaymentOptionsMap[collector.collectorBillScenarioID]?.collectorBillInfo[option.collectorPaymentOption.collectorBillID]?.collectorPaymentOptionInfo;\r\n }\r\n\r\n async deleteParcelCollector(collector: Weissman.Model.Domain.ParcelCollector): Promise {\r\n try {\r\n const msg = `Are you sure you want to remove ${collector.collectorAbbr}? Removing a parcel collector will remove all tax bill tasks which are not currently obtained.`;\r\n await this._messageBoxService.confirm(msg);\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n _.remove(this.parcel.parcelCollectors, { collectorID: collector.collectorID });\r\n\r\n if (collector.efAction !== 'add') {\r\n collector.efAction = 'delete';\r\n }\r\n\r\n this.reloadAnnualGrid = true;\r\n }\r\n\r\n async addParcelCollector(): Promise {\r\n const collectorList = await this._parcelTaxRateService.getCollectorsByParcelId(this.parcel.parcelID);\r\n const addedCollectorIds = _.chain(this.parcel.parcelCollectors)\r\n .reject({efAction: 'delete'})\r\n .map('collectorID')\r\n .value();\r\n\r\n const modalParams: AddParcelCollectorModalParams = {\r\n collectorList,\r\n addedCollectorIds,\r\n hasCompanyCollectors: this.parcel.hasCompanyCollectors,\r\n parcelId: this.parcel.parcelID\r\n };\r\n\r\n const modalResult = await this._modalService.showAsync(AddParcelCollectorModalComponent, modalParams, 'modal-md');\r\n\r\n if(!modalResult) {\r\n return;\r\n }\r\n\r\n const newCollector = modalResult.selectedCollector;\r\n\r\n this.serverActionChange.emit(true);\r\n try {\r\n const allResults = await Promise.all([\r\n this._billingScenarioService.getById(newCollector.collectorBillScenarioID),\r\n // TODO: This could be done more efficiently; we're making a separate API call to determine if\r\n // any available tax authorities exist and using that to determine if we should show a setup\r\n // link. Instead, we should extend an existing collector API endpoint or make a new one that\r\n // would return that along with collector data (similar to the parcel info API call).\r\n this._parcelTaxRateService.getAvailableTaxAuthoritiesByParcel(this.parcel.parcelID, newCollector.collectorID)\r\n ]);\r\n\r\n const billScenario = allResults[0];\r\n const bill = _.find(billScenario.collectorBills, {\r\n collectorBillScenarioID: newCollector.collectorBillScenarioID\r\n }) as any;\r\n\r\n const recordToAdd = {\r\n collectorID: newCollector.collectorID,\r\n collectorAbbr: newCollector.collectorAbbr,\r\n collectorBillScenarioID: newCollector.collectorBillScenarioID,\r\n collectorBillScenarioName: newCollector.collectorBillScenarioName,\r\n parcelID: this.parcel.parcelID,\r\n // collectorPaymentOptionID: newCollector.collectorPaymentOptionID,\r\n allTaxYears: modalResult.applyTo === 'all' ? true : false,\r\n taxYearForward: modalResult.applyTo === 'year' ? modalResult.year : null,\r\n hasAvailableTaxSetup: allResults[1].length > 0,\r\n parcelCollectorPaymentOptions: _.map(modalResult.parcelCollectorPaymentOptions, function (parcelCollectorPaymentOption) {\r\n return {\r\n collectorPaymentOptionID: parcelCollectorPaymentOption.collectorPaymentOptionID,\r\n collectorPaymentOption: _.find(bill.collectorPaymentOptions, { collectorPaymentOptionID: parcelCollectorPaymentOption.collectorPaymentOptionID }),\r\n efAction: 'add'\r\n };\r\n }),\r\n efAction: 'add'\r\n } as unknown as Weissman.Model.Domain.ParcelCollector;\r\n\r\n this.parcel.parcelCollectors.push(recordToAdd);\r\n\r\n this.reloadAnnualGrid = true;\r\n } finally {\r\n this.serverActionChange.emit(false);\r\n }\r\n }\r\n\r\n paymentOptionChanged(option: Weissman.Model.Domain.ParcelCollectorPaymentOption) {\r\n option.efAction = 'update';\r\n }\r\n\r\n getTRS(collector: Weissman.Model.Domain.ParcelCollector): Weissman.Model.Domain.ParcelTaxRateSetupDTO {\r\n return _.find(this.taxRateSetup, { parcelCollectorId: collector.parcelCollectorID });\r\n }\r\n\r\n deleteParcel(): void {\r\n const message = 'Are you sure you want to delete this parcel? If you choose to proceed, all information under this parcel (assessments, appeals, tax bills etc) will also be removed and can not be recovered.';\r\n const title = `Parcel ${this.parcel.acctNum}`;\r\n\r\n this._messageBoxService.confirm(message, title).then(async () => {\r\n this.serverActionChange.emit(true);\r\n try {\r\n this._parcelService.deleteParcel(this.parcel.parcelID).then(() => {\r\n\r\n // navigationService.disableNavWarning();\r\n this._upgradeNavigationServiceHandler.go('site', {\r\n companyId: +this._upgradeNavigationServiceHandler.getQuerystringParam('companyId'),\r\n siteId: +this._upgradeNavigationServiceHandler.getQuerystringParam('siteId')\r\n });\r\n });\r\n\r\n } finally {\r\n this.serverActionChange.emit(false);\r\n }\r\n });\r\n }\r\n\r\n goToMoveCopy(isMove: boolean): void {\r\n const state = isMove ? 'moveParcel' : 'copyParcel';\r\n\r\n this._upgradeNavigationServiceHandler.go(state, {\r\n companyID: +this._upgradeNavigationServiceHandler.getQuerystringParam('companyId'),\r\n siteID: +this._upgradeNavigationServiceHandler.getQuerystringParam('siteId'),\r\n parcelID: +this._upgradeNavigationServiceHandler.getQuerystringParam('parcelId'),\r\n isInactive: this.parcel.activityStatusID === 0\r\n });\r\n }\r\n\r\n linkedParcelsChanged(linkedParcelInfo: Core.LinkedParcelInfoDTO): void {\r\n this.parcel.excludeFMV = linkedParcelInfo.excludeFmv;\r\n this.parcel.masterParcelAcctNum = linkedParcelInfo.masterParcelAcctNum;\r\n this.parcel.masterParcelId = linkedParcelInfo.masterParcelId;\r\n this.parcel.parcelLinkageID = linkedParcelInfo.parcelLinkageID;\r\n this.parcel.subParcelCount = linkedParcelInfo.subParcelCount;\r\n\r\n // WK-6098\r\n if (linkedParcelInfo.newParcelRowVersion) {\r\n this.parcel.rowVersion = linkedParcelInfo.newParcelRowVersion;\r\n }\r\n }\r\n\r\n private _mapParcelAssessmentClasses(): Weissman.Model.Assessments.AssessmentClass[] {\r\n return _.chain(this.parcel.parcelAssessmentClasses)\r\n .map(parcelAssessmentClass => {\r\n const found = _.find(this.assessmentClasses, {\r\n assessmentClassID: parcelAssessmentClass.assessmentClass.assessmentClassID\r\n });\r\n\r\n return found || parcelAssessmentClass.assessmentClass;\r\n })\r\n .uniqBy('assessmentClassID')\r\n .value();\r\n }\r\n\r\n private _mapCollectorBillingScenarioList(collectorBillingScenarioList: ParcelCollectorBillScenarioInfo[]): AvailablePaymentOptionsMap {\r\n return _.chain(collectorBillingScenarioList)\r\n .groupBy('collectorBillScenarioID')\r\n .mapValues(x => {\r\n const billScenarioInfo = x[0];\r\n const collectorBillInfo = _.chain(billScenarioInfo.collectorBillInfo)\r\n .groupBy('collectorBillID')\r\n .mapValues((y: any) => {\r\n y = y[0];\r\n y.collectorPaymentOptionInfo = _.reject(y.collectorPaymentOptionInfo, { collectorPaymentOptionName: null });\r\n return y;\r\n })\r\n .value() as any;\r\n\r\n return {collectorBillInfo};\r\n })\r\n .value();\r\n }\r\n\r\n private _showWarningIfAnnualData(message: string): void {\r\n if (this.years.length) {\r\n this._messageBoxService.open({\r\n title: '',\r\n message: message,\r\n buttons: MessageBoxButtons.OK\r\n });\r\n }\r\n }\r\n\r\n}","\r\n
\r\n
\r\n

Parcel Info

\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, Inject, Input, OnInit } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { AnnualDetailsNavigationEventService } from 'src/app/Annual-Details/annual-details-event.service';\r\nimport { Assessor } from 'src/app/Assessor-Collector/assessor.model';\r\nimport { AssessorService } from 'src/app/Assessor-Collector/Assessor/assessor-service';\r\nimport { ChangeHistoryModalLaunchService } from 'src/app/Common/Change-History/change-history-modal-launch.service';\r\nimport { CurrentEntityService } from 'src/app/Common/Entity/CurrentEntityService';\r\nimport { InstanceRights, RestrictData, RestrictService } from 'src/app/Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\nimport { EntityTypeIds, RyanInstanceId } from 'src/app/constants.new';\r\nimport { NavigationService } from 'src/app/Layout/navigation.service';\r\nimport { TaskService } from 'src/app/Task/task.service.upgrade';\r\nimport { HelpContentComponentConfig } from 'src/app/UI-Lib/Help-Tooltip';\r\nimport {\r\n MessageBoxButtons,\r\n MessageBoxResult,\r\n MessageBoxService\r\n} from 'src/app/UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { ActivityService } from '../../../Common/Activity/activity.service';\r\nimport {\r\n AssessorDetailsComponent,\r\n AssessorDetailsComponentParams\r\n} from '../../Assessor-Details/assessorDetails.component';\r\nimport { InstanceRepository } from '../../Instance/instance.repository';\r\nimport { ParcelService } from '../parcel.service.upgrade';\r\nimport { ParcelTaxRateService } from '../TaxRateSetup/parcelTaxRateService';\r\nimport { ParcelCollectorTaxAuthorities } from './Tax-Rates/collectorTaxRateArea.component';\r\n\r\n@Component({\r\n selector: 'parcel-info-panel-new',\r\n templateUrl: 'parcelInfoPanel.component.html'\r\n})\r\n\r\nexport class ParcelInfoPanelComponent implements OnInit {\r\n constructor(\r\n private readonly _instanceRepository: InstanceRepository,\r\n private readonly _annualDetailsNavigationEventService: AnnualDetailsNavigationEventService,\r\n private readonly _upgradeNavigationServiceHandler: UpgradeNavigationServiceHandler,\r\n private readonly _assessorService: AssessorService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _taskService: TaskService,\r\n @Inject('$rootScope') private _rootScope: any,\r\n private readonly _parcelService: ParcelService,\r\n private readonly _currentEntityService: CurrentEntityService,\r\n private readonly _parcelTaxRateService: ParcelTaxRateService,\r\n private readonly _changeHistoryModalLaunchService: ChangeHistoryModalLaunchService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _activityService: ActivityService\r\n ) {\r\n }\r\n\r\n @Input() parcelViewDto: Core.ParcelViewDTO;\r\n @Input() stateAllowConsolidating: boolean;\r\n @Input() loadClientServices$: Subject;\r\n @Input() getAnnualGridCallback: (getCompTypesOnly: boolean) => void;\r\n\r\n editMode: boolean = false;\r\n loadingPermissions: boolean = false;\r\n serverAction: boolean = false;\r\n hasEditPermission: boolean = false;\r\n hasInstancePrivateView: boolean = false;\r\n assessors: Assessor[];\r\n parcelAssessor: Assessor;\r\n instanceId: number;\r\n assessorDetailsRenderer: HelpContentComponentConfig;\r\n years: number[];\r\n reloadAnnualGrid: boolean = false;\r\n\r\n private _originalParcel: Weissman.Model.Domain.Parcel;\r\n private _parcelCollectorTaxAuthorities: ParcelCollectorTaxAuthorities[];\r\n private _siteId: number;\r\n\r\n\r\n async ngOnInit() {\r\n this._initParcel();\r\n this._loadPermissions();\r\n this._loadData();\r\n }\r\n\r\n get parcel(): Weissman.Model.Domain.Parcel {\r\n return this.parcelViewDto.parcel;\r\n }\r\n\r\n edit(): void {\r\n this._originalParcel = _.cloneDeep(this.parcel);\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n this.editMode = true;\r\n }\r\n\r\n async save(): Promise {\r\n if (!this.parcel.acctNum) {\r\n this._toastr.error('Please enter Parcel Acct Num');\r\n return;\r\n }\r\n\r\n const missingAcctNum = _.find(this.parcel.altAccountNumbers, { acctNumber: '' });\r\n if (missingAcctNum?.accountNumberType?.accountNumberDesc) {\r\n this._toastr.error(`Please enter ${missingAcctNum.accountNumberType.accountNumberDesc} or delete it`);\r\n return;\r\n }\r\n\r\n const isParcelAcctNumNonAscii = this.parcel.acctNum && !(/^[ -~\\t\\n\\r]+$/.test(this.parcel.acctNum));\r\n if (isParcelAcctNumNonAscii) {\r\n this._toastr.error('Parcel Acct Num contains invalid character(s)');\r\n return;\r\n }\r\n\r\n this.reloadAnnualGrid = this._shouldReloadGridAfterSave() || this.reloadAnnualGrid;\r\n\r\n if (this.parcel.activityStatusID !== this._originalParcel.activityStatusID) {\r\n\r\n if (this.parcel.activityStatusID === 0) {\r\n // wk-2181\r\n // deactivating parcel - checking if user really can and want to do it\r\n // If there are any incomplete appeal pursuit or refund task series tasks then inform the user\r\n //\t\"This parcel's status cannot be changed to Inactive because there are open appeals or refunds.\".\r\n //\tChange the value in the dropdown back to its previous value.\r\n //\r\n const checkIfEntityMayBeDeactivatedResult = await this._taskService.checkIfEntityMayBeDeactivated(this.parcel.parcelID, EntityTypeIds.PARCEL);\r\n\r\n if (checkIfEntityMayBeDeactivatedResult.canBeDeactivated === false) {\r\n await this._messageBoxService.open({\r\n title: '',\r\n message: 'This parcel\\'s status cannot be changed to Inactive because there are open appeals or refunds.',\r\n buttons: MessageBoxButtons.OK\r\n });\r\n\r\n //\tChange the value in the dropdown back to its previous value.\r\n this.parcel.activityStatusID = this._originalParcel.activityStatusID;\r\n\r\n } else {\r\n if (checkIfEntityMayBeDeactivatedResult.openPaymentBatchTaskCount > 0) {\r\n await this._messageBoxService.open({\r\n title: '',\r\n message: 'This parcel\\'s status cannot be changed to Inactive because at least some of its batches have open payments.',\r\n buttons: MessageBoxButtons.OK\r\n });\r\n //\tChange the value in the dropdown back to its previous value.\r\n this.parcel.activityStatusID = this._originalParcel.activityStatusID;\r\n }\r\n else {\r\n // this parcel doesn't have any open appeals or refunds, confirm with user\r\n let msg = 'Changing the parcel\\'s status to Inactive will result in all client service responsibilities being changed to N/A. If the parcel is merged in a consolidated relationship, this will be removed. ';\r\n msg += ` This will result in ${checkIfEntityMayBeDeactivatedResult.openFilingTaskCount} filing task(s) `;\r\n msg += ` and ${checkIfEntityMayBeDeactivatedResult.openAssessmentTaskCount} assessment task(s) `;\r\n msg += ` and ${checkIfEntityMayBeDeactivatedResult.openTaxBillTaskCount} tax bill task(s) to no longer be scheduled. `;\r\n msg += ' NO FURTHER WORK OF ANY KIND WILL BE SCHEDULED FOR THIS ENTITY.';\r\n\r\n msg += ' Are you sure you want to proceed?';\r\n\r\n const result = await this._messageBoxService.open({\r\n title: 'Changing parcel\\'s status to Inactive',\r\n message: msg,\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n\r\n if (result === MessageBoxResult.Yes) {\r\n this.parcel.statusDate = new Date();\r\n this.reloadAnnualGrid = true;\r\n return this._saveParcelToAPI();\r\n } else {\r\n // user wants to cancel\r\n //\tChange the value in the dropdown back to its previous value.\r\n this.parcel.activityStatusID = this._originalParcel.activityStatusID;\r\n\r\n }\r\n }\r\n }\r\n } else {\r\n // activity status has been changed, but parcel is not deactivated\r\n this.parcel.statusDate = new Date();\r\n return this._saveParcelToAPI();\r\n }\r\n } else {\r\n // activity status has not been changed; just saving\r\n return this._saveParcelToAPI();\r\n }\r\n }\r\n\r\n async cancel(): Promise {\r\n this.serverAction = true;\r\n\r\n try {\r\n this.parcelViewDto = await this._parcelService.getView(this.parcel.parcelID, false);\r\n this._navigationService.disableNavWarning();\r\n this.editMode = false;\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n launchChangeHistoryModal(): void {\r\n this._changeHistoryModalLaunchService.openChangeHistoryModal(this.parcel.acctNum, this.parcel.parcelID, EntityTypeIds.PARCEL, null);\r\n }\r\n\r\n private async _saveParcelToAPI(): Promise {\r\n this.serverAction = true;\r\n\r\n try {\r\n const savedParcelDTO = await this._parcelService.update(this.parcel);\r\n\r\n await Promise.all(_.map(this._parcelCollectorTaxAuthorities, pc => {\r\n const savedParcelCollector = _.find(savedParcelDTO.parcel.parcelCollectors, {\r\n 'collectorBillScenarioID': pc.parcelCollector.collectorBillScenarioID\r\n }) as any;\r\n\r\n return this._parcelTaxRateService.saveTaxRateSetup(\r\n savedParcelCollector.parcelCollectorID,\r\n savedParcelCollector.rowVersion,\r\n null,\r\n _.map(pc.taxAuthorities, 'taxAuthorityId')\r\n ).then(saveTaxResult => {\r\n savedParcelCollector.rowVersion = saveTaxResult.parcelCollectorRowVersion;\r\n savedParcelCollector.taxAuthorityCount = pc.taxAuthorities.length;\r\n savedParcelCollector.hasTaxRateSetup = true;\r\n savedParcelCollector.taxAuthorities = _.map(pc.taxAuthorities, ta => _.omit(ta, 'efAction'));\r\n });\r\n }));\r\n\r\n this.parcelViewDto = savedParcelDTO;\r\n this.parcelAssessor = _.find(this.assessors, { assessorID: this.parcel.assessorID });\r\n\r\n if (this.reloadAnnualGrid) {\r\n this.reloadAnnualGrid = false;\r\n this._annualDetailsNavigationEventService.refreshActivityData();\r\n this.loadClientServices$.next();\r\n this._annualDetailsNavigationEventService.goToGrid();\r\n this.getAnnualGridCallback(false);\r\n }\r\n\r\n this._navigationService.disableNavWarning();\r\n this.editMode = false;\r\n\r\n this._rootScope.$emit('parcel:parcelInfoChanged', this.parcel);\r\n\r\n } finally {\r\n this.serverAction = false;\r\n this._activityService.clearParcelFilterCacheForSite(this._siteId);\r\n }\r\n }\r\n\r\n private _initParcel(): void {\r\n this._siteId = +this._upgradeNavigationServiceHandler.getQuerystringParam('siteId');\r\n\r\n this._currentEntityService.set(this.parcel, EntityTypeIds.PARCEL);\r\n this._annualDetailsNavigationEventService.yearsChangedEvent$.subscribe(years => this.years = years);\r\n\r\n this.parcel.parcelCollectors = _.map(this.parcel.parcelCollectors, pc => {\r\n pc.parcelCollectorPaymentOptions = _.sortBy(pc.parcelCollectorPaymentOptions, 'collectorBillName');\r\n return pc;\r\n });\r\n\r\n this.parcel.transaction = this.parcel.transaction || {\r\n soldDate: null\r\n } as Weissman.Model.Domain.Transaction;\r\n\r\n this._parcelService.parcelCollectorTaxAuthorities$.subscribe(x => this._parcelCollectorTaxAuthorities = x);\r\n }\r\n\r\n private async _loadPermissions(): Promise {\r\n this.loadingPermissions = true;\r\n\r\n try {\r\n this.instanceId = await lastValueFrom(this._instanceRepository.getEntityInstanceId('parcel', this.parcel.parcelID));\r\n this.hasInstancePrivateView = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, this.instanceId)\r\n || this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW, this.instanceId);\r\n\r\n this.assessorDetailsRenderer = this.instanceId === RyanInstanceId ? {\r\n component: AssessorDetailsComponent,\r\n componentParams: {\r\n stateId: this.parcel.address.stateID,\r\n parcelId: this.parcel.parcelID\r\n },\r\n canHover: true\r\n } : null;\r\n\r\n const restrictionData = {\r\n isCompany: false,\r\n entityId: this._siteId,\r\n roles: [],\r\n flag: Core.AccessRightsEnum.Write\r\n } as RestrictData;\r\n\r\n this.hasEditPermission = await this._restrictService.hasPermission(restrictionData);\r\n } finally {\r\n this.loadingPermissions = false;\r\n }\r\n }\r\n\r\n private async _loadData(): Promise {\r\n this.serverAction = true;\r\n\r\n try {\r\n const assessors = await this._assessorService.getByStateId(this.parcel.address.stateID);\r\n this.assessors = _.sortBy(assessors, 'abbr');\r\n this.parcelAssessor = _.find(this.assessors, { assessorID: this.parcel.assessorID });\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n private _shouldReloadGridAfterSave(): boolean {\r\n const originalIds = _.map(this._originalParcel.parcelAssessmentClasses, 'assessmentClassID');\r\n const editIds = _.map(this.parcel.parcelAssessmentClasses, 'assessmentClassID');\r\n\r\n const haveAssessmentClassesChanged = !!_.xor(originalIds, editIds).length;\r\n\r\n return haveAssessmentClassesChanged\r\n || this.parcel.activityStatusID !== this._originalParcel.activityStatusID\r\n || this.parcel.propertyTypeID !== this._originalParcel.propertyTypeID\r\n || this.parcel.accrualsExclude.excludeFromAccruals !== this._originalParcel.accrualsExclude.excludeFromAccruals;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { AccrualsModule } from '../../Accruals/accruals.module';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { ParcelActivitySummaryComponent } from './Activity/parcel-activity-summary.component';\r\nimport { ParcelActivityService } from './Activity/parcel-activity.service';\r\nimport { AnnualDetailsNavigationEventService } from '../../Annual-Details/annual-details-event.service';\r\nimport { ComplianceParcelModule } from '../../Compliance/Parcel/parcel.module';\r\nimport { LinkedParcelsComponent } from './Linked-Parcels/linkedParcels.component';\r\nimport { LinkedParcelsEditComponent } from './Linked-Parcels/Linked-Parcels-Edit/linkedParcelsEdit.component';\r\nimport { LinkedParcelsListComponent } from './Linked-Parcels/Linked-Parcels-List/linkedParcelsList.component';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { LinkedParcelsListGridActionCellRendererComponent } from './Linked-Parcels/Linked-Parcels-List/agGridActionCellRenderer.component';\r\nimport { LinkedParcelRepository } from './Linked-Parcels/linkedParcel.repository';\r\nimport { LinkedParcelsAddComponent } from './Linked-Parcels/Linked-Parcels-Add/linkedParcelsAdd.component';\r\nimport { ParcelTypeCellRendererComponent } from './Parcel-Type-Cell-Renderer/parcelTypeCellRenderer.component';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { ParcelReportsSitesComponent } from './Reports-Sites/parcelReportsSites.component';\r\nimport { ParcelReportsSitesListComponent } from './Reports-Sites/Reports-Sites-List/parcelReportsSitesList.component';\r\nimport { LinkedParcelsListGridNameCellRendererComponent } from './Linked-Parcels/Linked-Parcels-List/agGridNameCellRenderer.component';\r\nimport { ParcelReportsSitesListGridNameCellRendererComponent } from './Reports-Sites/Reports-Sites-List/agGridNameCellRenderer.component';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer } from '../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridExtensionsModule } from '../../Compliance/AgGrid/agGridExtensions.module';\r\nimport { ParcelIconModule } from './Icon/parcelIcon.module';\r\nimport { ParcelService } from './parcel.service.upgrade';\r\nimport { ParcelRepository } from '../../Core-Repositories';\r\nimport { AccrualsPanelComponent } from './Accruals/accrualsPanel.component';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { AddParcelCollectorModalComponent } from './Info/addParcelCollectorModal.component';\r\nimport { TempParcelCollectorModalService } from './Info/tempParcelCollectorModal.service';\r\nimport { ParcelInfoPanelComponent } from './Info/parcelInfoPanel.component';\r\nimport { ParcelInfoPanelViewComponent } from './Info/parcelInfoPanelView.component';\r\nimport { CollectorTaxRateAreaComponent } from './Info/Tax-Rates/collectorTaxRateArea.component';\r\nimport { ParcelInfoPanelEditComponent } from './Info/parcelInfoPanelEdit.component';\r\nimport { LegalDescriptionModalComponent } from './Info/legalDescriptionModal.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n ComplianceParcelModule,\r\n AgGridExtensionsModule,\r\n ParcelIconModule,\r\n AccrualsModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n LinkedParcelsListGridActionCellRendererComponent,\r\n ParcelTypeCellRendererComponent,\r\n LinkedParcelsListGridNameCellRendererComponent,\r\n ParcelReportsSitesListGridNameCellRendererComponent,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectedCellRenderer\r\n ]),\r\n TabsModule\r\n ],\r\n declarations: [\r\n ParcelActivitySummaryComponent,\r\n LinkedParcelsComponent,\r\n LinkedParcelsEditComponent,\r\n LinkedParcelsListComponent,\r\n LinkedParcelsListGridActionCellRendererComponent,\r\n LinkedParcelsAddComponent,\r\n ParcelTypeCellRendererComponent,\r\n ParcelReportsSitesComponent,\r\n ParcelReportsSitesListComponent,\r\n LinkedParcelsListGridNameCellRendererComponent,\r\n ParcelReportsSitesListGridNameCellRendererComponent,\r\n AccrualsPanelComponent,\r\n AddParcelCollectorModalComponent,\r\n ParcelInfoPanelComponent,\r\n ParcelInfoPanelViewComponent,\r\n ParcelInfoPanelEditComponent,\r\n CollectorTaxRateAreaComponent,\r\n LegalDescriptionModalComponent\r\n ],\r\n providers: [\r\n ParcelActivityService,\r\n AnnualDetailsNavigationEventService,\r\n LinkedParcelRepository,\r\n ParcelService,\r\n ParcelRepository,\r\n TempParcelCollectorModalService\r\n ]\r\n})\r\nexport class ParcelModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n //Entry components must have only two words, for example: parcelActivity not parcelActivitySummary\r\n //This is due to a bug in angular 1 case formatting where it gets confused with kebab casing with multiple dashes\r\n //And angular 1 will autoconvert camelCase to kebab-case\r\n hybridAdapterUtility.downgradeNg2Provider('ParcelService', ParcelService);\r\n hybridAdapterUtility.downgradeNg2Provider('tempParcelCollectorModalService', TempParcelCollectorModalService);\r\n hybridAdapterUtility.downgradeNg2Component('parcelActivity', ParcelActivitySummaryComponent);\r\n hybridAdapterUtility.downgradeNg2Component('linkedParcels', LinkedParcelsComponent);\r\n hybridAdapterUtility.downgradeNg2Component('linkedParcelsEdit', LinkedParcelsEditComponent);\r\n hybridAdapterUtility.downgradeNg2Component('linkedParcelsAdd', LinkedParcelsAddComponent);\r\n hybridAdapterUtility.downgradeNg2Component('parcelReportsSites', ParcelReportsSitesComponent);\r\n hybridAdapterUtility.downgradeNg2Component('accrualsPanel', AccrualsPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Component('parcelInfoPanelNew', ParcelInfoPanelComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { ModalModule } from 'ngx-bootstrap/modal';\r\nimport { ButtonsModule } from 'ngx-bootstrap/buttons';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { SharedPipesModule } from '../UI-Lib/Pipes/shared-pipes.module';\r\nimport { ReportManagerComponent } from './Manager/report.manager.component';\r\nimport { ReportManagerModalComponent } from './Manager/reportManagerModal.component';\r\nimport { ReportManagerModalService } from './Manager/reportManagerModal.service';\r\nimport { ReportManagerSelectEntitiesComponent } from './Manager/select.entities.component';\r\nimport { SaveReportModalComponent } from './Modals/save-report.component';\r\nimport { ReportManagerService } from './Manager/report.manager.service';\r\nimport { ReportManagerSelectEntitiesService } from './Manager/select.entities.service';\r\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\r\nimport { FurtherLimitPanelPsrComponent } from './Manager/Further-Limit-Panel/further.limit.panel.psr.component';\r\nimport { FurtherLimitPanelBudgetComponent } from './Manager/Further-Limit-Panel/further.limit.panel.budget.component';\r\nimport { FormatOutputPanelBudgetComponent } from './Manager/Format-Output-Panel/format.output.panel.budget.component';\r\nimport { FormatOutputPanelPsrComponent } from './Manager/Format-Output-Panel/format.output.panel.psr.component';\r\nimport { FurtherLimitPanelMaarComponent } from './Manager/Further-Limit-Panel/further.limit.panel.maar.component';\r\nimport { FurtherLimitPanelProgressStatusComponent } from './Manager/Further-Limit-Panel/further.limit.panel.progress.status.component';\r\nimport { FurtherLimitPanelSiteComponent } from './Manager/Further-Limit-Panel/further.limit.panel.site.component';\r\nimport { ReportOrderByComponent } from './Manager/Format-Output-Panel/Order-By/reportOrderBy.component';\r\nimport { FormatOutputPanelSiteComponent } from './Manager/Format-Output-Panel/format.output.panel.site.component';\r\nimport { ReportDetailOptionsComponent } from './Manager/Format-Output-Panel/report.detail.options.component';\r\nimport { FurtherLimitPanelSchedulesSummaryComponent } from './Manager/Further-Limit-Panel/further.limit.panel.schedules.summary.component';\r\nimport { FormatOutputPanelSchedulesSummaryComponent } from './Manager/Format-Output-Panel/format.output.panel.schedules.summary.component';\r\nimport { FurtherLimitPanelAssetDetailComponent } from './Manager/Further-Limit-Panel/further.limit.panel.asset.detail.component';\r\nimport { ReturnModule } from '../Compliance/Return/return.module';\r\nimport { FormatOutputPanelAssetDetailComponent } from './Manager/Format-Output-Panel/format.output.panel.asset.detail.component';\r\nimport { FurtherLimitPanelUserActivityComponent } from './Manager/Further-Limit-Panel/further.limit.panel.user.activity.component';\r\nimport { FormatOutputPanelUserActivityComponent } from './Manager/Format-Output-Panel/format.output.panel.user.activity.component';\r\nimport { ReportingService } from './reporting.service';\r\nimport { FurtherLimitPanelBudgetVarianceComponent } from './Manager/Further-Limit-Panel/further.limit.panel.budget.variance.component';\r\nimport { FormatOutputPanelBudgetVarianceComponent } from './Manager/Format-Output-Panel/format.output.panel.budget.variance.component';\r\nimport {\r\n FurtherLimitPanelSupportInstanceEscalationActivityComponent\r\n} from './Manager/Further-Limit-Panel/further.limit.panel.support.instance.escalation.activity.component';\r\nimport {\r\n FormatOutputPanelSupportInstanceEscalationActivityComponent\r\n} from './Manager/Format-Output-Panel/format.output.panel.support.instance.escalation.activity.component';\r\n\r\n//const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BrowserAnimationsModule,\r\n TabsModule,\r\n ModalModule,\r\n ButtonsModule,\r\n PopoverModule,\r\n TooltipModule,\r\n ReturnModule\r\n ],\r\n declarations: [\r\n ReportManagerComponent,\r\n SaveReportModalComponent,\r\n ReportManagerSelectEntitiesComponent,\r\n FurtherLimitPanelPsrComponent,\r\n FurtherLimitPanelBudgetComponent,\r\n FurtherLimitPanelMaarComponent,\r\n FurtherLimitPanelProgressStatusComponent,\r\n FormatOutputPanelPsrComponent,\r\n FormatOutputPanelBudgetComponent,\r\n FurtherLimitPanelSiteComponent,\r\n ReportOrderByComponent,\r\n FormatOutputPanelSiteComponent,\r\n ReportDetailOptionsComponent,\r\n ReportManagerModalComponent,\r\n FurtherLimitPanelSchedulesSummaryComponent,\r\n FormatOutputPanelSchedulesSummaryComponent,\r\n FurtherLimitPanelAssetDetailComponent,\r\n FormatOutputPanelAssetDetailComponent,\r\n FurtherLimitPanelUserActivityComponent,\r\n FormatOutputPanelUserActivityComponent,\r\n FurtherLimitPanelBudgetVarianceComponent,\r\n FormatOutputPanelBudgetVarianceComponent,\r\n FurtherLimitPanelSupportInstanceEscalationActivityComponent,\r\n FormatOutputPanelSupportInstanceEscalationActivityComponent\r\n ],\r\n providers: [ReportManagerService, ReportManagerModalService, ReportManagerSelectEntitiesService, ReportingService],\r\n exports: [ReportManagerSelectEntitiesComponent]\r\n})\r\nexport class ReportingModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n //Entry components must have only two words, for example: parcelActivity not parcelActivitySummary\r\n //This is due to a bug in angular 1 case formatting where it gets confused with kebab casing with multiple dashes\r\n //And angular 1 will autoconvert camelCase to kebab-case\r\n hybridAdapterUtility.downgradeNg2Component('reportManager', ReportManagerComponent);\r\n\r\n hybridAdapterUtility.downgradeNg2Provider('reportingService', ReportingService);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { RolesListComponent } from './roles.list.component';\r\n\r\n@NgModule({\r\n imports: [ WeissmanSharedModule ],\r\n declarations: [ RolesListComponent ],\r\n exports: [ RolesListComponent ]\r\n})\r\nexport class RoleModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('rolesList', RolesListComponent);\r\n }\r\n}\r\n","
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n\r\n","import { Component, ElementRef, forwardRef, Input, ViewChild } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { TimerService } from '../../../../UI-Lib/Utilities';\r\n\r\n@Component({\r\n selector: 'auto-populate-input',\r\n templateUrl: './autoPopulateInput.component.html',\r\n styleUrls: ['./autoPopulateInput.component.scss'],\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => AutoPopulateInputComponent),\r\n multi: true\r\n }\r\n ]\r\n})\r\nexport class AutoPopulateInputComponent implements ControlValueAccessor {\r\n constructor(private readonly _timerService: TimerService) {\r\n }\r\n\r\n @Input() inputClass: string;\r\n @Input() isDateInput: boolean;\r\n @Input() idpResults: string[] = [];\r\n @Input() currentDocument: Core.IntakeItemInfo;\r\n\r\n @ViewChild('testEl') testEl: ElementRef;\r\n\r\n value: string;\r\n disabled: boolean;\r\n\r\n showIdpMenu: boolean;\r\n idpButtonHovered: boolean;\r\n idpMenuHovered: boolean;\r\n\r\n // ControlValueAccessor methods\r\n onChange: (val: string) => void;\r\n onTouched: () => void;\r\n\r\n inputMask = (value: string): string => this.isDateInput ? '0000' : '';\r\n\r\n writeValue(value: string): void {\r\n this.value = value;\r\n }\r\n\r\n setDisabledState(disabled: boolean): void {\r\n this.disabled = disabled;\r\n }\r\n\r\n next(): void {\r\n this.onChange((this.value && this.value.trim()) || '');\r\n this.onTouched();\r\n }\r\n\r\n registerOnChange(fn: (val: string) => void): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: () => void): void {\r\n this.onTouched = fn;\r\n }\r\n\r\n setSingleIdpValue(): void {\r\n if (this.idpResults.length === 1) {\r\n this.writeValue(this.idpResults[0]);\r\n this.next();\r\n }\r\n }\r\n\r\n inputValueChanged(value: string): void {\r\n this.writeValue(value);\r\n this.next();\r\n }\r\n\r\n buttonHoverOut(): void {\r\n this.idpButtonHovered = false;\r\n this._closeMenu();\r\n }\r\n\r\n menuHoverOut(): void {\r\n this.idpMenuHovered = false;\r\n this._closeMenu();\r\n }\r\n\r\n menuFocusIn(): void {\r\n this.showIdpMenu = true;\r\n }\r\n\r\n menuFocusOut(): void {\r\n this.showIdpMenu = false;\r\n this.idpButtonHovered = false;\r\n this.idpMenuHovered = false;\r\n }\r\n\r\n keyedSelection(event: KeyboardEvent): void {\r\n event.stopPropagation();\r\n switch (event.key) {\r\n case 'ArrowDown':\r\n const nextIndex = this.idpResults.findIndex(x => x === this.value) + 1;\r\n if (nextIndex < this.idpResults.length) {\r\n this.writeValue(this.idpResults[nextIndex]);\r\n }\r\n break;\r\n case 'ArrowUp':\r\n const previousIndex = this.idpResults.findIndex(x => x === this.value) - 1;\r\n if (previousIndex >= 0) {\r\n this.writeValue(this.idpResults[previousIndex]);\r\n this.testEl.nativeElement.querySelector(`#idpValue-${previousIndex}`).focus();\r\n }\r\n break;\r\n case 'Enter':\r\n event.preventDefault();\r\n this.menuFocusOut();\r\n this.writeValue(this.value);\r\n this.next();\r\n break;\r\n case 'Escape':\r\n this.menuFocusOut();\r\n break;\r\n }\r\n }\r\n\r\n private _closeMenu(): void {\r\n this._timerService.setTimeout(() => {\r\n if (!this.idpButtonHovered && !this.idpMenuHovered) {\r\n this.showIdpMenu = false;\r\n this.idpButtonHovered = false;\r\n this.idpMenuHovered = false;\r\n }\r\n });\r\n }\r\n}\r\n","
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Client Instance{{ currentDocument.clientInstanceName }}
\r\n {{ filter.name }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n Results\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n \r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n","import {\r\n Component,\r\n EventEmitter,\r\n HostListener,\r\n Input,\r\n OnChanges,\r\n OnInit,\r\n Output, SimpleChanges, ViewChild\r\n} from '@angular/core';\r\nimport { BsDropdownDirective } from 'ngx-bootstrap/dropdown';\r\nimport { ProcessingService } from '../../../Processing/processing.service.upgrade';\r\nimport { SearchService } from '../../search.service';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { PropertyTypeService } from '../../../Common/Services/propertyType.service.upgrade';\r\nimport { QuickCriteria, QuickCriteriaFilter, QuickResultType } from './quickCriteria.model';\r\n\r\n@Component({\r\n selector: 'quick-search-criteria',\r\n templateUrl: './quickSearchCriteria.component.html'\r\n})\r\nexport class QuickSearchCriteriaComponent implements OnInit, OnChanges {\r\n constructor(private readonly _propertyTypeService: PropertyTypeService,\r\n private readonly _processingService: ProcessingService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _searchService: SearchService\r\n ) { }\r\n\r\n @Input() criteria: QuickCriteria;\r\n @Input() isDocumentProcessing: boolean;\r\n @Input() resultTypes: QuickResultType[];\r\n @Input() currentDocument: any;\r\n @Input() isOpen: boolean;\r\n\r\n @Output() criteriaChange: EventEmitter = new EventEmitter();\r\n @Output() search: EventEmitter = new EventEmitter();\r\n\r\n states = [];\r\n propertyTypes = [];\r\n\r\n @HostListener('keydown.enter') onEnterPressed() {\r\n this.search.emit(true);\r\n }\r\n\r\n @ViewChild('dropdown') bsDropdown: BsDropdownDirective;\r\n\r\n ngOnInit(): void {\r\n this._propertyTypeService.get()\r\n .then(result => {\r\n result.unshift({\r\n propertyTypeID: '',\r\n propTypeAbbr: ''\r\n });\r\n\r\n this.propertyTypes = result;\r\n });\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.currentDocument && changes.currentDocument.currentValue) {\r\n this.resultTypes = this._processingService.getResultTypesByDocumentType(this.currentDocument.attachmentType);\r\n\r\n if (this.resultTypes.length) {\r\n const foundResultType = this.resultTypes.find(x => x.id === this.currentDocument.attachmentType.defaultResultsEntityTypeID);\r\n\r\n this.criteria.resultType = foundResultType ? foundResultType.type : this.resultTypes[0].type;\r\n }\r\n\r\n this.criteria.activeFilters = this.criteria.activeFilters.map((filter) => {\r\n filter.text = this.currentDocument[filter.field]\r\n || this.currentDocument[filter.resultField]\r\n || filter.text;\r\n\r\n return filter;\r\n });\r\n\r\n this.criteria.inactiveFilters.forEach(filter => {\r\n filter.text = this.currentDocument[filter.field] || this.currentDocument[filter.resultField] || filter.text;\r\n\r\n if (filter.text) {\r\n this.criteria.activeFilters.push(filter);\r\n this.criteria.inactiveFilters = this.criteria.inactiveFilters.filter(x => x !== filter);\r\n }\r\n });\r\n }\r\n if (changes.isOpen && !changes.isOpen.firstChange && !changes.isOpen.currentValue) {\r\n this.bsDropdown.hide();\r\n }\r\n }\r\n\r\n addFilterButtonClicked(): void {\r\n this._productAnalyticsService.logEvent('add-additional-criteria');\r\n }\r\n\r\n addFilter(filter: QuickCriteriaFilter): boolean {\r\n filter.text = '';\r\n\r\n this.criteria.inactiveFilters = this.criteria.inactiveFilters.filter(x => x !== filter);\r\n this.criteria.activeFilters = [...this.criteria.activeFilters, filter];\r\n\r\n const sortedFilters = this.criteria.activeFilters.sort((a, b) => a.sequenceNum - b.sequenceNum);\r\n const sortedIndex = sortedFilters.findIndex(x => x.field === filter.field);\r\n\r\n this._productAnalyticsService.logSequenceEvent('add-new-criteria', 'clickFilter');\r\n this._searchService.focusOnFilter(sortedIndex);\r\n return false;\r\n }\r\n\r\n removeFilter(filter: QuickCriteriaFilter, index: number): void {\r\n this.criteria.activeFilters = this.criteria.activeFilters.filter(x => x !== filter);\r\n this.criteria.inactiveFilters = [...this.criteria.inactiveFilters, filter];\r\n\r\n this._searchService.focusOnFilter(index - 1);\r\n }\r\n\r\n changeResultType(): void {\r\n const entityTypes = ['parcel', 'site', 'company'];\r\n const subEntityTypes = ['filing', 'taxBill', 'assessment', 'appeal'];\r\n\r\n const filterTypes = this.criteria.activeFilters.filter(x => x.text).map(x => x.associatedWith);\r\n\r\n const foundType = [...entityTypes, ...subEntityTypes].find((type) => {\r\n return filterTypes.includes(type) && this.resultTypes.some(x => x.type === type);\r\n });\r\n\r\n if(!foundType || (foundType === 'parcel' && subEntityTypes.includes(this.criteria.resultType))) {\r\n return;\r\n }\r\n\r\n this.criteria.resultType = foundType;\r\n }\r\n\r\n showAnticipated(): boolean {\r\n const anticipatedResultTypes = ['assessment', 'appeal', 'taxBill', 'refund', 'filing'];\r\n\r\n return this.isDocumentProcessing && anticipatedResultTypes.includes(this.criteria.resultType);\r\n }\r\n\r\n addFilterToggled(isOpen: boolean): void {\r\n if (isOpen) {\r\n this._productAnalyticsService.initiateSequenceEvent({\r\n event: 'add-new-criteria',\r\n properties: {\r\n addCriteria: 'no'\r\n }\r\n }, ['clickAdd', 'clickAway'], true);\r\n this._productAnalyticsService.initiateSequenceEvent({\r\n event: 'add-new-criteria',\r\n properties: {\r\n addCriteria: 'yes'\r\n }\r\n }, ['clickAdd', 'clickFilter'], true);\r\n\r\n } else {\r\n this.addFilterClosed();\r\n }\r\n }\r\n\r\n addFilterClosed(): void {\r\n this._productAnalyticsService.logSequenceEvent('add-new-criteria', 'clickAway');\r\n }\r\n\r\n togglePrimaryAcctNumOnly() {\r\n this._productAnalyticsService.logEvent('check-primary-acct-num-only', {\r\n DpPrimaryAcct: this.criteria.primaryAcctNumOnly ? 'yes' : 'no'\r\n });\r\n }\r\n\r\n toggleExcludeInactive() {\r\n this._productAnalyticsService.logEvent('check-exclude-inactive', {\r\n DpExcludeInactive: this.criteria.activeOnly ? 'yes' : 'no'\r\n });\r\n }\r\n\r\n toggleAnticipated() {\r\n this._productAnalyticsService.logEvent('check-anticipated', {\r\n DpAnticipated: this.criteria.anticipated ? 'yes' : 'no'\r\n });\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { WeissmanSharedModule } from '../../../Common/weissman-shared.module';\r\nimport { HelpModule } from '../../../UI-Lib/Help-Tooltip/help.module';\r\nimport { UILibModule } from '../../../UI-Lib/UILib.module';\r\nimport { AutoPopulateInputComponent } from './IDP-Auto-Populate-Input/autoPopulateInput.component';\r\nimport { QuickSearchCriteriaComponent } from './quickSearchCriteria.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n UILibModule,\r\n FormsModule,\r\n BsDropdownModule,\r\n HelpModule,\r\n WeissmanSharedModule\r\n ],\r\n declarations: [\r\n QuickSearchCriteriaComponent,\r\n AutoPopulateInputComponent\r\n ],\r\n exports: [\r\n QuickSearchCriteriaComponent\r\n ]\r\n})\r\nexport class QuickSearchCriteriaModule { }\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { QuickSearchCriteriaComponent } from './Criteria/quickSearchCriteria.component';\r\nimport { QuickSearchCriteriaModule } from './Criteria/quickSearchCriteria.module';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n QuickSearchCriteriaModule\r\n ],\r\n declarations: [],\r\n providers: []\r\n})\r\nexport class QuickSearchModule {\r\n static setupModule(): void {\r\n hybridAdapterUtility.downgradeNg2Component('quickSearchCriteria', QuickSearchCriteriaComponent);\r\n }\r\n}\r\n","\r\n \r\n
\r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { TaskService } from '../../Task/task.service.upgrade';\r\nimport { MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { ProcessingService } from '../processing.service.upgrade';\r\n\r\nexport interface CompleteFileAppealModalParams {\r\n taskIDs: number[];\r\n searchTimestamp: Date;\r\n optionalArgs: { parentCallsService: true }\r\n}\r\n\r\n@Component({\r\n selector: 'app-complete-file-appeal-modal',\r\n templateUrl: './completeFileAppealModal.component.html'\r\n })\r\nexport class CompleteFileAppealModalComponent implements OnInit, IWeissmanModalComponent Promise> {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _taskService: TaskService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _processingService: ProcessingService) {\r\n }\r\n\r\n params: CompleteFileAppealModalParams;\r\n result: () => Promise;\r\n\r\n loading: boolean;\r\n payload = {\r\n taskIDs: [],\r\n filingReference: null,\r\n searchTimestamp: null\r\n };\r\n\r\n async ngOnInit(): Promise {\r\n this.loading = true;\r\n this.payload = {\r\n taskIDs: this.params.taskIDs,\r\n filingReference: null,\r\n searchTimestamp: this.params.searchTimestamp\r\n };\r\n const warning = await this._taskService.validateAssessorStateReqs(this.params.taskIDs);\r\n if (warning) {\r\n await this._messageBoxService.warning(warning);\r\n }\r\n this.loading = false;\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async process(): Promise {\r\n if (this.params.optionalArgs.parentCallsService) {\r\n this.result = () => this._processingService.completeFileAppeal(this.payload);\r\n this.cancel();\r\n }\r\n else {\r\n this.loading = true;\r\n\r\n try {\r\n this.result = await this._processingService.completeFileAppeal(this.payload);\r\n } finally {\r\n this.cancel();\r\n }\r\n }\r\n\r\n //// Code to demonstrate partial success\r\n //console.log(['Faking out completing tasks', this.payload]);\r\n //setTimeout(function () {\r\n // var result = {\r\n // errorResult: null\r\n // };\r\n\r\n // result.actionResults = _.map(this.payload.taskIDs, function (taskID) {\r\n // return {\r\n // taskActionResult: {\r\n // taskID: taskID,\r\n // result: null, // would have value in real-world example\r\n // errorMessage: null,\r\n // isAuthorized: true,\r\n // authorizationReason: 'Assigned User'\r\n // }\r\n // };\r\n // });\r\n\r\n // result.actionResults[0].taskActionResult = {\r\n // taskID: result.actionResults[0].taskActionResult.taskID,\r\n // result: null,\r\n // errorMessage: 'An unexpected error has occurred: [uuid]',\r\n // isAuthorized: true,\r\n // authorizationReason: null\r\n // };\r\n\r\n // $uibModalInstance.close(result);\r\n //}, 500);\r\n }\r\n}\r\n","\r\n
\r\n \r\n
\r\n
\r\n Action:\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n Comment:\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { UserService } from '../../../Account/user.service';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { DocumentExceptionActions, ProcessingExceptionStatus } from '../../../constants.new';\r\nimport { TeamService } from '../../../Team/team.service';\r\nimport { ProcessingService } from '../../processing.service.upgrade';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nexport interface DocumentProcessingExceptionData {\r\n selectedRow?: any;\r\n selectedEntity?: any;\r\n dataEntryJSON?: string;\r\n newDocumentTypeID?: number;\r\n entityDetails?: any;\r\n taskIDs?: number[];\r\n}\r\n\r\nexport interface DocumentProcessingExceptionModalParams {\r\n exceptionData: DocumentProcessingExceptionData;\r\n searchTimestamp: Date;\r\n optionalArgs: { parentCallsService: boolean, isTaxBill: boolean };\r\n instanceId: number\r\n}\r\n\r\n@Component({\r\n selector: 'app-document-processing-exception-modal',\r\n templateUrl: './documentProcessingExceptionModal.component.html'\r\n})\r\nexport class DocumentProcessingExceptionModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _processingService: ProcessingService,\r\n private readonly _teamsService: TeamService,\r\n private readonly _userService: UserService,\r\n private readonly _toastr: ToastrService) {}\r\n\r\n params: DocumentProcessingExceptionModalParams;\r\n result;\r\n\r\n loading: boolean;\r\n taskIDs: number[];\r\n instanceId: number;\r\n commentBody: string;\r\n\r\n disableBounceRejected: boolean;\r\n disableClearException: boolean;\r\n hasExceptionStatus: boolean;\r\n multipleTasks: boolean;\r\n isTaxBill: boolean;\r\n showRequestTaxRateSetups: boolean;\r\n reassign: any = {};\r\n escalate: any = {};\r\n request: any = {};\r\n taxRateSetups: any = {};\r\n actionType: DocumentExceptionActions;\r\n DocumentExceptionActions = DocumentExceptionActions;\r\n rejectedByUser = null;\r\n contactUser = null;\r\n clientInstanceId = null;\r\n intakeItem = null;\r\n\r\n async ngOnInit(): Promise {\r\n this.multipleTasks = !!this.params.exceptionData.taskIDs;\r\n\r\n if (this.multipleTasks) {\r\n this.taskIDs = this.params.exceptionData.taskIDs;\r\n this.loading = true;\r\n\r\n try {\r\n const extraData = await this._processingService.getBulkDocumentExceptionData(this.params.exceptionData.taskIDs);\r\n this.disableBounceRejected = !extraData.showBounceRejectedOption;\r\n this.disableClearException = !extraData.showClearExceptionOption;\r\n if (extraData.rejectorLastName) {\r\n this.rejectedByUser = {\r\n firstName: extraData.rejectorFirstName,\r\n lastName: extraData.rejectorLastName\r\n };\r\n }\r\n if (extraData.contactLastName) {\r\n this.contactUser = {\r\n firstName: extraData.contactFirstName,\r\n lastName: extraData.contactLastName\r\n };\r\n }\r\n this.clientInstanceId = extraData.clientInstanceId;\r\n\r\n if (this.clientInstanceId) {\r\n this.escalate = {\r\n userID: extraData.contactUserId,\r\n teamID: extraData.contactTeamId\r\n };\r\n }\r\n } finally {\r\n this.loading = false;\r\n }\r\n } else {\r\n this.intakeItem = this.params.exceptionData.selectedRow.intakeDocumentInfo;\r\n this.hasExceptionStatus = !!this.params.exceptionData.selectedRow.intakeDocumentInfo.intakeItem.exceptionStatusID;\r\n if (this.intakeItem &&\r\n this.intakeItem.intakeItem &&\r\n this.intakeItem.intakeItem.rejectedByUserID &&\r\n this.intakeItem.intakeItem.exceptionStatusID == ProcessingExceptionStatus.REJECTED) {\r\n const userTeams = await this._teamsService.getAssignableUserTeams(this.intakeItem.intakeItem.rejectedByUserID);\r\n this.rejectedByUser = userTeams.find(ut => ut.isDefault);\r\n }\r\n\r\n if (this.intakeItem && this.intakeItem.intakeBatch.clientInstanceId) {\r\n this.escalate = {\r\n userID: this.intakeItem.contactUser.userID,\r\n teamID: this.intakeItem.contactTeam.teamID\r\n };\r\n }\r\n\r\n this.clientInstanceId = this.intakeItem.intakeBatch.clientInstanceId;\r\n }\r\n\r\n this.isTaxBill = this.params.optionalArgs.isTaxBill;\r\n\r\n if (!this._userService.isRyanInstanceSelected() && this.clientInstanceId) {\r\n this.instanceId = this.clientInstanceId;\r\n this.escalate = {};\r\n }\r\n\r\n this.showRequestTaxRateSetups = this.isTaxBill && this._userService.isRyanInstanceSelected();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save() {\r\n if (this.params.optionalArgs.parentCallsService) {\r\n this.result = () => this.saveShared();\r\n this.cancel();\r\n } else {\r\n this.loading = true;\r\n // I'm pretty sure this.multipleTasks will always be falsey at this point since action views\r\n // now pass in parentCallsService; that said, we really should just refactor this mess so the\r\n // processing modal doesn't depend on parts of the grid\r\n if (this.multipleTasks) {\r\n const result = await this.saveShared();\r\n if (result) {\r\n this.result = result;\r\n }\r\n this.cancel();\r\n } else {\r\n try {\r\n await this.saveShared();\r\n this._toastr.success('Item Updated', 'Item was successfully updated');\r\n this.result = this.actionType;\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.loading = false;\r\n }\r\n }\r\n }\r\n }\r\n\r\n isValid() {\r\n if (!this.actionType) {\r\n return false;\r\n } else if ((this.actionType === DocumentExceptionActions.REASSIGN_ITEM && !this.reassign.userID)\r\n || (this.actionType === DocumentExceptionActions.ESCALATE_ITEM && !(this.escalate.userID || this.intakeItem && this.intakeItem.clientInstanceId || this.clientInstanceId))\r\n || (this.actionType === DocumentExceptionActions.REQUEST_TAX_RATE_SETUPS && !this.taxRateSetups.userID)\r\n || (this.actionType === DocumentExceptionActions.REQUEST_RESEARCH && !this.request.userID)) {\r\n return false;\r\n }\r\n\r\n return true;\r\n }\r\n\r\n createComment() {\r\n this.commentBody = '';\r\n\r\n switch(this.actionType) {\r\n case DocumentExceptionActions.REASSIGN_ITEM:\r\n if(this.reassign && !_.isEmpty(this.reassign.assignee)) {\r\n this.commentBody = `Reassigned item to ${ this.reassign.assignee.firstName } ${ this.reassign.assignee.lastName }.`;\r\n }\r\n break;\r\n case DocumentExceptionActions.ESCALATE_ITEM:\r\n if(this.escalate && !_.isEmpty(this.escalate.assignee)) {\r\n this.commentBody = `Escalated item to ${ this.escalate.assignee.firstName } ${ this.escalate.assignee.lastName }.`;\r\n }\r\n break;\r\n case DocumentExceptionActions.REQUEST_RESEARCH:\r\n if(this.request && !_.isEmpty(this.request.assignee)) {\r\n this.commentBody = `Research requested from ${ this.request.assignee.firstName } ${ this.request.assignee.lastName }.`;\r\n }\r\n break;\r\n case DocumentExceptionActions.REQUEST_TAX_RATE_SETUPS:\r\n if(this.taxRateSetups && !_.isEmpty(this.taxRateSetups.assignee)) {\r\n this.commentBody = `Tax rate setups requested from ${ this.taxRateSetups.assignee.firstName } ${ this.taxRateSetups.assignee.lastName }.`;\r\n }\r\n break;\r\n case DocumentExceptionActions.REJECT_ITEM:\r\n if (this.multipleTasks) {\r\n this.commentBody = `Rejected item to ${ this.contactUser ? (`${this.contactUser.firstName } ${ this.contactUser.lastName}`) : 'contact user' }.`;\r\n }\r\n else {\r\n this.commentBody = `Rejected item to ${ this.intakeItem.contactUser.firstName } ${ this.intakeItem.contactUser.lastName }.`;\r\n }\r\n break;\r\n case DocumentExceptionActions.CLOSE_ITEM:\r\n this.commentBody = 'Closed item (added in error)';\r\n break;\r\n }\r\n }\r\n\r\n saveShared() {\r\n if (this.multipleTasks) {\r\n return this._processingService.processDocumentBulkException({\r\n taskIDs: this.taskIDs,\r\n documentExceptionAction: this.actionType,\r\n newAssignment: this.getNewAssignment(),\r\n commentBody: this.commentBody,\r\n searchTimestamp: this.params.searchTimestamp\r\n\r\n });\r\n } else {\r\n this.checkForChangesInParcel();\r\n\r\n const documentIntakeID = this.intakeItem.intakeItem.intakeItemID;\r\n const taskID = this.params.exceptionData.selectedRow.n10908;\r\n return this._processingService.processDocumentException(documentIntakeID, taskID, this.params.exceptionData.selectedEntity,\r\n this.actionType, this.getNewAssignment(), this.commentBody, this.params.exceptionData.newDocumentTypeID,\r\n this.params.exceptionData.dataEntryJSON,\r\n this.intakeItem.intakeItem.rowVersion, this.intakeItem.parcelChanges);\r\n }\r\n }\r\n\r\n checkForChangesInParcel(): void {\r\n if(!this.isOverridden('assesseeName') && !this.isOverridden('parcelAddress') && !this.isOverridden('collectorAcctNum')) {\r\n this.intakeItem.parcelChanges = null;\r\n }\r\n }\r\n\r\n isOverridden(field: string): boolean {\r\n if(!this.intakeItem.parcelChanges) {\r\n return false;\r\n }\r\n\r\n if(field === 'parcelAddress') {\r\n const addressFields = ['address1', 'address2', 'city', 'zip'];\r\n return !_.isEqual(_.pick(this.intakeItem.parcelChanges.parcelAddress, addressFields), _.pick(this.params.exceptionData.entityDetails.extendedData.parcelAddress, addressFields));\r\n } else {\r\n return !_.isEqual(this.intakeItem.parcelChanges[field], this.params.exceptionData.entityDetails.extendedData[field]);\r\n }\r\n }\r\n\r\n getNewAssignment() {\r\n switch(this.actionType) {\r\n case DocumentExceptionActions.REASSIGN_ITEM:\r\n return {\r\n userID: this.reassign.userID,\r\n teamID: this.reassign.teamID\r\n };\r\n case DocumentExceptionActions.ESCALATE_ITEM:\r\n return {\r\n userID: this.escalate.userID,\r\n teamID: this.escalate.teamID\r\n };\r\n case DocumentExceptionActions.REQUEST_RESEARCH:\r\n return {\r\n userID: this.request.userID,\r\n teamID: this.request.teamID\r\n };\r\n case DocumentExceptionActions.REQUEST_TAX_RATE_SETUPS:\r\n return {\r\n userID: this.taxRateSetups.userID,\r\n teamID: this.taxRateSetups.teamID\r\n };\r\n case DocumentExceptionActions.REJECT_ITEM:\r\n if(!this.multipleTasks) {\r\n return {\r\n userID: this.intakeItem.contactUser.userID,\r\n teamID: this.intakeItem.contactTeam.teamID\r\n };\r\n } else {\r\n return null;\r\n }\r\n case DocumentExceptionActions.BOUNCE_REJECTED:\r\n if(!this.multipleTasks) {\r\n return {\r\n userID: this.rejectedByUser.userID,\r\n teamID: this.rejectedByUser.teamID\r\n };\r\n } else {\r\n return null;\r\n }\r\n default:\r\n return null;\r\n }\r\n }\r\n}\r\n","\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AttachmentService } from '../../../Attachment/attachment.service';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { ProcessingService } from '../../processing.service.upgrade';\r\n\r\nexport interface DuplicateIntakeItem {\r\n taskIDs: number[];\r\n duplicateCount: number;\r\n searchTimestamp: Date;\r\n attachmentTypeID?: number;\r\n}\r\n\r\nexport interface DuplicateIntakeItemModalParams {\r\n isBulk: boolean;\r\n duplicateItem: DuplicateIntakeItem;\r\n optionalArgs: { parentCallsService: true }\r\n}\r\n\r\n@Component({\r\n selector: 'app-duplicate-intake-item-modal',\r\n templateUrl: './duplicateIntakeItemModal.component.html'\r\n})\r\nexport class DuplicateIntakeItemModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _attachmentService: AttachmentService,\r\n private readonly _processingService: ProcessingService) {\r\n }\r\n\r\n params: DuplicateIntakeItemModalParams;\r\n result: () => Promise;\r\n\r\n documentTypeList: Core.AttachmentTypeModel[];\r\n isLoading: boolean = true;\r\n duplicate: DuplicateIntakeItem;\r\n\r\n async ngOnInit(): Promise {\r\n this.duplicate = this.params.duplicateItem;\r\n this.documentTypeList = await this._attachmentService.getAttachmentTypes();\r\n this.isLoading = false;\r\n }\r\n\r\n resetCopyNumber(): void {\r\n if(!this.duplicate.duplicateCount || this.duplicate.duplicateCount <= 0) {\r\n this.duplicate.duplicateCount = 1;\r\n }\r\n }\r\n\r\n checkCopyNumber(): void {\r\n if(this.duplicate.duplicateCount && this.duplicate.duplicateCount.toString().length > 2) {\r\n let newCount = this.duplicate.duplicateCount.toString();\r\n newCount = newCount.substring(0, 2);\r\n\r\n this.duplicate.duplicateCount = parseInt(newCount);\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async save(): Promise {\r\n this.isLoading = true;\r\n if(this.params.isBulk) {\r\n if (this.params.optionalArgs.parentCallsService) {\r\n this.result = () => {\r\n return this._processingService.createDuplicateIntakeItemBulk(this.duplicate);\r\n };\r\n this.cancel();\r\n }\r\n else {\r\n this.result = await this._processingService.createDuplicateIntakeItemBulk(this.duplicate);\r\n this.isLoading = false;\r\n this.cancel();\r\n }\r\n } else {\r\n const result = this._processingService.createDuplicateIntakeItem(this.duplicate);\r\n\r\n if (result) {\r\n this.result = () => result;\r\n }\r\n\r\n this.isLoading = false;\r\n this.cancel();\r\n }\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { FeatureFlagsService } from '../../Common/FeatureFlags/feature-flags-service';\r\nimport { IWeissmanModalComponent } from '../../Compliance/WeissmanModalService';\r\nimport { ReassignModes } from '../../constants.new';\r\nimport { ReassignTaskRequestModel, ReassignUserTaskRequestModel, TaskService } from '../task.service.upgrade';\r\n\r\nexport interface ReassignTaskModalParams {\r\n taskIDs: number[];\r\n reassignMode: ReassignModes;\r\n searchTimestamp: Date;\r\n instanceId: number;\r\n}\r\n\r\nexport interface ReassignTaskUserModel {\r\n taskIds: number[];\r\n searchTimestamp: Date;\r\n}\r\n\r\n@Component({\r\n selector: 'app-reassign-task-modal',\r\n templateUrl: './reassignTaskModal.component.html'\r\n })\r\nexport class ReassignTaskModalComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _featureFlagsService: FeatureFlagsService,\r\n private readonly _taskService: TaskService) {\r\n }\r\n\r\n params: ReassignTaskModalParams;\r\n result: () => Promise;\r\n\r\n user: Core.UserTeamModel;\r\n entityId: number;\r\n entityType: string;\r\n entityIdsMultiselect: number[];\r\n reassignMode: ReassignModes;\r\n ReassignModes = ReassignModes;\r\n\r\n get title(): string {\r\n switch (this.reassignMode) {\r\n case ReassignModes.Default:\r\n return 'Reassign Task(s)';\r\n case ReassignModes.ChangeContact:\r\n return 'Change Contact(s)';\r\n default:\r\n throw new Error(`Unrecognized reassign mode ${ this.reassignMode}`);\r\n }\r\n }\r\n\r\n ngOnInit(): void {\r\n this.reassignMode = this.params.reassignMode;\r\n\r\n if(this._featureFlagsService.featureFlags.enableMultiUserPermissionsCheck){\r\n this.entityIdsMultiselect = this.params.taskIDs;\r\n this.entityType = 'Task';\r\n }\r\n else{\r\n this.entityId = this.params.instanceId;\r\n this.entityType = 'Instance';\r\n }\r\n }\r\n\r\n save(): void {\r\n this.result = () => {\r\n switch (this.reassignMode) {\r\n case ReassignModes.Default:\r\n const reassignRequest: ReassignTaskRequestModel = {\r\n ...structuredClone(this.user),\r\n taskIds: this.params.taskIDs,\r\n searchTimestamp: this.params.searchTimestamp\r\n };\r\n return this._taskService.reassignMany(reassignRequest);\r\n case ReassignModes.ChangeContact:\r\n const changeRequest: ReassignUserTaskRequestModel = {\r\n taskIds: this.params.taskIDs,\r\n searchTimestamp: this.params.searchTimestamp,\r\n userId: this.user.userID,\r\n teamId: this.user.teamID\r\n };\r\n return this._taskService.changeContacts(changeRequest);\r\n default:\r\n throw new Error(`Unrecognized reassign mode ${ this.reassignMode}`);\r\n }\r\n };\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n userChanged(user: Core.UserTeamModel): void {\r\n this.user = user;\r\n }\r\n}\r\n","\r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { BsModalRef, BsModalService } from 'ngx-bootstrap/modal';\r\nimport { BulkOperationResult } from '../../Common/Models/bulk-operation-result.model';\r\nimport { AppealRecommendationTemplateComponent } from './appealRecommendationTemplate.component';\r\n\r\n@Injectable()\r\nexport class AppealRecommendationTemplateModalService {\r\n constructor(private modalService: BsModalService) { }\r\n\r\n modalRef: BsModalRef;\r\n\r\n launchModal(taskIds: number[], instanceId: number): Promise<() => void> {\r\n return new Promise<() => Promise>((resolve, reject) => {\r\n const initialState = {\r\n taskIds: taskIds,\r\n instanceId: instanceId,\r\n callback: (result: () => Promise) => {\r\n resolve(result);\r\n }\r\n };\r\n\r\n this.modalRef = this.modalService.show(AppealRecommendationTemplateComponent, {initialState, class: 'modal-no-max-width modal-xl'});\r\n });\r\n }\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { PaymentBatchService } from '../paymentBatch.service';\r\nimport { sortBy } from 'lodash';\r\nimport { BusyIndicatorService } from 'src/app/Busy-Indicator';\r\n\r\nexport interface AddPaymentsToBatchModalParams {\r\n topLevelCompanyId: number;\r\n taskIds: number[]\r\n}\r\n\r\n@Component({\r\n selector: 'payment-batch-add-payments-to-batch-modal',\r\n template: `\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Batch NumberBatch Type# PaymentsTotal Payment AmountDue DateStatusCompanyDescription
\r\n \r\n {{batch.batchNo}}{{batch.batchTypeName}}{{batch.paymentCount}}{{batch.paymentAmount | currency}}{{batch.earliestDueDate | weissmanDateFormat}}{{batch.batchStatus}}{{batch.company}}{{batch.description}}
\r\n\r\n
\r\n\r\n `\r\n})\r\n\r\nexport class AddPaymentsToBatchModalComponent implements OnInit, IWeissmanModalComponent Promise> {\r\n constructor(private readonly _bsModalRef: BsModalRef,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _paymentBatchService: PaymentBatchService) { }\r\n\r\n params: AddPaymentsToBatchModalParams;\r\n result: () => Promise;\r\n\r\n isSaving: boolean = false;\r\n paymentBatches: Core.PaymentBatchModel[];\r\n paymentBatchIdToAddTo: number;\r\n\r\n async ngOnInit() {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading batches...' });\r\n\r\n try {\r\n this.paymentBatches = await this._paymentBatchService.getAvailablePaymentBatchesForAddPayments(this.params.topLevelCompanyId, this.params.taskIds);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n async save() {\r\n this.result = () => {\r\n return this._paymentBatchService.addPaymentsToBatchByTaskId(this.paymentBatchIdToAddTo, this.params.taskIds);\r\n };\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}","import { Injectable } from '@angular/core';\r\nimport { WeissmanModalService } from 'src/app/Compliance/WeissmanModalService';\r\nimport { AddPaymentsToBatchModalComponent, AddPaymentsToBatchModalParams } from './addPaymentsToBatchModal.component';\r\n\r\n@Injectable()\r\nexport class AddPaymentsToBatchModalService {\r\n constructor(private _modalService: WeissmanModalService) { }\r\n\r\n async launchModal(topLevelCompanyId: number, taskIds: number[]) {\r\n\r\n const params: AddPaymentsToBatchModalParams = { topLevelCompanyId, taskIds };\r\n\r\n return this._modalService.showAsync(AddPaymentsToBatchModalComponent, params, 'modal-lg');\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ColDef, GridApi, GridOptions, RowNode } from 'ag-grid-community';\r\nimport { GridType } from 'angular-gridster2';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { lastValueFrom, Observable, Subject } from 'rxjs';\r\nimport { AppealService } from '../../Annual-Details/Appeals/appeal.service';\r\nimport { AppealApplicationService } from '../../Appeal-Application/appeal.application.service';\r\nimport {\r\n AppealRecommendationTemplateModalService\r\n} from '../../Appeal-Recommendation/Appeal-Recommendation-Template/appealRecommendationTemplateModal.service';\r\nimport { CommentsService } from '../../Comments/comments.service';\r\nimport { CommentsModalService } from '../../Comments/commentsModal.service';\r\nimport { ProductAnalyticsService } from '../../Common/Amplitude/productAnalytics.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { AgGridMultiSelectTracker } from '../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { WeissmanModalService } from '../../Compliance/WeissmanModalService';\r\nimport { ReassignModes, TaskActionViewContextOption } from '../../constants.new';\r\nimport { ActionViewRepository, InvoiceRepository } from '../../Core-Repositories';\r\nimport { ObtainPaymentReceiptTasksRequest } from '../../Core-Repositories/actionView.repository';\r\nimport {\r\n AddPaymentsToBatchModalService\r\n} from '../../Payment-Batch/Add-Payments-To-Batch-Modal/addPaymentsToBatchModal.service';\r\nimport {\r\n ChangeDueDateModalComponent,\r\n ChangeDueDateModalParams\r\n} from '../../Processing/change-due-date.modal.component';\r\nimport {\r\n CompleteFileAppealModalComponent, CompleteFileAppealModalParams\r\n} from '../../Processing/Complete-File-Appeal-Modal/completeFileAppealModal.component';\r\nimport {\r\n DocumentProcessingExceptionModalComponent, DocumentProcessingExceptionModalParams\r\n} from '../../Processing/Documents/Modals/documentProcessingExceptionModal.component';\r\nimport {\r\n DuplicateIntakeItem, DuplicateIntakeItemModalComponent,\r\n DuplicateIntakeItemModalParams\r\n} from '../../Processing/Documents/Modals/duplicateIntakeItemModal.component';\r\nimport {\r\n ProcessAppealWarrantedComponent, ProcessAppealWarrantedParams\r\n} from '../../Processing/Process-Appeal-Warranted-Modal/processAppealWarranted.component';\r\nimport {\r\n ProcessNoAppealComponent,\r\n ProcessNoAppealParams\r\n} from '../../Processing/Process-No-Appeal-Modal/processNoAppeal.component';\r\nimport { ProcessingService } from '../../Processing/processing.service.upgrade';\r\nimport { RetrievalStatusModalService } from '../../Processing/RetrievalStatus/retrieval-status-modal.service';\r\nimport { TransmittalService } from '../../Processing/Transmittal/transmittal.service';\r\nimport { AppealListReportRequest, ReportingService } from '../../Reporting/reporting.service';\r\nimport { MessageBoxService } from '../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport {\r\n ReassignTaskModalComponent,\r\n ReassignTaskModalParams\r\n} from '../Reassign-Task-Modal/reassignTaskModal.component';\r\nimport { TaskService } from '../task.service.upgrade';\r\nimport { ActionViewPersistenceService } from './Action.View.Persistence.Service.upgrade';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nexport interface ActionViewContextMenuItem {\r\n id: TaskActionViewContextOption;\r\n limitMessage?: string | boolean;\r\n function: (taskIDs?: number[], instanceId?: number) => any;\r\n}\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class ActionViewContextMenuService {\r\n constructor(private readonly _weissmanModalService: WeissmanModalService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _taskService: TaskService,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService,\r\n private readonly _appealService: AppealService,\r\n private readonly _appealApplicationService: AppealApplicationService,\r\n private readonly _transmittalService: TransmittalService,\r\n private readonly _commentsService: CommentsService,\r\n private readonly _commentsModalService: CommentsModalService,\r\n private readonly _processingService: ProcessingService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _retrievalStatusModalService: RetrievalStatusModalService,\r\n private readonly _reportingService: ReportingService,\r\n private readonly _appealRecommendationModalService: AppealRecommendationTemplateModalService,\r\n private readonly _addPaymentsToBatchModalService: AddPaymentsToBatchModalService,\r\n private readonly _actionViewRepository: ActionViewRepository,\r\n private readonly _invoiceRepository: InvoiceRepository,\r\n private readonly _navigationServiceHandler: UpgradeNavigationServiceHandler\r\n ) {\r\n }\r\n\r\n private _loadingSubject: Subject = new Subject();\r\n private _loading$: Observable = this._loadingSubject.asObservable();\r\n\r\n private _errors: string[] = [];\r\n private _warningLimit: number = 50;\r\n\r\n private readonly PERMISSION_ERROR_MESSAGE = 'User does not have permission on these items.';\r\n private readonly GENERIC_ERROR_MESSAGE = 'An error has occured processing these tasks.';\r\n private readonly CONCURRENCY_ERROR_MESSAGE = 'Items have been modified since the search was performed. Please refresh the search result.';\r\n\r\n get loading$(): Observable {\r\n return this._loading$;\r\n }\r\n\r\n //Using this to open modals for now, but the rest of the old service should be migrated over\r\n\r\n async openProcessNoAppealModal(taskIDs: number[], searchTimestamp: Date): Promise {\r\n const params: ProcessNoAppealParams = {\r\n taskIDs: taskIDs,\r\n searchTimestamp: searchTimestamp,\r\n updateAppealRecommendation: false\r\n };\r\n return this._weissmanModalService.showAsync(ProcessNoAppealComponent, params, 'modal-lg');\r\n }\r\n\r\n async openProcessAppealWarrantedModal(taskIDs: number[], searchTimestamp: Date): Promise {\r\n const params: ProcessAppealWarrantedParams = {\r\n taskIDs: taskIDs,\r\n searchTimestamp: searchTimestamp,\r\n runWithBuffer: true,\r\n updateAppealRecommendation: false\r\n };\r\n return await this._weissmanModalService.showAsync(ProcessAppealWarrantedComponent, params, 'modal-lg');\r\n }\r\n\r\n async getContextMenu(grid: GridApi, gridTracker: AgGridMultiSelectTracker, gridOptions: GridOptions, searchTimestamp: Date): Promise {\r\n if (gridTracker.getSelectedRowsCount() > 0) {\r\n this._productAnalyticsService.logEvent('select-action-view-tasks', { avTasksSelected: gridTracker.getSelectedRowsCount() });\r\n const menuItems: ActionViewContextMenuItem[] = [{\r\n id: TaskActionViewContextOption.ProcessDocument,\r\n function: async () => {\r\n await this._updateChangedGridRows(grid, gridTracker);\r\n const selectedRows = await this._getSortedSelection(grid, gridTracker);\r\n this._navigationServiceHandler.go('documentProcessing', {\r\n selectedRows,\r\n searchTimestamp: searchTimestamp\r\n });\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.ChangeContact,\r\n limitMessage: 'Are you sure you want to change contacts for #taskcount tasks?',\r\n function: async (taskIDs: number[], instanceId: number) => {\r\n const params: ReassignTaskModalParams = {\r\n taskIDs: taskIDs,\r\n reassignMode: ReassignModes.ChangeContact,\r\n searchTimestamp: searchTimestamp,\r\n instanceId: instanceId\r\n };\r\n const result = await this._weissmanModalService.showAsync(ReassignTaskModalComponent, params, 'modal-lg');\r\n\r\n if (result) {\r\n await this._runModalResult(grid, gridTracker, result, 'Processing contact change...');\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.Reassign,\r\n limitMessage: 'Are you sure you want to reassign #taskcount tasks?',\r\n function: async (taskIDs: number[], instanceId: number) => {\r\n const params: ReassignTaskModalParams = {\r\n taskIDs: taskIDs,\r\n reassignMode: ReassignModes.Default,\r\n searchTimestamp: searchTimestamp,\r\n instanceId: instanceId\r\n };\r\n const result = await this._weissmanModalService.showAsync(ReassignTaskModalComponent, params, 'modal-lg');\r\n\r\n if (result) {\r\n await this._runModalResult(grid, gridTracker, result, 'Reassigning...');\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.AddComment,\r\n function: async (taskIDs: number[]) => {\r\n let title = 'Add comment to ';\r\n if (gridTracker.getSelectedRowsCount() === 1) {\r\n title += ' task';\r\n } else {\r\n title += `${gridTracker.getSelectedRowsCount() } tasks`;\r\n }\r\n const entityData = await this._commentsService.getEntityDataForTasks(taskIDs);\r\n const years = _.uniq(entityData.map(x => x.year));\r\n let defaultYear = years[0];\r\n const multipleYears = years.length > 1;\r\n if (multipleYears) { defaultYear = '(multiple)'; }\r\n const comment = await this._commentsModalService.openAddCommentModal({\r\n title: title,\r\n allowBlank: true,\r\n yearIsRelevant: this._commentsService.yearIsRelevantForEntityTypeID(entityData[0].entityTypeID),\r\n showFull: true,\r\n defaultYear: defaultYear\r\n });\r\n if (comment) {\r\n let entityYearOverrides = null;\r\n if (multipleYears) {\r\n entityYearOverrides = entityData.map(entity => {\r\n return {\r\n entityID: entity.entityID,\r\n entityTypeID: entity.entityTypeID,\r\n year: entity.year\r\n };\r\n });\r\n comment.year = null;\r\n }\r\n this._loadingSubject.next('Saving...');\r\n try {\r\n await this._commentsService.sendTaskComments(taskIDs, comment, entityYearOverrides);\r\n // TODO: We should change the comment API endpoint to return bulk operation data; ideally,\r\n // it would even include new fields so the UI can automatically update the comment column.\r\n // I think that the next four lines would look like:\r\n // .then(processResult);\r\n this._loadingSubject.next(null);\r\n this._toastr.success(`Comment${ gridTracker.getSelectedRowsCount() !== 1 ? 's' : '' } added`);\r\n this._updateChangedGridRows(grid, gridTracker);\r\n } catch(err) {\r\n this._loadingSubject.next(null);\r\n this._toastr.error('An unexpected error has occurred');\r\n }\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.Duplicate,\r\n limitMessage: true,\r\n function: async (taskIDs: number[]) => {\r\n const duplicateItem: DuplicateIntakeItem = {\r\n taskIDs: taskIDs,\r\n duplicateCount: 1,\r\n searchTimestamp: searchTimestamp\r\n };\r\n const params: DuplicateIntakeItemModalParams = {\r\n isBulk: true,\r\n duplicateItem: duplicateItem,\r\n optionalArgs: { parentCallsService: true }\r\n };\r\n const result = await this._weissmanModalService.showAsync(DuplicateIntakeItemModalComponent, params, 'modal-lg');\r\n\r\n if (result) {\r\n await this._runModalResult(grid, gridTracker, result, 'Duplicating...');\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.AppealWarranted,\r\n limitMessage: true,\r\n function: async (taskIDs: number[]) => {\r\n let result = await this.openProcessAppealWarrantedModal(taskIDs, searchTimestamp);\r\n if (result){\r\n result = this._correctForAsyncError(result);\r\n await this._processAddPaymentsToBatchResult(grid, gridTracker, result);\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.AppealNotWarranted,\r\n limitMessage: true,\r\n function: async (taskIDs: number[]) => {\r\n let result = await this.openProcessNoAppealModal(taskIDs, searchTimestamp);\r\n if (result) {\r\n result = this._correctForAsyncError(result);\r\n await this._processAddPaymentsToBatchResult(grid, gridTracker, result);\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.CompleteFileAppeal,\r\n limitMessage: true,\r\n function: async (taskIDs: number[]) => {\r\n const params: CompleteFileAppealModalParams = {\r\n taskIDs: taskIDs,\r\n searchTimestamp: searchTimestamp,\r\n optionalArgs: { parentCallsService: true }\r\n };\r\n const result = await this._weissmanModalService.showAsync(CompleteFileAppealModalComponent, params, 'modal-lg');\r\n if (result) {\r\n await this._runModalResult(grid, gridTracker, result, 'Processing...');\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.DocumentException,\r\n limitMessage: true,\r\n function: async (taskIDs: number[], instanceId: number) => {\r\n let isTaxBill = true;\r\n grid.getModel().forEachNode(x => {\r\n if (gridTracker.isRowSelected(x.data.n10908)) {\r\n isTaxBill = isTaxBill && x.data.f9003 === 'Tax Bill';\r\n }\r\n });\r\n\r\n const params: DocumentProcessingExceptionModalParams = {\r\n exceptionData: { taskIDs: taskIDs },\r\n searchTimestamp: searchTimestamp,\r\n optionalArgs: { parentCallsService: true, isTaxBill: isTaxBill },\r\n instanceId: instanceId\r\n };\r\n const result = await this._weissmanModalService.showAsync(DocumentProcessingExceptionModalComponent, params, 'modal-lg');\r\n\r\n if (result) {\r\n await this._runModalResult(grid, gridTracker, result, 'Processing...');\r\n }\r\n }\r\n },\r\n { id: TaskActionViewContextOption.ChangeAppealDeadline, function: () => this._changeDueDates(grid, gridTracker, searchTimestamp, 9) },\r\n { id: TaskActionViewContextOption.ChangeFilingDeadline, function: () => this._changeDueDates(grid, gridTracker, searchTimestamp, 10) },\r\n {\r\n id: TaskActionViewContextOption.AddPrepareApplicationTasks,\r\n limitMessage: 'Are you sure you want to add up to #taskcount tasks?',\r\n function: async (taskIDs: number[]) => {\r\n this._loadingSubject.next('Adding prepare application tasks...');\r\n try {\r\n const result = await this._appealService.addPrepareApplicationTasks(taskIDs);\r\n await this._processResult(grid, gridTracker, result);\r\n } finally {\r\n this._loadingSubject.next(null);\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.CreatePreviewAppealApplication,\r\n function: async (taskIDs: number[]) => {\r\n this._loadingSubject.next('Loading appeal applications...');\r\n let searchResult = await this._appealApplicationService.searchByTaskIds(taskIDs);\r\n const newKey = (new Date()).getTime();\r\n\r\n let errorResults = searchResult.filter(r => r.errorMessage);\r\n searchResult = searchResult.filter(r => !r.errorMessage);\r\n\r\n const taskIdsNeedingApplications = searchResult\r\n .filter(r => !r.applicationExists)\r\n .map(r => r.taskID);\r\n\r\n const appealIds = searchResult.map(r => r.appealId);\r\n\r\n const callback = () => {\r\n sessionStorage[`AppealApplicationBatch${ newKey}`] = JSON.stringify(appealIds);\r\n this._updateChangedGridRows(grid, gridTracker);\r\n this._navigationServiceHandler.go('appealApplicationBatch', { appealBatchId: newKey });\r\n this._loadingSubject.next(null);\r\n };\r\n\r\n const errorCallback = (errorResult) => {\r\n const results: string[] = _.uniq(errorResult.map(er => er.errorMessage));\r\n this._taskService.showErrorNotificationModal(results, [],\r\n 'The following error or errors were encountered attempting to create appeal applications',\r\n 'The following warning or warnings were encountered attempting to create appeal applications');\r\n this._loadingSubject.next(null);\r\n };\r\n\r\n // Kind of a hack; if we detect that there are some appeals where the user doesn't have permission,\r\n // bail out by creating a result that looks like it came from a bulk API endpoint. This ensures\r\n // the appropriate rows get highlighted in red and that the error message is displayed in a consistent\r\n // way.\r\n const t = searchResult\r\n .filter(r => !r.hasPermission)\r\n .map(r => {\r\n return {\r\n taskID: r.taskID,\r\n errorMessage: 'You do not have permission to edit this appeal'\r\n } as Compliance.AppealApplicationTaskSearchResult;\r\n });\r\n errorResults = [...errorResults, ...t];\r\n\r\n if (errorResults.length > 0) {\r\n try {\r\n await this._processResultPromise(grid, gridTracker, errorResults as any);\r\n } catch(err) {\r\n errorCallback(err.errors);\r\n }\r\n return;\r\n }\r\n\r\n if (taskIdsNeedingApplications.length > 0) {\r\n try {\r\n const processingResult = await this._appealApplicationService.createNewApplicationBulk(taskIdsNeedingApplications);\r\n const finalResult = await this._processResultPromise(grid, gridTracker, processingResult);\r\n if (finalResult.errorResults.length < 1) {\r\n callback();\r\n } else {\r\n errorCallback(finalResult.errorResults);\r\n }\r\n } catch(finalResult) {\r\n errorCallback(finalResult.errors);\r\n }\r\n } else {\r\n callback();\r\n }\r\n }\r\n },\r\n { id: TaskActionViewContextOption.ChangeSubmitEvidenceDate, function: () => this._changeDueDates(grid, gridTracker, searchTimestamp, 11) },\r\n { id: TaskActionViewContextOption.ChangeInformalHearingDate, function: () => this._changeDueDates(grid, gridTracker, searchTimestamp, 12) },\r\n { id: TaskActionViewContextOption.ChangeFormalHearingDate, function: () => this._changeDueDates(grid, gridTracker, searchTimestamp, 13) },\r\n { id: TaskActionViewContextOption.ChangePaymentDueDate, function: () => this._changeDueDates(grid, gridTracker, searchTimestamp, 14) },\r\n { id: TaskActionViewContextOption.ChangeIntakeItemDueDate, function: () => this._changeDueDates(grid, gridTracker, searchTimestamp, 15) },\r\n { id: TaskActionViewContextOption.ChangeComplianceFilingDueDate, function: () => this._changeDueDates(grid, gridTracker, searchTimestamp, 16) },\r\n {\r\n id: TaskActionViewContextOption.Transmit,\r\n limitMessage: true,\r\n function: async (taskIDs: number[]) => {\r\n this._loadingSubject.next('Creating payment packages...');\r\n try {\r\n const result = await this._transmittalService.CreatePaymentPackage(taskIDs);\r\n try {\r\n await this._processResultPromise(grid, gridTracker, result.operationResult);\r\n this._loadingSubject.next(null);\r\n const newKey = (new Date()).getTime();\r\n sessionStorage[`PaymentPackageDrafts${newKey}`] = JSON.stringify(result.packageIDs);\r\n this._navigationServiceHandler.go('paymentPackagesDraft', {\r\n draftID: newKey,\r\n isTransmittal: false,\r\n paymentBatchId: null,\r\n taskId: null\r\n });\r\n } catch (errorResult) {\r\n this._loadingSubject.next(null);\r\n const errors = _.uniq(_.map(_.filter(errorResult.errors, (error) => {\r\n return error.errorMessage;\r\n }), 'errorMessage'));\r\n const warnings = _.uniq(_.map(_.filter(errorResult.errors, (error) => {\r\n return !error.errorMessage;\r\n }), 'warningMessage'));\r\n this._taskService.showErrorNotificationModal(errors, warnings,\r\n 'The following error or errors were encountered attempting to create bill ' +\r\n 'payment packages; please attempt to correct these errors and try again',\r\n 'The following issue or issues were encountered attempting to create bill ' +\r\n 'payment packages; tasks which had issues will require re-review before ' +\r\n 'they can be processed');\r\n //this._toastr.error(errorResult.message, 'Error!');\r\n }\r\n } catch (err) {\r\n console.error(err);\r\n this._toastr.error('An unexpected error has occurred.');\r\n this._loadingSubject.next(null);\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.ReviewPayment,\r\n limitMessage: 'Are you sure you want to complete #taskcount tasks?',\r\n function: async (taskIDs: number[]) => {\r\n this._loadingSubject.next('Updating payment review status...');\r\n // This should probably all be part of the processPaymentReviewed API call, but we want a specific message\r\n // for missing attachment IDs. In the future, we should probably make this message part of the bulk operation\r\n // result and look for it there as part of the payment reviewed call. This works fine for now, but is slightly\r\n // slower.\r\n try {\r\n const result = await this._transmittalService.CheckForMissingAttachments(taskIDs);\r\n if (result.length > 0) {\r\n this._loadingSubject.next(null);\r\n this._toastr.error('One or more payments do not have a bill image associated. A payment must have a bill image associated to be reviewed in an Action View.');\r\n grid.forEachNode((node: RowNode) => {\r\n if (result.includes(node.data.n10908)) {\r\n node.data.error = true;\r\n }\r\n });\r\n this._actionViewPersistenceService.selectionData = await gridTracker.getSelectedRowIds();\r\n grid.redrawRows();\r\n } else {\r\n try {\r\n const processResult = await this._processingService.processPaymentReviewed({\r\n taskIDs: taskIDs,\r\n searchTimestamp: searchTimestamp\r\n });\r\n this._loadingSubject.next(null);\r\n await this._processResult(grid, gridTracker, processResult);\r\n } finally {\r\n this._loadingSubject.next(null);\r\n }\r\n }\r\n } finally {\r\n this._loadingSubject.next(null);\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.ReReviewPayment,\r\n function: async (taskIDs: number[]) => {\r\n try {\r\n // TODO: Maybe shorten this message to less than book length\r\n await this._messageBoxService.confirmYesNo('Payment Transmittal is blocked for any payments which have completed review tasks ' +\r\n 'where the parcel or collector has changed since the task was complete. Once you have verified that the changes ' +\r\n 'do not impact the payment you can mark the Transmit Payment task as reviewed, which will clear the error. Are ' +\r\n `you sure you want to mark ${ (gridTracker.getSelectedRowsCount() === 1) ? 'this task' : (`these ${ gridTracker.getSelectedRowsCount() } tasks`)\r\n } as reviewed?`);\r\n } catch(err) {\r\n return;\r\n }\r\n this._loadingSubject.next('Updating payment review status...');\r\n\r\n try {\r\n const result = await this._transmittalService.ReReview({\r\n taskIDs: taskIDs,\r\n searchTimestamp: searchTimestamp\r\n });\r\n await this._processResult(grid, gridTracker, result);\r\n } finally {\r\n this._loadingSubject.next(null);\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.CreateInvoice,\r\n function: async (taskIDs: number[]) => {\r\n try {\r\n await this._messageBoxService.confirmYesNo((gridTracker.getSelectedRowsCount() === 1) ?\r\n 'Selected Invoice Appeal Task will be marked complete and the related appeal savings converted into a saved ' +\r\n 'contingency invoice ready to process as a draft. Proceed?' :\r\n 'Selected Invoice Appeal Tasks will be marked complete and their related appeal savings converted into saved ' +\r\n 'contingency invoices ready to process as drafts. Proceed?');\r\n } catch(err) {\r\n return;\r\n }\r\n\r\n this._loadingSubject.next('Creating invoices...');\r\n\r\n // TODO: Move this to the invoice service\r\n try {\r\n const result = await lastValueFrom(this._invoiceRepository.getInvoiceByTaskIds(taskIDs));\r\n this._loadingSubject.next(null);\r\n const callback = (resultObject) => {\r\n let showToast = true;\r\n if (resultObject.errorResults && resultObject.errorResults.length > 0) {\r\n // Get unique warningMessage properties out of the resultObject.errorResults array and add them to the errors array\r\n const warnings = _.uniq(_.map(_.filter(resultObject.errorResults, (error) => {\r\n return !error.errorMessage;\r\n }), 'warningMessage'));\r\n\r\n // If we got error messages but no user-friendly warning messages, don't bother with the\r\n // error-notification modal; the toast will be sufficient for that case\r\n if (_.some(warnings)) {\r\n const errors = [];\r\n // If results have 'warningMessage' properties, the API has sent a user-readable message in\r\n // that field; otherwise, there will be an 'errorMessage' property (that we surpress here)\r\n if (_.some(resultObject.errorResults, (errorResult) => !errorResult.warningMessage)) {\r\n errors.push('An unexpected error has occurred');\r\n }\r\n\r\n this._taskService.showErrorNotificationModal(errors, warnings,\r\n 'The following error or errors were encountered attempting to create invoices');\r\n showToast = _.some(resultObject.successfulResults);\r\n }\r\n }\r\n\r\n if (showToast) {\r\n this._toastProcessResult(resultObject);\r\n }\r\n };\r\n\r\n try {\r\n const resultObject = await this._processResultPromise(grid, gridTracker, result.operationResult);\r\n callback(resultObject);\r\n } catch(errorResult) {\r\n callback({\r\n errorResults: errorResult.errors\r\n });\r\n }\r\n } finally {\r\n this._loadingSubject.next(null);\r\n }\r\n }\r\n },\r\n { id: TaskActionViewContextOption.PrepareDraftInvoice, function: () => this._showInvoicePage(grid, gridTracker) },\r\n { id: TaskActionViewContextOption.ReviewDraftInvoice, function: () => this._showInvoicePage(grid, gridTracker) },\r\n { id: TaskActionViewContextOption.PreviewThenTransferInvoice, function: () => this._showInvoicePage(grid, gridTracker) },\r\n { id: TaskActionViewContextOption.PreviewThenTransferUBR, function: () => this._showInvoicePage(grid, gridTracker) },\r\n { id: TaskActionViewContextOption.RequestReliefOfUBR, function: () => this._showInvoicePage(grid, gridTracker) },\r\n {\r\n id: TaskActionViewContextOption.MarkInvoiceUBR,\r\n limitMessage: true,\r\n function: async (taskIDs: number[]) => {\r\n try{\r\n await this._messageBoxService.confirmYesNo('Selected Invoices will have their UBR flag set. Proceed?');\r\n } catch(err) {\r\n return;\r\n }\r\n\r\n this._loadingSubject.next('Editing invoices...');\r\n const result = await lastValueFrom(this._invoiceRepository.bulkMarkUBR(taskIDs));\r\n this._loadingSubject.next(null);\r\n\r\n const handleErrors = (errorResult) => {\r\n const validationErrors = _.map(_.filter(errorResult, 'warningMessage'), 'warningMessage');\r\n\r\n if (_.some(validationErrors)) {\r\n _.forEach(validationErrors, (err) => {\r\n this._toastr.warning(err);\r\n });\r\n }\r\n };\r\n\r\n try {\r\n const processingResult = await this._processResultPromise(grid, gridTracker, result);\r\n handleErrors(processingResult.errorResults);\r\n this._toastProcessResult(processingResult);\r\n } catch(errorResult) {\r\n handleErrors(errorResult.errors);\r\n if (_.some(errorResult.errors, 'errorMessage')) {\r\n this._toastr.error(errorResult.message, 'Error!');\r\n }\r\n } finally {\r\n this._loadingSubject.next(null);\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.TransferInvoice,\r\n limitMessage: true,\r\n function: async (taskIDs: number[]) => this._bulkTransferToRIBS(grid, gridTracker, 'Invoice', taskIDs)\r\n }, {\r\n id: TaskActionViewContextOption.TransferUBR,\r\n limitMessage: true,\r\n function: async (taskIDs: number[]) => this._bulkTransferToRIBS(grid, gridTracker, 'UBR', taskIDs)\r\n }, { id: TaskActionViewContextOption.ChangeInvoiceDueDate, function: () => this._changeDueDates(grid, gridTracker, searchTimestamp, 25) },\r\n {\r\n id: TaskActionViewContextOption.Skip,\r\n limitMessage: true,\r\n function: async (taskIDs: number[]) => {\r\n try {\r\n await this._messageBoxService.confirmYesNo('Skipping a task completes it and marks it as \"skipped\"; no further operations ' +\r\n `will be allowed on any skipped task. Are you sure you want to skip ${\r\n taskIDs.length === 1 ? 'this task' : (`these ${ taskIDs.length } tasks`) }?`);\r\n } catch {\r\n return;\r\n }\r\n\r\n try {\r\n this._loadingSubject.next('Skipping...');\r\n const result = await this._taskService.skipMany(taskIDs);\r\n this._loadingSubject.next(null);\r\n await this._processResult(grid, gridTracker, result);\r\n } catch(err) {\r\n this._loadingSubject.next(null);\r\n this._toastr.error('An unexpected error has ocurred');\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.PerformOCR,\r\n function: async (taskIDs: number[]) => {\r\n try {\r\n await this._messageBoxService.confirmYesNo(`Are you sure you want to perform OCR on ${\r\n taskIDs.length === 1 ? 'this task' : (`these ${ taskIDs.length } tasks`) }?`);\r\n this._loadingSubject.next('Updating tasks to perform OCR...');\r\n } catch(err) {\r\n return;\r\n }\r\n\r\n try {\r\n const result = await this._processingService.performOCR(taskIDs);\r\n this._loadingSubject.next(null);\r\n await this._processResult(grid, gridTracker, result);\r\n } catch(err) {\r\n this._loadingSubject.next(null);\r\n this._toastr.error('An unexpected error has ocurred');\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.PPReturnDataLoaded,\r\n limitMessage: true,\r\n function: async (taskIDs: number[]) => {\r\n try {\r\n await this._messageBoxService.confirmYesNo(`Are you sure you want to update ${\r\n taskIDs.length === 1 ? 'this task' : (`these ${ taskIDs.length } tasks`) }?`);\r\n this._loadingSubject.next('Updating Data Loaded tasks...');\r\n } catch(err) {\r\n return;\r\n }\r\n\r\n try {\r\n const result = await this._taskService.completeMany(taskIDs);\r\n this._loadingSubject.next(null);\r\n await this._processResult(grid, gridTracker, result);\r\n } catch(err) {\r\n this._loadingSubject.next(null);\r\n this._toastr.error('An unexpected error has ocurred');\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.SetDocumentRetrievalStatus,\r\n limitMessage: true,\r\n function: async (taskIDs: number[], instanceId: number) => {\r\n const result = await this._retrievalStatusModalService.launchSetDocumentRetrievalStatusModal(taskIDs, instanceId);\r\n await this._runModalResult(grid, gridTracker, result, 'Processing...');\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.ChangeConfirmHearingDate,\r\n function: () => this._changeDueDates(grid, gridTracker, searchTimestamp, 35)\r\n }, {\r\n id: TaskActionViewContextOption.AddObtainPaymentReceiptTasks,\r\n limitMessage: 'Are you sure you want to add up to #taskcount tasks?',\r\n function: async (taskIDs: number[]) => {\r\n this._loadingSubject.next('Adding obtain payment receipt tasks...');\r\n try {\r\n const result = await this._addObtainPaymentreceiptTasks(taskIDs);\r\n await this._processResult(grid, gridTracker, result);\r\n } finally {\r\n this._loadingSubject.next(null);\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.CompleteObtainPaymentReceiptTasks,\r\n limitMessage: 'Are you sure you want to complete up to #taskcount tasks?',\r\n function: async (taskIDs: number[]) => {\r\n this._loadingSubject.next('Completing obtain payment receipt tasks...');\r\n try {\r\n const result = await this._completeObtainPaymentReceiptTasks(searchTimestamp, taskIDs);\r\n await this._processResult(grid, gridTracker, result);\r\n } finally {\r\n this._loadingSubject.next(null);\r\n }\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.InsertObtainWorkpapersTaskBefore, function: async (taskIDs: number[]) => {\r\n this._loadingSubject.next('Adding obtain workpapers tasks...');\r\n const result = await this._addObtainWorkpapersTasks(taskIDs);\r\n await this._processResult(grid, gridTracker, result);\r\n this._loadingSubject.next(null);\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.GenerateAppealListReport,\r\n function: async (taskIDs: number[]) => {\r\n const request = {\r\n taskIds: taskIDs\r\n } as AppealListReportRequest;\r\n await this._reportingService.runAppealListReport(request);\r\n this._loadingSubject.next(null);\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.AppealRecommendation,\r\n function: async (taskIDs: number[], instanceId: number) => {\r\n const rows = await this._getSortedSelection(grid, gridTracker);\r\n const keyValues = ['Parcel Acct Num', 'Site Name', 'Site State', 'Parcel Assessor', 'Site Class', 'Prop Type', 'Appeal Deadline'].reduce((acc, x) => {\r\n const col: ColDef = gridOptions.columnApi['columnController'].columnDefs.find(c => c.headerName === x);\r\n acc[x] = col ? rows.map(y => y[col.field]) : [];\r\n return acc;\r\n }, {});\r\n this._productAnalyticsService.logEvent('right-click-AV-appeal-recommendation', {\r\n noOfParcels: _.uniq(keyValues['Parcel Acct Num']).length,\r\n noOfSites: _.uniq(keyValues['Site Name']).length,\r\n siteState: _.uniq(keyValues['Site State']),\r\n siteJuris: _.uniq(keyValues['Parcel Assessor']),\r\n siteClass: _.uniq(keyValues['Site Class']),\r\n propertyType: _.uniq(keyValues['Prop Type']),\r\n daysToAppealDeadline: _.uniq(keyValues['Appeal Deadline']),\r\n });\r\n const result = await this._appealRecommendationModalService.launchModal(taskIDs, instanceId);\r\n await this._runModalResult(grid, gridTracker, result, 'Processing...');\r\n }\r\n }, {\r\n id: TaskActionViewContextOption.AddToPaymentBatch,\r\n function: async (taskIDs: number[]) => {\r\n const topLevelCompanyIds: number[] = [];\r\n grid.forEachNode(x => {\r\n if (!topLevelCompanyIds.includes(x.data.n110)) {\r\n topLevelCompanyIds.push(x.data.n110);\r\n }\r\n });\r\n\r\n if(topLevelCompanyIds.length > 1) {\r\n this._toastr.error('Selected Payments must belong to the same Top Level Company.');\r\n\r\n } else if (topLevelCompanyIds.length == 0) {\r\n this._toastr.error('Unable to determine Top Level Company of selected Payments.');\r\n } else {\r\n const result = await this._addPaymentsToBatchModalService.launchModal(topLevelCompanyIds[0], taskIDs);\r\n\r\n if(result) {\r\n await this._runModalResult(grid, gridTracker, result, 'Adding Payments...');\r\n }\r\n }\r\n }\r\n }\r\n ];\r\n\r\n\r\n const itemPayload = await gridTracker.getSelectedRowIds();\r\n\r\n const results = await lastValueFrom(this._actionViewRepository.getTaskContextOptions(itemPayload));\r\n\r\n return results.options.map((contextOption) => {\r\n const menuHandler = _.find(menuItems, { id: contextOption.optionId });\r\n return {\r\n name: contextOption.text,\r\n onClick: async () => {\r\n this._productAnalyticsService.logEvent('select-action-view-right-click-option', { avAction: contextOption.text });\r\n // Shouldn't happen; this will be if we add an operation to the API and don't handle\r\n // it in the UI\r\n if (!menuHandler) {\r\n this._toastr.error('Error: processing is disabled for this operation.');\r\n } else if (menuHandler.limitMessage && gridTracker.getSelectedRowsCount() >= this._warningLimit) {\r\n let message: string;\r\n if (menuHandler.limitMessage === true) {\r\n message = `Are you sure you want to process ${gridTracker.getSelectedRowsCount()} tasks?`;\r\n } else {\r\n // Use the magic string #taskcount to insert the number of selected items into the message\r\n message = menuHandler.limitMessage.replace('#taskcount', `${gridTracker.getSelectedRowsCount()}`);\r\n }\r\n try {\r\n await this._messageBoxService.confirmYesNo(message);\r\n } catch (err) {\r\n return;\r\n }\r\n await menuHandler.function(itemPayload);\r\n } else {\r\n await menuHandler.function(itemPayload, results.singleInstanceId);\r\n }\r\n }\r\n };\r\n });\r\n } else {\r\n return [];\r\n }\r\n }\r\n\r\n hasErrors(): boolean {\r\n return this._errors.length > 0;\r\n }\r\n\r\n clearErrors(): void {\r\n this._errors = [];\r\n }\r\n\r\n private async _getSortedSelection(grid: GridApi, gridTracker: AgGridMultiSelectTracker) {\r\n const rows = [];\r\n grid.forEachNodeAfterFilterAndSort((row) => {\r\n if (gridTracker.isRowSelected(row.id)) {\r\n rows.push(row.data);\r\n }\r\n });\r\n return rows;\r\n }\r\n\r\n private async _runModalResult(grid: GridApi, gridTracker: AgGridMultiSelectTracker, modalResultFunction, loadingText?: string, callback?) {\r\n this._loadingSubject.next(loadingText);\r\n // Most of the time \"callback\" won't be specified, and we'll just want to go right to the default\r\n // \"processResult\" function\r\n try {\r\n let result = await modalResultFunction();\r\n this._loadingSubject.next(null);\r\n result = this._correctForAsyncError(result);\r\n if (callback) {\r\n callback(result);\r\n } else {\r\n // processResult(result);\r\n await this._processAddPaymentsToBatchResult(grid, gridTracker, result);\r\n }\r\n } catch(err) {\r\n this._loadingSubject.next(null);\r\n this._toastr.error('An unexpected error has occurred');\r\n }\r\n }\r\n\r\n private async _changeDueDates(grid: GridApi, gridTracker: AgGridMultiSelectTracker, searchTimestamp, optionID: number): Promise {\r\n if (gridTracker.getSelectedRowsCount() >= this._warningLimit) {\r\n try {\r\n await this._messageBoxService.confirmYesNo(`Are you sure you want to change the due dates of ${gridTracker.getSelectedRowsCount()} tasks?`);\r\n } catch(err) {\r\n return;\r\n }\r\n }\r\n\r\n const taskIDs = await gridTracker.getSelectedRowIds();\r\n const params: ChangeDueDateModalParams = {\r\n taskIDs,\r\n optionID,\r\n searchTimestamp,\r\n parentCallsService: true\r\n };\r\n const result = await this._weissmanModalService.showAsync(ChangeDueDateModalComponent, params, 'modal-lg');\r\n if (result) {\r\n await this._runModalResult(grid, gridTracker, result, 'Processing date change...');\r\n }\r\n }\r\n\r\n private _addObtainPaymentreceiptTasks(taskIds: number[]): Promise {\r\n return lastValueFrom(this._actionViewRepository.addObtainPaymentreceiptTasks(taskIds));\r\n }\r\n\r\n private _addObtainWorkpapersTasks(taskIds: number[]): Promise {\r\n return lastValueFrom(this._actionViewRepository.addObtainWorkpapersTasks(taskIds));\r\n }\r\n\r\n private _completeObtainPaymentReceiptTasks(searchTimestamp: Date, taskIds: number[]): Promise {\r\n const payload: ObtainPaymentReceiptTasksRequest = {\r\n taskIDs: taskIds,\r\n searchTimestamp: searchTimestamp\r\n };\r\n return lastValueFrom(this._actionViewRepository.completeObtainPaymentReceiptTasks(payload));\r\n }\r\n\r\n private async _showInvoicePage(grid: GridApi, gridTracker: AgGridMultiSelectTracker): Promise {\r\n const taskIds = await gridTracker.getSelectedRowIds();\r\n await this._updateChangedGridRows(grid, gridTracker);\r\n const newKey = (new Date()).getTime();\r\n sessionStorage[`InvoiceDrafts${ newKey}`] = JSON.stringify(taskIds);\r\n this._navigationServiceHandler.go('processInvoice', { draftId: newKey });\r\n }\r\n\r\n private async _bulkTransferToRIBS(grid: GridApi, gridTracker: AgGridMultiSelectTracker, label: string, taskIDs: number[]): Promise {\r\n try {\r\n await this._messageBoxService.confirmYesNo(`Selected ${ label }s will be transferred to RIBS. Proceed?`);\r\n } catch(err) {\r\n return;\r\n }\r\n\r\n this._loadingSubject.next('Transferring invoices...');\r\n try {\r\n // TODO: Move this to the invoice service\r\n const result = await lastValueFrom(this._invoiceRepository.bulkTransferToRIBS(taskIDs));\r\n this._loadingSubject.next(null);\r\n const handleErrors = (errorResult) => {\r\n const validationErrors = _.map(_.filter(errorResult, 'warningMessage'), 'warningMessage');\r\n\r\n if (_.some(validationErrors)) {\r\n _.forEach(validationErrors, (err, key) => {\r\n this._toastr.warning(err);\r\n });\r\n }\r\n };\r\n try {\r\n const processingResult = await this._processResultPromise(grid, gridTracker, result);\r\n handleErrors(processingResult.errorResults);\r\n this._toastProcessResult(processingResult);\r\n } catch(errorResult) {\r\n handleErrors(errorResult.errors);\r\n if (_.some(errorResult.errors, 'errorMessage')) {\r\n this._toastr.error(errorResult.message, 'Error!');\r\n }\r\n }\r\n } finally {\r\n this._loadingSubject.next(null);\r\n }\r\n }\r\n\r\n /* Example bulk processing payload (reassign in this case):\r\n [{\r\n \"taskID\": 23254880,\r\n \"entityID\": 29522,\r\n \"entityTypeID\": 15,\r\n \"errorMessage\": null,\r\n \"isAuthorized\": true,\r\n \"authorizationReason\": \"Assigned User\",\r\n \"changedFields\": {\r\n \"n10900\": \"5b1d7e74-771b-4619-a54c-f2b135fb515d\",\r\n \"n10901\": 72,\r\n \"f10002\": \"Rann, Jeremy\",\r\n \"f10003\": \"Team Project Weissman\"\r\n },\r\n \"markStale\": false // Typically there's either a changedFields object or markStake is true\r\n }]*/\r\n private async _processResultPromise(grid: GridApi, gridTracker: AgGridMultiSelectTracker, processingResult: Core.BulkOperationResult[]) {\r\n const successfulResults = _.filter(processingResult, (result) => {\r\n return !result.errorMessage && !result.warningMessage && !result.isConcurrencyCheckFailed;\r\n });\r\n const errorResults = _.filter(processingResult, (result) => {\r\n return result.errorMessage || result.warningMessage || result.isConcurrencyCheckFailed;\r\n });\r\n\r\n this._markErrorResults(grid, gridTracker, successfulResults, errorResults);\r\n\r\n if (successfulResults.length < 1) {\r\n if (errorResults.length < 1) {\r\n console.log('Processing result successfully retrieved from server but could not be parsed');\r\n return Promise.reject({\r\n message: this.GENERIC_ERROR_MESSAGE,\r\n errors: errorResults\r\n });\r\n } else if (_.every(errorResults, (result) => { return !result.isAuthorized; })) {\r\n // All results have authorization errors\r\n return Promise.reject({\r\n message: this.PERMISSION_ERROR_MESSAGE,\r\n errors: errorResults\r\n });\r\n } else if (_.every(errorResults, (result) => { return result.isConcurrencyCheckFailed; })) {\r\n // All results have concurrency errors\r\n return Promise.reject({\r\n message: this.CONCURRENCY_ERROR_MESSAGE,\r\n errors: errorResults\r\n });\r\n } else {\r\n console.log(`Processing result successfully retrieved from server, but processing indicated errors (taskID: error):\\n${\r\n _.map(processingResult, (result) => {\r\n return `${result.taskID }: ${ result.errorMessage || result.warningMessage}`;\r\n }).join('\\n')}`);\r\n return Promise.reject({\r\n message: this.GENERIC_ERROR_MESSAGE,\r\n errors: errorResults\r\n });\r\n }\r\n } else {\r\n const authReasons = [];\r\n _.forEach(successfulResults, (result) => {\r\n authReasons.push(`${result.taskID }: ${ result.authorizationReason}`);\r\n\r\n let row: RowNode;\r\n grid.forEachNode(x => {\r\n if (x.data.n10908 === result.taskID) {\r\n row = x;\r\n }\r\n });\r\n\r\n let persistIndex = null;\r\n if (this._actionViewPersistenceService && this._actionViewPersistenceService.detailResults\r\n && this._actionViewPersistenceService.detailResults.dataTable) {\r\n persistIndex = _.findIndex(this._actionViewPersistenceService.detailResults.dataTable, { n10908: result.taskID });\r\n }\r\n\r\n // It is valid that a result may come back for a row that isn't in the results; at least one example\r\n // is a dismiss intake item operation, which may affect both an Identify/Data Enter task and a\r\n // Perform QC task where only one of those is actually in the grid\r\n if (row) {\r\n // If the actionResult has a column named n10908 (which is the taskID), that's a flag that\r\n // this row contains search result data that sould be live-updated; if this is not present,\r\n // simply mark the corresponding row as stale\r\n if (result.markStale) {\r\n // Note that row options such as .stale are processed in SD.AgGrid.Directive.js (getRowStyle function)\r\n row.data.stale = true;\r\n } else {\r\n gridTracker.clear();\r\n _.assign(row.data, result.changedFields);\r\n if (persistIndex !== null && persistIndex >= 0) {\r\n _.assign(this._actionViewPersistenceService.detailResults.dataTable[persistIndex], result.changedFields);\r\n }\r\n }\r\n }\r\n });\r\n grid.redrawRows();\r\n\r\n if (authReasons.length > 0) {\r\n console.log('Task authorization reasons (taskID: reason):\\n', authReasons.join('\\n'));\r\n }\r\n\r\n return {\r\n successfulResults: successfulResults,\r\n errorResults: errorResults\r\n };\r\n }\r\n }\r\n\r\n private async _markErrorResults(grid: GridApi, gridTracker: AgGridMultiSelectTracker, successfulResults, errorResults): Promise {\r\n const consoleErrors = [];\r\n\r\n _.forEach(successfulResults, (result) => {\r\n let row: RowNode;\r\n grid.forEachNode(x => {\r\n if (x.data.n10908 === result.taskID) {\r\n row = x;\r\n }\r\n });\r\n if (row) {\r\n row.data.warning = false;\r\n row.data.error = false;\r\n }\r\n\r\n this._errors = _.reject(this._errors, {taskID: result.taskID});\r\n });\r\n\r\n _.forEach(errorResults, (result) => {\r\n consoleErrors.push(`${result.taskID }: ${ result.errorMessage || result.warningMessage}`);\r\n this._errors.push(result);\r\n\r\n let row: RowNode;\r\n grid.forEachNode(x => {\r\n if (x.data.n10908 === result.taskID) {\r\n row = x;\r\n }\r\n });\r\n if (row) {\r\n if (!result.errorMessage && result.warningMessage) {\r\n row.data.warning = true;\r\n } else {\r\n row.data.error = true;\r\n }\r\n }\r\n });\r\n\r\n if (consoleErrors.length > 0) {\r\n console.log(`Processing errors (taskID: error):\\n${ consoleErrors.join('\\n')}`);\r\n }\r\n\r\n this._actionViewPersistenceService.selectionData = await gridTracker.getSelectedRowIds();\r\n grid.redrawRows();\r\n }\r\n\r\n private _correctForAsyncError(result: any): Core.BulkOperationResult[] {\r\n if (result.asyncState !== undefined && result.result !== undefined) {\r\n console.log('WARNING: An asyncronous task result appears to have come back from the API; please check for a Task return and correct if necessary');\r\n return result.result;\r\n }\r\n else {\r\n return result;\r\n }\r\n }\r\n\r\n private async _processResult(grid: GridApi, gridTracker: AgGridMultiSelectTracker, processingResult): Promise {\r\n try {\r\n const result = await this._processResultPromise(grid, gridTracker, processingResult);\r\n this._toastProcessResult(result);\r\n } catch(errorResult) {\r\n this._toastr.error(errorResult.message, 'Error!');\r\n }\r\n }\r\n\r\n private async _processAddPaymentsToBatchResult(grid: GridApi, gridTracker: AgGridMultiSelectTracker, processingResult: Core.BulkOperationResult[]): Promise {\r\n try {\r\n const result = await this._processResultPromise(grid, gridTracker, processingResult);\r\n this._toastProcessResult(result);\r\n } catch (errorResult) {\r\n const errors = _.uniq(_.map(_.filter(errorResult.errors, (error) => {\r\n return error.errorMessage;\r\n }), 'errorMessage'));\r\n const warnings = _.uniq(_.map(_.filter(errorResult.errors, (error) => {\r\n return !error.errorMessage;\r\n }), 'warningMessage'));\r\n this._taskService.showErrorNotificationModal(errors, warnings,\r\n 'The following error(s) or warning(s) were encountered attempting to add payments ' +\r\n 'to a batch; please attempt to correct these errors and try again');\r\n //this._toastr.error(errorResult.message, 'Error!');\r\n }\r\n }\r\n\r\n private _toastProcessResult(resolution) {\r\n if (resolution.errorResults.length < 1) {\r\n this._toastr.success(`Successfully processed ${ resolution.successfulResults.length } tasks`);\r\n } else if (!resolution.successfulResults || resolution.successfulResults.length < 1) {\r\n this._toastr.error('An unexpected error has occurred');\r\n } else {\r\n this._toastr.warning(`Only some tasks successfully processed; ${ resolution.successfulResults.length } succeeded and ${ resolution.errorResults.length } failed`);\r\n }\r\n }\r\n\r\n private async _updateChangedGridRows(grid: GridApi, gridTracker: AgGridMultiSelectTracker): Promise {\r\n const updatedNodes: RowNode[] = [];\r\n grid.forEachNode((row) => {\r\n if (gridTracker.isRowSelected(row.id)) {\r\n row.data.stale = true;\r\n updatedNodes.push(row);\r\n }\r\n });\r\n\r\n this._actionViewPersistenceService.selectionData = await gridTracker.getSelectedRowIds();\r\n grid.redrawRows({ rowNodes: updatedNodes });\r\n }\r\n}\r\n","
\r\n
\r\n

Results

\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n {{ loadingText }}\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { UIRouter } from '@uirouter/angular';\r\nimport {\r\n ColDef,\r\n ColumnApi,\r\n CsvExportParams,\r\n GridApi,\r\n GridReadyEvent,\r\n RowDataChangedEvent,\r\n RowNode\r\n} from 'ag-grid-community';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { AgGridColumns, AgGridOptionsBuilder } from '../../../Compliance/AgGrid';\r\nimport {\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams,\r\n AgGridMultiSelectTracker\r\n} from '../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridExportOptions } from '../../../Compliance/AgGrid/ToolPanel/models';\r\nimport { ActionViewCategoryTypes } from '../../../constants.new';\r\nimport {\r\n AdvancedSearchColumnBuilder\r\n} from '../../../Search/Advanced/Advanced-Search-List/advancedSearchColumnBuilder.service';\r\nimport { AdvancedSearchPersistenceService } from '../../../Search/Advanced/advancedSearchPersistence.service';\r\nimport { SmartSearchService } from '../../../Search/Advanced/smartSearch.service';\r\nimport { ActionViewService } from '../action-view-service.upgrade';\r\nimport { ActionViewPersistenceService } from '../Action.View.Persistence.Service.upgrade';\r\nimport { ActionViewContextMenuService } from '../actionViewContextMenu.service';\r\n\r\nimport * as _ from 'lodash';\r\nimport * as moment from 'moment';\r\n\r\n@Component({\r\n selector: 'action-view-detailed',\r\n templateUrl: './actionDetailed.component.html',\r\n styleUrls: ['./actionDetailed.component.scss']\r\n})\r\nexport class ActionDetailedComponent implements OnInit, OnDestroy {\r\n constructor(private readonly _actionViewService: ActionViewService,\r\n private readonly _actionViewContextMenuService: ActionViewContextMenuService,\r\n private readonly _actionViewPersistenceService: ActionViewPersistenceService,\r\n private readonly _advancedSearchPersistenceService: AdvancedSearchPersistenceService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService,\r\n private readonly _uiRouter: UIRouter,\r\n private readonly _smartSearchService: SmartSearchService,\r\n private readonly _columnBuilder: AdvancedSearchColumnBuilder,\r\n private readonly _toastr: ToastrService) {\r\n }\r\n\r\n @Input() filterToExecute;\r\n @Input() drilldownMode;\r\n @Input() drilldownFilter;\r\n @Input() results;\r\n @Input() taskAssignmentApi;\r\n @Input() actionView;\r\n\r\n @Output() backToOverview: EventEmitter = new EventEmitter();\r\n\r\n gridId: string = '64f50d82-7571-4cdc-a705-f5100b054f16';\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridOptions = new AgGridOptionsBuilder({\r\n onFilterChanged: () => {\r\n this._actionViewPersistenceService.filter = this._gridApi.getFilterModel();\r\n this.gridTracker.onGridFilterChanged(false);\r\n },\r\n onSortChanged: () => {\r\n this._actionViewPersistenceService.sort = this._gridApi.getSortModel();\r\n this.gridTracker.onGridSortChanged();\r\n },\r\n getRowNodeId: (x) => x.n10908,\r\n rowClassRules: {\r\n 'clickable': (params) => false,\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected(params.data.n10908)\r\n },\r\n getRowStyle: (params) => {\r\n if (params.data.error) {\r\n return { 'color': 'red' };\r\n } else if (params.data.warning) {\r\n return { 'color': '#ffa000', 'font-weight': 'bold' };\r\n } else if (params.data.stale) {\r\n return { 'font-style': 'italic', 'color': 'silver' };\r\n }\r\n },\r\n suppressScrollOnNewData: true,\r\n onRowDataChanged: (event: RowDataChangedEvent) => {\r\n if (this._advancedSearchPersistenceService.scrollLocationIndex) {\r\n this._gridApi.ensureIndexVisible(this._advancedSearchPersistenceService.scrollLocationIndex, 'top');\r\n this._advancedSearchPersistenceService.scrollLocationIndex = null;\r\n }\r\n }\r\n })\r\n .withSort()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withLoadingOverlay()\r\n .withTextSelection()\r\n .build();\r\n\r\n exportOptions: AgGridExportOptions = {\r\n onExportClick: (): void => {\r\n // this.emitAnalyticsEvent('click-SMART-excel-export');\r\n this.exportToExcel();\r\n },\r\n disabled: false,\r\n canCancel: true\r\n };\r\n\r\n contextMenuItems: any[];\r\n contextMenuLoading = false;\r\n contextMenuOpen = false;\r\n showContextMenu = false;\r\n\r\n columnApi: ColumnApi;\r\n\r\n loading = false;\r\n loadingText = null;\r\n isDestroyed = false;\r\n showErrorsOnly = {\r\n value: false\r\n };\r\n showValidRowsOnly = {\r\n value: false\r\n };\r\n originalData = null;\r\n columnsExpanded: boolean;\r\n excelDownloading: boolean;\r\n\r\n private _gridApi: GridApi;\r\n private _destroy$: Subject = new Subject();\r\n\r\n get contextMenuDisabled(): boolean {\r\n return !this.gridTracker?.hasSelectedRows() || this.contextMenuLoading;\r\n }\r\n\r\n get contextMenuTooltip(): string {\r\n if (!this.gridTracker?.hasSelectedRows()) {\r\n return 'Please select at least one row to perform an action';\r\n } else if (this.contextMenuLoading) {\r\n return 'Loading actions...';\r\n } else if (!this.contextMenuItems?.length) {\r\n return 'Load selected actions';\r\n } else {\r\n return null;\r\n }\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._actionViewContextMenuService.loading$.pipe(takeUntil(this._destroy$)).subscribe((loading) => {\r\n this.loading = !!loading;\r\n this.loadingText = loading;\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n this._actionViewContextMenuService.clearErrors();\r\n this.isDestroyed = true;\r\n }\r\n\r\n async onAgGridReady(event: GridReadyEvent): Promise {\r\n this._gridApi = event.api;\r\n this.columnApi = event.columnApi;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this.gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe((selectedRows) => {\r\n this.contextMenuItems = null;\r\n this.showContextMenu = this.gridTracker.hasSelectedRows();\r\n });\r\n\r\n let finalFilter = structuredClone(this.filterToExecute);\r\n\r\n //load the filter\r\n if (this._actionViewPersistenceService.drilldownFilter) {\r\n //If we're loading the drilldown externally, wipe out the external flag so we don't get caught in an infinite loop\r\n finalFilter = structuredClone(this._actionViewPersistenceService.drilldownFilter);\r\n } else if (this.drilldownMode) {\r\n finalFilter = structuredClone(this.drilldownFilter);\r\n } else if (this._actionViewPersistenceService.resultsChanged) {\r\n finalFilter = structuredClone(this._actionViewPersistenceService.masterFilter);\r\n this.filterToExecute = structuredClone(finalFilter);\r\n await this.executeDetailedFilter(finalFilter);\r\n }\r\n\r\n //if we have no cached results and we have a filter\r\n if (!this.results && this.filterToExecute !== undefined) {\r\n await this.executeDetailedFilter(finalFilter);\r\n }\r\n // if we have no saved cached results\r\n else if (!this._actionViewPersistenceService.detailResults) {\r\n const stateParams = this._uiRouter.globals.params;\r\n const actionViewId = parseInt(stateParams.actionViewId);\r\n const isSystemView = parseInt(stateParams.actionViewType) === ActionViewCategoryTypes.SYSTEM;\r\n\r\n if (isSystemView) {\r\n const response = await this._actionViewService.getSystemActionViewById(actionViewId);\r\n\r\n const newCriteria = JSON.parse(response.criteria);\r\n const searchFilter = newCriteria.masterFilter;\r\n searchFilter.DetailedResults = true;\r\n //searchFilter.TaskOutputColumns =_.map(searchFilter.TaskOutputColumns, 'columnId')\r\n const result = await this.taskAssignmentApi.resolveDefaultOutput(searchFilter);\r\n await this.executeDetailedFilter(result);\r\n } else if (!this._actionViewPersistenceService.resultsChanged) {\r\n const response = await this._actionViewService.getCustomActionViewById(actionViewId);\r\n\r\n const newCriteria = JSON.parse(response.criteria);\r\n const searchFilter = newCriteria.masterFilter;\r\n searchFilter.DetailedResults = true;\r\n const result = await this.taskAssignmentApi.resolveDefaultOutput(searchFilter);\r\n await this.executeDetailedFilter(result);\r\n }\r\n } else if (this._actionViewPersistenceService.detailResults && !this._actionViewPersistenceService.resultsChanged) {\r\n this.results = this._actionViewPersistenceService.detailResults;\r\n } else if (!this.filterToExecute && finalFilter) {\r\n this.filterToExecute = structuredClone(finalFilter);\r\n }\r\n\r\n if (this.results) {\r\n this._buildTable(this.results.dataTable);\r\n }\r\n\r\n this._setRowData();\r\n }\r\n\r\n setPersistenceServiceWithResult(result): void {\r\n this._actionViewPersistenceService.detailResults = structuredClone(result);\r\n this.setPersistenceService();\r\n }\r\n\r\n setPersistenceService(): void {\r\n if (!this._actionViewPersistenceService.masterFilter) {\r\n this._actionViewPersistenceService.masterFilter = structuredClone(this.filterToExecute) || {};\r\n }\r\n\r\n //If specific user or teams are blank in the filters, we need to make sure they include an empty object\r\n //for when the user returns to the filter screens (instead of null)\r\n this._actionViewPersistenceService.masterFilter.ShowUserTeams = this._actionViewPersistenceService.masterFilter.ShowUserTeams || [{}];\r\n this._actionViewPersistenceService.masterFilter.ShowTeams = this._actionViewPersistenceService.masterFilter.ShowTeams || [{}];\r\n\r\n if (this.drilldownMode) {\r\n this._actionViewPersistenceService.drilldownFilter = structuredClone(this.drilldownFilter);\r\n }\r\n const stateParams = this._uiRouter.globals.params;\r\n this._actionViewPersistenceService.routeParams = structuredClone(stateParams);\r\n this._actionViewPersistenceService.actionViewType = stateParams.actionViewType;\r\n this._actionViewPersistenceService.drilldownMode = structuredClone(this.drilldownMode);\r\n this._actionViewPersistenceService.actionViewName = this.actionView.actionViewName;\r\n }\r\n\r\n async executeDetailedFilter(filter): Promise {\r\n this._actionViewPersistenceService.selectionData = [];\r\n\r\n this.filterToExecute = filter;\r\n\r\n try {\r\n const result = await this._actionViewService.executeActionView(filter);\r\n\r\n if (result.totalCount >= 50000) {\r\n this._toastr.warning('50,000 records are shown; if you want to see all results please use the \"Excel\" export option.', 'Action View');\r\n }\r\n\r\n this.results = result;\r\n\r\n // please do not remove this console output,Grant is using it\r\n //\r\n console.info(['ActionView Detailed Search results', result]);\r\n console.info(['ActionView Detailed Search result sql', result.sql]);\r\n\r\n this.setPersistenceServiceWithResult(result);\r\n } catch (err) {\r\n if (err !== 'Cancelled') {\r\n console.log(['ActionView search - Failure', err]);\r\n // error handler\r\n if (err.status === 0) {\r\n // $http timeout\r\n console.log('ActionView search - Failure - $http timeout');\r\n } else {\r\n // response error status from server\r\n console.log('ActionView search - Failure ');\r\n //toastr.info('', '\"Action View search has been cancelled');\r\n //warningService.warning(\"\", \"Action View search has been cancelled\", 6000);\r\n this.results = {};\r\n this.originalData = null;\r\n //showFilter()\r\n }\r\n }\r\n }\r\n }\r\n\r\n async getTableData(fromRefresh: boolean): Promise {\r\n if (fromRefresh) {\r\n this._productAnalyticsService.logEvent('click-action-view-refresh');\r\n }\r\n this._gridApi.showLoadingOverlay();\r\n this.showErrorsOnly.value = false;\r\n this.showValidRowsOnly.value = false;\r\n this._actionViewContextMenuService.clearErrors();\r\n\r\n this.gridTracker.clear();\r\n\r\n let resetFilter;\r\n // Figure out which filter we need. The three states are basically\r\n // 1) use the persistence service. This is when we return using the nub and takes precedence\r\n // 2) use the drilldown filter. This means we have drilled down from the overview page and need to use that\r\n // 3) lastly, use the filter on the page. This is most common. This is a normally executed filter.\r\n if (this.drilldownMode && !_.isEmpty(this.drilldownFilter)) {\r\n resetFilter = this.drilldownFilter;\r\n } else if (this._actionViewPersistenceService.masterFilter && !this.filterToExecute) {\r\n resetFilter = this._actionViewPersistenceService.masterFilter;\r\n } else if (this.filterToExecute) {\r\n resetFilter = this.filterToExecute;\r\n }\r\n\r\n if (resetFilter) {\r\n this.results = null;\r\n this.originalData = null;\r\n await this.executeDetailedFilter(resetFilter);\r\n this._setRowData();\r\n this._gridApi.hideOverlay();\r\n }\r\n }\r\n\r\n async getMenuOptions(): Promise {\r\n if (this.contextMenuOpen) {\r\n this.contextMenuOpen = false;\r\n return;\r\n }\r\n\r\n if (this.contextMenuItems?.length) {\r\n this.contextMenuOpen = true;\r\n return;\r\n }\r\n\r\n this.contextMenuLoading = true;\r\n\r\n this.setPersistenceService();\r\n this.contextMenuItems = await this._actionViewContextMenuService.getContextMenu(this._gridApi, this.gridTracker, this.gridOptions, this.results.searchTimestamp);\r\n\r\n this.contextMenuOpen = true;\r\n this.contextMenuLoading = false;\r\n }\r\n\r\n // remove CSV export per Grant comment regarding WK-4228 (already removed on the UI)\r\n exportToCsv(): void {\r\n const params = {\r\n fileName: `action-view - ${moment().format()}`\r\n } as CsvExportParams;\r\n this._gridApi.exportDataAsCsv(params);\r\n }\r\n\r\n async exportToExcel(): Promise {\r\n this.excelDownloading = true;\r\n this._productAnalyticsService.logEvent('click-action-view-excel-export');\r\n const filterToExecute = this.drilldownMode\r\n ? structuredClone(this.drilldownFilter)\r\n : structuredClone(this.filterToExecute);\r\n\r\n if (!this.actionView.actionViewName || this.actionView.actionViewName.trim() == '') {\r\n filterToExecute.searchName = 'Action View Results';\r\n } else {\r\n filterToExecute.searchName = this.actionView.actionViewName.replace(/[^a-z0-9_ \\-]/gi, '');\r\n }\r\n\r\n await this._actionViewService.executeActionViewToExcel(filterToExecute);\r\n this.excelDownloading = false;\r\n }\r\n\r\n resizeColumns(value: boolean): void {\r\n this.columnsExpanded = value;\r\n this._productAnalyticsService.logEvent('click-action-view-autosize');\r\n }\r\n\r\n hasErrors(): boolean {\r\n return this._actionViewContextMenuService.hasErrors();\r\n }\r\n\r\n filterResults(): void {\r\n if (!this.originalData) {\r\n this.originalData = structuredClone(this.results.dataTable);\r\n }\r\n\r\n if (this.showErrorsOnly.value || this.showValidRowsOnly.value) {\r\n this.results.dataTable = this.originalData.filter(x =>\r\n (this.showErrorsOnly.value && (x.error || x.warning)) ||\r\n (this.showValidRowsOnly.value && !x.error && !x.warning));\r\n } else {\r\n this.results.dataTable = this.originalData;\r\n }\r\n\r\n this._gridApi.setRowData(this.results.dataTable);\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.results)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this.results.dataTable);\r\n if (this._advancedSearchPersistenceService.columnsExpanded) {\r\n this._gridApi.sizeColumnsToFit();\r\n } else {\r\n this.columnApi.autoSizeAllColumns();\r\n }\r\n this._setAgGridValues();\r\n }\r\n\r\n private _setAgGridValues(): void {\r\n if(this._actionViewPersistenceService.sort) {\r\n this._gridApi.setSortModel(this._actionViewPersistenceService.sort);\r\n }\r\n if(this._actionViewPersistenceService.filter) {\r\n this._gridApi.setFilterModel(this._actionViewPersistenceService.filter);\r\n }\r\n }\r\n\r\n private _buildTable(tableData: any[]): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n // Important - For whatever reason, ag-grid will maintain the previous search column order if not reset\r\n this._gridApi.setColumnDefs([]);\r\n\r\n const search = this._advancedSearchPersistenceService.search;\r\n const columnIds = (tableData && tableData.length) ? Object.keys(tableData[0]) : [];\r\n\r\n // Reorder columnIds to match outputColumn order\r\n if (search && search.searchCriteria && search.searchCriteria.outputColumns) {\r\n const outputIds = search.searchCriteria.outputColumns.map(x => x.columnId);\r\n columnIds.sort((a, b) => {\r\n return outputIds.indexOf(+a.slice(1)) - outputIds.indexOf(+b.slice(1));\r\n });\r\n }\r\n\r\n const multiselectColDef = {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'n10908',\r\n width: AgGridColumns.selectionColumnWidth,\r\n maxWidth: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n editable: false,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: this.gridTracker } as AgGridMultiSelectRendererParams\r\n } as ColDef;\r\n\r\n const columnProperties = columnIds.reduce((acc, x) => {\r\n const fieldId = +x.slice(1);\r\n if (isNaN(fieldId)) {\r\n return acc;\r\n }\r\n\r\n const field = this._smartSearchService.getFieldById(fieldId);\r\n if (!field) {\r\n return acc;\r\n }\r\n\r\n const baseColumn = this._columnBuilder.getColumnDefinition(x, field, 'av');\r\n\r\n acc.push(baseColumn);\r\n return acc;\r\n }, []);\r\n\r\n const columns = [\r\n multiselectColDef,\r\n ...columnProperties\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setRowData(tableData);\r\n }\r\n\r\n private _clearTable(): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n this.gridTracker.clear();\r\n this._gridApi.setRowData([]);\r\n }\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows: RowNode[] = model.rowsToDisplay.slice(skip, take + 1);\r\n return {\r\n data: rows.map((x) => {\r\n return x.data.n10908;\r\n })\r\n } as Compliance.QueryResultModel;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { AgGridExtensionsModule } from '../../Compliance/AgGrid/agGridExtensions.module';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { DirectivesModule } from '../../UI-Lib/Directives/directives.module';\r\nimport { ActionViewContextMenuService } from './actionViewContextMenu.service';\r\nimport { ActionDetailedComponent } from './Detailed-List/actionDetailed.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n DirectivesModule,\r\n AgGridExtensionsModule,\r\n AgGridModule\r\n ],\r\n declarations: [ActionDetailedComponent],\r\n exports: [],\r\n})\r\nexport class ActionViewModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Provider('avContextMenuService', ActionViewContextMenuService);\r\n hybridAdapterUtility.downgradeNg2Component('actionViewDetailed', ActionDetailedComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { AppealRecommendationTemplateComponent } from './Appeal-Recommendation-Template/appealRecommendationTemplate.component';\r\nimport { AppealRecommendationTemplateModalService } from './Appeal-Recommendation-Template/appealRecommendationTemplateModal.service';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { QuillEditorComponent } from 'ngx-quill';\r\nimport { AppealRecommendationRepository } from './appealRecommendation.repository';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport {\r\n ARCCComponent\r\n} from './ARCC/aRCC.component';\r\nimport { CompanyModule } from '../Entity/Company/company.module';\r\nimport {\r\n AppealRecommendationCommandCenterGridActionCellRendererComponent\r\n} from './ARCC/agGridActionCellRenderer.component';\r\nimport {\r\n ARCCAssignedComponent\r\n} from './ARCC/ARCC-Assigned/aRCCAssigned.component';\r\nimport {\r\n ARCCAssignedDetailsModalComponent\r\n} from './ARCC/ARCC-Assigned-Details-Modal/aRCCAssignedDetailsModal.component';\r\nimport { TeamModule } from '../Team/team.module';\r\nimport {\r\n AppealRecommendationTemplateLastSentHelpComponent\r\n} from './Appeal-Recommendation-Template/appealRecommendationTemplateLastSentHelp.component';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport {\r\n AppealRecommendationTemplateDetailsComponent\r\n} from './Appeal-Recommendation-Template/Appeal-Recommendation-Template-Details/appealRecommendationTemplateDetails.component';\r\nimport {\r\n ARCCBulkUpdateComponent\r\n} from './ARCC/ARCC-Bulk-Update/aRCCBulkUpdate.component';\r\nimport { PropertyCharacteristicsModule } from '../Property-Characteristics/propertyCharacteristics.module';\r\nimport {\r\n ARCCBulkUpdateResultConfirmationComponent\r\n} from './ARCC/ARCC-Bulk-Update/ARCC-Bulk-Update-Result-Confirmation/aRCCBulkUpdateResultConfirmation.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n BusyIndicatorModule,\r\n QuillEditorComponent,\r\n BsDropdownModule.forRoot(),\r\n CompanyModule,\r\n TeamModule,\r\n ReactiveFormsModule,\r\n FormsModule,\r\n PropertyCharacteristicsModule\r\n ],\r\n declarations: [\r\n AppealRecommendationTemplateComponent,\r\n ARCCComponent,\r\n AppealRecommendationCommandCenterGridActionCellRendererComponent,\r\n ARCCAssignedComponent,\r\n ARCCAssignedDetailsModalComponent,\r\n AppealRecommendationTemplateLastSentHelpComponent,\r\n AppealRecommendationTemplateDetailsComponent,\r\n ARCCBulkUpdateComponent,\r\n ARCCBulkUpdateResultConfirmationComponent\r\n ],\r\n providers: [\r\n AppealRecommendationTemplateModalService,\r\n AppealRecommendationRepository\r\n ],\r\n exports: [\r\n AppealRecommendationTemplateComponent,\r\n ARCCComponent,\r\n AppealRecommendationCommandCenterGridActionCellRendererComponent,\r\n ARCCAssignedComponent,\r\n ARCCAssignedDetailsModalComponent,\r\n AppealRecommendationTemplateLastSentHelpComponent\r\n ]\r\n\r\n})\r\nexport class AppealRecommendationModule {\r\n static setupModule() {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Provider('appealRecommendationModalService', AppealRecommendationTemplateModalService);\r\n hybridAdapterUtility.downgradeNg2Component('appealRecommendationCommandCenter', ARCCComponent);\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { ClientServicesExceptionModalService } from '../Client-Services/Exceptions/client-service-exception-modal.service';\r\nimport { ClientServicesExceptionModalComponent } from '../Client-Services/Exceptions/client-service-exception.modal';\r\nimport { ClientServicesExceptionService } from '../Client-Services/Exceptions/client-services-exception.service';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { SharedPipesModule } from '../UI-Lib/Pipes/shared-pipes.module';\r\nimport { ActionViewOutputCustomComponent } from './ActionView/Action-View-Output-Custom/actionViewOutputCustom.component';\r\nimport { ActionViewOutputDefaultsComponent } from './ActionView/Action-View-Output-Defaults/actionViewOutputDefaults.component';\r\nimport { ActionViewOutputDefaultsGridActionCellRendererComponent } from './ActionView/Action-View-Output-Defaults/agGridActionCellRenderer.component';\r\nimport { AppealRecommendationModule } from '../Appeal-Recommendation/appealRecommendation.module';\r\nimport { ErrorNotificationComponent } from './Error-Notification/errorNotification.component';\r\nimport { ReassignTaskModalComponent } from './Reassign-Task-Modal/reassignTaskModal.component';\r\n// import { TaskSeriesArrowsComponent } from './Task-Series-Arrows/taskSeriesArrows.component';\r\n// import { TaskModalComponent } from './taskModal.component';\r\nimport { TaskModalsService } from './taskModals.service';\r\n\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n PopoverModule,\r\n AppealRecommendationModule\r\n ],\r\n declarations: [\r\n ClientServicesExceptionModalComponent,\r\n ActionViewOutputDefaultsGridActionCellRendererComponent,\r\n ActionViewOutputDefaultsComponent,\r\n ActionViewOutputCustomComponent,\r\n ErrorNotificationComponent,\r\n ReassignTaskModalComponent,\r\n // TaskModalComponent,\r\n // TaskSeriesArrowsComponent\r\n ],\r\n providers: [\r\n ClientServicesExceptionService,\r\n ClientServicesExceptionModalService\r\n ],\r\n exports: [\r\n ActionViewOutputDefaultsComponent\r\n ]\r\n})\r\nexport class TaskModule {\r\n static setupModule(): void {\r\n //let hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n //Entry components must have only two words, for example: parcelActivity not parcelActivitySummary\r\n //This is due to a bug in angular 1 case formatting where it gets confused with kebab casing with multiple dashes\r\n //And angular 1 will autoconvert camelCase to kebab-case\r\n hybridAdapterUtility.downgradeNg2Component('client-services-exception-modal', ClientServicesExceptionModalComponent);\r\n hybridAdapterUtility.downgradeNg2Component('actionViewOutputDefaults', ActionViewOutputDefaultsComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('taskModalsService', TaskModalsService);\r\n }\r\n}\r\n","

My Team's Tasks Due Within 45 Days

\r\n
\r\n
\r\n \r\n
\r\n
\r\n

No current tasks

\r\n
\r\n
\r\n

\r\n Your data is taking some time to load. To access your Action Views, click here.\r\n

\r\n
\r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n {{name}}\r\n
\r\n {{task.taskSeriesTypeName}}\r\n \r\n \r\n 0\" >{{item.ready}} 0\" (click)=\"drilldownCell(item, 'not ready', task)\">({{item.notReady}})\r\n \r\n
\r\n\r\n
\r\n","import { Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ActionViewService } from '../../Task/ActionView/action-view-service.upgrade';\r\nimport { ActionViewPersistenceService } from '../../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { UpgradeNavigationServiceHandler } from '../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { LandingViewTypes } from '../landing.component';\r\n\r\n@Component({\r\n selector: 'overview-single-table',\r\n templateUrl: './overview-single-grouping.component.html'\r\n})\r\nexport class OverviewSingleGroupingComponent implements OnChanges {\r\n constructor(private actionViewService: ActionViewService,\r\n private actionViewPersistenceService: ActionViewPersistenceService,\r\n private upgradeNavigationService: UpgradeNavigationServiceHandler) {}\r\n\r\n @Input() viewMode: LandingViewTypes;\r\n\r\n filter: any;\r\n drilldownFilter: any;\r\n tableData: any;\r\n headerNames: string[] = [];\r\n isLoading: boolean = true;\r\n actionViewTimeout: boolean = false;\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n const changedKeys = Object.keys(changes);\r\n if (changedKeys.indexOf('viewMode') >= 0) {\r\n this.executeActionView();\r\n }\r\n }\r\n\r\n drilldownCell(cell: any, ready: string, task: any): void {\r\n this.actionViewPersistenceService.clearSavedData();\r\n //step 1: set drilldown persistenceservice variable\r\n this.actionViewPersistenceService.externalDrilldown = true;\r\n this.actionViewPersistenceService.masterFilter = _.cloneDeep(this.filter);\r\n this.actionViewPersistenceService.drilldownFilter = _.cloneDeep(this.filter);\r\n this.actionViewPersistenceService.externalDrilldownData = {\r\n ready: ready,\r\n item: cell,\r\n task: task\r\n };\r\n\r\n this.upgradeNavigationService.go('actionview', {});\r\n }\r\n\r\n goToActionView(): void {\r\n this.actionViewPersistenceService.clearSavedData();\r\n this.actionViewPersistenceService.masterFilter = this.filter;\r\n this.upgradeNavigationService.go('actionview', {});\r\n }\r\n\r\n private async executeActionView() {\r\n this.isLoading = true;\r\n\r\n try {\r\n const result = await this.actionViewService.welcomeSearch(this.viewMode);\r\n this.filter = result.originalRequest;\r\n\r\n if (result.isCancelled) {\r\n this.actionViewTimeout = true;\r\n }\r\n else {\r\n this.tableData = _.map(result.group1ResultList, (task: any) => {\r\n task.data = _.map(task.data, (item: any) => {\r\n item.colClass = this.actionViewService.getUrgencyColumnStyleClass(item.sequence);\r\n return item;\r\n });\r\n return task;\r\n });\r\n\r\n if (this.tableData.length > 0) {\r\n const orderedHeaders: any[] = this.tableData[0].data;\r\n this.headerNames = _.chain(orderedHeaders)\r\n .sortBy('sequence')\r\n .map('label')\r\n .value();\r\n }\r\n this.drilldownFilter = _.cloneDeep(this.filter);\r\n }\r\n } finally {\r\n this.isLoading = false;\r\n }\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { DashboardComponent } from './dashboard.component';\r\nimport { DashboardDataService } from './dashboard.data.service';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { CommonModule } from '@angular/common';\r\nimport { UserWidgetComponent } from './Widgets/user.widget.component';\r\nimport { AppealSavingsWidgetComponent } from './Widgets/appeal.savings.widget.component';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { GridsterModule } from 'angular-gridster2';\r\nimport { QuickSearchButtonWidgetComponent } from './Widgets/quick.search.button.widget.component';\r\nimport { StatesButtonWidgetComponent } from './Widgets/states.button.widget.component';\r\nimport { CalendarWidgetComponent } from './Widgets/Calendar-Widget/calendar.widget.component';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { ShortcutWidgetSettingsComponent } from './Widgets/Shortcuts-Widget/shortcut.widget.settings.component';\r\nimport { ShortcutWidgetComponent } from './Widgets/Shortcuts-Widget/shortcut.widget.component';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { WidgetComponentRegistryService } from './widget.component.registry.service';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { PortfolioAnalysisWidgetComponent } from './Widgets/Portfolio-Analysis-Widget/portfolio.analysis.widget.component';\r\nimport { PortfolioAnalysisChartTableComponent } from './Widgets/Portfolio-Analysis-Widget/portfolio.analysis.chart.table.component';\r\nimport { MyTasksWidgetComponent } from './Widgets/My-Tasks-Widget/my.tasks.widget.component';\r\nimport { MyTasksWidgetSettingsComponent } from './Widgets/My-Tasks-Widget/my.tasks.widget.settings.component';\r\nimport { CalendarWidgetSettingsComponent } from './Widgets/Calendar-Widget/calendar.widget.settings.component';\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n BsDropdownModule.forRoot(),\r\n TooltipModule.forRoot(),\r\n PopoverModule.forRoot(),\r\n GridsterModule,\r\n WeissmanSharedModule,\r\n FormsModule\r\n ],\r\n declarations: [\r\n DashboardComponent,\r\n UserWidgetComponent,\r\n AppealSavingsWidgetComponent,\r\n QuickSearchButtonWidgetComponent,\r\n StatesButtonWidgetComponent,\r\n CalendarWidgetComponent,\r\n ShortcutWidgetComponent,\r\n ShortcutWidgetSettingsComponent,\r\n PortfolioAnalysisWidgetComponent,\r\n PortfolioAnalysisChartTableComponent,\r\n MyTasksWidgetComponent,\r\n MyTasksWidgetSettingsComponent,\r\n CalendarWidgetSettingsComponent\r\n ],\r\n providers: [DashboardDataService, WidgetComponentRegistryService],\r\n exports: [DashboardComponent]\r\n})\r\nexport class DashboardModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n //Entry components must have only two words, for example: parcelActivity not parcelActivitySummary\r\n //This is due to a bug in angular 1 case formatting where it gets confused with kebab casing with multiple dashes\r\n //And angular 1 will autoconvert camelCase to kebab-case\r\n hybridAdapterUtility.downgradeNg2Component('dashboard', DashboardComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('dashboardDataService', DashboardDataService);\r\n }\r\n}\r\n","import { forwardRef, NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HelpComponent } from './Help/help.component';\r\nimport { QuillModule } from 'ngx-quill';\r\nimport { LandingComponent } from './landing.component';\r\nimport { SSOLoginComponent } from './ssoLogin.component';\r\nimport { OverviewSingleGroupingComponent } from './Widgets/overview-single-grouping.component';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { LandingSelectorComponent } from './landing.selector.component';\r\nimport { DashboardModule } from '../Dashboard/dashboard.module';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n WeissmanSharedModule,\r\n QuillModule,\r\n TooltipModule.forRoot(),\r\n DashboardModule\r\n ],\r\n declarations: [\r\n HelpComponent,\r\n SSOLoginComponent,\r\n LandingComponent,\r\n OverviewSingleGroupingComponent,\r\n LandingSelectorComponent\r\n ]\r\n})\r\nexport class LandingModule {\r\n static setupModule(): void {\r\n //let hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n //Entry components must have only two words, for example: parcelActivity not parcelActivitySummary\r\n //This is due to a bug in angular 1 case formatting where it gets confused with kebab casing with multiple dashes\r\n //And angular 1 will autoconvert camelCase to kebab-case\r\n hybridAdapterUtility.downgradeNg2Component('helpComponent', HelpComponent);\r\n hybridAdapterUtility.downgradeNg2Component('landingSelector', LandingSelectorComponent);\r\n hybridAdapterUtility.downgradeNg2Component('ssoLogin', SSOLoginComponent);\r\n hybridAdapterUtility.downgradeNg2Component('landing', LandingComponent);\r\n\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { ElectronicFilingComponent } from './electronicFiling.component';\r\n\r\n@NgModule({\r\n imports: [WeissmanSharedModule],\r\n declarations: [ElectronicFilingComponent]\r\n})\r\nexport class ElectronicFilingModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('electronicFiling', ElectronicFilingComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { ValuationTemplatesComponent } from './valuationTemplates.component';\r\nimport { AddEditValuationTemplateComponent } from './Add-Edit-Tempalate/addEditValuationTemplate.component';\r\nimport { ValuationTemplateService } from './valuationTemplate.service';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { ValuationTemplateRepository } from '../../Core-Repositories/valuationTemplate.repository';\r\nimport { ValuationTemplateDetailComponent } from './Template-Detail/valuationTemplateDetail.component';\r\nimport { ValuationStatesListComponent } from './Template-Detail/States-List/valuationStatesList.component';\r\nimport { AddStateComponent } from './Template-Detail/States-List/Add-State/addState.component';\r\nimport { ValuationAssessorsListComponent } from './Template-Detail/Assessor-List/valuationAssessorsList.component';\r\nimport { AddAssessorComponent } from './Template-Detail/Assessor-List/Add-Assessor/addAssessor.component';\r\nimport { ValuationSiteClassListComponent } from './Template-Detail/Site-Class-List/valuationSiteClassList.component';\r\nimport { AddSiteClassComponent } from './Template-Detail/Site-Class-List/Add-Site-Class/addSiteClass.component';\r\nimport { ValuationTemplateUploadComponent } from './Template-Detail/Upload/valuationTemplateUpload.component';\r\nimport { UploadComponent } from './Template-Detail/Upload/Template-Upload/upload.component';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ReactiveFormsModule,\r\n BusyIndicatorModule,\r\n WeissmanSharedModule\r\n ],\r\n declarations: [\r\n ValuationTemplatesComponent,\r\n AddEditValuationTemplateComponent,\r\n ValuationTemplateDetailComponent,\r\n ValuationStatesListComponent,\r\n AddStateComponent,\r\n ValuationAssessorsListComponent,\r\n AddAssessorComponent,\r\n ValuationSiteClassListComponent,\r\n AddSiteClassComponent,\r\n ValuationTemplateUploadComponent,\r\n UploadComponent\r\n ],\r\n providers: [\r\n ValuationTemplateService,\r\n ValuationTemplateRepository\r\n ],\r\n exports: [\r\n ValuationTemplatesComponent,\r\n ValuationTemplateDetailComponent\r\n ]\r\n})\r\nexport class ValuationTemplatesModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('valuationTemplates', ValuationTemplatesComponent);\r\n hybridAdapterUtility.downgradeNg2Component('valuationTemplateDetail', ValuationTemplateDetailComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { IncomeStatementCategoryPickerComponent } from './Income-Statement/Income-Statement-Category-Selector/incomeStatementCategoryPicker.component';\r\nimport { IncomeStatementCategorySelectorComponent } from './Income-Statement/Income-Statement-Category-Selector/incomeStatementCategorySelector.component';\r\nimport { IncomeStatementListComponent } from './Income-Statement/Income-Statement-List/incomeStatementList.component';\r\nimport { RentRollGridActionCellRendererComponent } from './Rent-Roll/Rent-Roll-List/agGridActionCellRendererComponent';\r\nimport { RentRollListComponent } from './Rent-Roll/Rent-Roll-List/rentRollList.component';\r\nimport { ValuationTemplatesModule } from './Templates/valuationTemplates.module';\r\nimport { IncomeStatementBulkUpdateComponent } from './Income-Statement/Income-Statement-Bulk-Update/incomeStatementBulkUpdate.component';\r\nimport { RentRollBulkUpdateComponent } from './Rent-Roll/Rent-Roll-Bulk-Update/rentRollBulkUpdate.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n ValuationTemplatesModule\r\n ],\r\n declarations: [\r\n IncomeStatementCategorySelectorComponent,\r\n IncomeStatementCategoryPickerComponent,\r\n IncomeStatementListComponent,\r\n RentRollGridActionCellRendererComponent,\r\n RentRollListComponent,\r\n IncomeStatementBulkUpdateComponent,\r\n RentRollBulkUpdateComponent\r\n ],\r\n exports: [\r\n ValuationTemplatesModule,\r\n IncomeStatementCategorySelectorComponent,\r\n IncomeStatementListComponent,\r\n RentRollListComponent,\r\n IncomeStatementBulkUpdateComponent,\r\n RentRollBulkUpdateComponent\r\n ]\r\n})\r\nexport class ValuationModule {\r\n static setupModule() {\r\n ValuationTemplatesModule.setupModule();\r\n\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('incomeStatementList', IncomeStatementListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('rentRollList', RentRollListComponent);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular/main';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\n@Component({\r\n selector: 'asset-return-filings-status',\r\n template: `\r\n {{assetReturnModel.status}}\r\n \r\n {{assetReturnModel.completionDate.toLocaleDateString()}}\r\n \r\n `\r\n})\r\nexport class AssetReturnFilingStatusCellRendererComponent implements ICellRendererAngularComp {\r\n assetReturnModel: Compliance.AssetReturnModel;\r\n\r\n agInit(params: ICellRendererParams): void {\r\n this.assetReturnModel = params.data && params.data as Compliance.AssetReturnModel;\r\n }\r\n\r\n refresh(params: any): boolean {\r\n return false;\r\n }\r\n}\r\n","import { AssetInfoComponent } from './assetInfo.component';\r\nimport { AssetSummary } from '../../Models/assetSummary';\r\nimport { Observable } from 'rxjs';\r\n\r\nexport enum CustomTemplateTypes {\r\n AcqDate,\r\n AssetClass,\r\n CostAdjustments,\r\n GlAccount,\r\n ParcelSelector,\r\n Sites,\r\n Companies\r\n}\r\n\r\nexport interface TypeaheadParams {\r\n placeholder: string;\r\n valueParam: string;\r\n filterValue: string;\r\n values$: Observable;\r\n onBlur: () => void;\r\n onNoResults: () => void;\r\n onSelect: () => void;\r\n}\r\n\r\nexport interface AssetTemplate {\r\n type: Core.DescriptorFieldTypes | CustomTemplateTypes;\r\n modelParam?: string;\r\n isCustom?: boolean;\r\n isDoubleWidth?: boolean;\r\n maxLength?: number;\r\n isDisabled?: (value: number) => boolean;\r\n isStatic?: (value?: number) => boolean;\r\n}\r\n\r\nexport interface AssetInfoFieldBase {\r\n label: string;\r\n sourceParam: string;\r\n reportedParam: string;\r\n reportedOverride: string;\r\n reportedTemplate: AssetTemplate;\r\n}\r\n\r\nexport interface AssetInfoField extends AssetInfoFieldBase {\r\n cellClass?: string;\r\n labelHelpContentId?: string;\r\n labelTemplate?: AssetTemplate;\r\n sourceTemplate?: AssetTemplate;\r\n descriptorList?: string;\r\n descriptorCount?: number;\r\n descriptorHelpContentId?: string;\r\n descriptor?: Compliance.CompanyAssetDescriptorMappingModel;\r\n picklist?: Compliance.NameValuePair[];\r\n isCalculated?: string // added to fix the assetInfo.comnponent.html error\r\n reportedOverrideWithBlank?: any // added to fix the assetInfo.comnponent.html error\r\n isDisabled?: (value: any) => boolean;\r\n onChange?: (value: any, asset: AssetSummary, field: AssetInfoField) => void;\r\n onClear?: (asset: AssetSummary, field: AssetInfoField) => void;\r\n sourceValueGetter?: (value: string, field: AssetInfoField) => any;\r\n reportedValueGetter?: (asset: AssetSummary, field: AssetInfoField) => any;\r\n isRowShown?: () => boolean;\r\n isSourceCellShown?: (asset?: AssetSummary, field?: AssetInfoField) => any;\r\n isReportedCellShown?: (asset?: AssetSummary, field?: AssetInfoField) => any;\r\n}\r\n\r\nexport interface AssetLeasedInfoField extends AssetInfoFieldBase {\r\n picklist?: Compliance.NameValuePair[];\r\n maxLength?: number;\r\n}\r\n\r\nexport interface AssetInventoryField extends AssetInfoFieldBase {\r\n month: number;\r\n isCalculated?: string;\r\n}\r\n\r\nexport const ASSET_FIELDS: (classRef: AssetInfoComponent) => AssetInfoField[] = (classRef) => [\r\n {\r\n label: 'Is Locked',\r\n sourceParam: null,\r\n sourceTemplate: null,\r\n sourceValueGetter: () => null,\r\n picklist: [{name: 'Yes', value: true}, {name: 'No', value: false}],\r\n reportedParam: 'reportedIsLocked',\r\n reportedOverride: '',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Picklist },\r\n onChange: classRef.onIsLockedChange.bind(classRef),\r\n reportedValueGetter: classRef.getIsLockedDisplayValue.bind(classRef),\r\n isRowShown: () => !classRef.createNewAsset\r\n },\r\n {\r\n label: 'Ownership Type',\r\n sourceParam: 'assetOwnershipTypeId',\r\n sourceTemplate: { type: Core.DescriptorFieldTypes.Picklist },\r\n sourceValueGetter: () => null,\r\n picklist: [],\r\n reportedParam: 'assetOwnershipTypeId',\r\n reportedOverride: '',\r\n reportedTemplate: { type: null, isStatic: () => true },\r\n onChange: classRef.onOwnershipTypeChange.bind(classRef),\r\n reportedValueGetter: classRef.getOwnershipTypeDescription.bind(classRef)\r\n },\r\n {\r\n label: 'Company',\r\n sourceParam: 'sourceCompanyName',\r\n reportedParam: 'companyId',\r\n reportedOverride: 'reportedCompanyNameHasOverride',\r\n reportedTemplate: {\r\n type: CustomTemplateTypes.Companies,\r\n isCustom: true,\r\n isStatic: () => !classRef.createNewAsset\r\n },\r\n reportedValueGetter: classRef.getCompanyNameFromId.bind(classRef),\r\n isCalculated: 'isCompanyCalculated'\r\n },\r\n {\r\n label: 'Asset Number',\r\n sourceParam: 'sourceAssetNumber',\r\n reportedParam: 'reportedAssetNumber',\r\n reportedOverride: 'reportedAssetNumberHasOverride',\r\n reportedOverrideWithBlank: 'reportedAssetNumberHasOverrideWithBlank',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n },\r\n {\r\n label: 'Old Asset Number',\r\n sourceParam: 'sourceOldAssetNumber',\r\n reportedParam: 'reportedOldAssetNumber',\r\n reportedOverride: 'reportedOldAssetNumberHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text },\r\n isRowShown: () => classRef.editMode || classRef.hasOldAssetNumber\r\n },\r\n {\r\n label: 'State',\r\n sourceParam: '',\r\n reportedParam: 'state',\r\n reportedOverride: '',\r\n reportedTemplate: { type: null, isStatic: () => true },\r\n isRowShown: () => !classRef.createNewAsset\r\n },\r\n {\r\n label: 'Assessor',\r\n sourceParam: '',\r\n reportedParam: 'assessorName',\r\n reportedOverride: '',\r\n reportedTemplate: { type: null, isStatic: () => true },\r\n isRowShown: () => !classRef.createNewAsset\r\n },\r\n {\r\n label: 'Acquisition Date',\r\n labelHelpContentId: 'asset-info.acquisition-date-field',\r\n cellClass: 'acqDateAssetDescriptors-0',\r\n descriptorList: 'acqDateAssetDescriptors',\r\n descriptorHelpContentId: 'asset-info.acqDateAssetDescriptors',\r\n descriptor: {\r\n columnName: null,\r\n companyAssetDescriptorMappingId: 0,\r\n companyId: null,\r\n descriptor: null,\r\n pickList: null\r\n },\r\n sourceParam: 'sourceAcqDate',\r\n reportedParam: 'reportedAcqDate',\r\n reportedOverride: 'reportedAcqDateHasOverride',\r\n reportedTemplate: { type: CustomTemplateTypes.AcqDate, isCustom: true },\r\n isDisabled: () => classRef.assetListForm.value.acqDateAssetDescriptors > 0,\r\n onChange: classRef.onAcquisitionDateChanged.bind(classRef),\r\n onClear: classRef.clearAcqDateOverride.bind(classRef),\r\n reportedValueGetter: classRef.formatAlternativeDate.bind(classRef)\r\n },\r\n {\r\n label: 'Disposed Date',\r\n labelHelpContentId: 'asset-info.disposed-date-field',\r\n sourceParam: 'sourceDisposedDate',\r\n reportedParam: 'reportedDisposedDate',\r\n reportedOverride: 'reportedDisposedDateHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Date },\r\n onChange: classRef.onDisposedDateChanged.bind(classRef),\r\n onClear: classRef.clearDisposedDateOverride.bind(classRef),\r\n isDisabled: (row) => row && !row.isPrimary,\r\n isRowShown: () => !classRef.createNewAsset\r\n },\r\n {\r\n label: 'Description',\r\n sourceParam: 'sourceDescription',\r\n reportedParam: 'reportedDescription',\r\n reportedOverride: 'reportedDescriptionHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text },\r\n isRowShown: () => !classRef.createNewAsset\r\n },\r\n {\r\n label: 'Cost',\r\n labelHelpContentId: 'asset-info.cost-row-label',\r\n cellClass: 'costAssetDescriptors-0',\r\n labelTemplate: { type: CustomTemplateTypes.CostAdjustments, isCustom: true, isDoubleWidth: false },\r\n descriptorList: 'costAssetDescriptors',\r\n descriptorHelpContentId: 'asset-info.costAssetDescriptors',\r\n descriptor: {\r\n columnName: null,\r\n companyAssetDescriptorMappingId: 0,\r\n companyId: null,\r\n descriptor: null,\r\n pickList: null\r\n },\r\n sourceParam: 'sourceCost',\r\n reportedParam: 'reportedCost',\r\n reportedOverride: 'reportedCostHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n reportedValueGetter: classRef.formatTransientCost.bind(classRef),\r\n isDisabled: () => classRef.assetListForm.value.costAssetDescriptors > 0,\r\n isSourceCellShown: function() {\r\n return !this.labelTemplate.isDoubleWidth;\r\n },\r\n onChange: classRef.onTransientReportedCostChange.bind(classRef)\r\n },\r\n {\r\n label: 'Net Book Value',\r\n labelHelpContentId: 'asset-info.net-book-value-row-label',\r\n sourceParam: 'sourceNetBookValue',\r\n reportedParam: 'reportedNetBookValue',\r\n reportedOverride: 'reportedNetBookValueHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n isRowShown: () => !classRef.createNewAsset\r\n },\r\n {\r\n label: 'G/L Account',\r\n sourceParam: 'sourceGlAccountDisplay',\r\n reportedParam: 'reportedGlAccountDisplay',\r\n reportedOverride: 'reportedGlAccountHasOverride',\r\n reportedTemplate: { type: CustomTemplateTypes.GlAccount, isCustom: true },\r\n isRowShown: () => !classRef.createNewAsset,\r\n onClear: classRef.onGlAccountRemoveOverride.bind(classRef)\r\n },\r\n {\r\n label: 'Site',\r\n sourceParam: 'sourceSiteDisplay',\r\n reportedParam: 'reportedSiteDisplay',\r\n reportedOverride: 'reportedSiteHasOverride',\r\n reportedTemplate: { type: CustomTemplateTypes.Sites, isCustom: true },\r\n onClear: classRef.onSiteRemoveOverride.bind(classRef)\r\n },\r\n {\r\n label: 'Lease Type',\r\n sourceParam: 'sourceLeaseTypeDisplay',\r\n reportedParam: 'reportedLeaseTypeId',\r\n reportedOverride: 'reportedLeaseTypeHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Picklist },\r\n picklist: [],\r\n isRowShown: () => classRef.createNewAsset && classRef.currentAsset.isLeasedAsset\r\n },\r\n {\r\n label: 'Asset Class',\r\n sourceParam: 'sourceAssetClassificationDisplay',\r\n reportedParam: 'reportedAssetClassificationId',\r\n reportedOverride: 'assetClassificationHasOverride',\r\n reportedTemplate: { type: CustomTemplateTypes.AssetClass, isCustom: true },\r\n reportedValueGetter: classRef.getAssetClassName.bind(classRef),\r\n onClear: classRef.onAssetClassificationRemoveValue.bind(classRef),\r\n isRowShown: () => !classRef.createNewAsset\r\n },\r\n {\r\n label: 'Parcel',\r\n labelHelpContentId: 'asset-info.site-calculated-parcel',\r\n sourceParam: 'sourceParcelName',\r\n reportedParam: 'reportedParcelId',\r\n reportedOverride: 'reportedParcelHasOverride',\r\n reportedTemplate: { type: CustomTemplateTypes.ParcelSelector, isCustom: true },\r\n reportedValueGetter: classRef.getParcelName.bind(classRef),\r\n isRowShown: () => !classRef.createNewAsset\r\n }\r\n];\r\n\r\nexport const LEASED_TO_FIELDS: AssetLeasedInfoField[] = [\r\n {\r\n label: 'Lease Customer ID',\r\n sourceParam: 'sourceLeaseClientId',\r\n reportedParam: 'reportedLeaseClientId',\r\n reportedOverride: 'reportedLeaseClientIdHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n },\r\n {\r\n label: 'Location Name',\r\n sourceParam: 'sourceLeaseLocationName',\r\n reportedParam: 'reportedLeaseLocationName',\r\n reportedOverride: 'reportedLeaseLocationNameHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n },\r\n {\r\n label: 'Location Address',\r\n sourceParam: 'sourceLeaseAddress',\r\n reportedParam: 'reportedLeaseAddress',\r\n reportedOverride: 'reportedLeaseAddressHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n },\r\n {\r\n label: 'Location City',\r\n sourceParam: 'sourceLeaseCity',\r\n reportedParam: 'reportedLeaseCity',\r\n reportedOverride: 'reportedLeaseCityHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n },\r\n {\r\n label: 'Location State',\r\n sourceParam: 'sourceLeaseState',\r\n reportedParam: 'reportedLeaseState',\r\n reportedOverride: 'reportedLeaseStateHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text, maxLength: 2 }\r\n },\r\n {\r\n label: 'Location Zip',\r\n sourceParam: 'sourceLeaseZip',\r\n reportedParam: 'reportedLeaseZip',\r\n reportedOverride: 'reportedLeaseZipHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n }\r\n];\r\n\r\nexport const LEASED_TO_FROM_FIELDS: AssetLeasedInfoField[] = [\r\n {\r\n label: 'Lease Asset ID',\r\n sourceParam: 'sourceLeaseAssetId',\r\n reportedParam: 'reportedLeaseAssetId',\r\n reportedOverride: 'reportedLeaseAssetIdHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n },\r\n {\r\n label: 'Lease Start Date',\r\n sourceParam: 'sourceLeaseStartDate',\r\n reportedParam: 'reportedLeaseStartDate',\r\n reportedOverride: 'reportedLeaseStartDateHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Date }\r\n },\r\n {\r\n label: 'Lease End Date',\r\n sourceParam: 'sourceLeaseEndDate',\r\n reportedParam: 'reportedLeaseEndDate',\r\n reportedOverride: 'reportedLeaseEndDateHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Date }\r\n },\r\n {\r\n label: 'Lease Term In Months',\r\n sourceParam: 'sourceLeaseTermInMonths',\r\n reportedParam: 'reportedLeaseTermInMonths',\r\n reportedOverride: 'reportedLeaseTermInMonthsHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Number }\r\n },\r\n {\r\n label: 'Lease Monthly Payment',\r\n sourceParam: 'sourceLeaseMonthlyPayment',\r\n reportedParam: 'reportedLeaseMonthlyPayment',\r\n reportedOverride: 'reportedLeaseMonthlyPaymentHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency }\r\n },\r\n {\r\n label: 'Lease Type',\r\n sourceParam: 'sourceLeaseTypeId',\r\n reportedParam: 'reportedLeaseTypeId',\r\n reportedOverride: 'reportedLeaseTypeIdHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Picklist },\r\n picklist: []\r\n },\r\n {\r\n label: 'Lease Number',\r\n sourceParam: 'sourceLeaseNumber',\r\n reportedParam: 'reportedLeaseNumber',\r\n reportedOverride: 'reportedLeaseNumberHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n },\r\n {\r\n label: 'Billing Name',\r\n sourceParam: 'sourceLeaseBillingName',\r\n reportedParam: 'reportedLeaseBillingName',\r\n reportedOverride: 'reportedLeaseBillingNameHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n },\r\n {\r\n label: 'Billing Address',\r\n sourceParam: 'sourceLeaseBillingAddress',\r\n reportedParam: 'reportedLeaseBillingAddress',\r\n reportedOverride: 'reportedLeaseBillingAddressHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n },\r\n {\r\n label: 'Billing City',\r\n sourceParam: 'sourceLeaseBillingCity',\r\n reportedParam: 'reportedLeaseBillingCity',\r\n reportedOverride: 'reportedLeaseBillingCityHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n },\r\n {\r\n label: 'Billing State',\r\n sourceParam: 'sourceLeaseBillingState',\r\n reportedParam: 'reportedLeaseBillingState',\r\n reportedOverride: 'reportedLeaseBillingStateHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text, maxLength: 2 }\r\n },\r\n {\r\n label: 'Billing Zip',\r\n sourceParam: 'sourceLeaseBillingZip',\r\n reportedParam: 'reportedLeaseBillingZip',\r\n reportedOverride: 'reportedLeaseBillingZipHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Text }\r\n }\r\n];\r\n\r\nexport const INVENTORY_FIELDS: AssetInventoryField[] = [\r\n {\r\n label: 'Jan Balance',\r\n sourceParam: 'sourceInventoryJan',\r\n reportedParam: 'reportedInventoryJan',\r\n reportedOverride: 'reportedInventoryJanHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 1\r\n },\r\n {\r\n label: 'Feb Balance',\r\n sourceParam: 'sourceInventoryFeb',\r\n reportedParam: 'reportedInventoryFeb',\r\n reportedOverride: 'reportedInventoryFebHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 2\r\n },\r\n {\r\n label: 'Mar Balance',\r\n sourceParam: 'sourceInventoryMar',\r\n reportedParam: 'reportedInventoryMar',\r\n reportedOverride: 'reportedInventoryMarHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 3\r\n },\r\n {\r\n label: 'Apr Balance',\r\n sourceParam: 'sourceInventoryApr',\r\n reportedParam: 'reportedInventoryApr',\r\n reportedOverride: 'reportedInventoryAprHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 4\r\n },\r\n {\r\n label: 'May Balance',\r\n sourceParam: 'sourceInventoryMay',\r\n reportedParam: 'reportedInventoryMay',\r\n reportedOverride: 'reportedInventoryMayHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 5\r\n },\r\n {\r\n label: 'Jun Balance',\r\n sourceParam: 'sourceInventoryJun',\r\n reportedParam: 'reportedInventoryJun',\r\n reportedOverride: 'reportedInventoryJunHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 6\r\n },\r\n {\r\n label: 'Jul Balance',\r\n sourceParam: 'sourceInventoryJul',\r\n reportedParam: 'reportedInventoryJul',\r\n reportedOverride: 'reportedInventoryJulHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 7\r\n },\r\n {\r\n label: 'Aug Balance',\r\n sourceParam: 'sourceInventoryAug',\r\n reportedParam: 'reportedInventoryAug',\r\n reportedOverride: 'reportedInventoryAugHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 8\r\n },\r\n {\r\n label: 'Sep Balance',\r\n sourceParam: 'sourceInventorySep',\r\n reportedParam: 'reportedInventorySep',\r\n reportedOverride: 'reportedInventorySepHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 9\r\n },\r\n {\r\n label: 'Oct Balance',\r\n sourceParam: 'sourceInventoryOct',\r\n reportedParam: 'reportedInventoryOct',\r\n reportedOverride: 'reportedInventoryOctHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 10\r\n },\r\n {\r\n label: 'Nov Balance',\r\n sourceParam: 'sourceInventoryNov',\r\n reportedParam: 'reportedInventoryNov',\r\n reportedOverride: 'reportedInventoryNovHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 11\r\n },\r\n {\r\n label: 'Dec Balance',\r\n sourceParam: 'sourceInventoryDec',\r\n reportedParam: 'reportedInventoryDec',\r\n reportedOverride: 'reportedInventoryDecHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: 12\r\n },\r\n {\r\n label: 'Avg Balance',\r\n sourceParam: 'sourceInventoryAvr',\r\n reportedParam: 'reportedInventoryAvr',\r\n reportedOverride: 'reportedInventoryAvrHasOverride',\r\n reportedTemplate: { type: Core.DescriptorFieldTypes.Currency },\r\n month: -1,\r\n isCalculated: 'reportedInventoryAvrIsCalculated'\r\n }\r\n];\r\n","
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n","import { Component, Input, Output, EventEmitter } from '@angular/core';\r\nimport { FilterCheckbox } from './assetAdvancedDetails.component';\r\n\r\n@Component({\r\n selector: 'advanced-detail-checkbox',\r\n templateUrl: './assetAdvancedDetailCheckbox.component.html'\r\n})\r\nexport class AssetAdvancedDetailCheckboxComponent {\r\n @Input() options: Array;\r\n\r\n @Output() changed: EventEmitter = new EventEmitter();\r\n\r\n /**\r\n * Apply the change from clicking the label of the checkbox\r\n * @param check\r\n */\r\n changedFromClick(check: FilterCheckbox): void {\r\n check.formControl.setValue(!check.formControl.value);\r\n this.changed.emit(check);\r\n }\r\n}\r\n","\r\n
\r\n \r\n Calculated Source Cost: {{calculatedCost | currency: 'USD'}}\r\n \r\n \r\n Unattributed Source Percent: {{ unattributedPercent }}\r\n \r\n
\r\n
\r\n
\r\n
\r\n
Asset Number
\r\n
Percentage Cost
\r\n
Cost
\r\n
\r\n
\r\n
{{ asset.reportedAssetNumber }}
\r\n
\r\n \r\n %\r\n
\r\n
{{ costAmounts[i] | currency: 'USD'}}
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AssetSummary } from '../../../Models/assetSummary';\r\nimport { Decimal } from 'decimal.js';\r\nimport { IWeissmanModalComponent } from '../../../../WeissmanModalService';\r\n\r\nexport interface AssetInfoCostEditorParams {\r\n assets: AssetSummary[];\r\n calculatedCost: number;\r\n alternativeCostMappingModel: Compliance.CompanyAssetDescriptorMappingModel\r\n}\r\n\r\nexport interface AssetInfoCostEditorResult{\r\n costAmounts: number[];\r\n}\r\n\r\n@Component({\r\n selector: 'asset-info-cost-editor',\r\n templateUrl: './assetInfoCostEditor.component.html'\r\n})\r\nexport class AssetInfoCostEditorComponent implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private _bsModalRef: BsModalRef\r\n ) { }\r\n\r\n params: AssetInfoCostEditorParams;\r\n result: AssetInfoCostEditorResult;\r\n\r\n percentages: number[] = [];\r\n assets: AssetSummary[];\r\n calculatedCost: number;\r\n unattributedPercent: number;\r\n costAmounts: number[] = [];\r\n\r\n ngOnInit() {\r\n this.assets = this.params.assets;\r\n this.calculatedCost = this.params.calculatedCost;\r\n this.unattributedPercent = 100;\r\n for (let i = 0; i < this.assets.length; i++) {\r\n this.percentages[i] = 0;\r\n this.costAmounts[i] = 0;\r\n }\r\n\r\n //TRY TO CALCULATE PERCENTAGES\r\n // if no overrides, split as 100 to primary\r\n // if no override on first asset, set to 100, otherwise take best estimate\r\n let percentagesIt: number = 0;\r\n if (this.calculatedCost > 0) {\r\n this.assets.forEach((asset: AssetSummary) => {\r\n const columnName = this._getAlternativeCostColumnName(asset);\r\n if (asset.reportedColumnHasOverride(columnName)) {\r\n const costAmount = new Decimal(asset[`reported${columnName}`]);\r\n const percentage = costAmount.dividedBy(new Decimal(this.calculatedCost)).times(100).toDecimalPlaces(2);\r\n this.percentages[percentagesIt] = percentage.toNumber();\r\n } else {\r\n this.percentages[percentagesIt] = asset.isPrimary ? 100 : 0;\r\n }\r\n percentagesIt++;\r\n });\r\n this.onUpdatePercentages();\r\n }\r\n }\r\n\r\n onUpdatePercentages() {\r\n this.unattributedPercent = 100;\r\n\r\n let unattributedPercentDecimal = new Decimal(100);\r\n // clip percentages at 100\r\n for (let i = 0; i < this.percentages.length; i++) {\r\n if (this.percentages[i] > 100) {\r\n this.percentages[i] = 100;\r\n }\r\n }\r\n\r\n this.percentages.forEach((percent: number) => {\r\n unattributedPercentDecimal = unattributedPercentDecimal.minus(new Decimal(percent === null ? 0 : percent));\r\n });\r\n\r\n this.unattributedPercent = unattributedPercentDecimal.toDecimalPlaces(2).toNumber();\r\n\r\n // calculate real amounts\r\n const realAmounts: number[] = [];\r\n let totalAmount = 0;\r\n this.percentages.forEach((percent: number) => {\r\n const amount = new Decimal(percent).times(this.calculatedCost).dividedBy(100);\r\n const roundedAmount = amount.toDecimalPlaces(2).toNumber();\r\n realAmounts.push(roundedAmount);\r\n totalAmount += roundedAmount;\r\n });\r\n\r\n // check left over amount, assign to first with largest value, if all percent is used\r\n const leftOver = this.calculatedCost - totalAmount;\r\n if (this.unattributedPercent === 0) {\r\n if (leftOver > 0) {\r\n const highestValue = Math.max(...realAmounts);\r\n const index = realAmounts.findIndex(element => element === highestValue);\r\n realAmounts[index] = new Decimal(realAmounts[index]).plus(leftOver).toDecimalPlaces(2).toNumber();\r\n } else if (leftOver < 0) {\r\n const lowestValue = Math.min(...realAmounts);\r\n const index = realAmounts.lastIndexOf(lowestValue);\r\n realAmounts[index] = new Decimal(realAmounts[index]).plus(leftOver).toDecimalPlaces(2).toNumber();\r\n }\r\n }\r\n\r\n this.costAmounts = realAmounts;\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n saveDisabled(): boolean {\r\n return this.unattributedPercent !== 0;\r\n }\r\n\r\n save(): void {\r\n this.result = {\r\n costAmounts: this.costAmounts\r\n };\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _getAlternativeCostColumnName(asset: AssetSummary): string {\r\n const altCostMappingModel = this.params.alternativeCostMappingModel;\r\n if (altCostMappingModel !== null && asset.reportedColumnHasOverride(altCostMappingModel.columnName)) {\r\n return altCostMappingModel.columnName;\r\n } else {\r\n return 'Cost';\r\n }\r\n }\r\n\r\n}\r\n"," 0\">\r\n\r\n\r\n
\r\n \r\n
\r\n \r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n \r\n
\r\n\r\n\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n\r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n\r\n\r\n
\r\n \r\n
\r\n \r\n
\r\n\r\n\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n\r\n\r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n 1 && !classRef.assetCostsMatchCalculatedTotals && !classRef.createNewAsset && (classRef.assetListForm && classRef.assetListForm.controls.costAssetDescriptors.value === field.descriptor.companyAssetDescriptorMappingId)\" class=\"percentageWarning\" title=\"Source adjusted cost does not match allocated total of {{ classRef.allocatedTotal }}\">\r\n \r\n \r\n \r\n \r\n {{(field.sourceValueGetter) ? field.sourceValueGetter(row[field.reportedParam], field) : formatValue(row[field.sourceParam], field.reportedTemplate)}}\r\n \r\n \r\n \r\n
{{ classRef.getCostAdjustmentDescription() }}
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Field\r\n Source Value\r\n \r\n
\r\n \r\n Reporting Value 1\" class=\"text-muted\">(split {{(i + 1)}} of {{assets.length}})\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n {{field.label}}\r\n \r\n \r\n \r\n \r\n {{(field.sourceValueGetter) ? field.sourceValueGetter(currentAsset[field.sourceParam], field) : formatValue(currentAsset[field.sourceParam], field.reportedTemplate)}}\r\n \r\n \r\n
\r\n {{(field.sourceValueGetter) ? field.sourceValueGetter(currentAsset[field.sourceParam], field) : formatValue(currentAsset[field.sourceParam], field.reportedTemplate)}}\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n {{(field.reportedValueGetter) ? field.reportedValueGetter(asset, field) : formatValue(asset[field.reportedParam], field.reportedTemplate)}}\r\n \r\n {{asset.reportedIsAnchored ? '' : 'Not'}} Anchored\r\n Do not potentially dispose\r\n
\r\n
\r\n \r\n \r\n
\r\n
0 && assetListForm.get(field.descriptorList).value === field.descriptor.companyAssetDescriptorMappingId && (asset.reportedColumnHasOverride(field.descriptor.columnName) || asset[field.sourceParam])\"\r\n [ngStyle]=\"{ 'top': arrowBounds[field.descriptorList].top + 'px', left: arrowBounds[field.descriptorList].left + 15 + 'px' }\">\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
FieldSource Value\r\n
\r\n \r\n Reporting Value 1\" class=\"text-muted\">(split {{(i + 1)}} of {{assets.length}})\r\n \r\n
\r\n
{{field.label}}{{formatValue(currentAsset[field.sourceParam], field.reportedTemplate)}}\r\n
\r\n \r\n {{formatValue(asset[field.reportedParam], field.reportedTemplate)}}\r\n \r\n
\r\n
\r\n \r\n
\r\n
{{field.label}}{{formatValue(currentAsset[field.sourceParam], field.reportedTemplate)}}\r\n
\r\n \r\n {{formatValue(asset[field.reportedParam], field.reportedTemplate)}}\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
FieldSource Value\r\n
\r\n \r\n Reporting Value 1\" class=\"text-muted\">(split {{(i + 1)}} of {{assets.length}})\r\n \r\n
\r\n
{{field.label}}{{formatValue(currentAsset[field.sourceParam], field.reportedTemplate)}}\r\n
\r\n \r\n {{formatValue(asset[field.reportedParam], field.reportedTemplate)}}\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n","import { Component, ElementRef, EventEmitter, Input, OnDestroy, OnInit, Output, TemplateRef, ViewChild } from '@angular/core';\r\nimport { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms';\r\nimport { lastValueFrom, sequenceEqual, Subject } from 'rxjs';\r\nimport { distinctUntilChanged, takeUntil } from 'rxjs/operators';\r\nimport { BusyIndicatorMessageManager } from '../../../../Busy-Indicator';\r\nimport {\r\n AssetClassificationRepository,\r\n AssetRepository,\r\n CostAdjustmentRepository,\r\n ReportingParcelRepository\r\n} from '../../../Repositories';\r\nimport { AssetInfoService } from './assetInfo.service';\r\nimport { AssetInfoCostEditorComponent, AssetInfoCostEditorParams } from './Cost-Editor/assetInfoCostEditor.component';\r\nimport { AssetSummary } from '../../Models/assetSummary';\r\nimport { WeissmanModalService } from '../../../WeissmanModalService';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe';\r\nimport { WeissmanDateFormatPipe } from '../../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport {\r\n MessageModalButtons,\r\n MessageModalDisplayMode,\r\n MessageModalOptions,\r\n MessageModalResult,\r\n MessageModalService\r\n} from '../../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { CompanyService } from '../../../../Entity/Company/company.service';\r\nimport { CostAdjustmentHelpComponent } from '../costAdjustmentHelp.component';\r\nimport { HelpContent, HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport {\r\n ASSET_FIELDS,\r\n AssetInfoField,\r\n AssetInventoryField,\r\n AssetLeasedInfoField,\r\n AssetTemplate,\r\n CustomTemplateTypes,\r\n INVENTORY_FIELDS,\r\n LEASED_TO_FIELDS,\r\n LEASED_TO_FROM_FIELDS\r\n} from './assetInfo.columns';\r\n\r\nimport * as _ from 'lodash';\r\n\r\nimport { ChangeHistoryModalLaunchService } from '../../../../Common/Change-History/change-history-modal-launch.service';\r\nimport { ExtendedGLAccountModel } from './extendedGLAccountModel';\r\nimport { ExtendedSiteModel } from './extendedSiteModel';\r\nimport { StateSummary } from '../../../../Common/States/state.model';\r\nimport { AssetDescriptors } from '../assetDetails.component';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { InstanceRights, RestrictService } from '../../../../Common/Permissions/restrict.service';\r\nimport { TimerService } from '../../../../UI-Lib/Utilities/timer.service';\r\nimport DescriptorFieldTypes = Core.DescriptorFieldTypes;\r\n\r\nexport interface ExtendedCostAdjustmentTypeModel extends Compliance.CostAdjustmentTypeModel {\r\n applyToSource: boolean\r\n}\r\n\r\nexport interface FlattenedCostAdjustmentSource {\r\n typeName: string;\r\n costAdjustmentTypeId: number;\r\n applyToSource: boolean;\r\n sequence: number;\r\n states: Compliance.StateCostAdjustmentTypeModel[];\r\n}\r\n\r\nenum AssetInfoFieldsTab {\r\n Asset,\r\n Leasing,\r\n Inventory\r\n}\r\n\r\n@Component({\r\n selector: 'asset-info',\r\n templateUrl: './assetInfo.component.html',\r\n styleUrls: ['./assetInfo.component.scss']\r\n})\r\nexport class AssetInfoComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _assetRepository: AssetRepository,\r\n private readonly _assetInfoService: AssetInfoService,\r\n private readonly _costAdjustmentRepository: CostAdjustmentRepository,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _assetClassificationRepository: AssetClassificationRepository,\r\n private readonly _companyService: CompanyService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _changeHistoryModalLaunchService: ChangeHistoryModalLaunchService,\r\n private readonly _elementRef: ElementRef,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _helpService: HelpService,\r\n private readonly _reportingParcelRepository: ReportingParcelRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _timer: TimerService\r\n ) { }\r\n\r\n @Input() assets: AssetSummary[];\r\n @Input() reportingAssetId: number;\r\n @Input() lienDate: Date;\r\n @Input() createNewAsset: boolean;\r\n @Input() newAssetCompanyId: number;\r\n @Input() topLevelCompanyId: number;\r\n @Input() assetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[];\r\n\r\n @Input() states: StateSummary[];\r\n\r\n @Input()\r\n set assetDetailModel(value: Compliance.AssetDetailModel) {\r\n if (value) {\r\n this._assetDetailModel = value;\r\n this._populateAltToggleFields();\r\n }\r\n }\r\n get assetDetailModel(): Compliance.AssetDetailModel {\r\n return this._assetDetailModel;\r\n }\r\n\r\n @Input()\r\n set currentAsset(currentAsset: AssetSummary) {\r\n if (currentAsset) {\r\n this._currentAsset = currentAsset;\r\n this._primaryAssetIsLocked = currentAsset.isLocked;\r\n this._configureCurrentAsset();\r\n this._reloadArrows();\r\n }\r\n }\r\n get currentAsset(): AssetSummary {\r\n return this._currentAsset;\r\n }\r\n\r\n @Input()\r\n set isEditMode(editMode: boolean) {\r\n if (editMode) {\r\n this.enterEditState();\r\n } else {\r\n this.exitEditState();\r\n }\r\n }\r\n\r\n @Output() currentAssetChanged: EventEmitter = new EventEmitter();\r\n @Output() selectedDescriptorsChanged: EventEmitter = new EventEmitter();\r\n @Output() assetInfoReady: EventEmitter = new EventEmitter();\r\n\r\n @ViewChild('assetForm', { static: true }) assetForm;\r\n\r\n @ViewChild('text', { static: true }) textTemplate: ElementRef;\r\n @ViewChild('number', { static: true }) numberTemplate: ElementRef;\r\n @ViewChild('currency', { static: true }) currencyTemplate: ElementRef;\r\n @ViewChild('date', { static: true }) dateTemplate: ElementRef;\r\n @ViewChild('picklist', { static: true }) picklistTemplate: ElementRef;\r\n @ViewChild('yesNo', { static: true }) yesNoTemplate: ElementRef;\r\n\r\n @ViewChild('acqDate', { static: true }) acqDateTemplate: ElementRef;\r\n @ViewChild('assetClassification', { static: true }) assetClassTemplate: ElementRef;\r\n @ViewChild('companiesSelector', { static: true }) companiesSelector: ElementRef;\r\n @ViewChild('costAdjustments', { static: true }) costAdjustmentTemplate: ElementRef;\r\n @ViewChild('glAccount', { static: true }) glAccountTemplate: ElementRef;\r\n @ViewChild('parcelSelector', { static: true }) parcelSelectorTemplate: ElementRef;\r\n @ViewChild('sites', { static: true }) sitesTemplate: ElementRef;\r\n\r\n assetListForm: UntypedFormGroup;\r\n reportingAssetFormElement: any;\r\n arrowHelperElement: any;\r\n arrowBounds = {\r\n acqDateAssetDescriptors: {\r\n tooltip: 'asset-info.acquisition-date-selector-arrow',\r\n top: 0,\r\n left: 0,\r\n height: '0px',\r\n width: '0px',\r\n dPath: '',\r\n arrowPoints: ''\r\n },\r\n costAssetDescriptors: {\r\n tooltip: 'asset-info.cost-selector-arrow',\r\n top: 0,\r\n left: 0,\r\n height: '0px',\r\n width: '0px',\r\n dPath: '',\r\n arrowPoints: ''\r\n }\r\n };\r\n\r\n assetListFields: AssetInfoField[] = ASSET_FIELDS(this);\r\n leasedToFields: AssetLeasedInfoField[] = LEASED_TO_FIELDS;\r\n leasedToFromFields: AssetLeasedInfoField[] = LEASED_TO_FROM_FIELDS;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n editMode: boolean = false;\r\n\r\n costAdjustments: { [s: string]: Compliance.AssetCostAdjustmentModel } = {};\r\n extendedCostAdjustmentTypes: ExtendedCostAdjustmentTypeModel[] = [];\r\n costAdjustmentControlsVisible: boolean = false;\r\n costFieldValue: string;\r\n costAssetDescriptors: Compliance.CompanyAssetDescriptorMappingModel[];\r\n costAdjustmentTypes: Compliance.CostAdjustmentTypeModel[];\r\n glAccountFilter: string = '';\r\n assetIndex: number = null;\r\n childCompanies: { id: number; name: string }[] = [];\r\n selectedCompanyId: number = null;\r\n topLevelCompanyName: string = '';\r\n ownershipTypes: Compliance.NameValuePair[] = [];\r\n leaseTypes: Compliance.LeaseTypeModel[];\r\n costAdjustmentHelpDescription: string = '';\r\n hasOldAssetNumber: boolean = false;\r\n altAcqDateId: number = 0;\r\n altCostId: number = 0;\r\n canSeeHistory: boolean = false;\r\n\r\n customRenderer: HelpContent;\r\n\r\n AssetInfoFieldsTab = AssetInfoFieldsTab;\r\n\r\n private _currentAsset: AssetSummary;\r\n private _assetClassifications: Compliance.AssetClassificationModel[] = [];\r\n private _assetDetailModel: Compliance.AssetDetailModel;\r\n private _inventoryFields: AssetInventoryField[] = INVENTORY_FIELDS;\r\n\r\n private _templateMap: Map;\r\n private _customTemplateMap: Map;\r\n private _selectedFieldsTab: AssetInfoFieldsTab = AssetInfoFieldsTab.Asset;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n private _primaryAssetIsLocked: boolean = false;\r\n\r\n get costFieldHasSource() {\r\n return this._assetInfoService.hasSourceValue;\r\n }\r\n\r\n get assetCostsMatchCalculatedTotals(): boolean {\r\n return this._assetInfoService.assetValueMatched;\r\n }\r\n\r\n get allocatedTotal(): number {\r\n return this._assetInfoService.allocatedTotal;\r\n }\r\n\r\n get classRef(): AssetInfoComponent {\r\n return this;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n // Set custom help tooltip\r\n this.customRenderer = {\r\n helpContentId: 'asset-info.cost-row-label',\r\n hasIcon: true,\r\n helpContentComponent: {\r\n component: CostAdjustmentHelpComponent,\r\n canHover: true,\r\n hasIcon: true\r\n }\r\n };\r\n this._helpService.updateContent([this.customRenderer]);\r\n\r\n // Create template maps\r\n this._templateMap = new Map([\r\n [Core.DescriptorFieldTypes.Date, this.dateTemplate],\r\n [Core.DescriptorFieldTypes.Number, this.numberTemplate],\r\n [Core.DescriptorFieldTypes.Picklist, this.picklistTemplate],\r\n [Core.DescriptorFieldTypes.YesNo, this.yesNoTemplate],\r\n [Core.DescriptorFieldTypes.Text, this.textTemplate],\r\n [Core.DescriptorFieldTypes.Currency, this.currencyTemplate]\r\n ]);\r\n\r\n this._customTemplateMap = new Map([\r\n [CustomTemplateTypes.AcqDate, this.acqDateTemplate],\r\n [CustomTemplateTypes.AssetClass, this.assetClassTemplate],\r\n [CustomTemplateTypes.Companies, this.companiesSelector],\r\n [CustomTemplateTypes.CostAdjustments, this.costAdjustmentTemplate],\r\n [CustomTemplateTypes.GlAccount, this.glAccountTemplate],\r\n [CustomTemplateTypes.ParcelSelector, this.parcelSelectorTemplate],\r\n [CustomTemplateTypes.Sites, this.sitesTemplate]\r\n ]);\r\n\r\n this.assetListForm = this._fb.group({\r\n acqDateAssetDescriptors: [0],\r\n costAssetDescriptors: [0]\r\n });\r\n\r\n this.assetListForm.valueChanges\r\n .pipe(distinctUntilChanged(), takeUntil(this._destroy$))\r\n .subscribe(x => this.selectedDescriptorsChanged.next(x));\r\n\r\n this.assetListForm.get('acqDateAssetDescriptors').valueChanges\r\n .pipe(takeUntil(this._destroy$), distinctUntilChanged())\r\n .subscribe(id => {\r\n if (id) {\r\n this._timer.setTimeout(() => this._drawArrow(`.acqDateAssetDescriptors-${id}`, '.acqDateAssetDescriptors-0', this.arrowBounds.acqDateAssetDescriptors));\r\n }\r\n this.altAcqDateId = id;\r\n });\r\n\r\n this.assetListForm.get('costAssetDescriptors').valueChanges\r\n .pipe(takeUntil(this._destroy$), distinctUntilChanged())\r\n .subscribe(id => {\r\n this.altCostId = id;\r\n this.calculateCosts();\r\n\r\n this.assetListFields.filter(f => f.labelTemplate && f.labelTemplate.type === CustomTemplateTypes.CostAdjustments).forEach(f => f.labelTemplate.isDoubleWidth = false);\r\n if (id) {\r\n this.setCostAdjustmentControlsVisible(false);\r\n\r\n this._timer.setTimeout(() => this._drawArrow(`.costAssetDescriptors-${id}`, '.costAssetDescriptors-0', this.arrowBounds.costAssetDescriptors), 0);\r\n } else {\r\n this.setCostAdjustmentControlsVisible(this.hasCostAdjustments());\r\n }\r\n });\r\n\r\n this._assetInfoService.clearValues();\r\n\r\n const classifications = await lastValueFrom(this._assetClassificationRepository.getAssetClassifications());\r\n this._assetClassifications = [];\r\n classifications.forEach(x => this._flattenAssetClassifications(x, this._assetClassifications));\r\n\r\n this.costAdjustmentTypes = await lastValueFrom(this._costAdjustmentRepository.getTypes());\r\n\r\n // Add descriptors to list\r\n this._setDescriptors(Core.DescriptorCategoryEnum.AssetAquisitionDate, this.onAltAcqDateIdChange, 'acqDateAssetDescriptors');\r\n this._setCostDescriptors();\r\n this._setStandardDescriptors(Core.DescriptorCategoryEnum.AssetCost);\r\n this.costAssetDescriptors = this.assetDescriptors.filter(x => x.descriptor.category === Core.DescriptorCategoryEnum.AssetCost);\r\n\r\n this._getOwnershipTypes();\r\n this._getLeaseTypes();\r\n\r\n // Set up new asset\r\n if (this.createNewAsset) {\r\n this.childCompanies = (await this._companyService.getSubsidiaries(this.topLevelCompanyId, true)).sort((a, b) => {\r\n return a.name.localeCompare(b.name);\r\n });\r\n this.topLevelCompanyName = await this._companyService.getCompanyName(this.topLevelCompanyId);\r\n this.selectedCompanyId = this.newAssetCompanyId;\r\n\r\n this.onOwnershipTypeChange(this.ownershipTypes[0].value);\r\n\r\n this.enterEditState();\r\n }\r\n\r\n // Set up existing asset\r\n if (!this.createNewAsset) {\r\n // transientReportedCost should get updated by calculated cost, unless there is no source\r\n this._assetInfoService.calculatedCostUpdated$.pipe(takeUntil(this._destroy$)).subscribe((calculatedCost) => {\r\n if (!(this.assets && this.assets.length)) { return; }\r\n this.assets.forEach(asset => {\r\n if (!this._assetInfoService.hasSourceValue) {\r\n asset.transientReportedCost = null;\r\n } else if (asset.isPrimary) {\r\n asset.transientReportedCost = calculatedCost;\r\n } else {\r\n asset.transientReportedCost = 0;\r\n }\r\n });\r\n });\r\n }\r\n\r\n this.canSeeHistory = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW) ||\r\n this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT);\r\n\r\n this.assetInfoReady.next(true);\r\n\r\n this._populateAltToggleFields();\r\n this._updateCostAdjustmentTypes();\r\n this._updateCostAdjustments(); // called inside setAssets but skipped pre initialized\r\n this._reloadArrows();\r\n }\r\n\r\n ngOnDestroy() {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n add(): void {\r\n const asset = this.currentAsset.getModel();\r\n const newAsset = _.cloneDeep(asset);\r\n newAsset.reportingAsset.reportingAssetId = 0;\r\n newAsset.reportingAssetOverride = newAsset.reportingAssetOverride || {} as Compliance.ReportingAssetOverrideModel;\r\n newAsset.reportingAssetOverride.reportingAssetId = 0;\r\n newAsset.reportingAsset.isPrimary = false;\r\n\r\n // Remove cost overrides on split\r\n newAsset.reportingAssetOverride.cost = null;\r\n\r\n this.costAssetDescriptors.forEach((assetDescriptor: Compliance.CompanyAssetDescriptorMappingModel) =>\r\n {\r\n newAsset.reportingAssetOverride[assetDescriptor.columnName.toLowerCase()] = null;\r\n });\r\n\r\n if (!newAsset.reportingAssetOverride) {\r\n newAsset.reportingAssetOverride = {\r\n reportingAssetId: 0,\r\n reportingAssetOverrideId: 0,\r\n rowVersion: null,\r\n isGLAccountIdBlank: false\r\n };\r\n }\r\n\r\n // get the highest split number\r\n let splitNum = 0;\r\n\r\n const regex = new RegExp('_([0-9]{3})$', 'g');\r\n this.assets.forEach(\r\n x => {\r\n const matches = regex.exec(x.reportedAssetNumber);\r\n regex.lastIndex = 0;\r\n if (matches && matches.length === 2) {\r\n const num = +matches[1];\r\n if (num && num > splitNum) {\r\n splitNum = num;\r\n }\r\n }\r\n });\r\n\r\n splitNum = splitNum + 1;\r\n\r\n // pad left with 0s\r\n const padded = `000${splitNum}`;\r\n const suffix = padded.substr(padded.length - 3);\r\n\r\n newAsset.reportingAssetOverride.assetNumber = `${asset.assetNumber}_${suffix}`;\r\n\r\n const newAssetSummary = new AssetSummary(newAsset, this._keyValueDisplayPipe, null);\r\n\r\n this.assets.push(newAssetSummary);\r\n this.assetIndex = this.assets.length - 1;\r\n this.currentAsset = newAssetSummary;\r\n this.currentAssetChanged.next(this.currentAsset);\r\n }\r\n\r\n async delete(assetToDelete: AssetSummary): Promise {\r\n try {\r\n await this._messageModalService.confirm(\r\n `Are you sure you wish to delete '${assetToDelete.reportedAssetNumber}'?`,\r\n 'Confirm Delete');\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n // find asset index\r\n const assetIndex = this.assets.findIndex((asset: AssetSummary) => asset.reportingAssetId === assetToDelete.reportingAssetId);\r\n this.assets.splice(assetIndex, 1);\r\n\r\n let index = assetIndex - 1;\r\n if (index < 0) {\r\n index = 0;\r\n }\r\n\r\n this.currentAsset = this.assets[index];\r\n this.currentAssetChanged.next(this.currentAsset);\r\n return Promise.resolve();\r\n }\r\n\r\n isFormDirty(): boolean {\r\n return this.editMode || (this.assetForm && this.assetForm.dirty);\r\n }\r\n\r\n enterEditState(): void {\r\n this._populateAltToggleFields();\r\n this.editMode = true;\r\n this._configureCurrentAsset();\r\n this.calculateCosts();\r\n this._reloadArrows();\r\n }\r\n\r\n exitEditState(): void {\r\n this.editMode = false;\r\n this.assetForm.resetForm();\r\n this._populateAltToggleFields();\r\n this.calculateCosts();\r\n this._reloadArrows();\r\n }\r\n\r\n getTemplate(template: AssetTemplate): TemplateRef {\r\n return (!template.isCustom)\r\n ? this._templateMap.get(template.type) as unknown as TemplateRef\r\n : this._customTemplateMap.get(template.type) as unknown as TemplateRef;\r\n }\r\n\r\n templateValueChange(value: any, asset: AssetSummary, field: AssetInfoField): void {\r\n if (field.onChange) {\r\n field.onChange(value, asset, field);\r\n } else {\r\n asset[field.reportedParam] = value;\r\n }\r\n }\r\n\r\n formatValue(value: string, template: AssetTemplate): string {\r\n if (template.isCustom) {\r\n switch (template.type) {\r\n case CustomTemplateTypes.AcqDate:\r\n return value ? this._datePipe.transform(new Date(value), true) : '';\r\n default:\r\n return value;\r\n }\r\n }\r\n switch (template.type) {\r\n case Core.DescriptorFieldTypes.Date:\r\n return value ? this._datePipe.transform(new Date(value), true) : '';\r\n case Core.DescriptorFieldTypes.Currency:\r\n return this._decimalPipe.transform(value, '1.2-2');\r\n case DescriptorFieldTypes.YesNo:\r\n return value ? 'Yes' : 'No';\r\n default:\r\n return value;\r\n }\r\n }\r\n\r\n trackByFieldParam(index: number, field: AssetLeasedInfoField): string {\r\n return field.reportedParam;\r\n }\r\n\r\n trackByAssetId(index: number, asset: AssetSummary): number {\r\n return asset.assetId;\r\n }\r\n\r\n viewHistory(asset: AssetSummary): void {\r\n this._changeHistoryModalLaunchService.openChangeHistoryModal(\r\n asset.sourceAssetNumber,\r\n asset.reportingAssetId, Core.EntityTypes.Asset, 'ReportingAsset');\r\n }\r\n\r\n cancel(): void {\r\n // close outer modal\r\n }\r\n\r\n clearValue(asset: AssetSummary, field: AssetInfoField): void {\r\n if (field.onClear) {\r\n field.onClear(asset, field);\r\n } else {\r\n asset[field.reportedParam] = null;\r\n }\r\n }\r\n\r\n /**\r\n * Ownership type logic\r\n */\r\n\r\n onOwnershipTypeChange(ownershipTypeId: number): void {\r\n if (!(this.assets && this.assets.length)) {\r\n return;\r\n }\r\n\r\n this.assets.forEach(a => {\r\n a.assetOwnershipTypeId = ownershipTypeId;\r\n });\r\n }\r\n\r\n getOwnershipTypeDescription(asset: AssetSummary): string {\r\n const ownershipType = this.ownershipTypes.find(x => x.value === asset.assetOwnershipTypeId);\r\n return ownershipType ? ownershipType.name : '';\r\n }\r\n\r\n /**\r\n * Company Logic\r\n */\r\n\r\n getCompanyNameFromId(asset: AssetSummary, field: AssetInfoField): string {\r\n if (!this.createNewAsset) {\r\n return asset.companyName;\r\n } else if (asset[field.reportedParam] === this.topLevelCompanyId) {\r\n return this.topLevelCompanyName;\r\n } else {\r\n const company = this.childCompanies.find(c => c.id === asset[field.reportedParam]);\r\n return (company) ? company.name : '';\r\n }\r\n }\r\n\r\n updateSelectedCompanyId(id: number, asset: AssetSummary): void {\r\n this._assetInfoService.selectedCompanyId = id;\r\n this.selectedCompanyId = id;\r\n if (asset) {\r\n this.onGlAccountSelected(null, asset);\r\n this.onSiteSelected(null, asset);\r\n }\r\n }\r\n\r\n /**\r\n * Acquisition Date Logic\r\n */\r\n\r\n formatAlternativeDate(): string {\r\n let value;\r\n if (this.altAcqDateId === 0) {\r\n value = this.currentAsset.reportedAcqDate;\r\n } else {\r\n const field = this.assetListFields.find(x => (x.descriptor && x.descriptor.companyAssetDescriptorMappingId) === this.altAcqDateId);\r\n if (!field) {\r\n return '';\r\n }\r\n value = this.currentAsset[field.reportedParam];\r\n if (!value) {\r\n return null;\r\n }\r\n }\r\n\r\n return (this.editMode && !this.currentAsset.isLocked) ? value : this.formatValue(value, { type: Core.DescriptorFieldTypes.Date });\r\n }\r\n\r\n onAcquisitionDateChanged(acqDate: Date): void {\r\n if (this.assets && this.assets.length > 0) {\r\n this.assets.forEach(asset => {\r\n asset.reportedAcqDate = acqDate;\r\n });\r\n }\r\n }\r\n\r\n onAltAcqDateIdChange(acqDate: Date, asset: AssetSummary, field: AssetInfoField): void {\r\n asset[field.reportedParam] = acqDate;\r\n if (this.assets && this.assets.length > 0 && this.currentAsset.isPrimary) {\r\n this.assets.forEach(x => {\r\n if (!x.isPrimary) {\r\n x[field.reportedParam] = acqDate;\r\n x.reportedAcqDate = acqDate;\r\n }\r\n });\r\n }\r\n }\r\n\r\n clearAcqDateOverride(): void {\r\n if (this.assets && this.assets.length > 0) {\r\n this.assets.forEach(asset => {\r\n asset.reportedAcqDate = null;\r\n });\r\n }\r\n }\r\n\r\n onIsPerpetualChanged(eventTarget: EventTarget, asset: AssetSummary): void {\r\n const isPerpetual = (eventTarget as HTMLInputElement).checked;\r\n asset.reportingIsPerpetual = isPerpetual;\r\n console.log('asset.reportingIsPerpetual', asset.reportingIsPerpetual);\r\n }\r\n\r\n /**\r\n * Disposed Date Logic\r\n */\r\n\r\n onDisposedDateChanged(disposedDate: Date): void {\r\n if (!(this.assets && this.assets.length)) {\r\n return;\r\n }\r\n\r\n this.assets.forEach(asset => {\r\n asset.reportedDisposedDate = disposedDate;\r\n });\r\n }\r\n\r\n clearDisposedDateOverride(): void {\r\n if (this.assets && this.assets.length > 0) {\r\n this.assets.forEach(asset => {\r\n asset.reportedDisposedDate = null;\r\n });\r\n }\r\n }\r\n\r\n /**\r\n * Cost Logic\r\n */\r\n\r\n isCostField(fieldType: Core.DescriptorFieldTypes | CustomTemplateTypes): boolean {\r\n return !this.altCostId && fieldType === Core.DescriptorFieldTypes.Currency;\r\n }\r\n\r\n showCostAdjustments(id: number): boolean {\r\n return this.altCostId === id && !this.createNewAsset && this.costFieldHasSource;\r\n }\r\n\r\n hasCostAdjustments(): boolean {\r\n let nonNullFound = false;\r\n\r\n if (!this.altCostId) {\r\n this.extendedCostAdjustmentTypes.forEach((x: ExtendedCostAdjustmentTypeModel) => {\r\n const adjustment = this.costAdjustments[x.costAdjustmentTypeId];\r\n if (adjustment && (adjustment.adjustmentAmount !== null || adjustment.adjustmentPercentage !== null)) {\r\n nonNullFound = true;\r\n }\r\n });\r\n }\r\n\r\n return nonNullFound;\r\n }\r\n\r\n setCostAdjustmentControlsVisible(visible: boolean): void {\r\n this.costAdjustmentControlsVisible = visible;\r\n //double the width of the cell\r\n const costField = this.assetListFields\r\n .find(f => f.descriptor && f.descriptor.companyAssetDescriptorMappingId === this.altCostId && f.labelTemplate && f.labelTemplate.type === CustomTemplateTypes.CostAdjustments);\r\n if (costField) {\r\n costField.labelTemplate.isDoubleWidth = visible;\r\n }\r\n }\r\n\r\n formatTransientCost(asset: AssetSummary, field: AssetInfoField): number | string {\r\n if (this.editMode) {\r\n return (this.altCostId === 0) ? asset.transientReportedCost : this.getAlternativeCostOrOverride(asset);\r\n } else {\r\n if (this.altCostId > 0) {\r\n const value = this.getAlternativeCostOrOverride(asset);\r\n return this.formatValue(value, { type: Core.DescriptorFieldTypes.Currency });\r\n } else if (!(this.altCostId > 0) && !asset.reportedCostHasOverride) {\r\n return asset.isPrimary ? this.formatAlternativeCost() : '0.00';\r\n } else if (!(this.altCostId > 0) && asset.reportedCostHasOverride) {\r\n return this.formatValue(`${asset.reportedCost}`, { type: Core.DescriptorFieldTypes.Currency });\r\n }\r\n }\r\n return null;\r\n }\r\n\r\n formatAlternativeCost(): string {\r\n const output = this._assetInfoService.calculatedCost;\r\n return output ? output : '';\r\n }\r\n\r\n getAlternativeCostDisplay(asset: AssetSummary, field: AssetInfoField): string {\r\n const selectedCost = this.assetListForm.get(field.descriptorList);\r\n if (selectedCost && selectedCost.value !== field.descriptor.companyAssetDescriptorMappingId) {\r\n if (asset.reportedColumnHasOverride(field.descriptor.columnName)) {\r\n return this.formatValue(asset[field.reportedParam], { type: Core.DescriptorFieldTypes.Currency });\r\n } else {\r\n return null;\r\n }\r\n }\r\n\r\n if (this.editMode) {\r\n return asset[`transientReported${field.descriptor.columnName.toUpperCase()}`];\r\n } else {\r\n const value = this.getAlternativeCostOrOverride(asset);\r\n return this.formatValue(value, { type: Core.DescriptorFieldTypes.Currency });\r\n }\r\n }\r\n\r\n getAlternativeCostOrOverride(asset: AssetSummary): string {\r\n const target = this.assetListFields.find(f => f.descriptor && f.descriptor.companyAssetDescriptorMappingId === this.altCostId);\r\n if (!target) { return '0'; }\r\n\r\n if (asset.reportedColumnHasOverride(target.descriptor.columnName)) {\r\n return asset[target.reportedParam];\r\n }\r\n\r\n // Primary gets the cost, non primaries get 0 - unless there is no source\r\n if (this._assetInfoService.hasSourceValue) {\r\n return `${asset.isPrimary ? this._assetInfoService.calculatedCostValue : 0}`;\r\n } else {\r\n return null;\r\n }\r\n }\r\n\r\n onTransientReportedCostChange(event: any): void {\r\n // if this is different than the current calculated value (or 0 for split), persist as a real override\r\n\r\n const expectedValue = this.currentAsset.isPrimary ? this._assetInfoService.calculatedCostValue : 0;\r\n if (event && event.target && event.target.value != null && ((!this._assetInfoService.hasSourceValue) || parseFloat(event.target.value) !== expectedValue)) {\r\n this.currentAsset.reportedCost = event.target.value;\r\n }\r\n\r\n this.calculateCosts();\r\n }\r\n\r\n onTransientAlternateReportedCostChange(event: any, asset: AssetSummary, field: AssetInfoField): void {\r\n const expectedValue = asset.isPrimary ? this._assetInfoService.calculatedCostValue : 0;\r\n if (event.target && event.target.value && ((!this._assetInfoService.hasSourceValue) || parseFloat(event.target.value)) !== expectedValue) {\r\n asset[field.reportedParam] = event.target.value;\r\n asset[`transientReported${field.descriptor.columnName.toUpperCase()}`] = event.target.value;\r\n }\r\n\r\n this.calculateCosts();\r\n }\r\n\r\n getCostAdjustmentDescription(value: string, field: AssetInfoField): string {\r\n return (this.costFieldHasSource && this._assetInfoService.costAdjustmentDescription\r\n && (field && this.showCostAdjustments(field.descriptor.companyAssetDescriptorMappingId)))\r\n ? this._assetInfoService.costAdjustmentDescription\r\n : this.formatValue(value, { type: Core.DescriptorFieldTypes.Currency });\r\n }\r\n\r\n async showCostPercentageModal(): Promise {\r\n const params: AssetInfoCostEditorParams = {\r\n assets: this.assets,\r\n calculatedCost: this._assetInfoService.calculatedCostValue,\r\n alternativeCostMappingModel: this.getCostCompanyAssetDescriptorMappingModel()\r\n };\r\n\r\n const result = await this._modalService.showAsync(AssetInfoCostEditorComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n const altCostMappingModel: Compliance.CompanyAssetDescriptorMappingModel = this.getCostCompanyAssetDescriptorMappingModel();\r\n for (let i = 0; i < this.assets.length; i++) {\r\n const asset: AssetSummary = this.assets[i];\r\n const costAmount: number = result.costAmounts[i];\r\n const expectedValue = asset.isPrimary ? this._assetInfoService.calculatedCostValue : 0;\r\n\r\n asset.transientReportedCost = costAmount;\r\n // now update non transient setting\r\n if (costAmount !== expectedValue) {\r\n // use override\r\n if (altCostMappingModel != null) {\r\n const fieldName = `reported${altCostMappingModel.columnName.toUpperCase()}`;\r\n asset[fieldName] = costAmount;\r\n } else {\r\n asset.reportedCost = costAmount;\r\n }\r\n } else {\r\n // clear override\r\n if (altCostMappingModel != null) {\r\n const fieldName = `reported${altCostMappingModel.columnName.toUpperCase()}`;\r\n asset[fieldName] = null;\r\n } else {\r\n asset.reportedCost = null;\r\n }\r\n }\r\n }\r\n\r\n this.calculateCosts();\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n showAssignByPercentageButton(): boolean {\r\n if (this._assetInfoService.hasSourceValue && this.editMode && this.assets.length > 1) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n allowPerpetual(): boolean {\r\n const selectedAssetClassification = this._assetClassifications.find(\r\n x => x.assetClassificationId === this.currentAsset.reportedAssetClassificationId);\r\n return selectedAssetClassification && selectedAssetClassification.allowPerpetual;\r\n }\r\n\r\n calculateCosts(): void {\r\n if (this.currentAsset && !this.createNewAsset) {\r\n let sourceFieldValue;\r\n\r\n const altCostMappingModel = this.getCostCompanyAssetDescriptorMappingModel();\r\n\r\n if (!altCostMappingModel) {\r\n sourceFieldValue = this.currentAsset.sourceCost;\r\n } else {\r\n sourceFieldValue = this.currentAsset[`source${altCostMappingModel.columnName}`];\r\n }\r\n\r\n this._assetInfoService.calculateCostsAndCheckTotals(sourceFieldValue, this.costAdjustments, this.assets);\r\n }\r\n }\r\n\r\n getCostCompanyAssetDescriptorMappingModel(): Compliance.CompanyAssetDescriptorMappingModel {\r\n if (this.altCostId > 0) {\r\n const field = this.assetListFields.find(x => x.descriptor && x.descriptor.companyAssetDescriptorMappingId === this.altCostId);\r\n return field && field.descriptor;\r\n }\r\n return null;\r\n }\r\n\r\n /**\r\n * Asset Class Logic\r\n */\r\n\r\n onAssetClassificationChanged(assetClassificationId: number, asset: AssetSummary): void {\r\n const selectedAssetClassification = this._assetClassifications.find(x => x.assetClassificationId === assetClassificationId);\r\n asset.classificationAllowsPerpetual = selectedAssetClassification && selectedAssetClassification.allowPerpetual;\r\n //clear possible stale true value if new classification is not allowed\r\n if (selectedAssetClassification && !selectedAssetClassification.allowPerpetual) {\r\n asset.reportingIsPerpetual = false;\r\n }\r\n }\r\n\r\n getAssetClassName(asset: AssetSummary): string {\r\n return asset.reportedAssetClassificationDisplay;\r\n }\r\n\r\n onAssetClassificationRemoveValue(asset: AssetSummary): void {\r\n // when removing, default to GL account asset classification\r\n asset.reportedAssetClassificationId = asset.reportedGlAccountClassificationId || asset.sourceGlAccountClassificationId;\r\n if (!asset.reportedAssetClassificationId) { return; }\r\n\r\n // if the new asset class doesn't allow perpetual, set accordingly\r\n const selectedAssetClassification = this._assetClassifications.find(x => x.assetClassificationId === asset.reportedAssetClassificationId);\r\n\r\n if (selectedAssetClassification && !selectedAssetClassification.allowPerpetual) {\r\n asset.reportingIsPerpetual = false;\r\n }\r\n }\r\n\r\n /**\r\n * GL Account Logic\r\n */\r\n\r\n onGlAccountSelected(selected: ExtendedGLAccountModel, asset: AssetSummary): void {\r\n if (!selected) {\r\n asset.reportedGlAccount = null;\r\n asset.isReportedGlAccountBlank = true;\r\n return;\r\n }\r\n\r\n const glAccount = selected.model;\r\n if (!asset.reportedGlAccount || (asset.reportedGlAccount && asset.reportedGlAccount.assetClassificationId === asset.reportedAssetClassificationId)) {\r\n asset.reportedAssetClassificationId = glAccount.assetClassificationId;\r\n }\r\n\r\n // don't set an override if one doesn't exist and the classification matches the reported value (meaning source)\r\n if (!(asset.reportedGlAccount && glAccount.assetClassificationId === asset.reportedGlAccount.assetClassificationId && !asset.reportedGlAccountHasOverride)) {\r\n asset.reportedGlAccount = glAccount;\r\n asset.isReportedGlAccountBlank = false;\r\n }\r\n }\r\n\r\n onGlAccountRemoveOverride(asset: AssetSummary): void {\r\n // clear override and restore filter back to the source value if one exists\r\n asset.reportedGlAccount = null;\r\n asset.isReportedGlAccountBlank = (asset.reportedSiteHasOverride && asset.reportedSite.companyID !== asset.companyId);\r\n }\r\n\r\n /**\r\n * Site Logic\r\n */\r\n\r\n onSiteSelected(selected: ExtendedSiteModel, asset: AssetSummary): void {\r\n if (!selected || selected.model.siteID === asset.reportedSiteId) { return; }\r\n\r\n this.onGlAccountSelected(null, asset);\r\n asset.reportedSite = selected ? selected.model : null;\r\n if (selected?.model.reportingParcelId) {\r\n asset.reportedParcelId = selected.model.reportingParcelId;\r\n }\r\n\r\n if (this.createNewAsset && selected && this._assetInfoService.selectedCompanyId !== selected.model.companyID) {\r\n this.updateSelectedCompanyId(selected.model.companyID, asset);\r\n }\r\n }\r\n\r\n onSiteRemoveOverride(asset: AssetSummary): void {\r\n // clear override and restore filter back to the source value if one exists\r\n asset.reportedSite = null;\r\n if (asset.parcelHasOverride) {\r\n asset.reportedParcelId = null;\r\n }\r\n }\r\n\r\n /**\r\n * Parcel Logic\r\n */\r\n\r\n getParcelName(asset: AssetSummary): string {\r\n return asset.reportedParcelName;\r\n }\r\n\r\n getParcels = async (searchParams: any): Promise> => {\r\n return await lastValueFrom(this._reportingParcelRepository.getReportingParcelsByAsset(searchParams));\r\n };\r\n\r\n /**\r\n * Inventory Logic\r\n * @returns {}\r\n */\r\n\r\n get selectedFieldsTab(): AssetInfoFieldsTab{\r\n return this._selectedFieldsTab;\r\n }\r\n\r\n set selectedFieldsTab(value: AssetInfoFieldsTab){\r\n this._selectedFieldsTab = value;\r\n }\r\n\r\n get inventoryFields(): AssetInventoryField[] {\r\n return this._inventoryFields;\r\n }\r\n\r\n get showInventoryFields(): boolean {\r\n let showInventoryFields: boolean = false;\r\n\r\n this.assets.forEach((asset) => {\r\n showInventoryFields = !!(asset.reportedInventoryJan ||\r\n asset.reportedInventoryFeb ||\r\n asset.reportedInventoryMar ||\r\n asset.reportedInventoryApr ||\r\n asset.reportedInventoryMay ||\r\n asset.reportedInventoryJun ||\r\n asset.reportedInventoryJul ||\r\n asset.reportedInventoryAug ||\r\n asset.reportedInventorySep ||\r\n asset.reportedInventoryOct ||\r\n asset.reportedInventoryNov);\r\n\r\n if (!showInventoryFields) {\r\n const assetClassificationId = asset.reportedAssetClassificationId;\r\n\r\n if (assetClassificationId && this._assetClassifications) {\r\n const selectedAssetClassification = this._assetClassifications.find(\r\n x => x.assetClassificationId === assetClassificationId);\r\n\r\n showInventoryFields = selectedAssetClassification && selectedAssetClassification.isInventory;\r\n }\r\n }\r\n\r\n if (showInventoryFields) {\r\n return false;\r\n }\r\n });\r\n\r\n if (!showInventoryFields && this.selectedFieldsTab === AssetInfoFieldsTab.Inventory){\r\n this.selectedFieldsTab = AssetInfoFieldsTab.Asset;\r\n }\r\n\r\n return showInventoryFields;\r\n }\r\n\r\n overrideAll(asset: AssetSummary): void {\r\n this.assetListFields\r\n .filter(x =>\r\n x.reportedTemplate &&\r\n x.reportedParam &&\r\n !(x.reportedTemplate.isStatic && x.reportedTemplate.isStatic()) &&\r\n !((x.descriptor && x.descriptor.columnName) ? asset.reportedColumnHasOverride(x.descriptor.columnName) : asset[x.reportedOverride]) &&\r\n x.reportedParam !== 'reportedIsLocked')\r\n .forEach(x => this._overrideField(x, asset));\r\n\r\n this.inventoryFields.forEach(x => this._overrideField(x, asset));\r\n\r\n if (asset.isLeasedToOther) {\r\n this.leasedToFields.forEach(x => this._overrideField(x, asset));\r\n this.leasedToFromFields.forEach(x => this._overrideField(x, asset));\r\n } else if (asset.isLeasedFromOther) {\r\n this.leasedToFromFields.forEach(x => this._overrideField(x, asset));\r\n }\r\n }\r\n\r\n onDoNoPotentiallyDisposeChanged(value: boolean): void {\r\n if (!(this.assets && this.assets.length)) {\r\n return;\r\n }\r\n\r\n this.assets\r\n .filter(asset => !asset.isPrimary)\r\n .forEach(asset => {\r\n asset.reportedDoNotPotentiallyDispose = value;\r\n });\r\n }\r\n\r\n async onIsLockedChange(isLocked: boolean, asset: AssetSummary): Promise {\r\n if (!(this.assets && this.assets.length)) {\r\n return;\r\n }\r\n\r\n this._primaryAssetIsLocked = isLocked;\r\n\r\n if (isLocked) {\r\n this.overrideAll(asset);\r\n } else {\r\n try {\r\n const options: MessageModalOptions = {\r\n displayMode: MessageModalDisplayMode.SingleMessage,\r\n buttons: MessageModalButtons.YesNo,\r\n focusButton: MessageModalResult.Yes,\r\n message: 'Do you want to remove overrides?',\r\n title: 'Confirm'\r\n };\r\n\r\n await this._messageModalService.open(options);\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._removeOverrideAll(asset);\r\n }\r\n }\r\n\r\n getIsLockedDisplayValue(asset: AssetSummary): string {\r\n return asset.reportedIsLocked ? 'Yes' : 'No';\r\n }\r\n\r\n get primaryAssetIsLocked(): boolean {\r\n return this._primaryAssetIsLocked;\r\n }\r\n\r\n private _overrideField(x: AssetInfoField, asset: AssetSummary) {\r\n console.log('overrideField for ', x.reportedParam);\r\n switch (x.reportedParam) {\r\n case 'reportedGlAccountDisplay':\r\n asset.reportedGlAccount = asset.sourceGlAccount;\r\n break;\r\n case 'reportedCost':\r\n asset.reportedCost = +this.formatTransientCost(asset, x);\r\n break;\r\n case 'reportedSiteDisplay':\r\n asset.reportedSite = asset.sourceSite;\r\n\r\n if (!asset.parcelHasOverride && asset.sourceSiteReportingParcelId) {\r\n asset.reportedParcelId = asset.sourceSiteReportingParcelId;\r\n }\r\n break;\r\n // case 'reportedParcelId':\r\n // break;\r\n default:\r\n if (asset[x.sourceParam] !== null && asset[x.sourceParam] != undefined) {\r\n this.templateValueChange(asset[x.sourceParam], asset, x);\r\n }\r\n break;\r\n }\r\n }\r\n\r\n private _setCostDescriptors(): void {\r\n this._setDescriptors(Core.DescriptorCategoryEnum.AssetCost, this.onTransientAlternateReportedCostChange, 'costAssetDescriptors');\r\n this.assetListFields.filter(f => f.descriptorList === 'costAssetDescriptors').forEach(f => {\r\n if (f.descriptor.companyAssetDescriptorMappingId > 0) {\r\n const template = { type: CustomTemplateTypes.CostAdjustments, isCustom: true };\r\n f.labelTemplate = template;\r\n f.sourceValueGetter = this.getCostAdjustmentDescription.bind(this);\r\n f.reportedValueGetter = this.getAlternativeCostDisplay.bind(this);\r\n f.isSourceCellShown = function() {\r\n return !this.labelTemplate.isDoubleWidth;\r\n };\r\n }\r\n });\r\n }\r\n\r\n private _setDescriptors(descriptorType: Core.DescriptorCategoryEnum, onChange: any, listName?: string): void {\r\n const addAtIndex = (listName) ? this.assetListFields.findIndex(f => f.descriptorList === listName) : this.assetListFields.length - 1;\r\n if (addAtIndex === -1) { return; }\r\n const primary = this.assetListFields[addAtIndex];\r\n primary.descriptorCount = 0;\r\n this.assetDescriptors\r\n .filter(x => x.descriptor.category === descriptorType)\r\n .map((d, i, a) => this._fieldFromDescriptor(d, onChange, listName, a.length))\r\n .forEach(f => {\r\n this.assetListFields.splice(addAtIndex, 0, f);\r\n primary.descriptorCount += 1;\r\n });\r\n }\r\n\r\n private _setStandardDescriptors(descriptorType: Core.DescriptorCategoryEnum): void {\r\n const updateByReportedParam = (value: any, asset: AssetSummary, field: AssetInfoField) => {\r\n asset[field.reportedParam] = value;\r\n };\r\n const updateYesNo = (value: any, asset: AssetSummary, field: AssetInfoField) => {\r\n asset[field.reportedParam] = value ? 1 : 0;\r\n };\r\n\r\n this.assetDescriptors\r\n .filter(x => !([Core.DescriptorCategoryEnum.AssetCost, Core.DescriptorCategoryEnum.AssetAquisitionDate] as Core.DescriptorCategoryEnum[]).includes(x.descriptor.category))\r\n .map(d => {\r\n let onChange = updateByReportedParam;\r\n\r\n if (d.descriptor.fieldType === DescriptorFieldTypes.YesNo) {\r\n onChange = updateYesNo;\r\n }\r\n return this._fieldFromDescriptor(d, onChange, null, null);\r\n })\r\n .forEach(f => this.assetListFields.push(f));\r\n }\r\n\r\n private _fieldFromDescriptor(descriptor: Compliance.CompanyAssetDescriptorMappingModel, onChange: any, listName: string, count: number): AssetInfoField {\r\n const result: AssetInfoField = {\r\n label: descriptor.descriptor.name,\r\n cellClass: `${listName}-${descriptor.companyAssetDescriptorMappingId}`,\r\n descriptorList: listName,\r\n descriptorCount: count,\r\n descriptorHelpContentId: `asset-info.${listName}`,\r\n descriptor: descriptor,\r\n sourceParam: `source${descriptor.columnName}`,\r\n reportedParam: `reported${descriptor.columnName}`,\r\n reportedOverride: '',\r\n reportedTemplate: { type: descriptor.descriptor.fieldType, maxLength: descriptor.descriptor.validation && descriptor.descriptor.validation.maxLength },\r\n isDisabled: (row: AssetSummary) => this.assetListForm.value[listName] >= 0 && this.assetListForm.value[listName] !== descriptor.companyAssetDescriptorMappingId || (row && !row.isPrimary && listName === 'acqDateAssetDescriptors'),\r\n onChange: onChange.bind(this),\r\n isRowShown: () => !this.createNewAsset,\r\n picklist: descriptor.pickList && descriptor.pickList.map(x => {return {name: x.name, value: x.name};})\r\n };\r\n\r\n if (result.picklist && result.picklist.length !== 0) {\r\n result.reportedValueGetter = (asset: AssetSummary, field: AssetInfoField) => {\r\n const selectedOption = result.picklist.find(x => x.value === asset[field.reportedParam]);\r\n\r\n return selectedOption ? selectedOption.name : '';\r\n };\r\n }\r\n\r\n return result;\r\n }\r\n\r\n private async _getOwnershipTypes(): Promise {\r\n const ownershipTypes: Compliance.AssetOwnershipTypeModel[] = await lastValueFrom(this._assetRepository.getOwnershipTypes());\r\n this.ownershipTypes = ownershipTypes.map(l => ({ name: l.description, value: l.assetOwnershipTypeId }));\r\n const picklistField = this.assetListFields.find(f => f.sourceParam === 'assetOwnershipTypeId');\r\n picklistField.picklist = this.ownershipTypes;\r\n }\r\n\r\n private async _getLeaseTypes(): Promise {\r\n this.leaseTypes = await lastValueFrom(this._assetRepository.getLeaseTypes());\r\n let picklistField;\r\n if (this.createNewAsset) {\r\n picklistField = this.assetListFields.find(f => f.reportedParam === 'reportedLeaseTypeId');\r\n } else {\r\n picklistField = this.leasedToFromFields.find(f => f.reportedParam === 'reportedLeaseTypeId');\r\n }\r\n picklistField.picklist = this.leaseTypes.map(l => ({ name: l.leaseTypeId, value: l.leaseTypeId }));\r\n }\r\n\r\n private _flattenAssetClassifications(classification: Compliance.AssetClassificationModel, classifications: Compliance.AssetClassificationModel[]): void {\r\n classifications.push(classification);\r\n\r\n if (classification.childClassifications && classification.childClassifications.length) {\r\n classification.childClassifications.forEach(\r\n (x) => { this._flattenAssetClassifications(x, classifications); });\r\n }\r\n }\r\n\r\n private _updateCostAdjustments(): void {\r\n // need to update in component\r\n if (this.extendedCostAdjustmentTypes) {\r\n\r\n this.extendedCostAdjustmentTypes.forEach(x => {\r\n const costAdjustments = this.currentAsset.getModel().costAdjustments;\r\n const adjustment = costAdjustments && costAdjustments.find(y => y.costAdjustmentTypeId === x.costAdjustmentTypeId);\r\n if (adjustment) {\r\n const addAdjustment = { ...adjustment };\r\n if (addAdjustment.adjustmentAmount === 0) {\r\n addAdjustment.adjustmentAmount = null;\r\n }\r\n if (addAdjustment.adjustmentPercentage === 0) {\r\n addAdjustment.adjustmentPercentage = null;\r\n }\r\n if (addAdjustment.adjustmentPercentage !== null) {\r\n addAdjustment.adjustmentPercentage = addAdjustment.adjustmentPercentage * 100;\r\n }\r\n this.costAdjustments[x.costAdjustmentTypeId] = addAdjustment;\r\n } else {\r\n this.costAdjustments[x.costAdjustmentTypeId] = {\r\n adjustmentAmount: null,\r\n adjustmentPercentage: null,\r\n assetCostAdjustmentId: null,\r\n stateCostAdjustmentId: null,\r\n rowVersion: null,\r\n costAdjustmentTypeId: x.costAdjustmentTypeId\r\n };\r\n }\r\n });\r\n\r\n this._assetInfoService.costAdjustments = this.costAdjustments;\r\n this.calculateCosts();\r\n }\r\n }\r\n\r\n private _updateCostAdjustmentTypes(): void {\r\n const stateAbbr = this.currentAsset ? this.currentAsset.state : null;\r\n if (!stateAbbr || !this.costAdjustmentTypes) {\r\n return;\r\n }\r\n\r\n const state = this.states.find(x => x.abbr === stateAbbr);\r\n const stateId = state && state.stateID;\r\n\r\n const filteredTypes = this.costAdjustmentTypes.filter(x => x.states.find(y => y.stateId === stateId) ? true : false);\r\n const flattenedTypes: FlattenedCostAdjustmentSource[] = filteredTypes.map(type => {\r\n const typeState = type.states.find(x => x.stateId === stateId);\r\n return {\r\n typeName: type.typeName,\r\n costAdjustmentTypeId: type.costAdjustmentTypeId,\r\n applyToSource: typeState.applyToSource,\r\n sequence: typeState.sequence,\r\n states: []\r\n };\r\n });\r\n\r\n const sequencedCostAdjustments = flattenedTypes.sort((a, b) => a.sequence - b.sequence);\r\n this.extendedCostAdjustmentTypes = sequencedCostAdjustments;\r\n this.customRenderer.componentParams = { value: sequencedCostAdjustments };\r\n this._assetInfoService.extendedCostAdjustmentTypes = this.extendedCostAdjustmentTypes;\r\n\r\n }\r\n\r\n private _configureCurrentAsset(): void {\r\n this.hasOldAssetNumber = !!(this.currentAsset.sourceOldAssetNumber || this.assets.find(x => !!x.reportedOldAssetNumber));\r\n\r\n this._updateCostAdjustmentTypes();\r\n this._updateCostAdjustments();\r\n this.setCostAdjustmentControlsVisible(this.hasCostAdjustments());\r\n this.calculateCosts();\r\n\r\n if (this._assetInfoService.hasSourceValue) {\r\n this.currentAsset.transientReportedCost = this.currentAsset.isPrimary ? this._assetInfoService.calculatedCostValue : 0;\r\n } else {\r\n this.currentAsset.transientReportedCost = null;\r\n }\r\n }\r\n\r\n private _populateAltToggleFields(): void {\r\n if (this.assetListForm && this.assetDetailModel) {\r\n this.assetListForm.patchValue({\r\n acqDateAssetDescriptors: this.assetDetailModel.alternativeAcqDateDescriptorId ? this.assetDetailModel.alternativeAcqDateDescriptorId : 0,\r\n costAssetDescriptors: this.assetDetailModel.alternativeCostDescriptorId ? this.assetDetailModel.alternativeCostDescriptorId : 0\r\n });\r\n }\r\n }\r\n\r\n private _reloadArrows(): void {\r\n if (this.altAcqDateId) {\r\n this._timer.setTimeout(() => this._drawArrow(`.acqDateAssetDescriptors-${this.altAcqDateId}`, '.acqDateAssetDescriptors-0', this.arrowBounds.acqDateAssetDescriptors), 0);\r\n }\r\n\r\n if (this.altCostId) {\r\n this._timer.setTimeout(() => this._drawArrow(`.costAssetDescriptors-${this.altCostId}`, '.costAssetDescriptors-0', this.arrowBounds.costAssetDescriptors), 0);\r\n }\r\n }\r\n\r\n private _drawArrow(originId: string, targetId: string, arrowDataHolder: any): void {\r\n const target = this._elementRef.nativeElement.querySelectorAll(targetId)[0];\r\n const origin = this._elementRef.nativeElement.querySelectorAll(originId)[0];\r\n\r\n if (origin && target) {\r\n const originBounds = origin.getBoundingClientRect();\r\n const targetBounds = target.getBoundingClientRect();\r\n\r\n const arrowRightDistance = 40;\r\n\r\n arrowDataHolder.top = (originBounds.height / 2) - 6;\r\n arrowDataHolder.left = originBounds.width / 2;\r\n arrowDataHolder.height = `${targetBounds.top - originBounds.top + 10}px`;\r\n arrowDataHolder.width = `${arrowRightDistance + 10}px`;\r\n\r\n const rightTop = arrowRightDistance - 10;\r\n const rightBottom = targetBounds.top - originBounds.top - 10;\r\n\r\n arrowDataHolder.dPath = `M0,2 H${rightTop} a10,10 0 0 1 10,10 V${rightBottom} a10,10 0 0 1 -10,10 H6`;\r\n\r\n const arrowOffset = targetBounds.top - originBounds.top;\r\n\r\n arrowDataHolder.arrowPoints = `3,${arrowOffset} 9,${arrowOffset + 3} 9,${arrowOffset - 3}`;\r\n }\r\n }\r\n\r\n private _removeOverrideAll(asset: AssetSummary): void {\r\n this.assetListFields\r\n .filter(x =>\r\n x.reportedTemplate &&\r\n x.reportedParam &&\r\n !(x.reportedTemplate.isStatic && x.reportedTemplate.isStatic()) &&\r\n (x.descriptor && x.descriptor.columnName ? asset.reportedColumnHasOverride(x.descriptor.columnName) : asset[x.reportedOverride]) &&\r\n x.reportedParam !== 'reportedIsLocked' &&\r\n (asset.isPrimary || x.reportedParam !== 'reportedAssetNumber' && x.reportedParam !== 'reportedCost'))\r\n .forEach(x => this.clearValue(asset, x));\r\n\r\n this.inventoryFields.forEach(x => this.clearValue(asset, x));\r\n\r\n if (asset.isLeasedToOther) {\r\n this.leasedToFields.forEach(x => this.clearValue(asset, x));\r\n this.leasedToFromFields.forEach(x => this.clearValue(asset, x));\r\n } else if (asset.isLeasedFromOther) {\r\n this.leasedToFromFields.forEach(x => this.clearValue(asset, x));\r\n }\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy, Input } from '@angular/core';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridColumns } from '../../../AgGrid/agGridColumns';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { AssetReturnFilingStatusCellRendererComponent } from './agGridStatusCellRenderer.component';\r\nimport { AgGridFilterParams } from '../../../AgGrid/agGridFilterParams';\r\nimport { AgGridOptionsBuilder } from '../../../AgGrid/index';\r\nimport { AssetRepository } from '../../../Repositories';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from '../../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\n\r\n@Component({\r\n selector: 'asset-return-filings',\r\n templateUrl: './assetReturnFilings.component.html'\r\n})\r\nexport class AssetReturnFilingsComponent implements OnInit {\r\n constructor(\r\n private readonly _assetRepository: AssetRepository,\r\n private readonly _decimalPipe: DecimalPipe) {\r\n }\r\n\r\n @Input() assetId: number;\r\n @Input() lienDate: Date;\r\n @Input() companyId: number;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder()\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _assetReturns: Compliance.AssetReturnModel[];\r\n\r\n\r\n async ngOnInit(): Promise {\r\n this._assetReturns = await lastValueFrom(this._assetRepository.getReturns(this.assetId));\r\n\r\n this._setRowData();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Tax Year',\r\n field: 'taxYear',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agNumberColumnFilter'\r\n },\r\n {\r\n headerName: 'Asset Number',\r\n field: 'assetNumber',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter'\r\n },\r\n {\r\n headerName: 'Filing',\r\n field: 'filingDescription',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-filing',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as Compliance.AssetReturnModel;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n return `#/filing/${filingControl.filingId}`;\r\n },\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Filing Batch',\r\n field: 'filingBatchDescription',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-filing',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as Compliance.AssetReturnModel;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n return `#/returnBatch/${filingControl.filingBatchId}`;\r\n },\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Form',\r\n field: 'formName',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter'\r\n },\r\n {\r\n headerName: 'Parcel Acct Num',\r\n field: 'parcelAccountNumber',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const filingControl = params.data as Compliance.AssetReturnModel;\r\n if (!filingControl) {\r\n return '';\r\n }\r\n return `#/parcel/${filingControl.parcelId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Schedule',\r\n field: 'scheduleName',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter'\r\n },\r\n {\r\n headerName: 'Factor Table',\r\n field: 'factorTableName',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter'\r\n },\r\n {\r\n headerName: 'Cost',\r\n field: 'cost',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => {\r\n return this._decimalPipe.transform(params.value, '1.2-2');\r\n },\r\n filter: 'agNumberColumnFilter'\r\n },\r\n {\r\n headerName: 'Reported Value',\r\n field: 'reportedValue',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.numericColumnWidth,\r\n valueFormatter: (params) => {\r\n return this._decimalPipe.transform(params.value, '1.2-2');\r\n },\r\n filter: 'agNumberColumnFilter'\r\n },\r\n {\r\n headerName: 'Status',\r\n field: 'status',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.textColumnSmallWidth,\r\n cellClass: 'status-text',\r\n cellRendererFramework: AssetReturnFilingStatusCellRendererComponent\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._assetReturns)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._assetReturns);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n}\r\n","
\r\n \r\n \r\n \r\n
\r\n","import { Component, OnInit, Input } from '@angular/core';\r\nimport { GridOptions, GridReadyEvent, GridApi, ColDef, RowNode } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { WeissmanDateFormatPipe, WeissmanDateTimeFormatPipe } from '../../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { AssetRepository } from '../../../Repositories/asset.repository';\r\nimport { AgGridOptionsBuilder } from '../../../AgGrid/agGridOptionsBuilder';\r\nimport { AgGridColumns } from '../../../AgGrid/agGridColumns';\r\nimport { ValueFormatterParams } from 'ag-grid-community/dist/lib/entities/colDef';\r\nimport * as _ from 'lodash';\r\n\r\ninterface AssetActivityLogRow {\r\n assetLogModel: Compliance.SourceAssetVerificationLogModel;\r\n effectiveDate: Date;\r\n actionDate: Date;\r\n fieldChanged: string;\r\n action: string;\r\n createdByName: string;\r\n changedTo: string;\r\n changedFrom: string;\r\n lastInGroup: boolean;\r\n masterRowCount: number;\r\n}\r\n\r\n@Component({\r\n selector: 'asset-activity-log',\r\n templateUrl: './assetActivityLog.component.html'\r\n})\r\nexport class AssetActivityLogComponent implements OnInit {\r\n constructor(\r\n private readonly _assetRepository: AssetRepository,\r\n private readonly _datePipe: WeissmanDateFormatPipe,\r\n private readonly _dateTimePipe: WeissmanDateTimeFormatPipe) { }\r\n\r\n @Input() reportingAssetId: number;\r\n\r\n gridOptions: GridOptions;\r\n private _gridApi: GridApi;\r\n private _activityLogData: Compliance.SourceAssetVerificationLogModel[];\r\n\r\n\r\n ngOnInit(): void {\r\n const gridOptions = new AgGridOptionsBuilder()\r\n .withContext(this)\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withLoadingOverlay()\r\n .withTextSelection()\r\n .build();\r\n gridOptions.getRowClass = this._getRowClass;\r\n gridOptions.postSort = this._postSort;\r\n\r\n this.gridOptions = gridOptions;\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Effective Date',\r\n field: 'effectiveDate',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.dateColumnWidth,\r\n valueFormatter: (params) => params.value ? this._datePipe.transform(params.value, true) : '',\r\n comparator: this._outerDateComparator.bind(this)\r\n },\r\n {\r\n headerName: 'Action Date',\r\n field: 'actionDate',\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.dateColumnWidth,\r\n valueFormatter: (params) => params.value ? this._dateTimePipe.transform(params.value, true, 'central') : '',\r\n comparator: this._outerDateComparator.bind(this)\r\n },\r\n {\r\n headerName: 'User',\r\n field: 'createdByName',\r\n sortable: false,\r\n width: AgGridColumns.textColumnMedWidth,\r\n },\r\n {\r\n headerName: 'Asset Action',\r\n field: 'action',\r\n sortable: false,\r\n width: AgGridColumns.textColumnMedWidth,\r\n },\r\n {\r\n headerName: 'Field Changed',\r\n field: 'fieldChanged',\r\n sortable: false,\r\n width: AgGridColumns.textColumnMedWidth,\r\n },\r\n {\r\n headerName: 'Old Value',\r\n field: 'changedFrom',\r\n sortable: false,\r\n width: AgGridColumns.textColumnMedWidth,\r\n valueFormatter: this._formatChangeField.bind(this, 'changedFrom'),\r\n cellRenderer: (params) => {\r\n const data = params.data as AssetActivityLogRow;\r\n let value = '';\r\n if (data.fieldChanged) {\r\n value = params.value ? params.valueFormatted : 'blank';\r\n }\r\n return value;\r\n },\r\n cellClass: this._getCellClass.bind(this),\r\n tooltipField: 'changedFrom',\r\n },\r\n {\r\n headerName: 'New Value',\r\n field: 'changedTo',\r\n sortable: false,\r\n suppressSizeToFit: true,\r\n width: AgGridColumns.textColumnWidth,\r\n valueFormatter: this._formatChangeField.bind(this, 'changedTo'),\r\n cellRenderer: (params) => {\r\n const data = params.data as AssetActivityLogRow;\r\n let value = '';\r\n if (data.fieldChanged) {\r\n value = params.value ? params.valueFormatted : 'blank';\r\n }\r\n return value;\r\n },\r\n cellClass: this._getCellClass.bind(this),\r\n tooltipField: 'changedTo',\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.sizeColumnsToFit();\r\n this._setData();\r\n }\r\n\r\n private _postSort(rowNodes: RowNode[]): void {\r\n // make a 0 based index\r\n let rowCount = 0;\r\n const newRowNodesArr: any[] = [];\r\n const renumbers: any = {};\r\n // start with the row nodes with an assetLogModel\r\n const masterNodesArr = rowNodes.filter(rowNode => rowNode.data && rowNode.data.assetLogModel);\r\n masterNodesArr.forEach(rowNode => {\r\n const oldRowIndex = rowNode.data.masterRowCount;\r\n let childrenRows = rowNodes.filter(node => (!node.data.assetLogModel) && node.data.masterRowCount === oldRowIndex);\r\n renumbers[oldRowIndex] = rowCount;\r\n\r\n childrenRows = _.sortBy(childrenRows, 'data.fieldName');\r\n newRowNodesArr.push(rowNode);\r\n newRowNodesArr.push(...childrenRows);\r\n rowCount++;\r\n });\r\n\r\n //resort\r\n newRowNodesArr.forEach(rowNode => {\r\n rowNode.data.masterRowCount = renumbers[rowNode.data.masterRowCount];\r\n });\r\n\r\n // post sort works by resorting original array\r\n rowNodes.splice(0, rowNodes.length, ...newRowNodesArr);\r\n }\r\n\r\n private _formatChangeField(field, params: ValueFormatterParams): string {\r\n switch (this._formattingType(params.value)) {\r\n case 'date':\r\n return params.value ? this._datePipe.transform(new Date(params.value), true) : '';\r\n case 'number':\r\n return `${Number(params.value)}`;\r\n default:\r\n return params.value;\r\n }\r\n }\r\n\r\n private _outerDateComparator(a, b, nodeA, nodeB, inverted): number {\r\n const dateA = new Date(a).getTime();\r\n const dateB = new Date(b).getTime();\r\n\r\n if (isNaN(dateA) && isNaN(dateB)) {\r\n return 0;\r\n }\r\n if (isNaN(dateA)) {\r\n return -1;\r\n }\r\n if (isNaN(dateB)) {\r\n return 1;\r\n }\r\n return dateA - dateB;\r\n }\r\n\r\n private async _setData(): Promise {\r\n this._activityLogData = await lastValueFrom(this._assetRepository.getActivityLog(this.reportingAssetId));\r\n const rowData = this._initializeRowData();\r\n const expandedRowData = this._expandRowData(rowData);\r\n this._gridApi.setRowData(expandedRowData);\r\n }\r\n\r\n private _getRowClass(params): string {\r\n let className: string = params.data.masterRowCount % 2 ? 'asset-activity-table-odd' : 'asset-activity-table-even';\r\n if (params.data.lastInGroup) {\r\n className += '-last';\r\n }\r\n return className;\r\n }\r\n\r\n private _getCellClass(params): string {\r\n return (this._formattingType(params.value) === 'number') ? 'text-align-right' : '';\r\n }\r\n\r\n private _initializeRowData(): AssetActivityLogRow[] {\r\n const rows: AssetActivityLogRow[] = [];\r\n this._activityLogData.forEach((row: Compliance.SourceAssetVerificationLogModel) => {\r\n rows.push({\r\n assetLogModel: row,\r\n effectiveDate: row.effectiveDate,\r\n actionDate: row.actionDate,\r\n action: row.action,\r\n createdByName: row.createdByName,\r\n fieldChanged: null,\r\n changedFrom: null,\r\n changedTo: null,\r\n lastInGroup: true,\r\n masterRowCount: 0\r\n });\r\n });\r\n return rows;\r\n }\r\n\r\n private _expandRowData(oldRows: AssetActivityLogRow[]): AssetActivityLogRow[] {\r\n const sourceRows: AssetActivityLogRow[] = oldRows.filter((row: AssetActivityLogRow) => row.assetLogModel);\r\n const expandedRows: AssetActivityLogRow[] = [];\r\n let rowCount: number = 0;\r\n\r\n sourceRows.forEach((sourceRow: AssetActivityLogRow) => {\r\n sourceRow.masterRowCount = rowCount;\r\n expandedRows.push(sourceRow);\r\n\r\n if (sourceRow.assetLogModel.changes && sourceRow.assetLogModel.changes.length > 0) {\r\n const firstChange = sourceRow.assetLogModel.changes[0];\r\n sourceRow.fieldChanged = firstChange.fieldName;\r\n sourceRow.changedFrom = firstChange.priorValue;\r\n sourceRow.changedTo = firstChange.currentValue;\r\n sourceRow.lastInGroup = false;\r\n sourceRow.assetLogModel.changes.forEach(\r\n (changeModel: Compliance.SourceAssetVerificationFieldChangeModel, index: number) => {\r\n if (index > 0) {\r\n expandedRows.push({\r\n assetLogModel: null,\r\n effectiveDate: null,\r\n actionDate: null,\r\n action: null,\r\n createdByName: null,\r\n fieldChanged: changeModel.fieldName,\r\n changedFrom: changeModel.priorValue,\r\n changedTo: changeModel.currentValue,\r\n lastInGroup: (index + 1 === sourceRow.assetLogModel.changes.length),\r\n masterRowCount: rowCount\r\n });\r\n }\r\n });\r\n\r\n } else {\r\n sourceRow.lastInGroup = true;\r\n }\r\n\r\n rowCount++;\r\n\r\n });\r\n\r\n return expandedRows;\r\n }\r\n\r\n private _formattingType(value: any): string {\r\n if (Object.prototype.toString.call(value) === '[object Date]') {\r\n return 'date';\r\n } else if (typeof value === 'number') {\r\n return 'number';\r\n } else {\r\n return 'string';\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n \r\n
\r\n 0)\" class=\"cost-adjustment-table\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
{{ ca.typeName }}\r\n
\r\n
\r\n
\r\n
$
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
%
\r\n \r\n
\r\n
\r\n
\r\n
{{ costAdjustmentEmpty(ca) ? '' : '(' + costAdjustmentCalculations[ca.costAdjustmentTypeId] + ')'}}
\r\n Adj. Source Cost\r\n {{ calculatedCost }}
\r\n
\r\n","
\r\n \r\n \r\n \r\n
\r\n","import { Component, ElementRef, Input, Output, EventEmitter} from '@angular/core';\r\nimport { AssetSummary } from '../../../Models/assetSummary';\r\nimport { ExtendedCostAdjustmentTypeModel } from '../assetInfo.component';\r\nimport { AssetInfoService } from '../assetInfo.service';\r\nimport * as _ from 'lodash';\r\n\r\n@Component({\r\n selector: 'cost-adjustments',\r\n templateUrl: './costAdjustments.component.html',\r\n})\r\nexport class CostAdjustmentsComponent {\r\n constructor(\r\n private readonly _elementRef: ElementRef,\r\n private readonly _assetInfoService: AssetInfoService) {\r\n }\r\n\r\n @Input() assetSummary: AssetSummary;\r\n @Input() assets: AssetSummary[];\r\n @Input() costCompanyAssetDescriptorMappingModel: Compliance.CompanyAssetDescriptorMappingModel;\r\n @Input() extendedCostAdjustmentTypes: ExtendedCostAdjustmentTypeModel[];\r\n\r\n @Input()\r\n set costAdjustments(value: { [s: string]: Compliance.AssetCostAdjustmentModel; }) {\r\n this._costAdjustments = value;\r\n }\r\n get costAdjustments(): { [s: string]: Compliance.AssetCostAdjustmentModel } {\r\n return this._costAdjustments;\r\n }\r\n\r\n @Input()\r\n set costAdjustmentControlsVisible(value: boolean) {\r\n this._costAdjustmentControlsVisible = value;\r\n }\r\n get costAdjustmentControlsVisible(): boolean {\r\n return this._costAdjustmentControlsVisible;\r\n }\r\n\r\n @Output() costAdjustmentControlsVisibleChange = new EventEmitter();\r\n @Output() costAdjustmentsChange = new EventEmitter<{ [s: string]: Compliance.AssetCostAdjustmentModel; }>();\r\n\r\n costFieldName: string;\r\n\r\n private _costAdjustments: { [s: string]: Compliance.AssetCostAdjustmentModel; } = {};\r\n private _costAdjustmentControlsVisible: boolean;\r\n\r\n get costAdjustmentCalculations(): { [s: string]: string; } {\r\n return this._assetInfoService.costAdjustmentCalculations;\r\n }\r\n\r\n get calculatedCost(): string {\r\n return this._assetInfoService.calculatedCost;\r\n }\r\n\r\n showCostAdjustments(): void {\r\n this._costAdjustmentControlsVisible = true;\r\n this.costAdjustmentControlsVisibleChange.emit(this._costAdjustmentControlsVisible);\r\n }\r\n\r\n isCostInputDisabled(typeId, isPercent): boolean {\r\n const otherElemSelector = isPercent ? '.costAdjustmentAmount' : '.costAdjustmentPercent';\r\n const otherElem = this._elementRef.nativeElement.querySelector(otherElemSelector + typeId);\r\n\r\n if (otherElem && otherElem.value !== null && otherElem.value !== '' && otherElem.value !== 0 && otherElem !== '0') {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n calculateCosts(): void {\r\n this._assetInfoService.calculateCostsAndCheckTotals(this._getCostFieldSourceValue(), this.costAdjustments, this.assets);\r\n this.costAdjustmentsChange.next(this.costAdjustments);\r\n }\r\n\r\n costAdjustmentEmpty(adjustmentType: ExtendedCostAdjustmentTypeModel): boolean {\r\n const adjustment = this.costAdjustments[adjustmentType.costAdjustmentTypeId];\r\n if (adjustment && ((adjustment.adjustmentAmount !== null && adjustment.adjustmentAmount !== 0) || (adjustment.adjustmentPercentage !== null && adjustment.adjustmentPercentage !== 0))) {\r\n return false;\r\n } else {\r\n return true;\r\n }\r\n }\r\n\r\n private _getCostFieldSourceValue(): number {\r\n if (this.assetSummary) {\r\n const altCostMappingModel = this.costCompanyAssetDescriptorMappingModel;\r\n if (!altCostMappingModel) {\r\n return this.assetSummary.sourceCost;\r\n } else {\r\n return this.assetSummary[`source${altCostMappingModel.columnName}`];\r\n }\r\n } else {\r\n return null;\r\n }\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { WeissmanSharedModule } from '../../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { GLAccountSelectorComponent } from './glAccountSelector.component';\r\n\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n TypeaheadModule\r\n ],\r\n declarations: [GLAccountSelectorComponent],\r\n exports: [GLAccountSelectorComponent]\r\n})\r\nexport class GLAccountSelectorModule {\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { WeissmanSharedModule } from '../../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { SiteSelectorComponent } from './siteSelector.component';\r\n\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n TypeaheadModule\r\n ],\r\n declarations: [SiteSelectorComponent],\r\n exports: [SiteSelectorComponent]\r\n})\r\nexport class SiteSelectorModule {\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { AssetLienDateComponent } from './assetLienDate.component';\r\nimport { WeissmanSharedModule } from '../../../Common/weissman-shared.module';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule\r\n ],\r\n declarations: [\r\n AssetLienDateComponent\r\n ],\r\n exports: [\r\n AssetLienDateComponent\r\n ]\r\n})\r\nexport class AssetLienDateModule {}\r\n","\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n","import { lastValueFrom, Observable, of as observableOf, Subscription } from 'rxjs';\r\nimport { mergeMap } from 'rxjs/operators';\r\nimport { Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { ExtendedGLAccountModel } from '../../Asset/Asset-Details/Asset-Info/extendedGLAccountModel';\r\nimport { GLAccountRepository } from '../../Repositories';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe';\r\nimport GLAccountPropertyEnum = Compliance.GLAccountPropertyEnum;\r\nimport FilterTypeEnum = Core.FilterTypeEnum;\r\n\r\n@Component({\r\n selector: 'gl-account-selector',\r\n templateUrl: './glAccountSelector.component.html',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: GLAccountSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class GLAccountSelectorComponent implements OnInit, OnDestroy, ControlValueAccessor {\r\n constructor(\r\n private readonly _glAccountRepository: GLAccountRepository,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe\r\n ) { }\r\n\r\n private _glAccountSubscription: Subscription;\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n @Input() glAccountId: number;\r\n @Input() glAccountName: string;\r\n @Input() isDisabled: boolean = false;\r\n @Input() isRequiredField: boolean = true;\r\n @Input() isOverridden: boolean = false;\r\n @Input() glAccounts: Compliance.GLAccountModel[] = null;\r\n @Input() set companyId(companyId: number) {\r\n this._companyId = companyId;\r\n if (this.isInitialized) {\r\n this._getGlAccounts();\r\n }\r\n };\r\n\r\n @Output() glAccountIdChange = new EventEmitter();\r\n @Output() glAccountChange = new EventEmitter();\r\n\r\n glAccountFilter: string = '';\r\n isLoading: boolean;\r\n\r\n // this component will be considered initialized when the gl accounts have been loaded\r\n // in the meanwhile, any select gl account attempts will be skipped\r\n isInitialized: boolean = false;\r\n\r\n glAccounts$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.glAccountFilter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filterGlAccounts(token)));\r\n\r\n private _glAccounts: ExtendedGLAccountModel[] = [];\r\n private _glAccountNoResult: boolean = false;\r\n private _companyId: number;\r\n\r\n ngOnInit(): void {\r\n if (this.glAccounts){\r\n this._populateGlAccounts(this.glAccounts);\r\n } else {\r\n this._getGlAccounts();\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._glAccountSubscription && this._glAccountSubscription.unsubscribe();\r\n }\r\n\r\n writeValue(glAccount: Compliance.GLAccountModel): void {\r\n this._selectGlAccount(glAccount && glAccount.glAccountId);\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState?(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n onGlAccountBlur(): void {\r\n if (!this.isRequiredField && (!this.glAccountFilter || this.glAccountFilter.trim() === '')) {\r\n this.glAccountId = null;\r\n this.glAccountName = null;\r\n this.glAccountChange.emit(null);\r\n }\r\n\r\n this._selectGlAccount(this.glAccountId);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onGlAccountNoResults(event: boolean): void {\r\n this._glAccountNoResult = event;\r\n }\r\n\r\n onGlAccountSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const glAccount = match.item as ExtendedGLAccountModel;\r\n this._selectGlAccount(glAccount.model.glAccountId);\r\n this.glAccountIdChange.emit(glAccount.model.glAccountId);\r\n this.glAccountChange.emit(glAccount);\r\n\r\n this.glAccountFilter = match.value;\r\n }\r\n }\r\n\r\n private _filterGlAccounts(filter: string): Observable {\r\n return observableOf(\r\n (this._glAccounts || []).filter(x => x.displayName.toLowerCase().includes(filter && filter.toLowerCase()))\r\n );\r\n }\r\n\r\n private _selectGlAccount(glAccountId: number, glAccountName?: string): void {\r\n // keep track of the value that the classification is being set to\r\n this.glAccountId = glAccountId;\r\n // if not initialized then return\r\n // when initialized the asset class ID that is being tracked (above) will be selected\r\n if (!this.isInitialized) {\r\n return;\r\n }\r\n\r\n const glAccount = this._glAccounts.find(gl => gl.model.glAccountId === glAccountId || gl.displayName === glAccountName);\r\n if (glAccount) {\r\n this.glAccountId = glAccount.model.glAccountId;\r\n this.glAccountFilter = glAccount.displayName;\r\n } else {\r\n this.glAccountId = null;\r\n this.glAccountFilter = null;\r\n }\r\n\r\n this._onChangeFn && this._onChangeFn(this.glAccountId);\r\n }\r\n\r\n private async _getGlAccounts(): Promise {\r\n this.isLoading = true;\r\n // get the list of gl accounts\r\n const searchModel: Core.SearchModel = {\r\n columnFilters: [\r\n {\r\n filterProperty: GLAccountPropertyEnum.AccountType,\r\n filterValues: [\r\n {\r\n filterType: FilterTypeEnum.Equals,\r\n filterValue: 'Asset'\r\n }]\r\n }]\r\n };\r\n const response = await lastValueFrom(this._glAccountRepository\r\n .getList(this._companyId, searchModel));\r\n this._populateGlAccounts(response.data);\r\n }\r\n\r\n private _populateGlAccounts(glAccounts: Compliance.GLAccountModel[]){\r\n if (glAccounts) {\r\n this._glAccounts = glAccounts.map(x => new ExtendedGLAccountModel(x, this._keyValueDisplayPipe));\r\n }\r\n\r\n this.isInitialized = true;\r\n this._selectGlAccount(this.glAccountId, this.glAccountName);\r\n this.isLoading = false;\r\n }\r\n}\r\n","import { Observable, from, lastValueFrom } from 'rxjs';\r\nimport { mergeMap, map } from 'rxjs/operators';\r\nimport { Component, Input, Output, EventEmitter} from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { ExtendedSiteModel } from '../../Asset/Asset-Details/Asset-Info/extendedSiteModel';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe';\r\nimport { SiteRepository } from '../../../Core-Repositories';\r\n\r\n@Component({\r\n selector: 'site-selector',\r\n templateUrl: './siteSelector.component.html',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: SiteSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class SiteSelectorComponent implements ControlValueAccessor {\r\n constructor(\r\n private readonly _siteRepository: SiteRepository,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe\r\n ) { }\r\n\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n @Input() siteId: number;\r\n @Input() companyId: number;\r\n @Input() isDisabled: boolean = false;\r\n @Input() isRequiredField: boolean = true;\r\n @Input() isOverridden: boolean = false;\r\n @Input()\r\n set siteName(siteName: string) {\r\n this._siteName = siteName;\r\n this.siteFilter = siteName;\r\n };\r\n\r\n @Output() siteIdChange = new EventEmitter();\r\n @Output() siteChange = new EventEmitter();\r\n\r\n siteFilter: string = '';\r\n siteIsLoading: boolean = false;\r\n siteFieldEdited: boolean = false;\r\n\r\n // this component will be considered initialized when the gl accounts have been loaded\r\n // in the meanwhile, any select gl account attempts will be skipped\r\n isInitialized: boolean = false;\r\n\r\n sites$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.siteFilter); }) as Observable)\r\n .pipe(mergeMap((token: string) => this._filterSites(token)));\r\n\r\n private _siteName: string;\r\n private _siteNoResult: boolean = false;\r\n\r\n writeValue(siteId: number): void {\r\n this.siteId = siteId;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState?(isDisabled: boolean): void {\r\n this.isDisabled = isDisabled;\r\n }\r\n\r\n onBlur(): void {\r\n if (!this.isRequiredField && this.siteFilter.trim() === '') {\r\n this.siteId = null;\r\n this._siteName = null;\r\n this.siteChange.emit(null);\r\n }\r\n\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onNoResults(event: boolean): void {\r\n this._siteNoResult = event;\r\n }\r\n\r\n onSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const site = match.item as ExtendedSiteModel;\r\n this._selectsite(site);\r\n this.siteIdChange.emit(site.model.siteID);\r\n this.siteChange.emit(site);\r\n\r\n this.siteFilter = match.value;\r\n }\r\n }\r\n\r\n onLoadingChange(isLoading: boolean): void {\r\n this.siteIsLoading = isLoading;\r\n }\r\n\r\n private _filterSites(filter: string): Observable {\r\n const searchModel: Core.SiteSearchModel = {\r\n excludeFromInactiveCompany: true,\r\n pagination: {\r\n skip: 0,\r\n take: 100\r\n },\r\n columnFilters: [\r\n {\r\n filterProperty: Core.SitePropertyEnum.SiteNameOrNumber,\r\n filterValues: [\r\n {\r\n filterType: Core.FilterTypeEnum.Contains,\r\n filterValue: filter\r\n }\r\n ]\r\n }\r\n ],\r\n };\r\n\r\n return from(lastValueFrom(this._siteRepository.searchSites(this.companyId, searchModel))).pipe(\r\n map((sites) => sites.map(site => new ExtendedSiteModel(site, this._keyValueDisplayPipe))));\r\n }\r\n\r\n private _selectsite(site: ExtendedSiteModel): void {\r\n if (site) {\r\n this.siteId = site.model.siteID;\r\n this.siteFilter = site.displayName;\r\n } else {\r\n this.siteId = null;\r\n this.siteFilter = null;\r\n }\r\n\r\n this._onChangeFn && this._onChangeFn(this.siteId);\r\n }\r\n}\r\n","\r\n
\r\n \r\n
\r\n","import { NgModule } from '@angular/core';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridExtensionsModule } from '../../AgGrid/agGridExtensions.module';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { WeissmanSharedModule } from '../../../Common/weissman-shared.module';\r\nimport { BusyIndicatorModule } from '../../../Busy-Indicator';\r\nimport { ComplianceParcelModule } from '../../Parcel/parcel.module';\r\nimport { AgGridLoadingOverlayComponent } from '../../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { AssetClassSelectorModule } from '../Asset-Class-Selector/assetClassSelector.module';\r\nimport { AssetDetailsComponent } from './assetDetails.component';\r\nimport { AssetInfoComponent } from './Asset-Info/assetInfo.component';\r\nimport { AssetReturnFilingsComponent } from './Return-Filings/assetReturnFilings.component';\r\nimport { AssetReturnFilingStatusCellRendererComponent } from './Return-Filings/agGridStatusCellRenderer.component';\r\nimport { AssetActivityLogComponent } from './Activity-Log/assetActivityLog.component';\r\nimport { AssetInfoCostEditorComponent } from './Asset-Info/Cost-Editor/assetInfoCostEditor.component';\r\nimport { CostAdjustmentsComponent } from './Asset-Info/Cost-Adjustments/costAdjustments.component';\r\nimport { GLAccountSelectorModule } from '../../GL-Account/GL-Account-Selector/glAccountSelector.module';\r\nimport { SiteSelectorModule } from '../../Site/Site-Selector/siteSelector.module';\r\nimport { AssetLienDateModule } from '../Asset-Lien-Date/assetLienDate.module';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n BusyIndicatorModule.forRoot(),\r\n ComplianceParcelModule,\r\n TypeaheadModule,\r\n CurrencyMaskModule,\r\n AgGridExtensionsModule,\r\n GLAccountSelectorModule,\r\n SiteSelectorModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent\r\n ]),\r\n AssetLienDateModule,\r\n AssetClassSelectorModule\r\n ],\r\n declarations: [\r\n AssetActivityLogComponent,\r\n AssetDetailsComponent,\r\n AssetInfoComponent,\r\n AssetInfoCostEditorComponent,\r\n AssetReturnFilingsComponent,\r\n AssetReturnFilingStatusCellRendererComponent,\r\n CostAdjustmentsComponent\r\n ],\r\n providers: [],\r\n exports: [\r\n AssetDetailsComponent\r\n ]\r\n})\r\nexport class AssetDetailsModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer } from '../AgGrid/MultiSelectTracker';\r\nimport { AssetClassSelectorComponent } from './Asset-Class-Selector/assetClassSelector.component';\r\nimport { AssetClassSelectorModule } from './Asset-Class-Selector/assetClassSelector.module';\r\nimport { AssetListComponent } from './Asset-List/assetList.component';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { AssetListGridActionCellRendererComponent } from './Asset-List/agGridActionCellRenderer.component';\r\nimport { CostAdjustmentHelpComponent } from './Asset-Details/costAdjustmentHelp.component';\r\nimport { AssetInfoService } from './Asset-Details/Asset-Info/assetInfo.service';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { AssetClassPickerComponent } from './Asset-Class-Selector/assetClassPicker.component';\r\nimport { AssetReturnFilingStatusCellRendererComponent } from './Asset-Details/Return-Filings/agGridStatusCellRenderer.component';\r\nimport { AssetBulkUpdateActionComponent } from './Asset-List/Asset-Bulk-Update/assetBulkUpdateAction.component';\r\nimport { AssetDescriptorViewComponent } from './Asset-Descriptors/assetDescriptorView.component';\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { AssetDescriptorEditComponent } from './Asset-Descriptors/assetDescriptorEdit.component';\r\nimport { ComplianceParcelModule } from '../Parcel/parcel.module';\r\nimport { AssetLienDateDetailsComponent } from './Asset-Lien-Date-Details/assetLienDateDetails.component';\r\nimport { AssetLimitComponent } from './Asset-List/Asset-Limit/assetLimit.component';\r\nimport { AssetLimitDetailsComponent } from './Asset-List/Asset-Limit-Details/assetLimitDetails.component';\r\nimport { AssetAdvancedComponent } from './Asset-List/Asset-Advanced/assetAdvanced.component';\r\nimport { AssetAdvancedDetailsComponent } from './Asset-List/Asset-Advanced-Details/assetAdvancedDetails.component';\r\nimport { AssetAdvancedDetailCheckboxComponent } from './Asset-List/Asset-Advanced-Details/assetAdvancedDetailCheckbox.component';\r\nimport { AssetChangeIconCellRendererComponent } from './Asset-List/agGridChangeIconCellRenderer.component';\r\nimport { AssetChangeIconComponent } from './Asset-List/Asset-Change-Icon/assetChangeIcon.component';\r\nimport { AssetDetailsModule } from './Asset-Details/assetDetails.module';\r\nimport { AssetBulkUpdateComponent } from './Asset-List/Asset-Bulk-Update/assetBulkUpdate.component';\r\nimport { AssetLienDateModule } from './Asset-Lien-Date/assetLienDate.module';\r\nimport { CommentsModule } from '../../Comments/comments.module';\r\nimport { AssetImportProgressComponent } from './Asset-List/Asset-Import-Progress/assetImportProgress.component';\r\nimport { AssetImportProgressService } from './Asset-List/Asset-Import-Progress/assetImportProgress.service';\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n ReactiveFormsModule,\r\n CommonModule,\r\n TypeaheadModule,\r\n TooltipModule,\r\n BsDropdownModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n CurrencyMaskModule,\r\n CommentsModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectedCellRenderer,\r\n // asset list\r\n AssetListGridActionCellRendererComponent,\r\n // asset return filings list\r\n AssetReturnFilingStatusCellRendererComponent\r\n ]),\r\n ComplianceParcelModule,\r\n AssetDetailsModule,\r\n AssetLienDateModule,\r\n AssetClassSelectorModule\r\n ],\r\n declarations: [\r\n AssetAdvancedComponent,\r\n AssetAdvancedDetailsComponent,\r\n AssetAdvancedDetailCheckboxComponent,\r\n AssetListGridActionCellRendererComponent,\r\n AssetListComponent,\r\n CostAdjustmentHelpComponent,\r\n AssetBulkUpdateComponent,\r\n AssetClassPickerComponent,\r\n AssetBulkUpdateActionComponent,\r\n AssetDescriptorViewComponent,\r\n AssetDescriptorEditComponent,\r\n AssetLienDateDetailsComponent,\r\n AssetLimitComponent,\r\n AssetLimitDetailsComponent,\r\n AssetChangeIconComponent,\r\n AssetChangeIconCellRendererComponent,\r\n AssetImportProgressComponent\r\n ],\r\n providers: [\r\n AssetInfoService,\r\n AssetImportProgressService\r\n ],\r\n exports: [\r\n AssetLienDateDetailsComponent,\r\n AssetBulkUpdateActionComponent,\r\n AssetListComponent\r\n ]\r\n})\r\nexport class AssetModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('assetList', AssetListComponent);\r\n }\r\n}\r\n","\r\nimport {of as observableOf, Observable } from 'rxjs';\r\nimport {\r\n Component,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n SimpleChange,\r\n SimpleChanges\r\n} from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport * as _ from 'lodash';\r\nimport { mergeMap } from 'rxjs/operators';\r\n\r\n@Component({\r\n templateUrl: './attachmentTypeSelector.component.html',\r\n selector: 'attachment-type-selector',\r\n providers: [{\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: AttachmentTypeSelectorComponent,\r\n multi: true\r\n }]\r\n})\r\nexport class AttachmentTypeSelectorComponent implements ControlValueAccessor {\r\n\r\n // reactive forms functions\r\n private _onChangeFn: Function;\r\n private _onTouchedFn: Function;\r\n\r\n @Input() values: Compliance.AttachmentTypeViewModel[] = [];\r\n @Input() isOverridden: boolean = false;\r\n\r\n @Output() changed = new EventEmitter();\r\n\r\n value: string;\r\n disabled: boolean;\r\n filter: string = '';\r\n\r\n values$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.filter); }) as Observable)\r\n .pipe(mergeMap((token) => this._filter(token)));\r\n\r\n registerOnChange(fn: any): void {\r\n this._onChangeFn = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this._onTouchedFn = fn;\r\n }\r\n\r\n setDisabledState(isDisabled: boolean): void {\r\n this.disabled = isDisabled;\r\n }\r\n\r\n writeValue(attachmentType: string): void {\r\n this._select(attachmentType);\r\n }\r\n\r\n onBlur(): void {\r\n this._select(this.value);\r\n this._onTouchedFn && this._onTouchedFn();\r\n }\r\n\r\n onSelected(match: TypeaheadMatch): void {\r\n if (match && match.item) {\r\n const attachmentType = match.item as Compliance.AttachmentTypeViewModel;\r\n this._select(attachmentType.attachmentType);\r\n this.changed.emit(attachmentType.attachmentType);\r\n }\r\n }\r\n\r\n private _filter(filter: string): Observable {\r\n if (filter === null || filter === undefined) {\r\n filter = '';\r\n }\r\n\r\n return observableOf(\r\n (this.values || []).filter(x => x.attachmentType.toLowerCase().includes(filter.toLowerCase()))\r\n );\r\n }\r\n\r\n private _select(value: string): void {\r\n this.value = value;\r\n\r\n const attachmentType = _.find(this.values, (x) => x.attachmentType === value);\r\n\r\n if (attachmentType) {\r\n this.filter = value;\r\n } else {\r\n this.filter = null;\r\n }\r\n }\r\n}\r\n","
\r\n \r\n
\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { ModalModule } from 'ngx-bootstrap/modal';\r\nimport { ButtonsModule } from 'ngx-bootstrap/buttons';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { SortableModule } from 'ngx-bootstrap/sortable';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { DragulaModule } from 'ng2-dragula';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator'\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { ValuationModule } from '../../Valuation/valuation.module';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer} from '../AgGrid/MultiSelectTracker';\r\nimport { AssetClassSelectorModule } from '../Asset/Asset-Class-Selector/assetClassSelector.module';\r\nimport { EntityImportProcessComponent } from './Import-Process/importProcess.component';\r\nimport { EntityImportProcessService } from './Import-Process/importProcess.service';\r\nimport { AgGridMappingHeaderRowCellRendererComponent } from './Import-Process/Column-Mapping-Step/agGridHeaderRowCellRenderer.component';\r\nimport { EntityImportColumnMappingStepComponent } from './Import-Process/Column-Mapping-Step/columnMappingStep.component';\r\nimport { EntityImportColumnMappingStepService } from './Import-Process/Column-Mapping-Step/columnMappingStep.service';\r\nimport { EntityImportEditingStepComponent } from './Import-Process/Editing-Step/editingStep.component';\r\nimport { EntityImportEditorComponent } from './Import-Process/Editing-Step/Editor/editor.component';\r\nimport { EntityImportValidationSummaryComponent } from './Import-Process/Editing-Step/Validation-Summary/validationSummary.component';\r\nimport { EntityImportEditorEstimatedActionHeaderRendererComponent } from './Import-Process/Editing-Step/Editor/agGridEstimatedActionHeaderRenderer.component';\r\nimport { EntityImportEditorEstimatedActionFilterRendererComponent } from './Import-Process/Editing-Step/Editor/agGridEstimatedActionFilterRenderer.component';\r\nimport { EntityImportEditorEstimatedActionCellRendererComponent } from './Import-Process/Editing-Step/Editor/agGridEstimatedActionCellRenderer.component';\r\nimport { AgGridOverlayComponent } from './Import-Process/Column-Mapping-Step/Drag-And-Drop-Overlay/agGridOverlay.component';\r\nimport { AgGridOverlayService } from './Import-Process/Column-Mapping-Step/Drag-And-Drop-Overlay/agGridOverlay.service';\r\nimport { EntityImportUploadComponent } from './Upload/upload.component';\r\nimport { EntityImportStaticFieldsComponent } from './Static-Fields/staticFields.component';\r\nimport { EntityImportListComponent } from './Import-List/importList.component';\r\nimport { EntityImportListGridActionCellRendererComponent } from './Import-List/agGridActionCellRenderer.component';\r\nimport { EntityImportListGridProgressCellRendererComponent } from './Import-List/agGridProgressCellRenderer.component';\r\nimport { StepProgressIndicatorComponent } from '../../Common/Step-Progress-Indicator/stepProgressIndicator.component';\r\nimport { MessageModalService } from '../../UI-Lib/Message-Box/messageModal.service';\r\nimport { MessageModalComponent } from '../../UI-Lib/Message-Box/message-modal.component';\r\nimport { EntityImportSpecificationMappingComponent } from './Import-Process/Column-Mapping-Step/Import-Specification-Mapping/importSpecificationMapping.component';\r\nimport { AgGridDateFilterComponent } from '../AgGrid';\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { StepProgressIndicatorModule } from '../../Common/Step-Progress-Indicator/stepProgressIndicator.module';\r\nimport { EntityImportEditorAssetClassSelectorCellEditorComponent } from './Import-Process/Editing-Step/Editor/SelectorRenderers/agGridAssetClassSelectorRenderer.component';\r\nimport { AssetModule } from '../Asset/asset.module';\r\nimport { EntityImportProgressComponent } from './Import-Progress/entityImportProgress.component';\r\nimport { ImportBulkUpdateComponent } from './Import-Process/Editing-Step/Editor/Import-Bulk-Update/importBulkUpdate.component';\r\nimport { ImportBulkUpdateActionComponent } from './Import-Process/Editing-Step/Editor/Import-Bulk-Update/importBulkUpdateAction.component';\r\nimport { AssessorSelectorComponent } from './Import-Process/Editing-Step/Editor/Selectors/Assessor-Selector/assessorSelector.component';\r\nimport { EntityImportEditorAssessorSelectorCellEditorComponent } from './Import-Process/Editing-Step/Editor/SelectorRenderers/agGridAssessorSelectorRenderer.component';\r\nimport { ImportSpecificationListComponent } from './Import-Specification-List/importSpecificationList.component';\r\nimport { ImportSpecificationListGridActionCellRendererComponent } from './Import-Specification-List/agGridActionCellRenderer.component';\r\nimport { TransferConfirmComponent } from \"./Import-Process/Transfer-Confirm/transferConfirm.component\";\r\nimport { EntityImportSpecificationEditComponent } from './Import-Specification-List/Import-Specification-Edit/importSpecificationEdit.component';\r\nimport { AttachmentTypeSelectorComponent } from \"./Import-Process/Editing-Step/Editor/Selectors/Attachment-Type-Selector/attachmentTypeSelector.component\";\r\nimport { EntityImportEditorAttachmentTypeSelectorCellEditorComponent } from \"./Import-Process/Editing-Step/Editor/SelectorRenderers/agGridAttachmentTypeSelectorRenderer.component\";\r\nimport { EntityImportEditorLeaseTypeSelectorCellEditorComponent } from \"./Import-Process/Editing-Step/Editor/SelectorRenderers/agGridLeaseTypeSelectorRenderer.component\";\r\nimport { LeaseTypeSelectorComponent } from \"./Import-Process/Editing-Step/Editor/Selectors/Lease-Type-Selector/leaseTypeSelector.component\";\r\nimport { ExcelPreviewComponent } from \"./Excel-Preview/excelPreview.component\";\r\nimport { AssessmentClassSelectorComponent } from \"./Import-Process/Editing-Step/Editor/Selectors/AssessmentClass-Selector/assessmentClassSelector.component\";\r\nimport { EntityImportEditorAssessmentClassSelectorCellEditorComponent } from \"./Import-Process/Editing-Step/Editor/SelectorRenderers/agGridAssessmentClassSelectorRenderer.component\";\r\nimport { GLAccountSelectorComponent } from \"./Import-Process/Editing-Step/Editor/Selectors/GLAccount-Selector/glAccountSelector.component\";\r\nimport { EntityImportEditorGLAccountSelectorCellEditorComponent } from \"./Import-Process/Editing-Step/Editor/SelectorRenderers/agGridGLAccountSelectorRenderer.component\";\r\nimport { ImportMappingModalComponent } from './Import-Process/Column-Mapping-Step/Import-Mapping-Modal/importMappingModal.component';\r\nimport { TaxingDistrictSelectorComponent } from \"./Import-Process/Editing-Step/Editor/Selectors/TaxingDistrict-Selector/taxingDistrictSelector.component\";\r\nimport { EntityImportEditorTaxingSelectorCellEditorComponent } from \"./Import-Process/Editing-Step/Editor/SelectorRenderers/agGridTaxingDistrictSelectorRenderer.component\";\r\nimport { TypeaheadSelectorComponent } from './Import-Process/Editing-Step/Editor/Selectors/Typeahead-Selector/typeaheadSelector.component';\r\nimport { EntityImportEditorOneTimeVRecurringSelectorRendererCellEditorComponent } from './Import-Process/Editing-Step/Editor/SelectorRenderers/agGridOneTimeVRecurringSelectorRenderer.component';\r\nimport { OneTimeVRecurringSelectorComponent } from './Import-Process/Editing-Step/Editor/Selectors/OneTimeVRecurring-Selector/oneTimeVRecurringSelector.component';\r\nimport { EntityImportService } from './entityImport.service';\r\nimport { AssetLienDateModule } from '../Asset/Asset-Lien-Date/assetLienDate.module';\r\nimport { EntityImportEditorIncomeStatementCategorySelectorCellEditorComponent } from './Import-Process/Editing-Step/Editor/SelectorRenderers/agGridIncomeStatementCategorySelectorRenderer.component'\r\nimport { EntityImportEditorGLAccountTypeSelectorCellEditorComponent } from './Import-Process/Editing-Step/Editor/SelectorRenderers/agGridGLAccountTypeSelectorRenderer.component';\r\nimport {\r\n DynamicFieldBehaviorHelpComponent\r\n} from './Import-Process/Dynamic-Field-Behavior/Dynamic-Field-Behavior-Help/dynamicFieldBehaviorHelp.component';\r\nimport {\r\n DynamicFieldBehaviorConfigurationComponent\r\n} from './Import-Process/Dynamic-Field-Behavior/Dynamic-Field-Behavior-Configuration/dynamicFieldBehaviorConfiguration.component';\r\nimport { DynamicFieldBehaviorComponent } from './Import-Process/Dynamic-Field-Behavior/dynamicFieldBehavior.component';\r\nimport {\r\n DynamicFieldSelectedBehaviorHelpComponent\r\n} from './Import-Process/Dynamic-Field-Behavior/Dynamic-Field-Selected-Behavior-Help/dynamicFieldSelectedBehaviorHelp.component';\r\nimport { DynamicFieldBehaviorService } from './Import-Process/Dynamic-Field-Behavior/dynamicFieldBehavior.service';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BsDropdownModule,\r\n TabsModule,\r\n ModalModule,\r\n SortableModule,\r\n ButtonsModule,\r\n TooltipModule,\r\n CurrencyMaskModule,\r\n DragulaModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n StepProgressIndicatorModule,\r\n AssetModule,\r\n TypeaheadModule,\r\n AssetClassSelectorModule,\r\n ValuationModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridDateFilterComponent,\r\n // import list\r\n EntityImportListGridActionCellRendererComponent,\r\n EntityImportListGridProgressCellRendererComponent,\r\n // mapping\r\n AgGridMappingHeaderRowCellRendererComponent,\r\n // editing\r\n EntityImportEditorEstimatedActionHeaderRendererComponent,\r\n EntityImportEditorEstimatedActionFilterRendererComponent,\r\n EntityImportEditorEstimatedActionCellRendererComponent,\r\n EntityImportEditorAssessorSelectorCellEditorComponent,\r\n AttachmentTypeSelectorComponent,\r\n EntityImportEditorAttachmentTypeSelectorCellEditorComponent,\r\n LeaseTypeSelectorComponent,\r\n EntityImportEditorLeaseTypeSelectorCellEditorComponent,\r\n AssessmentClassSelectorComponent,\r\n GLAccountSelectorComponent,\r\n EntityImportEditorGLAccountSelectorCellEditorComponent,\r\n EntityImportEditorIncomeStatementCategorySelectorCellEditorComponent,\r\n EntityImportEditorGLAccountTypeSelectorCellEditorComponent,\r\n // specification\r\n ImportSpecificationListGridActionCellRendererComponent,\r\n EntityImportEditorAssessmentClassSelectorCellEditorComponent,\r\n EntityImportEditorTaxingSelectorCellEditorComponent,\r\n EntityImportEditorOneTimeVRecurringSelectorRendererCellEditorComponent,\r\n OneTimeVRecurringSelectorComponent\r\n ]),\r\n AssetLienDateModule\r\n ],\r\n declarations: [\r\n AgGridMappingHeaderRowCellRendererComponent,\r\n AgGridOverlayComponent,\r\n EntityImportStaticFieldsComponent,\r\n EntityImportEditorComponent,\r\n EntityImportProcessComponent,\r\n EntityImportUploadComponent,\r\n EntityImportColumnMappingStepComponent,\r\n EntityImportEditorComponent,\r\n EntityImportListComponent,\r\n EntityImportValidationSummaryComponent,\r\n EntityImportListGridActionCellRendererComponent,\r\n EntityImportListGridProgressCellRendererComponent,\r\n EntityImportEditorEstimatedActionHeaderRendererComponent,\r\n EntityImportEditorEstimatedActionFilterRendererComponent,\r\n EntityImportEditorEstimatedActionCellRendererComponent,\r\n MessageModalComponent,\r\n EntityImportEditingStepComponent,\r\n EntityImportSpecificationMappingComponent,\r\n EntityImportEditorAssetClassSelectorCellEditorComponent,\r\n EntityImportProgressComponent,\r\n ImportBulkUpdateComponent,\r\n ImportBulkUpdateActionComponent,\r\n EntityImportEditorAssessorSelectorCellEditorComponent,\r\n AssessorSelectorComponent,\r\n ImportSpecificationListComponent,\r\n ImportSpecificationListGridActionCellRendererComponent,\r\n EntityImportSpecificationEditComponent,\r\n TransferConfirmComponent,\r\n AttachmentTypeSelectorComponent,\r\n EntityImportEditorAttachmentTypeSelectorCellEditorComponent,\r\n LeaseTypeSelectorComponent,\r\n EntityImportEditorLeaseTypeSelectorCellEditorComponent,\r\n ExcelPreviewComponent,\r\n AssessmentClassSelectorComponent,\r\n EntityImportEditorAssessmentClassSelectorCellEditorComponent,\r\n GLAccountSelectorComponent,\r\n EntityImportEditorGLAccountSelectorCellEditorComponent,\r\n EntityImportEditorGLAccountTypeSelectorCellEditorComponent,\r\n ImportMappingModalComponent,\r\n TaxingDistrictSelectorComponent,\r\n EntityImportEditorTaxingSelectorCellEditorComponent,\r\n TypeaheadSelectorComponent,\r\n EntityImportEditorOneTimeVRecurringSelectorRendererCellEditorComponent,\r\n OneTimeVRecurringSelectorComponent,\r\n EntityImportEditorIncomeStatementCategorySelectorCellEditorComponent,\r\n DynamicFieldBehaviorComponent,\r\n DynamicFieldBehaviorHelpComponent,\r\n DynamicFieldBehaviorConfigurationComponent,\r\n DynamicFieldSelectedBehaviorHelpComponent\r\n ],\r\n providers: [\r\n AgGridOverlayService,\r\n EntityImportProcessService,\r\n EntityImportColumnMappingStepService,\r\n MessageModalService,\r\n EntityImportService,\r\n DynamicFieldBehaviorService\r\n ],\r\n exports: []\r\n})\r\nexport class EntityImportModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('entityImportList', EntityImportListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('entityImportProcess', EntityImportProcessComponent);\r\n hybridAdapterUtility.downgradeNg2Component('importSpecificationList', ImportSpecificationListComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { AgGridModule } from 'ag-grid-angular'\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component'\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { FactorTableListComponent } from './Factor-Table-List/factorTableList.component';\r\nimport { FactorTableDetailsComponent } from './Factor-Table-Details/factorTableDetails.component';\r\nimport { FactorTableListGridActionCellRendererComponent } from './Factor-Table-List/agGridActionCellRenderer.component';\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { FactorTableExportAttachmentsComponent } from \"./Factor-Table-Export-Attachments/factorTableExportAttachments.component\";\r\nimport { CommentsModule } from '../../Comments/comments.module';\r\nimport { WeissmanFactorTableTypeNamePipe } from \"./Factor-Table-Details/factorTableTypeName-pipe\";\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n ReactiveFormsModule,\r\n CommonModule,\r\n TypeaheadModule,\r\n PopoverModule,\r\n CurrencyMaskModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BsDropdownModule,\r\n CommentsModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n FactorTableListGridActionCellRendererComponent\r\n ])\r\n ],\r\n declarations: [\r\n FactorTableListComponent,\r\n FactorTableListGridActionCellRendererComponent,\r\n FactorTableDetailsComponent,\r\n FactorTableExportAttachmentsComponent,\r\n WeissmanFactorTableTypeNamePipe\r\n ],\r\n providers: [],\r\n exports: []\r\n})\r\nexport class FactorTableModule {\r\n static setupModule(): void {\r\n let hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('factorTableList', FactorTableListComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { ModalModule } from 'ngx-bootstrap/modal';\r\nimport { ButtonsModule } from 'ngx-bootstrap/buttons';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { SortableModule } from 'ngx-bootstrap/sortable';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { FactorTableModule } from '../Factor-Table/factorTable.module';\r\nimport {\r\n AssessorAddressTooltipComponent\r\n} from './Form-Assessor-List/Assessor-Address-Tooltip/assessorAddressTooltip.component';\r\nimport { FormPageComponent } from './Form-Page/formPage.component';\r\nimport { FormListComponent } from './Form-List/formList.component';\r\nimport { FormScheduleListComponent } from './Form-Schedule-List/formScheduleList.component';\r\nimport { FormCommentsComponent } from './Form-Comments/formComments.component';\r\nimport { FormAttachmentsComponent } from './Form-Attachments/formAttachments.component';\r\nimport { FormDetailsComponent } from './Form-Details/formDetails.component';\r\nimport { FormYearListComponent } from './Form-Year-List/formYearList.component';\r\nimport { FormAssessorAddComponent } from './Form-Assessor-Add/formAssessorAdd.component';\r\nimport { FormAssessorListComponent } from './Form-Assessor-List/formAssessorList.component';\r\nimport { FormAssessorsPanelGridActionCellRendererComponent } from './Form-Assessor-List/agGridActionCellRenderer.component';\r\nimport { FormService } from './form.service';\r\nimport { FormFactorTableListComponent } from './Form-Factor-Table-List/formFactorTableList.component';\r\nimport { FormFactorTableAddComponent} from './Form-Factor-Table-Add/formFactorTableAdd.component';\r\nimport { FormAssetClassMappingComponent } from './Form-Asset-Class-Mapping/formAssetClassMapping.component';\r\nimport { DropdownCellRenderer} from './Form-Asset-Class-Mapping/agGridDropdownCellRenderer.component';\r\nimport { FormFieldListComponent } from './Form-Field-List/formFieldList.component';\r\nimport { FormFieldsComponent } from './Form-Fields/formFields.component';\r\nimport { FormTemplateComponent } from './Form-Template/formTemplate.component';\r\nimport { FormTemplateUploadComponent } from './Form-Template-Upload/formTemplateUpload.component';\r\nimport { FormTemplateEditComponent } from './Form-Template-Edit/formTemplateEdit.component';\r\nimport { FormScheduleListGridCheckboxCellRendererComponent } from './Form-Schedule-List/agGridCheckboxCellRender.component';\r\nimport { FormScheduleListGridActionCellRendererComponent } from './Form-Schedule-List/agGridActionCellRenderer.component';\r\nimport { FormScheduleListGridFactorTableDropdownCellRendererComponent } from './Form-Schedule-List/agGridFactorTableDropdownCellRenderer.component';\r\nimport { FormScheduleListGridInputCellRendererComponent } from './Form-Schedule-List/agGridInputCellRender.component';\r\nimport { FormScheduleListGridReportDropdownCellRendererComponent } from './Form-Schedule-List/agGridReportDropdownCellRenderer.component';\r\nimport { FormFactorTableListGridActionCellRendererComponent } from './Form-Factor-Table-List/agGridActionCellRenderer.component';\r\nimport { FormReportListGridActionCellRendererComponent } from './Form-Report-List/agGridActionCellRenderer.component';\r\nimport { FormReportListComponent } from './Form-Report-List/formReportList.component';\r\nimport { FormReportListCheckboxCellRendererComponent } from './Form-Report-List/agGridCheckboxCellRender.component';\r\nimport { FormReportAddComponent } from './Form-Report-Add/formReportAdd.component';\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { FormAppealLevelListComponent } from './Form-Appeal-Level-List/formAppealLevelList.component';\r\nimport { FormYearNewComponent } from './Form-Year-New/formYearNew.component';\r\nimport { FormYearCopyComponent } from './Form-Year-Copy/formYearCopy.component';\r\nimport { FormYearCopyListComponent } from './Form-Year-Copy-List/formYearCopyList.component';\r\nimport { FormYearDeleteComponent } from './Form-Year-Delete/formYearDelete.component';\r\nimport { FormAssessorListAddressCellRendererComponent } from './Form-Assessor-List/agGridAddressCellRenderer.component';\r\nimport { ReportingModule } from '../../Reporting/reporting.module';\r\nimport { FormSetupUploadComponent } from './Form-Setup-Upload/formSetupUpload.component';\r\nimport { FormAssessorSelectComponent } from './Form-Assessor-Select/formAssessorSelect.component';\r\nimport { FormYearNewModalComponent } from './Form-Year-New-Modal/formYearNewModal.component';\r\nimport { FormAssessorAddressPickerComponent } from './Form-Assessor-Address-Picker/formAssessorAddressPicker.component';\r\nimport { FormAssetClassMappingListGridActionCellRendererComponent } from './Form-Asset-Class-Mapping/agGridActionCellRenderer.component';\r\nimport { FormSwitchesComponent } from './Form-Switches/formSwitches.component';\r\nimport { FormSetupDownloadComponent } from './Form-Setup-Download/formSetupDownload.component';\r\nimport { FormTemplateValidationComponent } from './Form-Template-Validation/formTemplateValidation.component';\r\nimport { FormFilingBatchesComponent } from './Form-FilingBatches/formFilingBatches.component';\r\nimport { FormFilingBatchListComponent } from './Form-Filing-Batch-List/formFilingBatchList.component';\r\nimport { ExportFormListComponent } from './Export-Form-List/exportFormList.component';\r\nimport {FormLibraryExportComponent} from './Form-Library-Export/formLibraryExport.component';\r\nimport {\r\n AssessorCertifiedTooltipComponent\r\n} from './Form-Assessor-List/Assessor-Certified-Tooltip/assessorCertifiedTooltip.component';\r\nimport {\r\n ExpandCellHeaderRendererComponent\r\n} from '../../Common/AgGrid/agGridExpandCellHeaderRenderer.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BsDropdownModule,\r\n TabsModule,\r\n ModalModule,\r\n TypeaheadModule,\r\n SortableModule,\r\n ButtonsModule,\r\n PopoverModule,\r\n TooltipModule,\r\n CurrencyMaskModule,\r\n ReportingModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n FormAssessorsPanelGridActionCellRendererComponent,\r\n ExpandCellHeaderRendererComponent,\r\n FormAssetClassMappingListGridActionCellRendererComponent,\r\n FormScheduleListGridCheckboxCellRendererComponent,\r\n FormScheduleListGridActionCellRendererComponent,\r\n FormScheduleListGridFactorTableDropdownCellRendererComponent,\r\n FormScheduleListGridInputCellRendererComponent,\r\n FormScheduleListGridReportDropdownCellRendererComponent,\r\n FormFactorTableListGridActionCellRendererComponent,\r\n FormReportListGridActionCellRendererComponent,\r\n FormReportListCheckboxCellRendererComponent,\r\n FormAssessorListAddressCellRendererComponent\r\n ]),\r\n FactorTableModule\r\n ],\r\n declarations: [\r\n FormPageComponent,\r\n FormScheduleListComponent,\r\n FormPageComponent,\r\n FormListComponent,\r\n FormDetailsComponent,\r\n FormYearListComponent,\r\n FormYearNewComponent,\r\n FormYearNewModalComponent,\r\n FormYearCopyComponent,\r\n FormYearCopyListComponent,\r\n FormYearDeleteComponent,\r\n FormAssessorAddComponent,\r\n FormAssessorListComponent,\r\n FormAssessorsPanelGridActionCellRendererComponent,\r\n FormCommentsComponent,\r\n FormAttachmentsComponent,\r\n FormDetailsComponent,\r\n FormFactorTableListComponent,\r\n FormFactorTableAddComponent,\r\n FormAssetClassMappingComponent,\r\n FormAssetClassMappingListGridActionCellRendererComponent,\r\n DropdownCellRenderer,\r\n FormFieldListComponent,\r\n FormFieldsComponent,\r\n FormTemplateComponent,\r\n FormTemplateUploadComponent,\r\n FormTemplateEditComponent,\r\n FormTemplateValidationComponent,\r\n FormScheduleListGridCheckboxCellRendererComponent,\r\n FormScheduleListGridActionCellRendererComponent,\r\n FormScheduleListGridFactorTableDropdownCellRendererComponent,\r\n FormScheduleListGridInputCellRendererComponent,\r\n FormScheduleListGridReportDropdownCellRendererComponent,\r\n FormFactorTableListGridActionCellRendererComponent,\r\n FormReportListComponent,\r\n FormReportListGridActionCellRendererComponent,\r\n FormReportListCheckboxCellRendererComponent,\r\n FormReportAddComponent,\r\n FormSwitchesComponent,\r\n FormAppealLevelListComponent,\r\n FormAssessorListAddressCellRendererComponent,\r\n FormSetupUploadComponent,\r\n FormAssessorSelectComponent,\r\n FormAssessorAddressPickerComponent,\r\n FormSetupDownloadComponent,\r\n FormFilingBatchesComponent,\r\n FormFilingBatchListComponent,\r\n ExportFormListComponent,\r\n FormLibraryExportComponent,\r\n AssessorCertifiedTooltipComponent,\r\n AssessorAddressTooltipComponent\r\n ],\r\n providers: [\r\n FormService\r\n ],\r\n exports: []\r\n})\r\nexport class FormModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('formPage', FormPageComponent);\r\n hybridAdapterUtility.downgradeNg2Component('formList', FormListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('formAttachments', FormAttachmentsComponent);\r\n hybridAdapterUtility.downgradeNg2Component('formComments', FormCommentsComponent);\r\n }\r\n}\r\n","import { forwardRef, NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { AgGridModule } from 'ag-grid-angular'\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component'\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { ValuationModule } from '../../Valuation/valuation.module';\r\nimport { AssetClassSelectorModule } from '../Asset/Asset-Class-Selector/assetClassSelector.module';\r\nimport { GLAccountListComponent } from './GL-Account-List/glAccountList.component';\r\nimport { GLAccountDetailsComponent } from './GL-Account-Details/glAccountDetails.component';\r\nimport { AssetModule } from '../Asset/asset.module'\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { GLAccountBulkUpdateComponent } from './GL-Account-List/GL-Account-Bulk-Update/glAccountBulkUpdate.component';\r\nimport { GLAccountBulkUpdateActionComponent } from './GL-Account-List/GL-Account-Bulk-Update/glAccountBulkUpdateAction.component';\r\nimport { GLAccountService } from './glAccount.service';\r\nimport { GLAccountBulkUpdateIncomeStatementTypesComponent } from \"./GL-Account-List/GL-Account-Bulk-Update/glAccountBulkUpdateIncomeStatementTypes.component\";\r\n\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n AssetModule,\r\n AssetClassSelectorModule,\r\n ValuationModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n ])\r\n ],\r\n declarations: [\r\n GLAccountListComponent,\r\n GLAccountDetailsComponent,\r\n GLAccountBulkUpdateComponent,\r\n GLAccountBulkUpdateActionComponent,\r\n GLAccountBulkUpdateIncomeStatementTypesComponent\r\n ],\r\n providers: [\r\n GLAccountService\r\n ],\r\n exports: [\r\n GLAccountListComponent,\r\n GLAccountDetailsComponent\r\n ]\r\n})\r\nexport class GLAccountModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('glAccountList', GLAccountListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('glAccountDetails', GLAccountDetailsComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { AgGridModule } from 'ag-grid-angular'\r\nimport { SupplementalInformationSheetComponent } from './Supplemental-Information-Sheet/supplementalInformationSheet.component';\r\nimport { DropdownCellRenderer } from './Supplemental-Information-Sheet/agGridDropdownCellRenderer.component';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n AgGridExtensionsModule,\r\n AgGridModule\r\n ],\r\n declarations: [\r\n SupplementalInformationSheetComponent,\r\n DropdownCellRenderer\r\n ]\r\n})\r\nexport class SupplementalInformationModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('supplementalInformationSheet', SupplementalInformationSheetComponent);\r\n }\r\n}\r\n","import { forwardRef, NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { AgGridModule } from 'ag-grid-angular'\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component'\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { LongRunningProcessListComponent } from './Long-Running-Process-List/longRunningProcessList.component';\r\nimport { LongRunningProcessPageComponent } from './Long-Running-Process-Page/longRunningProcessPage.component';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { LongRunningProcessService } from './longRunningProcess.service';\r\nimport { LongRunningProcessQuiesceComponent } from './Long-Running-Process-Quiesce/longRunningProcessQuiesce.component';\r\nimport { LongRunningProcessQuiesceModalComponent } from './Long-Running-Process-Quiesce-Modal/longRunningProcessQuiesceModal.component';\r\nimport { LongRunningProcessSyntheticComponent } from './Long-Running-Process-Synthetic/longRunningProcessSynthetic.component';\r\nimport { LongRunningProcessSyntheticModalComponent } from './Long-Running-Process-Synthetic-Modal/longRunningProcessSyntheticModal.component';\r\nimport { LongRunningProcessControlComponent } from './Long-Running-Process-Control/longRunningProcessControl.component';\r\nimport { LongRunningProcessControlModalComponent } from './Long-Running-Process-Control-Modal/longRunningProcessControlModal.component';\r\nimport { LongRunningProcessListGridActionCellRendererComponent } from './Long-Running-Process-List/agGridActionCellRenderer.component';\r\nimport {\r\n LongRunningProcessListGridErrorGuidCellRendererComponent\r\n} from \"./Long-Running-Process-List/long-running-process-list-grid-error-guid-cell-renderer.component\";\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n ReactiveFormsModule,\r\n CommonModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n LongRunningProcessListGridActionCellRendererComponent,\r\n LongRunningProcessListGridErrorGuidCellRendererComponent\r\n ])\r\n ],\r\n declarations: [\r\n LongRunningProcessPageComponent,\r\n LongRunningProcessListComponent,\r\n LongRunningProcessQuiesceComponent,\r\n LongRunningProcessQuiesceModalComponent,\r\n LongRunningProcessSyntheticComponent,\r\n LongRunningProcessSyntheticModalComponent,\r\n LongRunningProcessControlComponent,\r\n LongRunningProcessControlModalComponent,\r\n LongRunningProcessListGridActionCellRendererComponent,\r\n LongRunningProcessListGridErrorGuidCellRendererComponent\r\n ],\r\n providers: [\r\n LongRunningProcessService\r\n ],\r\n exports: []\r\n})\r\nexport class LongRunningProcessModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('longRunningProcessPage', LongRunningProcessPageComponent);\r\n hybridAdapterUtility.downgradeNg2Component('longRunningProcessList', LongRunningProcessListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('longRunningProcessQuiesceComponent', LongRunningProcessQuiesceComponent);\r\n hybridAdapterUtility.downgradeNg2Component('longRunningProcessQuiesceModalComponent', LongRunningProcessQuiesceModalComponent);\r\n hybridAdapterUtility.downgradeNg2Component('longRunningProcessSyntheticComponent', LongRunningProcessSyntheticComponent);\r\n hybridAdapterUtility.downgradeNg2Component('longRunningProcessSyntheticModalComponent', LongRunningProcessSyntheticModalComponent);\r\n hybridAdapterUtility.downgradeNg2Component('longRunningProcessControlComponent', LongRunningProcessControlComponent);\r\n hybridAdapterUtility.downgradeNg2Component('longRunningProcessControlModalComponent', LongRunningProcessControlModalComponent);\r\n }\r\n}\r\n","\r\nimport {map} from 'rxjs/operators';\r\nimport { Injectable } from '@angular/core';\r\nimport { HttpEvent, HttpInterceptor, HttpHandler, HttpRequest, HttpResponse } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\n\r\nimport { UtilitiesService } from '../../../UI-Lib/Utilities/Utilities.Service.upgrade';\r\n\r\n/**\r\n * Looks at a response and converts all Date strings into JavaScript Date objects.\r\n */\r\n@Injectable()\r\nexport class DateConvertInterceptor implements HttpInterceptor {\r\n constructor(private _utilities: UtilitiesService) { }\r\n\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n return next\r\n .handle(req).pipe(\r\n map(event => {\r\n if (event instanceof HttpResponse) {\r\n this._utilities.convertDateStringsToDates(event.body);\r\n }\r\n return event;\r\n }));\r\n }\r\n}\r\n","import {tap} from 'rxjs/operators';\r\nimport { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\n\r\nimport { Injectable } from '@angular/core';\r\nimport { TimerService } from '../../../UI-Lib/Utilities/timer.service';\r\n\r\n// Trust me, angular exists on window (this lets us hook into AngularJS)\r\ndeclare const angular: any;\r\n\r\n@Injectable()\r\nexport class Angular1CallbackInterceptor implements HttpInterceptor {\r\n constructor(private readonly _timer: TimerService) {}\r\n\r\n intercept(request: HttpRequest, next: HttpHandler): Observable> {\r\n return next.handle(request).pipe(tap(() => {\r\n /* Sometimes the new Angular http client appears to not hook AngularJS and kick off a digest cycle;\r\n * one such example is WK-6566, where the client services panel will load but the loading spinner doesn't\r\n * immediately disappear. If the user takes any action that AngularJS can tell might have altered the state,\r\n * everything will work again, but most of the time when the user is looking at a loading spinner, they're not\r\n * doing anything except waiting. Zone.js should be taking care of this so that any asynchronous event gets\r\n * hooked and kicks off a digest, but for whatever reason under some circumstances it fails. It also appears to\r\n * be a timing bug of some sort, as there is no series of steps we've ever found that reproduces the bug\r\n * reliably. For now, any time we make an HTTP call, go reach into Angular and tell it a change might have\r\n * happened. */\r\n this._timer.setTimeout(() => angular.element(document.body).injector().get('$rootScope').$apply(), 1);\r\n }));\r\n }\r\n}\r\n","export class HandledError extends Error {\r\n constructor(message: string, public originalError: Error) {\r\n super(message);\r\n this.name = 'HandledError';\r\n }\r\n}","import { tap } from 'rxjs/operators';\r\nimport { HttpEvent, HttpErrorResponse, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable, Inject } from '@angular/core';\r\nimport { AuthStorageService } from '../../../User/authStorage.service';\r\nimport { HandledError } from '../../Models/errorModels';\r\nimport { AppStates, AppStateService } from '../../../Layout/appStateService';\r\n\r\n@Injectable()\r\nexport class AuthInterceptor implements HttpInterceptor {\r\n constructor(\r\n @Inject('$rootScope') private _rootScope: any,\r\n @Inject('$location') private _location: any,\r\n private _authStorageService: AuthStorageService,\r\n private _appStateService: AppStateService\r\n ) {\r\n _appStateService.appState$.subscribe(s => this.appState = s);\r\n }\r\n\r\n private appState: AppStates;\r\n\r\n intercept(request: HttpRequest, next: HttpHandler): Observable> {\r\n if (this.appState === AppStates.LoggedOut) {\r\n throw 'Cannot make web request when logged out';\r\n }\r\n\r\n let token: string = null;\r\n const inMemoryAuthData = this._authStorageService.getAuthData();\r\n // Check for calls to /api/token where there is an Authorization header already. In that case, we\r\n // want to respect the auth header override.\r\n if (inMemoryAuthData && !(request.url.endsWith('/api/token') && request.headers.has('Authorization'))) {\r\n token = inMemoryAuthData.access_token;\r\n }\r\n if (token !== null) {\r\n request = request.clone({\r\n setHeaders: {\r\n Authorization: `Bearer ${token}`\r\n }\r\n });\r\n }\r\n\r\n // All HTTP requests should count as \"Activity\" (unless it is refreshing the token, which happens automatically).\r\n if (!(request.url.indexOf('api/token') >= 0)) {\r\n this._authStorageService.recordActivity('Angular2+ HTTP');\r\n }\r\n\r\n return next.handle(request).pipe(\r\n tap((event: HttpEvent) => { return null; }, (error: any) => {\r\n if (error instanceof HttpErrorResponse) {\r\n if (error.status == 403) {\r\n this._rootScope.$broadcast('navigationErrorCode403', error.message);\r\n }\r\n // WK-7767 - Same deal as the AngularJS interceptor for 401 responses; if the token changed between\r\n // the start and end of the request, it's a clue that this may not really be because the session died.\r\n // Assume this is an unexpected error in that case and let it fall through.\r\n else if (error.status == 401 && this._authStorageService.getAuthData().access_token === token) {\r\n if (this._authStorageService.authInterceptEnabled) {\r\n // The \"error\" property on Angular's response object actually contains the body of the\r\n // response. Confusingly, there is a message property, but it is something like\r\n // \"Http failure response for (url): 401 Unauthorized. Usually the API will respond in a\r\n // 401 with a string that explains why the user is not authorized, but not always. If\r\n // it doesn't just use a generic error message.\r\n let logoutMessage = 'Your session has ended unexpectedly';\r\n if (error.error && typeof(error.error) === 'string') {\r\n logoutMessage = error.error;\r\n }\r\n this._authStorageService.logoutMessage$.next(logoutMessage);\r\n throw new HandledError('401 response', error);\r\n }\r\n } else if (error.status == 503 || error.status == 502) {\r\n (window as any).location.reload(true);\r\n }\r\n }\r\n }));\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class CacheBusterInterceptor implements HttpInterceptor {\r\n intercept(request: HttpRequest, next: HttpHandler): Observable> {\r\n if (request.method === 'GET') {\r\n request = request.clone({\r\n params: request.params.set('cacheBuster', Date.now().toString())\r\n });\r\n }\r\n return next.handle(request);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\nimport { UserInstanceService } from '../../../User/userInstance.service';\r\n\r\n@Injectable()\r\nexport class InstanceHeaderInterceptor implements HttpInterceptor {\r\n constructor(private userInstanceService : UserInstanceService) {\r\n\r\n }\r\n intercept(request: HttpRequest, next: HttpHandler): Observable> {\r\n const method = request.method.toLowerCase();\r\n const url = request.url.toLowerCase();\r\n // If making one of these requests, we may be too early in the pipeline to clean the filtered instance\r\n // list, so skip the instance header entirely (this happens on initial login; we don't have the list\r\n // of instances until after GetUserInfo is called).\r\n const skipInstanceHeaderCases = [{ method: 'get', url: 'api/account/getuserinfo' }];\r\n\r\n if (!skipInstanceHeaderCases.some(c => method === c.method && url.indexOf(c.url) >= 0)) {\r\n //Add Instance selections to header - headers are immutable, hence the clone\r\n request = request.clone({\r\n setHeaders: {\r\n Instances: this.userInstanceService.getInstancesForHeader()\r\n }\r\n });\r\n }\r\n\r\n return next.handle(request);\r\n }\r\n}\r\n","import { HTTP_INTERCEPTORS } from '@angular/common/http';\r\nimport { DateConvertInterceptor } from './dateConvertInterceptor';\r\nimport { Angular1CallbackInterceptor } from './angular1CallbackInterceptor';\r\nimport { AuthInterceptor } from './authInterceptor';\r\nimport { CacheBusterInterceptor } from './cacheBusterInterceptor';\r\nimport { InstanceHeaderInterceptor } from './instanceHeaderInterceptor';\r\n\r\n/** Http interceptor providers in outside-in order. */\r\nexport const httpInterceptorProviders = [\r\n // Go tell AngularJS an event happened on every HTTP call; let's keep this interceptor first so that it fires last.\r\n { provide: HTTP_INTERCEPTORS, useClass: Angular1CallbackInterceptor, multi: true },\r\n { provide: HTTP_INTERCEPTORS, useClass: InstanceHeaderInterceptor, multi: true },\r\n { provide: HTTP_INTERCEPTORS, useClass: AuthInterceptor, multi: true},\r\n { provide: HTTP_INTERCEPTORS, useClass: CacheBusterInterceptor, multi: true},\r\n { provide: HTTP_INTERCEPTORS, useClass: DateConvertInterceptor, multi: true }\r\n];\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class LoggingService {\r\n logError(e) {\r\n if (e.rejection && e.rejection.error) {\r\n console.error(e.rejection.error);\r\n return;\r\n }\r\n else if (e.rejection) {\r\n console.error(e.rejection);\r\n return;\r\n }\r\n\r\n console.error(e);\r\n }\r\n}\r\n","import { ErrorHandler, Injectable, Injector, Inject } from '@angular/core';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { LoggingService } from '../Logging/logging.service';\r\nimport { HandledError } from '../Models/errorModels';\r\nimport * as _ from 'lodash';\r\n\r\n@Injectable()\r\nexport class GlobalErrorHandler implements ErrorHandler {\r\n constructor(@Inject(Injector) private _injector: Injector) {\r\n this._debouncedErrorHandler = _.debounce(this.internalErrorHandler, 250);\r\n }\r\n\r\n private readonly _translationMap = {\r\n 'Cannot send data if the connection is not in the \\'Connected\\' State.': 'Unable to connect to the real-time update service. Functionality may be degraded.'\r\n };\r\n\r\n private _debouncedErrorHandler;\r\n\r\n handleError(e): void {\r\n this._debouncedErrorHandler(e);\r\n }\r\n\r\n\r\n private internalErrorHandler(e) {\r\n // No idea why we can't just do e.rejection instanceof HandledError; use the name property to detect\r\n // this case.\r\n if (e instanceof HandledError || (e.rejection && e.rejection.name === HandledError.name)) {\r\n return;\r\n }\r\n\r\n // Status code 403 is handled in ngjsStart.js. No need to show the generic 'An unexpected error has occurred' error message\r\n // xhrStatus = abort when user cancels a request. No need to show error\r\n if (e.rejection && ([403].includes(e.rejection.status) || e.rejection.xhrStatus === 'abort')){\r\n return;\r\n }\r\n\r\n const loggingService = this._injector.get(LoggingService);\r\n const toastr = this._injector.get(ToastrService);\r\n loggingService.logError(e);\r\n\r\n let message = 'An unexpected error has occurred';\r\n\r\n if (e.rejection && e.rejection.message) {\r\n message = e.rejection.message;\r\n }\r\n\r\n if (e.rejection && e.rejection.error && e.rejection.error.message) {\r\n message = e.rejection.error.message;\r\n }\r\n\r\n if (this._translationMap[message]) {\r\n message = this._translationMap[message];\r\n }\r\n\r\n message = message.replace('\\r\\n', '
');\r\n toastr.error(message, '', {enableHtml: true});\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ICellRendererParamsForLinkedSitesListGridAction extends ICellRendererParams {\r\n canRemove: (params: ICellRendererParamsForLinkedSitesListGridAction) => boolean;\r\n remove: (params: ICellRendererParamsForLinkedSitesListGridAction) => void;\r\n toggleMaster: (params: ICellRendererParamsForLinkedSitesListGridAction) => void;\r\n getMasterTitle: (params: ICellRendererParamsForLinkedSitesListGridAction) => string;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n \r\n \r\n `\r\n})\r\nexport class LinkedSitesListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForLinkedSitesListGridAction;\r\n\r\n agInit(params: ICellRendererParamsForLinkedSitesListGridAction): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Injectable} from '@angular/core';\r\nimport { WeissmanKeyValueDisplayPipe } from '../../UI-Lib/Pipes/Key-Value-Display/keyValueDisplay-pipe';\r\n\r\n@Injectable()\r\nexport class ComplianceSiteService {\r\n constructor(private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe) { }\r\n\r\n getLinkedSiteName(linkedSite: Core.LinkedSiteModel) {\r\n return linkedSite.siteProperty\r\n ? this._keyValueDisplayPipe.transform(linkedSite, linkedSite.siteProperty, linkedSite.siteName)\r\n : linkedSite.siteName;\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport * as _ from 'lodash';\r\nimport { ReportingParcelRepository } from '../../../../Compliance/Repositories';\r\nimport { AgGridMultiSelectTracker, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectedCellRenderer } from '../../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { lastValueFrom, Subscription } from 'rxjs';\r\nimport { GridApi, GridReadyEvent, ColDef, GridOptions } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams } from '../../../AgGrid';\r\nimport { ComplianceSiteService } from '../../site.service';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\n\r\nexport interface LinkedSitesAddParams {\r\n companyId: number;\r\n sites: Core.LinkedSiteModel[];\r\n originalSites: Core.LinkedSiteModel[];\r\n siteId: number;\r\n}\r\n\r\ninterface LinkedSiteModelSelectable extends Core.LinkedSiteModel {\r\n isSelected: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'linked-sites-add',\r\n templateUrl: './linkedSitesAdd.component.html',\r\n styleUrls: ['./linkedSitesAdd.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class LinkedSitesAddComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _reportingParcelRepository: ReportingParcelRepository,\r\n private readonly _siteService: ComplianceSiteService) {\r\n }\r\n\r\n private _gridApi: GridApi;\r\n private _gridTracker: AgGridMultiSelectTracker;\r\n private _selectedRowsSub: Subscription;\r\n private _availableSites: Core.LinkedSiteModel[];\r\n private _allSites: Core.LinkedSiteModel[];\r\n\r\n params: LinkedSitesAddParams;\r\n result: Core.LinkedSiteModel[] = [];\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this._gridTracker.isRowSelected((params.data as Core.LinkedSiteModel).siteId)\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withFloatingFilter()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n rowsSelected: boolean = false;\r\n\r\n async ngOnInit(): Promise {\r\n const searchModel: Core.LinkedSiteSearchModel = {\r\n companyId: this.params.companyId,\r\n includeMasterSites: false\r\n };\r\n\r\n // get available sites from db\r\n const availableSites = await lastValueFrom(this._reportingParcelRepository.getAvailableSites(searchModel));\r\n\r\n // add sites originally linked, but not updated in db yet\r\n this._allSites = _.concat(availableSites, this.params.originalSites);\r\n\r\n // remove any sites in available already selected\r\n const result = _.filter(this._allSites, (as: Core.LinkedSiteModel) => !_.some(this.params.sites, (s: Core.LinkedSiteModel) => { return as.siteId === s.siteId; }));\r\n\r\n this._availableSites = _.map(result, (s) => { return { ...s, isSelected: false } as LinkedSiteModelSelectable });\r\n\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._selectedRowsSub && this._selectedRowsSub.unsubscribe();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n this._selectedRowsSub = this._gridTracker.selectedRows$.subscribe(x => {\r\n this.rowsSelected = x.selectAllRows || x.selectedRows.length > 0;\r\n });\r\n\r\n const columns: ColDef[] = [\r\n {\r\n field: 'siteId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressMovable: true,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this._gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this._gridTracker\r\n } as AgGridMultiSelectRendererParams\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const site = params.data as Core.LinkedSiteModel;\r\n return this._siteService.getLinkedSiteName(site) + (site.siteId === this.params.siteId ? ' (this site)' : '');\r\n },\r\n filterValueGetter: params => {\r\n const site = params.data as Core.LinkedSiteModel;\r\n return this._siteService.getLinkedSiteName(site);\r\n }\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n width: AgGridColumns.textColumnMedWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n async save(): Promise {\r\n const rowIds = await this._gridTracker.getSelectedRowIds();\r\n\r\n this.result = _.filter(this._allSites, (x) => _.some(rowIds, (y) => x.siteId === y));\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this._availableSites)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this._availableSites);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n return Promise.resolve({\r\n data: rows.map((x) => {\r\n const site = x.data as LinkedSiteModelSelectable;\r\n return site && site.siteId;\r\n })\r\n } as Compliance.QueryResultModel);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface LinkedSitesListGridNameCellRendererParams extends ICellRendererParams {\r\n getName: (params: LinkedSitesListGridNameCellRendererParams) => string;\r\n getLink: (params: LinkedSitesListGridNameCellRendererParams) => string;\r\n isMaster: (params: LinkedSitesListGridNameCellRendererParams) => boolean;\r\n canNavigate: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'linked-sites-list-grid-name-cell',\r\n template: `\r\n \r\n \r\n \r\n \r\n {{ params.getName(params) }}\r\n \r\n \r\n {{ params.getName(params) }}\r\n \r\n `\r\n})\r\nexport class LinkedSitesListGridNameCellRendererComponent implements ICellRendererAngularComp {\r\n params: LinkedSitesListGridNameCellRendererParams;\r\n\r\n agInit(params: LinkedSitesListGridNameCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","\r\n
\r\n \r\n \r\n
\r\n
\r\n"," 1) || (sites && sites.length === 1))\">\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n
\r\n
1)\">Master site is required.
\r\n
At least 2 linked sites are required.
\r\n
The master site doesn't have 1 active PP parcel so the reporting parcel cannot be set automatically
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, OnDestroy, ElementRef, ViewChild, ViewEncapsulation } from '@angular/core';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport * as _ from 'lodash';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams } from '../../../AgGrid';\r\nimport { LinkedSitesListGridActionCellRendererComponent, ICellRendererParamsForLinkedSitesListGridAction } from './agGridActionCellRenderer.component';\r\nimport { ComplianceSiteService } from '../../site.service';\r\nimport { WeissmanModalService, IWeissmanModalComponent } from '../../../WeissmanModalService';\r\nimport { LinkedSitesAddParams, LinkedSitesAddComponent } from '../Linked-Sites-Add/linkedSitesAdd.component';\r\nimport { LinkedSitesListGridNameCellRendererComponent, LinkedSitesListGridNameCellRendererParams } from './agGridNameCellRenderer.component';\r\nimport { TimerService } from '../../../../UI-Lib/Utilities/timer.service';\r\n\r\ninterface LinkedSiteRowModel extends Core.LinkedSiteModel {\r\n isMaster: boolean;\r\n}\r\n\r\nexport interface LinkedSitesListParams {\r\n companyId: number;\r\n siteId: number;\r\n masterSiteId: number;\r\n sites: Core.LinkedSiteModel[];\r\n editMode: boolean;\r\n}\r\n\r\nexport interface LinkedSitesListResult {\r\n masterSiteId: number;\r\n sites: Core.LinkedSiteModel[];\r\n}\r\n\r\n@Component({\r\n selector: 'linked-sites-list',\r\n templateUrl: './linkedSitesList.component.html',\r\n styleUrls: ['./linkedSitesList.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class LinkedSitesListComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _siteService: ComplianceSiteService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _timer: TimerService) { }\r\n\r\n private _gridApi: GridApi;\r\n private _originalSites: Core.LinkedSiteModel[];\r\n\r\n @ViewChild('focus') focusElement: ElementRef;\r\n\r\n params: LinkedSitesListParams;\r\n result: LinkedSitesListResult;\r\n\r\n sites: LinkedSiteRowModel[];\r\n masterSite: LinkedSiteRowModel;\r\n gridId: System.Guid = '6C6E2165-6879-4A3E-B977-50EB5EA014D6';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'grid-row-master': params => {\r\n const site = params.data as LinkedSiteRowModel;\r\n return site && site.isMaster;\r\n }\r\n }\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n get editMode(): boolean {\r\n return this.params && this.params.editMode;\r\n }\r\n\r\n ngOnInit() {\r\n this._originalSites = _.concat(this.params.sites);\r\n\r\n this.sites = _.map(this.params.sites,\r\n (x) => {\r\n return _.extend(\r\n {},\r\n x,\r\n {\r\n isMaster: x.siteId === this.params.masterSiteId\r\n }) as LinkedSiteRowModel;\r\n });\r\n\r\n this.masterSite = _.find(this.sites, x => x.isMaster);\r\n\r\n this._setRowData();\r\n }\r\n\r\n ngOnDestroy() { }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n width: AgGridColumns.textColumnLargeWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: LinkedSitesListGridNameCellRendererComponent,\r\n cellRendererParams: {\r\n getName: this._getName.bind(this),\r\n getLink: (params) => {\r\n const site = params.data as LinkedSiteRowModel;\r\n if (!site) {\r\n return null;\r\n }\r\n return `#/site/${site.siteId}`;\r\n },\r\n isMaster: (params) => {\r\n const site = params.data as LinkedSiteRowModel;\r\n return site && site.isMaster;\r\n },\r\n canNavigate: !this.editMode\r\n } as LinkedSitesListGridNameCellRendererParams,\r\n filterValueGetter: this._getName.bind(this)\r\n },\r\n {\r\n headerName: 'Master',\r\n field: 'isMaster',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const site = params.data as LinkedSiteRowModel;\r\n return site && site.isMaster ? 'Master' : 'Subordinate';\r\n },\r\n filterValueGetter: params => {\r\n const site = params.data as LinkedSiteRowModel;\r\n return site && site.isMaster ? 'Master' : 'Subordinate';\r\n }\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n lockPinned: true\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n }\r\n ];\r\n\r\n if (this.params.editMode) {\r\n columns.push({\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: LinkedSitesListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n canRemove: this._canRemove.bind(this),\r\n remove: this._remove.bind(this),\r\n toggleMaster: this._toggleMaster.bind(this),\r\n getMasterTitle: this._getMasterTitle.bind(this)\r\n } as ICellRendererParamsForLinkedSitesListGridAction\r\n });\r\n }\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._setRowData();\r\n }\r\n\r\n getLinkedSiteName(linkedSiteModel: Core.LinkedSiteModel) {\r\n return this._siteService.getLinkedSiteName(linkedSiteModel);\r\n }\r\n\r\n save(): void {\r\n // if the current site is the only one in the list, clear all links\r\n if (this.sites.length === 1 && _.find(this.sites, x => x.siteId === this.params.siteId)) {\r\n this.sites = [];\r\n }\r\n\r\n this.result = {\r\n masterSiteId: this.masterSite && this.masterSite.siteId,\r\n sites: this.sites\r\n };\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async add(): Promise {\r\n\r\n const params: LinkedSitesAddParams = {\r\n companyId: this.params.companyId,\r\n sites: this.sites,\r\n originalSites: this._originalSites,\r\n siteId: this.params.siteId\r\n };\r\n\r\n const result = await this._modalService.showAsync(LinkedSitesAddComponent, params, 'modal-lg');\r\n\r\n // restore focus to this modal\r\n this._timer.setTimeout(() => {\r\n this.focusElement.nativeElement.focus();\r\n }, 100);\r\n\r\n const newSites = _.map(result,\r\n (x) => {\r\n return _.extend(\r\n {} as LinkedSiteRowModel,\r\n x,\r\n {\r\n isMaster: this.masterSite && x.siteId === this.masterSite.siteId\r\n });\r\n });\r\n\r\n _.each(newSites, x => this.sites.push(x));\r\n\r\n this._setRowData();\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private _getMasterTitle(params: ICellRendererParamsForLinkedSitesListGridAction): string {\r\n const site = params.data as LinkedSiteRowModel;\r\n if (!site) {\r\n return '';\r\n }\r\n\r\n return site.isMaster ? 'Remove Master' : 'Make Master';\r\n }\r\n\r\n private _toggleMaster(params: ICellRendererParamsForLinkedSitesListGridAction): void {\r\n const newMasterSite = params.data as LinkedSiteRowModel;\r\n if (!newMasterSite) {\r\n return;\r\n }\r\n\r\n newMasterSite.isMaster = !newMasterSite.isMaster;\r\n this.masterSite = newMasterSite.isMaster ? newMasterSite : null;\r\n\r\n _.each(this.sites,\r\n (site) => {\r\n site.masterSiteId = newMasterSite.isMaster ? newMasterSite.siteId : null;\r\n site.isMaster = newMasterSite.isMaster ? site.siteId === newMasterSite.siteId : false;\r\n });\r\n\r\n this._setRowData();\r\n }\r\n\r\n private _canRemove(params: ICellRendererParamsForLinkedSitesListGridAction): boolean {\r\n const site = params.data as LinkedSiteRowModel;\r\n if (!site) {\r\n return false;\r\n }\r\n\r\n return true;\r\n }\r\n\r\n private _remove(params: ICellRendererParamsForLinkedSitesListGridAction): void {\r\n const site = params.data as LinkedSiteRowModel;\r\n if (!site) {\r\n return;\r\n }\r\n\r\n site.masterSiteId = null;\r\n site.isMaster = false;\r\n\r\n if (this.masterSite) {\r\n if (site.siteId === this.masterSite.siteId) {\r\n this.masterSite = null;\r\n }\r\n }\r\n\r\n _.remove(this.sites, x => x.siteId === site.siteId);\r\n\r\n this._setRowData();\r\n }\r\n\r\n removeAll(): void {\r\n _.forEach(this.sites, (site) => {\r\n site.masterSiteId = null;\r\n site.isMaster = false;\r\n });\r\n\r\n this.masterSite = null;\r\n\r\n this.sites = [];\r\n\r\n this._setRowData();\r\n }\r\n\r\n private _getName(params: LinkedSitesListGridNameCellRendererParams): string {\r\n const site = params.data as LinkedSiteRowModel;\r\n if (!site) {\r\n return '';\r\n }\r\n\r\n return this.getLinkedSiteName(site as Core.LinkedSiteModel) + (site.siteId === this.params.siteId ? ' (this site)' : '');\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!(this._gridApi && this.sites)) {\r\n return;\r\n }\r\n\r\n const masterSites = _.filter(this.sites, x => x.isMaster);\r\n const subordinateSites = _.filter(this.sites, x => !x.isMaster);\r\n\r\n this._gridApi.setPinnedTopRowData(masterSites);\r\n this._gridApi.setRowData(subordinateSites);\r\n this._gridApi.sizeColumnsToFit();\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const LINKED_SITES_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'linked-sites.master-site',\r\n tooltipText: 'Master site'\r\n }\r\n];\r\n","
\r\n Master Site:\r\n \r\n
\r\n
\r\n Linked To:\r\n \r\n
\r\n","import { Component, Input, OnInit, OnDestroy, SimpleChanges, SimpleChange } from '@angular/core';\r\nimport * as _ from 'lodash';\r\nimport { ComplianceSiteService } from '../site.service';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { LinkedSitesListParams, LinkedSitesListComponent } from './Linked-Sites-List/linkedSitesList.component';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { LINKED_SITES_HELP } from './linkedSites.component.help';\r\nimport { Site } from 'src/app/Entity/Site/Site.Model';\r\n\r\ninterface ComponentChanges extends SimpleChanges {\r\n sites: SimpleChange;\r\n siteId: SimpleChange;\r\n masterSiteId: SimpleChange;\r\n}\r\n\r\n@Component({\r\n selector: 'linked-sites',\r\n templateUrl: './linkedSites.component.html'\r\n})\r\nexport class LinkedSitesComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _siteService: ComplianceSiteService,\r\n private readonly _bsModalService: BsModalService,\r\n private readonly _wsModalService: WeissmanModalService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _helpService: HelpService) { }\r\n\r\n @Input() site: Site;\r\n @Input() masterSiteId: number;\r\n @Input() sites: Core.LinkedSiteModel[];\r\n @Input() isDisabled: boolean;\r\n\r\n masterSite: Core.LinkedSiteModel;\r\n linkedSites: Core.LinkedSiteModel[];\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(LINKED_SITES_HELP);\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n ngOnChanges(changes: ComponentChanges): void {\r\n this.masterSite = _.find(this.sites, x => this.site.siteID !== this.masterSiteId && x.siteId === this.masterSiteId);\r\n this.linkedSites = _.filter(this.sites, x => x.siteId !== this.masterSiteId);\r\n }\r\n\r\n getLinkedSiteName(linkedSiteModel: Core.LinkedSiteModel) {\r\n return this._siteService.getLinkedSiteName(linkedSiteModel);\r\n }\r\n\r\n async showLinkedSites(): Promise {\r\n try {\r\n const params: LinkedSitesListParams = {\r\n companyId: this.site.companyID,\r\n siteId: this.site.siteID,\r\n sites: _.map(this.site.linkedSites, _.clone),\r\n masterSiteId: this.site.masterSiteId,\r\n editMode: false\r\n };\r\n\r\n await this._wsModalService.show(() => {\r\n return this._bsModalService.show(LinkedSitesListComponent,\r\n {\r\n class: 'modal-lg',\r\n initialState: {\r\n params: params\r\n },\r\n ignoreBackdropClick: true\r\n });\r\n }).whenClosed;\r\n\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n navigateToSite(siteId: number): void {\r\n this._routerService.go('siteRedirect', { 'entityID': siteId });\r\n }\r\n}\r\n","import { Component, OnInit, OnDestroy, ViewEncapsulation } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { ReportingParcelRepository } from '../../../Repositories';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator/busyIndicator.service';\r\nimport { lastValueFrom, Observable } from 'rxjs';\r\nimport * as _ from 'lodash';\r\nimport { ComplianceSiteService } from '../../site.service';\r\nimport { mergeMap } from 'rxjs/operators';\r\n\r\nenum LinkedSitesReportingType {\r\n ThisSite = 1,\r\n AnotherSite = 2\r\n}\r\n\r\nexport interface LinkedSitesReportingParams {\r\n siteId: number;\r\n companyId: number;\r\n}\r\n\r\nexport interface LinkedSitesReportingResult {\r\n masterSite: Core.LinkedSiteModel;\r\n site: Core.LinkedSiteModel;\r\n}\r\n\r\nexport interface LinkedSiteTypeAheadModel extends Core.LinkedSiteModel {\r\n siteDisplayName: string;\r\n}\r\n\r\n@Component({\r\n selector: 'linked-sites-reporting',\r\n templateUrl: './linkedSitesReporting.component.html',\r\n styleUrls: ['./linkedSitesReporting.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class LinkedSitesReportingComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _reportingParcelRepository: ReportingParcelRepository,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _siteService: ComplianceSiteService) {\r\n }\r\n\r\n linkedSitesReportingTypes = LinkedSitesReportingType;\r\n selectedReportingType: LinkedSitesReportingType = LinkedSitesReportingType.ThisSite;\r\n selectedMasterSite: Core.LinkedSiteModel;\r\n site: Core.LinkedSiteModel;\r\n siteFilter: string = '';\r\n siteIsLoading: boolean = false;\r\n params: LinkedSitesReportingParams;\r\n result: LinkedSitesReportingResult;\r\n\r\n sites$: Observable = (Observable\r\n .create((observer: any) => { observer.next(this.siteFilter) }) as Observable)\r\n .pipe(mergeMap(async (token: string) => await this._filterSites(token)));\r\n\r\n async ngOnInit(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n this.site = await lastValueFrom(this._reportingParcelRepository.getLinkedSite(this.params.siteId));\r\n this.selectedMasterSite = this.site;\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n selectedReportingTypeChanged(reportingType: LinkedSitesReportingType): void {\r\n if (reportingType === LinkedSitesReportingType.ThisSite) {\r\n this.selectedMasterSite = this.site;\r\n this.siteFilter = '';\r\n } else {\r\n this.selectedMasterSite = null;\r\n }\r\n }\r\n\r\n async save(): Promise {\r\n this.result = {\r\n masterSite: this.selectedMasterSite,\r\n site: this.site\r\n };\r\n\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n onSiteLoadingChange(isLoading: boolean): void {\r\n this.siteIsLoading = isLoading;\r\n }\r\n\r\n onSiteSelected(match: TypeaheadMatch): void {\r\n this.selectedMasterSite = (match.item as Core.LinkedSiteModel);\r\n this.siteFilter = match.value;\r\n }\r\n\r\n private async _filterSites(filter: string): Promise {\r\n const searchModel: Core.LinkedSiteSearchModel = {\r\n companyId: this.params.companyId,\r\n includeMasterSites: true,\r\n columnFilters: [{\r\n filterProperty: Core.SitePropertyEnum.SiteNameOrNumber,\r\n filterValues: [\r\n {\r\n filterValue: filter,\r\n filterType: Core.FilterTypeEnum.Contains\r\n }\r\n ]\r\n }]\r\n };\r\n\r\n const sites = await lastValueFrom(this._reportingParcelRepository.getAvailableSites(searchModel));\r\n return _.filter(_.map(sites, (x: Core.LinkedSiteModel) => {\r\n return _.extend(\r\n {} as LinkedSiteTypeAheadModel,\r\n x,\r\n {\r\n displayName: this._siteService.getLinkedSiteName(x)\r\n });\r\n }), (x: LinkedSiteTypeAheadModel) => x.siteId !== this.site.siteId);\r\n }\r\n}\r\n","\r\n

How should assets be reported?

\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, OnInit, OnDestroy } from '@angular/core';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { LinkedSitesListComponent, LinkedSitesListParams } from '../Linked-Sites-List/linkedSitesList.component';\r\nimport { WeissmanModalService } from '../.../../../../WeissmanModalService';\r\nimport { LinkedSitesReportingComponent } from '../Linked-Sites-Reporting/linkedSitesReporting.component';\r\nimport * as _ from 'lodash';\r\nimport { LinkedSitesReportingParams } from '../Linked-Sites-Reporting/linkedSitesReporting.component';\r\nimport { LinkedSitesReportingResult } from '../Linked-Sites-Reporting/linkedSitesReporting.component';\r\nimport { Site } from 'src/app/Entity/Site/Site.Model';\r\n\r\n@Component({\r\n selector: 'linked-sites-edit',\r\n templateUrl: './linkedSitesEdit.component.html'\r\n})\r\nexport class LinkedSitesEditComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _bsModalService: BsModalService,\r\n private readonly _wsModalService: WeissmanModalService) {\r\n }\r\n\r\n @Input() site: Site;\r\n @Input() isDisabled: boolean;\r\n\r\n ngOnInit(): void { }\r\n\r\n ngOnDestroy(): void { }\r\n\r\n async edit(): Promise {\r\n try {\r\n\r\n const params: LinkedSitesListParams = {\r\n companyId: this.site.companyID,\r\n siteId: this.site.siteID,\r\n sites: _.map(this.site.linkedSites, _.clone),\r\n masterSiteId: this.site.masterSiteId,\r\n editMode: true\r\n };\r\n\r\n if (!params.sites.length) {\r\n const bsReportingModalRef = await this._wsModalService.show(() => {\r\n return this._bsModalService.show(LinkedSitesReportingComponent,\r\n {\r\n class: 'modal-md',\r\n initialState: {\r\n params: {\r\n siteId: this.site.siteID,\r\n companyId: this.site.companyID\r\n } as LinkedSitesReportingParams\r\n },\r\n ignoreBackdropClick: true\r\n });\r\n }).whenClosed;\r\n\r\n const reportingResult: LinkedSitesReportingResult = (bsReportingModalRef.content as LinkedSitesReportingComponent).result;\r\n if (!reportingResult && reportingResult.site && reportingResult.masterSite) {\r\n return Promise.resolve();\r\n }\r\n\r\n reportingResult.site.masterSiteId = reportingResult.masterSite.siteId;\r\n params.masterSiteId = reportingResult.masterSite.siteId;\r\n params.sites.push(reportingResult.site);\r\n\r\n if (reportingResult.masterSite.siteId !== reportingResult.site.siteId) {\r\n params.sites.push(reportingResult.masterSite);\r\n }\r\n }\r\n\r\n const bsModalSitesRef = await this._wsModalService.show(() => {\r\n return this._bsModalService.show(LinkedSitesListComponent,\r\n {\r\n class: 'modal-lg',\r\n initialState: {\r\n params: params\r\n },\r\n ignoreBackdropClick: true\r\n });\r\n }).whenClosed;\r\n\r\n const sitesResult = (bsModalSitesRef.content as LinkedSitesListComponent).result;\r\n\r\n if (!sitesResult) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.site.masterSiteId = sitesResult.masterSiteId;\r\n this.site.linkedSites = sitesResult.sites;\r\n\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n}\r\n","\r\n","import { forwardRef, NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { LinkedSitesComponent } from './Linked-Sites/linkedSites.component';\r\nimport { LinkedSitesEditComponent } from './Linked-Sites/Linked-Sites-Edit/linkedSitesEdit.component';\r\nimport { LinkedSitesListComponent } from './Linked-Sites/Linked-Sites-List/linkedSitesList.component';\r\nimport { LinkedSitesListGridActionCellRendererComponent } from './Linked-Sites/Linked-Sites-List/agGridActionCellRenderer.component';\r\nimport { ComplianceSiteService } from './site.service';\r\nimport { LinkedSitesAddComponent } from './Linked-Sites/Linked-Sites-Add/linkedSitesAdd.component';\r\nimport { LinkedSitesReportingComponent } from './Linked-Sites/Linked-Sites-Reporting/linkedSitesReporting.component';\r\nimport { LinkedSitesListGridNameCellRendererComponent } from './Linked-Sites/Linked-Sites-List/agGridNameCellRenderer.component';\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n CommonModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n LinkedSitesListGridActionCellRendererComponent,\r\n LinkedSitesListGridNameCellRendererComponent\r\n ]),\r\n TypeaheadModule\r\n ],\r\n declarations: [\r\n LinkedSitesComponent,\r\n LinkedSitesEditComponent,\r\n LinkedSitesListComponent,\r\n LinkedSitesListGridActionCellRendererComponent,\r\n LinkedSitesAddComponent,\r\n LinkedSitesReportingComponent,\r\n LinkedSitesListGridNameCellRendererComponent\r\n ],\r\n providers: [\r\n ComplianceSiteService\r\n ],\r\n exports: [\r\n LinkedSitesComponent,\r\n LinkedSitesEditComponent,\r\n LinkedSitesListComponent,\r\n LinkedSitesAddComponent,\r\n LinkedSitesReportingComponent\r\n ]\r\n})\r\nexport class ComplianceSiteModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('linkedSites', LinkedSitesComponent);\r\n hybridAdapterUtility.downgradeNg2Component('linkedSitesEdit', LinkedSitesEditComponent);\r\n hybridAdapterUtility.downgradeNg2Component('linkedSitesList', LinkedSitesListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('linkedSitesAdd', LinkedSitesAddComponent);\r\n hybridAdapterUtility.downgradeNg2Component('linkedSitesReporting', LinkedSitesReportingComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { AgGridExtensionsModule } from '../../Compliance/AgGrid/agGridExtensions.module';\r\nimport { ErrorLogListComponent } from './Error-Log-List/errorLogList.component';\r\nimport { ErrorLogService } from './errorLog.service';\r\nimport { ErrorLogListGridActionCellRendererComponent } from './Error-Log-List/agGridActionCellRenderer.component';\r\nimport { ErrorLogDetailsComponent } from './Error-Log-Details/errorLogDetails.component';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\n\r\n@NgModule({\r\n imports: [\r\n TabsModule,\r\n FormsModule,\r\n ReactiveFormsModule,\r\n CommonModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n ErrorLogListGridActionCellRendererComponent\r\n ])\r\n ],\r\n declarations: [\r\n ErrorLogListComponent,\r\n ErrorLogListGridActionCellRendererComponent,\r\n ErrorLogDetailsComponent\r\n ],\r\n providers: [\r\n ErrorLogService\r\n ],\r\n exports: []\r\n})\r\nexport class ErrorLogModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('errorLogList', ErrorLogListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('errorLogDetails', ErrorLogDetailsComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { AgGridExtensionsModule } from '../../Compliance/AgGrid/agGridExtensions.module';\r\nimport { QueryInfoListComponent } from './Query-Info-List/queryInfoList.component';\r\nimport { QueryInfoService } from './queryInfo.service';\r\nimport { QueryInfoListGridActionCellRendererComponent } from './Query-Info-List/agGridActionCellRenderer.component';\r\nimport { QueryInfoDetailsComponent } from './Query-Info-Details/queryInfoDetails.component';\r\n\r\n@NgModule({\r\n imports: [\r\n FormsModule,\r\n ReactiveFormsModule,\r\n CommonModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n QueryInfoListGridActionCellRendererComponent\r\n ])\r\n ],\r\n declarations: [\r\n QueryInfoListComponent,\r\n QueryInfoListGridActionCellRendererComponent,\r\n QueryInfoDetailsComponent\r\n ],\r\n providers: [\r\n QueryInfoService\r\n ],\r\n exports: []\r\n})\r\nexport class QueryInfoModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('queryInfoList', QueryInfoListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('queryInfoDetails', QueryInfoDetailsComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { CommandViewControlsComponent } from './Command-View-Controls/viewControls.component';\r\nimport { StateJurisdictionCommandCenterComponent } from './stateJurisdiction.component';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { StateJurisdictionBulkUpdateComponent } from './Bulk-Update/stateJurisdictionBulkUpdate.component';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n AgGridExtensionsModule,\r\n AgGridModule,\r\n BusyIndicatorModule.forRoot()\r\n ],\r\n declarations: [\r\n CommandViewControlsComponent,\r\n StateJurisdictionCommandCenterComponent,\r\n StateJurisdictionBulkUpdateComponent\r\n ],\r\n exports: [StateJurisdictionCommandCenterComponent]\r\n})\r\nexport class StateJurisdictionModule {\r\n static setupModule(): void {\r\n hybridAdapterUtility.downgradeNg2Component('stateJurisdictionCommandCenter', StateJurisdictionCommandCenterComponent);\r\n }\r\n}\r\n","
\r\n \r\n\r\n
\r\n \r\n \r\n \r\n

\r\n Tax year is required\r\n

\r\n
\r\n\r\n
\r\n \r\n \r\n

\r\n Description is required\r\n

\r\n
\r\n\r\n
\r\n \r\n \r\n \r\n

\r\n Parcel is required\r\n

\r\n
\r\n\r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { UntypedFormGroup, Validators, UntypedFormBuilder } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { lastValueFrom, Subject } from 'rxjs';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport { YearPickerMixin } from '../../../../UI-Lib/Mixins';\r\nimport { AllocationRepository } from '../../../Repositories';\r\nimport { IWeissmanModalComponent } from '../../../WeissmanModalService';\r\n\r\nexport interface AddAllocationModalParams {\r\n companyId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'add-allocation-modal',\r\n templateUrl: './addAllocationModal.component.html'\r\n})\r\nexport class AddAllocationModalComponent extends YearPickerMixin() implements OnInit, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _allocationRepository: AllocationRepository,\r\n private readonly _bsModalRef: BsModalRef) {\r\n super();\r\n }\r\n\r\n params: AddAllocationModalParams;\r\n result: Compliance.AllocationModel;\r\n\r\n allocationForm: UntypedFormGroup;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n async ngOnInit(): Promise {\r\n this.allocationForm = this._fb.group({\r\n taxYear: [new Date().getFullYear(), Validators.required],\r\n description: [null, Validators.required],\r\n parcelId: [null, Validators.required],\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n async addAllocation(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Adding Allocation' });\r\n const { taxYear, description, parcelId } = this.allocationForm.value;\r\n\r\n const model = {\r\n annualAssessmentId: -1\r\n } as Compliance.AllocationCreateModel;\r\n\r\n try {\r\n this.result = await lastValueFrom(this._allocationRepository.create(this.params.companyId, model));\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n this.cancel();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n //todo: do not use any\r\n getParcels = (searchParams: any) => {\r\n const { taxYear, description, parcelId } = this.allocationForm.value;\r\n searchParams.taxYear = taxYear;\r\n return lastValueFrom(this._allocationRepository.getAvailableParcels(searchParams));\r\n };\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { AttachmentModalData } from '../../../Attachment/attachment.modal.model';\r\nimport { CommentModalData } from '../../../Comments/comments.service';\r\n\r\nexport interface ICellRendererParamsForAllocationListGridAction extends ICellRendererParams {\r\n canEdit: boolean;\r\n viewDetails: (params: ICellRendererParamsForAllocationListGridAction) => void;\r\n delete: (params: ICellRendererParamsForAllocationListGridAction) => void;\r\n canDelete: (params: ICellRendererParamsForAllocationListGridAction) => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n`\r\n})\r\nexport class AllocationListGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForAllocationListGridAction;\r\n allocation: Compliance.AllocationModel;\r\n attachmentModalData: AttachmentModalData;\r\n commentModalData: CommentModalData;\r\n\r\n agInit(params: ICellRendererParamsForAllocationListGridAction): void {\r\n this.params = params;\r\n this.allocation = params.data as Compliance.AllocationModel;\r\n\r\n if (!this.allocation) {\r\n return;\r\n }\r\n\r\n this.attachmentModalData = {\r\n entityType: 'Allocation', //todo: make this a constant generated typescript value\r\n entityName: this.allocation.description,\r\n year: this.allocation.taxYear,\r\n disableYears: true,\r\n singleYear: true,\r\n entityData: {\r\n typeId: Core.EntityTypes.Allocation,\r\n id: this.allocation.allocationId,\r\n name: this.allocation.description\r\n },\r\n readOnly: !this.params.canEdit\r\n } as AttachmentModalData;\r\n\r\n this.commentModalData = {\r\n entityID: this.allocation.allocationId,\r\n entityTypeID: Core.EntityTypes.Allocation,\r\n entityName: this.allocation.description,\r\n parcelAcctNum: null,\r\n canEdit: this.params.canEdit,\r\n description: null,\r\n parcelID: null,\r\n year: this.allocation.taxYear.toString()\r\n } as CommentModalData;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n onViewDetailsClicked(): void {\r\n this.params.viewDetails(this.params);\r\n }\r\n\r\n onDeleteClicked(): void {\r\n this.params.delete(this.params);\r\n }\r\n}\r\n","import { GridApi, IGetRowsParams } from 'ag-grid-community';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { AgGridDataSourceBase } from '../../AgGrid';\r\nimport { AgGridDataSourceResult } from '../../AgGrid';\r\nimport { AllocationRepository } from '../../Repositories';\r\n\r\nexport interface AllocationListDataSourceParams {\r\n includeCompleted: boolean;\r\n companyId: number;\r\n}\r\n\r\nexport class AllocationListAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _allocationRepository: AllocationRepository,\r\n protected _dataSourceParamsFn: () => AllocationListDataSourceParams\r\n ) {\r\n super(_gridApi);\r\n }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'description', value: Compliance.AllocationPropertyEnum.Description },\r\n { name: 'companyName', value: Compliance.AllocationPropertyEnum.Company },\r\n { name: 'taxYear', value: Compliance.AllocationPropertyEnum.TaxYear },\r\n { name: 'stateAbbr', value: Compliance.AllocationPropertyEnum.State },\r\n { name: 'siteProperty', value: Compliance.AllocationPropertyEnum.SiteName },\r\n { name: 'siteNumber', value: Compliance.AllocationPropertyEnum.SiteNumber }\r\n ];\r\n\r\n async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Compliance.AllocationSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap)\r\n };\r\n\r\n const result = await lastValueFrom(this._allocationRepository.getList(this._dataSourceParams.companyId, searchParams));\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n return null;\r\n }\r\n\r\n getSearchParamsWithoutPagination(): Compliance.AllocationSearchModel {\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n includeCompleted: this._dataSourceParams.includeCompleted\r\n } as Compliance.AllocationSearchModel;\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return (this._dataSourceParams.companyId !== null);\r\n }\r\n\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const ALLOCATION_LIST_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'allocation-list.completed',\r\n tooltipText: 'Include allocations where all tasks have been completed.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'allocation-list.new-allocation',\r\n tooltipText: 'New allocation'\r\n }\r\n];\r\n","
\r\n \r\n
\r\n
\r\n

\r\n Allocations\r\n \r\n

\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { BreadCrumb } from '../../../UI-Lib/Bread-Crumb/breadCrumbs.component';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { InstanceRights, RestrictService } from '../../../Common/Permissions/restrict.service';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { CompanyService } from '../../../Entity/Company/company.service';\r\nimport { AgGridColumns, AgGridFilterParams, AgGridOptionsBuilder } from '../../AgGrid';\r\nimport {\r\n AgGridLinkCellRendererComponent,\r\n AgGridLinkCellRendererParams\r\n} from '../../AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { AllocationRepository } from '../../Repositories';\r\nimport { WeissmanModalService } from '../../WeissmanModalService';\r\nimport { AddAllocationModalComponent, AddAllocationModalParams } from './Add-Allocation/addAllocationModal.component';\r\nimport {\r\n AllocationListGridActionCellRendererComponent,\r\n ICellRendererParamsForAllocationListGridAction\r\n} from './agGridActionCellRenderer.component';\r\nimport { AllocationListAgGridDataSource, AllocationListDataSourceParams } from './agGridDataSource';\r\nimport { ALLOCATION_LIST_HELP } from './allocationList.component.help';\r\nimport { MessageModalService } from '../../../UI-Lib/Message-Box/messageModal.service';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from '../../AgGrid/ToolPanel/models';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport LongRunningProcessTypeEnum = Compliance.LongRunningProcessTypeEnum;\r\n\r\n@Component({\r\n selector: 'allocation-list',\r\n templateUrl: './allocationList.component.html',\r\n styleUrls: ['./allocationList.component.scss']\r\n})\r\nexport class AllocationListComponent implements OnInit {\r\n constructor(\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _companyService: CompanyService,\r\n private readonly _allocationRepository: AllocationRepository,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService,\r\n private readonly _messageModalService: MessageModalService,) { }\r\n\r\n breadcrumbs: BreadCrumb[] = [];\r\n companyId: number;\r\n companyName: string;\r\n\r\n isInitialized: boolean;\r\n canEdit: boolean;\r\n includeCompleted: boolean;\r\n refreshing: boolean;\r\n\r\n gridId: System.Guid = '70EC2321-804B-40E3-A32D-CA8C5C943D95';\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n rowClassRules: {\r\n 'row-completed': (params) => {\r\n const gridRow = params.data as Compliance.FilingBatchModel;\r\n return gridRow && gridRow.completedDate !== null;\r\n }\r\n }\r\n }).buildDefault(this);\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const searchParams = this._gridDataSource.getSearchParamsWithoutPagination();\r\n const exportModel: Compliance.AllocationExportModel = {\r\n searchModel: searchParams,\r\n columnsToReturn: columnsToReturn,\r\n fileFormat\r\n };\r\n\r\n const lrp$ = this._allocationRepository.startExport(this.companyId, exportModel);\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n return { longRunningProcessId, longRunningProcessTypeId: LongRunningProcessTypeEnum.ExportAllocations };\r\n },\r\n canCancel: true,\r\n showFileFormatSelection: true\r\n };\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: AllocationListAgGridDataSource;\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(ALLOCATION_LIST_HELP);\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n\r\n const responses = await Promise.all([\r\n this._companyService.load(this.companyId, false, false),\r\n this._restrictService.hasCompanyPermission(this.companyId, Core.AccessRightsEnum.Write)\r\n ]);\r\n\r\n const company = responses[0];\r\n\r\n if (!(company.ppReturnPreparationAllowed && this._restrictService.hasInstanceRight(InstanceRights.COMPLIANCEFEATURESVIEW, company.instanceID))) {\r\n this.navigateToUnauthorized();\r\n return Promise.resolve();\r\n }\r\n\r\n this.companyName = company.companyName;\r\n this.canEdit = responses[1];\r\n\r\n this.breadcrumbs.push({\r\n name: this.companyName,\r\n target: 'company',\r\n options: { companyId: this.companyId }\r\n });\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n this.isInitialized = true;\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Company Name',\r\n field: 'companyName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const allocation = params.data as Compliance.AllocationModel;\r\n if (!allocation) {\r\n return '';\r\n }\r\n return `#/company/${allocation.companyId}`;\r\n }\r\n } as AgGridLinkCellRendererParams\r\n },\r\n {\r\n headerName: 'Tax Year',\r\n field: 'taxYear',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.numericColumnWidth\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'stateAbbr',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.stateAbbreviationColumnWidth\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const allocation = params.data as Compliance.AllocationModel;\r\n if (!allocation) {\r\n return '';\r\n }\r\n return `#/site/${allocation.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Site Number',\r\n field: 'siteProperty',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const allocation = params.data as Compliance.AllocationModel;\r\n if (!allocation) {\r\n return '';\r\n }\r\n return `#/site/${allocation.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(4),\r\n minWidth: AgGridColumns.getActionColumnWidth(4),\r\n maxWidth: AgGridColumns.getActionColumnWidth(4),\r\n lockPinned: true,\r\n suppressColumnsToolPanel: true,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n sortable: false,\r\n cellRendererFramework: AllocationListGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n viewDetails: this._allocationSelected.bind(this),\r\n delete: this._delete.bind(this),\r\n canDelete: this._canDelete.bind(this),\r\n canEdit: this.canEdit\r\n } as ICellRendererParamsForAllocationListGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'dueDate',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n\r\n this._setDataSource();\r\n }\r\n\r\n async addNew(): Promise {\r\n const params: AddAllocationModalParams = {\r\n companyId: this.companyId\r\n };\r\n\r\n const result = await this._modalService.showAsync(AddAllocationModalComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this._navigateToDetail(result.allocationId);\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n refresh(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n onIncludeCompletedChange(): void {\r\n this._refreshDataSource();\r\n }\r\n\r\n navigateToUnauthorized(): void {\r\n this._routerService.go('unauthorizedAccess', {});\r\n }\r\n\r\n private _allocationSelected(row: ICellRendererParamsForAllocationListGridAction): void {\r\n const allocation = row.data as Compliance.AllocationModel;\r\n this._navigateToDetail(allocation.allocationId);\r\n }\r\n\r\n private _navigateToDetail(allocationId: number): void {\r\n this._routerService.go('allocationDetails', { allocationId });\r\n }\r\n\r\n private _canDelete(params: ICellRendererParamsForAllocationListGridAction): boolean {\r\n const allocation = params.data as Compliance.AllocationModel;\r\n if (!allocation) {\r\n return false;\r\n }\r\n\r\n return this.canEdit; // TODO && check if allocation not complete\r\n }\r\n\r\n private async _delete(params: ICellRendererParamsForAllocationListGridAction): Promise {\r\n const allocation = params.data as Compliance.AllocationModel;\r\n if (!allocation) {\r\n return Promise.resolve();\r\n }\r\n\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to delete the allocation?',\r\n 'Confirm'\r\n );\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Deleting' });\r\n try {\r\n await lastValueFrom(this._allocationRepository.delete(allocation.allocationId));\r\n this._refreshDataSource();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n private _refreshDataSource(): void {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const dataSourceParams = (): AllocationListDataSourceParams => {\r\n return {\r\n includeCompleted: this.includeCompleted,\r\n companyId: this.companyId\r\n };\r\n };\r\n\r\n this._gridDataSource = new AllocationListAgGridDataSource(this._gridApi, this._allocationRepository, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n}\r\n","import { ReactiveFormsModule } from '@angular/forms';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ScrollingModule } from '@angular/cdk/scrolling';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { CurrencyMaskModule } from 'ng2-currency-mask';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { AgGridExtensionsModule } from '../AgGrid/agGridExtensions.module';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer } from '../AgGrid/MultiSelectTracker';\r\nimport { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { AllocationDetailsComponent } from './Allocation-Details/allocationDetails.component';\r\nimport { AllocationListComponent } from './Allocation-List/allocationList.component';\r\nimport { AllocationListGridActionCellRendererComponent } from './Allocation-List/agGridActionCellRenderer.component';\r\nimport { AllocationRepository } from '../Repositories';\r\nimport { AllocationService } from './allocation.service';\r\nimport { AddAllocationModalComponent } from './Allocation-List/Add-Allocation/addAllocationModal.component';\r\nimport { AllocationDetailRepository } from '../Repositories/allocationDetail.repository';\r\nimport { ComplianceParcelModule } from '../Parcel/parcel.module';\r\nimport { AllocationDetailDragAndDropSourceComponent } from './Allocation-Details/Drag-And-Drop/allocationDetailDragAndDropSource.component';\r\nimport { AllocationDetailDragAndDropTargetComponent } from './Allocation-Details/Drag-And-Drop/allocationDetailDragAndDropTarget.component';\r\nimport { DragulaModule } from 'ng2-dragula';\r\nimport { AllocationDetailDragAndDropService } from './Allocation-Details/Drag-And-Drop/allocationDetailDragAndDrop.service';\r\nimport { AllocationDetailsService } from './Allocation-Details/allocationDetails.service';\r\nimport { AddTaxAuthorityComponent } from './Allocation-Details/Add-Tax-Authority/addTaxAuthority.component';\r\nimport { AllocationDetailBulkUpdateActionComponent } from './Allocation-Details/Allocation-Detail-Bulk-Update/allocationDetailBulkUpdateAction.component';\r\nimport { AllocationDetailBulkUpdateComponent } from './Allocation-Details/Allocation-Detail-Bulk-Update/allocationDetailBulkUpdate.component';\r\nimport { AllocationAssessmentSummaryComponentComponent } from './Allocation-Details/Allocation-Assessment-Summary/allocationAssessmentSummaryComponent.component';\r\nimport { CreateNewMergedParcelsComponent } from './Allocation-Details/Create-New-Merged-Parcels/create-new-merged-parcels.component';\r\nimport { AllocationDetailListGridActionCellRendererComponent } from './Allocation-Details/agGridActionCellRenderer.component';\r\nimport { AllocationDetailDragAndDropCellRendererComponent } from './Allocation-Details/Drag-And-Drop/allocationDetailDragAndDropCellRenderer.component';\r\nimport { AgGridAssessmentSummaryActionCellRendererComponent } from './Allocation-Details/agGridAssessmentSummaryActionCellRenderer.component';\r\nimport { AgGridAssessmentSummaryActionHeaderRendererComponent } from './Allocation-Details/agGridAssessmentSummaryActionHeaderRenderer.component';\r\nimport { CommentsModule } from '../../Comments/comments.module';\r\nimport { RetrieveAssetsComponent } from './Allocation-Details/Retrieve-Assets/retrieveAssets.component';\r\nimport {\r\n AssetsInAnotherAllocationsComponent\r\n} from './Allocation-Details/Assets-In-Another-Allocations/assetsInAnotherAllocations.component';\r\nimport { SelectTaxAuthorityComponent } from './Allocation-Details/Select-Tax-Authority/selectTaxAuthority.component';\r\n\r\n@NgModule({\r\n imports: [\r\n ReactiveFormsModule,\r\n CommonModule,\r\n TypeaheadModule,\r\n TooltipModule,\r\n BsDropdownModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n CurrencyMaskModule,\r\n ComplianceParcelModule,\r\n BusyIndicatorModule.forRoot(),\r\n DragulaModule,\r\n ScrollingModule,\r\n AgGridExtensionsModule,\r\n CommentsModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectedCellRenderer\r\n ])\r\n ],\r\n declarations: [\r\n AllocationDetailsComponent,\r\n AllocationListComponent,\r\n AllocationListGridActionCellRendererComponent,\r\n AgGridAssessmentSummaryActionCellRendererComponent,\r\n AgGridAssessmentSummaryActionHeaderRendererComponent,\r\n AddAllocationModalComponent,\r\n AllocationDetailDragAndDropSourceComponent,\r\n AllocationDetailDragAndDropTargetComponent,\r\n AllocationDetailDragAndDropCellRendererComponent,\r\n AddTaxAuthorityComponent,\r\n AllocationDetailBulkUpdateActionComponent,\r\n AllocationDetailBulkUpdateComponent,\r\n AllocationAssessmentSummaryComponentComponent,\r\n CreateNewMergedParcelsComponent,\r\n AllocationDetailListGridActionCellRendererComponent,\r\n RetrieveAssetsComponent,\r\n AssetsInAnotherAllocationsComponent,\r\n SelectTaxAuthorityComponent\r\n ],\r\n providers: [\r\n AllocationService,\r\n AllocationRepository,\r\n AllocationDetailRepository,\r\n AllocationDetailDragAndDropService,\r\n AllocationDetailsService\r\n ]\r\n})\r\n\r\nexport class AllocationModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('allocationDetails', AllocationDetailsComponent);\r\n hybridAdapterUtility.downgradeNg2Component('allocationList', AllocationListComponent);\r\n }\r\n}\r\n","import { NgModule, ErrorHandler } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { ElectronicFilingModule } from './Electronic-Filing/electronicFiling.module';\r\nimport { EntityImportModule } from './Entity-Import/entityImport.module';\r\nimport { AssetModule } from './Asset/asset.module';\r\nimport { FormModule } from './Form/form.module';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridLoadingOverlayComponent } from '../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { FactorTableModule } from './Factor-Table/factorTable.module';\r\nimport { GLAccountModule } from './GL-Account/glAccount.module';\r\nimport { FilingBatchModule } from './Filing-Batch/filingBatch.module';\r\nimport { ReturnModule } from './Return/return.module';\r\nimport { SupplementalInformationModule } from './Supplemental-Information/supplementalInformation.module';\r\nimport { LongRunningProcessModule } from './Long-Running-Process/longRunningProcess.module';\r\nimport {\r\n EntityImportRepository,\r\n AssetRepository,\r\n CostAdjustmentRepository,\r\n AssetClassificationRepository,\r\n FactorTableRepository,\r\n FormRepository,\r\n GLAccountRepository,\r\n FilingBatchRepository,\r\n ReturnRepository,\r\n ReturnAssetRepository,\r\n ReturnFormRepository,\r\n ReturnFormRevisionRepository,\r\n SupplementalInformationRepository,\r\n ReturnFormRevisionReportRepository,\r\n ReturnReportRepository,\r\n ReturnSettingsRepository,\r\n GridLayoutSpecificationRepository,\r\n CompanyAssetDescriptorRepository,\r\n LongRunningProcessRepository,\r\n ReportingParcelRepository,\r\n ErrorLogRepository,\r\n QueryInfoRepository,\r\n ImportSpecificationRepository,\r\n CompanyRepository,\r\n IncomeStatementCategoryRepository,\r\n AssessorCommandCenterRepository\r\n} from './Repositories';\r\nimport { httpInterceptorProviders } from '../Common/Data/HttpInterceptors';\r\nimport { GlobalErrorHandler } from '../Common/ErrorHandler/globalErrorHandler';\r\nimport { LoggingService } from '../Common/Logging/logging.service';\r\nimport { AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectedCellRenderer } from './AgGrid/MultiSelectTracker';\r\nimport { WeissmanModalService} from './WeissmanModalService';\r\nimport { EntityPickerService } from './Entity-Picker/entityPicker.service';\r\nimport { EntityPickerComponent } from './Entity-Picker/entityPicker.component';\r\nimport { WeissmanMutexService } from './WeissmanMutexService';\r\nimport { ComplianceParcelModule } from './Parcel/parcel.module';\r\nimport { AgGridDateFilterComponent } from './AgGrid';\r\nimport { ComplianceCompanyModule } from './Company/company.module';\r\nimport { ComplianceInfoRepository } from './Repositories/complianceInfo.repository';\r\nimport { ComplianceSiteModule } from './Site/site.module';\r\nimport { ErrorLogModule } from '../Diagnostics/Error-Log/errorLog.module';\r\nimport { QueryInfoModule } from '../Diagnostics/Query-Info/queryInfo.module';\r\nimport { FormSetupRepository } from './Repositories';\r\nimport { StateJurisdictionModule } from './State-And-Jurisdiction/stateJurisdiction.module';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { AllocationModule } from './Allocation/allocation.module';\r\nimport { FormLibraryRepository } from './Repositories/formLibraryRepository';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n EntityImportModule,\r\n AssetModule,\r\n FactorTableModule,\r\n FormModule,\r\n GLAccountModule,\r\n FilingBatchModule,\r\n ReturnModule,\r\n ComplianceCompanyModule,\r\n ComplianceSiteModule,\r\n ComplianceParcelModule,\r\n StateJurisdictionModule,\r\n SupplementalInformationModule,\r\n LongRunningProcessModule,\r\n ErrorLogModule,\r\n QueryInfoModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n AgGridMultiSelectedHeaderRenderer,\r\n AgGridMultiSelectedCellRenderer,\r\n AgGridDateFilterComponent\r\n ]),\r\n AllocationModule,\r\n ElectronicFilingModule\r\n ],\r\n declarations: [\r\n EntityPickerComponent\r\n ],\r\n providers: [\r\n { provide: ErrorHandler, useClass: GlobalErrorHandler },\r\n httpInterceptorProviders,\r\n LoggingService,\r\n EntityImportRepository,\r\n ImportSpecificationRepository,\r\n AssetRepository,\r\n AssetClassificationRepository,\r\n CostAdjustmentRepository,\r\n FactorTableRepository,\r\n FormRepository,\r\n GLAccountRepository,\r\n FilingBatchRepository,\r\n ReturnRepository,\r\n ReturnAssetRepository,\r\n ReturnFormRepository,\r\n ReturnFormRevisionRepository,\r\n ReturnFormRevisionReportRepository,\r\n ReturnReportRepository,\r\n SupplementalInformationRepository,\r\n ReturnSettingsRepository,\r\n GridLayoutSpecificationRepository,\r\n WeissmanModalService,\r\n WeissmanMutexService,\r\n EntityPickerService,\r\n CompanyAssetDescriptorRepository,\r\n LongRunningProcessRepository,\r\n ErrorLogRepository,\r\n QueryInfoRepository,\r\n ReportingParcelRepository,\r\n ComplianceInfoRepository,\r\n FormSetupRepository,\r\n CompanyRepository,\r\n AssessorCommandCenterRepository,\r\n IncomeStatementCategoryRepository,\r\n FormLibraryRepository\r\n ],\r\n exports: []\r\n})\r\nexport class ComplianceModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n EntityImportModule.setupModule();\r\n AssetModule.setupModule();\r\n FactorTableModule.setupModule();\r\n FormModule.setupModule();\r\n GLAccountModule.setupModule();\r\n FilingBatchModule.setupModule();\r\n ReturnModule.setupModule();\r\n SupplementalInformationModule.setupModule();\r\n LongRunningProcessModule.setupModule();\r\n ErrorLogModule.setupModule();\r\n QueryInfoModule.setupModule();\r\n ComplianceParcelModule.setupModule();\r\n ComplianceCompanyModule.setupModule();\r\n ComplianceSiteModule.setupModule();\r\n StateJurisdictionModule.setupModule();\r\n hybridAdapterUtility.downgradeNg2Provider('longRunningProcessRepository', LongRunningProcessRepository);\r\n AllocationModule.setupModule();\r\n ElectronicFilingModule.setupModule();\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { SDHttpService } from '../Common/Routing/sd-http.service';\r\nimport { BuildTimestampService, UtilitiesService } from '../UI-Lib/Utilities';\r\nimport { TaskService } from '../Task/task.service.upgrade';\r\nimport { MessageBoxService } from '../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { ParcelActivityModalService } from '../Entity/Parcel/Info/Activity/parcel-activity-modal.service.upgrade';\r\nimport { UpgradeNavigationServiceHandler } from '../Common/Routing/upgrade-navigation-handler.service';\r\nimport { EventAdapterService } from '../Common/Services/event-adapter.service.upgrade';\r\nimport { ProcessingService } from '../Processing/processing.service.upgrade';\r\nimport { ActionViewPersistenceService } from '../Task/ActionView/Action.View.Persistence.Service.upgrade';\r\nimport { UserGroupService } from '../User-Group/user-group-service.upgrade';\r\nimport { AssessorService } from '../Assessor-Collector/Assessor/assessor-service';\r\nimport { ActionViewService} from '../Task/ActionView/action-view-service.upgrade';\r\nimport { AuthenticationService} from '../Account/authentication-service.upgrade';\r\nimport { PropertyTypeService } from '../Common/Services/propertyType.service.upgrade';\r\nimport { CollectorService } from '../Assessor-Collector/Collector/collector.service.upgrade';\r\nimport { DocumentServiceUpgrade } from '../Documents/document.service.upgrade';\r\nimport { ContactModalService } from '../Contact/contactModal.service';\r\nimport { ContactsRoleAssociationServiceUpgrade } from '../Contact/contactsRoleAssociation.service.upgrade';\r\nimport { StartupService } from './startup.service.upgrade';\r\n\r\n@NgModule({\r\n providers: [\r\n { provide: '$location', useFactory: (i: any) => i.get('$location'), deps: ['$injector'] },\r\n { provide: UtilitiesService, useFactory: (i: any) => i.get('utils'), deps: ['$injector'] },\r\n { provide: '$http', useFactory: (i: any) => i.get('$http'), deps: ['$injector'] },\r\n { provide: SDHttpService, useFactory: (i: any) => i.get('sd.Http.Service'), deps: ['$injector'] },\r\n { provide: TaskService, useFactory: (i: any) => i.get('taskService'), deps: ['$injector'] },\r\n { provide: ActionViewPersistenceService, useFactory: (i: any) => i.get('actionViewPersistenceService'), deps: ['$injector'] },\r\n { provide: MessageBoxService, useFactory: (i: any) => i.get('messageBoxService'), deps: ['$injector'] },\r\n { provide: ParcelActivityModalService, useFactory: (i: any) => i.get('ParcelActivityModalService'), deps: ['$injector'] },\r\n { provide: UpgradeNavigationServiceHandler, useFactory: (i: any) => i.get('UpgradeNavigationServiceHandler'), deps: ['$injector'] },\r\n { provide: EventAdapterService, useFactory: (i: any) => i.get('eventAdapterService'), deps: ['$injector'] },\r\n { provide: ProcessingService, useFactory: (i: any) => i.get('processingService'), deps: ['$injector'] },\r\n { provide: BuildTimestampService, useFactory: (i: any) => i.get('BuildTimestampService'), deps: ['$injector'] },\r\n { provide: PropertyTypeService, useFactory: (i: any) => i.get('sd.Property.Type.Service'), deps: ['$injector'] },\r\n { provide: CollectorService, useFactory: (i: any) => i.get('CollectorService'), deps: ['$injector'] },\r\n { provide: UserGroupService, useFactory: (i: any) => i.get('sd.User.Group.Service'), deps: ['$injector'] },\r\n { provide: AssessorService, useFactory: (i: any) => i.get('sd.Assessor.Service'), deps: ['$injector'] },\r\n { provide: ActionViewService, useFactory: (i: any) => i.get('actionViewService'), deps: ['$injector'] },\r\n { provide: AuthenticationService, useFactory: (i: any) => i.get('sd.Authentication.Service'), deps: ['$injector'] },\r\n { provide: '$rootScope', useFactory: (i: any) => i.get('$rootScope'), deps: ['$injector'] },\r\n { provide: '$location', useFactory: (i: any) => i.get('$location'), deps: ['$injector'] },\r\n { provide: DocumentServiceUpgrade, useFactory: (i: any) => i.get('DocumentService'), deps: ['$injector'] },\r\n { provide: ContactModalService, useFactory: (i: any) => i.get('sd.Contacts.Service.old'), deps: ['$injector'] },\r\n { provide: ContactsRoleAssociationServiceUpgrade, useFactory: (i: any) => i.get('ContactRoleAssociationService'), deps: ['$injector'] },\r\n { provide: StartupService, useFactory: (i: any) => i.get('StartupService'), deps: ['$injector'] },\r\n { provide: 'routes', useFactory: (i: any) => i.get('routes'), deps: ['$injector'] },\r\n ]\r\n})\r\nexport class Ng1UpgradeModule {\r\n}\r\n","
\r\n \r\n
\r\n \r\n \r\n

\r\n Account number is required\r\n

\r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","// AngularJS events have other members, but we're not using event results at this time,\r\n// so for now just including the obvious parts\r\nexport interface Event {\r\n name: string;\r\n defaultPrevented: boolean;\r\n preventDefault(): void;\r\n}\r\n\r\nexport abstract class EventAdapterService {\r\n abstract broadcast(name: string, ...args: any[]): Event;\r\n}","export abstract class ContactsRoleAssociationServiceUpgrade {\r\n abstract openContactAssociationModal(params: any): Promise;\r\n}\r\n","export abstract class StartupService {\r\n abstract initializeNavService(): void;\r\n}\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { UntypedFormGroup, UntypedFormControl, Validators } from '@angular/forms';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { TypeaheadMatch } from 'ngx-bootstrap/typeahead';\r\nimport { AssessorService } from '../../../../Assessor-Collector/Assessor/assessor-service';\r\nimport { ActivityService } from '../../../../Common/Activity/activity.service';\r\nimport { PropertyTypeService } from '../../../../Common/Services/propertyType.service.upgrade';\r\nimport { AssessorSummary } from '../../Site.Model';\r\nimport { Subscription } from 'rxjs';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { MessageBoxService, MessageBoxButtons } from '../../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { SiteService } from '../../Site.Service.upgrade';\r\nimport * as _ from 'lodash';\r\nimport { BusyIndicatorService } from '../../../../Busy-Indicator';\r\nimport { ClientServiceResponsibilityService } from '../../../../Client-Services/clientServiceResponsibility.service';\r\nimport { EntityTypeIds } from '../../../../constants.new';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\nexport interface AddParcelModalParams {\r\n siteId: number;\r\n siteAddress: Weissman.Model.Misc.Address;\r\n stateId: number;\r\n stateName: string;\r\n siteAssessor: AssessorSummary;\r\n masterParcel: Core.ParcelTileDTO;\r\n}\r\n\r\n@Component({\r\n selector: 'add-parcel-modal',\r\n templateUrl: './addParcelModal.component.html'\r\n})\r\nexport class AddParcelModalComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _assessorService: AssessorService,\r\n private readonly _propertyTypeService: PropertyTypeService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _siteService: SiteService,\r\n private readonly _toastrService: ToastrService,\r\n private readonly _clientServiceResponsibilityService: ClientServiceResponsibilityService,\r\n private readonly _activityService: ActivityService\r\n ) { }\r\n\r\n params: AddParcelModalParams;\r\n result: Core.ParcelTileDTO;\r\n\r\n parcelForm: UntypedFormGroup;\r\n propertyTypes: Core.PropertyTypeModel[] = [];\r\n assessors: Core.AssessorModel[] = [];\r\n selectedAssessor: UntypedFormControl = new UntypedFormControl('');\r\n masterParcel: Core.ParcelTileDTO;\r\n canLinkMaster: boolean = true;\r\n\r\n private _formSub: Subscription;\r\n private _validPropertyTypes: Core.ClientServiceResponsibilitiesPropertyTypesResult;\r\n\r\n async ngOnInit(): Promise {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Loading' });\r\n\r\n try {\r\n this.masterParcel = this.params.masterParcel;\r\n\r\n this.parcelForm = new UntypedFormGroup({\r\n acctNum: new UntypedFormControl('', Validators.required),\r\n propertyTypeID: new UntypedFormControl(null, Validators.required),\r\n state: new UntypedFormControl({ value: this.params.stateName, disabled: true }),\r\n assessorID: new UntypedFormControl('', Validators.required),\r\n useSiteAddress: new UntypedFormControl(true),\r\n linkMasterParcel: new UntypedFormControl(!!this.masterParcel)\r\n });\r\n\r\n this.propertyTypes = await this._propertyTypeService.get();\r\n\r\n this.assessors = await this._assessorService.getByStateId(this.params.stateId);\r\n this._setDefaultAssessor();\r\n\r\n this._validPropertyTypes = await this._clientServiceResponsibilityService.getTopLevelPropertyTypes(this.params.siteId, EntityTypeIds.SITE);\r\n\r\n this._formSub = this.parcelForm.get('propertyTypeID').valueChanges.subscribe(id => {\r\n if (this.masterParcel) {\r\n this.canLinkMaster = !(id === 1 && this.masterParcel.linkageTypeId === 5); //todo: there is no linkage type id 5; use Core.LinkageType enum\r\n this.parcelForm.get('linkMasterParcel').setValue(this.canLinkMaster);\r\n }\r\n });\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._formSub && this._formSub.unsubscribe();\r\n }\r\n\r\n async addParcel(): Promise {\r\n const isParcelAcctNumNonAscii = this.parcelForm.value.acctNum && !(/^[ -~\\t\\n\\r]+$/.test(this.parcelForm.value.acctNum));\r\n if (isParcelAcctNumNonAscii) {\r\n this._toastrService.error('Parcel Acct Num contains invalid character(s)');\r\n return Promise.resolve();\r\n }\r\n\r\n if (! _.some(this._validPropertyTypes.propertyTypes, { id: this.parcelForm.value.propertyTypeID })) {\r\n await this._messageBoxService.open({\r\n message: 'Parcel cannot be added. The selected property type has not been configured for this site.',\r\n buttons: MessageBoxButtons.OK\r\n });\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n const address: Core.AddressModel = (this.parcelForm.value.useSiteAddress)\r\n ? { ...this.params.siteAddress, ...{ addressID: 0 } }\r\n : {\r\n addressID: 0,\r\n address1: null,\r\n address2: null,\r\n city: null,\r\n email: null,\r\n ext: null,\r\n fax: null,\r\n mobilePhone: null,\r\n phone: null,\r\n rowVersion: null,\r\n state: null,\r\n stateID: this.params.stateId,\r\n url: null,\r\n zip: null\r\n };\r\n\r\n const request: Core.ParcelModel = {\r\n siteID: this.params.siteId,\r\n acctNum: this.parcelForm.value.acctNum,\r\n address,\r\n addressID: (this.parcelForm.value.useSiteAddress) ? 0 : null,\r\n activityStatusID: Core.ActivityStatuses.Active,\r\n assessorID: this.parcelForm.value.assessorID,\r\n propertyTypeID: this.parcelForm.value.propertyTypeID,\r\n assessor: null,\r\n description: null,\r\n parcelID: 0,\r\n parcelLinkageID: (this.params.masterParcel && this.parcelForm.value.linkMasterParcel) ? this.params.masterParcel.parcelLinkageId : null\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Adding Parcel' });\r\n\r\n try {\r\n this.result = await this._siteService.post(request);\r\n\r\n this._activityService.clearParcelFilterCacheForSite(this.params.siteId);\r\n this._bsModalRef.hide();\r\n } finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n onAssessorSelected(match: TypeaheadMatch): void {\r\n const assessor = match.item as Core.AssessorModel;\r\n this.parcelForm.patchValue({\r\n assessorID: assessor.assessorID\r\n });\r\n }\r\n\r\n onAssessorBlur(): void {\r\n const assessorName = this.selectedAssessor.value as string;\r\n const assessor = this.assessors.find(a => a.name.toLowerCase() === assessorName.toLowerCase()) as Core.AssessorModel;\r\n if (assessor) {\r\n this.selectedAssessor.setValue(assessor.name);\r\n }\r\n this.parcelForm.patchValue({\r\n assessorID: (assessor && assessor.assessorID) ? assessor.assessorID : null\r\n });\r\n }\r\n\r\n private _setDefaultAssessor(): void {\r\n if (this.params.siteAssessor) {\r\n const assessor = this.assessors.find(a => a.assessorID === this.params.siteAssessor.assessorID);\r\n if (assessor) {\r\n this.parcelForm.get('assessorID').setValue(assessor.assessorID);\r\n this.selectedAssessor.setValue(assessor.name);\r\n }\r\n }\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const PARCEL_LIST_PANEL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'parcel-list-panel.view-switch',\r\n tooltipText: 'Toggle between tile and list view'\r\n },\r\n {\r\n helpContentId: 'parcel-list-panel.add',\r\n tooltipText: 'Add'\r\n },\r\n {\r\n helpContentId: 'parcel-list-panel.set-reporting',\r\n tooltipText: 'Set as site\\'s default parcel for compliance assets'\r\n },\r\n {\r\n helpContentId: 'parcel-list-panel.remove-reporting',\r\n tooltipText: 'Remove as site\\'s default parcel for compliance assets'\r\n },\r\n {\r\n helpContentId: 'parcel-list-panel.set-site-consolidated',\r\n tooltipText: 'Set as the site-consolidated parcel for compliance returns'\r\n },\r\n {\r\n helpContentId: 'parcel-list-panel.set-state-consolidated',\r\n tooltipText: 'Set as the state-consolidated parcel for compliance returns'\r\n },\r\n {\r\n helpContentId: 'parcel-list-panel.remove-site-consolidated',\r\n tooltipText: 'Remove as site-consolidated parcel for compliance returns'\r\n },\r\n {\r\n helpContentId: 'parcel-list-panel.remove-state-consolidated',\r\n tooltipText: 'Remove as state-consolidated parcel for compliance returns'\r\n },\r\n {\r\n helpContentId: 'parcel-list-panel.opt-out-consolidated',\r\n tooltipText: 'Opt out of consolidation for compliance returns'\r\n },\r\n {\r\n helpContentId: 'parcel-list-panel.opt-in-consolidated',\r\n tooltipText: 'Set as merged parcel for compliance returns'\r\n }\r\n];\r\n","import { HelpContent } from '../../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const PARCEL_BULK_UPDATE_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'parcel-bulk-update.header',\r\n tooltipText: 'Bulk Update',\r\n hasIcon: true\r\n }\r\n];\r\n","\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'parcel-bulk-update-action',\r\n templateUrl: './parcelBulkUpdateAction.component.html',\r\n styles: ['select {width:120px}']\r\n})\r\nexport class ParcelBulkUpdateActionComponent {\r\n constructor(\r\n ){\r\n this.possibleActions = [\r\n { name: 'No Change', value: Core.ParcelBulkUpdateFieldActionEnum.NoChange },\r\n { name: 'Change To', value: Core.ParcelBulkUpdateFieldActionEnum.ChangeTo }\r\n ];\r\n }\r\n\r\n @Input()\r\n set fieldAction(fieldAction: Core.ParcelBulkUpdateFieldActionEnum) {\r\n this.fieldActionChanged(fieldAction);\r\n }\r\n\r\n @Output() fieldActionChange = new EventEmitter();\r\n @Input() disabled: boolean;\r\n\r\n action: Core.ParcelBulkUpdateFieldActionEnum;\r\n possibleActions: Compliance.NameValuePair[];\r\n selectedAction: Core.ParcelBulkUpdateFieldActionEnum = Core.ParcelBulkUpdateFieldActionEnum.NoChange;\r\n\r\n public fieldActionChanged(action: Core.ParcelBulkUpdateFieldActionEnum): void {\r\n if (action || action === Core.ParcelBulkUpdateFieldActionEnum.NoChange) {\r\n this.selectedAction = action;\r\n this.fieldActionChange.next(action);\r\n } else {\r\n this.selectedAction = Core.ParcelBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n }\r\n\r\n isSelected(action: Core.ParcelBulkUpdateFieldActionEnum): boolean{\r\n return action === Core.ParcelBulkUpdateFieldActionEnum.NoChange;\r\n }\r\n}\r\n","\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Consolidation\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n

{{ validationMessage }}

\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, OnInit, ViewEncapsulation, OnDestroy } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { Subject } from 'rxjs';\r\nimport { HelpService } from '../../../../UI-Lib/Help-Tooltip';\r\nimport { IWeissmanModalComponent } from '../../../../Compliance/WeissmanModalService';\r\nimport { PARCEL_BULK_UPDATE_HELP } from './parcelBulkUpdate.component.help';\r\n\r\nexport interface ParcelBulkUpdateParams {\r\n selectedRows: Compliance.SelectedRowsModel;\r\n siteId: number;\r\n stateAllowConsolidating: boolean;\r\n isConsolidatedParcelSelected: boolean;\r\n isNonPPParcelsSelected: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'parcel-bulk-update',\r\n templateUrl: './parcelBulkUpdate.component.html',\r\n styleUrls: ['./parcelBulkUpdate.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ParcelBulkUpdateComponent implements OnInit, OnDestroy, IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _helpService: HelpService) { }\r\n\r\n params: ParcelBulkUpdateParams;\r\n result: Core.ParcelBulkUpdateModel;\r\n\r\n validationMessage: string = '';\r\n isFormValid: boolean = false;\r\n\r\n consolidatingTypes: Compliance.NameValuePair[] = [\r\n {\r\n name: 'Merged parcel',\r\n value: null\r\n },\r\n {\r\n name: 'Opt out of consolidation',\r\n value: Core.ConsolidatingTypeEnum.None\r\n }];\r\n\r\n consolidatingType: Core.ConsolidatingTypeEnum = null;\r\n consolidatingTypeAction: Core.ParcelBulkUpdateFieldActionEnum = Core.ParcelBulkUpdateFieldActionEnum.NoChange;\r\n\r\n private _destroy$: Subject = new Subject();\r\n\r\n\r\n ngOnInit(): void {\r\n this._helpService.setContent(PARCEL_BULK_UPDATE_HELP);\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n isDisabled(action: Core.ParcelBulkUpdateFieldActionEnum): boolean {\r\n return action !== Core.ParcelBulkUpdateFieldActionEnum.ChangeTo;\r\n }\r\n\r\n validateForm(): void {\r\n this.validationMessage = '';\r\n this.isFormValid = false;\r\n\r\n if (this.consolidatingTypeAction === Core.ParcelBulkUpdateFieldActionEnum.ChangeTo && this.params.isConsolidatedParcelSelected) {\r\n this.validationMessage = 'The consolidated parcel cannot be updated.';\r\n this.isFormValid = false;\r\n return;\r\n }\r\n\r\n if (this.consolidatingTypeAction === Core.ParcelBulkUpdateFieldActionEnum.ChangeTo && this.params.isNonPPParcelsSelected) {\r\n this.validationMessage = 'Only PP parcels can be updated.';\r\n this.isFormValid = false;\r\n return;\r\n }\r\n\r\n this.isFormValid = this.consolidatingTypeAction === Core.ParcelBulkUpdateFieldActionEnum.ChangeTo;\r\n }\r\n\r\n async save(): Promise {\r\n const bulkUpdateModel: Core.ParcelBulkUpdateModel = {\r\n siteId: this.params.siteId,\r\n force: false,\r\n reportingParcelAction: Core.ParcelBulkUpdateFieldActionEnum.NoChange,\r\n reportingParcelId: null,\r\n consolidatedParcelAction: Core.ParcelBulkUpdateFieldActionEnum.NoChange,\r\n consolidatedParcelId: null,\r\n optInParcelsAction: Core.ParcelBulkUpdateFieldActionEnum.NoChange,\r\n optInParcels: [],\r\n optOutParcelsAction: Core.ParcelBulkUpdateFieldActionEnum.NoChange,\r\n optOutParcels: []\r\n };\r\n\r\n if (this.consolidatingType === Core.ConsolidatingTypeEnum.None) {\r\n bulkUpdateModel.optOutParcelsAction = Core.ParcelBulkUpdateFieldActionEnum.ChangeTo;\r\n bulkUpdateModel.optOutParcels = this.params.selectedRows.selectedRows;\r\n }\r\n\r\n if (!this.consolidatingType) {\r\n bulkUpdateModel.optInParcelsAction = Core.ParcelBulkUpdateFieldActionEnum.ChangeTo;\r\n bulkUpdateModel.optInParcels = this.params.selectedRows.selectedRows;\r\n }\r\n\r\n this.result = bulkUpdateModel;\r\n\r\n this._bsModalRef.hide();\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface ParcelListActionCellRendererParams extends ICellRendererParams {\r\n canSetReporting: (params: ParcelListActionCellRendererParams) => boolean;\r\n setReporting: (params: ParcelListActionCellRendererParams) => void;\r\n canRemoveReporting: (params: ParcelListActionCellRendererParams) => boolean;\r\n removeReporting: (params: ParcelListActionCellRendererParams) => void;\r\n canSetConsolidated: (params: ParcelListActionCellRendererParams) => boolean;\r\n setConsolidated: (params: ParcelListActionCellRendererParams) => void;\r\n canRemoveConsolidated: (params: ParcelListActionCellRendererParams) => boolean;\r\n removeConsolidated: (params: ParcelListActionCellRendererParams) => void;\r\n canOptOutConsolidated: (params: ParcelListActionCellRendererParams) => boolean;\r\n optOutConsolidated: (params: ParcelListActionCellRendererParams) => void;\r\n canOptInConsolidated: (params: ParcelListActionCellRendererParams) => boolean;\r\n optInConsolidated: (params: ParcelListActionCellRendererParams) => void;\r\n stateAllowConsolidating: (params: ParcelListActionCellRendererParams) => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template:\r\n `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class ParcelListActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ParcelListActionCellRendererParams;\r\n\r\n agInit(params: ParcelListActionCellRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface PercentChangeRendererParams extends ICellRendererParams {\r\n getPercentage: (params: PercentChangeRendererParams) => number;\r\n}\r\n\r\n@Component({\r\n selector: 'percentage-change-renderer',\r\n template: ` 0, 'decrease': diff < 0 }\">\r\n\t\t\t\t\t 0, 'fa-arrow-down': diff < 0 }\"> {{diff | percent: '1.3'}}`\r\n})\r\nexport class PercentChangeRendererComponent implements ICellRendererAngularComp {\r\n\r\n params: PercentChangeRendererParams;\r\n\r\n agInit(params: PercentChangeRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n get diff(): number {\r\n return this.params.getPercentage(this.params);\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface FMVChangeRendererParams extends ICellRendererParams {\r\n getText: (params: FMVChangeRendererParams) => number;\r\n}\r\n\r\n@Component({\r\n selector: 'fmv-change-renderer',\r\n template: ` 0, 'decrease': change < 0 }\">\r\n\t\t\t\t\t 0, 'fa-arrow-down': change < 0 }\"> {{change | number}}`\r\n})\r\nexport class FMVChangeRendererComponent implements ICellRendererAngularComp {\r\n\r\n params: FMVChangeRendererParams;\r\n\r\n agInit(params: FMVChangeRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n get change(): number {\r\n return this.params.getText(this.params);\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\n\r\nexport interface TotalFMVRendererParams extends ICellRendererParams {\r\n activityStatusId: (params: TotalFMVRendererParams) => number;\r\n isFmvInclude: (params: TotalFMVRendererParams) => boolean;\r\n getTotal: (params: TotalFMVRendererParams) => string;\r\n}\r\n\r\n\r\n@Component({\r\n selector: 'total-fmv-renderer',\r\n template: `\"Inactive\"\r\n \"Inactive\"\r\n \r\n Σ\r\n \r\n \r\n {{total}}`\r\n})\r\nexport class TotalFMVRendererComponent implements ICellRendererAngularComp {\r\n\r\n params: TotalFMVRendererParams;\r\n\r\n agInit(params: TotalFMVRendererParams): void {\r\n this.params = params;\r\n }\r\n\r\n get activityStatusId(): number {\r\n return this.params.activityStatusId(this.params);\r\n }\r\n\r\n get isFmvInclude(): boolean {\r\n return this.params.isFmvInclude(this.params);\r\n }\r\n\r\n get total(): string {\r\n return this.params.getTotal(this.params);\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class EntityService {\r\n\r\n private LATEST: string = 'Latest';\r\n\r\n private _currentSiteId: number;\r\n\r\n private _parcelListDisplayStateSubject: BehaviorSubject = new BehaviorSubject(false);\r\n private _parcelListTaxYearSubject: BehaviorSubject = new BehaviorSubject(this.LATEST);\r\n private _parcelListScrollIndex: BehaviorSubject = new BehaviorSubject(null);\r\n\r\n parcelListDisplayState$: Observable = this._parcelListDisplayStateSubject.asObservable();\r\n parcelListTaxYear$: Observable = this._parcelListTaxYearSubject.asObservable();\r\n parcelListScrollIndex$: Observable = this._parcelListScrollIndex.asObservable();\r\n\r\n set currentSiteId(id: number) { this._currentSiteId = id; }\r\n\r\n get currentSiteId(): number { return this._currentSiteId; }\r\n\r\n get editGroup(): string {\r\n return 'site';\r\n }\r\n\r\n reset(): void {\r\n this._parcelListDisplayStateSubject.next(false);\r\n this._parcelListTaxYearSubject.next(this.LATEST);\r\n this._parcelListScrollIndex.next(null);\r\n }\r\n\r\n setParcelListScrollIndex(index: number): void {\r\n this._parcelListScrollIndex.next(index);\r\n }\r\n\r\n changeParcelListDisplayState(toggleValue: boolean): void {\r\n if (this._parcelListDisplayStateSubject.getValue() !== toggleValue) {\r\n this._parcelListDisplayStateSubject.next(toggleValue);\r\n }\r\n }\r\n\r\n changeParcelListTaxYear(taxYear: string): void {\r\n if (this._parcelListTaxYearSubject.getValue() !== taxYear) {\r\n this._parcelListTaxYearSubject.next(taxYear);\r\n }\r\n }\r\n}\r\n","
\r\n
\r\n\r\n \"Inactive\"\r\n
\r\n \r\n \r\n
\r\n = 20) }\">{{item.acctNum}}\r\n
\r\n
\r\n {{item.annualYear}}\r\n
\r\n
\r\n
{{item.description || 'dummy'}}
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n Total FMV:\r\n \r\n Σ\r\n \r\n \r\n {{(item.consolidatingTypeId !== 2 ? (item.totalFMV | number: '1.0-0') : 'N/A')}}\r\n 0, 'decrease': item.fmvChange < 0 }\">\r\n 0, 'fa-arrow-down': item.fmvChange < 0 }\"> {{item.fmvChange | number}}\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
{{component.componentName}}:{{component.fairMarketValue | number}}
\r\n
\r\n
Taxes:${{item.totalTaxes | number: '1.2'}}N/A\r\n 0, 'decrease': item.taxPercentDiff < 0 }\">\r\n 0, 'fa-arrow-down': item.taxPercentDiff < 0 }\"> {{item.taxPercentDiff | percent: '1.3'}}\r\n \r\n
This site's assets are reported on a parcel under another site. Click here to navigate to the reporting parcel.
\r\n
\r\n
\r\n
\r\n","import { Component, Input, Output, EventEmitter } from '@angular/core';\r\n\r\ninterface ParcelTileDTO extends Core.ParcelTileDTO {\r\n isExternalReportingParcel?: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'parcel-tile',\r\n templateUrl: './parcelTile.component.html',\r\n styleUrls: ['./parcelTile.component.scss']\r\n})\r\nexport class ParcelTileComponent {\r\n @Input() item: ParcelTileDTO;\r\n @Input() stateAllowConsolidating: boolean;\r\n @Input() ppReturnPreparationAllowed: boolean;\r\n @Output() navigateToParcel: EventEmitter = new EventEmitter();\r\n}\r\n","
\r\n
\r\n

Parcel List

\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Input, ViewEncapsulation, OnDestroy } from '@angular/core';\r\nimport { UntypedFormControl } from '@angular/forms';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { ProductAnalyticsService } from '../../../Common/Amplitude/productAnalytics.service';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { AddParcelModalComponent, AddParcelModalParams } from './Add-Parcel-Modal/addParcelModal.component';\r\nimport { ColDef, GridReadyEvent, GridApi, ColumnApi, FilterChangedEvent, RowNode, RowClickedEvent, ICellRendererParams } from 'ag-grid-community';\r\nimport { AgGridFilterParams, AgGridOptionsBuilder, AgGridColumns } from '../../../Compliance/AgGrid';\r\nimport { ParcelService } from '../../Parcel/parcel.service.upgrade';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { Subject, BehaviorSubject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { StateService } from '../../../Common/States/States.Service';\r\nimport { Site, AssessorSummary } from '../Site.Model';\r\nimport { BusyIndicatorMessageManager } from '../../../Busy-Indicator';\r\nimport { SiteService } from '../Site.Service.upgrade';\r\nimport { BaseExpandableComponent } from '../../../UI-Lib/Expandable-Component/baseExpandableComponent';\r\nimport { ParcelListControlRow, ParcelList } from '../Models/parcelList';\r\nimport { EntityService } from '../../entity.service';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { PARCEL_LIST_PANEL_HELP } from './parcelListPanel.component.help';\r\nimport { AgGridMultiSelectTracker, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectRendererParams, AgGridMultiSelectedCellRenderer } from '../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { ParcelBulkUpdateParams, ParcelBulkUpdateComponent } from './Parcel-Bulk-Update/parcelBulkUpdate.component';\r\nimport { WeissmanMutexService, IMutexServiceHandler } from '../../../Compliance/WeissmanMutexService';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { ParcelListActionCellRendererParams, ParcelListActionCellRendererComponent } from './agGridActionCellRenderer.component';\r\nimport { ParcelTypeCellRendererComponentParams, ParcelTypeCellRendererComponent } from '../../Parcel/Parcel-Type-Cell-Renderer/parcelTypeCellRenderer.component';\r\nimport { PercentChangeRendererParams, PercentChangeRendererComponent } from './agGridPercentChangeRenderer.component';\r\nimport { FMVChangeRendererParams, FMVChangeRendererComponent } from './agGridFMVChangeRenderer.component';\r\nimport { TotalFMVRendererParams, TotalFMVRendererComponent } from './agGridFMVRenderer.component';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { TimerService } from '../../../UI-Lib/Utilities/timer.service';\r\nimport ActivityStatuses = Core.ActivityStatuses;\r\n\r\n@Component({\r\n selector: 'parcel-list-panel',\r\n templateUrl: './parcelListPanel.component.html',\r\n styleUrls: ['./parcelListPanel.component.scss'],\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class ParcelListPanelComponent extends BaseExpandableComponent implements OnInit, OnDestroy, IMutexServiceHandler {\r\n constructor(\r\n private readonly _decimalPipe: DecimalPipe,\r\n private readonly _entityService: EntityService,\r\n private readonly _siteService: SiteService,\r\n private readonly _mutexService: WeissmanMutexService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _parcelService: ParcelService,\r\n private readonly _stateService: StateService,\r\n private readonly _toastrService: ToastrService,\r\n private readonly _helpService: HelpService,\r\n private readonly _timer: TimerService,\r\n private readonly _productAnalyticsService: ProductAnalyticsService) {\r\n super(_siteService, 'form-parcel-list');\r\n }\r\n\r\n @Input() site: Site;\r\n @Input() hasSiteWritePermission: boolean = false;\r\n @Input() parcelYears: number[];\r\n\r\n //Passed functions to communicate with angularjs parent\r\n @Input() maximize: (panelName: string) => void;\r\n @Input() minimize: () => void;\r\n\r\n editMode: boolean = false;\r\n hasChanges: boolean = false;\r\n dataLoading: boolean = false;\r\n isExcludeInactiveParcelsCheckboxVisible: boolean;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n contentTypeToggle: UntypedFormControl = new UntypedFormControl(false);\r\n excludeInactive: boolean;\r\n excludeInactiveParcels: UntypedFormControl = new UntypedFormControl(false);\r\n\r\n latestTaxYearLabel: string = 'Latest';\r\n taxYear: string;\r\n availableTaxYears: (number | string)[] = [];\r\n selectedTaxYear: UntypedFormControl = new UntypedFormControl();\r\n\r\n parcelList: ParcelList;\r\n\r\n agGridReady: boolean = false;\r\n gridTracker: AgGridMultiSelectTracker;\r\n selectedRows: number[] = [];\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n gridId: System.Guid = '0AD911C5-029D-47B6-847C-00B30505AD23';\r\n gridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'totals-row': (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return parcel && parcel.isTotalRow;\r\n },\r\n 'clickable': (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return parcel && !parcel.isTotalRow && !this.editMode;\r\n },\r\n 'ag-row-selected': (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return parcel && this.gridTracker.isRowSelected(parcel.parcelID);\r\n }\r\n },\r\n onRowClicked: this._navigateToParcelFromRowSelect.bind(this)\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withMultipleColumnSort()\r\n .withColumnResize()\r\n .withTextSelection()\r\n .withFilterChanged(this._updateTotal.bind(this))\r\n .withRowId((data) => {\r\n const parcel = data as ParcelListControlRow;\r\n return parcel && parcel.parcelID.toString();\r\n })\r\n .withColumnPinning()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _columnApi: ColumnApi;\r\n private _firstAssessor: AssessorSummary;\r\n private _stateId: number;\r\n private _state: Weissman.Model.Misc.State;\r\n private _maxTileCount: number = 100;\r\n private _selectedParcelIndex: number;\r\n private _destroy$: Subject = new Subject();\r\n private _gridColumnsInitialized: boolean;\r\n\r\n get canEdit(): boolean {\r\n return this.hasSiteWritePermission && this.ppReturnPreparationAllowed;\r\n }\r\n\r\n get hasMasterSite(): boolean {\r\n return this.site && this.site.masterSiteId && this.site.masterSiteId !== this.site.siteID;\r\n }\r\n\r\n get stateAllowConsolidating(): boolean {\r\n return this._state && this._state.allowConsolidating;\r\n }\r\n\r\n get ppReturnPreparationAllowed(): boolean {\r\n return this.site && this.site.ppReturnPreparationAllowed;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(PARCEL_LIST_PANEL_HELP);\r\n this._siteService.site = this.site;\r\n\r\n this.availableTaxYears = [this.latestTaxYearLabel, ...((this.parcelYears && this.parcelYears.length) ? this.parcelYears.reverse() : [])];\r\n\r\n if (this._entityService.currentSiteId !== this.site.siteID) {\r\n // Handle site specific state until all site route components are migrated from AngularJS\r\n this._entityService.reset();\r\n this._entityService.currentSiteId = this.site.siteID;\r\n }\r\n\r\n // State persistence\r\n this._entityService.parcelListDisplayState$.pipe(takeUntil(this._destroy$)).subscribe(state => this.contentTypeToggle.setValue(state));\r\n\r\n this._entityService.parcelListTaxYear$.pipe(takeUntil(this._destroy$)).subscribe(async (year) => {\r\n this._entityService.setParcelListScrollIndex(null);\r\n this.selectedTaxYear.setValue(year);\r\n await this._getParcels(year);\r\n });\r\n\r\n this._entityService.parcelListScrollIndex$.pipe(takeUntil(this._destroy$)).subscribe(i => {\r\n this._selectedParcelIndex = i;\r\n if (i !== null && i >= 0 && this._gridApi) {\r\n this._gridApi.ensureIndexVisible(this._selectedParcelIndex, 'top');\r\n }\r\n });\r\n\r\n this.excludeInactiveParcels.valueChanges.pipe(takeUntil(this._destroy$)).subscribe(exclude => {\r\n if (this.parcelList && this.excludeInactive !== exclude) {\r\n this.parcelList.filterInactive(exclude);\r\n if (this.agGridReady && this.contentTypeToggle.value) {\r\n this._setRowData();\r\n }\r\n }\r\n });\r\n\r\n this._siteService.parcelList$.pipe(takeUntil(this._destroy$)).subscribe(parcelList => {\r\n if (parcelList) {\r\n this.parcelList = parcelList;\r\n // Check for inactive parcels\r\n const inactiveParcelCount = this.parcelList.tiles.filter((p) => p.activityStatusID === 0).length;\r\n this.isExcludeInactiveParcelsCheckboxVisible = inactiveParcelCount !== 0;\r\n this.excludeInactiveParcels.setValue(inactiveParcelCount !== this.parcelList.tiles.length);\r\n if (this.contentTypeToggle.value) {\r\n this._setColumnDefinitions();\r\n }\r\n }\r\n });\r\n\r\n this._mutexService.lockChanged$.pipe(takeUntil(this._destroy$)).subscribe((x) => {\r\n const isLocked = x && x[this._entityService.editGroup];\r\n if (isLocked) {\r\n this.editMode = true;\r\n this.selectedTaxYear.disable();\r\n this.contentTypeToggle.disable();\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you wish to leave?');\r\n this._gridColumnsInitialized && this._columnApi && this._columnApi.setColumnsVisible(['grid-column-select'], true);\r\n }\r\n else {\r\n this.editMode = false;\r\n this.hasChanges = false;\r\n this.selectedTaxYear.enable();\r\n this.contentTypeToggle.enable();\r\n this._navigationService.disableNavWarning();\r\n this.gridTracker && this.gridTracker.clear();\r\n this.selectedRows = [];\r\n this._gridColumnsInitialized && this._columnApi && this._columnApi.setColumnsVisible(['grid-column-select'], false);\r\n this._gridApi && this._gridApi.redrawRows();\r\n }\r\n });\r\n\r\n // Theoretically we should re-initialize the page if the site changes, but in practice the only thing\r\n // that matters that we get from this.site is the address, so just reset the property on change (WK-8446)\r\n this._siteService.site$.pipe(takeUntil(this._destroy$)).subscribe(s => {\r\n this.site = s;\r\n if(this.site) {\r\n this._setSiteVars();\r\n }\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._siteService.reset();\r\n this._mutexService.release(this, this._entityService.editGroup);\r\n this._destroy$.next(true);\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._columnApi = event.columnApi;\r\n\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n this.gridTracker.selectedRows$.pipe(takeUntil(this._destroy$)).subscribe((selected: Compliance.SelectedRowsModel) => {\r\n this.selectedRows = (selected.selectAllRows)\r\n ? this.parcelList.parcels.filter(x => !x.isTotalRow).map(x => x.parcelID)\r\n : selected.selectedRows;\r\n\r\n this.isBulkUpdateVisible$.next(this.selectedRows && this.selectedRows.length > 0);\r\n });\r\n\r\n if (this.parcelList) {\r\n this._setColumnDefinitions();\r\n }\r\n\r\n this.agGridReady = true;\r\n this._setRowData();\r\n }\r\n\r\n wsMutexRelease(groupId: string): Promise {\r\n return Promise.resolve();\r\n }\r\n\r\n onViewChanged(toggleValue: boolean): void {\r\n this._entityService.changeParcelListDisplayState(toggleValue);\r\n }\r\n\r\n onTaxYearChanged(taxYear: string): void {\r\n this._entityService.changeParcelListTaxYear(taxYear);\r\n }\r\n\r\n async bulkUpdate(): Promise {\r\n let isConsolidatedParcelSelected: boolean = false;\r\n let isNonPPParcelsSelected: boolean = false;\r\n\r\n this.selectedRows.forEach(x => {\r\n const rowNode = this._gridApi.getRowNode(x.toString());\r\n const parcel = rowNode.data as ParcelListControlRow;\r\n\r\n if (parcel && parcel.parcelID == parcel.consolidatedParcelId) {\r\n isConsolidatedParcelSelected = true;\r\n }\r\n\r\n if (parcel && parcel.propertyTypeId !== Core.PropertyTypes.Personal) {\r\n isNonPPParcelsSelected = true;\r\n }\r\n });\r\n\r\n const params: ParcelBulkUpdateParams = {\r\n siteId: this.site.siteID,\r\n selectedRows: this.gridTracker.getSelectedRowsModel(),\r\n stateAllowConsolidating: this._state.allowConsolidating,\r\n isConsolidatedParcelSelected: isConsolidatedParcelSelected,\r\n isNonPPParcelsSelected: isNonPPParcelsSelected\r\n };\r\n\r\n const result = await this._modalService.showAsync(ParcelBulkUpdateComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n const update: RowNode[] = [];\r\n\r\n if (result.optInParcelsAction === Core.ParcelBulkUpdateFieldActionEnum.ChangeTo) {\r\n result.optInParcels.forEach(x => {\r\n const rowNode = this._gridApi.getRowNode(x.toString());\r\n const parcel = rowNode && rowNode.data as ParcelListControlRow;\r\n parcel.consolidatingTypeId = null;\r\n update.push(rowNode);\r\n this.hasChanges = true;\r\n });\r\n }\r\n\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this.gridTracker && this.gridTracker.clear();\r\n this.selectedRows = [];\r\n }\r\n\r\n edit(): void {\r\n this._mutexService.acquire(this, this._entityService.editGroup);\r\n }\r\n\r\n async save(): Promise {\r\n const bulkUpdateModel: Core.ParcelBulkUpdateModel = {\r\n siteId: this.site.siteID,\r\n force: true,\r\n reportingParcelAction: Core.ParcelBulkUpdateFieldActionEnum.NoChange,\r\n reportingParcelId: null,\r\n consolidatedParcelAction: Core.ParcelBulkUpdateFieldActionEnum.NoChange,\r\n consolidatedParcelId: null,\r\n optInParcelsAction: Core.ParcelBulkUpdateFieldActionEnum.NoChange,\r\n optInParcels: [],\r\n optOutParcelsAction: Core.ParcelBulkUpdateFieldActionEnum.NoChange,\r\n optOutParcels: []\r\n };\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const parcel = node.data as ParcelListControlRow;\r\n if (parcel && parcel.propertyTypeId === Core.PropertyTypes.Personal && !parcel.isExternalReportingParcel && !parcel.isTotalRow) {\r\n // update reporting parcel\r\n if (parcel.isReportingParcel !== parcel.originalIsReportingParcel) {\r\n bulkUpdateModel.reportingParcelAction = Core.ParcelBulkUpdateFieldActionEnum.ChangeTo;\r\n if (parcel.isReportingParcel) {\r\n bulkUpdateModel.reportingParcelId = parcel.parcelID;\r\n }\r\n }\r\n\r\n // update consolidated parcel\r\n if (parcel.consolidatedParcelId !== parcel.originalConsolidatedParcelId) {\r\n bulkUpdateModel.consolidatedParcelAction = Core.ParcelBulkUpdateFieldActionEnum.ChangeTo;\r\n if (parcel.consolidatedParcelId === parcel.parcelID) {\r\n bulkUpdateModel.consolidatedParcelId = parcel.parcelID;\r\n }\r\n }\r\n\r\n // update opt in/out\r\n if (parcel.consolidatedParcelId && (parcel.consolidatingTypeId !== parcel.originalConsolidatingTypeId)) {\r\n if (parcel.consolidatingTypeId === Core.ConsolidatingTypeEnum.None) {\r\n bulkUpdateModel.optOutParcelsAction = Core.ParcelBulkUpdateFieldActionEnum.ChangeTo;\r\n bulkUpdateModel.optOutParcels.push(parcel.parcelID);\r\n }\r\n\r\n if (!parcel.consolidatingTypeId) {\r\n bulkUpdateModel.optInParcelsAction = Core.ParcelBulkUpdateFieldActionEnum.ChangeTo;\r\n bulkUpdateModel.optInParcels.push(parcel.parcelID);\r\n }\r\n }\r\n }\r\n });\r\n\r\n this._setDataLoading(true);\r\n try {\r\n await this._parcelService.bulkUpdate(bulkUpdateModel);\r\n await this._siteService.updateParcelList(this.selectedTaxYear.value);\r\n this._mutexService.release(this, this._entityService.editGroup);\r\n } finally {\r\n this._setDataLoading(false);\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n cancel(): void {\r\n const update: RowNode[] = [];\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const parcel = node.data as ParcelListControlRow;\r\n if (parcel && parcel.propertyTypeId === Core.PropertyTypes.Personal && !parcel.isExternalReportingParcel && !parcel.isTotalRow &&\r\n (parcel.originalIsReportingParcel !== parcel.isReportingParcel ||\r\n parcel.originalConsolidatingTypeId !== parcel.consolidatingTypeId ||\r\n parcel.originalConsolidatedParcelId !== parcel.consolidatedParcelId)) {\r\n parcel.isReportingParcel = parcel.originalIsReportingParcel;\r\n parcel.consolidatingTypeId = parcel.originalConsolidatingTypeId;\r\n parcel.consolidatedParcelId = parcel.originalConsolidatedParcelId;\r\n update.push(node);\r\n }\r\n });\r\n\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this._mutexService.release(this, this._entityService.editGroup);\r\n }\r\n\r\n expandPanel() {\r\n super.expandComponent();\r\n if (this._gridApi && this.contentTypeToggle.value) {\r\n this._timer.setTimeout(() => {\r\n this._gridApi.sizeColumnsToFit();\r\n }, 500);\r\n }\r\n this.maximize('form-parcel-list');\r\n }\r\n\r\n collapsePanel(): void {\r\n super.collapseComponent();\r\n if (this._gridApi && this.contentTypeToggle.value) {\r\n this._timer.setTimeout(() => {\r\n this._gridApi.sizeColumnsToFit();\r\n }, 500);\r\n }\r\n this.minimize();\r\n }\r\n\r\n navigateToParcel(parcelID: number, parcel: Core.ParcelTileDTO): void {\r\n if (this.editMode) {\r\n return;\r\n }\r\n this._productAnalyticsService.logEvent('click-parcel-tile', { accessSiteParcel: `${parcel.propTypeAbbr} Parcel` });\r\n\r\n this._routerService.go('parcelRedirect', { entityID: parcelID });\r\n }\r\n\r\n async showAddParcel(): Promise {\r\n const masterParcel = this.parcelList.tiles.find(x => x.isMasterParcel);\r\n\r\n const params: AddParcelModalParams = {\r\n siteId: this.site.siteID,\r\n siteAddress: this.site.address,\r\n stateId: this._stateId,\r\n stateName: this._state.fullName,\r\n siteAssessor: this._firstAssessor,\r\n masterParcel: masterParcel\r\n };\r\n\r\n const result = await this._modalService.showAsync(AddParcelModalComponent, params, 'modal-md');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.navigateToParcel(result.parcelID, result);\r\n }\r\n\r\n private _canRemoveReportingParcel(params: ParcelListActionCellRendererParams): boolean {\r\n const parcel = params.data as ParcelListControlRow;\r\n return this.editMode &&\r\n parcel &&\r\n parcel.isReportingParcel &&\r\n !this.hasMasterSite; // prevent changing reporting parcel when in a master parcel relationship\r\n }\r\n\r\n private _removeReportingParcel(params: ParcelListActionCellRendererParams): void {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (!parcel) {\r\n return;\r\n }\r\n\r\n const update: RowNode[] = [];\r\n\r\n parcel.isReportingParcel = false;\r\n\r\n update.push(params.node);\r\n\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this.hasChanges = true;\r\n }\r\n\r\n private _canSetReportingParcel(params: ParcelListActionCellRendererParams): boolean {\r\n const parcel = params.data as ParcelListControlRow;\r\n return this.editMode &&\r\n parcel &&\r\n parcel.propertyTypeId === Core.PropertyTypes.Personal &&\r\n parcel.activityStatusID !== ActivityStatuses.Inactive &&\r\n !parcel.isReportingParcel &&\r\n !this.hasMasterSite; // prevent changing reporting parcel when in a master parcel relationship\r\n }\r\n\r\n private _setReportingParcel(params: ParcelListActionCellRendererParams): void {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (!parcel) {\r\n return;\r\n }\r\n\r\n const update: RowNode[] = [];\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const oldParcel = node.data as ParcelListControlRow;\r\n if (oldParcel && oldParcel.propertyTypeId === Core.PropertyTypes.Personal && !parcel.isExternalReportingParcel && !parcel.isTotalRow) {\r\n if (oldParcel.isReportingParcel) {\r\n oldParcel.isReportingParcel = false;\r\n update.push(node);\r\n }\r\n }\r\n });\r\n\r\n parcel.isReportingParcel = true;\r\n\r\n update.push(params.node);\r\n\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this.hasChanges = true;\r\n }\r\n\r\n private _canSetConsolidated(params: ParcelListActionCellRendererParams): boolean {\r\n const parcel = params.data as ParcelListControlRow;\r\n return this.editMode &&\r\n parcel &&\r\n parcel.propertyTypeId === Core.PropertyTypes.Personal &&\r\n parcel.activityStatusID !== Core.ActivityStatuses.Inactive &&\r\n !parcel.consolidatedParcelId &&\r\n !parcel.isExternalReportingParcel;\r\n }\r\n\r\n private _setConsolidatedParcel(params: ParcelListActionCellRendererParams): void {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (!parcel) {\r\n return;\r\n }\r\n\r\n const update: RowNode[] = [];\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const oldParcel = node.data as ParcelListControlRow;\r\n if (oldParcel && oldParcel.propertyTypeId === Core.PropertyTypes.Personal && !parcel.isExternalReportingParcel && !oldParcel.isTotalRow)\r\n {\r\n if (oldParcel.consolidatedParcelId !== parcel.parcelID) {\r\n oldParcel.consolidatedParcelId = parcel.parcelID;\r\n update.push(node);\r\n }\r\n }\r\n });\r\n\r\n parcel.consolidatingTypeId = Core.ConsolidatingTypeEnum.Consolidated;\r\n\r\n update.push(params.node);\r\n\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this.hasChanges = true;\r\n\r\n this._warnOnConsolidatedChange();\r\n }\r\n\r\n private _canRemoveConsolidated(params: ParcelListActionCellRendererParams): boolean {\r\n const parcel = params.data as ParcelListControlRow;\r\n return this.editMode &&\r\n parcel &&\r\n parcel.consolidatedParcelId &&\r\n parcel.consolidatedParcelId === parcel.parcelID &&\r\n !parcel.isExternalReportingParcel;\r\n }\r\n\r\n private _removeConsolidatedParcel(params: ParcelListActionCellRendererParams): void {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (!parcel) {\r\n return;\r\n }\r\n\r\n const update: RowNode[] = [];\r\n\r\n this._gridApi.forEachNode((node: RowNode) => {\r\n const oldParcel = node.data as ParcelListControlRow;\r\n\r\n if (oldParcel && oldParcel.propertyTypeId === Core.PropertyTypes.Personal && !parcel.isExternalReportingParcel && !parcel.isTotalRow) {\r\n if (oldParcel.consolidatedParcelId) {\r\n oldParcel.consolidatedParcelId = null;\r\n update.push(node);\r\n }\r\n }\r\n });\r\n\r\n parcel.consolidatedParcelId = null;\r\n parcel.consolidatingTypeId = null;\r\n\r\n update.push(params.node);\r\n\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this.hasChanges = true;\r\n }\r\n\r\n private _canOptOutConsolidated(params: ParcelListActionCellRendererParams): boolean {\r\n const parcel = params.data as ParcelListControlRow;\r\n return this.editMode &&\r\n parcel &&\r\n parcel.consolidatedParcelId &&\r\n parcel.consolidatedParcelId !== parcel.parcelID &&\r\n parcel.consolidatingTypeId === null &&\r\n !parcel.isExternalReportingParcel;\r\n }\r\n\r\n private _optOutConsolidatedParcel(params: ParcelListActionCellRendererParams): void {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (!parcel) {\r\n return;\r\n }\r\n\r\n const update: RowNode[] = [];\r\n\r\n parcel.consolidatingTypeId = Core.ConsolidatingTypeEnum.None;\r\n\r\n update.push(params.node);\r\n\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this.hasChanges = true;\r\n }\r\n\r\n private _canOptInConsolidated(params: ParcelListActionCellRendererParams): boolean {\r\n const parcel = params.data as ParcelListControlRow;\r\n return this.editMode &&\r\n parcel &&\r\n parcel.activityStatusID !== 0 &&\r\n parcel.consolidatedParcelId &&\r\n parcel.consolidatedParcelId !== parcel.parcelID &&\r\n parcel.consolidatingTypeId === Core.ConsolidatingTypeEnum.None &&\r\n !parcel.isExternalReportingParcel;\r\n }\r\n\r\n private _optInConsolidatedParcel(params: ParcelListActionCellRendererParams): void {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (!parcel) {\r\n return;\r\n }\r\n\r\n const update: RowNode[] = [];\r\n\r\n parcel.consolidatingTypeId = null;\r\n\r\n update.push(params.node);\r\n\r\n this._gridApi.redrawRows({ rowNodes: update });\r\n\r\n this.hasChanges = true;\r\n\r\n this._warnOnConsolidatedChange();\r\n }\r\n\r\n private async _setSiteVars() {\r\n this._stateId = this.site.address.stateID;\r\n this._firstAssessor = (this.site.assessors && this.site.assessors.length) ? this.site.assessors[0] : null;\r\n this._state = await this._stateService.getById(this._stateId);\r\n }\r\n\r\n private _setColumnDefinitions(): void {\r\n let columns: ColDef[] = [\r\n {\r\n colId: 'grid-column-select',\r\n field: 'parcelID',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n pinned: 'left',\r\n lockPinned: true,\r\n editable: false,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: {\r\n tracker: this.gridTracker\r\n } as AgGridMultiSelectRendererParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Type',\r\n field: 'propTypeAbbr',\r\n width: 100,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: ParcelTypeCellRendererComponent,\r\n cellRendererParams: {\r\n getParcelType: (params: ParcelTypeCellRendererComponentParams): string => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return parcel.propTypeAbbr;\r\n },\r\n isLinkedParcel: (params: ParcelTypeCellRendererComponentParams): boolean => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return parcel.isLinked;\r\n },\r\n isMasterParcel: (params: ParcelTypeCellRendererComponentParams): boolean => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return parcel.isMasterParcel;\r\n },\r\n isReportingParcel: (params: ParcelTypeCellRendererComponentParams): boolean => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return parcel.isReportingParcel && this.ppReturnPreparationAllowed;\r\n },\r\n isConsolidatedParcel: (params: ParcelTypeCellRendererComponentParams): boolean => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return parcel.consolidatingTypeId === Core.ConsolidatingTypeEnum.Consolidated && this.ppReturnPreparationAllowed;\r\n },\r\n ppReturnPreparationAllowed: (params: ParcelTypeCellRendererComponentParams) => this.ppReturnPreparationAllowed,\r\n stateAllowConsolidating: (params: ParcelTypeCellRendererComponentParams) => this.stateAllowConsolidating,\r\n isMergedParcel: (params: ParcelTypeCellRendererComponentParams): boolean => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return parcel.consolidatedParcelId && !parcel.consolidatingTypeId && this.ppReturnPreparationAllowed;\r\n }\r\n }\r\n },\r\n {\r\n headerName: 'Acct Num',\r\n field: 'acctNum',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return (!parcel.isTotalRow) ? parcel.acctNum : 'TOTAL';\r\n }\r\n },\r\n {\r\n headerName: 'Description',\r\n field: 'description',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return (!parcel.isTotalRow) ? parcel.description : '-';\r\n }\r\n },\r\n {\r\n headerName: 'Parcel #2',\r\n field: 'altParcel2',\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (parcel.isTotalRow) {\r\n return '-';\r\n }\r\n return (parcel.altParcel2) ? parcel.altParcel2 : '';\r\n }\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorAbbr',\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (parcel.isTotalRow) {\r\n return '-';\r\n }\r\n return (parcel.assessorAbbr) ? parcel.assessorAbbr : '';\r\n }\r\n },\r\n {\r\n headerName: 'Assessee',\r\n field: 'assesseeName',\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (parcel.isTotalRow) {\r\n return '-';\r\n }\r\n return (parcel.assesseeName) ? parcel.assesseeName : '';\r\n }\r\n },\r\n {\r\n headerName: 'Address',\r\n field: 'address',\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (parcel.isTotalRow) {\r\n return '-';\r\n }\r\n const address = parcel.address;\r\n let combined = '';\r\n if (address && address.address1) {\r\n combined += address.address1;\r\n }\r\n if (address && address.address2) {\r\n combined += ` ${address.address2}`;\r\n }\r\n return combined;\r\n }\r\n },\r\n {\r\n headerName: 'City',\r\n field: 'city',\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (parcel.isTotalRow) {\r\n return '-';\r\n }\r\n const address = parcel.address;\r\n return (address && address.city) ? address.city : '';\r\n }\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (parcel.isTotalRow) {\r\n return '-';\r\n }\r\n const address = parcel.address;\r\n return (address && address.state) ? address.state.abbr : '';\r\n }\r\n },\r\n {\r\n headerName: 'Zip',\r\n field: 'zip',\r\n hide: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (parcel.isTotalRow) {\r\n return '-';\r\n }\r\n const address = parcel.address;\r\n return (address && address.zip) ? address.zip : '';\r\n }\r\n },\r\n {\r\n headerName: 'Year',\r\n field: 'annualYear',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (parcel.isTotalRow) {\r\n return '-';\r\n }\r\n return (parcel.annualYear) ? parcel.annualYear.toString() : '';\r\n }\r\n },\r\n {\r\n headerName: 'Total FMV',\r\n field: 'totalFMV',\r\n type: 'numericColumn',\r\n width: 35 + AgGridColumns.numericColumnWidth,\r\n minWidth: 35 + AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellRendererFramework: TotalFMVRendererComponent,\r\n cellRendererParams: {\r\n activityStatusId: (params: TotalFMVRendererParams): number => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return (parcel) ? parcel.activityStatusID : 0;\r\n },\r\n isFmvInclude: (params: TotalFMVRendererParams): boolean => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return (parcel) ? parcel.isFmvInclude : false;\r\n },\r\n getTotal: (params: TotalFMVRendererParams): string => {\r\n const parcel = params.data as ParcelListControlRow;\r\n\r\n if (parcel.consolidatingTypeId === Core.ConsolidatingTypeEnum.Consolidated) {\r\n return 'N/A';\r\n }\r\n\r\n return (parcel && parcel.totalFMV) ? this._decimalPipe.transform(parcel.totalFMV) : '0';\r\n }\r\n } as TotalFMVRendererParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return ((parcel.status === null || parcel.status === 0)\r\n && !parcel.isTotalRow && parcel.consolidatingTypeId !== Core.ConsolidatingTypeEnum.Consolidated)\r\n ? 'text-end not-actual'\r\n : 'text-end';\r\n }\r\n },\r\n {\r\n headerName: 'FMV Change',\r\n field: 'fmvChange',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellRendererFramework: FMVChangeRendererComponent,\r\n cellRendererParams: {\r\n getText: (params: FMVChangeRendererParams): number => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (!parcel) {\r\n return;\r\n }\r\n return parcel.fmvChange;\r\n }\r\n } as FMVChangeRendererParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return ((parcel.status === null || parcel.status === 0)\r\n && !parcel.isTotalRow && parcel.consolidatingTypeId !== Core.ConsolidatingTypeEnum.Consolidated)\r\n ? 'text-end not-actual'\r\n : 'text-end';\r\n }\r\n },\r\n {\r\n headerName: 'Taxes',\r\n field: 'totalTaxes',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n\r\n if (parcel.consolidatingTypeId === Core.ConsolidatingTypeEnum.Consolidated) {\r\n return 'N/A';\r\n }\r\n\r\n return `$${ (parcel && parcel.totalTaxes) ? this._decimalPipe.transform(parcel.totalTaxes, '1.2') : '0.00'}`;\r\n },\r\n cellClass: (params: ICellRendererParams): string => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return (parcel.taxIsEstimated !== false\r\n && !parcel.isTotalRow && parcel.consolidatingTypeId !== Core.ConsolidatingTypeEnum.Consolidated)\r\n ? 'text-end tax-is-estimated'\r\n : 'text-end';\r\n }\r\n },\r\n {\r\n headerName: 'Tax % Difference',\r\n field: 'taxPercentDiff',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n filterValueGetter: (params: PercentChangeRendererParams): number => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return (parcel && parcel.taxPercentDiff) ? +((parcel.taxPercentDiff * 100).toFixed(3)) : 0;\r\n },\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n cellRendererFramework: PercentChangeRendererComponent,\r\n cellRendererParams: {\r\n getPercentage: (params: PercentChangeRendererParams): number => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (!parcel) {\r\n return 0;\r\n }\r\n\r\n if (parcel.isTotalRow) {\r\n return null;\r\n }\r\n\r\n return (parcel.taxPercentDiff) ? parcel.taxPercentDiff : 0;\r\n }\r\n } as PercentChangeRendererParams,\r\n cellClass: (params: ICellRendererParams): string => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return (parcel.taxIsEstimated !== false\r\n && !parcel.isTotalRow && parcel.consolidatingTypeId !== Core.ConsolidatingTypeEnum.Consolidated)\r\n ? 'text-end tax-is-estimated'\r\n : 'text-end';\r\n }\r\n }\r\n ];\r\n\r\n // Inject unique component columns if any\r\n const uniqueComponents = this._getUniqueComponents();\r\n if (uniqueComponents && uniqueComponents.length) {\r\n const componentCols = uniqueComponents.map(component => {\r\n const uniqueComponent = () => component; // Create closure\r\n return {\r\n headerName: component.componentName,\r\n field: 'components',\r\n type: 'numericColumn',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberWithRangeAndBlankOptionsFilterParams,\r\n filterValueGetter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n if (parcel.components) {\r\n const unique = uniqueComponent();\r\n const foundComponent = parcel.components.find(x => x.componentName === unique.componentName);\r\n return foundComponent && foundComponent.fairMarketValue;\r\n }\r\n\r\n },\r\n cellClass: (params: ICellRendererParams): string => {\r\n const parcel = params.data as ParcelListControlRow;\r\n return ((parcel.status === null || parcel.status === 0) && !parcel.isTotalRow) ? 'not-actual' : '';\r\n },\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const parcel = params.data as ParcelListControlRow;\r\n const unique = uniqueComponent();\r\n if (parcel.isTotalRow) {\r\n return parcel.totalComponents[unique.componentName]\r\n ? this._decimalPipe.transform(parcel.totalComponents[unique.componentName])\r\n : '-';\r\n }\r\n if (parcel.components) {\r\n const foundComponent = parcel.components.find(x => x.componentName === unique.componentName);\r\n return foundComponent ? this._decimalPipe.transform(foundComponent.fairMarketValue) : '--';\r\n }\r\n return '--';\r\n }\r\n } as ColDef;\r\n }) as ColDef[];\r\n\r\n const clone = [...columns];\r\n clone.splice(columns.length - 1, 0, ...componentCols);\r\n columns = clone;\r\n }\r\n\r\n columns.push({\r\n colId: 'grid-column-actions',\r\n headerName: '',\r\n field: 'actions',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n pinned: 'right',\r\n lockVisible: true,\r\n sortable: false,\r\n cellRendererFramework: ParcelListActionCellRendererComponent,\r\n cellRendererParams: {\r\n canSetReporting: this._canSetReportingParcel.bind(this),\r\n setReporting: this._setReportingParcel.bind(this),\r\n canRemoveReporting: this._canRemoveReportingParcel.bind(this),\r\n removeReporting: this._removeReportingParcel.bind(this),\r\n canSetConsolidated: this._canSetConsolidated.bind(this),\r\n setConsolidated: this._setConsolidatedParcel.bind(this),\r\n canRemoveConsolidated: this._canRemoveConsolidated.bind(this),\r\n removeConsolidated: this._removeConsolidatedParcel.bind(this),\r\n canOptOutConsolidated: this._canOptOutConsolidated.bind(this),\r\n optOutConsolidated: this._optOutConsolidatedParcel.bind(this),\r\n canOptInConsolidated: this._canOptInConsolidated.bind(this),\r\n optInConsolidated: this._optInConsolidatedParcel.bind(this),\r\n stateAllowConsolidating: (params) => this.stateAllowConsolidating\r\n } as ParcelListActionCellRendererParams,\r\n pinnedRowCellRenderer: () => { return ''; },\r\n hide: !this.canEdit\r\n });\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'accountNumber',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridColumnsInitialized = true;\r\n this._gridApi.setSortModel(defaultSortModel);\r\n }\r\n\r\n private _setRowData(): void {\r\n if (!this._gridApi) {\r\n return;\r\n }\r\n\r\n this.gridTracker && this.gridTracker.clear();\r\n this.selectedRows = [];\r\n\r\n this._gridApi.setRowData((this.parcelList) ? this.parcelList.parcels.filter(x => !x.isTotalRow) : []);\r\n\r\n this._gridApi.setPinnedBottomRowData(this.parcelList && this.parcelList.parcels.filter(x => x.isTotalRow));\r\n\r\n if (this._selectedParcelIndex !== null && this._selectedParcelIndex >= 0) {\r\n this._gridApi.ensureIndexVisible(this._selectedParcelIndex, 'top');\r\n }\r\n }\r\n\r\n private async _getParcels(year: number | string): Promise {\r\n this._setDataLoading(true);\r\n try {\r\n await this._siteService.updateParcelList(year);\r\n } finally {\r\n this._setDataLoading(false);\r\n return Promise.resolve();\r\n }\r\n }\r\n\r\n private _updateTotal(event: FilterChangedEvent): void {\r\n let totalFMV = 0;\r\n let totalTaxes = 0;\r\n const totalComponents = {};\r\n\r\n this._gridApi.forEachNodeAfterFilter((rowNode: RowNode) => {\r\n const parcel = rowNode.data as ParcelListControlRow;\r\n if (parcel) {\r\n totalFMV += parcel.totalFMV || 0;\r\n totalTaxes += parcel.totalTaxes || 0;\r\n\r\n if (parcel.components) {\r\n parcel.components.forEach(c => {\r\n totalComponents[c.componentName] += c.fairMarketValue;\r\n });\r\n }\r\n }\r\n });\r\n\r\n const rowNode = this._gridApi.getPinnedBottomRow(0);\r\n const parcel = rowNode.data as ParcelListControlRow;\r\n if (parcel) {\r\n parcel.totalFMV = totalFMV;\r\n parcel.totalTaxes = totalTaxes;\r\n Object.keys(totalComponents).forEach(key => parcel[key] = totalComponents[key]);\r\n }\r\n this._gridApi.redrawRows({ rowNodes: [rowNode] });\r\n }\r\n\r\n private _getUniqueComponents() {\r\n return this.parcelList.tiles\r\n .reduce((acc, parcel) => (parcel.components && parcel.components.length) ? [...acc, ...parcel.components] : acc, [])\r\n .filter((comp) => !!comp)\r\n .reduce((acc, comp) => (acc.findIndex(x => x.componentName === comp.componentName) === -1) ? [...acc, comp] : acc, []);\r\n }\r\n\r\n private _navigateToParcelFromRowSelect(row: RowClickedEvent): void {\r\n const parcel = row.data as ParcelListControlRow;\r\n const index = row.rowIndex;\r\n this._entityService.setParcelListScrollIndex(index);\r\n this.navigateToParcel(parcel.parcelID, parcel);\r\n }\r\n\r\n private _setDataLoading(disable: boolean): void {\r\n this.dataLoading = disable;\r\n if (disable) {\r\n this.contentTypeToggle.disable();\r\n this.excludeInactiveParcels.disable();\r\n this.selectedTaxYear.disable();\r\n } else {\r\n this.excludeInactiveParcels.enable();\r\n this.selectedTaxYear.enable();\r\n let tooltipText = 'Toggle between Tile and List views';\r\n if (this.parcelList && this.parcelList.tiles.length > this._maxTileCount) {\r\n this.contentTypeToggle.setValue(true);\r\n tooltipText = `Tile view is not available on sites with greater than ${this._maxTileCount} parcels.`;\r\n this.contentTypeToggle.disable();\r\n } else {\r\n this.contentTypeToggle.enable();\r\n }\r\n this._helpService.updateContent([{\r\n helpContentId: 'parcel-list-panel.view-switch',\r\n tooltipText\r\n }]);\r\n }\r\n }\r\n\r\n private _getGridRowIds(skip, take): Promise> {\r\n const model: any = this._gridApi.getModel();\r\n const rows = model.rowsToDisplay.slice(skip, take + 1);\r\n const queryResultModel: Compliance.QueryResultModel = {\r\n lastModifiedTimestamp: new Date(),\r\n totalRows: rows.length,\r\n totalValidRows: rows.length,\r\n data: rows.map((x) => {\r\n const parcel = x.data as ParcelListControlRow;\r\n return parcel && parcel.parcelID;\r\n })\r\n };\r\n\r\n return Promise.resolve(queryResultModel);\r\n }\r\n\r\n private _warnOnConsolidatedChange(): void {\r\n this._toastrService.warning('This change will remove Assessments, Bills, Appeals, and Budget from consolidated parcel, and incomplete filings and filings in unlocked batches from merged parcels.');\r\n }\r\n}\r\n","import { HelpContent } from '../../../UI-Lib/Help-Tooltip';\r\n\r\nexport const SITE_INFO_PANEL_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'site-info-panel.attachments',\r\n tooltipText: 'Attachments'\r\n },\r\n {\r\n helpContentId: 'site-info-panel.change-history',\r\n tooltipText: 'Change history'\r\n },\r\n {\r\n helpContentId: 'site-info-panel.comments',\r\n tooltipText: 'Comments'\r\n },\r\n {\r\n helpContentId: 'site-info-panel.copy',\r\n tooltipText: 'Copy'\r\n },\r\n {\r\n helpContentId: 'site-info-panel.images',\r\n tooltipText: 'Images'\r\n },\r\n {\r\n helpContentId: 'site-info-panel.cre',\r\n tooltipText: 'Valuation Tool'\r\n },\r\n {\r\n helpContentId: 'site-info-panel.map',\r\n tooltipText: 'Site Map'\r\n }\r\n]\r\n","import { AfterViewInit, Component, OnInit, ViewChild } from '@angular/core';\r\nimport { MapInfoWindow, MapMarker } from '@angular/google-maps';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { Constants } from '../../constants.new';\r\nimport { Site } from '../../Entity/Site/Site.Model';\r\nimport { UpgradeNavigationServiceHandler } from '../Routing/upgrade-navigation-handler.service';\r\nimport { Address } from '../Models/common.model';\r\n\r\n@Component({\r\n selector: 'google-maps-single-marker-modal',\r\n template: `\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n `\r\n})\r\nexport class GoogleMapsSingleMarkerModalComponent implements OnInit, AfterViewInit, IWeissmanModalComponent {\r\n constructor(public bsModalRef: BsModalRef,\r\n public constants: Constants,\r\n private navigationServiceHandler: UpgradeNavigationServiceHandler) {}\r\n\r\n @ViewChild(MapInfoWindow, { static: false }) infoWindow: MapInfoWindow;\r\n @ViewChild('markerElem') markerElem: MapMarker;\r\n\r\n params: {\r\n site: Site;\r\n };\r\n result: void;\r\n\r\n options: google.maps.MarkerOptions;\r\n coordinates: google.maps.LatLngLiteral;\r\n siteMapUrl: string;\r\n\r\n get siteAddress() {\r\n return this.params.site.address as unknown as Address;\r\n }\r\n\r\n ngOnInit() {\r\n this.options = {\r\n animation: google.maps.Animation.DROP,\r\n icon: `/images/google-maps-icons/${this._getIconName()}.png`\r\n };\r\n\r\n this.coordinates = {\r\n lat: this.params.site?.address.latitude,\r\n lng: this.params.site?.address.longitude\r\n };\r\n\r\n const params = { siteId: this.params.site.siteID, companyId: this.params.site.companyID};\r\n this.siteMapUrl = this.navigationServiceHandler.getHrefFromState('siteMap', params);\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.infoWindow.open(this.markerElem);\r\n }\r\n\r\n close() {\r\n this.infoWindow.close();\r\n this.bsModalRef.hide();\r\n }\r\n\r\n private _getIconName() {\r\n if(this.params.site?.siteClassSecondary?.siteClassPrimary?.siteClassPrimaryID != undefined) {\r\n return this.constants.SiteClassIcons[this.params.site.siteClassSecondary.siteClassPrimary.siteClassPrimaryID];\r\n } else {\r\n return 'symbol_inter';\r\n }\r\n }\r\n\r\n}\r\n","
\r\n
\r\n
\r\n

Site Info

\r\n
\r\n \r\n Processing...\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n

{{site.name}}

\r\n
\r\n Site Name: \r\n \r\n
\r\n
\r\n
\r\n
\r\n {{site.address.address1}}\r\n
\r\n Address:\r\n \r\n
\r\n
\r\n
\r\n {{site.address.address2}}\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n {{site.address.city}}, {{getState(site.address.stateID)}} {{site.address.zip}}\r\n
\r\n \r\n \r\n {{getState(site.address.stateID)}}\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n Site Number: \r\n \r\n {{site.property}}\r\n \r\n \r\n
\r\n
\r\n Assessor 1\">s:\r\n \r\n \r\n {{assessor.abbr}} {{assessor.municipalityName}}\r\n ,\r\n \r\n \r\n
\r\n
\r\n Site Class: \r\n \r\n {{getSiteClassName(site.siteClassSecondaryID)}}\r\n \r\n \r\n
\r\n
\r\n
\r\n Parent Excluded From Accruals\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n Status: \r\n \r\n
\r\n \r\n
\r\n Sold Date: \r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n Activation/Inactivation date information is not available for this site.\r\n
\r\n
site.inactivatedDateTime\">\r\n
\r\n Activated by {{site.activatedBy}}
\r\n Date: \r\n
\r\n
\r\n Inactivated by {{site.inactivatedBy}}
\r\n Date: \r\n
\r\n
\r\n
\r\n
\r\n Inactivated by {{site.inactivatedBy}}
\r\n Date: \r\n \r\n
\r\n
\r\n Activated by {{site.activatedBy}}
\r\n Date: \r\n \r\n
\r\n
\r\n
\r\n","import { Component, OnInit, Input } from '@angular/core';\r\nimport { UntypedFormGroup, UntypedFormControl, UntypedFormBuilder } from '@angular/forms';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { lastValueFrom } from 'rxjs';\r\nimport { RestrictService, RestrictData, Roles, InstanceRights } from '../../../Common/Permissions/restrict.service';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { SiteService } from '../Site.Service.upgrade';\r\nimport { AttachmentModalData } from '../../../Attachment/attachment.modal.model';\r\nimport { Site, AssessorSummary } from '../Site.Model';\r\nimport { TaskService } from '../../../Task/task.service.upgrade';\r\nimport { MessageBoxService, MessageBoxResult, MessageBoxButtons } from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { UpgradeNavigationServiceHandler } from '../../../Common/Routing/upgrade-navigation-handler.service';\r\nimport { Constants, EntityTypeIds } from '../../../constants.new';\r\nimport { SiteClassService } from '../siteClass.service';\r\nimport { ChangeHistoryModalLaunchService } from '../../../Common/Change-History/change-history-modal-launch.service';\r\nimport { HelpContentComponentConfig, HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { AssessorDetailsComponent, AssessorDetailsComponentParams } from '../../Assessor-Details/assessorDetails.component';\r\nimport { StateService } from '../../../Common/States/States.Service';\r\nimport { StateSummary } from '../../../Common/States/state.model';\r\nimport { DeleteConfirmationComponentParams, DeleteConfirmationComponent } from '../../../Common/Delete-Confirmation/deleteConfirmation.component';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport * as _ from 'lodash';\r\nimport { SITE_INFO_PANEL_HELP } from './siteInfoPanel.component.help';\r\nimport { BsModalService } from 'ngx-bootstrap/modal';\r\nimport { SiteMapService } from '../../site.map.service';\r\nimport { GoogleMapsSingleMarkerModalComponent } from '../../../Common/Address/google.maps.single.marker.modal.component';\r\nimport { InstanceRepository } from '../../Instance/instance.repository';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\nimport { UserInstanceService } from 'src/app/User/userInstance.service';\r\nimport { ActivityStatusService } from 'src/app/Common/Activity/activityStatus.service';\r\n\r\n@Component({\r\n selector: 'site-info-panel',\r\n templateUrl: './siteInfoPanel.component.html',\r\n styleUrls: ['./siteInfoPanel.component.scss']\r\n})\r\nexport class SiteInfoPanelComponent implements OnInit {\r\n constructor(\r\n public readonly toastr: ToastrService,\r\n public readonly featureFlagsService: FeatureFlagsService,\r\n private readonly _restrictService: RestrictService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _siteService: SiteService,\r\n private readonly _taskService: TaskService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _siteClassService: SiteClassService,\r\n private readonly _activityStatusService: ActivityStatusService,\r\n private readonly _changeHistoryModalLaunchService: ChangeHistoryModalLaunchService,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _constants: Constants,\r\n private readonly _stateService: StateService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService,\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _bsModalService: BsModalService,\r\n private readonly _siteMapService: SiteMapService,\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _instanceRepository: InstanceRepository\r\n ) { }\r\n\r\n @Input() site: Site;\r\n\r\n siteForm: UntypedFormGroup;\r\n\r\n states: StateSummary[];\r\n siteId: number;\r\n companyId: number;\r\n\r\n showSpinner: boolean = true;\r\n editMode: boolean = false;\r\n hasParcelInBatch: boolean;\r\n\r\n activityStatuses = [];\r\n siteClasses = [];\r\n imageUrls: {[img: string]: string};\r\n soldDatePickerIsOpen: boolean = false;\r\n allowUserToEditEntity: boolean = false;\r\n hasStateRoles: boolean = false;\r\n hasInstancePrivatePermission: boolean;\r\n hasMoveCopyPermission: boolean;\r\n permissionsLoaded: boolean;\r\n siteNumberRequired = true;\r\n\r\n customRenderer: HelpContentComponentConfig;\r\n\r\n analyticsCategory: string = 'site';\r\n warningMessage = 'Editing is in progress. Are you sure you want to leave?';\r\n\r\n get fAccrualsExclude() { return (this.siteForm.get('accrualsExclude') as UntypedFormGroup); }\r\n\r\n get attachmentsModel(): AttachmentModalData {\r\n if (!this.site) {\r\n return null;\r\n }\r\n return {\r\n entityType: 'Site',\r\n entityName: this.site.name\r\n } as AttachmentModalData;\r\n }\r\n\r\n async ngOnInit(): Promise {\r\n this._helpService.setContent(SITE_INFO_PANEL_HELP);\r\n\r\n this.imageUrls = this._constants.ImageURLs;\r\n this.companyId = parseInt(this._routerService.getQuerystringParam('companyId'));\r\n this.siteId = parseInt(this._routerService.getQuerystringParam('siteId'));\r\n\r\n this.hasStateRoles = !this._restrictService.isNotInRoles([Roles.STATEVIEW, Roles.STATEEDIT]);\r\n\r\n this.entityEditPermissionCheck(this.siteId);\r\n\r\n this.site.transaction = this.site.transaction || {\r\n soldDate: null\r\n };\r\n this.siteNumberRequired = this.site.company.ppReturnPreparationAllowed;\r\n\r\n this.siteForm = this._fb.group({\r\n name: [this.site.name],\r\n address: this._fb.group({\r\n address1: [this.site.address.address1],\r\n address2: [this.site.address.address2],\r\n city: [this.site.address.city],\r\n stateID: [this.site.address.stateID],\r\n zip: [this.site.address.zip]\r\n }),\r\n property: [this.site.property],\r\n siteClassSecondaryID: [this.site.siteClassSecondaryID],\r\n activityStatusID: [this.site.activityStatusID],\r\n transaction: this._fb.group({\r\n soldDate: [this.site.transaction.soldDate]\r\n }),\r\n accrualsExclude: this._fb.group({\r\n excludeFromAccruals: new UntypedFormControl({ value: this.site.accrualsExclude.excludeFromAccruals, disabled: !this.editMode })\r\n })\r\n });\r\n\r\n const entityInstanceId = (await lastValueFrom(this._instanceRepository.getEntityInstanceId('site', this.site.siteID)));\r\n this.hasMoveCopyPermission = this._restrictService.hasInstanceRight(InstanceRights.ALLOWMOVECOPY, entityInstanceId);\r\n this.hasInstancePrivatePermission = this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSEDIT, entityInstanceId) || this._restrictService.hasInstanceRight(InstanceRights.PRIVATEITEMSVIEW, entityInstanceId);\r\n\r\n //only show assessor hover if user is in ryan instance\r\n this.customRenderer = this._userInstanceService.isCurrentInstanceRyan() ? {\r\n component: AssessorDetailsComponent,\r\n componentParams: {\r\n stateId: this.site.address.stateID,\r\n siteId: this.site.siteID\r\n },\r\n canHover: true\r\n } : null;\r\n\r\n this._loadActivityStatuses();\r\n this._loadSiteClasses();\r\n this._loadStates();\r\n this.showSpinner = false;\r\n }\r\n\r\n launchChangeHistoryModal(): void {\r\n this._changeHistoryModalLaunchService.openChangeHistoryModal(this.site.name, this.siteId, EntityTypeIds.SITE, null);\r\n }\r\n\r\n startEditMode(): void {\r\n this.editMode = true;\r\n if ( !this.site.accrualsExclude.parentExcludedFromAccruals )\r\n this.fAccrualsExclude.get('excludeFromAccruals').enable();\r\n else\r\n this.fAccrualsExclude.get('excludeFromAccruals').disable();\r\n this._navigationService.enableNavWarning(this.warningMessage);\r\n }\r\n\r\n cancelEditMode(): void {\r\n this.editMode = false;\r\n this.fAccrualsExclude.get('excludeFromAccruals').disable();\r\n this.siteForm.patchValue(this.site);\r\n this._navigationService.disableNavWarning();\r\n }\r\n\r\n goToMove(): void {\r\n this._routerService.go('moveSite', {\r\n companyID: this.companyId,\r\n siteID: this.siteId,\r\n isInactive: this.site.activityStatusID === Core.ActivityStatuses.Inactive\r\n });\r\n }\r\n\r\n goToCopy(): void {\r\n this._routerService.go('copySite', {\r\n companyID: this.companyId,\r\n siteID: this.siteId,\r\n isInactive: this.site.activityStatusID === Core.ActivityStatuses.Inactive\r\n });\r\n }\r\n\r\n goToAssessor(assessor: AssessorSummary): void {\r\n this._routerService.go('assessor', { stateId: this.site.address.stateID, id: assessor.assessorID });\r\n }\r\n\r\n getCommentsModalData() {\r\n return {\r\n entityTypeID: EntityTypeIds.SITE,\r\n entityID: this.site.siteID,\r\n description: `Site: ${ this.site.name}`,\r\n canEdit: this.allowUserToEditEntity\r\n };\r\n }\r\n\r\n async saveSiteToAPI(siteToSave): Promise {\r\n this.showSpinner = true;\r\n\r\n try {\r\n const savedSite = await this._siteService.update(siteToSave, this.companyId);\r\n this._navigationService.disableNavWarning();\r\n this._siteService.updateParcelList();\r\n this.site = savedSite;\r\n this._siteService.site = savedSite;\r\n this.editMode = false;\r\n this.fAccrualsExclude.get('excludeFromAccruals').disable();\r\n this.showSpinner = false;\r\n } catch(err) {\r\n this.showSpinner = false;\r\n if (err.modelState != null){\r\n err.modelState.forEach((state) => {\r\n this.toastr.error('Error!', `${state.field }: ${ state.msg}`);\r\n });\r\n }\r\n if (err.error != null){\r\n this.toastr.error('Error!', err.error.message);\r\n }\r\n }\r\n }\r\n\r\n async saveSite(): Promise {\r\n if (this.editMode) {\r\n\r\n const siteToSave = { ...this.site, ...this.siteForm.value };\r\n siteToSave.address = { ...this.site.address, ...this.siteForm.get('address').value };\r\n\r\n const isSiteNameNonAscii = siteToSave.name && !(/^[ -~\\t\\n\\r]+$/.test(siteToSave.name));\r\n if (isSiteNameNonAscii) {\r\n this.toastr.error('Site Name contains invalid character(s)');\r\n return;\r\n }\r\n const isSiteNumberNonAscii = siteToSave.property && !(/^[ -~\\t\\n\\r]+$/.test(siteToSave.property));\r\n if (isSiteNumberNonAscii) {\r\n this.toastr.error('Site Number contains invalid character(s)');\r\n return;\r\n }\r\n\r\n // keep the old one until user confirms the change\r\n // this.site.activityStatusID = this.site.activityStatusID; // TODO Umm, this is a self assignment, what is it supposed to be doing???\r\n\r\n if (siteToSave.activityStatusID !== this.site.activityStatusID) {\r\n\r\n if (siteToSave.activityStatusID === Core.ActivityStatuses.Inactive) {\r\n const checkIfEntityMayBeDeactivatedResult = await this._taskService.checkIfEntityMayBeDeactivated(siteToSave.siteID, 5);\r\n\r\n if (checkIfEntityMayBeDeactivatedResult.canBeDeactivated === false) {\r\n await this._messageBoxService.open({\r\n title: '',\r\n message: 'This site\\'s status cannot be changed to Inactive because at least some of its parcels have open appeals or refunds.',\r\n buttons: MessageBoxButtons.OK\r\n });\r\n //\tChange the value in the dropdown back to its previous value.\r\n this.siteForm.patchValue({ activityStatusID: this.site.activityStatusID });\r\n\r\n // submit button has been clicked - we need to show form again\r\n this.editMode = true;\r\n\r\n } else {\r\n if (checkIfEntityMayBeDeactivatedResult.openPaymentBatchTaskCount > 0) {\r\n await this._messageBoxService.open({\r\n title: '',\r\n message: 'This site\\'s status cannot be changed to Inactive because at least some of its batches have open payments.',\r\n buttons: MessageBoxButtons.OK\r\n });\r\n //\tChange the value in the dropdown back to its previous value.\r\n this.siteForm.patchValue({ activityStatusID: this.site.activityStatusID });\r\n }\r\n else if (checkIfEntityMayBeDeactivatedResult.openInvoiceTaskCount > 0) {\r\n await this._messageBoxService.open({\r\n title: '',\r\n message: 'This site\\'s status cannot be changed to Inactive because there are open invoice tasks',\r\n buttons: MessageBoxButtons.OK\r\n });\r\n }\r\n else {\r\n // this site doesn't have any open appeals or refunds, confirm with user\r\n let msg = 'Changing the site\\'s status to Inactive will result in all client service responsibilities being changed to N/A on the site and all of its parcels. ';\r\n msg += ` This will result in ${ checkIfEntityMayBeDeactivatedResult.openFilingTaskCount } filing task(s) `;\r\n msg += ` and ${ checkIfEntityMayBeDeactivatedResult.openAssessmentTaskCount } assessment task(s) `;\r\n msg += ` and ${ checkIfEntityMayBeDeactivatedResult.openTaxBillTaskCount } tax bill task(s) to no longer be scheduled. `;\r\n msg += ' NO FURTHER WORK OF ANY KIND WILL BE SCHEDULED FOR THIS ENTITY. ';\r\n\r\n msg += ' Are you sure you want to proceed?';\r\n\r\n const okDialogResult = await this._messageBoxService.open({\r\n title: 'Changing site\\'s status to Inactive',\r\n message: msg,\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n if (okDialogResult === MessageBoxResult.Yes) {\r\n //siteToSave.statusDate = new Date();\r\n return this.saveSiteToAPI(siteToSave);\r\n }\r\n else {\r\n // user wants to cancel\r\n //\tChange the value in the dropdown back to its previous value.\r\n this.siteForm.patchValue({ activityStatusID: this.site.activityStatusID });\r\n this.editMode = true;\r\n\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // activity status has been changed, but site is not deactivated\r\n\r\n if (this.site.activityStatusID === Core.ActivityStatuses.Inactive\r\n || ( this.site.activityStatusID === Core.ActivityStatuses.ActivePending\r\n && siteToSave.activityStatusID === Core.ActivityStatuses.Active) // Per https://weissmandemo.atlassian.net/browse/PT-3597\r\n ) {\r\n return this.saveSiteToAPI(siteToSave);\r\n }\r\n else {\r\n const okDialogResult = await this._messageBoxService.open({\r\n title: 'Changing site\\'s status',\r\n message: 'Site status changes will cascade to all of its parcels. Proceed?',\r\n buttons: MessageBoxButtons.YesNo\r\n });\r\n if (okDialogResult === MessageBoxResult.Yes) {\r\n return this.saveSiteToAPI(siteToSave);\r\n }\r\n else {\r\n // user wants to cancel\r\n //\tChange the value in the dropdown back to its previous value.\r\n this.siteForm.patchValue({ activityStatusID: this.site.activityStatusID });\r\n this.editMode = true;\r\n\r\n }\r\n }\r\n\r\n }\r\n }\r\n else {\r\n // activity status has not been changed; just saving\r\n return this.saveSiteToAPI(siteToSave);\r\n }\r\n\r\n }\r\n }\r\n\r\n async deleteSite(): Promise {\r\n const params: DeleteConfirmationComponentParams = {\r\n item: `Site ${this.site.name}`,\r\n url: `/api/site/${this.site.siteID}`,\r\n message: 'Are you sure you want to delete this site? If you choose to proceed, all information under this site (parcels, assessments, appeals, tax bills etc) will also be removed and can not be recovered.'\r\n };\r\n\r\n const result = await this._modalService.showAsync(DeleteConfirmationComponent, params, 'modal-md');\r\n\r\n if (result) {\r\n this._navigationService.disableNavWarning();\r\n\r\n this._routerService.go('company',\r\n {\r\n companyId: this.companyId\r\n });\r\n }\r\n }\r\n\r\n async launchSiteMap() {\r\n const params = {\r\n site: this.site\r\n };\r\n\r\n this._modalService.showAsync(GoogleMapsSingleMarkerModalComponent, params, 'modal-md');\r\n }\r\n\r\n getInactiveURL(): string {\r\n return `/images/${(this.site.activityStatusID === Core.ActivityStatuses.Inactive) ? 'inactive' : 'active-pending'}.jpg`;\r\n }\r\n\r\n getSiteClassName(id: number): string {\r\n if (!id || this.siteClasses.length === 0) {\r\n return;\r\n }\r\n const foundSiteClass = this.siteClasses.find((site) => site.siteClassSecondaryID === id);\r\n return foundSiteClass && foundSiteClass.name;\r\n }\r\n\r\n async entityEditPermissionCheck(id: number): Promise {\r\n const restrictionData: RestrictData = new RestrictData();\r\n restrictionData.isCompany = false;\r\n restrictionData.entityId = id;\r\n restrictionData.flag = Core.AccessRightsEnum.Write;\r\n\r\n try {\r\n const result = await this._restrictService.hasPermission(restrictionData);\r\n this.allowUserToEditEntity = result;\r\n this.permissionsLoaded = true;\r\n } catch (err) {\r\n console.log('checkEntity - error', err);\r\n }\r\n }\r\n\r\n onSoldDateChanged(value: Date): void {\r\n this.siteForm.get('transaction').get('soldDate').markAsTouched();\r\n this.siteForm.patchValue({\r\n transaction: { soldDate: (value) ? value : null}\r\n });\r\n }\r\n\r\n hasParcels(): boolean {\r\n return this._siteService.hasParcels();\r\n }\r\n\r\n getState(id: number): string {\r\n if (!this.states) { return; }\r\n const state = this.states.find((x) => x.stateID === id);\r\n return (state) ? state.abbr : '';\r\n }\r\n\r\n goToValuationTool() {\r\n window.open(this.site.valuationToolUrl as unknown as string, '_blank');\r\n }\r\n\r\n //TODO this will not work. result is a number\r\n private _processAttachmentDialogResult(result): void {\r\n if (!result) return;\r\n this.site.hasImages = result.hasImages;\r\n }\r\n\r\n private async _loadActivityStatuses(): Promise {\r\n const result = await this._activityStatusService.get();\r\n this.activityStatuses = _.sortBy(result, 'status');\r\n }\r\n\r\n private async _loadSiteClasses(): Promise {\r\n const result = await this._siteClassService.getSecondaries();\r\n\r\n this.siteClasses = _.chain(result)\r\n .map((siteClass: any) => {\r\n siteClass.name = `${siteClass.siteClassPrimary.siteClassPrimaryDesc} - ${siteClass.siteClassDesc}`;\r\n return siteClass;\r\n })\r\n .sortBy('name')\r\n .value();\r\n }\r\n\r\n private async _loadStates(): Promise {\r\n this.states = await this._stateService.getSummary();\r\n }\r\n\r\n}\r\n","
\r\n
\r\n \r\n

Assets

\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, Input } from '@angular/core';\r\n\r\n\r\n@Component({\r\n selector: 'asset-list-panel',\r\n templateUrl: './assetListPanel.component.html'\r\n})\r\nexport class AssetListPanelComponent {\r\n @Input() companyId: number;\r\n @Input() parcelId: number;\r\n @Input() siteId: number;\r\n @Input() showComplianceInfo: boolean;\r\n @Input() company: Core.CompanyModel;\r\n\r\n onLoading: boolean = true;\r\n hasViewPermission: boolean = true;\r\n showBody: boolean = false;\r\n\r\n expandOrCollapse(): void {\r\n this.showBody = !this.showBody;\r\n }\r\n}\r\n","
\r\n
\r\n \r\n

Valuation

\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, Input, ChangeDetectionStrategy } from '@angular/core';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\n\r\n\r\n@Component({\r\n selector: 'valuation-panel',\r\n templateUrl: './valuationPanel.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n})\r\nexport class ValuationPanelComponent {\r\n constructor(public featureFlagService: FeatureFlagsService) {}\r\n\r\n @Input() companyId: number;\r\n @Input() parcelId: number;\r\n @Input() siteId: number;\r\n @Input() company: Core.CompanyModel;\r\n\r\n onIncomeStatementLoading: boolean = true;\r\n onRentRollLoading: boolean = true;\r\n hasViewPermission: boolean = true;\r\n showBody: boolean = false;\r\n showIncomeStatement: boolean = true;\r\n showRentRoll: boolean = false;\r\n\r\n\r\n expandOrCollapse(): void {\r\n this.showBody = !this.showBody;\r\n }\r\n\r\n incomeStatementSelected() {\r\n this.showRentRoll = false;\r\n this.showIncomeStatement = true;\r\n }\r\n\r\n rentRollSelected() {\r\n this.showIncomeStatement = false;\r\n this.showRentRoll = true;\r\n }\r\n}\r\n","
\r\n
\r\n \r\n

Responsible Entities

\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n","import { Component, Inject, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'responsible-entity-panel',\r\n templateUrl: './responsibleEntityPanel.component.html',\r\n})\r\nexport class ResponsibleEntityPanelComponent {\r\n constructor(@Inject('$rootScope') private _rootScope: any) {\r\n }\r\n\r\n @Input() companyId: number;\r\n @Input() siteId?: number;\r\n @Input() parcelId?: number;\r\n @Input() enableAllocations: boolean;\r\n\r\n loading: boolean = true;\r\n showBody: boolean = false;\r\n isMaximized: boolean = false;\r\n\r\n expandOrCollapse(): void {\r\n if (this.isMaximized) {\r\n return;\r\n }\r\n\r\n this.showBody = !this.showBody;\r\n }\r\n\r\n onLoadingChanged(loading: any) {\r\n loading = loading as boolean;\r\n this.loading = loading;\r\n }\r\n\r\n maximize(event): void {\r\n this.isMaximized = true;\r\n this.showBody = true;\r\n this._broadcastMaximize();\r\n event.stopPropagation();\r\n }\r\n\r\n unmaximize(event): void {\r\n this.isMaximized = false;\r\n this._broadcastMaximize();\r\n event.stopPropagation();\r\n }\r\n\r\n private _broadcastMaximize(): void {\r\n this._rootScope.$broadcast('maximize_change', {\r\n panelName: 'responsibleEntityPanel',\r\n maximized: this.isMaximized\r\n });\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { ResponsibleEntityListComponent } from './Responsible-Entity-List/responsibleEntityList.component';\r\nimport { ResponsibleEntityRepository } from './responsbileEntity.repository';\r\nimport {\r\n ResponsibleEntityListGridActionCellRendererComponent\r\n} from './Responsible-Entity-List/agGridActionCellRenderer.component';\r\nimport { ResponsibleEntityDetailsComponent } from './Responsible-Entity-Details/responsibleEntityDetails.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n BusyIndicatorModule,\r\n BsDropdownModule.forRoot()\r\n ],\r\n declarations: [\r\n ResponsibleEntityListComponent,\r\n ResponsibleEntityListGridActionCellRendererComponent,\r\n ResponsibleEntityDetailsComponent\r\n ],\r\n providers: [\r\n ResponsibleEntityRepository\r\n ],\r\n exports: [\r\n ResponsibleEntityListComponent\r\n ]\r\n})\r\nexport class ResponsibleEntityModule{\r\n\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { AgGridExtensionsModule } from '../../Compliance/AgGrid/agGridExtensions.module';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { ValuationModule } from '../../Valuation/valuation.module';\r\nimport { AddParcelModalComponent } from './Parcels/Add-Parcel-Modal/addParcelModal.component';\r\nimport { FMVChangeRendererComponent } from './Parcels/agGridFMVChangeRenderer.component';\r\nimport { ParcelListPanelComponent } from './Parcels/parcelListPanel.component';\r\nimport { ParcelTileComponent } from './Parcels/Parcel-Tile/parcelTile.component';\r\nimport { PercentChangeRendererComponent } from './Parcels/agGridPercentChangeRenderer.component';\r\nimport { TotalFMVRendererComponent } from './Parcels/agGridFMVRenderer.component';\r\nimport { SiteService } from './Site.Service.upgrade';\r\nimport { SiteInfoPanelComponent } from './Info/siteInfoPanel.component';\r\nimport { ComplianceSiteModule } from '../../Compliance/Site/site.module';\r\nimport { ParcelBulkUpdateComponent } from './Parcels/Parcel-Bulk-Update/parcelBulkUpdate.component';\r\nimport { ParcelBulkUpdateActionComponent } from './Parcels/Parcel-Bulk-Update/Parcel-Bulk-Update-Action/parcelBulkUpdateAction.component';\r\nimport { ParcelListActionCellRendererComponent } from './Parcels/agGridActionCellRenderer.component';\r\nimport { ParcelIconModule } from '../Parcel/Icon/parcelIcon.module';\r\nimport { AssetListPanelComponent } from './Assets/assetListPanel.component';\r\nimport { ValuationPanelComponent } from './Valuation/valuationPanel.component';\r\nimport { AssetModule } from '../../Compliance/Asset/asset.module';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { ResponsibleEntityPanelComponent } from './Responsible-Entity/responsibleEntityPanel.component';\r\nimport { ResponsibleEntityModule } from '../../Responsible-Entity/responsibleEntity.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ReactiveFormsModule,\r\n WeissmanSharedModule,\r\n TypeaheadModule,\r\n AgGridExtensionsModule,\r\n AgGridModule,\r\n ComplianceSiteModule,\r\n ParcelIconModule,\r\n BusyIndicatorModule.forRoot(),\r\n AssetModule,\r\n TabsModule,\r\n ValuationModule,\r\n ResponsibleEntityModule\r\n ],\r\n declarations: [\r\n AddParcelModalComponent,\r\n FMVChangeRendererComponent,\r\n ParcelListPanelComponent,\r\n ParcelListActionCellRendererComponent,\r\n ParcelTileComponent,\r\n ParcelBulkUpdateComponent,\r\n ParcelBulkUpdateActionComponent,\r\n PercentChangeRendererComponent,\r\n TotalFMVRendererComponent,\r\n SiteInfoPanelComponent,\r\n AssetListPanelComponent,\r\n ValuationPanelComponent,\r\n ResponsibleEntityPanelComponent\r\n ],\r\n providers: [\r\n SiteService\r\n ],\r\n exports: [\r\n ParcelListPanelComponent\r\n ]\r\n})\r\nexport class SiteModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Provider('sd.Site.Service', SiteService);\r\n hybridAdapterUtility.downgradeNg2Component('siteInfoPanel', SiteInfoPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Component('parcelListPanel', ParcelListPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Component('assetListPanel', AssetListPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Component('valuationPanel', ValuationPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Component('responsibleEntityPanel', ResponsibleEntityPanelComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { GoogleMapsModule } from '@angular/google-maps';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { SiteModule } from './Site/site.module';\r\nimport { EntityService } from './entity.service';\r\nimport { AssessorDetailsComponent } from './Assessor-Details/assessorDetails.component';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { ParcelIconModule } from './Parcel/Icon/parcelIcon.module';\r\nimport { CompanyModule } from './Company/company.module';\r\nimport { TaxFeedSettingRepository } from './taxFeedSettingRepository';\r\nimport { MoveCopyEntityComponent } from './move.copy.entity.component';\r\nimport { MoveCopyEntityService } from './move.copy.entity.service';\r\nimport { SiteMapComponent } from './site.map.component';\r\nimport { SiteMapService } from './site.map.service';\r\nimport { SiteMapInfoWindowComponent } from './site.map.info.window.component';\r\nimport { AccountingPeriodsModalComponent } from './Company/Company-Settings/Accounting-Periods/accounting.periods.modal.component';\r\nimport { AccountingPeriodsService } from './Company/Company-Settings/Accounting-Periods/accounting.periods.service';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n GoogleMapsModule,\r\n SiteModule,\r\n CompanyModule\r\n ],\r\n declarations: [\r\n AssessorDetailsComponent,\r\n MoveCopyEntityComponent,\r\n SiteMapComponent,\r\n SiteMapInfoWindowComponent,\r\n AccountingPeriodsModalComponent\r\n ],\r\n providers: [\r\n EntityService,\r\n TaxFeedSettingRepository,\r\n MoveCopyEntityService,\r\n SiteMapService,\r\n AccountingPeriodsService\r\n ],\r\n exports: [\r\n MoveCopyEntityComponent,\r\n SiteMapComponent\r\n ]\r\n})\r\nexport class EntityModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Provider('ng2EntityService', EntityService);\r\n hybridAdapterUtility.downgradeNg2Component('moveCopyEntity', MoveCopyEntityComponent);\r\n hybridAdapterUtility.downgradeNg2Component('siteMap', SiteMapComponent);\r\n\r\n SiteModule.setupModule();\r\n ParcelIconModule.setupModule();\r\n CompanyModule.setupModule();\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { UIRouterUpgradeModule } from '@uirouter/angular-hybrid';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { LogoutMessageComponent } from './logoutMessage.component';\r\nimport { NavigationModalsModule } from '../Navigation/User-Save/Modals/navigationModals.module';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n UIRouterUpgradeModule,\r\n NavigationModalsModule\r\n ],\r\n declarations: [\r\n LogoutMessageComponent\r\n ],\r\n exports: [\r\n LogoutMessageComponent\r\n ]\r\n})\r\nexport class LayoutModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('logoutMessage', LogoutMessageComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { CompanyModule } from '../Company/company.module';\r\nimport { AddInstanceModalComponent } from './Add/addInstanceModal.component';\r\nimport { InstanceInfoPanelComponent } from './Info/instanceInfoPanel.component';\r\nimport { InstanceRepository } from './instance.repository';\r\nimport { ManageInvitationsComponent } from './manageInvitations.component';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n CompanyModule,\r\n TypeaheadModule\r\n ],\r\n declarations: [\r\n AddInstanceModalComponent,\r\n ManageInvitationsComponent,\r\n InstanceInfoPanelComponent,\r\n ],\r\n providers: [\r\n InstanceRepository\r\n ]\r\n})\r\n\r\nexport class InstanceModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('manageInvitations', ManageInvitationsComponent);\r\n hybridAdapterUtility.downgradeNg2Component('instanceInfoPanel', InstanceInfoPanelComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { ConsultingEngagementModalComponent } from './consultingEngagementModal.component';\r\nimport { CompanyContractsModalComponent } from './CompanyContracts/companyContractsModal.component';\r\nimport { ConsultingEngagementsComponent } from './consultingEngagements.component';\r\nimport { ConsultingEngagementsRepository } from './consultingEngagements.repository';\r\nimport { InstanceRightsListComponent } from './CompanyContracts/instanceRightsList.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule\r\n ],\r\n declarations: [\r\n ConsultingEngagementsComponent,\r\n ConsultingEngagementModalComponent,\r\n CompanyContractsModalComponent,\r\n InstanceRightsListComponent,\r\n ],\r\n providers: [\r\n ConsultingEngagementsRepository\r\n ]\r\n})\r\n\r\nexport class ConsultingModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('consultingEngagements', ConsultingEngagementsComponent);\r\n hybridAdapterUtility.downgradeNg2Component('consultingEngagementModal', ConsultingEngagementModalComponent);\r\n hybridAdapterUtility.downgradeNg2Component('instanceRightsList', InstanceRightsListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('companyContractsModal', CompanyContractsModalComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { CsrCommandCenterComponent } from './csrCommandCenter.component';\r\nimport { CsrCommandCenterService } from './csrCommandCenter.service';\r\nimport {CsrCommandCenterRepository} from './csrCommandCenter.repository';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridExtensionsModule } from '../../Compliance/AgGrid/agGridExtensions.module';\r\nimport { ReportingModule } from '../../Reporting/reporting.module';\r\nimport { CsrBulkUpdateComponent } from './Bulk-Update/csrBulkUpdate.component';\r\nimport { CsrUpdateStatusCellRendererComponent } from './agGridCsrUpdateStatusCellRenderer.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n AgGridModule.withComponents({\r\n CsrUpdateStatusCellRendererComponent\r\n }),\r\n AgGridExtensionsModule,\r\n ReportingModule,\r\n ],\r\n declarations: [\r\n CsrCommandCenterComponent,\r\n CsrBulkUpdateComponent,\r\n CsrUpdateStatusCellRendererComponent,\r\n ],\r\n providers: [\r\n CsrCommandCenterService,\r\n CsrCommandCenterRepository\r\n ],\r\n exports: [\r\n CsrCommandCenterComponent,\r\n CsrBulkUpdateComponent\r\n ]\r\n})\r\nexport class CsrCommandCenterModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('csrCommandCenter', CsrCommandCenterComponent);\r\n }\r\n}\r\n","
\r\n
3\"\r\n class=\"select-all checkbox py-1 px-3 my-0 position-sticky\"\r\n helpTooltip\r\n [helpContentId]=\"helpContentId\"\r\n [helpDisabled]=\"helpDisabled\">\r\n \r\n
\r\n
\r\n \r\n
\r\n
\r\n","import { Component, forwardRef, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\n\r\nexport interface CheckboxList {\r\n label: string;\r\n value: any;\r\n checked: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'checkbox-list',\r\n templateUrl: './checkboxList.component.html',\r\n styleUrls: ['./checkboxList.component.scss'],\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => CheckboxListComponent),\r\n multi: true\r\n }\r\n ],\r\n})\r\nexport class CheckboxListComponent implements ControlValueAccessor {\r\n @Input() helpContentId: string;\r\n @Input() helpDisabled: boolean;\r\n\r\n value: CheckboxList[];\r\n disabled: boolean;\r\n\r\n get isAllChecked(): boolean {\r\n const selectedCount = this.value ? this.value.filter(item => item.checked).length : 0;\r\n if(selectedCount === 0) {\r\n return false;\r\n } else if (selectedCount === this.value.length) {\r\n return true;\r\n } else {\r\n return null;\r\n }\r\n }\r\n\r\n private onChange: (val: CheckboxList[]) => void = (val) => { return null; };\r\n private onTouched: () => void = () => { return null; };\r\n\r\n writeValue(value: CheckboxList[]): void {\r\n this.value = value;\r\n }\r\n\r\n setDisabledState(disabled: boolean): void {\r\n this.disabled = disabled;\r\n }\r\n\r\n next(): void {\r\n this.onChange(this.value);\r\n this.onTouched();\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouched = fn;\r\n }\r\n\r\n selectAll(): void {\r\n const isAllChecked = this.isAllChecked;\r\n this.value.forEach(item => {\r\n item.checked = !isAllChecked;\r\n });\r\n this.next();\r\n }\r\n\r\n checkChanged(checked: boolean, item: CheckboxList): void {\r\n item.checked = checked;\r\n this.next();\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { AssetClassSelectorModule } from '../Compliance/Asset/Asset-Class-Selector/assetClassSelector.module';\r\nimport { CheckboxListComponent } from './Tax-Authority/Allowed-Exemption-List/checkboxList.component';\r\nimport { TaxRateAreaComponent } from './Tax-Rate-Area/tax.rate.area.component';\r\nimport { TaxAuthorityComponent } from './Tax-Authority/tax.authority.component';\r\nimport { AddTaxEntityModalComponent } from '../Assessor-Collector/Tax-Rates/add.tax.entity.modal.component';\r\nimport { AddTaxYearModalComponent } from './Tax-Authority/add.tax.year.modal.component';\r\nimport { TaxRateCommandCenterComponent } from './Command-Center/tax.rate.command.center.component';\r\nimport { ShowTaxYearComponent } from './show.tax.year.component';\r\nimport { TaxAuthorityBulkUpdateComponent } from './Command-Center/Tax-Authority-Bulk-Update/tax.authority.bulk.update.component';\r\nimport { TaxAuthorityBulkUpdateActionComponent } from './Command-Center/Tax-Authority-Bulk-Update/tax.authority.bulk.update.action.component';\r\nimport { TaxRateCommandCenterCommentsCellRendererComponent } from './Command-Center/agGridCommentsCellRenderer.component';\r\nimport { TaxRateCommandCenterAttachmentsCellRendererComponent } from './Command-Center/agGridAttachmentsCellRenderer.component';\r\nimport { TaxRateQcByCellRendererComponent } from './agGridQcByCellRenderer.component';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n AssetClassSelectorModule\r\n ],\r\n declarations: [\r\n TaxRateAreaComponent,\r\n TaxAuthorityComponent,\r\n AddTaxEntityModalComponent,\r\n AddTaxYearModalComponent,\r\n TaxRateCommandCenterComponent,\r\n ShowTaxYearComponent,\r\n TaxAuthorityBulkUpdateComponent,\r\n TaxAuthorityBulkUpdateActionComponent,\r\n TaxRateCommandCenterCommentsCellRendererComponent,\r\n TaxRateCommandCenterAttachmentsCellRendererComponent,\r\n TaxRateQcByCellRendererComponent,\r\n CheckboxListComponent\r\n ],\r\n exports: [\r\n TaxRateAreaComponent,\r\n TaxAuthorityComponent,\r\n TaxRateCommandCenterComponent,\r\n ShowTaxYearComponent\r\n ]\r\n})\r\nexport class TaxRateModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('taxRateArea', TaxRateAreaComponent);\r\n hybridAdapterUtility.downgradeNg2Component('taxAuthority', TaxAuthorityComponent);\r\n hybridAdapterUtility.downgradeNg2Component('taxRateCommandCenter', TaxRateCommandCenterComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { TaxRateModule } from '../../Tax-Rate/tax.rate.module';\r\nimport { TaxRatesPanelTaxAuthoritiesCellRendererComponent } from './agGridTaxAuthoritiesCellRenderer.component';\r\nimport { TaxRatesPanelComponent } from './tax.rates.panel.component';\r\nimport { TaxRatesPanelService } from './tax.rates.panel.service';\r\nimport { TaxRatesService } from './tax.rates.service';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n TaxRateModule\r\n ],\r\n declarations: [\r\n TaxRatesPanelComponent,\r\n TaxRatesPanelTaxAuthoritiesCellRendererComponent,\r\n ],\r\n providers: [\r\n TaxRatesPanelService,\r\n TaxRatesService\r\n ],\r\n exports: [TaxRatesPanelComponent]\r\n})\r\nexport class TaxRatesPanelModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('taxRatesPanel', TaxRatesPanelComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { TaxingDistrictComponent } from './taxingDistrict.component';\r\nimport { TaxingDistrictListComponent } from './Taxing-District-List/taxingDistrictList.component';\r\nimport { TaxingDistrictListGridActionCellRendererComponent } from './Taxing-District-List/agGridActionCellRenderer.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n WeissmanSharedModule\r\n ],\r\n declarations: [\r\n TaxingDistrictComponent,\r\n TaxingDistrictListComponent,\r\n TaxingDistrictListGridActionCellRendererComponent\r\n ],\r\n exports: [\r\n TaxingDistrictComponent,\r\n TaxingDistrictListComponent\r\n ]\r\n})\r\nexport class TaxingDistrictModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('taxingDistrict', TaxingDistrictComponent);\r\n hybridAdapterUtility.downgradeNg2Component('taxingDistrictList', TaxingDistrictListComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { DeadlineListPanelComponent } from '../AppealDeadline/Panel/deadlineListPanel.component';\r\nimport { AssessmentClassListPanelComponent } from '../Assessment-Class/List/assessmentClassListPanel.component';\r\nimport { AssessmentClassModalComponent } from '../Assessment-Class/View/assessmentClassModal.component';\r\nimport { ProtocolListPanelComponent } from '../Protocols/protocolListPanel.component';\r\nimport { AssessorExceptionsModalComponent } from '../AppealDeadline/Assessor-Exceptions/assessorExceptionsModal.component';\r\nimport { DeadlineService } from '../AppealDeadline/deadline.service';\r\nimport { AssessmentClassService } from '../Assessment-Class/assessmentClass.service';\r\nimport { ProtocolService } from '../Protocols/protocol.service';\r\nimport { StateAssessorExceptionsModalComponent } from '../Protocols/stateAssessorExceptionsModal.component';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n BsDropdownModule\r\n ],\r\n declarations: [\r\n DeadlineListPanelComponent,\r\n AssessmentClassListPanelComponent,\r\n AssessmentClassModalComponent,\r\n ProtocolListPanelComponent,\r\n AssessorExceptionsModalComponent,\r\n StateAssessorExceptionsModalComponent\r\n ],\r\n providers: [\r\n DeadlineService,\r\n AssessmentClassService,\r\n ProtocolService\r\n ],\r\n exports: [\r\n DeadlineListPanelComponent,\r\n AssessmentClassListPanelComponent,\r\n AssessmentClassModalComponent,\r\n ProtocolListPanelComponent,\r\n AssessorExceptionsModalComponent,\r\n StateAssessorExceptionsModalComponent\r\n ]\r\n})\r\nexport class StateAssessorSharedModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { TaxRatesPanelModule } from '../Tax-Rates/taxRatesPanel.module';\r\nimport { CommentsModule } from '../../Comments/comments.module';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { TaxingDistrictModule } from '../Taxing-District/taxingDistrict.module';\r\nimport { StateAssessorSharedModule } from '../../State/stateAssessorShared.module';\r\nimport { AssessorInfoComponent } from './Assessor-Info/assessor.info.component';\r\nimport { AssessorAvailableCollectorsComponent } from './Assessor-Available-Collectors/assessor.available.collectors.component';\r\nimport { ContactModule } from '../../Contact/contact.module';\r\nimport { PropertyCharacteristicsModule } from '../../Property-Characteristics/propertyCharacteristics.module';\r\nimport { AssessorComponent } from './assessor.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n CommentsModule,\r\n TaxingDistrictModule,\r\n StateAssessorSharedModule,\r\n ContactModule,\r\n PropertyCharacteristicsModule,\r\n TaxRatesPanelModule\r\n ],\r\n declarations: [\r\n AssessorComponent,\r\n AssessorInfoComponent,\r\n AssessorAvailableCollectorsComponent\r\n ]\r\n})\r\nexport class AssessorModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('assessor', AssessorComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { TaxRatesPanelModule } from '../Tax-Rates/taxRatesPanel.module';\r\nimport { CollectorDetailsComponent } from './Collector-Details/collectorDetails.component';\r\nimport { CollectorComponent } from './collector.component';\r\nimport { CommentsModule } from '../../Comments/comments.module';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { BillingScenarioModalComponent } from './Billing-Scenario/New-Scenario/billingScenarioModal.component';\r\nimport { BillingScenarioService } from './Billing-Scenario/billingScenario.service';\r\nimport { BillingScenarioRepository } from '../../Core-Repositories/billingScenario.repository';\r\nimport { BillingScenarioComponent } from './Billing-Scenario/billingScenario.component';\r\nimport { HelpModule } from '../../UI-Lib/Help-Tooltip/help.module';\r\nimport { CollectorProtocolsComponent } from './Protocols/collectorProtocols.component';\r\nimport { ContactModule } from '../../Contact/contact.module';\r\nimport { PropertyCharacteristicsModule } from '../../Property-Characteristics/propertyCharacteristics.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n WeissmanSharedModule,\r\n CommentsModule,\r\n SharedPipesModule,\r\n HelpModule,\r\n ContactModule,\r\n TaxRatesPanelModule,\r\n PropertyCharacteristicsModule\r\n ],\r\n declarations: [\r\n CollectorComponent,\r\n CollectorDetailsComponent,\r\n BillingScenarioComponent,\r\n BillingScenarioModalComponent,\r\n CollectorProtocolsComponent\r\n ],\r\n providers: [\r\n BillingScenarioService,\r\n BillingScenarioRepository\r\n ],\r\n exports: [\r\n CollectorComponent,\r\n BillingScenarioComponent,\r\n CollectorProtocolsComponent\r\n ]\r\n})\r\nexport class CollectorModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('collector', CollectorComponent);\r\n hybridAdapterUtility.downgradeNg2Component('billingScenario', BillingScenarioComponent);\r\n hybridAdapterUtility.downgradeNg2Component('collectorProtocols', CollectorProtocolsComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('sd.Bill.Scenario.Service', BillingScenarioService);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { AssessorCollectorService } from './assessor.collector.service';\r\nimport { AssessorCollectorRepository } from '../Core-Repositories';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { AssessorModule } from './Assessor/assessor.module';\r\nimport { CollectorModule } from './Collector/collector.module';\r\nimport { AssessorListComponent } from './List/assessorList.component';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { AddAssessorModalComponent } from './List/addAssessorModal.component';\r\nimport { TaxRatesPanelModule } from './Tax-Rates/taxRatesPanel.module';\r\nimport { TaxingDistrictModule } from './Taxing-District/taxingDistrict.module';\r\nimport { AddCollectorModalComponent } from './Add/Collector/addCollectorModal.component';\r\nimport { CollectorListComponent } from './List/collectorList.component';\r\nimport { AlphabetizedListComponent } from './alphabetizedList.component';\r\n\r\n@NgModule({\r\n imports: [\r\n AssessorModule,\r\n CollectorModule,\r\n TaxingDistrictModule,\r\n WeissmanSharedModule,\r\n ],\r\n declarations: [\r\n AssessorListComponent,\r\n AddAssessorModalComponent,\r\n CollectorListComponent,\r\n AddCollectorModalComponent,\r\n AlphabetizedListComponent\r\n ],\r\n providers: [\r\n AssessorCollectorService,\r\n AssessorCollectorRepository\r\n ],\r\n exports: []\r\n})\r\nexport class AssessorCollectorModule {\r\n static setupModule(): void {\r\n AssessorModule.setupModule();\r\n CollectorModule.setupModule();\r\n TaxingDistrictModule.setupModule();\r\n TaxRatesPanelModule.setupModule();\r\n\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Provider('sd.Assessor.Collector.Service', AssessorCollectorService);\r\n hybridAdapterUtility.downgradeNg2Component('assessorList', AssessorListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('collectorList', CollectorListComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { SmartSearchComponent } from './smartSearch.component';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { AgGridExtensionsModule } from '../../Compliance/AgGrid/agGridExtensions.module';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { SmartSearchService } from './smartSearch.service';\r\nimport { AdvancedSearchListComponent } from './Advanced-Search-List/advancedSearchList.component';\r\nimport { AdvancedSearchComponent } from './Advanced-Search/advancedSearch.component';\r\nimport { AdvancedSearchBulkUpdateComponent } from './Advanced-Search-List/Bulk-Update/advancedSearchBulkUpdate.component';\r\nimport { SaveSearchModalComponent } from './Save-Search-Modal/saveSearchModal.component';\r\nimport { AdvancedSearchColumnBuilder } from './Advanced-Search-List/advancedSearchColumnBuilder.service';\r\nimport { AdvancedSearchRepository } from '../../Core-Repositories';\r\nimport { FilterListComponent } from './Advanced-Search/Filter-List/filterList.component';\r\nimport { OutputListComponent } from './Advanced-Search/Output-List/outputList.component';\r\nimport { SiteModule } from '../../Entity/Site/site.module';\r\nimport { DragAndDropListModule } from '../../UI-Lib/Directives/Drag-And-Drop-List/dragAndDropList.module';\r\nimport { AdvancedSearchListService } from './Advanced-Search-List/advancedSearchList.service';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n AgGridExtensionsModule,\r\n AgGridModule,\r\n SiteModule,\r\n DragAndDropListModule,\r\n BusyIndicatorModule.forRoot()\r\n ],\r\n declarations: [\r\n SmartSearchComponent,\r\n AdvancedSearchComponent,\r\n AdvancedSearchListComponent,\r\n AdvancedSearchBulkUpdateComponent,\r\n SaveSearchModalComponent,\r\n FilterListComponent,\r\n OutputListComponent\r\n ],\r\n providers: [\r\n SmartSearchService,\r\n AdvancedSearchColumnBuilder,\r\n AdvancedSearchRepository,\r\n AdvancedSearchListService\r\n ],\r\n exports: [SmartSearchComponent]\r\n})\r\nexport class SmartSearchModule {\r\n static setupModule(): void {\r\n hybridAdapterUtility.downgradeNg2Provider('advancedSearchService', SmartSearchService);\r\n hybridAdapterUtility.downgradeNg2Component('smartSearch', SmartSearchComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { AppealApplicationComponent } from './appealApplication.component';\r\nimport { AppealApplicationListComponent } from './Appeal-Application-List/appealApplicationList.component';\r\nimport { AppealApplicationService } from './appeal.application.service';\r\nimport { AppealApplicationViewerComponent } from './PDF-Viewer/appealApplicationViewer.component';\r\nimport { AppealApplicationSettingsComponent } from './Appeal-Application-Settings/appeal.application.settings.component';\r\nimport { AppealApplicationSetTopModalComponent } from './Set-Top-Modal/appealApplicationSetTopModal.component';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { ScrollingModule } from '@angular/cdk/scrolling';\r\nimport { DownloadAppealFormComponent } from './Appeal-Application-List/Download-Appeal-Form/downloadAppealForm.component';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { AppealApplicationRepository } from '../Core-Repositories';\r\nimport { AdditionalAccountTooltipComponent } from './Appeal-Application-List/Additional-Account-Tooltip/additionalAccountTooltip.component';\r\nimport { EditAppealSupplementAssociationsComponent } from './Appeal-Application-List/Edit-Appeal-Associations/editAppealSupplementAssociations.component';\r\nimport { EditAppealMainAssociationsComponent } from './Appeal-Application-List/Edit-Appeal-Associations/editAppealMainAssociations.component';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n BusyIndicatorModule,\r\n TabsModule,\r\n ScrollingModule,\r\n BsDropdownModule.forRoot()\r\n ],\r\n declarations: [\r\n AppealApplicationComponent,\r\n AppealApplicationListComponent,\r\n AppealApplicationViewerComponent,\r\n AppealApplicationSettingsComponent,\r\n AppealApplicationSetTopModalComponent,\r\n DownloadAppealFormComponent,\r\n EditAppealSupplementAssociationsComponent,\r\n AdditionalAccountTooltipComponent,\r\n EditAppealMainAssociationsComponent\r\n ],\r\n providers: [\r\n AppealApplicationService,\r\n AppealApplicationRepository\r\n ],\r\n exports: [AppealApplicationComponent]\r\n})\r\nexport class AppealApplicationModule {\r\n static setupModule(): void {\r\n hybridAdapterUtility.downgradeNg2Component('appealApplication', AppealApplicationComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('appealApplicationService', AppealApplicationService);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { CommentsModule } from '../Comments/comments.module';\r\nimport { UnitedStatesComponent } from './states.component';\r\nimport { USStateComponent } from './us.state.component';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { StateService } from '../Common/States/States.Service';\r\nimport { StateAssessorSharedModule } from './stateAssessorShared.module';\r\nimport { TypeaheadModule } from 'ngx-bootstrap/typeahead';\r\nimport { StateDetailsComponent } from './State-Details/state.details.component';\r\nimport { ContactModule } from '../Contact/contact.module';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n CommentsModule,\r\n StateAssessorSharedModule,\r\n ContactModule,\r\n TypeaheadModule\r\n ],\r\n declarations: [\r\n UnitedStatesComponent,\r\n USStateComponent,\r\n StateDetailsComponent\r\n ],\r\n providers: [StateService]\r\n})\r\nexport class StateModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('usState', USStateComponent);\r\n hybridAdapterUtility.downgradeNg2Component('unitedStates', UnitedStatesComponent);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { BusyIndicatorModule } from 'src/app/Busy-Indicator';\r\nimport { WeissmanSharedModule } from 'src/app/Common/weissman-shared.module';\r\nimport { ModalWrapperModule } from 'src/app/UI-Lib/Modal-Wrapper/modalWrapper.module';\r\nimport { AccountModule } from '../account.module';\r\nimport { LoginComponent } from './login.component';\r\nimport { LoginService } from './login.service';\r\n\r\nimport { TermsAndConditionsModalComponent } from './termsAndConditionsModal.component';\r\n\r\n@NgModule({\r\n imports: [\r\n ModalWrapperModule,\r\n WeissmanSharedModule,\r\n BusyIndicatorModule,\r\n AccountModule\r\n ],\r\n exports: [LoginComponent],\r\n declarations: [\r\n LoginComponent,\r\n TermsAndConditionsModalComponent\r\n ],\r\n providers: [LoginService],\r\n})\r\nexport class LoginModule { }\r\n","import { NgModule } from '@angular/core';\r\nimport { SupportInstanceListComponent } from './Support-Instance-List/supportInstanceList.component';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { SupportInstanceRepository } from '../Compliance/Repositories/supportInstance.repository';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport {\r\n SupportInstanceRequestAccessComponent\r\n} from './Support-Instance-Request-Access/supportInstanceRequestAccess.component';\r\n\r\nimport {\r\n SupportInstanceDeactivateInstancePendingComponent\r\n} from './Support-Instance-Deactivate-Instance-Pending/supportInstanceDeactivateInstancePending.component';\r\n\r\nimport {\r\n SupportInstanceDeactivateInstanceConfirmComponent\r\n} from './Support-Instance-Deactivate-Instance-Confirm/supportInstanceDeactivateInstanceConfirm.component';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n BusyIndicatorModule\r\n ],\r\n declarations: [\r\n SupportInstanceListComponent,\r\n SupportInstanceRequestAccessComponent,\r\n SupportInstanceDeactivateInstancePendingComponent,\r\n SupportInstanceDeactivateInstanceConfirmComponent\r\n ],\r\n providers: [\r\n SupportInstanceRepository\r\n ]\r\n})\r\nexport class SupportInstanceModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('supportInstanceList', SupportInstanceListComponent);\r\n }\r\n}\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { AbstractControl, UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';\r\nimport * as _ from 'lodash';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { UserGroupsService } from '../../userGroup.service';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { FeatureFlagsService } from '../../../Common/FeatureFlags/feature-flags-service';\r\nimport { RyanInstanceId } from '../../../constants.new';\r\nimport { UserInstanceService } from '../../../User/userInstance.service';\r\nimport { UserGroupPanel } from '../userGroupDetail.component';\r\n\r\nenum UserGroupPermissions {\r\n View = 'View',\r\n Edit = 'Edit',\r\n None = 'None'\r\n}\r\n@Component({\r\n selector: 'user-group-info',\r\n templateUrl: './userGroupInfo.component.html'\r\n})\r\nexport class UserGroupInfoComponent implements OnInit {\r\n constructor(\r\n private readonly _fb: UntypedFormBuilder,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _userGroupsService: UserGroupsService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _featureFlagService: FeatureFlagsService,\r\n private readonly _userInstanceService: UserInstanceService\r\n ) { }\r\n\r\n @Input() userGroup: Core.GroupModel;\r\n @Input() canEdit: boolean;\r\n @Output() expandClicked: EventEmitter = new EventEmitter();\r\n\r\n editMode: boolean = false;\r\n canEnterEditMode: boolean = true;\r\n infoForm: UntypedFormGroup;\r\n isExpanded: boolean = false;\r\n permissionOptions: string[] = Object.values(UserGroupPermissions);\r\n canUncheckIsConsultantGroup: boolean;\r\n showSupportGroupCheckbox: boolean;\r\n showDocumentsGroupCheckbox: boolean;\r\n\r\n private _initialValues: AbstractControl;\r\n\r\n async ngOnInit(): Promise {\r\n this._initForm();\r\n }\r\n\r\n edit() {\r\n this.infoForm.enable();\r\n if (!this.canUncheckIsConsultantGroup){\r\n this.infoForm.controls['isConsultantGroup'].disable();\r\n }\r\n this._userGroupsService.setPanelEdit(true);\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n }\r\n\r\n cancel() {\r\n this.infoForm.reset(this._initialValues);\r\n this._exitEditMode();\r\n }\r\n\r\n async onSubmit() {\r\n _.assign(this.userGroup, _.omit(this.infoForm.value, 'defaultPermission'));\r\n this.userGroup.grantReadToNewCompanies = this.infoForm.value.defaultPermission !== UserGroupPermissions.None;\r\n this.userGroup.grantWriteToNewCompanies = this.infoForm.value.defaultPermission === UserGroupPermissions.Edit;\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Updating Group Info' });\r\n try {\r\n await this._userGroupsService.update(this.userGroup as Core.GroupModel);\r\n this._initialValues = this.infoForm.value;\r\n this._exitEditMode();\r\n } catch (e2) {\r\n if (e2 && e2.status !== 422) {\r\n return Promise.reject(e2);\r\n }\r\n }\r\n finally {\r\n await busyRef.hide();\r\n }\r\n }\r\n\r\n expandComponent() {\r\n this.expandClicked.emit('userGroupInfo');\r\n this.isExpanded = true;\r\n }\r\n\r\n collapseComponent() {\r\n this.expandClicked.emit('userGroupInfo');\r\n this.isExpanded = false;\r\n }\r\n\r\n private _initForm() {\r\n this.canUncheckIsConsultantGroup = !this.userGroup.isConsultantGroup || !this.userGroup.consultingEngagementsCount;\r\n this.showDocumentsGroupCheckbox = this._featureFlagService.featureFlags.enableLicensedDocumentIntakeAndProcessing &&\r\n this._userInstanceService.RyanInstanceId === this._userInstanceService.getSelectedInstance().instanceId;\r\n\r\n //support group checkbox settings\r\n this.showSupportGroupCheckbox = this.userGroup.instanceID !== RyanInstanceId;\r\n\r\n this.infoForm = this._fb.group({\r\n name: [this.userGroup.name, Validators.required],\r\n description: [this.userGroup.description],\r\n grantReadToNewCompanies: [this.userGroup.grantReadToNewCompanies],\r\n grantWriteToNewCompanies: [this.userGroup.grantWriteToNewCompanies],\r\n defaultPermission: [this._getDefaultPermission()],\r\n isConsultantGroup: [this.userGroup.isConsultantGroup],\r\n isSupportGroup: [this.userGroup.isSupportGroup],\r\n isDocumentsGroup: [this.userGroup.isDocumentsGroup]\r\n });\r\n\r\n this._initialValues = this.infoForm.value;\r\n this.infoForm.disable();\r\n }\r\n\r\n\r\n get isConsultantGroupTitle(): string {\r\n return this.infoForm.enabled && !this.canUncheckIsConsultantGroup\r\n ? 'User group assigned to one or more consulting engagements.'\r\n : '';\r\n }\r\n\r\n private _getDefaultPermission() {\r\n if(this.userGroup.grantWriteToNewCompanies) {\r\n return UserGroupPermissions.Edit;\r\n } else if (this.userGroup.grantReadToNewCompanies) {\r\n return UserGroupPermissions.View;\r\n } else {\r\n return UserGroupPermissions.None;\r\n }\r\n }\r\n\r\n private _exitEditMode(): void {\r\n this.infoForm.disable();\r\n this._userGroupsService.setPanelEdit(false);\r\n this._navigationService.disableNavWarning();\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpInterceptor, HttpHandler, HttpRequest, HttpEvent, HttpErrorResponse } from '@angular/common/http';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { catchError } from 'rxjs/operators';\r\n\r\n@Injectable()\r\nexport class BlobErrorHttpInterceptor implements HttpInterceptor {\r\n public intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n return next.handle(req).pipe(\r\n catchError(err => {\r\n if (err instanceof HttpErrorResponse && err.error instanceof Blob && err.error.type === 'application/json') {\r\n // https://github.com/angular/angular/issues/19888\r\n // When request of type Blob, the error is also in Blob instead of object of the json data\r\n return new Promise((resolve, reject) => {\r\n const reader = new FileReader();\r\n reader.onload = (e: Event) => {\r\n try {\r\n const errmsg = JSON.parse((e.target).result);\r\n reject(new HttpErrorResponse({\r\n error: errmsg,\r\n headers: err.headers,\r\n status: err.status,\r\n statusText: err.statusText,\r\n url: err.url || undefined\r\n }));\r\n } catch (error) {\r\n reject(err);\r\n }\r\n };\r\n reader.onerror = (e) => {\r\n reject(err);\r\n };\r\n reader.readAsText(err.error);\r\n });\r\n }\r\n return throwError(err);\r\n })\r\n );\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { HybridAdapterUtility } from '../../Hybrid/hybrid-adapter.utility';\r\nimport { DatabaseRepository } from './database.repository';\r\nimport { ProcessListComponent } from './Process-List/processList.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WeissmanSharedModule } from '../../Common/weissman-shared.module';\r\nimport { SharedPipesModule } from '../../UI-Lib/Pipes/shared-pipes.module';\r\nimport { BusyIndicatorModule } from '../../Busy-Indicator';\r\nimport { AgGridExtensionsModule } from '../../Compliance/AgGrid/agGridExtensions.module';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { AgGridLoadingOverlayComponent } from '../../Common/AgGrid/agGridLoadingOverlay.component';\r\nimport {\r\n ErrorLogListGridActionCellRendererComponent\r\n} from '../Error-Log/Error-Log-List/agGridActionCellRenderer.component';\r\nimport {\r\n DatabaseProcessListGridActionCellRendererComponent\r\n} from './Process-List/agGridActionCellRenderer.component';\r\nimport { DatabaseClearCacheEntryComponent } from './Database-Clear-Cache-Entry/databaseClearCacheEntry.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n WeissmanSharedModule,\r\n SharedPipesModule,\r\n BusyIndicatorModule.forRoot(),\r\n AgGridExtensionsModule,\r\n AgGridModule.withComponents([\r\n // shared\r\n AgGridLoadingOverlayComponent,\r\n ErrorLogListGridActionCellRendererComponent\r\n ])\r\n ],\r\n declarations: [\r\n ProcessListComponent,\r\n DatabaseProcessListGridActionCellRendererComponent,\r\n DatabaseClearCacheEntryComponent\r\n ],\r\n providers: [\r\n DatabaseRepository\r\n ],\r\n exports: []\r\n})\r\nexport class DatabaseModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n hybridAdapterUtility.downgradeNg2Component('databaseProcessList', ProcessListComponent);\r\n }\r\n}\r\n","
\r\n
\r\n

\r\n Company Permissions\r\n \r\n

\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n","import { OnInit, Input, Component, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { GridApi, GridOptions, GridReadyEvent, ColDef, ValueGetterParams } from 'ag-grid-community';\r\nimport { AgGridOptionsBuilder, AgGridColumns, AgGridFilterParams, AgGridDropdownCellEditor } from '../../../Compliance/AgGrid';\r\nimport { DropdownCellEditorParams } from '../../../Compliance/AgGrid/CellEditors/agGridDropdownCellEditor.component';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { UserInstanceService } from '../../../User/userInstance.service';\r\nimport { PermissionService } from '../../permission.service';\r\nimport { CompanyPermissionAddComponent, CompanyPermissionAddParams } from '../Add/companyPermissionAdd.component';\r\nimport { CompanyPermissionAgGridDataSource, CompanyPermissionDataSourceParams } from './agGridDataSource';\r\nimport { CompanyPermissionOptions } from './CompanyPermissionOptions';\r\nimport { CompanyPermissionsGridActionCellRendererComponent, ICellRendererParamsForCompanyPermissionsGridAction } from './agGridActionCellRenderer.component';\r\nimport * as _ from 'lodash';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { USER_GROUP_DETAIL_HELP } from '../../../User-Group/User-Group-Detail/userGroupDetail.component.help';\r\nimport { CompanySitePermissionsParams, CompanySitePermissionsComponent } from '../Site/companySitePermissions.component';\r\n\r\n@Component({\r\n templateUrl: './companyPermissionUserPanel.component.html',\r\n selector: 'company-permission-user-panel',\r\n styles: [`\r\n :host {\r\n display: flex;\r\n flex-flow: column;\r\n height: 100%;\r\n width: 100%;\r\n }\r\n `]\r\n})\r\nexport class CompanyPermissionUserPanelComponent implements OnInit, OnChanges {\r\n constructor(\r\n private readonly _userInstanceService: UserInstanceService,\r\n private readonly _permissionService: PermissionService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _helpService: HelpService) { }\r\n\r\n @Input() userToEdit: {permissions: Core.PermissionModel[]};\r\n @Input() editMode: boolean;\r\n @Input() userId: System.Guid;\r\n\r\n addedCompanies: Core.PermissionModel[] = [];\r\n currentInstance: Core.InstanceViewModel;\r\n agGridReady: boolean;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder(\r\n {\r\n rowClassRules: {\r\n 'grid-row-deleted': params => params.data && _.some(this.userToEdit.permissions, x => {\r\n return x.efAction == 'delete' && x.permissionID === params.data.permissionID;\r\n })\r\n },\r\n singleClickEdit: true,\r\n suppressHorizontalScroll: true\r\n })\r\n .withColumnPinning()\r\n .buildDefault(this);\r\n\r\n private _gridApi: GridApi;\r\n private _gridDataSource: CompanyPermissionAgGridDataSource;\r\n\r\n ngOnInit(): void {\r\n this.userToEdit.permissions = [];\r\n this.currentInstance = this._userInstanceService.getSelectedInstance();\r\n this._helpService.setContent(USER_GROUP_DETAIL_HELP);\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges) {\r\n if(changes.editMode && (!changes.editMode.currentValue && changes.editMode.previousValue)) {\r\n this.userToEdit.permissions = [];\r\n this.refresh();\r\n }\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Company',\r\n field: 'entityName',\r\n lockVisible: true,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParamsStartsWith,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth\r\n },\r\n {\r\n headerName: 'Top Level Company',\r\n field: 'topLevelCompany',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParamsStartsWith,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnMedWidth\r\n },\r\n {\r\n headerName: 'Access Level',\r\n field: 'rightsDropdown',\r\n width: AgGridColumns.textColumnSmallWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n editable: (params) => {\r\n const permissionRow = params.data as Core.PermissionModel;\r\n if (!permissionRow) {\r\n return false;\r\n }\r\n\r\n return this.editMode && !_.some(this.userToEdit.permissions, x => {\r\n return x.efAction == 'delete' && x.permissionID === permissionRow.permissionID;\r\n });\r\n },\r\n cellEditorFramework: AgGridDropdownCellEditor,\r\n cellEditorParams: {\r\n getOptions: () => [\r\n { name: CompanyPermissionOptions.ViewAllSites, value: CompanyPermissionOptions.ViewAllSites },\r\n { name: CompanyPermissionOptions.ViewEditSomeSites, value: CompanyPermissionOptions.ViewEditSomeSites },\r\n { name: CompanyPermissionOptions.EditAllSites, value: CompanyPermissionOptions.EditAllSites }\r\n ],\r\n cellChanged: (params: DropdownCellEditorParams, newValue: string) => {\r\n const permission = params.data as Core.PermissionModel;\r\n this._setPermissionFlags(permission, newValue);\r\n\r\n const alreadyUpdatedIdx = _.findIndex(this.userToEdit.permissions, x => {\r\n return x.efAction === 'update' && x.permissionID === permission.permissionID;\r\n });\r\n\r\n if(alreadyUpdatedIdx >= 0) {\r\n this.userToEdit.permissions[alreadyUpdatedIdx] = permission;\r\n } else {\r\n permission.efAction = 'update';\r\n this.userToEdit.permissions.push(permission);\r\n }\r\n }\r\n },\r\n valueGetter: this._getDropownPermission.bind(this)\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(2),\r\n minWidth: AgGridColumns.getActionColumnWidth(2),\r\n maxWidth: AgGridColumns.getActionColumnWidth(2),\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n suppressColumnsToolPanel: true,\r\n lockPinned: true,\r\n sortable: false,\r\n cellRendererFramework: CompanyPermissionsGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n editMode: params => this.editMode,\r\n canLaunchSitesModal: (params: ICellRendererParamsForCompanyPermissionsGridAction) => {\r\n const permissionOption = this._getDropownPermission(params);\r\n return permissionOption === CompanyPermissionOptions.ViewEditSomeSites;\r\n },\r\n launchSitesModal: async (params: ICellRendererParamsForCompanyPermissionsGridAction) => {\r\n const permission = params.data as Core.PermissionModel;\r\n const saveRequest: Core.PermissionSaveRequest = {\r\n adds: [],\r\n deletes: [],\r\n updates: []\r\n };\r\n\r\n _.forEach(this.userToEdit.permissions, x => {\r\n if(x.efAction === 'add') {\r\n saveRequest.adds.push(x);\r\n } else if(x.efAction === 'update') {\r\n saveRequest.updates.push(x);\r\n } else if(x.efAction === 'delete') {\r\n saveRequest.deletes.push(x);\r\n }\r\n });\r\n\r\n const modalParams: CompanySitePermissionsParams = {\r\n companyId: permission.entityID,\r\n userId: this.userId,\r\n editMode: this.editMode,\r\n saveRequest: _.cloneDeep(saveRequest)\r\n };\r\n\r\n const result = await this._modalService.showAsync(CompanySitePermissionsComponent, modalParams, 'modal-lg');\r\n\r\n document.getElementsByTagName('body')[0].classList.add('modal-open');\r\n\r\n if(!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n result.adds = _.map(result.adds, x => {\r\n x.efAction = 'add';\r\n return x;\r\n });\r\n result.updates = _.map(result.updates, x => {\r\n x.efAction = 'update';\r\n return x;\r\n });\r\n result.deletes = _.map(result.deletes, x => {\r\n x.efAction = 'delete';\r\n return x;\r\n });\r\n\r\n this.userToEdit.permissions = [...result.adds, ...result.updates, ...result.deletes];\r\n },\r\n canRemove: params => {\r\n const permissionRow = params.data as Core.PermissionModel;\r\n if (!permissionRow) {\r\n return false;\r\n }\r\n\r\n return this.editMode && !_.some(this.userToEdit.permissions, x => {\r\n return x.efAction == 'delete' && x.permissionID === permissionRow.permissionID;\r\n });\r\n },\r\n remove: (params: ICellRendererParamsForCompanyPermissionsGridAction) => {\r\n const permissionRow = params.data as Core.PermissionModel;\r\n\r\n if(params.node.rowPinned) {\r\n this.userToEdit.permissions = _.reject(this.userToEdit.permissions, {entityID: permissionRow.entityID});\r\n this.addedCompanies = _.reject(this.addedCompanies, {entityID: permissionRow.entityID});\r\n } else {\r\n permissionRow.efAction = 'delete';\r\n this.userToEdit.permissions.push(permissionRow);\r\n this._gridApi.redrawRows();\r\n }\r\n },\r\n canUndoRemove: params => {\r\n const permissionRow = params.data as Core.PermissionModel;\r\n if (!permissionRow) {\r\n return false;\r\n }\r\n\r\n return this.editMode && _.some(this.userToEdit.permissions, x => {\r\n return x.efAction == 'delete' && x.permissionID === permissionRow.permissionID;\r\n });\r\n },\r\n undoRemove: (params: ICellRendererParamsForCompanyPermissionsGridAction) => {\r\n const permissionRow = params.data as Core.PermissionModel;\r\n this.userToEdit.permissions = _.reject(this.userToEdit.permissions, {permissionID: permissionRow.permissionID});\r\n\r\n this._gridApi.redrawRows();\r\n },\r\n } as ICellRendererParamsForCompanyPermissionsGridAction\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'entityName',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.sizeColumnsToFit();\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._setDataSource();\r\n }\r\n\r\n async addNewCompanyPermission() {\r\n // Add new permission modal\r\n const dataSourceParams: CompanyPermissionAddParams = {\r\n instanceId: this.currentInstance.instanceId,\r\n userId: this.userId,\r\n excludeCompanyIds: _.map(this.addedCompanies, 'entityID')\r\n };\r\n\r\n const result = await this._modalService.showAsync(CompanyPermissionAddComponent, dataSourceParams, 'modal-md');\r\n\r\n document.getElementsByTagName('body')[0].classList.add('modal-open');\r\n\r\n if (!result) {\r\n return Promise.resolve();\r\n }\r\n\r\n result.selectedRows = _.map(result.selectedRows, x => {\r\n this._setPermissionFlags(x, result.permission);\r\n x.efAction = 'add';\r\n return x;\r\n });\r\n\r\n this.userToEdit.permissions = [...this.userToEdit.permissions, ...result.selectedRows];\r\n this.addedCompanies = [...this.addedCompanies, ...result.selectedRows];\r\n }\r\n\r\n refresh(): void {\r\n this.addedCompanies = [];\r\n this._refreshDataSource();\r\n }\r\n\r\n private _getDropownPermission(params: ValueGetterParams): string {\r\n const dbPermission = params.data as Core.PermissionModel;\r\n\r\n if (!dbPermission) {\r\n return '';\r\n }\r\n\r\n const p = _.find(this.userToEdit.permissions, {permissionID: dbPermission.permissionID}) || dbPermission;\r\n\r\n if (p.writeAllowed) {\r\n if (p.includeAllChildRecords) {\r\n return CompanyPermissionOptions.EditAllSites;\r\n } else {\r\n return CompanyPermissionOptions.ViewEditSomeSites;\r\n }\r\n }\r\n\r\n if (p.readAllowed) {\r\n if (p.includeAllChildRecords) {\r\n return CompanyPermissionOptions.ViewAllSites;\r\n } else {\r\n return CompanyPermissionOptions.ViewEditSomeSites;\r\n }\r\n }\r\n }\r\n\r\n private _setPermissionFlags(permission: Core.PermissionModel, rightsString: string): void {\r\n permission.readAllowed = true;\r\n permission.writeAllowed = rightsString === CompanyPermissionOptions.EditAllSites;\r\n permission.includeAllChildRecords = rightsString === CompanyPermissionOptions.ViewAllSites || rightsString === CompanyPermissionOptions.EditAllSites;\r\n }\r\n\r\n private _refreshDataSource() {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const dataSourceParams = (): CompanyPermissionDataSourceParams => {\r\n return {\r\n instanceId: this.currentInstance.instanceId,\r\n userId: this.userId as number\r\n };\r\n };\r\n\r\n this._gridDataSource = new CompanyPermissionAgGridDataSource(this._gridApi, this._permissionService, dataSourceParams);\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { InstancePermissionPanelComponent } from './Instance/instancePermissionPanel.component';\r\nimport { PermissionService } from './permission.service';\r\nimport { ApplicationPermissionPanelComponent } from './Application/applicationPermissionPanel.component';\r\nimport { CompanyPermissionPanelComponent } from './Company/Panel/companyPermissionPanel.component';\r\nimport { CompanyPermissionUserPanelComponent } from './Company/Panel/companyPermissionUserPanel.component';\r\nimport { CompanySitePermissionsComponent } from './Company/Site/companySitePermissions.component';\r\nimport { CompanyPermissionAddComponent } from './Company/Add/companyPermissionAdd.component';\r\nimport { CompanyPermissionsGridActionCellRendererComponent } from './Company/Panel/agGridActionCellRenderer.component';\r\nimport { InstanceRightGridActionCellRendererComponent } from './Instance/agGridActionCellRenderer.component';\r\nimport { ApplicationPermissionGridActionCellRendererComponent } from './Application/agGridActionCellRenderer.component';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { CompanyPermissionsService } from './Company/companyPermissions.service';\r\nimport { ApplicationPermissionService } from './Application/applicationPermission.service';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n BusyIndicatorModule\r\n ],\r\n declarations: [\r\n InstancePermissionPanelComponent,\r\n ApplicationPermissionPanelComponent,\r\n CompanyPermissionPanelComponent,\r\n CompanyPermissionUserPanelComponent,\r\n CompanySitePermissionsComponent,\r\n CompanyPermissionAddComponent,\r\n CompanyPermissionsGridActionCellRendererComponent,\r\n InstanceRightGridActionCellRendererComponent,\r\n ApplicationPermissionGridActionCellRendererComponent\r\n ],\r\n providers: [\r\n PermissionService,\r\n CompanyPermissionsService,\r\n ApplicationPermissionService\r\n ],\r\n exports: [\r\n CompanyPermissionUserPanelComponent,\r\n InstancePermissionPanelComponent,\r\n ApplicationPermissionPanelComponent,\r\n CompanyPermissionPanelComponent\r\n ]\r\n})\r\nexport class PermissionModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('companyPermissionUserPanel', CompanyPermissionUserPanelComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('sd.Company.Permission.Service', CompanyPermissionsService);\r\n hybridAdapterUtility.downgradeNg2Provider('sd.Application.Permission.Service', ApplicationPermissionService);\r\n }\r\n}\r\n","
\r\n
\r\n
\r\n

Info

\r\n
\r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { NgModule } from '@angular/core';\r\nimport { PermissionModule } from '../Permission/permission.module';\r\nimport { UserGroupsGridActionCellRendererComponent } from './User-Group-List/agGridActionCellRendererComponent';\r\nimport { UserGroupListComponent } from './User-Group-List/userGroupList.component';\r\nimport { UserGroupDetailComponent } from './User-Group-Detail/userGroupDetail.component';\r\nimport { UserGroupInfoComponent } from './User-Group-Detail/User-Group-Info/userGroupInfo.component';\r\nimport { AddUserGroupModalComponent } from './User-Group-List/addUserGroupModal.component';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n PermissionModule\r\n ],\r\n declarations: [\r\n UserGroupsGridActionCellRendererComponent,\r\n UserGroupListComponent,\r\n UserGroupDetailComponent,\r\n UserGroupInfoComponent,\r\n AddUserGroupModalComponent\r\n ],\r\n exports: [\r\n UserGroupListComponent,\r\n UserGroupDetailComponent\r\n ]\r\n})\r\nexport class UserGroupModule {\r\n static setupModule(): void {\r\n const hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('userGroupList', UserGroupListComponent);\r\n hybridAdapterUtility.downgradeNg2Component('userGroupDetail', UserGroupDetailComponent);\r\n }\r\n}\r\n","import { CUSTOM_ELEMENTS_SCHEMA, NgModule } from '@angular/core';\r\nimport { AceAuthOidcWrapperComponent } from '../IAM/aceAuthOidcWrapper.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n AceAuthOidcWrapperComponent\r\n ],\r\n schemas: [CUSTOM_ELEMENTS_SCHEMA],\r\n exports: [\r\n AceAuthOidcWrapperComponent\r\n ]\r\n})\r\nexport class WebComponentWrapperModule {\r\n}","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { AttachmentModalData } from 'src/app/Attachment/attachment.modal.model';\r\nimport { CommentModalData } from 'src/app/Comments/comments.service';\r\n\r\nexport interface ICellRendererParamsForPaymentBatchPaymentsGridAction extends ICellRendererParams {\r\n canEdit: (params: ICellRendererParamsForPaymentBatchPaymentsGridAction) => boolean;\r\n edit: (params: ICellRendererParamsForPaymentBatchPaymentsGridAction) => void;\r\n delete: (params: ICellRendererParamsForPaymentBatchPaymentsGridAction) => void;\r\n canDelete: (params: ICellRendererParamsForPaymentBatchPaymentsGridAction) => boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'grid-action-cell',\r\n template: `\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n`\r\n})\r\nexport class PaymentBatchPaymentsGridActionCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForPaymentBatchPaymentsGridAction;\r\n row: Core.PaymentBatchDetailsEntryModel;\r\n attachmentModalData: AttachmentModalData;\r\n commentModalData: CommentModalData;\r\n\r\n agInit(params: ICellRendererParamsForPaymentBatchPaymentsGridAction): void {\r\n this.params = params;\r\n this.row = params.data as Core.PaymentBatchDetailsEntryModel;\r\n\r\n if (!this.row || params.data?.selectedTotalsRow) {\r\n return;\r\n }\r\n this.attachmentModalData = {\r\n entityType: 'Tax Bill',\r\n parentId: this.row.parcelId,\r\n parentType: 'Parcel',\r\n entityName: this.row.parcelAcctNum,\r\n entityDescription: `${this.row.taxYear} - ${this.row.collector} Bill`,\r\n year: this.row.taxYear,\r\n belowParcelEntity: {\r\n id: this.row.billId,\r\n typeId: Core.EntityTypes.Bill,\r\n name: 'Bill'\r\n },\r\n readOnly: !this.params.canEdit(params)\r\n } as AttachmentModalData;\r\n\r\n this.commentModalData = {\r\n entityID: this.row.billId,\r\n entityTypeID: Core.EntityTypes.Bill,\r\n disableCommentTypeSelection: true,\r\n parcelAcctNum: this.row.parcelAcctNum,\r\n canEdit: this.params.canEdit(params),\r\n parcelID: this.row.parcelId,\r\n description: `${this.row.taxYear} - ${this.row.collector} Bill`,\r\n year: this.row.taxYear.toString()\r\n } as CommentModalData;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n\r\n\r\n // descoped for now\r\n // onEditClicked(): void {\r\n // this.params.edit(this.params);\r\n // }\r\n\r\n onDeleteClicked(): void {\r\n this.params.delete(this.params);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ICellRendererAngularComp } from 'ag-grid-angular';\r\nimport { ICellRendererParams } from 'ag-grid-community';\r\nimport { AttachmentModalData } from 'src/app/Attachment/attachment.modal.model';\r\nimport { CommentModalData } from 'src/app/Comments/comments.service';\r\n\r\nexport interface ICellRendererParamsForPaymentBatchPaymentsGridPaymentErrors extends ICellRendererParams {\r\n getErrors: (params: ICellRendererParamsForPaymentBatchPaymentsGridPaymentErrors) => string[];\r\n}\r\n\r\n@Component({\r\n selector: 'grid-payment-errors-cell',\r\n template: `\r\n
\r\n \r\n
\r\n\r\n \r\n
    \r\n
  • {{error}}
  • \r\n
\r\n
\r\n`,\r\n styles: [`\r\n .fa-circle-exclamation { color: var(--ace-danger); font-size: 150%; }\r\n ul { color: var(--ace-danger); }\r\n `]\r\n})\r\nexport class PaymentBatchPaymentsGridPaymentErrorsCellRendererComponent implements ICellRendererAngularComp {\r\n params: ICellRendererParamsForPaymentBatchPaymentsGridPaymentErrors;\r\n row: Core.PaymentBatchDetailsEntryModel;\r\n attachmentModalData: AttachmentModalData;\r\n commentModalData: CommentModalData;\r\n\r\n agInit(params: ICellRendererParamsForPaymentBatchPaymentsGridPaymentErrors): void {\r\n this.params = params;\r\n }\r\n\r\n refresh(): boolean {\r\n return false; // tells grid to handle refreshing\r\n }\r\n}\r\n","import { ColDef } from 'ag-grid-community';\r\nimport { WeissmanDateFormat } from '../../../UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\nimport { AgGridColumns, AgGridFilterParams } from '../../../Compliance/AgGrid';\r\nimport { PaymentBatchPaymentsGridComponent as PaymentBatchPaymentsGridComponent } from './paymentBatchPaymentsGrid.component';\r\nimport { AgGridMultiSelectRendererParams, AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer } from 'src/app/Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridLinkCellRendererComponent, AgGridLinkCellRendererParams } from 'src/app/Compliance/AgGrid/CellRenderers/agGridLinkCellRenderer.component';\r\nimport { ICellRendererParamsForPaymentBatchPaymentsGridAction, PaymentBatchPaymentsGridActionCellRendererComponent } from './agGridActionCellRenderer.component';\r\nimport { PaymentPackage } from '../../../Processing/Transmittal/transmittal.models';\r\nimport { ICellRendererParamsForPaymentBatchPaymentsGridPaymentErrors, PaymentBatchPaymentsGridPaymentErrorsCellRendererComponent } from './agGridPaymentErrorsCellRenderer.component';\r\n\r\nexport const PAYMENT_BATCH_PAYMENTS_COLUMNS = (classRef: PaymentBatchPaymentsGridComponent): ColDef[] => [\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'paymentId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n editable: false,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: classRef.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: classRef.gridTracker } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n } as ColDef,\r\n {\r\n headerName: 'Payment Status',\r\n field: 'paymentStatus',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Payee',\r\n field: 'collector',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-collector',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/states/${model.stateId}/collectors/${model.collectorId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.stateAbbreviationColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-state',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/states/${model.stateId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Parcel Acct Num',\r\n field: 'parcelAcctNum',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-parcel',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/parcel/${model.parcelId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Installment',\r\n field: 'installmentName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Payment Amount',\r\n field: 'paymentAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => classRef.formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-payment',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/payment/${model.paymentId}`;\r\n },\r\n isDisabled: (params: AgGridLinkCellRendererParams) => params.data?.selectedTotalsRow\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Payment Due Date',\r\n field: 'dueDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!(model && model.dueDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.dueDate, true, 'stored');\r\n },\r\n },\r\n {\r\n headerName: 'Payment Notes',\r\n field: 'paymentNotes',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Payment Type',\r\n field: 'paymentType',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Bill Amount',\r\n field: 'billAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: x => classRef.formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Base Payment Amount',\r\n field: 'basePaymentAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: x => classRef.formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Discount Amount',\r\n field: 'discountAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: x => classRef.formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Interest',\r\n field: 'interestAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: x => classRef.formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Penalty',\r\n field: 'penaltyAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: x => classRef.formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Exemption Amount',\r\n field: 'exemptionAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: x => classRef.formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Check No',\r\n field: 'checkNo',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n },\r\n {\r\n headerName: 'Check Date',\r\n field: 'checkDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: (params) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!(model && model.checkDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.checkDate, true, 'stored');\r\n },\r\n },\r\n {\r\n headerName: 'Payment Post Date',\r\n field: 'postDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: (params) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!(model && model.postDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.postDate, true, 'stored');\r\n },\r\n },\r\n {\r\n headerName: 'Tax Year',\r\n field: 'taxYear',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Company',\r\n field: 'companyName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-company',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/company/${model.companyId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n hide: true,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-site',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/site/${model.siteId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-assessor',\r\n newWindow: true,\r\n getLink: (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!model) {\r\n return '';\r\n }\r\n return `#/states/${model.stateId}/assessors/${model.assessorId}`;\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n // hide: true\r\n },\r\n {\r\n headerName: 'Site Pay Res',\r\n field: 'sitePayRes',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Site Payment Resp',\r\n field: 'sitePaymentResp',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Parcel Pay Res',\r\n field: 'parcelPayRes',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: 'Parcel Payment Resp',\r\n field: 'parcelPaymentResp',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n hide: true\r\n },\r\n {\r\n headerName: '',\r\n field: 'paymentErrors',\r\n width: AgGridColumns.checkboxColumnMinWidth,\r\n suppressColumnsToolPanel: true,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n sortable: false,\r\n cellRendererFramework: PaymentBatchPaymentsGridPaymentErrorsCellRendererComponent,\r\n cellRendererParams: {\r\n getErrors: classRef.getErrors.bind(classRef)\r\n } as ICellRendererParamsForPaymentBatchPaymentsGridPaymentErrors\r\n },\r\n {\r\n headerName: '',\r\n field: 'actions',\r\n pinned: 'right',\r\n width: AgGridColumns.getActionColumnWidth(3),\r\n minWidth: AgGridColumns.getActionColumnWidth(3),\r\n maxWidth: AgGridColumns.getActionColumnWidth(3),\r\n lockPinned: true,\r\n suppressColumnsToolPanel: true,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n resizable: false,\r\n sortable: false,\r\n cellRendererFramework: PaymentBatchPaymentsGridActionCellRendererComponent,\r\n cellRendererParams: {\r\n delete: classRef.deleteRow.bind(classRef),\r\n canDelete: classRef.canDelete.bind(classRef),\r\n canEdit: classRef.canEdit.bind(classRef)\r\n } as ICellRendererParamsForPaymentBatchPaymentsGridAction\r\n }\r\n];\r\n\r\nexport const TRANSMITTAL_PACKAGE_COLUMN = (classRef: PaymentBatchPaymentsGridComponent): ColDef => ({\r\n headerName: 'Transmittal Package',\r\n field: 'transmittalPackageNum',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n hide: true,\r\n valueFormatter: (params) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!model) {\r\n return;\r\n }\r\n\r\n return classRef.paymentBatch.batchType !== Core.PaymentBatchTypeEnum.Transmittal ? ' ' : model.transmittalPackageNum;\r\n },\r\n cellRendererFramework: AgGridLinkCellRendererComponent,\r\n cellRendererParams: {\r\n getHelpContentId: (params: AgGridLinkCellRendererParams) => 'app.view-transmittal',\r\n onClickAsync: async (params: AgGridLinkCellRendererParams) => {\r\n const model = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!model) {\r\n return;\r\n }\r\n\r\n const busyRef = classRef.busyIndicatorService.show({message: 'Loading Transmittal...'});\r\n let paymentPackage: PaymentPackage = null;\r\n try {\r\n paymentPackage = await classRef.transmittalService.GetPaymentPackageByID(model.paymentPackageId);\r\n if (paymentPackage) {\r\n classRef.transmittalService.showPaymentPackageReviewModal(paymentPackage);\r\n }\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n } as AgGridLinkCellRendererParams,\r\n});\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from 'src/app/Compliance/AgGrid';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\n\r\nexport interface PaymentBatchPaymentsDataSourceParams {\r\n paymentBatchId: number;\r\n}\r\n\r\nexport class PaymentBatchPaymentsAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _paymentBatchService: PaymentBatchService,\r\n protected _dataSourceParamsFn: () => PaymentBatchPaymentsDataSourceParams\r\n ) { super(_gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'paymentStatus', value: Core.PaymentBatchDetailsEntryPropertyEnum.PaymentStatus },\r\n { name: 'collector', value: Core.PaymentBatchDetailsEntryPropertyEnum.Collector },\r\n { name: 'parcelAcctNum', value: Core.PaymentBatchDetailsEntryPropertyEnum.ParcelAcctNum },\r\n { name: 'installmentName', value: Core.PaymentBatchDetailsEntryPropertyEnum.InstallmentName },\r\n { name: 'paymentAmount', value: Core.PaymentBatchDetailsEntryPropertyEnum.PaymentAmount },\r\n { name: 'basePaymentAmount', value: Core.PaymentBatchDetailsEntryPropertyEnum.BasePaymentAmount },\r\n { name: 'discountAmount', value: Core.PaymentBatchDetailsEntryPropertyEnum.DiscountAmount },\r\n { name: 'penaltyAmount', value: Core.PaymentBatchDetailsEntryPropertyEnum.PenaltyAmount },\r\n { name: 'interestAmount', value: Core.PaymentBatchDetailsEntryPropertyEnum.InterestAmount },\r\n { name: 'exemptionAmount', value: Core.PaymentBatchDetailsEntryPropertyEnum.ExemptionAmount },\r\n { name: 'dueDate', value: Core.PaymentBatchDetailsEntryPropertyEnum.DueDate },\r\n { name: 'checkNo', value: Core.PaymentBatchDetailsEntryPropertyEnum.CheckNo },\r\n { name: 'checkDate', value: Core.PaymentBatchDetailsEntryPropertyEnum.CheckDate },\r\n { name: 'postDate', value: Core.PaymentBatchDetailsEntryPropertyEnum.PostDate },\r\n { name: 'transmittalPackageNum', value: Core.PaymentBatchDetailsEntryPropertyEnum.TransmittalPackageNum },\r\n { name: 'billAmount', value: Core.PaymentBatchDetailsEntryPropertyEnum.BillAmount },\r\n { name: 'state', value: Core.PaymentBatchDetailsEntryPropertyEnum.State },\r\n { name: 'companyName', value: Core.PaymentBatchDetailsEntryPropertyEnum.CompanyName },\r\n { name: 'siteName', value: Core.PaymentBatchDetailsEntryPropertyEnum.SiteName },\r\n { name: 'paymentType', value: Core.PaymentBatchDetailsEntryPropertyEnum.PaymentType },\r\n { name: 'taxYear', value: Core.PaymentBatchDetailsEntryPropertyEnum.TaxYear },\r\n { name: 'assessorName', value: Core.PaymentBatchDetailsEntryPropertyEnum.AssessorName},\r\n { name: 'sitePayRes', value: Core.PaymentBatchDetailsEntryPropertyEnum.SitePayRes},\r\n { name: 'sitePaymentResp', value: Core.PaymentBatchDetailsEntryPropertyEnum.SitePaymentResp},\r\n { name: 'parcelPayRes', value: Core.PaymentBatchDetailsEntryPropertyEnum.ParcelPayRes},\r\n { name: 'parcelPaymentResp', value: Core.PaymentBatchDetailsEntryPropertyEnum.ParcelPaymentResp}\r\n ];\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.PaymentBatchDetailsSearchModel = this._getSearchModel(startIndex, endIndex);\r\n\r\n return await this._paymentBatchService.getPaymentBatchPaymentsRowIds(searchParams);\r\n }\r\n\r\n getSearchParamsWithoutPagination() : Core.PaymentBatchDetailsSearchModel{\r\n this.refreshDataSourceParams();\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n paymentBatchId: this._dataSourceParams.paymentBatchId\r\n };\r\n }\r\n\r\n public async getSelectedRowTotals(selectedRowsModel: Compliance.SelectedRowsModel): Promise {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.selection = selectedRowsModel;\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: 100\r\n };\r\n\r\n const { totals } = await this._paymentBatchService.getPaymentBatchPaymentsList(searchParams);\r\n\r\n return totals;\r\n }\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n // return (this._dataSourceParams.instanceId !== null);\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.PaymentBatchDetailsSearchModel = {\r\n pagination: {\r\n skip: params.startRow,\r\n take: params.endRow - params.startRow\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n paymentBatchId: this._dataSourceParams.paymentBatchId\r\n };\r\n\r\n const result = await this._paymentBatchService.getPaymentBatchPaymentsList(searchParams);\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n\r\n\r\n private _getSearchModel(startIndex?: number, endIndex?: number): Core.PaymentBatchDetailsSearchModel {\r\n return {\r\n pagination: {\r\n skip: (startIndex) ? startIndex : 0,\r\n take: (endIndex) ? endIndex - startIndex + 1 : 0\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n paymentBatchId: this._dataSourceParams.paymentBatchId\r\n };\r\n }\r\n}\r\n","import { HelpContent } from '../../UI-Lib/Help-Tooltip';\r\n\r\nexport const PAYMENT_BATCH_DETAILS_HELP: HelpContent[] = [\r\n {\r\n helpContentId: 'payment-batch-details.edit-funded-amount',\r\n tooltipText: 'Funded Amount must be less than or equal to payment amount.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'payment-batch-details.add-payments-modal',\r\n tooltipText: ' List of payments that are available to add to this payment batch. The payment must be in the same company and may not already be included in another payment batch or already submitted for payment.',\r\n hasIcon: true\r\n },\r\n {\r\n helpContentId: 'payment-batch-details.add-payments-button',\r\n tooltipText: 'Add Payments'\r\n },\r\n {\r\n helpContentId: 'payment-batch-details.show-payment-errors',\r\n tooltipText: 'Show Errors'\r\n }\r\n];\r\n","import { Component, EventEmitter, OnDestroy, OnInit, Output, Input } from '@angular/core';\r\nimport { GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { BehaviorSubject, Subject, Subscription, lastValueFrom, takeUntil } from 'rxjs';\r\nimport { AgGridOptionsBuilder } from '../../../Compliance/AgGrid';\r\nimport { AgGridMultiSelectTracker } from '../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { BusyIndicatorRef, BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { HelpService } from 'src/app/UI-Lib/Help-Tooltip';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\nimport { DeleteConfirmationComponent, DeleteConfirmationComponentParams } from 'src/app/Common/Delete-Confirmation/deleteConfirmation.component';\r\nimport { CurrencyPipe, DecimalPipe } from '@angular/common';\r\nimport { WeissmanModalService } from 'src/app/Compliance/WeissmanModalService';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\nimport { PAYMENT_BATCH_PAYMENTS_COLUMNS, TRANSMITTAL_PACKAGE_COLUMN } from './paymentBatchPayments.columns';\r\nimport { PaymentBatchPaymentsAgGridDataSource, PaymentBatchPaymentsDataSourceParams } from './agGridDataSource';\r\nimport { ICellRendererParamsForPaymentBatchPaymentsGridAction } from './agGridActionCellRenderer.component';\r\nimport { MessageModalService } from 'src/app/UI-Lib/Message-Box/messageModal.service';\r\nimport { PaymentBatchRepository } from 'src/app/Core-Repositories/paymentBatch.repository';\r\nimport { TransmittalService } from 'src/app/Processing/Transmittal/transmittal.service';\r\nimport { PAYMENT_BATCH_DETAILS_HELP } from '../paymentBatchDetails.component.help';\r\nimport { chain, cloneDeep, findIndex, includes, reject} from 'lodash';\r\nimport * as _ from 'lodash';\r\nimport { ICellRendererParamsForPaymentBatchPaymentsGridPaymentErrors } from './agGridPaymentErrorsCellRenderer.component';\r\nimport { MessageBoxButtons, MessageBoxService, MessageBoxResult } from '../../../UI-Lib/Message-Box/messagebox.service.upgrade';\r\nimport { WeissmanKeyValueDisplayPipe } from 'src/app/UI-Lib/Pipes';\r\nimport { AgGridExportOptions, AgGridExportStartLRP } from 'src/app/Compliance/AgGrid/ToolPanel/models';\r\n\r\n@Component({\r\n selector: 'payment-batch-payments-grid',\r\n templateUrl: 'paymentBatchPaymentsGrid.component.html',\r\n styles: [`\r\n :host { display: contents; }\r\n `]\r\n})\r\n\r\nexport class PaymentBatchPaymentsGridComponent implements OnInit, OnDestroy {\r\n constructor(\r\n private readonly _helpService: HelpService,\r\n private readonly _paymentBatchRepository: PaymentBatchRepository,\r\n private readonly _paymentBatchService: PaymentBatchService,\r\n public readonly decimalPipe: DecimalPipe,\r\n public readonly currencyPipe: CurrencyPipe,\r\n private readonly _routerService: UpgradeNavigationServiceHandler,\r\n private readonly _modalService: WeissmanModalService,\r\n public readonly busyIndicatorService: BusyIndicatorService,\r\n private readonly _messageBoxService: MessageBoxService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe,\r\n public readonly transmittalService: TransmittalService) { }\r\n\r\n @Input() paymentBatch: Core.PaymentBatchModel;\r\n @Input() workflowStatus: Core.PaymentBatchDetailsWorkflowStatusModel;\r\n @Output() gridDataChanged: EventEmitter = new EventEmitter();\r\n @Output() rowCount: EventEmitter = new EventEmitter();\r\n\r\n isBulkDeleteVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n isBulkUpdateVisible$: BehaviorSubject = new BehaviorSubject(false);\r\n gridId: System.Guid = 'E83F889C-9538-4E06-BCDF-BD463B3B9FCC';\r\n busyRefId: string = this.busyIndicatorService.generateUniqueMessageIdentifier();\r\n paymentBatchId: number;\r\n totalsLoading: any;\r\n\r\n gridTracker: AgGridMultiSelectTracker;\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true,\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected(params.data.paymentId),\r\n 'selected-totals-row': (params) => params.data && params.data.selectedTotalsRow\r\n },\r\n rowModelType: 'infinite',\r\n onModelUpdated: () => this.rowCount.emit(this._gridDataSource.totalRows)\r\n }).withInfiniteScroll(100)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withColumnPinning()\r\n .build();\r\n\r\n exportOptions: AgGridExportOptions = {\r\n start: async (columnsToReturn: Compliance.NameValuePair[], fileFormat: Compliance.ExportFileFormatEnum): Promise => {\r\n const searchModel = this._gridDataSource.getSearchParamsWithoutPagination();\r\n\r\n const lrp$ = this._paymentBatchRepository.startPaymentBatchDetailsExport({\r\n searchModel,\r\n columnsToReturn,\r\n fileFormat\r\n });\r\n\r\n const longRunningProcessId = await lastValueFrom(lrp$);\r\n const longRunningProcessTypeId = Compliance.LongRunningProcessTypeEnum.PaymentBatchDetailsExport;\r\n\r\n return { longRunningProcessId, longRunningProcessTypeId };\r\n },\r\n canCancel: true,\r\n getDisabled: () => {\r\n return !this._gridDataSource\r\n || this._gridDataSource.totalRows === 0\r\n || this._gridDataSource.isRefreshing\r\n || this._noColumnsSelected();\r\n }\r\n };\r\n\r\n private _gridApi: GridApi;\r\n private _gridMultiSelectSub: Subscription;\r\n private _destroy$: Subject = new Subject();\r\n private _busyRef: BusyIndicatorRef;\r\n private _gridDataSource: PaymentBatchPaymentsAgGridDataSource;\r\n private _paymentErrors: Core.BulkOperationResult[] = [];\r\n private _lastFetchedTotals: Core.PaymentBatchPaymentTotalsModel;\r\n\r\n get refreshingGrid(): boolean {\r\n return this._gridDataSource && this._gridDataSource.isRefreshing;\r\n }\r\n\r\n ngOnInit() {\r\n this._helpService.setContent(PAYMENT_BATCH_DETAILS_HELP);\r\n this.paymentBatchId = parseInt(this._routerService.getQuerystringParam('paymentBatchId'));\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridApi.showLoadingOverlay();\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n const columns = PAYMENT_BATCH_PAYMENTS_COLUMNS(this);\r\n if(this.paymentBatch?.batchType === Core.PaymentBatchTypeEnum.Transmittal) {\r\n const billAmountIdx = findIndex(columns, {field: 'billAmount'});\r\n columns.splice(billAmountIdx, 0, TRANSMITTAL_PACKAGE_COLUMN(this));\r\n }\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(async () => {\r\n // if (!this.longRunningUpdateUnderway) {\r\n // this.isBulkUpdateVisible$.next(this.gridTracker.hasSelectedRows());\r\n // this.isRemoveExceptionsVisible$.next(this.gridTracker.hasSelectedRows());\r\n // }\r\n\r\n const isBulkDeleteVisible = this.workflowStatus?.canAddDeletePayments && this.gridTracker.hasSelectedRows();\r\n\r\n this.isBulkDeleteVisible$.next(isBulkDeleteVisible);\r\n const isBulkUpdateVisible = this.workflowStatus?.canAdvanceTask && this.gridTracker.hasSelectedRows();\r\n\r\n this.isBulkDeleteVisible$.next(isBulkDeleteVisible);\r\n this.isBulkUpdateVisible$.next(isBulkUpdateVisible);\r\n\r\n this._reloadTotals();\r\n });\r\n\r\n this._setDataSource();\r\n\r\n }\r\n\r\n addPaymentErrors(paymentErrors: Core.BulkOperationResult[]) {\r\n this._paymentErrors = paymentErrors;\r\n }\r\n\r\n async refresh(): Promise {\r\n this._paymentErrors = [];\r\n\r\n return this._refreshDataSource();\r\n }\r\n\r\n async bulkUpdate(): Promise {\r\n const answer = await this._messageBoxService.open({\r\n title: 'Mark Rereviewed',\r\n message: `Task advancement is blocked for any payments which have completed review tasks \r\n where the parcel or collector has changed since the task was complete. Once you have verified that the changes \r\n do not impact the payment you can mark the task as reviewed, which will clear the error. Are \r\n you sure you want to mark the selected record/s as reviewed?`,\r\n buttons: MessageBoxButtons.OKCancel\r\n });\r\n if (answer === MessageBoxResult.Cancel) {\r\n return;\r\n }\r\n this._showBusyIndicator('Rereview Payments', 'Rereviewing Payments from Batch', null, false, false);\r\n\r\n const model: Core.PaymentBatchDetailsPaymentBulkReReviewModel = {\r\n paymentBatchId: this.paymentBatchId,\r\n selectAllRows: this.gridTracker.getSelectedRowsModel().selectAllRows,\r\n selectedRows: this.gridTracker.getSelectedRowsModel().selectedRows,\r\n };\r\n\r\n try {\r\n await this._paymentBatchService.paymentBatchDetailsPaymentBulkReReview(model);\r\n this.refresh();\r\n }\r\n catch (e) {\r\n await this._hideBusyIndicator();\r\n return Promise.reject(e);\r\n }\r\n await this._hideBusyIndicator();\r\n return Promise.resolve();\r\n }\r\n\r\n async bulkDelete(): Promise {\r\n const params: DeleteConfirmationComponentParams = {\r\n item: 'Payment Batch Payments',\r\n message: 'Are you sure you want to remove selected Payments from the Batch?'\r\n };\r\n\r\n const result = await this._modalService.showAsync(DeleteConfirmationComponent, params, 'modal-md');\r\n\r\n if (result) {\r\n this._showBusyIndicator('Bulk Delete', 'Removing Payments from Batch', null, false, true);\r\n\r\n const model: Core.PaymentBatchDetailsPaymentBulkDeleteModel = {\r\n paymentBatchId: this.paymentBatchId,\r\n selectAllRows: this.gridTracker.getSelectedRowsModel().selectAllRows,\r\n selectedRows: this.gridTracker.getSelectedRowsModel().selectedRows,\r\n };\r\n\r\n try {\r\n const longRunningProcessId = await this._paymentBatchService.startPaymentBatchDetailsPaymentBulkDelete(model);\r\n await this._busyRef.setLongRunningProcessId(longRunningProcessId);\r\n }\r\n catch (e) {\r\n await this._hideBusyIndicator();\r\n return Promise.reject(e);\r\n }\r\n }\r\n\r\n return Promise.resolve();\r\n }\r\n\r\n async deleteRow(params: ICellRendererParamsForPaymentBatchPaymentsGridAction): Promise {\r\n const row = params.data as Core.PaymentBatchDetailsEntryModel;\r\n if (!row) {\r\n return;\r\n }\r\n\r\n const deleted = await this._deletePaymentBatchPaymentsRow(row);\r\n if (deleted) {\r\n this._refreshAndNotifyParent();\r\n }\r\n }\r\n\r\n canEdit(params) {\r\n return this.workflowStatus.canAddDeletePayments;\r\n }\r\n\r\n canDelete() {\r\n return this.workflowStatus.canAddDeletePayments;\r\n }\r\n\r\n getErrors(params: ICellRendererParamsForPaymentBatchPaymentsGridPaymentErrors): string[] {\r\n if(!params.data) {\r\n return [];\r\n }\r\n\r\n const row = params.data as Core.PaymentBatchDetailsEntryModel;\r\n const errorMessages = chain(this._paymentErrors)\r\n .filter({entityID: row.paymentId})\r\n .map(error => _.values(_.pick(error, ['errorMessage', 'warningMessage'])))\r\n .flatten()\r\n .filter(message => message !== null && message !== undefined)\r\n .value() as string[];\r\n\r\n return errorMessages;\r\n }\r\n\r\n formatCurrency(value: number): string {\r\n if(value == null) {\r\n return '';\r\n }\r\n\r\n const formattedVal = this.currencyPipe.transform(Math.abs(value), 'USD', 'symbol-narrow');\r\n return value < 0 ? `(${formattedVal})` : formattedVal;\r\n }\r\n\r\n handleTotalsUpdate = (totals: Core.PaymentBatchPaymentTotalsModel, isLoading: boolean = false) => {\r\n const model = {};\r\n const paymentRow: any = {\r\n model,\r\n getModel: () => { return model; },\r\n displayPipe: this._keyValueDisplayPipe,\r\n index: 0,\r\n paymentAmount: totals && totals.paymentAmountTotal,\r\n installmentName: 'SELECTED',\r\n selectedTotalsRow: true\r\n };\r\n\r\n if (isLoading) {\r\n this.totalsLoading = this._gridDataSource.getLoadingMessage(msg => {\r\n paymentRow.installmentName = msg;\r\n this._gridApi.setPinnedBottomRowData([paymentRow]);\r\n });\r\n return;\r\n } else if (!isLoading && this.totalsLoading >= 0) {\r\n clearInterval(this.totalsLoading);\r\n this.totalsLoading = null;\r\n }\r\n\r\n const totalRows = this.gridTracker.hasAnythingSelected() ? [paymentRow] : [];\r\n\r\n setTimeout(() => this._gridApi.setPinnedBottomRowData(totalRows), 100);\r\n };\r\n\r\n private async _getGridRowIds(skip: number, take: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(skip, take);\r\n }\r\n\r\n private async _refreshDataSource(): Promise {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkDeleteVisible$.next(false);\r\n this.isBulkUpdateVisible$.next(false);\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return false;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n this.isBulkDeleteVisible$.next(false);\r\n this.isBulkUpdateVisible$.next(false);\r\n const dataSourceParams = (): PaymentBatchPaymentsDataSourceParams => {\r\n return {\r\n paymentBatchId: this.paymentBatchId\r\n };\r\n };\r\n\r\n this._gridDataSource = new PaymentBatchPaymentsAgGridDataSource(\r\n this._gridApi,\r\n this._paymentBatchService,\r\n dataSourceParams,\r\n );\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private async _deletePaymentBatchPaymentsRow(row: Core.PaymentBatchDetailsEntryModel): Promise {\r\n try {\r\n await this._messageModalService.confirm('Are you sure you wish to remove the Payment from the Batch?', 'Confirm Delete');\r\n }\r\n catch (e) {\r\n return Promise.resolve(false);\r\n }\r\n\r\n const busyRef = this.busyIndicatorService.show({ message: 'Deleting' });\r\n\r\n try {\r\n await lastValueFrom(this._paymentBatchRepository.deletePaymentRow(row.paymentBatchId, row.paymentId));\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n\r\n return Promise.resolve(true);\r\n }\r\n\r\n private _showBusyIndicator(title: string, message: string = 'Working on it...', lrpId: number, canDismiss = true, hasProgressBar = true): void {\r\n if (this._busyRef) {\r\n this._busyRef.updateMessage(message, this.busyRefId);\r\n this._busyRef.setLongRunningProcessId(lrpId);\r\n return;\r\n }\r\n\r\n this._busyRef = this.busyIndicatorService.show({\r\n identifier: this.busyRefId,\r\n longRunningProcessId: lrpId,\r\n title: title ? title : 'Processing',\r\n message: message,\r\n hasProgressBar: hasProgressBar,\r\n canDismiss\r\n });\r\n\r\n this._busyRef.onProgressBarComplete().pipe(takeUntil(this._destroy$)).subscribe(async (success) => {\r\n await this._hideBusyIndicator();\r\n if (success) {\r\n this._refreshAndNotifyParent();\r\n }\r\n });\r\n }\r\n\r\n private async _hideBusyIndicator(): Promise {\r\n if (this._busyRef) {\r\n await this._busyRef.hide();\r\n this._busyRef = null;\r\n }\r\n this._destroy$.next();\r\n }\r\n\r\n private _refreshAndNotifyParent() {\r\n this.refresh();\r\n this.gridDataChanged.emit();\r\n }\r\n\r\n private async _reloadTotals(): Promise {\r\n if (!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const result = await this._gridDataSource.getSelectedRowTotals(this.gridTracker.getSelectedRowsModel());\r\n this.handleTotalsUpdate(result);\r\n }\r\n\r\n private _noColumnsSelected(): boolean {\r\n const visibleColumns = this.gridOptions.columnApi.getAllDisplayedColumns();\r\n const columnsWithData = reject(visibleColumns, col =>\r\n includes(['grid-column-multiselect', 'actions', 'paymentErrors'], col.getColId())\r\n );\r\n\r\n return !columnsWithData.length;\r\n }\r\n}\r\n"," 0\">\r\n\r\n

Awaiting Package Creation ...

\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Package #CreatedResponsible PartyCc/BccTransmittalsFeedPayment CountData Hub StatusSpecial Instructions
{{ getPackageNum(package) }}{{ package.completedDateTime ? (package.completedDateTime | weissmanDateFormat) : '' }}\r\n
\r\n \r\n {{ recipient.fullName }}\r\n \r\n
\r\n
\r\n Not Applicable\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n CC: \r\n {{ recipient.fullName }}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n BCC: \r\n {{ recipient.fullName }}\r\n
\r\n
\r\n
\r\n
\r\n Not Applicable\r\n
\r\n
\r\n \r\n {{isTransmittal ? 'Transmittal Link' : feedTextMap[package.feedType]}}\r\n \r\n \r\n {{package.paymentCount}}{{package.feedType === checkFeed ? package.dataHubStatus : 'N/A'}}{{isTransmittal ? package.specialInstructions : 'N/A'}}\r\n \r\n
\r\n\r\n\r\n
\r\n {{hoveredRecipient.companyName}}\r\n
{{hoveredRecipient.fullName}}\r\n
{{hoveredRecipient.title}}\r\n
\r\n {{hoveredRecipient.address.address1}}\r\n
{{hoveredRecipient.address.address2}}\r\n
{{hoveredRecipient.address.city}}, {{hoveredRecipient.address.abbr}} {{hoveredRecipient.address.zip}}\r\n
\r\n
\r\n
\r\n","\r\n\r\n\r\n","import { Component, Input, OnInit } from '@angular/core';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\nimport { PaymentPackage, RecipientType } from 'src/app/Processing/Transmittal/transmittal.models';\r\nimport { BusyIndicatorMessageManager, SnackBarService } from 'src/app/Busy-Indicator';\r\nimport { UpgradeNavigationServiceHandler } from 'src/app/Common/Routing/upgrade-navigation-handler.service';\r\nimport { TransmittalService } from 'src/app/Processing/Transmittal/transmittal.service';\r\nimport { Constants } from 'src/app/constants.new';\r\n\r\ninterface PaymentPackageUI extends Weissman.Model.TaxBills.PaymentPackage {\r\n feedType?: Core.PaymentBatchFeedTypes\r\n isDownloading?: boolean;\r\n paymentCount?: number;\r\n dataHubStatus?: string;\r\n}\r\n\r\n@Component({\r\n selector: 'payment-batch-packages',\r\n templateUrl: 'paymentBatchPackages.component.html',\r\n styles: [`\r\n\r\n .packages-table td {\r\n vertical-align: middle;\r\n }\r\n\r\n `]\r\n})\r\n\r\nexport class PaymentBatchPackagesComponent implements OnInit {\r\n constructor(private readonly _paymentBatchService: PaymentBatchService,\r\n private readonly _transmittalService: TransmittalService,\r\n private readonly constants: Constants,\r\n private readonly _navService: UpgradeNavigationServiceHandler,\r\n private readonly _snackBarService: SnackBarService) { }\r\n\r\n @Input() paymentBatch: Core.PaymentBatchModel;\r\n @Input() workflowStatus: Core.PaymentBatchDetailsWorkflowStatusModel;\r\n\r\n paymentPackages: PaymentPackageUI[] = [];\r\n RecipientType = RecipientType;\r\n hoveredRecipient: Weissman.Model.TaxBills.PaymentPackageRecipient;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n readonly recipientTypeMap: {\r\n [rType: string]: Weissman.Model.RecipientType\r\n } = {\r\n responsible: Weissman.Model.RecipientType.ResponsibleParty,\r\n cc: Weissman.Model.RecipientType.Cc,\r\n bcc: Weissman.Model.RecipientType.Bcc\r\n };\r\n\r\n readonly feedTextMap: {\r\n [paymentBatchFeedType: number]: string\r\n } = {\r\n [Core.PaymentBatchFeedTypes.CheckFeed]: 'Check Feed',\r\n [Core.PaymentBatchFeedTypes.FinalAPFeed]: 'Final AP Feed',\r\n [Core.PaymentBatchFeedTypes.PrelimAPFeed]: 'Preliminary AP Feed'\r\n\r\n };\r\n get checkFeed() : number {\r\n return Core.PaymentBatchFeedTypes.CheckFeed;\r\n }\r\n\r\n get isTransmittal(): boolean {\r\n return this.paymentBatch?.batchType === Core.PaymentBatchTypeEnum.Transmittal;\r\n }\r\n\r\n get awaitingPackageCreation(): boolean {\r\n return this.isTransmittal && !this.workflowStatus?.isSeriesCompleted;\r\n }\r\n\r\n async ngOnInit() {\r\n this.loadData();\r\n }\r\n\r\n async loadData() {\r\n if(this.awaitingPackageCreation) {\r\n return;\r\n }\r\n\r\n const busyMsg = 'loading';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsg);\r\n\r\n try {\r\n this.paymentPackages = await this._getPackages();\r\n this.paymentPackages.forEach(paymentPackage => {\r\n paymentPackage.paymentCount = paymentPackage.paymentTransmittals.map(res => res.paymentTransmittalItems.length).reduce((acc, ele) => acc +ele, 0);\r\n });\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n }\r\n\r\n getPackageNum(pmtPackage: PaymentPackageUI) {\r\n return pmtPackage.packageNumber\r\n ? `${this.constants.TransmittalOutputTypeAbbr[pmtPackage.transmittalOutputType]}-${pmtPackage.packageNumber}`\r\n : '';\r\n }\r\n\r\n setHoveredRecipient(recipient: Weissman.Model.TaxBills.PaymentPackageRecipient): void {\r\n this.hoveredRecipient = recipient;\r\n }\r\n\r\n navigateToBillPaymentPackages(paymentPackage: PaymentPackageUI) {\r\n this._navService.go('paymentPackageDetail', {\r\n companyID: paymentPackage.companyID,\r\n paymentPackageID: paymentPackage.paymentPackageID,\r\n paymentBatchId: this.paymentBatch.paymentBatchId\r\n });\r\n }\r\n\r\n launchReviewModal(paymentPackage: PaymentPackageUI) {\r\n this._transmittalService.showPaymentPackageReviewModal(paymentPackage as unknown as PaymentPackage);\r\n }\r\n\r\n isDownloadDisabled(paymentPackage: PaymentPackageUI) {\r\n return paymentPackage.isDownloading\r\n || (paymentPackage.feedType === Core.PaymentBatchFeedTypes.CheckFeed && !this.paymentBatch.userHasElevatedPermission);\r\n }\r\n\r\n async download(paymentPackage: PaymentPackageUI) {\r\n paymentPackage.isDownloading = true;\r\n\r\n try {\r\n const longRunningProcessId = await this._paymentBatchService.getOutputZip(this.paymentBatch.paymentBatchId, [paymentPackage.feedType]);\r\n this._snackBarService.addById(longRunningProcessId, Compliance.LongRunningProcessTypeEnum.PaymentBatchExportFeedsAndFiles);\r\n } finally {\r\n paymentPackage.isDownloading = false;\r\n }\r\n }\r\n\r\n private async _getPackages(): Promise {\r\n if(this.isTransmittal) {\r\n return this._paymentBatchService.getTransmittalPaymentPackages(this.paymentBatch.paymentBatchId);\r\n } else {\r\n const feedPackages = await this._paymentBatchService.getBillPaymentPackages(this.paymentBatch.paymentBatchId);\r\n return feedPackages.map(({package: paymentPackage, feedType, dataHubStatus}) => {\r\n return {\r\n ...paymentPackage[0],\r\n feedType,\r\n dataHubStatus\r\n };\r\n });\r\n }\r\n }\r\n}\r\n","\r\n\r\n

\r\n No shipping methods found...\r\n

\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Payee# of Payments# of ChecksTotal AmountShipping Method
{{row.collectorName}}, {{row.collectorState}} [{{row.collectorID}}]{{row.numberOfPayments}}{{row.numberOfChecks}}{{row.amount | currency:'USD'}}\r\n \r\n \r\n
\r\n
","import { Component, OnInit } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\n\r\nexport interface ShippingMethodsModalParams {\r\n paymentBatchId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'shipping-methods-modal',\r\n templateUrl: 'shippingMethodsModal.component.html',\r\n styles: [`\r\n .shipping-methods td {\r\n vertical-align: middle;\r\n } \r\n `]\r\n})\r\n\r\n\r\nexport class ShippingMethodsModalComponent implements IWeissmanModalComponent, OnInit {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _paymentBatchService: PaymentBatchService,\r\n private readonly _toastr: ToastrService\r\n ) { }\r\n\r\n params: ShippingMethodsModalParams;\r\n result: File;\r\n\r\n serverAction: boolean = false;\r\n shippingMethodPackages: Core.PaymentBatchDetailsShippingMethodsModel[];\r\n shippingMethods = [{\r\n id: Core.PaymentBatchShippingMethodEnum.USPSStandard,\r\n name: 'USPS Standard',\r\n }, {\r\n id: Core.PaymentBatchShippingMethodEnum.USPSStandardScottsdale,\r\n name: 'USPS Standard (Scottsdale)'\r\n }, {\r\n id: Core.PaymentBatchShippingMethodEnum.USPSCertifiedWReturnReceipt,\r\n name: 'USPS Certified w/Return Receipt',\r\n }, {\r\n id: Core.PaymentBatchShippingMethodEnum.USPSCertifiedWReturnReceiptScottsdale,\r\n name: 'USPS Certified w/Return Receipt (Scottsdale)',\r\n }, {\r\n id: Core.PaymentBatchShippingMethodEnum.USPSCertifiedWNoReturnReceipt,\r\n name: 'USPS Certified w/No Return Receipt ',\r\n }, {\r\n id: Core.PaymentBatchShippingMethodEnum.USPSCertifiedWNoReturnReceiptScottsdale,\r\n name: 'USPS Certified w/No Return Receipt (Scottsdale)',\r\n }, {\r\n id: Core.PaymentBatchShippingMethodEnum.FedEx,\r\n name: 'FedEx',\r\n },\r\n]\r\n\r\n async ngOnInit(): Promise {\r\n this.serverAction = true;\r\n try {\r\n this.shippingMethodPackages = await this._paymentBatchService.getShippingMethods(this.params.paymentBatchId)\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n getIt() {\r\n console.log(this.shippingMethodPackages)\r\n }\r\n\r\n async save() {\r\n this.serverAction = true;\r\n try {\r\n await this._paymentBatchService.setShippingMethods(this.params.paymentBatchId, this.shippingMethodPackages);\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.serverAction = false;\r\n }\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n}","
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n","import { Component, Input } from '@angular/core';\r\nimport { chain, some } from 'lodash';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\nimport { BusyIndicatorService, SnackBarService } from 'src/app/Busy-Indicator';\r\nimport { WeissmanModalService } from 'src/app/Compliance/WeissmanModalService';\r\nimport { ShippingMethodsModalComponent, ShippingMethodsModalParams } from './shippingMethodsModal.component';\r\n\r\n@Component({\r\n selector: 'payment-batch-output',\r\n templateUrl: 'paymentBatchOutput.component.html'\r\n})\r\n\r\nexport class PaymentBatchOutputComponent {\r\n constructor(private readonly _paymentBatchService: PaymentBatchService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _snackBarService: SnackBarService) {}\r\n @Input() paymentBatch: Core.PaymentBatchModel;\r\n\r\n feeds: {\r\n type: Core.PaymentBatchFeedTypes,\r\n checked: boolean;\r\n label: string;\r\n }[] = [\r\n {\r\n type: Core.PaymentBatchFeedTypes.FinalAPFeed,\r\n checked: false,\r\n label: 'AP Feed',\r\n },\r\n {\r\n type: Core.PaymentBatchFeedTypes.CheckFeed,\r\n checked: false,\r\n label: 'Check Feed'\r\n },\r\n {\r\n type: Core.PaymentBatchFeedTypes.CertificateOfMailLog,\r\n checked: false,\r\n label: 'USPS Certificate of Mailings'\r\n },\r\n {\r\n type: Core.PaymentBatchFeedTypes.CertificateOfMailSingle,\r\n checked: false,\r\n label: 'USPS Certificate of Mailings (Single)'\r\n },\r\n {\r\n type: Core.PaymentBatchFeedTypes.EnvelopeInserts,\r\n checked: false,\r\n label: 'Envelope Inserts'\r\n },\r\n {\r\n type: Core.PaymentBatchFeedTypes.ShippingMethods,\r\n checked: false,\r\n label: 'Mailing Excel Extract'\r\n }\r\n ];\r\n\r\n get isDownloadDisabled(): boolean {\r\n return !some(this.feeds, 'checked');\r\n }\r\n\r\n showShippingMethods(type: Core.PaymentBatchFeedTypes): boolean {\r\n return (this.paymentBatch.paymentBatchTaskSeriesOptionId == Core.PaymentBatchTaskSeriesOptionEnum.EarlyApproval\r\n || this.paymentBatch.paymentBatchTaskSeriesOptionId == Core.PaymentBatchTaskSeriesOptionEnum.Standard)\r\n && this.paymentBatch.hasCheckFeed\r\n && type === Core.PaymentBatchFeedTypes.ShippingMethods\r\n }\r\n\r\n isDisabled(feedType: Core.PaymentBatchFeedTypes) {\r\n if(feedType === Core.PaymentBatchFeedTypes.FinalAPFeed) {\r\n return false;\r\n } else {\r\n return !this.paymentBatch.hasCheckFeed || !this.paymentBatch.userHasElevatedPermission;\r\n }\r\n }\r\n\r\n async launchShippingMethodsModal() {\r\n const params: ShippingMethodsModalParams = {\r\n paymentBatchId: this.paymentBatch.paymentBatchId\r\n }\r\n\r\n const result = await this._modalService.showAsync(\r\n ShippingMethodsModalComponent,\r\n params,\r\n 'modal-xl'\r\n // 'modal-xl modal-no-max-width'\r\n );\r\n }\r\n\r\n async download() {\r\n const feedTypes = chain(this.feeds)\r\n .filter('checked')\r\n .map('type')\r\n .value();\r\n\r\n const busyRef = this._busyIndicatorService.show({ message: 'Setting LRP...' });\r\n\r\n try {\r\n const longRunningProcessId = await this._paymentBatchService.getOutputZip(this.paymentBatch.paymentBatchId, feedTypes);\r\n this._snackBarService.addById(longRunningProcessId, Compliance.LongRunningProcessTypeEnum.PaymentBatchExportFeedsAndFiles);\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n}"," 0\">\r\n\r\n
\r\n
\r\n
\r\n

\r\n Batch Settings\r\n

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n

Override Collectors Protocol

\r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n \r\n Maximum {{settings.maxItemsPerCheck ?? 'unlimited'}} payment item{{(settings.maxItemsPerCheck > 1 || !settings.maxItemsPerCheck ? 's' : '')}} per check\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
PayeeMax Payment Items Per check
{{payee.collectorName}}\r\n {{payee.inputValue ?? 'Unlimited'}}\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\nimport { cloneDeep, some } from 'lodash';\r\nimport { NavigationService } from 'src/app/Layout/navigation.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { BusyIndicatorMessageManager } from 'src/app/Busy-Indicator';\r\n\r\ninterface CollectorOverridesUI extends Core.PaymentBatchSettingsCollectorModel {\r\n inputValue: number;\r\n}\r\n\r\n@Component({\r\n selector: 'payment-batch-settings',\r\n templateUrl: 'paymentBatchSettings.component.html',\r\n styles: [`\r\n .ng-invalid {\r\n border-color: var(--ace-danger);\r\n box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.08);\r\n }\r\n `]\r\n})\r\n\r\nexport class PaymentBatchSettingsComponent implements OnInit {\r\n constructor(\r\n private readonly _paymentBatchService: PaymentBatchService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _navigationService: NavigationService\r\n ) {}\r\n\r\n @Input() paymentBatch: Core.PaymentBatchModel;\r\n @Input() workflowStatus: Core.PaymentBatchDetailsWorkflowStatusModel;\r\n @Output() editChange: EventEmitter = new EventEmitter();\r\n\r\n readonly MAX_PAYMENT_ITEMS = 1000;\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n editMode: boolean = false;\r\n settings: Core.PaymentBatchSettingsModel;\r\n collectorOverridesUI: CollectorOverridesUI[];\r\n\r\n private _originalSettings: Core.PaymentBatchSettingsModel;\r\n private _originalCollectorOverridesUI: CollectorOverridesUI[];\r\n\r\n\r\n async ngOnInit(): Promise {\r\n const busyMsg = 'Saving';\r\n this.busyIndicatorMessageManager.add('Loading', busyMsg);\r\n\r\n try {\r\n this.settings = await this._paymentBatchService.getPaymentBatchSettings(this.paymentBatch.paymentBatchId);\r\n this._setCollectorOverridesUI();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n }\r\n\r\n get canEdit(): boolean {\r\n return this.workflowStatus.canModifyMaxItemsPerCheck;\r\n }\r\n\r\n get allPayees(): Core.PaymentBatchCollectorOverrideScopeEnum {\r\n return Core.PaymentBatchCollectorOverrideScopeEnum.All;\r\n }\r\n\r\n get individualPayees(): Core.PaymentBatchCollectorOverrideScopeEnum {\r\n return Core.PaymentBatchCollectorOverrideScopeEnum.Individual;\r\n }\r\n\r\n get isAppliedToAll(): boolean {\r\n return this.settings.collectorOverrideScope === this.allPayees;\r\n }\r\n\r\n edit() {\r\n this._originalSettings = cloneDeep(this.settings);\r\n this._originalCollectorOverridesUI = cloneDeep(this.collectorOverridesUI);\r\n\r\n this.editMode = true;\r\n this.editChange.emit(true);\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n }\r\n\r\n revertOverride(payee: CollectorOverridesUI) {\r\n payee.inputValue = payee.maxItemsPerCheckCollector;\r\n payee.maxItemsPerCheckOverride = null;\r\n }\r\n\r\n async save() {\r\n if(this.isAppliedToAll) {\r\n if(this.settings.maxItemsPerCheck > this.MAX_PAYMENT_ITEMS) {\r\n this._toastr.error(`Max Payment Items must be below ${this.MAX_PAYMENT_ITEMS}`);\r\n return;\r\n }\r\n } else {\r\n if(some(this.collectorOverridesUI, x => x.inputValue > this.MAX_PAYMENT_ITEMS)) {\r\n this._toastr.error(`Max Payment Items must be below ${this.MAX_PAYMENT_ITEMS}`);\r\n return;\r\n }\r\n if(some(this.collectorOverridesUI, x => x.maxItemsPerCheckCollector && x.inputValue > x.maxItemsPerCheckCollector)) {\r\n this._toastr.error('Max Payment Items cannot exceed value at collector\\'s protocol');\r\n return;\r\n }\r\n }\r\n\r\n const busyMsg = 'saving';\r\n this.busyIndicatorMessageManager.add('Saving', busyMsg);\r\n\r\n try {\r\n if(!this.isAppliedToAll) {\r\n this.settings.collectorOverrides = this.settings.collectorOverrides.map((x, i) => {\r\n if (!this.collectorOverridesUI[i].inputValue) {\r\n // No override entered. Clear it from the model.\r\n x.maxItemsPerCheckOverride = null;\r\n }\r\n else if (x.maxItemsPerCheckCollector &&\r\n this.collectorOverridesUI[i].inputValue === x.maxItemsPerCheckCollector) {\r\n // Override entered but it matches Collector setting. Clear it from the model.\r\n x.maxItemsPerCheckOverride = null;\r\n }\r\n else {\r\n // Override entered and doesn't match Collector setting\r\n // or Collector has no setting. Clear it from the model.\r\n x.maxItemsPerCheckOverride = this.collectorOverridesUI[i].inputValue;\r\n }\r\n\r\n return x;\r\n });\r\n }\r\n\r\n this.settings = await this._paymentBatchService.savePaymentBatchSettings(this.paymentBatch.paymentBatchId, this.settings);\r\n this._setCollectorOverridesUI();\r\n\r\n this._exitEditMode();\r\n } finally {\r\n this.busyIndicatorMessageManager.remove(busyMsg);\r\n }\r\n }\r\n\r\n cancel() {\r\n this._exitEditMode();\r\n this.settings = this._originalSettings;\r\n this.collectorOverridesUI = this._originalCollectorOverridesUI;\r\n // this.settingsForm.reset(this.settings);\r\n }\r\n\r\n private _exitEditMode() {\r\n this._navigationService.disableNavWarning();\r\n this.editMode = false;\r\n this.editChange.emit(false);\r\n }\r\n\r\n private _setCollectorOverridesUI(): void {\r\n this.collectorOverridesUI = this.settings.collectorOverrides.map(x => ({\r\n ...x,\r\n inputValue: x.maxItemsPerCheckOverride ?? x.maxItemsPerCheckCollector\r\n }));\r\n }\r\n}\r\n","import { IGetRowsParams, GridApi } from 'ag-grid-community';\r\nimport { AgGridDataSourceBase, AgGridDataSourceResult } from 'src/app/Compliance/AgGrid';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\n\r\nexport interface PaymentBatchAddPaymentDataSourceParams {\r\n paymentBatchId: number;\r\n fromDate?: Date;\r\n toDate?: Date;\r\n selection?: Core.PaymentBatchAddPaymentSearchModel\r\n}\r\n\r\nexport class PaymentBatchAddPaymentAgGridDataSource extends AgGridDataSourceBase {\r\n constructor(\r\n private readonly _gridApi: GridApi,\r\n private readonly _paymentBatchService: PaymentBatchService,\r\n protected _dataSourceParamsFn: () => PaymentBatchAddPaymentDataSourceParams\r\n ) { super(_gridApi); }\r\n\r\n private readonly _propertyMap: Compliance.NameValuePair[] = [\r\n { name: 'parcelAcctNum', value: Core.PaymentBatchAddPaymentEnum.ParcelAcctNum },\r\n { name: 'siteName', value: Core.PaymentBatchAddPaymentEnum.SiteName },\r\n { name: 'state', value: Core.PaymentBatchAddPaymentEnum.State },\r\n { name: 'collector', value: Core.PaymentBatchAddPaymentEnum.Collector },\r\n { name: 'dueDate', value: Core.PaymentBatchAddPaymentEnum.DueDate },\r\n { name: 'installmentName', value: Core.PaymentBatchAddPaymentEnum.InstallmentName },\r\n { name: 'paymentAmount', value: Core.PaymentBatchAddPaymentEnum.PaymentAmount },\r\n { name: 'transmittalOutput', value: Core.PaymentBatchAddPaymentEnum.TransmittalOutput },\r\n { name: 'paymentType', value: Core.PaymentBatchAddPaymentEnum.PaymentType },\r\n { name: 'paymentStatus', value: Core.PaymentBatchAddPaymentEnum.PaymentStatus },\r\n { name: 'assessorName', value: Core.PaymentBatchAddPaymentEnum.AssessorName},\r\n { name: 'sitePayRes', value: Core.PaymentBatchAddPaymentEnum.SitePayRes},\r\n { name: 'sitePaymentResp', value: Core.PaymentBatchAddPaymentEnum.SitePaymentResp},\r\n { name: 'parcelPayRes', value: Core.PaymentBatchAddPaymentEnum.ParcelPayRes},\r\n { name: 'parcelPaymentResp', value: Core.PaymentBatchAddPaymentEnum.ParcelPaymentResp}\r\n ];\r\n\r\n async getRowIdsInternal(startIndex: number, endIndex: number): Promise> {\r\n const searchParams: Core.PaymentBatchAddPaymentSearchModel = this.getSearchModel(startIndex, endIndex);\r\n\r\n return await this._paymentBatchService.getPaymentBatchPaymentRowIds(searchParams);\r\n }\r\n\r\n public getSearchModel(startIndex?: number, endIndex?: number): Core.PaymentBatchAddPaymentSearchModel {\r\n return {\r\n pagination: {\r\n skip: (startIndex) ? startIndex : 0,\r\n take: (endIndex) ? endIndex - startIndex : 2000000000,\r\n noPagination: !startIndex && !endIndex ? true : false\r\n },\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n paymentBatchId: this._dataSourceParams.paymentBatchId,\r\n fromDate: this._dataSourceParams.fromDate,\r\n toDate: this._dataSourceParams.toDate\r\n };\r\n }\r\n\r\n getSearchParamsWithoutPagination() : Core.PaymentBatchAddPaymentSearchModel{\r\n this.refreshDataSourceParams();\r\n return {\r\n columnFilters: this.getColumnFilters(this._propertyMap),\r\n sortColumns: this.getSortColumns(this._propertyMap),\r\n fromDate: this._dataSourceParams.fromDate,\r\n toDate: this._dataSourceParams.toDate,\r\n paymentBatchId: this._dataSourceParams.paymentBatchId\r\n };\r\n }\r\n\r\n public async getSelectedRowTotals(selectedRowsModel: Compliance.SelectedRowsModel): Promise {\r\n const searchParams = this.getSearchParamsWithoutPagination();\r\n searchParams.selection = selectedRowsModel;\r\n searchParams.pagination = {\r\n skip: 0,\r\n take: 100\r\n };\r\n\r\n const { totals } = await this._paymentBatchService.getPaymentBatchPaymentList(searchParams);\r\n\r\n return totals;\r\n }\r\n\r\n\r\n protected canGetRows(): boolean {\r\n return true;\r\n }\r\n\r\n protected async getRowsInternal(params: IGetRowsParams): Promise {\r\n const searchParams: Core.PaymentBatchAddPaymentSearchModel = this.getSearchModel(params.startRow, params.endRow);\r\n\r\n const result = await this._paymentBatchService.getPaymentBatchPaymentList(searchParams);\r\n\r\n return {\r\n rows: result.data,\r\n totalRows: result.totalRows\r\n } as AgGridDataSourceResult;\r\n }\r\n}\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { IWeissmanModalComponent } from '../../../Compliance/WeissmanModalService';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\nimport { BusyIndicatorService } from '../../../Busy-Indicator';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { AgGridMultiSelectTracker } from '../../../Compliance/AgGrid/MultiSelectTracker';\r\nimport { AgGridOptionsBuilder } from '../../../Compliance/AgGrid';\r\nimport { GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { Subject, Subscription } from 'rxjs';\r\nimport { PaymentBatchAddPaymentAgGridDataSource, PaymentBatchAddPaymentDataSourceParams } from './agGridDataSource';\r\nimport { DecimalPipe } from '@angular/common';\r\nimport { PAYMENT_BATCH_ADD_PAYMENT_COLUMNS } from './paymentBatchAddPayment.columns';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { HelpService } from '../../../UI-Lib/Help-Tooltip';\r\nimport { PAYMENT_BATCH_DETAILS_HELP } from '../paymentBatchDetails.component.help';\r\nimport * as moment from 'moment';\r\nimport { WeissmanKeyValueDisplayPipe } from 'src/app/UI-Lib/Pipes';\r\nimport { cloneDeep } from 'lodash';\r\n\r\n@Component({\r\n selector: 'payment-batch-add-payments-modal',\r\n template: `\r\n \r\n
\r\n \r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n to\r\n
\r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n \r\n
\r\n `\r\n})\r\n\r\nexport class PaymentBatchAddPaymentsModalComponent implements OnInit, OnDestroy,\r\n IWeissmanModalComponent {\r\n constructor(\r\n private readonly _paymentBatchService: PaymentBatchService,\r\n private readonly _busyIndicatorService: BusyIndicatorService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _helpService: HelpService,\r\n public readonly decimalPipe: DecimalPipe,\r\n private readonly _keyValueDisplayPipe: WeissmanKeyValueDisplayPipe,\r\n private readonly _bsModalRef: BsModalRef\r\n ) { }\r\n\r\n params: number;\r\n result: Core.PaymentBatchAddPaymentResultModel;\r\n\r\n dataSourceParams: PaymentBatchAddPaymentDataSourceParams;\r\n selectedRowsModel: Compliance.SelectedRowsModel;\r\n totalsLoading: any;\r\n\r\n gridId: System.Guid = '68B1A759-6709-4F4A-92B7-02985301DE15';\r\n gridTracker: AgGridMultiSelectTracker;\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true,\r\n onFilterChanged: () => this.gridTracker.onGridFilterChanged(),\r\n onSortChanged: () => this.gridTracker.onGridSortChanged(),\r\n rowClassRules: {\r\n 'ag-row-selected': (params) => params.data && this.gridTracker.isRowSelected(params.data.paymentId),\r\n 'selected-totals-row': (params) => params.data && params.data.selectedTotalsRow\r\n },\r\n rowModelType: 'infinite'\r\n }).withInfiniteScroll(100)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withColumnPinning()\r\n .build();\r\n\r\n private _gridApi: GridApi;\r\n private _gridMultiSelectSub: Subscription;\r\n private _destroy$: Subject = new Subject();\r\n private _gridDataSource: PaymentBatchAddPaymentAgGridDataSource;\r\n private _lastFetchedTotals: Core.PaymentBatchPaymentTotalsModel;\r\n\r\n\r\n ngOnInit() {\r\n this._helpService.setContent(PAYMENT_BATCH_DETAILS_HELP);\r\n\r\n const now = new Date();\r\n // Set initial From Date to now - 3 months, beginning of month, 12:00:00\r\n // Set initial To Date to now + 3 months, end of month, 23:59:59\r\n this.dataSourceParams = {\r\n paymentBatchId: this.params,\r\n fromDate: moment(now).subtract(3, 'months').startOf('month').toDate(),\r\n toDate: moment(now).add(15, 'months').endOf('month').toDate()\r\n },\r\n this.selectedRowsModel = {\r\n selectAllRows: false,\r\n selectedRows: []\r\n };\r\n\r\n this.result = {\r\n paymentBatchId: this.params,\r\n succeeded: false,\r\n addedCount: 0,\r\n };\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._gridMultiSelectSub && this._gridMultiSelectSub.unsubscribe();\r\n this._destroy$.next();\r\n this._destroy$.complete();\r\n }\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n this._gridApi.showLoadingOverlay();\r\n this.gridTracker = new AgGridMultiSelectTracker(this.gridOptions, this._getGridRowIds.bind(this));\r\n\r\n const columns = PAYMENT_BATCH_ADD_PAYMENT_COLUMNS(this);\r\n this._gridApi.setColumnDefs(columns);\r\n\r\n this._gridMultiSelectSub = this.gridTracker.selectedRows$.subscribe(x => {\r\n this.selectedRowsModel = x;\r\n this._reloadTotals();\r\n });\r\n\r\n this._setDataSource();\r\n }\r\n\r\n async save() {\r\n const busyRef = this._busyIndicatorService.show({ message: 'Adding payments...' });\r\n\r\n try {\r\n const request: Core.PaymentBatchAddPaymentRequestModel = {\r\n searchParams: this._gridDataSource.getSearchModel(),\r\n selection: this.selectedRowsModel\r\n };\r\n\r\n this.result = await this._paymentBatchService.addPaymentsToPaymentBatch(request.searchParams.paymentBatchId, request);\r\n if (!this.result.succeeded)\r\n {\r\n this._toastr.error(this.result.errorMessage);\r\n return;\r\n }\r\n\r\n this._bsModalRef.hide();\r\n }\r\n catch (e) {\r\n const errorMessage = e && e.error && e.error.message ? e.error.message : 'Unexpected error without message';\r\n this._toastr.error(errorMessage);\r\n }\r\n finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n cancel(): void {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n async refresh(): Promise {\r\n this._refreshDataSource();\r\n }\r\n\r\n handleTotalsUpdate = (totals: Core.PaymentBatchPaymentTotalsModel, isLoading: boolean = false) => {\r\n const model = {};\r\n const paymentRow: any = {\r\n model,\r\n getModel: () => { return model; },\r\n displayPipe: this._keyValueDisplayPipe,\r\n index: 0,\r\n paymentAmount: totals && totals.paymentAmountTotal,\r\n installmentName: 'SELECTED',\r\n selectedTotalsRow: true\r\n };\r\n\r\n if (isLoading) {\r\n this.totalsLoading = this._gridDataSource.getLoadingMessage(msg => {\r\n paymentRow.installmentName = msg;\r\n this._gridApi.setPinnedBottomRowData([paymentRow]);\r\n });\r\n return;\r\n } else if (!isLoading && this.totalsLoading >= 0) {\r\n clearInterval(this.totalsLoading);\r\n this.totalsLoading = null;\r\n }\r\n\r\n const totalRows = this.gridTracker.hasAnythingSelected() ? [paymentRow] : [];\r\n\r\n setTimeout(() => this._gridApi.setPinnedBottomRowData(totalRows), 100);\r\n };\r\n\r\n private async _getGridRowIds(startIndex: number, endIndex: number): Promise> {\r\n return this._gridDataSource.getRowIdsInternal(startIndex, endIndex);\r\n }\r\n\r\n private async _refreshDataSource(): Promise {\r\n if (!this._gridDataSource) {\r\n const success = this._setDataSource();\r\n if (!success) {\r\n return;\r\n }\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n this._gridDataSource.refresh();\r\n }\r\n\r\n private _setDataSource(): boolean {\r\n if (!this._gridApi || this._gridDataSource) {\r\n return false;\r\n }\r\n\r\n this.gridTracker.clear(false);\r\n\r\n const dataSourceParams = (): PaymentBatchAddPaymentDataSourceParams => {\r\n return this.dataSourceParams;\r\n };\r\n\r\n this._gridDataSource = new PaymentBatchAddPaymentAgGridDataSource(\r\n this._gridApi,\r\n this._paymentBatchService,\r\n dataSourceParams,\r\n );\r\n\r\n this._gridApi.setDatasource(this._gridDataSource);\r\n return true;\r\n }\r\n\r\n private async _reloadTotals(): Promise {\r\n if (!this._gridDataSource) {\r\n return;\r\n }\r\n\r\n const result = await this._gridDataSource.getSelectedRowTotals(this.gridTracker.getSelectedRowsModel());\r\n this.handleTotalsUpdate(result);\r\n }\r\n}\r\n","import { ColDef } from 'ag-grid-community';\r\nimport { AgGridMultiSelectRendererParams, AgGridMultiSelectedCellRenderer, AgGridMultiSelectedHeaderRenderer, AgGridMultiSelectHeaderRendererParams } from 'src/app/Compliance/AgGrid/MultiSelectTracker';\r\nimport { PaymentBatchAddPaymentsModalComponent } from './addPaymentsToBatchModal.component';\r\nimport { AgGridColumns, AgGridFilterParams } from 'src/app/Compliance/AgGrid';\r\nimport { WeissmanDateFormat } from 'src/app/UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\n\r\nexport const PAYMENT_BATCH_ADD_PAYMENT_COLUMNS = (classRef: PaymentBatchAddPaymentsModalComponent): ColDef[] => [\r\n {\r\n colId: 'grid-column-multiselect',\r\n headerName: '',\r\n field: 'paymentId',\r\n width: AgGridColumns.selectionColumnWidth,\r\n suppressSizeToFit: true,\r\n suppressAutoSize: true,\r\n suppressColumnsToolPanel: true,\r\n editable: false,\r\n pinned: 'left',\r\n lockPinned: true,\r\n lockVisible: true,\r\n lockPosition: true,\r\n suppressMovable: true,\r\n headerComponentFramework: AgGridMultiSelectedHeaderRenderer,\r\n headerComponentParams: { tracker: classRef.gridTracker } as AgGridMultiSelectRendererParams,\r\n cellRendererFramework: AgGridMultiSelectedCellRenderer,\r\n cellRendererParams: { tracker: classRef.gridTracker } as AgGridMultiSelectRendererParams,\r\n pinnedRowCellRenderer: () => {return '';}\r\n } as ColDef,\r\n {\r\n headerName: 'Payment Status',\r\n field: 'paymentStatus',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Parcel Acct Num',\r\n field: 'parcelAcctNum',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Site',\r\n field: 'siteName',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.stateAbbreviationColumnWidth\r\n },\r\n {\r\n headerName: 'Collector',\r\n field: 'collector',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Due Date',\r\n field: 'dueDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as Core.PaymentBatchAddPaymentModel;\r\n if (!(model && model.dueDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.dueDate, true, 'stored');\r\n },\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Installment',\r\n field: 'installmentName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Payment Amount',\r\n field: 'paymentAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => classRef.decimalPipe.transform(x.value, '1.2-2'),\r\n cellClass: 'text-align-right'\r\n },\r\n {\r\n headerName: 'Output Type',\r\n field: 'transmittalOutput',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Payment Type',\r\n field: 'paymentType',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Assessor',\r\n field: 'assessorName',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Site Pay Res',\r\n field: 'sitePayRes',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Site Payment Resp',\r\n field: 'sitePaymentResp',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Parcel Pay Res',\r\n field: 'parcelPayRes',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n {\r\n headerName: 'Parcel Payment Resp',\r\n field: 'parcelPaymentResp',\r\n width: AgGridColumns.textColumnWidth,\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams\r\n },\r\n];\r\n","import { Component } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { ToastrService } from 'ngx-toastr';\r\nimport { BusyIndicatorMessageManager } from 'src/app/Busy-Indicator';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\n@Component({\r\n selector: 'check-import-modal',\r\n template: `\r\n 0\">\r\n\r\n \r\n
\r\n \r\n
\r\n
\r\n `\r\n})\r\n\r\n\r\nexport class CheckImportModalComponent implements IWeissmanModalComponent {\r\n constructor(\r\n private readonly _bsModalRef: BsModalRef,\r\n private readonly _toastr: ToastrService\r\n ) { }\r\n\r\n params: number;\r\n result: File;\r\n\r\n busyIndicatorMessageManager = new BusyIndicatorMessageManager();\r\n\r\n file: File;\r\n\r\n filesPicked(files: File[]) {\r\n if(files.length) {\r\n this.file = files[0];\r\n }\r\n\r\n const { name } = files[0];\r\n const index = name.lastIndexOf('.');\r\n if (index !== 0) {\r\n const fileExtension = name.substr(index + 1).toLowerCase();\r\n if (fileExtension === 'xls' || fileExtension === 'xlsx') {\r\n this.file = files[0];\r\n } else {\r\n this._toastr.error('Only .xlx or .xlsx file formats are allowed.');\r\n this.file = undefined;\r\n }\r\n }\r\n }\r\n\r\n async returnFile() {\r\n this.result = this.file;\r\n this._bsModalRef.hide();\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n\r\n}","import { CurrencyPipe } from '@angular/common';\r\nimport { Component, Input } from '@angular/core';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { reduce, startsWith } from 'lodash';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from 'src/app/Compliance/AgGrid';\r\nimport { WeissmanDateFormat } from 'src/app/UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\n\r\ninterface PaymentModelUI extends Core.PaymentBatchCheckImportPaymentModel {\r\n isTotal?: boolean;\r\n}\r\n\r\n@Component({\r\n selector: 'finalize-check-import-payment-grid',\r\n template: `\r\n

Payments

\r\n \r\n \r\n `\r\n})\r\n\r\nexport class FinalizeCheckImportPaymentGridComponent {\r\n constructor(private readonly _currencyPipe: CurrencyPipe) { }\r\n\r\n @Input() checkImportPayments: PaymentModelUI[];\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n rowClassRules: {\r\n 'row-matched': (params) => {\r\n const gridRow = params.data as PaymentModelUI;\r\n return !!gridRow.checkNo && (!gridRow.isTotal || startsWith(gridRow.collector, 'Matched'));\r\n },\r\n 'totals-row': (params) => {\r\n const gridRow = params.data as PaymentModelUI;\r\n return gridRow.isTotal;\r\n }\r\n },\r\n suppressScrollOnNewData: true\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n refreshing: boolean;\r\n\r\n private _gridApi: GridApi;\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Payee',\r\n field: 'collector',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellStyle: params => {\r\n const row = params.data as PaymentModelUI;\r\n return row.isTotal ? {textAlign: 'right', fontWeight: 'bold'} : null;\r\n }\r\n },\r\n {\r\n headerName: 'State',\r\n field: 'state',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.stateAbbreviationColumnWidth\r\n },\r\n {\r\n headerName: 'Parcel Acct Num',\r\n field: 'parcelAcctNum',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth\r\n },\r\n {\r\n headerName: 'Payment Amount',\r\n field: 'paymentAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Payment Due Date',\r\n field: 'dueDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as PaymentModelUI;\r\n if (!(model && model.dueDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.dueDate, true, 'stored');\r\n },\r\n },\r\n {\r\n headerName: 'Check No',\r\n field: 'checkNo',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n },\r\n {\r\n headerName: 'Check Date',\r\n field: 'checkDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as PaymentModelUI;\r\n if (!(model && model.checkDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.checkDate, true, 'stored');\r\n },\r\n },\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'collector',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._gridApi.sizeColumnsToFit();\r\n\r\n this.setRowData();\r\n }\r\n\r\n setRowData() {\r\n if (!(this._gridApi && this.checkImportPayments)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this.checkImportPayments);\r\n\r\n const totalRows = [];\r\n const matchedPayments = this.checkImportPayments.filter(x => !!x.checkNo);\r\n\r\n if(matchedPayments.length) {\r\n const matchedRow = this._getTotalRow(matchedPayments, true);\r\n totalRows.push(matchedRow);\r\n }\r\n\r\n const totalRow = this._getTotalRow(this.checkImportPayments);\r\n totalRows.push(totalRow);\r\n\r\n this._gridApi.setPinnedBottomRowData(totalRows);\r\n }\r\n\r\n private _formatCurrency(value: number): string {\r\n if(value == null) {\r\n return '';\r\n }\r\n\r\n const formattedVal = this._currencyPipe.transform(Math.abs(value), 'USD', 'symbol-narrow');\r\n return value < 0 ? `(${formattedVal})` : formattedVal;\r\n }\r\n\r\n private _getTotalRow(payments: PaymentModelUI[], justMatched: boolean = false) {\r\n const paymentAmount = reduce(payments, (sum, payment) => {\r\n sum += payment.paymentAmount;\r\n return sum;\r\n }, 0);\r\n\r\n const totalLabel = justMatched ? 'Matched' : 'Total';\r\n\r\n return {\r\n isTotal: true,\r\n paymentAmount,\r\n collector: `${totalLabel}: ${payments.length}`\r\n };\r\n }\r\n}","import { CurrencyPipe } from '@angular/common';\r\nimport { Component, Input } from '@angular/core';\r\nimport { ColDef, GridApi, GridOptions, GridReadyEvent } from 'ag-grid-community';\r\nimport { reduce, startsWith } from 'lodash';\r\nimport { AgGridOptionsBuilder, AgGridFilterParams, AgGridColumns } from 'src/app/Compliance/AgGrid';\r\nimport { WeissmanDateFormat } from 'src/app/UI-Lib/Pipes/Date-Format/date-formatting.pipe';\r\n\r\ninterface CheckModelUI extends Core.PaymentBatchCheckImportCheckModel {\r\n isTotal?: boolean\r\n}\r\n\r\n@Component({\r\n selector: 'finalize-check-import-checks-grid',\r\n template: `\r\n

Imported Checks

\r\n \r\n \r\n `\r\n})\r\n\r\nexport class FinalizeCheckImportChecksGridComponent {\r\n constructor(private readonly _currencyPipe: CurrencyPipe) { }\r\n\r\n @Input() checkImportChecks: CheckModelUI[];\r\n\r\n gridOptions: GridOptions = new AgGridOptionsBuilder({\r\n suppressScrollOnNewData: true,\r\n rowClassRules: {\r\n 'row-matched': (params) => {\r\n const gridRow = params.data as CheckModelUI;\r\n return !!gridRow.paymentCount && (!gridRow.isTotal || startsWith(gridRow.collector, 'Matched'));\r\n },\r\n 'totals-row': (params) => {\r\n const gridRow = params.data as CheckModelUI;\r\n return gridRow.isTotal;\r\n }\r\n },\r\n })\r\n .withContext(this)\r\n .withLoadingOverlay()\r\n .withColumnResize()\r\n .withMultipleColumnSort()\r\n .withTextSelection()\r\n .build();\r\n\r\n refreshing: boolean;\r\n\r\n private _gridApi: GridApi;\r\n\r\n onAgGridReady(event: GridReadyEvent): void {\r\n this._gridApi = event.api;\r\n\r\n const columns: ColDef[] = [\r\n {\r\n headerName: 'Payee',\r\n field: 'collector',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnWidth,\r\n cellStyle: params => {\r\n const row = params.data as CheckModelUI;\r\n return row.isTotal ? {textAlign: 'right', fontWeight: 'bold'} : null;\r\n }\r\n },\r\n {\r\n headerName: 'Check Amount',\r\n field: 'checkAmount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n valueFormatter: x => this._formatCurrency(x.value),\r\n cellClass: 'text-align-right',\r\n },\r\n {\r\n headerName: 'Check No',\r\n field: 'checkNo',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n },\r\n {\r\n headerName: 'Check Date',\r\n field: 'checkDate',\r\n width: AgGridColumns.dateColumnWidth,\r\n filter: 'agDateColumnFilter',\r\n filterParams: AgGridFilterParams.dateFilterParamsWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.dateFloatingFilterParams,\r\n valueFormatter: (params) => {\r\n const model = params.data as CheckModelUI;\r\n if (!(model && model.checkDate)) {\r\n return '';\r\n }\r\n\r\n return WeissmanDateFormat(model.checkDate, true, 'stored');\r\n },\r\n },\r\n {\r\n headerName: 'Payment Count',\r\n field: 'paymentCount',\r\n width: AgGridColumns.numericColumnWidth,\r\n filter: 'agNumberColumnFilter',\r\n filterParams: AgGridFilterParams.numberFilterWithBlankOptionsParams,\r\n floatingFilterComponentParams: AgGridFilterParams.numberFloatingFilterParams,\r\n },\r\n {\r\n headerName: 'Unmatched Reason',\r\n field: 'unmatchedReason',\r\n filter: 'agTextColumnFilter',\r\n filterParams: AgGridFilterParams.textFilterParams,\r\n floatingFilterComponentParams: AgGridFilterParams.textFloatingFilterParams,\r\n width: AgGridColumns.textColumnLargeWidth\r\n }\r\n ];\r\n\r\n const defaultSortModel = [\r\n {\r\n colId: 'collector',\r\n sort: 'asc'\r\n }\r\n ];\r\n\r\n this._gridApi.setColumnDefs(columns);\r\n this._gridApi.setSortModel(defaultSortModel);\r\n this._gridApi.sizeColumnsToFit();\r\n\r\n this.setRowData();\r\n }\r\n\r\n setRowData() {\r\n if (!(this._gridApi && this.checkImportChecks)) {\r\n return;\r\n }\r\n\r\n this._gridApi.setRowData(this.checkImportChecks);\r\n\r\n const totalRows = [];\r\n const matchedPayments = this.checkImportChecks.filter(x => !!x.paymentCount);\r\n\r\n if(matchedPayments.length) {\r\n const matchedRow = this._getTotalRow(matchedPayments, true);\r\n totalRows.push(matchedRow);\r\n }\r\n\r\n const totalRow = this._getTotalRow(this.checkImportChecks);\r\n totalRows.push(totalRow);\r\n\r\n this._gridApi.setPinnedBottomRowData(totalRows);\r\n }\r\n\r\n private _formatCurrency(value: number): string {\r\n if(value == null) {\r\n return '';\r\n }\r\n\r\n const formattedVal = this._currencyPipe.transform(Math.abs(value), 'USD', 'symbol-narrow');\r\n return value < 0 ? `(${formattedVal})` : formattedVal;\r\n }\r\n\r\n private _getTotalRow(payments: CheckModelUI[], justMatched: boolean = false) {\r\n const checkAmount = reduce(payments, (sum, payment) => {\r\n sum += payment.checkAmount;\r\n return sum;\r\n }, 0);\r\n\r\n const paymentCount = reduce(payments, (sum, payment) => {\r\n sum += payment.paymentCount;\r\n return sum;\r\n }, 0);\r\n\r\n const totalLabel = justMatched ? 'Matched' : 'Total';\r\n return {\r\n isTotal: true,\r\n checkAmount,\r\n paymentCount,\r\n collector: `${totalLabel}: ${payments.length}`\r\n };\r\n }\r\n}","import { Component, OnInit, ViewChild } from '@angular/core';\r\nimport { BsModalRef } from 'ngx-bootstrap/modal';\r\nimport { IWeissmanModalComponent } from 'src/app/Compliance/WeissmanModalService';\r\nimport { PaymentBatchService } from 'src/app/Payment-Batch/paymentBatch.service';\r\nimport { FinalizeCheckImportPaymentGridComponent } from './finalizeCheckImportPaymentGrid.componet';\r\nimport { FinalizeCheckImportChecksGridComponent } from './finalizeCheckImportChecksGrid.component';\r\nimport { every } from 'lodash';\r\nimport { MessageModalService } from 'src/app/UI-Lib/Message-Box/messageModal.service';\r\n\r\nexport interface FinalizeCheckImportModalParams {\r\n paymentBatchId: number;\r\n}\r\n\r\n@Component({\r\n selector: 'finalize-check-import-modal',\r\n template: `\r\n \r\n \r\n
\r\n
\r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n `\r\n})\r\n\r\nexport class FinalizeCheckImportModalComponent implements OnInit,\r\nIWeissmanModalComponent {\r\n constructor(private readonly _paymentBatchService: PaymentBatchService,\r\n private readonly _messageModalService: MessageModalService,\r\n private readonly _bsModalRef: BsModalRef\r\n ) { }\r\n\r\n @ViewChild('finalizeCheckImportPaymentGrid') finalizeCheckImportPaymentGrid: FinalizeCheckImportPaymentGridComponent;\r\n @ViewChild('finalizeCheckImportChecksGrid') finalizeCheckImportChecksGrid: FinalizeCheckImportChecksGridComponent;\r\n\r\n params: FinalizeCheckImportModalParams;\r\n result: boolean = false;\r\n\r\n checkImportModel: Core.PaymentBatchCheckImportModel;\r\n excludeMatchedItems: boolean = false;\r\n disableFinalize: boolean = true;\r\n isBusy: boolean = false;\r\n busyMessage: string = '';\r\n\r\n get checks() {\r\n return this.checkImportModel?.checks.filter(x => {\r\n return this.excludeMatchedItems ? !x.paymentCount : true;\r\n });\r\n }\r\n\r\n get payments() {\r\n return this.checkImportModel?.payments.filter(x => {\r\n return this.excludeMatchedItems ? !x.checkNo : true;\r\n });\r\n }\r\n\r\n async ngOnInit() {\r\n this.busyMessage = 'Loading Check Import';\r\n this.isBusy = true;\r\n try {\r\n this.checkImportModel = await this._paymentBatchService.getPaymentBatchCheckImport(this.params.paymentBatchId);\r\n this.disableFinalize = every(this.checkImportModel.payments, x => !x.checkNo);\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n filterItems() {\r\n setTimeout(() => {\r\n this.finalizeCheckImportPaymentGrid.setRowData();\r\n this.finalizeCheckImportChecksGrid.setRowData();\r\n });\r\n }\r\n\r\n async finalize() {\r\n this.busyMessage = 'Saving Import';\r\n this.isBusy = true;\r\n\r\n try {\r\n await this._paymentBatchService.savePaymentBatchCheckImport(\r\n this.checkImportModel.paymentBatchId,\r\n this.checkImportModel.paymentBatchCheckImportId\r\n );\r\n\r\n this.result = true;\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n async discard() {\r\n try {\r\n await this._messageModalService.confirm(\r\n 'Are you sure you wish to discard this import?',\r\n 'Confirm Discard');\r\n } catch (e) {\r\n return Promise.resolve();\r\n }\r\n\r\n this.busyMessage = 'Discarding Import';\r\n this.isBusy = true;\r\n\r\n try {\r\n await this._paymentBatchService.discardPaymentBatchCheckImport(\r\n this.checkImportModel.paymentBatchId,\r\n this.checkImportModel.paymentBatchCheckImportId\r\n );\r\n this._bsModalRef.hide();\r\n } finally {\r\n this.isBusy = false;\r\n }\r\n }\r\n\r\n cancel() {\r\n this._bsModalRef.hide();\r\n }\r\n}","
\r\n
\r\n

\r\n Batch Summary\r\n

\r\n
\r\n \r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Top Level Company:{{paymentBatch.topLevelCompanyName}}
Company:{{paymentBatch.company}}
Description:\r\n {{paymentBatch.description}}\r\n \r\n
Batch #:{{paymentBatch.batchNo}}
Batch Type:{{paymentBatch.batchTypeName}}{{paymentBatch.batchTypeName}}   [{{paymentBatch.workflowName}}]
\r\n
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
Total Payments:{{paymentBatch.paymentCount}}
Total Payment Amount:{{paymentBatch.paymentAmount | currency}}
Total Funded Amount:\r\n {{paymentBatch.fundedAmount | currency}}\r\n \r\n \r\n
Earliest Due Date:\r\n
\r\n {{paymentBatch.earliestDueDate | weissmanDateFormat}}\r\n
\r\n
Funding Due Date:\r\n
\r\n {{paymentBatch.fundingDueDate | weissmanDateFormat}}\r\n
\r\n
\r\n
\r\n
\r\n
\r\n Payment Batch cannot be advanced; total payment amount of Batch is $0.\r\n
\r\n
\r\n A change was made to Payments of the Batch that may have invalidated the AP and Check Feeds. Regeneration of the feeds is recommended.\r\n
\r\n
\r\n A change was made to Payments of the Batch that may have invalidated the AP Feed. Regeneration of the feed is recommended.\r\n
\r\n
\r\n \r\n
\r\n \r\n \r\n
\r\n
\r\n
\r\n
\r\n
\r\n
\r\n","import { Component, EventEmitter, Input, OnDestroy, Output } from '@angular/core';\r\nimport { WeissmanModalService } from '../../../Compliance/WeissmanModalService';\r\nimport { PaymentBatchAddPaymentsModalComponent } from '../Add-Payments-Modal/addPaymentsToBatchModal.component';\r\nimport { RefreshComponents } from '../paymentBatchDetails.component';\r\nimport { CheckImportModalComponent } from '../Check-Import-Modal/checkImportModal.component';\r\nimport { PaymentBatchService } from '../../paymentBatch.service';\r\nimport { BusyIndicatorService, IBusyIndicatorConfig } from 'src/app/Busy-Indicator';\r\nimport { Subject, takeUntil } from 'rxjs';\r\nimport { FinalizeCheckImportModalComponent } from '../Check-Import-Modal/Finalize/finalizeCheckImportModal.component';\r\nimport { cloneDeep } from 'lodash';\r\nimport { NavigationService } from '../../../Layout/navigation.service';\r\nimport { ToastrService } from 'ngx-toastr';\r\n\r\n@Component({\r\n selector: 'payment-batch-summary',\r\n templateUrl: 'paymentBatchSummary.component.html',\r\n styleUrls: ['paymentBatchSummary.component.scss']\r\n})\r\nexport class PaymentBatchSummaryComponent implements OnDestroy {\r\n constructor(\r\n private readonly _modalService: WeissmanModalService,\r\n private readonly _paymentBatchService: PaymentBatchService,\r\n private readonly _navigationService: NavigationService,\r\n private readonly _toastr: ToastrService,\r\n private readonly _busyIndicatorService: BusyIndicatorService\r\n ) { }\r\n\r\n @Input() paymentBatch: Core.PaymentBatchModel;\r\n @Input() isTransmittal: boolean;\r\n @Input() workflowStatus: Core.PaymentBatchDetailsWorkflowStatusModel;\r\n @Input() isPaymentGridActive: boolean;\r\n\r\n @Output() refreshPage: EventEmitter = new EventEmitter();\r\n\r\n editMode: boolean = false;\r\n\r\n private destroy$: Subject = new Subject();\r\n private _originalPaymentBatch: Core.PaymentBatchModel;\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next();\r\n this.destroy$.unsubscribe();\r\n }\r\n\r\n edit() {\r\n this._originalPaymentBatch = cloneDeep(this.paymentBatch);\r\n\r\n this.editMode = true;\r\n this._navigationService.enableNavWarning('Editing is in progress. Are you sure you want to leave?');\r\n }\r\n\r\n get canModifyDescription() : boolean {\r\n return this.editMode && this.workflowStatus?.canModifyDescription;\r\n }\r\n\r\n get canModifyFundedAmount() : boolean {\r\n return this.editMode && this.workflowStatus?.canModifyFundedAmount;\r\n }\r\n\r\n async save() {\r\n if(!this.paymentBatch.description) {\r\n this._toastr.error('Description cannot be blank');\r\n return;\r\n }\r\n\r\n const busyRef = this._busyIndicatorService.show({message: 'Saving'});\r\n try {\r\n this.paymentBatch = await this._paymentBatchService.savePaymentBatchDetails(this.paymentBatch.paymentBatchId, this.paymentBatch);\r\n this._exitEditMode();\r\n } finally {\r\n busyRef.hide();\r\n }\r\n }\r\n\r\n cancel() {\r\n this._exitEditMode();\r\n this.paymentBatch = this._originalPaymentBatch;\r\n }\r\n\r\n async launchAddPaymentsModal(): Promise {\r\n const params = this.paymentBatch.paymentBatchId;\r\n const result = await this._modalService.showAsync(\r\n PaymentBatchAddPaymentsModalComponent,\r\n params,\r\n 'modal-xl modal-no-max-width'\r\n );\r\n\r\n if(result?.succeeded) {\r\n this.refreshPage.emit({status: true, payments: true, packages: false});\r\n }\r\n }\r\n\r\n async importChecks() {\r\n const file = await this._modalService.showAsync(CheckImportModalComponent, this.paymentBatch.paymentBatchId, 'modal-md');\r\n\r\n if (!file) return;\r\n\r\n\r\n const formData = new FormData();\r\n\r\n formData.append('file', file);\r\n\r\n const longRunningProcessId = await this._paymentBatchService.startPaymentBatchCheckImport(\r\n this.paymentBatch.paymentBatchId, formData\r\n );\r\n const identifier = this._busyIndicatorService.generateUniqueMessageIdentifier();\r\n\r\n const busyConfig: IBusyIndicatorConfig = {\r\n identifier,\r\n longRunningProcessId,\r\n title: 'Check Import',\r\n message: 'Import Uploading',\r\n hasProgressBar: false,\r\n // canDismiss: !this.allocationId\r\n };\r\n\r\n const busyRef = this._busyIndicatorService.show(busyConfig);\r\n\r\n busyRef.onProgressBarComplete().pipe(takeUntil(this.destroy$)).subscribe((succeeded: boolean) => {\r\n busyRef.hide();\r\n if (succeeded) {\r\n this.refreshPage.emit({status: true, payments: false, packages: false});\r\n }\r\n\r\n this.destroy$.next();\r\n });\r\n\r\n busyRef.onDismiss().pipe(takeUntil(this.destroy$)).subscribe(() => {\r\n busyRef.hide();\r\n this.destroy$.next();\r\n });\r\n\r\n return busyRef;\r\n }\r\n\r\n async finalizeCheckImport() {\r\n const params = {\r\n paymentBatchId: this.paymentBatch.paymentBatchId\r\n };\r\n\r\n const didFinalize = await this._modalService.showAsync(FinalizeCheckImportModalComponent, params, 'modal-xl');\r\n\r\n const packages = false;\r\n const status = true;\r\n let payments = false;\r\n\r\n if(didFinalize) {\r\n payments = true;\r\n }\r\n\r\n this.refreshPage.emit({status, payments, packages});\r\n }\r\n\r\n private _exitEditMode() {\r\n this._navigationService.disableNavWarning();\r\n this.editMode = false;\r\n }\r\n}","import { NgModule } from '@angular/core';\r\nimport { CreatePaymentBatchModalComponent } from './Create-Payment-Batch-Modal/createPaymentBatchModal.component';\r\nimport { WeissmanSharedModule } from '../Common/weissman-shared.module';\r\nimport { HybridAdapterUtility } from '../Hybrid/hybrid-adapter.utility';\r\nimport { CompanyModule } from '../Entity/Company/company.module';\r\nimport { BusyIndicatorModule } from '../Busy-Indicator';\r\nimport { AgGridExtensionsModule } from '../Compliance/AgGrid/agGridExtensions.module';\r\nimport { AgGridModule } from 'ag-grid-angular';\r\nimport { PaymentBatchListGridActionCellRendererComponent } from './Command-Center/agGridActionCellRenderer.component';\r\nimport { PaymentBatchCommandCenterComponent } from './Command-Center/paymentBatch.component';\r\nimport { PaymentBatchService } from './paymentBatch.service';\r\nimport { PaymentBatchDetailsComponent } from './Payment-Batch-Details/paymentBatchDetails.component';\r\nimport { PaymentBatchPaymentsGridComponent } from './Payment-Batch-Details/Payments-Grid/paymentBatchPaymentsGrid.component';\r\nimport { PaymentBatchPaymentsGridActionCellRendererComponent } from './Payment-Batch-Details/Payments-Grid/agGridActionCellRenderer.component';\r\nimport { TransmittalModule } from '../Processing/Transmittal/transmittal.module';\r\nimport { PaymentBatchAddPaymentsModalComponent } from './Payment-Batch-Details/Add-Payments-Modal/addPaymentsToBatchModal.component';\r\nimport { PaymentBatchRepository } from '../Core-Repositories/paymentBatch.repository';\r\nimport { AddPaymentsToBatchModalComponent } from './Add-Payments-To-Batch-Modal/addPaymentsToBatchModal.component';\r\nimport { AddPaymentsToBatchModalService } from './Add-Payments-To-Batch-Modal/addPaymentsToBatchModal.service';\r\nimport { PaymentBatchTaskExceptionModalComponent } from './Payment-Batch-Details/Task-Exception-Modal/paymentBatchTaskExceptionModal.component';\r\nimport { PaymentBatchPackagesComponent } from './Payment-Batch-Details/Packages-Table/paymentBatchPackages.component';\r\nimport { PaymentBatchOutputComponent } from './Payment-Batch-Details/Output/paymentBatchOutput.component';\r\nimport { PaymentBatchPaymentsGridPaymentErrorsCellRendererComponent } from './Payment-Batch-Details/Payments-Grid/agGridPaymentErrorsCellRenderer.component';\r\nimport { PaymentBatchSettingsComponent } from './Payment-Batch-Details/Settings/paymentBatchSettings.component';\r\nimport { CheckImportModalComponent } from './Payment-Batch-Details/Check-Import-Modal/checkImportModal.component';\r\nimport { FinalizeCheckImportPaymentGridComponent } from './Payment-Batch-Details/Check-Import-Modal/Finalize/finalizeCheckImportPaymentGrid.componet';\r\nimport { FinalizeCheckImportChecksGridComponent } from './Payment-Batch-Details/Check-Import-Modal/Finalize/finalizeCheckImportChecksGrid.component';\r\nimport { FinalizeCheckImportModalComponent } from './Payment-Batch-Details/Check-Import-Modal/Finalize/finalizeCheckImportModal.component';\r\nimport { PaymentBatchSummaryComponent } from './Payment-Batch-Details/Payment-Batch-Summary/paymentBatchSummary.component';\r\nimport { PaymentBatchFiltersComponent } from './Command-Center/Filters/paymentBatchFilters.component';\r\nimport { ShippingMethodsModalComponent } from './Payment-Batch-Details/Output/shippingMethodsModal.component';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n WeissmanSharedModule,\r\n CompanyModule,\r\n AgGridExtensionsModule,\r\n AgGridModule.withComponents([\r\n PaymentBatchListGridActionCellRendererComponent,\r\n PaymentBatchPaymentsGridActionCellRendererComponent,\r\n PaymentBatchPaymentsGridPaymentErrorsCellRendererComponent\r\n ]),\r\n BusyIndicatorModule.forRoot(),\r\n TransmittalModule\r\n ],\r\n declarations: [\r\n CreatePaymentBatchModalComponent,\r\n PaymentBatchCommandCenterComponent,\r\n PaymentBatchListGridActionCellRendererComponent,\r\n PaymentBatchDetailsComponent,\r\n PaymentBatchPaymentsGridActionCellRendererComponent,\r\n PaymentBatchPaymentsGridComponent,\r\n PaymentBatchAddPaymentsModalComponent,\r\n AddPaymentsToBatchModalComponent,\r\n PaymentBatchTaskExceptionModalComponent,\r\n PaymentBatchPackagesComponent,\r\n PaymentBatchOutputComponent,\r\n PaymentBatchPaymentsGridPaymentErrorsCellRendererComponent,\r\n PaymentBatchSettingsComponent,\r\n CheckImportModalComponent,\r\n FinalizeCheckImportPaymentGridComponent,\r\n FinalizeCheckImportChecksGridComponent,\r\n FinalizeCheckImportModalComponent,\r\n PaymentBatchSummaryComponent,\r\n PaymentBatchFiltersComponent,\r\n ShippingMethodsModalComponent\r\n ],\r\n providers: [\r\n PaymentBatchService,\r\n PaymentBatchRepository,\r\n AddPaymentsToBatchModalService\r\n ],\r\n exports: []\r\n})\r\nexport class PaymentBatchModule {\r\n static setupModule(): void {\r\n hybridAdapterUtility.downgradeNg2Component('paymentBatchCommandCenter', PaymentBatchCommandCenterComponent);\r\n hybridAdapterUtility.downgradeNg2Component('paymentBatchDetails', PaymentBatchDetailsComponent);\r\n hybridAdapterUtility.downgradeNg2Provider('addPaymentsToBatchModalService', AddPaymentsToBatchModalService);\r\n }\r\n}","import 'zone.js';\r\nimport 'reflect-metadata';\r\nimport { Decimal } from 'decimal.js';\r\nimport { BrowserModule } from '@angular/platform-browser';\r\nimport { HTTP_INTERCEPTORS, HttpClientModule } from '@angular/common/http';\r\nimport { DoBootstrap, NgModule } from '@angular/core';\r\nimport { UpgradeModule } from '@angular/upgrade/static';\r\nimport { AccountModule } from './Account/account.module';\r\nimport { AccrualsModule } from './Accruals/accruals.module';\r\nimport { AgentsModule } from './Agents/agents.module';\r\nimport { AnnualDetailsModule } from './Annual-Details/annual-details.module';\r\nimport { AdminModule } from './Admin/admin.module';\r\nimport { AppComponent } from './app.component';\r\nimport { BudgetModule } from './Budget/budget.module';\r\nimport { BulkImportModule } from './Bulk-Import/bulk.import.module';\r\nimport { DiagnosticsModule } from './Diagnostics/diagnostics.module';\r\nimport { DocumentsModule } from './Documents/documents.module';\r\nimport { weissmanAppModule } from './Hybrid/ngjsStart';\r\nimport { NavigationModule } from './Navigation/navigation.module';\r\nimport { Ng2RoutesModule } from './ng2Routes.module';\r\nimport { ProcessingModule } from './Processing/processing.module';\r\nimport { HybridAdapterUtility } from './Hybrid/hybrid-adapter.utility';\r\nimport { NG1UpgradeProviders } from './Hybrid/ng1-upgrade-providers';\r\nimport { TabsModule } from 'ngx-bootstrap/tabs';\r\nimport { ModalModule } from 'ngx-bootstrap/modal';\r\nimport { ButtonsModule } from 'ngx-bootstrap/buttons';\r\nimport { PopoverModule } from 'ngx-bootstrap/popover';\r\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\r\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\r\nimport { ToastrModule } from 'ngx-toastr';\r\nimport { DragulaModule } from 'ng2-dragula';\r\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\r\nimport { ParcelModule } from './Entity/Parcel/parcel.module';\r\nimport { ReportingModule } from './Reporting/reporting.module';\r\nimport { WeissmanSharedModule } from './Common/weissman-shared.module';\r\nimport { RoleModule } from './Role/role.module';\r\nimport { QuickSearchModule } from './Search/Quick/quickSearch.module';\r\nimport { ActionViewModule } from './Task/ActionView/actionView.module';\r\nimport { TaskModule } from './Task/task.module';\r\nimport { LandingModule } from './Landing/landing.module';\r\nimport { ComplianceModule } from './Compliance/compliance.module';\r\nimport { DashboardModule } from './Dashboard/dashboard.module';\r\nimport { Ng1UpgradeModule } from './Hybrid/ng1Upgrade.module';\r\nimport { EntityModule } from './Entity/entity.module';\r\nimport { SnackBarModule } from './Busy-Indicator/SnackBar/snackBar.module';\r\nimport { LayoutModule } from './Layout/layout.module';\r\nimport { TeamModule } from './Team/team.module';\r\nimport { UserModule } from './User/user.module';\r\nimport { InstanceModule } from './Entity/Instance/instance.module';\r\nimport { ConsultingModule } from './Consulting/consulting.module';\r\nimport { CsrCommandCenterModule} from './Client-Services/Command-Center/csrCommandCenter.module';\r\nimport { AssessorCollectorModule } from './Assessor-Collector/assessorCollector.module';\r\nimport { SmartSearchModule } from './Search/Advanced/smartSearch.module';\r\nimport { AppealApplicationModule } from './Appeal-Application/appealApplication.module';\r\nimport { ClientServicesModule } from './Client-Services/client-services.module';\r\nimport { CommentsModule } from './Comments/comments.module';\r\nimport { StateModule } from './State/state.module';\r\nimport { AttachmentModule } from './Attachment/attachment.module';\r\nimport { ContactModule } from './Contact/contact.module';\r\nimport { LoginModule } from './Account/Login/login.module';\r\nimport { SupportInstanceModule } from './Support-Instances/supportInstance.module';\r\nimport { BlobErrorHttpInterceptor } from './UI-Lib/Interceptors/blobErrorHttp.interceptor';\r\nimport { DatabaseModule } from './Diagnostics/Database/database.module';\r\nimport { PropertyCharacteristicsModule } from './Property-Characteristics/propertyCharacteristics.module';\r\nimport { CarouselModule } from 'ngx-bootstrap/carousel';\r\nimport { QuillModule } from 'ngx-quill';\r\nimport { ProgressbarModule } from 'ngx-bootstrap/progressbar';\r\nimport { BusyIndicatorModule } from './Busy-Indicator';\r\nimport { SortableModule } from 'ngx-bootstrap/sortable';\r\nimport { AccordionModule } from 'ngx-bootstrap/accordion';\r\nimport { TaxRateModule } from './Tax-Rate/tax.rate.module';\r\nimport { PermissionModule } from './Permission/permission.module';\r\nimport { UserGroupModule } from './User-Group/userGroup.module';\r\nimport { ValuationModule } from './Valuation/valuation.module';\r\nimport { WebComponentWrapperModule } from './Common/webComponentWrapper.module';\r\nimport { PaymentBatchModule } from './Payment-Batch/paymentBatch.module';\r\nimport { AppealRecommendationModule } from './Appeal-Recommendation/appealRecommendation.module';\r\nimport { UIRouterUpgradeModule } from '@uirouter/angular-hybrid';\r\n\r\nimport * as Quill from 'quill';\r\nimport { ResponsibleEntityModule } from './Responsible-Entity/responsibleEntity.module';\r\n\r\nconst hybridAdapterUtility = new HybridAdapterUtility();\r\n\r\n@NgModule({\r\n imports: [\r\n BsDropdownModule.forRoot(),\r\n CarouselModule.forRoot(),\r\n ProgressbarModule.forRoot(),\r\n BusyIndicatorModule.forRoot(),\r\n AccordionModule.forRoot(),\r\n TabsModule.forRoot(),\r\n ModalModule.forRoot(),\r\n ButtonsModule.forRoot(),\r\n PopoverModule.forRoot(),\r\n TooltipModule.forRoot(),\r\n ToastrModule.forRoot({\r\n timeOut: 7500,\r\n positionClass: 'toast-bottom-right',\r\n easeTime: 100,\r\n onActivateTick: true\r\n }),\r\n DragulaModule.forRoot(),\r\n QuillModule.forRoot(),\r\n SortableModule.forRoot(),\r\n UIRouterUpgradeModule.forRoot(),\r\n AccountModule,\r\n AccrualsModule,\r\n AdminModule,\r\n AgentsModule,\r\n AnnualDetailsModule,\r\n AppealApplicationModule,\r\n AssessorCollectorModule,\r\n AttachmentModule,\r\n BrowserAnimationsModule,\r\n BrowserModule,\r\n BudgetModule,\r\n BulkImportModule,\r\n CommentsModule,\r\n ComplianceModule,\r\n ConsultingModule,\r\n ContactModule,\r\n CsrCommandCenterModule,\r\n DashboardModule,\r\n DatabaseModule,\r\n DiagnosticsModule,\r\n DocumentsModule,\r\n EntityModule,\r\n HttpClientModule,\r\n InstanceModule,\r\n LandingModule,\r\n LayoutModule,\r\n LoginModule,\r\n NavigationModule,\r\n Ng1UpgradeModule,\r\n ParcelModule,\r\n PermissionModule,\r\n ProcessingModule,\r\n PropertyCharacteristicsModule,\r\n ReportingModule,\r\n RoleModule,\r\n SmartSearchModule,\r\n SnackBarModule,\r\n StateModule,\r\n SupportInstanceModule,\r\n TaskModule,\r\n TaxRateModule,\r\n PaymentBatchModule,\r\n TeamModule,\r\n UpgradeModule,\r\n UserGroupModule,\r\n UserModule,\r\n ValuationModule,\r\n WebComponentWrapperModule,\r\n AppealRecommendationModule,\r\n QuickSearchModule,\r\n ActionViewModule,\r\n Ng2RoutesModule,\r\n ResponsibleEntityModule\r\n ],\r\n declarations: [\r\n AppComponent\r\n ],\r\n providers: [\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: BlobErrorHttpInterceptor,\r\n multi: true\r\n }\r\n ],\r\n exports: [\r\n AppComponent\r\n ]\r\n})\r\nexport class AppModule implements DoBootstrap {\r\n constructor (private upgrade: UpgradeModule) {\r\n // TODO: This should probably be moved to an import script\r\n (window).Decimal = Decimal;\r\n }\r\n\r\n async ngDoBootstrap() {\r\n // Ensure AngularJS destroys itself on hot reloads.\r\n if (window['$injector']) {\r\n window['$injector'].get('$uiRouter').dispose();\r\n window['$injector'].get('$rootScope').$destroy();\r\n }\r\n\r\n const ng1UpgradeProviders = new NG1UpgradeProviders(new HybridAdapterUtility());\r\n\r\n ng1UpgradeProviders.setupProviders();\r\n\r\n hybridAdapterUtility.downgradeNg2Component('appRoot', AppComponent);\r\n\r\n AccountModule.setupModule();\r\n AccrualsModule.setupModule();\r\n ActionViewModule.setupModule();\r\n AdminModule.setupModule();\r\n AnnualDetailsModule.setupModule();\r\n AgentsModule.setupModule();\r\n AppealApplicationModule.setupModule();\r\n AssessorCollectorModule.setupModule();\r\n AttachmentModule.setupModule();\r\n BudgetModule.setupModule();\r\n BulkImportModule.setupModule();\r\n ClientServicesModule.setupModule();\r\n CommentsModule.setupModule();\r\n ComplianceModule.setupModule();\r\n ConsultingModule.setupModule();\r\n ContactModule.setupModule();\r\n CsrCommandCenterModule.setupModule();\r\n DashboardModule.setupModule();\r\n DatabaseModule.setupModule();\r\n DocumentsModule.setupModule();\r\n EntityModule.setupModule();\r\n InstanceModule.setupModule();\r\n LandingModule.setupModule();\r\n LayoutModule.setupModule();\r\n NavigationModule.setupModule();\r\n ParcelModule.setupModule();\r\n PermissionModule.setupModule();\r\n ProcessingModule.setupModule();\r\n PropertyCharacteristicsModule.setupModule();\r\n ReportingModule.setupModule();\r\n RoleModule.setupModule();\r\n SmartSearchModule.setupModule();\r\n SnackBarModule.setupModule();\r\n StateModule.setupModule();\r\n SupportInstanceModule.setupModule();\r\n TaskModule.setupModule();\r\n TaxRateModule.setupModule();\r\n PaymentBatchModule.setupModule();\r\n TeamModule.setupModule();\r\n UserGroupModule.setupModule();\r\n UserModule.setupModule();\r\n ValuationModule.setupModule();\r\n WeissmanSharedModule.setupModule();\r\n AppealRecommendationModule.setupModule();\r\n QuickSearchModule.setupModule();\r\n\r\n this.upgrade.bootstrap(document.body, [weissmanAppModule.name], { strictDi: true });\r\n window['$injector'] = ((window as any).angular.element(document.body) as any).injector();\r\n\r\n this.setupQuill();\r\n }\r\n\r\n setupQuill() {\r\n // Configure Quill to use div instead of p (maybe this should be in a utility function?)\r\n // https://github.com/KillerCodeMonkey/ngx-quill/issues/18\r\n\r\n // Trust me TypeScript - I know what I'm doing! (I hope)\r\n const Parchment = (Quill as any).import('parchment');\r\n const Block = Parchment.query('block');\r\n\r\n Block.tagName = 'DIV';\r\n // or class NewBlock extends Block {}; NewBlock.tagName = 'DIV';\r\n (Quill as any).register(Block /* or NewBlock */, true);\r\n }\r\n}\r\n","export const environment = {\r\n production: true\r\n };\r\n","import { environment } from '../environments/environment';\r\n\r\n/* Here the term \"environment\" refers to the location deployed to (dev, qa, prod, etc.). To simplify deploys, there is\r\nno environment-specific code in the UI. Angular's built-in concept of \"environment\" is used to distinguish\r\nlocally-hosted UIs from deployed UIs, and the solution detects that it is on a production environment with the\r\nhard-coded prod URL, but all other configuration comes from the API. Here are the environment-specific settings:\r\n\r\ndeveloperMode - If Angular and AngularJS should be running in developer mode or production mode. Also referenced\r\nfrom time to time for things like navigation entries.\r\n Use developerMode when the environment config says to, otherwise false\r\nsignalRMessageBrokerUrl - Where the UI should connect to SignalR\r\n Retrieved from API\r\nweissman2Url - Where the UI should connect to the Weissman 2 service (which replaces SignalRBroker when present)\r\n Retrieved from API\r\nsignalRUseUnsafeLogin - Set when SignalR should come from a different host using CORS\r\namplitudeApiKey - amplitude.com\r\nruntimeEnvironment - What color banner should be displayed on the navbar\r\n Are we in developerMode? Use the local banner. Is this production? Use the prod banner. Otherwise,\r\n use the test banner unless overridden by API later.\r\n*/\r\nexport class WeissmanEnvironmentConfig {\r\n developerMode: boolean;\r\n signalRMessageBrokerUrl: string;\r\n weissman2Url: string;\r\n signalRUseUnsafeLogin: boolean;\r\n amplitudeApiKey: string;\r\n runtimeEnvironment: 'prod' | 'uat' | 'test' | 'local';\r\n\r\n static initEnvironment(): WeissmanEnvironmentConfig {\r\n const config = new WeissmanEnvironmentConfig();\r\n config.developerMode = !environment.production;\r\n config.runtimeEnvironment = config.developerMode ? 'local' : 'test';\r\n const urlMatch = /^(https?:\\/\\/[^\\/\\?]+)([\\/\\?].*)?$/.exec(window.location.href);\r\n if (urlMatch && urlMatch[1].toLowerCase() === 'https://propertypoint.tax') {\r\n config.runtimeEnvironment = 'prod';\r\n } else if (urlMatch && urlMatch[1].toLowerCase() === 'https://propertypoint-uat.ryanplatform.com') {\r\n config.runtimeEnvironment = 'uat';\r\n }\r\n return config;\r\n }\r\n}\r\n","export enum LocalStorageKeys {\r\n lastSSODomain = 'lastSSODomain',\r\n rememberSSOEmail = 'rememberSSOEmail'\r\n}\r\n","import { UIRouter, UrlService } from '@uirouter/angular';\r\nimport './app/Hybrid/externalImports';\r\nimport './app/Hybrid/ngjsStart';\r\nimport './app/Hybrid/appImports';\r\nimport { AppModule } from './app/app.module';\r\nimport { platformBrowserDynamic } from '@angular/platform-browser-dynamic';\r\nimport { enableProdMode, NgZone } from '@angular/core';\r\nimport { setAngularJSGlobal } from '@angular/upgrade/static';\r\nimport { weissmanAppModule } from './app/Hybrid/ngjsStart';\r\nimport { WeissmanEnvironmentConfig } from './app/weissmanEnvironmentConfig';\r\nimport { LocalStorageKeys } from './app/localStorageKeys';\r\n\r\nconst windowRef = window as any;\r\nconst refreshRegexResult = /^\\#\\/refresh\\/(.*)$/.exec(window.location.hash);\r\nlet locationSet = false;\r\nif (!refreshRegexResult) {\r\n windowRef.weissmanRefreshState = 'normal';\r\n if (window.location && window.location.search) {\r\n const parsedQueryString = /^\\?([^\\/\\?]*)\\/?$/.exec(window.location.search);\r\n const queryStringArguments = !parsedQueryString ? [] : parsedQueryString[1]\r\n .split('&')\r\n .map((a, i) => {\r\n const tokens = a.split('=');\r\n return {\r\n key: decodeURIComponent(tokens[0]),\r\n value: tokens[1] ? decodeURIComponent(tokens[1]) : null,\r\n raw: a,\r\n index: i\r\n };\r\n });\r\n\r\n const domainArgument = queryStringArguments.reverse().find(a => a.key === 'sso-domain');\r\n if (domainArgument) {\r\n localStorage[LocalStorageKeys.lastSSODomain] = domainArgument.value;\r\n const newQueryString = queryStringArguments.length === 1 ? '' : (`?${ queryStringArguments\r\n .filter(a => a.index !== domainArgument.index)\r\n .map(a => a.raw)\r\n .join('&') }/`);\r\n // Refresh page leaving out sso-domain argument\r\n locationSet = true;\r\n window.location.href = `${window.location.pathname}${newQueryString}${window.location.hash}`;\r\n }\r\n }\r\n}\r\nelse {\r\n windowRef.weissmanRefreshState = 'refreshed';\r\n const newHash = decodeURIComponent(refreshRegexResult[1]);\r\n console.log(`Processing refresh URL: ${ newHash}`);\r\n if (history.replaceState) {\r\n history.replaceState(null, '', newHash);\r\n }\r\n else {\r\n window.location.hash = newHash;\r\n }\r\n}\r\n\r\nif (!locationSet) {\r\n setAngularJSGlobal(windowRef.angular);\r\n\r\n const config = WeissmanEnvironmentConfig.initEnvironment();\r\n windowRef.weissmanEnvironmentConfig = config;\r\n\r\n if (!config.developerMode) {\r\n enableProdMode();\r\n }\r\n\r\n // Using AngularJS config block, call `deferIntercept()`.\r\n // This tells UI-Router to delay the initial URL sync (until all bootstrapping is complete)\r\n weissmanAppModule.config([ '$urlServiceProvider', ($urlService: UrlService) => $urlService.deferIntercept() ]);\r\n\r\n platformBrowserDynamic().bootstrapModule(AppModule).then((platformRef) => {\r\n // Ensure Angular destroys itself on hot reloads.\r\n window['platformRef'] && window['platformRef'].destroy();\r\n window['platformRef'] = null;\r\n\r\n // get() UrlService from DI (this call will create all the UIRouter services)\r\n const urlService: UrlService = platformRef.injector.get(UIRouter).urlService;\r\n\r\n // Instruct UIRouter to listen to URL changes\r\n function startUIRouter() {\r\n urlService.listen();\r\n urlService.sync();\r\n }\r\n\r\n const ngZone: NgZone = platformRef.injector.get(NgZone);\r\n ngZone.run(startUIRouter);\r\n });\r\n}\r\n","var map = {\n\t\"./af\": 51975,\n\t\"./af.js\": 51975,\n\t\"./ar\": 24145,\n\t\"./ar-dz\": 75982,\n\t\"./ar-dz.js\": 75982,\n\t\"./ar-kw\": 56242,\n\t\"./ar-kw.js\": 56242,\n\t\"./ar-ly\": 26864,\n\t\"./ar-ly.js\": 26864,\n\t\"./ar-ma\": 22239,\n\t\"./ar-ma.js\": 22239,\n\t\"./ar-ps\": 87669,\n\t\"./ar-ps.js\": 87669,\n\t\"./ar-sa\": 834,\n\t\"./ar-sa.js\": 834,\n\t\"./ar-tn\": 22387,\n\t\"./ar-tn.js\": 22387,\n\t\"./ar.js\": 24145,\n\t\"./az\": 32351,\n\t\"./az.js\": 32351,\n\t\"./be\": 35392,\n\t\"./be.js\": 35392,\n\t\"./bg\": 38946,\n\t\"./bg.js\": 38946,\n\t\"./bm\": 91284,\n\t\"./bm.js\": 91284,\n\t\"./bn\": 84885,\n\t\"./bn-bd\": 64936,\n\t\"./bn-bd.js\": 64936,\n\t\"./bn.js\": 84885,\n\t\"./bo\": 52342,\n\t\"./bo.js\": 52342,\n\t\"./br\": 21319,\n\t\"./br.js\": 21319,\n\t\"./bs\": 90605,\n\t\"./bs.js\": 90605,\n\t\"./ca\": 97135,\n\t\"./ca.js\": 97135,\n\t\"./cs\": 17783,\n\t\"./cs.js\": 17783,\n\t\"./cv\": 8060,\n\t\"./cv.js\": 8060,\n\t\"./cy\": 65052,\n\t\"./cy.js\": 65052,\n\t\"./da\": 6997,\n\t\"./da.js\": 6997,\n\t\"./de\": 74846,\n\t\"./de-at\": 15074,\n\t\"./de-at.js\": 15074,\n\t\"./de-ch\": 87973,\n\t\"./de-ch.js\": 87973,\n\t\"./de.js\": 74846,\n\t\"./dv\": 48879,\n\t\"./dv.js\": 48879,\n\t\"./el\": 88233,\n\t\"./el.js\": 88233,\n\t\"./en-au\": 32333,\n\t\"./en-au.js\": 32333,\n\t\"./en-ca\": 48371,\n\t\"./en-ca.js\": 48371,\n\t\"./en-gb\": 85980,\n\t\"./en-gb.js\": 85980,\n\t\"./en-ie\": 15263,\n\t\"./en-ie.js\": 15263,\n\t\"./en-il\": 96225,\n\t\"./en-il.js\": 96225,\n\t\"./en-in\": 89198,\n\t\"./en-in.js\": 89198,\n\t\"./en-nz\": 76014,\n\t\"./en-nz.js\": 76014,\n\t\"./en-sg\": 58604,\n\t\"./en-sg.js\": 58604,\n\t\"./eo\": 38351,\n\t\"./eo.js\": 38351,\n\t\"./es\": 47446,\n\t\"./es-do\": 15381,\n\t\"./es-do.js\": 15381,\n\t\"./es-mx\": 41268,\n\t\"./es-mx.js\": 41268,\n\t\"./es-us\": 93922,\n\t\"./es-us.js\": 93922,\n\t\"./es.js\": 47446,\n\t\"./et\": 93874,\n\t\"./et.js\": 93874,\n\t\"./eu\": 29501,\n\t\"./eu.js\": 29501,\n\t\"./fa\": 62986,\n\t\"./fa.js\": 62986,\n\t\"./fi\": 63517,\n\t\"./fi.js\": 63517,\n\t\"./fil\": 40471,\n\t\"./fil.js\": 40471,\n\t\"./fo\": 69848,\n\t\"./fo.js\": 69848,\n\t\"./fr\": 22104,\n\t\"./fr-ca\": 14079,\n\t\"./fr-ca.js\": 14079,\n\t\"./fr-ch\": 15960,\n\t\"./fr-ch.js\": 15960,\n\t\"./fr.js\": 22104,\n\t\"./fy\": 59942,\n\t\"./fy.js\": 59942,\n\t\"./ga\": 86259,\n\t\"./ga.js\": 86259,\n\t\"./gd\": 10196,\n\t\"./gd.js\": 10196,\n\t\"./gl\": 9667,\n\t\"./gl.js\": 9667,\n\t\"./gom-deva\": 58901,\n\t\"./gom-deva.js\": 58901,\n\t\"./gom-latn\": 8001,\n\t\"./gom-latn.js\": 8001,\n\t\"./gu\": 9430,\n\t\"./gu.js\": 9430,\n\t\"./he\": 98008,\n\t\"./he.js\": 98008,\n\t\"./hi\": 13449,\n\t\"./hi.js\": 13449,\n\t\"./hr\": 69271,\n\t\"./hr.js\": 69271,\n\t\"./hu\": 61036,\n\t\"./hu.js\": 61036,\n\t\"./hy-am\": 83043,\n\t\"./hy-am.js\": 83043,\n\t\"./id\": 27102,\n\t\"./id.js\": 27102,\n\t\"./is\": 87297,\n\t\"./is.js\": 87297,\n\t\"./it\": 11248,\n\t\"./it-ch\": 3529,\n\t\"./it-ch.js\": 3529,\n\t\"./it.js\": 11248,\n\t\"./ja\": 70645,\n\t\"./ja.js\": 70645,\n\t\"./jv\": 74317,\n\t\"./jv.js\": 74317,\n\t\"./ka\": 35359,\n\t\"./ka.js\": 35359,\n\t\"./kk\": 9027,\n\t\"./kk.js\": 9027,\n\t\"./km\": 14941,\n\t\"./km.js\": 14941,\n\t\"./kn\": 77478,\n\t\"./kn.js\": 77478,\n\t\"./ko\": 74356,\n\t\"./ko.js\": 74356,\n\t\"./ku\": 91077,\n\t\"./ku-kmr\": 59403,\n\t\"./ku-kmr.js\": 59403,\n\t\"./ku.js\": 91077,\n\t\"./ky\": 80145,\n\t\"./ky.js\": 80145,\n\t\"./lb\": 12339,\n\t\"./lb.js\": 12339,\n\t\"./lo\": 53814,\n\t\"./lo.js\": 53814,\n\t\"./lt\": 20281,\n\t\"./lt.js\": 20281,\n\t\"./lv\": 90177,\n\t\"./lv.js\": 90177,\n\t\"./me\": 39609,\n\t\"./me.js\": 39609,\n\t\"./mi\": 58772,\n\t\"./mi.js\": 58772,\n\t\"./mk\": 16112,\n\t\"./mk.js\": 16112,\n\t\"./ml\": 42854,\n\t\"./ml.js\": 42854,\n\t\"./mn\": 50538,\n\t\"./mn.js\": 50538,\n\t\"./mr\": 30450,\n\t\"./mr.js\": 30450,\n\t\"./ms\": 11508,\n\t\"./ms-my\": 86169,\n\t\"./ms-my.js\": 86169,\n\t\"./ms.js\": 11508,\n\t\"./mt\": 47009,\n\t\"./mt.js\": 47009,\n\t\"./my\": 55350,\n\t\"./my.js\": 55350,\n\t\"./nb\": 15909,\n\t\"./nb.js\": 15909,\n\t\"./ne\": 87502,\n\t\"./ne.js\": 87502,\n\t\"./nl\": 65321,\n\t\"./nl-be\": 94405,\n\t\"./nl-be.js\": 94405,\n\t\"./nl.js\": 65321,\n\t\"./nn\": 45704,\n\t\"./nn.js\": 45704,\n\t\"./oc-lnc\": 83788,\n\t\"./oc-lnc.js\": 83788,\n\t\"./pa-in\": 96290,\n\t\"./pa-in.js\": 96290,\n\t\"./pl\": 98265,\n\t\"./pl.js\": 98265,\n\t\"./pt\": 58802,\n\t\"./pt-br\": 53430,\n\t\"./pt-br.js\": 53430,\n\t\"./pt.js\": 58802,\n\t\"./ro\": 17732,\n\t\"./ro.js\": 17732,\n\t\"./ru\": 14548,\n\t\"./ru.js\": 14548,\n\t\"./sd\": 43268,\n\t\"./sd.js\": 43268,\n\t\"./se\": 31832,\n\t\"./se.js\": 31832,\n\t\"./si\": 51601,\n\t\"./si.js\": 51601,\n\t\"./sk\": 96759,\n\t\"./sk.js\": 96759,\n\t\"./sl\": 81930,\n\t\"./sl.js\": 81930,\n\t\"./sq\": 84476,\n\t\"./sq.js\": 84476,\n\t\"./sr\": 63648,\n\t\"./sr-cyrl\": 1249,\n\t\"./sr-cyrl.js\": 1249,\n\t\"./sr.js\": 63648,\n\t\"./ss\": 39724,\n\t\"./ss.js\": 39724,\n\t\"./sv\": 12280,\n\t\"./sv.js\": 12280,\n\t\"./sw\": 87639,\n\t\"./sw.js\": 87639,\n\t\"./ta\": 45843,\n\t\"./ta.js\": 45843,\n\t\"./te\": 89211,\n\t\"./te.js\": 89211,\n\t\"./tet\": 35822,\n\t\"./tet.js\": 35822,\n\t\"./tg\": 69191,\n\t\"./tg.js\": 69191,\n\t\"./th\": 74716,\n\t\"./th.js\": 74716,\n\t\"./tk\": 59684,\n\t\"./tk.js\": 59684,\n\t\"./tl-ph\": 84428,\n\t\"./tl-ph.js\": 84428,\n\t\"./tlh\": 85189,\n\t\"./tlh.js\": 85189,\n\t\"./tr\": 83807,\n\t\"./tr.js\": 83807,\n\t\"./tzl\": 6539,\n\t\"./tzl.js\": 6539,\n\t\"./tzm\": 36714,\n\t\"./tzm-latn\": 98827,\n\t\"./tzm-latn.js\": 98827,\n\t\"./tzm.js\": 36714,\n\t\"./ug-cn\": 97366,\n\t\"./ug-cn.js\": 97366,\n\t\"./uk\": 92757,\n\t\"./uk.js\": 92757,\n\t\"./ur\": 57362,\n\t\"./ur.js\": 57362,\n\t\"./uz\": 5534,\n\t\"./uz-latn\": 50321,\n\t\"./uz-latn.js\": 50321,\n\t\"./uz.js\": 5534,\n\t\"./vi\": 24049,\n\t\"./vi.js\": 24049,\n\t\"./x-pseudo\": 43134,\n\t\"./x-pseudo.js\": 43134,\n\t\"./yo\": 2668,\n\t\"./yo.js\": 2668,\n\t\"./zh-cn\": 41282,\n\t\"./zh-cn.js\": 41282,\n\t\"./zh-hk\": 13423,\n\t\"./zh-hk.js\": 13423,\n\t\"./zh-mo\": 6739,\n\t\"./zh-mo.js\": 6739,\n\t\"./zh-tw\": 81037,\n\t\"./zh-tw.js\": 81037\n};\n\n\nfunction webpackContext(req) {\n\tvar id = webpackContextResolve(req);\n\treturn __webpack_require__(id);\n}\nfunction webpackContextResolve(req) {\n\tif(!__webpack_require__.o(map, req)) {\n\t\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\t\te.code = 'MODULE_NOT_FOUND';\n\t\tthrow e;\n\t}\n\treturn map[req];\n}\nwebpackContext.keys = function webpackContextKeys() {\n\treturn Object.keys(map);\n};\nwebpackContext.resolve = webpackContextResolve;\nmodule.exports = webpackContext;\nwebpackContext.id = 46700;"],"x_google_ignoreList":[2034]}