Aslee 3 년 전
부모
커밋
30db139898

+ 3 - 0
src/main/java/com/caimei/modules/svip/web/CmSvipProductController.java

@@ -4,6 +4,7 @@ import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 
 import com.caimei.modules.live.entity.NewPageLiveAdvertisingImage;
+import com.caimei.modules.miniprogram.utils.UploadPicUtils;
 import com.caimei.modules.product.entity.Product;
 import com.caimei.modules.svip.entity.CmSvipProductAdsImage;
 import com.caimei.utils.MathUtil;
@@ -155,6 +156,8 @@ public class CmSvipProductController extends BaseController {
 			model.addAttribute("errorMsg", "请上传小程序端宣传图");
 			return adsImageForm(model);
 		}
+		UploadPicUtils.saveImageToServer(adsImage.getPcImage());
+		UploadPicUtils.saveImageToServer(adsImage.getAppletsImage());
 		cmSvipProductService.saveAdsImage(adsImage);
 		addMessage(redirectAttributes, "保存成功");
 		return "redirect:"+Global.getAdminPath()+"/svip/cmSvipProduct/?repage";

+ 2 - 2
src/main/webapp/WEB-INF/views/modules/svip/cmSvipProductAdsImageForm.jsp

@@ -106,7 +106,7 @@
 					<form:hidden id="pcImage" path="pcImage" htmlEscape="false" maxlength="255" class="input-xlarge required"/>
 					<sys:ckfinder input="pcImage" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
 					<br>
-					<label style="margin-left: 150px">建议图片分辨率750px*750px</label>
+					<label style="margin-left: 150px">建议图片分辨率1920px*510px</label>
 				</div>
 			</div>
 		</div>
@@ -117,7 +117,7 @@
 					<form:hidden id="appletsImage" path="appletsImage" htmlEscape="false" maxlength="255" class="input-xlarge required"/>
 					<sys:ckfinder input="appletsImage" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
 					<br>
-					<label style="margin-left: 150px">建议图片分辨率750px*750px</label>
+					<label style="margin-left: 150px">建议图片分辨率351px*170px</label>
 				</div>
 			</div>
 		</div>

+ 2 - 2
src/main/webapp/WEB-INF/views/modules/svip/cmSvipProductList.jsp

@@ -44,7 +44,7 @@
 		<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
 		<div class="ul-form">
 			 <label>商品ID:</label>
-				<form:input path="productId" htmlEscape="false" class="input-medium"/>
+				<form:input path="productId" htmlEscape="false" onkeyup="onlynum(this)" class="input-medium"/>
 			 <label>商品名称:</label>
 				<form:input path="productName" htmlEscape="false" class="input-medium"/>
 			 <label>供应商:</label>
@@ -62,7 +62,7 @@
 				<th>商品id</th>
 				<th>商品图片</th>
 				<th>商品名称</th>
-				<th>商品供应商</th>
+				<th>供应商</th>
 				<th>机构价</th>
 				<th>会员折扣</th>
 				<th>会员价</th>

+ 4 - 7
src/main/webapp/WEB-INF/views/modules/svip/svipAddProduct.jsp

