Duan_xu 2 lat temu
rodzic
commit
6dcbf8a199

+ 1 - 1
src/main/java/com/caimei/modules/newhome/web/NewPageFloorController.java

@@ -167,7 +167,7 @@ public class NewPageFloorController extends BaseController {
         model.addAttribute("count",count);
         model.addAttribute("page", list);
         model.addAttribute("date", new Date());
-//        model.addAttribute("addtime", pro.getAddTime());
+        model.addAttribute("newPageFloor",newPageFloor);
         return "modules/newhome/newFloorcontentForm";
     }
 

+ 2 - 1
src/main/resources/mappings/modules/newhome/NewPageFloorMapper.xml

@@ -180,7 +180,8 @@
 	</update>
 	<update id="updatshowFlag">
 		UPDATE product SET
-		showFlag=#{showFlag}
+		showFlag=#{showFlag},
+		recommend=#{recommend}
 		WHERE productID = #{productID}
 	</update>
 

+ 23 - 9
src/main/webapp/WEB-INF/views/modules/newhome/newFloorcontentForm.jsp

@@ -10,7 +10,13 @@
 	</style>
 	<script type="text/javascript">
 		$(document).ready(function() {
-
+            var tb=document.getElementById('contentTable');
+            // var rows=tb.rows;
+            for(var j=1;j<tb.rows.length; j++){
+                 // te=(tb.rows[j].cells[4].innerHTML,tb.rows[j].cells[4].innerHTML);
+                console.log(tb.rows[j].cells[4].innerHTML.slice(33))
+            }
+            // alert($("#span").text());
 		});
 		function page(n,s){
 			$("#pageNo").val(n);
@@ -162,7 +168,7 @@ debugger
 			console.log(newshowTime)
 			$.jBox.confirm("确定下线该商品吗?下线后该商品将不展示在商城新品区域","提示",function(v,h,f){
 				if(v === 1){
-					window.location.href="${ctx}/newhome/newPageFloor/updatshowFlag?showFlag=3&productID="+productID+"&newshowTime="+newshowTime+"&ShowTime="+ShowTime+"&addTime"+addTime;
+					window.location.href="${ctx}/newhome/newPageFloor/updatshowFlag?recommend=0&showFlag=4&productID="+productID+"&newshowTime="+newshowTime+"&ShowTime="+ShowTime+"&addTime"+addTime;
 				}
 			} ,{ buttons: {  '确定': 1,'取消':2}});
 		}
@@ -186,7 +192,7 @@ debugger
 <body>
 	<ul class="nav nav-tabs">
 		<li><a href="${ctx}/newhome/newPageFloor/lists">固定楼层管理列表</a></li>
-		<li class="active"><a href="${ctx}/newhome/newPageFloor/ContentPage">内容</a></li>
+		<li class="active"><a href="${ctx}/newhome/newPageFloor/ContentPage?floorId=${newPageFloor.id}&floorTitle=${newPageFloor.floorTitle}&floorType=${newPageFloor.floorType}">内容</a></li>
 	</ul>
 	<form:form id="searchForm" modelAttribute="" action="${ctx}/newhome/newPageFloor/ContentPage" class="breadcrumb form-search">
 		<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
@@ -208,11 +214,12 @@ debugger
 			</select>
 			<input class="btn btn-primary" style="width: 70px" onclick="batchSaveSort()" value="一键排序"/>&nbsp;&nbsp;&nbsp;&nbsp;
 			<input id="btnSubmit" class="btn btn-primary" type="submit" value="查询"/>
+			楼层名称:&nbsp;<span>${newPageFloor.floorTitle}</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span>楼层类型:&nbsp;<c:if test="${newPageFloor.floorType eq 1}">新品橱窗</c:if></span>
 		</div>
 	</form:form>
 
 	<sys:message content="${message}"/>
-	<table id="contentTable" class="table table-striped table-bordered table-condensed">
+    <table id="contentTable" class="table table-striped table-bordered table-condensed">
 		<thead>
 			<tr>
 				<th>商品ID</th>
@@ -225,6 +232,7 @@ debugger
 				<th>操作</th>
 			</tr>
 		</thead>
+
 		<tbody>
 		<c:forEach items="${page.list}" var="list">
 			<tr>
@@ -239,7 +247,7 @@ debugger
 					<c:if test="${list.showFlag eq 2}">
 						<font color="#ff8c00">展示过期</font>
 					</c:if>
-					<c:if test="${list.showFlag eq 3}">
+					<c:if test="${list.showFlag eq 4}">
 						<font color="red">已下线</font>
 					</c:if></td>
 
@@ -247,11 +255,17 @@ debugger
 					<c:if test="${not empty list.newshowTime}">
 					${list.newshowTime}~${list.showTime}
 					</c:if>
-	<c:if test="${not empty list.showTime && list.newshowTime ==null}">
-						${list.addTime}~${list.showTime}
+	<c:if test="${not empty list.addTime && list.newshowTime ==null}">
+          ${list.addTime}~${list.showTime}
 	</c:if>
 				</td>
