|  |  | @ -8,7 +8,8 @@ import API from "../../api/index.js"; | 
			
		
	
		
			
				
					|  |  |  | import moment from "moment"; | 
			
		
	
		
			
				
					|  |  |  | import { range, re } from "mathjs"; | 
			
		
	
		
			
				
					|  |  |  | import * as xlsx from 'xlsx'; | 
			
		
	
		
			
				
					|  |  |  | import _ from 'lodash'; | 
			
		
	
		
			
				
					|  |  |  | import _, { before } from 'lodash'; | 
			
		
	
		
			
				
					|  |  |  | import { th } from "element-plus/es/locales.mjs"; | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | // 这是添加上传图片的接口 | 
			
		
	
		
			
				
					|  |  |  | const imageUrl = ref(""); | 
			
		
	
	
		
			
				
					|  |  | @ -281,6 +282,7 @@ const deleteRecharge = function () { | 
			
		
	
		
			
				
					|  |  |  | // 批量充值 | 
			
		
	
		
			
				
					|  |  |  | // jwcode列表 | 
			
		
	
		
			
				
					|  |  |  | const jwcodeList = ref([]); | 
			
		
	
		
			
				
					|  |  |  | let jwcodeSet; | 
			
		
	
		
			
				
					|  |  |  | // 获取jwcode列表 | 
			
		
	
		
			
				
					|  |  |  | const getJwcodeList = async function () { | 
			
		
	
		
			
				
					|  |  |  |   try { | 
			
		
	
	
		
			
				
					|  |  | @ -294,16 +296,34 @@ const getJwcodeList = async function () { | 
			
		
	
		
			
				
					|  |  |  |     console.log("请求成功", result); | 
			
		
	
		
			
				
					|  |  |  |     // 存储表格数据 | 
			
		
	
		
			
				
					|  |  |  |     jwcodeList.value = result.data; | 
			
		
	
		
			
				
					|  |  |  |     jwcodeList.value = jwcodeList.value.map((item) => ({ | 
			
		
	
		
			
				
					|  |  |  |       value: item, | 
			
		
	
		
			
				
					|  |  |  |       label: item, | 
			
		
	
		
			
				
					|  |  |  |     })); | 
			
		
	
		
			
				
					|  |  |  |     console.log("精网号", jwcodeList.value); | 
			
		
	
		
			
				
					|  |  |  |     // 将数组转换为set | 
			
		
	
		
			
				
					|  |  |  |     jwcodeSet = new Set(jwcodeList.value); | 
			
		
	
		
			
				
					|  |  |  |     console.log("精网号set", jwcodeSet); | 
			
		
	
		
			
				
					|  |  |  |   } catch (error) { | 
			
		
	
		
			
				
					|  |  |  |     console.log("请求失败", error); | 
			
		
	
		
			
				
					|  |  |  |     // 在这里可以处理错误逻辑,比如显示错误提示等 | 
			
		
	
		
			
				
					|  |  |  |   } | 
			
		
	
		
			
				
					|  |  |  | }; | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | // 校验精网号 | 
			
		
	
		
			
				
					|  |  |  | // 精网号错误对象 | 
			
		
	
		
			
				
					|  |  |  | const errorCount = ref(0); | 
			
		
	
		
			
				
					|  |  |  | // 校验规则 | 
			
		
	
		
			
				
					|  |  |  | const validateInput = function (row, index) { | 
			
		
	
		
			
				
					|  |  |  |   console.log(jwcodeSet.has(row.jwcode), "has"); | 
			
		
	
		
			
				
					|  |  |  |   if (!jwcodeSet.has(row.jwcode) && row.jwcode != '' && row.jwcode != null) { | 
			
		
	
		
			
				
					|  |  |  |     row.isInputInvalid = true; | 
			
		
	
		
			
				
					|  |  |  |     row.inputErrorMessage = '精网号不存在'; | 
			
		
	
		
			
				
					|  |  |  |     errorCount.value++; | 
			
		
	
		
			
				
					|  |  |  |     return; | 
			
		
	
		
			
				
					|  |  |  |   } else { | 
			
		
	
		
			
				
					|  |  |  |     row.isInputInvalid = false; | 
			
		
	
		
			
				
					|  |  |  |     row.inputErrorMessage = ''; | 
			
		
	
		
			
				
					|  |  |  |     errorCount.value--; | 
			
		
	
		
			
				
					|  |  |  |   } | 
			
		
	
		
			
				
					|  |  |  | } | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | // 批量充值弹窗 | 
			
		
	
		
			
				
					|  |  |  | const batchRechargeVisible = ref(false); | 
			
		
	
		
			
				
					|  |  |  | const jwcodeSelectRef = ref(null); | 
			
		
	
	
		
			
				
					|  |  | @ -316,6 +336,11 @@ const batchData = ref([ | 
			
		
	
		
			
				
					|  |  |  |   { | 
			
		
	
		
			
				
					|  |  |  |     line: 1, | 
			
		
	
		
			
				
					|  |  |  |     showInput: true, | 
			
		
	
		
			
				
					|  |  |  |     isInputInvalid: false, | 
			
		
	
		
			
				
					|  |  |  |     inputErrorMessage: '', | 
			
		
	
		
			
				
					|  |  |  |     freeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |     rechargeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |     paidGold: "0", | 
			
		
	
		
			
				
					|  |  |  |   }, | 
			
		
	
		
			
				
					|  |  |  | ]); | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
	
		
			
				
					|  |  | @ -332,52 +357,6 @@ const batchInit = function () { | 
			
		
	
		
			
				
					|  |  |  |   openBatchRechargeVisible(); | 
			
		
	
		
			
				
					|  |  |  | }; | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | // 提取添加滚动监听的逻辑到单独函数 | 
			
		
	
		
			
				
					|  |  |  | const addScrollListener = () => { | 
			
		
	
		
			
				
					|  |  |  |   const SELECTWRAP_DOM = document.querySelector( | 
			
		
	
		
			
				
					|  |  |  |     ".el-select-dropdown .el-select-dropdown__wrap" | 
			
		
	
		
			
				
					|  |  |  |   ); | 
			
		
	
		
			
				
					|  |  |  |   if (SELECTWRAP_DOM) { | 
			
		
	
		
			
				
					|  |  |  |     SELECTWRAP_DOM.addEventListener("scroll", function () { | 
			
		
	
		
			
				
					|  |  |  |       const condition = this.scrollHeight - this.scrollTop <= this.clientHeight; | 
			
		
	
		
			
				
					|  |  |  |       if (condition) binding.value(); | 
			
		
	
		
			
				
					|  |  |  |     }); | 
			
		
	
		
			
				
					|  |  |  |   } | 
			
		
	
		
			
				
					|  |  |  | }; | 
			
		
	
		
			
				
					|  |  |  | // 局部注册指令 | 
			
		
	
		
			
				
					|  |  |  | const vJwcodeLoadmore = { | 
			
		
	
		
			
				
					|  |  |  |   mounted(el, binding) { | 
			
		
	
		
			
				
					|  |  |  |     nextTick(() => { | 
			
		
	
		
			
				
					|  |  |  |       console.log("el===", el, "binding===", binding); | 
			
		
	
		
			
				
					|  |  |  |       const SELECTWRAP_DOM = el.querySelector( | 
			
		
	
		
			
				
					|  |  |  |         ".el-select-dropdown .el-select-dropdown__wrap" | 
			
		
	
		
			
				
					|  |  |  |       ); | 
			
		
	
		
			
				
					|  |  |  |       console.log("SELECTWRAP_DOM===", SELECTWRAP_DOM); | 
			
		
	
		
			
				
					|  |  |  |       if (SELECTWRAP_DOM) { | 
			
		
	
		
			
				
					|  |  |  |         SELECTWRAP_DOM.addEventListener("scroll", function () { | 
			
		
	
		
			
				
					|  |  |  |           /** | 
			
		
	
		
			
				
					|  |  |  |            * scrollHeight 获取元素内容高度(只读) | 
			
		
	
		
			
				
					|  |  |  |            * scrollTop 获取或者设置元素的偏移值, | 
			
		
	
		
			
				
					|  |  |  |            *  常用于:计算滚动条的位置, 当一个元素的容器没有产生垂直方向的滚动条, 那它的scrollTop的值默认为0. | 
			
		
	
		
			
				
					|  |  |  |            * clientHeight 读取元素的可见高度(只读) | 
			
		
	
		
			
				
					|  |  |  |            * 如果元素滚动到底, 下面等式返回true, 没有则返回false: | 
			
		
	
		
			
				
					|  |  |  |            * ele.scrollHeight - ele.scrollTop === ele.clientHeight; | 
			
		
	
		
			
				
					|  |  |  |            */ | 
			
		
	
		
			
				
					|  |  |  |           const condition = | 
			
		
	
		
			
				
					|  |  |  |             this.scrollHeight - this.scrollTop <= this.clientHeight; | 
			
		
	
		
			
				
					|  |  |  |           if (condition) binding.value(); | 
			
		
	
		
			
				
					|  |  |  |         }); | 
			
		
	
		
			
				
					|  |  |  |       } | 
			
		
	
		
			
				
					|  |  |  |     }); | 
			
		
	
		
			
				
					|  |  |  |   }, | 
			
		
	
		
			
				
					|  |  |  | }; | 
			
		
	
		
			
				
					|  |  |  | // 下拉框打开时调用添加滚动监听函数 | 
			
		
	
		
			
				
					|  |  |  | // const jwcodeSelectScrollerListener = () => { | 
			
		
	
		
			
				
					|  |  |  | //   console.log(jwcodeSelectRef.value, 'jwcodeSelectRef.value') | 
			
		
	
		
			
				
					|  |  |  | //   if (jwcodeSelectRef.value) { | 
			
		
	
		
			
				
					|  |  |  | //     directives.loadmore(jwcodeSelectRef.value, loadMore(rangeNumber.value)); | 
			
		
	
		
			
				
					|  |  |  | //   } | 
			
		
	
		
			
				
					|  |  |  | // }; | 
			
		
	
		
			
				
					|  |  |  | // 添加行数对象 | 
			
		
	
		
			
				
					|  |  |  | const addLineObj = ref(0); | 
			
		
	
		
			
				
					|  |  |  | //添加一行 | 
			
		
	
	
		
			
				
					|  |  | @ -385,6 +364,11 @@ const addLine = function () { | 
			
		
	
		
			
				
					|  |  |  |   batchData.value.unshift({ | 
			
		
	
		
			
				
					|  |  |  |     line: ++i.value, | 
			
		
	
		
			
				
					|  |  |  |     showInput: true, | 
			
		
	
		
			
				
					|  |  |  |     isInputInvalid: false, | 
			
		
	
		
			
				
					|  |  |  |     inputErrorMessage: '', | 
			
		
	
		
			
				
					|  |  |  |     freeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |     rechargeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |     paidGold: "0", | 
			
		
	
		
			
				
					|  |  |  |   }); | 
			
		
	
		
			
				
					|  |  |  | }; | 
			
		
	
		
			
				
					|  |  |  | const loading = ref(false); | 
			
		
	
	
		
			
				
					|  |  | @ -403,36 +387,34 @@ const loading = ref(false); | 
			
		
	
		
			
				
					|  |  |  | //     ElMessage.error("添加失败"); | 
			
		
	
		
			
				
					|  |  |  | //   } | 
			
		
	
		
			
				
					|  |  |  | // } | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | // 添加多行点击按钮 | 
			
		
	
		
			
				
					|  |  |  | const addLines = async function () { | 
			
		
	
		
			
				
					|  |  |  |   try { | 
			
		
	
		
			
				
					|  |  |  |     loading.value = true; // 操作开始前,将loading设为true,显示加载动画 | 
			
		
	
		
			
				
					|  |  |  |     await nextTick(); // 等待视图更新,确保加载动画能及时显示出来 | 
			
		
	
		
			
				
					|  |  |  |     // loading.value = true; // 操作开始前,将loading设为true,显示加载动画 | 
			
		
	
		
			
				
					|  |  |  |     // console.log(loading.value, "loading.value"); | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  |     const addLinesPromises = []; | 
			
		
	
		
			
				
					|  |  |  |     for (let j = 0; j < addLineObj.value; j++) { | 
			
		
	
		
			
				
					|  |  |  |       addLinesPromises.push( | 
			
		
	
		
			
				
					|  |  |  |         new Promise((resolve) => { | 
			
		
	
		
			
				
					|  |  |  |           batchData.value.unshift({ | 
			
		
	
		
			
				
					|  |  |  |     const newItems = Array.from({ length: addLineObj.value }, (_, index) => reactive({ | 
			
		
	
		
			
				
					|  |  |  |       line: ++i.value, | 
			
		
	
		
			
				
					|  |  |  |       showInput: true, | 
			
		
	
		
			
				
					|  |  |  |           }); | 
			
		
	
		
			
				
					|  |  |  |           resolve(); | 
			
		
	
		
			
				
					|  |  |  |         }) | 
			
		
	
		
			
				
					|  |  |  |       ); | 
			
		
	
		
			
				
					|  |  |  |     } | 
			
		
	
		
			
				
					|  |  |  |     await Promise.all(addLinesPromises); | 
			
		
	
		
			
				
					|  |  |  |       isInputInvalid: false, | 
			
		
	
		
			
				
					|  |  |  |       inputErrorMessage: '', | 
			
		
	
		
			
				
					|  |  |  |       freeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |       rechargeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |       paidGold: "0", | 
			
		
	
		
			
				
					|  |  |  |     })); | 
			
		
	
		
			
				
					|  |  |  |     batchData.value = [...newItems, ...batchData.value]; | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  |     // 所有数据添加操作完成后,准备关闭加载动画 | 
			
		
	
		
			
				
					|  |  |  |     await nextTick(); // 再次等待视图更新,确保数据添加操作引起的视图变化已完成 | 
			
		
	
		
			
				
					|  |  |  |     loading.value = false; // 将loading设为false,关闭加载动画 | 
			
		
	
		
			
				
					|  |  |  |     ElMessage.success("添加成功"); | 
			
		
	
		
			
				
					|  |  |  |     // loading.value = false; // 将loading设为false,关闭加载动画 | 
			
		
	
		
			
				
					|  |  |  |   } catch (error) { | 
			
		
	
		
			
				
					|  |  |  |     console.log("添加失败", error); | 
			
		
	
		
			
				
					|  |  |  |     ElMessage.error("添加失败"); | 
			
		
	
		
			
				
					|  |  |  |     // 如果出现异常,也要确保关闭加载动画 | 
			
		
	
		
			
				
					|  |  |  |     loading.value = false; | 
			
		
	
		
			
				
					|  |  |  |     // loading.value = false; | 
			
		
	
		
			
				
					|  |  |  |   } | 
			
		
	
		
			
				
					|  |  |  | }; | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | // 导入excel按钮的ref | 
			
		
	
		
			
				
					|  |  |  | const uploadRefMap = ref({}); | 
			
		
	
		
			
				
					|  |  |  | // 获取excel数据 | 
			
		
	
	
		
			
				
					|  |  | @ -634,6 +616,7 @@ const handleBatchAvatarSuccess = (response, uploadFile) => { | 
			
		
	
		
			
				
					|  |  |  | }; | 
			
		
	
		
			
				
					|  |  |  | //批量充值确认按钮 | 
			
		
	
		
			
				
					|  |  |  | const batchAdd = async function () { | 
			
		
	
		
			
				
					|  |  |  |   try { | 
			
		
	
		
			
				
					|  |  |  |     console.log("batchData===", batchData.value); | 
			
		
	
		
			
				
					|  |  |  |     let msg = ''; | 
			
		
	
		
			
				
					|  |  |  |     if (batchData.value.length == 0) { | 
			
		
	
	
		
			
				
					|  |  | @ -643,6 +626,14 @@ const batchAdd = async function () { | 
			
		
	
		
			
				
					|  |  |  |       }); | 
			
		
	
		
			
				
					|  |  |  |       return; | 
			
		
	
		
			
				
					|  |  |  |     } | 
			
		
	
		
			
				
					|  |  |  |     if (errorCount.value > 0) { | 
			
		
	
		
			
				
					|  |  |  |       console.log("errorCount.value", errorCount.value); | 
			
		
	
		
			
				
					|  |  |  |       ElMessage({ | 
			
		
	
		
			
				
					|  |  |  |         type: "error", | 
			
		
	
		
			
				
					|  |  |  |         message: "请检查输入的精网号是否正确!", | 
			
		
	
		
			
				
					|  |  |  |       }); | 
			
		
	
		
			
				
					|  |  |  |       return; | 
			
		
	
		
			
				
					|  |  |  |     } | 
			
		
	
		
			
				
					|  |  |  |     for (let i = 0; i < batchData.value.length; i++) { | 
			
		
	
		
			
				
					|  |  |  |       batchData.value[i].adminId = adminData.value.adminId; | 
			
		
	
		
			
				
					|  |  |  |       batchData.value[i].area = adminData.value.area; | 
			
		
	
	
		
			
				
					|  |  | @ -663,6 +654,11 @@ const batchAdd = async function () { | 
			
		
	
		
			
				
					|  |  |  |         msg += `充值金币不能为空! <br/>`; | 
			
		
	
		
			
				
					|  |  |  |       } | 
			
		
	
		
			
				
					|  |  |  |       if ( | 
			
		
	
		
			
				
					|  |  |  |         batchData.value[i].freeGold == "" || | 
			
		
	
		
			
				
					|  |  |  |         batchData.value[i].freeGold == null) { | 
			
		
	
		
			
				
					|  |  |  |         msg += `免费金币不能为空! <br/>`; | 
			
		
	
		
			
				
					|  |  |  |       } | 
			
		
	
		
			
				
					|  |  |  |       if ( | 
			
		
	
		
			
				
					|  |  |  |         batchData.value[i].rechargeGold == "" || | 
			
		
	
		
			
				
					|  |  |  |         batchData.value[i].rechargeGold == null) { | 
			
		
	
		
			
				
					|  |  |  |         msg += `充值金额不能为空! <br/>`; | 
			
		
	
	
		
			
				
					|  |  | @ -677,6 +673,8 @@ const batchAdd = async function () { | 
			
		
	
		
			
				
					|  |  |  |         batchData.value[i].rechargeTime == null) { | 
			
		
	
		
			
				
					|  |  |  |         msg += `交款时间不能为空! <br/>`; | 
			
		
	
		
			
				
					|  |  |  |       } | 
			
		
	
		
			
				
					|  |  |  |       if (msg != '' && msg != null) { | 
			
		
	
		
			
				
					|  |  |  |         console.log(batchData.value[i]); | 
			
		
	
		
			
				
					|  |  |  |         ElMessage({ | 
			
		
	
		
			
				
					|  |  |  |           dangerouslyUseHTMLString: true, | 
			
		
	
		
			
				
					|  |  |  |           type: "error", | 
			
		
	
	
		
			
				
					|  |  | @ -684,7 +682,8 @@ const batchAdd = async function () { | 
			
		
	
		
			
				
					|  |  |  |         }); | 
			
		
	
		
			
				
					|  |  |  |         return; | 
			
		
	
		
			
				
					|  |  |  |       } | 
			
		
	
		
			
				
					|  |  |  |   console.log("batchData===", batchData.value); | 
			
		
	
		
			
				
					|  |  |  |     } | 
			
		
	
		
			
				
					|  |  |  |     console.log("batchData::", batchData.value); | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  |     const result = await API.post( | 
			
		
	
		
			
				
					|  |  |  |       "http://192.168.8.93:10010/recharge/recharge/addmore", | 
			
		
	
	
		
			
				
					|  |  | @ -702,11 +701,20 @@ const batchAdd = async function () { | 
			
		
	
		
			
				
					|  |  |  |     }); | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  |     closeBatchRechargeVisible(); | 
			
		
	
		
			
				
					|  |  |  |   } catch (error) { | 
			
		
	
		
			
				
					|  |  |  |     console.log("error===", error); | 
			
		
	
		
			
				
					|  |  |  |     ElMessage.error("添加失败"); | 
			
		
	
		
			
				
					|  |  |  |     return; | 
			
		
	
		
			
				
					|  |  |  |   }; | 
			
		
	
		
			
				
					|  |  |  | } | 
			
		
	
		
			
				
					|  |  |  | // 使用 _.throttle 并设置 trailing 为 false 实现严格节流,只执行一次 | 
			
		
	
		
			
				
					|  |  |  | const throttledBatchAdd = _.throttle(batchAdd, 5000, { trailing: false }); | 
			
		
	
		
			
				
					|  |  |  | const throttledBatchAdd = _.throttle(batchAdd, 2000, { trailing: false }); | 
			
		
	
		
			
				
					|  |  |  | // 批量设置的对象 | 
			
		
	
		
			
				
					|  |  |  | const batchSettingObj = ref({}); | 
			
		
	
		
			
				
					|  |  |  | const batchSettingObj = ref({ | 
			
		
	
		
			
				
					|  |  |  |   rechargeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |   paidGold: "0", | 
			
		
	
		
			
				
					|  |  |  |   freeGold: "0", | 
			
		
	
		
			
				
					|  |  |  | }); | 
			
		
	
		
			
				
					|  |  |  | // 批量充值弹窗 | 
			
		
	
		
			
				
					|  |  |  | const batchSettingVisible = ref(false); | 
			
		
	
		
			
				
					|  |  |  | // 打开批量充值弹窗 | 
			
		
	
	
		
			
				
					|  |  | @ -730,7 +738,11 @@ const batchSettingHandleAvatarSuccess = (response, uploadFile) => { | 
			
		
	
		
			
				
					|  |  |  | }; | 
			
		
	
		
			
				
					|  |  |  | // 批量设置取消按钮 | 
			
		
	
		
			
				
					|  |  |  | const cancelBatchSetting = function () { | 
			
		
	
		
			
				
					|  |  |  |   batchSettingObj.value = {}; | 
			
		
	
		
			
				
					|  |  |  |   batchSettingObj.value = { | 
			
		
	
		
			
				
					|  |  |  |     rechargeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |     paidGold: "0", | 
			
		
	
		
			
				
					|  |  |  |     freeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |   }; | 
			
		
	
		
			
				
					|  |  |  |   closeBatchSettingVisible(); | 
			
		
	
		
			
				
					|  |  |  | }; | 
			
		
	
		
			
				
					|  |  |  | // 批量设置确认按钮 | 
			
		
	
	
		
			
				
					|  |  | @ -804,7 +816,11 @@ const batchSettingConfirm = function () { | 
			
		
	
		
			
				
					|  |  |  |       batchData.value[i].remark = batchSettingObj.value.remark; | 
			
		
	
		
			
				
					|  |  |  |     } | 
			
		
	
		
			
				
					|  |  |  |   } | 
			
		
	
		
			
				
					|  |  |  |   batchSettingObj.value = {}; | 
			
		
	
		
			
				
					|  |  |  |   batchSettingObj.value = { | 
			
		
	
		
			
				
					|  |  |  |     rechargeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |     paidGold: "0", | 
			
		
	
		
			
				
					|  |  |  |     freeGold: "0", | 
			
		
	
		
			
				
					|  |  |  |   }; | 
			
		
	
		
			
				
					|  |  |  |   closeBatchSettingVisible(); | 
			
		
	
		
			
				
					|  |  |  | }; | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
	
		
			
				
					|  |  | @ -949,9 +965,9 @@ onMounted(async function () { | 
			
		
	
		
			
				
					|  |  |  |       <!-- <el-button type="primary" @click="addLine()" style="margin-right: 10px">新增一行</el-button> --> | 
			
		
	
		
			
				
					|  |  |  |       <div style="font-weight: bold; font-size: 20px"> | 
			
		
	
		
			
				
					|  |  |  |         <span>添加</span> | 
			
		
	
		
			
				
					|  |  |  |         <el-input style="width: 60px" v-model="addLineObj"></el-input> | 
			
		
	
		
			
				
					|  |  |  |         <el-input-number min="1" style="width: 100px;" controls-position="right" v-model="addLineObj"></el-input-number> | 
			
		
	
		
			
				
					|  |  |  |         <span>行</span> | 
			
		
	
		
			
				
					|  |  |  |         <el-button type="primary" @click="addLines()" style="margin-right: 10px">添加</el-button> | 
			
		
	
		
			
				
					|  |  |  |         <el-button type="primary" @click="addLines" style="margin-right: 10px">添加</el-button> | 
			
		
	
		
			
				
					|  |  |  |       </div> | 
			
		
	
		
			
				
					|  |  |  |       <el-button type="warning" @click="batchSettingInit()" style="margin-right: 10px">批量设置</el-button> | 
			
		
	
		
			
				
					|  |  |  |       <!-- <el-upload :ref="(el) => handleSetUploadRefMap(el)" action="" :http-request="httpExcelRequest" :limit="1" :show-file-list="false" | 
			
		
	
	
		
			
				
					|  |  | @ -961,7 +977,7 @@ onMounted(async function () { | 
			
		
	
		
			
				
					|  |  |  |       <el-button type="danger" plain @click="batchDel()" style="margin-right: 10px; width: 130px">批量删除</el-button> | 
			
		
	
		
			
				
					|  |  |  |     </el-row> | 
			
		
	
		
			
				
					|  |  |  |     <el-row> | 
			
		
	
		
			
				
					|  |  |  |       <el-table v-loading="loading" :data="batchData" border max-height="540px" style="height: 540px" | 
			
		
	
		
			
				
					|  |  |  |       <el-table :data="batchData" border max-height="540px" style="height: 540px" | 
			
		
	
		
			
				
					|  |  |  |         @selection-change="handleSelectionChangebatch"> | 
			
		
	
		
			
				
					|  |  |  |         <el-table-column type="selection" width="50px" /> | 
			
		
	
		
			
				
					|  |  |  |         <el-table-column property="index" label="序号" width="55px"> | 
			
		
	
	
		
			
				
					|  |  | @ -970,16 +986,18 @@ onMounted(async function () { | 
			
		
	
		
			
				
					|  |  |  |           </template> | 
			
		
	
		
			
				
					|  |  |  |         </el-table-column> | 
			
		
	
		
			
				
					|  |  |  |         <el-table-column property="jwcode" label="精网号" width="150px"> | 
			
		
	
		
			
				
					|  |  |  |           <!-- <template #default="scope"> | 
			
		
	
		
			
				
					|  |  |  |             <el-input v-if="scope.row.showInput" v-model="scope.row.jwcode" style="width: 110px" /> | 
			
		
	
		
			
				
					|  |  |  |             <span v-else>{{ scope.row.jwcode }}</span> | 
			
		
	
		
			
				
					|  |  |  |           </template> --> | 
			
		
	
		
			
				
					|  |  |  |           <template #default="scope"> | 
			
		
	
		
			
				
					|  |  |  |             <el-input v-if="scope.row.showInput" :class="{ 'is-invalid': scope.row.isInputInvalid }" | 
			
		
	
		
			
				
					|  |  |  |               @blur="validateInput(scope.row)" v-model="scope.row.jwcode" style="width: 110px" /> | 
			
		
	
		
			
				
					|  |  |  |             <p v-if="scope.row.isInputInvalid" class="error-message">{{ | 
			
		
	
		
			
				
					|  |  |  |               scope.row.inputErrorMessage }}</p> | 
			
		
	
		
			
				
					|  |  |  |           </template> | 
			
		
	
		
			
				
					|  |  |  |           <!-- <template #default="scope"> | 
			
		
	
		
			
				
					|  |  |  |             <el-select-v2 v-if="scope.row.showInput" filterable clearable v-model="scope.row.jwcode" | 
			
		
	
		
			
				
					|  |  |  |               placeholder="请选择精网号" style="widows: 110px;" :options="jwcodeList"> | 
			
		
	
		
			
				
					|  |  |  |             </el-select-v2> | 
			
		
	
		
			
				
					|  |  |  |             <span v-else>{{ scope.row.jwcode }}</span> | 
			
		
	
		
			
				
					|  |  |  |           </template> | 
			
		
	
		
			
				
					|  |  |  |           </template> --> | 
			
		
	
		
			
				
					|  |  |  |         </el-table-column> | 
			
		
	
		
			
				
					|  |  |  |         <el-table-column property="activityName" label="活动名称" width="150px"> | 
			
		
	
		
			
				
					|  |  |  |           <template #default="scope"> | 
			
		
	
	
		
			
				
					|  |  | @ -1002,7 +1020,7 @@ onMounted(async function () { | 
			
		
	
		
			
				
					|  |  |  |         <el-table-column property="freeGold" label="免费金币" width="110px"> | 
			
		
	
		
			
				
					|  |  |  |           <template #default="scope"> | 
			
		
	
		
			
				
					|  |  |  |             <el-input v-if="scope.row.showInput" v-model="scope.row.freeGold" style="width: 70px" /> | 
			
		
	
		
			
				
					|  |  |  |             <span v-else>{{ scope.row.paidGold }}</span> | 
			
		
	
		
			
				
					|  |  |  |             <span v-else>{{ scope.row.freeGold }}</span> | 
			
		
	
		
			
				
					|  |  |  |           </template> | 
			
		
	
		
			
				
					|  |  |  |         </el-table-column> | 
			
		
	
		
			
				
					|  |  |  |         <el-table-column property="rate" label="货币名称"> | 
			
		
	
	
		
			
				
					|  |  | @ -1180,6 +1198,15 @@ p { | 
			
		
	
		
			
				
					|  |  |  | </style> | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | <style> | 
			
		
	
		
			
				
					|  |  |  | .error-message { | 
			
		
	
		
			
				
					|  |  |  |   color: red; | 
			
		
	
		
			
				
					|  |  |  |   font-size: 12px; | 
			
		
	
		
			
				
					|  |  |  | } | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | .is-invalid .el-input__inner { | 
			
		
	
		
			
				
					|  |  |  |   border-color: red; | 
			
		
	
		
			
				
					|  |  |  | } | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | .avatar-uploader .el-upload { | 
			
		
	
		
			
				
					|  |  |  |   border: 1px dashed var(--el-border-color); | 
			
		
	
		
			
				
					|  |  |  |   border-radius: 6px; | 
			
		
	
	
		
			
				
					|  |  | 
 |