@@ -100,7 +100,6 @@
     }
 
     function getCheckedItems() {
-        debugger
         var items = new Array();
         var $items = $('.check-item:checked');
         var error = 0;
@@ -144,18 +143,16 @@
     function changeDiscount(productId,priceType) {
         if (priceType == 1) {
             var val = $("#discount" + productId).val();
-            if (val > 100 || val <0) {
+            if (val == '') {
+                $("#discountPrice"+productId).removeAttr('readonly');
+            } else if (val > 100 || val <0) {
                 $.jBox.tip("请输入0-100之间的数字", 'info');
-                val = '';
                 $("#discount" + productId).val('');
+                $("#discountPrice"+productId).removeAttr('readonly');
             }else {
                 val = Number(val).toFixed(2);
                 $("#discount" + productId).val(val);
-            }
-            if (val != '' && val != undefined) {
                 $("#discountPrice"+productId).attr('readonly', 'readonly');
-            } else {
-                $("#discountPrice"+productId).removeAttr('readonly');
             }
         } else {
             var val = $("#discountPrice" + productId).val();

+ 40 - 8
src/main/webapp/WEB-INF/views/modules/user/clubTemporaryForm.jsp

@@ -12,14 +12,23 @@
 				submitHandler: function (form) {
 					var bindMobile = $("#bindMobile").val();
 					var userID = $("#userId").val();
-					$.post("${ctx}/new/user/agency/checkMobile?bindMobile="+bindMobile+"&userID="+userID, function (data) {
-						if (data.code == -1) {
-							alertx(data.msg);
-						}else {
-							loading('正在提交,请稍等...');
-							form.submit();
-						}
-					})
+					var submitFlag = true;
+					var firstClubType = $('input[name=firstClubType]:checked').val();
+					var secondClubType = $('input[name=secondClubType]:checked').val();
+					if ((firstClubType == '1' && secondClubType > 4) || (firstClubType == '2' && secondClubType <= 4)) {
+						alertx("请选择机构类型");
+						submitFlag = false;
+					}
+					if (submitFlag) {
+						$.post("${ctx}/new/user/agency/checkMobile?bindMobile="+bindMobile+"&userID="+userID, function (data) {
+							if (data.code == -1) {
+								alertx(data.msg);
+							}else {
+								loading('正在提交,请稍等...');
+								form.submit();
+							}
+						})
+					}
 				},
 				errorContainer: "#messageBox",
 				errorPlacement: function (error, element) {
@@ -168,6 +177,7 @@
 				var html = '';
 				var nameval = $(this).val();
 				if (nameval == '1') {
+					$('.raw-option').hide();
 					$('.med-option,.qualification').show();
 					html += '<span class="new-tag up-club-tag" data-typeName="整形">整形</span>',
 							html += '<span class="new-tag up-club-tag" data-typeName="轻医美">轻医美</span>',
@@ -176,11 +186,13 @@
 					$('.Main-content').show();
 				} else if (nameval == '2') {
 					$('.med-option,.qualification,.epart').hide();
+					$('.raw-option').show();
 					$('input[name="secondClubType"]').attr('checked', false);
 					html += '<span class="new-tag up-club-tag" data-typeName="美容">美容</span>',
 							html += '<span class="new-tag up-club-tag" data-typeName="美体">美体</span>',
 							html += '<span class="new-tag up-club-tag" data-typeName="美发">美发</span>',
 							html += '<span class="new-tag up-club-tag" data-typeName="皮肤管理">皮肤管理</span>',
+							html += '<span class="new-tag up-club-tag" data-typeName="产后修复">产后修复</span>',
 							html += '<span class="new-tag up-club-tag" data-typeName="光电">光电</span>',
 							html += '<span class="new-tag up-club-tag" data-typeName="综合类">综合类</span>',
 							html += '<span class="new-tag up-club-tag" data-typeName="中医养生">中医养生</span>',
@@ -320,6 +332,11 @@
 			margin: 10px 0 0 160px;
 		}
 
+		.raw-option {
+			display: block;
+			margin: 10px 0 0 160px;
+		}
+
 		.control-group .new-tag {
 			display: inline-block;
 			width: 78px;
@@ -496,6 +513,21 @@
 						<div class="med-beauty"><input name="secondClubType" value="3"
 													   type="radio" ${clubTemporary.secondClubType == "3" ? "checked" : ""}/>医院
 						</div>
+						<div class="med-beauty"><input name="secondClubType" value="4"
+													   type="radio" ${cmClubinfo.secondClubType == "4" ? "checked" : ""}/>其他
+						</div>
+						<span class="err-tip"></span>
+					</div>
+					<div class="raw-option the-oradio" style="display: none">
+						<div class="med-beauty"><input name="secondClubType" value="5"
+													   type="radio"  ${cmClubinfo.secondClubType == "5" ? "checked" : ""}/>美容院
+						</div>
+						<div class="med-beauty"><input name="secondClubType" value="6"
+													   type="radio"  ${cmClubinfo.secondClubType == "6" ? "checked" : ""}/>养生馆
+						</div>
+						<div class="med-beauty"><input name="secondClubType" value="7"
+													   type="radio" ${cmClubinfo.secondClubType == "7" ? "checked" : ""}/>其他
+						</div>
 						<span class="err-tip"></span>
 					</div>
 					<div class="qualification control-group" style="display: none">

+ 0 - 1
src/main/webapp/WEB-INF/views/modules/userNew/cmAgencyForm.jsp

@@ -11,7 +11,6 @@
             $("#inputForm").validate({
                 ignore: "",
                 submitHandler: function (form) {
-                    debugger
                     var bindMobile = $("#bindMobile").val();
                     var userID = $("#userID").val();
                     var submitFlag = true;