ss-component-new 1.1.413 → 1.1.415
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{array-Dh0i46pi.js → array-CYOvmzeK.js} +2 -2
- package/dist/{array-CSwVpKuJ.cjs → array-DAoy3WS9.cjs} +1 -1
- package/dist/{index-ryZW4H12.cjs → index-3dpRV7yS.cjs} +1 -1
- package/dist/{index-b8cI-JMV.js → index-8nzu3dKT.js} +4 -4
- package/dist/{index-Bm-e95WZ.cjs → index-9QTlnrEQ.cjs} +1 -1
- package/dist/{index-DFLwJ3KT.js → index-9srnYnzT.js} +9 -9
- package/dist/{index-BE-LZbiq.js → index-AzrB9NlT.js} +4 -4
- package/dist/{index-KkjugPBD.js → index-B6_X9xq9.js} +4 -4
- package/dist/{index-Dgf9fuDm.cjs → index-BA-Qtevs.cjs} +1 -1
- package/dist/{index-DnhKk8wP.cjs → index-BHxsT1eb.cjs} +1 -1
- package/dist/{index-DALN1fcs.js → index-BJIMXITA.js} +5 -5
- package/dist/{index-CU9Do_8v.cjs → index-BJiXsb3E.cjs} +1 -1
- package/dist/{index-Dw0rc4QE.cjs → index-BJitBJZu.cjs} +1 -1
- package/dist/{index-RZC24UKn.js → index-BOzZXj2f.js} +7 -7
- package/dist/{index-BU03o3Ju.js → index-BPDslvev.js} +2 -2
- package/dist/{index-D7zpgFH2.js → index-BSAEf__V.js} +5 -5
- package/dist/{index-DxLAL2lm.cjs → index-BVuLbYm9.cjs} +1 -1
- package/dist/{index-Cx0UOXzP.js → index-Bhg9ISur.js} +6 -6
- package/dist/{index-BjaVXOv5.cjs → index-BibIA5-P.cjs} +1 -1
- package/dist/{index-Dp0b548D.cjs → index-BimZK7wy.cjs} +1 -1
- package/dist/{index-Bk37DuoM.cjs → index-BpPyaNFa.cjs} +1 -1
- package/dist/{index-CvB_YjeX.cjs → index-BszUQuvL.cjs} +1 -1
- package/dist/{index-Cr7aGVch.cjs → index-Bvr0YvSP.cjs} +1 -1
- package/dist/{index-BVPTyDGN.js → index-BxHhG5PY.js} +3 -3
- package/dist/{index-Cwveu5wW.cjs → index-C8jmJvXd.cjs} +2 -2
- package/dist/{index-bj7mOAVK.js → index-CA9lI4P8.js} +4 -4
- package/dist/index-CNQtTLfb.cjs +1 -0
- package/dist/{index-_wV6-Llj.cjs → index-CTTEAggF.cjs} +1 -1
- package/dist/{index-vX-r2aen.cjs → index-CdLmmvxi.cjs} +1 -1
- package/dist/{index-BbZUyAdu.cjs → index-CffNkMWN.cjs} +1 -1
- package/dist/{index-BjDV7Cz7.cjs → index-CilqH8oC.cjs} +1 -1
- package/dist/{index-BrdbMKvd.cjs → index-CyOcoFxe.cjs} +1 -1
- package/dist/{index-AYpwatFI.cjs → index-D68A4TXc.cjs} +1 -1
- package/dist/{index-JaxYzGiv.cjs → index-DBB_scdx.cjs} +1 -1
- package/dist/{index-C4OhyEpp.cjs → index-DHhMROzm.cjs} +1 -1
- package/dist/{index-BStNLZ42.js → index-DIv5glVC.js} +15 -15
- package/dist/{index-BCL3B2W3.js → index-DMp2zGXo.js} +7 -7
- package/dist/{index-BTw--p5k.js → index-DPm-3I4S.js} +6 -6
- package/dist/{index-24rHtXOF.js → index-DbuzlHfh.js} +9 -9
- package/dist/{index-CAPbOxeI.cjs → index-DjhZHYH_.cjs} +1 -1
- package/dist/{index-Dle4rTtv.js → index-Dm1_86kX.js} +3 -3
- package/dist/{index-Cz-SX3Vr.cjs → index-Dnq8JVuW.cjs} +1 -1
- package/dist/{index-BDBTYDAm.js → index-DoIHM98M.js} +1 -1
- package/dist/{index-BxnGHDCM.js → index-DrCpGMdZ.js} +3 -3
- package/dist/{index-BBceT0Au.js → index-DrUjNhjW.js} +1 -1
- package/dist/{index-DEowpIN-.js → index-DuwxEG2Y.js} +1 -1
- package/dist/{index-BPynUUkE.cjs → index-Dxfzna5p.cjs} +1 -1
- package/dist/{index-Mzgmsk8P.js → index-FBp-XX6h.js} +1 -1
- package/dist/{index-CY1519pX.js → index-TEDdJfFz.js} +7 -7
- package/dist/{index-B5T7_Hfv.js → index-UYsrvpRs.js} +380 -413
- package/dist/{index-C_Jun3tv.js → index-VOSN3Mnh.js} +5 -5
- package/dist/{index-B2Fq07yi.cjs → index-WPbX9sqP.cjs} +1 -1
- package/dist/{index-mnA3swxC.cjs → index-ZUmqWSaw.cjs} +1 -1
- package/dist/{index-BGGv8YCW.js → index-eSv5uzFM.js} +4 -4
- package/dist/{index-DCXRZxtU.js → index-faxMOO3y.js} +5 -5
- package/dist/{index.vue_vue_type_script_setup_true_lang-d9_SaET-.js → index.vue_vue_type_script_setup_true_lang-CKDefrVd.js} +3 -3
- package/dist/{index.vue_vue_type_script_setup_true_lang-OrELjG9X.cjs → index.vue_vue_type_script_setup_true_lang-Dr6igsfU.cjs} +1 -1
- package/dist/index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CaGB6aRQ.js +9119 -0
- package/dist/index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-x_oCFRtr.cjs +47 -0
- package/dist/{index.vue_vue_type_style_index_0_scoped_306ecd73_lang-C1K4Ki_m.cjs → index.vue_vue_type_style_index_0_scoped_306ecd73_lang-B7CgbfdF.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_306ecd73_lang-DysCq2pc.js → index.vue_vue_type_style_index_0_scoped_306ecd73_lang-CMsb25AU.js} +8 -8
- package/dist/{index.vue_vue_type_style_index_0_scoped_7ee96c6e_lang-CI2nWr0Z.cjs → index.vue_vue_type_style_index_0_scoped_7ee96c6e_lang-COxDD0Fj.cjs} +1 -1
- package/dist/{index.vue_vue_type_style_index_0_scoped_7ee96c6e_lang-CtkN_3NU.js → index.vue_vue_type_style_index_0_scoped_7ee96c6e_lang-DDi07ZiD.js} +15 -15
- package/dist/{login-jvP43w57.js → login-CARNmuDg.js} +1 -1
- package/dist/{login-CwoRR3Nc.cjs → login-DsWsywlE.cjs} +1 -1
- package/dist/{main-B4JZ9T9G.js → main-C7zpT64X.js} +6 -6
- package/dist/{main-DI3zYE5l.cjs → main-NoOanZcQ.cjs} +1 -1
- package/dist/{menu-Bj4qq0KK.cjs → menu-B-Z5KAh5.cjs} +1 -1
- package/dist/{menu-pNM6_DJi.js → menu-D9x5_s9p.js} +1 -1
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +1 -1
- package/dist/ss-component.js +10 -10
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component3.cjs +1 -1
- package/dist/ss-component3.js +1 -1
- package/dist/{threeModel-B2v_doHa.js → threeModel-BazaxATJ.js} +1 -1
- package/dist/{threeModel-Bx3XHoSZ.cjs → threeModel-MVkoDB-c.cjs} +1 -1
- package/dist/{threeModel.vue_vue_type_style_index_0_scoped_28fc9fe5_lang-BtFDMscB.cjs → threeModel.vue_vue_type_style_index_0_scoped_28fc9fe5_lang-CBBWsMHp.cjs} +1 -1
- package/dist/{threeModel.vue_vue_type_style_index_0_scoped_28fc9fe5_lang-BeUjxBt-.js → threeModel.vue_vue_type_style_index_0_scoped_28fc9fe5_lang-CnQhvwfL.js} +2 -2
- package/package.json +1 -1
- package/dist/index-b6dDRbJK.cjs +0 -1
- package/dist/index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-0DUFsOev.cjs +0 -244
- package/dist/index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-BP5MoIJH.js +0 -51941
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { defineComponent as e, reactive as a, onMounted as o, createElementBlock as r, openBlock as n, createVNode as m } from "vue";
|
|
2
2
|
import "./index-BHtNKL1L.js";
|
|
3
|
-
import "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-
|
|
4
|
-
import "./menu-
|
|
5
|
-
import { v as i } from "./index-
|
|
6
|
-
import { S as c } from "./index-
|
|
7
|
-
import { g as p } from "./index-
|
|
3
|
+
import "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CaGB6aRQ.js";
|
|
4
|
+
import "./menu-D9x5_s9p.js";
|
|
5
|
+
import { v as i } from "./index-faxMOO3y.js";
|
|
6
|
+
import { S as c } from "./index-DrCpGMdZ.js";
|
|
7
|
+
import { g as p } from "./index-B6_X9xq9.js";
|
|
8
8
|
const D = /* @__PURE__ */ e({
|
|
9
9
|
__name: "index",
|
|
10
10
|
setup(s) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const n=require("vue"),c=require("./menu-
|
|
1
|
+
"use strict";const n=require("vue"),c=require("./menu-B-Z5KAh5.cjs"),u=require("./index-BHxsT1eb.cjs"),g=require("./threeModel.vue_vue_type_style_index_0_scoped_28fc9fe5_lang-CBBWsMHp.cjs"),D=g.useModelComp(),{itemData:f}=c.storeToRefs(D),p=n.ref(0),m=n.ref([{label:"机构名称",value:"",name:"deptName"}]),i=e=>{console.log("handleQueryChange",e)},r=n.ref([{key:"extraButton",contents:[{label:"新增"}]},{key:"rowButton",contents:[{label:"编辑"},{label:"删除"}]},{key:"header",contents:[{label:"职位名称",prop:"postName"},{label:"职位排序",formType:"Number",prop:"postOrder"},{label:"备注",formType:"TextArea",prop:"remark"},{label:"操作"}]},{key:"tableContents",contents:[]}]),_=e=>{u.submitTableAsyncByVerify(e.singleContent,e.buttonName,p.value)},h=e=>{console.log("onDoubleClick",e)},k=(e,a)=>{console.log("onButtonClick",e,a)},C=async e=>{const a=await u.handleSubmitAsync(c.getInsofDataApi,{key:{type:"data",systemKey:sessionStorage.getItem("systemKey"),pageKey:e}},"查询"),l=a==null?void 0:a.map(t=>{var o;return{id:t.id,tableData:(o=t==null?void 0:t.value)==null?void 0:o.tableData}});return l==null?void 0:l.map(t=>{var o;if(Array.isArray(t==null?void 0:t.tableData)){let s={id:t.id};return(o=t==null?void 0:t.tableData)==null||o.forEach((b,d)=>{s[`a${d}`]=b}),s}else return{...t.tableData,id:t.id}})},y={comp:"Group",name:"/系统管理/职位管理",compData:[{key:"groupContents",contents:[{comp:"Table",compData:r.value,name:""}]}]};n.watch(()=>f.value,e=>{var a;e&&(e==null?void 0:e.length)>0&&(r.value=(a=e==null?void 0:e[0])==null?void 0:a.compData)});const A=Object.freeze(Object.defineProperty({__proto__:null,getPageDataAsync:C,handleItemDataChange:_,handleQueryChange:i,onButtonClick:k,onDoubleClick:h,pageData:r,queryFormData:m,structureId:p,tempPostPageData:y},Symbol.toStringTag,{value:"Module"}));exports.State=A;exports.tempPostPageData=y;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue");require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue");require("./index-BpPyaNFa.cjs");require("./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-x_oCFRtr.cjs");const n=require("./menu-B-Z5KAh5.cjs"),c=require("./index-BA-Qtevs.cjs"),r=require("./index-BHxsT1eb.cjs"),u=require("./login-DsWsywlE.cjs"),i=require("./index-DBB_scdx.cjs"),s=e.defineComponent({__name:"index",setup(l){const o=n.useMenuState(),{activeMenuPath:d}=n.storeToRefs(o),a=u.useLoginState(),t=e.reactive({...r.State});return e.onMounted(async()=>{a.getModelSecretAsync(),t.structureId=await i.getActivePageStructureId()}),(g,m)=>(e.openBlock(),e.createElementBlock("div",null,[e.createVNode(c.ssTable,{itemData:t.pageData,changedContent:t.changedRow,onChange:t.handleItemDataChange,onOnButtonClick:t.clickRowButton},null,8,["itemData","changedContent","onChange","onOnButtonClick"])]))}});exports.default=s;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { computed as b, getCurrentInstance as qe, inject as pe, unref as u, ref as A, onMounted as ie, watch as W, toRef as Ke, onUnmounted as Vn, shallowRef as Ve, nextTick as V, defineComponent as Z, useAttrs as _n, useSlots as un, createElementBlock as F, openBlock as E, normalizeStyle as Ye, normalizeClass as w, createCommentVNode as k, Fragment as _e, createElementVNode as P, renderSlot as Y, createBlock as M, withCtx as L, resolveDynamicComponent as K, mergeProps as lt, withModifiers as ke, createVNode as oe, toDisplayString as J, onBeforeUnmount as xe, provide as cn, Text as Dn, reactive as dn, h as Un, watchEffect as Kn, isRef as Yn, onScopeDispose as Wn, markRaw as ut, toRefs as Gn, resolveComponent as Ce, Transition as qn, withDirectives as et, withKeys as Re, createTextVNode as tt, vShow as nt, isVNode as fn, render as vn } from "vue";
|
|
2
|
-
import { S as Ft, m as pn, n as gt, t as hn, o as Pt, p as Xn, i as se, q as Ht, v as Xe, c as fe, w as ue, x as We, y as mn, z as ve, A as jn, B as Jn, C as Zn, D as Qn, F as Te, G as Ie, H as Me, _ as Be, I as he, V as eo, J as to, K as no, L as oo, M as ae, N as De, O as ao, e as Ge, P as gn, Q as bt, R as ro, T as ct, U as so, W as $t, X as io, Y as zt, d as lo, g as uo, b as co, Z as fo, $ as vo, a as po, a0 as Vt, a1 as _t, a2 as ho } from "./index-
|
|
3
|
-
import { m as mo } from "./menu-
|
|
4
|
-
import { e as Dt, i as bn, h as go, j as bo, k as yn, l as yo } from "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-
|
|
5
|
-
import { i as En } from "./index.vue_vue_type_script_setup_true_lang-
|
|
2
|
+
import { S as Ft, m as pn, n as gt, t as hn, o as Pt, p as Xn, i as se, q as Ht, v as Xe, c as fe, w as ue, x as We, y as mn, z as ve, A as jn, B as Jn, C as Zn, D as Qn, F as Te, G as Ie, H as Me, _ as Be, I as he, V as eo, J as to, K as no, L as oo, M as ae, N as De, O as ao, e as Ge, P as gn, Q as bt, R as ro, T as ct, U as so, W as $t, X as io, Y as zt, d as lo, g as uo, b as co, Z as fo, $ as vo, a as po, a0 as Vt, a1 as _t, a2 as ho } from "./index-DbuzlHfh.js";
|
|
3
|
+
import { m as mo } from "./menu-D9x5_s9p.js";
|
|
4
|
+
import { e as Dt, i as bn, h as go, j as bo, k as yn, l as yo } from "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CaGB6aRQ.js";
|
|
5
|
+
import { i as En } from "./index.vue_vue_type_script_setup_true_lang-CKDefrVd.js";
|
|
6
6
|
function Eo(e) {
|
|
7
7
|
return e;
|
|
8
8
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { ref as U, watch as Ne, nextTick as il, resolveComponent as ia, createBlock as sa, openBlock as pe, withCtx as ie, createElementVNode as ce, renderSlot as Ea, onMounted as ta, createElementBlock as ke, normalizeClass as sl, toDisplayString as Pe, createCommentVNode as Wa, Fragment as Qa, renderList as Xa, normalizeStyle as Ya, createVNode as ue, unref as tl, defineComponent as ol, createSlots as ul, createTextVNode as Ue } from "vue";
|
|
2
|
-
import { f as oa, g as I, d as Be, h as fl, i as We, c as na, s as Ve, u as Za, p as Le, e as cl } from "./menu-
|
|
3
|
-
import { u as yl } from "./threeModel.vue_vue_type_style_index_0_scoped_28fc9fe5_lang-
|
|
4
|
-
import { a3 as pl, S as Pa, a4 as dl, m as Fa, a5 as Na, a6 as gl } from "./index-
|
|
5
|
-
import { b as Qe, f as hl, s as Ba } from "./index-
|
|
6
|
-
import { U as Ra, n as ja, o as $a, p as xa, S as ea, q as bl, g as Xe, c as g, r as Ma, t as ml, u as Al, v as vl, w as kl } from "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-
|
|
2
|
+
import { f as oa, g as I, d as Be, h as fl, i as We, c as na, s as Ve, u as Za, p as Le, e as cl } from "./menu-D9x5_s9p.js";
|
|
3
|
+
import { u as yl } from "./threeModel.vue_vue_type_style_index_0_scoped_28fc9fe5_lang-CnQhvwfL.js";
|
|
4
|
+
import { a3 as pl, S as Pa, a4 as dl, m as Fa, a5 as Na, a6 as gl } from "./index-DbuzlHfh.js";
|
|
5
|
+
import { b as Qe, f as hl, s as Ba } from "./index-UYsrvpRs.js";
|
|
6
|
+
import { U as Ra, n as ja, o as $a, p as xa, S as ea, q as bl, g as Xe, c as g, r as Ma, t as ml, u as Al, v as vl, w as kl } from "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CaGB6aRQ.js";
|
|
7
7
|
import { _ as ua } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
8
8
|
var Tl = "__lodash_hash_undefined__";
|
|
9
9
|
function Dl(a) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineComponent as R, ref as b, reactive as A, resolveComponent as g, createElementBlock as k, openBlock as B, createVNode as u, withCtx as d, createElementVNode as l, createTextVNode as w, toDisplayString as N, nextTick as T, Fragment as q, withDirectives as $, renderSlot as z, vShow as H } from "vue";
|
|
2
|
-
import { C as V } from "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-
|
|
3
|
-
import { X as M, af as X, v as x, w as c, N as m } from "./index-
|
|
4
|
-
import { m as S } from "./menu-
|
|
2
|
+
import { C as V } from "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CaGB6aRQ.js";
|
|
3
|
+
import { X as M, af as X, v as x, w as c, N as m } from "./index-DbuzlHfh.js";
|
|
4
|
+
import { m as S } from "./menu-D9x5_s9p.js";
|
|
5
5
|
import { _ as J } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
6
6
|
function G(t) {
|
|
7
7
|
return t == null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),S=require("./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-
|
|
1
|
+
"use strict";const e=require("vue"),S=require("./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-x_oCFRtr.cjs"),a=require("./index-BJitBJZu.cjs"),_=require("./menu-B-Z5KAh5.cjs"),I=require("./_plugin-vue_export-helper-BHFhmbuH.cjs");function w(r){return r==null}const O="ElUpload";class k extends Error{constructor(o,n,i,p){super(o),this.name="UploadAjaxError",this.status=n,this.method=i,this.url=p}}function v(r,o,n){let i;return n.response?i=`${n.response.error||n.response}`:n.responseText?i=`${n.responseText}`:i=`fail to ${o.method} ${r} ${n.status}`,new k(i,n.status,o.method,r)}function B(r){const o=r.responseText||r.response;if(!o)return o;try{return JSON.parse(o)}catch{return o}}const R=r=>{typeof XMLHttpRequest>"u"&&a.throwError(O,"XMLHttpRequest is undefined");const o=new XMLHttpRequest,n=r.action;o.upload&&o.upload.addEventListener("progress",t=>{const c=t;c.percent=t.total>0?t.loaded/t.total*100:0,r.onProgress(c)});const i=new FormData;if(r.data)for(const[t,c]of Object.entries(r.data))a.isArray$1(c)&&c.length?i.append(t,...c):i.append(t,c);i.append(r.filename,r.file,r.file.name),o.addEventListener("error",()=>{r.onError(v(n,r,o))}),o.addEventListener("load",()=>{if(o.status<200||o.status>=300)return r.onError(v(n,r,o));r.onSuccess(B(o))}),o.open(r.method,n,!0),r.withCredentials&&"withCredentials"in o&&(o.withCredentials=!0);const p=r.headers||{};if(p instanceof Headers)p.forEach((t,c)=>o.setRequestHeader(c,t));else for(const[t,c]of Object.entries(p))w(c)||o.setRequestHeader(t,String(c));return o.send(i),o},T=["text","picture","picture-card"];let U=1;const D=()=>Date.now()+U++,L=a.buildProps({action:{type:String,default:"#"},headers:{type:a.definePropType(Object)},method:{type:String,default:"post"},data:{type:a.definePropType([Object,Function,Promise]),default:()=>_.mutable({})},multiple:Boolean,name:{type:String,default:"file"},drag:Boolean,withCredentials:Boolean,showFileList:{type:Boolean,default:!0},accept:{type:String,default:""},fileList:{type:a.definePropType(Array),default:()=>_.mutable([])},autoUpload:{type:Boolean,default:!0},listType:{type:String,values:T,default:"text"},httpRequest:{type:a.definePropType(Function),default:R},disabled:Boolean,limit:Number});a.buildProps({...L,beforeUpload:{type:a.definePropType(Function),default:a.NOOP},beforeRemove:{type:a.definePropType(Function)},onRemove:{type:a.definePropType(Function),default:a.NOOP},onChange:{type:a.definePropType(Function),default:a.NOOP},onPreview:{type:a.definePropType(Function),default:a.NOOP},onSuccess:{type:a.definePropType(Function),default:a.NOOP},onProgress:{type:a.definePropType(Function),default:a.NOOP},onError:{type:a.definePropType(Function),default:a.NOOP},onExceed:{type:a.definePropType(Function),default:a.NOOP},crossorigin:{type:a.definePropType(String)}});const F={style:{"text-align":"left"}},q={class:"cropper-warp"},j={class:"cropper-warp-left"},A=["src"],$={class:"cropper-warp-right"},H={class:"cropper-warp-right-item"},z={class:"cropper-warp-right-value"},M=["src"],X={class:"cropper-warp-right-item"},J={class:"cropper-warp-right-value"},G=["src"],K={class:"dialog-footer"},Q=e.defineComponent({__name:"index",props:{title:{type:String,default:""}},emits:["submitImage","deleteImage"],setup(r,{expose:o,emit:n}){const i=n,p=e.ref(),t=e.reactive({isShowDialog:!1,cropperImg:"",cropperImgBase64:"",cropper:null}),c=async l=>{if(!l)return;let s=window.URL||window.webkitURL;t.cropperImg=s.createObjectURL(l),t.isShowDialog=!0,e.nextTick(()=>{g()})},u=()=>{var l;(l=t.cropper)==null||l.destroy(),t.isShowDialog=!1},f=()=>{u()},d=async()=>{const l=await h();i("submitImage",{file:l}),u()},y=async()=>{i("deleteImage")},g=()=>{const l=document.querySelector(".cropper-warp-left-img");l&&l.setAttribute("crossOrigin","anonymous"),t.cropper=new S.Cropper(l,{viewMode:1,dragMode:"none",initialAspectRatio:1,aspectRatio:1,preview:".before",background:!0,autoCropArea:1,checkCrossOrigin:!1,crop:()=>{t.cropperImgBase64=t.cropper.getCroppedCanvas().toDataURL("image/jpeg")}})},h=()=>new Promise(l=>{t.cropper.getCroppedCanvas().toBlob(s=>{l(s)})}),C=async l=>{let s=window.URL||window.webkitURL;t.cropperImg=s.createObjectURL(l.raw),t.cropper.replace(t.cropperImg)},N=l=>{p.value.clearFiles();const s=l[0];s.uid=D(),p.value.handleStart(s)};return o({openDialog:c}),(l,s)=>{const E=e.resolveComponent("ele-Edit"),x=e.resolveComponent("el-icon"),m=e.resolveComponent("el-button"),b=e.resolveComponent("el-upload"),P=e.resolveComponent("el-dialog");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(P,{modelValue:t.isShowDialog,"onUpdate:modelValue":s[0]||(s[0]=V=>t.isShowDialog=V),width:"769px","before-close":f},{header:e.withCtx(()=>[e.createElementVNode("div",F,[e.createVNode(x,{size:"16",style:{"margin-right":"3px",display:"inline","vertical-align":"middle"}},{default:e.withCtx(()=>[e.createVNode(E)]),_:1}),e.createElementVNode("span",null,e.toDisplayString(r.title),1)])]),footer:e.withCtx(()=>[e.createElementVNode("span",K,[e.createVNode(b,{class:"avatar-uploader",ref_key:"uploadSignRef",ref:p,accept:".jpg,.png",limit:1,"show-file-list":!1,"auto-upload":!1,"on-change":C,"on-exceed":N},{trigger:e.withCtx(()=>[e.createVNode(m,{type:"info",icon:"ele-Picture"},{default:e.withCtx(()=>s[4]||(s[4]=[e.createTextVNode("选择图片")])),_:1,__:[4]})]),default:e.withCtx(()=>[e.createVNode(m,{onClick:y,type:"danger",icon:"ele-Picture",style:{"margin-left":"8px"}},{default:e.withCtx(()=>s[5]||(s[5]=[e.createTextVNode("删除图片")])),_:1,__:[5]})]),_:1},512),e.createElementVNode("div",null,[e.createVNode(m,{onClick:f,id:"themeBorderButton"},{default:e.withCtx(()=>s[6]||(s[6]=[e.createTextVNode("取 消")])),_:1,__:[6]}),e.createVNode(m,{onClick:d,id:"themeButton"},{default:e.withCtx(()=>s[7]||(s[7]=[e.createTextVNode("确 定")])),_:1,__:[7]})])])]),default:e.withCtx(()=>[e.createElementVNode("div",q,[e.createElementVNode("div",j,[e.createElementVNode("img",{src:t.cropperImg,class:"cropper-warp-left-img"},null,8,A)]),e.createElementVNode("div",$,[s[3]||(s[3]=e.createElementVNode("div",{class:"cropper-warp-right-title"},"预览",-1)),e.createElementVNode("div",H,[e.createElementVNode("div",z,[e.createElementVNode("img",{src:t.cropperImgBase64,class:"cropper-warp-right-value-img"},null,8,M)]),s[1]||(s[1]=e.createElementVNode("div",{class:"cropper-warp-right-label"},"100 x 100",-1))]),e.createElementVNode("div",X,[e.createElementVNode("div",J,[e.createElementVNode("img",{src:t.cropperImgBase64,class:"cropper-warp-right-value-img cropper-size"},null,8,G)]),s[2]||(s[2]=e.createElementVNode("div",{class:"cropper-warp-right-label"},"50 x 50",-1))])])])]),_:1},8,["modelValue"])])}}}),W=I._export_sfc(Q,[["__scopeId","data-v-5d760968"]]),Y=e.defineComponent({__name:"index",props:{avatarUrl:{type:String,default:""},avatarBlob:{type:Blob,default:""},size:{type:String,default:"large"},showCropper:{type:Boolean,default:!0},banClick:{type:Boolean,default:!1}},emits:["submitImage","deleteImage","clickAvatar"],setup(r,{emit:o}){const n=r,i=e.ref(),p=e.ref(null),t=o,c=async()=>{var d;n!=null&&n.banClick||(t("clickAvatar",n.avatarUrl),(d=i.value)==null||d.openDialog(n.avatarBlob))},u=async d=>{t("submitImage",d)},f=async()=>{t("deleteImage")};return(d,y)=>{const g=e.resolveComponent("el-avatar");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(g,{src:r.avatarUrl,onClick:c,fit:"cover",size:n==null?void 0:n.size,ref_key:"avatarRef",ref:p},{default:e.withCtx(()=>[e.renderSlot(d.$slots,"avatarDefault")]),_:3},8,["src","size"]),e.withDirectives(e.createVNode(W,{ref_key:"cropperDialogRef",ref:i,title:"更改头像",avatarUrl:r.avatarUrl,onSubmitImage:u,onDeleteImage:f},null,8,["avatarUrl"]),[[e.vShow,r.showCropper]])],64)}}});exports._sfc_main=Y;exports.isNil=w;
|