|
|
@ -110,7 +110,7 @@ |
|
|
|
中奖数 |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
{{ zhongjiangshuTotal }} |
|
|
|
{{ zhongjiangshucount }} |
|
|
|
</el-descriptions-item> |
|
|
|
<el-descriptions-item> |
|
|
|
<template #label> |
|
|
@ -262,6 +262,7 @@ export default { |
|
|
|
selectChangci: {}, |
|
|
|
dataObj: {}, |
|
|
|
zhongjiangshu: {}, |
|
|
|
zhongjiangshucount: 0, |
|
|
|
zhongjiangshuTotal: 0, |
|
|
|
tongjiValue: 0, |
|
|
|
tableHeight: 500, |
|
|
@ -270,6 +271,30 @@ export default { |
|
|
|
visible: false, |
|
|
|
fuwufeiValue: 0, |
|
|
|
}, |
|
|
|
form: {}, |
|
|
|
formLocal: { |
|
|
|
caipiaotype: "1", |
|
|
|
danxuan: 900, |
|
|
|
zuxuan: 150, |
|
|
|
shuangfei: 15, |
|
|
|
dudan: 3.3, |
|
|
|
dingwei1: 9, |
|
|
|
dingwei2: 80, |
|
|
|
budingwei: 0, |
|
|
|
fushi: 150, |
|
|
|
quanbaoduizi: 3.3, |
|
|
|
zuliu4: 35, |
|
|
|
zuliu5: 15, |
|
|
|
zuliu6: 7, |
|
|
|
zuliu7: 4, |
|
|
|
zusan4: 24, |
|
|
|
zusan5: 15, |
|
|
|
zusan6: 8, |
|
|
|
zusan7: 6, |
|
|
|
// bai: 0, |
|
|
|
// shi: 0, |
|
|
|
// ge: 0 |
|
|
|
}, |
|
|
|
screenshotStatus: false, |
|
|
|
yidanyizu: /一单一组[:|:]*([\d,.\s]+)(?=合计|共*)/, |
|
|
|
yizuliu: /1组六[:|:]*([\d,.\s]+)(?=合计|共*)/, |
|
|
@ -566,6 +591,12 @@ export default { |
|
|
|
ElMessage.error("请填写内容后预测") |
|
|
|
return |
|
|
|
} |
|
|
|
let formData = JSON.parse(localStorage.getItem('peifu') || "{}") |
|
|
|
if (_.isEmpty(formData)) { |
|
|
|
formData = this.formLocal |
|
|
|
} else { |
|
|
|
formData = { ...this.formLocal, ...formData } |
|
|
|
} |
|
|
|
let haomaList = [] |
|
|
|
// 按照换行符分割 |
|
|
|
let leftTextArr = this.leftText.split("\n") |
|
|
@ -584,15 +615,12 @@ export default { |
|
|
|
// yidan: /1单[:|:]*([\d,.\s]+)(?=合计|共*)/, |
|
|
|
// yizu: /1组[:|:]*([\d,.\s]+)(?=合计|共*)/, |
|
|
|
// jine: /(?:合计|共)(\d+)/g |
|
|
|
console.log(77711, leftTextArr) |
|
|
|
|
|
|
|
for (let i = 0; i < leftTextArr.length; i++) { |
|
|
|
let item = leftTextArr[i]; |
|
|
|
let type = "体彩" |
|
|
|
if (item.includes("福彩")) { |
|
|
|
type = "福彩" |
|
|
|
} |
|
|
|
console.log(77722, item) |
|
|
|
let jine = item.match(this.jine) |
|
|
|
if (jine) { |
|
|
|
jine = Number(jine[1]) |
|
|
@ -867,7 +895,6 @@ export default { |
|
|
|
}) |
|
|
|
} |
|
|
|
//alljine= [{"key":"danxuan","name":"体彩:1单","data":[{"type":"danxuan","value":["684"],"jine":2},{"type":"danxuan","value":["784"],"jine":2},{"type":"danxuan","value":["876"],"jine":2},{"type":"danxuan","value":["784"],"jine":6}]},{"key":"zuxuan","name":"体彩:1组","data":[{"type":"zuxuan","value":["684"],"jine":2},{"type":"zuxuan","value":["784"],"jine":2},{"type":"zuxuan","value":["876"],"jine":2},{"type":"zuxuan","value":["214"],"jine":4}]},{"key":"zuliu4","name":"体彩:1组六4码","data":[{"type":"zuliu4","numbers":["1269"],"jine":10}]},{"key":"zuliu5","name":"体彩:1组六5码","data":[{"type":"zuliu5","numbers":["12069"],"jine":10}]},{"key":"zuliu6","name":"体彩:1组六6码","data":[{"type":"zuliu6","numbers":["120769"],"jine":10}]},{"key":"zusan3","name":"体彩:1组三3码","data":[{"type":"zusan3","numbers":["874"],"jine":10}]},{"key":"shuangfei","name":"体彩:1双飞","data":[{"type":"shuangfei","value":["98"],"jine":10}]},{"key":"dingwei","name":"体彩:1定位","data":[{"type":"dingwei","value":["324"],"jine":10}]}] |
|
|
|
console.log(777, haomaList, alljine, JSON.stringify(alljine)) |
|
|
|
let alljineLocal = {} |
|
|
|
for (let i = 0; i < alljine.length; i++) { |
|
|
|
let element = alljine[i] |
|
|
@ -883,7 +910,7 @@ export default { |
|
|
|
for (let k = 0; k < item.value.length; k++) { |
|
|
|
let xiangmu = `${item.value[k]}`; |
|
|
|
if (xiangmu === zhonghaoma) { |
|
|
|
dataObj.zhong += Number(item.jine) * 900 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -903,7 +930,7 @@ export default { |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
if (_.difference(zhonghaomaArr, xiangmuArr).length === 0) { |
|
|
|
dataObj.zhong += Number(item.jine) * 150 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -923,7 +950,7 @@ export default { |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
if (_.difference(zhonghaomaArr, xiangmuArr).length === 0) { |
|
|
|
dataObj.zhong += Number(item.jine) * 35 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -943,7 +970,7 @@ export default { |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
if (_.difference(zhonghaomaArr, xiangmuArr).length === 0) { |
|
|
|
dataObj.zhong += Number(item.jine) * 15 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -963,7 +990,7 @@ export default { |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
if (_.difference(zhonghaomaArr, xiangmuArr).length === 0) { |
|
|
|
dataObj.zhong += Number(item.jine) * 7 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -983,7 +1010,7 @@ export default { |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
if (_.difference(zhonghaomaArr, xiangmuArr).length === 0) { |
|
|
|
dataObj.zhong += Number(item.jine) * 4 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -1003,7 +1030,7 @@ export default { |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
if (_.difference(zhonghaomaArr, xiangmuArr).length <= 1) { |
|
|
|
dataObj.zhong += Number(item.jine) * 24 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -1023,7 +1050,7 @@ export default { |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
if (_.difference(zhonghaomaArr, xiangmuArr).length <= 1) { |
|
|
|
dataObj.zhong += Number(item.jine) * 15 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -1043,7 +1070,7 @@ export default { |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
if (_.difference(zhonghaomaArr, xiangmuArr).length <= 1) { |
|
|
|
dataObj.zhong += Number(item.jine) * 8 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -1063,7 +1090,7 @@ export default { |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
if (_.difference(zhonghaomaArr, xiangmuArr).length <= 1) { |
|
|
|
dataObj.zhong += Number(item.jine) * 6 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -1083,7 +1110,7 @@ export default { |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
if (_.difference(zhonghaomaArr, xiangmuArr).length === 2) { |
|
|
|
dataObj.zhong += Number(item.jine) * 3.3 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -1109,16 +1136,42 @@ export default { |
|
|
|
} |
|
|
|
} |
|
|
|
if (count === 1) { |
|
|
|
dataObj.zhong += Number(item.jine) * 9 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[`${element.key}1`]) |
|
|
|
} else if (count > 1) { |
|
|
|
dataObj.zhong += Number(item.jine) * 80 |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[`${element.key}2`]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
alljineLocal[element.key] = dataObj |
|
|
|
} |
|
|
|
// 处理不定位的玩法 |
|
|
|
else if (element.key == 'budingwei') { |
|
|
|
// else if (element.key == 'budingwei') { |
|
|
|
// let dataObj = { |
|
|
|
// all: 0, |
|
|
|
// zhong: 0 |
|
|
|
// } |
|
|
|
// for (let j = 0; j < element.data.length; j++) { |
|
|
|
// let item = element.data[j]; |
|
|
|
// dataObj.all += Number(item.jine) |
|
|
|
// for (let k = 0; k < item.value.length; k++) { |
|
|
|
// let xiangmu = `${item.value[k]}`; |
|
|
|
// let xiangmuArr = xiangmu.split(''); |
|
|
|
// let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
// let count = 0 |
|
|
|
// for (let l = 0; l < zhonghaomaArr.length; l++) { |
|
|
|
// if (xiangmuArr.includes(zhonghaomaArr[l])) { |
|
|
|
// count++ |
|
|
|
// } |
|
|
|
// } |
|
|
|
// if (count >= 1) { |
|
|
|
// dataObj.zhong += Number(item.jine) * 9 |
|
|
|
// } |
|
|
|
// } |
|
|
|
// } |
|
|
|
// alljineLocal[element.key] = dataObj |
|
|
|
// } |
|
|
|
// 处理双飞的玩法 |
|
|
|
else if (element.key == 'shuangfei') { |
|
|
|
let dataObj = { |
|
|
|
all: 0, |
|
|
|
zhong: 0 |
|
|
@ -1136,15 +1189,15 @@ export default { |
|
|
|
count++ |
|
|
|
} |
|
|
|
} |
|
|
|
if (count >= 1) { |
|
|
|
dataObj.zhong += Number(item.jine) * 9 |
|
|
|
if (count >= 2) { |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
alljineLocal[element.key] = dataObj |
|
|
|
} |
|
|
|
// 处理双飞的玩法 |
|
|
|
else if (element.key == 'shuangfei') { |
|
|
|
// 处理复式的玩法 |
|
|
|
else if (element.key == 'fushi') { |
|
|
|
let dataObj = { |
|
|
|
all: 0, |
|
|
|
zhong: 0 |
|
|
@ -1162,15 +1215,15 @@ export default { |
|
|
|
count++ |
|
|
|
} |
|
|
|
} |
|
|
|
if (count >= 2) { |
|
|
|
dataObj.zhong += Number(item.jine) * 15 |
|
|
|
if (count >= 3) { |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
alljineLocal[element.key] = dataObj |
|
|
|
} |
|
|
|
// 处理复式的玩法 |
|
|
|
else if (element.key == 'fushi') { |
|
|
|
// 处理全包对子的玩法 |
|
|
|
else if (element.key == 'quanbaoduizi') { |
|
|
|
let dataObj = { |
|
|
|
all: 0, |
|
|
|
zhong: 0 |
|
|
@ -1181,54 +1234,25 @@ export default { |
|
|
|
for (let k = 0; k < item.value.length; k++) { |
|
|
|
let xiangmu = `${item.value[k]}`; |
|
|
|
let xiangmuArr = xiangmu.split(''); |
|
|
|
let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
let count = 0 |
|
|
|
for (let l = 0; l < zhonghaomaArr.length; l++) { |
|
|
|
if (xiangmuArr.includes(zhonghaomaArr[l])) { |
|
|
|
count++ |
|
|
|
} |
|
|
|
} |
|
|
|
if (count >= 3) { |
|
|
|
dataObj.zhong += Number(item.jine) * 150 |
|
|
|
xiangmuArr = _.uniq(xiangmuArr) |
|
|
|
if (xiangmuArr.length < 3) { |
|
|
|
dataObj.zhong += Number(item.jine) * Number(formData[element.key]) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
alljineLocal[element.key] = dataObj |
|
|
|
} |
|
|
|
// 处理全包对子的玩法 |
|
|
|
// else if (element.key == 'quanbaoduizi') { |
|
|
|
// let dataObj = { |
|
|
|
// all: 0, |
|
|
|
// zhong: 0 |
|
|
|
// } |
|
|
|
// for (let j = 0; j < element.data.length; j++) { |
|
|
|
// let item = element.data[j]; |
|
|
|
// dataObj.all += Number(item.jine) |
|
|
|
// for (let k = 0; k < item.value.length; k++) { |
|
|
|
// let xiangmu = `${item.value[k]}`; |
|
|
|
// let xiangmuArr = xiangmu.split(''); |
|
|
|
// let zhonghaomaArr = zhonghaoma.split(''); |
|
|
|
// let count = 0 |
|
|
|
// for (let l = 0; l < zhonghaomaArr.length; l++) { |
|
|
|
// if (xiangmuArr.includes(zhonghaomaArr[l])) { |
|
|
|
// count++ |
|
|
|
// } |
|
|
|
// } |
|
|
|
// if (count >= 3) { |
|
|
|
// dataObj.zhong += Number(item.jine) * 150 |
|
|
|
// } |
|
|
|
// } |
|
|
|
// } |
|
|
|
// alljineLocal[element.key] = dataObj |
|
|
|
// } |
|
|
|
} |
|
|
|
this.tongjiValue = 0 |
|
|
|
this.zhongjiangshuTotal = 0 |
|
|
|
this.zhongjiangshucount = 0 |
|
|
|
for (let key in alljineLocal) { |
|
|
|
this.tongjiValue += alljineLocal[key].all |
|
|
|
this.zhongjiangshuTotal += alljineLocal[key].zhong |
|
|
|
if (alljineLocal[key].zhong > 0) { |
|
|
|
this.zhongjiangshucount++ |
|
|
|
} |
|
|
|
} |
|
|
|
console.log(alljineLocal, 555) |
|
|
|
// ElMessage({ |
|
|
|
// type: 'success', |
|
|
|
// message: JSON.stringify(haomaList), |
|
|
|