mirror of
https://gitee.com/coder-xiaomo/flashsale
synced 2025-09-13 07:21:38 +08:00
商品模型1
This commit is contained in:
@@ -0,0 +1,82 @@
|
||||
package com.cxyxiaomo.flashsale.service.model;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
public class ItemModel {
|
||||
// 商品价格
|
||||
private Integer id;
|
||||
|
||||
// 商品名称
|
||||
private String title;
|
||||
|
||||
// 商品价格
|
||||
private BigDecimal price;
|
||||
|
||||
// 商品的库存
|
||||
private Integer stock;
|
||||
|
||||
// 商品的描述
|
||||
private String description;
|
||||
|
||||
// 商品的销量
|
||||
private Integer sales;
|
||||
|
||||
// 商品描述图片的URL
|
||||
private String imgUrl;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getTitle() {
|
||||
return title;
|
||||
}
|
||||
|
||||
public void setTitle(String title) {
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
public BigDecimal getPrice() {
|
||||
return price;
|
||||
}
|
||||
|
||||
public void setPrice(BigDecimal price) {
|
||||
this.price = price;
|
||||
}
|
||||
|
||||
public Integer getStock() {
|
||||
return stock;
|
||||
}
|
||||
|
||||
public void setStock(Integer stock) {
|
||||
this.stock = stock;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
||||
public void setDescription(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
public Integer getSales() {
|
||||
return sales;
|
||||
}
|
||||
|
||||
public void setSales(Integer sales) {
|
||||
this.sales = sales;
|
||||
}
|
||||
|
||||
public String getImgUrl() {
|
||||
return imgUrl;
|
||||
}
|
||||
|
||||
public void setImgUrl(String imgUrl) {
|
||||
this.imgUrl = imgUrl;
|
||||
}
|
||||
}
|
@@ -14,13 +14,13 @@
|
||||
|
||||
<!-- 生成 DataObject 类存放位置 -->
|
||||
<javaModelGenerator targetPackage="com.cxyxiaomo.flashsale.dataobject" targetProject="src/main/java">
|
||||
<property name="enableSubPackages" value="true" />
|
||||
<property name="trimStrings" value="true" />
|
||||
<property name="enableSubPackages" value="true"/>
|
||||
<property name="trimStrings" value="true"/>
|
||||
</javaModelGenerator>
|
||||
|
||||
<!-- 生成映射文件存放位置 -->
|
||||
<sqlMapGenerator targetPackage="mapping" targetProject="src/main/resources">
|
||||
<property name="enableSubPackages" value="true" />
|
||||
<sqlMapGenerator targetPackage="mapping" targetProject="src/main/resources">
|
||||
<property name="enableSubPackages" value="true"/>
|
||||
</sqlMapGenerator>
|
||||
|
||||
<!-- 生成Dao类存放位置 -->
|
||||
@@ -30,21 +30,27 @@
|
||||
type="XM1LMAPPER",生成SQLMap XML文件和独立的Mapper接口
|
||||
-->
|
||||
<javaClientGenerator type="XMLMAPPER" targetPackage="com.cxyxiaomo.flashsale.dao" targetProject="src/main/java">
|
||||
<property name="enableSubPackages" value="true" />
|
||||
<property name="enableSubPackages" value="true"/>
|
||||
</javaClientGenerator>
|
||||
|
||||
<!--去除复杂操作语句-->
|
||||
<!--enableCountByExample="false"-->
|
||||
<!--enableUpdateByExample="false" -->
|
||||
<!--enableDeleteByExample="false" -->
|
||||
<!--enableSelectByExample="false"-->
|
||||
<!--selectByExampleQueryId="false"-->
|
||||
|
||||
<!-- 生成对应表及其类名 -->
|
||||
<table tableName="user_info" domainObjectName="userDO" enableCountByExample="false"
|
||||
<table tableName="user_info" domainObjectName="UserDO" enableCountByExample="false"
|
||||
enableUpdateByExample="false" enableDeleteByExample="false" enableSelectByExample="false"
|
||||
selectByExampleQueryId="false">
|
||||
<!--去除复杂操作语句-->
|
||||
<!--enableCountByExample="false"-->
|
||||
<!--enableUpdateByExample="false" -->
|
||||
<!--enableDeleteByExample="false" -->
|
||||
<!--enableSelectByExample="false"-->
|
||||
<!--selectByExampleQueryId="false"-->
|
||||
</table>
|
||||
<table tableName="user_password" domainObjectName="userPasswordDO" enableCountByExample="false"
|
||||
selectByExampleQueryId="false"></table>
|
||||
<table tableName="user_password" domainObjectName="UserPasswordDO" enableCountByExample="false"
|
||||
enableUpdateByExample="false" enableDeleteByExample="false" enableSelectByExample="false"
|
||||
selectByExampleQueryId="false"></table>
|
||||
<table tableName="item_info" domainObjectName="ItemDO" enableCountByExample="false"
|
||||
enableUpdateByExample="false" enableDeleteByExample="false" enableSelectByExample="false"
|
||||
selectByExampleQueryId="false"></table>
|
||||
<table tableName="item_stock" domainObjectName="ItemStockDO" enableCountByExample="false"
|
||||
enableUpdateByExample="false" enableDeleteByExample="false" enableSelectByExample="false"
|
||||
selectByExampleQueryId="false"></table>
|
||||
|
||||
|
Reference in New Issue
Block a user