1 |
- import{d as o,g as a,w as r,T as i,n as c,j as t,F as n,B as u,z as l}from"./index.e6d6174e.js";import{U as m}from"./index.09405f55.js";import"./index.3dbd60dd.js";import"./index.83d3716a.js";import"./index.045f03fd.js";import"./index.d8c651bf.js";import"./use-height.8140ea04.js";import"./index.3d7e5752.js";import"./index.d92a5aca.js";import"./index.af99cf22.js";import"./index.17d70acf.js";import"./use-id.f239f36f.js";import"./icon_checkbox_default.2fe5d57e.js";import"./icon_checkbox-tenant.06c74bc2.js";import"./index.41be4a84.js";const p="_cashProtocol_ifi2b_1",h="_submit_ifi2b_4";var s={cashProtocol:p,submit:h},v=o({name:"cash-protocol",data(){return{realStatus:!0,url:""}},async mounted(){try{console.log(a.user);const e=a.user.data;!e.realName||!e.idCardNo?this.realStatus=!1:this.getDetail()}catch{}},methods:{async getDetail(){try{const e=await r.get("/api-teacher/sysUserContractRecord/queryLatestContractTemplate",{params:{contractType:"WITHDRAW"}});this.url=window.location.origin+window.location.pathname+"/pdf/web/viewer.html?file="+encodeURIComponent(e.data.origanalFileUrl)+"&btn=1"}catch{}},async onSubmit(){try{await r.get("/api-teacher/sysUserContractRecord/sign",{params:{contractType:"WITHDRAW"}}),setTimeout(()=>{i("\u7B7E\u7F72\u6210\u529F")},100),setTimeout(()=>{c({api:"openPageSuccess",content:{page:"WITHDRAW"}})},1e3)}catch{}},onSuccess(){this.realStatus=!0,this.getDetail()}},render(){return t("div",{class:s.cashProtocol},[this.realStatus?t(n,null,[t("iframe",{src:this.url,frameborder:"0",style:{width:"100%",height:"100vh",border:"none"}},null),t(u,{type:"primary",size:"large",block:!0,round:!0,class:s.submit,onClick:this.onSubmit},{default:()=>[l("\u6211\u5DF2\u9605\u8BFB\u5E76\u540C\u610F")]})]):t(m,{onSuccess:this.onSuccess},null)])}});export{v as default};
|