Skip to content

Commit

Permalink
remove unused classes
Browse files Browse the repository at this point in the history
Signed-off-by: Pablo <[email protected]>
  • Loading branch information
Balcan committed May 14, 2024
1 parent 2634d8e commit d47fcdd
Show file tree
Hide file tree
Showing 15 changed files with 4 additions and 545 deletions.
92 changes: 0 additions & 92 deletions app/src/main/java/org/dhis2/data/forms/EnrollmentFormRepository.kt

This file was deleted.

98 changes: 0 additions & 98 deletions app/src/main/java/org/dhis2/data/forms/EventRepository.java

This file was deleted.

16 changes: 0 additions & 16 deletions app/src/main/java/org/dhis2/data/forms/FormRepository.java

This file was deleted.

36 changes: 0 additions & 36 deletions app/src/main/java/org/dhis2/data/forms/ReportStatus.java

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,16 @@
import org.dhis2.commons.resources.ResourceManager;
import org.dhis2.commons.schedulers.SchedulerProvider;
import org.dhis2.data.dhislogic.DhisEnrollmentUtils;
import org.dhis2.data.forms.EventRepository;
import org.dhis2.data.forms.FormRepository;
import org.dhis2.data.forms.dataentry.SearchTEIRepository;
import org.dhis2.data.forms.dataentry.SearchTEIRepositoryImpl;
import org.dhis2.mobileProgramRules.EvaluationType;
import org.dhis2.mobileProgramRules.RuleEngineHelper;
import org.dhis2.form.data.FileController;
import org.dhis2.form.data.FormValueStore;
import org.dhis2.form.data.RulesRepository;
import org.dhis2.form.data.UniqueAttributeController;
import org.dhis2.form.model.RowAction;
import org.dhis2.form.ui.FieldViewModelFactory;
import org.dhis2.mobileProgramRules.EvaluationType;
import org.dhis2.mobileProgramRules.RuleEngineHelper;
import org.dhis2.usescases.eventsWithoutRegistration.eventCapture.domain.ConfigureEventCompletionDialog;
import org.dhis2.usescases.eventsWithoutRegistration.eventCapture.provider.EventCaptureResourcesProvider;
import org.dhis2.utils.customviews.navigationbar.NavigationPageConfigurator;
Expand Down Expand Up @@ -86,20 +84,13 @@ RulesRepository rulesRepository(@NonNull D2 d2) {
@Provides
@PerActivity
RuleEngineHelper ruleEngineRepository(D2 d2) {
if(eventUid == null) return null;
if (eventUid == null) return null;
return new RuleEngineHelper(
new EvaluationType.Event(eventUid),
new org.dhis2.mobileProgramRules.RulesRepository(d2)
);
}

@Provides
@PerActivity
FormRepository formRepository(@NonNull RulesRepository rulesRepository,
@NonNull D2 d2) {
return new EventRepository(rulesRepository, eventUid, d2);
}

@Provides
@PerActivity
FormValueStore valueStore(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,10 @@
import org.dhis2.commons.prefs.PreferenceProvider;
import org.dhis2.commons.prefs.PreferenceProviderImpl;
import org.dhis2.commons.resources.ColorUtils;
import org.dhis2.commons.resources.MetadataIconProvider;
import org.dhis2.commons.resources.DhisPeriodUtils;
import org.dhis2.commons.resources.MetadataIconProvider;
import org.dhis2.commons.resources.ResourceManager;
import org.dhis2.commons.schedulers.SchedulerProvider;
import org.dhis2.data.forms.EventRepository;
import org.dhis2.data.forms.FormRepository;
import org.dhis2.form.data.RulesRepository;
import org.dhis2.form.data.RulesUtilsProvider;
import org.dhis2.form.data.metadata.FileResourceConfiguration;
Expand Down Expand Up @@ -118,12 +116,6 @@ FieldViewModelFactory fieldFactory(
);
}

@Provides
FormRepository formRepository(@NonNull RulesRepository rulesRepository,
@NonNull D2 d2) {
return new EventRepository(rulesRepository, eventUid, d2);
}

@Provides
RulesRepository rulesRepository(@NonNull D2 d2) {
return new RulesRepository(d2);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ import org.dhis2.commons.prefs.PreferenceProvider
import org.dhis2.commons.resources.MetadataIconProvider
import org.dhis2.commons.schedulers.SchedulerProvider
import org.dhis2.commons.viewmodel.DispatcherProvider
import org.dhis2.data.forms.EnrollmentFormRepository
import org.dhis2.data.forms.FormRepository
import org.dhis2.form.data.RulesRepository
import org.dhis2.mobileProgramRules.EvaluationType
import org.dhis2.mobileProgramRules.RuleEngineHelper
Expand Down Expand Up @@ -79,20 +77,6 @@ class TeiDashboardModule(
return RulesRepository(d2)
}

@Provides
@PerActivity
fun formRepository(
rulesRepository: RulesRepository,
d2: D2,
): FormRepository {
val enrollmentUidToUse = enrollmentUid ?: ""
return EnrollmentFormRepository(
rulesRepository,
enrollmentUidToUse,
d2,
)
}

@Provides
@PerActivity
fun ruleEngineRepository(
Expand Down
Loading

0 comments on commit d47fcdd

Please sign in to comment.