Merge branch 'master' of https://gitea.qinmian.online/TreeData/cloud-web
commit
8d98edab71
|
@ -37,3 +37,23 @@ export function phonePlace(tel) {
|
||||||
method: 'GET'
|
method: 'GET'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function getIpPlace(ip) {
|
||||||
|
return request({
|
||||||
|
url: '/port/list/getIpPlace?ip='+ip,
|
||||||
|
method: 'GET'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
export function getHeadlines() {
|
||||||
|
return request({
|
||||||
|
url: '/port/list/getHeadlines',
|
||||||
|
method: 'GET'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
export function getBirthday(data) {
|
||||||
|
return request({
|
||||||
|
url: '/port/list/getBirthday',
|
||||||
|
method: 'post',
|
||||||
|
data:data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
|
@ -15,11 +15,11 @@
|
||||||
{{connector.connectorPrice}}/次<br>
|
{{connector.connectorPrice}}/次<br>
|
||||||
|
|
||||||
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testPhone()" v-if="connector.connectorName=='手机号查询归属地'">测试API</el-button>
|
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testPhone()" v-if="connector.connectorName=='手机号查询归属地'">测试API</el-button>
|
||||||
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testIP(connector)" v-if="connector.connectorName=='IP查询归属地'">测试</el-button>
|
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testIP()" v-if="connector.connectorName=='IP查询归属地'">测试API</el-button>
|
||||||
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testNews(connector)" v-if="connector.connectorName=='新闻头条'">测试</el-button>
|
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testNews()" v-if="connector.connectorName=='新闻头条'">测试API</el-button>
|
||||||
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testWeather(connector)" v-if="connector.connectorName=='气象预警'">测试</el-button>
|
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testWeather()" v-if="connector.connectorName=='气象预警'">测试</el-button>
|
||||||
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testBirthdate(connector)" v-if="connector.connectorName=='生辰助手'">测试</el-button>
|
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testBirthdate()" v-if="connector.connectorName=='生辰助手'">测试API</el-button>
|
||||||
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testMailbox(connector)" v-if="connector.connectorName=='邮编查询'">测试</el-button>
|
<el-button type="primary" style="float: right; padding: 10px 10px" @click="testMailbox()" v-if="connector.connectorName=='邮编查询'">测试</el-button>
|
||||||
</el-card>
|
</el-card>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
@ -27,7 +27,7 @@
|
||||||
<el-dialog title="手机查询归属地" :visible.sync="dialogFormVisible">
|
<el-dialog title="手机查询归属地" :visible.sync="dialogFormVisible">
|
||||||
<el-form :model="formInline">
|
<el-form :model="formInline">
|
||||||
<el-form-item label="手机号" :label-width="formLabelWidth">
|
<el-form-item label="手机号" :label-width="formLabelWidth">
|
||||||
<el-input v-model="formInline.tel" autocomplete="off"></el-input>
|
<el-input v-model="formInline.tel" autocomplete="off" placeholder="请输入手机号"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<span style="font-weight: bold;font-size: 20px" v-if="formInline.reason==true">
|
<span style="font-weight: bold;font-size: 20px" v-if="formInline.reason==true">
|
||||||
省份:{{this.formInline.province}}<br>
|
省份:{{this.formInline.province}}<br>
|
||||||
|
@ -44,20 +44,73 @@
|
||||||
|
|
||||||
<!--IP查询归属地-->
|
<!--IP查询归属地-->
|
||||||
<el-dialog title="IP查询归属地" :visible.sync="dialogFormVisible1">
|
<el-dialog title="IP查询归属地" :visible.sync="dialogFormVisible1">
|
||||||
<el-form :model="formInline">
|
<el-form :model="formIp">
|
||||||
<el-form-item label="IP" :label-width="formLabelWidth">
|
<el-form-item label="IP" >
|
||||||
<el-input v-model="formInline.tel" autocomplete="off"></el-input>
|
<el-input v-model="formIp.ip" autocomplete="off" placeholder="请输入ip"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<span style="font-weight: bold;font-size: 20px" v-if="formInline.reason==true">
|
<span style="font-weight: bold;font-size: 20px" v-if="formIp.reason==true">
|
||||||
省份:{{this.formInline.province}}<br>
|
国家:{{this.formIp.country}}<br>
|
||||||
城市:{{this.formInline.city}}<br>
|
省份:{{this.formIp.province}}<br>
|
||||||
区号:{{this.formInline.areacode}}<br>
|
城市:{{this.formIp.city}}<br>
|
||||||
邮编:{{this.formInline.zip}}<br>
|
运营商:{{this.formIp.isp}}<br>
|
||||||
运营商:{{this.formInline.company}}<br>
|
|
||||||
</span>
|
</span>
|
||||||
</el-form>
|
</el-form>
|
||||||
<div slot="footer" class="dialog-footer">
|
<div slot="footer" class="dialog-footer">
|
||||||
<el-button type="primary" @click="phonePlace()">发起请求</el-button>
|
<el-button type="primary" @click="getIpPlace()">发起请求</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
<!-- 新闻头条-->
|
||||||
|
<el-dialog title="新闻头条" :visible.sync="dialogTableVisible">
|
||||||
|
<el-table :data="gridData">
|
||||||
|
<el-table-column property="title" label="新闻标题" width="150"></el-table-column>
|
||||||
|
<el-table-column property="date" label="新闻时间" width="200"></el-table-column>
|
||||||
|
<el-table-column property="category" label="新闻分类"></el-table-column>
|
||||||
|
<el-table-column property="authorName" label="新闻来源"></el-table-column>
|
||||||
|
</el-table>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
<!--生辰助手-->
|
||||||
|
<el-dialog title="生辰助手" :visible.sync="dialogFormVisible2">
|
||||||
|
<el-form :model="formBirthday">
|
||||||
|
<el-form-item label="年" >
|
||||||
|
<el-input v-model="formBirthday.year" autocomplete="off" placeholder="请输入年份"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="月" >
|
||||||
|
<el-input v-model="formBirthday.month" autocomplete="off" placeholder="请输入月份"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="日" >
|
||||||
|
<el-input v-model="formBirthday.day" autocomplete="off" placeholder="请输入几号"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="时" >
|
||||||
|
<el-input v-model="formBirthday.hour" autocomplete="off" placeholder="请输入几点"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<span style="font-weight: bold;font-size: 20px" v-if="formBirthday.reason==true">
|
||||||
|
{{this.formBirthday.years}}<br>
|
||||||
|
{{this.formBirthday.months}}<br>
|
||||||
|
{{this.formBirthday.days}}<br>
|
||||||
|
{{this.formBirthday.animal}}<br>
|
||||||
|
{{this.formBirthday.imonthcn}}<br>
|
||||||
|
{{this.formBirthday.idaycn}}<br>
|
||||||
|
{{this.formBirthday.cyear}}<br>
|
||||||
|
{{this.formBirthday.cmonth}}<br>
|
||||||
|
{{this.formBirthday.cday}}<br>
|
||||||
|
{{this.formBirthday.gzyear}}<br>
|
||||||
|
{{this.formBirthday.gzmonth}}<br>
|
||||||
|
{{this.formBirthday.gzday}}<br>
|
||||||
|
{{this.formBirthday.isleap}}<br>
|
||||||
|
{{this.formBirthday.ncweek}}<br>
|
||||||
|
{{this.formBirthday.isterm}}<br>
|
||||||
|
{{this.formBirthday.term}}<br>
|
||||||
|
{{this.formBirthday.astro}}<br>
|
||||||
|
{{this.formBirthday.eightall}}<br>
|
||||||
|
{{this.formBirthday.fiveall}}
|
||||||
|
</span>
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button type="primary" @click="getBirthday()">发起请求</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
|
@ -69,6 +122,9 @@
|
||||||
import {findConnectorList} from "@/api/port/port";
|
import {findConnectorList} from "@/api/port/port";
|
||||||
import index from "vuex";
|
import index from "vuex";
|
||||||
import {phonePlace} from "@/api/port/port";
|
import {phonePlace} from "@/api/port/port";
|
||||||
|
import {getIpPlace} from "@/api/port/port";
|
||||||
|
import {getHeadlines} from "@/api/port/port";
|
||||||
|
import {getBirthday} from "@/api/port/port";
|
||||||
export default {
|
export default {
|
||||||
//import引入的组件需要注入到对象中才能使用"
|
//import引入的组件需要注入到对象中才能使用"
|
||||||
components: {},
|
components: {},
|
||||||
|
@ -78,6 +134,7 @@ export default {
|
||||||
|
|
||||||
return {
|
return {
|
||||||
connectorList:[],
|
connectorList:[],
|
||||||
|
gridData:[],
|
||||||
form:{},
|
form:{},
|
||||||
// 手机号查询归属地formInline
|
// 手机号查询归属地formInline
|
||||||
formInline:{
|
formInline:{
|
||||||
|
@ -89,9 +146,50 @@ export default {
|
||||||
company:"",
|
company:"",
|
||||||
reason:"",
|
reason:"",
|
||||||
},
|
},
|
||||||
|
|
||||||
|
formIp:{
|
||||||
|
ip:"",
|
||||||
|
country:"",
|
||||||
|
province:"",
|
||||||
|
city:"",
|
||||||
|
isp:"",
|
||||||
|
reason:"",
|
||||||
|
},
|
||||||
|
formBirthday:{
|
||||||
|
year:"",
|
||||||
|
month:"",
|
||||||
|
day:"",
|
||||||
|
hour:"",
|
||||||
|
years:"",
|
||||||
|
months:"",
|
||||||
|
days:"",
|
||||||
|
animal:"",
|
||||||
|
imonthcn:"",
|
||||||
|
idaycn:"",
|
||||||
|
cyear:"",
|
||||||
|
cmonth:"",
|
||||||
|
cday:"",
|
||||||
|
gzyear:"",
|
||||||
|
gzmonth:"",
|
||||||
|
gzday:"",
|
||||||
|
isleap:"",
|
||||||
|
ncweek:"",
|
||||||
|
isterm:"",
|
||||||
|
term:"",
|
||||||
|
astro:"",
|
||||||
|
eightall:"",
|
||||||
|
fiveall:"",
|
||||||
|
reason:"",
|
||||||
|
},
|
||||||
|
formNews:{
|
||||||
|
news:"",
|
||||||
|
reason:"",
|
||||||
|
},
|
||||||
// IP查询归属地
|
// IP查询归属地
|
||||||
dialogFormVisible:false,
|
dialogFormVisible:false,
|
||||||
dialogFormVisible1:false,
|
dialogFormVisible1:false,
|
||||||
|
dialogFormVisible2:false,
|
||||||
|
dialogTableVisible:false,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
//计算属性 类似于data概念",
|
//计算属性 类似于data概念",
|
||||||
|
@ -107,6 +205,57 @@ export default {
|
||||||
watch: {},
|
watch: {},
|
||||||
//方法集合",
|
//方法集合",
|
||||||
methods: {
|
methods: {
|
||||||
|
getBirthday(){
|
||||||
|
getBirthday(this.formBirthday).then((res)=>{
|
||||||
|
console.log(res.data);
|
||||||
|
this.formBirthday.reason=true;
|
||||||
|
this.formBirthday.years=res.data.years;
|
||||||
|
this.formBirthday.months=res.data.months;
|
||||||
|
this.formBirthday.days=res.data.days;
|
||||||
|
this.formBirthday.animal=res.data.animal;
|
||||||
|
this.formBirthday.imonthcn=res.data.imonthcn;
|
||||||
|
this.formBirthday.idaycn=res.data.idaycn;
|
||||||
|
this.formBirthday.cyear=res.data.cyear;
|
||||||
|
this.formBirthday.cmonth=res.data.cmonth;
|
||||||
|
this.formBirthday.cday=res.data.cday;
|
||||||
|
this.formBirthday.gzyear=res.data.gzyear;
|
||||||
|
this.formBirthday.gzmonth=res.data.gzmonth;
|
||||||
|
this.formBirthday.gzday=res.data.gzday;
|
||||||
|
this.formBirthday.isleap=res.data.isleap;
|
||||||
|
this.formBirthday.ncweek=res.data.ncweek;
|
||||||
|
this.formBirthday.isterm=res.data.isterm;
|
||||||
|
this.formBirthday.term=res.data.term;
|
||||||
|
this.formBirthday.astro=res.data.astro;
|
||||||
|
// this.formBirthday.eightall=res.data.eightall;
|
||||||
|
// this.formBirthday.fiveall=res.data.fiveall;
|
||||||
|
|
||||||
|
})
|
||||||
|
},
|
||||||
|
testBirthdate(){
|
||||||
|
this.dialogFormVisible2=true;
|
||||||
|
},
|
||||||
|
testNews(){
|
||||||
|
getHeadlines().then((res)=>{
|
||||||
|
this.gridData=res.data;
|
||||||
|
this.dialogTableVisible=true;
|
||||||
|
})
|
||||||
|
},
|
||||||
|
getIpPlace(){
|
||||||
|
getIpPlace(this.formIp.ip).then((res)=>{
|
||||||
|
console.log(res.data);
|
||||||
|
if (200==res.code){
|
||||||
|
this.formIp.country=res.data.country;
|
||||||
|
this.formIp.province=res.data.province;
|
||||||
|
this.formIp.city=res.data.city;
|
||||||
|
this.formIp.isp=res.data.isp;
|
||||||
|
this.formIp.reason=true;
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
testIP(ip){
|
||||||
|
this.formIp.ip=ip;
|
||||||
|
this.dialogFormVisible1=true;
|
||||||
|
},
|
||||||
testPhone(tel){
|
testPhone(tel){
|
||||||
this.formInline.tel=tel;
|
this.formInline.tel=tel;
|
||||||
this.dialogFormVisible=true;
|
this.dialogFormVisible=true;
|
||||||
|
|
Loading…
Reference in New Issue