You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 lines
5.5 KiB
1 lines
5.5 KiB
(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-117eea8a"],{"18f9":function(e,t,i){"use strict";i.r(t);i("d81d"),i("b0c0"),i("cca6");var s=i("dd85"),r=i("a86b"),a=i("72d9"),o=i("0127"),n=i("2843"),c=i("7eb6"),d=i("7872"),l={name:"ElectronicInvoice",data:function(){return{orderField:{imgPath:""},isHidden:!1,options:[],formGroup:[],type:"",showIcons:!1,prevPath:"",reportId:""}},components:{formComponent:r.a,imgPreview:c.a},created:function(){this.invoice_type_list={10101:"增值税普通发票",10100:"增值税专用发票",10102:"增值税电子普通发票",10300:"形式发票",10301:"收据",10506:"航空运输电子客票行程单"}},mounted:function(){var e=this.$route.query,t=e.id,i=e.type,s=e.reportId;this.id=t,this.reportId=s,this.type=i,"ImageQuery"==this.prevPath?this.getImageElectronicInvoice(t):this.getSelectImg(t)},methods:{downLoadFile:function(){this.$file.downloadFile("api/manager/invoiceImage/download/".concat(this.orderField.id),"",this.orderField.fileName)},initFormGroup:function(e){var t={"客运汽车":n.a,"火车票":n.a,"航空运输电子客票行程单":n.a,"出租车发票":n.a,"船票":n.a,"增值税普通发票":a.a,"增值税专用发票":a.a,"增值税电子普通发票":a.a,"增值税普通发票(卷票)":a.a,"机动车销售统一发票":a.a,"机打发票":o.a,"定额发票":o.a,"过路费发票":o.a,"国际小票":o.a,"滴滴出行行程单":o.a,"完税证明":o.a,"多票":o.a,"手工发票":o.a}[e.invoiceType]||a.a;1==e.status?this.formGroup=t.map((function(e){return e.disabled=!0,e})):10102==e.ticketCode||1==e.checked?this.formGroup=t.map((function(e){return"po"==e.key||"desc"==e.key?e.disabled=!1:e.disabled=!0,e})):this.formGroup=t.map((function(e){return e.disabled=!1,e}))},getImageElectronicInvoice:function(e){var t=this;Object(s.s)(e).then((function(e){200==e.status?(e.result=Object(d.a)(e.result),t.orderField=e.result,t.orderField=Object.assign(t.orderField,{pretaxAmount:t.orderField.total}),t.orderField.imgPath=e.result.imgUri,t.orderField.validStatus=1==e.result.validStatus?"已验真":"未验真",t.initFormGroup(e.result)):t.$message.error(e.message)})).catch((function(e){t.$message.error(e.message)}))},getSelectImg:function(e){var t=this;Object(s.B)(e).then((function(e){200==e.status?(e.result=Object(d.a)(e.result),t.orderField=e.result,t.orderField=Object.assign(t.orderField,{pretaxAmount:t.orderField.total}),t.orderField.imgPath=e.result.imgUri,t.initFormGroup(e.result)):t.$message.error(e.message)})).catch((function(e){t.$message.error(e.message)}))},saveInvoice:function(){var e=this,t=Object.assign({},this.orderField);Object(s.j)(t).then((function(t){200==t.status?(e.$message.success(t.message),e.goBack(),e.$parent.initTable()):e.$message.error(t.message)})).catch((function(t){e.$message.error(t.message)}))},handlePendingInvoice:function(){this.$router.push({name:"ImageAdmin",query:{id:this.reportId}})},checkInvoice:function(){var e=this,t=Object.assign({},this.orderField);t.status=1,Object(s.j)(t).then((function(t){200==t.status?(e.$message.success(t.message),e.goBack(),e.$parent.initTable()):e.$message.error(t.message)})).catch((function(t){e.$message.error(t.message)}))},goBack:function(){this.$router.go(-1)}},beforeRouteEnter:function(e,t,i){i((function(e){e.prevPath=t.name}))}},u=(i("a750"),i("2877")),m=Object(u.a)(l,(function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"ElectronicInvoice p2"},[i("div",{staticClass:"w100 j-sb d-flex m-bottom-2 a-center p-relative"},[i("div",{staticClass:"f20 f-weight"},[e._v(" 发票详情 "),i("span",{staticClass:"c-red"},[e._v(e._s(e.orderField.total))])]),i("div",{staticClass:"d-flex"},[i("FeesButton",{attrs:{text:"取消",icon:"el-icon-upload2"},on:{buttonClick:e.goBack}}),i("FeesButton",{attrs:{text:"待匹配纸票"},on:{buttonClick:e.handlePendingInvoice}}),i("FeesButton",{attrs:{text:"保存发票",icon:"el-icon-upload2"},on:{buttonClick:e.saveInvoice}})],1)]),i("el-tabs",[i("el-tab-pane",{attrs:{label:"发票信息"}},[i("div",{staticClass:"d-flex"},[i("div",{staticClass:"flex-4"},[""!=e.orderField.ext02&&"image"!=e.type?i("el-alert",{attrs:{title:e.orderField.ext02,type:"warning",closable:!1,"show-icon":""}}):e._e(),i("h1",{staticClass:"m-top-1",staticStyle:{"font-size":"24px","font-weight":"bold"}},[e._v(" "+e._s(e.invoice_type_list[e.orderField.ticketCode])+" ")]),i("formComponent",{attrs:{formGroup:e.formGroup,orderField:e.orderField}})],1),i("div",{staticClass:"m-right-2",staticStyle:{width:"1px",height:"500px",background:"#ccc"}}),i("div",{staticClass:"flex-2",staticStyle:{"min-height":"500px",background:"#c0c2c4"}},[i("div",{staticClass:"m-right-2 h100 w100 d-flex a-center j-center flex-direction"},[i("imgPreview",{staticClass:"w100 h100",staticStyle:{margin:"0 !important"},attrs:{imgItem:{}},scopedSlots:e._u([{key:"title",fn:function(){return[e._v(" "+e._s(e.orderField.invoiceType)+" ")]},proxy:!0},{key:"image",fn:function(){return[i("el-image",{attrs:{src:e.orderField.imgPath,"preview-src-list":[e.orderField.imgPath]}})]},proxy:!0},{key:"date",fn:function(){return[e._v(" "+e._s(e.orderField.date)+" ")]},proxy:!0},{key:"footer",fn:function(){return[i("span",{on:{click:e.downLoadFile}},[e._v(e._s(e.orderField.fileName))])]},proxy:!0}])})],1)])])])],1)],1)}),[],!1,null,"d259d5b2",null);t.default=m.exports},"70e3":function(e,t,i){},7872:function(e,t,i){"use strict";t.a=function(e){return 0==e.status?e.status1="未处理":1==e.status?e.status1="已处理":2==e.status?e.status1="异常":3==e.status&&(e.status1="pending"),e}},a750:function(e,t,i){"use strict";var s=i("70e3");i.n(s).a}}]);
|