Skip to content

Commit 8395121

Browse files
authored
Merge pull request #65 from webreinvent/2.x-hotfix/v2.0.1
2.x hotfix -> 2.x | v2.0.1
2 parents 0345345 + ab948a6 commit 8395121

File tree

8 files changed

+23
-7
lines changed

8 files changed

+23
-7
lines changed

Libraries/CmsSeeder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ public static function createSampleField($theme_slug, $file_path, $content_type_
265265
return false;
266266
}
267267

268-
$content_type = ContentTypeBase::where('slug', $content_type_slug)
268+
$content_type = ContentType::where('slug', $content_type_slug)
269269
->with(['groups.fields.type'])
270270
->first()->toArray();
271271

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Cms Module for VaahCMS
77

88
#### For Hot Reload add following:
99
```dotenv
10-
APP_MODULE_CMS_ENV=develop
10+
MODULE_CMS_ENV=develop
1111
```
1212

1313
#### Frontend Routes

Resources/assets/build/index.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Resources/views/backend/pages/app.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
@if(env('MODULE_CMS_ENV') == 'develop')
1616
<script type="module" src="http://localhost:8367/main.js"></script>
1717
@else
18-
<script type="module" src="{{vh_module_assets_url("Cms", "build/main.js")}}"></script>
18+
<script type="module" src="{{vh_module_assets_url("Cms", "build/index.js")}}"></script>
1919
@endif
2020

2121
@endsection

Vue/pages/contents/Form.vue

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,12 +50,16 @@ const toggleFormMenu = (event) => {
5050
<template #content>
5151
<div class="col-12 p-0">
5252
<div v-if="store.item">
53-
<div>
53+
<div class="p-inputgroup">
5454
<InputText class="w-full p-inputtext-sm mb-2"
5555
name="contents-name"
5656
data-testid="contents-name"
5757
placeholder="Perma link"
5858
v-model="store.item.permalink"/>
59+
<Button v-if="store.item.id"
60+
data-testid="contents-to_external_link"
61+
@click="store.toExternalLink(store.item)"
62+
class="p-button-sm mb-2" icon="pi pi-external-link"/>
5963
</div>
6064
<div class="mb-2">
6165
<AutoComplete v-model="store.selected_user_id"

Vue/pages/contents/components/Table.vue

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,12 @@ const useVaah = vaah();
9595
<template #body="prop">
9696
<div class="p-inputgroup ">
9797

98+
<Button class="p-button-tiny p-button-text"
99+
data-testid="contents-table-to-external-ink"
100+
v-tooltip.top="'View Content'"
101+
@click="store.toExternalLink(prop.data)"
102+
icon="pi pi-external-link" />
103+
98104
<Button class="p-button-tiny p-button-text"
99105
data-testid="contents-table-to-view"
100106
v-tooltip.top="'View'"

Vue/stores/store-contents.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -679,6 +679,12 @@ export const useContentStore = defineStore({
679679
this.$router.push({name: 'contents.form'})
680680
},
681681
//---------------------------------------------------------------------
682+
toExternalLink(item)
683+
{
684+
window.open(item.link_prefix+item.permalink,
685+
'_blank');
686+
},
687+
//---------------------------------------------------------------------
682688
toView(item)
683689
{
684690
this.item = vaah().clone(item);

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "vaahcms/cms",
33
"description": "Cms",
4-
"version": "2.0.0",
4+
"version": "2.0.1",
55
"authors": [
66
{
77
"name": "vaah",

0 commit comments

Comments
 (0)