"use strict";(globalThis["webpackChunkaurora_corporate_mobile_ui"]||=[]).push([[1212],{61212(o,l,e){e.r(l),e.d(l,{default:()=>y});var t=e(61758),n=e(58790);const i={class:"q-mx-lg q-mt-lg q-mb-md"},a={key:0},s={class:"q-mb-md dialog__title-text"},d={key:1,class:"dialog__title-text"};function c(o,l,e,c,r,h){const p=(0,t.g2)("button-dialog"),u=(0,t.g2)("app-dialog");return(0,t.uX)(),(0,t.Wv)(u,{modelValue:o.confirm,"onUpdate:modelValue":l[0]||(l[0]=l=>o.confirm=l),close:h.cancel,"align-actions":"between"},{content:(0,t.k6)(()=>[(0,t.Lk)("div",i,[o.downloadFiles.length>1?((0,t.uX)(),(0,t.CE)("div",a,[(0,t.Lk)("div",s,(0,n.v_)(`Encrypt ${o.downloadFiles.length} files?`),1),((0,t.uX)(!0),(0,t.CE)(t.FK,null,(0,t.pI)(o.downloadFiles,o=>((0,t.uX)(),(0,t.CE)("div",{key:o.hash,class:"text__caption q-mb-sm"},[(0,t.Lk)("span",null,(0,n.v_)(o.name),1)]))),128))])):(0,t.Q3)("",!0),1===o.downloadFiles.length?((0,t.uX)(),(0,t.CE)("div",d,(0,n.v_)(`Encrypt "${o.downloadFiles[0].name}"?`),1)):(0,t.Q3)("",!0)])]),actions:(0,t.k6)(()=>[(0,t.bF)(p,{class:"q-ma-sm",action:h.upload,label:o.$t("COREPARANOIDENCRYPTIONWEBCLIENTPLUGIN.ACTION_DONT_ENCRYPT")},null,8,["action","label"]),(0,t.bF)(p,{class:"q-ma-sm",action:h.uploadAndEncrypt,label:o.$t("COREPARANOIDENCRYPTIONWEBCLIENTPLUGIN.ACTION_ENCRYPT")},null,8,["action","label"])]),_:1},8,["modelValue","close"])}var r=e(35625),h=e(9090),p=e(15679),u=e(9950);const m={name:"FileUploadTypeSelectionDialog",components:{AppDialog:r.A,ButtonDialog:h.A},computed:{...(0,p.L8)(u._i,["downloadFiles"])},watch:{confirm(o){o||this.continueDownload||this.cancel()}},data:()=>({confirm:!1,noEncryptMethods:null,encryptMethod:null,continueDownload:!1,files:[]}),methods:{...(0,p.i0)(u._i,["removeSelectedUploadedFiles"]),openDialog(o,l,e){this.confirm=!0,this.noEncryptMethods=l,this.encryptMethod=o,this.files=e,this.continueDownload=!1},uploadAndEncrypt(){this.encryptMethod(),this.continueDownload=!0,this.confirm=!1},upload(){this.$root.nextUploadFiles({factory:this.noEncryptMethods.factory,added:null,uploaded:()=>{},finish:this.noEncryptMethods.finish}),this.confirm=!1},async cancel(){this.confirm=!1,this.removeSelectedUploadedFiles(this.files)}}};var E=e(12807);const f=(0,E.A)(m,[["render",c]]),y=f}}]);