| | |
| | | }); |
| | | } |
| | | |
| | | // 获取案例 |
| | | function getCaseApi(submitData) { |
| | | return $$.request({ |
| | | url: 'case-law/get-case', |
| | | type: 'post', |
| | | ai: true, |
| | | submitData, |
| | | service: 'mediate', |
| | | }); |
| | | } |
| | | |
| | | function caseRegisterSaveApi(submitData) { |
| | | return $$.request({ |
| | |
| | | saveStatus: true |
| | | }) |
| | | } |
| | | const res1 = await getCaseApi({ |
| | | caseDes: params.caseDes, |
| | | caseClaim: params.caseClaim, |
| | | caseId: params.id, |
| | | }); |
| | | if (res1.type) { |
| | | wx.setStorage({ |
| | | key: 'AICase', |
| | | data: { |
| | | caseDes: params.caseDes, |
| | | caseClaim: params.caseClaim, |
| | | caseId: params.id, |
| | | } |
| | | }); |
| | | } |
| | | }, |
| | | |
| | | //选择纠纷类型 、跳转事项概况语音描述,跳转事项申请语音描述 |
| | |
| | | // 图片识别 |
| | | ocrClick(e) { |
| | | let key = e.currentTarget.dataset.key; |
| | | let keyNum = e.currentTarget.dataset.keyNum; |
| | | let keyNum = e.currentTarget.dataset.keynum; |
| | | let that = this; |
| | | wx.chooseMedia({ |
| | | count: 1, |
| | |
| | | } |
| | | let wordsResult = data?.ocrResult?.wordsResult.join(''); |
| | | let wordsResultNum = data?.ocrResult?.wordsResultNum; |
| | | console.log('wordsResult', wordsResult); |
| | | that.setData({ |
| | | submitData: { |
| | | ...that.data.submitData, |
| | | [key]: wordsResult |
| | | [key]: that.data.submitData.caseDes + wordsResult |
| | | }, |
| | | [keyNum]: wordsResultNum |
| | | [keyNum]: (that.data.submitData.caseDes + wordsResult).length |
| | | }); |
| | | } |
| | | }, |
| | |
| | | perTypeName: '申请方当事人', |
| | | perClass: '09_01001-1', |
| | | perClassName: '自然人', |
| | | certiNo: data.idcard || '' |
| | | certiNo: data.idcard || '', |
| | | certiType: data.certiType || '09_00015-1', |
| | | certiTypeName: data.certiTypeName || '身份证', |
| | | }] |
| | | }) |
| | | }; |
| | |
| | | onShow: function () { |
| | | if (this.data.oneData?.trueName) { |
| | | let list = this.data.oneList; |
| | | console.log('list', list); |
| | | console.log('this.data.editIndex', this.data.editIndex); |
| | | console.log('this.data.oneData', this.data.oneData); |
| | | if (this.data.editIndex) { |
| | | list[this.data.editIndex] = this.data.oneData; |
| | | } else { |
| | |
| | | }) |
| | | } |
| | | |
| | | if (this.data.twoData?.title) { |
| | | if (this.data.twoData?.label) { |
| | | this.setData({ |
| | | submitData: { |
| | | ...this.data.submitData, |
| | | caseType: this.data.twoData.value, |
| | | caseTypeName: this.data.twoData.title, |
| | | caseTypeName: this.data.twoData.label, |
| | | }, |
| | | twoData: {} |
| | | }) |
| | |
| | | this.setData({ |
| | | submitData: { |
| | | ...this.data.submitData, |
| | | [this.data.twoKey]: this.data.twoValue |
| | | [this.data.twoKey]: this.data.submitData[this.data.twoKey] + this.data.twoValue, |
| | | }, |
| | | [this.data.twoKey + 'Num']: (this.data.submitData[this.data.twoKey] + this.data.twoValue).length, |
| | | twoValue: '', |
| | | twoKey: '' |
| | | }) |