|
@@ -59,18 +59,9 @@ const app=createApp({
|
|
|
number:0,
|
|
|
locale:null,
|
|
|
options:[
|
|
|
- {
|
|
|
- value: 'zh',
|
|
|
- label: '中文',
|
|
|
- },
|
|
|
- {
|
|
|
- value: 'en',
|
|
|
- label: 'English',
|
|
|
- },
|
|
|
- {
|
|
|
- value: 'ja',
|
|
|
- label: 'にほんご',
|
|
|
- },
|
|
|
+ {value: 'zh', label: '中文',},
|
|
|
+ {value: 'en', label: 'English',},
|
|
|
+ {value: 'ja', label: 'にほんご',},
|
|
|
],
|
|
|
tomcat_res:""
|
|
|
}
|
|
@@ -81,8 +72,9 @@ const app=createApp({
|
|
|
},
|
|
|
|
|
|
changelang(type){
|
|
|
- console.log(locale);
|
|
|
- console.log("-----------changelang-----------------");
|
|
|
+ console.log("-----------change lang-----------------");
|
|
|
+ console.log("this.locale : "+this.locale);
|
|
|
+ console.log("locale"+locale);
|
|
|
locale.value=type;
|
|
|
},
|
|
|
interface_web(){
|
|
@@ -91,12 +83,18 @@ const app=createApp({
|
|
|
request.onload=function(){
|
|
|
console.log("parse tomcat server string");
|
|
|
const res=JSON.parse(request.responseText);
|
|
|
+
|
|
|
this.tomcat_res=res.message;
|
|
|
- console.log("res.message:"+res.message);
|
|
|
console.log("res:"+res);
|
|
|
- console.log("res[\"message\"]:"+res["message"]);
|
|
|
- console.log("tomcat_res"+this.tomcat_res);
|
|
|
- alert("this.tomcat_res : "+this.tomcat_res)
|
|
|
+ console.log("res[0].title :"+res[0].title);
|
|
|
+ console.log("res[0].author :"+res[0].author);
|
|
|
+ console.log("res[0].publisher :"+res[0].publisher);
|
|
|
+ console.log("res[0].pages :"+res[0].pages);
|
|
|
+ console.log("res[1][\"title\"] :"+res[1]["title"]);
|
|
|
+ console.log("res[1][\"author\"] :"+res[1]["author"]);
|
|
|
+ console.log("this.tomcat_res : "+this.tomcat_res);
|
|
|
+ console.log("tomcat_res : "+tomcat_res);
|
|
|
+ alert("this.tomcat_res : "+this.tomcat_res);
|
|
|
};
|
|
|
request.open("POST","http://ancientapes.cc:8080/mineluxuries/book");
|
|
|
request.send("test tomcat");
|