com.macro.mall.model.PmsProductExample Java Examples

The following examples show how to use com.macro.mall.model.PmsProductExample. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: PmsBrandServiceImpl.java    From macrozheng-mall with MIT License 6 votes vote down vote up
@Override
public int updateBrand(Long id, PmsBrandParam pmsBrandParam) {
    PmsBrand pmsBrand = new PmsBrand();
    BeanUtils.copyProperties(pmsBrandParam, pmsBrand);
    pmsBrand.setId(id);
    //如果创建时首字母为空,取名称的第一个为首字母
    if (StringUtils.isEmpty(pmsBrand.getFirstLetter())) {
        pmsBrand.setFirstLetter(pmsBrand.getName().substring(0, 1));
    }
    //更新品牌时要更新商品中的品牌名称
    PmsProduct product = new PmsProduct();
    product.setBrandName(pmsBrand.getName());
    PmsProductExample example = new PmsProductExample();
    example.createCriteria().andBrandIdEqualTo(id);
    productMapper.updateByExampleSelective(product,example);
    return brandMapper.updateByPrimaryKeySelective(pmsBrand);
}
 
Example #2
Source File: PmsBrandServiceImpl.java    From macrozheng with Apache License 2.0 6 votes vote down vote up
@Override
public int updateBrand(Long id, PmsBrandParam pmsBrandParam) {
    PmsBrand pmsBrand = new PmsBrand();
    BeanUtils.copyProperties(pmsBrandParam, pmsBrand);
    pmsBrand.setId(id);
    //如果创建时首字母为空,取名称的第一个为首字母
    if (StringUtils.isEmpty(pmsBrand.getFirstLetter())) {
        pmsBrand.setFirstLetter(pmsBrand.getName().substring(0, 1));
    }
    //更新品牌时要更新商品中的品牌名称
    PmsProduct product = new PmsProduct();
    product.setBrandName(pmsBrand.getName());
    PmsProductExample example = new PmsProductExample();
    example.createCriteria().andBrandIdEqualTo(id);
    productMapper.updateByExampleSelective(product,example);
    return brandMapper.updateByPrimaryKeySelective(pmsBrand);
}
 
Example #3
Source File: PmsBrandServiceImpl.java    From mall-swarm with Apache License 2.0 6 votes vote down vote up
@Override
public int updateBrand(Long id, PmsBrandParam pmsBrandParam) {
    PmsBrand pmsBrand = new PmsBrand();
    BeanUtils.copyProperties(pmsBrandParam, pmsBrand);
    pmsBrand.setId(id);
    //如果创建时首字母为空,取名称的第一个为首字母
    if (StringUtils.isEmpty(pmsBrand.getFirstLetter())) {
        pmsBrand.setFirstLetter(pmsBrand.getName().substring(0, 1));
    }
    //更新品牌时要更新商品中的品牌名称
    PmsProduct product = new PmsProduct();
    product.setBrandName(pmsBrand.getName());
    PmsProductExample example = new PmsProductExample();
    example.createCriteria().andBrandIdEqualTo(id);
    productMapper.updateByExampleSelective(product,example);
    return brandMapper.updateByPrimaryKeySelective(pmsBrand);
}
 
Example #4
Source File: PmsBrandServiceImpl.java    From mall with Apache License 2.0 6 votes vote down vote up
@Override
public int updateBrand(Long id, PmsBrandParam pmsBrandParam) {
    PmsBrand pmsBrand = new PmsBrand();
    BeanUtils.copyProperties(pmsBrandParam, pmsBrand);
    pmsBrand.setId(id);
    //如果创建时首字母为空,取名称的第一个为首字母
    if (StringUtils.isEmpty(pmsBrand.getFirstLetter())) {
        pmsBrand.setFirstLetter(pmsBrand.getName().substring(0, 1));
    }
    //更新品牌时要更新商品中的品牌名称
    PmsProduct product = new PmsProduct();
    product.setBrandName(pmsBrand.getName());
    PmsProductExample example = new PmsProductExample();
    example.createCriteria().andBrandIdEqualTo(id);
    productMapper.updateByExampleSelective(product,example);
    return brandMapper.updateByPrimaryKeySelective(pmsBrand);
}
 
