Browse Source

组织商品删除运费字段,统一为到付

Aslee 4 years ago
parent
commit
c2856764f2

+ 0 - 9
src/main/java/com/caimei/modules/weisha/entity/CmOrganizeProduct.java

@@ -27,7 +27,6 @@ public class CmOrganizeProduct extends DataEntity<CmOrganizeProduct> {
 	private Integer costType;		// 成本价类型:1固定成本 2比例成本
 	private Double costPrice;		// 成本价
 	private Double costProportional;		// 比例成本百分比
-	private Integer postageType;		// 是否包邮 0包邮 1到付 2默认(遵循运费规则)
 	private Integer status;		// 商品状态:0已下架,1已上架
 	private Date addTime;		// 添加时间
 
@@ -125,15 +124,7 @@ public class CmOrganizeProduct extends DataEntity<CmOrganizeProduct> {
 	public void setCostProportional(Double costProportional) {
 		this.costProportional = costProportional;
 	}
-	
-	public Integer getPostageType() {
-		return postageType;
-	}
 
-	public void setPostageType(Integer postageType) {
-		this.postageType = postageType;
-	}
-	
 	public Integer getStatus() {
 		return status;
 	}

+ 2 - 12
src/main/resources/mappings/modules/weisha/CmOrganizeProductMapper.xml

@@ -16,7 +16,6 @@
 		a.costType AS "costType",
 		a.costPrice AS "costPrice",
 		a.costProportional AS "costProportional",
-		a.postageType AS "postageType",
 		a.status AS "status",
 		a.addTime AS "addTime",
 		a.delFlag AS "delFlag",
@@ -69,13 +68,7 @@
 				AND a.organizeId = #{organizeId}
 			</if>
 		</where>
-		<choose>
-			<when test="page !=null and page.orderBy != null and page.orderBy != ''">
-				ORDER BY ${page.orderBy}
-			</when>
-			<otherwise>
-			</otherwise>
-		</choose>
+		order by a.addTime desc
 	</select>
 	
 	<select id="findAllList" resultType="CmOrganizeProduct">
@@ -114,7 +107,7 @@
 	</select>
 	<select id="findProductByProductId" resultType="com.caimei.modules.weisha.entity.CmOrganizeProduct">
 		select productID as productId, ladderPriceFlag,price1 as price,ifnull(includedTax,2) as includedTax,invoiceType,taxPoint as clubTaxPoint,supplierTaxPoint as shopTaxPoint,minBuyNumber,costCheckFlag as costType,
-		       costPrice,costProportional,ifnull(freePostFlag,2) as postageType
+		       costPrice,costProportional
 		from product
 		where productID = #{productId}
 	</select>
@@ -140,7 +133,6 @@
 			costType,
 			costPrice,
 			costProportional,
-			postageType,
 			addTime
 		) VALUES (
 			#{organizeId},
@@ -155,7 +147,6 @@
 			#{costType},
 			#{costPrice},
 			#{costProportional},
-			#{postageType},
 			#{addTime}
 		)
 	</insert>
@@ -178,7 +169,6 @@
 			costType = #{costType},
 			costPrice = #{costPrice},
 			costProportional = #{costProportional},
-			postageType = #{postageType},
 			status = #{status},
 			addTime = #{addTime},
 			delFlag = #{delFlag}

+ 0 - 8
src/main/webapp/WEB-INF/views/modules/weisha/cmOrganizeProductForm.jsp

@@ -216,14 +216,6 @@
 				<form:input path="costProportional" htmlEscape="false"  maxlength="11" class="short  number" /> %
 			</div>
 		</div>
-		<div class="control-group">
-			<label class="control-label">运费:</label>
-			<div class="controls">
-				<input type="radio" name="postageType" value="2" ${(empty cmOrganizeProduct.postageType || cmOrganizeProduct.postageType eq "2") ? "checked" : ""}>默认(遵循运费规则)<b class="line">|</b>
-				<input type="radio" name="postageType" value="0" ${product.postageType == "0" ? "checked" : ""}>包邮<b class="line">|</b>
-				<input type="radio" name="postageType" value="1" ${product.postageType == "1" ? "checked" : ""}>到付
-			</div>
-		</div>
 		<div class="form-actions">
 			<input id="btnSubmit" class="btn btn-primary" type="submit" value="保 存"/>
 			<input id="btnCancel" class="btn" type="button" value="返 回" onclick="history.go(-1)"/>

+ 1 - 1
src/main/webapp/WEB-INF/views/modules/weisha/cmOrganizeProductList.jsp

@@ -187,7 +187,7 @@
 				</td>
 				<td>
     				<a href="${ctx}/weisha/cmOrganizeProduct/form?id=${cmOrganizeProduct.id}">编辑</a>
-    				<a href="${ctx}/weisha/cmOrganizeProduct/updateStatus?organizeId=${organizeId}&id=${cmOrganizeProduct.id}&status=${cmOrganizeProduct.status eq 1?0:1}">${cmOrganizeProduct.status eq 1?'下架':'上架'}</a>
+    				<a href="${ctx}/weisha/cmOrganizeProduct/updateStatus?organizeId=${organizeId}&id=${cmOrganizeProduct.id}&status=${cmOrganizeProduct.status eq 1?0:1}"  onclick="return confirmx('确定'+${cmOrganizeProduct.status eq 1?'下架该商品吗?':'上架该商品吗?'}, this.href)">${cmOrganizeProduct.status eq 1?'下架':'上架'}</a>
 					<a href="${ctx}/weisha/cmOrganizeProduct/delete?id=${cmOrganizeProduct.id}" onclick="return confirmx('确认要删除该商品吗?删除后需要重新添加', this.href)">删除</a>
 				</td>
 			</tr>