eidt-school-legacy.9bed8daf.js 6.4 KB

1
  1. System.register(["./index-legacy.eb062188.js","./index-legacy.ad813f4d.js","./logo-legacy.56c05c44.js","./area-legacy.b541a943.js","./index-legacy.930f2c38.js","./index-legacy.148f784c.js","./index-legacy.fecc738b.js","./index-legacy.3a3e070a.js","./index-legacy.bd6987bf.js","./index-legacy.b7c35e0c.js","./ImagePreview-legacy.747d0051.js","./index-legacy.fab451f1.js","./function-call-legacy.0bd16987.js","./index-legacy.918b8c74.js"],(function(e){"use strict";var a,o,n,t,l,s,c,d,i,r,u,g,p,m,A,f,b,R,y,h,w,x,Z,v,L;return{setters:[function(e){a=e.d,o=e.ag,n=e.ah,t=e.r,l=e.R,s=e.$,c=e.bJ,d=e.c,i=e.aj,r=e.q,u=e.a5,g=e.B,p=e.F,m=e.g,A=e.m,f=e.o,b=e.e},function(e){R=e.O},function(e){y=e.s,h=e.l},function(e){w=e.a},function(e){x=e.O},function(e){Z=e.C},function(e){v=e.I},function(e){L=e.F},function(){},function(){},function(){},function(){},function(){},function(){}],execute:function(){e("default",a({name:"school-detail",setup(){const e=o(),a=n(),V=t({list:[],info:{},showArea:!1,columns:[],showProvince:""}),j=t({address:"",logo:"",email:"",emergencyContact:"",addressLongitudeLatitude:""}),C=l();console.log(C.value);const M=async()=>{if(j.email){const e=/^[a-zA-Z0-9_.-]+@[a-zA-Z0-9-]+(\\.[a-zA-Z0-9-]+)*\.[a-zA-Z0-9]{2,6}$/;if(!j.email.match(e))return void f("请输入正确的邮箱")}if(j.address){try{await A.post("/api-school/school/update",{hideLoading:!1,data:{...j}}),"type"===a.query.page?e.go(-1):b({api:"back"})}catch(o){f(o.message)}console.log("submitInfo")}else f("请输入详细地址")};s((()=>{(async()=>{const e=(m.user.data.schoolInfos||[]).map((e=>e.id)).join(",");try{const{data:a}=await A.get(`/api-school/school/detail/${e}`,{});V.info=a,V.showProvince=a.provinceName+a.cityName,j.logo=a.logo,j.email=a.email,j.emergencyContact=a.emergencyContact,j.addressLongitudeLatitude=a.addressLongitudeLatitude,j.address=a.address}catch(a){f(a.message)}})()}));const W=()=>{C.value.startUpload()};return s((()=>{const e=[];w.forEach((a=>{const o={name:a.name,code:a.code,areas:[]};a.areas&&a.areas.length>0&&a.areas.forEach((e=>{o.areas.push({name:e.name,code:e.code})})),e.push(o)})),V.columns=e||[]})),s((()=>{c("sourseMapApi",(e=>{console.log(e.content.nowPoint,e.content.address),j.addressLongitudeLatitude=e.content.nowPoint,j.address=e.content.address}))})),()=>d(p,null,[d(i,null,null),d("div",{class:y.schoolEidtWrap},[d("div",{class:y.eidtWrap},[d(Z,{inset:!0},{default:()=>[d("div",{class:y.schoolDtailWrap,onClick:W},[d(v,{width:50,height:50,fit:"cover",class:y.schoolICon,src:j.logo?j.logo:h},null),d("div",{class:y.schoolBtnWrap},[d("p",null,[r("修改校徽")]),d(u,{name:"arrow",size:"12px",color:"#aaa"},null)])])]})]),d("div",{class:y.eidtWrap},[d(Z,{inset:!0},{default:()=>[d(L,{"label-align":"left",rows:3,modelValue:j.emergencyContact,"onUpdate:modelValue":e=>j.emergencyContact=e,maxlength:50,placeholder:"请输入姓名"},{label:()=>d("p",{class:y.addP},[r("主管领导")])}),d(L,{"label-align":"left",rows:3,modelValue:j.email,"onUpdate:modelValue":e=>j.email=e,maxlength:50,placeholder:"请输入邮箱账号"},{label:()=>d("p",{class:y.addP},[r("邮箱账号")])}),d(L,{"label-align":"top",maxlength:50,placeholder:"请选择学校地址",type:"textarea",disabled:!0,onClick:()=>(async()=>{try{b({api:"sourseMapApi",content:{type:"modify",orginPoint:j.addressLongitudeLatitude}},(e=>{console.log(e.content.nowPoint,e.content.address,"------"),j.addressLongitudeLatitude=e.content.nowPoint,j.address=e.content.address}))}catch(e){console.log(e)}})()},{extra:()=>d("div",{class:y.loctionIconWrap},null),label:()=>d("p",{class:[y.addP,y.addDet]},[r("学校地址 "),d(v,{width:19,height:18,src:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACYAAAAkCAYA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7/0bWWv0Psg2Atkb131gAXqn/1tKvIAhuJ6IDSRfhNtT0daRh7XneSRF5jpnPLgaltfZ1RKTRf4OmIRFZ1yhTRLYZYx6bSxfW2huI6BERubKN8DOuDTpNRGfiOD6TyWReFhF94OpNtc+6iIh6a7XaxZ7nrRSRla5jVb763ZSI6CURuZuZT9Z9Nb1LU4CIMBFppKxP/aVZjKJanhWRmIieFpH9mqTTqaVlER8bG1uZzWZvUoAisoaIrgKwdJEINdFqxD6vgGZnZ48Xi0W1wjz6D4HbHVCZGLHzAAAAAElFTkSuQmCC"},null)]),input:()=>d("div",{style:{paddingTop:"6px",paddingRight:"13px"}},[j.address])})]}),d(x,{class:y.upload,cropper:!0,bucket:"gyt",path:"/orchestra/",modelValue:j.logo,"onUpdate:modelValue":e=>j.logo=e,ref:C},null)]),d(R,{position:"bottom"},{default:()=>[d("div",{class:"btnGroup"},[d(g,{type:"primary",round:!0,block:!0,onClick:M},{default:()=>[r("确认修改")]})])]})])])}}))}}}));