Example #5
Source File: PmsProductMapper.java    From mall with Apache License 2.0 votes vote down vote up
List<PmsProduct> selectByExampleWithBLOBs(PmsProductExample example); 
Example #6
Source File: PmsProductMapper.java    From mall with Apache License 2.0 votes vote down vote up
long countByExample(PmsProductExample example); 
Example #7
Source File: PmsProductMapper.java    From mall with Apache License 2.0 votes vote down vote up
List<PmsProduct> selectByExample(PmsProductExample example); 
Example #8
Source File: PmsProductMapper.java    From mall with Apache License 2.0 votes vote down vote up
int updateByExampleSelective(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #9
Source File: PmsProductMapper.java    From mall with Apache License 2.0 votes vote down vote up
int updateByExampleWithBLOBs(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #10
Source File: PmsProductMapper.java    From mall with Apache License 2.0 votes vote down vote up
int updateByExample(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #11
Source File: PmsProductMapper.java    From macrozheng-mall with MIT License votes vote down vote up
int countByExample(PmsProductExample example); 
Example #12
Source File: PmsProductMapper.java    From macrozheng-mall with MIT License votes vote down vote up
int deleteByExample(PmsProductExample example); 
Example #13
Source File: PmsProductMapper.java    From macrozheng-mall with MIT License votes vote down vote up
List<PmsProduct> selectByExampleWithBLOBs(PmsProductExample example); 
Example #14
Source File: PmsProductMapper.java    From macrozheng-mall with MIT License votes vote down vote up
List<PmsProduct> selectByExample(PmsProductExample example); 
Example #15
Source File: PmsProductMapper.java    From macrozheng-mall with MIT License votes vote down vote up
int updateByExampleSelective(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #16
Source File: PmsProductMapper.java    From macrozheng-mall with MIT License votes vote down vote up
int updateByExampleWithBLOBs(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #17
Source File: PmsProductMapper.java    From macrozheng-mall with MIT License votes vote down vote up
int updateByExample(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #18
Source File: PmsProductMapper.java    From mall with Apache License 2.0 votes vote down vote up
int deleteByExample(PmsProductExample example); 
Example #19
Source File: PmsProductMapper.java    From mall-swarm with Apache License 2.0 votes vote down vote up
long countByExample(PmsProductExample example); 
Example #20
Source File: PmsProductMapper.java    From macrozheng with Apache License 2.0 votes vote down vote up
int updateByExample(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #21
Source File: PmsProductMapper.java    From macrozheng with Apache License 2.0 votes vote down vote up
int updateByExampleWithBLOBs(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #22
Source File: PmsProductMapper.java    From macrozheng with Apache License 2.0 votes vote down vote up
int updateByExampleSelective(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #23
Source File: PmsProductMapper.java    From macrozheng with Apache License 2.0 votes vote down vote up
List<PmsProduct> selectByExample(PmsProductExample example); 
Example #24
Source File: PmsProductMapper.java    From macrozheng with Apache License 2.0 votes vote down vote up
List<PmsProduct> selectByExampleWithBLOBs(PmsProductExample example); 
Example #25
Source File: PmsProductMapper.java    From macrozheng with Apache License 2.0 votes vote down vote up
int deleteByExample(PmsProductExample example); 
Example #26
Source File: PmsProductMapper.java    From macrozheng with Apache License 2.0 votes vote down vote up
int countByExample(PmsProductExample example); 
Example #27
Source File: PmsProductMapper.java    From mall-swarm with Apache License 2.0 votes vote down vote up
int updateByExample(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #28
Source File: PmsProductMapper.java    From mall-swarm with Apache License 2.0 votes vote down vote up
int updateByExampleWithBLOBs(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #29
Source File: PmsProductMapper.java    From mall-swarm with Apache License 2.0 votes vote down vote up
int updateByExampleSelective(@Param("record") PmsProduct record, @Param("example") PmsProductExample example); 
Example #30
Source File: PmsProductMapper.java    From mall-swarm with Apache License 2.0 votes vote down vote up
List<PmsProduct> selectByExample(PmsProductExample example);