Selaa lähdekoodia

合同查询金额区间

[user3] 4 vuotta sitten
vanhempi
commit
44cf16bb33

+ 5 - 2
src/main/resources/mappings/modules/workcontractinfo/WorkContractInfoDao.xml

@@ -296,9 +296,12 @@
 			<if test="beginInvestmentAmount != null and endInvestmentAmount != null and beginInvestmentAmount != '' and endInvestmentAmount != ''">
 				AND a.investment_amount &gt;= #{beginInvestmentAmount} AND a.investment_amount &lt;= #{endInvestmentAmount}
 			</if>
-			<if test="contractPrice != '' and contractPrice != null">
-				AND a.contract_price like concat('%',#{contractPrice},'%')
+			<if test="beginContractPrice != null and endContractPrice != null and beginContractPrice != '' and endContractPrice != ''">
+				AND a.contract_price &gt;= #{beginContractPrice} AND a.contract_price &lt;= #{endContractPrice}
 			</if>
+<!--			<if test="contractPrice != '' and contractPrice != null">-->
+<!--				AND a.contract_price like concat('%',#{contractPrice},'%')-->
+<!--			</if>-->
 			<if test="contractState != null and contractState != ''">
 				AND a.contract_state = #{contractState}
 			</if>

+ 6 - 2
src/main/webapp/webpage/modules/workcontractinfo/workContractInfoList.jsp

@@ -605,8 +605,12 @@
 					</div>
 					<div class="layui-item query athird">
 						<label class="layui-form-label  double-line">合同金额(元):</label>
-						<div class="layui-input-block with-icon">
-							<form:input path="contractPrice" htmlEscape="false" maxlength="255"  class=" form-control layui-input"/>
+						<div class="layui-input-block">
+							<input id="beginContractPrice" name="beginContractPrice" type="text" value="${workContractInfo.beginContractPrice}" maxlength="20" class="form-control layui-input query-group"/>
+							</input>
+							<span class="group-sep">-</span>
+							<input id="endContractPrice" name="endContractPrice" type="text" value="${workContractInfo.endContractPrice}"  maxlength="20" class="form-control layui-input query-group"/>
+							</input>
 						</div>
 					</div>
 				</div>