Reset Media route resolv using uid (besoin métier) vu avec Vincent
This commit is contained in:
parent
3dce58d9a0
commit
ad00dd2246
5 changed files with 16 additions and 6 deletions
|
|
@ -274,6 +274,16 @@ class Media extends Model
|
|||
|
||||
// * Laravel Behaviors
|
||||
|
||||
/**
|
||||
* Get the route key for the model.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getRouteKeyName()
|
||||
{
|
||||
return 'uid';
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the base cache tags that will be present
|
||||
* on all queries.
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@
|
|||
</button>
|
||||
<button
|
||||
class="float-right mr-10 copyclipboard"
|
||||
v-clipboard="'https://dam.lesidc.com/media/' + this.storeMedia.id"
|
||||
v-clipboard="'https://dam.lesidc.com/media/' + this.storeMedia.uid"
|
||||
title="Copier le lien"
|
||||
>
|
||||
<font-awesome-icon icon="link" />
|
||||
|
|
@ -292,7 +292,7 @@ export default {
|
|||
},
|
||||
SaveMedia() {
|
||||
axios
|
||||
.put(`/ajax/media/${this.storeMedia.id}`, {
|
||||
.put(`/ajax/media/${this.storeMedia.uid}`, {
|
||||
media: this.storeMedia,
|
||||
})
|
||||
.then((response) => {
|
||||
|
|
|
|||
|
|
@ -529,7 +529,7 @@ export default {
|
|||
},
|
||||
SetIdArcadia() {
|
||||
axios
|
||||
.post(`/ajax/media/${this.oMedia.id}/set-id-arcadia`)
|
||||
.post(`/ajax/media/${this.oMedia.uid}/set-id-arcadia`)
|
||||
.then((response) => {
|
||||
if (response.data === true) {
|
||||
this.oMedia.isLocked = true;
|
||||
|
|
@ -575,7 +575,7 @@ export default {
|
|||
SaveMedia() {
|
||||
const self = this;
|
||||
axios
|
||||
.put(`/ajax/media/${self.oMedia.id}`, self.oMedia)
|
||||
.put(`/ajax/media/${self.oMedia.uid}`, self.oMedia)
|
||||
.then((response) => {
|
||||
self.$loading.hide();
|
||||
if (response.data.status === true) {
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ export default {
|
|||
) {
|
||||
const _this2 = this;
|
||||
axios
|
||||
.post(`/ajax/media/${this.storeMedia.id}/get-media-others-infos`)
|
||||
.post(`/ajax/media/${this.storeMedia.uid}/get-media-others-infos`)
|
||||
.then((response) => {
|
||||
_this2.history = response.data.history;
|
||||
})
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ export default {
|
|||
) {
|
||||
const _this2 = this;
|
||||
axios
|
||||
.post(`/ajax/media/${this.storeMedia.id}/get-media-others-infos`)
|
||||
.post(`/ajax/media/${this.storeMedia.uid}/get-media-others-infos`)
|
||||
.then((response) => {
|
||||
_this2.links = response.data.vignettes;
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue