更换版本
This commit is contained in:
309
packageA/pages/rengong/rengong.js
Normal file
309
packageA/pages/rengong/rengong.js
Normal file
@@ -0,0 +1,309 @@
|
||||
var t;
|
||||
(t = getApp()),
|
||||
Page({
|
||||
data: {
|
||||
highe: wx.getSystemInfoSync().windowHeight + 180,
|
||||
inputShowed: !1,
|
||||
inputVal: "",
|
||||
amapPlugin: null,
|
||||
covers: [],
|
||||
address: [],
|
||||
scrollH: 356,
|
||||
dk: 1,
|
||||
ok: 0,
|
||||
type: 2,
|
||||
files: [],
|
||||
imgs: [],
|
||||
content: "",
|
||||
latitude: "",
|
||||
longitude: "",
|
||||
address: "",
|
||||
name: "",
|
||||
beizhu: "",
|
||||
cxjg: "",
|
||||
orderid: "",
|
||||
showPrivacy: !1,
|
||||
},
|
||||
uploadimg: function () {
|
||||
if (wx.getStorageSync("uid")) {
|
||||
var e = this.data.files,
|
||||
a = {
|
||||
url:
|
||||
t.util.url("entry/wxapp/scqiniu") +
|
||||
"&m=" +
|
||||
t.siteInfo.m +
|
||||
"&ids=uptp",
|
||||
path: e,
|
||||
};
|
||||
e.length > 0
|
||||
? ((t.globalData.files = []), this.uploadimgs(a))
|
||||
: this.ok(),
|
||||
this.setData({ ok: 1 });
|
||||
}
|
||||
},
|
||||
handleAgreePrivacyAuthorization() {
|
||||
this.setData({ showPrivacy: !1 }),
|
||||
wx.showToast({
|
||||
title: "感谢您的同意,请开始使用~",
|
||||
icon: "none",
|
||||
duration: 2e3,
|
||||
});
|
||||
},
|
||||
handleOpenPrivacyContract() {
|
||||
wx.openPrivacyContract({
|
||||
success: () => {},
|
||||
fail: () => {},
|
||||
complete: () => {},
|
||||
});
|
||||
},
|
||||
uploadimgs: function (e) {
|
||||
var a = this,
|
||||
i = e.i ? e.i : 0,
|
||||
o = e.success ? e.success : 0,
|
||||
n = e.fail ? e.fail : 0;
|
||||
wx.showLoading({ title: "上传中.." }),
|
||||
console.log("上传图片路径", e.path[i]),
|
||||
wx.uploadFile({
|
||||
url: e.url,
|
||||
filePath: e.path[i],
|
||||
name: "file",
|
||||
formData: null,
|
||||
success: (e) => {
|
||||
o++, console.log(e), console.log(i);
|
||||
var a = e.data.replace("\r\n", "");
|
||||
1 != a
|
||||
? (t.globalData.files = t.globalData.files.concat(a))
|
||||
: wx.showToast({
|
||||
title: "图片" + (i + 1) + "违规",
|
||||
icon: "success",
|
||||
duration: 2e3,
|
||||
});
|
||||
},
|
||||
fail: (t) => {
|
||||
n++, console.log("fail:" + i + "fail:" + n), wx.hideLoading();
|
||||
},
|
||||
complete: () => {
|
||||
console.log(i),
|
||||
++i == e.path.length
|
||||
? (console.log("执行完毕"),
|
||||
console.log(t.globalData.files),
|
||||
console.log("成功:" + o + " 失败:" + n),
|
||||
a.setData({ imgs: t.globalData.files }),
|
||||
wx.hideLoading(),
|
||||
a.ok())
|
||||
: (console.log(i),
|
||||
(e.i = i),
|
||||
(e.success = o),
|
||||
(e.fail = n),
|
||||
a.uploadimgs(e));
|
||||
},
|
||||
});
|
||||
},
|
||||
ok: function (e) {
|
||||
var a = this;
|
||||
if (5 == a.data.type || a.data.imgs[0])
|
||||
if (5 != a.data.type || a.data.cxjg) {
|
||||
wx.showLoading({ title: "完成中.." });
|
||||
var i = {
|
||||
uid: wx.getStorageSync("uid"),
|
||||
imgs: a.data.imgs,
|
||||
orderid: a.data.orderid,
|
||||
content: a.data.content,
|
||||
type: a.data.type,
|
||||
typeid: a.data.typeid,
|
||||
beizhu: a.data.beizhu,
|
||||
cxjg: a.data.cxjg,
|
||||
};
|
||||
t.getdata(i, "rengong").then((t) => {
|
||||
wx.hideLoading(),
|
||||
console.log("回调数据搜索:", t),
|
||||
a.setData({ ok: 0, files: [], imgs: [], content: "" }),
|
||||
wx.showModal({
|
||||
title: "温馨提示",
|
||||
content: "已经在提交~",
|
||||
success: function (t) {
|
||||
t.confirm
|
||||
? a.setData({ dk: 0 })
|
||||
: t.cancel && console.log("用户点击取消");
|
||||
},
|
||||
});
|
||||
});
|
||||
} else
|
||||
wx.showModal({
|
||||
title: "温馨提示",
|
||||
content: "请输入结果",
|
||||
success: function (t) {},
|
||||
});
|
||||
else
|
||||
wx.showModal({
|
||||
title: "温馨提示",
|
||||
content: "请上传结果图片",
|
||||
success: function (t) {},
|
||||
});
|
||||
},
|
||||
tuikuan: function (e) {
|
||||
var a = this;
|
||||
if (a.data.beizhu) {
|
||||
wx.showLoading({ title: "完成中.." });
|
||||
var i = {
|
||||
uid: wx.getStorageSync("uid"),
|
||||
orderid: a.data.orderid,
|
||||
typeid: a.data.typeid,
|
||||
type: 0,
|
||||
beizhu: a.data.beizhu,
|
||||
};
|
||||
t.getdata(i, "rengong").then((t) => {
|
||||
wx.hideLoading(),
|
||||
console.log("回调数据搜索:", t),
|
||||
a.setData({ ok: 0, files: [], imgs: [], content: "" }),
|
||||
wx.showModal({
|
||||
title: "温馨提示",
|
||||
content: "已经退款~",
|
||||
success: function (t) {
|
||||
t.confirm
|
||||
? a.setData({ dk: 0 })
|
||||
: t.cancel && console.log("用户点击取消");
|
||||
},
|
||||
});
|
||||
});
|
||||
} else
|
||||
wx.showModal({
|
||||
title: "温馨提示",
|
||||
content: "请填写退款备注",
|
||||
success: function (t) {},
|
||||
});
|
||||
},
|
||||
onShow: function (t) {
|
||||
wx.getPrivacySetting({
|
||||
success: (t) => {
|
||||
console.log(t),
|
||||
t.needAuthorization && this.setData({ showPrivacy: !0 });
|
||||
},
|
||||
fail: () => {},
|
||||
complete: () => {},
|
||||
});
|
||||
},
|
||||
onLoad: function (t) {
|
||||
wx.getStorageSync("uid") || getApp().wxlogin(),
|
||||
this.setData({
|
||||
orderid: t.orderid,
|
||||
type: t.type,
|
||||
typeid: t.type,
|
||||
vin: t.vin,
|
||||
}),
|
||||
this.getDetail(t.orderid);
|
||||
const e = this;
|
||||
wx.getSystemInfo({
|
||||
success: function (t) {
|
||||
e.setData({
|
||||
scrollH: t.windowHeight - 44 - (t.windowWidth / 750) * 400,
|
||||
});
|
||||
},
|
||||
});
|
||||
},
|
||||
getDetail: function (e) {
|
||||
var a = this,
|
||||
i = { typeid: a.data.typeid, orderid: e };
|
||||
t.getdata(i, "rengongid").then((t) => {
|
||||
console.log("回调数据:", t),
|
||||
t && a.setData({ cardata: t.data, orderid: e });
|
||||
});
|
||||
},
|
||||
chaping: function () {
|
||||
var t = this;
|
||||
setTimeout(function () {
|
||||
let e = null;
|
||||
wx.createInterstitialAd &&
|
||||
((e = wx.createInterstitialAd({ adUnitId: t.data.capingtId })),
|
||||
e.onLoad(() => {}),
|
||||
e.onError((t) => {}),
|
||||
e.onClose(() => {})),
|
||||
e &&
|
||||
e.show().catch((t) => {
|
||||
console.error(t);
|
||||
});
|
||||
}, 3e3);
|
||||
},
|
||||
chooseImage: function (e) {
|
||||
let a = this;
|
||||
a.data.files.length >= 120
|
||||
? t.showToast("最多上传120张图片")
|
||||
: wx.chooseImage({
|
||||
count: 120 - a.data.files.length,
|
||||
sizeType: ["original"],
|
||||
sourceType: ["album", "camera"],
|
||||
success: function (t) {
|
||||
a.setData({ files: a.data.files.concat(t.tempFilePaths) });
|
||||
},
|
||||
});
|
||||
},
|
||||
previewImage: function (t) {
|
||||
wx.previewImage({ current: t.currentTarget.id, urls: this.data.files });
|
||||
},
|
||||
xszImage: function (t) {
|
||||
wx.previewImage({
|
||||
current: t.currentTarget.id,
|
||||
urls: [t.currentTarget.id],
|
||||
});
|
||||
},
|
||||
fuzhi: function (t) {
|
||||
wx.setClipboardData({
|
||||
data: t.currentTarget.id,
|
||||
success(t) {
|
||||
wx.getClipboardData({
|
||||
success(t) {
|
||||
wx.showModal({
|
||||
title: "提示",
|
||||
content: "复制成功",
|
||||
success: function (t) {
|
||||
t.confirm
|
||||
? console.log("确定")
|
||||
: t.cancel && console.log("取消");
|
||||
},
|
||||
}),
|
||||
console.log(t.data);
|
||||
},
|
||||
});
|
||||
},
|
||||
});
|
||||
},
|
||||
deleteImage: function (t) {
|
||||
const e = t.currentTarget.dataset.index;
|
||||
let a = this.data.files;
|
||||
a.splice(e, 1), this.setData({ files: a });
|
||||
},
|
||||
trim: function (t) {
|
||||
return t ? t.toString().replace(/(^\s*)|(\s*$)/g, "") : t;
|
||||
},
|
||||
showInput() {
|
||||
this.setData({ inputShowed: !0 });
|
||||
},
|
||||
hideInput() {
|
||||
this.setData({ inputVal: "", inputShowed: !1 }), wx.hideKeyboard();
|
||||
},
|
||||
clearInput() {
|
||||
this.setData({ inputVal: "" });
|
||||
},
|
||||
inputTyping: function (t) {
|
||||
this.setData({ inputVal: t.detail.value });
|
||||
},
|
||||
qxdaka: function (t) {
|
||||
this.setData({ content: "" }), wx.navigateBack({ delta: 0 });
|
||||
},
|
||||
bindInput: function (t) {
|
||||
const e = t.detail.value;
|
||||
this.getPoiAround(e);
|
||||
},
|
||||
conInput: function (t) {
|
||||
this.setData({ content: t.detail.value }), console.log(t.detail.value);
|
||||
},
|
||||
gameInput: function (t) {
|
||||
this.setData({ orderid: t.detail.value }), console.log(t.detail.value);
|
||||
},
|
||||
beizhuInput: function (t) {
|
||||
this.setData({ beizhu: t.detail.value }), console.log(t.detail.value);
|
||||
},
|
||||
cxjgInput: function (t) {
|
||||
this.setData({ cxjg: t.detail.value }), console.log(t.detail.value);
|
||||
},
|
||||
});
|
||||
4
packageA/pages/rengong/rengong.json
Normal file
4
packageA/pages/rengong/rengong.json
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"navigationBarTitleText": "人工处理",
|
||||
"usingComponents": {}
|
||||
}
|
||||
83
packageA/pages/rengong/rengong.wxml
Normal file
83
packageA/pages/rengong/rengong.wxml
Normal file
@@ -0,0 +1,83 @@
|
||||
<view class="page__mask" wx:if="{{showPrivacy}}"></view>
|
||||
<view class="privacy-dialog" wx:if="{{showPrivacy}}">
|
||||
<view class="privacy-dialog__title">用户隐私保护提示</view>
|
||||
<view class="privacy-dialog__content">亲爱用户,当您点击同意并开始使用产品服务时,即表示你已理解并同息该条款内容,该条款将对您产生法律约束力。如您拒绝,将无法使用本小程序提供的相关产品及服务。</view>
|
||||
<button bindtap="handleOpenPrivacyContract" class="privacy-dialog__text">查看隐私协议</button>
|
||||
<button bindagreeprivacyauthorization="handleAgreePrivacyAuthorization" class="privacy-dialog__button" id="agree-btn" openType="agreePrivacyAuthorization">同意</button>
|
||||
</view>
|
||||
<view>
|
||||
<view style="width: 750rpx; height:auto;">
|
||||
<view class="container" style="width: 577rpx; height: 809rpx; ">
|
||||
<view class="tui-padding" style="width: 511rpx; height: 811rpx; ">
|
||||
<view class="tui-title tui-top40" wx:if="{{type==1}}">查询项目:维修记录</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{type==2}}">查询项目:出险记录</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{type==5}}">查询项目:交强险日期查询,公司查询</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{type==8}}">查询项目:电子保单</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{type==9}}">查询项目:车辆状态</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{type==4}}">查询项目:车架号处理</view>
|
||||
<view class="tui-title tui-top40" style="color: deeppink;" wx:if="{{type==26}}">查询项目:商业险信息查询</view>
|
||||
<view class="tui-title tui-top40" style="color: deeppink;" wx:if="{{cardata.cxtype}}">查询类型:{{cardata.cxtype}}</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.money}}">付费价格</view>
|
||||
<view bindtap="fuzhi" class="tui-cells" id="{{cardata.money}}" style="width: 617rpx; height: 85rpx; display: block; box-sizing: border-box; left: 0rpx; top: 0rpx" wx:if="{{cardata.money}}">
|
||||
<view class="tui-textarea" placeholderClass="tui-phcolor-color">{{cardata.money}}</view>
|
||||
</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.type==0}}">普通查询</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.type==1}}">高级查询</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.vin}}">车架号:</view>
|
||||
<view bindtap="fuzhi" class="tui-cells" id="{{cardata.vin}}" style="width: 617rpx; height: 85rpx; display: block; box-sizing: border-box; left: 0rpx; top: 0rpx" wx:if="{{cardata.vin}}">
|
||||
<input class="tui-textarea" maxlength="17" placeholder="车辆识别码/车架号" type="text" value="{{cardata.vin}}" wx:if="{{cardata.vin}}"></input>
|
||||
</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.chepai}}">车牌号</view>
|
||||
<view bindtap="fuzhi" class="tui-cells" id="{{cardata.chepai}}" style="width: 617rpx; height: 85rpx; display: block; box-sizing: border-box; left: 0rpx; top: 0rpx" wx:if="{{cardata.chepai}}">
|
||||
<input class="tui-textarea" maxlength="17" placeholder="车辆识别码/车架号" type="text" value="{{cardata.chepai}}" wx:if="{{cardata.chepai}}"></input>
|
||||
</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.engine}}">发动机号</view>
|
||||
<view bindtap="fuzhi" class="tui-cells" id="{{cardata.engine}}" style="width: 617rpx; height: 85rpx; display: block; box-sizing: border-box; left: 0rpx; top: 0rpx" wx:if="{{cardata.engine}}">
|
||||
<input class="tui-textarea" maxlength="17" placeholder="车辆识别码/车架号" type="text" value="{{cardata.engine}}" wx:if="{{cardata.engine}}"></input>
|
||||
</view>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.xszimg}}">行驶证</view>
|
||||
<image bindtap="xszImage" class="tui-upload-img" id="{{cardata.xszimg}}" mode="aspectFill" src="{{cardata.xszimg}}" wx:if="{{cardata.xszimg}}"></image>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.daben}}">大本(绿本1)</view>
|
||||
<image bindtap="xszImage" class="tui-upload-img" id="{{cardata.daben}}" mode="aspectFill" src="{{cardata.daben}}" wx:if="{{cardata.daben}}"></image>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.daben1}}">大本(绿本2)</view>
|
||||
<image bindtap="xszImage" class="tui-upload-img" id="{{cardata.daben1}}" mode="aspectFill" src="{{cardata.daben1}}" wx:if="{{cardata.daben1}}"></image>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.daben2}}">大本(绿本3)</view>
|
||||
<image bindtap="xszImage" class="tui-upload-img" id="{{cardata.daben2}}" mode="aspectFill" src="{{cardata.daben2}}" wx:if="{{cardata.daben2}}"></image>
|
||||
<view class="tui-title tui-top40" wx:if="{{cardata.daben3}}">大本(绿本4)</view>
|
||||
<image bindtap="xszImage" class="tui-upload-img" id="{{cardata.daben3}}" mode="aspectFill" src="{{cardata.daben3}}" wx:if="{{cardata.daben3}}"></image>
|
||||
<view class="tui-title tui-top40">通知单号</view>
|
||||
<view class="tui-cells" style="width: 617rpx; height: 105rpx; display: block; box-sizing: border-box; left: 0rpx; top: 0rpx">
|
||||
<textarea bindconfirm="gameInput" bindinput="gameInput" class="tui-textarea" maxlength="500" name="gameid" placeholder="写下通知单号~" placeholderClass="tui-phcolor-color" value="{{orderid}}"></textarea>
|
||||
</view>
|
||||
<block wx:if="{{type!=5}}">
|
||||
<view class="tui-title tui-top40">查询成功图片上传(请点击加号上传)当前共:{{files.length}}张图</view>
|
||||
<view class="tui-upload-box" style="width: 697rpx; height: auto;margin-left: -10px; ">
|
||||
<view class="tui-upload-item" style=" height: auto;" wx:for="{{files}}" wx:key="{{index}}">
|
||||
<image bindtap="previewImage" class="tui-upload-img" id="{{item}}" mode="aspectFill" src="{{item}}"></image>
|
||||
<text catchtap="deleteImage" class="grace-text-small grace-gray grace-icons icon-remove" data-index="{{index}}">删除该图</text>
|
||||
<tui-icon catchtap="deleteImage" data-index="{{index}}" name="close-fill" tuiIconClass="tui-upload-del"></tui-icon>
|
||||
</view>
|
||||
<view bindtap="chooseImage" class="tui-upload-item tui-upload-add" hidden="{{files.length>=120}}" hoverClass="tui-opcity" hoverStayTime="150">
|
||||
<text>+</text>
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
<block wx:if="{{type==5}}">
|
||||
<view class="tui-title tui-top40">查询结果</view>
|
||||
<view class="" style="width: 617rpx; height: 205rpx; left: 0rpx; top: 0rpx; border: 1px solid #e6e6e6;">
|
||||
<input bindconfirm="cxjgInput" bindinput="cxjgInput" maxlength="500" name="cxjg" placeholder="输入查询的结果~" style="width: 617rpx; height: 205rpx; font-size: 32rpx;left: 0rpx; top: 0rpx; border: 1px solid #e6e6e6;" value="{{cxjg}}"></input>
|
||||
</view>
|
||||
</block>
|
||||
<view class="tui-title tui-top40">退款备注</view>
|
||||
<view class="" style="width: 617rpx; height: 205rpx; left: 0rpx; top: 0rpx; border: 1px solid #e6e6e6;">
|
||||
<input bindconfirm="beizhuInput" bindinput="beizhuInput" maxlength="500" name="beizhu" placeholder="写下查询备注,如退款备注,查询结果说明~" style="width: 617rpx; height: 205rpx; font-size: 32rpx;left: 0rpx; top: 0rpx; border: 1px solid #e6e6e6;" value="{{beizhu}}"></input>
|
||||
</view>
|
||||
<view class="" style="width: 617rpx; height: 205rpx; left: 0rpx; top: 0rpx; ">
|
||||
<button bindtap="uploadimg" class="search-button">提交完成</button>
|
||||
<button bindtap="tuikuan" class="tukuan-button">立即退款</button>
|
||||
</view>
|
||||
<view style="height: 100rpx;"></view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
3163
packageA/pages/rengong/rengong.wxss
Normal file
3163
packageA/pages/rengong/rengong.wxss
Normal file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user