初始化
parent
5d1ff814ce
commit
fd8d7d611c
|
@ -1,5 +1,13 @@
|
||||||
import request from '@/utils/request'
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
|
||||||
|
export function addOrUpd(data) {
|
||||||
|
return request({
|
||||||
|
url: '/market/api/addOrUpd',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
export function upd(data) {
|
export function upd(data) {
|
||||||
return request({
|
return request({
|
||||||
url: '/market/api/upd',
|
url: '/market/api/upd',
|
||||||
|
|
|
@ -1,5 +1,11 @@
|
||||||
import request from '@/utils/request'
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
export function upddata(data) {
|
||||||
|
return request({
|
||||||
|
url: '/market/firminfo/upd/'+data,
|
||||||
|
method: 'post'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
export function edit(data) {
|
export function edit(data) {
|
||||||
return request({
|
return request({
|
||||||
|
|
|
@ -87,7 +87,7 @@ export default {
|
||||||
const url = `http://10.0.2.1:8080/market/alipay/pay?subject=${this.pay.subject}&totalAmount=${this.pay.totalAmount}`;
|
const url = `http://10.0.2.1:8080/market/alipay/pay?subject=${this.pay.subject}&totalAmount=${this.pay.totalAmount}`;
|
||||||
pay(this.pay).then(res=>{
|
pay(this.pay).then(res=>{
|
||||||
console.log(res)
|
console.log(res)
|
||||||
window.open(url, '_self');
|
//window.open(url, '_self');
|
||||||
if(200==res.code){
|
if(200==res.code){
|
||||||
this.firminfo.firmId=this.firminfoForm.firmId
|
this.firminfo.firmId=this.firminfoForm.firmId
|
||||||
this.firminfo.firmScore=this.pay.totalAmount
|
this.firminfo.firmScore=this.pay.totalAmount
|
||||||
|
|
|
@ -144,9 +144,25 @@
|
||||||
<el-form-item label="返回报文" prop="pass">
|
<el-form-item label="返回报文" prop="pass">
|
||||||
<span>{{apimsg.sysSerial}}</span>
|
<span>{{apimsg.sysSerial}}</span>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-button @click="test()">申请</el-button>
|
||||||
</el-form>
|
</el-form>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
|
<el-dialog
|
||||||
|
title="申请"
|
||||||
|
:visible.sync="dialogVisible"
|
||||||
|
width="30%">
|
||||||
|
<el-form :model="apiQueryParams" status-icon :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
|
||||||
|
<el-form-item label="次数" prop="pass">
|
||||||
|
<el-input v-model="apiQueryParams.myNum" autocomplete="off"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<span slot="footer" class="dialog-footer">
|
||||||
|
<el-button @click="dialogVisible = false">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="buy()">确 定</el-button>
|
||||||
|
</span>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -155,6 +171,8 @@ import { listApitype, getApitype, delApitype, addApitype, updateApitype } from "
|
||||||
import {getAirQuality, pay} from "../../../api/market/apitype";
|
import {getAirQuality, pay} from "../../../api/market/apitype";
|
||||||
import * as url from "url";
|
import * as url from "url";
|
||||||
import {listMsg} from "../../../api/reqmsg/msg";
|
import {listMsg} from "../../../api/reqmsg/msg";
|
||||||
|
import {addOrUpd} from "../../../api/api/api";
|
||||||
|
import {upddata} from "../../../api/firminfo/firminfo";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "Apitype",
|
name: "Apitype",
|
||||||
|
@ -208,13 +226,26 @@ export default {
|
||||||
apimsg:{},
|
apimsg:{},
|
||||||
reqmsg:[],
|
reqmsg:[],
|
||||||
reqmsgs:{},
|
reqmsgs:{},
|
||||||
|
apiQueryParams:{},
|
||||||
|
Layout:"",
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getList();
|
this.getList();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
buy(){
|
||||||
|
this.Layout=this.apiQueryParams.myNum*this.apimsg.sysNumber
|
||||||
|
upddata(this.Layout).then(res=>{
|
||||||
|
if (res.code==200){
|
||||||
|
addOrUpd(this.apiQueryParams).then(res=>{
|
||||||
|
console.log(res)
|
||||||
|
this.dialogVisible=false
|
||||||
|
location.reload()
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
getreqmsg(){
|
getreqmsg(){
|
||||||
listMsg(this.reqmsgs).then(res=>{
|
listMsg(this.reqmsgs).then(res=>{
|
||||||
this.reqmsg=res.data.rows
|
this.reqmsg=res.data.rows
|
||||||
|
@ -222,6 +253,7 @@ export default {
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
jkwd(customer){
|
jkwd(customer){
|
||||||
|
this.apiQueryParams.apiId=customer.sysId
|
||||||
this.reqmsgs.sysId=customer.sysId
|
this.reqmsgs.sysId=customer.sysId
|
||||||
this.sysId=customer.sysId
|
this.sysId=customer.sysId
|
||||||
this.apimsg=customer
|
this.apimsg=customer
|
||||||
|
@ -232,17 +264,8 @@ export default {
|
||||||
this.dialogVisible=true
|
this.dialogVisible=true
|
||||||
},
|
},
|
||||||
test(){
|
test(){
|
||||||
getAirQuality(this.sysId,this.unkownvalue).then(response =>{
|
this.dialogVisible=true
|
||||||
console.log(response)
|
|
||||||
this.jsonData=response
|
|
||||||
if(response.reason!=null){
|
|
||||||
this.jsonData=response.reason
|
|
||||||
}
|
|
||||||
if(response.result!=null){
|
|
||||||
this.jsonData=response.result
|
|
||||||
}
|
|
||||||
this.dialogVisible=true
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
async gotoMaintained(customer){
|
async gotoMaintained(customer){
|
||||||
this.pay.subject=customer.sysIntro
|
this.pay.subject=customer.sysIntro
|
||||||
|
|
Loading…
Reference in New Issue