-				<td><input  id="sort" name="sortIndex" style="width:50px;" value="${list.sortIndex}"  onkeyup="onlynum(this)"  onchange="changeSort(${list.productID},this)"></td>
+				<td>
+					<c:if test="${not empty list.sortIndex && list.sortIndex!=0}">
+					<input  id="sort" name="sortIndex" style="width:50px;" value="${list.sortIndex}"  onkeyup="onlynum(this)"  onchange="changeSort(${list.productID},this)"></td>
+				</c:if>
+				<c:if test="${empty list.sortIndex || list.sortIndex==0}">
+					<input  id="sort" name="sortIndex" style="width:50px;" value="1"  onkeyup="onlynum(this)"  onchange="changeSort(${list.productID},this)"></td>
+				</c:if>
 				<td>
 					<c:if test="${list.recommend eq 1}"><img src="/static/images/yes.gif" width="15px" border="none"/></c:if>
 				</td>
@@ -259,7 +273,7 @@ debugger
 					<c:if test="${list.showFlag eq 3}"><a class="red" href="javascript:void(0);" onclick="offocea(${list.productID},'${list.newshowTime}','${list.showTime}','${list.addTime}')">上线商品</a></c:if>
 					<c:if test="${list.showFlag eq 1 }"><a class="red" href="javascript:void(0);" onclick="offoceb(${list.productID},'${list.newshowTime}','${list.showTime}','${list.addTime}')">下线商品</a>	</c:if>
 					<c:if test="${list.recommend eq 1}"><a class="red" href="javascript:void(0);" onclick="offocec(${list.productID})">取消重点推荐</a> </c:if>
-					<c:if test="${list.recommend != 1 && count<=5}"><a class="red" href="javascript:void(0);" onclick="offoced(${list.productID})">设为重点推荐</a></c:if>
+					<c:if test="${list.recommend != 1 && count<=5 && list.showFlag != 4}"><a class="red" href="javascript:void(0);" onclick="offoced(${list.productID})">设为重点推荐</a></c:if>
 		          <a class="red" href="javascript:void(0);" onclick="offoce(${list.productID},new Date,'${list.newshowTime}','${list.addTime}')">更改展示时间</a>
                </td>
 </c:forEach>

+ 1 - 1
src/main/webapp/WEB-INF/views/modules/newhome/newPageFloorLists.jsp

@@ -161,7 +161,7 @@
 				<td><fmt:formatDate value="${newPageFloor.createDate}" pattern="yyyy-MM-dd HH:mm:ss"/></td>
 				<shiro:hasPermission name="newhome:newPageFloor:edit"><td>
     				<a href="${ctx}/newhome/newPageFloor/form?id=${newPageFloor.id}">编辑</a>
-                    <a href="${ctx}/newhome/newPageFloor/ContentPage?floorId=${newPageFloor.id}">内容</a>
+                    <a href="${ctx}/newhome/newPageFloor/ContentPage?floorId=${newPageFloor.id}&floorTitle=${newPageFloor.floorTitle}&floorType=${newPageFloor.floorType}">内容</a>
     				<shiro:hasPermission name="newhome:newPageFloor:delete">
 					<a href="${ctx}/newhome/newPageFloor/delete?id=${newPageFloor.id}" onclick="return confirmx('确定删除该楼层吗?', this.href)">删除</a>
 					</shiro:hasPermission>

+ 36 - 4
src/main/webapp/WEB-INF/views/modules/order/cmDiscernReceiptList.jsp

@@ -46,12 +46,21 @@
         .check-btn-wrapper input:last-child {
             margin-left: 10px;
         }
+        .select-ele input-medium:hover .options {
+            display: block;
+        }
         .weishaIcon {background:darkorange;color:white;margin:0 0px;padding:0 3px;font-style:normal;font-size: 12px; display:inline-block;border-radius:2px}
     </style>
     <script type="text/javascript">
-        $(document).ready(function () {
-
-        });
+        // $(document).ready(function () {
+        //
+        // });
+            $("#receipt").hover(function(){
+                console.log(1);
+                $("#mark-info").show();
+            },function(){
+                $("#mark-info").hide();
+            })
 
         function page(n, s) {
             $("#pageNo").val(n);
@@ -74,6 +83,22 @@
         function onlynum(obj) {
             obj.value = obj.value.replace(/[^\d]/g, ""); //清除"数字"以外的字符
         }
+
+        debugger
+        function myClickshow(one){
+            var event=document.getElementById("mark-info");
+            event.style.display="block";
+        }
+        function myClickhide(one){
+            var event=document.getElementById("mark-info");
+            event.style.display="none";
+        }
+
+        function changeReceiptType(){
+            debugger
+            var receiptType = $("#receiptType").val();
+            alertx(receiptType)
+        }
     </script>
 </head>
 <body>
@@ -103,17 +128,24 @@
                               htmlEscape="false"/>
             </form:select>
             <label>收款类别:</label>
-            <form:select path="receiptType" class="select-ele input-medium">
+            <form:select path="receiptType" class="select-ele input-medium" onchange="changeReceiptType()">
                 <form:option value="" label="全部"/>
                 <form:options items="${fns:getDictList('receiptType')}" itemLabel="label" itemValue="value"
                               htmlEscape="false"/>
             </form:select>
+            <ul id="mark-info" style="display: none">
+                <li>1</li>
+                <li>1</li>
+                <li>1</li>
+                <li>1</li>
+            </ul>
             <label>收款状态:</label>
             <form:select path="receiptStatus" class="select-ele input-medium">
                 <form:option value="" label="全部"/>
                 <form:options items="${fns:getDictList('discernReceiptStatus')}" itemLabel="label" itemValue="value"
                               htmlEscape="false"/>
             </form:select>
+
             <label>收款账号:</label>
             <form:select path="payType" class="select-ele input-medium">
                 <form:option value="" label="全部"/>