新增打单产品分区管理功能,优化常规分区逻辑
This commit is contained in:
@@ -20,11 +20,12 @@ import com.bms.common.core.page.TableDataInfo;
|
||||
import com.bms.common.enums.BusinessType;
|
||||
import com.bms.price.domain.PrcZone;
|
||||
import com.bms.price.domain.PrcZoneDetail;
|
||||
import com.bms.price.domain.PrcZoneLabelProduct;
|
||||
import com.bms.price.domain.PrcZoneRegion;
|
||||
import com.bms.price.service.IPrcZoneService;
|
||||
|
||||
/**
|
||||
* 分区管理:国家(region) -> 分区 -> 邮编明细
|
||||
* 分区管理:常规按国家;打单按产品。
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/price/zone")
|
||||
@@ -59,12 +60,36 @@ public class ZoneController extends BaseController
|
||||
return toAjax(zoneService.deleteZonesByRegionIds(regionIds));
|
||||
}
|
||||
|
||||
|
||||
// ========== label product zones ==========
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('price:zone:list')")
|
||||
@GetMapping("/label/product/list")
|
||||
public TableDataInfo labelProductList(PrcZoneLabelProduct query)
|
||||
{
|
||||
startPage();
|
||||
List<PrcZoneLabelProduct> list = zoneService.selectLabelProductZoneList(query);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('price:zone:remove')")
|
||||
@Log(title = "LabelZoneProduct", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/label/product/{productId}")
|
||||
public AjaxResult removeLabelProductZones(@PathVariable Long productId)
|
||||
{
|
||||
return toAjax(zoneService.deleteZonesByProductId(productId));
|
||||
}
|
||||
|
||||
// ========== zone ==========
|
||||
|
||||
@PreAuthorize("@ss.hasPermi('price:zone:list')")
|
||||
@GetMapping("/item/list")
|
||||
public TableDataInfo zoneList(PrcZone zone)
|
||||
{
|
||||
if (zone.getZoneType() == null || zone.getZoneType().isEmpty())
|
||||
{
|
||||
zone.setZoneType(PrcZone.TYPE_REGULAR);
|
||||
}
|
||||
startPage();
|
||||
List<PrcZone> list = zoneService.selectPrcZoneList(zone);
|
||||
return getDataTable(list);
|
||||
|
||||
Reference in New Issue
Block a user