| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146 |
- <!doctype html>
- <html lang="en" class="feedback">
- <head>
- <meta charset="UTF-8" />
- <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
- <title>问题反馈</title>
- <link rel="stylesheet" type="text/css" href="../css/mui.min.css" />
- <link href="../css/feedback-page.css" rel="stylesheet" />
- <style>
- p {
- font-size: 16px;
- color: #fe6604;
- }
-
- .mui-bar-nav {
- background-color: #00a1cb;
- color: #fff!important;
- }
- </style>
- </head>
- <body>
- <header class="mui-bar mui-bar-nav" style="">
- <a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left" style="color: #fff;"></a>
- <h1 class="mui-title" style="color: #fff;">办理工单</h1>
- </header>
- <div class="mui-content">
- <p>办理人(必填)</p>
- <div class="mui-input-row">
- <input id='contact' type="text" class="mui-input-clear contact" />
- </div>
- <p>办理内容(必填)</p>
- <div class="row mui-input-row">
- <textarea id='question' class="mui-input-clear question" placeholder="请详细描述你的问题和意见..."></textarea>
- </div>
- <div class="feedback">
- <p>添加图片(选填,提供问题截图,单张20M以下,最多上传5张)</p>
- <div id='image-list' class="row image-list"></div>
- </div>
- <div class="" style="padding: 10px;">
- <br />
- <button id="submit" type="button" class="mui-btn mui-btn-block mui-btn-primary submit">办理</button>
- </div>
- </div>
- <script src="../js/huayi.config.js"></script>
- <script src="../js/zepto.js"></script>
- <script src="../js/mui.min.js"></script>
- <script src="../js/feedback-page.js"></script>
- <script type="text/javascript">
- mui.init(
-
- );
- mui.plusReady(function() {
- var wv = plus.webview.currentWebview();
- var vText = wv.name;
- var token = wv.token;
- var Str = '';
- var str_ary;
- document.getElementById("submit").addEventListener('tap', function() {
- var username = $("#contact").val();
- var question = $("#question").val();
- $(".image-box").each(function(i, n) {
- var a = $(n).attr("indexs");
- if(a) {
- Str += a + ',';
- }
- });
- str_ary = Str.substring(0, Str.length - 1);
- // alert(str_ary);
- if(!username) {
- plus.nativeUI.toast('输入办理人');
- } else if(!question) {
- plus.nativeUI.toast('输入内容');
- } else{
- mui.ajax(huayi.config.callcenter_url + 'WorkOrder/DealWorkOrder', {
- data: {
- workorderid: vText,
- dealman: username, //办理人
- result: question, //办理内容
- state: 1,
- files: str_ary,
- token: token
- },
- dataType: 'json', //服务器返回json格式数据
- type: 'post', //HTTP请求类型
- timeout: 10000, //超时时间设置为10秒;
- success: function(data) {
- var btnArray = ['否', '是'];
- mui.confirm('是否办理工单', '提示', btnArray, function(e) {
- if(e.index == 1) {
- plus.nativeUI.toast('办理成功');
- // 页面跳转1
- var wobj = plus.webview.getWebviewById("Work-list");
- wobj.reload(true);
- // 页面跳转2
- // var isdeal = 0;
- // var nwaiting = plus.nativeUI.showWaiting();
- // webviewShow = plus.webview.create("Work-list.html?isdeal="+isdeal); //后台创建webview并打开show.html
- // webviewShow.addEventListener("loaded", function() { //注册新webview的载入完成事件
- // nwaiting.close(); //新webview的载入完毕后关闭等待框
- // webviewShow.show("slide-in-right", 300); //把新webview窗体显示出来,显示动画效果为速度300毫秒的右侧移入动画
- //
- // }, false);
- // 页面跳转3
- // var isdeal = 0;
- // mui.openWindow({
- // id: 'Work-list',
- // url: 'Work-list.html',
- // show: {
- // aniShow: 'pop-in'
- // },
- // styles: {
- // popGesture: 'hide'
- // },
- // waiting: {
- // autoShow: true
- // },
- // extras: {
- // isdeal: isdeal,
- //
- // }
- // });
- $("#contact").val("");
- $("#question").val("");
- } else {
- plus.nativeUI.toast('取消办理');
- }
- })
- },
- error: function(xhr, type, errorThrown) {
- }
- });
- }
-
-
- })
- })
- </script>
- </body>
- </html>
|