| | |
| | | }, |
| | | method: "GET", |
| | | success:(res)=>{ |
| | | console.log(res); |
| | | wx.setStorageSync('phone', res.data.msg) |
| | | if (res.data.data==2) { |
| | | wx.redirectTo( |
| | |
| | | // }, |
| | | // method: "GET", |
| | | // success: (res) => { |
| | | // console.log(res); |
| | | // // 如果用户已经注册直接进入 未注册进入宣传 role == 0用户 1警员 |
| | | // wx.setStorageSync('token', res.data.data.token) |
| | | // wx.setStorageSync('role', res.data.data.role) |
| | |
| | | }, |
| | | method: "GET", |
| | | success: (res) => { |
| | | console.log(res); |
| | | wx.setStorageSync('token', res.data.data.token) |
| | | wx.setStorageSync('role', res.data.data.role) |
| | | wx.setStorageSync('id', res.data.data.id) |
| | |
| | | }}) |
| | | }, |
| | | getReport() { |
| | | console.log("xxx") |
| | | wx.navigateTo({ |
| | | url: '../manager/report/index' |
| | | }) |
| | |
| | | cancel(){ |
| | | console.log("cancel") |
| | | wx.navigateBack({ |
| | | |
| | | }) |
| | | }, |
| | | //通过 |
| | |
| | | url: managerReportDetail.globalData.url +"/report/audit" , |
| | | method:"POST", |
| | | data:this.data.reportDetail, |
| | | header: { 'token':wx.getStorageSync('token') , |
| | | header: { |
| | | 'token': wx.getStorageSync('token'), |
| | | 'content-type': 'application/json' |
| | | } ,success:(res)=>{ |
| | | console.log(res) |
| | |
| | | } |
| | | }, |
| | | onLoad(e) { |
| | | console.log(e) |
| | | wx.request( |
| | | { |
| | | url:managerReportDetail.globalData.url+"/report/" + e.id, |
| | | method: "GET", |
| | | header: { 'token':wx.getStorageSync('token') }, |
| | | success: (res) => { |
| | | let contractMaterials = res.data.data.contractMaterials.split(",") |
| | | let elseMaterials = res.data.data.elseMaterials.split(",") |
| | | let idCardMaterials = res.data.data.idCardMaterials.split(",") |
| | | let transactionMaterials = res.data.data.transactionMaterials.split(",") |
| | | this.setData({ |
| | | reportDetail: res.data.data, |
| | | images:res.data.data.reportMaterials.split(",") |
| | | images: [...idCardMaterials,...contractMaterials,...transactionMaterials,...elseMaterials] |
| | | }) |
| | | console.log(this.data.reportDetail) |
| | | for (let index = 0; index < this.data.images.length; index++) { |
| | | if(this.data.images!=null&&this.data.images[index]!=""&&this.data.images!=undefined){ |
| | | this.data.images[index]=managerReportDetail.globalData.imageUrl+"/img/"+this.data.images[index] |
| | |
| | | this.setData({ |
| | | images:this.data.images |
| | | }) |
| | | console.log(this.data.images) |
| | | } |
| | | }) |
| | | wx.request( |
| | |
| | | }, |
| | | method: "GET", |
| | | success: (res) => { |
| | | console.log(res); |
| | | wx.setStorageSync('token', res.data.data.token) |
| | | wx.setStorageSync('role', res.data.data.role) |
| | | wx.setStorageSync('id', res.data.data.id) |
| | |
| | | |
| | | }, |
| | | getReport() { |
| | | console.log("xxx") |
| | | wx.navigateTo({ |
| | | url: '../user/report/index' |
| | | }) |
| | |
| | | }, |
| | | method: "GET", |
| | | success: (res) => { |
| | | console.log(res); |
| | | wx.setStorageSync('token', res.data.data.token) |
| | | wx.setStorageSync('role', res.data.data.role) |
| | | wx.setStorageSync('id', res.data.data.id) |
| | |
| | | method: "GET", |
| | | header: { 'token': wx.getStorageSync('token') }, |
| | | success: (res) => { |
| | | console.log(res) |
| | | if (res.data.data.reportMaterials != null) { |
| | | this.setData({ |
| | | images: res.data.data.reportMaterials.split(",").map(i=>userDetail.globalData.imageUrl + "/img/" +i) |
| | | images: [...res.data.data.idCardMaterials.split(","), ...res.data.data.contractMaterials.split(","), ...res.data.data.elseMaterials.split(","), ...res.data.data.transactionMaterials.split(",")].map(i => userDetail.globalData.imageUrl + "/img/" + i) |
| | | }) |
| | | } |
| | | this.setData({ |
| | | reportDetail: res.data.data |
| | | }) |
| | |
| | | // this.setData({ |
| | | // images: this.data.images |
| | | // }) |
| | | console.log(this.data.images) |
| | | } |
| | | }) |
| | | |
| | |
| | | }) |
| | | }, |
| | | getDetail(e){ |
| | | let url = '../report/detail/index?id=' + e.currentTarget.id |
| | | if (e.currentTarget.dataset.word == 2) { |
| | | url = '../report/submitReport/index?id=' + e.currentTarget.id |
| | | } |
| | | wx.navigateTo({ |
| | | url:'../report/detail/index?id='+e.currentTarget.id |
| | | url |
| | | }) |
| | | }, |
| | | report(){ |
| | |
| | | id:wx.getStorageSync('id') |
| | | }, |
| | | success:(res)=>{ |
| | | console.log(res) |
| | | this.setData({ |
| | | reportList:res.data.data |
| | | }) |
| | |
| | | |
| | | </van-empty> |
| | | <view wx:for="{{reportList}}" wx:key="id"> |
| | | <view class="conter" id="{{item.id}}" bindtap="getDetail"> |
| | | <view class="conter" id="{{item.id}}" bindtap="getDetail" data-word="{{item.isInGroup}}"> |
| | | <view class="inGroup" wx:if="{{item.isInGroup==1}}">已进群</view> |
| | | <view class="noInGroup" wx:if="{{item.isInGroup==0}}">未进群</view> |
| | | <view class="noInGroup" wx:if="{{item.isInGroup==2}}">已驳回</view> |
| | |
| | | import Toast from '@vant/weapp/toast/toast'; |
| | | Page({ |
| | | data: { |
| | | aaaform: {}, |
| | | capture:['camera'], |
| | | beforList:'a', |
| | | amountInvolved:'', |
| | |
| | | }) |
| | | }, |
| | | afterReadImg(event: { detail: { file: any; }; },name){ |
| | | console.log(event,name); |
| | | |
| | | const { file } = event.detail; |
| | | let that=this |
| | | console.log(file); |
| | | |
| | | // 当设置 mutiple 为 true 时, file 为数组格式,否则为对象格式 |
| | | wx.uploadFile({ |
| | | // filePath: this.data.imagesFile[index].tempFilePath, |
| | |
| | | const { cardIdList = [] } = that.data; |
| | | let result = JSON.parse(res.data) |
| | | if (that.data.beforList=='a') { |
| | | cardIdList.push({ ...file, url: res.data }); |
| | | cardIdList.push({ ...file, url: result.data }); |
| | | that.setData({ cardIdList }); |
| | | }else if(that.data.beforList=='b'){ |
| | | fileImgList.push({ ...file, url: res.data }); |
| | | fileImgList.push({ ...file, url: result.data }); |
| | | that.setData({ fileImgList }); |
| | | }else if(that.data.beforList=='c'){ |
| | | transactionReceiptList.push({ ...file, url: res.data }); |
| | | transactionReceiptList.push({ ...file, url: result.data }); |
| | | that.setData({ transactionReceiptList }); |
| | | }else if(that.data.beforList=='d'){ |
| | | otherList.push({ ...file, url: res.data }); |
| | | otherList.push({ ...file, url: result.data }); |
| | | that.setData({ otherList }); |
| | | } |
| | | |
| | | |
| | | that.setData({ |
| | | materials: that.data.materials+=result.data+"," |
| | | }) |
| | | console.log(that.data.materials); |
| | | }, |
| | | }); |
| | | }, |
| | | //选择案件 |
| | | pickCause(e: { detail: { value: string | number; }; }) { |
| | | console.log(e); |
| | | this.setData({ |
| | | causeIndex: e.detail.value |
| | | }) |
| | |
| | | this.setData({ |
| | | imagesFile: res.tempFiles |
| | | }) |
| | | console.log(this.data.imagesFile); |
| | | |
| | | for (let index = 0; index < this.data.imagesFile.length; index++) { |
| | | wx.uploadFile({ |
| | | filePath: this.data.imagesFile[index].tempFilePath, |
| | |
| | | this.setData({ |
| | | materials: this.data.materials+=result.data+"," |
| | | }) |
| | | console.log(this.data.materials); |
| | | } |
| | | }) |
| | | } |
| | |
| | | }, |
| | | //被骗时间 |
| | | onPickerChange(e){ |
| | | console.log(e) |
| | | this.data.cheatTime=e.detail.value |
| | | }, |
| | | subSex(e){ |
| | | console.log(e); |
| | | |
| | | }, |
| | | bindPickerChangeSex(e){ |
| | | console.log(e); |
| | | this.setData({ |
| | | sexId:e.detail.value |
| | | }) |
| | |
| | | }) |
| | | }, |
| | | getMoney:function(e){ |
| | | console.log(e.detail.value) |
| | | this.data.reportDetail.amountInvolved=e.detail.value |
| | | }, |
| | | getDe:function(e){ |
| | | console.log(e.detail.value) |
| | | this.data.reportDetail.reportDescription=e.detail.value |
| | | }, |
| | | getInfor:function(e){ |
| | | this.data.reportDetail.information=e.detail.value |
| | | console.log(e.detail.value) |
| | | }, |
| | | //通过 |
| | | cancel(){ |
| | |
| | | }) |
| | | }, |
| | | pass() { |
| | | console.log(this.data.realName); |
| | | if (this.data.realName=='') { |
| | | Toast('请输入姓名!'); |
| | | return |
| | |
| | | if (this.data.fileImgList.length!=0||this.data.transactionReceiptList.length!=0||this.data.otherList.length!=0) { |
| | | |
| | | }else{ |
| | | |
| | | Toast('相关合同,交易凭证,其他;必填一项!'); |
| | | return |
| | | } |
| | | this.data.materials=this.data.materials.substring(0,this.data.materials.length-1); |
| | | this.data.reportDetail.amountInvolved=this.data.amountInvolved, |
| | | this.data.reportDetail.workingLocation=this.data.workingLocation, |
| | | this.data.reportDetail.Location=this.data.Location, |
| | | this.data.reportDetail.userIdCard=this.data.userIdCard, |
| | | this.data.reportDetail.sex=this.data.sex, |
| | | this.data.reportDetail.realName=this.data.realName, |
| | | this.data.reportDetail.phone=this.data.phone, |
| | | this.data.reportDetail.amountInvolved = this.data.amountInvolved |
| | | this.data.reportDetail.workingLocation = this.data.workingLocation |
| | | this.data.reportDetail.location = this.data.Location |
| | | this.data.reportDetail.userIdCard = this.data.userIdCard |
| | | this.data.reportDetail.sex = this.data.sex |
| | | this.data.reportDetail.realName = this.data.realName |
| | | this.data.reportDetail.phone = this.data.phone |
| | | this.data.reportDetail.reportMaterials=this.data.materials |
| | | this.data.reportDetail.userId=wx.getStorageSync('id') |
| | | this.data.reportDetail.cheatTime=this.data.cheatTime |
| | | this.data.reportDetail.idCardMaterials = this.data.cardIdList.map(res => res.url).join(',') |
| | | this.data.reportDetail.contractMaterials = this.data.fileImgList.map(res => res.url).join(',') |
| | | this.data.reportDetail.transactionMaterials = this.data.transactionReceiptList.map(res => res.url).join(',') |
| | | this.data.reportDetail.elseMaterials = this.data.otherList.map(res => res.url).join(',') |
| | | // if ( this.data.reportDetail.information==null|| this.data.reportDetail.reportDescription==null) { |
| | | // wx.showToast({ |
| | | // icon: "none", |
| | |
| | | 'token': wx.getStorageSync('token'), |
| | | 'content-type': 'application/json' |
| | | }, success: (res) => { |
| | | console.log(res) |
| | | wx.reLaunch({ |
| | | url:'../../report/index' |
| | | }) |
| | | } |
| | | }) |
| | | |
| | | |
| | | }, |
| | | onLoad(e) { |
| | | let that = this |
| | | let phone = wx.getStorageSync('phone') |
| | | this.setData({ |
| | | phone:phone |
| | |
| | | secends = "0" + secends |
| | | } |
| | | this.data.cheatTime = date.getFullYear() + "-" + month + "-" + day + " " + hours+":"+minutes+":"+secends |
| | | console.log( this.data.cheatTime) |
| | | this.loadData(e) |
| | | wx.request( |
| | | { |
| | | url: submitReport.globalData.url+ "/cause/getCauseList", |
| | | url: submitReport.globalData.url + "/cause/getVxCauseList?phone=" + that.data.phone, |
| | | method: "GET", |
| | | header: { 'token': wx.getStorageSync('token')}, |
| | | success: (res) => { |
| | | let causes = res.data.data |
| | | console.log(that.data.aaaform); |
| | | if (e.id) { |
| | | causes.push({ |
| | | id: that.data.aaaform.causeId, |
| | | name: that.data.aaaform.description |
| | | }) |
| | | } |
| | | this.setData({ |
| | | causeList: res.data.data.records |
| | | causeList: causes, |
| | | causeIndex: causes.findIndex(i => i.id == that.data.aaaform.causeId) |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | | loadData(e: any) { |
| | | let that = this |
| | | const { arraySex } = this.data |
| | | if (e.id) { |
| | | wx.request({ |
| | | url: submitReport.globalData.url + "/report/rejectReport/" + e.id, |
| | | method: "GET", |
| | | header: { 'token': wx.getStorageSync('token') }, |
| | | success: res => { |
| | | let form = res.data.data |
| | | this.setData({ |
| | | aaaform: form, |
| | | realName: form.realName, |
| | | phone: form.mobile, |
| | | userIdCard: form.userIdCard, |
| | | amountInvolved: form.amountInvolved, |
| | | sex: form.sex, |
| | | sexId: arraySex.filter(i => i.sex == form.sex)[0].code, |
| | | Location: form.location, |
| | | workingLocation: form.workingLocation, |
| | | cardIdList: form.idCardMaterials.split(',').map(i => { |
| | | return { |
| | | thumb: that.imgComplete(i), |
| | | url: i, |
| | | type: "image", |
| | | size: 999999 |
| | | } |
| | | }), |
| | | fileImgList: form.contractMaterials.split(',').map(i => { |
| | | return { |
| | | thumb: that.imgComplete(i), |
| | | url: i, |
| | | type: "image", |
| | | size: 999999 |
| | | } |
| | | }), |
| | | transactionReceiptList: form.transactionMaterials.split(',').map(i => { |
| | | return { |
| | | thumb: that.imgComplete(i), |
| | | url: i, |
| | | type: "image", |
| | | size: 999999 |
| | | } |
| | | }), |
| | | otherList: form.elseMaterials.split(',').map(i => { |
| | | return { |
| | | thumb: that.imgComplete(i), |
| | | url: i, |
| | | type: "image", |
| | | size: 999999 |
| | | } |
| | | }) |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | }, |
| | | imgComplete(file: String): String { |
| | | return submitReport.globalData.imageUrl + "/img/" + file |
| | | } |
| | | }) |
| | |
| | | <view class="text">为更快审核,请如实填写相关信息,*为必填项</view> |
| | | </view> |
| | | <van-cell-group> |
| | | <van-field |
| | | bind:input="getrealName" |
| | | required |
| | | value="{{ realName }}" |
| | | label="姓名" |
| | | placeholder="请输入姓名" |
| | | /> |
| | | <van-field bind:input="getrealName" required value="{{ realName }}" label="姓名" placeholder="请输入姓名" /> |
| | | <!-- <van-field |
| | | bind:input="getsex" |
| | | required |
| | |
| | | </picker> |
| | | </view> |
| | | |
| | | <van-field |
| | | bind:input="getuserIdCard" |
| | | required |
| | | value="{{ userIdCard }}" |
| | | label="身份证" |
| | | placeholder="请输入身份证" |
| | | /> |
| | | <van-field |
| | | disabled |
| | | required |
| | | value="{{ phone }}" |
| | | label="联系电话" |
| | | placeholder="请输入联系电话" |
| | | |
| | | /> |
| | | <van-field |
| | | bind:input="getLocation" |
| | | required |
| | | value="{{ Location }}" |
| | | label="现住址" |
| | | placeholder="请输入现住址" |
| | | |
| | | /> |
| | | <van-field |
| | | bind:input="getworkingLocation" |
| | | required |
| | | value="{{ workingLocation }}" |
| | | label="工作单位" |
| | | placeholder="请输入工作单位" |
| | | |
| | | /> |
| | | <van-field bind:input="getuserIdCard" required value="{{ userIdCard }}" label="身份证" placeholder="请输入身份证" /> |
| | | <van-field disabled required value="{{ phone }}" label="联系电话" placeholder="请输入联系电话" /> |
| | | <van-field bind:input="getLocation" required value="{{ Location }}" label="现住址" placeholder="请输入现住址" /> |
| | | <van-field bind:input="getworkingLocation" required value="{{ workingLocation }}" label="工作单位" placeholder="请输入工作单位" /> |
| | | <view class="cause"> |
| | | <view class="font-wenzi-cause">描述</view> |
| | | <picker bindchange="pickCause" class="content" value="{{causeIndex}}" range="{{causeList}}" range-key="{{'name'}}" mode="selector"> |
| | |
| | | </picker> |
| | | |
| | | </view> |
| | | <van-field |
| | | bind:input="getamountInvolved" |
| | | required |
| | | value="{{ amountInvolved }}" |
| | | label="受损金额" |
| | | placeholder="请输入受损金额" |
| | | /> |
| | | <van-field |
| | | required |
| | | readonly |
| | | value="{{ }}" |
| | | label="作证材料" |
| | | placeholder=" " |
| | | > |
| | | <van-field bind:input="getamountInvolved" required value="{{ amountInvolved }}" label="受损金额" placeholder="请输入受损金额" /> |
| | | <van-field required readonly value="{{ }}" label="作证材料" placeholder=" "> |
| | | |
| | | </van-field> |
| | | <van-notice-bar |
| | | left-icon="volume-o" |
| | | text="身份证正反必填,相关合同,交易凭证,其他;三个必须要填写一个" |
| | | |
| | | /> |
| | | <van-notice-bar left-icon="volume-o" text="身份证正反必填,相关合同,交易凭证,其他;三个必须要填写一个" /> |
| | | <!-- <view class="upload" bindtap="uploadImage"> |
| | | <image class="imageUp" src="../../../icon/Photograph.png"></image> |
| | | <view class="upload-wenzi">拍摄身份证照片</view> |
| | |
| | | </view> --> |
| | | <van-tabs active="a" ellipsis="{{false}}" bind:change="onChangeTabs"> |
| | | <van-tab title="身份证正反面" name="a"> |
| | | <van-uploader |
| | | file-list="{{ cardIdList }}" |
| | | max-count="2" |
| | | bind:after-read="afterReadImg" |
| | | capture="{{ capture }}" |
| | | accept="image" |
| | | /> |
| | | <van-uploader file-list="{{ cardIdList }}" max-count="2" bind:after-read="afterReadImg" capture="{{ capture }}" accept="image" /> |
| | | |
| | | </van-tab> |
| | | <van-tab title="相关合同" name="b"> |
| | | <van-uploader |
| | | file-list="{{ fileImgList }}" |
| | | bind:after-read="afterReadImg" |
| | | /> |
| | | <van-uploader file-list="{{ fileImgList }}" bind:after-read="afterReadImg" /> |
| | | </van-tab> |
| | | <van-tab title="交易凭证" name="c"> |
| | | <van-uploader |
| | | file-list="{{ transactionReceiptList }}" |
| | | bind:after-read="afterReadImg" |
| | | /> |
| | | <van-uploader file-list="{{ transactionReceiptList }}" bind:after-read="afterReadImg" /> |
| | | </van-tab> |
| | | <van-tab title="其他" name="d"> |
| | | <van-uploader |
| | | file-list="{{ otherList }}" |
| | | bind:after-read="afterReadImg" |
| | | /> |
| | | <van-uploader file-list="{{ otherList }}" bind:after-read="afterReadImg" /> |
| | | </van-tab> |
| | | </van-tabs> |
| | | </van-cell-group> |