Skip to content

Commit

Permalink
Additional fixes to no longer hard code class API address
Browse files Browse the repository at this point in the history
  • Loading branch information
computate committed Dec 19, 2023
1 parent 11e82c8 commit 3d96785
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
2 changes: 2 additions & 0 deletions src/main/java/org/computate/vertx/api/BaseApiServiceImpl.java
Original file line number Diff line number Diff line change
Expand Up @@ -747,6 +747,8 @@ public void responsePivotSearch(Map<String, SolrResponse.Pivot> pivots, JsonObje

public abstract String searchVar(String varIndexed);

public abstract String getClassApiAddress();

public void calendarStuff() {

}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
*/
public interface ComputateSiteUser extends ComputateBaseModel {

public static final String CLASS_API_ADDRESS = "computate-vertx-enUS-ComputateSiteUser";
public static final String CLASS_API_ADDRESS_ComputateSiteUser = "computate-vertx-enUS-ComputateSiteUser";

void setUserName(String userName);

Expand Down Expand Up @@ -86,5 +86,4 @@ public interface ComputateSiteUser extends ComputateBaseModel {
Boolean getSeeDeleted();

Boolean getSeeArchived();

}
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ public ComputateJavaClassEnUSGenApiServiceImpl(EventBus eventBus, JsonObject con

@Override
public void searchComputateJavaClass(ServiceRequest serviceRequest, Handler<AsyncResult<ServiceResponse>> eventHandler) {
user(serviceRequest, ComputateSiteRequest.class, ComputateSiteUser.class, ComputateSiteUser.CLASS_API_ADDRESS, "postComputateSiteUserFuture", "patchComputateSiteUserFuture").onSuccess(siteRequest -> {
user(serviceRequest, ComputateSiteRequest.class, ComputateSiteUser.class, getClassApiAddress(), "postComputateSiteUserFuture", "patchComputateSiteUserFuture").onSuccess(siteRequest -> {
{
try {
searchComputateJavaClassList(siteRequest, false, true, false).onSuccess(listComputateJavaClass -> {
Expand Down Expand Up @@ -235,7 +235,7 @@ public void responsePivotSearchComputateJavaClass(List<SolrResponse.Pivot> pivot

@Override
public void getComputateJavaClass(ServiceRequest serviceRequest, Handler<AsyncResult<ServiceResponse>> eventHandler) {
user(serviceRequest, ComputateSiteRequest.class, ComputateSiteUser.class, ComputateSiteUser.CLASS_API_ADDRESS, "postComputateSiteUserFuture", "patchComputateSiteUserFuture").onSuccess(siteRequest -> {
user(serviceRequest, ComputateSiteRequest.class, ComputateSiteUser.class, getClassApiAddress(), "postComputateSiteUserFuture", "patchComputateSiteUserFuture").onSuccess(siteRequest -> {
{
try {
searchComputateJavaClassList(siteRequest, false, true, false).onSuccess(listComputateJavaClass -> {
Expand Down Expand Up @@ -304,7 +304,7 @@ public void searchpageComputateJavaClassId(ServiceRequest serviceRequest, Handle

@Override
public void searchpageComputateJavaClass(ServiceRequest serviceRequest, Handler<AsyncResult<ServiceResponse>> eventHandler) {
user(serviceRequest, ComputateSiteRequest.class, ComputateSiteUser.class, ComputateSiteUser.CLASS_API_ADDRESS, "postComputateSiteUserFuture", "patchComputateSiteUserFuture").onSuccess(siteRequest -> {
user(serviceRequest, ComputateSiteRequest.class, ComputateSiteUser.class, getClassApiAddress(), "postComputateSiteUserFuture", "patchComputateSiteUserFuture").onSuccess(siteRequest -> {
{
try {
searchComputateJavaClassList(siteRequest, false, true, false).onSuccess(listComputateJavaClass -> {
Expand Down Expand Up @@ -768,4 +768,9 @@ else if(softCommit == null)
public String searchVar(String varIndexed) {
return ComputateJavaClass.searchVarComputateJavaClass(varIndexed);
}

@Override
public String getClassApiAddress() {
return ComputateSiteUser.CLASS_API_ADDRESS_ComputateSiteUser;
}
}

0 comments on commit 3d96785

Please sign in to comment.