mirror of
https://gitea.gofwd.group/Forward_Group/ballistic-builder-spring.git
synced 2026-01-21 01:01:05 -05:00
more meta data in product api
This commit is contained in:
@@ -46,6 +46,10 @@ public class SecurityConfig {
|
|||||||
.requestMatchers("/actuator/health", "/actuator/info").permitAll()
|
.requestMatchers("/actuator/health", "/actuator/info").permitAll()
|
||||||
.requestMatchers("/api/products/gunbuilder/**").permitAll()
|
.requestMatchers("/api/products/gunbuilder/**").permitAll()
|
||||||
|
|
||||||
|
// Short links (public redirect)
|
||||||
|
.requestMatchers(HttpMethod.GET, "/go/**").permitAll()
|
||||||
|
.requestMatchers(HttpMethod.HEAD, "/go/**").permitAll()
|
||||||
|
|
||||||
// Public builds feed + public build detail (1 path segment only)
|
// Public builds feed + public build detail (1 path segment only)
|
||||||
.requestMatchers(HttpMethod.GET, "/api/v1/builds").permitAll()
|
.requestMatchers(HttpMethod.GET, "/api/v1/builds").permitAll()
|
||||||
.requestMatchers(HttpMethod.GET, "/api/v1/builds/*").permitAll()
|
.requestMatchers(HttpMethod.GET, "/api/v1/builds/*").permitAll()
|
||||||
|
|||||||
@@ -13,4 +13,12 @@ public class CatalogOptionDto {
|
|||||||
public BigDecimal price;
|
public BigDecimal price;
|
||||||
public String buyUrl;
|
public String buyUrl;
|
||||||
public Boolean inStock;
|
public Boolean inStock;
|
||||||
}
|
private String caliber;
|
||||||
|
|
||||||
|
public String getCaliber() {
|
||||||
|
return caliber;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCaliber(String caliber) {
|
||||||
|
this.caliber = caliber;
|
||||||
|
}}
|
||||||
@@ -64,6 +64,11 @@ public class ProductSummaryDto {
|
|||||||
this.categoryKey = categoryKey;
|
this.categoryKey = categoryKey;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private String caliber;
|
||||||
|
|
||||||
|
public String getCaliber() { return caliber; }
|
||||||
|
public void setCaliber(String caliber) { this.caliber = caliber; }
|
||||||
|
|
||||||
public BigDecimal getPrice() {
|
public BigDecimal getPrice() {
|
||||||
return price;
|
return price;
|
||||||
}
|
}
|
||||||
@@ -72,6 +77,11 @@ public class ProductSummaryDto {
|
|||||||
this.price = price;
|
this.price = price;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private Boolean inStock;
|
||||||
|
|
||||||
|
public Boolean getInStock() { return inStock; }
|
||||||
|
public void setInStock(Boolean inStock) { this.inStock = inStock; }
|
||||||
|
|
||||||
public String getBuyUrl() {
|
public String getBuyUrl() {
|
||||||
return buyUrl;
|
return buyUrl;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ public class ProductMapper {
|
|||||||
dto.setBrand(product.getBrand() != null ? product.getBrand().getName() : null);
|
dto.setBrand(product.getBrand() != null ? product.getBrand().getName() : null);
|
||||||
dto.setPlatform(product.getPlatform());
|
dto.setPlatform(product.getPlatform());
|
||||||
dto.setPartRole(product.getPartRole());
|
dto.setPartRole(product.getPartRole());
|
||||||
|
dto.setCaliber(product.getCaliber());
|
||||||
dto.setCategoryKey(product.getRawCategoryKey());
|
dto.setCategoryKey(product.getRawCategoryKey());
|
||||||
|
|
||||||
dto.setPrice(price);
|
dto.setPrice(price);
|
||||||
|
|||||||
Reference in New Issue
Block a user