Browse Source

修改申请发票中的抬头信息逻辑

master
liaoxinyu 1 year ago
parent
commit
d7b1f4c59e
  1. 3
      common/js/api.js
  2. 39
      pages/Invoicing/Invoicing.vue
  3. 2
      unpackage/dist/build/web/index.html
  4. 2
      unpackage/dist/build/web/static/js/index.274d89bc.js
  5. 2
      unpackage/dist/build/web/static/js/pages-Invoiced-Invoiced.bd013849.js
  6. 3
      unpackage/dist/build/web/static/js/pages-Invoicing-Invoicing.a944516e.js
  7. 3
      unpackage/dist/build/web/static/js/pages-Invoicing-Invoicing.ad8d5b89.js
  8. 2
      unpackage/dist/build/web/static/js/pages-Invoicing-Invoicing~pages-index-index~pages-login-registerphone.3b75cc14.js
  9. 2
      unpackage/dist/build/web/static/js/pages-login-wxlogin.9f3f893f.js

3
common/js/api.js

@ -36,6 +36,9 @@ let API = {
wx(data, success, fail){
API.sendRequest('get', data, '/wechat/login/wx', success, fail)
},
getFeeInvoiceHead(data, success, fail, boolean=true){
API.sendRequest('get', data, '/api/InvoiceIssuance/getFeeInvoiceHead', success, fail, boolean)
},
// 通用api
request(url, data, success, fail, boolean=true){
API.sendRequest('post', data, url, success, fail, boolean)

39
pages/Invoicing/Invoicing.vue

@ -64,22 +64,24 @@
<view v-if="stepsIndex === 1">
<view class="lookup">
<view class="lookup-title">抬头信息</view>
<view class="lookup-title1" @click="Obtain"><uni-icons type="redo-filled" size="30rpx" color="#007aff"></uni-icons></view>
<!-- <view class="lookup-title1" @click="Obtain"><uni-icons type="redo-filled" size="30rpx" color="#007aff"></uni-icons></view> -->
</view>
<uni-forms :modelValue="list2" ref="form1">
<uni-forms-item label="抬头类型" required name="name" :label-width="90">
<!-- <uni-data-checkbox v-model="list2.type" :localdata="headerType"></uni-data-checkbox> -->
<radio-group @change="radioChange2" style="height: 100%;display: flex;align-items: center;">
<label v-for="(item,index) in headerType" :key="item.value">
<radio :value="item.value" :checked="list2.type === item.value" /><text>{{item.text}}</text>
<radio :value="item.value" :checked="list2.type === item.value" disabled /><text>{{item.text}}</text>
</label>
</radio-group>
</uni-forms-item>
<uni-forms-item label="名称" required name="name" :label-width="90">
<uni-easyinput type="text" v-model="list2.title" :inputBorder="false" placeholder="请输入抬头名称"></uni-easyinput>
<!-- <uni-easyinput type="text" disabled v-model="list2.title" :inputBorder="false" placeholder="请输入抬头名称"></uni-easyinput> -->
<view class="list3_box" :style="{color: list2.title ? '#000' : '#999'}">{{list2.title?list2.title:'请输入抬头名称'}}</view>
</uni-forms-item>
<uni-forms-item label="税号" required name="name" :label-width="90" v-if="list2.type=='0'||!list2.type">
<uni-easyinput type="text" v-model="list2.tax_number" @blur="taxiD" :inputBorder="false" placeholder="请输入纳税人识别号"></uni-easyinput>
<!-- <uni-easyinput type="text" disabled v-model="list2.tax_number" @blur="taxiD" :inputBorder="false" placeholder="请输入纳税人识别号"></uni-easyinput> -->
<view class="list3_box" :style="{color: list2.title ? '#000' : '#999'}">{{list2.tax_number?list2.tax_number:'请输入抬头名称'}}</view>
</uni-forms-item>
</uni-forms>
</view>
@ -339,6 +341,7 @@
// }
this.pay()
this.form1 = this.$refs.form.modelValue;
this.Obtain()
}
if(this.stepsIndex == 2){
@ -429,17 +432,23 @@
// });
// #endif
// #ifdef H5
wxApi.wxRegister(() => {
wx.invoke('chooseInvoiceTitle', {"scene": "1"}, function (res) {
let info = JSON.parse(res.choose_invoice_title_info);
_this.list2.type = info.type;
_this.list2.title = info.title;
_this.list2.address = info.companyAddress;
_this.list2.telephone = info.telephone;
_this.list2.bank_name = info.bankName;
_this.list2.bank_account = info.bankAccount;
_this.list2.tax_number = info.taxNumber;
})
// wxApi.wxRegister(() => {
// wx.invoke('chooseInvoiceTitle', {"scene": "1"}, function (res) {
// let info = JSON.parse(res.choose_invoice_title_info);
// _this.list2.type = info.type;
// _this.list2.title = info.title;
// _this.list2.address = info.companyAddress;
// _this.list2.telephone = info.telephone;
// _this.list2.bank_name = info.bankName;
// _this.list2.bank_account = info.bankAccount;
// _this.list2.tax_number = info.taxNumber;
// })
// })
API.getFeeInvoiceHead({}, res => {
_this.list2.type = String(res.data.type);
console.log(typeof _this.list2.type);
_this.list2.title = res.data.title;
_this.list2.tax_number = res.data.tax_number;
})
// #endif
},

2
unpackage/dist/build/web/index.html

@ -1,2 +1,2 @@
<!DOCTYPE html><html lang=zh-CN><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><title>Waterinvoice_uiapp</title><script>var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=./static/index.2da1efab.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script src=./static/js/chunk-vendors.0e233154.js></script><script src=./static/js/index.e50ea416.js></script></body></html>
document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=./static/index.2da1efab.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script src=./static/js/chunk-vendors.0e233154.js></script><script src=./static/js/index.274d89bc.js></script></body></html>

2
unpackage/dist/build/web/static/js/index.e50ea416.js → unpackage/dist/build/web/static/js/index.274d89bc.js

File diff suppressed because one or more lines are too long

2
unpackage/dist/build/web/static/js/pages-Invoiced-Invoiced.407f6048.js → unpackage/dist/build/web/static/js/pages-Invoiced-Invoiced.bd013849.js

File diff suppressed because one or more lines are too long

3
unpackage/dist/build/web/static/js/pages-Invoicing-Invoicing.a944516e.js

File diff suppressed because one or more lines are too long

3
unpackage/dist/build/web/static/js/pages-Invoicing-Invoicing.ad8d5b89.js

File diff suppressed because one or more lines are too long

2
unpackage/dist/build/web/static/js/pages-Invoicing-Invoicing~pages-index-index~pages-login-registerphone.50724391.js → unpackage/dist/build/web/static/js/pages-Invoicing-Invoicing~pages-index-index~pages-login-registerphone.3b75cc14.js

File diff suppressed because one or more lines are too long

2
unpackage/dist/build/web/static/js/pages-login-wxlogin.57758eec.js → unpackage/dist/build/web/static/js/pages-login-wxlogin.9f3f893f.js

@ -1 +1 @@
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-login-wxlogin"],{4207:function(e,t,n){"use strict";n.d(t,"b",(function(){return a})),n.d(t,"c",(function(){return o})),n.d(t,"a",(function(){}));var a=function(){var e=this.$createElement,t=this._self._c||e;return t("v-uni-view")},o=[]},"75b1":function(e,t,n){"use strict";n("6a54");var a=n("f5bd").default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=a(n("d599")),i={data:function(){return{code:"",state:"",state1:"",appId:"",redirectUri:""}},onLoad:function(e){this.checkWeChatCode()},methods:{checkWeChatCode:function(){var e=this;o.default.getWxCode({},(function(t){1==t.code&&(e.redirectUri=t.data.redirectUri,e.appId=t.data.appId,e.state=t.data.state,e.getCode())}))},getCode:function(){var e=encodeURIComponent("https://intp.xingtongworld.com/wechat/");window.location.href="https://open.weixin.qq.com/connect/oauth2/authorize?appid="+this.appId+"&redirect_uri="+e+"&response_type=code&scope=snsapi_userinfo&state="+this.state+"#wechat_redirect"}}};t.default=i},d599:function(e,t,n){"use strict";n("6a54");var a=n("f5bd").default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=a(n("9b1b")),i="https://intp.xingtongworld.com",d={baseUrl:i,getJsSdkData:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("post",e,"/wechat/Wechat/getJsSdkData",t,n,a)},getQrCode:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("get",e,"/api/InvoiceIssuance/getQrCode",t,n,a)},getApplyData:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("get",e,"/api/InvoiceIssuance/getApplyData",t,n,a)},Home:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("post",e,"/api/InvoiceIssuance/getList",t,n,a)},validateFeePay:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("post",e,"/api/InvoiceIssuance/validateFeePay",t,n,a)},sendSms:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("post",e,"/wechat/wechat/sendSms",t,n,a)},getWxCode:function(e,t,n){d.sendRequest("get",e,"/wechat/login/getWxCode",t,n)},wx:function(e,t,n){d.sendRequest("get",e,"/wechat/login/wx",t,n)},request:function(e,t,n,a){var o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4];d.sendRequest("post",t,e,n,a,o)},sendRequest:function(e,t,n,a,d,c){var s="";s="post"==e?"application/x-www-form-urlencoded":"application/json";var u={};c&&(u.header={"Content-Type":s,Accept:"application/json, text/javascript, */*; q=0.01",token:uni.getStorageSync("AccessToken")||""}),uni.request((0,o.default)((0,o.default)({url:i+n,method:e,data:t},u),{},{success:function(e){1!=e.data.code&&-8!=e.data.code?(-14!=e.data.code&&-997!=e.data.code||(uni.removeStorageSync("AccessToken"),uni.removeStorageSync("phone"),uni.removeStorageSync("openid"),setTimeout((function(){uni.$emit("tokenExpired"),uni.reLaunch({url:"/pages/index/index"})}),2600)),"/api/InvoiceIssuance/validateFeePay"!==n&&uni.showToast({title:e.data.msg||e.msg,icon:"none"})):a&&a(e.data)}}))}},c=d;t.default=c},db07:function(e,t,n){"use strict";n.r(t);var a=n("75b1"),o=n.n(a);for(var i in a)["default"].indexOf(i)<0&&function(e){n.d(t,e,(function(){return a[e]}))}(i);t["default"]=o.a},e411:function(e,t,n){"use strict";n.r(t);var a=n("4207"),o=n("db07");for(var i in o)["default"].indexOf(i)<0&&function(e){n.d(t,e,(function(){return o[e]}))}(i);var d=n("828b"),c=Object(d["a"])(o["default"],a["b"],a["c"],!1,null,"7d4c1523",null,!1,a["a"],void 0);t["default"]=c.exports}}]);
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-login-wxlogin"],{4207:function(e,t,n){"use strict";n.d(t,"b",(function(){return a})),n.d(t,"c",(function(){return o})),n.d(t,"a",(function(){}));var a=function(){var e=this.$createElement,t=this._self._c||e;return t("v-uni-view")},o=[]},"75b1":function(e,t,n){"use strict";n("6a54");var a=n("f5bd").default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=a(n("d599")),i={data:function(){return{code:"",state:"",state1:"",appId:"",redirectUri:""}},onLoad:function(e){this.checkWeChatCode()},methods:{checkWeChatCode:function(){var e=this;o.default.getWxCode({},(function(t){1==t.code&&(e.redirectUri=t.data.redirectUri,e.appId=t.data.appId,e.state=t.data.state,e.getCode())}))},getCode:function(){var e=encodeURIComponent("https://intp.xingtongworld.com/wechat/");window.location.href="https://open.weixin.qq.com/connect/oauth2/authorize?appid="+this.appId+"&redirect_uri="+e+"&response_type=code&scope=snsapi_userinfo&state="+this.state+"#wechat_redirect"}}};t.default=i},d599:function(e,t,n){"use strict";n("6a54");var a=n("f5bd").default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=a(n("9b1b")),i="https://intp.xingtongworld.com",d={baseUrl:i,getJsSdkData:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("post",e,"/wechat/Wechat/getJsSdkData",t,n,a)},getQrCode:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("get",e,"/api/InvoiceIssuance/getQrCode",t,n,a)},getApplyData:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("get",e,"/api/InvoiceIssuance/getApplyData",t,n,a)},Home:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("post",e,"/api/InvoiceIssuance/getList",t,n,a)},validateFeePay:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("post",e,"/api/InvoiceIssuance/validateFeePay",t,n,a)},sendSms:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("post",e,"/wechat/wechat/sendSms",t,n,a)},getWxCode:function(e,t,n){d.sendRequest("get",e,"/wechat/login/getWxCode",t,n)},wx:function(e,t,n){d.sendRequest("get",e,"/wechat/login/wx",t,n)},getFeeInvoiceHead:function(e,t,n){var a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];d.sendRequest("get",e,"/api/InvoiceIssuance/getFeeInvoiceHead",t,n,a)},request:function(e,t,n,a){var o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4];d.sendRequest("post",t,e,n,a,o)},sendRequest:function(e,t,n,a,d,c){var s="";s="post"==e?"application/x-www-form-urlencoded":"application/json";var u={};c&&(u.header={"Content-Type":s,Accept:"application/json, text/javascript, */*; q=0.01",token:uni.getStorageSync("AccessToken")||""}),uni.request((0,o.default)((0,o.default)({url:i+n,method:e,data:t},u),{},{success:function(e){1!=e.data.code&&-8!=e.data.code?(-14!=e.data.code&&-997!=e.data.code||(uni.removeStorageSync("AccessToken"),uni.removeStorageSync("phone"),uni.removeStorageSync("openid"),setTimeout((function(){uni.$emit("tokenExpired"),uni.reLaunch({url:"/pages/index/index"})}),2600)),"/api/InvoiceIssuance/validateFeePay"!==n&&uni.showToast({title:e.data.msg||e.msg,icon:"none"})):a&&a(e.data)}}))}},c=d;t.default=c},db07:function(e,t,n){"use strict";n.r(t);var a=n("75b1"),o=n.n(a);for(var i in a)["default"].indexOf(i)<0&&function(e){n.d(t,e,(function(){return a[e]}))}(i);t["default"]=o.a},e411:function(e,t,n){"use strict";n.r(t);var a=n("4207"),o=n("db07");for(var i in o)["default"].indexOf(i)<0&&function(e){n.d(t,e,(function(){return o[e]}))}(i);var d=n("828b"),c=Object(d["a"])(o["default"],a["b"],a["c"],!1,null,"7d4c1523",null,!1,a["a"],void 0);t["default"]=c.exports}}]);
Loading…
Cancel
Save