| | |
| | | $("#storeSelect").hide(); |
| | | $("#citySelect").hide(); |
| | | |
| | | num = 0; |
| | | //移除指定门店的数据: |
| | | // 找到 tbody 元素 |
| | | var tbody = document.getElementById("coun"); |
| | | |
| | | // 移除所有子元素(即行) |
| | | while (tbody.firstChild) { |
| | | tbody.removeChild(tbody.firstChild); |
| | | } |
| | | couponInfoDlg.storeIds = []; |
| | | |
| | | //移除指城市的数据: |
| | | num = 0; |
| | | var cityDemoDiv = document.getElementById("cityDemo"); |
| | | |
| | | cityDemoDiv.innerHTML = ""; // 将内容置为空字符串 |
| | | var provinceSelect = document.getElementById("provinceData"); |
| | | var cityDataSelect = document.getElementById("cityData"); |
| | | provinceSelect.innerHTML = '<option value="">请选择</option>'; |
| | | cityDataSelect.innerHTML = '<option value="">请选择</option>'; |
| | | getProvince(null); |
| | | } |
| | | /** |
| | | * 指定城市 |
| | |
| | | function scopeOfApplication2() { |
| | | $("#storeSelect").hide(); |
| | | $("#citySelect").show(); |
| | | |
| | | //移除指定门店的数据: |
| | | // 找到 tbody 元素 |
| | | var tbody = document.getElementById("coun"); |
| | | // 移除所有子元素(即行) |
| | | while (tbody.firstChild) { |
| | | tbody.removeChild(tbody.firstChild); |
| | | } |
| | | couponInfoDlg.storeIds = []; |
| | | |
| | | |
| | | |
| | | } |
| | | /** |
| | | * 指定门店 |
| | |
| | | function scopeOfApplication3() { |
| | | $("#storeSelect").show(); |
| | | $("#citySelect").hide(); |
| | | |
| | | //移除指城市的数据: |
| | | num = 0; |
| | | var cityDemoDiv = document.getElementById("cityDemo"); |
| | | |
| | | cityDemoDiv.innerHTML = ""; // 将内容置为空字符串 |
| | | var provinceSelect = document.getElementById("provinceData"); |
| | | var cityDataSelect = document.getElementById("cityData"); |
| | | provinceSelect.innerHTML = '<option value="">请选择</option>'; |
| | | cityDataSelect.innerHTML = '<option value="">请选择</option>'; |
| | | getProvince(null); |
| | | |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | } |
| | | // 兑换方式 |
| | | let exchangeMethod = $(':radio[name="exchangeMethod"]:checked').val(); |
| | | if (distributionMethod === '' || distributionMethod === undefined || distributionMethod === null){ |
| | | if (exchangeMethod === '' || exchangeMethod === undefined || exchangeMethod === null){ |
| | | return Feng.error('兑换方式不能为空'); |
| | | } |
| | | if (distributionMethod === '1'){ |
| | | if (exchangeMethod === '1'){ |
| | | if (requiredPoints === undefined || requiredPoints === '' || requiredPoints === null){ |
| | | return Feng.error('所需积分不能为空'); |
| | | } |
| | | } |
| | | if (distributionMethod === '2'){ |
| | | if (exchangeMethod === '2'){ |
| | | if (requiredPoints === undefined || requiredPoints === '' || requiredPoints === null){ |
| | | return Feng.error('所需积分不能为空'); |
| | | } |
| | |
| | | return Feng.error('所需现金不能为空'); |
| | | } |
| | | } |
| | | if (distributionMethod === '3'){ |
| | | if (exchangeMethod === '3'){ |
| | | if (requiredCash === undefined || requiredCash === '' || requiredCash === null){ |
| | | return Feng.error('所需现金不能为空'); |
| | | } |