File tree Expand file tree Collapse file tree 4 files changed +37
-4
lines changed
Expand file tree Collapse file tree 4 files changed +37
-4
lines changed Original file line number Diff line number Diff line change 3737 .d-popup span .close : active {
3838 background-position : 0 -33px ;
3939 }
40-
4140.d-popup-title {
4241 font-size : 11px ;
4342 text-transform : uppercase;
4443 text-align : center;
45- color : # fffdd4 ;
46- margin : 0 0 9px ;
44+ color : # fffaba ;
45+ margin : 5px 0 16px ;
46+ letter-spacing : 2px ;
4747}
4848.d-popup-items {
4949 font-size : 12px ;
6464}
6565.d-popup .prop-value {
6666 color : # fff ;
67+ margin-bottom : 5px ;
6768}
69+ .d-popup-content {
70+ color : # fff ;
71+ font-size : 13px ;
72+ line-height : 24px ;
73+ }
74+ .d-popup-content li {
75+ margin-bottom : 5px ;
76+ color : # fff ;
77+ font-size : 12px ;
78+ }
79+ .d-popup-content li strong {
80+ color : # BDB9AE ;
81+ text-transfom : uppercese;
82+ font-weight : normal;
83+ font-size : 10px ;
84+ margin-right : 7px ;
85+ }
Original file line number Diff line number Diff line change @@ -498,6 +498,10 @@ App.HTML.Build.backup_list = function(backups)
498498 tpl . set ( ':OWNER' , App . Env . initialParams . auth_user . uid . uid ) ;
499499 tpl . set ( ':CREATED_AT_WDAY' , App . Constants . KEY . WDAYS [ created_date . getDay ( ) ] ) ;
500500 tpl . set ( ':SIZE' , App . Helpers . getMbHuman ( bckp . SIZE ) + ' ' + App . Helpers . getMbHuman ( bckp . SIZE , true ) ) ;
501+ // tpl.set(':DOWNLOAD_LINK', '/backup/' + App.Env.initialParams.auth_user.uid.uid + '.' + key + '.tar');
502+ tpl . set ( ':DOWNLOAD_LINK' , '/dispatch.php?jedi_method=MAIN.downloadBackup&key=' + key ) ;
503+
504+
501505 acc [ acc . length ++ ] = tpl . finalize ( )
502506 } ) ;
503507
Original file line number Diff line number Diff line change @@ -1076,7 +1076,7 @@ App.Templates.html = {
10761076 <span class="backup-size">\
10771077 <span class="backup-size-inner">~!:SIZE~!</span>\
10781078 </span>\
1079- <a class="backup-url" href="return alert(\'Not available at the time\'); ">download</a>\
1079+ <a class="backup-url" href="~!:DOWNLOAD_LINK~! ">download</a>\
10801080 </div>\
10811081 <div class="props-ext">\
10821082 <!-- div class="backup-actions">\
Original file line number Diff line number Diff line change @@ -144,6 +144,17 @@ public function getBackupsExecute(Request $request)
144144 return $ this ->reply ($ rs ['status ' ], @$ rs ['data ' ]);
145145 }
146146
147+ public function downloadBackupExecute (Request $ request )
148+ {
149+ $ user = VestaSession::getInstance ()->getUser ();
150+
151+ header ('Content-type: application/x-tar ' );
152+ header ('Content-Disposition: attachment; filename=" ' .$ user ['uid ' ].'. ' .$ _REQUEST ['key ' ].'.tar" ' );
153+ header ('X-Accel-Redirect: /backup/ ' .$ user ['uid ' ].'. ' .$ _REQUEST ['key ' ].'.tar ' );
154+
155+ exit ;
156+ }
157+
147158 /**
148159 * Get Initial params.
149160 * Global constants / variables / configs
You can’t perform that action at this time.
0 commit comments