|
@@ -81,15 +81,22 @@
|
|
|
<option value="">产品</option>
|
|
|
<#if productColorList?? && (productColorList?size > 0) >
|
|
|
<#list productColorList as productColorInfo>
|
|
|
- <option value ="${productColorInfo.colorBar!""}">${productColorInfo.productName!""}</option>
|
|
|
+ <option value ="${productColorInfo.colorBar!""}">${productColorInfo.productName!""} - ${productColorInfo.colorName!""}(${productColorInfo.colorBar!""})</option>
|
|
|
</#list>
|
|
|
</#if>
|
|
|
</select>
|
|
|
</span>
|
|
|
+
|
|
|
+ </div>
|
|
|
+ <div class="formControls col-2 col-sm-2" >
|
|
|
+ <input id="colorBars" name="colorBars" type="text" class="input-text" placeholder="请选择产品">
|
|
|
+ </div>
|
|
|
+ <div class="formControls col-1 col-sm-1" >
|
|
|
+ <button type="button" class="btn btn-primary" style="background: #32a3d8;color: #fff;-webkit-transform:translateY(-5%);" onclick="seleteBar();" id="" name="">删除</button>
|
|
|
</div>
|
|
|
<div class="formControls col-3 col-sm-3" >
|
|
|
- <input type="text" style="width:120px;height:36px;margin-right: 0px;margin-bottom: 10px;" name="startTime" id="startTime" class="input-text" placeholder="开始时间" onClick="WdatePicker({startDate: '%y-01-01 00:00:00' ,dateFmt:'yyyy-MM-dd HH:mm:ss',alwaysUseStartDate: true })" value="${(customerInfo.startTime?string("yyyyy-MM-dd HH:mm:ss"))!''}" readonly="readonly"/>-
|
|
|
- <input type="text" style="width:120px;height:36px;margin-right: 0px;margin-bottom: 10px;" name="endTime" id="endTime" class="input-text" placeholder="结束时间" onClick="WdatePicker({startDate: '%y-01-01 00:00:00' ,dateFmt:'yyyy-MM-dd HH:mm:ss',alwaysUseStartDate: true })" value="${(customerInfo.endTime?string("yyyy-MM-dd HH:mm:ss"))!''}" readonly="readonly"/>
|
|
|
+ <input type="text" style="width:120px;height:36px;margin-right: 0px;margin-bottom: 10px;" name="startDate" id="startDate" class="input-text" placeholder="开始时间" onClick="WdatePicker({startDate: '%y-01-01 00:00:00' ,dateFmt:'yyyy-MM-dd HH:mm:ss',alwaysUseStartDate: true })" value="" readonly="readonly"/>-
|
|
|
+ <input type="text" style="width:120px;height:36px;margin-right: 0px;margin-bottom: 10px;" name="endDate" id="endDate" class="input-text" placeholder="结束时间" onClick="WdatePicker({startDate: '%y-01-01 00:00:00' ,dateFmt:'yyyy-MM-dd HH:mm:ss',alwaysUseStartDate: true })" value="" readonly="readonly"/>
|
|
|
</div>
|
|
|
<div class="formControls col-1 col-sm-1" >
|
|
|
<button type="button" class="btn btn-primary" style="background: #32a3d8;color: #fff;-webkit-transform:translateY(-5%);" onclick="statistical();" id="" name="">搜索</button>
|
|
@@ -147,20 +154,35 @@
|
|
|
statistical();
|
|
|
})
|
|
|
|
|
|
+ $("#itemColorBar").on("change",function () {
|
|
|
+ var selected=$(this).children('option:selected').val();
|
|
|
+ if($("#colorBars").val() == null || $("#colorBars").val() == ""){
|
|
|
+ $("#colorBars").val(selected);
|
|
|
+ }else{
|
|
|
+ $("#colorBars").val($("#colorBars").val()+","+selected);
|
|
|
+ }
|
|
|
+ });
|
|
|
+ function seleteBar() {
|
|
|
+ var strs= new Array();
|
|
|
+ var colorBars = $("#colorBars").val();
|
|
|
+ strs = colorBars.split(",");
|
|
|
+ strs.pop();
|
|
|
+ $("#colorBars").val(strs);
|
|
|
+ }
|
|
|
/**
|
|
|
* 搜索订单
|
|
|
*/
|
|
|
function statistical(){
|
|
|
var salesStoreId = convertUndefinedToEmpty($("#salesStoreId").val());
|
|
|
- var startTime = convertUndefinedToEmpty($("#startTime").val());
|
|
|
- var endTime = convertUndefinedToEmpty($("endTime").val());
|
|
|
- var itemColorBar = convertUndefinedToEmpty($("itemColorBar").val());
|
|
|
+ var startDate = convertUndefinedToEmpty($("#startDate").val());
|
|
|
+ var endDate = convertUndefinedToEmpty($("#endDate").val());
|
|
|
+ var itemColorBar = convertUndefinedToEmpty($("#colorBars").val());
|
|
|
$.ajax({
|
|
|
type: "POST",
|
|
|
data: {
|
|
|
salesStoreId : salesStoreId,
|
|
|
- startTime : startTime,
|
|
|
- endTime : endTime,
|
|
|
+ startDate : startDate,
|
|
|
+ endDate : endDate,
|
|
|
itemColorBar : itemColorBar
|
|
|
},
|
|
|
url: "${path}/admin/customer/return_statistics",
|
|
@@ -178,7 +200,7 @@
|
|
|
//总退换货率计算
|
|
|
/*alert(returnStatisticsInfo.totalSales+" "+returnStatisticsInfo.totalExchange+" "+returnStatisticsInfo.totalReturn+" "+returnStatisticsInfo.secondaryChangeNew+" "+returnStatisticsInfo.returnForSecond);*/
|
|
|
html += '<tr class="text-c">' +
|
|
|
- ' <td>'+ returnStatisticsInfo.months +'</td>' +
|
|
|
+ ' <td>'+ returnStatisticsInfo.months +'月</td>' +
|
|
|
' <td>'+ returnStatisticsInfo.totalSales +'</td>' +
|
|
|
' <td>'+ (Number(returnStatisticsInfo.totalSales)-(Number(returnStatisticsInfo.totalExchange) - Number(returnStatisticsInfo.totalReturn))) +'</td>' +
|
|
|
' <td>'+ toDecimal(Number((returnStatisticsInfo.totalExchange + returnStatisticsInfo.totalReturn))/Number(returnStatisticsInfo.totalSales)* 100) +'%</td>' +
|