当前位置: 首页>>代码示例>>Java>>正文


Java Propagation.SUPPORTS属性代码示例

本文整理汇总了Java中org.springframework.transaction.annotation.Propagation.SUPPORTS属性的典型用法代码示例。如果您正苦于以下问题:Java Propagation.SUPPORTS属性的具体用法?Java Propagation.SUPPORTS怎么用?Java Propagation.SUPPORTS使用的例子?那么恭喜您, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在org.springframework.transaction.annotation.Propagation的用法示例。


在下文中一共展示了Propagation.SUPPORTS属性的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: addSystemCarModel

@Override
@Transactional(propagation = Propagation.SUPPORTS, readOnly = false)
public DataCarModel addSystemCarModel(DataCarModel systemCarModel) {
	Integer parentId = systemCarModel.getParentId();
	// 获取汽车车系
	DataCarCars systemCars = carsService.getSystemCarsById(parentId);
	systemCarModel.setParentId(parentId);
	systemCarModel.setInitial(systemCars.getInitial());
	systemCarModel.setDepth(4);
	// 添加数据
	systemCarModel = carModelDao.insert(systemCarModel);
	// 增加了汽车车型,就需要添加汽车车型的配置信息(基础信息,basic等详细信息暂无)
	DataCarAttribute systemCarAttr = new DataCarAttribute();
	systemCarAttr.setId(systemCarModel.getId());
	carAttrServcie.addSystemCarAttr(systemCarAttr);
	return systemCarModel;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:17,代码来源:DataCarModelServiceImpl.java

示例2: updateSystemCarAttr

@Override
@Transactional(propagation = Propagation.SUPPORTS, readOnly = false)
public boolean updateSystemCarAttr(DataCarAttribute DataCarAttribute) {
	// 对图片的长度进行判断
	String facadeImage = DataCarAttribute.getFacadeImage();
	String centralImage = DataCarAttribute.getCentralImage();
	String seatImage = DataCarAttribute.getSeatImage();
	String detailImage = DataCarAttribute.getDetailImage();
	if (facadeImage!=null && !"".equals(facadeImage)){
		DataCarAttribute.setFacadeImageCount(facadeImage.split(",").length);
	}
	if (centralImage!=null && !"".equals(centralImage)){
		DataCarAttribute.setCentralImageCount(centralImage.split(",").length);
	}
	if (seatImage!=null && !"".equals(seatImage)){
		DataCarAttribute.setSeatImageCount(seatImage.split(",").length);
	}
	if (detailImage!=null && !"".equals(detailImage)){
		DataCarAttribute.setDetailImageCount(detailImage.split(",").length);
	}
	return carAttributeDao.update(DataCarAttribute) > 0;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:22,代码来源:DataCarAttributeServiceImpl.java

示例3: updateSystemCarModel

@Override
@Transactional(propagation = Propagation.SUPPORTS, readOnly = false)
public boolean updateSystemCarModel(DataCarModel systemCarModel) {
	systemCarModel.setDepth(4);
	// 因为车型的配置信息,由车型信息下发,所以更改车型信息时,同时更改车型的配置信息(只更改基础信息)
	// 先判断是否存在配置信息,如果不存在,则不修改
	Integer carModelId = systemCarModel.getId();
	boolean isExist = carAttrServcie.idIsExist(String.valueOf(carModelId));
	if (isExist) {
		DataCarAttribute systemCarAttr = carModelToAttr(systemCarModel);
		systemCarAttr.setId(carModelId);
		carAttrServcie.updateSystemCarAttr(systemCarAttr);
	}
	return carModelDao.update(systemCarModel) > 0;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:15,代码来源:DataCarModelServiceImpl.java

示例4: deleteSystemCarModel

@Override
@Transactional(propagation = Propagation.SUPPORTS, readOnly = false)
public boolean deleteSystemCarModel(String id) {
	// 当删除汽车车型数据时,同事删除车型的配置信息
	carAttrServcie.deleteSystemCarAttr(id);
	return carModelDao.delete(id) > 0;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:7,代码来源:DataCarModelServiceImpl.java

示例5: addSystemCars

@Override
@Transactional(propagation=Propagation.SUPPORTS,readOnly=false)
public DataCarCars addSystemCars(DataCarCars carsEntity) {
	Integer parentId = carsEntity.getParentId();
	// 获取父汽车子公司
	DataCarSubBrand carSubBrandEntity = carSubBrandService.getCarSubBrandById(parentId);
	carsEntity.setParentId(parentId);
	carsEntity.setInitial(carSubBrandEntity.getInitial());
	carsEntity.setDepth(3);
	// 添加数据
	carsEntity = carsDao.insert(carsEntity);
	return carsEntity;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:13,代码来源:DataCarCarsServiceImpl.java

示例6: addSystemCarBrand

@Override
@Transactional(propagation = Propagation.SUPPORTS, readOnly = false)
public DataCarBrand addSystemCarBrand(DataCarBrand systemCarBrand) {
	systemCarBrand.setParentId(0);
	systemCarBrand.setStatus(PublicEnum.NORMAL.value());
	systemCarBrand.setDepth(1);
	// 添加数据
	systemCarBrand = carBrandDao.insert(systemCarBrand);
	return systemCarBrand;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:10,代码来源:DataCarBrandServiceImpl.java

示例7: udpateSystemCarBrand

@Override
@Transactional(propagation = Propagation.SUPPORTS, readOnly = false)
public boolean udpateSystemCarBrand(DataCarBrand systemCarBrand) {
	systemCarBrand.setParentId(0);
	systemCarBrand.setDepth(1);
	return carBrandDao.update(systemCarBrand) > 0;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:7,代码来源:DataCarBrandServiceImpl.java

示例8: addSystemCarSubBrand

@Override
@Transactional(propagation = Propagation.SUPPORTS, readOnly = false)
public DataCarSubBrand addSystemCarSubBrand(DataCarSubBrand carSubBrandEntity) {
	Integer parentId = carSubBrandEntity.getParentId();
	// 获取父品牌
	DataCarBrand carBrandEntity = carBrandService.getSystemCarBrandById(parentId);
	carSubBrandEntity.setParentId(parentId);
	carSubBrandEntity.setInitial(carBrandEntity.getInitial());
	carSubBrandEntity.setDepth(2);
	carSubBrandEntity.setStatus(PublicEnum.NORMAL.value());
	// 添加数据
	carSubBrandEntity = carSubBrandDao.insert(carSubBrandEntity);
	return carSubBrandEntity;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:14,代码来源:DataCarSubBrandServiceImpl.java

示例9: updateSystemCars

@Override
@Transactional(propagation=Propagation.SUPPORTS,readOnly=false)
public boolean updateSystemCars(DataCarCars carsEntity) {
	carsEntity.setDepth(3);
	return carsDao.update(carsEntity) > 0;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:6,代码来源:DataCarCarsServiceImpl.java

示例10: deleteSystemCarAttr

@Override
@Transactional(propagation = Propagation.SUPPORTS, readOnly = false)
public boolean deleteSystemCarAttr(String id) {
	return carAttributeDao.delete(id) > 0;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:5,代码来源:DataCarAttributeServiceImpl.java

示例11: updateSystemCarSubBrand

@Override
@Transactional(propagation = Propagation.SUPPORTS, readOnly = false)
public boolean updateSystemCarSubBrand(DataCarSubBrand carSubBrandEntity) {
	carSubBrandEntity.setDepth(2);
	return carSubBrandDao.update(carSubBrandEntity) > 0;
}
 
开发者ID:babymm,项目名称:mumu,代码行数:6,代码来源:DataCarSubBrandServiceImpl.java

示例12: enumerateItems

@Override
@Transactional(propagation = Propagation.SUPPORTS)
public List<ItemId> enumerateItems(String whereClause, String[] names, Object[] values)
{
	return dao.enumerateItemKeys(whereClause, names, values);
}
 
开发者ID:equella,项目名称:Equella,代码行数:6,代码来源:ItemServiceImpl.java

示例13: getItemIdKeys

@Override
@Transactional(propagation = Propagation.SUPPORTS)
public List<ItemIdKey> getItemIdKeys(List<Long> ids)
{
	return dao.getItemIdKeys(ids);
}
 
开发者ID:equella,项目名称:Equella,代码行数:6,代码来源:ItemServiceImpl.java

示例14: getItemIdKey

@Override
@Transactional(propagation = Propagation.SUPPORTS)
public ItemIdKey getItemIdKey(Long id)
{
	return dao.getItemIdKey(id);
}
 
开发者ID:equella,项目名称:Equella,代码行数:6,代码来源:ItemServiceImpl.java

示例15: operateAll

@Override
@Transactional(propagation = Propagation.SUPPORTS)
public void operateAll(ItemOperationFilter filter)
{
	operateAllPrivate(filter, null);
}
 
开发者ID:equella,项目名称:Equella,代码行数:6,代码来源:ItemServiceImpl.java


注:本文中的org.springframework.transaction.annotation.Propagation.SUPPORTS属性示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。