3838 v-if =" canDownload.isPermitted"
3939 :disabled =" !canDownload.isPossible"
4040 :text =" __('statamic-backup::backup.download.label')"
41- :redirect =" download_url(backup.timestamp )"
41+ :redirect =" download_url(backup.id )"
4242 />
4343 <span v-if =" canRestore.isPermitted && canRestore.isPossible" >
4444 <hr class =" divider" />
4545 <dropdown-item
4646 :disabled =" !canRestore.isPossible"
4747 :text =" __('statamic-backup::backup.restore.label')"
48- @click =" initiateRestore(backup.timestamp , backup.name)"
48+ @click =" initiateRestore(backup.id , backup.name)"
4949 />
5050 </span >
5151 <span v-if =" canDestroy.isPermitted && canDestroy.isPossible" >
5252 <hr class =" divider" />
5353 <dropdown-item
5454 :text =" __('statamic-backup::backup.destroy.label')"
5555 dangerous =" true"
56- @click =" initiateDestroy(backup.timestamp , backup.name)"
56+ @click =" initiateDestroy(backup.id , backup.name)"
5757 />
5858 </span >
5959 </dropdown-list >
@@ -118,7 +118,7 @@ export default {
118118 columns: this .initialColumns ,
119119 confirmingRestore: false ,
120120 confirmingDestroy: false ,
121- activeTimestamp : null ,
121+ activeId : null ,
122122 activeName: null ,
123123 };
124124 },
@@ -140,22 +140,22 @@ export default {
140140 },
141141 },
142142 methods: {
143- download_url (timestamp ) {
144- return cp_url (" api/backups/download/" + timestamp );
143+ download_url (id ) {
144+ return cp_url (" api/backups/download/" + id );
145145 },
146- restore_url (timestamp ) {
147- return cp_url (" api/backups/restore/" + timestamp );
146+ restore_url (id ) {
147+ return cp_url (" api/backups/restore/" + id );
148148 },
149- destroy_url (timestamp ) {
150- return cp_url (" api/backups/" + timestamp );
149+ destroy_url (id ) {
150+ return cp_url (" api/backups/" + id );
151151 },
152- initiateDestroy (timestamp , name ) {
153- this .activeTimestamp = timestamp ;
152+ initiateDestroy (id , name ) {
153+ this .activeId = id ;
154154 this .activeName = name;
155155 this .confirmingDestroy = true ;
156156 },
157- initiateRestore (timestamp , name ) {
158- this .activeTimestamp = timestamp ;
157+ initiateRestore (id , name ) {
158+ this .activeId = id ;
159159 this .activeName = name;
160160 this .confirmingRestore = true ;
161161 },
@@ -166,7 +166,7 @@ export default {
166166
167167 this .$store .dispatch (' backup-provider/setStatus' , ' restore_in_progress' );
168168 this .$axios
169- .post (this .restore_url (this .activeTimestamp ))
169+ .post (this .restore_url (this .activeId ))
170170 .then (({ data }) => {
171171 this .$toast .info (__ (data .message ));
172172 this .$emit (" onRestored" );
@@ -181,15 +181,15 @@ export default {
181181 })
182182 .finally (() => {
183183 this .activeName = null ;
184- this .activeTimestamp = null ;
184+ this .activeId = null ;
185185 });
186186 },
187187 destroy () {
188188 if (! this .canDestroy .isPossible ) return console .warn (" Cannot destroy backups." );
189189
190190 this .confirmingDestroy = false ;
191191 this .$axios
192- .delete (this .destroy_url (this .activeTimestamp ))
192+ .delete (this .destroy_url (this .activeId ))
193193 .then (({ data }) => {
194194 this .$toast .success (__ (data .message ));
195195 this .$emit (" onDestroyed" );
@@ -204,7 +204,7 @@ export default {
204204 })
205205 .finally (() => {
206206 this .activeName = null ;
207- this .activeTimestamp = null ;
207+ this .activeId = null ;
208208 });
209209 },
210210 },
0 commit comments