From e861eaba930d753ad7b892afa98b739bad1e26f9 Mon Sep 17 00:00:00 2001 From: zmt Date: Fri, 20 May 2022 18:06:05 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0closeTcp?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../assets/apps/__UNI__2B9497D/www/app-service.js | 2 +- .../assets/apps/__UNI__2B9497D/www/app-view.js | 2 +- .../apps/__UNI__2B9497D/www/pages/index/scan.js | 2 +- .../www/pages/sample/ext-component.js | 2 +- .../__UNI__2B9497D/www/pages/sample/ext-module.js | 2 +- .../unipluginDemo/pages/sample/ext-module-vue.vue | 20 ++++++-- .../io/dcloud/zmt_module/tcpServer/TCPTask.java | 10 ++++ .../io/dcloud/zmt_module/tcpServer/TcpServer.java | 58 +++++++++++----------- .../main/java/io/dcloud/zmt_module/zmtClass.java | 31 ++++++++++-- 9 files changed, 88 insertions(+), 41 deletions(-) diff --git a/app/src/main/assets/apps/__UNI__2B9497D/www/app-service.js b/app/src/main/assets/apps/__UNI__2B9497D/www/app-service.js index a6b1018..83876f8 100644 --- a/app/src/main/assets/apps/__UNI__2B9497D/www/app-service.js +++ b/app/src/main/assets/apps/__UNI__2B9497D/www/app-service.js @@ -1 +1 @@ -(this["webpackJsonp"]=this["webpackJsonp"]||[]).push([["app-service"],{"00f8":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=n("af3c"),s=uni.requireNativePlugin("Zmt-Module"),a=uni.requireNativePlugin("TestModule"),r=uni.requireNativePlugin("uniplugin_module_ox"),o=uni.requireNativePlugin("Face-Module"),c=uni.requireNativePlugin("modal"),u={onLoad:function(){this.initAPPListener()},onReady:function(){this.logs.push("\u5f53\u524d\u65f6\u95f4:"+this.getTime())},data:function(){return{logs:["LOG VIEW"]}},methods:{initAPPListener:function(){var t=this;plus.globalEvent.addEventListener("myEvent",(function(e){c.toast({message:"TestEvent\u6536\u5230\uff1a"+JSON.stringify(e),duration:3.5}),t.log("\u5168\u5c40\u4e8b\u4ef6\u63a5\u6536:"+JSON.stringify(e))}))},faceAsyncFunc:function(){var t=this;this.log("\u6267\u884cfaceModule.faceAsyncFunc"),o.faceAsyncFunc({name:"unimp",age:1},(function(e){c.toast({message:e,duration:1.5}),t.log(JSON.stringify(e))}))},tcpAsyncFunc:function(){var t=this;this.log("\u5f00\u542fTcp Server."),s.tcpAsyncFunc({port:"16666",name:"unimp",age:1},(function(e){c.toast({message:e,duration:2}),t.log("invoke:"+JSON.stringify(e))}))},testFun2:function(){var t=s.testSyncFunc({name:"unimp",age:1});c.toast({message:t,duration:1.5})},testAsyncFunc:function(){a.testAsyncFunc({name:"unimp",age:1},(function(t){c.toast({message:t,duration:1.5})}))},testSyncFunc:function(){var t=a.testSyncFunc({name:"unimp",age:1});c.toast({message:t,duration:1.5})},testAsyncFunc2:function(){r.testAsyncFunc2({name:"unimp",age:1},(function(t){c.toast({message:t,duration:1.5})}))},testSyncFunc2:function(){var t=r.testSyncFunc2({name:"unimp",age:1});c.toast({message:t,duration:1.5})},log:function(t){this.logs.push(this.getTime()+" ".concat(t))},getTime:function(){return(0,i.timeFormat)(new Date,"mm/dd hh:MM:ss")},gotoNativePage:function(){a.gotoNativePage()}}};e.default=u},"0101":function(t,e,n){"use strict";n.r(e);var i=n("e219"),s=n("b505");for(var a in s)"default"!==a&&function(t){n.d(e,t,(function(){return s[t]}))}(a);var r,o=n("f0c5"),c=Object(o["a"])(s["default"],i["b"],i["c"],!1,null,null,null,!1,i["a"],r);e["default"]=c.exports},"0348":function(t,e,n){"use strict";n.r(e);var i=n("585a"),s=n("4aaa");for(var a in s)"default"!==a&&function(t){n.d(e,t,(function(){return s[t]}))}(a);var r,o=n("f0c5"),c=Object(o["a"])(s["default"],i["b"],i["c"],!1,null,null,null,!1,i["a"],r);e["default"]=c.exports},"0d6a":function(t,e,n){"use strict";var i;n.d(e,"b",(function(){return s})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return i}));var s=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("view",{staticClass:t._$s(0,"sc","button-sp-area"),attrs:{_i:0}},[n("button",{attrs:{_i:1},on:{click:function(e){return t.showRichAlert()}}})])},a=[]},"0de9":function(t,e,n){"use strict";function i(t){var e=Object.prototype.toString.call(t);return e.substring(8,e.length-1)}function s(){return"string"===typeof __channelId__&&__channelId__}function a(t,e){switch(i(e)){case"Function":return"function() { [native code] }";default:return e}}function r(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),i=1;i1){var u=o.pop();c=o.join("---COMMA---"),0===u.indexOf(" at ")?c+=u:c+="---COMMA---"+u}else c=o[0];console[r](c)}n.r(e),n.d(e,"log",(function(){return r})),n.d(e,"default",(function(){return o}))},"40fd":function(t,e,n){"use strict";n.r(e);var i=n("4422"),s=n.n(i);for(var a in i)"default"!==a&&function(t){n.d(e,t,(function(){return i[t]}))}(a);e["default"]=s.a},4422:function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n={data:function(){return{optionQuery:{},ballList:[],page:1,pageTotal:1,isShowBtn:!1}},onLoad:function(t){t.stadium_id,t.brand_id},onReachBottom:function(){},methods:{returnBtn:function(){uni.navigateBack()},getList:function(e){var n=this,i=e.page,s=void 0===i?1:i,a=e.page_size,r=void 0===a?10:a,o=this.optionQuery;util.showLoad(),servers.post({url:API.tidList,data:{brand_id:o.brand_id,stadium_id:o.stadium_id,goods_name:"\u7bee\u7403\u5f55\u5165",page:s,page_size:r},failMsg:"\u52a0\u8f7d\u5931\u8d25\uff01"}).then((function(e){util.hideLoad(),n.pageTotal=Math.ceil(e.total/10);var i=e.list||[];return t("log","\u6b66\u6c49\u51e1\u8c37\uff1a",JSON.stringify(e)," at pages/index/ball_list.vue:102"),1==s?(i.length>0&&(n.isShowBtn=!0),n.ballList=i):i.length<=0?util.showNone("\u6ca1\u6709\u66f4\u591a\uff01"):(n.page=s,void(n.ballList=i))})).catch((function(e){t("error","\u7bee\u7403\u5217\u8868-err\uff1f",e," at pages/index/ball_list.vue:116")}))}}};e.default=n}).call(this,n("0de9")["default"])},"4aaa":function(t,e,n){"use strict";n.r(e);var i=n("00f8"),s=n.n(i);for(var a in i)"default"!==a&&function(t){n.d(e,t,(function(){return i[t]}))}(a);e["default"]=s.a},5215:function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n={data:function(){return{list:[{id:"ext-module",name:"\u6269\u5c55 module\u6d4b\u8bd5\u5217\u8868",open:!1,url:"/pages/sample/ext-module-vue"},{id:"ext-component",name:"\u6269\u5c55 component",open:!1,url:"/pages/sample/ext-component"},{id:"richAlert",name:"\u63d2\u4ef6\u793a\u4f8bRichAlert",open:!1,url:"/pages/sample/richAlert"}],navigateFlag:!1}},onLoad:function(){},methods:{goScan:function(){t("log",111," at pages/index/index.vue:59"),uni.navigateTo({url:"./scan"})},goBallList:function(){t("log",111," at pages/index/index.vue:66"),uni.navigateTo({url:"./ball_list"})},testScanCancle:function(){uni.scanCode({onlyFromCamera:!0,success:function(e){t("log","\u6761\u7801\u7c7b\u578b\uff1a"+e.scanType," at pages/index/index.vue:76"),t("log","\u6761\u7801\u5185\u5bb9\uff1a"+e.result," at pages/index/index.vue:77")}}),setTimeout((function(){t("log","\u6267\u884c\u8fd4\u56de"," at pages/index/index.vue:81"),uni.navigateBack(),uni.navigateBack()}),3e3)},triggerCollapse:function(t){if(this.list[t].pages)for(var e=0;e0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"yyyy-mm-dd";t||(t=Number(new Date)),"string"==typeof t&&t.indexOf("-")>0&&(t=t.replace(/\-/g,"/")),10==t.toString().length&&(t*=1e3);var n,i=new Date(t),s={"y+":i.getFullYear().toString(),"m+":(i.getMonth()+1).toString(),"d+":i.getDate().toString(),"h+":i.getHours().toString(),"M+":i.getMinutes().toString(),"s+":i.getSeconds().toString()};for(var a in s)n=new RegExp("("+a+")").exec(e),n&&(e=e.replace(n[1],1==n[1].length?s[a]:s[a].padStart(n[1].length,"0")));return e}function s(t){var e="",n=parseInt(t/3600),i=parseInt(t%3600/60),s=parseInt(t%3600%60);return n>0&&(n=n<10?"0"+n:n,e+=n+":"),i=i<10?"0"+i:i,s=s<10?"0"+s:s,e+=i+":"+s,e}Object.defineProperty(e,"__esModule",{value:!0}),e.timeFormat=i,e.getDurationTime=s,String.prototype.padStart||(String.prototype.padStart=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:" ";if("[object String]"!==Object.prototype.toString.call(e))throw new TypeError("fillString must be String");var n=this;if(n.length>=t)return String(n);var i=t-n.length,s=Math.ceil(i/e.length);while(s>>=1)e+=e,1===s&&(e+=e);return e.slice(0,i)+n})},b354:function(t,e,n){"use strict";n.r(e);var i=n("d479"),s=n.n(i);for(var a in i)"default"!==a&&function(t){n.d(e,t,(function(){return i[t]}))}(a);e["default"]=s.a},b505:function(t,e,n){"use strict";n.r(e);var i=n("5215"),s=n.n(i);for(var a in i)"default"!==a&&function(t){n.d(e,t,(function(){return i[t]}))}(a);e["default"]=s.a},bc8b:function(t,e,n){"use strict";n.r(e);var i=n("e10d"),s=n.n(i);for(var a in i)"default"!==a&&function(t){n.d(e,t,(function(){return i[t]}))}(a);e["default"]=s.a},d479:function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n={onLaunch:function(){t("log","App Launch"," at App.vue:4")},onShow:function(){t("log","App Show"," at App.vue:7")},onHide:function(){t("log","App Hide"," at App.vue:10")}};e.default=n}).call(this,n("0de9")["default"])},e10d:function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=uni.requireNativePlugin("modal"),i=uni.requireNativePlugin("DCloud-RichAlert"),s={data:function(){return{title:""}},onLoad:function(){},methods:{showRichAlert:function(){i.show({position:"bottom",title:"\u63d0\u793a\u4fe1\u606f",titleColor:"#FF0000",content:"uni-app \u662f\u4e00\u4e2a\u4f7f\u7528 Vue.js \u5f00\u53d1\u8de8\u5e73\u53f0\u5e94\u7528\u7684\u524d\u7aef\u6846\u67b6!\n\u514d\u8d39\u7684\n\u514d\u8d39\u7684\n\u514d\u8d39\u7684\n\u91cd\u8981\u7684\u4e8b\u60c5\u8bf4\u4e09\u904d",contentAlign:"left",checkBox:{title:"\u4e0d\u518d\u63d0\u793a",isSelected:!0},buttons:[{title:"\u53d6\u6d88"},{title:"\u5426"},{title:"\u786e\u8ba4",titleColor:"#3F51B5"}]},(function(e){var i=JSON.stringify(e);switch(n.toast({message:i,duration:1.5}),e.type){case"button":t("log","callback---button--"+e.index," at pages/sample/richAlert.vue:50");break;case"checkBox":t("log","callback---checkBox--"+e.isSelected," at pages/sample/richAlert.vue:53");break;case"a":t("log","callback---a--"+JSON.stringify(e)," at pages/sample/richAlert.vue:56");break;case"backCancel":t("log","callback---backCancel--"," at pages/sample/richAlert.vue:59");break}}))}}};e.default=s}).call(this,n("0de9")["default"])},e219:function(t,e,n){"use strict";var i;n.d(e,"b",(function(){return s})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return i}));var s=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("view",{staticClass:t._$s(0,"sc","uni-container"),attrs:{_i:0}},[n("view",{staticClass:t._$s(1,"sc","uni-hello-text"),attrs:{_i:1}},[n("text",{staticClass:t._$s(2,"sc","hello-text"),attrs:{_i:2}})]),t._l(t._$s(3,"f",{forItems:t.list}),(function(e,i,s,a){return n("view",{key:t._$s(3,"f",{forIndex:s,key:e.id}),staticClass:t._$s("3-"+a,"sc","uni-panel"),attrs:{_i:"3-"+a}},[n("view",{staticClass:t._$s("4-"+a,"sc","uni-panel-h"),class:t._$s("4-"+a,"c",e.open?"uni-panel-h-on":""),attrs:{_i:"4-"+a},on:{click:function(e){return t.triggerCollapse(i)}}},[n("text",{staticClass:t._$s("5-"+a,"sc","uni-panel-text"),attrs:{_i:"5-"+a}},[t._v(t._$s("5-"+a,"t0-0",t._s(e.name)))]),n("text",{staticClass:t._$s("6-"+a,"sc","uni-panel-icon uni-icon"),class:t._$s("6-"+a,"c",e.open?"uni-panel-icon-on":""),attrs:{_i:"6-"+a}},[t._v(t._$s("6-"+a,"t0-0",t._s(e.pages?"\ue581":"\ue470")))])]),t._$s("7-"+a,"i",e.open)?n("view",{staticClass:t._$s("7-"+a,"sc","uni-panel-c"),attrs:{_i:"7-"+a}},t._l(t._$s("8-"+a,"f",{forItems:e.pages}),(function(e,i,s,r){return n("view",{key:t._$s("8-"+a,"f",{forIndex:s,key:i}),staticClass:t._$s("8-"+a+"-"+r,"sc","uni-navigate-item"),attrs:{_i:"8-"+a+"-"+r},on:{click:function(n){return t.goDetailPage(e.url)}}},[n("text",{staticClass:t._$s("9-"+a+"-"+r,"sc","uni-navigate-text"),attrs:{_i:"9-"+a+"-"+r}},[t._v(t._$s("9-"+a+"-"+r,"t0-0",t._s(e.name?e.name:e)))]),n("text",{staticClass:t._$s("10-"+a+"-"+r,"sc","uni-navigate-icon uni-icon"),attrs:{_i:"10-"+a+"-"+r}})])})),0):t._e()])})),n("view",{staticClass:t._$s(11,"sc","uni-panel"),attrs:{_i:11}},[n("view",{staticClass:t._$s(12,"sc","uni-panel-h"),attrs:{_i:12},on:{click:function(e){return t.testScanCancle()}}}),n("view",{staticClass:t._$s(13,"sc","uni-panel-h"),attrs:{_i:13},on:{click:function(e){return t.goScan()}}}),n("view",{staticClass:t._$s(14,"sc","uni-panel-h"),attrs:{_i:14},on:{click:function(e){return t.goBallList()}}})])],2)},a=[]},f0c5:function(t,e,n){"use strict";function i(t,e,n,i,s,a,r,o,c,u){var l,f="function"===typeof t?t.options:t;if(c){f.components||(f.components={});var d=Object.prototype.hasOwnProperty;for(var _ in c)d.call(c,_)&&!d.call(f.components,_)&&(f.components[_]=c[_])}if(u&&((u.beforeCreate||(u.beforeCreate=[])).unshift((function(){this[u.__module]=this})),(f.mixins||(f.mixins=[])).push(u)),e&&(f.render=e,f.staticRenderFns=n,f._compiled=!0),i&&(f.functional=!0),a&&(f._scopeId="data-v-"+a),r?(l=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),s&&s.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(r)},f._ssrRegister=l):s&&(l=o?function(){s.call(this,this.$root.$options.shadowRoot)}:s),l)if(f.functional){f._injectStyles=l;var p=f.render;f.render=function(t,e){return l.call(e),p(t,e)}}else{var g=f.beforeCreate;f.beforeCreate=g?[].concat(g,l):[l]}return{exports:t,options:f}}n.d(e,"a",(function(){return i}))},f608:function(t,e,n){"use strict";n.r(e);var i=n("0d6a"),s=n("bc8b");for(var a in s)"default"!==a&&function(t){n.d(e,t,(function(){return s[t]}))}(a);var r,o=n("f0c5"),c=Object(o["a"])(s["default"],i["b"],i["c"],!1,null,null,null,!1,i["a"],r);e["default"]=c.exports}},[["5a57","app-config"]]]); \ No newline at end of file +(this["webpackJsonp"]=this["webpackJsonp"]||[]).push([["app-service"],{"0a3c":function(t,e,n){"use strict";n("e3f4");var i=a(n("8bbf")),s=a(n("8d89"));function a(t){return t&&t.__esModule?t:{default:t}}function r(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function o(t){for(var e=1;e1?e-1:0),i=1;i1){var u=o.pop();c=o.join("---COMMA---"),0===u.indexOf(" at ")?c+=u:c+="---COMMA---"+u}else c=o[0];console[r](c)}n.r(e),n.d(e,"log",(function(){return r})),n.d(e,"default",(function(){return o}))},"148d":function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=n("c677"),s=uni.requireNativePlugin("Zmt-Module"),a=uni.requireNativePlugin("TestModule"),r=uni.requireNativePlugin("uniplugin_module_ox"),o=uni.requireNativePlugin("Face-Module"),c=uni.requireNativePlugin("modal"),u={onLoad:function(){this.initAPPListener()},onReady:function(){this.logs.push("\u5f53\u524d\u65f6\u95f4:"+this.getTime())},data:function(){return{logs:["LOG VIEW"]}},methods:{initAPPListener:function(){var t=this;plus.globalEvent.addEventListener("myEvent",(function(e){c.toast({message:"TestEvent\u6536\u5230\uff1a"+JSON.stringify(e),duration:3.5}),t.log("\u5168\u5c40\u4e8b\u4ef6\u63a5\u6536:"+JSON.stringify(e))}))},faceAsyncFunc:function(){var t=this;this.log("\u6267\u884cfaceModule.faceAsyncFunc"),o.faceAsyncFunc({name:"unimp",age:1},(function(e){c.toast({message:e,duration:1.5}),t.log(JSON.stringify(e))}))},initTcp:function(){var t=this;this.log("Click Tcp Server."),s.initTcp({port:"16666"},(function(e){c.toast({message:e,duration:2}),t.log("invoke:"+JSON.stringify(e))}))},closeTcp:function(){var t=this;this.log("Click Tcp Server."),s.closeTcp({},(function(e){c.toast({message:e,duration:2}),t.log("invoke:"+JSON.stringify(e))}))},testFun2:function(){var t=s.testSyncFunc({name:"unimp",age:1});c.toast({message:t,duration:1.5})},testAsyncFunc:function(){a.testAsyncFunc({name:"unimp",age:1},(function(t){c.toast({message:t,duration:1.5})}))},testSyncFunc:function(){var t=a.testSyncFunc({name:"unimp",age:1});c.toast({message:t,duration:1.5})},testAsyncFunc2:function(){r.testAsyncFunc2({name:"unimp",age:1},(function(t){c.toast({message:t,duration:1.5})}))},testSyncFunc2:function(){var t=r.testSyncFunc2({name:"unimp",age:1});c.toast({message:t,duration:1.5})},log:function(t){this.logs.push(this.getTime()+" ".concat(t))},getTime:function(){return(0,i.timeFormat)(new Date,"mm/dd hh:MM:ss")},gotoNativePage:function(){a.gotoNativePage()}}};e.default=u},"1e9b":function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n={onLaunch:function(){t("log","App Launch"," at App.vue:4")},onShow:function(){t("log","App Show"," at App.vue:7")},onHide:function(){t("log","App Hide"," at App.vue:10")}};e.default=n}).call(this,n("0de9")["default"])},"3c60":function(t,e,n){"use strict";n.r(e);var i=n("7be9"),s=n("b5df");for(var a in s)"default"!==a&&function(t){n.d(e,t,(function(){return s[t]}))}(a);var r,o=n("f0c5"),c=Object(o["a"])(s["default"],i["b"],i["c"],!1,null,null,null,!1,i["a"],r);e["default"]=c.exports},"40a2":function(t,e,n){"use strict";n.r(e);var i=n("499f"),s=n("c3ad");for(var a in s)"default"!==a&&function(t){n.d(e,t,(function(){return s[t]}))}(a);var r,o=n("f0c5"),c=Object(o["a"])(s["default"],i["b"],i["c"],!1,null,null,null,!1,i["a"],r);e["default"]=c.exports},"499f":function(t,e,n){"use strict";var i;n.d(e,"b",(function(){return s})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return i}));var s=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("view",{staticClass:t._$s(0,"sc","ball-list"),attrs:{_i:0}},[n("view",{staticClass:t._$s(1,"sc","bl-line"),attrs:{_i:1}},[n("view"),n("view",{attrs:{_i:3},on:{click:t.returnBtn}})]),n("view",{staticClass:t._$s(4,"sc","bl-tab"),attrs:{_i:4}},[n("view"),n("view"),n("view"),n("view")]),n("scroll-view",{staticClass:t._$s(9,"sc","bl-scroll"),attrs:{_i:9}},[n("view",{staticClass:t._$s(10,"sc","bl-list"),attrs:{_i:10}},[t._l(3,(function(e,i,s,a){return n("view",{key:i,staticClass:t._$s("11-"+a,"sc","bll-item"),attrs:{_i:"11-"+a}},[n("view",{class:t._$s("12-"+a,"c",[i==t.ballList.length-1?"fillet-left":""]),attrs:{_i:"12-"+a}},[t._v(t._$s("12-"+a,"t0-0",t._s(e.goods_name||"555")))]),n("view",[t._v(t._$s("13-"+a,"t0-0",t._s(e.tid_string||"\u5408\u6cd5\u5927\u4f7f\u9986sfghdsfghdjsgdksjdjghdfjkghfd2021-11-11 11:22:54")))]),n("view",[t._v(t._$s("14-"+a,"t0-0",t._s(e.created_at||"123213")))]),n("view",{class:t._$s("15-"+a,"c",[i==t.ballList.length-1?"fillet-right":""]),attrs:{_i:"15-"+a}},[t._v(t._$s("15-"+a,"t0-0",t._s(e.operator_name||"544")))])])})),n("view",{staticClass:t._$s(16,"sc","info-list"),attrs:{_i:16}},t._l(3,(function(e,i,s,a){return n("view",{staticClass:t._$s("17-"+a,"sc","i-item"),attrs:{_i:"17-"+a}},[n("view",{staticClass:t._$s("18-"+a,"sc","i-box"),attrs:{_i:"18-"+a}}),n("view",{staticClass:t._$s("19-"+a,"sc","i-box"),attrs:{_i:"19-"+a}}),n("view",{staticClass:t._$s("20-"+a,"sc","i-box"),attrs:{_i:"20-"+a}}),n("view",{staticClass:t._$s("21-"+a,"sc","i-box"),attrs:{_i:"21-"+a}},[t._v(t._$s("21-"+a,"t0-0",t._s(e[2])))])])})),0)],2)]),t._$s(22,"i",t.isShowBtn)?n("view",{staticClass:t._$s(22,"sc","bl-btn"),attrs:{_i:22}},[n("view",{attrs:{_i:23},on:{click:function(e){return t.btnChange(1)}}}),n("view",[n("text",[t._v(t._$s(25,"t0-0",t._s(t.page||0)))]),n("text",[t._v(t._$s(26,"t0-0",t._s(t.pageTotal||0)))])]),n("view",{attrs:{_i:27},on:{click:function(e){return t.btnChange(2)}}})]):t._e()])},a=[]},5564:function(t,e,n){"use strict";n.r(e);var i=n("741d"),s=n.n(i);for(var a in i)"default"!==a&&function(t){n.d(e,t,(function(){return i[t]}))}(a);e["default"]=s.a},"741d":function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n={data:function(){return{list:[{id:"ext-module",name:"\u6269\u5c55 module\u6d4b\u8bd5\u5217\u8868",open:!1,url:"/pages/sample/ext-module-vue"},{id:"ext-component",name:"\u6269\u5c55 component",open:!1,url:"/pages/sample/ext-component"},{id:"richAlert",name:"\u63d2\u4ef6\u793a\u4f8bRichAlert",open:!1,url:"/pages/sample/richAlert"}],navigateFlag:!1}},onLoad:function(){},methods:{goScan:function(){t("log",111," at pages/index/index.vue:59"),uni.navigateTo({url:"./scan"})},goBallList:function(){t("log",111," at pages/index/index.vue:66"),uni.navigateTo({url:"./ball_list"})},testScanCancle:function(){uni.scanCode({onlyFromCamera:!0,success:function(e){t("log","\u6761\u7801\u7c7b\u578b\uff1a"+e.scanType," at pages/index/index.vue:76"),t("log","\u6761\u7801\u5185\u5bb9\uff1a"+e.result," at pages/index/index.vue:77")}}),setTimeout((function(){t("log","\u6267\u884c\u8fd4\u56de"," at pages/index/index.vue:81"),uni.navigateBack(),uni.navigateBack()}),3e3)},triggerCollapse:function(t){if(this.list[t].pages)for(var e=0;e0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"yyyy-mm-dd";t||(t=Number(new Date)),"string"==typeof t&&t.indexOf("-")>0&&(t=t.replace(/\-/g,"/")),10==t.toString().length&&(t*=1e3);var n,i=new Date(t),s={"y+":i.getFullYear().toString(),"m+":(i.getMonth()+1).toString(),"d+":i.getDate().toString(),"h+":i.getHours().toString(),"M+":i.getMinutes().toString(),"s+":i.getSeconds().toString()};for(var a in s)n=new RegExp("("+a+")").exec(e),n&&(e=e.replace(n[1],1==n[1].length?s[a]:s[a].padStart(n[1].length,"0")));return e}function s(t){var e="",n=parseInt(t/3600),i=parseInt(t%3600/60),s=parseInt(t%3600%60);return n>0&&(n=n<10?"0"+n:n,e+=n+":"),i=i<10?"0"+i:i,s=s<10?"0"+s:s,e+=i+":"+s,e}Object.defineProperty(e,"__esModule",{value:!0}),e.timeFormat=i,e.getDurationTime=s,String.prototype.padStart||(String.prototype.padStart=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:" ";if("[object String]"!==Object.prototype.toString.call(e))throw new TypeError("fillString must be String");var n=this;if(n.length>=t)return String(n);var i=t-n.length,s=Math.ceil(i/e.length);while(s>>=1)e+=e,1===s&&(e+=e);return e.slice(0,i)+n})},c8cc:function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=uni.requireNativePlugin("modal"),i=uni.requireNativePlugin("DCloud-RichAlert"),s={data:function(){return{title:""}},onLoad:function(){},methods:{showRichAlert:function(){i.show({position:"bottom",title:"\u63d0\u793a\u4fe1\u606f",titleColor:"#FF0000",content:"uni-app \u662f\u4e00\u4e2a\u4f7f\u7528 Vue.js \u5f00\u53d1\u8de8\u5e73\u53f0\u5e94\u7528\u7684\u524d\u7aef\u6846\u67b6!\n\u514d\u8d39\u7684\n\u514d\u8d39\u7684\n\u514d\u8d39\u7684\n\u91cd\u8981\u7684\u4e8b\u60c5\u8bf4\u4e09\u904d",contentAlign:"left",checkBox:{title:"\u4e0d\u518d\u63d0\u793a",isSelected:!0},buttons:[{title:"\u53d6\u6d88"},{title:"\u5426"},{title:"\u786e\u8ba4",titleColor:"#3F51B5"}]},(function(e){var i=JSON.stringify(e);switch(n.toast({message:i,duration:1.5}),e.type){case"button":t("log","callback---button--"+e.index," at pages/sample/richAlert.vue:50");break;case"checkBox":t("log","callback---checkBox--"+e.isSelected," at pages/sample/richAlert.vue:53");break;case"a":t("log","callback---a--"+JSON.stringify(e)," at pages/sample/richAlert.vue:56");break;case"backCancel":t("log","callback---backCancel--"," at pages/sample/richAlert.vue:59");break}}))}}};e.default=s}).call(this,n("0de9")["default"])},e3f4:function(t,e,n){"undefined"===typeof Promise||Promise.prototype.finally||(Promise.prototype.finally=function(t){var e=this.constructor;return this.then((function(n){return e.resolve(t()).then((function(){return n}))}),(function(n){return e.resolve(t()).then((function(){throw n}))}))}),uni.restoreGlobal&&uni.restoreGlobal(weex,plus,setTimeout,clearTimeout,setInterval,clearInterval),__definePage("pages/sample/ext-module-vue",(function(){return Vue.extend(n("3c60").default)})),__definePage("pages/index/index",(function(){return Vue.extend(n("8db1").default)})),__definePage("pages/index/ball_list",(function(){return Vue.extend(n("40a2").default)})),__definePage("pages/sample/richAlert",(function(){return Vue.extend(n("9a1b").default)}))},e678:function(t,e,n){"use strict";var i;n.d(e,"b",(function(){return s})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return i}));var s=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("view",{staticClass:t._$s(0,"sc","button-sp-area"),attrs:{_i:0}},[n("button",{attrs:{_i:1},on:{click:function(e){return t.showRichAlert()}}})])},a=[]},f0c5:function(t,e,n){"use strict";function i(t,e,n,i,s,a,r,o,c,u){var l,f="function"===typeof t?t.options:t;if(c){f.components||(f.components={});var d=Object.prototype.hasOwnProperty;for(var p in c)d.call(c,p)&&!d.call(f.components,p)&&(f.components[p]=c[p])}if(u&&((u.beforeCreate||(u.beforeCreate=[])).unshift((function(){this[u.__module]=this})),(f.mixins||(f.mixins=[])).push(u)),e&&(f.render=e,f.staticRenderFns=n,f._compiled=!0),i&&(f.functional=!0),a&&(f._scopeId="data-v-"+a),r?(l=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),s&&s.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(r)},f._ssrRegister=l):s&&(l=o?function(){s.call(this,this.$root.$options.shadowRoot)}:s),l)if(f.functional){f._injectStyles=l;var _=f.render;f.render=function(t,e){return l.call(e),_(t,e)}}else{var g=f.beforeCreate;f.beforeCreate=g?[].concat(g,l):[l]}return{exports:t,options:f}}n.d(e,"a",(function(){return i}))},f5b2:function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n={data:function(){return{optionQuery:{},ballList:[],page:1,pageTotal:1,isShowBtn:!1}},onLoad:function(t){t.stadium_id,t.brand_id},onReachBottom:function(){},methods:{returnBtn:function(){uni.navigateBack()},getList:function(e){var n=this,i=e.page,s=void 0===i?1:i,a=e.page_size,r=void 0===a?10:a,o=this.optionQuery;util.showLoad(),servers.post({url:API.tidList,data:{brand_id:o.brand_id,stadium_id:o.stadium_id,goods_name:"\u7bee\u7403\u5f55\u5165",page:s,page_size:r},failMsg:"\u52a0\u8f7d\u5931\u8d25\uff01"}).then((function(e){util.hideLoad(),n.pageTotal=Math.ceil(e.total/10);var i=e.list||[];return t("log","\u6b66\u6c49\u51e1\u8c37\uff1a",JSON.stringify(e)," at pages/index/ball_list.vue:102"),1==s?(i.length>0&&(n.isShowBtn=!0),n.ballList=i):i.length<=0?util.showNone("\u6ca1\u6709\u66f4\u591a\uff01"):(n.page=s,void(n.ballList=i))})).catch((function(e){t("error","\u7bee\u7403\u5217\u8868-err\uff1f",e," at pages/index/ball_list.vue:116")}))}}};e.default=n}).call(this,n("0de9")["default"])}},[["0a3c","app-config"]]]); \ No newline at end of file diff --git a/app/src/main/assets/apps/__UNI__2B9497D/www/app-view.js b/app/src/main/assets/apps/__UNI__2B9497D/www/app-view.js index e02d950..c30699f 100644 --- a/app/src/main/assets/apps/__UNI__2B9497D/www/app-view.js +++ b/app/src/main/assets/apps/__UNI__2B9497D/www/app-view.js @@ -1 +1 @@ -(function(t){var n={};function e(i){if(n[i])return n[i].exports;var r=n[i]={i:i,l:!1,exports:{}};return t[i].call(r.exports,r,r.exports,e),r.l=!0,r.exports}e.m=t,e.c=n,e.d=function(t,n,i){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:i})},e.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n)return t;if(4&n&&"object"===typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(e.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var r in t)e.d(i,r,function(n){return t[n]}.bind(null,r));return i},e.n=function(t){var n=t&&t.__esModule?function(){return t["default"]}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},e.p="./",e(e.s="5a57")})({"0101":function(t,n,e){"use strict";e.r(n);var i=e("e219"),r=e("b505");for(var o in r)"default"!==o&&function(t){e.d(n,t,(function(){return r[t]}))}(o);e("e52d");var a,s=e("f0c5"),l=Object(s["a"])(r["default"],i["b"],i["c"],!1,null,null,null,!1,i["a"],a);n["default"]=l.exports},"0348":function(t,n,e){"use strict";e.r(n);var i=e("585a"),r=e("4aaa");for(var o in r)"default"!==o&&function(t){e.d(n,t,(function(){return r[t]}))}(o);e("76cb");var a,s=e("f0c5"),l=Object(s["a"])(r["default"],i["b"],i["c"],!1,null,null,null,!1,i["a"],a);n["default"]=l.exports},"0353":function(t,n,e){var i=e("7757");"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var r=e("7f7e").default;r("50970dee",i,!0,{sourceMap:!1,shadowMode:!1})},"06b2":function(t,n,e){var i=e("1575");"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var r=e("7f7e").default;r("b2f7858c",i,!0,{sourceMap:!1,shadowMode:!1})},"0962":function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default=void 0;var i={data:function(){return{wxsProps:{}}},components:{}};n.default=i},"0d6a":function(t,n,e){"use strict";var i;e.d(n,"b",(function(){return r})),e.d(n,"c",(function(){return o})),e.d(n,"a",(function(){return i}));var r=function(){var t=this,n=t.$createElement,e=t._self._c||n;return e("v-uni-view",{staticClass:t._$g(0,"sc"),attrs:{_i:0}},[e("v-uni-button",{attrs:{type:"primary",plain:"true",_i:1},on:{click:function(n){return t.$handleViewEvent(n)}}},[t._v("\u70b9\u51fb\u663e\u793a\u5f39\u7a97")])],1)},o=[]},1524:function(t,n,e){var i=e("7905");"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var r=e("7f7e").default;r("312004cf",i,!0,{sourceMap:!1,shadowMode:!1})},1575:function(t,n,e){var i=e("24fb");n=i(!1),n.push([t.i,"uni-button{margin-top:30upx;margin-bottom:30upx}.button-sp-area{margin:0 auto;width:60%}.content{text-align:center;height:400upx}.wrapper{flex-direction:column;justify-content:center}.button{width:200px;margin-top:30px;margin-left:20px;padding-top:20px;padding-bottom:20px;border-width:2px;border-style:solid;border-color:#458b00;background-color:#458b00}.text{font-size:30px;color:#666;text-align:center}",""]),t.exports=n},2332:function(t,n,e){"use strict";var i=e("06b2"),r=e.n(i);r.a},"24fb":function(t,n,e){"use strict";function i(t,n){var e=t[1]||"",i=t[3];if(!i)return e;if(n&&"function"===typeof btoa){var o=r(i),a=i.sources.map((function(t){return"/*# sourceURL=".concat(i.sourceRoot||"").concat(t," */")}));return[e].concat(a).concat([o]).join("\n")}return[e].join("\n")}function r(t){var n=btoa(unescape(encodeURIComponent(JSON.stringify(t)))),e="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(n);return"/*# ".concat(e," */")}t.exports=function(t){var n=[];return n.toString=function(){return this.map((function(n){var e=i(n,t);return n[2]?"@media ".concat(n[2]," {").concat(e,"}"):e})).join("")},n.i=function(t,e,i){"string"===typeof t&&(t=[[null,t,""]]);var r={};if(i)for(var o=0;o uni-view:first-child{color:#1a1a1a;font-size:44rpx;line-height:60rpx;font-weight:700}.ball-list .bl-line > uni-view:nth-child(2){color:#009874;font-size:28rpx;line-height:40rpx}.ball-list .bl-tab{margin:0 24rpx;border-top-left-radius:10rpx;border-top-right-radius:10rpx;background-color:#ddd;display:flex;align-items:center;justify-content:flex-start}.ball-list .bl-tab > uni-view{width:174rpx;height:110rpx;color:#1a1a1a;font-size:28rpx;line-height:40rpx;text-align:center;border-right:2rpx solid #f2f2f7;display:flex;align-items:center;justify-content:center}.ball-list .bl-tab > uni-view:last-child{border-right:0rpx solid #f2f2f7}.ball-list .bl-scroll{height:850rpx}.ball-list .bl-list{height:auto}.ball-list .bl-list .bll-item{margin:0 24rpx;display:flex;align-items:center;justify-content:flex-start;background-color:#fff;width:700rpx}.ball-list .bl-list .bll-item > uni-view{padding:0 4rpx;width:174rpx;height:100%;color:#1a1a1a;font-size:24rpx;text-align:center;line-height:34rpx;background-color:#fff;word-wrap:break-word;word-break:break-all;white-space:pre-wrap;display:flex;align-items:center;justify-content:center;flex-direction:row}.ball-list .bl-list .bll-item > uni-view:last-child{border-right:0rpx solid #f2f2f7}.ball-list .bl-list .bll-item > uni-view:not(:last-child){border-bottom:1rpx solid red}.ball-list .bl-list .info-list{margin:0 24rpx;margin-top:30rpx;margin-bottom:50rpx;width:700rpx;height:auto;background:#fff;border-radius:10rpx;font-size:28rpx}.ball-list .bl-list .info-list .i-item{display:flex;align-items:center;justify-content:center;align-items:stretch}.ball-list .bl-list .info-list .i-item .i-box{display:flex;align-items:center;justify-content:center;flex-direction:row;padding:26rpx 10rpx;width:176rpx;height:auto}.ball-list .bl-list .info-list .i-item .i-box:nth-child(2){border:1rpx solid #f2f2f7;border-bottom:none;border-top:none;word-break:break-all}.ball-list .bl-list .info-list .i-item .i-box:nth-child(3){border:1rpx solid #f2f2f7;border-bottom:none;flex-grow:1}.ball-list .bl-list .info-list .i-item .i-box:last-child{flex-grow:1}.ball-list .bl-list .info-list .i-item:not(:last-child){border-bottom:1rpx solid #f2f2f7}.ball-list .bl-btn{position:fixed;bottom:0;left:0;padding:12rpx 0;width:750rpx;background-color:#fff;border-top:2rpx solid #f2f2f7;display:flex;align-items:center;justify-content:center}.ball-list .bl-btn > uni-view{font-size:28rpx;line-height:40rpx;text-align:center}.ball-list .bl-btn > uni-view:first-child{padding:12rpx 0;width:180rpx;color:#009874;background-color:#fff;border:2rpx solid #009874;border-radius:6rpx}.ball-list .bl-btn > uni-view:nth-child(2){margin:0 50rpx}.ball-list .bl-btn > uni-view:nth-child(2) > uni-text{margin:0 2rpx;color:#009874}.ball-list .bl-btn > uni-view:nth-child(3){padding:12rpx 0;width:180rpx;color:#fff;background-color:#009874;border:2rpx solid #009874;border-radius:6rpx}',""]),t.exports=n},"7c39":function(t,n,e){var i=e("527d");"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var r=e("7f7e").default;r("53dca976",i,!0,{sourceMap:!1,shadowMode:!1})},"7f7e":function(t,n,e){"use strict";function i(t,n){for(var e=[],i={},r=0;re.parts.length&&(i.parts.length=e.parts.length)}else{var a=[];for(r=0;r uni-view:first-child{color:#1a1a1a;font-size:44rpx;line-height:60rpx;font-weight:700}.ball-list .bl-line > uni-view:nth-child(2){color:#009874;font-size:28rpx;line-height:40rpx}.ball-list .bl-tab{margin:0 24rpx;border-top-left-radius:10rpx;border-top-right-radius:10rpx;background-color:#ddd;display:flex;align-items:center;justify-content:flex-start}.ball-list .bl-tab > uni-view{width:174rpx;height:110rpx;color:#1a1a1a;font-size:28rpx;line-height:40rpx;text-align:center;border-right:2rpx solid #f2f2f7;display:flex;align-items:center;justify-content:center}.ball-list .bl-tab > uni-view:last-child{border-right:0rpx solid #f2f2f7}.ball-list .bl-scroll{height:850rpx}.ball-list .bl-list{height:auto}.ball-list .bl-list .bll-item{margin:0 24rpx;display:flex;align-items:center;justify-content:flex-start;background-color:#fff;width:700rpx}.ball-list .bl-list .bll-item > uni-view{padding:0 4rpx;width:174rpx;height:100%;color:#1a1a1a;font-size:24rpx;text-align:center;line-height:34rpx;background-color:#fff;word-wrap:break-word;word-break:break-all;white-space:pre-wrap;display:flex;align-items:center;justify-content:center;flex-direction:row}.ball-list .bl-list .bll-item > uni-view:last-child{border-right:0rpx solid #f2f2f7}.ball-list .bl-list .bll-item > uni-view:not(:last-child){border-bottom:1rpx solid red}.ball-list .bl-list .info-list{margin:0 24rpx;margin-top:30rpx;margin-bottom:50rpx;width:700rpx;height:auto;background:#fff;border-radius:10rpx;font-size:28rpx}.ball-list .bl-list .info-list .i-item{display:flex;align-items:center;justify-content:center;align-items:stretch}.ball-list .bl-list .info-list .i-item .i-box{display:flex;align-items:center;justify-content:center;flex-direction:row;padding:26rpx 10rpx;width:176rpx;height:auto}.ball-list .bl-list .info-list .i-item .i-box:nth-child(2){border:1rpx solid #f2f2f7;border-bottom:none;border-top:none;word-break:break-all}.ball-list .bl-list .info-list .i-item .i-box:nth-child(3){border:1rpx solid #f2f2f7;border-bottom:none;flex-grow:1}.ball-list .bl-list .info-list .i-item .i-box:last-child{flex-grow:1}.ball-list .bl-list .info-list .i-item:not(:last-child){border-bottom:1rpx solid #f2f2f7}.ball-list .bl-btn{position:fixed;bottom:0;left:0;padding:12rpx 0;width:750rpx;background-color:#fff;border-top:2rpx solid #f2f2f7;display:flex;align-items:center;justify-content:center}.ball-list .bl-btn > uni-view{font-size:28rpx;line-height:40rpx;text-align:center}.ball-list .bl-btn > uni-view:first-child{padding:12rpx 0;width:180rpx;color:#009874;background-color:#fff;border:2rpx solid #009874;border-radius:6rpx}.ball-list .bl-btn > uni-view:nth-child(2){margin:0 50rpx}.ball-list .bl-btn > uni-view:nth-child(2) > uni-text{margin:0 2rpx;color:#009874}.ball-list .bl-btn > uni-view:nth-child(3){padding:12rpx 0;width:180rpx;color:#fff;background-color:#009874;border:2rpx solid #009874;border-radius:6rpx}',""]),t.exports=e},2275:function(t,e,n){"use strict";var i=n("fe81"),r=n.n(i);r.a},"24fb":function(t,e,n){"use strict";function i(t,e){var n=t[1]||"",i=t[3];if(!i)return n;if(e&&"function"===typeof btoa){var a=r(i),o=i.sources.map((function(t){return"/*# sourceURL=".concat(i.sourceRoot||"").concat(t," */")}));return[n].concat(o).concat([a]).join("\n")}return[n].join("\n")}function r(t){var e=btoa(unescape(encodeURIComponent(JSON.stringify(t)))),n="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(e);return"/*# ".concat(n," */")}t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n=i(e,t);return e[2]?"@media ".concat(e[2]," {").concat(n,"}"):n})).join("")},e.i=function(t,n,i){"string"===typeof t&&(t=[[null,t,""]]);var r={};if(i)for(var a=0;an.parts.length&&(i.parts.length=n.parts.length)}else{var o=[];for(r=0;r1?e-1:0),o=1;o1){var u=c.pop();l=c.join("---COMMA---"),0===u.indexOf(" at ")?l+=u:l+="---COMMA---"+u}else l=c[0];console[a](l)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return weex.requireModule(t)}},,function(t,e,n){"use strict";n.r(e);var o=n(14),i=n.n(o);for(var r in o)"default"!==r&&function(t){n.d(e,t,(function(){return o[t]}))}(r);e.default=i.a},,,,function(t,e,n){"use strict";n.r(e);n(2);var o=n(6);"undefined"==typeof Promise||Promise.prototype.finally||(Promise.prototype.finally=function(t){var e=this.constructor;return this.then((function(n){return e.resolve(t()).then((function(){return n}))}),(function(n){return e.resolve(t()).then((function(){throw n}))}))}),o.default.mpType="page",o.default.route="pages/index/scan",o.default.el="#root",new Vue(o.default)}]); \ No newline at end of file +!function(t){var e={};function n(o){if(e[o])return e[o].exports;var i=e[o]={i:o,l:!1,exports:{}};return t[o].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t,e,o){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:o})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(o,i,function(e){return t[e]}.bind(null,i));return o},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=25)}([function(t,e){t.exports={"uni-icon":{fontFamily:"uniicons",fontWeight:"normal"},"uni-bg-red":{backgroundColor:"#F76260",color:"#FFFFFF"},"uni-bg-green":{backgroundColor:"#09BB07",color:"#FFFFFF"},"uni-bg-blue":{backgroundColor:"#007AFF",color:"#FFFFFF"},"uni-container":{flex:1,paddingTop:"15",paddingRight:"15",paddingBottom:"15",paddingLeft:"15",backgroundColor:"#f8f8f8"},"uni-padding-lr":{paddingLeft:"15",paddingRight:"15"},"uni-padding-tb":{paddingTop:"15",paddingBottom:"15"},"uni-header-logo":{paddingTop:"15",paddingRight:"15",paddingBottom:"15",paddingLeft:"15",flexDirection:"column",justifyContent:"center",alignItems:"center",marginTop:"10upx"},"uni-header-image":{width:"80",height:"80"},"uni-hello-text":{marginBottom:"20"},"hello-text":{color:"#7A7E83",fontSize:"14",lineHeight:"20"},"hello-link":{color:"#7A7E83",fontSize:"14",lineHeight:"20"},"uni-panel":{marginBottom:"12"},"uni-panel-h":{backgroundColor:"#ffffff",flexDirection:"row",alignItems:"center",paddingTop:"12",paddingRight:"12",paddingBottom:"12",paddingLeft:"12"},"uni-panel-h-on":{backgroundColor:"#f0f0f0"},"uni-panel-text":{flex:1,color:"#000000",fontSize:"14",fontWeight:"normal"},"uni-panel-icon":{marginLeft:"15",color:"#999999",fontSize:"14",fontWeight:"normal",transform:"rotate(0deg)",transitionDuration:0,transitionProperty:"transform"},"uni-panel-icon-on":{transform:"rotate(180deg)"},"uni-navigate-item":{flexDirection:"row",alignItems:"center",backgroundColor:"#FFFFFF",borderTopStyle:"solid",borderTopColor:"#f0f0f0",borderTopWidth:"1",paddingTop:"12",paddingRight:"12",paddingBottom:"12",paddingLeft:"12","backgroundColor:active":"#f8f8f8"},"uni-navigate-text":{flex:1,color:"#000000",fontSize:"14",fontWeight:"normal"},"uni-navigate-icon":{marginLeft:"15",color:"#999999",fontSize:"14",fontWeight:"normal"},"uni-list-cell":{position:"relative",flexDirection:"row",justifyContent:"flex-start",alignItems:"center"},"uni-list-cell-pd":{paddingTop:"22upx",paddingRight:"30upx",paddingBottom:"22upx",paddingLeft:"30upx"},"flex-r":{flexDirection:"row"},"flex-c":{flexDirection:"column"},"a-i-c":{alignItems:"center"},"j-c-c":{justifyContent:"center"},"list-item":{flexDirection:"row",paddingTop:"10",paddingRight:"10",paddingBottom:"10",paddingLeft:"10"},"@VERSION":2}},function(t,e,n){"use strict";function o(t,e,n,o,i,r,a,c,l,u){var s,f="function"==typeof t?t.options:t;if(l){f.components||(f.components={});var d=Object.prototype.hasOwnProperty;for(var p in l)d.call(l,p)&&!d.call(f.components,p)&&(f.components[p]=l[p])}if(u&&((u.beforeCreate||(u.beforeCreate=[])).unshift((function(){this[u.__module]=this})),(f.mixins||(f.mixins=[])).push(u)),e&&(f.render=e,f.staticRenderFns=n,f._compiled=!0),o&&(f.functional=!0),r&&(f._scopeId="data-v-"+r),a?(s=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),i&&i.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},f._ssrRegister=s):i&&(s=c?function(){i.call(this,this.$root.$options.shadowRoot)}:i),s)if(f.functional){f._injectStyles=s;var g=f.render;f.render=function(t,e){return s.call(e),g(t,e)}}else{var _=f.beforeCreate;f.beforeCreate=_?[].concat(_,s):[s]}return{exports:t,options:f}}n.d(e,"a",(function(){return o}))},function(t,e,n){Vue.prototype.__$appStyle__={},Vue.prototype.__merge_style&&Vue.prototype.__merge_style(n(3).default,Vue.prototype.__$appStyle__)},function(t,e,n){"use strict";n.r(e);var o=n(0),i=n.n(o);for(var r in o)"default"!==r&&function(t){n.d(e,t,(function(){return o[t]}))}(r);e.default=i.a},,,function(t,e,n){"use strict";var o=n(17),i=n(12),r=n(1);var a=Object(r.a)(i.default,o.b,o.c,!1,null,null,"78abdf82",!1,o.a,void 0);(function(t){this.options.style||(this.options.style={}),Vue.prototype.__merge_style&&Vue.prototype.__$appStyle__&&Vue.prototype.__merge_style(Vue.prototype.__$appStyle__,this.options.style),Vue.prototype.__merge_style?Vue.prototype.__merge_style(n(21).default,this.options.style):Object.assign(this.options.style,n(21).default)}).call(a),e.default=a.exports},,,,,,function(t,e,n){"use strict";var o=n(13),i=n.n(o);e.default=i.a},function(t,e,n){"use strict";(function(t,n){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var o={onLoad:function(){},data:function(){return{fil:[0,2,1]}},methods:{toback:function(){var t=this;setTimeout((function(){t.tocancel(),uni.navigateBack()}),3e3)},success1:function(e){t("log","success1:"+JSON.stringify(e)," at pages/index/scan.nvue:40")},fail1:function(e){t("log","fail1:"+JSON.stringify(e)," at pages/index/scan.nvue:43")},toStart:function(){this.$refs.barcode.start({conserve:!0,filename:"_doc/barcode/"})},tocancel:function(){this.$refs.barcode.cancel()},toFlash:function(){this.$refs.barcode.setFlash(!0)},toscan:function(){t("log","scan:"," at pages/index/scan.nvue:59"),n("barcodeScan").scan("/static/barcode1.png",(function(e){t("log","scan_error:"+JSON.stringify(e)," at pages/index/scan.nvue:63")}))}}};e.default=o}).call(this,n(18).default,n(19).default)},function(t,e){t.exports={"@VERSION":2}},,,function(t,e,n){"use strict";n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return i})),n.d(e,"a",(function(){}));var o=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("scroll-view",{staticStyle:{flexDirection:"column"},attrs:{scrollY:!0,showScrollbar:!0,enableBackToTop:!0,bubble:"true"}},[n("view",{staticClass:["main"]},[n("button",{staticClass:["btn"],on:{click:t.toStart}},[t._v("\n\t\t\t\u5f00\u59cb\u626b\u7801\u8bc6\u522b")]),n("button",{staticClass:["btn"],on:{click:t.tocancel}},[t._v("\u53d6\u6d88\u626b\u7801\u8bc6\u522b")]),n("button",{staticClass:["btn"],on:{click:t.toFlash}},[t._v("\u5f00\u542f\u95ea\u5149\u706f")]),n("button",{staticClass:["btn"],on:{click:t.toscan}},[t._v("\u9884\u89c8")]),n("button",{staticClass:["btn"],on:{click:t.toback}},[n("view",{staticClass:["dot"]}),t._v("\n\t\t\t3s\u540e\u8fd4\u56de")]),n("view",{staticClass:["bottom-dot"]})],1)])},i=[]},function(t,e,n){"use strict";function o(t){var e=Object.prototype.toString.call(t);return e.substring(8,e.length-1)}function i(){return"string"==typeof __channelId__&&__channelId__}function r(t,e){switch(o(e)){case"Function":return"function() { [native code] }";default:return e}}Object.defineProperty(e,"__esModule",{value:!0}),e.log=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),o=1;o1){var u=c.pop();l=c.join("---COMMA---"),0===u.indexOf(" at ")?l+=u:l+="---COMMA---"+u}else l=c[0];console[a](l)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return weex.requireModule(t)}},,function(t,e,n){"use strict";n.r(e);var o=n(14),i=n.n(o);for(var r in o)"default"!==r&&function(t){n.d(e,t,(function(){return o[t]}))}(r);e.default=i.a},,,,function(t,e,n){"use strict";n.r(e);n(2);var o=n(6);"undefined"==typeof Promise||Promise.prototype.finally||(Promise.prototype.finally=function(t){var e=this.constructor;return this.then((function(n){return e.resolve(t()).then((function(){return n}))}),(function(n){return e.resolve(t()).then((function(){throw n}))}))}),o.default.mpType="page",o.default.route="pages/index/scan",o.default.el="#root",new Vue(o.default)}]); \ No newline at end of file diff --git a/app/src/main/assets/apps/__UNI__2B9497D/www/pages/sample/ext-component.js b/app/src/main/assets/apps/__UNI__2B9497D/www/pages/sample/ext-component.js index 6a1570f..9f4323f 100644 --- a/app/src/main/assets/apps/__UNI__2B9497D/www/pages/sample/ext-component.js +++ b/app/src/main/assets/apps/__UNI__2B9497D/www/pages/sample/ext-component.js @@ -1 +1 @@ -!function(t){var e={};function n(o){if(e[o])return e[o].exports;var r=e[o]={i:o,l:!1,exports:{}};return t[o].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=t,n.c=e,n.d=function(t,e,o){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:o})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)n.d(o,r,function(e){return t[e]}.bind(null,r));return o},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=22)}([function(t,e){t.exports={"uni-icon":{fontFamily:"uniicons",fontWeight:"normal"},"uni-bg-red":{backgroundColor:"#F76260",color:"#FFFFFF"},"uni-bg-green":{backgroundColor:"#09BB07",color:"#FFFFFF"},"uni-bg-blue":{backgroundColor:"#007AFF",color:"#FFFFFF"},"uni-container":{flex:1,paddingTop:"15",paddingRight:"15",paddingBottom:"15",paddingLeft:"15",backgroundColor:"#f8f8f8"},"uni-padding-lr":{paddingLeft:"15",paddingRight:"15"},"uni-padding-tb":{paddingTop:"15",paddingBottom:"15"},"uni-header-logo":{paddingTop:"15",paddingRight:"15",paddingBottom:"15",paddingLeft:"15",flexDirection:"column",justifyContent:"center",alignItems:"center",marginTop:"10upx"},"uni-header-image":{width:"80",height:"80"},"uni-hello-text":{marginBottom:"20"},"hello-text":{color:"#7A7E83",fontSize:"14",lineHeight:"20"},"hello-link":{color:"#7A7E83",fontSize:"14",lineHeight:"20"},"uni-panel":{marginBottom:"12"},"uni-panel-h":{backgroundColor:"#ffffff",flexDirection:"row",alignItems:"center",paddingTop:"12",paddingRight:"12",paddingBottom:"12",paddingLeft:"12"},"uni-panel-h-on":{backgroundColor:"#f0f0f0"},"uni-panel-text":{flex:1,color:"#000000",fontSize:"14",fontWeight:"normal"},"uni-panel-icon":{marginLeft:"15",color:"#999999",fontSize:"14",fontWeight:"normal",transform:"rotate(0deg)",transitionDuration:0,transitionProperty:"transform"},"uni-panel-icon-on":{transform:"rotate(180deg)"},"uni-navigate-item":{flexDirection:"row",alignItems:"center",backgroundColor:"#FFFFFF",borderTopStyle:"solid",borderTopColor:"#f0f0f0",borderTopWidth:"1",paddingTop:"12",paddingRight:"12",paddingBottom:"12",paddingLeft:"12","backgroundColor:active":"#f8f8f8"},"uni-navigate-text":{flex:1,color:"#000000",fontSize:"14",fontWeight:"normal"},"uni-navigate-icon":{marginLeft:"15",color:"#999999",fontSize:"14",fontWeight:"normal"},"uni-list-cell":{position:"relative",flexDirection:"row",justifyContent:"flex-start",alignItems:"center"},"uni-list-cell-pd":{paddingTop:"22upx",paddingRight:"30upx",paddingBottom:"22upx",paddingLeft:"30upx"},"flex-r":{flexDirection:"row"},"flex-c":{flexDirection:"column"},"a-i-c":{alignItems:"center"},"j-c-c":{justifyContent:"center"},"list-item":{flexDirection:"row",paddingTop:"10",paddingRight:"10",paddingBottom:"10",paddingLeft:"10"},"@VERSION":2}},function(t,e,n){"use strict";function o(t,e,n,o,r,i,a,l,u,c){var f,d="function"==typeof t?t.options:t;if(u){d.components||(d.components={});var p=Object.prototype.hasOwnProperty;for(var s in u)p.call(u,s)&&!p.call(d.components,s)&&(d.components[s]=u[s])}if(c&&((c.beforeCreate||(c.beforeCreate=[])).unshift((function(){this[c.__module]=this})),(d.mixins||(d.mixins=[])).push(c)),e&&(d.render=e,d.staticRenderFns=n,d._compiled=!0),o&&(d.functional=!0),i&&(d._scopeId="data-v-"+i),a?(f=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),r&&r.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},d._ssrRegister=f):r&&(f=l?function(){r.call(this,this.$root.$options.shadowRoot)}:r),f)if(d.functional){d._injectStyles=f;var g=d.render;d.render=function(t,e){return f.call(e),g(t,e)}}else{var h=d.beforeCreate;d.beforeCreate=h?[].concat(h,f):[f]}return{exports:t,options:d}}n.d(e,"a",(function(){return o}))},function(t,e,n){Vue.prototype.__$appStyle__={},Vue.prototype.__merge_style&&Vue.prototype.__merge_style(n(3).default,Vue.prototype.__$appStyle__)},function(t,e,n){"use strict";n.r(e);var o=n(0),r=n.n(o);for(var i in o)"default"!==i&&function(t){n.d(e,t,(function(){return o[t]}))}(i);e.default=r.a},function(t,e,n){"use strict";var o=n(15),r=n(7),i=n(1),a=Object(i.a)(r.default,o.b,o.c,!1,null,null,"ccd8f580",!1,o.a,void 0);e.default=a.exports},,,function(t,e,n){"use strict";var o=n(8),r=n.n(o);e.default=r.a},function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n={data:function(){return{}},onLoad:function(){},methods:{onTel:function(e){t("log","onTel="+e.detail.tel," at pages/sample/ext-component.nvue:17")},myTextClick:function(t){this.$refs.telText.clearTel()}}};e.default=n}).call(this,n(18).default)},,,,,,,function(t,e,n){"use strict";n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return r})),n.d(e,"a",(function(){}));var o=function(){var t=this.$createElement,e=this._self._c||t;return e("scroll-view",{staticStyle:{flexDirection:"column"},attrs:{scrollY:!0,showScrollbar:!0,enableBackToTop:!0,bubble:"true"}},[e("div",[e("myText",{ref:"telText",staticStyle:{width:"200",height:"100"},attrs:{tel:"12305"},on:{onTel:this.onTel,click:this.myTextClick}})],1)])},r=[]},,,function(t,e,n){"use strict";function o(t){var e=Object.prototype.toString.call(t);return e.substring(8,e.length-1)}function r(){return"string"==typeof __channelId__&&__channelId__}function i(t,e){switch(o(e)){case"Function":return"function() { [native code] }";default:return e}}Object.defineProperty(e,"__esModule",{value:!0}),e.log=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),o=1;o1){var c=l.pop();u=l.join("---COMMA---"),0===c.indexOf(" at ")?u+=c:u+="---COMMA---"+c}else u=l[0];console[a](u)}},,,,function(t,e,n){"use strict";n.r(e);n(2);var o=n(4);"undefined"==typeof Promise||Promise.prototype.finally||(Promise.prototype.finally=function(t){var e=this.constructor;return this.then((function(n){return e.resolve(t()).then((function(){return n}))}),(function(n){return e.resolve(t()).then((function(){throw n}))}))}),o.default.mpType="page",o.default.route="pages/sample/ext-component",o.default.el="#root",new Vue(o.default)}]); \ No newline at end of file +!function(t){var e={};function n(o){if(e[o])return e[o].exports;var r=e[o]={i:o,l:!1,exports:{}};return t[o].call(r.exports,r,r.exports,n),r.l=!0,r.exports}n.m=t,n.c=e,n.d=function(t,e,o){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:o})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)n.d(o,r,function(e){return t[e]}.bind(null,r));return o},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=22)}([function(t,e){t.exports={"uni-icon":{fontFamily:"uniicons",fontWeight:"normal"},"uni-bg-red":{backgroundColor:"#F76260",color:"#FFFFFF"},"uni-bg-green":{backgroundColor:"#09BB07",color:"#FFFFFF"},"uni-bg-blue":{backgroundColor:"#007AFF",color:"#FFFFFF"},"uni-container":{flex:1,paddingTop:"15",paddingRight:"15",paddingBottom:"15",paddingLeft:"15",backgroundColor:"#f8f8f8"},"uni-padding-lr":{paddingLeft:"15",paddingRight:"15"},"uni-padding-tb":{paddingTop:"15",paddingBottom:"15"},"uni-header-logo":{paddingTop:"15",paddingRight:"15",paddingBottom:"15",paddingLeft:"15",flexDirection:"column",justifyContent:"center",alignItems:"center",marginTop:"10upx"},"uni-header-image":{width:"80",height:"80"},"uni-hello-text":{marginBottom:"20"},"hello-text":{color:"#7A7E83",fontSize:"14",lineHeight:"20"},"hello-link":{color:"#7A7E83",fontSize:"14",lineHeight:"20"},"uni-panel":{marginBottom:"12"},"uni-panel-h":{backgroundColor:"#ffffff",flexDirection:"row",alignItems:"center",paddingTop:"12",paddingRight:"12",paddingBottom:"12",paddingLeft:"12"},"uni-panel-h-on":{backgroundColor:"#f0f0f0"},"uni-panel-text":{flex:1,color:"#000000",fontSize:"14",fontWeight:"normal"},"uni-panel-icon":{marginLeft:"15",color:"#999999",fontSize:"14",fontWeight:"normal",transform:"rotate(0deg)",transitionDuration:0,transitionProperty:"transform"},"uni-panel-icon-on":{transform:"rotate(180deg)"},"uni-navigate-item":{flexDirection:"row",alignItems:"center",backgroundColor:"#FFFFFF",borderTopStyle:"solid",borderTopColor:"#f0f0f0",borderTopWidth:"1",paddingTop:"12",paddingRight:"12",paddingBottom:"12",paddingLeft:"12","backgroundColor:active":"#f8f8f8"},"uni-navigate-text":{flex:1,color:"#000000",fontSize:"14",fontWeight:"normal"},"uni-navigate-icon":{marginLeft:"15",color:"#999999",fontSize:"14",fontWeight:"normal"},"uni-list-cell":{position:"relative",flexDirection:"row",justifyContent:"flex-start",alignItems:"center"},"uni-list-cell-pd":{paddingTop:"22upx",paddingRight:"30upx",paddingBottom:"22upx",paddingLeft:"30upx"},"flex-r":{flexDirection:"row"},"flex-c":{flexDirection:"column"},"a-i-c":{alignItems:"center"},"j-c-c":{justifyContent:"center"},"list-item":{flexDirection:"row",paddingTop:"10",paddingRight:"10",paddingBottom:"10",paddingLeft:"10"},"@VERSION":2}},function(t,e,n){"use strict";function o(t,e,n,o,r,i,a,l,u,c){var f,d="function"==typeof t?t.options:t;if(u){d.components||(d.components={});var p=Object.prototype.hasOwnProperty;for(var s in u)p.call(u,s)&&!p.call(d.components,s)&&(d.components[s]=u[s])}if(c&&((c.beforeCreate||(c.beforeCreate=[])).unshift((function(){this[c.__module]=this})),(d.mixins||(d.mixins=[])).push(c)),e&&(d.render=e,d.staticRenderFns=n,d._compiled=!0),o&&(d.functional=!0),i&&(d._scopeId="data-v-"+i),a?(f=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),r&&r.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},d._ssrRegister=f):r&&(f=l?function(){r.call(this,this.$root.$options.shadowRoot)}:r),f)if(d.functional){d._injectStyles=f;var g=d.render;d.render=function(t,e){return f.call(e),g(t,e)}}else{var h=d.beforeCreate;d.beforeCreate=h?[].concat(h,f):[f]}return{exports:t,options:d}}n.d(e,"a",(function(){return o}))},function(t,e,n){Vue.prototype.__$appStyle__={},Vue.prototype.__merge_style&&Vue.prototype.__merge_style(n(3).default,Vue.prototype.__$appStyle__)},function(t,e,n){"use strict";n.r(e);var o=n(0),r=n.n(o);for(var i in o)"default"!==i&&function(t){n.d(e,t,(function(){return o[t]}))}(i);e.default=r.a},function(t,e,n){"use strict";var o=n(15),r=n(7),i=n(1),a=Object(i.a)(r.default,o.b,o.c,!1,null,null,"577f43ad",!1,o.a,void 0);e.default=a.exports},,,function(t,e,n){"use strict";var o=n(8),r=n.n(o);e.default=r.a},function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n={data:function(){return{}},onLoad:function(){},methods:{onTel:function(e){t("log","onTel="+e.detail.tel," at pages/sample/ext-component.nvue:17")},myTextClick:function(t){this.$refs.telText.clearTel()}}};e.default=n}).call(this,n(18).default)},,,,,,,function(t,e,n){"use strict";n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return r})),n.d(e,"a",(function(){}));var o=function(){var t=this.$createElement,e=this._self._c||t;return e("scroll-view",{staticStyle:{flexDirection:"column"},attrs:{scrollY:!0,showScrollbar:!0,enableBackToTop:!0,bubble:"true"}},[e("div",[e("myText",{ref:"telText",staticStyle:{width:"200",height:"100"},attrs:{tel:"12305"},on:{onTel:this.onTel,click:this.myTextClick}})],1)])},r=[]},,,function(t,e,n){"use strict";function o(t){var e=Object.prototype.toString.call(t);return e.substring(8,e.length-1)}function r(){return"string"==typeof __channelId__&&__channelId__}function i(t,e){switch(o(e)){case"Function":return"function() { [native code] }";default:return e}}Object.defineProperty(e,"__esModule",{value:!0}),e.log=function(t){for(var e=arguments.length,n=new Array(e>1?e-1:0),o=1;o1){var c=l.pop();u=l.join("---COMMA---"),0===c.indexOf(" at ")?u+=c:u+="---COMMA---"+c}else u=l[0];console[a](u)}},,,,function(t,e,n){"use strict";n.r(e);n(2);var o=n(4);"undefined"==typeof Promise||Promise.prototype.finally||(Promise.prototype.finally=function(t){var e=this.constructor;return this.then((function(n){return e.resolve(t()).then((function(){return n}))}),(function(n){return e.resolve(t()).then((function(){throw n}))}))}),o.default.mpType="page",o.default.route="pages/sample/ext-component",o.default.el="#root",new Vue(o.default)}]); \ No newline at end of file diff --git a/app/src/main/assets/apps/__UNI__2B9497D/www/pages/sample/ext-module.js b/app/src/main/assets/apps/__UNI__2B9497D/www/pages/sample/ext-module.js index 641ee37..eb089e6 100644 --- a/app/src/main/assets/apps/__UNI__2B9497D/www/pages/sample/ext-module.js +++ b/app/src/main/assets/apps/__UNI__2B9497D/www/pages/sample/ext-module.js @@ -1 +1 @@ -!function(t){var e={};function n(o){if(e[o])return e[o].exports;var i=e[o]={i:o,l:!1,exports:{}};return t[o].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t,e,o){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:o})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(o,i,function(e){return t[e]}.bind(null,i));return o},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=23)}([function(t,e){t.exports={"uni-icon":{fontFamily:"uniicons",fontWeight:"normal"},"uni-bg-red":{backgroundColor:"#F76260",color:"#FFFFFF"},"uni-bg-green":{backgroundColor:"#09BB07",color:"#FFFFFF"},"uni-bg-blue":{backgroundColor:"#007AFF",color:"#FFFFFF"},"uni-container":{flex:1,paddingTop:"15",paddingRight:"15",paddingBottom:"15",paddingLeft:"15",backgroundColor:"#f8f8f8"},"uni-padding-lr":{paddingLeft:"15",paddingRight:"15"},"uni-padding-tb":{paddingTop:"15",paddingBottom:"15"},"uni-header-logo":{paddingTop:"15",paddingRight:"15",paddingBottom:"15",paddingLeft:"15",flexDirection:"column",justifyContent:"center",alignItems:"center",marginTop:"10upx"},"uni-header-image":{width:"80",height:"80"},"uni-hello-text":{marginBottom:"20"},"hello-text":{color:"#7A7E83",fontSize:"14",lineHeight:"20"},"hello-link":{color:"#7A7E83",fontSize:"14",lineHeight:"20"},"uni-panel":{marginBottom:"12"},"uni-panel-h":{backgroundColor:"#ffffff",flexDirection:"row",alignItems:"center",paddingTop:"12",paddingRight:"12",paddingBottom:"12",paddingLeft:"12"},"uni-panel-h-on":{backgroundColor:"#f0f0f0"},"uni-panel-text":{flex:1,color:"#000000",fontSize:"14",fontWeight:"normal"},"uni-panel-icon":{marginLeft:"15",color:"#999999",fontSize:"14",fontWeight:"normal",transform:"rotate(0deg)",transitionDuration:0,transitionProperty:"transform"},"uni-panel-icon-on":{transform:"rotate(180deg)"},"uni-navigate-item":{flexDirection:"row",alignItems:"center",backgroundColor:"#FFFFFF",borderTopStyle:"solid",borderTopColor:"#f0f0f0",borderTopWidth:"1",paddingTop:"12",paddingRight:"12",paddingBottom:"12",paddingLeft:"12","backgroundColor:active":"#f8f8f8"},"uni-navigate-text":{flex:1,color:"#000000",fontSize:"14",fontWeight:"normal"},"uni-navigate-icon":{marginLeft:"15",color:"#999999",fontSize:"14",fontWeight:"normal"},"uni-list-cell":{position:"relative",flexDirection:"row",justifyContent:"flex-start",alignItems:"center"},"uni-list-cell-pd":{paddingTop:"22upx",paddingRight:"30upx",paddingBottom:"22upx",paddingLeft:"30upx"},"flex-r":{flexDirection:"row"},"flex-c":{flexDirection:"column"},"a-i-c":{alignItems:"center"},"j-c-c":{justifyContent:"center"},"list-item":{flexDirection:"row",paddingTop:"10",paddingRight:"10",paddingBottom:"10",paddingLeft:"10"},"@VERSION":2}},function(t,e,n){"use strict";function o(t,e,n,o,i,r,a,u,s,c){var l,p="function"==typeof t?t.options:t;if(s){p.components||(p.components={});var d=Object.prototype.hasOwnProperty;for(var f in s)d.call(s,f)&&!d.call(p.components,f)&&(p.components[f]=s[f])}if(c&&((c.beforeCreate||(c.beforeCreate=[])).unshift((function(){this[c.__module]=this})),(p.mixins||(p.mixins=[])).push(c)),e&&(p.render=e,p.staticRenderFns=n,p._compiled=!0),o&&(p.functional=!0),r&&(p._scopeId="data-v-"+r),a?(l=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),i&&i.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},p._ssrRegister=l):i&&(l=u?function(){i.call(this,this.$root.$options.shadowRoot)}:i),l)if(p.functional){p._injectStyles=l;var g=p.render;p.render=function(t,e){return l.call(e),g(t,e)}}else{var m=p.beforeCreate;p.beforeCreate=m?[].concat(m,l):[l]}return{exports:t,options:p}}n.d(e,"a",(function(){return o}))},function(t,e,n){Vue.prototype.__$appStyle__={},Vue.prototype.__merge_style&&Vue.prototype.__merge_style(n(3).default,Vue.prototype.__$appStyle__)},function(t,e,n){"use strict";n.r(e);var o=n(0),i=n.n(o);for(var r in o)"default"!==r&&function(t){n.d(e,t,(function(){return o[t]}))}(r);e.default=i.a},,function(t,e,n){"use strict";var o=n(16),i=n(9),r=n(1);var a=Object(r.a)(i.default,o.b,o.c,!1,null,null,"56be5383",!1,o.a,void 0);(function(t){this.options.style||(this.options.style={}),Vue.prototype.__merge_style&&Vue.prototype.__$appStyle__&&Vue.prototype.__merge_style(Vue.prototype.__$appStyle__,this.options.style),Vue.prototype.__merge_style?Vue.prototype.__merge_style(n(20).default,this.options.style):Object.assign(this.options.style,n(20).default)}).call(a),e.default=a.exports},,,,function(t,e,n){"use strict";var o=n(10),i=n.n(o);e.default=i.a},function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var o=n(24),i=t("Zmt-Module"),r=t("TestModule"),a=t("uniplugin_module_ox"),u=t("Face-Module"),s=t("modal"),c={onLoad:function(){this.initAPPListener()},onReady:function(){this.logs.push("\u5f53\u524d\u65f6\u95f4:"+this.getTime())},data:function(){return{logs:["LOG VIEW"]}},methods:{initAPPListener:function(){plus.globalEvent.addEventListener("TestEvent",(function(t){s.toast({message:"TestEvent\u6536\u5230\uff1a"+t.msg,duration:1.5})}))},faceAsyncFunc:function(){var t=this;this.log("\u6267\u884cfaceModule.faceAsyncFunc"),u.faceAsyncFunc({name:"unimp",age:1},(function(e){s.toast({message:e,duration:1.5}),t.log(JSON.stringify(e))}))},tcpAsyncFunc:function(){var t=this;this.log("\u5f00\u542fTcp Server."),i.tcpAsyncFunc({name:"unimp",age:1},(function(e){s.toast({message:e,duration:2}),t.log("tcp\u63a5\u6536:"+e.code)}))},testFun2:function(){var t=i.testSyncFunc({name:"unimp",age:1});s.toast({message:t,duration:1.5})},testAsyncFunc:function(){r.testAsyncFunc({name:"unimp",age:1},(function(t){s.toast({message:t,duration:1.5})}))},testSyncFunc:function(){var t=r.testSyncFunc({name:"unimp",age:1});s.toast({message:t,duration:1.5})},testAsyncFunc2:function(){a.testAsyncFunc2({name:"unimp",age:1},(function(t){s.toast({message:t,duration:1.5})}))},testSyncFunc2:function(){var t=a.testSyncFunc2({name:"unimp",age:1});s.toast({message:t,duration:1.5})},log:function(t){this.logs.push(this.getTime()+" ".concat(t))},getTime:function(){return(0,o.timeFormat)(new Date,"mm/dd hh:MM:ss")},gotoNativePage:function(){r.gotoNativePage()}}};e.default=c}).call(this,n(19).default)},function(t,e){t.exports={content:{fontSize:"12"},btn:{marginTop:"3",marginRight:"3",marginBottom:"3",marginLeft:"3"},tips:{fontSize:"11",color:"#808080",fontWeight:"800"},console:{backgroundColor:"#D3D3D3",paddingTop:"20rpx",paddingRight:"20rpx",paddingBottom:"20rpx",paddingLeft:"20rpx"},log:{color:"#8B0000",fontSize:"11",fontWeight:"800"},"@VERSION":2}},,,,,function(t,e,n){"use strict";n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return i})),n.d(e,"a",(function(){}));var o=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("scroll-view",{staticStyle:{flexDirection:"column"},attrs:{scrollY:!0,showScrollbar:!0,enableBackToTop:!0,bubble:"true"}},[n("div",{staticClass:["content"]},[n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.gotoNativePage}},[t._v("\u8df3\u8f6c\u539f\u751fActivity")]),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.tcpAsyncFunc}},[t._v("[\u5f00\u542fTcpServer]")]),n("u-text",{staticClass:["tips"],appendAsTree:!0,attrs:{append:"tree"}},[t._v("\n\t\t\u70b9\u51fb\u540e\u5c06\u5f00\u542fTcpServer. \u672c\u673aIP: 192.168.1.64 \u7aef\u53e3\uff1a16666\n\t")]),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.faceAsyncFunc}},[t._v("[\u767e\u5ea6\u4eba\u8138SDK\u6388\u6743]")]),n("u-text",{staticClass:["tips"],appendAsTree:!0,attrs:{append:"tree"}},[t._v("\n\t\t\u70b9\u51fb\u540e\u5c06\u8fdb\u884c\u767e\u5ea6\u4eba\u8138SDK\u521d\u59cb\u5316\u53ca\u6388\u6743\u7533\u8bf7,\u8be5\u6388\u6743\u7801\u5199\u6b7b\u5728Android\u7aefzmt_module\u5185faceClass,\u56e0\u5df2\u4f7f\u7528\u8fc7,\u5c06\u8fd4\u56de\u5df2\u88ab\u5360\u7528\u63d0\u793a.\n\t")]),n("view",{staticClass:["console"]},t._l(t.logs,(function(e){return n("u-text",{staticClass:["log"],appendAsTree:!0,attrs:{append:"tree"}},[t._v(t._s(e))])})),0),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.testAsyncFunc2}},[t._v("uniplugin_module_ox testAsyncFunc2")]),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.testSyncFunc2}},[t._v("uniplugin_module_ox testSyncFunc2")]),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.testAsyncFunc}},[t._v("uniplugin_module testAsyncFunc")]),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.testSyncFunc}},[t._v("uniplugin_module testSyncFunc")])],1)])},i=[]},,,function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return weex.requireModule(t)}},function(t,e,n){"use strict";n.r(e);var o=n(11),i=n.n(o);for(var r in o)"default"!==r&&function(t){n.d(e,t,(function(){return o[t]}))}(r);e.default=i.a},,,function(t,e,n){"use strict";n.r(e);n(2);var o=n(5);"undefined"==typeof Promise||Promise.prototype.finally||(Promise.prototype.finally=function(t){var e=this.constructor;return this.then((function(n){return e.resolve(t()).then((function(){return n}))}),(function(n){return e.resolve(t()).then((function(){throw n}))}))}),o.default.mpType="page",o.default.route="pages/sample/ext-module",o.default.el="#root",new Vue(o.default)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.timeFormat=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"yyyy-mm-dd";t||(t=Number(new Date));"string"==typeof t&&t.indexOf("-")>0&&(t=t.replace(/\-/g,"/"));10==t.toString().length&&(t*=1e3);var n,o=new Date(t),i={"y+":o.getFullYear().toString(),"m+":(o.getMonth()+1).toString(),"d+":o.getDate().toString(),"h+":o.getHours().toString(),"M+":o.getMinutes().toString(),"s+":o.getSeconds().toString()};for(var r in i)(n=new RegExp("("+r+")").exec(e))&&(e=e.replace(n[1],1==n[1].length?i[r]:i[r].padStart(n[1].length,"0")));return e},e.getDurationTime=function(t){var e="",n=parseInt(t/3600),o=parseInt(t%3600/60),i=parseInt(t%3600%60);n>0&&(e+=(n=n<10?"0"+n:n)+":");return e+=(o=o<10?"0"+o:o)+":"+(i=i<10?"0"+i:i)},String.prototype.padStart||(String.prototype.padStart=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:" ";if("[object String]"!==Object.prototype.toString.call(e))throw new TypeError("fillString must be String");var n=this;if(n.length>=t)return String(n);for(var o=t-n.length,i=Math.ceil(o/e.length);i>>=1;)e+=e,1===i&&(e+=e);return e.slice(0,o)+n})}]); \ No newline at end of file +!function(t){var e={};function n(o){if(e[o])return e[o].exports;var i=e[o]={i:o,l:!1,exports:{}};return t[o].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t,e,o){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:o})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(o,i,function(e){return t[e]}.bind(null,i));return o},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=23)}([function(t,e){t.exports={"uni-icon":{fontFamily:"uniicons",fontWeight:"normal"},"uni-bg-red":{backgroundColor:"#F76260",color:"#FFFFFF"},"uni-bg-green":{backgroundColor:"#09BB07",color:"#FFFFFF"},"uni-bg-blue":{backgroundColor:"#007AFF",color:"#FFFFFF"},"uni-container":{flex:1,paddingTop:"15",paddingRight:"15",paddingBottom:"15",paddingLeft:"15",backgroundColor:"#f8f8f8"},"uni-padding-lr":{paddingLeft:"15",paddingRight:"15"},"uni-padding-tb":{paddingTop:"15",paddingBottom:"15"},"uni-header-logo":{paddingTop:"15",paddingRight:"15",paddingBottom:"15",paddingLeft:"15",flexDirection:"column",justifyContent:"center",alignItems:"center",marginTop:"10upx"},"uni-header-image":{width:"80",height:"80"},"uni-hello-text":{marginBottom:"20"},"hello-text":{color:"#7A7E83",fontSize:"14",lineHeight:"20"},"hello-link":{color:"#7A7E83",fontSize:"14",lineHeight:"20"},"uni-panel":{marginBottom:"12"},"uni-panel-h":{backgroundColor:"#ffffff",flexDirection:"row",alignItems:"center",paddingTop:"12",paddingRight:"12",paddingBottom:"12",paddingLeft:"12"},"uni-panel-h-on":{backgroundColor:"#f0f0f0"},"uni-panel-text":{flex:1,color:"#000000",fontSize:"14",fontWeight:"normal"},"uni-panel-icon":{marginLeft:"15",color:"#999999",fontSize:"14",fontWeight:"normal",transform:"rotate(0deg)",transitionDuration:0,transitionProperty:"transform"},"uni-panel-icon-on":{transform:"rotate(180deg)"},"uni-navigate-item":{flexDirection:"row",alignItems:"center",backgroundColor:"#FFFFFF",borderTopStyle:"solid",borderTopColor:"#f0f0f0",borderTopWidth:"1",paddingTop:"12",paddingRight:"12",paddingBottom:"12",paddingLeft:"12","backgroundColor:active":"#f8f8f8"},"uni-navigate-text":{flex:1,color:"#000000",fontSize:"14",fontWeight:"normal"},"uni-navigate-icon":{marginLeft:"15",color:"#999999",fontSize:"14",fontWeight:"normal"},"uni-list-cell":{position:"relative",flexDirection:"row",justifyContent:"flex-start",alignItems:"center"},"uni-list-cell-pd":{paddingTop:"22upx",paddingRight:"30upx",paddingBottom:"22upx",paddingLeft:"30upx"},"flex-r":{flexDirection:"row"},"flex-c":{flexDirection:"column"},"a-i-c":{alignItems:"center"},"j-c-c":{justifyContent:"center"},"list-item":{flexDirection:"row",paddingTop:"10",paddingRight:"10",paddingBottom:"10",paddingLeft:"10"},"@VERSION":2}},function(t,e,n){"use strict";function o(t,e,n,o,i,r,a,u,s,c){var l,p="function"==typeof t?t.options:t;if(s){p.components||(p.components={});var d=Object.prototype.hasOwnProperty;for(var f in s)d.call(s,f)&&!d.call(p.components,f)&&(p.components[f]=s[f])}if(c&&((c.beforeCreate||(c.beforeCreate=[])).unshift((function(){this[c.__module]=this})),(p.mixins||(p.mixins=[])).push(c)),e&&(p.render=e,p.staticRenderFns=n,p._compiled=!0),o&&(p.functional=!0),r&&(p._scopeId="data-v-"+r),a?(l=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),i&&i.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},p._ssrRegister=l):i&&(l=u?function(){i.call(this,this.$root.$options.shadowRoot)}:i),l)if(p.functional){p._injectStyles=l;var g=p.render;p.render=function(t,e){return l.call(e),g(t,e)}}else{var m=p.beforeCreate;p.beforeCreate=m?[].concat(m,l):[l]}return{exports:t,options:p}}n.d(e,"a",(function(){return o}))},function(t,e,n){Vue.prototype.__$appStyle__={},Vue.prototype.__merge_style&&Vue.prototype.__merge_style(n(3).default,Vue.prototype.__$appStyle__)},function(t,e,n){"use strict";n.r(e);var o=n(0),i=n.n(o);for(var r in o)"default"!==r&&function(t){n.d(e,t,(function(){return o[t]}))}(r);e.default=i.a},,function(t,e,n){"use strict";var o=n(16),i=n(9),r=n(1);var a=Object(r.a)(i.default,o.b,o.c,!1,null,null,"263ff436",!1,o.a,void 0);(function(t){this.options.style||(this.options.style={}),Vue.prototype.__merge_style&&Vue.prototype.__$appStyle__&&Vue.prototype.__merge_style(Vue.prototype.__$appStyle__,this.options.style),Vue.prototype.__merge_style?Vue.prototype.__merge_style(n(20).default,this.options.style):Object.assign(this.options.style,n(20).default)}).call(a),e.default=a.exports},,,,function(t,e,n){"use strict";var o=n(10),i=n.n(o);e.default=i.a},function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var o=n(24),i=t("Zmt-Module"),r=t("TestModule"),a=t("uniplugin_module_ox"),u=t("Face-Module"),s=t("modal"),c={onLoad:function(){this.initAPPListener()},onReady:function(){this.logs.push("\u5f53\u524d\u65f6\u95f4:"+this.getTime())},data:function(){return{logs:["LOG VIEW"]}},methods:{initAPPListener:function(){plus.globalEvent.addEventListener("TestEvent",(function(t){s.toast({message:"TestEvent\u6536\u5230\uff1a"+t.msg,duration:1.5})}))},faceAsyncFunc:function(){var t=this;this.log("\u6267\u884cfaceModule.faceAsyncFunc"),u.faceAsyncFunc({name:"unimp",age:1},(function(e){s.toast({message:e,duration:1.5}),t.log(JSON.stringify(e))}))},tcpAsyncFunc:function(){var t=this;this.log("\u5f00\u542fTcp Server."),i.tcpAsyncFunc({name:"unimp",age:1},(function(e){s.toast({message:e,duration:2}),t.log("tcp\u63a5\u6536:"+e.code)}))},testFun2:function(){var t=i.testSyncFunc({name:"unimp",age:1});s.toast({message:t,duration:1.5})},testAsyncFunc:function(){r.testAsyncFunc({name:"unimp",age:1},(function(t){s.toast({message:t,duration:1.5})}))},testSyncFunc:function(){var t=r.testSyncFunc({name:"unimp",age:1});s.toast({message:t,duration:1.5})},testAsyncFunc2:function(){a.testAsyncFunc2({name:"unimp",age:1},(function(t){s.toast({message:t,duration:1.5})}))},testSyncFunc2:function(){var t=a.testSyncFunc2({name:"unimp",age:1});s.toast({message:t,duration:1.5})},log:function(t){this.logs.push(this.getTime()+" ".concat(t))},getTime:function(){return(0,o.timeFormat)(new Date,"mm/dd hh:MM:ss")},gotoNativePage:function(){r.gotoNativePage()}}};e.default=c}).call(this,n(19).default)},function(t,e){t.exports={content:{fontSize:"12"},btn:{marginTop:"3",marginRight:"3",marginBottom:"3",marginLeft:"3"},tips:{fontSize:"11",color:"#808080",fontWeight:"800"},console:{backgroundColor:"#D3D3D3",paddingTop:"20rpx",paddingRight:"20rpx",paddingBottom:"20rpx",paddingLeft:"20rpx"},log:{color:"#8B0000",fontSize:"11",fontWeight:"800"},"@VERSION":2}},,,,,function(t,e,n){"use strict";n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return i})),n.d(e,"a",(function(){}));var o=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("scroll-view",{staticStyle:{flexDirection:"column"},attrs:{scrollY:!0,showScrollbar:!0,enableBackToTop:!0,bubble:"true"}},[n("div",{staticClass:["content"]},[n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.gotoNativePage}},[t._v("\u8df3\u8f6c\u539f\u751fActivity")]),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.tcpAsyncFunc}},[t._v("[\u5f00\u542fTcpServer]")]),n("u-text",{staticClass:["tips"],appendAsTree:!0,attrs:{append:"tree"}},[t._v("\n\t\t\u70b9\u51fb\u540e\u5c06\u5f00\u542fTcpServer. \u672c\u673aIP: 192.168.1.64 \u7aef\u53e3\uff1a16666\n\t")]),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.faceAsyncFunc}},[t._v("[\u767e\u5ea6\u4eba\u8138SDK\u6388\u6743]")]),n("u-text",{staticClass:["tips"],appendAsTree:!0,attrs:{append:"tree"}},[t._v("\n\t\t\u70b9\u51fb\u540e\u5c06\u8fdb\u884c\u767e\u5ea6\u4eba\u8138SDK\u521d\u59cb\u5316\u53ca\u6388\u6743\u7533\u8bf7,\u8be5\u6388\u6743\u7801\u5199\u6b7b\u5728Android\u7aefzmt_module\u5185faceClass,\u56e0\u5df2\u4f7f\u7528\u8fc7,\u5c06\u8fd4\u56de\u5df2\u88ab\u5360\u7528\u63d0\u793a.\n\t")]),n("view",{staticClass:["console"]},t._l(t.logs,(function(e){return n("u-text",{staticClass:["log"],appendAsTree:!0,attrs:{append:"tree"}},[t._v(t._s(e))])})),0),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.testAsyncFunc2}},[t._v("uniplugin_module_ox testAsyncFunc2")]),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.testSyncFunc2}},[t._v("uniplugin_module_ox testSyncFunc2")]),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.testAsyncFunc}},[t._v("uniplugin_module testAsyncFunc")]),n("button",{staticClass:["btn"],attrs:{type:"primary"},on:{click:t.testSyncFunc}},[t._v("uniplugin_module testSyncFunc")])],1)])},i=[]},,,function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return weex.requireModule(t)}},function(t,e,n){"use strict";n.r(e);var o=n(11),i=n.n(o);for(var r in o)"default"!==r&&function(t){n.d(e,t,(function(){return o[t]}))}(r);e.default=i.a},,,function(t,e,n){"use strict";n.r(e);n(2);var o=n(5);"undefined"==typeof Promise||Promise.prototype.finally||(Promise.prototype.finally=function(t){var e=this.constructor;return this.then((function(n){return e.resolve(t()).then((function(){return n}))}),(function(n){return e.resolve(t()).then((function(){throw n}))}))}),o.default.mpType="page",o.default.route="pages/sample/ext-module",o.default.el="#root",new Vue(o.default)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.timeFormat=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"yyyy-mm-dd";t||(t=Number(new Date));"string"==typeof t&&t.indexOf("-")>0&&(t=t.replace(/\-/g,"/"));10==t.toString().length&&(t*=1e3);var n,o=new Date(t),i={"y+":o.getFullYear().toString(),"m+":(o.getMonth()+1).toString(),"d+":o.getDate().toString(),"h+":o.getHours().toString(),"M+":o.getMinutes().toString(),"s+":o.getSeconds().toString()};for(var r in i)(n=new RegExp("("+r+")").exec(e))&&(e=e.replace(n[1],1==n[1].length?i[r]:i[r].padStart(n[1].length,"0")));return e},e.getDurationTime=function(t){var e="",n=parseInt(t/3600),o=parseInt(t%3600/60),i=parseInt(t%3600%60);n>0&&(e+=(n=n<10?"0"+n:n)+":");return e+=(o=o<10?"0"+o:o)+":"+(i=i<10?"0"+i:i)},String.prototype.padStart||(String.prototype.padStart=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:" ";if("[object String]"!==Object.prototype.toString.call(e))throw new TypeError("fillString must be String");var n=this;if(n.length>=t)return String(n);for(var o=t-n.length,i=Math.ceil(o/e.length);i>>=1;)e+=e,1===i&&(e+=e);return e.slice(0,o)+n})}]); \ No newline at end of file diff --git a/uniappWWW/unipluginDemo/pages/sample/ext-module-vue.vue b/uniappWWW/unipluginDemo/pages/sample/ext-module-vue.vue index c34a4e1..7313dfb 100755 --- a/uniappWWW/unipluginDemo/pages/sample/ext-module-vue.vue +++ b/uniappWWW/unipluginDemo/pages/sample/ext-module-vue.vue @@ -2,7 +2,8 @@
- + + 点击后将开启TcpServer. 本机IP: 192.168.1.64 端口:16666 @@ -82,10 +83,10 @@ this.log(JSON.stringify(ret)) }) }, - tcpAsyncFunc(){ + initTcp(){ // 调用异步方法 this.log("Click Tcp Server.") - zmtModule.tcpAsyncFunc({ + zmtModule.initTcp({ 'port':"16666", }, (ret) => { @@ -96,6 +97,19 @@ this.log("invoke:"+JSON.stringify(ret)) }) }, + closeTcp(){ + // 调用异步方法 + this.log("Click Tcp Server.") + zmtModule.closeTcp({ + }, + (ret) => { + modal.toast({ + message: ret, + duration: 2 + }); + this.log("invoke:"+JSON.stringify(ret)) + }) + }, testFun2(){ // 调用同步方法 var ret = zmtModule.testSyncFunc({ diff --git a/zmt_module/src/main/java/io/dcloud/zmt_module/tcpServer/TCPTask.java b/zmt_module/src/main/java/io/dcloud/zmt_module/tcpServer/TCPTask.java index 21606da..2ef93fb 100644 --- a/zmt_module/src/main/java/io/dcloud/zmt_module/tcpServer/TCPTask.java +++ b/zmt_module/src/main/java/io/dcloud/zmt_module/tcpServer/TCPTask.java @@ -17,6 +17,7 @@ public class TCPTask { TcpServer server = new TcpServer(); Thread myThread; + Boolean stopThread = false; // TCP task public void task(final Integer port, final UniJSCallback uniJSCallback){ // Android 4.0 之后不能在主线程中请求HTTP请求 @@ -33,6 +34,10 @@ public class TCPTask { server.initSocket(port,uniJSCallback); while (true){ + if(stopThread){ + break; + } + String tcp_receive_message = server.receiveMessage(SocketConfig.UTF_8);//接收消息 if(tcp_receive_message!=null){ @@ -67,4 +72,9 @@ public class TCPTask { myThread.start(); } + public void closeTask(){ + this.stopThread = true; + server.close(); + } + } diff --git a/zmt_module/src/main/java/io/dcloud/zmt_module/tcpServer/TcpServer.java b/zmt_module/src/main/java/io/dcloud/zmt_module/tcpServer/TcpServer.java index c516410..bc22b8a 100644 --- a/zmt_module/src/main/java/io/dcloud/zmt_module/tcpServer/TcpServer.java +++ b/zmt_module/src/main/java/io/dcloud/zmt_module/tcpServer/TcpServer.java @@ -42,7 +42,7 @@ public class TcpServer { public void initSocket(int port, UniJSCallback uniJSCallback){ System.out.println(TAG+"initSocket"); try{ - if (mServerSocket != null) { mServerSocket.close(); mServerSocket = null; } +// if (mServerSocket != null) { mServerSocket.close(); mServerSocket = null; } if (mServerSocket==null){ mServerSocket = new ServerSocket(port); @@ -59,34 +59,34 @@ public class TcpServer { uniJSCallback.invokeAndKeepAlive(data); - while (true){ - String tcp_receive_message = receiveMessage(SocketConfig.UTF_8);//接收消息 - - if(tcp_receive_message!=null){ - System.out.println(TAG+"接收消息:"+tcp_receive_message); - String send_msg = "App received tcp message!"; //回发socket消息,确认接收 - send_msg = SocketHelper.getMessageByReadLine(send_msg); - sendMessage(send_msg, SocketConfig.UTF_8);//回发消息 - - JSONObject data_receive = new JSONObject(); - data_receive.put("threadID", Thread.currentThread().getId()); - data_receive.put("threadName", Thread.currentThread().getName()); -// data.put("message", server.); -// data.put("message", tcp_receive_message); - data_receive.put("message", tcp_receive_message); -// myCallback.tcpCallback(data); -// myTcpCallback.tcpCallback(data);//回调到zmtClass给uni端 - - uniJSCallback.invokeAndKeepAlive(data_receive); - } - - try { - Thread.sleep(1000); //定义休眠时间 - } catch (InterruptedException e) { - e.printStackTrace(); - } - - } +// while (true){ +// String tcp_receive_message = receiveMessage(SocketConfig.UTF_8);//接收消息 +// +// if(tcp_receive_message!=null){ +// System.out.println(TAG+"接收消息:"+tcp_receive_message); +// String send_msg = "App received tcp message!"; //回发socket消息,确认接收 +// send_msg = SocketHelper.getMessageByReadLine(send_msg); +// sendMessage(send_msg, SocketConfig.UTF_8);//回发消息 +// +// JSONObject data_receive = new JSONObject(); +// data_receive.put("threadID", Thread.currentThread().getId()); +// data_receive.put("threadName", Thread.currentThread().getName()); +//// data.put("message", server.); +//// data.put("message", tcp_receive_message); +// data_receive.put("message", tcp_receive_message); +//// myCallback.tcpCallback(data); +//// myTcpCallback.tcpCallback(data);//回调到zmtClass给uni端 +// +// uniJSCallback.invokeAndKeepAlive(data_receive); +// } +// +// try { +// Thread.sleep(1000); //定义休眠时间 +// } catch (InterruptedException e) { +// e.printStackTrace(); +// } +// +// } } diff --git a/zmt_module/src/main/java/io/dcloud/zmt_module/zmtClass.java b/zmt_module/src/main/java/io/dcloud/zmt_module/zmtClass.java index 7803cb2..500b670 100644 --- a/zmt_module/src/main/java/io/dcloud/zmt_module/zmtClass.java +++ b/zmt_module/src/main/java/io/dcloud/zmt_module/zmtClass.java @@ -13,11 +13,11 @@ public class zmtClass extends UniModule { String TAG = "module plugin"; // final AbsSDKInstance uniSDK = this.mUniSDKInstance;//定义uniSDK - + TCPTask myTask = new TCPTask(); //run ui thread @UniJSMethod(uiThread = true) - public void tcpAsyncFunc(JSONObject options, final UniJSCallback callback) { - Log.e(TAG, "tcpAsyncFunc:"+options); + public void initTcp(JSONObject options, final UniJSCallback callback) { + Log.e(TAG, "tcpAsyncFunc:"+options+myTask.toString()); Integer port = 16666;//默认端口,当uni传递port参数时,采用传递port初始化tcp String s_port = options.getString("port"); @@ -28,7 +28,15 @@ public class zmtClass extends UniModule { //开启TCP,传入jsCallback - new TCPTask().task(port, callback); + if(myTask!=null){ + myTask.task(port, callback); + }else{ + JSONObject data = new JSONObject(); + data.put("code", "0"); + data.put("toast", "请勿重复开启"); + callback.invokeAndKeepAlive(data); + } + // 全局回调 // Map params=new HashMap<>(); @@ -37,6 +45,21 @@ public class zmtClass extends UniModule { } + //run JS thread + @UniJSMethod(uiThread = true) + public void closeTcp(JSONObject options, final UniJSCallback callback){ + Log.e(TAG, "testSyncFunc--zmt2"); + JSONObject data = new JSONObject(); + data.put("code", "0"); + data.put("toast", "closeTcp"); + if(myTask!=null){ + myTask.closeTask(); + myTask = null; + } + + callback.invokeAndKeepAlive(data); + } + @UniJSMethod(uiThread = true) public void testAsyncFunc(JSONObject options, UniJSCallback callback) { Log.e(TAG, "testAsyncFunc--zmt:"+options);