From 033db943c51e00137b7f4de8fa43b6c42d7e6f38 Mon Sep 17 00:00:00 2001 From: dengbw Date: Wed, 2 Nov 2022 14:08:05 +0800 Subject: [PATCH] viewer_1102 --- admin/views/index.php | 6 + admin/views/receiver/orders/get.php | 90 +- admin/views/receiver/orderv2/get/ckinfo.php | 365 +- admin/views/receiver/orderv2/get/index.php | 174 +- admin/views/receiver/orderv2/get/loaninfo.php | 114 +- .../libraries/receiver/Order_datas_entity.php | 6 + .../static/js/plugin/viewer/jquery-viewer.js | 73 + www/admin/static/js/plugin/viewer/viewer.css | 446 +++ www/admin/static/js/plugin/viewer/viewer.js | 3204 +++++++++++++++++ 9 files changed, 4110 insertions(+), 368 deletions(-) create mode 100644 www/admin/static/js/plugin/viewer/jquery-viewer.js create mode 100644 www/admin/static/js/plugin/viewer/viewer.css create mode 100644 www/admin/static/js/plugin/viewer/viewer.js diff --git a/admin/views/index.php b/admin/views/index.php index aba37482..a3df5352 100755 --- a/admin/views/index.php +++ b/admin/views/index.php @@ -18,6 +18,7 @@ + @@ -32,6 +33,7 @@ + @@ -154,6 +156,10 @@
@@ -225,22 +233,26 @@
-
+
@@ -277,17 +290,19 @@
--> @@ -313,20 +329,25 @@
- - + + 上传图片 - - + + 上传pdf -
    +
    • - - + +
    • @@ -513,7 +534,10 @@ // } this.info.loan_info.loan_time = loan_time; } - $.post("/receiver/orderv2/orders/edit_loan", {'info': this.info, 'status': status}, function (data) { + $.post("/receiver/orderv2/orders/edit_loan", { + 'info': this.info, + 'status': status + }, function (data) { console.dir(data); if (data.code) { layer.msg(data.msg, function () { @@ -563,18 +587,6 @@ }) }, - show_carimg: function (type) { - layer.photos({ - photos: '#layer-photos-demo-' + type, - anim: 5, //0-6的选择,指定弹出图片动画类型,默认随机(请注意,3.0之前的版本用shift参数) - tab: function () { - xz_num = 0; - $("#layui-layer-photos").parent().append('
      \n' + - '\t\t\n' + - '\t
      '); - } - }); - }, //保存身份证 save_cardID: function () { var that = this; @@ -615,10 +627,10 @@ } }, 'json'); }, - cancelItem:function(){ + cancelItem: function () { var that = this; - layer.confirm('你确定取消分配吗?', {icon: 3, title:'提示'}, function(index){ - $.post("/receiver/orderv2/orders/edit_ckcar", {id:that.info.id}, function (data) { + layer.confirm('你确定取消分配吗?', {icon: 3, title: '提示'}, function (index) { + $.post("/receiver/orderv2/orders/edit_ckcar", {id: that.info.id}, function (data) { if (data.code) { layer.msg(data.msg, {time: 2000, icon: 1}, function () { $.form.reload(); @@ -644,71 +656,12 @@ } }); }); - //旋转图片 - $(document).on("click", "#" + xz_name, function (e) { - console.log("xz_num=" + xz_num); - xz_num = (xz_num + 90) % 360; - $(".layui-layer.layui-layer-page.layui-layer-photos").css('background', 'black');//旋转之后背景色设置为黑色,不然在旋转长方形图片时会留下白色空白 - $("#layui-layer-photos").css('transform', 'rotate(' + xz_num + 'deg)'); - }); - //图片放大缩小 - $(document).on("mousewheel DOMMouseScroll", ".layui-layer-phimg", function (e) { - var delta = (e.originalEvent.wheelDelta && (e.originalEvent.wheelDelta > 0 ? 1 : -1)) || // chrome & ie - (e.originalEvent.detail && (e.originalEvent.detail > 0 ? -1 : 1)); // firefox - var imagep = $(".layui-layer-phimg").parent().parent(); - var image = $(".layui-layer-phimg").parent(); - var h = image.height(); - var w = image.width(); - var img_url = $("#imglayer").attr("src"); - // 创建对象 - var img = new Image(); - // 改变图片的src - img.src = img_url; - var width = img.width; - var height = img.height; - debugger; - if (delta > 0) { - if (h < (window.innerHeight)) { - h = h * 1.05; - w = w * 1.05; - width = width * 1.05; - height = height * 1.05; - } - } else if (delta < 0) { - if (h > 100) { - h = h * 0.95; - w = w * 0.95; - width = width * 0.95; - height = height * 0.95; - } - } - imagep.css("top", (window.innerHeight - h) / 2); - imagep.css("left", (window.innerWidth - w) / 2); - image.height(h); - image.width(w); - imagep.height(h); - imagep.width(w); - var current = $("#current").val(); - if ((current / 90) % 2 == 1) { - $('#imglayer').css("width", h); - $('#imglayer').css("margin-top", -(w - h) / 2); - if (height < width) { - $('#imglayer').css("margin-left", (w - h) / 2); - } - } else { - $('#imglayer').css("width", w); - $('#imglayer').css("margin-top", 0); - if (height < width) { - $('#imglayer').css("margin-left", 0); - } - } - }); function upBill(obj) { var loading = layer.msg('图片识别中..', { icon: 16 - ,shade: 0.3 - ,time: false + , shade: 0.3 + , time: false }); var value = $(obj).val(); var that = this; @@ -726,11 +679,12 @@ } }, 'json'); } + function edit_bill_img(obj) { var loading = layer.msg('上传中', { icon: 16 - ,shade: 0.3 - ,time: false + , shade: 0.3 + , time: false }); var value = $(obj).val(); $.post("/receiver/orderv2/orders/edit_bill_img", { @@ -747,4 +701,4 @@ } }, 'json'); } - + \ No newline at end of file diff --git a/admin/views/receiver/orderv2/get/loaninfo.php b/admin/views/receiver/orderv2/get/loaninfo.php index 214c8e1d..01065bf7 100644 --- a/admin/views/receiver/orderv2/get/loaninfo.php +++ b/admin/views/receiver/orderv2/get/loaninfo.php @@ -41,14 +41,14 @@
- +
- +
@@ -56,85 +56,93 @@
- - - -
- -
- - -
-
-
-
- - -
- - +
+
+ + +
+
+ + + +
+ +
+ + +
+
+