Transfered to new version of API (which is more RESTful)
This commit is contained in:
parent
5bc86ce49a
commit
0a52ef6b42
BIN
.idea/caches/gradle_models.ser
Normal file
BIN
.idea/caches/gradle_models.ser
Normal file
Binary file not shown.
@ -4,6 +4,7 @@ import java.util.List;
|
||||
|
||||
import retrofit2.Call;
|
||||
import retrofit2.http.GET;
|
||||
import retrofit2.http.Path;
|
||||
import retrofit2.http.Query;
|
||||
import ru.volgorobot.vrcatalog.model.DetailModel;
|
||||
import ru.volgorobot.vrcatalog.model.FirstLevelModel;
|
||||
@ -12,24 +13,24 @@ import ru.volgorobot.vrcatalog.model.ThirdLevelModel;
|
||||
|
||||
public interface VRApi {
|
||||
|
||||
@GET("/API/Api.php?action=getFirstLevel")
|
||||
@GET("/api/level/1")
|
||||
Call<List<FirstLevelModel>> getFirstLevel();
|
||||
|
||||
@GET("/API/Api.php?action=getSecondLevel")
|
||||
Call<List<SecondLevelModel>> getSecondLevel(@Query("parentTypeID") int parentTypeID);
|
||||
@GET("/api/level/2")
|
||||
Call<List<SecondLevelModel>> getSecondLevel(@Query("categoryID") int categoryID);
|
||||
|
||||
@GET("/API/Api.php?action=getDetailsByParentID")
|
||||
Call<List<ThirdLevelModel>> getDetails(@Query("parentID") int parentID);
|
||||
@GET("/api/level/3")
|
||||
Call<List<ThirdLevelModel>> getDetails(@Query("subcategoryID") int subcategoryID);
|
||||
|
||||
@GET("/API/Api.php?action=getDetailByID")
|
||||
Call<List<DetailModel>> getDetailByID(@Query("detailID") int detailID);
|
||||
@GET("/api/item/{id}")
|
||||
Call<List<DetailModel>> getDetailByID(@Path("id") int itemID);
|
||||
|
||||
@GET("/API/Api.php?action=getCategoryByID")
|
||||
Call<List<FirstLevelModel>> getCategoryByID(@Query("id") int id);
|
||||
@GET("/api/level/1/{id}")
|
||||
Call<List<FirstLevelModel>> getCategoryByID(@Path("id") int categoryID);
|
||||
|
||||
@GET("/API/Api.php?action=getSubCategoryByID")
|
||||
Call<List<SecondLevelModel>> getSubCategoryByID(@Query("id") int id);
|
||||
@GET("/api/level/2/{id}")
|
||||
Call<List<SecondLevelModel>> getSubCategoryByID(@Path("id") int subcategoryID);
|
||||
|
||||
@GET("/API/Api.php?action=getDetailsByName")
|
||||
@GET("/api/item")
|
||||
Call<List<ThirdLevelModel>> getDetailsByName(@Query("name") String name);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user