102 lines
3.2 KiB
Java
102 lines
3.2 KiB
Java
package com.utopiaindustries.qualitychecker.apiservice;
|
|
|
|
import com.utopiaindustries.qualitychecker.models.EmployeePhoto;
|
|
import com.utopiaindustries.qualitychecker.models.InspectionCheckPoint;
|
|
import com.utopiaindustries.qualitychecker.models.InspectionCheckpointSku;
|
|
import com.utopiaindustries.qualitychecker.models.InspectionDefect;
|
|
import com.utopiaindustries.qualitychecker.models.InspectionDimension;
|
|
import com.utopiaindustries.qualitychecker.models.InspectionLabelResponse;
|
|
import com.utopiaindustries.qualitychecker.models.InspectionReport;
|
|
import com.utopiaindustries.qualitychecker.models.InspectionReportItem;
|
|
import com.utopiaindustries.qualitychecker.models.ItemUnit;
|
|
import com.utopiaindustries.qualitychecker.models.Product;
|
|
import com.utopiaindustries.qualitychecker.models.VoiceOfCustomer;
|
|
|
|
import java.util.List;
|
|
import java.util.Map;
|
|
|
|
import retrofit2.Call;
|
|
import retrofit2.http.Body;
|
|
import retrofit2.http.GET;
|
|
import retrofit2.http.POST;
|
|
import retrofit2.http.Path;
|
|
import retrofit2.http.Query;
|
|
|
|
public interface ApiService {
|
|
|
|
@GET("rest/uic/inspection-report")
|
|
Call<List<InspectionReport>> fetchAllReports(
|
|
@Query("username") String username
|
|
);
|
|
|
|
@GET("rest/uic/inspection-report/{id}")
|
|
Call<InspectionReport> fetchReport(
|
|
@Path("id") long id
|
|
);
|
|
|
|
@POST("rest/authentication/authenticate-user")
|
|
Call<Boolean> isUserAuthenticated(
|
|
@Query("username") String username,
|
|
@Query("password") String password,
|
|
@Query("roles") String[] roles
|
|
);
|
|
|
|
@POST("rest/uic/inspection-report")
|
|
Call<Map<String,String>> saveInspectionReport(
|
|
@Body InspectionReport inspectionReport
|
|
);
|
|
|
|
@GET("rest/uic/cosmos-products/find-by-sku")
|
|
Call<List<Product>> fetchProductBySku(
|
|
@Query("sku") String sku
|
|
);
|
|
|
|
@GET("rest/uic/inspection-report/checkpoints")
|
|
Call<List<InspectionCheckPoint>> fetchCheckPoints();
|
|
|
|
@GET( "rest/uic/inspection-report/defects" )
|
|
Call<List<InspectionDefect>> fetchDefects();
|
|
|
|
// @GET( "rest/uic/inspection-report/dimensions" )
|
|
// Call<List<InspectionDimension>> fetchDimensions(
|
|
// @Query("sku") String sku
|
|
// );
|
|
|
|
@GET( "rest/uic/inspection-report/dimensions" )
|
|
Call<List<InspectionDimension>> fetchDimensions();
|
|
|
|
@GET( "rest/hrms/employees/attendance")
|
|
Call<EmployeePhoto> fetchEmployeePhoto(
|
|
@Query("username") String username
|
|
);
|
|
|
|
@GET("rest/cosmos/amazon-voc")
|
|
Call<List<VoiceOfCustomer>> fetchVocs(
|
|
@Query("asin") String asin
|
|
);
|
|
|
|
@GET( "rest/uic/cosmos-products/find-by-fnsku")
|
|
Call<Product> fetchByFnsku(
|
|
@Query("fnsku") String fnsku
|
|
);
|
|
|
|
@GET( "rest/uic/inspection-report/inspection-items-logs" )
|
|
Call<List<InspectionReportItem>> fetchItemsLogs(
|
|
@Query("sku") String sku
|
|
);
|
|
|
|
@GET( "rest/uic/items/units" )
|
|
Call<List<ItemUnit>> fetchItemUnits();
|
|
|
|
@GET( "rest/uic/cosmos-products/" )
|
|
Call<List<Product>> fetchAllProducts(
|
|
@Query("is-active") boolean isActive
|
|
);
|
|
|
|
@GET( "rest/uic/inspection-report/inspection-sku-checkpoints" )
|
|
Call<List<InspectionCheckpointSku>> fetchSkuCheckpoints( );
|
|
|
|
@GET("rest/uic/inspection-report/get-inspection-label")
|
|
Call<InspectionLabelResponse> fetchAllInspectionLabels();
|
|
}
|